mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-04-02 03:34:33 +00:00
Editor: Introduce sticky position block support.
In the Gutenberg plugin, a position block support feature was introduced last year, that allows a Group block to be set to a "sticky" position, meaning that when the page scrolls, the block will stick to the top of the window. This change merges the "sticky" position feature for blocks introduced in Gutenberg 15.0. Props andrewserong, flixos90, mukesh27. Fixes #57618. git-svn-id: https://develop.svn.wordpress.org/trunk@55285 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -304,7 +304,8 @@ class WP_Theme_JSON {
|
||||
* and `typography`, and renamed others according to the new schema.
|
||||
* @since 6.0.0 Added `color.defaultDuotone`.
|
||||
* @since 6.1.0 Added `layout.definitions` and `useRootPaddingAwareAlignments`.
|
||||
* @since 6.2.0 Added `dimensions.minHeight`, 'shadow.presets', and 'shadow.defaultPresets'.
|
||||
* @since 6.2.0 Added `dimensions.minHeight`, 'shadow.presets', 'shadow.defaultPresets',
|
||||
* `position.fixed` and `position.sticky`.
|
||||
* @var array
|
||||
*/
|
||||
const VALID_SETTINGS = array(
|
||||
@@ -339,6 +340,10 @@ class WP_Theme_JSON {
|
||||
'definitions' => null,
|
||||
'wideSize' => null,
|
||||
),
|
||||
'position' => array(
|
||||
'fixed' => null,
|
||||
'sticky' => null,
|
||||
),
|
||||
'spacing' => array(
|
||||
'customSpacingSize' => null,
|
||||
'spacingSizes' => null,
|
||||
@@ -513,7 +518,7 @@ class WP_Theme_JSON {
|
||||
* Options that settings.appearanceTools enables.
|
||||
*
|
||||
* @since 6.0.0
|
||||
* @since 6.2.0 Added `dimensions.minHeight`.
|
||||
* @since 6.2.0 Added `dimensions.minHeight` and `position.sticky`.
|
||||
* @var array
|
||||
*/
|
||||
const APPEARANCE_TOOLS_OPT_INS = array(
|
||||
@@ -523,6 +528,7 @@ class WP_Theme_JSON {
|
||||
array( 'border', 'width' ),
|
||||
array( 'color', 'link' ),
|
||||
array( 'dimensions', 'minHeight' ),
|
||||
array( 'position', 'sticky' ),
|
||||
array( 'spacing', 'blockGap' ),
|
||||
array( 'spacing', 'margin' ),
|
||||
array( 'spacing', 'padding' ),
|
||||
|
||||
Reference in New Issue
Block a user