@wordpress/editor 14.32.0 → 14.32.1-next.ff1cebbba.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1263) hide show
  1. package/build/bindings/api.js +45 -33
  2. package/build/bindings/api.js.map +7 -1
  3. package/build/bindings/entity.js +78 -0
  4. package/build/bindings/entity.js.map +7 -0
  5. package/build/bindings/pattern-overrides.js +58 -65
  6. package/build/bindings/pattern-overrides.js.map +7 -1
  7. package/build/bindings/post-data.js +71 -91
  8. package/build/bindings/post-data.js.map +7 -1
  9. package/build/bindings/post-meta.js +74 -106
  10. package/build/bindings/post-meta.js.map +7 -1
  11. package/build/components/autocompleters/index.js +36 -11
  12. package/build/components/autocompleters/index.js.map +7 -1
  13. package/build/components/autocompleters/user.js +66 -54
  14. package/build/components/autocompleters/user.js.map +7 -1
  15. package/build/components/autosave-monitor/index.js +59 -73
  16. package/build/components/autosave-monitor/index.js.map +7 -1
  17. package/build/components/block-removal-warnings/index.js +81 -57
  18. package/build/components/block-removal-warnings/index.js.map +7 -1
  19. package/build/components/block-settings-menu/content-only-settings-menu.js +161 -121
  20. package/build/components/block-settings-menu/content-only-settings-menu.js.map +7 -1
  21. package/build/components/block-settings-menu/plugin-block-settings-menu-item.js +42 -99
  22. package/build/components/block-settings-menu/plugin-block-settings-menu-item.js.map +7 -1
  23. package/build/components/block-visibility/index.js +123 -0
  24. package/build/components/block-visibility/index.js.map +7 -0
  25. package/build/components/blog-title/index.js +127 -108
  26. package/build/components/blog-title/index.js.map +7 -1
  27. package/build/components/character-count/index.js +30 -23
  28. package/build/components/character-count/index.js.map +7 -1
  29. package/build/components/collab-sidebar/add-comment.js +89 -70
  30. package/build/components/collab-sidebar/add-comment.js.map +7 -1
  31. package/build/components/collab-sidebar/comment-author-info.js +72 -84
  32. package/build/components/collab-sidebar/comment-author-info.js.map +7 -1
  33. package/build/components/collab-sidebar/comment-form.js +92 -81
  34. package/build/components/collab-sidebar/comment-form.js.map +7 -1
  35. package/build/components/collab-sidebar/comment-indicator-toolbar.js +96 -83
  36. package/build/components/collab-sidebar/comment-indicator-toolbar.js.map +7 -1
  37. package/build/components/collab-sidebar/comment-menu-item.js +46 -0
  38. package/build/components/collab-sidebar/comment-menu-item.js.map +7 -0
  39. package/build/components/collab-sidebar/comments.js +544 -317
  40. package/build/components/collab-sidebar/comments.js.map +7 -1
  41. package/build/components/collab-sidebar/constants.js +30 -7
  42. package/build/components/collab-sidebar/constants.js.map +7 -1
  43. package/build/components/collab-sidebar/hooks.js +312 -58
  44. package/build/components/collab-sidebar/hooks.js.map +7 -1
  45. package/build/components/collab-sidebar/index.js +183 -252
  46. package/build/components/collab-sidebar/index.js.map +7 -1
  47. package/build/components/collab-sidebar/utils.js +94 -79
  48. package/build/components/collab-sidebar/utils.js.map +7 -1
  49. package/build/components/collapsible-block-toolbar/index.js +70 -60
  50. package/build/components/collapsible-block-toolbar/index.js.map +7 -1
  51. package/build/components/commands/index.js +218 -268
  52. package/build/components/commands/index.js.map +7 -1
  53. package/build/components/deprecated.js +328 -248
  54. package/build/components/deprecated.js.map +7 -1
  55. package/build/components/document-bar/index.js +145 -153
  56. package/build/components/document-bar/index.js.map +7 -1
  57. package/build/components/document-outline/check.js +28 -27
  58. package/build/components/document-outline/check.js.map +7 -1
  59. package/build/components/document-outline/index.js +169 -207
  60. package/build/components/document-outline/index.js.map +7 -1
  61. package/build/components/document-outline/item.js +68 -35
  62. package/build/components/document-outline/item.js.map +7 -1
  63. package/build/components/document-tools/index.js +145 -133
  64. package/build/components/document-tools/index.js.map +7 -1
  65. package/build/components/editor/index.js +99 -63
  66. package/build/components/editor/index.js.map +7 -1
  67. package/build/components/editor-history/redo.js +51 -54
  68. package/build/components/editor-history/redo.js.map +7 -1
  69. package/build/components/editor-history/undo.js +50 -53
  70. package/build/components/editor-history/undo.js.map +7 -1
  71. package/build/components/editor-interface/content-slot-fill.js +27 -12
  72. package/build/components/editor-interface/content-slot-fill.js.map +7 -1
  73. package/build/components/editor-interface/index.js +142 -127
  74. package/build/components/editor-interface/index.js.map +7 -1
  75. package/build/components/editor-notices/index.js +74 -58
  76. package/build/components/editor-notices/index.js.map +7 -1
  77. package/build/components/editor-snackbars/index.js +40 -32
  78. package/build/components/editor-snackbars/index.js.map +7 -1
  79. package/build/components/entities-saved-states/entity-record-item.js +70 -70
  80. package/build/components/entities-saved-states/entity-record-item.js.map +7 -1
  81. package/build/components/entities-saved-states/entity-type-list.js +108 -78
  82. package/build/components/entities-saved-states/entity-type-list.js.map +7 -1
  83. package/build/components/entities-saved-states/hooks/use-is-dirty.js +62 -61
  84. package/build/components/entities-saved-states/hooks/use-is-dirty.js.map +7 -1
  85. package/build/components/entities-saved-states/index.js +177 -161
  86. package/build/components/entities-saved-states/index.js.map +7 -1
  87. package/build/components/error-boundary/index.js +59 -85
  88. package/build/components/error-boundary/index.js.map +7 -1
  89. package/build/components/global-keyboard-shortcuts/index.js +58 -71
  90. package/build/components/global-keyboard-shortcuts/index.js.map +7 -1
  91. package/build/components/global-keyboard-shortcuts/register-shortcuts.js +106 -93
  92. package/build/components/global-keyboard-shortcuts/register-shortcuts.js.map +7 -1
  93. package/build/components/global-styles-provider/index.js +173 -146
  94. package/build/components/global-styles-provider/index.js.map +7 -1
  95. package/build/components/header/back-button.js +40 -26
  96. package/build/components/header/back-button.js.map +7 -1
  97. package/build/components/header/index.js +175 -162
  98. package/build/components/header/index.js.map +7 -1
  99. package/build/components/index.js +311 -780
  100. package/build/components/index.js.map +7 -1
  101. package/build/components/inserter-sidebar/index.js +62 -71
  102. package/build/components/inserter-sidebar/index.js.map +7 -1
  103. package/build/components/keyboard-shortcut-help-modal/config.js +74 -70
  104. package/build/components/keyboard-shortcut-help-modal/config.js.map +7 -1
  105. package/build/components/keyboard-shortcut-help-modal/dynamic-shortcut.js +61 -43
  106. package/build/components/keyboard-shortcut-help-modal/dynamic-shortcut.js.map +7 -1
  107. package/build/components/keyboard-shortcut-help-modal/index.js +165 -111
  108. package/build/components/keyboard-shortcut-help-modal/index.js.map +7 -1
  109. package/build/components/keyboard-shortcut-help-modal/shortcut.js +76 -55
  110. package/build/components/keyboard-shortcut-help-modal/shortcut.js.map +7 -1
  111. package/build/components/list-view-sidebar/index.js +117 -121
  112. package/build/components/list-view-sidebar/index.js.map +7 -1
  113. package/build/components/list-view-sidebar/list-view-outline.js +56 -41
  114. package/build/components/list-view-sidebar/list-view-outline.js.map +7 -1
  115. package/build/components/local-autosave-monitor/index.js +118 -148
  116. package/build/components/local-autosave-monitor/index.js.map +7 -1
  117. package/build/components/media-categories/index.js +160 -144
  118. package/build/components/media-categories/index.js.map +7 -1
  119. package/build/components/mode-switcher/index.js +68 -63
  120. package/build/components/mode-switcher/index.js.map +7 -1
  121. package/build/components/more-menu/copy-content-menu-item.js +46 -43
  122. package/build/components/more-menu/copy-content-menu-item.js.map +7 -1
  123. package/build/components/more-menu/index.js +174 -119
  124. package/build/components/more-menu/index.js.map +7 -1
  125. package/build/components/more-menu/tools-more-menu-group.js +27 -21
  126. package/build/components/more-menu/tools-more-menu-group.js.map +7 -1
  127. package/build/components/more-menu/view-more-menu-group.js +30 -22
  128. package/build/components/more-menu/view-more-menu-group.js.map +7 -1
  129. package/build/components/page-attributes/check.js +37 -40
  130. package/build/components/page-attributes/check.js.map +7 -1
  131. package/build/components/page-attributes/order.js +66 -64
  132. package/build/components/page-attributes/order.js.map +7 -1
  133. package/build/components/page-attributes/panel.js +45 -43
  134. package/build/components/page-attributes/panel.js.map +7 -1
  135. package/build/components/page-attributes/parent.js +224 -207
  136. package/build/components/page-attributes/parent.js.map +7 -1
  137. package/build/components/pattern-duplicate-modal/index.js +58 -48
  138. package/build/components/pattern-duplicate-modal/index.js.map +7 -1
  139. package/build/components/pattern-overrides-panel/index.js +33 -23
  140. package/build/components/pattern-overrides-panel/index.js.map +7 -1
  141. package/build/components/pattern-rename-modal/index.js +51 -47
  142. package/build/components/pattern-rename-modal/index.js.map +7 -1
  143. package/build/components/plugin-document-setting-panel/index.js +74 -114
  144. package/build/components/plugin-document-setting-panel/index.js.map +7 -1
  145. package/build/components/plugin-more-menu-item/index.js +37 -78
  146. package/build/components/plugin-more-menu-item/index.js.map +7 -1
  147. package/build/components/plugin-post-publish-panel/index.js +37 -59
  148. package/build/components/plugin-post-publish-panel/index.js.map +7 -1
  149. package/build/components/plugin-post-status-info/index.js +27 -73
  150. package/build/components/plugin-post-status-info/index.js.map +7 -1
  151. package/build/components/plugin-pre-publish-panel/index.js +37 -62
  152. package/build/components/plugin-pre-publish-panel/index.js.map +7 -1
  153. package/build/components/plugin-preview-menu-item/index.js +37 -57
  154. package/build/components/plugin-preview-menu-item/index.js.map +7 -1
  155. package/build/components/plugin-sidebar/index.js +34 -86
  156. package/build/components/plugin-sidebar/index.js.map +7 -1
  157. package/build/components/plugin-sidebar-more-menu-item/index.js +33 -67
  158. package/build/components/plugin-sidebar-more-menu-item/index.js.map +7 -1
  159. package/build/components/post-actions/actions.js +111 -103
  160. package/build/components/post-actions/actions.js.map +7 -1
  161. package/build/components/post-actions/index.js +126 -131
  162. package/build/components/post-actions/index.js.map +7 -1
  163. package/build/components/post-actions/set-as-homepage.js +123 -123
  164. package/build/components/post-actions/set-as-homepage.js.map +7 -1
  165. package/build/components/post-actions/set-as-posts-page.js +118 -120
  166. package/build/components/post-actions/set-as-posts-page.js.map +7 -1
  167. package/build/components/post-author/check.js +41 -38
  168. package/build/components/post-author/check.js.map +7 -1
  169. package/build/components/post-author/combobox.js +50 -52
  170. package/build/components/post-author/combobox.js.map +7 -1
  171. package/build/components/post-author/constants.js +34 -10
  172. package/build/components/post-author/constants.js.map +7 -1
  173. package/build/components/post-author/hook.js +71 -71
  174. package/build/components/post-author/hook.js.map +7 -1
  175. package/build/components/post-author/index.js +43 -31
  176. package/build/components/post-author/index.js.map +7 -1
  177. package/build/components/post-author/panel.js +106 -95
  178. package/build/components/post-author/panel.js.map +7 -1
  179. package/build/components/post-author/select.js +45 -40
  180. package/build/components/post-author/select.js.map +7 -1
  181. package/build/components/post-card-panel/index.js +128 -113
  182. package/build/components/post-card-panel/index.js.map +7 -1
  183. package/build/components/post-comments/index.js +60 -55
  184. package/build/components/post-comments/index.js.map +7 -1
  185. package/build/components/post-content-information/index.js +64 -65
  186. package/build/components/post-content-information/index.js.map +7 -1
  187. package/build/components/post-discussion/panel.js +114 -128
  188. package/build/components/post-discussion/panel.js.map +7 -1
  189. package/build/components/post-excerpt/check.js +37 -27
  190. package/build/components/post-excerpt/check.js.map +7 -1
  191. package/build/components/post-excerpt/index.js +75 -71
  192. package/build/components/post-excerpt/index.js.map +7 -1
  193. package/build/components/post-excerpt/panel.js +152 -141
  194. package/build/components/post-excerpt/panel.js.map +7 -1
  195. package/build/components/post-excerpt/plugin.js +28 -70
  196. package/build/components/post-excerpt/plugin.js.map +7 -1
  197. package/build/components/post-featured-image/check.js +38 -32
  198. package/build/components/post-featured-image/check.js.map +7 -1
  199. package/build/components/post-featured-image/index.js +224 -211
  200. package/build/components/post-featured-image/index.js.map +7 -1
  201. package/build/components/post-featured-image/panel.js +55 -59
  202. package/build/components/post-featured-image/panel.js.map +7 -1
  203. package/build/components/post-fields/index.js +55 -56
  204. package/build/components/post-fields/index.js.map +7 -1
  205. package/build/components/post-format/check.js +42 -33
  206. package/build/components/post-format/check.js.map +7 -1
  207. package/build/components/post-format/index.js +100 -113
  208. package/build/components/post-format/index.js.map +7 -1
  209. package/build/components/post-format/panel.js +91 -82
  210. package/build/components/post-format/panel.js.map +7 -1
  211. package/build/components/post-last-edited-panel/index.js +38 -29
  212. package/build/components/post-last-edited-panel/index.js.map +7 -1
  213. package/build/components/post-last-revision/check.js +41 -41
  214. package/build/components/post-last-revision/check.js.map +7 -1
  215. package/build/components/post-last-revision/index.js +75 -66
  216. package/build/components/post-last-revision/index.js.map +7 -1
  217. package/build/components/post-last-revision/panel.js +39 -30
  218. package/build/components/post-last-revision/panel.js.map +7 -1
  219. package/build/components/post-locked-modal/index.js +148 -145
  220. package/build/components/post-locked-modal/index.js.map +7 -1
  221. package/build/components/post-panel-row/index.js +49 -35
  222. package/build/components/post-panel-row/index.js.map +7 -1
  223. package/build/components/post-panel-section/index.js +38 -26
  224. package/build/components/post-panel-section/index.js.map +7 -1
  225. package/build/components/post-pending-status/check.js +34 -40
  226. package/build/components/post-pending-status/check.js.map +7 -1
  227. package/build/components/post-pending-status/index.js +58 -41
  228. package/build/components/post-pending-status/index.js.map +7 -1
  229. package/build/components/post-pingbacks/index.js +52 -44
  230. package/build/components/post-pingbacks/index.js.map +7 -1
  231. package/build/components/post-preview-button/index.js +90 -120
  232. package/build/components/post-preview-button/index.js.map +7 -1
  233. package/build/components/post-publish-button/index.js +125 -137
  234. package/build/components/post-publish-button/index.js.map +7 -1
  235. package/build/components/post-publish-button/label.js +39 -40
  236. package/build/components/post-publish-button/label.js.map +7 -1
  237. package/build/components/post-publish-button/post-publish-button-or-toggle.js +62 -68
  238. package/build/components/post-publish-button/post-publish-button-or-toggle.js.map +7 -1
  239. package/build/components/post-publish-panel/index.js +136 -135
  240. package/build/components/post-publish-panel/index.js.map +7 -1
  241. package/build/components/post-publish-panel/maybe-category-panel.js +71 -67
  242. package/build/components/post-publish-panel/maybe-category-panel.js.map +7 -1
  243. package/build/components/post-publish-panel/maybe-post-format-panel.js +72 -63
  244. package/build/components/post-publish-panel/maybe-post-format-panel.js.map +7 -1
  245. package/build/components/post-publish-panel/maybe-tags-panel.js +86 -80
  246. package/build/components/post-publish-panel/maybe-tags-panel.js.map +7 -1
  247. package/build/components/post-publish-panel/maybe-upload-media.js +172 -214
  248. package/build/components/post-publish-panel/maybe-upload-media.js.map +7 -1
  249. package/build/components/post-publish-panel/media-util.js +63 -72
  250. package/build/components/post-publish-panel/media-util.js.map +7 -1
  251. package/build/components/post-publish-panel/postpublish.js +135 -130
  252. package/build/components/post-publish-panel/postpublish.js.map +7 -1
  253. package/build/components/post-publish-panel/prepublish.js +137 -103
  254. package/build/components/post-publish-panel/prepublish.js.map +7 -1
  255. package/build/components/post-saved-state/index.js +115 -131
  256. package/build/components/post-saved-state/index.js.map +7 -1
  257. package/build/components/post-schedule/check.js +27 -29
  258. package/build/components/post-schedule/check.js.map +7 -1
  259. package/build/components/post-schedule/index.js +96 -93
  260. package/build/components/post-schedule/index.js.map +7 -1
  261. package/build/components/post-schedule/label.js +79 -86
  262. package/build/components/post-schedule/label.js.map +7 -1
  263. package/build/components/post-schedule/panel.js +88 -73
  264. package/build/components/post-schedule/panel.js.map +7 -1
  265. package/build/components/post-status/index.js +238 -202
  266. package/build/components/post-status/index.js.map +7 -1
  267. package/build/components/post-sticky/check.js +30 -35
  268. package/build/components/post-sticky/check.js.map +7 -1
  269. package/build/components/post-sticky/index.js +50 -40
  270. package/build/components/post-sticky/index.js.map +7 -1
  271. package/build/components/post-sticky/panel.js +43 -21
  272. package/build/components/post-sticky/panel.js.map +7 -1
  273. package/build/components/post-switch-to-draft-button/index.js +80 -75
  274. package/build/components/post-switch-to-draft-button/index.js.map +7 -1
  275. package/build/components/post-sync-status/index.js +45 -44
  276. package/build/components/post-sync-status/index.js.map +7 -1
  277. package/build/components/post-taxonomies/check.js +36 -33
  278. package/build/components/post-taxonomies/check.js.map +7 -1
  279. package/build/components/post-taxonomies/flat-term-selector.js +189 -189
  280. package/build/components/post-taxonomies/flat-term-selector.js.map +7 -1
  281. package/build/components/post-taxonomies/hierarchical-term-selector.js +244 -280
  282. package/build/components/post-taxonomies/hierarchical-term-selector.js.map +7 -1
  283. package/build/components/post-taxonomies/index.js +68 -58
  284. package/build/components/post-taxonomies/index.js.map +7 -1
  285. package/build/components/post-taxonomies/most-used-terms.js +73 -56
  286. package/build/components/post-taxonomies/most-used-terms.js.map +7 -1
  287. package/build/components/post-taxonomies/panel.js +66 -69
  288. package/build/components/post-taxonomies/panel.js.map +7 -1
  289. package/build/components/post-template/block-theme.js +165 -123
  290. package/build/components/post-template/block-theme.js.map +7 -1
  291. package/build/components/post-template/classic-theme.js +193 -187
  292. package/build/components/post-template/classic-theme.js.map +7 -1
  293. package/build/components/post-template/create-new-template-modal.js +139 -110
  294. package/build/components/post-template/create-new-template-modal.js.map +7 -1
  295. package/build/components/post-template/create-new-template.js +65 -46
  296. package/build/components/post-template/create-new-template.js.map +7 -1
  297. package/build/components/post-template/hooks.js +116 -84
  298. package/build/components/post-template/hooks.js.map +7 -1
  299. package/build/components/post-template/panel.js +56 -52
  300. package/build/components/post-template/panel.js.map +7 -1
  301. package/build/components/post-template/reset-default-template.js +49 -43
  302. package/build/components/post-template/reset-default-template.js.map +7 -1
  303. package/build/components/post-template/swap-template-button.js +109 -91
  304. package/build/components/post-template/swap-template-button.js.map +7 -1
  305. package/build/components/post-text-editor/index.js +80 -81
  306. package/build/components/post-text-editor/index.js.map +7 -1
  307. package/build/components/post-title/constants.js +30 -7
  308. package/build/components/post-title/constants.js.map +7 -1
  309. package/build/components/post-title/index.js +99 -126
  310. package/build/components/post-title/index.js.map +7 -1
  311. package/build/components/post-title/post-title-raw.js +74 -78
  312. package/build/components/post-title/post-title-raw.js.map +7 -1
  313. package/build/components/post-title/use-post-title-focus.js +35 -52
  314. package/build/components/post-title/use-post-title-focus.js.map +7 -1
  315. package/build/components/post-title/use-post-title.js +30 -37
  316. package/build/components/post-title/use-post-title.js.map +7 -1
  317. package/build/components/post-transform-panel/hooks.js +70 -67
  318. package/build/components/post-transform-panel/hooks.js.map +7 -1
  319. package/build/components/post-transform-panel/index.js +69 -75
  320. package/build/components/post-transform-panel/index.js.map +7 -1
  321. package/build/components/post-trash/check.js +33 -42
  322. package/build/components/post-trash/check.js.map +7 -1
  323. package/build/components/post-trash/index.js +78 -67
  324. package/build/components/post-trash/index.js.map +7 -1
  325. package/build/components/post-type-support-check/index.js +34 -47
  326. package/build/components/post-type-support-check/index.js.map +7 -1
  327. package/build/components/post-url/check.js +31 -32
  328. package/build/components/post-url/check.js.map +7 -1
  329. package/build/components/post-url/index.js +155 -156
  330. package/build/components/post-url/index.js.map +7 -1
  331. package/build/components/post-url/label.js +35 -30
  332. package/build/components/post-url/label.js.map +7 -1
  333. package/build/components/post-url/panel.js +111 -112
  334. package/build/components/post-url/panel.js.map +7 -1
  335. package/build/components/post-view-link/index.js +48 -47
  336. package/build/components/post-view-link/index.js.map +7 -1
  337. package/build/components/post-visibility/check.js +28 -33
  338. package/build/components/post-visibility/check.js.map +7 -1
  339. package/build/components/post-visibility/index.js +83 -84
  340. package/build/components/post-visibility/index.js.map +7 -1
  341. package/build/components/post-visibility/label.js +35 -30
  342. package/build/components/post-visibility/label.js.map +7 -1
  343. package/build/components/post-visibility/utils.js +44 -23
  344. package/build/components/post-visibility/utils.js.map +7 -1
  345. package/build/components/posts-per-page/index.js +110 -98
  346. package/build/components/posts-per-page/index.js.map +7 -1
  347. package/build/components/preferences-modal/enable-panel.js +47 -42
  348. package/build/components/preferences-modal/enable-panel.js.map +7 -1
  349. package/build/components/preferences-modal/enable-plugin-document-setting-panel.js +40 -31
  350. package/build/components/preferences-modal/enable-plugin-document-setting-panel.js.map +7 -1
  351. package/build/components/preferences-modal/enable-publish-sidebar.js +39 -32
  352. package/build/components/preferences-modal/enable-publish-sidebar.js.map +7 -1
  353. package/build/components/preferences-modal/index.js +391 -231
  354. package/build/components/preferences-modal/index.js.map +7 -1
  355. package/build/components/preview-dropdown/index.js +165 -151
  356. package/build/components/preview-dropdown/index.js.map +7 -1
  357. package/build/components/provider/disable-non-page-content-blocks.js +67 -82
  358. package/build/components/provider/disable-non-page-content-blocks.js.map +7 -1
  359. package/build/components/provider/index.js +283 -325
  360. package/build/components/provider/index.js.map +7 -1
  361. package/build/components/provider/navigation-block-editing-mode.js +32 -29
  362. package/build/components/provider/navigation-block-editing-mode.js.map +7 -1
  363. package/build/components/provider/use-auto-switch-editor-sidebars.js +48 -39
  364. package/build/components/provider/use-auto-switch-editor-sidebars.js.map +7 -1
  365. package/build/components/provider/use-block-editor-settings.js +249 -178
  366. package/build/components/provider/use-block-editor-settings.js.map +7 -1
  367. package/build/components/provider/use-hide-blocks-from-inserter.js +87 -46
  368. package/build/components/provider/use-hide-blocks-from-inserter.js.map +7 -1
  369. package/build/components/provider/use-post-content-blocks.js +48 -29
  370. package/build/components/provider/use-post-content-blocks.js.map +7 -1
  371. package/build/components/provider/with-registry-provider.js +52 -46
  372. package/build/components/provider/with-registry-provider.js.map +7 -1
  373. package/build/components/resizable-editor/index.js +99 -86
  374. package/build/components/resizable-editor/index.js.map +7 -1
  375. package/build/components/resizable-editor/resize-handle.js +42 -36
  376. package/build/components/resizable-editor/resize-handle.js.map +7 -1
  377. package/build/components/save-publish-panels/index.js +88 -69
  378. package/build/components/save-publish-panels/index.js.map +7 -1
  379. package/build/components/sidebar/constants.js +29 -8
  380. package/build/components/sidebar/constants.js.map +7 -1
  381. package/build/components/sidebar/header.js +56 -50
  382. package/build/components/sidebar/header.js.map +7 -1
  383. package/build/components/sidebar/index.js +156 -136
  384. package/build/components/sidebar/index.js.map +7 -1
  385. package/build/components/sidebar/post-summary.js +114 -91
  386. package/build/components/sidebar/post-summary.js.map +7 -1
  387. package/build/components/site-discussion/index.js +132 -113
  388. package/build/components/site-discussion/index.js.map +7 -1
  389. package/build/components/start-page-options/index.js +136 -146
  390. package/build/components/start-page-options/index.js.map +7 -1
  391. package/build/components/start-template-options/index.js +168 -157
  392. package/build/components/start-template-options/index.js.map +7 -1
  393. package/build/components/table-of-contents/index.js +78 -69
  394. package/build/components/table-of-contents/index.js.map +7 -1
  395. package/build/components/table-of-contents/panel.js +101 -94
  396. package/build/components/table-of-contents/panel.js.map +7 -1
  397. package/build/components/template-content-panel/index.js +74 -58
  398. package/build/components/template-content-panel/index.js.map +7 -1
  399. package/build/components/template-part-content-panel/index.js +51 -54
  400. package/build/components/template-part-content-panel/index.js.map +7 -1
  401. package/build/components/template-part-menu-items/convert-to-regular.js +44 -32
  402. package/build/components/template-part-menu-items/convert-to-regular.js.map +7 -1
  403. package/build/components/template-part-menu-items/convert-to-template-part.js +76 -68
  404. package/build/components/template-part-menu-items/convert-to-template-part.js.map +7 -1
  405. package/build/components/template-part-menu-items/index.js +62 -52
  406. package/build/components/template-part-menu-items/index.js.map +7 -1
  407. package/build/components/template-validation-notice/index.js +71 -47
  408. package/build/components/template-validation-notice/index.js.map +7 -1
  409. package/build/components/text-editor/index.js +68 -62
  410. package/build/components/text-editor/index.js.map +7 -1
  411. package/build/components/theme-support-check/index.js +32 -43
  412. package/build/components/theme-support-check/index.js.map +7 -1
  413. package/build/components/time-to-read/index.js +54 -51
  414. package/build/components/time-to-read/index.js.map +7 -1
  415. package/build/components/unsaved-changes-warning/index.js +34 -38
  416. package/build/components/unsaved-changes-warning/index.js.map +7 -1
  417. package/build/components/visual-editor/edit-template-blocks-notification.js +64 -68
  418. package/build/components/visual-editor/edit-template-blocks-notification.js.map +7 -1
  419. package/build/components/visual-editor/index.js +286 -247
  420. package/build/components/visual-editor/index.js.map +7 -1
  421. package/build/components/visual-editor/use-select-nearest-editable-block.js +75 -68
  422. package/build/components/visual-editor/use-select-nearest-editable-block.js.map +7 -1
  423. package/build/components/visual-editor/use-zoom-out-mode-exit.js +52 -46
  424. package/build/components/visual-editor/use-zoom-out-mode-exit.js.map +7 -1
  425. package/build/components/word-count/index.js +34 -35
  426. package/build/components/word-count/index.js.map +7 -1
  427. package/build/components/zoom-out-toggle/index.js +88 -72
  428. package/build/components/zoom-out-toggle/index.js.map +7 -1
  429. package/build/dataviews/api.js +47 -80
  430. package/build/dataviews/api.js.map +7 -1
  431. package/build/dataviews/fields/content-preview/content-preview-view.js +81 -89
  432. package/build/dataviews/fields/content-preview/content-preview-view.js.map +7 -1
  433. package/build/dataviews/fields/content-preview/index.js +39 -21
  434. package/build/dataviews/fields/content-preview/index.js.map +7 -1
  435. package/build/dataviews/store/private-actions.js +122 -56
  436. package/build/dataviews/store/private-actions.js.map +7 -1
  437. package/build/dataviews/store/private-selectors.js +32 -15
  438. package/build/dataviews/store/private-selectors.js.map +7 -1
  439. package/build/dataviews/store/reducer.js +50 -31
  440. package/build/dataviews/store/reducer.js.map +7 -1
  441. package/build/hooks/custom-sources-backwards-compatibility.js +70 -83
  442. package/build/hooks/custom-sources-backwards-compatibility.js.map +7 -1
  443. package/build/hooks/default-autocompleters.js +9 -17
  444. package/build/hooks/default-autocompleters.js.map +7 -1
  445. package/build/hooks/index.js +7 -7
  446. package/build/hooks/index.js.map +7 -1
  447. package/build/hooks/media-upload.js +8 -9
  448. package/build/hooks/media-upload.js.map +7 -1
  449. package/build/hooks/navigation-link-view-button.js +44 -66
  450. package/build/hooks/navigation-link-view-button.js.map +7 -1
  451. package/build/hooks/pattern-overrides.js +51 -70
  452. package/build/hooks/pattern-overrides.js.map +7 -1
  453. package/build/hooks/template-part-navigation-edit-button.js +91 -0
  454. package/build/hooks/template-part-navigation-edit-button.js.map +7 -0
  455. package/build/index.js +41 -77
  456. package/build/index.js.map +7 -1
  457. package/build/lock-unlock.js +31 -14
  458. package/build/lock-unlock.js.map +7 -1
  459. package/build/private-apis.js +76 -59
  460. package/build/private-apis.js.map +7 -1
  461. package/build/store/actions.js +516 -931
  462. package/build/store/actions.js.map +7 -1
  463. package/build/store/constants.js +70 -31
  464. package/build/store/constants.js.map +7 -1
  465. package/build/store/defaults.js +31 -33
  466. package/build/store/defaults.js.map +7 -1
  467. package/build/store/index.js +52 -41
  468. package/build/store/index.js.map +7 -1
  469. package/build/store/local-autosave.js +39 -27
  470. package/build/store/local-autosave.js.map +7 -1
  471. package/build/store/private-actions.js +290 -299
  472. package/build/store/private-actions.js.map +7 -1
  473. package/build/store/private-selectors.js +189 -188
  474. package/build/store/private-selectors.js.map +7 -1
  475. package/build/store/reducer.js +128 -280
  476. package/build/store/reducer.js.map +7 -1
  477. package/build/store/selectors.js +819 -1470
  478. package/build/store/selectors.js.map +7 -1
  479. package/build/store/utils/is-template-revertable.js +24 -19
  480. package/build/store/utils/is-template-revertable.js.map +7 -1
  481. package/build/store/utils/notice-builder.js +73 -94
  482. package/build/store/utils/notice-builder.js.map +7 -1
  483. package/build/utils/get-item-title.js +34 -25
  484. package/build/utils/get-item-title.js.map +7 -1
  485. package/build/utils/get-template-info.js +37 -46
  486. package/build/utils/get-template-info.js.map +7 -1
  487. package/build/utils/get-template-part-icon.js +34 -24
  488. package/build/utils/get-template-part-icon.js.map +7 -1
  489. package/build/utils/index.js +41 -24
  490. package/build/utils/index.js.map +7 -1
  491. package/build/utils/media-sideload/index.js +26 -19
  492. package/build/utils/media-sideload/index.js.map +7 -1
  493. package/build/utils/media-upload/index.js +46 -63
  494. package/build/utils/media-upload/index.js.map +7 -1
  495. package/build/utils/pageTypeBadge.js +33 -31
  496. package/build/utils/pageTypeBadge.js.map +7 -1
  497. package/build/utils/search-templates.js +45 -47
  498. package/build/utils/search-templates.js.map +7 -1
  499. package/build/utils/terms.js +57 -63
  500. package/build/utils/terms.js.map +7 -1
  501. package/build/utils/url.js +43 -33
  502. package/build/utils/url.js.map +7 -1
  503. package/build-module/bindings/api.js +11 -26
  504. package/build-module/bindings/api.js.map +7 -1
  505. package/build-module/bindings/entity.js +58 -0
  506. package/build-module/bindings/entity.js.map +7 -0
  507. package/build-module/bindings/pattern-overrides.js +39 -59
  508. package/build-module/bindings/pattern-overrides.js.map +7 -1
  509. package/build-module/bindings/post-data.js +53 -87
  510. package/build-module/bindings/post-data.js.map +7 -1
  511. package/build-module/bindings/post-meta.js +55 -101
  512. package/build-module/bindings/post-meta.js.map +7 -1
  513. package/build-module/components/autocompleters/index.js +5 -2
  514. package/build-module/components/autocompleters/index.js.map +7 -1
  515. package/build-module/components/autocompleters/user.js +45 -49
  516. package/build-module/components/autocompleters/user.js.map +7 -1
  517. package/build-module/components/autosave-monitor/index.js +37 -67
  518. package/build-module/components/autosave-monitor/index.js.map +7 -1
  519. package/build-module/components/block-removal-warnings/index.js +64 -54
  520. package/build-module/components/block-removal-warnings/index.js.map +7 -1
  521. package/build-module/components/block-settings-menu/content-only-settings-menu.js +136 -113
  522. package/build-module/components/block-settings-menu/content-only-settings-menu.js.map +7 -1
  523. package/build-module/components/block-settings-menu/plugin-block-settings-menu-item.js +23 -93
  524. package/build-module/components/block-settings-menu/plugin-block-settings-menu-item.js.map +7 -1
  525. package/build-module/components/block-visibility/index.js +103 -0
  526. package/build-module/components/block-visibility/index.js.map +7 -0
  527. package/build-module/components/blog-title/index.js +102 -101
  528. package/build-module/components/blog-title/index.js.map +7 -1
  529. package/build-module/components/character-count/index.js +13 -20
  530. package/build-module/components/character-count/index.js.map +7 -1
  531. package/build-module/components/collab-sidebar/add-comment.js +64 -66
  532. package/build-module/components/collab-sidebar/add-comment.js.map +7 -1
  533. package/build-module/components/collab-sidebar/comment-author-info.js +55 -77
  534. package/build-module/components/collab-sidebar/comment-author-info.js.map +7 -1
  535. package/build-module/components/collab-sidebar/comment-form.js +68 -75
  536. package/build-module/components/collab-sidebar/comment-form.js.map +7 -1
  537. package/build-module/components/collab-sidebar/comment-indicator-toolbar.js +67 -76
  538. package/build-module/components/collab-sidebar/comment-indicator-toolbar.js.map +7 -1
  539. package/build-module/components/collab-sidebar/comment-menu-item.js +26 -0
  540. package/build-module/components/collab-sidebar/comment-menu-item.js.map +7 -0
  541. package/build-module/components/collab-sidebar/comments.js +521 -309
  542. package/build-module/components/collab-sidebar/comments.js.map +7 -1
  543. package/build-module/components/collab-sidebar/constants.js +7 -3
  544. package/build-module/components/collab-sidebar/constants.js.map +7 -1
  545. package/build-module/components/collab-sidebar/hooks.js +301 -54
  546. package/build-module/components/collab-sidebar/hooks.js.map +7 -1
  547. package/build-module/components/collab-sidebar/index.js +158 -245
  548. package/build-module/components/collab-sidebar/index.js.map +7 -1
  549. package/build-module/components/collab-sidebar/utils.js +71 -76
  550. package/build-module/components/collab-sidebar/utils.js.map +7 -1
  551. package/build-module/components/collapsible-block-toolbar/index.js +44 -52
  552. package/build-module/components/collapsible-block-toolbar/index.js.map +7 -1
  553. package/build-module/components/commands/index.js +188 -241
  554. package/build-module/components/commands/index.js.map +7 -1
  555. package/build-module/components/deprecated.js +297 -237
  556. package/build-module/components/deprecated.js.map +7 -1
  557. package/build-module/components/document-bar/index.js +114 -141
  558. package/build-module/components/document-bar/index.js.map +7 -1
  559. package/build-module/components/document-outline/check.js +10 -23
  560. package/build-module/components/document-outline/check.js.map +7 -1
  561. package/build-module/components/document-outline/index.js +141 -203
  562. package/build-module/components/document-outline/index.js.map +7 -1
  563. package/build-module/components/document-outline/item.js +40 -29
  564. package/build-module/components/document-outline/item.js.map +7 -1
  565. package/build-module/components/document-tools/index.js +115 -125
  566. package/build-module/components/document-tools/index.js.map +7 -1
  567. package/build-module/components/editor/index.js +71 -57
  568. package/build-module/components/editor/index.js.map +7 -1
  569. package/build-module/components/editor-history/redo.js +33 -49
  570. package/build-module/components/editor-history/redo.js.map +7 -1
  571. package/build-module/components/editor-history/undo.js +32 -48
  572. package/build-module/components/editor-history/undo.js.map +7 -1
  573. package/build-module/components/editor-interface/content-slot-fill.js +9 -7
  574. package/build-module/components/editor-interface/content-slot-fill.js.map +7 -1
  575. package/build-module/components/editor-interface/index.js +111 -118
  576. package/build-module/components/editor-interface/index.js.map +7 -1
  577. package/build-module/components/editor-notices/index.js +43 -53
  578. package/build-module/components/editor-notices/index.js.map +7 -1
  579. package/build-module/components/editor-snackbars/index.js +23 -29
  580. package/build-module/components/editor-snackbars/index.js.map +7 -1
  581. package/build-module/components/entities-saved-states/entity-record-item.js +52 -65
  582. package/build-module/components/entities-saved-states/entity-record-item.js.map +7 -1
  583. package/build-module/components/entities-saved-states/entity-type-list.js +81 -73
  584. package/build-module/components/entities-saved-states/entity-type-list.js.map +7 -1
  585. package/build-module/components/entities-saved-states/hooks/use-is-dirty.js +39 -55
  586. package/build-module/components/entities-saved-states/hooks/use-is-dirty.js.map +7 -1
  587. package/build-module/components/entities-saved-states/index.js +150 -152
  588. package/build-module/components/entities-saved-states/index.js.map +7 -1
  589. package/build-module/components/error-boundary/index.js +42 -77
  590. package/build-module/components/error-boundary/index.js.map +7 -1
  591. package/build-module/components/global-keyboard-shortcuts/index.js +39 -66
  592. package/build-module/components/global-keyboard-shortcuts/index.js.map +7 -1
  593. package/build-module/components/global-keyboard-shortcuts/register-shortcuts.js +86 -88
  594. package/build-module/components/global-keyboard-shortcuts/register-shortcuts.js.map +7 -1
  595. package/build-module/components/global-styles-provider/index.js +135 -134
  596. package/build-module/components/global-styles-provider/index.js.map +7 -1
  597. package/build-module/components/header/back-button.js +20 -20
  598. package/build-module/components/header/back-button.js.map +7 -1
  599. package/build-module/components/header/index.js +148 -151
  600. package/build-module/components/header/index.js.map +7 -1
  601. package/build-module/components/index.js +192 -118
  602. package/build-module/components/index.js.map +7 -1
  603. package/build-module/components/inserter-sidebar/index.js +45 -64
  604. package/build-module/components/inserter-sidebar/index.js.map +7 -1
  605. package/build-module/components/keyboard-shortcut-help-modal/config.js +62 -75
  606. package/build-module/components/keyboard-shortcut-help-modal/config.js.map +7 -1
  607. package/build-module/components/keyboard-shortcut-help-modal/dynamic-shortcut.js +33 -37
  608. package/build-module/components/keyboard-shortcut-help-modal/dynamic-shortcut.js.map +7 -1
  609. package/build-module/components/keyboard-shortcut-help-modal/index.js +140 -105
  610. package/build-module/components/keyboard-shortcut-help-modal/index.js.map +7 -1
  611. package/build-module/components/keyboard-shortcut-help-modal/shortcut.js +58 -50
  612. package/build-module/components/keyboard-shortcut-help-modal/shortcut.js.map +7 -1
  613. package/build-module/components/list-view-sidebar/index.js +86 -109
  614. package/build-module/components/list-view-sidebar/index.js.map +7 -1
  615. package/build-module/components/list-view-sidebar/list-view-outline.js +29 -36
  616. package/build-module/components/list-view-sidebar/list-view-outline.js.map +7 -1
  617. package/build-module/components/local-autosave-monitor/index.js +81 -130
  618. package/build-module/components/local-autosave-monitor/index.js.map +7 -1
  619. package/build-module/components/media-categories/index.js +139 -137
  620. package/build-module/components/media-categories/index.js.map +7 -1
  621. package/build-module/components/mode-switcher/index.js +50 -60
  622. package/build-module/components/mode-switcher/index.js.map +7 -1
  623. package/build-module/components/more-menu/copy-content-menu-item.js +27 -37
  624. package/build-module/components/more-menu/copy-content-menu-item.js.map +7 -1
  625. package/build-module/components/more-menu/index.js +154 -113
  626. package/build-module/components/more-menu/index.js.map +7 -1
  627. package/build-module/components/more-menu/tools-more-menu-group.js +9 -16
  628. package/build-module/components/more-menu/tools-more-menu-group.js.map +7 -1
  629. package/build-module/components/more-menu/view-more-menu-group.js +12 -17
  630. package/build-module/components/more-menu/view-more-menu-group.js.map +7 -1
  631. package/build-module/components/page-attributes/check.js +15 -35
  632. package/build-module/components/page-attributes/check.js.map +7 -1
  633. package/build-module/components/page-attributes/order.js +42 -58
  634. package/build-module/components/page-attributes/order.js.map +7 -1
  635. package/build-module/components/page-attributes/panel.js +18 -37
  636. package/build-module/components/page-attributes/panel.js.map +7 -1
  637. package/build-module/components/page-attributes/parent.js +198 -197
  638. package/build-module/components/page-attributes/parent.js.map +7 -1
  639. package/build-module/components/pattern-duplicate-modal/index.js +36 -42
  640. package/build-module/components/pattern-duplicate-modal/index.js.map +7 -1
  641. package/build-module/components/pattern-overrides-panel/index.js +16 -19
  642. package/build-module/components/pattern-overrides-panel/index.js.map +7 -1
  643. package/build-module/components/pattern-rename-modal/index.js +29 -41
  644. package/build-module/components/pattern-rename-modal/index.js.map +7 -1
  645. package/build-module/components/plugin-document-setting-panel/index.js +46 -108
  646. package/build-module/components/plugin-document-setting-panel/index.js.map +7 -1
  647. package/build-module/components/plugin-more-menu-item/index.js +18 -74
  648. package/build-module/components/plugin-more-menu-item/index.js.map +7 -1
  649. package/build-module/components/plugin-post-publish-panel/index.js +19 -54
  650. package/build-module/components/plugin-post-publish-panel/index.js.map +7 -1
  651. package/build-module/components/plugin-post-status-info/index.js +9 -68
  652. package/build-module/components/plugin-post-status-info/index.js.map +7 -1
  653. package/build-module/components/plugin-pre-publish-panel/index.js +19 -57
  654. package/build-module/components/plugin-pre-publish-panel/index.js.map +7 -1
  655. package/build-module/components/plugin-preview-menu-item/index.js +18 -53
  656. package/build-module/components/plugin-preview-menu-item/index.js.map +7 -1
  657. package/build-module/components/plugin-sidebar/index.js +16 -83
  658. package/build-module/components/plugin-sidebar/index.js.map +7 -1
  659. package/build-module/components/plugin-sidebar-more-menu-item/index.js +15 -64
  660. package/build-module/components/plugin-sidebar-more-menu-item/index.js.map +7 -1
  661. package/build-module/components/post-actions/actions.js +85 -94
  662. package/build-module/components/post-actions/actions.js.map +7 -1
  663. package/build-module/components/post-actions/index.js +104 -121
  664. package/build-module/components/post-actions/index.js.map +7 -1
  665. package/build-module/components/post-actions/set-as-homepage.js +104 -115
  666. package/build-module/components/post-actions/set-as-homepage.js.map +7 -1
  667. package/build-module/components/post-actions/set-as-posts-page.js +99 -112
  668. package/build-module/components/post-actions/set-as-posts-page.js.map +7 -1
  669. package/build-module/components/post-author/check.js +12 -33
  670. package/build-module/components/post-author/check.js.map +7 -1
  671. package/build-module/components/post-author/combobox.js +32 -47
  672. package/build-module/components/post-author/combobox.js.map +7 -1
  673. package/build-module/components/post-author/constants.js +11 -6
  674. package/build-module/components/post-author/constants.js.map +7 -1
  675. package/build-module/components/post-author/hook.js +48 -65
  676. package/build-module/components/post-author/hook.js.map +7 -1
  677. package/build-module/components/post-author/index.js +14 -24
  678. package/build-module/components/post-author/index.js.map +7 -1
  679. package/build-module/components/post-author/panel.js +73 -87
  680. package/build-module/components/post-author/panel.js.map +7 -1
  681. package/build-module/components/post-author/select.js +28 -36
  682. package/build-module/components/post-author/select.js.map +7 -1
  683. package/build-module/components/post-card-panel/index.js +107 -105
  684. package/build-module/components/post-card-panel/index.js.map +7 -1
  685. package/build-module/components/post-comments/index.js +45 -50
  686. package/build-module/components/post-comments/index.js.map +7 -1
  687. package/build-module/components/post-content-information/index.js +49 -61
  688. package/build-module/components/post-content-information/index.js.map +7 -1
  689. package/build-module/components/post-discussion/panel.js +90 -122
  690. package/build-module/components/post-discussion/panel.js.map +7 -1
  691. package/build-module/components/post-excerpt/check.js +9 -23
  692. package/build-module/components/post-excerpt/check.js.map +7 -1
  693. package/build-module/components/post-excerpt/index.js +57 -68
  694. package/build-module/components/post-excerpt/index.js.map +7 -1
  695. package/build-module/components/post-excerpt/panel.js +124 -134
  696. package/build-module/components/post-excerpt/panel.js.map +7 -1
  697. package/build-module/components/post-excerpt/plugin.js +10 -65
  698. package/build-module/components/post-excerpt/plugin.js.map +7 -1
  699. package/build-module/components/post-featured-image/check.js +10 -28
  700. package/build-module/components/post-featured-image/check.js.map +7 -1
  701. package/build-module/components/post-featured-image/index.js +203 -200
  702. package/build-module/components/post-featured-image/index.js.map +7 -1
  703. package/build-module/components/post-featured-image/panel.js +26 -52
  704. package/build-module/components/post-featured-image/panel.js.map +7 -1
  705. package/build-module/components/post-fields/index.js +36 -49
  706. package/build-module/components/post-fields/index.js.map +7 -1
  707. package/build-module/components/post-format/check.js +14 -29
  708. package/build-module/components/post-format/check.js.map +7 -1
  709. package/build-module/components/post-format/index.js +68 -107
  710. package/build-module/components/post-format/index.js.map +7 -1
  711. package/build-module/components/post-format/panel.js +60 -73
  712. package/build-module/components/post-format/panel.js.map +7 -1
  713. package/build-module/components/post-last-edited-panel/index.js +20 -24
  714. package/build-module/components/post-last-edited-panel/index.js.map +7 -1
  715. package/build-module/components/post-last-revision/check.js +13 -37
  716. package/build-module/components/post-last-revision/check.js.map +7 -1
  717. package/build-module/components/post-last-revision/index.js +43 -59
  718. package/build-module/components/post-last-revision/index.js.map +7 -1
  719. package/build-module/components/post-last-revision/panel.js +10 -25
  720. package/build-module/components/post-last-revision/panel.js.map +7 -1
  721. package/build-module/components/post-locked-modal/index.js +133 -137
  722. package/build-module/components/post-locked-modal/index.js.map +7 -1
  723. package/build-module/components/post-panel-row/index.js +21 -29
  724. package/build-module/components/post-panel-row/index.js.map +7 -1
  725. package/build-module/components/post-panel-section/index.js +10 -20
  726. package/build-module/components/post-panel-section/index.js.map +7 -1
  727. package/build-module/components/post-pending-status/check.js +12 -35
  728. package/build-module/components/post-pending-status/check.js.map +7 -1
  729. package/build-module/components/post-pending-status/index.js +27 -36
  730. package/build-module/components/post-pending-status/index.js.map +7 -1
  731. package/build-module/components/post-pingbacks/index.js +34 -39
  732. package/build-module/components/post-pingbacks/index.js.map +7 -1
  733. package/build-module/components/post-preview-button/index.js +71 -114
  734. package/build-module/components/post-preview-button/index.js.map +7 -1
  735. package/build-module/components/post-publish-button/index.js +93 -130
  736. package/build-module/components/post-publish-button/index.js.map +7 -1
  737. package/build-module/components/post-publish-button/label.js +20 -35
  738. package/build-module/components/post-publish-button/label.js.map +7 -1
  739. package/build-module/components/post-publish-button/post-publish-button-or-toggle.js +28 -56
  740. package/build-module/components/post-publish-button/post-publish-button-or-toggle.js.map +7 -1
  741. package/build-module/components/post-publish-panel/index.js +108 -126
  742. package/build-module/components/post-publish-panel/index.js.map +7 -1
  743. package/build-module/components/post-publish-panel/maybe-category-panel.js +40 -58
  744. package/build-module/components/post-publish-panel/maybe-category-panel.js.map +7 -1
  745. package/build-module/components/post-publish-panel/maybe-post-format-panel.js +55 -59
  746. package/build-module/components/post-publish-panel/maybe-post-format-panel.js.map +7 -1
  747. package/build-module/components/post-publish-panel/maybe-tags-panel.js +57 -73
  748. package/build-module/components/post-publish-panel/maybe-tags-panel.js.map +7 -1
  749. package/build-module/components/post-publish-panel/maybe-upload-media.js +158 -207
  750. package/build-module/components/post-publish-panel/maybe-upload-media.js.map +7 -1
  751. package/build-module/components/post-publish-panel/media-util.js +42 -69
  752. package/build-module/components/post-publish-panel/media-util.js.map +7 -1
  753. package/build-module/components/post-publish-panel/postpublish.js +109 -120
  754. package/build-module/components/post-publish-panel/postpublish.js.map +7 -1
  755. package/build-module/components/post-publish-panel/prepublish.js +108 -96
  756. package/build-module/components/post-publish-panel/prepublish.js.map +7 -1
  757. package/build-module/components/post-saved-state/index.js +87 -124
  758. package/build-module/components/post-saved-state/index.js.map +7 -1
  759. package/build-module/components/post-schedule/check.js +9 -25
  760. package/build-module/components/post-schedule/check.js.map +7 -1
  761. package/build-module/components/post-schedule/index.js +75 -88
  762. package/build-module/components/post-schedule/index.js.map +7 -1
  763. package/build-module/components/post-schedule/label.js +49 -73
  764. package/build-module/components/post-schedule/label.js.map +7 -1
  765. package/build-module/components/post-schedule/panel.js +63 -65
  766. package/build-module/components/post-schedule/panel.js.map +7 -1
  767. package/build-module/components/post-status/index.js +223 -194
  768. package/build-module/components/post-status/index.js.map +7 -1
  769. package/build-module/components/post-sticky/check.js +10 -29
  770. package/build-module/components/post-sticky/check.js.map +7 -1
  771. package/build-module/components/post-sticky/index.js +22 -36
  772. package/build-module/components/post-sticky/index.js.map +7 -1
  773. package/build-module/components/post-sticky/panel.js +12 -15
  774. package/build-module/components/post-sticky/panel.js.map +7 -1
  775. package/build-module/components/post-switch-to-draft-button/index.js +54 -70
  776. package/build-module/components/post-switch-to-draft-button/index.js.map +7 -1
  777. package/build-module/components/post-sync-status/index.js +17 -40
  778. package/build-module/components/post-sync-status/index.js.map +7 -1
  779. package/build-module/components/post-taxonomies/check.js +17 -28
  780. package/build-module/components/post-taxonomies/check.js.map +7 -1
  781. package/build-module/components/post-taxonomies/flat-term-selector.js +154 -177
  782. package/build-module/components/post-taxonomies/flat-term-selector.js.map +7 -1
  783. package/build-module/components/post-taxonomies/hierarchical-term-selector.js +232 -270
  784. package/build-module/components/post-taxonomies/hierarchical-term-selector.js.map +7 -1
  785. package/build-module/components/post-taxonomies/index.js +34 -49
  786. package/build-module/components/post-taxonomies/index.js.map +7 -1
  787. package/build-module/components/post-taxonomies/most-used-terms.js +54 -50
  788. package/build-module/components/post-taxonomies/most-used-terms.js.map +7 -1
  789. package/build-module/components/post-taxonomies/panel.js +39 -66
  790. package/build-module/components/post-taxonomies/panel.js.map +7 -1
  791. package/build-module/components/post-template/block-theme.js +134 -114
  792. package/build-module/components/post-template/block-theme.js.map +7 -1
  793. package/build-module/components/post-template/classic-theme.js +161 -177
  794. package/build-module/components/post-template/classic-theme.js.map +7 -1
  795. package/build-module/components/post-template/create-new-template-modal.js +126 -104
  796. package/build-module/components/post-template/create-new-template-modal.js.map +7 -1
  797. package/build-module/components/post-template/create-new-template.js +36 -39
  798. package/build-module/components/post-template/create-new-template.js.map +7 -1
  799. package/build-module/components/post-template/hooks.js +95 -80
  800. package/build-module/components/post-template/hooks.js.map +7 -1
  801. package/build-module/components/post-template/panel.js +25 -45
  802. package/build-module/components/post-template/panel.js.map +7 -1
  803. package/build-module/components/post-template/reset-default-template.js +33 -36
  804. package/build-module/components/post-template/reset-default-template.js.map +7 -1
  805. package/build-module/components/post-template/swap-template-button.js +86 -81
  806. package/build-module/components/post-template/swap-template-button.js.map +7 -1
  807. package/build-module/components/post-text-editor/index.js +49 -74
  808. package/build-module/components/post-text-editor/index.js.map +7 -1
  809. package/build-module/components/post-title/constants.js +7 -3
  810. package/build-module/components/post-title/constants.js.map +7 -1
  811. package/build-module/components/post-title/index.js +67 -111
  812. package/build-module/components/post-title/index.js.map +7 -1
  813. package/build-module/components/post-title/post-title-raw.js +43 -71
  814. package/build-module/components/post-title/post-title-raw.js.map +7 -1
  815. package/build-module/components/post-title/use-post-title-focus.js +15 -46
  816. package/build-module/components/post-title/use-post-title-focus.js.map +7 -1
  817. package/build-module/components/post-title/use-post-title.js +13 -33
  818. package/build-module/components/post-title/use-post-title.js.map +7 -1
  819. package/build-module/components/post-transform-panel/hooks.js +44 -58
  820. package/build-module/components/post-transform-panel/hooks.js.map +7 -1
  821. package/build-module/components/post-transform-panel/index.js +53 -69
  822. package/build-module/components/post-transform-panel/index.js.map +7 -1
  823. package/build-module/components/post-trash/check.js +14 -37
  824. package/build-module/components/post-trash/check.js.map +7 -1
  825. package/build-module/components/post-trash/index.js +49 -59
  826. package/build-module/components/post-trash/index.js.map +7 -1
  827. package/build-module/components/post-type-support-check/index.js +16 -42
  828. package/build-module/components/post-type-support-check/index.js.map +7 -1
  829. package/build-module/components/post-url/check.js +9 -24
  830. package/build-module/components/post-url/check.js.map +7 -1
  831. package/build-module/components/post-url/index.js +137 -146
  832. package/build-module/components/post-url/index.js.map +7 -1
  833. package/build-module/components/post-url/label.js +14 -26
  834. package/build-module/components/post-url/label.js.map +7 -1
  835. package/build-module/components/post-url/panel.js +80 -105
  836. package/build-module/components/post-url/panel.js.map +7 -1
  837. package/build-module/components/post-view-link/index.js +27 -39
  838. package/build-module/components/post-view-link/index.js.map +7 -1
  839. package/build-module/components/post-visibility/check.js +10 -29
  840. package/build-module/components/post-visibility/check.js.map +7 -1
  841. package/build-module/components/post-visibility/index.js +66 -78
  842. package/build-module/components/post-visibility/index.js.map +7 -1
  843. package/build-module/components/post-visibility/label.js +15 -27
  844. package/build-module/components/post-visibility/label.js.map +7 -1
  845. package/build-module/components/post-visibility/utils.js +22 -18
  846. package/build-module/components/post-visibility/utils.js.map +7 -1
  847. package/build-module/components/posts-per-page/index.js +85 -91
  848. package/build-module/components/posts-per-page/index.js.map +7 -1
  849. package/build-module/components/preferences-modal/enable-panel.js +30 -38
  850. package/build-module/components/preferences-modal/enable-panel.js.map +7 -1
  851. package/build-module/components/preferences-modal/enable-plugin-document-setting-panel.js +12 -25
  852. package/build-module/components/preferences-modal/enable-plugin-document-setting-panel.js.map +7 -1
  853. package/build-module/components/preferences-modal/enable-publish-sidebar.js +21 -27
  854. package/build-module/components/preferences-modal/enable-publish-sidebar.js.map +7 -1
  855. package/build-module/components/preferences-modal/index.js +365 -225
  856. package/build-module/components/preferences-modal/index.js.map +7 -1
  857. package/build-module/components/preview-dropdown/index.js +140 -141
  858. package/build-module/components/preview-dropdown/index.js.map +7 -1
  859. package/build-module/components/provider/disable-non-page-content-blocks.js +34 -72
  860. package/build-module/components/provider/disable-non-page-content-blocks.js.map +7 -1
  861. package/build-module/components/provider/index.js +257 -317
  862. package/build-module/components/provider/index.js.map +7 -1
  863. package/build-module/components/provider/navigation-block-editing-mode.js +14 -25
  864. package/build-module/components/provider/navigation-block-editing-mode.js.map +7 -1
  865. package/build-module/components/provider/use-auto-switch-editor-sidebars.js +28 -33
  866. package/build-module/components/provider/use-auto-switch-editor-sidebars.js.map +7 -1
  867. package/build-module/components/provider/use-block-editor-settings.js +223 -166
  868. package/build-module/components/provider/use-block-editor-settings.js.map +7 -1
  869. package/build-module/components/provider/use-hide-blocks-from-inserter.js +65 -42
  870. package/build-module/components/provider/use-hide-blocks-from-inserter.js.map +7 -1
  871. package/build-module/components/provider/use-post-content-blocks.js +31 -25
  872. package/build-module/components/provider/use-post-content-blocks.js.map +7 -1
  873. package/build-module/components/provider/with-registry-provider.js +34 -41
  874. package/build-module/components/provider/with-registry-provider.js.map +7 -1
  875. package/build-module/components/resizable-editor/index.js +70 -80
  876. package/build-module/components/resizable-editor/index.js.map +7 -1
  877. package/build-module/components/resizable-editor/resize-handle.js +27 -30
  878. package/build-module/components/resizable-editor/resize-handle.js.map +7 -1
  879. package/build-module/components/save-publish-panels/index.js +56 -62
  880. package/build-module/components/save-publish-panels/index.js.map +7 -1
  881. package/build-module/components/sidebar/constants.js +7 -4
  882. package/build-module/components/sidebar/constants.js.map +7 -1
  883. package/build-module/components/sidebar/header.js +38 -45
  884. package/build-module/components/sidebar/header.js.map +7 -1
  885. package/build-module/components/sidebar/index.js +136 -125
  886. package/build-module/components/sidebar/index.js.map +7 -1
  887. package/build-module/components/sidebar/post-summary.js +86 -87
  888. package/build-module/components/sidebar/post-summary.js.map +7 -1
  889. package/build-module/components/site-discussion/index.js +110 -107
  890. package/build-module/components/site-discussion/index.js.map +7 -1
  891. package/build-module/components/start-page-options/index.js +114 -137
  892. package/build-module/components/start-page-options/index.js.map +7 -1
  893. package/build-module/components/start-template-options/index.js +148 -150
  894. package/build-module/components/start-template-options/index.js.map +7 -1
  895. package/build-module/components/table-of-contents/index.js +50 -63
  896. package/build-module/components/table-of-contents/index.js.map +7 -1
  897. package/build-module/components/table-of-contents/panel.js +73 -88
  898. package/build-module/components/table-of-contents/panel.js.map +7 -1
  899. package/build-module/components/template-content-panel/index.js +57 -54
  900. package/build-module/components/template-content-panel/index.js.map +7 -1
  901. package/build-module/components/template-part-content-panel/index.js +35 -48
  902. package/build-module/components/template-part-content-panel/index.js.map +7 -1
  903. package/build-module/components/template-part-menu-items/convert-to-regular.js +26 -27
  904. package/build-module/components/template-part-menu-items/convert-to-regular.js.map +7 -1
  905. package/build-module/components/template-part-menu-items/convert-to-template-part.js +56 -61
  906. package/build-module/components/template-part-menu-items/convert-to-template-part.js.map +7 -1
  907. package/build-module/components/template-part-menu-items/index.js +38 -47
  908. package/build-module/components/template-part-menu-items/index.js.map +7 -1
  909. package/build-module/components/template-validation-notice/index.js +55 -41
  910. package/build-module/components/template-validation-notice/index.js.map +7 -1
  911. package/build-module/components/text-editor/index.js +38 -54
  912. package/build-module/components/text-editor/index.js.map +7 -1
  913. package/build-module/components/theme-support-check/index.js +13 -38
  914. package/build-module/components/theme-support-check/index.js.map +7 -1
  915. package/build-module/components/time-to-read/index.js +36 -48
  916. package/build-module/components/time-to-read/index.js.map +7 -1
  917. package/build-module/components/unsaved-changes-warning/index.js +16 -34
  918. package/build-module/components/unsaved-changes-warning/index.js.map +7 -1
  919. package/build-module/components/visual-editor/edit-template-blocks-notification.js +44 -63
  920. package/build-module/components/visual-editor/edit-template-blocks-notification.js.map +7 -1
  921. package/build-module/components/visual-editor/index.js +256 -225
  922. package/build-module/components/visual-editor/index.js.map +7 -1
  923. package/build-module/components/visual-editor/use-select-nearest-editable-block.js +58 -64
  924. package/build-module/components/visual-editor/use-select-nearest-editable-block.js.map +7 -1
  925. package/build-module/components/visual-editor/use-zoom-out-mode-exit.js +31 -43
  926. package/build-module/components/visual-editor/use-zoom-out-mode-exit.js.map +7 -1
  927. package/build-module/components/word-count/index.js +16 -32
  928. package/build-module/components/word-count/index.js.map +7 -1
  929. package/build-module/components/zoom-out-toggle/index.js +72 -66
  930. package/build-module/components/zoom-out-toggle/index.js.map +7 -1
  931. package/build-module/dataviews/api.js +26 -77
  932. package/build-module/dataviews/api.js.map +7 -1
  933. package/build-module/dataviews/fields/content-preview/content-preview-view.js +66 -85
  934. package/build-module/dataviews/fields/content-preview/content-preview-view.js.map +7 -1
  935. package/build-module/dataviews/fields/content-preview/index.js +10 -15
  936. package/build-module/dataviews/fields/content-preview/index.js.map +7 -1
  937. package/build-module/dataviews/store/private-actions.js +113 -43
  938. package/build-module/dataviews/store/private-actions.js.map +7 -1
  939. package/build-module/dataviews/store/private-selectors.js +11 -12
  940. package/build-module/dataviews/store/private-selectors.js.map +7 -1
  941. package/build-module/dataviews/store/reducer.js +32 -26
  942. package/build-module/dataviews/store/reducer.js.map +7 -1
  943. package/build-module/hooks/custom-sources-backwards-compatibility.js +70 -83
  944. package/build-module/hooks/custom-sources-backwards-compatibility.js.map +7 -1
  945. package/build-module/hooks/default-autocompleters.js +9 -15
  946. package/build-module/hooks/default-autocompleters.js.map +7 -1
  947. package/build-module/hooks/index.js +7 -9
  948. package/build-module/hooks/index.js.map +7 -1
  949. package/build-module/hooks/media-upload.js +8 -7
  950. package/build-module/hooks/media-upload.js.map +7 -1
  951. package/build-module/hooks/navigation-link-view-button.js +46 -63
  952. package/build-module/hooks/navigation-link-view-button.js.map +7 -1
  953. package/build-module/hooks/pattern-overrides.js +48 -67
  954. package/build-module/hooks/pattern-overrides.js.map +7 -1
  955. package/build-module/hooks/template-part-navigation-edit-button.js +97 -0
  956. package/build-module/hooks/template-part-navigation-edit-button.js.map +7 -0
  957. package/build-module/index.js +13 -15
  958. package/build-module/index.js.map +7 -1
  959. package/build-module/lock-unlock.js +8 -7
  960. package/build-module/lock-unlock.js.map +7 -1
  961. package/build-module/private-apis.js +31 -31
  962. package/build-module/private-apis.js.map +7 -1
  963. package/build-module/store/actions.js +424 -872
  964. package/build-module/store/actions.js.map +7 -1
  965. package/build-module/store/constants.js +36 -27
  966. package/build-module/store/constants.js.map +7 -1
  967. package/build-module/store/defaults.js +8 -28
  968. package/build-module/store/defaults.js.map +7 -1
  969. package/build-module/store/index.js +15 -30
  970. package/build-module/store/index.js.map +7 -1
  971. package/build-module/store/local-autosave.js +18 -24
  972. package/build-module/store/local-autosave.js.map +7 -1
  973. package/build-module/store/private-actions.js +242 -257
  974. package/build-module/store/private-actions.js.map +7 -1
  975. package/build-module/store/private-selectors.js +157 -174
  976. package/build-module/store/private-selectors.js.map +7 -1
  977. package/build-module/store/reducer.js +89 -267
  978. package/build-module/store/reducer.js.map +7 -1
  979. package/build-module/store/selectors.js +712 -1433
  980. package/build-module/store/selectors.js.map +7 -1
  981. package/build-module/store/utils/is-template-revertable.js +6 -15
  982. package/build-module/store/utils/is-template-revertable.js.map +7 -1
  983. package/build-module/store/utils/notice-builder.js +52 -91
  984. package/build-module/store/utils/notice-builder.js.map +7 -1
  985. package/build-module/utils/get-item-title.js +10 -19
  986. package/build-module/utils/get-item-title.js.map +7 -1
  987. package/build-module/utils/get-template-info.js +14 -38
  988. package/build-module/utils/get-template-info.js.map +7 -1
  989. package/build-module/utils/get-template-part-icon.js +14 -16
  990. package/build-module/utils/get-template-part-icon.js.map +7 -1
  991. package/build-module/utils/index.js +9 -8
  992. package/build-module/utils/index.js.map +7 -1
  993. package/build-module/utils/media-sideload/index.js +8 -14
  994. package/build-module/utils/media-sideload/index.js.map +7 -1
  995. package/build-module/utils/media-upload/index.js +26 -56
  996. package/build-module/utils/media-upload/index.js.map +7 -1
  997. package/build-module/utils/pageTypeBadge.js +16 -28
  998. package/build-module/utils/pageTypeBadge.js.map +7 -1
  999. package/build-module/utils/search-templates.js +12 -41
  1000. package/build-module/utils/search-templates.js.map +7 -1
  1001. package/build-module/utils/terms.js +32 -55
  1002. package/build-module/utils/terms.js.map +7 -1
  1003. package/build-module/utils/url.js +11 -28
  1004. package/build-module/utils/url.js.map +7 -1
  1005. package/build-style/style-rtl.css +327 -136
  1006. package/build-style/style.css +327 -136
  1007. package/build-types/bindings/entity.d.ts +16 -0
  1008. package/build-types/bindings/entity.d.ts.map +1 -0
  1009. package/build-types/bindings/post-data.d.ts +16 -0
  1010. package/build-types/bindings/post-meta.d.ts +13 -0
  1011. package/build-types/components/{preferences-modal/block-visibility.d.ts → block-visibility/index.d.ts} +1 -1
  1012. package/build-types/components/block-visibility/index.d.ts.map +1 -0
  1013. package/build-types/components/collab-sidebar/add-comment.d.ts +6 -14
  1014. package/build-types/components/collab-sidebar/add-comment.d.ts.map +1 -1
  1015. package/build-types/components/collab-sidebar/comment-form.d.ts +9 -18
  1016. package/build-types/components/collab-sidebar/comment-form.d.ts.map +1 -1
  1017. package/build-types/components/collab-sidebar/comment-menu-item.d.ts +5 -0
  1018. package/build-types/components/collab-sidebar/comment-menu-item.d.ts.map +1 -0
  1019. package/build-types/components/collab-sidebar/comments.d.ts +10 -1
  1020. package/build-types/components/collab-sidebar/comments.d.ts.map +1 -1
  1021. package/build-types/components/collab-sidebar/hooks.d.ts +33 -0
  1022. package/build-types/components/collab-sidebar/hooks.d.ts.map +1 -1
  1023. package/build-types/components/collab-sidebar/index.d.ts.map +1 -1
  1024. package/build-types/components/collab-sidebar/utils.d.ts +20 -0
  1025. package/build-types/components/collab-sidebar/utils.d.ts.map +1 -1
  1026. package/build-types/components/document-tools/index.d.ts.map +1 -1
  1027. package/build-types/components/header/index.d.ts.map +1 -1
  1028. package/build-types/components/post-excerpt/panel.d.ts.map +1 -1
  1029. package/build-types/components/post-template/block-theme.d.ts.map +1 -1
  1030. package/build-types/components/post-template/hooks.d.ts.map +1 -1
  1031. package/build-types/components/provider/disable-non-page-content-blocks.d.ts.map +1 -1
  1032. package/build-types/components/provider/use-hide-blocks-from-inserter.d.ts.map +1 -1
  1033. package/build-types/components/visual-editor/index.d.ts.map +1 -1
  1034. package/build-types/hooks/template-part-navigation-edit-button.d.ts +2 -0
  1035. package/build-types/hooks/template-part-navigation-edit-button.d.ts.map +1 -0
  1036. package/build-types/store/actions.d.ts.map +1 -1
  1037. package/package.json +59 -39
  1038. package/src/bindings/api.js +2 -2
  1039. package/src/bindings/entity.js +89 -0
  1040. package/src/bindings/post-data.js +23 -0
  1041. package/src/bindings/post-meta.js +19 -0
  1042. package/src/components/autocompleters/style.scss +2 -0
  1043. package/src/components/block-settings-menu/style.scss +2 -0
  1044. package/src/components/{preferences-modal/block-visibility.js → block-visibility/index.js} +37 -5
  1045. package/src/components/block-visibility/style.scss +25 -0
  1046. package/src/components/blog-title/style.scss +2 -0
  1047. package/src/components/collab-sidebar/add-comment.js +18 -17
  1048. package/src/components/collab-sidebar/comment-author-info.js +2 -2
  1049. package/src/components/collab-sidebar/comment-form.js +15 -17
  1050. package/src/components/collab-sidebar/comment-indicator-toolbar.js +2 -2
  1051. package/src/components/collab-sidebar/{comment-button.js → comment-menu-item.js} +4 -4
  1052. package/src/components/collab-sidebar/comments.js +413 -183
  1053. package/src/components/collab-sidebar/hooks.js +343 -22
  1054. package/src/components/collab-sidebar/index.js +94 -190
  1055. package/src/components/collab-sidebar/style.scss +44 -26
  1056. package/src/components/collab-sidebar/utils.js +55 -0
  1057. package/src/components/collapsible-block-toolbar/style.scss +5 -1
  1058. package/src/components/commands/index.js +2 -2
  1059. package/src/components/document-bar/style.scss +5 -0
  1060. package/src/components/document-outline/style.scss +3 -0
  1061. package/src/components/document-tools/index.js +1 -20
  1062. package/src/components/document-tools/style.scss +4 -0
  1063. package/src/components/editor-help/style.scss +3 -0
  1064. package/src/components/editor-interface/style.scss +2 -0
  1065. package/src/components/editor-notices/style.scss +3 -0
  1066. package/src/components/entities-saved-states/style.scss +3 -0
  1067. package/src/components/error-boundary/style.scss +3 -0
  1068. package/src/components/header/index.js +3 -8
  1069. package/src/components/header/style.scss +6 -0
  1070. package/src/components/inserter-sidebar/style.scss +2 -0
  1071. package/src/components/keyboard-shortcut-help-modal/style.scss +2 -0
  1072. package/src/components/list-view-sidebar/style.scss +4 -1
  1073. package/src/components/page-attributes/style.scss +2 -0
  1074. package/src/components/post-actions/style.scss +2 -0
  1075. package/src/components/post-author/style.scss +2 -0
  1076. package/src/components/post-card-panel/style.scss +4 -0
  1077. package/src/components/post-content-information/style.scss +2 -0
  1078. package/src/components/post-discussion/style.scss +2 -0
  1079. package/src/components/post-excerpt/panel.js +12 -6
  1080. package/src/components/post-excerpt/style.scss +2 -0
  1081. package/src/components/post-featured-image/style.scss +7 -0
  1082. package/src/components/post-format/style.scss +2 -0
  1083. package/src/components/post-last-edited-panel/style.scss +2 -0
  1084. package/src/components/post-last-revision/style.scss +3 -0
  1085. package/src/components/post-locked-modal/style.scss +2 -0
  1086. package/src/components/post-panel-row/style.scss +2 -0
  1087. package/src/components/post-panel-section/style.scss +2 -0
  1088. package/src/components/post-publish-button/post-publish-button-or-toggle.js +1 -1
  1089. package/src/components/post-publish-panel/style.scss +5 -0
  1090. package/src/components/post-saved-state/style.scss +4 -0
  1091. package/src/components/post-schedule/style.scss +2 -0
  1092. package/src/components/post-status/style.scss +3 -0
  1093. package/src/components/post-sticky/style.scss +3 -0
  1094. package/src/components/post-sync-status/style.scss +2 -0
  1095. package/src/components/post-taxonomies/style.scss +2 -0
  1096. package/src/components/post-template/block-theme.js +45 -3
  1097. package/src/components/post-template/hooks.js +48 -21
  1098. package/src/components/post-template/style.scss +5 -0
  1099. package/src/components/post-text-editor/style.scss +4 -0
  1100. package/src/components/post-title/style.scss +2 -0
  1101. package/src/components/post-url/style.scss +2 -0
  1102. package/src/components/posts-per-page/style.scss +2 -0
  1103. package/src/components/preferences-modal/index.js +1 -1
  1104. package/src/components/provider/disable-non-page-content-blocks.js +7 -13
  1105. package/src/components/provider/use-hide-blocks-from-inserter.js +37 -6
  1106. package/src/components/resizable-editor/style.scss +4 -0
  1107. package/src/components/save-publish-panels/style.scss +4 -0
  1108. package/src/components/sidebar/style.scss +3 -0
  1109. package/src/components/site-discussion/style.scss +2 -1
  1110. package/src/components/start-page-options/style.scss +5 -0
  1111. package/src/components/start-template-options/style.scss +5 -0
  1112. package/src/components/table-of-contents/style.scss +5 -0
  1113. package/src/components/text-editor/style.scss +6 -0
  1114. package/src/components/visual-editor/index.js +11 -21
  1115. package/src/components/visual-editor/style.scss +3 -1
  1116. package/src/dataviews/fields/content-preview/style.scss +2 -0
  1117. package/src/hooks/index.js +1 -0
  1118. package/src/hooks/template-part-navigation-edit-button.js +145 -0
  1119. package/src/store/actions.js +6 -1
  1120. package/src/style.scss +57 -56
  1121. package/tsconfig.tsbuildinfo +1 -1
  1122. package/build/bindings/term-data.js +0 -171
  1123. package/build/bindings/term-data.js.map +0 -1
  1124. package/build/components/block-settings-menu/content-only-settings-menu.native.js +0 -11
  1125. package/build/components/block-settings-menu/content-only-settings-menu.native.js.map +0 -1
  1126. package/build/components/collab-sidebar/comment-button.js +0 -42
  1127. package/build/components/collab-sidebar/comment-button.js.map +0 -1
  1128. package/build/components/commands/index.native.js +0 -9
  1129. package/build/components/commands/index.native.js.map +0 -1
  1130. package/build/components/deprecated.native.js +0 -121
  1131. package/build/components/deprecated.native.js.map +0 -1
  1132. package/build/components/editor-help/add-blocks.native.js +0 -41
  1133. package/build/components/editor-help/add-blocks.native.js.map +0 -1
  1134. package/build/components/editor-help/customize-blocks.native.js +0 -41
  1135. package/build/components/editor-help/customize-blocks.native.js.map +0 -1
  1136. package/build/components/editor-help/help-detail-navigation-screen.native.js +0 -69
  1137. package/build/components/editor-help/help-detail-navigation-screen.native.js.map +0 -1
  1138. package/build/components/editor-help/help-get-support-button.native.js +0 -41
  1139. package/build/components/editor-help/help-get-support-button.native.js.map +0 -1
  1140. package/build/components/editor-help/help-section-title.native.js +0 -37
  1141. package/build/components/editor-help/help-section-title.native.js.map +0 -1
  1142. package/build/components/editor-help/help-topic-row.native.js +0 -42
  1143. package/build/components/editor-help/help-topic-row.native.js.map +0 -1
  1144. package/build/components/editor-help/icon-move-blocks.native.js +0 -19
  1145. package/build/components/editor-help/icon-move-blocks.native.js.map +0 -1
  1146. package/build/components/editor-help/index.native.js +0 -173
  1147. package/build/components/editor-help/index.native.js.map +0 -1
  1148. package/build/components/editor-help/intro-to-blocks.native.js +0 -70
  1149. package/build/components/editor-help/intro-to-blocks.native.js.map +0 -1
  1150. package/build/components/editor-help/move-blocks.native.js +0 -52
  1151. package/build/components/editor-help/move-blocks.native.js.map +0 -1
  1152. package/build/components/editor-help/remove-blocks.native.js +0 -39
  1153. package/build/components/editor-help/remove-blocks.native.js.map +0 -1
  1154. package/build/components/editor-help/view-sections.native.js +0 -80
  1155. package/build/components/editor-help/view-sections.native.js.map +0 -1
  1156. package/build/components/error-boundary/index.native.js +0 -143
  1157. package/build/components/error-boundary/index.native.js.map +0 -1
  1158. package/build/components/index.native.js +0 -85
  1159. package/build/components/index.native.js.map +0 -1
  1160. package/build/components/offline-status/index.native.js +0 -83
  1161. package/build/components/offline-status/index.native.js.map +0 -1
  1162. package/build/components/post-title/index.native.js +0 -251
  1163. package/build/components/post-title/index.native.js.map +0 -1
  1164. package/build/components/preferences-modal/block-visibility.js +0 -88
  1165. package/build/components/preferences-modal/block-visibility.js.map +0 -1
  1166. package/build/components/provider/index.native.js +0 -426
  1167. package/build/components/provider/index.native.js.map +0 -1
  1168. package/build/components/provider/use-block-editor-settings.native.js +0 -46
  1169. package/build/components/provider/use-block-editor-settings.native.js.map +0 -1
  1170. package/build/components/template-part-menu-items/index.native.js +0 -10
  1171. package/build/components/template-part-menu-items/index.native.js.map +0 -1
  1172. package/build/hooks/index.native.js +0 -2
  1173. package/build/hooks/index.native.js.map +0 -1
  1174. package/build/index.native.js +0 -56
  1175. package/build/index.native.js.map +0 -1
  1176. package/build/private-apis.native.js +0 -44
  1177. package/build/private-apis.native.js.map +0 -1
  1178. package/build/store/actions.native.js +0 -51
  1179. package/build/store/actions.native.js.map +0 -1
  1180. package/build/store/reducer.native.js +0 -105
  1181. package/build/store/reducer.native.js.map +0 -1
  1182. package/build/store/selectors.native.js +0 -70
  1183. package/build/store/selectors.native.js.map +0 -1
  1184. package/build/utils/index.native.js +0 -14
  1185. package/build/utils/index.native.js.map +0 -1
  1186. package/build/utils/media-sideload/index.native.js +0 -8
  1187. package/build/utils/media-sideload/index.native.js.map +0 -1
  1188. package/build/utils/media-upload/index.native.js +0 -8
  1189. package/build/utils/media-upload/index.native.js.map +0 -1
  1190. package/build-module/bindings/term-data.js +0 -165
  1191. package/build-module/bindings/term-data.js.map +0 -1
  1192. package/build-module/components/block-settings-menu/content-only-settings-menu.native.js +0 -5
  1193. package/build-module/components/block-settings-menu/content-only-settings-menu.native.js.map +0 -1
  1194. package/build-module/components/collab-sidebar/comment-button.js +0 -35
  1195. package/build-module/components/collab-sidebar/comment-button.js.map +0 -1
  1196. package/build-module/components/commands/index.native.js +0 -3
  1197. package/build-module/components/commands/index.native.js.map +0 -1
  1198. package/build-module/components/deprecated.native.js +0 -7
  1199. package/build-module/components/deprecated.native.js.map +0 -1
  1200. package/build-module/components/editor-help/add-blocks.native.js +0 -33
  1201. package/build-module/components/editor-help/add-blocks.native.js.map +0 -1
  1202. package/build-module/components/editor-help/customize-blocks.native.js +0 -33
  1203. package/build-module/components/editor-help/customize-blocks.native.js.map +0 -1
  1204. package/build-module/components/editor-help/help-detail-navigation-screen.native.js +0 -61
  1205. package/build-module/components/editor-help/help-detail-navigation-screen.native.js.map +0 -1
  1206. package/build-module/components/editor-help/help-get-support-button.native.js +0 -33
  1207. package/build-module/components/editor-help/help-get-support-button.native.js.map +0 -1
  1208. package/build-module/components/editor-help/help-section-title.native.js +0 -29
  1209. package/build-module/components/editor-help/help-section-title.native.js.map +0 -1
  1210. package/build-module/components/editor-help/help-topic-row.native.js +0 -35
  1211. package/build-module/components/editor-help/help-topic-row.native.js.map +0 -1
  1212. package/build-module/components/editor-help/icon-move-blocks.native.js +0 -13
  1213. package/build-module/components/editor-help/icon-move-blocks.native.js.map +0 -1
  1214. package/build-module/components/editor-help/index.native.js +0 -165
  1215. package/build-module/components/editor-help/index.native.js.map +0 -1
  1216. package/build-module/components/editor-help/intro-to-blocks.native.js +0 -62
  1217. package/build-module/components/editor-help/intro-to-blocks.native.js.map +0 -1
  1218. package/build-module/components/editor-help/move-blocks.native.js +0 -44
  1219. package/build-module/components/editor-help/move-blocks.native.js.map +0 -1
  1220. package/build-module/components/editor-help/remove-blocks.native.js +0 -31
  1221. package/build-module/components/editor-help/remove-blocks.native.js.map +0 -1
  1222. package/build-module/components/editor-help/view-sections.native.js +0 -69
  1223. package/build-module/components/editor-help/view-sections.native.js.map +0 -1
  1224. package/build-module/components/error-boundary/index.native.js +0 -135
  1225. package/build-module/components/error-boundary/index.native.js.map +0 -1
  1226. package/build-module/components/index.native.js +0 -15
  1227. package/build-module/components/index.native.js.map +0 -1
  1228. package/build-module/components/offline-status/index.native.js +0 -77
  1229. package/build-module/components/offline-status/index.native.js.map +0 -1
  1230. package/build-module/components/post-title/index.native.js +0 -243
  1231. package/build-module/components/post-title/index.native.js.map +0 -1
  1232. package/build-module/components/preferences-modal/block-visibility.js +0 -81
  1233. package/build-module/components/preferences-modal/block-visibility.js.map +0 -1
  1234. package/build-module/components/provider/index.native.js +0 -416
  1235. package/build-module/components/provider/index.native.js.map +0 -1
  1236. package/build-module/components/provider/use-block-editor-settings.native.js +0 -38
  1237. package/build-module/components/provider/use-block-editor-settings.native.js.map +0 -1
  1238. package/build-module/components/template-part-menu-items/index.native.js +0 -4
  1239. package/build-module/components/template-part-menu-items/index.native.js.map +0 -1
  1240. package/build-module/hooks/index.native.js +0 -2
  1241. package/build-module/hooks/index.native.js.map +0 -1
  1242. package/build-module/index.native.js +0 -16
  1243. package/build-module/index.native.js.map +0 -1
  1244. package/build-module/private-apis.native.js +0 -34
  1245. package/build-module/private-apis.native.js.map +0 -1
  1246. package/build-module/store/actions.native.js +0 -27
  1247. package/build-module/store/actions.native.js.map +0 -1
  1248. package/build-module/store/reducer.native.js +0 -81
  1249. package/build-module/store/reducer.native.js.map +0 -1
  1250. package/build-module/store/selectors.native.js +0 -49
  1251. package/build-module/store/selectors.native.js.map +0 -1
  1252. package/build-module/utils/index.native.js +0 -6
  1253. package/build-module/utils/index.native.js.map +0 -1
  1254. package/build-module/utils/media-sideload/index.native.js +0 -2
  1255. package/build-module/utils/media-sideload/index.native.js.map +0 -1
  1256. package/build-module/utils/media-upload/index.native.js +0 -2
  1257. package/build-module/utils/media-upload/index.native.js.map +0 -1
  1258. package/build-types/bindings/term-data.d.ts +0 -25
  1259. package/build-types/bindings/term-data.d.ts.map +0 -1
  1260. package/build-types/components/collab-sidebar/comment-button.d.ts +0 -5
  1261. package/build-types/components/collab-sidebar/comment-button.d.ts.map +0 -1
  1262. package/build-types/components/preferences-modal/block-visibility.d.ts.map +0 -1
  1263. package/src/bindings/term-data.js +0 -159
@@ -1,98 +1,69 @@
1
- /**
2
- * WordPress dependencies
3
- */
4
- import { Flex, FlexItem, Modal, ToggleControl } from '@wordpress/components';
5
- import { __ } from '@wordpress/i18n';
6
- import { useState, useMemo, useEffect } from '@wordpress/element';
7
- import { store as blockEditorStore, __experimentalBlockPatternsList as BlockPatternsList } from '@wordpress/block-editor';
8
- import { useSelect, useDispatch } from '@wordpress/data';
9
- import { store as coreStore } from '@wordpress/core-data';
10
- import { __unstableSerializeAndClean } from '@wordpress/blocks';
11
- import { store as preferencesStore } from '@wordpress/preferences';
12
- import { store as interfaceStore } from '@wordpress/interface';
13
-
14
- /**
15
- * Internal dependencies
16
- */
17
- import { TEMPLATE_POST_TYPE } from '../../store/constants';
18
- import { store as editorStore } from '../../store';
19
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
20
- export function useStartPatterns() {
21
- // A pattern is a start pattern if it includes 'core/post-content' in its blockTypes,
22
- // and it has no postTypes declared and the current post type is page or if
23
- // the current post type is part of the postTypes declared.
24
- const {
25
- blockPatternsWithPostContentBlockType,
26
- postType
27
- } = useSelect(select => {
28
- const {
29
- getPatternsByBlockTypes,
30
- getBlocksByName
31
- } = select(blockEditorStore);
32
- const {
33
- getCurrentPostType,
34
- getRenderingMode
35
- } = select(editorStore);
36
- const rootClientId = getRenderingMode() === 'post-only' ? '' : getBlocksByName('core/post-content')?.[0];
37
- return {
38
- blockPatternsWithPostContentBlockType: getPatternsByBlockTypes('core/post-content', rootClientId),
39
- postType: getCurrentPostType()
40
- };
41
- }, []);
1
+ import { jsx, jsxs } from "react/jsx-runtime";
2
+ import { Flex, FlexItem, Modal, ToggleControl } from "@wordpress/components";
3
+ import { __ } from "@wordpress/i18n";
4
+ import { useState, useMemo, useEffect } from "@wordpress/element";
5
+ import {
6
+ store as blockEditorStore,
7
+ __experimentalBlockPatternsList as BlockPatternsList
8
+ } from "@wordpress/block-editor";
9
+ import { useSelect, useDispatch } from "@wordpress/data";
10
+ import { store as coreStore } from "@wordpress/core-data";
11
+ import { __unstableSerializeAndClean } from "@wordpress/blocks";
12
+ import { store as preferencesStore } from "@wordpress/preferences";
13
+ import { store as interfaceStore } from "@wordpress/interface";
14
+ import { TEMPLATE_POST_TYPE } from "../../store/constants";
15
+ import { store as editorStore } from "../../store";
16
+ function useStartPatterns() {
17
+ const { blockPatternsWithPostContentBlockType, postType } = useSelect(
18
+ (select) => {
19
+ const { getPatternsByBlockTypes, getBlocksByName } = select(blockEditorStore);
20
+ const { getCurrentPostType, getRenderingMode } = select(editorStore);
21
+ const rootClientId = getRenderingMode() === "post-only" ? "" : getBlocksByName("core/post-content")?.[0];
22
+ return {
23
+ blockPatternsWithPostContentBlockType: getPatternsByBlockTypes(
24
+ "core/post-content",
25
+ rootClientId
26
+ ),
27
+ postType: getCurrentPostType()
28
+ };
29
+ },
30
+ []
31
+ );
42
32
  return useMemo(() => {
43
33
  if (!blockPatternsWithPostContentBlockType?.length) {
44
34
  return [];
45
35
  }
46
-
47
- /*
48
- * Filter patterns without postTypes declared if the current postType is page
49
- * or patterns that declare the current postType in its post type array.
50
- */
51
- return blockPatternsWithPostContentBlockType.filter(pattern => {
52
- return postType === 'page' && !pattern.postTypes || Array.isArray(pattern.postTypes) && pattern.postTypes.includes(postType);
36
+ return blockPatternsWithPostContentBlockType.filter((pattern) => {
37
+ return postType === "page" && !pattern.postTypes || Array.isArray(pattern.postTypes) && pattern.postTypes.includes(postType);
53
38
  });
54
39
  }, [postType, blockPatternsWithPostContentBlockType]);
55
40
  }
56
- function PatternSelection({
57
- blockPatterns,
58
- onChoosePattern
59
- }) {
60
- const {
61
- editEntityRecord
62
- } = useDispatch(coreStore);
63
- const {
64
- postType,
65
- postId
66
- } = useSelect(select => {
67
- const {
68
- getCurrentPostType,
69
- getCurrentPostId
70
- } = select(editorStore);
41
+ function PatternSelection({ blockPatterns, onChoosePattern }) {
42
+ const { editEntityRecord } = useDispatch(coreStore);
43
+ const { postType, postId } = useSelect((select) => {
44
+ const { getCurrentPostType, getCurrentPostId } = select(editorStore);
71
45
  return {
72
46
  postType: getCurrentPostType(),
73
47
  postId: getCurrentPostId()
74
48
  };
75
49
  }, []);
76
- return /*#__PURE__*/_jsx(BlockPatternsList, {
77
- blockPatterns: blockPatterns,
78
- onClickPattern: (_pattern, blocks) => {
79
- editEntityRecord('postType', postType, postId, {
80
- blocks,
81
- content: ({
82
- blocks: blocksForSerialization = []
83
- }) => __unstableSerializeAndClean(blocksForSerialization)
84
- });
85
- onChoosePattern();
50
+ return /* @__PURE__ */ jsx(
51
+ BlockPatternsList,
52
+ {
53
+ blockPatterns,
54
+ onClickPattern: (_pattern, blocks) => {
55
+ editEntityRecord("postType", postType, postId, {
56
+ blocks,
57
+ content: ({ blocks: blocksForSerialization = [] }) => __unstableSerializeAndClean(blocksForSerialization)
58
+ });
59
+ onChoosePattern();
60
+ }
86
61
  }
87
- });
62
+ );
88
63
  }
89
- function StartPageOptionsModal({
90
- onClose
91
- }) {
64
+ function StartPageOptionsModal({ onClose }) {
92
65
  const [showStartPatterns, setShowStartPatterns] = useState(true);
93
- const {
94
- set: setPreference
95
- } = useDispatch(preferencesStore);
66
+ const { set: setPreference } = useDispatch(preferencesStore);
96
67
  const startPatterns = useStartPatterns();
97
68
  const hasStartPattern = startPatterns.length > 0;
98
69
  if (!hasStartPattern) {
@@ -100,79 +71,85 @@ function StartPageOptionsModal({
100
71
  }
101
72
  function handleClose() {
102
73
  onClose();
103
- setPreference('core', 'enableChoosePatternModal', showStartPatterns);
74
+ setPreference("core", "enableChoosePatternModal", showStartPatterns);
104
75
  }
105
- return /*#__PURE__*/_jsxs(Modal, {
106
- className: "editor-start-page-options__modal",
107
- title: __('Choose a pattern'),
108
- isFullScreen: true,
109
- onRequestClose: handleClose,
110
- children: [/*#__PURE__*/_jsx("div", {
111
- className: "editor-start-page-options__modal-content",
112
- children: /*#__PURE__*/_jsx(PatternSelection, {
113
- blockPatterns: startPatterns,
114
- onChoosePattern: handleClose
115
- })
116
- }), /*#__PURE__*/_jsx(Flex, {
117
- className: "editor-start-page-options__modal__actions",
118
- justify: "flex-end",
119
- expanded: false,
120
- children: /*#__PURE__*/_jsx(FlexItem, {
121
- children: /*#__PURE__*/_jsx(ToggleControl, {
122
- __nextHasNoMarginBottom: true,
123
- checked: showStartPatterns,
124
- label: __('Show starter patterns'),
125
- help: __('Shows starter patterns when creating a new page.'),
126
- onChange: newValue => {
127
- setShowStartPatterns(newValue);
76
+ return /* @__PURE__ */ jsxs(
77
+ Modal,
78
+ {
79
+ className: "editor-start-page-options__modal",
80
+ title: __("Choose a pattern"),
81
+ isFullScreen: true,
82
+ onRequestClose: handleClose,
83
+ children: [
84
+ /* @__PURE__ */ jsx("div", { className: "editor-start-page-options__modal-content", children: /* @__PURE__ */ jsx(
85
+ PatternSelection,
86
+ {
87
+ blockPatterns: startPatterns,
88
+ onChoosePattern: handleClose
128
89
  }
129
- })
130
- })
131
- })]
132
- });
90
+ ) }),
91
+ /* @__PURE__ */ jsx(
92
+ Flex,
93
+ {
94
+ className: "editor-start-page-options__modal__actions",
95
+ justify: "flex-end",
96
+ expanded: false,
97
+ children: /* @__PURE__ */ jsx(FlexItem, { children: /* @__PURE__ */ jsx(
98
+ ToggleControl,
99
+ {
100
+ __nextHasNoMarginBottom: true,
101
+ checked: showStartPatterns,
102
+ label: __("Show starter patterns"),
103
+ help: __(
104
+ "Shows starter patterns when creating a new page."
105
+ ),
106
+ onChange: (newValue) => {
107
+ setShowStartPatterns(newValue);
108
+ }
109
+ }
110
+ ) })
111
+ }
112
+ )
113
+ ]
114
+ }
115
+ );
133
116
  }
134
- export default function StartPageOptions() {
117
+ function StartPageOptions() {
135
118
  const [isOpen, setIsOpen] = useState(false);
136
- const {
137
- isEditedPostDirty,
138
- isEditedPostEmpty
139
- } = useSelect(editorStore);
140
- const {
141
- isModalActive
142
- } = useSelect(interfaceStore);
143
- const {
144
- enabled,
145
- postId
146
- } = useSelect(select => {
147
- const {
148
- getCurrentPostId,
149
- getCurrentPostType
150
- } = select(editorStore);
151
- const choosePatternModalEnabled = select(preferencesStore).get('core', 'enableChoosePatternModal');
119
+ const { isEditedPostDirty, isEditedPostEmpty } = useSelect(editorStore);
120
+ const { isModalActive } = useSelect(interfaceStore);
121
+ const { enabled, postId } = useSelect((select) => {
122
+ const { getCurrentPostId, getCurrentPostType } = select(editorStore);
123
+ const choosePatternModalEnabled = select(preferencesStore).get(
124
+ "core",
125
+ "enableChoosePatternModal"
126
+ );
152
127
  return {
153
128
  postId: getCurrentPostId(),
154
129
  enabled: choosePatternModalEnabled && TEMPLATE_POST_TYPE !== getCurrentPostType()
155
130
  };
156
131
  }, []);
157
-
158
- // Note: The `postId` ensures the effect re-runs when pages are switched without remounting the component.
159
- // Examples: changing pages in the List View, creating a new page via Command Palette.
160
132
  useEffect(() => {
161
133
  const isFreshPage = !isEditedPostDirty() && isEditedPostEmpty();
162
- // Prevents immediately opening when features is enabled via preferences modal.
163
- const isPreferencesModalActive = isModalActive('editor/preferences');
134
+ const isPreferencesModalActive = isModalActive("editor/preferences");
164
135
  if (!enabled || !isFreshPage || isPreferencesModalActive) {
165
136
  return;
166
137
  }
167
-
168
- // Open the modal after the initial render for a new page.
169
138
  setIsOpen(true);
170
- }, [enabled, postId, isEditedPostDirty, isEditedPostEmpty, isModalActive]);
139
+ }, [
140
+ enabled,
141
+ postId,
142
+ isEditedPostDirty,
143
+ isEditedPostEmpty,
144
+ isModalActive
145
+ ]);
171
146
  if (!isOpen) {
172
147
  return null;
173
148
  }
174
- return /*#__PURE__*/_jsx(StartPageOptionsModal, {
175
- onClose: () => setIsOpen(false)
176
- });
149
+ return /* @__PURE__ */ jsx(StartPageOptionsModal, { onClose: () => setIsOpen(false) });
177
150
  }
178
- //# sourceMappingURL=index.js.map
151
+ export {
152
+ StartPageOptions as default,
153
+ useStartPatterns
154
+ };
155
+ //# sourceMappingURL=index.js.map
@@ -1 +1,7 @@
1
- {"version":3,"names":["Flex","FlexItem","Modal","ToggleControl","__","useState","useMemo","useEffect","store","blockEditorStore","__experimentalBlockPatternsList","BlockPatternsList","useSelect","useDispatch","coreStore","__unstableSerializeAndClean","preferencesStore","interfaceStore","TEMPLATE_POST_TYPE","editorStore","jsx","_jsx","jsxs","_jsxs","useStartPatterns","blockPatternsWithPostContentBlockType","postType","select","getPatternsByBlockTypes","getBlocksByName","getCurrentPostType","getRenderingMode","rootClientId","length","filter","pattern","postTypes","Array","isArray","includes","PatternSelection","blockPatterns","onChoosePattern","editEntityRecord","postId","getCurrentPostId","onClickPattern","_pattern","blocks","content","blocksForSerialization","StartPageOptionsModal","onClose","showStartPatterns","setShowStartPatterns","set","setPreference","startPatterns","hasStartPattern","handleClose","className","title","isFullScreen","onRequestClose","children","justify","expanded","__nextHasNoMarginBottom","checked","label","help","onChange","newValue","StartPageOptions","isOpen","setIsOpen","isEditedPostDirty","isEditedPostEmpty","isModalActive","enabled","choosePatternModalEnabled","get","isFreshPage","isPreferencesModalActive"],"sources":["@wordpress/editor/src/components/start-page-options/index.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { Flex, FlexItem, Modal, ToggleControl } from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { useState, useMemo, useEffect } from '@wordpress/element';\nimport {\n\tstore as blockEditorStore,\n\t__experimentalBlockPatternsList as BlockPatternsList,\n} from '@wordpress/block-editor';\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport { store as coreStore } from '@wordpress/core-data';\nimport { __unstableSerializeAndClean } from '@wordpress/blocks';\nimport { store as preferencesStore } from '@wordpress/preferences';\nimport { store as interfaceStore } from '@wordpress/interface';\n\n/**\n * Internal dependencies\n */\nimport { TEMPLATE_POST_TYPE } from '../../store/constants';\nimport { store as editorStore } from '../../store';\n\nexport function useStartPatterns() {\n\t// A pattern is a start pattern if it includes 'core/post-content' in its blockTypes,\n\t// and it has no postTypes declared and the current post type is page or if\n\t// the current post type is part of the postTypes declared.\n\tconst { blockPatternsWithPostContentBlockType, postType } = useSelect(\n\t\t( select ) => {\n\t\t\tconst { getPatternsByBlockTypes, getBlocksByName } =\n\t\t\t\tselect( blockEditorStore );\n\t\t\tconst { getCurrentPostType, getRenderingMode } =\n\t\t\t\tselect( editorStore );\n\t\t\tconst rootClientId =\n\t\t\t\tgetRenderingMode() === 'post-only'\n\t\t\t\t\t? ''\n\t\t\t\t\t: getBlocksByName( 'core/post-content' )?.[ 0 ];\n\t\t\treturn {\n\t\t\t\tblockPatternsWithPostContentBlockType: getPatternsByBlockTypes(\n\t\t\t\t\t'core/post-content',\n\t\t\t\t\trootClientId\n\t\t\t\t),\n\t\t\t\tpostType: getCurrentPostType(),\n\t\t\t};\n\t\t},\n\t\t[]\n\t);\n\n\treturn useMemo( () => {\n\t\tif ( ! blockPatternsWithPostContentBlockType?.length ) {\n\t\t\treturn [];\n\t\t}\n\n\t\t/*\n\t\t * Filter patterns without postTypes declared if the current postType is page\n\t\t * or patterns that declare the current postType in its post type array.\n\t\t */\n\t\treturn blockPatternsWithPostContentBlockType.filter( ( pattern ) => {\n\t\t\treturn (\n\t\t\t\t( postType === 'page' && ! pattern.postTypes ) ||\n\t\t\t\t( Array.isArray( pattern.postTypes ) &&\n\t\t\t\t\tpattern.postTypes.includes( postType ) )\n\t\t\t);\n\t\t} );\n\t}, [ postType, blockPatternsWithPostContentBlockType ] );\n}\n\nfunction PatternSelection( { blockPatterns, onChoosePattern } ) {\n\tconst { editEntityRecord } = useDispatch( coreStore );\n\tconst { postType, postId } = useSelect( ( select ) => {\n\t\tconst { getCurrentPostType, getCurrentPostId } = select( editorStore );\n\n\t\treturn {\n\t\t\tpostType: getCurrentPostType(),\n\t\t\tpostId: getCurrentPostId(),\n\t\t};\n\t}, [] );\n\treturn (\n\t\t<BlockPatternsList\n\t\t\tblockPatterns={ blockPatterns }\n\t\t\tonClickPattern={ ( _pattern, blocks ) => {\n\t\t\t\teditEntityRecord( 'postType', postType, postId, {\n\t\t\t\t\tblocks,\n\t\t\t\t\tcontent: ( { blocks: blocksForSerialization = [] } ) =>\n\t\t\t\t\t\t__unstableSerializeAndClean( blocksForSerialization ),\n\t\t\t\t} );\n\t\t\t\tonChoosePattern();\n\t\t\t} }\n\t\t/>\n\t);\n}\n\nfunction StartPageOptionsModal( { onClose } ) {\n\tconst [ showStartPatterns, setShowStartPatterns ] = useState( true );\n\tconst { set: setPreference } = useDispatch( preferencesStore );\n\tconst startPatterns = useStartPatterns();\n\tconst hasStartPattern = startPatterns.length > 0;\n\n\tif ( ! hasStartPattern ) {\n\t\treturn null;\n\t}\n\n\tfunction handleClose() {\n\t\tonClose();\n\t\tsetPreference( 'core', 'enableChoosePatternModal', showStartPatterns );\n\t}\n\n\treturn (\n\t\t<Modal\n\t\t\tclassName=\"editor-start-page-options__modal\"\n\t\t\ttitle={ __( 'Choose a pattern' ) }\n\t\t\tisFullScreen\n\t\t\tonRequestClose={ handleClose }\n\t\t>\n\t\t\t<div className=\"editor-start-page-options__modal-content\">\n\t\t\t\t<PatternSelection\n\t\t\t\t\tblockPatterns={ startPatterns }\n\t\t\t\t\tonChoosePattern={ handleClose }\n\t\t\t\t/>\n\t\t\t</div>\n\t\t\t<Flex\n\t\t\t\tclassName=\"editor-start-page-options__modal__actions\"\n\t\t\t\tjustify=\"flex-end\"\n\t\t\t\texpanded={ false }\n\t\t\t>\n\t\t\t\t<FlexItem>\n\t\t\t\t\t<ToggleControl\n\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t\tchecked={ showStartPatterns }\n\t\t\t\t\t\tlabel={ __( 'Show starter patterns' ) }\n\t\t\t\t\t\thelp={ __(\n\t\t\t\t\t\t\t'Shows starter patterns when creating a new page.'\n\t\t\t\t\t\t) }\n\t\t\t\t\t\tonChange={ ( newValue ) => {\n\t\t\t\t\t\t\tsetShowStartPatterns( newValue );\n\t\t\t\t\t\t} }\n\t\t\t\t\t/>\n\t\t\t\t</FlexItem>\n\t\t\t</Flex>\n\t\t</Modal>\n\t);\n}\n\nexport default function StartPageOptions() {\n\tconst [ isOpen, setIsOpen ] = useState( false );\n\tconst { isEditedPostDirty, isEditedPostEmpty } = useSelect( editorStore );\n\tconst { isModalActive } = useSelect( interfaceStore );\n\tconst { enabled, postId } = useSelect( ( select ) => {\n\t\tconst { getCurrentPostId, getCurrentPostType } = select( editorStore );\n\t\tconst choosePatternModalEnabled = select( preferencesStore ).get(\n\t\t\t'core',\n\t\t\t'enableChoosePatternModal'\n\t\t);\n\t\treturn {\n\t\t\tpostId: getCurrentPostId(),\n\t\t\tenabled:\n\t\t\t\tchoosePatternModalEnabled &&\n\t\t\t\tTEMPLATE_POST_TYPE !== getCurrentPostType(),\n\t\t};\n\t}, [] );\n\n\t// Note: The `postId` ensures the effect re-runs when pages are switched without remounting the component.\n\t// Examples: changing pages in the List View, creating a new page via Command Palette.\n\tuseEffect( () => {\n\t\tconst isFreshPage = ! isEditedPostDirty() && isEditedPostEmpty();\n\t\t// Prevents immediately opening when features is enabled via preferences modal.\n\t\tconst isPreferencesModalActive = isModalActive( 'editor/preferences' );\n\t\tif ( ! enabled || ! isFreshPage || isPreferencesModalActive ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Open the modal after the initial render for a new page.\n\t\tsetIsOpen( true );\n\t}, [\n\t\tenabled,\n\t\tpostId,\n\t\tisEditedPostDirty,\n\t\tisEditedPostEmpty,\n\t\tisModalActive,\n\t] );\n\n\tif ( ! isOpen ) {\n\t\treturn null;\n\t}\n\n\treturn <StartPageOptionsModal onClose={ () => setIsOpen( false ) } />;\n}\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,IAAI,EAAEC,QAAQ,EAAEC,KAAK,EAAEC,aAAa,QAAQ,uBAAuB;AAC5E,SAASC,EAAE,QAAQ,iBAAiB;AACpC,SAASC,QAAQ,E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3,
3
+ "sources": ["../../../src/components/start-page-options/index.js"],
4
+ "sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { Flex, FlexItem, Modal, ToggleControl } from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { useState, useMemo, useEffect } from '@wordpress/element';\nimport {\n\tstore as blockEditorStore,\n\t__experimentalBlockPatternsList as BlockPatternsList,\n} from '@wordpress/block-editor';\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport { store as coreStore } from '@wordpress/core-data';\nimport { __unstableSerializeAndClean } from '@wordpress/blocks';\nimport { store as preferencesStore } from '@wordpress/preferences';\nimport { store as interfaceStore } from '@wordpress/interface';\n\n/**\n * Internal dependencies\n */\nimport { TEMPLATE_POST_TYPE } from '../../store/constants';\nimport { store as editorStore } from '../../store';\n\nexport function useStartPatterns() {\n\t// A pattern is a start pattern if it includes 'core/post-content' in its blockTypes,\n\t// and it has no postTypes declared and the current post type is page or if\n\t// the current post type is part of the postTypes declared.\n\tconst { blockPatternsWithPostContentBlockType, postType } = useSelect(\n\t\t( select ) => {\n\t\t\tconst { getPatternsByBlockTypes, getBlocksByName } =\n\t\t\t\tselect( blockEditorStore );\n\t\t\tconst { getCurrentPostType, getRenderingMode } =\n\t\t\t\tselect( editorStore );\n\t\t\tconst rootClientId =\n\t\t\t\tgetRenderingMode() === 'post-only'\n\t\t\t\t\t? ''\n\t\t\t\t\t: getBlocksByName( 'core/post-content' )?.[ 0 ];\n\t\t\treturn {\n\t\t\t\tblockPatternsWithPostContentBlockType: getPatternsByBlockTypes(\n\t\t\t\t\t'core/post-content',\n\t\t\t\t\trootClientId\n\t\t\t\t),\n\t\t\t\tpostType: getCurrentPostType(),\n\t\t\t};\n\t\t},\n\t\t[]\n\t);\n\n\treturn useMemo( () => {\n\t\tif ( ! blockPatternsWithPostContentBlockType?.length ) {\n\t\t\treturn [];\n\t\t}\n\n\t\t/*\n\t\t * Filter patterns without postTypes declared if the current postType is page\n\t\t * or patterns that declare the current postType in its post type array.\n\t\t */\n\t\treturn blockPatternsWithPostContentBlockType.filter( ( pattern ) => {\n\t\t\treturn (\n\t\t\t\t( postType === 'page' && ! pattern.postTypes ) ||\n\t\t\t\t( Array.isArray( pattern.postTypes ) &&\n\t\t\t\t\tpattern.postTypes.includes( postType ) )\n\t\t\t);\n\t\t} );\n\t}, [ postType, blockPatternsWithPostContentBlockType ] );\n}\n\nfunction PatternSelection( { blockPatterns, onChoosePattern } ) {\n\tconst { editEntityRecord } = useDispatch( coreStore );\n\tconst { postType, postId } = useSelect( ( select ) => {\n\t\tconst { getCurrentPostType, getCurrentPostId } = select( editorStore );\n\n\t\treturn {\n\t\t\tpostType: getCurrentPostType(),\n\t\t\tpostId: getCurrentPostId(),\n\t\t};\n\t}, [] );\n\treturn (\n\t\t<BlockPatternsList\n\t\t\tblockPatterns={ blockPatterns }\n\t\t\tonClickPattern={ ( _pattern, blocks ) => {\n\t\t\t\teditEntityRecord( 'postType', postType, postId, {\n\t\t\t\t\tblocks,\n\t\t\t\t\tcontent: ( { blocks: blocksForSerialization = [] } ) =>\n\t\t\t\t\t\t__unstableSerializeAndClean( blocksForSerialization ),\n\t\t\t\t} );\n\t\t\t\tonChoosePattern();\n\t\t\t} }\n\t\t/>\n\t);\n}\n\nfunction StartPageOptionsModal( { onClose } ) {\n\tconst [ showStartPatterns, setShowStartPatterns ] = useState( true );\n\tconst { set: setPreference } = useDispatch( preferencesStore );\n\tconst startPatterns = useStartPatterns();\n\tconst hasStartPattern = startPatterns.length > 0;\n\n\tif ( ! hasStartPattern ) {\n\t\treturn null;\n\t}\n\n\tfunction handleClose() {\n\t\tonClose();\n\t\tsetPreference( 'core', 'enableChoosePatternModal', showStartPatterns );\n\t}\n\n\treturn (\n\t\t<Modal\n\t\t\tclassName=\"editor-start-page-options__modal\"\n\t\t\ttitle={ __( 'Choose a pattern' ) }\n\t\t\tisFullScreen\n\t\t\tonRequestClose={ handleClose }\n\t\t>\n\t\t\t<div className=\"editor-start-page-options__modal-content\">\n\t\t\t\t<PatternSelection\n\t\t\t\t\tblockPatterns={ startPatterns }\n\t\t\t\t\tonChoosePattern={ handleClose }\n\t\t\t\t/>\n\t\t\t</div>\n\t\t\t<Flex\n\t\t\t\tclassName=\"editor-start-page-options__modal__actions\"\n\t\t\t\tjustify=\"flex-end\"\n\t\t\t\texpanded={ false }\n\t\t\t>\n\t\t\t\t<FlexItem>\n\t\t\t\t\t<ToggleControl\n\t\t\t\t\t\t__nextHasNoMarginBottom\n\t\t\t\t\t\tchecked={ showStartPatterns }\n\t\t\t\t\t\tlabel={ __( 'Show starter patterns' ) }\n\t\t\t\t\t\thelp={ __(\n\t\t\t\t\t\t\t'Shows starter patterns when creating a new page.'\n\t\t\t\t\t\t) }\n\t\t\t\t\t\tonChange={ ( newValue ) => {\n\t\t\t\t\t\t\tsetShowStartPatterns( newValue );\n\t\t\t\t\t\t} }\n\t\t\t\t\t/>\n\t\t\t\t</FlexItem>\n\t\t\t</Flex>\n\t\t</Modal>\n\t);\n}\n\nexport default function StartPageOptions() {\n\tconst [ isOpen, setIsOpen ] = useState( false );\n\tconst { isEditedPostDirty, isEditedPostEmpty } = useSelect( editorStore );\n\tconst { isModalActive } = useSelect( interfaceStore );\n\tconst { enabled, postId } = useSelect( ( select ) => {\n\t\tconst { getCurrentPostId, getCurrentPostType } = select( editorStore );\n\t\tconst choosePatternModalEnabled = select( preferencesStore ).get(\n\t\t\t'core',\n\t\t\t'enableChoosePatternModal'\n\t\t);\n\t\treturn {\n\t\t\tpostId: getCurrentPostId(),\n\t\t\tenabled:\n\t\t\t\tchoosePatternModalEnabled &&\n\t\t\t\tTEMPLATE_POST_TYPE !== getCurrentPostType(),\n\t\t};\n\t}, [] );\n\n\t// Note: The `postId` ensures the effect re-runs when pages are switched without remounting the component.\n\t// Examples: changing pages in the List View, creating a new page via Command Palette.\n\tuseEffect( () => {\n\t\tconst isFreshPage = ! isEditedPostDirty() && isEditedPostEmpty();\n\t\t// Prevents immediately opening when features is enabled via preferences modal.\n\t\tconst isPreferencesModalActive = isModalActive( 'editor/preferences' );\n\t\tif ( ! enabled || ! isFreshPage || isPreferencesModalActive ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Open the modal after the initial render for a new page.\n\t\tsetIsOpen( true );\n\t}, [\n\t\tenabled,\n\t\tpostId,\n\t\tisEditedPostDirty,\n\t\tisEditedPostEmpty,\n\t\tisModalActive,\n\t] );\n\n\tif ( ! isOpen ) {\n\t\treturn null;\n\t}\n\n\treturn <StartPageOptionsModal onClose={ () => setIsOpen( false ) } />;\n}\n"],
5
+ "mappings": "AA6EE,cA8BA,YA9BA;AA1EF,SAAS,MAAM,UAAU,OAAO,qBAAqB;AACrD,SAAS,UAAU;AACnB,SAAS,UAAU,SAAS,iBAAiB;AAC7C;AAAA,EACC,SAAS;AAAA,EACT,mCAAmC;AAAA,OAC7B;AACP,SAAS,WAAW,mBAAmB;AACvC,SAAS,SAAS,iBAAiB;AACnC,SAAS,mCAAmC;AAC5C,SAAS,SAAS,wBAAwB;AAC1C,SAAS,SAAS,sBAAsB;AAKxC,SAAS,0BAA0B;AACnC,SAAS,SAAS,mBAAmB;AAE9B,SAAS,mBAAmB;AAIlC,QAAM,EAAE,uCAAuC,SAAS,IAAI;AAAA,IAC3D,CAAE,WAAY;AACb,YAAM,EAAE,yBAAyB,gBAAgB,IAChD,OAAQ,gBAAiB;AAC1B,YAAM,EAAE,oBAAoB,iBAAiB,IAC5C,OAAQ,WAAY;AACrB,YAAM,eACL,iBAAiB,MAAM,cACpB,KACA,gBAAiB,mBAAoB,IAAK,CAAE;AAChD,aAAO;AAAA,QACN,uCAAuC;AAAA,UACtC;AAAA,UACA;AAAA,QACD;AAAA,QACA,UAAU,mBAAmB;AAAA,MAC9B;AAAA,IACD;AAAA,IACA,CAAC;AAAA,EACF;AAEA,SAAO,QAAS,MAAM;AACrB,QAAK,CAAE,uCAAuC,QAAS;AACtD,aAAO,CAAC;AAAA,IACT;AAMA,WAAO,sCAAsC,OAAQ,CAAE,Y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