@wordpress/block-library 9.8.7 → 9.10.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 +4 -0
- package/build/audio/edit.native.js +1 -1
- package/build/audio/edit.native.js.map +1 -1
- package/build/avatar/index.js +2 -1
- package/build/avatar/index.js.map +1 -1
- package/build/block/edit.js.map +1 -1
- package/build/block/edit.native.js +2 -2
- package/build/block/edit.native.js.map +1 -1
- package/build/block-keyboard-shortcuts/index.js.map +1 -1
- package/build/button/deprecated.js.map +1 -1
- package/build/button/edit.js.map +1 -1
- package/build/button/edit.native.js.map +1 -1
- package/build/button/get-updated-link-attributes.js.map +1 -1
- package/build/button/save.js.map +1 -1
- package/build/buttons/deprecated.js.map +1 -1
- package/build/categories/edit.js +1 -1
- package/build/categories/edit.js.map +1 -1
- package/build/column/deprecated.js.map +1 -1
- package/build/column/edit.js +1 -1
- package/build/column/edit.js.map +1 -1
- package/build/column/edit.native.js.map +1 -1
- package/build/column/save.js.map +1 -1
- package/build/columns/deprecated.js.map +1 -1
- package/build/columns/edit.js.map +1 -1
- package/build/columns/edit.native.js +1 -1
- package/build/columns/edit.native.js.map +1 -1
- package/build/columns/save.js.map +1 -1
- package/build/columns/transforms.js.map +1 -1
- package/build/columns/utils.js.map +1 -1
- package/build/comment-author-avatar/edit.js.map +1 -1
- package/build/comment-author-name/edit.js.map +1 -1
- package/build/comment-author-name/index.js +2 -1
- package/build/comment-author-name/index.js.map +1 -1
- package/build/comment-content/edit.js.map +1 -1
- package/build/comment-content/index.js +2 -1
- package/build/comment-content/index.js.map +1 -1
- package/build/comment-date/index.js +2 -1
- package/build/comment-date/index.js.map +1 -1
- package/build/comment-edit-link/edit.js.map +1 -1
- package/build/comment-edit-link/index.js +2 -1
- package/build/comment-edit-link/index.js.map +1 -1
- package/build/comment-reply-link/edit.js.map +1 -1
- package/build/comment-reply-link/index.js +2 -1
- package/build/comment-reply-link/index.js.map +1 -1
- package/build/comment-template/hooks.js.map +1 -1
- package/build/comments/edit/comments-legacy.js.map +1 -1
- package/build/comments-pagination-next/edit.js.map +1 -1
- package/build/comments-pagination-next/index.js +5 -0
- package/build/comments-pagination-next/index.js.map +1 -1
- package/build/comments-pagination-numbers/edit.js.map +1 -1
- package/build/comments-pagination-numbers/index.js +2 -1
- package/build/comments-pagination-numbers/index.js.map +1 -1
- package/build/comments-pagination-previous/edit.js.map +1 -1
- package/build/comments-pagination-previous/index.js +5 -0
- package/build/comments-pagination-previous/index.js.map +1 -1
- package/build/comments-title/edit.js +2 -2
- package/build/comments-title/edit.js.map +1 -1
- package/build/comments-title/index.js +2 -1
- package/build/comments-title/index.js.map +1 -1
- package/build/cover/controls.native.js.map +1 -1
- package/build/cover/deprecated.js.map +1 -1
- package/build/cover/edit/index.js.map +1 -1
- package/build/cover/edit/inspector-controls.js +74 -30
- package/build/cover/edit/inspector-controls.js.map +1 -1
- package/build/cover/save.js.map +1 -1
- package/build/cover/shared.js.map +1 -1
- package/build/embed/deprecated.js.map +1 -1
- package/build/embed/edit.js +16 -3
- package/build/embed/edit.js.map +1 -1
- package/build/embed/embed-preview.js +5 -19
- package/build/embed/embed-preview.js.map +1 -1
- package/build/embed/embed-preview.native.js +1 -1
- package/build/embed/embed-preview.native.js.map +1 -1
- package/build/embed/save.js.map +1 -1
- package/build/embed/transforms.js.map +1 -1
- package/build/embed/variations.js +1 -1
- package/build/embed/variations.js.map +1 -1
- package/build/embed/wp-embed-preview.native.js.map +1 -1
- package/build/file/deprecated.js +3 -3
- package/build/file/deprecated.js.map +1 -1
- package/build/file/edit.js.map +1 -1
- package/build/file/index.js +8 -4
- package/build/file/index.js.map +1 -1
- package/build/file/save.js.map +1 -1
- package/build/footnotes/edit.js.map +1 -1
- package/build/footnotes/format.js.map +1 -1
- package/build/form/edit.js.map +1 -1
- package/build/form-submission-notification/edit.js.map +1 -1
- package/build/form-submission-notification/save.js.map +1 -1
- package/build/freeform/edit.js.map +1 -1
- package/build/freeform/modal.js.map +1 -1
- package/build/gallery/deprecated.js.map +1 -1
- package/build/gallery/edit.js +2 -2
- package/build/gallery/edit.js.map +1 -1
- package/build/gallery/gallery.js.map +1 -1
- package/build/gallery/gallery.native.js +1 -1
- package/build/gallery/gallery.native.js.map +1 -1
- package/build/gallery/gap-styles.js.map +1 -1
- package/build/gallery/save.js.map +1 -1
- package/build/group/placeholder.js.map +1 -1
- package/build/heading/deprecated.js.map +1 -1
- package/build/heading/edit.js.map +1 -1
- package/build/heading/edit.native.js.map +1 -1
- package/build/heading/index.js +2 -2
- package/build/heading/index.js.map +1 -1
- package/build/heading/save.js.map +1 -1
- package/build/heading/transforms.js.map +1 -1
- package/build/home-link/edit.js.map +1 -1
- package/build/html/preview.js.map +1 -1
- package/build/image/deprecated.js.map +1 -1
- package/build/image/edit.js +1 -1
- package/build/image/edit.js.map +1 -1
- package/build/image/edit.native.js +1 -1
- package/build/image/edit.native.js.map +1 -1
- package/build/image/image.js +3 -3
- package/build/image/image.js.map +1 -1
- package/build/image/save.js.map +1 -1
- package/build/image/view.js.map +1 -1
- package/build/index.native.js.map +1 -1
- package/build/latest-posts/edit.js +2 -2
- package/build/latest-posts/edit.js.map +1 -1
- package/build/media-text/deprecated.js.map +1 -1
- package/build/media-text/edit.js.map +1 -1
- package/build/media-text/edit.native.js.map +1 -1
- package/build/media-text/image-fill.js.map +1 -1
- package/build/media-text/save.js.map +1 -1
- package/build/missing/edit.js +2 -2
- package/build/missing/edit.js.map +1 -1
- package/build/more/edit.js.map +1 -1
- package/build/more/save.js.map +1 -1
- package/build/navigation/edit/accessible-menu-description.js.map +1 -1
- package/build/navigation/edit/index.js.map +1 -1
- package/build/navigation/edit/leaf-more-menu.js +1 -1
- package/build/navigation/edit/leaf-more-menu.js.map +1 -1
- package/build/navigation/edit/menu-inspector-controls.js +1 -1
- package/build/navigation/edit/menu-inspector-controls.js.map +1 -1
- package/build/navigation/edit/responsive-wrapper.js.map +1 -1
- package/build/navigation/edit/use-convert-classic-menu-to-block-menu.js.map +1 -1
- package/build/navigation/edit/use-create-navigation-menu.js.map +1 -1
- package/build/navigation/edit/use-generate-default-navigation-title.js.map +1 -1
- package/build/navigation/edit/utils.js.map +1 -1
- package/build/navigation/use-navigation-menu.js.map +1 -1
- package/build/navigation-link/edit.js.map +1 -1
- package/build/navigation-link/link-ui.js.map +1 -1
- package/build/nextpage/edit.native.js +1 -1
- package/build/nextpage/edit.native.js.map +1 -1
- package/build/page-list-item/edit.js +1 -1
- package/build/page-list-item/edit.js.map +1 -1
- package/build/paragraph/deprecated.js.map +1 -1
- package/build/paragraph/edit.js.map +1 -1
- package/build/paragraph/save.js.map +1 -1
- package/build/pattern/recursion-detector.js +1 -0
- package/build/pattern/recursion-detector.js.map +1 -1
- package/build/post-author/edit.js.map +1 -1
- package/build/post-author-biography/edit.js.map +1 -1
- package/build/post-author-name/edit.js.map +1 -1
- package/build/post-comments-count/edit.js.map +1 -1
- package/build/post-comments-form/edit.js.map +1 -1
- package/build/post-comments-form/form.js +1 -1
- package/build/post-comments-form/form.js.map +1 -1
- package/build/post-comments-link/edit.js +1 -1
- package/build/post-comments-link/edit.js.map +1 -1
- package/build/post-date/edit.js.map +1 -1
- package/build/post-excerpt/edit.js.map +1 -1
- package/build/post-navigation-link/edit.js.map +1 -1
- package/build/post-navigation-link/index.js +6 -0
- package/build/post-navigation-link/index.js.map +1 -1
- package/build/post-navigation-link/variations.js +14 -2
- package/build/post-navigation-link/variations.js.map +1 -1
- package/build/post-template/edit.js.map +1 -1
- package/build/post-terms/edit.js.map +1 -1
- package/build/post-time-to-read/edit.js +1 -1
- package/build/post-time-to-read/edit.js.map +1 -1
- package/build/post-time-to-read/index.js +2 -1
- package/build/post-time-to-read/index.js.map +1 -1
- package/build/post-title/edit.js.map +1 -1
- package/build/pullquote/deprecated.js.map +1 -1
- package/build/pullquote/edit.js.map +1 -1
- package/build/pullquote/save.js.map +1 -1
- package/build/pullquote/shared.js.map +1 -1
- package/build/query/edit/inspector-controls/author-control.js +1 -0
- package/build/query/edit/inspector-controls/author-control.js.map +1 -1
- package/build/query/edit/inspector-controls/index.js +7 -10
- package/build/query/edit/inspector-controls/index.js.map +1 -1
- package/build/query/edit/inspector-controls/order-control.js.map +1 -1
- package/build/query/edit/inspector-controls/pages-control.js +1 -1
- package/build/query/edit/inspector-controls/pages-control.js.map +1 -1
- package/build/query/edit/inspector-controls/parent-control.js +1 -0
- package/build/query/edit/inspector-controls/parent-control.js.map +1 -1
- package/build/query/edit/inspector-controls/per-page-control.js +1 -1
- package/build/query/edit/inspector-controls/per-page-control.js.map +1 -1
- package/build/query/edit/inspector-controls/taxonomy-controls.js +1 -0
- package/build/query/edit/inspector-controls/taxonomy-controls.js.map +1 -1
- package/build/query/edit/pattern-selection-modal.js +1 -1
- package/build/query/edit/pattern-selection-modal.js.map +1 -1
- package/build/query/index.js +1 -0
- package/build/query/index.js.map +1 -1
- package/build/query/utils.js.map +1 -1
- package/build/query/view.js.map +1 -1
- package/build/query-no-results/index.js +8 -0
- package/build/query-no-results/index.js.map +1 -1
- package/build/query-pagination-next/edit.js.map +1 -1
- package/build/query-pagination-numbers/edit.js.map +1 -1
- package/build/query-pagination-numbers/index.js +2 -1
- package/build/query-pagination-numbers/index.js.map +1 -1
- package/build/query-pagination-previous/edit.js.map +1 -1
- package/build/query-title/edit.js +3 -3
- package/build/query-title/edit.js.map +1 -1
- package/build/query-title/index.js +5 -0
- package/build/query-title/index.js.map +1 -1
- package/build/quote/deprecated.js.map +1 -1
- package/build/quote/edit.js.map +1 -1
- package/build/quote/save.js.map +1 -1
- package/build/quote/transforms.js.map +1 -1
- package/build/search/edit.js.map +1 -1
- package/build/search/edit.native.js.map +1 -1
- package/build/shortcode/edit.js.map +1 -1
- package/build/site-logo/edit.js +5 -3
- package/build/site-logo/edit.js.map +1 -1
- package/build/site-tagline/edit.js.map +1 -1
- package/build/site-title/edit.js.map +1 -1
- package/build/social-link/edit.js.map +1 -1
- package/build/social-link/edit.native.js.map +1 -1
- package/build/social-links/deprecated.js.map +1 -1
- package/build/social-links/edit.js.map +1 -1
- package/build/spacer/controls.native.js.map +1 -1
- package/build/spacer/deprecated.js.map +1 -1
- package/build/spacer/edit.js.map +1 -1
- package/build/table/deprecated.js.map +1 -1
- package/build/table/edit.js.map +1 -1
- package/build/table/save.js.map +1 -1
- package/build/table-of-contents/edit.js +1 -1
- package/build/table-of-contents/edit.js.map +1 -1
- package/build/table-of-contents/hooks.js.map +1 -1
- package/build/table-of-contents/index.js +42 -1
- package/build/table-of-contents/index.js.map +1 -1
- package/build/tag-cloud/edit.js.map +1 -1
- package/build/template-part/edit/advanced-controls.js +1 -1
- package/build/template-part/edit/advanced-controls.js.map +1 -1
- package/build/template-part/edit/import-controls.js +2 -1
- package/build/template-part/edit/import-controls.js.map +1 -1
- package/build/template-part/edit/index.js +2 -2
- package/build/template-part/edit/index.js.map +1 -1
- package/build/template-part/edit/selection-modal.js +2 -2
- package/build/template-part/edit/selection-modal.js.map +1 -1
- package/build/template-part/edit/utils/hooks.js.map +1 -1
- package/build/template-part/variations.js.map +1 -1
- package/build/term-description/edit.js.map +1 -1
- package/build/term-description/index.js +2 -1
- package/build/term-description/index.js.map +1 -1
- package/build/text-columns/edit.js.map +1 -1
- package/build/text-columns/save.js.map +1 -1
- package/build/verse/deprecated.js.map +1 -1
- package/build/verse/edit.js.map +1 -1
- package/build/verse/save.js.map +1 -1
- package/build/video/edit.js +1 -1
- package/build/video/edit.js.map +1 -1
- package/build/video/edit.native.js +1 -1
- package/build/video/edit.native.js.map +1 -1
- package/build/video/tracks-editor.js +1 -1
- package/build/video/tracks-editor.js.map +1 -1
- package/build-module/archives/edit.js +1 -3
- package/build-module/archives/edit.js.map +1 -1
- package/build-module/audio/deprecated.js +1 -2
- package/build-module/audio/deprecated.js.map +1 -1
- package/build-module/audio/edit.js +1 -3
- package/build-module/audio/edit.js.map +1 -1
- package/build-module/audio/edit.native.js +2 -4
- package/build-module/audio/edit.native.js.map +1 -1
- package/build-module/audio/save.js +1 -2
- package/build-module/audio/save.js.map +1 -1
- package/build-module/avatar/edit.js +1 -3
- package/build-module/avatar/edit.js.map +1 -1
- package/build-module/avatar/index.js +2 -1
- package/build-module/avatar/index.js.map +1 -1
- package/build-module/block/edit-title.native.js +1 -2
- package/build-module/block/edit-title.native.js.map +1 -1
- package/build-module/block/edit.js +1 -3
- package/build-module/block/edit.js.map +1 -1
- package/build-module/block/edit.native.js +3 -4
- package/build-module/block/edit.native.js.map +1 -1
- package/build-module/block-keyboard-shortcuts/index.js.map +1 -1
- package/build-module/button/color-background.native.js +1 -2
- package/build-module/button/color-background.native.js.map +1 -1
- package/build-module/button/deprecated.js.map +1 -1
- package/build-module/button/edit.js +1 -3
- package/build-module/button/edit.js.map +1 -1
- package/build-module/button/edit.native.js +1 -3
- package/build-module/button/edit.native.js.map +1 -1
- package/build-module/button/get-updated-link-attributes.js.map +1 -1
- package/build-module/button/save.js.map +1 -1
- package/build-module/buttons/deprecated.js.map +1 -1
- package/build-module/buttons/edit.native.js +1 -3
- package/build-module/buttons/edit.native.js.map +1 -1
- package/build-module/categories/edit.js +2 -4
- package/build-module/categories/edit.js.map +1 -1
- package/build-module/column/deprecated.js.map +1 -1
- package/build-module/column/edit.js +2 -4
- package/build-module/column/edit.js.map +1 -1
- package/build-module/column/edit.native.js +1 -3
- package/build-module/column/edit.native.js.map +1 -1
- package/build-module/column/save.js.map +1 -1
- package/build-module/columns/deprecated.js.map +1 -1
- package/build-module/columns/edit.js +1 -3
- package/build-module/columns/edit.js.map +1 -1
- package/build-module/columns/edit.native.js +2 -4
- package/build-module/columns/edit.native.js.map +1 -1
- package/build-module/columns/save.js.map +1 -1
- package/build-module/columns/transforms.js.map +1 -1
- package/build-module/columns/utils.js.map +1 -1
- package/build-module/comment-author-avatar/edit.js +1 -3
- package/build-module/comment-author-avatar/edit.js.map +1 -1
- package/build-module/comment-author-name/edit.js +1 -3
- package/build-module/comment-author-name/edit.js.map +1 -1
- package/build-module/comment-author-name/index.js +2 -1
- package/build-module/comment-author-name/index.js.map +1 -1
- package/build-module/comment-content/edit.js +1 -3
- package/build-module/comment-content/edit.js.map +1 -1
- package/build-module/comment-content/index.js +2 -1
- package/build-module/comment-content/index.js.map +1 -1
- package/build-module/comment-date/edit.js +1 -3
- package/build-module/comment-date/edit.js.map +1 -1
- package/build-module/comment-date/index.js +2 -1
- package/build-module/comment-date/index.js.map +1 -1
- package/build-module/comment-edit-link/edit.js +1 -3
- package/build-module/comment-edit-link/edit.js.map +1 -1
- package/build-module/comment-edit-link/index.js +2 -1
- package/build-module/comment-edit-link/index.js.map +1 -1
- package/build-module/comment-reply-link/edit.js +1 -3
- package/build-module/comment-reply-link/edit.js.map +1 -1
- package/build-module/comment-reply-link/index.js +2 -1
- package/build-module/comment-reply-link/index.js.map +1 -1
- package/build-module/comment-template/edit.js +1 -2
- package/build-module/comment-template/edit.js.map +1 -1
- package/build-module/comment-template/hooks.js.map +1 -1
- package/build-module/comments/edit/comments-legacy.js +1 -3
- package/build-module/comments/edit/comments-legacy.js.map +1 -1
- package/build-module/comments/edit/index.js +1 -3
- package/build-module/comments/edit/index.js.map +1 -1
- package/build-module/comments/edit/placeholder.js +1 -2
- package/build-module/comments/edit/placeholder.js.map +1 -1
- package/build-module/comments-pagination/comments-pagination-arrow-controls.js +1 -2
- package/build-module/comments-pagination/comments-pagination-arrow-controls.js.map +1 -1
- package/build-module/comments-pagination/edit.js +1 -3
- package/build-module/comments-pagination/edit.js.map +1 -1
- package/build-module/comments-pagination-next/edit.js +1 -2
- package/build-module/comments-pagination-next/edit.js.map +1 -1
- package/build-module/comments-pagination-next/index.js +5 -0
- package/build-module/comments-pagination-next/index.js.map +1 -1
- package/build-module/comments-pagination-numbers/edit.js +1 -2
- package/build-module/comments-pagination-numbers/edit.js.map +1 -1
- package/build-module/comments-pagination-numbers/index.js +2 -1
- package/build-module/comments-pagination-numbers/index.js.map +1 -1
- package/build-module/comments-pagination-previous/edit.js +1 -2
- package/build-module/comments-pagination-previous/edit.js.map +1 -1
- package/build-module/comments-pagination-previous/index.js +5 -0
- package/build-module/comments-pagination-previous/index.js.map +1 -1
- package/build-module/comments-title/edit.js +3 -5
- package/build-module/comments-title/edit.js.map +1 -1
- package/build-module/comments-title/index.js +2 -1
- package/build-module/comments-title/index.js.map +1 -1
- package/build-module/cover/controls.native.js +1 -3
- package/build-module/cover/controls.native.js.map +1 -1
- package/build-module/cover/deprecated.js +1 -2
- package/build-module/cover/deprecated.js.map +1 -1
- package/build-module/cover/edit/block-controls.js +1 -3
- package/build-module/cover/edit/block-controls.js.map +1 -1
- package/build-module/cover/edit/index.js +1 -3
- package/build-module/cover/edit/index.js.map +1 -1
- package/build-module/cover/edit/inspector-controls.js +76 -34
- package/build-module/cover/edit/inspector-controls.js.map +1 -1
- package/build-module/cover/edit.native.js +1 -3
- package/build-module/cover/edit.native.js.map +1 -1
- package/build-module/cover/save.js +1 -2
- package/build-module/cover/save.js.map +1 -1
- package/build-module/cover/shared.js.map +1 -1
- package/build-module/details/edit.js +1 -3
- package/build-module/details/edit.js.map +1 -1
- package/build-module/details/save.js +1 -2
- package/build-module/details/save.js.map +1 -1
- package/build-module/embed/deprecated.js +1 -2
- package/build-module/embed/deprecated.js.map +1 -1
- package/build-module/embed/edit.js +17 -6
- package/build-module/embed/edit.js.map +1 -1
- package/build-module/embed/edit.native.js +1 -3
- package/build-module/embed/edit.native.js.map +1 -1
- package/build-module/embed/embed-controls.js +1 -3
- package/build-module/embed/embed-controls.js.map +1 -1
- package/build-module/embed/embed-controls.native.js +1 -3
- package/build-module/embed/embed-controls.native.js.map +1 -1
- package/build-module/embed/embed-no-preview.native.js +1 -3
- package/build-module/embed/embed-no-preview.native.js.map +1 -1
- package/build-module/embed/embed-placeholder.js +1 -2
- package/build-module/embed/embed-placeholder.js.map +1 -1
- package/build-module/embed/embed-placeholder.native.js +1 -3
- package/build-module/embed/embed-placeholder.native.js.map +1 -1
- package/build-module/embed/embed-preview.js +6 -21
- package/build-module/embed/embed-preview.js.map +1 -1
- package/build-module/embed/embed-preview.native.js +2 -4
- package/build-module/embed/embed-preview.native.js.map +1 -1
- package/build-module/embed/icons.js +1 -2
- package/build-module/embed/icons.js.map +1 -1
- package/build-module/embed/save.js +1 -2
- package/build-module/embed/save.js.map +1 -1
- package/build-module/embed/transforms.js.map +1 -1
- package/build-module/embed/variations.js +1 -1
- package/build-module/embed/variations.js.map +1 -1
- package/build-module/embed/wp-embed-preview.native.js.map +1 -1
- package/build-module/file/deprecated.js +4 -6
- package/build-module/file/deprecated.js.map +1 -1
- package/build-module/file/edit.js +1 -3
- package/build-module/file/edit.js.map +1 -1
- package/build-module/file/edit.native.js +1 -2
- package/build-module/file/edit.native.js.map +1 -1
- package/build-module/file/index.js +8 -4
- package/build-module/file/index.js.map +1 -1
- package/build-module/file/inspector.js +1 -3
- package/build-module/file/inspector.js.map +1 -1
- package/build-module/file/save.js +1 -3
- package/build-module/file/save.js.map +1 -1
- package/build-module/footnotes/edit.js +1 -2
- package/build-module/footnotes/edit.js.map +1 -1
- package/build-module/footnotes/format.js.map +1 -1
- package/build-module/form/edit.js +1 -3
- package/build-module/form/edit.js.map +1 -1
- package/build-module/form-input/deprecated.js +1 -2
- package/build-module/form-input/deprecated.js.map +1 -1
- package/build-module/form-input/edit.js +1 -3
- package/build-module/form-input/edit.js.map +1 -1
- package/build-module/form-input/save.js +1 -2
- package/build-module/form-input/save.js.map +1 -1
- package/build-module/form-submission-notification/edit.js.map +1 -1
- package/build-module/form-submission-notification/save.js.map +1 -1
- package/build-module/freeform/edit.js +1 -3
- package/build-module/freeform/edit.js.map +1 -1
- package/build-module/freeform/modal.js +1 -3
- package/build-module/freeform/modal.js.map +1 -1
- package/build-module/gallery/deprecated.js +1 -2
- package/build-module/gallery/deprecated.js.map +1 -1
- package/build-module/gallery/edit.js +3 -5
- package/build-module/gallery/edit.js.map +1 -1
- package/build-module/gallery/gallery.js +1 -2
- package/build-module/gallery/gallery.js.map +1 -1
- package/build-module/gallery/gallery.native.js +2 -3
- package/build-module/gallery/gallery.native.js.map +1 -1
- package/build-module/gallery/gap-styles.js.map +1 -1
- package/build-module/gallery/save.js +1 -2
- package/build-module/gallery/save.js.map +1 -1
- package/build-module/group/edit.js +1 -3
- package/build-module/group/edit.js.map +1 -1
- package/build-module/group/edit.native.js +1 -2
- package/build-module/group/edit.native.js.map +1 -1
- package/build-module/group/placeholder.js.map +1 -1
- package/build-module/heading/deprecated.js.map +1 -1
- package/build-module/heading/edit.js +1 -3
- package/build-module/heading/edit.js.map +1 -1
- package/build-module/heading/edit.native.js +1 -3
- package/build-module/heading/edit.native.js.map +1 -1
- package/build-module/heading/index.js +2 -2
- package/build-module/heading/index.js.map +1 -1
- package/build-module/heading/save.js.map +1 -1
- package/build-module/heading/transforms.js.map +1 -1
- package/build-module/home-link/edit.js +1 -2
- package/build-module/home-link/edit.js.map +1 -1
- package/build-module/html/edit.js +1 -3
- package/build-module/html/edit.js.map +1 -1
- package/build-module/html/preview.js +1 -3
- package/build-module/html/preview.js.map +1 -1
- package/build-module/image/deprecated.js +1 -3
- package/build-module/image/deprecated.js.map +1 -1
- package/build-module/image/edit.js +2 -4
- package/build-module/image/edit.js.map +1 -1
- package/build-module/image/edit.native.js +2 -4
- package/build-module/image/edit.native.js.map +1 -1
- package/build-module/image/image.js +4 -6
- package/build-module/image/image.js.map +1 -1
- package/build-module/image/save.js +1 -3
- package/build-module/image/save.js.map +1 -1
- package/build-module/image/view.js.map +1 -1
- package/build-module/index.native.js.map +1 -1
- package/build-module/latest-comments/edit.js +1 -2
- package/build-module/latest-comments/edit.js.map +1 -1
- package/build-module/latest-posts/edit.js +3 -5
- package/build-module/latest-posts/edit.js.map +1 -1
- package/build-module/latest-posts/edit.native.js +1 -3
- package/build-module/latest-posts/edit.native.js.map +1 -1
- package/build-module/list/edit.js +1 -3
- package/build-module/list/edit.js.map +1 -1
- package/build-module/list/ordered-list-settings.js +1 -2
- package/build-module/list/ordered-list-settings.js.map +1 -1
- package/build-module/list-item/edit.js +1 -3
- package/build-module/list-item/edit.js.map +1 -1
- package/build-module/list-item/edit.native.js +1 -2
- package/build-module/list-item/edit.native.js.map +1 -1
- package/build-module/list-item/list-style-type.native.js +1 -2
- package/build-module/list-item/list-style-type.native.js.map +1 -1
- package/build-module/list-item/save.js +1 -2
- package/build-module/list-item/save.js.map +1 -1
- package/build-module/loginout/edit.js +1 -3
- package/build-module/loginout/edit.js.map +1 -1
- package/build-module/media-text/deprecated.js +1 -2
- package/build-module/media-text/deprecated.js.map +1 -1
- package/build-module/media-text/edit.js +1 -3
- package/build-module/media-text/edit.js.map +1 -1
- package/build-module/media-text/edit.native.js +1 -3
- package/build-module/media-text/edit.native.js.map +1 -1
- package/build-module/media-text/icon-retry.native.js +1 -2
- package/build-module/media-text/icon-retry.native.js.map +1 -1
- package/build-module/media-text/image-fill.js.map +1 -1
- package/build-module/media-text/media-container.js +1 -2
- package/build-module/media-text/media-container.js.map +1 -1
- package/build-module/media-text/media-container.native.js +1 -3
- package/build-module/media-text/media-container.native.js.map +1 -1
- package/build-module/media-text/save.js +1 -2
- package/build-module/media-text/save.js.map +1 -1
- package/build-module/missing/edit.js +3 -4
- package/build-module/missing/edit.js.map +1 -1
- package/build-module/missing/edit.native.js +1 -2
- package/build-module/missing/edit.native.js.map +1 -1
- package/build-module/more/edit.js +1 -3
- package/build-module/more/edit.js.map +1 -1
- package/build-module/more/save.js.map +1 -1
- package/build-module/navigation/edit/accessible-menu-description.js.map +1 -1
- package/build-module/navigation/edit/index.js +1 -3
- package/build-module/navigation/edit/index.js.map +1 -1
- package/build-module/navigation/edit/leaf-more-menu.js +2 -4
- package/build-module/navigation/edit/leaf-more-menu.js.map +1 -1
- package/build-module/navigation/edit/menu-inspector-controls.js +2 -3
- package/build-module/navigation/edit/menu-inspector-controls.js.map +1 -1
- package/build-module/navigation/edit/navigation-menu-delete-control.js +1 -3
- package/build-module/navigation/edit/navigation-menu-delete-control.js.map +1 -1
- package/build-module/navigation/edit/navigation-menu-selector.js +1 -3
- package/build-module/navigation/edit/navigation-menu-selector.js.map +1 -1
- package/build-module/navigation/edit/overlay-menu-icon.js +1 -2
- package/build-module/navigation/edit/overlay-menu-icon.js.map +1 -1
- package/build-module/navigation/edit/overlay-menu-preview.js +1 -3
- package/build-module/navigation/edit/overlay-menu-preview.js.map +1 -1
- package/build-module/navigation/edit/placeholder/index.js +1 -3
- package/build-module/navigation/edit/placeholder/index.js.map +1 -1
- package/build-module/navigation/edit/placeholder/placeholder-preview.js +1 -2
- package/build-module/navigation/edit/placeholder/placeholder-preview.js.map +1 -1
- package/build-module/navigation/edit/responsive-wrapper.js +1 -3
- package/build-module/navigation/edit/responsive-wrapper.js.map +1 -1
- package/build-module/navigation/edit/use-convert-classic-menu-to-block-menu.js.map +1 -1
- package/build-module/navigation/edit/use-create-navigation-menu.js.map +1 -1
- package/build-module/navigation/edit/use-generate-default-navigation-title.js.map +1 -1
- package/build-module/navigation/edit/utils.js.map +1 -1
- package/build-module/navigation/use-navigation-menu.js.map +1 -1
- package/build-module/navigation-link/edit.js +1 -3
- package/build-module/navigation-link/edit.js.map +1 -1
- package/build-module/navigation-link/link-ui.js +1 -2
- package/build-module/navigation-link/link-ui.js.map +1 -1
- package/build-module/navigation-submenu/edit.js +1 -3
- package/build-module/navigation-submenu/edit.js.map +1 -1
- package/build-module/nextpage/edit.native.js +1 -1
- package/build-module/nextpage/edit.native.js.map +1 -1
- package/build-module/page-list/convert-to-links-modal.js +1 -2
- package/build-module/page-list/convert-to-links-modal.js.map +1 -1
- package/build-module/page-list/edit.js +1 -3
- package/build-module/page-list/edit.js.map +1 -1
- package/build-module/page-list-item/edit.js +2 -4
- package/build-module/page-list-item/edit.js.map +1 -1
- package/build-module/paragraph/deprecated.js.map +1 -1
- package/build-module/paragraph/edit.js +1 -3
- package/build-module/paragraph/edit.js.map +1 -1
- package/build-module/paragraph/edit.native.js +1 -3
- package/build-module/paragraph/edit.native.js.map +1 -1
- package/build-module/paragraph/save.js.map +1 -1
- package/build-module/pattern/recursion-detector.js +1 -0
- package/build-module/pattern/recursion-detector.js.map +1 -1
- package/build-module/post-author/edit.js +1 -3
- package/build-module/post-author/edit.js.map +1 -1
- package/build-module/post-author-biography/edit.js +1 -3
- package/build-module/post-author-biography/edit.js.map +1 -1
- package/build-module/post-author-name/edit.js +1 -3
- package/build-module/post-author-name/edit.js.map +1 -1
- package/build-module/post-comment/edit.js +1 -2
- package/build-module/post-comment/edit.js.map +1 -1
- package/build-module/post-comments-count/edit.js +1 -3
- package/build-module/post-comments-count/edit.js.map +1 -1
- package/build-module/post-comments-form/edit.js +1 -3
- package/build-module/post-comments-form/edit.js.map +1 -1
- package/build-module/post-comments-form/form.js +2 -3
- package/build-module/post-comments-form/form.js.map +1 -1
- package/build-module/post-comments-link/edit.js +2 -4
- package/build-module/post-comments-link/edit.js.map +1 -1
- package/build-module/post-content/edit.js +1 -2
- package/build-module/post-content/edit.js.map +1 -1
- package/build-module/post-date/edit.js +1 -3
- package/build-module/post-date/edit.js.map +1 -1
- package/build-module/post-excerpt/edit.js +1 -3
- package/build-module/post-excerpt/edit.js.map +1 -1
- package/build-module/post-featured-image/dimension-controls.js +1 -3
- package/build-module/post-featured-image/dimension-controls.js.map +1 -1
- package/build-module/post-featured-image/edit.js +1 -3
- package/build-module/post-featured-image/edit.js.map +1 -1
- package/build-module/post-featured-image/overlay-controls.js +1 -3
- package/build-module/post-featured-image/overlay-controls.js.map +1 -1
- package/build-module/post-navigation-link/edit.js +1 -3
- package/build-module/post-navigation-link/edit.js.map +1 -1
- package/build-module/post-navigation-link/index.js +6 -0
- package/build-module/post-navigation-link/index.js.map +1 -1
- package/build-module/post-navigation-link/variations.js +14 -2
- package/build-module/post-navigation-link/variations.js.map +1 -1
- package/build-module/post-template/edit.js +1 -3
- package/build-module/post-template/edit.js.map +1 -1
- package/build-module/post-terms/edit.js +1 -3
- package/build-module/post-terms/edit.js.map +1 -1
- package/build-module/post-time-to-read/edit.js +2 -4
- package/build-module/post-time-to-read/edit.js.map +1 -1
- package/build-module/post-time-to-read/index.js +2 -1
- package/build-module/post-time-to-read/index.js.map +1 -1
- package/build-module/post-title/edit.js +1 -3
- package/build-module/post-title/edit.js.map +1 -1
- package/build-module/pullquote/deprecated.js +1 -2
- package/build-module/pullquote/deprecated.js.map +1 -1
- package/build-module/pullquote/edit.js +1 -3
- package/build-module/pullquote/edit.js.map +1 -1
- package/build-module/pullquote/edit.native.js +1 -3
- package/build-module/pullquote/edit.native.js.map +1 -1
- package/build-module/pullquote/save.js +1 -2
- package/build-module/pullquote/save.js.map +1 -1
- package/build-module/pullquote/shared.js.map +1 -1
- package/build-module/query/edit/enhanced-pagination-modal.js +1 -2
- package/build-module/query/edit/enhanced-pagination-modal.js.map +1 -1
- package/build-module/query/edit/index.js +1 -3
- package/build-module/query/edit/index.js.map +1 -1
- package/build-module/query/edit/inspector-controls/author-control.js +1 -0
- package/build-module/query/edit/inspector-controls/author-control.js.map +1 -1
- package/build-module/query/edit/inspector-controls/enhanced-pagination-control.js +1 -2
- package/build-module/query/edit/inspector-controls/enhanced-pagination-control.js.map +1 -1
- package/build-module/query/edit/inspector-controls/index.js +8 -13
- package/build-module/query/edit/inspector-controls/index.js.map +1 -1
- package/build-module/query/edit/inspector-controls/order-control.js.map +1 -1
- package/build-module/query/edit/inspector-controls/pages-control.js +1 -1
- package/build-module/query/edit/inspector-controls/pages-control.js.map +1 -1
- package/build-module/query/edit/inspector-controls/parent-control.js +1 -0
- package/build-module/query/edit/inspector-controls/parent-control.js.map +1 -1
- package/build-module/query/edit/inspector-controls/per-page-control.js +1 -1
- package/build-module/query/edit/inspector-controls/per-page-control.js.map +1 -1
- package/build-module/query/edit/inspector-controls/taxonomy-controls.js +1 -0
- package/build-module/query/edit/inspector-controls/taxonomy-controls.js.map +1 -1
- package/build-module/query/edit/pattern-selection-modal.js +2 -3
- package/build-module/query/edit/pattern-selection-modal.js.map +1 -1
- package/build-module/query/edit/query-content.js +1 -3
- package/build-module/query/edit/query-content.js.map +1 -1
- package/build-module/query/edit/query-placeholder.js +1 -2
- package/build-module/query/edit/query-placeholder.js.map +1 -1
- package/build-module/query/edit/query-toolbar.js +1 -2
- package/build-module/query/edit/query-toolbar.js.map +1 -1
- package/build-module/query/index.js +1 -0
- package/build-module/query/index.js.map +1 -1
- package/build-module/query/utils.js.map +1 -1
- package/build-module/query/view.js.map +1 -1
- package/build-module/query-no-results/index.js +8 -0
- package/build-module/query-no-results/index.js.map +1 -1
- package/build-module/query-pagination/edit.js +1 -3
- package/build-module/query-pagination/edit.js.map +1 -1
- package/build-module/query-pagination/query-pagination-arrow-controls.js +1 -2
- package/build-module/query-pagination/query-pagination-arrow-controls.js.map +1 -1
- package/build-module/query-pagination-next/edit.js +1 -2
- package/build-module/query-pagination-next/edit.js.map +1 -1
- package/build-module/query-pagination-numbers/edit.js +1 -3
- package/build-module/query-pagination-numbers/edit.js.map +1 -1
- package/build-module/query-pagination-numbers/index.js +2 -1
- package/build-module/query-pagination-numbers/index.js.map +1 -1
- package/build-module/query-pagination-previous/edit.js +1 -2
- package/build-module/query-pagination-previous/edit.js.map +1 -1
- package/build-module/query-title/edit.js +4 -6
- package/build-module/query-title/edit.js.map +1 -1
- package/build-module/query-title/index.js +5 -0
- package/build-module/query-title/index.js.map +1 -1
- package/build-module/quote/deprecated.js +1 -2
- package/build-module/quote/deprecated.js.map +1 -1
- package/build-module/quote/edit.js +1 -3
- package/build-module/quote/edit.js.map +1 -1
- package/build-module/quote/save.js +1 -2
- package/build-module/quote/save.js.map +1 -1
- package/build-module/quote/transforms.js.map +1 -1
- package/build-module/read-more/edit.js +1 -3
- package/build-module/read-more/edit.js.map +1 -1
- package/build-module/rss/edit.js +1 -3
- package/build-module/rss/edit.js.map +1 -1
- package/build-module/search/edit.js +1 -3
- package/build-module/search/edit.js.map +1 -1
- package/build-module/search/edit.native.js +1 -2
- package/build-module/search/edit.native.js.map +1 -1
- package/build-module/search/icons.js +1 -2
- package/build-module/search/icons.js.map +1 -1
- package/build-module/separator/edit.js +1 -2
- package/build-module/separator/edit.js.map +1 -1
- package/build-module/shortcode/edit.js.map +1 -1
- package/build-module/shortcode/edit.native.js +1 -2
- package/build-module/shortcode/edit.native.js.map +1 -1
- package/build-module/site-logo/edit.js +6 -6
- package/build-module/site-logo/edit.js.map +1 -1
- package/build-module/site-tagline/edit.js +1 -3
- package/build-module/site-tagline/edit.js.map +1 -1
- package/build-module/site-title/edit.js +1 -3
- package/build-module/site-title/edit.js.map +1 -1
- package/build-module/social-link/edit.js +1 -3
- package/build-module/social-link/edit.js.map +1 -1
- package/build-module/social-link/edit.native.js +1 -3
- package/build-module/social-link/edit.native.js.map +1 -1
- package/build-module/social-links/deprecated.js.map +1 -1
- package/build-module/social-links/edit.js +1 -3
- package/build-module/social-links/edit.js.map +1 -1
- package/build-module/spacer/controls.js +1 -3
- package/build-module/spacer/controls.js.map +1 -1
- package/build-module/spacer/controls.native.js +1 -2
- package/build-module/spacer/controls.native.js.map +1 -1
- package/build-module/spacer/deprecated.js.map +1 -1
- package/build-module/spacer/edit.js +1 -3
- package/build-module/spacer/edit.js.map +1 -1
- package/build-module/table/deprecated.js +1 -2
- package/build-module/table/deprecated.js.map +1 -1
- package/build-module/table/edit.js +1 -3
- package/build-module/table/edit.js.map +1 -1
- package/build-module/table/save.js +1 -2
- package/build-module/table/save.js.map +1 -1
- package/build-module/table-of-contents/edit.js +2 -4
- package/build-module/table-of-contents/edit.js.map +1 -1
- package/build-module/table-of-contents/hooks.js.map +1 -1
- package/build-module/table-of-contents/index.js +42 -1
- package/build-module/table-of-contents/index.js.map +1 -1
- package/build-module/table-of-contents/list.js +1 -3
- package/build-module/table-of-contents/list.js.map +1 -1
- package/build-module/tag-cloud/edit.js +1 -3
- package/build-module/tag-cloud/edit.js.map +1 -1
- package/build-module/template-part/edit/advanced-controls.js +2 -4
- package/build-module/template-part/edit/advanced-controls.js.map +1 -1
- package/build-module/template-part/edit/import-controls.js +3 -3
- package/build-module/template-part/edit/import-controls.js.map +1 -1
- package/build-module/template-part/edit/index.js +3 -5
- package/build-module/template-part/edit/index.js.map +1 -1
- package/build-module/template-part/edit/placeholder.js +1 -2
- package/build-module/template-part/edit/placeholder.js.map +1 -1
- package/build-module/template-part/edit/selection-modal.js +3 -4
- package/build-module/template-part/edit/selection-modal.js.map +1 -1
- package/build-module/template-part/edit/title-modal.js +1 -2
- package/build-module/template-part/edit/title-modal.js.map +1 -1
- package/build-module/template-part/edit/utils/hooks.js.map +1 -1
- package/build-module/template-part/variations.js.map +1 -1
- package/build-module/term-description/edit.js +1 -3
- package/build-module/term-description/edit.js.map +1 -1
- package/build-module/term-description/index.js +2 -1
- package/build-module/term-description/index.js.map +1 -1
- package/build-module/text-columns/edit.js +1 -3
- package/build-module/text-columns/edit.js.map +1 -1
- package/build-module/text-columns/save.js.map +1 -1
- package/build-module/utils/caption.js +1 -3
- package/build-module/utils/caption.js.map +1 -1
- package/build-module/verse/deprecated.js.map +1 -1
- package/build-module/verse/edit.js +1 -3
- package/build-module/verse/edit.js.map +1 -1
- package/build-module/verse/save.js.map +1 -1
- package/build-module/video/deprecated.js +1 -2
- package/build-module/video/deprecated.js.map +1 -1
- package/build-module/video/edit-common-settings.js +1 -3
- package/build-module/video/edit-common-settings.js.map +1 -1
- package/build-module/video/edit.js +2 -4
- package/build-module/video/edit.js.map +1 -1
- package/build-module/video/edit.native.js +2 -3
- package/build-module/video/edit.native.js.map +1 -1
- package/build-module/video/icon-retry.native.js +1 -2
- package/build-module/video/icon-retry.native.js.map +1 -1
- package/build-module/video/save.js +1 -2
- package/build-module/video/save.js.map +1 -1
- package/build-module/video/tracks-editor.js +2 -4
- package/build-module/video/tracks-editor.js.map +1 -1
- package/build-style/archives/editor-rtl.css +10 -1
- package/build-style/archives/editor.css +10 -1
- package/build-style/archives/style-rtl.css +10 -1
- package/build-style/archives/style.css +10 -1
- package/build-style/audio/editor-rtl.css +10 -1
- package/build-style/audio/editor.css +10 -1
- package/build-style/audio/style-rtl.css +10 -1
- package/build-style/audio/style.css +10 -1
- package/build-style/audio/theme-rtl.css +10 -1
- package/build-style/audio/theme.css +10 -1
- package/build-style/avatar/editor-rtl.css +10 -1
- package/build-style/avatar/editor.css +10 -1
- package/build-style/avatar/style-rtl.css +10 -1
- package/build-style/avatar/style.css +10 -1
- package/build-style/button/editor-rtl.css +10 -1
- package/build-style/button/editor.css +10 -1
- package/build-style/button/style-rtl.css +10 -1
- package/build-style/button/style.css +10 -1
- package/build-style/buttons/editor-rtl.css +10 -1
- package/build-style/buttons/editor.css +10 -1
- package/build-style/buttons/style-rtl.css +11 -1
- package/build-style/buttons/style.css +11 -1
- package/build-style/calendar/style-rtl.css +10 -1
- package/build-style/calendar/style.css +10 -1
- package/build-style/categories/editor-rtl.css +10 -1
- package/build-style/categories/editor.css +10 -1
- package/build-style/categories/style-rtl.css +10 -1
- package/build-style/categories/style.css +10 -1
- package/build-style/classic-rtl.css +10 -1
- package/build-style/classic.css +10 -1
- package/build-style/code/editor-rtl.css +10 -1
- package/build-style/code/editor.css +10 -1
- package/build-style/code/style-rtl.css +12 -1
- package/build-style/code/style.css +14 -1
- package/build-style/code/theme-rtl.css +10 -1
- package/build-style/code/theme.css +10 -1
- package/build-style/columns/editor-rtl.css +10 -1
- package/build-style/columns/editor.css +10 -1
- package/build-style/columns/style-rtl.css +10 -1
- package/build-style/columns/style.css +10 -1
- package/build-style/comment-author-avatar/editor-rtl.css +10 -1
- package/build-style/comment-author-avatar/editor.css +10 -1
- package/build-style/comment-author-name/style-rtl.css +10 -1
- package/build-style/comment-author-name/style.css +10 -1
- package/build-style/comment-content/style-rtl.css +10 -1
- package/build-style/comment-content/style.css +10 -1
- package/build-style/comment-date/style-rtl.css +10 -1
- package/build-style/comment-date/style.css +10 -1
- package/build-style/comment-edit-link/style-rtl.css +10 -1
- package/build-style/comment-edit-link/style.css +10 -1
- package/build-style/comment-reply-link/style-rtl.css +10 -1
- package/build-style/comment-reply-link/style.css +10 -1
- package/build-style/comment-template/style-rtl.css +10 -1
- package/build-style/comment-template/style.css +10 -1
- package/build-style/comments/editor-rtl.css +10 -1
- package/build-style/comments/editor.css +10 -1
- package/build-style/comments/style-rtl.css +10 -1
- package/build-style/comments/style.css +10 -1
- package/build-style/comments-pagination/editor-rtl.css +10 -1
- package/build-style/comments-pagination/editor.css +10 -1
- package/build-style/comments-pagination/style-rtl.css +10 -1
- package/build-style/comments-pagination/style.css +10 -1
- package/build-style/comments-pagination-numbers/editor-rtl.css +10 -1
- package/build-style/comments-pagination-numbers/editor.css +10 -1
- package/build-style/comments-title/editor-rtl.css +10 -1
- package/build-style/comments-title/editor.css +10 -1
- package/build-style/common-rtl.css +10 -3
- package/build-style/common.css +10 -3
- package/build-style/cover/editor-rtl.css +11 -1
- package/build-style/cover/editor.css +11 -1
- package/build-style/cover/style-rtl.css +14 -5
- package/build-style/cover/style.css +14 -5
- package/build-style/details/editor-rtl.css +10 -1
- package/build-style/details/editor.css +10 -1
- package/build-style/details/style-rtl.css +10 -1
- package/build-style/details/style.css +10 -1
- package/build-style/editor-elements-rtl.css +10 -1
- package/build-style/editor-elements.css +10 -1
- package/build-style/editor-rtl.css +15 -17
- package/build-style/editor.css +15 -17
- package/build-style/elements-rtl.css +10 -1
- package/build-style/elements.css +10 -1
- package/build-style/embed/editor-rtl.css +10 -1
- package/build-style/embed/editor.css +10 -1
- package/build-style/embed/style-rtl.css +10 -1
- package/build-style/embed/style.css +10 -1
- package/build-style/embed/theme-rtl.css +10 -1
- package/build-style/embed/theme.css +10 -1
- package/build-style/file/editor-rtl.css +10 -1
- package/build-style/file/editor.css +10 -1
- package/build-style/file/style-rtl.css +10 -1
- package/build-style/file/style.css +10 -1
- package/build-style/footnotes/style-rtl.css +10 -1
- package/build-style/footnotes/style.css +10 -1
- package/build-style/form-input/editor-rtl.css +10 -1
- package/build-style/form-input/editor.css +10 -1
- package/build-style/form-input/style-rtl.css +10 -1
- package/build-style/form-input/style.css +10 -1
- package/build-style/form-submission-notification/editor-rtl.css +10 -1
- package/build-style/form-submission-notification/editor.css +10 -1
- package/build-style/form-submit-button/style-rtl.css +10 -1
- package/build-style/form-submit-button/style.css +10 -1
- package/build-style/freeform/editor-rtl.css +10 -1
- package/build-style/freeform/editor.css +10 -1
- package/build-style/gallery/editor-rtl.css +10 -1
- package/build-style/gallery/editor.css +10 -1
- package/build-style/gallery/style-rtl.css +10 -1
- package/build-style/gallery/style.css +10 -1
- package/build-style/gallery/theme-rtl.css +10 -1
- package/build-style/gallery/theme.css +10 -1
- package/build-style/group/editor-rtl.css +10 -1
- package/build-style/group/editor.css +10 -1
- package/build-style/group/style-rtl.css +10 -1
- package/build-style/group/style.css +10 -1
- package/build-style/group/theme-rtl.css +10 -1
- package/build-style/group/theme.css +10 -1
- package/build-style/heading/style-rtl.css +10 -1
- package/build-style/heading/style.css +10 -1
- package/build-style/html/editor-rtl.css +10 -1
- package/build-style/html/editor.css +10 -1
- package/build-style/image/editor-rtl.css +10 -1
- package/build-style/image/editor.css +10 -1
- package/build-style/image/style-rtl.css +10 -1
- package/build-style/image/style.css +10 -1
- package/build-style/image/theme-rtl.css +10 -1
- package/build-style/image/theme.css +10 -1
- package/build-style/latest-comments/style-rtl.css +10 -1
- package/build-style/latest-comments/style.css +10 -1
- package/build-style/latest-posts/editor-rtl.css +10 -1
- package/build-style/latest-posts/editor.css +10 -1
- package/build-style/latest-posts/style-rtl.css +10 -1
- package/build-style/latest-posts/style.css +10 -1
- package/build-style/list/style-rtl.css +10 -1
- package/build-style/list/style.css +10 -1
- package/build-style/loginout/style-rtl.css +10 -1
- package/build-style/loginout/style.css +10 -1
- package/build-style/media-text/editor-rtl.css +10 -1
- package/build-style/media-text/editor.css +10 -1
- package/build-style/media-text/style-rtl.css +10 -1
- package/build-style/media-text/style.css +10 -1
- package/build-style/more/editor-rtl.css +10 -1
- package/build-style/more/editor.css +10 -1
- package/build-style/navigation/editor-rtl.css +10 -1
- package/build-style/navigation/editor.css +10 -1
- package/build-style/navigation/style-rtl.css +10 -1
- package/build-style/navigation/style.css +10 -1
- package/build-style/navigation-link/editor-rtl.css +10 -1
- package/build-style/navigation-link/editor.css +10 -1
- package/build-style/navigation-link/style-rtl.css +10 -1
- package/build-style/navigation-link/style.css +10 -1
- package/build-style/navigation-submenu/editor-rtl.css +10 -1
- package/build-style/navigation-submenu/editor.css +10 -1
- package/build-style/nextpage/editor-rtl.css +10 -1
- package/build-style/nextpage/editor.css +10 -1
- package/build-style/page-list/editor-rtl.css +10 -1
- package/build-style/page-list/editor.css +10 -1
- package/build-style/page-list/style-rtl.css +10 -1
- package/build-style/page-list/style.css +10 -1
- package/build-style/paragraph/editor-rtl.css +10 -1
- package/build-style/paragraph/editor.css +10 -1
- package/build-style/paragraph/style-rtl.css +10 -1
- package/build-style/paragraph/style.css +10 -1
- package/build-style/post-author/editor-rtl.css +10 -1
- package/build-style/post-author/editor.css +10 -1
- package/build-style/post-author/style-rtl.css +10 -1
- package/build-style/post-author/style.css +10 -1
- package/build-style/post-author-biography/style-rtl.css +10 -1
- package/build-style/post-author-biography/style.css +10 -1
- package/build-style/post-author-name/style-rtl.css +10 -1
- package/build-style/post-author-name/style.css +10 -1
- package/build-style/post-comments-form/editor-rtl.css +10 -1
- package/build-style/post-comments-form/editor.css +10 -1
- package/build-style/post-comments-form/style-rtl.css +10 -1
- package/build-style/post-comments-form/style.css +10 -1
- package/build-style/post-content/style-rtl.css +10 -1
- package/build-style/post-content/style.css +10 -1
- package/build-style/post-date/style-rtl.css +10 -1
- package/build-style/post-date/style.css +10 -1
- package/build-style/post-excerpt/editor-rtl.css +10 -1
- package/build-style/post-excerpt/editor.css +10 -1
- package/build-style/post-excerpt/style-rtl.css +10 -1
- package/build-style/post-excerpt/style.css +10 -1
- package/build-style/post-featured-image/editor-rtl.css +10 -1
- package/build-style/post-featured-image/editor.css +10 -1
- package/build-style/post-featured-image/style-rtl.css +10 -1
- package/build-style/post-featured-image/style.css +10 -1
- package/build-style/post-navigation-link/style-rtl.css +10 -1
- package/build-style/post-navigation-link/style.css +10 -1
- package/build-style/post-template/editor-rtl.css +10 -1
- package/build-style/post-template/editor.css +10 -1
- package/build-style/post-template/style-rtl.css +10 -1
- package/build-style/post-template/style.css +10 -1
- package/build-style/post-terms/style-rtl.css +10 -1
- package/build-style/post-terms/style.css +10 -1
- package/build-style/post-time-to-read/style-rtl.css +10 -1
- package/build-style/post-time-to-read/style.css +10 -1
- package/build-style/post-title/style-rtl.css +10 -1
- package/build-style/post-title/style.css +10 -1
- package/build-style/preformatted/style-rtl.css +10 -1
- package/build-style/preformatted/style.css +10 -1
- package/build-style/pullquote/editor-rtl.css +10 -1
- package/build-style/pullquote/editor.css +10 -1
- package/build-style/pullquote/style-rtl.css +10 -1
- package/build-style/pullquote/style.css +10 -1
- package/build-style/pullquote/theme-rtl.css +10 -1
- package/build-style/pullquote/theme.css +10 -1
- package/build-style/query/editor-rtl.css +10 -1
- package/build-style/query/editor.css +10 -1
- package/build-style/query-pagination/editor-rtl.css +10 -1
- package/build-style/query-pagination/editor.css +10 -1
- package/build-style/query-pagination/style-rtl.css +10 -1
- package/build-style/query-pagination/style.css +10 -1
- package/build-style/query-pagination-numbers/editor-rtl.css +10 -1
- package/build-style/query-pagination-numbers/editor.css +10 -1
- package/build-style/query-title/style-rtl.css +10 -1
- package/build-style/query-title/style.css +10 -1
- package/build-style/quote/style-rtl.css +10 -1
- package/build-style/quote/style.css +10 -1
- package/build-style/quote/theme-rtl.css +10 -1
- package/build-style/quote/theme.css +10 -1
- package/build-style/read-more/style-rtl.css +10 -1
- package/build-style/read-more/style.css +10 -1
- package/build-style/reset-rtl.css +10 -1
- package/build-style/reset.css +10 -1
- package/build-style/rss/editor-rtl.css +10 -1
- package/build-style/rss/editor.css +10 -1
- package/build-style/rss/style-rtl.css +10 -1
- package/build-style/rss/style.css +10 -1
- package/build-style/search/editor-rtl.css +10 -1
- package/build-style/search/editor.css +10 -1
- package/build-style/search/style-rtl.css +10 -1
- package/build-style/search/style.css +10 -1
- package/build-style/search/theme-rtl.css +10 -1
- package/build-style/search/theme.css +10 -1
- package/build-style/separator/editor-rtl.css +10 -1
- package/build-style/separator/editor.css +10 -1
- package/build-style/separator/style-rtl.css +10 -1
- package/build-style/separator/style.css +10 -1
- package/build-style/separator/theme-rtl.css +10 -1
- package/build-style/separator/theme.css +10 -1
- package/build-style/shortcode/editor-rtl.css +10 -1
- package/build-style/shortcode/editor.css +10 -1
- package/build-style/site-logo/editor-rtl.css +10 -1
- package/build-style/site-logo/editor.css +10 -1
- package/build-style/site-logo/style-rtl.css +10 -1
- package/build-style/site-logo/style.css +10 -1
- package/build-style/site-tagline/editor-rtl.css +10 -1
- package/build-style/site-tagline/editor.css +10 -1
- package/build-style/site-tagline/style-rtl.css +10 -1
- package/build-style/site-tagline/style.css +10 -1
- package/build-style/site-title/editor-rtl.css +10 -1
- package/build-style/site-title/editor.css +10 -1
- package/build-style/site-title/style-rtl.css +10 -1
- package/build-style/site-title/style.css +10 -1
- package/build-style/social-link/editor-rtl.css +10 -1
- package/build-style/social-link/editor.css +10 -1
- package/build-style/social-links/editor-rtl.css +14 -12
- package/build-style/social-links/editor.css +14 -12
- package/build-style/social-links/style-rtl.css +10 -1
- package/build-style/social-links/style.css +10 -1
- package/build-style/spacer/editor-rtl.css +10 -1
- package/build-style/spacer/editor.css +10 -1
- package/build-style/spacer/style-rtl.css +10 -1
- package/build-style/spacer/style.css +10 -1
- package/build-style/style-rtl.css +17 -7
- package/build-style/style.css +19 -7
- package/build-style/table/editor-rtl.css +10 -1
- package/build-style/table/editor.css +10 -1
- package/build-style/table/style-rtl.css +10 -1
- package/build-style/table/style.css +10 -1
- package/build-style/table/theme-rtl.css +10 -1
- package/build-style/table/theme.css +10 -1
- package/build-style/table-of-contents/style-rtl.css +10 -1
- package/build-style/table-of-contents/style.css +10 -1
- package/build-style/tag-cloud/editor-rtl.css +10 -1
- package/build-style/tag-cloud/editor.css +10 -1
- package/build-style/tag-cloud/style-rtl.css +10 -1
- package/build-style/tag-cloud/style.css +10 -1
- package/build-style/template-part/editor-rtl.css +10 -1
- package/build-style/template-part/editor.css +10 -1
- package/build-style/template-part/theme-rtl.css +10 -1
- package/build-style/template-part/theme.css +10 -1
- package/build-style/term-description/style-rtl.css +10 -1
- package/build-style/term-description/style.css +10 -1
- package/build-style/text-columns/editor-rtl.css +10 -1
- package/build-style/text-columns/editor.css +10 -1
- package/build-style/text-columns/style-rtl.css +10 -1
- package/build-style/text-columns/style.css +10 -1
- package/build-style/theme-rtl.css +10 -1
- package/build-style/theme.css +10 -1
- package/build-style/verse/style-rtl.css +10 -1
- package/build-style/verse/style.css +10 -1
- package/build-style/video/editor-rtl.css +10 -1
- package/build-style/video/editor.css +10 -1
- package/build-style/video/style-rtl.css +10 -1
- package/build-style/video/style.css +10 -1
- package/build-style/video/theme-rtl.css +10 -1
- package/build-style/video/theme.css +10 -1
- package/package.json +36 -36
- package/src/avatar/index.js +1 -0
- package/src/buttons/style.scss +2 -0
- package/src/code/style.scss +5 -0
- package/src/comment-author-name/index.js +1 -0
- package/src/comment-content/index.js +1 -0
- package/src/comment-date/index.js +1 -0
- package/src/comment-edit-link/index.js +1 -0
- package/src/comment-reply-link/index.js +1 -0
- package/src/comments-pagination-next/block.json +5 -0
- package/src/comments-pagination-numbers/index.js +1 -0
- package/src/comments-pagination-previous/block.json +5 -0
- package/src/comments-title/index.js +1 -0
- package/src/common.scss +0 -3
- package/src/cover/edit/inspector-controls.js +103 -44
- package/src/cover/editor.scss +1 -0
- package/src/cover/index.php +38 -19
- package/src/cover/style.scss +1 -1
- package/src/cover/test/edit.js +2 -2
- package/src/editor.scss +0 -1
- package/src/embed/edit.js +19 -2
- package/src/embed/embed-preview.js +2 -18
- package/src/file/block.json +8 -4
- package/src/post-navigation-link/block.json +6 -0
- package/src/post-navigation-link/variations.js +12 -0
- package/src/post-terms/index.php +7 -6
- package/src/post-time-to-read/index.js +1 -0
- package/src/query/block.json +1 -0
- package/src/query/edit/inspector-controls/index.js +7 -10
- package/src/query/edit/inspector-controls/pages-control.js +1 -1
- package/src/query/edit/inspector-controls/per-page-control.js +1 -1
- package/src/query/edit/pattern-selection-modal.js +1 -1
- package/src/query-no-results/block.json +10 -0
- package/src/query-pagination-numbers/index.js +1 -0
- package/src/query-title/block.json +5 -0
- package/src/site-logo/edit.js +1 -0
- package/src/social-links/editor.scss +4 -13
- package/src/table-of-contents/block.json +52 -1
- package/src/template-part/edit/selection-modal.js +1 -1
- package/src/term-description/index.js +1 -0
- package/build-style/post-content/editor-rtl.css +0 -95
- package/build-style/post-content/editor.css +0 -95
- package/src/post-content/editor.scss +0 -4
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["clsx","AlignmentControl","BlockControls","InspectorControls","useBlockProps","PlainText","HeadingLevelDropdown","useBlockEditingMode","ToggleControl","TextControl","PanelBody","__","createBlock","getDefaultBlockName","useEntityProp","store","coreStore","useSelect","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","PostTitleEdit","attributes","level","levelOptions","textAlign","isLink","rel","linkTarget","setAttributes","context","postType","postId","queryId","insertBlocksAfter","TagName","isDescendentOfQueryLoop","Number","isFinite","userCanEdit","select","canUser","kind","name","id","rawTitle","setTitle","fullTitle","link","onSplitAtEnd","blockProps","className","blockEditingMode","titleElement","children","tagName","placeholder","value","onChange","__experimentalVersion","__unstableOnSplitAtEnd","dangerouslySetInnerHTML","__html","rendered","href","target","length","onClick","event","preventDefault","group","options","newLevel","nextAlign","title","__nextHasNoMarginBottom","label","checked","__next40pxDefaultSize","newRel"],"sources":["@wordpress/block-library/src/post-title/edit.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport {\n\tAlignmentControl,\n\tBlockControls,\n\tInspectorControls,\n\tuseBlockProps,\n\tPlainText,\n\tHeadingLevelDropdown,\n\tuseBlockEditingMode,\n} from '@wordpress/block-editor';\nimport { ToggleControl, TextControl, PanelBody } from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { createBlock, getDefaultBlockName } from '@wordpress/blocks';\nimport { useEntityProp, store as coreStore } from '@wordpress/core-data';\nimport { useSelect } from '@wordpress/data';\n\nexport default function PostTitleEdit( {\n\tattributes: { level, levelOptions, textAlign, isLink, rel, linkTarget },\n\tsetAttributes,\n\tcontext: { postType, postId, queryId },\n\tinsertBlocksAfter,\n} ) {\n\tconst TagName = level === 0 ? 'p' : `h${ level }`;\n\tconst isDescendentOfQueryLoop = Number.isFinite( queryId );\n\tconst userCanEdit = useSelect(\n\t\t( select ) => {\n\t\t\t/**\n\t\t\t * useCanEditEntity may trigger an OPTIONS request to the REST API\n\t\t\t * via the canUser resolver. However, when the Post Title is a\n\t\t\t * descendant of a Query Loop block, the title cannot be edited. In\n\t\t\t * order to avoid these unnecessary requests, we call the hook\n\t\t\t * without the proper data, resulting in returning early without\n\t\t\t * making them.\n\t\t\t */\n\t\t\tif ( isDescendentOfQueryLoop ) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\treturn select( coreStore ).canUser( 'update', {\n\t\t\t\tkind: 'postType',\n\t\t\t\tname: postType,\n\t\t\t\tid: postId,\n\t\t\t} );\n\t\t},\n\t\t[ isDescendentOfQueryLoop, postType, postId ]\n\t);\n\tconst [ rawTitle = '', setTitle, fullTitle ] = useEntityProp(\n\t\t'postType',\n\t\tpostType,\n\t\t'title',\n\t\tpostId\n\t);\n\tconst [ link ] = useEntityProp( 'postType', postType, 'link', postId );\n\tconst onSplitAtEnd = () => {\n\t\tinsertBlocksAfter( createBlock( getDefaultBlockName() ) );\n\t};\n\tconst blockProps = useBlockProps( {\n\t\tclassName: clsx( {\n\t\t\t[ `has-text-align-${ textAlign }` ]: textAlign,\n\t\t} ),\n\t} );\n\tconst blockEditingMode = useBlockEditingMode();\n\n\tlet titleElement = <TagName { ...blockProps }>{ __( 'Title' ) }</TagName>;\n\n\tif ( postType && postId ) {\n\t\ttitleElement = userCanEdit ? (\n\t\t\t<PlainText\n\t\t\t\ttagName={ TagName }\n\t\t\t\tplaceholder={ __( 'No title' ) }\n\t\t\t\tvalue={ rawTitle }\n\t\t\t\tonChange={ setTitle }\n\t\t\t\t__experimentalVersion={ 2 }\n\t\t\t\t__unstableOnSplitAtEnd={ onSplitAtEnd }\n\t\t\t\t{ ...blockProps }\n\t\t\t/>\n\t\t) : (\n\t\t\t<TagName\n\t\t\t\t{ ...blockProps }\n\t\t\t\tdangerouslySetInnerHTML={ { __html: fullTitle?.rendered } }\n\t\t\t/>\n\t\t);\n\t}\n\n\tif ( isLink && postType && postId ) {\n\t\ttitleElement = userCanEdit ? (\n\t\t\t<TagName { ...blockProps }>\n\t\t\t\t<PlainText\n\t\t\t\t\ttagName=\"a\"\n\t\t\t\t\thref={ link }\n\t\t\t\t\ttarget={ linkTarget }\n\t\t\t\t\trel={ rel }\n\t\t\t\t\tplaceholder={ ! rawTitle.length ? __( 'No title' ) : null }\n\t\t\t\t\tvalue={ rawTitle }\n\t\t\t\t\tonChange={ setTitle }\n\t\t\t\t\t__experimentalVersion={ 2 }\n\t\t\t\t\t__unstableOnSplitAtEnd={ onSplitAtEnd }\n\t\t\t\t/>\n\t\t\t</TagName>\n\t\t) : (\n\t\t\t<TagName { ...blockProps }>\n\t\t\t\t<a\n\t\t\t\t\thref={ link }\n\t\t\t\t\ttarget={ linkTarget }\n\t\t\t\t\trel={ rel }\n\t\t\t\t\tonClick={ ( event ) => event.preventDefault() }\n\t\t\t\t\tdangerouslySetInnerHTML={ {\n\t\t\t\t\t\t__html: fullTitle?.rendered,\n\t\t\t\t\t} }\n\t\t\t\t/>\n\t\t\t</TagName>\n\t\t);\n\t}\n\n\treturn (\n\t\t<>\n\t\t\t{ blockEditingMode === 'default' && (\n\t\t\t\t<>\n\t\t\t\t\t<BlockControls group=\"block\">\n\t\t\t\t\t\t<HeadingLevelDropdown\n\t\t\t\t\t\t\tvalue={ level }\n\t\t\t\t\t\t\toptions={ levelOptions }\n\t\t\t\t\t\t\tonChange={ ( newLevel ) =>\n\t\t\t\t\t\t\t\tsetAttributes( { level: newLevel } )\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t/>\n\t\t\t\t\t\t<AlignmentControl\n\t\t\t\t\t\t\tvalue={ textAlign }\n\t\t\t\t\t\t\tonChange={ ( nextAlign ) => {\n\t\t\t\t\t\t\t\tsetAttributes( { textAlign: nextAlign } );\n\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t/>\n\t\t\t\t\t</BlockControls>\n\t\t\t\t\t<InspectorControls>\n\t\t\t\t\t\t<PanelBody title={ __( 'Settings' ) }>\n\t\t\t\t\t\t\t<ToggleControl\n\t\t\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t\t\t\tlabel={ __( 'Make title a link' ) }\n\t\t\t\t\t\t\t\tonChange={ () =>\n\t\t\t\t\t\t\t\t\tsetAttributes( { isLink: ! isLink } )\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tchecked={ isLink }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t{ isLink && (\n\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t<ToggleControl\n\t\t\t\t\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t\t\t\t\t\tlabel={ __( 'Open in new tab' ) }\n\t\t\t\t\t\t\t\t\t\tonChange={ ( value ) =>\n\t\t\t\t\t\t\t\t\t\t\tsetAttributes( {\n\t\t\t\t\t\t\t\t\t\t\t\tlinkTarget: value\n\t\t\t\t\t\t\t\t\t\t\t\t\t? '_blank'\n\t\t\t\t\t\t\t\t\t\t\t\t\t: '_self',\n\t\t\t\t\t\t\t\t\t\t\t} )\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\tchecked={ linkTarget === '_blank' }\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t<TextControl\n\t\t\t\t\t\t\t\t\t\t__next40pxDefaultSize\n\t\t\t\t\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t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uB;cACvBC,KAAK,EAAGpE,EAAE,CAAE,UAAW,CAAG;cAC1BiD,KAAK,EAAG9B,GAAK;cACb+B,QAAQ,EAAKqB,MAAM,IAClBlD,aAAa,CAAE;gBAAEF,GAAG,EAAEoD;cAAO,CAAE;YAC/B,CACD,CAAC;UAAA,CACD,CACF;QAAA,CACS;MAAC,CACM,CAAC;IAAA,CACnB,CACF,EACC1B,YAAY;EAAA,CACb,CAAC;AAEL","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["clsx","AlignmentControl","BlockControls","InspectorControls","useBlockProps","PlainText","HeadingLevelDropdown","useBlockEditingMode","ToggleControl","TextControl","PanelBody","__","createBlock","getDefaultBlockName","useEntityProp","store","coreStore","useSelect","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","PostTitleEdit","attributes","level","levelOptions","textAlign","isLink","rel","linkTarget","setAttributes","context","postType","postId","queryId","insertBlocksAfter","TagName","isDescendentOfQueryLoop","Number","isFinite","userCanEdit","select","canUser","kind","name","id","rawTitle","setTitle","fullTitle","link","onSplitAtEnd","blockProps","className","blockEditingMode","titleElement","children","tagName","placeholder","value","onChange","__experimentalVersion","__unstableOnSplitAtEnd","dangerouslySetInnerHTML","__html","rendered","href","target","length","onClick","event","preventDefault","group","options","newLevel","nextAlign","title","__nextHasNoMarginBottom","label","checked","__next40pxDefaultSize","newRel"],"sources":["@wordpress/block-library/src/post-title/edit.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport {\n\tAlignmentControl,\n\tBlockControls,\n\tInspectorControls,\n\tuseBlockProps,\n\tPlainText,\n\tHeadingLevelDropdown,\n\tuseBlockEditingMode,\n} from '@wordpress/block-editor';\nimport { ToggleControl, TextControl, PanelBody } from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { createBlock, getDefaultBlockName } from '@wordpress/blocks';\nimport { useEntityProp, store as coreStore } from '@wordpress/core-data';\nimport { useSelect } from '@wordpress/data';\n\nexport default function PostTitleEdit( {\n\tattributes: { level, levelOptions, textAlign, isLink, rel, linkTarget },\n\tsetAttributes,\n\tcontext: { postType, postId, queryId },\n\tinsertBlocksAfter,\n} ) {\n\tconst TagName = level === 0 ? 'p' : `h${ level }`;\n\tconst isDescendentOfQueryLoop = Number.isFinite( queryId );\n\tconst userCanEdit = useSelect(\n\t\t( select ) => {\n\t\t\t/**\n\t\t\t * useCanEditEntity may trigger an OPTIONS request to the REST API\n\t\t\t * via the canUser resolver. However, when the Post Title is a\n\t\t\t * descendant of a Query Loop block, the title cannot be edited. In\n\t\t\t * order to avoid these unnecessary requests, we call the hook\n\t\t\t * without the proper data, resulting in returning early without\n\t\t\t * making them.\n\t\t\t */\n\t\t\tif ( isDescendentOfQueryLoop ) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\treturn select( coreStore ).canUser( 'update', {\n\t\t\t\tkind: 'postType',\n\t\t\t\tname: postType,\n\t\t\t\tid: postId,\n\t\t\t} );\n\t\t},\n\t\t[ isDescendentOfQueryLoop, postType, postId ]\n\t);\n\tconst [ rawTitle = '', setTitle, fullTitle ] = useEntityProp(\n\t\t'postType',\n\t\tpostType,\n\t\t'title',\n\t\tpostId\n\t);\n\tconst [ link ] = useEntityProp( 'postType', postType, 'link', postId );\n\tconst onSplitAtEnd = () => {\n\t\tinsertBlocksAfter( createBlock( getDefaultBlockName() ) );\n\t};\n\tconst blockProps = useBlockProps( {\n\t\tclassName: clsx( {\n\t\t\t[ `has-text-align-${ textAlign }` ]: textAlign,\n\t\t} ),\n\t} );\n\tconst blockEditingMode = useBlockEditingMode();\n\n\tlet titleElement = <TagName { ...blockProps }>{ __( 'Title' ) }</TagName>;\n\n\tif ( postType && postId ) {\n\t\ttitleElement = userCanEdit ? (\n\t\t\t<PlainText\n\t\t\t\ttagName={ TagName }\n\t\t\t\tplaceholder={ __( 'No title' ) }\n\t\t\t\tvalue={ rawTitle }\n\t\t\t\tonChange={ setTitle }\n\t\t\t\t__experimentalVersion={ 2 }\n\t\t\t\t__unstableOnSplitAtEnd={ onSplitAtEnd }\n\t\t\t\t{ ...blockProps }\n\t\t\t/>\n\t\t) : (\n\t\t\t<TagName\n\t\t\t\t{ ...blockProps }\n\t\t\t\tdangerouslySetInnerHTML={ { __html: fullTitle?.rendered } }\n\t\t\t/>\n\t\t);\n\t}\n\n\tif ( isLink && postType && postId ) {\n\t\ttitleElement = userCanEdit ? (\n\t\t\t<TagName { ...blockProps }>\n\t\t\t\t<PlainText\n\t\t\t\t\ttagName=\"a\"\n\t\t\t\t\thref={ link }\n\t\t\t\t\ttarget={ linkTarget }\n\t\t\t\t\trel={ rel }\n\t\t\t\t\tplaceholder={ ! rawTitle.length ? __( 'No title' ) : null }\n\t\t\t\t\tvalue={ rawTitle }\n\t\t\t\t\tonChange={ setTitle }\n\t\t\t\t\t__experimentalVersion={ 2 }\n\t\t\t\t\t__unstableOnSplitAtEnd={ onSplitAtEnd }\n\t\t\t\t/>\n\t\t\t</TagName>\n\t\t) : (\n\t\t\t<TagName { ...blockProps }>\n\t\t\t\t<a\n\t\t\t\t\thref={ link }\n\t\t\t\t\ttarget={ linkTarget }\n\t\t\t\t\trel={ rel }\n\t\t\t\t\tonClick={ ( event ) => event.preventDefault() }\n\t\t\t\t\tdangerouslySetInnerHTML={ {\n\t\t\t\t\t\t__html: fullTitle?.rendered,\n\t\t\t\t\t} }\n\t\t\t\t/>\n\t\t\t</TagName>\n\t\t);\n\t}\n\n\treturn (\n\t\t<>\n\t\t\t{ blockEditingMode === 'default' && (\n\t\t\t\t<>\n\t\t\t\t\t<BlockControls group=\"block\">\n\t\t\t\t\t\t<HeadingLevelDropdown\n\t\t\t\t\t\t\tvalue={ level }\n\t\t\t\t\t\t\toptions={ levelOptions }\n\t\t\t\t\t\t\tonChange={ ( newLevel ) =>\n\t\t\t\t\t\t\t\tsetAttributes( { level: newLevel } )\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t/>\n\t\t\t\t\t\t<AlignmentControl\n\t\t\t\t\t\t\tvalue={ textAlign }\n\t\t\t\t\t\t\tonChange={ ( nextAlign ) => {\n\t\t\t\t\t\t\t\tsetAttributes( { textAlign: nextAlign } );\n\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t/>\n\t\t\t\t\t</BlockControls>\n\t\t\t\t\t<InspectorControls>\n\t\t\t\t\t\t<PanelBody title={ __( 'Settings' ) }>\n\t\t\t\t\t\t\t<ToggleControl\n\t\t\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t\t\t\tlabel={ __( 'Make title a link' ) }\n\t\t\t\t\t\t\t\tonChange={ () =>\n\t\t\t\t\t\t\t\t\tsetAttributes( { isLink: ! isLink } )\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tchecked={ isLink }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t{ isLink && (\n\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t<ToggleControl\n\t\t\t\t\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t\t\t\t\t\tlabel={ __( 'Open in new tab' ) }\n\t\t\t\t\t\t\t\t\t\tonChange={ ( value ) =>\n\t\t\t\t\t\t\t\t\t\t\tsetAttributes( {\n\t\t\t\t\t\t\t\t\t\t\t\tlinkTarget: value\n\t\t\t\t\t\t\t\t\t\t\t\t\t? '_blank'\n\t\t\t\t\t\t\t\t\t\t\t\t\t: '_self',\n\t\t\t\t\t\t\t\t\t\t\t} )\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\tchecked={ linkTarget === '_blank' }\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t<TextControl\n\t\t\t\t\t\t\t\t\t\t__next40pxDefaultSize\n\t\t\t\t\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t\t\t\t\t\tlabel={ __( 'Link rel' ) }\n\t\t\t\t\t\t\t\t\t\tvalue={ rel }\n\t\t\t\t\t\t\t\t\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AAM,IAClBlD,aAAa,CAAE;gBAAEF,GAAG,EAAEoD;cAAO,CAAE;YAC/B,CACD,CAAC;UAAA,CACD,CACF;QAAA,CACS;MAAC,CACM,CAAC;IAAA,CACnB,CACF,EACC1B,YAAY;EAAA,CACb,CAAC;AAEL","ignoreList":[]}
|
|
@@ -13,8 +13,7 @@ import { select } from '@wordpress/data';
|
|
|
13
13
|
* Internal dependencies
|
|
14
14
|
*/
|
|
15
15
|
import { SOLID_COLOR_CLASS } from './shared';
|
|
16
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
17
|
-
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
16
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
18
17
|
const blockAttributes = {
|
|
19
18
|
value: {
|
|
20
19
|
type: 'string',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["clsx","getColorClassName","getColorObjectByAttributeValues","RichText","store","blockEditorStore","useBlockProps","select","SOLID_COLOR_CLASS","jsx","_jsx","jsxs","_jsxs","blockAttributes","value","type","source","selector","multiline","citation","default","mainColor","customMainColor","textColor","customTextColor","parseBorderColor","styleString","matches","match","multilineToInline","padded","values","split","shift","pop","join","v5","attributes","role","textAlign","save","shouldShowCitation","isEmpty","className","children","Content","tagName","migrate","v4","isSolidColorStyle","includes","figureClasses","figureStyles","backgroundClass","backgroundColor","undefined","borderColor","blockquoteTextColorClass","blockquoteClasses","blockquoteStyles","color","style","border","background","text","v3","figureStyle","attribute","v2","figureClass","_select$getSettings$c","colors","getSettings","colorObject","blockquoteStyle","v1","v0","align"],"sources":["@wordpress/block-library/src/pullquote/deprecated.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport {\n\tgetColorClassName,\n\tgetColorObjectByAttributeValues,\n\tRichText,\n\tstore as blockEditorStore,\n\tuseBlockProps,\n} from '@wordpress/block-editor';\nimport { select } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport { SOLID_COLOR_CLASS } from './shared';\n\nconst blockAttributes = {\n\tvalue: {\n\t\ttype: 'string',\n\t\tsource: 'html',\n\t\tselector: 'blockquote',\n\t\tmultiline: 'p',\n\t},\n\tcitation: {\n\t\ttype: 'string',\n\t\tsource: 'html',\n\t\tselector: 'cite',\n\t\tdefault: '',\n\t},\n\tmainColor: {\n\t\ttype: 'string',\n\t},\n\tcustomMainColor: {\n\t\ttype: 'string',\n\t},\n\ttextColor: {\n\t\ttype: 'string',\n\t},\n\tcustomTextColor: {\n\t\ttype: 'string',\n\t},\n};\n\nfunction parseBorderColor( styleString ) {\n\tif ( ! styleString ) {\n\t\treturn;\n\t}\n\tconst matches = styleString.match( /border-color:([^;]+)[;]?/ );\n\tif ( matches && matches[ 1 ] ) {\n\t\treturn matches[ 1 ];\n\t}\n}\n\nfunction multilineToInline( value ) {\n\tvalue = value || `<p></p>`;\n\tconst padded = `</p>${ value }<p>`;\n\tconst values = padded.split( `</p><p>` );\n\n\tvalues.shift();\n\tvalues.pop();\n\n\treturn values.join( '<br>' );\n}\n\nconst v5 = {\n\tattributes: {\n\t\tvalue: {\n\t\t\ttype: 'string',\n\t\t\tsource: 'html',\n\t\t\tselector: 'blockquote',\n\t\t\tmultiline: 'p',\n\t\t\trole: 'content',\n\t\t},\n\t\tcitation: {\n\t\t\ttype: 'string',\n\t\t\tsource: 'html',\n\t\t\tselector: 'cite',\n\t\t\tdefault: '',\n\t\t\trole: 'content',\n\t\t},\n\t\ttextAlign: {\n\t\t\ttype: 'string',\n\t\t},\n\t},\n\tsave( { attributes } ) {\n\t\tconst { textAlign, citation, value } = attributes;\n\t\tconst shouldShowCitation = ! RichText.isEmpty( citation );\n\n\t\treturn (\n\t\t\t<figure\n\t\t\t\t{ ...useBlockProps.save( {\n\t\t\t\t\tclassName: clsx( {\n\t\t\t\t\t\t[ `has-text-align-${ textAlign }` ]: textAlign,\n\t\t\t\t\t} ),\n\t\t\t\t} ) }\n\t\t\t>\n\t\t\t\t<blockquote>\n\t\t\t\t\t<RichText.Content value={ value } multiline />\n\t\t\t\t\t{ shouldShowCitation && (\n\t\t\t\t\t\t<RichText.Content tagName=\"cite\" value={ citation } />\n\t\t\t\t\t) }\n\t\t\t\t</blockquote>\n\t\t\t</figure>\n\t\t);\n\t},\n\tmigrate( { value, ...attributes } ) {\n\t\treturn {\n\t\t\tvalue: multilineToInline( value ),\n\t\t\t...attributes,\n\t\t};\n\t},\n};\n\n// TODO: this is ripe for a bit of a clean up according to the example in https://developer.wordpress.org/block-editor/reference-guides/block-api/block-deprecation/#example\n\nconst v4 = {\n\tattributes: {\n\t\t...blockAttributes,\n\t},\n\tsave( { attributes } ) {\n\t\tconst {\n\t\t\tmainColor,\n\t\t\tcustomMainColor,\n\t\t\tcustomTextColor,\n\t\t\ttextColor,\n\t\t\tvalue,\n\t\t\tcitation,\n\t\t\tclassName,\n\t\t} = attributes;\n\n\t\tconst isSolidColorStyle = className?.includes( SOLID_COLOR_CLASS );\n\n\t\tlet figureClasses, figureStyles;\n\n\t\t// Is solid color style\n\t\tif ( isSolidColorStyle ) {\n\t\t\tconst backgroundClass = getColorClassName(\n\t\t\t\t'background-color',\n\t\t\t\tmainColor\n\t\t\t);\n\n\t\t\tfigureClasses = clsx( {\n\t\t\t\t'has-background': backgroundClass || customMainColor,\n\t\t\t\t[ backgroundClass ]: backgroundClass,\n\t\t\t} );\n\n\t\t\tfigureStyles = {\n\t\t\t\tbackgroundColor: backgroundClass ? undefined : customMainColor,\n\t\t\t};\n\t\t\t// Is normal style and a custom color is being used ( we can set a style directly with its value)\n\t\t} else if ( customMainColor ) {\n\t\t\tfigureStyles = {\n\t\t\t\tborderColor: customMainColor,\n\t\t\t};\n\t\t}\n\n\t\tconst blockquoteTextColorClass = getColorClassName(\n\t\t\t'color',\n\t\t\ttextColor\n\t\t);\n\t\tconst blockquoteClasses = clsx( {\n\t\t\t'has-text-color': textColor || customTextColor,\n\t\t\t[ blockquoteTextColorClass ]: blockquoteTextColorClass,\n\t\t} );\n\n\t\tconst blockquoteStyles = blockquoteTextColorClass\n\t\t\t? undefined\n\t\t\t: { color: customTextColor };\n\n\t\treturn (\n\t\t\t<figure\n\t\t\t\t{ ...useBlockProps.save( {\n\t\t\t\t\tclassName: figureClasses,\n\t\t\t\t\tstyle: figureStyles,\n\t\t\t\t} ) }\n\t\t\t>\n\t\t\t\t<blockquote\n\t\t\t\t\tclassName={ blockquoteClasses }\n\t\t\t\t\tstyle={ blockquoteStyles }\n\t\t\t\t>\n\t\t\t\t\t<RichText.Content value={ value } multiline />\n\t\t\t\t\t{ ! RichText.isEmpty( citation ) && (\n\t\t\t\t\t\t<RichText.Content tagName=\"cite\" value={ citation } />\n\t\t\t\t\t) }\n\t\t\t\t</blockquote>\n\t\t\t</figure>\n\t\t);\n\t},\n\tmigrate( {\n\t\tvalue,\n\t\tclassName,\n\t\tmainColor,\n\t\tcustomMainColor,\n\t\tcustomTextColor,\n\t\t...attributes\n\t} ) {\n\t\tconst isSolidColorStyle = className?.includes( SOLID_COLOR_CLASS );\n\t\tlet style;\n\n\t\tif ( customMainColor ) {\n\t\t\tif ( ! isSolidColorStyle ) {\n\t\t\t\t// Block supports: Set style.border.color if a deprecated block has a default style and a `customMainColor` attribute.\n\t\t\t\tstyle = {\n\t\t\t\t\tborder: {\n\t\t\t\t\t\tcolor: customMainColor,\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t} else {\n\t\t\t\t// Block supports: Set style.color.background if a deprecated block has a solid style and a `customMainColor` attribute.\n\t\t\t\tstyle = {\n\t\t\t\t\tcolor: {\n\t\t\t\t\t\tbackground: customMainColor,\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\n\t\t// Block supports: Set style.color.text if a deprecated block has a `customTextColor` attribute.\n\t\tif ( customTextColor && style ) {\n\t\t\tstyle.color = {\n\t\t\t\t...style.color,\n\t\t\t\ttext: customTextColor,\n\t\t\t};\n\t\t}\n\n\t\treturn {\n\t\t\tvalue: multilineToInline( value ),\n\t\t\tclassName,\n\t\t\tbackgroundColor: isSolidColorStyle ? mainColor : undefined,\n\t\t\tborderColor: isSolidColorStyle ? undefined : mainColor,\n\t\t\ttextAlign: isSolidColorStyle ? 'left' : undefined,\n\t\t\tstyle,\n\t\t\t...attributes,\n\t\t};\n\t},\n};\n\nconst v3 = {\n\tattributes: {\n\t\t...blockAttributes,\n\t\t// figureStyle is an attribute that never existed.\n\t\t// We are using it as a way to access the styles previously applied to the figure.\n\t\tfigureStyle: {\n\t\t\tsource: 'attribute',\n\t\t\tselector: 'figure',\n\t\t\tattribute: 'style',\n\t\t},\n\t},\n\tsave( { attributes } ) {\n\t\tconst {\n\t\t\tmainColor,\n\t\t\tcustomMainColor,\n\t\t\ttextColor,\n\t\t\tcustomTextColor,\n\t\t\tvalue,\n\t\t\tcitation,\n\t\t\tclassName,\n\t\t\tfigureStyle,\n\t\t} = attributes;\n\n\t\tconst isSolidColorStyle = className?.includes( SOLID_COLOR_CLASS );\n\n\t\tlet figureClasses, figureStyles;\n\n\t\t// Is solid color style\n\t\tif ( isSolidColorStyle ) {\n\t\t\tconst backgroundClass = getColorClassName(\n\t\t\t\t'background-color',\n\t\t\t\tmainColor\n\t\t\t);\n\n\t\t\tfigureClasses = clsx( {\n\t\t\t\t'has-background': backgroundClass || customMainColor,\n\t\t\t\t[ backgroundClass ]: backgroundClass,\n\t\t\t} );\n\n\t\t\tfigureStyles = {\n\t\t\t\tbackgroundColor: backgroundClass ? undefined : customMainColor,\n\t\t\t};\n\t\t\t// Is normal style and a custom color is being used ( we can set a style directly with its value)\n\t\t} else if ( customMainColor ) {\n\t\t\tfigureStyles = {\n\t\t\t\tborderColor: customMainColor,\n\t\t\t};\n\t\t\t// If normal style and a named color are being used, we need to retrieve the color value to set the style,\n\t\t\t// as there is no expectation that themes create classes that set border colors.\n\t\t} else if ( mainColor ) {\n\t\t\t// Previously here we queried the color settings to know the color value\n\t\t\t// of a named color. This made the save function impure and the block was refactored,\n\t\t\t// because meanwhile a change in the editor made it impossible to query color settings in the save function.\n\t\t\t// Here instead of querying the color settings to know the color value, we retrieve the value\n\t\t\t// directly from the style previously serialized.\n\t\t\tconst borderColor = parseBorderColor( figureStyle );\n\t\t\tfigureStyles = {\n\t\t\t\tborderColor,\n\t\t\t};\n\t\t}\n\n\t\tconst blockquoteTextColorClass = getColorClassName(\n\t\t\t'color',\n\t\t\ttextColor\n\t\t);\n\t\tconst blockquoteClasses =\n\t\t\t( textColor || customTextColor ) &&\n\t\t\tclsx( 'has-text-color', {\n\t\t\t\t[ blockquoteTextColorClass ]: blockquoteTextColorClass,\n\t\t\t} );\n\n\t\tconst blockquoteStyles = blockquoteTextColorClass\n\t\t\t? undefined\n\t\t\t: { color: customTextColor };\n\n\t\treturn (\n\t\t\t<figure className={ figureClasses } style={ figureStyles }>\n\t\t\t\t<blockquote\n\t\t\t\t\tclassName={ blockquoteClasses }\n\t\t\t\t\tstyle={ blockquoteStyles }\n\t\t\t\t>\n\t\t\t\t\t<RichText.Content value={ value } multiline />\n\t\t\t\t\t{ ! RichText.isEmpty( citation ) && (\n\t\t\t\t\t\t<RichText.Content tagName=\"cite\" value={ citation } />\n\t\t\t\t\t) }\n\t\t\t\t</blockquote>\n\t\t\t</figure>\n\t\t);\n\t},\n\tmigrate( {\n\t\tvalue,\n\t\tclassName,\n\t\tfigureStyle,\n\t\tmainColor,\n\t\tcustomMainColor,\n\t\tcustomTextColor,\n\t\t...attributes\n\t} ) {\n\t\tconst isSolidColorStyle = className?.includes( SOLID_COLOR_CLASS );\n\t\tlet style;\n\n\t\tif ( customMainColor ) {\n\t\t\tif ( ! isSolidColorStyle ) {\n\t\t\t\t// Block supports: Set style.border.color if a deprecated block has a default style and a `customMainColor` attribute.\n\t\t\t\tstyle = {\n\t\t\t\t\tborder: {\n\t\t\t\t\t\tcolor: customMainColor,\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t} else {\n\t\t\t\t// Block supports: Set style.color.background if a deprecated block has a solid style and a `customMainColor` attribute.\n\t\t\t\tstyle = {\n\t\t\t\t\tcolor: {\n\t\t\t\t\t\tbackground: customMainColor,\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\n\t\t// Block supports: Set style.color.text if a deprecated block has a `customTextColor` attribute.\n\t\tif ( customTextColor && style ) {\n\t\t\tstyle.color = {\n\t\t\t\t...style.color,\n\t\t\t\ttext: customTextColor,\n\t\t\t};\n\t\t}\n\t\t// If is the default style, and a main color is set,\n\t\t// migrate the main color value into a custom border color.\n\t\t// The custom border color value is retrieved by parsing the figure styles.\n\t\tif ( ! isSolidColorStyle && mainColor && figureStyle ) {\n\t\t\tconst borderColor = parseBorderColor( figureStyle );\n\t\t\tif ( borderColor ) {\n\t\t\t\treturn {\n\t\t\t\t\tvalue: multilineToInline( value ),\n\t\t\t\t\t...attributes,\n\t\t\t\t\tclassName,\n\t\t\t\t\t// Block supports: Set style.border.color if a deprecated block has `mainColor`, inline border CSS and is not a solid color style.\n\t\t\t\t\tstyle: {\n\t\t\t\t\t\tborder: {\n\t\t\t\t\t\t\tcolor: borderColor,\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\t\treturn {\n\t\t\tvalue: multilineToInline( value ),\n\t\t\tclassName,\n\t\t\tbackgroundColor: isSolidColorStyle ? mainColor : undefined,\n\t\t\tborderColor: isSolidColorStyle ? undefined : mainColor,\n\t\t\ttextAlign: isSolidColorStyle ? 'left' : undefined,\n\t\t\tstyle,\n\t\t\t...attributes,\n\t\t};\n\t},\n};\n\nconst v2 = {\n\tattributes: blockAttributes,\n\tsave( { attributes } ) {\n\t\tconst {\n\t\t\tmainColor,\n\t\t\tcustomMainColor,\n\t\t\ttextColor,\n\t\t\tcustomTextColor,\n\t\t\tvalue,\n\t\t\tcitation,\n\t\t\tclassName,\n\t\t} = attributes;\n\t\tconst isSolidColorStyle = className?.includes( SOLID_COLOR_CLASS );\n\n\t\tlet figureClass, figureStyles;\n\t\t// Is solid color style\n\t\tif ( isSolidColorStyle ) {\n\t\t\tfigureClass = getColorClassName( 'background-color', mainColor );\n\t\t\tif ( ! figureClass ) {\n\t\t\t\tfigureStyles = {\n\t\t\t\t\tbackgroundColor: customMainColor,\n\t\t\t\t};\n\t\t\t}\n\t\t\t// Is normal style and a custom color is being used ( we can set a style directly with its value)\n\t\t} else if ( customMainColor ) {\n\t\t\tfigureStyles = {\n\t\t\t\tborderColor: customMainColor,\n\t\t\t};\n\t\t\t// Is normal style and a named color is being used, we need to retrieve the color value to set the style,\n\t\t\t// as there is no expectation that themes create classes that set border colors.\n\t\t} else if ( mainColor ) {\n\t\t\tconst colors =\n\t\t\t\tselect( blockEditorStore ).getSettings().colors ?? [];\n\t\t\tconst colorObject = getColorObjectByAttributeValues(\n\t\t\t\tcolors,\n\t\t\t\tmainColor\n\t\t\t);\n\t\t\tfigureStyles = {\n\t\t\t\tborderColor: colorObject.color,\n\t\t\t};\n\t\t}\n\n\t\tconst blockquoteTextColorClass = getColorClassName(\n\t\t\t'color',\n\t\t\ttextColor\n\t\t);\n\t\tconst blockquoteClasses =\n\t\t\ttextColor || customTextColor\n\t\t\t\t? clsx( 'has-text-color', {\n\t\t\t\t\t\t[ blockquoteTextColorClass ]: blockquoteTextColorClass,\n\t\t\t\t } )\n\t\t\t\t: undefined;\n\t\tconst blockquoteStyle = blockquoteTextColorClass\n\t\t\t? undefined\n\t\t\t: { color: customTextColor };\n\t\treturn (\n\t\t\t<figure className={ figureClass } style={ figureStyles }>\n\t\t\t\t<blockquote\n\t\t\t\t\tclassName={ blockquoteClasses }\n\t\t\t\t\tstyle={ blockquoteStyle }\n\t\t\t\t>\n\t\t\t\t\t<RichText.Content value={ value } multiline />\n\t\t\t\t\t{ ! RichText.isEmpty( citation ) && (\n\t\t\t\t\t\t<RichText.Content tagName=\"cite\" value={ citation } />\n\t\t\t\t\t) }\n\t\t\t\t</blockquote>\n\t\t\t</figure>\n\t\t);\n\t},\n\tmigrate( {\n\t\tvalue,\n\t\tclassName,\n\t\tmainColor,\n\t\tcustomMainColor,\n\t\tcustomTextColor,\n\t\t...attributes\n\t} ) {\n\t\tconst isSolidColorStyle = className?.includes( SOLID_COLOR_CLASS );\n\t\tlet style = {};\n\n\t\tif ( customMainColor ) {\n\t\t\tif ( ! isSolidColorStyle ) {\n\t\t\t\t// Block supports: Set style.border.color if a deprecated block has a default style and a `customMainColor` attribute.\n\t\t\t\tstyle = {\n\t\t\t\t\tborder: {\n\t\t\t\t\t\tcolor: customMainColor,\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t} else {\n\t\t\t\t// Block supports: Set style.color.background if a deprecated block has a solid style and a `customMainColor` attribute.\n\t\t\t\tstyle = {\n\t\t\t\t\tcolor: {\n\t\t\t\t\t\tbackground: customMainColor,\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\n\t\t// Block supports: Set style.color.text if a deprecated block has a `customTextColor` attribute.\n\t\tif ( customTextColor && style ) {\n\t\t\tstyle.color = {\n\t\t\t\t...style.color,\n\t\t\t\ttext: customTextColor,\n\t\t\t};\n\t\t}\n\n\t\treturn {\n\t\t\tvalue: multilineToInline( value ),\n\t\t\tclassName,\n\t\t\tbackgroundColor: isSolidColorStyle ? mainColor : undefined,\n\t\t\tborderColor: isSolidColorStyle ? undefined : mainColor,\n\t\t\ttextAlign: isSolidColorStyle ? 'left' : undefined,\n\t\t\tstyle,\n\t\t\t...attributes,\n\t\t};\n\t},\n};\n\nconst v1 = {\n\tattributes: {\n\t\t...blockAttributes,\n\t},\n\tsave( { attributes } ) {\n\t\tconst { value, citation } = attributes;\n\t\treturn (\n\t\t\t<blockquote>\n\t\t\t\t<RichText.Content value={ value } multiline />\n\t\t\t\t{ ! RichText.isEmpty( citation ) && (\n\t\t\t\t\t<RichText.Content tagName=\"cite\" value={ citation } />\n\t\t\t\t) }\n\t\t\t</blockquote>\n\t\t);\n\t},\n\tmigrate( { value, ...attributes } ) {\n\t\treturn {\n\t\t\tvalue: multilineToInline( value ),\n\t\t\t...attributes,\n\t\t};\n\t},\n};\n\nconst v0 = {\n\tattributes: {\n\t\t...blockAttributes,\n\t\tcitation: {\n\t\t\ttype: 'string',\n\t\t\tsource: 'html',\n\t\t\tselector: 'footer',\n\t\t},\n\t\talign: {\n\t\t\ttype: 'string',\n\t\t\tdefault: 'none',\n\t\t},\n\t},\n\n\tsave( { attributes } ) {\n\t\tconst { value, citation, align } = attributes;\n\n\t\treturn (\n\t\t\t<blockquote className={ `align${ align }` }>\n\t\t\t\t<RichText.Content value={ value } multiline />\n\t\t\t\t{ ! RichText.isEmpty( citation ) && (\n\t\t\t\t\t<RichText.Content tagName=\"footer\" value={ citation } />\n\t\t\t\t) }\n\t\t\t</blockquote>\n\t\t);\n\t},\n\tmigrate( { value, ...attributes } ) {\n\t\treturn {\n\t\t\tvalue: multilineToInline( value ),\n\t\t\t...attributes,\n\t\t};\n\t},\n};\n\n/**\n * New deprecations need to be placed first\n * for them to have higher priority.\n *\n * Old deprecations may need to be updated as well.\n *\n * See block-deprecation.md\n */\nexport default [ v5, v4, v3, v2, v1, v0 ];\n"],"mappings":"AAAA;AACA;AACA;AACA,OAAOA,IAAI,MAAM,MAAM;;AAEvB;AACA;AACA;AACA,SACCC,iBAAiB,EACjBC,+BAA+B,EAC/BC,QAAQ,EACRC,KAAK,IAAIC,gBAAgB,EACzBC,aAAa,QACP,yBAAyB;AAChC,SAASC,MAAM,QAAQ,iBAAiB;;AAExC;AACA;AACA;AACA,SAASC,iBAAiB,QAAQ,UAAU;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAAA,SAAAC,IAAA,IAAAC,KAAA;AAE7C,MAAMC,eAAe,GAAG;EACvBC,KAAK,EAAE;IACNC,IAAI,EAAE,QAAQ;IACdC,MAAM,EAAE,MAAM;IACdC,QAAQ,EAAE,YAAY;IACtBC,SAAS,EAAE;EACZ,CAAC;EACDC,QAAQ,EAAE;IACTJ,IAAI,EAAE,QAA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C;IACD4D,KAAK,EAAE;MACN9D,IAAI,EAAE,QAAQ;MACdK,OAAO,EAAE;IACV;EACD,CAAC;EAEDoB,IAAIA,CAAE;IAAEH;EAAW,CAAC,EAAG;IACtB,MAAM;MAAEvB,KAAK;MAAEK,QAAQ;MAAE0D;IAAM,CAAC,GAAGxC,UAAU;IAE7C,oBACCzB,KAAA;MAAY+B,SAAS,EAAI,QAAQkC,KAAO,EAAG;MAAAjC,QAAA,gBAC1ClC,IAAA,CAACP,QAAQ,CAAC0C,OAAO;QAAC/B,KAAK,EAAGA,KAAO;QAACI,SAAS;MAAA,CAAE,CAAC,EAC5C,CAAEf,QAAQ,CAACuC,OAAO,CAAEvB,QAAS,CAAC,iBAC/BT,IAAA,CAACP,QAAQ,CAAC0C,OAAO;QAACC,OAAO,EAAC,QAAQ;QAAChC,KAAK,EAAGK;MAAU,CAAE,CACvD;IAAA,CACU,CAAC;EAEf,CAAC;EACD4B,OAAOA,CAAE;IAAEjC,KAAK;IAAE,GAAGuB;EAAW,CAAC,EAAG;IACnC,OAAO;MACNvB,KAAK,EAAEe,iBAAiB,CAAEf,KAAM,CAAC;MACjC,GAAGuB;IACJ,CAAC;EACF;AACD,CAAC;;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,CAAED,EAAE,EAAEY,EAAE,EAAEiB,EAAE,EAAEG,EAAE,EAAEO,EAAE,EAAEC,EAAE,CAAE","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["clsx","getColorClassName","getColorObjectByAttributeValues","RichText","store","blockEditorStore","useBlockProps","select","SOLID_COLOR_CLASS","jsx","_jsx","jsxs","_jsxs","blockAttributes","value","type","source","selector","multiline","citation","default","mainColor","customMainColor","textColor","customTextColor","parseBorderColor","styleString","matches","match","multilineToInline","padded","values","split","shift","pop","join","v5","attributes","role","textAlign","save","shouldShowCitation","isEmpty","className","children","Content","tagName","migrate","v4","isSolidColorStyle","includes","figureClasses","figureStyles","backgroundClass","backgroundColor","undefined","borderColor","blockquoteTextColorClass","blockquoteClasses","blockquoteStyles","color","style","border","background","text","v3","figureStyle","attribute","v2","figureClass","_select$getSettings$c","colors","getSettings","colorObject","blockquoteStyle","v1","v0","align"],"sources":["@wordpress/block-library/src/pullquote/deprecated.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport {\n\tgetColorClassName,\n\tgetColorObjectByAttributeValues,\n\tRichText,\n\tstore as blockEditorStore,\n\tuseBlockProps,\n} from '@wordpress/block-editor';\nimport { select } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport { SOLID_COLOR_CLASS } from './shared';\n\nconst blockAttributes = {\n\tvalue: {\n\t\ttype: 'string',\n\t\tsource: 'html',\n\t\tselector: 'blockquote',\n\t\tmultiline: 'p',\n\t},\n\tcitation: {\n\t\ttype: 'string',\n\t\tsource: 'html',\n\t\tselector: 'cite',\n\t\tdefault: '',\n\t},\n\tmainColor: {\n\t\ttype: 'string',\n\t},\n\tcustomMainColor: {\n\t\ttype: 'string',\n\t},\n\ttextColor: {\n\t\ttype: 'string',\n\t},\n\tcustomTextColor: {\n\t\ttype: 'string',\n\t},\n};\n\nfunction parseBorderColor( styleString ) {\n\tif ( ! styleString ) {\n\t\treturn;\n\t}\n\tconst matches = styleString.match( /border-color:([^;]+)[;]?/ );\n\tif ( matches && matches[ 1 ] ) {\n\t\treturn matches[ 1 ];\n\t}\n}\n\nfunction multilineToInline( value ) {\n\tvalue = value || `<p></p>`;\n\tconst padded = `</p>${ value }<p>`;\n\tconst values = padded.split( `</p><p>` );\n\n\tvalues.shift();\n\tvalues.pop();\n\n\treturn values.join( '<br>' );\n}\n\nconst v5 = {\n\tattributes: {\n\t\tvalue: {\n\t\t\ttype: 'string',\n\t\t\tsource: 'html',\n\t\t\tselector: 'blockquote',\n\t\t\tmultiline: 'p',\n\t\t\trole: 'content',\n\t\t},\n\t\tcitation: {\n\t\t\ttype: 'string',\n\t\t\tsource: 'html',\n\t\t\tselector: 'cite',\n\t\t\tdefault: '',\n\t\t\trole: 'content',\n\t\t},\n\t\ttextAlign: {\n\t\t\ttype: 'string',\n\t\t},\n\t},\n\tsave( { attributes } ) {\n\t\tconst { textAlign, citation, value } = attributes;\n\t\tconst shouldShowCitation = ! RichText.isEmpty( citation );\n\n\t\treturn (\n\t\t\t<figure\n\t\t\t\t{ ...useBlockProps.save( {\n\t\t\t\t\tclassName: clsx( {\n\t\t\t\t\t\t[ `has-text-align-${ textAlign }` ]: textAlign,\n\t\t\t\t\t} ),\n\t\t\t\t} ) }\n\t\t\t>\n\t\t\t\t<blockquote>\n\t\t\t\t\t<RichText.Content value={ value } multiline />\n\t\t\t\t\t{ shouldShowCitation && (\n\t\t\t\t\t\t<RichText.Content tagName=\"cite\" value={ citation } />\n\t\t\t\t\t) }\n\t\t\t\t</blockquote>\n\t\t\t</figure>\n\t\t);\n\t},\n\tmigrate( { value, ...attributes } ) {\n\t\treturn {\n\t\t\tvalue: multilineToInline( value ),\n\t\t\t...attributes,\n\t\t};\n\t},\n};\n\n// TODO: this is ripe for a bit of a clean up according to the example in https://developer.wordpress.org/block-editor/reference-guides/block-api/block-deprecation/#example\n\nconst v4 = {\n\tattributes: {\n\t\t...blockAttributes,\n\t},\n\tsave( { attributes } ) {\n\t\tconst {\n\t\t\tmainColor,\n\t\t\tcustomMainColor,\n\t\t\tcustomTextColor,\n\t\t\ttextColor,\n\t\t\tvalue,\n\t\t\tcitation,\n\t\t\tclassName,\n\t\t} = attributes;\n\n\t\tconst isSolidColorStyle = className?.includes( SOLID_COLOR_CLASS );\n\n\t\tlet figureClasses, figureStyles;\n\n\t\t// Is solid color style\n\t\tif ( isSolidColorStyle ) {\n\t\t\tconst backgroundClass = getColorClassName(\n\t\t\t\t'background-color',\n\t\t\t\tmainColor\n\t\t\t);\n\n\t\t\tfigureClasses = clsx( {\n\t\t\t\t'has-background': backgroundClass || customMainColor,\n\t\t\t\t[ backgroundClass ]: backgroundClass,\n\t\t\t} );\n\n\t\t\tfigureStyles = {\n\t\t\t\tbackgroundColor: backgroundClass ? undefined : customMainColor,\n\t\t\t};\n\t\t\t// Is normal style and a custom color is being used ( we can set a style directly with its value)\n\t\t} else if ( customMainColor ) {\n\t\t\tfigureStyles = {\n\t\t\t\tborderColor: customMainColor,\n\t\t\t};\n\t\t}\n\n\t\tconst blockquoteTextColorClass = getColorClassName(\n\t\t\t'color',\n\t\t\ttextColor\n\t\t);\n\t\tconst blockquoteClasses = clsx( {\n\t\t\t'has-text-color': textColor || customTextColor,\n\t\t\t[ blockquoteTextColorClass ]: blockquoteTextColorClass,\n\t\t} );\n\n\t\tconst blockquoteStyles = blockquoteTextColorClass\n\t\t\t? undefined\n\t\t\t: { color: customTextColor };\n\n\t\treturn (\n\t\t\t<figure\n\t\t\t\t{ ...useBlockProps.save( {\n\t\t\t\t\tclassName: figureClasses,\n\t\t\t\t\tstyle: figureStyles,\n\t\t\t\t} ) }\n\t\t\t>\n\t\t\t\t<blockquote\n\t\t\t\t\tclassName={ blockquoteClasses }\n\t\t\t\t\tstyle={ blockquoteStyles }\n\t\t\t\t>\n\t\t\t\t\t<RichText.Content value={ value } multiline />\n\t\t\t\t\t{ ! RichText.isEmpty( citation ) && (\n\t\t\t\t\t\t<RichText.Content tagName=\"cite\" value={ citation } />\n\t\t\t\t\t) }\n\t\t\t\t</blockquote>\n\t\t\t</figure>\n\t\t);\n\t},\n\tmigrate( {\n\t\tvalue,\n\t\tclassName,\n\t\tmainColor,\n\t\tcustomMainColor,\n\t\tcustomTextColor,\n\t\t...attributes\n\t} ) {\n\t\tconst isSolidColorStyle = className?.includes( SOLID_COLOR_CLASS );\n\t\tlet style;\n\n\t\tif ( customMainColor ) {\n\t\t\tif ( ! isSolidColorStyle ) {\n\t\t\t\t// Block supports: Set style.border.color if a deprecated block has a default style and a `customMainColor` attribute.\n\t\t\t\tstyle = {\n\t\t\t\t\tborder: {\n\t\t\t\t\t\tcolor: customMainColor,\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t} else {\n\t\t\t\t// Block supports: Set style.color.background if a deprecated block has a solid style and a `customMainColor` attribute.\n\t\t\t\tstyle = {\n\t\t\t\t\tcolor: {\n\t\t\t\t\t\tbackground: customMainColor,\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\n\t\t// Block supports: Set style.color.text if a deprecated block has a `customTextColor` attribute.\n\t\tif ( customTextColor && style ) {\n\t\t\tstyle.color = {\n\t\t\t\t...style.color,\n\t\t\t\ttext: customTextColor,\n\t\t\t};\n\t\t}\n\n\t\treturn {\n\t\t\tvalue: multilineToInline( value ),\n\t\t\tclassName,\n\t\t\tbackgroundColor: isSolidColorStyle ? mainColor : undefined,\n\t\t\tborderColor: isSolidColorStyle ? undefined : mainColor,\n\t\t\ttextAlign: isSolidColorStyle ? 'left' : undefined,\n\t\t\tstyle,\n\t\t\t...attributes,\n\t\t};\n\t},\n};\n\nconst v3 = {\n\tattributes: {\n\t\t...blockAttributes,\n\t\t// figureStyle is an attribute that never existed.\n\t\t// We are using it as a way to access the styles previously applied to the figure.\n\t\tfigureStyle: {\n\t\t\tsource: 'attribute',\n\t\t\tselector: 'figure',\n\t\t\tattribute: 'style',\n\t\t},\n\t},\n\tsave( { attributes } ) {\n\t\tconst {\n\t\t\tmainColor,\n\t\t\tcustomMainColor,\n\t\t\ttextColor,\n\t\t\tcustomTextColor,\n\t\t\tvalue,\n\t\t\tcitation,\n\t\t\tclassName,\n\t\t\tfigureStyle,\n\t\t} = attributes;\n\n\t\tconst isSolidColorStyle = className?.includes( SOLID_COLOR_CLASS );\n\n\t\tlet figureClasses, figureStyles;\n\n\t\t// Is solid color style\n\t\tif ( isSolidColorStyle ) {\n\t\t\tconst backgroundClass = getColorClassName(\n\t\t\t\t'background-color',\n\t\t\t\tmainColor\n\t\t\t);\n\n\t\t\tfigureClasses = clsx( {\n\t\t\t\t'has-background': backgroundClass || customMainColor,\n\t\t\t\t[ backgroundClass ]: backgroundClass,\n\t\t\t} );\n\n\t\t\tfigureStyles = {\n\t\t\t\tbackgroundColor: backgroundClass ? undefined : customMainColor,\n\t\t\t};\n\t\t\t// Is normal style and a custom color is being used ( we can set a style directly with its value)\n\t\t} else if ( customMainColor ) {\n\t\t\tfigureStyles = {\n\t\t\t\tborderColor: customMainColor,\n\t\t\t};\n\t\t\t// If normal style and a named color are being used, we need to retrieve the color value to set the style,\n\t\t\t// as there is no expectation that themes create classes that set border colors.\n\t\t} else if ( mainColor ) {\n\t\t\t// Previously here we queried the color settings to know the color value\n\t\t\t// of a named color. This made the save function impure and the block was refactored,\n\t\t\t// because meanwhile a change in the editor made it impossible to query color settings in the save function.\n\t\t\t// Here instead of querying the color settings to know the color value, we retrieve the value\n\t\t\t// directly from the style previously serialized.\n\t\t\tconst borderColor = parseBorderColor( figureStyle );\n\t\t\tfigureStyles = {\n\t\t\t\tborderColor,\n\t\t\t};\n\t\t}\n\n\t\tconst blockquoteTextColorClass = getColorClassName(\n\t\t\t'color',\n\t\t\ttextColor\n\t\t);\n\t\tconst blockquoteClasses =\n\t\t\t( textColor || customTextColor ) &&\n\t\t\tclsx( 'has-text-color', {\n\t\t\t\t[ blockquoteTextColorClass ]: blockquoteTextColorClass,\n\t\t\t} );\n\n\t\tconst blockquoteStyles = blockquoteTextColorClass\n\t\t\t? undefined\n\t\t\t: { color: customTextColor };\n\n\t\treturn (\n\t\t\t<figure className={ figureClasses } style={ figureStyles }>\n\t\t\t\t<blockquote\n\t\t\t\t\tclassName={ blockquoteClasses }\n\t\t\t\t\tstyle={ blockquoteStyles }\n\t\t\t\t>\n\t\t\t\t\t<RichText.Content value={ value } multiline />\n\t\t\t\t\t{ ! RichText.isEmpty( citation ) && (\n\t\t\t\t\t\t<RichText.Content tagName=\"cite\" value={ citation } />\n\t\t\t\t\t) }\n\t\t\t\t</blockquote>\n\t\t\t</figure>\n\t\t);\n\t},\n\tmigrate( {\n\t\tvalue,\n\t\tclassName,\n\t\tfigureStyle,\n\t\tmainColor,\n\t\tcustomMainColor,\n\t\tcustomTextColor,\n\t\t...attributes\n\t} ) {\n\t\tconst isSolidColorStyle = className?.includes( SOLID_COLOR_CLASS );\n\t\tlet style;\n\n\t\tif ( customMainColor ) {\n\t\t\tif ( ! isSolidColorStyle ) {\n\t\t\t\t// Block supports: Set style.border.color if a deprecated block has a default style and a `customMainColor` attribute.\n\t\t\t\tstyle = {\n\t\t\t\t\tborder: {\n\t\t\t\t\t\tcolor: customMainColor,\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t} else {\n\t\t\t\t// Block supports: Set style.color.background if a deprecated block has a solid style and a `customMainColor` attribute.\n\t\t\t\tstyle = {\n\t\t\t\t\tcolor: {\n\t\t\t\t\t\tbackground: customMainColor,\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\n\t\t// Block supports: Set style.color.text if a deprecated block has a `customTextColor` attribute.\n\t\tif ( customTextColor && style ) {\n\t\t\tstyle.color = {\n\t\t\t\t...style.color,\n\t\t\t\ttext: customTextColor,\n\t\t\t};\n\t\t}\n\t\t// If is the default style, and a main color is set,\n\t\t// migrate the main color value into a custom border color.\n\t\t// The custom border color value is retrieved by parsing the figure styles.\n\t\tif ( ! isSolidColorStyle && mainColor && figureStyle ) {\n\t\t\tconst borderColor = parseBorderColor( figureStyle );\n\t\t\tif ( borderColor ) {\n\t\t\t\treturn {\n\t\t\t\t\tvalue: multilineToInline( value ),\n\t\t\t\t\t...attributes,\n\t\t\t\t\tclassName,\n\t\t\t\t\t// Block supports: Set style.border.color if a deprecated block has `mainColor`, inline border CSS and is not a solid color style.\n\t\t\t\t\tstyle: {\n\t\t\t\t\t\tborder: {\n\t\t\t\t\t\t\tcolor: borderColor,\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\t\treturn {\n\t\t\tvalue: multilineToInline( value ),\n\t\t\tclassName,\n\t\t\tbackgroundColor: isSolidColorStyle ? mainColor : undefined,\n\t\t\tborderColor: isSolidColorStyle ? undefined : mainColor,\n\t\t\ttextAlign: isSolidColorStyle ? 'left' : undefined,\n\t\t\tstyle,\n\t\t\t...attributes,\n\t\t};\n\t},\n};\n\nconst v2 = {\n\tattributes: blockAttributes,\n\tsave( { attributes } ) {\n\t\tconst {\n\t\t\tmainColor,\n\t\t\tcustomMainColor,\n\t\t\ttextColor,\n\t\t\tcustomTextColor,\n\t\t\tvalue,\n\t\t\tcitation,\n\t\t\tclassName,\n\t\t} = attributes;\n\t\tconst isSolidColorStyle = className?.includes( SOLID_COLOR_CLASS );\n\n\t\tlet figureClass, figureStyles;\n\t\t// Is solid color style\n\t\tif ( isSolidColorStyle ) {\n\t\t\tfigureClass = getColorClassName( 'background-color', mainColor );\n\t\t\tif ( ! figureClass ) {\n\t\t\t\tfigureStyles = {\n\t\t\t\t\tbackgroundColor: customMainColor,\n\t\t\t\t};\n\t\t\t}\n\t\t\t// Is normal style and a custom color is being used ( we can set a style directly with its value)\n\t\t} else if ( customMainColor ) {\n\t\t\tfigureStyles = {\n\t\t\t\tborderColor: customMainColor,\n\t\t\t};\n\t\t\t// Is normal style and a named color is being used, we need to retrieve the color value to set the style,\n\t\t\t// as there is no expectation that themes create classes that set border colors.\n\t\t} else if ( mainColor ) {\n\t\t\tconst colors =\n\t\t\t\tselect( blockEditorStore ).getSettings().colors ?? [];\n\t\t\tconst colorObject = getColorObjectByAttributeValues(\n\t\t\t\tcolors,\n\t\t\t\tmainColor\n\t\t\t);\n\t\t\tfigureStyles = {\n\t\t\t\tborderColor: colorObject.color,\n\t\t\t};\n\t\t}\n\n\t\tconst blockquoteTextColorClass = getColorClassName(\n\t\t\t'color',\n\t\t\ttextColor\n\t\t);\n\t\tconst blockquoteClasses =\n\t\t\ttextColor || customTextColor\n\t\t\t\t? clsx( 'has-text-color', {\n\t\t\t\t\t\t[ blockquoteTextColorClass ]: blockquoteTextColorClass,\n\t\t\t\t } )\n\t\t\t\t: undefined;\n\t\tconst blockquoteStyle = blockquoteTextColorClass\n\t\t\t? undefined\n\t\t\t: { color: customTextColor };\n\t\treturn (\n\t\t\t<figure className={ figureClass } style={ figureStyles }>\n\t\t\t\t<blockquote\n\t\t\t\t\tclassName={ blockquoteClasses }\n\t\t\t\t\tstyle={ blockquoteStyle }\n\t\t\t\t>\n\t\t\t\t\t<RichText.Content value={ value } multiline />\n\t\t\t\t\t{ ! RichText.isEmpty( citation ) && (\n\t\t\t\t\t\t<RichText.Content tagName=\"cite\" value={ citation } />\n\t\t\t\t\t) }\n\t\t\t\t</blockquote>\n\t\t\t</figure>\n\t\t);\n\t},\n\tmigrate( {\n\t\tvalue,\n\t\tclassName,\n\t\tmainColor,\n\t\tcustomMainColor,\n\t\tcustomTextColor,\n\t\t...attributes\n\t} ) {\n\t\tconst isSolidColorStyle = className?.includes( SOLID_COLOR_CLASS );\n\t\tlet style = {};\n\n\t\tif ( customMainColor ) {\n\t\t\tif ( ! isSolidColorStyle ) {\n\t\t\t\t// Block supports: Set style.border.color if a deprecated block has a default style and a `customMainColor` attribute.\n\t\t\t\tstyle = {\n\t\t\t\t\tborder: {\n\t\t\t\t\t\tcolor: customMainColor,\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t} else {\n\t\t\t\t// Block supports: Set style.color.background if a deprecated block has a solid style and a `customMainColor` attribute.\n\t\t\t\tstyle = {\n\t\t\t\t\tcolor: {\n\t\t\t\t\t\tbackground: customMainColor,\n\t\t\t\t\t},\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\n\t\t// Block supports: Set style.color.text if a deprecated block has a `customTextColor` attribute.\n\t\tif ( customTextColor && style ) {\n\t\t\tstyle.color = {\n\t\t\t\t...style.color,\n\t\t\t\ttext: customTextColor,\n\t\t\t};\n\t\t}\n\n\t\treturn {\n\t\t\tvalue: multilineToInline( value ),\n\t\t\tclassName,\n\t\t\tbackgroundColor: isSolidColorStyle ? mainColor : undefined,\n\t\t\tborderColor: isSolidColorStyle ? undefined : mainColor,\n\t\t\ttextAlign: isSolidColorStyle ? 'left' : undefined,\n\t\t\tstyle,\n\t\t\t...attributes,\n\t\t};\n\t},\n};\n\nconst v1 = {\n\tattributes: {\n\t\t...blockAttributes,\n\t},\n\tsave( { attributes } ) {\n\t\tconst { value, citation } = attributes;\n\t\treturn (\n\t\t\t<blockquote>\n\t\t\t\t<RichText.Content value={ value } multiline />\n\t\t\t\t{ ! RichText.isEmpty( citation ) && (\n\t\t\t\t\t<RichText.Content tagName=\"cite\" value={ citation } />\n\t\t\t\t) }\n\t\t\t</blockquote>\n\t\t);\n\t},\n\tmigrate( { value, ...attributes } ) {\n\t\treturn {\n\t\t\tvalue: multilineToInline( value ),\n\t\t\t...attributes,\n\t\t};\n\t},\n};\n\nconst v0 = {\n\tattributes: {\n\t\t...blockAttributes,\n\t\tcitation: {\n\t\t\ttype: 'string',\n\t\t\tsource: 'html',\n\t\t\tselector: 'footer',\n\t\t},\n\t\talign: {\n\t\t\ttype: 'string',\n\t\t\tdefault: 'none',\n\t\t},\n\t},\n\n\tsave( { attributes } ) {\n\t\tconst { value, citation, align } = attributes;\n\n\t\treturn (\n\t\t\t<blockquote className={ `align${ align }` }>\n\t\t\t\t<RichText.Content value={ value } multiline />\n\t\t\t\t{ ! RichText.isEmpty( citation ) && (\n\t\t\t\t\t<RichText.Content tagName=\"footer\" value={ citation } />\n\t\t\t\t) }\n\t\t\t</blockquote>\n\t\t);\n\t},\n\tmigrate( { value, ...attributes } ) {\n\t\treturn {\n\t\t\tvalue: multilineToInline( value ),\n\t\t\t...attributes,\n\t\t};\n\t},\n};\n\n/**\n * New deprecations need to be placed first\n * for them to have higher priority.\n *\n * Old deprecations may need to be updated as well.\n *\n * See block-deprecation.md\n */\nexport default [ v5, v4, v3, v2, v1, v0 ];\n"],"mappings":"AAAA;AACA;AACA;AACA,OAAOA,IAAI,MAAM,MAAM;;AAEvB;AACA;AACA;AACA,SACCC,iBAAiB,EACjBC,+BAA+B,EAC/BC,QAAQ,EACRC,KAAK,IAAIC,gBAAgB,EACzBC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E","ignoreList":[]}
|
|
@@ -16,9 +16,7 @@ import { Platform } from '@wordpress/element';
|
|
|
16
16
|
*/
|
|
17
17
|
import { Figure } from './figure';
|
|
18
18
|
import { BlockQuote } from './blockquote';
|
|
19
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
20
|
-
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
21
|
-
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
19
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
22
20
|
const isWebPlatform = Platform.OS === 'web';
|
|
23
21
|
function PullQuoteEdit({
|
|
24
22
|
attributes,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["clsx","__","AlignmentControl","BlockControls","RichText","useBlockProps","createBlock","getDefaultBlockName","Platform","Figure","BlockQuote","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","isWebPlatform","OS","PullQuoteEdit","attributes","setAttributes","isSelected","insertBlocksAfter","textAlign","citation","value","blockProps","className","shouldShowCitation","isEmpty","children","group","onChange","nextAlign","identifier","tagName","nextValue","placeholder","undefined","style","display","nextCitation","__unstableMobileNoFocusOnMount","__unstableOnSplitAtEnd"],"sources":["@wordpress/block-library/src/pullquote/edit.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport {\n\tAlignmentControl,\n\tBlockControls,\n\tRichText,\n\tuseBlockProps,\n} from '@wordpress/block-editor';\nimport { createBlock, getDefaultBlockName } from '@wordpress/blocks';\nimport { Platform } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport { Figure } from './figure';\nimport { BlockQuote } from './blockquote';\n\nconst isWebPlatform = Platform.OS === 'web';\n\nfunction PullQuoteEdit( {\n\tattributes,\n\tsetAttributes,\n\tisSelected,\n\tinsertBlocksAfter,\n} ) {\n\tconst { textAlign, citation, value } = attributes;\n\tconst blockProps = useBlockProps( {\n\t\tclassName: clsx( {\n\t\t\t[ `has-text-align-${ textAlign }` ]: textAlign,\n\t\t} ),\n\t} );\n\tconst shouldShowCitation = ! RichText.isEmpty( citation ) || isSelected;\n\n\treturn (\n\t\t<>\n\t\t\t<BlockControls group=\"block\">\n\t\t\t\t<AlignmentControl\n\t\t\t\t\tvalue={ textAlign }\n\t\t\t\t\tonChange={ ( nextAlign ) => {\n\t\t\t\t\t\tsetAttributes( { textAlign: nextAlign } );\n\t\t\t\t\t} }\n\t\t\t\t/>\n\t\t\t</BlockControls>\n\t\t\t<Figure { ...blockProps }>\n\t\t\t\t<BlockQuote>\n\t\t\t\t\t<RichText\n\t\t\t\t\t\tidentifier=\"value\"\n\t\t\t\t\t\ttagName=\"p\"\n\t\t\t\t\t\tvalue={ value }\n\t\t\t\t\t\tonChange={ ( nextValue ) =>\n\t\t\t\t\t\t\tsetAttributes( {\n\t\t\t\t\t\t\t\tvalue: nextValue,\n\t\t\t\t\t\t\t} )\n\t\t\t\t\t\t}\n\t\t\t\t\t\taria-label={ __( 'Pullquote text' ) }\n\t\t\t\t\t\tplaceholder={\n\t\t\t\t\t\t\t// translators: placeholder text used for the quote\n\t\t\t\t\t\t\t__( 'Add quote' )\n\t\t\t\t\t\t}\n\t\t\t\t\t\ttextAlign=\"center\"\n\t\t\t\t\t/>\n\t\t\t\t\t{ shouldShowCitation && (\n\t\t\t\t\t\t<RichText\n\t\t\t\t\t\t\tidentifier=\"citation\"\n\t\t\t\t\t\t\ttagName={ isWebPlatform ? 'cite' : undefined }\n\t\t\t\t\t\t\tstyle={ { display: 'block' } }\n\t\t\t\t\t\t\tvalue={ citation }\n\t\t\t\t\t\t\taria-label={ __( 'Pullquote citation text' ) }\n\t\t\t\t\t\t\tplaceholder={\n\t\t\t\t\t\t\t\t// translators: placeholder text used for the citation\n\t\t\t\t\t\t\t\t__( 'Add citation' )\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tonChange={ ( nextCitation ) =>\n\t\t\t\t\t\t\t\tsetAttributes( {\n\t\t\t\t\t\t\t\t\tcitation: nextCitation,\n\t\t\t\t\t\t\t\t} )\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tclassName=\"wp-block-pullquote__citation\"\n\t\t\t\t\t\t\t__unstableMobileNoFocusOnMount\n\t\t\t\t\t\t\ttextAlign=\"center\"\n\t\t\t\t\t\t\t__unstableOnSplitAtEnd={ () =>\n\t\t\t\t\t\t\t\tinsertBlocksAfter(\n\t\t\t\t\t\t\t\t\tcreateBlock( getDefaultBlockName() )\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</BlockQuote>\n\t\t\t</Figure>\n\t\t</>\n\t);\n}\n\nexport default PullQuoteEdit;\n"],"mappings":"AAAA;AACA;AACA;AACA,OAAOA,IAAI,MAAM,MAAM;;AAEvB;AACA;AACA;AACA,SAASC,EAAE,QAAQ,iBAAiB;AACpC,SACCC,gBAAgB,EAChBC,aAAa,EACbC,QAAQ,EACRC,aAAa,QACP,yBAAyB;AAChC,SAASC,WAAW,EAAEC,mBAAmB,QAAQ,mBAAmB;AACpE,SAASC,QAAQ,QAAQ,oBAAoB;;AAE7C;AACA;AACA;AACA,SAASC,MAAM,QAAQ,UAAU;AACjC,SAASC,UAAU,QAAQ,cAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA
|
|
1
|
+
{"version":3,"names":["clsx","__","AlignmentControl","BlockControls","RichText","useBlockProps","createBlock","getDefaultBlockName","Platform","Figure","BlockQuote","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","isWebPlatform","OS","PullQuoteEdit","attributes","setAttributes","isSelected","insertBlocksAfter","textAlign","citation","value","blockProps","className","shouldShowCitation","isEmpty","children","group","onChange","nextAlign","identifier","tagName","nextValue","placeholder","undefined","style","display","nextCitation","__unstableMobileNoFocusOnMount","__unstableOnSplitAtEnd"],"sources":["@wordpress/block-library/src/pullquote/edit.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport {\n\tAlignmentControl,\n\tBlockControls,\n\tRichText,\n\tuseBlockProps,\n} from '@wordpress/block-editor';\nimport { createBlock, getDefaultBlockName } from '@wordpress/blocks';\nimport { Platform } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport { Figure } from './figure';\nimport { BlockQuote } from './blockquote';\n\nconst isWebPlatform = Platform.OS === 'web';\n\nfunction PullQuoteEdit( {\n\tattributes,\n\tsetAttributes,\n\tisSelected,\n\tinsertBlocksAfter,\n} ) {\n\tconst { textAlign, citation, value } = attributes;\n\tconst blockProps = useBlockProps( {\n\t\tclassName: clsx( {\n\t\t\t[ `has-text-align-${ textAlign }` ]: textAlign,\n\t\t} ),\n\t} );\n\tconst shouldShowCitation = ! RichText.isEmpty( citation ) || isSelected;\n\n\treturn (\n\t\t<>\n\t\t\t<BlockControls group=\"block\">\n\t\t\t\t<AlignmentControl\n\t\t\t\t\tvalue={ textAlign }\n\t\t\t\t\tonChange={ ( nextAlign ) => {\n\t\t\t\t\t\tsetAttributes( { textAlign: nextAlign } );\n\t\t\t\t\t} }\n\t\t\t\t/>\n\t\t\t</BlockControls>\n\t\t\t<Figure { ...blockProps }>\n\t\t\t\t<BlockQuote>\n\t\t\t\t\t<RichText\n\t\t\t\t\t\tidentifier=\"value\"\n\t\t\t\t\t\ttagName=\"p\"\n\t\t\t\t\t\tvalue={ value }\n\t\t\t\t\t\tonChange={ ( nextValue ) =>\n\t\t\t\t\t\t\tsetAttributes( {\n\t\t\t\t\t\t\t\tvalue: nextValue,\n\t\t\t\t\t\t\t} )\n\t\t\t\t\t\t}\n\t\t\t\t\t\taria-label={ __( 'Pullquote text' ) }\n\t\t\t\t\t\tplaceholder={\n\t\t\t\t\t\t\t// translators: placeholder text used for the quote\n\t\t\t\t\t\t\t__( 'Add quote' )\n\t\t\t\t\t\t}\n\t\t\t\t\t\ttextAlign=\"center\"\n\t\t\t\t\t/>\n\t\t\t\t\t{ shouldShowCitation && (\n\t\t\t\t\t\t<RichText\n\t\t\t\t\t\t\tidentifier=\"citation\"\n\t\t\t\t\t\t\ttagName={ isWebPlatform ? 'cite' : undefined }\n\t\t\t\t\t\t\tstyle={ { display: 'block' } }\n\t\t\t\t\t\t\tvalue={ citation }\n\t\t\t\t\t\t\taria-label={ __( 'Pullquote citation text' ) }\n\t\t\t\t\t\t\tplaceholder={\n\t\t\t\t\t\t\t\t// translators: placeholder text used for the citation\n\t\t\t\t\t\t\t\t__( 'Add citation' )\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tonChange={ ( nextCitation ) =>\n\t\t\t\t\t\t\t\tsetAttributes( {\n\t\t\t\t\t\t\t\t\tcitation: nextCitation,\n\t\t\t\t\t\t\t\t} )\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tclassName=\"wp-block-pullquote__citation\"\n\t\t\t\t\t\t\t__unstableMobileNoFocusOnMount\n\t\t\t\t\t\t\ttextAlign=\"center\"\n\t\t\t\t\t\t\t__unstableOnSplitAtEnd={ () =>\n\t\t\t\t\t\t\t\tinsertBlocksAfter(\n\t\t\t\t\t\t\t\t\tcreateBlock( getDefaultBlockName() )\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</BlockQuote>\n\t\t\t</Figure>\n\t\t</>\n\t);\n}\n\nexport default PullQuoteEdit;\n"],"mappings":"AAAA;AACA;AACA;AACA,OAAOA,IAAI,MAAM,MAAM;;AAEvB;AACA;AACA;AACA,SAASC,EAAE,QAAQ,iBAAiB;AACpC,SACCC,gBAAgB,EAChBC,aAAa,EACbC,QAAQ,EACRC,aAAa,QACP,yBAAyB;AAChC,SAASC,WAAW,EAAEC,mBAAmB,QAAQ,mBAAmB;AACpE,SAASC,QAAQ,QAAQ,oBAAoB;;AAE7C;AACA;AACA;AACA,S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UACV;UACArC,EAAE,CAAE,WAAY,CAChB;UACDuB,SAAS,EAAC;QAAQ,CAClB,CAAC,EACAK,kBAAkB,iBACnBjB,IAAA,CAACR,QAAQ;UACR+B,UAAU,EAAC,UAAU;UACrBC,OAAO,EAAGnB,aAAa,GAAG,MAAM,GAAGsB,SAAW;UAC9CC,KAAK,EAAG;YAAEC,OAAO,EAAE;UAAQ,CAAG;UAC9Bf,KAAK,EAAGD,QAAU;UAClB,cAAaxB,EAAE,CAAE,yBAA0B,CAAG;UAC9CqC,WAAW;UACV;UACArC,EAAE,CAAE,cAAe,CACnB;UACDgC,QAAQ,EAAKS,YAAY,IACxBrB,aAAa,CAAE;YACdI,QAAQ,EAAEiB;UACX,CAAE,CACF;UACDd,SAAS,EAAC,8BAA8B;UACxCe,8BAA8B;UAC9BnB,SAAS,EAAC,QAAQ;UAClBoB,sBAAsB,EAAGA,CAAA,KACxBrB,iBAAiB,CAChBjB,WAAW,CAAEC,mBAAmB,CAAC,CAAE,CACpC;QACA,CACD,CACD;MAAA,CACU;IAAC,CACN,CAAC;EAAA,CACR,CAAC;AAEL;AAEA,eAAeY,aAAa","ignoreList":[]}
|
|
@@ -10,9 +10,7 @@ import { createBlock, getDefaultBlockName } from '@wordpress/blocks';
|
|
|
10
10
|
*/
|
|
11
11
|
import { Figure } from './figure';
|
|
12
12
|
import { BlockQuote } from './blockquote';
|
|
13
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
14
|
-
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
15
|
-
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
13
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
16
14
|
const getBackgroundColor = ({
|
|
17
15
|
attributes,
|
|
18
16
|
colors,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["__","AlignmentControl","BlockControls","RichText","useBlockProps","getColorObjectByAttributeValues","__experimentalGetColorClassesAndStyles","getColorClassesAndStyles","createBlock","getDefaultBlockName","Figure","BlockQuote","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","getBackgroundColor","attributes","colors","style","backgroundColor","colorProps","colorObject","color","background","getTextColor","textColor","baseColors","text","getBorderColor","props","wrapperProps","defaultColor","borderColor","PullQuoteEdit","setAttributes","isSelected","insertBlocksAfter","textAlign","citation","value","blockProps","shouldShowCitation","isEmpty","children","group","onChange","nextAlign","identifier","nextValue","placeholder","nextCitation","__unstableMobileNoFocusOnMount","__unstableOnSplitAtEnd"],"sources":["@wordpress/block-library/src/pullquote/edit.native.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport {\n\tAlignmentControl,\n\tBlockControls,\n\tRichText,\n\tuseBlockProps,\n\tgetColorObjectByAttributeValues,\n\t__experimentalGetColorClassesAndStyles as getColorClassesAndStyles,\n} from '@wordpress/block-editor';\nimport { createBlock, getDefaultBlockName } from '@wordpress/blocks';\n\n/**\n * Internal dependencies\n */\nimport { Figure } from './figure';\nimport { BlockQuote } from './blockquote';\n\nconst getBackgroundColor = ( { attributes, colors, style } ) => {\n\tconst { backgroundColor } = attributes;\n\n\tconst colorProps = getColorClassesAndStyles( attributes );\n\tconst colorObject = getColorObjectByAttributeValues(\n\t\tcolors,\n\t\tbackgroundColor\n\t);\n\n\treturn (\n\t\tcolorObject?.color ||\n\t\tcolorProps.style?.backgroundColor ||\n\t\tcolorProps.style?.background ||\n\t\tstyle?.backgroundColor\n\t);\n};\n\nconst getTextColor = ( { attributes, colors, style } ) => {\n\tconst colorProps = getColorClassesAndStyles( attributes );\n\tconst colorObject = getColorObjectByAttributeValues(\n\t\tcolors,\n\t\tattributes.textColor\n\t);\n\treturn (\n\t\tcolorObject?.color ||\n\t\tcolorProps.style?.color ||\n\t\tstyle?.color ||\n\t\tstyle?.baseColors?.color?.text\n\t);\n};\nconst getBorderColor = ( props ) => {\n\tconst { wrapperProps } = props;\n\tconst defaultColor = getTextColor( props );\n\n\treturn wrapperProps?.style?.borderColor || defaultColor;\n};\n/**\n * Internal dependencies\n */\n\nfunction PullQuoteEdit( props ) {\n\tconst { attributes, setAttributes, isSelected, insertBlocksAfter } = props;\n\tconst { textAlign, citation, value } = attributes;\n\n\tconst blockProps = useBlockProps( {\n\t\tbackgroundColor: getBackgroundColor( props ),\n\t\tborderColor: getBorderColor( props ),\n\t} );\n\n\tconst shouldShowCitation = ! RichText.isEmpty( citation ) || isSelected;\n\n\treturn (\n\t\t<>\n\t\t\t<BlockControls group=\"block\">\n\t\t\t\t<AlignmentControl\n\t\t\t\t\tvalue={ textAlign }\n\t\t\t\t\tonChange={ ( nextAlign ) => {\n\t\t\t\t\t\tsetAttributes( { textAlign: nextAlign } );\n\t\t\t\t\t} }\n\t\t\t\t/>\n\t\t\t</BlockControls>\n\t\t\t<Figure { ...blockProps }>\n\t\t\t\t<BlockQuote textColor={ getTextColor( props ) }>\n\t\t\t\t\t<RichText\n\t\t\t\t\t\tidentifier=\"value\"\n\t\t\t\t\t\tvalue={ value }\n\t\t\t\t\t\tonChange={ ( nextValue ) =>\n\t\t\t\t\t\t\tsetAttributes( {\n\t\t\t\t\t\t\t\tvalue: nextValue,\n\t\t\t\t\t\t\t} )\n\t\t\t\t\t\t}\n\t\t\t\t\t\taria-label={ __( 'Pullquote text' ) }\n\t\t\t\t\t\tplaceholder={\n\t\t\t\t\t\t\t// translators: placeholder text used for the quote\n\t\t\t\t\t\t\t__( 'Add quote' )\n\t\t\t\t\t\t}\n\t\t\t\t\t\ttextAlign={ textAlign ?? 'center' }\n\t\t\t\t\t/>\n\t\t\t\t\t{ shouldShowCitation && (\n\t\t\t\t\t\t<RichText\n\t\t\t\t\t\t\tidentifier=\"citation\"\n\t\t\t\t\t\t\tvalue={ citation }\n\t\t\t\t\t\t\taria-label={ __( 'Pullquote citation text' ) }\n\t\t\t\t\t\t\tplaceholder={\n\t\t\t\t\t\t\t\t// translators: placeholder text used for the citation\n\t\t\t\t\t\t\t\t__( 'Add citation' )\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tonChange={ ( nextCitation ) =>\n\t\t\t\t\t\t\t\tsetAttributes( {\n\t\t\t\t\t\t\t\t\tcitation: nextCitation,\n\t\t\t\t\t\t\t\t} )\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t__unstableMobileNoFocusOnMount\n\t\t\t\t\t\t\ttextAlign={ textAlign ?? 'center' }\n\t\t\t\t\t\t\t__unstableOnSplitAtEnd={ () =>\n\t\t\t\t\t\t\t\tinsertBlocksAfter(\n\t\t\t\t\t\t\t\t\tcreateBlock( getDefaultBlockName() )\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</BlockQuote>\n\t\t\t</Figure>\n\t\t</>\n\t);\n}\n\nexport default PullQuoteEdit;\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,EAAE,QAAQ,iBAAiB;AACpC,SACCC,gBAAgB,EAChBC,aAAa,EACbC,QAAQ,EACRC,aAAa,EACbC,+BAA+B,EAC/BC,sCAAsC,IAAIC,wBAAwB,QAC5D,yBAAyB;AAChC,SAASC,WAAW,EAAEC,mBAAmB,QAAQ,mBAAmB;;AAEpE;AACA;AACA;AACA,SAASC,MAAM,QAAQ,UAAU;AACjC,SAASC,UAAU,QAAQ,cAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA
|
|
1
|
+
{"version":3,"names":["__","AlignmentControl","BlockControls","RichText","useBlockProps","getColorObjectByAttributeValues","__experimentalGetColorClassesAndStyles","getColorClassesAndStyles","createBlock","getDefaultBlockName","Figure","BlockQuote","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","getBackgroundColor","attributes","colors","style","backgroundColor","colorProps","colorObject","color","background","getTextColor","textColor","baseColors","text","getBorderColor","props","wrapperProps","defaultColor","borderColor","PullQuoteEdit","setAttributes","isSelected","insertBlocksAfter","textAlign","citation","value","blockProps","shouldShowCitation","isEmpty","children","group","onChange","nextAlign","identifier","nextValue","placeholder","nextCitation","__unstableMobileNoFocusOnMount","__unstableOnSplitAtEnd"],"sources":["@wordpress/block-library/src/pullquote/edit.native.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport {\n\tAlignmentControl,\n\tBlockControls,\n\tRichText,\n\tuseBlockProps,\n\tgetColorObjectByAttributeValues,\n\t__experimentalGetColorClassesAndStyles as getColorClassesAndStyles,\n} from '@wordpress/block-editor';\nimport { createBlock, getDefaultBlockName } from '@wordpress/blocks';\n\n/**\n * Internal dependencies\n */\nimport { Figure } from './figure';\nimport { BlockQuote } from './blockquote';\n\nconst getBackgroundColor = ( { attributes, colors, style } ) => {\n\tconst { backgroundColor } = attributes;\n\n\tconst colorProps = getColorClassesAndStyles( attributes );\n\tconst colorObject = getColorObjectByAttributeValues(\n\t\tcolors,\n\t\tbackgroundColor\n\t);\n\n\treturn (\n\t\tcolorObject?.color ||\n\t\tcolorProps.style?.backgroundColor ||\n\t\tcolorProps.style?.background ||\n\t\tstyle?.backgroundColor\n\t);\n};\n\nconst getTextColor = ( { attributes, colors, style } ) => {\n\tconst colorProps = getColorClassesAndStyles( attributes );\n\tconst colorObject = getColorObjectByAttributeValues(\n\t\tcolors,\n\t\tattributes.textColor\n\t);\n\treturn (\n\t\tcolorObject?.color ||\n\t\tcolorProps.style?.color ||\n\t\tstyle?.color ||\n\t\tstyle?.baseColors?.color?.text\n\t);\n};\nconst getBorderColor = ( props ) => {\n\tconst { wrapperProps } = props;\n\tconst defaultColor = getTextColor( props );\n\n\treturn wrapperProps?.style?.borderColor || defaultColor;\n};\n/**\n * Internal dependencies\n */\n\nfunction PullQuoteEdit( props ) {\n\tconst { attributes, setAttributes, isSelected, insertBlocksAfter } = props;\n\tconst { textAlign, citation, value } = attributes;\n\n\tconst blockProps = useBlockProps( {\n\t\tbackgroundColor: getBackgroundColor( props ),\n\t\tborderColor: getBorderColor( props ),\n\t} );\n\n\tconst shouldShowCitation = ! RichText.isEmpty( citation ) || isSelected;\n\n\treturn (\n\t\t<>\n\t\t\t<BlockControls group=\"block\">\n\t\t\t\t<AlignmentControl\n\t\t\t\t\tvalue={ textAlign }\n\t\t\t\t\tonChange={ ( nextAlign ) => {\n\t\t\t\t\t\tsetAttributes( { textAlign: nextAlign } );\n\t\t\t\t\t} }\n\t\t\t\t/>\n\t\t\t</BlockControls>\n\t\t\t<Figure { ...blockProps }>\n\t\t\t\t<BlockQuote textColor={ getTextColor( props ) }>\n\t\t\t\t\t<RichText\n\t\t\t\t\t\tidentifier=\"value\"\n\t\t\t\t\t\tvalue={ value }\n\t\t\t\t\t\tonChange={ ( nextValue ) =>\n\t\t\t\t\t\t\tsetAttributes( {\n\t\t\t\t\t\t\t\tvalue: nextValue,\n\t\t\t\t\t\t\t} )\n\t\t\t\t\t\t}\n\t\t\t\t\t\taria-label={ __( 'Pullquote text' ) }\n\t\t\t\t\t\tplaceholder={\n\t\t\t\t\t\t\t// translators: placeholder text used for the quote\n\t\t\t\t\t\t\t__( 'Add quote' )\n\t\t\t\t\t\t}\n\t\t\t\t\t\ttextAlign={ textAlign ?? 'center' }\n\t\t\t\t\t/>\n\t\t\t\t\t{ shouldShowCitation && (\n\t\t\t\t\t\t<RichText\n\t\t\t\t\t\t\tidentifier=\"citation\"\n\t\t\t\t\t\t\tvalue={ citation }\n\t\t\t\t\t\t\taria-label={ __( 'Pullquote citation text' ) }\n\t\t\t\t\t\t\tplaceholder={\n\t\t\t\t\t\t\t\t// translators: placeholder text used for the citation\n\t\t\t\t\t\t\t\t__( 'Add citation' )\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tonChange={ ( nextCitation ) =>\n\t\t\t\t\t\t\t\tsetAttributes( {\n\t\t\t\t\t\t\t\t\tcitation: nextCitation,\n\t\t\t\t\t\t\t\t} )\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t__unstableMobileNoFocusOnMount\n\t\t\t\t\t\t\ttextAlign={ textAlign ?? 'center' }\n\t\t\t\t\t\t\t__unstableOnSplitAtEnd={ () =>\n\t\t\t\t\t\t\t\tinsertBlocksAfter(\n\t\t\t\t\t\t\t\t\tcreateBlock( getDefaultBlockName() )\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</BlockQuote>\n\t\t\t</Figure>\n\t\t</>\n\t);\n}\n\nexport default PullQuoteEdit;\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,EAAE,QAAQ,iBAAiB;AACpC,SACCC,gBAAgB,EAChBC,aAAa,EACbC,QAAQ,EACRC,aAAa,EACbC,+BAA+B,EAC/BC,sCAAsC,IAAIC,wBAAwB,QAC5D,yBAAyB;AAChC,SAASC,WAAW,EAAEC,mBAAmB,QAAQ,mBAAmB;;AAEpE;AACA;AACA;AACA,SAASC,MAAM,QAAQ,UAAU;AACjC,SAASC,UAAU,QAAQ,cAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA,EAAAC,QAAA,IAAAC,SAAA;AAE1C,MAAMC,kBAAkB,GAAGA,CAAE;EAAEC,UAAU;EAAEC,MAAM;EAAEC;AAAM,CAAC,KAAM;EAC/D,MAAM;IAAEC;EAAgB,CAAC,GAAGH,UAAU;EAEtC,MAAMI,UAAU,GAAGhB,wBAAwB,CAAEY,UAAW,CAAC;EACzD,MAAMK,WAAW,GAAGnB,+BAA+B,CAClDe,MAAM,EACNE,eACD,CAAC;EAED,OACCE,WAAW,EAAEC,KAAK,IAClBF,UAAU,CAACF,KAAK,EAAEC,eAAe,IACjCC,UAAU,CAACF,KAAK,EAAEK,UAAU,IAC5BL,KAAK,EAAEC,eAAe;AAExB,CAAC;AAED,MAAMK,YAAY,GAAGA,CAAE;EAAER,UAAU;EAAEC,MAAM;EAAEC;AAAM,CAAC,KAAM;EACzD,MAAME,UAAU,GAAGhB,wBAAwB,CAAEY,UAAW,CAAC;EACzD,MA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;MAAA,GAAMiC,UAAU;MAAAG,QAAA,eACtB/B,KAAA,CAACJ,UAAU;QAACiB,SAAS,EAAGD,YAAY,CAAEK,KAAM,CAAG;QAAAc,QAAA,gBAC9CjC,IAAA,CAACV,QAAQ;UACR+C,UAAU,EAAC,OAAO;UAClBR,KAAK,EAAGA,KAAO;UACfM,QAAQ,EAAKG,SAAS,IACrBd,aAAa,CAAE;YACdK,KAAK,EAAES;UACR,CAAE,CACF;UACD,cAAanD,EAAE,CAAE,gBAAiB,CAAG;UACrCoD,WAAW;UACV;UACApD,EAAE,CAAE,WAAY,CAChB;UACDwC,SAAS,EAAGA,SAAS,aAATA,SAAS,cAATA,SAAS,GAAI;QAAU,CACnC,CAAC,EACAI,kBAAkB,iBACnB/B,IAAA,CAACV,QAAQ;UACR+C,UAAU,EAAC,UAAU;UACrBR,KAAK,EAAGD,QAAU;UAClB,cAAazC,EAAE,CAAE,yBAA0B,CAAG;UAC9CoD,WAAW;UACV;UACApD,EAAE,CAAE,cAAe,CACnB;UACDgD,QAAQ,EAAKK,YAAY,IACxBhB,aAAa,CAAE;YACdI,QAAQ,EAAEY;UACX,CAAE,CACF;UACDC,8BAA8B;UAC9Bd,SAAS,EAAGA,SAAS,aAATA,SAAS,cAATA,SAAS,GAAI,QAAU;UACnCe,sBAAsB,EAAGA,CAAA,KACxBhB,iBAAiB,CAChB/B,WAAW,CAAEC,mBAAmB,CAAC,CAAE,CACpC;QACA,CACD,CACD;MAAA,CACU;IAAC,CACN,CAAC;EAAA,CACR,CAAC;AAEL;AAEA,eAAe2B,aAAa","ignoreList":[]}
|
|
@@ -7,8 +7,7 @@ import clsx from 'clsx';
|
|
|
7
7
|
* WordPress dependencies
|
|
8
8
|
*/
|
|
9
9
|
import { RichText, useBlockProps } from '@wordpress/block-editor';
|
|
10
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
11
|
-
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
10
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
12
11
|
export default function save({
|
|
13
12
|
attributes
|
|
14
13
|
}) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["clsx","RichText","useBlockProps","jsx","_jsx","jsxs","_jsxs","save","attributes","textAlign","citation","value","shouldShowCitation","isEmpty","className","children","Content","tagName"],"sources":["@wordpress/block-library/src/pullquote/save.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport { RichText, useBlockProps } from '@wordpress/block-editor';\n\nexport default function save( { attributes } ) {\n\tconst { textAlign, citation, value } = attributes;\n\tconst shouldShowCitation = ! RichText.isEmpty( citation );\n\n\treturn (\n\t\t<figure\n\t\t\t{ ...useBlockProps.save( {\n\t\t\t\tclassName: clsx( {\n\t\t\t\t\t[ `has-text-align-${ textAlign }` ]: textAlign,\n\t\t\t\t} ),\n\t\t\t} ) }\n\t\t>\n\t\t\t<blockquote>\n\t\t\t\t<RichText.Content tagName=\"p\" value={ value } />\n\t\t\t\t{ shouldShowCitation && (\n\t\t\t\t\t<RichText.Content tagName=\"cite\" value={ citation } />\n\t\t\t\t) }\n\t\t\t</blockquote>\n\t\t</figure>\n\t);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,OAAOA,IAAI,MAAM,MAAM;;AAEvB;AACA;AACA;AACA,SAASC,QAAQ,EAAEC,aAAa,QAAQ,yBAAyB;AAAC,SAAAC,GAAA,IAAAC,IAAA
|
|
1
|
+
{"version":3,"names":["clsx","RichText","useBlockProps","jsx","_jsx","jsxs","_jsxs","save","attributes","textAlign","citation","value","shouldShowCitation","isEmpty","className","children","Content","tagName"],"sources":["@wordpress/block-library/src/pullquote/save.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport { RichText, useBlockProps } from '@wordpress/block-editor';\n\nexport default function save( { attributes } ) {\n\tconst { textAlign, citation, value } = attributes;\n\tconst shouldShowCitation = ! RichText.isEmpty( citation );\n\n\treturn (\n\t\t<figure\n\t\t\t{ ...useBlockProps.save( {\n\t\t\t\tclassName: clsx( {\n\t\t\t\t\t[ `has-text-align-${ textAlign }` ]: textAlign,\n\t\t\t\t} ),\n\t\t\t} ) }\n\t\t>\n\t\t\t<blockquote>\n\t\t\t\t<RichText.Content tagName=\"p\" value={ value } />\n\t\t\t\t{ shouldShowCitation && (\n\t\t\t\t\t<RichText.Content tagName=\"cite\" value={ citation } />\n\t\t\t\t) }\n\t\t\t</blockquote>\n\t\t</figure>\n\t);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,OAAOA,IAAI,MAAM,MAAM;;AAEvB;AACA;AACA;AACA,SAASC,QAAQ,EAAEC,aAAa,QAAQ,yBAAyB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAElE,eAAe,SAASC,IAAIA,CAAE;EAAEC;AAAW,CAAC,EAAG;EAC9C,MAAM;IAAEC,SAAS;IAAEC,QAAQ;IAAEC;EAAM,CAAC,GAAGH,UAAU;EACjD,MAAMI,kBAAkB,GAAG,CAAEX,QAAQ,CAACY,OAAO,CAAEH,QAAS,CAAC;EAEzD,oBACCN,IAAA;IAAA,GACMF,aAAa,CAACK,IAAI,CAAE;MACxBO,SAAS,EAAEd,IAAI,CAAE;QAChB,CAAE,kBAAmBS,SAAS,EAAG,GAAIA;MACtC,CAAE;IACH,CAAE,CAAC;IAAAM,QAAA,eAEHT,KAAA;MAAAS,QAAA,gBACCX,IAAA,CAACH,QAAQ,CAACe,OAAO;QAACC,OAAO,EAAC,GAAG;QAACN,KAAK,EAAGA;MAAO,CAAE,CAAC,EAC9CC,kBAAkB,iBACnBR,IAAA,CAACH,QAAQ,CAACe,OAAO;QAACC,OAAO,EAAC,MAAM;QAACN,KAAK,EAAGD;MAAU,CAAE,CACrD;IAAA,CACU;EAAC,CACN,CAAC;AAEX","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["SOLID_COLOR_CLASS"],"sources":["@wordpress/block-library/src/pullquote/shared.js"],"sourcesContent":["export const SOLID_COLOR_CLASS = `is-style-solid-color`;\n"],"mappings":"AAAA,OAAO,MAAMA,iBAAiB,
|
|
1
|
+
{"version":3,"names":["SOLID_COLOR_CLASS"],"sources":["@wordpress/block-library/src/pullquote/shared.js"],"sourcesContent":["export const SOLID_COLOR_CLASS = `is-style-solid-color`;\n"],"mappings":"AAAA,OAAO,MAAMA,iBAAiB,GAAG,sBAAsB","ignoreList":[]}
|
|
@@ -9,8 +9,7 @@ import { useState, useEffect } from '@wordpress/element';
|
|
|
9
9
|
* Internal dependencies
|
|
10
10
|
*/
|
|
11
11
|
import { useUnsupportedBlocks } from '../utils';
|
|
12
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
|
-
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
12
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
14
13
|
const modalDescriptionId = 'wp-block-query-enhanced-pagination-modal__description';
|
|
15
14
|
export default function EnhancedPaginationModal({
|
|
16
15
|
clientId,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["Button","Modal","__experimentalVStack","VStack","__","useState","useEffect","useUnsupportedBlocks","jsx","_jsx","jsxs","_jsxs","modalDescriptionId","EnhancedPaginationModal","clientId","attributes","enhancedPagination","setAttributes","isOpen","setOpen","hasBlocksFromPlugins","hasPostContentBlock","hasUnsupportedBlocks","window","__experimentalFullPageClientSideNavigation","closeModal","notice","title","className","aria","describedby","role","focusOnMount","isDismissible","onRequestClose","children","alignment","spacing","id","__next40pxDefaultSize","variant","onClick"],"sources":["@wordpress/block-library/src/query/edit/enhanced-pagination-modal.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport {\n\tButton,\n\tModal,\n\t__experimentalVStack as VStack,\n} from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { useState, useEffect } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport { useUnsupportedBlocks } from '../utils';\n\nconst modalDescriptionId =\n\t'wp-block-query-enhanced-pagination-modal__description';\n\nexport default function EnhancedPaginationModal( {\n\tclientId,\n\tattributes: { enhancedPagination },\n\tsetAttributes,\n} ) {\n\tconst [ isOpen, setOpen ] = useState( false );\n\tconst { hasBlocksFromPlugins, hasPostContentBlock, hasUnsupportedBlocks } =\n\t\tuseUnsupportedBlocks( clientId );\n\n\tuseEffect( () => {\n\t\tif (\n\t\t\tenhancedPagination &&\n\t\t\thasUnsupportedBlocks &&\n\t\t\t! window.__experimentalFullPageClientSideNavigation\n\t\t) {\n\t\t\tsetAttributes( { enhancedPagination: false } );\n\t\t\tsetOpen( true );\n\t\t}\n\t}, [ enhancedPagination, hasUnsupportedBlocks, setAttributes ] );\n\n\tconst closeModal = () => {\n\t\tsetOpen( false );\n\t};\n\n\tlet notice = __(\n\t\t'If you still want to prevent full page reloads, remove that block, then disable \"Reload full page\" again in the Query Block settings.'\n\t);\n\tif ( hasBlocksFromPlugins ) {\n\t\tnotice =\n\t\t\t__(\n\t\t\t\t'Currently, avoiding full page reloads is not possible when non-interactive or non-client Navigation compatible blocks from plugins are present inside the Query block.'\n\t\t\t) +\n\t\t\t' ' +\n\t\t\tnotice;\n\t} else if ( hasPostContentBlock ) {\n\t\tnotice =\n\t\t\t__(\n\t\t\t\t'Currently, avoiding full page reloads is not possible when a Content block is present inside the Query block.'\n\t\t\t) +\n\t\t\t' ' +\n\t\t\tnotice;\n\t}\n\n\treturn (\n\t\tisOpen && (\n\t\t\t<Modal\n\t\t\t\ttitle={ __( 'Query block: Reload full page enabled' ) }\n\t\t\t\tclassName=\"wp-block-query__enhanced-pagination-modal\"\n\t\t\t\taria={ {\n\t\t\t\t\tdescribedby: modalDescriptionId,\n\t\t\t\t} }\n\t\t\t\trole=\"alertdialog\"\n\t\t\t\tfocusOnMount=\"firstElement\"\n\t\t\t\tisDismissible={ false }\n\t\t\t\tonRequestClose={ closeModal }\n\t\t\t>\n\t\t\t\t<VStack alignment=\"right\" spacing={ 5 }>\n\t\t\t\t\t<span id={ modalDescriptionId }>{ notice }</span>\n\t\t\t\t\t<Button\n\t\t\t\t\t\t__next40pxDefaultSize\n\t\t\t\t\t\tvariant=\"primary\"\n\t\t\t\t\t\tonClick={ closeModal }\n\t\t\t\t\t>\n\t\t\t\t\t\t{ __( 'OK' ) }\n\t\t\t\t\t</Button>\n\t\t\t\t</VStack>\n\t\t\t</Modal>\n\t\t)\n\t);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,SACCA,MAAM,EACNC,KAAK,EACLC,oBAAoB,IAAIC,MAAM,QACxB,uBAAuB;AAC9B,SAASC,EAAE,QAAQ,iBAAiB;AACpC,SAASC,QAAQ,EAAEC,SAAS,QAAQ,oBAAoB;;AAExD;AACA;AACA;AACA,SAASC,oBAAoB,QAAQ,UAAU;AAAC,SAAAC,GAAA,IAAAC,IAAA
|
|
1
|
+
{"version":3,"names":["Button","Modal","__experimentalVStack","VStack","__","useState","useEffect","useUnsupportedBlocks","jsx","_jsx","jsxs","_jsxs","modalDescriptionId","EnhancedPaginationModal","clientId","attributes","enhancedPagination","setAttributes","isOpen","setOpen","hasBlocksFromPlugins","hasPostContentBlock","hasUnsupportedBlocks","window","__experimentalFullPageClientSideNavigation","closeModal","notice","title","className","aria","describedby","role","focusOnMount","isDismissible","onRequestClose","children","alignment","spacing","id","__next40pxDefaultSize","variant","onClick"],"sources":["@wordpress/block-library/src/query/edit/enhanced-pagination-modal.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport {\n\tButton,\n\tModal,\n\t__experimentalVStack as VStack,\n} from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { useState, useEffect } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport { useUnsupportedBlocks } from '../utils';\n\nconst modalDescriptionId =\n\t'wp-block-query-enhanced-pagination-modal__description';\n\nexport default function EnhancedPaginationModal( {\n\tclientId,\n\tattributes: { enhancedPagination },\n\tsetAttributes,\n} ) {\n\tconst [ isOpen, setOpen ] = useState( false );\n\tconst { hasBlocksFromPlugins, hasPostContentBlock, hasUnsupportedBlocks } =\n\t\tuseUnsupportedBlocks( clientId );\n\n\tuseEffect( () => {\n\t\tif (\n\t\t\tenhancedPagination &&\n\t\t\thasUnsupportedBlocks &&\n\t\t\t! window.__experimentalFullPageClientSideNavigation\n\t\t) {\n\t\t\tsetAttributes( { enhancedPagination: false } );\n\t\t\tsetOpen( true );\n\t\t}\n\t}, [ enhancedPagination, hasUnsupportedBlocks, setAttributes ] );\n\n\tconst closeModal = () => {\n\t\tsetOpen( false );\n\t};\n\n\tlet notice = __(\n\t\t'If you still want to prevent full page reloads, remove that block, then disable \"Reload full page\" again in the Query Block settings.'\n\t);\n\tif ( hasBlocksFromPlugins ) {\n\t\tnotice =\n\t\t\t__(\n\t\t\t\t'Currently, avoiding full page reloads is not possible when non-interactive or non-client Navigation compatible blocks from plugins are present inside the Query block.'\n\t\t\t) +\n\t\t\t' ' +\n\t\t\tnotice;\n\t} else if ( hasPostContentBlock ) {\n\t\tnotice =\n\t\t\t__(\n\t\t\t\t'Currently, avoiding full page reloads is not possible when a Content block is present inside the Query block.'\n\t\t\t) +\n\t\t\t' ' +\n\t\t\tnotice;\n\t}\n\n\treturn (\n\t\tisOpen && (\n\t\t\t<Modal\n\t\t\t\ttitle={ __( 'Query block: Reload full page enabled' ) }\n\t\t\t\tclassName=\"wp-block-query__enhanced-pagination-modal\"\n\t\t\t\taria={ {\n\t\t\t\t\tdescribedby: modalDescriptionId,\n\t\t\t\t} }\n\t\t\t\trole=\"alertdialog\"\n\t\t\t\tfocusOnMount=\"firstElement\"\n\t\t\t\tisDismissible={ false }\n\t\t\t\tonRequestClose={ closeModal }\n\t\t\t>\n\t\t\t\t<VStack alignment=\"right\" spacing={ 5 }>\n\t\t\t\t\t<span id={ modalDescriptionId }>{ notice }</span>\n\t\t\t\t\t<Button\n\t\t\t\t\t\t__next40p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C3BM,MAAM,GACLtB,EAAE,CACD,wKACD,CAAC,GACD,GAAG,GACHsB,MAAM;EACR,CAAC,MAAM,IAAKL,mBAAmB,EAAG;IACjCK,MAAM,GACLtB,EAAE,CACD,+GACD,CAAC,GACD,GAAG,GACHsB,MAAM;EACR;EAEA,OACCR,MAAM,iBACLT,IAAA,CAACR,KAAK;IACL0B,KAAK,EAAGvB,EAAE,CAAE,uCAAwC,CAAG;IACvDwB,SAAS,EAAC,2CAA2C;IACrDC,IAAI,EAAG;MACNC,WAAW,EAAElB;IACd,CAAG;IACHmB,IAAI,EAAC,aAAa;IAClBC,YAAY,EAAC,cAAc;IAC3BC,aAAa,EAAG,KAAO;IACvBC,cAAc,EAAGT,UAAY;IAAAU,QAAA,eAE7BxB,KAAA,CAACR,MAAM;MAACiC,SAAS,EAAC,OAAO;MAACC,OAAO,EAAG,CAAG;MAAAF,QAAA,gBACtC1B,IAAA;QAAM6B,EAAE,EAAG1B,kBAAoB;QAAAuB,QAAA,EAAGT;MAAM,CAAQ,CAAC,eACjDjB,IAAA,CAACT,MAAM;QACNuC,qBAAqB;QACrBC,OAAO,EAAC,SAAS;QACjBC,OAAO,EAAGhB,UAAY;QAAAU,QAAA,EAEpB/B,EAAE,CAAE,IAAK;MAAC,CACL,CAAC;IAAA,CACF;EAAC,CACH,CACP;AAEH","ignoreList":[]}
|
|
@@ -11,9 +11,7 @@ import { store as blockEditorStore } from '@wordpress/block-editor';
|
|
|
11
11
|
import QueryContent from './query-content';
|
|
12
12
|
import QueryPlaceholder from './query-placeholder';
|
|
13
13
|
import PatternSelectionModal from './pattern-selection-modal';
|
|
14
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
15
|
-
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
16
|
-
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
14
|
+
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
17
15
|
const QueryEdit = props => {
|
|
18
16
|
const {
|
|
19
17
|
clientId,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["useSelect","useState","store","blockEditorStore","QueryContent","QueryPlaceholder","PatternSelectionModal","jsx","_jsx","Fragment","_Fragment","jsxs","_jsxs","QueryEdit","props","clientId","attributes","isPatternSelectionModalOpen","setIsPatternSelectionModalOpen","hasInnerBlocks","select","getBlocks","length","Component","children","openPatternSelectionModal"],"sources":["@wordpress/block-library/src/query/edit/index.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { useSelect } from '@wordpress/data';\nimport { useState } from '@wordpress/element';\nimport { store as blockEditorStore } from '@wordpress/block-editor';\n\n/**\n * Internal dependencies\n */\nimport QueryContent from './query-content';\nimport QueryPlaceholder from './query-placeholder';\nimport PatternSelectionModal from './pattern-selection-modal';\n\nconst QueryEdit = ( props ) => {\n\tconst { clientId, attributes } = props;\n\tconst [ isPatternSelectionModalOpen, setIsPatternSelectionModalOpen ] =\n\t\tuseState( false );\n\tconst hasInnerBlocks = useSelect(\n\t\t( select ) =>\n\t\t\t!! select( blockEditorStore ).getBlocks( clientId ).length,\n\t\t[ clientId ]\n\t);\n\tconst Component = hasInnerBlocks ? QueryContent : QueryPlaceholder;\n\treturn (\n\t\t<>\n\t\t\t<Component\n\t\t\t\t{ ...props }\n\t\t\t\topenPatternSelectionModal={ () =>\n\t\t\t\t\tsetIsPatternSelectionModalOpen( true )\n\t\t\t\t}\n\t\t\t/>\n\t\t\t{ isPatternSelectionModalOpen && (\n\t\t\t\t<PatternSelectionModal\n\t\t\t\t\tclientId={ clientId }\n\t\t\t\t\tattributes={ attributes }\n\t\t\t\t\tsetIsPatternSelectionModalOpen={\n\t\t\t\t\t\tsetIsPatternSelectionModalOpen\n\t\t\t\t\t}\n\t\t\t\t/>\n\t\t\t) }\n\t\t</>\n\t);\n};\n\nexport default QueryEdit;\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,SAAS,QAAQ,iBAAiB;AAC3C,SAASC,QAAQ,QAAQ,oBAAoB;AAC7C,SAASC,KAAK,IAAIC,gBAAgB,QAAQ,yBAAyB;;AAEnE;AACA;AACA;AACA,OAAOC,YAAY,MAAM,iBAAiB;AAC1C,OAAOC,gBAAgB,MAAM,qBAAqB;AAClD,OAAOC,qBAAqB,MAAM,2BAA2B;AAAC,SAAAC,GAAA,IAAAC,IAAA
|
|
1
|
+
{"version":3,"names":["useSelect","useState","store","blockEditorStore","QueryContent","QueryPlaceholder","PatternSelectionModal","jsx","_jsx","Fragment","_Fragment","jsxs","_jsxs","QueryEdit","props","clientId","attributes","isPatternSelectionModalOpen","setIsPatternSelectionModalOpen","hasInnerBlocks","select","getBlocks","length","Component","children","openPatternSelectionModal"],"sources":["@wordpress/block-library/src/query/edit/index.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { useSelect } from '@wordpress/data';\nimport { useState } from '@wordpress/element';\nimport { store as blockEditorStore } from '@wordpress/block-editor';\n\n/**\n * Internal dependencies\n */\nimport QueryContent from './query-content';\nimport QueryPlaceholder from './query-placeholder';\nimport PatternSelectionModal from './pattern-selection-modal';\n\nconst QueryEdit = ( props ) => {\n\tconst { clientId, attributes } = props;\n\tconst [ isPatternSelectionModalOpen, setIsPatternSelectionModalOpen ] =\n\t\tuseState( false );\n\tconst hasInnerBlocks = useSelect(\n\t\t( select ) =>\n\t\t\t!! select( blockEditorStore ).getBlocks( clientId ).length,\n\t\t[ clientId ]\n\t);\n\tconst Component = hasInnerBlocks ? QueryContent : QueryPlaceholder;\n\treturn (\n\t\t<>\n\t\t\t<Component\n\t\t\t\t{ ...props }\n\t\t\t\topenPatternSelectionModal={ () =>\n\t\t\t\t\tsetIsPatternSelectionModalOpen( true )\n\t\t\t\t}\n\t\t\t/>\n\t\t\t{ isPatternSelectionModalOpen && (\n\t\t\t\t<PatternSelectionModal\n\t\t\t\t\tclientId={ clientId }\n\t\t\t\t\tattributes={ attributes }\n\t\t\t\t\tsetIsPatternSelectionModalOpen={\n\t\t\t\t\t\tset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|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["__","FormTokenField","useSelect","store","coreStore","getEntitiesInfo","jsx","_jsx","AUTHORS_QUERY","who","per_page","_fields","context","AuthorControl","value","onChange","authorsList","select","getUsers","authorsInfo","normalizedValue","toString","split","sanitizedValue","reduce","accumulator","authorId","author","mapById","push","id","name","getIdByValue","entitiesMappedByName","authorValue","onAuthorChange","newValue","ids","Array","from","mapByName","add","Set","join","label","suggestions","names","__experimentalShowHowTo","__nextHasNoMarginBottom","__next40pxDefaultSize"],"sources":["@wordpress/block-library/src/query/edit/inspector-controls/author-control.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { FormTokenField } from '@wordpress/components';\nimport { useSelect } from '@wordpress/data';\nimport { store as coreStore } from '@wordpress/core-data';\n\n/**\n * Internal dependencies\n */\nimport { getEntitiesInfo } from '../../utils';\n\nconst AUTHORS_QUERY = {\n\twho: 'authors',\n\tper_page: -1,\n\t_fields: 'id,name',\n\tcontext: 'view',\n};\n\nfunction AuthorControl( { value, onChange } ) {\n\tconst authorsList = useSelect( ( select ) => {\n\t\tconst { getUsers } = select( coreStore );\n\t\treturn getUsers( AUTHORS_QUERY );\n\t}, [] );\n\n\tif ( ! authorsList ) {\n\t\treturn null;\n\t}\n\tconst authorsInfo = getEntitiesInfo( authorsList );\n\t/**\n\t * We need to normalize the value because the block operates on a\n\t * comma(`,`) separated string value and `FormTokenFiels` needs an\n\t * array.\n\t */\n\tconst normalizedValue = ! value ? [] : value.toString().split( ',' );\n\t// Returns only the existing authors ids. This prevents the component\n\t// from crashing in the editor, when non existing ids are provided.\n\tconst sanitizedValue = normalizedValue.reduce(\n\t\t( accumulator, authorId ) => {\n\t\t\tconst author = authorsInfo.mapById[ authorId ];\n\t\t\tif ( author ) {\n\t\t\t\taccumulator.push( {\n\t\t\t\t\tid: authorId,\n\t\t\t\t\tvalue: author.name,\n\t\t\t\t} );\n\t\t\t}\n\t\t\treturn accumulator;\n\t\t},\n\t\t[]\n\t);\n\n\tconst getIdByValue = ( entitiesMappedByName, authorValue ) => {\n\t\tconst id = authorValue?.id || entitiesMappedByName[ authorValue ]?.id;\n\t\tif ( id ) {\n\t\t\treturn id;\n\t\t}\n\t};\n\tconst onAuthorChange = ( newValue ) => {\n\t\tconst ids = Array.from(\n\t\t\tnewValue.reduce( ( accumulator, author ) => {\n\t\t\t\t// Verify that new values point to existing entities.\n\t\t\t\tconst id = getIdByValue( authorsInfo.mapByName, author );\n\t\t\t\tif ( id ) {\n\t\t\t\t\taccumulator.add( id );\n\t\t\t\t}\n\t\t\t\treturn accumulator;\n\t\t\t}, new Set() )\n\t\t);\n\t\tonChange( { author: ids.join( ',' ) } );\n\t};\n\treturn (\n\t\t<FormTokenField\n\t\t\tlabel={ __( 'Authors' ) }\n\t\t\tvalue={ sanitizedValue }\n\t\t\tsuggestions={ authorsInfo.names }\n\t\t\tonChange={ onAuthorChange }\n\t\t\t__experimentalShowHowTo={ false }\n\t\t\t__nextHasNoMarginBottom\n\t\t\t__next40pxDefaultSize\n\t\t/>\n\t);\n}\n\nexport default AuthorControl;\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,EAAE,QAAQ,iBAAiB;AACpC,SAASC,cAAc,QAAQ,uBAAuB;AACtD,SAASC,SAAS,QAAQ,iBAAiB;AAC3C,SAASC,KAAK,IAAIC,SAAS,QAAQ,sBAAsB;;AAEzD;AACA;AACA;AACA,SAASC,eAAe,QAAQ,aAAa;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAE9C,MAAMC,aAAa,GAAG;EACrBC,GAAG,EAAE,SAAS;EACdC,QAAQ,EAAE,CAAC,CAAC;EACZC,OAAO,EAAE,SAAS;EAClBC,OAAO,EAAE;AACV,CAAC;AAED,SAASC,aAAaA,CAAE;EAAEC,KAAK;EAAEC;AAAS,CAAC,EAAG;EAC7C,MAAMC,WAAW,GAAGd,SAAS,CAAIe,MAAM,IAAM;IAC5C,MAAM;MAAEC;I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ACtB;MACA,OAAOL,WAAW;IACnB,CAAC,EAAE,IAAIiB,GAAG,CAAC,CAAE,CACd,CAAC;IACD3B,QAAQ,CAAE;MAAEY,MAAM,EAAEU,GAAG,CAACM,IAAI,CAAE,GAAI;IAAE,CAAE,CAAC;EACxC,CAAC;EACD,oBACCpC,IAAA,CAACN,cAAc;IACd2C,KAAK,EAAG5C,EAAE,CAAE,SAAU,CAAG;IACzBc,KAAK,EAAGS,cAAgB;IACxBsB,WAAW,EAAG1B,WAAW,CAAC2B,KAAO;IACjC/B,QAAQ,EAAGoB,cAAgB;IAC3BY,uBAAuB,EAAG,KAAO;IACjCC,uBAAuB;IACvBC,qBAAqB;EAAA,CACrB,CAAC;AAEJ;AAEA,eAAepC,aAAa","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["__","FormTokenField","useSelect","store","coreStore","getEntitiesInfo","jsx","_jsx","AUTHORS_QUERY","who","per_page","_fields","context","AuthorControl","value","onChange","authorsList","select","getUsers","authorsInfo","normalizedValue","toString","split","sanitizedValue","reduce","accumulator","authorId","author","mapById","push","id","name","getIdByValue","entitiesMappedByName","authorValue","onAuthorChange","newValue","ids","Array","from","mapByName","add","Set","join","label","suggestions","names","__experimentalShowHowTo","__nextHasNoMarginBottom","__next40pxDefaultSize"],"sources":["@wordpress/block-library/src/query/edit/inspector-controls/author-control.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { FormTokenField } from '@wordpress/components';\nimport { useSelect } from '@wordpress/data';\nimport { store as coreStore } from '@wordpress/core-data';\n\n/**\n * Internal dependencies\n */\nimport { getEntitiesInfo } from '../../utils';\n\nconst AUTHORS_QUERY = {\n\twho: 'authors',\n\tper_page: -1,\n\t_fields: 'id,name',\n\tcontext: 'view',\n};\n\nfunction AuthorControl( { value, onChange } ) {\n\tconst authorsList = useSelect( ( select ) => {\n\t\tconst { getUsers } = select( coreStore );\n\t\treturn getUsers( AUTHORS_QUERY );\n\t}, [] );\n\n\tif ( ! authorsList ) {\n\t\treturn null;\n\t}\n\tconst authorsInfo = getEntitiesInfo( authorsList );\n\t/**\n\t * We need to normalize the value because the block operates on a\n\t * comma(`,`) separated string value and `FormTokenFiels` needs an\n\t * array.\n\t */\n\tconst normalizedValue = ! value ? [] : value.toString().split( ',' );\n\t// Returns only the existing authors ids. This prevents the component\n\t// from crashing in the editor, when non existing ids are provided.\n\tconst sanitizedValue = normalizedValue.reduce(\n\t\t( accumulator, authorId ) => {\n\t\t\tconst author = authorsInfo.mapById[ authorId ];\n\t\t\tif ( author ) {\n\t\t\t\taccumulator.push( {\n\t\t\t\t\tid: authorId,\n\t\t\t\t\tvalue: author.name,\n\t\t\t\t} );\n\t\t\t}\n\t\t\treturn accumulator;\n\t\t},\n\t\t[]\n\t);\n\n\tconst getIdByValue = ( entitiesMappedByName, authorValue ) => {\n\t\tconst id = authorValue?.id || entitiesMappedByName[ authorValue ]?.id;\n\t\tif ( id ) {\n\t\t\treturn id;\n\t\t}\n\t};\n\tconst onAuthorChange = ( newValue ) => {\n\t\tconst ids = Array.from(\n\t\t\tnewValue.reduce( ( accumulator, author ) => {\n\t\t\t\t// Verify that new values point to existing entities.\n\t\t\t\tconst id = getIdByValue( authorsInfo.mapByName, author );\n\t\t\t\tif ( id ) {\n\t\t\t\t\taccumulator.add( id );\n\t\t\t\t}\n\t\t\t\treturn accumulator;\n\t\t\t}, new Set() )\n\t\t);\n\t\tonChange( { author: ids.join( ',' ) } );\n\t};\n\treturn (\n\t\t<FormTokenField\n\t\t\tlabel={ __( 'Authors' ) }\n\t\t\tvalue={ sanitizedValue }\n\t\t\tsuggestions={ authorsInfo.names }\n\t\t\tonChange={ onAuthorChange }\n\t\t\t__experimentalShowHowTo={ false }\n\t\t\t__nextHasNoMarginBottom\n\t\t\t__next40pxDefaultSize\n\t\t/>\n\t);\n}\n\nexport default AuthorControl;\n"],"mappings":";AAAA;AACA;AACA;AACA,SAASA,EAAE,QAAQ,iBAAiB;AACpC,SAASC,cA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,MAAMJ,EAAE,GAAGI,WAAW,EAAEJ,EAAE,IAAIG,oBAAoB,CAAEC,WAAW,CAAE,EAAEJ,EAAE;IACrE,IAAKA,EAAE,EAAG;MACT,OAAOA,EAAE;IACV;EACD,CAAC;EACD,MAAMK,cAAc,GAAKC,QAAQ,IAAM;IACtC,MAAMC,GAAG,GAAGC,KAAK,CAACC,IAAI,CACrBH,QAAQ,CAACZ,MAAM,CAAE,CAAEC,WAAW,EAAEE,MAAM,KAAM;MAC3C;MACA,MAAMG,EAAE,GAAGE,YAAY,CAAEb,WAAW,CAACqB,SAAS,EAAEb,MAAO,CAAC;MACxD,IAAKG,EAAE,EAAG;QACTL,WAAW,CAACgB,GAAG,CAAEX,EAAG,CAAC;MACtB;MACA,OAAOL,WAAW;IACnB,CAAC,EAAE,IAAIiB,GAAG,CAAC,CAAE,CACd,CAAC;IACD3B,QAAQ,CAAE;MAAEY,MAAM,EAAEU,GAAG,CAACM,IAAI,CAAE,GAAI;IAAE,CAAE,CAAC;EACxC,CAAC;EACD,oBACCpC,IAAA,CAACN,cAAc;IACd2C,KAAK,EAAG5C,EAAE,CAAE,SAAU,CAAG;IACzBc,KAAK,EAAGS,cAAgB;IACxBsB,WAAW,EAAG1B,WAAW,CAAC2B,KAAO;IACjC/B,QAAQ,EAAGoB,cAAgB;IAC3BY,uBAAuB,EAAG,KAAO;IACjCC,uBAAuB;IACvBC,qBAAqB;EAAA,CACrB,CAAC;AAEJ;AAEA,eAAepC,aAAa","ignoreList":[]}
|
|
@@ -8,8 +8,7 @@ import { __ } from '@wordpress/i18n';
|
|
|
8
8
|
* Internal dependencies
|
|
9
9
|
*/
|
|
10
10
|
import { useUnsupportedBlocks } from '../../utils';
|
|
11
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
12
|
-
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
11
|
+
import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
|
|
13
12
|
export default function EnhancedPaginationControl({
|
|
14
13
|
enhancedPagination,
|
|
15
14
|
setAttributes,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ToggleControl","__","useUnsupportedBlocks","jsx","_jsx","Fragment","_Fragment","EnhancedPaginationControl","enhancedPagination","setAttributes","clientId","hasUnsupportedBlocks","fullPageClientSideNavigation","window","__experimentalFullPageClientSideNavigation","help","children","__nextHasNoMarginBottom","label","checked","disabled","onChange","value"],"sources":["@wordpress/block-library/src/query/edit/inspector-controls/enhanced-pagination-control.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { ToggleControl } from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\n\n/**\n * Internal dependencies\n */\nimport { useUnsupportedBlocks } from '../../utils';\n\nexport default function EnhancedPaginationControl( {\n\tenhancedPagination,\n\tsetAttributes,\n\tclientId,\n} ) {\n\tconst { hasUnsupportedBlocks } = useUnsupportedBlocks( clientId );\n\tconst fullPageClientSideNavigation =\n\t\twindow.__experimentalFullPageClientSideNavigation;\n\n\tlet help = __( 'Browsing between pages requires a full page reload.' );\n\tif ( fullPageClientSideNavigation ) {\n\t\thelp = __(\n\t\t\t'Experimental full-page client-side navigation setting enabled.'\n\t\t);\n\t} else if ( enhancedPagination ) {\n\t\thelp = __(\n\t\t\t'Reload the full page—instead of just the posts list—when visitors navigate between pages.'\n\t\t);\n\t} else if ( hasUnsupportedBlocks ) {\n\t\thelp = __(\n\t\t\t'Enhancement disabled because there are non-compatible blocks inside the Query block.'\n\t\t);\n\t}\n\n\treturn (\n\t\t<>\n\t\t\t<ToggleControl\n\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\tlabel={ __( 'Reload full page' ) }\n\t\t\t\thelp={ help }\n\t\t\t\tchecked={\n\t\t\t\t\t! enhancedPagination && ! fullPageClientSideNavigation\n\t\t\t\t}\n\t\t\t\tdisabled={\n\t\t\t\t\thasUnsupportedBlocks || fullPageClientSideNavigation\n\t\t\t\t}\n\t\t\t\tonChange={ ( value ) => {\n\t\t\t\t\tsetAttributes( {\n\t\t\t\t\t\tenhancedPagination: ! value,\n\t\t\t\t\t} );\n\t\t\t\t} }\n\t\t\t/>\n\t\t</>\n\t);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,aAAa,QAAQ,uBAAuB;AACrD,SAASC,EAAE,QAAQ,iBAAiB;;AAEpC;AACA;AACA;AACA,SAASC,oBAAoB,QAAQ,aAAa;AAAC,SAAAC,GAAA,IAAAC,IAAA
|
|
1
|
+
{"version":3,"names":["ToggleControl","__","useUnsupportedBlocks","jsx","_jsx","Fragment","_Fragment","EnhancedPaginationControl","enhancedPagination","setAttributes","clientId","hasUnsupportedBlocks","fullPageClientSideNavigation","window","__experimentalFullPageClientSideNavigation","help","children","__nextHasNoMarginBottom","label","checked","disabled","onChange","value"],"sources":["@wordpress/block-library/src/query/edit/inspector-controls/enhanced-pagination-control.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { ToggleControl } from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\n\n/**\n * Internal dependencies\n */\nimport { useUnsupportedBlocks } from '../../utils';\n\nexport default function EnhancedPaginationControl( {\n\tenhancedPagination,\n\tsetAttributes,\n\tclientId,\n} ) {\n\tconst { hasUnsupportedBlocks } = useUnsupportedBlocks( clientId );\n\tconst fullPageClientSideNavigation =\n\t\twindow.__experimentalFullPageClientSideNavigation;\n\n\tlet help = __( 'Browsing between pages requires a full page reload.' );\n\tif ( fullPageClientSideNavigation ) {\n\t\thelp = __(\n\t\t\t'Experimental full-page client-side navigation setting enabled.'\n\t\t);\n\t} else if ( enhancedPagination ) {\n\t\thelp = __(\n\t\t\t'Reload the full page—instead of just the posts list—when visitors navigate between pages.'\n\t\t);\n\t} else if ( hasUnsupportedBlocks ) {\n\t\thelp = __(\n\t\t\t'Enhancement disabled because there are non-compatible blocks inside the Query block.'\n\t\t);\n\t}\n\n\treturn (\n\t\t<>\n\t\t\t<ToggleControl\n\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\tlabel={ __( 'Reload full page' ) }\n\t\t\t\thelp={ help }\n\t\t\t\tchecked={\n\t\t\t\t\t! enhancedPagination && ! fullPageClientSideNavigation\n\t\t\t\t}\n\t\t\t\tdisabled={\n\t\t\t\t\thasUnsupportedBlocks || fullPageClientSideNavigation\n\t\t\t\t}\n\t\t\t\tonChange={ ( value ) => {\n\t\t\t\t\tsetAttributes( {\n\t\t\t\t\t\tenhancedPagination: ! value,\n\t\t\t\t\t} );\n\t\t\t\t} }\n\t\t\t/>\n\t\t</>\n\t);\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,aAAa,QAAQ,uBAAuB;AACrD,SAASC,EAAE,QAAQ,iBAAiB;;AAEpC;AACA;AACA;AACA,SAASC,oBAAoB,QAAQ,aAAa;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,QAAA,IAAAC,SAAA;AAEnD,eAAe,SAASC,yBAAyBA,CAAE;EAClDC,kBAAkB;EAClBC,aAAa;EACbC;AACD,CAAC,EAAG;EACH,MAAM;IAAEC;EAAqB,CAAC,GAAGT,oBAAoB,CAAEQ,QAAS,CAAC;EACjE,MAAME,4BAA4B,GACjCC,MAAM,CAACC,0CAA0C;EAElD,IAAIC,IAAI,GAAGd,EAAE,CAAE,qDAAsD,CAAC;EACtE,IAAKW,4BAA4B,EAAG;IACnCG,IAAI,GAAGd,EAAE,CACR,gEACD,CAAC;EACF,CAAC,MAAM,IAAKO,kBAAkB,EAAG;IAChCO,IAAI,GAAGd,EAAE,CACR,2FACD,CAAC;EACF,CAAC,MAAM,IAAKU,oBAAoB,EAAG;IAClCI,IAAI,GAAGd,EAAE,CACR,sFACD,CAAC;EACF;EAEA,oBACCG,IAAA,CAAAE,SAAA;IAAAU,QAAA,eACCZ,IAAA,CAACJ,aAAa;MACbiB,uBAAuB;MACvBC,KAAK,EAAGjB,EAAE,CAAE,kBAAmB,CAAG;MAClCc,IAAI,EAAGA,IAAM;MACbI,OAAO,EACN,CAAEX,kBAAkB,IAAI,CAAEI,4BAC1B;MACDQ,QAAQ,EACPT,oBAAoB,IAAIC,4BACxB;MACDS,QAAQ,EAAKC,KAAK,IAAM;QACvBb,aAAa,CAAE;UACdD,kBAAkB,EAAE,CAAEc;QACvB,CAAE,CAAC;MACJ;IAAG,CACH;EAAC,CACD,CAAC;AAEL","ignoreList":[]}
|
|
@@ -25,9 +25,7 @@ import PagesControl from './pages-control';
|
|
|
25
25
|
import { unlock } from '../../../lock-unlock';
|
|
26
26
|
import { usePostTypes, useIsPostTypeHierarchical, useAllowedControls, isControlAllowed, useTaxonomies } from '../../utils';
|
|
27
27
|
import { useToolsPanelDropdownMenuProps } from '../../../utils/hooks';
|
|
28
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
29
|
-
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
30
|
-
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
28
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
31
29
|
const {
|
|
32
30
|
BlockInfo
|
|
33
31
|
} = unlock(blockEditorPrivateApis);
|
|
@@ -57,7 +55,7 @@ export default function QueryInspectorControls(props) {
|
|
|
57
55
|
format
|
|
58
56
|
} = query;
|
|
59
57
|
const allowedControls = useAllowedControls(attributes);
|
|
60
|
-
const
|
|
58
|
+
const showSticky = postType === 'post';
|
|
61
59
|
const {
|
|
62
60
|
postTypesTaxonomiesMap,
|
|
63
61
|
postTypesSelectOptions,
|
|
@@ -65,9 +63,6 @@ export default function QueryInspectorControls(props) {
|
|
|
65
63
|
} = usePostTypes();
|
|
66
64
|
const taxonomies = useTaxonomies(postType);
|
|
67
65
|
const isPostTypeHierarchical = useIsPostTypeHierarchical(postType);
|
|
68
|
-
useEffect(() => {
|
|
69
|
-
setShowSticky(postType === 'post');
|
|
70
|
-
}, [postType]);
|
|
71
66
|
const onPostTypeChange = newValue => {
|
|
72
67
|
const updateQuery = {
|
|
73
68
|
postType: newValue
|
|
@@ -152,16 +147,16 @@ export default function QueryInspectorControls(props) {
|
|
|
152
147
|
isBlock: true,
|
|
153
148
|
onChange: value => {
|
|
154
149
|
setQuery({
|
|
155
|
-
inherit:
|
|
150
|
+
inherit: value === 'default'
|
|
156
151
|
});
|
|
157
152
|
},
|
|
158
153
|
help: inherit ? __('Display a list of posts or custom post types based on the current template.') : __('Display a list of posts or custom post types based on specific criteria.'),
|
|
159
|
-
value: !!inherit,
|
|
154
|
+
value: !!inherit ? 'default' : 'custom',
|
|
160
155
|
children: [/*#__PURE__*/_jsx(ToggleGroupControlOption, {
|
|
161
|
-
value:
|
|
156
|
+
value: "default",
|
|
162
157
|
label: __('Default')
|
|
163
158
|
}), /*#__PURE__*/_jsx(ToggleGroupControlOption, {
|
|
164
|
-
value:
|
|
159
|
+
value: "custom",
|
|
165
160
|
label: __('Custom')
|
|
166
161
|
})]
|
|
167
162
|
}), showPostTypeControl && (postTypesSelectOptions.length > 2 ? /*#__PURE__*/_jsx(SelectControl, {
|
|
@@ -221,7 +216,7 @@ export default function QueryInspectorControls(props) {
|
|
|
221
216
|
},
|
|
222
217
|
dropdownMenuProps: dropdownMenuProps,
|
|
223
218
|
children: [/*#__PURE__*/_jsx(ToolsPanelItem, {
|
|
224
|
-
label: __('Items'),
|
|
219
|
+
label: __('Items per page'),
|
|
225
220
|
hasValue: () => perPage > 0,
|
|
226
221
|
children: /*#__PURE__*/_jsx(PerPageControl, {
|
|
227
222
|
perPage: perPage,
|
|
@@ -239,7 +234,7 @@ export default function QueryInspectorControls(props) {
|
|
|
239
234
|
onChange: setQuery
|
|
240
235
|
})
|
|
241
236
|
}), /*#__PURE__*/_jsx(ToolsPanelItem, {
|
|
242
|
-
label: __('Max
|
|
237
|
+
label: __('Max pages to show'),
|
|
243
238
|
hasValue: () => pages > 0,
|
|
244
239
|
onDeselect: () => setQuery({
|
|
245
240
|
pages: 0
|