@cloudscape-design/components 3.0.996 → 3.0.998

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 (1163) hide show
  1. package/alert/actions-wrapper/index.d.ts +22 -14
  2. package/alert/analytics-metadata/interfaces.d.ts +14 -15
  3. package/alert/index.d.ts +1 -2
  4. package/alert/interfaces.d.ts +86 -87
  5. package/alert/internal.d.ts +3 -4
  6. package/anchor-navigation/anchor-item/index.d.ts +13 -8
  7. package/anchor-navigation/index.d.ts +4 -2
  8. package/anchor-navigation/interfaces.d.ts +55 -56
  9. package/anchor-navigation/internal.d.ts +10 -2
  10. package/anchor-navigation/use-scroll-spy.d.ts +9 -6
  11. package/anchor-navigation/utils.d.ts +3 -4
  12. package/annotation-context/annotation/annotation-icon.d.ts +5 -4
  13. package/annotation-context/annotation/annotation-popover.d.ts +35 -19
  14. package/annotation-context/annotation/annotation-trigger.d.ts +6 -7
  15. package/annotation-context/annotation/closed-annotation.d.ts +15 -9
  16. package/annotation-context/annotation/open-annotation.d.ts +33 -18
  17. package/annotation-context/annotation/styles.css.js +24 -24
  18. package/annotation-context/annotation/styles.scoped.css +32 -32
  19. package/annotation-context/annotation/styles.selectors.js +24 -24
  20. package/annotation-context/context.d.ts +8 -9
  21. package/annotation-context/index.d.ts +9 -2
  22. package/annotation-context/interfaces.d.ts +67 -68
  23. package/annotation-context/utils.d.ts +9 -10
  24. package/app-layout/classic.d.ts +14 -15
  25. package/app-layout/content-wrapper/index.d.ts +10 -11
  26. package/app-layout/defaults.d.ts +4 -5
  27. package/app-layout/drawer/drawers-helpers.d.ts +6 -7
  28. package/app-layout/drawer/index.d.ts +10 -2
  29. package/app-layout/drawer/interfaces.d.ts +50 -51
  30. package/app-layout/drawer/overflow-menu.d.ts +14 -9
  31. package/app-layout/drawer/resizable-drawer.d.ts +9 -2
  32. package/app-layout/index.d.ts +1 -2
  33. package/app-layout/interfaces.d.ts +294 -296
  34. package/app-layout/internal.d.ts +14 -15
  35. package/app-layout/mobile-toolbar/index.d.ts +34 -20
  36. package/app-layout/notifications/index.d.ts +7 -8
  37. package/app-layout/notifications/styles.css.js +3 -3
  38. package/app-layout/notifications/styles.scoped.css +7 -7
  39. package/app-layout/notifications/styles.selectors.js +3 -3
  40. package/app-layout/runtime-drawer/index.d.ts +5 -6
  41. package/app-layout/runtime-drawer/use-runtime-drawer-context.d.ts +5 -4
  42. package/app-layout/split-panel/constants.d.ts +1 -2
  43. package/app-layout/split-panel/drawer.d.ts +7 -5
  44. package/app-layout/split-panel/index.d.ts +1 -2
  45. package/app-layout/split-panel/provider.d.ts +14 -7
  46. package/app-layout/split-panel/split-panel-forced-position.d.ts +7 -5
  47. package/app-layout/toggles/index.d.ts +21 -22
  48. package/app-layout/toggles/interfaces.d.ts +11 -12
  49. package/app-layout/utils/feature-flags.d.ts +1 -2
  50. package/app-layout/utils/interfaces.d.ts +5 -6
  51. package/app-layout/utils/sticky-offsets.d.ts +2 -3
  52. package/app-layout/utils/use-app-layout-placement.d.ts +6 -7
  53. package/app-layout/utils/use-drawers.d.ts +48 -35
  54. package/app-layout/utils/use-focus-control.d.ts +15 -16
  55. package/app-layout/utils/use-keyboard-events.d.ts +8 -5
  56. package/app-layout/utils/use-observed-element.d.ts +1 -2
  57. package/app-layout/utils/use-pointer-events.d.ts +6 -2
  58. package/app-layout/utils/use-resize.d.ts +22 -15
  59. package/app-layout/utils/use-split-panel-focus-control.d.ts +9 -10
  60. package/app-layout/utils/visibility-context.d.ts +1 -2
  61. package/app-layout/visual-refresh/background.d.ts +1 -2
  62. package/app-layout/visual-refresh/breadcrumbs.d.ts +1 -2
  63. package/app-layout/visual-refresh/context.d.ts +55 -56
  64. package/app-layout/visual-refresh/drawers.d.ts +1 -2
  65. package/app-layout/visual-refresh/header.d.ts +1 -2
  66. package/app-layout/visual-refresh/index.d.ts +14 -15
  67. package/app-layout/visual-refresh/layout.d.ts +5 -4
  68. package/app-layout/visual-refresh/main.d.ts +1 -2
  69. package/app-layout/visual-refresh/mobile-toolbar.d.ts +1 -2
  70. package/app-layout/visual-refresh/navigation.d.ts +1 -2
  71. package/app-layout/visual-refresh/notifications.d.ts +1 -2
  72. package/app-layout/visual-refresh/split-panel.d.ts +6 -5
  73. package/app-layout/visual-refresh/styles.css.js +86 -86
  74. package/app-layout/visual-refresh/styles.scoped.css +258 -258
  75. package/app-layout/visual-refresh/styles.selectors.js +86 -86
  76. package/app-layout/visual-refresh/tools.d.ts +5 -4
  77. package/app-layout/visual-refresh/trigger-button.d.ts +19 -20
  78. package/app-layout/visual-refresh/use-background-overlap.d.ts +11 -8
  79. package/app-layout/visual-refresh-toolbar/compute-layout.d.ts +67 -44
  80. package/app-layout/visual-refresh-toolbar/contexts.d.ts +2 -3
  81. package/app-layout/visual-refresh-toolbar/drawer/global-drawer.d.ts +9 -6
  82. package/app-layout/visual-refresh-toolbar/drawer/global-drawers.d.ts +5 -4
  83. package/app-layout/visual-refresh-toolbar/drawer/index.d.ts +1 -2
  84. package/app-layout/visual-refresh-toolbar/drawer/local-drawer.d.ts +5 -4
  85. package/app-layout/visual-refresh-toolbar/drawer/styles.css.js +17 -17
  86. package/app-layout/visual-refresh-toolbar/drawer/styles.scoped.css +39 -39
  87. package/app-layout/visual-refresh-toolbar/drawer/styles.selectors.js +17 -17
  88. package/app-layout/visual-refresh-toolbar/drawer/use-resize.d.ts +19 -13
  89. package/app-layout/visual-refresh-toolbar/index.d.ts +1 -2
  90. package/app-layout/visual-refresh-toolbar/interfaces.d.ts +52 -53
  91. package/app-layout/visual-refresh-toolbar/internal.d.ts +1 -2
  92. package/app-layout/visual-refresh-toolbar/multi-layout.d.ts +26 -27
  93. package/app-layout/visual-refresh-toolbar/navigation/index.d.ts +5 -4
  94. package/app-layout/visual-refresh-toolbar/navigation/styles.css.js +4 -4
  95. package/app-layout/visual-refresh-toolbar/navigation/styles.scoped.css +7 -7
  96. package/app-layout/visual-refresh-toolbar/navigation/styles.selectors.js +4 -4
  97. package/app-layout/visual-refresh-toolbar/notifications/index.d.ts +7 -5
  98. package/app-layout/visual-refresh-toolbar/skeleton/breadcrumbs/index.d.ts +7 -5
  99. package/app-layout/visual-refresh-toolbar/skeleton/index.d.ts +12 -13
  100. package/app-layout/visual-refresh-toolbar/skeleton/slot-skeletons.d.ts +1 -2
  101. package/app-layout/visual-refresh-toolbar/skeleton/slot-wrappers.d.ts +7 -8
  102. package/app-layout/visual-refresh-toolbar/skeleton/styles.css.js +21 -21
  103. package/app-layout/visual-refresh-toolbar/skeleton/styles.scoped.css +45 -45
  104. package/app-layout/visual-refresh-toolbar/skeleton/styles.selectors.js +21 -21
  105. package/app-layout/visual-refresh-toolbar/split-panel/index.d.ts +17 -10
  106. package/app-layout/visual-refresh-toolbar/toolbar/drawer-triggers.d.ts +42 -25
  107. package/app-layout/visual-refresh-toolbar/toolbar/index.d.ts +27 -25
  108. package/app-layout/visual-refresh-toolbar/toolbar/trigger-button/index.d.ts +47 -48
  109. package/app-layout-toolbar/analytics-metadata/interfaces.d.ts +11 -12
  110. package/app-layout-toolbar/index.d.ts +1 -2
  111. package/app-layout-toolbar/interfaces.d.ts +46 -48
  112. package/area-chart/async-store/index.d.ts +11 -12
  113. package/area-chart/chart-container.d.ts +34 -8
  114. package/area-chart/elements/area-chart-filter.d.ts +11 -7
  115. package/area-chart/elements/area-chart-legend.d.ts +11 -7
  116. package/area-chart/elements/area-series.d.ts +8 -5
  117. package/area-chart/elements/chart-popover.d.ts +15 -9
  118. package/area-chart/elements/data-series.d.ts +5 -4
  119. package/area-chart/elements/highlighted-point.d.ts +3 -4
  120. package/area-chart/elements/threshold-series.d.ts +10 -6
  121. package/area-chart/elements/use-highlight-details.d.ts +22 -17
  122. package/area-chart/elements/vertical-marker.d.ts +5 -4
  123. package/area-chart/index.d.ts +10 -3
  124. package/area-chart/interfaces.d.ts +51 -52
  125. package/area-chart/internal.d.ts +38 -3
  126. package/area-chart/model/compute-chart-props.d.ts +30 -22
  127. package/area-chart/model/create-series-decorator.d.ts +1 -2
  128. package/area-chart/model/index.d.ts +72 -73
  129. package/area-chart/model/interactions-store.d.ts +15 -16
  130. package/area-chart/model/use-chart-model.d.ts +32 -17
  131. package/area-chart/model/use-filter-props.d.ts +1 -2
  132. package/area-chart/model/use-highlight-props.d.ts +1 -2
  133. package/area-chart/model/utils.d.ts +4 -5
  134. package/attribute-editor/additional-info.d.ts +7 -5
  135. package/attribute-editor/grid-defaults.d.ts +1 -2
  136. package/attribute-editor/index.d.ts +1 -2
  137. package/attribute-editor/interfaces.d.ts +148 -149
  138. package/attribute-editor/internal.d.ts +1 -2
  139. package/attribute-editor/row.d.ts +13 -14
  140. package/attribute-editor/utils.d.ts +3 -4
  141. package/autosuggest/analytics-metadata/interfaces.d.ts +6 -7
  142. package/autosuggest/autosuggest-option.d.ts +12 -13
  143. package/autosuggest/index.d.ts +1 -2
  144. package/autosuggest/interfaces.d.ts +118 -119
  145. package/autosuggest/internal.d.ts +2 -4
  146. package/autosuggest/load-more-controller.d.ts +13 -10
  147. package/autosuggest/options-controller.d.ts +24 -17
  148. package/autosuggest/options-list.d.ts +28 -14
  149. package/autosuggest/plain-list.d.ts +23 -15
  150. package/autosuggest/utils/utils.d.ts +1 -2
  151. package/autosuggest/virtual-list.d.ts +11 -3
  152. package/badge/index.d.ts +5 -2
  153. package/badge/interfaces.d.ts +9 -10
  154. package/bar-chart/index.d.ts +14 -3
  155. package/bar-chart/interfaces.d.ts +27 -28
  156. package/box/index.d.ts +6 -2
  157. package/box/interfaces.d.ts +130 -131
  158. package/box/internal.d.ts +16 -3
  159. package/breadcrumb-group/all-items-dropdown.d.ts +13 -10
  160. package/breadcrumb-group/analytics-metadata/interfaces.d.ts +17 -18
  161. package/breadcrumb-group/implementation.d.ts +11 -3
  162. package/breadcrumb-group/index.d.ts +4 -2
  163. package/breadcrumb-group/interfaces.d.ts +56 -59
  164. package/breadcrumb-group/internal.d.ts +1 -2
  165. package/breadcrumb-group/item/funnel.d.ts +6 -7
  166. package/breadcrumb-group/item/item.d.ts +9 -2
  167. package/breadcrumb-group/skeleton.d.ts +2 -3
  168. package/breadcrumb-group/utils.d.ts +5 -6
  169. package/button/analytics-metadata/interfaces.d.ts +12 -13
  170. package/button/icon-helper.d.ts +11 -12
  171. package/button/index.d.ts +1 -2
  172. package/button/index.d.ts.map +1 -1
  173. package/button/index.js +11 -13
  174. package/button/interfaces.d.ts +202 -169
  175. package/button/interfaces.d.ts.map +1 -1
  176. package/button/interfaces.js.map +1 -1
  177. package/button/internal-do-not-use-core.js +20 -0
  178. package/button/internal-do-not-use-core.js.map +1 -0
  179. package/button/internal.d.ts +19 -20
  180. package/button/internal.d.ts.map +1 -1
  181. package/button/internal.js +27 -3
  182. package/button/internal.js.map +1 -1
  183. package/button/styles.css.js +22 -22
  184. package/button/styles.scoped.css +211 -210
  185. package/button/styles.selectors.js +22 -22
  186. package/button-dropdown/analytics-metadata/interfaces.d.ts +26 -27
  187. package/button-dropdown/category-elements/category-element.d.ts +15 -3
  188. package/button-dropdown/category-elements/expandable-category-element.d.ts +16 -3
  189. package/button-dropdown/category-elements/mobile-expandable-category-element.d.ts +15 -3
  190. package/button-dropdown/index.d.ts +1 -2
  191. package/button-dropdown/interfaces.d.ts +256 -257
  192. package/button-dropdown/internal.d.ts +1 -2
  193. package/button-dropdown/item-element/index.d.ts +15 -3
  194. package/button-dropdown/items-list.d.ts +19 -2
  195. package/button-dropdown/mobile-expandable-group/mobile-expandable-group.d.ts +18 -15
  196. package/button-dropdown/tooltip.d.ts +11 -7
  197. package/button-dropdown/utils/create-items-tree.d.ts +5 -6
  198. package/button-dropdown/utils/menu-item.d.ts +5 -6
  199. package/button-dropdown/utils/move-highlight.d.ts +17 -12
  200. package/button-dropdown/utils/use-button-dropdown.d.ts +25 -18
  201. package/button-dropdown/utils/use-highlighted-menu.d.ts +14 -11
  202. package/button-dropdown/utils/utils.d.ts +1 -2
  203. package/button-group/analytics-metadata/interfaces.d.ts +3 -4
  204. package/button-group/file-input-item.d.ts +5 -6
  205. package/button-group/icon-button-item.d.ts +6 -7
  206. package/button-group/icon-toggle-button-item.d.ts +6 -7
  207. package/button-group/index.d.ts +1 -2
  208. package/button-group/interfaces.d.ts +164 -166
  209. package/button-group/internal.d.ts +1 -2
  210. package/button-group/item-element.d.ts +14 -15
  211. package/button-group/menu-dropdown-item.d.ts +7 -8
  212. package/calendar/grid/calendar-grid-header.d.ts +7 -5
  213. package/calendar/grid/index.d.ts +32 -18
  214. package/calendar/grid/use-calendar-grid-keyboard-navigation.d.ts +19 -11
  215. package/calendar/grid/use-calendar-grid-rows.d.ts +11 -7
  216. package/calendar/header/header-button.d.ts +11 -6
  217. package/calendar/header/index.d.ts +13 -8
  218. package/calendar/index.d.ts +6 -2
  219. package/calendar/interfaces.d.ts +97 -98
  220. package/calendar/internal.d.ts +18 -2
  221. package/calendar/use-calendar-labels.d.ts +21 -15
  222. package/calendar/utils/intl.d.ts +1 -2
  223. package/calendar/utils/navigation-day.d.ts +1 -2
  224. package/calendar/utils/navigation-month.d.ts +1 -2
  225. package/cards/cards-layout-helper.d.ts +1 -2
  226. package/cards/index.d.ts +1 -2
  227. package/cards/interfaces.d.ts +228 -229
  228. package/checkbox/analytics-metadata/interfaces.d.ts +11 -12
  229. package/checkbox/base-checkbox.d.ts +51 -52
  230. package/checkbox/index.d.ts +1 -2
  231. package/checkbox/interfaces.d.ts +30 -31
  232. package/checkbox/internal.d.ts +4 -5
  233. package/code-editor/ace-modes.d.ts +329 -330
  234. package/code-editor/ace-themes.d.ts +81 -82
  235. package/code-editor/error-screen.d.ts +9 -6
  236. package/code-editor/index.d.ts +1 -2
  237. package/code-editor/interfaces.d.ts +146 -147
  238. package/code-editor/listeners.d.ts +1 -2
  239. package/code-editor/loading-screen.d.ts +2 -3
  240. package/code-editor/pane.d.ts +27 -15
  241. package/code-editor/preferences-modal.d.ts +20 -21
  242. package/code-editor/resizable-box/index.d.ts +14 -8
  243. package/code-editor/setup-editor.d.ts +1 -2
  244. package/code-editor/status-bar.d.ts +36 -20
  245. package/code-editor/tab-button.d.ts +16 -17
  246. package/code-editor/use-editor.d.ts +20 -13
  247. package/code-editor/util.d.ts +9 -7
  248. package/collection-preferences/analytics-metadata/interfaces.d.ts +33 -34
  249. package/collection-preferences/analytics-metadata/utils.d.ts +3 -4
  250. package/collection-preferences/content-display/content-display-option.d.ts +4 -5
  251. package/collection-preferences/content-display/index.d.ts +18 -5
  252. package/collection-preferences/content-display/utils.d.ts +8 -6
  253. package/collection-preferences/index.d.ts +22 -2
  254. package/collection-preferences/interfaces.d.ts +298 -299
  255. package/collection-preferences/utils.d.ts +70 -30
  256. package/collection-preferences/visible-content.d.ts +9 -5
  257. package/column-layout/flexible-column-layout/index.d.ts +10 -4
  258. package/column-layout/grid-column-layout.d.ts +12 -5
  259. package/column-layout/index.d.ts +7 -2
  260. package/column-layout/interfaces.d.ts +38 -39
  261. package/column-layout/internal.d.ts +12 -2
  262. package/column-layout/util.d.ts +1 -2
  263. package/container/analytics-metadata/interfaces.d.ts +3 -4
  264. package/container/index.d.ts +7 -2
  265. package/container/interfaces.d.ts +82 -83
  266. package/container/internal.d.ts +41 -20
  267. package/container/use-sticky-header.d.ts +24 -19
  268. package/content-layout/index.d.ts +1 -2
  269. package/content-layout/interfaces.d.ts +68 -69
  270. package/content-layout/internal.d.ts +15 -3
  271. package/content-layout/styles.css.js +14 -14
  272. package/content-layout/styles.scoped.css +27 -27
  273. package/content-layout/styles.selectors.js +14 -14
  274. package/contexts/form-field.d.ts +1 -2
  275. package/copy-to-clipboard/index.d.ts +5 -2
  276. package/copy-to-clipboard/interfaces.d.ts +54 -55
  277. package/copy-to-clipboard/internal.d.ts +16 -5
  278. package/date-input/index.d.ts +1 -2
  279. package/date-input/interfaces.d.ts +6 -7
  280. package/date-input/internal.d.ts +2 -3
  281. package/date-input/utils.d.ts +5 -3
  282. package/date-picker/index.d.ts +1 -2
  283. package/date-picker/interfaces.d.ts +79 -80
  284. package/date-picker/utils.d.ts +23 -13
  285. package/date-range-picker/calendar/grids/grid-cell.d.ts +2 -3
  286. package/date-range-picker/calendar/grids/grid.d.ts +22 -2
  287. package/date-range-picker/calendar/grids/index.d.ts +18 -2
  288. package/date-range-picker/calendar/grids/interfaces.d.ts +37 -38
  289. package/date-range-picker/calendar/grids/intl.d.ts +13 -8
  290. package/date-range-picker/calendar/header/header-button.d.ts +11 -6
  291. package/date-range-picker/calendar/header/index.d.ts +18 -10
  292. package/date-range-picker/calendar/index.d.ts +23 -12
  293. package/date-range-picker/calendar/range-inputs.d.ts +26 -14
  294. package/date-range-picker/calendar/utils.d.ts +1 -2
  295. package/date-range-picker/dropdown.d.ts +31 -8
  296. package/date-range-picker/index.d.ts +1 -2
  297. package/date-range-picker/interfaces.d.ts +373 -374
  298. package/date-range-picker/mode-switcher.d.ts +8 -5
  299. package/date-range-picker/relative-range/index.d.ts +18 -10
  300. package/date-range-picker/time-offset.d.ts +9 -10
  301. package/date-range-picker/utils.d.ts +13 -10
  302. package/drawer/implementation.d.ts +11 -3
  303. package/drawer/index.d.ts +1 -2
  304. package/drawer/interfaces.d.ts +33 -34
  305. package/drawer/internal.d.ts +1 -2
  306. package/expandable-section/analytics-metadata/interfaces.d.ts +15 -16
  307. package/expandable-section/expandable-section-container.d.ts +19 -10
  308. package/expandable-section/expandable-section-header.d.ts +41 -23
  309. package/expandable-section/index.d.ts +4 -2
  310. package/expandable-section/interfaces.d.ts +87 -88
  311. package/expandable-section/internal.d.ts +21 -4
  312. package/expandable-section/utils.d.ts +1 -2
  313. package/file-dropzone/index.d.ts +1 -2
  314. package/file-dropzone/interfaces.d.ts +13 -14
  315. package/file-dropzone/internal.d.ts +6 -2
  316. package/file-dropzone/use-files-dragging.d.ts +2 -3
  317. package/file-input/analytics-metadata/interfaces.d.ts +7 -8
  318. package/file-input/index.d.ts +1 -2
  319. package/file-input/interfaces.d.ts +46 -47
  320. package/file-input/internal.d.ts +4 -5
  321. package/file-token-group/default-formatters.d.ts +1 -2
  322. package/file-token-group/file-token.d.ts +39 -25
  323. package/file-token-group/index.d.ts +9 -3
  324. package/file-token-group/interfaces.d.ts +79 -80
  325. package/file-token-group/internal.d.ts +14 -3
  326. package/file-token-group/thumbnail.d.ts +5 -4
  327. package/file-upload/index.d.ts +1 -2
  328. package/file-upload/interfaces.d.ts +101 -102
  329. package/file-upload/internal.d.ts +1 -2
  330. package/flashbar/analytics-metadata/interfaces.d.ts +30 -31
  331. package/flashbar/analytics-metadata/utils.d.ts +2 -3
  332. package/flashbar/collapsible-flashbar.d.ts +4 -2
  333. package/flashbar/common.d.ts +20 -15
  334. package/flashbar/constant.d.ts +1 -2
  335. package/flashbar/flash.d.ts +4 -5
  336. package/flashbar/index.d.ts +1 -2
  337. package/flashbar/interfaces.d.ts +86 -87
  338. package/flashbar/non-collapsible-flashbar.d.ts +5 -2
  339. package/flashbar/styles.css.js +50 -50
  340. package/flashbar/styles.scoped.css +166 -166
  341. package/flashbar/styles.selectors.js +50 -50
  342. package/flashbar/utils.d.ts +6 -7
  343. package/form/analytics-metadata/interfaces.d.ts +7 -8
  344. package/form/index.d.ts +4 -2
  345. package/form/interfaces.d.ts +48 -49
  346. package/form/internal.d.ts +15 -5
  347. package/form-field/analytics-metadata/interfaces.d.ts +3 -4
  348. package/form-field/index.d.ts +4 -2
  349. package/form-field/interfaces.d.ts +91 -92
  350. package/form-field/internal.d.ts +44 -15
  351. package/form-field/util.d.ts +13 -9
  352. package/grid/index.d.ts +6 -2
  353. package/grid/interfaces.d.ts +47 -48
  354. package/grid/internal.d.ts +10 -11
  355. package/header/analytics/use-table-integration.d.ts +1 -2
  356. package/header/index.d.ts +4 -2
  357. package/header/interfaces.d.ts +40 -41
  358. package/header/internal.d.ts +24 -9
  359. package/help-panel/implementation.d.ts +10 -3
  360. package/help-panel/index.d.ts +1 -2
  361. package/help-panel/interfaces.d.ts +27 -28
  362. package/help-panel/internal.d.ts +1 -2
  363. package/hotspot/index.d.ts +7 -2
  364. package/hotspot/interfaces.d.ts +31 -32
  365. package/i18n/context.d.ts +9 -10
  366. package/i18n/dynamic.d.ts +1 -2
  367. package/i18n/get-matchable-locales.d.ts +1 -2
  368. package/i18n/index.d.ts +1 -2
  369. package/i18n/messages/all.all.d.ts +1 -1
  370. package/i18n/messages/all.ar.d.ts +1 -1
  371. package/i18n/messages/all.de.d.ts +1 -1
  372. package/i18n/messages/all.en-GB.d.ts +1 -1
  373. package/i18n/messages/all.en.d.ts +1 -1
  374. package/i18n/messages/all.es.d.ts +1 -1
  375. package/i18n/messages/all.fr.d.ts +1 -1
  376. package/i18n/messages/all.id.d.ts +1 -1
  377. package/i18n/messages/all.it.d.ts +1 -1
  378. package/i18n/messages/all.ja.d.ts +1 -1
  379. package/i18n/messages/all.ko.d.ts +1 -1
  380. package/i18n/messages/all.pt-BR.d.ts +1 -1
  381. package/i18n/messages/all.th.d.ts +1 -1
  382. package/i18n/messages/all.tr.d.ts +1 -1
  383. package/i18n/messages/all.zh-CN.d.ts +1 -1
  384. package/i18n/messages/all.zh-TW.d.ts +1 -1
  385. package/i18n/messages-types.d.ts +558 -559
  386. package/i18n/provider.d.ts +16 -13
  387. package/i18n/testing.d.ts +9 -6
  388. package/icon/generated/icons.d.ts +128 -129
  389. package/icon/index.d.ts +5 -2
  390. package/icon/interfaces.d.ts +62 -63
  391. package/icon/internal.d.ts +14 -4
  392. package/index.d.ts +1 -2
  393. package/input/analytics-metadata/interfaces.d.ts +5 -6
  394. package/input/index.d.ts +1 -2
  395. package/input/interfaces.d.ts +136 -137
  396. package/input/internal.d.ts +14 -15
  397. package/input/utils.d.ts +1 -2
  398. package/interfaces.d.ts +1 -2
  399. package/internal/analytics/components/analytics-funnel.d.ts +26 -23
  400. package/internal/analytics/context/analytics-context.d.ts +51 -52
  401. package/internal/analytics/hooks/use-funnel.d.ts +13 -14
  402. package/internal/analytics/index.d.ts +1 -2
  403. package/internal/analytics/interfaces.d.ts +98 -99
  404. package/internal/analytics/selectors.d.ts +1 -2
  405. package/internal/analytics/utils/parse-count-text.d.ts +1 -2
  406. package/internal/animate.d.ts +14 -10
  407. package/internal/base-component/index.d.ts +15 -16
  408. package/internal/breakpoints.d.ts +1 -2
  409. package/internal/components/abstract-switch/index.d.ts +36 -18
  410. package/internal/components/autosuggest-input/index.d.ts +19 -20
  411. package/internal/components/button-trigger/analytics-metadata/interfaces.d.ts +9 -10
  412. package/internal/components/button-trigger/index.d.ts +27 -28
  413. package/internal/components/cartesian-chart/axis-label.d.ts +8 -5
  414. package/internal/components/cartesian-chart/block-end-labels.d.ts +35 -20
  415. package/internal/components/cartesian-chart/chart-container.d.ts +9 -10
  416. package/internal/components/cartesian-chart/constants.d.ts +1 -2
  417. package/internal/components/cartesian-chart/emphasized-baseline.d.ts +10 -6
  418. package/internal/components/cartesian-chart/highlighted-point.d.ts +10 -11
  419. package/internal/components/cartesian-chart/inline-start-labels.d.ts +20 -11
  420. package/internal/components/cartesian-chart/interfaces.d.ts +196 -197
  421. package/internal/components/cartesian-chart/label-utils.d.ts +16 -12
  422. package/internal/components/cartesian-chart/labels-measure.d.ts +12 -7
  423. package/internal/components/cartesian-chart/scales.d.ts +31 -32
  424. package/internal/components/cartesian-chart/ticks.d.ts +1 -2
  425. package/internal/components/cartesian-chart/vertical-grid-lines.d.ts +9 -6
  426. package/internal/components/cartesian-chart/vertical-marker.d.ts +9 -10
  427. package/internal/components/chart-filter/index.d.ts +17 -12
  428. package/internal/components/chart-legend/index.d.ts +17 -11
  429. package/internal/components/chart-plot/application-controller.d.ts +7 -8
  430. package/internal/components/chart-plot/focus-outline.d.ts +9 -6
  431. package/internal/components/chart-plot/index.d.ts +30 -31
  432. package/internal/components/chart-plot/interfaces.d.ts +3 -4
  433. package/internal/components/chart-popover/index.d.ts +30 -31
  434. package/internal/components/chart-series-details/index.d.ts +13 -14
  435. package/internal/components/chart-series-details/series-details-text.d.ts +1 -2
  436. package/internal/components/chart-series-marker/index.d.ts +6 -4
  437. package/internal/components/chart-status-container/index.d.ts +34 -20
  438. package/internal/components/chart-wrapper/index.d.ts +12 -13
  439. package/internal/components/checkbox-icon/index.d.ts +12 -7
  440. package/internal/components/drag-handle/button.d.ts +1 -2
  441. package/internal/components/drag-handle/hooks/interfaces.d.ts +36 -37
  442. package/internal/components/drag-handle/hooks/use-drag-handle-interaction-state.d.ts +10 -11
  443. package/internal/components/drag-handle/index.d.ts +1 -2
  444. package/internal/components/drag-handle/interfaces.d.ts +34 -35
  445. package/internal/components/drag-handle/resize-icon.d.ts +5 -4
  446. package/internal/components/drag-handle-wrapper/direction-button.d.ts +11 -7
  447. package/internal/components/drag-handle-wrapper/index.d.ts +10 -2
  448. package/internal/components/drag-handle-wrapper/interfaces.d.ts +9 -10
  449. package/internal/components/drag-handle-wrapper/portal-overlay.d.ts +9 -6
  450. package/internal/components/drag-handle-wrapper/styles.css.js +21 -21
  451. package/internal/components/drag-handle-wrapper/styles.scoped.css +44 -44
  452. package/internal/components/drag-handle-wrapper/styles.selectors.js +21 -21
  453. package/internal/components/dropdown/context.d.ts +8 -6
  454. package/internal/components/dropdown/dropdown-fit-handler.d.ts +44 -27
  455. package/internal/components/dropdown/dropdown-position.d.ts +17 -13
  456. package/internal/components/dropdown/index.d.ts +29 -3
  457. package/internal/components/dropdown/interfaces.d.ts +146 -147
  458. package/internal/components/dropdown/styles.css.js +20 -20
  459. package/internal/components/dropdown/styles.scoped.css +38 -38
  460. package/internal/components/dropdown/styles.selectors.js +20 -20
  461. package/internal/components/dropdown-footer/index.d.ts +4 -5
  462. package/internal/components/dropdown-status/index.d.ts +40 -25
  463. package/internal/components/dropdown-status/interfaces.d.ts +38 -39
  464. package/internal/components/focus-lock/index.d.ts +10 -11
  465. package/internal/components/focus-lock/utils.d.ts +1 -2
  466. package/internal/components/interfaces.d.ts +3 -4
  467. package/internal/components/masked-input/index.d.ts +1 -2
  468. package/internal/components/masked-input/interfaces.d.ts +20 -21
  469. package/internal/components/masked-input/keyboard-handler.d.ts +3 -4
  470. package/internal/components/masked-input/use-mask.d.ts +26 -17
  471. package/internal/components/masked-input/utils/keys.d.ts +1 -2
  472. package/internal/components/masked-input/utils/mask-format.d.ts +42 -39
  473. package/internal/components/masked-input/utils/strings.d.ts +1 -2
  474. package/internal/components/menu-dropdown/index.d.ts +11 -3
  475. package/internal/components/menu-dropdown/interfaces.d.ts +20 -21
  476. package/internal/components/option/highlight-match.d.ts +7 -5
  477. package/internal/components/option/index.d.ts +11 -3
  478. package/internal/components/option/interfaces.d.ts +29 -30
  479. package/internal/components/option/option-announcer.d.ts +9 -6
  480. package/internal/components/option/option-parts.d.ts +55 -29
  481. package/internal/components/option/utils/filter-options.d.ts +1 -2
  482. package/internal/components/option/utils/flatten-options.d.ts +3 -4
  483. package/internal/components/option/utils/prepare-options.d.ts +6 -7
  484. package/internal/components/options-list/index.d.ts +27 -28
  485. package/internal/components/options-list/utils/test-indexes.d.ts +5 -6
  486. package/internal/components/options-list/utils/use-highlight-option.d.ts +19 -18
  487. package/internal/components/options-list/utils/use-highlight-option.d.ts.map +1 -1
  488. package/internal/components/options-list/utils/use-highlight-option.js +0 -1
  489. package/internal/components/options-list/utils/use-highlight-option.js.map +1 -1
  490. package/internal/components/options-list/utils/use-ids.d.ts +1 -2
  491. package/internal/components/options-list/utils/use-keyboard.d.ts +14 -15
  492. package/internal/components/options-list/utils/use-open-state.d.ts +14 -11
  493. package/internal/components/panel-resize-handle/index.d.ts +9 -10
  494. package/internal/components/responsive-text/index.d.ts +13 -8
  495. package/internal/components/responsive-text/responsive-text-utils.d.ts +1 -2
  496. package/internal/components/screenreader-only/index.d.ts +4 -5
  497. package/internal/components/selectable-item/analytics-metadata/interfaces.d.ts +8 -9
  498. package/internal/components/selectable-item/analytics-metadata/utils.d.ts +5 -2
  499. package/internal/components/selectable-item/index.d.ts +1 -2
  500. package/internal/components/selectable-item/interfaces.d.ts +30 -31
  501. package/internal/components/sortable-area/index.d.ts +9 -3
  502. package/internal/components/sortable-area/interfaces.d.ts +35 -36
  503. package/internal/components/sortable-area/keyboard-sensor/defaults.d.ts +1 -2
  504. package/internal/components/sortable-area/keyboard-sensor/index.d.ts +15 -16
  505. package/internal/components/sortable-area/keyboard-sensor/utilities/events.d.ts +5 -6
  506. package/internal/components/sortable-area/keyboard-sensor/utilities/listeners.d.ts +6 -7
  507. package/internal/components/sortable-area/keyboard-sensor/utilities/scroll.d.ts +11 -7
  508. package/internal/components/sortable-area/use-drag-and-drop-reorder.d.ts +13 -11
  509. package/internal/components/sortable-area/use-live-announcements.d.ts +25 -10
  510. package/internal/components/tab-trap/index.d.ts +7 -5
  511. package/internal/components/token-list/analytics-metadata/interfaces.d.ts +9 -10
  512. package/internal/components/token-list/index.d.ts +11 -2
  513. package/internal/components/token-list/interfaces.d.ts +12 -13
  514. package/internal/components/token-list/token-limit-toggle.d.ts +19 -11
  515. package/internal/components/tooltip/index.d.ts +20 -11
  516. package/internal/components/transition/index.d.ts +18 -11
  517. package/internal/components/visual-context/index.d.ts +9 -6
  518. package/internal/context/button-context.d.ts +6 -5
  519. package/internal/context/collection-label-context.d.ts +2 -3
  520. package/internal/context/collection-preferences-metadata-context.d.ts +5 -6
  521. package/internal/context/container-header.d.ts +5 -4
  522. package/internal/context/dynamic-overlap-context.d.ts +1 -2
  523. package/internal/context/form-field-context.d.ts +49 -50
  524. package/internal/context/info-link-label-context.d.ts +1 -2
  525. package/internal/context/link-default-variant-context.d.ts +3 -4
  526. package/internal/context/modal-context.d.ts +4 -5
  527. package/internal/context/reset-contexts-for-modal.d.ts +5 -4
  528. package/internal/context/single-tab-stop-navigation-context.d.ts +17 -18
  529. package/internal/context/split-panel-context.d.ts +27 -28
  530. package/internal/context/table-component-context.d.ts +15 -16
  531. package/internal/debounce.d.ts +1 -2
  532. package/internal/do-not-use/chart-filter.d.ts +1 -2
  533. package/internal/do-not-use/chart-tooltip.d.ts +1 -2
  534. package/internal/do-not-use/drag-handle.d.ts +1 -2
  535. package/internal/do-not-use/expandable-section.d.ts +1 -2
  536. package/internal/do-not-use/i18n.d.ts +1 -2
  537. package/internal/do-not-use/tooltip.d.ts +1 -2
  538. package/internal/environment.js +1 -1
  539. package/internal/environment.json +1 -1
  540. package/internal/events/index.d.ts +20 -18
  541. package/internal/focus-tracker.d.ts +18 -16
  542. package/internal/generated/custom-css-properties/index.d.ts +76 -61
  543. package/internal/generated/custom-css-properties/index.d.ts.map +1 -1
  544. package/internal/generated/custom-css-properties/index.js +75 -59
  545. package/internal/generated/custom-css-properties/index.js.map +1 -1
  546. package/internal/generated/theming/index.cjs.d.ts +12 -13
  547. package/internal/generated/theming/index.d.ts +12 -13
  548. package/internal/hooks/check-controlled/index.d.ts +1 -2
  549. package/internal/hooks/container-queries/index.d.ts +1 -2
  550. package/internal/hooks/container-queries/use-container-breakpoints.d.ts +1 -2
  551. package/internal/hooks/container-queries/use-height-measure.d.ts +1 -2
  552. package/internal/hooks/forward-focus/index.d.ts +3 -4
  553. package/internal/hooks/forward-focus/radio-group.d.ts +3 -4
  554. package/internal/hooks/use-base-component/index.d.ts +3 -4
  555. package/internal/hooks/use-controllable/index.d.ts +9 -6
  556. package/internal/hooks/use-date-cache/index.d.ts +1 -2
  557. package/internal/hooks/use-debounce-callback/index.d.ts +1 -2
  558. package/internal/hooks/use-dom-attribute/index.d.ts +2 -3
  559. package/internal/hooks/use-dynamic-overlap/index.d.ts +5 -6
  560. package/internal/hooks/use-effect-on-update.d.ts +1 -2
  561. package/internal/hooks/use-focus-tracker.d.ts +6 -7
  562. package/internal/hooks/use-has-rendered/index.d.ts +1 -2
  563. package/internal/hooks/use-hidden-description/index.d.ts +6 -7
  564. package/internal/hooks/use-intersection-observer/index.d.ts +7 -6
  565. package/internal/hooks/use-list-focus-controller.d.ts +13 -8
  566. package/internal/hooks/use-mobile/index.d.ts +1 -2
  567. package/internal/hooks/use-modal-component-analytics/index.d.ts +1 -2
  568. package/internal/hooks/use-mouse-down-target.d.ts +1 -2
  569. package/internal/hooks/use-performance-marks/index.d.ts +2 -3
  570. package/internal/hooks/use-performance-marks/is-in-viewport.d.ts +1 -2
  571. package/internal/hooks/use-portal-mode-classes/index.d.ts +1 -2
  572. package/internal/hooks/use-previous/index.d.ts +1 -2
  573. package/internal/hooks/use-scroll-sync/index.d.ts +1 -2
  574. package/internal/hooks/use-table-interaction-metrics/index.d.ts +23 -15
  575. package/internal/hooks/use-virtual/index.d.ts +14 -10
  576. package/internal/hooks/use-virtual/sticky-range-extractor.d.ts +5 -6
  577. package/internal/hooks/use-visual-mode/index.d.ts +1 -2
  578. package/internal/is-development.d.ts +1 -2
  579. package/internal/keycode.d.ts +14 -15
  580. package/internal/manifest.json +1 -1
  581. package/internal/metrics.d.ts +1 -2
  582. package/internal/plugins/api.d.ts +20 -21
  583. package/internal/plugins/controllers/action-buttons.d.ts +20 -21
  584. package/internal/plugins/controllers/alert-flash-content.d.ts +36 -37
  585. package/internal/plugins/controllers/app-layout-widget.d.ts +19 -20
  586. package/internal/plugins/controllers/breadcrumbs.d.ts +23 -24
  587. package/internal/plugins/controllers/drawers.d.ts +63 -61
  588. package/internal/plugins/controllers/shared-react-contexts.d.ts +5 -6
  589. package/internal/plugins/helpers/index.d.ts +1 -2
  590. package/internal/plugins/helpers/metrics.d.ts +1 -2
  591. package/internal/plugins/helpers/use-discovered-action.d.ts +4 -5
  592. package/internal/plugins/helpers/use-discovered-content.d.ts +16 -13
  593. package/internal/plugins/helpers/use-global-breadcrumbs.d.ts +1 -2
  594. package/internal/plugins/helpers/utils.d.ts +3 -4
  595. package/internal/plugins/index.d.ts +1 -2
  596. package/internal/styles/colors.d.ts +1 -2
  597. package/internal/styles/global-vars.d.ts +3 -4
  598. package/internal/styles/motion/utils.d.ts +1 -2
  599. package/internal/tooltip-do-not-use/index.d.ts +1 -2
  600. package/internal/types.d.ts +2 -5
  601. package/internal/utils/apply-display-name.d.ts +1 -2
  602. package/internal/utils/browser-scrollbar-size.d.ts +3 -4
  603. package/internal/utils/calculate-once.d.ts +1 -2
  604. package/internal/utils/check-safe-url.d.ts +1 -2
  605. package/internal/utils/circle-index.d.ts +1 -2
  606. package/internal/utils/content-header-utils.d.ts +1 -2
  607. package/internal/utils/create-category-color-scale.d.ts +1 -2
  608. package/internal/utils/date-time/calendar.d.ts +44 -34
  609. package/internal/utils/date-time/display-format.d.ts +1 -2
  610. package/internal/utils/date-time/format-date-iso.d.ts +13 -8
  611. package/internal/utils/date-time/format-date-localized.d.ts +15 -9
  612. package/internal/utils/date-time/format-date-time-with-offset.d.ts +13 -8
  613. package/internal/utils/date-time/format-date-time.d.ts +1 -2
  614. package/internal/utils/date-time/format-date.d.ts +1 -2
  615. package/internal/utils/date-time/format-time-offset.d.ts +1 -2
  616. package/internal/utils/date-time/format-time.d.ts +1 -2
  617. package/internal/utils/date-time/index.d.ts +1 -2
  618. package/internal/utils/date-time/is-iso-only.d.ts +1 -2
  619. package/internal/utils/date-time/join-date-time.d.ts +3 -4
  620. package/internal/utils/date-time/parse-date.d.ts +1 -2
  621. package/internal/utils/date-time/parse-timezone-offset.d.ts +1 -2
  622. package/internal/utils/date-time/shift-timezone-offset.d.ts +1 -2
  623. package/internal/utils/dom.d.ts +7 -5
  624. package/internal/utils/external-props.d.ts +1 -2
  625. package/internal/utils/get-visual-theme.d.ts +1 -2
  626. package/internal/utils/handle-key.d.ts +27 -16
  627. package/internal/utils/has-value.d.ts +1 -2
  628. package/internal/utils/locale/index.d.ts +1 -2
  629. package/internal/utils/locale/merge-locales.d.ts +1 -2
  630. package/internal/utils/locale/normalize-locale.d.ts +1 -2
  631. package/internal/utils/locale/normalize-start-of-week.d.ts +1 -2
  632. package/internal/utils/node-belongs.d.ts +1 -2
  633. package/internal/utils/pointer-events-mock.d.ts +3 -4
  634. package/internal/utils/promises.d.ts +5 -7
  635. package/internal/utils/scrollable-containers.d.ts +19 -12
  636. package/internal/utils/strings/index.d.ts +1 -2
  637. package/internal/utils/strings/join-strings.d.ts +1 -2
  638. package/internal/utils/strings/pad-left-zeros.d.ts +1 -2
  639. package/internal/utils/throttle.d.ts +7 -6
  640. package/internal/utils/use-container-width.d.ts +1 -2
  641. package/internal/widget-exports.d.ts +3 -4
  642. package/internal/widgets/index.d.ts +1 -2
  643. package/key-value-pairs/index.d.ts +8 -2
  644. package/key-value-pairs/interfaces.d.ts +55 -56
  645. package/key-value-pairs/internal.d.ts +1 -2
  646. package/line-chart/index.d.ts +11 -3
  647. package/line-chart/interfaces.d.ts +13 -14
  648. package/link/analytics-metadata/interfaces.d.ts +13 -14
  649. package/link/index.d.ts +1 -2
  650. package/link/interfaces.d.ts +96 -97
  651. package/link/internal.d.ts +2 -3
  652. package/live-region/controller.d.ts +28 -26
  653. package/live-region/index.d.ts +7 -3
  654. package/live-region/interfaces.d.ts +22 -23
  655. package/live-region/internal.d.ts +22 -23
  656. package/mixed-line-bar-chart/bar-groups.d.ts +15 -9
  657. package/mixed-line-bar-chart/bar-series.d.ts +31 -17
  658. package/mixed-line-bar-chart/chart-container.d.ts +59 -31
  659. package/mixed-line-bar-chart/chart-legend.d.ts +17 -10
  660. package/mixed-line-bar-chart/chart-popover.d.ts +14 -15
  661. package/mixed-line-bar-chart/create-one-side-rounded-rect-path.d.ts +11 -7
  662. package/mixed-line-bar-chart/data-series.d.ts +25 -14
  663. package/mixed-line-bar-chart/domain.d.ts +1 -2
  664. package/mixed-line-bar-chart/format-highlighted.d.ts +13 -9
  665. package/mixed-line-bar-chart/hooks/use-mouse-hover.d.ts +26 -16
  666. package/mixed-line-bar-chart/hooks/use-navigation.d.ts +41 -23
  667. package/mixed-line-bar-chart/hooks/use-popover.d.ts +6 -7
  668. package/mixed-line-bar-chart/index.d.ts +13 -3
  669. package/mixed-line-bar-chart/interfaces.d.ts +106 -107
  670. package/mixed-line-bar-chart/internal.d.ts +41 -3
  671. package/mixed-line-bar-chart/line-series.d.ts +15 -9
  672. package/mixed-line-bar-chart/make-scaled-bar-groups.d.ts +10 -11
  673. package/mixed-line-bar-chart/make-scaled-series.d.ts +6 -7
  674. package/mixed-line-bar-chart/utils.d.ts +3 -4
  675. package/modal/analytics-metadata/interfaces.d.ts +7 -8
  676. package/modal/body-scroll.d.ts +1 -2
  677. package/modal/index.d.ts +4 -2
  678. package/modal/interfaces.d.ts +74 -75
  679. package/modal/internal.d.ts +14 -10
  680. package/multiselect/analytics-metadata/interfaces.d.ts +7 -8
  681. package/multiselect/embedded.d.ts +7 -8
  682. package/multiselect/index.d.ts +1 -2
  683. package/multiselect/interfaces.d.ts +80 -81
  684. package/multiselect/internal.d.ts +7 -8
  685. package/multiselect/use-multiselect.d.ts +87 -59
  686. package/package.json +1 -1
  687. package/pagination/analytics-metadata/interfaces.d.ts +13 -14
  688. package/pagination/index.d.ts +1 -2
  689. package/pagination/interfaces.d.ts +72 -73
  690. package/pagination/internal.d.ts +13 -3
  691. package/pagination/utils.d.ts +5 -6
  692. package/pie-chart/index.d.ts +21 -3
  693. package/pie-chart/interfaces.d.ts +221 -222
  694. package/pie-chart/labels.d.ts +19 -11
  695. package/pie-chart/pie-chart.d.ts +35 -13
  696. package/pie-chart/responsive-text.d.ts +17 -11
  697. package/pie-chart/segments.d.ts +23 -13
  698. package/pie-chart/utils.d.ts +22 -19
  699. package/popover/arrow.d.ts +2 -3
  700. package/popover/body.d.ts +22 -12
  701. package/popover/container.d.ts +48 -31
  702. package/popover/index.d.ts +1 -2
  703. package/popover/interfaces.d.ts +80 -81
  704. package/popover/internal.d.ts +8 -9
  705. package/popover/use-popover-position.d.ts +32 -20
  706. package/popover/utils/positions.d.ts +30 -20
  707. package/progress-bar/index.d.ts +15 -2
  708. package/progress-bar/interfaces.d.ts +70 -71
  709. package/progress-bar/internal.d.ts +35 -19
  710. package/prompt-input/index.d.ts +1 -2
  711. package/prompt-input/interfaces.d.ts +92 -93
  712. package/prompt-input/internal.d.ts +2 -4
  713. package/property-filter/analytics-metadata/interfaces.d.ts +24 -25
  714. package/property-filter/controller.d.ts +45 -41
  715. package/property-filter/filter-options.d.ts +1 -2
  716. package/property-filter/filtering-token/index.d.ts +27 -28
  717. package/property-filter/i18n-utils.d.ts +14 -15
  718. package/property-filter/index.d.ts +1 -2
  719. package/property-filter/interfaces.d.ts +325 -326
  720. package/property-filter/internal.d.ts +7 -8
  721. package/property-filter/property-editor.d.ts +45 -24
  722. package/property-filter/property-filter-autosuggest.d.ts +10 -11
  723. package/property-filter/token-editor-inputs.d.ts +41 -26
  724. package/property-filter/token-editor.d.ts +34 -18
  725. package/property-filter/token.d.ts +39 -21
  726. package/property-filter/use-load-items.d.ts +4 -5
  727. package/property-filter/utils.d.ts +9 -6
  728. package/radio-group/analytics-metadata/interfaces.d.ts +9 -10
  729. package/radio-group/index.d.ts +1 -2
  730. package/radio-group/interfaces.d.ts +64 -65
  731. package/radio-group/internal.d.ts +1 -2
  732. package/radio-group/radio-button.d.ts +6 -7
  733. package/s3-resource-selector/index.d.ts +1 -2
  734. package/s3-resource-selector/interfaces.d.ts +231 -232
  735. package/s3-resource-selector/s3-in-context/index.d.ts +12 -13
  736. package/s3-resource-selector/s3-in-context/search-input.d.ts +1 -2
  737. package/s3-resource-selector/s3-in-context/use-versions-fetch.d.ts +9 -10
  738. package/s3-resource-selector/s3-in-context/validation.d.ts +1 -2
  739. package/s3-resource-selector/s3-modal/basic-table.d.ts +35 -26
  740. package/s3-resource-selector/s3-modal/buckets-table.d.ts +21 -12
  741. package/s3-resource-selector/s3-modal/column-formats.d.ts +1 -2
  742. package/s3-resource-selector/s3-modal/empty-state.d.ts +9 -6
  743. package/s3-resource-selector/s3-modal/index.d.ts +34 -18
  744. package/s3-resource-selector/s3-modal/objects-table.d.ts +23 -13
  745. package/s3-resource-selector/s3-modal/table-utils.d.ts +4 -2
  746. package/s3-resource-selector/s3-modal/versions-table.d.ts +19 -11
  747. package/s3-resource-selector/utils.d.ts +1 -2
  748. package/segmented-control/index.d.ts +1 -2
  749. package/segmented-control/interfaces.d.ts +46 -47
  750. package/segmented-control/internal-segmented-control.d.ts +7 -2
  751. package/segmented-control/internal.d.ts +10 -3
  752. package/segmented-control/segment.d.ts +5 -6
  753. package/select/analytics-metadata/interfaces.d.ts +6 -7
  754. package/select/index.d.ts +1 -2
  755. package/select/interfaces.d.ts +182 -183
  756. package/select/internal.d.ts +2 -3
  757. package/select/parts/common.d.ts +1 -2
  758. package/select/parts/filter.d.ts +3 -4
  759. package/select/parts/item.d.ts +15 -16
  760. package/select/parts/multiselect-item.d.ts +2 -3
  761. package/select/parts/plain-list.d.ts +13 -14
  762. package/select/parts/trigger.d.ts +11 -12
  763. package/select/parts/virtual-list.d.ts +1 -2
  764. package/select/utils/check-option-value-field.d.ts +1 -2
  765. package/select/utils/connect-options.d.ts +1 -2
  766. package/select/utils/get-item-props.d.ts +13 -8
  767. package/select/utils/render-options.d.ts +29 -16
  768. package/select/utils/scroll-to-index.d.ts +7 -5
  769. package/select/utils/use-announcement.d.ts +16 -10
  770. package/select/utils/use-load-items.d.ts +12 -9
  771. package/select/utils/use-native-search.d.ts +13 -8
  772. package/select/utils/use-select.d.ts +50 -34
  773. package/select/utils/use-select.d.ts.map +1 -1
  774. package/select/utils/use-select.js +4 -17
  775. package/select/utils/use-select.js.map +1 -1
  776. package/side-navigation/analytics-metadata/interfaces.d.ts +13 -14
  777. package/side-navigation/implementation.d.ts +11 -3
  778. package/side-navigation/index.d.ts +4 -2
  779. package/side-navigation/interfaces.d.ts +171 -172
  780. package/side-navigation/internal.d.ts +1 -2
  781. package/side-navigation/parts.d.ts +21 -11
  782. package/side-navigation/util.d.ts +1 -2
  783. package/slider/index.d.ts +5 -2
  784. package/slider/interfaces.d.ts +74 -75
  785. package/slider/internal.d.ts +20 -5
  786. package/slider/slider-labels.d.ts +15 -9
  787. package/slider/styles.css.js +26 -26
  788. package/slider/styles.scoped.css +86 -86
  789. package/slider/styles.selectors.js +26 -26
  790. package/slider/tick-marks.d.ts +11 -12
  791. package/slider/utils.d.ts +3 -4
  792. package/space-between/index.d.ts +4 -2
  793. package/space-between/interfaces.d.ts +20 -21
  794. package/space-between/internal.d.ts +1 -2
  795. package/spinner/index.d.ts +5 -2
  796. package/spinner/interfaces.d.ts +11 -12
  797. package/spinner/internal.d.ts +8 -5
  798. package/spinner/styles.css.js +13 -13
  799. package/spinner/styles.scoped.css +39 -39
  800. package/spinner/styles.selectors.js +13 -13
  801. package/split-panel/bottom.d.ts +16 -5
  802. package/split-panel/icons/bottom-icon-refresh.d.ts +1 -2
  803. package/split-panel/icons/bottom-icon.d.ts +1 -2
  804. package/split-panel/icons/side-position-refresh.d.ts +4 -5
  805. package/split-panel/icons/side-position.d.ts +1 -2
  806. package/split-panel/implementation.d.ts +10 -3
  807. package/split-panel/index.d.ts +6 -2
  808. package/split-panel/interfaces.d.ts +53 -54
  809. package/split-panel/internal.d.ts +1 -2
  810. package/split-panel/preferences-modal.d.ts +20 -21
  811. package/split-panel/side.d.ts +19 -6
  812. package/split-panel/utils/size-utils.d.ts +1 -2
  813. package/status-indicator/index.d.ts +5 -2
  814. package/status-indicator/internal.d.ts +48 -38
  815. package/steps/index.d.ts +5 -3
  816. package/steps/interfaces.d.ts +33 -34
  817. package/steps/internal.d.ts +9 -3
  818. package/table/analytics-metadata/interfaces.d.ts +44 -45
  819. package/table/body-cell/click-away.d.ts +1 -2
  820. package/table/body-cell/disabled-inline-editor.d.ts +12 -4
  821. package/table/body-cell/index.d.ts +8 -9
  822. package/table/body-cell/inline-editor.d.ts +17 -11
  823. package/table/body-cell/td-element.d.ts +35 -36
  824. package/table/column-widths-utils.d.ts +4 -5
  825. package/table/expandable-rows/expand-toggle-button.d.ts +11 -7
  826. package/table/expandable-rows/expandable-rows-utils.d.ts +24 -20
  827. package/table/header-cell/index.d.ts +54 -28
  828. package/table/header-cell/th-element.d.ts +37 -19
  829. package/table/header-cell/utils.d.ts +1 -2
  830. package/table/index.d.ts +1 -2
  831. package/table/interfaces.d.ts +514 -515
  832. package/table/internal.d.ts +1 -2
  833. package/table/no-data-cell.d.ts +17 -10
  834. package/table/progressive-loading/items-loader.d.ts +22 -12
  835. package/table/progressive-loading/loader-cell.d.ts +7 -4
  836. package/table/progressive-loading/progressive-loading-utils.d.ts +15 -12
  837. package/table/resizer/index.d.ts +23 -13
  838. package/table/resizer/resizer-lookup.d.ts +5 -6
  839. package/table/selection/index.d.ts +1 -2
  840. package/table/selection/interfaces.d.ts +10 -11
  841. package/table/selection/selection-cell.d.ts +17 -9
  842. package/table/selection/selection-control.d.ts +23 -11
  843. package/table/selection/use-selection-focus-move.d.ts +7 -8
  844. package/table/selection/use-selection.d.ts +6 -7
  845. package/table/selection/utils.d.ts +16 -17
  846. package/table/sticky-columns/index.d.ts +1 -2
  847. package/table/sticky-columns/interfaces.d.ts +21 -22
  848. package/table/sticky-columns/use-sticky-columns.d.ts +26 -19
  849. package/table/sticky-columns/utils.d.ts +1 -2
  850. package/table/sticky-header.d.ts +14 -15
  851. package/table/sticky-scrollbar/index.d.ts +1 -2
  852. package/table/sticky-scrollbar/sticky-scrollbar.d.ts +5 -6
  853. package/table/sticky-scrollbar/use-sticky-scrollbar.d.ts +1 -2
  854. package/table/sticky-scrolling.d.ts +3 -4
  855. package/table/table-role/grid-navigation.d.ts +6 -2
  856. package/table/table-role/index.d.ts +2 -3
  857. package/table/table-role/interfaces.d.ts +9 -10
  858. package/table/table-role/table-role-helper.d.ts +23 -24
  859. package/table/table-role/utils.d.ts +1 -2
  860. package/table/thead.d.ts +26 -27
  861. package/table/tools-header.d.ts +13 -8
  862. package/table/use-cell-editing.d.ts +22 -14
  863. package/table/use-column-widths.d.ts +16 -12
  864. package/table/use-prevent-sticky-click-scroll.d.ts +1 -2
  865. package/table/use-row-events.d.ts +7 -5
  866. package/table/use-sticky-header.d.ts +3 -4
  867. package/table/use-table-focus-navigation.d.ts +14 -9
  868. package/table/utils.d.ts +10 -7
  869. package/tabs/analytics-metadata/interfaces.d.ts +27 -28
  870. package/tabs/index.d.ts +14 -2
  871. package/tabs/interfaces.d.ts +154 -155
  872. package/tabs/native-smooth-scroll-supported.d.ts +1 -2
  873. package/tabs/scroll-utils.d.ts +1 -2
  874. package/tabs/smooth-scroll.d.ts +1 -2
  875. package/tabs/tab-header-bar.d.ts +29 -16
  876. package/tag-editor/index.d.ts +1 -2
  877. package/tag-editor/interfaces.d.ts +112 -113
  878. package/tag-editor/internal.d.ts +20 -21
  879. package/tag-editor/utils.d.ts +3 -4
  880. package/tag-editor/validation.d.ts +3 -4
  881. package/test-utils/dom/alert/index.d.ts +21 -21
  882. package/test-utils/dom/anchor-navigation/index.d.ts +12 -12
  883. package/test-utils/dom/annotation/index.d.ts +9 -9
  884. package/test-utils/dom/app-layout/index.d.ts +32 -32
  885. package/test-utils/dom/app-layout-toolbar/index.d.ts +2 -2
  886. package/test-utils/dom/area-chart/index.d.ts +8 -8
  887. package/test-utils/dom/attribute-editor/index.d.ts +30 -30
  888. package/test-utils/dom/autosuggest/index.d.ts +87 -87
  889. package/test-utils/dom/badge/index.d.ts +2 -2
  890. package/test-utils/dom/bar-chart/index.d.ts +2 -2
  891. package/test-utils/dom/box/index.d.ts +2 -2
  892. package/test-utils/dom/breadcrumb-group/index.d.ts +18 -18
  893. package/test-utils/dom/button/index.d.ts +6 -6
  894. package/test-utils/dom/button-dropdown/index.d.ts +41 -41
  895. package/test-utils/dom/button-group/index.d.ts +26 -26
  896. package/test-utils/dom/calendar/index.d.ts +24 -24
  897. package/test-utils/dom/cards/index.d.ts +31 -31
  898. package/test-utils/dom/checkbox/index.d.ts +6 -6
  899. package/test-utils/dom/code-editor/index.d.ts +17 -17
  900. package/test-utils/dom/collection-preferences/content-display-preference.d.ts +40 -40
  901. package/test-utils/dom/collection-preferences/index.d.ts +16 -16
  902. package/test-utils/dom/collection-preferences/page-size-preference.d.ts +4 -4
  903. package/test-utils/dom/collection-preferences/sticky-columns-preference.d.ts +6 -6
  904. package/test-utils/dom/collection-preferences/visible-content-preference.d.ts +12 -12
  905. package/test-utils/dom/column-layout/index.d.ts +2 -2
  906. package/test-utils/dom/container/index.d.ts +6 -6
  907. package/test-utils/dom/content-layout/index.d.ts +7 -7
  908. package/test-utils/dom/copy-to-clipboard/index.d.ts +15 -15
  909. package/test-utils/dom/date-input/index.d.ts +2 -2
  910. package/test-utils/dom/date-picker/index.d.ts +19 -19
  911. package/test-utils/dom/date-range-picker/index.d.ts +82 -82
  912. package/test-utils/dom/drawer/index.d.ts +5 -5
  913. package/test-utils/dom/expandable-section/index.d.ts +9 -9
  914. package/test-utils/dom/file-dropzone/index.d.ts +3 -3
  915. package/test-utils/dom/file-input/index.d.ts +4 -4
  916. package/test-utils/dom/file-token-group/index.d.ts +17 -17
  917. package/test-utils/dom/file-upload/index.d.ts +18 -18
  918. package/test-utils/dom/flashbar/flash.d.ts +20 -20
  919. package/test-utils/dom/flashbar/index.d.ts +20 -20
  920. package/test-utils/dom/form/index.d.ts +7 -7
  921. package/test-utils/dom/form-field/index.d.ts +10 -10
  922. package/test-utils/dom/grid/index.d.ts +7 -7
  923. package/test-utils/dom/header/index.d.ts +7 -7
  924. package/test-utils/dom/help-panel/index.d.ts +5 -5
  925. package/test-utils/dom/hotspot/index.d.ts +4 -4
  926. package/test-utils/dom/icon/index.d.ts +2 -2
  927. package/test-utils/dom/index.d.ts +1443 -1443
  928. package/test-utils/dom/input/base-input.d.ts +17 -17
  929. package/test-utils/dom/input/index.d.ts +3 -3
  930. package/test-utils/dom/internal/abstract-switch.d.ts +5 -5
  931. package/test-utils/dom/internal/autosuggest-input.d.ts +4 -4
  932. package/test-utils/dom/internal/chart-filter.d.ts +4 -4
  933. package/test-utils/dom/internal/chart-legend.d.ts +6 -6
  934. package/test-utils/dom/internal/chart-popover.d.ts +9 -9
  935. package/test-utils/dom/internal/chart-tooltip.d.ts +6 -6
  936. package/test-utils/dom/internal/charts.d.ts +5 -5
  937. package/test-utils/dom/internal/drag-handle.d.ts +7 -7
  938. package/test-utils/dom/internal/dropdown-host.d.ts +119 -119
  939. package/test-utils/dom/internal/dropdown.d.ts +3 -3
  940. package/test-utils/dom/internal/option.d.ts +7 -7
  941. package/test-utils/dom/internal/options-list.d.ts +2 -2
  942. package/test-utils/dom/internal/tooltip.d.ts +2 -2
  943. package/test-utils/dom/key-value-pairs/index.d.ts +8 -8
  944. package/test-utils/dom/line-chart/index.d.ts +2 -2
  945. package/test-utils/dom/link/index.d.ts +2 -2
  946. package/test-utils/dom/live-region/index.d.ts +2 -2
  947. package/test-utils/dom/mixed-line-bar-chart/index.d.ts +21 -21
  948. package/test-utils/dom/modal/index.d.ts +7 -7
  949. package/test-utils/dom/multiselect/index.d.ts +38 -38
  950. package/test-utils/dom/pagination/index.d.ts +13 -13
  951. package/test-utils/dom/pie-chart/index.d.ts +13 -13
  952. package/test-utils/dom/popover/index.d.ts +24 -24
  953. package/test-utils/dom/progress-bar/index.d.ts +14 -14
  954. package/test-utils/dom/prompt-input/index.d.ts +18 -18
  955. package/test-utils/dom/property-filter/index.d.ts +68 -68
  956. package/test-utils/dom/radio-group/index.d.ts +4 -4
  957. package/test-utils/dom/radio-group/radio-button.d.ts +5 -5
  958. package/test-utils/dom/s3-resource-selector/index.d.ts +11 -11
  959. package/test-utils/dom/segmented-control/index.d.ts +11 -11
  960. package/test-utils/dom/select/index.d.ts +28 -28
  961. package/test-utils/dom/side-navigation/index.d.ts +18 -18
  962. package/test-utils/dom/slider/index.d.ts +3 -3
  963. package/test-utils/dom/space-between/index.d.ts +2 -2
  964. package/test-utils/dom/spinner/index.d.ts +2 -2
  965. package/test-utils/dom/split-panel/index.d.ts +17 -17
  966. package/test-utils/dom/status-indicator/index.d.ts +2 -2
  967. package/test-utils/dom/steps/index.d.ts +14 -14
  968. package/test-utils/dom/table/index.d.ts +91 -91
  969. package/test-utils/dom/tabs/index.d.ts +68 -68
  970. package/test-utils/dom/tag-editor/index.d.ts +17 -17
  971. package/test-utils/dom/text-content/index.d.ts +2 -2
  972. package/test-utils/dom/text-filter/index.d.ts +4 -4
  973. package/test-utils/dom/textarea/index.d.ts +15 -15
  974. package/test-utils/dom/tiles/index.d.ts +5 -5
  975. package/test-utils/dom/tiles/tile.d.ts +7 -7
  976. package/test-utils/dom/time-input/index.d.ts +2 -2
  977. package/test-utils/dom/toggle/index.d.ts +6 -6
  978. package/test-utils/dom/toggle-button/index.d.ts +3 -3
  979. package/test-utils/dom/token-group/index.d.ts +13 -13
  980. package/test-utils/dom/token-group/token.d.ts +5 -5
  981. package/test-utils/dom/top-navigation/1.0-beta/index.d.ts +17 -17
  982. package/test-utils/dom/top-navigation/index.d.ts +23 -23
  983. package/test-utils/dom/tutorial-panel/index.d.ts +12 -12
  984. package/test-utils/dom/tutorial-panel/tutorial.d.ts +10 -10
  985. package/test-utils/dom/wizard/index.d.ts +22 -22
  986. package/test-utils/selectors/alert/index.d.ts +21 -21
  987. package/test-utils/selectors/anchor-navigation/index.d.ts +11 -11
  988. package/test-utils/selectors/annotation/index.d.ts +9 -9
  989. package/test-utils/selectors/app-layout/index.d.ts +32 -32
  990. package/test-utils/selectors/app-layout-toolbar/index.d.ts +2 -2
  991. package/test-utils/selectors/area-chart/index.d.ts +8 -8
  992. package/test-utils/selectors/attribute-editor/index.d.ts +30 -30
  993. package/test-utils/selectors/autosuggest/index.d.ts +67 -67
  994. package/test-utils/selectors/badge/index.d.ts +2 -2
  995. package/test-utils/selectors/bar-chart/index.d.ts +2 -2
  996. package/test-utils/selectors/box/index.d.ts +2 -2
  997. package/test-utils/selectors/breadcrumb-group/index.d.ts +18 -18
  998. package/test-utils/selectors/button/index.d.ts +5 -5
  999. package/test-utils/selectors/button-dropdown/index.d.ts +39 -39
  1000. package/test-utils/selectors/button-group/index.d.ts +26 -26
  1001. package/test-utils/selectors/calendar/index.d.ts +24 -24
  1002. package/test-utils/selectors/cards/index.d.ts +31 -31
  1003. package/test-utils/selectors/checkbox/index.d.ts +6 -6
  1004. package/test-utils/selectors/code-editor/index.d.ts +11 -11
  1005. package/test-utils/selectors/collection-preferences/content-display-preference.d.ts +40 -40
  1006. package/test-utils/selectors/collection-preferences/index.d.ts +16 -16
  1007. package/test-utils/selectors/collection-preferences/page-size-preference.d.ts +4 -4
  1008. package/test-utils/selectors/collection-preferences/sticky-columns-preference.d.ts +6 -6
  1009. package/test-utils/selectors/collection-preferences/visible-content-preference.d.ts +12 -12
  1010. package/test-utils/selectors/column-layout/index.d.ts +2 -2
  1011. package/test-utils/selectors/container/index.d.ts +6 -6
  1012. package/test-utils/selectors/content-layout/index.d.ts +7 -7
  1013. package/test-utils/selectors/copy-to-clipboard/index.d.ts +15 -15
  1014. package/test-utils/selectors/date-input/index.d.ts +2 -2
  1015. package/test-utils/selectors/date-picker/index.d.ts +11 -11
  1016. package/test-utils/selectors/date-range-picker/index.d.ts +81 -81
  1017. package/test-utils/selectors/drawer/index.d.ts +5 -5
  1018. package/test-utils/selectors/expandable-section/index.d.ts +9 -9
  1019. package/test-utils/selectors/file-dropzone/index.d.ts +3 -3
  1020. package/test-utils/selectors/file-input/index.d.ts +4 -4
  1021. package/test-utils/selectors/file-token-group/index.d.ts +17 -17
  1022. package/test-utils/selectors/file-upload/index.d.ts +18 -18
  1023. package/test-utils/selectors/flashbar/flash.d.ts +20 -20
  1024. package/test-utils/selectors/flashbar/index.d.ts +20 -20
  1025. package/test-utils/selectors/form/index.d.ts +7 -7
  1026. package/test-utils/selectors/form-field/index.d.ts +10 -10
  1027. package/test-utils/selectors/grid/index.d.ts +7 -7
  1028. package/test-utils/selectors/header/index.d.ts +7 -7
  1029. package/test-utils/selectors/help-panel/index.d.ts +5 -5
  1030. package/test-utils/selectors/hotspot/index.d.ts +4 -4
  1031. package/test-utils/selectors/icon/index.d.ts +2 -2
  1032. package/test-utils/selectors/index.d.ts +1283 -1283
  1033. package/test-utils/selectors/input/base-input.d.ts +2 -2
  1034. package/test-utils/selectors/input/index.d.ts +3 -3
  1035. package/test-utils/selectors/internal/abstract-switch.d.ts +5 -5
  1036. package/test-utils/selectors/internal/autosuggest-input.d.ts +4 -4
  1037. package/test-utils/selectors/internal/chart-filter.d.ts +4 -4
  1038. package/test-utils/selectors/internal/chart-legend.d.ts +6 -6
  1039. package/test-utils/selectors/internal/chart-popover.d.ts +9 -9
  1040. package/test-utils/selectors/internal/chart-tooltip.d.ts +6 -6
  1041. package/test-utils/selectors/internal/charts.d.ts +5 -5
  1042. package/test-utils/selectors/internal/drag-handle.d.ts +7 -7
  1043. package/test-utils/selectors/internal/dropdown-host.d.ts +56 -56
  1044. package/test-utils/selectors/internal/dropdown.d.ts +3 -3
  1045. package/test-utils/selectors/internal/option.d.ts +7 -7
  1046. package/test-utils/selectors/internal/options-list.d.ts +2 -2
  1047. package/test-utils/selectors/internal/tooltip.d.ts +2 -2
  1048. package/test-utils/selectors/key-value-pairs/index.d.ts +8 -8
  1049. package/test-utils/selectors/line-chart/index.d.ts +2 -2
  1050. package/test-utils/selectors/link/index.d.ts +2 -2
  1051. package/test-utils/selectors/live-region/index.d.ts +2 -2
  1052. package/test-utils/selectors/mixed-line-bar-chart/index.d.ts +21 -21
  1053. package/test-utils/selectors/modal/index.d.ts +6 -6
  1054. package/test-utils/selectors/multiselect/index.d.ts +37 -37
  1055. package/test-utils/selectors/pagination/index.d.ts +12 -12
  1056. package/test-utils/selectors/pie-chart/index.d.ts +13 -13
  1057. package/test-utils/selectors/popover/index.d.ts +24 -24
  1058. package/test-utils/selectors/progress-bar/index.d.ts +14 -14
  1059. package/test-utils/selectors/prompt-input/index.d.ts +6 -6
  1060. package/test-utils/selectors/property-filter/index.d.ts +68 -68
  1061. package/test-utils/selectors/radio-group/index.d.ts +4 -4
  1062. package/test-utils/selectors/radio-group/radio-button.d.ts +5 -5
  1063. package/test-utils/selectors/s3-resource-selector/index.d.ts +11 -11
  1064. package/test-utils/selectors/segmented-control/index.d.ts +11 -11
  1065. package/test-utils/selectors/select/index.d.ts +27 -27
  1066. package/test-utils/selectors/side-navigation/index.d.ts +18 -18
  1067. package/test-utils/selectors/slider/index.d.ts +3 -3
  1068. package/test-utils/selectors/space-between/index.d.ts +2 -2
  1069. package/test-utils/selectors/spinner/index.d.ts +2 -2
  1070. package/test-utils/selectors/split-panel/index.d.ts +17 -17
  1071. package/test-utils/selectors/status-indicator/index.d.ts +2 -2
  1072. package/test-utils/selectors/steps/index.d.ts +14 -14
  1073. package/test-utils/selectors/table/index.d.ts +90 -90
  1074. package/test-utils/selectors/tabs/index.d.ts +68 -68
  1075. package/test-utils/selectors/tag-editor/index.d.ts +17 -17
  1076. package/test-utils/selectors/text-content/index.d.ts +2 -2
  1077. package/test-utils/selectors/text-filter/index.d.ts +4 -4
  1078. package/test-utils/selectors/textarea/index.d.ts +3 -3
  1079. package/test-utils/selectors/tiles/index.d.ts +5 -5
  1080. package/test-utils/selectors/tiles/tile.d.ts +7 -7
  1081. package/test-utils/selectors/time-input/index.d.ts +2 -2
  1082. package/test-utils/selectors/toggle/index.d.ts +6 -6
  1083. package/test-utils/selectors/toggle-button/index.d.ts +2 -2
  1084. package/test-utils/selectors/token-group/index.d.ts +13 -13
  1085. package/test-utils/selectors/token-group/token.d.ts +5 -5
  1086. package/test-utils/selectors/top-navigation/1.0-beta/index.d.ts +17 -17
  1087. package/test-utils/selectors/top-navigation/index.d.ts +23 -23
  1088. package/test-utils/selectors/tutorial-panel/index.d.ts +12 -12
  1089. package/test-utils/selectors/tutorial-panel/tutorial.d.ts +10 -10
  1090. package/test-utils/selectors/wizard/index.d.ts +22 -22
  1091. package/text-content/index.d.ts +4 -2
  1092. package/text-content/interfaces.d.ts +6 -7
  1093. package/text-filter/analytics/use-table-integration.d.ts +1 -2
  1094. package/text-filter/analytics-metadata/interfaces.d.ts +6 -7
  1095. package/text-filter/index.d.ts +1 -2
  1096. package/text-filter/interfaces.d.ts +54 -55
  1097. package/text-filter/internal.d.ts +1 -2
  1098. package/text-filter/search-results.d.ts +4 -5
  1099. package/text-filter/use-debounce-search-result-callback.d.ts +10 -6
  1100. package/textarea/index.d.ts +1 -2
  1101. package/textarea/interfaces.d.ts +26 -27
  1102. package/theming/index.d.ts +13 -8
  1103. package/tiles/analytics-metadata/interfaces.d.ts +9 -10
  1104. package/tiles/index.d.ts +1 -2
  1105. package/tiles/interfaces.d.ts +70 -71
  1106. package/tiles/internal.d.ts +1 -2
  1107. package/tiles/tile.d.ts +7 -8
  1108. package/time-input/index.d.ts +1 -2
  1109. package/time-input/interfaces.d.ts +26 -27
  1110. package/time-input/internal.d.ts +1 -2
  1111. package/toggle/analytics-metadata/interfaces.d.ts +11 -12
  1112. package/toggle/index.d.ts +1 -2
  1113. package/toggle/interfaces.d.ts +16 -17
  1114. package/toggle/internal.d.ts +2 -3
  1115. package/toggle-button/index.d.ts +1 -2
  1116. package/toggle-button/index.js +11 -15
  1117. package/toggle-button/interfaces.d.ts +68 -69
  1118. package/toggle-button/internal-do-not-use-core.js +22 -0
  1119. package/toggle-button/internal.d.ts +2 -3
  1120. package/toggle-button/util.d.ts +1 -2
  1121. package/token-group/analytics-metadata/interfaces.d.ts +11 -12
  1122. package/token-group/dismiss-button.d.ts +5 -6
  1123. package/token-group/index.d.ts +5 -2
  1124. package/token-group/interfaces.d.ts +75 -76
  1125. package/token-group/internal.d.ts +14 -3
  1126. package/token-group/token.d.ts +17 -10
  1127. package/top-navigation/1.0-beta/index.d.ts +4 -2
  1128. package/top-navigation/1.0-beta/interfaces.d.ts +94 -95
  1129. package/top-navigation/1.0-beta/internal.d.ts +9 -3
  1130. package/top-navigation/1.0-beta/parts/overflow-menu.d.ts +13 -10
  1131. package/top-navigation/1.0-beta/parts/utility.d.ts +10 -6
  1132. package/top-navigation/1.0-beta/use-top-navigation.d.ts +21 -17
  1133. package/top-navigation/index.d.ts +4 -2
  1134. package/top-navigation/interfaces.d.ts +108 -109
  1135. package/top-navigation/internal.d.ts +9 -3
  1136. package/top-navigation/parts/overflow-menu/header.d.ts +7 -8
  1137. package/top-navigation/parts/overflow-menu/index.d.ts +14 -9
  1138. package/top-navigation/parts/overflow-menu/menu-item.d.ts +4 -5
  1139. package/top-navigation/parts/overflow-menu/router.d.ts +15 -11
  1140. package/top-navigation/parts/overflow-menu/views/submenu.d.ts +12 -5
  1141. package/top-navigation/parts/overflow-menu/views/utilities.d.ts +10 -5
  1142. package/top-navigation/parts/utility.d.ts +8 -5
  1143. package/top-navigation/use-top-navigation.d.ts +29 -26
  1144. package/tutorial-panel/components/tutorial-detail-view/congratulation-screen.d.ts +9 -6
  1145. package/tutorial-panel/components/tutorial-detail-view/index.d.ts +13 -8
  1146. package/tutorial-panel/components/tutorial-detail-view/task-list.d.ts +11 -7
  1147. package/tutorial-panel/components/tutorial-detail-view/task.d.ts +15 -9
  1148. package/tutorial-panel/components/tutorial-list/index.d.ts +13 -8
  1149. package/tutorial-panel/index.d.ts +8 -2
  1150. package/tutorial-panel/interfaces.d.ts +169 -170
  1151. package/wizard/analytics-metadata/interfaces.d.ts +25 -26
  1152. package/wizard/analytics-metadata/utils.d.ts +3 -4
  1153. package/wizard/analytics.d.ts +5 -6
  1154. package/wizard/index.d.ts +6 -3
  1155. package/wizard/interfaces.d.ts +145 -146
  1156. package/wizard/internal.d.ts +16 -4
  1157. package/wizard/unmount.d.ts +5 -6
  1158. package/wizard/wizard-actions.d.ts +33 -18
  1159. package/wizard/wizard-form-header.d.ts +5 -4
  1160. package/wizard/wizard-form.d.ts +13 -14
  1161. package/wizard/wizard-navigation.d.ts +21 -12
  1162. package/button/index.js.map +0 -1
  1163. /package/toggle-button/{index.js.map → internal-do-not-use-core.js.map} +0 -0
@@ -1,7 +1,7 @@
1
1
  import { OptionDefinition, OptionGroup } from '../../internal/components/option/interfaces';
2
2
  import { SelectProps } from '../interfaces';
3
3
  interface OptionHolder {
4
- option?: OptionDefinition | OptionGroup;
4
+ option?: OptionDefinition | OptionGroup;
5
5
  }
6
6
  /**
7
7
  * The hook produces the live region string to be announced when an option is highlighted.
@@ -9,13 +9,19 @@ interface OptionHolder {
9
9
  *
10
10
  * If the testing reveals no issues with the native announcements the live-region can be removed.
11
11
  */
12
- export declare function useAnnouncement<Option extends OptionHolder>({ highlightText, announceSelected, highlightedOption, getParent, selectedAriaLabel, renderHighlightedAriaLive, }: {
13
- highlightText?: string;
14
- announceSelected: boolean;
15
- highlightedOption?: Option;
16
- getParent: (option: Option) => undefined | OptionGroup;
17
- selectedAriaLabel?: string;
18
- renderHighlightedAriaLive?: SelectProps.ContainingOptionAndGroupString;
12
+ export declare function useAnnouncement<Option extends OptionHolder>({
13
+ highlightText,
14
+ announceSelected,
15
+ highlightedOption,
16
+ getParent,
17
+ selectedAriaLabel,
18
+ renderHighlightedAriaLive
19
+ }: {
20
+ highlightText?: string;
21
+ announceSelected: boolean;
22
+ highlightedOption?: Option;
23
+ getParent: (option: Option) => undefined | OptionGroup;
24
+ selectedAriaLabel?: string;
25
+ renderHighlightedAriaLive?: SelectProps.ContainingOptionAndGroupString;
19
26
  }): string;
20
- export {};
21
- //# sourceMappingURL=use-announcement.d.ts.map
27
+ export {};
@@ -2,14 +2,17 @@ import { DropdownStatusProps } from '../../internal/components/dropdown-status';
2
2
  import { OptionDefinition, OptionGroup } from '../../internal/components/option/interfaces';
3
3
  import { SelectProps } from '../interfaces';
4
4
  interface UseLoadItemsProps {
5
- onLoadItems: SelectProps['onLoadItems'];
6
- options: ReadonlyArray<OptionDefinition | OptionGroup>;
7
- statusType: DropdownStatusProps.StatusType;
5
+ onLoadItems: SelectProps['onLoadItems'];
6
+ options: ReadonlyArray<OptionDefinition | OptionGroup>;
7
+ statusType: DropdownStatusProps.StatusType;
8
8
  }
9
- export declare const useLoadItems: ({ onLoadItems, options, statusType }: UseLoadItemsProps) => {
10
- fireLoadItems: (filteringText: string) => void;
11
- handleLoadMore: () => void;
12
- handleRecoveryClick: () => void;
9
+ export declare const useLoadItems: ({
10
+ onLoadItems,
11
+ options,
12
+ statusType
13
+ }: UseLoadItemsProps) => {
14
+ fireLoadItems: (filteringText: string) => void;
15
+ handleLoadMore: () => void;
16
+ handleRecoveryClick: () => void;
13
17
  };
14
- export {};
15
- //# sourceMappingURL=use-load-items.d.ts.map
18
+ export {};
@@ -1,12 +1,17 @@
1
1
  import React from 'react';
2
2
  import type { DropdownOption, OptionDefinition } from '../../internal/components/option/interfaces';
3
3
  interface UseNativeSearchProps {
4
- isEnabled: boolean;
5
- options: ReadonlyArray<DropdownOption>;
6
- highlightOption: (option: DropdownOption) => void;
7
- highlightedOption: OptionDefinition | undefined | null;
8
- useInteractiveGroups?: boolean;
4
+ isEnabled: boolean;
5
+ options: ReadonlyArray<DropdownOption>;
6
+ highlightOption: (option: DropdownOption) => void;
7
+ highlightedOption: OptionDefinition | undefined | null;
8
+ useInteractiveGroups?: boolean;
9
9
  }
10
- export declare function useNativeSearch({ isEnabled, options, highlightOption, highlightedOption, useInteractiveGroups, }: UseNativeSearchProps): (event: React.KeyboardEvent) => void;
11
- export {};
12
- //# sourceMappingURL=use-native-search.d.ts.map
10
+ export declare function useNativeSearch({
11
+ isEnabled,
12
+ options,
13
+ highlightOption,
14
+ highlightedOption,
15
+ useInteractiveGroups
16
+ }: UseNativeSearchProps): (event: React.KeyboardEvent) => void;
17
+ export {};
@@ -8,44 +8,60 @@ import { NonCancelableEventHandler } from '../../internal/events';
8
8
  import { FilterProps } from '../parts/filter';
9
9
  import { ItemProps } from '../parts/item';
10
10
  export type MenuProps = Omit<OptionsListProps, 'children'> & {
11
- ref: React.RefObject<HTMLUListElement>;
11
+ ref: React.RefObject<HTMLUListElement>;
12
12
  };
13
13
  export type GetOptionProps = (option: DropdownOption, index: number) => ItemProps;
14
14
  interface UseSelectProps {
15
- selectedOptions: ReadonlyArray<OptionDefinition>;
16
- updateSelectedOption: (option: OptionDefinition) => void;
17
- options: ReadonlyArray<DropdownOption>;
18
- filteringType: string;
19
- keepOpen?: boolean;
20
- embedded?: boolean;
21
- onBlur?: NonCancelableEventHandler;
22
- onFocus?: NonCancelableEventHandler;
23
- externalRef: React.Ref<any>;
24
- fireLoadItems: (filteringText: string) => void;
25
- setFilteringValue?: (filteringText: string) => void;
26
- useInteractiveGroups?: boolean;
27
- statusType: DropdownStatusProps.StatusType;
28
- isAllSelected?: boolean;
29
- isSomeSelected?: boolean;
30
- toggleAll?: () => void;
15
+ selectedOptions: ReadonlyArray<OptionDefinition>;
16
+ updateSelectedOption: (option: OptionDefinition) => void;
17
+ options: ReadonlyArray<DropdownOption>;
18
+ filteringType: string;
19
+ keepOpen?: boolean;
20
+ embedded?: boolean;
21
+ onBlur?: NonCancelableEventHandler;
22
+ onFocus?: NonCancelableEventHandler;
23
+ externalRef: React.Ref<any>;
24
+ fireLoadItems: (filteringText: string) => void;
25
+ setFilteringValue?: (filteringText: string) => void;
26
+ useInteractiveGroups?: boolean;
27
+ statusType: DropdownStatusProps.StatusType;
28
+ isAllSelected?: boolean;
29
+ isSomeSelected?: boolean;
30
+ toggleAll?: () => void;
31
31
  }
32
32
  export interface SelectTriggerProps extends ButtonTriggerProps {
33
- ref: RefObject<HTMLButtonElement>;
33
+ ref: RefObject<HTMLButtonElement>;
34
34
  }
35
- export declare function useSelect({ selectedOptions, updateSelectedOption, options, filteringType, onBlur, onFocus, externalRef, keepOpen, embedded, fireLoadItems, setFilteringValue, useInteractiveGroups, statusType, isAllSelected, isSomeSelected, toggleAll, }: UseSelectProps): {
36
- isOpen: boolean;
37
- highlightedOption: DropdownOption | undefined;
38
- highlightedIndex: number;
39
- highlightType: import("../../internal/components/options-list/utils/use-highlight-option").HighlightType;
40
- getTriggerProps: (disabled?: boolean, autoFocus?: boolean) => SelectTriggerProps;
41
- getDropdownProps: () => Pick<DropdownProps, 'onFocus' | 'onBlur' | 'dropdownContentId' | 'dropdownContentRole'>;
42
- getMenuProps: () => MenuProps;
43
- getFilterProps: () => Partial<FilterProps>;
44
- getOptionProps: (option: DropdownOption, index: number) => any;
45
- highlightOption: (option: DropdownOption) => void;
46
- selectOption: (option?: DropdownOption) => void;
47
- announceSelected: boolean;
48
- dialogId: string;
35
+ export declare function useSelect({
36
+ selectedOptions,
37
+ updateSelectedOption,
38
+ options,
39
+ filteringType,
40
+ onBlur,
41
+ onFocus,
42
+ externalRef,
43
+ keepOpen,
44
+ embedded,
45
+ fireLoadItems,
46
+ setFilteringValue,
47
+ useInteractiveGroups,
48
+ statusType,
49
+ isAllSelected,
50
+ isSomeSelected,
51
+ toggleAll
52
+ }: UseSelectProps): {
53
+ isOpen: boolean;
54
+ highlightedOption: DropdownOption | undefined;
55
+ highlightedIndex: number;
56
+ highlightType: import("../../internal/components/options-list/utils/use-highlight-option").HighlightType;
57
+ getTriggerProps: (disabled?: boolean, autoFocus?: boolean) => SelectTriggerProps;
58
+ getDropdownProps: () => Pick<DropdownProps, 'onFocus' | 'onBlur' | 'dropdownContentId' | 'dropdownContentRole'>;
59
+ getMenuProps: () => MenuProps;
60
+ getFilterProps: () => Partial<FilterProps>;
61
+ getOptionProps: (option: DropdownOption, index: number) => any;
62
+ highlightOption: (option: DropdownOption) => void;
63
+ selectOption: (option?: DropdownOption) => void;
64
+ announceSelected: boolean;
65
+ dialogId: string;
49
66
  };
50
- export {};
51
- //# sourceMappingURL=use-select.d.ts.map
67
+ export {};
@@ -1 +1 @@
1
- {"version":3,"file":"use-select.d.ts","sourceRoot":"","sources":["../../../../src/select/utils/use-select.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAKzC,OAAO,EAAE,kBAAkB,EAAE,MAAM,0CAA0C,CAAC;AAC9E,OAAO,EAAE,aAAa,EAAE,MAAM,+CAA+C,CAAC;AAC9E,OAAO,EAAE,mBAAmB,EAAE,MAAM,2CAA2C,CAAC;AAChF,OAAO,EAAE,cAAc,EAAE,gBAAgB,EAAe,MAAM,6CAA6C,CAAC;AAE5G,OAAO,EAAE,gBAAgB,EAAE,MAAM,wCAAwC,CAAC;AAK1E,OAAO,EAA0B,yBAAyB,EAAE,MAAM,uBAAuB,CAAC;AAG1F,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAC9C,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAG1C,MAAM,MAAM,SAAS,GAAG,IAAI,CAAC,gBAAgB,EAAE,UAAU,CAAC,GAAG;IAAE,GAAG,EAAE,KAAK,CAAC,SAAS,CAAC,gBAAgB,CAAC,CAA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,EAAE,OAAO,CAAC;IACnB,MAAM,CAAC,EAAE,yBAAyB,CAAC;IACnC,OAAO,CAAC,EAAE,yBAAyB,CAAC;IACpC,WAAW,EAAE,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IAC5B,aAAa,EAAE,CAAC,aAAa,EAAE,MAAM,KAAK,IAAI,CAAC;IAC/C,iBAAiB,CAAC,EAAE,CAAC,aAAa,EAAE,MAAM,KAAK,IAAI,CAAC;IACpD,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAC/B,UAAU,EAAE,mBAAmB,CAAC,UAAU,CAAC;IAC3C,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;CACxB;AAED,MAAM,WAAW,kBAAmB,SAAQ,kBAAkB;IAC5D,GAAG,EAAE,SAAS,CAAC,iBAAiB,CAAC,CAAC;CACnC;AAED,wBAAgB,SAAS,CAAC,EACxB,eAAe,EACf,oBAAoB,EACpB,OAAO,EACP,aAAa,EACb,MAAM,EACN,OAAO,EACP,WAAW,EACX,QAAQ,EACR,QAAQ,EACR,aAAa,EACb,iBAAiB,EACjB,oBAA4B,EAC5B,UAAU,EACV,aAAa,EACb,cAAc,EACd,SAAS,GACV,EAAE,cAAc;;;;;;4BA4Ge,KAC5B,aAAa,EACb,SAAS,GAAG,QAAQ,GAAG,mBAAmB,GAAG,qBAAqB,CACnE;;0BA4B0B,QAAQ,WAAW,CAAC;6BAoEf,cAAc,SAAS,MAAM;;4BApJ9B,cAAc;;;EAiO9C"}
@@ -24,7 +24,7 @@ export function useSelect({ selectedOptions, updateSelectedOption, options, filt
24
24
  }
25
25
  return selectedValuesSet;
26
26
  }, new Set());
27
- const [{ highlightType, highlightedOption, highlightedIndex }, { moveHighlightWithKeyboard, resetHighlightWithKeyboard, setHighlightedIndexWithMouse, highlightOptionWithKeyboard, highlightFirstOptionWithMouse, goHomeWithKeyboard, goEndWithKeyboard, },] = useHighlightedOption({ options: options, isHighlightable });
27
+ const [{ highlightType, highlightedOption, highlightedIndex }, { moveHighlightWithKeyboard, resetHighlightWithKeyboard, setHighlightedIndexWithMouse, highlightOptionWithKeyboard, goHomeWithKeyboard, goEndWithKeyboard, },] = useHighlightedOption({ options: options, isHighlightable });
28
28
  const { isOpen, openDropdown, closeDropdown, toggleDropdown, openedWithKeyboard } = useOpenState({
29
29
  defaultOpen: embedded,
30
30
  onOpen: () => fireLoadItems(''),
@@ -214,23 +214,12 @@ export function useSelect({ selectedOptions, updateSelectedOption, options, filt
214
214
  useEffect(() => {
215
215
  // highlight the first selected option, when opening the Select component without filter input
216
216
  // keep the focus in the filter input when opening, so that screenreader can recognize the combobox
217
- if (isOpen && !prevOpen && options.length > 0 && !hasFilter) {
217
+ if (isOpen && !prevOpen && hasSelectedOption && !hasFilter) {
218
218
  if (openedWithKeyboard) {
219
- if (__selectedOptions[0]) {
220
- highlightOptionWithKeyboard(__selectedOptions[0]);
221
- }
222
- else {
223
- goHomeWithKeyboard();
224
- }
219
+ highlightOptionWithKeyboard(__selectedOptions[0]);
225
220
  }
226
221
  else {
227
- if (!__selectedOptions[0] || !options.includes(__selectedOptions[0])) {
228
- highlightFirstOptionWithMouse();
229
- }
230
- else {
231
- const highlightedIndex = options.indexOf(__selectedOptions[0]);
232
- setHighlightedIndexWithMouse(highlightedIndex, true);
233
- }
222
+ setHighlightedIndexWithMouse(options.indexOf(__selectedOptions[0]), true);
234
223
  }
235
224
  }
236
225
  }, [
@@ -239,8 +228,6 @@ export function useSelect({ selectedOptions, updateSelectedOption, options, filt
239
228
  hasSelectedOption,
240
229
  setHighlightedIndexWithMouse,
241
230
  highlightOptionWithKeyboard,
242
- highlightFirstOptionWithMouse,
243
- goHomeWithKeyboard,
244
231
  openedWithKeyboard,
245
232
  options,
246
233
  prevOpen,
@@ -1 +1 @@
1
- {"version":3,"file":"use-select.js","sourceRoot":"","sources":["../../../../src/select/utils/use-select.ts"],"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CAAC;IAElC,eAAe,CAAC,WAAW,EAAE,UAA0C,CAAC,CAAC;IACzE,MAAM,wBAAwB,GAC5B,CAAC,CAAC,iBAAiB,IAAI,OAAO,CAAC,iBAAiB,CAAC,MAAM,CAAC,IAAI,aAAa,CAAC,iBAAiB,CAAC,MAAM,CAAC,CAAC,QAAQ,CAAC;IAC/G,MAAM,gBAAgB,GACpB,CAAC,CAAC,iBAAiB,IAAI,CAAC,iBAAiB,CAAC,OAAO,CAAC,iBAAiB,CAAC,GAAG,CAAC,CAAC,IAAI,wBAAwB,CAAC,CAAC;IAEzG,OAAO;QACL,MAAM;QACN,iBAAiB;QACjB,gBAAgB;QAChB,aAAa;QACb,eAAe;QACf,gBAAgB;QAChB,YAAY;QACZ,cAAc;QACd,cAAc;QACd,eAAe,EAAE,2BAA2B;QAC5C,YAAY;QACZ,gBAAgB;QAChB,QAAQ;KACT,CAAC;AACJ,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React, { RefObject } from 'react';\nimport { useEffect, useRef } from 'react';\n\nimport { useUniqueId } from '@cloudscape-design/component-toolkit/internal';\n\nimport { ButtonTriggerProps } from '../../internal/components/button-trigger';\nimport { DropdownProps } from '../../internal/components/dropdown/interfaces';\nimport { DropdownStatusProps } from '../../internal/components/dropdown-status';\nimport { DropdownOption, OptionDefinition, OptionGroup } from '../../internal/components/option/interfaces';\nimport { isGroup, isGroupInteractive, isInteractive } from '../../internal/components/option/utils/filter-options';\nimport { OptionsListProps } from '../../internal/components/options-list';\nimport { useHighlightedOption } from '../../internal/components/options-list/utils/use-highlight-option';\nimport { getOptionId } from '../../internal/components/options-list/utils/use-ids';\nimport { useMenuKeyboard, useTriggerKeyboard } from '../../internal/components/options-list/utils/use-keyboard';\nimport { useOpenState } from '../../internal/components/options-list/utils/use-open-state';\nimport { fireNonCancelableEvent, NonCancelableEventHandler } from '../../internal/events';\nimport useForwardFocus from '../../internal/hooks/forward-focus';\nimport { usePrevious } from '../../internal/hooks/use-previous';\nimport { FilterProps } from '../parts/filter';\nimport { ItemProps } from '../parts/item';\nimport { connectOptionsByValue } from './connect-options';\n\nexport type MenuProps = Omit<OptionsListProps, 'children'> & { ref: React.RefObject<HTMLUListElement> };\nexport type GetOptionProps = (option: DropdownOption, index: number) => ItemProps;\n\ninterface UseSelectProps {\n selectedOptions: ReadonlyArray<OptionDefinition>;\n updateSelectedOption: (option: OptionDefinition) => void;\n options: ReadonlyArray<DropdownOption>;\n filteringType: string;\n keepOpen?: boolean;\n embedded?: boolean;\n onBlur?: NonCancelableEventHandler;\n onFocus?: NonCancelableEventHandler;\n externalRef: React.Ref<any>;\n fireLoadItems: (filteringText: string) => void;\n setFilteringValue?: (filteringText: string) => void;\n useInteractiveGroups?: boolean;\n statusType: DropdownStatusProps.StatusType;\n isAllSelected?: boolean;\n isSomeSelected?: boolean;\n toggleAll?: () => void;\n}\n\nexport interface SelectTriggerProps extends ButtonTriggerProps {\n ref: RefObject<HTMLButtonElement>;\n}\n\nexport function useSelect({\n selectedOptions,\n updateSelectedOption,\n options,\n filteringType,\n onBlur,\n onFocus,\n externalRef,\n keepOpen,\n embedded,\n fireLoadItems,\n setFilteringValue,\n useInteractiveGroups = false,\n statusType,\n isAllSelected,\n isSomeSelected,\n toggleAll,\n}: UseSelectProps) {\n const interactivityCheck = useInteractiveGroups ? isGroupInteractive : isInteractive;\n\n const isHighlightable = (option?: DropdownOption) => !!option && (useInteractiveGroups || option.type !== 'parent');\n\n const filterRef = useRef<HTMLInputElement>(null);\n const triggerRef = useRef<HTMLButtonElement>(null);\n const menuRef = useRef<HTMLUListElement>(null);\n const hasFilter = filteringType !== 'none' && !embedded;\n const activeRef = hasFilter ? filterRef : menuRef;\n const __selectedOptions = connectOptionsByValue(options, selectedOptions);\n const __selectedValuesSet = selectedOptions.reduce((selectedValuesSet: Set<string>, item: OptionDefinition) => {\n if (item.value) {\n selectedValuesSet.add(item.value);\n }\n return selectedValuesSet;\n }, new Set<string>());\n const [\n { highlightType, highlightedOption, highlightedIndex },\n {\n moveHighlightWithKeyboard,\n resetHighlightWithKeyboard,\n setHighlightedIndexWithMouse,\n highlightOptionWithKeyboard,\n highlightFirstOptionWithMouse,\n goHomeWithKeyboard,\n goEndWithKeyboard,\n },\n ] = useHighlightedOption({ options: options, isHighlightable });\n\n const { isOpen, openDropdown, closeDropdown, toggleDropdown, openedWithKeyboard } = useOpenState({\n defaultOpen: embedded,\n onOpen: () => fireLoadItems(''),\n onClose: () => {\n resetHighlightWithKeyboard();\n setFilteringValue?.('');\n },\n });\n\n const handleFocus = () => {\n fireNonCancelableEvent(onFocus, {});\n };\n\n const handleBlur = () => {\n fireNonCancelableEvent(onBlur, {});\n closeDropdown();\n };\n\n const hasSelectedOption = __selectedOptions.length > 0;\n const menuId = useUniqueId('option-list');\n const dialogId = useUniqueId('dialog');\n const highlightedOptionId = getOptionId(menuId, highlightedIndex);\n\n const closeDropdownIfNecessary = () => {\n if (!keepOpen) {\n triggerRef.current?.focus();\n closeDropdown();\n }\n };\n\n const selectOption = (option?: DropdownOption) => {\n const optionToSelect = option || highlightedOption;\n if (!optionToSelect || !interactivityCheck(optionToSelect)) {\n return;\n }\n if (optionToSelect.type === 'select-all' && toggleAll) {\n toggleAll();\n } else {\n updateSelectedOption(optionToSelect.option);\n }\n closeDropdownIfNecessary();\n };\n\n const activeKeyDownHandler = useMenuKeyboard({\n goUp: () => {\n if (\n (!useInteractiveGroups && highlightedOption?.type === 'child' && highlightedIndex === 1) ||\n highlightedIndex === 0\n ) {\n goEndWithKeyboard();\n return;\n }\n moveHighlightWithKeyboard(-1);\n },\n goDown: () => {\n if (highlightedIndex === options.length - 1) {\n goHomeWithKeyboard();\n return;\n }\n\n moveHighlightWithKeyboard(1);\n },\n selectOption,\n goHome: goHomeWithKeyboard,\n goEnd: goEndWithKeyboard,\n closeDropdown: () => {\n if (!embedded) {\n triggerRef.current?.focus();\n closeDropdown();\n }\n },\n preventNativeSpace: !hasFilter || !!highlightedOption,\n });\n\n const triggerKeyDownHandler = useTriggerKeyboard({\n openDropdown: () => openDropdown(true),\n goHome: goHomeWithKeyboard,\n });\n\n const getDropdownProps: () => Pick<\n DropdownProps,\n 'onFocus' | 'onBlur' | 'dropdownContentId' | 'dropdownContentRole'\n > = () => ({\n onFocus: handleFocus,\n onBlur: handleBlur,\n dropdownContentId: dialogId,\n dropdownContentRole: hasFilter ? 'dialog' : undefined,\n });\n\n const getTriggerProps = (disabled = false, autoFocus = false) => {\n const triggerProps: SelectTriggerProps = {\n ref: triggerRef,\n onFocus: () => closeDropdown(),\n autoFocus,\n ariaHasPopup: hasFilter ? 'dialog' : 'listbox',\n ariaControls: isOpen ? (hasFilter ? dialogId : menuId) : undefined,\n };\n if (!disabled) {\n triggerProps.onMouseDown = (event: CustomEvent) => {\n event.preventDefault(); // prevent current focus from blurring as it immediately closes the dropdown\n if (isOpen) {\n triggerRef.current?.focus();\n }\n toggleDropdown();\n };\n triggerProps.onKeyDown = triggerKeyDownHandler;\n }\n return triggerProps;\n };\n\n const getFilterProps = (): Partial<FilterProps> => {\n if (!hasFilter || !setFilteringValue) {\n return {};\n }\n\n return {\n ref: filterRef,\n onKeyDown: activeKeyDownHandler,\n onChange: event => {\n setFilteringValue(event.detail.value);\n resetHighlightWithKeyboard();\n },\n __onDelayedInput: event => {\n fireLoadItems(event.detail.value);\n },\n __nativeAttributes: {\n 'aria-activedescendant': highlightedOptionId,\n ['aria-owns']: menuId,\n ['aria-controls']: menuId,\n },\n };\n };\n\n const getMenuProps = () => {\n const menuProps: MenuProps = {\n id: menuId,\n ref: menuRef,\n open: isOpen,\n onMouseUp: itemIndex => {\n if (itemIndex > -1) {\n selectOption(options[itemIndex]);\n }\n },\n onMouseMove: itemIndex => {\n if (itemIndex > -1) {\n setHighlightedIndexWithMouse(itemIndex);\n }\n },\n statusType,\n };\n if (!hasFilter) {\n menuProps.onKeyDown = activeKeyDownHandler;\n menuProps.nativeAttributes = {\n 'aria-activedescendant': highlightedOptionId,\n };\n }\n if (embedded) {\n menuProps.onFocus = () => {\n if (!highlightedOption) {\n goHomeWithKeyboard();\n }\n };\n menuProps.onBlur = () => {\n resetHighlightWithKeyboard();\n };\n }\n return menuProps;\n };\n const getGroupState = (option: OptionGroup) => {\n const totalSelected = option.options.filter(item => !!item.value && __selectedValuesSet.has(item.value)).length;\n const hasSelected = totalSelected > 0;\n const allSelected = totalSelected === option.options.length;\n return {\n selected: hasSelected && allSelected && useInteractiveGroups,\n indeterminate: hasSelected && !allSelected,\n };\n };\n\n const getOptionProps = (option: DropdownOption, index: number) => {\n const isSelectAll = option.type === 'select-all';\n const highlighted = option === highlightedOption;\n const groupState = isGroup(option.option) ? getGroupState(option.option) : undefined;\n const selected = isSelectAll ? isAllSelected : __selectedOptions.indexOf(option) > -1 || !!groupState?.selected;\n const nextOption = options[index + 1]?.option;\n const isNextSelected =\n !!nextOption && isGroup(nextOption)\n ? getGroupState(nextOption).selected\n : __selectedOptions.indexOf(options[index + 1]) > -1;\n const optionProps: any = {\n key: index,\n option,\n highlighted,\n selected,\n isNextSelected,\n indeterminate: !!groupState?.indeterminate || (isSelectAll && !isAllSelected && isSomeSelected),\n ['data-mouse-target']: isHighlightable(option) ? index : -1,\n id: getOptionId(menuId, index),\n };\n\n return optionProps;\n };\n\n const prevOpen = usePrevious<boolean>(isOpen);\n useEffect(() => {\n // highlight the first selected option, when opening the Select component without filter input\n // keep the focus in the filter input when opening, so that screenreader can recognize the combobox\n if (isOpen && !prevOpen && options.length > 0 && !hasFilter) {\n if (openedWithKeyboard) {\n if (__selectedOptions[0]) {\n highlightOptionWithKeyboard(__selectedOptions[0]);\n } else {\n goHomeWithKeyboard();\n }\n } else {\n if (!__selectedOptions[0] || !options.includes(__selectedOptions[0])) {\n highlightFirstOptionWithMouse();\n } else {\n const highlightedIndex = options.indexOf(__selectedOptions[0]);\n setHighlightedIndexWithMouse(highlightedIndex, true);\n }\n }\n }\n }, [\n isOpen,\n __selectedOptions,\n hasSelectedOption,\n setHighlightedIndexWithMouse,\n highlightOptionWithKeyboard,\n highlightFirstOptionWithMouse,\n goHomeWithKeyboard,\n openedWithKeyboard,\n options,\n prevOpen,\n hasFilter,\n ]);\n\n useEffect(() => {\n if (isOpen && !embedded) {\n // dropdown-fit calculations ensure that the dropdown will fit inside the current\n // viewport, so prevent the browser from trying to scroll it into view (e.g. if\n // scroll-padding-top is set on a parent)\n activeRef.current?.focus({ preventScroll: true });\n }\n }, [isOpen, activeRef, embedded]);\n\n useForwardFocus(externalRef, triggerRef as React.RefObject<HTMLElement>);\n const highlightedGroupSelected =\n !!highlightedOption && isGroup(highlightedOption.option) && getGroupState(highlightedOption.option).selected;\n const announceSelected =\n !!highlightedOption && (__selectedOptions.indexOf(highlightedOption) > -1 || highlightedGroupSelected);\n\n return {\n isOpen,\n highlightedOption,\n highlightedIndex,\n highlightType,\n getTriggerProps,\n getDropdownProps,\n getMenuProps,\n getFilterProps,\n getOptionProps,\n highlightOption: highlightOptionWithKeyboard,\n selectOption,\n announceSelected,\n dialogId,\n };\n}\n"]}
1
+ {"version":3,"file":"use-select.js","sourceRoot":"","sources":["../../../../src/select/utils/use-select.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAE1C,OAAO,EAAE,WAAW,EAAE,MAAM,+CAA+C,CAAC;AAM5E,OAAO,EAAE,OAAO,EAAE,kBAAkB,EAAE,aAAa,EAAE,MAAM,uDAAuD,CAAC;AAEnH,OAAO,EAAE,oBAAoB,EAAE,MAAM,mEAAmE,CAAC;AACzG,OAAO,EAAE,WAAW,EAAE,MAAM,sDAAsD,CAAC;AACnF,OAAO,EAAE,eAAe,EAAE,kBAAkB,EAAE,MAAM,2DAA2D,CAAC;AAChH,OAAO,EAAE,YAAY,EAAE,MAAM,6DAA6D,CAAC;AAC3F,OAAO,EAAE,sBAAsB,EAA6B,MAAM,uBAAuB,CAAC;AAC1F,OAAO,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AA4B;QAC5B,2BAA2B;QAC3B,kBAAkB;QAClB,OAAO;QACP,QAAQ;QACR,SAAS;KACV,CAAC,CAAC;IAEH,SAAS,CAAC,GAAG,EAAE;;QACb,IAAI,MAAM,IAAI,CAAC,QAAQ,EAAE;YACvB,iFAAiF;YACjF,+EAA+E;YAC/E,yCAAyC;YACzC,MAAA,SAAS,CAAC,OAAO,0CAAE,KAAK,CAAC,EAAE,aAAa,EAAE,IAAI,EAAE,CAAC,CAAC;SACnD;IACH,CAAC,EAAE,CAAC,MAAM,EAAE,SAAS,EAAE,QAAQ,CAAC,CAAC,CAAC;IAElC,eAAe,CAAC,WAAW,EAAE,UAA0C,CAAC,CAAC;IACzE,MAAM,wBAAwB,GAC5B,CAAC,CAAC,iBAAiB,IAAI,OAAO,CAAC,iBAAiB,CAAC,MAAM,CAAC,IAAI,aAAa,CAAC,iBAAiB,CAAC,MAAM,CAAC,CAAC,QAAQ,CAAC;IAC/G,MAAM,gBAAgB,GACpB,CAAC,CAAC,iBAAiB,IAAI,CAAC,iBAAiB,CAAC,OAAO,CAAC,iBAAiB,CAAC,GAAG,CAAC,CAAC,IAAI,wBAAwB,CAAC,CAAC;IAEzG,OAAO;QACL,MAAM;QACN,iBAAiB;QACjB,gBAAgB;QAChB,aAAa;QACb,eAAe;QACf,gBAAgB;QAChB,YAAY;QACZ,cAAc;QACd,cAAc;QACd,eAAe,EAAE,2BAA2B;QAC5C,YAAY;QACZ,gBAAgB;QAChB,QAAQ;KACT,CAAC;AACJ,CAAC","sourcesContent":["// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.\n// SPDX-License-Identifier: Apache-2.0\nimport React, { RefObject } from 'react';\nimport { useEffect, useRef } from 'react';\n\nimport { useUniqueId } from '@cloudscape-design/component-toolkit/internal';\n\nimport { ButtonTriggerProps } from '../../internal/components/button-trigger';\nimport { DropdownProps } from '../../internal/components/dropdown/interfaces';\nimport { DropdownStatusProps } from '../../internal/components/dropdown-status';\nimport { DropdownOption, OptionDefinition, OptionGroup } from '../../internal/components/option/interfaces';\nimport { isGroup, isGroupInteractive, isInteractive } from '../../internal/components/option/utils/filter-options';\nimport { OptionsListProps } from '../../internal/components/options-list';\nimport { useHighlightedOption } from '../../internal/components/options-list/utils/use-highlight-option';\nimport { getOptionId } from '../../internal/components/options-list/utils/use-ids';\nimport { useMenuKeyboard, useTriggerKeyboard } from '../../internal/components/options-list/utils/use-keyboard';\nimport { useOpenState } from '../../internal/components/options-list/utils/use-open-state';\nimport { fireNonCancelableEvent, NonCancelableEventHandler } from '../../internal/events';\nimport useForwardFocus from '../../internal/hooks/forward-focus';\nimport { usePrevious } from '../../internal/hooks/use-previous';\nimport { FilterProps } from '../parts/filter';\nimport { ItemProps } from '../parts/item';\nimport { connectOptionsByValue } from './connect-options';\n\nexport type MenuProps = Omit<OptionsListProps, 'children'> & { ref: React.RefObject<HTMLUListElement> };\nexport type GetOptionProps = (option: DropdownOption, index: number) => ItemProps;\n\ninterface UseSelectProps {\n selectedOptions: ReadonlyArray<OptionDefinition>;\n updateSelectedOption: (option: OptionDefinition) => void;\n options: ReadonlyArray<DropdownOption>;\n filteringType: string;\n keepOpen?: boolean;\n embedded?: boolean;\n onBlur?: NonCancelableEventHandler;\n onFocus?: NonCancelableEventHandler;\n externalRef: React.Ref<any>;\n fireLoadItems: (filteringText: string) => void;\n setFilteringValue?: (filteringText: string) => void;\n useInteractiveGroups?: boolean;\n statusType: DropdownStatusProps.StatusType;\n isAllSelected?: boolean;\n isSomeSelected?: boolean;\n toggleAll?: () => void;\n}\n\nexport interface SelectTriggerProps extends ButtonTriggerProps {\n ref: RefObject<HTMLButtonElement>;\n}\n\nexport function useSelect({\n selectedOptions,\n updateSelectedOption,\n options,\n filteringType,\n onBlur,\n onFocus,\n externalRef,\n keepOpen,\n embedded,\n fireLoadItems,\n setFilteringValue,\n useInteractiveGroups = false,\n statusType,\n isAllSelected,\n isSomeSelected,\n toggleAll,\n}: UseSelectProps) {\n const interactivityCheck = useInteractiveGroups ? isGroupInteractive : isInteractive;\n\n const isHighlightable = (option?: DropdownOption) => !!option && (useInteractiveGroups || option.type !== 'parent');\n\n const filterRef = useRef<HTMLInputElement>(null);\n const triggerRef = useRef<HTMLButtonElement>(null);\n const menuRef = useRef<HTMLUListElement>(null);\n const hasFilter = filteringType !== 'none' && !embedded;\n const activeRef = hasFilter ? filterRef : menuRef;\n const __selectedOptions = connectOptionsByValue(options, selectedOptions);\n const __selectedValuesSet = selectedOptions.reduce((selectedValuesSet: Set<string>, item: OptionDefinition) => {\n if (item.value) {\n selectedValuesSet.add(item.value);\n }\n return selectedValuesSet;\n }, new Set<string>());\n const [\n { highlightType, highlightedOption, highlightedIndex },\n {\n moveHighlightWithKeyboard,\n resetHighlightWithKeyboard,\n setHighlightedIndexWithMouse,\n highlightOptionWithKeyboard,\n goHomeWithKeyboard,\n goEndWithKeyboard,\n },\n ] = useHighlightedOption({ options: options, isHighlightable });\n\n const { isOpen, openDropdown, closeDropdown, toggleDropdown, openedWithKeyboard } = useOpenState({\n defaultOpen: embedded,\n onOpen: () => fireLoadItems(''),\n onClose: () => {\n resetHighlightWithKeyboard();\n setFilteringValue?.('');\n },\n });\n\n const handleFocus = () => {\n fireNonCancelableEvent(onFocus, {});\n };\n\n const handleBlur = () => {\n fireNonCancelableEvent(onBlur, {});\n closeDropdown();\n };\n\n const hasSelectedOption = __selectedOptions.length > 0;\n const menuId = useUniqueId('option-list');\n const dialogId = useUniqueId('dialog');\n const highlightedOptionId = getOptionId(menuId, highlightedIndex);\n\n const closeDropdownIfNecessary = () => {\n if (!keepOpen) {\n triggerRef.current?.focus();\n closeDropdown();\n }\n };\n\n const selectOption = (option?: DropdownOption) => {\n const optionToSelect = option || highlightedOption;\n if (!optionToSelect || !interactivityCheck(optionToSelect)) {\n return;\n }\n if (optionToSelect.type === 'select-all' && toggleAll) {\n toggleAll();\n } else {\n updateSelectedOption(optionToSelect.option);\n }\n closeDropdownIfNecessary();\n };\n\n const activeKeyDownHandler = useMenuKeyboard({\n goUp: () => {\n if (\n (!useInteractiveGroups && highlightedOption?.type === 'child' && highlightedIndex === 1) ||\n highlightedIndex === 0\n ) {\n goEndWithKeyboard();\n return;\n }\n moveHighlightWithKeyboard(-1);\n },\n goDown: () => {\n if (highlightedIndex === options.length - 1) {\n goHomeWithKeyboard();\n return;\n }\n\n moveHighlightWithKeyboard(1);\n },\n selectOption,\n goHome: goHomeWithKeyboard,\n goEnd: goEndWithKeyboard,\n closeDropdown: () => {\n if (!embedded) {\n triggerRef.current?.focus();\n closeDropdown();\n }\n },\n preventNativeSpace: !hasFilter || !!highlightedOption,\n });\n\n const triggerKeyDownHandler = useTriggerKeyboard({\n openDropdown: () => openDropdown(true),\n goHome: goHomeWithKeyboard,\n });\n\n const getDropdownProps: () => Pick<\n DropdownProps,\n 'onFocus' | 'onBlur' | 'dropdownContentId' | 'dropdownContentRole'\n > = () => ({\n onFocus: handleFocus,\n onBlur: handleBlur,\n dropdownContentId: dialogId,\n dropdownContentRole: hasFilter ? 'dialog' : undefined,\n });\n\n const getTriggerProps = (disabled = false, autoFocus = false) => {\n const triggerProps: SelectTriggerProps = {\n ref: triggerRef,\n onFocus: () => closeDropdown(),\n autoFocus,\n ariaHasPopup: hasFilter ? 'dialog' : 'listbox',\n ariaControls: isOpen ? (hasFilter ? dialogId : menuId) : undefined,\n };\n if (!disabled) {\n triggerProps.onMouseDown = (event: CustomEvent) => {\n event.preventDefault(); // prevent current focus from blurring as it immediately closes the dropdown\n if (isOpen) {\n triggerRef.current?.focus();\n }\n toggleDropdown();\n };\n triggerProps.onKeyDown = triggerKeyDownHandler;\n }\n return triggerProps;\n };\n\n const getFilterProps = (): Partial<FilterProps> => {\n if (!hasFilter || !setFilteringValue) {\n return {};\n }\n\n return {\n ref: filterRef,\n onKeyDown: activeKeyDownHandler,\n onChange: event => {\n setFilteringValue(event.detail.value);\n resetHighlightWithKeyboard();\n },\n __onDelayedInput: event => {\n fireLoadItems(event.detail.value);\n },\n __nativeAttributes: {\n 'aria-activedescendant': highlightedOptionId,\n ['aria-owns']: menuId,\n ['aria-controls']: menuId,\n },\n };\n };\n\n const getMenuProps = () => {\n const menuProps: MenuProps = {\n id: menuId,\n ref: menuRef,\n open: isOpen,\n onMouseUp: itemIndex => {\n if (itemIndex > -1) {\n selectOption(options[itemIndex]);\n }\n },\n onMouseMove: itemIndex => {\n if (itemIndex > -1) {\n setHighlightedIndexWithMouse(itemIndex);\n }\n },\n statusType,\n };\n if (!hasFilter) {\n menuProps.onKeyDown = activeKeyDownHandler;\n menuProps.nativeAttributes = {\n 'aria-activedescendant': highlightedOptionId,\n };\n }\n if (embedded) {\n menuProps.onFocus = () => {\n if (!highlightedOption) {\n goHomeWithKeyboard();\n }\n };\n menuProps.onBlur = () => {\n resetHighlightWithKeyboard();\n };\n }\n return menuProps;\n };\n const getGroupState = (option: OptionGroup) => {\n const totalSelected = option.options.filter(item => !!item.value && __selectedValuesSet.has(item.value)).length;\n const hasSelected = totalSelected > 0;\n const allSelected = totalSelected === option.options.length;\n return {\n selected: hasSelected && allSelected && useInteractiveGroups,\n indeterminate: hasSelected && !allSelected,\n };\n };\n\n const getOptionProps = (option: DropdownOption, index: number) => {\n const isSelectAll = option.type === 'select-all';\n const highlighted = option === highlightedOption;\n const groupState = isGroup(option.option) ? getGroupState(option.option) : undefined;\n const selected = isSelectAll ? isAllSelected : __selectedOptions.indexOf(option) > -1 || !!groupState?.selected;\n const nextOption = options[index + 1]?.option;\n const isNextSelected =\n !!nextOption && isGroup(nextOption)\n ? getGroupState(nextOption).selected\n : __selectedOptions.indexOf(options[index + 1]) > -1;\n const optionProps: any = {\n key: index,\n option,\n highlighted,\n selected,\n isNextSelected,\n indeterminate: !!groupState?.indeterminate || (isSelectAll && !isAllSelected && isSomeSelected),\n ['data-mouse-target']: isHighlightable(option) ? index : -1,\n id: getOptionId(menuId, index),\n };\n\n return optionProps;\n };\n\n const prevOpen = usePrevious<boolean>(isOpen);\n useEffect(() => {\n // highlight the first selected option, when opening the Select component without filter input\n // keep the focus in the filter input when opening, so that screenreader can recognize the combobox\n if (isOpen && !prevOpen && hasSelectedOption && !hasFilter) {\n if (openedWithKeyboard) {\n highlightOptionWithKeyboard(__selectedOptions[0]);\n } else {\n setHighlightedIndexWithMouse(options.indexOf(__selectedOptions[0]), true);\n }\n }\n }, [\n isOpen,\n __selectedOptions,\n hasSelectedOption,\n setHighlightedIndexWithMouse,\n highlightOptionWithKeyboard,\n openedWithKeyboard,\n options,\n prevOpen,\n hasFilter,\n ]);\n\n useEffect(() => {\n if (isOpen && !embedded) {\n // dropdown-fit calculations ensure that the dropdown will fit inside the current\n // viewport, so prevent the browser from trying to scroll it into view (e.g. if\n // scroll-padding-top is set on a parent)\n activeRef.current?.focus({ preventScroll: true });\n }\n }, [isOpen, activeRef, embedded]);\n\n useForwardFocus(externalRef, triggerRef as React.RefObject<HTMLElement>);\n const highlightedGroupSelected =\n !!highlightedOption && isGroup(highlightedOption.option) && getGroupState(highlightedOption.option).selected;\n const announceSelected =\n !!highlightedOption && (__selectedOptions.indexOf(highlightedOption) > -1 || highlightedGroupSelected);\n\n return {\n isOpen,\n highlightedOption,\n highlightedIndex,\n highlightType,\n getTriggerProps,\n getDropdownProps,\n getMenuProps,\n getFilterProps,\n getOptionProps,\n highlightOption: highlightOptionWithKeyboard,\n selectOption,\n announceSelected,\n dialogId,\n };\n}\n"]}
@@ -1,20 +1,19 @@
1
1
  import { GeneratedAnalyticsMetadataExpandableSectionCollapse, GeneratedAnalyticsMetadataExpandableSectionExpand } from '../../expandable-section/analytics-metadata/interfaces';
2
2
  export interface GeneratedAnalyticsMetadataSideNavigationClick {
3
- action: 'click';
4
- detail: {
5
- label: string;
6
- position?: string;
7
- href?: string;
8
- external: string;
9
- };
3
+ action: 'click';
4
+ detail: {
5
+ label: string;
6
+ position?: string;
7
+ href?: string;
8
+ external: string;
9
+ };
10
10
  }
11
11
  export type GeneratedAnalyticsMetadataSideNavigationExpand = GeneratedAnalyticsMetadataExpandableSectionExpand;
12
12
  export type GeneratedAnalyticsMetadataSideNavigationCollapse = GeneratedAnalyticsMetadataExpandableSectionCollapse;
13
13
  export interface GeneratedAnalyticsMetadataSideNavigationComponent {
14
- name: 'awsui.SideNavigation';
15
- label: string;
16
- properties: {
17
- activeHref: string;
18
- };
19
- }
20
- //# sourceMappingURL=interfaces.d.ts.map
14
+ name: 'awsui.SideNavigation';
15
+ label: string;
16
+ properties: {
17
+ activeHref: string;
18
+ };
19
+ }
@@ -2,7 +2,15 @@
2
2
  import { InternalBaseComponentProps } from '../internal/hooks/use-base-component';
3
3
  import { SideNavigationProps } from './interfaces';
4
4
  type SideNavigationInternalProps = SideNavigationProps & InternalBaseComponentProps;
5
- export declare function SideNavigationImplementation({ header, itemsControl, activeHref, items, onFollow, onChange, __internalRootRef, ...props }: SideNavigationInternalProps): JSX.Element;
5
+ export declare function SideNavigationImplementation({
6
+ header,
7
+ itemsControl,
8
+ activeHref,
9
+ items,
10
+ onFollow,
11
+ onChange,
12
+ __internalRootRef,
13
+ ...props
14
+ }: SideNavigationInternalProps): JSX.Element;
6
15
  export declare const createWidgetizedSideNavigation: (Loader?: typeof SideNavigationImplementation | undefined) => typeof SideNavigationImplementation;
7
- export {};
8
- //# sourceMappingURL=implementation.d.ts.map
16
+ export {};
@@ -1,5 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import { SideNavigationProps } from './interfaces';
3
3
  export { SideNavigationProps };
4
- export default function SideNavigation({ items, ...props }: SideNavigationProps): JSX.Element;
5
- //# sourceMappingURL=index.d.ts.map
4
+ export default function SideNavigation({
5
+ items,
6
+ ...props
7
+ }: SideNavigationProps): JSX.Element;