This repository has been archived by the owner on Oct 4, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 54
P2 786 only render ok when block is valid #1146
Merged
increddibelly
merged 41 commits into
develop
from
P2-786-only-render-ok-when-block-is-valid
May 10, 2021
Merged
Changes from 1 commit
Commits
Show all changes
41 commits
Select commit
Hold shift + click to select a range
4f15ce7
Added a method that checks if the blockValidationResult is considered…
d976c74
Adds a check to see if the added suggestion is valid
0e3a803
Updates the tests for the blocksuggestions
f772213
Improval of the test by mocking the functions directly
bc2a734
Merge branch 'develop' of https://github.com/Yoast/javascript into P2…
9eb9930
Process CR
c467972
Remove typehints in jsdoc
54dfb3a
Merge branch 'develop' of https://github.com/Yoast/javascript into P2…
cd2ea53
Check if the block validation is OK
c67c29a
Merge branch 'develop' of https://github.com/Yoast/javascript into P2…
ebfa7e5
Merge branch 'develop' of https://github.com/Yoast/javascript into P2…
8e2debd
Refactored the BlockSuggestionsPresenter a little bit
7404075
Changes the working of the validation a little bit.
51d120d
make the SidebarWarningPresenter retrieve validation for a client Id
increddibelly 74d36e4
fix unit tests
increddibelly c89071d
extract the BlockSuggestionsPresenter logic from the component
increddibelly e95a228
BlockSuggestionsPresenter allows more detailed control now; validatio…
increddibelly 565f3fe
Merge branch 'develop' into P2-786-only-render-ok-when-block-is-valid
increddibelly 0426ce0
added additional valid results and validation
increddibelly 9c10dcf
Add validation to RichtTextBase
increddibelly e251ab9
remove unused code
increddibelly 25356ce
added ValidationBlockInstruction to allow blocks to opt-in validation
increddibelly 9872f78
fixing unit tests
increddibelly cd31dfe
fixed unit tests
increddibelly 94a719f
Bump @wordpress/data to the latest version
johannadevos 87a09ca
prevent an error for missing instructions
increddibelly f9f5aaf
Merge remote-tracking branch 'origin/release/16.3' into P2-786-only-r…
increddibelly cad6799
replaced ValidatingBlockInstruction base class with single function
increddibelly 9f8404e
Merge remote-tracking branch 'origin/release/16.3' into P2-786-only-r…
increddibelly 1d0e61d
fine tune variationpicker validation
increddibelly a41779b
fix Date validation
increddibelly 3c14f53
typo
increddibelly e28dcb0
Merge remote-tracking branch 'origin/develop' into P2-786-only-render…
increddibelly 8db91db
fix Date tests.
increddibelly 318b5a3
Update packages/schema-blocks/src/functions/presenters/BlockSuggestio…
increddibelly 0f4d7b1
Update packages/schema-blocks/src/functions/presenters/BlockSuggestio…
increddibelly 94fa03a
processed CR comments
increddibelly c93634a
Update packages/schema-blocks/src/core/validation/BlockValidationResu…
increddibelly 3cfa7f1
fix CS
increddibelly a92916b
make method of reading current block content consistent with other Yo…
increddibelly 0053d33
Removed superfluous isValid check from BlockSuggestionsPresenter.
hansjovis File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
fine tune variationpicker validation
- Loading branch information
commit 1d0e61db546682ed6a79540f3415fca7e5f7a83e
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,6 @@ import { __, sprintf } from "@wordpress/i18n"; | |
import { BlockValidation, BlockValidationResult, BlockPresence } from "../../core/validation"; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Nice that you consolidated these imports 👍 |
||
import { getHumanReadableBlockName } from "../BlockHelper"; | ||
import { getAllDescendantIssues } from "../validators"; | ||
import logger from "../logger"; | ||
|
||
/** | ||
* A warning message for in the sidebar schema analysis. | ||
|
@@ -90,8 +89,6 @@ export function createAnalysisMessages( validation: BlockValidationResult ): Sid | |
} | ||
|
||
const issues = getAllDescendantIssues( validation ); | ||
logger.debug( "Issues:", issues ); | ||
|
||
const messages = []; | ||
|
||
messages.push( ...getErrorMessages( issues ) ); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.