-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Transformation from Separator to Spacer (#66230)
* Add a transform from the Separator block to the Spacer block * Add a transform from the Separator block to the Spacer block Feat #65492 * Add transformation from spacer to separator - Remove the default height of 50px after transformation to default 100px that of Spacer - Update the transform of blocks so that it retains anchor attribute * Add new transformation block titles in Test * Add new transformation block titles in Test * Add new transformation block titles in Test and resolve linting problem * Add new transformation block titles in Test and resolve linting problem * Update test suite snapshot for test [mobile] to pass successfully --------- Co-authored-by: talldan <[email protected]> Co-authored-by: rudrakshi-gupta <[email protected]>
- Loading branch information
1 parent
0d91946
commit 5b7ac9e
Showing
7 changed files
with
47 additions
and
2 deletions.
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
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 |
---|---|---|
@@ -0,0 +1,20 @@ | ||
/** | ||
* WordPress dependencies | ||
*/ | ||
import { createBlock } from '@wordpress/blocks'; | ||
|
||
const transforms = { | ||
to: [ | ||
{ | ||
type: 'block', | ||
blocks: [ 'core/separator' ], // Transform to Separator. | ||
transform: ( { anchor } ) => { | ||
return createBlock( 'core/separator', { | ||
anchor: anchor || '', | ||
} ); | ||
}, | ||
}, | ||
], | ||
}; | ||
|
||
export default transforms; |
5b7ac9e
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.
Flaky tests detected in 5b7ac9e.
Some tests passed with failed attempts. The failures may not be related to this commit but are still reported for visibility. See the documentation for more information.
🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/11496803755
📝 Reported issues:
/test/e2e/specs/widgets/customizing-widgets.spec.js