@wordpress/block-editor 15.5.0 → 15.5.1-next.ff1cebbba.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +0 -4
- package/build/autocompleters/block.js +117 -87
- package/build/autocompleters/block.js.map +7 -1
- package/build/autocompleters/link.js +58 -48
- package/build/autocompleters/link.js.map +7 -1
- package/build/components/alignment-control/index.js +44 -28
- package/build/components/alignment-control/index.js.map +7 -1
- package/build/components/alignment-control/ui.js +72 -54
- package/build/components/alignment-control/ui.js.map +7 -1
- package/build/components/autocomplete/index.js +64 -62
- package/build/components/autocomplete/index.js.map +7 -1
- package/build/components/background-image-control/index.js +494 -452
- package/build/components/background-image-control/index.js.map +7 -1
- package/build/components/block-actions/index.js +76 -62
- package/build/components/block-actions/index.js.map +7 -1
- package/build/components/block-alignment-control/constants.js +44 -25
- package/build/components/block-alignment-control/constants.js.map +7 -1
- package/build/components/block-alignment-control/index.js +44 -28
- package/build/components/block-alignment-control/index.js.map +7 -1
- package/build/components/block-alignment-control/ui.js +75 -71
- package/build/components/block-alignment-control/ui.js.map +7 -1
- package/build/components/block-alignment-control/use-available-alignments.js +60 -54
- package/build/components/block-alignment-control/use-available-alignments.js.map +7 -1
- package/build/components/block-alignment-matrix-control/index.js +66 -82
- package/build/components/block-alignment-matrix-control/index.js.map +7 -1
- package/build/components/block-allowed-blocks/allowed-blocks-control.js +99 -0
- package/build/components/block-allowed-blocks/allowed-blocks-control.js.map +7 -0
- package/build/components/block-allowed-blocks/index.js +42 -0
- package/build/components/block-allowed-blocks/index.js.map +7 -0
- package/build/components/block-allowed-blocks/modal.js +124 -0
- package/build/components/block-allowed-blocks/modal.js.map +7 -0
- package/build/components/block-breadcrumb/index.js +125 -103
- package/build/components/block-breadcrumb/index.js.map +7 -1
- package/build/components/block-canvas/index.js +121 -123
- package/build/components/block-canvas/index.js.map +7 -1
- package/build/components/block-card/index.js +92 -121
- package/build/components/block-card/index.js.map +7 -1
- package/build/components/block-compare/block-view.js +38 -35
- package/build/components/block-compare/block-view.js.map +7 -1
- package/build/components/block-compare/index.js +73 -60
- package/build/components/block-compare/index.js.map +7 -1
- package/build/components/block-content-overlay/index.js +31 -21
- package/build/components/block-content-overlay/index.js.map +7 -1
- package/build/components/block-context/index.js +39 -46
- package/build/components/block-context/index.js.map +7 -1
- package/build/components/block-controls/fill.js +51 -40
- package/build/components/block-controls/fill.js.map +7 -1
- package/build/components/block-controls/groups.js +29 -16
- package/build/components/block-controls/groups.js.map +7 -1
- package/build/components/block-controls/hook.js +39 -21
- package/build/components/block-controls/hook.js.map +7 -1
- package/build/components/block-controls/index.js +47 -29
- package/build/components/block-controls/index.js.map +7 -1
- package/build/components/block-controls/slot.js +58 -51
- package/build/components/block-controls/slot.js.map +7 -1
- package/build/components/block-draggable/draggable-chip.js +59 -44
- package/build/components/block-draggable/draggable-chip.js.map +7 -1
- package/build/components/block-draggable/index.js +165 -146
- package/build/components/block-draggable/index.js.map +7 -1
- package/build/components/block-draggable/use-scroll-when-dragging.js +58 -47
- package/build/components/block-draggable/use-scroll-when-dragging.js.map +7 -1
- package/build/components/block-edit/context.js +52 -30
- package/build/components/block-edit/context.js.map +7 -1
- package/build/components/block-edit/edit.js +230 -195
- package/build/components/block-edit/edit.js.map +7 -1
- package/build/components/block-edit/index.js +93 -72
- package/build/components/block-edit/index.js.map +7 -1
- package/build/components/block-edit/multiple-usage-warning.js +79 -41
- package/build/components/block-edit/multiple-usage-warning.js.map +7 -1
- package/build/components/block-edit-visually-button/index.js +40 -32
- package/build/components/block-edit-visually-button/index.js.map +7 -1
- package/build/components/block-editing-mode/index.js +42 -64
- package/build/components/block-editing-mode/index.js.map +7 -1
- package/build/components/block-full-height-alignment-control/index.js +38 -22
- package/build/components/block-full-height-alignment-control/index.js.map +7 -1
- package/build/components/block-heading-level-dropdown/heading-level-icon.js +35 -42
- package/build/components/block-heading-level-dropdown/heading-level-icon.js.map +7 -1
- package/build/components/block-heading-level-dropdown/index.js +64 -65
- package/build/components/block-heading-level-dropdown/index.js.map +7 -1
- package/build/components/block-icon/index.js +52 -43
- package/build/components/block-icon/index.js.map +7 -1
- package/build/components/block-inspector/edit-contents-button.js +53 -48
- package/build/components/block-inspector/edit-contents-button.js.map +7 -1
- package/build/components/block-inspector/index.js +237 -200
- package/build/components/block-inspector/index.js.map +7 -1
- package/build/components/block-inspector/useBlockInspectorAnimationSettings.js +44 -38
- package/build/components/block-inspector/useBlockInspectorAnimationSettings.js.map +7 -1
- package/build/components/block-list/block-crash-boundary.js +25 -12
- package/build/components/block-list/block-crash-boundary.js.map +7 -1
- package/build/components/block-list/block-crash-warning.js +37 -23
- package/build/components/block-list/block-crash-warning.js.map +7 -1
- package/build/components/block-list/block-html.js +65 -49
- package/build/components/block-list/block-html.js.map +7 -1
- package/build/components/block-list/block-invalid-warning.js +152 -106
- package/build/components/block-list/block-invalid-warning.js.map +7 -1
- package/build/components/block-list/block.js +366 -423
- package/build/components/block-list/block.js.map +7 -1
- package/build/components/block-list/index.js +210 -178
- package/build/components/block-list/index.js.map +7 -1
- package/build/components/block-list/layout.js +46 -48
- package/build/components/block-list/layout.js.map +7 -1
- package/build/components/block-list/private-block-context.js +29 -12
- package/build/components/block-list/private-block-context.js.map +7 -1
- package/build/components/block-list/subdirectory-icon.js +43 -26
- package/build/components/block-list/subdirectory-icon.js.map +7 -1
- package/build/components/block-list/use-block-props/index.js +118 -149
- package/build/components/block-list/use-block-props/index.js.map +7 -1
- package/build/components/block-list/use-block-props/use-block-refs.js +49 -59
- package/build/components/block-list/use-block-props/use-block-refs.js.map +7 -1
- package/build/components/block-list/use-block-props/use-firefox-draggable-compatibility.js +42 -47
- package/build/components/block-list/use-block-props/use-firefox-draggable-compatibility.js.map +7 -1
- package/build/components/block-list/use-block-props/use-focus-first-element.js +47 -62
- package/build/components/block-list/use-block-props/use-focus-first-element.js.map +7 -1
- package/build/components/block-list/use-block-props/use-focus-handler.js +54 -65
- package/build/components/block-list/use-block-props/use-focus-handler.js.map +7 -1
- package/build/components/block-list/use-block-props/use-intersection-observer.js +41 -25
- package/build/components/block-list/use-block-props/use-intersection-observer.js.map +7 -1
- package/build/components/block-list/use-block-props/use-is-hovered.js +37 -24
- package/build/components/block-list/use-block-props/use-is-hovered.js.map +7 -1
- package/build/components/block-list/use-block-props/use-scroll-into-view.js +54 -40
- package/build/components/block-list/use-block-props/use-scroll-into-view.js.map +7 -1
- package/build/components/block-list/use-block-props/use-selected-block-event-handlers.js +205 -173
- package/build/components/block-list/use-block-props/use-selected-block-event-handlers.js.map +7 -1
- package/build/components/block-list/use-in-between-inserter.js +122 -113
- package/build/components/block-list/use-in-between-inserter.js.map +7 -1
- package/build/components/block-list/zoom-out-separator.js +85 -80
- package/build/components/block-list/zoom-out-separator.js.map +7 -1
- package/build/components/block-list-appender/index.js +79 -86
- package/build/components/block-list-appender/index.js.map +7 -1
- package/build/components/block-lock/index.js +44 -31
- package/build/components/block-lock/index.js.map +7 -1
- package/build/components/block-lock/menu-item.js +59 -42
- package/build/components/block-lock/menu-item.js.map +7 -1
- package/build/components/block-lock/modal.js +233 -183
- package/build/components/block-lock/modal.js.map +7 -1
- package/build/components/block-lock/toolbar.js +59 -51
- package/build/components/block-lock/toolbar.js.map +7 -1
- package/build/components/block-lock/use-block-lock.js +48 -43
- package/build/components/block-lock/use-block-lock.js.map +7 -1
- package/build/components/block-manager/category.js +111 -65
- package/build/components/block-manager/category.js.map +7 -1
- package/build/components/block-manager/checklist.js +55 -36
- package/build/components/block-manager/checklist.js.map +7 -1
- package/build/components/block-manager/index.js +123 -91
- package/build/components/block-manager/index.js.map +7 -1
- package/build/components/block-mover/button.js +155 -133
- package/build/components/block-mover/button.js.map +7 -1
- package/build/components/block-mover/index.js +111 -95
- package/build/components/block-mover/index.js.map +7 -1
- package/build/components/block-mover/mover-description.js +243 -169
- package/build/components/block-mover/mover-description.js.map +7 -1
- package/build/components/block-navigation/dropdown.js +86 -72
- package/build/components/block-navigation/dropdown.js.map +7 -1
- package/build/components/block-parent-selector/index.js +73 -59
- package/build/components/block-parent-selector/index.js.map +7 -1
- package/build/components/block-pattern-setup/constants.js +29 -8
- package/build/components/block-pattern-setup/constants.js.map +7 -1
- package/build/components/block-pattern-setup/index.js +175 -147
- package/build/components/block-pattern-setup/index.js.map +7 -1
- package/build/components/block-pattern-setup/setup-toolbar.js +94 -73
- package/build/components/block-pattern-setup/setup-toolbar.js.map +7 -1
- package/build/components/block-pattern-setup/use-patterns-setup.js +42 -28
- package/build/components/block-pattern-setup/use-patterns-setup.js.map +7 -1
- package/build/components/block-patterns-list/index.js +189 -164
- package/build/components/block-patterns-list/index.js.map +7 -1
- package/build/components/block-patterns-paging/index.js +119 -84
- package/build/components/block-patterns-paging/index.js.map +7 -1
- package/build/components/block-popover/cover.js +54 -45
- package/build/components/block-popover/cover.js.map +7 -1
- package/build/components/block-popover/drop-zone.js +64 -54
- package/build/components/block-popover/drop-zone.js.map +7 -1
- package/build/components/block-popover/inbetween.js +127 -133
- package/build/components/block-popover/inbetween.js.map +7 -1
- package/build/components/block-popover/index.js +113 -91
- package/build/components/block-popover/index.js.map +7 -1
- package/build/components/block-popover/use-popover-scroll.js +48 -53
- package/build/components/block-popover/use-popover-scroll.js.map +7 -1
- package/build/components/block-preview/async.js +33 -35
- package/build/components/block-preview/async.js.map +7 -1
- package/build/components/block-preview/auto.js +114 -103
- package/build/components/block-preview/auto.js.map +7 -1
- package/build/components/block-preview/index.js +136 -116
- package/build/components/block-preview/index.js.map +7 -1
- package/build/components/block-quick-navigation/index.js +82 -76
- package/build/components/block-quick-navigation/index.js.map +7 -1
- package/build/components/block-removal-warning-modal/index.js +76 -55
- package/build/components/block-removal-warning-modal/index.js.map +7 -1
- package/build/components/block-rename/index.js +41 -24
- package/build/components/block-rename/index.js.map +7 -1
- package/build/components/block-rename/is-empty-string.js +22 -5
- package/build/components/block-rename/is-empty-string.js.map +7 -1
- package/build/components/block-rename/modal.js +135 -103
- package/build/components/block-rename/modal.js.map +7 -1
- package/build/components/block-rename/rename-control.js +59 -36
- package/build/components/block-rename/rename-control.js.map +7 -1
- package/build/components/block-rename/use-block-rename.js +24 -11
- package/build/components/block-rename/use-block-rename.js.map +7 -1
- package/build/components/block-selection-clearer/index.js +53 -57
- package/build/components/block-selection-clearer/index.js.map +7 -1
- package/build/components/block-settings-menu/block-html-convert-button.js +46 -34
- package/build/components/block-settings-menu/block-html-convert-button.js.map +7 -1
- package/build/components/block-settings-menu/block-mode-toggle.js +56 -53
- package/build/components/block-settings-menu/block-mode-toggle.js.map +7 -1
- package/build/components/block-settings-menu/block-parent-selector-menu-item.js +59 -42
- package/build/components/block-settings-menu/block-parent-selector-menu-item.js.map +7 -1
- package/build/components/block-settings-menu/block-settings-dropdown.js +287 -233
- package/build/components/block-settings-menu/block-settings-dropdown.js.map +7 -1
- package/build/components/block-settings-menu/block-settings-menu-first-item.js +27 -15
- package/build/components/block-settings-menu/block-settings-menu-first-item.js.map +7 -1
- package/build/components/block-settings-menu/index.js +53 -32
- package/build/components/block-settings-menu/index.js.map +7 -1
- package/build/components/block-settings-menu-controls/index.js +129 -107
- package/build/components/block-settings-menu-controls/index.js.map +7 -1
- package/build/components/block-styles/index.js +99 -75
- package/build/components/block-styles/index.js.map +7 -1
- package/build/components/block-styles/menu-items.js +60 -43
- package/build/components/block-styles/menu-items.js.map +7 -1
- package/build/components/block-styles/preview-panel.js +42 -26
- package/build/components/block-styles/preview-panel.js.map +7 -1
- package/build/components/block-styles/use-styles-for-block.js +53 -70
- package/build/components/block-styles/use-styles-for-block.js.map +7 -1
- package/build/components/block-styles/utils.js +61 -66
- package/build/components/block-styles/utils.js.map +7 -1
- package/build/components/block-switcher/block-styles-menu.js +46 -33
- package/build/components/block-switcher/block-styles-menu.js.map +7 -1
- package/build/components/block-switcher/block-transformations-menu.js +137 -126
- package/build/components/block-switcher/block-transformations-menu.js.map +7 -1
- package/build/components/block-switcher/block-variation-transformations.js +113 -85
- package/build/components/block-switcher/block-variation-transformations.js.map +7 -1
- package/build/components/block-switcher/index.js +247 -208
- package/build/components/block-switcher/index.js.map +7 -1
- package/build/components/block-switcher/pattern-transformations-menu.js +129 -99
- package/build/components/block-switcher/pattern-transformations-menu.js.map +7 -1
- package/build/components/block-switcher/preview-block-popover.js +48 -38
- package/build/components/block-switcher/preview-block-popover.js.map +7 -1
- package/build/components/block-switcher/use-transformed-patterns.js +62 -80
- package/build/components/block-switcher/use-transformed-patterns.js.map +7 -1
- package/build/components/block-switcher/utils.js +37 -45
- package/build/components/block-switcher/utils.js.map +7 -1
- package/build/components/block-title/index.js +35 -38
- package/build/components/block-title/index.js.map +7 -1
- package/build/components/block-title/use-block-display-title.js +48 -60
- package/build/components/block-title/use-block-display-title.js.map +7 -1
- package/build/components/block-toolbar/block-name-context.js +26 -13
- package/build/components/block-toolbar/block-name-context.js.map +7 -1
- package/build/components/block-toolbar/block-toolbar-last-item.js +27 -15
- package/build/components/block-toolbar/block-toolbar-last-item.js.map +7 -1
- package/build/components/block-toolbar/change-design.js +104 -92
- package/build/components/block-toolbar/change-design.js.map +7 -1
- package/build/components/block-toolbar/index.js +203 -186
- package/build/components/block-toolbar/index.js.map +7 -1
- package/build/components/block-toolbar/switch-section-style.js +111 -88
- package/build/components/block-toolbar/switch-section-style.js.map +7 -1
- package/build/components/block-toolbar/use-has-block-toolbar.js +33 -33
- package/build/components/block-toolbar/use-has-block-toolbar.js.map +7 -1
- package/build/components/block-toolbar/utils.js +63 -79
- package/build/components/block-toolbar/utils.js.map +7 -1
- package/build/components/block-tools/block-toolbar-popover.js +75 -72
- package/build/components/block-tools/block-toolbar-popover.js.map +7 -1
- package/build/components/block-tools/empty-block-inserter.js +64 -40
- package/build/components/block-tools/empty-block-inserter.js.map +7 -1
- package/build/components/block-tools/index.js +168 -119
- package/build/components/block-tools/index.js.map +7 -1
- package/build/components/block-tools/insertion-point.js +174 -159
- package/build/components/block-tools/insertion-point.js.map +7 -1
- package/build/components/block-tools/use-block-toolbar-popover-props.js +74 -101
- package/build/components/block-tools/use-block-toolbar-popover-props.js.map +7 -1
- package/build/components/block-tools/use-selected-block-tool-props.js +58 -51
- package/build/components/block-tools/use-selected-block-tool-props.js.map +7 -1
- package/build/components/block-tools/use-show-block-tools.js +34 -31
- package/build/components/block-tools/use-show-block-tools.js.map +7 -1
- package/build/components/block-tools/zoom-out-mode-inserter-button.js +56 -31
- package/build/components/block-tools/zoom-out-mode-inserter-button.js.map +7 -1
- package/build/components/block-tools/zoom-out-mode-inserters.js +71 -54
- package/build/components/block-tools/zoom-out-mode-inserters.js.map +7 -1
- package/build/components/block-types-list/index.js +57 -35
- package/build/components/block-types-list/index.js.map +7 -1
- package/build/components/block-variation-picker/index.js +86 -58
- package/build/components/block-variation-picker/index.js.map +7 -1
- package/build/components/block-variation-transforms/index.js +155 -140
- package/build/components/block-variation-transforms/index.js.map +7 -1
- package/build/components/block-vertical-alignment-control/index.js +44 -28
- package/build/components/block-vertical-alignment-control/index.js.map +7 -1
- package/build/components/block-vertical-alignment-control/ui.js +62 -49
- package/build/components/block-vertical-alignment-control/ui.js.map +7 -1
- package/build/components/block-visibility/index.js +38 -17
- package/build/components/block-visibility/index.js.map +7 -1
- package/build/components/block-visibility/menu-item.js +99 -44
- package/build/components/block-visibility/menu-item.js.map +7 -1
- package/build/components/block-visibility/toolbar.js +75 -73
- package/build/components/block-visibility/toolbar.js.map +7 -1
- package/build/components/border-radius-control/constants.js +61 -32
- package/build/components/border-radius-control/constants.js.map +7 -1
- package/build/components/border-radius-control/index.js +106 -97
- package/build/components/border-radius-control/index.js.map +7 -1
- package/build/components/border-radius-control/linked-button.js +39 -26
- package/build/components/border-radius-control/linked-button.js.map +7 -1
- package/build/components/border-radius-control/single-input-control.js +171 -139
- package/build/components/border-radius-control/single-input-control.js.map +7 -1
- package/build/components/border-radius-control/utils.js +87 -181
- package/build/components/border-radius-control/utils.js.map +7 -1
- package/build/components/button-block-appender/index.js +105 -90
- package/build/components/button-block-appender/index.js.map +7 -1
- package/build/components/child-layout-control/index.js +317 -272
- package/build/components/child-layout-control/index.js.map +7 -1
- package/build/components/collab/block-comment-icon-slot.js +25 -12
- package/build/components/collab/block-comment-icon-slot.js.map +7 -1
- package/build/components/collab/block-comment-icon-toolbar-slot.js +27 -12
- package/build/components/collab/block-comment-icon-toolbar-slot.js.map +7 -1
- package/build/components/color-palette/control.js +44 -19
- package/build/components/color-palette/control.js.map +7 -1
- package/build/components/color-palette/index.js +35 -15
- package/build/components/color-palette/index.js.map +7 -1
- package/build/components/color-palette/with-color-context.js +58 -30
- package/build/components/color-palette/with-color-context.js.map +7 -1
- package/build/components/color-style-selector/index.js +72 -90
- package/build/components/color-style-selector/index.js.map +7 -1
- package/build/components/colors/index.js +44 -36
- package/build/components/colors/index.js.map +7 -1
- package/build/components/colors/utils.js +57 -81
- package/build/components/colors/utils.js.map +7 -1
- package/build/components/colors/with-colors.js +155 -192
- package/build/components/colors/with-colors.js.map +7 -1
- package/build/components/colors-gradients/control.js +140 -117
- package/build/components/colors-gradients/control.js.map +7 -1
- package/build/components/colors-gradients/dropdown.js +153 -159
- package/build/components/colors-gradients/dropdown.js.map +7 -1
- package/build/components/colors-gradients/panel-color-gradient-settings.js +120 -83
- package/build/components/colors-gradients/panel-color-gradient-settings.js.map +7 -1
- package/build/components/colors-gradients/use-multiple-origin-colors-and-gradients.js +92 -41
- package/build/components/colors-gradients/use-multiple-origin-colors-and-gradients.js.map +7 -1
- package/build/components/content-lock/index.js +26 -10
- package/build/components/content-lock/index.js.map +7 -1
- package/build/components/content-lock/modify-content-lock-menu-item.js +61 -57
- package/build/components/content-lock/modify-content-lock-menu-item.js.map +7 -1
- package/build/components/contrast-checker/index.js +87 -73
- package/build/components/contrast-checker/index.js.map +7 -1
- package/build/components/convert-to-group-buttons/index.js +86 -60
- package/build/components/convert-to-group-buttons/index.js.map +7 -1
- package/build/components/convert-to-group-buttons/toolbar.js +104 -102
- package/build/components/convert-to-group-buttons/toolbar.js.map +7 -1
- package/build/components/convert-to-group-buttons/use-convert-to-group-button-props.js +49 -61
- package/build/components/convert-to-group-buttons/use-convert-to-group-button-props.js.map +7 -1
- package/build/components/copy-handler/index.js +50 -40
- package/build/components/copy-handler/index.js.map +7 -1
- package/build/components/date-format-picker/index.js +136 -110
- package/build/components/date-format-picker/index.js.map +7 -1
- package/build/components/default-block-appender/index.js +110 -98
- package/build/components/default-block-appender/index.js.map +7 -1
- package/build/components/dimensions-tool/aspect-ratio-tool.js +76 -73
- package/build/components/dimensions-tool/aspect-ratio-tool.js.map +7 -1
- package/build/components/dimensions-tool/index.js +136 -190
- package/build/components/dimensions-tool/index.js.map +7 -1
- package/build/components/dimensions-tool/scale-tool.js +88 -93
- package/build/components/dimensions-tool/scale-tool.js.map +7 -1
- package/build/components/dimensions-tool/width-height-tool.js +93 -107
- package/build/components/dimensions-tool/width-height-tool.js.map +7 -1
- package/build/components/duotone/utils.js +40 -58
- package/build/components/duotone/utils.js.map +7 -1
- package/build/components/duotone-control/index.js +82 -69
- package/build/components/duotone-control/index.js.map +7 -1
- package/build/components/editable-text/index.js +40 -37
- package/build/components/editable-text/index.js.map +7 -1
- package/build/components/editor-styles/index.js +113 -100
- package/build/components/editor-styles/index.js.map +7 -1
- package/build/components/floating-toolbar/nav-up-icon.js +48 -29
- package/build/components/floating-toolbar/nav-up-icon.js.map +7 -1
- package/build/components/font-appearance-control/index.js +100 -118
- package/build/components/font-appearance-control/index.js.map +7 -1
- package/build/components/font-family/index.js +84 -66
- package/build/components/font-family/index.js.map +7 -1
- package/build/components/font-sizes/fluid-utils.js +81 -164
- package/build/components/font-sizes/fluid-utils.js.map +7 -1
- package/build/components/font-sizes/font-size-picker.js +38 -27
- package/build/components/font-sizes/font-size-picker.js.map +7 -1
- package/build/components/font-sizes/index.js +48 -43
- package/build/components/font-sizes/index.js.map +7 -1
- package/build/components/font-sizes/utils.js +37 -57
- package/build/components/font-sizes/utils.js.map +7 -1
- package/build/components/font-sizes/with-font-sizes.js +144 -119
- package/build/components/font-sizes/with-font-sizes.js.map +7 -1
- package/build/components/global-styles/advanced-panel.js +64 -51
- package/build/components/global-styles/advanced-panel.js.map +7 -1
- package/build/components/global-styles/background-panel.js +97 -88
- package/build/components/global-styles/background-panel.js.map +7 -1
- package/build/components/global-styles/border-panel.js +188 -156
- package/build/components/global-styles/border-panel.js.map +7 -1
- package/build/components/global-styles/color-panel.js +521 -401
- package/build/components/global-styles/color-panel.js.map +7 -1
- package/build/components/global-styles/context.js +36 -14
- package/build/components/global-styles/context.js.map +7 -1
- package/build/components/global-styles/dimensions-panel.js +427 -360
- package/build/components/global-styles/dimensions-panel.js.map +7 -1
- package/build/components/global-styles/filters-panel.js +153 -142
- package/build/components/global-styles/filters-panel.js.map +7 -1
- package/build/components/global-styles/get-block-css-selector.js +44 -79
- package/build/components/global-styles/get-block-css-selector.js.map +7 -1
- package/build/components/global-styles/get-global-styles-changes.js +152 -168
- package/build/components/global-styles/get-global-styles-changes.js.map +7 -1
- package/build/components/global-styles/hooks.js +259 -144
- package/build/components/global-styles/hooks.js.map +7 -1
- package/build/components/global-styles/image-settings-panel.js +62 -51
- package/build/components/global-styles/image-settings-panel.js.map +7 -1
- package/build/components/global-styles/index.js +107 -196
- package/build/components/global-styles/index.js.map +7 -1
- package/build/components/global-styles/shadow-panel-components.js +175 -164
- package/build/components/global-styles/shadow-panel-components.js.map +7 -1
- package/build/components/global-styles/typography-panel.js +421 -288
- package/build/components/global-styles/typography-panel.js.map +7 -1
- package/build/components/global-styles/typography-utils.js +92 -179
- package/build/components/global-styles/typography-utils.js.map +7 -1
- package/build/components/global-styles/use-global-styles-output.js +695 -761
- package/build/components/global-styles/use-global-styles-output.js.map +7 -1
- package/build/components/global-styles/utils.js +302 -358
- package/build/components/global-styles/utils.js.map +7 -1
- package/build/components/gradients/index.js +21 -15
- package/build/components/gradients/index.js.map +7 -1
- package/build/components/gradients/use-gradient.js +97 -83
- package/build/components/gradients/use-gradient.js.map +7 -1
- package/build/components/gradients/with-gradient.js +31 -20
- package/build/components/gradients/with-gradient.js.map +7 -1
- package/build/components/grid/grid-item-movers.js +160 -103
- package/build/components/grid/grid-item-movers.js.map +7 -1
- package/build/components/grid/grid-item-resizer.js +144 -108
- package/build/components/grid/grid-item-resizer.js.map +7 -1
- package/build/components/grid/grid-visualizer.js +279 -205
- package/build/components/grid/grid-visualizer.js.map +7 -1
- package/build/components/grid/index.js +34 -30
- package/build/components/grid/index.js.map +7 -1
- package/build/components/grid/use-get-number-of-blocks-before-cell.js +30 -24
- package/build/components/grid/use-get-number-of-blocks-before-cell.js.map +7 -1
- package/build/components/grid/use-grid-layout-sync.js +124 -118
- package/build/components/grid/use-grid-layout-sync.js.map +7 -1
- package/build/components/grid/utils.js +101 -80
- package/build/components/grid/utils.js.map +7 -1
- package/build/components/height-control/index.js +132 -196
- package/build/components/height-control/index.js.map +7 -1
- package/build/components/html-element-control/index.js +76 -91
- package/build/components/html-element-control/index.js.map +7 -1
- package/build/components/html-element-control/messages.js +58 -24
- package/build/components/html-element-control/messages.js.map +7 -1
- package/build/components/iframe/get-compatibility-styles.js +89 -87
- package/build/components/iframe/get-compatibility-styles.js.map +7 -1
- package/build/components/iframe/index.js +192 -214
- package/build/components/iframe/index.js.map +7 -1
- package/build/components/iframe/use-scale-canvas.js +164 -272
- package/build/components/iframe/use-scale-canvas.js.map +7 -1
- package/build/components/image-editor/aspect-ratio-dropdown.js +120 -106
- package/build/components/image-editor/aspect-ratio-dropdown.js.map +7 -1
- package/build/components/image-editor/constants.js +34 -9
- package/build/components/image-editor/constants.js.map +7 -1
- package/build/components/image-editor/context.js +54 -33
- package/build/components/image-editor/context.js.map +7 -1
- package/build/components/image-editor/cropper.js +85 -59
- package/build/components/image-editor/cropper.js.map +7 -1
- package/build/components/image-editor/form-controls.js +31 -32
- package/build/components/image-editor/form-controls.js.map +7 -1
- package/build/components/image-editor/index.js +73 -49
- package/build/components/image-editor/index.js.map +7 -1
- package/build/components/image-editor/rotation-button.js +37 -28
- package/build/components/image-editor/rotation-button.js.map +7 -1
- package/build/components/image-editor/use-save-image.js +98 -72
- package/build/components/image-editor/use-save-image.js.map +7 -1
- package/build/components/image-editor/use-transform-image.js +70 -45
- package/build/components/image-editor/use-transform-image.js.map +7 -1
- package/build/components/image-editor/zoom-dropdown.js +58 -50
- package/build/components/image-editor/zoom-dropdown.js.map +7 -1
- package/build/components/image-size-control/index.js +115 -102
- package/build/components/image-size-control/index.js.map +7 -1
- package/build/components/image-size-control/use-dimension-handler.js +40 -34
- package/build/components/image-size-control/use-dimension-handler.js.map +7 -1
- package/build/components/index.js +408 -1075
- package/build/components/index.js.map +7 -1
- package/build/components/inner-blocks/button-block-appender.js +49 -30
- package/build/components/inner-blocks/button-block-appender.js.map +7 -1
- package/build/components/inner-blocks/default-block-appender.js +37 -19
- package/build/components/inner-blocks/default-block-appender.js.map +7 -1
- package/build/components/inner-blocks/index.js +167 -190
- package/build/components/inner-blocks/index.js.map +7 -1
- package/build/components/inner-blocks/use-block-context.js +49 -37
- package/build/components/inner-blocks/use-block-context.js.map +7 -1
- package/build/components/inner-blocks/use-inner-block-template-sync.js +69 -73
- package/build/components/inner-blocks/use-inner-block-template-sync.js.map +7 -1
- package/build/components/inner-blocks/use-nested-settings-update.js +82 -107
- package/build/components/inner-blocks/use-nested-settings-update.js.map +7 -1
- package/build/components/inserter/block-patterns-explorer/index.js +78 -59
- package/build/components/inserter/block-patterns-explorer/index.js.map +7 -1
- package/build/components/inserter/block-patterns-explorer/pattern-explorer-sidebar.js +63 -49
- package/build/components/inserter/block-patterns-explorer/pattern-explorer-sidebar.js.map +7 -1
- package/build/components/inserter/block-patterns-explorer/pattern-list.js +137 -85
- package/build/components/inserter/block-patterns-explorer/pattern-list.js.map +7 -1
- package/build/components/inserter/block-patterns-tab/index.js +89 -62
- package/build/components/inserter/block-patterns-tab/index.js.map +7 -1
- package/build/components/inserter/block-patterns-tab/pattern-category-previews.js +184 -114
- package/build/components/inserter/block-patterns-tab/pattern-category-previews.js.map +7 -1
- package/build/components/inserter/block-patterns-tab/patterns-filter.js +144 -104
- package/build/components/inserter/block-patterns-tab/patterns-filter.js.map +7 -1
- package/build/components/inserter/block-patterns-tab/use-pattern-categories.js +89 -38
- package/build/components/inserter/block-patterns-tab/use-pattern-categories.js.map +7 -1
- package/build/components/inserter/block-patterns-tab/utils.js +57 -42
- package/build/components/inserter/block-patterns-tab/utils.js.map +7 -1
- package/build/components/inserter/block-types-tab.js +173 -140
- package/build/components/inserter/block-types-tab.js.map +7 -1
- package/build/components/inserter/category-tabs/index.js +90 -71
- package/build/components/inserter/category-tabs/index.js.map +7 -1
- package/build/components/inserter/hooks/use-block-types-state.js +92 -68
- package/build/components/inserter/hooks/use-block-types-state.js.map +7 -1
- package/build/components/inserter/hooks/use-insertion-point.js +160 -127
- package/build/components/inserter/hooks/use-insertion-point.js.map +7 -1
- package/build/components/inserter/hooks/use-patterns-paging.js +47 -35
- package/build/components/inserter/hooks/use-patterns-paging.js.map +7 -1
- package/build/components/inserter/hooks/use-patterns-state.js +111 -84
- package/build/components/inserter/hooks/use-patterns-state.js.map +7 -1
- package/build/components/inserter/index.js +230 -237
- package/build/components/inserter/index.js.map +7 -1
- package/build/components/inserter/library.js +73 -53
- package/build/components/inserter/library.js.map +7 -1
- package/build/components/inserter/media-tab/hooks.js +88 -86
- package/build/components/inserter/media-tab/hooks.js.map +7 -1
- package/build/components/inserter/media-tab/index.js +41 -24
- package/build/components/inserter/media-tab/index.js.map +7 -1
- package/build/components/inserter/media-tab/media-list.js +45 -29
- package/build/components/inserter/media-tab/media-list.js.map +7 -1
- package/build/components/inserter/media-tab/media-panel.js +72 -52
- package/build/components/inserter/media-tab/media-panel.js.map +7 -1
- package/build/components/inserter/media-tab/media-preview.js +266 -238
- package/build/components/inserter/media-tab/media-preview.js.map +7 -1
- package/build/components/inserter/media-tab/media-tab.js +108 -84
- package/build/components/inserter/media-tab/media-tab.js.map +7 -1
- package/build/components/inserter/media-tab/utils.js +47 -45
- package/build/components/inserter/media-tab/utils.js.map +7 -1
- package/build/components/inserter/menu.js +317 -221
- package/build/components/inserter/menu.js.map +7 -1
- package/build/components/inserter/mobile-tab-navigation.js +82 -76
- package/build/components/inserter/mobile-tab-navigation.js.map +7 -1
- package/build/components/inserter/no-results.js +26 -18
- package/build/components/inserter/no-results.js.map +7 -1
- package/build/components/inserter/panel.js +33 -31
- package/build/components/inserter/panel.js.map +7 -1
- package/build/components/inserter/preview-panel.js +71 -64
- package/build/components/inserter/preview-panel.js.map +7 -1
- package/build/components/inserter/quick-inserter.js +114 -88
- package/build/components/inserter/quick-inserter.js.map +7 -1
- package/build/components/inserter/search-items.js +90 -114
- package/build/components/inserter/search-items.js.map +7 -1
- package/build/components/inserter/search-results.js +171 -115
- package/build/components/inserter/search-results.js.map +7 -1
- package/build/components/inserter/tips.js +55 -28
- package/build/components/inserter/tips.js.map +7 -1
- package/build/components/inserter-button/sparkles.js +30 -19
- package/build/components/inserter-button/sparkles.js.map +7 -1
- package/build/components/inserter-draggable-blocks/index.js +87 -75
- package/build/components/inserter-draggable-blocks/index.js.map +7 -1
- package/build/components/inserter-list-item/index.js +135 -100
- package/build/components/inserter-list-item/index.js.map +7 -1
- package/build/components/inserter-listbox/context.js +26 -13
- package/build/components/inserter-listbox/context.js.map +7 -1
- package/build/components/inserter-listbox/group.js +52 -32
- package/build/components/inserter-listbox/group.js.map +7 -1
- package/build/components/inserter-listbox/index.js +59 -52
- package/build/components/inserter-listbox/index.js.map +7 -1
- package/build/components/inserter-listbox/item.js +47 -47
- package/build/components/inserter-listbox/item.js.map +7 -1
- package/build/components/inserter-listbox/row.js +27 -18
- package/build/components/inserter-listbox/row.js.map +7 -1
- package/build/components/inserter-menu-extension/index.js +27 -15
- package/build/components/inserter-menu-extension/index.js.map +7 -1
- package/build/components/inspector-controls/block-support-slot-container.js +37 -28
- package/build/components/inspector-controls/block-support-slot-container.js.map +7 -1
- package/build/components/inspector-controls/block-support-tools-panel.js +74 -65
- package/build/components/inspector-controls/block-support-tools-panel.js.map +7 -1
- package/build/components/inspector-controls/fill.js +71 -74
- package/build/components/inspector-controls/fill.js.map +7 -1
- package/build/components/inspector-controls/groups.js +51 -24
- package/build/components/inspector-controls/groups.js.map +7 -1
- package/build/components/inspector-controls/index.js +48 -34
- package/build/components/inspector-controls/index.js.map +7 -1
- package/build/components/inspector-controls/slot.js +60 -46
- package/build/components/inspector-controls/slot.js.map +7 -1
- package/build/components/inspector-controls-tabs/advanced-controls-panel.js +56 -30
- package/build/components/inspector-controls-tabs/advanced-controls-panel.js.map +7 -1
- package/build/components/inspector-controls-tabs/content-tab.js +39 -28
- package/build/components/inspector-controls-tabs/content-tab.js.map +7 -1
- package/build/components/inspector-controls-tabs/index.js +86 -97
- package/build/components/inspector-controls-tabs/index.js.map +7 -1
- package/build/components/inspector-controls-tabs/position-controls-panel.js +90 -73
- package/build/components/inspector-controls-tabs/position-controls-panel.js.map +7 -1
- package/build/components/inspector-controls-tabs/settings-tab.js +43 -24
- package/build/components/inspector-controls-tabs/settings-tab.js.map +7 -1
- package/build/components/inspector-controls-tabs/styles-tab.js +83 -56
- package/build/components/inspector-controls-tabs/styles-tab.js.map +7 -1
- package/build/components/inspector-controls-tabs/use-inspector-controls-tabs.js +67 -51
- package/build/components/inspector-controls-tabs/use-inspector-controls-tabs.js.map +7 -1
- package/build/components/inspector-controls-tabs/use-is-list-view-tab-disabled.js +30 -11
- package/build/components/inspector-controls-tabs/use-is-list-view-tab-disabled.js.map +7 -1
- package/build/components/inspector-controls-tabs/utils.js +54 -31
- package/build/components/inspector-controls-tabs/utils.js.map +7 -1
- package/build/components/inspector-popover-header/index.js +64 -46
- package/build/components/inspector-popover-header/index.js.map +7 -1
- package/build/components/justify-content-control/index.js +44 -28
- package/build/components/justify-content-control/index.js.map +7 -1
- package/build/components/justify-content-control/ui.js +86 -67
- package/build/components/justify-content-control/ui.js.map +7 -1
- package/build/components/keyboard-shortcuts/index.js +136 -107
- package/build/components/keyboard-shortcuts/index.js.map +7 -1
- package/build/components/letter-spacing-control/index.js +65 -55
- package/build/components/letter-spacing-control/index.js.map +7 -1
- package/build/components/line-height-control/index.js +75 -84
- package/build/components/line-height-control/index.js.map +7 -1
- package/build/components/line-height-control/utils.js +39 -33
- package/build/components/line-height-control/utils.js.map +7 -1
- package/build/components/link-control/constants.js +56 -23
- package/build/components/link-control/constants.js.map +7 -1
- package/build/components/link-control/index.js +336 -323
- package/build/components/link-control/index.js.map +7 -1
- package/build/components/link-control/is-url-like.js +31 -42
- package/build/components/link-control/is-url-like.js.map +7 -1
- package/build/components/link-control/link-preview.js +147 -140
- package/build/components/link-control/link-preview.js.map +7 -1
- package/build/components/link-control/search-create-button.js +53 -29
- package/build/components/link-control/search-create-button.js.map +7 -1
- package/build/components/link-control/search-input.js +154 -140
- package/build/components/link-control/search-input.js.map +7 -1
- package/build/components/link-control/search-item.js +108 -93
- package/build/components/link-control/search-item.js.map +7 -1
- package/build/components/link-control/search-results.js +100 -73
- package/build/components/link-control/search-results.js.map +7 -1
- package/build/components/link-control/settings-drawer.js +56 -51
- package/build/components/link-control/settings-drawer.js.map +7 -1
- package/build/components/link-control/settings.js +66 -35
- package/build/components/link-control/settings.js.map +7 -1
- package/build/components/link-control/use-create-page.js +44 -42
- package/build/components/link-control/use-create-page.js.map +7 -1
- package/build/components/link-control/use-internal-value.js +56 -35
- package/build/components/link-control/use-internal-value.js.map +7 -1
- package/build/components/link-control/use-rich-url-data.js +38 -38
- package/build/components/link-control/use-rich-url-data.js.map +7 -1
- package/build/components/link-control/use-search-handler.js +97 -87
- package/build/components/link-control/use-search-handler.js.map +7 -1
- package/build/components/link-control/viewer-slot.js +34 -17
- package/build/components/link-control/viewer-slot.js.map +7 -1
- package/build/components/list-view/appender.js +118 -98
- package/build/components/list-view/appender.js.map +7 -1
- package/build/components/list-view/aria-referenced-text.js +28 -32
- package/build/components/list-view/aria-referenced-text.js.map +7 -1
- package/build/components/list-view/block-contents.js +93 -78
- package/build/components/list-view/block-contents.js.map +7 -1
- package/build/components/list-view/block-select-button.js +146 -145
- package/build/components/list-view/block-select-button.js.map +7 -1
- package/build/components/list-view/block.js +386 -386
- package/build/components/list-view/block.js.map +7 -1
- package/build/components/list-view/branch.js +154 -147
- package/build/components/list-view/branch.js.map +7 -1
- package/build/components/list-view/context.js +32 -14
- package/build/components/list-view/context.js.map +7 -1
- package/build/components/list-view/drop-indicator.js +168 -172
- package/build/components/list-view/drop-indicator.js.map +7 -1
- package/build/components/list-view/expander.js +36 -27
- package/build/components/list-view/expander.js.map +7 -1
- package/build/components/list-view/index.js +279 -270
- package/build/components/list-view/index.js.map +7 -1
- package/build/components/list-view/leaf.js +74 -55
- package/build/components/list-view/leaf.js.map +7 -1
- package/build/components/list-view/use-block-selection.js +116 -108
- package/build/components/list-view/use-block-selection.js.map +7 -1
- package/build/components/list-view/use-clipboard-handler.js +71 -78
- package/build/components/list-view/use-clipboard-handler.js.map +7 -1
- package/build/components/list-view/use-list-view-block-indexes.js +26 -13
- package/build/components/list-view/use-list-view-block-indexes.js.map +7 -1
- package/build/components/list-view/use-list-view-client-ids.js +41 -32
- package/build/components/list-view/use-list-view-client-ids.js.map +7 -1
- package/build/components/list-view/use-list-view-collapse-items.js +32 -33
- package/build/components/list-view/use-list-view-collapse-items.js.map +7 -1
- package/build/components/list-view/use-list-view-drop-zone.js +189 -303
- package/build/components/list-view/use-list-view-drop-zone.js.map +7 -1
- package/build/components/list-view/use-list-view-expand-selected-item.js +46 -38
- package/build/components/list-view/use-list-view-expand-selected-item.js.map +7 -1
- package/build/components/list-view/use-list-view-images.js +44 -64
- package/build/components/list-view/use-list-view-images.js.map +7 -1
- package/build/components/list-view/use-list-view-scroll-into-view.js +27 -26
- package/build/components/list-view/use-list-view-scroll-into-view.js.map +7 -1
- package/build/components/list-view/utils.js +72 -120
- package/build/components/list-view/utils.js.map +7 -1
- package/build/components/media-placeholder/index.js +352 -298
- package/build/components/media-placeholder/index.js.map +7 -1
- package/build/components/media-replace-flow/index.js +181 -160
- package/build/components/media-replace-flow/index.js.map +7 -1
- package/build/components/media-upload/check.js +33 -29
- package/build/components/media-upload/check.js.map +7 -1
- package/build/components/media-upload/index.js +24 -22
- package/build/components/media-upload/index.js.map +7 -1
- package/build/components/media-upload-progress/constants.js +42 -11
- package/build/components/media-upload-progress/constants.js.map +7 -1
- package/build/components/multi-selection-inspector/index.js +59 -35
- package/build/components/multi-selection-inspector/index.js.map +7 -1
- package/build/components/navigable-toolbar/index.js +98 -103
- package/build/components/navigable-toolbar/index.js.map +7 -1
- package/build/components/observe-typing/index.js +142 -211
- package/build/components/observe-typing/index.js.map +7 -1
- package/build/components/panel-color-settings/index.js +47 -29
- package/build/components/panel-color-settings/index.js.map +7 -1
- package/build/components/plain-text/index.js +50 -79
- package/build/components/plain-text/index.js.map +7 -1
- package/build/components/preview-options/index.js +35 -13
- package/build/components/preview-options/index.js.map +7 -1
- package/build/components/provider/block-refs-provider.js +36 -27
- package/build/components/provider/block-refs-provider.js.map +7 -1
- package/build/components/provider/index.js +111 -97
- package/build/components/provider/index.js.map +7 -1
- package/build/components/provider/use-block-sync.js +57 -153
- package/build/components/provider/use-block-sync.js.map +7 -1
- package/build/components/provider/use-media-upload-settings.js +33 -24
- package/build/components/provider/use-media-upload-settings.js.map +7 -1
- package/build/components/provider/with-registry-provider.js +47 -43
- package/build/components/provider/with-registry-provider.js.map +7 -1
- package/build/components/publish-date-time-picker/index.js +76 -48
- package/build/components/publish-date-time-picker/index.js.map +7 -1
- package/build/components/recursion-provider/index.js +68 -93
- package/build/components/recursion-provider/index.js.map +7 -1
- package/build/components/resizable-box-popover/index.js +44 -25
- package/build/components/resizable-box-popover/index.js.map +7 -1
- package/build/components/resolution-tool/index.js +67 -43
- package/build/components/resolution-tool/index.js.map +7 -1
- package/build/components/responsive-block-control/index.js +114 -72
- package/build/components/responsive-block-control/index.js.map +7 -1
- package/build/components/responsive-block-control/label.js +40 -26
- package/build/components/responsive-block-control/label.js.map +7 -1
- package/build/components/rich-text/content.js +56 -48
- package/build/components/rich-text/content.js.map +7 -1
- package/build/components/rich-text/event-listeners/before-input-rules.js +45 -61
- package/build/components/rich-text/event-listeners/before-input-rules.js.map +7 -1
- package/build/components/rich-text/event-listeners/delete.js +34 -39
- package/build/components/rich-text/event-listeners/delete.js.map +7 -1
- package/build/components/rich-text/event-listeners/enter.js +43 -46
- package/build/components/rich-text/event-listeners/enter.js.map +7 -1
- package/build/components/rich-text/event-listeners/firefox-compat.js +31 -24
- package/build/components/rich-text/event-listeners/firefox-compat.js.map +7 -1
- package/build/components/rich-text/event-listeners/index.js +80 -40
- package/build/components/rich-text/event-listeners/index.js.map +7 -1
- package/build/components/rich-text/event-listeners/input-events.js +26 -12
- package/build/components/rich-text/event-listeners/input-events.js.map +7 -1
- package/build/components/rich-text/event-listeners/input-rules.js +68 -74
- package/build/components/rich-text/event-listeners/input-rules.js.map +7 -1
- package/build/components/rich-text/event-listeners/insert-replacement-text.js +29 -24
- package/build/components/rich-text/event-listeners/insert-replacement-text.js.map +7 -1
- package/build/components/rich-text/event-listeners/paste-handler.js +59 -72
- package/build/components/rich-text/event-listeners/paste-handler.js.map +7 -1
- package/build/components/rich-text/event-listeners/remove-browser-shortcuts.js +27 -18
- package/build/components/rich-text/event-listeners/remove-browser-shortcuts.js.map +7 -1
- package/build/components/rich-text/event-listeners/shortcuts.js +26 -12
- package/build/components/rich-text/event-listeners/shortcuts.js.map +7 -1
- package/build/components/rich-text/event-listeners/undo-automatic-change.js +32 -31
- package/build/components/rich-text/event-listeners/undo-automatic-change.js.map +7 -1
- package/build/components/rich-text/format-edit.js +72 -57
- package/build/components/rich-text/format-edit.js.map +7 -1
- package/build/components/rich-text/format-toolbar/index.js +79 -61
- package/build/components/rich-text/format-toolbar/index.js.map +7 -1
- package/build/components/rich-text/format-toolbar-container.js +61 -52
- package/build/components/rich-text/format-toolbar-container.js.map +7 -1
- package/build/components/rich-text/get-rich-text-values.js +75 -54
- package/build/components/rich-text/get-rich-text-values.js.map +7 -1
- package/build/components/rich-text/index.js +340 -342
- package/build/components/rich-text/index.js.map +7 -1
- package/build/components/rich-text/input-event.js +32 -22
- package/build/components/rich-text/input-event.js.map +7 -1
- package/build/components/rich-text/multiline.js +104 -76
- package/build/components/rich-text/multiline.js.map +7 -1
- package/build/components/rich-text/native/format-edit.js +44 -30
- package/build/components/rich-text/native/format-edit.js.map +7 -1
- package/build/components/rich-text/native/index.js +24 -7
- package/build/components/rich-text/native/index.js.map +7 -1
- package/build/components/rich-text/native/use-format-types.js +89 -63
- package/build/components/rich-text/native/use-format-types.js.map +7 -1
- package/build/components/rich-text/prevent-event-discovery.js +31 -17
- package/build/components/rich-text/prevent-event-discovery.js.map +7 -1
- package/build/components/rich-text/shortcut.js +34 -25
- package/build/components/rich-text/shortcut.js.map +7 -1
- package/build/components/rich-text/toolbar-button.js +32 -21
- package/build/components/rich-text/toolbar-button.js.map +7 -1
- package/build/components/rich-text/use-format-types.js +127 -90
- package/build/components/rich-text/use-format-types.js.map +7 -1
- package/build/components/rich-text/use-mark-persistent.js +34 -32
- package/build/components/rich-text/use-mark-persistent.js.map +7 -1
- package/build/components/rich-text/utils.js +46 -45
- package/build/components/rich-text/utils.js.map +7 -1
- package/build/components/rich-text/with-deprecations.js +64 -37
- package/build/components/rich-text/with-deprecations.js.map +7 -1
- package/build/components/selection-scroll-into-view/index.js +40 -20
- package/build/components/selection-scroll-into-view/index.js.map +7 -1
- package/build/components/skip-to-selected-block/index.js +46 -33
- package/build/components/skip-to-selected-block/index.js.map +7 -1
- package/build/components/spacing-sizes-control/hooks/use-spacing-sizes.js +56 -39
- package/build/components/spacing-sizes-control/hooks/use-spacing-sizes.js.map +7 -1
- package/build/components/spacing-sizes-control/index.js +91 -113
- package/build/components/spacing-sizes-control/index.js.map +7 -1
- package/build/components/spacing-sizes-control/input-controls/axial.js +61 -38
- package/build/components/spacing-sizes-control/input-controls/axial.js.map +7 -1
- package/build/components/spacing-sizes-control/input-controls/separated.js +57 -32
- package/build/components/spacing-sizes-control/input-controls/separated.js.map +7 -1
- package/build/components/spacing-sizes-control/input-controls/single.js +56 -29
- package/build/components/spacing-sizes-control/input-controls/single.js.map +7 -1
- package/build/components/spacing-sizes-control/input-controls/spacing-input-control.js +239 -276
- package/build/components/spacing-sizes-control/input-controls/spacing-input-control.js.map +7 -1
- package/build/components/spacing-sizes-control/linked-button.js +38 -25
- package/build/components/spacing-sizes-control/linked-button.js.map +7 -1
- package/build/components/spacing-sizes-control/utils.js +112 -180
- package/build/components/spacing-sizes-control/utils.js.map +7 -1
- package/build/components/tabbed-sidebar/index.js +77 -99
- package/build/components/tabbed-sidebar/index.js.map +7 -1
- package/build/components/text-alignment-control/index.js +95 -69
- package/build/components/text-alignment-control/index.js.map +7 -1
- package/build/components/text-decoration-control/index.js +82 -61
- package/build/components/text-decoration-control/index.js.map +7 -1
- package/build/components/text-transform-control/index.js +88 -70
- package/build/components/text-transform-control/index.js.map +7 -1
- package/build/components/typewriter/index.js +173 -211
- package/build/components/typewriter/index.js.map +7 -1
- package/build/components/unit-control/index.js +30 -27
- package/build/components/unit-control/index.js.map +7 -1
- package/build/components/url-input/button.js +93 -74
- package/build/components/url-input/button.js.map +7 -1
- package/build/components/url-input/index.js +211 -247
- package/build/components/url-input/index.js.map +7 -1
- package/build/components/url-popover/image-url-input-ui.js +253 -202
- package/build/components/url-popover/image-url-input-ui.js.map +7 -1
- package/build/components/url-popover/index.js +113 -101
- package/build/components/url-popover/index.js.map +7 -1
- package/build/components/url-popover/link-editor.js +67 -38
- package/build/components/url-popover/link-editor.js.map +7 -1
- package/build/components/url-popover/link-viewer-url.js +43 -32
- package/build/components/url-popover/link-viewer-url.js.map +7 -1
- package/build/components/url-popover/link-viewer.js +67 -38
- package/build/components/url-popover/link-viewer.js.map +7 -1
- package/build/components/use-block-commands/index.js +181 -151
- package/build/components/use-block-commands/index.js.map +7 -1
- package/build/components/use-block-display-information/index.js +74 -105
- package/build/components/use-block-display-information/index.js.map +7 -1
- package/build/components/use-block-drop-zone/index.js +303 -313
- package/build/components/use-block-drop-zone/index.js.map +7 -1
- package/build/components/use-flash-editable-blocks/index.js +66 -52
- package/build/components/use-flash-editable-blocks/index.js.map +7 -1
- package/build/components/use-moving-animation/index.js +66 -111
- package/build/components/use-moving-animation/index.js.map +7 -1
- package/build/components/use-on-block-drop/index.js +201 -180
- package/build/components/use-on-block-drop/index.js.map +7 -1
- package/build/components/use-on-block-drop/types.js +16 -5
- package/build/components/use-on-block-drop/types.js.map +7 -1
- package/build/components/use-paste-styles/index.js +144 -142
- package/build/components/use-paste-styles/index.js.map +7 -1
- package/build/components/use-resize-canvas/index.js +38 -32
- package/build/components/use-resize-canvas/index.js.map +7 -1
- package/build/components/use-settings/index.js +55 -57
- package/build/components/use-settings/index.js.map +7 -1
- package/build/components/warning/index.js +73 -65
- package/build/components/warning/index.js.map +7 -1
- package/build/components/writing-flow/index.js +111 -72
- package/build/components/writing-flow/index.js.map +7 -1
- package/build/components/writing-flow/use-arrow-nav.js +115 -153
- package/build/components/writing-flow/use-arrow-nav.js.map +7 -1
- package/build/components/writing-flow/use-click-selection.js +55 -55
- package/build/components/writing-flow/use-click-selection.js.map +7 -1
- package/build/components/writing-flow/use-clipboard-handler.js +83 -87
- package/build/components/writing-flow/use-clipboard-handler.js.map +7 -1
- package/build/components/writing-flow/use-drag-selection.js +99 -149
- package/build/components/writing-flow/use-drag-selection.js.map +7 -1
- package/build/components/writing-flow/use-input.js +72 -62
- package/build/components/writing-flow/use-input.js.map +7 -1
- package/build/components/writing-flow/use-multi-selection.js +57 -61
- package/build/components/writing-flow/use-multi-selection.js.map +7 -1
- package/build/components/writing-flow/use-select-all.js +39 -37
- package/build/components/writing-flow/use-select-all.js.map +7 -1
- package/build/components/writing-flow/use-selection-observer.js +136 -188
- package/build/components/writing-flow/use-selection-observer.js.map +7 -1
- package/build/components/writing-flow/use-tab-nav.js +97 -147
- package/build/components/writing-flow/use-tab-nav.js.map +7 -1
- package/build/components/writing-flow/utils.js +59 -71
- package/build/components/writing-flow/utils.js.map +7 -1
- package/build/components/writing-mode-control/index.js +75 -62
- package/build/components/writing-mode-control/index.js.map +7 -1
- package/build/elements/index.js +30 -10
- package/build/elements/index.js.map +7 -1
- package/build/hooks/align.js +102 -133
- package/build/hooks/align.js.map +7 -1
- package/build/hooks/allowed-blocks.js +84 -0
- package/build/hooks/allowed-blocks.js.map +7 -0
- package/build/hooks/anchor.js +81 -88
- package/build/hooks/anchor.js.map +7 -1
- package/build/hooks/aria-label.js +43 -43
- package/build/hooks/aria-label.js.map +7 -1
- package/build/hooks/background.js +112 -112
- package/build/hooks/background.js.map +7 -1
- package/build/hooks/block-bindings.js +394 -253
- package/build/hooks/block-bindings.js.map +7 -1
- package/build/hooks/block-hooks.js +171 -163
- package/build/hooks/block-hooks.js.map +7 -1
- package/build/hooks/block-renaming.js +41 -32
- package/build/hooks/block-renaming.js.map +7 -1
- package/build/hooks/block-style-variation.js +152 -180
- package/build/hooks/block-style-variation.js.map +7 -1
- package/build/hooks/border.js +183 -254
- package/build/hooks/border.js.map +7 -1
- package/build/hooks/color.js +216 -195
- package/build/hooks/color.js.map +7 -1
- package/build/hooks/compat.js +10 -13
- package/build/hooks/compat.js.map +7 -1
- package/build/hooks/content-lock-ui.js +51 -58
- package/build/hooks/content-lock-ui.js.map +7 -1
- package/build/hooks/contrast-checker.js +67 -46
- package/build/hooks/contrast-checker.js.map +7 -1
- package/build/hooks/custom-class-name.js +84 -87
- package/build/hooks/custom-class-name.js.map +7 -1
- package/build/hooks/dimensions.js +153 -141
- package/build/hooks/dimensions.js.map +7 -1
- package/build/hooks/duotone.js +173 -194
- package/build/hooks/duotone.js.map +7 -1
- package/build/hooks/fit-text.js +206 -0
- package/build/hooks/fit-text.js.map +7 -0
- package/build/hooks/font-family.js +70 -78
- package/build/hooks/font-family.js.map +7 -1
- package/build/hooks/font-size.js +134 -127
- package/build/hooks/font-size.js.map +7 -1
- package/build/hooks/gap.js +33 -31
- package/build/hooks/gap.js.map +7 -1
- package/build/hooks/generated-class-name.js +42 -32
- package/build/hooks/generated-class-name.js.map +7 -1
- package/build/hooks/grid-visualizer.js +51 -60
- package/build/hooks/grid-visualizer.js.map +7 -1
- package/build/hooks/index.js +157 -147
- package/build/hooks/index.js.map +7 -1
- package/build/hooks/layout-child.js +128 -141
- package/build/hooks/layout-child.js.map +7 -1
- package/build/hooks/layout.js +260 -295
- package/build/hooks/layout.js.map +7 -1
- package/build/hooks/line-height.js +61 -55
- package/build/hooks/line-height.js.map +7 -1
- package/build/hooks/lock.js +30 -23
- package/build/hooks/lock.js.map +7 -1
- package/build/hooks/metadata.js +34 -23
- package/build/hooks/metadata.js.map +7 -1
- package/build/hooks/position.js +169 -240
- package/build/hooks/position.js.map +7 -1
- package/build/hooks/settings.js +10 -13
- package/build/hooks/settings.js.map +7 -1
- package/build/hooks/spacing-visualizer.js +108 -88
- package/build/hooks/spacing-visualizer.js.map +7 -1
- package/build/hooks/style.js +157 -281
- package/build/hooks/style.js.map +7 -1
- package/build/hooks/supports.js +145 -288
- package/build/hooks/supports.js.map +7 -1
- package/build/hooks/text-align.js +110 -101
- package/build/hooks/text-align.js.map +7 -1
- package/build/hooks/typography.js +139 -107
- package/build/hooks/typography.js.map +7 -1
- package/build/hooks/use-border-props.js +47 -52
- package/build/hooks/use-border-props.js.map +7 -1
- package/build/hooks/use-cached-truthy.js +29 -18
- package/build/hooks/use-cached-truthy.js.map +7 -1
- package/build/hooks/use-color-props.js +101 -89
- package/build/hooks/use-color-props.js.map +7 -1
- package/build/hooks/use-shadow-props.js +29 -25
- package/build/hooks/use-shadow-props.js.map +7 -1
- package/build/hooks/use-spacing-props.js +29 -30
- package/build/hooks/use-spacing-props.js.map +7 -1
- package/build/hooks/use-typography-props.js +55 -51
- package/build/hooks/use-typography-props.js.map +7 -1
- package/build/hooks/use-zoom-out.js +40 -56
- package/build/hooks/use-zoom-out.js.map +7 -1
- package/build/hooks/utils.js +421 -251
- package/build/hooks/utils.js.map +7 -1
- package/build/index.js +65 -150
- package/build/index.js.map +7 -1
- package/build/layouts/constrained.js +211 -211
- package/build/layouts/constrained.js.map +7 -1
- package/build/layouts/definitions.js +188 -144
- package/build/layouts/definitions.js.map +7 -1
- package/build/layouts/flex.js +250 -239
- package/build/layouts/flex.js.map +7 -1
- package/build/layouts/flow.js +59 -61
- package/build/layouts/flow.js.map +7 -1
- package/build/layouts/grid.js +247 -249
- package/build/layouts/grid.js.map +7 -1
- package/build/layouts/index.js +45 -31
- package/build/layouts/index.js.map +7 -1
- package/build/layouts/utils.js +51 -70
- package/build/layouts/utils.js.map +7 -1
- package/build/lock-unlock.js +31 -14
- package/build/lock-unlock.js.map +7 -1
- package/build/private-apis.js +119 -97
- package/build/private-apis.js.map +7 -1
- package/build/store/actions.js +620 -1283
- package/build/store/actions.js.map +7 -1
- package/build/store/array.js +38 -28
- package/build/store/array.js.map +7 -1
- package/build/store/constants.js +27 -6
- package/build/store/constants.js.map +7 -1
- package/build/store/defaults.js +191 -202
- package/build/store/defaults.js.map +7 -1
- package/build/store/get-block-settings.js +105 -96
- package/build/store/get-block-settings.js.map +7 -1
- package/build/store/index.js +56 -56
- package/build/store/index.js.map +7 -1
- package/build/store/private-actions.js +158 -323
- package/build/store/private-actions.js.map +7 -1
- package/build/store/private-keys.js +45 -12
- package/build/store/private-keys.js.map +7 -1
- package/build/store/private-selectors.js +298 -468
- package/build/store/private-selectors.js.map +7 -1
- package/build/store/reducer.js +1142 -1819
- package/build/store/reducer.js.map +7 -1
- package/build/store/selectors.js +1191 -2198
- package/build/store/selectors.js.map +7 -1
- package/build/store/utils.js +87 -54
- package/build/store/utils.js.map +7 -1
- package/build/utils/block-bindings.js +46 -179
- package/build/utils/block-bindings.js.map +7 -1
- package/build/utils/dom.js +58 -105
- package/build/utils/dom.js.map +7 -1
- package/build/utils/fit-text-frontend.js +41 -0
- package/build/utils/fit-text-frontend.js.map +7 -0
- package/build/utils/fit-text-utils.js +63 -0
- package/build/utils/fit-text-utils.js.map +7 -0
- package/build/utils/format-font-style.js +35 -27
- package/build/utils/format-font-style.js.map +7 -1
- package/build/utils/format-font-weight.js +51 -43
- package/build/utils/format-font-weight.js.map +7 -1
- package/build/utils/get-editor-region.js +27 -25
- package/build/utils/get-editor-region.js.map +7 -1
- package/build/utils/get-font-styles-and-weights.js +113 -107
- package/build/utils/get-font-styles-and-weights.js.map +7 -1
- package/build/utils/get-px-from-css-unit.js +23 -14
- package/build/utils/get-px-from-css-unit.js.map +7 -1
- package/build/utils/index.js +41 -24
- package/build/utils/index.js.map +7 -1
- package/build/utils/math.js +40 -82
- package/build/utils/math.js.map +7 -1
- package/build/utils/object.js +37 -57
- package/build/utils/object.js.map +7 -1
- package/build/utils/order-inserter-block-items.js +27 -22
- package/build/utils/order-inserter-block-items.js.map +7 -1
- package/build/utils/pasting.js +41 -85
- package/build/utils/pasting.js.map +7 -1
- package/build/utils/selection.js +35 -29
- package/build/utils/selection.js.map +7 -1
- package/build/utils/sorting.js +32 -33
- package/build/utils/sorting.js.map +7 -1
- package/build/utils/transform-styles/index.js +101 -145
- package/build/utils/transform-styles/index.js.map +7 -1
- package/build/utils/use-notify-copy.js +81 -55
- package/build/utils/use-notify-copy.js.map +7 -1
- package/build-module/autocompleters/block.js +92 -79
- package/build-module/autocompleters/block.js.map +7 -1
- package/build-module/autocompleters/link.js +29 -41
- package/build-module/autocompleters/link.js.map +7 -1
- package/build-module/components/alignment-control/index.js +11 -21
- package/build-module/components/alignment-control/index.js.map +7 -1
- package/build-module/components/alignment-control/ui.js +52 -47
- package/build-module/components/alignment-control/ui.js.map +7 -1
- package/build-module/components/autocomplete/index.js +31 -53
- package/build-module/components/autocomplete/index.js.map +7 -1
- package/build-module/components/background-image-control/index.js +471 -432
- package/build-module/components/background-image-control/index.js.map +7 -1
- package/build-module/components/block-actions/index.js +51 -55
- package/build-module/components/block-actions/index.js.map +7 -1
- package/build-module/components/block-alignment-control/constants.js +22 -14
- package/build-module/components/block-alignment-control/constants.js.map +7 -1
- package/build-module/components/block-alignment-control/index.js +11 -21
- package/build-module/components/block-alignment-control/index.js.map +7 -1
- package/build-module/components/block-alignment-control/ui.js +47 -60
- package/build-module/components/block-alignment-control/ui.js.map +7 -1
- package/build-module/components/block-alignment-control/use-available-alignments.js +41 -48
- package/build-module/components/block-alignment-control/use-available-alignments.js.map +7 -1
- package/build-module/components/block-alignment-matrix-control/index.js +52 -77
- package/build-module/components/block-alignment-matrix-control/index.js.map +7 -1
- package/build-module/components/block-allowed-blocks/allowed-blocks-control.js +69 -0
- package/build-module/components/block-allowed-blocks/allowed-blocks-control.js.map +7 -0
- package/build-module/components/block-allowed-blocks/index.js +7 -0
- package/build-module/components/block-allowed-blocks/index.js.map +7 -0
- package/build-module/components/block-allowed-blocks/modal.js +101 -0
- package/build-module/components/block-allowed-blocks/modal.js.map +7 -0
- package/build-module/components/block-breadcrumb/index.js +94 -96
- package/build-module/components/block-breadcrumb/index.js.map +7 -1
- package/build-module/components/block-canvas/index.js +85 -113
- package/build-module/components/block-canvas/index.js.map +7 -1
- package/build-module/components/block-card/index.js +67 -115
- package/build-module/components/block-card/index.js.map +7 -1
- package/build-module/components/block-compare/block-view.js +21 -31
- package/build-module/components/block-compare/block-view.js.map +7 -1
- package/build-module/components/block-compare/index.js +44 -52
- package/build-module/components/block-compare/index.js.map +7 -1
- package/build-module/components/block-content-overlay/index.js +14 -17
- package/build-module/components/block-content-overlay/index.js.map +7 -1
- package/build-module/components/block-context/index.js +15 -40
- package/build-module/components/block-context/index.js.map +7 -1
- package/build-module/components/block-controls/fill.js +27 -35
- package/build-module/components/block-controls/fill.js.map +7 -1
- package/build-module/components/block-controls/groups.js +11 -11
- package/build-module/components/block-controls/groups.js.map +7 -1
- package/build-module/components/block-controls/hook.js +11 -11
- package/build-module/components/block-controls/hook.js.map +7 -1
- package/build-module/components/block-controls/index.js +13 -20
- package/build-module/components/block-controls/index.js.map +7 -1
- package/build-module/components/block-controls/slot.js +31 -41
- package/build-module/components/block-controls/slot.js.map +7 -1
- package/build-module/components/block-draggable/draggable-chip.js +32 -39
- package/build-module/components/block-draggable/draggable-chip.js.map +7 -1
- package/build-module/components/block-draggable/index.js +131 -134
- package/build-module/components/block-draggable/index.js.map +7 -1
- package/build-module/components/block-draggable/use-scroll-when-dragging.js +36 -38
- package/build-module/components/block-draggable/use-scroll-when-dragging.js.map +7 -1
- package/build-module/components/block-edit/context.js +22 -24
- package/build-module/components/block-edit/context.js.map +7 -1
- package/build-module/components/block-edit/edit.js +205 -186
- package/build-module/components/block-edit/edit.js.map +7 -1
- package/build-module/components/block-edit/index.js +70 -64
- package/build-module/components/block-edit/index.js.map +7 -1
- package/build-module/components/block-edit/multiple-usage-warning.js +47 -35
- package/build-module/components/block-edit/multiple-usage-warning.js.map +7 -1
- package/build-module/components/block-edit-visually-button/index.js +22 -27
- package/build-module/components/block-edit-visually-button/index.js.map +7 -1
- package/build-module/components/block-editing-mode/index.js +21 -58
- package/build-module/components/block-editing-mode/index.js.map +7 -1
- package/build-module/components/block-full-height-alignment-control/index.js +20 -17
- package/build-module/components/block-full-height-alignment-control/index.js.map +7 -1
- package/build-module/components/block-heading-level-dropdown/heading-level-icon.js +17 -31
- package/build-module/components/block-heading-level-dropdown/heading-level-icon.js.map +7 -1
- package/build-module/components/block-heading-level-dropdown/index.js +37 -60
- package/build-module/components/block-heading-level-dropdown/index.js.map +7 -1
- package/build-module/components/block-icon/index.js +23 -36
- package/build-module/components/block-icon/index.js.map +7 -1
- package/build-module/components/block-inspector/edit-contents-button.js +35 -43
- package/build-module/components/block-inspector/edit-contents-button.js.map +7 -1
- package/build-module/components/block-inspector/index.js +208 -189
- package/build-module/components/block-inspector/index.js.map +7 -1
- package/build-module/components/block-inspector/useBlockInspectorAnimationSettings.js +27 -34
- package/build-module/components/block-inspector/useBlockInspectorAnimationSettings.js.map +7 -1
- package/build-module/components/block-list/block-crash-boundary.js +6 -6
- package/build-module/components/block-list/block-crash-boundary.js.map +7 -1
- package/build-module/components/block-list/block-crash-warning.js +9 -16
- package/build-module/components/block-list/block-crash-warning.js.map +7 -1
- package/build-module/components/block-list/block-html.js +38 -38
- package/build-module/components/block-list/block-html.js.map +7 -1
- package/build-module/components/block-list/block-invalid-warning.js +123 -99
- package/build-module/components/block-list/block-invalid-warning.js.map +7 -1
- package/build-module/components/block-list/block.js +335 -403
- package/build-module/components/block-list/block.js.map +7 -1
- package/build-module/components/block-list/index.js +187 -167
- package/build-module/components/block-list/index.js.map +7 -1
- package/build-module/components/block-list/layout.js +19 -38
- package/build-module/components/block-list/layout.js.map +7 -1
- package/build-module/components/block-list/private-block-context.js +7 -7
- package/build-module/components/block-list/private-block-context.js.map +7 -1
- package/build-module/components/block-list/subdirectory-icon.js +25 -21
- package/build-module/components/block-list/subdirectory-icon.js.map +7 -1
- package/build-module/components/block-list/use-block-props/index.js +84 -139
- package/build-module/components/block-list/use-block-props/index.js.map +7 -1
- package/build-module/components/block-list/use-block-props/use-block-refs.js +26 -54
- package/build-module/components/block-list/use-block-props/use-block-refs.js.map +7 -1
- package/build-module/components/block-list/use-block-props/use-firefox-draggable-compatibility.js +21 -43
- package/build-module/components/block-list/use-block-props/use-firefox-draggable-compatibility.js.map +7 -1
- package/build-module/components/block-list/use-block-props/use-focus-first-element.js +23 -51
- package/build-module/components/block-list/use-block-props/use-focus-first-element.js.map +7 -1
- package/build-module/components/block-list/use-block-props/use-focus-handler.js +33 -62
- package/build-module/components/block-list/use-block-props/use-focus-handler.js.map +7 -1
- package/build-module/components/block-list/use-block-props/use-intersection-observer.js +19 -20
- package/build-module/components/block-list/use-block-props/use-intersection-observer.js.map +7 -1
- package/build-module/components/block-list/use-block-props/use-is-hovered.js +16 -20
- package/build-module/components/block-list/use-block-props/use-is-hovered.js.map +7 -1
- package/build-module/components/block-list/use-block-props/use-scroll-into-view.js +31 -34
- package/build-module/components/block-list/use-block-props/use-scroll-into-view.js.map +7 -1
- package/build-module/components/block-list/use-block-props/use-selected-block-event-handlers.js +182 -167
- package/build-module/components/block-list/use-block-props/use-selected-block-event-handlers.js.map +7 -1
- package/build-module/components/block-list/use-in-between-inserter.js +99 -107
- package/build-module/components/block-list/use-in-between-inserter.js.map +7 -1
- package/build-module/components/block-list/zoom-out-separator.js +54 -72
- package/build-module/components/block-list/zoom-out-separator.js.map +7 -1
- package/build-module/components/block-list-appender/index.js +52 -81
- package/build-module/components/block-list-appender/index.js.map +7 -1
- package/build-module/components/block-lock/index.js +11 -5
- package/build-module/components/block-lock/index.js.map +7 -1
- package/build-module/components/block-lock/menu-item.js +31 -36
- package/build-module/components/block-lock/menu-item.js.map +7 -1
- package/build-module/components/block-lock/modal.js +211 -176
- package/build-module/components/block-lock/modal.js.map +7 -1
- package/build-module/components/block-lock/toolbar.js +28 -42
- package/build-module/components/block-lock/toolbar.js.map +7 -1
- package/build-module/components/block-lock/use-block-lock.js +31 -40
- package/build-module/components/block-lock/use-block-lock.js.map +7 -1
- package/build-module/components/block-manager/category.js +82 -58
- package/build-module/components/block-manager/category.js.map +7 -1
- package/build-module/components/block-manager/checklist.js +27 -30
- package/build-module/components/block-manager/checklist.js.map +7 -1
- package/build-module/components/block-manager/index.js +95 -83
- package/build-module/components/block-manager/index.js.map +7 -1
- package/build-module/components/block-mover/button.js +124 -124
- package/build-module/components/block-mover/button.js.map +7 -1
- package/build-module/components/block-mover/index.js +83 -90
- package/build-module/components/block-mover/index.js.map +7 -1
- package/build-module/components/block-mover/mover-description.js +191 -134
- package/build-module/components/block-mover/mover-description.js.map +7 -1
- package/build-module/components/block-navigation/dropdown.js +58 -66
- package/build-module/components/block-navigation/dropdown.js.map +7 -1
- package/build-module/components/block-parent-selector/index.js +41 -51
- package/build-module/components/block-parent-selector/index.js.map +7 -1
- package/build-module/components/block-pattern-setup/constants.js +7 -4
- package/build-module/components/block-pattern-setup/constants.js.map +7 -1
- package/build-module/components/block-pattern-setup/index.js +142 -136
- package/build-module/components/block-pattern-setup/index.js.map +7 -1
- package/build-module/components/block-pattern-setup/setup-toolbar.js +80 -67
- package/build-module/components/block-pattern-setup/setup-toolbar.js.map +7 -1
- package/build-module/components/block-pattern-setup/use-patterns-setup.js +24 -23
- package/build-module/components/block-pattern-setup/use-patterns-setup.js.map +7 -1
- package/build-module/components/block-patterns-list/index.js +160 -152
- package/build-module/components/block-patterns-list/index.js.map +7 -1
- package/build-module/components/block-patterns-paging/index.js +107 -80
- package/build-module/components/block-patterns-paging/index.js.map +7 -1
- package/build-module/components/block-popover/cover.js +31 -35
- package/build-module/components/block-popover/cover.js.map +7 -1
- package/build-module/components/block-popover/drop-zone.js +35 -47
- package/build-module/components/block-popover/drop-zone.js.map +7 -1
- package/build-module/components/block-popover/inbetween.js +90 -118
- package/build-module/components/block-popover/inbetween.js.map +7 -1
- package/build-module/components/block-popover/index.js +84 -83
- package/build-module/components/block-popover/index.js.map +7 -1
- package/build-module/components/block-popover/use-popover-scroll.js +30 -48
- package/build-module/components/block-popover/use-popover-scroll.js.map +7 -1
- package/build-module/components/block-preview/async.js +7 -26
- package/build-module/components/block-preview/async.js.map +7 -1
- package/build-module/components/block-preview/auto.js +84 -96
- package/build-module/components/block-preview/auto.js.map +7 -1
- package/build-module/components/block-preview/index.js +100 -106
- package/build-module/components/block-preview/index.js.map +7 -1
- package/build-module/components/block-quick-navigation/index.js +59 -68
- package/build-module/components/block-quick-navigation/index.js.map +7 -1
- package/build-module/components/block-removal-warning-modal/index.js +56 -48
- package/build-module/components/block-removal-warning-modal/index.js.map +7 -1
- package/build-module/components/block-rename/index.js +9 -4
- package/build-module/components/block-rename/index.js.map +7 -1
- package/build-module/components/block-rename/is-empty-string.js +5 -2
- package/build-module/components/block-rename/is-empty-string.js.map +7 -1
- package/build-module/components/block-rename/modal.js +110 -94
- package/build-module/components/block-rename/modal.js.map +7 -1
- package/build-module/components/block-rename/rename-control.js +30 -29
- package/build-module/components/block-rename/rename-control.js.map +7 -1
- package/build-module/components/block-rename/use-block-rename.js +7 -7
- package/build-module/components/block-rename/use-block-rename.js.map +7 -1
- package/build-module/components/block-selection-clearer/index.js +33 -54
- package/build-module/components/block-selection-clearer/index.js.map +7 -1
- package/build-module/components/block-settings-menu/block-html-convert-button.js +28 -29
- package/build-module/components/block-settings-menu/block-html-convert-button.js.map +7 -1
- package/build-module/components/block-settings-menu/block-mode-toggle.js +38 -48
- package/build-module/components/block-settings-menu/block-mode-toggle.js.map +7 -1
- package/build-module/components/block-settings-menu/block-parent-selector-menu-item.js +30 -35
- package/build-module/components/block-settings-menu/block-parent-selector-menu-item.js.map +7 -1
- package/build-module/components/block-settings-menu/block-settings-dropdown.js +259 -226
- package/build-module/components/block-settings-menu/block-settings-dropdown.js.map +7 -1
- package/build-module/components/block-settings-menu/block-settings-menu-first-item.js +9 -10
- package/build-module/components/block-settings-menu/block-settings-menu-first-item.js.map +7 -1
- package/build-module/components/block-settings-menu/index.js +21 -25
- package/build-module/components/block-settings-menu/index.js.map +7 -1
- package/build-module/components/block-settings-menu-controls/index.js +107 -100
- package/build-module/components/block-settings-menu-controls/index.js.map +7 -1
- package/build-module/components/block-styles/index.js +72 -66
- package/build-module/components/block-styles/index.js.map +7 -1
- package/build-module/components/block-styles/menu-items.js +31 -36
- package/build-module/components/block-styles/menu-items.js.map +7 -1
- package/build-module/components/block-styles/preview-panel.js +12 -18
- package/build-module/components/block-styles/preview-panel.js.map +7 -1
- package/build-module/components/block-styles/use-styles-for-block.js +35 -61
- package/build-module/components/block-styles/use-styles-for-block.js.map +7 -1
- package/build-module/components/block-styles/utils.js +28 -60
- package/build-module/components/block-styles/utils.js.map +7 -1
- package/build-module/components/block-switcher/block-styles-menu.js +18 -27
- package/build-module/components/block-switcher/block-styles-menu.js.map +7 -1
- package/build-module/components/block-switcher/block-transformations-menu.js +109 -119
- package/build-module/components/block-switcher/block-transformations-menu.js.map +7 -1
- package/build-module/components/block-switcher/block-variation-transformations.js +83 -76
- package/build-module/components/block-switcher/block-variation-transformations.js.map +7 -1
- package/build-module/components/block-switcher/index.js +223 -197
- package/build-module/components/block-switcher/index.js.map +7 -1
- package/build-module/components/block-switcher/pattern-transformations-menu.js +105 -91
- package/build-module/components/block-switcher/pattern-transformations-menu.js.map +7 -1
- package/build-module/components/block-switcher/preview-block-popover.js +20 -32
- package/build-module/components/block-switcher/preview-block-popover.js.map +7 -1
- package/build-module/components/block-switcher/use-transformed-patterns.js +41 -76
- package/build-module/components/block-switcher/use-transformed-patterns.js.map +7 -1
- package/build-module/components/block-switcher/utils.js +15 -40
- package/build-module/components/block-switcher/utils.js.map +7 -1
- package/build-module/components/block-title/index.js +7 -34
- package/build-module/components/block-title/index.js.map +7 -1
- package/build-module/components/block-title/use-block-display-title.js +34 -57
- package/build-module/components/block-title/use-block-display-title.js.map +7 -1
- package/build-module/components/block-toolbar/block-name-context.js +8 -8
- package/build-module/components/block-toolbar/block-name-context.js.map +7 -1
- package/build-module/components/block-toolbar/block-toolbar-last-item.js +9 -10
- package/build-module/components/block-toolbar/block-toolbar-last-item.js.map +7 -1
- package/build-module/components/block-toolbar/change-design.js +79 -84
- package/build-module/components/block-toolbar/change-design.js.map +7 -1
- package/build-module/components/block-toolbar/index.js +169 -173
- package/build-module/components/block-toolbar/index.js.map +7 -1
- package/build-module/components/block-toolbar/switch-section-style.js +89 -82
- package/build-module/components/block-toolbar/switch-section-style.js.map +7 -1
- package/build-module/components/block-toolbar/use-has-block-toolbar.js +11 -28
- package/build-module/components/block-toolbar/use-has-block-toolbar.js.map +7 -1
- package/build-module/components/block-toolbar/utils.js +38 -71
- package/build-module/components/block-toolbar/utils.js.map +7 -1
- package/build-module/components/block-tools/block-toolbar-popover.js +43 -60
- package/build-module/components/block-tools/block-toolbar-popover.js.map +7 -1
- package/build-module/components/block-tools/empty-block-inserter.js +35 -33
- package/build-module/components/block-tools/empty-block-inserter.js.map +7 -1
- package/build-module/components/block-tools/index.js +139 -103
- package/build-module/components/block-tools/index.js.map +7 -1
- package/build-module/components/block-tools/insertion-point.js +144 -149
- package/build-module/components/block-tools/insertion-point.js.map +7 -1
- package/build-module/components/block-tools/use-block-toolbar-popover-props.js +55 -90
- package/build-module/components/block-tools/use-block-toolbar-popover-props.js.map +7 -1
- package/build-module/components/block-tools/use-selected-block-tool-props.js +41 -48
- package/build-module/components/block-tools/use-selected-block-tool-props.js.map +7 -1
- package/build-module/components/block-tools/use-show-block-tools.js +12 -27
- package/build-module/components/block-tools/use-show-block-tools.js.map +7 -1
- package/build-module/components/block-tools/zoom-out-mode-inserter-button.js +28 -25
- package/build-module/components/block-tools/zoom-out-mode-inserter-button.js.map +7 -1
- package/build-module/components/block-tools/zoom-out-mode-inserters.js +40 -45
- package/build-module/components/block-tools/zoom-out-mode-inserters.js.map +7 -1
- package/build-module/components/block-types-list/index.js +28 -28
- package/build-module/components/block-types-list/index.js.map +7 -1
- package/build-module/components/block-variation-picker/index.js +57 -51
- package/build-module/components/block-variation-picker/index.js.map +7 -1
- package/build-module/components/block-variation-transforms/index.js +134 -133
- package/build-module/components/block-variation-transforms/index.js.map +7 -1
- package/build-module/components/block-vertical-alignment-control/index.js +11 -21
- package/build-module/components/block-vertical-alignment-control/index.js.map +7 -1
- package/build-module/components/block-vertical-alignment-control/ui.js +44 -38
- package/build-module/components/block-vertical-alignment-control/ui.js.map +7 -1
- package/build-module/components/block-visibility/index.js +7 -3
- package/build-module/components/block-visibility/index.js.map +7 -1
- package/build-module/components/block-visibility/menu-item.js +81 -39
- package/build-module/components/block-visibility/menu-item.js.map +7 -1
- package/build-module/components/block-visibility/toolbar.js +55 -66
- package/build-module/components/block-visibility/toolbar.js.map +7 -1
- package/build-module/components/border-radius-control/constants.js +34 -22
- package/build-module/components/border-radius-control/constants.js.map +7 -1
- package/build-module/components/border-radius-control/index.js +81 -84
- package/build-module/components/border-radius-control/index.js.map +7 -1
- package/build-module/components/border-radius-control/linked-button.js +21 -21
- package/build-module/components/border-radius-control/linked-button.js.map +7 -1
- package/build-module/components/border-radius-control/single-input-control.js +168 -126
- package/build-module/components/border-radius-control/single-input-control.js.map +7 -1
- package/build-module/components/border-radius-control/utils.js +66 -178
- package/build-module/components/border-radius-control/utils.js.map +7 -1
- package/build-module/components/button-block-appender/index.js +72 -83
- package/build-module/components/button-block-appender/index.js.map +7 -1
- package/build-module/components/child-layout-control/index.js +305 -266
- package/build-module/components/child-layout-control/index.js.map +7 -1
- package/build-module/components/collab/block-comment-icon-slot.js +7 -7
- package/build-module/components/collab/block-comment-icon-slot.js.map +7 -1
- package/build-module/components/collab/block-comment-icon-toolbar-slot.js +9 -7
- package/build-module/components/collab/block-comment-icon-toolbar-slot.js.map +7 -1
- package/build-module/components/color-palette/control.js +17 -14
- package/build-module/components/color-palette/control.js.map +7 -1
- package/build-module/components/color-palette/index.js +7 -11
- package/build-module/components/color-palette/index.js.map +7 -1
- package/build-module/components/color-palette/with-color-context.js +40 -27
- package/build-module/components/color-palette/with-color-context.js.map +7 -1
- package/build-module/components/color-style-selector/index.js +48 -82
- package/build-module/components/color-style-selector/index.js.map +7 -1
- package/build-module/components/colors/index.js +14 -3
- package/build-module/components/colors/index.js.map +7 -1
- package/build-module/components/colors/utils.js +24 -73
- package/build-module/components/colors/utils.js.map +7 -1
- package/build-module/components/colors/with-colors.js +140 -188
- package/build-module/components/colors/with-colors.js.map +7 -1
- package/build-module/components/colors-gradients/control.js +118 -111
- package/build-module/components/colors-gradients/control.js.map +7 -1
- package/build-module/components/colors-gradients/dropdown.js +134 -155
- package/build-module/components/colors-gradients/dropdown.js.map +7 -1
- package/build-module/components/colors-gradients/panel-color-gradient-settings.js +90 -75
- package/build-module/components/colors-gradients/panel-color-gradient-settings.js.map +7 -1
- package/build-module/components/colors-gradients/use-multiple-origin-colors-and-gradients.js +73 -36
- package/build-module/components/colors-gradients/use-multiple-origin-colors-and-gradients.js.map +7 -1
- package/build-module/components/content-lock/index.js +5 -2
- package/build-module/components/content-lock/index.js.map +7 -1
- package/build-module/components/content-lock/modify-content-lock-menu-item.js +38 -51
- package/build-module/components/content-lock/modify-content-lock-menu-item.js.map +7 -1
- package/build-module/components/contrast-checker/index.js +54 -62
- package/build-module/components/contrast-checker/index.js.map +7 -1
- package/build-module/components/convert-to-group-buttons/index.js +53 -44
- package/build-module/components/convert-to-group-buttons/index.js.map +7 -1
- package/build-module/components/convert-to-group-buttons/toolbar.js +86 -97
- package/build-module/components/convert-to-group-buttons/toolbar.js.map +7 -1
- package/build-module/components/convert-to-group-buttons/use-convert-to-group-button-props.js +32 -58
- package/build-module/components/convert-to-group-buttons/use-convert-to-group-button-props.js.map +7 -1
- package/build-module/components/copy-handler/index.js +19 -34
- package/build-module/components/copy-handler/index.js.map +7 -1
- package/build-module/components/date-format-picker/index.js +126 -107
- package/build-module/components/date-format-picker/index.js.map +7 -1
- package/build-module/components/default-block-appender/index.js +78 -92
- package/build-module/components/default-block-appender/index.js.map +7 -1
- package/build-module/components/dimensions-tool/aspect-ratio-tool.js +61 -69
- package/build-module/components/dimensions-tool/aspect-ratio-tool.js.map +7 -1
- package/build-module/components/dimensions-tool/index.js +105 -183
- package/build-module/components/dimensions-tool/index.js.map +7 -1
- package/build-module/components/dimensions-tool/scale-tool.js +74 -90
- package/build-module/components/dimensions-tool/scale-tool.js.map +7 -1
- package/build-module/components/dimensions-tool/width-height-tool.js +69 -106
- package/build-module/components/dimensions-tool/width-height-tool.js.map +7 -1
- package/build-module/components/duotone/utils.js +18 -54
- package/build-module/components/duotone/utils.js.map +7 -1
- package/build-module/components/duotone-control/index.js +71 -64
- package/build-module/components/duotone-control/index.js.map +7 -1
- package/build-module/components/editable-text/index.js +11 -30
- package/build-module/components/editable-text/index.js.map +7 -1
- package/build-module/components/editor-styles/index.js +83 -92
- package/build-module/components/editor-styles/index.js.map +7 -1
- package/build-module/components/floating-toolbar/nav-up-icon.js +30 -24
- package/build-module/components/floating-toolbar/nav-up-icon.js.map +7 -1
- package/build-module/components/font-appearance-control/index.js +68 -110
- package/build-module/components/font-appearance-control/index.js.map +7 -1
- package/build-module/components/font-family/index.js +57 -61
- package/build-module/components/font-family/index.js.map +7 -1
- package/build-module/components/font-sizes/fluid-utils.js +60 -161
- package/build-module/components/font-sizes/fluid-utils.js.map +7 -1
- package/build-module/components/font-sizes/font-size-picker.js +20 -22
- package/build-module/components/font-sizes/font-size-picker.js.map +7 -1
- package/build-module/components/font-sizes/index.js +17 -5
- package/build-module/components/font-sizes/index.js.map +7 -1
- package/build-module/components/font-sizes/utils.js +16 -52
- package/build-module/components/font-sizes/utils.js.map +7 -1
- package/build-module/components/font-sizes/with-font-sizes.js +126 -113
- package/build-module/components/font-sizes/with-font-sizes.js.map +7 -1
- package/build-module/components/global-styles/advanced-panel.js +40 -45
- package/build-module/components/global-styles/advanced-panel.js.map +7 -1
- package/build-module/components/global-styles/background-panel.js +69 -81
- package/build-module/components/global-styles/background-panel.js.map +7 -1
- package/build-module/components/global-styles/border-panel.js +157 -143
- package/build-module/components/global-styles/border-panel.js.map +7 -1
- package/build-module/components/global-styles/color-panel.js +491 -384
- package/build-module/components/global-styles/color-panel.js.map +7 -1
- package/build-module/components/global-styles/context.js +13 -9
- package/build-module/components/global-styles/context.js.map +7 -1
- package/build-module/components/global-styles/dimensions-panel.js +400 -351
- package/build-module/components/global-styles/dimensions-panel.js.map +7 -1
- package/build-module/components/global-styles/filters-panel.js +136 -136
- package/build-module/components/global-styles/filters-panel.js.map +7 -1
- package/build-module/components/global-styles/get-block-css-selector.js +20 -73
- package/build-module/components/global-styles/get-block-css-selector.js.map +7 -1
- package/build-module/components/global-styles/get-global-styles-changes.js +122 -163
- package/build-module/components/global-styles/get-global-styles-changes.js.map +7 -1
- package/build-module/components/global-styles/hooks.js +214 -124
- package/build-module/components/global-styles/hooks.js.map +7 -1
- package/build-module/components/global-styles/image-settings-panel.js +45 -46
- package/build-module/components/global-styles/image-settings-panel.js.map +7 -1
- package/build-module/components/global-styles/index.js +73 -15
- package/build-module/components/global-styles/index.js.map +7 -1
- package/build-module/components/global-styles/shadow-panel-components.js +147 -154
- package/build-module/components/global-styles/shadow-panel-components.js.map +7 -1
- package/build-module/components/global-styles/typography-panel.js +395 -279
- package/build-module/components/global-styles/typography-panel.js.map +7 -1
- package/build-module/components/global-styles/typography-utils.js +73 -175
- package/build-module/components/global-styles/typography-utils.js.map +7 -1
- package/build-module/components/global-styles/use-global-styles-output.js +667 -733
- package/build-module/components/global-styles/use-global-styles-output.js.map +7 -1
- package/build-module/components/global-styles/utils.js +264 -351
- package/build-module/components/global-styles/utils.js.map +7 -1
- package/build-module/components/gradients/index.js +2 -2
- package/build-module/components/gradients/index.js.map +7 -1
- package/build-module/components/gradients/use-gradient.js +76 -79
- package/build-module/components/gradients/use-gradient.js.map +7 -1
- package/build-module/components/gradients/with-gradient.js +9 -14
- package/build-module/components/gradients/with-gradient.js.map +7 -1
- package/build-module/components/grid/grid-item-movers.js +135 -95
- package/build-module/components/grid/grid-item-movers.js.map +7 -1
- package/build-module/components/grid/grid-item-resizer.js +109 -99
- package/build-module/components/grid/grid-item-resizer.js.map +7 -1
- package/build-module/components/grid/grid-visualizer.js +238 -190
- package/build-module/components/grid/grid-visualizer.js.map +7 -1
- package/build-module/components/grid/index.js +11 -5
- package/build-module/components/grid/index.js.map +7 -1
- package/build-module/components/grid/use-get-number-of-blocks-before-cell.js +9 -20
- package/build-module/components/grid/use-get-number-of-blocks-before-cell.js.map +7 -1
- package/build-module/components/grid/use-grid-layout-sync.js +98 -109
- package/build-module/components/grid/use-grid-layout-sync.js.map +7 -1
- package/build-module/components/grid/utils.js +79 -75
- package/build-module/components/grid/utils.js.map +7 -1
- package/build-module/components/height-control/index.js +122 -190
- package/build-module/components/height-control/index.js.map +7 -1
- package/build-module/components/html-element-control/index.js +62 -88
- package/build-module/components/html-element-control/index.js.map +7 -1
- package/build-module/components/html-element-control/messages.js +36 -20
- package/build-module/components/html-element-control/messages.js.map +7 -1
- package/build-module/components/iframe/get-compatibility-styles.js +68 -84
- package/build-module/components/iframe/get-compatibility-styles.js.map +7 -1
- package/build-module/components/iframe/index.js +161 -199
- package/build-module/components/iframe/index.js.map +7 -1
- package/build-module/components/iframe/use-scale-canvas.js +131 -257
- package/build-module/components/iframe/use-scale-canvas.js.map +7 -1
- package/build-module/components/image-editor/aspect-ratio-dropdown.js +99 -101
- package/build-module/components/image-editor/aspect-ratio-dropdown.js.map +7 -1
- package/build-module/components/image-editor/constants.js +10 -5
- package/build-module/components/image-editor/constants.js.map +7 -1
- package/build-module/components/image-editor/context.js +20 -23
- package/build-module/components/image-editor/context.js.map +7 -1
- package/build-module/components/image-editor/cropper.js +57 -53
- package/build-module/components/image-editor/cropper.js.map +7 -1
- package/build-module/components/image-editor/form-controls.js +14 -28
- package/build-module/components/image-editor/form-controls.js.map +7 -1
- package/build-module/components/image-editor/index.js +46 -44
- package/build-module/components/image-editor/index.js.map +7 -1
- package/build-module/components/image-editor/rotation-button.js +20 -25
- package/build-module/components/image-editor/rotation-button.js.map +7 -1
- package/build-module/components/image-editor/use-save-image.js +76 -63
- package/build-module/components/image-editor/use-save-image.js.map +7 -1
- package/build-module/components/image-editor/use-transform-image.js +47 -35
- package/build-module/components/image-editor/use-transform-image.js.map +7 -1
- package/build-module/components/image-editor/zoom-dropdown.js +46 -46
- package/build-module/components/image-editor/zoom-dropdown.js.map +7 -1
- package/build-module/components/image-size-control/index.js +95 -97
- package/build-module/components/image-size-control/index.js.map +7 -1
- package/build-module/components/image-size-control/use-dimension-handler.js +21 -28
- package/build-module/components/image-size-control/use-dimension-handler.js.map +7 -1
- package/build-module/components/index.js +293 -125
- package/build-module/components/index.js.map +7 -1
- package/build-module/components/inner-blocks/button-block-appender.js +22 -25
- package/build-module/components/inner-blocks/button-block-appender.js.map +7 -1
- package/build-module/components/inner-blocks/default-block-appender.js +10 -14
- package/build-module/components/inner-blocks/default-block-appender.js.map +7 -1
- package/build-module/components/inner-blocks/index.js +131 -175
- package/build-module/components/inner-blocks/index.js.map +7 -1
- package/build-module/components/inner-blocks/use-block-context.js +32 -34
- package/build-module/components/inner-blocks/use-block-context.js.map +7 -1
- package/build-module/components/inner-blocks/use-inner-block-template-sync.js +37 -64
- package/build-module/components/inner-blocks/use-inner-block-template-sync.js.map +7 -1
- package/build-module/components/inner-blocks/use-nested-settings-update.js +51 -99
- package/build-module/components/inner-blocks/use-nested-settings-update.js.map +7 -1
- package/build-module/components/inserter/block-patterns-explorer/index.js +49 -52
- package/build-module/components/inserter/block-patterns-explorer/index.js.map +7 -1
- package/build-module/components/inserter/block-patterns-explorer/pattern-explorer-sidebar.js +45 -44
- package/build-module/components/inserter/block-patterns-explorer/pattern-explorer-sidebar.js.map +7 -1
- package/build-module/components/inserter/block-patterns-explorer/pattern-list.js +105 -70
- package/build-module/components/inserter/block-patterns-explorer/pattern-list.js.map +7 -1
- package/build-module/components/inserter/block-patterns-tab/index.js +59 -54
- package/build-module/components/inserter/block-patterns-tab/index.js.map +7 -1
- package/build-module/components/inserter/block-patterns-tab/pattern-category-previews.js +169 -107
- package/build-module/components/inserter/block-patterns-tab/pattern-category-previews.js.map +7 -1
- package/build-module/components/inserter/block-patterns-tab/patterns-filter.js +132 -98
- package/build-module/components/inserter/block-patterns-tab/patterns-filter.js.map +7 -1
- package/build-module/components/inserter/block-patterns-tab/use-pattern-categories.js +58 -27
- package/build-module/components/inserter/block-patterns-tab/use-pattern-categories.js.map +7 -1
- package/build-module/components/inserter/block-patterns-tab/utils.js +31 -37
- package/build-module/components/inserter/block-patterns-tab/utils.js.map +7 -1
- package/build-module/components/inserter/block-types-tab.js +135 -127
- package/build-module/components/inserter/block-types-tab.js.map +7 -1
- package/build-module/components/inserter/category-tabs/index.js +72 -63
- package/build-module/components/inserter/category-tabs/index.js.map +7 -1
- package/build-module/components/inserter/hooks/use-block-types-state.js +80 -64
- package/build-module/components/inserter/hooks/use-block-types-state.js.map +7 -1
- package/build-module/components/inserter/hooks/use-insertion-point.js +137 -117
- package/build-module/components/inserter/hooks/use-insertion-point.js.map +7 -1
- package/build-module/components/inserter/hooks/use-patterns-paging.js +25 -26
- package/build-module/components/inserter/hooks/use-patterns-paging.js.map +7 -1
- package/build-module/components/inserter/hooks/use-patterns-state.js +92 -79
- package/build-module/components/inserter/hooks/use-patterns-state.js.map +7 -1
- package/build-module/components/inserter/index.js +199 -228
- package/build-module/components/inserter/index.js.map +7 -1
- package/build-module/components/inserter/library.js +51 -48
- package/build-module/components/inserter/library.js.map +7 -1
- package/build-module/components/inserter/media-tab/hooks.js +61 -77
- package/build-module/components/inserter/media-tab/hooks.js.map +7 -1
- package/build-module/components/inserter/media-tab/index.js +9 -4
- package/build-module/components/inserter/media-tab/index.js.map +7 -1
- package/build-module/components/inserter/media-tab/media-list.js +27 -24
- package/build-module/components/inserter/media-tab/media-list.js.map +7 -1
- package/build-module/components/inserter/media-tab/media-panel.js +39 -45
- package/build-module/components/inserter/media-tab/media-panel.js.map +7 -1
- package/build-module/components/inserter/media-tab/media-preview.js +241 -227
- package/build-module/components/inserter/media-tab/media-preview.js.map +7 -1
- package/build-module/components/inserter/media-tab/media-tab.js +79 -77
- package/build-module/components/inserter/media-tab/media-tab.js.map +7 -1
- package/build-module/components/inserter/media-tab/utils.js +25 -40
- package/build-module/components/inserter/media-tab/utils.js.map +7 -1
- package/build-module/components/inserter/menu.js +279 -202
- package/build-module/components/inserter/menu.js.map +7 -1
- package/build-module/components/inserter/mobile-tab-navigation.js +74 -71
- package/build-module/components/inserter/mobile-tab-navigation.js.map +7 -1
- package/build-module/components/inserter/no-results.js +8 -13
- package/build-module/components/inserter/no-results.js.map +7 -1
- package/build-module/components/inserter/panel.js +15 -26
- package/build-module/components/inserter/panel.js.map +7 -1
- package/build-module/components/inserter/preview-panel.js +43 -54
- package/build-module/components/inserter/preview-panel.js.map +7 -1
- package/build-module/components/inserter/quick-inserter.js +85 -81
- package/build-module/components/inserter/quick-inserter.js.map +7 -1
- package/build-module/components/inserter/search-items.js +53 -102
- package/build-module/components/inserter/search-items.js.map +7 -1
- package/build-module/components/inserter/search-results.js +136 -102
- package/build-module/components/inserter/search-results.js.map +7 -1
- package/build-module/components/inserter/tips.js +36 -22
- package/build-module/components/inserter/tips.js.map +7 -1
- package/build-module/components/inserter-button/sparkles.js +12 -14
- package/build-module/components/inserter-button/sparkles.js.map +7 -1
- package/build-module/components/inserter-draggable-blocks/index.js +58 -68
- package/build-module/components/inserter-draggable-blocks/index.js.map +7 -1
- package/build-module/components/inserter-list-item/index.js +111 -93
- package/build-module/components/inserter-list-item/index.js.map +7 -1
- package/build-module/components/inserter-listbox/context.js +7 -7
- package/build-module/components/inserter-listbox/context.js.map +7 -1
- package/build-module/components/inserter-listbox/group.js +32 -25
- package/build-module/components/inserter-listbox/group.js.map +7 -1
- package/build-module/components/inserter-listbox/index.js +26 -31
- package/build-module/components/inserter-listbox/index.js.map +7 -1
- package/build-module/components/inserter-listbox/item.js +29 -42
- package/build-module/components/inserter-listbox/item.js.map +7 -1
- package/build-module/components/inserter-listbox/row.js +9 -13
- package/build-module/components/inserter-listbox/row.js.map +7 -1
- package/build-module/components/inserter-menu-extension/index.js +9 -10
- package/build-module/components/inserter-menu-extension/index.js.map +7 -1
- package/build-module/components/inspector-controls/block-support-slot-container.js +19 -23
- package/build-module/components/inspector-controls/block-support-slot-container.js.map +7 -1
- package/build-module/components/inspector-controls/block-support-tools-panel.js +54 -58
- package/build-module/components/inspector-controls/block-support-tools-panel.js.map +7 -1
- package/build-module/components/inspector-controls/fill.js +46 -65
- package/build-module/components/inspector-controls/fill.js.map +7 -1
- package/build-module/components/inspector-controls/groups.js +29 -19
- package/build-module/components/inspector-controls/groups.js.map +7 -1
- package/build-module/components/inspector-controls/index.js +14 -25
- package/build-module/components/inspector-controls/index.js.map +7 -1
- package/build-module/components/inspector-controls/slot.js +31 -39
- package/build-module/components/inspector-controls/slot.js.map +7 -1
- package/build-module/components/inspector-controls-tabs/advanced-controls-panel.js +33 -22
- package/build-module/components/inspector-controls-tabs/advanced-controls-panel.js.map +7 -1
- package/build-module/components/inspector-controls-tabs/content-tab.js +11 -22
- package/build-module/components/inspector-controls-tabs/content-tab.js.map +7 -1
- package/build-module/components/inspector-controls-tabs/index.js +62 -91
- package/build-module/components/inspector-controls-tabs/index.js.map +7 -1
- package/build-module/components/inspector-controls-tabs/position-controls-panel.js +64 -65
- package/build-module/components/inspector-controls-tabs/position-controls-panel.js.map +7 -1
- package/build-module/components/inspector-controls-tabs/settings-tab.js +15 -18
- package/build-module/components/inspector-controls-tabs/settings-tab.js.map +7 -1
- package/build-module/components/inspector-controls-tabs/styles-tab.js +55 -50
- package/build-module/components/inspector-controls-tabs/styles-tab.js.map +7 -1
- package/build-module/components/inspector-controls-tabs/use-inspector-controls-tabs.js +32 -38
- package/build-module/components/inspector-controls-tabs/use-inspector-controls-tabs.js.map +7 -1
- package/build-module/components/inspector-controls-tabs/use-is-list-view-tab-disabled.js +8 -6
- package/build-module/components/inspector-controls-tabs/use-is-list-view-tab-disabled.js.map +7 -1
- package/build-module/components/inspector-controls-tabs/utils.js +25 -22
- package/build-module/components/inspector-controls-tabs/utils.js.map +7 -1
- package/build-module/components/inspector-popover-header/index.js +54 -42
- package/build-module/components/inspector-popover-header/index.js.map +7 -1
- package/build-module/components/justify-content-control/index.js +11 -21
- package/build-module/components/justify-content-control/index.js.map +7 -1
- package/build-module/components/justify-content-control/ui.js +69 -57
- package/build-module/components/justify-content-control/ui.js.map +7 -1
- package/build-module/components/keyboard-shortcuts/index.js +117 -101
- package/build-module/components/keyboard-shortcuts/index.js.map +7 -1
- package/build-module/components/letter-spacing-control/index.js +39 -50
- package/build-module/components/letter-spacing-control/index.js.map +7 -1
- package/build-module/components/line-height-control/index.js +44 -69
- package/build-module/components/line-height-control/index.js.map +7 -1
- package/build-module/components/line-height-control/utils.js +14 -29
- package/build-module/components/line-height-control/utils.js.map +7 -1
- package/build-module/components/link-control/constants.js +28 -19
- package/build-module/components/link-control/constants.js.map +7 -1
- package/build-module/components/link-control/index.js +297 -305
- package/build-module/components/link-control/index.js.map +7 -1
- package/build-module/components/link-control/is-url-like.js +12 -37
- package/build-module/components/link-control/is-url-like.js.map +7 -1
- package/build-module/components/link-control/link-preview.js +128 -134
- package/build-module/components/link-control/link-preview.js.map +7 -1
- package/build-module/components/link-control/search-create-button.js +32 -24
- package/build-module/components/link-control/search-create-button.js.map +7 -1
- package/build-module/components/link-control/search-input.js +122 -134
- package/build-module/components/link-control/search-input.js.map +7 -1
- package/build-module/components/link-control/search-item.js +78 -78
- package/build-module/components/link-control/search-item.js.map +7 -1
- package/build-module/components/link-control/search-results.js +67 -65
- package/build-module/components/link-control/search-results.js.map +7 -1
- package/build-module/components/link-control/settings-drawer.js +40 -44
- package/build-module/components/link-control/settings-drawer.js.map +7 -1
- package/build-module/components/link-control/settings.js +48 -30
- package/build-module/components/link-control/settings.js.map +7 -1
- package/build-module/components/link-control/use-create-page.js +23 -34
- package/build-module/components/link-control/use-create-page.js.map +7 -1
- package/build-module/components/link-control/use-internal-value.js +26 -27
- package/build-module/components/link-control/use-internal-value.js.map +7 -1
- package/build-module/components/link-control/use-rich-url-data.js +18 -31
- package/build-module/components/link-control/use-rich-url-data.js.map +7 -1
- package/build-module/components/link-control/use-search-handler.js +66 -74
- package/build-module/components/link-control/use-search-handler.js.map +7 -1
- package/build-module/components/link-control/viewer-slot.js +11 -11
- package/build-module/components/link-control/viewer-slot.js.map +7 -1
- package/build-module/components/list-view/appender.js +87 -93
- package/build-module/components/list-view/appender.js.map +7 -1
- package/build-module/components/list-view/aria-referenced-text.js +8 -27
- package/build-module/components/list-view/aria-referenced-text.js.map +7 -1
- package/build-module/components/list-view/block-contents.js +65 -72
- package/build-module/components/list-view/block-contents.js.map +7 -1
- package/build-module/components/list-view/block-select-button.js +119 -136
- package/build-module/components/list-view/block-select-button.js.map +7 -1
- package/build-module/components/list-view/block.js +358 -360
- package/build-module/components/list-view/block.js.map +7 -1
- package/build-module/components/list-view/branch.js +125 -139
- package/build-module/components/list-view/branch.js.map +7 -1
- package/build-module/components/list-view/context.js +9 -8
- package/build-module/components/list-view/context.js.map +7 -1
- package/build-module/components/list-view/drop-indicator.js +135 -157
- package/build-module/components/list-view/drop-indicator.js.map +7 -1
- package/build-module/components/list-view/expander.js +18 -22
- package/build-module/components/list-view/expander.js.map +7 -1
- package/build-module/components/list-view/index.js +249 -252
- package/build-module/components/list-view/index.js.map +7 -1
- package/build-module/components/list-view/leaf.js +45 -48
- package/build-module/components/list-view/leaf.js.map +7 -1
- package/build-module/components/list-view/use-block-selection.js +98 -103
- package/build-module/components/list-view/use-block-selection.js.map +7 -1
- package/build-module/components/list-view/use-clipboard-handler.js +48 -69
- package/build-module/components/list-view/use-clipboard-handler.js.map +7 -1
- package/build-module/components/list-view/use-list-view-block-indexes.js +8 -8
- package/build-module/components/list-view/use-list-view-block-indexes.js.map +7 -1
- package/build-module/components/list-view/use-list-view-client-ids.js +23 -28
- package/build-module/components/list-view/use-list-view-client-ids.js.map +7 -1
- package/build-module/components/list-view/use-list-view-collapse-items.js +13 -27
- package/build-module/components/list-view/use-list-view-collapse-items.js.map +7 -1
- package/build-module/components/list-view/use-list-view-drop-zone.js +157 -290
- package/build-module/components/list-view/use-list-view-drop-zone.js.map +7 -1
- package/build-module/components/list-view/use-list-view-expand-selected-item.js +27 -32
- package/build-module/components/list-view/use-list-view-expand-selected-item.js.map +7 -1
- package/build-module/components/list-view/use-list-view-images.js +25 -59
- package/build-module/components/list-view/use-list-view-images.js.map +7 -1
- package/build-module/components/list-view/use-list-view-scroll-into-view.js +8 -20
- package/build-module/components/list-view/use-list-view-scroll-into-view.js.map +7 -1
- package/build-module/components/list-view/utils.js +48 -111
- package/build-module/components/list-view/utils.js.map +7 -1
- package/build-module/components/media-placeholder/index.js +326 -289
- package/build-module/components/media-placeholder/index.js.map +7 -1
- package/build-module/components/media-replace-flow/index.js +162 -152
- package/build-module/components/media-replace-flow/index.js.map +7 -1
- package/build-module/components/media-upload/check.js +11 -23
- package/build-module/components/media-upload/check.js.map +7 -1
- package/build-module/components/media-upload/index.js +6 -18
- package/build-module/components/media-upload/index.js.map +7 -1
- package/build-module/components/media-upload-progress/constants.js +15 -7
- package/build-module/components/media-upload-progress/constants.js.map +7 -1
- package/build-module/components/multi-selection-inspector/index.js +32 -30
- package/build-module/components/multi-selection-inspector/index.js.map +7 -1
- package/build-module/components/navigable-toolbar/index.js +65 -86
- package/build-module/components/navigable-toolbar/index.js.map +7 -1
- package/build-module/components/observe-typing/index.js +129 -207
- package/build-module/components/observe-typing/index.js.map +7 -1
- package/build-module/components/panel-color-settings/index.js +19 -23
- package/build-module/components/panel-color-settings/index.js.map +7 -1
- package/build-module/components/plain-text/index.js +22 -75
- package/build-module/components/plain-text/index.js.map +7 -1
- package/build-module/components/preview-options/index.js +8 -8
- package/build-module/components/preview-options/index.js.map +7 -1
- package/build-module/components/provider/block-refs-provider.js +13 -21
- package/build-module/components/provider/block-refs-provider.js.map +7 -1
- package/build-module/components/provider/index.js +80 -91
- package/build-module/components/provider/index.js.map +7 -1
- package/build-module/components/provider/use-block-sync.js +27 -136
- package/build-module/components/provider/use-block-sync.js.map +7 -1
- package/build-module/components/provider/use-media-upload-settings.js +15 -20
- package/build-module/components/provider/use-media-upload-settings.js.map +7 -1
- package/build-module/components/provider/with-registry-provider.js +27 -36
- package/build-module/components/provider/with-registry-provider.js.map +7 -1
- package/build-module/components/publish-date-time-picker/index.js +42 -39
- package/build-module/components/publish-date-time-picker/index.js.map +7 -1
- package/build-module/components/recursion-provider/index.js +31 -81
- package/build-module/components/recursion-provider/index.js.map +7 -1
- package/build-module/components/resizable-box-popover/index.js +17 -20
- package/build-module/components/resizable-box-popover/index.js.map +7 -1
- package/build-module/components/resolution-tool/index.js +53 -39
- package/build-module/components/resolution-tool/index.js.map +7 -1
- package/build-module/components/responsive-block-control/index.js +86 -66
- package/build-module/components/responsive-block-control/index.js.map +7 -1
- package/build-module/components/responsive-block-control/label.js +22 -21
- package/build-module/components/responsive-block-control/label.js.map +7 -1
- package/build-module/components/rich-text/content.js +22 -40
- package/build-module/components/rich-text/content.js.map +7 -1
- package/build-module/components/rich-text/event-listeners/before-input-rules.js +23 -52
- package/build-module/components/rich-text/event-listeners/before-input-rules.js.map +7 -1
- package/build-module/components/rich-text/event-listeners/delete.js +13 -31
- package/build-module/components/rich-text/event-listeners/delete.js.map +7 -1
- package/build-module/components/rich-text/event-listeners/enter.js +22 -38
- package/build-module/components/rich-text/event-listeners/enter.js.map +7 -1
- package/build-module/components/rich-text/event-listeners/firefox-compat.js +12 -18
- package/build-module/components/rich-text/event-listeners/firefox-compat.js.map +7 -1
- package/build-module/components/rich-text/event-listeners/index.js +47 -33
- package/build-module/components/rich-text/event-listeners/index.js.map +7 -1
- package/build-module/components/rich-text/event-listeners/input-events.js +8 -7
- package/build-module/components/rich-text/event-listeners/input-events.js.map +7 -1
- package/build-module/components/rich-text/event-listeners/input-rules.js +46 -64
- package/build-module/components/rich-text/event-listeners/input-rules.js.map +7 -1
- package/build-module/components/rich-text/event-listeners/insert-replacement-text.js +10 -19
- package/build-module/components/rich-text/event-listeners/insert-replacement-text.js.map +7 -1
- package/build-module/components/rich-text/event-listeners/paste-handler.js +36 -65
- package/build-module/components/rich-text/event-listeners/paste-handler.js.map +7 -1
- package/build-module/components/rich-text/event-listeners/remove-browser-shortcuts.js +9 -14
- package/build-module/components/rich-text/event-listeners/remove-browser-shortcuts.js.map +7 -1
- package/build-module/components/rich-text/event-listeners/shortcuts.js +8 -7
- package/build-module/components/rich-text/event-listeners/shortcuts.js.map +7 -1
- package/build-module/components/rich-text/event-listeners/undo-automatic-change.js +13 -26
- package/build-module/components/rich-text/event-listeners/undo-automatic-change.js.map +7 -1
- package/build-module/components/rich-text/format-edit.js +36 -46
- package/build-module/components/rich-text/format-edit.js.map +7 -1
- package/build-module/components/rich-text/format-toolbar/index.js +51 -55
- package/build-module/components/rich-text/format-toolbar/index.js.map +7 -1
- package/build-module/components/rich-text/format-toolbar-container.js +33 -46
- package/build-module/components/rich-text/format-toolbar-container.js.map +7 -1
- package/build-module/components/rich-text/get-rich-text-values.js +37 -43
- package/build-module/components/rich-text/get-rich-text-values.js.map +7 -1
- package/build-module/components/rich-text/index.js +298 -303
- package/build-module/components/rich-text/index.js.map +7 -1
- package/build-module/components/rich-text/input-event.js +7 -14
- package/build-module/components/rich-text/input-event.js.map +7 -1
- package/build-module/components/rich-text/multiline.js +74 -68
- package/build-module/components/rich-text/multiline.js.map +7 -1
- package/build-module/components/rich-text/native/format-edit.js +25 -24
- package/build-module/components/rich-text/native/format-edit.js.map +7 -1
- package/build-module/components/rich-text/native/index.js +6 -2
- package/build-module/components/rich-text/native/index.js.map +7 -1
- package/build-module/components/rich-text/native/use-format-types.js +64 -55
- package/build-module/components/rich-text/native/use-format-types.js.map +7 -1
- package/build-module/components/rich-text/prevent-event-discovery.js +9 -12
- package/build-module/components/rich-text/prevent-event-discovery.js.map +7 -1
- package/build-module/components/rich-text/shortcut.js +8 -16
- package/build-module/components/rich-text/shortcut.js.map +7 -1
- package/build-module/components/rich-text/toolbar-button.js +10 -16
- package/build-module/components/rich-text/toolbar-button.js.map +7 -1
- package/build-module/components/rich-text/use-format-types.js +102 -82
- package/build-module/components/rich-text/use-format-types.js.map +7 -1
- package/build-module/components/rich-text/use-mark-persistent.js +10 -25
- package/build-module/components/rich-text/use-mark-persistent.js.map +7 -1
- package/build-module/components/rich-text/utils.js +24 -40
- package/build-module/components/rich-text/utils.js.map +7 -1
- package/build-module/components/rich-text/with-deprecations.js +30 -29
- package/build-module/components/rich-text/with-deprecations.js.map +7 -1
- package/build-module/components/selection-scroll-into-view/index.js +9 -16
- package/build-module/components/selection-scroll-into-view/index.js.map +7 -1
- package/build-module/components/skip-to-selected-block/index.js +26 -28
- package/build-module/components/skip-to-selected-block/index.js.map +7 -1
- package/build-module/components/spacing-sizes-control/hooks/use-spacing-sizes.js +38 -34
- package/build-module/components/spacing-sizes-control/hooks/use-spacing-sizes.js.map +7 -1
- package/build-module/components/spacing-sizes-control/index.js +65 -101
- package/build-module/components/spacing-sizes-control/index.js.map +7 -1
- package/build-module/components/spacing-sizes-control/input-controls/axial.js +37 -31
- package/build-module/components/spacing-sizes-control/input-controls/axial.js.map +7 -1
- package/build-module/components/spacing-sizes-control/input-controls/separated.js +33 -25
- package/build-module/components/spacing-sizes-control/input-controls/separated.js.map +7 -1
- package/build-module/components/spacing-sizes-control/input-controls/single.js +29 -24
- package/build-module/components/spacing-sizes-control/input-controls/single.js.map +7 -1
- package/build-module/components/spacing-sizes-control/input-controls/spacing-input-control.js +230 -263
- package/build-module/components/spacing-sizes-control/input-controls/spacing-input-control.js.map +7 -1
- package/build-module/components/spacing-sizes-control/linked-button.js +20 -20
- package/build-module/components/spacing-sizes-control/linked-button.js.map +7 -1
- package/build-module/components/spacing-sizes-control/utils.js +85 -167
- package/build-module/components/spacing-sizes-control/utils.js.map +7 -1
- package/build-module/components/tabbed-sidebar/index.js +62 -94
- package/build-module/components/tabbed-sidebar/index.js.map +7 -1
- package/build-module/components/text-alignment-control/index.js +76 -64
- package/build-module/components/text-alignment-control/index.js.map +7 -1
- package/build-module/components/text-decoration-control/index.js +58 -56
- package/build-module/components/text-decoration-control/index.js.map +7 -1
- package/build-module/components/text-transform-control/index.js +68 -64
- package/build-module/components/text-transform-control/index.js.map +7 -1
- package/build-module/components/typewriter/index.js +152 -206
- package/build-module/components/typewriter/index.js.map +7 -1
- package/build-module/components/unit-control/index.js +14 -21
- package/build-module/components/unit-control/index.js.map +7 -1
- package/build-module/components/url-input/button.js +68 -70
- package/build-module/components/url-input/button.js.map +7 -1
- package/build-module/components/url-input/index.js +191 -239
- package/build-module/components/url-input/index.js.map +7 -1
- package/build-module/components/url-popover/image-url-input-ui.js +232 -186
- package/build-module/components/url-popover/image-url-input-ui.js.map +7 -1
- package/build-module/components/url-popover/index.js +87 -93
- package/build-module/components/url-popover/index.js.map +7 -1
- package/build-module/components/url-popover/link-editor.js +40 -33
- package/build-module/components/url-popover/link-editor.js.map +7 -1
- package/build-module/components/url-popover/link-viewer-url.js +15 -26
- package/build-module/components/url-popover/link-viewer-url.js.map +7 -1
- package/build-module/components/url-popover/link-viewer.js +40 -33
- package/build-module/components/url-popover/link-viewer.js.map +7 -1
- package/build-module/components/use-block-commands/index.js +151 -133
- package/build-module/components/use-block-commands/index.js.map +7 -1
- package/build-module/components/use-block-display-information/index.js +62 -102
- package/build-module/components/use-block-display-information/index.js.map +7 -1
- package/build-module/components/use-block-drop-zone/index.js +277 -301
- package/build-module/components/use-block-drop-zone/index.js.map +7 -1
- package/build-module/components/use-flash-editable-blocks/index.js +45 -48
- package/build-module/components/use-flash-editable-blocks/index.js.map +7 -1
- package/build-module/components/use-moving-animation/index.js +43 -102
- package/build-module/components/use-moving-animation/index.js.map +7 -1
- package/build-module/components/use-on-block-drop/index.js +184 -173
- package/build-module/components/use-on-block-drop/index.js.map +7 -1
- package/build-module/components/use-on-block-drop/types.js +1 -2
- package/build-module/components/use-on-block-drop/types.js.map +7 -1
- package/build-module/components/use-paste-styles/index.js +127 -127
- package/build-module/components/use-paste-styles/index.js.map +7 -1
- package/build-module/components/use-resize-canvas/index.js +19 -27
- package/build-module/components/use-resize-canvas/index.js.map +7 -1
- package/build-module/components/use-settings/index.js +24 -53
- package/build-module/components/use-settings/index.js.map +7 -1
- package/build-module/components/warning/index.js +45 -59
- package/build-module/components/warning/index.js.map +7 -1
- package/build-module/components/writing-flow/index.js +79 -65
- package/build-module/components/writing-flow/index.js.map +7 -1
- package/build-module/components/writing-flow/use-arrow-nav.js +89 -136
- package/build-module/components/writing-flow/use-arrow-nav.js.map +7 -1
- package/build-module/components/writing-flow/use-click-selection.js +38 -51
- package/build-module/components/writing-flow/use-click-selection.js.map +7 -1
- package/build-module/components/writing-flow/use-clipboard-handler.js +68 -76
- package/build-module/components/writing-flow/use-clipboard-handler.js.map +7 -1
- package/build-module/components/writing-flow/use-drag-selection.js +81 -145
- package/build-module/components/writing-flow/use-drag-selection.js.map +7 -1
- package/build-module/components/writing-flow/use-input.js +54 -52
- package/build-module/components/writing-flow/use-input.js.map +7 -1
- package/build-module/components/writing-flow/use-multi-selection.js +38 -55
- package/build-module/components/writing-flow/use-multi-selection.js.map +7 -1
- package/build-module/components/writing-flow/use-select-all.js +20 -31
- package/build-module/components/writing-flow/use-select-all.js.map +7 -1
- package/build-module/components/writing-flow/use-selection-observer.js +118 -184
- package/build-module/components/writing-flow/use-selection-observer.js.map +7 -1
- package/build-module/components/writing-flow/use-tab-nav.js +68 -131
- package/build-module/components/writing-flow/use-tab-nav.js.map +7 -1
- package/build-module/components/writing-flow/utils.js +40 -62
- package/build-module/components/writing-flow/utils.js.map +7 -1
- package/build-module/components/writing-mode-control/index.js +50 -56
- package/build-module/components/writing-mode-control/index.js.map +7 -1
- package/build-module/elements/index.js +8 -5
- package/build-module/elements/index.js.map +7 -1
- package/build-module/hooks/align.js +71 -125
- package/build-module/hooks/align.js.map +7 -1
- package/build-module/hooks/allowed-blocks.js +50 -0
- package/build-module/hooks/allowed-blocks.js.map +7 -0
- package/build-module/hooks/anchor.js +58 -84
- package/build-module/hooks/anchor.js.map +7 -1
- package/build-module/hooks/aria-label.js +22 -39
- package/build-module/hooks/aria-label.js.map +7 -1
- package/build-module/hooks/background.js +80 -100
- package/build-module/hooks/background.js.map +7 -1
- package/build-module/hooks/block-bindings.js +370 -245
- package/build-module/hooks/block-bindings.js.map +7 -1
- package/build-module/hooks/block-hooks.js +153 -158
- package/build-module/hooks/block-hooks.js.map +7 -1
- package/build-module/hooks/block-renaming.js +20 -29
- package/build-module/hooks/block-renaming.js.map +7 -1
- package/build-module/hooks/block-style-variation.js +127 -167
- package/build-module/hooks/block-style-variation.js.map +7 -1
- package/build-module/hooks/border.js +143 -231
- package/build-module/hooks/border.js.map +7 -1
- package/build-module/hooks/color.js +182 -174
- package/build-module/hooks/color.js.map +7 -1
- package/build-module/hooks/compat.js +10 -11
- package/build-module/hooks/compat.js.map +7 -1
- package/build-module/hooks/content-lock-ui.js +32 -53
- package/build-module/hooks/content-lock-ui.js.map +7 -1
- package/build-module/hooks/contrast-checker.js +36 -37
- package/build-module/hooks/contrast-checker.js.map +7 -1
- package/build-module/hooks/custom-class-name.js +52 -82
- package/build-module/hooks/custom-class-name.js.map +7 -1
- package/build-module/hooks/dimensions.js +113 -126
- package/build-module/hooks/dimensions.js.map +7 -1
- package/build-module/hooks/duotone.js +148 -178
- package/build-module/hooks/duotone.js.map +7 -1
- package/build-module/hooks/fit-text.js +174 -0
- package/build-module/hooks/fit-text.js.map +7 -0
- package/build-module/hooks/font-family.js +33 -68
- package/build-module/hooks/font-family.js.map +7 -1
- package/build-module/hooks/font-size.js +102 -111
- package/build-module/hooks/font-size.js.map +7 -1
- package/build-module/hooks/gap.js +9 -25
- package/build-module/hooks/gap.js.map +7 -1
- package/build-module/hooks/generated-class-name.js +20 -28
- package/build-module/hooks/generated-class-name.js.map +7 -1
- package/build-module/hooks/grid-visualizer.js +50 -57
- package/build-module/hooks/grid-visualizer.js.map +7 -1
- package/build-module/hooks/index.js +113 -48
- package/build-module/hooks/index.js.map +7 -1
- package/build-module/hooks/layout-child.js +109 -132
- package/build-module/hooks/layout-child.js.map +7 -1
- package/build-module/hooks/layout.js +229 -283
- package/build-module/hooks/layout.js.map +7 -1
- package/build-module/hooks/line-height.js +27 -47
- package/build-module/hooks/line-height.js.map +7 -1
- package/build-module/hooks/lock.js +9 -20
- package/build-module/hooks/lock.js.map +7 -1
- package/build-module/hooks/metadata.js +13 -19
- package/build-module/hooks/metadata.js.map +7 -1
- package/build-module/hooks/position.js +123 -221
- package/build-module/hooks/position.js.map +7 -1
- package/build-module/hooks/settings.js +10 -11
- package/build-module/hooks/settings.js.map +7 -1
- package/build-module/hooks/spacing-visualizer.js +69 -75
- package/build-module/hooks/spacing-visualizer.js.map +7 -1
- package/build-module/hooks/style.js +145 -271
- package/build-module/hooks/style.js.map +7 -1
- package/build-module/hooks/supports.js +95 -253
- package/build-module/hooks/supports.js.map +7 -1
- package/build-module/hooks/text-align.js +77 -89
- package/build-module/hooks/text-align.js.map +7 -1
- package/build-module/hooks/typography.js +105 -94
- package/build-module/hooks/typography.js.map +7 -1
- package/build-module/hooks/use-border-props.js +14 -46
- package/build-module/hooks/use-border-props.js.map +7 -1
- package/build-module/hooks/use-cached-truthy.js +6 -13
- package/build-module/hooks/use-cached-truthy.js.map +7 -1
- package/build-module/hooks/use-color-props.js +74 -83
- package/build-module/hooks/use-color-props.js.map +7 -1
- package/build-module/hooks/use-shadow-props.js +8 -22
- package/build-module/hooks/use-shadow-props.js.map +7 -1
- package/build-module/hooks/use-spacing-props.js +8 -27
- package/build-module/hooks/use-spacing-props.js.map +7 -1
- package/build-module/hooks/use-typography-props.js +24 -46
- package/build-module/hooks/use-typography-props.js.map +7 -1
- package/build-module/hooks/use-zoom-out.js +15 -49
- package/build-module/hooks/use-zoom-out.js.map +7 -1
- package/build-module/hooks/utils.js +384 -235
- package/build-module/hooks/utils.js.map +7 -1
- package/build-module/index.js +38 -12
- package/build-module/index.js.map +7 -1
- package/build-module/layouts/constrained.js +200 -201
- package/build-module/layouts/constrained.js.map +7 -1
- package/build-module/layouts/definitions.js +166 -140
- package/build-module/layouts/definitions.js.map +7 -1
- package/build-module/layouts/flex.js +246 -231
- package/build-module/layouts/flex.js.map +7 -1
- package/build-module/layouts/flow.js +36 -53
- package/build-module/layouts/flow.js.map +7 -1
- package/build-module/layouts/grid.js +237 -243
- package/build-module/layouts/grid.js.map +7 -1
- package/build-module/layouts/index.js +12 -24
- package/build-module/layouts/index.js.map +7 -1
- package/build-module/layouts/utils.js +28 -65
- package/build-module/layouts/utils.js.map +7 -1
- package/build-module/lock-unlock.js +8 -7
- package/build-module/lock-unlock.js.map +7 -1
- package/build-module/private-apis.js +63 -44
- package/build-module/private-apis.js.map +7 -1
- package/build-module/store/actions.js +536 -1191
- package/build-module/store/actions.js.map +7 -1
- package/build-module/store/array.js +17 -25
- package/build-module/store/array.js.map +7 -1
- package/build-module/store/constants.js +5 -2
- package/build-module/store/constants.js.map +7 -1
- package/build-module/store/defaults.js +168 -197
- package/build-module/store/defaults.js.map +7 -1
- package/build-module/store/get-block-settings.js +83 -88
- package/build-module/store/get-block-settings.js.map +7 -1
- package/build-module/store/index.js +17 -43
- package/build-module/store/index.js.map +7 -1
- package/build-module/store/private-actions.js +121 -310
- package/build-module/store/private-actions.js.map +7 -1
- package/build-module/store/private-keys.js +17 -8
- package/build-module/store/private-keys.js.map +7 -1
- package/build-module/store/private-selectors.js +282 -442
- package/build-module/store/private-selectors.js.map +7 -1
- package/build-module/store/reducer.js +1102 -1801
- package/build-module/store/reducer.js.map +7 -1
- package/build-module/store/selectors.js +1135 -2151
- package/build-module/store/selectors.js.map +7 -1
- package/build-module/store/utils.js +60 -42
- package/build-module/store/utils.js.map +7 -1
- package/build-module/utils/block-bindings.js +25 -175
- package/build-module/utils/block-bindings.js.map +7 -1
- package/build-module/utils/dom.js +36 -101
- package/build-module/utils/dom.js.map +7 -1
- package/build-module/utils/fit-text-frontend.js +40 -0
- package/build-module/utils/fit-text-frontend.js.map +7 -0
- package/build-module/utils/fit-text-utils.js +39 -0
- package/build-module/utils/fit-text-utils.js.map +7 -0
- package/build-module/utils/format-font-style.js +14 -24
- package/build-module/utils/format-font-style.js.map +7 -1
- package/build-module/utils/format-font-weight.js +30 -40
- package/build-module/utils/format-font-weight.js.map +7 -1
- package/build-module/utils/get-editor-region.js +10 -22
- package/build-module/utils/get-editor-region.js.map +7 -1
- package/build-module/utils/get-font-styles-and-weights.js +90 -101
- package/build-module/utils/get-font-styles-and-weights.js.map +7 -1
- package/build-module/utils/get-px-from-css-unit.js +5 -9
- package/build-module/utils/get-px-from-css-unit.js.map +7 -1
- package/build-module/utils/index.js +9 -4
- package/build-module/utils/index.js.map +7 -1
- package/build-module/utils/math.js +18 -78
- package/build-module/utils/math.js.map +7 -1
- package/build-module/utils/object.js +16 -53
- package/build-module/utils/object.js.map +7 -1
- package/build-module/utils/order-inserter-block-items.js +6 -18
- package/build-module/utils/order-inserter-block-items.js.map +7 -1
- package/build-module/utils/pasting.js +17 -79
- package/build-module/utils/pasting.js.map +7 -1
- package/build-module/utils/selection.js +13 -25
- package/build-module/utils/selection.js.map +7 -1
- package/build-module/utils/sorting.js +10 -29
- package/build-module/utils/sorting.js.map +7 -1
- package/build-module/utils/transform-styles/index.js +72 -136
- package/build-module/utils/transform-styles/index.js.map +7 -1
- package/build-module/utils/use-notify-copy.js +58 -49
- package/build-module/utils/use-notify-copy.js.map +7 -1
- package/build-style/content-rtl.css +64 -192
- package/build-style/content.css +64 -192
- package/build-style/default-editor-styles-rtl.css +3 -197
- package/build-style/default-editor-styles.css +3 -197
- package/build-style/style-rtl.css +140 -290
- package/build-style/style.css +140 -290
- package/package.json +56 -36
- package/src/autocompleters/style.scss +2 -0
- package/src/components/background-image-control/style.scss +4 -0
- package/src/components/block-allowed-blocks/allowed-blocks-control.js +80 -0
- package/src/components/block-allowed-blocks/index.js +2 -0
- package/src/components/block-allowed-blocks/modal.js +100 -0
- package/src/components/block-allowed-blocks/style.scss +27 -0
- package/src/components/block-breadcrumb/style.scss +3 -0
- package/src/components/block-canvas/style.scss +8 -1
- package/src/components/block-card/index.js +37 -30
- package/src/components/block-card/style.scss +3 -0
- package/src/components/block-compare/style.scss +4 -0
- package/src/components/block-draggable/content.scss +3 -2
- package/src/components/block-draggable/style.scss +3 -0
- package/src/components/block-edit/edit.js +2 -14
- package/src/components/block-icon/content.scss +7 -0
- package/src/components/block-icon/style.scss +7 -0
- package/src/components/block-inspector/index.js +27 -3
- package/src/components/block-inspector/style.scss +3 -0
- package/src/components/block-list/block.js +12 -1
- package/src/components/block-list/content.scss +19 -9
- package/src/components/block-list/index.js +11 -6
- package/src/components/block-list/use-block-props/use-selected-block-event-handlers.js +132 -34
- package/src/components/block-list-appender/content.scss +2 -0
- package/src/components/block-lock/style.scss +4 -0
- package/src/components/block-manager/index.js +32 -28
- package/src/components/block-manager/style.scss +4 -26
- package/src/components/block-mover/style.scss +3 -0
- package/src/components/block-navigation/style.scss +3 -0
- package/src/components/block-pattern-setup/style.scss +5 -0
- package/src/components/block-patterns-list/style.scss +3 -0
- package/src/components/block-patterns-paging/style.scss +3 -0
- package/src/components/block-popover/style.scss +2 -0
- package/src/components/block-rename/modal.js +3 -2
- package/src/components/block-rename/style.scss +2 -0
- package/src/components/block-settings-menu/block-settings-dropdown.js +7 -9
- package/src/components/block-styles/style.scss +5 -0
- package/src/components/block-switcher/style.scss +3 -0
- package/src/components/block-toolbar/index.js +2 -14
- package/src/components/block-toolbar/style.scss +5 -1
- package/src/components/block-tools/index.js +46 -1
- package/src/components/block-tools/style.scss +4 -45
- package/src/components/block-tools/use-show-block-tools.js +1 -8
- package/src/components/block-variation-picker/content.scss +3 -0
- package/src/components/block-variation-transforms/style.scss +3 -0
- package/src/components/block-visibility/menu-item.js +45 -2
- package/src/components/border-radius-control/style.scss +2 -0
- package/src/components/button-block-appender/content.scss +3 -0
- package/src/components/color-palette/test/__snapshots__/control.js.snap +1 -1
- package/src/components/colors-gradients/style.scss +4 -0
- package/src/components/date-format-picker/style.scss +3 -0
- package/src/components/default-block-appender/content.scss +4 -0
- package/src/components/duotone-control/style.scss +4 -0
- package/src/components/font-appearance-control/style.scss +2 -0
- package/src/components/font-family/style.scss +2 -0
- package/src/components/global-styles/color-panel.js +2 -0
- package/src/components/global-styles/get-global-styles-changes.js +2 -0
- package/src/components/global-styles/style.scss +3 -0
- package/src/components/grid/style.scss +5 -0
- package/src/components/iframe/content.scss +8 -1
- package/src/components/iframe/style.scss +7 -0
- package/src/components/index.js +0 -1
- package/src/components/inserter/style.scss +6 -5
- package/src/components/inserter-list-item/style.scss +2 -0
- package/src/components/inspector-controls/groups.js +5 -0
- package/src/components/inspector-controls-tabs/advanced-controls-panel.js +7 -1
- package/src/components/inspector-popover-header/style.scss +2 -0
- package/src/components/keyboard-shortcuts/index.js +10 -0
- package/src/components/link-control/index.js +118 -16
- package/src/components/link-control/link-preview.js +9 -2
- package/src/components/link-control/search-input.js +3 -1
- package/src/components/link-control/settings.js +38 -11
- package/src/components/link-control/style.scss +20 -3
- package/src/components/link-control/test/index.js +511 -1
- package/src/components/list-view/block.js +32 -0
- package/src/components/list-view/style.scss +5 -0
- package/src/components/media-placeholder/style.scss +2 -0
- package/src/components/media-replace-flow/style.scss +3 -0
- package/src/components/multi-selection-inspector/style.scss +2 -0
- package/src/components/responsive-block-control/style.scss +3 -0
- package/src/components/rich-text/content.scss +2 -0
- package/src/components/rich-text/index.js +18 -17
- package/src/components/rich-text/style.scss +3 -0
- package/src/components/skip-to-selected-block/style.scss +2 -0
- package/src/components/spacing-sizes-control/style.scss +2 -0
- package/src/components/tabbed-sidebar/style.scss +3 -0
- package/src/components/url-input/index.js +8 -4
- package/src/components/url-input/style.scss +4 -0
- package/src/components/url-popover/link-viewer.js +2 -2
- package/src/components/url-popover/style.scss +3 -0
- package/src/components/use-block-commands/index.js +40 -0
- package/src/components/warning/content.scss +4 -0
- package/src/content.scss +16 -14
- package/src/default-editor-styles.scss +1 -0
- package/src/hooks/allowed-blocks.js +74 -0
- package/src/hooks/block-bindings.js +399 -200
- package/src/hooks/block-hooks.scss +3 -0
- package/src/hooks/color.scss +2 -0
- package/src/hooks/fit-text.js +268 -0
- package/src/hooks/index.js +6 -0
- package/src/hooks/layout.scss +3 -0
- package/src/hooks/typography.js +2 -0
- package/src/private-apis.js +6 -1
- package/src/store/actions.js +2 -15
- package/src/store/private-actions.js +15 -0
- package/src/store/private-selectors.js +13 -14
- package/src/store/reducer.js +81 -265
- package/src/store/selectors.js +2 -44
- package/src/store/test/private-selectors.js +2 -9
- package/src/store/test/reducer.js +1 -345
- package/src/store/test/selectors.js +3 -1
- package/src/store/utils.js +11 -12
- package/src/style.scss +64 -62
- package/src/utils/fit-text-frontend.js +84 -0
- package/src/utils/fit-text-utils.js +75 -0
- package/build/components/audio-player/audio-url-parser.native.js +0 -24
- package/build/components/audio-player/audio-url-parser.native.js.map +0 -1
- package/build/components/audio-player/index.native.js +0 -174
- package/build/components/audio-player/index.native.js.map +0 -1
- package/build/components/block-alignment-control/ui.native.js +0 -80
- package/build/components/block-alignment-control/ui.native.js.map +0 -1
- package/build/components/block-caption/index.native.js +0 -95
- package/build/components/block-caption/index.native.js.map +0 -1
- package/build/components/block-controls/slot.native.js +0 -46
- package/build/components/block-controls/slot.native.js.map +0 -1
- package/build/components/block-draggable/draggable-chip.native.js +0 -58
- package/build/components/block-draggable/draggable-chip.native.js.map +0 -1
- package/build/components/block-draggable/dropping-insertion-point.native.js +0 -134
- package/build/components/block-draggable/dropping-insertion-point.native.js.map +0 -1
- package/build/components/block-draggable/index.native.js +0 -432
- package/build/components/block-draggable/index.native.js.map +0 -1
- package/build/components/block-draggable/use-scroll-when-dragging.native.js +0 -118
- package/build/components/block-draggable/use-scroll-when-dragging.native.js.map +0 -1
- package/build/components/block-edit/edit.native.js +0 -51
- package/build/components/block-edit/edit.native.js.map +0 -1
- package/build/components/block-heading-level-dropdown/index.native.js +0 -68
- package/build/components/block-heading-level-dropdown/index.native.js.map +0 -1
- package/build/components/block-icon/index.native.js +0 -56
- package/build/components/block-icon/index.native.js.map +0 -1
- package/build/components/block-list/block-crash-boundary.native.js +0 -49
- package/build/components/block-list/block-crash-boundary.native.js.map +0 -1
- package/build/components/block-list/block-crash-warning.native.js +0 -24
- package/build/components/block-list/block-crash-warning.native.js.map +0 -1
- package/build/components/block-list/block-invalid-warning.native.js +0 -79
- package/build/components/block-list/block-invalid-warning.native.js.map +0 -1
- package/build/components/block-list/block-list-context.native.js +0 -170
- package/build/components/block-list/block-list-context.native.js.map +0 -1
- package/build/components/block-list/block-list-item-cell.native.js +0 -74
- package/build/components/block-list/block-list-item-cell.native.js.map +0 -1
- package/build/components/block-list/block-list-item.native.js +0 -191
- package/build/components/block-list/block-list-item.native.js.map +0 -1
- package/build/components/block-list/block-outline.native.js +0 -61
- package/build/components/block-list/block-outline.native.js.map +0 -1
- package/build/components/block-list/block-selection-button.native.js +0 -98
- package/build/components/block-list/block-selection-button.native.js.map +0 -1
- package/build/components/block-list/block.native.js +0 -538
- package/build/components/block-list/block.native.js.map +0 -1
- package/build/components/block-list/grid-item.native.js +0 -63
- package/build/components/block-list/grid-item.native.js.map +0 -1
- package/build/components/block-list/index.native.js +0 -351
- package/build/components/block-list/index.native.js.map +0 -1
- package/build/components/block-list/insertion-point.native.js +0 -45
- package/build/components/block-list/insertion-point.native.js.map +0 -1
- package/build/components/block-list/use-block-props/index.native.js +0 -24
- package/build/components/block-list/use-block-props/index.native.js.map +0 -1
- package/build/components/block-list/use-scroll-upon-insertion.native.js +0 -40
- package/build/components/block-list/use-scroll-upon-insertion.native.js.map +0 -1
- package/build/components/block-list-appender/index.native.js +0 -69
- package/build/components/block-list-appender/index.native.js.map +0 -1
- package/build/components/block-media-update-progress/index.native.js +0 -287
- package/build/components/block-media-update-progress/index.native.js.map +0 -1
- package/build/components/block-mover/index.native.js +0 -173
- package/build/components/block-mover/index.native.js.map +0 -1
- package/build/components/block-mover/mover-description.native.js +0 -130
- package/build/components/block-mover/mover-description.native.js.map +0 -1
- package/build/components/block-settings/button.native.js +0 -44
- package/build/components/block-settings/button.native.js.map +0 -1
- package/build/components/block-settings/container.native.js +0 -84
- package/build/components/block-settings/container.native.js.map +0 -1
- package/build/components/block-settings/index.native.js +0 -29
- package/build/components/block-settings/index.native.js.map +0 -1
- package/build/components/block-styles/index.native.js +0 -89
- package/build/components/block-styles/index.native.js.map +0 -1
- package/build/components/block-styles/preview.native.js +0 -96
- package/build/components/block-styles/preview.native.js.map +0 -1
- package/build/components/block-switcher/block-transformations-menu.native.js +0 -79
- package/build/components/block-switcher/block-transformations-menu.native.js.map +0 -1
- package/build/components/block-toolbar/block-toolbar-menu.native.js +0 -378
- package/build/components/block-toolbar/block-toolbar-menu.native.js.map +0 -1
- package/build/components/block-toolbar/index.native.js +0 -108
- package/build/components/block-toolbar/index.native.js.map +0 -1
- package/build/components/block-types-list/index.native.js +0 -141
- package/build/components/block-types-list/index.native.js.map +0 -1
- package/build/components/block-variation-picker/index.native.js +0 -91
- package/build/components/block-variation-picker/index.native.js.map +0 -1
- package/build/components/button-block-appender/index.native.js +0 -82
- package/build/components/button-block-appender/index.native.js.map +0 -1
- package/build/components/caption/index.native.js +0 -62
- package/build/components/caption/index.native.js.map +0 -1
- package/build/components/colors-gradients/panel-color-gradient-settings.native.js +0 -62
- package/build/components/colors-gradients/panel-color-gradient-settings.native.js.map +0 -1
- package/build/components/contrast-checker/index.native.js +0 -91
- package/build/components/contrast-checker/index.native.js.map +0 -1
- package/build/components/convert-to-group-buttons/index.native.js +0 -82
- package/build/components/convert-to-group-buttons/index.native.js.map +0 -1
- package/build/components/default-block-appender/index.native.js +0 -113
- package/build/components/default-block-appender/index.native.js.map +0 -1
- package/build/components/floating-toolbar/index.native.js +0 -126
- package/build/components/floating-toolbar/index.native.js.map +0 -1
- package/build/components/font-sizes/index.native.js +0 -40
- package/build/components/font-sizes/index.native.js.map +0 -1
- package/build/components/global-styles/color-panel.native.js +0 -146
- package/build/components/global-styles/color-panel.native.js.map +0 -1
- package/build/components/global-styles/use-global-styles-context.native.js +0 -456
- package/build/components/global-styles/use-global-styles-context.native.js.map +0 -1
- package/build/components/gradients/index.native.js +0 -28
- package/build/components/gradients/index.native.js.map +0 -1
- package/build/components/image-link-destinations/index.native.js +0 -127
- package/build/components/image-link-destinations/index.native.js.map +0 -1
- package/build/components/index.native.js +0 -657
- package/build/components/index.native.js.map +0 -1
- package/build/components/inner-blocks/constants.native.js +0 -12
- package/build/components/inner-blocks/constants.native.js.map +0 -1
- package/build/components/inner-blocks/index.native.js +0 -208
- package/build/components/inner-blocks/index.native.js.map +0 -1
- package/build/components/inner-blocks/warning-max-depth-exceeded.native.js +0 -95
- package/build/components/inner-blocks/warning-max-depth-exceeded.native.js.map +0 -1
- package/build/components/inserter/block-types-tab.native.js +0 -72
- package/build/components/inserter/block-types-tab.native.js.map +0 -1
- package/build/components/inserter/hooks/use-block-type-impressions.native.js +0 -62
- package/build/components/inserter/hooks/use-block-type-impressions.native.js.map +0 -1
- package/build/components/inserter/hooks/use-clipboard-block.native.js +0 -51
- package/build/components/inserter/hooks/use-clipboard-block.native.js.map +0 -1
- package/build/components/inserter/index.native.js +0 -369
- package/build/components/inserter/index.native.js.map +0 -1
- package/build/components/inserter/menu.native.js +0 -189
- package/build/components/inserter/menu.native.js.map +0 -1
- package/build/components/inserter/no-results.native.js +0 -49
- package/build/components/inserter/no-results.native.js.map +0 -1
- package/build/components/inserter/reusable-blocks-tab.native.js +0 -57
- package/build/components/inserter/reusable-blocks-tab.native.js.map +0 -1
- package/build/components/inserter/search-results.native.js +0 -71
- package/build/components/inserter/search-results.native.js.map +0 -1
- package/build/components/inserter/tabs.native.js +0 -140
- package/build/components/inserter/tabs.native.js.map +0 -1
- package/build/components/inserter/utils.native.js +0 -56
- package/build/components/inserter/utils.native.js.map +0 -1
- package/build/components/inserter-button/index.native.js +0 -92
- package/build/components/inserter-button/index.native.js.map +0 -1
- package/build/components/inspector-controls/fill.native.js +0 -63
- package/build/components/inspector-controls/fill.native.js.map +0 -1
- package/build/components/inspector-controls/slot.native.js +0 -42
- package/build/components/inspector-controls/slot.native.js.map +0 -1
- package/build/components/inspector-controls-tabs/advanced-controls-panel.native.js +0 -38
- package/build/components/inspector-controls-tabs/advanced-controls-panel.native.js.map +0 -1
- package/build/components/line-height-control/index.native.js +0 -40
- package/build/components/line-height-control/index.native.js.map +0 -1
- package/build/components/media-placeholder/index.native.js +0 -200
- package/build/components/media-placeholder/index.native.js.map +0 -1
- package/build/components/media-replace-flow/index.native.js +0 -21
- package/build/components/media-replace-flow/index.native.js.map +0 -1
- package/build/components/media-upload/constants.native.js +0 -20
- package/build/components/media-upload/constants.native.js.map +0 -1
- package/build/components/media-upload/index.native.js +0 -294
- package/build/components/media-upload/index.native.js.map +0 -1
- package/build/components/media-upload-progress/index.native.js +0 -203
- package/build/components/media-upload-progress/index.native.js.map +0 -1
- package/build/components/plain-text/index.native.js +0 -157
- package/build/components/plain-text/index.native.js.map +0 -1
- package/build/components/provider/index.native.js +0 -42
- package/build/components/provider/index.native.js.map +0 -1
- package/build/components/rich-text/embed-handler-picker.native.js +0 -54
- package/build/components/rich-text/embed-handler-picker.native.js.map +0 -1
- package/build/components/rich-text/file-paste-handler.native.js +0 -10
- package/build/components/rich-text/file-paste-handler.native.js.map +0 -1
- package/build/components/rich-text/format-toolbar/index.native.js +0 -23
- package/build/components/rich-text/format-toolbar/index.native.js.map +0 -1
- package/build/components/rich-text/format-toolbar-container.native.js +0 -23
- package/build/components/rich-text/format-toolbar-container.native.js.map +0 -1
- package/build/components/rich-text/index.native.js +0 -601
- package/build/components/rich-text/index.native.js.map +0 -1
- package/build/components/rich-text/input-event.native.js +0 -18
- package/build/components/rich-text/input-event.native.js.map +0 -1
- package/build/components/rich-text/native/get-format-colors.native.js +0 -39
- package/build/components/rich-text/native/get-format-colors.native.js.map +0 -1
- package/build/components/rich-text/native/index.native.js +0 -1184
- package/build/components/rich-text/native/index.native.js.map +0 -1
- package/build/components/rich-text/native/toolbar-button-with-options.native.js +0 -60
- package/build/components/rich-text/native/toolbar-button-with-options.native.js.map +0 -1
- package/build/components/rich-text/remove-browser-shortcuts.native.js +0 -9
- package/build/components/rich-text/remove-browser-shortcuts.native.js.map +0 -1
- package/build/components/rich-text/shortcut.native.js +0 -18
- package/build/components/rich-text/shortcut.native.js.map +0 -1
- package/build/components/tool-selector/index.js +0 -90
- package/build/components/tool-selector/index.js.map +0 -1
- package/build/components/ungroup-button/index.native.js +0 -77
- package/build/components/ungroup-button/index.native.js.map +0 -1
- package/build/components/unsupported-block-details/index.native.js +0 -129
- package/build/components/unsupported-block-details/index.native.js.map +0 -1
- package/build/components/url-input/index.native.js +0 -39
- package/build/components/url-input/index.native.js.map +0 -1
- package/build/components/use-block-drop-zone/index.native.js +0 -192
- package/build/components/use-block-drop-zone/index.native.js.map +0 -1
- package/build/components/use-on-block-drop/index.native.js +0 -89
- package/build/components/use-on-block-drop/index.native.js.map +0 -1
- package/build/components/use-unsupported-block-editor/index.native.js +0 -57
- package/build/components/use-unsupported-block-editor/index.native.js.map +0 -1
- package/build/components/video-player/gridicon-play.native.js +0 -20
- package/build/components/video-player/gridicon-play.native.js.map +0 -1
- package/build/components/video-player/index.native.js +0 -135
- package/build/components/video-player/index.native.js.map +0 -1
- package/build/components/warning/index.native.js +0 -63
- package/build/components/warning/index.native.js.map +0 -1
- package/build/hooks/align.native.js +0 -56
- package/build/hooks/align.native.js.map +0 -1
- package/build/hooks/custom-class-name.native.js +0 -66
- package/build/hooks/custom-class-name.native.js.map +0 -1
- package/build/hooks/index.native.js +0 -85
- package/build/hooks/index.native.js.map +0 -1
- package/build/hooks/layout.native.js +0 -20
- package/build/hooks/layout.native.js.map +0 -1
- package/build/hooks/typography.native.js +0 -76
- package/build/hooks/typography.native.js.map +0 -1
- package/build/hooks/use-editor-wrapper-styles.native.js +0 -227
- package/build/hooks/use-editor-wrapper-styles.native.js.map +0 -1
- package/build/index.native.js +0 -28
- package/build/index.native.js.map +0 -1
- package/build/private-apis.native.js +0 -31
- package/build/private-apis.native.js.map +0 -1
- package/build/store/defaults.native.js +0 -31
- package/build/store/defaults.native.js.map +0 -1
- package/build-module/components/audio-player/audio-url-parser.native.js +0 -16
- package/build-module/components/audio-player/audio-url-parser.native.js.map +0 -1
- package/build-module/components/audio-player/index.native.js +0 -166
- package/build-module/components/audio-player/index.native.js.map +0 -1
- package/build-module/components/block-alignment-control/ui.native.js +0 -72
- package/build-module/components/block-alignment-control/ui.native.js.map +0 -1
- package/build-module/components/block-caption/index.native.js +0 -87
- package/build-module/components/block-caption/index.native.js.map +0 -1
- package/build-module/components/block-controls/slot.native.js +0 -38
- package/build-module/components/block-controls/slot.native.js.map +0 -1
- package/build-module/components/block-draggable/draggable-chip.native.js +0 -50
- package/build-module/components/block-draggable/draggable-chip.native.js.map +0 -1
- package/build-module/components/block-draggable/dropping-insertion-point.native.js +0 -126
- package/build-module/components/block-draggable/dropping-insertion-point.native.js.map +0 -1
- package/build-module/components/block-draggable/index.native.js +0 -422
- package/build-module/components/block-draggable/index.native.js.map +0 -1
- package/build-module/components/block-draggable/use-scroll-when-dragging.native.js +0 -111
- package/build-module/components/block-draggable/use-scroll-when-dragging.native.js.map +0 -1
- package/build-module/components/block-edit/edit.native.js +0 -44
- package/build-module/components/block-edit/edit.native.js.map +0 -1
- package/build-module/components/block-heading-level-dropdown/index.native.js +0 -60
- package/build-module/components/block-heading-level-dropdown/index.native.js.map +0 -1
- package/build-module/components/block-icon/index.native.js +0 -47
- package/build-module/components/block-icon/index.native.js.map +0 -1
- package/build-module/components/block-list/block-crash-boundary.native.js +0 -42
- package/build-module/components/block-list/block-crash-boundary.native.js.map +0 -1
- package/build-module/components/block-list/block-crash-warning.native.js +0 -15
- package/build-module/components/block-list/block-crash-warning.native.js.map +0 -1
- package/build-module/components/block-list/block-invalid-warning.native.js +0 -71
- package/build-module/components/block-list/block-invalid-warning.native.js.map +0 -1
- package/build-module/components/block-list/block-list-context.native.js +0 -160
- package/build-module/components/block-list/block-list-context.native.js.map +0 -1
- package/build-module/components/block-list/block-list-item-cell.native.js +0 -67
- package/build-module/components/block-list/block-list-item-cell.native.js.map +0 -1
- package/build-module/components/block-list/block-list-item.native.js +0 -185
- package/build-module/components/block-list/block-list-item.native.js.map +0 -1
- package/build-module/components/block-list/block-outline.native.js +0 -53
- package/build-module/components/block-list/block-outline.native.js.map +0 -1
- package/build-module/components/block-list/block-selection-button.native.js +0 -90
- package/build-module/components/block-list/block-selection-button.native.js.map +0 -1
- package/build-module/components/block-list/block.native.js +0 -530
- package/build-module/components/block-list/block.native.js.map +0 -1
- package/build-module/components/block-list/grid-item.native.js +0 -55
- package/build-module/components/block-list/grid-item.native.js.map +0 -1
- package/build-module/components/block-list/index.native.js +0 -343
- package/build-module/components/block-list/index.native.js.map +0 -1
- package/build-module/components/block-list/insertion-point.native.js +0 -37
- package/build-module/components/block-list/insertion-point.native.js.map +0 -1
- package/build-module/components/block-list/use-block-props/index.native.js +0 -17
- package/build-module/components/block-list/use-block-props/index.native.js.map +0 -1
- package/build-module/components/block-list/use-scroll-upon-insertion.native.js +0 -33
- package/build-module/components/block-list/use-scroll-upon-insertion.native.js.map +0 -1
- package/build-module/components/block-list-appender/index.native.js +0 -61
- package/build-module/components/block-list-appender/index.native.js.map +0 -1
- package/build-module/components/block-media-update-progress/index.native.js +0 -278
- package/build-module/components/block-media-update-progress/index.native.js.map +0 -1
- package/build-module/components/block-mover/index.native.js +0 -165
- package/build-module/components/block-mover/index.native.js.map +0 -1
- package/build-module/components/block-mover/mover-description.native.js +0 -122
- package/build-module/components/block-mover/mover-description.native.js.map +0 -1
- package/build-module/components/block-settings/button.native.js +0 -37
- package/build-module/components/block-settings/button.native.js.map +0 -1
- package/build-module/components/block-settings/container.native.js +0 -75
- package/build-module/components/block-settings/container.native.js.map +0 -1
- package/build-module/components/block-settings/index.native.js +0 -3
- package/build-module/components/block-settings/index.native.js.map +0 -1
- package/build-module/components/block-styles/index.native.js +0 -81
- package/build-module/components/block-styles/index.native.js.map +0 -1
- package/build-module/components/block-styles/preview.native.js +0 -88
- package/build-module/components/block-styles/preview.native.js.map +0 -1
- package/build-module/components/block-switcher/block-transformations-menu.native.js +0 -72
- package/build-module/components/block-switcher/block-transformations-menu.native.js.map +0 -1
- package/build-module/components/block-toolbar/block-toolbar-menu.native.js +0 -369
- package/build-module/components/block-toolbar/block-toolbar-menu.native.js.map +0 -1
- package/build-module/components/block-toolbar/index.native.js +0 -100
- package/build-module/components/block-toolbar/index.native.js.map +0 -1
- package/build-module/components/block-types-list/index.native.js +0 -133
- package/build-module/components/block-types-list/index.native.js.map +0 -1
- package/build-module/components/block-variation-picker/index.native.js +0 -83
- package/build-module/components/block-variation-picker/index.native.js.map +0 -1
- package/build-module/components/button-block-appender/index.native.js +0 -74
- package/build-module/components/button-block-appender/index.native.js.map +0 -1
- package/build-module/components/caption/index.native.js +0 -55
- package/build-module/components/caption/index.native.js.map +0 -1
- package/build-module/components/colors-gradients/panel-color-gradient-settings.native.js +0 -55
- package/build-module/components/colors-gradients/panel-color-gradient-settings.native.js.map +0 -1
- package/build-module/components/contrast-checker/index.native.js +0 -82
- package/build-module/components/contrast-checker/index.native.js.map +0 -1
- package/build-module/components/convert-to-group-buttons/index.native.js +0 -69
- package/build-module/components/convert-to-group-buttons/index.native.js.map +0 -1
- package/build-module/components/default-block-appender/index.native.js +0 -104
- package/build-module/components/default-block-appender/index.native.js.map +0 -1
- package/build-module/components/floating-toolbar/index.native.js +0 -118
- package/build-module/components/floating-toolbar/index.native.js.map +0 -1
- package/build-module/components/font-sizes/index.native.js +0 -4
- package/build-module/components/font-sizes/index.native.js.map +0 -1
- package/build-module/components/global-styles/color-panel.native.js +0 -133
- package/build-module/components/global-styles/color-panel.native.js.map +0 -1
- package/build-module/components/global-styles/use-global-styles-context.native.js +0 -437
- package/build-module/components/global-styles/use-global-styles-context.native.js.map +0 -1
- package/build-module/components/gradients/index.native.js +0 -3
- package/build-module/components/gradients/index.native.js.map +0 -1
- package/build-module/components/image-link-destinations/index.native.js +0 -119
- package/build-module/components/image-link-destinations/index.native.js.map +0 -1
- package/build-module/components/index.native.js +0 -58
- package/build-module/components/index.native.js.map +0 -1
- package/build-module/components/inner-blocks/constants.native.js +0 -6
- package/build-module/components/inner-blocks/constants.native.js.map +0 -1
- package/build-module/components/inner-blocks/index.native.js +0 -200
- package/build-module/components/inner-blocks/index.native.js.map +0 -1
- package/build-module/components/inner-blocks/warning-max-depth-exceeded.native.js +0 -87
- package/build-module/components/inner-blocks/warning-max-depth-exceeded.native.js.map +0 -1
- package/build-module/components/inserter/block-types-tab.native.js +0 -64
- package/build-module/components/inserter/block-types-tab.native.js.map +0 -1
- package/build-module/components/inserter/hooks/use-block-type-impressions.native.js +0 -55
- package/build-module/components/inserter/hooks/use-block-type-impressions.native.js.map +0 -1
- package/build-module/components/inserter/hooks/use-clipboard-block.native.js +0 -44
- package/build-module/components/inserter/hooks/use-clipboard-block.native.js.map +0 -1
- package/build-module/components/inserter/index.native.js +0 -360
- package/build-module/components/inserter/index.native.js.map +0 -1
- package/build-module/components/inserter/menu.native.js +0 -181
- package/build-module/components/inserter/menu.native.js.map +0 -1
- package/build-module/components/inserter/no-results.native.js +0 -41
- package/build-module/components/inserter/no-results.native.js.map +0 -1
- package/build-module/components/inserter/reusable-blocks-tab.native.js +0 -49
- package/build-module/components/inserter/reusable-blocks-tab.native.js.map +0 -1
- package/build-module/components/inserter/search-results.native.js +0 -63
- package/build-module/components/inserter/search-results.native.js.map +0 -1
- package/build-module/components/inserter/tabs.native.js +0 -132
- package/build-module/components/inserter/tabs.native.js.map +0 -1
- package/build-module/components/inserter/utils.native.js +0 -48
- package/build-module/components/inserter/utils.native.js.map +0 -1
- package/build-module/components/inserter-button/index.native.js +0 -84
- package/build-module/components/inserter-button/index.native.js.map +0 -1
- package/build-module/components/inspector-controls/fill.native.js +0 -55
- package/build-module/components/inspector-controls/fill.native.js.map +0 -1
- package/build-module/components/inspector-controls/slot.native.js +0 -34
- package/build-module/components/inspector-controls/slot.native.js.map +0 -1
- package/build-module/components/inspector-controls-tabs/advanced-controls-panel.native.js +0 -30
- package/build-module/components/inspector-controls-tabs/advanced-controls-panel.native.js.map +0 -1
- package/build-module/components/line-height-control/index.native.js +0 -32
- package/build-module/components/line-height-control/index.native.js.map +0 -1
- package/build-module/components/media-placeholder/index.native.js +0 -192
- package/build-module/components/media-placeholder/index.native.js.map +0 -1
- package/build-module/components/media-replace-flow/index.native.js +0 -15
- package/build-module/components/media-replace-flow/index.native.js.map +0 -1
- package/build-module/components/media-upload/constants.native.js +0 -13
- package/build-module/components/media-upload/constants.native.js.map +0 -1
- package/build-module/components/media-upload/index.native.js +0 -285
- package/build-module/components/media-upload/index.native.js.map +0 -1
- package/build-module/components/media-upload-progress/index.native.js +0 -194
- package/build-module/components/media-upload-progress/index.native.js.map +0 -1
- package/build-module/components/plain-text/index.native.js +0 -148
- package/build-module/components/plain-text/index.native.js.map +0 -1
- package/build-module/components/provider/index.native.js +0 -37
- package/build-module/components/provider/index.native.js.map +0 -1
- package/build-module/components/rich-text/embed-handler-picker.native.js +0 -47
- package/build-module/components/rich-text/embed-handler-picker.native.js.map +0 -1
- package/build-module/components/rich-text/file-paste-handler.native.js +0 -4
- package/build-module/components/rich-text/file-paste-handler.native.js.map +0 -1
- package/build-module/components/rich-text/format-toolbar/index.native.js +0 -17
- package/build-module/components/rich-text/format-toolbar/index.native.js.map +0 -1
- package/build-module/components/rich-text/format-toolbar-container.native.js +0 -15
- package/build-module/components/rich-text/format-toolbar-container.native.js.map +0 -1
- package/build-module/components/rich-text/index.native.js +0 -573
- package/build-module/components/rich-text/index.native.js.map +0 -1
- package/build-module/components/rich-text/input-event.native.js +0 -10
- package/build-module/components/rich-text/input-event.native.js.map +0 -1
- package/build-module/components/rich-text/native/get-format-colors.native.js +0 -32
- package/build-module/components/rich-text/native/get-format-colors.native.js.map +0 -1
- package/build-module/components/rich-text/native/index.native.js +0 -1176
- package/build-module/components/rich-text/native/index.native.js.map +0 -1
- package/build-module/components/rich-text/native/toolbar-button-with-options.native.js +0 -55
- package/build-module/components/rich-text/native/toolbar-button-with-options.native.js.map +0 -1
- package/build-module/components/rich-text/remove-browser-shortcuts.native.js +0 -2
- package/build-module/components/rich-text/remove-browser-shortcuts.native.js.map +0 -1
- package/build-module/components/rich-text/shortcut.native.js +0 -10
- package/build-module/components/rich-text/shortcut.native.js.map +0 -1
- package/build-module/components/tool-selector/index.js +0 -83
- package/build-module/components/tool-selector/index.js.map +0 -1
- package/build-module/components/ungroup-button/index.native.js +0 -69
- package/build-module/components/ungroup-button/index.native.js.map +0 -1
- package/build-module/components/unsupported-block-details/index.native.js +0 -121
- package/build-module/components/unsupported-block-details/index.native.js.map +0 -1
- package/build-module/components/url-input/index.native.js +0 -32
- package/build-module/components/url-input/index.native.js.map +0 -1
- package/build-module/components/use-block-drop-zone/index.native.js +0 -183
- package/build-module/components/use-block-drop-zone/index.native.js.map +0 -1
- package/build-module/components/use-on-block-drop/index.native.js +0 -82
- package/build-module/components/use-on-block-drop/index.native.js.map +0 -1
- package/build-module/components/use-unsupported-block-editor/index.native.js +0 -51
- package/build-module/components/use-unsupported-block-editor/index.native.js.map +0 -1
- package/build-module/components/video-player/gridicon-play.native.js +0 -14
- package/build-module/components/video-player/gridicon-play.native.js.map +0 -1
- package/build-module/components/video-player/index.native.js +0 -128
- package/build-module/components/video-player/index.native.js.map +0 -1
- package/build-module/components/warning/index.native.js +0 -55
- package/build-module/components/warning/index.native.js.map +0 -1
- package/build-module/hooks/align.native.js +0 -32
- package/build-module/hooks/align.native.js.map +0 -1
- package/build-module/hooks/custom-class-name.native.js +0 -57
- package/build-module/hooks/custom-class-name.native.js.map +0 -1
- package/build-module/hooks/index.native.js +0 -24
- package/build-module/hooks/index.native.js.map +0 -1
- package/build-module/hooks/layout.native.js +0 -18
- package/build-module/hooks/layout.native.js.map +0 -1
- package/build-module/hooks/typography.native.js +0 -68
- package/build-module/hooks/typography.native.js.map +0 -1
- package/build-module/hooks/use-editor-wrapper-styles.native.js +0 -219
- package/build-module/hooks/use-editor-wrapper-styles.native.js.map +0 -1
- package/build-module/index.native.js +0 -6
- package/build-module/index.native.js.map +0 -1
- package/build-module/private-apis.native.js +0 -22
- package/build-module/private-apis.native.js.map +0 -1
- package/build-module/store/defaults.native.js +0 -19
- package/build-module/store/defaults.native.js.map +0 -1
- package/src/components/tool-selector/index.js +0 -107
- package/src/components/tool-selector/style.scss +0 -15
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{"version":3,"names":["__experimentalParseQuantityAndUnitFromRawValue","parseQuantityAndUnitFromRawValue","__experimentalUnitControl","UnitControl","__experimentalHStack","HStack","Icon","Tooltip","RangeControl","Button","CustomSelectControl","__","useState","settings","getAllValue","getCustomValueFromPreset","getPresetValueFromControlValue","getPresetValueFromCustomValue","getSliderValueFromPreset","isValuePreset","convertPresetsToCustomValues","CORNERS","ICONS","MIN_BORDER_RADIUS_VALUE","MAX_BORDER_RADIUS_VALUES","RANGE_CONTROL_MAX_SIZE","jsx","_jsx","jsxs","_jsxs","SingleInputControl","corner","onChange","selectedUnits","setSelectedUnits","values","valuesProp","units","presets","changeCornerValue","validatedValue","topLeft","topRight","bottomLeft","bottomRight","onChangeValue","next","isNumeric","isNaN","parseFloat","nextValue","undefined","onChangeUnit","newUnits","value","convertedValues","customValue","resolvedPresetValue","parsedQuantity","parsedUnit","computedUnit","flat","unitConfig","find","item","step","showCustomValueControl","setShowCustomValueControl","showRangeControl","length","presetIndex","rangeTooltip","newValue","name","marks","slice","map","_newValue","index","label","hasPresets","options","slug","size","key","icon","handleSliderChange","val","children","className","text","placement","join","onUnitChange","min","__next40pxDefaultSize","hideLabelFromVision","max","initialPosition","withInputField","__nextHasNoMarginBottom","newSize","renderTooltipContent","option","selection","selectedItem","onClick","isPressed","iconSize"],"sources":["@wordpress/block-editor/src/components/border-radius-control/single-input-control.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport {\n\t__experimentalParseQuantityAndUnitFromRawValue as parseQuantityAndUnitFromRawValue,\n\t__experimentalUnitControl as UnitControl,\n\t__experimentalHStack as HStack,\n\tIcon,\n\tTooltip,\n\tRangeControl,\n\tButton,\n\tCustomSelectControl,\n} from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { useState } from '@wordpress/element';\nimport { settings } from '@wordpress/icons';\n\n/**\n * Internal dependencies\n */\nimport {\n\tgetAllValue,\n\tgetCustomValueFromPreset,\n\tgetPresetValueFromControlValue,\n\tgetPresetValueFromCustomValue,\n\tgetSliderValueFromPreset,\n\tisValuePreset,\n\tconvertPresetsToCustomValues,\n} from './utils';\nimport {\n\tCORNERS,\n\tICONS,\n\tMIN_BORDER_RADIUS_VALUE,\n\tMAX_BORDER_RADIUS_VALUES,\n\tRANGE_CONTROL_MAX_SIZE,\n} from './constants';\n\nexport default function SingleInputControl( {\n\tcorner,\n\tonChange,\n\tselectedUnits,\n\tsetSelectedUnits,\n\tvalues: valuesProp,\n\tunits,\n\tpresets,\n} ) {\n\tconst changeCornerValue = ( validatedValue ) => {\n\t\tif ( corner === 'all' ) {\n\t\t\tonChange( {\n\t\t\t\ttopLeft: validatedValue,\n\t\t\t\ttopRight: validatedValue,\n\t\t\t\tbottomLeft: validatedValue,\n\t\t\t\tbottomRight: validatedValue,\n\t\t\t} );\n\t\t} else {\n\t\t\tonChange( {\n\t\t\t\t...values,\n\t\t\t\t[ corner ]: validatedValue,\n\t\t\t} );\n\t\t}\n\t};\n\n\tconst onChangeValue = ( next ) => {\n\t\tif ( ! onChange ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Filter out CSS-unit-only values to prevent invalid styles.\n\t\tconst isNumeric = ! isNaN( parseFloat( next ) );\n\t\tconst nextValue = isNumeric ? next : undefined;\n\t\tchangeCornerValue( nextValue );\n\t};\n\n\tconst onChangeUnit = ( next ) => {\n\t\tconst newUnits = { ...selectedUnits };\n\t\tif ( corner === 'all' ) {\n\t\t\tnewUnits.topLeft = next;\n\t\t\tnewUnits.topRight = next;\n\t\t\tnewUnits.bottomLeft = next;\n\t\t\tnewUnits.bottomRight = next;\n\t\t} else {\n\t\t\tnewUnits[ corner ] = next;\n\t\t}\n\t\tsetSelectedUnits( newUnits );\n\t};\n\n\t// For shorthand style & backwards compatibility, handle flat string value.\n\tconst values =\n\t\ttypeof valuesProp !== 'string'\n\t\t\t? valuesProp\n\t\t\t: {\n\t\t\t\t\ttopLeft: valuesProp,\n\t\t\t\t\ttopRight: valuesProp,\n\t\t\t\t\tbottomLeft: valuesProp,\n\t\t\t\t\tbottomRight: valuesProp,\n\t\t\t };\n\n\t// For 'all' corner, convert presets to custom values before calling getAllValue\n\t// For individual corners, check if the value should be converted to a preset\n\tlet value;\n\tif ( corner === 'all' ) {\n\t\tconst convertedValues = convertPresetsToCustomValues( values, presets );\n\t\tconst customValue = getAllValue( convertedValues );\n\t\tvalue = getPresetValueFromCustomValue( customValue, presets );\n\t} else {\n\t\tvalue = getPresetValueFromCustomValue( values[ corner ], presets );\n\t}\n\tconst resolvedPresetValue = isValuePreset( value )\n\t\t? getCustomValueFromPreset( value, presets )\n\t\t: value;\n\tconst [ parsedQuantity, parsedUnit ] =\n\t\tparseQuantityAndUnitFromRawValue( resolvedPresetValue );\n\tconst computedUnit = value\n\t\t? parsedUnit\n\t\t: selectedUnits[ corner ] || selectedUnits.flat || 'px';\n\tconst unitConfig =\n\t\tunits && units.find( ( item ) => item.value === computedUnit );\n\tconst step = unitConfig?.step || 1;\n\tconst [ showCustomValueControl, setShowCustomValueControl ] = useState(\n\t\tvalue !== undefined && ! isValuePreset( value )\n\t);\n\tconst showRangeControl = presets.length <= RANGE_CONTROL_MAX_SIZE;\n\tconst presetIndex = getSliderValueFromPreset( value, presets );\n\tconst rangeTooltip = ( newValue ) =>\n\t\tvalue === undefined ? undefined : presets[ newValue ]?.name;\n\tconst marks = presets\n\t\t.slice( 1, presets.length - 1 )\n\t\t.map( ( _newValue, index ) => ( {\n\t\t\tvalue: index + 1,\n\t\t\tlabel: undefined,\n\t\t} ) );\n\tconst hasPresets = marks.length > 0;\n\tlet options = [];\n\tif ( ! showRangeControl ) {\n\t\toptions = [\n\t\t\t...presets,\n\t\t\t{\n\t\t\t\tname: __( 'Custom' ),\n\t\t\t\tslug: 'custom',\n\t\t\t\tsize: resolvedPresetValue,\n\t\t\t},\n\t\t].map( ( size, index ) => ( {\n\t\t\tkey: index,\n\t\t\tname: size.name,\n\t\t} ) );\n\t}\n\tconst icon = ICONS[ corner ];\n\n\tconst handleSliderChange = ( next ) => {\n\t\tconst val =\n\t\t\tnext !== undefined ? `${ next }${ computedUnit }` : undefined;\n\t\tchangeCornerValue( val );\n\t};\n\n\t// Controls are wrapped in tooltips as visible labels aren't desired here.\n\t// Tooltip rendering also requires the UnitControl to be wrapped. See:\n\t// https://github.com/WordPress/gutenberg/pull/24966#issuecomment-685875026\n\treturn (\n\t\t<HStack>\n\t\t\t{ icon && (\n\t\t\t\t<Icon\n\t\t\t\t\tclassName=\"components-border-radius-control__icon\"\n\t\t\t\t\ticon={ icon }\n\t\t\t\t\tsize={ 24 }\n\t\t\t\t/>\n\t\t\t) }\n\t\t\t{ ( ! hasPresets || showCustomValueControl ) && (\n\t\t\t\t<div className=\"components-border-radius-control__input-controls-wrapper\">\n\t\t\t\t\t<Tooltip text={ CORNERS[ corner ] } placement=\"top\">\n\t\t\t\t\t\t<div className=\"components-border-radius-control__tooltip-wrapper\">\n\t\t\t\t\t\t\t<UnitControl\n\t\t\t\t\t\t\t\tclassName=\"components-border-radius-control__unit-control\"\n\t\t\t\t\t\t\t\taria-label={ CORNERS[ corner ] }\n\t\t\t\t\t\t\t\tvalue={ [ parsedQuantity, computedUnit ].join(\n\t\t\t\t\t\t\t\t\t''\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\tonChange={ onChangeValue }\n\t\t\t\t\t\t\t\tonUnitChange={ onChangeUnit }\n\t\t\t\t\t\t\t\tsize=\"__unstable-large\"\n\t\t\t\t\t\t\t\tmin={ MIN_BORDER_RADIUS_VALUE }\n\t\t\t\t\t\t\t\tunits={ units }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</Tooltip>\n\t\t\t\t\t<RangeControl\n\t\t\t\t\t\t__next40pxDefaultSize\n\t\t\t\t\t\tlabel={ __( 'Border radius' ) }\n\t\t\t\t\t\thideLabelFromVision\n\t\t\t\t\t\tclassName=\"components-border-radius-control__range-control\"\n\t\t\t\t\t\tvalue={ parsedQuantity ?? '' }\n\t\t\t\t\t\tmin={ MIN_BORDER_RADIUS_VALUE }\n\t\t\t\t\t\tmax={ MAX_BORDER_RADIUS_VALUES[ computedUnit ] }\n\t\t\t\t\t\tinitialPosition={ 0 }\n\t\t\t\t\t\twithInputField={ false }\n\t\t\t\t\t\tonChange={ handleSliderChange }\n\t\t\t\t\t\tstep={ step }\n\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t/>\n\t\t\t\t</div>\n\t\t\t) }\n\t\t\t{ hasPresets && showRangeControl && ! showCustomValueControl && (\n\t\t\t\t<RangeControl\n\t\t\t\t\t__next40pxDefaultSize\n\t\t\t\t\tclassName=\"components-border-radius-control__range-control\"\n\t\t\t\t\tvalue={ presetIndex }\n\t\t\t\t\tonChange={ ( newSize ) => {\n\t\t\t\t\t\tchangeCornerValue(\n\t\t\t\t\t\t\tgetPresetValueFromControlValue(\n\t\t\t\t\t\t\t\tnewSize,\n\t\t\t\t\t\t\t\t'range',\n\t\t\t\t\t\t\t\tpresets\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t);\n\t\t\t\t\t} }\n\t\t\t\t\twithInputField={ false }\n\t\t\t\t\taria-valuenow={ presetIndex }\n\t\t\t\t\taria-valuetext={ presets[ presetIndex ]?.name }\n\t\t\t\t\trenderTooltipContent={ rangeTooltip }\n\t\t\t\t\tmin={ 0 }\n\t\t\t\t\tmax={ presets.length - 1 }\n\t\t\t\t\tmarks={ marks }\n\t\t\t\t\tlabel={ CORNERS[ corner ] }\n\t\t\t\t\thideLabelFromVision\n\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t/>\n\t\t\t) }\n\n\t\t\t{ ! showRangeControl && ! showCustomValueControl && (\n\t\t\t\t<CustomSelectControl\n\t\t\t\t\tclassName=\"components-border-radius-control__custom-select-control\"\n\t\t\t\t\tvalue={\n\t\t\t\t\t\toptions.find(\n\t\t\t\t\t\t\t( option ) => option.key === presetIndex\n\t\t\t\t\t\t) || options[ options.length - 1 ]\n\t\t\t\t\t}\n\t\t\t\t\tonChange={ ( selection ) => {\n\t\t\t\t\t\tif (\n\t\t\t\t\t\t\tselection.selectedItem.key ===\n\t\t\t\t\t\t\toptions.length - 1\n\t\t\t\t\t\t) {\n\t\t\t\t\t\t\tsetShowCustomValueControl( true );\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tchangeCornerValue(\n\t\t\t\t\t\t\t\tgetPresetValueFromControlValue(\n\t\t\t\t\t\t\t\t\tselection.selectedItem.key,\n\t\t\t\t\t\t\t\t\t'selectList',\n\t\t\t\t\t\t\t\t\tpresets\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\t\t\t\t\t} }\n\t\t\t\t\toptions={ options }\n\t\t\t\t\tlabel={ CORNERS[ corner ] }\n\t\t\t\t\thideLabelFromVision\n\t\t\t\t\tsize=\"__unstable-large\"\n\t\t\t\t/>\n\t\t\t) }\n\t\t\t{ hasPresets && (\n\t\t\t\t<Button\n\t\t\t\t\tlabel={\n\t\t\t\t\t\tshowCustomValueControl\n\t\t\t\t\t\t\t? __( 'Use border radius preset' )\n\t\t\t\t\t\t\t: __( 'Set custom border radius' )\n\t\t\t\t\t}\n\t\t\t\t\ticon={ settings }\n\t\t\t\t\tonClick={ () => {\n\t\t\t\t\t\tsetShowCustomValueControl( ! showCustomValueControl );\n\t\t\t\t\t} }\n\t\t\t\t\tisPressed={ showCustomValueControl }\n\t\t\t\t\tsize=\"small\"\n\t\t\t\t\tclassName=\"components-border-radius-control__custom-toggle\"\n\t\t\t\t\ticonSize={ 24 }\n\t\t\t\t/>\n\t\t\t) }\n\t\t</HStack>\n\t);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,SACCA,8CAA8C,IAAIC,gCAAgC,EAClFC,yBAAyB,IAAIC,WAAW,EACxCC,oBAAoB,IAAIC,MAAM,EAC9BC,IAAI,EACJC,OAAO,EACPC,YAAY,EACZC,MAAM,EACNC,mBAAmB,QACb,uBAAuB;AAC9B,SAASC,EAAE,QAAQ,iBAAiB;AACpC,SAASC,QAAQ,QAAQ,oBAAoB;AAC7C,SAASC,QAAQ,QAAQ,kBAAkB;;AAE3C;AACA;AACA;AACA,SACCC,WAAW,EACXC,wBAAwB,EACxBC,8BAA8B,EAC9BC,6BAA6B,EAC7BC,wBAAwB,EACxBC,aAAa,EACbC,4BAA4B,QACtB,SAAS;AAChB,SACCC,OAAO,EACPC,KAAK,EACLC,uBAAuB,EACvBC,wBAAwB,EACxBC,sBAAsB,QAChB,aAAa;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAErB,eAAe,SAASC,kBAAkBA,CAAE;EAC3CC,MAAM;EACNC,QAAQ;EACRC,aAAa;EACbC,gBAAgB;EAChB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CAAE,0BAA2B,CAClC;MACD0E,IAAI,EAAGxE,QAAU;MACjB6F,OAAO,EAAGA,CAAA,KAAM;QACfvC,yBAAyB,CAAE,CAAED,sBAAuB,CAAC;MACtD,CAAG;MACHyC,SAAS,EAAGzC,sBAAwB;MACpCiB,IAAI,EAAC,OAAO;MACZM,SAAS,EAAC,iDAAiD;MAC3DmB,QAAQ,EAAG;IAAI,CACf,CACD;EAAA,CACM,CAAC;AAEX","ignoreList":[]}
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/components/border-radius-control/single-input-control.js"],
|
|
4
|
+
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport {\n\t__experimentalParseQuantityAndUnitFromRawValue as parseQuantityAndUnitFromRawValue,\n\t__experimentalUnitControl as UnitControl,\n\t__experimentalHStack as HStack,\n\tIcon,\n\tTooltip,\n\tRangeControl,\n\tButton,\n\tCustomSelectControl,\n} from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { useState } from '@wordpress/element';\nimport { settings } from '@wordpress/icons';\n\n/**\n * Internal dependencies\n */\nimport {\n\tgetAllValue,\n\tgetCustomValueFromPreset,\n\tgetPresetValueFromControlValue,\n\tgetPresetValueFromCustomValue,\n\tgetSliderValueFromPreset,\n\tisValuePreset,\n\tconvertPresetsToCustomValues,\n} from './utils';\nimport {\n\tCORNERS,\n\tICONS,\n\tMIN_BORDER_RADIUS_VALUE,\n\tMAX_BORDER_RADIUS_VALUES,\n\tRANGE_CONTROL_MAX_SIZE,\n} from './constants';\n\nexport default function SingleInputControl( {\n\tcorner,\n\tonChange,\n\tselectedUnits,\n\tsetSelectedUnits,\n\tvalues: valuesProp,\n\tunits,\n\tpresets,\n} ) {\n\tconst changeCornerValue = ( validatedValue ) => {\n\t\tif ( corner === 'all' ) {\n\t\t\tonChange( {\n\t\t\t\ttopLeft: validatedValue,\n\t\t\t\ttopRight: validatedValue,\n\t\t\t\tbottomLeft: validatedValue,\n\t\t\t\tbottomRight: validatedValue,\n\t\t\t} );\n\t\t} else {\n\t\t\tonChange( {\n\t\t\t\t...values,\n\t\t\t\t[ corner ]: validatedValue,\n\t\t\t} );\n\t\t}\n\t};\n\n\tconst onChangeValue = ( next ) => {\n\t\tif ( ! onChange ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Filter out CSS-unit-only values to prevent invalid styles.\n\t\tconst isNumeric = ! isNaN( parseFloat( next ) );\n\t\tconst nextValue = isNumeric ? next : undefined;\n\t\tchangeCornerValue( nextValue );\n\t};\n\n\tconst onChangeUnit = ( next ) => {\n\t\tconst newUnits = { ...selectedUnits };\n\t\tif ( corner === 'all' ) {\n\t\t\tnewUnits.topLeft = next;\n\t\t\tnewUnits.topRight = next;\n\t\t\tnewUnits.bottomLeft = next;\n\t\t\tnewUnits.bottomRight = next;\n\t\t} else {\n\t\t\tnewUnits[ corner ] = next;\n\t\t}\n\t\tsetSelectedUnits( newUnits );\n\t};\n\n\t// For shorthand style & backwards compatibility, handle flat string value.\n\tconst values =\n\t\ttypeof valuesProp !== 'string'\n\t\t\t? valuesProp\n\t\t\t: {\n\t\t\t\t\ttopLeft: valuesProp,\n\t\t\t\t\ttopRight: valuesProp,\n\t\t\t\t\tbottomLeft: valuesProp,\n\t\t\t\t\tbottomRight: valuesProp,\n\t\t\t };\n\n\t// For 'all' corner, convert presets to custom values before calling getAllValue\n\t// For individual corners, check if the value should be converted to a preset\n\tlet value;\n\tif ( corner === 'all' ) {\n\t\tconst convertedValues = convertPresetsToCustomValues( values, presets );\n\t\tconst customValue = getAllValue( convertedValues );\n\t\tvalue = getPresetValueFromCustomValue( customValue, presets );\n\t} else {\n\t\tvalue = getPresetValueFromCustomValue( values[ corner ], presets );\n\t}\n\tconst resolvedPresetValue = isValuePreset( value )\n\t\t? getCustomValueFromPreset( value, presets )\n\t\t: value;\n\tconst [ parsedQuantity, parsedUnit ] =\n\t\tparseQuantityAndUnitFromRawValue( resolvedPresetValue );\n\tconst computedUnit = value\n\t\t? parsedUnit\n\t\t: selectedUnits[ corner ] || selectedUnits.flat || 'px';\n\tconst unitConfig =\n\t\tunits && units.find( ( item ) => item.value === computedUnit );\n\tconst step = unitConfig?.step || 1;\n\tconst [ showCustomValueControl, setShowCustomValueControl ] = useState(\n\t\tvalue !== undefined && ! isValuePreset( value )\n\t);\n\tconst showRangeControl = presets.length <= RANGE_CONTROL_MAX_SIZE;\n\tconst presetIndex = getSliderValueFromPreset( value, presets );\n\tconst rangeTooltip = ( newValue ) =>\n\t\tvalue === undefined ? undefined : presets[ newValue ]?.name;\n\tconst marks = presets\n\t\t.slice( 1, presets.length - 1 )\n\t\t.map( ( _newValue, index ) => ( {\n\t\t\tvalue: index + 1,\n\t\t\tlabel: undefined,\n\t\t} ) );\n\tconst hasPresets = marks.length > 0;\n\tlet options = [];\n\tif ( ! showRangeControl ) {\n\t\toptions = [\n\t\t\t...presets,\n\t\t\t{\n\t\t\t\tname: __( 'Custom' ),\n\t\t\t\tslug: 'custom',\n\t\t\t\tsize: resolvedPresetValue,\n\t\t\t},\n\t\t].map( ( size, index ) => ( {\n\t\t\tkey: index,\n\t\t\tname: size.name,\n\t\t} ) );\n\t}\n\tconst icon = ICONS[ corner ];\n\n\tconst handleSliderChange = ( next ) => {\n\t\tconst val =\n\t\t\tnext !== undefined ? `${ next }${ computedUnit }` : undefined;\n\t\tchangeCornerValue( val );\n\t};\n\n\t// Controls are wrapped in tooltips as visible labels aren't desired here.\n\t// Tooltip rendering also requires the UnitControl to be wrapped. See:\n\t// https://github.com/WordPress/gutenberg/pull/24966#issuecomment-685875026\n\treturn (\n\t\t<HStack>\n\t\t\t{ icon && (\n\t\t\t\t<Icon\n\t\t\t\t\tclassName=\"components-border-radius-control__icon\"\n\t\t\t\t\ticon={ icon }\n\t\t\t\t\tsize={ 24 }\n\t\t\t\t/>\n\t\t\t) }\n\t\t\t{ ( ! hasPresets || showCustomValueControl ) && (\n\t\t\t\t<div className=\"components-border-radius-control__input-controls-wrapper\">\n\t\t\t\t\t<Tooltip text={ CORNERS[ corner ] } placement=\"top\">\n\t\t\t\t\t\t<div className=\"components-border-radius-control__tooltip-wrapper\">\n\t\t\t\t\t\t\t<UnitControl\n\t\t\t\t\t\t\t\tclassName=\"components-border-radius-control__unit-control\"\n\t\t\t\t\t\t\t\taria-label={ CORNERS[ corner ] }\n\t\t\t\t\t\t\t\tvalue={ [ parsedQuantity, computedUnit ].join(\n\t\t\t\t\t\t\t\t\t''\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\tonChange={ onChangeValue }\n\t\t\t\t\t\t\t\tonUnitChange={ onChangeUnit }\n\t\t\t\t\t\t\t\tsize=\"__unstable-large\"\n\t\t\t\t\t\t\t\tmin={ MIN_BORDER_RADIUS_VALUE }\n\t\t\t\t\t\t\t\tunits={ units }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</Tooltip>\n\t\t\t\t\t<RangeControl\n\t\t\t\t\t\t__next40pxDefaultSize\n\t\t\t\t\t\tlabel={ __( 'Border radius' ) }\n\t\t\t\t\t\thideLabelFromVision\n\t\t\t\t\t\tclassName=\"components-border-radius-control__range-control\"\n\t\t\t\t\t\tvalue={ parsedQuantity ?? '' }\n\t\t\t\t\t\tmin={ MIN_BORDER_RADIUS_VALUE }\n\t\t\t\t\t\tmax={ MAX_BORDER_RADIUS_VALUES[ computedUnit ] }\n\t\t\t\t\t\tinitialPosition={ 0 }\n\t\t\t\t\t\twithInputField={ false }\n\t\t\t\t\t\tonChange={ handleSliderChange }\n\t\t\t\t\t\tstep={ step }\n\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t/>\n\t\t\t\t</div>\n\t\t\t) }\n\t\t\t{ hasPresets && showRangeControl && ! showCustomValueControl && (\n\t\t\t\t<RangeControl\n\t\t\t\t\t__next40pxDefaultSize\n\t\t\t\t\tclassName=\"components-border-radius-control__range-control\"\n\t\t\t\t\tvalue={ presetIndex }\n\t\t\t\t\tonChange={ ( newSize ) => {\n\t\t\t\t\t\tchangeCornerValue(\n\t\t\t\t\t\t\tgetPresetValueFromControlValue(\n\t\t\t\t\t\t\t\tnewSize,\n\t\t\t\t\t\t\t\t'range',\n\t\t\t\t\t\t\t\tpresets\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t);\n\t\t\t\t\t} }\n\t\t\t\t\twithInputField={ false }\n\t\t\t\t\taria-valuenow={ presetIndex }\n\t\t\t\t\taria-valuetext={ presets[ presetIndex ]?.name }\n\t\t\t\t\trenderTooltipContent={ rangeTooltip }\n\t\t\t\t\tmin={ 0 }\n\t\t\t\t\tmax={ presets.length - 1 }\n\t\t\t\t\tmarks={ marks }\n\t\t\t\t\tlabel={ CORNERS[ corner ] }\n\t\t\t\t\thideLabelFromVision\n\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t/>\n\t\t\t) }\n\n\t\t\t{ ! showRangeControl && ! showCustomValueControl && (\n\t\t\t\t<CustomSelectControl\n\t\t\t\t\tclassName=\"components-border-radius-control__custom-select-control\"\n\t\t\t\t\tvalue={\n\t\t\t\t\t\toptions.find(\n\t\t\t\t\t\t\t( option ) => option.key === presetIndex\n\t\t\t\t\t\t) || options[ options.length - 1 ]\n\t\t\t\t\t}\n\t\t\t\t\tonChange={ ( selection ) => {\n\t\t\t\t\t\tif (\n\t\t\t\t\t\t\tselection.selectedItem.key ===\n\t\t\t\t\t\t\toptions.length - 1\n\t\t\t\t\t\t) {\n\t\t\t\t\t\t\tsetShowCustomValueControl( true );\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tchangeCornerValue(\n\t\t\t\t\t\t\t\tgetPresetValueFromControlValue(\n\t\t\t\t\t\t\t\t\tselection.selectedItem.key,\n\t\t\t\t\t\t\t\t\t'selectList',\n\t\t\t\t\t\t\t\t\tpresets\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\t\t\t\t\t} }\n\t\t\t\t\toptions={ options }\n\t\t\t\t\tlabel={ CORNERS[ corner ] }\n\t\t\t\t\thideLabelFromVision\n\t\t\t\t\tsize=\"__unstable-large\"\n\t\t\t\t/>\n\t\t\t) }\n\t\t\t{ hasPresets && (\n\t\t\t\t<Button\n\t\t\t\t\tlabel={\n\t\t\t\t\t\tshowCustomValueControl\n\t\t\t\t\t\t\t? __( 'Use border radius preset' )\n\t\t\t\t\t\t\t: __( 'Set custom border radius' )\n\t\t\t\t\t}\n\t\t\t\t\ticon={ settings }\n\t\t\t\t\tonClick={ () => {\n\t\t\t\t\t\tsetShowCustomValueControl( ! showCustomValueControl );\n\t\t\t\t\t} }\n\t\t\t\t\tisPressed={ showCustomValueControl }\n\t\t\t\t\tsize=\"small\"\n\t\t\t\t\tclassName=\"components-border-radius-control__custom-toggle\"\n\t\t\t\t\ticonSize={ 24 }\n\t\t\t\t/>\n\t\t\t) }\n\t\t</HStack>\n\t);\n}\n"],
|
|
5
|
+
"mappings": "AAgKI,cAOA,YAPA;AA7JJ;AAAA,EACC,kDAAkD;AAAA,EAClD,6BAA6B;AAAA,EAC7B,wBAAwB;AAAA,EACxB;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACM;AACP,SAAS,UAAU;AACnB,SAAS,gBAAgB;AACzB,SAAS,gBAAgB;AAKzB;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACM;AACP;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACM;AAEQ,SAAR,mBAAqC;AAAA,EAC3C;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,QAAQ;AAAA,EACR;AAAA,EACA;AACD,GAAI;AACH,QAAM,oBAAoB,CAAE,mBAAoB;AAC/C,QAAK,WAAW,OAAQ;AACvB,eAAU;AAAA,QACT,SAAS;AAAA,QACT,UAAU;AAAA,QACV,YAAY;AAAA,QACZ,aAAa;AAAA,MACd,CAAE;AAAA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A,QACA;AAAA,QACA,OAAQ,QAAS,MAAO;AAAA,QACxB,qBAAmB;AAAA,QACnB,MAAK;AAAA;AAAA,IACN;AAAA,IAEC,cACD;AAAA,MAAC;AAAA;AAAA,QACA,OACC,yBACG,GAAI,0BAA2B,IAC/B,GAAI,0BAA2B;AAAA,QAEnC,MAAO;AAAA,QACP,SAAU,MAAM;AACf,oCAA2B,CAAE,sBAAuB;AAAA,QACrD;AAAA,QACA,WAAY;AAAA,QACZ,MAAK;AAAA,QACL,WAAU;AAAA,QACV,UAAW;AAAA;AAAA,IACZ;AAAA,KAEF;AAEF;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
|
@@ -1,82 +1,35 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
*/
|
|
4
|
-
import { __experimentalParseQuantityAndUnitFromRawValue as parseQuantityAndUnitFromRawValue } from '@wordpress/components';
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* Gets the (non-undefined) item with the highest occurrence within an array
|
|
8
|
-
* Based in part on: https://stackoverflow.com/a/20762713
|
|
9
|
-
*
|
|
10
|
-
* Undefined values are always sorted to the end by `sort`, so this function
|
|
11
|
-
* returns the first element, to always prioritize real values over undefined
|
|
12
|
-
* values.
|
|
13
|
-
*
|
|
14
|
-
* See: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#description
|
|
15
|
-
*
|
|
16
|
-
* @param {Array<any>} inputArray Array of items to check.
|
|
17
|
-
* @return {any} The item with the most occurrences.
|
|
18
|
-
*/
|
|
19
|
-
export function mode(inputArray) {
|
|
1
|
+
import { __experimentalParseQuantityAndUnitFromRawValue as parseQuantityAndUnitFromRawValue } from "@wordpress/components";
|
|
2
|
+
function mode(inputArray) {
|
|
20
3
|
const arr = [...inputArray];
|
|
21
|
-
return arr.sort(
|
|
4
|
+
return arr.sort(
|
|
5
|
+
(a, b) => inputArray.filter((v) => v === b).length - inputArray.filter((v) => v === a).length
|
|
6
|
+
).shift();
|
|
22
7
|
}
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
*
|
|
27
|
-
* - If a single flat border radius is set, its unit will be used
|
|
28
|
-
* - If individual corner selections, the most common of those will be used
|
|
29
|
-
* - Failing any unit selections a default of 'px' is returned.
|
|
30
|
-
*
|
|
31
|
-
* @param {Object} selectedUnits Unit selections for flat radius & each corner.
|
|
32
|
-
* @return {string} Most common CSS unit from current selections. Default: `px`.
|
|
33
|
-
*/
|
|
34
|
-
export function getAllUnit(selectedUnits = {}) {
|
|
35
|
-
const {
|
|
36
|
-
flat,
|
|
37
|
-
...cornerUnits
|
|
38
|
-
} = selectedUnits;
|
|
39
|
-
return flat || mode(Object.values(cornerUnits).filter(Boolean)) || 'px';
|
|
8
|
+
function getAllUnit(selectedUnits = {}) {
|
|
9
|
+
const { flat, ...cornerUnits } = selectedUnits;
|
|
10
|
+
return flat || mode(Object.values(cornerUnits).filter(Boolean)) || "px";
|
|
40
11
|
}
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
* Gets the 'all' input value and unit from values data.
|
|
44
|
-
*
|
|
45
|
-
* @param {Object|string} values Radius values.
|
|
46
|
-
* @return {string} A value + unit for the 'all' input.
|
|
47
|
-
*/
|
|
48
|
-
export function getAllValue(values = {}) {
|
|
49
|
-
/**
|
|
50
|
-
* Border radius support was originally a single pixel value.
|
|
51
|
-
*
|
|
52
|
-
* To maintain backwards compatibility treat this case as the all value.
|
|
53
|
-
*/
|
|
54
|
-
if (typeof values === 'string') {
|
|
12
|
+
function getAllValue(values = {}) {
|
|
13
|
+
if (typeof values === "string") {
|
|
55
14
|
return values;
|
|
56
15
|
}
|
|
57
|
-
const parsedQuantitiesAndUnits = Object.values(values).map(
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
const
|
|
16
|
+
const parsedQuantitiesAndUnits = Object.values(values).map(
|
|
17
|
+
(value2) => parseQuantityAndUnitFromRawValue(value2)
|
|
18
|
+
);
|
|
19
|
+
const allValues = parsedQuantitiesAndUnits.map(
|
|
20
|
+
(value2) => value2[0] ?? ""
|
|
21
|
+
);
|
|
22
|
+
const allUnits = parsedQuantitiesAndUnits.map((value2) => value2[1]);
|
|
23
|
+
const value = allValues.every((v) => v === allValues[0]) ? allValues[0] : "";
|
|
64
24
|
const unit = mode(allUnits);
|
|
65
|
-
const allValue = value === 0 || value ? `${value}${unit ||
|
|
25
|
+
const allValue = value === 0 || value ? `${value}${unit || ""}` : void 0;
|
|
66
26
|
return allValue;
|
|
67
27
|
}
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
* Checks to determine if values are mixed.
|
|
71
|
-
*
|
|
72
|
-
* @param {Object} values Radius values.
|
|
73
|
-
* @return {boolean} Whether values are mixed.
|
|
74
|
-
*/
|
|
75
|
-
export function hasMixedValues(values = {}) {
|
|
76
|
-
if (typeof values === 'string') {
|
|
28
|
+
function hasMixedValues(values = {}) {
|
|
29
|
+
if (typeof values === "string") {
|
|
77
30
|
return false;
|
|
78
31
|
}
|
|
79
|
-
if (!values || typeof values !==
|
|
32
|
+
if (!values || typeof values !== "object") {
|
|
80
33
|
return false;
|
|
81
34
|
}
|
|
82
35
|
const cornerValues = Object.values(values);
|
|
@@ -84,171 +37,106 @@ export function hasMixedValues(values = {}) {
|
|
|
84
37
|
return false;
|
|
85
38
|
}
|
|
86
39
|
const firstValue = cornerValues[0];
|
|
87
|
-
|
|
88
|
-
// Check if all values are exactly the same (including undefined)
|
|
89
|
-
const allSame = cornerValues.every(value => value === firstValue);
|
|
40
|
+
const allSame = cornerValues.every((value) => value === firstValue);
|
|
90
41
|
return !allSame;
|
|
91
42
|
}
|
|
92
|
-
|
|
93
|
-
/**
|
|
94
|
-
* Checks to determine if values are defined.
|
|
95
|
-
*
|
|
96
|
-
* @param {Object} values Radius values.
|
|
97
|
-
* @return {boolean} Whether values are mixed.
|
|
98
|
-
*/
|
|
99
|
-
export function hasDefinedValues(values) {
|
|
43
|
+
function hasDefinedValues(values) {
|
|
100
44
|
if (!values) {
|
|
101
45
|
return false;
|
|
102
46
|
}
|
|
103
|
-
|
|
104
|
-
// A string value represents a shorthand value.
|
|
105
|
-
if (typeof values === 'string') {
|
|
47
|
+
if (typeof values === "string") {
|
|
106
48
|
return true;
|
|
107
49
|
}
|
|
108
|
-
|
|
109
|
-
// An object represents longhand border radius values, if any are set
|
|
110
|
-
// flag values as being defined.
|
|
111
|
-
const filteredValues = Object.values(values).filter(value => {
|
|
50
|
+
const filteredValues = Object.values(values).filter((value) => {
|
|
112
51
|
return !!value || value === 0;
|
|
113
52
|
});
|
|
114
53
|
return !!filteredValues.length;
|
|
115
54
|
}
|
|
116
|
-
|
|
117
|
-
/**
|
|
118
|
-
* Checks is given value is a radius preset.
|
|
119
|
-
*
|
|
120
|
-
* @param {string} value Value to check
|
|
121
|
-
*
|
|
122
|
-
* @return {boolean} Return true if value is string in format var:preset|border-radius|.
|
|
123
|
-
*/
|
|
124
|
-
export function isValuePreset(value) {
|
|
55
|
+
function isValuePreset(value) {
|
|
125
56
|
if (!value?.includes) {
|
|
126
57
|
return false;
|
|
127
58
|
}
|
|
128
|
-
return value ===
|
|
59
|
+
return value === "0" || value.includes("var:preset|border-radius|");
|
|
129
60
|
}
|
|
130
|
-
|
|
131
|
-
/**
|
|
132
|
-
* Returns the slug section of the given preset string.
|
|
133
|
-
*
|
|
134
|
-
* @param {string} value Value to extract slug from.
|
|
135
|
-
*
|
|
136
|
-
* @return {string|undefined} The int value of the slug from given preset.
|
|
137
|
-
*/
|
|
138
|
-
export function getPresetSlug(value) {
|
|
61
|
+
function getPresetSlug(value) {
|
|
139
62
|
if (!value) {
|
|
140
63
|
return;
|
|
141
64
|
}
|
|
142
|
-
if (value ===
|
|
65
|
+
if (value === "0" || value === "default") {
|
|
143
66
|
return value;
|
|
144
67
|
}
|
|
145
68
|
const slug = value.match(/var:preset\|border-radius\|(.+)/);
|
|
146
|
-
return slug ? slug[1] :
|
|
69
|
+
return slug ? slug[1] : void 0;
|
|
147
70
|
}
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
* Converts radius preset value into a Range component value .
|
|
151
|
-
*
|
|
152
|
-
* @param {string} presetValue Value to convert to Range value.
|
|
153
|
-
* @param {Array} presets Array of current radius preset value objects.
|
|
154
|
-
*
|
|
155
|
-
* @return {number} The int value for use in Range control.
|
|
156
|
-
*/
|
|
157
|
-
export function getSliderValueFromPreset(presetValue, presets) {
|
|
158
|
-
if (presetValue === undefined) {
|
|
71
|
+
function getSliderValueFromPreset(presetValue, presets) {
|
|
72
|
+
if (presetValue === void 0) {
|
|
159
73
|
return 0;
|
|
160
74
|
}
|
|
161
|
-
const slug = parseFloat(presetValue, 10) === 0 ?
|
|
162
|
-
const sliderValue = presets.findIndex(size => {
|
|
75
|
+
const slug = parseFloat(presetValue, 10) === 0 ? "0" : getPresetSlug(presetValue);
|
|
76
|
+
const sliderValue = presets.findIndex((size) => {
|
|
163
77
|
return String(size.slug) === slug;
|
|
164
78
|
});
|
|
165
|
-
|
|
166
|
-
// Returning NaN rather than undefined as undefined makes range control thumb sit in center
|
|
167
79
|
return sliderValue !== -1 ? sliderValue : NaN;
|
|
168
80
|
}
|
|
169
|
-
|
|
170
|
-
/**
|
|
171
|
-
* Converts a preset into a custom value.
|
|
172
|
-
*
|
|
173
|
-
* @param {string} value Value to convert
|
|
174
|
-
* @param {Array} presets Array of the current radius preset objects
|
|
175
|
-
*
|
|
176
|
-
* @return {string} Mapping of the radius preset to its equivalent custom value.
|
|
177
|
-
*/
|
|
178
|
-
export function getCustomValueFromPreset(value, presets) {
|
|
81
|
+
function getCustomValueFromPreset(value, presets) {
|
|
179
82
|
if (!isValuePreset(value)) {
|
|
180
83
|
return value;
|
|
181
84
|
}
|
|
182
|
-
const slug = parseFloat(value, 10) === 0 ?
|
|
183
|
-
const radiusSize = presets.find(size => String(size.slug) === slug);
|
|
85
|
+
const slug = parseFloat(value, 10) === 0 ? "0" : getPresetSlug(value);
|
|
86
|
+
const radiusSize = presets.find((size) => String(size.slug) === slug);
|
|
184
87
|
return radiusSize?.size;
|
|
185
88
|
}
|
|
186
|
-
|
|
187
|
-
/**
|
|
188
|
-
* Converts a control value into a preset value.
|
|
189
|
-
*
|
|
190
|
-
* @param {number} controlValue to convert to preset value.
|
|
191
|
-
* @param {string} controlType Type of control
|
|
192
|
-
* @param {Array} presets Array of current radius preset value objects.
|
|
193
|
-
*
|
|
194
|
-
* @return {string} The custom value for use in Range control.
|
|
195
|
-
*/
|
|
196
|
-
export function getPresetValueFromControlValue(controlValue, controlType, presets) {
|
|
89
|
+
function getPresetValueFromControlValue(controlValue, controlType, presets) {
|
|
197
90
|
const size = parseInt(controlValue, 10);
|
|
198
|
-
if (controlType ===
|
|
91
|
+
if (controlType === "selectList") {
|
|
199
92
|
if (size === 0) {
|
|
200
|
-
return
|
|
93
|
+
return void 0;
|
|
201
94
|
}
|
|
202
95
|
} else if (size === 0) {
|
|
203
|
-
return
|
|
96
|
+
return "0";
|
|
204
97
|
}
|
|
205
98
|
return `var:preset|border-radius|${presets[controlValue]?.slug}`;
|
|
206
99
|
}
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
* Converts a custom value to preset value if one can be found.
|
|
210
|
-
*
|
|
211
|
-
* Returns value as-is if no match is found.
|
|
212
|
-
*
|
|
213
|
-
* @param {string} value Value to convert
|
|
214
|
-
* @param {Array} presets Array of the current border radius preset objects
|
|
215
|
-
*
|
|
216
|
-
* @return {string} The preset value if it can be found.
|
|
217
|
-
*/
|
|
218
|
-
export function getPresetValueFromCustomValue(value, presets) {
|
|
219
|
-
// Return value as-is if it is undefined or is already a preset, or '0';
|
|
220
|
-
if (!value || isValuePreset(value) || value === '0') {
|
|
100
|
+
function getPresetValueFromCustomValue(value, presets) {
|
|
101
|
+
if (!value || isValuePreset(value) || value === "0") {
|
|
221
102
|
return value;
|
|
222
103
|
}
|
|
223
|
-
const spacingMatch = presets.find(
|
|
104
|
+
const spacingMatch = presets.find(
|
|
105
|
+
(size) => String(size.size) === String(value)
|
|
106
|
+
);
|
|
224
107
|
if (spacingMatch?.slug) {
|
|
225
108
|
return `var:preset|border-radius|${spacingMatch.slug}`;
|
|
226
109
|
}
|
|
227
110
|
return value;
|
|
228
111
|
}
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
* Converts all preset values in a values object to their custom equivalents.
|
|
232
|
-
*
|
|
233
|
-
* @param {Object} values Values object to convert
|
|
234
|
-
* @param {Array} presets Array of current border radius preset objects
|
|
235
|
-
*
|
|
236
|
-
* @return {Object} Values with presets converted to custom values
|
|
237
|
-
*/
|
|
238
|
-
export function convertPresetsToCustomValues(values, presets) {
|
|
239
|
-
if (!values || typeof values !== 'object') {
|
|
112
|
+
function convertPresetsToCustomValues(values, presets) {
|
|
113
|
+
if (!values || typeof values !== "object") {
|
|
240
114
|
return values;
|
|
241
115
|
}
|
|
242
116
|
const converted = {};
|
|
243
|
-
Object.keys(values).forEach(key => {
|
|
117
|
+
Object.keys(values).forEach((key) => {
|
|
244
118
|
const value = values[key];
|
|
245
119
|
if (isValuePreset(value)) {
|
|
246
120
|
const customValue = getCustomValueFromPreset(value, presets);
|
|
247
|
-
converted[key] = customValue !==
|
|
121
|
+
converted[key] = customValue !== void 0 ? customValue : value;
|
|
248
122
|
} else {
|
|
249
123
|
converted[key] = value;
|
|
250
124
|
}
|
|
251
125
|
});
|
|
252
126
|
return converted;
|
|
253
127
|
}
|
|
254
|
-
|
|
128
|
+
export {
|
|
129
|
+
convertPresetsToCustomValues,
|
|
130
|
+
getAllUnit,
|
|
131
|
+
getAllValue,
|
|
132
|
+
getCustomValueFromPreset,
|
|
133
|
+
getPresetSlug,
|
|
134
|
+
getPresetValueFromControlValue,
|
|
135
|
+
getPresetValueFromCustomValue,
|
|
136
|
+
getSliderValueFromPreset,
|
|
137
|
+
hasDefinedValues,
|
|
138
|
+
hasMixedValues,
|
|
139
|
+
isValuePreset,
|
|
140
|
+
mode
|
|
141
|
+
};
|
|
142
|
+
//# sourceMappingURL=utils.js.map
|
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{"version":3,"names":["__experimentalParseQuantityAndUnitFromRawValue","parseQuantityAndUnitFromRawValue","mode","inputArray","arr","sort","a","b","filter","v","length","shift","getAllUnit","selectedUnits","flat","cornerUnits","Object","values","Boolean","getAllValue","parsedQuantitiesAndUnits","map","value","allValues","_value$","allUnits","every","unit","allValue","undefined","hasMixedValues","cornerValues","firstValue","allSame","hasDefinedValues","filteredValues","isValuePreset","includes","getPresetSlug","slug","match","getSliderValueFromPreset","presetValue","presets","parseFloat","sliderValue","findIndex","size","String","NaN","getCustomValueFromPreset","radiusSize","find","getPresetValueFromControlValue","controlValue","controlType","parseInt","getPresetValueFromCustomValue","spacingMatch","convertPresetsToCustomValues","converted","keys","forEach","key","customValue"],"sources":["@wordpress/block-editor/src/components/border-radius-control/utils.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { __experimentalParseQuantityAndUnitFromRawValue as parseQuantityAndUnitFromRawValue } from '@wordpress/components';\n\n/**\n * Gets the (non-undefined) item with the highest occurrence within an array\n * Based in part on: https://stackoverflow.com/a/20762713\n *\n * Undefined values are always sorted to the end by `sort`, so this function\n * returns the first element, to always prioritize real values over undefined\n * values.\n *\n * See: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#description\n *\n * @param {Array<any>} inputArray Array of items to check.\n * @return {any} The item with the most occurrences.\n */\nexport function mode( inputArray ) {\n\tconst arr = [ ...inputArray ];\n\treturn arr\n\t\t.sort(\n\t\t\t( a, b ) =>\n\t\t\t\tinputArray.filter( ( v ) => v === b ).length -\n\t\t\t\tinputArray.filter( ( v ) => v === a ).length\n\t\t)\n\t\t.shift();\n}\n\n/**\n * Returns the most common CSS unit from the current CSS unit selections.\n *\n * - If a single flat border radius is set, its unit will be used\n * - If individual corner selections, the most common of those will be used\n * - Failing any unit selections a default of 'px' is returned.\n *\n * @param {Object} selectedUnits Unit selections for flat radius & each corner.\n * @return {string} Most common CSS unit from current selections. Default: `px`.\n */\nexport function getAllUnit( selectedUnits = {} ) {\n\tconst { flat, ...cornerUnits } = selectedUnits;\n\treturn (\n\t\tflat || mode( Object.values( cornerUnits ).filter( Boolean ) ) || 'px'\n\t);\n}\n\n/**\n * Gets the 'all' input value and unit from values data.\n *\n * @param {Object|string} values Radius values.\n * @return {string} A value + unit for the 'all' input.\n */\nexport function getAllValue( values = {} ) {\n\t/**\n\t * Border radius support was originally a single pixel value.\n\t *\n\t * To maintain backwards compatibility treat this case as the all value.\n\t */\n\tif ( typeof values === 'string' ) {\n\t\treturn values;\n\t}\n\n\tconst parsedQuantitiesAndUnits = Object.values( values ).map( ( value ) =>\n\t\tparseQuantityAndUnitFromRawValue( value )\n\t);\n\n\tconst allValues = parsedQuantitiesAndUnits.map(\n\t\t( value ) => value[ 0 ] ?? ''\n\t);\n\tconst allUnits = parsedQuantitiesAndUnits.map( ( value ) => value[ 1 ] );\n\n\tconst value = allValues.every( ( v ) => v === allValues[ 0 ] )\n\t\t? allValues[ 0 ]\n\t\t: '';\n\tconst unit = mode( allUnits );\n\n\tconst allValue =\n\t\tvalue === 0 || value ? `${ value }${ unit || '' }` : undefined;\n\n\treturn allValue;\n}\n\n/**\n * Checks to determine if values are mixed.\n *\n * @param {Object} values Radius values.\n * @return {boolean} Whether values are mixed.\n */\nexport function hasMixedValues( values = {} ) {\n\tif ( typeof values === 'string' ) {\n\t\treturn false;\n\t}\n\n\tif ( ! values || typeof values !== 'object' ) {\n\t\treturn false;\n\t}\n\n\tconst cornerValues = Object.values( values );\n\n\tif ( cornerValues.length === 0 ) {\n\t\treturn false;\n\t}\n\n\tconst firstValue = cornerValues[ 0 ];\n\n\t// Check if all values are exactly the same (including undefined)\n\tconst allSame = cornerValues.every( ( value ) => value === firstValue );\n\n\treturn ! allSame;\n}\n\n/**\n * Checks to determine if values are defined.\n *\n * @param {Object} values Radius values.\n * @return {boolean} Whether values are mixed.\n */\nexport function hasDefinedValues( values ) {\n\tif ( ! values ) {\n\t\treturn false;\n\t}\n\n\t// A string value represents a shorthand value.\n\tif ( typeof values === 'string' ) {\n\t\treturn true;\n\t}\n\n\t// An object represents longhand border radius values, if any are set\n\t// flag values as being defined.\n\tconst filteredValues = Object.values( values ).filter( ( value ) => {\n\t\treturn !! value || value === 0;\n\t} );\n\n\treturn !! filteredValues.length;\n}\n\n/**\n * Checks is given value is a radius preset.\n *\n * @param {string} value Value to check\n *\n * @return {boolean} Return true if value is string in format var:preset|border-radius|.\n */\nexport function isValuePreset( value ) {\n\tif ( ! value?.includes ) {\n\t\treturn false;\n\t}\n\treturn value === '0' || value.includes( 'var:preset|border-radius|' );\n}\n\n/**\n * Returns the slug section of the given preset string.\n *\n * @param {string} value Value to extract slug from.\n *\n * @return {string|undefined} The int value of the slug from given preset.\n */\nexport function getPresetSlug( value ) {\n\tif ( ! value ) {\n\t\treturn;\n\t}\n\n\tif ( value === '0' || value === 'default' ) {\n\t\treturn value;\n\t}\n\n\tconst slug = value.match( /var:preset\\|border-radius\\|(.+)/ );\n\n\treturn slug ? slug[ 1 ] : undefined;\n}\n\n/**\n * Converts radius preset value into a Range component value .\n *\n * @param {string} presetValue Value to convert to Range value.\n * @param {Array} presets Array of current radius preset value objects.\n *\n * @return {number} The int value for use in Range control.\n */\nexport function getSliderValueFromPreset( presetValue, presets ) {\n\tif ( presetValue === undefined ) {\n\t\treturn 0;\n\t}\n\tconst slug =\n\t\tparseFloat( presetValue, 10 ) === 0\n\t\t\t? '0'\n\t\t\t: getPresetSlug( presetValue );\n\tconst sliderValue = presets.findIndex( ( size ) => {\n\t\treturn String( size.slug ) === slug;\n\t} );\n\n\t// Returning NaN rather than undefined as undefined makes range control thumb sit in center\n\treturn sliderValue !== -1 ? sliderValue : NaN;\n}\n\n/**\n * Converts a preset into a custom value.\n *\n * @param {string} value Value to convert\n * @param {Array} presets Array of the current radius preset objects\n *\n * @return {string} Mapping of the radius preset to its equivalent custom value.\n */\nexport function getCustomValueFromPreset( value, presets ) {\n\tif ( ! isValuePreset( value ) ) {\n\t\treturn value;\n\t}\n\n\tconst slug = parseFloat( value, 10 ) === 0 ? '0' : getPresetSlug( value );\n\tconst radiusSize = presets.find( ( size ) => String( size.slug ) === slug );\n\n\treturn radiusSize?.size;\n}\n\n/**\n * Converts a control value into a preset value.\n *\n * @param {number} controlValue to convert to preset value.\n * @param {string} controlType Type of control\n * @param {Array} presets Array of current radius preset value objects.\n *\n * @return {string} The custom value for use in Range control.\n */\nexport function getPresetValueFromControlValue(\n\tcontrolValue,\n\tcontrolType,\n\tpresets\n) {\n\tconst size = parseInt( controlValue, 10 );\n\tif ( controlType === 'selectList' ) {\n\t\tif ( size === 0 ) {\n\t\t\treturn undefined;\n\t\t}\n\t} else if ( size === 0 ) {\n\t\treturn '0';\n\t}\n\n\treturn `var:preset|border-radius|${ presets[ controlValue ]?.slug }`;\n}\n\n/**\n * Converts a custom value to preset value if one can be found.\n *\n * Returns value as-is if no match is found.\n *\n * @param {string} value Value to convert\n * @param {Array} presets Array of the current border radius preset objects\n *\n * @return {string} The preset value if it can be found.\n */\nexport function getPresetValueFromCustomValue( value, presets ) {\n\t// Return value as-is if it is undefined or is already a preset, or '0';\n\tif ( ! value || isValuePreset( value ) || value === '0' ) {\n\t\treturn value;\n\t}\n\n\tconst spacingMatch = presets.find(\n\t\t( size ) => String( size.size ) === String( value )\n\t);\n\n\tif ( spacingMatch?.slug ) {\n\t\treturn `var:preset|border-radius|${ spacingMatch.slug }`;\n\t}\n\n\treturn value;\n}\n\n/**\n * Converts all preset values in a values object to their custom equivalents.\n *\n * @param {Object} values Values object to convert\n * @param {Array} presets Array of current border radius preset objects\n *\n * @return {Object} Values with presets converted to custom values\n */\nexport function convertPresetsToCustomValues( values, presets ) {\n\tif ( ! values || typeof values !== 'object' ) {\n\t\treturn values;\n\t}\n\n\tconst converted = {};\n\tObject.keys( values ).forEach( ( key ) => {\n\t\tconst value = values[ key ];\n\t\tif ( isValuePreset( value ) ) {\n\t\t\tconst customValue = getCustomValueFromPreset( value, presets );\n\t\t\tconverted[ key ] = customValue !== undefined ? customValue : value;\n\t\t} else {\n\t\t\tconverted[ key ] = value;\n\t\t}\n\t} );\n\n\treturn converted;\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,8CAA8C,IAAIC,gCAAgC,QAAQ,uBAAuB;;AAE1H;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,IAAIA,CAAEC,UAAU,EAAG;EAClC,MAAMC,GAAG,GAAG,CAAE,GAAGD,UAAU,CAAE;EAC7B,OAAOC,GAAG,CACRC,IAAI,CACJ,CAAEC,CAAC,EAAEC,CAAC,KACLJ,UAAU,CAACK,MAAM,CAAIC,CAAC,IAAMA,CAAC,KAAKF,CAAE,CAAC,CAACG,MAAM,GAC5CP,UAAU,CAACK,MAAM,CAAIC,CAAC,IAAMA,CAAC,KAAKH,CAAE,CAAC,CAACI,MACxC,CAAC,CACAC,KAAK,CAAC,CAAC;AACV;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,UAAUA,CAAEC,aAAa,GAAG,CAAC,CAAC,EAAG;EAChD,MAAM;IAAEC,IAAI;IAAE,GAAGC;EAAY,CAAC,GAAGF,aAAa;EAC9C,OACCC,IAAI,IAAIZ,IAAI,CAAEc,MAAM,CAACC,MAAM,CAAEF,WAAY,CAAC,CAACP,MAAM,CAAEU,OAAQ,CAAE,CAAC,IAAI,IAAI;AAExE;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,WAAWA,CAAEF,MAAM,GAAG,CAAC,CAAC,EAAG;EAC1C;AACD;AACA;AACA;AACA;EACC,IAAK,OAAOA,MAAM,KAAK,QAAQ,EAAG;IACjC,OAAOA,MAAM;EACd;EAEA,MAAMG,wBAAwB,GAAGJ,MAAM,CAACC,MAAM,CAAEA,MAAO,CAAC,CAACI,GAAG,CAAIC,KAAK,IACpErB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components/border-radius-control/utils.js"],
|
|
4
|
+
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { __experimentalParseQuantityAndUnitFromRawValue as parseQuantityAndUnitFromRawValue } from '@wordpress/components';\n\n/**\n * Gets the (non-undefined) item with the highest occurrence within an array\n * Based in part on: https://stackoverflow.com/a/20762713\n *\n * Undefined values are always sorted to the end by `sort`, so this function\n * returns the first element, to always prioritize real values over undefined\n * values.\n *\n * See: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#description\n *\n * @param {Array<any>} inputArray Array of items to check.\n * @return {any} The item with the most occurrences.\n */\nexport function mode( inputArray ) {\n\tconst arr = [ ...inputArray ];\n\treturn arr\n\t\t.sort(\n\t\t\t( a, b ) =>\n\t\t\t\tinputArray.filter( ( v ) => v === b ).length -\n\t\t\t\tinputArray.filter( ( v ) => v === a ).length\n\t\t)\n\t\t.shift();\n}\n\n/**\n * Returns the most common CSS unit from the current CSS unit selections.\n *\n * - If a single flat border radius is set, its unit will be used\n * - If individual corner selections, the most common of those will be used\n * - Failing any unit selections a default of 'px' is returned.\n *\n * @param {Object} selectedUnits Unit selections for flat radius & each corner.\n * @return {string} Most common CSS unit from current selections. Default: `px`.\n */\nexport function getAllUnit( selectedUnits = {} ) {\n\tconst { flat, ...cornerUnits } = selectedUnits;\n\treturn (\n\t\tflat || mode( Object.values( cornerUnits ).filter( Boolean ) ) || 'px'\n\t);\n}\n\n/**\n * Gets the 'all' input value and unit from values data.\n *\n * @param {Object|string} values Radius values.\n * @return {string} A value + unit for the 'all' input.\n */\nexport function getAllValue( values = {} ) {\n\t/**\n\t * Border radius support was originally a single pixel value.\n\t *\n\t * To maintain backwards compatibility treat this case as the all value.\n\t */\n\tif ( typeof values === 'string' ) {\n\t\treturn values;\n\t}\n\n\tconst parsedQuantitiesAndUnits = Object.values( values ).map( ( value ) =>\n\t\tparseQuantityAndUnitFromRawValue( value )\n\t);\n\n\tconst allValues = parsedQuantitiesAndUnits.map(\n\t\t( value ) => value[ 0 ] ?? ''\n\t);\n\tconst allUnits = parsedQuantitiesAndUnits.map( ( value ) => value[ 1 ] );\n\n\tconst value = allValues.every( ( v ) => v === allValues[ 0 ] )\n\t\t? allValues[ 0 ]\n\t\t: '';\n\tconst unit = mode( allUnits );\n\n\tconst allValue =\n\t\tvalue === 0 || value ? `${ value }${ unit || '' }` : undefined;\n\n\treturn allValue;\n}\n\n/**\n * Checks to determine if values are mixed.\n *\n * @param {Object} values Radius values.\n * @return {boolean} Whether values are mixed.\n */\nexport function hasMixedValues( values = {} ) {\n\tif ( typeof values === 'string' ) {\n\t\treturn false;\n\t}\n\n\tif ( ! values || typeof values !== 'object' ) {\n\t\treturn false;\n\t}\n\n\tconst cornerValues = Object.values( values );\n\n\tif ( cornerValues.length === 0 ) {\n\t\treturn false;\n\t}\n\n\tconst firstValue = cornerValues[ 0 ];\n\n\t// Check if all values are exactly the same (including undefined)\n\tconst allSame = cornerValues.every( ( value ) => value === firstValue );\n\n\treturn ! allSame;\n}\n\n/**\n * Checks to determine if values are defined.\n *\n * @param {Object} values Radius values.\n * @return {boolean} Whether values are mixed.\n */\nexport function hasDefinedValues( values ) {\n\tif ( ! values ) {\n\t\treturn false;\n\t}\n\n\t// A string value represents a shorthand value.\n\tif ( typeof values === 'string' ) {\n\t\treturn true;\n\t}\n\n\t// An object represents longhand border radius values, if any are set\n\t// flag values as being defined.\n\tconst filteredValues = Object.values( values ).filter( ( value ) => {\n\t\treturn !! value || value === 0;\n\t} );\n\n\treturn !! filteredValues.length;\n}\n\n/**\n * Checks is given value is a radius preset.\n *\n * @param {string} value Value to check\n *\n * @return {boolean} Return true if value is string in format var:preset|border-radius|.\n */\nexport function isValuePreset( value ) {\n\tif ( ! value?.includes ) {\n\t\treturn false;\n\t}\n\treturn value === '0' || value.includes( 'var:preset|border-radius|' );\n}\n\n/**\n * Returns the slug section of the given preset string.\n *\n * @param {string} value Value to extract slug from.\n *\n * @return {string|undefined} The int value of the slug from given preset.\n */\nexport function getPresetSlug( value ) {\n\tif ( ! value ) {\n\t\treturn;\n\t}\n\n\tif ( value === '0' || value === 'default' ) {\n\t\treturn value;\n\t}\n\n\tconst slug = value.match( /var:preset\\|border-radius\\|(.+)/ );\n\n\treturn slug ? slug[ 1 ] : undefined;\n}\n\n/**\n * Converts radius preset value into a Range component value .\n *\n * @param {string} presetValue Value to convert to Range value.\n * @param {Array} presets Array of current radius preset value objects.\n *\n * @return {number} The int value for use in Range control.\n */\nexport function getSliderValueFromPreset( presetValue, presets ) {\n\tif ( presetValue === undefined ) {\n\t\treturn 0;\n\t}\n\tconst slug =\n\t\tparseFloat( presetValue, 10 ) === 0\n\t\t\t? '0'\n\t\t\t: getPresetSlug( presetValue );\n\tconst sliderValue = presets.findIndex( ( size ) => {\n\t\treturn String( size.slug ) === slug;\n\t} );\n\n\t// Returning NaN rather than undefined as undefined makes range control thumb sit in center\n\treturn sliderValue !== -1 ? sliderValue : NaN;\n}\n\n/**\n * Converts a preset into a custom value.\n *\n * @param {string} value Value to convert\n * @param {Array} presets Array of the current radius preset objects\n *\n * @return {string} Mapping of the radius preset to its equivalent custom value.\n */\nexport function getCustomValueFromPreset( value, presets ) {\n\tif ( ! isValuePreset( value ) ) {\n\t\treturn value;\n\t}\n\n\tconst slug = parseFloat( value, 10 ) === 0 ? '0' : getPresetSlug( value );\n\tconst radiusSize = presets.find( ( size ) => String( size.slug ) === slug );\n\n\treturn radiusSize?.size;\n}\n\n/**\n * Converts a control value into a preset value.\n *\n * @param {number} controlValue to convert to preset value.\n * @param {string} controlType Type of control\n * @param {Array} presets Array of current radius preset value objects.\n *\n * @return {string} The custom value for use in Range control.\n */\nexport function getPresetValueFromControlValue(\n\tcontrolValue,\n\tcontrolType,\n\tpresets\n) {\n\tconst size = parseInt( controlValue, 10 );\n\tif ( controlType === 'selectList' ) {\n\t\tif ( size === 0 ) {\n\t\t\treturn undefined;\n\t\t}\n\t} else if ( size === 0 ) {\n\t\treturn '0';\n\t}\n\n\treturn `var:preset|border-radius|${ presets[ controlValue ]?.slug }`;\n}\n\n/**\n * Converts a custom value to preset value if one can be found.\n *\n * Returns value as-is if no match is found.\n *\n * @param {string} value Value to convert\n * @param {Array} presets Array of the current border radius preset objects\n *\n * @return {string} The preset value if it can be found.\n */\nexport function getPresetValueFromCustomValue( value, presets ) {\n\t// Return value as-is if it is undefined or is already a preset, or '0';\n\tif ( ! value || isValuePreset( value ) || value === '0' ) {\n\t\treturn value;\n\t}\n\n\tconst spacingMatch = presets.find(\n\t\t( size ) => String( size.size ) === String( value )\n\t);\n\n\tif ( spacingMatch?.slug ) {\n\t\treturn `var:preset|border-radius|${ spacingMatch.slug }`;\n\t}\n\n\treturn value;\n}\n\n/**\n * Converts all preset values in a values object to their custom equivalents.\n *\n * @param {Object} values Values object to convert\n * @param {Array} presets Array of current border radius preset objects\n *\n * @return {Object} Values with presets converted to custom values\n */\nexport function convertPresetsToCustomValues( values, presets ) {\n\tif ( ! values || typeof values !== 'object' ) {\n\t\treturn values;\n\t}\n\n\tconst converted = {};\n\tObject.keys( values ).forEach( ( key ) => {\n\t\tconst value = values[ key ];\n\t\tif ( isValuePreset( value ) ) {\n\t\t\tconst customValue = getCustomValueFromPreset( value, presets );\n\t\t\tconverted[ key ] = customValue !== undefined ? customValue : value;\n\t\t} else {\n\t\t\tconverted[ key ] = value;\n\t\t}\n\t} );\n\n\treturn converted;\n}\n"],
|
|
5
|
+
"mappings": "AAGA,SAAS,kDAAkD,wCAAwC;AAe5F,SAAS,KAAM,YAAa;AAClC,QAAM,MAAM,CAAE,GAAG,UAAW;AAC5B,SAAO,IACL;AAAA,IACA,CAAE,GAAG,MACJ,WAAW,OAAQ,CAAE,MAAO,MAAM,CAAE,EAAE,SACtC,WAAW,OAAQ,CAAE,MAAO,MAAM,CAAE,EAAE;AAAA,EACxC,EACC,MAAM;AACT;AAYO,SAAS,WAAY,gBAAgB,CAAC,GAAI;AAChD,QAAM,EAAE,MAAM,GAAG,YAAY,IAAI;AACjC,SAC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
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
})
|
|
65
|
-
});
|
|
66
|
-
},
|
|
67
|
-
isAppender: true
|
|
68
|
-
});
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import clsx from "clsx";
|
|
3
|
+
import { Button } from "@wordpress/components";
|
|
4
|
+
import { forwardRef } from "@wordpress/element";
|
|
5
|
+
import { _x, sprintf } from "@wordpress/i18n";
|
|
6
|
+
import { Icon, plus } from "@wordpress/icons";
|
|
7
|
+
import deprecated from "@wordpress/deprecated";
|
|
8
|
+
import Inserter from "../inserter";
|
|
9
|
+
function ButtonBlockAppender({ rootClientId, className, onFocus, tabIndex, onSelect }, ref) {
|
|
10
|
+
return /* @__PURE__ */ jsx(
|
|
11
|
+
Inserter,
|
|
12
|
+
{
|
|
13
|
+
position: "bottom center",
|
|
14
|
+
rootClientId,
|
|
15
|
+
__experimentalIsQuick: true,
|
|
16
|
+
onSelectOrClose: (...args) => {
|
|
17
|
+
if (onSelect && typeof onSelect === "function") {
|
|
18
|
+
onSelect(...args);
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
renderToggle: ({
|
|
22
|
+
onToggle,
|
|
23
|
+
disabled,
|
|
24
|
+
isOpen,
|
|
25
|
+
blockTitle,
|
|
26
|
+
hasSingleBlockType
|
|
27
|
+
}) => {
|
|
28
|
+
const isToggleButton = !hasSingleBlockType;
|
|
29
|
+
const label = hasSingleBlockType ? sprintf(
|
|
30
|
+
// translators: %s: the name of the block when there is only one
|
|
31
|
+
_x(
|
|
32
|
+
"Add %s",
|
|
33
|
+
"directly add the only allowed block"
|
|
34
|
+
),
|
|
35
|
+
blockTitle
|
|
36
|
+
) : _x(
|
|
37
|
+
"Add block",
|
|
38
|
+
"Generic label for block inserter button"
|
|
39
|
+
);
|
|
40
|
+
return /* @__PURE__ */ jsx(
|
|
41
|
+
Button,
|
|
42
|
+
{
|
|
43
|
+
__next40pxDefaultSize: true,
|
|
44
|
+
ref,
|
|
45
|
+
onFocus,
|
|
46
|
+
tabIndex,
|
|
47
|
+
className: clsx(
|
|
48
|
+
className,
|
|
49
|
+
"block-editor-button-block-appender"
|
|
50
|
+
),
|
|
51
|
+
onClick: onToggle,
|
|
52
|
+
"aria-haspopup": isToggleButton ? "true" : void 0,
|
|
53
|
+
"aria-expanded": isToggleButton ? isOpen : void 0,
|
|
54
|
+
disabled,
|
|
55
|
+
label,
|
|
56
|
+
showTooltip: true,
|
|
57
|
+
children: /* @__PURE__ */ jsx(Icon, { icon: plus })
|
|
58
|
+
}
|
|
59
|
+
);
|
|
60
|
+
},
|
|
61
|
+
isAppender: true
|
|
62
|
+
}
|
|
63
|
+
);
|
|
69
64
|
}
|
|
70
|
-
|
|
71
|
-
/**
|
|
72
|
-
* Use `ButtonBlockAppender` instead.
|
|
73
|
-
*
|
|
74
|
-
* @deprecated
|
|
75
|
-
*/
|
|
76
|
-
export const ButtonBlockerAppender = forwardRef((props, ref) => {
|
|
65
|
+
const ButtonBlockerAppender = forwardRef((props, ref) => {
|
|
77
66
|
deprecated(`wp.blockEditor.ButtonBlockerAppender`, {
|
|
78
|
-
alternative:
|
|
79
|
-
since:
|
|
67
|
+
alternative: "wp.blockEditor.ButtonBlockAppender",
|
|
68
|
+
since: "5.9"
|
|
80
69
|
});
|
|
81
70
|
return ButtonBlockAppender(props, ref);
|
|
82
71
|
});
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
//# sourceMappingURL=index.js.map
|
|
72
|
+
var button_block_appender_default = forwardRef(ButtonBlockAppender);
|
|
73
|
+
export {
|
|
74
|
+
ButtonBlockerAppender,
|
|
75
|
+
button_block_appender_default as default
|
|
76
|
+
};
|
|
77
|
+
//# sourceMappingURL=index.js.map
|