@wordpress/block-editor 9.4.0 → 9.7.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/CHANGELOG.md +6 -0
- package/README.md +1 -8
- package/build/components/block-list/block-invalid-warning.native.js +54 -6
- package/build/components/block-list/block-invalid-warning.native.js.map +1 -1
- package/build/components/block-list/block.js +14 -4
- package/build/components/block-list/block.js.map +1 -1
- package/build/components/block-list/block.native.js +2 -1
- package/build/components/block-list/block.native.js.map +1 -1
- package/build/components/block-list/index.native.js +5 -4
- package/build/components/block-list/index.native.js.map +1 -1
- package/build/components/block-list/layout.js +20 -5
- package/build/components/block-list/layout.js.map +1 -1
- package/build/components/block-list/use-block-props/use-block-class-names.js +5 -2
- package/build/components/block-list/use-block-props/use-block-class-names.js.map +1 -1
- package/build/components/block-lock/modal.js +37 -7
- package/build/components/block-lock/modal.js.map +1 -1
- package/build/components/block-mobile-toolbar/block-actions-menu.native.js +1 -1
- package/build/components/block-mobile-toolbar/block-actions-menu.native.js.map +1 -1
- package/build/components/block-mover/mover-description.js +95 -32
- package/build/components/block-mover/mover-description.js.map +1 -1
- package/build/components/block-pattern-setup/index.js +5 -17
- package/build/components/block-pattern-setup/index.js.map +1 -1
- package/build/components/block-popover/inbetween.js +2 -2
- package/build/components/block-popover/inbetween.js.map +1 -1
- package/build/components/block-popover/index.js +1 -1
- package/build/components/block-popover/index.js.map +1 -1
- package/build/components/block-settings-menu/block-mode-toggle.js +1 -1
- package/build/components/block-settings-menu/block-mode-toggle.js.map +1 -1
- package/build/components/block-settings-menu/block-settings-dropdown.js +4 -1
- package/build/components/block-settings-menu/block-settings-dropdown.js.map +1 -1
- package/build/components/block-settings-menu-controls/index.js +1 -1
- package/build/components/block-settings-menu-controls/index.js.map +1 -1
- package/build/components/block-styles/index.js +3 -6
- package/build/components/block-styles/index.js.map +1 -1
- package/build/components/block-styles/preview.native.js.map +1 -1
- package/build/components/block-switcher/index.js +7 -1
- package/build/components/block-switcher/index.js.map +1 -1
- package/build/components/block-title/index.js +8 -2
- package/build/components/block-title/index.js.map +1 -1
- package/build/components/block-title/use-block-display-title.js +12 -5
- package/build/components/block-title/use-block-display-title.js.map +1 -1
- package/build/components/block-tools/block-contextual-toolbar.js +1 -1
- package/build/components/block-tools/block-contextual-toolbar.js.map +1 -1
- package/build/components/block-tools/block-selection-button.js +1 -7
- package/build/components/block-tools/block-selection-button.js.map +1 -1
- package/build/components/block-tools/index.js +4 -1
- package/build/components/block-tools/index.js.map +1 -1
- package/build/components/block-types-list/index.js +1 -1
- package/build/components/block-types-list/index.js.map +1 -1
- package/build/components/block-types-list/index.native.js +65 -23
- package/build/components/block-types-list/index.native.js.map +1 -1
- package/build/components/border-radius-control/index.js +5 -1
- package/build/components/border-radius-control/index.js.map +1 -1
- package/build/components/colors/utils.js +6 -2
- package/build/components/colors/utils.js.map +1 -1
- package/build/components/colors/with-colors.js +1 -1
- package/build/components/colors/with-colors.js.map +1 -1
- package/build/components/colors-gradients/control.js +49 -39
- package/build/components/colors-gradients/control.js.map +1 -1
- package/build/components/colors-gradients/dropdown.js +9 -3
- package/build/components/colors-gradients/dropdown.js.map +1 -1
- package/build/components/date-format-picker/index.js +1 -1
- package/build/components/date-format-picker/index.js.map +1 -1
- package/build/components/font-appearance-control/index.js +10 -4
- package/build/components/font-appearance-control/index.js.map +1 -1
- package/build/components/iframe/index.js +19 -6
- package/build/components/iframe/index.js.map +1 -1
- package/build/components/image-editor/cropper.js +4 -3
- package/build/components/image-editor/cropper.js.map +1 -1
- package/build/components/image-editor/index.js +3 -1
- package/build/components/image-editor/index.js.map +1 -1
- package/build/components/image-size-control/index.js +3 -1
- package/build/components/image-size-control/index.js.map +1 -1
- package/build/components/index.js +13 -6
- package/build/components/index.js.map +1 -1
- package/build/components/index.native.js +11 -4
- package/build/components/index.native.js.map +1 -1
- package/build/components/inserter/block-types-tab.native.js +30 -16
- package/build/components/inserter/block-types-tab.native.js.map +1 -1
- package/build/components/inserter/index.native.js +8 -3
- package/build/components/inserter/index.native.js.map +1 -1
- package/build/components/inserter/preview-panel.js +8 -8
- package/build/components/inserter/preview-panel.js.map +1 -1
- package/build/components/inserter/reusable-blocks-tab.native.js +5 -1
- package/build/components/inserter/reusable-blocks-tab.native.js.map +1 -1
- package/build/components/inserter/search-results.native.js +5 -2
- package/build/components/inserter/search-results.native.js.map +1 -1
- package/build/components/inserter/utils.native.js +21 -0
- package/build/components/inserter/utils.native.js.map +1 -1
- package/build/components/inserter-list-item/index.js +7 -20
- package/build/components/inserter-list-item/index.js.map +1 -1
- package/build/components/letter-spacing-control/index.js +6 -3
- package/build/components/letter-spacing-control/index.js.map +1 -1
- package/build/components/line-height-control/index.js +6 -3
- package/build/components/line-height-control/index.js.map +1 -1
- package/build/components/link-control/index.js +1 -1
- package/build/components/link-control/index.js.map +1 -1
- package/build/components/link-control/is-url-like.js +1 -7
- package/build/components/link-control/is-url-like.js.map +1 -1
- package/build/components/link-control/use-search-handler.js +1 -7
- package/build/components/link-control/use-search-handler.js.map +1 -1
- package/build/components/list-view/block-select-button.js +15 -7
- package/build/components/list-view/block-select-button.js.map +1 -1
- package/build/components/list-view/branch.js +1 -7
- package/build/components/list-view/branch.js.map +1 -1
- package/build/components/list-view/drop-indicator.js +1 -1
- package/build/components/list-view/drop-indicator.js.map +1 -1
- package/build/components/list-view/expander.js +3 -1
- package/build/components/list-view/expander.js.map +1 -1
- package/build/components/media-placeholder/index.js +13 -2
- package/build/components/media-placeholder/index.js.map +1 -1
- package/build/components/media-replace-flow/index.js +3 -6
- package/build/components/media-replace-flow/index.js.map +1 -1
- package/build/components/media-upload/index.native.js +8 -3
- package/build/components/media-upload/index.native.js.map +1 -1
- package/build/components/observe-typing/index.js +22 -8
- package/build/components/observe-typing/index.js.map +1 -1
- package/build/components/preview-options/index.js +2 -2
- package/build/components/preview-options/index.js.map +1 -1
- package/build/components/{use-no-recursive-renders → recursion-provider}/index.js +40 -18
- package/build/components/recursion-provider/index.js.map +1 -0
- package/build/components/rich-text/format-toolbar-container.js +61 -12
- package/build/components/rich-text/format-toolbar-container.js.map +1 -1
- package/build/components/rich-text/index.js +8 -2
- package/build/components/rich-text/index.js.map +1 -1
- package/build/components/rich-text/index.native.js +3 -1
- package/build/components/rich-text/index.native.js.map +1 -1
- package/build/components/rich-text/use-before-input-rules.js +110 -0
- package/build/components/rich-text/use-before-input-rules.js.map +1 -0
- package/build/components/rich-text/use-format-types.js +36 -16
- package/build/components/rich-text/use-format-types.js.map +1 -1
- package/build/components/text-decoration-control/index.js +3 -1
- package/build/components/text-decoration-control/index.js.map +1 -1
- package/build/components/text-transform-control/index.js +3 -1
- package/build/components/text-transform-control/index.js.map +1 -1
- package/build/components/url-popover/image-url-input-ui.js +4 -1
- package/build/components/url-popover/image-url-input-ui.js.map +1 -1
- package/build/components/url-popover/index.js +2 -1
- package/build/components/url-popover/index.js.map +1 -1
- package/build/components/writing-flow/use-arrow-nav.js +38 -27
- package/build/components/writing-flow/use-arrow-nav.js.map +1 -1
- package/build/components/writing-flow/use-drag-selection.js +9 -2
- package/build/components/writing-flow/use-drag-selection.js.map +1 -1
- package/build/components/writing-flow/use-multi-selection.js +3 -47
- package/build/components/writing-flow/use-multi-selection.js.map +1 -1
- package/build/components/writing-flow/use-select-all.js +3 -1
- package/build/components/writing-flow/use-select-all.js.map +1 -1
- package/build/components/writing-flow/use-selection-observer.js +1 -3
- package/build/components/writing-flow/use-selection-observer.js.map +1 -1
- package/build/components/writing-flow/use-tab-nav.js +1 -1
- package/build/components/writing-flow/use-tab-nav.js.map +1 -1
- package/build/hooks/color.js +2 -4
- package/build/hooks/color.js.map +1 -1
- package/build/hooks/index.js +8 -0
- package/build/hooks/index.js.map +1 -1
- package/build/hooks/layout.js +61 -15
- package/build/hooks/layout.js.map +1 -1
- package/build/hooks/style.js +41 -31
- package/build/hooks/style.js.map +1 -1
- package/build/hooks/utils.js +5 -3
- package/build/hooks/utils.js.map +1 -1
- package/build/index.js +7 -0
- package/build/index.js.map +1 -1
- package/build/layouts/flex.js +40 -36
- package/build/layouts/flex.js.map +1 -1
- package/build/layouts/flow.js +35 -37
- package/build/layouts/flow.js.map +1 -1
- package/build/layouts/utils.js +35 -3
- package/build/layouts/utils.js.map +1 -1
- package/build/store/actions.js +15 -18
- package/build/store/actions.js.map +1 -1
- package/build/store/index.js +0 -4
- package/build/store/index.js.map +1 -1
- package/build/store/reducer.js +5 -3
- package/build/store/reducer.js.map +1 -1
- package/build/store/selectors.js +3 -3
- package/build/store/selectors.js.map +1 -1
- package/build/utils/block-variation-transforms.js +15 -9
- package/build/utils/block-variation-transforms.js.map +1 -1
- package/build/utils/pasting.js +9 -1
- package/build/utils/pasting.js.map +1 -1
- package/build-module/components/block-list/block-invalid-warning.native.js +50 -6
- package/build-module/components/block-list/block-invalid-warning.native.js.map +1 -1
- package/build-module/components/block-list/block.js +15 -5
- package/build-module/components/block-list/block.js.map +1 -1
- package/build-module/components/block-list/block.native.js +2 -1
- package/build-module/components/block-list/block.native.js.map +1 -1
- package/build-module/components/block-list/index.native.js +4 -2
- package/build-module/components/block-list/index.native.js.map +1 -1
- package/build-module/components/block-list/layout.js +19 -4
- package/build-module/components/block-list/layout.js.map +1 -1
- package/build-module/components/block-list/use-block-props/use-block-class-names.js +5 -2
- package/build-module/components/block-list/use-block-props/use-block-class-names.js.map +1 -1
- package/build-module/components/block-lock/modal.js +39 -8
- package/build-module/components/block-lock/modal.js.map +1 -1
- package/build-module/components/block-mobile-toolbar/block-actions-menu.native.js +2 -2
- package/build-module/components/block-mobile-toolbar/block-actions-menu.native.js.map +1 -1
- package/build-module/components/block-mover/mover-description.js +97 -33
- package/build-module/components/block-mover/mover-description.js.map +1 -1
- package/build-module/components/block-pattern-setup/index.js +6 -18
- package/build-module/components/block-pattern-setup/index.js.map +1 -1
- package/build-module/components/block-popover/inbetween.js +2 -2
- package/build-module/components/block-popover/inbetween.js.map +1 -1
- package/build-module/components/block-popover/index.js +1 -1
- package/build-module/components/block-popover/index.js.map +1 -1
- package/build-module/components/block-settings-menu/block-mode-toggle.js +1 -1
- package/build-module/components/block-settings-menu/block-mode-toggle.js.map +1 -1
- package/build-module/components/block-settings-menu/block-settings-dropdown.js +4 -1
- package/build-module/components/block-settings-menu/block-settings-dropdown.js.map +1 -1
- package/build-module/components/block-settings-menu-controls/index.js +2 -2
- package/build-module/components/block-settings-menu-controls/index.js.map +1 -1
- package/build-module/components/block-styles/index.js +4 -7
- package/build-module/components/block-styles/index.js.map +1 -1
- package/build-module/components/block-styles/preview.native.js.map +1 -1
- package/build-module/components/block-switcher/index.js +7 -1
- package/build-module/components/block-switcher/index.js.map +1 -1
- package/build-module/components/block-title/index.js +8 -2
- package/build-module/components/block-title/index.js.map +1 -1
- package/build-module/components/block-title/use-block-display-title.js +12 -5
- package/build-module/components/block-title/use-block-display-title.js.map +1 -1
- package/build-module/components/block-tools/block-contextual-toolbar.js +1 -1
- package/build-module/components/block-tools/block-contextual-toolbar.js.map +1 -1
- package/build-module/components/block-tools/block-selection-button.js +1 -7
- package/build-module/components/block-tools/block-selection-button.js.map +1 -1
- package/build-module/components/block-tools/index.js +4 -1
- package/build-module/components/block-tools/index.js.map +1 -1
- package/build-module/components/block-types-list/index.js +1 -1
- package/build-module/components/block-types-list/index.js.map +1 -1
- package/build-module/components/block-types-list/index.native.js +67 -25
- package/build-module/components/block-types-list/index.native.js.map +1 -1
- package/build-module/components/border-radius-control/index.js +6 -2
- package/build-module/components/border-radius-control/index.js.map +1 -1
- package/build-module/components/colors/utils.js +7 -3
- package/build-module/components/colors/utils.js.map +1 -1
- package/build-module/components/colors/with-colors.js +2 -2
- package/build-module/components/colors/with-colors.js.map +1 -1
- package/build-module/components/colors-gradients/control.js +50 -40
- package/build-module/components/colors-gradients/control.js.map +1 -1
- package/build-module/components/colors-gradients/dropdown.js +10 -4
- package/build-module/components/colors-gradients/dropdown.js.map +1 -1
- package/build-module/components/date-format-picker/index.js +1 -1
- package/build-module/components/date-format-picker/index.js.map +1 -1
- package/build-module/components/font-appearance-control/index.js +7 -4
- package/build-module/components/font-appearance-control/index.js.map +1 -1
- package/build-module/components/iframe/index.js +19 -6
- package/build-module/components/iframe/index.js.map +1 -1
- package/build-module/components/image-editor/cropper.js +4 -3
- package/build-module/components/image-editor/cropper.js.map +1 -1
- package/build-module/components/image-editor/index.js +3 -1
- package/build-module/components/image-editor/index.js.map +1 -1
- package/build-module/components/image-size-control/index.js +3 -1
- package/build-module/components/image-size-control/index.js.map +1 -1
- package/build-module/components/index.js +1 -1
- package/build-module/components/index.js.map +1 -1
- package/build-module/components/index.native.js +1 -1
- package/build-module/components/index.native.js.map +1 -1
- package/build-module/components/inserter/block-types-tab.native.js +31 -15
- package/build-module/components/inserter/block-types-tab.native.js.map +1 -1
- package/build-module/components/inserter/index.native.js +9 -2
- package/build-module/components/inserter/index.native.js.map +1 -1
- package/build-module/components/inserter/preview-panel.js +9 -9
- package/build-module/components/inserter/preview-panel.js.map +1 -1
- package/build-module/components/inserter/reusable-blocks-tab.native.js +6 -2
- package/build-module/components/inserter/reusable-blocks-tab.native.js.map +1 -1
- package/build-module/components/inserter/search-results.native.js +6 -3
- package/build-module/components/inserter/search-results.native.js.map +1 -1
- package/build-module/components/inserter/utils.native.js +19 -0
- package/build-module/components/inserter/utils.native.js.map +1 -1
- package/build-module/components/inserter-list-item/index.js +5 -18
- package/build-module/components/inserter-list-item/index.js.map +1 -1
- package/build-module/components/letter-spacing-control/index.js +5 -3
- package/build-module/components/letter-spacing-control/index.js.map +1 -1
- package/build-module/components/line-height-control/index.js +5 -3
- package/build-module/components/line-height-control/index.js.map +1 -1
- package/build-module/components/link-control/index.js +1 -1
- package/build-module/components/link-control/index.js.map +1 -1
- package/build-module/components/link-control/is-url-like.js +1 -6
- package/build-module/components/link-control/is-url-like.js.map +1 -1
- package/build-module/components/link-control/use-search-handler.js +1 -6
- package/build-module/components/link-control/use-search-handler.js.map +1 -1
- package/build-module/components/list-view/block-select-button.js +16 -8
- package/build-module/components/list-view/block-select-button.js.map +1 -1
- package/build-module/components/list-view/branch.js +1 -6
- package/build-module/components/list-view/branch.js.map +1 -1
- package/build-module/components/list-view/drop-indicator.js +1 -1
- package/build-module/components/list-view/drop-indicator.js.map +1 -1
- package/build-module/components/list-view/expander.js +3 -2
- package/build-module/components/list-view/expander.js.map +1 -1
- package/build-module/components/media-placeholder/index.js +13 -2
- package/build-module/components/media-placeholder/index.js.map +1 -1
- package/build-module/components/media-replace-flow/index.js +4 -7
- package/build-module/components/media-replace-flow/index.js.map +1 -1
- package/build-module/components/media-upload/index.native.js +9 -2
- package/build-module/components/media-upload/index.native.js.map +1 -1
- package/build-module/components/observe-typing/index.js +22 -8
- package/build-module/components/observe-typing/index.js.map +1 -1
- package/build-module/components/preview-options/index.js +2 -2
- package/build-module/components/preview-options/index.js.map +1 -1
- package/build-module/components/{use-no-recursive-renders → recursion-provider}/index.js +39 -19
- package/build-module/components/recursion-provider/index.js.map +1 -0
- package/build-module/components/rich-text/format-toolbar-container.js +58 -12
- package/build-module/components/rich-text/format-toolbar-container.js.map +1 -1
- package/build-module/components/rich-text/index.js +7 -2
- package/build-module/components/rich-text/index.js.map +1 -1
- package/build-module/components/rich-text/index.native.js +3 -1
- package/build-module/components/rich-text/index.native.js.map +1 -1
- package/build-module/components/rich-text/use-before-input-rules.js +96 -0
- package/build-module/components/rich-text/use-before-input-rules.js.map +1 -0
- package/build-module/components/rich-text/use-format-types.js +37 -18
- package/build-module/components/rich-text/use-format-types.js.map +1 -1
- package/build-module/components/text-decoration-control/index.js +4 -2
- package/build-module/components/text-decoration-control/index.js.map +1 -1
- package/build-module/components/text-transform-control/index.js +4 -2
- package/build-module/components/text-transform-control/index.js.map +1 -1
- package/build-module/components/url-popover/image-url-input-ui.js +4 -1
- package/build-module/components/url-popover/image-url-input-ui.js.map +1 -1
- package/build-module/components/url-popover/index.js +2 -1
- package/build-module/components/url-popover/index.js.map +1 -1
- package/build-module/components/writing-flow/use-arrow-nav.js +40 -29
- package/build-module/components/writing-flow/use-arrow-nav.js.map +1 -1
- package/build-module/components/writing-flow/use-drag-selection.js +9 -2
- package/build-module/components/writing-flow/use-drag-selection.js.map +1 -1
- package/build-module/components/writing-flow/use-multi-selection.js +3 -45
- package/build-module/components/writing-flow/use-multi-selection.js.map +1 -1
- package/build-module/components/writing-flow/use-select-all.js +3 -1
- package/build-module/components/writing-flow/use-select-all.js.map +1 -1
- package/build-module/components/writing-flow/use-selection-observer.js +1 -3
- package/build-module/components/writing-flow/use-selection-observer.js.map +1 -1
- package/build-module/components/writing-flow/use-tab-nav.js +1 -1
- package/build-module/components/writing-flow/use-tab-nav.js.map +1 -1
- package/build-module/hooks/color.js +2 -3
- package/build-module/hooks/color.js.map +1 -1
- package/build-module/hooks/index.js +1 -0
- package/build-module/hooks/index.js.map +1 -1
- package/build-module/hooks/layout.js +62 -16
- package/build-module/hooks/layout.js.map +1 -1
- package/build-module/hooks/style.js +44 -35
- package/build-module/hooks/style.js.map +1 -1
- package/build-module/hooks/utils.js +5 -2
- package/build-module/hooks/utils.js.map +1 -1
- package/build-module/index.js +1 -1
- package/build-module/index.js.map +1 -1
- package/build-module/layouts/flex.js +41 -33
- package/build-module/layouts/flex.js.map +1 -1
- package/build-module/layouts/flow.js +35 -38
- package/build-module/layouts/flow.js.map +1 -1
- package/build-module/layouts/utils.js +33 -3
- package/build-module/layouts/utils.js.map +1 -1
- package/build-module/store/actions.js +9 -10
- package/build-module/store/actions.js.map +1 -1
- package/build-module/store/index.js +0 -4
- package/build-module/store/index.js.map +1 -1
- package/build-module/store/reducer.js +5 -2
- package/build-module/store/reducer.js.map +1 -1
- package/build-module/store/selectors.js +4 -4
- package/build-module/store/selectors.js.map +1 -1
- package/build-module/utils/block-variation-transforms.js +14 -7
- package/build-module/utils/block-variation-transforms.js.map +1 -1
- package/build-module/utils/pasting.js +9 -1
- package/build-module/utils/pasting.js.map +1 -1
- package/build-style/style-rtl.css +72 -14
- package/build-style/style.css +72 -14
- package/package.json +28 -28
- package/src/components/block-list/block-invalid-warning.native.js +42 -7
- package/src/components/block-list/block.js +15 -4
- package/src/components/block-list/block.native.js +1 -0
- package/src/components/block-list/index.native.js +2 -2
- package/src/components/block-list/layout.js +15 -3
- package/src/components/block-list/style.scss +1 -1
- package/src/components/block-list/use-block-props/use-block-class-names.js +5 -1
- package/src/components/block-lock/modal.js +47 -9
- package/src/components/block-lock/style.scss +10 -0
- package/src/components/block-mobile-toolbar/block-actions-menu.native.js +3 -3
- package/src/components/block-mover/mover-description.js +131 -48
- package/src/components/block-mover/test/mover-description.js +55 -3
- package/src/components/block-pattern-setup/index.js +3 -15
- package/src/components/block-pattern-setup/style.scss +4 -2
- package/src/components/block-popover/inbetween.js +2 -1
- package/src/components/block-popover/index.js +1 -1
- package/src/components/block-popover/style.scss +25 -2
- package/src/components/block-settings-menu/block-mode-toggle.js +1 -0
- package/src/components/block-settings-menu/block-settings-dropdown.js +4 -1
- package/src/components/block-settings-menu-controls/index.js +2 -2
- package/src/components/block-styles/index.js +4 -7
- package/src/components/block-styles/preview.native.js +1 -0
- package/src/components/block-styles/style.scss +10 -0
- package/src/components/block-switcher/index.js +7 -1
- package/src/components/block-title/index.js +3 -2
- package/src/components/block-title/use-block-display-title.js +11 -5
- package/src/components/block-tools/block-contextual-toolbar.js +3 -1
- package/src/components/block-tools/block-selection-button.js +0 -5
- package/src/components/block-tools/index.js +4 -1
- package/src/components/block-types-list/index.js +1 -1
- package/src/components/block-types-list/index.native.js +76 -24
- package/src/components/block-types-list/style.native.scss +18 -0
- package/src/components/border-radius-control/index.js +6 -1
- package/src/components/color-palette/test/__snapshots__/control.js.snap +91 -79
- package/src/components/colors/test/__snapshots__/with-colors.js.snap +1 -1
- package/src/components/colors/test/with-colors.js +1 -1
- package/src/components/colors/utils.js +5 -2
- package/src/components/colors/with-colors.js +2 -2
- package/src/components/colors-gradients/control.js +82 -65
- package/src/components/colors-gradients/dropdown.js +14 -3
- package/src/components/colors-gradients/style.scss +34 -9
- package/src/components/colors-gradients/test/control.js +16 -23
- package/src/components/date-format-picker/index.js +1 -0
- package/src/components/font-appearance-control/index.js +3 -0
- package/src/components/iframe/index.js +25 -6
- package/src/components/image-editor/cropper.js +9 -3
- package/src/components/image-editor/index.js +2 -0
- package/src/components/image-size-control/README.md +7 -0
- package/src/components/image-size-control/index.js +2 -0
- package/src/components/index.js +4 -1
- package/src/components/index.native.js +4 -1
- package/src/components/inserter/block-types-tab.native.js +42 -21
- package/src/components/inserter/index.native.js +7 -2
- package/src/components/inserter/preview-panel.js +6 -14
- package/src/components/inserter/reusable-blocks-tab.native.js +4 -2
- package/src/components/inserter/search-results.native.js +4 -2
- package/src/components/inserter/style.scss +1 -1
- package/src/components/inserter/test/block-types-tab.native.js +2 -0
- package/src/components/inserter/test/utils.native.js +37 -0
- package/src/components/inserter/utils.native.js +11 -0
- package/src/components/inserter-list-item/index.js +5 -18
- package/src/components/letter-spacing-control/index.js +2 -0
- package/src/components/line-height-control/index.js +2 -0
- package/src/components/link-control/index.js +1 -0
- package/src/components/link-control/is-url-like.js +1 -6
- package/src/components/link-control/test/index.js +6 -4
- package/src/components/link-control/use-search-handler.js +1 -6
- package/src/components/list-view/block-select-button.js +29 -14
- package/src/components/list-view/branch.js +1 -6
- package/src/components/list-view/drop-indicator.js +1 -1
- package/src/components/list-view/expander.js +4 -2
- package/src/components/list-view/style.scss +18 -4
- package/src/components/media-placeholder/index.js +19 -0
- package/src/components/media-replace-flow/index.js +3 -6
- package/src/components/media-replace-flow/test/index.js +14 -4
- package/src/components/media-upload/index.native.js +7 -3
- package/src/components/observe-typing/index.js +17 -14
- package/src/components/preview-options/index.js +2 -2
- package/src/components/{use-no-recursive-renders → recursion-provider}/index.js +39 -28
- package/src/components/{use-no-recursive-renders/test/use-no-recursive-renders.js → recursion-provider/test/index.js} +5 -6
- package/src/components/rich-text/README.md +13 -1
- package/src/components/rich-text/format-toolbar-container.js +63 -14
- package/src/components/rich-text/index.js +3 -0
- package/src/components/rich-text/index.native.js +2 -0
- package/src/components/rich-text/use-before-input-rules.js +91 -0
- package/src/components/rich-text/use-format-types.js +38 -17
- package/src/components/text-decoration-control/index.js +4 -2
- package/src/components/text-transform-control/index.js +4 -2
- package/src/components/url-popover/image-url-input-ui.js +3 -0
- package/src/components/url-popover/index.js +1 -0
- package/src/components/url-popover/test/__snapshots__/index.js.snap +3 -0
- package/src/components/writing-flow/use-arrow-nav.js +36 -34
- package/src/components/writing-flow/use-drag-selection.js +7 -1
- package/src/components/writing-flow/use-multi-selection.js +1 -48
- package/src/components/writing-flow/use-select-all.js +2 -1
- package/src/components/writing-flow/use-selection-observer.js +2 -3
- package/src/components/writing-flow/use-tab-nav.js +1 -1
- package/src/hooks/color.js +10 -3
- package/src/hooks/index.js +1 -0
- package/src/hooks/layout.js +66 -23
- package/src/hooks/style.js +46 -39
- package/src/hooks/utils.js +7 -3
- package/src/index.js +1 -0
- package/src/layouts/flex.js +47 -41
- package/src/layouts/flow.js +35 -34
- package/src/layouts/test/flex.js +21 -0
- package/src/layouts/test/flow.js +21 -0
- package/src/layouts/test/utils.js +138 -0
- package/src/layouts/utils.js +44 -3
- package/src/store/actions.js +10 -11
- package/src/store/index.js +0 -4
- package/src/store/reducer.js +3 -2
- package/src/store/selectors.js +3 -4
- package/src/utils/block-variation-transforms.js +13 -6
- package/src/utils/pasting.js +10 -1
- package/src/utils/test/block-variation-transforms.js +24 -0
- package/src/utils/test/pasting.js +10 -0
- package/tsconfig.json +2 -1
- package/build/components/use-no-recursive-renders/index.js.map +0 -1
- package/build-module/components/use-no-recursive-renders/index.js.map +0 -1
|
@@ -1,9 +1,15 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* External dependencies
|
|
3
|
-
*/
|
|
4
|
-
import { isMatch } from 'lodash';
|
|
5
1
|
/** @typedef {import('@wordpress/blocks').WPBlockVariation} WPBlockVariation */
|
|
2
|
+
function matchesAttributes(blockAttributes, variation) {
|
|
3
|
+
return Object.entries(variation).every(_ref => {
|
|
4
|
+
let [key, value] = _ref;
|
|
5
|
+
|
|
6
|
+
if (typeof value === 'object' && typeof blockAttributes[key] === 'object') {
|
|
7
|
+
return matchesAttributes(blockAttributes[key], value);
|
|
8
|
+
}
|
|
6
9
|
|
|
10
|
+
return blockAttributes[key] === value;
|
|
11
|
+
});
|
|
12
|
+
}
|
|
7
13
|
/**
|
|
8
14
|
* Matches the provided block variations with a block's attributes. If no match
|
|
9
15
|
* or more than one matches are found it returns `undefined`. If a single match is
|
|
@@ -17,14 +23,15 @@ import { isMatch } from 'lodash';
|
|
|
17
23
|
* @return {?WPBlockVariation} - If a match is found returns it. If not or more than one matches are found returns `undefined`.
|
|
18
24
|
*/
|
|
19
25
|
|
|
26
|
+
|
|
20
27
|
export const __experimentalGetMatchingVariation = (blockAttributes, variations) => {
|
|
21
28
|
if (!variations || !blockAttributes) return;
|
|
22
|
-
const matches = variations.filter(
|
|
29
|
+
const matches = variations.filter(_ref2 => {
|
|
23
30
|
let {
|
|
24
31
|
attributes
|
|
25
|
-
} =
|
|
32
|
+
} = _ref2;
|
|
26
33
|
if (!attributes || !Object.keys(attributes).length) return false;
|
|
27
|
-
return
|
|
34
|
+
return matchesAttributes(blockAttributes, attributes);
|
|
28
35
|
});
|
|
29
36
|
if (matches.length !== 1) return;
|
|
30
37
|
return matches[0];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["@wordpress/block-editor/src/utils/block-variation-transforms.js"],"names":["
|
|
1
|
+
{"version":3,"sources":["@wordpress/block-editor/src/utils/block-variation-transforms.js"],"names":["matchesAttributes","blockAttributes","variation","Object","entries","every","key","value","__experimentalGetMatchingVariation","variations","matches","filter","attributes","keys","length"],"mappings":"AAAA;AAEA,SAASA,iBAAT,CAA4BC,eAA5B,EAA6CC,SAA7C,EAAyD;AACxD,SAAOC,MAAM,CAACC,OAAP,CAAgBF,SAAhB,EAA4BG,KAA5B,CAAmC,QAAsB;AAAA,QAApB,CAAEC,GAAF,EAAOC,KAAP,CAAoB;;AAC/D,QACC,OAAOA,KAAP,KAAiB,QAAjB,IACA,OAAON,eAAe,CAAEK,GAAF,CAAtB,KAAkC,QAFnC,EAGE;AACD,aAAON,iBAAiB,CAAEC,eAAe,CAAEK,GAAF,CAAjB,EAA0BC,KAA1B,CAAxB;AACA;;AACD,WAAON,eAAe,CAAEK,GAAF,CAAf,KAA2BC,KAAlC;AACA,GARM,CAAP;AASA;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AACA,OAAO,MAAMC,kCAAkC,GAAG,CACjDP,eADiD,EAEjDQ,UAFiD,KAG7C;AACJ,MAAK,CAAEA,UAAF,IAAgB,CAAER,eAAvB,EAAyC;AACzC,QAAMS,OAAO,GAAGD,UAAU,CAACE,MAAX,CAAmB,SAAsB;AAAA,QAApB;AAAEC,MAAAA;AAAF,KAAoB;AACxD,QAAK,CAAEA,UAAF,IAAgB,CAAET,MAAM,CAACU,IAAP,CAAaD,UAAb,EAA0BE,MAAjD,EAA0D,OAAO,KAAP;AAC1D,WAAOd,iBAAiB,CAAEC,eAAF,EAAmBW,UAAnB,CAAxB;AACA,GAHe,CAAhB;AAIA,MAAKF,OAAO,CAACI,MAAR,KAAmB,CAAxB,EAA4B;AAC5B,SAAOJ,OAAO,CAAE,CAAF,CAAd;AACA,CAXM","sourcesContent":["/** @typedef {import('@wordpress/blocks').WPBlockVariation} WPBlockVariation */\n\nfunction matchesAttributes( blockAttributes, variation ) {\n\treturn Object.entries( variation ).every( ( [ key, value ] ) => {\n\t\tif (\n\t\t\ttypeof value === 'object' &&\n\t\t\ttypeof blockAttributes[ key ] === 'object'\n\t\t) {\n\t\t\treturn matchesAttributes( blockAttributes[ key ], value );\n\t\t}\n\t\treturn blockAttributes[ key ] === value;\n\t} );\n}\n\n/**\n * Matches the provided block variations with a block's attributes. If no match\n * or more than one matches are found it returns `undefined`. If a single match is\n * found it returns it.\n *\n * This is a simple implementation for now as it takes into account only the attributes\n * of a block variation and not `InnerBlocks`.\n *\n * @param {Object} blockAttributes - The block attributes to try to find a match.\n * @param {WPBlockVariation[]} variations - A list of block variations to test for a match.\n * @return {?WPBlockVariation} - If a match is found returns it. If not or more than one matches are found returns `undefined`.\n */\nexport const __experimentalGetMatchingVariation = (\n\tblockAttributes,\n\tvariations\n) => {\n\tif ( ! variations || ! blockAttributes ) return;\n\tconst matches = variations.filter( ( { attributes } ) => {\n\t\tif ( ! attributes || ! Object.keys( attributes ).length ) return false;\n\t\treturn matchesAttributes( blockAttributes, attributes );\n\t} );\n\tif ( matches.length !== 1 ) return;\n\treturn matches[ 0 ];\n};\n"]}
|
|
@@ -72,7 +72,15 @@ export function shouldDismissPastedFiles(files, html
|
|
|
72
72
|
// other elements found, like <figure>, but we assume that the user's
|
|
73
73
|
// intention is to paste the actual image file.
|
|
74
74
|
const IMAGE_TAG = /<\s*img\b/gi;
|
|
75
|
-
|
|
75
|
+
if (((_html$match = html.match(IMAGE_TAG)) === null || _html$match === void 0 ? void 0 : _html$match.length) !== 1) return true; // Even when there is exactly one <img> tag in the HTML payload, we
|
|
76
|
+
// choose to weed out local images, i.e. those whose source starts with
|
|
77
|
+
// "file://". These payloads occur in specific configurations, such as
|
|
78
|
+
// when copying an entire document from Microsoft Word, that contains
|
|
79
|
+
// text and exactly one image, and pasting that content using Google
|
|
80
|
+
// Chrome.
|
|
81
|
+
|
|
82
|
+
const IMG_WITH_LOCAL_SRC = /<\s*img\b[^>]*\bsrc="file:\/\//i;
|
|
83
|
+
if (html.match(IMG_WITH_LOCAL_SRC)) return true;
|
|
76
84
|
}
|
|
77
85
|
|
|
78
86
|
return false;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["@wordpress/block-editor/src/utils/pasting.js"],"names":["createBlobURL","getFilesFromDataTransfer","getPasteEventData","clipboardData","plainText","html","getData","error1","error2","files","filter","type","test","length","shouldDismissPastedFiles","map","file","join","indexOf","IMAGE_TAG","match"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,aAAT,QAA8B,iBAA9B;AACA,SAASC,wBAAT,QAAyC,gBAAzC;AAEA,OAAO,SAASC,iBAAT,OAAgD;AAAA,MAApB;AAAEC,IAAAA;AAAF,GAAoB;AACtD,MAAIC,SAAS,GAAG,EAAhB;AACA,MAAIC,IAAI,GAAG,EAAX,CAFsD,CAItD;AACA;AACA;;AACA,MAAI;AACHD,IAAAA,SAAS,GAAGD,aAAa,CAACG,OAAd,CAAuB,YAAvB,CAAZ;AACAD,IAAAA,IAAI,GAAGF,aAAa,CAACG,OAAd,CAAuB,WAAvB,CAAP;AACA,GAHD,CAGE,OAAQC,MAAR,EAAiB;AAClB,QAAI;AACHF,MAAAA,IAAI,GAAGF,aAAa,CAACG,OAAd,CAAuB,MAAvB,CAAP;AACA,KAFD,CAEE,OAAQE,MAAR,EAAiB;AAClB;AACA;AACA;AACA;AACA;AACD;;AAED,QAAMC,KAAK,GAAGR,wBAAwB,CAAEE,aAAF,CAAxB,CAA0CO,MAA1C,CACb;AAAA,QAAE;AAAEC,MAAAA;AAAF,KAAF;AAAA,WAAgB,kCAAkCC,IAAlC,CAAwCD,IAAxC,CAAhB;AAAA,GADa,CAAd;;AAIA,MACCF,KAAK,CAACI,MAAN,IACA,CAAEC,wBAAwB,CAAEL,KAAF,EAASJ,IAAT,EAAeD,SAAf,CAF3B,EAGE;AACDC,IAAAA,IAAI,GAAGI,KAAK,CACVM,GADK,CACEC,IAAF,IAAa,aAAahB,aAAa,CAAEgB,IAAF,CAAU,IADjD,EAELC,IAFK,CAEC,EAFD,CAAP;AAGAb,IAAAA,SAAS,GAAG,EAAZ;AACA;;AAED,SAAO;AAAEC,IAAAA,IAAF;AAAQD,IAAAA;AAAR,GAAP;AACA;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,OAAO,SAASU,wBAAT,CAAmCL,KAAnC,EAA0CJ;AAAK;AAA/C,EAAkE;AACxE;AACA;AACA,MACCA,IAAI,IACJ,CAAAI,KAAK,SAAL,IAAAA,KAAK,WAAL,YAAAA,KAAK,CAAEI,MAAP,MAAkB,CADlB,IAEAJ,KAAK,CAAE,CAAF,CAAL,CAAWE,IAAX,CAAgBO,OAAhB,CAAyB,QAAzB,MAAwC,CAHzC,EAIE;AAAA;;AACD;AACA;AACA;AACA;AACA,UAAMC,SAAS,GAAG,aAAlB;AACA,
|
|
1
|
+
{"version":3,"sources":["@wordpress/block-editor/src/utils/pasting.js"],"names":["createBlobURL","getFilesFromDataTransfer","getPasteEventData","clipboardData","plainText","html","getData","error1","error2","files","filter","type","test","length","shouldDismissPastedFiles","map","file","join","indexOf","IMAGE_TAG","match","IMG_WITH_LOCAL_SRC"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,aAAT,QAA8B,iBAA9B;AACA,SAASC,wBAAT,QAAyC,gBAAzC;AAEA,OAAO,SAASC,iBAAT,OAAgD;AAAA,MAApB;AAAEC,IAAAA;AAAF,GAAoB;AACtD,MAAIC,SAAS,GAAG,EAAhB;AACA,MAAIC,IAAI,GAAG,EAAX,CAFsD,CAItD;AACA;AACA;;AACA,MAAI;AACHD,IAAAA,SAAS,GAAGD,aAAa,CAACG,OAAd,CAAuB,YAAvB,CAAZ;AACAD,IAAAA,IAAI,GAAGF,aAAa,CAACG,OAAd,CAAuB,WAAvB,CAAP;AACA,GAHD,CAGE,OAAQC,MAAR,EAAiB;AAClB,QAAI;AACHF,MAAAA,IAAI,GAAGF,aAAa,CAACG,OAAd,CAAuB,MAAvB,CAAP;AACA,KAFD,CAEE,OAAQE,MAAR,EAAiB;AAClB;AACA;AACA;AACA;AACA;AACD;;AAED,QAAMC,KAAK,GAAGR,wBAAwB,CAAEE,aAAF,CAAxB,CAA0CO,MAA1C,CACb;AAAA,QAAE;AAAEC,MAAAA;AAAF,KAAF;AAAA,WAAgB,kCAAkCC,IAAlC,CAAwCD,IAAxC,CAAhB;AAAA,GADa,CAAd;;AAIA,MACCF,KAAK,CAACI,MAAN,IACA,CAAEC,wBAAwB,CAAEL,KAAF,EAASJ,IAAT,EAAeD,SAAf,CAF3B,EAGE;AACDC,IAAAA,IAAI,GAAGI,KAAK,CACVM,GADK,CACEC,IAAF,IAAa,aAAahB,aAAa,CAAEgB,IAAF,CAAU,IADjD,EAELC,IAFK,CAEC,EAFD,CAAP;AAGAb,IAAAA,SAAS,GAAG,EAAZ;AACA;;AAED,SAAO;AAAEC,IAAAA,IAAF;AAAQD,IAAAA;AAAR,GAAP;AACA;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,OAAO,SAASU,wBAAT,CAAmCL,KAAnC,EAA0CJ;AAAK;AAA/C,EAAkE;AACxE;AACA;AACA,MACCA,IAAI,IACJ,CAAAI,KAAK,SAAL,IAAAA,KAAK,WAAL,YAAAA,KAAK,CAAEI,MAAP,MAAkB,CADlB,IAEAJ,KAAK,CAAE,CAAF,CAAL,CAAWE,IAAX,CAAgBO,OAAhB,CAAyB,QAAzB,MAAwC,CAHzC,EAIE;AAAA;;AACD;AACA;AACA;AACA;AACA,UAAMC,SAAS,GAAG,aAAlB;AACA,QAAK,gBAAAd,IAAI,CAACe,KAAL,CAAYD,SAAZ,6DAAyBN,MAAzB,MAAoC,CAAzC,EAA6C,OAAO,IAAP,CAN5C,CAQD;AACA;AACA;AACA;AACA;AACA;;AACA,UAAMQ,kBAAkB,GAAG,iCAA3B;AACA,QAAKhB,IAAI,CAACe,KAAL,CAAYC,kBAAZ,CAAL,EAAwC,OAAO,IAAP;AACxC;;AAED,SAAO,KAAP;AACA","sourcesContent":["/**\n * WordPress dependencies\n */\nimport { createBlobURL } from '@wordpress/blob';\nimport { getFilesFromDataTransfer } from '@wordpress/dom';\n\nexport function getPasteEventData( { clipboardData } ) {\n\tlet plainText = '';\n\tlet html = '';\n\n\t// IE11 only supports `Text` as an argument for `getData` and will\n\t// otherwise throw an invalid argument error, so we try the standard\n\t// arguments first, then fallback to `Text` if they fail.\n\ttry {\n\t\tplainText = clipboardData.getData( 'text/plain' );\n\t\thtml = clipboardData.getData( 'text/html' );\n\t} catch ( error1 ) {\n\t\ttry {\n\t\t\thtml = clipboardData.getData( 'Text' );\n\t\t} catch ( error2 ) {\n\t\t\t// Some browsers like UC Browser paste plain text by default and\n\t\t\t// don't support clipboardData at all, so allow default\n\t\t\t// behaviour.\n\t\t\treturn;\n\t\t}\n\t}\n\n\tconst files = getFilesFromDataTransfer( clipboardData ).filter(\n\t\t( { type } ) => /^image\\/(?:jpe?g|png|gif|webp)$/.test( type )\n\t);\n\n\tif (\n\t\tfiles.length &&\n\t\t! shouldDismissPastedFiles( files, html, plainText )\n\t) {\n\t\thtml = files\n\t\t\t.map( ( file ) => `<img src=\"${ createBlobURL( file ) }\">` )\n\t\t\t.join( '' );\n\t\tplainText = '';\n\t}\n\n\treturn { html, plainText };\n}\n\n/**\n * Given a collection of DataTransfer files and HTML and plain text strings,\n * determine whether the files are to be dismissed in favor of the HTML.\n *\n * Certain office-type programs, like Microsoft Word or Apple Numbers,\n * will, upon copy, generate a screenshot of the content being copied and\n * attach it to the clipboard alongside the actual rich text that the user\n * sought to copy. In those cases, we should let Gutenberg handle the rich text\n * content and not the screenshot, since this allows Gutenberg to insert\n * meaningful blocks, like paragraphs, lists or even tables.\n *\n * @param {File[]} files File objects obtained from a paste event\n * @param {string} html HTML content obtained from a paste event\n * @return {boolean} True if the files should be dismissed\n */\nexport function shouldDismissPastedFiles( files, html /*, plainText */ ) {\n\t// The question is only relevant when there is actual HTML content and when\n\t// there is exactly one image file.\n\tif (\n\t\thtml &&\n\t\tfiles?.length === 1 &&\n\t\tfiles[ 0 ].type.indexOf( 'image/' ) === 0\n\t) {\n\t\t// A single <img> tag found in the HTML source suggests that the\n\t\t// content being pasted revolves around an image. Sometimes there are\n\t\t// other elements found, like <figure>, but we assume that the user's\n\t\t// intention is to paste the actual image file.\n\t\tconst IMAGE_TAG = /<\\s*img\\b/gi;\n\t\tif ( html.match( IMAGE_TAG )?.length !== 1 ) return true;\n\n\t\t// Even when there is exactly one <img> tag in the HTML payload, we\n\t\t// choose to weed out local images, i.e. those whose source starts with\n\t\t// \"file://\". These payloads occur in specific configurations, such as\n\t\t// when copying an entire document from Microsoft Word, that contains\n\t\t// text and exactly one image, and pasting that content using Google\n\t\t// Chrome.\n\t\tconst IMG_WITH_LOCAL_SRC = /<\\s*img\\b[^>]*\\bsrc=\"file:\\/\\//i;\n\t\tif ( html.match( IMG_WITH_LOCAL_SRC ) ) return true;\n\t}\n\n\treturn false;\n}\n"]}
|
|
@@ -177,7 +177,7 @@
|
|
|
177
177
|
cursor: default;
|
|
178
178
|
}
|
|
179
179
|
.block-editor-block-list__layout.is-navigate-mode .block-editor-block-list__block.is-selected::after, .block-editor-block-list__layout.is-navigate-mode .block-editor-block-list__block.is-hovered::after,
|
|
180
|
-
.block-editor-block-list__layout .block-editor-block-list__block.is-multi-selected:not(
|
|
180
|
+
.block-editor-block-list__layout .block-editor-block-list__block.is-multi-selected:not(.is-partially-selected)::after,
|
|
181
181
|
.block-editor-block-list__layout .block-editor-block-list__block.is-highlighted::after,
|
|
182
182
|
.block-editor-block-list__layout .block-editor-block-list__block.is-highlighted ~ .is-multi-selected::after {
|
|
183
183
|
position: absolute;
|
|
@@ -193,13 +193,13 @@
|
|
|
193
193
|
outline: 2px solid transparent;
|
|
194
194
|
}
|
|
195
195
|
.is-dark-theme .block-editor-block-list__layout.is-navigate-mode .block-editor-block-list__block.is-selected::after, .is-dark-theme .block-editor-block-list__layout.is-navigate-mode .block-editor-block-list__block.is-hovered::after,
|
|
196
|
-
.is-dark-theme .block-editor-block-list__layout .block-editor-block-list__block.is-multi-selected:not(
|
|
196
|
+
.is-dark-theme .block-editor-block-list__layout .block-editor-block-list__block.is-multi-selected:not(.is-partially-selected)::after,
|
|
197
197
|
.is-dark-theme .block-editor-block-list__layout .block-editor-block-list__block.is-highlighted::after,
|
|
198
198
|
.is-dark-theme .block-editor-block-list__layout .block-editor-block-list__block.is-highlighted ~ .is-multi-selected::after {
|
|
199
199
|
box-shadow: 0 0 0 1px #fff;
|
|
200
200
|
}
|
|
201
201
|
.block-editor-block-list__layout.is-navigate-mode .block-editor-block-list__block.is-selected .components-placeholder ::selection, .block-editor-block-list__layout.is-navigate-mode .block-editor-block-list__block.is-hovered .components-placeholder ::selection,
|
|
202
|
-
.block-editor-block-list__layout .block-editor-block-list__block.is-multi-selected:not(
|
|
202
|
+
.block-editor-block-list__layout .block-editor-block-list__block.is-multi-selected:not(.is-partially-selected) .components-placeholder ::selection,
|
|
203
203
|
.block-editor-block-list__layout .block-editor-block-list__block.is-highlighted .components-placeholder ::selection,
|
|
204
204
|
.block-editor-block-list__layout .block-editor-block-list__block.is-highlighted ~ .is-multi-selected .components-placeholder ::selection {
|
|
205
205
|
background: transparent;
|
|
@@ -709,6 +709,15 @@
|
|
|
709
709
|
border-radius: 2px;
|
|
710
710
|
}
|
|
711
711
|
|
|
712
|
+
.block-editor-block-lock-modal__template-lock {
|
|
713
|
+
border-top: 1px solid #ddd;
|
|
714
|
+
margin-top: 16px;
|
|
715
|
+
padding: 12px 0;
|
|
716
|
+
}
|
|
717
|
+
.block-editor-block-lock-modal__template-lock .components-base-control__field {
|
|
718
|
+
margin: 0;
|
|
719
|
+
}
|
|
720
|
+
|
|
712
721
|
.block-editor-block-lock-modal__actions {
|
|
713
722
|
margin-top: 24px;
|
|
714
723
|
}
|
|
@@ -1074,7 +1083,20 @@
|
|
|
1074
1083
|
overflow-y: visible;
|
|
1075
1084
|
pointer-events: none;
|
|
1076
1085
|
}
|
|
1077
|
-
.components-popover.block-editor-block-popover .components-popover__content
|
|
1086
|
+
.components-popover.block-editor-block-popover:not(.block-editor-block-popover__inbetween) .components-popover__content * {
|
|
1087
|
+
pointer-events: all;
|
|
1088
|
+
}
|
|
1089
|
+
|
|
1090
|
+
.components-popover.block-editor-block-popover__inbetween {
|
|
1091
|
+
pointer-events: none;
|
|
1092
|
+
}
|
|
1093
|
+
.components-popover.block-editor-block-popover__inbetween * {
|
|
1094
|
+
pointer-events: none;
|
|
1095
|
+
}
|
|
1096
|
+
.components-popover.block-editor-block-popover__inbetween .is-with-inserter {
|
|
1097
|
+
pointer-events: all;
|
|
1098
|
+
}
|
|
1099
|
+
.components-popover.block-editor-block-popover__inbetween .is-with-inserter * {
|
|
1078
1100
|
pointer-events: all;
|
|
1079
1101
|
}
|
|
1080
1102
|
|
|
@@ -1176,6 +1198,12 @@
|
|
|
1176
1198
|
.block-editor-block-styles__variants .block-editor-block-styles__item.is-active:focus {
|
|
1177
1199
|
box-shadow: inset 0 0 0 1px #fff, 0 0 0 2px var(--wp-admin-theme-color);
|
|
1178
1200
|
}
|
|
1201
|
+
.block-editor-block-styles__variants .block-editor-block-styles__item-text {
|
|
1202
|
+
word-break: break-all;
|
|
1203
|
+
white-space: normal;
|
|
1204
|
+
text-align: start;
|
|
1205
|
+
text-align-last: center;
|
|
1206
|
+
}
|
|
1179
1207
|
|
|
1180
1208
|
.block-editor-block-styles__block-preview-container,
|
|
1181
1209
|
.block-editor-block-styles__block-preview-container * {
|
|
@@ -1434,6 +1462,8 @@
|
|
|
1434
1462
|
display: block;
|
|
1435
1463
|
width: 100%;
|
|
1436
1464
|
padding: 32px;
|
|
1465
|
+
padding-bottom: 0;
|
|
1466
|
+
padding-top: 0;
|
|
1437
1467
|
column-count: 2;
|
|
1438
1468
|
}
|
|
1439
1469
|
@media (min-width: 1440px) {
|
|
@@ -1465,7 +1495,8 @@
|
|
|
1465
1495
|
text-align: right;
|
|
1466
1496
|
margin: 0;
|
|
1467
1497
|
color: #1e1e1e;
|
|
1468
|
-
|
|
1498
|
+
position: absolute;
|
|
1499
|
+
bottom: 0;
|
|
1469
1500
|
background-color: #fff;
|
|
1470
1501
|
display: flex;
|
|
1471
1502
|
flex-direction: row;
|
|
@@ -1531,7 +1562,6 @@
|
|
|
1531
1562
|
.block-editor-block-pattern-setup__carousel,
|
|
1532
1563
|
.block-editor-block-pattern-setup__grid {
|
|
1533
1564
|
width: 100%;
|
|
1534
|
-
overflow-y: auto;
|
|
1535
1565
|
}
|
|
1536
1566
|
|
|
1537
1567
|
.block-editor-block-variation-transforms {
|
|
@@ -1654,6 +1684,10 @@
|
|
|
1654
1684
|
min-width: 0;
|
|
1655
1685
|
}
|
|
1656
1686
|
|
|
1687
|
+
.block-editor-color-gradient-control__tabs .block-editor-color-gradient-control__panel {
|
|
1688
|
+
padding: 16px;
|
|
1689
|
+
}
|
|
1690
|
+
|
|
1657
1691
|
.block-editor-panel-color-gradient-settings.block-editor-panel-color-gradient-settings, .block-editor-panel-color-gradient-settings.block-editor-panel-color-gradient-settings > div:not(:first-of-type) {
|
|
1658
1692
|
display: block;
|
|
1659
1693
|
}
|
|
@@ -1669,8 +1703,9 @@
|
|
|
1669
1703
|
margin-bottom: inherit;
|
|
1670
1704
|
}
|
|
1671
1705
|
|
|
1672
|
-
.block-editor-panel-color-gradient-settings__dropdown-content .
|
|
1673
|
-
width:
|
|
1706
|
+
.block-editor-panel-color-gradient-settings__dropdown-content .block-editor-color-gradient-control__panel {
|
|
1707
|
+
width: 260px;
|
|
1708
|
+
padding: 16px;
|
|
1674
1709
|
}
|
|
1675
1710
|
|
|
1676
1711
|
.block-editor-panel-color-gradient-settings__color-indicator {
|
|
@@ -1686,6 +1721,7 @@
|
|
|
1686
1721
|
*/
|
|
1687
1722
|
.block-editor-tools-panel-color-gradient-settings__item {
|
|
1688
1723
|
padding: 0;
|
|
1724
|
+
max-width: 100%;
|
|
1689
1725
|
border-right: 1px solid rgba(0, 0, 0, 0.1);
|
|
1690
1726
|
border-left: 1px solid rgba(0, 0, 0, 0.1);
|
|
1691
1727
|
border-bottom: 1px solid rgba(0, 0, 0, 0.1);
|
|
@@ -1710,16 +1746,27 @@
|
|
|
1710
1746
|
padding: 0;
|
|
1711
1747
|
}
|
|
1712
1748
|
.block-editor-tools-panel-color-gradient-settings__dropdown > button {
|
|
1713
|
-
height:
|
|
1749
|
+
height: auto;
|
|
1750
|
+
padding-top: 10px;
|
|
1751
|
+
padding-bottom: 10px;
|
|
1752
|
+
text-align: right;
|
|
1714
1753
|
}
|
|
1715
1754
|
.block-editor-tools-panel-color-gradient-settings__dropdown > button.is-open {
|
|
1716
1755
|
background: #f0f0f0;
|
|
1717
1756
|
color: var(--wp-admin-theme-color);
|
|
1718
1757
|
}
|
|
1758
|
+
.block-editor-tools-panel-color-gradient-settings__dropdown .block-editor-panel-color-gradient-settings__color-name {
|
|
1759
|
+
white-space: nowrap;
|
|
1760
|
+
overflow: hidden;
|
|
1761
|
+
text-overflow: ellipsis;
|
|
1762
|
+
}
|
|
1719
1763
|
|
|
1720
1764
|
.block-editor-panel-color-gradient-settings__dropdown {
|
|
1721
1765
|
width: 100%;
|
|
1722
1766
|
}
|
|
1767
|
+
.block-editor-panel-color-gradient-settings__dropdown .component-color-indicator {
|
|
1768
|
+
flex-shrink: 0;
|
|
1769
|
+
}
|
|
1723
1770
|
|
|
1724
1771
|
.block-editor-contrast-checker > .components-notice {
|
|
1725
1772
|
margin: 0;
|
|
@@ -2548,7 +2595,7 @@
|
|
|
2548
2595
|
align-items: center;
|
|
2549
2596
|
width: 100%;
|
|
2550
2597
|
height: auto;
|
|
2551
|
-
padding: 6px 0 6px
|
|
2598
|
+
padding: 6px 0 6px 4px;
|
|
2552
2599
|
text-align: right;
|
|
2553
2600
|
color: #1e1e1e;
|
|
2554
2601
|
border-radius: 2px;
|
|
@@ -2666,7 +2713,7 @@
|
|
|
2666
2713
|
padding: 0;
|
|
2667
2714
|
}
|
|
2668
2715
|
.block-editor-list-view-leaf .block-editor-list-view-block__menu-cell {
|
|
2669
|
-
padding-left:
|
|
2716
|
+
padding-left: 4px;
|
|
2670
2717
|
}
|
|
2671
2718
|
.block-editor-list-view-leaf .block-editor-list-view-block__menu-cell .components-button.has-icon {
|
|
2672
2719
|
height: 24px;
|
|
@@ -2740,13 +2787,24 @@
|
|
|
2740
2787
|
.block-editor-list-view-leaf .block-editor-inserter__toggle:active {
|
|
2741
2788
|
color: #fff;
|
|
2742
2789
|
}
|
|
2790
|
+
.block-editor-list-view-leaf .block-editor-list-view-block-select-button__label-wrapper {
|
|
2791
|
+
min-width: 120px;
|
|
2792
|
+
}
|
|
2793
|
+
.block-editor-list-view-leaf .block-editor-list-view-block-select-button__title {
|
|
2794
|
+
flex: 1;
|
|
2795
|
+
position: relative;
|
|
2796
|
+
}
|
|
2797
|
+
.block-editor-list-view-leaf .block-editor-list-view-block-select-button__title .components-truncate {
|
|
2798
|
+
position: absolute;
|
|
2799
|
+
width: 100%;
|
|
2800
|
+
transform: translateY(-50%);
|
|
2801
|
+
}
|
|
2743
2802
|
.block-editor-list-view-leaf .block-editor-list-view-block-select-button__anchor {
|
|
2744
2803
|
background: rgba(0, 0, 0, 0.1);
|
|
2745
2804
|
border-radius: 2px;
|
|
2746
2805
|
display: inline-block;
|
|
2747
2806
|
padding: 2px 6px;
|
|
2748
|
-
|
|
2749
|
-
max-width: 120px;
|
|
2807
|
+
max-width: min(100px, 40%);
|
|
2750
2808
|
overflow: hidden;
|
|
2751
2809
|
text-overflow: ellipsis;
|
|
2752
2810
|
}
|
|
@@ -4067,7 +4125,7 @@ figcaption.block-editor-rich-text__editable [data-rich-text-placeholder]::before
|
|
|
4067
4125
|
|
|
4068
4126
|
.block-editor-block-patterns-explorer__sidebar {
|
|
4069
4127
|
position: absolute;
|
|
4070
|
-
top:
|
|
4128
|
+
top: 76px;
|
|
4071
4129
|
right: 0;
|
|
4072
4130
|
bottom: 0;
|
|
4073
4131
|
width: 280px;
|
package/build-style/style.css
CHANGED
|
@@ -177,7 +177,7 @@
|
|
|
177
177
|
cursor: default;
|
|
178
178
|
}
|
|
179
179
|
.block-editor-block-list__layout.is-navigate-mode .block-editor-block-list__block.is-selected::after, .block-editor-block-list__layout.is-navigate-mode .block-editor-block-list__block.is-hovered::after,
|
|
180
|
-
.block-editor-block-list__layout .block-editor-block-list__block.is-multi-selected:not(
|
|
180
|
+
.block-editor-block-list__layout .block-editor-block-list__block.is-multi-selected:not(.is-partially-selected)::after,
|
|
181
181
|
.block-editor-block-list__layout .block-editor-block-list__block.is-highlighted::after,
|
|
182
182
|
.block-editor-block-list__layout .block-editor-block-list__block.is-highlighted ~ .is-multi-selected::after {
|
|
183
183
|
position: absolute;
|
|
@@ -193,13 +193,13 @@
|
|
|
193
193
|
outline: 2px solid transparent;
|
|
194
194
|
}
|
|
195
195
|
.is-dark-theme .block-editor-block-list__layout.is-navigate-mode .block-editor-block-list__block.is-selected::after, .is-dark-theme .block-editor-block-list__layout.is-navigate-mode .block-editor-block-list__block.is-hovered::after,
|
|
196
|
-
.is-dark-theme .block-editor-block-list__layout .block-editor-block-list__block.is-multi-selected:not(
|
|
196
|
+
.is-dark-theme .block-editor-block-list__layout .block-editor-block-list__block.is-multi-selected:not(.is-partially-selected)::after,
|
|
197
197
|
.is-dark-theme .block-editor-block-list__layout .block-editor-block-list__block.is-highlighted::after,
|
|
198
198
|
.is-dark-theme .block-editor-block-list__layout .block-editor-block-list__block.is-highlighted ~ .is-multi-selected::after {
|
|
199
199
|
box-shadow: 0 0 0 1px #fff;
|
|
200
200
|
}
|
|
201
201
|
.block-editor-block-list__layout.is-navigate-mode .block-editor-block-list__block.is-selected .components-placeholder ::selection, .block-editor-block-list__layout.is-navigate-mode .block-editor-block-list__block.is-hovered .components-placeholder ::selection,
|
|
202
|
-
.block-editor-block-list__layout .block-editor-block-list__block.is-multi-selected:not(
|
|
202
|
+
.block-editor-block-list__layout .block-editor-block-list__block.is-multi-selected:not(.is-partially-selected) .components-placeholder ::selection,
|
|
203
203
|
.block-editor-block-list__layout .block-editor-block-list__block.is-highlighted .components-placeholder ::selection,
|
|
204
204
|
.block-editor-block-list__layout .block-editor-block-list__block.is-highlighted ~ .is-multi-selected .components-placeholder ::selection {
|
|
205
205
|
background: transparent;
|
|
@@ -709,6 +709,15 @@
|
|
|
709
709
|
border-radius: 2px;
|
|
710
710
|
}
|
|
711
711
|
|
|
712
|
+
.block-editor-block-lock-modal__template-lock {
|
|
713
|
+
border-top: 1px solid #ddd;
|
|
714
|
+
margin-top: 16px;
|
|
715
|
+
padding: 12px 0;
|
|
716
|
+
}
|
|
717
|
+
.block-editor-block-lock-modal__template-lock .components-base-control__field {
|
|
718
|
+
margin: 0;
|
|
719
|
+
}
|
|
720
|
+
|
|
712
721
|
.block-editor-block-lock-modal__actions {
|
|
713
722
|
margin-top: 24px;
|
|
714
723
|
}
|
|
@@ -1074,7 +1083,20 @@
|
|
|
1074
1083
|
overflow-y: visible;
|
|
1075
1084
|
pointer-events: none;
|
|
1076
1085
|
}
|
|
1077
|
-
.components-popover.block-editor-block-popover .components-popover__content
|
|
1086
|
+
.components-popover.block-editor-block-popover:not(.block-editor-block-popover__inbetween) .components-popover__content * {
|
|
1087
|
+
pointer-events: all;
|
|
1088
|
+
}
|
|
1089
|
+
|
|
1090
|
+
.components-popover.block-editor-block-popover__inbetween {
|
|
1091
|
+
pointer-events: none;
|
|
1092
|
+
}
|
|
1093
|
+
.components-popover.block-editor-block-popover__inbetween * {
|
|
1094
|
+
pointer-events: none;
|
|
1095
|
+
}
|
|
1096
|
+
.components-popover.block-editor-block-popover__inbetween .is-with-inserter {
|
|
1097
|
+
pointer-events: all;
|
|
1098
|
+
}
|
|
1099
|
+
.components-popover.block-editor-block-popover__inbetween .is-with-inserter * {
|
|
1078
1100
|
pointer-events: all;
|
|
1079
1101
|
}
|
|
1080
1102
|
|
|
@@ -1176,6 +1198,12 @@
|
|
|
1176
1198
|
.block-editor-block-styles__variants .block-editor-block-styles__item.is-active:focus {
|
|
1177
1199
|
box-shadow: inset 0 0 0 1px #fff, 0 0 0 2px var(--wp-admin-theme-color);
|
|
1178
1200
|
}
|
|
1201
|
+
.block-editor-block-styles__variants .block-editor-block-styles__item-text {
|
|
1202
|
+
word-break: break-all;
|
|
1203
|
+
white-space: normal;
|
|
1204
|
+
text-align: start;
|
|
1205
|
+
text-align-last: center;
|
|
1206
|
+
}
|
|
1179
1207
|
|
|
1180
1208
|
.block-editor-block-styles__block-preview-container,
|
|
1181
1209
|
.block-editor-block-styles__block-preview-container * {
|
|
@@ -1434,6 +1462,8 @@
|
|
|
1434
1462
|
display: block;
|
|
1435
1463
|
width: 100%;
|
|
1436
1464
|
padding: 32px;
|
|
1465
|
+
padding-bottom: 0;
|
|
1466
|
+
padding-top: 0;
|
|
1437
1467
|
column-count: 2;
|
|
1438
1468
|
}
|
|
1439
1469
|
@media (min-width: 1440px) {
|
|
@@ -1465,7 +1495,8 @@
|
|
|
1465
1495
|
text-align: left;
|
|
1466
1496
|
margin: 0;
|
|
1467
1497
|
color: #1e1e1e;
|
|
1468
|
-
|
|
1498
|
+
position: absolute;
|
|
1499
|
+
bottom: 0;
|
|
1469
1500
|
background-color: #fff;
|
|
1470
1501
|
display: flex;
|
|
1471
1502
|
flex-direction: row;
|
|
@@ -1531,7 +1562,6 @@
|
|
|
1531
1562
|
.block-editor-block-pattern-setup__carousel,
|
|
1532
1563
|
.block-editor-block-pattern-setup__grid {
|
|
1533
1564
|
width: 100%;
|
|
1534
|
-
overflow-y: auto;
|
|
1535
1565
|
}
|
|
1536
1566
|
|
|
1537
1567
|
.block-editor-block-variation-transforms {
|
|
@@ -1654,6 +1684,10 @@
|
|
|
1654
1684
|
min-width: 0;
|
|
1655
1685
|
}
|
|
1656
1686
|
|
|
1687
|
+
.block-editor-color-gradient-control__tabs .block-editor-color-gradient-control__panel {
|
|
1688
|
+
padding: 16px;
|
|
1689
|
+
}
|
|
1690
|
+
|
|
1657
1691
|
.block-editor-panel-color-gradient-settings.block-editor-panel-color-gradient-settings, .block-editor-panel-color-gradient-settings.block-editor-panel-color-gradient-settings > div:not(:first-of-type) {
|
|
1658
1692
|
display: block;
|
|
1659
1693
|
}
|
|
@@ -1669,8 +1703,9 @@
|
|
|
1669
1703
|
margin-bottom: inherit;
|
|
1670
1704
|
}
|
|
1671
1705
|
|
|
1672
|
-
.block-editor-panel-color-gradient-settings__dropdown-content .
|
|
1673
|
-
width:
|
|
1706
|
+
.block-editor-panel-color-gradient-settings__dropdown-content .block-editor-color-gradient-control__panel {
|
|
1707
|
+
width: 260px;
|
|
1708
|
+
padding: 16px;
|
|
1674
1709
|
}
|
|
1675
1710
|
|
|
1676
1711
|
.block-editor-panel-color-gradient-settings__color-indicator {
|
|
@@ -1686,6 +1721,7 @@
|
|
|
1686
1721
|
*/
|
|
1687
1722
|
.block-editor-tools-panel-color-gradient-settings__item {
|
|
1688
1723
|
padding: 0;
|
|
1724
|
+
max-width: 100%;
|
|
1689
1725
|
border-left: 1px solid rgba(0, 0, 0, 0.1);
|
|
1690
1726
|
border-right: 1px solid rgba(0, 0, 0, 0.1);
|
|
1691
1727
|
border-bottom: 1px solid rgba(0, 0, 0, 0.1);
|
|
@@ -1710,16 +1746,27 @@
|
|
|
1710
1746
|
padding: 0;
|
|
1711
1747
|
}
|
|
1712
1748
|
.block-editor-tools-panel-color-gradient-settings__dropdown > button {
|
|
1713
|
-
height:
|
|
1749
|
+
height: auto;
|
|
1750
|
+
padding-top: 10px;
|
|
1751
|
+
padding-bottom: 10px;
|
|
1752
|
+
text-align: left;
|
|
1714
1753
|
}
|
|
1715
1754
|
.block-editor-tools-panel-color-gradient-settings__dropdown > button.is-open {
|
|
1716
1755
|
background: #f0f0f0;
|
|
1717
1756
|
color: var(--wp-admin-theme-color);
|
|
1718
1757
|
}
|
|
1758
|
+
.block-editor-tools-panel-color-gradient-settings__dropdown .block-editor-panel-color-gradient-settings__color-name {
|
|
1759
|
+
white-space: nowrap;
|
|
1760
|
+
overflow: hidden;
|
|
1761
|
+
text-overflow: ellipsis;
|
|
1762
|
+
}
|
|
1719
1763
|
|
|
1720
1764
|
.block-editor-panel-color-gradient-settings__dropdown {
|
|
1721
1765
|
width: 100%;
|
|
1722
1766
|
}
|
|
1767
|
+
.block-editor-panel-color-gradient-settings__dropdown .component-color-indicator {
|
|
1768
|
+
flex-shrink: 0;
|
|
1769
|
+
}
|
|
1723
1770
|
|
|
1724
1771
|
.block-editor-contrast-checker > .components-notice {
|
|
1725
1772
|
margin: 0;
|
|
@@ -2548,7 +2595,7 @@
|
|
|
2548
2595
|
align-items: center;
|
|
2549
2596
|
width: 100%;
|
|
2550
2597
|
height: auto;
|
|
2551
|
-
padding: 6px
|
|
2598
|
+
padding: 6px 4px 6px 0;
|
|
2552
2599
|
text-align: left;
|
|
2553
2600
|
color: #1e1e1e;
|
|
2554
2601
|
border-radius: 2px;
|
|
@@ -2666,7 +2713,7 @@
|
|
|
2666
2713
|
padding: 0;
|
|
2667
2714
|
}
|
|
2668
2715
|
.block-editor-list-view-leaf .block-editor-list-view-block__menu-cell {
|
|
2669
|
-
padding-right:
|
|
2716
|
+
padding-right: 4px;
|
|
2670
2717
|
}
|
|
2671
2718
|
.block-editor-list-view-leaf .block-editor-list-view-block__menu-cell .components-button.has-icon {
|
|
2672
2719
|
height: 24px;
|
|
@@ -2740,13 +2787,24 @@
|
|
|
2740
2787
|
.block-editor-list-view-leaf .block-editor-inserter__toggle:active {
|
|
2741
2788
|
color: #fff;
|
|
2742
2789
|
}
|
|
2790
|
+
.block-editor-list-view-leaf .block-editor-list-view-block-select-button__label-wrapper {
|
|
2791
|
+
min-width: 120px;
|
|
2792
|
+
}
|
|
2793
|
+
.block-editor-list-view-leaf .block-editor-list-view-block-select-button__title {
|
|
2794
|
+
flex: 1;
|
|
2795
|
+
position: relative;
|
|
2796
|
+
}
|
|
2797
|
+
.block-editor-list-view-leaf .block-editor-list-view-block-select-button__title .components-truncate {
|
|
2798
|
+
position: absolute;
|
|
2799
|
+
width: 100%;
|
|
2800
|
+
transform: translateY(-50%);
|
|
2801
|
+
}
|
|
2743
2802
|
.block-editor-list-view-leaf .block-editor-list-view-block-select-button__anchor {
|
|
2744
2803
|
background: rgba(0, 0, 0, 0.1);
|
|
2745
2804
|
border-radius: 2px;
|
|
2746
2805
|
display: inline-block;
|
|
2747
2806
|
padding: 2px 6px;
|
|
2748
|
-
|
|
2749
|
-
max-width: 120px;
|
|
2807
|
+
max-width: min(100px, 40%);
|
|
2750
2808
|
overflow: hidden;
|
|
2751
2809
|
text-overflow: ellipsis;
|
|
2752
2810
|
}
|
|
@@ -4067,7 +4125,7 @@ figcaption.block-editor-rich-text__editable [data-rich-text-placeholder]::before
|
|
|
4067
4125
|
|
|
4068
4126
|
.block-editor-block-patterns-explorer__sidebar {
|
|
4069
4127
|
position: absolute;
|
|
4070
|
-
top:
|
|
4128
|
+
top: 76px;
|
|
4071
4129
|
left: 0;
|
|
4072
4130
|
bottom: 0;
|
|
4073
4131
|
width: 280px;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wordpress/block-editor",
|
|
3
|
-
"version": "9.
|
|
3
|
+
"version": "9.7.0",
|
|
4
4
|
"description": "Generic block editor.",
|
|
5
5
|
"author": "The WordPress Contributors",
|
|
6
6
|
"license": "GPL-2.0-or-later",
|
|
@@ -33,32 +33,32 @@
|
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"@babel/runtime": "^7.16.0",
|
|
35
35
|
"@react-spring/web": "^9.4.5",
|
|
36
|
-
"@wordpress/a11y": "^3.
|
|
37
|
-
"@wordpress/api-fetch": "^6.
|
|
38
|
-
"@wordpress/blob": "^3.
|
|
39
|
-
"@wordpress/blocks": "^11.
|
|
40
|
-
"@wordpress/components": "^19.
|
|
41
|
-
"@wordpress/compose": "^5.
|
|
42
|
-
"@wordpress/data": "^6.
|
|
43
|
-
"@wordpress/date": "^4.
|
|
44
|
-
"@wordpress/deprecated": "^3.
|
|
45
|
-
"@wordpress/dom": "^3.
|
|
46
|
-
"@wordpress/element": "^4.
|
|
47
|
-
"@wordpress/hooks": "^3.
|
|
48
|
-
"@wordpress/html-entities": "^3.
|
|
49
|
-
"@wordpress/i18n": "^4.
|
|
50
|
-
"@wordpress/icons": "^9.
|
|
51
|
-
"@wordpress/is-shallow-equal": "^4.
|
|
52
|
-
"@wordpress/keyboard-shortcuts": "^3.
|
|
53
|
-
"@wordpress/keycodes": "^3.
|
|
54
|
-
"@wordpress/notices": "^3.
|
|
55
|
-
"@wordpress/rich-text": "^5.
|
|
56
|
-
"@wordpress/shortcode": "^3.
|
|
57
|
-
"@wordpress/style-engine": "^0.
|
|
58
|
-
"@wordpress/token-list": "^2.
|
|
59
|
-
"@wordpress/url": "^3.
|
|
60
|
-
"@wordpress/warning": "^2.
|
|
61
|
-
"@wordpress/wordcount": "^3.
|
|
36
|
+
"@wordpress/a11y": "^3.15.0",
|
|
37
|
+
"@wordpress/api-fetch": "^6.12.0",
|
|
38
|
+
"@wordpress/blob": "^3.15.0",
|
|
39
|
+
"@wordpress/blocks": "^11.14.0",
|
|
40
|
+
"@wordpress/components": "^19.17.0",
|
|
41
|
+
"@wordpress/compose": "^5.13.0",
|
|
42
|
+
"@wordpress/data": "^6.15.0",
|
|
43
|
+
"@wordpress/date": "^4.15.0",
|
|
44
|
+
"@wordpress/deprecated": "^3.15.0",
|
|
45
|
+
"@wordpress/dom": "^3.15.0",
|
|
46
|
+
"@wordpress/element": "^4.13.0",
|
|
47
|
+
"@wordpress/hooks": "^3.15.0",
|
|
48
|
+
"@wordpress/html-entities": "^3.15.0",
|
|
49
|
+
"@wordpress/i18n": "^4.15.0",
|
|
50
|
+
"@wordpress/icons": "^9.6.0",
|
|
51
|
+
"@wordpress/is-shallow-equal": "^4.15.0",
|
|
52
|
+
"@wordpress/keyboard-shortcuts": "^3.13.0",
|
|
53
|
+
"@wordpress/keycodes": "^3.15.0",
|
|
54
|
+
"@wordpress/notices": "^3.15.0",
|
|
55
|
+
"@wordpress/rich-text": "^5.13.0",
|
|
56
|
+
"@wordpress/shortcode": "^3.15.0",
|
|
57
|
+
"@wordpress/style-engine": "^0.14.0",
|
|
58
|
+
"@wordpress/token-list": "^2.15.0",
|
|
59
|
+
"@wordpress/url": "^3.16.0",
|
|
60
|
+
"@wordpress/warning": "^2.15.0",
|
|
61
|
+
"@wordpress/wordcount": "^3.15.0",
|
|
62
62
|
"classnames": "^2.3.1",
|
|
63
63
|
"colord": "^2.7.0",
|
|
64
64
|
"diff": "^4.0.2",
|
|
@@ -77,5 +77,5 @@
|
|
|
77
77
|
"publishConfig": {
|
|
78
78
|
"access": "public"
|
|
79
79
|
},
|
|
80
|
-
"gitHead": "
|
|
80
|
+
"gitHead": "08358f53b627a15148c3a3e433cdf58cf8714aa4"
|
|
81
81
|
}
|
|
@@ -1,27 +1,62 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* External dependencies
|
|
3
|
+
*/
|
|
4
|
+
import { TouchableWithoutFeedback } from 'react-native';
|
|
5
|
+
|
|
1
6
|
/**
|
|
2
7
|
* WordPress dependencies
|
|
3
8
|
*/
|
|
4
9
|
import { __, sprintf } from '@wordpress/i18n';
|
|
10
|
+
import { useSelect, useDispatch } from '@wordpress/data';
|
|
11
|
+
import { createBlock } from '@wordpress/blocks';
|
|
5
12
|
|
|
6
13
|
/**
|
|
7
14
|
* Internal dependencies
|
|
8
15
|
*/
|
|
9
16
|
import Warning from '../warning';
|
|
17
|
+
import { store as blockEditorStore } from '../../store';
|
|
10
18
|
|
|
11
|
-
export default function BlockInvalidWarning( { blockTitle, icon } ) {
|
|
19
|
+
export default function BlockInvalidWarning( { blockTitle, icon, clientId } ) {
|
|
12
20
|
const accessibilityLabel = sprintf(
|
|
13
21
|
/* translators: accessibility text for blocks with invalid content. %d: localized block title */
|
|
14
22
|
__( '%s block. This block has invalid content' ),
|
|
15
23
|
blockTitle
|
|
16
24
|
);
|
|
17
25
|
|
|
26
|
+
const selector = ( select ) => {
|
|
27
|
+
const { getBlock } = select( blockEditorStore );
|
|
28
|
+
const block = getBlock( clientId );
|
|
29
|
+
return {
|
|
30
|
+
block,
|
|
31
|
+
};
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
const { block } = useSelect( selector, [ clientId ] );
|
|
35
|
+
|
|
36
|
+
const { replaceBlock } = useDispatch( blockEditorStore );
|
|
37
|
+
|
|
38
|
+
const recoverBlock = ( { name, attributes, innerBlocks } ) =>
|
|
39
|
+
createBlock( name, attributes, innerBlocks );
|
|
40
|
+
|
|
41
|
+
const attemptBlockRecovery = () => {
|
|
42
|
+
replaceBlock( block.clientId, recoverBlock( block ) );
|
|
43
|
+
};
|
|
44
|
+
|
|
18
45
|
return (
|
|
19
|
-
<
|
|
20
|
-
|
|
21
|
-
message={ __( 'Problem displaying block' ) }
|
|
22
|
-
icon={ icon }
|
|
46
|
+
<TouchableWithoutFeedback
|
|
47
|
+
onPress={ attemptBlockRecovery }
|
|
23
48
|
accessible={ true }
|
|
24
|
-
|
|
25
|
-
|
|
49
|
+
accessibilityRole={ 'button' }
|
|
50
|
+
>
|
|
51
|
+
<Warning
|
|
52
|
+
title={ blockTitle }
|
|
53
|
+
// eslint-disable-next-line @wordpress/i18n-no-collapsible-whitespace
|
|
54
|
+
message={ __(
|
|
55
|
+
'Problem displaying block. \nTap to attempt block recovery.'
|
|
56
|
+
) }
|
|
57
|
+
icon={ icon }
|
|
58
|
+
accessibilityLabel={ accessibilityLabel }
|
|
59
|
+
/>
|
|
60
|
+
</TouchableWithoutFeedback>
|
|
26
61
|
);
|
|
27
62
|
}
|