@wordpress/components 19.12.0 → 19.15.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 (1409) hide show
  1. package/CHANGELOG.md +116 -3
  2. package/CONTRIBUTING.md +94 -12
  3. package/build/alignment-matrix-control/index.js +3 -3
  4. package/build/alignment-matrix-control/index.js.map +1 -1
  5. package/build/alignment-matrix-control/utils.js +1 -7
  6. package/build/alignment-matrix-control/utils.js.map +1 -1
  7. package/build/angle-picker-control/index.js +2 -2
  8. package/build/angle-picker-control/index.js.map +1 -1
  9. package/build/autocomplete/autocompleter-ui.js +4 -2
  10. package/build/autocomplete/autocompleter-ui.js.map +1 -1
  11. package/build/autocomplete/autocompleter-ui.native.js +9 -3
  12. package/build/autocomplete/autocompleter-ui.native.js.map +1 -1
  13. package/build/autocomplete/get-default-use-items.js +5 -1
  14. package/build/autocomplete/get-default-use-items.js.map +1 -1
  15. package/build/autocomplete/index.js +9 -3
  16. package/build/autocomplete/index.js.map +1 -1
  17. package/build/border-box-control/border-box-control/component.js +2 -1
  18. package/build/border-box-control/border-box-control/component.js.map +1 -1
  19. package/build/border-box-control/border-box-control-linked-button/component.js.map +1 -1
  20. package/build/border-box-control/border-box-control-split-controls/component.js +2 -1
  21. package/build/border-box-control/border-box-control-split-controls/component.js.map +1 -1
  22. package/build/border-box-control/utils.js.map +1 -1
  23. package/build/border-control/border-control/component.js +40 -4
  24. package/build/border-control/border-control/component.js.map +1 -1
  25. package/build/border-control/border-control/hook.js.map +1 -1
  26. package/build/box-control/all-input-control.js +6 -10
  27. package/build/box-control/all-input-control.js.map +1 -1
  28. package/build/box-control/axial-input-controls.js.map +1 -1
  29. package/build/box-control/index.js +4 -8
  30. package/build/box-control/index.js.map +1 -1
  31. package/build/box-control/input-controls.js +6 -10
  32. package/build/box-control/input-controls.js.map +1 -1
  33. package/build/box-control/unit-control.js +4 -4
  34. package/build/box-control/unit-control.js.map +1 -1
  35. package/build/box-control/utils.js +3 -3
  36. package/build/box-control/utils.js.map +1 -1
  37. package/build/button/index.native.js +1 -3
  38. package/build/button/index.native.js.map +1 -1
  39. package/build/checkbox-control/index.js.map +1 -1
  40. package/build/color-indicator/index.js +27 -10
  41. package/build/color-indicator/index.js.map +1 -1
  42. package/build/color-indicator/types.js +6 -0
  43. package/build/color-indicator/types.js.map +1 -0
  44. package/build/color-palette/index.js +2 -1
  45. package/build/color-palette/index.js.map +1 -1
  46. package/build/color-picker/component.js +6 -9
  47. package/build/color-picker/component.js.map +1 -1
  48. package/build/color-picker/hex-input.js +5 -4
  49. package/build/color-picker/hex-input.js.map +1 -1
  50. package/build/color-picker/index.native.js +35 -34
  51. package/build/color-picker/index.native.js.map +1 -1
  52. package/build/color-picker/input-with-slider.js +4 -3
  53. package/build/color-picker/input-with-slider.js.map +1 -1
  54. package/build/color-picker/styles.js +42 -36
  55. package/build/color-picker/styles.js.map +1 -1
  56. package/build/color-picker/use-deprecated-props.js +22 -31
  57. package/build/color-picker/use-deprecated-props.js.map +1 -1
  58. package/build/combobox-control/index.js +18 -8
  59. package/build/combobox-control/index.js.map +1 -1
  60. package/build/combobox-control/styles.js +39 -0
  61. package/build/combobox-control/styles.js.map +1 -0
  62. package/build/confirm-dialog/component.js.map +1 -1
  63. package/build/custom-gradient-bar/constants.js +1 -3
  64. package/build/custom-gradient-bar/constants.js.map +1 -1
  65. package/build/custom-gradient-bar/control-points.js +15 -8
  66. package/build/custom-gradient-bar/control-points.js.map +1 -1
  67. package/build/custom-gradient-bar/index.js +5 -5
  68. package/build/custom-gradient-bar/index.js.map +1 -1
  69. package/build/custom-gradient-bar/utils.js +5 -7
  70. package/build/custom-gradient-bar/utils.js.map +1 -1
  71. package/build/custom-gradient-picker/index.js +8 -8
  72. package/build/custom-gradient-picker/index.js.map +1 -1
  73. package/build/custom-gradient-picker/index.native.js +8 -9
  74. package/build/custom-gradient-picker/index.native.js.map +1 -1
  75. package/build/custom-gradient-picker/serializer.js +4 -7
  76. package/build/custom-gradient-picker/serializer.js.map +1 -1
  77. package/build/custom-gradient-picker/utils.js.map +1 -1
  78. package/build/custom-select-control/index.js.map +1 -1
  79. package/build/date-time/date/index.js +7 -5
  80. package/build/date-time/date/index.js.map +1 -1
  81. package/build/date-time/date-time/index.js +6 -4
  82. package/build/date-time/date-time/index.js.map +1 -1
  83. package/build/dimension-control/index.js +1 -3
  84. package/build/dimension-control/index.js.map +1 -1
  85. package/build/divider/styles.js +5 -5
  86. package/build/divider/styles.js.map +1 -1
  87. package/build/draggable/index.js.map +1 -1
  88. package/build/draggable/index.native.js +6 -1
  89. package/build/draggable/index.native.js.map +1 -1
  90. package/build/drop-zone/provider.js.map +1 -1
  91. package/build/dropdown/index.js +2 -2
  92. package/build/dropdown/index.js.map +1 -1
  93. package/build/dropdown-menu/index.js +16 -5
  94. package/build/dropdown-menu/index.js.map +1 -1
  95. package/build/dropdown-menu/index.native.js +17 -6
  96. package/build/dropdown-menu/index.native.js.map +1 -1
  97. package/build/duotone-picker/duotone-picker.js +42 -29
  98. package/build/duotone-picker/duotone-picker.js.map +1 -1
  99. package/build/elevation/hook.js +14 -14
  100. package/build/elevation/hook.js.map +1 -1
  101. package/build/external-link/index.js +20 -10
  102. package/build/external-link/index.js.map +1 -1
  103. package/build/external-link/styles/external-link-styles.js +3 -3
  104. package/build/external-link/styles/external-link-styles.js.map +1 -1
  105. package/build/external-link/types.js +6 -0
  106. package/build/external-link/types.js.map +1 -0
  107. package/build/flex/flex/hook.js +9 -5
  108. package/build/flex/flex/hook.js.map +1 -1
  109. package/build/focal-point-picker/controls.js +3 -7
  110. package/build/focal-point-picker/controls.js.map +1 -1
  111. package/build/focal-point-picker/grid.js +2 -7
  112. package/build/focal-point-picker/grid.js.map +1 -1
  113. package/build/focal-point-picker/index.js.map +1 -1
  114. package/build/focal-point-picker/index.native.js +12 -12
  115. package/build/focal-point-picker/index.native.js.map +1 -1
  116. package/build/focal-point-picker/media.js +4 -8
  117. package/build/focal-point-picker/media.js.map +1 -1
  118. package/build/focal-point-picker/tooltip/index.native.js +11 -12
  119. package/build/focal-point-picker/tooltip/index.native.js.map +1 -1
  120. package/build/font-size-picker/index.js +1 -1
  121. package/build/font-size-picker/index.js.map +1 -1
  122. package/build/form-toggle/index.js +34 -9
  123. package/build/form-toggle/index.js.map +1 -1
  124. package/build/form-toggle/types.js +6 -0
  125. package/build/form-toggle/types.js.map +1 -0
  126. package/build/form-token-field/index.js +344 -360
  127. package/build/form-token-field/index.js.map +1 -1
  128. package/build/form-token-field/styles.js +40 -0
  129. package/build/form-token-field/styles.js.map +1 -0
  130. package/build/form-token-field/suggestions-list.js +22 -21
  131. package/build/form-token-field/suggestions-list.js.map +1 -1
  132. package/build/form-token-field/token-input.js +39 -53
  133. package/build/form-token-field/token-input.js.map +1 -1
  134. package/build/form-token-field/token.js +3 -3
  135. package/build/form-token-field/token.js.map +1 -1
  136. package/build/form-token-field/types.js +6 -0
  137. package/build/form-token-field/types.js.map +1 -0
  138. package/build/gradient-picker/index.js.map +1 -1
  139. package/build/grid/component.js +7 -8
  140. package/build/grid/component.js.map +1 -1
  141. package/build/grid/hook.js +1 -5
  142. package/build/grid/hook.js.map +1 -1
  143. package/build/grid/index.js.map +1 -1
  144. package/build/grid/utils.js +4 -7
  145. package/build/grid/utils.js.map +1 -1
  146. package/build/h-stack/component.js +5 -9
  147. package/build/h-stack/component.js.map +1 -1
  148. package/build/h-stack/hook.js +8 -10
  149. package/build/h-stack/hook.js.map +1 -1
  150. package/build/h-stack/index.js.map +1 -1
  151. package/build/h-stack/utils.js +8 -19
  152. package/build/h-stack/utils.js.map +1 -1
  153. package/build/heading/component.js +0 -1
  154. package/build/heading/component.js.map +1 -1
  155. package/build/heading/hook.js.map +1 -1
  156. package/build/heading/types.js +6 -0
  157. package/build/heading/types.js.map +1 -0
  158. package/build/higher-order/navigate-regions/index.js.map +1 -1
  159. package/build/higher-order/with-focus-return/index.js.map +1 -1
  160. package/build/higher-order/with-spoken-messages/index.js.map +1 -1
  161. package/build/icon/index.js.map +1 -1
  162. package/build/input-control/index.js +5 -5
  163. package/build/input-control/index.js.map +1 -1
  164. package/build/input-control/input-field.js +10 -10
  165. package/build/input-control/input-field.js.map +1 -1
  166. package/build/input-control/reducer/reducer.js.map +1 -1
  167. package/build/input-control/utils.js +1 -1
  168. package/build/input-control/utils.js.map +1 -1
  169. package/build/menu-item/index.js +1 -3
  170. package/build/menu-item/index.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/cell.native.js.map +1 -1
  175. package/build/mobile/bottom-sheet/cycle-picker-cell.native.js +1 -7
  176. package/build/mobile/bottom-sheet/cycle-picker-cell.native.js.map +1 -1
  177. package/build/mobile/bottom-sheet/index.native.js.map +1 -1
  178. package/build/mobile/bottom-sheet/keyboard-avoiding-view.native.js +0 -1
  179. package/build/mobile/bottom-sheet/keyboard-avoiding-view.native.js.map +1 -1
  180. package/build/mobile/bottom-sheet/picker-cell.native.js.map +1 -1
  181. package/build/mobile/bottom-sheet/stepper-cell/index.native.js.map +1 -1
  182. package/build/mobile/color-settings/index.native.js.map +1 -1
  183. package/build/mobile/focal-point-settings-panel/index.native.js +1 -1
  184. package/build/mobile/focal-point-settings-panel/index.native.js.map +1 -1
  185. package/build/mobile/global-styles-context/index.native.js.map +1 -1
  186. package/build/mobile/gradient/index.native.js.map +1 -1
  187. package/build/mobile/html-text-input/index.native.js.map +1 -1
  188. package/build/mobile/image/index.native.js +4 -2
  189. package/build/mobile/image/index.native.js.map +1 -1
  190. package/build/mobile/inserter-button/index.native.js.map +1 -1
  191. package/build/mobile/link-picker/index.native.js +4 -4
  192. package/build/mobile/link-picker/index.native.js.map +1 -1
  193. package/build/mobile/link-settings/image-link-destinations-screen.native.js.map +1 -1
  194. package/build/mobile/media-edit/index.native.js.map +1 -1
  195. package/build/mobile/segmented-control/index.native.js +3 -5
  196. package/build/mobile/segmented-control/index.native.js.map +1 -1
  197. package/build/modal/index.js +18 -4
  198. package/build/modal/index.js.map +1 -1
  199. package/build/navigable-container/container.js +4 -2
  200. package/build/navigable-container/container.js.map +1 -1
  201. package/build/navigation/context.js +12 -16
  202. package/build/navigation/context.js.map +1 -1
  203. package/build/navigation/group/index.js +4 -7
  204. package/build/navigation/group/index.js.map +1 -1
  205. package/build/navigation/index.js +7 -4
  206. package/build/navigation/index.js.map +1 -1
  207. package/build/navigation/item/base.js +6 -3
  208. package/build/navigation/item/base.js.map +1 -1
  209. package/build/navigation/item/index.js +3 -3
  210. package/build/navigation/item/index.js.map +1 -1
  211. package/build/navigation/item/use-navigation-tree-item.js +2 -1
  212. package/build/navigation/item/use-navigation-tree-item.js.map +1 -1
  213. package/build/navigation/menu/menu-title-search.js +1 -7
  214. package/build/navigation/menu/menu-title-search.js.map +1 -1
  215. package/build/navigation/menu/search-no-results-found.js +1 -7
  216. package/build/navigation/menu/search-no-results-found.js.map +1 -1
  217. package/build/navigation/use-navigation-tree-nodes.js +18 -10
  218. package/build/navigation/use-navigation-tree-nodes.js.map +1 -1
  219. package/build/navigation/utils.js +4 -2
  220. package/build/navigation/utils.js.map +1 -1
  221. package/build/navigator/navigator-back-button/hook.js.map +1 -1
  222. package/build/navigator/navigator-button/hook.js.map +1 -1
  223. package/build/navigator/navigator-provider/component.js +1 -1
  224. package/build/navigator/navigator-provider/component.js.map +1 -1
  225. package/build/navigator/navigator-screen/component.js +1 -1
  226. package/build/navigator/navigator-screen/component.js.map +1 -1
  227. package/build/notice/index.js +5 -5
  228. package/build/notice/index.js.map +1 -1
  229. package/build/notice/list.js +4 -2
  230. package/build/notice/list.js.map +1 -1
  231. package/build/panel/body.js +3 -3
  232. package/build/panel/body.js.map +1 -1
  233. package/build/placeholder/index.js +26 -12
  234. package/build/placeholder/index.js.map +1 -1
  235. package/build/popover/index.js +4 -4
  236. package/build/popover/index.js.map +1 -1
  237. package/build/radio-control/index.js +43 -7
  238. package/build/radio-control/index.js.map +1 -1
  239. package/build/radio-control/types.js +6 -0
  240. package/build/radio-control/types.js.map +1 -0
  241. package/build/range-control/index.js +63 -47
  242. package/build/range-control/index.js.map +1 -1
  243. package/build/range-control/input-range.js +11 -17
  244. package/build/range-control/input-range.js.map +1 -1
  245. package/build/range-control/mark.js +5 -7
  246. package/build/range-control/mark.js.map +1 -1
  247. package/build/range-control/rail.js +10 -16
  248. package/build/range-control/rail.js.map +1 -1
  249. package/build/range-control/styles/range-control-styles.js +62 -62
  250. package/build/range-control/styles/range-control-styles.js.map +1 -1
  251. package/build/range-control/tooltip.js +5 -7
  252. package/build/range-control/tooltip.js.map +1 -1
  253. package/build/range-control/types.js +6 -0
  254. package/build/range-control/types.js.map +1 -0
  255. package/build/range-control/utils.js +27 -36
  256. package/build/range-control/utils.js.map +1 -1
  257. package/build/resizable-box/resize-tooltip/index.js +3 -3
  258. package/build/resizable-box/resize-tooltip/index.js.map +1 -1
  259. package/build/resizable-box/resize-tooltip/utils.js +5 -13
  260. package/build/resizable-box/resize-tooltip/utils.js.map +1 -1
  261. package/build/responsive-wrapper/index.js.map +1 -1
  262. package/build/scrollable/component.js +7 -8
  263. package/build/scrollable/component.js.map +1 -1
  264. package/build/scrollable/hook.js +0 -8
  265. package/build/scrollable/hook.js.map +1 -1
  266. package/build/scrollable/index.js.map +1 -1
  267. package/build/scrollable/styles.js +7 -7
  268. package/build/scrollable/styles.js.map +1 -1
  269. package/build/select-control/index.js +5 -3
  270. package/build/select-control/index.js.map +1 -1
  271. package/build/shortcut/index.js +2 -8
  272. package/build/shortcut/index.js.map +1 -1
  273. package/build/slot-fill/fill.js +1 -7
  274. package/build/slot-fill/fill.js.map +1 -1
  275. package/build/slot-fill/index.native.js +6 -8
  276. package/build/slot-fill/index.native.js.map +1 -1
  277. package/build/slot-fill/provider.js +4 -8
  278. package/build/slot-fill/provider.js.map +1 -1
  279. package/build/slot-fill/slot.js +17 -10
  280. package/build/slot-fill/slot.js.map +1 -1
  281. package/build/snackbar/index.js +7 -7
  282. package/build/snackbar/index.js.map +1 -1
  283. package/build/snackbar/list.js +3 -1
  284. package/build/snackbar/list.js.map +1 -1
  285. package/build/spacer/component.js +5 -5
  286. package/build/spacer/component.js.map +1 -1
  287. package/build/spacer/hook.js +2 -2
  288. package/build/spacer/hook.js.map +1 -1
  289. package/build/spacer/index.js.map +1 -1
  290. package/build/spinner/index.js +26 -13
  291. package/build/spinner/index.js.map +1 -1
  292. package/build/spinner/styles.js +10 -10
  293. package/build/spinner/styles.js.map +1 -1
  294. package/build/tab-panel/index.js +3 -1
  295. package/build/tab-panel/index.js.map +1 -1
  296. package/build/text/hook.js +4 -4
  297. package/build/text/hook.js.map +1 -1
  298. package/build/text/utils.js.map +1 -1
  299. package/build/text-highlight/index.js +22 -5
  300. package/build/text-highlight/index.js.map +1 -1
  301. package/build/text-highlight/types.js +6 -0
  302. package/build/text-highlight/types.js.map +1 -0
  303. package/build/tip/index.js +5 -11
  304. package/build/tip/index.js.map +1 -1
  305. package/build/tip/types.js +6 -0
  306. package/build/tip/types.js.map +1 -0
  307. package/build/toggle-control/index.js +1 -3
  308. package/build/toggle-control/index.js.map +1 -1
  309. package/build/toggle-control/index.native.js +1 -7
  310. package/build/toggle-control/index.native.js.map +1 -1
  311. package/build/toggle-group-control/toggle-group-control/toggle-group-control-backdrop.js.map +1 -1
  312. package/build/toolbar/index.js.map +1 -1
  313. package/build/toolbar-group/index.js +3 -3
  314. package/build/toolbar-group/index.js.map +1 -1
  315. package/build/tools-panel/tools-panel/hook.js.map +1 -1
  316. package/build/tools-panel/tools-panel-header/hook.js.map +1 -1
  317. package/build/tooltip/index.js +2 -1
  318. package/build/tooltip/index.js.map +1 -1
  319. package/build/tree-grid/roving-tab-index-item.js.map +1 -1
  320. package/build/tree-select/index.js +59 -6
  321. package/build/tree-select/index.js.map +1 -1
  322. package/build/tree-select/types.js +6 -0
  323. package/build/tree-select/types.js.map +1 -0
  324. package/build/truncate/component.js +7 -8
  325. package/build/truncate/component.js.map +1 -1
  326. package/build/truncate/hook.js +3 -10
  327. package/build/truncate/hook.js.map +1 -1
  328. package/build/truncate/index.js.map +1 -1
  329. package/build/truncate/styles.js +1 -1
  330. package/build/truncate/styles.js.map +1 -1
  331. package/build/truncate/utils.js +3 -16
  332. package/build/truncate/utils.js.map +1 -1
  333. package/build/ui/form-group/form-group-content.js.map +1 -1
  334. package/build/ui/utils/get-valid-children.js.map +1 -1
  335. package/build/unit-control/index.js.map +1 -1
  336. package/build/utils/math.js +17 -7
  337. package/build/utils/math.js.map +1 -1
  338. package/build/utils/unit-values.js.map +1 -1
  339. package/build/utils/values.js.map +1 -1
  340. package/build/v-stack/component.js +9 -9
  341. package/build/v-stack/component.js.map +1 -1
  342. package/build/v-stack/hook.js +0 -5
  343. package/build/v-stack/hook.js.map +1 -1
  344. package/build/v-stack/index.js.map +1 -1
  345. package/build/visually-hidden/component.js +12 -13
  346. package/build/visually-hidden/component.js.map +1 -1
  347. package/build/visually-hidden/index.js.map +1 -1
  348. package/build/visually-hidden/styles.js +3 -1
  349. package/build/visually-hidden/styles.js.map +1 -1
  350. package/build/visually-hidden/types.js +6 -0
  351. package/build/visually-hidden/types.js.map +1 -0
  352. package/build/z-stack/component.js +22 -3
  353. package/build/z-stack/component.js.map +1 -1
  354. package/build/z-stack/types.js +6 -0
  355. package/build/z-stack/types.js.map +1 -0
  356. package/build-module/alignment-matrix-control/index.js +2 -1
  357. package/build-module/alignment-matrix-control/index.js.map +1 -1
  358. package/build-module/alignment-matrix-control/utils.js +1 -6
  359. package/build-module/alignment-matrix-control/utils.js.map +1 -1
  360. package/build-module/angle-picker-control/index.js +1 -1
  361. package/build-module/angle-picker-control/index.js.map +1 -1
  362. package/build-module/autocomplete/autocompleter-ui.js +4 -2
  363. package/build-module/autocomplete/autocompleter-ui.js.map +1 -1
  364. package/build-module/autocomplete/autocompleter-ui.native.js +9 -3
  365. package/build-module/autocomplete/autocompleter-ui.native.js.map +1 -1
  366. package/build-module/autocomplete/get-default-use-items.js +3 -2
  367. package/build-module/autocomplete/get-default-use-items.js.map +1 -1
  368. package/build-module/autocomplete/index.js +7 -4
  369. package/build-module/autocomplete/index.js.map +1 -1
  370. package/build-module/border-box-control/border-box-control/component.js +2 -1
  371. package/build-module/border-box-control/border-box-control/component.js.map +1 -1
  372. package/build-module/border-box-control/border-box-control-linked-button/component.js.map +1 -1
  373. package/build-module/border-box-control/border-box-control-split-controls/component.js +2 -1
  374. package/build-module/border-box-control/border-box-control-split-controls/component.js.map +1 -1
  375. package/build-module/border-box-control/utils.js.map +1 -1
  376. package/build-module/border-control/border-control/component.js +38 -3
  377. package/build-module/border-control/border-control/component.js.map +1 -1
  378. package/build-module/border-control/border-control/hook.js.map +1 -1
  379. package/build-module/box-control/all-input-control.js +3 -5
  380. package/build-module/box-control/all-input-control.js.map +1 -1
  381. package/build-module/box-control/axial-input-controls.js.map +1 -1
  382. package/build-module/box-control/index.js +3 -6
  383. package/build-module/box-control/index.js.map +1 -1
  384. package/build-module/box-control/input-controls.js +3 -5
  385. package/build-module/box-control/input-controls.js.map +1 -1
  386. package/build-module/box-control/unit-control.js +3 -1
  387. package/build-module/box-control/unit-control.js.map +1 -1
  388. package/build-module/box-control/utils.js +4 -4
  389. package/build-module/box-control/utils.js.map +1 -1
  390. package/build-module/button/index.native.js +1 -2
  391. package/build-module/button/index.native.js.map +1 -1
  392. package/build-module/checkbox-control/index.js.map +1 -1
  393. package/build-module/color-indicator/index.js +29 -8
  394. package/build-module/color-indicator/index.js.map +1 -1
  395. package/build-module/color-indicator/types.js +2 -0
  396. package/build-module/color-indicator/types.js.map +1 -0
  397. package/build-module/color-palette/index.js +2 -1
  398. package/build-module/color-palette/index.js.map +1 -1
  399. package/build-module/color-picker/component.js +7 -8
  400. package/build-module/color-picker/component.js.map +1 -1
  401. package/build-module/color-picker/hex-input.js +4 -3
  402. package/build-module/color-picker/hex-input.js.map +1 -1
  403. package/build-module/color-picker/index.native.js +36 -35
  404. package/build-module/color-picker/index.native.js.map +1 -1
  405. package/build-module/color-picker/input-with-slider.js +4 -3
  406. package/build-module/color-picker/input-with-slider.js.map +1 -1
  407. package/build-module/color-picker/styles.js +28 -31
  408. package/build-module/color-picker/styles.js.map +1 -1
  409. package/build-module/color-picker/use-deprecated-props.js +22 -31
  410. package/build-module/color-picker/use-deprecated-props.js.map +1 -1
  411. package/build-module/combobox-control/index.js +18 -8
  412. package/build-module/combobox-control/index.js.map +1 -1
  413. package/build-module/combobox-control/styles.js +27 -0
  414. package/build-module/combobox-control/styles.js.map +1 -0
  415. package/build-module/confirm-dialog/component.js.map +1 -1
  416. package/build-module/custom-gradient-bar/constants.js +0 -1
  417. package/build-module/custom-gradient-bar/constants.js.map +1 -1
  418. package/build-module/custom-gradient-bar/control-points.js +16 -9
  419. package/build-module/custom-gradient-bar/control-points.js.map +1 -1
  420. package/build-module/custom-gradient-bar/index.js +6 -6
  421. package/build-module/custom-gradient-bar/index.js.map +1 -1
  422. package/build-module/custom-gradient-bar/utils.js +6 -8
  423. package/build-module/custom-gradient-bar/utils.js.map +1 -1
  424. package/build-module/custom-gradient-picker/index.js +8 -7
  425. package/build-module/custom-gradient-picker/index.js.map +1 -1
  426. package/build-module/custom-gradient-picker/index.native.js +8 -8
  427. package/build-module/custom-gradient-picker/index.native.js.map +1 -1
  428. package/build-module/custom-gradient-picker/serializer.js +4 -6
  429. package/build-module/custom-gradient-picker/serializer.js.map +1 -1
  430. package/build-module/custom-gradient-picker/utils.js.map +1 -1
  431. package/build-module/custom-select-control/index.js.map +1 -1
  432. package/build-module/date-time/date/index.js +7 -4
  433. package/build-module/date-time/date/index.js.map +1 -1
  434. package/build-module/date-time/date-time/index.js +5 -2
  435. package/build-module/date-time/date-time/index.js.map +1 -1
  436. package/build-module/dimension-control/index.js +1 -2
  437. package/build-module/dimension-control/index.js.map +1 -1
  438. package/build-module/divider/styles.js +5 -5
  439. package/build-module/divider/styles.js.map +1 -1
  440. package/build-module/draggable/index.js.map +1 -1
  441. package/build-module/draggable/index.native.js +6 -1
  442. package/build-module/draggable/index.native.js.map +1 -1
  443. package/build-module/drop-zone/provider.js.map +1 -1
  444. package/build-module/dropdown/index.js +2 -2
  445. package/build-module/dropdown/index.js.map +1 -1
  446. package/build-module/dropdown-menu/index.js +16 -4
  447. package/build-module/dropdown-menu/index.js.map +1 -1
  448. package/build-module/dropdown-menu/index.native.js +16 -4
  449. package/build-module/dropdown-menu/index.native.js.map +1 -1
  450. package/build-module/duotone-picker/duotone-picker.js +42 -29
  451. package/build-module/duotone-picker/duotone-picker.js.map +1 -1
  452. package/build-module/elevation/hook.js +13 -13
  453. package/build-module/elevation/hook.js.map +1 -1
  454. package/build-module/external-link/index.js +22 -8
  455. package/build-module/external-link/index.js.map +1 -1
  456. package/build-module/external-link/styles/external-link-styles.js +3 -3
  457. package/build-module/external-link/styles/external-link-styles.js.map +1 -1
  458. package/build-module/external-link/types.js +2 -0
  459. package/build-module/external-link/types.js.map +1 -0
  460. package/build-module/flex/flex/hook.js +7 -5
  461. package/build-module/flex/flex/hook.js.map +1 -1
  462. package/build-module/focal-point-picker/controls.js +3 -5
  463. package/build-module/focal-point-picker/controls.js.map +1 -1
  464. package/build-module/focal-point-picker/grid.js +2 -6
  465. package/build-module/focal-point-picker/grid.js.map +1 -1
  466. package/build-module/focal-point-picker/index.js.map +1 -1
  467. package/build-module/focal-point-picker/index.native.js +9 -9
  468. package/build-module/focal-point-picker/index.native.js.map +1 -1
  469. package/build-module/focal-point-picker/media.js +3 -5
  470. package/build-module/focal-point-picker/media.js.map +1 -1
  471. package/build-module/focal-point-picker/tooltip/index.native.js +11 -12
  472. package/build-module/focal-point-picker/tooltip/index.native.js.map +1 -1
  473. package/build-module/font-size-picker/index.js +1 -1
  474. package/build-module/font-size-picker/index.js.map +1 -1
  475. package/build-module/form-toggle/index.js +31 -7
  476. package/build-module/form-toggle/index.js.map +1 -1
  477. package/build-module/form-toggle/types.js +2 -0
  478. package/build-module/form-toggle/types.js.map +1 -0
  479. package/build-module/form-token-field/index.js +345 -363
  480. package/build-module/form-token-field/index.js.map +1 -1
  481. package/build-module/form-token-field/styles.js +28 -0
  482. package/build-module/form-token-field/styles.js.map +1 -0
  483. package/build-module/form-token-field/suggestions-list.js +27 -23
  484. package/build-module/form-token-field/suggestions-list.js.map +1 -1
  485. package/build-module/form-token-field/token-input.js +43 -58
  486. package/build-module/form-token-field/token-input.js.map +1 -1
  487. package/build-module/form-token-field/token.js +3 -1
  488. package/build-module/form-token-field/token.js.map +1 -1
  489. package/build-module/form-token-field/types.js +2 -0
  490. package/build-module/form-token-field/types.js.map +1 -0
  491. package/build-module/gradient-picker/index.js.map +1 -1
  492. package/build-module/grid/component.js +7 -8
  493. package/build-module/grid/component.js.map +1 -1
  494. package/build-module/grid/hook.js +1 -5
  495. package/build-module/grid/hook.js.map +1 -1
  496. package/build-module/grid/index.js.map +1 -1
  497. package/build-module/grid/utils.js +3 -8
  498. package/build-module/grid/utils.js.map +1 -1
  499. package/build-module/h-stack/component.js +3 -7
  500. package/build-module/h-stack/component.js.map +1 -1
  501. package/build-module/h-stack/hook.js +10 -12
  502. package/build-module/h-stack/hook.js.map +1 -1
  503. package/build-module/h-stack/index.js.map +1 -1
  504. package/build-module/h-stack/utils.js +8 -20
  505. package/build-module/h-stack/utils.js.map +1 -1
  506. package/build-module/heading/component.js +0 -1
  507. package/build-module/heading/component.js.map +1 -1
  508. package/build-module/heading/hook.js.map +1 -1
  509. package/build-module/heading/types.js +2 -0
  510. package/build-module/heading/types.js.map +1 -0
  511. package/build-module/higher-order/navigate-regions/index.js.map +1 -1
  512. package/build-module/higher-order/with-focus-return/index.js.map +1 -1
  513. package/build-module/higher-order/with-spoken-messages/index.js.map +1 -1
  514. package/build-module/icon/index.js.map +1 -1
  515. package/build-module/input-control/index.js +2 -1
  516. package/build-module/input-control/index.js.map +1 -1
  517. package/build-module/input-control/input-field.js +2 -1
  518. package/build-module/input-control/input-field.js.map +1 -1
  519. package/build-module/input-control/reducer/reducer.js.map +1 -1
  520. package/build-module/input-control/utils.js +1 -1
  521. package/build-module/input-control/utils.js.map +1 -1
  522. package/build-module/menu-item/index.js +1 -2
  523. package/build-module/menu-item/index.js.map +1 -1
  524. package/build-module/menu-items-choice/index.js +3 -5
  525. package/build-module/menu-items-choice/index.js.map +1 -1
  526. package/build-module/mobile/bottom-sheet/bottom-sheet-context.native.js.map +1 -1
  527. package/build-module/mobile/bottom-sheet/cell.native.js.map +1 -1
  528. package/build-module/mobile/bottom-sheet/cycle-picker-cell.native.js +1 -6
  529. package/build-module/mobile/bottom-sheet/cycle-picker-cell.native.js.map +1 -1
  530. package/build-module/mobile/bottom-sheet/index.native.js.map +1 -1
  531. package/build-module/mobile/bottom-sheet/keyboard-avoiding-view.native.js +0 -1
  532. package/build-module/mobile/bottom-sheet/keyboard-avoiding-view.native.js.map +1 -1
  533. package/build-module/mobile/bottom-sheet/picker-cell.native.js.map +1 -1
  534. package/build-module/mobile/bottom-sheet/stepper-cell/index.native.js.map +1 -1
  535. package/build-module/mobile/color-settings/index.native.js.map +1 -1
  536. package/build-module/mobile/focal-point-settings-panel/index.native.js +2 -2
  537. package/build-module/mobile/focal-point-settings-panel/index.native.js.map +1 -1
  538. package/build-module/mobile/global-styles-context/index.native.js.map +1 -1
  539. package/build-module/mobile/gradient/index.native.js.map +1 -1
  540. package/build-module/mobile/html-text-input/index.native.js.map +1 -1
  541. package/build-module/mobile/image/index.native.js +3 -2
  542. package/build-module/mobile/image/index.native.js.map +1 -1
  543. package/build-module/mobile/inserter-button/index.native.js.map +1 -1
  544. package/build-module/mobile/link-picker/index.native.js +4 -3
  545. package/build-module/mobile/link-picker/index.native.js.map +1 -1
  546. package/build-module/mobile/link-settings/image-link-destinations-screen.native.js.map +1 -1
  547. package/build-module/mobile/media-edit/index.native.js.map +1 -1
  548. package/build-module/mobile/segmented-control/index.native.js +3 -4
  549. package/build-module/mobile/segmented-control/index.native.js.map +1 -1
  550. package/build-module/modal/index.js +20 -6
  551. package/build-module/modal/index.js.map +1 -1
  552. package/build-module/navigable-container/container.js +5 -2
  553. package/build-module/navigable-container/container.js.map +1 -1
  554. package/build-module/navigation/context.js +3 -5
  555. package/build-module/navigation/context.js.map +1 -1
  556. package/build-module/navigation/group/index.js +3 -6
  557. package/build-module/navigation/group/index.js.map +1 -1
  558. package/build-module/navigation/index.js +7 -2
  559. package/build-module/navigation/index.js.map +1 -1
  560. package/build-module/navigation/item/base.js +5 -2
  561. package/build-module/navigation/item/base.js.map +1 -1
  562. package/build-module/navigation/item/index.js +3 -1
  563. package/build-module/navigation/item/index.js.map +1 -1
  564. package/build-module/navigation/item/use-navigation-tree-item.js +2 -1
  565. package/build-module/navigation/item/use-navigation-tree-item.js.map +1 -1
  566. package/build-module/navigation/menu/menu-title-search.js +1 -6
  567. package/build-module/navigation/menu/menu-title-search.js.map +1 -1
  568. package/build-module/navigation/menu/search-no-results-found.js +1 -6
  569. package/build-module/navigation/menu/search-no-results-found.js.map +1 -1
  570. package/build-module/navigation/use-navigation-tree-nodes.js +18 -9
  571. package/build-module/navigation/use-navigation-tree-nodes.js.map +1 -1
  572. package/build-module/navigation/utils.js +2 -2
  573. package/build-module/navigation/utils.js.map +1 -1
  574. package/build-module/navigator/navigator-back-button/hook.js.map +1 -1
  575. package/build-module/navigator/navigator-button/hook.js.map +1 -1
  576. package/build-module/navigator/navigator-provider/component.js +1 -1
  577. package/build-module/navigator/navigator-provider/component.js.map +1 -1
  578. package/build-module/navigator/navigator-screen/component.js +1 -1
  579. package/build-module/navigator/navigator-screen/component.js.map +1 -1
  580. package/build-module/notice/index.js +2 -1
  581. package/build-module/notice/index.js.map +1 -1
  582. package/build-module/notice/list.js +4 -1
  583. package/build-module/notice/list.js.map +1 -1
  584. package/build-module/panel/body.js +3 -1
  585. package/build-module/panel/body.js.map +1 -1
  586. package/build-module/placeholder/index.js +24 -11
  587. package/build-module/placeholder/index.js.map +1 -1
  588. package/build-module/popover/index.js +4 -4
  589. package/build-module/popover/index.js.map +1 -1
  590. package/build-module/radio-control/index.js +40 -7
  591. package/build-module/radio-control/index.js.map +1 -1
  592. package/build-module/radio-control/types.js +2 -0
  593. package/build-module/radio-control/types.js.map +1 -0
  594. package/build-module/range-control/index.js +57 -41
  595. package/build-module/range-control/index.js.map +1 -1
  596. package/build-module/range-control/input-range.js +7 -11
  597. package/build-module/range-control/input-range.js.map +1 -1
  598. package/build-module/range-control/mark.js +5 -6
  599. package/build-module/range-control/mark.js.map +1 -1
  600. package/build-module/range-control/rail.js +10 -15
  601. package/build-module/range-control/rail.js.map +1 -1
  602. package/build-module/range-control/styles/range-control-styles.js +62 -64
  603. package/build-module/range-control/styles/range-control-styles.js.map +1 -1
  604. package/build-module/range-control/tooltip.js +5 -6
  605. package/build-module/range-control/tooltip.js.map +1 -1
  606. package/build-module/range-control/types.js +2 -0
  607. package/build-module/range-control/types.js.map +1 -0
  608. package/build-module/range-control/utils.js +24 -32
  609. package/build-module/range-control/utils.js.map +1 -1
  610. package/build-module/resizable-box/resize-tooltip/index.js +2 -1
  611. package/build-module/resizable-box/resize-tooltip/index.js.map +1 -1
  612. package/build-module/resizable-box/resize-tooltip/utils.js +5 -11
  613. package/build-module/resizable-box/resize-tooltip/utils.js.map +1 -1
  614. package/build-module/responsive-wrapper/index.js.map +1 -1
  615. package/build-module/scrollable/component.js +7 -8
  616. package/build-module/scrollable/component.js.map +1 -1
  617. package/build-module/scrollable/hook.js +0 -8
  618. package/build-module/scrollable/hook.js.map +1 -1
  619. package/build-module/scrollable/index.js.map +1 -1
  620. package/build-module/scrollable/styles.js +7 -7
  621. package/build-module/scrollable/styles.js.map +1 -1
  622. package/build-module/select-control/index.js +3 -1
  623. package/build-module/select-control/index.js.map +1 -1
  624. package/build-module/shortcut/index.js +2 -7
  625. package/build-module/shortcut/index.js.map +1 -1
  626. package/build-module/slot-fill/fill.js +1 -6
  627. package/build-module/slot-fill/fill.js.map +1 -1
  628. package/build-module/slot-fill/index.native.js +6 -7
  629. package/build-module/slot-fill/index.native.js.map +1 -1
  630. package/build-module/slot-fill/provider.js +4 -7
  631. package/build-module/slot-fill/provider.js.map +1 -1
  632. package/build-module/slot-fill/slot.js +15 -8
  633. package/build-module/slot-fill/slot.js.map +1 -1
  634. package/build-module/snackbar/index.js +3 -1
  635. package/build-module/snackbar/index.js.map +1 -1
  636. package/build-module/snackbar/list.js +4 -1
  637. package/build-module/snackbar/list.js.map +1 -1
  638. package/build-module/spacer/component.js +3 -4
  639. package/build-module/spacer/component.js.map +1 -1
  640. package/build-module/spacer/hook.js +2 -2
  641. package/build-module/spacer/hook.js.map +1 -1
  642. package/build-module/spacer/index.js.map +1 -1
  643. package/build-module/spinner/index.js +22 -13
  644. package/build-module/spinner/index.js.map +1 -1
  645. package/build-module/spinner/styles.js +10 -10
  646. package/build-module/spinner/styles.js.map +1 -1
  647. package/build-module/tab-panel/index.js +3 -1
  648. package/build-module/tab-panel/index.js.map +1 -1
  649. package/build-module/text/hook.js +4 -4
  650. package/build-module/text/hook.js.map +1 -1
  651. package/build-module/text/utils.js.map +1 -1
  652. package/build-module/text-highlight/index.js +23 -6
  653. package/build-module/text-highlight/index.js.map +1 -1
  654. package/build-module/text-highlight/types.js +2 -0
  655. package/build-module/text-highlight/types.js.map +1 -0
  656. package/build-module/tip/index.js +6 -10
  657. package/build-module/tip/index.js.map +1 -1
  658. package/build-module/tip/types.js +2 -0
  659. package/build-module/tip/types.js.map +1 -0
  660. package/build-module/toggle-control/index.js +1 -2
  661. package/build-module/toggle-control/index.js.map +1 -1
  662. package/build-module/toggle-control/index.native.js +1 -6
  663. package/build-module/toggle-control/index.native.js.map +1 -1
  664. package/build-module/toggle-group-control/toggle-group-control/toggle-group-control-backdrop.js.map +1 -1
  665. package/build-module/toolbar/index.js.map +1 -1
  666. package/build-module/toolbar-group/index.js +3 -2
  667. package/build-module/toolbar-group/index.js.map +1 -1
  668. package/build-module/tools-panel/tools-panel/hook.js.map +1 -1
  669. package/build-module/tools-panel/tools-panel-header/hook.js.map +1 -1
  670. package/build-module/tooltip/index.js +2 -1
  671. package/build-module/tooltip/index.js.map +1 -1
  672. package/build-module/tree-grid/roving-tab-index-item.js.map +1 -1
  673. package/build-module/tree-select/index.js +56 -6
  674. package/build-module/tree-select/index.js.map +1 -1
  675. package/build-module/tree-select/types.js +2 -0
  676. package/build-module/tree-select/types.js.map +1 -0
  677. package/build-module/truncate/component.js +7 -8
  678. package/build-module/truncate/component.js.map +1 -1
  679. package/build-module/truncate/hook.js +3 -10
  680. package/build-module/truncate/hook.js.map +1 -1
  681. package/build-module/truncate/index.js.map +1 -1
  682. package/build-module/truncate/styles.js +1 -1
  683. package/build-module/truncate/styles.js.map +1 -1
  684. package/build-module/truncate/utils.js +3 -16
  685. package/build-module/truncate/utils.js.map +1 -1
  686. package/build-module/ui/form-group/form-group-content.js.map +1 -1
  687. package/build-module/ui/utils/get-valid-children.js.map +1 -1
  688. package/build-module/unit-control/index.js.map +1 -1
  689. package/build-module/utils/math.js +15 -6
  690. package/build-module/utils/math.js.map +1 -1
  691. package/build-module/utils/unit-values.js.map +1 -1
  692. package/build-module/utils/values.js.map +1 -1
  693. package/build-module/v-stack/component.js +9 -9
  694. package/build-module/v-stack/component.js.map +1 -1
  695. package/build-module/v-stack/hook.js +0 -5
  696. package/build-module/v-stack/hook.js.map +1 -1
  697. package/build-module/v-stack/index.js.map +1 -1
  698. package/build-module/visually-hidden/component.js +12 -13
  699. package/build-module/visually-hidden/component.js.map +1 -1
  700. package/build-module/visually-hidden/index.js.map +1 -1
  701. package/build-module/visually-hidden/styles.js +3 -1
  702. package/build-module/visually-hidden/styles.js.map +1 -1
  703. package/build-module/visually-hidden/types.js +2 -0
  704. package/build-module/visually-hidden/types.js.map +1 -0
  705. package/build-module/z-stack/component.js +21 -2
  706. package/build-module/z-stack/component.js.map +1 -1
  707. package/build-module/z-stack/types.js +2 -0
  708. package/build-module/z-stack/types.js.map +1 -0
  709. package/build-style/style-rtl.css +61 -22
  710. package/build-style/style.css +61 -23
  711. package/build-types/base-control/stories/index.d.ts.map +1 -1
  712. package/build-types/base-field/hook.d.ts +0 -1
  713. package/build-types/base-field/hook.d.ts.map +1 -1
  714. package/build-types/border-box-control/border-box-control/component.d.ts.map +1 -1
  715. package/build-types/border-box-control/border-box-control/hook.d.ts +0 -1
  716. package/build-types/border-box-control/border-box-control/hook.d.ts.map +1 -1
  717. package/build-types/border-box-control/border-box-control-linked-button/component.d.ts.map +1 -1
  718. package/build-types/border-box-control/border-box-control-linked-button/hook.d.ts +0 -1
  719. package/build-types/border-box-control/border-box-control-linked-button/hook.d.ts.map +1 -1
  720. package/build-types/border-box-control/border-box-control-split-controls/component.d.ts.map +1 -1
  721. package/build-types/border-box-control/border-box-control-split-controls/hook.d.ts +0 -1
  722. package/build-types/border-box-control/border-box-control-split-controls/hook.d.ts.map +1 -1
  723. package/build-types/border-box-control/border-box-control-visualizer/hook.d.ts +0 -1
  724. package/build-types/border-box-control/border-box-control-visualizer/hook.d.ts.map +1 -1
  725. package/build-types/border-box-control/utils.d.ts.map +1 -1
  726. package/build-types/border-control/border-control/component.d.ts +36 -2
  727. package/build-types/border-control/border-control/component.d.ts.map +1 -1
  728. package/build-types/border-control/border-control/hook.d.ts +1 -2
  729. package/build-types/border-control/border-control/hook.d.ts.map +1 -1
  730. package/build-types/border-control/border-control-dropdown/hook.d.ts +0 -1
  731. package/build-types/border-control/border-control-dropdown/hook.d.ts.map +1 -1
  732. package/build-types/border-control/border-control-style-picker/hook.d.ts +0 -1
  733. package/build-types/border-control/border-control-style-picker/hook.d.ts.map +1 -1
  734. package/build-types/border-control/stories/index.d.ts +33 -0
  735. package/build-types/border-control/stories/index.d.ts.map +1 -0
  736. package/build-types/button-group/index.d.ts +1 -1
  737. package/build-types/button-group/index.d.ts.map +1 -1
  738. package/build-types/card/card/hook.d.ts +0 -1
  739. package/build-types/card/card/hook.d.ts.map +1 -1
  740. package/build-types/card/card-body/hook.d.ts +0 -1
  741. package/build-types/card/card-body/hook.d.ts.map +1 -1
  742. package/build-types/card/card-divider/hook.d.ts +0 -1
  743. package/build-types/card/card-divider/hook.d.ts.map +1 -1
  744. package/build-types/card/card-footer/hook.d.ts +0 -1
  745. package/build-types/card/card-footer/hook.d.ts.map +1 -1
  746. package/build-types/card/card-header/hook.d.ts +0 -1
  747. package/build-types/card/card-header/hook.d.ts.map +1 -1
  748. package/build-types/card/card-media/hook.d.ts +0 -1
  749. package/build-types/card/card-media/hook.d.ts.map +1 -1
  750. package/build-types/checkbox-control/index.d.ts.map +1 -1
  751. package/build-types/checkbox-control/stories/index.d.ts.map +1 -1
  752. package/build-types/color-indicator/index.d.ts +16 -5
  753. package/build-types/color-indicator/index.d.ts.map +1 -1
  754. package/build-types/color-indicator/stories/index.d.ts +12 -0
  755. package/build-types/color-indicator/stories/index.d.ts.map +1 -0
  756. package/build-types/color-indicator/test/index.d.ts +2 -0
  757. package/build-types/color-indicator/test/index.d.ts.map +1 -0
  758. package/build-types/color-indicator/types.d.ts +12 -0
  759. package/build-types/color-indicator/types.d.ts.map +1 -0
  760. package/build-types/color-palette/index.d.ts.map +1 -1
  761. package/build-types/color-palette/styles.d.ts +4 -2
  762. package/build-types/color-palette/styles.d.ts.map +1 -1
  763. package/build-types/color-picker/component.d.ts.map +1 -1
  764. package/build-types/color-picker/hex-input.d.ts.map +1 -1
  765. package/build-types/color-picker/input-with-slider.d.ts.map +1 -1
  766. package/build-types/color-picker/styles.d.ts +48 -32
  767. package/build-types/color-picker/styles.d.ts.map +1 -1
  768. package/build-types/color-picker/use-deprecated-props.d.ts.map +1 -1
  769. package/build-types/confirm-dialog/component.d.ts.map +1 -1
  770. package/build-types/date-time/date/index.d.ts +1 -1
  771. package/build-types/date-time/date/index.d.ts.map +1 -1
  772. package/build-types/date-time/date-time/index.d.ts.map +1 -1
  773. package/build-types/date-time/stories/date-time.d.ts.map +1 -1
  774. package/build-types/date-time/stories/date.d.ts.map +1 -1
  775. package/build-types/date-time/time/styles.d.ts +1 -1
  776. package/build-types/date-time/types.d.ts +6 -0
  777. package/build-types/date-time/types.d.ts.map +1 -1
  778. package/build-types/divider/styles.d.ts.map +1 -1
  779. package/build-types/dropdown-menu/index.d.ts.map +1 -1
  780. package/build-types/elevation/hook.d.ts +0 -1
  781. package/build-types/elevation/hook.d.ts.map +1 -1
  782. package/build-types/external-link/index.d.ts +17 -0
  783. package/build-types/external-link/index.d.ts.map +1 -0
  784. package/build-types/external-link/stories/index.d.ts +12 -0
  785. package/build-types/external-link/stories/index.d.ts.map +1 -0
  786. package/build-types/external-link/styles/external-link-styles.d.ts +10 -0
  787. package/build-types/external-link/styles/external-link-styles.d.ts.map +1 -0
  788. package/build-types/external-link/types.d.ts +15 -0
  789. package/build-types/external-link/types.d.ts.map +1 -0
  790. package/build-types/flex/flex/hook.d.ts +0 -1
  791. package/build-types/flex/flex/hook.d.ts.map +1 -1
  792. package/build-types/flex/flex-block/hook.d.ts +0 -1
  793. package/build-types/flex/flex-block/hook.d.ts.map +1 -1
  794. package/build-types/flex/flex-item/hook.d.ts +0 -1
  795. package/build-types/flex/flex-item/hook.d.ts.map +1 -1
  796. package/build-types/form-toggle/index.d.ts +29 -0
  797. package/build-types/form-toggle/index.d.ts.map +1 -0
  798. package/build-types/form-toggle/stories/index.d.ts +12 -0
  799. package/build-types/form-toggle/stories/index.d.ts.map +1 -0
  800. package/build-types/form-toggle/test/index.d.ts +2 -0
  801. package/build-types/form-toggle/test/index.d.ts.map +1 -0
  802. package/build-types/form-toggle/types.d.ts +22 -0
  803. package/build-types/form-toggle/types.d.ts.map +1 -0
  804. package/build-types/form-token-field/index.d.ts +15 -0
  805. package/build-types/form-token-field/index.d.ts.map +1 -0
  806. package/build-types/form-token-field/stories/index.d.ts +13 -0
  807. package/build-types/form-token-field/stories/index.d.ts.map +1 -0
  808. package/build-types/form-token-field/styles.d.ts +14 -0
  809. package/build-types/form-token-field/styles.d.ts.map +1 -0
  810. package/build-types/form-token-field/suggestions-list.d.ts +10 -0
  811. package/build-types/form-token-field/suggestions-list.d.ts.map +1 -0
  812. package/build-types/form-token-field/test/lib/fixtures.d.ts +26 -0
  813. package/build-types/form-token-field/test/lib/fixtures.d.ts.map +1 -0
  814. package/build-types/form-token-field/test/lib/token-field-wrapper.d.ts +21 -0
  815. package/build-types/form-token-field/test/lib/token-field-wrapper.d.ts.map +1 -0
  816. package/build-types/form-token-field/token-input.d.ts +12 -0
  817. package/build-types/form-token-field/token-input.d.ts.map +1 -0
  818. package/build-types/form-token-field/token.d.ts +4 -0
  819. package/build-types/form-token-field/token.d.ts.map +1 -0
  820. package/build-types/form-token-field/types.d.ts +183 -0
  821. package/build-types/form-token-field/types.d.ts.map +1 -0
  822. package/build-types/grid/component.d.ts +3 -3
  823. package/build-types/grid/component.d.ts.map +1 -1
  824. package/build-types/grid/hook.d.ts +5 -3
  825. package/build-types/grid/hook.d.ts.map +1 -1
  826. package/build-types/grid/index.d.ts +2 -2
  827. package/build-types/grid/index.d.ts.map +1 -1
  828. package/build-types/grid/stories/index.d.ts +9 -0
  829. package/build-types/grid/stories/index.d.ts.map +1 -0
  830. package/build-types/grid/test/grid.d.ts +2 -0
  831. package/build-types/grid/test/grid.d.ts.map +1 -0
  832. package/build-types/grid/types.d.ts +16 -15
  833. package/build-types/grid/types.d.ts.map +1 -1
  834. package/build-types/grid/utils.d.ts +50 -69
  835. package/build-types/grid/utils.d.ts.map +1 -1
  836. package/build-types/h-stack/component.d.ts +3 -2
  837. package/build-types/h-stack/component.d.ts.map +1 -1
  838. package/build-types/h-stack/hook.d.ts +5 -4
  839. package/build-types/h-stack/hook.d.ts.map +1 -1
  840. package/build-types/h-stack/index.d.ts +2 -2
  841. package/build-types/h-stack/index.d.ts.map +1 -1
  842. package/build-types/h-stack/stories/index.d.ts +9 -0
  843. package/build-types/h-stack/stories/index.d.ts.map +1 -0
  844. package/build-types/h-stack/test/index.d.ts +2 -0
  845. package/build-types/h-stack/test/index.d.ts.map +1 -0
  846. package/build-types/h-stack/utils.d.ts +8 -4
  847. package/build-types/h-stack/utils.d.ts.map +1 -1
  848. package/build-types/heading/component.d.ts +1 -2
  849. package/build-types/heading/component.d.ts.map +1 -1
  850. package/build-types/heading/hook.d.ts +1 -29
  851. package/build-types/heading/hook.d.ts.map +1 -1
  852. package/build-types/heading/stories/index.d.ts.map +1 -1
  853. package/build-types/heading/test/index.d.ts +2 -0
  854. package/build-types/heading/test/index.d.ts.map +1 -0
  855. package/build-types/heading/types.d.ts +16 -0
  856. package/build-types/heading/types.d.ts.map +1 -0
  857. package/build-types/higher-order/with-focus-outside/index.d.ts +1 -1
  858. package/build-types/icon/index.d.ts +1 -1
  859. package/build-types/icon/index.d.ts.map +1 -1
  860. package/build-types/input-control/index.d.ts +1 -1
  861. package/build-types/input-control/index.d.ts.map +1 -1
  862. package/build-types/input-control/input-field.d.ts +1 -1
  863. package/build-types/input-control/input-field.d.ts.map +1 -1
  864. package/build-types/input-control/reducer/reducer.d.ts.map +1 -1
  865. package/build-types/input-control/stories/index.d.ts +5 -5
  866. package/build-types/input-control/stories/index.d.ts.map +1 -1
  867. package/build-types/item-group/item/hook.d.ts +0 -1
  868. package/build-types/item-group/item/hook.d.ts.map +1 -1
  869. package/build-types/item-group/item-group/hook.d.ts +0 -1
  870. package/build-types/item-group/item-group/hook.d.ts.map +1 -1
  871. package/build-types/menu-item/index.d.ts.map +1 -1
  872. package/build-types/navigator/navigator-back-button/hook.d.ts +0 -1
  873. package/build-types/navigator/navigator-back-button/hook.d.ts.map +1 -1
  874. package/build-types/navigator/navigator-button/hook.d.ts +0 -1
  875. package/build-types/navigator/navigator-button/hook.d.ts.map +1 -1
  876. package/build-types/navigator/navigator-provider/component.d.ts.map +1 -1
  877. package/build-types/number-control/styles/number-control-styles.d.ts +1 -1
  878. package/build-types/popover/index.d.ts.map +1 -1
  879. package/build-types/radio-control/index.d.ts +31 -0
  880. package/build-types/radio-control/index.d.ts.map +1 -0
  881. package/build-types/radio-control/stories/index.d.ts +12 -0
  882. package/build-types/radio-control/stories/index.d.ts.map +1 -0
  883. package/build-types/radio-control/types.d.ts +29 -0
  884. package/build-types/radio-control/types.d.ts.map +1 -0
  885. package/build-types/range-control/index.d.ts +54 -29
  886. package/build-types/range-control/index.d.ts.map +1 -1
  887. package/build-types/range-control/input-range.d.ts +7 -10
  888. package/build-types/range-control/input-range.d.ts.map +1 -1
  889. package/build-types/range-control/mark.d.ts +4 -7
  890. package/build-types/range-control/mark.d.ts.map +1 -1
  891. package/build-types/range-control/rail.d.ts +4 -9
  892. package/build-types/range-control/rail.d.ts.map +1 -1
  893. package/build-types/range-control/stories/index.d.ts +48 -0
  894. package/build-types/range-control/stories/index.d.ts.map +1 -0
  895. package/build-types/range-control/styles/range-control-styles.d.ts +32 -40
  896. package/build-types/range-control/styles/range-control-styles.d.ts.map +1 -1
  897. package/build-types/range-control/test/index.d.ts +2 -0
  898. package/build-types/range-control/test/index.d.ts.map +1 -0
  899. package/build-types/range-control/tooltip.d.ts +4 -11
  900. package/build-types/range-control/tooltip.d.ts.map +1 -1
  901. package/build-types/range-control/types.d.ts +302 -0
  902. package/build-types/range-control/types.d.ts.map +1 -0
  903. package/build-types/range-control/utils.d.ts +15 -33
  904. package/build-types/range-control/utils.d.ts.map +1 -1
  905. package/build-types/resizable-box/resize-tooltip/index.d.ts.map +1 -1
  906. package/build-types/resizable-box/resize-tooltip/utils.d.ts.map +1 -1
  907. package/build-types/scrollable/component.d.ts +3 -3
  908. package/build-types/scrollable/component.d.ts.map +1 -1
  909. package/build-types/scrollable/hook.d.ts +5 -3
  910. package/build-types/scrollable/hook.d.ts.map +1 -1
  911. package/build-types/scrollable/index.d.ts +2 -2
  912. package/build-types/scrollable/index.d.ts.map +1 -1
  913. package/build-types/scrollable/stories/index.d.ts +9 -0
  914. package/build-types/scrollable/stories/index.d.ts.map +1 -0
  915. package/build-types/scrollable/styles.d.ts +7 -7
  916. package/build-types/scrollable/styles.d.ts.map +1 -1
  917. package/build-types/scrollable/test/index.d.ts +2 -0
  918. package/build-types/scrollable/test/index.d.ts.map +1 -0
  919. package/build-types/scrollable/types.d.ts +9 -6
  920. package/build-types/scrollable/types.d.ts.map +1 -1
  921. package/build-types/select-control/index.d.ts +1 -1
  922. package/build-types/select-control/index.d.ts.map +1 -1
  923. package/build-types/select-control/stories/index.d.ts +3 -3
  924. package/build-types/select-control/stories/index.d.ts.map +1 -1
  925. package/build-types/shortcut/index.d.ts.map +1 -1
  926. package/build-types/slot-fill/fill.d.ts.map +1 -1
  927. package/build-types/slot-fill/provider.d.ts.map +1 -1
  928. package/build-types/slot-fill/slot.d.ts.map +1 -1
  929. package/build-types/spacer/component.d.ts +3 -4
  930. package/build-types/spacer/component.d.ts.map +1 -1
  931. package/build-types/spacer/hook.d.ts +2 -3
  932. package/build-types/spacer/hook.d.ts.map +1 -1
  933. package/build-types/spacer/index.d.ts +1 -1
  934. package/build-types/spacer/index.d.ts.map +1 -1
  935. package/build-types/spacer/stories/index.d.ts +12 -0
  936. package/build-types/spacer/stories/index.d.ts.map +1 -0
  937. package/build-types/spacer/test/index.d.ts +2 -0
  938. package/build-types/spacer/test/index.d.ts.map +1 -0
  939. package/build-types/spacer/types.d.ts +41 -29
  940. package/build-types/spacer/types.d.ts.map +1 -1
  941. package/build-types/spinner/index.d.ts +16 -15
  942. package/build-types/spinner/index.d.ts.map +1 -1
  943. package/build-types/spinner/stories/index.d.ts +13 -0
  944. package/build-types/spinner/stories/index.d.ts.map +1 -0
  945. package/build-types/spinner/styles.d.ts +4 -3
  946. package/build-types/spinner/styles.d.ts.map +1 -1
  947. package/build-types/surface/hook.d.ts +0 -1
  948. package/build-types/surface/hook.d.ts.map +1 -1
  949. package/build-types/text/hook.d.ts +0 -1
  950. package/build-types/text/hook.d.ts.map +1 -1
  951. package/build-types/text/types.d.ts +1 -1
  952. package/build-types/text/types.d.ts.map +1 -1
  953. package/build-types/text/utils.d.ts.map +1 -1
  954. package/build-types/text-control/index.d.ts +1 -1
  955. package/build-types/text-control/index.d.ts.map +1 -1
  956. package/build-types/text-control/stories/index.d.ts.map +1 -1
  957. package/build-types/text-highlight/index.d.ts +23 -0
  958. package/build-types/text-highlight/index.d.ts.map +1 -0
  959. package/build-types/text-highlight/stories/index.d.ts +12 -0
  960. package/build-types/text-highlight/stories/index.d.ts.map +1 -0
  961. package/build-types/text-highlight/test/index.d.ts +2 -0
  962. package/build-types/text-highlight/test/index.d.ts.map +1 -0
  963. package/build-types/text-highlight/types.d.ts +17 -0
  964. package/build-types/text-highlight/types.d.ts.map +1 -0
  965. package/build-types/tip/index.d.ts +5 -14
  966. package/build-types/tip/index.d.ts.map +1 -1
  967. package/build-types/tip/stories/index.d.ts +12 -0
  968. package/build-types/tip/stories/index.d.ts.map +1 -0
  969. package/build-types/tip/types.d.ts +11 -0
  970. package/build-types/tip/types.d.ts.map +1 -0
  971. package/build-types/toggle-group-control/toggle-group-control/toggle-group-control-backdrop.d.ts.map +1 -1
  972. package/build-types/tools-panel/tools-panel/hook.d.ts +0 -1
  973. package/build-types/tools-panel/tools-panel/hook.d.ts.map +1 -1
  974. package/build-types/tools-panel/tools-panel-header/hook.d.ts +0 -1
  975. package/build-types/tools-panel/tools-panel-header/hook.d.ts.map +1 -1
  976. package/build-types/tools-panel/tools-panel-item/hook.d.ts +0 -1
  977. package/build-types/tools-panel/tools-panel-item/hook.d.ts.map +1 -1
  978. package/build-types/tooltip/index.d.ts.map +1 -1
  979. package/build-types/tree-select/index.d.ts +53 -0
  980. package/build-types/tree-select/index.d.ts.map +1 -0
  981. package/build-types/tree-select/stories/index.d.ts +12 -0
  982. package/build-types/tree-select/stories/index.d.ts.map +1 -0
  983. package/build-types/tree-select/types.d.ts +30 -0
  984. package/build-types/tree-select/types.d.ts.map +1 -0
  985. package/build-types/truncate/component.d.ts +3 -3
  986. package/build-types/truncate/component.d.ts.map +1 -1
  987. package/build-types/truncate/hook.d.ts +5 -3
  988. package/build-types/truncate/hook.d.ts.map +1 -1
  989. package/build-types/truncate/index.d.ts +2 -2
  990. package/build-types/truncate/index.d.ts.map +1 -1
  991. package/build-types/truncate/stories/index.d.ts +13 -0
  992. package/build-types/truncate/stories/index.d.ts.map +1 -0
  993. package/build-types/truncate/styles.d.ts +1 -1
  994. package/build-types/truncate/styles.d.ts.map +1 -1
  995. package/build-types/truncate/test/index.d.ts +2 -0
  996. package/build-types/truncate/test/index.d.ts.map +1 -0
  997. package/build-types/truncate/types.d.ts +22 -11
  998. package/build-types/truncate/types.d.ts.map +1 -1
  999. package/build-types/truncate/utils.d.ts +17 -28
  1000. package/build-types/truncate/utils.d.ts.map +1 -1
  1001. package/build-types/ui/context/wordpress-component.d.ts.map +1 -1
  1002. package/build-types/ui/control-group/hook.d.ts +0 -1
  1003. package/build-types/ui/control-group/hook.d.ts.map +1 -1
  1004. package/build-types/ui/control-label/hook.d.ts +0 -1
  1005. package/build-types/ui/control-label/hook.d.ts.map +1 -1
  1006. package/build-types/ui/form-group/form-group.d.ts +1 -1
  1007. package/build-types/ui/form-group/types.d.ts +1 -1
  1008. package/build-types/ui/form-group/types.d.ts.map +1 -1
  1009. package/build-types/ui/form-group/use-form-group.d.ts +5 -7
  1010. package/build-types/ui/form-group/use-form-group.d.ts.map +1 -1
  1011. package/build-types/ui/utils/get-valid-children.d.ts +2 -2
  1012. package/build-types/ui/utils/get-valid-children.d.ts.map +1 -1
  1013. package/build-types/unit-control/index.d.ts +1 -1
  1014. package/build-types/unit-control/index.d.ts.map +1 -1
  1015. package/build-types/unit-control/stories/index.d.ts.map +1 -1
  1016. package/build-types/utils/math.d.ts +10 -0
  1017. package/build-types/utils/math.d.ts.map +1 -1
  1018. package/build-types/utils/unit-values.d.ts.map +1 -1
  1019. package/build-types/utils/values.d.ts.map +1 -1
  1020. package/build-types/v-stack/component.d.ts +5 -4
  1021. package/build-types/v-stack/component.d.ts.map +1 -1
  1022. package/build-types/v-stack/hook.d.ts +5 -4
  1023. package/build-types/v-stack/hook.d.ts.map +1 -1
  1024. package/build-types/v-stack/index.d.ts +2 -2
  1025. package/build-types/v-stack/index.d.ts.map +1 -1
  1026. package/build-types/v-stack/stories/index.d.ts +9 -0
  1027. package/build-types/v-stack/stories/index.d.ts.map +1 -0
  1028. package/build-types/v-stack/test/index.d.ts +2 -0
  1029. package/build-types/v-stack/test/index.d.ts.map +1 -0
  1030. package/build-types/v-stack/types.d.ts +21 -1
  1031. package/build-types/v-stack/types.d.ts.map +1 -1
  1032. package/build-types/visually-hidden/component.d.ts +8 -10
  1033. package/build-types/visually-hidden/component.d.ts.map +1 -1
  1034. package/build-types/visually-hidden/index.d.ts +1 -1
  1035. package/build-types/visually-hidden/index.d.ts.map +1 -1
  1036. package/build-types/visually-hidden/stories/index.d.ts +14 -0
  1037. package/build-types/visually-hidden/stories/index.d.ts.map +1 -0
  1038. package/build-types/visually-hidden/styles.d.ts +5 -2
  1039. package/build-types/visually-hidden/styles.d.ts.map +1 -1
  1040. package/build-types/visually-hidden/test/index.d.ts +2 -0
  1041. package/build-types/visually-hidden/test/index.d.ts.map +1 -0
  1042. package/build-types/visually-hidden/types.d.ts +11 -0
  1043. package/build-types/visually-hidden/types.d.ts.map +1 -0
  1044. package/build-types/z-stack/component.d.ts +18 -28
  1045. package/build-types/z-stack/component.d.ts.map +1 -1
  1046. package/build-types/z-stack/stories/index.d.ts +6 -0
  1047. package/build-types/z-stack/stories/index.d.ts.map +1 -0
  1048. package/build-types/z-stack/types.d.ts +33 -0
  1049. package/build-types/z-stack/types.d.ts.map +1 -0
  1050. package/package.json +18 -17
  1051. package/src/alignment-matrix-control/index.js +2 -1
  1052. package/src/alignment-matrix-control/utils.js +1 -6
  1053. package/src/angle-picker-control/index.js +1 -1
  1054. package/src/autocomplete/autocompleter-ui.js +4 -1
  1055. package/src/autocomplete/autocompleter-ui.native.js +8 -2
  1056. package/src/autocomplete/get-default-use-items.js +3 -2
  1057. package/src/autocomplete/index.js +7 -10
  1058. package/src/base-control/stories/index.tsx +2 -3
  1059. package/src/border-box-control/border-box-control/component.tsx +1 -0
  1060. package/src/border-box-control/border-box-control-linked-button/component.tsx +2 -5
  1061. package/src/border-box-control/border-box-control-split-controls/component.tsx +1 -0
  1062. package/src/border-box-control/utils.ts +5 -2
  1063. package/src/border-control/border-control/component.tsx +41 -4
  1064. package/src/border-control/border-control/hook.ts +3 -4
  1065. package/src/border-control/stories/index.tsx +150 -0
  1066. package/src/box-control/all-input-control.js +2 -4
  1067. package/src/box-control/axial-input-controls.js +4 -6
  1068. package/src/box-control/index.js +3 -6
  1069. package/src/box-control/input-controls.js +33 -36
  1070. package/src/box-control/unit-control.js +2 -1
  1071. package/src/box-control/utils.js +4 -4
  1072. package/src/button/README.md +1 -1
  1073. package/src/button/index.native.js +1 -2
  1074. package/src/card/stories/index.js +10 -5
  1075. package/src/checkbox-control/index.tsx +2 -3
  1076. package/src/checkbox-control/stories/index.tsx +2 -3
  1077. package/src/checkbox-control/test/index.tsx +2 -1
  1078. package/src/color-indicator/README.md +7 -9
  1079. package/src/color-indicator/index.tsx +47 -0
  1080. package/src/color-indicator/stories/index.tsx +37 -0
  1081. package/src/color-indicator/test/__snapshots__/index.tsx.snap +11 -0
  1082. package/src/color-indicator/test/{index.js → index.tsx} +4 -4
  1083. package/src/color-indicator/types.ts +12 -0
  1084. package/src/color-palette/index.js +5 -1
  1085. package/src/color-picker/component.tsx +12 -11
  1086. package/src/color-picker/hex-input.tsx +3 -2
  1087. package/src/color-picker/index.native.js +27 -31
  1088. package/src/color-picker/input-with-slider.tsx +4 -2
  1089. package/src/color-picker/styles.ts +20 -6
  1090. package/src/color-picker/use-deprecated-props.ts +24 -43
  1091. package/src/combobox-control/index.js +18 -8
  1092. package/src/combobox-control/stories/index.js +3 -2
  1093. package/src/combobox-control/style.scss +1 -1
  1094. package/src/combobox-control/styles.ts +27 -0
  1095. package/src/confirm-dialog/component.tsx +7 -8
  1096. package/src/custom-gradient-bar/constants.js +2 -2
  1097. package/src/custom-gradient-bar/control-points.js +20 -16
  1098. package/src/custom-gradient-bar/index.js +11 -11
  1099. package/src/custom-gradient-bar/test/utils.js +79 -0
  1100. package/src/custom-gradient-bar/utils.js +6 -18
  1101. package/src/custom-gradient-picker/index.js +4 -11
  1102. package/src/custom-gradient-picker/index.native.js +3 -11
  1103. package/src/custom-gradient-picker/serializer.js +5 -11
  1104. package/src/custom-gradient-picker/style.scss +1 -3
  1105. package/src/custom-gradient-picker/utils.js +4 -3
  1106. package/src/custom-select-control/index.js +2 -1
  1107. package/src/custom-select-control/stories/index.js +1 -2
  1108. package/src/date-time/README.md +7 -0
  1109. package/src/date-time/date/index.tsx +4 -2
  1110. package/src/date-time/date/style.scss +10 -0
  1111. package/src/date-time/date/test/index.tsx +1 -1
  1112. package/src/date-time/date-time/index.tsx +8 -8
  1113. package/src/date-time/stories/date-time.tsx +4 -6
  1114. package/src/date-time/stories/date.tsx +2 -3
  1115. package/src/date-time/time/test/index.tsx +12 -12
  1116. package/src/date-time/types.ts +7 -0
  1117. package/src/dimension-control/README.md +5 -2
  1118. package/src/dimension-control/index.js +1 -2
  1119. package/src/dimension-control/test/index.test.js +7 -7
  1120. package/src/divider/styles.ts +2 -3
  1121. package/src/draggable/index.js +3 -3
  1122. package/src/draggable/index.native.js +12 -4
  1123. package/src/drop-zone/provider.js +1 -2
  1124. package/src/dropdown/index.js +2 -2
  1125. package/src/dropdown-menu/index.js +13 -4
  1126. package/src/dropdown-menu/index.native.js +13 -5
  1127. package/src/duotone-picker/duotone-picker.js +58 -37
  1128. package/src/duotone-picker/style.scss +19 -0
  1129. package/src/elevation/hook.js +11 -11
  1130. package/src/external-link/README.md +18 -0
  1131. package/src/external-link/{index.js → index.tsx} +35 -9
  1132. package/src/external-link/stories/index.tsx +36 -0
  1133. package/src/external-link/styles/{external-link-styles.js → external-link-styles.ts} +0 -0
  1134. package/src/external-link/types.ts +15 -0
  1135. package/src/flex/flex/README.md +5 -10
  1136. package/src/flex/flex/hook.js +4 -1
  1137. package/src/flex/flex-item/README.md +1 -1
  1138. package/src/focal-point-picker/controls.js +1 -5
  1139. package/src/focal-point-picker/grid.js +2 -5
  1140. package/src/focal-point-picker/index.js +2 -8
  1141. package/src/focal-point-picker/index.native.js +9 -9
  1142. package/src/focal-point-picker/media.js +2 -5
  1143. package/src/focal-point-picker/tooltip/index.native.js +10 -11
  1144. package/src/font-size-picker/index.js +3 -1
  1145. package/src/form-toggle/README.md +10 -11
  1146. package/src/form-toggle/index.tsx +71 -0
  1147. package/src/form-toggle/stories/index.tsx +52 -0
  1148. package/src/form-toggle/test/__snapshots__/index.tsx.snap +54 -0
  1149. package/src/form-toggle/test/index.tsx +102 -0
  1150. package/src/form-toggle/types.ts +22 -0
  1151. package/src/form-token-field/index.tsx +715 -0
  1152. package/src/form-token-field/stories/index.tsx +103 -0
  1153. package/src/form-token-field/style.scss +4 -8
  1154. package/src/form-token-field/styles.ts +32 -0
  1155. package/src/form-token-field/{suggestions-list.js → suggestions-list.tsx} +43 -29
  1156. package/src/form-token-field/test/index.js +70 -40
  1157. package/src/form-token-field/test/lib/token-field-wrapper.tsx +71 -0
  1158. package/src/form-token-field/token-input.tsx +76 -0
  1159. package/src/form-token-field/{token.js → token.tsx} +4 -2
  1160. package/src/form-token-field/types.ts +185 -0
  1161. package/src/gradient-picker/index.js +4 -3
  1162. package/src/grid/README.md +33 -19
  1163. package/src/grid/{component.js → component.tsx} +13 -9
  1164. package/src/grid/{hook.js → hook.ts} +5 -5
  1165. package/src/grid/{index.js → index.ts} +0 -0
  1166. package/src/grid/stories/index.tsx +72 -0
  1167. package/src/grid/test/{grid.js → grid.tsx} +4 -4
  1168. package/src/grid/types.ts +16 -17
  1169. package/src/grid/{utils.js → utils.ts} +9 -7
  1170. package/src/guide/style.scss +1 -0
  1171. package/src/h-stack/{component.js → component.tsx} +8 -8
  1172. package/src/h-stack/{hook.js → hook.tsx} +21 -16
  1173. package/src/h-stack/{index.js → index.ts} +0 -0
  1174. package/src/h-stack/stories/index.tsx +92 -0
  1175. package/src/h-stack/test/__snapshots__/{index.js.snap → index.tsx.snap} +0 -0
  1176. package/src/h-stack/test/{index.js → index.tsx} +0 -0
  1177. package/src/h-stack/{utils.js → utils.ts} +16 -16
  1178. package/src/heading/README.md +4 -3
  1179. package/src/heading/component.tsx +2 -2
  1180. package/src/heading/hook.ts +6 -46
  1181. package/src/heading/stories/index.tsx +5 -1
  1182. package/src/heading/test/__snapshots__/{index.js.snap → index.tsx.snap} +0 -0
  1183. package/src/heading/test/index.tsx +68 -0
  1184. package/src/heading/types.ts +29 -0
  1185. package/src/higher-order/navigate-regions/README.md +4 -1
  1186. package/src/higher-order/navigate-regions/index.js +7 -5
  1187. package/src/higher-order/with-filters/test/index.js +43 -36
  1188. package/src/higher-order/with-focus-return/index.js +14 -13
  1189. package/src/higher-order/with-spoken-messages/index.js +8 -7
  1190. package/src/higher-order/with-spoken-messages/test/index.js +1 -1
  1191. package/src/icon/index.tsx +3 -3
  1192. package/src/input-control/index.tsx +2 -1
  1193. package/src/input-control/input-field.tsx +2 -1
  1194. package/src/input-control/reducer/reducer.ts +23 -21
  1195. package/src/input-control/test/index.js +106 -31
  1196. package/src/input-control/utils.ts +1 -1
  1197. package/src/item-group/stories/index.js +2 -1
  1198. package/src/menu-item/index.js +1 -2
  1199. package/src/menu-item/test/index.js +2 -1
  1200. package/src/menu-items-choice/index.js +2 -5
  1201. package/src/mobile/bottom-sheet/bottom-sheet-context.native.js +2 -4
  1202. package/src/mobile/bottom-sheet/cell.native.js +2 -3
  1203. package/src/mobile/bottom-sheet/cycle-picker-cell.native.js +3 -5
  1204. package/src/mobile/bottom-sheet/index.native.js +14 -17
  1205. package/src/mobile/bottom-sheet/keyboard-avoiding-view.native.js +2 -7
  1206. package/src/mobile/bottom-sheet/picker-cell.native.js +2 -7
  1207. package/src/mobile/bottom-sheet/stepper-cell/index.native.js +4 -6
  1208. package/src/mobile/color-settings/index.native.js +2 -4
  1209. package/src/mobile/focal-point-settings-panel/index.native.js +2 -2
  1210. package/src/mobile/global-styles-context/index.native.js +8 -7
  1211. package/src/mobile/gradient/index.native.js +12 -9
  1212. package/src/mobile/gradient/test/index.native.js +1 -3
  1213. package/src/mobile/html-text-input/index.native.js +2 -3
  1214. package/src/mobile/image/index.native.js +3 -2
  1215. package/src/mobile/inserter-button/index.native.js +2 -6
  1216. package/src/mobile/link-picker/index.native.js +2 -3
  1217. package/src/mobile/link-settings/image-link-destinations-screen.native.js +6 -2
  1218. package/src/mobile/media-edit/index.native.js +2 -3
  1219. package/src/mobile/segmented-control/index.native.js +9 -9
  1220. package/src/mobile/utils/test/index.native.js +3 -12
  1221. package/src/modal/index.js +22 -3
  1222. package/src/modal/stories/index.js +17 -1
  1223. package/src/modal/style.scss +9 -18
  1224. package/src/navigable-container/container.js +3 -2
  1225. package/src/navigable-container/test/menu.js +1 -2
  1226. package/src/navigable-container/test/tabbable.js +1 -2
  1227. package/src/navigation/context.js +2 -5
  1228. package/src/navigation/group/index.js +8 -3
  1229. package/src/navigation/index.js +5 -1
  1230. package/src/navigation/item/base.js +5 -3
  1231. package/src/navigation/item/index.js +2 -1
  1232. package/src/navigation/item/use-navigation-tree-item.js +2 -0
  1233. package/src/navigation/menu/menu-title-search.js +3 -6
  1234. package/src/navigation/menu/search-no-results-found.js +3 -6
  1235. package/src/navigation/stories/controlled-state.js +1 -1
  1236. package/src/navigation/stories/more-examples.js +2 -3
  1237. package/src/navigation/test/index.js +252 -52
  1238. package/src/navigation/use-navigation-tree-nodes.js +11 -10
  1239. package/src/navigation/utils.js +2 -2
  1240. package/src/navigator/navigator-back-button/hook.ts +14 -12
  1241. package/src/navigator/navigator-button/hook.ts +14 -13
  1242. package/src/navigator/navigator-provider/component.tsx +2 -6
  1243. package/src/navigator/navigator-screen/component.tsx +3 -3
  1244. package/src/notice/index.js +2 -1
  1245. package/src/notice/list.js +3 -1
  1246. package/src/number-control/stories/index.js +24 -24
  1247. package/src/panel/body.js +2 -1
  1248. package/src/placeholder/README.md +7 -6
  1249. package/src/placeholder/index.js +27 -10
  1250. package/src/placeholder/style.scss +23 -0
  1251. package/src/popover/README.md +2 -2
  1252. package/src/popover/index.js +7 -4
  1253. package/src/radio-control/README.md +17 -23
  1254. package/src/radio-control/index.tsx +107 -0
  1255. package/src/radio-control/stories/index.tsx +72 -0
  1256. package/src/radio-control/types.ts +32 -0
  1257. package/src/range-control/README.md +107 -79
  1258. package/src/range-control/{index.js → index.tsx} +81 -49
  1259. package/src/range-control/{input-range.js → input-range.tsx} +13 -12
  1260. package/src/range-control/{mark.js → mark.tsx} +15 -9
  1261. package/src/range-control/{rail.js → rail.tsx} +40 -23
  1262. package/src/range-control/stories/index.tsx +244 -0
  1263. package/src/range-control/styles/{range-control-styles.js → range-control-styles.ts} +28 -24
  1264. package/src/range-control/test/index.tsx +311 -0
  1265. package/src/range-control/{tooltip.js → tooltip.tsx} +19 -14
  1266. package/src/range-control/types.ts +326 -0
  1267. package/src/range-control/utils.ts +132 -0
  1268. package/src/resizable-box/resize-tooltip/index.tsx +2 -1
  1269. package/src/resizable-box/resize-tooltip/utils.ts +3 -8
  1270. package/src/responsive-wrapper/index.js +2 -4
  1271. package/src/sandbox/test/index.js +4 -6
  1272. package/src/scrollable/README.md +14 -8
  1273. package/src/scrollable/{component.js → component.tsx} +13 -10
  1274. package/src/scrollable/{hook.js → hook.ts} +5 -7
  1275. package/src/scrollable/{index.js → index.ts} +0 -0
  1276. package/src/scrollable/stories/{index.js → index.tsx} +29 -34
  1277. package/src/scrollable/{styles.js → styles.ts} +0 -0
  1278. package/src/scrollable/test/__snapshots__/{index.js.snap → index.tsx.snap} +1 -0
  1279. package/src/scrollable/test/index.tsx +34 -0
  1280. package/src/scrollable/types.ts +10 -5
  1281. package/src/select-control/index.tsx +3 -1
  1282. package/src/select-control/stories/index.tsx +3 -4
  1283. package/src/select-control/test/select-control.tsx +22 -15
  1284. package/src/shortcut/index.js +2 -7
  1285. package/src/slot-fill/fill.js +1 -5
  1286. package/src/slot-fill/index.native.js +2 -7
  1287. package/src/slot-fill/provider.js +3 -7
  1288. package/src/slot-fill/slot.js +31 -24
  1289. package/src/slot-fill/test/slot.js +2 -3
  1290. package/src/snackbar/index.js +1 -1
  1291. package/src/snackbar/list.js +2 -1
  1292. package/src/spacer/README.md +43 -37
  1293. package/src/spacer/component.tsx +5 -6
  1294. package/src/spacer/hook.ts +4 -2
  1295. package/src/spacer/index.ts +1 -1
  1296. package/src/spacer/stories/index.tsx +70 -0
  1297. package/src/spacer/test/__snapshots__/{index.js.snap → index.tsx.snap} +1 -0
  1298. package/src/spacer/test/index.tsx +149 -0
  1299. package/src/spacer/types.ts +41 -29
  1300. package/src/spinner/{index.js → index.tsx} +23 -9
  1301. package/src/spinner/stories/index.tsx +32 -0
  1302. package/src/spinner/{styles.js → styles.ts} +0 -0
  1303. package/src/style.scss +1 -0
  1304. package/src/tab-panel/README.md +1 -1
  1305. package/src/tab-panel/index.js +3 -1
  1306. package/src/text/hook.js +4 -1
  1307. package/src/text/types.ts +1 -1
  1308. package/src/text/utils.js +2 -3
  1309. package/src/text-control/stories/index.tsx +4 -6
  1310. package/src/text-highlight/README.md +6 -6
  1311. package/src/text-highlight/index.tsx +49 -0
  1312. package/src/text-highlight/stories/index.tsx +33 -0
  1313. package/src/text-highlight/test/index.tsx +93 -0
  1314. package/src/text-highlight/types.ts +16 -0
  1315. package/src/tip/index.tsx +22 -0
  1316. package/src/tip/stories/index.tsx +33 -0
  1317. package/src/tip/types.ts +11 -0
  1318. package/src/toggle-control/index.js +1 -2
  1319. package/src/toggle-control/index.native.js +2 -6
  1320. package/src/toggle-group-control/toggle-group-control/toggle-group-control-backdrop.tsx +2 -4
  1321. package/src/toolbar/index.js +1 -2
  1322. package/src/toolbar-group/index.js +1 -2
  1323. package/src/tools-panel/tools-panel/hook.ts +2 -4
  1324. package/src/tools-panel/tools-panel-header/hook.ts +2 -5
  1325. package/src/tooltip/index.js +1 -0
  1326. package/src/tree-grid/roving-tab-index-item.js +2 -4
  1327. package/src/tree-grid/test/index.js +2 -3
  1328. package/src/tree-select/README.md +2 -2
  1329. package/src/tree-select/index.tsx +99 -0
  1330. package/src/tree-select/stories/index.tsx +80 -0
  1331. package/src/tree-select/types.ts +35 -0
  1332. package/src/truncate/README.md +16 -12
  1333. package/src/truncate/{component.js → component.tsx} +13 -9
  1334. package/src/truncate/{hook.js → hook.ts} +8 -10
  1335. package/src/truncate/{index.js → index.ts} +0 -0
  1336. package/src/truncate/stories/index.tsx +49 -0
  1337. package/src/truncate/{styles.js → styles.ts} +0 -0
  1338. package/src/truncate/test/{index.js → index.tsx} +4 -4
  1339. package/src/truncate/types.ts +28 -10
  1340. package/src/truncate/{utils.js → utils.ts} +19 -19
  1341. package/src/ui/context/wordpress-component.ts +4 -5
  1342. package/src/ui/form-group/form-group-content.js +4 -4
  1343. package/src/ui/form-group/types.ts +1 -1
  1344. package/src/ui/utils/get-valid-children.ts +4 -2
  1345. package/src/unit-control/index.tsx +7 -9
  1346. package/src/unit-control/stories/index.tsx +8 -12
  1347. package/src/unit-control/test/index.tsx +4 -7
  1348. package/src/utils/hooks/stories/use-cx.js +8 -7
  1349. package/src/utils/hooks/test/use-controlled-state.js +2 -1
  1350. package/src/utils/math.js +14 -5
  1351. package/src/utils/test/math.js +22 -1
  1352. package/src/utils/unit-values.ts +2 -1
  1353. package/src/utils/values.js +2 -3
  1354. package/src/v-stack/README.md +6 -18
  1355. package/src/v-stack/{component.js → component.tsx} +15 -10
  1356. package/src/v-stack/{hook.js → hook.ts} +5 -6
  1357. package/src/v-stack/{index.js → index.ts} +0 -0
  1358. package/src/v-stack/stories/index.tsx +41 -0
  1359. package/src/v-stack/test/__snapshots__/{index.js.snap → index.tsx.snap} +0 -0
  1360. package/src/v-stack/test/{index.js → index.tsx} +0 -0
  1361. package/src/v-stack/types.ts +21 -1
  1362. package/src/visually-hidden/{component.js → component.tsx} +23 -15
  1363. package/src/visually-hidden/{index.js → index.ts} +0 -0
  1364. package/src/visually-hidden/stories/index.tsx +66 -0
  1365. package/src/visually-hidden/{styles.js → styles.ts} +6 -2
  1366. package/src/visually-hidden/test/__snapshots__/{index.js.snap → index.tsx.snap} +0 -0
  1367. package/src/visually-hidden/test/index.tsx +17 -0
  1368. package/src/visually-hidden/types.ts +11 -0
  1369. package/src/z-stack/README.md +14 -3
  1370. package/src/z-stack/component.tsx +24 -29
  1371. package/src/z-stack/stories/index.tsx +76 -0
  1372. package/src/z-stack/types.ts +33 -0
  1373. package/tsconfig.json +7 -0
  1374. package/tsconfig.tsbuildinfo +1 -1
  1375. package/src/border-control/stories/index.js +0 -119
  1376. package/src/color-indicator/index.js +0 -16
  1377. package/src/color-indicator/stories/index.js +0 -22
  1378. package/src/color-indicator/test/__snapshots__/index.js.snap +0 -13
  1379. package/src/external-link/stories/index.js +0 -23
  1380. package/src/form-toggle/index.js +0 -37
  1381. package/src/form-toggle/stories/index.js +0 -28
  1382. package/src/form-toggle/test/index.js +0 -75
  1383. package/src/form-token-field/index.js +0 -725
  1384. package/src/form-token-field/stories/index.js +0 -102
  1385. package/src/form-token-field/test/lib/token-field-wrapper.js +0 -56
  1386. package/src/form-token-field/token-input.js +0 -81
  1387. package/src/grid/stories/index.js +0 -49
  1388. package/src/h-stack/stories/index.js +0 -22
  1389. package/src/heading/test/index.js +0 -67
  1390. package/src/radio-control/index.js +0 -69
  1391. package/src/radio-control/stories/index.js +0 -41
  1392. package/src/range-control/stories/index.js +0 -180
  1393. package/src/range-control/test/index.js +0 -320
  1394. package/src/range-control/utils.js +0 -132
  1395. package/src/scrollable/test/index.js +0 -31
  1396. package/src/spacer/stories/index.js +0 -59
  1397. package/src/spacer/test/index.js +0 -146
  1398. package/src/spinner/stories/index.js +0 -43
  1399. package/src/text-highlight/index.js +0 -28
  1400. package/src/text-highlight/stories/index.js +0 -28
  1401. package/src/text-highlight/test/index.js +0 -120
  1402. package/src/tip/index.js +0 -24
  1403. package/src/tip/stories/index.js +0 -26
  1404. package/src/tree-select/index.js +0 -48
  1405. package/src/tree-select/stories/index.js +0 -80
  1406. package/src/truncate/stories/index.js +0 -38
  1407. package/src/visually-hidden/stories/index.js +0 -42
  1408. package/src/visually-hidden/test/index.js +0 -19
  1409. package/src/z-stack/stories/index.js +0 -70
@@ -1 +1 @@
1
- {"version":3,"sources":["@wordpress/components/src/mobile/bottom-sheet/index.native.js"],"names":["Dimensions","Keyboard","LayoutAnimation","PanResponder","Platform","ScrollView","StatusBar","Text","TouchableHighlight","View","Modal","SafeArea","omit","subscribeAndroidModalClosed","Component","withPreferredColorScheme","styles","Button","Cell","CyclePickerCell","PickerCell","SwitchCell","RangeCell","ColorCell","LinkCell","LinkSuggestionItemCell","RadioCell","NavigationScreen","NavigationContainer","KeyboardAvoidingView","BottomSheetSubSheet","NavBar","BottomSheetProvider","DEFAULT_LAYOUT_ANIMATION","Presets","easeInEaseOut","BottomSheet","constructor","arguments","onSafeAreaInsetsUpdate","bind","onScroll","isScrolling","onShouldEnableScroll","onDismiss","onShouldSetBottomSheetMaxHeight","setIsFullScreen","onDimensionsChange","onHeaderLayout","onCloseBottomSheet","onHandleClosingBottomSheet","onHardwareButtonPress","onHandleHardwareButtonPress","keyboardShow","keyboardHide","headerHeight","keyboardHeight","lastLayoutAnimation","lastLayoutAnimationFinished","state","safeAreaBottomInset","safeAreaTopInset","bounces","maxHeight","scrollEnabled","handleClosingBottomSheet","handleHardwareButtonPress","isMaxHeightSet","isFullScreen","props","e","isVisible","height","endCoordinates","performKeyboardLayoutAnimation","onSetMaxHeight","onKeyboardShow","onKeyboardHide","event","duration","easing","animationConfig","type","Types","layoutAnimation","update","create","property","Properties","opacity","delete","configureNext","performRegularLayoutAnimation","useLastLayoutAnimation","OS","componentDidMount","getSafeAreaInsetsForRootView","then","androidModalClosedSubscription","onClose","dimensionsChangeSubscription","addEventListener","keyboardShowListener","addListener","keyboardHideListener","safeAreaEventSubscription","componentWillUnmount","remove","result","safeAreaInsets","bottom","top","setState","width","get","statusBarHeight","currentHeight","maxHeightWithOpenKeyboard","Math","min","nativeEvent","layout","round","isCloseToBottom","layoutMeasurement","contentOffset","contentSize","y","isCloseToTop","value","action","getContentStyle","paddingBottom","scrollableContent","render","title","leftButton","rightButton","header","hideHeader","style","contentStyle","getStylesFromColorScheme","children","withHeaderSeparator","hasNavigation","rest","panResponder","onMoveShouldSetPanResponder","evt","gestureState","dy","backgroundStyle","background","backgroundDark","bottomSheetHeaderTitleStyle","bottomSheetHeaderTitle","bottomSheetHeaderTitleDark","listStyle","flexGrow","flexShrink","setMinHeightToMaxHeight","minHeight","listProps","disableScrollViewPanResponder","onScrollBeginDrag","onScrollEndDrag","scrollEventThrottle","contentContainerStyle","content","emptyHeader","automaticallyAdjustContentInsets","WrapperView","getHeader","bottomSheetHeader","flex","separator","showDragIndicator","allowDragIndicator","bottomModal","undefined","panHandlers","onMoveShouldSetResponder","onMoveShouldSetResponderCapture","borderColor","marginTop","backgroundFullScreen","testID","dragIndicator","shouldEnableBottomSheetScroll","shouldEnableBottomSheetMaxHeight","isBottomSheetContentScrolling","getWidth","maxWidth","ThemedBottomSheet","SubSheet"],"mappings":";;;AAAA;AACA;AACA;AACA,SACCA,UADD,EAECC,QAFD,EAGCC,eAHD,EAICC,YAJD,EAKCC,QALD,EAMCC,UAND,EAOCC,SAPD,EAQCC,IARD,EASCC,kBATD,EAUCC,IAVD,QAWO,cAXP;AAYA,OAAOC,KAAP,MAAkB,oBAAlB;AACA,OAAOC,QAAP,MAAqB,wBAArB;AACA,SAASC,IAAT,QAAqB,QAArB;AAEA;AACA;AACA;;AACA,SAASC,2BAAT,QAA4C,gCAA5C;AACA,SAASC,SAAT,QAA0B,oBAA1B;AACA,SAASC,wBAAT,QAAyC,oBAAzC;AAEA;AACA;AACA;;AACA,OAAOC,MAAP,MAAmB,eAAnB;AACA,OAAOC,MAAP,MAAmB,UAAnB;AACA,OAAOC,IAAP,MAAiB,QAAjB;AACA,OAAOC,eAAP,MAA4B,qBAA5B;AACA,OAAOC,UAAP,MAAuB,eAAvB;AACA,OAAOC,UAAP,MAAuB,eAAvB;AACA,OAAOC,SAAP,MAAsB,cAAtB;AACA,OAAOC,SAAP,MAAsB,cAAtB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B,GAAwCA,mBAAxC;AAEA,eAAesK,iBAAf","sourcesContent":["/**\n * External dependencies\n */\nimport {\n\tDimensions,\n\tKeyboard,\n\tLayoutAnimation,\n\tPanResponder,\n\tPlatform,\n\tScrollView,\n\tStatusBar,\n\tText,\n\tTouchableHighlight,\n\tView,\n} from 'react-native';\nimport Modal from 'react-native-modal';\nimport SafeArea from 'react-native-safe-area';\nimport { omit } from 'lodash';\n\n/**\n * WordPress dependencies\n */\nimport { subscribeAndroidModalClosed } from '@wordpress/react-native-bridge';\nimport { Component } from '@wordpress/element';\nimport { withPreferredColorScheme } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport styles from './styles.scss';\nimport Button from './button';\nimport Cell from './cell';\nimport CyclePickerCell from './cycle-picker-cell';\nimport PickerCell from './picker-cell';\nimport SwitchCell from './switch-cell';\nimport RangeCell from './range-cell';\nimport ColorCell from './color-cell';\nimport LinkCell from './link-cell';\nimport LinkSuggestionItemCell from './link-suggestion-item-cell';\nimport RadioCell from './radio-cell';\nimport NavigationScreen from './bottom-sheet-navigation/navigation-screen';\nimport NavigationContainer from './bottom-sheet-navigation/navigation-container';\nimport KeyboardAvoidingView from './keyboard-avoiding-view';\nimport BottomSheetSubSheet from './sub-sheet';\nimport NavBar from './nav-bar';\nimport { BottomSheetProvider } from './bottom-sheet-context';\n\nconst DEFAULT_LAYOUT_ANIMATION = LayoutAnimation.Presets.easeInEaseOut;\n\nclass BottomSheet extends Component {\n\tconstructor() {\n\t\tsuper( ...arguments );\n\t\tthis.onSafeAreaInsetsUpdate = this.onSafeAreaInsetsUpdate.bind( this );\n\t\tthis.onScroll = this.onScroll.bind( this );\n\t\tthis.isScrolling = this.isScrolling.bind( this );\n\t\tthis.onShouldEnableScroll = this.onShouldEnableScroll.bind( this );\n\t\tthis.onDismiss = this.onDismiss.bind( this );\n\t\tthis.onShouldSetBottomSheetMaxHeight = this.onShouldSetBottomSheetMaxHeight.bind(\n\t\t\tthis\n\t\t);\n\n\t\tthis.setIsFullScreen = this.setIsFullScreen.bind( this );\n\n\t\tthis.onDimensionsChange = this.onDimensionsChange.bind( this );\n\t\tthis.onHeaderLayout = this.onHeaderLayout.bind( this );\n\t\tthis.onCloseBottomSheet = this.onCloseBottomSheet.bind( this );\n\t\tthis.onHandleClosingBottomSheet = this.onHandleClosingBottomSheet.bind(\n\t\t\tthis\n\t\t);\n\t\tthis.onHardwareButtonPress = this.onHardwareButtonPress.bind( this );\n\t\tthis.onHandleHardwareButtonPress = this.onHandleHardwareButtonPress.bind(\n\t\t\tthis\n\t\t);\n\t\tthis.keyboardShow = this.keyboardShow.bind( this );\n\t\tthis.keyboardHide = this.keyboardHide.bind( this );\n\n\t\tthis.headerHeight = 0;\n\t\tthis.keyboardHeight = 0;\n\t\tthis.lastLayoutAnimation = null;\n\t\tthis.lastLayoutAnimationFinished = false;\n\n\t\tthis.state = {\n\t\t\tsafeAreaBottomInset: 0,\n\t\t\tsafeAreaTopInset: 0,\n\t\t\tbounces: false,\n\t\t\tmaxHeight: 0,\n\t\t\tscrollEnabled: true,\n\t\t\tisScrolling: false,\n\t\t\thandleClosingBottomSheet: null,\n\t\t\thandleHardwareButtonPress: null,\n\t\t\tisMaxHeightSet: true,\n\t\t\tisFullScreen: this.props.isFullScreen || false,\n\t\t};\n\t}\n\n\tkeyboardShow( e ) {\n\t\tif ( ! this.props.isVisible ) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst { height } = e.endCoordinates;\n\t\tthis.keyboardHeight = height;\n\t\tthis.performKeyboardLayoutAnimation( e );\n\t\tthis.onSetMaxHeight();\n\t\tthis.props.onKeyboardShow?.();\n\t}\n\n\tkeyboardHide( e ) {\n\t\tif ( ! this.props.isVisible ) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.keyboardHeight = 0;\n\t\tthis.performKeyboardLayoutAnimation( e );\n\t\tthis.onSetMaxHeight();\n\t\tthis.props.onKeyboardHide?.();\n\t}\n\n\tperformKeyboardLayoutAnimation( event ) {\n\t\tconst { duration, easing } = event;\n\n\t\tif ( duration && easing ) {\n\t\t\t// This layout animation is the same as the React Native's KeyboardAvoidingView component.\n\t\t\t// Reference: https://github.com/facebook/react-native/blob/266b21baf35e052ff28120f79c06c4f6dddc51a9/Libraries/Components/Keyboard/KeyboardAvoidingView.js#L119-L128.\n\t\t\tconst animationConfig = {\n\t\t\t\t// We have to pass the duration equal to minimal accepted duration defined here: RCTLayoutAnimation.m.\n\t\t\t\tduration: duration > 10 ? duration : 10,\n\t\t\t\ttype: LayoutAnimation.Types[ easing ] || 'keyboard',\n\t\t\t};\n\t\t\tconst layoutAnimation = {\n\t\t\t\tduration: animationConfig.duration,\n\t\t\t\tupdate: animationConfig,\n\t\t\t\tcreate: {\n\t\t\t\t\t...animationConfig,\n\t\t\t\t\tproperty: LayoutAnimation.Properties.opacity,\n\t\t\t\t},\n\t\t\t\tdelete: {\n\t\t\t\t\t...animationConfig,\n\t\t\t\t\tproperty: LayoutAnimation.Properties.opacity,\n\t\t\t\t},\n\t\t\t};\n\t\t\tthis.lastLayoutAnimationFinished = false;\n\t\t\tLayoutAnimation.configureNext( layoutAnimation, () => {\n\t\t\t\tthis.lastLayoutAnimationFinished = true;\n\t\t\t} );\n\t\t\tthis.lastLayoutAnimation = layoutAnimation;\n\t\t} else {\n\t\t\t// TODO: Reinstate animations, possibly replacing `LayoutAnimation` with\n\t\t\t// more nuanced `Animated` usage or replacing our custom `BottomSheet`\n\t\t\t// with `@gorhom/bottom-sheet`. This animation was disabled to avoid a\n\t\t\t// preexisting bug: https://github.com/WordPress/gutenberg/issues/30562\n\t\t\t// this.performRegularLayoutAnimation( {\n\t\t\t// \tuseLastLayoutAnimation: false,\n\t\t\t// } );.\n\t\t}\n\t}\n\n\tperformRegularLayoutAnimation( { useLastLayoutAnimation } ) {\n\t\t// On Android, we should prevent triggering multiple layout animations at the same time because it can produce visual glitches.\n\t\tif (\n\t\t\tPlatform.OS === 'android' &&\n\t\t\tthis.lastLayoutAnimation &&\n\t\t\t! this.lastLayoutAnimationFinished\n\t\t) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst layoutAnimation = useLastLayoutAnimation\n\t\t\t? this.lastLayoutAnimation || DEFAULT_LAYOUT_ANIMATION\n\t\t\t: DEFAULT_LAYOUT_ANIMATION;\n\n\t\tthis.lastLayoutAnimationFinished = false;\n\t\tLayoutAnimation.configureNext( layoutAnimation, () => {\n\t\t\tthis.lastLayoutAnimationFinished = true;\n\t\t} );\n\t\tthis.lastLayoutAnimation = layoutAnimation;\n\t}\n\n\tcomponentDidMount() {\n\t\tSafeArea.getSafeAreaInsetsForRootView().then(\n\t\t\tthis.onSafeAreaInsetsUpdate\n\t\t);\n\n\t\tif ( Platform.OS === 'android' ) {\n\t\t\tthis.androidModalClosedSubscription = subscribeAndroidModalClosed(\n\t\t\t\t() => {\n\t\t\t\t\tthis.props.onClose();\n\t\t\t\t}\n\t\t\t);\n\t\t}\n\n\t\tthis.dimensionsChangeSubscription = Dimensions.addEventListener(\n\t\t\t'change',\n\t\t\tthis.onDimensionsChange\n\t\t);\n\n\t\t// 'Will' keyboard events are not available on Android.\n\t\t// Reference: https://reactnative.dev/docs/0.61/keyboard#addlistener.\n\t\tthis.keyboardShowListener = Keyboard.addListener(\n\t\t\tPlatform.OS === 'ios' ? 'keyboardWillShow' : 'keyboardDidShow',\n\t\t\tthis.keyboardShow\n\t\t);\n\t\tthis.keyboardHideListener = Keyboard.addListener(\n\t\t\tPlatform.OS === 'ios' ? 'keyboardWillHide' : 'keyboardDidHide',\n\t\t\tthis.keyboardHide\n\t\t);\n\n\t\tthis.safeAreaEventSubscription = SafeArea.addEventListener(\n\t\t\t'safeAreaInsetsForRootViewDidChange',\n\t\t\tthis.onSafeAreaInsetsUpdate\n\t\t);\n\t\tthis.onSetMaxHeight();\n\t}\n\n\tcomponentWillUnmount() {\n\t\tthis.dimensionsChangeSubscription.remove();\n\t\tthis.keyboardShowListener.remove();\n\t\tthis.keyboardHideListener.remove();\n\t\tif ( this.androidModalClosedSubscription ) {\n\t\t\tthis.androidModalClosedSubscription.remove();\n\t\t}\n\t\tif ( this.safeAreaEventSubscription === null ) {\n\t\t\treturn;\n\t\t}\n\t\tthis.safeAreaEventSubscription.remove();\n\t\tthis.safeAreaEventSubscription = null;\n\t}\n\n\tonSafeAreaInsetsUpdate( result ) {\n\t\tconst { safeAreaBottomInset, safeAreaTopInset } = this.state;\n\t\tif ( this.safeAreaEventSubscription === null ) {\n\t\t\treturn;\n\t\t}\n\t\tconst { safeAreaInsets } = result;\n\t\tif (\n\t\t\tsafeAreaBottomInset !== safeAreaInsets.bottom ||\n\t\t\tsafeAreaTopInset !== safeAreaInsets.top\n\t\t) {\n\t\t\tthis.setState( {\n\t\t\t\tsafeAreaBottomInset: safeAreaInsets.bottom,\n\t\t\t\tsafeAreaTopInset: safeAreaInsets.top,\n\t\t\t} );\n\t\t}\n\t}\n\n\tonSetMaxHeight() {\n\t\tconst { height, width } = Dimensions.get( 'window' );\n\t\tconst { safeAreaBottomInset } = this.state;\n\t\tconst statusBarHeight =\n\t\t\tPlatform.OS === 'android' ? StatusBar.currentHeight : 0;\n\n\t\t// `maxHeight` when modal is opened along with a keyboard.\n\t\tconst maxHeightWithOpenKeyboard =\n\t\t\t0.95 *\n\t\t\t( Dimensions.get( 'window' ).height -\n\t\t\t\tthis.keyboardHeight -\n\t\t\t\tstatusBarHeight -\n\t\t\t\tthis.headerHeight );\n\n\t\t// In landscape orientation, set `maxHeight` to ~96% of the height.\n\t\tif ( width > height ) {\n\t\t\tthis.setState( {\n\t\t\t\tmaxHeight: Math.min(\n\t\t\t\t\t0.96 * height - this.headerHeight,\n\t\t\t\t\tmaxHeightWithOpenKeyboard\n\t\t\t\t),\n\t\t\t} );\n\t\t\t// In portrait orientation, set `maxHeight` to ~59% of the height.\n\t\t} else {\n\t\t\tthis.setState( {\n\t\t\t\tmaxHeight: Math.min(\n\t\t\t\t\theight * 0.59 - safeAreaBottomInset - this.headerHeight,\n\t\t\t\t\tmaxHeightWithOpenKeyboard\n\t\t\t\t),\n\t\t\t} );\n\t\t}\n\t}\n\n\tonDimensionsChange() {\n\t\tthis.onSetMaxHeight();\n\t\tthis.setState( { bounces: false } );\n\t}\n\n\tonHeaderLayout( { nativeEvent } ) {\n\t\tconst { height } = nativeEvent.layout;\n\t\t// The layout animation should only be triggered if the header\n\t\t// height has changed after being mounted.\n\t\tif (\n\t\t\tthis.headerHeight !== 0 &&\n\t\t\tMath.round( height ) !== Math.round( this.headerHeight )\n\t\t) {\n\t\t\tthis.performRegularLayoutAnimation( {\n\t\t\t\tuseLastLayoutAnimation: true,\n\t\t\t} );\n\t\t}\n\t\tthis.headerHeight = height;\n\t\tthis.onSetMaxHeight();\n\t}\n\n\tisCloseToBottom( { layoutMeasurement, contentOffset, contentSize } ) {\n\t\treturn (\n\t\t\tlayoutMeasurement.height + contentOffset.y >=\n\t\t\tcontentSize.height - contentOffset.y\n\t\t);\n\t}\n\n\tisCloseToTop( { contentOffset } ) {\n\t\treturn contentOffset.y < 10;\n\t}\n\n\tonScroll( { nativeEvent } ) {\n\t\tif ( this.isCloseToTop( nativeEvent ) ) {\n\t\t\tthis.setState( { bounces: false } );\n\t\t} else {\n\t\t\tthis.setState( { bounces: true } );\n\t\t}\n\t}\n\n\tonDismiss() {\n\t\tconst { onDismiss } = this.props;\n\n\t\tif ( onDismiss ) {\n\t\t\tonDismiss();\n\t\t}\n\n\t\tthis.onCloseBottomSheet();\n\t}\n\n\tonShouldEnableScroll( value ) {\n\t\tthis.setState( { scrollEnabled: value } );\n\t}\n\n\tonShouldSetBottomSheetMaxHeight( value ) {\n\t\tthis.setState( { isMaxHeightSet: value } );\n\t}\n\n\tisScrolling( value ) {\n\t\tthis.setState( { isScrolling: value } );\n\t}\n\n\tonHandleClosingBottomSheet( action ) {\n\t\tthis.setState( { handleClosingBottomSheet: action } );\n\t}\n\n\tonHandleHardwareButtonPress( action ) {\n\t\tthis.setState( { handleHardwareButtonPress: action } );\n\t}\n\n\tonCloseBottomSheet() {\n\t\tconst { onClose } = this.props;\n\t\tconst { handleClosingBottomSheet } = this.state;\n\t\tif ( handleClosingBottomSheet ) {\n\t\t\thandleClosingBottomSheet();\n\t\t\tthis.onHandleClosingBottomSheet( null );\n\t\t}\n\t\tif ( onClose ) {\n\t\t\tonClose();\n\t\t}\n\t\tthis.onShouldSetBottomSheetMaxHeight( true );\n\t}\n\n\tsetIsFullScreen( isFullScreen ) {\n\t\tif ( isFullScreen !== this.state.isFullScreen ) {\n\t\t\tif ( isFullScreen ) {\n\t\t\t\tthis.setState( { isFullScreen, isMaxHeightSet: false } );\n\t\t\t} else {\n\t\t\t\tthis.setState( { isFullScreen, isMaxHeightSet: true } );\n\t\t\t}\n\t\t}\n\t}\n\n\tonHardwareButtonPress() {\n\t\tconst { onClose } = this.props;\n\t\tconst { handleHardwareButtonPress } = this.state;\n\t\tif ( handleHardwareButtonPress && handleHardwareButtonPress() ) {\n\t\t\treturn;\n\t\t}\n\t\tif ( onClose ) {\n\t\t\treturn onClose();\n\t\t}\n\t}\n\n\tgetContentStyle() {\n\t\tconst { safeAreaBottomInset } = this.state;\n\t\treturn {\n\t\t\tpaddingBottom:\n\t\t\t\t( safeAreaBottomInset || 0 ) +\n\t\t\t\tstyles.scrollableContent.paddingBottom,\n\t\t};\n\t}\n\n\trender() {\n\t\tconst {\n\t\t\ttitle = '',\n\t\t\tisVisible,\n\t\t\tleftButton,\n\t\t\trightButton,\n\t\t\theader,\n\t\t\thideHeader,\n\t\t\tstyle = {},\n\t\t\tcontentStyle = {},\n\t\t\tgetStylesFromColorScheme,\n\t\t\tchildren,\n\t\t\twithHeaderSeparator = false,\n\t\t\thasNavigation,\n\t\t\t...rest\n\t\t} = this.props;\n\t\tconst {\n\t\t\tmaxHeight,\n\t\t\tbounces,\n\t\t\tsafeAreaBottomInset,\n\t\t\tsafeAreaTopInset,\n\t\t\tisScrolling,\n\t\t\tscrollEnabled,\n\t\t\tisMaxHeightSet,\n\t\t\tisFullScreen,\n\t\t} = this.state;\n\n\t\tconst panResponder = PanResponder.create( {\n\t\t\tonMoveShouldSetPanResponder: ( evt, gestureState ) => {\n\t\t\t\t// 'swiping-to-close' option is temporarily and partially disabled\n\t\t\t\t// on Android ( swipe / drag is still available in the top most area - near drag indicator).\n\t\t\t\tif ( Platform.OS === 'ios' ) {\n\t\t\t\t\t// Activates swipe down over child Touchables if the swipe is long enough.\n\t\t\t\t\t// With this we can adjust sensibility on the swipe vs tap gestures.\n\t\t\t\t\tif ( gestureState.dy > 3 && ! bounces ) {\n\t\t\t\t\t\tgestureState.dy = 0;\n\t\t\t\t\t\treturn true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn false;\n\t\t\t},\n\t\t} );\n\n\t\tconst backgroundStyle = getStylesFromColorScheme(\n\t\t\tstyles.background,\n\t\t\tstyles.backgroundDark\n\t\t);\n\n\t\tconst bottomSheetHeaderTitleStyle = getStylesFromColorScheme(\n\t\t\tstyles.bottomSheetHeaderTitle,\n\t\t\tstyles.bottomSheetHeaderTitleDark\n\t\t);\n\n\t\tlet listStyle = {};\n\t\tif ( isFullScreen ) {\n\t\t\tlistStyle = { flexGrow: 1, flexShrink: 1 };\n\t\t} else if ( isMaxHeightSet ) {\n\t\t\tlistStyle = { maxHeight };\n\n\t\t\t// Allow setting a \"static\" height of the bottom sheet\n\t\t\t// by setting the min height to the max height.\n\t\t\tif ( this.props.setMinHeightToMaxHeight ) {\n\t\t\t\tlistStyle.minHeight = maxHeight;\n\t\t\t}\n\t\t}\n\n\t\tconst listProps = {\n\t\t\tdisableScrollViewPanResponder: true,\n\t\t\tbounces,\n\t\t\tonScroll: this.onScroll,\n\t\t\tonScrollBeginDrag: this.onScrollBeginDrag,\n\t\t\tonScrollEndDrag: this.onScrollEndDrag,\n\t\t\tscrollEventThrottle: 16,\n\t\t\tcontentContainerStyle: [\n\t\t\t\tstyles.content,\n\t\t\t\thideHeader && styles.emptyHeader,\n\t\t\t\tcontentStyle,\n\t\t\t\tisFullScreen && { flexGrow: 1 },\n\t\t\t],\n\t\t\tstyle: listStyle,\n\t\t\tsafeAreaBottomInset,\n\t\t\tscrollEnabled,\n\t\t\tautomaticallyAdjustContentInsets: false,\n\t\t};\n\n\t\tconst WrapperView = hasNavigation ? View : ScrollView;\n\n\t\tconst getHeader = () => (\n\t\t\t<>\n\t\t\t\t{ header || (\n\t\t\t\t\t<View style={ styles.bottomSheetHeader }>\n\t\t\t\t\t\t<View style={ styles.flex }>{ leftButton }</View>\n\t\t\t\t\t\t<Text\n\t\t\t\t\t\t\tstyle={ bottomSheetHeaderTitleStyle }\n\t\t\t\t\t\t\tmaxFontSizeMultiplier={ 3 }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ title }\n\t\t\t\t\t\t</Text>\n\t\t\t\t\t\t<View style={ styles.flex }>{ rightButton }</View>\n\t\t\t\t\t</View>\n\t\t\t\t) }\n\t\t\t\t{ withHeaderSeparator && <View style={ styles.separator } /> }\n\t\t\t</>\n\t\t);\n\n\t\tconst showDragIndicator = () => {\n\t\t\t// If iOS or not fullscreen show the drag indicator.\n\t\t\tif ( Platform.OS === 'ios' || ! this.state.isFullScreen ) {\n\t\t\t\treturn true;\n\t\t\t}\n\n\t\t\t// Otherwise check the allowDragIndicator.\n\t\t\treturn this.props.allowDragIndicator;\n\t\t};\n\n\t\treturn (\n\t\t\t<Modal\n\t\t\t\tisVisible={ isVisible }\n\t\t\t\tstyle={ styles.bottomModal }\n\t\t\t\tanimationInTiming={ 400 }\n\t\t\t\tanimationOutTiming={ 300 }\n\t\t\t\tbackdropTransitionInTiming={ 50 }\n\t\t\t\tbackdropTransitionOutTiming={ 50 }\n\t\t\t\tbackdropOpacity={ 0.2 }\n\t\t\t\tonBackdropPress={ this.onCloseBottomSheet }\n\t\t\t\tonBackButtonPress={ this.onHardwareButtonPress }\n\t\t\t\tonSwipeComplete={ this.onCloseBottomSheet }\n\t\t\t\tonDismiss={ Platform.OS === 'ios' ? this.onDismiss : undefined }\n\t\t\t\tonModalHide={\n\t\t\t\t\tPlatform.OS === 'android' ? this.onDismiss : undefined\n\t\t\t\t}\n\t\t\t\tswipeDirection=\"down\"\n\t\t\t\tonMoveShouldSetResponder={\n\t\t\t\t\tscrollEnabled &&\n\t\t\t\t\tpanResponder.panHandlers.onMoveShouldSetResponder\n\t\t\t\t}\n\t\t\t\tonMoveShouldSetResponderCapture={\n\t\t\t\t\tscrollEnabled &&\n\t\t\t\t\tpanResponder.panHandlers.onMoveShouldSetResponderCapture\n\t\t\t\t}\n\t\t\t\tonAccessibilityEscape={ this.onCloseBottomSheet }\n\t\t\t\t// We need to prevent overwriting the onDismiss prop,\n\t\t\t\t// for this reason it is excluded from the rest object.\n\t\t\t\t{ ...omit( rest, 'onDismiss' ) }\n\t\t\t>\n\t\t\t\t<KeyboardAvoidingView\n\t\t\t\t\tbehavior={ Platform.OS === 'ios' && 'padding' }\n\t\t\t\t\tstyle={ {\n\t\t\t\t\t\t...backgroundStyle,\n\t\t\t\t\t\tborderColor: 'rgba(0, 0, 0, 0.1)',\n\t\t\t\t\t\tmarginTop:\n\t\t\t\t\t\t\tPlatform.OS === 'ios' && isFullScreen\n\t\t\t\t\t\t\t\t? safeAreaTopInset\n\t\t\t\t\t\t\t\t: 0,\n\t\t\t\t\t\tflex: isFullScreen ? 1 : undefined,\n\t\t\t\t\t\t...( Platform.OS === 'android' && isFullScreen\n\t\t\t\t\t\t\t? styles.backgroundFullScreen\n\t\t\t\t\t\t\t: {} ),\n\t\t\t\t\t\t...style,\n\t\t\t\t\t} }\n\t\t\t\t\tkeyboardVerticalOffset={ -safeAreaBottomInset }\n\t\t\t\t>\n\t\t\t\t\t<View\n\t\t\t\t\t\tstyle={ styles.header }\n\t\t\t\t\t\tonLayout={ this.onHeaderLayout }\n\t\t\t\t\t\ttestID={ `${ rest.testID || 'bottom-sheet' }-header` }\n\t\t\t\t\t>\n\t\t\t\t\t\t{ showDragIndicator() && (\n\t\t\t\t\t\t\t<View style={ styles.dragIndicator } />\n\t\t\t\t\t\t) }\n\t\t\t\t\t\t{ ! hideHeader && getHeader() }\n\t\t\t\t\t</View>\n\t\t\t\t\t<WrapperView\n\t\t\t\t\t\t{ ...( hasNavigation\n\t\t\t\t\t\t\t? { style: listProps.style }\n\t\t\t\t\t\t\t: listProps ) }\n\t\t\t\t\t>\n\t\t\t\t\t\t<BottomSheetProvider\n\t\t\t\t\t\t\tvalue={ {\n\t\t\t\t\t\t\t\tshouldEnableBottomSheetScroll: this\n\t\t\t\t\t\t\t\t\t.onShouldEnableScroll,\n\t\t\t\t\t\t\t\tshouldEnableBottomSheetMaxHeight: this\n\t\t\t\t\t\t\t\t\t.onShouldSetBottomSheetMaxHeight,\n\t\t\t\t\t\t\t\tisBottomSheetContentScrolling: isScrolling,\n\t\t\t\t\t\t\t\tonHandleClosingBottomSheet: this\n\t\t\t\t\t\t\t\t\t.onHandleClosingBottomSheet,\n\t\t\t\t\t\t\t\tonHandleHardwareButtonPress: this\n\t\t\t\t\t\t\t\t\t.onHandleHardwareButtonPress,\n\t\t\t\t\t\t\t\tlistProps,\n\t\t\t\t\t\t\t\tsetIsFullScreen: this.setIsFullScreen,\n\t\t\t\t\t\t\t\tsafeAreaBottomInset,\n\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ hasNavigation ? (\n\t\t\t\t\t\t\t\t<>{ children }</>\n\t\t\t\t\t\t\t) : (\n\t\t\t\t\t\t\t\t<TouchableHighlight accessible={ false }>\n\t\t\t\t\t\t\t\t\t<>{ children }</>\n\t\t\t\t\t\t\t\t</TouchableHighlight>\n\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t</BottomSheetProvider>\n\t\t\t\t\t\t{ ! hasNavigation && (\n\t\t\t\t\t\t\t<View\n\t\t\t\t\t\t\t\tstyle={ {\n\t\t\t\t\t\t\t\t\theight:\n\t\t\t\t\t\t\t\t\t\tsafeAreaBottomInset ||\n\t\t\t\t\t\t\t\t\t\tstyles.scrollableContent.paddingBottom,\n\t\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t) }\n\t\t\t\t\t</WrapperView>\n\t\t\t\t</KeyboardAvoidingView>\n\t\t\t</Modal>\n\t\t);\n\t}\n}\n\nfunction getWidth() {\n\treturn Math.min(\n\t\tDimensions.get( 'window' ).width,\n\t\tstyles.background.maxWidth\n\t);\n}\n\nconst ThemedBottomSheet = withPreferredColorScheme( BottomSheet );\n\nThemedBottomSheet.getWidth = getWidth;\nThemedBottomSheet.Button = Button;\nThemedBottomSheet.Cell = Cell;\nThemedBottomSheet.SubSheet = BottomSheetSubSheet;\nThemedBottomSheet.NavBar = NavBar;\nThemedBottomSheet.CyclePickerCell = CyclePickerCell;\nThemedBottomSheet.PickerCell = PickerCell;\nThemedBottomSheet.SwitchCell = SwitchCell;\nThemedBottomSheet.RangeCell = RangeCell;\nThemedBottomSheet.ColorCell = ColorCell;\nThemedBottomSheet.LinkCell = LinkCell;\nThemedBottomSheet.LinkSuggestionItemCell = LinkSuggestionItemCell;\nThemedBottomSheet.RadioCell = RadioCell;\nThemedBottomSheet.NavigationScreen = NavigationScreen;\nThemedBottomSheet.NavigationContainer = NavigationContainer;\n\nexport default ThemedBottomSheet;\n"]}
1
+ {"version":3,"sources":["@wordpress/components/src/mobile/bottom-sheet/index.native.js"],"names":["Dimensions","Keyboard","LayoutAnimation","PanResponder","Platform","ScrollView","StatusBar","Text","TouchableHighlight","View","Modal","SafeArea","omit","subscribeAndroidModalClosed","Component","withPreferredColorScheme","styles","Button","Cell","CyclePickerCell","PickerCell","SwitchCell","RangeCell","ColorCell","LinkCell","LinkSuggestionItemCell","RadioCell","NavigationScreen","NavigationContainer","KeyboardAvoidingView","BottomSheetSubSheet","NavBar","BottomSheetProvider","DEFAULT_LAYOUT_ANIMATION","Presets","easeInEaseOut","BottomSheet","constructor","arguments","onSafeAreaInsetsUpdate","bind","onScroll","isScrolling","onShouldEnableScroll","onDismiss","onShouldSetBottomSheetMaxHeight","setIsFullScreen","onDimensionsChange","onHeaderLayout","onCloseBottomSheet","onHandleClosingBottomSheet","onHardwareButtonPress","onHandleHardwareButtonPress","keyboardShow","keyboardHide","headerHeight","keyboardHeight","lastLayoutAnimation","lastLayoutAnimationFinished","state","safeAreaBottomInset","safeAreaTopInset","bounces","maxHeight","scrollEnabled","handleClosingBottomSheet","handleHardwareButtonPress","isMaxHeightSet","isFullScreen","props","e","isVisible","height","endCoordinates","performKeyboardLayoutAnimation","onSetMaxHeight","onKeyboardShow","onKeyboardHide","event","duration","easing","animationConfig","type","Types","layoutAnimation","update","create","property","Properties","opacity","delete","configureNext","performRegularLayoutAnimation","useLastLayoutAnimation","OS","componentDidMount","getSafeAreaInsetsForRootView","then","androidModalClosedSubscription","onClose","dimensionsChangeSubscription","addEventListener","keyboardShowListener","addListener","keyboardHideListener","safeAreaEventSubscription","componentWillUnmount","remove","result","safeAreaInsets","bottom","top","setState","width","get","statusBarHeight","currentHeight","maxHeightWithOpenKeyboard","Math","min","nativeEvent","layout","round","isCloseToBottom","layoutMeasurement","contentOffset","contentSize","y","isCloseToTop","value","action","getContentStyle","paddingBottom","scrollableContent","render","title","leftButton","rightButton","header","hideHeader","style","contentStyle","getStylesFromColorScheme","children","withHeaderSeparator","hasNavigation","rest","panResponder","onMoveShouldSetPanResponder","evt","gestureState","dy","backgroundStyle","background","backgroundDark","bottomSheetHeaderTitleStyle","bottomSheetHeaderTitle","bottomSheetHeaderTitleDark","listStyle","flexGrow","flexShrink","setMinHeightToMaxHeight","minHeight","listProps","disableScrollViewPanResponder","onScrollBeginDrag","onScrollEndDrag","scrollEventThrottle","contentContainerStyle","content","emptyHeader","automaticallyAdjustContentInsets","WrapperView","getHeader","bottomSheetHeader","flex","separator","showDragIndicator","allowDragIndicator","bottomModal","undefined","panHandlers","onMoveShouldSetResponder","onMoveShouldSetResponderCapture","borderColor","marginTop","backgroundFullScreen","testID","dragIndicator","shouldEnableBottomSheetScroll","shouldEnableBottomSheetMaxHeight","isBottomSheet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AAF,CAAlD;AAEA8J,iBAAiB,CAACF,QAAlB,GAA6BA,QAA7B;AACAE,iBAAiB,CAACjL,MAAlB,GAA2BA,MAA3B;AACAiL,iBAAiB,CAAChL,IAAlB,GAAyBA,IAAzB;AACAgL,iBAAiB,CAACC,QAAlB,GAA6BrK,mBAA7B;AACAoK,iBAAiB,CAACnK,MAAlB,GAA2BA,MAA3B;AACAmK,iBAAiB,CAAC/K,eAAlB,GAAoCA,eAApC;AACA+K,iBAAiB,CAAC9K,UAAlB,GAA+BA,UAA/B;AACA8K,iBAAiB,CAAC7K,UAAlB,GAA+BA,UAA/B;AACA6K,iBAAiB,CAAC5K,SAAlB,GAA8BA,SAA9B;AACA4K,iBAAiB,CAAC3K,SAAlB,GAA8BA,SAA9B;AACA2K,iBAAiB,CAAC1K,QAAlB,GAA6BA,QAA7B;AACA0K,iBAAiB,CAACzK,sBAAlB,GAA2CA,sBAA3C;AACAyK,iBAAiB,CAACxK,SAAlB,GAA8BA,SAA9B;AACAwK,iBAAiB,CAACvK,gBAAlB,GAAqCA,gBAArC;AACAuK,iBAAiB,CAACtK,mBAAlB,GAAwCA,mBAAxC;AAEA,eAAesK,iBAAf","sourcesContent":["/**\n * External dependencies\n */\nimport {\n\tDimensions,\n\tKeyboard,\n\tLayoutAnimation,\n\tPanResponder,\n\tPlatform,\n\tScrollView,\n\tStatusBar,\n\tText,\n\tTouchableHighlight,\n\tView,\n} from 'react-native';\nimport Modal from 'react-native-modal';\nimport SafeArea from 'react-native-safe-area';\nimport { omit } from 'lodash';\n\n/**\n * WordPress dependencies\n */\nimport { subscribeAndroidModalClosed } from '@wordpress/react-native-bridge';\nimport { Component } from '@wordpress/element';\nimport { withPreferredColorScheme } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport styles from './styles.scss';\nimport Button from './button';\nimport Cell from './cell';\nimport CyclePickerCell from './cycle-picker-cell';\nimport PickerCell from './picker-cell';\nimport SwitchCell from './switch-cell';\nimport RangeCell from './range-cell';\nimport ColorCell from './color-cell';\nimport LinkCell from './link-cell';\nimport LinkSuggestionItemCell from './link-suggestion-item-cell';\nimport RadioCell from './radio-cell';\nimport NavigationScreen from './bottom-sheet-navigation/navigation-screen';\nimport NavigationContainer from './bottom-sheet-navigation/navigation-container';\nimport KeyboardAvoidingView from './keyboard-avoiding-view';\nimport BottomSheetSubSheet from './sub-sheet';\nimport NavBar from './nav-bar';\nimport { BottomSheetProvider } from './bottom-sheet-context';\n\nconst DEFAULT_LAYOUT_ANIMATION = LayoutAnimation.Presets.easeInEaseOut;\n\nclass BottomSheet extends Component {\n\tconstructor() {\n\t\tsuper( ...arguments );\n\t\tthis.onSafeAreaInsetsUpdate = this.onSafeAreaInsetsUpdate.bind( this );\n\t\tthis.onScroll = this.onScroll.bind( this );\n\t\tthis.isScrolling = this.isScrolling.bind( this );\n\t\tthis.onShouldEnableScroll = this.onShouldEnableScroll.bind( this );\n\t\tthis.onDismiss = this.onDismiss.bind( this );\n\t\tthis.onShouldSetBottomSheetMaxHeight =\n\t\t\tthis.onShouldSetBottomSheetMaxHeight.bind( this );\n\n\t\tthis.setIsFullScreen = this.setIsFullScreen.bind( this );\n\n\t\tthis.onDimensionsChange = this.onDimensionsChange.bind( this );\n\t\tthis.onHeaderLayout = this.onHeaderLayout.bind( this );\n\t\tthis.onCloseBottomSheet = this.onCloseBottomSheet.bind( this );\n\t\tthis.onHandleClosingBottomSheet =\n\t\t\tthis.onHandleClosingBottomSheet.bind( this );\n\t\tthis.onHardwareButtonPress = this.onHardwareButtonPress.bind( this );\n\t\tthis.onHandleHardwareButtonPress =\n\t\t\tthis.onHandleHardwareButtonPress.bind( this );\n\t\tthis.keyboardShow = this.keyboardShow.bind( this );\n\t\tthis.keyboardHide = this.keyboardHide.bind( this );\n\n\t\tthis.headerHeight = 0;\n\t\tthis.keyboardHeight = 0;\n\t\tthis.lastLayoutAnimation = null;\n\t\tthis.lastLayoutAnimationFinished = false;\n\n\t\tthis.state = {\n\t\t\tsafeAreaBottomInset: 0,\n\t\t\tsafeAreaTopInset: 0,\n\t\t\tbounces: false,\n\t\t\tmaxHeight: 0,\n\t\t\tscrollEnabled: true,\n\t\t\tisScrolling: false,\n\t\t\thandleClosingBottomSheet: null,\n\t\t\thandleHardwareButtonPress: null,\n\t\t\tisMaxHeightSet: true,\n\t\t\tisFullScreen: this.props.isFullScreen || false,\n\t\t};\n\t}\n\n\tkeyboardShow( e ) {\n\t\tif ( ! this.props.isVisible ) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst { height } = e.endCoordinates;\n\t\tthis.keyboardHeight = height;\n\t\tthis.performKeyboardLayoutAnimation( e );\n\t\tthis.onSetMaxHeight();\n\t\tthis.props.onKeyboardShow?.();\n\t}\n\n\tkeyboardHide( e ) {\n\t\tif ( ! this.props.isVisible ) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.keyboardHeight = 0;\n\t\tthis.performKeyboardLayoutAnimation( e );\n\t\tthis.onSetMaxHeight();\n\t\tthis.props.onKeyboardHide?.();\n\t}\n\n\tperformKeyboardLayoutAnimation( event ) {\n\t\tconst { duration, easing } = event;\n\n\t\tif ( duration && easing ) {\n\t\t\t// This layout animation is the same as the React Native's KeyboardAvoidingView component.\n\t\t\t// Reference: https://github.com/facebook/react-native/blob/266b21baf35e052ff28120f79c06c4f6dddc51a9/Libraries/Components/Keyboard/KeyboardAvoidingView.js#L119-L128.\n\t\t\tconst animationConfig = {\n\t\t\t\t// We have to pass the duration equal to minimal accepted duration defined here: RCTLayoutAnimation.m.\n\t\t\t\tduration: duration > 10 ? duration : 10,\n\t\t\t\ttype: LayoutAnimation.Types[ easing ] || 'keyboard',\n\t\t\t};\n\t\t\tconst layoutAnimation = {\n\t\t\t\tduration: animationConfig.duration,\n\t\t\t\tupdate: animationConfig,\n\t\t\t\tcreate: {\n\t\t\t\t\t...animationConfig,\n\t\t\t\t\tproperty: LayoutAnimation.Properties.opacity,\n\t\t\t\t},\n\t\t\t\tdelete: {\n\t\t\t\t\t...animationConfig,\n\t\t\t\t\tproperty: LayoutAnimation.Properties.opacity,\n\t\t\t\t},\n\t\t\t};\n\t\t\tthis.lastLayoutAnimationFinished = false;\n\t\t\tLayoutAnimation.configureNext( layoutAnimation, () => {\n\t\t\t\tthis.lastLayoutAnimationFinished = true;\n\t\t\t} );\n\t\t\tthis.lastLayoutAnimation = layoutAnimation;\n\t\t} else {\n\t\t\t// TODO: Reinstate animations, possibly replacing `LayoutAnimation` with\n\t\t\t// more nuanced `Animated` usage or replacing our custom `BottomSheet`\n\t\t\t// with `@gorhom/bottom-sheet`. This animation was disabled to avoid a\n\t\t\t// preexisting bug: https://github.com/WordPress/gutenberg/issues/30562\n\t\t\t// this.performRegularLayoutAnimation( {\n\t\t\t// \tuseLastLayoutAnimation: false,\n\t\t\t// } );.\n\t\t}\n\t}\n\n\tperformRegularLayoutAnimation( { useLastLayoutAnimation } ) {\n\t\t// On Android, we should prevent triggering multiple layout animations at the same time because it can produce visual glitches.\n\t\tif (\n\t\t\tPlatform.OS === 'android' &&\n\t\t\tthis.lastLayoutAnimation &&\n\t\t\t! this.lastLayoutAnimationFinished\n\t\t) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst layoutAnimation = useLastLayoutAnimation\n\t\t\t? this.lastLayoutAnimation || DEFAULT_LAYOUT_ANIMATION\n\t\t\t: DEFAULT_LAYOUT_ANIMATION;\n\n\t\tthis.lastLayoutAnimationFinished = false;\n\t\tLayoutAnimation.configureNext( layoutAnimation, () => {\n\t\t\tthis.lastLayoutAnimationFinished = true;\n\t\t} );\n\t\tthis.lastLayoutAnimation = layoutAnimation;\n\t}\n\n\tcomponentDidMount() {\n\t\tSafeArea.getSafeAreaInsetsForRootView().then(\n\t\t\tthis.onSafeAreaInsetsUpdate\n\t\t);\n\n\t\tif ( Platform.OS === 'android' ) {\n\t\t\tthis.androidModalClosedSubscription = subscribeAndroidModalClosed(\n\t\t\t\t() => {\n\t\t\t\t\tthis.props.onClose();\n\t\t\t\t}\n\t\t\t);\n\t\t}\n\n\t\tthis.dimensionsChangeSubscription = Dimensions.addEventListener(\n\t\t\t'change',\n\t\t\tthis.onDimensionsChange\n\t\t);\n\n\t\t// 'Will' keyboard events are not available on Android.\n\t\t// Reference: https://reactnative.dev/docs/0.61/keyboard#addlistener.\n\t\tthis.keyboardShowListener = Keyboard.addListener(\n\t\t\tPlatform.OS === 'ios' ? 'keyboardWillShow' : 'keyboardDidShow',\n\t\t\tthis.keyboardShow\n\t\t);\n\t\tthis.keyboardHideListener = Keyboard.addListener(\n\t\t\tPlatform.OS === 'ios' ? 'keyboardWillHide' : 'keyboardDidHide',\n\t\t\tthis.keyboardHide\n\t\t);\n\n\t\tthis.safeAreaEventSubscription = SafeArea.addEventListener(\n\t\t\t'safeAreaInsetsForRootViewDidChange',\n\t\t\tthis.onSafeAreaInsetsUpdate\n\t\t);\n\t\tthis.onSetMaxHeight();\n\t}\n\n\tcomponentWillUnmount() {\n\t\tthis.dimensionsChangeSubscription.remove();\n\t\tthis.keyboardShowListener.remove();\n\t\tthis.keyboardHideListener.remove();\n\t\tif ( this.androidModalClosedSubscription ) {\n\t\t\tthis.androidModalClosedSubscription.remove();\n\t\t}\n\t\tif ( this.safeAreaEventSubscription === null ) {\n\t\t\treturn;\n\t\t}\n\t\tthis.safeAreaEventSubscription.remove();\n\t\tthis.safeAreaEventSubscription = null;\n\t}\n\n\tonSafeAreaInsetsUpdate( result ) {\n\t\tconst { safeAreaBottomInset, safeAreaTopInset } = this.state;\n\t\tif ( this.safeAreaEventSubscription === null ) {\n\t\t\treturn;\n\t\t}\n\t\tconst { safeAreaInsets } = result;\n\t\tif (\n\t\t\tsafeAreaBottomInset !== safeAreaInsets.bottom ||\n\t\t\tsafeAreaTopInset !== safeAreaInsets.top\n\t\t) {\n\t\t\tthis.setState( {\n\t\t\t\tsafeAreaBottomInset: safeAreaInsets.bottom,\n\t\t\t\tsafeAreaTopInset: safeAreaInsets.top,\n\t\t\t} );\n\t\t}\n\t}\n\n\tonSetMaxHeight() {\n\t\tconst { height, width } = Dimensions.get( 'window' );\n\t\tconst { safeAreaBottomInset } = this.state;\n\t\tconst statusBarHeight =\n\t\t\tPlatform.OS === 'android' ? StatusBar.currentHeight : 0;\n\n\t\t// `maxHeight` when modal is opened along with a keyboard.\n\t\tconst maxHeightWithOpenKeyboard =\n\t\t\t0.95 *\n\t\t\t( Dimensions.get( 'window' ).height -\n\t\t\t\tthis.keyboardHeight -\n\t\t\t\tstatusBarHeight -\n\t\t\t\tthis.headerHeight );\n\n\t\t// In landscape orientation, set `maxHeight` to ~96% of the height.\n\t\tif ( width > height ) {\n\t\t\tthis.setState( {\n\t\t\t\tmaxHeight: Math.min(\n\t\t\t\t\t0.96 * height - this.headerHeight,\n\t\t\t\t\tmaxHeightWithOpenKeyboard\n\t\t\t\t),\n\t\t\t} );\n\t\t\t// In portrait orientation, set `maxHeight` to ~59% of the height.\n\t\t} else {\n\t\t\tthis.setState( {\n\t\t\t\tmaxHeight: Math.min(\n\t\t\t\t\theight * 0.59 - safeAreaBottomInset - this.headerHeight,\n\t\t\t\t\tmaxHeightWithOpenKeyboard\n\t\t\t\t),\n\t\t\t} );\n\t\t}\n\t}\n\n\tonDimensionsChange() {\n\t\tthis.onSetMaxHeight();\n\t\tthis.setState( { bounces: false } );\n\t}\n\n\tonHeaderLayout( { nativeEvent } ) {\n\t\tconst { height } = nativeEvent.layout;\n\t\t// The layout animation should only be triggered if the header\n\t\t// height has changed after being mounted.\n\t\tif (\n\t\t\tthis.headerHeight !== 0 &&\n\t\t\tMath.round( height ) !== Math.round( this.headerHeight )\n\t\t) {\n\t\t\tthis.performRegularLayoutAnimation( {\n\t\t\t\tuseLastLayoutAnimation: true,\n\t\t\t} );\n\t\t}\n\t\tthis.headerHeight = height;\n\t\tthis.onSetMaxHeight();\n\t}\n\n\tisCloseToBottom( { layoutMeasurement, contentOffset, contentSize } ) {\n\t\treturn (\n\t\t\tlayoutMeasurement.height + contentOffset.y >=\n\t\t\tcontentSize.height - contentOffset.y\n\t\t);\n\t}\n\n\tisCloseToTop( { contentOffset } ) {\n\t\treturn contentOffset.y < 10;\n\t}\n\n\tonScroll( { nativeEvent } ) {\n\t\tif ( this.isCloseToTop( nativeEvent ) ) {\n\t\t\tthis.setState( { bounces: false } );\n\t\t} else {\n\t\t\tthis.setState( { bounces: true } );\n\t\t}\n\t}\n\n\tonDismiss() {\n\t\tconst { onDismiss } = this.props;\n\n\t\tif ( onDismiss ) {\n\t\t\tonDismiss();\n\t\t}\n\n\t\tthis.onCloseBottomSheet();\n\t}\n\n\tonShouldEnableScroll( value ) {\n\t\tthis.setState( { scrollEnabled: value } );\n\t}\n\n\tonShouldSetBottomSheetMaxHeight( value ) {\n\t\tthis.setState( { isMaxHeightSet: value } );\n\t}\n\n\tisScrolling( value ) {\n\t\tthis.setState( { isScrolling: value } );\n\t}\n\n\tonHandleClosingBottomSheet( action ) {\n\t\tthis.setState( { handleClosingBottomSheet: action } );\n\t}\n\n\tonHandleHardwareButtonPress( action ) {\n\t\tthis.setState( { handleHardwareButtonPress: action } );\n\t}\n\n\tonCloseBottomSheet() {\n\t\tconst { onClose } = this.props;\n\t\tconst { handleClosingBottomSheet } = this.state;\n\t\tif ( handleClosingBottomSheet ) {\n\t\t\thandleClosingBottomSheet();\n\t\t\tthis.onHandleClosingBottomSheet( null );\n\t\t}\n\t\tif ( onClose ) {\n\t\t\tonClose();\n\t\t}\n\t\tthis.onShouldSetBottomSheetMaxHeight( true );\n\t}\n\n\tsetIsFullScreen( isFullScreen ) {\n\t\tif ( isFullScreen !== this.state.isFullScreen ) {\n\t\t\tif ( isFullScreen ) {\n\t\t\t\tthis.setState( { isFullScreen, isMaxHeightSet: false } );\n\t\t\t} else {\n\t\t\t\tthis.setState( { isFullScreen, isMaxHeightSet: true } );\n\t\t\t}\n\t\t}\n\t}\n\n\tonHardwareButtonPress() {\n\t\tconst { onClose } = this.props;\n\t\tconst { handleHardwareButtonPress } = this.state;\n\t\tif ( handleHardwareButtonPress && handleHardwareButtonPress() ) {\n\t\t\treturn;\n\t\t}\n\t\tif ( onClose ) {\n\t\t\treturn onClose();\n\t\t}\n\t}\n\n\tgetContentStyle() {\n\t\tconst { safeAreaBottomInset } = this.state;\n\t\treturn {\n\t\t\tpaddingBottom:\n\t\t\t\t( safeAreaBottomInset || 0 ) +\n\t\t\t\tstyles.scrollableContent.paddingBottom,\n\t\t};\n\t}\n\n\trender() {\n\t\tconst {\n\t\t\ttitle = '',\n\t\t\tisVisible,\n\t\t\tleftButton,\n\t\t\trightButton,\n\t\t\theader,\n\t\t\thideHeader,\n\t\t\tstyle = {},\n\t\t\tcontentStyle = {},\n\t\t\tgetStylesFromColorScheme,\n\t\t\tchildren,\n\t\t\twithHeaderSeparator = false,\n\t\t\thasNavigation,\n\t\t\t...rest\n\t\t} = this.props;\n\t\tconst {\n\t\t\tmaxHeight,\n\t\t\tbounces,\n\t\t\tsafeAreaBottomInset,\n\t\t\tsafeAreaTopInset,\n\t\t\tisScrolling,\n\t\t\tscrollEnabled,\n\t\t\tisMaxHeightSet,\n\t\t\tisFullScreen,\n\t\t} = this.state;\n\n\t\tconst panResponder = PanResponder.create( {\n\t\t\tonMoveShouldSetPanResponder: ( evt, gestureState ) => {\n\t\t\t\t// 'swiping-to-close' option is temporarily and partially disabled\n\t\t\t\t// on Android ( swipe / drag is still available in the top most area - near drag indicator).\n\t\t\t\tif ( Platform.OS === 'ios' ) {\n\t\t\t\t\t// Activates swipe down over child Touchables if the swipe is long enough.\n\t\t\t\t\t// With this we can adjust sensibility on the swipe vs tap gestures.\n\t\t\t\t\tif ( gestureState.dy > 3 && ! bounces ) {\n\t\t\t\t\t\tgestureState.dy = 0;\n\t\t\t\t\t\treturn true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn false;\n\t\t\t},\n\t\t} );\n\n\t\tconst backgroundStyle = getStylesFromColorScheme(\n\t\t\tstyles.background,\n\t\t\tstyles.backgroundDark\n\t\t);\n\n\t\tconst bottomSheetHeaderTitleStyle = getStylesFromColorScheme(\n\t\t\tstyles.bottomSheetHeaderTitle,\n\t\t\tstyles.bottomSheetHeaderTitleDark\n\t\t);\n\n\t\tlet listStyle = {};\n\t\tif ( isFullScreen ) {\n\t\t\tlistStyle = { flexGrow: 1, flexShrink: 1 };\n\t\t} else if ( isMaxHeightSet ) {\n\t\t\tlistStyle = { maxHeight };\n\n\t\t\t// Allow setting a \"static\" height of the bottom sheet\n\t\t\t// by setting the min height to the max height.\n\t\t\tif ( this.props.setMinHeightToMaxHeight ) {\n\t\t\t\tlistStyle.minHeight = maxHeight;\n\t\t\t}\n\t\t}\n\n\t\tconst listProps = {\n\t\t\tdisableScrollViewPanResponder: true,\n\t\t\tbounces,\n\t\t\tonScroll: this.onScroll,\n\t\t\tonScrollBeginDrag: this.onScrollBeginDrag,\n\t\t\tonScrollEndDrag: this.onScrollEndDrag,\n\t\t\tscrollEventThrottle: 16,\n\t\t\tcontentContainerStyle: [\n\t\t\t\tstyles.content,\n\t\t\t\thideHeader && styles.emptyHeader,\n\t\t\t\tcontentStyle,\n\t\t\t\tisFullScreen && { flexGrow: 1 },\n\t\t\t],\n\t\t\tstyle: listStyle,\n\t\t\tsafeAreaBottomInset,\n\t\t\tscrollEnabled,\n\t\t\tautomaticallyAdjustContentInsets: false,\n\t\t};\n\n\t\tconst WrapperView = hasNavigation ? View : ScrollView;\n\n\t\tconst getHeader = () => (\n\t\t\t<>\n\t\t\t\t{ header || (\n\t\t\t\t\t<View style={ styles.bottomSheetHeader }>\n\t\t\t\t\t\t<View style={ styles.flex }>{ leftButton }</View>\n\t\t\t\t\t\t<Text\n\t\t\t\t\t\t\tstyle={ bottomSheetHeaderTitleStyle }\n\t\t\t\t\t\t\tmaxFontSizeMultiplier={ 3 }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ title }\n\t\t\t\t\t\t</Text>\n\t\t\t\t\t\t<View style={ styles.flex }>{ rightButton }</View>\n\t\t\t\t\t</View>\n\t\t\t\t) }\n\t\t\t\t{ withHeaderSeparator && <View style={ styles.separator } /> }\n\t\t\t</>\n\t\t);\n\n\t\tconst showDragIndicator = () => {\n\t\t\t// If iOS or not fullscreen show the drag indicator.\n\t\t\tif ( Platform.OS === 'ios' || ! this.state.isFullScreen ) {\n\t\t\t\treturn true;\n\t\t\t}\n\n\t\t\t// Otherwise check the allowDragIndicator.\n\t\t\treturn this.props.allowDragIndicator;\n\t\t};\n\n\t\treturn (\n\t\t\t<Modal\n\t\t\t\tisVisible={ isVisible }\n\t\t\t\tstyle={ styles.bottomModal }\n\t\t\t\tanimationInTiming={ 400 }\n\t\t\t\tanimationOutTiming={ 300 }\n\t\t\t\tbackdropTransitionInTiming={ 50 }\n\t\t\t\tbackdropTransitionOutTiming={ 50 }\n\t\t\t\tbackdropOpacity={ 0.2 }\n\t\t\t\tonBackdropPress={ this.onCloseBottomSheet }\n\t\t\t\tonBackButtonPress={ this.onHardwareButtonPress }\n\t\t\t\tonSwipeComplete={ this.onCloseBottomSheet }\n\t\t\t\tonDismiss={ Platform.OS === 'ios' ? this.onDismiss : undefined }\n\t\t\t\tonModalHide={\n\t\t\t\t\tPlatform.OS === 'android' ? this.onDismiss : undefined\n\t\t\t\t}\n\t\t\t\tswipeDirection=\"down\"\n\t\t\t\tonMoveShouldSetResponder={\n\t\t\t\t\tscrollEnabled &&\n\t\t\t\t\tpanResponder.panHandlers.onMoveShouldSetResponder\n\t\t\t\t}\n\t\t\t\tonMoveShouldSetResponderCapture={\n\t\t\t\t\tscrollEnabled &&\n\t\t\t\t\tpanResponder.panHandlers.onMoveShouldSetResponderCapture\n\t\t\t\t}\n\t\t\t\tonAccessibilityEscape={ this.onCloseBottomSheet }\n\t\t\t\t// We need to prevent overwriting the onDismiss prop,\n\t\t\t\t// for this reason it is excluded from the rest object.\n\t\t\t\t{ ...omit( rest, 'onDismiss' ) }\n\t\t\t>\n\t\t\t\t<KeyboardAvoidingView\n\t\t\t\t\tbehavior={ Platform.OS === 'ios' && 'padding' }\n\t\t\t\t\tstyle={ {\n\t\t\t\t\t\t...backgroundStyle,\n\t\t\t\t\t\tborderColor: 'rgba(0, 0, 0, 0.1)',\n\t\t\t\t\t\tmarginTop:\n\t\t\t\t\t\t\tPlatform.OS === 'ios' && isFullScreen\n\t\t\t\t\t\t\t\t? safeAreaTopInset\n\t\t\t\t\t\t\t\t: 0,\n\t\t\t\t\t\tflex: isFullScreen ? 1 : undefined,\n\t\t\t\t\t\t...( Platform.OS === 'android' && isFullScreen\n\t\t\t\t\t\t\t? styles.backgroundFullScreen\n\t\t\t\t\t\t\t: {} ),\n\t\t\t\t\t\t...style,\n\t\t\t\t\t} }\n\t\t\t\t\tkeyboardVerticalOffset={ -safeAreaBottomInset }\n\t\t\t\t>\n\t\t\t\t\t<View\n\t\t\t\t\t\tstyle={ styles.header }\n\t\t\t\t\t\tonLayout={ this.onHeaderLayout }\n\t\t\t\t\t\ttestID={ `${ rest.testID || 'bottom-sheet' }-header` }\n\t\t\t\t\t>\n\t\t\t\t\t\t{ showDragIndicator() && (\n\t\t\t\t\t\t\t<View style={ styles.dragIndicator } />\n\t\t\t\t\t\t) }\n\t\t\t\t\t\t{ ! hideHeader && getHeader() }\n\t\t\t\t\t</View>\n\t\t\t\t\t<WrapperView\n\t\t\t\t\t\t{ ...( hasNavigation\n\t\t\t\t\t\t\t? { style: listProps.style }\n\t\t\t\t\t\t\t: listProps ) }\n\t\t\t\t\t>\n\t\t\t\t\t\t<BottomSheetProvider\n\t\t\t\t\t\t\tvalue={ {\n\t\t\t\t\t\t\t\tshouldEnableBottomSheetScroll:\n\t\t\t\t\t\t\t\t\tthis.onShouldEnableScroll,\n\t\t\t\t\t\t\t\tshouldEnableBottomSheetMaxHeight:\n\t\t\t\t\t\t\t\t\tthis.onShouldSetBottomSheetMaxHeight,\n\t\t\t\t\t\t\t\tisBottomSheetContentScrolling: isScrolling,\n\t\t\t\t\t\t\t\tonHandleClosingBottomSheet:\n\t\t\t\t\t\t\t\t\tthis.onHandleClosingBottomSheet,\n\t\t\t\t\t\t\t\tonHandleHardwareButtonPress:\n\t\t\t\t\t\t\t\t\tthis.onHandleHardwareButtonPress,\n\t\t\t\t\t\t\t\tlistProps,\n\t\t\t\t\t\t\t\tsetIsFullScreen: this.setIsFullScreen,\n\t\t\t\t\t\t\t\tsafeAreaBottomInset,\n\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{ hasNavigation ? (\n\t\t\t\t\t\t\t\t<>{ children }</>\n\t\t\t\t\t\t\t) : (\n\t\t\t\t\t\t\t\t<TouchableHighlight accessible={ false }>\n\t\t\t\t\t\t\t\t\t<>{ children }</>\n\t\t\t\t\t\t\t\t</TouchableHighlight>\n\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t</BottomSheetProvider>\n\t\t\t\t\t\t{ ! hasNavigation && (\n\t\t\t\t\t\t\t<View\n\t\t\t\t\t\t\t\tstyle={ {\n\t\t\t\t\t\t\t\t\theight:\n\t\t\t\t\t\t\t\t\t\tsafeAreaBottomInset ||\n\t\t\t\t\t\t\t\t\t\tstyles.scrollableContent.paddingBottom,\n\t\t\t\t\t\t\t\t} }\n\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t) }\n\t\t\t\t\t</WrapperView>\n\t\t\t\t</KeyboardAvoidingView>\n\t\t\t</Modal>\n\t\t);\n\t}\n}\n\nfunction getWidth() {\n\treturn Math.min(\n\t\tDimensions.get( 'window' ).width,\n\t\tstyles.background.maxWidth\n\t);\n}\n\nconst ThemedBottomSheet = withPreferredColorScheme( BottomSheet );\n\nThemedBottomSheet.getWidth = getWidth;\nThemedBottomSheet.Button = Button;\nThemedBottomSheet.Cell = Cell;\nThemedBottomSheet.SubSheet = BottomSheetSubSheet;\nThemedBottomSheet.NavBar = NavBar;\nThemedBottomSheet.CyclePickerCell = CyclePickerCell;\nThemedBottomSheet.PickerCell = PickerCell;\nThemedBottomSheet.SwitchCell = SwitchCell;\nThemedBottomSheet.RangeCell = RangeCell;\nThemedBottomSheet.ColorCell = ColorCell;\nThemedBottomSheet.LinkCell = LinkCell;\nThemedBottomSheet.LinkSuggestionItemCell = LinkSuggestionItemCell;\nThemedBottomSheet.RadioCell = RadioCell;\nThemedBottomSheet.NavigationScreen = NavigationScreen;\nThemedBottomSheet.NavigationContainer = NavigationContainer;\n\nexport default ThemedBottomSheet;\n"]}
@@ -102,7 +102,6 @@ class KeyboardAvoidingView extends Component {
102
102
  children,
103
103
  enabled,
104
104
  keyboardVerticalOffset,
105
- // eslint-disable-line no-unused-vars
106
105
  style,
107
106
  ...props
108
107
  } = this.props;
@@ -1 +1 @@
1
- {"version":3,"sources":["@wordpress/components/src/mobile/bottom-sheet/keyboard-avoiding-view.native.js"],"names":["Keyboard","LayoutAnimation","Platform","StyleSheet","View","Dimensions","Component","KeyboardAvoidingView","constructor","arguments","_onKeyboardChange","bind","_subscriptions","state","bottom","_relativeKeyboardHeight","keyboardFrame","windowWidth","get","width","isFloatingKeyboard","windowHeight","height","keyboardY","screenY","props","keyboardVerticalOffset","final","Math","max","event","setState","duration","easing","endCoordinates","configureNext","update","type","Types","componentDidMount","OS","addListener","componentWillUnmount","forEach","subscription","remove","render","children","enabled","style","finalStyle","bottomHeight","compose","paddingBottom","defaultProps"],"mappings":";;;AAAA;AACA;AACA;AACA,SACCA,QADD,EAECC,eAFD,EAGCC,QAHD,EAICC,UAJD,EAKCC,IALD,EAMCC,UAND,QAOO,cAPP;AASA;AACA;AACA;;AACA,SAASC,SAAT,QAA0B,oBAA1B;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,MAAMC,oBAAN,SAAmCD,SAAnC,CAA6C;AAC5CE,EAAAA,WAAW,GAAG;AACb,UAAO,GAAGC,SAAV;AAEA,SAAKC,iBAAL,GAAyB,KAAKA,iBAAL,CAAuBC,IAAvB,CAA6B,IAA7B,CAAzB;AACA,SAAKC,cAAL,GAAsB,EAAtB;AACA,SAAKC,KAAL,GAAa;AACZC,MAAAA,MAAM,EAAE;AADI,KAAb;AAGA;;AAEDC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AAe;AAAEjB,MAAAA,MAAM,EAAEQ;AAAV,KAAf;AACA;;AAEDiB,EAAAA,iBAAiB,GAAG;AACnB,QAAKrC,QAAQ,CAACsC,EAAT,KAAgB,KAArB,EAA6B;AAC5B,WAAK5B,cAAL,GAAsB,CACrBZ,QAAQ,CAACyC,WAAT,CACC,yBADD,EAEC,KAAK/B,iBAFN,CADqB,CAAtB;AAMA;AACD;;AAEDgC,EAAAA,oBAAoB,GAAG;AACtB,SAAK9B,cAAL,CAAoB+B,OAApB,CAA+BC,YAAF,IAAoB;AAChDA,MAAAA,YAAY,CAACC,MAAb;AACA,KAFD;AAGA;;AAEDC,EAAAA,MAAM,GAAG;AACR,UAAM;AACLC,MAAAA,QADK;AAELC,MAAAA,OAFK;AAGLtB,MAAAA,sBAHK;AAGmB;AACxBuB,MAAAA,KAJK;AAKL,SAAGxB;AALE,QAMF,KAAKA,KANT;AAQA,QAAIyB,UAAU,GAAGD,KAAjB;;AACA,QAAK/C,QAAQ,CAACsC,EAAT,KAAgB,KAArB,EAA6B;AAC5B,YAAMW,YAAY,GAAGH,OAAO,GAAG,KAAKnC,KAAL,CAAWC,MAAd,GAAuB,CAAnD;AACAoC,MAAAA,UAAU,GAAG/C,UAAU,CAACiD,OAAX,CAAoBH,KAApB,EAA2B;AACvCI,QAAAA,aAAa,EAAEF;AADwB,OAA3B,CAAb;AAGA;;AAED,WACC,cAAC,IAAD;AAAM,MAAA,KAAK,EAAGD;AAAd,OAAgCzB,KAAhC,GACGsB,QADH,CADD;AAKA;;AAjG2C;;AAoG7CxC,oBAAoB,CAAC+C,YAArB,GAAoC;AACnCN,EAAAA,OAAO,EAAE,IAD0B;AAEnCtB,EAAAA,sBAAsB,EAAE;AAFW,CAApC;AAKA,eAAenB,oBAAf","sourcesContent":["/**\n * External dependencies\n */\nimport {\n\tKeyboard,\n\tLayoutAnimation,\n\tPlatform,\n\tStyleSheet,\n\tView,\n\tDimensions,\n} from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { Component } from '@wordpress/element';\n\n/**\n * This is a simplified version of Facebook's KeyboardAvoidingView.\n * It's meant to work specifically with BottomSheets.\n * This fixes an issue in the bottom padding calculation, when the\n * BottomSheet was presented on Landscape, with the keyboard already present,\n * and a TextField on Autofocus (situation present on Links UI)\n */\nclass KeyboardAvoidingView extends Component {\n\tconstructor() {\n\t\tsuper( ...arguments );\n\n\t\tthis._onKeyboardChange = this._onKeyboardChange.bind( this );\n\t\tthis._subscriptions = [];\n\t\tthis.state = {\n\t\t\tbottom: 0,\n\t\t};\n\t}\n\n\t_relativeKeyboardHeight( keyboardFrame ) {\n\t\tif ( ! keyboardFrame ) {\n\t\t\treturn 0;\n\t\t}\n\n\t\tconst windowWidth = Dimensions.get( 'window' ).width;\n\t\tconst isFloatingKeyboard = keyboardFrame.width !== windowWidth;\n\t\tif ( isFloatingKeyboard ) {\n\t\t\treturn 0;\n\t\t}\n\n\t\tconst windowHeight = Dimensions.get( 'window' ).height;\n\t\tconst keyboardY =\n\t\t\tkeyboardFrame.screenY - this.props.keyboardVerticalOffset;\n\n\t\tconst final = Math.max( windowHeight - keyboardY, 0 );\n\t\treturn final;\n\t}\n\n\t/**\n\t * @param {Object} event Keyboard event.\n\t */\n\t_onKeyboardChange( event ) {\n\t\tif ( event === null ) {\n\t\t\tthis.setState( { bottom: 0 } );\n\t\t\treturn;\n\t\t}\n\n\t\tconst { duration, easing, endCoordinates } = event;\n\t\tconst height = this._relativeKeyboardHeight( endCoordinates );\n\n\t\tif ( this.state.bottom === height ) {\n\t\t\treturn;\n\t\t}\n\n\t\tif ( duration && easing ) {\n\t\t\tLayoutAnimation.configureNext( {\n\t\t\t\tduration,\n\t\t\t\tupdate: {\n\t\t\t\t\tduration,\n\t\t\t\t\ttype: LayoutAnimation.Types[ easing ] || 'keyboard',\n\t\t\t\t},\n\t\t\t} );\n\t\t}\n\t\tthis.setState( { bottom: height } );\n\t}\n\n\tcomponentDidMount() {\n\t\tif ( Platform.OS === 'ios' ) {\n\t\t\tthis._subscriptions = [\n\t\t\t\tKeyboard.addListener(\n\t\t\t\t\t'keyboardWillChangeFrame',\n\t\t\t\t\tthis._onKeyboardChange\n\t\t\t\t),\n\t\t\t];\n\t\t}\n\t}\n\n\tcomponentWillUnmount() {\n\t\tthis._subscriptions.forEach( ( subscription ) => {\n\t\t\tsubscription.remove();\n\t\t} );\n\t}\n\n\trender() {\n\t\tconst {\n\t\t\tchildren,\n\t\t\tenabled,\n\t\t\tkeyboardVerticalOffset, // eslint-disable-line no-unused-vars\n\t\t\tstyle,\n\t\t\t...props\n\t\t} = this.props;\n\n\t\tlet finalStyle = style;\n\t\tif ( Platform.OS === 'ios' ) {\n\t\t\tconst bottomHeight = enabled ? this.state.bottom : 0;\n\t\t\tfinalStyle = StyleSheet.compose( style, {\n\t\t\t\tpaddingBottom: bottomHeight,\n\t\t\t} );\n\t\t}\n\n\t\treturn (\n\t\t\t<View style={ finalStyle } { ...props }>\n\t\t\t\t{ children }\n\t\t\t</View>\n\t\t);\n\t}\n}\n\nKeyboardAvoidingView.defaultProps = {\n\tenabled: true,\n\tkeyboardVerticalOffset: 0,\n};\n\nexport default KeyboardAvoidingView;\n"]}
1
+ {"version":3,"sources":["@wordpress/components/src/mobile/bottom-sheet/keyboard-avoiding-view.native.js"],"names":["Keyboard","LayoutAnimation","Platform","StyleSheet","View","Dimensions","Component","KeyboardAvoidingView","constructor","arguments","_onKeyboardChange","bind","_subscriptions","state","bottom","_relativeKeyboardHeight","keyboardFrame","windowWidth","get","width","isFloatingKeyboard","windowHeight","height","keyboardY","screenY","props","keyboardVerticalOffset","final","Math","max","event","setState","duration","easing","endCoordinates","configureNext","update","type","Types","componentDidMount","OS","addListener","componentWillUnmount","forEach","subscription","remove","render","children","enabled","style","finalStyle","bottomHeight","compose","paddingBottom","defaultProps"],"mappings":";;;AAAA;AACA;AACA;AACA,SACCA,QADD,EAECC,eAFD,EAGCC,QAHD,EAICC,UAJD,EAKCC,IALD,EAMCC,UAND,QAOO,cA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cAAC,IAAD;AAAM,MAAA,KAAK,EAAGD;AAAd,OAAgCzB,KAAhC,GACGsB,QADH,CADD;AAKA;;AA5F2C;;AA+F7CxC,oBAAoB,CAAC+C,YAArB,GAAoC;AACnCN,EAAAA,OAAO,EAAE,IAD0B;AAEnCtB,EAAAA,sBAAsB,EAAE;AAFW,CAApC;AAKA,eAAenB,oBAAf","sourcesContent":["/**\n * External dependencies\n */\nimport {\n\tKeyboard,\n\tLayoutAnimation,\n\tPlatform,\n\tStyleSheet,\n\tView,\n\tDimensions,\n} from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { Component } from '@wordpress/element';\n\n/**\n * This is a simplified version of Facebook's KeyboardAvoidingView.\n * It's meant to work specifically with BottomSheets.\n * This fixes an issue in the bottom padding calculation, when the\n * BottomSheet was presented on Landscape, with the keyboard already present,\n * and a TextField on Autofocus (situation present on Links UI)\n */\nclass KeyboardAvoidingView extends Component {\n\tconstructor() {\n\t\tsuper( ...arguments );\n\n\t\tthis._onKeyboardChange = this._onKeyboardChange.bind( this );\n\t\tthis._subscriptions = [];\n\t\tthis.state = {\n\t\t\tbottom: 0,\n\t\t};\n\t}\n\n\t_relativeKeyboardHeight( keyboardFrame ) {\n\t\tif ( ! keyboardFrame ) {\n\t\t\treturn 0;\n\t\t}\n\n\t\tconst windowWidth = Dimensions.get( 'window' ).width;\n\t\tconst isFloatingKeyboard = keyboardFrame.width !== windowWidth;\n\t\tif ( isFloatingKeyboard ) {\n\t\t\treturn 0;\n\t\t}\n\n\t\tconst windowHeight = Dimensions.get( 'window' ).height;\n\t\tconst keyboardY =\n\t\t\tkeyboardFrame.screenY - this.props.keyboardVerticalOffset;\n\n\t\tconst final = Math.max( windowHeight - keyboardY, 0 );\n\t\treturn final;\n\t}\n\n\t/**\n\t * @param {Object} event Keyboard event.\n\t */\n\t_onKeyboardChange( event ) {\n\t\tif ( event === null ) {\n\t\t\tthis.setState( { bottom: 0 } );\n\t\t\treturn;\n\t\t}\n\n\t\tconst { duration, easing, endCoordinates } = event;\n\t\tconst height = this._relativeKeyboardHeight( endCoordinates );\n\n\t\tif ( this.state.bottom === height ) {\n\t\t\treturn;\n\t\t}\n\n\t\tif ( duration && easing ) {\n\t\t\tLayoutAnimation.configureNext( {\n\t\t\t\tduration,\n\t\t\t\tupdate: {\n\t\t\t\t\tduration,\n\t\t\t\t\ttype: LayoutAnimation.Types[ easing ] || 'keyboard',\n\t\t\t\t},\n\t\t\t} );\n\t\t}\n\t\tthis.setState( { bottom: height } );\n\t}\n\n\tcomponentDidMount() {\n\t\tif ( Platform.OS === 'ios' ) {\n\t\t\tthis._subscriptions = [\n\t\t\t\tKeyboard.addListener(\n\t\t\t\t\t'keyboardWillChangeFrame',\n\t\t\t\t\tthis._onKeyboardChange\n\t\t\t\t),\n\t\t\t];\n\t\t}\n\t}\n\n\tcomponentWillUnmount() {\n\t\tthis._subscriptions.forEach( ( subscription ) => {\n\t\t\tsubscription.remove();\n\t\t} );\n\t}\n\n\trender() {\n\t\tconst { children, enabled, keyboardVerticalOffset, style, ...props } =\n\t\t\tthis.props;\n\n\t\tlet finalStyle = style;\n\t\tif ( Platform.OS === 'ios' ) {\n\t\t\tconst bottomHeight = enabled ? this.state.bottom : 0;\n\t\t\tfinalStyle = StyleSheet.compose( style, {\n\t\t\t\tpaddingBottom: bottomHeight,\n\t\t\t} );\n\t\t}\n\n\t\treturn (\n\t\t\t<View style={ finalStyle } { ...props }>\n\t\t\t\t{ children }\n\t\t\t</View>\n\t\t);\n\t}\n}\n\nKeyboardAvoidingView.defaultProps = {\n\tenabled: true,\n\tkeyboardVerticalOffset: 0,\n};\n\nexport default KeyboardAvoidingView;\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["@wordpress/components/src/mobile/bottom-sheet/picker-cell.native.js"],"names":["find","Cell","Picker","BottomSheetPickerCell","props","options","hideCancelButton","onChangeValue","value","cellProps","picker","onCellPress","presentPicker","onChange","newValue","option","label","instance"],"mappings":";;;AAAA;AACA;AACA;AACA,SAASA,IAAT,QAAqB,QAArB;AAEA;AACA;AACA;;AACA,OAAOC,IAAP,MAAiB,QAAjB;AACA,OAAOC,MAAP,MAAmB,WAAnB;AAEA,eAAe,SAASC,qBAAT,CAAgCC,KAAhC,EAAwC;AACtD,QAAM;AACLC,IAAAA,OADK;AAELC,IAAAA,gBAFK;AAGLC,IAAAA,aAHK;AAILC,IAAAA,KAJK;AAKL,OAAGC;AALE,MAMFL,KANJ;AAQA,MAAIM,MAAJ;;AAEA,QAAMC,WAAW,GAAG,MAAM;AACzBD,IAAAA,MAAM,CAACE,aAAP;AACA,GAFD;;AAIA,QAAMC,QAAQ,GAAKC,QAAF,IAAgB;AAChCP,IAAAA,aAAa,CAAEO,QAAF,CAAb;AACA,GAFD;;AAIA,QAAMC,MAAM,GAAGf,IAAI,CAAEK,OAAF,EAAW;AAAEG,IAAAA;AAAF,GAAX,CAAnB;AACA,QAAMQ,KAAK,GAAGD,MAAM,GAAGA,MAAM,CAACC,KAAV,GAAkBR,KAAtC;AAEA,SACC,cAAC,IAAD;AACC,IAAA,OAAO,EAAGG,WADX;AAEC,IAAA,QAAQ,EAAG,KAFZ;AAGC,IAAA,KAAK,EAAGK;AAHT,KAIMP,SAJN,GAMC,cAAC,MAAD;AACC,IAAA,SAAS,MADV;AAEC,IAAA,gBAAgB,EAAGH,gBAFpB;AAGC,IAAA,GAAG,EAAKW,QAAF,IAAkBP,MAAM,GAAGO,QAHlC;AAIC,IAAA,OAAO,EAAGZ,OAJX;AAKC,IAAA,QAAQ,EAAGQ;AALZ,IAND,CADD;AAgBA","sourcesContent":["/**\n * External dependencies\n */\nimport { find } from 'lodash';\n\n/**\n * Internal dependencies\n */\nimport Cell from './cell';\nimport Picker from '../picker';\n\nexport default function BottomSheetPickerCell( props ) {\n\tconst {\n\t\toptions,\n\t\thideCancelButton,\n\t\tonChangeValue,\n\t\tvalue,\n\t\t...cellProps\n\t} = props;\n\n\tlet picker;\n\n\tconst onCellPress = () => {\n\t\tpicker.presentPicker();\n\t};\n\n\tconst onChange = ( newValue ) => {\n\t\tonChangeValue( newValue );\n\t};\n\n\tconst option = find( options, { value } );\n\tconst label = option ? option.label : value;\n\n\treturn (\n\t\t<Cell\n\t\t\tonPress={ onCellPress }\n\t\t\teditable={ false }\n\t\t\tvalue={ label }\n\t\t\t{ ...cellProps }\n\t\t>\n\t\t\t<Picker\n\t\t\t\tleftAlign\n\t\t\t\thideCancelButton={ hideCancelButton }\n\t\t\t\tref={ ( instance ) => ( picker = instance ) }\n\t\t\t\toptions={ options }\n\t\t\t\tonChange={ onChange }\n\t\t\t/>\n\t\t</Cell>\n\t);\n}\n"]}
1
+ {"version":3,"sources":["@wordpress/components/src/mobile/bottom-sheet/picker-cell.native.js"],"names":["find","Cell","Picker","BottomSheetPickerCell","props","options","hideCancelButton","onChangeValue","value","cellProps","picker","onCellPress","presentPicker","onChange","newValue","option","label","instance"],"mappings":";;;AAAA;AACA;AACA;AACA,SAASA,IAAT,QAAqB,QAArB;AAEA;AACA;AACA;;AACA,OAAOC,IAAP,MAAiB,QAAjB;AACA,OAAOC,MAAP,MAAmB,WAAnB;AAEA,eAAe,SAASC,qBAAT,CAAgCC,KAAhC,EAAwC;AACtD,QAAM;AAAEC,IAAAA,OAAF;AAAWC,IAAAA,gBAAX;AAA6BC,IAAAA,aAA7B;AAA4CC,IAAAA,KAA5C;AAAmD,OAAGC;AAAtD,MACLL,KADD;AAGA,MAAIM,MAAJ;;AAEA,QAAMC,WAAW,GAAG,MAAM;AACzBD,IAAAA,MAAM,CAACE,aAAP;AACA,GAFD;;AAIA,QAAMC,QAAQ,GAAKC,QAAF,IAAgB;AAChCP,IAAAA,aAAa,CAAEO,QAAF,CAAb;AACA,GAFD;;AAIA,QAAMC,MAAM,GAAGf,IAAI,CAAEK,OAAF,EAAW;AAAEG,IAAAA;AAAF,GAAX,CAAnB;AACA,QAAMQ,KAAK,GAAGD,MAAM,GAAGA,MAAM,CAACC,KAAV,GAAkBR,KAAtC;AAEA,SACC,cAAC,IAAD;AACC,IAAA,OAAO,EAAGG,WADX;AAEC,IAAA,QAAQ,EAAG,KAFZ;AAGC,IAAA,KAAK,EAAGK;AAHT,KAIMP,SAJN,GAMC,cAAC,MAAD;AACC,IAAA,SAAS,MADV;AAEC,IAAA,gBAAgB,EAAGH,gBAFpB;AAGC,IAAA,GAAG,EAAKW,QAAF,IAAkBP,MAAM,GAAGO,QAHlC;AAIC,IAAA,OAAO,EAAGZ,OAJX;AAKC,IAAA,QAAQ,EAAGQ;AALZ,IAND,CADD;AAgBA","sourcesContent":["/**\n * External dependencies\n */\nimport { find } from 'lodash';\n\n/**\n * Internal dependencies\n */\nimport Cell from './cell';\nimport Picker from '../picker';\n\nexport default function BottomSheetPickerCell( props ) {\n\tconst { options, hideCancelButton, onChangeValue, value, ...cellProps } =\n\t\tprops;\n\n\tlet picker;\n\n\tconst onCellPress = () => {\n\t\tpicker.presentPicker();\n\t};\n\n\tconst onChange = ( newValue ) => {\n\t\tonChangeValue( newValue );\n\t};\n\n\tconst option = find( options, { value } );\n\tconst label = option ? option.label : value;\n\n\treturn (\n\t\t<Cell\n\t\t\tonPress={ onCellPress }\n\t\t\teditable={ false }\n\t\t\tvalue={ label }\n\t\t\t{ ...cellProps }\n\t\t>\n\t\t\t<Picker\n\t\t\t\tleftAlign\n\t\t\t\thideCancelButton={ hideCancelButton }\n\t\t\t\tref={ ( instance ) => ( picker = instance ) }\n\t\t\t\toptions={ options }\n\t\t\t\tonChange={ onChange }\n\t\t\t/>\n\t\t</Cell>\n\t);\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["@wordpress/components/src/mobile/bottom-sheet/stepper-cell/index.native.js"],"names":["AccessibilityInfo","View","Platform","__","sprintf","Component","withPreferredColorScheme","Cell","Stepper","styles","RangeTextInput","toFixed","STEP_DELAY","DEFAULT_STEP","isIOS","OS","BottomSheetStepperCell","constructor","props","announceValue","bind","onDecrementValue","onDecrementValuePressIn","onIncrementValue","onIncrementValuePressIn","onPressOut","value","defaultValue","min","initialValue","state","inputValue","stepperValue","componentWillUnmount","clearTimeout","timeout","clearInterval","interval","timeoutAnnounceValue","step","max","onChange","decimalNum","newValue","parseInt","undefined","setState","setTimeout","startPressInterval","callback","speed","counter","setInterval","label","unitLabel","announceForAccessibility","render","settingLabel","icon","separatorType","children","shouldDisplayTextInput","preview","openUnitPicker","cellContainerStyle","isMinValue","isMaxValue","labelStyle","cellLabel","cellLabelNoIcon","getAccessibilityHint","accessibilityLabel","containerStyle","rowContainer","containerIOS","containerAndroid","name","event","nativeEvent","actionName","columnContainer","cellRowStyles","defaultProps"],"mappings":";;AAAA;AACA;AACA;AACA,SAASA,iBAAT,EAA4BC,IAA5B,EAAkCC,QAAlC,QAAkD,cAAlD;AAEA;AACA;AACA;;AACA,SAASC,EAAT,EAAaC,OAAb,QAA4B,iBAA5B;AACA,SAASC,SAAT,QAA0B,oBAA1B;AACA,SAASC,wBAAT,QAAyC,oBAAzC;AAEA;AACA;AACA;;AACA,OAAOC,IAAP,MAAiB,SAAjB;AACA,OAAOC,OAAP,MAAoB,WAApB;AACA,OAAOC,MAAP,MAAmB,cAAnB;AACA,OAAOC,cAAP,MAA2B,qBAA3B;AACA,SAASC,OAAT,QAAwB,aAAxB;AAEA,MAAMC,UAAU,GAAG,GAAnB;AACA,MAAMC,YAAY,GAAG,CAArB;AAEA,MAAMC,KAAK,GAAGZ,QAAQ,CAACa,EAAT,KAAgB,KAA9B;;AAEA,MAAMC,sBAAN,SAAqCX,SAArC,CAA+C;AAC9CY,EAAAA,WAAW,CAAEC,KAAF,EAAU;AACpB,UAAOA,KAAP;AAEA,SAAKC,aAAL,GAAqB,KAAKA,aAAL,CAAmBC,IAAnB,CAAyB,IAAzB,CAArB;AACA,SAAKC,gBAAL,GAAwB,KAAKA,gBAAL,CAAsBD,IAAtB,CAA4B,IAA5B,CAAxB;AACA,SAAKE,uBAAL,GAA+B,KAAKA,uBAAL,CAA6BF,IAA7B,CAC9B,IAD8B,CAA/B;AAGA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,kBADa,EAEpBF,OAAO,IAAIrD,MAAM,CAACuE,eAFE,EAGpBhB,kBAHoB,CAFtB;AAOC,MAAA,qBAAqB,EACpBF,OAAO,GAAGU,cAAH,GAAoB/D,MAAM,CAACwE,aARpC;AAUC,MAAA,QAAQ,EAAG,KAVZ;AAWC,MAAA,IAAI,EAAGvB,IAXR;AAYC,MAAA,KAAK,EAAGL,KAZT;AAaC,MAAA,UAAU,EAAGc,UAbd;AAcC,MAAA,SAAS,EAAG,IAdb;AAeC,MAAA,aAAa,EAAGR;AAfjB,OAiBC,cAAC,IAAD;AAAM,MAAA,KAAK,EAAGG,OAAO,IAAIU;AAAzB,OACGV,OADH,EAEC,cAAC,OAAD;AACC,MAAA,UAAU,EAAGI,UADd;AAEC,MAAA,UAAU,EAAGD,UAFd;AAGC,MAAA,kBAAkB,EACjB,KAAK3C,uBAJP;AAMC,MAAA,kBAAkB,EACjB,KAAKE,uBAPP;AASC,MAAA,UAAU,EAAG,KAAKC,UATnB;AAUC,MAAA,KAAK,EAAGC,KAVT;AAWC,MAAA,sBAAsB,EACrBmC;AAZF,OAeGA,sBAAsB,IACvB,cAAC,cAAD;AACC,MAAA,KAAK,EAAGR,KADT;AAEC,MAAA,QAAQ,EAAGZ,QAFZ;AAGC,MAAA,YAAY,EAAI,GAAGV,UAAY,EAHhC;AAIC,MAAA,KAAK,EAAGL,KAJT;AAKC,MAAA,GAAG,EAAGE,GALP;AAMC,MAAA,IAAI,EAAG,CANR;AAOC,MAAA,UAAU,EAAGc;AAPd,OASGkB,QATH,CAhBF,CAFD,CAjBD,CADD,CA1BD,CADD;AAiFA;;AAtO6C;;AAyO/C5C,sBAAsB,CAACkE,YAAvB,GAAsC;AACrC3C,EAAAA,IAAI,EAAE1B;AAD+B,CAAtC;AAIA,eAAeP,wBAAwB,CAAEU,sBAAF,CAAvC","sourcesContent":["/**\n * External dependencies\n */\nimport { AccessibilityInfo, View, Platform } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { __, sprintf } from '@wordpress/i18n';\nimport { Component } from '@wordpress/element';\nimport { withPreferredColorScheme } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport Cell from '../cell';\nimport Stepper from './stepper';\nimport styles from './style.scss';\nimport RangeTextInput from '../range-text-input';\nimport { toFixed } from '../../utils';\n\nconst STEP_DELAY = 200;\nconst DEFAULT_STEP = 1;\n\nconst isIOS = Platform.OS === 'ios';\n\nclass BottomSheetStepperCell extends Component {\n\tconstructor( props ) {\n\t\tsuper( props );\n\n\t\tthis.announceValue = this.announceValue.bind( this );\n\t\tthis.onDecrementValue = this.onDecrementValue.bind( this );\n\t\tthis.onDecrementValuePressIn = this.onDecrementValuePressIn.bind(\n\t\t\tthis\n\t\t);\n\t\tthis.onIncrementValue = this.onIncrementValue.bind( this );\n\t\tthis.onIncrementValuePressIn = this.onIncrementValuePressIn.bind(\n\t\t\tthis\n\t\t);\n\t\tthis.onPressOut = this.onPressOut.bind( this );\n\n\t\tconst { value, defaultValue, min } = props;\n\n\t\tconst initialValue = value || defaultValue || min;\n\n\t\tthis.state = {\n\t\t\tinputValue: initialValue,\n\t\t\tstepperValue: initialValue,\n\t\t};\n\t}\n\n\tcomponentWillUnmount() {\n\t\tclearTimeout( this.timeout );\n\t\tclearInterval( this.interval );\n\t\tclearTimeout( this.timeoutAnnounceValue );\n\t}\n\n\tonIncrementValue() {\n\t\tconst { step, max, onChange, value, decimalNum } = this.props;\n\t\tlet newValue = toFixed( value + step, decimalNum );\n\t\tnewValue =\n\t\t\tparseInt( newValue ) === newValue ? parseInt( newValue ) : newValue;\n\t\tif ( newValue <= max || max === undefined ) {\n\t\t\tonChange( newValue );\n\t\t\tthis.setState( {\n\t\t\t\tinputValue: newValue,\n\t\t\t} );\n\t\t\tthis.announceValue( newValue );\n\t\t}\n\t}\n\n\tonDecrementValue() {\n\t\tconst { step, min, onChange, value, decimalNum } = this.props;\n\t\tlet newValue = toFixed( value - step, decimalNum );\n\t\tnewValue =\n\t\t\tparseInt( newValue ) === newValue ? parseInt( newValue ) : newValue;\n\t\tif ( newValue >= min ) {\n\t\t\tonChange( newValue );\n\t\t\tthis.setState( {\n\t\t\t\tinputValue: newValue,\n\t\t\t} );\n\t\t\tthis.announceValue( newValue );\n\t\t}\n\t}\n\n\tonIncrementValuePressIn() {\n\t\tthis.onIncrementValue();\n\t\tthis.timeout = setTimeout( () => {\n\t\t\tthis.startPressInterval( this.onIncrementValue );\n\t\t}, 500 );\n\t}\n\n\tonDecrementValuePressIn() {\n\t\tthis.onDecrementValue();\n\t\tthis.timeout = setTimeout( () => {\n\t\t\tthis.startPressInterval( this.onDecrementValue );\n\t\t}, 500 );\n\t}\n\n\tonPressOut() {\n\t\tclearTimeout( this.timeout );\n\t\tclearInterval( this.interval );\n\t}\n\n\tstartPressInterval( callback, speed = STEP_DELAY ) {\n\t\tlet counter = 0;\n\t\tthis.interval = setInterval( () => {\n\t\t\tcallback();\n\t\t\tcounter += 1;\n\n\t\t\tif ( counter === 10 ) {\n\t\t\t\tclearInterval( this.interval );\n\t\t\t\tthis.startPressInterval( callback, speed / 2 );\n\t\t\t}\n\t\t}, speed );\n\t}\n\n\tannounceValue( value ) {\n\t\tconst { label, unitLabel = '' } = this.props;\n\n\t\tif ( isIOS ) {\n\t\t\t// On Android it triggers the accessibilityLabel with the value change\n\t\t\tclearTimeout( this.timeoutAnnounceValue );\n\t\t\tthis.timeoutAnnounceValue = setTimeout( () => {\n\t\t\t\tAccessibilityInfo.announceForAccessibility(\n\t\t\t\t\t`${ value } ${ unitLabel } ${ label }`\n\t\t\t\t);\n\t\t\t}, 300 );\n\t\t}\n\t}\n\n\trender() {\n\t\tconst {\n\t\t\tlabel,\n\t\t\tsettingLabel = 'Value',\n\t\t\tunitLabel = '',\n\t\t\ticon,\n\t\t\tmin,\n\t\t\tmax,\n\t\t\tvalue,\n\t\t\tseparatorType,\n\t\t\tchildren,\n\t\t\tshouldDisplayTextInput = false,\n\t\t\tpreview,\n\t\t\tonChange,\n\t\t\topenUnitPicker,\n\t\t\tdecimalNum,\n\t\t\tcellContainerStyle,\n\t\t} = this.props;\n\t\tconst { inputValue } = this.state;\n\t\tconst isMinValue = value === min;\n\t\tconst isMaxValue = value === max;\n\t\tconst labelStyle = [\n\t\t\tstyles.cellLabel,\n\t\t\t! icon ? styles.cellLabelNoIcon : {},\n\t\t];\n\n\t\tconst getAccessibilityHint = () => {\n\t\t\treturn openUnitPicker ? __( 'double-tap to change unit' ) : '';\n\t\t};\n\n\t\tconst accessibilityLabel = sprintf(\n\t\t\t/* translators: accessibility text. Inform about current value. %1$s: Control label %2$s: setting label (example: width), %3$s: Current value. %4$s: value measurement unit (example: pixels) */\n\t\t\t__( '%1$s. %2$s is %3$s %4$s.' ),\n\t\t\tlabel,\n\t\t\tsettingLabel,\n\t\t\tvalue,\n\t\t\tunitLabel\n\t\t);\n\n\t\tconst containerStyle = [\n\t\t\tstyles.rowContainer,\n\t\t\tisIOS ? styles.containerIOS : styles.containerAndroid,\n\t\t];\n\n\t\treturn (\n\t\t\t<View\n\t\t\t\taccessible={ true }\n\t\t\t\taccessibilityRole=\"adjustable\"\n\t\t\t\taccessibilityLabel={ accessibilityLabel }\n\t\t\t\taccessibilityHint={ getAccessibilityHint() }\n\t\t\t\taccessibilityActions={ [\n\t\t\t\t\t{ name: 'increment' },\n\t\t\t\t\t{ name: 'decrement' },\n\t\t\t\t\t{ name: 'activate' },\n\t\t\t\t] }\n\t\t\t\tonAccessibilityAction={ ( event ) => {\n\t\t\t\t\tswitch ( event.nativeEvent.actionName ) {\n\t\t\t\t\t\tcase 'increment':\n\t\t\t\t\t\t\tthis.onIncrementValue();\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'decrement':\n\t\t\t\t\t\t\tthis.onDecrementValue();\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'activate':\n\t\t\t\t\t\t\tif ( openUnitPicker ) {\n\t\t\t\t\t\t\t\topenUnitPicker();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t} }\n\t\t\t>\n\t\t\t\t<View importantForAccessibility=\"no-hide-descendants\">\n\t\t\t\t\t<Cell\n\t\t\t\t\t\taccessible={ false }\n\t\t\t\t\t\tcellContainerStyle={ [\n\t\t\t\t\t\t\tstyles.cellContainerStyle,\n\t\t\t\t\t\t\tpreview && styles.columnContainer,\n\t\t\t\t\t\t\tcellContainerStyle,\n\t\t\t\t\t\t] }\n\t\t\t\t\t\tcellRowContainerStyle={\n\t\t\t\t\t\t\tpreview ? containerStyle : styles.cellRowStyles\n\t\t\t\t\t\t}\n\t\t\t\t\t\teditable={ false }\n\t\t\t\t\t\ticon={ icon }\n\t\t\t\t\t\tlabel={ label }\n\t\t\t\t\t\tlabelStyle={ labelStyle }\n\t\t\t\t\t\tleftAlign={ true }\n\t\t\t\t\t\tseparatorType={ separatorType }\n\t\t\t\t\t>\n\t\t\t\t\t\t<View style={ preview && containerStyle }>\n\t\t\t\t\t\t\t{ preview }\n\t\t\t\t\t\t\t<Stepper\n\t\t\t\t\t\t\t\tisMaxValue={ isMaxValue }\n\t\t\t\t\t\t\t\tisMinValue={ isMinValue }\n\t\t\t\t\t\t\t\tonPressInDecrement={\n\t\t\t\t\t\t\t\t\tthis.onDecrementValuePressIn\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tonPressInIncrement={\n\t\t\t\t\t\t\t\t\tthis.onIncrementValuePressIn\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tonPressOut={ this.onPressOut }\n\t\t\t\t\t\t\t\tvalue={ value }\n\t\t\t\t\t\t\t\tshouldDisplayTextInput={\n\t\t\t\t\t\t\t\t\tshouldDisplayTextInput\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{ shouldDisplayTextInput && (\n\t\t\t\t\t\t\t\t\t<RangeTextInput\n\t\t\t\t\t\t\t\t\t\tlabel={ label }\n\t\t\t\t\t\t\t\t\t\tonChange={ onChange }\n\t\t\t\t\t\t\t\t\t\tdefaultValue={ `${ inputValue }` }\n\t\t\t\t\t\t\t\t\t\tvalue={ value }\n\t\t\t\t\t\t\t\t\t\tmin={ min }\n\t\t\t\t\t\t\t\t\t\tstep={ 1 }\n\t\t\t\t\t\t\t\t\t\tdecimalNum={ decimalNum }\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{ children }\n\t\t\t\t\t\t\t\t\t</RangeTextInput>\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t</Stepper>\n\t\t\t\t\t\t</View>\n\t\t\t\t\t</Cell>\n\t\t\t\t</View>\n\t\t\t</View>\n\t\t);\n\t}\n}\n\nBottomSheetStepperCell.defaultProps = {\n\tstep: DEFAULT_STEP,\n};\n\nexport default withPreferredColorScheme( BottomSheetStepperCell );\n"]}
1
+ {"version":3,"sources":["@wordpress/components/src/mobile/bottom-sheet/stepper-cell/index.native.js"],"names":["AccessibilityInfo","View","Platform","__","sprintf","Component","withPreferredColorScheme","Cell","Stepper","styles","RangeTextInput","toFixed","STEP_DELAY","DEFAULT_STEP","isIOS","OS","BottomSheetStepperCell","constructor","props","announceValue","bind","onDecrementValue","onDecrementValuePressIn","onIncrementValue","onIncrementValuePressIn","onPressOut","value","defaultValue","min","initialValue","state","inputValue","stepperValue","componentWillUnmount","clearTimeout","timeout","clearInterval","interval","timeoutAnnounceValue","step","max","onChange","decimalNum","newValue","parseInt","undefined","setState","setTimeout","startPressInterval","callback","speed","counter","setInterval","label","unitLabel","announceForAccessibility","render","settingLabel","icon","separatorType","children","shouldDisplayTextInput","preview","openUnitPicker","cellContainerStyle","isMinValue","isMaxValue","labelStyle","cellLabel","cellLabelNoIcon","getAccessibilityHint","accessibilityLabel","containerStyle","rowContainer","containerIOS","containerAndroid","name","event","nativeEvent","actionName","columnContainer","cellRowStyles","defaultProps"],"mappings":";;AAAA;AACA;AACA;AACA,SAASA,iBAAT,EAA4BC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D;AACC,MAAA,UAAU,EAAGI,UADd;AAEC,MAAA,UAAU,EAAGD,UAFd;AAGC,MAAA,kBAAkB,EACjB,KAAK3C,uBAJP;AAMC,MAAA,kBAAkB,EACjB,KAAKE,uBAPP;AASC,MAAA,UAAU,EAAG,KAAKC,UATnB;AAUC,MAAA,KAAK,EAAGC,KAVT;AAWC,MAAA,sBAAsB,EACrBmC;AAZF,OAeGA,sBAAsB,IACvB,cAAC,cAAD;AACC,MAAA,KAAK,EAAGR,KADT;AAEC,MAAA,QAAQ,EAAGZ,QAFZ;AAGC,MAAA,YAAY,EAAI,GAAGV,UAAY,EAHhC;AAIC,MAAA,KAAK,EAAGL,KAJT;AAKC,MAAA,GAAG,EAAGE,GALP;AAMC,MAAA,IAAI,EAAG,CANR;AAOC,MAAA,UAAU,EAAGc;AAPd,OASGkB,QATH,CAhBF,CAFD,CAjBD,CADD,CA1BD,CADD;AAiFA;;AApO6C;;AAuO/C5C,sBAAsB,CAACkE,YAAvB,GAAsC;AACrC3C,EAAAA,IAAI,EAAE1B;AAD+B,CAAtC;AAIA,eAAeP,wBAAwB,CAAEU,sBAAF,CAAvC","sourcesContent":["/**\n * External dependencies\n */\nimport { AccessibilityInfo, View, Platform } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { __, sprintf } from '@wordpress/i18n';\nimport { Component } from '@wordpress/element';\nimport { withPreferredColorScheme } from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport Cell from '../cell';\nimport Stepper from './stepper';\nimport styles from './style.scss';\nimport RangeTextInput from '../range-text-input';\nimport { toFixed } from '../../utils';\n\nconst STEP_DELAY = 200;\nconst DEFAULT_STEP = 1;\n\nconst isIOS = Platform.OS === 'ios';\n\nclass BottomSheetStepperCell extends Component {\n\tconstructor( props ) {\n\t\tsuper( props );\n\n\t\tthis.announceValue = this.announceValue.bind( this );\n\t\tthis.onDecrementValue = this.onDecrementValue.bind( this );\n\t\tthis.onDecrementValuePressIn =\n\t\t\tthis.onDecrementValuePressIn.bind( this );\n\t\tthis.onIncrementValue = this.onIncrementValue.bind( this );\n\t\tthis.onIncrementValuePressIn =\n\t\t\tthis.onIncrementValuePressIn.bind( this );\n\t\tthis.onPressOut = this.onPressOut.bind( this );\n\n\t\tconst { value, defaultValue, min } = props;\n\n\t\tconst initialValue = value || defaultValue || min;\n\n\t\tthis.state = {\n\t\t\tinputValue: initialValue,\n\t\t\tstepperValue: initialValue,\n\t\t};\n\t}\n\n\tcomponentWillUnmount() {\n\t\tclearTimeout( this.timeout );\n\t\tclearInterval( this.interval );\n\t\tclearTimeout( this.timeoutAnnounceValue );\n\t}\n\n\tonIncrementValue() {\n\t\tconst { step, max, onChange, value, decimalNum } = this.props;\n\t\tlet newValue = toFixed( value + step, decimalNum );\n\t\tnewValue =\n\t\t\tparseInt( newValue ) === newValue ? parseInt( newValue ) : newValue;\n\t\tif ( newValue <= max || max === undefined ) {\n\t\t\tonChange( newValue );\n\t\t\tthis.setState( {\n\t\t\t\tinputValue: newValue,\n\t\t\t} );\n\t\t\tthis.announceValue( newValue );\n\t\t}\n\t}\n\n\tonDecrementValue() {\n\t\tconst { step, min, onChange, value, decimalNum } = this.props;\n\t\tlet newValue = toFixed( value - step, decimalNum );\n\t\tnewValue =\n\t\t\tparseInt( newValue ) === newValue ? parseInt( newValue ) : newValue;\n\t\tif ( newValue >= min ) {\n\t\t\tonChange( newValue );\n\t\t\tthis.setState( {\n\t\t\t\tinputValue: newValue,\n\t\t\t} );\n\t\t\tthis.announceValue( newValue );\n\t\t}\n\t}\n\n\tonIncrementValuePressIn() {\n\t\tthis.onIncrementValue();\n\t\tthis.timeout = setTimeout( () => {\n\t\t\tthis.startPressInterval( this.onIncrementValue );\n\t\t}, 500 );\n\t}\n\n\tonDecrementValuePressIn() {\n\t\tthis.onDecrementValue();\n\t\tthis.timeout = setTimeout( () => {\n\t\t\tthis.startPressInterval( this.onDecrementValue );\n\t\t}, 500 );\n\t}\n\n\tonPressOut() {\n\t\tclearTimeout( this.timeout );\n\t\tclearInterval( this.interval );\n\t}\n\n\tstartPressInterval( callback, speed = STEP_DELAY ) {\n\t\tlet counter = 0;\n\t\tthis.interval = setInterval( () => {\n\t\t\tcallback();\n\t\t\tcounter += 1;\n\n\t\t\tif ( counter === 10 ) {\n\t\t\t\tclearInterval( this.interval );\n\t\t\t\tthis.startPressInterval( callback, speed / 2 );\n\t\t\t}\n\t\t}, speed );\n\t}\n\n\tannounceValue( value ) {\n\t\tconst { label, unitLabel = '' } = this.props;\n\n\t\tif ( isIOS ) {\n\t\t\t// On Android it triggers the accessibilityLabel with the value change\n\t\t\tclearTimeout( this.timeoutAnnounceValue );\n\t\t\tthis.timeoutAnnounceValue = setTimeout( () => {\n\t\t\t\tAccessibilityInfo.announceForAccessibility(\n\t\t\t\t\t`${ value } ${ unitLabel } ${ label }`\n\t\t\t\t);\n\t\t\t}, 300 );\n\t\t}\n\t}\n\n\trender() {\n\t\tconst {\n\t\t\tlabel,\n\t\t\tsettingLabel = 'Value',\n\t\t\tunitLabel = '',\n\t\t\ticon,\n\t\t\tmin,\n\t\t\tmax,\n\t\t\tvalue,\n\t\t\tseparatorType,\n\t\t\tchildren,\n\t\t\tshouldDisplayTextInput = false,\n\t\t\tpreview,\n\t\t\tonChange,\n\t\t\topenUnitPicker,\n\t\t\tdecimalNum,\n\t\t\tcellContainerStyle,\n\t\t} = this.props;\n\t\tconst { inputValue } = this.state;\n\t\tconst isMinValue = value === min;\n\t\tconst isMaxValue = value === max;\n\t\tconst labelStyle = [\n\t\t\tstyles.cellLabel,\n\t\t\t! icon ? styles.cellLabelNoIcon : {},\n\t\t];\n\n\t\tconst getAccessibilityHint = () => {\n\t\t\treturn openUnitPicker ? __( 'double-tap to change unit' ) : '';\n\t\t};\n\n\t\tconst accessibilityLabel = sprintf(\n\t\t\t/* translators: accessibility text. Inform about current value. %1$s: Control label %2$s: setting label (example: width), %3$s: Current value. %4$s: value measurement unit (example: pixels) */\n\t\t\t__( '%1$s. %2$s is %3$s %4$s.' ),\n\t\t\tlabel,\n\t\t\tsettingLabel,\n\t\t\tvalue,\n\t\t\tunitLabel\n\t\t);\n\n\t\tconst containerStyle = [\n\t\t\tstyles.rowContainer,\n\t\t\tisIOS ? styles.containerIOS : styles.containerAndroid,\n\t\t];\n\n\t\treturn (\n\t\t\t<View\n\t\t\t\taccessible={ true }\n\t\t\t\taccessibilityRole=\"adjustable\"\n\t\t\t\taccessibilityLabel={ accessibilityLabel }\n\t\t\t\taccessibilityHint={ getAccessibilityHint() }\n\t\t\t\taccessibilityActions={ [\n\t\t\t\t\t{ name: 'increment' },\n\t\t\t\t\t{ name: 'decrement' },\n\t\t\t\t\t{ name: 'activate' },\n\t\t\t\t] }\n\t\t\t\tonAccessibilityAction={ ( event ) => {\n\t\t\t\t\tswitch ( event.nativeEvent.actionName ) {\n\t\t\t\t\t\tcase 'increment':\n\t\t\t\t\t\t\tthis.onIncrementValue();\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'decrement':\n\t\t\t\t\t\t\tthis.onDecrementValue();\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'activate':\n\t\t\t\t\t\t\tif ( openUnitPicker ) {\n\t\t\t\t\t\t\t\topenUnitPicker();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t} }\n\t\t\t>\n\t\t\t\t<View importantForAccessibility=\"no-hide-descendants\">\n\t\t\t\t\t<Cell\n\t\t\t\t\t\taccessible={ false }\n\t\t\t\t\t\tcellContainerStyle={ [\n\t\t\t\t\t\t\tstyles.cellContainerStyle,\n\t\t\t\t\t\t\tpreview && styles.columnContainer,\n\t\t\t\t\t\t\tcellContainerStyle,\n\t\t\t\t\t\t] }\n\t\t\t\t\t\tcellRowContainerStyle={\n\t\t\t\t\t\t\tpreview ? containerStyle : styles.cellRowStyles\n\t\t\t\t\t\t}\n\t\t\t\t\t\teditable={ false }\n\t\t\t\t\t\ticon={ icon }\n\t\t\t\t\t\tlabel={ label }\n\t\t\t\t\t\tlabelStyle={ labelStyle }\n\t\t\t\t\t\tleftAlign={ true }\n\t\t\t\t\t\tseparatorType={ separatorType }\n\t\t\t\t\t>\n\t\t\t\t\t\t<View style={ preview && containerStyle }>\n\t\t\t\t\t\t\t{ preview }\n\t\t\t\t\t\t\t<Stepper\n\t\t\t\t\t\t\t\tisMaxValue={ isMaxValue }\n\t\t\t\t\t\t\t\tisMinValue={ isMinValue }\n\t\t\t\t\t\t\t\tonPressInDecrement={\n\t\t\t\t\t\t\t\t\tthis.onDecrementValuePressIn\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tonPressInIncrement={\n\t\t\t\t\t\t\t\t\tthis.onIncrementValuePressIn\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tonPressOut={ this.onPressOut }\n\t\t\t\t\t\t\t\tvalue={ value }\n\t\t\t\t\t\t\t\tshouldDisplayTextInput={\n\t\t\t\t\t\t\t\t\tshouldDisplayTextInput\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{ shouldDisplayTextInput && (\n\t\t\t\t\t\t\t\t\t<RangeTextInput\n\t\t\t\t\t\t\t\t\t\tlabel={ label }\n\t\t\t\t\t\t\t\t\t\tonChange={ onChange }\n\t\t\t\t\t\t\t\t\t\tdefaultValue={ `${ inputValue }` }\n\t\t\t\t\t\t\t\t\t\tvalue={ value }\n\t\t\t\t\t\t\t\t\t\tmin={ min }\n\t\t\t\t\t\t\t\t\t\tstep={ 1 }\n\t\t\t\t\t\t\t\t\t\tdecimalNum={ decimalNum }\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{ children }\n\t\t\t\t\t\t\t\t\t</RangeTextInput>\n\t\t\t\t\t\t\t\t) }\n\t\t\t\t\t\t\t</Stepper>\n\t\t\t\t\t\t</View>\n\t\t\t\t\t</Cell>\n\t\t\t\t</View>\n\t\t\t</View>\n\t\t);\n\t}\n}\n\nBottomSheetStepperCell.defaultProps = {\n\tstep: DEFAULT_STEP,\n};\n\nexport default withPreferredColorScheme( BottomSheetStepperCell );\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["@wordpress/components/src/mobile/color-settings/index.native.js"],"names":["useRoute","memo","useEffect","useContext","BottomSheetContext","BottomSheet","PickerScreen","GradientPickerScreen","PaletteScreen","colorsUtils","ColorSettingsMemo","defaultSettings","onHandleClosingBottomSheet","shouldEnableBottomSheetMaxHeight","onColorChange","colorValue","gradientValue","onGradientChange","onColorCleared","label","hideNavigation","screens","palette","picker","gradientPicker","ColorSettings","props","route","params"],"mappings":";;;AAAA;AACA;AACA;AACA,SAASA,QAAT,QAAyB,0BAAzB;AAEA;AACA;AACA;;AACA,SAASC,IAAT,EAAeC,SAAf,EAA0BC,UAA1B,QAA4C,oBAA5C;AACA,SAASC,kBAAT,EAA6BC,WAA7B,QAAgD,uBAAhD;AAEA;AACA;AACA;;AACA,OAAOC,YAAP,MAAyB,iBAAzB;AACA,OAAOC,oBAAP,MAAiC,0BAAjC;AACA,OAAOC,aAAP,MAA0B,kBAA1B;AAEA,SAASC,WAAT,QAA4B,SAA5B;AAEA,MAAMC,iBAAiB,GAAGT,IAAI,CAC7B,QAWO;AAAA,MAXL;AACDU,IAAAA,eADC;AAEDC,IAAAA,0BAFC;AAGDC,IAAAA,gCAHC;AAIDC,IAAAA,aAJC;AAKDC,IAAAA,UALC;AAMDC,IAAAA,aANC;AAODC,IAAAA,gBAPC;AAQDC,IAAAA,cARC;AASDC,IAAAA,KATC;AAUDC,IAAAA;AAVC,GAWK;AACNlB,EAAAA,SAAS,CAAE,MAAM;AAChBW,IAAAA,gCAAgC,CAAE,IAAF,CAAhC;AACAD,IAAAA,0BAA0B,CAAE,IAAF,CAA1B;AACA,GAHQ,EAGN,EAHM,CAAT;AAIA,SACC,cAAC,WAAD,CAAa,mBAAb,QACC,cAAC,WAAD,CAAa,gBAAb;AACC,IAAA,IAAI,EAAGH,WAAW,CAACY,OAAZ,CAAoBC,OAD5B;AAEC,IAAA,aAAa,EAAG;AACfX,MAAAA,eADe;AAEfG,MAAAA,aAFe;AAGfC,MAAAA,UAHe;AAIfC,MAAAA,aAJe;AAKfC,MAAAA,gBALe;AAMfC,MAAAA,cANe;AAOfC,MAAAA,KAPe;AAQfC,MAAAA;AARe;AAFjB,KAaC,cAAC,aAAD,OAbD,CADD,EAgBC,cAAC,WAAD,CAAa,gBAAb;AACC,IAAA,IAAI,EAAGX,WAAW,CAACY,OAAZ,CAAoBE;AAD5B,KAGC,cAAC,YAAD,OAHD,CAhBD,EAqBC,cAAC,WAAD,CAAa,gBAAb;AACC,IAAA,IAAI,EAAGd,WAAW,CAACY,OAAZ,CAAoBG;AAD5B,KAGC,cAAC,oBAAD,OAHD,CArBD,CADD;AA6BA,CA9C4B,CAA9B;;AAgDA,SAASC,aAAT,CAAwBC,KAAxB,EAAgC;AAC/B,QAAMC,KAAK,GAAG3B,QAAQ,EAAtB;AACA,QAAM;AACLY,IAAAA,0BADK;AAELC,IAAAA;AAFK,MAGFV,UAAU,CAAEC,kBAAF,CAHd;AAKA,SACC,cAAC,iBAAD;AACC,IAAA,0BAA0B,EAAGQ,0BAD9B;AAEC,IAAA,gCAAgC,EAC/BC;AAHF,KAKMa,KALN,EAMMC,KAAK,CAACC,MANZ,EADD;AAUA;;AAED,eAAeH,aAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { useRoute } from '@react-navigation/native';\n\n/**\n * WordPress dependencies\n */\nimport { memo, useEffect, useContext } from '@wordpress/element';\nimport { BottomSheetContext, BottomSheet } from '@wordpress/components';\n\n/**\n * Internal dependencies\n */\nimport PickerScreen from './picker-screen';\nimport GradientPickerScreen from './gradient-picker-screen';\nimport PaletteScreen from './palette.screen';\n\nimport { colorsUtils } from './utils';\n\nconst ColorSettingsMemo = memo(\n\t( {\n\t\tdefaultSettings,\n\t\tonHandleClosingBottomSheet,\n\t\tshouldEnableBottomSheetMaxHeight,\n\t\tonColorChange,\n\t\tcolorValue,\n\t\tgradientValue,\n\t\tonGradientChange,\n\t\tonColorCleared,\n\t\tlabel,\n\t\thideNavigation,\n\t} ) => {\n\t\tuseEffect( () => {\n\t\t\tshouldEnableBottomSheetMaxHeight( true );\n\t\t\tonHandleClosingBottomSheet( null );\n\t\t}, [] );\n\t\treturn (\n\t\t\t<BottomSheet.NavigationContainer>\n\t\t\t\t<BottomSheet.NavigationScreen\n\t\t\t\t\tname={ colorsUtils.screens.palette }\n\t\t\t\t\tinitialParams={ {\n\t\t\t\t\t\tdefaultSettings,\n\t\t\t\t\t\tonColorChange,\n\t\t\t\t\t\tcolorValue,\n\t\t\t\t\t\tgradientValue,\n\t\t\t\t\t\tonGradientChange,\n\t\t\t\t\t\tonColorCleared,\n\t\t\t\t\t\tlabel,\n\t\t\t\t\t\thideNavigation,\n\t\t\t\t\t} }\n\t\t\t\t>\n\t\t\t\t\t<PaletteScreen />\n\t\t\t\t</BottomSheet.NavigationScreen>\n\t\t\t\t<BottomSheet.NavigationScreen\n\t\t\t\t\tname={ colorsUtils.screens.picker }\n\t\t\t\t>\n\t\t\t\t\t<PickerScreen />\n\t\t\t\t</BottomSheet.NavigationScreen>\n\t\t\t\t<BottomSheet.NavigationScreen\n\t\t\t\t\tname={ colorsUtils.screens.gradientPicker }\n\t\t\t\t>\n\t\t\t\t\t<GradientPickerScreen />\n\t\t\t\t</BottomSheet.NavigationScreen>\n\t\t\t</BottomSheet.NavigationContainer>\n\t\t);\n\t}\n);\nfunction ColorSettings( props ) {\n\tconst route = useRoute();\n\tconst {\n\t\tonHandleClosingBottomSheet,\n\t\tshouldEnableBottomSheetMaxHeight,\n\t} = useContext( BottomSheetContext );\n\n\treturn (\n\t\t<ColorSettingsMemo\n\t\t\tonHandleClosingBottomSheet={ onHandleClosingBottomSheet }\n\t\t\tshouldEnableBottomSheetMaxHeight={\n\t\t\t\tshouldEnableBottomSheetMaxHeight\n\t\t\t}\n\t\t\t{ ...props }\n\t\t\t{ ...route.params }\n\t\t/>\n\t);\n}\n\nexport default ColorSettings;\n"]}
1
+ {"version":3,"sources":["@wordpress/components/src/mobile/color-settings/index.native.js"],"names":["useRoute","memo","useEffect","useContext","BottomSheetContext","BottomSheet","PickerScreen","GradientPickerScreen","PaletteScreen","colorsUtils","ColorSettingsMemo","defaultSettings","onHandleClosingBottomSheet","shouldEnableBottomSheetMaxHeight","onColorChange","colorValue","gradientValue","onGradientChange","onColorCleared","label","hideNavigation","screens","palette","picker","gradientPicker","ColorSettings","props","route","params"],"mappings":";;;AAAA;AACA;AACA;AACA,SAASA,QAAT,QAAyB,0BAAzB;AAEA;AACA;AACA;;AACA,SAASC,IAAT,EAAeC,SAAf,EAA0BC,UAA1B,QAA4C,oBAA5C;AACA,SAASC,kBAAT,EAA6BC,WAA7B,QAAgD,uBAAhD;AAEA;AACA;AACA;;AACA,OAAOC,YAAP,MAAyB,iBAAzB;AACA,OAAOC,oBAAP,MAAiC,0BAAjC;AACA,OAAOC,aAAP,MAA0B,kBAA1B;AAEA,SAASC,WAAT,QAA4B,SAA5B;AAEA,MAAMC,iBAAiB,GAAGT,IAAI,CAC7B,QAWO;AAAA,MAXL;AACDU,IAAAA,eADC;AAEDC,IAAAA,0BAFC;AAGDC,IAAAA,gCAHC;AAIDC,IAAAA,aAJC;AAKDC,IAAAA,UALC;AAMDC,IAAAA,aANC;AAODC,IAAAA,gBAPC;AAQDC,IAAAA,cARC;AASDC,IAAAA,KATC;AAUDC,IAAAA;AAVC,GAWK;AACNlB,EAAAA,SAAS,CAAE,MAAM;AAChBW,IAAAA,gCAAgC,CAAE,IAAF,CAAhC;AACAD,IAAAA,0BAA0B,CAAE,IAAF,CAA1B;AACA,GAHQ,EAGN,EAHM,CAAT;AAIA,SACC,cAAC,WAAD,CAAa,mBAAb,QACC,cAAC,WAAD,CAAa,gBAAb;AACC,IAAA,IAAI,EAAGH,WAAW,CAACY,OAAZ,CAAoBC,OAD5B;AAEC,IAAA,aAAa,EAAG;AACfX,MAAAA,eADe;AAEfG,MAAAA,aAFe;AAGfC,MAAAA,UAHe;AAIfC,MAAAA,aAJe;AAKfC,MAAAA,gBALe;AAMfC,MAAAA,cANe;AAOfC,MAAAA,KAPe;AAQfC,MAAAA;AARe;AAFjB,KAaC,cAAC,aAAD,OAbD,CADD,EAgBC,cAAC,WAAD,CAAa,gBAAb;AACC,IAAA,IAAI,EAAGX,WAAW,CAACY,OAAZ,CAAoBE;AAD5B,KAGC,cAAC,YAAD,OAHD,CAhBD,EAqBC,cAAC,WAAD,CAAa,gBAAb;AACC,IAAA,IAAI,EAAGd,WAAW,CAACY,OAAZ,CAAoBG;AAD5B,KAGC,cAAC,oBAAD,OAHD,CArBD,CADD;AA6BA,CA9C4B,CAA9B;;AAgDA,SAASC,aAAT,CAAwBC,KAAxB,EAAgC;AAC/B,QAAMC,KAAK,GAAG3B,QAAQ,EAAtB;AACA,QAAM;AAAEY,IAAAA,0BAAF;AAA8BC,IAAAA;AAA9B,MACLV,UAAU,CAAEC,kBAAF,CADX;AAGA,SACC,cAAC,iBAAD;AACC,IAAA,0BAA0B,EAAGQ,0BAD9B;AAEC,IAAA,gCAAgC,EAC/BC;AAHF,KAKMa,KALN,EAMMC,KAAK,CAACC,MANZ,EADD;AAUA;;AAED,eAAeH,aAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { useRoute } from '@react-navigation/native';\n\n/**\n * WordPress dependencies\n */\nimport { memo, useEffect, useContext } from '@wordpress/element';\nimport { BottomSheetContext, BottomSheet } from '@wordpress/components';\n\n/**\n * Internal dependencies\n */\nimport PickerScreen from './picker-screen';\nimport GradientPickerScreen from './gradient-picker-screen';\nimport PaletteScreen from './palette.screen';\n\nimport { colorsUtils } from './utils';\n\nconst ColorSettingsMemo = memo(\n\t( {\n\t\tdefaultSettings,\n\t\tonHandleClosingBottomSheet,\n\t\tshouldEnableBottomSheetMaxHeight,\n\t\tonColorChange,\n\t\tcolorValue,\n\t\tgradientValue,\n\t\tonGradientChange,\n\t\tonColorCleared,\n\t\tlabel,\n\t\thideNavigation,\n\t} ) => {\n\t\tuseEffect( () => {\n\t\t\tshouldEnableBottomSheetMaxHeight( true );\n\t\t\tonHandleClosingBottomSheet( null );\n\t\t}, [] );\n\t\treturn (\n\t\t\t<BottomSheet.NavigationContainer>\n\t\t\t\t<BottomSheet.NavigationScreen\n\t\t\t\t\tname={ colorsUtils.screens.palette }\n\t\t\t\t\tinitialParams={ {\n\t\t\t\t\t\tdefaultSettings,\n\t\t\t\t\t\tonColorChange,\n\t\t\t\t\t\tcolorValue,\n\t\t\t\t\t\tgradientValue,\n\t\t\t\t\t\tonGradientChange,\n\t\t\t\t\t\tonColorCleared,\n\t\t\t\t\t\tlabel,\n\t\t\t\t\t\thideNavigation,\n\t\t\t\t\t} }\n\t\t\t\t>\n\t\t\t\t\t<PaletteScreen />\n\t\t\t\t</BottomSheet.NavigationScreen>\n\t\t\t\t<BottomSheet.NavigationScreen\n\t\t\t\t\tname={ colorsUtils.screens.picker }\n\t\t\t\t>\n\t\t\t\t\t<PickerScreen />\n\t\t\t\t</BottomSheet.NavigationScreen>\n\t\t\t\t<BottomSheet.NavigationScreen\n\t\t\t\t\tname={ colorsUtils.screens.gradientPicker }\n\t\t\t\t>\n\t\t\t\t\t<GradientPickerScreen />\n\t\t\t\t</BottomSheet.NavigationScreen>\n\t\t\t</BottomSheet.NavigationContainer>\n\t\t);\n\t}\n);\nfunction ColorSettings( props ) {\n\tconst route = useRoute();\n\tconst { onHandleClosingBottomSheet, shouldEnableBottomSheetMaxHeight } =\n\t\tuseContext( BottomSheetContext );\n\n\treturn (\n\t\t<ColorSettingsMemo\n\t\t\tonHandleClosingBottomSheet={ onHandleClosingBottomSheet }\n\t\t\tshouldEnableBottomSheetMaxHeight={\n\t\t\t\tshouldEnableBottomSheetMaxHeight\n\t\t\t}\n\t\t\t{ ...props }\n\t\t\t{ ...route.params }\n\t\t/>\n\t);\n}\n\nexport default ColorSettings;\n"]}
@@ -11,7 +11,7 @@ import { useRoute, useNavigation } from '@react-navigation/native';
11
11
  */
12
12
 
13
13
  import { __ } from '@wordpress/i18n';
14
- import { memo, useContext, useState } from '@wordpress/element';
14
+ import { memo, useContext, useState, useCallback } from '@wordpress/element';
15
15
  import { BottomSheetContext, FocalPointPicker } from '@wordpress/components';
16
16
  /**
17
17
  * Internal dependencies
@@ -52,7 +52,7 @@ const FocalPointSettingsPanelMemo = memo(_ref => {
52
52
  onPress: () => onButtonPress('apply')
53
53
  })), createElement(FocalPointPicker, {
54
54
  focalPoint: draftFocalPoint,
55
- onChange: setPosition,
55
+ onChange: useCallback(setPosition, []),
56
56
  shouldEnableBottomSheetScroll: shouldEnableBottomSheetScroll,
57
57
  url: url
58
58
  }));
@@ -1 +1 @@
1
- {"version":3,"sources":["@wordpress/components/src/mobile/focal-point-settings-panel/index.native.js"],"names":["SafeAreaView","useRoute","useNavigation","__","memo","useContext","useState","BottomSheetContext","FocalPointPicker","NavBar","styles","FocalPointSettingsPanelMemo","focalPoint","onFocalPointChange","shouldEnableBottomSheetScroll","url","navigation","onButtonPress","action","goBack","draftFocalPoint","setDraftFocalPoint","setPosition","coordinates","prevState","safearea","FocalPointSettingsPanel","props","route","params"],"mappings":";;;AAAA;AACA;AACA;AACA,SAASA,YAAT,QAA6B,cAA7B;AACA,SAASC,QAAT,EAAmBC,aAAnB,QAAwC,0BAAxC;AAEA;AACA;AACA;;AACA,SAASC,EAAT,QAAmB,iBAAnB;AACA,SAASC,IAAT,EAAeC,UAAf,EAA2BC,QAA3B,QAA2C,oBAA3C;AACA,SAASC,kBAAT,EAA6BC,gBAA7B,QAAqD,uBAArD;AAEA;AACA;AACA;;AACA,OAAOC,MAAP,MAAmB,yBAAnB;AACA,OAAOC,MAAP,MAAmB,eAAnB;AAEA,MAAMC,2BAA2B,GAAGP,IAAI,CACvC,QAKO;AAAA,MALL;AACDQ,IAAAA,UADC;AAEDC,IAAAA,kBAFC;AAGDC,IAAAA,6BAHC;AAIDC,IAAAA;AAJC,GAKK;AAC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Af","sourcesContent":["/**\n * External dependencies\n */\nimport { SafeAreaView } from 'react-native';\nimport { useRoute, useNavigation } from '@react-navigation/native';\n\n/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { memo, useContext, useState } from '@wordpress/element';\nimport { BottomSheetContext, FocalPointPicker } from '@wordpress/components';\n\n/**\n * Internal dependencies\n */\nimport NavBar from '../bottom-sheet/nav-bar';\nimport styles from './styles.scss';\n\nconst FocalPointSettingsPanelMemo = memo(\n\t( {\n\t\tfocalPoint,\n\t\tonFocalPointChange,\n\t\tshouldEnableBottomSheetScroll,\n\t\turl,\n\t} ) => {\n\t\tconst navigation = useNavigation();\n\n\t\tfunction onButtonPress( action ) {\n\t\t\tnavigation.goBack();\n\t\t\tif ( action === 'apply' ) {\n\t\t\t\tonFocalPointChange( draftFocalPoint );\n\t\t\t}\n\t\t}\n\n\t\tconst [ draftFocalPoint, setDraftFocalPoint ] = useState( focalPoint );\n\t\tfunction setPosition( coordinates ) {\n\t\t\tsetDraftFocalPoint( ( prevState ) => ( {\n\t\t\t\t...prevState,\n\t\t\t\t...coordinates,\n\t\t\t} ) );\n\t\t}\n\n\t\treturn (\n\t\t\t<SafeAreaView style={ styles.safearea }>\n\t\t\t\t<NavBar>\n\t\t\t\t\t<NavBar.DismissButton\n\t\t\t\t\t\tonPress={ () => onButtonPress( 'cancel' ) }\n\t\t\t\t\t/>\n\t\t\t\t\t<NavBar.Heading>\n\t\t\t\t\t\t{ __( 'Edit focal point' ) }\n\t\t\t\t\t</NavBar.Heading>\n\t\t\t\t\t<NavBar.ApplyButton\n\t\t\t\t\t\tonPress={ () => onButtonPress( 'apply' ) }\n\t\t\t\t\t/>\n\t\t\t\t</NavBar>\n\t\t\t\t<FocalPointPicker\n\t\t\t\t\tfocalPoint={ draftFocalPoint }\n\t\t\t\t\tonChange={ setPosition }\n\t\t\t\t\tshouldEnableBottomSheetScroll={\n\t\t\t\t\t\tshouldEnableBottomSheetScroll\n\t\t\t\t\t}\n\t\t\t\t\turl={ url }\n\t\t\t\t/>\n\t\t\t</SafeAreaView>\n\t\t);\n\t}\n);\n\nfunction FocalPointSettingsPanel( props ) {\n\tconst route = useRoute();\n\tconst { shouldEnableBottomSheetScroll } = useContext( BottomSheetContext );\n\n\treturn (\n\t\t<FocalPointSettingsPanelMemo\n\t\t\tshouldEnableBottomSheetScroll={ shouldEnableBottomSheetScroll }\n\t\t\t{ ...props }\n\t\t\t{ ...route.params }\n\t\t/>\n\t);\n}\n\nexport default FocalPointSettingsPanel;\n"]}
1
+ {"version":3,"sources":["@wordpress/components/src/mobile/focal-point-settings-panel/index.native.js"],"names":["SafeAreaView","useRoute","useNavigation","__","memo","useContext","useState","useCallback","BottomSheetContext","FocalPointPicker","NavBar","styles","FocalPointSettingsPanelMemo","focalPoint","onFocalPointChange","shouldEnableBottomSheetScroll","url","navigation","onButtonPress","action","goBack","draftFocalPoint","setDraftFocalPoint","setPosition","coordinates","prevState","safearea","FocalPointSettingsPanel","props","route","params"],"mappings":";;;AAAA;AACA;AACA;AACA,SAASA,YAAT,QAA6B,cAA7B;AACA,SAASC,QAAT,EAAmBC,aAAnB,QAAwC,0BAAxC;AAEA;AACA;AACA;;AACA,SAASC,EAAT,QAAmB,iBAAnB;AACA,SAASC,IAAT,EAAeC,UAAf,EAA2BC,QAA3B,EAAqCC,WAArC,QAAwD,oBAAxD;AACA,SAASC,kBAAT,EAA6BC,gBAA7B,QAAqD,uBAArD;AAEA;AACA;AACA;;AACA,OAAOC,MAAP,MAAmB,yBAAnB;AACA,OAAOC,MAAP,MAAmB,eAAnB;AAEA,MAAMC,2BAA2B,GAAGR,IAAI,CACvC,QAKO;AAAA,MALL;AACDS,IAAAA,UADC;AAEDC,IAAAA,kBAFC;AAGDC,IAAAA,6BAHC;AAIDC,IAAAA;AAJC,GAKK;AACN,QAAMC,UAAU,GAAGf,aAAa,EAAhC;;AAEA,WAASgB,aAAT,CAAwBC,MAAxB,EAAiC;AAChCF,IAAAA,UAAU,C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avigation } from '@react-navigation/native';\n\n/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { memo, useContext, useState, useCallback } from '@wordpress/element';\nimport { BottomSheetContext, FocalPointPicker } from '@wordpress/components';\n\n/**\n * Internal dependencies\n */\nimport NavBar from '../bottom-sheet/nav-bar';\nimport styles from './styles.scss';\n\nconst FocalPointSettingsPanelMemo = memo(\n\t( {\n\t\tfocalPoint,\n\t\tonFocalPointChange,\n\t\tshouldEnableBottomSheetScroll,\n\t\turl,\n\t} ) => {\n\t\tconst navigation = useNavigation();\n\n\t\tfunction onButtonPress( action ) {\n\t\t\tnavigation.goBack();\n\t\t\tif ( action === 'apply' ) {\n\t\t\t\tonFocalPointChange( draftFocalPoint );\n\t\t\t}\n\t\t}\n\n\t\tconst [ draftFocalPoint, setDraftFocalPoint ] = useState( focalPoint );\n\t\tfunction setPosition( coordinates ) {\n\t\t\tsetDraftFocalPoint( ( prevState ) => ( {\n\t\t\t\t...prevState,\n\t\t\t\t...coordinates,\n\t\t\t} ) );\n\t\t}\n\n\t\treturn (\n\t\t\t<SafeAreaView style={ styles.safearea }>\n\t\t\t\t<NavBar>\n\t\t\t\t\t<NavBar.DismissButton\n\t\t\t\t\t\tonPress={ () => onButtonPress( 'cancel' ) }\n\t\t\t\t\t/>\n\t\t\t\t\t<NavBar.Heading>\n\t\t\t\t\t\t{ __( 'Edit focal point' ) }\n\t\t\t\t\t</NavBar.Heading>\n\t\t\t\t\t<NavBar.ApplyButton\n\t\t\t\t\t\tonPress={ () => onButtonPress( 'apply' ) }\n\t\t\t\t\t/>\n\t\t\t\t</NavBar>\n\t\t\t\t<FocalPointPicker\n\t\t\t\t\tfocalPoint={ draftFocalPoint }\n\t\t\t\t\tonChange={ useCallback( setPosition, [] ) }\n\t\t\t\t\tshouldEnableBottomSheetScroll={\n\t\t\t\t\t\tshouldEnableBottomSheetScroll\n\t\t\t\t\t}\n\t\t\t\t\turl={ url }\n\t\t\t\t/>\n\t\t\t</SafeAreaView>\n\t\t);\n\t}\n);\n\nfunction FocalPointSettingsPanel( props ) {\n\tconst route = useRoute();\n\tconst { shouldEnableBottomSheetScroll } = useContext( BottomSheetContext );\n\n\treturn (\n\t\t<FocalPointSettingsPanelMemo\n\t\t\tshouldEnableBottomSheetScroll={ shouldEnableBottomSheetScroll }\n\t\t\t{ ...props }\n\t\t\t{ ...route.params }\n\t\t/>\n\t);\n}\n\nexport default FocalPointSettingsPanel;\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["@wordpress/components/src/mobile/global-styles-context/index.native.js"],"names":["pick","createContext","useContext","BLOCK_STYLE_ATTRIBUTES","getBlockPaddings","getBlockColors","getBlockTypography","GlobalStylesContext","style","getMergedGlobalStyles","baseGlobalStyles","globalStyle","wrapperPropsStyle","blockAttributes","defaultColors","blockName","fontSizes","baseGlobalColors","baseColors","blockStyleAttributes","wrapperPropsStyleFiltered","mergedStyle","blockColors","blockPaddings","blockTypography","useGlobalStyles","globalStyles","withGlobalStyles","WrappedComponent","props"],"mappings":";;;AAAA;AACA;AACA;AACA,SAASA,IAAT,QAAqB,QAArB;AAEA;AACA;AACA;;AACA,SAASC,aAAT,EAAwBC,UAAxB,QAA0C,oBAA1C;AAEA;AACA;AACA;;AACA,SACCC,sBADD,EAECC,gBAFD,EAGCC,cAHD,EAICC,kBAJD,QAKO,SALP;AAOA,MAAMC,mBAAmB,GAAGN,aAAa,CAAE;AAAEO,EAAAA,KAAK,EAAE;AAAT,CAAF,CAAzC;AAEAD,mBAAmB,CAACJ,sBAApB,GAA6CA,sBAA7C;AAEA,OAAO,MAAMM,qBAAqB,GAAG,CACpCC,gBADoC,EAEpCC,WAFoC,EAGpCC,iBAHoC,EAIpCC,eAJoC,EAKpCC,aALoC,EAMpCC,SANoC,EAOpCC,SAPoC,KAQhC;AACJ,QAAMC,gBAAgB,GAAG;AACxBC,IAAAA,UAAU,EAAER,gBAAgB,IAAI;AADR,GAAzB;AAGA,QAAMS,oBAAoB,GAAGnB,IAAI,CAChCa,eADgC,EAEhCV,sBAFgC,CAAjC,CAJI,CAQJ;AACA;;AACA,QAAMiB,yBAAyB,GAAGpB,IAAI,CACrCY,iBADqC,EAErCT,sBAFqC,CAAtC;AAKA,QAAMkB,WAAW,GAAG,EACnB,GAAGJ,gBADgB;AAEnB,OAAGN,WAFgB;AAGnB,OAAGS;AAHgB,GAApB;AAKA,QAAME,WAAW,GAAGjB,cAAc,CACjCc,oBADiC,EAEjCL,aAFiC,EAGjCC,SAHiC,EAIjCL,gBAJiC,CAAlC;AAMA,QAAMa,aAAa,GAAGnB,gBAAgB,CACrCiB,WADqC,EAErCT,iBAFqC,EAGrCO,oBAHqC,EAIrCG,WAJqC,CAAtC;AAMA,QAAME,eAAe,GAAGlB,kBAAkB,CACzCa,oBADyC,EAEzCH,SAFyC,EAGzCD,SAHyC,EAIzCL,gBAJyC,CAA1C;AAOA,SAAO,EACN,GAAGW,WADG;AAEN,OAAGE,aAFG;AAGN,OAAGD,WAHG;AAIN,OAAGE;AAJG,GAAP;AAMA,CArDM;AAuDP,OAAO,MAAMC,eAAe,GAAG,MAAM;AACpC,QAAMC,YAAY,GAAGxB,UAAU,CAAEK,mBAAF,CAA/B;AAEA,SAAOmB,YAAP;AACA,CAJM;AAMP,OAAO,MAAMC,gBAAgB,GAAKC,gBAAF,IAA0BC,KAAF,IACvD,cAAC,mBAAD,CAAqB,QAArB,QACKH,YAAF,IACD,cAAC,gBAAD,eAAuBG,KAAvB;AAA+B,EAAA,YAAY,EAAGH;AAA9C,GAFF,CADM;AAQP,eAAenB,mBAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { pick } from 'lodash';\n\n/**\n * WordPress dependencies\n */\nimport { createContext, useContext } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport {\n\tBLOCK_STYLE_ATTRIBUTES,\n\tgetBlockPaddings,\n\tgetBlockColors,\n\tgetBlockTypography,\n} from './utils';\n\nconst GlobalStylesContext = createContext( { style: {} } );\n\nGlobalStylesContext.BLOCK_STYLE_ATTRIBUTES = BLOCK_STYLE_ATTRIBUTES;\n\nexport const getMergedGlobalStyles = (\n\tbaseGlobalStyles,\n\tglobalStyle,\n\twrapperPropsStyle,\n\tblockAttributes,\n\tdefaultColors,\n\tblockName,\n\tfontSizes\n) => {\n\tconst baseGlobalColors = {\n\t\tbaseColors: baseGlobalStyles || {},\n\t};\n\tconst blockStyleAttributes = pick(\n\t\tblockAttributes,\n\t\tBLOCK_STYLE_ATTRIBUTES\n\t);\n\t// This prevents certain wrapper styles from being applied to blocks that\n\t// don't support them yet.\n\tconst wrapperPropsStyleFiltered = pick(\n\t\twrapperPropsStyle,\n\t\tBLOCK_STYLE_ATTRIBUTES\n\t);\n\n\tconst mergedStyle = {\n\t\t...baseGlobalColors,\n\t\t...globalStyle,\n\t\t...wrapperPropsStyleFiltered,\n\t};\n\tconst blockColors = getBlockColors(\n\t\tblockStyleAttributes,\n\t\tdefaultColors,\n\t\tblockName,\n\t\tbaseGlobalStyles\n\t);\n\tconst blockPaddings = getBlockPaddings(\n\t\tmergedStyle,\n\t\twrapperPropsStyle,\n\t\tblockStyleAttributes,\n\t\tblockColors\n\t);\n\tconst blockTypography = getBlockTypography(\n\t\tblockStyleAttributes,\n\t\tfontSizes,\n\t\tblockName,\n\t\tbaseGlobalStyles\n\t);\n\n\treturn {\n\t\t...mergedStyle,\n\t\t...blockPaddings,\n\t\t...blockColors,\n\t\t...blockTypography,\n\t};\n};\n\nexport const useGlobalStyles = () => {\n\tconst globalStyles = useContext( GlobalStylesContext );\n\n\treturn globalStyles;\n};\n\nexport const withGlobalStyles = ( WrappedComponent ) => ( props ) => (\n\t<GlobalStylesContext.Consumer>\n\t\t{ ( globalStyles ) => (\n\t\t\t<WrappedComponent { ...props } globalStyles={ globalStyles } />\n\t\t) }\n\t</GlobalStylesContext.Consumer>\n);\n\nexport default GlobalStylesContext;\n"]}
1
+ {"version":3,"sources":["@wordpress/components/src/mobile/global-styles-context/index.native.js"],"names":["pick","createContext","useContext","BLOCK_STYLE_ATTRIBUTES","getBlockPaddings","getBlockColors","getBlockTypography","GlobalStylesContext","style","getMergedGlobalStyles","baseGlobalStyles","globalStyle","wrapperPropsStyle","blockAttributes","defaultColors","blockName","fontSizes","baseGlobalColors","baseColors","blockStyleAttributes","wrapperPropsStyleFiltered","mergedStyle","blockColors","blockPaddings","blockTypography","useGlobalStyles","globalStyles","withGlobalStyles","WrappedComponent","props"],"mappings":";;;AAAA;AACA;AACA;AACA,SAASA,IAAT,QAAqB,QAArB;AAEA;AACA;AACA;;AACA,SAASC,aAAT,EAAwBC,UAAxB,QAA0C,oBAA1C;AAEA;AACA;AACA;;AACA,SACCC,sBADD,EAECC,gBAFD,EAGCC,cAHD,EAICC,kBAJD,QAKO,SALP;AAOA,MAAMC,mBAAmB,GAAGN,aAAa,CAAE;AAAEO,EAAAA,KAAK,EAAE;AAAT,CAAF,CAAzC;AAEAD,mBAAmB,CAACJ,sBAApB,GAA6CA,sBAA7C;AAEA,OAAO,MAAMM,qBAAqB,GAAG,CACpCC,gBADoC,EAEpCC,WAFoC,EAGpCC,iBAHoC,EAIpCC,eAJoC,EAKpCC,aALoC,EAMpCC,SANoC,EAOpCC,SAPoC,KAQhC;AACJ,QAAMC,gBAAgB,GAAG;AACxBC,IAAAA,UAAU,EAAER,gBAAgB,IAAI;AADR,GAAzB;AAGA,QAAMS,oBAAoB,GAAGnB,IAAI,CAChCa,eADgC,EAEhCV,sBAFgC,CAAjC,CAJI,CAQJ;AACA;;AACA,QAAMiB,yBAAyB,GAAGpB,IAAI,CACrCY,iBADqC,EAErCT,sBAFqC,CAAtC;AAKA,QAAMkB,WAAW,GAAG,EACnB,GAAGJ,gBADgB;AAEnB,OAAGN,WAFgB;AAGnB,OAAGS;AAHgB,GAApB;AAKA,QAAME,WAAW,GAAGjB,cAAc,CACjCc,oBADiC,EAEjCL,aAFiC,EAGjCC,SAHiC,EAIjCL,gBAJiC,CAAlC;AAMA,QAAMa,aAAa,GAAGnB,gBAAgB,CACrCiB,WADqC,EAErCT,iBAFqC,EAGrCO,oBAHqC,EAIrCG,WAJqC,CAAtC;AAMA,QAAME,eAAe,GAAGlB,kBAAkB,CACzCa,oBADyC,EAEzCH,SAFyC,EAGzCD,SAHyC,EAIzCL,gBAJyC,CAA1C;AAOA,SAAO,EACN,GAAGW,WADG;AAEN,OAAGE,aAFG;AAGN,OAAGD,WAHG;AAIN,OAAGE;AAJG,GAAP;AAMA,CArDM;AAuDP,OAAO,MAAMC,eAAe,GAAG,MAAM;AACpC,QAAMC,YAAY,GAAGxB,UAAU,CAAEK,mBAAF,CAA/B;AAEA,SAAOmB,YAAP;AACA,CAJM;AAMP,OAAO,MAAMC,gBAAgB,GAAKC,gBAAF,IAA0BC,KAAF,IAEtD,cAAC,mBAAD,CAAqB,QAArB,QACKH,YAAF,IACD,cAAC,gBAAD,eAAuBG,KAAvB;AAA+B,EAAA,YAAY,EAAGH;AAA9C,GAFF,CAFK;AASP,eAAenB,mBAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { pick } from 'lodash';\n\n/**\n * WordPress dependencies\n */\nimport { createContext, useContext } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport {\n\tBLOCK_STYLE_ATTRIBUTES,\n\tgetBlockPaddings,\n\tgetBlockColors,\n\tgetBlockTypography,\n} from './utils';\n\nconst GlobalStylesContext = createContext( { style: {} } );\n\nGlobalStylesContext.BLOCK_STYLE_ATTRIBUTES = BLOCK_STYLE_ATTRIBUTES;\n\nexport const getMergedGlobalStyles = (\n\tbaseGlobalStyles,\n\tglobalStyle,\n\twrapperPropsStyle,\n\tblockAttributes,\n\tdefaultColors,\n\tblockName,\n\tfontSizes\n) => {\n\tconst baseGlobalColors = {\n\t\tbaseColors: baseGlobalStyles || {},\n\t};\n\tconst blockStyleAttributes = pick(\n\t\tblockAttributes,\n\t\tBLOCK_STYLE_ATTRIBUTES\n\t);\n\t// This prevents certain wrapper styles from being applied to blocks that\n\t// don't support them yet.\n\tconst wrapperPropsStyleFiltered = pick(\n\t\twrapperPropsStyle,\n\t\tBLOCK_STYLE_ATTRIBUTES\n\t);\n\n\tconst mergedStyle = {\n\t\t...baseGlobalColors,\n\t\t...globalStyle,\n\t\t...wrapperPropsStyleFiltered,\n\t};\n\tconst blockColors = getBlockColors(\n\t\tblockStyleAttributes,\n\t\tdefaultColors,\n\t\tblockName,\n\t\tbaseGlobalStyles\n\t);\n\tconst blockPaddings = getBlockPaddings(\n\t\tmergedStyle,\n\t\twrapperPropsStyle,\n\t\tblockStyleAttributes,\n\t\tblockColors\n\t);\n\tconst blockTypography = getBlockTypography(\n\t\tblockStyleAttributes,\n\t\tfontSizes,\n\t\tblockName,\n\t\tbaseGlobalStyles\n\t);\n\n\treturn {\n\t\t...mergedStyle,\n\t\t...blockPaddings,\n\t\t...blockColors,\n\t\t...blockTypography,\n\t};\n};\n\nexport const useGlobalStyles = () => {\n\tconst globalStyles = useContext( GlobalStylesContext );\n\n\treturn globalStyles;\n};\n\nexport const withGlobalStyles = ( WrappedComponent ) => ( props ) =>\n\t(\n\t\t<GlobalStylesContext.Consumer>\n\t\t\t{ ( globalStyles ) => (\n\t\t\t\t<WrappedComponent { ...props } globalStyles={ globalStyles } />\n\t\t\t) }\n\t\t</GlobalStylesContext.Consumer>\n\t);\n\nexport default GlobalStylesContext;\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["@wordpress/components/src/mobile/gradient/index.native.js"],"names":["View","Platform","RNLinearGradient","gradientParser","colorsUtils","RadialGradient","Stop","SVG","Defs","Rect","useResizeObserver","useMemo","styles","getGradientAngle","gradientValue","angleBase","matchAngle","angle","exec","angleType","includes","parseFloat","getGradientColorGroup","colorNeedParenthesis","excludeSideOrCorner","modifiedGradientValue","replace","concat","parse","map","gradient","colorStops","color","index","type","value","length","fallbackLength","colorLength","join","getGradientBaseColors","colorGroup","getColorLocations","location","Number","Gradient","style","angleCenter","x","y","children","otherProps","resizeObserver","sizes","width","height","isGradient","getGradientType","gradients","locations","colors","isLinearGradient","linear","overflow","radialGradientContent","OS","group"],"mappings":";;;AAAA;AACA;AACA;AACA,SAASA,IAAT,EAAeC,QAAf,QAA+B,cAA/B;AACA,OAAOC,gBAAP,MAA6B,8BAA7B;AACA,OAAOC,cAAP,MAA2B,iBAA3B;AACA;AACA;AACA;;AACA,SAASC,WAAT,QAA4B,uBAA5B;AACA,SAASC,cAAT,EAAyBC,IAAzB,EAA+BC,GAA/B,EAAoCC,IAApC,EAA0CC,IAA1C,QAAsD,uBAAtD;AACA,SAASC,iBAAT,QAAkC,oBAAlC;AACA,SAASC,OAAT,QAAwB,oBAAxB;AAEA;AACA;AACA;;AACA,OAAOC,MAAP,MAAmB,cAAnB;AAEA,OAAO,SAASC,gBAAT,CAA2BC,aAA3B,EAA2C;AACjD,QAAMC,SAAS,GAAG,EAAlB;AACA,QAAMC,UAAU,GAAG,0BAAnB;AACA,QAAMC,KAAK,GAAGD,UAAU,CAACE,IAAX,CAAiBJ,aAAjB,IACXE,UAAU,CAACE,IAAX,CAAiBJ,aAAjB,EAAkC,CAAlC,CADW,GAEX,QAFH;AAIA,QAAMK,SAAS,GAAGF,KAAK,CAACG,QAAN,CAAgB,KAAhB,IAA0B,OAA1B,GAAoC,cAAtD;;AAEA,MAAKD,SAAS,KAAK,cAAnB,EAAoC;AACnC,YAASF,KAAT;AACC,WAAK,QAAL;AACC,eAAO,CAAP;;AACD,WAAK,cAAL;AACA,WAAK,cAAL;AACC,eAAOF,SAAP;;AACD,WAAK,UAAL;AACC,eAAO,IAAIA,SAAX;;AACD,WAAK,iBAAL;AACA,WAAK,iBAAL;AACC,eAAO,IAAIA,SAAX;;AACD,WAAK,WAAL;AACC,eAAO,IAAIA,SAAX;;AACD,WAAK,gBAAL;AACA,WAAK,gBAAL;AACC,eAAO,IAAIA,SAAX;;AACD,WAAK,SAAL;AACC,eAAO,IAAIA,SAAX;;AACD,WAAK,aAAL;AACA,WAAK,aAAL;AACC,eAAO,IAAIA,SAAX;AApBF;AAsBA,GA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AAF,CAAO,IAAIA,KAAK,CAAE,CAAF,CAAO;AAJvC,MADD;AAQA,GATC,CARH,CADD,CADD,EAsBC,cAAC,IAAD;AACC,IAAA,MAAM,EAAGX,MADV;AAEC,IAAA,KAAK,EAAGD,KAFT;AAGC,IAAA,IAAI,EAAC;AAHN,IAtBD,CAHD,CADD;AAkCA;;AAED,eAAeT,QAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { View, Platform } from 'react-native';\nimport RNLinearGradient from 'react-native-linear-gradient';\nimport gradientParser from 'gradient-parser';\n/**\n * WordPress dependencies\n */\nimport { colorsUtils } from '@wordpress/components';\nimport { RadialGradient, Stop, SVG, Defs, Rect } from '@wordpress/primitives';\nimport { useResizeObserver } from '@wordpress/compose';\nimport { useMemo } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport styles from './style.scss';\n\nexport function getGradientAngle( gradientValue ) {\n\tconst angleBase = 45;\n\tconst matchAngle = /\\(((\\d+deg)|(to\\s[^,]+))/;\n\tconst angle = matchAngle.exec( gradientValue )\n\t\t? matchAngle.exec( gradientValue )[ 1 ]\n\t\t: '180deg';\n\n\tconst angleType = angle.includes( 'deg' ) ? 'angle' : 'sideOrCorner';\n\n\tif ( angleType === 'sideOrCorner' ) {\n\t\tswitch ( angle ) {\n\t\t\tcase 'to top':\n\t\t\t\treturn 0;\n\t\t\tcase 'to top right':\n\t\t\tcase 'to right top':\n\t\t\t\treturn angleBase;\n\t\t\tcase 'to right':\n\t\t\t\treturn 2 * angleBase;\n\t\t\tcase 'to bottom right':\n\t\t\tcase 'to right bottom':\n\t\t\t\treturn 3 * angleBase;\n\t\t\tcase 'to bottom':\n\t\t\t\treturn 4 * angleBase;\n\t\t\tcase 'to bottom left':\n\t\t\tcase 'to left bottom':\n\t\t\t\treturn 5 * angleBase;\n\t\t\tcase 'to left':\n\t\t\t\treturn 6 * angleBase;\n\t\t\tcase 'to top left':\n\t\t\tcase 'to left top':\n\t\t\t\treturn 7 * angleBase;\n\t\t}\n\t} else if ( angleType === 'angle' ) {\n\t\treturn parseFloat( angle );\n\t} else return 4 * angleBase;\n}\n\nexport function getGradientColorGroup( gradientValue ) {\n\tconst colorNeedParenthesis = [ 'rgb', 'rgba' ];\n\n\tconst excludeSideOrCorner = /linear-gradient\\(to\\s+([a-z\\s]+,)/;\n\n\t// Parser has some difficulties with angle defined as a side or corner (e.g. `to left`)\n\t// so it's going to be excluded in order to matching color groups.\n\tconst modifiedGradientValue = gradientValue.replace(\n\t\texcludeSideOrCorner,\n\t\t'linear-gradient('\n\t);\n\n\treturn [].concat(\n\t\t...gradientParser.parse( modifiedGradientValue )?.map( ( gradient ) =>\n\t\t\tgradient.colorStops?.map( ( color, index ) => {\n\t\t\t\tconst { type, value, length } = color;\n\t\t\t\tconst fallbackLength = `${\n\t\t\t\t\t100 * ( index / ( gradient.colorStops.length - 1 ) )\n\t\t\t\t}%`;\n\t\t\t\tconst colorLength = length\n\t\t\t\t\t? `${ length.value }${ length.type }`\n\t\t\t\t\t: fallbackLength;\n\n\t\t\t\tif ( colorNeedParenthesis.includes( type ) ) {\n\t\t\t\t\treturn [ `${ type }(${ value.join( ',' ) })`, colorLength ];\n\t\t\t\t} else if ( type === 'literal' ) {\n\t\t\t\t\treturn [ value, colorLength ];\n\t\t\t\t}\n\t\t\t\treturn [ `#${ value }`, colorLength ];\n\t\t\t} )\n\t\t)\n\t);\n}\n\nexport function getGradientBaseColors( colorGroup ) {\n\treturn colorGroup.map( ( color ) => color[ 0 ] );\n}\n\nexport function getColorLocations( colorGroup ) {\n\treturn colorGroup.map(\n\t\t( location ) => Number( location[ 1 ].replace( '%', '' ) ) / 100\n\t);\n}\n\nfunction Gradient( {\n\tgradientValue,\n\tstyle,\n\tangleCenter = { x: 0.5, y: 0.5 },\n\tchildren,\n\t...otherProps\n} ) {\n\tconst [ resizeObserver, sizes ] = useResizeObserver();\n\tconst { width = 0, height = 0 } = sizes || {};\n\tconst { isGradient, getGradientType, gradients } = colorsUtils;\n\n\tconst colorGroup = useMemo( () => getGradientColorGroup( gradientValue ), [\n\t\tgradientValue,\n\t] );\n\n\tconst locations = useMemo( () => getColorLocations( colorGroup ), [\n\t\tcolorGroup,\n\t] );\n\n\tconst colors = useMemo( () => getGradientBaseColors( colorGroup ), [\n\t\tcolorGroup,\n\t] );\n\n\tif ( ! gradientValue || ! isGradient( gradientValue ) ) {\n\t\treturn null;\n\t}\n\n\tconst isLinearGradient =\n\t\tgetGradientType( gradientValue ) === gradients.linear;\n\n\tif ( isLinearGradient ) {\n\t\treturn (\n\t\t\t<RNLinearGradient\n\t\t\t\tcolors={ colors }\n\t\t\t\tuseAngle={ true }\n\t\t\t\tangle={ getGradientAngle( gradientValue ) }\n\t\t\t\tlocations={ locations }\n\t\t\t\tangleCenter={ angleCenter }\n\t\t\t\tstyle={ style }\n\t\t\t\t{ ...otherProps }\n\t\t\t>\n\t\t\t\t{ children }\n\t\t\t</RNLinearGradient>\n\t\t);\n\t}\n\n\treturn (\n\t\t<View style={ [ style, styles.overflow ] }>\n\t\t\t<View style={ styles.radialGradientContent }>{ children }</View>\n\t\t\t{ resizeObserver }\n\t\t\t<SVG>\n\t\t\t\t<Defs>\n\t\t\t\t\t<RadialGradient\n\t\t\t\t\t\t// eslint-disable-next-line no-restricted-syntax\n\t\t\t\t\t\tid=\"radialGradient\"\n\t\t\t\t\t\tgradientUnits=\"userSpaceOnUse\"\n\t\t\t\t\t\trx=\"70%\"\n\t\t\t\t\t\try=\"70%\"\n\t\t\t\t\t\tcy={ Platform.OS === 'android' ? width / 2 : '50%' }\n\t\t\t\t\t>\n\t\t\t\t\t\t{ colorGroup.map( ( group ) => {\n\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t<Stop\n\t\t\t\t\t\t\t\t\toffset={ group[ 1 ] }\n\t\t\t\t\t\t\t\t\tstopColor={ group[ 0 ] }\n\t\t\t\t\t\t\t\t\tstopOpacity=\"1\"\n\t\t\t\t\t\t\t\t\tkey={ `${ group[ 1 ] }-${ group[ 0 ] }` }\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t} ) }\n\t\t\t\t\t</RadialGradient>\n\t\t\t\t</Defs>\n\t\t\t\t<Rect\n\t\t\t\t\theight={ height }\n\t\t\t\t\twidth={ width }\n\t\t\t\t\tfill=\"url(#radialGradient)\"\n\t\t\t\t/>\n\t\t\t</SVG>\n\t\t</View>\n\t);\n}\n\nexport default Gradient;\n"]}
1
+ {"version":3,"sources":["@wordpress/components/src/mobile/gradient/index.native.js"],"names":["View","Platform","RNLinearGradient","gradientParser","colorsUtils","RadialGradient","Stop","SVG","Defs","Rect","useResizeObserver","useMemo","styles","getGradientAngle","gradientValue","angleBase","matchAngle","angle","exec","angleType","includes","parseFloat","getGradientColorGroup","colorNeedParenthesis","excludeSideOrCorner","modifiedGradientValue","replace","concat","parse","map","gradient","colorStops","color","index","type","value","length","fallbackLength","colorLength","join","getGradientBaseColors","colorGroup","getColorLocations","location","Number","Gradient","style","angleCenter","x","y","children","otherProps","resizeObserver","sizes","width","height","isGradient","getGradientType","gradients","locations","colors","isLinearGradient","linear","overflow","radialGradientContent","OS","group"],"mappings":";;;AAAA;AACA;AACA;AACA,SAASA,IAAT,EAAeC,QAAf,QAA+B,cAA/B;AACA,OAAOC,gBAAP,MAA6B,8BAA7B;AACA,OAAOC,cAAP,MAA2B,iBAA3B;AACA;AACA;AACA;;AACA,SAASC,WAAT,QAA4B,uBAA5B;AACA,SAASC,cAAT,EAAyBC,IAAzB,EAA+BC,GAA/B,EAAoCC,IAApC,EAA0CC,IAA1C,QAAsD,uBAAtD;AACA,SAASC,iBAAT,QAAkC,oBAAlC;AACA,SAASC,OAAT,QAAwB,oBAAxB;AAEA;AACA;AACA;;AACA,OAAOC,MAAP,MAAmB,cAAnB;AAEA,OAAO,SAASC,gBAAT,CAA2BC,aAA3B,EAA2C;AACjD,QAAMC,SAAS,GAAG,EAAlB;AACA,QAAMC,UAAU,GAAG,0BAAnB;AACA,QAAM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KAAF,EAASlC,MAAM,CAACmD,QAAhB;AAAd,KACC,cAAC,IAAD;AAAM,IAAA,KAAK,EAAGnD,MAAM,CAACoD;AAArB,KAA+Cd,QAA/C,CADD,EAEGE,cAFH,EAGC,cAAC,GAAD,QACC,cAAC,IAAD,QACC,cAAC,cAAD,CACC;AADD;AAEC,IAAA,EAAE,EAAC,gBAFJ;AAGC,IAAA,aAAa,EAAC,gBAHf;AAIC,IAAA,EAAE,EAAC,KAJJ;AAKC,IAAA,EAAE,EAAC,KALJ;AAMC,IAAA,EAAE,EAAGnD,QAAQ,CAACgE,EAAT,KAAgB,SAAhB,GAA4BX,KAAK,GAAG,CAApC,GAAwC;AAN9C,KAQGb,UAAU,CAACZ,GAAX,CAAkBqC,KAAF,IAAa;AAC9B,WACC,cAAC,IAAD;AACC,MAAA,MAAM,EAAGA,KAAK,CAAE,CAAF,CADf;AAEC,MAAA,SAAS,EAAGA,KAAK,CAAE,CAAF,CAFlB;AAGC,MAAA,WAAW,EAAC,GAHb;AAIC,MAAA,GAAG,EAAI,GAAGA,KAAK,CAAE,CAAF,CAAO,IAAIA,KAAK,CAAE,CAAF,CAAO;AAJvC,MADD;AAQA,GATC,CARH,CADD,CADD,EAsBC,cAAC,IAAD;AACC,IAAA,MAAM,EAAGX,MADV;AAEC,IAAA,KAAK,EAAGD,KAFT;AAGC,IAAA,IAAI,EAAC;AAHN,IAtBD,CAHD,CADD;AAkCA;;AAED,eAAeT,QAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { View, Platform } from 'react-native';\nimport RNLinearGradient from 'react-native-linear-gradient';\nimport gradientParser from 'gradient-parser';\n/**\n * WordPress dependencies\n */\nimport { colorsUtils } from '@wordpress/components';\nimport { RadialGradient, Stop, SVG, Defs, Rect } from '@wordpress/primitives';\nimport { useResizeObserver } from '@wordpress/compose';\nimport { useMemo } from '@wordpress/element';\n\n/**\n * Internal dependencies\n */\nimport styles from './style.scss';\n\nexport function getGradientAngle( gradientValue ) {\n\tconst angleBase = 45;\n\tconst matchAngle = /\\(((\\d+deg)|(to\\s[^,]+))/;\n\tconst angle = matchAngle.exec( gradientValue )\n\t\t? matchAngle.exec( gradientValue )[ 1 ]\n\t\t: '180deg';\n\n\tconst angleType = angle.includes( 'deg' ) ? 'angle' : 'sideOrCorner';\n\n\tif ( angleType === 'sideOrCorner' ) {\n\t\tswitch ( angle ) {\n\t\t\tcase 'to top':\n\t\t\t\treturn 0;\n\t\t\tcase 'to top right':\n\t\t\tcase 'to right top':\n\t\t\t\treturn angleBase;\n\t\t\tcase 'to right':\n\t\t\t\treturn 2 * angleBase;\n\t\t\tcase 'to bottom right':\n\t\t\tcase 'to right bottom':\n\t\t\t\treturn 3 * angleBase;\n\t\t\tcase 'to bottom':\n\t\t\t\treturn 4 * angleBase;\n\t\t\tcase 'to bottom left':\n\t\t\tcase 'to left bottom':\n\t\t\t\treturn 5 * angleBase;\n\t\t\tcase 'to left':\n\t\t\t\treturn 6 * angleBase;\n\t\t\tcase 'to top left':\n\t\t\tcase 'to left top':\n\t\t\t\treturn 7 * angleBase;\n\t\t}\n\t} else if ( angleType === 'angle' ) {\n\t\treturn parseFloat( angle );\n\t} else return 4 * angleBase;\n}\n\nexport function getGradientColorGroup( gradientValue ) {\n\tconst colorNeedParenthesis = [ 'rgb', 'rgba' ];\n\n\tconst excludeSideOrCorner = /linear-gradient\\(to\\s+([a-z\\s]+,)/;\n\n\t// Parser has some difficulties with angle defined as a side or corner (e.g. `to left`)\n\t// so it's going to be excluded in order to matching color groups.\n\tconst modifiedGradientValue = gradientValue.replace(\n\t\texcludeSideOrCorner,\n\t\t'linear-gradient('\n\t);\n\n\treturn [].concat(\n\t\t...gradientParser.parse( modifiedGradientValue )?.map( ( gradient ) =>\n\t\t\tgradient.colorStops?.map( ( color, index ) => {\n\t\t\t\tconst { type, value, length } = color;\n\t\t\t\tconst fallbackLength = `${\n\t\t\t\t\t100 * ( index / ( gradient.colorStops.length - 1 ) )\n\t\t\t\t}%`;\n\t\t\t\tconst colorLength = length\n\t\t\t\t\t? `${ length.value }${ length.type }`\n\t\t\t\t\t: fallbackLength;\n\n\t\t\t\tif ( colorNeedParenthesis.includes( type ) ) {\n\t\t\t\t\treturn [ `${ type }(${ value.join( ',' ) })`, colorLength ];\n\t\t\t\t} else if ( type === 'literal' ) {\n\t\t\t\t\treturn [ value, colorLength ];\n\t\t\t\t}\n\t\t\t\treturn [ `#${ value }`, colorLength ];\n\t\t\t} )\n\t\t)\n\t);\n}\n\nexport function getGradientBaseColors( colorGroup ) {\n\treturn colorGroup.map( ( color ) => color[ 0 ] );\n}\n\nexport function getColorLocations( colorGroup ) {\n\treturn colorGroup.map(\n\t\t( location ) => Number( location[ 1 ].replace( '%', '' ) ) / 100\n\t);\n}\n\nfunction Gradient( {\n\tgradientValue,\n\tstyle,\n\tangleCenter = { x: 0.5, y: 0.5 },\n\tchildren,\n\t...otherProps\n} ) {\n\tconst [ resizeObserver, sizes ] = useResizeObserver();\n\tconst { width = 0, height = 0 } = sizes || {};\n\tconst { isGradient, getGradientType, gradients } = colorsUtils;\n\n\tconst colorGroup = useMemo(\n\t\t() => getGradientColorGroup( gradientValue ),\n\t\t[ gradientValue ]\n\t);\n\n\tconst locations = useMemo(\n\t\t() => getColorLocations( colorGroup ),\n\t\t[ colorGroup ]\n\t);\n\n\tconst colors = useMemo(\n\t\t() => getGradientBaseColors( colorGroup ),\n\t\t[ colorGroup ]\n\t);\n\n\tif ( ! gradientValue || ! isGradient( gradientValue ) ) {\n\t\treturn null;\n\t}\n\n\tconst isLinearGradient =\n\t\tgetGradientType( gradientValue ) === gradients.linear;\n\n\tif ( isLinearGradient ) {\n\t\treturn (\n\t\t\t<RNLinearGradient\n\t\t\t\tcolors={ colors }\n\t\t\t\tuseAngle={ true }\n\t\t\t\tangle={ getGradientAngle( gradientValue ) }\n\t\t\t\tlocations={ locations }\n\t\t\t\tangleCenter={ angleCenter }\n\t\t\t\tstyle={ style }\n\t\t\t\t{ ...otherProps }\n\t\t\t>\n\t\t\t\t{ children }\n\t\t\t</RNLinearGradient>\n\t\t);\n\t}\n\n\treturn (\n\t\t<View style={ [ style, styles.overflow ] }>\n\t\t\t<View style={ styles.radialGradientContent }>{ children }</View>\n\t\t\t{ resizeObserver }\n\t\t\t<SVG>\n\t\t\t\t<Defs>\n\t\t\t\t\t<RadialGradient\n\t\t\t\t\t\t// eslint-disable-next-line no-restricted-syntax\n\t\t\t\t\t\tid=\"radialGradient\"\n\t\t\t\t\t\tgradientUnits=\"userSpaceOnUse\"\n\t\t\t\t\t\trx=\"70%\"\n\t\t\t\t\t\try=\"70%\"\n\t\t\t\t\t\tcy={ Platform.OS === 'android' ? width / 2 : '50%' }\n\t\t\t\t\t>\n\t\t\t\t\t\t{ colorGroup.map( ( group ) => {\n\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t<Stop\n\t\t\t\t\t\t\t\t\toffset={ group[ 1 ] }\n\t\t\t\t\t\t\t\t\tstopColor={ group[ 0 ] }\n\t\t\t\t\t\t\t\t\tstopOpacity=\"1\"\n\t\t\t\t\t\t\t\t\tkey={ `${ group[ 1 ] }-${ group[ 0 ] }` }\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t} ) }\n\t\t\t\t\t</RadialGradient>\n\t\t\t\t</Defs>\n\t\t\t\t<Rect\n\t\t\t\t\theight={ height }\n\t\t\t\t\twidth={ width }\n\t\t\t\t\tfill=\"url(#radialGradient)\"\n\t\t\t\t/>\n\t\t\t</SVG>\n\t\t</View>\n\t);\n}\n\nexport default Gradient;\n"]}
@@ -1 +1 @@
1
- {"version":3,"sources":["@wordpress/components/src/mobile/html-text-input/index.native.js"],"names":["ScrollView","TextInput","Component","__","parse","withDispatch","withSelect","addFilter","removeFilter","withInstanceId","compose","withPreferredColorScheme","KeyboardAvoidingView","styles","HTMLTextInput","constructor","arguments","edit","bind","stopEditing","getHTMLForParent","state","getDerivedStateFromProps","props","isDirty","value","componentWillUnmount","html","onChange","setState","onPersist","render","editTitle","getStylesFromColorScheme","parentHeight","style","title","titleStyle","htmlViewTitle","text","color","htmlStyle","htmlView","htmlViewDark","placeholderStyle","placeholder","placeholderDark","keyboardAvoidingView","scrollView","contentTextInputRef","select","getEditedPostAttribute","getEditedPostContent","dispatch","editPost","resetEditorBlocks","content","blocks"],"mappings":";;AAAA;AACA;AACA;AACA,SAASA,UAAT,EAAqBC,SAArB,QAAsC,cAAtC;AAEA;AACA;AACA;;AACA,SAASC,SAAT,QAA0B,oBAA1B;AACA,SAASC,EAAT,QAAmB,iBAAnB;AACA,SAASC,KAAT,QAAsB,mBAAtB;AACA,SAASC,YAAT,EAAuBC,UAAvB,QAAyC,iBAAzC;AACA,SAASC,SAAT,EAAoBC,YAApB,QAAwC,kBAAxC;AACA,SACCC,cADD,EAECC,OAFD,EAGCC,wBAHD,QAIO,oBAJP;AAMA;AACA;AACA;;AACA,OAAOC,oBAAP,MAAiC,2BAAjC;AACA,OAAOC,MAAP,MAAmB,cAAnB;AAEA,OAAO,MAAMC,aAAN,SAA4BZ,SAA5B,CAAsC;AAC5Ca,EAAAA,WAAW,GAAG;AACb,UAAO,GAAGC,SAAV;AAEA,SAAKC,IAAL,GAAY,KAAKA,IAAL,CAAUC,IAAV,CAAgB,IAAhB,CAAZ;AACA,SAAKC,WAAL,GAAmB,KAAKA,WAAL,CAAiBD,IAAjB,CAAuB,IAAvB,CAAnB;AACA,SAAKE,gBAAL,GAAwB,KAAKA,gBAAL,CAAsBF,IAAtB,CAA4B,IAA5B,CAAxB;AACAX,IAAAA,SAAS,CACR,qBADQ,EAER,iBAFQ,EAGR,KAAKa,gBAHG,CAAT;AAMA,SAAKC,KAAL,GAAa,EAAb;AACA;;AAE8B,SAAxBC,wBAAwB,CAAEC,KAAF,EAASF,KAAT,EAAiB;AAC/C,QAAKA,KAAK,CAACG,OAAX,EAAqB;AACpB,aAAO,IAAP;AACA;;AAED,WAAO;AACNC,MAAAA,KAAK,EAAEF,KAAK,CAACE,KADP;A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,KAZjB,CAaC;AACA;AACA;AAfD;AAgBC,MAAA,0BAA0B,EAAG;AAhB9B,MAZD,CAJD,CADD;AAsCA;;AA9G2C;AAiH7C,eAAe9B,OAAO,CAAE,CACvBJ,UAAU,CAAI4C,MAAF,IAAc;AACzB,QAAM;AAAEC,IAAAA,sBAAF;AAA0BC,IAAAA;AAA1B,MAAmDF,MAAM,CAC9D,aAD8D,CAA/D;AAIA,SAAO;AACNd,IAAAA,KAAK,EAAEe,sBAAsB,CAAE,OAAF,CADvB;AAEN1B,IAAAA,KAAK,EAAE2B,oBAAoB;AAFrB,GAAP;AAIA,CATS,CADa,EAWvB/C,YAAY,CAAIgD,QAAF,IAAgB;AAC7B,QAAM;AAAEC,IAAAA,QAAF;AAAYC,IAAAA;AAAZ,MAAkCF,QAAQ,CAAE,aAAF,CAAhD;AACA,SAAO;AACNrB,IAAAA,SAAS,CAAEI,KAAF,EAAU;AAClBkB,MAAAA,QAAQ,CAAE;AAAElB,QAAAA;AAAF,OAAF,CAAR;AACA,KAHK;;AAINR,IAAAA,QAAQ,CAAE4B,OAAF,EAAY;AACnBF,MAAAA,QAAQ,CAAE;AAAEE,QAAAA;AAAF,OAAF,CAAR;AACA,KANK;;AAON1B,IAAAA,SAAS,CAAE0B,OAAF,EAAY;AACpB,YAAMC,MAAM,GAAGrD,KAAK,CAAEoD,OAAF,CAApB;AACAD,MAAAA,iBAAiB,CAAEE,MAAF,CAAjB;AACA;;AAVK,GAAP;AAYA,CAdW,CAXW,EA0BvBhD,cA1BuB,EA2BvBE,wBA3BuB,CAAF,CAAP,CA4BVG,aA5BU,CAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { ScrollView, TextInput } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { Component } from '@wordpress/element';\nimport { __ } from '@wordpress/i18n';\nimport { parse } from '@wordpress/blocks';\nimport { withDispatch, withSelect } from '@wordpress/data';\nimport { addFilter, removeFilter } from '@wordpress/hooks';\nimport {\n\twithInstanceId,\n\tcompose,\n\twithPreferredColorScheme,\n} from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport KeyboardAvoidingView from '../keyboard-avoiding-view';\nimport styles from './style.scss';\n\nexport class HTMLTextInput extends Component {\n\tconstructor() {\n\t\tsuper( ...arguments );\n\n\t\tthis.edit = this.edit.bind( this );\n\t\tthis.stopEditing = this.stopEditing.bind( this );\n\t\tthis.getHTMLForParent = this.getHTMLForParent.bind( this );\n\t\taddFilter(\n\t\t\t'native.persist-html',\n\t\t\t'html-text-input',\n\t\t\tthis.getHTMLForParent\n\t\t);\n\n\t\tthis.state = {};\n\t}\n\n\tstatic getDerivedStateFromProps( props, state ) {\n\t\tif ( state.isDirty ) {\n\t\t\treturn null;\n\t\t}\n\n\t\treturn {\n\t\t\tvalue: props.value,\n\t\t\tisDirty: false,\n\t\t};\n\t}\n\n\tcomponentWillUnmount() {\n\t\tremoveFilter( 'native.persist-html', 'html-text-input' );\n\t\t// TODO: Blocking main thread.\n\t\tthis.stopEditing();\n\t}\n\n\tedit( html ) {\n\t\tthis.props.onChange( html );\n\t\tthis.setState( { value: html, isDirty: true } );\n\t}\n\n\tgetHTMLForParent() {\n\t\treturn this.state.value;\n\t}\n\n\tstopEditing() {\n\t\tif ( this.state.isDirty ) {\n\t\t\tthis.props.onPersist( this.state.value );\n\t\t\tthis.setState( { isDirty: false } );\n\t\t}\n\t}\n\n\trender() {\n\t\tconst {\n\t\t\teditTitle,\n\t\t\tgetStylesFromColorScheme,\n\t\t\tparentHeight,\n\t\t\tstyle,\n\t\t\ttitle,\n\t\t} = this.props;\n\t\tconst titleStyle = [\n\t\t\tstyles.htmlViewTitle,\n\t\t\tstyle?.text && { color: style.text },\n\t\t];\n\t\tconst htmlStyle = [\n\t\t\tgetStylesFromColorScheme( styles.htmlView, styles.htmlViewDark ),\n\t\t\tstyle?.text && { color: style.text },\n\t\t];\n\t\tconst placeholderStyle = {\n\t\t\t...getStylesFromColorScheme(\n\t\t\t\tstyles.placeholder,\n\t\t\t\tstyles.placeholderDark\n\t\t\t),\n\t\t\t...( style?.text && { color: style.text } ),\n\t\t};\n\t\treturn (\n\t\t\t<KeyboardAvoidingView\n\t\t\t\tstyle={ styles.keyboardAvoidingView }\n\t\t\t\tparentHeight={ parentHeight }\n\t\t\t>\n\t\t\t\t<ScrollView style={ styles.scrollView }>\n\t\t\t\t\t<TextInput\n\t\t\t\t\t\tautoCorrect={ false }\n\t\t\t\t\t\taccessibilityLabel=\"html-view-title\"\n\t\t\t\t\t\ttextAlignVertical=\"center\"\n\t\t\t\t\t\tnumberOfLines={ 1 }\n\t\t\t\t\t\tstyle={ titleStyle }\n\t\t\t\t\t\tvalue={ title }\n\t\t\t\t\t\tplaceholder={ __( 'Add title' ) }\n\t\t\t\t\t\tplaceholderTextColor={ placeholderStyle.color }\n\t\t\t\t\t\tonChangeText={ editTitle }\n\t\t\t\t\t/>\n\t\t\t\t\t<TextInput\n\t\t\t\t\t\tref={ this.contentTextInputRef }\n\t\t\t\t\t\tautoCorrect={ false }\n\t\t\t\t\t\taccessibilityLabel=\"html-view-content\"\n\t\t\t\t\t\ttextAlignVertical=\"top\"\n\t\t\t\t\t\tmultiline\n\t\t\t\t\t\tstyle={ htmlStyle }\n\t\t\t\t\t\tvalue={ this.state.value }\n\t\t\t\t\t\tonChangeText={ this.edit }\n\t\t\t\t\t\tonBlur={ this.stopEditing }\n\t\t\t\t\t\tplaceholder={ __( 'Start writing…' ) }\n\t\t\t\t\t\tplaceholderTextColor={ placeholderStyle.color }\n\t\t\t\t\t\tscrollEnabled={ false }\n\t\t\t\t\t\t// [Only iOS] This prop prevents the text input from\n\t\t\t\t\t\t// automatically getting focused after scrolling\n\t\t\t\t\t\t// content.\n\t\t\t\t\t\trejectResponderTermination={ false }\n\t\t\t\t\t/>\n\t\t\t\t</ScrollView>\n\t\t\t</KeyboardAvoidingView>\n\t\t);\n\t}\n}\n\nexport default compose( [\n\twithSelect( ( select ) => {\n\t\tconst { getEditedPostAttribute, getEditedPostContent } = select(\n\t\t\t'core/editor'\n\t\t);\n\n\t\treturn {\n\t\t\ttitle: getEditedPostAttribute( 'title' ),\n\t\t\tvalue: getEditedPostContent(),\n\t\t};\n\t} ),\n\twithDispatch( ( dispatch ) => {\n\t\tconst { editPost, resetEditorBlocks } = dispatch( 'core/editor' );\n\t\treturn {\n\t\t\teditTitle( title ) {\n\t\t\t\teditPost( { title } );\n\t\t\t},\n\t\t\tonChange( content ) {\n\t\t\t\teditPost( { content } );\n\t\t\t},\n\t\t\tonPersist( content ) {\n\t\t\t\tconst blocks = parse( content );\n\t\t\t\tresetEditorBlocks( blocks );\n\t\t\t},\n\t\t};\n\t} ),\n\twithInstanceId,\n\twithPreferredColorScheme,\n] )( HTMLTextInput );\n"]}
1
+ {"version":3,"sources":["@wordpress/components/src/mobile/html-text-input/index.native.js"],"names":["ScrollView","TextInput","Component","__","parse","withDispatch","withSelect","addFilter","removeFilter","withInstanceId","compose","withPreferredColorScheme","KeyboardAvoidingView","styles","HTMLTextInput","constructor","arguments","edit","bind","stopEditing","getHTMLForParent","state","getDerivedStateFromProps","props","isDirty","value","componentWillUnmount","html","onChange","setState","onPersist","render","editTitle","getStylesFromColorScheme","parentHeight","style","title","titleStyle","htmlViewTitle","text","color","htmlStyle","htmlView","htmlViewDark","placeholderStyle","placeholder","placeholderDark","keyboardAvoidingView","scrollView","contentTextInputRef","select","getEditedPostAttribute","getEditedPostContent","dispatch","editPost","resetEditorBlocks","content","blocks"],"mappings":";;AAAA;AACA;AACA;AACA,SAASA,UAAT,EAAqBC,SAArB,QAAsC,cAAtC;AAEA;AACA;AACA;;AACA,SAASC,SAAT,QAA0B,oBAA1B;AACA,SAASC,EAAT,QAAmB,iBAAnB;AACA,SAASC,KAAT,QAAsB,mBAAtB;AACA,SAASC,YAAT,EAAuBC,UAAvB,QAAyC,iBAAzC;AACA,SAASC,SAAT,EAAoBC,YAApB,QAAwC,kBAAxC;AACA,SACCC,cADD,EAECC,OAFD,EAGCC,wBAHD,QAI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B,IAAAA,SAAS,CAAEI,KAAF,EAAU;AAClBkB,MAAAA,QAAQ,CAAE;AAAElB,QAAAA;AAAF,OAAF,CAAR;AACA,KAHK;;AAINR,IAAAA,QAAQ,CAAE4B,OAAF,EAAY;AACnBF,MAAAA,QAAQ,CAAE;AAAEE,QAAAA;AAAF,OAAF,CAAR;AACA,KANK;;AAON1B,IAAAA,SAAS,CAAE0B,OAAF,EAAY;AACpB,YAAMC,MAAM,GAAGrD,KAAK,CAAEoD,OAAF,CAApB;AACAD,MAAAA,iBAAiB,CAAEE,MAAF,CAAjB;AACA;;AAVK,GAAP;AAYA,CAdW,CAVW,EAyBvBhD,cAzBuB,EA0BvBE,wBA1BuB,CAAF,CAAP,CA2BVG,aA3BU,CAAf","sourcesContent":["/**\n * External dependencies\n */\nimport { ScrollView, TextInput } from 'react-native';\n\n/**\n * WordPress dependencies\n */\nimport { Component } from '@wordpress/element';\nimport { __ } from '@wordpress/i18n';\nimport { parse } from '@wordpress/blocks';\nimport { withDispatch, withSelect } from '@wordpress/data';\nimport { addFilter, removeFilter } from '@wordpress/hooks';\nimport {\n\twithInstanceId,\n\tcompose,\n\twithPreferredColorScheme,\n} from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport KeyboardAvoidingView from '../keyboard-avoiding-view';\nimport styles from './style.scss';\n\nexport class HTMLTextInput extends Component {\n\tconstructor() {\n\t\tsuper( ...arguments );\n\n\t\tthis.edit = this.edit.bind( this );\n\t\tthis.stopEditing = this.stopEditing.bind( this );\n\t\tthis.getHTMLForParent = this.getHTMLForParent.bind( this );\n\t\taddFilter(\n\t\t\t'native.persist-html',\n\t\t\t'html-text-input',\n\t\t\tthis.getHTMLForParent\n\t\t);\n\n\t\tthis.state = {};\n\t}\n\n\tstatic getDerivedStateFromProps( props, state ) {\n\t\tif ( state.isDirty ) {\n\t\t\treturn null;\n\t\t}\n\n\t\treturn {\n\t\t\tvalue: props.value,\n\t\t\tisDirty: false,\n\t\t};\n\t}\n\n\tcomponentWillUnmount() {\n\t\tremoveFilter( 'native.persist-html', 'html-text-input' );\n\t\t// TODO: Blocking main thread.\n\t\tthis.stopEditing();\n\t}\n\n\tedit( html ) {\n\t\tthis.props.onChange( html );\n\t\tthis.setState( { value: html, isDirty: true } );\n\t}\n\n\tgetHTMLForParent() {\n\t\treturn this.state.value;\n\t}\n\n\tstopEditing() {\n\t\tif ( this.state.isDirty ) {\n\t\t\tthis.props.onPersist( this.state.value );\n\t\t\tthis.setState( { isDirty: false } );\n\t\t}\n\t}\n\n\trender() {\n\t\tconst {\n\t\t\teditTitle,\n\t\t\tgetStylesFromColorScheme,\n\t\t\tparentHeight,\n\t\t\tstyle,\n\t\t\ttitle,\n\t\t} = this.props;\n\t\tconst titleStyle = [\n\t\t\tstyles.htmlViewTitle,\n\t\t\tstyle?.text && { color: style.text },\n\t\t];\n\t\tconst htmlStyle = [\n\t\t\tgetStylesFromColorScheme( styles.htmlView, styles.htmlViewDark ),\n\t\t\tstyle?.text && { color: style.text },\n\t\t];\n\t\tconst placeholderStyle = {\n\t\t\t...getStylesFromColorScheme(\n\t\t\t\tstyles.placeholder,\n\t\t\t\tstyles.placeholderDark\n\t\t\t),\n\t\t\t...( style?.text && { color: style.text } ),\n\t\t};\n\t\treturn (\n\t\t\t<KeyboardAvoidingView\n\t\t\t\tstyle={ styles.keyboardAvoidingView }\n\t\t\t\tparentHeight={ parentHeight }\n\t\t\t>\n\t\t\t\t<ScrollView style={ styles.scrollView }>\n\t\t\t\t\t<TextInput\n\t\t\t\t\t\tautoCorrect={ false }\n\t\t\t\t\t\taccessibilityLabel=\"html-view-title\"\n\t\t\t\t\t\ttextAlignVertical=\"center\"\n\t\t\t\t\t\tnumberOfLines={ 1 }\n\t\t\t\t\t\tstyle={ titleStyle }\n\t\t\t\t\t\tvalue={ title }\n\t\t\t\t\t\tplaceholder={ __( 'Add title' ) }\n\t\t\t\t\t\tplaceholderTextColor={ placeholderStyle.color }\n\t\t\t\t\t\tonChangeText={ editTitle }\n\t\t\t\t\t/>\n\t\t\t\t\t<TextInput\n\t\t\t\t\t\tref={ this.contentTextInputRef }\n\t\t\t\t\t\tautoCorrect={ false }\n\t\t\t\t\t\taccessibilityLabel=\"html-view-content\"\n\t\t\t\t\t\ttextAlignVertical=\"top\"\n\t\t\t\t\t\tmultiline\n\t\t\t\t\t\tstyle={ htmlStyle }\n\t\t\t\t\t\tvalue={ this.state.value }\n\t\t\t\t\t\tonChangeText={ this.edit }\n\t\t\t\t\t\tonBlur={ this.stopEditing }\n\t\t\t\t\t\tplaceholder={ __( 'Start writing…' ) }\n\t\t\t\t\t\tplaceholderTextColor={ placeholderStyle.color }\n\t\t\t\t\t\tscrollEnabled={ false }\n\t\t\t\t\t\t// [Only iOS] This prop prevents the text input from\n\t\t\t\t\t\t// automatically getting focused after scrolling\n\t\t\t\t\t\t// content.\n\t\t\t\t\t\trejectResponderTermination={ false }\n\t\t\t\t\t/>\n\t\t\t\t</ScrollView>\n\t\t\t</KeyboardAvoidingView>\n\t\t);\n\t}\n}\n\nexport default compose( [\n\twithSelect( ( select ) => {\n\t\tconst { getEditedPostAttribute, getEditedPostContent } =\n\t\t\tselect( 'core/editor' );\n\n\t\treturn {\n\t\t\ttitle: getEditedPostAttribute( 'title' ),\n\t\t\tvalue: getEditedPostContent(),\n\t\t};\n\t} ),\n\twithDispatch( ( dispatch ) => {\n\t\tconst { editPost, resetEditorBlocks } = dispatch( 'core/editor' );\n\t\treturn {\n\t\t\teditTitle( title ) {\n\t\t\t\teditPost( { title } );\n\t\t\t},\n\t\t\tonChange( content ) {\n\t\t\t\teditPost( { content } );\n\t\t\t},\n\t\t\tonPersist( content ) {\n\t\t\t\tconst blocks = parse( content );\n\t\t\t\tresetEditorBlocks( blocks );\n\t\t\t},\n\t\t};\n\t} ),\n\twithInstanceId,\n\twithPreferredColorScheme,\n] )( HTMLTextInput );\n"]}
@@ -5,6 +5,7 @@ import { createElement } from "@wordpress/element";
5
5
  * External dependencies
6
6
  */
7
7
  import { Image, Text, View } from 'react-native';
8
+ import FastImage from 'react-native-fast-image';
8
9
  /**
9
10
  * WordPress dependencies
10
11
  */
@@ -166,7 +167,7 @@ const ImageComponent = _ref => {
166
167
  style: styles.imageUploadingIconContainer
167
168
  }, getIcon(ICON_TYPE.UPLOAD))) : createElement(View, {
168
169
  style: focalPoint && styles.focalPointContent
169
- }, createElement(Image, _extends({}, !resizeMode && {
170
+ }, createElement(FastImage, _extends({}, !resizeMode && {
170
171
  aspectRatio: imageData === null || imageData === void 0 ? void 0 : imageData.aspectRatio
171
172
  }, {
172
173
  style: imageStyles,
@@ -176,7 +177,7 @@ const ImageComponent = _ref => {
176
177
  }, !focalPoint && {
177
178
  resizeMethod: 'scale'
178
179
  }, {
179
- resizeMode: resizeMode
180
+ resizeMode: FastImage.resizeMode[resizeMode]
180
181
  }))), isUploadFailed && retryMessage && createElement(View, {
181
182
  style: [styles.imageContainer, styles.retryContainer]
182
183
  }, createElement(View, {