@wordpress/editor 14.34.0 → 14.34.1-next.2f1c7c01b.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.
Files changed (1133) hide show
  1. package/build/bindings/api.js +2 -0
  2. package/build/bindings/api.js.map +1 -1
  3. package/build/bindings/pattern-overrides.js +3 -1
  4. package/build/bindings/pattern-overrides.js.map +1 -1
  5. package/build/bindings/post-data.js +50 -64
  6. package/build/bindings/post-data.js.map +3 -3
  7. package/build/bindings/post-meta.js +47 -39
  8. package/build/bindings/post-meta.js.map +2 -2
  9. package/build/bindings/term-data.js +3 -1
  10. package/build/bindings/term-data.js.map +1 -1
  11. package/build/components/autocompleters/index.js +2 -0
  12. package/build/components/autocompleters/index.js.map +1 -1
  13. package/build/components/autocompleters/user.js +3 -1
  14. package/build/components/autocompleters/user.js.map +1 -1
  15. package/build/components/autosave-monitor/index.js +4 -2
  16. package/build/components/autosave-monitor/index.js.map +1 -1
  17. package/build/components/block-removal-warnings/index.js +6 -4
  18. package/build/components/block-removal-warnings/index.js.map +1 -1
  19. package/build/components/block-settings-menu/plugin-block-settings-menu-item.js +6 -4
  20. package/build/components/block-settings-menu/plugin-block-settings-menu-item.js.map +1 -1
  21. package/build/components/block-visibility/index.js +5 -3
  22. package/build/components/block-visibility/index.js.map +1 -1
  23. package/build/components/blog-title/index.js +4 -2
  24. package/build/components/blog-title/index.js.map +1 -1
  25. package/build/components/character-count/index.js +2 -0
  26. package/build/components/character-count/index.js.map +1 -1
  27. package/build/components/collab-sidebar/add-comment.js +18 -12
  28. package/build/components/collab-sidebar/add-comment.js.map +2 -2
  29. package/build/components/collab-sidebar/comment-author-info.js +4 -2
  30. package/build/components/collab-sidebar/comment-author-info.js.map +2 -2
  31. package/build/components/collab-sidebar/comment-form.js +3 -1
  32. package/build/components/collab-sidebar/comment-form.js.map +1 -1
  33. package/build/components/collab-sidebar/comment-indicator-toolbar.js +14 -26
  34. package/build/components/collab-sidebar/comment-indicator-toolbar.js.map +3 -3
  35. package/build/components/collab-sidebar/comment-menu-item.js +40 -8
  36. package/build/components/collab-sidebar/comment-menu-item.js.map +3 -3
  37. package/build/components/collab-sidebar/comments.js +348 -323
  38. package/build/components/collab-sidebar/comments.js.map +3 -3
  39. package/build/components/collab-sidebar/constants.js +5 -3
  40. package/build/components/collab-sidebar/constants.js.map +1 -1
  41. package/build/components/collab-sidebar/hooks.js +8 -4
  42. package/build/components/collab-sidebar/hooks.js.map +2 -2
  43. package/build/components/collab-sidebar/index.js +50 -24
  44. package/build/components/collab-sidebar/index.js.map +3 -3
  45. package/build/components/collab-sidebar/utils.js +4 -2
  46. package/build/components/collab-sidebar/utils.js.map +2 -2
  47. package/build/components/collapsible-block-toolbar/index.js +4 -2
  48. package/build/components/collapsible-block-toolbar/index.js.map +1 -1
  49. package/build/components/commands/index.js +6 -4
  50. package/build/components/commands/index.js.map +1 -1
  51. package/build/components/deprecated.js +55 -53
  52. package/build/components/deprecated.js.map +1 -1
  53. package/build/components/document-bar/index.js +4 -2
  54. package/build/components/document-bar/index.js.map +1 -1
  55. package/build/components/document-outline/check.js +2 -0
  56. package/build/components/document-outline/check.js.map +1 -1
  57. package/build/components/document-outline/index.js +9 -7
  58. package/build/components/document-outline/index.js.map +1 -1
  59. package/build/components/document-outline/item.js +4 -2
  60. package/build/components/document-outline/item.js.map +1 -1
  61. package/build/components/document-tools/index.js +3 -1
  62. package/build/components/document-tools/index.js.map +1 -1
  63. package/build/components/editor/index.js +4 -2
  64. package/build/components/editor/index.js.map +3 -3
  65. package/build/components/editor-history/redo.js +3 -1
  66. package/build/components/editor-history/redo.js.map +1 -1
  67. package/build/components/editor-history/undo.js +3 -1
  68. package/build/components/editor-history/undo.js.map +1 -1
  69. package/build/components/editor-interface/index.js +4 -2
  70. package/build/components/editor-interface/index.js.map +1 -1
  71. package/build/components/editor-notices/index.js +3 -1
  72. package/build/components/editor-notices/index.js.map +1 -1
  73. package/build/components/editor-snackbars/index.js +4 -2
  74. package/build/components/editor-snackbars/index.js.map +1 -1
  75. package/build/components/entities-saved-states/entity-record-item.js +3 -1
  76. package/build/components/entities-saved-states/entity-record-item.js.map +1 -1
  77. package/build/components/entities-saved-states/entity-type-list.js +3 -1
  78. package/build/components/entities-saved-states/entity-type-list.js.map +1 -1
  79. package/build/components/entities-saved-states/hooks/use-is-dirty.js +3 -1
  80. package/build/components/entities-saved-states/hooks/use-is-dirty.js.map +1 -1
  81. package/build/components/entities-saved-states/index.js +3 -1
  82. package/build/components/entities-saved-states/index.js.map +1 -1
  83. package/build/components/error-boundary/index.js +5 -3
  84. package/build/components/error-boundary/index.js.map +1 -1
  85. package/build/components/global-keyboard-shortcuts/index.js +2 -0
  86. package/build/components/global-keyboard-shortcuts/index.js.map +1 -1
  87. package/build/components/global-keyboard-shortcuts/register-shortcuts.js +3 -1
  88. package/build/components/global-keyboard-shortcuts/register-shortcuts.js.map +1 -1
  89. package/build/components/global-styles/block-link.js +2 -0
  90. package/build/components/global-styles/block-link.js.map +1 -1
  91. package/build/components/global-styles/header.js +3 -1
  92. package/build/components/global-styles/header.js.map +1 -1
  93. package/build/components/global-styles/hooks.js +3 -1
  94. package/build/components/global-styles/hooks.js.map +1 -1
  95. package/build/components/global-styles/index.js +3 -1
  96. package/build/components/global-styles/index.js.map +1 -1
  97. package/build/components/global-styles/menu.js +3 -1
  98. package/build/components/global-styles/menu.js.map +1 -1
  99. package/build/components/global-styles-provider/index.js +3 -1
  100. package/build/components/global-styles-provider/index.js.map +1 -1
  101. package/build/components/global-styles-renderer/index.js +2 -0
  102. package/build/components/global-styles-renderer/index.js.map +1 -1
  103. package/build/components/global-styles-sidebar/default-sidebar.js +3 -1
  104. package/build/components/global-styles-sidebar/default-sidebar.js.map +1 -1
  105. package/build/components/global-styles-sidebar/index.js +3 -1
  106. package/build/components/global-styles-sidebar/index.js.map +1 -1
  107. package/build/components/global-styles-sidebar/welcome-guide-image.js +2 -0
  108. package/build/components/global-styles-sidebar/welcome-guide-image.js.map +1 -1
  109. package/build/components/global-styles-sidebar/welcome-guide.js +3 -1
  110. package/build/components/global-styles-sidebar/welcome-guide.js.map +1 -1
  111. package/build/components/header/back-button.js +8 -6
  112. package/build/components/header/back-button.js.map +1 -1
  113. package/build/components/header/index.js +5 -3
  114. package/build/components/header/index.js.map +1 -1
  115. package/build/components/index.js +4 -2
  116. package/build/components/index.js.map +2 -2
  117. package/build/components/inserter-sidebar/index.js +4 -2
  118. package/build/components/inserter-sidebar/index.js.map +1 -1
  119. package/build/components/keyboard-shortcut-help-modal/config.js +3 -1
  120. package/build/components/keyboard-shortcut-help-modal/config.js.map +1 -1
  121. package/build/components/keyboard-shortcut-help-modal/dynamic-shortcut.js +3 -1
  122. package/build/components/keyboard-shortcut-help-modal/dynamic-shortcut.js.map +1 -1
  123. package/build/components/keyboard-shortcut-help-modal/index.js +7 -5
  124. package/build/components/keyboard-shortcut-help-modal/index.js.map +1 -1
  125. package/build/components/keyboard-shortcut-help-modal/shortcut.js +3 -1
  126. package/build/components/keyboard-shortcut-help-modal/shortcut.js.map +1 -1
  127. package/build/components/list-view-sidebar/index.js +4 -2
  128. package/build/components/list-view-sidebar/index.js.map +1 -1
  129. package/build/components/list-view-sidebar/list-view-outline.js +3 -1
  130. package/build/components/list-view-sidebar/list-view-outline.js.map +1 -1
  131. package/build/components/local-autosave-monitor/index.js +6 -4
  132. package/build/components/local-autosave-monitor/index.js.map +1 -1
  133. package/build/components/media-categories/index.js +8 -6
  134. package/build/components/media-categories/index.js.map +1 -1
  135. package/build/components/mode-switcher/index.js +4 -2
  136. package/build/components/mode-switcher/index.js.map +1 -1
  137. package/build/components/more-menu/copy-content-menu-item.js +3 -1
  138. package/build/components/more-menu/copy-content-menu-item.js.map +1 -1
  139. package/build/components/more-menu/index.js +4 -2
  140. package/build/components/more-menu/index.js.map +2 -2
  141. package/build/components/more-menu/tools-more-menu-group.js +4 -2
  142. package/build/components/more-menu/tools-more-menu-group.js.map +1 -1
  143. package/build/components/more-menu/view-more-menu-group.js +4 -2
  144. package/build/components/more-menu/view-more-menu-group.js.map +1 -1
  145. package/build/components/page-attributes/check.js +2 -0
  146. package/build/components/page-attributes/check.js.map +1 -1
  147. package/build/components/page-attributes/order.js +3 -1
  148. package/build/components/page-attributes/order.js.map +1 -1
  149. package/build/components/page-attributes/panel.js +4 -2
  150. package/build/components/page-attributes/panel.js.map +1 -1
  151. package/build/components/page-attributes/parent.js +4 -2
  152. package/build/components/page-attributes/parent.js.map +1 -1
  153. package/build/components/pattern-duplicate-modal/index.js +5 -3
  154. package/build/components/pattern-duplicate-modal/index.js.map +1 -1
  155. package/build/components/pattern-overrides-panel/index.js +4 -2
  156. package/build/components/pattern-overrides-panel/index.js.map +1 -1
  157. package/build/components/pattern-rename-modal/index.js +5 -3
  158. package/build/components/pattern-rename-modal/index.js.map +1 -1
  159. package/build/components/plugin-document-setting-panel/index.js +5 -3
  160. package/build/components/plugin-document-setting-panel/index.js.map +1 -1
  161. package/build/components/plugin-more-menu-item/index.js +3 -1
  162. package/build/components/plugin-more-menu-item/index.js.map +1 -1
  163. package/build/components/plugin-post-publish-panel/index.js +5 -3
  164. package/build/components/plugin-post-publish-panel/index.js.map +1 -1
  165. package/build/components/plugin-post-status-info/index.js +5 -3
  166. package/build/components/plugin-post-status-info/index.js.map +1 -1
  167. package/build/components/plugin-pre-publish-panel/index.js +5 -3
  168. package/build/components/plugin-pre-publish-panel/index.js.map +1 -1
  169. package/build/components/plugin-preview-menu-item/index.js +3 -1
  170. package/build/components/plugin-preview-menu-item/index.js.map +1 -1
  171. package/build/components/plugin-sidebar/index.js +3 -1
  172. package/build/components/plugin-sidebar/index.js.map +1 -1
  173. package/build/components/plugin-sidebar-more-menu-item/index.js +3 -1
  174. package/build/components/plugin-sidebar-more-menu-item/index.js.map +1 -1
  175. package/build/components/post-actions/actions.js +3 -1
  176. package/build/components/post-actions/actions.js.map +1 -1
  177. package/build/components/post-actions/index.js +4 -2
  178. package/build/components/post-actions/index.js.map +1 -1
  179. package/build/components/post-actions/set-as-homepage.js +5 -3
  180. package/build/components/post-actions/set-as-homepage.js.map +1 -1
  181. package/build/components/post-actions/set-as-posts-page.js +5 -3
  182. package/build/components/post-actions/set-as-posts-page.js.map +1 -1
  183. package/build/components/post-author/check.js +3 -1
  184. package/build/components/post-author/check.js.map +1 -1
  185. package/build/components/post-author/combobox.js +3 -1
  186. package/build/components/post-author/combobox.js.map +1 -1
  187. package/build/components/post-author/constants.js +4 -2
  188. package/build/components/post-author/constants.js.map +1 -1
  189. package/build/components/post-author/hook.js +2 -0
  190. package/build/components/post-author/hook.js.map +1 -1
  191. package/build/components/post-author/index.js +4 -2
  192. package/build/components/post-author/index.js.map +1 -1
  193. package/build/components/post-author/panel.js +3 -1
  194. package/build/components/post-author/panel.js.map +1 -1
  195. package/build/components/post-author/select.js +3 -1
  196. package/build/components/post-author/select.js.map +1 -1
  197. package/build/components/post-card-panel/index.js +4 -2
  198. package/build/components/post-card-panel/index.js.map +1 -1
  199. package/build/components/post-comments/index.js +4 -2
  200. package/build/components/post-comments/index.js.map +1 -1
  201. package/build/components/post-content-information/index.js +4 -2
  202. package/build/components/post-content-information/index.js.map +1 -1
  203. package/build/components/post-discussion/panel.js +4 -2
  204. package/build/components/post-discussion/panel.js.map +1 -1
  205. package/build/components/post-excerpt/check.js +3 -1
  206. package/build/components/post-excerpt/check.js.map +1 -1
  207. package/build/components/post-excerpt/index.js +3 -1
  208. package/build/components/post-excerpt/index.js.map +1 -1
  209. package/build/components/post-excerpt/panel.js +4 -2
  210. package/build/components/post-excerpt/panel.js.map +1 -1
  211. package/build/components/post-excerpt/plugin.js +5 -3
  212. package/build/components/post-excerpt/plugin.js.map +1 -1
  213. package/build/components/post-featured-image/check.js +3 -1
  214. package/build/components/post-featured-image/check.js.map +1 -1
  215. package/build/components/post-featured-image/index.js +10 -8
  216. package/build/components/post-featured-image/index.js.map +1 -1
  217. package/build/components/post-featured-image/panel.js +4 -2
  218. package/build/components/post-featured-image/panel.js.map +1 -1
  219. package/build/components/post-fields/index.js +2 -0
  220. package/build/components/post-fields/index.js.map +1 -1
  221. package/build/components/post-format/check.js +3 -1
  222. package/build/components/post-format/check.js.map +1 -1
  223. package/build/components/post-format/index.js +4 -2
  224. package/build/components/post-format/index.js.map +1 -1
  225. package/build/components/post-format/panel.js +3 -1
  226. package/build/components/post-format/panel.js.map +1 -1
  227. package/build/components/post-last-edited-panel/index.js +3 -1
  228. package/build/components/post-last-edited-panel/index.js.map +1 -1
  229. package/build/components/post-last-revision/check.js +3 -1
  230. package/build/components/post-last-revision/check.js.map +1 -1
  231. package/build/components/post-last-revision/index.js +3 -1
  232. package/build/components/post-last-revision/index.js.map +1 -1
  233. package/build/components/post-last-revision/panel.js +3 -1
  234. package/build/components/post-last-revision/panel.js.map +1 -1
  235. package/build/components/post-locked-modal/index.js +3 -1
  236. package/build/components/post-locked-modal/index.js.map +1 -1
  237. package/build/components/post-panel-row/index.js +4 -2
  238. package/build/components/post-panel-row/index.js.map +1 -1
  239. package/build/components/post-panel-section/index.js +3 -1
  240. package/build/components/post-panel-section/index.js.map +1 -1
  241. package/build/components/post-pending-status/check.js +2 -0
  242. package/build/components/post-pending-status/check.js.map +1 -1
  243. package/build/components/post-pending-status/index.js +3 -1
  244. package/build/components/post-pending-status/index.js.map +1 -1
  245. package/build/components/post-pingbacks/index.js +3 -1
  246. package/build/components/post-pingbacks/index.js.map +1 -1
  247. package/build/components/post-preview-button/index.js +3 -1
  248. package/build/components/post-preview-button/index.js.map +1 -1
  249. package/build/components/post-publish-button/index.js +6 -4
  250. package/build/components/post-publish-button/index.js.map +1 -1
  251. package/build/components/post-publish-button/label.js +2 -0
  252. package/build/components/post-publish-button/label.js.map +1 -1
  253. package/build/components/post-publish-button/post-publish-button-or-toggle.js +5 -3
  254. package/build/components/post-publish-button/post-publish-button-or-toggle.js.map +1 -1
  255. package/build/components/post-publish-panel/index.js +5 -3
  256. package/build/components/post-publish-panel/index.js.map +1 -1
  257. package/build/components/post-publish-panel/maybe-category-panel.js +3 -1
  258. package/build/components/post-publish-panel/maybe-category-panel.js.map +1 -1
  259. package/build/components/post-publish-panel/maybe-post-format-panel.js +5 -3
  260. package/build/components/post-publish-panel/maybe-post-format-panel.js.map +1 -1
  261. package/build/components/post-publish-panel/maybe-tags-panel.js +5 -3
  262. package/build/components/post-publish-panel/maybe-tags-panel.js.map +1 -1
  263. package/build/components/post-publish-panel/maybe-upload-media.js +3 -1
  264. package/build/components/post-publish-panel/maybe-upload-media.js.map +1 -1
  265. package/build/components/post-publish-panel/media-util.js +2 -0
  266. package/build/components/post-publish-panel/media-util.js.map +1 -1
  267. package/build/components/post-publish-panel/postpublish.js +6 -4
  268. package/build/components/post-publish-panel/postpublish.js.map +1 -1
  269. package/build/components/post-publish-panel/prepublish.js +3 -1
  270. package/build/components/post-publish-panel/prepublish.js.map +1 -1
  271. package/build/components/post-saved-state/index.js +3 -1
  272. package/build/components/post-saved-state/index.js.map +1 -1
  273. package/build/components/post-schedule/check.js +2 -0
  274. package/build/components/post-schedule/check.js.map +1 -1
  275. package/build/components/post-schedule/index.js +4 -2
  276. package/build/components/post-schedule/index.js.map +1 -1
  277. package/build/components/post-schedule/label.js +2 -0
  278. package/build/components/post-schedule/label.js.map +1 -1
  279. package/build/components/post-schedule/panel.js +4 -2
  280. package/build/components/post-schedule/panel.js.map +1 -1
  281. package/build/components/post-status/index.js +6 -4
  282. package/build/components/post-status/index.js.map +1 -1
  283. package/build/components/post-sticky/check.js +2 -0
  284. package/build/components/post-sticky/check.js.map +1 -1
  285. package/build/components/post-sticky/index.js +3 -1
  286. package/build/components/post-sticky/index.js.map +1 -1
  287. package/build/components/post-sticky/panel.js +3 -1
  288. package/build/components/post-sticky/panel.js.map +1 -1
  289. package/build/components/post-switch-to-draft-button/index.js +3 -1
  290. package/build/components/post-switch-to-draft-button/index.js.map +1 -1
  291. package/build/components/post-sync-status/index.js +3 -1
  292. package/build/components/post-sync-status/index.js.map +1 -1
  293. package/build/components/post-taxonomies/check.js +2 -0
  294. package/build/components/post-taxonomies/check.js.map +1 -1
  295. package/build/components/post-taxonomies/flat-term-selector.js +9 -7
  296. package/build/components/post-taxonomies/flat-term-selector.js.map +1 -1
  297. package/build/components/post-taxonomies/hierarchical-term-selector.js +8 -6
  298. package/build/components/post-taxonomies/hierarchical-term-selector.js.map +1 -1
  299. package/build/components/post-taxonomies/index.js +4 -2
  300. package/build/components/post-taxonomies/index.js.map +1 -1
  301. package/build/components/post-taxonomies/most-used-terms.js +5 -3
  302. package/build/components/post-taxonomies/most-used-terms.js.map +1 -1
  303. package/build/components/post-taxonomies/panel.js +3 -1
  304. package/build/components/post-taxonomies/panel.js.map +1 -1
  305. package/build/components/post-template/block-theme.js +3 -1
  306. package/build/components/post-template/block-theme.js.map +1 -1
  307. package/build/components/post-template/classic-theme.js +3 -1
  308. package/build/components/post-template/classic-theme.js.map +1 -1
  309. package/build/components/post-template/create-new-template-modal.js +4 -2
  310. package/build/components/post-template/create-new-template-modal.js.map +1 -1
  311. package/build/components/post-template/create-new-template.js +3 -1
  312. package/build/components/post-template/create-new-template.js.map +1 -1
  313. package/build/components/post-template/hooks.js +2 -0
  314. package/build/components/post-template/hooks.js.map +1 -1
  315. package/build/components/post-template/panel.js +3 -1
  316. package/build/components/post-template/panel.js.map +1 -1
  317. package/build/components/post-template/reset-default-template.js +3 -1
  318. package/build/components/post-template/reset-default-template.js.map +1 -1
  319. package/build/components/post-template/swap-template-button.js +3 -1
  320. package/build/components/post-template/swap-template-button.js.map +1 -1
  321. package/build/components/post-text-editor/index.js +3 -1
  322. package/build/components/post-text-editor/index.js.map +1 -1
  323. package/build/components/post-title/constants.js +4 -2
  324. package/build/components/post-title/constants.js.map +1 -1
  325. package/build/components/post-title/index.js +7 -5
  326. package/build/components/post-title/index.js.map +1 -1
  327. package/build/components/post-title/post-title-raw.js +3 -1
  328. package/build/components/post-title/post-title-raw.js.map +1 -1
  329. package/build/components/post-title/use-post-title-focus.js +2 -0
  330. package/build/components/post-title/use-post-title-focus.js.map +1 -1
  331. package/build/components/post-title/use-post-title.js +2 -0
  332. package/build/components/post-title/use-post-title.js.map +1 -1
  333. package/build/components/post-transform-panel/hooks.js +3 -1
  334. package/build/components/post-transform-panel/hooks.js.map +1 -1
  335. package/build/components/post-transform-panel/index.js +3 -1
  336. package/build/components/post-transform-panel/index.js.map +1 -1
  337. package/build/components/post-trash/check.js +2 -0
  338. package/build/components/post-trash/check.js.map +1 -1
  339. package/build/components/post-trash/index.js +3 -1
  340. package/build/components/post-trash/index.js.map +1 -1
  341. package/build/components/post-type-support-check/index.js +2 -0
  342. package/build/components/post-type-support-check/index.js.map +1 -1
  343. package/build/components/post-url/check.js +2 -0
  344. package/build/components/post-url/check.js.map +1 -1
  345. package/build/components/post-url/index.js +3 -1
  346. package/build/components/post-url/index.js.map +1 -1
  347. package/build/components/post-url/label.js +2 -0
  348. package/build/components/post-url/label.js.map +1 -1
  349. package/build/components/post-url/panel.js +3 -1
  350. package/build/components/post-url/panel.js.map +1 -1
  351. package/build/components/post-view-link/index.js +3 -1
  352. package/build/components/post-view-link/index.js.map +1 -1
  353. package/build/components/post-visibility/check.js +2 -0
  354. package/build/components/post-visibility/check.js.map +1 -1
  355. package/build/components/post-visibility/index.js +3 -1
  356. package/build/components/post-visibility/index.js.map +1 -1
  357. package/build/components/post-visibility/label.js +2 -0
  358. package/build/components/post-visibility/label.js.map +1 -1
  359. package/build/components/post-visibility/utils.js +3 -1
  360. package/build/components/post-visibility/utils.js.map +1 -1
  361. package/build/components/posts-per-page/index.js +3 -1
  362. package/build/components/posts-per-page/index.js.map +1 -1
  363. package/build/components/preferences-modal/enable-panel.js +4 -2
  364. package/build/components/preferences-modal/enable-panel.js.map +1 -1
  365. package/build/components/preferences-modal/enable-plugin-document-setting-panel.js +5 -3
  366. package/build/components/preferences-modal/enable-plugin-document-setting-panel.js.map +1 -1
  367. package/build/components/preferences-modal/enable-publish-sidebar.js +4 -2
  368. package/build/components/preferences-modal/enable-publish-sidebar.js.map +1 -1
  369. package/build/components/preferences-modal/index.js +5 -3
  370. package/build/components/preferences-modal/index.js.map +2 -2
  371. package/build/components/preview-dropdown/index.js +3 -1
  372. package/build/components/preview-dropdown/index.js.map +1 -1
  373. package/build/components/provider/disable-non-page-content-blocks.js +2 -0
  374. package/build/components/provider/disable-non-page-content-blocks.js.map +1 -1
  375. package/build/components/provider/index.js +8 -6
  376. package/build/components/provider/index.js.map +1 -1
  377. package/build/components/provider/navigation-block-editing-mode.js +2 -0
  378. package/build/components/provider/navigation-block-editing-mode.js.map +1 -1
  379. package/build/components/provider/use-auto-switch-editor-sidebars.js +2 -0
  380. package/build/components/provider/use-auto-switch-editor-sidebars.js.map +1 -1
  381. package/build/components/provider/use-block-editor-settings.js +5 -3
  382. package/build/components/provider/use-block-editor-settings.js.map +1 -1
  383. package/build/components/provider/use-hide-blocks-from-inserter.js +3 -1
  384. package/build/components/provider/use-hide-blocks-from-inserter.js.map +1 -1
  385. package/build/components/provider/use-post-content-blocks.js +3 -1
  386. package/build/components/provider/use-post-content-blocks.js.map +1 -1
  387. package/build/components/provider/with-registry-provider.js +4 -2
  388. package/build/components/provider/with-registry-provider.js.map +1 -1
  389. package/build/components/resizable-editor/index.js +4 -2
  390. package/build/components/resizable-editor/index.js.map +1 -1
  391. package/build/components/resizable-editor/resize-handle.js +4 -2
  392. package/build/components/resizable-editor/resize-handle.js.map +1 -1
  393. package/build/components/save-publish-panels/index.js +5 -3
  394. package/build/components/save-publish-panels/index.js.map +1 -1
  395. package/build/components/sidebar/constants.js +3 -1
  396. package/build/components/sidebar/constants.js.map +1 -1
  397. package/build/components/sidebar/header.js +5 -3
  398. package/build/components/sidebar/header.js.map +1 -1
  399. package/build/components/sidebar/index.js +7 -5
  400. package/build/components/sidebar/index.js.map +1 -1
  401. package/build/components/sidebar/post-summary.js +4 -2
  402. package/build/components/sidebar/post-summary.js.map +1 -1
  403. package/build/components/site-discussion/index.js +4 -2
  404. package/build/components/site-discussion/index.js.map +1 -1
  405. package/build/components/start-page-options/index.js +7 -6
  406. package/build/components/start-page-options/index.js.map +2 -2
  407. package/build/components/start-template-options/index.js +3 -1
  408. package/build/components/start-template-options/index.js.map +1 -1
  409. package/build/components/style-book/categories.js +2 -0
  410. package/build/components/style-book/categories.js.map +1 -1
  411. package/build/components/style-book/color-examples.js +4 -2
  412. package/build/components/style-book/color-examples.js.map +1 -1
  413. package/build/components/style-book/constants.js +9 -7
  414. package/build/components/style-book/constants.js.map +1 -1
  415. package/build/components/style-book/duotone-examples.js +4 -2
  416. package/build/components/style-book/duotone-examples.js.map +1 -1
  417. package/build/components/style-book/examples.js +3 -1
  418. package/build/components/style-book/examples.js.map +1 -1
  419. package/build/components/style-book/index.js +13 -11
  420. package/build/components/style-book/index.js.map +1 -1
  421. package/build/components/style-book/types.js +2 -0
  422. package/build/components/style-book/types.js.map +1 -1
  423. package/build/components/styles-canvas/index.js +3 -1
  424. package/build/components/styles-canvas/index.js.map +1 -1
  425. package/build/components/styles-canvas/revisions.js +4 -2
  426. package/build/components/styles-canvas/revisions.js.map +1 -1
  427. package/build/components/styles-canvas/style-book.js +3 -1
  428. package/build/components/styles-canvas/style-book.js.map +1 -1
  429. package/build/components/table-of-contents/index.js +3 -1
  430. package/build/components/table-of-contents/index.js.map +1 -1
  431. package/build/components/table-of-contents/panel.js +3 -1
  432. package/build/components/table-of-contents/panel.js.map +1 -1
  433. package/build/components/template-content-panel/index.js +6 -4
  434. package/build/components/template-content-panel/index.js.map +1 -1
  435. package/build/components/template-part-content-panel/index.js +4 -2
  436. package/build/components/template-part-content-panel/index.js.map +1 -1
  437. package/build/components/template-part-menu-items/convert-to-regular.js +3 -1
  438. package/build/components/template-part-menu-items/convert-to-regular.js.map +1 -1
  439. package/build/components/template-part-menu-items/convert-to-template-part.js +3 -1
  440. package/build/components/template-part-menu-items/convert-to-template-part.js.map +1 -1
  441. package/build/components/template-part-menu-items/index.js +3 -1
  442. package/build/components/template-part-menu-items/index.js.map +1 -1
  443. package/build/components/template-validation-notice/index.js +3 -1
  444. package/build/components/template-validation-notice/index.js.map +1 -1
  445. package/build/components/text-editor/index.js +3 -1
  446. package/build/components/text-editor/index.js.map +1 -1
  447. package/build/components/theme-support-check/index.js +2 -0
  448. package/build/components/theme-support-check/index.js.map +1 -1
  449. package/build/components/time-to-read/index.js +4 -2
  450. package/build/components/time-to-read/index.js.map +1 -1
  451. package/build/components/unsaved-changes-warning/index.js +2 -0
  452. package/build/components/unsaved-changes-warning/index.js.map +1 -1
  453. package/build/components/visual-editor/edit-template-blocks-notification.js +3 -1
  454. package/build/components/visual-editor/edit-template-blocks-notification.js.map +1 -1
  455. package/build/components/visual-editor/index.js +25 -12
  456. package/build/components/visual-editor/index.js.map +2 -2
  457. package/build/components/visual-editor/use-select-nearest-editable-block.js +3 -1
  458. package/build/components/visual-editor/use-select-nearest-editable-block.js.map +1 -1
  459. package/build/components/visual-editor/use-zoom-out-mode-exit.js +2 -0
  460. package/build/components/visual-editor/use-zoom-out-mode-exit.js.map +1 -1
  461. package/build/components/word-count/index.js +3 -1
  462. package/build/components/word-count/index.js.map +1 -1
  463. package/build/components/zoom-out-toggle/index.js +4 -2
  464. package/build/components/zoom-out-toggle/index.js.map +1 -1
  465. package/build/dataviews/api.js +2 -0
  466. package/build/dataviews/api.js.map +1 -1
  467. package/build/dataviews/fields/content-preview/content-preview-view.js +4 -2
  468. package/build/dataviews/fields/content-preview/content-preview-view.js.map +1 -1
  469. package/build/dataviews/fields/content-preview/index.js +3 -1
  470. package/build/dataviews/fields/content-preview/index.js.map +1 -1
  471. package/build/dataviews/store/private-actions.js +3 -1
  472. package/build/dataviews/store/private-actions.js.map +1 -1
  473. package/build/dataviews/store/private-selectors.js +3 -1
  474. package/build/dataviews/store/private-selectors.js.map +1 -1
  475. package/build/dataviews/store/reducer.js +2 -0
  476. package/build/dataviews/store/reducer.js.map +1 -1
  477. package/build/hooks/custom-sources-backwards-compatibility.js +4 -2
  478. package/build/hooks/custom-sources-backwards-compatibility.js.map +1 -1
  479. package/build/hooks/default-autocompleters.js +2 -0
  480. package/build/hooks/default-autocompleters.js.map +1 -1
  481. package/build/hooks/index.js +2 -0
  482. package/build/hooks/index.js.map +1 -1
  483. package/build/hooks/media-upload.js +3 -1
  484. package/build/hooks/media-upload.js.map +1 -1
  485. package/build/hooks/navigation-link-view-button.js +5 -3
  486. package/build/hooks/navigation-link-view-button.js.map +1 -1
  487. package/build/hooks/pattern-overrides.js +5 -3
  488. package/build/hooks/pattern-overrides.js.map +1 -1
  489. package/build/hooks/push-changes-to-global-styles/index.js +12 -10
  490. package/build/hooks/push-changes-to-global-styles/index.js.map +1 -1
  491. package/build/hooks/template-part-navigation-edit-button.js +7 -5
  492. package/build/hooks/template-part-navigation-edit-button.js.map +1 -1
  493. package/build/hooks/use-global-styles-output.js +2 -0
  494. package/build/hooks/use-global-styles-output.js.map +1 -1
  495. package/build/index.js +2 -0
  496. package/build/index.js.map +1 -1
  497. package/build/lock-unlock.js +3 -1
  498. package/build/lock-unlock.js.map +1 -1
  499. package/build/private-apis.js +4 -2
  500. package/build/private-apis.js.map +1 -1
  501. package/build/store/actions.js +53 -51
  502. package/build/store/actions.js.map +1 -1
  503. package/build/store/constants.js +15 -13
  504. package/build/store/constants.js.map +1 -1
  505. package/build/store/defaults.js +3 -1
  506. package/build/store/defaults.js.map +1 -1
  507. package/build/store/index.js +4 -2
  508. package/build/store/index.js.map +1 -1
  509. package/build/store/local-autosave.js +2 -0
  510. package/build/store/local-autosave.js.map +1 -1
  511. package/build/store/private-actions.js +17 -7
  512. package/build/store/private-actions.js.map +2 -2
  513. package/build/store/private-selectors.js +15 -8
  514. package/build/store/private-selectors.js.map +2 -2
  515. package/build/store/reducer.js +12 -0
  516. package/build/store/reducer.js.map +2 -2
  517. package/build/store/selectors.js +80 -78
  518. package/build/store/selectors.js.map +2 -2
  519. package/build/store/utils/is-template-revertable.js +2 -0
  520. package/build/store/utils/is-template-revertable.js.map +1 -1
  521. package/build/store/utils/notice-builder.js +2 -0
  522. package/build/store/utils/notice-builder.js.map +1 -1
  523. package/build/utils/get-item-title.js +2 -0
  524. package/build/utils/get-item-title.js.map +1 -1
  525. package/build/utils/get-template-info.js +4 -2
  526. package/build/utils/get-template-info.js.map +1 -1
  527. package/build/utils/get-template-part-icon.js +2 -0
  528. package/build/utils/get-template-part-icon.js.map +1 -1
  529. package/build/utils/index.js +2 -0
  530. package/build/utils/index.js.map +1 -1
  531. package/build/utils/media-sideload/index.js +3 -1
  532. package/build/utils/media-sideload/index.js.map +1 -1
  533. package/build/utils/media-upload/index.js +3 -1
  534. package/build/utils/media-upload/index.js.map +1 -1
  535. package/build/utils/pageTypeBadge.js +2 -0
  536. package/build/utils/pageTypeBadge.js.map +1 -1
  537. package/build/utils/search-templates.js +2 -0
  538. package/build/utils/search-templates.js.map +1 -1
  539. package/build/utils/set-nested-value.js +2 -0
  540. package/build/utils/set-nested-value.js.map +1 -1
  541. package/build/utils/terms.js +5 -3
  542. package/build/utils/terms.js.map +1 -1
  543. package/build/utils/url.js +2 -0
  544. package/build/utils/url.js.map +1 -1
  545. package/build-module/bindings/api.js +1 -0
  546. package/build-module/bindings/api.js.map +1 -1
  547. package/build-module/bindings/pattern-overrides.js +2 -1
  548. package/build-module/bindings/pattern-overrides.js.map +1 -1
  549. package/build-module/bindings/post-data.js +49 -64
  550. package/build-module/bindings/post-data.js.map +2 -2
  551. package/build-module/bindings/post-meta.js +46 -39
  552. package/build-module/bindings/post-meta.js.map +2 -2
  553. package/build-module/bindings/term-data.js +2 -1
  554. package/build-module/bindings/term-data.js.map +1 -1
  555. package/build-module/components/autocompleters/index.js +1 -0
  556. package/build-module/components/autocompleters/index.js.map +1 -1
  557. package/build-module/components/autocompleters/user.js +2 -1
  558. package/build-module/components/autocompleters/user.js.map +1 -1
  559. package/build-module/components/autosave-monitor/index.js +3 -2
  560. package/build-module/components/autosave-monitor/index.js.map +1 -1
  561. package/build-module/components/block-removal-warnings/index.js +5 -4
  562. package/build-module/components/block-removal-warnings/index.js.map +1 -1
  563. package/build-module/components/block-settings-menu/plugin-block-settings-menu-item.js +5 -4
  564. package/build-module/components/block-settings-menu/plugin-block-settings-menu-item.js.map +1 -1
  565. package/build-module/components/block-visibility/index.js +4 -3
  566. package/build-module/components/block-visibility/index.js.map +1 -1
  567. package/build-module/components/blog-title/index.js +3 -2
  568. package/build-module/components/blog-title/index.js.map +1 -1
  569. package/build-module/components/character-count/index.js +1 -0
  570. package/build-module/components/character-count/index.js.map +1 -1
  571. package/build-module/components/collab-sidebar/add-comment.js +18 -13
  572. package/build-module/components/collab-sidebar/add-comment.js.map +2 -2
  573. package/build-module/components/collab-sidebar/comment-author-info.js +3 -2
  574. package/build-module/components/collab-sidebar/comment-author-info.js.map +2 -2
  575. package/build-module/components/collab-sidebar/comment-form.js +2 -1
  576. package/build-module/components/collab-sidebar/comment-form.js.map +1 -1
  577. package/build-module/components/collab-sidebar/comment-indicator-toolbar.js +19 -28
  578. package/build-module/components/collab-sidebar/comment-indicator-toolbar.js.map +2 -2
  579. package/build-module/components/collab-sidebar/comment-menu-item.js +43 -9
  580. package/build-module/components/collab-sidebar/comment-menu-item.js.map +2 -2
  581. package/build-module/components/collab-sidebar/comments.js +349 -324
  582. package/build-module/components/collab-sidebar/comments.js.map +2 -2
  583. package/build-module/components/collab-sidebar/constants.js +4 -3
  584. package/build-module/components/collab-sidebar/constants.js.map +1 -1
  585. package/build-module/components/collab-sidebar/hooks.js +7 -4
  586. package/build-module/components/collab-sidebar/hooks.js.map +2 -2
  587. package/build-module/components/collab-sidebar/index.js +49 -24
  588. package/build-module/components/collab-sidebar/index.js.map +2 -2
  589. package/build-module/components/collab-sidebar/utils.js +3 -2
  590. package/build-module/components/collab-sidebar/utils.js.map +2 -2
  591. package/build-module/components/collapsible-block-toolbar/index.js +3 -2
  592. package/build-module/components/collapsible-block-toolbar/index.js.map +1 -1
  593. package/build-module/components/commands/index.js +5 -4
  594. package/build-module/components/commands/index.js.map +1 -1
  595. package/build-module/components/deprecated.js +54 -53
  596. package/build-module/components/deprecated.js.map +1 -1
  597. package/build-module/components/document-bar/index.js +3 -2
  598. package/build-module/components/document-bar/index.js.map +1 -1
  599. package/build-module/components/document-outline/check.js +1 -0
  600. package/build-module/components/document-outline/check.js.map +1 -1
  601. package/build-module/components/document-outline/index.js +8 -7
  602. package/build-module/components/document-outline/index.js.map +1 -1
  603. package/build-module/components/document-outline/item.js +3 -2
  604. package/build-module/components/document-outline/item.js.map +1 -1
  605. package/build-module/components/document-tools/index.js +2 -1
  606. package/build-module/components/document-tools/index.js.map +1 -1
  607. package/build-module/components/editor/index.js +3 -2
  608. package/build-module/components/editor/index.js.map +2 -2
  609. package/build-module/components/editor-history/redo.js +2 -1
  610. package/build-module/components/editor-history/redo.js.map +1 -1
  611. package/build-module/components/editor-history/undo.js +2 -1
  612. package/build-module/components/editor-history/undo.js.map +1 -1
  613. package/build-module/components/editor-interface/index.js +3 -2
  614. package/build-module/components/editor-interface/index.js.map +1 -1
  615. package/build-module/components/editor-notices/index.js +2 -1
  616. package/build-module/components/editor-notices/index.js.map +1 -1
  617. package/build-module/components/editor-snackbars/index.js +3 -2
  618. package/build-module/components/editor-snackbars/index.js.map +1 -1
  619. package/build-module/components/entities-saved-states/entity-record-item.js +2 -1
  620. package/build-module/components/entities-saved-states/entity-record-item.js.map +1 -1
  621. package/build-module/components/entities-saved-states/entity-type-list.js +2 -1
  622. package/build-module/components/entities-saved-states/entity-type-list.js.map +1 -1
  623. package/build-module/components/entities-saved-states/hooks/use-is-dirty.js +2 -1
  624. package/build-module/components/entities-saved-states/hooks/use-is-dirty.js.map +1 -1
  625. package/build-module/components/entities-saved-states/index.js +2 -1
  626. package/build-module/components/entities-saved-states/index.js.map +1 -1
  627. package/build-module/components/error-boundary/index.js +4 -3
  628. package/build-module/components/error-boundary/index.js.map +1 -1
  629. package/build-module/components/global-keyboard-shortcuts/index.js +1 -0
  630. package/build-module/components/global-keyboard-shortcuts/index.js.map +1 -1
  631. package/build-module/components/global-keyboard-shortcuts/register-shortcuts.js +2 -1
  632. package/build-module/components/global-keyboard-shortcuts/register-shortcuts.js.map +1 -1
  633. package/build-module/components/global-styles/block-link.js +1 -0
  634. package/build-module/components/global-styles/block-link.js.map +1 -1
  635. package/build-module/components/global-styles/header.js +2 -1
  636. package/build-module/components/global-styles/header.js.map +1 -1
  637. package/build-module/components/global-styles/hooks.js +2 -1
  638. package/build-module/components/global-styles/hooks.js.map +1 -1
  639. package/build-module/components/global-styles/index.js +3 -2
  640. package/build-module/components/global-styles/index.js.map +1 -1
  641. package/build-module/components/global-styles/menu.js +2 -1
  642. package/build-module/components/global-styles/menu.js.map +1 -1
  643. package/build-module/components/global-styles-provider/index.js +2 -1
  644. package/build-module/components/global-styles-provider/index.js.map +1 -1
  645. package/build-module/components/global-styles-renderer/index.js +1 -0
  646. package/build-module/components/global-styles-renderer/index.js.map +1 -1
  647. package/build-module/components/global-styles-sidebar/default-sidebar.js +2 -1
  648. package/build-module/components/global-styles-sidebar/default-sidebar.js.map +1 -1
  649. package/build-module/components/global-styles-sidebar/index.js +2 -1
  650. package/build-module/components/global-styles-sidebar/index.js.map +1 -1
  651. package/build-module/components/global-styles-sidebar/welcome-guide-image.js +1 -0
  652. package/build-module/components/global-styles-sidebar/welcome-guide-image.js.map +1 -1
  653. package/build-module/components/global-styles-sidebar/welcome-guide.js +2 -1
  654. package/build-module/components/global-styles-sidebar/welcome-guide.js.map +1 -1
  655. package/build-module/components/header/back-button.js +7 -6
  656. package/build-module/components/header/back-button.js.map +1 -1
  657. package/build-module/components/header/index.js +4 -3
  658. package/build-module/components/header/index.js.map +1 -1
  659. package/build-module/components/index.js +3 -2
  660. package/build-module/components/index.js.map +1 -1
  661. package/build-module/components/inserter-sidebar/index.js +3 -2
  662. package/build-module/components/inserter-sidebar/index.js.map +1 -1
  663. package/build-module/components/keyboard-shortcut-help-modal/config.js +2 -1
  664. package/build-module/components/keyboard-shortcut-help-modal/config.js.map +1 -1
  665. package/build-module/components/keyboard-shortcut-help-modal/dynamic-shortcut.js +2 -1
  666. package/build-module/components/keyboard-shortcut-help-modal/dynamic-shortcut.js.map +1 -1
  667. package/build-module/components/keyboard-shortcut-help-modal/index.js +6 -5
  668. package/build-module/components/keyboard-shortcut-help-modal/index.js.map +1 -1
  669. package/build-module/components/keyboard-shortcut-help-modal/shortcut.js +5 -4
  670. package/build-module/components/keyboard-shortcut-help-modal/shortcut.js.map +1 -1
  671. package/build-module/components/list-view-sidebar/index.js +3 -2
  672. package/build-module/components/list-view-sidebar/index.js.map +1 -1
  673. package/build-module/components/list-view-sidebar/list-view-outline.js +2 -1
  674. package/build-module/components/list-view-sidebar/list-view-outline.js.map +1 -1
  675. package/build-module/components/local-autosave-monitor/index.js +5 -4
  676. package/build-module/components/local-autosave-monitor/index.js.map +1 -1
  677. package/build-module/components/media-categories/index.js +7 -6
  678. package/build-module/components/media-categories/index.js.map +1 -1
  679. package/build-module/components/mode-switcher/index.js +3 -2
  680. package/build-module/components/mode-switcher/index.js.map +1 -1
  681. package/build-module/components/more-menu/copy-content-menu-item.js +2 -1
  682. package/build-module/components/more-menu/copy-content-menu-item.js.map +1 -1
  683. package/build-module/components/more-menu/index.js +3 -2
  684. package/build-module/components/more-menu/index.js.map +2 -2
  685. package/build-module/components/more-menu/tools-more-menu-group.js +3 -2
  686. package/build-module/components/more-menu/tools-more-menu-group.js.map +1 -1
  687. package/build-module/components/more-menu/view-more-menu-group.js +3 -2
  688. package/build-module/components/more-menu/view-more-menu-group.js.map +1 -1
  689. package/build-module/components/page-attributes/check.js +1 -0
  690. package/build-module/components/page-attributes/check.js.map +1 -1
  691. package/build-module/components/page-attributes/order.js +2 -1
  692. package/build-module/components/page-attributes/order.js.map +1 -1
  693. package/build-module/components/page-attributes/panel.js +3 -2
  694. package/build-module/components/page-attributes/panel.js.map +1 -1
  695. package/build-module/components/page-attributes/parent.js +3 -2
  696. package/build-module/components/page-attributes/parent.js.map +1 -1
  697. package/build-module/components/pattern-duplicate-modal/index.js +4 -3
  698. package/build-module/components/pattern-duplicate-modal/index.js.map +1 -1
  699. package/build-module/components/pattern-overrides-panel/index.js +3 -2
  700. package/build-module/components/pattern-overrides-panel/index.js.map +1 -1
  701. package/build-module/components/pattern-rename-modal/index.js +4 -3
  702. package/build-module/components/pattern-rename-modal/index.js.map +1 -1
  703. package/build-module/components/plugin-document-setting-panel/index.js +4 -3
  704. package/build-module/components/plugin-document-setting-panel/index.js.map +1 -1
  705. package/build-module/components/plugin-more-menu-item/index.js +2 -1
  706. package/build-module/components/plugin-more-menu-item/index.js.map +1 -1
  707. package/build-module/components/plugin-post-publish-panel/index.js +4 -3
  708. package/build-module/components/plugin-post-publish-panel/index.js.map +1 -1
  709. package/build-module/components/plugin-post-status-info/index.js +4 -3
  710. package/build-module/components/plugin-post-status-info/index.js.map +1 -1
  711. package/build-module/components/plugin-pre-publish-panel/index.js +4 -3
  712. package/build-module/components/plugin-pre-publish-panel/index.js.map +1 -1
  713. package/build-module/components/plugin-preview-menu-item/index.js +2 -1
  714. package/build-module/components/plugin-preview-menu-item/index.js.map +1 -1
  715. package/build-module/components/plugin-sidebar/index.js +2 -1
  716. package/build-module/components/plugin-sidebar/index.js.map +1 -1
  717. package/build-module/components/plugin-sidebar-more-menu-item/index.js +2 -1
  718. package/build-module/components/plugin-sidebar-more-menu-item/index.js.map +1 -1
  719. package/build-module/components/post-actions/actions.js +2 -1
  720. package/build-module/components/post-actions/actions.js.map +1 -1
  721. package/build-module/components/post-actions/index.js +3 -2
  722. package/build-module/components/post-actions/index.js.map +1 -1
  723. package/build-module/components/post-actions/set-as-homepage.js +4 -3
  724. package/build-module/components/post-actions/set-as-homepage.js.map +1 -1
  725. package/build-module/components/post-actions/set-as-posts-page.js +4 -3
  726. package/build-module/components/post-actions/set-as-posts-page.js.map +1 -1
  727. package/build-module/components/post-author/check.js +2 -1
  728. package/build-module/components/post-author/check.js.map +1 -1
  729. package/build-module/components/post-author/combobox.js +2 -1
  730. package/build-module/components/post-author/combobox.js.map +1 -1
  731. package/build-module/components/post-author/constants.js +3 -2
  732. package/build-module/components/post-author/constants.js.map +1 -1
  733. package/build-module/components/post-author/hook.js +1 -0
  734. package/build-module/components/post-author/hook.js.map +1 -1
  735. package/build-module/components/post-author/index.js +3 -2
  736. package/build-module/components/post-author/index.js.map +1 -1
  737. package/build-module/components/post-author/panel.js +2 -1
  738. package/build-module/components/post-author/panel.js.map +1 -1
  739. package/build-module/components/post-author/select.js +2 -1
  740. package/build-module/components/post-author/select.js.map +1 -1
  741. package/build-module/components/post-card-panel/index.js +3 -2
  742. package/build-module/components/post-card-panel/index.js.map +1 -1
  743. package/build-module/components/post-comments/index.js +3 -2
  744. package/build-module/components/post-comments/index.js.map +1 -1
  745. package/build-module/components/post-content-information/index.js +3 -2
  746. package/build-module/components/post-content-information/index.js.map +1 -1
  747. package/build-module/components/post-discussion/panel.js +3 -2
  748. package/build-module/components/post-discussion/panel.js.map +1 -1
  749. package/build-module/components/post-excerpt/check.js +2 -1
  750. package/build-module/components/post-excerpt/check.js.map +1 -1
  751. package/build-module/components/post-excerpt/index.js +2 -1
  752. package/build-module/components/post-excerpt/index.js.map +1 -1
  753. package/build-module/components/post-excerpt/panel.js +3 -2
  754. package/build-module/components/post-excerpt/panel.js.map +1 -1
  755. package/build-module/components/post-excerpt/plugin.js +4 -3
  756. package/build-module/components/post-excerpt/plugin.js.map +1 -1
  757. package/build-module/components/post-featured-image/check.js +2 -1
  758. package/build-module/components/post-featured-image/check.js.map +1 -1
  759. package/build-module/components/post-featured-image/index.js +9 -8
  760. package/build-module/components/post-featured-image/index.js.map +1 -1
  761. package/build-module/components/post-featured-image/panel.js +3 -2
  762. package/build-module/components/post-featured-image/panel.js.map +1 -1
  763. package/build-module/components/post-fields/index.js +1 -0
  764. package/build-module/components/post-fields/index.js.map +1 -1
  765. package/build-module/components/post-format/check.js +2 -1
  766. package/build-module/components/post-format/check.js.map +1 -1
  767. package/build-module/components/post-format/index.js +3 -2
  768. package/build-module/components/post-format/index.js.map +1 -1
  769. package/build-module/components/post-format/panel.js +2 -1
  770. package/build-module/components/post-format/panel.js.map +1 -1
  771. package/build-module/components/post-last-edited-panel/index.js +2 -1
  772. package/build-module/components/post-last-edited-panel/index.js.map +1 -1
  773. package/build-module/components/post-last-revision/check.js +2 -1
  774. package/build-module/components/post-last-revision/check.js.map +1 -1
  775. package/build-module/components/post-last-revision/index.js +2 -1
  776. package/build-module/components/post-last-revision/index.js.map +1 -1
  777. package/build-module/components/post-last-revision/panel.js +2 -1
  778. package/build-module/components/post-last-revision/panel.js.map +1 -1
  779. package/build-module/components/post-locked-modal/index.js +2 -1
  780. package/build-module/components/post-locked-modal/index.js.map +1 -1
  781. package/build-module/components/post-panel-row/index.js +3 -2
  782. package/build-module/components/post-panel-row/index.js.map +1 -1
  783. package/build-module/components/post-panel-section/index.js +2 -1
  784. package/build-module/components/post-panel-section/index.js.map +1 -1
  785. package/build-module/components/post-pending-status/check.js +1 -0
  786. package/build-module/components/post-pending-status/check.js.map +1 -1
  787. package/build-module/components/post-pending-status/index.js +2 -1
  788. package/build-module/components/post-pending-status/index.js.map +1 -1
  789. package/build-module/components/post-pingbacks/index.js +2 -1
  790. package/build-module/components/post-pingbacks/index.js.map +1 -1
  791. package/build-module/components/post-preview-button/index.js +2 -1
  792. package/build-module/components/post-preview-button/index.js.map +1 -1
  793. package/build-module/components/post-publish-button/index.js +5 -4
  794. package/build-module/components/post-publish-button/index.js.map +1 -1
  795. package/build-module/components/post-publish-button/label.js +1 -0
  796. package/build-module/components/post-publish-button/label.js.map +1 -1
  797. package/build-module/components/post-publish-button/post-publish-button-or-toggle.js +4 -3
  798. package/build-module/components/post-publish-button/post-publish-button-or-toggle.js.map +1 -1
  799. package/build-module/components/post-publish-panel/index.js +4 -3
  800. package/build-module/components/post-publish-panel/index.js.map +1 -1
  801. package/build-module/components/post-publish-panel/maybe-category-panel.js +2 -1
  802. package/build-module/components/post-publish-panel/maybe-category-panel.js.map +1 -1
  803. package/build-module/components/post-publish-panel/maybe-post-format-panel.js +4 -3
  804. package/build-module/components/post-publish-panel/maybe-post-format-panel.js.map +1 -1
  805. package/build-module/components/post-publish-panel/maybe-tags-panel.js +4 -3
  806. package/build-module/components/post-publish-panel/maybe-tags-panel.js.map +1 -1
  807. package/build-module/components/post-publish-panel/maybe-upload-media.js +2 -1
  808. package/build-module/components/post-publish-panel/maybe-upload-media.js.map +1 -1
  809. package/build-module/components/post-publish-panel/media-util.js +1 -0
  810. package/build-module/components/post-publish-panel/media-util.js.map +1 -1
  811. package/build-module/components/post-publish-panel/postpublish.js +5 -4
  812. package/build-module/components/post-publish-panel/postpublish.js.map +1 -1
  813. package/build-module/components/post-publish-panel/prepublish.js +2 -1
  814. package/build-module/components/post-publish-panel/prepublish.js.map +1 -1
  815. package/build-module/components/post-saved-state/index.js +2 -1
  816. package/build-module/components/post-saved-state/index.js.map +1 -1
  817. package/build-module/components/post-schedule/check.js +1 -0
  818. package/build-module/components/post-schedule/check.js.map +1 -1
  819. package/build-module/components/post-schedule/index.js +3 -2
  820. package/build-module/components/post-schedule/index.js.map +1 -1
  821. package/build-module/components/post-schedule/label.js +1 -0
  822. package/build-module/components/post-schedule/label.js.map +1 -1
  823. package/build-module/components/post-schedule/panel.js +3 -2
  824. package/build-module/components/post-schedule/panel.js.map +1 -1
  825. package/build-module/components/post-status/index.js +5 -4
  826. package/build-module/components/post-status/index.js.map +1 -1
  827. package/build-module/components/post-sticky/check.js +1 -0
  828. package/build-module/components/post-sticky/check.js.map +1 -1
  829. package/build-module/components/post-sticky/index.js +2 -1
  830. package/build-module/components/post-sticky/index.js.map +1 -1
  831. package/build-module/components/post-sticky/panel.js +2 -1
  832. package/build-module/components/post-sticky/panel.js.map +1 -1
  833. package/build-module/components/post-switch-to-draft-button/index.js +2 -1
  834. package/build-module/components/post-switch-to-draft-button/index.js.map +1 -1
  835. package/build-module/components/post-sync-status/index.js +2 -1
  836. package/build-module/components/post-sync-status/index.js.map +1 -1
  837. package/build-module/components/post-taxonomies/check.js +1 -0
  838. package/build-module/components/post-taxonomies/check.js.map +1 -1
  839. package/build-module/components/post-taxonomies/flat-term-selector.js +8 -7
  840. package/build-module/components/post-taxonomies/flat-term-selector.js.map +1 -1
  841. package/build-module/components/post-taxonomies/hierarchical-term-selector.js +7 -6
  842. package/build-module/components/post-taxonomies/hierarchical-term-selector.js.map +1 -1
  843. package/build-module/components/post-taxonomies/index.js +3 -2
  844. package/build-module/components/post-taxonomies/index.js.map +1 -1
  845. package/build-module/components/post-taxonomies/most-used-terms.js +4 -3
  846. package/build-module/components/post-taxonomies/most-used-terms.js.map +1 -1
  847. package/build-module/components/post-taxonomies/panel.js +2 -1
  848. package/build-module/components/post-taxonomies/panel.js.map +1 -1
  849. package/build-module/components/post-template/block-theme.js +2 -1
  850. package/build-module/components/post-template/block-theme.js.map +1 -1
  851. package/build-module/components/post-template/classic-theme.js +2 -1
  852. package/build-module/components/post-template/classic-theme.js.map +1 -1
  853. package/build-module/components/post-template/create-new-template-modal.js +3 -2
  854. package/build-module/components/post-template/create-new-template-modal.js.map +1 -1
  855. package/build-module/components/post-template/create-new-template.js +2 -1
  856. package/build-module/components/post-template/create-new-template.js.map +1 -1
  857. package/build-module/components/post-template/hooks.js +1 -0
  858. package/build-module/components/post-template/hooks.js.map +1 -1
  859. package/build-module/components/post-template/panel.js +2 -1
  860. package/build-module/components/post-template/panel.js.map +1 -1
  861. package/build-module/components/post-template/reset-default-template.js +2 -1
  862. package/build-module/components/post-template/reset-default-template.js.map +1 -1
  863. package/build-module/components/post-template/swap-template-button.js +2 -1
  864. package/build-module/components/post-template/swap-template-button.js.map +1 -1
  865. package/build-module/components/post-text-editor/index.js +2 -1
  866. package/build-module/components/post-text-editor/index.js.map +1 -1
  867. package/build-module/components/post-title/constants.js +3 -2
  868. package/build-module/components/post-title/constants.js.map +1 -1
  869. package/build-module/components/post-title/index.js +3 -2
  870. package/build-module/components/post-title/index.js.map +1 -1
  871. package/build-module/components/post-title/post-title-raw.js +2 -1
  872. package/build-module/components/post-title/post-title-raw.js.map +1 -1
  873. package/build-module/components/post-title/use-post-title-focus.js +1 -0
  874. package/build-module/components/post-title/use-post-title-focus.js.map +1 -1
  875. package/build-module/components/post-title/use-post-title.js +1 -0
  876. package/build-module/components/post-title/use-post-title.js.map +1 -1
  877. package/build-module/components/post-transform-panel/hooks.js +2 -1
  878. package/build-module/components/post-transform-panel/hooks.js.map +1 -1
  879. package/build-module/components/post-transform-panel/index.js +2 -1
  880. package/build-module/components/post-transform-panel/index.js.map +1 -1
  881. package/build-module/components/post-trash/check.js +1 -0
  882. package/build-module/components/post-trash/check.js.map +1 -1
  883. package/build-module/components/post-trash/index.js +2 -1
  884. package/build-module/components/post-trash/index.js.map +1 -1
  885. package/build-module/components/post-type-support-check/index.js +1 -0
  886. package/build-module/components/post-type-support-check/index.js.map +1 -1
  887. package/build-module/components/post-url/check.js +1 -0
  888. package/build-module/components/post-url/check.js.map +1 -1
  889. package/build-module/components/post-url/index.js +2 -1
  890. package/build-module/components/post-url/index.js.map +1 -1
  891. package/build-module/components/post-url/label.js +1 -0
  892. package/build-module/components/post-url/label.js.map +1 -1
  893. package/build-module/components/post-url/panel.js +2 -1
  894. package/build-module/components/post-url/panel.js.map +1 -1
  895. package/build-module/components/post-view-link/index.js +2 -1
  896. package/build-module/components/post-view-link/index.js.map +1 -1
  897. package/build-module/components/post-visibility/check.js +1 -0
  898. package/build-module/components/post-visibility/check.js.map +1 -1
  899. package/build-module/components/post-visibility/index.js +2 -1
  900. package/build-module/components/post-visibility/index.js.map +1 -1
  901. package/build-module/components/post-visibility/label.js +1 -0
  902. package/build-module/components/post-visibility/label.js.map +1 -1
  903. package/build-module/components/post-visibility/utils.js +2 -1
  904. package/build-module/components/post-visibility/utils.js.map +1 -1
  905. package/build-module/components/posts-per-page/index.js +2 -1
  906. package/build-module/components/posts-per-page/index.js.map +1 -1
  907. package/build-module/components/preferences-modal/enable-panel.js +3 -2
  908. package/build-module/components/preferences-modal/enable-panel.js.map +1 -1
  909. package/build-module/components/preferences-modal/enable-plugin-document-setting-panel.js +4 -3
  910. package/build-module/components/preferences-modal/enable-plugin-document-setting-panel.js.map +1 -1
  911. package/build-module/components/preferences-modal/enable-publish-sidebar.js +3 -2
  912. package/build-module/components/preferences-modal/enable-publish-sidebar.js.map +1 -1
  913. package/build-module/components/preferences-modal/index.js +4 -3
  914. package/build-module/components/preferences-modal/index.js.map +2 -2
  915. package/build-module/components/preview-dropdown/index.js +2 -1
  916. package/build-module/components/preview-dropdown/index.js.map +1 -1
  917. package/build-module/components/provider/disable-non-page-content-blocks.js +1 -0
  918. package/build-module/components/provider/disable-non-page-content-blocks.js.map +1 -1
  919. package/build-module/components/provider/index.js +7 -6
  920. package/build-module/components/provider/index.js.map +1 -1
  921. package/build-module/components/provider/navigation-block-editing-mode.js +1 -0
  922. package/build-module/components/provider/navigation-block-editing-mode.js.map +1 -1
  923. package/build-module/components/provider/use-auto-switch-editor-sidebars.js +1 -0
  924. package/build-module/components/provider/use-auto-switch-editor-sidebars.js.map +1 -1
  925. package/build-module/components/provider/use-block-editor-settings.js +4 -3
  926. package/build-module/components/provider/use-block-editor-settings.js.map +1 -1
  927. package/build-module/components/provider/use-hide-blocks-from-inserter.js +2 -1
  928. package/build-module/components/provider/use-hide-blocks-from-inserter.js.map +1 -1
  929. package/build-module/components/provider/use-post-content-blocks.js +2 -1
  930. package/build-module/components/provider/use-post-content-blocks.js.map +1 -1
  931. package/build-module/components/provider/with-registry-provider.js +3 -2
  932. package/build-module/components/provider/with-registry-provider.js.map +1 -1
  933. package/build-module/components/resizable-editor/index.js +3 -2
  934. package/build-module/components/resizable-editor/index.js.map +1 -1
  935. package/build-module/components/resizable-editor/resize-handle.js +3 -2
  936. package/build-module/components/resizable-editor/resize-handle.js.map +1 -1
  937. package/build-module/components/save-publish-panels/index.js +4 -3
  938. package/build-module/components/save-publish-panels/index.js.map +1 -1
  939. package/build-module/components/sidebar/constants.js +2 -1
  940. package/build-module/components/sidebar/constants.js.map +1 -1
  941. package/build-module/components/sidebar/header.js +4 -3
  942. package/build-module/components/sidebar/header.js.map +1 -1
  943. package/build-module/components/sidebar/index.js +6 -5
  944. package/build-module/components/sidebar/index.js.map +1 -1
  945. package/build-module/components/sidebar/post-summary.js +3 -2
  946. package/build-module/components/sidebar/post-summary.js.map +1 -1
  947. package/build-module/components/site-discussion/index.js +3 -2
  948. package/build-module/components/site-discussion/index.js.map +1 -1
  949. package/build-module/components/start-page-options/index.js +7 -7
  950. package/build-module/components/start-page-options/index.js.map +2 -2
  951. package/build-module/components/start-template-options/index.js +2 -1
  952. package/build-module/components/start-template-options/index.js.map +1 -1
  953. package/build-module/components/style-book/categories.js +1 -0
  954. package/build-module/components/style-book/categories.js.map +1 -1
  955. package/build-module/components/style-book/color-examples.js +3 -2
  956. package/build-module/components/style-book/color-examples.js.map +1 -1
  957. package/build-module/components/style-book/constants.js +8 -7
  958. package/build-module/components/style-book/constants.js.map +1 -1
  959. package/build-module/components/style-book/duotone-examples.js +3 -2
  960. package/build-module/components/style-book/duotone-examples.js.map +1 -1
  961. package/build-module/components/style-book/examples.js +2 -1
  962. package/build-module/components/style-book/examples.js.map +1 -1
  963. package/build-module/components/style-book/index.js +12 -11
  964. package/build-module/components/style-book/index.js.map +1 -1
  965. package/build-module/components/styles-canvas/index.js +2 -1
  966. package/build-module/components/styles-canvas/index.js.map +1 -1
  967. package/build-module/components/styles-canvas/revisions.js +3 -2
  968. package/build-module/components/styles-canvas/revisions.js.map +1 -1
  969. package/build-module/components/styles-canvas/style-book.js +2 -1
  970. package/build-module/components/styles-canvas/style-book.js.map +1 -1
  971. package/build-module/components/table-of-contents/index.js +2 -1
  972. package/build-module/components/table-of-contents/index.js.map +1 -1
  973. package/build-module/components/table-of-contents/panel.js +2 -1
  974. package/build-module/components/table-of-contents/panel.js.map +1 -1
  975. package/build-module/components/template-content-panel/index.js +5 -4
  976. package/build-module/components/template-content-panel/index.js.map +1 -1
  977. package/build-module/components/template-part-content-panel/index.js +3 -2
  978. package/build-module/components/template-part-content-panel/index.js.map +1 -1
  979. package/build-module/components/template-part-menu-items/convert-to-regular.js +2 -1
  980. package/build-module/components/template-part-menu-items/convert-to-regular.js.map +1 -1
  981. package/build-module/components/template-part-menu-items/convert-to-template-part.js +2 -1
  982. package/build-module/components/template-part-menu-items/convert-to-template-part.js.map +1 -1
  983. package/build-module/components/template-part-menu-items/index.js +2 -1
  984. package/build-module/components/template-part-menu-items/index.js.map +1 -1
  985. package/build-module/components/template-validation-notice/index.js +2 -1
  986. package/build-module/components/template-validation-notice/index.js.map +1 -1
  987. package/build-module/components/text-editor/index.js +2 -1
  988. package/build-module/components/text-editor/index.js.map +1 -1
  989. package/build-module/components/theme-support-check/index.js +1 -0
  990. package/build-module/components/theme-support-check/index.js.map +1 -1
  991. package/build-module/components/time-to-read/index.js +3 -2
  992. package/build-module/components/time-to-read/index.js.map +1 -1
  993. package/build-module/components/unsaved-changes-warning/index.js +1 -0
  994. package/build-module/components/unsaved-changes-warning/index.js.map +1 -1
  995. package/build-module/components/visual-editor/edit-template-blocks-notification.js +2 -1
  996. package/build-module/components/visual-editor/edit-template-blocks-notification.js.map +1 -1
  997. package/build-module/components/visual-editor/index.js +24 -12
  998. package/build-module/components/visual-editor/index.js.map +2 -2
  999. package/build-module/components/visual-editor/use-select-nearest-editable-block.js +2 -1
  1000. package/build-module/components/visual-editor/use-select-nearest-editable-block.js.map +1 -1
  1001. package/build-module/components/visual-editor/use-zoom-out-mode-exit.js +1 -0
  1002. package/build-module/components/visual-editor/use-zoom-out-mode-exit.js.map +1 -1
  1003. package/build-module/components/word-count/index.js +2 -1
  1004. package/build-module/components/word-count/index.js.map +1 -1
  1005. package/build-module/components/zoom-out-toggle/index.js +3 -2
  1006. package/build-module/components/zoom-out-toggle/index.js.map +1 -1
  1007. package/build-module/dataviews/api.js +1 -0
  1008. package/build-module/dataviews/api.js.map +1 -1
  1009. package/build-module/dataviews/fields/content-preview/content-preview-view.js +3 -2
  1010. package/build-module/dataviews/fields/content-preview/content-preview-view.js.map +1 -1
  1011. package/build-module/dataviews/fields/content-preview/index.js +2 -1
  1012. package/build-module/dataviews/fields/content-preview/index.js.map +1 -1
  1013. package/build-module/dataviews/store/private-actions.js +2 -1
  1014. package/build-module/dataviews/store/private-actions.js.map +1 -1
  1015. package/build-module/dataviews/store/private-selectors.js +2 -1
  1016. package/build-module/dataviews/store/private-selectors.js.map +1 -1
  1017. package/build-module/dataviews/store/reducer.js +1 -0
  1018. package/build-module/dataviews/store/reducer.js.map +1 -1
  1019. package/build-module/hooks/custom-sources-backwards-compatibility.js +3 -2
  1020. package/build-module/hooks/custom-sources-backwards-compatibility.js.map +1 -1
  1021. package/build-module/hooks/default-autocompleters.js +1 -0
  1022. package/build-module/hooks/default-autocompleters.js.map +1 -1
  1023. package/build-module/hooks/index.js +1 -0
  1024. package/build-module/hooks/index.js.map +1 -1
  1025. package/build-module/hooks/media-upload.js +2 -1
  1026. package/build-module/hooks/media-upload.js.map +1 -1
  1027. package/build-module/hooks/navigation-link-view-button.js +4 -3
  1028. package/build-module/hooks/navigation-link-view-button.js.map +1 -1
  1029. package/build-module/hooks/pattern-overrides.js +4 -3
  1030. package/build-module/hooks/pattern-overrides.js.map +1 -1
  1031. package/build-module/hooks/push-changes-to-global-styles/index.js +11 -10
  1032. package/build-module/hooks/push-changes-to-global-styles/index.js.map +1 -1
  1033. package/build-module/hooks/template-part-navigation-edit-button.js +6 -5
  1034. package/build-module/hooks/template-part-navigation-edit-button.js.map +1 -1
  1035. package/build-module/hooks/use-global-styles-output.js +1 -0
  1036. package/build-module/hooks/use-global-styles-output.js.map +1 -1
  1037. package/build-module/index.js +1 -0
  1038. package/build-module/index.js.map +1 -1
  1039. package/build-module/lock-unlock.js +2 -1
  1040. package/build-module/lock-unlock.js.map +1 -1
  1041. package/build-module/private-apis.js +3 -2
  1042. package/build-module/private-apis.js.map +1 -1
  1043. package/build-module/store/actions.js +52 -51
  1044. package/build-module/store/actions.js.map +1 -1
  1045. package/build-module/store/constants.js +14 -13
  1046. package/build-module/store/constants.js.map +1 -1
  1047. package/build-module/store/defaults.js +2 -1
  1048. package/build-module/store/defaults.js.map +1 -1
  1049. package/build-module/store/index.js +3 -2
  1050. package/build-module/store/index.js.map +1 -1
  1051. package/build-module/store/local-autosave.js +1 -0
  1052. package/build-module/store/local-autosave.js.map +1 -1
  1053. package/build-module/store/private-actions.js +15 -7
  1054. package/build-module/store/private-actions.js.map +2 -2
  1055. package/build-module/store/private-selectors.js +13 -8
  1056. package/build-module/store/private-selectors.js.map +2 -2
  1057. package/build-module/store/reducer.js +10 -0
  1058. package/build-module/store/reducer.js.map +2 -2
  1059. package/build-module/store/selectors.js +79 -78
  1060. package/build-module/store/selectors.js.map +2 -2
  1061. package/build-module/store/utils/is-template-revertable.js +1 -0
  1062. package/build-module/store/utils/is-template-revertable.js.map +1 -1
  1063. package/build-module/store/utils/notice-builder.js +1 -0
  1064. package/build-module/store/utils/notice-builder.js.map +1 -1
  1065. package/build-module/utils/get-item-title.js +1 -0
  1066. package/build-module/utils/get-item-title.js.map +1 -1
  1067. package/build-module/utils/get-template-info.js +3 -2
  1068. package/build-module/utils/get-template-info.js.map +1 -1
  1069. package/build-module/utils/get-template-part-icon.js +1 -0
  1070. package/build-module/utils/get-template-part-icon.js.map +1 -1
  1071. package/build-module/utils/index.js +1 -0
  1072. package/build-module/utils/index.js.map +1 -1
  1073. package/build-module/utils/media-sideload/index.js +2 -1
  1074. package/build-module/utils/media-sideload/index.js.map +1 -1
  1075. package/build-module/utils/media-upload/index.js +2 -1
  1076. package/build-module/utils/media-upload/index.js.map +1 -1
  1077. package/build-module/utils/pageTypeBadge.js +1 -0
  1078. package/build-module/utils/pageTypeBadge.js.map +1 -1
  1079. package/build-module/utils/search-templates.js +1 -0
  1080. package/build-module/utils/search-templates.js.map +1 -1
  1081. package/build-module/utils/set-nested-value.js +1 -0
  1082. package/build-module/utils/set-nested-value.js.map +1 -1
  1083. package/build-module/utils/terms.js +4 -3
  1084. package/build-module/utils/terms.js.map +1 -1
  1085. package/build-module/utils/url.js +1 -0
  1086. package/build-module/utils/url.js.map +1 -1
  1087. package/build-style/style-rtl.css +9 -45
  1088. package/build-style/style.css +9 -45
  1089. package/build-types/bindings/post-data.d.ts +18 -8
  1090. package/build-types/bindings/post-meta.d.ts +1 -7
  1091. package/build-types/components/collab-sidebar/add-comment.d.ts +3 -3
  1092. package/build-types/components/collab-sidebar/add-comment.d.ts.map +1 -1
  1093. package/build-types/components/collab-sidebar/comment-indicator-toolbar.d.ts.map +1 -1
  1094. package/build-types/components/collab-sidebar/comment-menu-item.d.ts +3 -2
  1095. package/build-types/components/collab-sidebar/comment-menu-item.d.ts.map +1 -1
  1096. package/build-types/components/collab-sidebar/comments.d.ts +4 -4
  1097. package/build-types/components/collab-sidebar/comments.d.ts.map +1 -1
  1098. package/build-types/components/collab-sidebar/hooks.d.ts.map +1 -1
  1099. package/build-types/components/collab-sidebar/index.d.ts.map +1 -1
  1100. package/build-types/components/collab-sidebar/utils.d.ts.map +1 -1
  1101. package/build-types/components/start-page-options/index.d.ts.map +1 -1
  1102. package/build-types/components/visual-editor/index.d.ts.map +1 -1
  1103. package/build-types/store/private-actions.d.ts +7 -0
  1104. package/build-types/store/private-actions.d.ts.map +1 -1
  1105. package/build-types/store/private-selectors.d.ts +7 -0
  1106. package/build-types/store/private-selectors.d.ts.map +1 -1
  1107. package/build-types/store/reducer.d.ts +10 -0
  1108. package/build-types/store/reducer.d.ts.map +1 -1
  1109. package/build-types/store/selectors.d.ts.map +1 -1
  1110. package/package.json +40 -40
  1111. package/src/bindings/post-data.js +63 -111
  1112. package/src/bindings/post-meta.js +55 -46
  1113. package/src/bindings/test/post-meta.js +211 -0
  1114. package/src/components/collab-sidebar/add-comment.js +20 -11
  1115. package/src/components/collab-sidebar/comment-author-info.js +1 -1
  1116. package/src/components/collab-sidebar/comment-indicator-toolbar.js +19 -29
  1117. package/src/components/collab-sidebar/comment-menu-item.js +51 -11
  1118. package/src/components/collab-sidebar/comments.js +87 -53
  1119. package/src/components/collab-sidebar/hooks.js +6 -4
  1120. package/src/components/collab-sidebar/index.js +75 -37
  1121. package/src/components/collab-sidebar/style.scss +7 -46
  1122. package/src/components/collab-sidebar/utils.js +3 -2
  1123. package/src/components/editor/index.js +1 -1
  1124. package/src/components/more-menu/index.js +1 -1
  1125. package/src/components/preferences-modal/index.js +1 -1
  1126. package/src/components/start-page-options/index.js +5 -6
  1127. package/src/components/start-page-options/style.scss +1 -1
  1128. package/src/components/visual-editor/index.js +27 -6
  1129. package/src/store/private-actions.js +13 -0
  1130. package/src/store/private-selectors.js +10 -0
  1131. package/src/store/reducer.js +16 -0
  1132. package/src/store/selectors.js +0 -2
  1133. package/tsconfig.tsbuildinfo +1 -1
@@ -1,4 +1,4 @@
1
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
1
+ // packages/editor/src/components/post-publish-panel/postpublish.js
2
2
  import {
3
3
  PanelBody,
4
4
  Button,
@@ -16,9 +16,10 @@ import { store as coreStore } from "@wordpress/core-data";
16
16
  import { external } from "@wordpress/icons";
17
17
  import PostScheduleLabel from "../post-schedule/label";
18
18
  import { store as editorStore } from "../../store";
19
- const POSTNAME = "%postname%";
20
- const PAGENAME = "%pagename%";
21
- const getFuturePostUrl = (post) => {
19
+ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
20
+ var POSTNAME = "%postname%";
21
+ var PAGENAME = "%pagename%";
22
+ var getFuturePostUrl = (post) => {
22
23
  const { slug } = post;
23
24
  if (post.permalink_template.includes(POSTNAME)) {
24
25
  return post.permalink_template.replace(POSTNAME, slug);
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-publish-panel/postpublish.js"],
4
4
  "sourcesContent": ["/**\n * WordPress dependencies\n */\nimport {\n\tPanelBody,\n\tButton,\n\tTextControl,\n\tExternalLink,\n\tVisuallyHidden,\n} from '@wordpress/components';\nimport { __, sprintf } from '@wordpress/i18n';\nimport { useCallback, useEffect, useState, useRef } from '@wordpress/element';\nimport { useSelect } from '@wordpress/data';\nimport { addQueryArgs, safeDecodeURIComponent } from '@wordpress/url';\nimport { decodeEntities } from '@wordpress/html-entities';\nimport { useCopyToClipboard } from '@wordpress/compose';\nimport { store as coreStore } from '@wordpress/core-data';\nimport { external } from '@wordpress/icons';\n\n/**\n * Internal dependencies\n */\nimport PostScheduleLabel from '../post-schedule/label';\nimport { store as editorStore } from '../../store';\n\nconst POSTNAME = '%postname%';\nconst PAGENAME = '%pagename%';\n\n/**\n * Returns URL for a future post.\n *\n * @param {Object} post Post object.\n *\n * @return {string} PostPublish URL.\n */\n\nconst getFuturePostUrl = ( post ) => {\n\tconst { slug } = post;\n\n\tif ( post.permalink_template.includes( POSTNAME ) ) {\n\t\treturn post.permalink_template.replace( POSTNAME, slug );\n\t}\n\n\tif ( post.permalink_template.includes( PAGENAME ) ) {\n\t\treturn post.permalink_template.replace( PAGENAME, slug );\n\t}\n\n\treturn post.permalink_template;\n};\n\nfunction CopyButton( { text } ) {\n\tconst [ showCopyConfirmation, setShowCopyConfirmation ] = useState( false );\n\tconst timeoutIdRef = useRef();\n\tconst ref = useCopyToClipboard( text, () => {\n\t\tsetShowCopyConfirmation( true );\n\t\tif ( timeoutIdRef.current ) {\n\t\t\tclearTimeout( timeoutIdRef.current );\n\t\t}\n\t\ttimeoutIdRef.current = setTimeout( () => {\n\t\t\tsetShowCopyConfirmation( false );\n\t\t}, 4000 );\n\t} );\n\n\tuseEffect( () => {\n\t\treturn () => {\n\t\t\tif ( timeoutIdRef.current ) {\n\t\t\t\tclearTimeout( timeoutIdRef.current );\n\t\t\t}\n\t\t};\n\t}, [] );\n\n\treturn (\n\t\t<Button __next40pxDefaultSize variant=\"secondary\" ref={ ref }>\n\t\t\t{ showCopyConfirmation ? __( 'Copied!' ) : __( 'Copy' ) }\n\t\t</Button>\n\t);\n}\n\nexport default function PostPublishPanelPostpublish( {\n\tfocusOnMount,\n\tchildren,\n} ) {\n\tconst { post, postType, isScheduled } = useSelect( ( select ) => {\n\t\tconst {\n\t\t\tgetEditedPostAttribute,\n\t\t\tgetCurrentPost,\n\t\t\tisCurrentPostScheduled,\n\t\t} = select( editorStore );\n\t\tconst { getPostType } = select( coreStore );\n\n\t\treturn {\n\t\t\tpost: getCurrentPost(),\n\t\t\tpostType: getPostType( getEditedPostAttribute( 'type' ) ),\n\t\t\tisScheduled: isCurrentPostScheduled(),\n\t\t};\n\t}, [] );\n\n\tconst postLabel = postType?.labels?.singular_name;\n\tconst viewPostLabel = postType?.labels?.view_item;\n\tconst addNewPostLabel = postType?.labels?.add_new_item;\n\tconst link =\n\t\tpost.status === 'future' ? getFuturePostUrl( post ) : post.link;\n\tconst addLink = addQueryArgs( 'post-new.php', {\n\t\tpost_type: post.type,\n\t} );\n\n\tconst postLinkRef = useCallback(\n\t\t( node ) => {\n\t\t\tif ( focusOnMount && node ) {\n\t\t\t\tnode.focus();\n\t\t\t}\n\t\t},\n\t\t[ focusOnMount ]\n\t);\n\n\tconst postPublishNonLinkHeader = isScheduled ? (\n\t\t<>\n\t\t\t{ __( 'is now scheduled. It will go live on' ) }{ ' ' }\n\t\t\t<PostScheduleLabel />.\n\t\t</>\n\t) : (\n\t\t__( 'is now live.' )\n\t);\n\n\treturn (\n\t\t<div className=\"post-publish-panel__postpublish\">\n\t\t\t<PanelBody className=\"post-publish-panel__postpublish-header\">\n\t\t\t\t<ExternalLink ref={ postLinkRef } href={ link }>\n\t\t\t\t\t{ decodeEntities( post.title ) || __( '(no title)' ) }\n\t\t\t\t</ExternalLink>{ ' ' }\n\t\t\t\t{ postPublishNonLinkHeader }\n\t\t\t</PanelBody>\n\t\t\t<PanelBody>\n\t\t\t\t<p className=\"post-publish-panel__postpublish-subheader\">\n\t\t\t\t\t<strong>{ __( 'What\u2019s next?' ) }</strong>\n\t\t\t\t</p>\n\t\t\t\t<div className=\"post-publish-panel__postpublish-post-address-container\">\n\t\t\t\t\t<TextControl\n\t\t\t\t\t\t__next40pxDefaultSize\n\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t\tclassName=\"post-publish-panel__postpublish-post-address\"\n\t\t\t\t\t\treadOnly\n\t\t\t\t\t\tlabel={ sprintf(\n\t\t\t\t\t\t\t/* translators: %s: post type singular name */\n\t\t\t\t\t\t\t__( '%s address' ),\n\t\t\t\t\t\t\tpostLabel\n\t\t\t\t\t\t) }\n\t\t\t\t\t\tvalue={ safeDecodeURIComponent( link ) }\n\t\t\t\t\t\tonFocus={ ( event ) => event.target.select() }\n\t\t\t\t\t/>\n\n\t\t\t\t\t<div className=\"post-publish-panel__postpublish-post-address__copy-button-wrap\">\n\t\t\t\t\t\t<CopyButton text={ link } />\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\n\t\t\t\t<div className=\"post-publish-panel__postpublish-buttons\">\n\t\t\t\t\t{ ! isScheduled && (\n\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\tvariant=\"primary\"\n\t\t\t\t\t\t\thref={ link }\n\t\t\t\t\t\t\t__next40pxDefaultSize\n\t\t\t\t\t\t\ticon={ external }\n\t\t\t\t\t\t\ticonPosition=\"right\"\n\t\t\t\t\t\t\ttarget=\"_blank\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ viewPostLabel }\n\t\t\t\t\t\t\t<VisuallyHidden as=\"span\">\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t/* translators: accessibility text */\n\t\t\t\t\t\t\t\t\t__( '(opens in a new tab)' )\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t</VisuallyHidden>\n\t\t\t\t\t\t</Button>\n\t\t\t\t\t) }\n\t\t\t\t\t<Button\n\t\t\t\t\t\tvariant={ isScheduled ? 'primary' : 'secondary' }\n\t\t\t\t\t\t__next40pxDefaultSize\n\t\t\t\t\t\thref={ addLink }\n\t\t\t\t\t>\n\t\t\t\t\t\t{ addNewPostLabel }\n\t\t\t\t\t</Button>\n\t\t\t\t</div>\n\t\t\t</PanelBody>\n\t\t\t{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d,8BAAC,cAAW,MAAO,MAAO,GAC3B;AAAA,SACD;AAAA,MAEA,qBAAC,SAAI,WAAU,2CACZ;AAAA,SAAE,eACH;AAAA,UAAC;AAAA;AAAA,YACA,SAAQ;AAAA,YACR,MAAO;AAAA,YACP,uBAAqB;AAAA,YACrB,MAAO;AAAA,YACP,cAAa;AAAA,YACb,QAAO;AAAA,YAEL;AAAA;AAAA,cACF,oBAAC;AAAA,gBAAe,IAAG;AAAA;AAAA,gBAGjB,aAAI,sBAAuB;AAAA,eAE7B;AAAA;AAAA;AAAA,QACD;AAAA,QAED;AAAA,UAAC;AAAA;AAAA,YACA,SAAU,cAAc,YAAY;AAAA,YACpC,uBAAqB;AAAA,YACrB,MAAO;AAAA,YAEL;AAAA;AAAA,QACH;AAAA,SACD;AAAA,OACD;AAAA,IACE;AAAA,KACH;AAEF;",
6
6
  "names": []
7
7
  }
@@ -1,4 +1,4 @@
1
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
1
+ // packages/editor/src/components/post-publish-panel/prepublish.js
2
2
  import { __ } from "@wordpress/i18n";
3
3
  import { Icon, PanelBody } from "@wordpress/components";
4
4
  import { useSelect } from "@wordpress/data";
@@ -15,6 +15,7 @@ import MaybePostFormatPanel from "./maybe-post-format-panel";
15
15
  import { store as editorStore } from "../../store";
16
16
  import MaybeCategoryPanel from "./maybe-category-panel";
17
17
  import MaybeUploadMedia from "./maybe-upload-media";
18
+ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
18
19
  function PostPublishPanelPrepublish({ children }) {
19
20
  const {
20
21
  isBeingScheduled,
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-publish-panel/prepublish.js"],
4
4
  "sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { Icon, PanelBody } from '@wordpress/components';\nimport { useSelect } from '@wordpress/data';\nimport { wordpress } from '@wordpress/icons';\nimport { filterURLForDisplay } from '@wordpress/url';\nimport { store as coreStore } from '@wordpress/core-data';\nimport { decodeEntities } from '@wordpress/html-entities';\n\n/**\n * Internal dependencies\n */\nimport PostVisibility from '../post-visibility';\nimport PostVisibilityLabel from '../post-visibility/label';\nimport PostSchedule from '../post-schedule';\nimport PostScheduleLabel from '../post-schedule/label';\nimport MaybeTagsPanel from './maybe-tags-panel';\nimport MaybePostFormatPanel from './maybe-post-format-panel';\nimport { store as editorStore } from '../../store';\nimport MaybeCategoryPanel from './maybe-category-panel';\nimport MaybeUploadMedia from './maybe-upload-media';\n\nfunction PostPublishPanelPrepublish( { children } ) {\n\tconst {\n\t\tisBeingScheduled,\n\t\tisRequestingSiteIcon,\n\t\thasPublishAction,\n\t\tsiteIconUrl,\n\t\tsiteTitle,\n\t\tsiteHome,\n\t} = useSelect( ( select ) => {\n\t\tconst { getCurrentPost, isEditedPostBeingScheduled } =\n\t\t\tselect( editorStore );\n\t\tconst { getEntityRecord, isResolving } = select( coreStore );\n\t\tconst siteData =\n\t\t\tgetEntityRecord( 'root', '__unstableBase', undefined ) || {};\n\n\t\treturn {\n\t\t\thasPublishAction:\n\t\t\t\tgetCurrentPost()._links?.[ 'wp:action-publish' ] ?? false,\n\t\t\tisBeingScheduled: isEditedPostBeingScheduled(),\n\t\t\tisRequestingSiteIcon: isResolving( 'getEntityRecord', [\n\t\t\t\t'root',\n\t\t\t\t'__unstableBase',\n\t\t\t\tundefined,\n\t\t\t] ),\n\t\t\tsiteIconUrl: siteData.site_icon_url,\n\t\t\tsiteTitle: siteData.name,\n\t\t\tsiteHome: siteData.home && filterURLForDisplay( siteData.home ),\n\t\t};\n\t}, [] );\n\n\tlet siteIcon = (\n\t\t<Icon className=\"components-site-icon\" size=\"36px\" icon={ wordpress } />\n\t);\n\n\tif ( siteIconUrl ) {\n\t\tsiteIcon = (\n\t\t\t<img\n\t\t\t\talt={ __( 'Site Icon' ) }\n\t\t\t\tclassName=\"components-site-icon\"\n\t\t\t\tsrc={ siteIconUrl }\n\t\t\t/>\n\t\t);\n\t}\n\n\tif ( isRequestingSiteIcon ) {\n\t\tsiteIcon = null;\n\t}\n\n\tlet prePublishTitle, prePublishBodyText;\n\n\tif ( ! hasPublishAction ) {\n\t\tprePublishTitle = __( 'Are you ready to submit for review?' );\n\t\tprePublishBodyText = __(\n\t\t\t'Your work will be reviewed and then approved.'\n\t\t);\n\t} else if ( isBeingScheduled ) {\n\t\tprePublishTitle = __( 'Are you ready to schedule?' );\n\t\tprePublishBodyText = __(\n\t\t\t'Your work will be published at the specified date and time.'\n\t\t);\n\t} else {\n\t\tprePublishTitle = __( 'Are you ready to publish?' );\n\t\tprePublishBodyText = __(\n\t\t\t'Double-check your settings before publishing.'\n\t\t);\n\t}\n\n\treturn (\n\t\t<div className=\"editor-post-publish-panel__prepublish\">\n\t\t\t<div>\n\t\t\t\t<strong>{ prePublishTitle }</strong>\n\t\t\t</div>\n\t\t\t<p>{ prePublishBodyText }</p>\n\t\t\t<div className=\"components-site-card\">\n\t\t\t\t{ siteIcon }\n\t\t\t\t<div className=\"components-site-info\">\n\t\t\t\t\t<span className=\"components-site-name\">\n\t\t\t\t\t\t{ decodeEntities( siteTitle ) || __( '(Untitled)' ) }\n\t\t\t\t\t</span>\n\t\t\t\t\t<span className=\"components-site-home\">{ siteHome }</span>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<MaybeUploadMedia />\n\t\t\t{ hasPublishAction && (\n\t\t\t\t<>\n\t\t\t\t\t<PanelBody\n\t\t\t\t\t\tinitialOpen={ false }\n\t\t\t\t\t\ttitle={ [\n\t\t\t\t\t\t\t__( 'Visibility:' ),\n\t\t\t\t\t\t\t<span\n\t\t\t\t\t\t\t\tclassName=\"editor-post-publish-panel__link\"\n\t\t\t\t\t\t\t\tkey=\"label\"\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t<PostVisibilityLabel />\n\t\t\t\t\t\t\t</span>,\n\t\t\t\t\t\t] }\n\t\t\t\t\t>\n\t\t\t\t\t\t<PostVisibility />\n\t\t\t\t\t</PanelBody>\n\t\t\t\t\t<PanelBody\n\t\t\t\t\t\tinitialOpen={ false }\n\t\t\t\t\t\ttitle={ [\n\t\t\t\t\t\t\t__( 'Publish:' ),\n\t\t\t\t\t\t\t<span\n\t\t\t\t\t\t\t\tclassName=\"editor-post-publish-panel__link\"\n\t\t\t\t\t\t\t\tkey=\"label\"\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t<PostScheduleLabel />\n\t\t\t\t\t\t\t</span>,\n\t\t\t\t\t\t] }\n\t\t\t\t\t>\n\t\t\t\t\t\t<PostSchedule />\n\t\t\t\t\t</PanelBody>\n\t\t\t\t</>\n\t\t\t) }\n\t\t\t<MaybePostFormatPanel />\n\t\t\t<MaybeTagsPanel />\n\t\t\t<MaybeCategoryPanel />\n\t\t\t{ children }\n\t\t</div>\n\t);\n}\n\nexport default PostPublishPanelPrepublish;\n"],
5
- "mappings": "AAuDE,SAqDE,UArDF,KA4CE,YA5CF;AApDF,SAAS,UAAU;AACnB,SAAS,MAAM,iBAAiB;AAChC,SAAS,iBAAiB;AAC1B,SAAS,iBAAiB;AAC1B,SAAS,2BAA2B;AACpC,SAAS,SAAS,iBAAiB;AACnC,SAAS,sBAAsB;AAK/B,OAAO,oBAAoB;AAC3B,OAAO,yBAAyB;AAChC,OAAO,kBAAkB;AACzB,OAAO,uBAAuB;AAC9B,OAAO,oBAAoB;AAC3B,OAAO,0BAA0B;AACjC,SAAS,SAAS,mBAAmB;AACrC,OAAO,wBAAwB;AAC/B,OAAO,sBAAsB;AAE7B,SAAS,2BAA4B,EAAE,SAAS,GAAI;AACnD,QAAM;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACD,IAAI,UAAW,CAAE,WAAY;AAC5B,UAAM,EAAE,gBAAgB,2BAA2B,IAClD,OAAQ,WAAY;AACrB,UAAM,EAAE,iBAAiB,YAAY,IAAI,OAAQ,SAAU;AAC3D,UAAM,WACL,gBAAiB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AC,SAAI,WAAU,wBACd;AAAA,4BAAC,UAAK,WAAU,wBACb,yBAAgB,SAAU,KAAK,GAAI,YAAa,GACnD;AAAA,QACA,oBAAC,UAAK,WAAU,wBAAyB,oBAAU;AAAA,SACpD;AAAA,OACD;AAAA,IACA,oBAAC,oBAAiB;AAAA,IAChB,oBACD,iCACC;AAAA;AAAA,QAAC;AAAA;AAAA,UACA,aAAc;AAAA,UACd,OAAQ;AAAA,YACP,GAAI,aAAc;AAAA,YAClB;AAAA,cAAC;AAAA;AAAA,gBACA,WAAU;AAAA,gBAGV,8BAAC,uBAAoB;AAAA;AAAA,cAFjB;AAAA,YAGL;AAAA,UACD;AAAA,UAEA,8BAAC,kBAAe;AAAA;AAAA,MACjB;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACA,aAAc;AAAA,UACd,OAAQ;AAAA,YACP,GAAI,UAAW;AAAA,YACf;AAAA,cAAC;AAAA;AAAA,gBACA,WAAU;AAAA,gBAGV,8BAAC,qBAAkB;AAAA;AAAA,cAFf;AAAA,YAGL;AAAA,UACD;AAAA,UAEA,8BAAC,gBAAa;AAAA;AAAA,MACf;AAAA,OACD;AAAA,IAED,oBAAC,wBAAqB;AAAA,IACtB,oBAAC,kBAAe;AAAA,IAChB,oBAAC,sBAAmB;AAAA,IAClB;AAAA,KACH;AAEF;AAEA,IAAO,qBAAQ;",
6
6
  "names": []
7
7
  }
@@ -1,4 +1,4 @@
1
- import { jsx, jsxs } from "react/jsx-runtime";
1
+ // packages/editor/src/components/post-saved-state/index.js
2
2
  import clsx from "clsx";
3
3
  import {
4
4
  __unstableGetAnimateClassName as getAnimateClassName,
@@ -13,6 +13,7 @@ import { displayShortcut } from "@wordpress/keycodes";
13
13
  import { store as preferencesStore } from "@wordpress/preferences";
14
14
  import { STATUS_OPTIONS } from "../../components/post-status";
15
15
  import { store as editorStore } from "../../store";
16
+ import { jsx, jsxs } from "react/jsx-runtime";
16
17
  function PostSavedState({ forceIsDirty }) {
17
18
  const [forceSavedMessage, setForceSavedMessage] = useState(false);
18
19
  const isLargeViewport = useViewportMatch("small");
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-saved-state/index.js"],
4
4
  "sourcesContent": ["/**\n * External dependencies\n */\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport {\n\t__unstableGetAnimateClassName as getAnimateClassName,\n\tButton,\n} from '@wordpress/components';\nimport { usePrevious, useViewportMatch } from '@wordpress/compose';\nimport { useDispatch, useSelect } from '@wordpress/data';\nimport { useEffect, useState } from '@wordpress/element';\nimport { __ } from '@wordpress/i18n';\nimport { Icon, check, cloud, cloudUpload } from '@wordpress/icons';\nimport { displayShortcut } from '@wordpress/keycodes';\nimport { store as preferencesStore } from '@wordpress/preferences';\n\n/**\n * Internal dependencies\n */\nimport { STATUS_OPTIONS } from '../../components/post-status';\nimport { store as editorStore } from '../../store';\n\n/**\n * Component showing whether the post is saved or not and providing save\n * buttons.\n *\n * @param {Object} props Component props.\n * @param {?boolean} props.forceIsDirty Whether to force the post to be marked\n * as dirty.\n * @return {import('react').ComponentType} The component.\n */\nexport default function PostSavedState( { forceIsDirty } ) {\n\tconst [ forceSavedMessage, setForceSavedMessage ] = useState( false );\n\tconst isLargeViewport = useViewportMatch( 'small' );\n\n\tconst {\n\t\tisAutosaving,\n\t\tisDirty,\n\t\tisNew,\n\t\tisPublished,\n\t\tisSaveable,\n\t\tisSaving,\n\t\tisScheduled,\n\t\thasPublishAction,\n\t\tshowIconLabels,\n\t\tpostStatus,\n\t\tpostStatusHasChanged,\n\t} = useSelect(\n\t\t( select ) => {\n\t\t\tconst {\n\t\t\t\tisEditedPostNew,\n\t\t\t\tisCurrentPostPublished,\n\t\t\t\tisCurrentPostScheduled,\n\t\t\t\tisEditedPostDirty,\n\t\t\t\tisSavingPost,\n\t\t\t\tisEditedPostSaveable,\n\t\t\t\tgetCurrentPost,\n\t\t\t\tisAutosavingPost,\n\t\t\t\tgetEditedPostAttribute,\n\t\t\t\tgetPostEdits,\n\t\t\t} = select( editorStore );\n\t\t\tconst { get } = select( preferencesStore );\n\t\t\treturn {\n\t\t\t\tisAutosaving: isAutosavingPost(),\n\t\t\t\tisDirty: forceIsDirty || isEditedPostDirty(),\n\t\t\t\tisNew: isEditedPostNew(),\n\t\t\t\tisPublished: isCurrentPostPublished(),\n\t\t\t\tisSaving: isSavingPost(),\n\t\t\t\tisSaveable: isEditedPostSaveable(),\n\t\t\t\tisScheduled: isCurrentPostScheduled(),\n\t\t\t\thasPublishAction:\n\t\t\t\t\tgetCurrentPost()?._links?.[ 'wp:action-publish' ] ?? false,\n\t\t\t\tshowIconLabels: get( 'core', 'showIconLabels' ),\n\t\t\t\tpostStatus: getEditedPostAttribute( 'status' ),\n\t\t\t\tpostStatusHasChanged: !! getPostEdits()?.status,\n\t\t\t};\n\t\t},\n\t\t[ forceIsDirty ]\n\t);\n\tconst isPending = postStatus === 'pending';\n\tconst { savePost } = useDispatch( editorStore );\n\n\tconst wasSaving = usePrevious( isSaving );\n\n\tuseEffect( () => {\n\t\tlet timeoutId;\n\n\t\tif ( wasSaving && ! isSaving ) {\n\t\t\tsetForceSavedMessage( true );\n\t\t\ttimeoutId = setTimeout( () => {\n\t\t\t\tsetForceSavedMessage( false );\n\t\t\t}, 1000 );\n\t\t}\n\n\t\treturn () => clearTimeout( timeoutId );\n\t}, [ isSaving ] );\n\n\t// Once the post has been submitted for review this button\n\t// is not needed for the contributor role.\n\tif ( ! hasPublishAction && isPending ) {\n\t\treturn null;\n\t}\n\n\t// We shouldn't render the button if the post has not one of the following statuses: pending, draft, auto-draft.\n\t// The reason for this is that this button handles the `save as pending` and `save draft` actions.\n\t// An exception for this is when the post has a custom status and there should be a way to save changes without\n\t// having to publish. This should be handled better in the future when custom statuses have better support.\n\t// @see https://github.com/WordPress/gutenberg/issues/3144.\n\tconst isIneligibleStatus =\n\t\t! [ 'pending', 'draft', 'auto-draft' ].includes( postStatus ) &&\n\t\tSTATUS_OPTIONS.map( ( { value } ) => value ).includes( postStatus );\n\n\tif (\n\t\tisPublished ||\n\t\tisScheduled ||\n\t\tisIneligibleStatus ||\n\t\t( postStatusHasChanged &&\n\t\t\t[ 'pending', 'draft' ].includes( postStatus ) )\n\t) {\n\t\treturn null;\n\t}\n\n\t/* translators: button label text should, if possible, be under 16 characters. */\n\tconst label = isPending ? __( 'Save as pending' ) : __( 'Save draft' );\n\n\t/* translators: button label text should, if possible, be under 16 characters. */\n\tconst shortLabel = __( 'Save' );\n\n\tconst isSaved = forceSavedMessage || ( ! isNew && ! isDirty );\n\tconst isSavedState = isSaving || isSaved;\n\tconst isDisabled = isSaving || isSaved || ! isSaveable;\n\tlet text;\n\n\tif ( isSaving ) {\n\t\ttext = isAutosaving ? __( 'Autosaving' ) : __( 'Saving' );\n\t} else if ( isSaved ) {\n\t\ttext = __( 'Saved' );\n\t} else if ( isLargeViewport ) {\n\t\ttext = label;\n\t} else if ( showIconLabels ) {\n\t\ttext = shortLabel;\n\t}\n\n\t// Use common Button instance for all saved states so that focus is not\n\t// lost.\n\treturn (\n\t\t<Button\n\t\t\tclassName={\n\t\t\t\tisSaveable || isSaving\n\t\t\t\t\t? clsx( {\n\t\t\t\t\t\t\t'editor-post-save-draft': ! isSavedState,\n\t\t\t\t\t\t\t'editor-post-saved-state': isSavedState,\n\t\t\t\t\t\t\t'is-saving': isSaving,\n\t\t\t\t\t\t\t'is-autosaving': isAutosaving,\n\t\t\t\t\t\t\t'is-saved': isSaved,\n\t\t\t\t\t\t\t[ getAnimateClassName( {\n\t\t\t\t\t\t\t\ttype: 'loading',\n\t\t\t\t\t\t\t} ) ]: isSaving,\n\t\t\t\t\t } )\n\t\t\t\t\t: undefined\n\t\t\t}\n\t\t\tonClick={ isDisabled ? undefined : () => savePost() }\n\t\t\t/*\n\t\t\t * We want the tooltip to show the keyboard shortcut only when the\n\t\t\t * button does something, i.e. when it's not disabled.\n\t\t\t */\n\t\t\tshortcut={ isDisabled ? undefined : displayShortcut.primary( 's' ) }\n\t\t\tvariant=\"tertiary\"\n\t\t\tsize=\"compact\"\n\t\t\ticon={ isLargeViewport ? undefined : cloudUpload }\n\t\t\tlabel={ text || label }\n\t\t\taria-disabled={ isDisabled }\n\t\t>\n\t\t\t{ isSavedState && <Icon icon={ isSaved ? check : cloud } /> }\n\t\t\t{ text }\n\t\t</Button>\n\t);\n}\n"],
5
- "mappings": "AAsJE,SA2BmB,KA3BnB;AAnJF,OAAO,UAAU;AAKjB;AAAA,EACC,iCAAiC;AAAA,EACjC;AAAA,OACM;AACP,SAAS,aAAa,wBAAwB;AAC9C,SAAS,aAAa,iBAAiB;AACvC,SAAS,WAAW,gBAAgB;AACpC,SAAS,UAAU;AACnB,SAAS,MAAM,OAAO,OAAO,mBAAmB;AAChD,SAAS,uBAAuB;AAChC,SAAS,SAAS,wBAAwB;AAK1C,SAAS,sBAAsB;AAC/B,SAAS,SAAS,mBAAmB;AAWtB,SAAR,eAAiC,EAAE,aAAa,GAAI;AAC1D,QAAM,CAAE,mBAAmB,oBAAqB,IAAI,SAAU,KAAM;AACpE,QAAM,kBAAkB,iBAAkB,OAAQ;AAElD,QAAM;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACD,IAAI;AAAA,IACH,CAAE,WAAY;AACb,YAAM;AAAA,QACL;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,QACA;AAAA,MACD,IAAI,OAAQ,WAAY;AACxB,YAAM,EAAE,IAAI,IAAI,OAAQ,gBAAiB;AACzC,aAAO;AAAA,QACN,cAAc,iBAAiB;AAAA,QAC/B,SAAS,gBAAgB,kBAAkB;AAAA,QAC3C,OAAO,gBAAgB;AAAA,QACvB,aAAa,uBAAuB;AAAA,QACpC,UAAU,aAAa;AAAA,QACvB,YAA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BACD,CAAE,WAAW,OAAQ,EAAE,SAAU,UAAW,GAC5C;AACD,WAAO;AAAA,EACR;AAGA,QAAM,QAAQ,YAAY,GAAI,iBAAkB,IAAI,GAAI,YAAa;AAGrE,QAAM,aAAa,GAAI,MAAO;AAE9B,QAAM,UAAU,qBAAuB,CAAE,SAAS,CAAE;AACpD,QAAM,eAAe,YAAY;AACjC,QAAM,aAAa,YAAY,WAAW,CAAE;AAC5C,MAAI;AAEJ,MAAK,UAAW;AACf,WAAO,eAAe,GAAI,YAAa,IAAI,GAAI,QAAS;AAAA,EACzD,WAAY,SAAU;AACrB,WAAO,GAAI,OAAQ;AAAA,EACpB,WAAY,iBAAkB;AAC7B,WAAO;AAAA,EACR,WAAY,gBAAiB;AAC5B,WAAO;AAAA,EACR;AAIA,SACC;AAAA,IAAC;AAAA;AAAA,MACA,WACC,cAAc,WACX,KAAM;AAAA,QACN,0BAA0B,CAAE;AAAA,QAC5B,2BAA2B;AAAA,QAC3B,aAAa;AAAA,QACb,iBAAiB;AAAA,QACjB,YAAY;AAAA,QACZ,CAAE,oBAAqB;AAAA,UACtB,MAAM;AAAA,QACP,CAAE,CAAE,GAAG;AAAA,MACP,CAAE,IACF;AAAA,MAEJ,SAAU,aAAa,SAAY,MAAM,SAAS;AAAA,MAKlD,UAAW,aAAa,SAAY,gBAAgB,QAAS,GAAI;AAAA,MACjE,SAAQ;AAAA,MACR,MAAK;AAAA,MACL,MAAO,kBAAkB,SAAY;AAAA,MACrC,OAAQ,QAAQ;AAAA,MAChB,iBAAgB;AAAA,MAEd;AAAA,wBAAgB,oBAAC,QAAK,MAAO,UAAU,QAAQ,OAAQ;AAAA,QACvD;AAAA;AAAA;AAAA,EACH;AAEF;",
6
6
  "names": []
7
7
  }
@@ -1,3 +1,4 @@
1
+ // packages/editor/src/components/post-schedule/check.js
1
2
  import { useSelect } from "@wordpress/data";
2
3
  import { store as editorStore } from "../../store";
3
4
  function PostScheduleCheck({ children }) {
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-schedule/check.js"],
4
4
  "sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { useSelect } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport { store as editorStore } from '../../store';\n\n/**\n * Wrapper component that renders its children only if post has a publish action.\n *\n * @param {Object} props Props.\n * @param {React.ReactNode} props.children Children to be rendered.\n *\n * @return {React.ReactNode} - The component to be rendered or null if there is no publish action.\n */\nexport default function PostScheduleCheck( { children } ) {\n\tconst hasPublishAction = useSelect( ( select ) => {\n\t\treturn (\n\t\t\tselect( editorStore ).getCurrentPost()._links?.[\n\t\t\t\t'wp:action-publish'\n\t\t\t] ?? false\n\t\t);\n\t}, [] );\n\n\tif ( ! hasPublishAction ) {\n\t\treturn null;\n\t}\n\n\treturn children;\n}\n"],
5
- "mappings": "AAGA,SAAS,iBAAiB;AAK1B,SAAS,SAAS,mBAAmB;AAUtB,SAAR,kBAAoC,EAAE,SAAS,GAAI;AACzD,QAAM,mBAAmB,UAAW,CAAE,WAAY;AACjD,WACC,OAAQ,WAAY,EAAE,eAAe,EAAE,SACtC,mBACD,KAAK;AAAA,EAEP,GAAG,CAAC,CAAE;AAEN,MAAK,CAAE,kBAAmB;AACzB,WAAO;AAAA,EACR;AAEA,SAAO;AACR;",
5
+ "mappings": ";AAGA,SAAS,iBAAiB;AAK1B,SAAS,SAAS,mBAAmB;AAUtB,SAAR,kBAAoC,EAAE,SAAS,GAAI;AACzD,QAAM,mBAAmB,UAAW,CAAE,WAAY;AACjD,WACC,OAAQ,WAAY,EAAE,eAAe,EAAE,SACtC,mBACD,KAAK;AAAA,EAEP,GAAG,CAAC,CAAE;AAEN,MAAK,CAAE,kBAAmB;AACzB,WAAO;AAAA,EACR;AAEA,SAAO;AACR;",
6
6
  "names": []
7
7
  }
@@ -1,4 +1,4 @@
1
- import { jsx } from "react/jsx-runtime";
1
+ // packages/editor/src/components/post-schedule/index.js
2
2
  import { parseISO, endOfMonth, startOfMonth } from "date-fns";
3
3
  import { getSettings } from "@wordpress/date";
4
4
  import { _x } from "@wordpress/i18n";
@@ -8,7 +8,8 @@ import { useState, useMemo } from "@wordpress/element";
8
8
  import { store as coreStore } from "@wordpress/core-data";
9
9
  import { store as editorStore } from "../../store";
10
10
  import { unlock } from "../../lock-unlock";
11
- const { PrivatePublishDateTimePicker } = unlock(blockEditorPrivateApis);
11
+ import { jsx } from "react/jsx-runtime";
12
+ var { PrivatePublishDateTimePicker } = unlock(blockEditorPrivateApis);
12
13
  function PostSchedule(props) {
13
14
  return /* @__PURE__ */ jsx(
14
15
  PrivatePostSchedule,
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-schedule/index.js"],
4
4
  "sourcesContent": ["/**\n * External dependencies\n */\nimport { parseISO, endOfMonth, startOfMonth } from 'date-fns';\n\n/**\n * WordPress dependencies\n */\nimport { getSettings } from '@wordpress/date';\nimport { _x } from '@wordpress/i18n';\nimport { useDispatch, useSelect } from '@wordpress/data';\nimport { privateApis as blockEditorPrivateApis } from '@wordpress/block-editor';\nimport { useState, useMemo } from '@wordpress/element';\nimport { store as coreStore } from '@wordpress/core-data';\n\n/**\n * Internal dependencies\n */\nimport { store as editorStore } from '../../store';\nimport { unlock } from '../../lock-unlock';\n\nconst { PrivatePublishDateTimePicker } = unlock( blockEditorPrivateApis );\n\n/**\n * Renders the PostSchedule component. It allows the user to schedule a post.\n *\n * @param {Object} props Props.\n * @param {Function} props.onClose Function to close the component.\n *\n * @return {React.ReactNode} The rendered component.\n */\nexport default function PostSchedule( props ) {\n\treturn (\n\t\t<PrivatePostSchedule\n\t\t\t{ ...props }\n\t\t\tshowPopoverHeaderActions\n\t\t\tisCompact={ false }\n\t\t/>\n\t);\n}\n\nexport function PrivatePostSchedule( {\n\tonClose,\n\tshowPopoverHeaderActions,\n\tisCompact,\n} ) {\n\tconst { postDate, postType } = useSelect(\n\t\t( select ) => ( {\n\t\t\tpostDate: select( editorStore ).getEditedPostAttribute( 'date' ),\n\t\t\tpostType: select( editorStore ).getCurrentPostType(),\n\t\t} ),\n\t\t[]\n\t);\n\n\tconst { editPost } = useDispatch( editorStore );\n\tconst onUpdateDate = ( date ) => editPost( { date } );\n\n\tconst [ previewedMonth, setPreviewedMonth ] = useState(\n\t\tstartOfMonth( new Date( postDate ) )\n\t);\n\n\t// Pick up published and scheduled site posts.\n\tconst eventsByPostType = useSelect(\n\t\t( select ) =>\n\t\t\tselect( coreStore ).getEntityRecords( 'postType', postType, {\n\t\t\t\tstatus: 'publish,future',\n\t\t\t\tafter: startOfMonth( previewedMonth ).toISOString(),\n\t\t\t\tbefore: endOfMonth( previewedMonth ).toISOString(),\n\t\t\t\texclude: [ select( editorStore ).getCurrentPostId() ],\n\t\t\t\tper_page: 100,\n\t\t\t\t_fields: 'id,date',\n\t\t\t} ),\n\t\t[ previewedMonth, postType ]\n\t);\n\n\tconst events = useMemo(\n\t\t() =>\n\t\t\t( eventsByPostType || [] ).map( ( { date: eventDate } ) => ( {\n\t\t\t\tdate: new Date( eventDate ),\n\t\t\t} ) ),\n\t\t[ eventsByPostType ]\n\t);\n\n\tconst settings = getSettings();\n\n\t// To know if the current timezone is a 12 hour time with look for \"a\" in the time format\n\t// We also make sure this a is not escaped by a \"/\"\n\tconst is12HourTime = /a(?!\\\\)/i.test(\n\t\tsettings.formats.time\n\t\t\t.toLowerCase() // Test only the lower case a.\n\t\t\t.replace( /\\\\\\\\/g, '' ) // Replace \"//\" with empty strings.\n\t\t\t.split( '' )\n\t\t\t.reverse()\n\t\t\t.join( '' ) // Reverse the string and test for \"a\" not followed by a slash.\n\t);\n\n\treturn (\n\t\t<PrivatePublishDateTimePicker\n\t\t\tcurrentDate={ postDate }\n\t\t\tonChange={ onUpdateDate }\n\t\t\tis12Hour={ is12HourTime }\n\t\t\tdateOrder={\n\t\t\t\t/* translators: Order of day, month, and year. Available formats are 'dmy', 'mdy', and 'ymd'. */\n\t\t\t\t_x( 'dmy', 'date order' )\n\t\t\t}\n\t\t\tevents={ events }\n\t\t\tonMonthPreviewed={ ( date ) =>\n\t\t\t\tsetPreviewedMonth( parseISO( date ) )\n\t\t\t}\n\t\t\tonClose={ onClose }\n\t\t\tisCompact={ isCompact }\n\t\t\tshowPopoverHeaderActions={ showPopoverHeaderActions }\n\t\t/>\n\t);\n}\n"],
5
- "mappings": "AAiCE;AA9BF,SAAS,UAAU,YAAY,oBAAoB;AAKnD,SAAS,mBAAmB;AAC5B,SAAS,UAAU;AACnB,SAAS,aAAa,iBAAiB;AACvC,SAAS,eAAe,8BAA8B;AACtD,SAAS,UAAU,eAAe;AAClC,SAAS,SAAS,iBAAiB;AAKnC,SAAS,SAAS,mBAAmB;AACrC,SAAS,cAAc;AAEvB,MAAM,EAAE,6BAA6B,IAAI,OAAQ,sBAAuB;AAUzD,SAAR,aAA+B,OAAQ;AAC7C,SACC;AAAA,IAAC;AAAA;AAAA,MACE,GAAG;AAAA,MACL,0BAAwB;AAAA,MACxB,WAAY;AAAA;AAAA,EACb;AAEF;AAEO,SAAS,oBAAqB;AAAA,EACpC;AAAA,EACA;AAAA,EACA;AACD,GAAI;AACH,QAAM,EAAE,UAAU,SAAS,IAAI;AAAA,IAC9B,CAAE,YAAc;AAAA,MACf,UAAU,OAAQ,WAAY,EAAE,uBAAwB,MAAO;AAAA,MAC/D,UAAU,OAAQ,WAAY,EAAE,mBAAmB;AAAA,IACpD;AAAA,IACA,CAAC;AAAA,EACF;AAEA,QAAM,EAAE,SAAS,IAAI,YAAa,WAAY;AAC9C,QAAM,eAAe,CAAE,SAAU,SAAU,EAAE,KAAK,CAAE;AAEpD,QAAM,CAAE,gBAAgB,iBAAkB,IAAI;AAAA,IAC7C,aAAc,IAAI,KAAM,QAAS,CAAE;AAAA,EACpC;AAGA,QAAM,mBAAmB;AAAA,IACxB,CAAE,WACD,OAAQ,SAAU,EAAE,iBAAkB,YAAY,UAAU;AAAA,MAC3D,QAAQ;AAAA,MACR,OAAO,aAAc,cAAe,EAAE,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d,UAAW;AAAA,MACX,UAAW;AAAA,MACX;AAAA;AAAA,QAEC,GAAI,OAAO,YAAa;AAAA;AAAA,MAEzB;AAAA,MACA,kBAAmB,CAAE,SACpB,kBAAmB,SAAU,IAAK,CAAE;AAAA,MAErC;AAAA,MACA;AAAA,MACA;AAAA;AAAA,EACD;AAEF;",
6
6
  "names": []
7
7
  }
@@ -1,3 +1,4 @@
1
+ // packages/editor/src/components/post-schedule/label.js
1
2
  import { __, _x, sprintf, isRTL } from "@wordpress/i18n";
2
3
  import { getSettings, getDate, dateI18n } from "@wordpress/date";
3
4
  import { useSelect } from "@wordpress/data";
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-schedule/label.js"],
4
4
  "sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { __, _x, sprintf, isRTL } from '@wordpress/i18n';\nimport { getSettings, getDate, dateI18n } from '@wordpress/date';\nimport { useSelect } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport { store as editorStore } from '../../store';\n\n/**\n * Renders the PostScheduleLabel component.\n *\n * @param {Object} props Props.\n *\n * @return {React.ReactNode} The rendered component.\n */\nexport default function PostScheduleLabel( props ) {\n\treturn usePostScheduleLabel( props );\n}\n\n/**\n * Custom hook to get the label for post schedule.\n *\n * @param {Object} options Options for the hook.\n * @param {boolean} options.full Whether to get the full label or not. Default is false.\n *\n * @return {string} The label for post schedule.\n */\nexport function usePostScheduleLabel( { full = false } = {} ) {\n\tconst { date, isFloating } = useSelect(\n\t\t( select ) => ( {\n\t\t\tdate: select( editorStore ).getEditedPostAttribute( 'date' ),\n\t\t\tisFloating: select( editorStore ).isEditedPostDateFloating(),\n\t\t} ),\n\t\t[]\n\t);\n\n\treturn full\n\t\t? getFullPostScheduleLabel( date )\n\t\t: getPostScheduleLabel( date, { isFloating } );\n}\n\nexport function getFullPostScheduleLabel( dateAttribute ) {\n\tconst date = getDate( dateAttribute );\n\n\tconst timezoneAbbreviation = getTimezoneAbbreviation();\n\tconst formattedDate = dateI18n(\n\t\t// translators: Use a non-breaking space between 'g:i' and 'a' if appropriate.\n\t\t_x( 'F j, Y g:i\\xa0a', 'post schedule full date format' ),\n\t\tdate\n\t);\n\treturn isRTL()\n\t\t? `${ timezoneAbbreviation } ${ formattedDate }`\n\t\t: `${ formattedDate } ${ timezoneAbbreviation }`;\n}\n\nexport function getPostScheduleLabel(\n\tdateAttribute,\n\t{ isFloating = false, now = new Date() } = {}\n) {\n\tif ( ! dateAttribute || isFloating ) {\n\t\treturn __( 'Immediately' );\n\t}\n\n\t// If the user timezone does not equal the site timezone then using words\n\t// like 'tomorrow' is confusing, so show the full date.\n\tif ( ! isTimezoneSameAsSiteTimezone( now ) ) {\n\t\treturn getFullPostScheduleLabel( dateAttribute );\n\t}\n\n\tconst date = getDate( dateAttribute );\n\n\tif ( isSameDay( date, now ) ) {\n\t\treturn sprintf(\n\t\t\t// translators: %s: Time of day the post is scheduled for.\n\t\t\t__( 'Today at %s' ),\n\t\t\t// translators: If using a space between 'g:i' and 'a', use a non-breaking space.\n\t\t\tdateI18n( _x( 'g:i\\xa0a', 'post schedule time format' ), date )\n\t\t);\n\t}\n\n\tconst tomorrow = new Date( now );\n\ttomorrow.setDate( tomorrow.getDate() + 1 );\n\n\tif ( isSameDay( date, tomorrow ) ) {\n\t\treturn sprintf(\n\t\t\t// translators: %s: Time of day the post is scheduled for.\n\t\t\t__( 'Tomorrow at %s' ),\n\t\t\t// translators: If using a space between 'g:i' and 'a', use a non-breaking space.\n\t\t\tdateI18n( _x( 'g:i\\xa0a', 'post schedule time format' ), date )\n\t\t);\n\t}\n\n\tif ( date.getFullYear() === now.getFullYear() ) {\n\t\treturn dateI18n(\n\t\t\t// translators: If using a space between 'g:i' and 'a', use a non-breaking space.\n\t\t\t_x( 'F j g:i\\xa0a', 'post schedule date format without year' ),\n\t\t\tdate\n\t\t);\n\t}\n\n\treturn dateI18n(\n\t\t// translators: Use a non-breaking space between 'g:i' and 'a' if appropriate.\n\t\t_x( 'F j, Y g:i\\xa0a', 'post schedule full date format' ),\n\t\tdate\n\t);\n}\n\nfunction getTimezoneAbbreviation() {\n\tconst { timezone } = getSettings();\n\n\tif ( timezone.abbr && isNaN( Number( timezone.abbr ) ) ) {\n\t\treturn timezone.abbr;\n\t}\n\n\tconst symbol = timezone.offset < 0 ? '' : '+';\n\treturn `UTC${ symbol }${ timezone.offsetFormatted }`;\n}\n\nfunction isTimezoneSameAsSiteTimezone( date ) {\n\tconst { timezone } = getSettings();\n\n\tconst siteOffset = Number( timezone.offset );\n\tconst dateOffset = -1 * ( date.getTimezoneOffset() / 60 );\n\treturn siteOffset === dateOffset;\n}\n\nfunction isSameDay( left, right ) {\n\treturn (\n\t\tleft.getDate() === right.getDate() &&\n\t\tleft.getMonth() === right.getMonth() &&\n\t\tleft.getFullYear() === right.getFullYear()\n\t);\n}\n"],
5
- "mappings": "AAGA,SAAS,IAAI,IAAI,SAAS,aAAa;AACvC,SAAS,aAAa,SAAS,gBAAgB;AAC/C,SAAS,iBAAiB;AAK1B,SAAS,SAAS,mBAAmB;AAStB,SAAR,kBAAoC,OAAQ;AAClD,SAAO,qBAAsB,KAAM;AACpC;AAUO,SAAS,qBAAsB,EAAE,OAAO,MAAM,IAAI,CAAC,GAAI;AAC7D,QAAM,EAAE,MAAM,WAAW,IAAI;AAAA,IAC5B,CAAE,YAAc;AAAA,MACf,MAAM,OAAQ,WAAY,EAAE,uBAAwB,MAAO;AAAA,MAC3D,YAAY,OAAQ,WAAY,EAAE,yBAAyB;AAAA,IAC5D;AAAA,IACA,CAAC;AAAA,EACF;AAEA,SAAO,OACJ,yBAA0B,IAAK,IAC/B,qBAAsB,MAAM,EAAE,WAAW,CAAE;AAC/C;AAEO,SAAS,yBAA0B,eAAgB;AACzD,QAAM,OAAO,QAAS,aAAc;AAEpC,QAAM,uBAAuB,wBAAwB;AACrD,QAAM,gBAAgB;AAAA;AAAA,IAErB,GAAI,mBAAmB,gCAAiC;AAAA,IACxD;AA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AAM,MAAM,QAAQ,KACjC,KAAK,SAAS,MAAM,MAAM,SAAS,KACnC,KAAK,YAAY,MAAM,MAAM,YAAY;AAE3C;",
6
6
  "names": []
7
7
  }
@@ -1,4 +1,4 @@
1
- import { jsx } from "react/jsx-runtime";
1
+ // packages/editor/src/components/post-schedule/panel.js
2
2
  import { Button, Dropdown } from "@wordpress/components";
3
3
  import { __, sprintf } from "@wordpress/i18n";
4
4
  import { useState, useMemo } from "@wordpress/element";
@@ -14,7 +14,8 @@ import {
14
14
  PATTERN_POST_TYPE,
15
15
  NAVIGATION_POST_TYPE
16
16
  } from "../../store/constants";
17
- const DESIGN_POST_TYPES = [
17
+ import { jsx } from "react/jsx-runtime";
18
+ var DESIGN_POST_TYPES = [
18
19
  TEMPLATE_POST_TYPE,
19
20
  TEMPLATE_PART_POST_TYPE,
20
21
  PATTERN_POST_TYPE,
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-schedule/panel.js"],
4
4
  "sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { Button, Dropdown } from '@wordpress/components';\nimport { __, sprintf } from '@wordpress/i18n';\nimport { useState, useMemo } from '@wordpress/element';\nimport { useSelect } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport PostScheduleCheck from './check';\nimport PostScheduleForm from './index';\nimport { usePostScheduleLabel } from './label';\nimport PostPanelRow from '../post-panel-row';\nimport { store as editorStore } from '../../store';\nimport {\n\tTEMPLATE_POST_TYPE,\n\tTEMPLATE_PART_POST_TYPE,\n\tPATTERN_POST_TYPE,\n\tNAVIGATION_POST_TYPE,\n} from '../../store/constants';\n\nconst DESIGN_POST_TYPES = [\n\tTEMPLATE_POST_TYPE,\n\tTEMPLATE_PART_POST_TYPE,\n\tPATTERN_POST_TYPE,\n\tNAVIGATION_POST_TYPE,\n];\n\n/**\n * Renders the Post Schedule Panel component.\n *\n * @return {React.ReactNode} The rendered component.\n */\nexport default function PostSchedulePanel() {\n\tconst [ popoverAnchor, setPopoverAnchor ] = useState( null );\n\tconst postType = useSelect(\n\t\t( select ) => select( editorStore ).getCurrentPostType(),\n\t\t[]\n\t);\n\t// Memoize popoverProps to avoid returning a new object every time.\n\tconst popoverProps = useMemo(\n\t\t() => ( {\n\t\t\t// Anchor the popover to the middle of the entire row so that it doesn't\n\t\t\t// move around when the label changes.\n\t\t\tanchor: popoverAnchor,\n\t\t\t'aria-label': __( 'Change publish date' ),\n\t\t\tplacement: 'left-start',\n\t\t\toffset: 36,\n\t\t\tshift: true,\n\t\t} ),\n\t\t[ popoverAnchor ]\n\t);\n\n\tconst label = usePostScheduleLabel();\n\tconst fullLabel = usePostScheduleLabel( { full: true } );\n\tif ( DESIGN_POST_TYPES.includes( postType ) ) {\n\t\treturn null;\n\t}\n\n\treturn (\n\t\t<PostScheduleCheck>\n\t\t\t<PostPanelRow label={ __( 'Publish' ) } ref={ setPopoverAnchor }>\n\t\t\t\t<Dropdown\n\t\t\t\t\tpopoverProps={ popoverProps }\n\t\t\t\t\tfocusOnMount\n\t\t\t\t\tclassName=\"editor-post-schedule__panel-dropdown\"\n\t\t\t\t\tcontentClassName=\"editor-post-schedule__dialog\"\n\t\t\t\t\trenderToggle={ ( { onToggle, isOpen } ) => (\n\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\tsize=\"compact\"\n\t\t\t\t\t\t\tclassName=\"editor-post-schedule__dialog-toggle\"\n\t\t\t\t\t\t\tvariant=\"tertiary\"\n\t\t\t\t\t\t\ttooltipPosition=\"middle left\"\n\t\t\t\t\t\t\tonClick={ onToggle }\n\t\t\t\t\t\t\taria-label={ sprintf(\n\t\t\t\t\t\t\t\t// translators: %s: Current post date.\n\t\t\t\t\t\t\t\t__( 'Change date: %s' ),\n\t\t\t\t\t\t\t\tlabel\n\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\tlabel={ fullLabel }\n\t\t\t\t\t\t\tshowTooltip={ label !== fullLabel }\n\t\t\t\t\t\t\taria-expanded={ isOpen }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ label }\n\t\t\t\t\t\t</Button>\n\t\t\t\t\t) }\n\t\t\t\t\trenderContent={ ( { onClose } ) => (\n\t\t\t\t\t\t<PostScheduleForm onClose={ onClose } />\n\t\t\t\t\t) }\n\t\t\t\t/>\n\t\t\t</PostPanelRow>\n\t\t</PostScheduleCheck>\n\t);\n}\n"],
5
- "mappings": "AAsEM;AAnEN,SAAS,QAAQ,gBAAgB;AACjC,SAAS,IAAI,eAAe;AAC5B,SAAS,UAAU,eAAe;AAClC,SAAS,iBAAiB;AAK1B,OAAO,uBAAuB;AAC9B,OAAO,sBAAsB;AAC7B,SAAS,4BAA4B;AACrC,OAAO,kBAAkB;AACzB,SAAS,SAAS,mBAAmB;AACrC;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACM;AAEP,MAAM,oBAAoB;AAAA,EACzB;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACD;AAOe,SAAR,oBAAqC;AAC3C,QAAM,CAAE,eAAe,gBAAiB,IAAI,SAAU,IAAK;AAC3D,QAAM,WAAW;AAAA,IAChB,CAAE,WAAY,OAAQ,WAAY,EAAE,mBAAmB;AAAA,IACvD,CAAC;AAAA,EACF;AAEA,QAAM,eAAe;AAAA,IACpB,OAAQ;AAAA;AAAA;AAAA,MAGP,QAAQ;AAAA,MACR,cAAc,GAAI,qBAAsB;AAAA,MACxC,WAAW;AAAA,MACX,QAAQ;AAAA,MACR,OAAO;AAAA,IACR;AAAA,IACA,CAAE,aAAc;AAAA,EACjB;AAEA,QAAM,QAAQ,qBAAqB;AACnC,QAAM,YAAY,qBAAsB,EAAE,MAAM,KAAK,CAAE;AACvD,MAAK,kBAAkB,SAAU,QAAS,GAAI;AAC7C,WAAO;AAAA,EACR;AAEA,SACC,oBAAC,qBACA,8BAAC,gBAAa,OAAQ,GAAI,SAAU,GAAI,KAAM,kBAC7C;AAAA,IAAC;AAAA;AAAA,MACA;AAAA,MACA,cAAY;A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AY,qBAAsB,EAAE,MAAM,KAAK,CAAE;AACvD,MAAK,kBAAkB,SAAU,QAAS,GAAI;AAC7C,WAAO;AAAA,EACR;AAEA,SACC,oBAAC,qBACA,8BAAC,gBAAa,OAAQ,GAAI,SAAU,GAAI,KAAM,kBAC7C;AAAA,IAAC;AAAA;AAAA,MACA;AAAA,MACA,cAAY;AAAA,MACZ,WAAU;AAAA,MACV,kBAAiB;AAAA,MACjB,cAAe,CAAE,EAAE,UAAU,OAAO,MACnC;AAAA,QAAC;AAAA;AAAA,UACA,MAAK;AAAA,UACL,WAAU;AAAA,UACV,SAAQ;AAAA,UACR,iBAAgB;AAAA,UAChB,SAAU;AAAA,UACV,cAAa;AAAA;AAAA,YAEZ,GAAI,iBAAkB;AAAA,YACtB;AAAA,UACD;AAAA,UACA,OAAQ;AAAA,UACR,aAAc,UAAU;AAAA,UACxB,iBAAgB;AAAA,UAEd;AAAA;AAAA,MACH;AAAA,MAED,eAAgB,CAAE,EAAE,QAAQ,MAC3B,oBAAC,oBAAiB,SAAoB;AAAA;AAAA,EAExC,GACD,GACD;AAEF;",
6
6
  "names": []
7
7
  }
@@ -1,4 +1,4 @@
1
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
1
+ // packages/editor/src/components/post-status/index.js
2
2
  import {
3
3
  Button,
4
4
  CheckboxControl,
@@ -30,7 +30,8 @@ import PostPanelRow from "../post-panel-row";
30
30
  import PostSticky from "../post-sticky";
31
31
  import { PrivatePostSchedule } from "../post-schedule";
32
32
  import { store as editorStore } from "../../store";
33
- const postStatusesInfo = {
33
+ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
34
+ var postStatusesInfo = {
34
35
  "auto-draft": { label: __("Draft"), icon: drafts },
35
36
  draft: { label: __("Draft"), icon: drafts },
36
37
  pending: { label: __("Pending"), icon: pending },
@@ -38,7 +39,7 @@ const postStatusesInfo = {
38
39
  future: { label: __("Scheduled"), icon: scheduled },
39
40
  publish: { label: __("Published"), icon: published }
40
41
  };
41
- const STATUS_OPTIONS = [
42
+ var STATUS_OPTIONS = [
42
43
  {
43
44
  label: __("Draft"),
44
45
  value: "draft",
@@ -65,7 +66,7 @@ const STATUS_OPTIONS = [
65
66
  description: __("Visible to everyone.")
66
67
  }
67
68
  ];
68
- const DESIGN_POST_TYPES = [
69
+ var DESIGN_POST_TYPES = [
69
70
  TEMPLATE_POST_TYPE,
70
71
  TEMPLATE_PART_POST_TYPE,
71
72
  PATTERN_POST_TYPE,
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-status/index.js"],
4
4
  "sourcesContent": ["/**\n * WordPress dependencies\n */\nimport {\n\tButton,\n\tCheckboxControl,\n\tDropdown,\n\t__experimentalVStack as VStack,\n\tTextControl,\n\tRadioControl,\n} from '@wordpress/components';\nimport { __, sprintf } from '@wordpress/i18n';\nimport { useDispatch, useSelect } from '@wordpress/data';\nimport { useState, useMemo } from '@wordpress/element';\nimport { store as coreStore } from '@wordpress/core-data';\nimport { __experimentalInspectorPopoverHeader as InspectorPopoverHeader } from '@wordpress/block-editor';\nimport { useInstanceId } from '@wordpress/compose';\nimport {\n\tdrafts,\n\tpublished,\n\tscheduled,\n\tpending,\n\tnotAllowed,\n} from '@wordpress/icons';\n\n/**\n * Internal dependencies\n */\nimport {\n\tTEMPLATE_POST_TYPE,\n\tTEMPLATE_PART_POST_TYPE,\n\tPATTERN_POST_TYPE,\n\tNAVIGATION_POST_TYPE,\n} from '../../store/constants';\nimport PostPanelRow from '../post-panel-row';\nimport PostSticky from '../post-sticky';\nimport { PrivatePostSchedule } from '../post-schedule';\nimport { store as editorStore } from '../../store';\n\nconst postStatusesInfo = {\n\t'auto-draft': { label: __( 'Draft' ), icon: drafts },\n\tdraft: { label: __( 'Draft' ), icon: drafts },\n\tpending: { label: __( 'Pending' ), icon: pending },\n\tprivate: { label: __( 'Private' ), icon: notAllowed },\n\tfuture: { label: __( 'Scheduled' ), icon: scheduled },\n\tpublish: { label: __( 'Published' ), icon: published },\n};\n\nexport const STATUS_OPTIONS = [\n\t{\n\t\tlabel: __( 'Draft' ),\n\t\tvalue: 'draft',\n\t\tdescription: __( 'Not ready to publish.' ),\n\t},\n\t{\n\t\tlabel: __( 'Pending' ),\n\t\tvalue: 'pending',\n\t\tdescription: __( 'Waiting for review before publishing.' ),\n\t},\n\t{\n\t\tlabel: __( 'Private' ),\n\t\tvalue: 'private',\n\t\tdescription: __( 'Only visible to site admins and editors.' ),\n\t},\n\t{\n\t\tlabel: __( 'Scheduled' ),\n\t\tvalue: 'future',\n\t\tdescription: __( 'Publish automatically on a chosen date.' ),\n\t},\n\t{\n\t\tlabel: __( 'Published' ),\n\t\tvalue: 'publish',\n\t\tdescription: __( 'Visible to everyone.' ),\n\t},\n];\n\nconst DESIGN_POST_TYPES = [\n\tTEMPLATE_POST_TYPE,\n\tTEMPLATE_PART_POST_TYPE,\n\tPATTERN_POST_TYPE,\n\tNAVIGATION_POST_TYPE,\n];\n\nexport default function PostStatus() {\n\tconst { status, date, password, postId, postType, canEdit } = useSelect(\n\t\t( select ) => {\n\t\t\tconst {\n\t\t\t\tgetEditedPostAttribute,\n\t\t\t\tgetCurrentPostId,\n\t\t\t\tgetCurrentPostType,\n\t\t\t\tgetCurrentPost,\n\t\t\t} = select( editorStore );\n\t\t\treturn {\n\t\t\t\tstatus: getEditedPostAttribute( 'status' ),\n\t\t\t\tdate: getEditedPostAttribute( 'date' ),\n\t\t\t\tpassword: getEditedPostAttribute( 'password' ),\n\t\t\t\tpostId: getCurrentPostId(),\n\t\t\t\tpostType: getCurrentPostType(),\n\t\t\t\tcanEdit:\n\t\t\t\t\tgetCurrentPost()._links?.[ 'wp:action-publish' ] ?? false,\n\t\t\t};\n\t\t},\n\t\t[]\n\t);\n\tconst [ showPassword, setShowPassword ] = useState( !! password );\n\tconst passwordInputId = useInstanceId(\n\t\tPostStatus,\n\t\t'editor-change-status__password-input'\n\t);\n\tconst { editEntityRecord } = useDispatch( coreStore );\n\tconst [ popoverAnchor, setPopoverAnchor ] = useState( null );\n\t// Memoize popoverProps to avoid returning a new object every time.\n\tconst popoverProps = useMemo(\n\t\t() => ( {\n\t\t\t// Anchor the popover to the middle of the entire row so that it doesn't\n\t\t\t// move around when the label changes.\n\t\t\tanchor: popoverAnchor,\n\t\t\t'aria-label': __( 'Status & visibility' ),\n\t\t\theaderTitle: __( 'Status & visibility' ),\n\t\t\tplacement: 'left-start',\n\t\t\toffset: 36,\n\t\t\tshift: true,\n\t\t} ),\n\t\t[ popoverAnchor ]\n\t);\n\n\tif ( DESIGN_POST_TYPES.includes( postType ) ) {\n\t\treturn null;\n\t}\n\n\tconst updatePost = ( {\n\t\tstatus: newStatus = status,\n\t\tpassword: newPassword = password,\n\t\tdate: newDate = date,\n\t} ) => {\n\t\teditEntityRecord( 'postType', postType, postId, {\n\t\t\tstatus: newStatus,\n\t\t\tdate: newDate,\n\t\t\tpassword: newPassword,\n\t\t} );\n\t};\n\n\tconst handleTogglePassword = ( value ) => {\n\t\tsetShowPassword( value );\n\t\tif ( ! value ) {\n\t\t\tupdatePost( { password: '' } );\n\t\t}\n\t};\n\n\tconst handleStatus = ( value ) => {\n\t\tlet newDate = date;\n\t\tlet newPassword = password;\n\t\tif ( status === 'future' && new Date( date ) > new Date() ) {\n\t\t\tnewDate = null;\n\t\t}\n\t\tif ( value === 'private' && password ) {\n\t\t\tnewPassword = '';\n\t\t}\n\t\tupdatePost( {\n\t\t\tstatus: value,\n\t\t\tdate: newDate,\n\t\t\tpassword: newPassword,\n\t\t} );\n\t};\n\n\treturn (\n\t\t<PostPanelRow label={ __( 'Status' ) } ref={ setPopoverAnchor }>\n\t\t\t{ canEdit ? (\n\t\t\t\t<Dropdown\n\t\t\t\t\tclassName=\"editor-post-status\"\n\t\t\t\t\tcontentClassName=\"editor-change-status__content\"\n\t\t\t\t\tpopoverProps={ popoverProps }\n\t\t\t\t\tfocusOnMount\n\t\t\t\t\trenderToggle={ ( { onToggle, isOpen } ) => (\n\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\tclassName=\"editor-post-status__toggle\"\n\t\t\t\t\t\t\tvariant=\"tertiary\"\n\t\t\t\t\t\t\tsize=\"compact\"\n\t\t\t\t\t\t\tonClick={ onToggle }\n\t\t\t\t\t\t\ticon={ postStatusesInfo[ status ]?.icon }\n\t\t\t\t\t\t\taria-label={ sprintf(\n\t\t\t\t\t\t\t\t// translators: %s: Current post status.\n\t\t\t\t\t\t\t\t__( 'Change status: %s' ),\n\t\t\t\t\t\t\t\tpostStatusesInfo[ status ]?.label\n\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\taria-expanded={ isOpen }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ postStatusesInfo[ status ]?.label }\n\t\t\t\t\t\t</Button>\n\t\t\t\t\t) }\n\t\t\t\t\trenderContent={ ( { onClose } ) => (\n\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t<InspectorPopoverHeader\n\t\t\t\t\t\t\t\ttitle={ __( 'Status & visibility' ) }\n\t\t\t\t\t\t\t\tonClose={ onClose }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t<form\n\t\t\t\t\t\t\t\tonSubmit={ ( event ) => {\n\t\t\t\t\t\t\t\t\tevent.preventDefault();\n\t\t\t\t\t\t\t\t\tonClose();\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\t<VStack spacing={ 4 }>\n\t\t\t\t\t\t\t\t\t<RadioControl\n\t\t\t\t\t\t\t\t\t\tclassName=\"editor-change-status__options\"\n\t\t\t\t\t\t\t\t\t\thideLabelFromVision\n\t\t\t\t\t\t\t\t\t\tlabel={ __( 'Status' ) }\n\t\t\t\t\t\t\t\t\t\toptions={ STATUS_OPTIONS }\n\t\t\t\t\t\t\t\t\t\tonChange={ handleStatus }\n\t\t\t\t\t\t\t\t\t\tselected={\n\t\t\t\t\t\t\t\t\t\t\tstatus === 'auto-draft'\n\t\t\t\t\t\t\t\t\t\t\t\t? 'draft'\n\t\t\t\t\t\t\t\t\t\t\t\t: status\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t{ status === 'future' && (\n\t\t\t\t\t\t\t\t\t\t<div className=\"editor-change-status__publish-date-wrapper\">\n\t\t\t\t\t\t\t\t\t\t\t<PrivatePostSchedule\n\t\t\t\t\t\t\t\t\t\t\t\tshowPopoverHeaderActions={\n\t\t\t\t\t\t\t\t\t\t\t\t\tfalse\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\tisCompact\n\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\t{ status !== 'private' && (\n\t\t\t\t\t\t\t\t\t\t<VStack\n\t\t\t\t\t\t\t\t\t\t\tas=\"fieldset\"\n\t\t\t\t\t\t\t\t\t\t\tspacing={ 4 }\n\t\t\t\t\t\t\t\t\t\t\tclassName=\"editor-change-status__password-fieldset\"\n\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t<CheckboxControl\n\t\t\t\t\t\t\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t\t\t\t\t\t\t\tlabel={ __(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'Password protected'\n\t\t\t\t\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\t\t\t\thelp={ __(\n\t\t\t\t\t\t\t\t\t\t\t\t\t'Only visible to those who know the password.'\n\t\t\t\t\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\t\t\t\tchecked={ showPassword }\n\t\t\t\t\t\t\t\t\t\t\t\tonChange={\n\t\t\t\t\t\t\t\t\t\t\t\t\thandleTogglePassword\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t\t{ showPassword && (\n\t\t\t\t\t\t\t\t\t\t\t\t<div className=\"editor-change-status__password-input\">\n\t\t\t\t\t\t\t\t\t\t\t\t\t<TextControl\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tlabel={ __(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'Password'\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tonChange={ ( value ) =>\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tupdatePost( {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tpassword: value,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t} )\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tvalue={ password }\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tplaceholder={ __(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'Use a secure password'\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\t\t\t\t\t\ttype=\"text\"\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tid={ passwordInputId }\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t__next40pxDefaultSize\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tmaxLength={ 255 }\n\t\t\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\t\t</VStack>\n\t\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\t\t<PostSticky />\n\t\t\t\t\t\t\t\t</VStack>\n\t\t\t\t\t\t\t</form>\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\t\t<div className=\"editor-post-status is-read-only\">\n\t\t\t\t\t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,OAAQ;AAAA,wBACR,aAAc;AAAA,0BACb;AAAA,wBACD;AAAA,wBACA,MAAK;AAAA,wBACL,IAAK;AAAA,wBACL,uBAAqB;AAAA,wBACrB,yBAAuB;AAAA,wBACvB,WAAY;AAAA;AAAA,oBACb,GACD;AAAA;AAAA;AAAA,cAEF;AAAA,cAED,oBAAC,cAAW;AAAA,eACb;AAAA;AAAA,QACD;AAAA,SACD;AAAA;AAAA,EAEF,IAEA,oBAAC,SAAI,WAAU,mCACZ,2BAAkB,MAAO,GAAG,OAC/B,GAEF;AAEF;",
6
6
  "names": []
7
7
  }
@@ -1,3 +1,4 @@
1
+ // packages/editor/src/components/post-sticky/check.js
1
2
  import { useSelect } from "@wordpress/data";
2
3
  import { store as editorStore } from "../../store";
3
4
  function PostStickyCheck({ children }) {
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-sticky/check.js"],
4
4
  "sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { useSelect } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport { store as editorStore } from '../../store';\n\n/**\n * Wrapper component that renders its children only if post has a sticky action.\n *\n * @param {Object} props Props.\n * @param {React.ReactNode} props.children Children to be rendered.\n *\n * @return {React.ReactNode} The component to be rendered or null if post type is not 'post' or hasStickyAction is false.\n */\nexport default function PostStickyCheck( { children } ) {\n\tconst { hasStickyAction, postType } = useSelect( ( select ) => {\n\t\tconst post = select( editorStore ).getCurrentPost();\n\t\treturn {\n\t\t\thasStickyAction: post._links?.[ 'wp:action-sticky' ] ?? false,\n\t\t\tpostType: select( editorStore ).getCurrentPostType(),\n\t\t};\n\t}, [] );\n\n\tif ( postType !== 'post' || ! hasStickyAction ) {\n\t\treturn null;\n\t}\n\n\treturn children;\n}\n"],
5
- "mappings": "AAGA,SAAS,iBAAiB;AAK1B,SAAS,SAAS,mBAAmB;AAUtB,SAAR,gBAAkC,EAAE,SAAS,GAAI;AACvD,QAAM,EAAE,iBAAiB,SAAS,IAAI,UAAW,CAAE,WAAY;AAC9D,UAAM,OAAO,OAAQ,WAAY,EAAE,eAAe;AAClD,WAAO;AAAA,MACN,iBAAiB,KAAK,SAAU,kBAAmB,KAAK;AAAA,MACxD,UAAU,OAAQ,WAAY,EAAE,mBAAmB;AAAA,IACpD;AAAA,EACD,GAAG,CAAC,CAAE;AAEN,MAAK,aAAa,UAAU,CAAE,iBAAkB;AAC/C,WAAO;AAAA,EACR;AAEA,SAAO;AACR;",
5
+ "mappings": ";AAGA,SAAS,iBAAiB;AAK1B,SAAS,SAAS,mBAAmB;AAUtB,SAAR,gBAAkC,EAAE,SAAS,GAAI;AACvD,QAAM,EAAE,iBAAiB,SAAS,IAAI,UAAW,CAAE,WAAY;AAC9D,UAAM,OAAO,OAAQ,WAAY,EAAE,eAAe;AAClD,WAAO;AAAA,MACN,iBAAiB,KAAK,SAAU,kBAAmB,KAAK;AAAA,MACxD,UAAU,OAAQ,WAAY,EAAE,mBAAmB;AAAA,IACpD;AAAA,EACD,GAAG,CAAC,CAAE;AAEN,MAAK,aAAa,UAAU,CAAE,iBAAkB;AAC/C,WAAO;AAAA,EACR;AAEA,SAAO;AACR;",
6
6
  "names": []
7
7
  }
@@ -1,9 +1,10 @@
1
- import { jsx } from "react/jsx-runtime";
1
+ // packages/editor/src/components/post-sticky/index.js
2
2
  import { __ } from "@wordpress/i18n";
3
3
  import { CheckboxControl } from "@wordpress/components";
4
4
  import { useDispatch, useSelect } from "@wordpress/data";
5
5
  import PostStickyCheck from "./check";
6
6
  import { store as editorStore } from "../../store";
7
+ import { jsx } from "react/jsx-runtime";
7
8
  function PostSticky() {
8
9
  const postSticky = useSelect((select) => {
9
10
  return select(editorStore).getEditedPostAttribute("sticky") ?? false;
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-sticky/index.js"],
4
4
  "sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { CheckboxControl } from '@wordpress/components';\nimport { useDispatch, useSelect } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport PostStickyCheck from './check';\nimport { store as editorStore } from '../../store';\n\n/**\n * Renders the PostSticky component. It provides a checkbox control for the sticky post feature.\n *\n * @return {React.ReactNode} The rendered component.\n */\nexport default function PostSticky() {\n\tconst postSticky = useSelect( ( select ) => {\n\t\treturn (\n\t\t\tselect( editorStore ).getEditedPostAttribute( 'sticky' ) ?? false\n\t\t);\n\t}, [] );\n\tconst { editPost } = useDispatch( editorStore );\n\n\treturn (\n\t\t<PostStickyCheck>\n\t\t\t<CheckboxControl\n\t\t\t\tclassName=\"editor-post-sticky__checkbox-control\"\n\t\t\t\tlabel={ __( 'Sticky' ) }\n\t\t\t\thelp={ __( 'Pin this post to the top of the blog.' ) }\n\t\t\t\tchecked={ postSticky }\n\t\t\t\tonChange={ () => editPost( { sticky: ! postSticky } ) }\n\t\t\t\t__nextHasNoMarginBottom\n\t\t\t/>\n\t\t</PostStickyCheck>\n\t);\n}\n"],
5
- "mappings": "AA4BG;AAzBH,SAAS,UAAU;AACnB,SAAS,uBAAuB;AAChC,SAAS,aAAa,iBAAiB;AAKvC,OAAO,qBAAqB;AAC5B,SAAS,SAAS,mBAAmB;AAOtB,SAAR,aAA8B;AACpC,QAAM,aAAa,UAAW,CAAE,WAAY;AAC3C,WACC,OAAQ,WAAY,EAAE,uBAAwB,QAAS,KAAK;AAAA,EAE9D,GAAG,CAAC,CAAE;AACN,QAAM,EAAE,SAAS,IAAI,YAAa,WAAY;AAE9C,SACC,oBAAC,mBACA;AAAA,IAAC;AAAA;AAAA,MACA,WAAU;AAAA,MACV,OAAQ,GAAI,QAAS;AAAA,MACrB,MAAO,GAAI,uCAAwC;AAAA,MACnD,SAAU;AAAA,MACV,UAAW,MAAM,SAAU,EAAE,QAAQ,CAAE,WAAW,CAAE;AAAA,MACpD,yBAAuB;AAAA;AAAA,EACxB,GACD;AAEF;",
5
+ "mappings": ";AAGA,SAAS,UAAU;AACnB,SAAS,uBAAuB;AAChC,SAAS,aAAa,iBAAiB;AAKvC,OAAO,qBAAqB;AAC5B,SAAS,SAAS,mBAAmB;AAiBlC;AAVY,SAAR,aAA8B;AACpC,QAAM,aAAa,UAAW,CAAE,WAAY;AAC3C,WACC,OAAQ,WAAY,EAAE,uBAAwB,QAAS,KAAK;AAAA,EAE9D,GAAG,CAAC,CAAE;AACN,QAAM,EAAE,SAAS,IAAI,YAAa,WAAY;AAE9C,SACC,oBAAC,mBACA;AAAA,IAAC;AAAA;AAAA,MACA,WAAU;AAAA,MACV,OAAQ,GAAI,QAAS;AAAA,MACrB,MAAO,GAAI,uCAAwC;AAAA,MACnD,SAAU;AAAA,MACV,UAAW,MAAM,SAAU,EAAE,QAAQ,CAAE,WAAW,CAAE;AAAA,MACpD,yBAAuB;AAAA;AAAA,EACxB,GACD;AAEF;",
6
6
  "names": []
7
7
  }
@@ -1,7 +1,8 @@
1
- import { jsx } from "react/jsx-runtime";
1
+ // packages/editor/src/components/post-sticky/panel.js
2
2
  import PostPanelRow from "../post-panel-row";
3
3
  import PostStickyForm from "./";
4
4
  import PostStickyCheck from "./check";
5
+ import { jsx } from "react/jsx-runtime";
5
6
  function PostStickyPanel() {
6
7
  return /* @__PURE__ */ jsx(PostStickyCheck, { children: /* @__PURE__ */ jsx(PostPanelRow, { children: /* @__PURE__ */ jsx(PostStickyForm, {}) }) });
7
8
  }
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-sticky/panel.js"],
4
4
  "sourcesContent": ["/**\n * Internal dependencies\n */\nimport PostPanelRow from '../post-panel-row';\nimport PostStickyForm from './';\nimport PostStickyCheck from './check';\n\nexport function PostStickyPanel() {\n\treturn (\n\t\t<PostStickyCheck>\n\t\t\t<PostPanelRow>\n\t\t\t\t<PostStickyForm />\n\t\t\t</PostPanelRow>\n\t\t</PostStickyCheck>\n\t);\n}\n\nexport default PostStickyPanel;\n"],
5
- "mappings": "AAWI;AARJ,OAAO,kBAAkB;AACzB,OAAO,oBAAoB;AAC3B,OAAO,qBAAqB;AAErB,SAAS,kBAAkB;AACjC,SACC,oBAAC,mBACA,8BAAC,gBACA,8BAAC,kBAAe,GACjB,GACD;AAEF;AAEA,IAAO,gBAAQ;",
5
+ "mappings": ";AAGA,OAAO,kBAAkB;AACzB,OAAO,oBAAoB;AAC3B,OAAO,qBAAqB;AAMxB;AAJG,SAAS,kBAAkB;AACjC,SACC,oBAAC,mBACA,8BAAC,gBACA,8BAAC,kBAAe,GACjB,GACD;AAEF;AAEA,IAAO,gBAAQ;",
6
6
  "names": []
7
7
  }
@@ -1,4 +1,4 @@
1
- import { Fragment, jsx, jsxs } from "react/jsx-runtime";
1
+ // packages/editor/src/components/post-switch-to-draft-button/index.js
2
2
  import {
3
3
  Button,
4
4
  __experimentalConfirmDialog as ConfirmDialog
@@ -8,6 +8,7 @@ import { useDispatch, useSelect } from "@wordpress/data";
8
8
  import { useState } from "@wordpress/element";
9
9
  import deprecated from "@wordpress/deprecated";
10
10
  import { store as editorStore } from "../../store";
11
+ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
11
12
  function PostSwitchToDraftButton() {
12
13
  deprecated("wp.editor.PostSwitchToDraftButton", {
13
14
  since: "6.7",
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-switch-to-draft-button/index.js"],
4
4
  "sourcesContent": ["/**\n * WordPress dependencies\n */\nimport {\n\tButton,\n\t__experimentalConfirmDialog as ConfirmDialog,\n} from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { useDispatch, useSelect } from '@wordpress/data';\nimport { useState } from '@wordpress/element';\nimport deprecated from '@wordpress/deprecated';\n\n/**\n * Internal dependencies\n */\nimport { store as editorStore } from '../../store';\n\n/**\n * Renders a button component that allows the user to switch a post to draft status.\n *\n * @return {React.ReactNode} The rendered component.\n */\nexport default function PostSwitchToDraftButton() {\n\tdeprecated( 'wp.editor.PostSwitchToDraftButton', {\n\t\tsince: '6.7',\n\t\tversion: '6.9',\n\t} );\n\tconst [ showConfirmDialog, setShowConfirmDialog ] = useState( false );\n\n\tconst { editPost, savePost } = useDispatch( editorStore );\n\tconst { isSaving, isPublished, isScheduled } = useSelect( ( select ) => {\n\t\tconst { isSavingPost, isCurrentPostPublished, isCurrentPostScheduled } =\n\t\t\tselect( editorStore );\n\t\treturn {\n\t\t\tisSaving: isSavingPost(),\n\t\t\tisPublished: isCurrentPostPublished(),\n\t\t\tisScheduled: isCurrentPostScheduled(),\n\t\t};\n\t}, [] );\n\n\tconst isDisabled = isSaving || ( ! isPublished && ! isScheduled );\n\n\tlet alertMessage;\n\tlet confirmButtonText;\n\tif ( isPublished ) {\n\t\talertMessage = __( 'Are you sure you want to unpublish this post?' );\n\t\tconfirmButtonText = __( 'Unpublish' );\n\t} else if ( isScheduled ) {\n\t\talertMessage = __( 'Are you sure you want to unschedule this post?' );\n\t\tconfirmButtonText = __( 'Unschedule' );\n\t}\n\n\tconst handleConfirm = () => {\n\t\tsetShowConfirmDialog( false );\n\t\teditPost( { status: 'draft' } );\n\t\tsavePost();\n\t};\n\n\treturn (\n\t\t<>\n\t\t\t<Button\n\t\t\t\t__next40pxDefaultSize\n\t\t\t\tclassName=\"editor-post-switch-to-draft\"\n\t\t\t\tonClick={ () => {\n\t\t\t\t\tif ( ! isDisabled ) {\n\t\t\t\t\t\tsetShowConfirmDialog( true );\n\t\t\t\t\t}\n\t\t\t\t} }\n\t\t\t\taria-disabled={ isDisabled }\n\t\t\t\tvariant=\"secondary\"\n\t\t\t\tstyle={ { flexGrow: '1', justifyContent: 'center' } }\n\t\t\t>\n\t\t\t\t{ __( 'Switch to draft' ) }\n\t\t\t</Button>\n\t\t\t<ConfirmDialog\n\t\t\t\tisOpen={ showConfirmDialog }\n\t\t\t\tonConfirm={ handleConfirm }\n\t\t\t\tonCancel={ () => setShowConfirmDialog( false ) }\n\t\t\t\tconfirmButtonText={ confirmButtonText }\n\t\t\t>\n\t\t\t\t{ alertMess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ACV;AAEA,SACC,iCACC;AAAA;AAAA,MAAC;AAAA;AAAA,QACA,uBAAqB;AAAA,QACrB,WAAU;AAAA,QACV,SAAU,MAAM;AACf,cAAK,CAAE,YAAa;AACnB,iCAAsB,IAAK;AAAA,UAC5B;AAAA,QACD;AAAA,QACA,iBAAgB;AAAA,QAChB,SAAQ;AAAA,QACR,OAAQ,EAAE,UAAU,KAAK,gBAAgB,SAAS;AAAA,QAEhD,aAAI,iBAAkB;AAAA;AAAA,IACzB;AAAA,IACA;AAAA,MAAC;AAAA;AAAA,QACA,QAAS;AAAA,QACT,WAAY;AAAA,QACZ,UAAW,MAAM,qBAAsB,KAAM;AAAA,QAC7C;AAAA,QAEE;AAAA;AAAA,IACH;AAAA,KACD;AAEF;",
6
6
  "names": []
7
7
  }
@@ -1,8 +1,9 @@
1
- import { jsx } from "react/jsx-runtime";
1
+ // packages/editor/src/components/post-sync-status/index.js
2
2
  import { useSelect } from "@wordpress/data";
3
3
  import { __, _x } from "@wordpress/i18n";
4
4
  import PostPanelRow from "../post-panel-row";
5
5
  import { store as editorStore } from "../../store";
6
+ import { jsx } from "react/jsx-runtime";
6
7
  function PostSyncStatus() {
7
8
  const { syncStatus, postType } = useSelect((select) => {
8
9
  const { getEditedPostAttribute } = select(editorStore);
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-sync-status/index.js"],
4
4
  "sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { useSelect } from '@wordpress/data';\nimport { __, _x } from '@wordpress/i18n';\n\n/**\n * Internal dependencies\n */\nimport PostPanelRow from '../post-panel-row';\nimport { store as editorStore } from '../../store';\n\n/**\n * Renders the sync status of a post.\n *\n * @return {React.ReactNode} The rendered sync status component.\n */\nexport default function PostSyncStatus() {\n\tconst { syncStatus, postType } = useSelect( ( select ) => {\n\t\tconst { getEditedPostAttribute } = select( editorStore );\n\t\tconst meta = getEditedPostAttribute( 'meta' );\n\n\t\t// When the post is first created, the top level wp_pattern_sync_status is not set so get meta value instead.\n\t\tconst currentSyncStatus =\n\t\t\tmeta?.wp_pattern_sync_status === 'unsynced'\n\t\t\t\t? 'unsynced'\n\t\t\t\t: getEditedPostAttribute( 'wp_pattern_sync_status' );\n\n\t\treturn {\n\t\t\tsyncStatus: currentSyncStatus,\n\t\t\tpostType: getEditedPostAttribute( 'type' ),\n\t\t};\n\t} );\n\n\tif ( postType !== 'wp_block' ) {\n\t\treturn null;\n\t}\n\n\treturn (\n\t\t<PostPanelRow label={ __( 'Sync status' ) }>\n\t\t\t<div className=\"editor-post-sync-status__value\">\n\t\t\t\t{ syncStatus === 'unsynced'\n\t\t\t\t\t? _x( 'Not synced', 'pattern (singular)' )\n\t\t\t\t\t: _x( 'Synced', 'pattern (singular)' ) }\n\t\t\t</div>\n\t\t</PostPanelRow>\n\t);\n}\n"],
5
- "mappings": "AAwCG;AArCH,SAAS,iBAAiB;AAC1B,SAAS,IAAI,UAAU;AAKvB,OAAO,kBAAkB;AACzB,SAAS,SAAS,mBAAmB;AAOtB,SAAR,iBAAkC;AACxC,QAAM,EAAE,YAAY,SAAS,IAAI,UAAW,CAAE,WAAY;AACzD,UAAM,EAAE,uBAAuB,IAAI,OAAQ,WAAY;AACvD,UAAM,OAAO,uBAAwB,MAAO;AAG5C,UAAM,oBACL,MAAM,2BAA2B,aAC9B,aACA,uBAAwB,wBAAyB;AAErD,WAAO;AAAA,MACN,YAAY;AAAA,MACZ,UAAU,uBAAwB,MAAO;AAAA,IAC1C;AAAA,EACD,CAAE;AAEF,MAAK,aAAa,YAAa;AAC9B,WAAO;AAAA,EACR;AAEA,SACC,oBAAC,gBAAa,OAAQ,GAAI,aAAc,GACvC,8BAAC,SAAI,WAAU,kCACZ,yBAAe,aACd,GAAI,cAAc,oBAAqB,IACvC,GAAI,UAAU,oBAAqB,GACvC,GACD;AAEF;",
5
+ "mappings": ";AAGA,SAAS,iBAAiB;AAC1B,SAAS,IAAI,UAAU;AAKvB,OAAO,kBAAkB;AACzB,SAAS,SAAS,mBAAmB;AA8BlC;AAvBY,SAAR,iBAAkC;AACxC,QAAM,EAAE,YAAY,SAAS,IAAI,UAAW,CAAE,WAAY;AACzD,UAAM,EAAE,uBAAuB,IAAI,OAAQ,WAAY;AACvD,UAAM,OAAO,uBAAwB,MAAO;AAG5C,UAAM,oBACL,MAAM,2BAA2B,aAC9B,aACA,uBAAwB,wBAAyB;AAErD,WAAO;AAAA,MACN,YAAY;AAAA,MACZ,UAAU,uBAAwB,MAAO;AAAA,IAC1C;AAAA,EACD,CAAE;AAEF,MAAK,aAAa,YAAa;AAC9B,WAAO;AAAA,EACR;AAEA,SACC,oBAAC,gBAAa,OAAQ,GAAI,aAAc,GACvC,8BAAC,SAAI,WAAU,kCACZ,yBAAe,aACd,GAAI,cAAc,oBAAqB,IACvC,GAAI,UAAU,oBAAqB,GACvC,GACD;AAEF;",
6
6
  "names": []
7
7
  }
@@ -1,3 +1,4 @@
1
+ // packages/editor/src/components/post-taxonomies/check.js
1
2
  import { useSelect } from "@wordpress/data";
2
3
  import { store as coreStore } from "@wordpress/core-data";
3
4
  import { store as editorStore } from "../../store";
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/components/post-taxonomies/check.js"],
4
4
  "sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { useSelect } from '@wordpress/data';\nimport { store as coreStore } from '@wordpress/core-data';\n\n/**\n * Internal dependencies\n */\nimport { store as editorStore } from '../../store';\n\n/**\n * Renders the children components only if the current post type has taxonomies.\n *\n * @param {Object} props The component props.\n * @param {React.ReactNode} props.children The children components to render.\n *\n * @return {React.ReactNode} The rendered children components or null if the current post type has no taxonomies.\n */\nexport default function PostTaxonomiesCheck( { children } ) {\n\tconst hasTaxonomies = useSelect( ( select ) => {\n\t\tconst postType = select( editorStore ).getCurrentPostType();\n\t\tconst taxonomies = select( coreStore ).getEntityRecords(\n\t\t\t'root',\n\t\t\t'taxonomy',\n\t\t\t{ per_page: -1 }\n\t\t);\n\t\treturn taxonomies?.some( ( taxonomy ) =>\n\t\t\ttaxonomy.types.includes( postType )\n\t\t);\n\t}, [] );\n\tif ( ! hasTaxonomies ) {\n\t\treturn null;\n\t}\n\n\treturn children;\n}\n"],
5
- "mappings": "AAGA,SAAS,iBAAiB;AAC1B,SAAS,SAAS,iBAAiB;AAKnC,SAAS,SAAS,mBAAmB;AAUtB,SAAR,oBAAsC,EAAE,SAAS,GAAI;AAC3D,QAAM,gBAAgB,UAAW,CAAE,WAAY;AAC9C,UAAM,WAAW,OAAQ,WAAY,EAAE,mBAAmB;AAC1D,UAAM,aAAa,OAAQ,SAAU,EAAE;AAAA,MACtC;AAAA,MACA;AAAA,MACA,EAAE,UAAU,GAAG;AAAA,IAChB;AACA,WAAO,YAAY;AAAA,MAAM,CAAE,aAC1B,SAAS,MAAM,SAAU,QAAS;AAAA,IACnC;AAAA,EACD,GAAG,CAAC,CAAE;AACN,MAAK,CAAE,eAAgB;AACtB,WAAO;AAAA,EACR;AAEA,SAAO;AACR;",
5
+ "mappings": ";AAGA,SAAS,iBAAiB;AAC1B,SAAS,SAAS,iBAAiB;AAKnC,SAAS,SAAS,mBAAmB;AAUtB,SAAR,oBAAsC,EAAE,SAAS,GAAI;AAC3D,QAAM,gBAAgB,UAAW,CAAE,WAAY;AAC9C,UAAM,WAAW,OAAQ,WAAY,EAAE,mBAAmB;AAC1D,UAAM,aAAa,OAAQ,SAAU,EAAE;AAAA,MACtC;AAAA,MACA;AAAA,MACA,EAAE,UAAU,GAAG;AAAA,IAChB;AACA,WAAO,YAAY;AAAA,MAAM,CAAE,aAC1B,SAAS,MAAM,SAAU,QAAS;AAAA,IACnC;AAAA,EACD,GAAG,CAAC,CAAE;AACN,MAAK,CAAE,eAAgB;AACtB,WAAO;AAAA,EACR;AAEA,SAAO;AACR;",
6
6
  "names": []
7
7
  }
@@ -1,4 +1,4 @@
1
- import { jsx, jsxs } from "react/jsx-runtime";
1
+ // packages/editor/src/components/post-taxonomies/flat-term-selector.js
2
2
  import { __, _x, sprintf } from "@wordpress/i18n";
3
3
  import { Fragment, useEffect, useMemo, useState } from "@wordpress/element";
4
4
  import {
@@ -15,20 +15,21 @@ import { store as noticesStore } from "@wordpress/notices";
15
15
  import { store as editorStore } from "../../store";
16
16
  import { unescapeString, unescapeTerm } from "../../utils/terms";
17
17
  import MostUsedTerms from "./most-used-terms";
18
- const EMPTY_ARRAY = [];
19
- const MAX_TERMS_SUGGESTIONS = 100;
20
- const DEFAULT_QUERY = {
18
+ import { jsx, jsxs } from "react/jsx-runtime";
19
+ var EMPTY_ARRAY = [];
20
+ var MAX_TERMS_SUGGESTIONS = 100;
21
+ var DEFAULT_QUERY = {
21
22
  per_page: MAX_TERMS_SUGGESTIONS,
22
23
  _fields: "id,name",
23
24
  context: "view"
24
25
  };
25
- const isSameTermName = (termA, termB) => unescapeString(termA).toLowerCase() === unescapeString(termB).toLowerCase();
26
- const termNamesToIds = (names, terms) => {
26
+ var isSameTermName = (termA, termB) => unescapeString(termA).toLowerCase() === unescapeString(termB).toLowerCase();
27
+ var termNamesToIds = (names, terms) => {
27
28
  return names.map(
28
29
  (termName) => terms.find((term) => isSameTermName(term.name, termName))?.id
29
30
  ).filter((id) => id !== void 0);
30
31
  };
31
- const Wrapper = ({ children, __nextHasNoMarginBottom }) => __nextHasNoMarginBottom ? /* @__PURE__ */ jsx(VStack, { spacing: 4, children }) : /* @__PURE__ */ jsx(Fragment, { children });
32
+ var Wrapper = ({ children, __nextHasNoMarginBottom }) => __nextHasNoMarginBottom ? /* @__PURE__ */ jsx(VStack, { spacing: 4, children }) : /* @__PURE__ */ jsx(Fragment, { children });
32
33
  function FlatTermSelector({ slug, __nextHasNoMarginBottom }) {
33
34
  const [values, setValues] = useState([]);
34
35
  const [search, setSearch] = useState("");