@wordpress/components 19.10.0 → 19.13.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 (1279) hide show
  1. package/CHANGELOG.md +97 -6
  2. package/CONTRIBUTING.md +94 -12
  3. package/README.md +1 -1
  4. package/build/alignment-matrix-control/index.js +8 -5
  5. package/build/alignment-matrix-control/index.js.map +1 -1
  6. package/build/angle-picker-control/index.js +2 -2
  7. package/build/angle-picker-control/index.js.map +1 -1
  8. package/build/autocomplete/autocompleter-ui.js +1 -1
  9. package/build/autocomplete/autocompleter-ui.js.map +1 -1
  10. package/build/autocomplete/autocompleter-ui.native.js +2 -2
  11. package/build/autocomplete/autocompleter-ui.native.js.map +1 -1
  12. package/build/autocomplete/index.js +12 -10
  13. package/build/autocomplete/index.js.map +1 -1
  14. package/build/border-box-control/border-box-control/component.js +22 -7
  15. package/build/border-box-control/border-box-control/component.js.map +1 -1
  16. package/build/border-box-control/border-box-control/hook.js +2 -2
  17. package/build/border-box-control/border-box-control/hook.js.map +1 -1
  18. package/build/border-box-control/border-box-control-linked-button/component.js.map +1 -1
  19. package/build/border-box-control/border-box-control-linked-button/hook.js +3 -2
  20. package/build/border-box-control/border-box-control-linked-button/hook.js.map +1 -1
  21. package/build/border-box-control/border-box-control-split-controls/component.js +23 -8
  22. package/build/border-box-control/border-box-control-split-controls/component.js.map +1 -1
  23. package/build/border-box-control/border-box-control-split-controls/hook.js +13 -4
  24. package/build/border-box-control/border-box-control-split-controls/hook.js.map +1 -1
  25. package/build/border-box-control/border-box-control-visualizer/hook.js +7 -2
  26. package/build/border-box-control/border-box-control-visualizer/hook.js.map +1 -1
  27. package/build/border-box-control/styles.js +25 -19
  28. package/build/border-box-control/styles.js.map +1 -1
  29. package/build/border-box-control/utils.js.map +1 -1
  30. package/build/border-control/border-control/component.js +5 -3
  31. package/build/border-control/border-control/component.js.map +1 -1
  32. package/build/border-control/border-control/hook.js +8 -5
  33. package/build/border-control/border-control/hook.js.map +1 -1
  34. package/build/border-control/border-control-dropdown/component.js +6 -2
  35. package/build/border-control/border-control-dropdown/component.js.map +1 -1
  36. package/build/border-control/border-control-dropdown/hook.js +5 -5
  37. package/build/border-control/border-control-dropdown/hook.js.map +1 -1
  38. package/build/border-control/styles.js +58 -29
  39. package/build/border-control/styles.js.map +1 -1
  40. package/build/box-control/all-input-control.js +6 -10
  41. package/build/box-control/all-input-control.js.map +1 -1
  42. package/build/box-control/axial-input-controls.js.map +1 -1
  43. package/build/box-control/index.js +3 -7
  44. package/build/box-control/index.js.map +1 -1
  45. package/build/box-control/input-controls.js +6 -10
  46. package/build/box-control/input-controls.js.map +1 -1
  47. package/build/box-control/unit-control.js +4 -4
  48. package/build/box-control/unit-control.js.map +1 -1
  49. package/build/button/index.native.js +16 -4
  50. package/build/button/index.native.js.map +1 -1
  51. package/build/button-group/index.js +24 -7
  52. package/build/button-group/index.js.map +1 -1
  53. package/build/{flyout → button-group}/types.js +0 -0
  54. package/build/button-group/types.js.map +1 -0
  55. package/build/checkbox-control/index.js +34 -7
  56. package/build/checkbox-control/index.js.map +1 -1
  57. package/build/checkbox-control/types.js +6 -0
  58. package/build/checkbox-control/types.js.map +1 -0
  59. package/build/color-palette/index.js +14 -14
  60. package/build/color-palette/index.js.map +1 -1
  61. package/build/color-palette/index.native.js +4 -1
  62. package/build/color-palette/index.native.js.map +1 -1
  63. package/build/color-picker/color-copy-button.js +87 -0
  64. package/build/color-picker/color-copy-button.js.map +1 -0
  65. package/build/color-picker/component.js +5 -15
  66. package/build/color-picker/component.js.map +1 -1
  67. package/build/color-picker/hex-input.js +18 -1
  68. package/build/color-picker/hex-input.js.map +1 -1
  69. package/build/color-picker/index.native.js.map +1 -1
  70. package/build/color-picker/styles.js +11 -11
  71. package/build/color-picker/styles.js.map +1 -1
  72. package/build/combobox-control/index.js +4 -2
  73. package/build/combobox-control/index.js.map +1 -1
  74. package/build/confirm-dialog/component.js.map +1 -1
  75. package/build/custom-gradient-bar/constants.js +1 -3
  76. package/build/custom-gradient-bar/constants.js.map +1 -1
  77. package/build/custom-gradient-bar/control-points.js +15 -8
  78. package/build/custom-gradient-bar/control-points.js.map +1 -1
  79. package/build/custom-gradient-bar/index.js +5 -5
  80. package/build/custom-gradient-bar/index.js.map +1 -1
  81. package/build/custom-gradient-bar/utils.js +5 -7
  82. package/build/custom-gradient-bar/utils.js.map +1 -1
  83. package/build/custom-gradient-picker/utils.js +1 -1
  84. package/build/custom-gradient-picker/utils.js.map +1 -1
  85. package/build/custom-select-control/index.js.map +1 -1
  86. package/build/date-time/{date.js → date/index.js} +84 -21
  87. package/build/date-time/date/index.js.map +1 -0
  88. package/build/date-time/date/styles.js +70 -0
  89. package/build/date-time/date/styles.js.map +1 -0
  90. package/build/date-time/{utils.js → date/utils.js} +6 -4
  91. package/build/date-time/date/utils.js.map +1 -0
  92. package/build/date-time/date-time/index.js +175 -0
  93. package/build/date-time/date-time/index.js.map +1 -0
  94. package/build/date-time/date-time/styles.js +32 -0
  95. package/build/date-time/date-time/styles.js.map +1 -0
  96. package/build/date-time/index.js +2 -84
  97. package/build/date-time/index.js.map +1 -1
  98. package/build/date-time/time/index.js +322 -0
  99. package/build/date-time/time/index.js.map +1 -0
  100. package/build/date-time/time/styles.js +139 -0
  101. package/build/date-time/time/styles.js.map +1 -0
  102. package/build/date-time/{timezone.js → time/timezone.js} +8 -5
  103. package/build/date-time/time/timezone.js.map +1 -0
  104. package/build/date-time/types.js +6 -0
  105. package/build/date-time/types.js.map +1 -0
  106. package/build/dimension-control/index.js +1 -3
  107. package/build/dimension-control/index.js.map +1 -1
  108. package/build/disabled/index.js +1 -1
  109. package/build/disabled/index.js.map +1 -1
  110. package/build/divider/styles.js +5 -5
  111. package/build/divider/styles.js.map +1 -1
  112. package/build/draggable/index.js.map +1 -1
  113. package/build/draggable/index.native.js +233 -0
  114. package/build/draggable/index.native.js.map +1 -0
  115. package/build/drop-zone/provider.js.map +1 -1
  116. package/build/dropdown/index.js +11 -6
  117. package/build/dropdown/index.js.map +1 -1
  118. package/build/dropdown-menu/index.js +13 -2
  119. package/build/dropdown-menu/index.js.map +1 -1
  120. package/build/dropdown-menu/index.native.js +13 -2
  121. package/build/dropdown-menu/index.native.js.map +1 -1
  122. package/build/external-link/index.js +20 -8
  123. package/build/external-link/index.js.map +1 -1
  124. package/build/external-link/styles/external-link-styles.js +3 -3
  125. package/build/external-link/styles/external-link-styles.js.map +1 -1
  126. package/build/external-link/types.js +6 -0
  127. package/build/external-link/types.js.map +1 -0
  128. package/build/flex/flex/hook.js +9 -5
  129. package/build/flex/flex/hook.js.map +1 -1
  130. package/build/focal-point-picker/controls.js +3 -7
  131. package/build/focal-point-picker/controls.js.map +1 -1
  132. package/build/focal-point-picker/index.js.map +1 -1
  133. package/build/focal-point-picker/index.native.js +3 -3
  134. package/build/focal-point-picker/index.native.js.map +1 -1
  135. package/build/focal-point-picker/media.js +4 -8
  136. package/build/focal-point-picker/media.js.map +1 -1
  137. package/build/font-size-picker/index.js +1 -1
  138. package/build/font-size-picker/index.js.map +1 -1
  139. package/build/form-toggle/index.js +6 -4
  140. package/build/form-toggle/index.js.map +1 -1
  141. package/build/form-token-field/index.js +328 -359
  142. package/build/form-token-field/index.js.map +1 -1
  143. package/build/form-token-field/suggestions-list.js +26 -20
  144. package/build/form-token-field/suggestions-list.js.map +1 -1
  145. package/build/form-token-field/token-input.js +39 -53
  146. package/build/form-token-field/token-input.js.map +1 -1
  147. package/build/form-token-field/token.js +3 -3
  148. package/build/form-token-field/token.js.map +1 -1
  149. package/build/form-token-field/types.js +6 -0
  150. package/build/form-token-field/types.js.map +1 -0
  151. package/build/gradient-picker/index.js.map +1 -1
  152. package/build/heading/hook.js.map +1 -1
  153. package/build/higher-order/navigate-regions/index.js.map +1 -1
  154. package/build/higher-order/with-focus-return/index.js.map +1 -1
  155. package/build/higher-order/with-spoken-messages/index.js.map +1 -1
  156. package/build/icon/index.js.map +1 -1
  157. package/build/index.js +0 -8
  158. package/build/index.js.map +1 -1
  159. package/build/index.native.js +16 -0
  160. package/build/index.native.js.map +1 -1
  161. package/build/input-control/index.js +14 -9
  162. package/build/input-control/index.js.map +1 -1
  163. package/build/input-control/input-field.js +11 -36
  164. package/build/input-control/input-field.js.map +1 -1
  165. package/build/input-control/reducer/reducer.js +36 -24
  166. package/build/input-control/reducer/reducer.js.map +1 -1
  167. package/build/input-control/reducer/state.js +0 -1
  168. package/build/input-control/reducer/state.js.map +1 -1
  169. package/build/input-control/utils.js +46 -1
  170. package/build/input-control/utils.js.map +1 -1
  171. package/build/menu-items-choice/index.js +3 -7
  172. package/build/menu-items-choice/index.js.map +1 -1
  173. package/build/mobile/bottom-sheet/bottom-sheet-context.native.js.map +1 -1
  174. package/build/mobile/bottom-sheet/bottom-sheet-navigation/navigation-screen.native.js +1 -1
  175. package/build/mobile/bottom-sheet/bottom-sheet-navigation/navigation-screen.native.js.map +1 -1
  176. package/build/mobile/bottom-sheet/cell.native.js.map +1 -1
  177. package/build/mobile/bottom-sheet/cycle-picker-cell.native.js +1 -7
  178. package/build/mobile/bottom-sheet/cycle-picker-cell.native.js.map +1 -1
  179. package/build/mobile/bottom-sheet/index.native.js +1 -1
  180. package/build/mobile/bottom-sheet/index.native.js.map +1 -1
  181. package/build/mobile/bottom-sheet/picker-cell.native.js.map +1 -1
  182. package/build/mobile/bottom-sheet/stepper-cell/index.native.js.map +1 -1
  183. package/build/mobile/bottom-sheet-select-control/index.native.js +3 -2
  184. package/build/mobile/bottom-sheet-select-control/index.native.js.map +1 -1
  185. package/build/mobile/color-settings/index.native.js.map +1 -1
  186. package/build/mobile/global-styles-context/index.native.js.map +1 -1
  187. package/build/mobile/gradient/index.native.js.map +1 -1
  188. package/build/mobile/html-text-input/index.native.js +19 -8
  189. package/build/mobile/html-text-input/index.native.js.map +1 -1
  190. package/build/mobile/inserter-button/index.native.js.map +1 -1
  191. package/build/mobile/keyboard-aware-flat-list/index.android.js +28 -5
  192. package/build/mobile/keyboard-aware-flat-list/index.android.js.map +1 -1
  193. package/build/mobile/keyboard-aware-flat-list/index.ios.js +47 -24
  194. package/build/mobile/keyboard-aware-flat-list/index.ios.js.map +1 -1
  195. package/build/mobile/link-settings/image-link-destinations-screen.native.js.map +1 -1
  196. package/build/mobile/media-edit/index.native.js.map +1 -1
  197. package/build/mobile/segmented-control/index.native.js +1 -1
  198. package/build/mobile/segmented-control/index.native.js.map +1 -1
  199. package/build/modal/index.js +1 -1
  200. package/build/modal/index.js.map +1 -1
  201. package/build/navigable-container/container.js +4 -2
  202. package/build/navigable-container/container.js.map +1 -1
  203. package/build/navigation/context.js +12 -16
  204. package/build/navigation/context.js.map +1 -1
  205. package/build/navigation/index.js +3 -3
  206. package/build/navigation/index.js.map +1 -1
  207. package/build/navigation/item/index.js +3 -3
  208. package/build/navigation/item/index.js.map +1 -1
  209. package/build/navigator/navigator-back-button/hook.js.map +1 -1
  210. package/build/navigator/navigator-button/hook.js.map +1 -1
  211. package/build/navigator/navigator-provider/component.js +1 -1
  212. package/build/navigator/navigator-provider/component.js.map +1 -1
  213. package/build/navigator/navigator-screen/component.js +1 -1
  214. package/build/navigator/navigator-screen/component.js.map +1 -1
  215. package/build/notice/index.js +5 -5
  216. package/build/notice/index.js.map +1 -1
  217. package/build/notice/list.js +4 -2
  218. package/build/notice/list.js.map +1 -1
  219. package/build/palette-edit/index.js +38 -7
  220. package/build/palette-edit/index.js.map +1 -1
  221. package/build/panel/body.js +3 -3
  222. package/build/panel/body.js.map +1 -1
  223. package/build/placeholder/index.js +26 -12
  224. package/build/placeholder/index.js.map +1 -1
  225. package/build/popover/index.js +228 -275
  226. package/build/popover/index.js.map +1 -1
  227. package/build/radio-control/index.js +43 -7
  228. package/build/radio-control/index.js.map +1 -1
  229. package/build/radio-control/types.js +6 -0
  230. package/build/radio-control/types.js.map +1 -0
  231. package/build/range-control/index.js +8 -6
  232. package/build/range-control/index.js.map +1 -1
  233. package/build/range-control/input-range.js +6 -10
  234. package/build/range-control/input-range.js.map +1 -1
  235. package/build/range-control/utils.js +7 -5
  236. package/build/range-control/utils.js.map +1 -1
  237. package/build/resizable-box/resize-tooltip/index.js +3 -3
  238. package/build/resizable-box/resize-tooltip/index.js.map +1 -1
  239. package/build/resizable-box/resize-tooltip/utils.js +8 -14
  240. package/build/resizable-box/resize-tooltip/utils.js.map +1 -1
  241. package/build/responsive-wrapper/index.js.map +1 -1
  242. package/build/sandbox/index.native.js +1 -1
  243. package/build/sandbox/index.native.js.map +1 -1
  244. package/build/search-control/index.js +4 -6
  245. package/build/search-control/index.js.map +1 -1
  246. package/build/select-control/index.js +8 -4
  247. package/build/select-control/index.js.map +1 -1
  248. package/build/select-control/styles/select-control-styles.js +14 -11
  249. package/build/select-control/styles/select-control-styles.js.map +1 -1
  250. package/build/slot-fill/fill.js +1 -7
  251. package/build/slot-fill/fill.js.map +1 -1
  252. package/build/slot-fill/slot.js +14 -3
  253. package/build/slot-fill/slot.js.map +1 -1
  254. package/build/snackbar/index.js +7 -7
  255. package/build/snackbar/index.js.map +1 -1
  256. package/build/snackbar/list.js +3 -1
  257. package/build/snackbar/list.js.map +1 -1
  258. package/build/spacer/hook.js +11 -3
  259. package/build/spacer/hook.js.map +1 -1
  260. package/build/surface/component.js +7 -7
  261. package/build/surface/component.js.map +1 -1
  262. package/build/surface/hook.js +8 -11
  263. package/build/surface/hook.js.map +1 -1
  264. package/build/surface/index.js.map +1 -1
  265. package/build/surface/styles.js +8 -48
  266. package/build/surface/styles.js.map +1 -1
  267. package/build/tab-panel/index.js +3 -1
  268. package/build/tab-panel/index.js.map +1 -1
  269. package/build/text/hook.js +4 -4
  270. package/build/text/hook.js.map +1 -1
  271. package/build/text/utils.js.map +1 -1
  272. package/build/textarea-control/index.js +40 -6
  273. package/build/textarea-control/index.js.map +1 -1
  274. package/build/textarea-control/styles/textarea-control-styles.js +3 -3
  275. package/build/textarea-control/styles/textarea-control-styles.js.map +1 -1
  276. package/build/textarea-control/types.js +6 -0
  277. package/build/textarea-control/types.js.map +1 -0
  278. package/build/toggle-control/index.js +1 -3
  279. package/build/toggle-control/index.js.map +1 -1
  280. package/build/toggle-control/index.native.js +1 -7
  281. package/build/toggle-control/index.native.js.map +1 -1
  282. package/build/toggle-group-control/toggle-group-control/component.js +1 -3
  283. package/build/toggle-group-control/toggle-group-control/component.js.map +1 -1
  284. package/build/toggle-group-control/toggle-group-control/toggle-group-control-backdrop.js.map +1 -1
  285. package/build/toolbar/index.js.map +1 -1
  286. package/build/tools-panel/tools-panel/hook.js.map +1 -1
  287. package/build/tools-panel/tools-panel-header/hook.js.map +1 -1
  288. package/build/tooltip/index.js +3 -2
  289. package/build/tooltip/index.js.map +1 -1
  290. package/build/tree-grid/roving-tab-index-item.js.map +1 -1
  291. package/build/tree-select/index.js +57 -4
  292. package/build/tree-select/index.js.map +1 -1
  293. package/build/tree-select/types.js +6 -0
  294. package/build/tree-select/types.js.map +1 -0
  295. package/build/ui/form-group/form-group-content.js.map +1 -1
  296. package/build/unit-control/index.js.map +1 -1
  297. package/build/utils/hooks/index.js +0 -8
  298. package/build/utils/hooks/index.js.map +1 -1
  299. package/build/utils/unit-values.js.map +1 -1
  300. package/build/utils/values.js.map +1 -1
  301. package/build/z-stack/component.js +22 -3
  302. package/build/z-stack/component.js.map +1 -1
  303. package/build/z-stack/types.js +6 -0
  304. package/build/z-stack/types.js.map +1 -0
  305. package/build-module/alignment-matrix-control/index.js +7 -3
  306. package/build-module/alignment-matrix-control/index.js.map +1 -1
  307. package/build-module/angle-picker-control/index.js +1 -1
  308. package/build-module/angle-picker-control/index.js.map +1 -1
  309. package/build-module/autocomplete/autocompleter-ui.js +1 -1
  310. package/build-module/autocomplete/autocompleter-ui.js.map +1 -1
  311. package/build-module/autocomplete/autocompleter-ui.native.js +2 -2
  312. package/build-module/autocomplete/autocompleter-ui.native.js.map +1 -1
  313. package/build-module/autocomplete/index.js +13 -11
  314. package/build-module/autocomplete/index.js.map +1 -1
  315. package/build-module/border-box-control/border-box-control/component.js +22 -7
  316. package/build-module/border-box-control/border-box-control/component.js.map +1 -1
  317. package/build-module/border-box-control/border-box-control/hook.js +2 -2
  318. package/build-module/border-box-control/border-box-control/hook.js.map +1 -1
  319. package/build-module/border-box-control/border-box-control-linked-button/component.js.map +1 -1
  320. package/build-module/border-box-control/border-box-control-linked-button/hook.js +3 -2
  321. package/build-module/border-box-control/border-box-control-linked-button/hook.js.map +1 -1
  322. package/build-module/border-box-control/border-box-control-split-controls/component.js +23 -8
  323. package/build-module/border-box-control/border-box-control-split-controls/component.js.map +1 -1
  324. package/build-module/border-box-control/border-box-control-split-controls/hook.js +11 -4
  325. package/build-module/border-box-control/border-box-control-split-controls/hook.js.map +1 -1
  326. package/build-module/border-box-control/border-box-control-visualizer/hook.js +5 -2
  327. package/build-module/border-box-control/border-box-control-visualizer/hook.js.map +1 -1
  328. package/build-module/border-box-control/styles.js +15 -16
  329. package/build-module/border-box-control/styles.js.map +1 -1
  330. package/build-module/border-box-control/utils.js.map +1 -1
  331. package/build-module/border-control/border-control/component.js +5 -3
  332. package/build-module/border-control/border-control/component.js.map +1 -1
  333. package/build-module/border-control/border-control/hook.js +8 -5
  334. package/build-module/border-control/border-control/hook.js.map +1 -1
  335. package/build-module/border-control/border-control-dropdown/component.js +6 -2
  336. package/build-module/border-control/border-control-dropdown/component.js.map +1 -1
  337. package/build-module/border-control/border-control-dropdown/hook.js +5 -5
  338. package/build-module/border-control/border-control-dropdown/hook.js.map +1 -1
  339. package/build-module/border-control/styles.js +56 -29
  340. package/build-module/border-control/styles.js.map +1 -1
  341. package/build-module/box-control/all-input-control.js +3 -5
  342. package/build-module/box-control/all-input-control.js.map +1 -1
  343. package/build-module/box-control/axial-input-controls.js.map +1 -1
  344. package/build-module/box-control/index.js +2 -5
  345. package/build-module/box-control/index.js.map +1 -1
  346. package/build-module/box-control/input-controls.js +3 -5
  347. package/build-module/box-control/input-controls.js.map +1 -1
  348. package/build-module/box-control/unit-control.js +3 -1
  349. package/build-module/box-control/unit-control.js.map +1 -1
  350. package/build-module/button/index.native.js +17 -5
  351. package/build-module/button/index.native.js.map +1 -1
  352. package/build-module/button-group/index.js +27 -7
  353. package/build-module/button-group/index.js.map +1 -1
  354. package/build-module/{flyout → button-group}/types.js +0 -0
  355. package/build-module/{flyout → button-group}/types.js.map +0 -0
  356. package/build-module/checkbox-control/index.js +31 -7
  357. package/build-module/checkbox-control/index.js.map +1 -1
  358. package/build-module/checkbox-control/types.js +2 -0
  359. package/{build/flyout → build-module/checkbox-control}/types.js.map +0 -0
  360. package/build-module/color-palette/index.js +12 -16
  361. package/build-module/color-palette/index.js.map +1 -1
  362. package/build-module/color-palette/index.native.js +4 -1
  363. package/build-module/color-palette/index.native.js.map +1 -1
  364. package/build-module/color-picker/color-copy-button.js +73 -0
  365. package/build-module/color-picker/color-copy-button.js.map +1 -0
  366. package/build-module/color-picker/component.js +6 -15
  367. package/build-module/color-picker/component.js.map +1 -1
  368. package/build-module/color-picker/hex-input.js +18 -1
  369. package/build-module/color-picker/hex-input.js.map +1 -1
  370. package/build-module/color-picker/index.native.js.map +1 -1
  371. package/build-module/color-picker/styles.js +9 -9
  372. package/build-module/color-picker/styles.js.map +1 -1
  373. package/build-module/combobox-control/index.js +5 -2
  374. package/build-module/combobox-control/index.js.map +1 -1
  375. package/build-module/confirm-dialog/component.js.map +1 -1
  376. package/build-module/custom-gradient-bar/constants.js +0 -1
  377. package/build-module/custom-gradient-bar/constants.js.map +1 -1
  378. package/build-module/custom-gradient-bar/control-points.js +16 -9
  379. package/build-module/custom-gradient-bar/control-points.js.map +1 -1
  380. package/build-module/custom-gradient-bar/index.js +6 -6
  381. package/build-module/custom-gradient-bar/index.js.map +1 -1
  382. package/build-module/custom-gradient-bar/utils.js +6 -8
  383. package/build-module/custom-gradient-bar/utils.js.map +1 -1
  384. package/build-module/custom-gradient-picker/utils.js +1 -1
  385. package/build-module/custom-gradient-picker/utils.js.map +1 -1
  386. package/build-module/custom-select-control/index.js.map +1 -1
  387. package/build-module/date-time/{date.js → date/index.js} +81 -23
  388. package/build-module/date-time/date/index.js.map +1 -0
  389. package/build-module/date-time/date/styles.js +61 -0
  390. package/build-module/date-time/date/styles.js.map +1 -0
  391. package/build-module/date-time/date/utils.js +22 -0
  392. package/build-module/date-time/date/utils.js.map +1 -0
  393. package/build-module/date-time/date-time/index.js +145 -0
  394. package/build-module/date-time/date-time/index.js.map +1 -0
  395. package/build-module/date-time/date-time/styles.js +22 -0
  396. package/build-module/date-time/date-time/styles.js.map +1 -0
  397. package/build-module/date-time/index.js +2 -82
  398. package/build-module/date-time/index.js.map +1 -1
  399. package/build-module/date-time/time/index.js +302 -0
  400. package/build-module/date-time/time/index.js.map +1 -0
  401. package/build-module/date-time/time/styles.js +118 -0
  402. package/build-module/date-time/time/styles.js.map +1 -0
  403. package/build-module/date-time/{timezone.js → time/timezone.js} +7 -5
  404. package/build-module/date-time/time/timezone.js.map +1 -0
  405. package/build-module/date-time/types.js +2 -0
  406. package/build-module/date-time/types.js.map +1 -0
  407. package/build-module/dimension-control/index.js +1 -2
  408. package/build-module/dimension-control/index.js.map +1 -1
  409. package/build-module/disabled/index.js +1 -1
  410. package/build-module/disabled/index.js.map +1 -1
  411. package/build-module/divider/styles.js +5 -5
  412. package/build-module/divider/styles.js.map +1 -1
  413. package/build-module/draggable/index.js.map +1 -1
  414. package/build-module/draggable/index.native.js +216 -0
  415. package/build-module/draggable/index.native.js.map +1 -0
  416. package/build-module/drop-zone/provider.js.map +1 -1
  417. package/build-module/dropdown/index.js +11 -6
  418. package/build-module/dropdown/index.js.map +1 -1
  419. package/build-module/dropdown-menu/index.js +12 -1
  420. package/build-module/dropdown-menu/index.js.map +1 -1
  421. package/build-module/dropdown-menu/index.native.js +12 -1
  422. package/build-module/dropdown-menu/index.native.js.map +1 -1
  423. package/build-module/external-link/index.js +22 -7
  424. package/build-module/external-link/index.js.map +1 -1
  425. package/build-module/external-link/styles/external-link-styles.js +3 -3
  426. package/build-module/external-link/styles/external-link-styles.js.map +1 -1
  427. package/build-module/external-link/types.js +2 -0
  428. package/build-module/external-link/types.js.map +1 -0
  429. package/build-module/flex/flex/hook.js +7 -5
  430. package/build-module/flex/flex/hook.js.map +1 -1
  431. package/build-module/focal-point-picker/controls.js +3 -5
  432. package/build-module/focal-point-picker/controls.js.map +1 -1
  433. package/build-module/focal-point-picker/index.js.map +1 -1
  434. package/build-module/focal-point-picker/index.native.js +3 -3
  435. package/build-module/focal-point-picker/index.native.js.map +1 -1
  436. package/build-module/focal-point-picker/media.js +3 -5
  437. package/build-module/focal-point-picker/media.js.map +1 -1
  438. package/build-module/font-size-picker/index.js +1 -1
  439. package/build-module/font-size-picker/index.js.map +1 -1
  440. package/build-module/form-toggle/index.js +1 -1
  441. package/build-module/form-toggle/index.js.map +1 -1
  442. package/build-module/form-token-field/index.js +329 -361
  443. package/build-module/form-token-field/index.js.map +1 -1
  444. package/build-module/form-token-field/suggestions-list.js +32 -23
  445. package/build-module/form-token-field/suggestions-list.js.map +1 -1
  446. package/build-module/form-token-field/token-input.js +43 -58
  447. package/build-module/form-token-field/token-input.js.map +1 -1
  448. package/build-module/form-token-field/token.js +3 -1
  449. package/build-module/form-token-field/token.js.map +1 -1
  450. package/build-module/form-token-field/types.js +2 -0
  451. package/build-module/form-token-field/types.js.map +1 -0
  452. package/build-module/gradient-picker/index.js.map +1 -1
  453. package/build-module/heading/hook.js.map +1 -1
  454. package/build-module/higher-order/navigate-regions/index.js.map +1 -1
  455. package/build-module/higher-order/with-focus-return/index.js.map +1 -1
  456. package/build-module/higher-order/with-spoken-messages/index.js.map +1 -1
  457. package/build-module/icon/index.js.map +1 -1
  458. package/build-module/index.js +0 -1
  459. package/build-module/index.js.map +1 -1
  460. package/build-module/index.native.js +2 -1
  461. package/build-module/index.native.js.map +1 -1
  462. package/build-module/input-control/index.js +10 -5
  463. package/build-module/input-control/index.js.map +1 -1
  464. package/build-module/input-control/input-field.js +3 -26
  465. package/build-module/input-control/input-field.js.map +1 -1
  466. package/build-module/input-control/reducer/reducer.js +38 -26
  467. package/build-module/input-control/reducer/reducer.js.map +1 -1
  468. package/build-module/input-control/reducer/state.js +0 -1
  469. package/build-module/input-control/reducer/state.js.map +1 -1
  470. package/build-module/input-control/utils.js +49 -3
  471. package/build-module/input-control/utils.js.map +1 -1
  472. package/build-module/menu-items-choice/index.js +3 -5
  473. package/build-module/menu-items-choice/index.js.map +1 -1
  474. package/build-module/mobile/bottom-sheet/bottom-sheet-context.native.js.map +1 -1
  475. package/build-module/mobile/bottom-sheet/bottom-sheet-navigation/navigation-screen.native.js +1 -1
  476. package/build-module/mobile/bottom-sheet/bottom-sheet-navigation/navigation-screen.native.js.map +1 -1
  477. package/build-module/mobile/bottom-sheet/cell.native.js.map +1 -1
  478. package/build-module/mobile/bottom-sheet/cycle-picker-cell.native.js +1 -6
  479. package/build-module/mobile/bottom-sheet/cycle-picker-cell.native.js.map +1 -1
  480. package/build-module/mobile/bottom-sheet/index.native.js +1 -1
  481. package/build-module/mobile/bottom-sheet/index.native.js.map +1 -1
  482. package/build-module/mobile/bottom-sheet/picker-cell.native.js.map +1 -1
  483. package/build-module/mobile/bottom-sheet/stepper-cell/index.native.js.map +1 -1
  484. package/build-module/mobile/bottom-sheet-select-control/index.native.js +3 -2
  485. package/build-module/mobile/bottom-sheet-select-control/index.native.js.map +1 -1
  486. package/build-module/mobile/color-settings/index.native.js.map +1 -1
  487. package/build-module/mobile/global-styles-context/index.native.js.map +1 -1
  488. package/build-module/mobile/gradient/index.native.js.map +1 -1
  489. package/build-module/mobile/html-text-input/index.native.js +20 -9
  490. package/build-module/mobile/html-text-input/index.native.js.map +1 -1
  491. package/build-module/mobile/inserter-button/index.native.js.map +1 -1
  492. package/build-module/mobile/keyboard-aware-flat-list/index.android.js +21 -5
  493. package/build-module/mobile/keyboard-aware-flat-list/index.android.js.map +1 -1
  494. package/build-module/mobile/keyboard-aware-flat-list/index.ios.js +42 -25
  495. package/build-module/mobile/keyboard-aware-flat-list/index.ios.js.map +1 -1
  496. package/build-module/mobile/link-settings/image-link-destinations-screen.native.js.map +1 -1
  497. package/build-module/mobile/media-edit/index.native.js.map +1 -1
  498. package/build-module/mobile/segmented-control/index.native.js +2 -2
  499. package/build-module/mobile/segmented-control/index.native.js.map +1 -1
  500. package/build-module/modal/index.js +1 -1
  501. package/build-module/modal/index.js.map +1 -1
  502. package/build-module/navigable-container/container.js +5 -2
  503. package/build-module/navigable-container/container.js.map +1 -1
  504. package/build-module/navigation/context.js +3 -5
  505. package/build-module/navigation/context.js.map +1 -1
  506. package/build-module/navigation/index.js +3 -1
  507. package/build-module/navigation/index.js.map +1 -1
  508. package/build-module/navigation/item/index.js +3 -1
  509. package/build-module/navigation/item/index.js.map +1 -1
  510. package/build-module/navigator/navigator-back-button/hook.js.map +1 -1
  511. package/build-module/navigator/navigator-button/hook.js.map +1 -1
  512. package/build-module/navigator/navigator-provider/component.js +1 -1
  513. package/build-module/navigator/navigator-provider/component.js.map +1 -1
  514. package/build-module/navigator/navigator-screen/component.js +1 -1
  515. package/build-module/navigator/navigator-screen/component.js.map +1 -1
  516. package/build-module/notice/index.js +2 -1
  517. package/build-module/notice/index.js.map +1 -1
  518. package/build-module/notice/list.js +4 -1
  519. package/build-module/notice/list.js.map +1 -1
  520. package/build-module/palette-edit/index.js +37 -7
  521. package/build-module/palette-edit/index.js.map +1 -1
  522. package/build-module/panel/body.js +3 -1
  523. package/build-module/panel/body.js.map +1 -1
  524. package/build-module/placeholder/index.js +24 -11
  525. package/build-module/placeholder/index.js.map +1 -1
  526. package/build-module/popover/index.js +230 -277
  527. package/build-module/popover/index.js.map +1 -1
  528. package/build-module/radio-control/index.js +40 -7
  529. package/build-module/radio-control/index.js.map +1 -1
  530. package/build-module/radio-control/types.js +2 -0
  531. package/build-module/radio-control/types.js.map +1 -0
  532. package/build-module/range-control/index.js +4 -2
  533. package/build-module/range-control/index.js.map +1 -1
  534. package/build-module/range-control/input-range.js +2 -5
  535. package/build-module/range-control/input-range.js.map +1 -1
  536. package/build-module/range-control/utils.js +4 -1
  537. package/build-module/range-control/utils.js.map +1 -1
  538. package/build-module/resizable-box/resize-tooltip/index.js +2 -1
  539. package/build-module/resizable-box/resize-tooltip/index.js.map +1 -1
  540. package/build-module/resizable-box/resize-tooltip/utils.js +7 -10
  541. package/build-module/resizable-box/resize-tooltip/utils.js.map +1 -1
  542. package/build-module/responsive-wrapper/index.js.map +1 -1
  543. package/build-module/sandbox/index.native.js +1 -1
  544. package/build-module/sandbox/index.native.js.map +1 -1
  545. package/build-module/search-control/index.js +6 -7
  546. package/build-module/search-control/index.js.map +1 -1
  547. package/build-module/select-control/index.js +6 -2
  548. package/build-module/select-control/index.js.map +1 -1
  549. package/build-module/select-control/styles/select-control-styles.js +14 -11
  550. package/build-module/select-control/styles/select-control-styles.js.map +1 -1
  551. package/build-module/slot-fill/fill.js +1 -6
  552. package/build-module/slot-fill/fill.js.map +1 -1
  553. package/build-module/slot-fill/slot.js +12 -2
  554. package/build-module/slot-fill/slot.js.map +1 -1
  555. package/build-module/snackbar/index.js +3 -1
  556. package/build-module/snackbar/index.js.map +1 -1
  557. package/build-module/snackbar/list.js +4 -1
  558. package/build-module/snackbar/list.js.map +1 -1
  559. package/build-module/spacer/hook.js +10 -2
  560. package/build-module/spacer/hook.js.map +1 -1
  561. package/build-module/surface/component.js +7 -7
  562. package/build-module/surface/component.js.map +1 -1
  563. package/build-module/surface/hook.js +8 -11
  564. package/build-module/surface/hook.js.map +1 -1
  565. package/build-module/surface/index.js.map +1 -1
  566. package/build-module/surface/styles.js +8 -48
  567. package/build-module/surface/styles.js.map +1 -1
  568. package/build-module/tab-panel/index.js +3 -1
  569. package/build-module/tab-panel/index.js.map +1 -1
  570. package/build-module/text/hook.js +4 -4
  571. package/build-module/text/hook.js.map +1 -1
  572. package/build-module/text/utils.js.map +1 -1
  573. package/build-module/textarea-control/index.js +36 -5
  574. package/build-module/textarea-control/index.js.map +1 -1
  575. package/build-module/textarea-control/styles/textarea-control-styles.js +3 -3
  576. package/build-module/textarea-control/styles/textarea-control-styles.js.map +1 -1
  577. package/build-module/textarea-control/types.js +2 -0
  578. package/build-module/textarea-control/types.js.map +1 -0
  579. package/build-module/toggle-control/index.js +1 -2
  580. package/build-module/toggle-control/index.js.map +1 -1
  581. package/build-module/toggle-control/index.native.js +1 -6
  582. package/build-module/toggle-control/index.native.js.map +1 -1
  583. package/build-module/toggle-group-control/toggle-group-control/component.js +2 -3
  584. package/build-module/toggle-group-control/toggle-group-control/component.js.map +1 -1
  585. package/build-module/toggle-group-control/toggle-group-control/toggle-group-control-backdrop.js.map +1 -1
  586. package/build-module/toolbar/index.js.map +1 -1
  587. package/build-module/tools-panel/tools-panel/hook.js.map +1 -1
  588. package/build-module/tools-panel/tools-panel-header/hook.js.map +1 -1
  589. package/build-module/tooltip/index.js +3 -2
  590. package/build-module/tooltip/index.js.map +1 -1
  591. package/build-module/tree-grid/roving-tab-index-item.js.map +1 -1
  592. package/build-module/tree-select/index.js +53 -3
  593. package/build-module/tree-select/index.js.map +1 -1
  594. package/build-module/tree-select/types.js +2 -0
  595. package/build-module/tree-select/types.js.map +1 -0
  596. package/build-module/ui/form-group/form-group-content.js.map +1 -1
  597. package/build-module/unit-control/index.js.map +1 -1
  598. package/build-module/utils/hooks/index.js +0 -1
  599. package/build-module/utils/hooks/index.js.map +1 -1
  600. package/build-module/utils/unit-values.js.map +1 -1
  601. package/build-module/utils/values.js.map +1 -1
  602. package/build-module/z-stack/component.js +21 -2
  603. package/build-module/z-stack/component.js.map +1 -1
  604. package/build-module/z-stack/types.js +2 -0
  605. package/build-module/z-stack/types.js.map +1 -0
  606. package/build-style/style-rtl.css +75 -360
  607. package/build-style/style.css +71 -364
  608. package/build-types/base-control/stories/index.d.ts.map +1 -1
  609. package/build-types/base-field/hook.d.ts +0 -1
  610. package/build-types/base-field/hook.d.ts.map +1 -1
  611. package/build-types/border-box-control/border-box-control/component.d.ts.map +1 -1
  612. package/build-types/border-box-control/border-box-control/hook.d.ts +3 -2
  613. package/build-types/border-box-control/border-box-control/hook.d.ts.map +1 -1
  614. package/build-types/border-box-control/border-box-control-linked-button/component.d.ts.map +1 -1
  615. package/build-types/border-box-control/border-box-control-linked-button/hook.d.ts +0 -1
  616. package/build-types/border-box-control/border-box-control-linked-button/hook.d.ts.map +1 -1
  617. package/build-types/border-box-control/border-box-control-split-controls/component.d.ts.map +1 -1
  618. package/build-types/border-box-control/border-box-control-split-controls/hook.d.ts +4 -2
  619. package/build-types/border-box-control/border-box-control-split-controls/hook.d.ts.map +1 -1
  620. package/build-types/border-box-control/border-box-control-visualizer/hook.d.ts +0 -1
  621. package/build-types/border-box-control/border-box-control-visualizer/hook.d.ts.map +1 -1
  622. package/build-types/border-box-control/styles.d.ts +4 -3
  623. package/build-types/border-box-control/styles.d.ts.map +1 -1
  624. package/build-types/border-box-control/types.d.ts +40 -13
  625. package/build-types/border-box-control/types.d.ts.map +1 -1
  626. package/build-types/border-box-control/utils.d.ts.map +1 -1
  627. package/build-types/border-control/border-control/component.d.ts.map +1 -1
  628. package/build-types/border-control/border-control/hook.d.ts +2 -2
  629. package/build-types/border-control/border-control/hook.d.ts.map +1 -1
  630. package/build-types/border-control/border-control-dropdown/component.d.ts.map +1 -1
  631. package/build-types/border-control/border-control-dropdown/hook.d.ts +1 -1
  632. package/build-types/border-control/border-control-dropdown/hook.d.ts.map +1 -1
  633. package/build-types/border-control/border-control-style-picker/hook.d.ts +0 -1
  634. package/build-types/border-control/border-control-style-picker/hook.d.ts.map +1 -1
  635. package/build-types/border-control/styles.d.ts +2 -1
  636. package/build-types/border-control/styles.d.ts.map +1 -1
  637. package/build-types/border-control/types.d.ts +18 -6
  638. package/build-types/border-control/types.d.ts.map +1 -1
  639. package/build-types/button-group/index.d.ts +25 -0
  640. package/build-types/button-group/index.d.ts.map +1 -0
  641. package/build-types/button-group/stories/index.d.ts +12 -0
  642. package/build-types/button-group/stories/index.d.ts.map +1 -0
  643. package/build-types/button-group/types.d.ts +11 -0
  644. package/build-types/button-group/types.d.ts.map +1 -0
  645. package/build-types/card/card/hook.d.ts +0 -1
  646. package/build-types/card/card/hook.d.ts.map +1 -1
  647. package/build-types/card/card-body/hook.d.ts +0 -1
  648. package/build-types/card/card-body/hook.d.ts.map +1 -1
  649. package/build-types/card/card-divider/hook.d.ts +0 -1
  650. package/build-types/card/card-divider/hook.d.ts.map +1 -1
  651. package/build-types/card/card-footer/hook.d.ts +0 -1
  652. package/build-types/card/card-footer/hook.d.ts.map +1 -1
  653. package/build-types/card/card-header/hook.d.ts +0 -1
  654. package/build-types/card/card-header/hook.d.ts.map +1 -1
  655. package/build-types/card/card-media/hook.d.ts +0 -1
  656. package/build-types/card/card-media/hook.d.ts.map +1 -1
  657. package/build-types/card/types.d.ts +1 -1
  658. package/build-types/card/types.d.ts.map +1 -1
  659. package/build-types/checkbox-control/index.d.ts +26 -0
  660. package/build-types/checkbox-control/index.d.ts.map +1 -0
  661. package/build-types/checkbox-control/stories/index.d.ts +13 -0
  662. package/build-types/checkbox-control/stories/index.d.ts.map +1 -0
  663. package/build-types/checkbox-control/test/index.d.ts +2 -0
  664. package/build-types/checkbox-control/test/index.d.ts.map +1 -0
  665. package/build-types/checkbox-control/types.d.ts +35 -0
  666. package/build-types/checkbox-control/types.d.ts.map +1 -0
  667. package/build-types/color-palette/index.d.ts +1 -0
  668. package/build-types/color-palette/index.d.ts.map +1 -1
  669. package/build-types/color-palette/test/utils.d.ts +2 -0
  670. package/build-types/color-palette/test/utils.d.ts.map +1 -0
  671. package/build-types/color-picker/color-copy-button.d.ts +4 -0
  672. package/build-types/color-picker/color-copy-button.d.ts.map +1 -0
  673. package/build-types/color-picker/component.d.ts.map +1 -1
  674. package/build-types/color-picker/hex-input.d.ts.map +1 -1
  675. package/build-types/color-picker/styles.d.ts +8 -8
  676. package/build-types/color-picker/styles.d.ts.map +1 -1
  677. package/build-types/color-picker/types.d.ts +8 -0
  678. package/build-types/color-picker/types.d.ts.map +1 -1
  679. package/build-types/confirm-dialog/component.d.ts.map +1 -1
  680. package/build-types/date-time/date/index.d.ts +25 -0
  681. package/build-types/date-time/date/index.d.ts.map +1 -0
  682. package/build-types/date-time/date/styles.d.ts +23 -0
  683. package/build-types/date-time/date/styles.d.ts.map +1 -0
  684. package/build-types/date-time/date/test/index.d.ts +2 -0
  685. package/build-types/date-time/date/test/index.d.ts.map +1 -0
  686. package/build-types/date-time/date/test/utils.d.ts +2 -0
  687. package/build-types/date-time/date/test/utils.d.ts.map +1 -0
  688. package/build-types/date-time/date/utils.d.ts +15 -0
  689. package/build-types/date-time/date/utils.d.ts.map +1 -0
  690. package/build-types/date-time/date-time/index.d.ts +33 -0
  691. package/build-types/date-time/date-time/index.d.ts.map +1 -0
  692. package/build-types/date-time/date-time/styles.d.ts +6 -0
  693. package/build-types/date-time/date-time/styles.d.ts.map +1 -0
  694. package/build-types/date-time/index.d.ts +9 -0
  695. package/build-types/date-time/index.d.ts.map +1 -0
  696. package/build-types/date-time/stories/date-time.d.ts +14 -0
  697. package/build-types/date-time/stories/date-time.d.ts.map +1 -0
  698. package/build-types/date-time/stories/date.d.ts +14 -0
  699. package/build-types/date-time/stories/date.d.ts.map +1 -0
  700. package/build-types/date-time/stories/time.d.ts +12 -0
  701. package/build-types/date-time/stories/time.d.ts.map +1 -0
  702. package/build-types/date-time/stories/utils.d.ts +3 -0
  703. package/build-types/date-time/stories/utils.d.ts.map +1 -0
  704. package/build-types/date-time/time/index.d.ts +25 -0
  705. package/build-types/date-time/time/index.d.ts.map +1 -0
  706. package/build-types/date-time/time/styles.d.ts +111 -0
  707. package/build-types/date-time/time/styles.d.ts.map +1 -0
  708. package/build-types/date-time/time/test/index.d.ts +2 -0
  709. package/build-types/date-time/time/test/index.d.ts.map +1 -0
  710. package/build-types/date-time/time/timezone.d.ts +8 -0
  711. package/build-types/date-time/time/timezone.d.ts.map +1 -0
  712. package/build-types/date-time/types.d.ts +90 -0
  713. package/build-types/date-time/types.d.ts.map +1 -0
  714. package/build-types/divider/styles.d.ts.map +1 -1
  715. package/build-types/dropdown/index.d.ts.map +1 -1
  716. package/build-types/dropdown-menu/index.d.ts.map +1 -1
  717. package/build-types/elevation/hook.d.ts +0 -1
  718. package/build-types/elevation/hook.d.ts.map +1 -1
  719. package/build-types/external-link/index.d.ts +17 -0
  720. package/build-types/external-link/index.d.ts.map +1 -0
  721. package/build-types/external-link/stories/index.d.ts +12 -0
  722. package/build-types/external-link/stories/index.d.ts.map +1 -0
  723. package/build-types/external-link/styles/external-link-styles.d.ts +10 -0
  724. package/build-types/external-link/styles/external-link-styles.d.ts.map +1 -0
  725. package/build-types/external-link/types.d.ts +15 -0
  726. package/build-types/external-link/types.d.ts.map +1 -0
  727. package/build-types/flex/flex/hook.d.ts +0 -1
  728. package/build-types/flex/flex/hook.d.ts.map +1 -1
  729. package/build-types/flex/flex-block/hook.d.ts +0 -1
  730. package/build-types/flex/flex-block/hook.d.ts.map +1 -1
  731. package/build-types/flex/flex-item/hook.d.ts +0 -1
  732. package/build-types/flex/flex-item/hook.d.ts.map +1 -1
  733. package/build-types/form-token-field/index.d.ts +15 -0
  734. package/build-types/form-token-field/index.d.ts.map +1 -0
  735. package/build-types/form-token-field/stories/index.d.ts +13 -0
  736. package/build-types/form-token-field/stories/index.d.ts.map +1 -0
  737. package/build-types/form-token-field/suggestions-list.d.ts +10 -0
  738. package/build-types/form-token-field/suggestions-list.d.ts.map +1 -0
  739. package/build-types/form-token-field/test/lib/fixtures.d.ts +26 -0
  740. package/build-types/form-token-field/test/lib/fixtures.d.ts.map +1 -0
  741. package/build-types/form-token-field/test/lib/token-field-wrapper.d.ts +18 -0
  742. package/build-types/form-token-field/test/lib/token-field-wrapper.d.ts.map +1 -0
  743. package/build-types/form-token-field/token-input.d.ts +12 -0
  744. package/build-types/form-token-field/token-input.d.ts.map +1 -0
  745. package/build-types/form-token-field/token.d.ts +4 -0
  746. package/build-types/form-token-field/token.d.ts.map +1 -0
  747. package/build-types/form-token-field/types.d.ts +176 -0
  748. package/build-types/form-token-field/types.d.ts.map +1 -0
  749. package/build-types/grid/hook.d.ts +0 -1
  750. package/build-types/grid/hook.d.ts.map +1 -1
  751. package/build-types/h-stack/hook.d.ts +0 -1
  752. package/build-types/h-stack/hook.d.ts.map +1 -1
  753. package/build-types/heading/hook.d.ts +0 -1
  754. package/build-types/heading/hook.d.ts.map +1 -1
  755. package/build-types/higher-order/with-focus-outside/index.d.ts +1 -1
  756. package/build-types/input-control/index.d.ts +1 -1
  757. package/build-types/input-control/index.d.ts.map +1 -1
  758. package/build-types/input-control/input-field.d.ts +1 -1
  759. package/build-types/input-control/input-field.d.ts.map +1 -1
  760. package/build-types/input-control/reducer/reducer.d.ts +5 -3
  761. package/build-types/input-control/reducer/reducer.d.ts.map +1 -1
  762. package/build-types/input-control/reducer/state.d.ts +2 -2
  763. package/build-types/input-control/reducer/state.d.ts.map +1 -1
  764. package/build-types/input-control/stories/index.d.ts +5 -5
  765. package/build-types/input-control/stories/index.d.ts.map +1 -1
  766. package/build-types/input-control/utils.d.ts +17 -0
  767. package/build-types/input-control/utils.d.ts.map +1 -1
  768. package/build-types/item-group/item/hook.d.ts +0 -1
  769. package/build-types/item-group/item/hook.d.ts.map +1 -1
  770. package/build-types/item-group/item-group/hook.d.ts +0 -1
  771. package/build-types/item-group/item-group/hook.d.ts.map +1 -1
  772. package/build-types/navigator/navigator-back-button/hook.d.ts +0 -1
  773. package/build-types/navigator/navigator-back-button/hook.d.ts.map +1 -1
  774. package/build-types/navigator/navigator-button/hook.d.ts +0 -1
  775. package/build-types/navigator/navigator-button/hook.d.ts.map +1 -1
  776. package/build-types/navigator/navigator-provider/component.d.ts.map +1 -1
  777. package/build-types/number-control/styles/number-control-styles.d.ts +1 -1
  778. package/build-types/popover/index.d.ts +6 -7
  779. package/build-types/popover/index.d.ts.map +1 -1
  780. package/build-types/radio-control/index.d.ts +31 -0
  781. package/build-types/radio-control/index.d.ts.map +1 -0
  782. package/build-types/radio-control/stories/index.d.ts +12 -0
  783. package/build-types/radio-control/stories/index.d.ts.map +1 -0
  784. package/build-types/radio-control/types.d.ts +29 -0
  785. package/build-types/radio-control/types.d.ts.map +1 -0
  786. package/build-types/range-control/index.d.ts +5 -5
  787. package/build-types/range-control/index.d.ts.map +1 -1
  788. package/build-types/range-control/input-range.d.ts +4 -4
  789. package/build-types/range-control/input-range.d.ts.map +1 -1
  790. package/build-types/range-control/utils.d.ts.map +1 -1
  791. package/build-types/resizable-box/index.d.ts +1 -1
  792. package/build-types/resizable-box/resize-tooltip/index.d.ts +1 -1
  793. package/build-types/resizable-box/resize-tooltip/index.d.ts.map +1 -1
  794. package/build-types/resizable-box/resize-tooltip/utils.d.ts.map +1 -1
  795. package/build-types/scrollable/hook.d.ts +0 -1
  796. package/build-types/scrollable/hook.d.ts.map +1 -1
  797. package/build-types/select-control/index.d.ts +1 -1
  798. package/build-types/select-control/index.d.ts.map +1 -1
  799. package/build-types/select-control/stories/index.d.ts +3 -3
  800. package/build-types/select-control/stories/index.d.ts.map +1 -1
  801. package/build-types/select-control/styles/select-control-styles.d.ts.map +1 -1
  802. package/build-types/select-control/types.d.ts +1 -1
  803. package/build-types/select-control/types.d.ts.map +1 -1
  804. package/build-types/slot-fill/fill.d.ts.map +1 -1
  805. package/build-types/slot-fill/slot.d.ts.map +1 -1
  806. package/build-types/spacer/hook.d.ts +0 -1
  807. package/build-types/spacer/hook.d.ts.map +1 -1
  808. package/build-types/surface/component.d.ts +3 -2
  809. package/build-types/surface/component.d.ts.map +1 -1
  810. package/build-types/surface/hook.d.ts +4 -5
  811. package/build-types/surface/hook.d.ts.map +1 -1
  812. package/build-types/surface/index.d.ts +2 -2
  813. package/build-types/surface/index.d.ts.map +1 -1
  814. package/build-types/surface/stories/index.d.ts +12 -0
  815. package/build-types/surface/stories/index.d.ts.map +1 -0
  816. package/build-types/surface/styles.d.ts +10 -21
  817. package/build-types/surface/styles.d.ts.map +1 -1
  818. package/build-types/surface/test/index.d.ts +2 -0
  819. package/build-types/{flyout/flyout → surface/test}/index.d.ts.map +1 -1
  820. package/build-types/surface/types.d.ts +1 -1
  821. package/build-types/surface/types.d.ts.map +1 -1
  822. package/build-types/text/hook.d.ts +0 -1
  823. package/build-types/text/hook.d.ts.map +1 -1
  824. package/build-types/text/utils.d.ts.map +1 -1
  825. package/build-types/text-control/index.d.ts +1 -1
  826. package/build-types/text-control/index.d.ts.map +1 -1
  827. package/build-types/text-control/stories/index.d.ts.map +1 -1
  828. package/build-types/textarea-control/index.d.ts +29 -0
  829. package/build-types/textarea-control/index.d.ts.map +1 -0
  830. package/build-types/textarea-control/stories/index.d.ts +12 -0
  831. package/build-types/textarea-control/stories/index.d.ts.map +1 -0
  832. package/build-types/textarea-control/styles/textarea-control-styles.d.ts +6 -0
  833. package/build-types/textarea-control/styles/textarea-control-styles.d.ts.map +1 -0
  834. package/build-types/textarea-control/types.d.ts +26 -0
  835. package/build-types/textarea-control/types.d.ts.map +1 -0
  836. package/build-types/toggle-group-control/toggle-group-control/component.d.ts.map +1 -1
  837. package/build-types/toggle-group-control/toggle-group-control/toggle-group-control-backdrop.d.ts.map +1 -1
  838. package/build-types/tools-panel/tools-panel/hook.d.ts +0 -1
  839. package/build-types/tools-panel/tools-panel/hook.d.ts.map +1 -1
  840. package/build-types/tools-panel/tools-panel-header/hook.d.ts +0 -1
  841. package/build-types/tools-panel/tools-panel-header/hook.d.ts.map +1 -1
  842. package/build-types/tools-panel/tools-panel-item/hook.d.ts +0 -1
  843. package/build-types/tools-panel/tools-panel-item/hook.d.ts.map +1 -1
  844. package/build-types/tooltip/index.d.ts.map +1 -1
  845. package/build-types/tree-select/index.d.ts +53 -0
  846. package/build-types/tree-select/index.d.ts.map +1 -0
  847. package/build-types/tree-select/stories/index.d.ts +12 -0
  848. package/build-types/tree-select/stories/index.d.ts.map +1 -0
  849. package/build-types/tree-select/types.d.ts +30 -0
  850. package/build-types/tree-select/types.d.ts.map +1 -0
  851. package/build-types/truncate/hook.d.ts +0 -1
  852. package/build-types/truncate/hook.d.ts.map +1 -1
  853. package/build-types/ui/context/wordpress-component.d.ts.map +1 -1
  854. package/build-types/ui/control-group/hook.d.ts +0 -1
  855. package/build-types/ui/control-group/hook.d.ts.map +1 -1
  856. package/build-types/ui/control-label/hook.d.ts +0 -1
  857. package/build-types/ui/control-label/hook.d.ts.map +1 -1
  858. package/build-types/ui/form-group/use-form-group.d.ts +0 -2
  859. package/build-types/ui/form-group/use-form-group.d.ts.map +1 -1
  860. package/build-types/unit-control/index.d.ts +1 -1
  861. package/build-types/unit-control/index.d.ts.map +1 -1
  862. package/build-types/unit-control/stories/index.d.ts.map +1 -1
  863. package/build-types/utils/hooks/index.d.ts +0 -1
  864. package/build-types/utils/unit-values.d.ts.map +1 -1
  865. package/build-types/utils/values.d.ts.map +1 -1
  866. package/build-types/v-stack/hook.d.ts +0 -1
  867. package/build-types/v-stack/hook.d.ts.map +1 -1
  868. package/build-types/z-stack/component.d.ts +18 -28
  869. package/build-types/z-stack/component.d.ts.map +1 -1
  870. package/build-types/z-stack/stories/index.d.ts +6 -0
  871. package/build-types/z-stack/stories/index.d.ts.map +1 -0
  872. package/build-types/z-stack/types.d.ts +33 -0
  873. package/build-types/z-stack/types.d.ts.map +1 -0
  874. package/package.json +20 -20
  875. package/src/alignment-matrix-control/index.js +6 -3
  876. package/src/angle-picker-control/index.js +1 -1
  877. package/src/autocomplete/autocompleter-ui.js +1 -1
  878. package/src/autocomplete/autocompleter-ui.native.js +2 -2
  879. package/src/autocomplete/index.js +21 -9
  880. package/src/autocomplete/style.scss +1 -1
  881. package/src/base-control/stories/index.tsx +2 -3
  882. package/src/border-box-control/border-box-control/README.md +10 -14
  883. package/src/border-box-control/border-box-control/component.tsx +21 -4
  884. package/src/border-box-control/border-box-control/hook.ts +2 -2
  885. package/src/border-box-control/border-box-control-linked-button/component.tsx +2 -5
  886. package/src/border-box-control/border-box-control-linked-button/hook.ts +10 -6
  887. package/src/border-box-control/border-box-control-split-controls/component.tsx +26 -7
  888. package/src/border-box-control/border-box-control-split-controls/hook.ts +18 -4
  889. package/src/border-box-control/border-box-control-visualizer/hook.ts +14 -6
  890. package/src/border-box-control/stories/index.js +1 -0
  891. package/src/border-box-control/styles.ts +20 -9
  892. package/src/border-box-control/types.ts +40 -14
  893. package/src/border-box-control/utils.ts +5 -2
  894. package/src/border-control/border-control/README.md +0 -7
  895. package/src/border-control/border-control/component.tsx +4 -2
  896. package/src/border-control/border-control/hook.ts +15 -7
  897. package/src/border-control/border-control-dropdown/component.tsx +18 -11
  898. package/src/border-control/border-control-dropdown/hook.ts +7 -5
  899. package/src/border-control/stories/index.js +1 -0
  900. package/src/border-control/styles.ts +82 -22
  901. package/src/border-control/types.ts +18 -6
  902. package/src/box-control/all-input-control.js +2 -4
  903. package/src/box-control/axial-input-controls.js +4 -6
  904. package/src/box-control/index.js +2 -5
  905. package/src/box-control/input-controls.js +33 -36
  906. package/src/box-control/test/index.js +120 -109
  907. package/src/box-control/unit-control.js +2 -1
  908. package/src/button/index.native.js +34 -20
  909. package/src/button-group/index.tsx +47 -0
  910. package/src/button-group/stories/index.tsx +41 -0
  911. package/src/button-group/types.ts +11 -0
  912. package/src/card/stories/index.js +10 -5
  913. package/src/card/types.ts +1 -1
  914. package/src/checkbox-control/README.md +10 -8
  915. package/src/checkbox-control/{index.js → index.tsx} +51 -17
  916. package/src/checkbox-control/stories/{index.js → index.tsx} +48 -27
  917. package/src/checkbox-control/test/__snapshots__/index.tsx.snap +42 -0
  918. package/src/checkbox-control/test/index.tsx +110 -0
  919. package/src/checkbox-control/types.ts +36 -0
  920. package/src/circular-option-picker/style.scss +1 -0
  921. package/src/color-palette/index.js +17 -17
  922. package/src/color-palette/index.native.js +3 -0
  923. package/src/color-palette/stories/index.js +25 -1
  924. package/src/color-palette/style.scss +3 -18
  925. package/src/color-palette/test/utils.ts +24 -0
  926. package/src/color-picker/color-copy-button.tsx +76 -0
  927. package/src/color-picker/component.tsx +18 -38
  928. package/src/color-picker/hex-input.tsx +16 -0
  929. package/src/color-picker/index.native.js +7 -4
  930. package/src/color-picker/styles.ts +5 -1
  931. package/src/color-picker/types.ts +9 -0
  932. package/src/combobox-control/index.js +4 -2
  933. package/src/confirm-dialog/component.tsx +7 -8
  934. package/src/custom-gradient-bar/constants.js +2 -2
  935. package/src/custom-gradient-bar/control-points.js +20 -16
  936. package/src/custom-gradient-bar/index.js +11 -11
  937. package/src/custom-gradient-bar/test/utils.js +79 -0
  938. package/src/custom-gradient-bar/utils.js +6 -18
  939. package/src/custom-gradient-picker/style.scss +1 -3
  940. package/src/custom-gradient-picker/utils.js +5 -4
  941. package/src/custom-select-control/index.js +2 -1
  942. package/src/custom-select-control/stories/index.js +1 -2
  943. package/src/date-time/README.md +29 -10
  944. package/src/date-time/{datepicker.scss → date/datepicker.scss} +0 -0
  945. package/src/date-time/{date.js → date/index.tsx} +77 -25
  946. package/src/date-time/date/style.scss +85 -0
  947. package/src/date-time/date/styles.ts +55 -0
  948. package/src/date-time/{test/date.js → date/test/index.tsx} +5 -4
  949. package/src/date-time/{test/utils.js → date/test/utils.ts} +1 -1
  950. package/src/date-time/date/utils.ts +20 -0
  951. package/src/date-time/date-time/index.tsx +215 -0
  952. package/src/date-time/date-time/styles.ts +8 -0
  953. package/src/date-time/index.ts +9 -0
  954. package/src/date-time/stories/date-time.tsx +73 -0
  955. package/src/date-time/stories/date.tsx +72 -0
  956. package/src/date-time/stories/time.tsx +51 -0
  957. package/src/date-time/stories/utils.ts +9 -0
  958. package/src/date-time/style.scss +1 -262
  959. package/src/date-time/time/index.tsx +356 -0
  960. package/src/date-time/time/styles.ts +119 -0
  961. package/src/date-time/{test/time.js → time/test/index.tsx} +119 -57
  962. package/src/date-time/{timezone.js → time/timezone.tsx} +9 -5
  963. package/src/date-time/types.ts +104 -0
  964. package/src/dimension-control/index.js +1 -2
  965. package/src/disabled/index.js +1 -1
  966. package/src/divider/styles.ts +2 -3
  967. package/src/draggable/index.js +3 -3
  968. package/src/draggable/index.native.js +234 -0
  969. package/src/draggable/style.native.scss +3 -0
  970. package/src/draggable/test/index.native.js +130 -0
  971. package/src/drop-zone/provider.js +1 -2
  972. package/src/dropdown/index.js +14 -5
  973. package/src/dropdown/style.scss +1 -1
  974. package/src/dropdown-menu/index.js +11 -1
  975. package/src/dropdown-menu/index.native.js +11 -1
  976. package/src/external-link/README.md +18 -0
  977. package/src/external-link/{index.js → index.tsx} +26 -6
  978. package/src/external-link/stories/index.tsx +36 -0
  979. package/src/external-link/styles/{external-link-styles.js → external-link-styles.ts} +0 -0
  980. package/src/external-link/types.ts +15 -0
  981. package/src/flex/flex/hook.js +4 -1
  982. package/src/focal-point-picker/controls.js +1 -5
  983. package/src/focal-point-picker/index.js +2 -8
  984. package/src/focal-point-picker/index.native.js +3 -3
  985. package/src/focal-point-picker/media.js +2 -5
  986. package/src/font-size-picker/index.js +3 -1
  987. package/src/form-file-upload/test/index.js +8 -4
  988. package/src/form-toggle/index.js +2 -1
  989. package/src/form-toggle/test/index.js +1 -2
  990. package/src/form-token-field/index.tsx +694 -0
  991. package/src/form-token-field/stories/index.tsx +103 -0
  992. package/src/form-token-field/style.scss +2 -1
  993. package/src/form-token-field/{suggestions-list.js → suggestions-list.tsx} +45 -29
  994. package/src/form-token-field/test/index.js +64 -31
  995. package/src/form-token-field/test/lib/{token-field-wrapper.js → token-field-wrapper.tsx} +24 -9
  996. package/src/form-token-field/token-input.tsx +76 -0
  997. package/src/form-token-field/{token.js → token.tsx} +4 -2
  998. package/src/form-token-field/types.ts +178 -0
  999. package/src/gradient-picker/index.js +4 -3
  1000. package/src/heading/hook.ts +5 -4
  1001. package/src/higher-order/navigate-regions/index.js +7 -5
  1002. package/src/higher-order/with-filters/test/index.js +43 -36
  1003. package/src/higher-order/with-focus-return/index.js +14 -13
  1004. package/src/higher-order/with-spoken-messages/index.js +8 -7
  1005. package/src/higher-order/with-spoken-messages/test/index.js +1 -1
  1006. package/src/icon/index.tsx +2 -2
  1007. package/src/index.js +0 -1
  1008. package/src/index.native.js +1 -0
  1009. package/src/input-control/index.tsx +10 -3
  1010. package/src/input-control/input-field.tsx +12 -31
  1011. package/src/input-control/reducer/reducer.ts +63 -47
  1012. package/src/input-control/reducer/state.ts +2 -3
  1013. package/src/input-control/utils.ts +56 -2
  1014. package/src/item-group/stories/index.js +24 -19
  1015. package/src/menu-item/test/index.js +2 -1
  1016. package/src/menu-items-choice/index.js +2 -5
  1017. package/src/mobile/bottom-sheet/bottom-sheet-context.native.js +2 -4
  1018. package/src/mobile/bottom-sheet/bottom-sheet-navigation/navigation-screen.native.js +1 -1
  1019. package/src/mobile/bottom-sheet/bottom-sheet-navigation/test/navigation-container.native.js +1 -1
  1020. package/src/mobile/bottom-sheet/cell.native.js +2 -3
  1021. package/src/mobile/bottom-sheet/cycle-picker-cell.native.js +3 -5
  1022. package/src/mobile/bottom-sheet/index.native.js +15 -18
  1023. package/src/mobile/bottom-sheet/picker-cell.native.js +2 -7
  1024. package/src/mobile/bottom-sheet/stepper-cell/index.native.js +4 -6
  1025. package/src/mobile/bottom-sheet-select-control/index.native.js +7 -2
  1026. package/src/mobile/color-settings/index.native.js +2 -4
  1027. package/src/mobile/global-styles-context/index.native.js +8 -7
  1028. package/src/mobile/gradient/index.native.js +12 -9
  1029. package/src/mobile/gradient/test/index.native.js +1 -3
  1030. package/src/mobile/html-text-input/index.native.js +47 -32
  1031. package/src/mobile/html-text-input/style.android.scss +1 -15
  1032. package/src/mobile/html-text-input/style.ios.scss +1 -15
  1033. package/src/mobile/html-text-input/{style-common.native.scss → style.scss} +16 -0
  1034. package/src/mobile/inserter-button/index.native.js +2 -6
  1035. package/src/mobile/keyboard-aware-flat-list/index.android.js +15 -5
  1036. package/src/mobile/keyboard-aware-flat-list/index.ios.js +75 -46
  1037. package/src/mobile/link-settings/image-link-destinations-screen.native.js +6 -2
  1038. package/src/mobile/media-edit/index.native.js +2 -3
  1039. package/src/mobile/segmented-control/index.native.js +4 -5
  1040. package/src/mobile/utils/test/index.native.js +3 -12
  1041. package/src/modal/index.js +1 -1
  1042. package/src/navigable-container/container.js +3 -2
  1043. package/src/navigable-container/test/menu.js +1 -2
  1044. package/src/navigable-container/test/tabbable.js +1 -2
  1045. package/src/navigation/context.js +2 -5
  1046. package/src/navigation/index.js +2 -1
  1047. package/src/navigation/item/index.js +2 -1
  1048. package/src/navigation/stories/controlled-state.js +1 -1
  1049. package/src/navigation/stories/more-examples.js +2 -3
  1050. package/src/navigation/test/index.js +252 -52
  1051. package/src/navigator/navigator-back-button/hook.ts +14 -12
  1052. package/src/navigator/navigator-button/hook.ts +14 -13
  1053. package/src/navigator/navigator-provider/component.tsx +2 -6
  1054. package/src/navigator/navigator-screen/component.tsx +3 -3
  1055. package/src/navigator/stories/index.js +16 -10
  1056. package/src/notice/index.js +2 -1
  1057. package/src/notice/list.js +3 -1
  1058. package/src/palette-edit/index.js +37 -9
  1059. package/src/palette-edit/style.scss +0 -7
  1060. package/src/palette-edit/test/index.js +63 -0
  1061. package/src/panel/README.md +1 -1
  1062. package/src/panel/body.js +2 -1
  1063. package/src/placeholder/README.md +7 -6
  1064. package/src/placeholder/index.js +27 -10
  1065. package/src/placeholder/style.scss +23 -0
  1066. package/src/placeholder/test/index.js +7 -0
  1067. package/src/popover/README.md +7 -9
  1068. package/src/popover/index.js +256 -370
  1069. package/src/popover/style.scss +20 -190
  1070. package/src/popover/test/__snapshots__/index.js.snap +6 -18
  1071. package/src/query-controls/README.md +1 -1
  1072. package/src/radio-control/README.md +17 -23
  1073. package/src/radio-control/index.tsx +107 -0
  1074. package/src/radio-control/stories/index.tsx +72 -0
  1075. package/src/radio-control/types.ts +32 -0
  1076. package/src/range-control/index.js +4 -2
  1077. package/src/range-control/input-range.js +2 -5
  1078. package/src/range-control/utils.js +3 -1
  1079. package/src/resizable-box/resize-tooltip/index.tsx +2 -1
  1080. package/src/resizable-box/resize-tooltip/utils.ts +5 -10
  1081. package/src/responsive-wrapper/index.js +2 -4
  1082. package/src/sandbox/index.native.js +1 -1
  1083. package/src/sandbox/test/index.js +4 -6
  1084. package/src/search-control/index.js +6 -7
  1085. package/src/select-control/README.md +11 -0
  1086. package/src/select-control/index.tsx +9 -2
  1087. package/src/select-control/stories/index.tsx +3 -4
  1088. package/src/select-control/styles/select-control-styles.ts +6 -3
  1089. package/src/select-control/types.ts +1 -1
  1090. package/src/slot-fill/README.md +1 -1
  1091. package/src/slot-fill/fill.js +1 -5
  1092. package/src/slot-fill/slot.js +12 -2
  1093. package/src/snackbar/index.js +1 -1
  1094. package/src/snackbar/list.js +2 -1
  1095. package/src/spacer/hook.ts +13 -13
  1096. package/src/surface/README.md +15 -15
  1097. package/src/surface/{component.js → component.tsx} +13 -7
  1098. package/src/surface/{hook.js → hook.ts} +13 -12
  1099. package/src/surface/{index.js → index.ts} +0 -0
  1100. package/src/surface/stories/index.tsx +40 -0
  1101. package/src/surface/{styles.js → styles.ts} +15 -44
  1102. package/src/surface/test/__snapshots__/{index.js.snap → index.tsx.snap} +0 -0
  1103. package/src/surface/test/{index.js → index.tsx} +2 -1
  1104. package/src/surface/types.ts +1 -1
  1105. package/src/tab-panel/index.js +3 -1
  1106. package/src/tab-panel/style.scss +1 -1
  1107. package/src/text/hook.js +4 -1
  1108. package/src/text/utils.js +2 -3
  1109. package/src/text-control/stories/index.tsx +4 -6
  1110. package/src/textarea-control/README.md +14 -20
  1111. package/src/textarea-control/index.tsx +86 -0
  1112. package/src/textarea-control/stories/index.tsx +58 -0
  1113. package/src/textarea-control/styles/{textarea-control-styles.js → textarea-control-styles.ts} +0 -0
  1114. package/src/textarea-control/types.ts +30 -0
  1115. package/src/toggle-control/index.js +1 -2
  1116. package/src/toggle-control/index.native.js +2 -6
  1117. package/src/toggle-group-control/test/__snapshots__/index.js.snap +4 -10
  1118. package/src/toggle-group-control/toggle-group-control/component.tsx +7 -3
  1119. package/src/toggle-group-control/toggle-group-control/toggle-group-control-backdrop.tsx +2 -4
  1120. package/src/toolbar/index.js +1 -2
  1121. package/src/tools-panel/tools-panel/hook.ts +2 -4
  1122. package/src/tools-panel/tools-panel-header/hook.ts +2 -5
  1123. package/src/tooltip/index.js +9 -2
  1124. package/src/tooltip/style.scss +2 -4
  1125. package/src/tooltip/test/index.native.js +1 -1
  1126. package/src/tree-grid/roving-tab-index-item.js +2 -4
  1127. package/src/tree-grid/test/index.js +2 -3
  1128. package/src/tree-select/README.md +2 -2
  1129. package/src/tree-select/index.tsx +99 -0
  1130. package/src/tree-select/stories/index.tsx +80 -0
  1131. package/src/tree-select/types.ts +35 -0
  1132. package/src/ui/context/wordpress-component.ts +4 -5
  1133. package/src/ui/form-group/form-group-content.js +4 -4
  1134. package/src/unit-control/index.tsx +7 -9
  1135. package/src/unit-control/stories/index.tsx +8 -12
  1136. package/src/unit-control/test/index.tsx +88 -11
  1137. package/src/utils/hooks/index.js +0 -1
  1138. package/src/utils/hooks/stories/use-cx.js +8 -7
  1139. package/src/utils/hooks/test/use-controlled-state.js +2 -1
  1140. package/src/utils/unit-values.ts +2 -1
  1141. package/src/utils/values.js +2 -3
  1142. package/src/z-stack/README.md +14 -3
  1143. package/src/z-stack/component.tsx +24 -29
  1144. package/src/z-stack/stories/index.tsx +76 -0
  1145. package/src/z-stack/types.ts +33 -0
  1146. package/tsconfig.json +12 -2
  1147. package/tsconfig.tsbuildinfo +1 -1
  1148. package/build/color-picker/color-display.js +0 -184
  1149. package/build/color-picker/color-display.js.map +0 -1
  1150. package/build/date-time/date.js.map +0 -1
  1151. package/build/date-time/time.js +0 -287
  1152. package/build/date-time/time.js.map +0 -1
  1153. package/build/date-time/timezone.js.map +0 -1
  1154. package/build/date-time/utils.js.map +0 -1
  1155. package/build/flyout/context.js +0 -23
  1156. package/build/flyout/context.js.map +0 -1
  1157. package/build/flyout/flyout/component.js +0 -106
  1158. package/build/flyout/flyout/component.js.map +0 -1
  1159. package/build/flyout/flyout/hook.js +0 -53
  1160. package/build/flyout/flyout/hook.js.map +0 -1
  1161. package/build/flyout/flyout/index.js +0 -24
  1162. package/build/flyout/flyout/index.js.map +0 -1
  1163. package/build/flyout/flyout-content/component.js +0 -65
  1164. package/build/flyout/flyout-content/component.js.map +0 -1
  1165. package/build/flyout/flyout-content/index.js +0 -16
  1166. package/build/flyout/flyout-content/index.js.map +0 -1
  1167. package/build/flyout/index.js +0 -16
  1168. package/build/flyout/index.js.map +0 -1
  1169. package/build/flyout/styles.js +0 -46
  1170. package/build/flyout/styles.js.map +0 -1
  1171. package/build/flyout/utils.js +0 -36
  1172. package/build/flyout/utils.js.map +0 -1
  1173. package/build/mobile/html-text-input/container.android.js +0 -41
  1174. package/build/mobile/html-text-input/container.android.js.map +0 -1
  1175. package/build/mobile/html-text-input/container.ios.js +0 -60
  1176. package/build/mobile/html-text-input/container.ios.js.map +0 -1
  1177. package/build/popover/utils.js +0 -322
  1178. package/build/popover/utils.js.map +0 -1
  1179. package/build/utils/hooks/use-combined-ref.js +0 -32
  1180. package/build/utils/hooks/use-combined-ref.js.map +0 -1
  1181. package/build-module/color-picker/color-display.js +0 -170
  1182. package/build-module/color-picker/color-display.js.map +0 -1
  1183. package/build-module/date-time/date.js.map +0 -1
  1184. package/build-module/date-time/time.js +0 -269
  1185. package/build-module/date-time/time.js.map +0 -1
  1186. package/build-module/date-time/timezone.js.map +0 -1
  1187. package/build-module/date-time/utils.js +0 -20
  1188. package/build-module/date-time/utils.js.map +0 -1
  1189. package/build-module/flyout/context.js +0 -11
  1190. package/build-module/flyout/context.js.map +0 -1
  1191. package/build-module/flyout/flyout/component.js +0 -89
  1192. package/build-module/flyout/flyout/component.js.map +0 -1
  1193. package/build-module/flyout/flyout/hook.js +0 -44
  1194. package/build-module/flyout/flyout/hook.js.map +0 -1
  1195. package/build-module/flyout/flyout/index.js +0 -3
  1196. package/build-module/flyout/flyout/index.js.map +0 -1
  1197. package/build-module/flyout/flyout-content/component.js +0 -51
  1198. package/build-module/flyout/flyout-content/component.js.map +0 -1
  1199. package/build-module/flyout/flyout-content/index.js +0 -2
  1200. package/build-module/flyout/flyout-content/index.js.map +0 -1
  1201. package/build-module/flyout/index.js +0 -2
  1202. package/build-module/flyout/index.js.map +0 -1
  1203. package/build-module/flyout/styles.js +0 -27
  1204. package/build-module/flyout/styles.js.map +0 -1
  1205. package/build-module/flyout/utils.js +0 -25
  1206. package/build-module/flyout/utils.js.map +0 -1
  1207. package/build-module/mobile/html-text-input/container.android.js +0 -29
  1208. package/build-module/mobile/html-text-input/container.android.js.map +0 -1
  1209. package/build-module/mobile/html-text-input/container.ios.js +0 -48
  1210. package/build-module/mobile/html-text-input/container.ios.js.map +0 -1
  1211. package/build-module/popover/utils.js +0 -308
  1212. package/build-module/popover/utils.js.map +0 -1
  1213. package/build-module/utils/hooks/use-combined-ref.js +0 -28
  1214. package/build-module/utils/hooks/use-combined-ref.js.map +0 -1
  1215. package/build-types/color-picker/color-display.d.ts +0 -14
  1216. package/build-types/color-picker/color-display.d.ts.map +0 -1
  1217. package/build-types/flyout/context.d.ts +0 -6
  1218. package/build-types/flyout/context.d.ts.map +0 -1
  1219. package/build-types/flyout/flyout/component.d.ts +0 -21
  1220. package/build-types/flyout/flyout/component.d.ts.map +0 -1
  1221. package/build-types/flyout/flyout/hook.d.ts +0 -270
  1222. package/build-types/flyout/flyout/hook.d.ts.map +0 -1
  1223. package/build-types/flyout/flyout/index.d.ts +0 -3
  1224. package/build-types/flyout/flyout-content/component.d.ts +0 -3
  1225. package/build-types/flyout/flyout-content/component.d.ts.map +0 -1
  1226. package/build-types/flyout/flyout-content/index.d.ts +0 -2
  1227. package/build-types/flyout/flyout-content/index.d.ts.map +0 -1
  1228. package/build-types/flyout/index.d.ts +0 -2
  1229. package/build-types/flyout/index.d.ts.map +0 -1
  1230. package/build-types/flyout/styles.d.ts +0 -22
  1231. package/build-types/flyout/styles.d.ts.map +0 -1
  1232. package/build-types/flyout/types.d.ts +0 -80
  1233. package/build-types/flyout/types.d.ts.map +0 -1
  1234. package/build-types/flyout/utils.d.ts +0 -8
  1235. package/build-types/flyout/utils.d.ts.map +0 -1
  1236. package/build-types/popover/utils.d.ts +0 -70
  1237. package/build-types/popover/utils.d.ts.map +0 -1
  1238. package/build-types/utils/hooks/use-combined-ref.d.ts +0 -8
  1239. package/build-types/utils/hooks/use-combined-ref.d.ts.map +0 -1
  1240. package/src/button-group/index.js +0 -17
  1241. package/src/button-group/stories/index.js +0 -21
  1242. package/src/color-picker/color-display.tsx +0 -169
  1243. package/src/date-time/index.js +0 -170
  1244. package/src/date-time/stories/date.js +0 -17
  1245. package/src/date-time/stories/index.js +0 -91
  1246. package/src/date-time/stories/time.js +0 -32
  1247. package/src/date-time/time.js +0 -310
  1248. package/src/date-time/utils.js +0 -18
  1249. package/src/external-link/stories/index.js +0 -23
  1250. package/src/flyout/context.js +0 -10
  1251. package/src/flyout/flyout/README.md +0 -98
  1252. package/src/flyout/flyout/component.js +0 -111
  1253. package/src/flyout/flyout/hook.js +0 -45
  1254. package/src/flyout/flyout/index.js +0 -2
  1255. package/src/flyout/flyout-content/component.js +0 -53
  1256. package/src/flyout/flyout-content/index.js +0 -1
  1257. package/src/flyout/index.js +0 -1
  1258. package/src/flyout/stories/index.js +0 -24
  1259. package/src/flyout/styles.ts +0 -41
  1260. package/src/flyout/test/__snapshots__/index.js.snap +0 -186
  1261. package/src/flyout/test/index.js +0 -103
  1262. package/src/flyout/types.ts +0 -84
  1263. package/src/flyout/utils.js +0 -23
  1264. package/src/form-token-field/index.js +0 -725
  1265. package/src/form-token-field/stories/index.js +0 -102
  1266. package/src/form-token-field/token-input.js +0 -81
  1267. package/src/mobile/html-text-input/container.android.js +0 -23
  1268. package/src/mobile/html-text-input/container.ios.js +0 -50
  1269. package/src/popover/test/utils.js +0 -304
  1270. package/src/popover/utils.js +0 -396
  1271. package/src/radio-control/index.js +0 -69
  1272. package/src/radio-control/stories/index.js +0 -41
  1273. package/src/surface/stories/index.js +0 -46
  1274. package/src/textarea-control/index.js +0 -45
  1275. package/src/textarea-control/stories/index.js +0 -48
  1276. package/src/tree-select/index.js +0 -48
  1277. package/src/tree-select/stories/index.js +0 -80
  1278. package/src/utils/hooks/use-combined-ref.ts +0 -28
  1279. package/src/z-stack/stories/index.js +0 -70
@@ -1,396 +0,0 @@
1
- // @ts-nocheck
2
- /**
3
- * WordPress dependencies
4
- */
5
- import { isRTL } from '@wordpress/i18n';
6
-
7
- /**
8
- * Module constants
9
- */
10
- const HEIGHT_OFFSET = 10; // Used by the arrow and a bit of empty space.
11
-
12
- /**
13
- * Utility used to compute the popover position over the xAxis
14
- *
15
- * @param {Object} anchorRect Anchor Rect.
16
- * @param {Object} contentSize Content Size.
17
- * @param {string} xAxis Desired xAxis.
18
- * @param {string} corner Desired corner.
19
- * @param {boolean} stickyBoundaryElement The boundary element to use when
20
- * switching between sticky and normal
21
- * position.
22
- * @param {string} chosenYAxis yAxis to be used.
23
- * @param {Element} boundaryElement Boundary element.
24
- * @param {boolean} forcePosition Don't adjust position based on anchor.
25
- * @param {boolean} forceXAlignment Don't adjust alignment based on YAxis
26
- *
27
- * @return {Object} Popover xAxis position and constraints.
28
- */
29
- export function computePopoverXAxisPosition(
30
- anchorRect,
31
- contentSize,
32
- xAxis,
33
- corner,
34
- stickyBoundaryElement,
35
- chosenYAxis,
36
- boundaryElement,
37
- forcePosition,
38
- forceXAlignment
39
- ) {
40
- const { width } = contentSize;
41
-
42
- // Correct xAxis for RTL support.
43
- if ( xAxis === 'left' && isRTL() ) {
44
- xAxis = 'right';
45
- } else if ( xAxis === 'right' && isRTL() ) {
46
- xAxis = 'left';
47
- }
48
-
49
- if ( corner === 'left' && isRTL() ) {
50
- corner = 'right';
51
- } else if ( corner === 'right' && isRTL() ) {
52
- corner = 'left';
53
- }
54
-
55
- // X axis alignment choices.
56
- const anchorMidPoint = Math.round( anchorRect.left + anchorRect.width / 2 );
57
- const centerAlignment = {
58
- popoverLeft: anchorMidPoint,
59
- contentWidth:
60
- ( anchorMidPoint - width / 2 > 0 ? width / 2 : anchorMidPoint ) +
61
- ( anchorMidPoint + width / 2 > window.innerWidth
62
- ? window.innerWidth - anchorMidPoint
63
- : width / 2 ),
64
- };
65
-
66
- let leftAlignmentX = anchorRect.left;
67
-
68
- if ( corner === 'right' ) {
69
- leftAlignmentX = anchorRect.right;
70
- } else if ( chosenYAxis !== 'middle' && ! forceXAlignment ) {
71
- leftAlignmentX = anchorMidPoint;
72
- }
73
-
74
- let rightAlignmentX = anchorRect.right;
75
-
76
- if ( corner === 'left' ) {
77
- rightAlignmentX = anchorRect.left;
78
- } else if ( chosenYAxis !== 'middle' && ! forceXAlignment ) {
79
- rightAlignmentX = anchorMidPoint;
80
- }
81
-
82
- const leftAlignment = {
83
- popoverLeft: leftAlignmentX,
84
- contentWidth: leftAlignmentX - width > 0 ? width : leftAlignmentX,
85
- };
86
- const rightAlignment = {
87
- popoverLeft: rightAlignmentX,
88
- contentWidth:
89
- rightAlignmentX + width > window.innerWidth
90
- ? window.innerWidth - rightAlignmentX
91
- : width,
92
- };
93
-
94
- // Choosing the x axis.
95
- let chosenXAxis = xAxis;
96
- let contentWidth = null;
97
-
98
- if ( ! stickyBoundaryElement && ! forcePosition ) {
99
- if ( xAxis === 'center' && centerAlignment.contentWidth === width ) {
100
- chosenXAxis = 'center';
101
- } else if ( xAxis === 'left' && leftAlignment.contentWidth === width ) {
102
- chosenXAxis = 'left';
103
- } else if (
104
- xAxis === 'right' &&
105
- rightAlignment.contentWidth === width
106
- ) {
107
- chosenXAxis = 'right';
108
- } else {
109
- chosenXAxis =
110
- leftAlignment.contentWidth > rightAlignment.contentWidth
111
- ? 'left'
112
- : 'right';
113
- const chosenWidth =
114
- chosenXAxis === 'left'
115
- ? leftAlignment.contentWidth
116
- : rightAlignment.contentWidth;
117
-
118
- // Limit width of the content to the viewport width
119
- if ( width > window.innerWidth ) {
120
- contentWidth = window.innerWidth;
121
- }
122
-
123
- // If we can't find any alignment options that could fit
124
- // our content, then let's fallback to the center of the viewport.
125
- if ( chosenWidth !== width ) {
126
- chosenXAxis = 'center';
127
- centerAlignment.popoverLeft = window.innerWidth / 2;
128
- }
129
- }
130
- }
131
-
132
- let popoverLeft;
133
- if ( chosenXAxis === 'center' ) {
134
- popoverLeft = centerAlignment.popoverLeft;
135
- } else if ( chosenXAxis === 'left' ) {
136
- popoverLeft = leftAlignment.popoverLeft;
137
- } else {
138
- popoverLeft = rightAlignment.popoverLeft;
139
- }
140
-
141
- if ( boundaryElement ) {
142
- popoverLeft = Math.min(
143
- popoverLeft,
144
- boundaryElement.offsetLeft + boundaryElement.offsetWidth - width
145
- );
146
-
147
- // Avoid the popover being position beyond the left boundary if the
148
- // direction is left to right.
149
- if ( ! isRTL() ) {
150
- popoverLeft = Math.max( popoverLeft, 0 );
151
- }
152
- }
153
-
154
- return {
155
- xAxis: chosenXAxis,
156
- popoverLeft,
157
- contentWidth,
158
- };
159
- }
160
-
161
- /**
162
- * Utility used to compute the popover position over the yAxis
163
- *
164
- * @param {Object} anchorRect Anchor Rect.
165
- * @param {Object} contentSize Content Size.
166
- * @param {string} yAxis Desired yAxis.
167
- * @param {string} corner Desired corner.
168
- * @param {boolean} stickyBoundaryElement The boundary element to use when switching between sticky
169
- * and normal position.
170
- * @param {Element} anchorRef The anchor element.
171
- * @param {Element} relativeOffsetTop If applicable, top offset of the relative positioned
172
- * parent container.
173
- * @param {boolean} forcePosition Don't adjust position based on anchor.
174
- * @param {Element|null} editorWrapper Element that wraps the editor content. Used to access
175
- * scroll position to determine sticky behavior.
176
- * @return {Object} Popover xAxis position and constraints.
177
- */
178
- export function computePopoverYAxisPosition(
179
- anchorRect,
180
- contentSize,
181
- yAxis,
182
- corner,
183
- stickyBoundaryElement,
184
- anchorRef,
185
- relativeOffsetTop,
186
- forcePosition,
187
- editorWrapper
188
- ) {
189
- const { height } = contentSize;
190
-
191
- if ( stickyBoundaryElement ) {
192
- const stickyRect = stickyBoundaryElement.getBoundingClientRect();
193
- const stickyPositionTop = stickyRect.top + height - relativeOffsetTop;
194
- const stickyPositionBottom =
195
- stickyRect.bottom - height - relativeOffsetTop;
196
-
197
- if ( anchorRect.top <= stickyPositionTop ) {
198
- if ( editorWrapper ) {
199
- // If a popover cannot be positioned above the anchor, even after scrolling, we must
200
- // ensure we use the bottom position instead of the popover slot. This prevents the
201
- // popover from always restricting block content and interaction while selected if the
202
- // block is near the top of the site editor.
203
-
204
- const isRoomAboveInCanvas =
205
- height + HEIGHT_OFFSET <
206
- editorWrapper.scrollTop + anchorRect.top;
207
- if ( ! isRoomAboveInCanvas ) {
208
- return {
209
- yAxis: 'bottom',
210
- // If the bottom of the block is also below the bottom sticky position (ex -
211
- // block is also taller than the editor window), return the bottom sticky
212
- // position instead. We do this instead of the top sticky position both to
213
- // allow a smooth transition and more importantly to ensure every section of
214
- // the block can be free from popover obscuration at some point in the
215
- // scroll position.
216
- popoverTop: Math.min(
217
- anchorRect.bottom,
218
- stickyPositionBottom
219
- ),
220
- };
221
- }
222
- }
223
- // Default sticky behavior.
224
- return {
225
- yAxis,
226
- popoverTop: Math.min( anchorRect.bottom, stickyPositionTop ),
227
- };
228
- }
229
- }
230
-
231
- // Y axis alignment choices.
232
- let anchorMidPoint = anchorRect.top + anchorRect.height / 2;
233
-
234
- if ( corner === 'bottom' ) {
235
- anchorMidPoint = anchorRect.bottom;
236
- } else if ( corner === 'top' ) {
237
- anchorMidPoint = anchorRect.top;
238
- }
239
-
240
- const middleAlignment = {
241
- popoverTop: anchorMidPoint,
242
- contentHeight:
243
- ( anchorMidPoint - height / 2 > 0 ? height / 2 : anchorMidPoint ) +
244
- ( anchorMidPoint + height / 2 > window.innerHeight
245
- ? window.innerHeight - anchorMidPoint
246
- : height / 2 ),
247
- };
248
-
249
- const topAlignment = {
250
- popoverTop: anchorRect.top,
251
- contentHeight:
252
- anchorRect.top - HEIGHT_OFFSET - height > 0
253
- ? height
254
- : anchorRect.top - HEIGHT_OFFSET,
255
- };
256
- const bottomAlignment = {
257
- popoverTop: anchorRect.bottom,
258
- contentHeight:
259
- anchorRect.bottom + HEIGHT_OFFSET + height > window.innerHeight
260
- ? window.innerHeight - HEIGHT_OFFSET - anchorRect.bottom
261
- : height,
262
- };
263
-
264
- // Choosing the y axis.
265
- let chosenYAxis = yAxis;
266
- let contentHeight = null;
267
-
268
- if ( ! stickyBoundaryElement && ! forcePosition ) {
269
- if ( yAxis === 'middle' && middleAlignment.contentHeight === height ) {
270
- chosenYAxis = 'middle';
271
- } else if ( yAxis === 'top' && topAlignment.contentHeight === height ) {
272
- chosenYAxis = 'top';
273
- } else if (
274
- yAxis === 'bottom' &&
275
- bottomAlignment.contentHeight === height
276
- ) {
277
- chosenYAxis = 'bottom';
278
- } else {
279
- chosenYAxis =
280
- topAlignment.contentHeight > bottomAlignment.contentHeight
281
- ? 'top'
282
- : 'bottom';
283
- const chosenHeight =
284
- chosenYAxis === 'top'
285
- ? topAlignment.contentHeight
286
- : bottomAlignment.contentHeight;
287
- contentHeight = chosenHeight !== height ? chosenHeight : null;
288
- }
289
- }
290
-
291
- let popoverTop;
292
- if ( chosenYAxis === 'middle' ) {
293
- popoverTop = middleAlignment.popoverTop;
294
- } else if ( chosenYAxis === 'top' ) {
295
- popoverTop = topAlignment.popoverTop;
296
- } else {
297
- popoverTop = bottomAlignment.popoverTop;
298
- }
299
-
300
- return {
301
- yAxis: chosenYAxis,
302
- popoverTop,
303
- contentHeight,
304
- };
305
- }
306
-
307
- /**
308
- * Utility used to compute the popover position and the content max width/height for a popover given
309
- * its anchor rect and its content size.
310
- *
311
- * @param {Object} anchorRect Anchor Rect.
312
- * @param {Object} contentSize Content Size.
313
- * @param {string} position Position.
314
- * @param {boolean} stickyBoundaryElement The boundary element to use when switching between
315
- * sticky and normal position.
316
- * @param {Element} anchorRef The anchor element.
317
- * @param {number} relativeOffsetTop If applicable, top offset of the relative positioned
318
- * parent container.
319
- * @param {Element} boundaryElement Boundary element.
320
- * @param {boolean} forcePosition Don't adjust position based on anchor.
321
- * @param {boolean} forceXAlignment Don't adjust alignment based on YAxis
322
- * @param {Element|null} editorWrapper Element that wraps the editor content. Used to access
323
- * scroll position to determine sticky behavior.
324
- * @return {Object} Popover position and constraints.
325
- */
326
- export function computePopoverPosition(
327
- anchorRect,
328
- contentSize,
329
- position = 'top',
330
- stickyBoundaryElement,
331
- anchorRef,
332
- relativeOffsetTop,
333
- boundaryElement,
334
- forcePosition,
335
- forceXAlignment,
336
- editorWrapper
337
- ) {
338
- const [ yAxis, xAxis = 'center', corner ] = position.split( ' ' );
339
-
340
- const yAxisPosition = computePopoverYAxisPosition(
341
- anchorRect,
342
- contentSize,
343
- yAxis,
344
- corner,
345
- stickyBoundaryElement,
346
- anchorRef,
347
- relativeOffsetTop,
348
- forcePosition,
349
- editorWrapper
350
- );
351
- const xAxisPosition = computePopoverXAxisPosition(
352
- anchorRect,
353
- contentSize,
354
- xAxis,
355
- corner,
356
- stickyBoundaryElement,
357
- yAxisPosition.yAxis,
358
- boundaryElement,
359
- forcePosition,
360
- forceXAlignment
361
- );
362
-
363
- return {
364
- ...xAxisPosition,
365
- ...yAxisPosition,
366
- };
367
- }
368
-
369
- /**
370
- * Offsets the given rect by the position of the iframe that contains the
371
- * element. If the owner document is not in an iframe then it returns with the
372
- * original rect. If the popover container document and the anchor document are
373
- * the same, the original rect will also be returned.
374
- *
375
- * @param {DOMRect} rect bounds of the element
376
- * @param {Document} ownerDocument document of the element
377
- * @param {Element} container The popover container to position.
378
- *
379
- * @return {DOMRect} offsetted bounds
380
- */
381
- export function offsetIframe( rect, ownerDocument, container ) {
382
- const { defaultView } = ownerDocument;
383
- const { frameElement } = defaultView;
384
-
385
- if ( ! frameElement || ownerDocument === container.ownerDocument ) {
386
- return rect;
387
- }
388
-
389
- const iframeRect = frameElement.getBoundingClientRect();
390
- return new defaultView.DOMRect(
391
- rect.left + iframeRect.left,
392
- rect.top + iframeRect.top,
393
- rect.width,
394
- rect.height
395
- );
396
- }
@@ -1,69 +0,0 @@
1
- /**
2
- * External dependencies
3
- */
4
- import { isEmpty } from 'lodash';
5
- import classnames from 'classnames';
6
-
7
- /**
8
- * WordPress dependencies
9
- */
10
- import { useInstanceId } from '@wordpress/compose';
11
-
12
- /**
13
- * Internal dependencies
14
- */
15
- import BaseControl from '../base-control';
16
-
17
- export default function RadioControl( {
18
- label,
19
- className,
20
- selected,
21
- help,
22
- onChange,
23
- hideLabelFromVision,
24
- options = [],
25
- ...props
26
- } ) {
27
- const instanceId = useInstanceId( RadioControl );
28
- const id = `inspector-radio-control-${ instanceId }`;
29
- const onChangeValue = ( event ) => onChange( event.target.value );
30
-
31
- return (
32
- ! isEmpty( options ) && (
33
- <BaseControl
34
- label={ label }
35
- id={ id }
36
- hideLabelFromVision={ hideLabelFromVision }
37
- help={ help }
38
- className={ classnames(
39
- className,
40
- 'components-radio-control'
41
- ) }
42
- >
43
- { options.map( ( option, index ) => (
44
- <div
45
- key={ `${ id }-${ index }` }
46
- className="components-radio-control__option"
47
- >
48
- <input
49
- id={ `${ id }-${ index }` }
50
- className="components-radio-control__input"
51
- type="radio"
52
- name={ id }
53
- value={ option.value }
54
- onChange={ onChangeValue }
55
- checked={ option.value === selected }
56
- aria-describedby={
57
- !! help ? `${ id }__help` : undefined
58
- }
59
- { ...props }
60
- />
61
- <label htmlFor={ `${ id }-${ index }` }>
62
- { option.label }
63
- </label>
64
- </div>
65
- ) ) }
66
- </BaseControl>
67
- )
68
- );
69
- }
@@ -1,41 +0,0 @@
1
- /**
2
- * WordPress dependencies
3
- */
4
- import { useState } from '@wordpress/element';
5
-
6
- /**
7
- * Internal dependencies
8
- */
9
- import RadioControl from '../';
10
-
11
- export default { title: 'Components/RadioControl', component: RadioControl };
12
-
13
- const RadioControlWithState = ( props ) => {
14
- const [ option, setOption ] = useState( 'public' );
15
-
16
- return (
17
- <RadioControl { ...props } selected={ option } onChange={ setOption } />
18
- );
19
- };
20
-
21
- const options = [
22
- { label: 'Public', value: 'public' },
23
- { label: 'Private', value: 'private' },
24
- { label: 'Password Protected', value: 'password' },
25
- ];
26
-
27
- export const _default = () => {
28
- return (
29
- <RadioControlWithState label="Post visibility" options={ options } />
30
- );
31
- };
32
-
33
- export const withHelp = () => {
34
- return (
35
- <RadioControlWithState
36
- help="The visibility level for the current post"
37
- label="Post visibility"
38
- options={ options }
39
- />
40
- );
41
- };
@@ -1,46 +0,0 @@
1
- /**
2
- * External dependencies
3
- */
4
- import { boolean, number, select } from '@storybook/addon-knobs';
5
-
6
- /**
7
- * Internal dependencies
8
- */
9
- import { Surface } from '../';
10
- import { Text } from '../../text';
11
-
12
- export default {
13
- component: Surface,
14
- title: 'Components (Experimental)/Surface',
15
- parameters: {
16
- knobs: { disable: false },
17
- },
18
- };
19
-
20
- const variantOptions = {
21
- default: 'default',
22
- secondary: 'secondary',
23
- tertiary: 'tertiary',
24
- dotted: 'dotted',
25
- grid: 'grid',
26
- };
27
-
28
- export const _default = () => {
29
- const props = {
30
- backgroundSize: number( 'backgroundSize', 12 ),
31
- borderTop: boolean( 'borderTop', false ),
32
- borderBottom: boolean( 'borderBottom', false ),
33
- borderLeft: boolean( 'borderLeft', false ),
34
- borderRight: boolean( 'borderRight', false ),
35
- variant: select( 'variant', variantOptions, 'default' ),
36
- };
37
-
38
- return (
39
- <Surface
40
- { ...props }
41
- style={ { padding: 20, maxWidth: 400, margin: '20vh auto' } }
42
- >
43
- <Text>Surface</Text>
44
- </Surface>
45
- );
46
- };
@@ -1,45 +0,0 @@
1
- /**
2
- * WordPress dependencies
3
- */
4
- import { useInstanceId } from '@wordpress/compose';
5
-
6
- /**
7
- * Internal dependencies
8
- */
9
- import BaseControl from '../base-control';
10
- import { StyledTextarea } from './styles/textarea-control-styles';
11
-
12
- export default function TextareaControl( {
13
- label,
14
- hideLabelFromVision,
15
- value,
16
- help,
17
- onChange,
18
- rows = 4,
19
- className,
20
- ...props
21
- } ) {
22
- const instanceId = useInstanceId( TextareaControl );
23
- const id = `inspector-textarea-control-${ instanceId }`;
24
- const onChangeValue = ( event ) => onChange( event.target.value );
25
-
26
- return (
27
- <BaseControl
28
- label={ label }
29
- hideLabelFromVision={ hideLabelFromVision }
30
- id={ id }
31
- help={ help }
32
- className={ className }
33
- >
34
- <StyledTextarea
35
- className="components-textarea-control__input"
36
- id={ id }
37
- rows={ rows }
38
- onChange={ onChangeValue }
39
- aria-describedby={ !! help ? id + '__help' : undefined }
40
- value={ value }
41
- { ...props }
42
- />
43
- </BaseControl>
44
- );
45
- }
@@ -1,48 +0,0 @@
1
- /**
2
- * External dependencies
3
- */
4
- import { boolean, number, text } from '@storybook/addon-knobs';
5
-
6
- /**
7
- * WordPress dependencies
8
- */
9
- import { useState } from '@wordpress/element';
10
-
11
- /**
12
- * Internal dependencies
13
- */
14
- import TextareaControl from '../';
15
-
16
- export default {
17
- title: 'Components/TextareaControl',
18
- component: TextareaControl,
19
- parameters: {
20
- knobs: { disable: false },
21
- },
22
- };
23
-
24
- const TextareaControlWithState = ( props ) => {
25
- const [ value, setValue ] = useState();
26
-
27
- return (
28
- <TextareaControl { ...props } value={ value } onChange={ setValue } />
29
- );
30
- };
31
-
32
- export const _default = () => {
33
- const label = text( 'Label', 'Label Text' );
34
- const hideLabelFromVision = boolean( 'Hide Label From Vision', false );
35
- const help = text( 'Help Text', 'Help text to explain the textarea.' );
36
- const rows = number( 'Rows', 4 );
37
- const className = text( 'Class Name', '' );
38
-
39
- return (
40
- <TextareaControlWithState
41
- label={ label }
42
- hideLabelFromVision={ hideLabelFromVision }
43
- help={ help }
44
- rows={ rows }
45
- className={ className }
46
- />
47
- );
48
- };
@@ -1,48 +0,0 @@
1
- /**
2
- * External dependencies
3
- */
4
- import { unescape as unescapeString, repeat, flatMap, compact } from 'lodash';
5
-
6
- /**
7
- * WordPress dependencies
8
- */
9
- import { useMemo } from '@wordpress/element';
10
- /**
11
- * Internal dependencies
12
- */
13
- import { SelectControl } from '../';
14
-
15
- function getSelectOptions( tree, level = 0 ) {
16
- return flatMap( tree, ( treeNode ) => [
17
- {
18
- value: treeNode.id,
19
- label:
20
- repeat( '\u00A0', level * 3 ) + unescapeString( treeNode.name ),
21
- },
22
- ...getSelectOptions( treeNode.children || [], level + 1 ),
23
- ] );
24
- }
25
-
26
- export default function TreeSelect( {
27
- label,
28
- noOptionLabel,
29
- onChange,
30
- selectedId,
31
- tree,
32
- ...props
33
- } ) {
34
- const options = useMemo( () => {
35
- return compact( [
36
- noOptionLabel && { value: '', label: noOptionLabel },
37
- ...getSelectOptions( tree ),
38
- ] );
39
- }, [ noOptionLabel, tree ] );
40
-
41
- return (
42
- <SelectControl
43
- { ...{ label, options, onChange } }
44
- value={ selectedId }
45
- { ...props }
46
- />
47
- );
48
- }