@wordpress/block-library 8.14.0 → 8.16.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 (365) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/build/avatar/edit.js +1 -0
  3. package/build/avatar/edit.js.map +1 -1
  4. package/build/avatar/index.js +3 -0
  5. package/build/avatar/index.js.map +1 -1
  6. package/build/block/edit.js +2 -30
  7. package/build/block/edit.js.map +1 -1
  8. package/build/block/index.js +2 -1
  9. package/build/block/index.js.map +1 -1
  10. package/build/buttons/edit.js +2 -2
  11. package/build/buttons/edit.js.map +1 -1
  12. package/build/column/edit.native.js +1 -4
  13. package/build/column/edit.native.js.map +1 -1
  14. package/build/columns/edit.js +1 -0
  15. package/build/columns/edit.js.map +1 -1
  16. package/build/comment-author-avatar/edit.js +1 -0
  17. package/build/comment-author-avatar/edit.js.map +1 -1
  18. package/build/cover/deprecated.js +4 -2
  19. package/build/cover/deprecated.js.map +1 -1
  20. package/build/cover/index.js +2 -1
  21. package/build/cover/index.js.map +1 -1
  22. package/build/embed/embed-placeholder.native.js +37 -13
  23. package/build/embed/embed-placeholder.native.js.map +1 -1
  24. package/build/file/index.js +1 -2
  25. package/build/file/index.js.map +1 -1
  26. package/build/file/inspector.js +1 -0
  27. package/build/file/inspector.js.map +1 -1
  28. package/build/file/view-interactivity.js +23 -0
  29. package/build/file/view-interactivity.js.map +1 -0
  30. package/build/file/view.js +1 -15
  31. package/build/file/view.js.map +1 -1
  32. package/build/footnotes/edit.js +31 -1
  33. package/build/footnotes/edit.js.map +1 -1
  34. package/build/footnotes/format.js +119 -23
  35. package/build/footnotes/format.js.map +1 -1
  36. package/build/footnotes/index.js +45 -4
  37. package/build/footnotes/index.js.map +1 -1
  38. package/build/gallery/edit.js +8 -6
  39. package/build/gallery/edit.js.map +1 -1
  40. package/build/image/deprecated.js +106 -2
  41. package/build/image/deprecated.js.map +1 -1
  42. package/build/image/image.js +2 -2
  43. package/build/image/image.js.map +1 -1
  44. package/build/image/index.js +2 -1
  45. package/build/image/index.js.map +1 -1
  46. package/build/index.js +3 -1
  47. package/build/index.js.map +1 -1
  48. package/build/latest-comments/edit.js +1 -0
  49. package/build/latest-comments/edit.js.map +1 -1
  50. package/build/latest-posts/edit.js +2 -0
  51. package/build/latest-posts/edit.js.map +1 -1
  52. package/build/list/edit.js +4 -4
  53. package/build/list/edit.js.map +1 -1
  54. package/build/list-item/hooks/use-merge.js +10 -1
  55. package/build/list-item/hooks/use-merge.js.map +1 -1
  56. package/build/media-text/media-container.native.js +2 -1
  57. package/build/media-text/media-container.native.js.map +1 -1
  58. package/build/missing/edit.native.js +7 -5
  59. package/build/missing/edit.native.js.map +1 -1
  60. package/build/navigation/constants.js +10 -4
  61. package/build/navigation/constants.js.map +1 -1
  62. package/build/navigation/edit/index.js +16 -2
  63. package/build/navigation/edit/index.js.map +1 -1
  64. package/build/navigation/edit/inner-blocks.js +2 -2
  65. package/build/navigation/edit/inner-blocks.js.map +1 -1
  66. package/build/navigation/edit/menu-inspector-controls.js +1 -1
  67. package/build/navigation/edit/menu-inspector-controls.js.map +1 -1
  68. package/build/navigation/edit/navigation-menu-selector.js +4 -4
  69. package/build/navigation/edit/navigation-menu-selector.js.map +1 -1
  70. package/build/navigation/edit/unsaved-inner-blocks.js +2 -2
  71. package/build/navigation/edit/unsaved-inner-blocks.js.map +1 -1
  72. package/build/navigation/edit/use-convert-classic-menu-to-block-menu.js +10 -15
  73. package/build/navigation/edit/use-convert-classic-menu-to-block-menu.js.map +1 -1
  74. package/build/navigation/index.js +2 -3
  75. package/build/navigation/index.js.map +1 -1
  76. package/build/navigation/use-navigation-menu.js +33 -45
  77. package/build/navigation/use-navigation-menu.js.map +1 -1
  78. package/build/navigation/view-interactivity.js +185 -0
  79. package/build/navigation/view-interactivity.js.map +1 -0
  80. package/build/navigation/view-modal.js +125 -0
  81. package/build/navigation/view-modal.js.map +1 -0
  82. package/build/navigation/view.js +71 -163
  83. package/build/navigation/view.js.map +1 -1
  84. package/build/navigation-link/edit.js +12 -7
  85. package/build/navigation-link/edit.js.map +1 -1
  86. package/build/navigation-submenu/edit.js +2 -2
  87. package/build/navigation-submenu/edit.js.map +1 -1
  88. package/build/pattern/edit.js +28 -4
  89. package/build/pattern/edit.js.map +1 -1
  90. package/build/preformatted/index.js +4 -0
  91. package/build/preformatted/index.js.map +1 -1
  92. package/build/query-pagination/edit.js +1 -1
  93. package/build/query-pagination/edit.js.map +1 -1
  94. package/build/query-title/edit.js +43 -1
  95. package/build/query-title/edit.js.map +1 -1
  96. package/build/quote/transforms.js +8 -0
  97. package/build/quote/transforms.js.map +1 -1
  98. package/build/rss/edit.js +3 -0
  99. package/build/rss/edit.js.map +1 -1
  100. package/build/search/edit.js +4 -3
  101. package/build/search/edit.js.map +1 -1
  102. package/build/search/index.js +1 -0
  103. package/build/search/index.js.map +1 -1
  104. package/build/search/view.js +166 -62
  105. package/build/search/view.js.map +1 -1
  106. package/build/site-logo/edit.js +1 -0
  107. package/build/site-logo/edit.js.map +1 -1
  108. package/build/social-link/icons/index.js +13 -0
  109. package/build/social-link/icons/index.js.map +1 -1
  110. package/build/social-link/icons/threads.js +25 -0
  111. package/build/social-link/icons/threads.js.map +1 -0
  112. package/build/social-link/variations.js +7 -0
  113. package/build/social-link/variations.js.map +1 -1
  114. package/build/tag-cloud/edit.js +1 -0
  115. package/build/tag-cloud/edit.js.map +1 -1
  116. package/build/template-part/edit/import-controls.js +1 -1
  117. package/build/template-part/edit/import-controls.js.map +1 -1
  118. package/build/template-part/edit/index.js +1 -1
  119. package/build/template-part/edit/index.js.map +1 -1
  120. package/build/text-columns/edit.js +1 -0
  121. package/build/text-columns/edit.js.map +1 -1
  122. package/build-module/avatar/edit.js +1 -0
  123. package/build-module/avatar/edit.js.map +1 -1
  124. package/build-module/avatar/index.js +3 -0
  125. package/build-module/avatar/index.js.map +1 -1
  126. package/build-module/block/edit.js +4 -29
  127. package/build-module/block/edit.js.map +1 -1
  128. package/build-module/block/index.js +2 -1
  129. package/build-module/block/index.js.map +1 -1
  130. package/build-module/buttons/edit.js +2 -2
  131. package/build-module/buttons/edit.js.map +1 -1
  132. package/build-module/column/edit.native.js +1 -4
  133. package/build-module/column/edit.native.js.map +1 -1
  134. package/build-module/columns/edit.js +1 -0
  135. package/build-module/columns/edit.js.map +1 -1
  136. package/build-module/comment-author-avatar/edit.js +1 -0
  137. package/build-module/comment-author-avatar/edit.js.map +1 -1
  138. package/build-module/cover/deprecated.js +4 -2
  139. package/build-module/cover/deprecated.js.map +1 -1
  140. package/build-module/cover/index.js +2 -1
  141. package/build-module/cover/index.js.map +1 -1
  142. package/build-module/embed/embed-placeholder.native.js +37 -14
  143. package/build-module/embed/embed-placeholder.native.js.map +1 -1
  144. package/build-module/file/index.js +1 -2
  145. package/build-module/file/index.js.map +1 -1
  146. package/build-module/file/inspector.js +1 -0
  147. package/build-module/file/inspector.js.map +1 -1
  148. package/build-module/file/view-interactivity.js +19 -0
  149. package/build-module/file/view-interactivity.js.map +1 -0
  150. package/build-module/file/view.js +2 -15
  151. package/build-module/file/view.js.map +1 -1
  152. package/build-module/footnotes/edit.js +29 -2
  153. package/build-module/footnotes/edit.js.map +1 -1
  154. package/build-module/footnotes/format.js +120 -25
  155. package/build-module/footnotes/format.js.map +1 -1
  156. package/build-module/footnotes/index.js +45 -4
  157. package/build-module/footnotes/index.js.map +1 -1
  158. package/build-module/gallery/edit.js +8 -6
  159. package/build-module/gallery/edit.js.map +1 -1
  160. package/build-module/image/deprecated.js +107 -3
  161. package/build-module/image/deprecated.js.map +1 -1
  162. package/build-module/image/image.js +2 -2
  163. package/build-module/image/image.js.map +1 -1
  164. package/build-module/image/index.js +2 -1
  165. package/build-module/image/index.js.map +1 -1
  166. package/build-module/index.js +3 -1
  167. package/build-module/index.js.map +1 -1
  168. package/build-module/latest-comments/edit.js +1 -0
  169. package/build-module/latest-comments/edit.js.map +1 -1
  170. package/build-module/latest-posts/edit.js +2 -0
  171. package/build-module/latest-posts/edit.js.map +1 -1
  172. package/build-module/list/edit.js +4 -4
  173. package/build-module/list/edit.js.map +1 -1
  174. package/build-module/list-item/hooks/use-merge.js +10 -1
  175. package/build-module/list-item/hooks/use-merge.js.map +1 -1
  176. package/build-module/media-text/media-container.native.js +2 -1
  177. package/build-module/media-text/media-container.native.js.map +1 -1
  178. package/build-module/missing/edit.native.js +8 -6
  179. package/build-module/missing/edit.native.js.map +1 -1
  180. package/build-module/navigation/constants.js +8 -3
  181. package/build-module/navigation/constants.js.map +1 -1
  182. package/build-module/navigation/edit/index.js +17 -3
  183. package/build-module/navigation/edit/index.js.map +1 -1
  184. package/build-module/navigation/edit/inner-blocks.js +2 -2
  185. package/build-module/navigation/edit/inner-blocks.js.map +1 -1
  186. package/build-module/navigation/edit/menu-inspector-controls.js +1 -1
  187. package/build-module/navigation/edit/menu-inspector-controls.js.map +1 -1
  188. package/build-module/navigation/edit/navigation-menu-selector.js +4 -4
  189. package/build-module/navigation/edit/navigation-menu-selector.js.map +1 -1
  190. package/build-module/navigation/edit/unsaved-inner-blocks.js +2 -2
  191. package/build-module/navigation/edit/unsaved-inner-blocks.js.map +1 -1
  192. package/build-module/navigation/edit/use-convert-classic-menu-to-block-menu.js +10 -14
  193. package/build-module/navigation/edit/use-convert-classic-menu-to-block-menu.js.map +1 -1
  194. package/build-module/navigation/index.js +2 -3
  195. package/build-module/navigation/index.js.map +1 -1
  196. package/build-module/navigation/use-navigation-menu.js +35 -47
  197. package/build-module/navigation/use-navigation-menu.js.map +1 -1
  198. package/build-module/navigation/view-interactivity.js +182 -0
  199. package/build-module/navigation/view-interactivity.js.map +1 -0
  200. package/build-module/navigation/view-modal.js +120 -0
  201. package/build-module/navigation/view-modal.js.map +1 -0
  202. package/build-module/navigation/view.js +72 -163
  203. package/build-module/navigation/view.js.map +1 -1
  204. package/build-module/navigation-link/edit.js +12 -7
  205. package/build-module/navigation-link/edit.js.map +1 -1
  206. package/build-module/navigation-submenu/edit.js +2 -2
  207. package/build-module/navigation-submenu/edit.js.map +1 -1
  208. package/build-module/pattern/edit.js +27 -4
  209. package/build-module/pattern/edit.js.map +1 -1
  210. package/build-module/preformatted/index.js +4 -0
  211. package/build-module/preformatted/index.js.map +1 -1
  212. package/build-module/query-pagination/edit.js +1 -1
  213. package/build-module/query-pagination/edit.js.map +1 -1
  214. package/build-module/query-title/edit.js +44 -3
  215. package/build-module/query-title/edit.js.map +1 -1
  216. package/build-module/quote/transforms.js +8 -0
  217. package/build-module/quote/transforms.js.map +1 -1
  218. package/build-module/rss/edit.js +3 -0
  219. package/build-module/rss/edit.js.map +1 -1
  220. package/build-module/search/edit.js +4 -3
  221. package/build-module/search/edit.js.map +1 -1
  222. package/build-module/search/index.js +1 -0
  223. package/build-module/search/index.js.map +1 -1
  224. package/build-module/search/view.js +166 -62
  225. package/build-module/search/view.js.map +1 -1
  226. package/build-module/site-logo/edit.js +1 -0
  227. package/build-module/site-logo/edit.js.map +1 -1
  228. package/build-module/social-link/icons/index.js +1 -0
  229. package/build-module/social-link/icons/index.js.map +1 -1
  230. package/build-module/social-link/icons/threads.js +15 -0
  231. package/build-module/social-link/icons/threads.js.map +1 -0
  232. package/build-module/social-link/variations.js +8 -1
  233. package/build-module/social-link/variations.js.map +1 -1
  234. package/build-module/tag-cloud/edit.js +1 -0
  235. package/build-module/tag-cloud/edit.js.map +1 -1
  236. package/build-module/template-part/edit/import-controls.js +2 -2
  237. package/build-module/template-part/edit/import-controls.js.map +1 -1
  238. package/build-module/template-part/edit/index.js +1 -1
  239. package/build-module/template-part/edit/index.js.map +1 -1
  240. package/build-module/text-columns/edit.js +1 -0
  241. package/build-module/text-columns/edit.js.map +1 -1
  242. package/build-style/details/style-rtl.css +4 -2
  243. package/build-style/details/style.css +4 -2
  244. package/build-style/footnotes/style-rtl.css +4 -3
  245. package/build-style/footnotes/style.css +4 -3
  246. package/build-style/navigation/style-rtl.css +14 -2
  247. package/build-style/navigation/style.css +14 -2
  248. package/build-style/preformatted/style-rtl.css +2 -1
  249. package/build-style/preformatted/style.css +2 -1
  250. package/build-style/query-pagination/style-rtl.css +4 -2
  251. package/build-style/query-pagination/style.css +4 -2
  252. package/build-style/social-links/style-rtl.css +7 -0
  253. package/build-style/social-links/style.css +7 -0
  254. package/build-style/style-rtl.css +36 -10
  255. package/build-style/style.css +36 -10
  256. package/build-style/video/style-rtl.css +1 -0
  257. package/build-style/video/style.css +1 -0
  258. package/package.json +33 -32
  259. package/src/audio/test/__snapshots__/edit.native.js.snap +118 -33
  260. package/src/avatar/block.json +3 -0
  261. package/src/avatar/edit.js +1 -0
  262. package/src/block/block.json +2 -1
  263. package/src/block/edit.js +1 -39
  264. package/src/block/editor.native.scss +2 -2
  265. package/src/buttons/edit.js +2 -2
  266. package/src/buttons/test/edit.native.js +4 -0
  267. package/src/column/edit.native.js +4 -10
  268. package/src/column/editor.native.scss +0 -4
  269. package/src/columns/edit.js +1 -0
  270. package/src/columns/test/edit.native.js +5 -0
  271. package/src/comment-author-avatar/edit.js +1 -0
  272. package/src/comment-template/index.php +7 -2
  273. package/src/cover/block.json +2 -1
  274. package/src/cover/deprecated.js +2 -0
  275. package/src/cover/test/edit.native.js +8 -0
  276. package/src/embed/embed-placeholder.native.js +80 -47
  277. package/src/embed/styles.native.scss +54 -18
  278. package/src/embed/test/index.native.js +13 -5
  279. package/src/file/block.json +1 -2
  280. package/src/file/index.php +20 -2
  281. package/src/file/inspector.js +1 -0
  282. package/src/file/test/__snapshots__/edit.native.js.snap +119 -33
  283. package/src/file/view-interactivity.js +18 -0
  284. package/src/file/view.js +5 -14
  285. package/src/footnotes/block.json +44 -2
  286. package/src/footnotes/edit.js +33 -2
  287. package/src/footnotes/format.js +90 -25
  288. package/src/footnotes/index.js +0 -1
  289. package/src/footnotes/index.php +207 -0
  290. package/src/footnotes/style.scss +6 -3
  291. package/src/gallery/edit.js +42 -38
  292. package/src/gallery/test/index.native.js +31 -18
  293. package/src/heading/test/index.native.js +4 -0
  294. package/src/home-link/index.php +15 -2
  295. package/src/image/block.json +2 -1
  296. package/src/image/deprecated.js +109 -3
  297. package/src/image/image.js +2 -2
  298. package/src/image/index.php +45 -8
  299. package/src/image/test/edit.native.js +1 -2
  300. package/src/index.js +5 -1
  301. package/src/latest-comments/edit.js +1 -0
  302. package/src/latest-posts/edit.js +2 -0
  303. package/src/list/edit.js +6 -4
  304. package/src/list/test/edit.native.js +134 -33
  305. package/src/list-item/hooks/use-merge.js +12 -5
  306. package/src/media-text/media-container.native.js +1 -0
  307. package/src/missing/edit.native.js +12 -10
  308. package/src/missing/style.native.scss +19 -12
  309. package/src/missing/test/__snapshots__/edit.native.js.snap +42 -13
  310. package/src/navigation/block.json +2 -3
  311. package/src/navigation/constants.js +12 -6
  312. package/src/navigation/edit/index.js +29 -1
  313. package/src/navigation/edit/inner-blocks.js +2 -2
  314. package/src/navigation/edit/menu-inspector-controls.js +1 -1
  315. package/src/navigation/edit/navigation-menu-selector.js +8 -4
  316. package/src/navigation/edit/unsaved-inner-blocks.js +2 -2
  317. package/src/navigation/edit/use-convert-classic-menu-to-block-menu.js +17 -21
  318. package/src/navigation/index.php +50 -18
  319. package/src/navigation/style.scss +27 -8
  320. package/src/navigation/use-navigation-menu.js +39 -63
  321. package/src/navigation/view-interactivity.js +196 -0
  322. package/src/navigation/view-modal.js +127 -0
  323. package/src/navigation/view.js +96 -185
  324. package/src/navigation-link/edit.js +61 -47
  325. package/src/navigation-submenu/edit.js +2 -2
  326. package/src/paragraph/test/__snapshots__/edit.native.js.snap +1 -0
  327. package/src/paragraph/test/edit.native.js +81 -35
  328. package/src/pattern/edit.js +21 -0
  329. package/src/pattern/index.php +13 -1
  330. package/src/post-template/index.php +6 -2
  331. package/src/post-title/index.php +8 -3
  332. package/src/preformatted/block.json +4 -0
  333. package/src/preformatted/style.scss +4 -1
  334. package/src/preformatted/test/__snapshots__/edit.native.js.snap +2 -0
  335. package/src/pullquote/test/edit.native.js +12 -4
  336. package/src/query-pagination/edit.js +17 -14
  337. package/src/query-title/edit.js +48 -6
  338. package/src/quote/test/__snapshots__/transforms.native.js.snap +10 -0
  339. package/src/quote/test/edit.native.js +12 -4
  340. package/src/quote/test/transforms.native.js +5 -1
  341. package/src/quote/transforms.js +13 -0
  342. package/src/rss/edit.js +3 -0
  343. package/src/search/block.json +1 -0
  344. package/src/search/edit.js +4 -3
  345. package/src/search/index.php +26 -4
  346. package/src/search/test/__snapshots__/edit.native.js.snap +70 -0
  347. package/src/search/view.js +171 -67
  348. package/src/site-logo/edit.js +1 -0
  349. package/src/social-link/icons/index.js +1 -0
  350. package/src/social-link/icons/threads.js +10 -0
  351. package/src/social-link/index.php +4 -0
  352. package/src/social-link/socials-with-bg.scss +5 -0
  353. package/src/social-link/socials-without-bg.scss +4 -0
  354. package/src/social-link/variations.js +7 -0
  355. package/src/tag-cloud/edit.js +1 -0
  356. package/src/template-part/edit/import-controls.js +2 -2
  357. package/src/template-part/edit/index.js +1 -1
  358. package/src/template-part/index.php +7 -16
  359. package/src/text-columns/edit.js +1 -0
  360. package/src/video/style.scss +1 -0
  361. package/build/gallery/shared-icon.native.js +0 -38
  362. package/build/gallery/shared-icon.native.js.map +0 -1
  363. package/build-module/gallery/shared-icon.native.js +0 -24
  364. package/build-module/gallery/shared-icon.native.js.map +0 -1
  365. package/src/gallery/shared-icon.native.js +0 -23
@@ -20,6 +20,15 @@ exports[`Search Block renders block with button inside option 1`] = `
20
20
  }
21
21
  >
22
22
  <RCTAztecView
23
+ accessibilityState={
24
+ {
25
+ "busy": undefined,
26
+ "checked": undefined,
27
+ "disabled": undefined,
28
+ "expanded": undefined,
29
+ "selected": undefined,
30
+ }
31
+ }
23
32
  accessible={true}
24
33
  activeFormats={[]}
25
34
  blockType={
@@ -52,6 +61,7 @@ exports[`Search Block renders block with button inside option 1`] = `
52
61
  onStartShouldSetResponder={[Function]}
53
62
  placeholder="Add label…"
54
63
  placeholderTextColor="gray"
64
+ selectionColor="black"
55
65
  style={
56
66
  {
57
67
  "backgroundColor": undefined,
@@ -135,6 +145,15 @@ exports[`Search Block renders block with button inside option 1`] = `
135
145
  }
136
146
  >
137
147
  <RCTAztecView
148
+ accessibilityState={
149
+ {
150
+ "busy": undefined,
151
+ "checked": undefined,
152
+ "disabled": undefined,
153
+ "expanded": undefined,
154
+ "selected": undefined,
155
+ }
156
+ }
138
157
  accessible={true}
139
158
  activeFormats={[]}
140
159
  blockType={
@@ -168,6 +187,7 @@ exports[`Search Block renders block with button inside option 1`] = `
168
187
  onStartShouldSetResponder={[Function]}
169
188
  placeholder=""
170
189
  placeholderTextColor="gray"
190
+ selectionColor="black"
171
191
  style={
172
192
  {
173
193
  "backgroundColor": undefined,
@@ -214,6 +234,15 @@ exports[`Search Block renders block with icon button option matches snapshot 1`]
214
234
  }
215
235
  >
216
236
  <RCTAztecView
237
+ accessibilityState={
238
+ {
239
+ "busy": undefined,
240
+ "checked": undefined,
241
+ "disabled": undefined,
242
+ "expanded": undefined,
243
+ "selected": undefined,
244
+ }
245
+ }
217
246
  accessible={true}
218
247
  activeFormats={[]}
219
248
  blockType={
@@ -246,6 +275,7 @@ exports[`Search Block renders block with icon button option matches snapshot 1`]
246
275
  onStartShouldSetResponder={[Function]}
247
276
  placeholder="Add label…"
248
277
  placeholderTextColor="gray"
278
+ selectionColor="black"
249
279
  style={
250
280
  {
251
281
  "backgroundColor": undefined,
@@ -399,6 +429,15 @@ exports[`Search Block renders block with label hidden matches snapshot 1`] = `
399
429
  }
400
430
  >
401
431
  <RCTAztecView
432
+ accessibilityState={
433
+ {
434
+ "busy": undefined,
435
+ "checked": undefined,
436
+ "disabled": undefined,
437
+ "expanded": undefined,
438
+ "selected": undefined,
439
+ }
440
+ }
402
441
  accessible={true}
403
442
  activeFormats={[]}
404
443
  blockType={
@@ -432,6 +471,7 @@ exports[`Search Block renders block with label hidden matches snapshot 1`] = `
432
471
  onStartShouldSetResponder={[Function]}
433
472
  placeholder=""
434
473
  placeholderTextColor="gray"
474
+ selectionColor="black"
435
475
  style={
436
476
  {
437
477
  "backgroundColor": undefined,
@@ -478,6 +518,15 @@ exports[`Search Block renders with default configuration matches snapshot 1`] =
478
518
  }
479
519
  >
480
520
  <RCTAztecView
521
+ accessibilityState={
522
+ {
523
+ "busy": undefined,
524
+ "checked": undefined,
525
+ "disabled": undefined,
526
+ "expanded": undefined,
527
+ "selected": undefined,
528
+ }
529
+ }
481
530
  accessible={true}
482
531
  activeFormats={[]}
483
532
  blockType={
@@ -510,6 +559,7 @@ exports[`Search Block renders with default configuration matches snapshot 1`] =
510
559
  onStartShouldSetResponder={[Function]}
511
560
  placeholder="Add label…"
512
561
  placeholderTextColor="gray"
562
+ selectionColor="black"
513
563
  style={
514
564
  {
515
565
  "backgroundColor": undefined,
@@ -593,6 +643,15 @@ exports[`Search Block renders with default configuration matches snapshot 1`] =
593
643
  }
594
644
  >
595
645
  <RCTAztecView
646
+ accessibilityState={
647
+ {
648
+ "busy": undefined,
649
+ "checked": undefined,
650
+ "disabled": undefined,
651
+ "expanded": undefined,
652
+ "selected": undefined,
653
+ }
654
+ }
596
655
  accessible={true}
597
656
  activeFormats={[]}
598
657
  blockType={
@@ -626,6 +685,7 @@ exports[`Search Block renders with default configuration matches snapshot 1`] =
626
685
  onStartShouldSetResponder={[Function]}
627
686
  placeholder=""
628
687
  placeholderTextColor="gray"
688
+ selectionColor="black"
629
689
  style={
630
690
  {
631
691
  "backgroundColor": undefined,
@@ -672,6 +732,15 @@ exports[`Search Block renders with no-button option matches snapshot 1`] = `
672
732
  }
673
733
  >
674
734
  <RCTAztecView
735
+ accessibilityState={
736
+ {
737
+ "busy": undefined,
738
+ "checked": undefined,
739
+ "disabled": undefined,
740
+ "expanded": undefined,
741
+ "selected": undefined,
742
+ }
743
+ }
675
744
  accessible={true}
676
745
  activeFormats={[]}
677
746
  blockType={
@@ -704,6 +773,7 @@ exports[`Search Block renders with no-button option matches snapshot 1`] = `
704
773
  onStartShouldSetResponder={[Function]}
705
774
  placeholder="Add label…"
706
775
  placeholderTextColor="gray"
776
+ selectionColor="black"
707
777
  style={
708
778
  {
709
779
  "backgroundColor": undefined,
@@ -1,68 +1,172 @@
1
- window.addEventListener( 'DOMContentLoaded', () => {
2
- const hiddenClass = 'wp-block-search__searchfield-hidden';
3
-
4
- Array.from(
5
- document.getElementsByClassName(
6
- 'wp-block-search__button-behavior-expand'
7
- )
8
- ).forEach( ( block ) => {
9
- const searchField = block.querySelector( '.wp-block-search__input' );
10
- const searchButton = block.querySelector( '.wp-block-search__button' );
11
- const searchLabel = block.querySelector( '.wp-block-search__label' );
12
- const ariaLabel = searchButton.getAttribute( 'aria-label' );
13
- const id = searchField.getAttribute( 'id' );
14
-
15
- const toggleSearchField = ( showSearchField ) => {
16
- if ( showSearchField ) {
17
- searchField.removeAttribute( 'aria-hidden' );
18
- searchField.removeAttribute( 'tabindex' );
19
- searchButton.removeAttribute( 'aria-expanded' );
20
- searchButton.removeAttribute( 'aria-controls' );
21
- searchButton.setAttribute( 'type', 'submit' );
22
- searchButton.setAttribute( 'aria-label', 'Submit Search' );
23
-
24
- return block.classList.remove( hiddenClass );
25
- }
26
-
27
- searchButton.removeAttribute( 'type' );
28
- searchField.setAttribute( 'aria-hidden', 'true' );
29
- searchField.setAttribute( 'tabindex', '-1' );
30
- searchButton.setAttribute( 'aria-expanded', 'false' );
31
- searchButton.setAttribute( 'aria-controls', id );
32
- searchButton.setAttribute( 'aria-label', ariaLabel );
33
- return block.classList.add( hiddenClass );
34
- };
35
-
36
- const hideSearchField = ( e ) => {
37
- if ( ! e.target.closest( '.wp-block-search' ) ) {
38
- return toggleSearchField( false );
39
- }
40
-
41
- if ( e.key === 'Escape' ) {
42
- searchButton.focus();
43
- return toggleSearchField( false );
44
- }
45
- };
46
-
47
- const handleButtonClick = ( e ) => {
48
- if ( block.classList.contains( hiddenClass ) ) {
49
- e.preventDefault();
50
- searchField.focus();
51
- toggleSearchField( true );
52
- }
53
- };
54
-
55
- searchButton.removeAttribute( 'type' );
56
- searchField.addEventListener( 'keydown', ( e ) => {
57
- hideSearchField( e );
58
- } );
59
- searchButton.addEventListener( 'click', handleButtonClick );
60
- searchButton.addEventListener( 'keydown', ( e ) => {
61
- hideSearchField( e );
62
- } );
63
- if ( searchLabel ) {
64
- searchLabel.addEventListener( 'click', handleButtonClick );
65
- }
66
- document.body.addEventListener( 'click', hideSearchField );
1
+ /*eslint-env browser*/
2
+
3
+ /** @type {?HTMLFormElement} */
4
+ let expandedSearchBlock = null;
5
+
6
+ const hiddenClass = 'wp-block-search__searchfield-hidden';
7
+
8
+ /**
9
+ * Toggles aria-label with data-toggled-aria-label.
10
+ *
11
+ * @param {HTMLElement} element
12
+ */
13
+ function toggleAriaLabel( element ) {
14
+ if ( ! ( 'toggledAriaLabel' in element.dataset ) ) {
15
+ throw new Error( 'Element lacks toggledAriaLabel in dataset.' );
16
+ }
17
+
18
+ const ariaLabel = element.dataset.toggledAriaLabel;
19
+ element.dataset.toggledAriaLabel = element.ariaLabel;
20
+ element.ariaLabel = ariaLabel;
21
+ }
22
+
23
+ /**
24
+ * Gets search input.
25
+ *
26
+ * @param {HTMLFormElement} block Search block.
27
+ * @return {HTMLInputElement} Search input.
28
+ */
29
+ function getSearchInput( block ) {
30
+ return block.querySelector( '.wp-block-search__input' );
31
+ }
32
+
33
+ /**
34
+ * Gets search button.
35
+ *
36
+ * @param {HTMLFormElement} block Search block.
37
+ * @return {HTMLButtonElement} Search button.
38
+ */
39
+ function getSearchButton( block ) {
40
+ return block.querySelector( '.wp-block-search__button' );
41
+ }
42
+
43
+ /**
44
+ * Handles keydown event to collapse an expanded Search block (when pressing Escape key).
45
+ *
46
+ * @param {KeyboardEvent} event
47
+ */
48
+ function handleKeydownEvent( event ) {
49
+ if ( ! expandedSearchBlock ) {
50
+ // In case the event listener wasn't removed in time.
51
+ return;
52
+ }
53
+
54
+ if ( event.key === 'Escape' ) {
55
+ const block = expandedSearchBlock; // This is nullified by collapseExpandedSearchBlock().
56
+ collapseExpandedSearchBlock();
57
+ getSearchButton( block ).focus();
58
+ }
59
+ }
60
+
61
+ /**
62
+ * Handles keyup event to collapse an expanded Search block (e.g. when tabbing out of expanded Search block).
63
+ *
64
+ * @param {KeyboardEvent} event
65
+ */
66
+ function handleKeyupEvent( event ) {
67
+ if ( ! expandedSearchBlock ) {
68
+ // In case the event listener wasn't removed in time.
69
+ return;
70
+ }
71
+
72
+ if ( event.target.closest( '.wp-block-search' ) !== expandedSearchBlock ) {
73
+ collapseExpandedSearchBlock();
74
+ }
75
+ }
76
+
77
+ /**
78
+ * Expands search block.
79
+ *
80
+ * Inverse of what is done in collapseExpandedSearchBlock().
81
+ *
82
+ * @param {HTMLFormElement} block Search block.
83
+ */
84
+ function expandSearchBlock( block ) {
85
+ // Make sure only one is open at a time.
86
+ if ( expandedSearchBlock ) {
87
+ collapseExpandedSearchBlock();
88
+ }
89
+
90
+ const searchField = getSearchInput( block );
91
+ const searchButton = getSearchButton( block );
92
+
93
+ searchButton.type = 'submit';
94
+ searchField.ariaHidden = 'false';
95
+ searchField.tabIndex = 0;
96
+ searchButton.ariaExpanded = 'true';
97
+ searchButton.removeAttribute( 'aria-controls' ); // Note: Seemingly not reflected with searchButton.ariaControls.
98
+ toggleAriaLabel( searchButton );
99
+ block.classList.remove( hiddenClass );
100
+
101
+ searchField.focus(); // Note that Chrome seems to do this automatically.
102
+
103
+ // The following two must be inverse of what is done in collapseExpandedSearchBlock().
104
+ document.addEventListener( 'keydown', handleKeydownEvent, {
105
+ passive: true,
106
+ } );
107
+ document.addEventListener( 'keyup', handleKeyupEvent, {
108
+ passive: true,
109
+ } );
110
+
111
+ expandedSearchBlock = block;
112
+ }
113
+
114
+ /**
115
+ * Collapses the expanded search block.
116
+ *
117
+ * Inverse of what is done in expandSearchBlock().
118
+ */
119
+ function collapseExpandedSearchBlock() {
120
+ if ( ! expandedSearchBlock ) {
121
+ throw new Error( 'Expected expandedSearchBlock to be defined.' );
122
+ }
123
+ const block = expandedSearchBlock;
124
+ const searchField = getSearchInput( block );
125
+ const searchButton = getSearchButton( block );
126
+
127
+ searchButton.type = 'button';
128
+ searchField.ariaHidden = 'true';
129
+ searchField.tabIndex = -1;
130
+ searchButton.ariaExpanded = 'false';
131
+ searchButton.setAttribute( 'aria-controls', searchField.id ); // Note: Seemingly not reflected with searchButton.ariaControls.
132
+ toggleAriaLabel( searchButton );
133
+ block.classList.add( hiddenClass );
134
+
135
+ // The following two must be inverse of what is done in expandSearchBlock().
136
+ document.removeEventListener( 'keydown', handleKeydownEvent, {
137
+ passive: true,
67
138
  } );
68
- } );
139
+ document.removeEventListener( 'keyup', handleKeyupEvent, {
140
+ passive: true,
141
+ } );
142
+
143
+ expandedSearchBlock = null;
144
+ }
145
+
146
+ // Listen for click events anywhere on the document so this script can be loaded asynchronously in the head.
147
+ document.addEventListener(
148
+ 'click',
149
+ ( event ) => {
150
+ // Get the ancestor expandable Search block of the clicked element.
151
+ const block = event.target.closest(
152
+ '.wp-block-search__button-behavior-expand'
153
+ );
154
+
155
+ /*
156
+ * If there is already an expanded search block and either the current click was not for a Search block or it was
157
+ * for another block, then collapse the currently-expanded block.
158
+ */
159
+ if ( expandedSearchBlock && block !== expandedSearchBlock ) {
160
+ collapseExpandedSearchBlock();
161
+ }
162
+
163
+ // If the click was on or inside a collapsed Search block, expand it.
164
+ if (
165
+ block instanceof HTMLFormElement &&
166
+ block.classList.contains( hiddenClass )
167
+ ) {
168
+ expandSearchBlock( block );
169
+ }
170
+ },
171
+ { passive: true }
172
+ );
@@ -293,6 +293,7 @@ const SiteLogo = ( {
293
293
  <PanelBody title={ __( 'Settings' ) }>
294
294
  <RangeControl
295
295
  __nextHasNoMarginBottom
296
+ __next40pxDefaultSize
296
297
  label={ __( 'Image width' ) }
297
298
  onChange={ ( newWidth ) =>
298
299
  setAttributes( { width: newWidth } )
@@ -31,6 +31,7 @@ export * from './snapchat';
31
31
  export * from './soundcloud';
32
32
  export * from './spotify';
33
33
  export * from './telegram';
34
+ export * from './threads';
34
35
  export * from './tiktok';
35
36
  export * from './tumblr';
36
37
  export * from './twitch';
@@ -0,0 +1,10 @@
1
+ /**
2
+ * WordPress dependencies
3
+ */
4
+ import { Path, SVG } from '@wordpress/primitives';
5
+
6
+ export const ThreadsIcon = () => (
7
+ <SVG width="24" height="24" viewBox="0 0 24 24" version="1.1">
8
+ <Path d="M16.3 11.3c-.1 0-.2-.1-.2-.1-.1-2.6-1.5-4-3.9-4-1.4 0-2.6.6-3.3 1.7l1.3.9c.5-.8 1.4-1 2-1 .8 0 1.4.2 1.7.7.3.3.5.8.5 1.3-.7-.1-1.4-.2-2.2-.1-2.2.1-3.7 1.4-3.6 3.2 0 .9.5 1.7 1.3 2.2.7.4 1.5.6 2.4.6 1.2-.1 2.1-.5 2.7-1.3.5-.6.8-1.4.9-2.4.6.3 1 .8 1.2 1.3.4.9.4 2.4-.8 3.6-1.1 1.1-2.3 1.5-4.3 1.5-2.1 0-3.8-.7-4.8-2S5.7 14.3 5.7 12c0-2.3.5-4.1 1.5-5.4 1.1-1.3 2.7-2 4.8-2 2.2 0 3.8.7 4.9 2 .5.7.9 1.5 1.2 2.5l1.5-.4c-.3-1.2-.8-2.2-1.5-3.1-1.3-1.7-3.3-2.6-6-2.6-2.6 0-4.7.9-6 2.6C4.9 7.2 4.3 9.3 4.3 12s.6 4.8 1.9 6.4c1.4 1.7 3.4 2.6 6 2.6 2.3 0 4-.6 5.3-2 1.8-1.8 1.7-4 1.1-5.4-.4-.9-1.2-1.7-2.3-2.3zm-4 3.8c-1 .1-2-.4-2-1.3 0-.7.5-1.5 2.1-1.6h.5c.6 0 1.1.1 1.6.2-.2 2.3-1.3 2.7-2.2 2.7z" />
9
+ </SVG>
10
+ );
@@ -258,6 +258,10 @@ function block_core_social_link_services( $service = '', $field = '' ) {
258
258
  'name' => 'Telegram',
259
259
  'icon' => '<svg width="24" height="24" viewBox="0 0 128 128" version="1.1" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false"><path d="M28.9700376,63.3244248 C47.6273373,55.1957357 60.0684594,49.8368063 66.2934036,47.2476366 C84.0668845,39.855031 87.7600616,38.5708563 90.1672227,38.528 C90.6966555,38.5191258 91.8804274,38.6503351 92.6472251,39.2725385 C93.294694,39.7979149 93.4728387,40.5076237 93.5580865,41.0057381 C93.6433345,41.5038525 93.7494885,42.63857 93.6651041,43.5252052 C92.7019529,53.6451182 88.5344133,78.2034783 86.4142057,89.5379542 C85.5170662,94.3339958 83.750571,95.9420841 82.0403991,96.0994568 C78.3237996,96.4414641 75.5015827,93.6432685 71.9018743,91.2836143 C66.2690414,87.5912212 63.0868492,85.2926952 57.6192095,81.6896017 C51.3004058,77.5256038 55.3966232,75.2369981 58.9976911,71.4967761 C59.9401076,70.5179421 76.3155302,55.6232293 76.6324771,54.2720454 C76.6721165,54.1030573 76.7089039,53.4731496 76.3346867,53.1405352 C75.9604695,52.8079208 75.4081573,52.921662 75.0095933,53.0121213 C74.444641,53.1403447 65.4461175,59.0880351 48.0140228,70.8551922 C45.4598218,72.6091037 43.1463059,73.4636682 41.0734751,73.4188859 C38.7883453,73.3695169 34.3926725,72.1268388 31.1249416,71.0646282 C27.1169366,69.7617838 23.931454,69.0729605 24.208838,66.8603276 C24.3533167,65.7078514 25.9403832,64.5292172 28.9700376,63.3244248 Z" /></svg>',
260
260
  ),
261
+ 'threads' => array(
262
+ 'name' => 'Threads',
263
+ 'icon' => '<svg width="24" height="24" viewBox="0 0 24 24" version="1.1" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false"><path d="M16.3 11.3c-.1 0-.2-.1-.2-.1-.1-2.6-1.5-4-3.9-4-1.4 0-2.6.6-3.3 1.7l1.3.9c.5-.8 1.4-1 2-1 .8 0 1.4.2 1.7.7.3.3.5.8.5 1.3-.7-.1-1.4-.2-2.2-.1-2.2.1-3.7 1.4-3.6 3.2 0 .9.5 1.7 1.3 2.2.7.4 1.5.6 2.4.6 1.2-.1 2.1-.5 2.7-1.3.5-.6.8-1.4.9-2.4.6.3 1 .8 1.2 1.3.4.9.4 2.4-.8 3.6-1.1 1.1-2.3 1.5-4.3 1.5-2.1 0-3.8-.7-4.8-2S5.7 14.3 5.7 12c0-2.3.5-4.1 1.5-5.4 1.1-1.3 2.7-2 4.8-2 2.2 0 3.8.7 4.9 2 .5.7.9 1.5 1.2 2.5l1.5-.4c-.3-1.2-.8-2.2-1.5-3.1-1.3-1.7-3.3-2.6-6-2.6-2.6 0-4.7.9-6 2.6C4.9 7.2 4.3 9.3 4.3 12s.6 4.8 1.9 6.4c1.4 1.7 3.4 2.6 6 2.6 2.3 0 4-.6 5.3-2 1.8-1.8 1.7-4 1.1-5.4-.4-.9-1.2-1.7-2.3-2.3zm-4 3.8c-1 .1-2-.4-2-1.3 0-.7.5-1.5 2.1-1.6h.5c.6 0 1.1.1 1.6.2-.2 2.3-1.3 2.7-2.2 2.7z"/></svg>',
264
+ ),
261
265
  'tiktok' => array(
262
266
  'name' => 'TikTok',
263
267
  'icon' => '<svg width="24" height="24" viewBox="0 0 32 32" version="1.1" xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false"><path d="M16.708 0.027c1.745-0.027 3.48-0.011 5.213-0.027 0.105 2.041 0.839 4.12 2.333 5.563 1.491 1.479 3.6 2.156 5.652 2.385v5.369c-1.923-0.063-3.855-0.463-5.6-1.291-0.76-0.344-1.468-0.787-2.161-1.24-0.009 3.896 0.016 7.787-0.025 11.667-0.104 1.864-0.719 3.719-1.803 5.255-1.744 2.557-4.771 4.224-7.88 4.276-1.907 0.109-3.812-0.411-5.437-1.369-2.693-1.588-4.588-4.495-4.864-7.615-0.032-0.667-0.043-1.333-0.016-1.984 0.24-2.537 1.495-4.964 3.443-6.615 2.208-1.923 5.301-2.839 8.197-2.297 0.027 1.975-0.052 3.948-0.052 5.923-1.323-0.428-2.869-0.308-4.025 0.495-0.844 0.547-1.485 1.385-1.819 2.333-0.276 0.676-0.197 1.427-0.181 2.145 0.317 2.188 2.421 4.027 4.667 3.828 1.489-0.016 2.916-0.88 3.692-2.145 0.251-0.443 0.532-0.896 0.547-1.417 0.131-2.385 0.079-4.76 0.095-7.145 0.011-5.375-0.016-10.735 0.025-16.093z" /></svg>',
@@ -154,6 +154,11 @@
154
154
  color: #fff;
155
155
  }
156
156
 
157
+ .wp-social-link-threads {
158
+ background-color: #000;
159
+ color: #fff;
160
+ }
161
+
157
162
  .wp-social-link-tiktok {
158
163
  background-color: #000;
159
164
  color: #fff;
@@ -119,6 +119,10 @@
119
119
  color: #2aabee;
120
120
  }
121
121
 
122
+ .wp-social-link-threads {
123
+ color: #000;
124
+ }
125
+
122
126
  .wp-social-link-tiktok {
123
127
  color: #000;
124
128
  }
@@ -35,6 +35,7 @@ import {
35
35
  SoundCloudIcon,
36
36
  SpotifyIcon,
37
37
  TelegramIcon,
38
+ ThreadsIcon,
38
39
  TiktokIcon,
39
40
  TumblrIcon,
40
41
  TwitchIcon,
@@ -255,6 +256,12 @@ const variations = [
255
256
  title: 'Telegram',
256
257
  icon: TelegramIcon,
257
258
  },
259
+ {
260
+ name: 'threads',
261
+ attributes: { service: 'threads' },
262
+ title: 'Threads',
263
+ icon: ThreadsIcon,
264
+ },
258
265
  {
259
266
  name: 'tiktok',
260
267
  attributes: { service: 'tiktok' },
@@ -122,6 +122,7 @@ function TagCloudEdit( { attributes, setAttributes, taxonomies } ) {
122
122
  />
123
123
  <RangeControl
124
124
  __nextHasNoMarginBottom
125
+ __next40pxDefaultSize
125
126
  label={ __( 'Number of tags' ) }
126
127
  value={ numberOfTags }
127
128
  onChange={ ( value ) =>
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * WordPress dependencies
3
3
  */
4
- import { __, sprintf } from '@wordpress/i18n';
4
+ import { __, _x, sprintf } from '@wordpress/i18n';
5
5
  import { useMemo, useState } from '@wordpress/element';
6
6
  import { useDispatch, useSelect, useRegistry } from '@wordpress/data';
7
7
  import {
@@ -163,7 +163,7 @@ export function TemplatePartImportControls( { area, setAttributes } ) {
163
163
  isBusy={ isBusy }
164
164
  aria-disabled={ isBusy || ! selectedSidebar }
165
165
  >
166
- { __( 'Import' ) }
166
+ { _x( 'Import', 'button label' ) }
167
167
  </Button>
168
168
  </FlexItem>
169
169
  </HStack>
@@ -77,7 +77,7 @@ export default function TemplatePartEdit( {
77
77
  area: _area,
78
78
  };
79
79
  },
80
- [ templatePartId, clientId ]
80
+ [ templatePartId, attributes.area, clientId ]
81
81
  );
82
82
  const { templateParts } = useAlternativeTemplateParts(
83
83
  area,
@@ -18,12 +18,11 @@ function render_block_core_template_part( $attributes ) {
18
18
  $template_part_id = null;
19
19
  $content = null;
20
20
  $area = WP_TEMPLATE_PART_AREA_UNCATEGORIZED;
21
- $stylesheet = get_stylesheet();
22
21
 
23
22
  if (
24
23
  isset( $attributes['slug'] ) &&
25
24
  isset( $attributes['theme'] ) &&
26
- $stylesheet === $attributes['theme']
25
+ get_stylesheet() === $attributes['theme']
27
26
  ) {
28
27
  $template_part_id = $attributes['theme'] . '//' . $attributes['slug'];
29
28
  $template_part_query = new WP_Query(
@@ -64,23 +63,15 @@ function render_block_core_template_part( $attributes ) {
64
63
  */
65
64
  do_action( 'render_block_core_template_part_post', $template_part_id, $attributes, $template_part_post, $content );
66
65
  } else {
66
+ $template_part_file_path = '';
67
67
  // Else, if the template part was provided by the active theme,
68
68
  // render the corresponding file content.
69
69
  if ( 0 === validate_file( $attributes['slug'] ) ) {
70
- $themes = array( $stylesheet );
71
- $template = get_template();
72
- if ( $stylesheet !== $template ) {
73
- $themes[] = $template;
74
- }
70
+ $block_template = get_block_file_template( $template_part_id, 'wp_template_part' );
75
71
 
76
- foreach ( $themes as $theme ) {
77
- $theme_folders = get_block_theme_folders( $theme );
78
- $template_part_file_path = get_theme_file_path( '/' . $theme_folders['wp_template_part'] . '/' . $attributes['slug'] . '.html' );
79
- if ( file_exists( $template_part_file_path ) ) {
80
- $content = (string) file_get_contents( $template_part_file_path );
81
- $content = '' !== $content ? _inject_theme_attribute_in_block_template_content( $content ) : '';
82
- break;
83
- }
72
+ $content = $block_template->content;
73
+ if ( isset( $block_template->area ) ) {
74
+ $area = $block_template->area;
84
75
  }
85
76
  }
86
77
 
@@ -256,7 +247,7 @@ function build_template_part_block_instance_variations() {
256
247
  'area' => $template_part->area,
257
248
  ),
258
249
  'scope' => array( 'inserter' ),
259
- 'icon' => $icon_by_area[ $template_part->area ],
250
+ 'icon' => isset( $icon_by_area[ $template_part->area ] ) ? $icon_by_area[ $template_part->area ] : null,
260
251
  'example' => array(
261
252
  'attributes' => array(
262
253
  'slug' => $template_part->slug,
@@ -35,6 +35,7 @@ export default function TextColumnsEdit( { attributes, setAttributes } ) {
35
35
  <PanelBody>
36
36
  <RangeControl
37
37
  __nextHasNoMarginBottom
38
+ __next40pxDefaultSize
38
39
  label={ __( 'Columns' ) }
39
40
  value={ columns }
40
41
  onChange={ ( value ) =>
@@ -3,6 +3,7 @@
3
3
  box-sizing: border-box;
4
4
  video {
5
5
  width: 100%;
6
+ vertical-align: middle;
6
7
  }
7
8
 
8
9
  @supports (position: sticky) {
@@ -1,38 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
-
5
- Object.defineProperty(exports, "__esModule", {
6
- value: true
7
- });
8
- exports.sharedIcon = void 0;
9
-
10
- var _element = require("@wordpress/element");
11
-
12
- var _components = require("@wordpress/components");
13
-
14
- var _compose = require("@wordpress/compose");
15
-
16
- var _icons = require("@wordpress/icons");
17
-
18
- var _styles = _interopRequireDefault(require("./styles.scss"));
19
-
20
- /**
21
- * WordPress dependencies
22
- */
23
-
24
- /**
25
- * Internal dependencies
26
- */
27
- const IconWithColorScheme = (0, _compose.withPreferredColorScheme)(({
28
- getStylesFromColorScheme
29
- }) => {
30
- const colorSchemeStyles = getStylesFromColorScheme(_styles.default.icon, _styles.default.iconDark);
31
- return (0, _element.createElement)(_components.Icon, {
32
- icon: _icons.gallery,
33
- ...colorSchemeStyles
34
- });
35
- });
36
- const sharedIcon = (0, _element.createElement)(IconWithColorScheme, null);
37
- exports.sharedIcon = sharedIcon;
38
- //# sourceMappingURL=shared-icon.native.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["@wordpress/block-library/src/gallery/shared-icon.native.js"],"names":["IconWithColorScheme","getStylesFromColorScheme","colorSchemeStyles","styles","icon","iconDark","sharedIcon"],"mappings":";;;;;;;;;;;AAGA;;AACA;;AACA;;AAKA;;AAVA;AACA;AACA;;AAKA;AACA;AACA;AAGA,MAAMA,mBAAmB,GAAG,uCAC3B,CAAE;AAAEC,EAAAA;AAAF,CAAF,KAAoC;AACnC,QAAMC,iBAAiB,GAAGD,wBAAwB,CACjDE,gBAAOC,IAD0C,EAEjDD,gBAAOE,QAF0C,CAAlD;AAIA,SAAO,4BAAC,gBAAD;AAAM,IAAA,IAAI,EAAGD,cAAb;AAAA,OAAyBF;AAAzB,IAAP;AACA,CAP0B,CAA5B;AAUO,MAAMI,UAAU,GAAG,4BAAC,mBAAD,OAAnB","sourcesContent":["/**\n * WordPress dependencies\n */\nimport { Icon } from '@wordpress/components';\nimport { withPreferredColorScheme } from '@wordpress/compose';\nimport { gallery as icon } from '@wordpress/icons';\n\n/**\n * Internal dependencies\n */\nimport styles from './styles.scss';\n\nconst IconWithColorScheme = withPreferredColorScheme(\n\t( { getStylesFromColorScheme } ) => {\n\t\tconst colorSchemeStyles = getStylesFromColorScheme(\n\t\t\tstyles.icon,\n\t\t\tstyles.iconDark\n\t\t);\n\t\treturn <Icon icon={ icon } { ...colorSchemeStyles } />;\n\t}\n);\n\nexport const sharedIcon = <IconWithColorScheme />;\n"]}