@wordpress/components 28.3.0 → 28.5.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 (1233) hide show
  1. package/CHANGELOG.md +70 -1
  2. package/CONTRIBUTING.md +1 -1
  3. package/build/autocomplete/autocompleter-ui.js +2 -0
  4. package/build/autocomplete/autocompleter-ui.js.map +1 -1
  5. package/build/autocomplete/types.js.map +1 -1
  6. package/build/base-control/styles/base-control-styles.js +8 -8
  7. package/build/base-control/styles/base-control-styles.js.map +1 -1
  8. package/build/base-control/types.js.map +1 -1
  9. package/build/border-control/styles.js +18 -24
  10. package/build/border-control/styles.js.map +1 -1
  11. package/build/button/index.js +9 -7
  12. package/build/button/index.js.map +1 -1
  13. package/build/button/types.js.map +1 -1
  14. package/build/checkbox-control/index.js +1 -0
  15. package/build/checkbox-control/index.js.map +1 -1
  16. package/build/color-palette/index.js +1 -1
  17. package/build/color-palette/index.js.map +1 -1
  18. package/build/color-picker/component.js +8 -17
  19. package/build/color-picker/component.js.map +1 -1
  20. package/build/combobox-control/index.js +9 -0
  21. package/build/combobox-control/index.js.map +1 -1
  22. package/build/custom-select-control/index.js +141 -167
  23. package/build/custom-select-control/index.js.map +1 -1
  24. package/build/custom-select-control/types.js +6 -0
  25. package/build/custom-select-control/types.js.map +1 -0
  26. package/build/custom-select-control-v2/custom-select.js +4 -1
  27. package/build/custom-select-control-v2/custom-select.js.map +1 -1
  28. package/build/custom-select-control-v2/index.js +35 -7
  29. package/build/custom-select-control-v2/index.js.map +1 -1
  30. package/build/custom-select-control-v2/styles.js +25 -9
  31. package/build/custom-select-control-v2/styles.js.map +1 -1
  32. package/build/custom-select-control-v2/types.js.map +1 -1
  33. package/build/date-time/index.js +0 -7
  34. package/build/date-time/index.js.map +1 -1
  35. package/build/date-time/time/index.js +66 -38
  36. package/build/date-time/time/index.js.map +1 -1
  37. package/build/date-time/time/styles.js +11 -11
  38. package/build/date-time/time/styles.js.map +1 -1
  39. package/build/date-time/{time-input → time/time-input}/index.js +7 -7
  40. package/build/date-time/time/time-input/index.js.map +1 -0
  41. package/build/dropdown-menu-v2/styles.js +14 -14
  42. package/build/dropdown-menu-v2/styles.js.map +1 -1
  43. package/build/focal-point-picker/index.js +1 -0
  44. package/build/focal-point-picker/index.js.map +1 -1
  45. package/build/font-size-picker/font-size-picker-select.js +4 -4
  46. package/build/font-size-picker/font-size-picker-select.js.map +1 -1
  47. package/build/font-size-picker/index.js +36 -24
  48. package/build/font-size-picker/index.js.map +1 -1
  49. package/build/font-size-picker/types.js.map +1 -1
  50. package/build/form-toggle/index.js +24 -24
  51. package/build/form-toggle/index.js.map +1 -1
  52. package/build/form-token-field/index.js +8 -0
  53. package/build/form-token-field/index.js.map +1 -1
  54. package/build/guide/index.js +2 -0
  55. package/build/guide/index.js.map +1 -1
  56. package/build/heading/types.js.map +1 -1
  57. package/build/index.js +2 -2
  58. package/build/index.js.map +1 -1
  59. package/build/mobile/bottom-sheet/bottom-sheet-navigation/navigation-screen.native.js +1 -1
  60. package/build/mobile/bottom-sheet/bottom-sheet-navigation/navigation-screen.native.js.map +1 -1
  61. package/build/modal/index.js +18 -11
  62. package/build/modal/index.js.map +1 -1
  63. package/build/private-apis.js +0 -4
  64. package/build/private-apis.js.map +1 -1
  65. package/build/query-controls/index.js +1 -1
  66. package/build/query-controls/index.js.map +1 -1
  67. package/build/radio-control/index.js +34 -7
  68. package/build/radio-control/index.js.map +1 -1
  69. package/build/radio-control/types.js.map +1 -1
  70. package/build/range-control/index.js +1 -0
  71. package/build/range-control/index.js.map +1 -1
  72. package/build/select-control/index.js +25 -8
  73. package/build/select-control/index.js.map +1 -1
  74. package/build/select-control/styles/select-control-styles.js +42 -11
  75. package/build/select-control/styles/select-control-styles.js.map +1 -1
  76. package/build/select-control/types.js.map +1 -1
  77. package/build/tabs/styles.js +3 -3
  78. package/build/tabs/styles.js.map +1 -1
  79. package/build/tabs/tablist.js +4 -189
  80. package/build/tabs/tablist.js.map +1 -1
  81. package/build/text-control/index.js +1 -0
  82. package/build/text-control/index.js.map +1 -1
  83. package/build/textarea-control/index.js +1 -0
  84. package/build/textarea-control/index.js.map +1 -1
  85. package/build/toggle-control/index.js +36 -28
  86. package/build/toggle-control/index.js.map +1 -1
  87. package/build/toggle-group-control/toggle-group-control/component.js +6 -1
  88. package/build/toggle-group-control/toggle-group-control/component.js.map +1 -1
  89. package/build/toggle-group-control/toggle-group-control-option/component.js +6 -1
  90. package/build/toggle-group-control/toggle-group-control-option/component.js.map +1 -1
  91. package/build/toggle-group-control/toggle-group-control-option-base/component.js +3 -0
  92. package/build/toggle-group-control/toggle-group-control-option-base/component.js.map +1 -1
  93. package/build/toggle-group-control/toggle-group-control-option-base/styles.js +9 -9
  94. package/build/toggle-group-control/toggle-group-control-option-base/styles.js.map +1 -1
  95. package/build/toggle-group-control/toggle-group-control-option-icon/component.js +14 -14
  96. package/build/toggle-group-control/toggle-group-control-option-icon/component.js.map +1 -1
  97. package/build/tools-panel/tools-panel-header/component.js +1 -1
  98. package/build/tools-panel/tools-panel-header/component.js.map +1 -1
  99. package/build/tooltip/index.js +12 -1
  100. package/build/tooltip/index.js.map +1 -1
  101. package/build/tree-select/index.js +1 -1
  102. package/build/tree-select/index.js.map +1 -1
  103. package/build/utils/config-values.js +6 -0
  104. package/build/utils/config-values.js.map +1 -1
  105. package/build/utils/element-rect.js +157 -0
  106. package/build/utils/element-rect.js.map +1 -0
  107. package/build/utils/hooks/use-event.js +41 -0
  108. package/build/utils/hooks/use-event.js.map +1 -0
  109. package/build/utils/hooks/use-on-value-update.js +46 -0
  110. package/build/utils/hooks/use-on-value-update.js.map +1 -0
  111. package/build-module/autocomplete/autocompleter-ui.js +2 -0
  112. package/build-module/autocomplete/autocompleter-ui.js.map +1 -1
  113. package/build-module/autocomplete/types.js.map +1 -1
  114. package/build-module/base-control/styles/base-control-styles.js +8 -8
  115. package/build-module/base-control/styles/base-control-styles.js.map +1 -1
  116. package/build-module/base-control/types.js.map +1 -1
  117. package/build-module/border-control/styles.js +13 -23
  118. package/build-module/border-control/styles.js.map +1 -1
  119. package/build-module/button/index.js +9 -7
  120. package/build-module/button/index.js.map +1 -1
  121. package/build-module/button/types.js.map +1 -1
  122. package/build-module/checkbox-control/index.js +1 -0
  123. package/build-module/checkbox-control/index.js.map +1 -1
  124. package/build-module/color-palette/index.js +1 -1
  125. package/build-module/color-palette/index.js.map +1 -1
  126. package/build-module/color-picker/component.js +9 -18
  127. package/build-module/color-picker/component.js.map +1 -1
  128. package/build-module/combobox-control/index.js +9 -0
  129. package/build-module/combobox-control/index.js.map +1 -1
  130. package/build-module/custom-select-control/index.js +140 -166
  131. package/build-module/custom-select-control/index.js.map +1 -1
  132. package/build-module/custom-select-control/types.js +2 -0
  133. package/build-module/custom-select-control/types.js.map +1 -0
  134. package/build-module/custom-select-control-v2/custom-select.js +4 -1
  135. package/build-module/custom-select-control-v2/custom-select.js.map +1 -1
  136. package/build-module/custom-select-control-v2/index.js +27 -1
  137. package/build-module/custom-select-control-v2/index.js.map +1 -1
  138. package/build-module/custom-select-control-v2/styles.js +26 -10
  139. package/build-module/custom-select-control-v2/styles.js.map +1 -1
  140. package/build-module/custom-select-control-v2/types.js.map +1 -1
  141. package/build-module/date-time/index.js +1 -2
  142. package/build-module/date-time/index.js.map +1 -1
  143. package/build-module/date-time/time/index.js +66 -38
  144. package/build-module/date-time/time/index.js.map +1 -1
  145. package/build-module/date-time/time/styles.js +11 -11
  146. package/build-module/date-time/time/styles.js.map +1 -1
  147. package/build-module/date-time/{time-input → time/time-input}/index.js +7 -7
  148. package/build-module/date-time/time/time-input/index.js.map +1 -0
  149. package/build-module/dropdown-menu-v2/styles.js +14 -14
  150. package/build-module/dropdown-menu-v2/styles.js.map +1 -1
  151. package/build-module/focal-point-picker/index.js +1 -0
  152. package/build-module/focal-point-picker/index.js.map +1 -1
  153. package/build-module/font-size-picker/font-size-picker-select.js +3 -3
  154. package/build-module/font-size-picker/font-size-picker-select.js.map +1 -1
  155. package/build-module/font-size-picker/index.js +36 -24
  156. package/build-module/font-size-picker/index.js.map +1 -1
  157. package/build-module/font-size-picker/types.js.map +1 -1
  158. package/build-module/form-toggle/index.js +23 -22
  159. package/build-module/form-toggle/index.js.map +1 -1
  160. package/build-module/form-token-field/index.js +8 -0
  161. package/build-module/form-token-field/index.js.map +1 -1
  162. package/build-module/guide/index.js +2 -0
  163. package/build-module/guide/index.js.map +1 -1
  164. package/build-module/heading/types.js.map +1 -1
  165. package/build-module/index.js +1 -1
  166. package/build-module/index.js.map +1 -1
  167. package/build-module/mobile/bottom-sheet/bottom-sheet-navigation/navigation-screen.native.js +1 -1
  168. package/build-module/mobile/bottom-sheet/bottom-sheet-navigation/navigation-screen.native.js.map +1 -1
  169. package/build-module/modal/index.js +17 -11
  170. package/build-module/modal/index.js.map +1 -1
  171. package/build-module/private-apis.js +0 -4
  172. package/build-module/private-apis.js.map +1 -1
  173. package/build-module/query-controls/index.js +1 -1
  174. package/build-module/query-controls/index.js.map +1 -1
  175. package/build-module/radio-control/index.js +35 -9
  176. package/build-module/radio-control/index.js.map +1 -1
  177. package/build-module/radio-control/types.js.map +1 -1
  178. package/build-module/range-control/index.js +1 -0
  179. package/build-module/range-control/index.js.map +1 -1
  180. package/build-module/select-control/index.js +25 -8
  181. package/build-module/select-control/index.js.map +1 -1
  182. package/build-module/select-control/styles/select-control-styles.js +41 -6
  183. package/build-module/select-control/styles/select-control-styles.js.map +1 -1
  184. package/build-module/select-control/types.js.map +1 -1
  185. package/build-module/tabs/styles.js +3 -3
  186. package/build-module/tabs/styles.js.map +1 -1
  187. package/build-module/tabs/tablist.js +3 -188
  188. package/build-module/tabs/tablist.js.map +1 -1
  189. package/build-module/text-control/index.js +1 -0
  190. package/build-module/text-control/index.js.map +1 -1
  191. package/build-module/textarea-control/index.js +1 -0
  192. package/build-module/textarea-control/index.js.map +1 -1
  193. package/build-module/toggle-control/index.js +35 -27
  194. package/build-module/toggle-control/index.js.map +1 -1
  195. package/build-module/toggle-group-control/toggle-group-control/component.js +6 -1
  196. package/build-module/toggle-group-control/toggle-group-control/component.js.map +1 -1
  197. package/build-module/toggle-group-control/toggle-group-control-option/component.js +6 -1
  198. package/build-module/toggle-group-control/toggle-group-control-option/component.js.map +1 -1
  199. package/build-module/toggle-group-control/toggle-group-control-option-base/component.js +3 -0
  200. package/build-module/toggle-group-control/toggle-group-control-option-base/component.js.map +1 -1
  201. package/build-module/toggle-group-control/toggle-group-control-option-base/styles.js +9 -9
  202. package/build-module/toggle-group-control/toggle-group-control-option-base/styles.js.map +1 -1
  203. package/build-module/toggle-group-control/toggle-group-control-option-icon/component.js +14 -14
  204. package/build-module/toggle-group-control/toggle-group-control-option-icon/component.js.map +1 -1
  205. package/build-module/tools-panel/tools-panel-header/component.js +1 -1
  206. package/build-module/tools-panel/tools-panel-header/component.js.map +1 -1
  207. package/build-module/tooltip/index.js +13 -2
  208. package/build-module/tooltip/index.js.map +1 -1
  209. package/build-module/tree-select/index.js +1 -1
  210. package/build-module/tree-select/index.js.map +1 -1
  211. package/build-module/utils/config-values.js +6 -0
  212. package/build-module/utils/config-values.js.map +1 -1
  213. package/build-module/utils/element-rect.js +147 -0
  214. package/build-module/utils/element-rect.js.map +1 -0
  215. package/build-module/utils/hooks/use-event.js +35 -0
  216. package/build-module/utils/hooks/use-event.js.map +1 -0
  217. package/build-module/utils/hooks/use-on-value-update.js +39 -0
  218. package/build-module/utils/hooks/use-on-value-update.js.map +1 -0
  219. package/build-style/style-rtl.css +126 -123
  220. package/build-style/style.css +126 -123
  221. package/build-types/alignment-matrix-control/cell.d.ts +0 -1
  222. package/build-types/alignment-matrix-control/cell.d.ts.map +1 -1
  223. package/build-types/alignment-matrix-control/icon.d.ts +0 -1
  224. package/build-types/alignment-matrix-control/icon.d.ts.map +1 -1
  225. package/build-types/alignment-matrix-control/index.d.ts +0 -1
  226. package/build-types/alignment-matrix-control/index.d.ts.map +1 -1
  227. package/build-types/alignment-matrix-control/stories/index.story.d.ts +0 -1
  228. package/build-types/alignment-matrix-control/stories/index.story.d.ts.map +1 -1
  229. package/build-types/alignment-matrix-control/styles/alignment-matrix-control-icon-styles.d.ts +8 -9
  230. package/build-types/alignment-matrix-control/styles/alignment-matrix-control-icon-styles.d.ts.map +1 -1
  231. package/build-types/alignment-matrix-control/styles/alignment-matrix-control-styles.d.ts +10 -11
  232. package/build-types/alignment-matrix-control/styles/alignment-matrix-control-styles.d.ts.map +1 -1
  233. package/build-types/angle-picker-control/angle-circle.d.ts +0 -1
  234. package/build-types/angle-picker-control/angle-circle.d.ts.map +1 -1
  235. package/build-types/angle-picker-control/index.d.ts +0 -1
  236. package/build-types/angle-picker-control/index.d.ts.map +1 -1
  237. package/build-types/angle-picker-control/stories/index.story.d.ts +0 -1
  238. package/build-types/angle-picker-control/stories/index.story.d.ts.map +1 -1
  239. package/build-types/angle-picker-control/styles/angle-picker-control-styles.d.ts +7 -8
  240. package/build-types/angle-picker-control/styles/angle-picker-control-styles.d.ts.map +1 -1
  241. package/build-types/animate/index.d.ts +0 -1
  242. package/build-types/animate/index.d.ts.map +1 -1
  243. package/build-types/animate/types.d.ts +0 -1
  244. package/build-types/animate/types.d.ts.map +1 -1
  245. package/build-types/autocomplete/autocompleter-ui.d.ts +0 -1
  246. package/build-types/autocomplete/autocompleter-ui.d.ts.map +1 -1
  247. package/build-types/autocomplete/index.d.ts +2 -3
  248. package/build-types/autocomplete/index.d.ts.map +1 -1
  249. package/build-types/autocomplete/types.d.ts +2 -3
  250. package/build-types/autocomplete/types.d.ts.map +1 -1
  251. package/build-types/base-control/hooks.d.ts +3 -4
  252. package/build-types/base-control/hooks.d.ts.map +1 -1
  253. package/build-types/base-control/index.d.ts +0 -1
  254. package/build-types/base-control/index.d.ts.map +1 -1
  255. package/build-types/base-control/stories/index.story.d.ts +0 -1
  256. package/build-types/base-control/stories/index.story.d.ts.map +1 -1
  257. package/build-types/base-control/styles/base-control-styles.d.ts +10 -11
  258. package/build-types/base-control/styles/base-control-styles.d.ts.map +1 -1
  259. package/build-types/base-control/types.d.ts +1 -1
  260. package/build-types/border-box-control/border-box-control/component.d.ts +4 -5
  261. package/build-types/border-box-control/border-box-control/component.d.ts.map +1 -1
  262. package/build-types/border-box-control/border-box-control/hook.d.ts +14 -16
  263. package/build-types/border-box-control/border-box-control/hook.d.ts.map +1 -1
  264. package/build-types/border-box-control/border-box-control-linked-button/component.d.ts +0 -1
  265. package/build-types/border-box-control/border-box-control-linked-button/component.d.ts.map +1 -1
  266. package/build-types/border-box-control/border-box-control-linked-button/hook.d.ts +12 -14
  267. package/build-types/border-box-control/border-box-control-linked-button/hook.d.ts.map +1 -1
  268. package/build-types/border-box-control/border-box-control-split-controls/component.d.ts +5 -6
  269. package/build-types/border-box-control/border-box-control-split-controls/component.d.ts.map +1 -1
  270. package/build-types/border-box-control/border-box-control-split-controls/hook.d.ts +14 -16
  271. package/build-types/border-box-control/border-box-control-split-controls/hook.d.ts.map +1 -1
  272. package/build-types/border-box-control/border-box-control-visualizer/component.d.ts +1 -2
  273. package/build-types/border-box-control/border-box-control-visualizer/component.d.ts.map +1 -1
  274. package/build-types/border-box-control/border-box-control-visualizer/hook.d.ts +9 -11
  275. package/build-types/border-box-control/border-box-control-visualizer/hook.d.ts.map +1 -1
  276. package/build-types/border-box-control/stories/index.story.d.ts +4 -5
  277. package/build-types/border-box-control/stories/index.story.d.ts.map +1 -1
  278. package/build-types/border-box-control/styles.d.ts +3 -3
  279. package/build-types/border-box-control/utils.d.ts.map +1 -1
  280. package/build-types/border-control/border-control/component.d.ts +14 -15
  281. package/build-types/border-control/border-control/component.d.ts.map +1 -1
  282. package/build-types/border-control/border-control/hook.d.ts +17 -19
  283. package/build-types/border-control/border-control/hook.d.ts.map +1 -1
  284. package/build-types/border-control/border-control-dropdown/component.d.ts +6 -7
  285. package/build-types/border-control/border-control-dropdown/component.d.ts.map +1 -1
  286. package/build-types/border-control/border-control-dropdown/hook.d.ts +12 -14
  287. package/build-types/border-control/border-control-dropdown/hook.d.ts.map +1 -1
  288. package/build-types/border-control/border-control-style-picker/component.d.ts +2 -3
  289. package/build-types/border-control/border-control-style-picker/component.d.ts.map +1 -1
  290. package/build-types/border-control/stories/index.story.d.ts +84 -85
  291. package/build-types/border-control/stories/index.story.d.ts.map +1 -1
  292. package/build-types/border-control/styles.d.ts +2 -2
  293. package/build-types/border-control/styles.d.ts.map +1 -1
  294. package/build-types/box-control/all-input-control.d.ts +0 -1
  295. package/build-types/box-control/all-input-control.d.ts.map +1 -1
  296. package/build-types/box-control/axial-input-controls.d.ts +0 -1
  297. package/build-types/box-control/axial-input-controls.d.ts.map +1 -1
  298. package/build-types/box-control/icon.d.ts +0 -1
  299. package/build-types/box-control/icon.d.ts.map +1 -1
  300. package/build-types/box-control/index.d.ts +0 -1
  301. package/build-types/box-control/index.d.ts.map +1 -1
  302. package/build-types/box-control/input-controls.d.ts +0 -1
  303. package/build-types/box-control/input-controls.d.ts.map +1 -1
  304. package/build-types/box-control/linked-button.d.ts +0 -1
  305. package/build-types/box-control/linked-button.d.ts.map +1 -1
  306. package/build-types/box-control/stories/index.story.d.ts +312 -350
  307. package/build-types/box-control/stories/index.story.d.ts.map +1 -1
  308. package/build-types/box-control/styles/box-control-icon-styles.d.ts +16 -17
  309. package/build-types/box-control/styles/box-control-icon-styles.d.ts.map +1 -1
  310. package/build-types/box-control/styles/box-control-styles.d.ts +44 -45
  311. package/build-types/box-control/styles/box-control-styles.d.ts.map +1 -1
  312. package/build-types/box-control/types.d.ts +0 -1
  313. package/build-types/box-control/types.d.ts.map +1 -1
  314. package/build-types/button/deprecated.d.ts +69 -70
  315. package/build-types/button/deprecated.d.ts.map +1 -1
  316. package/build-types/button/index.d.ts.map +1 -1
  317. package/build-types/button/stories/e2e/index.story.d.ts +0 -1
  318. package/build-types/button/stories/e2e/index.story.d.ts.map +1 -1
  319. package/build-types/button/stories/index.story.d.ts +0 -1
  320. package/build-types/button/stories/index.story.d.ts.map +1 -1
  321. package/build-types/button/types.d.ts +9 -2
  322. package/build-types/button/types.d.ts.map +1 -1
  323. package/build-types/button-group/index.d.ts +0 -1
  324. package/build-types/button-group/index.d.ts.map +1 -1
  325. package/build-types/card/card/component.d.ts +5 -6
  326. package/build-types/card/card/component.d.ts.map +1 -1
  327. package/build-types/card/card/hook.d.ts +10 -12
  328. package/build-types/card/card/hook.d.ts.map +1 -1
  329. package/build-types/card/card-body/component.d.ts +4 -5
  330. package/build-types/card/card-body/component.d.ts.map +1 -1
  331. package/build-types/card/card-body/hook.d.ts +10 -12
  332. package/build-types/card/card-body/hook.d.ts.map +1 -1
  333. package/build-types/card/card-divider/component.d.ts +4 -5
  334. package/build-types/card/card-divider/component.d.ts.map +1 -1
  335. package/build-types/card/card-divider/hook.d.ts +15 -17
  336. package/build-types/card/card-divider/hook.d.ts.map +1 -1
  337. package/build-types/card/card-footer/component.d.ts +5 -6
  338. package/build-types/card/card-footer/component.d.ts.map +1 -1
  339. package/build-types/card/card-footer/hook.d.ts +10 -12
  340. package/build-types/card/card-footer/hook.d.ts.map +1 -1
  341. package/build-types/card/card-header/component.d.ts +4 -5
  342. package/build-types/card/card-header/component.d.ts.map +1 -1
  343. package/build-types/card/card-header/hook.d.ts +10 -12
  344. package/build-types/card/card-header/hook.d.ts.map +1 -1
  345. package/build-types/card/card-media/component.d.ts +0 -1
  346. package/build-types/card/card-media/component.d.ts.map +1 -1
  347. package/build-types/card/card-media/hook.d.ts +10 -12
  348. package/build-types/card/card-media/hook.d.ts.map +1 -1
  349. package/build-types/card/context.d.ts +0 -1
  350. package/build-types/card/context.d.ts.map +1 -1
  351. package/build-types/card/stories/index.story.d.ts +3 -22
  352. package/build-types/card/stories/index.story.d.ts.map +1 -1
  353. package/build-types/checkbox-control/index.d.ts +1 -1
  354. package/build-types/checkbox-control/index.d.ts.map +1 -1
  355. package/build-types/circular-option-picker/circular-option-picker-actions.d.ts +0 -1
  356. package/build-types/circular-option-picker/circular-option-picker-actions.d.ts.map +1 -1
  357. package/build-types/circular-option-picker/circular-option-picker-context.d.ts +0 -1
  358. package/build-types/circular-option-picker/circular-option-picker-context.d.ts.map +1 -1
  359. package/build-types/circular-option-picker/circular-option-picker-option-group.d.ts +0 -1
  360. package/build-types/circular-option-picker/circular-option-picker-option-group.d.ts.map +1 -1
  361. package/build-types/circular-option-picker/circular-option-picker-option.d.ts +0 -1
  362. package/build-types/circular-option-picker/circular-option-picker-option.d.ts.map +1 -1
  363. package/build-types/circular-option-picker/circular-option-picker.d.ts +0 -1
  364. package/build-types/circular-option-picker/circular-option-picker.d.ts.map +1 -1
  365. package/build-types/clipboard-button/index.d.ts +0 -1
  366. package/build-types/clipboard-button/index.d.ts.map +1 -1
  367. package/build-types/color-indicator/index.d.ts +0 -1
  368. package/build-types/color-indicator/index.d.ts.map +1 -1
  369. package/build-types/color-palette/index.d.ts +0 -1
  370. package/build-types/color-palette/index.d.ts.map +1 -1
  371. package/build-types/color-palette/stories/index.story.d.ts +0 -1
  372. package/build-types/color-palette/stories/index.story.d.ts.map +1 -1
  373. package/build-types/color-palette/styles.d.ts +7 -8
  374. package/build-types/color-palette/styles.d.ts.map +1 -1
  375. package/build-types/color-palette/utils.d.ts +1 -1
  376. package/build-types/color-palette/utils.d.ts.map +1 -1
  377. package/build-types/color-picker/color-copy-button.d.ts +0 -1
  378. package/build-types/color-picker/color-copy-button.d.ts.map +1 -1
  379. package/build-types/color-picker/color-input.d.ts +0 -1
  380. package/build-types/color-picker/color-input.d.ts.map +1 -1
  381. package/build-types/color-picker/component.d.ts +5 -6
  382. package/build-types/color-picker/component.d.ts.map +1 -1
  383. package/build-types/color-picker/hex-input.d.ts +0 -1
  384. package/build-types/color-picker/hex-input.d.ts.map +1 -1
  385. package/build-types/color-picker/hsl-input.d.ts +0 -1
  386. package/build-types/color-picker/hsl-input.d.ts.map +1 -1
  387. package/build-types/color-picker/input-with-slider.d.ts +0 -1
  388. package/build-types/color-picker/input-with-slider.d.ts.map +1 -1
  389. package/build-types/color-picker/legacy-adapter.d.ts +0 -1
  390. package/build-types/color-picker/legacy-adapter.d.ts.map +1 -1
  391. package/build-types/color-picker/picker.d.ts +0 -1
  392. package/build-types/color-picker/picker.d.ts.map +1 -1
  393. package/build-types/color-picker/rgb-input.d.ts +0 -1
  394. package/build-types/color-picker/rgb-input.d.ts.map +1 -1
  395. package/build-types/color-picker/stories/index.story.d.ts +2 -9
  396. package/build-types/color-picker/stories/index.story.d.ts.map +1 -1
  397. package/build-types/color-picker/styles.d.ts +55 -54
  398. package/build-types/color-picker/styles.d.ts.map +1 -1
  399. package/build-types/combobox-control/index.d.ts +1 -1
  400. package/build-types/combobox-control/index.d.ts.map +1 -1
  401. package/build-types/combobox-control/stories/index.story.d.ts +41 -41
  402. package/build-types/combobox-control/stories/index.story.d.ts.map +1 -1
  403. package/build-types/combobox-control/styles.d.ts +1 -2
  404. package/build-types/combobox-control/styles.d.ts.map +1 -1
  405. package/build-types/combobox-control/types.d.ts +0 -1
  406. package/build-types/combobox-control/types.d.ts.map +1 -1
  407. package/build-types/composite/current/stories/utils.d.ts +0 -1
  408. package/build-types/composite/current/stories/utils.d.ts.map +1 -1
  409. package/build-types/composite/legacy/index.d.ts +0 -1
  410. package/build-types/composite/legacy/index.d.ts.map +1 -1
  411. package/build-types/composite/legacy/stories/utils.d.ts +0 -1
  412. package/build-types/composite/legacy/stories/utils.d.ts.map +1 -1
  413. package/build-types/confirm-dialog/component.d.ts +0 -1
  414. package/build-types/confirm-dialog/component.d.ts.map +1 -1
  415. package/build-types/confirm-dialog/stories/index.story.d.ts +0 -1
  416. package/build-types/confirm-dialog/stories/index.story.d.ts.map +1 -1
  417. package/build-types/context/context-system-provider.d.ts +1 -1
  418. package/build-types/context/context-system-provider.d.ts.map +1 -1
  419. package/build-types/context/get-styled-class-name-from-key.d.ts +9 -1
  420. package/build-types/context/get-styled-class-name-from-key.d.ts.map +1 -1
  421. package/build-types/context/use-context-system.d.ts +1 -1
  422. package/build-types/context/use-context-system.d.ts.map +1 -1
  423. package/build-types/context/utils.d.ts.map +1 -1
  424. package/build-types/custom-gradient-picker/gradient-bar/control-points.d.ts +0 -1
  425. package/build-types/custom-gradient-picker/gradient-bar/control-points.d.ts.map +1 -1
  426. package/build-types/custom-gradient-picker/gradient-bar/index.d.ts +0 -1
  427. package/build-types/custom-gradient-picker/gradient-bar/index.d.ts.map +1 -1
  428. package/build-types/custom-gradient-picker/index.d.ts +0 -1
  429. package/build-types/custom-gradient-picker/index.d.ts.map +1 -1
  430. package/build-types/custom-gradient-picker/styles/custom-gradient-picker-styles.d.ts +2 -3
  431. package/build-types/custom-gradient-picker/styles/custom-gradient-picker-styles.d.ts.map +1 -1
  432. package/build-types/custom-gradient-picker/types.d.ts +0 -1
  433. package/build-types/custom-gradient-picker/types.d.ts.map +1 -1
  434. package/build-types/custom-gradient-picker/utils.d.ts.map +1 -1
  435. package/build-types/custom-select-control/index.d.ts +3 -2
  436. package/build-types/custom-select-control/index.d.ts.map +1 -1
  437. package/build-types/custom-select-control/stories/index.story.d.ts +6 -42
  438. package/build-types/custom-select-control/stories/index.story.d.ts.map +1 -1
  439. package/build-types/custom-select-control/test/index.d.ts.map +1 -0
  440. package/build-types/custom-select-control/types.d.ts +122 -0
  441. package/build-types/custom-select-control/types.d.ts.map +1 -0
  442. package/build-types/custom-select-control-v2/custom-select.d.ts +0 -1
  443. package/build-types/custom-select-control-v2/custom-select.d.ts.map +1 -1
  444. package/build-types/custom-select-control-v2/index.d.ts +7 -4
  445. package/build-types/custom-select-control-v2/index.d.ts.map +1 -1
  446. package/build-types/custom-select-control-v2/item.d.ts +0 -1
  447. package/build-types/custom-select-control-v2/item.d.ts.map +1 -1
  448. package/build-types/custom-select-control-v2/stories/{default.story.d.ts → index.story.d.ts} +10 -11
  449. package/build-types/custom-select-control-v2/stories/index.story.d.ts.map +1 -0
  450. package/build-types/custom-select-control-v2/styles.d.ts +30 -43
  451. package/build-types/custom-select-control-v2/styles.d.ts.map +1 -1
  452. package/build-types/custom-select-control-v2/types.d.ts +0 -106
  453. package/build-types/custom-select-control-v2/types.d.ts.map +1 -1
  454. package/build-types/dashicon/index.d.ts +0 -1
  455. package/build-types/dashicon/index.d.ts.map +1 -1
  456. package/build-types/date-time/date/index.d.ts +0 -1
  457. package/build-types/date-time/date/index.d.ts.map +1 -1
  458. package/build-types/date-time/date/styles.d.ts +17 -18
  459. package/build-types/date-time/date/styles.d.ts.map +1 -1
  460. package/build-types/date-time/date-time/index.d.ts +1 -2
  461. package/build-types/date-time/date-time/index.d.ts.map +1 -1
  462. package/build-types/date-time/date-time/styles.d.ts +3 -4
  463. package/build-types/date-time/date-time/styles.d.ts.map +1 -1
  464. package/build-types/date-time/index.d.ts +1 -2
  465. package/build-types/date-time/index.d.ts.map +1 -1
  466. package/build-types/date-time/stories/time.story.d.ts +5 -0
  467. package/build-types/date-time/stories/time.story.d.ts.map +1 -1
  468. package/build-types/date-time/time/index.d.ts +3 -1
  469. package/build-types/date-time/time/index.d.ts.map +1 -1
  470. package/build-types/date-time/time/styles.d.ts +64 -65
  471. package/build-types/date-time/time/styles.d.ts.map +1 -1
  472. package/build-types/date-time/{time-input → time/time-input}/index.d.ts +1 -2
  473. package/build-types/date-time/time/time-input/index.d.ts.map +1 -0
  474. package/build-types/date-time/time/time-input/test/index.d.ts.map +1 -0
  475. package/build-types/date-time/time/timezone.d.ts +0 -1
  476. package/build-types/date-time/time/timezone.d.ts.map +1 -1
  477. package/build-types/date-time/types.d.ts +0 -1
  478. package/build-types/date-time/types.d.ts.map +1 -1
  479. package/build-types/date-time/utils.d.ts +3 -4
  480. package/build-types/date-time/utils.d.ts.map +1 -1
  481. package/build-types/dimension-control/index.d.ts +0 -1
  482. package/build-types/dimension-control/index.d.ts.map +1 -1
  483. package/build-types/disabled/index.d.ts +0 -1
  484. package/build-types/disabled/index.d.ts.map +1 -1
  485. package/build-types/disabled/types.d.ts +0 -1
  486. package/build-types/disabled/types.d.ts.map +1 -1
  487. package/build-types/disclosure/index.d.ts +0 -1
  488. package/build-types/disclosure/index.d.ts.map +1 -1
  489. package/build-types/disclosure/types.d.ts +0 -1
  490. package/build-types/disclosure/types.d.ts.map +1 -1
  491. package/build-types/divider/component.d.ts +4 -5
  492. package/build-types/divider/component.d.ts.map +1 -1
  493. package/build-types/divider/styles.d.ts +6 -7
  494. package/build-types/divider/styles.d.ts.map +1 -1
  495. package/build-types/draggable/index.d.ts +0 -1
  496. package/build-types/draggable/index.d.ts.map +1 -1
  497. package/build-types/drop-zone/index.d.ts +0 -1
  498. package/build-types/drop-zone/index.d.ts.map +1 -1
  499. package/build-types/drop-zone/provider.d.ts +0 -1
  500. package/build-types/drop-zone/provider.d.ts.map +1 -1
  501. package/build-types/drop-zone/stories/index.story.d.ts +0 -1
  502. package/build-types/drop-zone/stories/index.story.d.ts.map +1 -1
  503. package/build-types/dropdown/dropdown-content-wrapper.d.ts +0 -1
  504. package/build-types/dropdown/dropdown-content-wrapper.d.ts.map +1 -1
  505. package/build-types/dropdown/index.d.ts +0 -1
  506. package/build-types/dropdown/index.d.ts.map +1 -1
  507. package/build-types/dropdown/stories/index.story.d.ts +5 -6
  508. package/build-types/dropdown/stories/index.story.d.ts.map +1 -1
  509. package/build-types/dropdown/styles.d.ts +2 -3
  510. package/build-types/dropdown/styles.d.ts.map +1 -1
  511. package/build-types/dropdown-menu/index.d.ts +0 -1
  512. package/build-types/dropdown-menu/index.d.ts.map +1 -1
  513. package/build-types/dropdown-menu/stories/index.story.d.ts +3 -4
  514. package/build-types/dropdown-menu/stories/index.story.d.ts.map +1 -1
  515. package/build-types/dropdown-menu-v2/index.d.ts +0 -1
  516. package/build-types/dropdown-menu-v2/index.d.ts.map +1 -1
  517. package/build-types/dropdown-menu-v2/stories/index.story.d.ts.map +1 -1
  518. package/build-types/dropdown-menu-v2/styles.d.ts +41 -60
  519. package/build-types/dropdown-menu-v2/styles.d.ts.map +1 -1
  520. package/build-types/dropdown-menu-v2/types.d.ts +0 -1
  521. package/build-types/dropdown-menu-v2/types.d.ts.map +1 -1
  522. package/build-types/duotone-picker/color-list-picker/index.d.ts +0 -1
  523. package/build-types/duotone-picker/color-list-picker/index.d.ts.map +1 -1
  524. package/build-types/duotone-picker/custom-duotone-bar.d.ts +0 -1
  525. package/build-types/duotone-picker/custom-duotone-bar.d.ts.map +1 -1
  526. package/build-types/duotone-picker/duotone-picker.d.ts +0 -1
  527. package/build-types/duotone-picker/duotone-picker.d.ts.map +1 -1
  528. package/build-types/duotone-picker/duotone-swatch.d.ts +0 -1
  529. package/build-types/duotone-picker/duotone-swatch.d.ts.map +1 -1
  530. package/build-types/elevation/component.d.ts +0 -1
  531. package/build-types/elevation/component.d.ts.map +1 -1
  532. package/build-types/elevation/hook.d.ts +9 -11
  533. package/build-types/elevation/hook.d.ts.map +1 -1
  534. package/build-types/external-link/index.d.ts +0 -1
  535. package/build-types/external-link/index.d.ts.map +1 -1
  536. package/build-types/flex/context.d.ts +2 -3
  537. package/build-types/flex/context.d.ts.map +1 -1
  538. package/build-types/flex/flex/component.d.ts +0 -1
  539. package/build-types/flex/flex/component.d.ts.map +1 -1
  540. package/build-types/flex/flex/hook.d.ts +9 -11
  541. package/build-types/flex/flex/hook.d.ts.map +1 -1
  542. package/build-types/flex/flex-block/component.d.ts +0 -1
  543. package/build-types/flex/flex-block/component.d.ts.map +1 -1
  544. package/build-types/flex/flex-block/hook.d.ts +9 -11
  545. package/build-types/flex/flex-block/hook.d.ts.map +1 -1
  546. package/build-types/flex/flex-item/component.d.ts +0 -1
  547. package/build-types/flex/flex-item/component.d.ts.map +1 -1
  548. package/build-types/flex/flex-item/hook.d.ts +9 -11
  549. package/build-types/flex/flex-item/hook.d.ts.map +1 -1
  550. package/build-types/focal-point-picker/controls.d.ts +0 -1
  551. package/build-types/focal-point-picker/controls.d.ts.map +1 -1
  552. package/build-types/focal-point-picker/focal-point.d.ts +0 -1
  553. package/build-types/focal-point-picker/focal-point.d.ts.map +1 -1
  554. package/build-types/focal-point-picker/grid.d.ts +0 -1
  555. package/build-types/focal-point-picker/grid.d.ts.map +1 -1
  556. package/build-types/focal-point-picker/index.d.ts +1 -1
  557. package/build-types/focal-point-picker/index.d.ts.map +1 -1
  558. package/build-types/focal-point-picker/media.d.ts +0 -1
  559. package/build-types/focal-point-picker/media.d.ts.map +1 -1
  560. package/build-types/focal-point-picker/stories/index.story.d.ts +32 -33
  561. package/build-types/focal-point-picker/stories/index.story.d.ts.map +1 -1
  562. package/build-types/focal-point-picker/styles/focal-point-picker-style.d.ts +26 -27
  563. package/build-types/focal-point-picker/styles/focal-point-picker-style.d.ts.map +1 -1
  564. package/build-types/focal-point-picker/styles/focal-point-style.d.ts +2 -3
  565. package/build-types/focal-point-picker/styles/focal-point-style.d.ts.map +1 -1
  566. package/build-types/focusable-iframe/index.d.ts +0 -1
  567. package/build-types/focusable-iframe/index.d.ts.map +1 -1
  568. package/build-types/font-size-picker/font-size-picker-select.d.ts +0 -1
  569. package/build-types/font-size-picker/font-size-picker-select.d.ts.map +1 -1
  570. package/build-types/font-size-picker/font-size-picker-toggle-group.d.ts +0 -1
  571. package/build-types/font-size-picker/font-size-picker-toggle-group.d.ts.map +1 -1
  572. package/build-types/font-size-picker/index.d.ts +0 -1
  573. package/build-types/font-size-picker/index.d.ts.map +1 -1
  574. package/build-types/font-size-picker/stories/e2e/index.story.d.ts +0 -1
  575. package/build-types/font-size-picker/stories/e2e/index.story.d.ts.map +1 -1
  576. package/build-types/font-size-picker/styles.d.ts +9 -10
  577. package/build-types/font-size-picker/styles.d.ts.map +1 -1
  578. package/build-types/font-size-picker/types.d.ts +6 -5
  579. package/build-types/font-size-picker/types.d.ts.map +1 -1
  580. package/build-types/form-file-upload/index.d.ts +0 -1
  581. package/build-types/form-file-upload/index.d.ts.map +1 -1
  582. package/build-types/form-file-upload/stories/index.story.d.ts +0 -1
  583. package/build-types/form-file-upload/stories/index.story.d.ts.map +1 -1
  584. package/build-types/form-toggle/index.d.ts +2 -5
  585. package/build-types/form-toggle/index.d.ts.map +1 -1
  586. package/build-types/form-token-field/index.d.ts +0 -1
  587. package/build-types/form-token-field/index.d.ts.map +1 -1
  588. package/build-types/form-token-field/stories/index.story.d.ts.map +1 -1
  589. package/build-types/form-token-field/styles.d.ts +1 -2
  590. package/build-types/form-token-field/styles.d.ts.map +1 -1
  591. package/build-types/form-token-field/suggestions-list.d.ts +0 -1
  592. package/build-types/form-token-field/suggestions-list.d.ts.map +1 -1
  593. package/build-types/form-token-field/token.d.ts +0 -1
  594. package/build-types/form-token-field/token.d.ts.map +1 -1
  595. package/build-types/gradient-picker/index.d.ts +0 -1
  596. package/build-types/gradient-picker/index.d.ts.map +1 -1
  597. package/build-types/gradient-picker/types.d.ts +0 -1
  598. package/build-types/gradient-picker/types.d.ts.map +1 -1
  599. package/build-types/grid/component.d.ts +0 -1
  600. package/build-types/grid/component.d.ts.map +1 -1
  601. package/build-types/grid/hook.d.ts +9 -11
  602. package/build-types/grid/hook.d.ts.map +1 -1
  603. package/build-types/guide/icons.d.ts +0 -1
  604. package/build-types/guide/icons.d.ts.map +1 -1
  605. package/build-types/guide/index.d.ts +0 -1
  606. package/build-types/guide/index.d.ts.map +1 -1
  607. package/build-types/guide/page-control.d.ts +0 -1
  608. package/build-types/guide/page-control.d.ts.map +1 -1
  609. package/build-types/guide/page.d.ts +0 -1
  610. package/build-types/guide/page.d.ts.map +1 -1
  611. package/build-types/h-stack/component.d.ts +2 -3
  612. package/build-types/h-stack/component.d.ts.map +1 -1
  613. package/build-types/h-stack/hook.d.ts +9 -11
  614. package/build-types/h-stack/hook.d.ts.map +1 -1
  615. package/build-types/heading/component.d.ts +5 -6
  616. package/build-types/heading/component.d.ts.map +1 -1
  617. package/build-types/heading/hook.d.ts +9 -11
  618. package/build-types/heading/hook.d.ts.map +1 -1
  619. package/build-types/heading/types.d.ts +1 -1
  620. package/build-types/heading/types.d.ts.map +1 -1
  621. package/build-types/higher-order/navigate-regions/index.d.ts +1 -2
  622. package/build-types/higher-order/navigate-regions/index.d.ts.map +1 -1
  623. package/build-types/higher-order/with-constrained-tabbing/index.d.ts +0 -1
  624. package/build-types/higher-order/with-constrained-tabbing/index.d.ts.map +1 -1
  625. package/build-types/higher-order/with-fallback-styles/index.d.ts +3 -4
  626. package/build-types/higher-order/with-fallback-styles/index.d.ts.map +1 -1
  627. package/build-types/higher-order/with-filters/index.d.ts +4 -5
  628. package/build-types/higher-order/with-filters/index.d.ts.map +1 -1
  629. package/build-types/higher-order/with-focus-outside/index.d.ts +0 -1
  630. package/build-types/higher-order/with-focus-outside/index.d.ts.map +1 -1
  631. package/build-types/higher-order/with-focus-return/index.d.ts +0 -1
  632. package/build-types/higher-order/with-focus-return/index.d.ts.map +1 -1
  633. package/build-types/higher-order/with-notices/index.d.ts +0 -1
  634. package/build-types/higher-order/with-notices/index.d.ts.map +1 -1
  635. package/build-types/higher-order/with-notices/types.d.ts +0 -1
  636. package/build-types/higher-order/with-notices/types.d.ts.map +1 -1
  637. package/build-types/higher-order/with-spoken-messages/index.d.ts +0 -1
  638. package/build-types/higher-order/with-spoken-messages/index.d.ts.map +1 -1
  639. package/build-types/index.d.ts +1 -1
  640. package/build-types/index.d.ts.map +1 -1
  641. package/build-types/input-control/backdrop.d.ts +0 -1
  642. package/build-types/input-control/backdrop.d.ts.map +1 -1
  643. package/build-types/input-control/input-base.d.ts +0 -1
  644. package/build-types/input-control/input-base.d.ts.map +1 -1
  645. package/build-types/input-control/input-field.d.ts +0 -1
  646. package/build-types/input-control/input-field.d.ts.map +1 -1
  647. package/build-types/input-control/input-prefix-wrapper.d.ts +0 -1
  648. package/build-types/input-control/input-prefix-wrapper.d.ts.map +1 -1
  649. package/build-types/input-control/input-suffix-wrapper.d.ts +0 -1
  650. package/build-types/input-control/input-suffix-wrapper.d.ts.map +1 -1
  651. package/build-types/input-control/label.d.ts +0 -1
  652. package/build-types/input-control/label.d.ts.map +1 -1
  653. package/build-types/input-control/reducer/reducer.d.ts +9 -9
  654. package/build-types/input-control/reducer/reducer.d.ts.map +1 -1
  655. package/build-types/input-control/stories/index.story.d.ts +0 -1
  656. package/build-types/input-control/stories/index.story.d.ts.map +1 -1
  657. package/build-types/input-control/styles/input-control-styles.d.ts +13 -13
  658. package/build-types/input-control/styles/input-control-styles.d.ts.map +1 -1
  659. package/build-types/isolated-event-container/index.d.ts +0 -1
  660. package/build-types/isolated-event-container/index.d.ts.map +1 -1
  661. package/build-types/item-group/context.d.ts +0 -1
  662. package/build-types/item-group/context.d.ts.map +1 -1
  663. package/build-types/item-group/item/component.d.ts +0 -1
  664. package/build-types/item-group/item/component.d.ts.map +1 -1
  665. package/build-types/item-group/item/hook.d.ts +10 -12
  666. package/build-types/item-group/item/hook.d.ts.map +1 -1
  667. package/build-types/item-group/item-group/component.d.ts +0 -1
  668. package/build-types/item-group/item-group/component.d.ts.map +1 -1
  669. package/build-types/item-group/item-group/hook.d.ts +11 -13
  670. package/build-types/item-group/item-group/hook.d.ts.map +1 -1
  671. package/build-types/item-group/styles.d.ts +1 -1
  672. package/build-types/item-group/types.d.ts +0 -1
  673. package/build-types/item-group/types.d.ts.map +1 -1
  674. package/build-types/keyboard-shortcuts/index.d.ts +0 -1
  675. package/build-types/keyboard-shortcuts/index.d.ts.map +1 -1
  676. package/build-types/keyboard-shortcuts/types.d.ts +0 -1
  677. package/build-types/keyboard-shortcuts/types.d.ts.map +1 -1
  678. package/build-types/menu-group/index.d.ts +0 -1
  679. package/build-types/menu-group/index.d.ts.map +1 -1
  680. package/build-types/menu-item/index.d.ts +8 -9
  681. package/build-types/menu-item/index.d.ts.map +1 -1
  682. package/build-types/menu-item/stories/index.story.d.ts +32 -33
  683. package/build-types/menu-item/stories/index.story.d.ts.map +1 -1
  684. package/build-types/menu-items-choice/index.d.ts +0 -1
  685. package/build-types/menu-items-choice/index.d.ts.map +1 -1
  686. package/build-types/modal/index.d.ts +0 -1
  687. package/build-types/modal/index.d.ts.map +1 -1
  688. package/build-types/navigable-container/container.d.ts +8 -8
  689. package/build-types/navigable-container/menu.d.ts +7 -7
  690. package/build-types/navigable-container/tabbable.d.ts +6 -6
  691. package/build-types/navigation/back-button/index.d.ts +0 -1
  692. package/build-types/navigation/back-button/index.d.ts.map +1 -1
  693. package/build-types/navigation/context.d.ts +0 -1
  694. package/build-types/navigation/context.d.ts.map +1 -1
  695. package/build-types/navigation/group/context.d.ts +0 -1
  696. package/build-types/navigation/group/context.d.ts.map +1 -1
  697. package/build-types/navigation/group/index.d.ts +0 -1
  698. package/build-types/navigation/group/index.d.ts.map +1 -1
  699. package/build-types/navigation/index.d.ts +0 -1
  700. package/build-types/navigation/index.d.ts.map +1 -1
  701. package/build-types/navigation/item/base-content.d.ts +0 -1
  702. package/build-types/navigation/item/base-content.d.ts.map +1 -1
  703. package/build-types/navigation/item/base.d.ts +0 -1
  704. package/build-types/navigation/item/base.d.ts.map +1 -1
  705. package/build-types/navigation/item/index.d.ts +0 -1
  706. package/build-types/navigation/item/index.d.ts.map +1 -1
  707. package/build-types/navigation/menu/context.d.ts +0 -1
  708. package/build-types/navigation/menu/context.d.ts.map +1 -1
  709. package/build-types/navigation/menu/index.d.ts +0 -1
  710. package/build-types/navigation/menu/index.d.ts.map +1 -1
  711. package/build-types/navigation/menu/menu-title-search.d.ts +0 -1
  712. package/build-types/navigation/menu/menu-title-search.d.ts.map +1 -1
  713. package/build-types/navigation/menu/menu-title.d.ts +0 -1
  714. package/build-types/navigation/menu/menu-title.d.ts.map +1 -1
  715. package/build-types/navigation/menu/search-no-results-found.d.ts +0 -1
  716. package/build-types/navigation/menu/search-no-results-found.d.ts.map +1 -1
  717. package/build-types/navigation/styles/navigation-styles.d.ts +27 -28
  718. package/build-types/navigation/styles/navigation-styles.d.ts.map +1 -1
  719. package/build-types/navigation/types.d.ts +0 -1
  720. package/build-types/navigation/types.d.ts.map +1 -1
  721. package/build-types/navigation/use-navigation-tree-nodes.d.ts +0 -1
  722. package/build-types/navigation/use-navigation-tree-nodes.d.ts.map +1 -1
  723. package/build-types/navigator/context.d.ts +0 -1
  724. package/build-types/navigator/context.d.ts.map +1 -1
  725. package/build-types/navigator/navigator-back-button/component.d.ts +17 -18
  726. package/build-types/navigator/navigator-back-button/component.d.ts.map +1 -1
  727. package/build-types/navigator/navigator-back-button/hook.d.ts +29 -31
  728. package/build-types/navigator/navigator-back-button/hook.d.ts.map +1 -1
  729. package/build-types/navigator/navigator-button/component.d.ts +18 -19
  730. package/build-types/navigator/navigator-button/component.d.ts.map +1 -1
  731. package/build-types/navigator/navigator-button/hook.d.ts +29 -31
  732. package/build-types/navigator/navigator-button/hook.d.ts.map +1 -1
  733. package/build-types/navigator/navigator-provider/component.d.ts +0 -1
  734. package/build-types/navigator/navigator-provider/component.d.ts.map +1 -1
  735. package/build-types/navigator/navigator-screen/component.d.ts +0 -1
  736. package/build-types/navigator/navigator-screen/component.d.ts.map +1 -1
  737. package/build-types/navigator/navigator-to-parent-button/component.d.ts +17 -18
  738. package/build-types/navigator/navigator-to-parent-button/component.d.ts.map +1 -1
  739. package/build-types/navigator/stories/index.story.d.ts +4 -4
  740. package/build-types/navigator/stories/index.story.d.ts.map +1 -1
  741. package/build-types/notice/index.d.ts +0 -1
  742. package/build-types/notice/index.d.ts.map +1 -1
  743. package/build-types/notice/list.d.ts +0 -1
  744. package/build-types/notice/list.d.ts.map +1 -1
  745. package/build-types/number-control/index.d.ts +12 -13
  746. package/build-types/number-control/index.d.ts.map +1 -1
  747. package/build-types/number-control/stories/index.story.d.ts +12 -13
  748. package/build-types/number-control/stories/index.story.d.ts.map +1 -1
  749. package/build-types/number-control/styles/number-control-styles.d.ts +2 -3
  750. package/build-types/number-control/styles/number-control-styles.d.ts.map +1 -1
  751. package/build-types/palette-edit/index.d.ts +0 -1
  752. package/build-types/palette-edit/index.d.ts.map +1 -1
  753. package/build-types/palette-edit/styles.d.ts +18 -20
  754. package/build-types/palette-edit/styles.d.ts.map +1 -1
  755. package/build-types/panel/body.d.ts +0 -1
  756. package/build-types/panel/body.d.ts.map +1 -1
  757. package/build-types/panel/header.d.ts +0 -1
  758. package/build-types/panel/header.d.ts.map +1 -1
  759. package/build-types/panel/index.d.ts +0 -1
  760. package/build-types/panel/index.d.ts.map +1 -1
  761. package/build-types/panel/row.d.ts +0 -1
  762. package/build-types/panel/row.d.ts.map +1 -1
  763. package/build-types/panel/types.d.ts +0 -1
  764. package/build-types/panel/types.d.ts.map +1 -1
  765. package/build-types/placeholder/index.d.ts +0 -1
  766. package/build-types/placeholder/index.d.ts.map +1 -1
  767. package/build-types/popover/index.d.ts +0 -1
  768. package/build-types/popover/index.d.ts.map +1 -1
  769. package/build-types/popover/overlay-middlewares.d.ts +1 -11
  770. package/build-types/popover/overlay-middlewares.d.ts.map +1 -1
  771. package/build-types/popover/stories/e2e/index.story.d.ts +0 -1
  772. package/build-types/popover/stories/e2e/index.story.d.ts.map +1 -1
  773. package/build-types/popover/stories/index.story.d.ts +6 -6
  774. package/build-types/popover/stories/index.story.d.ts.map +1 -1
  775. package/build-types/popover/test/utils/index.d.ts +0 -1
  776. package/build-types/popover/test/utils/index.d.ts.map +1 -1
  777. package/build-types/popover/utils.d.ts +3 -3
  778. package/build-types/popover/utils.d.ts.map +1 -1
  779. package/build-types/private-apis.d.ts.map +1 -1
  780. package/build-types/progress-bar/index.d.ts +0 -1
  781. package/build-types/progress-bar/index.d.ts.map +1 -1
  782. package/build-types/progress-bar/stories/index.story.d.ts +0 -1
  783. package/build-types/progress-bar/stories/index.story.d.ts.map +1 -1
  784. package/build-types/progress-bar/styles.d.ts +6 -7
  785. package/build-types/progress-bar/styles.d.ts.map +1 -1
  786. package/build-types/query-controls/author-select.d.ts +0 -1
  787. package/build-types/query-controls/author-select.d.ts.map +1 -1
  788. package/build-types/query-controls/category-select.d.ts +0 -1
  789. package/build-types/query-controls/category-select.d.ts.map +1 -1
  790. package/build-types/query-controls/index.d.ts +0 -1
  791. package/build-types/query-controls/index.d.ts.map +1 -1
  792. package/build-types/radio-control/index.d.ts +0 -1
  793. package/build-types/radio-control/index.d.ts.map +1 -1
  794. package/build-types/radio-control/stories/index.story.d.ts +1 -0
  795. package/build-types/radio-control/stories/index.story.d.ts.map +1 -1
  796. package/build-types/radio-control/test/index.d.ts +2 -0
  797. package/build-types/radio-control/test/index.d.ts.map +1 -0
  798. package/build-types/radio-control/types.d.ts +4 -0
  799. package/build-types/radio-control/types.d.ts.map +1 -1
  800. package/build-types/radio-group/context.d.ts +2 -3
  801. package/build-types/radio-group/context.d.ts.map +1 -1
  802. package/build-types/radio-group/index.d.ts +0 -1
  803. package/build-types/radio-group/index.d.ts.map +1 -1
  804. package/build-types/radio-group/radio.d.ts +0 -1
  805. package/build-types/radio-group/radio.d.ts.map +1 -1
  806. package/build-types/radio-group/types.d.ts +0 -1
  807. package/build-types/radio-group/types.d.ts.map +1 -1
  808. package/build-types/range-control/index.d.ts +29 -29
  809. package/build-types/range-control/index.d.ts.map +1 -1
  810. package/build-types/range-control/input-range.d.ts +0 -1
  811. package/build-types/range-control/input-range.d.ts.map +1 -1
  812. package/build-types/range-control/mark.d.ts +0 -1
  813. package/build-types/range-control/mark.d.ts.map +1 -1
  814. package/build-types/range-control/rail.d.ts +0 -1
  815. package/build-types/range-control/rail.d.ts.map +1 -1
  816. package/build-types/range-control/styles/range-control-styles.d.ts +48 -49
  817. package/build-types/range-control/styles/range-control-styles.d.ts.map +1 -1
  818. package/build-types/range-control/tooltip.d.ts +0 -1
  819. package/build-types/range-control/tooltip.d.ts.map +1 -1
  820. package/build-types/resizable-box/index.d.ts +7 -20
  821. package/build-types/resizable-box/index.d.ts.map +1 -1
  822. package/build-types/resizable-box/resize-tooltip/label.d.ts +0 -1
  823. package/build-types/resizable-box/resize-tooltip/label.d.ts.map +1 -1
  824. package/build-types/resizable-box/resize-tooltip/styles/resize-tooltip.styles.d.ts +7 -8
  825. package/build-types/resizable-box/resize-tooltip/styles/resize-tooltip.styles.d.ts.map +1 -1
  826. package/build-types/resizable-box/resize-tooltip/utils.d.ts +0 -1
  827. package/build-types/resizable-box/resize-tooltip/utils.d.ts.map +1 -1
  828. package/build-types/resizable-box/stories/index.story.d.ts +32 -39
  829. package/build-types/resizable-box/stories/index.story.d.ts.map +1 -1
  830. package/build-types/responsive-wrapper/index.d.ts +0 -1
  831. package/build-types/responsive-wrapper/index.d.ts.map +1 -1
  832. package/build-types/responsive-wrapper/types.d.ts +0 -1
  833. package/build-types/responsive-wrapper/types.d.ts.map +1 -1
  834. package/build-types/sandbox/index.d.ts +0 -1
  835. package/build-types/sandbox/index.d.ts.map +1 -1
  836. package/build-types/sandbox/types.d.ts +0 -1
  837. package/build-types/sandbox/types.d.ts.map +1 -1
  838. package/build-types/scrollable/component.d.ts +0 -1
  839. package/build-types/scrollable/component.d.ts.map +1 -1
  840. package/build-types/scrollable/hook.d.ts +9 -11
  841. package/build-types/scrollable/hook.d.ts.map +1 -1
  842. package/build-types/search-control/index.d.ts +0 -1
  843. package/build-types/search-control/index.d.ts.map +1 -1
  844. package/build-types/search-control/stories/index.story.d.ts +0 -1
  845. package/build-types/search-control/stories/index.story.d.ts.map +1 -1
  846. package/build-types/search-control/styles.d.ts +3 -4
  847. package/build-types/search-control/styles.d.ts.map +1 -1
  848. package/build-types/search-control/types.d.ts +0 -1
  849. package/build-types/search-control/types.d.ts.map +1 -1
  850. package/build-types/select-control/chevron-down.d.ts +0 -1
  851. package/build-types/select-control/chevron-down.d.ts.map +1 -1
  852. package/build-types/select-control/index.d.ts +4 -2
  853. package/build-types/select-control/index.d.ts.map +1 -1
  854. package/build-types/select-control/stories/index.story.d.ts +9 -3
  855. package/build-types/select-control/stories/index.story.d.ts.map +1 -1
  856. package/build-types/select-control/styles/select-control-styles.d.ts +7 -8
  857. package/build-types/select-control/styles/select-control-styles.d.ts.map +1 -1
  858. package/build-types/select-control/types.d.ts +33 -27
  859. package/build-types/select-control/types.d.ts.map +1 -1
  860. package/build-types/shortcut/index.d.ts +0 -1
  861. package/build-types/shortcut/index.d.ts.map +1 -1
  862. package/build-types/slot-fill/bubbles-virtually/fill.d.ts +0 -1
  863. package/build-types/slot-fill/bubbles-virtually/fill.d.ts.map +1 -1
  864. package/build-types/slot-fill/bubbles-virtually/slot-fill-context.d.ts +0 -1
  865. package/build-types/slot-fill/bubbles-virtually/slot-fill-context.d.ts.map +1 -1
  866. package/build-types/slot-fill/bubbles-virtually/slot-fill-provider.d.ts +0 -1
  867. package/build-types/slot-fill/bubbles-virtually/slot-fill-provider.d.ts.map +1 -1
  868. package/build-types/slot-fill/bubbles-virtually/slot.d.ts +1 -2
  869. package/build-types/slot-fill/bubbles-virtually/slot.d.ts.map +1 -1
  870. package/build-types/slot-fill/bubbles-virtually/use-slot.d.ts.map +1 -1
  871. package/build-types/slot-fill/context.d.ts +0 -1
  872. package/build-types/slot-fill/context.d.ts.map +1 -1
  873. package/build-types/slot-fill/index.d.ts +4 -4
  874. package/build-types/slot-fill/index.d.ts.map +1 -1
  875. package/build-types/slot-fill/provider.d.ts +0 -1
  876. package/build-types/slot-fill/provider.d.ts.map +1 -1
  877. package/build-types/slot-fill/slot.d.ts +1 -2
  878. package/build-types/slot-fill/slot.d.ts.map +1 -1
  879. package/build-types/slot-fill/use-slot.d.ts +0 -1
  880. package/build-types/slot-fill/use-slot.d.ts.map +1 -1
  881. package/build-types/snackbar/index.d.ts +5 -6
  882. package/build-types/snackbar/index.d.ts.map +1 -1
  883. package/build-types/snackbar/list.d.ts +0 -1
  884. package/build-types/snackbar/list.d.ts.map +1 -1
  885. package/build-types/spacer/component.d.ts +0 -1
  886. package/build-types/spacer/component.d.ts.map +1 -1
  887. package/build-types/spacer/hook.d.ts +9 -11
  888. package/build-types/spacer/hook.d.ts.map +1 -1
  889. package/build-types/spinner/styles.d.ts +6 -7
  890. package/build-types/spinner/styles.d.ts.map +1 -1
  891. package/build-types/style-provider/index.d.ts +0 -1
  892. package/build-types/style-provider/index.d.ts.map +1 -1
  893. package/build-types/surface/component.d.ts +0 -1
  894. package/build-types/surface/component.d.ts.map +1 -1
  895. package/build-types/surface/hook.d.ts +10 -12
  896. package/build-types/surface/hook.d.ts.map +1 -1
  897. package/build-types/surface/types.d.ts +0 -1
  898. package/build-types/surface/types.d.ts.map +1 -1
  899. package/build-types/tab-panel/index.d.ts +0 -1
  900. package/build-types/tab-panel/index.d.ts.map +1 -1
  901. package/build-types/tab-panel/stories/index.story.d.ts +0 -1
  902. package/build-types/tab-panel/stories/index.story.d.ts.map +1 -1
  903. package/build-types/tabs/context.d.ts +0 -1
  904. package/build-types/tabs/context.d.ts.map +1 -1
  905. package/build-types/tabs/index.d.ts +0 -1
  906. package/build-types/tabs/index.d.ts.map +1 -1
  907. package/build-types/tabs/styles.d.ts +12 -19
  908. package/build-types/tabs/styles.d.ts.map +1 -1
  909. package/build-types/tabs/tab.d.ts +0 -1
  910. package/build-types/tabs/tab.d.ts.map +1 -1
  911. package/build-types/tabs/tablist.d.ts +0 -1
  912. package/build-types/tabs/tablist.d.ts.map +1 -1
  913. package/build-types/tabs/tabpanel.d.ts +0 -1
  914. package/build-types/tabs/tabpanel.d.ts.map +1 -1
  915. package/build-types/tabs/types.d.ts +0 -1
  916. package/build-types/tabs/types.d.ts.map +1 -1
  917. package/build-types/text/component.d.ts +0 -1
  918. package/build-types/text/component.d.ts.map +1 -1
  919. package/build-types/text/hook.d.ts +9 -9
  920. package/build-types/text/stories/index.story.d.ts +0 -1
  921. package/build-types/text/stories/index.story.d.ts.map +1 -1
  922. package/build-types/text/utils.d.ts +0 -1
  923. package/build-types/text/utils.d.ts.map +1 -1
  924. package/build-types/text-control/index.d.ts +3 -3
  925. package/build-types/text-control/index.d.ts.map +1 -1
  926. package/build-types/text-highlight/index.d.ts +0 -1
  927. package/build-types/text-highlight/index.d.ts.map +1 -1
  928. package/build-types/textarea-control/index.d.ts +2 -2
  929. package/build-types/textarea-control/index.d.ts.map +1 -1
  930. package/build-types/textarea-control/styles/textarea-control-styles.d.ts +2 -3
  931. package/build-types/textarea-control/styles/textarea-control-styles.d.ts.map +1 -1
  932. package/build-types/theme/color-algorithms.d.ts +1 -9
  933. package/build-types/theme/color-algorithms.d.ts.map +1 -1
  934. package/build-types/theme/index.d.ts +0 -1
  935. package/build-types/theme/index.d.ts.map +1 -1
  936. package/build-types/theme/stories/index.story.d.ts +0 -1
  937. package/build-types/theme/stories/index.story.d.ts.map +1 -1
  938. package/build-types/theme/styles.d.ts +2 -3
  939. package/build-types/theme/styles.d.ts.map +1 -1
  940. package/build-types/tip/index.d.ts +0 -1
  941. package/build-types/tip/index.d.ts.map +1 -1
  942. package/build-types/toggle-control/index.d.ts +3 -9
  943. package/build-types/toggle-control/index.d.ts.map +1 -1
  944. package/build-types/toggle-control/stories/index.story.d.ts +0 -1
  945. package/build-types/toggle-control/stories/index.story.d.ts.map +1 -1
  946. package/build-types/toggle-group-control/context.d.ts +0 -1
  947. package/build-types/toggle-group-control/context.d.ts.map +1 -1
  948. package/build-types/toggle-group-control/toggle-group-control/as-button-group.d.ts +0 -1
  949. package/build-types/toggle-group-control/toggle-group-control/as-button-group.d.ts.map +1 -1
  950. package/build-types/toggle-group-control/toggle-group-control/as-radio-group.d.ts +0 -1
  951. package/build-types/toggle-group-control/toggle-group-control/as-radio-group.d.ts.map +1 -1
  952. package/build-types/toggle-group-control/toggle-group-control/component.d.ts +14 -10
  953. package/build-types/toggle-group-control/toggle-group-control/component.d.ts.map +1 -1
  954. package/build-types/toggle-group-control/toggle-group-control/styles.d.ts +5 -6
  955. package/build-types/toggle-group-control/toggle-group-control/styles.d.ts.map +1 -1
  956. package/build-types/toggle-group-control/toggle-group-control-option/component.d.ts +6 -2
  957. package/build-types/toggle-group-control/toggle-group-control-option/component.d.ts.map +1 -1
  958. package/build-types/toggle-group-control/toggle-group-control-option-base/component.d.ts +1 -2
  959. package/build-types/toggle-group-control/toggle-group-control-option-base/component.d.ts.map +1 -1
  960. package/build-types/toggle-group-control/toggle-group-control-option-base/styles.d.ts +5 -6
  961. package/build-types/toggle-group-control/toggle-group-control-option-base/styles.d.ts.map +1 -1
  962. package/build-types/toggle-group-control/toggle-group-control-option-icon/component.d.ts +14 -15
  963. package/build-types/toggle-group-control/toggle-group-control-option-icon/component.d.ts.map +1 -1
  964. package/build-types/toolbar/stories/index.story.d.ts +0 -1
  965. package/build-types/toolbar/stories/index.story.d.ts.map +1 -1
  966. package/build-types/toolbar/toolbar/index.d.ts +0 -1
  967. package/build-types/toolbar/toolbar/index.d.ts.map +1 -1
  968. package/build-types/toolbar/toolbar/toolbar-container.d.ts +0 -1
  969. package/build-types/toolbar/toolbar/toolbar-container.d.ts.map +1 -1
  970. package/build-types/toolbar/toolbar-button/index.d.ts +0 -1
  971. package/build-types/toolbar/toolbar-button/index.d.ts.map +1 -1
  972. package/build-types/toolbar/toolbar-button/toolbar-button-container.d.ts +0 -1
  973. package/build-types/toolbar/toolbar-button/toolbar-button-container.d.ts.map +1 -1
  974. package/build-types/toolbar/toolbar-context/index.d.ts +0 -1
  975. package/build-types/toolbar/toolbar-context/index.d.ts.map +1 -1
  976. package/build-types/toolbar/toolbar-dropdown-menu/index.d.ts +0 -1
  977. package/build-types/toolbar/toolbar-dropdown-menu/index.d.ts.map +1 -1
  978. package/build-types/toolbar/toolbar-group/index.d.ts +0 -1
  979. package/build-types/toolbar/toolbar-group/index.d.ts.map +1 -1
  980. package/build-types/toolbar/toolbar-group/toolbar-group-collapsed.d.ts +0 -1
  981. package/build-types/toolbar/toolbar-group/toolbar-group-collapsed.d.ts.map +1 -1
  982. package/build-types/toolbar/toolbar-group/toolbar-group-container.d.ts +1 -2
  983. package/build-types/toolbar/toolbar-group/toolbar-group-container.d.ts.map +1 -1
  984. package/build-types/toolbar/toolbar-item/index.d.ts +2 -3
  985. package/build-types/toolbar/toolbar-item/index.d.ts.map +1 -1
  986. package/build-types/tools-panel/context.d.ts +0 -1
  987. package/build-types/tools-panel/context.d.ts.map +1 -1
  988. package/build-types/tools-panel/styles.d.ts +2 -3
  989. package/build-types/tools-panel/styles.d.ts.map +1 -1
  990. package/build-types/tools-panel/tools-panel/component.d.ts +0 -1
  991. package/build-types/tools-panel/tools-panel/component.d.ts.map +1 -1
  992. package/build-types/tools-panel/tools-panel/hook.d.ts +10 -12
  993. package/build-types/tools-panel/tools-panel/hook.d.ts.map +1 -1
  994. package/build-types/tools-panel/tools-panel-header/component.d.ts +0 -1
  995. package/build-types/tools-panel/tools-panel-header/component.d.ts.map +1 -1
  996. package/build-types/tools-panel/tools-panel-header/hook.d.ts +11 -13
  997. package/build-types/tools-panel/tools-panel-header/hook.d.ts.map +1 -1
  998. package/build-types/tools-panel/tools-panel-item/component.d.ts +3 -4
  999. package/build-types/tools-panel/tools-panel-item/component.d.ts.map +1 -1
  1000. package/build-types/tools-panel/tools-panel-item/hook.d.ts +9 -11
  1001. package/build-types/tools-panel/tools-panel-item/hook.d.ts.map +1 -1
  1002. package/build-types/tooltip/index.d.ts +0 -1
  1003. package/build-types/tooltip/index.d.ts.map +1 -1
  1004. package/build-types/tooltip/stories/index.story.d.ts +0 -1
  1005. package/build-types/tooltip/stories/index.story.d.ts.map +1 -1
  1006. package/build-types/tooltip/test/utils/index.d.ts +1 -5
  1007. package/build-types/tooltip/test/utils/index.d.ts.map +1 -1
  1008. package/build-types/tooltip/types.d.ts +0 -1
  1009. package/build-types/tooltip/types.d.ts.map +1 -1
  1010. package/build-types/tree-grid/cell.d.ts +0 -1
  1011. package/build-types/tree-grid/cell.d.ts.map +1 -1
  1012. package/build-types/tree-grid/index.d.ts +0 -1
  1013. package/build-types/tree-grid/index.d.ts.map +1 -1
  1014. package/build-types/tree-grid/item.d.ts +0 -1
  1015. package/build-types/tree-grid/item.d.ts.map +1 -1
  1016. package/build-types/tree-grid/roving-tab-index-context.d.ts +0 -1
  1017. package/build-types/tree-grid/roving-tab-index-context.d.ts.map +1 -1
  1018. package/build-types/tree-grid/roving-tab-index-item.d.ts +0 -1
  1019. package/build-types/tree-grid/roving-tab-index-item.d.ts.map +1 -1
  1020. package/build-types/tree-grid/roving-tab-index.d.ts +0 -1
  1021. package/build-types/tree-grid/roving-tab-index.d.ts.map +1 -1
  1022. package/build-types/tree-grid/row.d.ts +0 -1
  1023. package/build-types/tree-grid/row.d.ts.map +1 -1
  1024. package/build-types/tree-grid/stories/index.story.d.ts +0 -1
  1025. package/build-types/tree-grid/stories/index.story.d.ts.map +1 -1
  1026. package/build-types/tree-grid/types.d.ts +0 -1
  1027. package/build-types/tree-grid/types.d.ts.map +1 -1
  1028. package/build-types/tree-select/index.d.ts +1 -1
  1029. package/build-types/tree-select/index.d.ts.map +1 -1
  1030. package/build-types/truncate/component.d.ts +0 -1
  1031. package/build-types/truncate/component.d.ts.map +1 -1
  1032. package/build-types/truncate/hook.d.ts +9 -11
  1033. package/build-types/truncate/hook.d.ts.map +1 -1
  1034. package/build-types/truncate/utils.d.ts.map +1 -1
  1035. package/build-types/unit-control/index.d.ts +7 -8
  1036. package/build-types/unit-control/index.d.ts.map +1 -1
  1037. package/build-types/unit-control/styles/unit-control-styles.d.ts +17 -18
  1038. package/build-types/unit-control/styles/unit-control-styles.d.ts.map +1 -1
  1039. package/build-types/unit-control/unit-select-control.d.ts +0 -1
  1040. package/build-types/unit-control/unit-select-control.d.ts.map +1 -1
  1041. package/build-types/unit-control/utils.d.ts.map +1 -1
  1042. package/build-types/utils/breakpoint.d.ts +1 -10
  1043. package/build-types/utils/breakpoint.d.ts.map +1 -1
  1044. package/build-types/utils/config-values.d.ts +6 -0
  1045. package/build-types/utils/element-rect.d.ts +111 -0
  1046. package/build-types/utils/element-rect.d.ts.map +1 -0
  1047. package/build-types/utils/font.d.ts +1 -6
  1048. package/build-types/utils/font.d.ts.map +1 -1
  1049. package/build-types/utils/hooks/use-controlled-state.d.ts +1 -1
  1050. package/build-types/utils/hooks/use-controlled-state.d.ts.map +1 -1
  1051. package/build-types/utils/hooks/use-controlled-value.d.ts +0 -1
  1052. package/build-types/utils/hooks/use-controlled-value.d.ts.map +1 -1
  1053. package/build-types/utils/hooks/use-event.d.ts +20 -0
  1054. package/build-types/utils/hooks/use-event.d.ts.map +1 -0
  1055. package/build-types/utils/hooks/use-on-value-update.d.ts +19 -0
  1056. package/build-types/utils/hooks/use-on-value-update.d.ts.map +1 -0
  1057. package/build-types/utils/hooks/use-update-effect.d.ts +1 -1
  1058. package/build-types/utils/math.d.ts.map +1 -1
  1059. package/build-types/utils/rtl.d.ts +2 -2
  1060. package/build-types/utils/values.d.ts +2 -2
  1061. package/build-types/utils/values.d.ts.map +1 -1
  1062. package/build-types/utils/with-ignore-ime-events.d.ts +0 -1
  1063. package/build-types/utils/with-ignore-ime-events.d.ts.map +1 -1
  1064. package/build-types/v-stack/component.d.ts +2 -3
  1065. package/build-types/v-stack/component.d.ts.map +1 -1
  1066. package/build-types/v-stack/hook.d.ts +9 -11
  1067. package/build-types/v-stack/hook.d.ts.map +1 -1
  1068. package/build-types/v-stack/stories/index.story.d.ts +2 -3
  1069. package/build-types/v-stack/stories/index.story.d.ts.map +1 -1
  1070. package/build-types/view/component.d.ts +0 -2
  1071. package/build-types/view/component.d.ts.map +1 -1
  1072. package/build-types/visually-hidden/component.d.ts +0 -1
  1073. package/build-types/visually-hidden/component.d.ts.map +1 -1
  1074. package/build-types/z-stack/component.d.ts +0 -1
  1075. package/build-types/z-stack/component.d.ts.map +1 -1
  1076. package/build-types/z-stack/styles.d.ts +4 -5
  1077. package/build-types/z-stack/styles.d.ts.map +1 -1
  1078. package/package.json +20 -21
  1079. package/src/alignment-matrix-control/test/index.tsx +1 -3
  1080. package/src/autocomplete/README.md +2 -2
  1081. package/src/autocomplete/autocompleter-ui.tsx +2 -0
  1082. package/src/autocomplete/style.scss +0 -6
  1083. package/src/autocomplete/types.ts +2 -3
  1084. package/src/base-control/README.md +1 -1
  1085. package/src/base-control/styles/base-control-styles.ts +1 -1
  1086. package/src/base-control/types.ts +1 -1
  1087. package/src/border-control/styles.ts +0 -5
  1088. package/src/button/README.md +1 -1
  1089. package/src/button/index.tsx +9 -7
  1090. package/src/button/stories/e2e/index.story.tsx +103 -21
  1091. package/src/button/style.scss +49 -21
  1092. package/src/button/test/index.tsx +35 -44
  1093. package/src/button/types.ts +9 -2
  1094. package/src/card/card/README.md +1 -1
  1095. package/src/card/stories/index.story.tsx +43 -42
  1096. package/src/checkbox-control/README.md +8 -0
  1097. package/src/checkbox-control/index.tsx +1 -0
  1098. package/src/checkbox-control/style.scss +3 -1
  1099. package/src/circular-option-picker/test/index.tsx +1 -4
  1100. package/src/color-palette/index.tsx +22 -20
  1101. package/src/color-picker/component.tsx +12 -22
  1102. package/src/color-picker/stories/index.story.tsx +2 -22
  1103. package/src/combobox-control/README.md +9 -0
  1104. package/src/combobox-control/index.tsx +11 -0
  1105. package/src/combobox-control/test/index.tsx +127 -1
  1106. package/src/composite/legacy/test/index.tsx +2 -18
  1107. package/src/custom-select-control/README.md +34 -32
  1108. package/src/custom-select-control/index.tsx +206 -0
  1109. package/src/custom-select-control/stories/index.story.tsx +26 -18
  1110. package/src/{custom-select-control-v2/legacy-component → custom-select-control}/test/index.tsx +90 -77
  1111. package/src/custom-select-control/types.ts +123 -0
  1112. package/src/custom-select-control-v2/custom-select.tsx +2 -0
  1113. package/src/custom-select-control-v2/index.tsx +26 -1
  1114. package/src/custom-select-control-v2/stories/{default.story.tsx → index.story.tsx} +1 -1
  1115. package/src/custom-select-control-v2/styles.ts +29 -3
  1116. package/src/custom-select-control-v2/test/index.tsx +15 -19
  1117. package/src/custom-select-control-v2/types.ts +0 -109
  1118. package/src/date-time/index.ts +1 -2
  1119. package/src/date-time/stories/time.story.tsx +17 -0
  1120. package/src/date-time/time/index.tsx +46 -16
  1121. package/src/date-time/time/styles.ts +1 -0
  1122. package/src/date-time/{time-input → time/time-input}/index.tsx +9 -9
  1123. package/src/dimension-control/test/__snapshots__/index.test.js.snap +4 -0
  1124. package/src/disabled/README.md +1 -1
  1125. package/src/dropdown/stories/index.story.tsx +55 -50
  1126. package/src/dropdown-menu/stories/index.story.tsx +52 -55
  1127. package/src/dropdown-menu-v2/stories/index.story.tsx +0 -12
  1128. package/src/dropdown-menu-v2/styles.ts +18 -17
  1129. package/src/dropdown-menu-v2/test/index.tsx +1 -4
  1130. package/src/focal-point-picker/README.md +9 -0
  1131. package/src/focal-point-picker/index.tsx +1 -0
  1132. package/src/font-size-picker/README.md +1 -1
  1133. package/src/font-size-picker/font-size-picker-select.tsx +3 -3
  1134. package/src/font-size-picker/index.tsx +68 -64
  1135. package/src/font-size-picker/test/index.tsx +128 -53
  1136. package/src/font-size-picker/types.ts +6 -5
  1137. package/src/form-toggle/index.tsx +23 -21
  1138. package/src/form-toggle/style.scss +14 -9
  1139. package/src/form-token-field/README.md +2 -1
  1140. package/src/form-token-field/index.tsx +9 -0
  1141. package/src/form-token-field/stories/index.story.tsx +2 -0
  1142. package/src/guide/index.tsx +2 -0
  1143. package/src/heading/types.ts +1 -4
  1144. package/src/higher-order/navigate-regions/style.scss +3 -15
  1145. package/src/index.ts +1 -1
  1146. package/src/mobile/bottom-sheet/bottom-sheet-navigation/navigation-screen.native.js +1 -1
  1147. package/src/modal/index.tsx +21 -20
  1148. package/src/navigator/stories/index.story.tsx +240 -242
  1149. package/src/notice/test/__snapshots__/index.tsx.snap +1 -1
  1150. package/src/placeholder/style.scss +11 -2
  1151. package/src/popover/stories/index.story.tsx +155 -153
  1152. package/src/private-apis.ts +0 -4
  1153. package/src/query-controls/index.tsx +5 -1
  1154. package/src/radio-control/index.tsx +48 -7
  1155. package/src/radio-control/stories/index.story.tsx +23 -0
  1156. package/src/radio-control/style.scss +32 -3
  1157. package/src/radio-control/test/index.tsx +274 -0
  1158. package/src/radio-control/types.ts +4 -0
  1159. package/src/range-control/README.md +8 -0
  1160. package/src/range-control/index.tsx +1 -0
  1161. package/src/resizable-box/resize-tooltip/README.md +1 -1
  1162. package/src/select-control/README.md +16 -1
  1163. package/src/select-control/index.tsx +40 -22
  1164. package/src/select-control/stories/index.story.tsx +6 -0
  1165. package/src/select-control/styles/select-control-styles.ts +24 -1
  1166. package/src/select-control/test/select-control.tsx +148 -4
  1167. package/src/select-control/types.ts +76 -65
  1168. package/src/style.scss +1 -1
  1169. package/src/tab-panel/test/index.tsx +1 -8
  1170. package/src/tabs/styles.ts +10 -2
  1171. package/src/tabs/tablist.tsx +3 -243
  1172. package/src/tabs/test/index.tsx +68 -84
  1173. package/src/text-control/README.md +1 -0
  1174. package/src/text-control/index.tsx +1 -0
  1175. package/src/text-control/style.scss +5 -0
  1176. package/src/textarea-control/README.md +8 -0
  1177. package/src/textarea-control/index.tsx +1 -0
  1178. package/src/toggle-control/README.md +9 -0
  1179. package/src/toggle-control/index.tsx +37 -25
  1180. package/src/toggle-control/style.scss +12 -0
  1181. package/src/toggle-group-control/test/__snapshots__/index.tsx.snap +42 -12
  1182. package/src/toggle-group-control/test/index.tsx +112 -4
  1183. package/src/toggle-group-control/toggle-group-control/README.md +13 -1
  1184. package/src/toggle-group-control/toggle-group-control/component.tsx +6 -1
  1185. package/src/toggle-group-control/toggle-group-control-option/README.md +6 -1
  1186. package/src/toggle-group-control/toggle-group-control-option/component.tsx +6 -1
  1187. package/src/toggle-group-control/toggle-group-control-option-base/component.tsx +6 -1
  1188. package/src/toggle-group-control/toggle-group-control-option-base/styles.ts +5 -0
  1189. package/src/toggle-group-control/toggle-group-control-option-icon/README.md +1 -1
  1190. package/src/toggle-group-control/toggle-group-control-option-icon/component.tsx +14 -14
  1191. package/src/tools-panel/tools-panel-header/component.tsx +1 -1
  1192. package/src/tooltip/index.tsx +15 -2
  1193. package/src/tooltip/test/index.tsx +0 -5
  1194. package/src/tooltip/test/utils/index.tsx +5 -5
  1195. package/src/tree-select/README.md +9 -0
  1196. package/src/tree-select/index.tsx +1 -1
  1197. package/src/utils/config-values.js +6 -0
  1198. package/src/utils/element-rect.ts +197 -0
  1199. package/src/utils/hooks/use-event.ts +38 -0
  1200. package/src/utils/hooks/use-on-value-update.ts +42 -0
  1201. package/tsconfig.tsbuildinfo +1 -1
  1202. package/build/custom-select-control-v2/default-component/index.js +0 -42
  1203. package/build/custom-select-control-v2/default-component/index.js.map +0 -1
  1204. package/build/custom-select-control-v2/legacy-component/index.js +0 -131
  1205. package/build/custom-select-control-v2/legacy-component/index.js.map +0 -1
  1206. package/build/date-time/time-input/index.js.map +0 -1
  1207. package/build-module/custom-select-control-v2/default-component/index.js +0 -31
  1208. package/build-module/custom-select-control-v2/default-component/index.js.map +0 -1
  1209. package/build-module/custom-select-control-v2/legacy-component/index.js +0 -122
  1210. package/build-module/custom-select-control-v2/legacy-component/index.js.map +0 -1
  1211. package/build-module/date-time/time-input/index.js.map +0 -1
  1212. package/build-types/custom-select-control-v2/default-component/index.d.ts +0 -9
  1213. package/build-types/custom-select-control-v2/default-component/index.d.ts.map +0 -1
  1214. package/build-types/custom-select-control-v2/legacy-component/index.d.ts +0 -5
  1215. package/build-types/custom-select-control-v2/legacy-component/index.d.ts.map +0 -1
  1216. package/build-types/custom-select-control-v2/legacy-component/test/index.d.ts.map +0 -1
  1217. package/build-types/custom-select-control-v2/stories/default.story.d.ts.map +0 -1
  1218. package/build-types/custom-select-control-v2/stories/legacy.story.d.ts +0 -14
  1219. package/build-types/custom-select-control-v2/stories/legacy.story.d.ts.map +0 -1
  1220. package/build-types/date-time/stories/time-input.story.d.ts +0 -12
  1221. package/build-types/date-time/stories/time-input.story.d.ts.map +0 -1
  1222. package/build-types/date-time/time-input/index.d.ts.map +0 -1
  1223. package/build-types/date-time/time-input/test/index.d.ts.map +0 -1
  1224. package/src/custom-select-control/index.js +0 -240
  1225. package/src/custom-select-control/style.scss +0 -75
  1226. package/src/custom-select-control/test/index.js +0 -665
  1227. package/src/custom-select-control-v2/default-component/index.tsx +0 -29
  1228. package/src/custom-select-control-v2/legacy-component/index.tsx +0 -153
  1229. package/src/custom-select-control-v2/stories/legacy.story.tsx +0 -72
  1230. package/src/date-time/stories/time-input.story.tsx +0 -36
  1231. /package/build-types/{custom-select-control-v2/legacy-component → custom-select-control}/test/index.d.ts +0 -0
  1232. /package/build-types/date-time/{time-input → time/time-input}/test/index.d.ts +0 -0
  1233. /package/src/date-time/{time-input → time/time-input}/test/index.tsx +0 -0
@@ -7,7 +7,7 @@ import * as Ariakit from '@ariakit/react';
7
7
  * WordPress dependencies
8
8
  */
9
9
  import warning from '@wordpress/warning';
10
- import { forwardRef, useCallback, useEffect, useInsertionEffect, useRef, useState } from '@wordpress/element';
10
+ import { forwardRef, useState } from '@wordpress/element';
11
11
 
12
12
  /**
13
13
  * Internal dependencies
@@ -16,194 +16,9 @@ import { forwardRef, useCallback, useEffect, useInsertionEffect, useRef, useStat
16
16
  import { useTabsContext } from './context';
17
17
  import { TabListWrapper } from './styles';
18
18
  import clsx from 'clsx';
19
-
20
- // TODO: move these into a separate utility file, for use in other components
21
- // such as ToggleGroupControl.
22
-
23
- /**
24
- * Any function.
25
- */
19
+ import { useTrackElementOffsetRect } from '../utils/element-rect';
20
+ import { useOnValueUpdate } from '../utils/hooks/use-on-value-update';
26
21
  import { jsx as _jsx } from "react/jsx-runtime";
27
- /**
28
- * Creates a stable callback function that has access to the latest state and
29
- * can be used within event handlers and effect callbacks. Throws when used in
30
- * the render phase.
31
- *
32
- * @example
33
- *
34
- * ```tsx
35
- * function Component(props) {
36
- * const onClick = useEvent(props.onClick);
37
- * React.useEffect(() => {}, [onClick]);
38
- * }
39
- * ```
40
- */
41
- function useEvent(callback) {
42
- const ref = useRef(() => {
43
- throw new Error('Cannot call an event handler while rendering.');
44
- });
45
- useInsertionEffect(() => {
46
- ref.current = callback;
47
- });
48
- return useCallback((...args) => ref.current?.(...args), []);
49
- }
50
-
51
- /**
52
- * `useResizeObserver` options.
53
- */
54
-
55
- /**
56
- * Fires `onResize` when the target element is resized.
57
- *
58
- * **The element must not be stored in a ref**, else it won't be observed
59
- * or updated. Instead, it should be stored in a React state or equivalent.
60
- *
61
- * It sets up a `ResizeObserver` that tracks the element under the hood. The
62
- * target element can be changed dynamically, and the observer will be
63
- * updated accordingly.
64
- *
65
- * By default, `onResize` is called when the observer is set up, in addition
66
- * to when the element is resized. This behavior can be disabled with the
67
- * `fireOnObserve` option.
68
- *
69
- * @example
70
- *
71
- * ```tsx
72
- * const [ targetElement, setTargetElement ] = useState< HTMLElement | null >();
73
- *
74
- * useResizeObserver( targetElement, ( element ) => {
75
- * console.log( 'Element resized:', element );
76
- * } );
77
- *
78
- * <div ref={ setTargetElement } />;
79
- * ```
80
- */
81
- function useResizeObserver(
82
- /**
83
- * The target element to observe. It can be changed dynamically.
84
- */
85
- targetElement,
86
- /**
87
- * Callback to fire when the element is resized. It will also be
88
- * called when the observer is set up, unless `fireOnObserve` is
89
- * set to `false`.
90
- */
91
- onResize, {
92
- fireOnObserve = true
93
- } = {}) {
94
- const onResizeEvent = useEvent(onResize);
95
- const observedElementRef = useRef();
96
- const resizeObserverRef = useRef();
97
- useEffect(() => {
98
- if (targetElement === observedElementRef.current) {
99
- return;
100
- }
101
- observedElementRef.current = targetElement;
102
-
103
- // Set up a ResizeObserver.
104
- if (!resizeObserverRef.current) {
105
- resizeObserverRef.current = new ResizeObserver(() => {
106
- if (observedElementRef.current) {
107
- onResizeEvent(observedElementRef.current);
108
- }
109
- });
110
- }
111
- const {
112
- current: resizeObserver
113
- } = resizeObserverRef;
114
-
115
- // Observe new element.
116
- if (targetElement) {
117
- if (fireOnObserve) {
118
- onResizeEvent(targetElement);
119
- }
120
- resizeObserver.observe(targetElement);
121
- }
122
- return () => {
123
- // Unobserve previous element.
124
- if (observedElementRef.current) {
125
- resizeObserver.unobserve(observedElementRef.current);
126
- }
127
- };
128
- }, [fireOnObserve, onResizeEvent, targetElement]);
129
- }
130
-
131
- /**
132
- * The position and dimensions of an element, relative to its offset parent.
133
- */
134
-
135
- /**
136
- * An `ElementOffsetRect` object with all values set to zero.
137
- */
138
- const NULL_ELEMENT_OFFSET_RECT = {
139
- left: 0,
140
- top: 0,
141
- width: 0,
142
- height: 0
143
- };
144
-
145
- /**
146
- * Returns the position and dimensions of an element, relative to its offset
147
- * parent. This is useful in contexts where `getBoundingClientRect` is not
148
- * suitable, such as when the element is transformed.
149
- *
150
- * **Note:** the `left` and `right` values are adjusted due to a limitation
151
- * in the way the browser calculates the offset position of the element,
152
- * which can cause unwanted scrollbars to appear. This adjustment makes the
153
- * values potentially inaccurate within a range of 1 pixel.
154
- */
155
- function getElementOffsetRect(element) {
156
- return {
157
- // The adjustments mentioned in the documentation above are necessary
158
- // because `offsetLeft` and `offsetTop` are rounded to the nearest pixel,
159
- // which can result in a position mismatch that causes unwanted overflow.
160
- // For context, see: https://github.com/WordPress/gutenberg/pull/61979
161
- left: Math.max(element.offsetLeft - 1, 0),
162
- top: Math.max(element.offsetTop - 1, 0),
163
- // This is a workaround to obtain these values with a sub-pixel precision,
164
- // since `offsetWidth` and `offsetHeight` are rounded to the nearest pixel.
165
- width: parseFloat(getComputedStyle(element).width),
166
- height: parseFloat(getComputedStyle(element).height)
167
- };
168
- }
169
-
170
- /**
171
- * Tracks the position and dimensions of an element, relative to its offset
172
- * parent. The element can be changed dynamically.
173
- */
174
- function useTrackElementOffsetRect(targetElement) {
175
- const [indicatorPosition, setIndicatorPosition] = useState(NULL_ELEMENT_OFFSET_RECT);
176
- useResizeObserver(targetElement, element => setIndicatorPosition(getElementOffsetRect(element)));
177
- return indicatorPosition;
178
- }
179
-
180
- /**
181
- * Context object for the `onUpdate` callback of `useOnValueUpdate`.
182
- */
183
-
184
- /**
185
- * Calls the `onUpdate` callback when the `value` changes.
186
- */
187
- function useOnValueUpdate(
188
- /**
189
- * The value to watch for changes.
190
- */
191
- value,
192
- /**
193
- * Callback to fire when the value changes.
194
- */
195
- onUpdate) {
196
- const previousValueRef = useRef(value);
197
- const updateCallbackEvent = useEvent(onUpdate);
198
- useEffect(() => {
199
- if (previousValueRef.current !== value) {
200
- updateCallbackEvent({
201
- previousValue: previousValueRef.current
202
- });
203
- previousValueRef.current = value;
204
- }
205
- }, [updateCallbackEvent, value]);
206
- }
207
22
  export const TabList = forwardRef(function TabList({
208
23
  children,
209
24
  ...otherProps
@@ -1 +1 @@
1
- {"version":3,"names":["Ariakit","warning","forwardRef","useCallback","useEffect","useInsertionEffect","useRef","useState","useTabsContext","TabListWrapper","clsx","jsx","_jsx","useEvent","callback","ref","Error","current","args","useResizeObserver","targetElement","onResize","fireOnObserve","onResizeEvent","observedElementRef","resizeObserverRef","ResizeObserver","resizeObserver","observe","unobserve","NULL_ELEMENT_OFFSET_RECT","left","top","width","height","getElementOffsetRect","element","Math","max","offsetLeft","offsetTop","parseFloat","getComputedStyle","useTrackElementOffsetRect","indicatorPosition","setIndicatorPosition","useOnValueUpdate","value","onUpdate","previousValueRef","updateCallbackEvent","previousValue","TabList","children","otherProps","context","selectedId","store","item","animationEnabled","setAnimationEnabled","globalThis","SCRIPT_DEBUG","activeId","selectOnMove","setActiveId","onBlur","render","onTransitionEnd","event","pseudoElement","style","className"],"sources":["@wordpress/components/src/tabs/tablist.tsx"],"sourcesContent":["/**\n * External dependencies\n */\nimport * as Ariakit from '@ariakit/react';\n\n/**\n * WordPress dependencies\n */\nimport warning from '@wordpress/warning';\nimport {\n\tforwardRef,\n\tuseCallback,\n\tuseEffect,\n\tuseInsertionEffect,\n\tuseRef,\n\tuseState,\n} from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport type { TabListProps } from './types';\nimport { useTabsContext } from './context';\nimport { TabListWrapper } from './styles';\nimport type { WordPressComponentProps } from '../context';\nimport clsx from 'clsx';\n\n// TODO: move these into a separate utility file, for use in other components\n// such as ToggleGroupControl.\n\n/**\n * Any function.\n */\ntype AnyFunction = ( ...args: any ) => any;\n\n/**\n * Creates a stable callback function that has access to the latest state and\n * can be used within event handlers and effect callbacks. Throws when used in\n * the render phase.\n *\n * @example\n *\n * ```tsx\n * function Component(props) {\n * const onClick = useEvent(props.onClick);\n * React.useEffect(() => {}, [onClick]);\n * }\n * ```\n */\nfunction useEvent< T extends AnyFunction >( callback?: T ) {\n\tconst ref = useRef< AnyFunction | undefined >( () => {\n\t\tthrow new Error( 'Cannot call an event handler while rendering.' );\n\t} );\n\tuseInsertionEffect( () => {\n\t\tref.current = callback;\n\t} );\n\treturn useCallback< AnyFunction >(\n\t\t( ...args ) => ref.current?.( ...args ),\n\t\t[]\n\t) as T;\n}\n\n/**\n * `useResizeObserver` options.\n */\ntype UseResizeObserverOptions = {\n\t/**\n\t * Whether to trigger the callback when an element's ResizeObserver is\n\t * first set up.\n\t *\n\t * @default true\n\t */\n\tfireOnObserve?: boolean;\n};\n\n/**\n * Fires `onResize` when the target element is resized.\n *\n * **The element must not be stored in a ref**, else it won't be observed\n * or updated. Instead, it should be stored in a React state or equivalent.\n *\n * It sets up a `ResizeObserver` that tracks the element under the hood. The\n * target element can be changed dynamically, and the observer will be\n * updated accordingly.\n *\n * By default, `onResize` is called when the observer is set up, in addition\n * to when the element is resized. This behavior can be disabled with the\n * `fireOnObserve` option.\n *\n * @example\n *\n * ```tsx\n * const [ targetElement, setTargetElement ] = useState< HTMLElement | null >();\n *\n * useResizeObserver( targetElement, ( element ) => {\n * console.log( 'Element resized:', element );\n * } );\n *\n * <div ref={ setTargetElement } />;\n * ```\n */\nfunction useResizeObserver(\n\t/**\n\t * The target element to observe. It can be changed dynamically.\n\t */\n\ttargetElement: HTMLElement | undefined | null,\n\n\t/**\n\t * Callback to fire when the element is resized. It will also be\n\t * called when the observer is set up, unless `fireOnObserve` is\n\t * set to `false`.\n\t */\n\tonResize: ( element: HTMLElement ) => void,\n\t{ fireOnObserve = true }: UseResizeObserverOptions = {}\n) {\n\tconst onResizeEvent = useEvent( onResize );\n\n\tconst observedElementRef = useRef< HTMLElement | null >();\n\tconst resizeObserverRef = useRef< ResizeObserver >();\n\n\tuseEffect( () => {\n\t\tif ( targetElement === observedElementRef.current ) {\n\t\t\treturn;\n\t\t}\n\n\t\tobservedElementRef.current = targetElement;\n\n\t\t// Set up a ResizeObserver.\n\t\tif ( ! resizeObserverRef.current ) {\n\t\t\tresizeObserverRef.current = new ResizeObserver( () => {\n\t\t\t\tif ( observedElementRef.current ) {\n\t\t\t\t\tonResizeEvent( observedElementRef.current );\n\t\t\t\t}\n\t\t\t} );\n\t\t}\n\t\tconst { current: resizeObserver } = resizeObserverRef;\n\n\t\t// Observe new element.\n\t\tif ( targetElement ) {\n\t\t\tif ( fireOnObserve ) {\n\t\t\t\tonResizeEvent( targetElement );\n\t\t\t}\n\t\t\tresizeObserver.observe( targetElement );\n\t\t}\n\n\t\treturn () => {\n\t\t\t// Unobserve previous element.\n\t\t\tif ( observedElementRef.current ) {\n\t\t\t\tresizeObserver.unobserve( observedElementRef.current );\n\t\t\t}\n\t\t};\n\t}, [ fireOnObserve, onResizeEvent, targetElement ] );\n}\n\n/**\n * The position and dimensions of an element, relative to its offset parent.\n */\ntype ElementOffsetRect = {\n\t/**\n\t * The distance from the left edge of the offset parent to the left edge of\n\t * the element.\n\t */\n\tleft: number;\n\t/**\n\t * The distance from the top edge of the offset parent to the top edge of\n\t * the element.\n\t */\n\ttop: number;\n\t/**\n\t * The width of the element.\n\t */\n\twidth: number;\n\t/**\n\t * The height of the element.\n\t */\n\theight: number;\n};\n\n/**\n * An `ElementOffsetRect` object with all values set to zero.\n */\nconst NULL_ELEMENT_OFFSET_RECT = {\n\tleft: 0,\n\ttop: 0,\n\twidth: 0,\n\theight: 0,\n} satisfies ElementOffsetRect;\n\n/**\n * Returns the position and dimensions of an element, relative to its offset\n * parent. This is useful in contexts where `getBoundingClientRect` is not\n * suitable, such as when the element is transformed.\n *\n * **Note:** the `left` and `right` values are adjusted due to a limitation\n * in the way the browser calculates the offset position of the element,\n * which can cause unwanted scrollbars to appear. This adjustment makes the\n * values potentially inaccurate within a range of 1 pixel.\n */\nfunction getElementOffsetRect( element: HTMLElement ): ElementOffsetRect {\n\treturn {\n\t\t// The adjustments mentioned in the documentation above are necessary\n\t\t// because `offsetLeft` and `offsetTop` are rounded to the nearest pixel,\n\t\t// which can result in a position mismatch that causes unwanted overflow.\n\t\t// For context, see: https://github.com/WordPress/gutenberg/pull/61979\n\t\tleft: Math.max( element.offsetLeft - 1, 0 ),\n\t\ttop: Math.max( element.offsetTop - 1, 0 ),\n\t\t// This is a workaround to obtain these values with a sub-pixel precision,\n\t\t// since `offsetWidth` and `offsetHeight` are rounded to the nearest pixel.\n\t\twidth: parseFloat( getComputedStyle( element ).width ),\n\t\theight: parseFloat( getComputedStyle( element ).height ),\n\t};\n}\n\n/**\n * Tracks the position and dimensions of an element, relative to its offset\n * parent. The element can be changed dynamically.\n */\nfunction useTrackElementOffsetRect(\n\ttargetElement: HTMLElement | undefined | null\n) {\n\tconst [ indicatorPosition, setIndicatorPosition ] =\n\t\tuseState< ElementOffsetRect >( NULL_ELEMENT_OFFSET_RECT );\n\n\tuseResizeObserver( targetElement, ( element ) =>\n\t\tsetIndicatorPosition( getElementOffsetRect( element ) )\n\t);\n\n\treturn indicatorPosition;\n}\n\n/**\n * Context object for the `onUpdate` callback of `useOnValueUpdate`.\n */\ntype ValueUpdateContext< T > = {\n\tpreviousValue: T;\n};\n\n/**\n * Calls the `onUpdate` callback when the `value` changes.\n */\nfunction useOnValueUpdate< T >(\n\t/**\n\t * The value to watch for changes.\n\t */\n\tvalue: T,\n\t/**\n\t * Callback to fire when the value changes.\n\t */\n\tonUpdate: ( context: ValueUpdateContext< T > ) => void\n) {\n\tconst previousValueRef = useRef( value );\n\tconst updateCallbackEvent = useEvent( onUpdate );\n\tuseEffect( () => {\n\t\tif ( previousValueRef.current !== value ) {\n\t\t\tupdateCallbackEvent( {\n\t\t\t\tpreviousValue: previousValueRef.current,\n\t\t\t} );\n\t\t\tpreviousValueRef.current = value;\n\t\t}\n\t}, [ updateCallbackEvent, value ] );\n}\n\nexport const TabList = forwardRef<\n\tHTMLDivElement,\n\tWordPressComponentProps< TabListProps, 'div', false >\n>( function TabList( { children, ...otherProps }, ref ) {\n\tconst context = useTabsContext();\n\n\tconst selectedId = context?.store.useState( 'selectedId' );\n\tconst indicatorPosition = useTrackElementOffsetRect(\n\t\tcontext?.store.item( selectedId )?.element\n\t);\n\n\tconst [ animationEnabled, setAnimationEnabled ] = useState( false );\n\tuseOnValueUpdate(\n\t\tselectedId,\n\t\t( { previousValue } ) => previousValue && setAnimationEnabled( true )\n\t);\n\n\tif ( ! context ) {\n\t\twarning( '`Tabs.TabList` must be wrapped in a `Tabs` component.' );\n\t\treturn null;\n\t}\n\tconst { store } = context;\n\n\tconst { activeId, selectOnMove } = store.useState();\n\tconst { setActiveId } = store;\n\n\tconst onBlur = () => {\n\t\tif ( ! selectOnMove ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// When automatic tab selection is on, make sure that the active tab is up\n\t\t// to date with the selected tab when leaving the tablist. This makes sure\n\t\t// that the selected tab will receive keyboard focus when tabbing back into\n\t\t// the tablist.\n\t\tif ( selectedId !== activeId ) {\n\t\t\tsetActiveId( selectedId );\n\t\t}\n\t};\n\n\treturn (\n\t\t<Ariakit.TabList\n\t\t\tref={ ref }\n\t\t\tstore={ store }\n\t\t\trender={\n\t\t\t\t<TabListWrapper\n\t\t\t\t\tonTransitionEnd={ ( event ) => {\n\t\t\t\t\t\tif ( event.pseudoElement === '::after' ) {\n\t\t\t\t\t\t\tsetAnimationEnabled( false );\n\t\t\t\t\t\t}\n\t\t\t\t\t} }\n\t\t\t\t/>\n\t\t\t}\n\t\t\tonBlur={ onBlur }\n\t\t\t{ ...otherProps }\n\t\t\tstyle={ {\n\t\t\t\t'--indicator-left': `${ indicatorPosition.left }px`,\n\t\t\t\t'--indicator-top': `${ indicatorPosition.top }px`,\n\t\t\t\t'--indicator-width': `${ indicatorPosition.width }px`,\n\t\t\t\t'--indicator-height': `${ indicatorPosition.height }px`,\n\t\t\t\t...otherProps.style,\n\t\t\t} }\n\t\t\tclassName={ clsx(\n\t\t\t\tanimationEnabled ? 'is-animation-enabled' : '',\n\t\t\t\totherProps.className\n\t\t\t) }\n\t\t>\n\t\t\t{ children }\n\t\t</Ariakit.TabList>\n\t);\n} );\n"],"mappings":"AAAA;AACA;AACA;AACA,OAAO,KAAKA,OAAO,MAAM,gBAAgB;;AAEzC;AACA;AACA;AACA,OAAOC,OAAO,MAAM,oBAAoB;AACxC,SACCC,UAAU,EACVC,WAAW,EACXC,SAAS,EACTC,kBAAkB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AAQ,IAAG;MACvD,GAAGoB,UAAU,CAACiB;IACf,CAAG;IACHC,SAAS,EAAG9D,IAAI,CACfiD,gBAAgB,GAAG,sBAAsB,GAAG,EAAE,EAC9CL,UAAU,CAACkB,SACZ,CAAG;IAAAnB,QAAA,EAEDA;EAAQ,CACM,CAAC;AAEpB,CAAE,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["Ariakit","warning","forwardRef","useState","useTabsContext","TabListWrapper","clsx","useTrackElementOffsetRect","useOnValueUpdate","jsx","_jsx","TabList","children","otherProps","ref","context","selectedId","store","indicatorPosition","item","element","animationEnabled","setAnimationEnabled","previousValue","globalThis","SCRIPT_DEBUG","activeId","selectOnMove","setActiveId","onBlur","render","onTransitionEnd","event","pseudoElement","style","left","top","width","height","className"],"sources":["@wordpress/components/src/tabs/tablist.tsx"],"sourcesContent":["/**\n * External dependencies\n */\nimport * as Ariakit from '@ariakit/react';\n\n/**\n * WordPress dependencies\n */\nimport warning from '@wordpress/warning';\nimport { forwardRef, useState } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport type { TabListProps } from './types';\nimport { useTabsContext } from './context';\nimport { TabListWrapper } from './styles';\nimport type { WordPressComponentProps } from '../context';\nimport clsx from 'clsx';\nimport { useTrackElementOffsetRect } from '../utils/element-rect';\nimport { useOnValueUpdate } from '../utils/hooks/use-on-value-update';\n\nexport const TabList = forwardRef<\n\tHTMLDivElement,\n\tWordPressComponentProps< TabListProps, 'div', false >\n>( function TabList( { children, ...otherProps }, ref ) {\n\tconst context = useTabsContext();\n\n\tconst selectedId = context?.store.useState( 'selectedId' );\n\tconst indicatorPosition = useTrackElementOffsetRect(\n\t\tcontext?.store.item( selectedId )?.element\n\t);\n\n\tconst [ animationEnabled, setAnimationEnabled ] = useState( false );\n\tuseOnValueUpdate(\n\t\tselectedId,\n\t\t( { previousValue } ) => previousValue && setAnimationEnabled( true )\n\t);\n\n\tif ( ! context ) {\n\t\twarning( '`Tabs.TabList` must be wrapped in a `Tabs` component.' );\n\t\treturn null;\n\t}\n\tconst { store } = context;\n\n\tconst { activeId, selectOnMove } = store.useState();\n\tconst { setActiveId } = store;\n\n\tconst onBlur = () => {\n\t\tif ( ! selectOnMove ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// When automatic tab selection is on, make sure that the active tab is up\n\t\t// to date with the selected tab when leaving the tablist. This makes sure\n\t\t// that the selected tab will receive keyboard focus when tabbing back into\n\t\t// the tablist.\n\t\tif ( selectedId !== activeId ) {\n\t\t\tsetActiveId( selectedId );\n\t\t}\n\t};\n\n\treturn (\n\t\t<Ariakit.TabList\n\t\t\tref={ ref }\n\t\t\tstore={ store }\n\t\t\trender={\n\t\t\t\t<TabListWrapper\n\t\t\t\t\tonTransitionEnd={ ( event ) => {\n\t\t\t\t\t\tif ( event.pseudoElement === '::after' ) {\n\t\t\t\t\t\t\tsetAnimationEnabled( false );\n\t\t\t\t\t\t}\n\t\t\t\t\t} }\n\t\t\t\t/>\n\t\t\t}\n\t\t\tonBlur={ onBlur }\n\t\t\t{ ...otherProps }\n\t\t\tstyle={ {\n\t\t\t\t'--indicator-left': `${ indicatorPosition.left }px`,\n\t\t\t\t'--indicator-top': `${ indicatorPosition.top }px`,\n\t\t\t\t'--indicator-width': `${ indicatorPosition.width }px`,\n\t\t\t\t'--indicator-height': `${ indicatorPosition.height }px`,\n\t\t\t\t...otherProps.style,\n\t\t\t} }\n\t\t\tclassName={ clsx(\n\t\t\t\tanimationEnabled ? 'is-animation-enabled' : '',\n\t\t\t\totherProps.className\n\t\t\t) }\n\t\t>\n\t\t\t{ children }\n\t\t</Ariakit.TabList>\n\t);\n} );\n"],"mappings":"AAAA;AACA;AACA;AACA,OAAO,KAAKA,OAAO,MAAM,gBAAgB;;AAEzC;AACA;AACA;AACA,OAAOC,OAAO,MAAM,oBAAoB;AACxC,SAASC,UAAU,EAAEC,QAAQ,QAAQ,oBAAoB;;AAEzD;AACA;AACA;;AAEA,SAASC,cAAc,QAAQ,WAAW;AAC1C,SAAS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CAACW,OAAO;IACfG,GAAG,EAAGA,GAAK;IACXG,KAAK,EAAGA,KAAO;IACfa,MAAM,eACLpB,IAAA,CAACL,cAAc;MACd0B,eAAe,EAAKC,KAAK,IAAM;QAC9B,IAAKA,KAAK,CAACC,aAAa,KAAK,SAAS,EAAG;UACxCX,mBAAmB,CAAE,KAAM,CAAC;QAC7B;MACD;IAAG,CACH,CACD;IACDO,MAAM,EAAGA,MAAQ;IAAA,GACZhB,UAAU;IACfqB,KAAK,EAAG;MACP,kBAAkB,EAAG,GAAGhB,iBAAiB,CAACiB,IAAM,IAAG;MACnD,iBAAiB,EAAG,GAAGjB,iBAAiB,CAACkB,GAAK,IAAG;MACjD,mBAAmB,EAAG,GAAGlB,iBAAiB,CAACmB,KAAO,IAAG;MACrD,oBAAoB,EAAG,GAAGnB,iBAAiB,CAACoB,MAAQ,IAAG;MACvD,GAAGzB,UAAU,CAACqB;IACf,CAAG;IACHK,SAAS,EAAGjC,IAAI,CACfe,gBAAgB,GAAG,sBAAsB,GAAG,EAAE,EAC9CR,UAAU,CAAC0B,SACZ,CAAG;IAAA3B,QAAA,EAEDA;EAAQ,CACM,CAAC;AAEpB,CAAE,CAAC","ignoreList":[]}
@@ -65,6 +65,7 @@ function UnforwardedTextControl(props, ref) {
65
65
  *
66
66
  * return (
67
67
  * <TextControl
68
+ * __nextHasNoMarginBottom
68
69
  * label="Additional CSS Class"
69
70
  * value={ className }
70
71
  * onChange={ ( value ) => setClassName( value ) }
@@ -1 +1 @@
1
- {"version":3,"names":["clsx","useInstanceId","forwardRef","BaseControl","jsx","_jsx","UnforwardedTextControl","props","ref","__nextHasNoMarginBottom","__next40pxDefaultSize","label","hideLabelFromVision","value","help","id","idProp","className","onChange","type","additionalProps","TextControl","onChangeValue","event","target","children","undefined"],"sources":["@wordpress/components/src/text-control/index.tsx"],"sourcesContent":["/**\n * External dependencies\n */\nimport type { ChangeEvent, ForwardedRef } from 'react';\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport { useInstanceId } from '@wordpress/compose';\nimport { forwardRef } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport BaseControl from '../base-control';\nimport type { WordPressComponentProps } from '../context';\nimport type { TextControlProps } from './types';\n\nfunction UnforwardedTextControl(\n\tprops: WordPressComponentProps< TextControlProps, 'input', false >,\n\tref: ForwardedRef< HTMLInputElement >\n) {\n\tconst {\n\t\t__nextHasNoMarginBottom,\n\t\t__next40pxDefaultSize = false,\n\t\tlabel,\n\t\thideLabelFromVision,\n\t\tvalue,\n\t\thelp,\n\t\tid: idProp,\n\t\tclassName,\n\t\tonChange,\n\t\ttype = 'text',\n\t\t...additionalProps\n\t} = props;\n\tconst id = useInstanceId( TextControl, 'inspector-text-control', idProp );\n\tconst onChangeValue = ( event: ChangeEvent< HTMLInputElement > ) =>\n\t\tonChange( event.target.value );\n\n\treturn (\n\t\t<BaseControl\n\t\t\t__nextHasNoMarginBottom={ __nextHasNoMarginBottom }\n\t\t\tlabel={ label }\n\t\t\thideLabelFromVision={ hideLabelFromVision }\n\t\t\tid={ id }\n\t\t\thelp={ help }\n\t\t\tclassName={ className }\n\t\t>\n\t\t\t<input\n\t\t\t\tclassName={ clsx( 'components-text-control__input', {\n\t\t\t\t\t'is-next-40px-default-size': __next40pxDefaultSize,\n\t\t\t\t} ) }\n\t\t\t\ttype={ type }\n\t\t\t\tid={ id }\n\t\t\t\tvalue={ value }\n\t\t\t\tonChange={ onChangeValue }\n\t\t\t\taria-describedby={ !! help ? id + '__help' : undefined }\n\t\t\t\tref={ ref }\n\t\t\t\t{ ...additionalProps }\n\t\t\t/>\n\t\t</BaseControl>\n\t);\n}\n\n/**\n * TextControl components let users enter and edit text.\n *\n * ```jsx\n * import { TextControl } from '@wordpress/components';\n * import { useState } from '@wordpress/element';\n *\n * const MyTextControl = () => {\n * const [ className, setClassName ] = useState( '' );\n *\n * return (\n * <TextControl\n * label=\"Additional CSS Class\"\n * value={ className }\n * onChange={ ( value ) => setClassName( value ) }\n * />\n * );\n * };\n * ```\n */\nexport const TextControl = forwardRef( UnforwardedTextControl );\n\nexport default TextControl;\n"],"mappings":"AAAA;AACA;AACA;;AAEA,OAAOA,IAAI,MAAM,MAAM;;AAEvB;AACA;AACA;AACA,SAASC,aAAa,QAAQ,oBAAoB;AAClD,SAASC,UAAU,QAAQ,oBAAoB;;AAE/C;AACA;AACA;AACA,OAAOC,WAAW,MAAM,iBAAiB;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAI1C,SAASC,sBAAsBA,CAC9BC,KAAkE,EAClEC,GAAqC,EACpC;EACD,MAAM;IACLC,uBAAuB;IACvBC,qBAAqB,GAAG,KAAK;IAC7BC,KAAK;IACLC,mBAAmB;IACnBC,KAAK;IACLC,IAAI;IACJC,EAAE,EAAEC,MAAM;IACVC,SAAS;IACTC,QAAQ;IACRC,IAAI,GAAG,MAAM;IACb,GAAGC;EACJ,CAAC,GAAGb,KAAK;EACT,MAAMQ,EAAE,GAAGd,aAAa,CAAEoB,WAAW,EAAE,wBAAwB,EAAEL,MAAO,CAAC;EACzE,MAAMM,aAAa,GAAKC,KAAsC,IAC7DL,QAAQ,CAAEK,KAAK,CAACC,MAAM,CAACX,KAAM,CAAC;EAE/B,oBACCR,IAAA,CAACF,WAAW;IACXM,uBAAuB,EAAGA,uBAAyB;IACnDE,KAAK,EAAGA,KAAO;IACfC,mBAAmB,EAAGA,mBAAqB;IAC3CG,EAAE,EAAGA,EAAI;IACTD,IAAI,EAAGA,IAAM;IACbG,SAAS,EAAGA,SAAW;IAAAQ,QAAA,eAEvBpB,IAAA;MACCY,SAAS,EAAGjB,IAAI,CAAE,gCAAgC,EAAE;QACnD,2BAA2B,EAAEU;MAC9B,CAAE,CAAG;MACLS,IAAI,EAAGA,IAAM;MACbJ,EAAE,EAAGA,EAAI;MACTF,KAAK,EAAGA,KAAO;MACfK,QAAQ,EAAGI,aAAe;MAC1B,oBAAmB,CAAC,CAAER,IAAI,GAAGC,EAAE,GAAG,QAAQ,GAAGW,SAAW;MACxDlB,GAAG,EAAGA,GAAK;MAAA,GACNY;IAAe,CACpB;EAAC,CACU,CAAC;AAEhB;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,WAAW,GAAGnB,UAAU,CAAEI,sBAAuB,CAAC;AAE/D,eAAee,WAAW","ignoreList":[]}
1
+ {"version":3,"names":["clsx","useInstanceId","forwardRef","BaseControl","jsx","_jsx","UnforwardedTextControl","props","ref","__nextHasNoMarginBottom","__next40pxDefaultSize","label","hideLabelFromVision","value","help","id","idProp","className","onChange","type","additionalProps","TextControl","onChangeValue","event","target","children","undefined"],"sources":["@wordpress/components/src/text-control/index.tsx"],"sourcesContent":["/**\n * External dependencies\n */\nimport type { ChangeEvent, ForwardedRef } from 'react';\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport { useInstanceId } from '@wordpress/compose';\nimport { forwardRef } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport BaseControl from '../base-control';\nimport type { WordPressComponentProps } from '../context';\nimport type { TextControlProps } from './types';\n\nfunction UnforwardedTextControl(\n\tprops: WordPressComponentProps< TextControlProps, 'input', false >,\n\tref: ForwardedRef< HTMLInputElement >\n) {\n\tconst {\n\t\t__nextHasNoMarginBottom,\n\t\t__next40pxDefaultSize = false,\n\t\tlabel,\n\t\thideLabelFromVision,\n\t\tvalue,\n\t\thelp,\n\t\tid: idProp,\n\t\tclassName,\n\t\tonChange,\n\t\ttype = 'text',\n\t\t...additionalProps\n\t} = props;\n\tconst id = useInstanceId( TextControl, 'inspector-text-control', idProp );\n\tconst onChangeValue = ( event: ChangeEvent< HTMLInputElement > ) =>\n\t\tonChange( event.target.value );\n\n\treturn (\n\t\t<BaseControl\n\t\t\t__nextHasNoMarginBottom={ __nextHasNoMarginBottom }\n\t\t\tlabel={ label }\n\t\t\thideLabelFromVision={ hideLabelFromVision }\n\t\t\tid={ id }\n\t\t\thelp={ help }\n\t\t\tclassName={ className }\n\t\t>\n\t\t\t<input\n\t\t\t\tclassName={ clsx( 'components-text-control__input', {\n\t\t\t\t\t'is-next-40px-default-size': __next40pxDefaultSize,\n\t\t\t\t} ) }\n\t\t\t\ttype={ type }\n\t\t\t\tid={ id }\n\t\t\t\tvalue={ value }\n\t\t\t\tonChange={ onChangeValue }\n\t\t\t\taria-describedby={ !! help ? id + '__help' : undefined }\n\t\t\t\tref={ ref }\n\t\t\t\t{ ...additionalProps }\n\t\t\t/>\n\t\t</BaseControl>\n\t);\n}\n\n/**\n * TextControl components let users enter and edit text.\n *\n * ```jsx\n * import { TextControl } from '@wordpress/components';\n * import { useState } from '@wordpress/element';\n *\n * const MyTextControl = () => {\n * const [ className, setClassName ] = useState( '' );\n *\n * return (\n * <TextControl\n * __nextHasNoMarginBottom\n * label=\"Additional CSS Class\"\n * value={ className }\n * onChange={ ( value ) => setClassName( value ) }\n * />\n * );\n * };\n * ```\n */\nexport const TextControl = forwardRef( UnforwardedTextControl );\n\nexport default TextControl;\n"],"mappings":"AAAA;AACA;AACA;;AAEA,OAAOA,IAAI,MAAM,MAAM;;AAEvB;AACA;AACA;AACA,SAASC,aAAa,QAAQ,oBAAoB;AAClD,SAASC,UAAU,QAAQ,oBAAoB;;AAE/C;AACA;AACA;AACA,OAAOC,WAAW,MAAM,iBAAiB;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAI1C,SAASC,sBAAsBA,CAC9BC,KAAkE,EAClEC,GAAqC,EACpC;EACD,MAAM;IACLC,uBAAuB;IACvBC,qBAAqB,GAAG,KAAK;IAC7BC,KAAK;IACLC,mBAAmB;IACnBC,KAAK;IACLC,IAAI;IACJC,EAAE,EAAEC,MAAM;IACVC,SAAS;IACTC,QAAQ;IACRC,IAAI,GAAG,MAAM;IACb,GAAGC;EACJ,CAAC,GAAGb,KAAK;EACT,MAAMQ,EAAE,GAAGd,aAAa,CAAEoB,WAAW,EAAE,wBAAwB,EAAEL,MAAO,CAAC;EACzE,MAAMM,aAAa,GAAKC,KAAsC,IAC7DL,QAAQ,CAAEK,KAAK,CAACC,MAAM,CAACX,KAAM,CAAC;EAE/B,oBACCR,IAAA,CAACF,WAAW;IACXM,uBAAuB,EAAGA,uBAAyB;IACnDE,KAAK,EAAGA,KAAO;IACfC,mBAAmB,EAAGA,mBAAqB;IAC3CG,EAAE,EAAGA,EAAI;IACTD,IAAI,EAAGA,IAAM;IACbG,SAAS,EAAGA,SAAW;IAAAQ,QAAA,eAEvBpB,IAAA;MACCY,SAAS,EAAGjB,IAAI,CAAE,gCAAgC,EAAE;QACnD,2BAA2B,EAAEU;MAC9B,CAAE,CAAG;MACLS,IAAI,EAAGA,IAAM;MACbJ,EAAE,EAAGA,EAAI;MACTF,KAAK,EAAGA,KAAO;MACfK,QAAQ,EAAGI,aAAe;MAC1B,oBAAmB,CAAC,CAAER,IAAI,GAAGC,EAAE,GAAG,QAAQ,GAAGW,SAAW;MACxDlB,GAAG,EAAGA,GAAK;MAAA,GACNY;IAAe,CACpB;EAAC,CACU,CAAC;AAEhB;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,WAAW,GAAGnB,UAAU,CAAEI,sBAAuB,CAAC;AAE/D,eAAee,WAAW","ignoreList":[]}
@@ -59,6 +59,7 @@ function UnforwardedTextareaControl(props, ref) {
59
59
  *
60
60
  * return (
61
61
  * <TextareaControl
62
+ * __nextHasNoMarginBottom
62
63
  * label="Text"
63
64
  * help="Enter some text"
64
65
  * value={ text }
@@ -1 +1 @@
1
- {"version":3,"names":["useInstanceId","forwardRef","BaseControl","StyledTextarea","jsx","_jsx","UnforwardedTextareaControl","props","ref","__nextHasNoMarginBottom","label","hideLabelFromVision","value","help","onChange","rows","className","additionalProps","instanceId","TextareaControl","id","onChangeValue","event","target","children","undefined"],"sources":["@wordpress/components/src/textarea-control/index.tsx"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { useInstanceId } from '@wordpress/compose';\nimport { forwardRef } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport BaseControl from '../base-control';\nimport { StyledTextarea } from './styles/textarea-control-styles';\nimport type { TextareaControlProps } from './types';\nimport type { WordPressComponentProps } from '../context';\n\nfunction UnforwardedTextareaControl(\n\tprops: WordPressComponentProps< TextareaControlProps, 'textarea', false >,\n\tref: React.ForwardedRef< HTMLTextAreaElement >\n) {\n\tconst {\n\t\t__nextHasNoMarginBottom,\n\t\tlabel,\n\t\thideLabelFromVision,\n\t\tvalue,\n\t\thelp,\n\t\tonChange,\n\t\trows = 4,\n\t\tclassName,\n\t\t...additionalProps\n\t} = props;\n\tconst instanceId = useInstanceId( TextareaControl );\n\tconst id = `inspector-textarea-control-${ instanceId }`;\n\tconst onChangeValue = ( event: React.ChangeEvent< HTMLTextAreaElement > ) =>\n\t\tonChange( event.target.value );\n\n\treturn (\n\t\t<BaseControl\n\t\t\t__nextHasNoMarginBottom={ __nextHasNoMarginBottom }\n\t\t\tlabel={ label }\n\t\t\thideLabelFromVision={ hideLabelFromVision }\n\t\t\tid={ id }\n\t\t\thelp={ help }\n\t\t\tclassName={ className }\n\t\t>\n\t\t\t<StyledTextarea\n\t\t\t\tclassName=\"components-textarea-control__input\"\n\t\t\t\tid={ id }\n\t\t\t\trows={ rows }\n\t\t\t\tonChange={ onChangeValue }\n\t\t\t\taria-describedby={ !! help ? id + '__help' : undefined }\n\t\t\t\tvalue={ value }\n\t\t\t\tref={ ref }\n\t\t\t\t{ ...additionalProps }\n\t\t\t/>\n\t\t</BaseControl>\n\t);\n}\n\n/**\n * TextareaControls are TextControls that allow for multiple lines of text, and\n * wrap overflow text onto a new line. They are a fixed height and scroll\n * vertically when the cursor reaches the bottom of the field.\n *\n * ```jsx\n * import { TextareaControl } from '@wordpress/components';\n * import { useState } from '@wordpress/element';\n *\n * const MyTextareaControl = () => {\n * const [ text, setText ] = useState( '' );\n *\n * return (\n * <TextareaControl\n * label=\"Text\"\n * help=\"Enter some text\"\n * value={ text }\n * onChange={ ( value ) => setText( value ) }\n * />\n * );\n * };\n * ```\n */\nexport const TextareaControl = forwardRef( UnforwardedTextareaControl );\n\nexport default TextareaControl;\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,aAAa,QAAQ,oBAAoB;AAClD,SAASC,UAAU,QAAQ,oBAAoB;;AAE/C;AACA;AACA;AACA,OAAOC,WAAW,MAAM,iBAAiB;AACzC,SAASC,cAAc,QAAQ,kCAAkC;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAIlE,SAASC,0BAA0BA,CAClCC,KAAyE,EACzEC,GAA8C,EAC7C;EACD,MAAM;IACLC,uBAAuB;IACvBC,KAAK;IACLC,mBAAmB;IACnBC,KAAK;IACLC,IAAI;IACJC,QAAQ;IACRC,IAAI,GAAG,CAAC;IACRC,SAAS;IACT,GAAGC;EACJ,CAAC,GAAGV,KAAK;EACT,MAAMW,UAAU,GAAGlB,aAAa,CAAEmB,eAAgB,CAAC;EACnD,MAAMC,EAAE,GAAI,8BAA8BF,UAAY,EAAC;EACvD,MAAMG,aAAa,GAAKC,KAA+C,IACtER,QAAQ,CAAEQ,KAAK,CAACC,MAAM,CAACX,KAAM,CAAC;EAE/B,oBACCP,IAAA,CAACH,WAAW;IACXO,uBAAuB,EAAGA,uBAAyB;IACnDC,KAAK,EAAGA,KAAO;IACfC,mBAAmB,EAAGA,mBAAqB;IAC3CS,EAAE,EAAGA,EAAI;IACTP,IAAI,EAAGA,IAAM;IACbG,SAAS,EAAGA,SAAW;IAAAQ,QAAA,eAEvBnB,IAAA,CAACF,cAAc;MACda,SAAS,EAAC,oCAAoC;MAC9CI,EAAE,EAAGA,EAAI;MACTL,IAAI,EAAGA,IAAM;MACbD,QAAQ,EAAGO,aAAe;MAC1B,oBAAmB,CAAC,CAAER,IAAI,GAAGO,EAAE,GAAG,QAAQ,GAAGK,SAAW;MACxDb,KAAK,EAAGA,KAAO;MACfJ,GAAG,EAAGA,GAAK;MAAA,GACNS;IAAe,CACpB;EAAC,CACU,CAAC;AAEhB;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAME,eAAe,GAAGlB,UAAU,CAAEK,0BAA2B,CAAC;AAEvE,eAAea,eAAe","ignoreList":[]}
1
+ {"version":3,"names":["useInstanceId","forwardRef","BaseControl","StyledTextarea","jsx","_jsx","UnforwardedTextareaControl","props","ref","__nextHasNoMarginBottom","label","hideLabelFromVision","value","help","onChange","rows","className","additionalProps","instanceId","TextareaControl","id","onChangeValue","event","target","children","undefined"],"sources":["@wordpress/components/src/textarea-control/index.tsx"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { useInstanceId } from '@wordpress/compose';\nimport { forwardRef } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport BaseControl from '../base-control';\nimport { StyledTextarea } from './styles/textarea-control-styles';\nimport type { TextareaControlProps } from './types';\nimport type { WordPressComponentProps } from '../context';\n\nfunction UnforwardedTextareaControl(\n\tprops: WordPressComponentProps< TextareaControlProps, 'textarea', false >,\n\tref: React.ForwardedRef< HTMLTextAreaElement >\n) {\n\tconst {\n\t\t__nextHasNoMarginBottom,\n\t\tlabel,\n\t\thideLabelFromVision,\n\t\tvalue,\n\t\thelp,\n\t\tonChange,\n\t\trows = 4,\n\t\tclassName,\n\t\t...additionalProps\n\t} = props;\n\tconst instanceId = useInstanceId( TextareaControl );\n\tconst id = `inspector-textarea-control-${ instanceId }`;\n\tconst onChangeValue = ( event: React.ChangeEvent< HTMLTextAreaElement > ) =>\n\t\tonChange( event.target.value );\n\n\treturn (\n\t\t<BaseControl\n\t\t\t__nextHasNoMarginBottom={ __nextHasNoMarginBottom }\n\t\t\tlabel={ label }\n\t\t\thideLabelFromVision={ hideLabelFromVision }\n\t\t\tid={ id }\n\t\t\thelp={ help }\n\t\t\tclassName={ className }\n\t\t>\n\t\t\t<StyledTextarea\n\t\t\t\tclassName=\"components-textarea-control__input\"\n\t\t\t\tid={ id }\n\t\t\t\trows={ rows }\n\t\t\t\tonChange={ onChangeValue }\n\t\t\t\taria-describedby={ !! help ? id + '__help' : undefined }\n\t\t\t\tvalue={ value }\n\t\t\t\tref={ ref }\n\t\t\t\t{ ...additionalProps }\n\t\t\t/>\n\t\t</BaseControl>\n\t);\n}\n\n/**\n * TextareaControls are TextControls that allow for multiple lines of text, and\n * wrap overflow text onto a new line. They are a fixed height and scroll\n * vertically when the cursor reaches the bottom of the field.\n *\n * ```jsx\n * import { TextareaControl } from '@wordpress/components';\n * import { useState } from '@wordpress/element';\n *\n * const MyTextareaControl = () => {\n * const [ text, setText ] = useState( '' );\n *\n * return (\n * <TextareaControl\n * __nextHasNoMarginBottom\n * label=\"Text\"\n * help=\"Enter some text\"\n * value={ text }\n * onChange={ ( value ) => setText( value ) }\n * />\n * );\n * };\n * ```\n */\nexport const TextareaControl = forwardRef( UnforwardedTextareaControl );\n\nexport default TextareaControl;\n"],"mappings":"AAAA;AACA;AACA;AACA,SAASA,aAAa,QAAQ,oBAAoB;AAClD,SAASC,UAAU,QAAQ,oBAAoB;;AAE/C;AACA;AACA;AACA,OAAOC,WAAW,MAAM,iBAAiB;AACzC,SAASC,cAAc,QAAQ,kCAAkC;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAIlE,SAASC,0BAA0BA,CAClCC,KAAyE,EACzEC,GAA8C,EAC7C;EACD,MAAM;IACLC,uBAAuB;IACvBC,KAAK;IACLC,mBAAmB;IACnBC,KAAK;IACLC,IAAI;IACJC,QAAQ;IACRC,IAAI,GAAG,CAAC;IACRC,SAAS;IACT,GAAGC;EACJ,CAAC,GAAGV,KAAK;EACT,MAAMW,UAAU,GAAGlB,aAAa,CAAEmB,eAAgB,CAAC;EACnD,MAAMC,EAAE,GAAI,8BAA8BF,UAAY,EAAC;EACvD,MAAMG,aAAa,GAAKC,KAA+C,IACtER,QAAQ,CAAEQ,KAAK,CAACC,MAAM,CAACX,KAAM,CAAC;EAE/B,oBACCP,IAAA,CAACH,WAAW;IACXO,uBAAuB,EAAGA,uBAAyB;IACnDC,KAAK,EAAGA,KAAO;IACfC,mBAAmB,EAAGA,mBAAqB;IAC3CS,EAAE,EAAGA,EAAI;IACTP,IAAI,EAAGA,IAAM;IACbG,SAAS,EAAGA,SAAW;IAAAQ,QAAA,eAEvBnB,IAAA,CAACF,cAAc;MACda,SAAS,EAAC,oCAAoC;MAC9CI,EAAE,EAAGA,EAAI;MACTL,IAAI,EAAGA,IAAM;MACbD,QAAQ,EAAGO,aAAe;MAC1B,oBAAmB,CAAC,CAAER,IAAI,GAAGO,EAAE,GAAG,QAAQ,GAAGK,SAAW;MACxDb,KAAK,EAAGA,KAAO;MACfJ,GAAG,EAAGA,GAAK;MAAA,GACNS;IAAe,CACpB;EAAC,CACU,CAAC;AAEhB;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAME,eAAe,GAAGlB,UAAU,CAAEK,0BAA2B,CAAC;AAEvE,eAAea,eAAe","ignoreList":[]}
@@ -3,6 +3,7 @@
3
3
  */
4
4
 
5
5
  import { css } from '@emotion/react';
6
+ import clsx from 'clsx';
6
7
 
7
8
  /**
8
9
  * WordPress dependencies
@@ -19,30 +20,9 @@ import BaseControl from '../base-control';
19
20
  import { HStack } from '../h-stack';
20
21
  import { useCx } from '../utils';
21
22
  import { space } from '../utils/space';
22
-
23
- /**
24
- * ToggleControl is used to generate a toggle user interface.
25
- *
26
- * ```jsx
27
- * import { ToggleControl } from '@wordpress/components';
28
- * import { useState } from '@wordpress/element';
29
- *
30
- * const MyToggleControl = () => {
31
- * const [ value, setValue ] = useState( false );
32
- *
33
- * return (
34
- * <ToggleControl
35
- * label="Fixed Background"
36
- * checked={ value }
37
- * onChange={ () => setValue( ( state ) => ! state ) }
38
- * />
39
- * );
40
- * };
41
- * ```
42
- */
43
23
  import { jsx as _jsx } from "react/jsx-runtime";
44
24
  import { jsxs as _jsxs } from "react/jsx-runtime";
45
- export function ToggleControl({
25
+ function UnforwardedToggleControl({
46
26
  __nextHasNoMarginBottom,
47
27
  label,
48
28
  checked,
@@ -59,7 +39,7 @@ export function ToggleControl({
59
39
  const cx = useCx();
60
40
  const classes = cx('components-toggle-control', className, !__nextHasNoMarginBottom && /*#__PURE__*/css({
61
41
  marginBottom: space(3)
62
- }, process.env.NODE_ENV === "production" ? "" : ";label:classes;", process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIkB3b3JkcHJlc3MvY29tcG9uZW50cy9zcmMvdG9nZ2xlLWNvbnRyb2wvaW5kZXgudHN4Il0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQWtFK0IiLCJmaWxlIjoiQHdvcmRwcmVzcy9jb21wb25lbnRzL3NyYy90b2dnbGUtY29udHJvbC9pbmRleC50c3giLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEV4dGVybmFsIGRlcGVuZGVuY2llc1xuICovXG5pbXBvcnQgdHlwZSB7IENoYW5nZUV2ZW50LCBGb3J3YXJkZWRSZWYgfSBmcm9tICdyZWFjdCc7XG5pbXBvcnQgeyBjc3MgfSBmcm9tICdAZW1vdGlvbi9yZWFjdCc7XG5cbi8qKlxuICogV29yZFByZXNzIGRlcGVuZGVuY2llc1xuICovXG5pbXBvcnQgeyBmb3J3YXJkUmVmIH0gZnJvbSAnQHdvcmRwcmVzcy9lbGVtZW50JztcbmltcG9ydCB7IHVzZUluc3RhbmNlSWQgfSBmcm9tICdAd29yZHByZXNzL2NvbXBvc2UnO1xuXG4vKipcbiAqIEludGVybmFsIGRlcGVuZGVuY2llc1xuICovXG5pb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XHRcdFx0XHRyZWY9eyByZWYgfVxuXHRcdFx0XHQvPlxuXHRcdFx0XHQ8RmxleEJsb2NrXG5cdFx0XHRcdFx0YXM9XCJsYWJlbFwiXG5cdFx0XHRcdFx0aHRtbEZvcj17IGlkIH1cblx0XHRcdFx0XHRjbGFzc05hbWU9XCJjb21wb25lbnRzLXRvZ2dsZS1jb250cm9sX19sYWJlbFwiXG5cdFx0XHRcdD5cblx0XHRcdFx0XHR7IGxhYmVsIH1cblx0XHRcdFx0PC9GbGV4QmxvY2s+XG5cdFx0XHQ8L0hTdGFjaz5cblx0XHQ8L0Jhc2VDb250cm9sPlxuXHQpO1xufVxuXG5leHBvcnQgZGVmYXVsdCBmb3J3YXJkUmVmKCBUb2dnbGVDb250cm9sICk7XG4iXX0= */"));
42
+ }, process.env.NODE_ENV === "production" ? "" : ";label:classes;", process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIkB3b3JkcHJlc3MvY29tcG9uZW50cy9zcmMvdG9nZ2xlLWNvbnRyb2wvaW5kZXgudHN4Il0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQStDK0IiLCJmaWxlIjoiQHdvcmRwcmVzcy9jb21wb25lbnRzL3NyYy90b2dnbGUtY29udHJvbC9pbmRleC50c3giLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEV4dGVybmFsIGRlcGVuZGVuY2llc1xuICovXG5pbXBvcnQgdHlwZSB7IENoYW5nZUV2ZW50LCBGb3J3YXJkZWRSZWYgfSBmcm9tICdyZWFjdCc7XG5pbXBvcnQgeyBjc3MgfSBmcm9tICdAZW1vdGlvbi9yZWFjdCc7XG5pbXBvcnQgY2xzeCBmcm9tICdjbHN4JztcblxuLyoqXG4gKiBXb3JkUHJlc3MgZGVwZW5kZW5jaWVzXG4gKi9cbmltcG9ydCB7IGZvcndhcmRSZWYgfSBmcm9tICdAd29yZHByZXNz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cblx0XHRcdFx0PlxuXHRcdFx0XHRcdHsgbGFiZWwgfVxuXHRcdFx0XHQ8L0ZsZXhCbG9jaz5cblx0XHRcdDwvSFN0YWNrPlxuXHRcdDwvQmFzZUNvbnRyb2w+XG5cdCk7XG59XG5cbi8qKlxuICogVG9nZ2xlQ29udHJvbCBpcyB1c2VkIHRvIGdlbmVyYXRlIGEgdG9nZ2xlIHVzZXIgaW50ZXJmYWNlLlxuICpcbiAqIGBgYGpzeFxuICogaW1wb3J0IHsgVG9nZ2xlQ29udHJvbCB9IGZyb20gJ0B3b3JkcHJlc3MvY29tcG9uZW50cyc7XG4gKiBpbXBvcnQgeyB1c2VTdGF0ZSB9IGZyb20gJ0B3b3JkcHJlc3MvZWxlbWVudCc7XG4gKlxuICogY29uc3QgTXlUb2dnbGVDb250cm9sID0gKCkgPT4ge1xuICogICBjb25zdCBbIHZhbHVlLCBzZXRWYWx1ZSBdID0gdXNlU3RhdGUoIGZhbHNlICk7XG4gKlxuICogICByZXR1cm4gKFxuICogICAgIDxUb2dnbGVDb250cm9sXG4gKiAgICAgICBfX25leHRIYXNOb01hcmdpbkJvdHRvbVxuICogICAgICAgbGFiZWw9XCJGaXhlZCBCYWNrZ3JvdW5kXCJcbiAqICAgICAgIGNoZWNrZWQ9eyB2YWx1ZSB9XG4gKiAgICAgICBvbkNoYW5nZT17ICgpID0+IHNldFZhbHVlKCAoIHN0YXRlICkgPT4gISBzdGF0ZSApIH1cbiAqICAgICAvPlxuICogICApO1xuICogfTtcbiAqIGBgYFxuICovXG5leHBvcnQgY29uc3QgVG9nZ2xlQ29udHJvbCA9IGZvcndhcmRSZWYoIFVuZm9yd2FyZGVkVG9nZ2xlQ29udHJvbCApO1xuXG5leHBvcnQgZGVmYXVsdCBUb2dnbGVDb250cm9sO1xuIl19 */"));
63
43
  let describedBy, helpLabel;
64
44
  if (help) {
65
45
  if (typeof help === 'function') {
@@ -78,12 +58,15 @@ export function ToggleControl({
78
58
  }
79
59
  return /*#__PURE__*/_jsx(BaseControl, {
80
60
  id: id,
81
- help: helpLabel,
61
+ help: helpLabel && /*#__PURE__*/_jsx("span", {
62
+ className: "components-toggle-control__help",
63
+ children: helpLabel
64
+ }),
82
65
  className: classes,
83
66
  __nextHasNoMarginBottom: true,
84
67
  children: /*#__PURE__*/_jsxs(HStack, {
85
68
  justify: "flex-start",
86
- spacing: 3,
69
+ spacing: 2,
87
70
  children: [/*#__PURE__*/_jsx(FormToggle, {
88
71
  id: id,
89
72
  checked: checked,
@@ -94,11 +77,36 @@ export function ToggleControl({
94
77
  }), /*#__PURE__*/_jsx(FlexBlock, {
95
78
  as: "label",
96
79
  htmlFor: id,
97
- className: "components-toggle-control__label",
80
+ className: clsx('components-toggle-control__label', {
81
+ 'is-disabled': disabled
82
+ }),
98
83
  children: label
99
84
  })]
100
85
  })
101
86
  });
102
87
  }
103
- export default forwardRef(ToggleControl);
88
+
89
+ /**
90
+ * ToggleControl is used to generate a toggle user interface.
91
+ *
92
+ * ```jsx
93
+ * import { ToggleControl } from '@wordpress/components';
94
+ * import { useState } from '@wordpress/element';
95
+ *
96
+ * const MyToggleControl = () => {
97
+ * const [ value, setValue ] = useState( false );
98
+ *
99
+ * return (
100
+ * <ToggleControl
101
+ * __nextHasNoMarginBottom
102
+ * label="Fixed Background"
103
+ * checked={ value }
104
+ * onChange={ () => setValue( ( state ) => ! state ) }
105
+ * />
106
+ * );
107
+ * };
108
+ * ```
109
+ */
110
+ export const ToggleControl = forwardRef(UnforwardedToggleControl);
111
+ export default ToggleControl;
104
112
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["css","forwardRef","useInstanceId","FlexBlock","FormToggle","BaseControl","HStack","useCx","space","jsx","_jsx","jsxs","_jsxs","ToggleControl","__nextHasNoMarginBottom","label","checked","help","className","onChange","disabled","ref","onChangeToggle","event","target","instanceId","id","cx","classes","marginBottom","process","env","NODE_ENV","describedBy","helpLabel","undefined","children","justify","spacing","as","htmlFor"],"sources":["@wordpress/components/src/toggle-control/index.tsx"],"sourcesContent":["/**\n * External dependencies\n */\nimport type { ChangeEvent, ForwardedRef } from 'react';\nimport { css } from '@emotion/react';\n\n/**\n * WordPress dependencies\n */\nimport { forwardRef } from '@wordpress/element';\nimport { useInstanceId } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport { FlexBlock } from '../flex';\nimport FormToggle from '../form-toggle';\nimport BaseControl from '../base-control';\nimport type { WordPressComponentProps } from '../context/wordpress-component';\nimport type { ToggleControlProps } from './types';\nimport { HStack } from '../h-stack';\nimport { useCx } from '../utils';\nimport { space } from '../utils/space';\n\n/**\n * ToggleControl is used to generate a toggle user interface.\n *\n * ```jsx\n * import { ToggleControl } from '@wordpress/components';\n * import { useState } from '@wordpress/element';\n *\n * const MyToggleControl = () => {\n * const [ value, setValue ] = useState( false );\n *\n * return (\n * <ToggleControl\n * label=\"Fixed Background\"\n * checked={ value }\n * onChange={ () => setValue( ( state ) => ! state ) }\n * />\n * );\n * };\n * ```\n */\nexport function ToggleControl(\n\t{\n\t\t__nextHasNoMarginBottom,\n\t\tlabel,\n\t\tchecked,\n\t\thelp,\n\t\tclassName,\n\t\tonChange,\n\t\tdisabled,\n\t}: WordPressComponentProps< ToggleControlProps, 'input', false >,\n\tref: ForwardedRef< HTMLInputElement >\n) {\n\tfunction onChangeToggle( event: ChangeEvent< HTMLInputElement > ) {\n\t\tonChange( event.target.checked );\n\t}\n\tconst instanceId = useInstanceId( ToggleControl );\n\tconst id = `inspector-toggle-control-${ instanceId }`;\n\n\tconst cx = useCx();\n\tconst classes = cx(\n\t\t'components-toggle-control',\n\t\tclassName,\n\t\t! __nextHasNoMarginBottom && css( { marginBottom: space( 3 ) } )\n\t);\n\n\tlet describedBy, helpLabel;\n\tif ( help ) {\n\t\tif ( typeof help === 'function' ) {\n\t\t\t// `help` as a function works only for controlled components where\n\t\t\t// `checked` is passed down from parent component. Uncontrolled\n\t\t\t// component can show only a static help label.\n\t\t\tif ( checked !== undefined ) {\n\t\t\t\thelpLabel = help( checked );\n\t\t\t}\n\t\t} else {\n\t\t\thelpLabel = help;\n\t\t}\n\t\tif ( helpLabel ) {\n\t\t\tdescribedBy = id + '__help';\n\t\t}\n\t}\n\n\treturn (\n\t\t<BaseControl\n\t\t\tid={ id }\n\t\t\thelp={ helpLabel }\n\t\t\tclassName={ classes }\n\t\t\t__nextHasNoMarginBottom\n\t\t>\n\t\t\t<HStack justify=\"flex-start\" spacing={ 3 }>\n\t\t\t\t<FormToggle\n\t\t\t\t\tid={ id }\n\t\t\t\t\tchecked={ checked }\n\t\t\t\t\tonChange={ onChangeToggle }\n\t\t\t\t\taria-describedby={ describedBy }\n\t\t\t\t\tdisabled={ disabled }\n\t\t\t\t\tref={ ref }\n\t\t\t\t/>\n\t\t\t\t<FlexBlock\n\t\t\t\t\tas=\"label\"\n\t\t\t\t\thtmlFor={ id }\n\t\t\t\t\tclassName=\"components-toggle-control__label\"\n\t\t\t\t>\n\t\t\t\t\t{ label }\n\t\t\t\t</FlexBlock>\n\t\t\t</HStack>\n\t\t</BaseControl>\n\t);\n}\n\nexport default forwardRef( ToggleControl );\n"],"mappings":"AAAA;AACA;AACA;;AAEA,SAASA,GAAG,QAAQ,gBAAgB;;AAEpC;AACA;AACA;AACA,SAASC,UAAU,QAAQ,oBAAoB;AAC/C,SAASC,aAAa,QAAQ,oBAAoB;;AAElD;AACA;AACA;AACA,SAASC,SAAS,QAAQ,SAAS;AACnC,OAAOC,UAAU,MAAM,gBAAgB;AACvC,OAAOC,WAAW,MAAM,iBAAiB;AAGzC,SAASC,MAAM,QAAQ,YAAY;AACnC,SAASC,KAAK,QAAQ,UAAU;AAChC,SAASC,KAAK,QAAQ,gBAAgB;;AAEtC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAnBA,SAAAC,GAAA,IAAAC,IAAA;AAAA,SAAAC,IAAA,IAAAC,KAAA;AAoBA,OA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,CAACN,UAAU;QACVsB,EAAE,EAAGA,EAAI;QACTV,OAAO,EAAGA,OAAS;QACnBG,QAAQ,EAAGG,cAAgB;QAC3B,oBAAmBW,WAAa;QAChCb,QAAQ,EAAGA,QAAU;QACrBC,GAAG,EAAGA;MAAK,CACX,CAAC,eACFX,IAAA,CAACP,SAAS;QACToC,EAAE,EAAC,OAAO;QACVC,OAAO,EAAGd,EAAI;QACdR,SAAS,EAAC,kCAAkC;QAAAkB,QAAA,EAE1CrB;MAAK,CACG,CAAC;IAAA,CACL;EAAC,CACG,CAAC;AAEhB;AAEA,eAAed,UAAU,CAAEY,aAAc,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["css","clsx","forwardRef","useInstanceId","FlexBlock","FormToggle","BaseControl","HStack","useCx","space","jsx","_jsx","jsxs","_jsxs","UnforwardedToggleControl","__nextHasNoMarginBottom","label","checked","help","className","onChange","disabled","ref","onChangeToggle","event","target","instanceId","ToggleControl","id","cx","classes","marginBottom","process","env","NODE_ENV","describedBy","helpLabel","undefined","children","justify","spacing","as","htmlFor"],"sources":["@wordpress/components/src/toggle-control/index.tsx"],"sourcesContent":["/**\n * External dependencies\n */\nimport type { ChangeEvent, ForwardedRef } from 'react';\nimport { css } from '@emotion/react';\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport { forwardRef } from '@wordpress/element';\nimport { useInstanceId } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport { FlexBlock } from '../flex';\nimport FormToggle from '../form-toggle';\nimport BaseControl from '../base-control';\nimport type { WordPressComponentProps } from '../context/wordpress-component';\nimport type { ToggleControlProps } from './types';\nimport { HStack } from '../h-stack';\nimport { useCx } from '../utils';\nimport { space } from '../utils/space';\n\nfunction UnforwardedToggleControl(\n\t{\n\t\t__nextHasNoMarginBottom,\n\t\tlabel,\n\t\tchecked,\n\t\thelp,\n\t\tclassName,\n\t\tonChange,\n\t\tdisabled,\n\t}: WordPressComponentProps< ToggleControlProps, 'input', false >,\n\tref: ForwardedRef< HTMLInputElement >\n) {\n\tfunction onChangeToggle( event: ChangeEvent< HTMLInputElement > ) {\n\t\tonChange( event.target.checked );\n\t}\n\tconst instanceId = useInstanceId( ToggleControl );\n\tconst id = `inspector-toggle-control-${ instanceId }`;\n\n\tconst cx = useCx();\n\tconst classes = cx(\n\t\t'components-toggle-control',\n\t\tclassName,\n\t\t! __nextHasNoMarginBottom && css( { marginBottom: space( 3 ) } )\n\t);\n\n\tlet describedBy, helpLabel;\n\tif ( help ) {\n\t\tif ( typeof help === 'function' ) {\n\t\t\t// `help` as a function works only for controlled components where\n\t\t\t// `checked` is passed down from parent component. Uncontrolled\n\t\t\t// component can show only a static help label.\n\t\t\tif ( checked !== undefined ) {\n\t\t\t\thelpLabel = help( checked );\n\t\t\t}\n\t\t} else {\n\t\t\thelpLabel = help;\n\t\t}\n\t\tif ( helpLabel ) {\n\t\t\tdescribedBy = id + '__help';\n\t\t}\n\t}\n\n\treturn (\n\t\t<BaseControl\n\t\t\tid={ id }\n\t\t\thelp={\n\t\t\t\thelpLabel && (\n\t\t\t\t\t<span className=\"components-toggle-control__help\">\n\t\t\t\t\t\t{ helpLabel }\n\t\t\t\t\t</span>\n\t\t\t\t)\n\t\t\t}\n\t\t\tclassName={ classes }\n\t\t\t__nextHasNoMarginBottom\n\t\t>\n\t\t\t<HStack justify=\"flex-start\" spacing={ 2 }>\n\t\t\t\t<FormToggle\n\t\t\t\t\tid={ id }\n\t\t\t\t\tchecked={ checked }\n\t\t\t\t\tonChange={ onChangeToggle }\n\t\t\t\t\taria-describedby={ describedBy }\n\t\t\t\t\tdisabled={ disabled }\n\t\t\t\t\tref={ ref }\n\t\t\t\t/>\n\t\t\t\t<FlexBlock\n\t\t\t\t\tas=\"label\"\n\t\t\t\t\thtmlFor={ id }\n\t\t\t\t\tclassName={ clsx( 'components-toggle-control__label', {\n\t\t\t\t\t\t'is-disabled': disabled,\n\t\t\t\t\t} ) }\n\t\t\t\t>\n\t\t\t\t\t{ label }\n\t\t\t\t</FlexBlock>\n\t\t\t</HStack>\n\t\t</BaseControl>\n\t);\n}\n\n/**\n * ToggleControl is used to generate a toggle user interface.\n *\n * ```jsx\n * import { ToggleControl } from '@wordpress/components';\n * import { useState } from '@wordpress/element';\n *\n * const MyToggleControl = () => {\n * const [ value, setValue ] = useState( false );\n *\n * return (\n * <ToggleControl\n * __nextHasNoMarginBottom\n * label=\"Fixed Background\"\n * checked={ value }\n * onChange={ () => setValue( ( state ) => ! state ) }\n * />\n * );\n * };\n * ```\n */\nexport const ToggleControl = forwardRef( UnforwardedToggleControl );\n\nexport default ToggleControl;\n"],"mappings":"AAAA;AACA;AACA;;AAEA,SAASA,GAAG,QAAQ,gBAAgB;AACpC,OAAOC,IAAI,MAAM,MAAM;;AAEvB;AACA;AACA;AACA,SAASC,UAAU,QAAQ,oBAAoB;AAC/C,SAASC,aAAa,QAAQ,oBAAoB;;AAElD;AACA;AACA;AACA,SAASC,SAAS,QAAQ,SAAS;AACnC,OAAOC,UAAU,MAAM,gBAAgB;AACvC,OAAOC,WAAW,MAAM,iBAAiB;AAGzC,SAASC,MAAM,QAAQ,YAAY;AACnC,SAASC,KAAK,QAAQ,UAAU;AAChC,SAASC,KAAK,QAAQ,gBAAgB;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAAA,SAAAC,IAAA,IAAAC,KAAA;AAEvC,SAASC,wBAAwBA,CAChC;EACCC,uBAAuB;EACvBC,KAAK;EACLC,OAAO;EACPC,IAAI;EACJC,SAAS;EACTC,QAAQ;EACRC;AAC8D,CAAC,EAChEC,GAAqC,EACpC;EACD,SAASC,cAAcA,CAAEC,KAAsC,EAAG;IACjEJ,QAAQ,CAAEI,KAAK,CAACC,MAAM,CAACR,OAAQ,CAAC;EACjC;EACA,MAAMS,UAAU,GAAGvB,aAAa,CAAEwB,aAAc,CAAC;EACjD,MAAMC,EAAE,GAAI,4BAA4BF,UAAY,EAAC;EAErD,MAAMG,EAAE,GAAGrB,KAAK,CAAC,CAAC;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rD,aAAa,EAAEoB;QAChB,CAAE,CAAG;QAAAiB,QAAA,EAEHtB;MAAK,CACG,CAAC;IAAA,CACL;EAAC,CACG,CAAC;AAEhB;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMW,aAAa,GAAGzB,UAAU,CAAEY,wBAAyB,CAAC;AAEnE,eAAea,aAAa","ignoreList":[]}
@@ -94,7 +94,12 @@ function UnconnectedToggleGroupControl(props, forwardedRef) {
94
94
  *
95
95
  * function Example() {
96
96
  * return (
97
- * <ToggleGroupControl label="my label" value="vertical" isBlock>
97
+ * <ToggleGroupControl
98
+ * label="my label"
99
+ * value="vertical"
100
+ * isBlock
101
+ * __nextHasNoMarginBottom
102
+ * >
98
103
  * <ToggleGroupControlOption value="horizontal" label="Horizontal" />
99
104
  * <ToggleGroupControlOption value="vertical" label="Vertical" />
100
105
  * </ToggleGroupControl>
@@ -1 +1 @@
1
- {"version":3,"names":["LayoutGroup","useInstanceId","useMemo","contextConnect","useContextSystem","useCx","BaseControl","VisualLabelWrapper","styles","ToggleGroupControlAsRadioGroup","ToggleGroupControlAsButtonGroup","jsx","_jsx","jsxs","_jsxs","UnconnectedToggleGroupControl","props","forwardedRef","__nextHasNoMarginBottom","__next40pxDefaultSize","className","isAdaptiveWidth","isBlock","isDeselectable","label","hideLabelFromVision","help","onChange","size","value","children","otherProps","baseId","ToggleGroupControl","normalizedSize","cx","classes","toggleGroupControl","block","MainControl","VisualLabel","ref","id"],"sources":["@wordpress/components/src/toggle-group-control/toggle-group-control/component.tsx"],"sourcesContent":["/**\n * External dependencies\n */\nimport type { ForwardedRef } from 'react';\nimport { LayoutGroup } from 'framer-motion';\n\n/**\n * WordPress dependencies\n */\nimport { useInstanceId } from '@wordpress/compose';\nimport { useMemo } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport type { WordPressComponentProps } from '../../context';\nimport { contextConnect, useContextSystem } from '../../context';\nimport { useCx } from '../../utils/hooks';\nimport BaseControl from '../../base-control';\nimport type { ToggleGroupControlProps } from '../types';\nimport { VisualLabelWrapper } from './styles';\nimport * as styles from './styles';\nimport { ToggleGroupControlAsRadioGroup } from './as-radio-group';\nimport { ToggleGroupControlAsButtonGroup } from './as-button-group';\n\nfunction UnconnectedToggleGroupControl(\n\tprops: WordPressComponentProps< ToggleGroupControlProps, 'div', false >,\n\tforwardedRef: ForwardedRef< any >\n) {\n\tconst {\n\t\t__nextHasNoMarginBottom = false,\n\t\t__next40pxDefaultSize = false,\n\t\tclassName,\n\t\tisAdaptiveWidth = false,\n\t\tisBlock = false,\n\t\tisDeselectable = false,\n\t\tlabel,\n\t\thideLabelFromVision = false,\n\t\thelp,\n\t\tonChange,\n\t\tsize = 'default',\n\t\tvalue,\n\t\tchildren,\n\t\t...otherProps\n\t} = useContextSystem( props, 'ToggleGroupControl' );\n\n\tconst baseId = useInstanceId( ToggleGroupControl, 'toggle-group-control' );\n\tconst normalizedSize =\n\t\t__next40pxDefaultSize && size === 'default' ? '__unstable-large' : size;\n\n\tconst cx = useCx();\n\n\tconst classes = useMemo(\n\t\t() =>\n\t\t\tcx(\n\t\t\t\tstyles.toggleGroupControl( {\n\t\t\t\t\tisBlock,\n\t\t\t\t\tisDeselectable,\n\t\t\t\t\tsize: normalizedSize,\n\t\t\t\t} ),\n\t\t\t\tisBlock && styles.block,\n\t\t\t\tclassName\n\t\t\t),\n\t\t[ className, cx, isBlock, isDeselectable, normalizedSize ]\n\t);\n\n\tconst MainControl = isDeselectable\n\t\t? ToggleGroupControlAsButtonGroup\n\t\t: ToggleGroupControlAsRadioGroup;\n\n\treturn (\n\t\t<BaseControl\n\t\t\thelp={ help }\n\t\t\t__nextHasNoMarginBottom={ __nextHasNoMarginBottom }\n\t\t>\n\t\t\t{ ! hideLabelFromVision && (\n\t\t\t\t<VisualLabelWrapper>\n\t\t\t\t\t<BaseControl.VisualLabel>{ label }</BaseControl.VisualLabel>\n\t\t\t\t</VisualLabelWrapper>\n\t\t\t) }\n\t\t\t<MainControl\n\t\t\t\t{ ...otherProps }\n\t\t\t\tclassName={ classes }\n\t\t\t\tisAdaptiveWidth={ isAdaptiveWidth }\n\t\t\t\tlabel={ label }\n\t\t\t\tonChange={ onChange }\n\t\t\t\tref={ forwardedRef }\n\t\t\t\tsize={ normalizedSize }\n\t\t\t\tvalue={ value }\n\t\t\t>\n\t\t\t\t<LayoutGroup id={ baseId }>{ children }</LayoutGroup>\n\t\t\t</MainControl>\n\t\t</BaseControl>\n\t);\n}\n\n/**\n * `ToggleGroupControl` is a form component that lets users choose options\n * represented in horizontal segments. To render options for this control use\n * `ToggleGroupControlOption` component.\n *\n * This component is intended for selecting a single persistent value from a set of options,\n * similar to a how a radio button group would work. If you simply want a toggle to switch between views,\n * use a `TabPanel` instead.\n *\n * Only use this control when you know for sure the labels of items inside won't\n * wrap. For items with longer labels, you can consider a `SelectControl` or a\n * `CustomSelectControl` component instead.\n *\n * ```jsx\n * import {\n * __experimentalToggleGroupControl as ToggleGroupControl,\n * __experimentalToggleGroupControlOption as ToggleGroupControlOption,\n * } from '@wordpress/components';\n *\n * function Example() {\n * return (\n * <ToggleGroupControl label=\"my label\" value=\"vertical\" isBlock>\n * <ToggleGroupControlOption value=\"horizontal\" label=\"Horizontal\" />\n * <ToggleGroupControlOption value=\"vertical\" label=\"Vertical\" />\n * </ToggleGroupControl>\n * );\n * }\n * ```\n */\nexport const ToggleGroupControl = contextConnect(\n\tUnconnectedToggleGroupControl,\n\t'ToggleGroupControl'\n);\n\nexport default ToggleGroupControl;\n"],"mappings":"AAAA;AACA;AACA;;AAEA,SAASA,WAAW,QAAQ,eAAe;;AAE3C;AACA;AACA;AACA,SAASC,aAAa,QAAQ,oBAAoB;AAClD,SAASC,OAAO,QAAQ,oBAAoB;;AAE5C;AACA;AACA;;AAEA,SAASC,cAAc,EAAEC,gBAAgB,QAAQ,eAAe;AAChE,SAASC,KAAK,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8B;EAEjC,oBACCK,KAAA,CAACR,WAAW;IACXoB,IAAI,EAAGA,IAAM;IACbR,uBAAuB,EAAGA,uBAAyB;IAAAY,QAAA,GAEjD,CAAEL,mBAAmB,iBACtBb,IAAA,CAACL,kBAAkB;MAAAuB,QAAA,eAClBlB,IAAA,CAACN,WAAW,CAACkC,WAAW;QAAAV,QAAA,EAAGN;MAAK,CAA2B;IAAC,CACzC,CACpB,eACDZ,IAAA,CAAC2B,WAAW;MAAA,GACNR,UAAU;MACfX,SAAS,EAAGgB,OAAS;MACrBf,eAAe,EAAGA,eAAiB;MACnCG,KAAK,EAAGA,KAAO;MACfG,QAAQ,EAAGA,QAAU;MACrBc,GAAG,EAAGxB,YAAc;MACpBW,IAAI,EAAGM,cAAgB;MACvBL,KAAK,EAAGA,KAAO;MAAAC,QAAA,eAEflB,IAAA,CAACZ,WAAW;QAAC0C,EAAE,EAAGV,MAAQ;QAAAF,QAAA,EAAGA;MAAQ,CAAe;IAAC,CACzC,CAAC;EAAA,CACF,CAAC;AAEhB;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMG,kBAAkB,GAAG9B,cAAc,CAC/CY,6BAA6B,EAC7B,oBACD,CAAC;AAED,eAAekB,kBAAkB","ignoreList":[]}
1
+ {"version":3,"names":["LayoutGroup","useInstanceId","useMemo","contextConnect","useContextSystem","useCx","BaseControl","VisualLabelWrapper","styles","ToggleGroupControlAsRadioGroup","ToggleGroupControlAsButtonGroup","jsx","_jsx","jsxs","_jsxs","UnconnectedToggleGroupControl","props","forwardedRef","__nextHasNoMarginBottom","__next40pxDefaultSize","className","isAdaptiveWidth","isBlock","isDeselectable","label","hideLabelFromVision","help","onChange","size","value","children","otherProps","baseId","ToggleGroupControl","normalizedSize","cx","classes","toggleGroupControl","block","MainControl","VisualLabel","ref","id"],"sources":["@wordpress/components/src/toggle-group-control/toggle-group-control/component.tsx"],"sourcesContent":["/**\n * External dependencies\n */\nimport type { ForwardedRef } from 'react';\nimport { LayoutGroup } from 'framer-motion';\n\n/**\n * WordPress dependencies\n */\nimport { useInstanceId } from '@wordpress/compose';\nimport { useMemo } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport type { WordPressComponentProps } from '../../context';\nimport { contextConnect, useContextSystem } from '../../context';\nimport { useCx } from '../../utils/hooks';\nimport BaseControl from '../../base-control';\nimport type { ToggleGroupControlProps } from '../types';\nimport { VisualLabelWrapper } from './styles';\nimport * as styles from './styles';\nimport { ToggleGroupControlAsRadioGroup } from './as-radio-group';\nimport { ToggleGroupControlAsButtonGroup } from './as-button-group';\n\nfunction UnconnectedToggleGroupControl(\n\tprops: WordPressComponentProps< ToggleGroupControlProps, 'div', false >,\n\tforwardedRef: ForwardedRef< any >\n) {\n\tconst {\n\t\t__nextHasNoMarginBottom = false,\n\t\t__next40pxDefaultSize = false,\n\t\tclassName,\n\t\tisAdaptiveWidth = false,\n\t\tisBlock = false,\n\t\tisDeselectable = false,\n\t\tlabel,\n\t\thideLabelFromVision = false,\n\t\thelp,\n\t\tonChange,\n\t\tsize = 'default',\n\t\tvalue,\n\t\tchildren,\n\t\t...otherProps\n\t} = useContextSystem( props, 'ToggleGroupControl' );\n\n\tconst baseId = useInstanceId( ToggleGroupControl, 'toggle-group-control' );\n\tconst normalizedSize =\n\t\t__next40pxDefaultSize && size === 'default' ? '__unstable-large' : size;\n\n\tconst cx = useCx();\n\n\tconst classes = useMemo(\n\t\t() =>\n\t\t\tcx(\n\t\t\t\tstyles.toggleGroupControl( {\n\t\t\t\t\tisBlock,\n\t\t\t\t\tisDeselectable,\n\t\t\t\t\tsize: normalizedSize,\n\t\t\t\t} ),\n\t\t\t\tisBlock && styles.block,\n\t\t\t\tclassName\n\t\t\t),\n\t\t[ className, cx, isBlock, isDeselectable, normalizedSize ]\n\t);\n\n\tconst MainControl = isDeselectable\n\t\t? ToggleGroupControlAsButtonGroup\n\t\t: ToggleGroupControlAsRadioGroup;\n\n\treturn (\n\t\t<BaseControl\n\t\t\thelp={ help }\n\t\t\t__nextHasNoMarginBottom={ __nextHasNoMarginBottom }\n\t\t>\n\t\t\t{ ! hideLabelFromVision && (\n\t\t\t\t<VisualLabelWrapper>\n\t\t\t\t\t<BaseControl.VisualLabel>{ label }</BaseControl.VisualLabel>\n\t\t\t\t</VisualLabelWrapper>\n\t\t\t) }\n\t\t\t<MainControl\n\t\t\t\t{ ...otherProps }\n\t\t\t\tclassName={ classes }\n\t\t\t\tisAdaptiveWidth={ isAdaptiveWidth }\n\t\t\t\tlabel={ label }\n\t\t\t\tonChange={ onChange }\n\t\t\t\tref={ forwardedRef }\n\t\t\t\tsize={ normalizedSize }\n\t\t\t\tvalue={ value }\n\t\t\t>\n\t\t\t\t<LayoutGroup id={ baseId }>{ children }</LayoutGroup>\n\t\t\t</MainControl>\n\t\t</BaseControl>\n\t);\n}\n\n/**\n * `ToggleGroupControl` is a form component that lets users choose options\n * represented in horizontal segments. To render options for this control use\n * `ToggleGroupControlOption` component.\n *\n * This component is intended for selecting a single persistent value from a set of options,\n * similar to a how a radio button group would work. If you simply want a toggle to switch between views,\n * use a `TabPanel` instead.\n *\n * Only use this control when you know for sure the labels of items inside won't\n * wrap. For items with longer labels, you can consider a `SelectControl` or a\n * `CustomSelectControl` component instead.\n *\n * ```jsx\n * import {\n * __experimentalToggleGroupControl as ToggleGroupControl,\n * __experimentalToggleGroupControlOption as ToggleGroupControlOption,\n * } from '@wordpress/components';\n *\n * function Example() {\n * return (\n * <ToggleGroupControl\n * label=\"my label\"\n * value=\"vertical\"\n * isBlock\n * __nextHasNoMarginBottom\n * >\n * <ToggleGroupControlOption value=\"horizontal\" label=\"Horizontal\" />\n * <ToggleGroupControlOption value=\"vertical\" label=\"Vertical\" />\n * </ToggleGroupControl>\n * );\n * }\n * ```\n */\nexport const ToggleGroupControl = contextConnect(\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nforwardedToggleGroupControlOption(props, ref) {
39
39
  *
40
40
  * function Example() {
41
41
  * return (
42
- * <ToggleGroupControl label="my label" value="vertical" isBlock>
42
+ * <ToggleGroupControl
43
+ * label="my label"
44
+ * value="vertical"
45
+ * isBlock
46
+ * __nextHasNoMarginBottom
47
+ * >
43
48
  * <ToggleGroupControlOption value="horizontal" label="Horizontal" />
44
49
  * <ToggleGroupControlOption value="vertical" label="Vertical" />
45
50
  * </ToggleGroupControl>
@@ -1 +1 @@
1
- {"version":3,"names":["forwardRef","ToggleGroupControlOptionBase","jsx","_jsx","UnforwardedToggleGroupControlOption","props","ref","label","restProps","optionLabel","children","ToggleGroupControlOption"],"sources":["@wordpress/components/src/toggle-group-control/toggle-group-control-option/component.tsx"],"sourcesContent":["/**\n * External dependencies\n */\nimport type { ForwardedRef } from 'react';\n\n/**\n * WordPress dependencies\n */\nimport { forwardRef } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport type { WordPressComponentProps } from '../../context';\nimport type { ToggleGroupControlOptionProps } from '../types';\nimport { ToggleGroupControlOptionBase } from '../toggle-group-control-option-base';\n\nfunction UnforwardedToggleGroupControlOption(\n\tprops: WordPressComponentProps<\n\t\tToggleGroupControlOptionProps,\n\t\t'button',\n\t\tfalse\n\t>,\n\tref: ForwardedRef< any >\n) {\n\tconst { label, ...restProps } = props;\n\tconst optionLabel = restProps[ 'aria-label' ] || label;\n\treturn (\n\t\t<ToggleGroupControlOptionBase\n\t\t\t{ ...restProps }\n\t\t\taria-label={ optionLabel }\n\t\t\tref={ ref }\n\t\t>\n\t\t\t{ label }\n\t\t</ToggleGroupControlOptionBase>\n\t);\n}\n\n/**\n * `ToggleGroupControlOption` is a form component and is meant to be used as a\n * child of `ToggleGroupControl`.\n *\n * ```jsx\n * import {\n * __experimentalToggleGroupControl as ToggleGroupControl,\n * __experimentalToggleGroupControlOption as ToggleGroupControlOption,\n * } from '@wordpress/components';\n *\n * function Example() {\n * return (\n * <ToggleGroupControl label=\"my label\" value=\"vertical\" isBlock>\n * <ToggleGroupControlOption value=\"horizontal\" label=\"Horizontal\" />\n * <ToggleGroupControlOption value=\"vertical\" label=\"Vertical\" />\n * </ToggleGroupControl>\n * );\n * }\n * ```\n */\nexport const ToggleGroupControlOption = forwardRef(\n\tUnforwardedToggleGroupControlOption\n);\n\nexport default ToggleGroupControlOption;\n"],"mappings":"AAAA;AACA;AACA;;AAGA;AACA;AACA;AACA,SAASA,UAAU,QAAQ,oBAAoB;;AAE/C;AACA;AACA;;AAGA,SAASC,4BAA4B,QAAQ,qCAAqC;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAEnF,SAASC,mCAAmCA,CAC3CC,KAIC,EACDC,GAAwB,EACvB;EACD,MAAM;IAAEC,KAAK;IAAE,GAAGC;EAAU,CAAC,GAAGH,KAAK;EACrC,MAAMI,WAAW,GAAGD,SAAS,CAAE,YAAY,CAAE,IAAID,KAAK;EACtD,oBACCJ,IAAA,CAACF,4BAA4B;IAAA,GACvBO,SAAS;IACd,cAAaC,WAAa;IAC1BH,GAAG,EAAGA,GAAK;IAAAI,QAAA,EAETH;EAAK,CACsB,CAAC;AAEjC;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMI,wBAAwB,GAAGX,UAAU,CACjDI,mCACD,CAAC;AAED,eAAeO,wBAAwB","ignoreList":[]}
1
+ {"version":3,"names":["forwardRef","ToggleGroupControlOptionBase","jsx","_jsx","UnforwardedToggleGroupControlOption","props","ref","label","restProps","optionLabel","children","ToggleGroupControlOption"],"sources":["@wordpress/components/src/toggle-group-control/toggle-group-control-option/component.tsx"],"sourcesContent":["/**\n * External dependencies\n */\nimport type { ForwardedRef } from 'react';\n\n/**\n * WordPress dependencies\n */\nimport { forwardRef } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport type { WordPressComponentProps } from '../../context';\nimport type { ToggleGroupControlOptionProps } from '../types';\nimport { ToggleGroupControlOptionBase } from '../toggle-group-control-option-base';\n\nfunction UnforwardedToggleGroupControlOption(\n\tprops: WordPressComponentProps<\n\t\tToggleGroupControlOptionProps,\n\t\t'button',\n\t\tfalse\n\t>,\n\tref: ForwardedRef< any >\n) {\n\tconst { label, ...restProps } = props;\n\tconst optionLabel = restProps[ 'aria-label' ] || label;\n\treturn (\n\t\t<ToggleGroupControlOptionBase\n\t\t\t{ ...restProps }\n\t\t\taria-label={ optionLabel }\n\t\t\tref={ ref }\n\t\t>\n\t\t\t{ label }\n\t\t</ToggleGroupControlOptionBase>\n\t);\n}\n\n/**\n * `ToggleGroupControlOption` is a form component and is meant to be used as a\n * child of `ToggleGroupControl`.\n *\n * ```jsx\n * import {\n * __experimentalToggleGroupControl as ToggleGroupControl,\n * __experimentalToggleGroupControlOption as ToggleGroupControlOption,\n * } from '@wordpress/components';\n *\n * function Example() {\n * return (\n * <ToggleGroupControl\n * label=\"my label\"\n * value=\"vertical\"\n * isBlock\n * __nextHasNoMarginBottom\n * >\n * <ToggleGroupControlOption value=\"horizontal\" label=\"Horizontal\" />\n * <ToggleGroupControlOption value=\"vertical\" label=\"Vertical\" />\n * </ToggleGroupControl>\n * );\n * }\n * ```\n */\nexport const ToggleGroupControlOption = forwardRef(\n\tUnforwardedToggleGroupControlOption\n);\n\nexport default ToggleGroupControlOption;\n"],"mappings":"AAAA;AACA;AACA;;AAGA;AACA;AACA;AACA,SAASA,UAAU,QAAQ,oBAAoB;;AAE/C;AACA;AACA;;AAGA,SAASC,4BAA4B,QAAQ,qCAAqC;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAEnF,SAASC,mCAAmCA,CAC3CC,KAIC,EACDC,GAAwB,EACvB;EACD,MAAM;IAAEC,KAAK;IAAE,GAAGC;EAAU,CAAC,GAAGH,KAAK;EACrC,MAAMI,WAAW,GAAGD,SAAS,CAAE,YAAY,CAAE,IAAID,KAAK;EACtD,oBACCJ,IAAA,CAACF,4BAA4B;IAAA,GACvBO,SAAS;IACd,cAAaC,WAAa;IAC1BH,GAAG,EAAGA,GAAK;IAAAI,QAAA,EAETH;EAAK,CACsB,CAAC;AAEjC;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMI,wBAAwB,GAAGX,UAAU,CACjDI,mCACD,CAAC;AAED,eAAeO,wBAAwB","ignoreList":[]}
@@ -67,6 +67,7 @@ function ToggleGroupControlOptionBase(props, forwardedRef) {
67
67
  children,
68
68
  showTooltip = false,
69
69
  onFocus: onFocusProp,
70
+ disabled,
70
71
  ...otherButtonProps
71
72
  } = buttonProps;
72
73
  const isPressed = toggleGroupControlContext.value === value;
@@ -99,6 +100,7 @@ function ToggleGroupControlOptionBase(props, forwardedRef) {
99
100
  text: otherButtonProps['aria-label'],
100
101
  children: isDeselectable ? /*#__PURE__*/_jsx("button", {
101
102
  ...commonProps,
103
+ disabled: disabled,
102
104
  onFocus: onFocusProp,
103
105
  "aria-pressed": isPressed,
104
106
  type: "button",
@@ -107,6 +109,7 @@ function ToggleGroupControlOptionBase(props, forwardedRef) {
107
109
  children: children
108
110
  })
109
111
  }) : /*#__PURE__*/_jsx(Ariakit.Radio, {
112
+ disabled: disabled,
110
113
  render: /*#__PURE__*/_jsx("button", {
111
114
  type: "button",
112
115
  ...commonProps,