Add backward compatibility support for lightBlockWrapper in getSaveElement#27189
Merged
Conversation
|
Size Change: +19 B (0%) Total Size: 1.2 MB
ℹ️ View Unchanged
|
tellthemachines
approved these changes
Nov 25, 2020
Contributor
tellthemachines
left a comment
There was a problem hiding this comment.
This is working well!
Contributor
|
lightBlockWrapper was never a stable API (you were forced to use __experimentalBlock in addition to it) so I'm really not sure this code is needed. |
Contributor
|
I guess it's ok for consistency but I wouldn't mind removing all of these fallbacks. |
tellthemachines
added a commit
that referenced
this pull request
Dec 1, 2020
* Provide a minimum of code wrapping for the code block. (#26623) * Block Support: Fix font size style when applying block support (#26762) * Fix Separator editor styles (#27071) * Fix the Post author selector for contributors (#26554) Co-authored-by: Riad Benguella <benguella@gmail.com> * Align single half width column to left (#27142) * remove the auto margin for individual column blocks * update margin values for blocks in blocks to zero insted of auto * Add backward compatibility support for lightBlockWrapper in getSaveElement (#27189) * Code block: paste plain text (#27236) * paste plain text option * Add e2e test * Fix crash when null date passed to TimePicker (#27316) * Fix crash when null date passed. * Update test * Fix GH actions "cancel" step (#27025) * use new syntax for setting env var * Update package-lock * Update package-lock again * Remove the button only option from the UI until it can be wired up to something that works in the front end. (#27379) * Fix combobox csuggestion list closure when clicking scrollbar (#27367) Co-authored-by: Joen A <1204802+jasmussen@users.noreply.github.com> Co-authored-by: Aaron Robertshaw <60436221+aaronrobertshaw@users.noreply.github.com> Co-authored-by: Nik Tsekouras <ntsekouras@outlook.com> Co-authored-by: Adam Silverstein <adamsilverstein@earthboundhosting.com> Co-authored-by: Riad Benguella <benguella@gmail.com> Co-authored-by: andrei draganescu <me@andreidraganescu.info> Co-authored-by: Daniel Richards <daniel.richards@automattic.com> Co-authored-by: Ella van Durpe <wp@iseulde.com> Co-authored-by: Noah Allen <noahtallen@gmail.com> Co-authored-by: Andy Peatling <apeatling@users.noreply.github.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Description
Fixes #26672
#25642 added support for the
apiVersion: 2block setting which replaces thelightBlockWrappersupports setting.In some places in that PR, backwards compatibility for
lightBlockWrapperwas left in place:gutenberg/packages/block-editor/src/components/block-edit/edit.js
Lines 54 to 57 in 0ca9736
gutenberg/packages/block-editor/src/components/block-list/block.js
Lines 137 to 139 in 1f0d0f5
But
getSaveElementdoesn't seem to have that, which causes the duplicate classnames described in #26672:gutenberg/packages/blocks/src/api/serializer.js
Lines 119 to 123 in 1f0d0f5
How has this been tested?
Types of changes
Bug fix (non-breaking change which fixes an issue)
Checklist: