-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Blocks: Apply the most recent filters to previously registered blocks #34299
Merged
+469
−153
Merged
Changes from all commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
5536a23
Blocks: Try to split block registration from filtering
gziolo 5181bfa
Experiment with data control for processing block settings
gziolo b0132b7
Add store controls that reapplies block type filters
gziolo d87f4b0
Add test block and filter to validate if it works
gziolo 78fc988
Meassure impact on the loading time when 100 custom blocks and filter…
gziolo bc1e788
Reapply block type filters for all editor screens
gziolo b42a4b6
Remove test code examples
gziolo 8496a17
Improve code documentation for new functionality
gziolo 11b6b59
Remove broken functionality in the block types reducer
gziolo 097b240
Apply suggestions from code review
gziolo 43a763d
Provide the default value for variations iin block type to align with…
gziolo c2456fa
Improve handling for block styles and variations when `ADD_BLOCK_TYPE…
gziolo 5fc04e9
Update buildBlockTypeItem to correctly fetch block type variations
gziolo 98036d7
Test: Add e2e test that ensures that filters can be added after block…
gziolo aaabad7
Blocks: Move logic to actions and remove controls
gziolo 03fb310
Rename __experimentalAddBlockType to __experimentalRegisterBlockType
gziolo 5ad37b4
Improve the description for __experimentalReapplyBlockTypeFilters
gziolo 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
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
Oops, something went wrong.
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.
Block
variations
, similar tostyles
, default to an empty array on the server:https://github.com/WordPress/wordpress-develop/blob/0bf7d5ea0dd8761ec3026a01aaa27646db8bd7a4/src/wp-includes/class-wp-block-type.php#L102-L108
Let's align how it is handled.