@wordpress/edit-site 5.29.0 → 5.30.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 (364) hide show
  1. package/CHANGELOG.md +2 -0
  2. package/build/components/actions/index.js +1 -1
  3. package/build/components/actions/index.js.map +1 -1
  4. package/build/components/block-editor/editor-canvas.js +10 -11
  5. package/build/components/block-editor/editor-canvas.js.map +1 -1
  6. package/build/components/editor/index.js +1 -15
  7. package/build/components/editor/index.js.map +1 -1
  8. package/build/components/global-styles/color-palette-panel.js +9 -0
  9. package/build/components/global-styles/color-palette-panel.js.map +1 -1
  10. package/build/components/global-styles/font-families.js +1 -1
  11. package/build/components/global-styles/font-families.js.map +1 -1
  12. package/build/components/global-styles/font-library-modal/collection-font-variant.js +2 -2
  13. package/build/components/global-styles/font-library-modal/collection-font-variant.js.map +1 -1
  14. package/build/components/global-styles/font-library-modal/context.js +62 -58
  15. package/build/components/global-styles/font-library-modal/context.js.map +1 -1
  16. package/build/components/global-styles/font-library-modal/font-card.js +10 -15
  17. package/build/components/global-styles/font-library-modal/font-card.js.map +1 -1
  18. package/build/components/global-styles/font-library-modal/font-collection.js +118 -76
  19. package/build/components/global-styles/font-library-modal/font-collection.js.map +1 -1
  20. package/build/components/global-styles/font-library-modal/font-demo.js +29 -8
  21. package/build/components/global-styles/font-library-modal/font-demo.js.map +1 -1
  22. package/build/components/global-styles/font-library-modal/index.js +19 -6
  23. package/build/components/global-styles/font-library-modal/index.js.map +1 -1
  24. package/build/components/global-styles/font-library-modal/installed-fonts.js +151 -79
  25. package/build/components/global-styles/font-library-modal/installed-fonts.js.map +1 -1
  26. package/build/components/global-styles/font-library-modal/library-font-variant.js +2 -2
  27. package/build/components/global-styles/font-library-modal/library-font-variant.js.map +1 -1
  28. package/build/components/global-styles/font-library-modal/upload-fonts.js +8 -14
  29. package/build/components/global-styles/font-library-modal/upload-fonts.js.map +1 -1
  30. package/build/components/global-styles/font-library-modal/utils/index.js +38 -4
  31. package/build/components/global-styles/font-library-modal/utils/index.js.map +1 -1
  32. package/build/components/global-styles/font-library-modal/utils/preview-styles.js +1 -1
  33. package/build/components/global-styles/font-library-modal/utils/preview-styles.js.map +1 -1
  34. package/build/components/global-styles/gradients-palette-panel.js.map +1 -1
  35. package/build/components/global-styles/header.js +1 -1
  36. package/build/components/global-styles/header.js.map +1 -1
  37. package/build/components/global-styles/highlighted-colors.js +50 -0
  38. package/build/components/global-styles/highlighted-colors.js.map +1 -0
  39. package/build/components/global-styles/preview-colors.js +62 -0
  40. package/build/components/global-styles/preview-colors.js.map +1 -0
  41. package/build/components/global-styles/preview-iframe.js +131 -0
  42. package/build/components/global-styles/preview-iframe.js.map +1 -0
  43. package/build/components/global-styles/preview-styles.js +163 -0
  44. package/build/components/global-styles/preview-styles.js.map +1 -0
  45. package/build/components/global-styles/preview-typography.js +65 -0
  46. package/build/components/global-styles/preview-typography.js.map +1 -0
  47. package/build/components/global-styles/screen-block-list.js +1 -1
  48. package/build/components/global-styles/screen-block-list.js.map +1 -1
  49. package/build/components/global-styles/screen-block.js +1 -1
  50. package/build/components/global-styles/screen-block.js.map +1 -1
  51. package/build/components/global-styles/screen-colors.js +10 -2
  52. package/build/components/global-styles/screen-colors.js.map +1 -1
  53. package/build/components/global-styles/screen-revisions/index.js +2 -2
  54. package/build/components/global-styles/screen-revisions/index.js.map +1 -1
  55. package/build/components/global-styles/screen-root.js +2 -2
  56. package/build/components/global-styles/screen-root.js.map +1 -1
  57. package/build/components/global-styles/screen-typography.js +10 -2
  58. package/build/components/global-styles/screen-typography.js.map +1 -1
  59. package/build/components/global-styles/style-variations-container.js +12 -84
  60. package/build/components/global-styles/style-variations-container.js.map +1 -1
  61. package/build/components/global-styles/{typogrphy-elements.js → typography-elements.js} +1 -1
  62. package/build/components/global-styles/typography-elements.js.map +1 -0
  63. package/build/components/global-styles/ui.js +27 -2
  64. package/build/components/global-styles/ui.js.map +1 -1
  65. package/build/components/global-styles/utils.js +22 -0
  66. package/build/components/global-styles/utils.js.map +1 -1
  67. package/build/components/global-styles/variations/variation.js +90 -0
  68. package/build/components/global-styles/variations/variation.js.map +1 -0
  69. package/build/components/global-styles/variations/variations-color.js +36 -0
  70. package/build/components/global-styles/variations/variations-color.js.map +1 -0
  71. package/build/components/global-styles/{variations-panel.js → variations/variations-panel.js} +1 -1
  72. package/build/components/global-styles/variations/variations-panel.js.map +1 -0
  73. package/build/components/global-styles/variations/variations-typography.js +64 -0
  74. package/build/components/global-styles/variations/variations-typography.js.map +1 -0
  75. package/build/components/header-edit-mode/index.js +12 -11
  76. package/build/components/header-edit-mode/index.js.map +1 -1
  77. package/build/components/header-edit-mode/more-menu/index.js +10 -2
  78. package/build/components/header-edit-mode/more-menu/index.js.map +1 -1
  79. package/build/components/layout/index.js +4 -1
  80. package/build/components/layout/index.js.map +1 -1
  81. package/build/components/page-patterns/index.js +14 -14
  82. package/build/components/page-patterns/index.js.map +1 -1
  83. package/build/components/{list/added-by.js → page-templates-template-parts/hooks.js} +1 -61
  84. package/build/components/page-templates-template-parts/hooks.js.map +1 -0
  85. package/build/components/page-templates-template-parts/index.js +14 -6
  86. package/build/components/page-templates-template-parts/index.js.map +1 -1
  87. package/build/components/resizable-frame/index.js +2 -1
  88. package/build/components/resizable-frame/index.js.map +1 -1
  89. package/build/components/revisions/index.js.map +1 -1
  90. package/build/components/save-panel/index.js +18 -3
  91. package/build/components/save-panel/index.js.map +1 -1
  92. package/build/components/sidebar/index.js +1 -1
  93. package/build/components/sidebar/index.js.map +1 -1
  94. package/build/components/sidebar-dataviews/default-views.js +2 -0
  95. package/build/components/sidebar-dataviews/default-views.js.map +1 -1
  96. package/build/components/sidebar-edit-mode/page-panels/page-status.js.map +1 -1
  97. package/build/components/sidebar-edit-mode/template-panel/index.js.map +1 -1
  98. package/build/components/sidebar-navigation-screen-main/index.js +1 -2
  99. package/build/components/sidebar-navigation-screen-main/index.js.map +1 -1
  100. package/build/components/sidebar-navigation-screen-navigation-menu/delete-modal.js.map +1 -1
  101. package/build/components/sidebar-navigation-screen-navigation-menu/single-navigation-menu.js +0 -3
  102. package/build/components/sidebar-navigation-screen-navigation-menu/single-navigation-menu.js.map +1 -1
  103. package/build/components/sidebar-navigation-screen-pattern/template-part-navigation-menu.js.map +1 -1
  104. package/build/components/sidebar-navigation-screen-pattern/template-part-navigation-menus.js.map +1 -1
  105. package/build/components/sidebar-navigation-screen-pattern/use-pattern-details.js +2 -2
  106. package/build/components/sidebar-navigation-screen-pattern/use-pattern-details.js.map +1 -1
  107. package/build/components/sidebar-navigation-screen-template/index.js +2 -2
  108. package/build/components/sidebar-navigation-screen-template/index.js.map +1 -1
  109. package/build/components/sidebar-navigation-screen-templates-browse/content.js +4 -4
  110. package/build/components/sidebar-navigation-screen-templates-browse/content.js.map +1 -1
  111. package/build/components/sidebar-navigation-screen-templates-browse/index.js +7 -5
  112. package/build/components/sidebar-navigation-screen-templates-browse/index.js.map +1 -1
  113. package/build/components/start-template-options/index.js.map +1 -1
  114. package/build/hooks/use-theme-style-variations/use-theme-style-variations-by-property.js +65 -0
  115. package/build/hooks/use-theme-style-variations/use-theme-style-variations-by-property.js.map +1 -1
  116. package/build-module/components/actions/index.js +1 -1
  117. package/build-module/components/actions/index.js.map +1 -1
  118. package/build-module/components/block-editor/editor-canvas.js +10 -11
  119. package/build-module/components/block-editor/editor-canvas.js.map +1 -1
  120. package/build-module/components/editor/index.js +2 -16
  121. package/build-module/components/editor/index.js.map +1 -1
  122. package/build-module/components/global-styles/color-palette-panel.js +8 -0
  123. package/build-module/components/global-styles/color-palette-panel.js.map +1 -1
  124. package/build-module/components/global-styles/font-families.js +1 -1
  125. package/build-module/components/global-styles/font-families.js.map +1 -1
  126. package/build-module/components/global-styles/font-library-modal/collection-font-variant.js +4 -4
  127. package/build-module/components/global-styles/font-library-modal/collection-font-variant.js.map +1 -1
  128. package/build-module/components/global-styles/font-library-modal/context.js +63 -59
  129. package/build-module/components/global-styles/font-library-modal/context.js.map +1 -1
  130. package/build-module/components/global-styles/font-library-modal/font-card.js +11 -16
  131. package/build-module/components/global-styles/font-library-modal/font-card.js.map +1 -1
  132. package/build-module/components/global-styles/font-library-modal/font-collection.js +121 -79
  133. package/build-module/components/global-styles/font-library-modal/font-collection.js.map +1 -1
  134. package/build-module/components/global-styles/font-library-modal/font-demo.js +30 -9
  135. package/build-module/components/global-styles/font-library-modal/font-demo.js.map +1 -1
  136. package/build-module/components/global-styles/font-library-modal/index.js +19 -6
  137. package/build-module/components/global-styles/font-library-modal/index.js.map +1 -1
  138. package/build-module/components/global-styles/font-library-modal/installed-fonts.js +151 -79
  139. package/build-module/components/global-styles/font-library-modal/installed-fonts.js.map +1 -1
  140. package/build-module/components/global-styles/font-library-modal/library-font-variant.js +4 -4
  141. package/build-module/components/global-styles/font-library-modal/library-font-variant.js.map +1 -1
  142. package/build-module/components/global-styles/font-library-modal/upload-fonts.js +9 -15
  143. package/build-module/components/global-styles/font-library-modal/upload-fonts.js.map +1 -1
  144. package/build-module/components/global-styles/font-library-modal/utils/index.js +37 -4
  145. package/build-module/components/global-styles/font-library-modal/utils/index.js.map +1 -1
  146. package/build-module/components/global-styles/font-library-modal/utils/preview-styles.js +1 -1
  147. package/build-module/components/global-styles/font-library-modal/utils/preview-styles.js.map +1 -1
  148. package/build-module/components/global-styles/gradients-palette-panel.js.map +1 -1
  149. package/build-module/components/global-styles/header.js +1 -1
  150. package/build-module/components/global-styles/header.js.map +1 -1
  151. package/build-module/components/global-styles/highlighted-colors.js +43 -0
  152. package/build-module/components/global-styles/highlighted-colors.js.map +1 -0
  153. package/build-module/components/global-styles/preview-colors.js +54 -0
  154. package/build-module/components/global-styles/preview-colors.js.map +1 -0
  155. package/build-module/components/global-styles/preview-iframe.js +124 -0
  156. package/build-module/components/global-styles/preview-iframe.js.map +1 -0
  157. package/build-module/components/global-styles/preview-styles.js +155 -0
  158. package/build-module/components/global-styles/preview-styles.js.map +1 -0
  159. package/build-module/components/global-styles/preview-typography.js +58 -0
  160. package/build-module/components/global-styles/preview-typography.js.map +1 -0
  161. package/build-module/components/global-styles/screen-block-list.js +1 -1
  162. package/build-module/components/global-styles/screen-block-list.js.map +1 -1
  163. package/build-module/components/global-styles/screen-block.js +1 -1
  164. package/build-module/components/global-styles/screen-block.js.map +1 -1
  165. package/build-module/components/global-styles/screen-colors.js +10 -2
  166. package/build-module/components/global-styles/screen-colors.js.map +1 -1
  167. package/build-module/components/global-styles/screen-revisions/index.js +2 -2
  168. package/build-module/components/global-styles/screen-revisions/index.js.map +1 -1
  169. package/build-module/components/global-styles/screen-root.js +2 -2
  170. package/build-module/components/global-styles/screen-root.js.map +1 -1
  171. package/build-module/components/global-styles/screen-typography.js +10 -2
  172. package/build-module/components/global-styles/screen-typography.js.map +1 -1
  173. package/build-module/components/global-styles/style-variations-container.js +13 -85
  174. package/build-module/components/global-styles/style-variations-container.js.map +1 -1
  175. package/build-module/components/global-styles/{typogrphy-elements.js → typography-elements.js} +1 -1
  176. package/build-module/components/global-styles/typography-elements.js.map +1 -0
  177. package/build-module/components/global-styles/ui.js +27 -2
  178. package/build-module/components/global-styles/ui.js.map +1 -1
  179. package/build-module/components/global-styles/utils.js +21 -0
  180. package/build-module/components/global-styles/utils.js.map +1 -1
  181. package/build-module/components/global-styles/variations/variation.js +82 -0
  182. package/build-module/components/global-styles/variations/variation.js.map +1 -0
  183. package/build-module/components/global-styles/variations/variations-color.js +28 -0
  184. package/build-module/components/global-styles/variations/variations-color.js.map +1 -0
  185. package/build-module/components/global-styles/{variations-panel.js → variations/variations-panel.js} +1 -1
  186. package/build-module/components/global-styles/variations/variations-panel.js.map +1 -0
  187. package/build-module/components/global-styles/variations/variations-typography.js +56 -0
  188. package/build-module/components/global-styles/variations/variations-typography.js.map +1 -0
  189. package/build-module/components/header-edit-mode/index.js +13 -12
  190. package/build-module/components/header-edit-mode/index.js.map +1 -1
  191. package/build-module/components/header-edit-mode/more-menu/index.js +13 -5
  192. package/build-module/components/header-edit-mode/more-menu/index.js.map +1 -1
  193. package/build-module/components/layout/index.js +4 -1
  194. package/build-module/components/layout/index.js.map +1 -1
  195. package/build-module/components/page-patterns/index.js +14 -14
  196. package/build-module/components/page-patterns/index.js.map +1 -1
  197. package/build-module/components/{list/added-by.js → page-templates-template-parts/hooks.js} +2 -59
  198. package/build-module/components/page-templates-template-parts/hooks.js.map +1 -0
  199. package/build-module/components/page-templates-template-parts/index.js +13 -5
  200. package/build-module/components/page-templates-template-parts/index.js.map +1 -1
  201. package/build-module/components/resizable-frame/index.js +2 -1
  202. package/build-module/components/resizable-frame/index.js.map +1 -1
  203. package/build-module/components/revisions/index.js.map +1 -1
  204. package/build-module/components/save-panel/index.js +18 -3
  205. package/build-module/components/save-panel/index.js.map +1 -1
  206. package/build-module/components/sidebar/index.js +1 -1
  207. package/build-module/components/sidebar/index.js.map +1 -1
  208. package/build-module/components/sidebar-dataviews/default-views.js +3 -1
  209. package/build-module/components/sidebar-dataviews/default-views.js.map +1 -1
  210. package/build-module/components/sidebar-edit-mode/page-panels/page-status.js.map +1 -1
  211. package/build-module/components/sidebar-edit-mode/template-panel/index.js.map +1 -1
  212. package/build-module/components/sidebar-navigation-screen-main/index.js +1 -2
  213. package/build-module/components/sidebar-navigation-screen-main/index.js.map +1 -1
  214. package/build-module/components/sidebar-navigation-screen-navigation-menu/delete-modal.js.map +1 -1
  215. package/build-module/components/sidebar-navigation-screen-navigation-menu/single-navigation-menu.js +0 -3
  216. package/build-module/components/sidebar-navigation-screen-navigation-menu/single-navigation-menu.js.map +1 -1
  217. package/build-module/components/sidebar-navigation-screen-pattern/template-part-navigation-menu.js.map +1 -1
  218. package/build-module/components/sidebar-navigation-screen-pattern/template-part-navigation-menus.js.map +1 -1
  219. package/build-module/components/sidebar-navigation-screen-pattern/use-pattern-details.js +1 -1
  220. package/build-module/components/sidebar-navigation-screen-pattern/use-pattern-details.js.map +1 -1
  221. package/build-module/components/sidebar-navigation-screen-template/index.js +1 -1
  222. package/build-module/components/sidebar-navigation-screen-template/index.js.map +1 -1
  223. package/build-module/components/sidebar-navigation-screen-templates-browse/content.js +3 -3
  224. package/build-module/components/sidebar-navigation-screen-templates-browse/content.js.map +1 -1
  225. package/build-module/components/sidebar-navigation-screen-templates-browse/index.js +7 -5
  226. package/build-module/components/sidebar-navigation-screen-templates-browse/index.js.map +1 -1
  227. package/build-module/components/start-template-options/index.js.map +1 -1
  228. package/build-module/hooks/use-theme-style-variations/use-theme-style-variations-by-property.js +63 -1
  229. package/build-module/hooks/use-theme-style-variations/use-theme-style-variations-by-property.js.map +1 -1
  230. package/build-style/style-rtl.css +163 -286
  231. package/build-style/style.css +163 -286
  232. package/package.json +42 -42
  233. package/src/components/actions/index.js +1 -1
  234. package/src/components/block-editor/editor-canvas.js +13 -12
  235. package/src/components/block-editor/style.scss +0 -3
  236. package/src/components/editor/index.js +0 -20
  237. package/src/components/global-styles/color-palette-panel.js +11 -1
  238. package/src/components/global-styles/font-families.js +1 -1
  239. package/src/components/global-styles/font-library-modal/collection-font-variant.js +5 -5
  240. package/src/components/global-styles/font-library-modal/context.js +116 -104
  241. package/src/components/global-styles/font-library-modal/font-card.js +11 -26
  242. package/src/components/global-styles/font-library-modal/font-collection.js +297 -218
  243. package/src/components/global-styles/font-library-modal/font-demo.js +38 -4
  244. package/src/components/global-styles/font-library-modal/index.js +23 -16
  245. package/src/components/global-styles/font-library-modal/installed-fonts.js +243 -114
  246. package/src/components/global-styles/font-library-modal/library-font-variant.js +5 -5
  247. package/src/components/global-styles/font-library-modal/style.scss +15 -8
  248. package/src/components/global-styles/font-library-modal/upload-fonts.js +17 -19
  249. package/src/components/global-styles/font-library-modal/utils/index.js +44 -4
  250. package/src/components/global-styles/font-library-modal/utils/preview-styles.js +2 -1
  251. package/src/components/global-styles/font-library-modal/utils/test/getDisplaySrcFromFontFace.spec.js +7 -18
  252. package/src/components/global-styles/gradients-palette-panel.js +2 -2
  253. package/src/components/global-styles/header.js +1 -1
  254. package/src/components/global-styles/highlighted-colors.js +39 -0
  255. package/src/components/global-styles/preview-colors.js +61 -0
  256. package/src/components/global-styles/preview-iframe.js +153 -0
  257. package/src/components/global-styles/preview-styles.js +185 -0
  258. package/src/components/global-styles/preview-typography.js +62 -0
  259. package/src/components/global-styles/screen-block-list.js +1 -1
  260. package/src/components/global-styles/screen-block.js +4 -1
  261. package/src/components/global-styles/screen-colors.js +13 -1
  262. package/src/components/global-styles/screen-revisions/index.js +5 -2
  263. package/src/components/global-styles/screen-root.js +2 -2
  264. package/src/components/global-styles/screen-typography.js +19 -2
  265. package/src/components/global-styles/style-variations-container.js +14 -92
  266. package/src/components/global-styles/style.scss +0 -34
  267. package/src/components/global-styles/ui.js +26 -2
  268. package/src/components/global-styles/utils.js +37 -0
  269. package/src/components/global-styles/variations/style.scss +44 -0
  270. package/src/components/global-styles/variations/variation.js +93 -0
  271. package/src/components/global-styles/variations/variations-color.js +30 -0
  272. package/src/components/global-styles/{variations-panel.js → variations/variations-panel.js} +1 -1
  273. package/src/components/global-styles/variations/variations-typography.js +85 -0
  274. package/src/components/header-edit-mode/index.js +20 -27
  275. package/src/components/header-edit-mode/more-menu/index.js +17 -8
  276. package/src/components/header-edit-mode/style.scss +4 -0
  277. package/src/components/layout/index.js +5 -0
  278. package/src/components/page-patterns/index.js +21 -21
  279. package/src/components/{list/added-by.js → page-templates-template-parts/hooks.js} +1 -66
  280. package/src/components/page-templates-template-parts/index.js +20 -3
  281. package/src/components/page-templates-template-parts/style.scss +48 -0
  282. package/src/components/resizable-frame/index.js +1 -0
  283. package/src/components/revisions/index.js +1 -1
  284. package/src/components/save-panel/index.js +34 -12
  285. package/src/components/sidebar/index.js +1 -1
  286. package/src/components/sidebar-dataviews/default-views.js +3 -1
  287. package/src/components/sidebar-edit-mode/page-panels/page-status.js +1 -1
  288. package/src/components/sidebar-edit-mode/template-panel/index.js +1 -1
  289. package/src/components/sidebar-navigation-screen-main/index.js +0 -2
  290. package/src/components/sidebar-navigation-screen-navigation-menu/delete-modal.js +1 -1
  291. package/src/components/sidebar-navigation-screen-navigation-menu/single-navigation-menu.js +0 -2
  292. package/src/components/sidebar-navigation-screen-pattern/template-part-navigation-menu.js +1 -1
  293. package/src/components/sidebar-navigation-screen-pattern/template-part-navigation-menus.js +1 -1
  294. package/src/components/sidebar-navigation-screen-pattern/use-pattern-details.js +1 -1
  295. package/src/components/sidebar-navigation-screen-template/index.js +1 -1
  296. package/src/components/sidebar-navigation-screen-templates-browse/content.js +3 -3
  297. package/src/components/sidebar-navigation-screen-templates-browse/index.js +5 -3
  298. package/src/components/start-template-options/index.js +1 -1
  299. package/src/hooks/use-theme-style-variations/test/use-theme-style-variations-by-property.js +173 -0
  300. package/src/hooks/use-theme-style-variations/use-theme-style-variations-by-property.js +68 -1
  301. package/src/style.scss +2 -2
  302. package/build/components/global-styles/font-library-modal/collection-font-details.js +0 -50
  303. package/build/components/global-styles/font-library-modal/collection-font-details.js.map +0 -1
  304. package/build/components/global-styles/font-library-modal/confirm-delete-dialog.js +0 -30
  305. package/build/components/global-styles/font-library-modal/confirm-delete-dialog.js.map +0 -1
  306. package/build/components/global-styles/font-library-modal/library-font-card.js +0 -39
  307. package/build/components/global-styles/font-library-modal/library-font-card.js.map +0 -1
  308. package/build/components/global-styles/font-library-modal/tab-panel-layout.js +0 -67
  309. package/build/components/global-styles/font-library-modal/tab-panel-layout.js.map +0 -1
  310. package/build/components/global-styles/preview.js +0 -271
  311. package/build/components/global-styles/preview.js.map +0 -1
  312. package/build/components/global-styles/typogrphy-elements.js.map +0 -1
  313. package/build/components/global-styles/variations-panel.js.map +0 -1
  314. package/build/components/list/added-by.js.map +0 -1
  315. package/build/components/list/header.js +0 -55
  316. package/build/components/list/header.js.map +0 -1
  317. package/build/components/list/index.js +0 -80
  318. package/build/components/list/index.js.map +0 -1
  319. package/build/components/list/table.js +0 -94
  320. package/build/components/list/table.js.map +0 -1
  321. package/build/components/list/use-register-shortcuts.js +0 -51
  322. package/build/components/list/use-register-shortcuts.js.map +0 -1
  323. package/build/components/sidebar-navigation-screen-main/template-part-hint.js +0 -36
  324. package/build/components/sidebar-navigation-screen-main/template-part-hint.js.map +0 -1
  325. package/build/components/sidebar-navigation-screen-navigation-menu/edit-button.js +0 -36
  326. package/build/components/sidebar-navigation-screen-navigation-menu/edit-button.js.map +0 -1
  327. package/build-module/components/global-styles/font-library-modal/collection-font-details.js +0 -42
  328. package/build-module/components/global-styles/font-library-modal/collection-font-details.js.map +0 -1
  329. package/build-module/components/global-styles/font-library-modal/confirm-delete-dialog.js +0 -23
  330. package/build-module/components/global-styles/font-library-modal/confirm-delete-dialog.js.map +0 -1
  331. package/build-module/components/global-styles/font-library-modal/library-font-card.js +0 -31
  332. package/build-module/components/global-styles/font-library-modal/library-font-card.js.map +0 -1
  333. package/build-module/components/global-styles/font-library-modal/tab-panel-layout.js +0 -60
  334. package/build-module/components/global-styles/font-library-modal/tab-panel-layout.js.map +0 -1
  335. package/build-module/components/global-styles/preview.js +0 -264
  336. package/build-module/components/global-styles/preview.js.map +0 -1
  337. package/build-module/components/global-styles/typogrphy-elements.js.map +0 -1
  338. package/build-module/components/global-styles/variations-panel.js.map +0 -1
  339. package/build-module/components/list/added-by.js.map +0 -1
  340. package/build-module/components/list/header.js +0 -47
  341. package/build-module/components/list/header.js.map +0 -1
  342. package/build-module/components/list/index.js +0 -72
  343. package/build-module/components/list/index.js.map +0 -1
  344. package/build-module/components/list/table.js +0 -86
  345. package/build-module/components/list/table.js.map +0 -1
  346. package/build-module/components/list/use-register-shortcuts.js +0 -45
  347. package/build-module/components/list/use-register-shortcuts.js.map +0 -1
  348. package/build-module/components/sidebar-navigation-screen-main/template-part-hint.js +0 -29
  349. package/build-module/components/sidebar-navigation-screen-main/template-part-hint.js.map +0 -1
  350. package/build-module/components/sidebar-navigation-screen-navigation-menu/edit-button.js +0 -27
  351. package/build-module/components/sidebar-navigation-screen-navigation-menu/edit-button.js.map +0 -1
  352. package/src/components/global-styles/font-library-modal/collection-font-details.js +0 -56
  353. package/src/components/global-styles/font-library-modal/confirm-delete-dialog.js +0 -33
  354. package/src/components/global-styles/font-library-modal/library-font-card.js +0 -34
  355. package/src/components/global-styles/font-library-modal/tab-panel-layout.js +0 -85
  356. package/src/components/global-styles/preview.js +0 -327
  357. package/src/components/list/header.js +0 -48
  358. package/src/components/list/index.js +0 -87
  359. package/src/components/list/style.scss +0 -188
  360. package/src/components/list/table.js +0 -140
  361. package/src/components/list/use-register-shortcuts.js +0 -49
  362. package/src/components/sidebar-navigation-screen-main/template-part-hint.js +0 -34
  363. package/src/components/sidebar-navigation-screen-navigation-menu/edit-button.js +0 -22
  364. /package/src/components/global-styles/{typogrphy-elements.js → typography-elements.js} +0 -0
@@ -0,0 +1,90 @@
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+ Object.defineProperty(exports, "__esModule", {
5
+ value: true
6
+ });
7
+ exports.default = Variation;
8
+ var _react = require("react");
9
+ var _classnames = _interopRequireDefault(require("classnames"));
10
+ var _element = require("@wordpress/element");
11
+ var _keycodes = require("@wordpress/keycodes");
12
+ var _i18n = require("@wordpress/i18n");
13
+ var _blockEditor = require("@wordpress/block-editor");
14
+ var _globalStylesProvider = require("../global-styles-provider");
15
+ var _lockUnlock = require("../../../lock-unlock");
16
+ /**
17
+ * External dependencies
18
+ */
19
+
20
+ /**
21
+ * WordPress dependencies
22
+ */
23
+
24
+ /**
25
+ * Internal dependencies
26
+ */
27
+
28
+ const {
29
+ GlobalStylesContext,
30
+ areGlobalStyleConfigsEqual
31
+ } = (0, _lockUnlock.unlock)(_blockEditor.privateApis);
32
+ function Variation({
33
+ variation,
34
+ children
35
+ }) {
36
+ const [isFocused, setIsFocused] = (0, _element.useState)(false);
37
+ const {
38
+ base,
39
+ user,
40
+ setUserConfig
41
+ } = (0, _element.useContext)(GlobalStylesContext);
42
+ const context = (0, _element.useMemo)(() => {
43
+ var _variation$settings, _variation$styles;
44
+ return {
45
+ user: {
46
+ settings: (_variation$settings = variation.settings) !== null && _variation$settings !== void 0 ? _variation$settings : {},
47
+ styles: (_variation$styles = variation.styles) !== null && _variation$styles !== void 0 ? _variation$styles : {}
48
+ },
49
+ base,
50
+ merged: (0, _globalStylesProvider.mergeBaseAndUserConfigs)(base, variation),
51
+ setUserConfig: () => {}
52
+ };
53
+ }, [variation, base]);
54
+ const selectVariation = () => {
55
+ setUserConfig(() => ({
56
+ settings: variation.settings,
57
+ styles: variation.styles
58
+ }));
59
+ };
60
+ const selectOnEnter = event => {
61
+ if (event.keyCode === _keycodes.ENTER) {
62
+ event.preventDefault();
63
+ selectVariation();
64
+ }
65
+ };
66
+ const isActive = (0, _element.useMemo)(() => areGlobalStyleConfigsEqual(user, variation), [user, variation]);
67
+ let label = variation?.title;
68
+ if (variation?.description) {
69
+ label = (0, _i18n.sprintf)( /* translators: %1$s: variation title. %2$s variation description. */
70
+ (0, _i18n.__)('%1$s (%2$s)'), variation?.title, variation?.description);
71
+ }
72
+ return (0, _react.createElement)(GlobalStylesContext.Provider, {
73
+ value: context
74
+ }, (0, _react.createElement)("div", {
75
+ className: (0, _classnames.default)('edit-site-global-styles-variations_item', {
76
+ 'is-active': isActive
77
+ }),
78
+ role: "button",
79
+ onClick: selectVariation,
80
+ onKeyDown: selectOnEnter,
81
+ tabIndex: "0",
82
+ "aria-label": label,
83
+ "aria-current": isActive,
84
+ onFocus: () => setIsFocused(true),
85
+ onBlur: () => setIsFocused(false)
86
+ }, (0, _react.createElement)("div", {
87
+ className: "edit-site-global-styles-variations_item-preview"
88
+ }, children(isFocused))));
89
+ }
90
+ //# sourceMappingURL=variation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_classnames","_interopRequireDefault","require","_element","_keycodes","_i18n","_blockEditor","_globalStylesProvider","_lockUnlock","GlobalStylesContext","areGlobalStyleConfigsEqual","unlock","blockEditorPrivateApis","Variation","variation","children","isFocused","setIsFocused","useState","base","user","setUserConfig","useContext","context","useMemo","_variation$settings","_variation$styles","settings","styles","merged","mergeBaseAndUserConfigs","selectVariation","selectOnEnter","event","keyCode","ENTER","preventDefault","isActive","label","title","description","sprintf","__","_react","createElement","Provider","value","className","classnames","role","onClick","onKeyDown","tabIndex","onFocus","onBlur"],"sources":["@wordpress/edit-site/src/components/global-styles/variations/variation.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport classnames from 'classnames';\n\n/**\n * WordPress dependencies\n */\nimport { useMemo, useContext, useState } from '@wordpress/element';\nimport { ENTER } from '@wordpress/keycodes';\nimport { __, sprintf } from '@wordpress/i18n';\nimport { privateApis as blockEditorPrivateApis } from '@wordpress/block-editor';\n\n/**\n * Internal dependencies\n */\nimport { mergeBaseAndUserConfigs } from '../global-styles-provider';\nimport { unlock } from '../../../lock-unlock';\n\nconst { GlobalStylesContext, areGlobalStyleConfigsEqual } = unlock(\n\tblockEditorPrivateApis\n);\n\nexport default function Variation( { variation, children } ) {\n\tconst [ isFocused, setIsFocused ] = useState( false );\n\tconst { base, user, setUserConfig } = useContext( GlobalStylesContext );\n\tconst context = useMemo(\n\t\t() => ( {\n\t\t\tuser: {\n\t\t\t\tsettings: variation.settings ?? {},\n\t\t\t\tstyles: variation.styles ?? {},\n\t\t\t},\n\t\t\tbase,\n\t\t\tmerged: mergeBaseAndUserConfigs( base, variation ),\n\t\t\tsetUserConfig: () => {},\n\t\t} ),\n\t\t[ variation, base ]\n\t);\n\n\tconst selectVariation = () => {\n\t\tsetUserConfig( () => ( {\n\t\t\tsettings: variation.settings,\n\t\t\tstyles: variation.styles,\n\t\t} ) );\n\t};\n\n\tconst selectOnEnter = ( event ) => {\n\t\tif ( event.keyCode === ENTER ) {\n\t\t\tevent.preventDefault();\n\t\t\tselectVariation();\n\t\t}\n\t};\n\n\tconst isActive = useMemo(\n\t\t() => areGlobalStyleConfigsEqual( user, variation ),\n\t\t[ user, variation ]\n\t);\n\n\tlet label = variation?.title;\n\tif ( variation?.description ) {\n\t\tlabel = sprintf(\n\t\t\t/* translators: %1$s: variation title. %2$s variation description. */\n\t\t\t__( '%1$s (%2$s)' ),\n\t\t\tvariation?.title,\n\t\t\tvariation?.description\n\t\t);\n\t}\n\n\treturn (\n\t\t<GlobalStylesContext.Provider value={ context }>\n\t\t\t<div\n\t\t\t\tclassName={ classnames(\n\t\t\t\t\t'edit-site-global-styles-variations_item',\n\t\t\t\t\t{\n\t\t\t\t\t\t'is-active': isActive,\n\t\t\t\t\t}\n\t\t\t\t) }\n\t\t\t\trole=\"button\"\n\t\t\t\tonClick={ selectVariation }\n\t\t\t\tonKeyDown={ selectOnEnter }\n\t\t\t\ttabIndex=\"0\"\n\t\t\t\taria-label={ label }\n\t\t\t\taria-current={ isActive }\n\t\t\t\tonFocus={ () => setIsFocused( true ) }\n\t\t\t\tonBlur={ () => setIsFocused( false ) }\n\t\t\t>\n\t\t\t\t<div className=\"edit-site-global-styles-variations_item-preview\">\n\t\t\t\t\t{ children( isFocused ) }\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t</GlobalStylesContext.Provider>\n\t);\n}\n"],"mappings":";;;;;;;;AAGA,IAAAA,WAAA,GAAAC,sBAAA,CAAAC,OAAA;AAKA,IAAAC,QAAA,GAAAD,OAAA;AACA,IAAAE,SAAA,GAAAF,OAAA;AACA,IAAAG,KAAA,GAAAH,OAAA;AACA,IAAAI,YAAA,GAAAJ,OAAA;AAKA,IAAAK,qBAAA,GAAAL,OAAA;AACA,IAAAM,WAAA,GAAAN,OAAA;AAjBA;AACA;AACA;;AAGA;AACA;AACA;;AAMA;AACA;AACA;;AAIA,MAAM;EAAEO,mBAAmB;EAAEC;AAA2B,CAAC,GAAG,IAAAC,kBAAM,EACjEC,wBACD,CAAC;AAEc,SAASC,SAASA,CAAE;EAAEC,SAAS;EAAEC;AAAS,CAAC,EAAG;EAC5D,MAAM,CAAEC,SAAS,EAAEC,YAAY,CAAE,GAAG,IAAAC,iBAAQ,EAAE,KAAM,CAAC;EACrD,MAAM;IAAEC,IAAI;IAAEC,IAAI;IAAEC;EAAc,CAAC,GAAG,IAAAC,mBAAU,EA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C;EACF;EAEA,OACC,IAAAG,MAAA,CAAAC,aAAA,EAACnC,mBAAmB,CAACoC,QAAQ;IAACC,KAAK,EAAGvB;EAAS,GAC9C,IAAAoB,MAAA,CAAAC,aAAA;IACCG,SAAS,EAAG,IAAAC,mBAAU,EACrB,yCAAyC,EACzC;MACC,WAAW,EAAEX;IACd,CACD,CAAG;IACHY,IAAI,EAAC,QAAQ;IACbC,OAAO,EAAGnB,eAAiB;IAC3BoB,SAAS,EAAGnB,aAAe;IAC3BoB,QAAQ,EAAC,GAAG;IACZ,cAAad,KAAO;IACpB,gBAAeD,QAAU;IACzBgB,OAAO,EAAGA,CAAA,KAAMpC,YAAY,CAAE,IAAK,CAAG;IACtCqC,MAAM,EAAGA,CAAA,KAAMrC,YAAY,CAAE,KAAM;EAAG,GAEtC,IAAA0B,MAAA,CAAAC,aAAA;IAAKG,SAAS,EAAC;EAAiD,GAC7DhC,QAAQ,CAAEC,SAAU,CAClB,CACD,CACwB,CAAC;AAEjC"}
@@ -0,0 +1,36 @@
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+ Object.defineProperty(exports, "__esModule", {
5
+ value: true
6
+ });
7
+ exports.default = ColorVariations;
8
+ var _react = require("react");
9
+ var _components = require("@wordpress/components");
10
+ var _i18n = require("@wordpress/i18n");
11
+ var _subtitle = _interopRequireDefault(require("../subtitle"));
12
+ var _variation = _interopRequireDefault(require("./variation"));
13
+ var _previewColors = _interopRequireDefault(require("../preview-colors"));
14
+ /**
15
+ * WordPress dependencies
16
+ */
17
+
18
+ /**
19
+ * Internal dependencies
20
+ */
21
+
22
+ function ColorVariations({
23
+ variations
24
+ }) {
25
+ return (0, _react.createElement)(_components.__experimentalVStack, {
26
+ spacing: 3
27
+ }, (0, _react.createElement)(_subtitle.default, {
28
+ level: 3
29
+ }, (0, _i18n.__)('Presets')), (0, _react.createElement)(_components.__experimentalGrid, {
30
+ columns: 3
31
+ }, variations.map((variation, index) => (0, _react.createElement)(_variation.default, {
32
+ key: index,
33
+ variation: variation
34
+ }, () => (0, _react.createElement)(_previewColors.default, null)))));
35
+ }
36
+ //# sourceMappingURL=variations-color.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_components","require","_i18n","_subtitle","_interopRequireDefault","_variation","_previewColors","ColorVariations","variations","_react","createElement","__experimentalVStack","spacing","default","level","__","__experimentalGrid","columns","map","variation","index","key"],"sources":["@wordpress/edit-site/src/components/global-styles/variations/variations-color.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport {\n\t__experimentalGrid as Grid,\n\t__experimentalVStack as VStack,\n} from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\n\n/**\n * Internal dependencies\n */\nimport Subtitle from '../subtitle';\nimport Variation from './variation';\nimport StylesPreviewColors from '../preview-colors';\n\nexport default function ColorVariations( { variations } ) {\n\treturn (\n\t\t<VStack spacing={ 3 }>\n\t\t\t<Subtitle level={ 3 }>{ __( 'Presets' ) }</Subtitle>\n\t\t\t<Grid columns={ 3 }>\n\t\t\t\t{ variations.map( ( variation, index ) => (\n\t\t\t\t\t<Variation key={ index } variation={ variation }>\n\t\t\t\t\t\t{ () => <StylesPreviewColors /> }\n\t\t\t\t\t</Variation>\n\t\t\t\t) ) }\n\t\t\t</Grid>\n\t\t</VStack>\n\t);\n}\n"],"mappings":";;;;;;;;AAGA,IAAAA,WAAA,GAAAC,OAAA;AAIA,IAAAC,KAAA,GAAAD,OAAA;AAKA,IAAAE,SAAA,GAAAC,sBAAA,CAAAH,OAAA;AACA,IAAAI,UAAA,GAAAD,sBAAA,CAAAH,OAAA;AACA,IAAAK,cAAA,GAAAF,sBAAA,CAAAH,OAAA;AAdA;AACA;AACA;;AAOA;AACA;AACA;;AAKe,SAASM,eAAeA,CAAE;EAAEC;AAAW,CAAC,EAAG;EACzD,OACC,IAAAC,MAAA,CAAAC,aAAA,EAACV,WAAA,CAAAW,oBAAM;IAACC,OAAO,EAAG;EAAG,GACpB,IAAAH,MAAA,CAAAC,aAAA,EAACP,SAAA,CAAAU,OAAQ;IAACC,KAAK,EAAG;EAAG,GAAG,IAAAC,QAAE,EAAE,SAAU,CAAa,CAAC,EACpD,IAAAN,MAAA,CAAAC,aAAA,EAACV,WAAA,CAAAgB,kBAAI;IAACC,OAAO,EAAG;EAAG,GAChBT,UAAU,CAACU,GAAG,CAAE,CAAEC,SAAS,EAAEC,KAAK,KACnC,IAAAX,MAAA,CAAAC,aAAA,EAACL,UAAA,CAAAQ,OAAS;IAACQ,GAAG,EAAGD,KAAO;IAACD,SAAS,EAAGA;EAAW,GAC7C,MAAM,IAAAV,MAAA,CAAAC,aAAA,EAACJ,cAAA,CAAAO,OAAmB,MAAE,CACpB,CACV,CACG,CACC,CAAC;AAEX"}
@@ -9,7 +9,7 @@ var _react = require("react");
9
9
  var _blocks = require("@wordpress/blocks");
10
10
  var _data = require("@wordpress/data");
11
11
  var _components = require("@wordpress/components");
12
- var _navigationButton = require("./navigation-button");
12
+ var _navigationButton = require("../navigation-button");
13
13
  /**
14
14
  * WordPress dependencies
15
15
  */
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_blocks","require","_data","_components","_navigationButton","getCoreBlockStyles","blockStyles","filter","style","source","useBlockVariations","name","useSelect","select","getBlockStyles","blocksStore","coreBlockStyles","VariationsPanel","_react","createElement","__experimentalItemGroup","isBordered","isSeparated","map","index","isDefault","NavigationButtonAsItem","key","path","encodeURIComponent","label"],"sources":["@wordpress/edit-site/src/components/global-styles/variations/variations-panel.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { store as blocksStore } from '@wordpress/blocks';\nimport { useSelect } from '@wordpress/data';\nimport { __experimentalItemGroup as ItemGroup } from '@wordpress/components';\n/**\n * Internal dependencies\n */\n\nimport { NavigationButtonAsItem } from '../navigation-button';\n\nfunction getCoreBlockStyles( blockStyles ) {\n\treturn blockStyles?.filter( ( style ) => style.source === 'block' );\n}\n\nexport function useBlockVariations( name ) {\n\tconst blockStyles = useSelect(\n\t\t( select ) => {\n\t\t\tconst { getBlockStyles } = select( blocksStore );\n\t\t\treturn getBlockStyles( name );\n\t\t},\n\t\t[ name ]\n\t);\n\tconst coreBlockStyles = getCoreBlockStyles( blockStyles );\n\treturn coreBlockStyles;\n}\n\nexport function VariationsPanel( { name } ) {\n\tconst coreBlockStyles = useBlockVariations( name );\n\n\treturn (\n\t\t<ItemGroup isBordered isSeparated>\n\t\t\t{ coreBlockStyles.map( ( style, index ) => {\n\t\t\t\tif ( style?.isDefault ) {\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t\treturn (\n\t\t\t\t\t<NavigationButtonAsItem\n\t\t\t\t\t\tkey={ index }\n\t\t\t\t\t\tpath={\n\t\t\t\t\t\t\t'/blocks/' +\n\t\t\t\t\t\t\tencodeURIComponent( name ) +\n\t\t\t\t\t\t\t'/variations/' +\n\t\t\t\t\t\t\tencodeURIComponent( style.name )\n\t\t\t\t\t\t}\n\t\t\t\t\t\taria-label={ style.label }\n\t\t\t\t\t>\n\t\t\t\t\t\t{ style.label }\n\t\t\t\t\t</NavigationButtonAsItem>\n\t\t\t\t);\n\t\t\t} ) }\n\t\t</ItemGroup>\n\t);\n}\n"],"mappings":";;;;;;;;AAGA,IAAAA,OAAA,GAAAC,OAAA;AACA,IAAAC,KAAA,GAAAD,OAAA;AACA,IAAAE,WAAA,GAAAF,OAAA;AAKA,IAAAG,iBAAA,GAAAH,OAAA;AAVA;AACA;AACA;;AAIA;AACA;AACA;;AAIA,SAASI,kBAAkBA,CAAEC,WAAW,EAAG;EAC1C,OAAOA,WAAW,EAAEC,MAAM,CAAIC,KAAK,IAAMA,KAAK,CAACC,MAAM,KAAK,OAAQ,CAAC;AACpE;AAEO,SAASC,kBAAkBA,CAAEC,IAAI,EAAG;EAC1C,MAAML,WAAW,GAAG,IAAAM,eAAS,EAC1BC,MAAM,IAAM;IACb,MAAM;MAAEC;IAAe,CAAC,GAAGD,MAAM,CAAEE,aAAY,CAAC;IAChD,OAAOD,cAAc,CAAEH,IAAK,CAAC;EAC9B,CAAC,EACD,CAAEA,IAAI,CACP,CAAC;EACD,MAAMK,eAAe,GAAGX,kBAAkB,CAAEC,WAAY,CAAC;EACzD,OAAOU,eAAe;AACvB;AAEO,SAASC,eAAeA,CAAE;EAAEN;AAAK,CAAC,EAAG;EAC3C,MAAMK,eAAe,GAAGN,kBAAkB,CAAEC,IAAK,CAAC;EAElD,OACC,IAAAO,MAAA,CAAAC,aAAA,EAAChB,WAAA,CAAAiB,uBAAS;IAACC,UAAU;IAACC,WAAW;EAAA,GAC9BN,eAAe,CAACO,GAAG,CAAE,CAAEf,KAAK,EAAEgB,KAAK,KAAM;IAC1C,IAAKhB,KAAK,EAAEiB,SAAS,EAAG;MACvB,OAAO,IAAI;IACZ;IACA,OACC,IAAAP,MAAA,CAAAC,aAAA,EAACf,iBAAA,CAAAsB,sBAAsB;MACtBC,GAAG,EAAGH,KAAO;MACbI,IAAI,EACH,UAAU,GACVC,kBAAkB,CAAElB,IAAK,CAAC,GAC1B,cAAc,GACdkB,kBAAkB,CAAErB,KAAK,CAACG,IAAK,CAC/B;MACD,cAAaH,KAAK,CAACsB;IAAO,GAExBtB,KAAK,CAACsB,KACe,CAAC;EAE3B,CAAE,CACQ,CAAC;AAEd"}
@@ -0,0 +1,64 @@
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+ Object.defineProperty(exports, "__esModule", {
5
+ value: true
6
+ });
7
+ exports.default = TypographyVariations;
8
+ var _react = require("react");
9
+ var _element = require("@wordpress/element");
10
+ var _components = require("@wordpress/components");
11
+ var _i18n = require("@wordpress/i18n");
12
+ var _blockEditor = require("@wordpress/block-editor");
13
+ var _globalStylesProvider = require("../global-styles-provider");
14
+ var _lockUnlock = require("../../../lock-unlock");
15
+ var _useThemeStyleVariationsByProperty = require("../../../hooks/use-theme-style-variations/use-theme-style-variations-by-property");
16
+ var _previewTypography = _interopRequireDefault(require("../preview-typography"));
17
+ var _subtitle = _interopRequireDefault(require("../subtitle"));
18
+ var _utils = require("../utils");
19
+ var _variation = _interopRequireDefault(require("./variation"));
20
+ /**
21
+ * WordPress dependencies
22
+ */
23
+
24
+ /**
25
+ * Internal dependencies
26
+ */
27
+
28
+ const {
29
+ GlobalStylesContext
30
+ } = (0, _lockUnlock.unlock)(_blockEditor.privateApis);
31
+ function TypographyVariations() {
32
+ const typographyVariations = (0, _useThemeStyleVariationsByProperty.useCurrentMergeThemeStyleVariationsWithUserConfig)({
33
+ property: 'typography',
34
+ filter: variation => variation?.settings?.typography?.fontFamilies && Object.keys(variation?.settings?.typography?.fontFamilies).length
35
+ });
36
+ const {
37
+ base
38
+ } = (0, _element.useContext)(GlobalStylesContext);
39
+
40
+ /*
41
+ * Filter duplicate variations based on the font families used in the variation.
42
+ */
43
+ const uniqueTypographyVariations = typographyVariations?.length ? Object.values(typographyVariations.reduce((acc, variation) => {
44
+ const [bodyFontFamily, headingFontFamily] = (0, _utils.getFontFamilies)((0, _globalStylesProvider.mergeBaseAndUserConfigs)(base, variation));
45
+ if (headingFontFamily?.name && bodyFontFamily?.name && !acc[`${headingFontFamily?.name}:${bodyFontFamily?.name}`]) {
46
+ acc[`${headingFontFamily?.name}:${bodyFontFamily?.name}`] = variation;
47
+ }
48
+ return acc;
49
+ }, {})) : [];
50
+ return (0, _react.createElement)(_components.__experimentalVStack, {
51
+ spacing: 3
52
+ }, (0, _react.createElement)(_subtitle.default, {
53
+ level: 3
54
+ }, (0, _i18n.__)('Presets')), (0, _react.createElement)(_components.__experimentalGrid, {
55
+ columns: 3,
56
+ className: "edit-site-global-styles-style-variations-container"
57
+ }, typographyVariations && typographyVariations.length ? uniqueTypographyVariations.map((variation, index) => (0, _react.createElement)(_variation.default, {
58
+ key: index,
59
+ variation: variation
60
+ }, () => (0, _react.createElement)(_previewTypography.default, {
61
+ variation: variation
62
+ }))) : null));
63
+ }
64
+ //# sourceMappingURL=variations-typography.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_element","require","_components","_i18n","_blockEditor","_globalStylesProvider","_lockUnlock","_useThemeStyleVariationsByProperty","_previewTypography","_interopRequireDefault","_subtitle","_utils","_variation","GlobalStylesContext","unlock","blockEditorPrivateApis","TypographyVariations","typographyVariations","useCurrentMergeThemeStyleVariationsWithUserConfig","property","filter","variation","settings","typography","fontFamilies","Object","keys","length","base","useContext","uniqueTypographyVariations","values","reduce","acc","bodyFontFamily","headingFontFamily","getFontFamilies","mergeBaseAndUserConfigs","name","_react","createElement","__experimentalVStack","spacing","default","level","__","__experimentalGrid","columns","className","map","index","key"],"sources":["@wordpress/edit-site/src/components/global-styles/variations/variations-typography.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { useContext } from '@wordpress/element';\nimport {\n\t__experimentalGrid as Grid,\n\t__experimentalVStack as VStack,\n} from '@wordpress/components';\nimport { __ } from '@wordpress/i18n';\nimport { privateApis as blockEditorPrivateApis } from '@wordpress/block-editor';\n\n/**\n * Internal dependencies\n */\nimport { mergeBaseAndUserConfigs } from '../global-styles-provider';\nimport { unlock } from '../../../lock-unlock';\nimport { useCurrentMergeThemeStyleVariationsWithUserConfig } from '../../../hooks/use-theme-style-variations/use-theme-style-variations-by-property';\nimport PreviewTypography from '../preview-typography';\nimport Subtitle from '../subtitle';\nimport { getFontFamilies } from '../utils';\nimport Variation from './variation';\n\nconst { GlobalStylesContext } = unlock( blockEditorPrivateApis );\n\nexport default function TypographyVariations() {\n\tconst typographyVariations =\n\t\tuseCurrentMergeThemeStyleVariationsWithUserConfig( {\n\t\t\tproperty: 'typography',\n\t\t\tfilter: ( variation ) =>\n\t\t\t\tvariation?.settings?.typography?.fontFamilies &&\n\t\t\t\tObject.keys( variation?.settings?.typography?.fontFamilies )\n\t\t\t\t\t.length,\n\t\t} );\n\n\tconst { base } = useContext( GlobalStylesContext );\n\n\t/*\n\t * Filter duplicate variations based on the font families used in the variation.\n\t */\n\tconst uniqueTypographyVariations = typographyVariations?.length\n\t\t? Object.values(\n\t\t\t\ttypographyVariations.reduce( ( acc, variation ) => {\n\t\t\t\t\tconst [ bodyFontFamily, headingFontFamily ] =\n\t\t\t\t\t\tgetFontFamilies(\n\t\t\t\t\t\t\tmergeBaseAndUserConfigs( base, variation )\n\t\t\t\t\t\t);\n\t\t\t\t\tif (\n\t\t\t\t\t\theadingFontFamily?.name &&\n\t\t\t\t\t\tbodyFontFamily?.name &&\n\t\t\t\t\t\t! acc[\n\t\t\t\t\t\t\t`${ headingFontFamily?.name }:${ bodyFontFamily?.name }`\n\t\t\t\t\t\t]\n\t\t\t\t\t) {\n\t\t\t\t\t\tacc[\n\t\t\t\t\t\t\t`${ headingFontFamily?.name }:${ bodyFontFamily?.name }`\n\t\t\t\t\t\t] = variation;\n\t\t\t\t\t}\n\n\t\t\t\t\treturn acc;\n\t\t\t\t}, {} )\n\t\t )\n\t\t: [];\n\n\treturn (\n\t\t<VStack spacing={ 3 }>\n\t\t\t<Subtitle level={ 3 }>{ __( 'Presets' ) }</Subtitle>\n\t\t\t<Grid\n\t\t\t\tcolumns={ 3 }\n\t\t\t\tclassName=\"edit-site-global-styles-style-variations-container\"\n\t\t\t>\n\t\t\t\t{ typographyVariations && typographyVariations.length\n\t\t\t\t\t? uniqueTypographyVariations.map( ( variation, index ) => (\n\t\t\t\t\t\t\t<Variation key={ index } variation={ variation }>\n\t\t\t\t\t\t\t\t{ () => (\n\t\t\t\t\t\t\t\t\t<PreviewTypography\n\t\t\t\t\t\t\t\t\t\tvariation={ variation }\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t</Variation>\n\t\t\t\t\t ) )\n\t\t\t\t\t: null }\n\t\t\t</Grid>\n\t\t</VStack>\n\t);\n}\n"],"mappings":";;;;;;;;AAGA,IAAAA,QAAA,GAAAC,OAAA;AACA,IAAAC,WAAA,GAAAD,OAAA;AAIA,IAAAE,KAAA,GAAAF,OAAA;AACA,IAAAG,YAAA,GAAAH,OAAA;AAK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AEG,IAAM,IAAIJ,cAAc,EAAEI,IAAM,EAAC,CACxD,GAAGjB,SAAS;IACd;IAEA,OAAOY,GAAG;EACX,CAAC,EAAE,CAAC,CAAE,CACN,CAAC,GACD,EAAE;EAEL,OACC,IAAAM,MAAA,CAAAC,aAAA,EAACtC,WAAA,CAAAuC,oBAAM;IAACC,OAAO,EAAG;EAAG,GACpB,IAAAH,MAAA,CAAAC,aAAA,EAAC9B,SAAA,CAAAiC,OAAQ;IAACC,KAAK,EAAG;EAAG,GAAG,IAAAC,QAAE,EAAE,SAAU,CAAa,CAAC,EACpD,IAAAN,MAAA,CAAAC,aAAA,EAACtC,WAAA,CAAA4C,kBAAI;IACJC,OAAO,EAAG,CAAG;IACbC,SAAS,EAAC;EAAoD,GAE5D/B,oBAAoB,IAAIA,oBAAoB,CAACU,MAAM,GAClDG,0BAA0B,CAACmB,GAAG,CAAE,CAAE5B,SAAS,EAAE6B,KAAK,KAClD,IAAAX,MAAA,CAAAC,aAAA,EAAC5B,UAAA,CAAA+B,OAAS;IAACQ,GAAG,EAAGD,KAAO;IAAC7B,SAAS,EAAGA;EAAW,GAC7C,MACD,IAAAkB,MAAA,CAAAC,aAAA,EAAChC,kBAAA,CAAAmC,OAAiB;IACjBtB,SAAS,EAAGA;EAAW,CACvB,CAEQ,CACT,CAAC,GACH,IACE,CACC,CAAC;AAEX"}
@@ -36,6 +36,9 @@ var _constants = require("../../utils/constants");
36
36
  * Internal dependencies
37
37
  */
38
38
 
39
+ const {
40
+ useShowBlockTools
41
+ } = (0, _lockUnlock.unlock)(_blockEditor.privateApis);
39
42
  const {
40
43
  PostViewLink,
41
44
  PreviewDropdown
@@ -47,9 +50,7 @@ function HeaderEditMode() {
47
50
  blockEditorMode,
48
51
  blockSelectionStart,
49
52
  showIconLabels,
50
- editorCanvasView,
51
- hasFixedToolbar,
52
- isZoomOutMode
53
+ editorCanvasView
53
54
  } = (0, _data.useSelect)(select => {
54
55
  const {
55
56
  getEditedPostType
@@ -71,20 +72,20 @@ function HeaderEditMode() {
71
72
  blockSelectionStart: getBlockSelectionStart(),
72
73
  showIconLabels: getPreference('core', 'showIconLabels'),
73
74
  editorCanvasView: (0, _lockUnlock.unlock)(select(_store.store)).getEditorCanvasContainerView(),
74
- hasFixedToolbar: getPreference('core', 'fixedToolbar'),
75
- isDistractionFree: getPreference('core', 'distractionFree'),
76
- isZoomOutMode: __unstableGetEditorMode() === 'zoom-out'
75
+ isDistractionFree: getPreference('core', 'distractionFree')
77
76
  };
78
77
  }, []);
79
78
  const isLargeViewport = (0, _compose.useViewportMatch)('medium');
80
- const isTopToolbar = !isZoomOutMode && hasFixedToolbar && isLargeViewport;
79
+ const {
80
+ showFixedToolbar
81
+ } = useShowBlockTools();
82
+ const showTopToolbar = isLargeViewport && showFixedToolbar;
81
83
  const blockToolbarRef = (0, _element.useRef)();
82
84
  const disableMotion = (0, _compose.useReducedMotion)();
83
85
  const hasDefaultEditorCanvasView = !(0, _editorCanvasContainer.useHasEditorCanvasContainer)();
84
86
  const isFocusMode = _constants.FOCUSABLE_ENTITIES.includes(templateType);
85
87
  const isZoomedOutView = blockEditorMode === 'zoom-out';
86
88
  const [isBlockToolsCollapsed, setIsBlockToolsCollapsed] = (0, _element.useState)(true);
87
- const hasBlockSelected = !!blockSelectionStart;
88
89
  (0, _element.useEffect)(() => {
89
90
  // If we have a new block selection, show the block tools
90
91
  if (blockSelectionStart) {
@@ -121,7 +122,7 @@ function HeaderEditMode() {
121
122
  }, (0, _react.createElement)(_documentTools.default, {
122
123
  blockEditorMode: blockEditorMode,
123
124
  isDistractionFree: isDistractionFree
124
- }), isTopToolbar && (0, _react.createElement)(_react.Fragment, null, (0, _react.createElement)("div", {
125
+ }), showTopToolbar && (0, _react.createElement)(_react.Fragment, null, (0, _react.createElement)("div", {
125
126
  className: (0, _classnames.default)('selected-block-tools-wrapper', {
126
127
  'is-collapsed': isBlockToolsCollapsed
127
128
  })
@@ -130,7 +131,7 @@ function HeaderEditMode() {
130
131
  })), (0, _react.createElement)(_components.Popover.Slot, {
131
132
  ref: blockToolbarRef,
132
133
  name: "block-toolbar"
133
- }), hasBlockSelected && (0, _react.createElement)(_components.Button, {
134
+ }), (0, _react.createElement)(_components.Button, {
134
135
  className: "edit-site-header-edit-mode__block-tools-toggle",
135
136
  icon: isBlockToolsCollapsed ? _icons.next : _icons.previous,
136
137
  onClick: () => {
@@ -139,7 +140,7 @@ function HeaderEditMode() {
139
140
  label: isBlockToolsCollapsed ? (0, _i18n.__)('Show block tools') : (0, _i18n.__)('Hide block tools')
140
141
  }))), !isDistractionFree && (0, _react.createElement)("div", {
141
142
  className: (0, _classnames.default)('edit-site-header-edit-mode__center', {
142
- 'is-collapsed': !isBlockToolsCollapsed && isLargeViewport
143
+ 'is-collapsed': !isBlockToolsCollapsed && showTopToolbar
143
144
  })
144
145
  }, !hasDefaultEditorCanvasView ? (0, _editorCanvasContainer.getEditorCanvasContainerTitle)(editorCanvasView) : (0, _react.createElement)(_editor.DocumentBar, null)), (0, _react.createElement)("div", {
145
146
  className: "edit-site-header-edit-mode__end"
@@ -1 +1 @@
1
- {"version":3,"names":["_classnames","_interopRequireDefault","require","_compose","_blockEditor","_data","_element","_interface","_i18n","_icons","_components","_preferences","_editor","_moreMenu","_saveButton","_documentTools","_store","_editorCanvasContainer","_lockUnlock","_constants","PostViewLink","PreviewDropdown","unlock","editorPrivateApis","HeaderEditMode","templateType","isDistractionFree","blockEditorMode","blockSelectionStart","showIconLabels","editorCanvasView","hasFixedToolbar","isZoomOutMode","useSelect","select","getEditedPostType","editSiteStore","getBlockSelectionStart","__unstableGetEditorMode","blockEditorStore","get","getPreference","preferencesStore","getDeviceType","editorStore","deviceType","getEditorCanvasContainerView","isLargeViewport","useViewportMatch","isTopToolbar","blockToolbarRef","useRef","disableMotion","useReducedMotion","hasDefaultEditorCanvasView","useHasEditorCanvasContainer","isFocusMode","FOCUSABLE_ENTITIES","includes","isZoomedOutView","isBlockToolsCollapsed","setIsBlockToolsCollapsed","useState","hasBlockSelected","useEffect","toolbarVariants","y","isDistractionFreeHovering","view","edit","toolbarTransition","type","duration","ease","_react","createElement","className","classnames","__unstableMotion","div","variants","transition","default","Fragment","BlockToolbar","hideDragHandle","Popover","Slot","ref","name","Button","icon","next","previous","onClick","collapsed","label","__","getEditorCanvasContainerTitle","DocumentBar","disabled","size","PinnedItems","scope"],"sources":["@wordpress/edit-site/src/components/header-edit-mode/index.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport classnames from 'classnames';\n\n/**\n * WordPress dependencies\n */\nimport { useViewportMatch, useReducedMotion } from '@wordpress/compose';\nimport {\n\tBlockToolbar,\n\tstore as blockEditorStore,\n} from '@wordpress/block-editor';\nimport { useSelect } from '@wordpress/data';\nimport { useEffect, useRef, useState } from '@wordpress/element';\nimport { PinnedItems } from '@wordpress/interface';\nimport { __ } from '@wordpress/i18n';\nimport { next, previous } from '@wordpress/icons';\nimport {\n\tButton,\n\t__unstableMotion as motion,\n\tPopover,\n} from '@wordpress/components';\nimport { store as preferencesStore } from '@wordpress/preferences';\nimport {\n\tDocumentBar,\n\tstore as editorStore,\n\tprivateApis as editorPrivateApis,\n} from '@wordpress/editor';\n\n/**\n * Internal dependencies\n */\nimport MoreMenu from './more-menu';\nimport SaveButton from '../save-button';\nimport DocumentTools from './document-tools';\nimport { store as editSiteStore } from '../../store';\nimport {\n\tgetEditorCanvasContainerTitle,\n\tuseHasEditorCanvasContainer,\n} from '../editor-canvas-container';\nimport { unlock } from '../../lock-unlock';\nimport { FOCUSABLE_ENTITIES } from '../../utils/constants';\n\nconst { PostViewLink, PreviewDropdown } = unlock( editorPrivateApis );\n\nexport default function HeaderEditMode() {\n\tconst {\n\t\ttemplateType,\n\t\tisDistractionFree,\n\t\tblockEditorMode,\n\t\tblockSelectionStart,\n\t\tshowIconLabels,\n\t\teditorCanvasView,\n\t\thasFixedToolbar,\n\t\tisZoomOutMode,\n\t} = useSelect( ( select ) => {\n\t\tconst { getEditedPostType } = select( editSiteStore );\n\t\tconst { getBlockSelectionStart, __unstableGetEditorMode } =\n\t\t\tselect( blockEditorStore );\n\t\tconst { get: getPreference } = select( preferencesStore );\n\t\tconst { getDeviceType } = select( editorStore );\n\n\t\treturn {\n\t\t\tdeviceType: getDeviceType(),\n\t\t\ttemplateType: getEditedPostType(),\n\t\t\tblockEditorMode: __unstableGetEditorMode(),\n\t\t\tblockSelectionStart: getBlockSelectionStart(),\n\t\t\tshowIconLabels: getPreference( 'core', 'showIconLabels' ),\n\t\t\teditorCanvasView: unlock(\n\t\t\t\tselect( editSiteStore )\n\t\t\t).getEditorCanvasContainerView(),\n\t\t\thasFixedToolbar: getPreference( 'core', 'fixedToolbar' ),\n\t\t\tisDistractionFree: getPreference( 'core', 'distractionFree' ),\n\t\t\tisZoomOutMode: __unstableGetEditorMode() === 'zoom-out',\n\t\t};\n\t}, [] );\n\n\tconst isLargeViewport = useViewportMatch( 'medium' );\n\tconst isTopToolbar = ! isZoomOutMode && hasFixedToolbar && isLargeViewport;\n\tconst blockToolbarRef = useRef();\n\tconst disableMotion = useReducedMotion();\n\n\tconst hasDefaultEditorCanvasView = ! useHasEditorCanvasContainer();\n\n\tconst isFocusMode = FOCUSABLE_ENTITIES.includes( templateType );\n\n\tconst isZoomedOutView = blockEditorMode === 'zoom-out';\n\n\tconst [ isBlockToolsCollapsed, setIsBlockToolsCollapsed ] =\n\t\tuseState( true );\n\n\tconst hasBlockSelected = !! blockSelectionStart;\n\n\tuseEffect( () => {\n\t\t// If we have a new block selection, show the block tools\n\t\tif ( blockSelectionStart ) {\n\t\t\tsetIsBlockToolsCollapsed( false );\n\t\t}\n\t}, [ blockSelectionStart ] );\n\n\tconst toolbarVariants = {\n\t\tisDistractionFree: { y: '-50px' },\n\t\tisDistractionFreeHovering: { y: 0 },\n\t\tview: { y: 0 },\n\t\tedit: { y: 0 },\n\t};\n\n\tconst toolbarTransition = {\n\t\ttype: 'tween',\n\t\tduration: disableMotion ? 0 : 0.2,\n\t\tease: 'easeOut',\n\t};\n\n\treturn (\n\t\t<div\n\t\t\tclassName={ classnames( 'edit-site-header-edit-mode', {\n\t\t\t\t'show-icon-labels': showIconLabels,\n\t\t\t} ) }\n\t\t>\n\t\t\t{ hasDefaultEditorCanvasView && (\n\t\t\t\t<motion.div\n\t\t\t\t\tclassName=\"edit-site-header-edit-mode__start\"\n\t\t\t\t\tvariants={ toolbarVariants }\n\t\t\t\t\ttransition={ toolbarTransition }\n\t\t\t\t>\n\t\t\t\t\t<DocumentTools\n\t\t\t\t\t\tblockEditorMode={ blockEditorMode }\n\t\t\t\t\t\tisDistractionFree={ isDistractionFree }\n\t\t\t\t\t/>\n\t\t\t\t\t{ isTopToolbar && (\n\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t<div\n\t\t\t\t\t\t\t\tclassName={ classnames(\n\t\t\t\t\t\t\t\t\t'selected-block-tools-wrapper',\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t'is-collapsed': isBlockToolsCollapsed,\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t<BlockToolbar hideDragHandle />\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<Popover.Slot\n\t\t\t\t\t\t\t\tref={ blockToolbarRef }\n\t\t\t\t\t\t\t\tname=\"block-toolbar\"\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t{ hasBlockSelected && (\n\t\t\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\t\t\tclassName=\"edit-site-header-edit-mode__block-tools-toggle\"\n\t\t\t\t\t\t\t\t\ticon={\n\t\t\t\t\t\t\t\t\t\tisBlockToolsCollapsed ? next : previous\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tonClick={ () => {\n\t\t\t\t\t\t\t\t\t\tsetIsBlockToolsCollapsed(\n\t\t\t\t\t\t\t\t\t\t\t( collapsed ) => ! collapsed\n\t\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t\t\t\tlabel={\n\t\t\t\t\t\t\t\t\t\tisBlockToolsCollapsed\n\t\t\t\t\t\t\t\t\t\t\t? __( 'Show block tools' )\n\t\t\t\t\t\t\t\t\t\t\t: __( 'Hide block tools' )\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t</>\n\t\t\t\t\t) }\n\t\t\t\t</motion.div>\n\t\t\t) }\n\n\t\t\t{ ! isDistractionFree && (\n\t\t\t\t<div\n\t\t\t\t\tclassName={ classnames(\n\t\t\t\t\t\t'edit-site-header-edit-mode__center',\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t'is-collapsed':\n\t\t\t\t\t\t\t\t! isBlockToolsCollapsed && isLargeViewport,\n\t\t\t\t\t\t}\n\t\t\t\t\t) }\n\t\t\t\t>\n\t\t\t\t\t{ ! hasDefaultEditorCanvasView ? (\n\t\t\t\t\t\tgetEditorCanvasContainerTitle( editorCanvasView )\n\t\t\t\t\t) : (\n\t\t\t\t\t\t<DocumentBar />\n\t\t\t\t\t) }\n\t\t\t\t</div>\n\t\t\t) }\n\n\t\t\t<div className=\"edit-site-header-edit-mode__end\">\n\t\t\t\t<motion.div\n\t\t\t\t\tclassName=\"edit-site-header-edit-mode__actions\"\n\t\t\t\t\tvariants={ toolbarVariants }\n\t\t\t\t\ttransition={ toolbarTransition }\n\t\t\t\t>\n\t\t\t\t\t{ isLargeViewport && (\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tclassName={ classnames(\n\t\t\t\t\t\t\t\t'edit-site-header-edit-mode__preview-options',\n\t\t\t\t\t\t\t\t{ 'is-zoomed-out': isZoomedOutView }\n\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<PreviewDropdown\n\t\t\t\t\t\t\t\tdisabled={\n\t\t\t\t\t\t\t\t\tisFocusMode || ! hasDefaultEditorCanvasView\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t) }\n\t\t\t\t\t<PostViewLink />\n\t\t\t\t\t<SaveButton size=\"compact\" />\n\t\t\t\t\t{ ! isDistractionFree && (\n\t\t\t\t\t\t<PinnedItems.Slot scope=\"core/edit-site\" />\n\t\t\t\t\t) }\n\t\t\t\t\t<MoreMenu showIconLabels={ showIconLabels } />\n\t\t\t\t</motion.div>\n\t\t\t</div>\n\t\t</div>\n\t);\n}\n"],"mappings":";;;;;;;;AAGA,IAAAA,WAAA,GAAAC,sBAAA,CAAAC,OAAA;AAKA,IAAAC,QAAA,GAAAD,OAAA;AACA,IAAAE,YAAA,GAAAF,OAAA;AAIA,IAAAG,KAAA,GAAAH,OAAA;AACA,IAAAI,QAAA,GAAAJ,OAAA;AACA,IAAAK,UAAA,GAAAL,OAAA;AACA,IAAAM,KAAA,GAAAN,OAAA;AACA,IAAAO,MAAA,GAAAP,OAAA;AACA,IAAAQ,WAAA,GAAAR,OAAA;AAKA,IAAAS,YAAA,GAAAT,OAAA;AACA,IAAAU,OAAA,GAAAV,OAAA;AASA,IAAAW,SAAA,GAAAZ,sBAAA,CAAAC,OAAA;AACA,IAAAY,WAAA,GAAAb,sBAAA,CAAAC,OAAA;AACA,IAAAa,cAAA,GAAAd,sBAAA,CAAAC,OAAA;AACA,IAAAc,MAAA,GAAAd,OAAA;AACA,IAAAe,sBAAA,GAAAf,OAAA;AAIA,IAAAgB,WAAA,GAAAhB,OAAA;AACA,IAAAiB,UAAA,GAAAjB,OAAA;AA1CA;AACA;AACA;;AAGA;AACA;AACA;;AAuBA;AACA;AACA;;AAYA,MAAM;EAAEkB,YAAY;EAAEC;AAAgB,CAAC,GAAG,IAAAC,kBAAM,EAAEC,mBAAkB,CAAC;AAEtD,SAASC,cAAcA,CAAA,EAAG;EACxC,MAAM;IACLC,YAAY;IACZC,iBAAiB;IACjBC,eAAe;IACfC,mBAA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ACjE,WAAA,CAAAoE,gBAAM,CAACC,GAAG;IACVH,SAAS,EAAC,qCAAqC;IAC/CI,QAAQ,EAAGf,eAAiB;IAC5BgB,UAAU,EAAGX;EAAmB,GAE9BvB,eAAe,IAChB,IAAA2B,MAAA,CAAAC,aAAA;IACCC,SAAS,EAAG,IAAAC,mBAAU,EACrB,6CAA6C,EAC7C;MAAE,eAAe,EAAElB;IAAgB,CACpC;EAAG,GAEH,IAAAe,MAAA,CAAAC,aAAA,EAACtD,eAAe;IACf+E,QAAQ,EACP5C,WAAW,IAAI,CAAEF;EACjB,CACD,CACG,CACL,EACD,IAAAoB,MAAA,CAAAC,aAAA,EAACvD,YAAY,MAAE,CAAC,EAChB,IAAAsD,MAAA,CAAAC,aAAA,EAAC7D,WAAA,CAAAoE,OAAU;IAACmB,IAAI,EAAC;EAAS,CAAE,CAAC,EAC3B,CAAE3E,iBAAiB,IACpB,IAAAgD,MAAA,CAAAC,aAAA,EAACpE,UAAA,CAAA+F,WAAW,CAACf,IAAI;IAACgB,KAAK,EAAC;EAAgB,CAAE,CAC1C,EACD,IAAA7B,MAAA,CAAAC,aAAA,EAAC9D,SAAA,CAAAqE,OAAQ;IAACrD,cAAc,EAAGA;EAAgB,CAAE,CAClC,CACR,CACD,CAAC;AAER"}
1
+ {"version":3,"names":["_classnames","_interopRequireDefault","require","_compose","_blockEditor","_data","_element","_interface","_i18n","_icons","_components","_preferences","_editor","_moreMenu","_saveButton","_documentTools","_store","_editorCanvasContainer","_lockUnlock","_constants","useShowBlockTools","unlock","blockEditorPrivateApis","PostViewLink","PreviewDropdown","editorPrivateApis","HeaderEditMode","templateType","isDistractionFree","blockEditorMode","blockSelectionStart","showIconLabels","editorCanvasView","useSelect","select","getEditedPostType","editSiteStore","getBlockSelectionStart","__unstableGetEditorMode","blockEditorStore","get","getPreference","preferencesStore","getDeviceType","editorStore","deviceType","getEditorCanvasContainerView","isLargeViewport","useViewportMatch","showFixedToolbar","showTopToolbar","blockToolbarRef","useRef","disableMotion","useReducedMotion","hasDefaultEditorCanvasView","useHasEditorCanvasContainer","isFocusMode","FOCUSABLE_ENTITIES","includes","isZoomedOutView","isBlockToolsCollapsed","setIsBlockToolsCollapsed","useState","useEffect","toolbarVariants","y","isDistractionFreeHovering","view","edit","toolbarTransition","type","duration","ease","_react","createElement","className","classnames","__unstableMotion","div","variants","transition","default","Fragment","BlockToolbar","hideDragHandle","Popover","Slot","ref","name","Button","icon","next","previous","onClick","collapsed","label","__","getEditorCanvasContainerTitle","DocumentBar","disabled","size","PinnedItems","scope"],"sources":["@wordpress/edit-site/src/components/header-edit-mode/index.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport classnames from 'classnames';\n\n/**\n * WordPress dependencies\n */\nimport { useViewportMatch, useReducedMotion } from '@wordpress/compose';\nimport {\n\tBlockToolbar,\n\tprivateApis as blockEditorPrivateApis,\n\tstore as blockEditorStore,\n} from '@wordpress/block-editor';\nimport { useSelect } from '@wordpress/data';\nimport { useEffect, useRef, useState } from '@wordpress/element';\nimport { PinnedItems } from '@wordpress/interface';\nimport { __ } from '@wordpress/i18n';\nimport { next, previous } from '@wordpress/icons';\nimport {\n\tButton,\n\t__unstableMotion as motion,\n\tPopover,\n} from '@wordpress/components';\nimport { store as preferencesStore } from '@wordpress/preferences';\nimport {\n\tDocumentBar,\n\tstore as editorStore,\n\tprivateApis as editorPrivateApis,\n} from '@wordpress/editor';\n\n/**\n * Internal dependencies\n */\nimport MoreMenu from './more-menu';\nimport SaveButton from '../save-button';\nimport DocumentTools from './document-tools';\nimport { store as editSiteStore } from '../../store';\nimport {\n\tgetEditorCanvasContainerTitle,\n\tuseHasEditorCanvasContainer,\n} from '../editor-canvas-container';\nimport { unlock } from '../../lock-unlock';\nimport { FOCUSABLE_ENTITIES } from '../../utils/constants';\n\nconst { useShowBlockTools } = unlock( blockEditorPrivateApis );\nconst { PostViewLink, PreviewDropdown } = unlock( editorPrivateApis );\n\nexport default function HeaderEditMode() {\n\tconst {\n\t\ttemplateType,\n\t\tisDistractionFree,\n\t\tblockEditorMode,\n\t\tblockSelectionStart,\n\t\tshowIconLabels,\n\t\teditorCanvasView,\n\t} = useSelect( ( select ) => {\n\t\tconst { getEditedPostType } = select( editSiteStore );\n\t\tconst { getBlockSelectionStart, __unstableGetEditorMode } =\n\t\t\tselect( blockEditorStore );\n\t\tconst { get: getPreference } = select( preferencesStore );\n\t\tconst { getDeviceType } = select( editorStore );\n\n\t\treturn {\n\t\t\tdeviceType: getDeviceType(),\n\t\t\ttemplateType: getEditedPostType(),\n\t\t\tblockEditorMode: __unstableGetEditorMode(),\n\t\t\tblockSelectionStart: getBlockSelectionStart(),\n\t\t\tshowIconLabels: getPreference( 'core', 'showIconLabels' ),\n\t\t\teditorCanvasView: unlock(\n\t\t\t\tselect( editSiteStore )\n\t\t\t).getEditorCanvasContainerView(),\n\t\t\tisDistractionFree: getPreference( 'core', 'distractionFree' ),\n\t\t};\n\t}, [] );\n\n\tconst isLargeViewport = useViewportMatch( 'medium' );\n\tconst { showFixedToolbar } = useShowBlockTools();\n\tconst showTopToolbar = isLargeViewport && showFixedToolbar;\n\tconst blockToolbarRef = useRef();\n\tconst disableMotion = useReducedMotion();\n\n\tconst hasDefaultEditorCanvasView = ! useHasEditorCanvasContainer();\n\n\tconst isFocusMode = FOCUSABLE_ENTITIES.includes( templateType );\n\n\tconst isZoomedOutView = blockEditorMode === 'zoom-out';\n\n\tconst [ isBlockToolsCollapsed, setIsBlockToolsCollapsed ] =\n\t\tuseState( true );\n\n\tuseEffect( () => {\n\t\t// If we have a new block selection, show the block tools\n\t\tif ( blockSelectionStart ) {\n\t\t\tsetIsBlockToolsCollapsed( false );\n\t\t}\n\t}, [ blockSelectionStart ] );\n\n\tconst toolbarVariants = {\n\t\tisDistractionFree: { y: '-50px' },\n\t\tisDistractionFreeHovering: { y: 0 },\n\t\tview: { y: 0 },\n\t\tedit: { y: 0 },\n\t};\n\n\tconst toolbarTransition = {\n\t\ttype: 'tween',\n\t\tduration: disableMotion ? 0 : 0.2,\n\t\tease: 'easeOut',\n\t};\n\n\treturn (\n\t\t<div\n\t\t\tclassName={ classnames( 'edit-site-header-edit-mode', {\n\t\t\t\t'show-icon-labels': showIconLabels,\n\t\t\t} ) }\n\t\t>\n\t\t\t{ hasDefaultEditorCanvasView && (\n\t\t\t\t<motion.div\n\t\t\t\t\tclassName=\"edit-site-header-edit-mode__start\"\n\t\t\t\t\tvariants={ toolbarVariants }\n\t\t\t\t\ttransition={ toolbarTransition }\n\t\t\t\t>\n\t\t\t\t\t<DocumentTools\n\t\t\t\t\t\tblockEditorMode={ blockEditorMode }\n\t\t\t\t\t\tisDistractionFree={ isDistractionFree }\n\t\t\t\t\t/>\n\t\t\t\t\t{ showTopToolbar && (\n\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t<div\n\t\t\t\t\t\t\t\tclassName={ classnames(\n\t\t\t\t\t\t\t\t\t'selected-block-tools-wrapper',\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t'is-collapsed': isBlockToolsCollapsed,\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t<BlockToolbar hideDragHandle />\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t<Popover.Slot\n\t\t\t\t\t\t\t\tref={ blockToolbarRef }\n\t\t\t\t\t\t\t\tname=\"block-toolbar\"\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\t\tclassName=\"edit-site-header-edit-mode__block-tools-toggle\"\n\t\t\t\t\t\t\t\ticon={ isBlockToolsCollapsed ? next : previous }\n\t\t\t\t\t\t\t\tonClick={ () => {\n\t\t\t\t\t\t\t\t\tsetIsBlockToolsCollapsed(\n\t\t\t\t\t\t\t\t\t\t( collapsed ) => ! collapsed\n\t\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t\t\tlabel={\n\t\t\t\t\t\t\t\t\tisBlockToolsCollapsed\n\t\t\t\t\t\t\t\t\t\t? __( 'Show block tools' )\n\t\t\t\t\t\t\t\t\t\t: __( 'Hide block tools' )\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</>\n\t\t\t\t\t) }\n\t\t\t\t</motion.div>\n\t\t\t) }\n\n\t\t\t{ ! isDistractionFree && (\n\t\t\t\t<div\n\t\t\t\t\tclassName={ classnames(\n\t\t\t\t\t\t'edit-site-header-edit-mode__center',\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t'is-collapsed':\n\t\t\t\t\t\t\t\t! isBlockToolsCollapsed && showTopToolbar,\n\t\t\t\t\t\t}\n\t\t\t\t\t) }\n\t\t\t\t>\n\t\t\t\t\t{ ! hasDefaultEditorCanvasView ? (\n\t\t\t\t\t\tgetEditorCanvasContainerTitle( editorCanvasView )\n\t\t\t\t\t) : (\n\t\t\t\t\t\t<DocumentBar />\n\t\t\t\t\t) }\n\t\t\t\t</div>\n\t\t\t) }\n\n\t\t\t<div className=\"edit-site-header-edit-mode__end\">\n\t\t\t\t<motion.div\n\t\t\t\t\tclassName=\"edit-site-header-edit-mode__actions\"\n\t\t\t\t\tvariants={ toolbarVariants }\n\t\t\t\t\ttransition={ toolbarTransition }\n\t\t\t\t>\n\t\t\t\t\t{ isLargeViewport && (\n\t\t\t\t\t\t<div\n\t\t\t\t\t\t\tclassName={ classnames(\n\t\t\t\t\t\t\t\t'edit-site-header-edit-mode__preview-options',\n\t\t\t\t\t\t\t\t{ 'is-zoomed-out': isZoomedOutView }\n\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<PreviewDropdown\n\t\t\t\t\t\t\t\tdisabled={\n\t\t\t\t\t\t\t\t\tisFocusMode || ! hasDefaultEditorCanvasView\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t) }\n\t\t\t\t\t<PostViewLink />\n\t\t\t\t\t<SaveButton size=\"compact\" />\n\t\t\t\t\t{ ! isDistractionFree && (\n\t\t\t\t\t\t<PinnedItems.Slot scope=\"core/edit-site\" />\n\t\t\t\t\t) }\n\t\t\t\t\t<MoreMenu showIconLabels={ showIconLabels } />\n\t\t\t\t</motion.div>\n\t\t\t</div>\n\t\t</div>\n\t);\n}\n"],"mappings":";;;;;;;;AAGA,IAAAA,WAAA,GAAAC,sBAAA,CAAAC,OAAA;AAKA,IAAAC,QAAA,GAAAD,OAAA;AACA,IAAAE,YAAA,GAAAF,OAAA;AAKA,IAAAG,KAAA,GAAAH,OAAA;AACA,IAAAI,QAAA,GAAAJ,OAAA;AACA,IAAAK,UAAA,GAAAL,OAAA;AACA,IAAAM,KAAA,GAAAN,OAAA;AACA,IAAAO,MAAA,GAAAP,OAAA;AACA,IAAAQ,WAAA,GAAAR,OAAA;AAKA,IAAAS,YAAA,GAAAT,OAAA;AACA,IAAAU,OAAA,GAAAV,OAAA;AASA,IAAAW,SAAA,GAAAZ,sBAAA,CAAAC,OAAA;AACA,IAAAY,WAAA,GAAAb,sBAAA,CAAAC,OAAA;AACA,IAAAa,cAAA,GAAAd,sBAAA,CAAAC,OAAA;AACA,IAAAc,MAAA,GAAAd,OAAA;AACA,IAAAe,sBAAA,GAAAf,OAAA;AAIA,IAAAgB,WAAA,GAAAhB,OAAA;AACA,IAAAiB,UAAA,GAAAjB,OAAA;AA3CA;AACA;AACA;;AAGA;AACA;AACA;;AAwBA;AACA;AACA;;AAYA,MAAM;EAAEkB;AAAkB,CAAC,GAAG,IAAAC,kBAAM,EAAEC,wBAAuB,CAAC;AAC9D,MAAM;EAAEC,YAAY;EAAEC;AAAgB,CAAC,GAAG,IAAAH,kBAAM,EAAEI,mBAAkB,CAAC;AAEtD,SAASC,cAAcA,CAAA,EAAG;EACxC,MAAM;IACLC,YAAY;IACZC,iBAAiB;IACjBC,eAAe;IACfC,mBAAmB;IACnBC,cAAc;IACdC;E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AG,IAAAC,mBAAU,EACrB,6CAA6C,EAC7C;MAAE,eAAe,EAAEjB;IAAgB,CACpC;EAAG,GAEH,IAAAc,MAAA,CAAAC,aAAA,EAACnD,eAAe;IACf4E,QAAQ,EACP3C,WAAW,IAAI,CAAEF;EACjB,CACD,CACG,CACL,EACD,IAAAmB,MAAA,CAAAC,aAAA,EAACpD,YAAY,MAAE,CAAC,EAChB,IAAAmD,MAAA,CAAAC,aAAA,EAAC7D,WAAA,CAAAoE,OAAU;IAACmB,IAAI,EAAC;EAAS,CAAE,CAAC,EAC3B,CAAEzE,iBAAiB,IACpB,IAAA8C,MAAA,CAAAC,aAAA,EAACpE,UAAA,CAAA+F,WAAW,CAACf,IAAI;IAACgB,KAAK,EAAC;EAAgB,CAAE,CAC1C,EACD,IAAA7B,MAAA,CAAAC,aAAA,EAAC9D,SAAA,CAAAqE,OAAQ;IAACnD,cAAc,EAAGA;EAAgB,CAAE,CAClC,CACR,CACD,CAAC;AAER"}
@@ -53,12 +53,20 @@ function MoreMenu({
53
53
  const turnOffDistractionFree = () => {
54
54
  setPreference('core', 'distractionFree', false);
55
55
  };
56
- return (0, _react.createElement)(_react.Fragment, null, (0, _react.createElement)(_interface.MoreMenuDropdown, {
56
+ return (0, _react.createElement)(_react.Fragment, null, (0, _react.createElement)(_components.DropdownMenu, {
57
+ icon: _icons.moreVertical,
58
+ label: (0, _i18n.__)('Options'),
59
+ popoverProps: {
60
+ placement: 'bottom-end',
61
+ className: 'more-menu-dropdown__content'
62
+ },
57
63
  toggleProps: {
58
64
  showTooltip: !showIconLabels,
59
65
  ...(showIconLabels && {
60
66
  variant: 'tertiary'
61
- })
67
+ }),
68
+ tooltipPosition: 'bottom',
69
+ size: 'compact'
62
70
  }
63
71
  }, ({
64
72
  onClose
@@ -1 +1 @@
1
- {"version":3,"names":["_i18n","require","_data","_keycodes","_icons","_components","_interface","_preferences","_coreData","_editor","_keyboardShortcutHelpModal","_interopRequireWildcard","_preferencesModal","_toolsMoreMenuGroup","_interopRequireDefault","_siteExport","_welcomeGuideMenuItem","_copyContentMenuItem","_lockUnlock","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","prototype","hasOwnProperty","call","i","set","ModeSwitcher","unlock","editorPrivateApis","MoreMenu","showIconLabels","openModal","useDispatch","interfaceStore","setPreference","preferencesStore","isBlockBasedTheme","useSelect","select","coreStore","getCurrentTheme","is_block_theme","toggleDistractionFree","editorStore","turnOffDistractionFree","_react","createElement","Fragment","MoreMenuDropdown","toggleProps","showTooltip","variant","onClose","MenuGroup","label","_x","PreferenceToggleMenuItem","scope","name","onToggle","__","info","messageActivated","messageDeactivated","handleToggling","shortcut","displayShortcut","primaryShift","ActionItem","Slot","as","fillProps","onClick","MenuItem","KEYBOARD_SHORTCUT_HELP_MODAL_NAME","access","icon","external","role","href","target","rel","VisuallyHidden","PREFERENCES_MODAL_NAME"],"sources":["@wordpress/edit-site/src/components/header-edit-mode/more-menu/index.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { __, _x } from '@wordpress/i18n';\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport { displayShortcut } from '@wordpress/keycodes';\nimport { external } from '@wordpress/icons';\nimport { MenuGroup, MenuItem, VisuallyHidden } from '@wordpress/components';\nimport {\n\tActionItem,\n\tMoreMenuDropdown,\n\tstore as interfaceStore,\n} from '@wordpress/interface';\nimport {\n\tPreferenceToggleMenuItem,\n\tstore as preferencesStore,\n} from '@wordpress/preferences';\nimport { store as coreStore } from '@wordpress/core-data';\nimport {\n\tstore as editorStore,\n\tprivateApis as editorPrivateApis,\n} from '@wordpress/editor';\n\n/**\n * Internal dependencies\n */\nimport {\n\tKEYBOARD_SHORTCUT_HELP_MODAL_NAME,\n\tdefault as KeyboardShortcutHelpModal,\n} from '../../keyboard-shortcut-help-modal';\nimport {\n\tPREFERENCES_MODAL_NAME,\n\tdefault as EditSitePreferencesModal,\n} from '../../preferences-modal';\nimport ToolsMoreMenuGroup from '../tools-more-menu-group';\nimport SiteExport from './site-export';\nimport WelcomeGuideMenuItem from './welcome-guide-menu-item';\nimport CopyContentMenuItem from './copy-content-menu-item';\nimport { unlock } from '../../../lock-unlock';\n\nconst { ModeSwitcher } = unlock( editorPrivateApis );\n\nexport default function MoreMenu( { showIconLabels } ) {\n\tconst { openModal } = useDispatch( interfaceStore );\n\tconst { set: setPreference } = useDispatch( preferencesStore );\n\tconst isBlockBasedTheme = useSelect( ( select ) => {\n\t\treturn select( coreStore ).getCurrentTheme().is_block_theme;\n\t}, [] );\n\n\tconst { toggleDistractionFree } = useDispatch( editorStore );\n\n\tconst turnOffDistractionFree = () => {\n\t\tsetPreference( 'core', 'distractionFree', false );\n\t};\n\n\treturn (\n\t\t<>\n\t\t\t<MoreMenuDropdown\n\t\t\t\ttoggleProps={ {\n\t\t\t\t\tshowTooltip: ! showIconLabels,\n\t\t\t\t\t...( showIconLabels && { variant: 'tertiary' } ),\n\t\t\t\t} }\n\t\t\t>\n\t\t\t\t{ ( { onClose } ) => (\n\t\t\t\t\t<>\n\t\t\t\t\t\t<MenuGroup label={ _x( 'View', 'noun' ) }>\n\t\t\t\t\t\t\t<PreferenceToggleMenuItem\n\t\t\t\t\t\t\t\tscope=\"core\"\n\t\t\t\t\t\t\t\tname=\"fixedToolbar\"\n\t\t\t\t\t\t\t\tonToggle={ turnOffDistractionFree }\n\t\t\t\t\t\t\t\tlabel={ __( 'Top toolbar' ) }\n\t\t\t\t\t\t\t\tinfo={ __(\n\t\t\t\t\t\t\t\t\t'Access all block and document tools in a single place'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\tmessageActivated={ __(\n\t\t\t\t\t\t\t\t\t'Top toolbar activated'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\tmessageDeactivated={ __(\n\t\t\t\t\t\t\t\t\t'Top toolbar deactivated'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t<PreferenceToggleMenuItem\n\t\t\t\t\t\t\t\tscope=\"core\"\n\t\t\t\t\t\t\t\tname=\"distractionFree\"\n\t\t\t\t\t\t\t\tlabel={ __( 'Distraction free' ) }\n\t\t\t\t\t\t\t\tinfo={ __( 'Write with calmness' ) }\n\t\t\t\t\t\t\t\thandleToggling={ false }\n\t\t\t\t\t\t\t\tonToggle={ toggleDistractionFree }\n\t\t\t\t\t\t\t\tmessageActivated={ __(\n\t\t\t\t\t\t\t\t\t'Distraction free mode activated'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\tmessageDeactivated={ __(\n\t\t\t\t\t\t\t\t\t'Distraction free mode deactivated'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\tshortcut={ displayShortcut.primaryShift(\n\t\t\t\t\t\t\t\t\t'\\\\'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t<PreferenceToggleMenuItem\n\t\t\t\t\t\t\t\tscope=\"core\"\n\t\t\t\t\t\t\t\tname=\"focusMode\"\n\t\t\t\t\t\t\t\tlabel={ __( 'Spotlight mode' ) }\n\t\t\t\t\t\t\t\tinfo={ __( 'Focus on one block at a time' ) }\n\t\t\t\t\t\t\t\tmessageActivated={ __(\n\t\t\t\t\t\t\t\t\t'Spotlight mode activated'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\tmessageDeactivated={ __(\n\t\t\t\t\t\t\t\t\t'Spotlight mode deactivated'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</MenuGroup>\n\t\t\t\t\t\t<ModeSwitcher />\n\t\t\t\t\t\t<ActionItem.Slot\n\t\t\t\t\t\t\tname=\"core/edit-site/plugin-more-menu\"\n\t\t\t\t\t\t\tlabel={ __( 'Plugins' ) }\n\t\t\t\t\t\t\tas={ MenuGroup }\n\t\t\t\t\t\t\tfillProps={ { onClick: onClose } }\n\t\t\t\t\t\t/>\n\t\t\t\t\t\t<MenuGroup label={ __( 'Tools' ) }>\n\t\t\t\t\t\t\t{ isBlockBasedTheme && <SiteExport /> }\n\t\t\t\t\t\t\t<MenuItem\n\t\t\t\t\t\t\t\tonClick={ () =>\n\t\t\t\t\t\t\t\t\topenModal(\n\t\t\t\t\t\t\t\t\t\tKEYBOARD_SHORTCUT_HELP_MODAL_NAME\n\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tshortcut={ displayShortcut.access( 'h' ) }\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{ __( 'Keyboard shortcuts' ) }\n\t\t\t\t\t\t\t</MenuItem>\n\t\t\t\t\t\t\t<WelcomeGuideMenuItem />\n\t\t\t\t\t\t\t<CopyContentMenuItem />\n\t\t\t\t\t\t\t<MenuItem\n\t\t\t\t\t\t\t\ticon={ external }\n\t\t\t\t\t\t\t\trole=\"menuitem\"\n\t\t\t\t\t\t\t\thref={ __(\n\t\t\t\t\t\t\t\t\t'https://wordpress.org/documentation/article/site-editor/'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\ttarget=\"_blank\"\n\t\t\t\t\t\t\t\trel=\"noopener noreferrer\"\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{ __( 'Help' ) }\n\t\t\t\t\t\t\t\t<VisuallyHidden as=\"span\">\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t/* translators: accessibility text */\n\t\t\t\t\t\t\t\t\t\t__( '(opens in a new tab)' )\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t</VisuallyHidden>\n\t\t\t\t\t\t\t</MenuItem>\n\t\t\t\t\t\t\t<ToolsMoreMenuGroup.Slot\n\t\t\t\t\t\t\t\tfillProps={ { onClose } }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</MenuGroup>\n\t\t\t\t\t\t<MenuGroup>\n\t\t\t\t\t\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AC;AAEL"}
1
+ {"version":3,"names":["_i18n","require","_data","_keycodes","_icons","_components","_interface","_preferences","_coreData","_editor","_keyboardShortcutHelpModal","_interopRequireWildcard","_preferencesModal","_toolsMoreMenuGroup","_interopRequireDefault","_siteExport","_welcomeGuideMenuItem","_copyContentMenuItem","_lockUnlock","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","prototype","hasOwnProperty","call","i","set","ModeSwitcher","unlock","editorPrivateApis","MoreMenu","showIconLabels","openModal","useDispatch","interfaceStore","setPreference","preferencesStore","isBlockBasedTheme","useSelect","select","coreStore","getCurrentTheme","is_block_theme","toggleDistractionFree","editorStore","turnOffDistractionFree","_react","createElement","Fragment","DropdownMenu","icon","moreVertical","label","__","popoverProps","placement","className","toggleProps","showTooltip","variant","tooltipPosition","size","onClose","MenuGroup","_x","PreferenceToggleMenuItem","scope","name","onToggle","info","messageActivated","messageDeactivated","handleToggling","shortcut","displayShortcut","primaryShift","ActionItem","Slot","as","fillProps","onClick","MenuItem","KEYBOARD_SHORTCUT_HELP_MODAL_NAME","access","external","role","href","target","rel","VisuallyHidden","PREFERENCES_MODAL_NAME"],"sources":["@wordpress/edit-site/src/components/header-edit-mode/more-menu/index.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { __, _x } from '@wordpress/i18n';\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport { displayShortcut } from '@wordpress/keycodes';\nimport { external, moreVertical } from '@wordpress/icons';\nimport {\n\tMenuGroup,\n\tMenuItem,\n\tVisuallyHidden,\n\tDropdownMenu,\n} from '@wordpress/components';\nimport { ActionItem, store as interfaceStore } from '@wordpress/interface';\nimport {\n\tPreferenceToggleMenuItem,\n\tstore as preferencesStore,\n} from '@wordpress/preferences';\nimport { store as coreStore } from '@wordpress/core-data';\nimport {\n\tstore as editorStore,\n\tprivateApis as editorPrivateApis,\n} from '@wordpress/editor';\n\n/**\n * Internal dependencies\n */\nimport {\n\tKEYBOARD_SHORTCUT_HELP_MODAL_NAME,\n\tdefault as KeyboardShortcutHelpModal,\n} from '../../keyboard-shortcut-help-modal';\nimport {\n\tPREFERENCES_MODAL_NAME,\n\tdefault as EditSitePreferencesModal,\n} from '../../preferences-modal';\nimport ToolsMoreMenuGroup from '../tools-more-menu-group';\nimport SiteExport from './site-export';\nimport WelcomeGuideMenuItem from './welcome-guide-menu-item';\nimport CopyContentMenuItem from './copy-content-menu-item';\nimport { unlock } from '../../../lock-unlock';\n\nconst { ModeSwitcher } = unlock( editorPrivateApis );\n\nexport default function MoreMenu( { showIconLabels } ) {\n\tconst { openModal } = useDispatch( interfaceStore );\n\tconst { set: setPreference } = useDispatch( preferencesStore );\n\tconst isBlockBasedTheme = useSelect( ( select ) => {\n\t\treturn select( coreStore ).getCurrentTheme().is_block_theme;\n\t}, [] );\n\n\tconst { toggleDistractionFree } = useDispatch( editorStore );\n\n\tconst turnOffDistractionFree = () => {\n\t\tsetPreference( 'core', 'distractionFree', false );\n\t};\n\n\treturn (\n\t\t<>\n\t\t\t<DropdownMenu\n\t\t\t\ticon={ moreVertical }\n\t\t\t\tlabel={ __( 'Options' ) }\n\t\t\t\tpopoverProps={ {\n\t\t\t\t\tplacement: 'bottom-end',\n\t\t\t\t\tclassName: 'more-menu-dropdown__content',\n\t\t\t\t} }\n\t\t\t\ttoggleProps={ {\n\t\t\t\t\tshowTooltip: ! showIconLabels,\n\t\t\t\t\t...( showIconLabels && { variant: 'tertiary' } ),\n\t\t\t\t\ttooltipPosition: 'bottom',\n\t\t\t\t\tsize: 'compact',\n\t\t\t\t} }\n\t\t\t>\n\t\t\t\t{ ( { onClose } ) => (\n\t\t\t\t\t<>\n\t\t\t\t\t\t<MenuGroup label={ _x( 'View', 'noun' ) }>\n\t\t\t\t\t\t\t<PreferenceToggleMenuItem\n\t\t\t\t\t\t\t\tscope=\"core\"\n\t\t\t\t\t\t\t\tname=\"fixedToolbar\"\n\t\t\t\t\t\t\t\tonToggle={ turnOffDistractionFree }\n\t\t\t\t\t\t\t\tlabel={ __( 'Top toolbar' ) }\n\t\t\t\t\t\t\t\tinfo={ __(\n\t\t\t\t\t\t\t\t\t'Access all block and document tools in a single place'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\tmessageActivated={ __(\n\t\t\t\t\t\t\t\t\t'Top toolbar activated'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\tmessageDeactivated={ __(\n\t\t\t\t\t\t\t\t\t'Top toolbar deactivated'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t<PreferenceToggleMenuItem\n\t\t\t\t\t\t\t\tscope=\"core\"\n\t\t\t\t\t\t\t\tname=\"distractionFree\"\n\t\t\t\t\t\t\t\tlabel={ __( 'Distraction free' ) }\n\t\t\t\t\t\t\t\tinfo={ __( 'Write with calmness' ) }\n\t\t\t\t\t\t\t\thandleToggling={ false }\n\t\t\t\t\t\t\t\tonToggle={ toggleDistractionFree }\n\t\t\t\t\t\t\t\tmessageActivated={ __(\n\t\t\t\t\t\t\t\t\t'Distraction free mode activated'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\tmessageDeactivated={ __(\n\t\t\t\t\t\t\t\t\t'Distraction free mode deactivated'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\tshortcut={ displayShortcut.primaryShift(\n\t\t\t\t\t\t\t\t\t'\\\\'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t<PreferenceToggleMenuItem\n\t\t\t\t\t\t\t\tscope=\"core\"\n\t\t\t\t\t\t\t\tname=\"focusMode\"\n\t\t\t\t\t\t\t\tlabel={ __( 'Spotlight mode' ) }\n\t\t\t\t\t\t\t\tinfo={ __( 'Focus on one block at a time' ) }\n\t\t\t\t\t\t\t\tmessageActivated={ __(\n\t\t\t\t\t\t\t\t\t'Spotlight mode activated'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\tmessageDeactivated={ __(\n\t\t\t\t\t\t\t\t\t'Spotlight mode deactivated'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</MenuGroup>\n\t\t\t\t\t\t<ModeSwitcher />\n\t\t\t\t\t\t<ActionItem.Slot\n\t\t\t\t\t\t\tname=\"core/edit-site/plugin-more-menu\"\n\t\t\t\t\t\t\tlabel={ __( 'Plugins' ) }\n\t\t\t\t\t\t\tas={ MenuGroup }\n\t\t\t\t\t\t\tfillProps={ { onClick: onClose } }\n\t\t\t\t\t\t/>\n\t\t\t\t\t\t<MenuGroup label={ __( 'Tools' ) }>\n\t\t\t\t\t\t\t{ isBlockBasedTheme && <SiteExport /> }\n\t\t\t\t\t\t\t<MenuItem\n\t\t\t\t\t\t\t\tonClick={ () =>\n\t\t\t\t\t\t\t\t\topenModal(\n\t\t\t\t\t\t\t\t\t\tKEYBOARD_SHORTCUT_HELP_MODAL_NAME\n\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tshortcut={ displayShortcut.access( 'h' ) }\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{ __( 'Keyboard shortcuts' ) }\n\t\t\t\t\t\t\t</MenuItem>\n\t\t\t\t\t\t\t<WelcomeGuideMenuItem />\n\t\t\t\t\t\t\t<CopyContentMenuItem />\n\t\t\t\t\t\t\t<MenuItem\n\t\t\t\t\t\t\t\ticon={ external }\n\t\t\t\t\t\t\t\trole=\"menuitem\"\n\t\t\t\t\t\t\t\thref={ __(\n\t\t\t\t\t\t\t\t\t'https://wordpress.org/documentation/article/site-editor/'\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t\ttarget=\"_blank\"\n\t\t\t\t\t\t\t\trel=\"noopener noreferrer\"\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{ __( 'Help' ) }\n\t\t\t\t\t\t\t\t<VisuallyHidden as=\"span\">\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t/* translators: accessibility text */\n\t\t\t\t\t\t\t\t\t\t__( '(opens in a new tab)' )\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t</VisuallyHidden>\n\t\t\t\t\t\t\t</MenuItem>\n\t\t\t\t\t\t\t<ToolsMoreMenuGroup.Slot\n\t\t\t\t\t\t\t\tfillProps={ { onClose } }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t</MenuGroup>\n\t\t\t\t\t\t<MenuGroup>\n\t\t\t\t\t\t\t<MenuItem\n\t\t\t\t\t\t\t\tonClick={ () =>\n\t\t\t\t\t\t\t\t\topenModal( PREFERENCES_MODAL_NAME )\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{ __( 'Preferences' ) }\n\t\t\t\t\t\t\t</MenuItem>\n\t\t\t\t\t\t</MenuGroup>\n\t\t\t\t\t</>\n\t\t\t\t) }\n\t\t\t</DropdownMenu>\n\t\t\t<KeyboardShortcutHelpModal />\n\t\t\t<EditSitePreferencesModal />\n\t\t</>\n\t);\n}\n"],"mappings":";;;;;;;;AAGA,IAAAA,KAAA,GAAAC,OAAA;AACA,IAAAC,KAAA,GAAAD,OAAA;AACA,IAAAE,SAAA,GAAAF,OAAA;AACA,IAAAG,MAAA,GAAAH,OAAA;AACA,IAAAI,WAAA,GAAAJ,OAAA;AAMA,IAAAK,UAAA,GAAAL,OAAA;AACA,IAAAM,YAAA,GAAAN,OAAA;AAIA,IAAAO,SAAA,GAAAP,OAAA;AACA,IAAAQ,OAAA,GAAAR,OAAA;AAQA,IAAAS,0BAAA,GAAAC,uBAAA,CAAAV,OAAA;AAIA,IAAAW,iBAAA,GAAAD,uBAAA,CAAAV,OAAA;AAIA,IAAAY,mBAAA,GAAAC,sBAAA,CAAAb,OAAA;AACA,IAAAc,WAAA,GAAAD,sBAAA,CAAAb,OAAA;AACA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,EAAC;EAAM,GAEvB;EACA,IAAAzB,QAAE,EAAE,sBAAuB,CAEb,CACP,CAAC,EACX,IAAAP,MAAA,CAAAC,aAAA,EAAC/C,mBAAA,CAAAY,OAAkB,CAACiE,IAAI;IACvBE,SAAS,EAAG;MAAEjB;IAAQ;EAAG,CACzB,CACS,CAAC,EACZ,IAAAhB,MAAA,CAAAC,aAAA,EAACvD,WAAA,CAAAuE,SAAS,QACT,IAAAjB,MAAA,CAAAC,aAAA,EAACvD,WAAA,CAAAyF,QAAQ;IACRD,OAAO,EAAGA,CAAA,KACThD,SAAS,CAAE0D,wCAAuB;EAClC,GAEC,IAAArC,QAAE,EAAE,aAAc,CACX,CACA,CACV,CAEU,CAAC,EACf,IAAAP,MAAA,CAAAC,aAAA,EAAClD,0BAAA,CAAAe,OAAyB,MAAE,CAAC,EAC7B,IAAAkC,MAAA,CAAAC,aAAA,EAAChD,iBAAA,CAAAa,OAAwB,MAAE,CAC1B,CAAC;AAEL"}
@@ -66,6 +66,7 @@ function Layout() {
66
66
  const isMobileViewport = (0, _compose.useViewportMatch)('medium', '<');
67
67
  const {
68
68
  isDistractionFree,
69
+ isZoomOutMode,
69
70
  hasFixedToolbar,
70
71
  hasBlockSelected,
71
72
  canvasMode,
@@ -84,6 +85,7 @@ function Layout() {
84
85
  nextShortcut: getAllShortcutKeyCombinations('core/edit-site/next-region'),
85
86
  hasFixedToolbar: select(_preferences.store).get('core', 'fixedToolbar'),
86
87
  isDistractionFree: select(_preferences.store).get('core', 'distractionFree'),
88
+ isZoomOutMode: select(_blockEditor.store).__unstableGetEditorMode() === 'zoom-out',
87
89
  hasBlockSelected: select(_blockEditor.store).getBlockSelectionStart()
88
90
  };
89
91
  }, []);
@@ -146,7 +148,8 @@ function Layout() {
146
148
  'is-distraction-free': isDistractionFree && canvasMode === 'edit',
147
149
  'is-full-canvas': canvasMode === 'edit',
148
150
  'has-fixed-toolbar': hasFixedToolbar,
149
- 'is-block-toolbar-visible': hasBlockSelected
151
+ 'is-block-toolbar-visible': hasBlockSelected,
152
+ 'is-zoom-out': isZoomOutMode
150
153
  })
151
154
  }, (0, _react.createElement)(_components.__unstableMotion.div, {
152
155
  className: "edit-site-layout__header-container",