@wordpress/block-library 9.1.0 → 9.3.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 (387) hide show
  1. package/CHANGELOG.md +21 -17
  2. package/build/audio/edit.js +20 -8
  3. package/build/audio/edit.js.map +1 -1
  4. package/build/audio/index.js +4 -0
  5. package/build/audio/index.js.map +1 -1
  6. package/build/audio/transforms.js +1 -1
  7. package/build/audio/transforms.js.map +1 -1
  8. package/build/block/edit.js +0 -1
  9. package/build/block/edit.js.map +1 -1
  10. package/build/block/index.js +5 -1
  11. package/build/block/index.js.map +1 -1
  12. package/build/button/index.js +1 -0
  13. package/build/button/index.js.map +1 -1
  14. package/build/embed/embed-preview.js +4 -4
  15. package/build/embed/embed-preview.js.map +1 -1
  16. package/build/file/edit.js +14 -6
  17. package/build/file/edit.js.map +1 -1
  18. package/build/file/index.js +4 -0
  19. package/build/file/index.js.map +1 -1
  20. package/build/file/transforms.js +2 -3
  21. package/build/file/transforms.js.map +1 -1
  22. package/build/gallery/deprecated.js +6 -54
  23. package/build/gallery/deprecated.js.map +1 -1
  24. package/build/gallery/edit.js +9 -8
  25. package/build/gallery/edit.js.map +1 -1
  26. package/build/gallery/index.js +2 -2
  27. package/build/gallery/index.js.map +1 -1
  28. package/build/gallery/save.js +0 -11
  29. package/build/gallery/save.js.map +1 -1
  30. package/build/gallery/shared.js +0 -27
  31. package/build/gallery/shared.js.map +1 -1
  32. package/build/gallery/transforms.js +29 -80
  33. package/build/gallery/transforms.js.map +1 -1
  34. package/build/group/index.js +1 -0
  35. package/build/group/index.js.map +1 -1
  36. package/build/group/placeholder.js +5 -0
  37. package/build/group/placeholder.js.map +1 -1
  38. package/build/image/edit.js +13 -21
  39. package/build/image/edit.js.map +1 -1
  40. package/build/image/image.js +33 -19
  41. package/build/image/image.js.map +1 -1
  42. package/build/image/index.js +4 -0
  43. package/build/image/index.js.map +1 -1
  44. package/build/image/transforms.js +1 -1
  45. package/build/image/transforms.js.map +1 -1
  46. package/build/list-item/edit.js +1 -1
  47. package/build/list-item/edit.js.map +1 -1
  48. package/build/list-item/hooks/use-merge.js +8 -1
  49. package/build/list-item/hooks/use-merge.js.map +1 -1
  50. package/build/list-item/index.js +11 -1
  51. package/build/list-item/index.js.map +1 -1
  52. package/build/lock-unlock.js +1 -1
  53. package/build/lock-unlock.js.map +1 -1
  54. package/build/loginout/index.js +3 -0
  55. package/build/loginout/index.js.map +1 -1
  56. package/build/media-text/edit.js +3 -2
  57. package/build/media-text/edit.js.map +1 -1
  58. package/build/navigation-submenu/edit.js +1 -1
  59. package/build/navigation-submenu/edit.js.map +1 -1
  60. package/build/page-list/convert-to-links-modal.js +1 -1
  61. package/build/page-list/convert-to-links-modal.js.map +1 -1
  62. package/build/page-list/edit.js +1 -1
  63. package/build/page-list/edit.js.map +1 -1
  64. package/build/post-content/index.js +3 -0
  65. package/build/post-content/index.js.map +1 -1
  66. package/build/post-date/edit.js +3 -1
  67. package/build/post-date/edit.js.map +1 -1
  68. package/build/post-excerpt/index.js +3 -0
  69. package/build/post-excerpt/index.js.map +1 -1
  70. package/build/post-title/index.js +3 -0
  71. package/build/post-title/index.js.map +1 -1
  72. package/build/query/edit/inspector-controls/index.js +3 -2
  73. package/build/query/edit/inspector-controls/index.js.map +1 -1
  74. package/build/query/edit/query-toolbar.js +54 -61
  75. package/build/query/edit/query-toolbar.js.map +1 -1
  76. package/build/query/index.js +34 -0
  77. package/build/query/index.js.map +1 -1
  78. package/build/quote/edit.js +1 -0
  79. package/build/quote/edit.js.map +1 -1
  80. package/build/site-tagline/index.js +1 -0
  81. package/build/site-tagline/index.js.map +1 -1
  82. package/build/site-title/index.js +1 -0
  83. package/build/site-title/index.js.map +1 -1
  84. package/build/social-link/edit.js +9 -3
  85. package/build/social-link/edit.js.map +1 -1
  86. package/build/table/edit.js +8 -17
  87. package/build/table/edit.js.map +1 -1
  88. package/build/table-of-contents/index.js +1 -1
  89. package/build/template-part/edit/title-modal.js +1 -1
  90. package/build/template-part/edit/title-modal.js.map +1 -1
  91. package/build/utils/caption.js +2 -1
  92. package/build/utils/caption.js.map +1 -1
  93. package/build/utils/hooks.js +12 -0
  94. package/build/utils/hooks.js.map +1 -1
  95. package/build/verse/index.js +1 -0
  96. package/build/verse/index.js.map +1 -1
  97. package/build/video/deprecated.js +4 -0
  98. package/build/video/deprecated.js.map +1 -1
  99. package/build/video/edit.js +17 -7
  100. package/build/video/edit.js.map +1 -1
  101. package/build/video/index.js +4 -0
  102. package/build/video/index.js.map +1 -1
  103. package/build/video/transforms.js +1 -1
  104. package/build/video/transforms.js.map +1 -1
  105. package/build-module/audio/edit.js +20 -8
  106. package/build-module/audio/edit.js.map +1 -1
  107. package/build-module/audio/index.js +4 -0
  108. package/build-module/audio/index.js.map +1 -1
  109. package/build-module/audio/transforms.js +1 -1
  110. package/build-module/audio/transforms.js.map +1 -1
  111. package/build-module/block/edit.js +0 -1
  112. package/build-module/block/edit.js.map +1 -1
  113. package/build-module/block/index.js +5 -1
  114. package/build-module/block/index.js.map +1 -1
  115. package/build-module/button/index.js +1 -0
  116. package/build-module/button/index.js.map +1 -1
  117. package/build-module/embed/embed-preview.js +4 -4
  118. package/build-module/embed/embed-preview.js.map +1 -1
  119. package/build-module/file/edit.js +15 -7
  120. package/build-module/file/edit.js.map +1 -1
  121. package/build-module/file/index.js +4 -0
  122. package/build-module/file/index.js.map +1 -1
  123. package/build-module/file/transforms.js +2 -3
  124. package/build-module/file/transforms.js.map +1 -1
  125. package/build-module/gallery/deprecated.js +6 -54
  126. package/build-module/gallery/deprecated.js.map +1 -1
  127. package/build-module/gallery/edit.js +10 -9
  128. package/build-module/gallery/edit.js.map +1 -1
  129. package/build-module/gallery/index.js +1 -1
  130. package/build-module/gallery/index.js.map +1 -1
  131. package/build-module/gallery/save.js +0 -11
  132. package/build-module/gallery/save.js.map +1 -1
  133. package/build-module/gallery/shared.js +0 -25
  134. package/build-module/gallery/shared.js.map +1 -1
  135. package/build-module/gallery/transforms.js +29 -80
  136. package/build-module/gallery/transforms.js.map +1 -1
  137. package/build-module/group/index.js +1 -0
  138. package/build-module/group/index.js.map +1 -1
  139. package/build-module/group/placeholder.js +5 -0
  140. package/build-module/group/placeholder.js.map +1 -1
  141. package/build-module/image/edit.js +12 -20
  142. package/build-module/image/edit.js.map +1 -1
  143. package/build-module/image/image.js +28 -14
  144. package/build-module/image/image.js.map +1 -1
  145. package/build-module/image/index.js +4 -0
  146. package/build-module/image/index.js.map +1 -1
  147. package/build-module/image/transforms.js +1 -1
  148. package/build-module/image/transforms.js.map +1 -1
  149. package/build-module/list-item/edit.js +1 -1
  150. package/build-module/list-item/edit.js.map +1 -1
  151. package/build-module/list-item/hooks/use-merge.js +8 -1
  152. package/build-module/list-item/hooks/use-merge.js.map +1 -1
  153. package/build-module/list-item/index.js +11 -1
  154. package/build-module/list-item/index.js.map +1 -1
  155. package/build-module/lock-unlock.js +1 -1
  156. package/build-module/lock-unlock.js.map +1 -1
  157. package/build-module/loginout/index.js +3 -0
  158. package/build-module/loginout/index.js.map +1 -1
  159. package/build-module/media-text/edit.js +3 -2
  160. package/build-module/media-text/edit.js.map +1 -1
  161. package/build-module/navigation-submenu/edit.js +1 -1
  162. package/build-module/navigation-submenu/edit.js.map +1 -1
  163. package/build-module/page-list/convert-to-links-modal.js +1 -1
  164. package/build-module/page-list/convert-to-links-modal.js.map +1 -1
  165. package/build-module/page-list/edit.js +1 -1
  166. package/build-module/page-list/edit.js.map +1 -1
  167. package/build-module/post-content/index.js +3 -0
  168. package/build-module/post-content/index.js.map +1 -1
  169. package/build-module/post-date/edit.js +4 -2
  170. package/build-module/post-date/edit.js.map +1 -1
  171. package/build-module/post-excerpt/index.js +3 -0
  172. package/build-module/post-excerpt/index.js.map +1 -1
  173. package/build-module/post-title/index.js +3 -0
  174. package/build-module/post-title/index.js.map +1 -1
  175. package/build-module/query/edit/inspector-controls/index.js +3 -2
  176. package/build-module/query/edit/inspector-controls/index.js.map +1 -1
  177. package/build-module/query/edit/query-toolbar.js +55 -62
  178. package/build-module/query/edit/query-toolbar.js.map +1 -1
  179. package/build-module/query/index.js +34 -0
  180. package/build-module/query/index.js.map +1 -1
  181. package/build-module/quote/edit.js +1 -0
  182. package/build-module/quote/edit.js.map +1 -1
  183. package/build-module/site-tagline/index.js +1 -0
  184. package/build-module/site-tagline/index.js.map +1 -1
  185. package/build-module/site-title/index.js +1 -0
  186. package/build-module/site-title/index.js.map +1 -1
  187. package/build-module/social-link/edit.js +9 -3
  188. package/build-module/social-link/edit.js.map +1 -1
  189. package/build-module/table/edit.js +9 -18
  190. package/build-module/table/edit.js.map +1 -1
  191. package/build-module/table-of-contents/index.js +1 -1
  192. package/build-module/template-part/edit/title-modal.js +1 -1
  193. package/build-module/template-part/edit/title-modal.js.map +1 -1
  194. package/build-module/utils/caption.js +2 -1
  195. package/build-module/utils/caption.js.map +1 -1
  196. package/build-module/utils/hooks.js +11 -0
  197. package/build-module/utils/hooks.js.map +1 -1
  198. package/build-module/verse/index.js +1 -0
  199. package/build-module/verse/index.js.map +1 -1
  200. package/build-module/video/deprecated.js +4 -0
  201. package/build-module/video/deprecated.js.map +1 -1
  202. package/build-module/video/edit.js +18 -8
  203. package/build-module/video/edit.js.map +1 -1
  204. package/build-module/video/index.js +4 -0
  205. package/build-module/video/index.js.map +1 -1
  206. package/build-module/video/transforms.js +1 -1
  207. package/build-module/video/transforms.js.map +1 -1
  208. package/build-style/audio/style-rtl.css +1 -1
  209. package/build-style/audio/style.css +1 -1
  210. package/build-style/audio/theme-rtl.css +2 -2
  211. package/build-style/audio/theme.css +2 -2
  212. package/build-style/common-rtl.css +1 -3
  213. package/build-style/common.css +1 -3
  214. package/build-style/editor-rtl.css +3 -12
  215. package/build-style/editor.css +3 -12
  216. package/build-style/embed/style-rtl.css +1 -1
  217. package/build-style/embed/style.css +1 -1
  218. package/build-style/embed/theme-rtl.css +2 -2
  219. package/build-style/embed/theme.css +2 -2
  220. package/build-style/image/editor-rtl.css +0 -12
  221. package/build-style/image/editor.css +0 -12
  222. package/build-style/image/style-rtl.css +7 -1
  223. package/build-style/image/style.css +7 -1
  224. package/build-style/media-text/style-rtl.css +4 -0
  225. package/build-style/media-text/style.css +4 -0
  226. package/build-style/navigation/style-rtl.css +1 -0
  227. package/build-style/navigation/style.css +1 -0
  228. package/build-style/post-comments-form/style-rtl.css +11 -10
  229. package/build-style/post-comments-form/style.css +11 -10
  230. package/build-style/query/editor-rtl.css +3 -0
  231. package/build-style/query/editor.css +3 -0
  232. package/build-style/reset-rtl.css +1 -5
  233. package/build-style/reset.css +1 -5
  234. package/build-style/search/style-rtl.css +1 -2
  235. package/build-style/search/style.css +1 -2
  236. package/build-style/social-links/style-rtl.css +91 -91
  237. package/build-style/social-links/style.css +91 -91
  238. package/build-style/style-rtl.css +119 -110
  239. package/build-style/style.css +119 -110
  240. package/build-style/table/theme-rtl.css +2 -2
  241. package/build-style/table/theme.css +2 -2
  242. package/build-style/theme-rtl.css +8 -8
  243. package/build-style/theme.css +8 -8
  244. package/build-style/video/style-rtl.css +1 -1
  245. package/build-style/video/style.css +1 -1
  246. package/build-style/video/theme-rtl.css +2 -2
  247. package/build-style/video/theme.css +2 -2
  248. package/package.json +35 -35
  249. package/src/audio/block.json +4 -0
  250. package/src/audio/edit.js +19 -7
  251. package/src/audio/style.scss +1 -1
  252. package/src/audio/theme.scss +1 -1
  253. package/src/audio/transforms.js +1 -1
  254. package/src/block/block.json +5 -1
  255. package/src/block/edit.js +0 -1
  256. package/src/button/block.json +1 -0
  257. package/src/button/index.php +14 -1
  258. package/src/embed/embed-preview.js +4 -6
  259. package/src/embed/style.scss +1 -1
  260. package/src/embed/theme.scss +1 -1
  261. package/src/file/block.json +4 -0
  262. package/src/file/edit.js +19 -6
  263. package/src/file/transforms.js +1 -2
  264. package/src/gallery/deprecated.js +6 -55
  265. package/src/gallery/edit.js +13 -10
  266. package/src/gallery/gallery-styles.native.scss +0 -2
  267. package/src/gallery/index.js +1 -1
  268. package/src/gallery/save.js +0 -10
  269. package/src/gallery/shared.js +0 -28
  270. package/src/gallery/transforms.js +56 -99
  271. package/src/group/block.json +1 -0
  272. package/src/group/placeholder.js +7 -0
  273. package/src/image/block.json +4 -0
  274. package/src/image/edit.js +10 -19
  275. package/src/image/editor.scss +0 -13
  276. package/src/image/image.js +45 -16
  277. package/src/image/index.php +26 -5
  278. package/src/image/style.scss +11 -1
  279. package/src/image/transforms.js +1 -1
  280. package/src/list-item/block.json +11 -1
  281. package/src/list-item/edit.js +1 -1
  282. package/src/list-item/hooks/use-merge.js +19 -5
  283. package/src/lock-unlock.js +1 -1
  284. package/src/loginout/block.json +3 -0
  285. package/src/media-text/edit.js +3 -2
  286. package/src/media-text/index.php +68 -18
  287. package/src/media-text/style.scss +4 -0
  288. package/src/navigation/index.php +5 -3
  289. package/src/navigation/style.scss +1 -0
  290. package/src/navigation-submenu/edit.js +1 -1
  291. package/src/page-list/convert-to-links-modal.js +1 -1
  292. package/src/page-list/edit.js +1 -1
  293. package/src/paragraph/test/__snapshots__/edit.native.js.snap +30 -0
  294. package/src/paragraph/test/edit.native.js +99 -0
  295. package/src/post-comments-form/style.scss +15 -12
  296. package/src/post-content/block.json +3 -0
  297. package/src/post-date/edit.js +5 -1
  298. package/src/post-date/index.php +9 -3
  299. package/src/post-excerpt/block.json +3 -0
  300. package/src/post-title/block.json +3 -0
  301. package/src/query/edit/inspector-controls/index.js +3 -2
  302. package/src/query/edit/query-toolbar.js +60 -72
  303. package/src/query/editor.scss +4 -0
  304. package/src/query/index.js +40 -0
  305. package/src/quote/edit.js +1 -0
  306. package/src/reset.scss +11 -12
  307. package/src/site-tagline/block.json +1 -0
  308. package/src/site-title/block.json +1 -0
  309. package/src/social-link/edit.js +9 -3
  310. package/src/social-links/style.scss +2 -2
  311. package/src/table/edit.js +11 -24
  312. package/src/table/theme.scss +1 -1
  313. package/src/table-of-contents/block.json +1 -1
  314. package/src/template-part/edit/title-modal.js +1 -1
  315. package/src/template-part/index.php +1 -1
  316. package/src/utils/caption.js +5 -1
  317. package/src/utils/hooks.js +14 -1
  318. package/src/verse/block.json +1 -0
  319. package/src/video/block.json +4 -0
  320. package/src/video/edit.js +23 -8
  321. package/src/video/style.scss +1 -1
  322. package/src/video/theme.scss +1 -1
  323. package/src/video/transforms.js +1 -1
  324. package/tsconfig.tsbuildinfo +1 -1
  325. package/build/gallery/edit-wrapper.js +0 -37
  326. package/build/gallery/edit-wrapper.js.map +0 -1
  327. package/build/gallery/v1/constants.js +0 -10
  328. package/build/gallery/v1/constants.js.map +0 -1
  329. package/build/gallery/v1/edit.js +0 -399
  330. package/build/gallery/v1/edit.js.map +0 -1
  331. package/build/gallery/v1/gallery-button.native.js +0 -55
  332. package/build/gallery/v1/gallery-button.native.js.map +0 -1
  333. package/build/gallery/v1/gallery-image.js +0 -285
  334. package/build/gallery/v1/gallery-image.js.map +0 -1
  335. package/build/gallery/v1/gallery-image.native.js +0 -297
  336. package/build/gallery/v1/gallery-image.native.js.map +0 -1
  337. package/build/gallery/v1/gallery.js +0 -112
  338. package/build/gallery/v1/gallery.js.map +0 -1
  339. package/build/gallery/v1/gallery.native.js +0 -139
  340. package/build/gallery/v1/gallery.native.js.map +0 -1
  341. package/build/gallery/v1/save.js +0 -81
  342. package/build/gallery/v1/save.js.map +0 -1
  343. package/build/gallery/v1/shared.js +0 -17
  344. package/build/gallery/v1/shared.js.map +0 -1
  345. package/build/gallery/v1/tiles.native.js +0 -83
  346. package/build/gallery/v1/tiles.native.js.map +0 -1
  347. package/build/utils/constants.js +0 -15
  348. package/build/utils/constants.js.map +0 -1
  349. package/build-module/gallery/edit-wrapper.js +0 -31
  350. package/build-module/gallery/edit-wrapper.js.map +0 -1
  351. package/build-module/gallery/v1/constants.js +0 -4
  352. package/build-module/gallery/v1/constants.js.map +0 -1
  353. package/build-module/gallery/v1/edit.js +0 -393
  354. package/build-module/gallery/v1/edit.js.map +0 -1
  355. package/build-module/gallery/v1/gallery-button.native.js +0 -46
  356. package/build-module/gallery/v1/gallery-button.native.js.map +0 -1
  357. package/build-module/gallery/v1/gallery-image.js +0 -279
  358. package/build-module/gallery/v1/gallery-image.js.map +0 -1
  359. package/build-module/gallery/v1/gallery-image.native.js +0 -291
  360. package/build-module/gallery/v1/gallery-image.native.js.map +0 -1
  361. package/build-module/gallery/v1/gallery.js +0 -104
  362. package/build-module/gallery/v1/gallery.js.map +0 -1
  363. package/build-module/gallery/v1/gallery.native.js +0 -131
  364. package/build-module/gallery/v1/gallery.native.js.map +0 -1
  365. package/build-module/gallery/v1/save.js +0 -74
  366. package/build-module/gallery/v1/save.js.map +0 -1
  367. package/build-module/gallery/v1/shared.js +0 -10
  368. package/build-module/gallery/v1/shared.js.map +0 -1
  369. package/build-module/gallery/v1/tiles.native.js +0 -75
  370. package/build-module/gallery/v1/tiles.native.js.map +0 -1
  371. package/build-module/utils/constants.js +0 -9
  372. package/build-module/utils/constants.js.map +0 -1
  373. package/src/gallery/edit-wrapper.js +0 -27
  374. package/src/gallery/v1/constants.js +0 -3
  375. package/src/gallery/v1/edit.js +0 -450
  376. package/src/gallery/v1/gallery-button.native.js +0 -47
  377. package/src/gallery/v1/gallery-image-style.native.scss +0 -109
  378. package/src/gallery/v1/gallery-image.js +0 -293
  379. package/src/gallery/v1/gallery-image.native.js +0 -348
  380. package/src/gallery/v1/gallery-styles.native.scss +0 -8
  381. package/src/gallery/v1/gallery.js +0 -125
  382. package/src/gallery/v1/gallery.native.js +0 -162
  383. package/src/gallery/v1/save.js +0 -98
  384. package/src/gallery/v1/shared.js +0 -19
  385. package/src/gallery/v1/tiles-styles.native.scss +0 -11
  386. package/src/gallery/v1/tiles.native.js +0 -79
  387. package/src/utils/constants.js +0 -8
@@ -1,4 +1,9 @@
1
1
  .wp-block-image {
2
+
3
+ a {
4
+ display: inline-block;
5
+ }
6
+
2
7
  img {
3
8
  height: auto;
4
9
  max-width: 100%;
@@ -27,6 +32,11 @@
27
32
  text-align: center;
28
33
  }
29
34
 
35
+ &.alignfull a,
36
+ &.alignwide a {
37
+ width: 100%;
38
+ }
39
+
30
40
  &.alignfull img,
31
41
  &.alignwide img {
32
42
  height: auto;
@@ -78,7 +88,7 @@
78
88
  // Supply caption styles to images, even if the theme hasn't opted in.
79
89
  // Reason being: the new markup, <figcaptions>, are not likely to be styled in the majority of existing themes,
80
90
  // so we supply the styles so as to not appear broken or unstyled in those themes.
81
- figcaption {
91
+ :where(figcaption) {
82
92
  @include caption-style();
83
93
  }
84
94
 
@@ -159,7 +159,7 @@ const transforms = {
159
159
  transform( files ) {
160
160
  const blocks = files.map( ( file ) => {
161
161
  return createBlock( 'core/image', {
162
- url: createBlobURL( file ),
162
+ blob: createBlobURL( file ),
163
163
  } );
164
164
  } );
165
165
  return blocks;
@@ -21,8 +21,15 @@
21
21
  },
22
22
  "supports": {
23
23
  "className": false,
24
- "__experimentalSelector": ".wp-block-list > li",
25
24
  "splitting": true,
25
+ "color": {
26
+ "gradients": true,
27
+ "link": true,
28
+ "__experimentalDefaultControls": {
29
+ "background": true,
30
+ "text": true
31
+ }
32
+ },
26
33
  "spacing": {
27
34
  "margin": true,
28
35
  "padding": true,
@@ -47,5 +54,8 @@
47
54
  "interactivity": {
48
55
  "clientNavigation": true
49
56
  }
57
+ },
58
+ "selectors": {
59
+ "root": ".wp-block-list > li"
50
60
  }
51
61
  }
@@ -61,7 +61,7 @@ export function IndentUI( { clientId } ) {
61
61
  icon={ isRTL() ? formatIndentRTL : formatIndent }
62
62
  title={ __( 'Indent' ) }
63
63
  describedBy={ __( 'Indent list item' ) }
64
- isDisabled={ ! canIndent }
64
+ disabled={ ! canIndent }
65
65
  onClick={ () => indentListItem() }
66
66
  />
67
67
  </>
@@ -92,11 +92,25 @@ export default function useMerge( clientId, onMerge ) {
92
92
  // list.
93
93
  const [ nestedListClientId ] = getBlockOrder( clientIdB );
94
94
  if ( nestedListClientId ) {
95
- moveBlocksToPosition(
96
- getBlockOrder( nestedListClientId ),
97
- nestedListClientId,
98
- getBlockRootClientId( clientIdA )
99
- );
95
+ // If we are merging with the previous list item, and the
96
+ // previous list item does not have nested list, move the
97
+ // nested list to the previous list item.
98
+ if (
99
+ getPreviousBlockClientId( clientIdB ) === clientIdA &&
100
+ ! getBlockOrder( clientIdA ).length
101
+ ) {
102
+ moveBlocksToPosition(
103
+ [ nestedListClientId ],
104
+ clientIdB,
105
+ clientIdA
106
+ );
107
+ } else {
108
+ moveBlocksToPosition(
109
+ getBlockOrder( nestedListClientId ),
110
+ nestedListClientId,
111
+ getBlockRootClientId( clientIdA )
112
+ );
113
+ }
100
114
  }
101
115
  mergeBlocks( clientIdA, clientIdB );
102
116
  } );
@@ -5,6 +5,6 @@ import { __dangerousOptInToUnstableAPIsOnlyForCoreModules } from '@wordpress/pri
5
5
 
6
6
  export const { lock, unlock } =
7
7
  __dangerousOptInToUnstableAPIsOnlyForCoreModules(
8
- 'I know using unstable features means my theme or plugin will inevitably break in the next version of WordPress.',
8
+ 'I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.',
9
9
  '@wordpress/block-library'
10
10
  );
@@ -17,6 +17,9 @@
17
17
  "default": true
18
18
  }
19
19
  },
20
+ "example": {
21
+ "viewportWidth": 350
22
+ },
20
23
  "supports": {
21
24
  "className": true,
22
25
  "spacing": {
@@ -46,7 +46,7 @@ import {
46
46
  TEMPLATE,
47
47
  } from './constants';
48
48
  import { unlock } from '../lock-unlock';
49
- import { TOOLSPANEL_DROPDOWNMENU_PROPS } from '../utils/constants';
49
+ import { useToolsPanelDropdownMenuProps } from '../utils/hooks';
50
50
 
51
51
  const { ResolutionTool } = unlock( blockEditorPrivateApis );
52
52
 
@@ -276,6 +276,7 @@ function MediaTextEdit( {
276
276
  mediaSizeSlug: newMediaSizeSlug,
277
277
  } );
278
278
  };
279
+ const dropdownMenuProps = useToolsPanelDropdownMenuProps();
279
280
 
280
281
  const mediaTextGeneralSettings = (
281
282
  <ToolsPanel
@@ -290,7 +291,7 @@ function MediaTextEdit( {
290
291
  mediaSizeSlug: undefined,
291
292
  } );
292
293
  } }
293
- dropdownMenuProps={ TOOLSPANEL_DROPDOWNMENU_PROPS }
294
+ dropdownMenuProps={ dropdownMenuProps }
294
295
  >
295
296
  <ToolsPanelItem
296
297
  label={ __( 'Media width' ) }
@@ -29,28 +29,78 @@ function render_block_core_media_text( $attributes, $content ) {
29
29
  return $content;
30
30
  }
31
31
 
32
- $image_tag = '<figure class="wp-block-media-text__media"><img>';
33
- $content = preg_replace( '/<figure\s+class="wp-block-media-text__media">/', $image_tag, $content );
32
+ $media_tag_processor = new WP_HTML_Tag_Processor( $content );
33
+ $wrapping_figure_query = array(
34
+ 'tag_name' => 'figure',
35
+ 'class_name' => 'wp-block-media-text__media',
36
+ );
37
+ $has_media_on_right = isset( $attributes['mediaPosition'] ) && 'right' === $attributes['mediaPosition'];
38
+ $image_fill = isset( $attributes['imageFill'] ) && $attributes['imageFill'];
39
+ $focal_point = isset( $attributes['focalPoint'] ) ? round( $attributes['focalPoint']['x'] * 100 ) . '% ' . round( $attributes['focalPoint']['y'] * 100 ) . '%' : '50% 50%';
40
+ $unique_id = 'wp-block-media-text__media-' . wp_unique_id();
34
41
 
35
- $processor = new WP_HTML_Tag_Processor( $content );
36
- if ( isset( $attributes['imageFill'] ) && $attributes['imageFill'] ) {
37
- $position = '50% 50%';
38
- if ( isset( $attributes['focalPoint'] ) ) {
39
- $position = round( $attributes['focalPoint']['x'] * 100 ) . '% ' . round( $attributes['focalPoint']['y'] * 100 ) . '%';
42
+ if ( $has_media_on_right ) {
43
+ // Loop through all the figure tags and set a bookmark on the last figure tag.
44
+ while ( $media_tag_processor->next_tag( $wrapping_figure_query ) ) {
45
+ $media_tag_processor->set_bookmark( 'last_figure' );
46
+ }
47
+ if ( $media_tag_processor->has_bookmark( 'last_figure' ) ) {
48
+ $media_tag_processor->seek( 'last_figure' );
49
+ if ( $image_fill ) {
50
+ $media_tag_processor->set_attribute( 'style', 'background-image:url(' . esc_url( $current_featured_image ) . ');background-position:' . $focal_point . ';' );
51
+ } else {
52
+ // Insert a unique ID to identify the figure tag.
53
+ $media_tag_processor->set_attribute( 'id', $unique_id );
54
+ }
55
+ }
56
+ } else {
57
+ if ( $media_tag_processor->next_tag( $wrapping_figure_query ) ) {
58
+ if ( $image_fill ) {
59
+ $media_tag_processor->set_attribute( 'style', 'background-image:url(' . esc_url( $current_featured_image ) . ');background-position:' . $focal_point . ';' );
60
+ } else {
61
+ // Insert a unique ID to identify the figure tag.
62
+ $media_tag_processor->set_attribute( 'id', $unique_id );
63
+ }
40
64
  }
41
- $processor->next_tag( 'figure' );
42
- $processor->set_attribute( 'style', 'background-image:url(' . esc_url( $current_featured_image ) . ');background-position:' . $position . ';' );
43
- }
44
- $processor->next_tag( 'img' );
45
- $media_size_slug = 'full';
46
- if ( isset( $attributes['mediaSizeSlug'] ) ) {
47
- $media_size_slug = $attributes['mediaSizeSlug'];
48
65
  }
49
- $processor->set_attribute( 'src', esc_url( $current_featured_image ) );
50
- $processor->set_attribute( 'class', 'wp-image-' . get_post_thumbnail_id() . ' size-' . $media_size_slug );
51
- $processor->set_attribute( 'alt', trim( strip_tags( get_post_meta( get_post_thumbnail_id(), '_wp_attachment_image_alt', true ) ) ) );
52
66
 
53
- $content = $processor->get_updated_html();
67
+ $content = $media_tag_processor->get_updated_html();
68
+
69
+ // If the image is not set to fill, add the image tag inside the figure tag,
70
+ // and update the image attributes in order to display the featured image.
71
+ if ( ! $image_fill ) {
72
+ $media_size_slug = isset( $attributes['mediaSizeSlug'] ) ? $attributes['mediaSizeSlug'] : 'full';
73
+ $image_tag = '<img class="wp-block-media-text__featured_image">';
74
+ $content = preg_replace(
75
+ '/(<figure\s+id="' . preg_quote( $unique_id, '/' ) . '"\s+class="wp-block-media-text__media"\s*>)/',
76
+ '$1' . $image_tag,
77
+ $content
78
+ );
79
+
80
+ $image_tag_processor = new WP_HTML_Tag_Processor( $content );
81
+ if ( $image_tag_processor->next_tag(
82
+ array(
83
+ 'tag_name' => 'figure',
84
+ 'id' => $unique_id,
85
+ )
86
+ ) ) {
87
+ // The ID is only used to ensure that the correct figure tag is selected,
88
+ // and can now be removed.
89
+ $image_tag_processor->remove_attribute( 'id' );
90
+ if ( $image_tag_processor->next_tag(
91
+ array(
92
+ 'tag_name' => 'img',
93
+ 'class_name' => 'wp-block-media-text__featured_image',
94
+ )
95
+ ) ) {
96
+ $image_tag_processor->set_attribute( 'src', esc_url( $current_featured_image ) );
97
+ $image_tag_processor->set_attribute( 'class', 'wp-image-' . get_post_thumbnail_id() . ' size-' . $media_size_slug );
98
+ $image_tag_processor->set_attribute( 'alt', trim( strip_tags( get_post_meta( get_post_thumbnail_id(), '_wp_attachment_image_alt', true ) ) ) );
99
+
100
+ $content = $image_tag_processor->get_updated_html();
101
+ }
102
+ }
103
+ }
54
104
 
55
105
  return $content;
56
106
  }
@@ -68,6 +68,10 @@
68
68
  /*!rtl:end:ignore*/
69
69
  }
70
70
 
71
+ .wp-block-media-text__media a {
72
+ display: inline-block;
73
+ }
74
+
71
75
  .wp-block-media-text__media img,
72
76
  .wp-block-media-text__media video {
73
77
  height: auto;
@@ -519,9 +519,11 @@ class WP_Navigation_Block_Renderer {
519
519
  ';
520
520
  }
521
521
 
522
+ $overlay_inline_styles = esc_attr( safecss_filter_attr( $colors['overlay_inline_styles'] ) );
523
+
522
524
  return sprintf(
523
525
  '<button aria-haspopup="dialog" %3$s class="%6$s" %10$s>%8$s</button>
524
- <div class="%5$s" style="%7$s" id="%1$s" %11$s>
526
+ <div class="%5$s" %7$s id="%1$s" %11$s>
525
527
  <div class="wp-block-navigation__responsive-close" tabindex="-1">
526
528
  <div class="wp-block-navigation__responsive-dialog" %12$s>
527
529
  <button %4$s class="wp-block-navigation__responsive-container-close" %13$s>%9$s</button>
@@ -537,7 +539,7 @@ class WP_Navigation_Block_Renderer {
537
539
  $toggle_aria_label_close,
538
540
  esc_attr( implode( ' ', $responsive_container_classes ) ),
539
541
  esc_attr( implode( ' ', $open_button_classes ) ),
540
- esc_attr( safecss_filter_attr( $colors['overlay_inline_styles'] ) ),
542
+ ( ! empty( $overlay_inline_styles ) ) ? "style=\"$overlay_inline_styles\"" : '',
541
543
  $toggle_button_content,
542
544
  $toggle_close_button_content,
543
545
  $open_button_directives,
@@ -826,7 +828,7 @@ function block_core_navigation_add_directives_to_submenu( $tags, $block_attribut
826
828
  $tags->set_attribute( 'data-wp-interactive', 'core/navigation' );
827
829
  $tags->set_attribute( 'data-wp-context', '{ "submenuOpenedBy": { "click": false, "hover": false, "focus": false }, "type": "submenu" }' );
828
830
  $tags->set_attribute( 'data-wp-watch', 'callbacks.initMenu' );
829
- $tags->set_attribute( 'data-wp-on-async--focusout', 'actions.handleMenuFocusout' );
831
+ $tags->set_attribute( 'data-wp-on--focusout', 'actions.handleMenuFocusout' );
830
832
  $tags->set_attribute( 'data-wp-on--keydown', 'actions.handleMenuKeydown' );
831
833
 
832
834
  // This is a fix for Safari. Without it, Safari doesn't change the active
@@ -300,6 +300,7 @@ button.wp-block-navigation-item__content {
300
300
  color: currentColor;
301
301
  font-size: inherit;
302
302
  font-family: inherit;
303
+ letter-spacing: inherit;
303
304
  line-height: inherit;
304
305
  font-style: inherit;
305
306
  font-weight: inherit;
@@ -387,7 +387,7 @@ export default function NavigationSubmenuEdit( {
387
387
  title={ __( 'Convert to Link' ) }
388
388
  onClick={ transformToLink }
389
389
  className="wp-block-navigation__submenu__revert"
390
- isDisabled={ ! canConvertToLink }
390
+ disabled={ ! canConvertToLink }
391
391
  />
392
392
  </ToolbarGroup>
393
393
  </BlockControls>
@@ -36,7 +36,7 @@ export function ConvertToLinksModal( { onClick, onClose, disabled } ) {
36
36
  </Button>
37
37
  <Button
38
38
  variant="primary"
39
- __experimentalIsFocusable
39
+ accessibleWhenDisabled
40
40
  disabled={ disabled }
41
41
  onClick={ onClick }
42
42
  >
@@ -338,7 +338,7 @@ export default function PageListEdit( {
338
338
  <p>{ convertDescription }</p>
339
339
  <Button
340
340
  variant="primary"
341
- __experimentalIsFocusable
341
+ accessibleWhenDisabled
342
342
  disabled={ ! hasResolvedPages }
343
343
  onClick={ convertToNavigationLinks }
344
344
  >
@@ -1,5 +1,35 @@
1
1
  // Jest Snapshot v1, https://goo.gl/fbAQLP
2
2
 
3
+ exports[`Paragraph block should be able to use a prefix to create a Heading block 1`] = `
4
+ "<!-- wp:heading {"level":1} -->
5
+ <h1 class="wp-block-heading"></h1>
6
+ <!-- /wp:heading -->"
7
+ `;
8
+
9
+ exports[`Paragraph block should be able to use a prefix to create a List block 1`] = `
10
+ "<!-- wp:list -->
11
+ <ul class="wp-block-list"><!-- wp:list-item -->
12
+ <li></li>
13
+ <!-- /wp:list-item --></ul>
14
+ <!-- /wp:list -->"
15
+ `;
16
+
17
+ exports[`Paragraph block should be able to use a prefix to create a Quote block 1`] = `
18
+ "<!-- wp:quote -->
19
+ <blockquote class="wp-block-quote"><!-- wp:paragraph -->
20
+ <p></p>
21
+ <!-- /wp:paragraph --></blockquote>
22
+ <!-- /wp:quote -->"
23
+ `;
24
+
25
+ exports[`Paragraph block should be able to use a prefix to create a numbered List block 1`] = `
26
+ "<!-- wp:list {"ordered":true} -->
27
+ <ol class="wp-block-list"><!-- wp:list-item -->
28
+ <li></li>
29
+ <!-- /wp:list-item --></ol>
30
+ <!-- /wp:list -->"
31
+ `;
32
+
3
33
  exports[`Paragraph block should prevent deleting the first Paragraph block when pressing backspace at the start 1`] = `
4
34
  "<!-- wp:paragraph -->
5
35
  <p>A quick brown fox jumps over the lazy dog.</p>
@@ -90,6 +90,105 @@ describe( 'Paragraph block', () => {
90
90
  expect( getEditorHtml() ).toMatchSnapshot();
91
91
  } );
92
92
 
93
+ it( 'should be able to use a prefix to create a Heading block', async () => {
94
+ const screen = await initializeEditor();
95
+ await addBlock( screen, 'Paragraph' );
96
+ const text = '# ';
97
+
98
+ const paragraphBlock = getBlock( screen, 'Paragraph' );
99
+ fireEvent.press( paragraphBlock );
100
+ const paragraphTextInput =
101
+ within( paragraphBlock ).getByPlaceholderText( 'Start writing…' );
102
+ typeInRichText( paragraphTextInput, text, {
103
+ finalSelectionStart: 1,
104
+ finalSelectionEnd: 1,
105
+ } );
106
+
107
+ fireEvent( paragraphTextInput, 'onChange', {
108
+ nativeEvent: { text },
109
+ preventDefault() {},
110
+ } );
111
+
112
+ const headingBlock = getBlock( screen, 'Heading' );
113
+ expect( headingBlock ).toBeVisible();
114
+ expect( getEditorHtml() ).toMatchSnapshot();
115
+ } );
116
+
117
+ it( 'should be able to use a prefix to create a Quote block', async () => {
118
+ const screen = await initializeEditor();
119
+ await addBlock( screen, 'Paragraph' );
120
+ const text = '> ';
121
+
122
+ const paragraphBlock = getBlock( screen, 'Paragraph' );
123
+ fireEvent.press( paragraphBlock );
124
+ const paragraphTextInput =
125
+ within( paragraphBlock ).getByPlaceholderText( 'Start writing…' );
126
+ typeInRichText( paragraphTextInput, text, {
127
+ finalSelectionStart: 1,
128
+ finalSelectionEnd: 1,
129
+ } );
130
+
131
+ fireEvent( paragraphTextInput, 'onChange', {
132
+ nativeEvent: { text },
133
+ preventDefault() {},
134
+ } );
135
+ const quoteBlock = getBlock( screen, 'Quote' );
136
+ await triggerBlockListLayout( quoteBlock );
137
+
138
+ expect( quoteBlock ).toBeVisible();
139
+ expect( getEditorHtml() ).toMatchSnapshot();
140
+ } );
141
+
142
+ it( 'should be able to use a prefix to create a List block', async () => {
143
+ const screen = await initializeEditor();
144
+ await addBlock( screen, 'Paragraph' );
145
+ const text = '- ';
146
+
147
+ const paragraphBlock = getBlock( screen, 'Paragraph' );
148
+ fireEvent.press( paragraphBlock );
149
+ const paragraphTextInput =
150
+ within( paragraphBlock ).getByPlaceholderText( 'Start writing…' );
151
+ typeInRichText( paragraphTextInput, text, {
152
+ finalSelectionStart: 1,
153
+ finalSelectionEnd: 1,
154
+ } );
155
+
156
+ fireEvent( paragraphTextInput, 'onChange', {
157
+ nativeEvent: { text },
158
+ preventDefault() {},
159
+ } );
160
+ const listBlock = getBlock( screen, 'List' );
161
+ await triggerBlockListLayout( listBlock );
162
+
163
+ expect( listBlock ).toBeVisible();
164
+ expect( getEditorHtml() ).toMatchSnapshot();
165
+ } );
166
+
167
+ it( 'should be able to use a prefix to create a numbered List block', async () => {
168
+ const screen = await initializeEditor();
169
+ await addBlock( screen, 'Paragraph' );
170
+ const text = '1. ';
171
+
172
+ const paragraphBlock = getBlock( screen, 'Paragraph' );
173
+ fireEvent.press( paragraphBlock );
174
+ const paragraphTextInput =
175
+ within( paragraphBlock ).getByPlaceholderText( 'Start writing…' );
176
+ typeInRichText( paragraphTextInput, text, {
177
+ finalSelectionStart: 2,
178
+ finalSelectionEnd: 2,
179
+ } );
180
+
181
+ fireEvent( paragraphTextInput, 'onChange', {
182
+ nativeEvent: { text },
183
+ preventDefault() {},
184
+ } );
185
+ const listBlock = getBlock( screen, 'List' );
186
+ await triggerBlockListLayout( listBlock );
187
+
188
+ expect( listBlock ).toBeVisible();
189
+ expect( getEditorHtml() ).toMatchSnapshot();
190
+ } );
191
+
93
192
  it( 'should bold text', async () => {
94
193
  // Arrange
95
194
  const screen = await initializeEditor();
@@ -1,3 +1,18 @@
1
+ // Allow these default styles to be overridden by global styles.
2
+ :where(.wp-block-post-comments-form) {
3
+ textarea,
4
+ input:not([type="submit"]) {
5
+ border: 1px solid $gray-600;
6
+ font-size: 1em;
7
+ font-family: inherit;
8
+ }
9
+
10
+ textarea,
11
+ input:where(:not([type="submit"]):not([type="checkbox"])) {
12
+ padding: calc(0.667em + 2px); // The extra 2px is added to match outline buttons.
13
+ }
14
+ }
15
+
1
16
  .wp-block-post-comments-form {
2
17
  // This block has customizable padding, border-box makes that more predictable.
3
18
  box-sizing: border-box;
@@ -31,18 +46,6 @@
31
46
  overflow-wrap: break-word;
32
47
  }
33
48
 
34
- textarea,
35
- input:not([type="submit"]) {
36
- border: 1px solid $gray-600;
37
- font-size: 1em;
38
- font-family: inherit;
39
- }
40
-
41
- textarea,
42
- input:not([type="submit"]):not([type="checkbox"]) {
43
- padding: calc(0.667em + 2px); // The extra 2px is added to match outline buttons.
44
- }
45
-
46
49
  .comment-form {
47
50
  textarea,
48
51
  // Make sure to not set display block on hidden input fields, to prevent
@@ -7,6 +7,9 @@
7
7
  "description": "Displays the contents of a post or page.",
8
8
  "textdomain": "default",
9
9
  "usesContext": [ "postId", "postType", "queryId" ],
10
+ "example": {
11
+ "viewportWidth": 350
12
+ },
10
13
  "supports": {
11
14
  "align": [ "wide", "full" ],
12
15
  "html": false,
@@ -28,7 +28,7 @@ import {
28
28
  ToggleControl,
29
29
  PanelBody,
30
30
  } from '@wordpress/components';
31
- import { __, sprintf } from '@wordpress/i18n';
31
+ import { __, _x, sprintf } from '@wordpress/i18n';
32
32
  import { edit } from '@wordpress/icons';
33
33
  import { DOWN } from '@wordpress/keycodes';
34
34
  import { useSelect } from '@wordpress/data';
@@ -128,6 +128,10 @@ export default function PostDateEdit( {
128
128
  siteTimeFormat
129
129
  ) }
130
130
  onClose={ onClose }
131
+ dateOrder={
132
+ /* translators: Order of day, month, and year. Available formats are 'dmy', 'mdy', and 'ymd'. */
133
+ _x( 'dmy', 'date order' )
134
+ }
131
135
  />
132
136
  ) }
133
137
  renderToggle={ ( { isOpen, onToggle } ) => {
@@ -23,8 +23,14 @@ function render_block_core_post_date( $attributes, $content, $block ) {
23
23
  $post_ID = $block->context['postId'];
24
24
 
25
25
  if ( isset( $attributes['format'] ) && 'human-diff' === $attributes['format'] ) {
26
- // translators: %s: human-readable time difference.
27
- $formatted_date = sprintf( __( '%s ago', 'gutenberg' ), human_time_diff( get_post_timestamp( $post_ID ) ) );
26
+ $post_timestamp = get_post_timestamp( $post_ID );
27
+ if ( $post_timestamp > time() ) {
28
+ // translators: %s: human-readable time difference.
29
+ $formatted_date = sprintf( __( '%s from now', 'gutenberg' ), human_time_diff( $post_timestamp ) );
30
+ } else {
31
+ // translators: %s: human-readable time difference.
32
+ $formatted_date = sprintf( __( '%s ago', 'gutenberg' ), human_time_diff( $post_timestamp ) );
33
+ }
28
34
  } else {
29
35
  $formatted_date = get_the_date( empty( $attributes['format'] ) ? '' : $attributes['format'], $post_ID );
30
36
  }
@@ -44,7 +50,7 @@ function render_block_core_post_date( $attributes, $content, $block ) {
44
50
  */
45
51
  if ( isset( $attributes['displayType'] ) && 'modified' === $attributes['displayType'] ) {
46
52
  if ( get_the_modified_date( 'Ymdhi', $post_ID ) > get_the_date( 'Ymdhi', $post_ID ) ) {
47
- if ( 'human-diff' === $attributes['format'] ) {
53
+ if ( isset( $attributes['format'] ) && 'human-diff' === $attributes['format'] ) {
48
54
  // translators: %s: human-readable time difference.
49
55
  $formatted_date = sprintf( __( '%s ago', 'gutenberg' ), human_time_diff( get_post_timestamp( $post_ID, 'modified' ) ) );
50
56
  } else {
@@ -23,6 +23,9 @@
23
23
  }
24
24
  },
25
25
  "usesContext": [ "postId", "postType", "queryId" ],
26
+ "example": {
27
+ "viewportWidth": 350
28
+ },
26
29
  "supports": {
27
30
  "html": false,
28
31
  "color": {
@@ -29,6 +29,9 @@
29
29
  "default": "_self"
30
30
  }
31
31
  },
32
+ "example": {
33
+ "viewportWidth": 350
34
+ },
32
35
  "supports": {
33
36
  "align": [ "wide", "full" ],
34
37
  "html": false,
@@ -34,7 +34,7 @@ import {
34
34
  isControlAllowed,
35
35
  useTaxonomies,
36
36
  } from '../../utils';
37
- import { TOOLSPANEL_DROPDOWNMENU_PROPS } from '../../../utils/constants';
37
+ import { useToolsPanelDropdownMenuProps } from '../../../utils/hooks';
38
38
 
39
39
  const { BlockInfo } = unlock( blockEditorPrivateApis );
40
40
 
@@ -128,6 +128,7 @@ export default function QueryInspectorControls( props ) {
128
128
  showAuthorControl ||
129
129
  showSearchControl ||
130
130
  showParentControl;
131
+ const dropdownMenuProps = useToolsPanelDropdownMenuProps();
131
132
 
132
133
  return (
133
134
  <>
@@ -223,7 +224,7 @@ export default function QueryInspectorControls( props ) {
223
224
  } );
224
225
  setQuerySearch( '' );
225
226
  } }
226
- dropdownMenuProps={ TOOLSPANEL_DROPDOWNMENU_PROPS }
227
+ dropdownMenuProps={ dropdownMenuProps }
227
228
  >
228
229
  { showTaxControl && (
229
230
  <ToolsPanelItem