@wordpress/components 19.13.0 → 19.14.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 (398) hide show
  1. package/CHANGELOG.md +38 -1
  2. package/build/alignment-matrix-control/utils.js +1 -7
  3. package/build/alignment-matrix-control/utils.js.map +1 -1
  4. package/build/autocomplete/autocompleter-ui.js +4 -2
  5. package/build/autocomplete/autocompleter-ui.js.map +1 -1
  6. package/build/autocomplete/autocompleter-ui.native.js +9 -3
  7. package/build/autocomplete/autocompleter-ui.native.js.map +1 -1
  8. package/build/autocomplete/index.js +4 -2
  9. package/build/autocomplete/index.js.map +1 -1
  10. package/build/border-box-control/border-box-control/component.js +2 -1
  11. package/build/border-box-control/border-box-control/component.js.map +1 -1
  12. package/build/border-box-control/border-box-control-split-controls/component.js +2 -1
  13. package/build/border-box-control/border-box-control-split-controls/component.js.map +1 -1
  14. package/build/border-control/border-control/component.js +40 -4
  15. package/build/border-control/border-control/component.js.map +1 -1
  16. package/build/box-control/utils.js +3 -3
  17. package/build/box-control/utils.js.map +1 -1
  18. package/build/color-indicator/index.js +27 -10
  19. package/build/color-indicator/index.js.map +1 -1
  20. package/build/color-indicator/types.js +6 -0
  21. package/build/color-indicator/types.js.map +1 -0
  22. package/build/color-palette/index.js +2 -1
  23. package/build/color-palette/index.js.map +1 -1
  24. package/build/color-picker/component.js +6 -9
  25. package/build/color-picker/component.js.map +1 -1
  26. package/build/color-picker/input-with-slider.js +1 -2
  27. package/build/color-picker/input-with-slider.js.map +1 -1
  28. package/build/color-picker/styles.js +34 -16
  29. package/build/color-picker/styles.js.map +1 -1
  30. package/build/custom-gradient-picker/index.js +8 -8
  31. package/build/custom-gradient-picker/index.js.map +1 -1
  32. package/build/custom-gradient-picker/index.native.js +8 -9
  33. package/build/custom-gradient-picker/index.native.js.map +1 -1
  34. package/build/custom-gradient-picker/serializer.js +4 -7
  35. package/build/custom-gradient-picker/serializer.js.map +1 -1
  36. package/build/date-time/date/index.js +3 -1
  37. package/build/date-time/date/index.js.map +1 -1
  38. package/build/date-time/date-time/index.js +3 -1
  39. package/build/date-time/date-time/index.js.map +1 -1
  40. package/build/duotone-picker/duotone-picker.js +42 -29
  41. package/build/duotone-picker/duotone-picker.js.map +1 -1
  42. package/build/elevation/hook.js +13 -13
  43. package/build/elevation/hook.js.map +1 -1
  44. package/build/focal-point-picker/index.native.js +4 -4
  45. package/build/focal-point-picker/index.native.js.map +1 -1
  46. package/build/form-toggle/index.js +28 -5
  47. package/build/form-toggle/index.js.map +1 -1
  48. package/build/form-toggle/types.js +6 -0
  49. package/build/form-toggle/types.js.map +1 -0
  50. package/build/h-stack/utils.js +3 -3
  51. package/build/h-stack/utils.js.map +1 -1
  52. package/build/heading/component.js +0 -1
  53. package/build/heading/component.js.map +1 -1
  54. package/build/heading/hook.js.map +1 -1
  55. package/build/heading/types.js +6 -0
  56. package/build/heading/types.js.map +1 -0
  57. package/build/mobile/bottom-sheet/keyboard-avoiding-view.native.js +0 -1
  58. package/build/mobile/bottom-sheet/keyboard-avoiding-view.native.js.map +1 -1
  59. package/build/mobile/link-picker/index.native.js +4 -4
  60. package/build/mobile/link-picker/index.native.js.map +1 -1
  61. package/build/mobile/segmented-control/index.native.js +2 -4
  62. package/build/mobile/segmented-control/index.native.js.map +1 -1
  63. package/build/navigation/group/index.js +4 -7
  64. package/build/navigation/group/index.js.map +1 -1
  65. package/build/navigation/item/base.js +3 -3
  66. package/build/navigation/item/base.js.map +1 -1
  67. package/build/navigation/item/use-navigation-tree-item.js +2 -1
  68. package/build/navigation/item/use-navigation-tree-item.js.map +1 -1
  69. package/build/navigation/menu/menu-title-search.js +1 -7
  70. package/build/navigation/menu/menu-title-search.js.map +1 -1
  71. package/build/navigation/menu/search-no-results-found.js +1 -7
  72. package/build/navigation/menu/search-no-results-found.js.map +1 -1
  73. package/build/navigation/use-navigation-tree-nodes.js +18 -10
  74. package/build/navigation/use-navigation-tree-nodes.js.map +1 -1
  75. package/build/navigation/utils.js +4 -2
  76. package/build/navigation/utils.js.map +1 -1
  77. package/build/range-control/index.js +3 -3
  78. package/build/range-control/index.js.map +1 -1
  79. package/build/range-control/utils.js +3 -7
  80. package/build/range-control/utils.js.map +1 -1
  81. package/build/spacer/component.js +5 -5
  82. package/build/spacer/component.js.map +1 -1
  83. package/build/spinner/index.js +26 -13
  84. package/build/spinner/index.js.map +1 -1
  85. package/build/spinner/styles.js +10 -10
  86. package/build/spinner/styles.js.map +1 -1
  87. package/build/truncate/component.js +7 -8
  88. package/build/truncate/component.js.map +1 -1
  89. package/build/truncate/hook.js +3 -10
  90. package/build/truncate/hook.js.map +1 -1
  91. package/build/truncate/index.js.map +1 -1
  92. package/build/truncate/styles.js +1 -1
  93. package/build/truncate/styles.js.map +1 -1
  94. package/build/truncate/utils.js +3 -16
  95. package/build/truncate/utils.js.map +1 -1
  96. package/build/utils/math.js +17 -7
  97. package/build/utils/math.js.map +1 -1
  98. package/build/v-stack/component.js +9 -9
  99. package/build/v-stack/component.js.map +1 -1
  100. package/build/v-stack/hook.js +0 -5
  101. package/build/v-stack/hook.js.map +1 -1
  102. package/build/v-stack/index.js.map +1 -1
  103. package/build-module/alignment-matrix-control/utils.js +1 -6
  104. package/build-module/alignment-matrix-control/utils.js.map +1 -1
  105. package/build-module/autocomplete/autocompleter-ui.js +4 -2
  106. package/build-module/autocomplete/autocompleter-ui.js.map +1 -1
  107. package/build-module/autocomplete/autocompleter-ui.native.js +9 -3
  108. package/build-module/autocomplete/autocompleter-ui.native.js.map +1 -1
  109. package/build-module/autocomplete/index.js +4 -2
  110. package/build-module/autocomplete/index.js.map +1 -1
  111. package/build-module/border-box-control/border-box-control/component.js +2 -1
  112. package/build-module/border-box-control/border-box-control/component.js.map +1 -1
  113. package/build-module/border-box-control/border-box-control-split-controls/component.js +2 -1
  114. package/build-module/border-box-control/border-box-control-split-controls/component.js.map +1 -1
  115. package/build-module/border-control/border-control/component.js +38 -3
  116. package/build-module/border-control/border-control/component.js.map +1 -1
  117. package/build-module/box-control/utils.js +4 -4
  118. package/build-module/box-control/utils.js.map +1 -1
  119. package/build-module/color-indicator/index.js +29 -8
  120. package/build-module/color-indicator/index.js.map +1 -1
  121. package/build-module/color-indicator/types.js +2 -0
  122. package/build-module/color-indicator/types.js.map +1 -0
  123. package/build-module/color-palette/index.js +2 -1
  124. package/build-module/color-palette/index.js.map +1 -1
  125. package/build-module/color-picker/component.js +7 -8
  126. package/build-module/color-picker/component.js.map +1 -1
  127. package/build-module/color-picker/input-with-slider.js +1 -2
  128. package/build-module/color-picker/input-with-slider.js.map +1 -1
  129. package/build-module/color-picker/styles.js +28 -14
  130. package/build-module/color-picker/styles.js.map +1 -1
  131. package/build-module/custom-gradient-picker/index.js +8 -7
  132. package/build-module/custom-gradient-picker/index.js.map +1 -1
  133. package/build-module/custom-gradient-picker/index.native.js +8 -8
  134. package/build-module/custom-gradient-picker/index.native.js.map +1 -1
  135. package/build-module/custom-gradient-picker/serializer.js +4 -6
  136. package/build-module/custom-gradient-picker/serializer.js.map +1 -1
  137. package/build-module/date-time/date/index.js +3 -1
  138. package/build-module/date-time/date/index.js.map +1 -1
  139. package/build-module/date-time/date-time/index.js +3 -1
  140. package/build-module/date-time/date-time/index.js.map +1 -1
  141. package/build-module/duotone-picker/duotone-picker.js +42 -29
  142. package/build-module/duotone-picker/duotone-picker.js.map +1 -1
  143. package/build-module/elevation/hook.js +12 -12
  144. package/build-module/elevation/hook.js.map +1 -1
  145. package/build-module/focal-point-picker/index.native.js +1 -1
  146. package/build-module/focal-point-picker/index.native.js.map +1 -1
  147. package/build-module/form-toggle/index.js +30 -6
  148. package/build-module/form-toggle/index.js.map +1 -1
  149. package/build-module/form-toggle/types.js +2 -0
  150. package/build-module/form-toggle/types.js.map +1 -0
  151. package/build-module/h-stack/utils.js +3 -3
  152. package/build-module/h-stack/utils.js.map +1 -1
  153. package/build-module/heading/component.js +0 -1
  154. package/build-module/heading/component.js.map +1 -1
  155. package/build-module/heading/hook.js.map +1 -1
  156. package/build-module/heading/types.js +2 -0
  157. package/build-module/heading/types.js.map +1 -0
  158. package/build-module/mobile/bottom-sheet/keyboard-avoiding-view.native.js +0 -1
  159. package/build-module/mobile/bottom-sheet/keyboard-avoiding-view.native.js.map +1 -1
  160. package/build-module/mobile/link-picker/index.native.js +4 -3
  161. package/build-module/mobile/link-picker/index.native.js.map +1 -1
  162. package/build-module/mobile/segmented-control/index.native.js +2 -3
  163. package/build-module/mobile/segmented-control/index.native.js.map +1 -1
  164. package/build-module/navigation/group/index.js +3 -6
  165. package/build-module/navigation/group/index.js.map +1 -1
  166. package/build-module/navigation/item/base.js +2 -2
  167. package/build-module/navigation/item/base.js.map +1 -1
  168. package/build-module/navigation/item/use-navigation-tree-item.js +2 -1
  169. package/build-module/navigation/item/use-navigation-tree-item.js.map +1 -1
  170. package/build-module/navigation/menu/menu-title-search.js +1 -6
  171. package/build-module/navigation/menu/menu-title-search.js.map +1 -1
  172. package/build-module/navigation/menu/search-no-results-found.js +1 -6
  173. package/build-module/navigation/menu/search-no-results-found.js.map +1 -1
  174. package/build-module/navigation/use-navigation-tree-nodes.js +18 -9
  175. package/build-module/navigation/use-navigation-tree-nodes.js.map +1 -1
  176. package/build-module/navigation/utils.js +2 -2
  177. package/build-module/navigation/utils.js.map +1 -1
  178. package/build-module/range-control/index.js +1 -1
  179. package/build-module/range-control/index.js.map +1 -1
  180. package/build-module/range-control/utils.js +1 -5
  181. package/build-module/range-control/utils.js.map +1 -1
  182. package/build-module/spacer/component.js +3 -4
  183. package/build-module/spacer/component.js.map +1 -1
  184. package/build-module/spinner/index.js +22 -13
  185. package/build-module/spinner/index.js.map +1 -1
  186. package/build-module/spinner/styles.js +10 -10
  187. package/build-module/spinner/styles.js.map +1 -1
  188. package/build-module/truncate/component.js +7 -8
  189. package/build-module/truncate/component.js.map +1 -1
  190. package/build-module/truncate/hook.js +3 -10
  191. package/build-module/truncate/hook.js.map +1 -1
  192. package/build-module/truncate/index.js.map +1 -1
  193. package/build-module/truncate/styles.js +1 -1
  194. package/build-module/truncate/styles.js.map +1 -1
  195. package/build-module/truncate/utils.js +3 -16
  196. package/build-module/truncate/utils.js.map +1 -1
  197. package/build-module/utils/math.js +15 -6
  198. package/build-module/utils/math.js.map +1 -1
  199. package/build-module/v-stack/component.js +9 -9
  200. package/build-module/v-stack/component.js.map +1 -1
  201. package/build-module/v-stack/hook.js +0 -5
  202. package/build-module/v-stack/hook.js.map +1 -1
  203. package/build-module/v-stack/index.js.map +1 -1
  204. package/build-style/style-rtl.css +16 -0
  205. package/build-style/style.css +16 -0
  206. package/build-types/border-box-control/border-box-control/component.d.ts.map +1 -1
  207. package/build-types/border-box-control/border-box-control-split-controls/component.d.ts.map +1 -1
  208. package/build-types/border-control/border-control/component.d.ts +36 -2
  209. package/build-types/border-control/border-control/component.d.ts.map +1 -1
  210. package/build-types/border-control/stories/index.d.ts +33 -0
  211. package/build-types/border-control/stories/index.d.ts.map +1 -0
  212. package/build-types/color-indicator/index.d.ts +16 -5
  213. package/build-types/color-indicator/index.d.ts.map +1 -1
  214. package/build-types/color-indicator/stories/index.d.ts +12 -0
  215. package/build-types/color-indicator/stories/index.d.ts.map +1 -0
  216. package/build-types/color-indicator/test/index.d.ts +2 -0
  217. package/build-types/color-indicator/test/index.d.ts.map +1 -0
  218. package/build-types/color-indicator/types.d.ts +12 -0
  219. package/build-types/color-indicator/types.d.ts.map +1 -0
  220. package/build-types/color-palette/index.d.ts.map +1 -1
  221. package/build-types/color-palette/styles.d.ts +4 -2
  222. package/build-types/color-palette/styles.d.ts.map +1 -1
  223. package/build-types/color-picker/component.d.ts.map +1 -1
  224. package/build-types/color-picker/styles.d.ts +17 -0
  225. package/build-types/color-picker/styles.d.ts.map +1 -1
  226. package/build-types/date-time/date/index.d.ts +1 -1
  227. package/build-types/date-time/date/index.d.ts.map +1 -1
  228. package/build-types/date-time/date-time/index.d.ts.map +1 -1
  229. package/build-types/date-time/types.d.ts +6 -0
  230. package/build-types/date-time/types.d.ts.map +1 -1
  231. package/build-types/form-toggle/index.d.ts +29 -0
  232. package/build-types/form-toggle/index.d.ts.map +1 -0
  233. package/build-types/form-toggle/stories/index.d.ts +12 -0
  234. package/build-types/form-toggle/stories/index.d.ts.map +1 -0
  235. package/build-types/form-toggle/test/index.d.ts +2 -0
  236. package/build-types/form-toggle/test/index.d.ts.map +1 -0
  237. package/build-types/form-toggle/types.d.ts +22 -0
  238. package/build-types/form-toggle/types.d.ts.map +1 -0
  239. package/build-types/form-token-field/test/lib/token-field-wrapper.d.ts +3 -0
  240. package/build-types/form-token-field/test/lib/token-field-wrapper.d.ts.map +1 -1
  241. package/build-types/heading/component.d.ts +1 -2
  242. package/build-types/heading/component.d.ts.map +1 -1
  243. package/build-types/heading/hook.d.ts +1 -28
  244. package/build-types/heading/hook.d.ts.map +1 -1
  245. package/build-types/heading/stories/index.d.ts.map +1 -1
  246. package/build-types/heading/test/index.d.ts +2 -0
  247. package/build-types/heading/test/index.d.ts.map +1 -0
  248. package/build-types/heading/types.d.ts +16 -0
  249. package/build-types/heading/types.d.ts.map +1 -0
  250. package/build-types/range-control/utils.d.ts.map +1 -1
  251. package/build-types/spacer/component.d.ts +2 -3
  252. package/build-types/spacer/component.d.ts.map +1 -1
  253. package/build-types/spacer/stories/index.d.ts +12 -0
  254. package/build-types/spacer/stories/index.d.ts.map +1 -0
  255. package/build-types/spinner/index.d.ts +16 -15
  256. package/build-types/spinner/index.d.ts.map +1 -1
  257. package/build-types/spinner/stories/index.d.ts +13 -0
  258. package/build-types/spinner/stories/index.d.ts.map +1 -0
  259. package/build-types/spinner/styles.d.ts +4 -3
  260. package/build-types/spinner/styles.d.ts.map +1 -1
  261. package/build-types/text/types.d.ts +1 -1
  262. package/build-types/text/types.d.ts.map +1 -1
  263. package/build-types/truncate/component.d.ts +3 -3
  264. package/build-types/truncate/component.d.ts.map +1 -1
  265. package/build-types/truncate/hook.d.ts +5 -2
  266. package/build-types/truncate/hook.d.ts.map +1 -1
  267. package/build-types/truncate/index.d.ts +2 -2
  268. package/build-types/truncate/index.d.ts.map +1 -1
  269. package/build-types/truncate/stories/index.d.ts +13 -0
  270. package/build-types/truncate/stories/index.d.ts.map +1 -0
  271. package/build-types/truncate/styles.d.ts +1 -1
  272. package/build-types/truncate/styles.d.ts.map +1 -1
  273. package/build-types/truncate/test/index.d.ts +2 -0
  274. package/build-types/truncate/test/index.d.ts.map +1 -0
  275. package/build-types/truncate/types.d.ts +22 -11
  276. package/build-types/truncate/types.d.ts.map +1 -1
  277. package/build-types/truncate/utils.d.ts +17 -28
  278. package/build-types/truncate/utils.d.ts.map +1 -1
  279. package/build-types/ui/form-group/use-form-group.d.ts +2 -2
  280. package/build-types/utils/math.d.ts +10 -0
  281. package/build-types/utils/math.d.ts.map +1 -1
  282. package/build-types/v-stack/component.d.ts +5 -4
  283. package/build-types/v-stack/component.d.ts.map +1 -1
  284. package/build-types/v-stack/hook.d.ts +5 -3
  285. package/build-types/v-stack/hook.d.ts.map +1 -1
  286. package/build-types/v-stack/index.d.ts +2 -2
  287. package/build-types/v-stack/index.d.ts.map +1 -1
  288. package/build-types/v-stack/stories/index.d.ts +9 -0
  289. package/build-types/v-stack/stories/index.d.ts.map +1 -0
  290. package/build-types/v-stack/test/index.d.ts +2 -0
  291. package/build-types/v-stack/test/index.d.ts.map +1 -0
  292. package/build-types/v-stack/types.d.ts +21 -1
  293. package/build-types/v-stack/types.d.ts.map +1 -1
  294. package/package.json +18 -17
  295. package/src/alignment-matrix-control/utils.js +1 -6
  296. package/src/autocomplete/autocompleter-ui.js +4 -1
  297. package/src/autocomplete/autocompleter-ui.native.js +8 -2
  298. package/src/autocomplete/index.js +4 -8
  299. package/src/border-box-control/border-box-control/component.tsx +1 -0
  300. package/src/border-box-control/border-box-control-split-controls/component.tsx +1 -0
  301. package/src/border-control/border-control/component.tsx +41 -4
  302. package/src/border-control/stories/index.tsx +150 -0
  303. package/src/box-control/utils.js +4 -4
  304. package/src/color-indicator/README.md +7 -9
  305. package/src/color-indicator/index.tsx +47 -0
  306. package/src/color-indicator/stories/index.tsx +37 -0
  307. package/src/color-indicator/test/__snapshots__/index.tsx.snap +11 -0
  308. package/src/color-indicator/test/{index.js → index.tsx} +4 -4
  309. package/src/color-indicator/types.ts +12 -0
  310. package/src/color-palette/index.js +5 -1
  311. package/src/color-picker/component.tsx +12 -11
  312. package/src/color-picker/input-with-slider.tsx +2 -2
  313. package/src/color-picker/styles.ts +20 -1
  314. package/src/custom-gradient-picker/index.js +4 -11
  315. package/src/custom-gradient-picker/index.native.js +3 -11
  316. package/src/custom-gradient-picker/serializer.js +5 -11
  317. package/src/date-time/README.md +7 -0
  318. package/src/date-time/date/index.tsx +2 -0
  319. package/src/date-time/date-time/index.tsx +2 -0
  320. package/src/date-time/types.ts +7 -0
  321. package/src/dimension-control/README.md +5 -2
  322. package/src/dimension-control/test/index.test.js +7 -7
  323. package/src/duotone-picker/duotone-picker.js +58 -37
  324. package/src/duotone-picker/style.scss +19 -0
  325. package/src/elevation/hook.js +8 -8
  326. package/src/flex/flex/README.md +5 -10
  327. package/src/flex/flex-item/README.md +1 -1
  328. package/src/focal-point-picker/index.native.js +1 -1
  329. package/src/form-toggle/README.md +10 -11
  330. package/src/form-toggle/index.tsx +71 -0
  331. package/src/form-toggle/stories/index.tsx +52 -0
  332. package/src/form-toggle/test/__snapshots__/index.tsx.snap +54 -0
  333. package/src/form-toggle/test/index.tsx +102 -0
  334. package/src/form-toggle/types.ts +22 -0
  335. package/src/form-token-field/test/index.js +6 -9
  336. package/src/form-token-field/test/lib/token-field-wrapper.tsx +2 -2
  337. package/src/h-stack/utils.js +3 -3
  338. package/src/heading/README.md +4 -3
  339. package/src/heading/component.tsx +2 -2
  340. package/src/heading/hook.ts +1 -42
  341. package/src/heading/stories/index.tsx +5 -1
  342. package/src/heading/test/__snapshots__/{index.js.snap → index.tsx.snap} +0 -0
  343. package/src/heading/test/index.tsx +68 -0
  344. package/src/heading/types.ts +29 -0
  345. package/src/input-control/test/index.js +106 -31
  346. package/src/mobile/bottom-sheet/keyboard-avoiding-view.native.js +2 -7
  347. package/src/mobile/link-picker/index.native.js +2 -3
  348. package/src/mobile/segmented-control/index.native.js +6 -5
  349. package/src/navigation/group/index.js +8 -3
  350. package/src/navigation/item/base.js +3 -2
  351. package/src/navigation/item/use-navigation-tree-item.js +2 -0
  352. package/src/navigation/menu/menu-title-search.js +3 -6
  353. package/src/navigation/menu/search-no-results-found.js +3 -6
  354. package/src/navigation/use-navigation-tree-nodes.js +11 -10
  355. package/src/navigation/utils.js +2 -2
  356. package/src/number-control/stories/index.js +24 -24
  357. package/src/range-control/index.js +1 -1
  358. package/src/range-control/utils.js +1 -4
  359. package/src/slot-fill/test/slot.js +2 -3
  360. package/src/spacer/component.tsx +3 -4
  361. package/src/spacer/stories/index.tsx +70 -0
  362. package/src/spinner/{index.js → index.tsx} +23 -9
  363. package/src/spinner/stories/index.tsx +32 -0
  364. package/src/spinner/{styles.js → styles.ts} +0 -0
  365. package/src/style.scss +1 -0
  366. package/src/text/types.ts +1 -1
  367. package/src/truncate/README.md +16 -12
  368. package/src/truncate/{component.js → component.tsx} +13 -9
  369. package/src/truncate/{hook.js → hook.ts} +8 -10
  370. package/src/truncate/{index.js → index.ts} +0 -0
  371. package/src/truncate/stories/index.tsx +49 -0
  372. package/src/truncate/{styles.js → styles.ts} +0 -0
  373. package/src/truncate/test/{index.js → index.tsx} +4 -4
  374. package/src/truncate/types.ts +28 -10
  375. package/src/truncate/{utils.js → utils.ts} +19 -19
  376. package/src/utils/math.js +14 -5
  377. package/src/utils/test/math.js +22 -1
  378. package/src/v-stack/README.md +6 -18
  379. package/src/v-stack/{component.js → component.tsx} +15 -10
  380. package/src/v-stack/{hook.js → hook.ts} +5 -6
  381. package/src/v-stack/{index.js → index.ts} +0 -0
  382. package/src/v-stack/stories/index.tsx +41 -0
  383. package/src/v-stack/test/__snapshots__/{index.js.snap → index.tsx.snap} +0 -0
  384. package/src/v-stack/test/{index.js → index.tsx} +0 -0
  385. package/src/v-stack/types.ts +21 -1
  386. package/tsconfig.json +1 -0
  387. package/tsconfig.tsbuildinfo +1 -1
  388. package/src/border-control/stories/index.js +0 -119
  389. package/src/color-indicator/index.js +0 -16
  390. package/src/color-indicator/stories/index.js +0 -22
  391. package/src/color-indicator/test/__snapshots__/index.js.snap +0 -13
  392. package/src/form-toggle/index.js +0 -38
  393. package/src/form-toggle/stories/index.js +0 -28
  394. package/src/form-toggle/test/index.js +0 -74
  395. package/src/heading/test/index.js +0 -67
  396. package/src/spacer/stories/index.js +0 -59
  397. package/src/spinner/stories/index.js +0 -43
  398. package/src/truncate/stories/index.js +0 -38
@@ -1,8 +1,3 @@
1
- /**
2
- * External dependencies
3
- */
4
- import { flattenDeep } from 'lodash';
5
-
6
1
  /**
7
2
  * WordPress dependencies
8
3
  */
@@ -28,7 +23,7 @@ export const ALIGNMENT_LABEL = {
28
23
  };
29
24
 
30
25
  // Transforms GRID into a flat Array of values.
31
- export const ALIGNMENTS = flattenDeep( GRID );
26
+ export const ALIGNMENTS = GRID.flat();
32
27
 
33
28
  /**
34
29
  * Parses and transforms an incoming value to better match the alignment values
@@ -39,7 +39,10 @@ export function getAutoCompleterUI( autocompleter ) {
39
39
 
40
40
  useLayoutEffect( () => {
41
41
  onChangeOptions( items );
42
- }, [ onChangeOptions, items ] );
42
+ // Temporarily disabling exhaustive-deps to avoid introducing unexpected side effecst.
43
+ // See https://github.com/WordPress/gutenberg/pull/41820
44
+ // eslint-disable-next-line react-hooks/exhaustive-deps
45
+ }, [ items ] );
43
46
 
44
47
  if ( ! items.length > 0 ) {
45
48
  return null;
@@ -71,7 +71,10 @@ export function getAutoCompleterUI( autocompleter ) {
71
71
  } else if ( isVisible && text.length === 0 ) {
72
72
  startAnimation( false );
73
73
  }
74
- }, [ onChangeOptions, items, isVisible, text, startAnimation ] );
74
+ // Temporarily disabling exhaustive-deps to avoid introducing unexpected side effecst.
75
+ // See https://github.com/WordPress/gutenberg/pull/41820
76
+ // eslint-disable-next-line react-hooks/exhaustive-deps
77
+ }, [ items, isVisible, text ] );
75
78
 
76
79
  const activeItemStyles = usePreferredColorSchemeStyle(
77
80
  styles[ 'components-autocomplete__item-active' ],
@@ -111,7 +114,10 @@ export function getAutoCompleterUI( autocompleter ) {
111
114
  }
112
115
  } );
113
116
  },
114
- [ animationValue, isVisible, reset ]
117
+ // Temporarily disabling exhaustive-deps to avoid introducing unexpected side effecst.
118
+ // See https://github.com/WordPress/gutenberg/pull/41820
119
+ // eslint-disable-next-line react-hooks/exhaustive-deps
120
+ [ isVisible ]
115
121
  );
116
122
 
117
123
  const contentStyles = {
@@ -375,14 +375,10 @@ function useAutocomplete( {
375
375
  : AutocompleterUI
376
376
  );
377
377
  setFilterValue( query );
378
- }, [
379
- textContent,
380
- AutocompleterUI,
381
- autocompleter,
382
- completers,
383
- record,
384
- filteredOptions.length,
385
- ] );
378
+ // Temporarily disabling exhaustive-deps to avoid introducing unexpected side effecst.
379
+ // See https://github.com/WordPress/gutenberg/pull/41820
380
+ // eslint-disable-next-line react-hooks/exhaustive-deps
381
+ }, [ textContent ] );
386
382
 
387
383
  const { key: selectedKey = '' } = filteredOptions[ selectedIndex ] || {};
388
384
  const { className } = autocompleter || {};
@@ -69,6 +69,7 @@ const BorderBoxControl = (
69
69
  placement: popoverPlacement,
70
70
  offset: popoverOffset,
71
71
  anchorRef: containerRef,
72
+ __unstableShift: true,
72
73
  }
73
74
  : undefined;
74
75
 
@@ -43,6 +43,7 @@ const BorderBoxControlSplitControls = (
43
43
  placement: popoverPlacement,
44
44
  offset: popoverOffset,
45
45
  anchorRef: containerRef,
46
+ __unstableShift: true,
46
47
  }
47
48
  : undefined;
48
49
 
@@ -27,8 +27,8 @@ const BorderLabel = ( props: LabelProps ) => {
27
27
  );
28
28
  };
29
29
 
30
- const BorderControl = (
31
- props: WordPressComponentProps< BorderControlProps, 'div' >,
30
+ const UnconnectedBorderControl = (
31
+ props: WordPressComponentProps< BorderControlProps, 'div', false >,
32
32
  forwardedRef: React.ForwardedRef< any >
33
33
  ) => {
34
34
  const {
@@ -109,6 +109,43 @@ const BorderControl = (
109
109
  );
110
110
  };
111
111
 
112
- const ConnectedBorderControl = contextConnect( BorderControl, 'BorderControl' );
112
+ /**
113
+ * The `BorderControl` brings together internal sub-components which allow users to
114
+ * set the various properties of a border. The first sub-component, a
115
+ * `BorderDropdown` contains options representing border color and style. The
116
+ * border width is controlled via a `UnitControl` and an optional `RangeControl`.
117
+ *
118
+ * Border radius is not covered by this control as it may be desired separate to
119
+ * color, style, and width. For example, the border radius may be absorbed under
120
+ * a "shape" abstraction.
121
+ *
122
+ * ```jsx
123
+ * import { __experimentalBorderControl as BorderControl } from '@wordpress/components';
124
+ * import { __ } from '@wordpress/i18n';
125
+ *
126
+ * const colors = [
127
+ * { name: 'Blue 20', color: '#72aee6' },
128
+ * // ...
129
+ * ];
130
+ *
131
+ * const MyBorderControl = () => {
132
+ * const [ border, setBorder ] = useState();
133
+ * const onChange = ( newBorder ) => setBorder( newBorder );
134
+ *
135
+ * return (
136
+ * <BorderControl
137
+ * colors={ colors }
138
+ * label={ __( 'Border' ) }
139
+ * onChange={ onChange }
140
+ * value={ border }
141
+ * />
142
+ * );
143
+ * };
144
+ * ```
145
+ */
146
+ export const BorderControl = contextConnect(
147
+ UnconnectedBorderControl,
148
+ 'BorderControl'
149
+ );
113
150
 
114
- export default ConnectedBorderControl;
151
+ export default BorderControl;
@@ -0,0 +1,150 @@
1
+ /**
2
+ * External dependencies
3
+ */
4
+ import type { ComponentMeta, ComponentStory } from '@storybook/react';
5
+ import type { ComponentProps } from 'react';
6
+
7
+ /**
8
+ * WordPress dependencies
9
+ */
10
+ import { useState } from '@wordpress/element';
11
+
12
+ /**
13
+ * Internal dependencies
14
+ */
15
+ import { BorderControl } from '..';
16
+ import { Provider as SlotFillProvider } from '../../slot-fill';
17
+ import Popover from '../../popover';
18
+ import type { Border } from '../types';
19
+
20
+ const meta: ComponentMeta< typeof BorderControl > = {
21
+ title: 'Components (Experimental)/BorderControl',
22
+ component: BorderControl,
23
+ argTypes: {
24
+ onChange: {
25
+ action: 'onChange',
26
+ },
27
+ width: { control: { type: 'text' } },
28
+ value: { control: { type: null } },
29
+ },
30
+ parameters: {
31
+ controls: { expanded: true },
32
+ docs: { source: { state: 'open' } },
33
+ },
34
+ };
35
+ export default meta;
36
+
37
+ // Available border colors.
38
+ const colors = [
39
+ { name: 'Blue', color: '#72aee6' },
40
+ { name: 'Red', color: '#e65054' },
41
+ { name: 'Yellow', color: '#f2d675' },
42
+ ];
43
+
44
+ // Multiple origin colors.
45
+ const multipleOriginColors = [
46
+ {
47
+ name: 'Default',
48
+ colors: [
49
+ { name: 'Gray 20', color: '#a7aaad' },
50
+ { name: 'Gray 70', color: '#3c434a' },
51
+ ],
52
+ },
53
+ {
54
+ name: 'Theme',
55
+ colors: [
56
+ { name: 'Blue 20', color: '#72aee6' },
57
+ { name: 'Blue 40', color: '#3582c4' },
58
+ { name: 'Blue 70', color: '#0a4b78' },
59
+ ],
60
+ },
61
+ {
62
+ name: 'User',
63
+ colors: [
64
+ { name: 'Green', color: '#00a32a' },
65
+ { name: 'Yellow', color: '#f2d675' },
66
+ ],
67
+ },
68
+ ];
69
+
70
+ const Template: ComponentStory< typeof BorderControl > = ( {
71
+ onChange,
72
+ ...props
73
+ } ) => {
74
+ const [ border, setBorder ] = useState< Border >();
75
+ const onChangeMerged: ComponentProps<
76
+ typeof BorderControl
77
+ >[ 'onChange' ] = ( newBorder ) => {
78
+ setBorder( newBorder );
79
+ onChange( newBorder );
80
+ };
81
+
82
+ return (
83
+ <SlotFillProvider>
84
+ <div style={ { maxWidth: '280px' } }>
85
+ <BorderControl
86
+ onChange={ onChangeMerged }
87
+ value={ border }
88
+ { ...props }
89
+ />
90
+ </div>
91
+ { /* @ts-expect-error Ignore until Popover is converted to TS */ }
92
+ <Popover.Slot />
93
+ </SlotFillProvider>
94
+ );
95
+ };
96
+
97
+ export const Default = Template.bind( {} );
98
+ Default.args = {
99
+ colors,
100
+ label: 'Border',
101
+ };
102
+
103
+ /**
104
+ * Render a slider beside the control.
105
+ */
106
+ export const WithSlider = Template.bind( {} );
107
+ WithSlider.args = {
108
+ ...Default.args,
109
+ withSlider: true,
110
+ };
111
+
112
+ /**
113
+ * When rendering with a slider, the `width` prop is useful to customize the width of the number input.
114
+ */
115
+ export const WithSliderCustomWidth = Template.bind( {} );
116
+ WithSliderCustomWidth.args = {
117
+ ...Default.args,
118
+ withSlider: true,
119
+ width: '150px',
120
+ };
121
+ WithSliderCustomWidth.storyName = 'With Slider (Custom Width)';
122
+
123
+ /**
124
+ * Restrict the width of the control and prevent it from expanding to take up additional space.
125
+ * When `true`, the `width` prop will be ignored.
126
+ */
127
+ export const IsCompact = Template.bind( {} );
128
+ IsCompact.args = {
129
+ ...Default.args,
130
+ isCompact: true,
131
+ };
132
+
133
+ /**
134
+ * The `colors` object can contain multiple origins.
135
+ */
136
+ export const WithMultipleOrigins = Template.bind( {} );
137
+ WithMultipleOrigins.args = {
138
+ ...Default.args,
139
+ colors: multipleOriginColors,
140
+ __experimentalHasMultipleOrigins: true,
141
+ };
142
+
143
+ /**
144
+ * Allow the alpha channel to be edited on each color.
145
+ */
146
+ export const WithAlphaEnabled = Template.bind( {} );
147
+ WithAlphaEnabled.args = {
148
+ ...Default.args,
149
+ enableAlpha: true,
150
+ };
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * External dependencies
3
3
  */
4
- import { isEmpty, isNumber } from 'lodash';
4
+ import { isEmpty } from 'lodash';
5
5
 
6
6
  /**
7
7
  * WordPress dependencies
@@ -82,16 +82,16 @@ export function getAllValue(
82
82
  : '';
83
83
 
84
84
  /**
85
- * The isNumber check is important. On reset actions, the incoming value
85
+ * The typeof === 'number' check is important. On reset actions, the incoming value
86
86
  * may be null or an empty string.
87
87
  *
88
88
  * Also, the value may also be zero (0), which is considered a valid unit value.
89
89
  *
90
- * isNumber() is more specific for these cases, rather than relying on a
90
+ * typeof === 'number' is more specific for these cases, rather than relying on a
91
91
  * simple truthy check.
92
92
  */
93
93
  let commonUnit;
94
- if ( isNumber( commonQuantity ) ) {
94
+ if ( typeof commonQuantity === 'number' ) {
95
95
  commonUnit = mode( allParsedUnits );
96
96
  } else {
97
97
  // Set meaningful unit selection if no commonQuantity and user has previously
@@ -1,6 +1,6 @@
1
1
  # ColorIndicator
2
2
 
3
- ColorIndicator is a React component that renders a specific color in a squared box. It's often used to summarize a collection of used colors in a child component.
3
+ ColorIndicator is a React component that renders a specific color in a circle. It's often used to summarize a collection of used colors in a child component.
4
4
 
5
5
  ### Single component
6
6
 
@@ -22,16 +22,14 @@ const MyColorIndicator = () => <ColorIndicator colorValue="#0073aa" />;
22
22
 
23
23
  The component accepts the following props:
24
24
 
25
- ### colorValue
25
+ ### `className`: `string`
26
26
 
27
- The color of the indicator. Any value from the [`background`](https://developer.mozilla.org/en-US/docs/Web/CSS/background) property is supported.
27
+ Extra classes for the used `<span>` element. By default only `component-color-indicator` is added.
28
28
 
29
- - Type: `string`
30
- - Required: Yes
29
+ - Required: No
31
30
 
32
- ### className
31
+ ### `colorValue`: `CSSProperties[ 'background' ]`
33
32
 
34
- Extra classes for the used `<span>` element. By default only `component-color-indicator` is added.
33
+ The color of the indicator. Any value from the CSS [`background`](https://developer.mozilla.org/en-US/docs/Web/CSS/background) property is supported.
35
34
 
36
- - Type: `string`
37
- - Required: No
35
+ - Required: Yes
@@ -0,0 +1,47 @@
1
+ /**
2
+ * External dependencies
3
+ */
4
+ import classnames from 'classnames';
5
+ import type { ForwardedRef } from 'react';
6
+
7
+ /**
8
+ * WordPress dependencies
9
+ */
10
+ import { forwardRef } from '@wordpress/element';
11
+
12
+ /**
13
+ * Internal dependencies
14
+ */
15
+ import type { WordPressComponentProps } from '../ui/context';
16
+ import type { ColorIndicatorProps } from './types';
17
+
18
+ function UnforwardedColorIndicator(
19
+ props: WordPressComponentProps< ColorIndicatorProps, 'span', false >,
20
+ forwardedRef: ForwardedRef< HTMLSpanElement >
21
+ ) {
22
+ const { className, colorValue, ...additionalProps } = props;
23
+
24
+ return (
25
+ <span
26
+ className={ classnames( 'component-color-indicator', className ) }
27
+ style={ { background: colorValue } }
28
+ ref={ forwardedRef }
29
+ { ...additionalProps }
30
+ />
31
+ );
32
+ }
33
+
34
+ /**
35
+ * ColorIndicator is a React component that renders a specific color in a
36
+ * circle. It's often used to summarize a collection of used colors in a child
37
+ * component.
38
+ *
39
+ * ```jsx
40
+ * import { ColorIndicator } from '@wordpress/components';
41
+ *
42
+ * const MyColorIndicator = () => <ColorIndicator colorValue="#0073aa" />;
43
+ * ```
44
+ */
45
+ export const ColorIndicator = forwardRef( UnforwardedColorIndicator );
46
+
47
+ export default ColorIndicator;
@@ -0,0 +1,37 @@
1
+ /**
2
+ * External dependencies
3
+ */
4
+ import type { ComponentMeta, ComponentStory } from '@storybook/react';
5
+
6
+ /**
7
+ * Internal dependencies
8
+ */
9
+ import ColorIndicator from '..';
10
+
11
+ const meta: ComponentMeta< typeof ColorIndicator > = {
12
+ component: ColorIndicator,
13
+ title: 'Components/ColorIndicator',
14
+ argTypes: {
15
+ colorValue: {
16
+ control: { type: 'color' },
17
+ },
18
+ },
19
+ parameters: {
20
+ controls: {
21
+ expanded: true,
22
+ },
23
+ docs: { source: { state: 'open' } },
24
+ },
25
+ };
26
+ export default meta;
27
+
28
+ const Template: ComponentStory< typeof ColorIndicator > = ( { ...args } ) => (
29
+ <ColorIndicator { ...args } />
30
+ );
31
+
32
+ export const Default: ComponentStory< typeof ColorIndicator > = Template.bind(
33
+ {}
34
+ );
35
+ Default.args = {
36
+ colorValue: '#0073aa',
37
+ };
@@ -0,0 +1,11 @@
1
+ // Jest Snapshot v1, https://goo.gl/fbAQLP
2
+
3
+ exports[`ColorIndicator matches the snapshot 1`] = `
4
+ <div>
5
+ <span
6
+ aria-label="sample label"
7
+ class="component-color-indicator"
8
+ style="background: rgb(255, 255, 255);"
9
+ />
10
+ </div>
11
+ `;
@@ -1,19 +1,19 @@
1
1
  /**
2
2
  * External dependencies
3
3
  */
4
- import { shallow } from 'enzyme';
4
+ import { render } from '@testing-library/react';
5
5
 
6
6
  /**
7
7
  * Internal dependencies
8
8
  */
9
- import ColorIndicator from '../';
9
+ import ColorIndicator from '..';
10
10
 
11
11
  describe( 'ColorIndicator', () => {
12
12
  it( 'matches the snapshot', () => {
13
- const wrapper = shallow(
13
+ const { container } = render(
14
14
  <ColorIndicator aria-label="sample label" colorValue="#fff" />
15
15
  );
16
16
 
17
- expect( wrapper ).toMatchSnapshot();
17
+ expect( container ).toMatchSnapshot();
18
18
  } );
19
19
  } );
@@ -0,0 +1,12 @@
1
+ /**
2
+ * External dependencies
3
+ */
4
+ import type { CSSProperties } from 'react';
5
+
6
+ export type ColorIndicatorProps = {
7
+ /**
8
+ * The color of the indicator. Any value from the CSS `background` property
9
+ * is supported.
10
+ */
11
+ colorValue: CSSProperties[ 'background' ];
12
+ };
@@ -118,7 +118,11 @@ export function CustomColorPickerDropdown( { isRenderedInSidebar, ...props } ) {
118
118
  contentClassName="components-color-palette__custom-color-dropdown-content"
119
119
  popoverProps={
120
120
  isRenderedInSidebar
121
- ? { placement: 'left-start', offset: 20 }
121
+ ? {
122
+ placement: 'left-start',
123
+ offset: 20,
124
+ __unstableShift: true,
125
+ }
122
126
  : undefined
123
127
  }
124
128
  { ...props }
@@ -20,12 +20,12 @@ import {
20
20
  contextConnect,
21
21
  WordPressComponentProps,
22
22
  } from '../ui/context';
23
- import { HStack } from '../h-stack';
24
- import { Spacer } from '../spacer';
25
23
  import {
26
24
  ColorfulWrapper,
27
25
  SelectControl,
28
26
  AuxiliaryColorArtefactWrapper,
27
+ AuxiliaryColorArtefactHStackHeader,
28
+ ColorInputWrapper,
29
29
  } from './styles';
30
30
  import { ColorCopyButton } from './color-copy-button';
31
31
  import { ColorInput } from './color-input';
@@ -95,7 +95,7 @@ const ColorPicker = (
95
95
  enableAlpha={ enableAlpha }
96
96
  />
97
97
  <AuxiliaryColorArtefactWrapper>
98
- <HStack justify="space-between">
98
+ <AuxiliaryColorArtefactHStackHeader justify="space-between">
99
99
  <SelectControl
100
100
  options={ options }
101
101
  value={ colorType }
@@ -109,14 +109,15 @@ const ColorPicker = (
109
109
  color={ safeColordColor }
110
110
  colorType={ copyFormat || colorType }
111
111
  />
112
- </HStack>
113
- <Spacer margin={ 4 } />
114
- <ColorInput
115
- colorType={ colorType }
116
- color={ safeColordColor }
117
- onChange={ handleChange }
118
- enableAlpha={ enableAlpha }
119
- />
112
+ </AuxiliaryColorArtefactHStackHeader>
113
+ <ColorInputWrapper direction="column" gap={ 2 }>
114
+ <ColorInput
115
+ colorType={ colorType }
116
+ color={ safeColordColor }
117
+ onChange={ handleChange }
118
+ enableAlpha={ enableAlpha }
119
+ />
120
+ </ColorInputWrapper>
120
121
  </AuxiliaryColorArtefactWrapper>
121
122
  </ColorfulWrapper>
122
123
  );
@@ -26,7 +26,7 @@ export const InputWithSlider = ( {
26
26
  value,
27
27
  }: InputWithSliderProps ) => {
28
28
  return (
29
- <Spacer as={ HStack } spacing={ 4 }>
29
+ <HStack spacing={ 4 }>
30
30
  <NumberControlWrapper
31
31
  min={ min }
32
32
  max={ max }
@@ -55,6 +55,6 @@ export const InputWithSlider = ( {
55
55
  onChange={ onChange }
56
56
  withInputField={ false }
57
57
  />
58
- </Spacer>
58
+ </HStack>
59
59
  );
60
60
  };
@@ -12,6 +12,8 @@ import InnerRangeControl from '../range-control';
12
12
  import { StyledField } from '../base-control/styles/base-control-styles';
13
13
  import { space } from '../ui/utils/space';
14
14
  import Button from '../button';
15
+ import { Flex } from '../flex';
16
+ import { HStack } from '../h-stack';
15
17
  import {
16
18
  BackdropUI,
17
19
  Container as InputControlContainer,
@@ -36,6 +38,7 @@ export const SelectControl = styled( InnerSelectControl )`
36
38
 
37
39
  export const RangeControl = styled( InnerRangeControl )`
38
40
  flex: 1;
41
+ margin-right: ${ space( 2 ) };
39
42
 
40
43
  ${ StyledField } {
41
44
  margin-bottom: 0;
@@ -58,7 +61,22 @@ const interactiveHueStyles = `
58
61
  }`;
59
62
 
60
63
  export const AuxiliaryColorArtefactWrapper = styled.div`
61
- padding: ${ space( 2 ) } ${ space( 4 ) };
64
+ padding-top: ${ space( 2 ) };
65
+ padding-right: 0;
66
+ padding-left: 0;
67
+ padding-bottom: 0;
68
+ `;
69
+
70
+ export const AuxiliaryColorArtefactHStackHeader = styled( HStack )`
71
+ padding-left: ${ space( 4 ) };
72
+ padding-right: ${ space( 4 ) };
73
+ `;
74
+
75
+ export const ColorInputWrapper = styled( Flex )`
76
+ padding-top: ${ space( 4 ) };
77
+ padding-left: ${ space( 4 ) };
78
+ padding-right: ${ space( 3 ) };
79
+ padding-bottom: ${ space( 5 ) };
62
80
  `;
63
81
 
64
82
  export const ColorfulWrapper = styled.div`
@@ -70,6 +88,7 @@ export const ColorfulWrapper = styled.div`
70
88
  align-items: center;
71
89
  width: 216px;
72
90
  height: auto;
91
+ overflow: hidden;
73
92
  }
74
93
 
75
94
  .react-colorful__saturation {
@@ -1,8 +1,3 @@
1
- /**
2
- * External dependencies
3
- */
4
- import { get, omit } from 'lodash';
5
-
6
1
  /**
7
2
  * WordPress dependencies
8
3
  */
@@ -34,11 +29,8 @@ import {
34
29
  } from './styles/custom-gradient-picker-styles';
35
30
 
36
31
  const GradientAnglePicker = ( { gradientAST, hasGradient, onChange } ) => {
37
- const angle = get(
38
- gradientAST,
39
- [ 'orientation', 'value' ],
40
- DEFAULT_LINEAR_GRADIENT_ANGLE
41
- );
32
+ const angle =
33
+ gradientAST?.orientation?.value ?? DEFAULT_LINEAR_GRADIENT_ANGLE;
42
34
  const onAngleChange = ( newAngle ) => {
43
35
  onChange(
44
36
  serializeGradient( {
@@ -74,9 +66,10 @@ const GradientTypePicker = ( { gradientAST, hasGradient, onChange } ) => {
74
66
  };
75
67
 
76
68
  const onSetRadialGradient = () => {
69
+ const { orientation, ...restGradientAST } = gradientAST;
77
70
  onChange(
78
71
  serializeGradient( {
79
- ...omit( gradientAST, [ 'orientation' ] ),
72
+ ...restGradientAST,
80
73
  type: 'radial-gradient',
81
74
  } )
82
75
  );