@pega/cosmos-react-core 9.0.0-build.9.8 → 9.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1414) hide show
  1. package/lib/components/AIButton/AIButton.d.ts +3 -1
  2. package/lib/components/AIButton/AIButton.d.ts.map +1 -1
  3. package/lib/components/AIRewrite/AIRewrite.d.ts +4 -0
  4. package/lib/components/AIRewrite/AIRewrite.d.ts.map +1 -0
  5. package/lib/components/AIRewrite/AIRewrite.js +39 -0
  6. package/lib/components/AIRewrite/AIRewrite.js.map +1 -0
  7. package/lib/components/AIRewrite/AIRewrite.styles.d.ts +24 -0
  8. package/lib/components/AIRewrite/AIRewrite.styles.d.ts.map +1 -0
  9. package/lib/components/AIRewrite/AIRewrite.styles.js +24 -0
  10. package/lib/components/AIRewrite/AIRewrite.styles.js.map +1 -0
  11. package/lib/components/AIRewrite/AIRewrite.test-ids.d.ts +2 -0
  12. package/lib/components/AIRewrite/AIRewrite.test-ids.d.ts.map +1 -0
  13. package/lib/components/AIRewrite/AIRewrite.test-ids.js +10 -0
  14. package/lib/components/AIRewrite/AIRewrite.test-ids.js.map +1 -0
  15. package/lib/components/AIRewrite/AIRewrite.types.d.ts +21 -0
  16. package/lib/components/AIRewrite/AIRewrite.types.d.ts.map +1 -0
  17. package/lib/components/AIRewrite/AIRewrite.types.js +2 -0
  18. package/lib/components/AIRewrite/AIRewrite.types.js.map +1 -0
  19. package/lib/components/AIRewrite/index.d.ts +4 -0
  20. package/lib/components/AIRewrite/index.d.ts.map +1 -0
  21. package/lib/components/AIRewrite/index.js +3 -0
  22. package/lib/components/AIRewrite/index.js.map +1 -0
  23. package/lib/components/Actions/Actions.d.ts +2 -0
  24. package/lib/components/Actions/Actions.d.ts.map +1 -1
  25. package/lib/components/Actions/Actions.js +34 -8
  26. package/lib/components/Actions/Actions.js.map +1 -1
  27. package/lib/components/AdditionalInfo/AdditionalInfo.d.ts +1 -1
  28. package/lib/components/AdditionalInfo/AdditionalInfo.d.ts.map +1 -1
  29. package/lib/components/AppShell/AppHeader.d.ts.map +1 -1
  30. package/lib/components/AppShell/AppHeader.js +11 -2
  31. package/lib/components/AppShell/AppHeader.js.map +1 -1
  32. package/lib/components/AppShell/AppHeader.styles.d.ts +14 -12
  33. package/lib/components/AppShell/AppHeader.styles.d.ts.map +1 -1
  34. package/lib/components/AppShell/AppHeader.styles.js +36 -16
  35. package/lib/components/AppShell/AppHeader.styles.js.map +1 -1
  36. package/lib/components/AppShell/AppNavigationPanel.d.ts +14 -0
  37. package/lib/components/AppShell/AppNavigationPanel.d.ts.map +1 -0
  38. package/lib/components/AppShell/AppNavigationPanel.js +173 -0
  39. package/lib/components/AppShell/AppNavigationPanel.js.map +1 -0
  40. package/lib/components/AppShell/AppNavigationPanel.types.d.ts +28 -0
  41. package/lib/components/AppShell/AppNavigationPanel.types.d.ts.map +1 -0
  42. package/lib/components/AppShell/AppNavigationPanel.types.js +2 -0
  43. package/lib/components/AppShell/AppNavigationPanel.types.js.map +1 -0
  44. package/lib/components/AppShell/AppShell.d.ts +2 -5
  45. package/lib/components/AppShell/AppShell.d.ts.map +1 -1
  46. package/lib/components/AppShell/AppShell.js +213 -202
  47. package/lib/components/AppShell/AppShell.js.map +1 -1
  48. package/lib/components/AppShell/AppShell.styles.d.ts +243 -31
  49. package/lib/components/AppShell/AppShell.styles.d.ts.map +1 -1
  50. package/lib/components/AppShell/AppShell.styles.js +574 -128
  51. package/lib/components/AppShell/AppShell.styles.js.map +1 -1
  52. package/lib/components/AppShell/AppShell.types.d.ts +42 -5
  53. package/lib/components/AppShell/AppShell.types.d.ts.map +1 -1
  54. package/lib/components/AppShell/AppShell.types.js.map +1 -1
  55. package/lib/components/AppShell/AppShellContext.d.ts +6 -2
  56. package/lib/components/AppShell/AppShellContext.d.ts.map +1 -1
  57. package/lib/components/AppShell/AppShellContext.js +5 -9
  58. package/lib/components/AppShell/AppShellContext.js.map +1 -1
  59. package/lib/components/AppShell/AppShellList.styles.d.ts +14 -14
  60. package/lib/components/AppShell/AppShellList.styles.d.ts.map +1 -1
  61. package/lib/components/AppShell/AppShellList.styles.js +0 -1
  62. package/lib/components/AppShell/AppShellList.styles.js.map +1 -1
  63. package/lib/components/AppShell/AppShellSearch.d.ts.map +1 -1
  64. package/lib/components/AppShell/AppShellSearch.js +2 -4
  65. package/lib/components/AppShell/AppShellSearch.js.map +1 -1
  66. package/lib/components/AppShell/AppShellSearch.styles.d.ts +7 -5
  67. package/lib/components/AppShell/AppShellSearch.styles.d.ts.map +1 -1
  68. package/lib/components/AppShell/AppShellSearch.styles.js +3 -3
  69. package/lib/components/AppShell/AppShellSearch.styles.js.map +1 -1
  70. package/lib/components/AppShell/AppTopNav.d.ts +4 -0
  71. package/lib/components/AppShell/AppTopNav.d.ts.map +1 -0
  72. package/lib/components/AppShell/AppTopNav.js +183 -0
  73. package/lib/components/AppShell/AppTopNav.js.map +1 -0
  74. package/lib/components/AppShell/AppTopNav.styles.d.ts +946 -0
  75. package/lib/components/AppShell/AppTopNav.styles.d.ts.map +1 -0
  76. package/lib/components/AppShell/AppTopNav.styles.js +184 -0
  77. package/lib/components/AppShell/AppTopNav.styles.js.map +1 -0
  78. package/lib/components/AppShell/AppTopNav.types.d.ts +16 -0
  79. package/lib/components/AppShell/AppTopNav.types.d.ts.map +1 -0
  80. package/lib/components/AppShell/AppTopNav.types.js +2 -0
  81. package/lib/components/AppShell/AppTopNav.types.js.map +1 -0
  82. package/lib/components/AppShell/Drawer.d.ts +2 -1
  83. package/lib/components/AppShell/Drawer.d.ts.map +1 -1
  84. package/lib/components/AppShell/Drawer.js +15 -14
  85. package/lib/components/AppShell/Drawer.js.map +1 -1
  86. package/lib/components/AppShell/Drawer.styles.d.ts +22 -11
  87. package/lib/components/AppShell/Drawer.styles.d.ts.map +1 -1
  88. package/lib/components/AppShell/Drawer.styles.js +37 -40
  89. package/lib/components/AppShell/Drawer.styles.js.map +1 -1
  90. package/lib/components/AppShell/NavigationList.d.ts.map +1 -1
  91. package/lib/components/AppShell/NavigationList.js +17 -13
  92. package/lib/components/AppShell/NavigationList.js.map +1 -1
  93. package/lib/components/AppShell/NavigationListItemWrapper.d.ts.map +1 -1
  94. package/lib/components/AppShell/NavigationListItemWrapper.js +125 -65
  95. package/lib/components/AppShell/NavigationListItemWrapper.js.map +1 -1
  96. package/lib/components/AppShell/ThemeSwitcher.d.ts +11 -0
  97. package/lib/components/AppShell/ThemeSwitcher.d.ts.map +1 -0
  98. package/lib/components/AppShell/ThemeSwitcher.js +58 -0
  99. package/lib/components/AppShell/ThemeSwitcher.js.map +1 -0
  100. package/lib/components/AppShell/ThemeSwitcher.test-ids.d.ts +2 -0
  101. package/lib/components/AppShell/ThemeSwitcher.test-ids.d.ts.map +1 -0
  102. package/lib/components/AppShell/ThemeSwitcher.test-ids.js +3 -0
  103. package/lib/components/AppShell/ThemeSwitcher.test-ids.js.map +1 -0
  104. package/lib/components/AppShell/TopNavMoreMenu.d.ts +9 -0
  105. package/lib/components/AppShell/TopNavMoreMenu.d.ts.map +1 -0
  106. package/lib/components/AppShell/TopNavMoreMenu.js +73 -0
  107. package/lib/components/AppShell/TopNavMoreMenu.js.map +1 -0
  108. package/lib/components/AppShell/index.d.ts +2 -1
  109. package/lib/components/AppShell/index.d.ts.map +1 -1
  110. package/lib/components/AppShell/index.js +1 -0
  111. package/lib/components/AppShell/index.js.map +1 -1
  112. package/lib/components/AppShell/style-utils.d.ts +0 -1
  113. package/lib/components/AppShell/style-utils.d.ts.map +1 -1
  114. package/lib/components/AppShell/style-utils.js +0 -1
  115. package/lib/components/AppShell/style-utils.js.map +1 -1
  116. package/lib/components/AppShell/useTopNavOverflow.d.ts +17 -0
  117. package/lib/components/AppShell/useTopNavOverflow.d.ts.map +1 -0
  118. package/lib/components/AppShell/useTopNavOverflow.js +73 -0
  119. package/lib/components/AppShell/useTopNavOverflow.js.map +1 -0
  120. package/lib/components/AppShell/utils.d.ts +9 -0
  121. package/lib/components/AppShell/utils.d.ts.map +1 -1
  122. package/lib/components/AppShell/utils.js +16 -1
  123. package/lib/components/AppShell/utils.js.map +1 -1
  124. package/lib/components/Avatar/Avatar.d.ts +9 -5
  125. package/lib/components/Avatar/Avatar.d.ts.map +1 -1
  126. package/lib/components/Avatar/Avatar.js +13 -8
  127. package/lib/components/Avatar/Avatar.js.map +1 -1
  128. package/lib/components/Backdrop/Backdrop.d.ts +186 -3
  129. package/lib/components/Backdrop/Backdrop.d.ts.map +1 -1
  130. package/lib/components/Backdrop/Backdrop.js +20 -21
  131. package/lib/components/Backdrop/Backdrop.js.map +1 -1
  132. package/lib/components/Badges/Alert.d.ts +1 -1
  133. package/lib/components/Badges/Alert.d.ts.map +1 -1
  134. package/lib/components/Badges/Count.d.ts +4 -2
  135. package/lib/components/Badges/Count.d.ts.map +1 -1
  136. package/lib/components/Badges/Count.js +9 -3
  137. package/lib/components/Badges/Count.js.map +1 -1
  138. package/lib/components/Badges/Keyboard.d.ts +1 -1
  139. package/lib/components/Badges/Keyboard.d.ts.map +1 -1
  140. package/lib/components/Badges/Keyboard.js +8 -2
  141. package/lib/components/Badges/Keyboard.js.map +1 -1
  142. package/lib/components/Badges/Selection.d.ts +8 -4
  143. package/lib/components/Badges/Selection.d.ts.map +1 -1
  144. package/lib/components/Badges/Selection.js +23 -7
  145. package/lib/components/Badges/Selection.js.map +1 -1
  146. package/lib/components/Badges/Status.d.ts +2 -2
  147. package/lib/components/Badges/Status.d.ts.map +1 -1
  148. package/lib/components/Badges/Tag.d.ts +10 -2
  149. package/lib/components/Badges/Tag.d.ts.map +1 -1
  150. package/lib/components/Badges/Tag.js.map +1 -1
  151. package/lib/components/Banner/Banner.d.ts +10 -13
  152. package/lib/components/Banner/Banner.d.ts.map +1 -1
  153. package/lib/components/Banner/Banner.js +49 -102
  154. package/lib/components/Banner/Banner.js.map +1 -1
  155. package/lib/components/Banner/Banner.styles.d.ts +22 -0
  156. package/lib/components/Banner/Banner.styles.d.ts.map +1 -0
  157. package/lib/components/Banner/Banner.styles.js +84 -0
  158. package/lib/components/Banner/Banner.styles.js.map +1 -0
  159. package/lib/components/Breadcrumbs/Breadcrumbs.d.ts +2 -3
  160. package/lib/components/Breadcrumbs/Breadcrumbs.d.ts.map +1 -1
  161. package/lib/components/Button/BareButton.d.ts +1 -1
  162. package/lib/components/Button/BareButton.d.ts.map +1 -1
  163. package/lib/components/Button/BareButton.js +4 -1
  164. package/lib/components/Button/BareButton.js.map +1 -1
  165. package/lib/components/Button/BareRoleButton.d.ts +1 -1
  166. package/lib/components/Button/BareRoleButton.d.ts.map +1 -1
  167. package/lib/components/Button/Button.d.ts +7 -3
  168. package/lib/components/Button/Button.d.ts.map +1 -1
  169. package/lib/components/Button/Button.js +22 -8
  170. package/lib/components/Button/Button.js.map +1 -1
  171. package/lib/components/Card/Card.d.ts +3 -3
  172. package/lib/components/Card/Card.d.ts.map +1 -1
  173. package/lib/components/Card/Card.js +25 -25
  174. package/lib/components/Card/Card.js.map +1 -1
  175. package/lib/components/Card/Card.test-ids.d.ts +2 -0
  176. package/lib/components/Card/Card.test-ids.d.ts.map +1 -0
  177. package/lib/components/Card/Card.test-ids.js +3 -0
  178. package/lib/components/Card/Card.test-ids.js.map +1 -0
  179. package/lib/components/Card/CardContent.d.ts +1 -1
  180. package/lib/components/Card/CardContent.d.ts.map +1 -1
  181. package/lib/components/Card/CardContent.js +6 -1
  182. package/lib/components/Card/CardContent.js.map +1 -1
  183. package/lib/components/Card/CardFooter.d.ts +1 -1
  184. package/lib/components/Card/CardFooter.d.ts.map +1 -1
  185. package/lib/components/Card/CardFooter.js +4 -0
  186. package/lib/components/Card/CardFooter.js.map +1 -1
  187. package/lib/components/Card/CardHeader.d.ts +1 -1
  188. package/lib/components/Card/CardHeader.d.ts.map +1 -1
  189. package/lib/components/Card/CardHeader.js +19 -3
  190. package/lib/components/Card/CardHeader.js.map +1 -1
  191. package/lib/components/Card/CardMedia.d.ts +1 -1
  192. package/lib/components/Card/CardMedia.d.ts.map +1 -1
  193. package/lib/components/Checkbox/Checkbox.test-ids.d.ts +1 -1
  194. package/lib/components/Checkbox/Checkbox.test-ids.d.ts.map +1 -1
  195. package/lib/components/Checkbox/CheckboxCard.d.ts +11 -3
  196. package/lib/components/Checkbox/CheckboxCard.d.ts.map +1 -1
  197. package/lib/components/Checkbox/CheckboxCard.js +5 -22
  198. package/lib/components/Checkbox/CheckboxCard.js.map +1 -1
  199. package/lib/components/CheckboxGroup/CheckboxGroup.d.ts +7 -0
  200. package/lib/components/CheckboxGroup/CheckboxGroup.d.ts.map +1 -0
  201. package/lib/components/CheckboxGroup/CheckboxGroup.js +10 -0
  202. package/lib/components/CheckboxGroup/CheckboxGroup.js.map +1 -0
  203. package/lib/components/CheckboxGroup/index.d.ts +2 -1
  204. package/lib/components/CheckboxGroup/index.d.ts.map +1 -1
  205. package/lib/components/CheckboxGroup/index.js +1 -1
  206. package/lib/components/CheckboxGroup/index.js.map +1 -1
  207. package/lib/components/ClassificationMarking/ClassificationMarking.d.ts +6 -0
  208. package/lib/components/ClassificationMarking/ClassificationMarking.d.ts.map +1 -0
  209. package/lib/components/ClassificationMarking/ClassificationMarking.js +11 -0
  210. package/lib/components/ClassificationMarking/ClassificationMarking.js.map +1 -0
  211. package/lib/components/ClassificationMarking/ClassificationMarking.styles.d.ts +19 -0
  212. package/lib/components/ClassificationMarking/ClassificationMarking.styles.d.ts.map +1 -0
  213. package/lib/components/ClassificationMarking/ClassificationMarking.styles.js +66 -0
  214. package/lib/components/ClassificationMarking/ClassificationMarking.styles.js.map +1 -0
  215. package/lib/components/ClassificationMarking/ClassificationMarking.test-ids.d.ts +2 -0
  216. package/lib/components/ClassificationMarking/ClassificationMarking.test-ids.d.ts.map +1 -0
  217. package/lib/components/ClassificationMarking/ClassificationMarking.test-ids.js +7 -0
  218. package/lib/components/ClassificationMarking/ClassificationMarking.test-ids.js.map +1 -0
  219. package/lib/components/ClassificationMarking/ClassificationMarking.types.d.ts +19 -0
  220. package/lib/components/ClassificationMarking/ClassificationMarking.types.d.ts.map +1 -0
  221. package/lib/components/ClassificationMarking/ClassificationMarking.types.js +2 -0
  222. package/lib/components/ClassificationMarking/ClassificationMarking.types.js.map +1 -0
  223. package/lib/components/ClassificationMarking/index.d.ts +3 -0
  224. package/lib/components/ClassificationMarking/index.d.ts.map +1 -0
  225. package/lib/components/ClassificationMarking/index.js +2 -0
  226. package/lib/components/ClassificationMarking/index.js.map +1 -0
  227. package/lib/components/ComboBox/ComboBox.d.ts.map +1 -1
  228. package/lib/components/ComboBox/ComboBox.js +9 -8
  229. package/lib/components/ComboBox/ComboBox.js.map +1 -1
  230. package/lib/components/ComboBox/ComboBox.styles.d.ts +8 -3
  231. package/lib/components/ComboBox/ComboBox.styles.d.ts.map +1 -1
  232. package/lib/components/ComboBox/ComboBox.styles.js +33 -16
  233. package/lib/components/ComboBox/ComboBox.styles.js.map +1 -1
  234. package/lib/components/ComboBox/ComboBox.types.d.ts +1 -0
  235. package/lib/components/ComboBox/ComboBox.types.d.ts.map +1 -1
  236. package/lib/components/ComboBox/ComboBox.types.js.map +1 -1
  237. package/lib/components/ComboBox/MultiSelectInput/MultiSelectInput.d.ts +3 -1
  238. package/lib/components/ComboBox/MultiSelectInput/MultiSelectInput.d.ts.map +1 -1
  239. package/lib/components/ComboBox/MultiSelectInput/MultiSelectInput.js +84 -10
  240. package/lib/components/ComboBox/MultiSelectInput/MultiSelectInput.js.map +1 -1
  241. package/lib/components/ComboBox/MultiSelectInput/MultiSelectInput.types.d.ts +2 -0
  242. package/lib/components/ComboBox/MultiSelectInput/MultiSelectInput.types.d.ts.map +1 -1
  243. package/lib/components/ComboBox/MultiSelectInput/MultiSelectInput.types.js.map +1 -1
  244. package/lib/components/ComboBox/SingleSelectInput/SingleSelectInput.d.ts +3 -1
  245. package/lib/components/ComboBox/SingleSelectInput/SingleSelectInput.d.ts.map +1 -1
  246. package/lib/components/ComboBox/SingleSelectInput/SingleSelectInput.js +33 -4
  247. package/lib/components/ComboBox/SingleSelectInput/SingleSelectInput.js.map +1 -1
  248. package/lib/components/ComboBox/SingleSelectInput/SingleSelectInput.types.d.ts +2 -0
  249. package/lib/components/ComboBox/SingleSelectInput/SingleSelectInput.types.d.ts.map +1 -1
  250. package/lib/components/ComboBox/SingleSelectInput/SingleSelectInput.types.js.map +1 -1
  251. package/lib/components/ComboBox/index.d.ts +1 -0
  252. package/lib/components/ComboBox/index.d.ts.map +1 -1
  253. package/lib/components/ComboBox/index.js +1 -0
  254. package/lib/components/ComboBox/index.js.map +1 -1
  255. package/lib/components/CompositeInput/CompositeInput.d.ts.map +1 -1
  256. package/lib/components/CompositeInput/CompositeInput.js +7 -9
  257. package/lib/components/CompositeInput/CompositeInput.js.map +1 -1
  258. package/lib/components/CompositeInput/CompositeInput.styles.d.ts +8 -3
  259. package/lib/components/CompositeInput/CompositeInput.styles.d.ts.map +1 -1
  260. package/lib/components/CompositeInput/CompositeInput.styles.js +31 -1
  261. package/lib/components/CompositeInput/CompositeInput.styles.js.map +1 -1
  262. package/lib/components/Configuration/Configuration.d.ts +8 -3
  263. package/lib/components/Configuration/Configuration.d.ts.map +1 -1
  264. package/lib/components/Configuration/Configuration.js +17 -3
  265. package/lib/components/Configuration/Configuration.js.map +1 -1
  266. package/lib/components/Configuration/LocaleOverride.d.ts +10 -0
  267. package/lib/components/Configuration/LocaleOverride.d.ts.map +1 -0
  268. package/lib/components/Configuration/LocaleOverride.js +23 -0
  269. package/lib/components/Configuration/LocaleOverride.js.map +1 -0
  270. package/lib/components/Configuration/index.d.ts +2 -0
  271. package/lib/components/Configuration/index.d.ts.map +1 -1
  272. package/lib/components/Configuration/index.js +1 -0
  273. package/lib/components/Configuration/index.js.map +1 -1
  274. package/lib/components/CreditCard/CreditCard.types.d.ts +4 -0
  275. package/lib/components/CreditCard/CreditCard.types.d.ts.map +1 -1
  276. package/lib/components/CreditCard/CreditCard.types.js.map +1 -1
  277. package/lib/components/CreditCard/CreditCardInput.d.ts +2 -1
  278. package/lib/components/CreditCard/CreditCardInput.d.ts.map +1 -1
  279. package/lib/components/CreditCard/CreditCardInput.js +1 -1
  280. package/lib/components/CreditCard/CreditCardInput.js.map +1 -1
  281. package/lib/components/Currency/CurrencyInput.js +1 -1
  282. package/lib/components/Currency/CurrencyInput.js.map +1 -1
  283. package/lib/components/Currency/CurrencyInput.styles.d.ts +4 -2
  284. package/lib/components/Currency/CurrencyInput.styles.d.ts.map +1 -1
  285. package/lib/components/DangerButton/DangerButton.d.ts +3 -1
  286. package/lib/components/DangerButton/DangerButton.d.ts.map +1 -1
  287. package/lib/components/DateTime/DateTime.types.d.ts +7 -1
  288. package/lib/components/DateTime/DateTime.types.d.ts.map +1 -1
  289. package/lib/components/DateTime/DateTime.types.js.map +1 -1
  290. package/lib/components/DateTime/DateTimeDisplay.d.ts +1 -1
  291. package/lib/components/DateTime/DateTimeDisplay.d.ts.map +1 -1
  292. package/lib/components/DateTime/Input/DateInput.d.ts +7 -2
  293. package/lib/components/DateTime/Input/DateInput.d.ts.map +1 -1
  294. package/lib/components/DateTime/Input/DateInput.js +16 -8
  295. package/lib/components/DateTime/Input/DateInput.js.map +1 -1
  296. package/lib/components/DateTime/Input/DateRangeInput.d.ts.map +1 -1
  297. package/lib/components/DateTime/Input/DateRangeInput.js +10 -4
  298. package/lib/components/DateTime/Input/DateRangeInput.js.map +1 -1
  299. package/lib/components/DateTime/Input/DateTime.styles.d.ts +11 -7
  300. package/lib/components/DateTime/Input/DateTime.styles.d.ts.map +1 -1
  301. package/lib/components/DateTime/Input/DateTime.styles.js +5 -2
  302. package/lib/components/DateTime/Input/DateTime.styles.js.map +1 -1
  303. package/lib/components/DateTime/Input/DateTimeInput.d.ts +4 -2
  304. package/lib/components/DateTime/Input/DateTimeInput.d.ts.map +1 -1
  305. package/lib/components/DateTime/Input/DateTimeInput.js +20 -14
  306. package/lib/components/DateTime/Input/DateTimeInput.js.map +1 -1
  307. package/lib/components/DateTime/Input/DayOfWeekInput.d.ts.map +1 -1
  308. package/lib/components/DateTime/Input/DayOfWeekInput.js.map +1 -1
  309. package/lib/components/DateTime/Input/Duration/DurationInput.d.ts.map +1 -1
  310. package/lib/components/DateTime/Input/Duration/DurationInput.js +2 -4
  311. package/lib/components/DateTime/Input/Duration/DurationInput.js.map +1 -1
  312. package/lib/components/DateTime/Input/Duration/NumberUnit.d.ts +3 -1
  313. package/lib/components/DateTime/Input/Duration/NumberUnit.d.ts.map +1 -1
  314. package/lib/components/DateTime/Input/MonthInput.d.ts +3 -1
  315. package/lib/components/DateTime/Input/MonthInput.d.ts.map +1 -1
  316. package/lib/components/DateTime/Input/MonthInput.js +6 -8
  317. package/lib/components/DateTime/Input/MonthInput.js.map +1 -1
  318. package/lib/components/DateTime/Input/PartInput.d.ts.map +1 -1
  319. package/lib/components/DateTime/Input/PartInput.js +21 -12
  320. package/lib/components/DateTime/Input/PartInput.js.map +1 -1
  321. package/lib/components/DateTime/Input/QuarterInput.d.ts +3 -1
  322. package/lib/components/DateTime/Input/QuarterInput.d.ts.map +1 -1
  323. package/lib/components/DateTime/Input/QuarterInput.js +2 -2
  324. package/lib/components/DateTime/Input/QuarterInput.js.map +1 -1
  325. package/lib/components/DateTime/Input/TimeInput.d.ts +3 -1
  326. package/lib/components/DateTime/Input/TimeInput.d.ts.map +1 -1
  327. package/lib/components/DateTime/Input/TimeInput.js +3 -3
  328. package/lib/components/DateTime/Input/TimeInput.js.map +1 -1
  329. package/lib/components/DateTime/Input/TimeRangeInput.d.ts.map +1 -1
  330. package/lib/components/DateTime/Input/TimeRangeInput.js +9 -4
  331. package/lib/components/DateTime/Input/TimeRangeInput.js.map +1 -1
  332. package/lib/components/DateTime/Input/WeekInput.d.ts +3 -1
  333. package/lib/components/DateTime/Input/WeekInput.d.ts.map +1 -1
  334. package/lib/components/DateTime/Input/WeekInput.js +23 -12
  335. package/lib/components/DateTime/Input/WeekInput.js.map +1 -1
  336. package/lib/components/DateTime/Input/local.d.ts +10 -9
  337. package/lib/components/DateTime/Input/local.d.ts.map +1 -1
  338. package/lib/components/DateTime/Input/local.js.map +1 -1
  339. package/lib/components/DateTime/Input/utils.d.ts +11 -11
  340. package/lib/components/DateTime/Input/utils.d.ts.map +1 -1
  341. package/lib/components/DateTime/Input/utils.js +77 -48
  342. package/lib/components/DateTime/Input/utils.js.map +1 -1
  343. package/lib/components/DateTime/Picker/Calendar.d.ts +4 -1
  344. package/lib/components/DateTime/Picker/Calendar.d.ts.map +1 -1
  345. package/lib/components/DateTime/Picker/Calendar.js +28 -26
  346. package/lib/components/DateTime/Picker/Calendar.js.map +1 -1
  347. package/lib/components/DateTime/Picker/Calendar.styles.d.ts +14 -8
  348. package/lib/components/DateTime/Picker/Calendar.styles.d.ts.map +1 -1
  349. package/lib/components/DateTime/Picker/Calendar.styles.js +6 -1
  350. package/lib/components/DateTime/Picker/Calendar.styles.js.map +1 -1
  351. package/lib/components/DateTime/Picker/DatePicker.d.ts.map +1 -1
  352. package/lib/components/DateTime/Picker/DatePicker.js +15 -15
  353. package/lib/components/DateTime/Picker/DatePicker.js.map +1 -1
  354. package/lib/components/DateTime/Picker/DatePicker.styles.d.ts +8 -4
  355. package/lib/components/DateTime/Picker/DatePicker.styles.d.ts.map +1 -1
  356. package/lib/components/DateTime/Picker/DatePicker.styles.js +5 -4
  357. package/lib/components/DateTime/Picker/DatePicker.styles.js.map +1 -1
  358. package/lib/components/DateTime/Picker/DatePicker.types.d.ts +11 -1
  359. package/lib/components/DateTime/Picker/DatePicker.types.d.ts.map +1 -1
  360. package/lib/components/DateTime/Picker/DatePicker.types.js.map +1 -1
  361. package/lib/components/DateTime/Picker/DateRangePicker.d.ts.map +1 -1
  362. package/lib/components/DateTime/Picker/DateRangePicker.js +15 -15
  363. package/lib/components/DateTime/Picker/DateRangePicker.js.map +1 -1
  364. package/lib/components/DateTime/Picker/TimePicker.d.ts +2 -0
  365. package/lib/components/DateTime/Picker/TimePicker.d.ts.map +1 -1
  366. package/lib/components/DateTime/Picker/TimePicker.js +19 -11
  367. package/lib/components/DateTime/Picker/TimePicker.js.map +1 -1
  368. package/lib/components/DateTime/Picker/Weeks.d.ts +3 -2
  369. package/lib/components/DateTime/Picker/Weeks.d.ts.map +1 -1
  370. package/lib/components/DateTime/Picker/Weeks.js +7 -7
  371. package/lib/components/DateTime/Picker/Weeks.js.map +1 -1
  372. package/lib/components/DateTime/Picker/utils.d.ts +4 -3
  373. package/lib/components/DateTime/Picker/utils.d.ts.map +1 -1
  374. package/lib/components/DateTime/Picker/utils.js.map +1 -1
  375. package/lib/components/DateTime/utils.d.ts +8 -1
  376. package/lib/components/DateTime/utils.d.ts.map +1 -1
  377. package/lib/components/DateTime/utils.js +86 -82
  378. package/lib/components/DateTime/utils.js.map +1 -1
  379. package/lib/components/Dialog/Dialog.styles.d.ts +5 -5
  380. package/lib/components/Dialog/Dialog.styles.d.ts.map +1 -1
  381. package/lib/components/Dialog/Dialog.styles.js +7 -0
  382. package/lib/components/Dialog/Dialog.styles.js.map +1 -1
  383. package/lib/components/Dialog/Dialog.types.d.ts +5 -2
  384. package/lib/components/Dialog/Dialog.types.d.ts.map +1 -1
  385. package/lib/components/Dialog/Dialog.types.js.map +1 -1
  386. package/lib/components/Dialog/FormDialog.d.ts +3 -1
  387. package/lib/components/Dialog/FormDialog.d.ts.map +1 -1
  388. package/lib/components/Dialog/FormDialog.js +20 -15
  389. package/lib/components/Dialog/FormDialog.js.map +1 -1
  390. package/lib/components/Dialog/InfoDialog.d.ts.map +1 -1
  391. package/lib/components/Dialog/InfoDialog.js +15 -14
  392. package/lib/components/Dialog/InfoDialog.js.map +1 -1
  393. package/lib/components/Dialog/InfoDialog.styles.d.ts +6 -2
  394. package/lib/components/Dialog/InfoDialog.styles.d.ts.map +1 -1
  395. package/lib/components/Drawer/Drawer.d.ts +2 -2
  396. package/lib/components/Drawer/Drawer.d.ts.map +1 -1
  397. package/lib/components/Drawer/Drawer.js +9 -0
  398. package/lib/components/Drawer/Drawer.js.map +1 -1
  399. package/lib/components/Drawer/ResizeHandle.d.ts +2 -1
  400. package/lib/components/Drawer/ResizeHandle.d.ts.map +1 -1
  401. package/lib/components/Drawer/ResizeHandle.js +3 -2
  402. package/lib/components/Drawer/ResizeHandle.js.map +1 -1
  403. package/lib/components/EmojiPicker/EmojiPicker.styles.d.ts +2 -2
  404. package/lib/components/EmojiPicker/EmojiPicker.styles.d.ts.map +1 -1
  405. package/lib/components/EmojiPicker/EmojiPicker.styles.js +1 -1
  406. package/lib/components/EmojiPicker/EmojiPicker.styles.js.map +1 -1
  407. package/lib/components/EmptyState/EmptyState.d.ts +1 -1
  408. package/lib/components/EmptyState/EmptyState.d.ts.map +1 -1
  409. package/lib/components/ErrorState/ErrorState.d.ts +1 -1
  410. package/lib/components/ErrorState/ErrorState.d.ts.map +1 -1
  411. package/lib/components/ExpandCollapse/ExpandCollapseButton.d.ts +32 -0
  412. package/lib/components/ExpandCollapse/ExpandCollapseButton.d.ts.map +1 -0
  413. package/lib/components/ExpandCollapse/ExpandCollapseButton.js +81 -0
  414. package/lib/components/ExpandCollapse/ExpandCollapseButton.js.map +1 -0
  415. package/lib/components/ExpandCollapse/index.d.ts +2 -0
  416. package/lib/components/ExpandCollapse/index.d.ts.map +1 -1
  417. package/lib/components/ExpandCollapse/index.js +1 -0
  418. package/lib/components/ExpandCollapse/index.js.map +1 -1
  419. package/lib/components/FieldGroup/FieldGroup.d.ts +381 -8
  420. package/lib/components/FieldGroup/FieldGroup.d.ts.map +1 -1
  421. package/lib/components/FieldGroup/FieldGroup.js +27 -22
  422. package/lib/components/FieldGroup/FieldGroup.js.map +1 -1
  423. package/lib/components/FieldGroup/FieldGroupList.d.ts +2 -2
  424. package/lib/components/FieldGroup/FieldGroupList.d.ts.map +1 -1
  425. package/lib/components/FieldGroup/FieldGroupList.js +61 -48
  426. package/lib/components/FieldGroup/FieldGroupList.js.map +1 -1
  427. package/lib/components/FieldValueList/FieldValueList.d.ts +13 -4
  428. package/lib/components/FieldValueList/FieldValueList.d.ts.map +1 -1
  429. package/lib/components/FieldValueList/FieldValueList.js +20 -9
  430. package/lib/components/FieldValueList/FieldValueList.js.map +1 -1
  431. package/lib/components/FieldValueList/index.d.ts +1 -1
  432. package/lib/components/FieldValueList/index.d.ts.map +1 -1
  433. package/lib/components/FieldValueList/index.js +1 -1
  434. package/lib/components/FieldValueList/index.js.map +1 -1
  435. package/lib/components/File/FileDisplay.d.ts +1 -1
  436. package/lib/components/File/FileDisplay.d.ts.map +1 -1
  437. package/lib/components/File/FileDisplay.js +2 -2
  438. package/lib/components/File/FileDisplay.js.map +1 -1
  439. package/lib/components/File/FileInput.d.ts.map +1 -1
  440. package/lib/components/File/FileInput.js +11 -21
  441. package/lib/components/File/FileInput.js.map +1 -1
  442. package/lib/components/File/FileInput.styles.d.ts +753 -17
  443. package/lib/components/File/FileInput.styles.d.ts.map +1 -1
  444. package/lib/components/File/FileInput.styles.js +16 -18
  445. package/lib/components/File/FileInput.styles.js.map +1 -1
  446. package/lib/components/File/FileItem.d.ts +11 -3
  447. package/lib/components/File/FileItem.d.ts.map +1 -1
  448. package/lib/components/File/FileItem.js +29 -12
  449. package/lib/components/File/FileItem.js.map +1 -1
  450. package/lib/components/File/FileList.d.ts +184 -2
  451. package/lib/components/File/FileList.d.ts.map +1 -1
  452. package/lib/components/File/FileList.js.map +1 -1
  453. package/lib/components/File/FileUploadItem.js +1 -1
  454. package/lib/components/File/FileUploadItem.js.map +1 -1
  455. package/lib/components/File/FileVisual.d.ts +4 -3
  456. package/lib/components/File/FileVisual.d.ts.map +1 -1
  457. package/lib/components/Flex/Flex.d.ts +1 -1
  458. package/lib/components/Flex/Flex.d.ts.map +1 -1
  459. package/lib/components/Flex/Flex.js +1 -1
  460. package/lib/components/Flex/Flex.js.map +1 -1
  461. package/lib/components/FormControl/FormControl.d.ts +2 -2
  462. package/lib/components/FormControl/FormControl.d.ts.map +1 -1
  463. package/lib/components/FormControl/FormControl.js +65 -54
  464. package/lib/components/FormControl/FormControl.js.map +1 -1
  465. package/lib/components/FormField/FormField.d.ts +12 -5
  466. package/lib/components/FormField/FormField.d.ts.map +1 -1
  467. package/lib/components/FormField/FormField.js +98 -61
  468. package/lib/components/FormField/FormField.js.map +1 -1
  469. package/lib/components/FormField/index.d.ts +1 -1
  470. package/lib/components/FormField/index.d.ts.map +1 -1
  471. package/lib/components/FormField/index.js +1 -1
  472. package/lib/components/FormField/index.js.map +1 -1
  473. package/lib/components/Fullscreen/Fullscreen.d.ts +3 -5
  474. package/lib/components/Fullscreen/Fullscreen.d.ts.map +1 -1
  475. package/lib/components/Fullscreen/Fullscreen.js +12 -8
  476. package/lib/components/Fullscreen/Fullscreen.js.map +1 -1
  477. package/lib/components/Fullscreen/FullscreenButton.d.ts +3 -1
  478. package/lib/components/Fullscreen/FullscreenButton.d.ts.map +1 -1
  479. package/lib/components/Grid/Grid.d.ts +1 -1
  480. package/lib/components/Grid/Grid.d.ts.map +1 -1
  481. package/lib/components/HTML/HTML.d.ts +3 -3
  482. package/lib/components/HTML/HTML.d.ts.map +1 -1
  483. package/lib/components/HTML/HTML.js +11 -5
  484. package/lib/components/HTML/HTML.js.map +1 -1
  485. package/lib/components/HiddenText/HiddenText.d.ts +1 -1
  486. package/lib/components/HiddenText/HiddenText.d.ts.map +1 -1
  487. package/lib/components/Icon/Icon.d.ts +4 -4
  488. package/lib/components/Icon/Icon.d.ts.map +1 -1
  489. package/lib/components/Icon/Icon.js +7 -2
  490. package/lib/components/Icon/Icon.js.map +1 -1
  491. package/lib/components/Icon/iconNames.d.ts +1 -1
  492. package/lib/components/Icon/iconNames.d.ts.map +1 -1
  493. package/lib/components/Icon/iconNames.js +17 -0
  494. package/lib/components/Icon/iconNames.js.map +1 -1
  495. package/lib/components/Icon/icons/arrow-micro-left-right-reverse.icon.d.ts +5 -0
  496. package/lib/components/Icon/icons/arrow-micro-left-right-reverse.icon.d.ts.map +1 -0
  497. package/lib/components/Icon/icons/arrow-micro-left-right-reverse.icon.js +7 -0
  498. package/lib/components/Icon/icons/arrow-micro-left-right-reverse.icon.js.map +1 -0
  499. package/lib/components/Icon/icons/arrow-micro-left-right.icon.d.ts +5 -0
  500. package/lib/components/Icon/icons/arrow-micro-left-right.icon.d.ts.map +1 -0
  501. package/lib/components/Icon/icons/arrow-micro-left-right.icon.js +7 -0
  502. package/lib/components/Icon/icons/arrow-micro-left-right.icon.js.map +1 -0
  503. package/lib/components/Icon/icons/brain.icon.d.ts +5 -0
  504. package/lib/components/Icon/icons/brain.icon.d.ts.map +1 -0
  505. package/lib/components/Icon/icons/brain.icon.js +7 -0
  506. package/lib/components/Icon/icons/brain.icon.js.map +1 -0
  507. package/lib/components/Icon/icons/chats-ai.icon.d.ts +5 -0
  508. package/lib/components/Icon/icons/chats-ai.icon.d.ts.map +1 -0
  509. package/lib/components/Icon/icons/chats-ai.icon.js +7 -0
  510. package/lib/components/Icon/icons/chats-ai.icon.js.map +1 -0
  511. package/lib/components/Icon/icons/check-solid.icon.d.ts +5 -0
  512. package/lib/components/Icon/icons/check-solid.icon.d.ts.map +1 -0
  513. package/lib/components/Icon/icons/check-solid.icon.js +7 -0
  514. package/lib/components/Icon/icons/check-solid.icon.js.map +1 -0
  515. package/lib/components/Icon/icons/clock-sla.icon.d.ts +5 -0
  516. package/lib/components/Icon/icons/clock-sla.icon.d.ts.map +1 -0
  517. package/lib/components/Icon/icons/clock-sla.icon.js +7 -0
  518. package/lib/components/Icon/icons/clock-sla.icon.js.map +1 -0
  519. package/lib/components/Icon/icons/csr-connected.icon.d.ts +5 -0
  520. package/lib/components/Icon/icons/csr-connected.icon.d.ts.map +1 -0
  521. package/lib/components/Icon/icons/csr-connected.icon.js +7 -0
  522. package/lib/components/Icon/icons/csr-connected.icon.js.map +1 -0
  523. package/lib/components/Icon/icons/dataviz-string-field.icon.d.ts.map +1 -1
  524. package/lib/components/Icon/icons/dataviz-string-field.icon.js +1 -1
  525. package/lib/components/Icon/icons/dataviz-string-field.icon.js.map +1 -1
  526. package/lib/components/Icon/icons/gear-box-dotted.icon.d.ts +5 -0
  527. package/lib/components/Icon/icons/gear-box-dotted.icon.d.ts.map +1 -0
  528. package/lib/components/Icon/icons/gear-box-dotted.icon.js +7 -0
  529. package/lib/components/Icon/icons/gear-box-dotted.icon.js.map +1 -0
  530. package/lib/components/Icon/icons/information-solid.icon.js +1 -1
  531. package/lib/components/Icon/icons/information-solid.icon.js.map +1 -1
  532. package/lib/components/Icon/icons/information.icon.js +1 -1
  533. package/lib/components/Icon/icons/information.icon.js.map +1 -1
  534. package/lib/components/Icon/icons/input-pen.icon.d.ts +5 -0
  535. package/lib/components/Icon/icons/input-pen.icon.d.ts.map +1 -0
  536. package/lib/components/Icon/icons/input-pen.icon.js +7 -0
  537. package/lib/components/Icon/icons/input-pen.icon.js.map +1 -0
  538. package/lib/components/Icon/icons/mcp.icon.d.ts +5 -0
  539. package/lib/components/Icon/icons/mcp.icon.d.ts.map +1 -0
  540. package/lib/components/Icon/icons/mcp.icon.js +7 -0
  541. package/lib/components/Icon/icons/mcp.icon.js.map +1 -0
  542. package/lib/components/Icon/icons/open.icon.d.ts.map +1 -1
  543. package/lib/components/Icon/icons/open.icon.js +2 -2
  544. package/lib/components/Icon/icons/open.icon.js.map +1 -1
  545. package/lib/components/Icon/icons/preview-bottom.icon.d.ts +5 -0
  546. package/lib/components/Icon/icons/preview-bottom.icon.d.ts.map +1 -0
  547. package/lib/components/Icon/icons/preview-bottom.icon.js +7 -0
  548. package/lib/components/Icon/icons/preview-bottom.icon.js.map +1 -0
  549. package/lib/components/Icon/icons/preview-collapse.icon.d.ts +5 -0
  550. package/lib/components/Icon/icons/preview-collapse.icon.d.ts.map +1 -0
  551. package/lib/components/Icon/icons/preview-collapse.icon.js +7 -0
  552. package/lib/components/Icon/icons/preview-collapse.icon.js.map +1 -0
  553. package/lib/components/Icon/icons/preview-expand.icon.d.ts +5 -0
  554. package/lib/components/Icon/icons/preview-expand.icon.d.ts.map +1 -0
  555. package/lib/components/Icon/icons/preview-expand.icon.js +7 -0
  556. package/lib/components/Icon/icons/preview-expand.icon.js.map +1 -0
  557. package/lib/components/Icon/icons/preview-hide.icon.d.ts +5 -0
  558. package/lib/components/Icon/icons/preview-hide.icon.d.ts.map +1 -0
  559. package/lib/components/Icon/icons/preview-hide.icon.js +7 -0
  560. package/lib/components/Icon/icons/preview-hide.icon.js.map +1 -0
  561. package/lib/components/Icon/icons/preview-rtl.icon.d.ts +5 -0
  562. package/lib/components/Icon/icons/preview-rtl.icon.d.ts.map +1 -0
  563. package/lib/components/Icon/icons/preview-rtl.icon.js +7 -0
  564. package/lib/components/Icon/icons/preview-rtl.icon.js.map +1 -0
  565. package/lib/components/Icon/icons/script-solid.icon.d.ts +5 -0
  566. package/lib/components/Icon/icons/script-solid.icon.d.ts.map +1 -0
  567. package/lib/components/Icon/icons/script-solid.icon.js +7 -0
  568. package/lib/components/Icon/icons/script-solid.icon.js.map +1 -0
  569. package/lib/components/Icon/icons/user-laptop.icon.d.ts +5 -0
  570. package/lib/components/Icon/icons/user-laptop.icon.d.ts.map +1 -0
  571. package/lib/components/Icon/icons/user-laptop.icon.js +7 -0
  572. package/lib/components/Icon/icons/user-laptop.icon.js.map +1 -0
  573. package/lib/components/Icon/index.d.ts +1 -1
  574. package/lib/components/Icon/index.d.ts.map +1 -1
  575. package/lib/components/Icon/index.js +1 -1
  576. package/lib/components/Icon/index.js.map +1 -1
  577. package/lib/components/Icon/streamline-icons/animal-print.icon.d.ts +5 -0
  578. package/lib/components/Icon/streamline-icons/animal-print.icon.d.ts.map +1 -0
  579. package/lib/components/Icon/streamline-icons/animal-print.icon.js +7 -0
  580. package/lib/components/Icon/streamline-icons/animal-print.icon.js.map +1 -0
  581. package/lib/components/Icon/streamline-icons/boat-cargo.icon.d.ts +5 -0
  582. package/lib/components/Icon/streamline-icons/boat-cargo.icon.d.ts.map +1 -0
  583. package/lib/components/Icon/streamline-icons/boat-cargo.icon.js +7 -0
  584. package/lib/components/Icon/streamline-icons/boat-cargo.icon.js.map +1 -0
  585. package/lib/components/Icon/streamline-icons/bolt-solid.icon.d.ts +5 -0
  586. package/lib/components/Icon/streamline-icons/bolt-solid.icon.d.ts.map +1 -0
  587. package/lib/components/Icon/streamline-icons/bolt-solid.icon.js +7 -0
  588. package/lib/components/Icon/streamline-icons/bolt-solid.icon.js.map +1 -0
  589. package/lib/components/Icon/streamline-icons/bolt.icon.d.ts +5 -0
  590. package/lib/components/Icon/streamline-icons/bolt.icon.d.ts.map +1 -0
  591. package/lib/components/Icon/streamline-icons/bolt.icon.js +7 -0
  592. package/lib/components/Icon/streamline-icons/bolt.icon.js.map +1 -0
  593. package/lib/components/Icon/streamline-icons/browser-site.icon.d.ts +5 -0
  594. package/lib/components/Icon/streamline-icons/browser-site.icon.d.ts.map +1 -0
  595. package/lib/components/Icon/streamline-icons/browser-site.icon.js +7 -0
  596. package/lib/components/Icon/streamline-icons/browser-site.icon.js.map +1 -0
  597. package/lib/components/Icon/streamline-icons/building-globe.icon.d.ts +5 -0
  598. package/lib/components/Icon/streamline-icons/building-globe.icon.d.ts.map +1 -0
  599. package/lib/components/Icon/streamline-icons/building-globe.icon.js +7 -0
  600. package/lib/components/Icon/streamline-icons/building-globe.icon.js.map +1 -0
  601. package/lib/components/Icon/streamline-icons/check-polaris-solid.icon.d.ts +5 -0
  602. package/lib/components/Icon/streamline-icons/check-polaris-solid.icon.d.ts.map +1 -0
  603. package/lib/components/Icon/streamline-icons/check-polaris-solid.icon.js +7 -0
  604. package/lib/components/Icon/streamline-icons/check-polaris-solid.icon.js.map +1 -0
  605. package/lib/components/Icon/streamline-icons/chess.icon.d.ts +5 -0
  606. package/lib/components/Icon/streamline-icons/chess.icon.d.ts.map +1 -0
  607. package/lib/components/Icon/streamline-icons/chess.icon.js +7 -0
  608. package/lib/components/Icon/streamline-icons/chess.icon.js.map +1 -0
  609. package/lib/components/Icon/streamline-icons/clock-sla.icon.d.ts +5 -0
  610. package/lib/components/Icon/streamline-icons/clock-sla.icon.d.ts.map +1 -0
  611. package/lib/components/Icon/streamline-icons/clock-sla.icon.js +7 -0
  612. package/lib/components/Icon/streamline-icons/clock-sla.icon.js.map +1 -0
  613. package/lib/components/Icon/streamline-icons/cloud-nodes.icon.d.ts +5 -0
  614. package/lib/components/Icon/streamline-icons/cloud-nodes.icon.d.ts.map +1 -0
  615. package/lib/components/Icon/streamline-icons/cloud-nodes.icon.js +7 -0
  616. package/lib/components/Icon/streamline-icons/cloud-nodes.icon.js.map +1 -0
  617. package/lib/components/Icon/streamline-icons/confetti.icon.d.ts +5 -0
  618. package/lib/components/Icon/streamline-icons/confetti.icon.d.ts.map +1 -0
  619. package/lib/components/Icon/streamline-icons/confetti.icon.js +7 -0
  620. package/lib/components/Icon/streamline-icons/confetti.icon.js.map +1 -0
  621. package/lib/components/Icon/streamline-icons/conveyor-cargo.icon.d.ts +5 -0
  622. package/lib/components/Icon/streamline-icons/conveyor-cargo.icon.d.ts.map +1 -0
  623. package/lib/components/Icon/streamline-icons/conveyor-cargo.icon.js +7 -0
  624. package/lib/components/Icon/streamline-icons/conveyor-cargo.icon.js.map +1 -0
  625. package/lib/components/Icon/streamline-icons/cpu-chip.icon.d.ts +5 -0
  626. package/lib/components/Icon/streamline-icons/cpu-chip.icon.d.ts.map +1 -0
  627. package/lib/components/Icon/streamline-icons/cpu-chip.icon.js +7 -0
  628. package/lib/components/Icon/streamline-icons/cpu-chip.icon.js.map +1 -0
  629. package/lib/components/Icon/streamline-icons/desktop-pencil.icon.d.ts +5 -0
  630. package/lib/components/Icon/streamline-icons/desktop-pencil.icon.d.ts.map +1 -0
  631. package/lib/components/Icon/streamline-icons/desktop-pencil.icon.js +7 -0
  632. package/lib/components/Icon/streamline-icons/desktop-pencil.icon.js.map +1 -0
  633. package/lib/components/Icon/streamline-icons/disc-document.icon.d.ts +5 -0
  634. package/lib/components/Icon/streamline-icons/disc-document.icon.d.ts.map +1 -0
  635. package/lib/components/Icon/streamline-icons/disc-document.icon.js +7 -0
  636. package/lib/components/Icon/streamline-icons/disc-document.icon.js.map +1 -0
  637. package/lib/components/Icon/streamline-icons/disc-nodes.icon.d.ts +5 -0
  638. package/lib/components/Icon/streamline-icons/disc-nodes.icon.d.ts.map +1 -0
  639. package/lib/components/Icon/streamline-icons/disc-nodes.icon.js +7 -0
  640. package/lib/components/Icon/streamline-icons/disc-nodes.icon.js.map +1 -0
  641. package/lib/components/Icon/streamline-icons/doc-ai.icon.d.ts +5 -0
  642. package/lib/components/Icon/streamline-icons/doc-ai.icon.d.ts.map +1 -0
  643. package/lib/components/Icon/streamline-icons/doc-ai.icon.js +7 -0
  644. package/lib/components/Icon/streamline-icons/doc-ai.icon.js.map +1 -0
  645. package/lib/components/Icon/streamline-icons/document-json.icon.d.ts +5 -0
  646. package/lib/components/Icon/streamline-icons/document-json.icon.d.ts.map +1 -0
  647. package/lib/components/Icon/streamline-icons/document-json.icon.js +7 -0
  648. package/lib/components/Icon/streamline-icons/document-json.icon.js.map +1 -0
  649. package/lib/components/Icon/streamline-icons/exchange-case-user.icon.d.ts +5 -0
  650. package/lib/components/Icon/streamline-icons/exchange-case-user.icon.d.ts.map +1 -0
  651. package/lib/components/Icon/streamline-icons/exchange-case-user.icon.js +7 -0
  652. package/lib/components/Icon/streamline-icons/exchange-case-user.icon.js.map +1 -0
  653. package/lib/components/Icon/streamline-icons/exchange-cases.icon.d.ts +5 -0
  654. package/lib/components/Icon/streamline-icons/exchange-cases.icon.d.ts.map +1 -0
  655. package/lib/components/Icon/streamline-icons/exchange-cases.icon.js +7 -0
  656. package/lib/components/Icon/streamline-icons/exchange-cases.icon.js.map +1 -0
  657. package/lib/components/Icon/streamline-icons/factory.icon.d.ts +5 -0
  658. package/lib/components/Icon/streamline-icons/factory.icon.d.ts.map +1 -0
  659. package/lib/components/Icon/streamline-icons/factory.icon.js +7 -0
  660. package/lib/components/Icon/streamline-icons/factory.icon.js.map +1 -0
  661. package/lib/components/Icon/streamline-icons/fast-food.icon.d.ts +5 -0
  662. package/lib/components/Icon/streamline-icons/fast-food.icon.d.ts.map +1 -0
  663. package/lib/components/Icon/streamline-icons/fast-food.icon.js +7 -0
  664. package/lib/components/Icon/streamline-icons/fast-food.icon.js.map +1 -0
  665. package/lib/components/Icon/streamline-icons/field-cursor.icon.js +1 -1
  666. package/lib/components/Icon/streamline-icons/field-cursor.icon.js.map +1 -1
  667. package/lib/components/Icon/streamline-icons/field-group.icon.d.ts +5 -0
  668. package/lib/components/Icon/streamline-icons/field-group.icon.d.ts.map +1 -0
  669. package/lib/components/Icon/streamline-icons/field-group.icon.js +7 -0
  670. package/lib/components/Icon/streamline-icons/field-group.icon.js.map +1 -0
  671. package/lib/components/Icon/streamline-icons/gear-nodes.icon.d.ts +5 -0
  672. package/lib/components/Icon/streamline-icons/gear-nodes.icon.d.ts.map +1 -0
  673. package/lib/components/Icon/streamline-icons/gear-nodes.icon.js +7 -0
  674. package/lib/components/Icon/streamline-icons/gear-nodes.icon.js.map +1 -0
  675. package/lib/components/Icon/streamline-icons/heart-rate.icon.d.ts +5 -0
  676. package/lib/components/Icon/streamline-icons/heart-rate.icon.d.ts.map +1 -0
  677. package/lib/components/Icon/streamline-icons/heart-rate.icon.js +7 -0
  678. package/lib/components/Icon/streamline-icons/heart-rate.icon.js.map +1 -0
  679. package/lib/components/Icon/streamline-icons/hexagons.icon.d.ts +5 -0
  680. package/lib/components/Icon/streamline-icons/hexagons.icon.d.ts.map +1 -0
  681. package/lib/components/Icon/streamline-icons/hexagons.icon.js +7 -0
  682. package/lib/components/Icon/streamline-icons/hexagons.icon.js.map +1 -0
  683. package/lib/components/Icon/streamline-icons/language-pack.icon.d.ts +5 -0
  684. package/lib/components/Icon/streamline-icons/language-pack.icon.d.ts.map +1 -0
  685. package/lib/components/Icon/streamline-icons/language-pack.icon.js +7 -0
  686. package/lib/components/Icon/streamline-icons/language-pack.icon.js.map +1 -0
  687. package/lib/components/Icon/streamline-icons/layout.icon.d.ts +5 -0
  688. package/lib/components/Icon/streamline-icons/layout.icon.d.ts.map +1 -0
  689. package/lib/components/Icon/streamline-icons/layout.icon.js +7 -0
  690. package/lib/components/Icon/streamline-icons/layout.icon.js.map +1 -0
  691. package/lib/components/Icon/streamline-icons/mcp.icon.d.ts +5 -0
  692. package/lib/components/Icon/streamline-icons/mcp.icon.d.ts.map +1 -0
  693. package/lib/components/Icon/streamline-icons/mcp.icon.js +7 -0
  694. package/lib/components/Icon/streamline-icons/mcp.icon.js.map +1 -0
  695. package/lib/components/Icon/streamline-icons/motherboard.icon.d.ts +5 -0
  696. package/lib/components/Icon/streamline-icons/motherboard.icon.d.ts.map +1 -0
  697. package/lib/components/Icon/streamline-icons/motherboard.icon.js +7 -0
  698. package/lib/components/Icon/streamline-icons/motherboard.icon.js.map +1 -0
  699. package/lib/components/Icon/streamline-icons/oil-tower.icon.d.ts +5 -0
  700. package/lib/components/Icon/streamline-icons/oil-tower.icon.d.ts.map +1 -0
  701. package/lib/components/Icon/streamline-icons/oil-tower.icon.js +7 -0
  702. package/lib/components/Icon/streamline-icons/oil-tower.icon.js.map +1 -0
  703. package/lib/components/Icon/streamline-icons/phone-stethescope.icon.d.ts +5 -0
  704. package/lib/components/Icon/streamline-icons/phone-stethescope.icon.d.ts.map +1 -0
  705. package/lib/components/Icon/streamline-icons/phone-stethescope.icon.js +7 -0
  706. package/lib/components/Icon/streamline-icons/phone-stethescope.icon.js.map +1 -0
  707. package/lib/components/Icon/streamline-icons/piggybank.icon.d.ts +5 -0
  708. package/lib/components/Icon/streamline-icons/piggybank.icon.d.ts.map +1 -0
  709. package/lib/components/Icon/streamline-icons/piggybank.icon.js +7 -0
  710. package/lib/components/Icon/streamline-icons/piggybank.icon.js.map +1 -0
  711. package/lib/components/Icon/streamline-icons/plug-connect.icon.d.ts +5 -0
  712. package/lib/components/Icon/streamline-icons/plug-connect.icon.d.ts.map +1 -0
  713. package/lib/components/Icon/streamline-icons/plug-connect.icon.js +7 -0
  714. package/lib/components/Icon/streamline-icons/plug-connect.icon.js.map +1 -0
  715. package/lib/components/Icon/streamline-icons/prescription.icon.d.ts +5 -0
  716. package/lib/components/Icon/streamline-icons/prescription.icon.d.ts.map +1 -0
  717. package/lib/components/Icon/streamline-icons/prescription.icon.js +7 -0
  718. package/lib/components/Icon/streamline-icons/prescription.icon.js.map +1 -0
  719. package/lib/components/Icon/streamline-icons/preview-bottom.icon.d.ts +5 -0
  720. package/lib/components/Icon/streamline-icons/preview-bottom.icon.d.ts.map +1 -0
  721. package/lib/components/Icon/streamline-icons/preview-bottom.icon.js +7 -0
  722. package/lib/components/Icon/streamline-icons/preview-bottom.icon.js.map +1 -0
  723. package/lib/components/Icon/streamline-icons/preview-hide.icon.d.ts +5 -0
  724. package/lib/components/Icon/streamline-icons/preview-hide.icon.d.ts.map +1 -0
  725. package/lib/components/Icon/streamline-icons/preview-hide.icon.js +7 -0
  726. package/lib/components/Icon/streamline-icons/preview-hide.icon.js.map +1 -0
  727. package/lib/components/Icon/streamline-icons/preview-rtl.icon.d.ts +5 -0
  728. package/lib/components/Icon/streamline-icons/preview-rtl.icon.d.ts.map +1 -0
  729. package/lib/components/Icon/streamline-icons/preview-rtl.icon.js +7 -0
  730. package/lib/components/Icon/streamline-icons/preview-rtl.icon.js.map +1 -0
  731. package/lib/components/Icon/streamline-icons/preview.icon.d.ts +5 -0
  732. package/lib/components/Icon/streamline-icons/preview.icon.d.ts.map +1 -0
  733. package/lib/components/Icon/streamline-icons/preview.icon.js +7 -0
  734. package/lib/components/Icon/streamline-icons/preview.icon.js.map +1 -0
  735. package/lib/components/Icon/streamline-icons/return.icon.d.ts +5 -0
  736. package/lib/components/Icon/streamline-icons/return.icon.d.ts.map +1 -0
  737. package/lib/components/Icon/streamline-icons/return.icon.js +7 -0
  738. package/lib/components/Icon/streamline-icons/return.icon.js.map +1 -0
  739. package/lib/components/Icon/streamline-icons/robot-assembly.icon.d.ts +5 -0
  740. package/lib/components/Icon/streamline-icons/robot-assembly.icon.d.ts.map +1 -0
  741. package/lib/components/Icon/streamline-icons/robot-assembly.icon.js +7 -0
  742. package/lib/components/Icon/streamline-icons/robot-assembly.icon.js.map +1 -0
  743. package/lib/components/Icon/streamline-icons/scale-unequal.icon.d.ts +5 -0
  744. package/lib/components/Icon/streamline-icons/scale-unequal.icon.d.ts.map +1 -0
  745. package/lib/components/Icon/streamline-icons/scale-unequal.icon.js +7 -0
  746. package/lib/components/Icon/streamline-icons/scale-unequal.icon.js.map +1 -0
  747. package/lib/components/Icon/streamline-icons/selection-cursor.icon.d.ts +5 -0
  748. package/lib/components/Icon/streamline-icons/selection-cursor.icon.d.ts.map +1 -0
  749. package/lib/components/Icon/streamline-icons/selection-cursor.icon.js +7 -0
  750. package/lib/components/Icon/streamline-icons/selection-cursor.icon.js.map +1 -0
  751. package/lib/components/Icon/streamline-icons/send-solid.icon.d.ts +5 -0
  752. package/lib/components/Icon/streamline-icons/send-solid.icon.d.ts.map +1 -0
  753. package/lib/components/Icon/streamline-icons/send-solid.icon.js +7 -0
  754. package/lib/components/Icon/streamline-icons/send-solid.icon.js.map +1 -0
  755. package/lib/components/Icon/streamline-icons/sewing-machine.icon.d.ts +5 -0
  756. package/lib/components/Icon/streamline-icons/sewing-machine.icon.d.ts.map +1 -0
  757. package/lib/components/Icon/streamline-icons/sewing-machine.icon.js +7 -0
  758. package/lib/components/Icon/streamline-icons/sewing-machine.icon.js.map +1 -0
  759. package/lib/components/Icon/streamline-icons/shapes.icon.d.ts +5 -0
  760. package/lib/components/Icon/streamline-icons/shapes.icon.d.ts.map +1 -0
  761. package/lib/components/Icon/streamline-icons/shapes.icon.js +7 -0
  762. package/lib/components/Icon/streamline-icons/shapes.icon.js.map +1 -0
  763. package/lib/components/Icon/streamline-icons/share-case.icon.d.ts +5 -0
  764. package/lib/components/Icon/streamline-icons/share-case.icon.d.ts.map +1 -0
  765. package/lib/components/Icon/streamline-icons/share-case.icon.js +7 -0
  766. package/lib/components/Icon/streamline-icons/share-case.icon.js.map +1 -0
  767. package/lib/components/Icon/streamline-icons/share-document.icon.d.ts +5 -0
  768. package/lib/components/Icon/streamline-icons/share-document.icon.d.ts.map +1 -0
  769. package/lib/components/Icon/streamline-icons/share-document.icon.js +7 -0
  770. package/lib/components/Icon/streamline-icons/share-document.icon.js.map +1 -0
  771. package/lib/components/Icon/streamline-icons/shield-currency.icon.d.ts +5 -0
  772. package/lib/components/Icon/streamline-icons/shield-currency.icon.d.ts.map +1 -0
  773. package/lib/components/Icon/streamline-icons/shield-currency.icon.js +7 -0
  774. package/lib/components/Icon/streamline-icons/shield-currency.icon.js.map +1 -0
  775. package/lib/components/Icon/streamline-icons/shield-lock.icon.d.ts +5 -0
  776. package/lib/components/Icon/streamline-icons/shield-lock.icon.d.ts.map +1 -0
  777. package/lib/components/Icon/streamline-icons/shield-lock.icon.js +7 -0
  778. package/lib/components/Icon/streamline-icons/shield-lock.icon.js.map +1 -0
  779. package/lib/components/Icon/streamline-icons/table-disc.icon.d.ts +5 -0
  780. package/lib/components/Icon/streamline-icons/table-disc.icon.d.ts.map +1 -0
  781. package/lib/components/Icon/streamline-icons/table-disc.icon.js +7 -0
  782. package/lib/components/Icon/streamline-icons/table-disc.icon.js.map +1 -0
  783. package/lib/components/Icon/streamline-icons/tablet-rate.icon.d.ts +5 -0
  784. package/lib/components/Icon/streamline-icons/tablet-rate.icon.d.ts.map +1 -0
  785. package/lib/components/Icon/streamline-icons/tablet-rate.icon.js +7 -0
  786. package/lib/components/Icon/streamline-icons/tablet-rate.icon.js.map +1 -0
  787. package/lib/components/Icon/streamline-icons/ticket-movie.icon.d.ts +5 -0
  788. package/lib/components/Icon/streamline-icons/ticket-movie.icon.d.ts.map +1 -0
  789. package/lib/components/Icon/streamline-icons/ticket-movie.icon.js +7 -0
  790. package/lib/components/Icon/streamline-icons/ticket-movie.icon.js.map +1 -0
  791. package/lib/components/Icon/streamline-icons/train.icon.d.ts +5 -0
  792. package/lib/components/Icon/streamline-icons/train.icon.d.ts.map +1 -0
  793. package/lib/components/Icon/streamline-icons/train.icon.js +7 -0
  794. package/lib/components/Icon/streamline-icons/train.icon.js.map +1 -0
  795. package/lib/components/Icon/streamline-icons/translate.icon.d.ts +5 -0
  796. package/lib/components/Icon/streamline-icons/translate.icon.d.ts.map +1 -0
  797. package/lib/components/Icon/streamline-icons/translate.icon.js +7 -0
  798. package/lib/components/Icon/streamline-icons/translate.icon.js.map +1 -0
  799. package/lib/components/Icon/streamline-icons/truck-cargo.icon.d.ts +5 -0
  800. package/lib/components/Icon/streamline-icons/truck-cargo.icon.d.ts.map +1 -0
  801. package/lib/components/Icon/streamline-icons/truck-cargo.icon.js +7 -0
  802. package/lib/components/Icon/streamline-icons/truck-cargo.icon.js.map +1 -0
  803. package/lib/components/Icon/streamline-icons/truck-clock.icon.d.ts +5 -0
  804. package/lib/components/Icon/streamline-icons/truck-clock.icon.d.ts.map +1 -0
  805. package/lib/components/Icon/streamline-icons/truck-clock.icon.js +7 -0
  806. package/lib/components/Icon/streamline-icons/truck-clock.icon.js.map +1 -0
  807. package/lib/components/Icon/streamline-icons/truck.icon.d.ts +5 -0
  808. package/lib/components/Icon/streamline-icons/truck.icon.d.ts.map +1 -0
  809. package/lib/components/Icon/streamline-icons/truck.icon.js +7 -0
  810. package/lib/components/Icon/streamline-icons/truck.icon.js.map +1 -0
  811. package/lib/components/Icon/streamline-icons/user-laptop.icon.d.ts +5 -0
  812. package/lib/components/Icon/streamline-icons/user-laptop.icon.d.ts.map +1 -0
  813. package/lib/components/Icon/streamline-icons/user-laptop.icon.js +7 -0
  814. package/lib/components/Icon/streamline-icons/user-laptop.icon.js.map +1 -0
  815. package/lib/components/Icon/streamline-icons/user-plane.icon.d.ts +5 -0
  816. package/lib/components/Icon/streamline-icons/user-plane.icon.d.ts.map +1 -0
  817. package/lib/components/Icon/streamline-icons/user-plane.icon.js +7 -0
  818. package/lib/components/Icon/streamline-icons/user-plane.icon.js.map +1 -0
  819. package/lib/components/Icon/streamline-icons/user-polaris-solid.icon.d.ts +5 -0
  820. package/lib/components/Icon/streamline-icons/user-polaris-solid.icon.d.ts.map +1 -0
  821. package/lib/components/Icon/streamline-icons/user-polaris-solid.icon.js +7 -0
  822. package/lib/components/Icon/streamline-icons/user-polaris-solid.icon.js.map +1 -0
  823. package/lib/components/Icon/streamline-icons/veterinarian-dog.icon.d.ts +5 -0
  824. package/lib/components/Icon/streamline-icons/veterinarian-dog.icon.d.ts.map +1 -0
  825. package/lib/components/Icon/streamline-icons/veterinarian-dog.icon.js +7 -0
  826. package/lib/components/Icon/streamline-icons/veterinarian-dog.icon.js.map +1 -0
  827. package/lib/components/Icon/streamline-icons/video-player.icon.d.ts +5 -0
  828. package/lib/components/Icon/streamline-icons/video-player.icon.d.ts.map +1 -0
  829. package/lib/components/Icon/streamline-icons/video-player.icon.js +7 -0
  830. package/lib/components/Icon/streamline-icons/video-player.icon.js.map +1 -0
  831. package/lib/components/Icon/streamlineIconNames.d.ts +1 -1
  832. package/lib/components/Icon/streamlineIconNames.d.ts.map +1 -1
  833. package/lib/components/Icon/streamlineIconNames.js +63 -0
  834. package/lib/components/Icon/streamlineIconNames.js.map +1 -1
  835. package/lib/components/Image/Image.d.ts +1 -1
  836. package/lib/components/Image/Image.d.ts.map +1 -1
  837. package/lib/components/Image/Image.js +1 -0
  838. package/lib/components/Image/Image.js.map +1 -1
  839. package/lib/components/InlineEdit/InlineEdit.d.ts +26 -0
  840. package/lib/components/InlineEdit/InlineEdit.d.ts.map +1 -0
  841. package/lib/components/InlineEdit/InlineEdit.js +21 -0
  842. package/lib/components/InlineEdit/InlineEdit.js.map +1 -0
  843. package/lib/components/InlineEdit/InlineEdit.styles.d.ts +27 -0
  844. package/lib/components/InlineEdit/InlineEdit.styles.d.ts.map +1 -0
  845. package/lib/components/InlineEdit/InlineEdit.styles.js +49 -0
  846. package/lib/components/InlineEdit/InlineEdit.styles.js.map +1 -0
  847. package/lib/components/InlineEdit/InlineEdit.test-ids.d.ts +3 -0
  848. package/lib/components/InlineEdit/InlineEdit.test-ids.d.ts.map +1 -0
  849. package/lib/components/InlineEdit/InlineEdit.test-ids.js +4 -0
  850. package/lib/components/InlineEdit/InlineEdit.test-ids.js.map +1 -0
  851. package/lib/components/InlineEdit/index.d.ts +3 -0
  852. package/lib/components/InlineEdit/index.d.ts.map +1 -0
  853. package/lib/components/InlineEdit/index.js +2 -0
  854. package/lib/components/InlineEdit/index.js.map +1 -0
  855. package/lib/components/Input/Input.js +3 -3
  856. package/lib/components/Input/Input.js.map +1 -1
  857. package/lib/components/Input/Input.styles.d.ts +2 -2
  858. package/lib/components/Input/Input.styles.d.ts.map +1 -1
  859. package/lib/components/KeyboardCommands/KeyboardCommands.d.ts +6 -0
  860. package/lib/components/KeyboardCommands/KeyboardCommands.d.ts.map +1 -0
  861. package/lib/components/KeyboardCommands/KeyboardCommands.js +73 -0
  862. package/lib/components/KeyboardCommands/KeyboardCommands.js.map +1 -0
  863. package/lib/components/KeyboardCommands/index.d.ts +3 -0
  864. package/lib/components/KeyboardCommands/index.d.ts.map +1 -0
  865. package/lib/components/KeyboardCommands/index.js +3 -0
  866. package/lib/components/KeyboardCommands/index.js.map +1 -0
  867. package/lib/components/Label/Label.d.ts +4 -2
  868. package/lib/components/Label/Label.d.ts.map +1 -1
  869. package/lib/components/Label/Label.js +5 -1
  870. package/lib/components/Label/Label.js.map +1 -1
  871. package/lib/components/Lightbox/Lightbox.d.ts.map +1 -1
  872. package/lib/components/Lightbox/Lightbox.js +44 -20
  873. package/lib/components/Lightbox/Lightbox.js.map +1 -1
  874. package/lib/components/Lightbox/Lightbox.styles.d.ts +24 -11
  875. package/lib/components/Lightbox/Lightbox.styles.d.ts.map +1 -1
  876. package/lib/components/Lightbox/Lightbox.styles.js +33 -5
  877. package/lib/components/Lightbox/Lightbox.styles.js.map +1 -1
  878. package/lib/components/Lightbox/Lightbox.types.d.ts +13 -0
  879. package/lib/components/Lightbox/Lightbox.types.d.ts.map +1 -1
  880. package/lib/components/Lightbox/Lightbox.types.js.map +1 -1
  881. package/lib/components/Lightbox/index.d.ts +1 -1
  882. package/lib/components/Lightbox/index.d.ts.map +1 -1
  883. package/lib/components/Lightbox/index.js.map +1 -1
  884. package/lib/components/Link/Link.d.ts +17 -6
  885. package/lib/components/Link/Link.d.ts.map +1 -1
  886. package/lib/components/Link/Link.js +9 -7
  887. package/lib/components/Link/Link.js.map +1 -1
  888. package/lib/components/List/CommaSeparatedList.d.ts +2 -2
  889. package/lib/components/List/CommaSeparatedList.d.ts.map +1 -1
  890. package/lib/components/List/List.d.ts +3 -3
  891. package/lib/components/List/List.d.ts.map +1 -1
  892. package/lib/components/ListToolbar/ListToolbar.d.ts +1 -1
  893. package/lib/components/ListToolbar/ListToolbar.d.ts.map +1 -1
  894. package/lib/components/ListToolbar/ListToolbar.js +53 -81
  895. package/lib/components/ListToolbar/ListToolbar.js.map +1 -1
  896. package/lib/components/ListToolbar/ListToolbar.styles.d.ts +405 -15
  897. package/lib/components/ListToolbar/ListToolbar.styles.d.ts.map +1 -1
  898. package/lib/components/ListToolbar/ListToolbar.styles.js +58 -36
  899. package/lib/components/ListToolbar/ListToolbar.styles.js.map +1 -1
  900. package/lib/components/ListToolbar/ListToolbar.test-ids.d.ts +1 -1
  901. package/lib/components/ListToolbar/ListToolbar.test-ids.d.ts.map +1 -1
  902. package/lib/components/ListToolbar/ListToolbar.test-ids.js +0 -1
  903. package/lib/components/ListToolbar/ListToolbar.test-ids.js.map +1 -1
  904. package/lib/components/ListToolbar/ListToolbar.types.d.ts +9 -6
  905. package/lib/components/ListToolbar/ListToolbar.types.d.ts.map +1 -1
  906. package/lib/components/ListToolbar/ListToolbar.types.js.map +1 -1
  907. package/lib/components/LiveLog/LiveLog.js +2 -2
  908. package/lib/components/LiveLog/LiveLog.js.map +1 -1
  909. package/lib/components/LiveLog/LiveLog.styles.d.ts +1 -1
  910. package/lib/components/LiveLog/LiveLog.styles.d.ts.map +1 -1
  911. package/lib/components/LiveLog/LiveLog.types.d.ts +1 -1
  912. package/lib/components/LiveLog/LiveLog.types.js.map +1 -1
  913. package/lib/components/Location/GoogleMapsAPI.d.ts +4 -5
  914. package/lib/components/Location/GoogleMapsAPI.d.ts.map +1 -1
  915. package/lib/components/Location/GoogleMapsAPI.js +66 -69
  916. package/lib/components/Location/GoogleMapsAPI.js.map +1 -1
  917. package/lib/components/Location/LocationAPI.types.d.ts +2 -3
  918. package/lib/components/Location/LocationAPI.types.d.ts.map +1 -1
  919. package/lib/components/Location/LocationAPI.types.js.map +1 -1
  920. package/lib/components/Location/LocationInput.d.ts.map +1 -1
  921. package/lib/components/Location/LocationInput.js +72 -48
  922. package/lib/components/Location/LocationInput.js.map +1 -1
  923. package/lib/components/Location/LocationView.d.ts +2 -0
  924. package/lib/components/Location/LocationView.d.ts.map +1 -1
  925. package/lib/components/Location/LocationView.js +3 -3
  926. package/lib/components/Location/LocationView.js.map +1 -1
  927. package/lib/components/Location/LocationView.styles.d.ts +8 -6
  928. package/lib/components/Location/LocationView.styles.d.ts.map +1 -1
  929. package/lib/components/Mark/Mark.d.ts +5 -1
  930. package/lib/components/Mark/Mark.d.ts.map +1 -1
  931. package/lib/components/Mark/Mark.js +8 -7
  932. package/lib/components/Mark/Mark.js.map +1 -1
  933. package/lib/components/Menu/Menu.d.ts.map +1 -1
  934. package/lib/components/Menu/Menu.js +59 -7
  935. package/lib/components/Menu/Menu.js.map +1 -1
  936. package/lib/components/Menu/Menu.styles.d.ts +21 -15
  937. package/lib/components/Menu/Menu.styles.d.ts.map +1 -1
  938. package/lib/components/Menu/Menu.styles.js +138 -6
  939. package/lib/components/Menu/Menu.styles.js.map +1 -1
  940. package/lib/components/Menu/Menu.types.d.ts +10 -1
  941. package/lib/components/Menu/Menu.types.d.ts.map +1 -1
  942. package/lib/components/Menu/Menu.types.js.map +1 -1
  943. package/lib/components/Menu/MenuItem.d.ts.map +1 -1
  944. package/lib/components/Menu/MenuItem.js +19 -20
  945. package/lib/components/Menu/MenuItem.js.map +1 -1
  946. package/lib/components/MenuButton/MenuButton.d.ts +2 -6
  947. package/lib/components/MenuButton/MenuButton.d.ts.map +1 -1
  948. package/lib/components/MenuButton/MenuButton.js +64 -11
  949. package/lib/components/MenuButton/MenuButton.js.map +1 -1
  950. package/lib/components/MetaList/MetaList.d.ts +4 -4
  951. package/lib/components/MetaList/MetaList.d.ts.map +1 -1
  952. package/lib/components/Modal/Contexts.d.ts.map +1 -1
  953. package/lib/components/Modal/Contexts.js +2 -1
  954. package/lib/components/Modal/Contexts.js.map +1 -1
  955. package/lib/components/Modal/DockedModals.d.ts.map +1 -1
  956. package/lib/components/Modal/DockedModals.js +2 -1
  957. package/lib/components/Modal/DockedModals.js.map +1 -1
  958. package/lib/components/Modal/MinimizedModal.d.ts.map +1 -1
  959. package/lib/components/Modal/MinimizedModal.js +30 -8
  960. package/lib/components/Modal/MinimizedModal.js.map +1 -1
  961. package/lib/components/Modal/Modal.d.ts.map +1 -1
  962. package/lib/components/Modal/Modal.js +54 -17
  963. package/lib/components/Modal/Modal.js.map +1 -1
  964. package/lib/components/Modal/Modal.styles.d.ts +5 -6
  965. package/lib/components/Modal/Modal.styles.d.ts.map +1 -1
  966. package/lib/components/Modal/Modal.styles.js +66 -15
  967. package/lib/components/Modal/Modal.styles.js.map +1 -1
  968. package/lib/components/Modal/Modal.types.d.ts +19 -3
  969. package/lib/components/Modal/Modal.types.d.ts.map +1 -1
  970. package/lib/components/Modal/Modal.types.js.map +1 -1
  971. package/lib/components/Modal/ModalManager.d.ts.map +1 -1
  972. package/lib/components/Modal/ModalManager.js +28 -9
  973. package/lib/components/Modal/ModalManager.js.map +1 -1
  974. package/lib/components/Modal/useModalMove.d.ts +30 -0
  975. package/lib/components/Modal/useModalMove.d.ts.map +1 -0
  976. package/lib/components/Modal/useModalMove.js +148 -0
  977. package/lib/components/Modal/useModalMove.js.map +1 -0
  978. package/lib/components/MultiStepForm/FormProgress.styles.d.ts +208 -12
  979. package/lib/components/MultiStepForm/FormProgress.styles.d.ts.map +1 -1
  980. package/lib/components/MultiStepForm/FormProgress.styles.js +199 -69
  981. package/lib/components/MultiStepForm/FormProgress.styles.js.map +1 -1
  982. package/lib/components/MultiStepForm/HorizontalFormProgress.d.ts +2 -1
  983. package/lib/components/MultiStepForm/HorizontalFormProgress.d.ts.map +1 -1
  984. package/lib/components/MultiStepForm/HorizontalFormProgress.js +44 -25
  985. package/lib/components/MultiStepForm/HorizontalFormProgress.js.map +1 -1
  986. package/lib/components/MultiStepForm/MultiStepForm.d.ts +190 -5
  987. package/lib/components/MultiStepForm/MultiStepForm.d.ts.map +1 -1
  988. package/lib/components/MultiStepForm/MultiStepForm.js +40 -11
  989. package/lib/components/MultiStepForm/MultiStepForm.js.map +1 -1
  990. package/lib/components/MultiStepForm/MultiStepForm.types.d.ts +20 -6
  991. package/lib/components/MultiStepForm/MultiStepForm.types.d.ts.map +1 -1
  992. package/lib/components/MultiStepForm/MultiStepForm.types.js.map +1 -1
  993. package/lib/components/MultiStepForm/VerticalFormProgress.d.ts +1 -1
  994. package/lib/components/MultiStepForm/VerticalFormProgress.d.ts.map +1 -1
  995. package/lib/components/MultiStepForm/VerticalFormProgress.js +7 -4
  996. package/lib/components/MultiStepForm/VerticalFormProgress.js.map +1 -1
  997. package/lib/components/MultiStepForm/useFormProgressOverflow.d.ts +6 -0
  998. package/lib/components/MultiStepForm/useFormProgressOverflow.d.ts.map +1 -0
  999. package/lib/components/MultiStepForm/useFormProgressOverflow.js +35 -0
  1000. package/lib/components/MultiStepForm/useFormProgressOverflow.js.map +1 -0
  1001. package/lib/components/Number/NumberInput.d.ts.map +1 -1
  1002. package/lib/components/Number/NumberInput.js +1 -3
  1003. package/lib/components/Number/NumberInput.js.map +1 -1
  1004. package/lib/components/Number/NumberInput.styles.d.ts +8 -4
  1005. package/lib/components/Number/NumberInput.styles.d.ts.map +1 -1
  1006. package/lib/components/Number/NumberInput.types.d.ts +4 -0
  1007. package/lib/components/Number/NumberInput.types.d.ts.map +1 -1
  1008. package/lib/components/Number/NumberInput.types.js.map +1 -1
  1009. package/lib/components/Number/NumberRangeInput.d.ts.map +1 -1
  1010. package/lib/components/Number/NumberRangeInput.js +2 -5
  1011. package/lib/components/Number/NumberRangeInput.js.map +1 -1
  1012. package/lib/components/PageTemplates/CategorySubPage.styles.d.ts +22 -18
  1013. package/lib/components/PageTemplates/CategorySubPage.styles.d.ts.map +1 -1
  1014. package/lib/components/PageTemplates/CategorySubPage.styles.js +24 -5
  1015. package/lib/components/PageTemplates/CategorySubPage.styles.js.map +1 -1
  1016. package/lib/components/PageTemplates/DashboardPage.d.ts +12 -6
  1017. package/lib/components/PageTemplates/DashboardPage.d.ts.map +1 -1
  1018. package/lib/components/PageTemplates/DashboardPage.js +1 -1
  1019. package/lib/components/PageTemplates/DashboardPage.js.map +1 -1
  1020. package/lib/components/PageTemplates/GridLayout/EditorBackground.d.ts.map +1 -1
  1021. package/lib/components/PageTemplates/GridLayout/EditorBackground.js +1 -0
  1022. package/lib/components/PageTemplates/GridLayout/EditorBackground.js.map +1 -1
  1023. package/lib/components/PageTemplates/GridLayout/EditorGridItem.d.ts.map +1 -1
  1024. package/lib/components/PageTemplates/GridLayout/EditorGridItem.js +6 -0
  1025. package/lib/components/PageTemplates/GridLayout/EditorGridItem.js.map +1 -1
  1026. package/lib/components/PageTemplates/GridLayout/GridLayoutEditor.d.ts +6 -0
  1027. package/lib/components/PageTemplates/GridLayout/GridLayoutEditor.d.ts.map +1 -1
  1028. package/lib/components/PageTemplates/GridLayout/GridLayoutEditor.js +2 -2
  1029. package/lib/components/PageTemplates/GridLayout/GridLayoutEditor.js.map +1 -1
  1030. package/lib/components/PageTemplates/GridLayout/GridLayoutViewer.d.ts +6 -0
  1031. package/lib/components/PageTemplates/GridLayout/GridLayoutViewer.d.ts.map +1 -1
  1032. package/lib/components/PageTemplates/GridLayout/GridLayoutViewer.js +2 -2
  1033. package/lib/components/PageTemplates/GridLayout/GridLayoutViewer.js.map +1 -1
  1034. package/lib/components/PageTemplates/GridLayout/ReactGridLayoutStyles.d.ts +1 -1
  1035. package/lib/components/PageTemplates/GridLayout/ReactGridLayoutStyles.d.ts.map +1 -1
  1036. package/lib/components/PageTemplates/GridLayout/ReactResizableStyles.d.ts +1 -1
  1037. package/lib/components/PageTemplates/GridLayout/ReactResizableStyles.d.ts.map +1 -1
  1038. package/lib/components/PageTemplates/GridLayout/utils.d.ts +2 -1
  1039. package/lib/components/PageTemplates/GridLayout/utils.d.ts.map +1 -1
  1040. package/lib/components/PageTemplates/GridLayout/utils.js +4 -3
  1041. package/lib/components/PageTemplates/GridLayout/utils.js.map +1 -1
  1042. package/lib/components/PageTemplates/PageTemplates.d.ts +191 -9
  1043. package/lib/components/PageTemplates/PageTemplates.d.ts.map +1 -1
  1044. package/lib/components/PageTemplates/PageTemplates.js +31 -16
  1045. package/lib/components/PageTemplates/PageTemplates.js.map +1 -1
  1046. package/lib/components/Phone/PhoneInput.d.ts +3 -0
  1047. package/lib/components/Phone/PhoneInput.d.ts.map +1 -1
  1048. package/lib/components/Phone/PhoneInput.js +8 -4
  1049. package/lib/components/Phone/PhoneInput.js.map +1 -1
  1050. package/lib/components/Phone/utils.d.ts +1 -1
  1051. package/lib/components/Phone/utils.d.ts.map +1 -1
  1052. package/lib/components/Phone/utils.js +5 -2
  1053. package/lib/components/Phone/utils.js.map +1 -1
  1054. package/lib/components/Popover/Popover.d.ts.map +1 -1
  1055. package/lib/components/Popover/Popover.js +18 -10
  1056. package/lib/components/Popover/Popover.js.map +1 -1
  1057. package/lib/components/Popover/Popover.styles.d.ts +3 -3
  1058. package/lib/components/Popover/Popover.styles.d.ts.map +1 -1
  1059. package/lib/components/Popover/Popover.styles.js +13 -9
  1060. package/lib/components/Popover/Popover.styles.js.map +1 -1
  1061. package/lib/components/Popover/modifiers.js +1 -1
  1062. package/lib/components/Popover/modifiers.js.map +1 -1
  1063. package/lib/components/Preview/Contexts.d.ts +5 -0
  1064. package/lib/components/Preview/Contexts.d.ts.map +1 -0
  1065. package/lib/components/Preview/Contexts.js +19 -0
  1066. package/lib/components/Preview/Contexts.js.map +1 -0
  1067. package/lib/components/Preview/Preview.types.d.ts +46 -0
  1068. package/lib/components/Preview/Preview.types.d.ts.map +1 -0
  1069. package/lib/components/Preview/Preview.types.js +2 -0
  1070. package/lib/components/Preview/Preview.types.js.map +1 -0
  1071. package/lib/components/Preview/PreviewManager.d.ts +11 -0
  1072. package/lib/components/Preview/PreviewManager.d.ts.map +1 -0
  1073. package/lib/components/Preview/PreviewManager.js +125 -0
  1074. package/lib/components/Preview/PreviewManager.js.map +1 -0
  1075. package/lib/components/Preview/PreviewPanel.d.ts +7 -0
  1076. package/lib/components/Preview/PreviewPanel.d.ts.map +1 -0
  1077. package/lib/components/Preview/PreviewPanel.js +110 -0
  1078. package/lib/components/Preview/PreviewPanel.js.map +1 -0
  1079. package/lib/components/Preview/PreviewPanel.test-ids.d.ts +2 -0
  1080. package/lib/components/Preview/PreviewPanel.test-ids.d.ts.map +1 -0
  1081. package/lib/components/Preview/PreviewPanel.test-ids.js +6 -0
  1082. package/lib/components/Preview/PreviewPanel.test-ids.js.map +1 -0
  1083. package/lib/components/Preview/index.d.ts +5 -0
  1084. package/lib/components/Preview/index.d.ts.map +1 -0
  1085. package/lib/components/Preview/index.js +4 -0
  1086. package/lib/components/Preview/index.js.map +1 -0
  1087. package/lib/components/Progress/Progress.js +1 -1
  1088. package/lib/components/Progress/Progress.js.map +1 -1
  1089. package/lib/components/Progress/Progress.styles.d.ts +199 -9
  1090. package/lib/components/Progress/Progress.styles.d.ts.map +1 -1
  1091. package/lib/components/Progress/Progress.styles.js +1 -1
  1092. package/lib/components/Progress/Progress.styles.js.map +1 -1
  1093. package/lib/components/QRCode/QRCode.d.ts +1 -1
  1094. package/lib/components/QRCode/QRCode.d.ts.map +1 -1
  1095. package/lib/components/RadioButton/RadioButton.test-ids.d.ts +1 -1
  1096. package/lib/components/RadioButton/RadioButton.test-ids.d.ts.map +1 -1
  1097. package/lib/components/RadioButton/RadioButtonCard.d.ts +11 -3
  1098. package/lib/components/RadioButton/RadioButtonCard.d.ts.map +1 -1
  1099. package/lib/components/RadioButton/RadioButtonCard.js +5 -22
  1100. package/lib/components/RadioButton/RadioButtonCard.js.map +1 -1
  1101. package/lib/components/RadioButtonGroup/RadioButtonGroup.d.ts +7 -0
  1102. package/lib/components/RadioButtonGroup/RadioButtonGroup.d.ts.map +1 -0
  1103. package/lib/components/RadioButtonGroup/RadioButtonGroup.js +10 -0
  1104. package/lib/components/RadioButtonGroup/RadioButtonGroup.js.map +1 -0
  1105. package/lib/components/RadioButtonGroup/index.d.ts +2 -1
  1106. package/lib/components/RadioButtonGroup/index.d.ts.map +1 -1
  1107. package/lib/components/RadioButtonGroup/index.js +1 -1
  1108. package/lib/components/RadioButtonGroup/index.js.map +1 -1
  1109. package/lib/components/RadioCheck/RadioCheck.d.ts +9 -4
  1110. package/lib/components/RadioCheck/RadioCheck.d.ts.map +1 -1
  1111. package/lib/components/RadioCheck/RadioCheck.js +97 -75
  1112. package/lib/components/RadioCheck/RadioCheck.js.map +1 -1
  1113. package/lib/components/RadioCheckGroup/RadioCheckGroup.d.ts +11 -5
  1114. package/lib/components/RadioCheckGroup/RadioCheckGroup.d.ts.map +1 -1
  1115. package/lib/components/RadioCheckGroup/RadioCheckGroup.js +70 -19
  1116. package/lib/components/RadioCheckGroup/RadioCheckGroup.js.map +1 -1
  1117. package/lib/components/Rating/Rating.d.ts +1 -1
  1118. package/lib/components/Rating/Rating.d.ts.map +1 -1
  1119. package/lib/components/ResponsiveActions/ResponsiveActions.d.ts +2 -2
  1120. package/lib/components/ResponsiveActions/ResponsiveActions.d.ts.map +1 -1
  1121. package/lib/components/ResponsiveActions/ResponsiveActions.js +12 -15
  1122. package/lib/components/ResponsiveActions/ResponsiveActions.js.map +1 -1
  1123. package/lib/components/SearchInput/SearchInput.d.ts +7 -7
  1124. package/lib/components/SearchInput/SearchInput.d.ts.map +1 -1
  1125. package/lib/components/SearchInput/SearchInput.js +41 -29
  1126. package/lib/components/SearchInput/SearchInput.js.map +1 -1
  1127. package/lib/components/SearchInput/SearchInput.styles.d.ts +21 -13
  1128. package/lib/components/SearchInput/SearchInput.styles.d.ts.map +1 -1
  1129. package/lib/components/SearchInput/SearchInput.styles.js +3 -5
  1130. package/lib/components/SearchInput/SearchInput.styles.js.map +1 -1
  1131. package/lib/components/Select/Select.d.ts +3 -3
  1132. package/lib/components/Select/Select.d.ts.map +1 -1
  1133. package/lib/components/Select/Select.js +14 -11
  1134. package/lib/components/Select/Select.js.map +1 -1
  1135. package/lib/components/SelectionCard/SelectionCard.d.ts +1 -1
  1136. package/lib/components/SelectionCard/SelectionCard.d.ts.map +1 -1
  1137. package/lib/components/SelectionCard/SelectionCard.js +50 -29
  1138. package/lib/components/SelectionCard/SelectionCard.js.map +1 -1
  1139. package/lib/components/SelectionCard/SelectionCard.styles.d.ts +36 -11
  1140. package/lib/components/SelectionCard/SelectionCard.styles.d.ts.map +1 -1
  1141. package/lib/components/SelectionCard/SelectionCard.styles.js +226 -62
  1142. package/lib/components/SelectionCard/SelectionCard.styles.js.map +1 -1
  1143. package/lib/components/SelectionCard/SelectionCard.test-ids.d.ts +2 -2
  1144. package/lib/components/SelectionCard/SelectionCard.test-ids.d.ts.map +1 -1
  1145. package/lib/components/SelectionCard/SelectionCard.test-ids.js +1 -1
  1146. package/lib/components/SelectionCard/SelectionCard.test-ids.js.map +1 -1
  1147. package/lib/components/SelectionCard/SelectionCard.types.d.ts +24 -6
  1148. package/lib/components/SelectionCard/SelectionCard.types.d.ts.map +1 -1
  1149. package/lib/components/SelectionCard/SelectionCard.types.js.map +1 -1
  1150. package/lib/components/SelectionCard/SelectionCardActions.d.ts +8 -0
  1151. package/lib/components/SelectionCard/SelectionCardActions.d.ts.map +1 -0
  1152. package/lib/components/SelectionCard/SelectionCardActions.js +48 -0
  1153. package/lib/components/SelectionCard/SelectionCardActions.js.map +1 -0
  1154. package/lib/components/SelectionCard/SelectionCardDisplay.d.ts +12 -4
  1155. package/lib/components/SelectionCard/SelectionCardDisplay.d.ts.map +1 -1
  1156. package/lib/components/SelectionCard/SelectionCardDisplay.js +6 -3
  1157. package/lib/components/SelectionCard/SelectionCardDisplay.js.map +1 -1
  1158. package/lib/components/SelectionCard/index.d.ts +1 -1
  1159. package/lib/components/SelectionCard/index.d.ts.map +1 -1
  1160. package/lib/components/SelectionCard/index.js.map +1 -1
  1161. package/lib/components/Sentiment/Sentiment.d.ts +1 -1
  1162. package/lib/components/Sentiment/Sentiment.d.ts.map +1 -1
  1163. package/lib/components/ShowMoreLess/ShowMoreLess.d.ts +3 -1
  1164. package/lib/components/ShowMoreLess/ShowMoreLess.d.ts.map +1 -1
  1165. package/lib/components/Skeleton/LineSkeleton.d.ts +1 -1
  1166. package/lib/components/Skeleton/LineSkeleton.d.ts.map +1 -1
  1167. package/lib/components/Skeleton/RectangleSkeleton.d.ts +1 -1
  1168. package/lib/components/Skeleton/RectangleSkeleton.d.ts.map +1 -1
  1169. package/lib/components/SkipLinks/SkipLinks.d.ts +0 -1
  1170. package/lib/components/SkipLinks/SkipLinks.d.ts.map +1 -1
  1171. package/lib/components/SkipLinks/SkipLinks.js +10 -53
  1172. package/lib/components/SkipLinks/SkipLinks.js.map +1 -1
  1173. package/lib/components/SkipLinks/SkipLinks.styles.d.ts +6 -0
  1174. package/lib/components/SkipLinks/SkipLinks.styles.d.ts.map +1 -0
  1175. package/lib/components/SkipLinks/SkipLinks.styles.js +61 -0
  1176. package/lib/components/SkipLinks/SkipLinks.styles.js.map +1 -0
  1177. package/lib/components/SkipLinks/index.d.ts +1 -1
  1178. package/lib/components/SkipLinks/index.d.ts.map +1 -1
  1179. package/lib/components/SkipLinks/index.js +1 -1
  1180. package/lib/components/SkipLinks/index.js.map +1 -1
  1181. package/lib/components/Slider/Slider.d.ts.map +1 -1
  1182. package/lib/components/Slider/Slider.js +18 -3
  1183. package/lib/components/Slider/Slider.js.map +1 -1
  1184. package/lib/components/Slider/Slider.styles.d.ts +15 -13
  1185. package/lib/components/Slider/Slider.styles.d.ts.map +1 -1
  1186. package/lib/components/Slider/Slider.styles.js +2 -2
  1187. package/lib/components/Slider/Slider.styles.js.map +1 -1
  1188. package/lib/components/SpeechToTextButton/SpeechToTextButton.d.ts +13 -0
  1189. package/lib/components/SpeechToTextButton/SpeechToTextButton.d.ts.map +1 -0
  1190. package/lib/components/SpeechToTextButton/SpeechToTextButton.js +29 -0
  1191. package/lib/components/SpeechToTextButton/SpeechToTextButton.js.map +1 -0
  1192. package/lib/components/SpeechToTextButton/SpeechToTextButton.test-ids.d.ts +2 -0
  1193. package/lib/components/SpeechToTextButton/SpeechToTextButton.test-ids.d.ts.map +1 -0
  1194. package/lib/components/SpeechToTextButton/SpeechToTextButton.test-ids.js +3 -0
  1195. package/lib/components/SpeechToTextButton/SpeechToTextButton.test-ids.js.map +1 -0
  1196. package/lib/components/SpeechToTextButton/index.d.ts +3 -0
  1197. package/lib/components/SpeechToTextButton/index.d.ts.map +1 -0
  1198. package/lib/components/SpeechToTextButton/index.js +2 -0
  1199. package/lib/components/SpeechToTextButton/index.js.map +1 -0
  1200. package/lib/components/SummaryItem/SummaryItem.d.ts +371 -7
  1201. package/lib/components/SummaryItem/SummaryItem.d.ts.map +1 -1
  1202. package/lib/components/SummaryItem/SummaryItem.js +3 -1
  1203. package/lib/components/SummaryItem/SummaryItem.js.map +1 -1
  1204. package/lib/components/SummaryList/SummaryList.d.ts +26 -8
  1205. package/lib/components/SummaryList/SummaryList.d.ts.map +1 -1
  1206. package/lib/components/SummaryList/SummaryList.js +54 -9
  1207. package/lib/components/SummaryList/SummaryList.js.map +1 -1
  1208. package/lib/components/SummaryList/ViewAll.d.ts +10 -4
  1209. package/lib/components/SummaryList/ViewAll.d.ts.map +1 -1
  1210. package/lib/components/SummaryList/ViewAll.js +23 -3
  1211. package/lib/components/SummaryList/ViewAll.js.map +1 -1
  1212. package/lib/components/SummaryList/index.d.ts +1 -0
  1213. package/lib/components/SummaryList/index.d.ts.map +1 -1
  1214. package/lib/components/SummaryList/index.js.map +1 -1
  1215. package/lib/components/Switch/Switch.d.ts +3 -3
  1216. package/lib/components/Switch/Switch.d.ts.map +1 -1
  1217. package/lib/components/Switch/Switch.js +14 -5
  1218. package/lib/components/Switch/Switch.js.map +1 -1
  1219. package/lib/components/Table/Table.d.ts +2 -1
  1220. package/lib/components/Table/Table.d.ts.map +1 -1
  1221. package/lib/components/Table/Table.js +1 -0
  1222. package/lib/components/Table/Table.js.map +1 -1
  1223. package/lib/components/Tabs/Tab.d.ts +3 -4
  1224. package/lib/components/Tabs/Tab.d.ts.map +1 -1
  1225. package/lib/components/Tabs/Tab.js +111 -106
  1226. package/lib/components/Tabs/Tab.js.map +1 -1
  1227. package/lib/components/Tabs/TabPanel.d.ts +184 -2
  1228. package/lib/components/Tabs/TabPanel.d.ts.map +1 -1
  1229. package/lib/components/Tabs/TabPanel.js +4 -2
  1230. package/lib/components/Tabs/TabPanel.js.map +1 -1
  1231. package/lib/components/Tabs/Tabs.d.ts.map +1 -1
  1232. package/lib/components/Tabs/Tabs.js +24 -1
  1233. package/lib/components/Tabs/Tabs.js.map +1 -1
  1234. package/lib/components/Tabs/Tabs.styles.d.ts +12 -10
  1235. package/lib/components/Tabs/Tabs.styles.d.ts.map +1 -1
  1236. package/lib/components/Tabs/Tabs.styles.js +126 -11
  1237. package/lib/components/Tabs/Tabs.styles.js.map +1 -1
  1238. package/lib/components/Text/Text.d.ts +1 -1
  1239. package/lib/components/Text/Text.d.ts.map +1 -1
  1240. package/lib/components/TextArea/TextArea.d.ts +3 -1
  1241. package/lib/components/TextArea/TextArea.d.ts.map +1 -1
  1242. package/lib/components/TextArea/TextArea.js +95 -28
  1243. package/lib/components/TextArea/TextArea.js.map +1 -1
  1244. package/lib/components/TextArea/TextArea.styles.d.ts +3 -2
  1245. package/lib/components/TextArea/TextArea.styles.d.ts.map +1 -1
  1246. package/lib/components/TextArea/TextArea.styles.js +2 -0
  1247. package/lib/components/TextArea/TextArea.styles.js.map +1 -1
  1248. package/lib/components/Toaster/Toaster.d.ts +1 -1
  1249. package/lib/components/Toaster/Toaster.d.ts.map +1 -1
  1250. package/lib/components/Toaster/Toaster.js +5 -5
  1251. package/lib/components/Toaster/Toaster.js.map +1 -1
  1252. package/lib/components/Toaster/Toaster.types.d.ts +0 -13
  1253. package/lib/components/Toaster/Toaster.types.d.ts.map +1 -1
  1254. package/lib/components/Toaster/Toaster.types.js.map +1 -1
  1255. package/lib/components/Tooltip/Tooltip.d.ts +1 -1
  1256. package/lib/components/Tooltip/Tooltip.d.ts.map +1 -1
  1257. package/lib/components/Tooltip/Tooltip.js +5 -0
  1258. package/lib/components/Tooltip/Tooltip.js.map +1 -1
  1259. package/lib/components/Tree/StandardTree.d.ts.map +1 -1
  1260. package/lib/components/Tree/StandardTree.js +4 -3
  1261. package/lib/components/Tree/StandardTree.js.map +1 -1
  1262. package/lib/components/Tree/StandardTree.styles.d.ts +20 -16
  1263. package/lib/components/Tree/StandardTree.styles.d.ts.map +1 -1
  1264. package/lib/components/Tree/StandardTree.styles.js +11 -10
  1265. package/lib/components/Tree/StandardTree.styles.js.map +1 -1
  1266. package/lib/components/Tree/StandardTree.types.d.ts +2 -2
  1267. package/lib/components/Tree/StandardTree.types.d.ts.map +1 -1
  1268. package/lib/components/Tree/StandardTree.types.js.map +1 -1
  1269. package/lib/components/Tree/Tree.d.ts +2 -2
  1270. package/lib/components/Tree/Tree.d.ts.map +1 -1
  1271. package/lib/components/VisuallyHiddenText/VisuallyHiddenText.d.ts +1 -1
  1272. package/lib/components/VisuallyHiddenText/VisuallyHiddenText.d.ts.map +1 -1
  1273. package/lib/hooks/index.d.ts +5 -0
  1274. package/lib/hooks/index.d.ts.map +1 -1
  1275. package/lib/hooks/index.js +5 -0
  1276. package/lib/hooks/index.js.map +1 -1
  1277. package/lib/hooks/useActiveDescendant.d.ts +6 -1
  1278. package/lib/hooks/useActiveDescendant.d.ts.map +1 -1
  1279. package/lib/hooks/useActiveDescendant.js +5 -5
  1280. package/lib/hooks/useActiveDescendant.js.map +1 -1
  1281. package/lib/hooks/useAnimatedText.d.ts +3 -1
  1282. package/lib/hooks/useAnimatedText.d.ts.map +1 -1
  1283. package/lib/hooks/useAnimatedText.js +66 -46
  1284. package/lib/hooks/useAnimatedText.js.map +1 -1
  1285. package/lib/hooks/useArrows.d.ts +27 -7
  1286. package/lib/hooks/useArrows.d.ts.map +1 -1
  1287. package/lib/hooks/useArrows.js +50 -26
  1288. package/lib/hooks/useArrows.js.map +1 -1
  1289. package/lib/hooks/useContentTabIndex.d.ts +17 -0
  1290. package/lib/hooks/useContentTabIndex.d.ts.map +1 -0
  1291. package/lib/hooks/useContentTabIndex.js +48 -0
  1292. package/lib/hooks/useContentTabIndex.js.map +1 -0
  1293. package/lib/hooks/useFocusTrap.d.ts.map +1 -1
  1294. package/lib/hooks/useFocusTrap.js +1 -0
  1295. package/lib/hooks/useFocusTrap.js.map +1 -1
  1296. package/lib/hooks/useFocusWithin.d.ts.map +1 -1
  1297. package/lib/hooks/useFocusWithin.js +11 -6
  1298. package/lib/hooks/useFocusWithin.js.map +1 -1
  1299. package/lib/hooks/useHighlight.d.ts +12 -0
  1300. package/lib/hooks/useHighlight.d.ts.map +1 -0
  1301. package/lib/hooks/useHighlight.js +55 -0
  1302. package/lib/hooks/useHighlight.js.map +1 -0
  1303. package/lib/hooks/useI18n.d.ts +331 -16
  1304. package/lib/hooks/useI18n.d.ts.map +1 -1
  1305. package/lib/hooks/useOS.d.ts +1 -1
  1306. package/lib/hooks/usePreviewContext.d.ts +7 -0
  1307. package/lib/hooks/usePreviewContext.d.ts.map +1 -0
  1308. package/lib/hooks/usePreviewContext.js +12 -0
  1309. package/lib/hooks/usePreviewContext.js.map +1 -0
  1310. package/lib/hooks/usePreviewManager.d.ts +8 -0
  1311. package/lib/hooks/usePreviewManager.d.ts.map +1 -0
  1312. package/lib/hooks/usePreviewManager.js +16 -0
  1313. package/lib/hooks/usePreviewManager.js.map +1 -0
  1314. package/lib/hooks/useScrollStick.js +1 -1
  1315. package/lib/hooks/useScrollStick.js.map +1 -1
  1316. package/lib/hooks/useSpeechRecognition.d.ts +21 -0
  1317. package/lib/hooks/useSpeechRecognition.d.ts.map +1 -0
  1318. package/lib/hooks/useSpeechRecognition.js +123 -0
  1319. package/lib/hooks/useSpeechRecognition.js.map +1 -0
  1320. package/lib/hooks/useThemeMode.d.ts +10 -0
  1321. package/lib/hooks/useThemeMode.d.ts.map +1 -0
  1322. package/lib/hooks/useThemeMode.js +11 -0
  1323. package/lib/hooks/useThemeMode.js.map +1 -0
  1324. package/lib/hooks/useTransitionState.d.ts +3 -2
  1325. package/lib/hooks/useTransitionState.d.ts.map +1 -1
  1326. package/lib/hooks/useTransitionState.js.map +1 -1
  1327. package/lib/i18n/default.d.ts +340 -17
  1328. package/lib/i18n/default.d.ts.map +1 -1
  1329. package/lib/i18n/default.js +379 -36
  1330. package/lib/i18n/default.js.map +1 -1
  1331. package/lib/i18n/i18n.d.ts +331 -16
  1332. package/lib/i18n/i18n.d.ts.map +1 -1
  1333. package/lib/i18n/translate.d.ts +0 -1
  1334. package/lib/i18n/translate.d.ts.map +1 -1
  1335. package/lib/i18n/translate.js +0 -1
  1336. package/lib/i18n/translate.js.map +1 -1
  1337. package/lib/index.d.ts +13 -0
  1338. package/lib/index.d.ts.map +1 -1
  1339. package/lib/index.js +13 -0
  1340. package/lib/index.js.map +1 -1
  1341. package/lib/styles/GlobalStyle.d.ts +3 -3
  1342. package/lib/styles/GlobalStyle.d.ts.map +1 -1
  1343. package/lib/styles/GlobalStyle.js +22 -4
  1344. package/lib/styles/GlobalStyle.js.map +1 -1
  1345. package/lib/styles/animations.d.ts +8 -8
  1346. package/lib/styles/animations.d.ts.map +1 -1
  1347. package/lib/styles/animations.js +71 -53
  1348. package/lib/styles/animations.js.map +1 -1
  1349. package/lib/styles/constants.d.ts +4 -0
  1350. package/lib/styles/constants.d.ts.map +1 -1
  1351. package/lib/styles/constants.js +12 -0
  1352. package/lib/styles/constants.js.map +1 -1
  1353. package/lib/styles/mixins.d.ts +3 -3
  1354. package/lib/styles/mixins.d.ts.map +1 -1
  1355. package/lib/styles/utils.d.ts +35 -4
  1356. package/lib/styles/utils.d.ts.map +1 -1
  1357. package/lib/styles/utils.js +93 -11
  1358. package/lib/styles/utils.js.map +1 -1
  1359. package/lib/theme/index.d.ts +4 -0
  1360. package/lib/theme/index.d.ts.map +1 -1
  1361. package/lib/theme/index.js +4 -0
  1362. package/lib/theme/index.js.map +1 -1
  1363. package/lib/theme/theme.d.ts +348 -0
  1364. package/lib/theme/theme.d.ts.map +1 -1
  1365. package/lib/theme/themeDefinition.json +212 -4
  1366. package/lib/theme/themeOverrides.schema.json +346 -170
  1367. package/lib/theme/themes/andromeda2025Theme.json +2 -2
  1368. package/lib/theme/themes/aries2023DarkTheme.json +22 -0
  1369. package/lib/theme/themes/bootes2025DarkTheme.json +32 -1
  1370. package/lib/theme/themes/bootes2025Theme.json +11 -2
  1371. package/lib/theme/themes/darkTheme.json +22 -0
  1372. package/lib/theme/themes/orionDarkTheme.json +175 -0
  1373. package/lib/theme/themes/orionTheme.json +155 -0
  1374. package/lib/theme/themes/studioDarkTheme.json +25 -7
  1375. package/lib/theme/themes/studioTheme.json +37 -19
  1376. package/lib/theme/themes/virgoDarkTheme.json +206 -0
  1377. package/lib/theme/themes/virgoTheme.json +166 -0
  1378. package/lib/utils/focusHeadingOrContainer.d.ts.map +1 -1
  1379. package/lib/utils/focusHeadingOrContainer.js +2 -17
  1380. package/lib/utils/focusHeadingOrContainer.js.map +1 -1
  1381. package/lib/utils/focusNonInteractiveElement.d.ts +1 -1
  1382. package/lib/utils/focusNonInteractiveElement.d.ts.map +1 -1
  1383. package/lib/utils/focusNonInteractiveElement.js.map +1 -1
  1384. package/lib/utils/formatListToLocaleString.d.ts +0 -1
  1385. package/lib/utils/formatListToLocaleString.d.ts.map +1 -1
  1386. package/lib/utils/formatListToLocaleString.js +0 -1
  1387. package/lib/utils/formatListToLocaleString.js.map +1 -1
  1388. package/lib/utils/getAllPopovers.d.ts.map +1 -1
  1389. package/lib/utils/getAllPopovers.js +2 -1
  1390. package/lib/utils/getAllPopovers.js.map +1 -1
  1391. package/lib/utils/getEffectiveRect.d.ts +13 -0
  1392. package/lib/utils/getEffectiveRect.d.ts.map +1 -0
  1393. package/lib/utils/getEffectiveRect.js +93 -0
  1394. package/lib/utils/getEffectiveRect.js.map +1 -0
  1395. package/lib/utils/getFocusables.d.ts.map +1 -1
  1396. package/lib/utils/getFocusables.js +2 -1
  1397. package/lib/utils/getFocusables.js.map +1 -1
  1398. package/lib/utils/getParentWindow.d.ts +3 -0
  1399. package/lib/utils/getParentWindow.d.ts.map +1 -0
  1400. package/lib/utils/getParentWindow.js +12 -0
  1401. package/lib/utils/getParentWindow.js.map +1 -0
  1402. package/lib/utils/handleLinkClick.d.ts +33 -0
  1403. package/lib/utils/handleLinkClick.d.ts.map +1 -0
  1404. package/lib/utils/handleLinkClick.js +41 -0
  1405. package/lib/utils/handleLinkClick.js.map +1 -0
  1406. package/lib/utils/index.d.ts +3 -0
  1407. package/lib/utils/index.d.ts.map +1 -1
  1408. package/lib/utils/index.js +3 -0
  1409. package/lib/utils/index.js.map +1 -1
  1410. package/lib/utils/markdownTokenizer.d.ts +4 -1
  1411. package/lib/utils/markdownTokenizer.d.ts.map +1 -1
  1412. package/lib/utils/markdownTokenizer.js +46 -13
  1413. package/lib/utils/markdownTokenizer.js.map +1 -1
  1414. package/package.json +6 -5
@@ -1,5 +1,5 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { useState, useEffect, useRef } from 'react';
2
+ import { useState, useEffect, useRef, useCallback } from 'react';
3
3
  import Flex from '../../Flex';
4
4
  import MonthInput from '../Input/MonthInput';
5
5
  import Icon, { registerIcon } from '../../Icon';
@@ -7,25 +7,25 @@ import * as caretLeftIcon from '../../Icon/icons/caret-left.icon';
7
7
  import * as caretRightIcon from '../../Icon/icons/caret-right.icon';
8
8
  import { useConfiguration, useI18n, useTestIds } from '../../../hooks';
9
9
  import { getCalendarTypeFromLocale } from '../Input/utils';
10
- import { getAdjustedUTCDateTime } from '../utils';
10
+ import { getAdjustedUTCDateTime, getAdjustedUTCDateTimeForTimezone } from '../utils';
11
11
  import { getDatePickerTestIds } from '../DateTime.test-ids';
12
12
  import Calendar from './Calendar';
13
- import Weeks from './Weeks';
14
13
  import { StyledDatePicker, StyledDatePickerMonthInput, StyledMonthNavigationButton, StyledMonthPicker } from './DatePicker.styles';
15
14
  import { isValidDate, toDateTimeString } from './utils';
16
15
  registerIcon(caretLeftIcon, caretRightIcon);
17
16
  const DateRangePicker = (props) => {
18
17
  const { locale } = useConfiguration();
19
- const { testId, selected: initial, selectedRange, onChange, min, max, mode, showWeekNumber, ...restProps } = props;
18
+ const { testId, selected: initial, selectedRange, onChange, min, max, mode, showWeekNumber, timeZone, ...restProps } = props;
20
19
  const testIds = useTestIds(testId, getDatePickerTestIds);
20
+ const getNow = useCallback(() => (timeZone ? getAdjustedUTCDateTimeForTimezone(timeZone) : getAdjustedUTCDateTime()), [timeZone]);
21
21
  const [selected, setSelected] = useState(initial);
22
- const [current, setCurrent] = useState(selected && isValidDate(selected) ? selected : new Date());
22
+ const [current, setCurrent] = useState(() => selected && isValidDate(selected) ? selected : getNow());
23
23
  useEffect(() => {
24
24
  if (toDateTimeString(initial) !== toDateTimeString(selected)) {
25
25
  setSelected(initial);
26
- setCurrent(initial || new Date());
26
+ setCurrent(initial || getNow());
27
27
  }
28
- }, [toDateTimeString(initial)]);
28
+ }, [toDateTimeString(initial), getNow]);
29
29
  const calendarRef = useRef(null);
30
30
  useEffect(() => {
31
31
  // need to postpone focusing to make sure onFocusWithin has been attached
@@ -44,7 +44,7 @@ const DateRangePicker = (props) => {
44
44
  newCurrent.setUTCMonth(newCurrent.getUTCMonth() - 1);
45
45
  setCurrent(newCurrent);
46
46
  }, children: _jsx(Icon, { name: 'caret-left' }) }), _jsx(StyledMonthNavigationButton, { "data-testid": testIds.setCurrentDate, label: t('set_current_date_a11y'), icon: true, variant: 'simple', onClick: () => {
47
- const currDate = getAdjustedUTCDateTime();
47
+ const currDate = getNow();
48
48
  setCurrent(currDate);
49
49
  setSelected(currDate);
50
50
  onChange?.(currDate);
@@ -52,13 +52,13 @@ const DateRangePicker = (props) => {
52
52
  const newCurrent = new Date(current);
53
53
  newCurrent.setUTCMonth(newCurrent.getUTCMonth() + 1);
54
54
  setCurrent(newCurrent);
55
- }, children: _jsx(Icon, { name: 'caret-right' }) })] }), _jsxs(Flex, { container: { wrap: 'nowrap' }, children: [showWeekNumber && _jsx(Weeks, { current: current, calendarType: calendarType, disabled: true }), _jsx(Calendar, { ref: calendarRef, selected: selected && isValidDate(selected) ? selected : undefined, current: current, selectedRange: selectedRange, showHighlight: true, calendarType: calendarType, onFocus: date => {
56
- setCurrent(date);
57
- }, onSelect: date => {
58
- setCurrent(date);
59
- setSelected(date);
60
- onChange?.(date);
61
- }, min: min, max: max })] })] }));
55
+ }, children: _jsx(Icon, { name: 'caret-right' }) })] }), _jsx(Flex, { container: { wrap: 'nowrap', justify: 'center' }, children: _jsx(Calendar, { ref: calendarRef, selected: selected && isValidDate(selected) ? selected : undefined, current: current, selectedRange: selectedRange, showHighlight: true, calendarType: calendarType, showWeekNumber: showWeekNumber, onFocus: date => {
56
+ setCurrent(date);
57
+ }, onSelect: date => {
58
+ setCurrent(date);
59
+ setSelected(date);
60
+ onChange?.(date);
61
+ }, min: min, max: max, timeZone: timeZone }) })] }));
62
62
  };
63
63
  export default DateRangePicker;
64
64
  //# sourceMappingURL=DateRangePicker.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"DateRangePicker.js","sourceRoot":"","sources":["../../../../src/components/DateTime/Picker/DateRangePicker.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAGpD,OAAO,IAAI,MAAM,YAAY,CAAC;AAC9B,OAAO,UAAU,MAAM,qBAAqB,CAAC;AAC7C,OAAO,IAAI,EAAE,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAChD,OAAO,KAAK,aAAa,MA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AAI,EAAC,aAAa,GAAG,GACC,IACzB,EACP,MAAC,IAAI,IAAC,SAAS,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,aAChC,cAAc,IAAI,KAAC,KAAK,IAAC,OAAO,EAAE,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,QAAQ,SAAG,EACnF,KAAC,QAAQ,IACP,GAAG,EAAE,WAAW,EAChB,QAAQ,EAAE,QAAQ,IAAI,WAAW,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,EAClE,OAAO,EAAE,OAAO,EAChB,aAAa,EAAE,aAAa,EAC5B,aAAa,QACb,YAAY,EAAE,YAAY,EAC1B,OAAO,EAAE,IAAI,CAAC,EAAE;4BACd,UAAU,CAAC,IAAI,CAAC,CAAC;wBACnB,CAAC,EACD,QAAQ,EAAE,IAAI,CAAC,EAAE;4BACf,UAAU,CAAC,IAAI,CAAC,CAAC;4BACjB,WAAW,CAAC,IAAI,CAAC,CAAC;4BAClB,QAAQ,EAAE,CAAC,IAAI,CAAC,CAAC;wBACnB,CAAC,EACD,GAAG,EAAE,GAAG,EACR,GAAG,EAAE,GAAG,GACR,IACG,IACU,CACpB,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,eAAe,CAAC","sourcesContent":["import { useState, useEffect, useRef } from 'react';\nimport type { FunctionComponent } from 'react';\n\nimport Flex from '../../Flex';\nimport MonthInput from '../Input/MonthInput';\nimport Icon, { registerIcon } from '../../Icon';\nimport * as caretLeftIcon from '../../Icon/icons/caret-left.icon';\nimport * as caretRightIcon from '../../Icon/icons/caret-right.icon';\nimport { useConfiguration, useI18n, useTestIds } from '../../../hooks';\nimport { getCalendarTypeFromLocale } from '../Input/utils';\nimport { getAdjustedUTCDateTime } from '../utils';\nimport { getDatePickerTestIds } from '../DateTime.test-ids';\n\nimport Calendar from './Calendar';\nimport type DatePickerProps from './DatePicker.types';\nimport Weeks from './Weeks';\nimport {\n StyledDatePicker,\n StyledDatePickerMonthInput,\n StyledMonthNavigationButton,\n StyledMonthPicker\n} from './DatePicker.styles';\nimport { isValidDate, toDateTimeString } from './utils';\n\nregisterIcon(caretLeftIcon, caretRightIcon);\n\nexport interface DateRangePickerProps extends DatePickerProps {\n /** Defines dates range that can be set by the user. */\n selectedRange?: { startDate: Date | undefined; endDate: Date | undefined };\n}\n\nconst DateRangePicker: FunctionComponent<DateRangePickerProps> = (props: DateRangePickerProps) => {\n const { locale } = useConfiguration();\n const {\n testId,\n selected: initial,\n selectedRange,\n onChange,\n min,\n max,\n mode,\n showWeekNumber,\n ...restProps\n } = props;\n const testIds = useTestIds(testId, getDatePickerTestIds);\n const [selected, setSelected] = useState(initial);\n const [current, setCurrent] = useState(selected && isValidDate(selected) ? selected : new Date());\n\n useEffect(() => {\n if (toDateTimeString(initial) !== toDateTimeString(selected)) {\n setSelected(initial);\n setCurrent(initial || new Date());\n }\n }, [toDateTimeString(initial)]);\n\n const calendarRef = useRef<HTMLDivElement>(null);\n useEffect(() => {\n // need to postpone focusing to make sure onFocusWithin has been attached\n setTimeout(() => {\n calendarRef.current?.querySelector<HTMLElement>('button[tabindex=\"0\"]:enabled')?.focus();\n });\n }, []);\n\n const calendarType = getCalendarTypeFromLocale(locale);\n const t = useI18n();\n\n return (\n <StyledDatePicker aria-label={t('calendar')} role='region' {...restProps}>\n <Flex as={StyledMonthPicker} container={{ justify: 'between', alignItems: 'end' }}>\n <MonthInput\n data-testid={testIds.month}\n aria-label={t('picker_jump_to_month_and_year')}\n value={current}\n as={StyledDatePickerMonthInput}\n innerLabelsHidden={false}\n required\n role='group'\n onChange={({ valueAsTimestamp }) => {\n const newCurrent = new Date(valueAsTimestamp!);\n newCurrent.setUTCDate(current.getUTCDate());\n setCurrent(newCurrent);\n }}\n min={min}\n max={max}\n />\n <StyledMonthNavigationButton\n data-testid={testIds.previousMonth}\n label={t('picker_prev_month')}\n variant='simple'\n icon\n onClick={() => {\n const newCurrent = new Date(current);\n newCurrent.setUTCMonth(newCurrent.getUTCMonth() - 1);\n setCurrent(newCurrent);\n }}\n >\n <Icon name='caret-left' />\n </StyledMonthNavigationButton>\n <StyledMonthNavigationButton\n data-testid={testIds.setCurrentDate}\n label={t('set_current_date_a11y')}\n icon\n variant='simple'\n onClick={() => {\n const currDate = getAdjustedUTCDateTime();\n setCurrent(currDate);\n setSelected(currDate);\n onChange?.(currDate);\n }}\n >\n <Icon name='calendar-now' />\n </StyledMonthNavigationButton>\n <StyledMonthNavigationButton\n data-testid={testIds.nextMonth}\n label={t('picker_next_month')}\n variant='simple'\n icon\n onClick={() => {\n const newCurrent = new Date(current);\n newCurrent.setUTCMonth(newCurrent.getUTCMonth() + 1);\n setCurrent(newCurrent);\n }}\n >\n <Icon name='caret-right' />\n </StyledMonthNavigationButton>\n </Flex>\n <Flex container={{ wrap: 'nowrap' }}>\n {showWeekNumber && <Weeks current={current} calendarType={calendarType} disabled />}\n <Calendar\n ref={calendarRef}\n selected={selected && isValidDate(selected) ? selected : undefined}\n current={current}\n selectedRange={selectedRange}\n showHighlight\n calendarType={calendarType}\n onFocus={date => {\n setCurrent(date);\n }}\n onSelect={date => {\n setCurrent(date);\n setSelected(date);\n onChange?.(date);\n }}\n min={min}\n max={max}\n />\n </Flex>\n </StyledDatePicker>\n );\n};\n\nexport default DateRangePicker;\n"]}
1
+ {"version":3,"file":"DateRangePicker.js","sourceRoot":"","sources":["../../../../src/components/DateTime/Picker/DateRangePicker.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AAGjE,OAAO,IAAI,MAAM,YAAY,CAAC;AAC9B,OAAO,UAAU,MAAM,qBAAqB,CAAC;AAC7C,OAAO,IAAI,EAAE,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAChD,OAAO,KAAK,aAAa,MAAM,kCAAkC,CAAC;AAClE,OAAO,KAAK,cAAc,MAAM,mCAAmC,CAAC;AACpE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C,UAAU,CAAC,WAAW,EAAE,GAAG,CAAC,CAAC,CAAC;4BACrD,UAAU,CAAC,UAAU,CAAC,CAAC;wBACzB,CAAC,YAED,KAAC,IAAI,IAAC,IAAI,EAAC,aAAa,GAAG,GACC,IACzB,EACP,KAAC,IAAI,IAAC,SAAS,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,YACpD,KAAC,QAAQ,IACP,GAAG,EAAE,WAAW,EAChB,QAAQ,EAAE,QAAQ,IAAI,WAAW,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,EAClE,OAAO,EAAE,OAAO,EAChB,aAAa,EAAE,aAAa,EAC5B,aAAa,QACb,YAAY,EAAE,YAAY,EAC1B,cAAc,EAAE,cAAc,EAC9B,OAAO,EAAE,IAAI,CAAC,EAAE;wBACd,UAAU,CAAC,IAAI,CAAC,CAAC;oBACnB,CAAC,EACD,QAAQ,EAAE,IAAI,CAAC,EAAE;wBACf,UAAU,CAAC,IAAI,CAAC,CAAC;wBACjB,WAAW,CAAC,IAAI,CAAC,CAAC;wBAClB,QAAQ,EAAE,CAAC,IAAI,CAAC,CAAC;oBACnB,CAAC,EACD,GAAG,EAAE,GAAG,EACR,GAAG,EAAE,GAAG,EACR,QAAQ,EAAE,QAAQ,GAClB,GACG,IACU,CACpB,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,eAAe,CAAC","sourcesContent":["import { useState, useEffect, useRef, useCallback } from 'react';\nimport type { FunctionComponent } from 'react';\n\nimport Flex from '../../Flex';\nimport MonthInput from '../Input/MonthInput';\nimport Icon, { registerIcon } from '../../Icon';\nimport * as caretLeftIcon from '../../Icon/icons/caret-left.icon';\nimport * as caretRightIcon from '../../Icon/icons/caret-right.icon';\nimport { useConfiguration, useI18n, useTestIds } from '../../../hooks';\nimport { getCalendarTypeFromLocale } from '../Input/utils';\nimport { getAdjustedUTCDateTime, getAdjustedUTCDateTimeForTimezone } from '../utils';\nimport { getDatePickerTestIds } from '../DateTime.test-ids';\nimport type { CalendarType } from '../Input/local';\n\nimport Calendar from './Calendar';\nimport type DatePickerProps from './DatePicker.types';\nimport {\n StyledDatePicker,\n StyledDatePickerMonthInput,\n StyledMonthNavigationButton,\n StyledMonthPicker\n} from './DatePicker.styles';\nimport { isValidDate, toDateTimeString } from './utils';\n\nregisterIcon(caretLeftIcon, caretRightIcon);\n\nexport interface DateRangePickerProps extends DatePickerProps {\n /** Defines dates range that can be set by the user. */\n selectedRange?: { startDate: Date | undefined; endDate: Date | undefined };\n}\n\nconst DateRangePicker: FunctionComponent<DateRangePickerProps> = (props: DateRangePickerProps) => {\n const { locale } = useConfiguration();\n const {\n testId,\n selected: initial,\n selectedRange,\n onChange,\n min,\n max,\n mode,\n showWeekNumber,\n timeZone,\n ...restProps\n } = props;\n const testIds = useTestIds(testId, getDatePickerTestIds);\n const getNow = useCallback(\n () => (timeZone ? getAdjustedUTCDateTimeForTimezone(timeZone) : getAdjustedUTCDateTime()),\n [timeZone]\n );\n const [selected, setSelected] = useState(initial);\n const [current, setCurrent] = useState(() =>\n selected && isValidDate(selected) ? selected : getNow()\n );\n\n useEffect(() => {\n if (toDateTimeString(initial) !== toDateTimeString(selected)) {\n setSelected(initial);\n setCurrent(initial || getNow());\n }\n }, [toDateTimeString(initial), getNow]);\n\n const calendarRef = useRef<HTMLDivElement>(null);\n useEffect(() => {\n // need to postpone focusing to make sure onFocusWithin has been attached\n setTimeout(() => {\n calendarRef.current?.querySelector<HTMLElement>('button[tabindex=\"0\"]:enabled')?.focus();\n });\n }, []);\n\n const calendarType: CalendarType = getCalendarTypeFromLocale(locale);\n const t = useI18n();\n\n return (\n <StyledDatePicker aria-label={t('calendar')} role='region' {...restProps}>\n <Flex as={StyledMonthPicker} container={{ justify: 'between', alignItems: 'end' }}>\n <MonthInput\n data-testid={testIds.month}\n aria-label={t('picker_jump_to_month_and_year')}\n value={current}\n as={StyledDatePickerMonthInput}\n innerLabelsHidden={false}\n required\n role='group'\n onChange={({ valueAsTimestamp }) => {\n const newCurrent = new Date(valueAsTimestamp!);\n newCurrent.setUTCDate(current.getUTCDate());\n setCurrent(newCurrent);\n }}\n min={min}\n max={max}\n />\n <StyledMonthNavigationButton\n data-testid={testIds.previousMonth}\n label={t('picker_prev_month')}\n variant='simple'\n icon\n onClick={() => {\n const newCurrent = new Date(current);\n newCurrent.setUTCMonth(newCurrent.getUTCMonth() - 1);\n setCurrent(newCurrent);\n }}\n >\n <Icon name='caret-left' />\n </StyledMonthNavigationButton>\n <StyledMonthNavigationButton\n data-testid={testIds.setCurrentDate}\n label={t('set_current_date_a11y')}\n icon\n variant='simple'\n onClick={() => {\n const currDate = getNow();\n setCurrent(currDate);\n setSelected(currDate);\n onChange?.(currDate);\n }}\n >\n <Icon name='calendar-now' />\n </StyledMonthNavigationButton>\n <StyledMonthNavigationButton\n data-testid={testIds.nextMonth}\n label={t('picker_next_month')}\n variant='simple'\n icon\n onClick={() => {\n const newCurrent = new Date(current);\n newCurrent.setUTCMonth(newCurrent.getUTCMonth() + 1);\n setCurrent(newCurrent);\n }}\n >\n <Icon name='caret-right' />\n </StyledMonthNavigationButton>\n </Flex>\n <Flex container={{ wrap: 'nowrap', justify: 'center' }}>\n <Calendar\n ref={calendarRef}\n selected={selected && isValidDate(selected) ? selected : undefined}\n current={current}\n selectedRange={selectedRange}\n showHighlight\n calendarType={calendarType}\n showWeekNumber={showWeekNumber}\n onFocus={date => {\n setCurrent(date);\n }}\n onSelect={date => {\n setCurrent(date);\n setSelected(date);\n onChange?.(date);\n }}\n min={min}\n max={max}\n timeZone={timeZone}\n />\n </Flex>\n </StyledDatePicker>\n );\n};\n\nexport default DateRangePicker;\n"]}
@@ -17,6 +17,8 @@ export interface TimePickerProps extends BaseProps, TestIdProp {
17
17
  interval?: MinuteInterval;
18
18
  /** Defines clock format that overrides locale based format */
19
19
  clockFormat?: ClockFormat;
20
+ /** Display seconds in picker option labels. */
21
+ withSeconds?: boolean;
20
22
  }
21
23
  declare const TimePicker: FunctionComponent<TimePickerProps & ForwardProps>;
22
24
  export default TimePicker;
@@ -1 +1 @@
1
- {"version":3,"file":"TimePicker.d.ts","sourceRoot":"","sources":["../../../../src/components/DateTime/Picker/TimePicker.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAK/C,OAAO,KAAK,EAAE,SAAS,EAAU,YAAY,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAIlF,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAKlD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAEzD,MAAM,WAAW,eAAgB,SAAQ,SAAS,EAAE,UAAU;IAC5D;;;OAGG;IACH,QAAQ,CAAC,EAAE,IAAI,CAAC;IAChB,kDAAkD;IAClD,QAAQ,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,IAAI,CAAC;IAC/B;;;OAGG;IACH,QAAQ,CAAC,EAAE,cAAc,CAAC;IAC1B,8DAA8D;IAC9D,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B;AA4DD,QAAA,MAAM,UAAU,EAAE,iBAAiB,CAAC,eAAe,GAAG,YAAY,CAsHjE,CAAC;AAEF,eAAe,UAAU,CAAC"}
1
+ {"version":3,"file":"TimePicker.d.ts","sourceRoot":"","sources":["../../../../src/components/DateTime/Picker/TimePicker.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAK/C,OAAO,KAAK,EAAE,SAAS,EAAU,YAAY,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAIlF,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAKlD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAEzD,MAAM,WAAW,eAAgB,SAAQ,SAAS,EAAE,UAAU;IAC5D;;;OAGG;IACH,QAAQ,CAAC,EAAE,IAAI,CAAC;IAChB,kDAAkD;IAClD,QAAQ,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,IAAI,CAAC;IAC/B;;;OAGG;IACH,QAAQ,CAAC,EAAE,cAAc,CAAC;IAC1B,8DAA8D;IAC9D,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,+CAA+C;IAC/C,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AA+DD,QAAA,MAAM,UAAU,EAAE,iBAAiB,CAAC,eAAe,GAAG,YAAY,CAkIjE,CAAC;AAEF,eAAe,UAAU,CAAC"}
@@ -18,6 +18,7 @@ const StyledTimePicker = styled.ul `
18
18
  StyledTimePicker.defaultProps = defaultThemeProp;
19
19
  const StyledTimeButton = styled.button(({ theme: { base, components }, selected }) => {
20
20
  const activeColor = tryCatch(() => mix(0.85, base.palette['primary-background'], base.palette.interactive));
21
+ const { spacing } = base;
21
22
  return css `
22
23
  color: ${base.palette['foreground-color']};
23
24
  width: 100%;
@@ -32,16 +33,17 @@ const StyledTimeButton = styled.button(({ theme: { base, components }, selected
32
33
  background-color: ${selected ? activeColor : 'transparent'};
33
34
 
34
35
  > span {
35
- margin-inline-end: 0.125rem;
36
+ margin-inline-end: calc(0.25 * ${spacing});
36
37
  &:first-child {
37
38
  margin-inline-start: ${components['form-control']['border-width']};
39
+ padding-inline-start: ${spacing};
38
40
  }
39
- &:nth-child(2) {
40
- margin-inline-start: 0.125rem;
41
- }
42
- &:first-child,
41
+ &:nth-child(2),
43
42
  &:nth-child(3) {
44
- padding-inline-start: 0.5rem;
43
+ margin-inline-start: calc(0.25 * ${spacing});
44
+ }
45
+ &[data-meridiem] {
46
+ padding-inline-start: calc(0.75 * ${spacing});
45
47
  }
46
48
  }
47
49
 
@@ -58,7 +60,7 @@ const StyledTimeItem = styled.li `
58
60
  StyledTimeItem.defaultProps = defaultThemeProp;
59
61
  const TimePicker = (props) => {
60
62
  const { locale } = useConfiguration();
61
- const { testId, selected = new Date(0), interval = 30, clockFormat, onSelect, ...restProps } = props;
63
+ const { testId, selected = new Date(0), interval = 30, clockFormat, withSeconds, onSelect, ...restProps } = props;
62
64
  const intervalInMS = interval * 60000;
63
65
  const { hourCycle: defaultHourCycle } = useMemo(() => getIntlDateTimeFormatFromCache(locale, {
64
66
  hour: '2-digit',
@@ -66,12 +68,13 @@ const TimePicker = (props) => {
66
68
  }).resolvedOptions(), [clockFormat, locale]);
67
69
  const actionsList = Array.from(getIntervalGenerator(intervalInMS), time => {
68
70
  const date = selected ? new Date(new Date().setUTCHours(0, 0, 0, 0)) : new Date(selected);
69
- date.setUTCHours(time.getUTCHours(), time.getUTCMinutes());
71
+ date.setUTCHours(time.getUTCHours(), time.getUTCMinutes(), time.getUTCSeconds());
70
72
  return {
71
73
  id: date.getTime().toString(),
72
74
  text: Intl.DateTimeFormat(locale, {
73
75
  hour: '2-digit',
74
76
  minute: '2-digit',
77
+ ...(withSeconds && { second: '2-digit' }),
75
78
  timeZone: 'UTC',
76
79
  /** Use this to fix Chrome https://bugs.chromium.org/p/chromium/issues/detail?id=1045791 */
77
80
  hourCycle: defaultHourCycle === 'h24' ? 'h23' : defaultHourCycle
@@ -80,7 +83,8 @@ const TimePicker = (props) => {
80
83
  });
81
84
  const isSelected = (date) => {
82
85
  return (selected?.getUTCHours() === date.getUTCHours() &&
83
- selected?.getUTCMinutes() === date.getUTCMinutes());
86
+ selected?.getUTCMinutes() === date.getUTCMinutes() &&
87
+ (!withSeconds || selected?.getUTCSeconds() === date.getUTCSeconds()));
84
88
  };
85
89
  const [buttonEl, setButtonEl] = useElement();
86
90
  const menuRef = useRef(null);
@@ -91,8 +95,12 @@ const TimePicker = (props) => {
91
95
  allowTabFocus: false
92
96
  });
93
97
  const renderTime = (text) => {
94
- const [hour, minute, meridiem] = text.split(/:| /);
95
- return (_jsxs(_Fragment, { children: [_jsx("span", { children: hour }), ":", _jsx("span", { children: minute }), meridiem && _jsx("span", { children: meridiem })] }));
98
+ const parts = text.split(/:| /);
99
+ const hour = parts[0];
100
+ const minute = parts[1];
101
+ const second = withSeconds ? parts[2] : undefined;
102
+ const meridiem = withSeconds ? parts[3] : parts[2];
103
+ return (_jsxs(_Fragment, { children: [_jsx("span", { children: hour }), ":", _jsx("span", { children: minute }), second !== undefined && (_jsxs(_Fragment, { children: [":", _jsx("span", { children: second })] })), meridiem && _jsx("span", { "data-meridiem": true, children: meridiem })] }));
96
104
  };
97
105
  const setTabIndexes = useCallback(() => {
98
106
  const focusEl = menuRef.current;
@@ -1 +1 @@
1
- {"version":3,"file":"TimePicker.js","sourceRoot":"","sources":["../../../../src/components/DateTime/Picker/TimePicker.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAEhE,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAE/B,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAElD,OAAO,MAAM,MAAM,cAAc,CAAC;AAClC,OAAO,EAAE,SAAS,EAAE,gBAAgB,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AACzE,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAElD,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,8BAA8B,EAAE,MAAM,UAAU,CAAC;AAE1D,OAAO,EAAE,oBAAoB,EAAE,MAAM,SAAS,CAAC;AAoB/C,MAAM,gBAAgB,GAAG,MAAM,CAAC,EAAE,CAAA;;;;;CAKjC,CAAC;AAEF,gBAAgB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAEjD,MAAM,gBAAgB,GAAG,MAAM,CAAC,MAAM,CACpC,CAAC,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,UAAU,EAAE,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,CAAC;IACH,CAAC,EAAE,CAAC,QAAQ,CAAC,CAAC,CAAC;IAEf,SAAS,CAAC,GAAG,EAAE;QACb,QAAQ,EAAE,KAAK,EAAE,CAAC;QAClB,aAAa,EAAE,CAAC;IAClB,CAAC,EAAE,CAAC,QAAQ,CAAC,CAAC,CAAC;IAEf,OAAO,CACL,KAAC,gBAAgB,mBAAc,MAAM,EAAE,IAAI,EAAC,MAAM,EAAC,QAAQ,EAAE,CAAC,CAAC,EAAE,GAAG,EAAE,OAAO,KAAM,SAAS,YACzF,WAAW,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,EAAU,EAAE,EAAE;YACxC,MAAM,IAAI,GAAG,IAAI,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC;YAClC,OAAO,CACL,KAAC,cAAc,IAAC,IAAI,EAAC,cAAc,YACjC,KAAC,gBAAgB,IACf,IAAI,EAAC,UAAU,EACf,EAAE,EAAE,MAAM,EACV,OAAO,EAAC,QAAQ,EAChB,GAAG,EAAE,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,IAAI,gBAC9B,IAAI,EAChB,QAAQ,EAAE,UAAU,CAAC,IAAI,CAAC,kBACZ,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,SAAS,EACnD,OAAO,EAAE,UAAU,CAAC,IAAI,CAAC,EACzB,OAAO,EAAE,GAAG,EAAE;wBACZ,QAAQ,EAAE,CAAC,IAAI,CAAC,CAAC;oBACnB,CAAC,EACD,QAAQ,EAAC,IAAI,YAEZ,UAAU,CAAC,IAAI,CAAC,GACA,IAhBoB,EAAE,CAiB1B,CAClB,CAAC;QACJ,CAAC,CAAC,GACe,CACpB,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,UAAU,CAAC","sourcesContent":["import { useCallback, useEffect, useMemo, useRef } from 'react';\nimport type { FunctionComponent } from 'react';\nimport styled, { css } from 'styled-components';\nimport { mix } from 'polished';\n\nimport { defaultThemeProp } from '../../../theme';\nimport type { BaseProps, Action, ForwardProps, TestIdProp } from '../../../types';\nimport Button from '../../Button';\nimport { useArrows, useConfiguration, useElement } from '../../../hooks';\nimport { is12HClockFormat } from '../Input/utils';\nimport type { ClockFormat } from '../Input/utils';\nimport { tryCatch } from '../../../utils';\nimport { getIntlDateTimeFormatFromCache } from '../utils';\n\nimport { getIntervalGenerator } from './utils';\nimport type { MinuteInterval } from './DatePicker.types';\n\nexport interface TimePickerProps extends BaseProps, TestIdProp {\n /**\n * Defines default time that will be selected when the Time Picker is opened.\n * @default new Date()\n */\n selected?: Date;\n /** Callback fired when selected value changes. */\n onSelect: (date: Date) => void;\n /**\n * Defines interval for time picker options (in minutes).\n * @default 30\n */\n interval?: MinuteInterval;\n /** Defines clock format that overrides locale based format */\n clockFormat?: ClockFormat;\n}\n\nconst StyledTimePicker = styled.ul`\n list-style: none;\n max-height: 10rem;\n overflow: auto;\n width: 100%;\n`;\n\nStyledTimePicker.defaultProps = defaultThemeProp;\n\nconst StyledTimeButton = styled.button<TimePickerProps>(\n ({ theme: { base, components }, selected }) => {\n const activeColor = tryCatch(() =>\n mix(0.85, base.palette['primary-background'], base.palette.interactive)\n );\n\n return css`\n color: ${base.palette['foreground-color']};\n width: 100%;\n border-radius: inherit;\n overflow: hidden;\n text-align: start;\n text-overflow: ellipsis;\n white-space: nowrap;\n border-width: 0;\n justify-content: start;\n padding: 0;\n background-color: ${selected ? activeColor : 'transparent'};\n\n > span {\n margin-inline-end: 0.125rem;\n &:first-child {\n margin-inline-start: ${components['form-control']['border-width']};\n }\n &:nth-child(2) {\n margin-inline-start: 0.125rem;\n }\n &:first-child,\n &:nth-child(3) {\n padding-inline-start: 0.5rem;\n }\n }\n\n &:enabled:focus,\n &:not([disabled]):focus {\n box-shadow: ${base.shadow['focus-inset']};\n }\n `;\n }\n);\n\nStyledTimeButton.defaultProps = defaultThemeProp;\n\nconst StyledTimeItem = styled.li`\n border-radius: 0;\n`;\n\nStyledTimeItem.defaultProps = defaultThemeProp;\n\nconst TimePicker: FunctionComponent<TimePickerProps & ForwardProps> = (props: TimePickerProps) => {\n const { locale } = useConfiguration();\n const {\n testId,\n selected = new Date(0),\n interval = 30,\n clockFormat,\n onSelect,\n ...restProps\n } = props;\n\n const intervalInMS = interval * 60000;\n\n const { hourCycle: defaultHourCycle } = useMemo(\n () =>\n getIntlDateTimeFormatFromCache(locale, {\n hour: '2-digit',\n hour12: clockFormat ? clockFormat === 12 : is12HClockFormat(locale)\n }).resolvedOptions(),\n [clockFormat, locale]\n );\n\n const actionsList = Array.from(getIntervalGenerator(intervalInMS), time => {\n const date = selected ? new Date(new Date().setUTCHours(0, 0, 0, 0)) : new Date(selected);\n date.setUTCHours(time.getUTCHours(), time.getUTCMinutes());\n return {\n id: date.getTime().toString(),\n text: Intl.DateTimeFormat(locale, {\n hour: '2-digit',\n minute: '2-digit',\n timeZone: 'UTC',\n /** Use this to fix Chrome https://bugs.chromium.org/p/chromium/issues/detail?id=1045791 */\n hourCycle: defaultHourCycle === 'h24' ? 'h23' : defaultHourCycle\n }).format(date)\n };\n });\n\n const isSelected = (date: Date) => {\n return (\n selected?.getUTCHours() === date.getUTCHours() &&\n selected?.getUTCMinutes() === date.getUTCMinutes()\n );\n };\n\n const [buttonEl, setButtonEl] = useElement<HTMLElement>();\n const menuRef = useRef<HTMLUListElement>(null);\n\n useArrows(menuRef, {\n selector: 'button',\n cycle: true,\n dir: 'up-down',\n allowTabFocus: false\n });\n\n const renderTime = (text: string) => {\n const [hour, minute, meridiem] = text.split(/:| /);\n return (\n <>\n <span>{hour}</span>:<span>{minute}</span>\n {meridiem && <span>{meridiem}</span>}\n </>\n );\n };\n\n const setTabIndexes = useCallback(() => {\n const focusEl = menuRef.current;\n if (!focusEl) return;\n const focusableElements = Array.from(focusEl.querySelectorAll('button'));\n\n if (focusableElements.length > 0) {\n let isChecked = false;\n focusableElements.slice(1).forEach(item => {\n const checked = (item as HTMLInputElement).checked;\n if (checked) {\n isChecked = true;\n item.tabIndex = 0;\n } else item.tabIndex = -1;\n });\n\n if (!isChecked) {\n (focusableElements[0] as HTMLElement).tabIndex = 0;\n focusableElements[0].focus();\n }\n }\n }, [selected]);\n\n useEffect(() => {\n buttonEl?.focus();\n setTabIndexes();\n }, [buttonEl]);\n\n return (\n <StyledTimePicker data-testid={testId} role='menu' tabIndex={-1} ref={menuRef} {...restProps}>\n {actionsList.map(({ text, id }: Action) => {\n const item = new Date(Number(id));\n return (\n <StyledTimeItem role='presentation' key={id}>\n <StyledTimeButton\n role='menuitem'\n as={Button}\n variant='simple'\n ref={isSelected(item) ? setButtonEl : null}\n aria-label={text}\n selected={isSelected(item)}\n aria-current={isSelected(item) ? 'time' : undefined}\n checked={isSelected(item)}\n onClick={() => {\n onSelect?.(item);\n }}\n tabIndex='-1'\n >\n {renderTime(text)}\n </StyledTimeButton>\n </StyledTimeItem>\n );\n })}\n </StyledTimePicker>\n );\n};\n\nexport default TimePicker;\n"]}
1
+ {"version":3,"file":"TimePicker.js","sourceRoot":"","sources":["../../../../src/components/DateTime/Picker/TimePicker.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAEhE,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAE/B,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAElD,OAAO,MAAM,MAAM,cAAc,CAAC;AAClC,OAAO,EAAE,SAAS,EAAE,gBAAgB,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AACzE,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAElD,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAC1C,OAAO,EAAE,8BAA8B,EAAE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AAQ,EAAE,CAAC,CAAC,EAAE,GAAG,EAAE,OAAO,KAAM,SAAS,YACzF,WAAW,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,EAAE,EAAE,EAAU,EAAE,EAAE;YACxC,MAAM,IAAI,GAAG,IAAI,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC;YAClC,OAAO,CACL,KAAC,cAAc,IAAC,IAAI,EAAC,cAAc,YACjC,KAAC,gBAAgB,IACf,IAAI,EAAC,UAAU,EACf,EAAE,EAAE,MAAM,EACV,OAAO,EAAC,QAAQ,EAChB,GAAG,EAAE,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,IAAI,gBAC9B,IAAI,EAChB,QAAQ,EAAE,UAAU,CAAC,IAAI,CAAC,kBACZ,UAAU,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,SAAS,EACnD,OAAO,EAAE,UAAU,CAAC,IAAI,CAAC,EACzB,OAAO,EAAE,GAAG,EAAE;wBACZ,QAAQ,EAAE,CAAC,IAAI,CAAC,CAAC;oBACnB,CAAC,EACD,QAAQ,EAAC,IAAI,YAEZ,UAAU,CAAC,IAAI,CAAC,GACA,IAhBoB,EAAE,CAiB1B,CAClB,CAAC;QACJ,CAAC,CAAC,GACe,CACpB,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,UAAU,CAAC","sourcesContent":["import { useCallback, useEffect, useMemo, useRef } from 'react';\nimport type { FunctionComponent } from 'react';\nimport styled, { css } from 'styled-components';\nimport { mix } from 'polished';\n\nimport { defaultThemeProp } from '../../../theme';\nimport type { BaseProps, Action, ForwardProps, TestIdProp } from '../../../types';\nimport Button from '../../Button';\nimport { useArrows, useConfiguration, useElement } from '../../../hooks';\nimport { is12HClockFormat } from '../Input/utils';\nimport type { ClockFormat } from '../Input/utils';\nimport { tryCatch } from '../../../utils';\nimport { getIntlDateTimeFormatFromCache } from '../utils';\n\nimport { getIntervalGenerator } from './utils';\nimport type { MinuteInterval } from './DatePicker.types';\n\nexport interface TimePickerProps extends BaseProps, TestIdProp {\n /**\n * Defines default time that will be selected when the Time Picker is opened.\n * @default new Date()\n */\n selected?: Date;\n /** Callback fired when selected value changes. */\n onSelect: (date: Date) => void;\n /**\n * Defines interval for time picker options (in minutes).\n * @default 30\n */\n interval?: MinuteInterval;\n /** Defines clock format that overrides locale based format */\n clockFormat?: ClockFormat;\n /** Display seconds in picker option labels. */\n withSeconds?: boolean;\n}\n\nconst StyledTimePicker = styled.ul`\n list-style: none;\n max-height: 10rem;\n overflow: auto;\n width: 100%;\n`;\n\nStyledTimePicker.defaultProps = defaultThemeProp;\n\nconst StyledTimeButton = styled.button<TimePickerProps>(\n ({ theme: { base, components }, selected }) => {\n const activeColor = tryCatch(() =>\n mix(0.85, base.palette['primary-background'], base.palette.interactive)\n );\n\n const { spacing } = base;\n\n return css`\n color: ${base.palette['foreground-color']};\n width: 100%;\n border-radius: inherit;\n overflow: hidden;\n text-align: start;\n text-overflow: ellipsis;\n white-space: nowrap;\n border-width: 0;\n justify-content: start;\n padding: 0;\n background-color: ${selected ? activeColor : 'transparent'};\n\n > span {\n margin-inline-end: calc(0.25 * ${spacing});\n &:first-child {\n margin-inline-start: ${components['form-control']['border-width']};\n padding-inline-start: ${spacing};\n }\n &:nth-child(2),\n &:nth-child(3) {\n margin-inline-start: calc(0.25 * ${spacing});\n }\n &[data-meridiem] {\n padding-inline-start: calc(0.75 * ${spacing});\n }\n }\n\n &:enabled:focus,\n &:not([disabled]):focus {\n box-shadow: ${base.shadow['focus-inset']};\n }\n `;\n }\n);\n\nStyledTimeButton.defaultProps = defaultThemeProp;\n\nconst StyledTimeItem = styled.li`\n border-radius: 0;\n`;\n\nStyledTimeItem.defaultProps = defaultThemeProp;\n\nconst TimePicker: FunctionComponent<TimePickerProps & ForwardProps> = (props: TimePickerProps) => {\n const { locale } = useConfiguration();\n const {\n testId,\n selected = new Date(0),\n interval = 30,\n clockFormat,\n withSeconds,\n onSelect,\n ...restProps\n } = props;\n\n const intervalInMS = interval * 60000;\n\n const { hourCycle: defaultHourCycle } = useMemo(\n () =>\n getIntlDateTimeFormatFromCache(locale, {\n hour: '2-digit',\n hour12: clockFormat ? clockFormat === 12 : is12HClockFormat(locale)\n }).resolvedOptions(),\n [clockFormat, locale]\n );\n\n const actionsList = Array.from(getIntervalGenerator(intervalInMS), time => {\n const date = selected ? new Date(new Date().setUTCHours(0, 0, 0, 0)) : new Date(selected);\n date.setUTCHours(time.getUTCHours(), time.getUTCMinutes(), time.getUTCSeconds());\n return {\n id: date.getTime().toString(),\n text: Intl.DateTimeFormat(locale, {\n hour: '2-digit',\n minute: '2-digit',\n ...(withSeconds && { second: '2-digit' }),\n timeZone: 'UTC',\n /** Use this to fix Chrome https://bugs.chromium.org/p/chromium/issues/detail?id=1045791 */\n hourCycle: defaultHourCycle === 'h24' ? 'h23' : defaultHourCycle\n }).format(date)\n };\n });\n\n const isSelected = (date: Date) => {\n return (\n selected?.getUTCHours() === date.getUTCHours() &&\n selected?.getUTCMinutes() === date.getUTCMinutes() &&\n (!withSeconds || selected?.getUTCSeconds() === date.getUTCSeconds())\n );\n };\n\n const [buttonEl, setButtonEl] = useElement<HTMLElement>();\n const menuRef = useRef<HTMLUListElement>(null);\n\n useArrows(menuRef, {\n selector: 'button',\n cycle: true,\n dir: 'up-down',\n allowTabFocus: false\n });\n\n const renderTime = (text: string) => {\n const parts = text.split(/:| /);\n const hour = parts[0];\n const minute = parts[1];\n const second = withSeconds ? parts[2] : undefined;\n const meridiem = withSeconds ? parts[3] : parts[2];\n return (\n <>\n <span>{hour}</span>:<span>{minute}</span>\n {second !== undefined && (\n <>\n :<span>{second}</span>\n </>\n )}\n {meridiem && <span data-meridiem>{meridiem}</span>}\n </>\n );\n };\n\n const setTabIndexes = useCallback(() => {\n const focusEl = menuRef.current;\n if (!focusEl) return;\n const focusableElements = Array.from(focusEl.querySelectorAll('button'));\n\n if (focusableElements.length > 0) {\n let isChecked = false;\n focusableElements.slice(1).forEach(item => {\n const checked = (item as HTMLInputElement).checked;\n if (checked) {\n isChecked = true;\n item.tabIndex = 0;\n } else item.tabIndex = -1;\n });\n\n if (!isChecked) {\n (focusableElements[0] as HTMLElement).tabIndex = 0;\n focusableElements[0].focus();\n }\n }\n }, [selected]);\n\n useEffect(() => {\n buttonEl?.focus();\n setTabIndexes();\n }, [buttonEl]);\n\n return (\n <StyledTimePicker data-testid={testId} role='menu' tabIndex={-1} ref={menuRef} {...restProps}>\n {actionsList.map(({ text, id }: Action) => {\n const item = new Date(Number(id));\n return (\n <StyledTimeItem role='presentation' key={id}>\n <StyledTimeButton\n role='menuitem'\n as={Button}\n variant='simple'\n ref={isSelected(item) ? setButtonEl : null}\n aria-label={text}\n selected={isSelected(item)}\n aria-current={isSelected(item) ? 'time' : undefined}\n checked={isSelected(item)}\n onClick={() => {\n onSelect?.(item);\n }}\n tabIndex='-1'\n >\n {renderTime(text)}\n </StyledTimeButton>\n </StyledTimeItem>\n );\n })}\n </StyledTimePicker>\n );\n};\n\nexport default TimePicker;\n"]}
@@ -1,4 +1,5 @@
1
1
  import type { FC } from 'react';
2
+ import { type CalendarType } from '../Input/local';
2
3
  import type { ForwardProps } from '../../../types';
3
4
  import type { FormControlProps } from '../../FormControl';
4
5
  export interface WeeksProps {
@@ -19,7 +20,7 @@ export interface WeeksProps {
19
20
  /** Callback fired when new week is selected. */
20
21
  onSelect?: (date: Date) => void;
21
22
  /** Sets the type of calendar to be used. This will be determined by locale if no value is provided. */
22
- calendarType?: string;
23
+ calendarType?: CalendarType;
23
24
  /** Defines minimum available value that can be selected by the user. */
24
25
  min?: string | number | Date;
25
26
  /** Defines maximum available value that can be selected by the user. */
@@ -29,7 +30,7 @@ export interface WeeksProps {
29
30
  /** Should text be in long or short format (ie. only number). */
30
31
  size?: 'short' | 'long';
31
32
  }
32
- export declare const StyledWeekNumbers: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
33
+ export declare const StyledWeekNumbers: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
33
34
  declare const Weeks: FC<WeeksProps & ForwardProps>;
34
35
  export default Weeks;
35
36
  //# sourceMappingURL=Weeks.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Weeks.d.ts","sourceRoot":"","sources":["../../../../src/components/DateTime/Picker/Weeks.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,EAAuC,MAAM,OAAO,CAAC;AAUrE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AACnD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAK1D,MAAM,WAAW,UAAU;IACzB;;;OAGG;IACH,EAAE,CAAC,EAAE,gBAAgB,CAAC,IAAI,CAAC,CAAC;IAC5B,iFAAiF;IACjF,QAAQ,CAAC,EAAE,IAAI,CAAC;IAChB;;;OAGG;IACH,OAAO,CAAC,EAAE,IAAI,CAAC;IACf,iDAAiD;IACjD,OAAO,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,IAAI,CAAC;IAC/B,gDAAgD;IAChD,QAAQ,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,IAAI,CAAC;IAChC,uGAAuG;IACvG,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,wEAAwE;IACxE,GAAG,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IAC7B,wEAAwE;IACxE,GAAG,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;IAC7B,+DAA+D;IAC/D,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,gEAAgE;IAChE,IAAI,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;CACzB;AAED,eAAO,MAAM,iBAAiB,yGAG7B,CAAC;AA0BF,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AAC"}
@@ -5,7 +5,7 @@ import Flex from '../../Flex';
5
5
  import { defaultThemeProp } from '../../../theme';
6
6
  import Text from '../../Text';
7
7
  import { cap } from '../../../utils';
8
- import { getDateOfISOWeek, getWeek, parseToDate, toUTCDateString } from '../Input/utils';
8
+ import { getDateOfWeek, getWeek, parseToDate, toUTCDateString } from '../Input/utils';
9
9
  import { useConfiguration, useConsolidatedRef, useFocusWithin } from '../../../hooks';
10
10
  import { CALENDAR_TYPES } from '../Input/local';
11
11
  import { StyledColumnLabel, StyledPick } from './Calendar.styles';
@@ -70,11 +70,11 @@ const Weeks = forwardRef(function Weeks(props, ref) {
70
70
  const isChecked = (day) => {
71
71
  return (selected &&
72
72
  toUTCDateString(day) ===
73
- toUTCDateString(getDateOfISOWeek(getWeek(selected, calendarType, 'UTC'), selected.getFullYear())));
73
+ toUTCDateString(getDateOfWeek(getWeek(selected, calendarType, 'UTC'), selected.getFullYear(), calendarType)));
74
74
  };
75
75
  const isFocused = (day) => {
76
76
  return (toUTCDateString(day) ===
77
- toUTCDateString(getDateOfISOWeek(getWeek(focusedWeek, calendarType, 'UTC'), focusedWeek.getFullYear())));
77
+ toUTCDateString(getDateOfWeek(getWeek(focusedWeek, calendarType, 'UTC'), focusedWeek.getFullYear(), calendarType)));
78
78
  };
79
79
  const displayNames = new Intl.DisplayNames(locale, {
80
80
  style: 'long',
@@ -85,14 +85,14 @@ const Weeks = forwardRef(function Weeks(props, ref) {
85
85
  type: 'dateTimeField'
86
86
  });
87
87
  const weeks = getWeeksOfMonth(current, calendarType).map(({ weekNo, weekYear }) => {
88
- const dateOfISOWeek = getDateOfISOWeek(weekNo, weekYear);
89
- return (_jsxs(StyledWeekNumber, { variant: 'simple', icon: false, type: 'button', loading: false, ref: isFocused(dateOfISOWeek)
88
+ const dateOfWeek = getDateOfWeek(weekNo, weekYear, calendarType);
89
+ return (_jsxs(StyledWeekNumber, { variant: 'simple', icon: false, type: 'button', loading: false, ref: isFocused(dateOfWeek)
90
90
  ? (focusedRef) => {
91
91
  if (hasFocus)
92
92
  focusedRef?.focus();
93
93
  }
94
- : undefined, tabIndex: isFocused(dateOfISOWeek) ? 0 : -1, disabled: isDisabled(dateOfISOWeek), "aria-selected": isChecked(dateOfISOWeek) || undefined, "aria-label": `${displayNames.of('weekOfYear')} ${weekNo.toString()} ${weekYear.toString()}`, onClick: () => {
95
- onSelect?.(dateOfISOWeek);
94
+ : undefined, tabIndex: isFocused(dateOfWeek) ? 0 : -1, disabled: isDisabled(dateOfWeek), "aria-selected": isChecked(dateOfWeek) || undefined, "aria-label": `${displayNames.of('weekOfYear')} ${weekNo.toString()} ${weekYear.toString()}`, onClick: () => {
95
+ onSelect?.(dateOfWeek);
96
96
  }, children: [size === 'long' && `${cap(displayNames.of('weekOfYear'))} `, weekNo.toString()] }, weekNo));
97
97
  });
98
98
  const label = size === 'short' ? (_jsx(Text, { as: StyledColumnLabel, forwardedAs: 'abbr', title: cap(displayNames.of('weekOfYear')), children: cap(displayNamesShort.of('weekOfYear')) })) : (_jsx(Text, { as: StyledColumnLabel, children: cap(displayNames.of('weekOfYear')) }));
@@ -1 +1 @@
1
- {"version":3,"file":"Weeks.js","sourceRoot":"","sources":["../../../../src/components/DateTime/Picker/Weeks.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,eAAe,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAE9D,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,IAAI,MAAM,YAAY,CAAC;AAC9B,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,IAAI,MAAM,YAAY,CAAC;AAC9B,OAAO,EAAE,GAAG,EAAE,MAAM,gBAAgB,CAAC;AACrC,OAAO,EAAE,gBAAgB,EAAE,OAAO,EAAE,WAAW,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AACzF,OAAO,EAAE,gBAAgB,EAAE,kBAAkB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CAAC,YACtF,GAAG,CAAC,iBAAiB,CAAC,EAAE,CAAC,YAAY,CAAC,CAAC,GACnC,CACR,CAAC,CAAC,CAAC,CACF,KAAC,IAAI,IAAC,EAAE,EAAE,iBAAiB,YAAG,GAAG,CAAC,YAAY,CAAC,EAAE,CAAC,YAAY,CAAC,CAAC,GAAQ,CACzE,CAAC;IAEJ,OAAO,CACL,MAAC,IAAI,IACH,EAAE,EAAE,iBAAiB,EACrB,SAAS,EAAE,EAAE,SAAS,EAAE,QAAQ,EAAE,EAClC,GAAG,EAAE,YAAY,EACjB,SAAS,EAAE,SAAS,aAEnB,KAAK,EACL,KAAK,IACD,CACR,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,eAAe,KAAK,CAAC","sourcesContent":["import { useLayoutEffect, useState, forwardRef } from 'react';\nimport type { FC, KeyboardEvent, PropsWithoutRef, Ref } from 'react';\nimport styled, { css } from 'styled-components';\n\nimport Flex from '../../Flex';\nimport { defaultThemeProp } from '../../../theme';\nimport Text from '../../Text';\nimport { cap } from '../../../utils';\nimport { getDateOfISOWeek, getWeek, parseToDate, toUTCDateString } from '../Input/utils';\nimport { useConfiguration, useConsolidatedRef, useFocusWithin } from '../../../hooks';\nimport { CALENDAR_TYPES } from '../Input/local';\nimport type { ForwardProps } from '../../../types';\nimport type { FormControlProps } from '../../FormControl';\n\nimport { StyledColumnLabel, StyledPick } from './Calendar.styles';\nimport { getWeeksOfMonth } from './utils';\n\nexport interface WeeksProps {\n /**\n * Sets DOM id for the control and associates label element via 'for' attribute.\n * If an id is not pass, a random id will be generated for any render.\n */\n id?: FormControlProps['id'];\n /** Defines default week that will be selected when the Date Picker is opened. */\n selected?: Date;\n /**\n * Defines default week that will be focused initially when the Date Picker is opened.\n * @default new Date()\n */\n current?: Date;\n /** Callback fired when user focuses new week. */\n onFocus?: (date: Date) => void;\n /** Callback fired when new week is selected. */\n onSelect?: (date: Date) => void;\n /** Sets the type of calendar to be used. This will be determined by locale if no value is provided. */\n calendarType?: string;\n /** Defines minimum available value that can be selected by the user. */\n min?: string | number | Date;\n /** Defines maximum available value that can be selected by the user. */\n max?: string | number | Date;\n /** Set the calendar to disabled state, ie. non-interactive. */\n disabled?: boolean;\n /** Should text be in long or short format (ie. only number). */\n size?: 'short' | 'long';\n}\n\nexport const StyledWeekNumbers = styled.div`\n margin-inline-end: ${props => props.theme.base.spacing};\n color: rgba(0, 0, 0, 0.75);\n`;\n\nStyledWeekNumbers.defaultProps = defaultThemeProp;\n\nconst StyledWeekNumber = styled(StyledPick)(props => {\n const {\n theme: {\n base: { 'border-radius': borderRadius }\n }\n } = props;\n\n return css`\n &:disabled {\n &:nth-child(2) {\n border-radius: calc(0.5 * ${borderRadius}) calc(0.5 * ${borderRadius}) 0 0;\n }\n\n &:last-child {\n border-radius: 0 0 calc(0.5 * ${borderRadius}) calc(0.5 * ${borderRadius});\n }\n }\n `;\n});\n\nStyledWeekNumber.defaultProps = defaultThemeProp;\n\nconst Weeks: FC<WeeksProps & ForwardProps> = forwardRef(function Weeks(\n props: PropsWithoutRef<WeeksProps>,\n ref: Ref<HTMLButtonElement>\n) {\n const {\n selected,\n current = selected ? new Date(selected.getTime()) : new Date(),\n calendarType = CALENDAR_TYPES.ISO_8601,\n onSelect,\n onFocus,\n disabled = false,\n size = 'short'\n } = props;\n\n const { locale } = useConfiguration();\n\n const [focusedWeek, setFocusedWeek] = useState(current);\n useLayoutEffect(() => {\n setFocusedWeek(current);\n }, [current.getUTCFullYear(), current.getUTCMonth()]);\n\n let newFocused: Date;\n const onKeyDown = (ev: KeyboardEvent<HTMLElement>) => {\n if (['ArrowUp', 'ArrowDown', 'Enter'].includes(ev.key)) ev.preventDefault();\n switch (ev.key) {\n case 'ArrowUp':\n newFocused = new Date(focusedWeek);\n newFocused.setUTCDate(focusedWeek.getUTCDate() - 7);\n setFocusedWeek(newFocused);\n onFocus?.(newFocused);\n break;\n case 'ArrowDown':\n newFocused = new Date(focusedWeek);\n newFocused.setUTCDate(focusedWeek.getUTCDate() + 7);\n setFocusedWeek(newFocused);\n onFocus?.(newFocused);\n break;\n case 'Enter':\n onSelect?.(focusedWeek);\n break;\n default:\n }\n };\n\n const containerRef = useConsolidatedRef(ref);\n const hasFocus = useFocusWithin([containerRef]);\n\n const min = props.min ? parseToDate(props.min) : -Infinity;\n const max = props.max ? parseToDate(props.max) : Infinity;\n const isDisabled = (day: Date) => {\n return disabled || Number(min) > day.getTime() || day.getTime() > Number(max);\n };\n\n const isChecked = (day: Date) => {\n return (\n selected &&\n toUTCDateString(day) ===\n toUTCDateString(\n getDateOfISOWeek(getWeek(selected, calendarType, 'UTC'), selected.getFullYear())\n )\n );\n };\n\n const isFocused = (day: Date) => {\n return (\n toUTCDateString(day) ===\n toUTCDateString(\n getDateOfISOWeek(getWeek(focusedWeek, calendarType, 'UTC'), focusedWeek.getFullYear())\n )\n );\n };\n\n const displayNames = new Intl.DisplayNames(locale, {\n style: 'long',\n type: 'dateTimeField'\n }) as Intl.DateTimeDisplayNames;\n const displayNamesShort = new Intl.DisplayNames(locale, {\n style: 'short',\n type: 'dateTimeField'\n }) as Intl.DateTimeDisplayNames;\n\n const weeks = getWeeksOfMonth(current, calendarType).map(({ weekNo, weekYear }) => {\n const dateOfISOWeek = getDateOfISOWeek(weekNo, weekYear);\n return (\n <StyledWeekNumber\n key={weekNo}\n variant='simple'\n icon={false}\n type='button'\n loading={false}\n ref={\n isFocused(dateOfISOWeek)\n ? (focusedRef: HTMLButtonElement) => {\n if (hasFocus) focusedRef?.focus();\n }\n : undefined\n }\n tabIndex={isFocused(dateOfISOWeek) ? 0 : -1}\n disabled={isDisabled(dateOfISOWeek)}\n aria-selected={isChecked(dateOfISOWeek) || undefined}\n aria-label={`${displayNames.of('weekOfYear')} ${weekNo.toString()} ${weekYear.toString()}`}\n onClick={() => {\n onSelect?.(dateOfISOWeek);\n }}\n >\n {size === 'long' && `${cap(displayNames.of('weekOfYear'))} `}\n {weekNo.toString()}\n </StyledWeekNumber>\n );\n });\n\n const label =\n size === 'short' ? (\n <Text as={StyledColumnLabel} forwardedAs='abbr' title={cap(displayNames.of('weekOfYear'))}>\n {cap(displayNamesShort.of('weekOfYear'))}\n </Text>\n ) : (\n <Text as={StyledColumnLabel}>{cap(displayNames.of('weekOfYear'))}</Text>\n );\n\n return (\n <Flex\n as={StyledWeekNumbers}\n container={{ direction: 'column' }}\n ref={containerRef}\n onKeyDown={onKeyDown}\n >\n {label}\n {weeks}\n </Flex>\n );\n});\n\nexport default Weeks;\n"]}
1
+ {"version":3,"file":"Weeks.js","sourceRoot":"","sources":["../../../../src/components/DateTime/Picker/Weeks.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,eAAe,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAE9D,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,IAAI,MAAM,YAAY,CAAC;AAC9B,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,IAAI,MAAM,YAAY,CAAC;AAC9B,OAAO,EAAE,GAAG,EAAE,MAAM,gBAAgB,CAAC;AACrC,OAAO,EAAE,aAAa,EAAE,OAAO,EAAE,WAAW,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AACtF,OAAO,EAAE,gBAAgB,EAAE,kBAAkB,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AACtF,OAAO,EAAE,cAAc,EAAqB,MAAM,gBAAgB,CAAC;AAInE,OAAO,EAAE,iBAAiB,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAClE,OAAO,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AA+B1C,MAAM,CAAC,MAAM,iBAAiB,GAAG,MAAM,CAAC,GAAG,CAAA;uBACpB,KAAK,CAAC,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,OAAO;;CAEvD,CAAC;AAEF,iBAAiB,CAAC,YAAY,GAAG,gBA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AEnB,KAAK,EACL,KAAK,IACD,CACR,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,eAAe,KAAK,CAAC","sourcesContent":["import { useLayoutEffect, useState, forwardRef } from 'react';\nimport type { FC, KeyboardEvent, PropsWithoutRef, Ref } from 'react';\nimport styled, { css } from 'styled-components';\n\nimport Flex from '../../Flex';\nimport { defaultThemeProp } from '../../../theme';\nimport Text from '../../Text';\nimport { cap } from '../../../utils';\nimport { getDateOfWeek, getWeek, parseToDate, toUTCDateString } from '../Input/utils';\nimport { useConfiguration, useConsolidatedRef, useFocusWithin } from '../../../hooks';\nimport { CALENDAR_TYPES, type CalendarType } from '../Input/local';\nimport type { ForwardProps } from '../../../types';\nimport type { FormControlProps } from '../../FormControl';\n\nimport { StyledColumnLabel, StyledPick } from './Calendar.styles';\nimport { getWeeksOfMonth } from './utils';\n\nexport interface WeeksProps {\n /**\n * Sets DOM id for the control and associates label element via 'for' attribute.\n * If an id is not pass, a random id will be generated for any render.\n */\n id?: FormControlProps['id'];\n /** Defines default week that will be selected when the Date Picker is opened. */\n selected?: Date;\n /**\n * Defines default week that will be focused initially when the Date Picker is opened.\n * @default new Date()\n */\n current?: Date;\n /** Callback fired when user focuses new week. */\n onFocus?: (date: Date) => void;\n /** Callback fired when new week is selected. */\n onSelect?: (date: Date) => void;\n /** Sets the type of calendar to be used. This will be determined by locale if no value is provided. */\n calendarType?: CalendarType;\n /** Defines minimum available value that can be selected by the user. */\n min?: string | number | Date;\n /** Defines maximum available value that can be selected by the user. */\n max?: string | number | Date;\n /** Set the calendar to disabled state, ie. non-interactive. */\n disabled?: boolean;\n /** Should text be in long or short format (ie. only number). */\n size?: 'short' | 'long';\n}\n\nexport const StyledWeekNumbers = styled.div`\n margin-inline-end: ${props => props.theme.base.spacing};\n color: rgba(0, 0, 0, 0.75);\n`;\n\nStyledWeekNumbers.defaultProps = defaultThemeProp;\n\nconst StyledWeekNumber = styled(StyledPick)(props => {\n const {\n theme: {\n base: { 'border-radius': borderRadius }\n }\n } = props;\n\n return css`\n &:disabled {\n &:nth-child(2) {\n border-radius: calc(0.5 * ${borderRadius}) calc(0.5 * ${borderRadius}) 0 0;\n }\n\n &:last-child {\n border-radius: 0 0 calc(0.5 * ${borderRadius}) calc(0.5 * ${borderRadius});\n }\n }\n `;\n});\n\nStyledWeekNumber.defaultProps = defaultThemeProp;\n\nconst Weeks: FC<WeeksProps & ForwardProps> = forwardRef(function Weeks(\n props: PropsWithoutRef<WeeksProps>,\n ref: Ref<HTMLButtonElement>\n) {\n const {\n selected,\n current = selected ? new Date(selected.getTime()) : new Date(),\n calendarType = CALENDAR_TYPES.ISO_8601,\n onSelect,\n onFocus,\n disabled = false,\n size = 'short'\n } = props;\n\n const { locale } = useConfiguration();\n\n const [focusedWeek, setFocusedWeek] = useState(current);\n useLayoutEffect(() => {\n setFocusedWeek(current);\n }, [current.getUTCFullYear(), current.getUTCMonth()]);\n\n let newFocused: Date;\n const onKeyDown = (ev: KeyboardEvent<HTMLElement>) => {\n if (['ArrowUp', 'ArrowDown', 'Enter'].includes(ev.key)) ev.preventDefault();\n switch (ev.key) {\n case 'ArrowUp':\n newFocused = new Date(focusedWeek);\n newFocused.setUTCDate(focusedWeek.getUTCDate() - 7);\n setFocusedWeek(newFocused);\n onFocus?.(newFocused);\n break;\n case 'ArrowDown':\n newFocused = new Date(focusedWeek);\n newFocused.setUTCDate(focusedWeek.getUTCDate() + 7);\n setFocusedWeek(newFocused);\n onFocus?.(newFocused);\n break;\n case 'Enter':\n onSelect?.(focusedWeek);\n break;\n default:\n }\n };\n\n const containerRef = useConsolidatedRef(ref);\n const hasFocus = useFocusWithin([containerRef]);\n\n const min = props.min ? parseToDate(props.min) : -Infinity;\n const max = props.max ? parseToDate(props.max) : Infinity;\n const isDisabled = (day: Date) => {\n return disabled || Number(min) > day.getTime() || day.getTime() > Number(max);\n };\n\n const isChecked = (day: Date) => {\n return (\n selected &&\n toUTCDateString(day) ===\n toUTCDateString(\n getDateOfWeek(\n getWeek(selected, calendarType, 'UTC'),\n selected.getFullYear(),\n calendarType\n )\n )\n );\n };\n\n const isFocused = (day: Date) => {\n return (\n toUTCDateString(day) ===\n toUTCDateString(\n getDateOfWeek(\n getWeek(focusedWeek, calendarType, 'UTC'),\n focusedWeek.getFullYear(),\n calendarType\n )\n )\n );\n };\n\n const displayNames = new Intl.DisplayNames(locale, {\n style: 'long',\n type: 'dateTimeField'\n }) as Intl.DateTimeDisplayNames;\n const displayNamesShort = new Intl.DisplayNames(locale, {\n style: 'short',\n type: 'dateTimeField'\n }) as Intl.DateTimeDisplayNames;\n\n const weeks = getWeeksOfMonth(current, calendarType).map(({ weekNo, weekYear }) => {\n const dateOfWeek = getDateOfWeek(weekNo, weekYear, calendarType);\n return (\n <StyledWeekNumber\n key={weekNo}\n variant='simple'\n icon={false}\n type='button'\n loading={false}\n ref={\n isFocused(dateOfWeek)\n ? (focusedRef: HTMLButtonElement) => {\n if (hasFocus) focusedRef?.focus();\n }\n : undefined\n }\n tabIndex={isFocused(dateOfWeek) ? 0 : -1}\n disabled={isDisabled(dateOfWeek)}\n aria-selected={isChecked(dateOfWeek) || undefined}\n aria-label={`${displayNames.of('weekOfYear')} ${weekNo.toString()} ${weekYear.toString()}`}\n onClick={() => {\n onSelect?.(dateOfWeek);\n }}\n >\n {size === 'long' && `${cap(displayNames.of('weekOfYear'))} `}\n {weekNo.toString()}\n </StyledWeekNumber>\n );\n });\n\n const label =\n size === 'short' ? (\n <Text as={StyledColumnLabel} forwardedAs='abbr' title={cap(displayNames.of('weekOfYear'))}>\n {cap(displayNamesShort.of('weekOfYear'))}\n </Text>\n ) : (\n <Text as={StyledColumnLabel}>{cap(displayNames.of('weekOfYear'))}</Text>\n );\n\n return (\n <Flex\n as={StyledWeekNumbers}\n container={{ direction: 'column' }}\n ref={containerRef}\n onKeyDown={onKeyDown}\n >\n {label}\n {weeks}\n </Flex>\n );\n});\n\nexport default Weeks;\n"]}
@@ -1,8 +1,9 @@
1
+ import type { CalendarType } from '../Input/local';
1
2
  import type DatePickerProps from './DatePicker.types';
2
- export declare const getLocalizedDays: (calendarType: string, localeTag?: string) => string[][];
3
+ export declare const getLocalizedDays: (calendarType: CalendarType, localeTag?: string) => string[][];
3
4
  export declare const isValidDate: (date: Date) => boolean;
4
- export declare const getDaysOfMonth: (date: Date, calendarType: string) => Date[];
5
- export declare const getWeeksOfMonth: (date: Date, calendarType: string) => {
5
+ export declare const getDaysOfMonth: (date: Date, calendarType: CalendarType) => Date[];
6
+ export declare const getWeeksOfMonth: (date: Date, calendarType: CalendarType) => {
6
7
  weekNo: number;
7
8
  weekYear: number;
8
9
  }[];
@@ -1 +1 @@
1
- {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../src/components/DateTime/Picker/utils.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,eAAe,MAAM,oBAAoB,CAAC;AAEtD,eAAO,MAAM,gBAAgB,GAAI,cAAc,MAAM,EAAE,YAAY,MAAM,eAOxE,CAAC;AAEF,eAAO,MAAM,WAAW,GAAI,MAAM,IAAI,YAErC,CAAC;AAEF,eAAO,MAAM,cAAc,GAAI,MAAM,IAAI,EAAE,cAAc,MAAM,KAAG,IAAI,EAQrE,CAAC;AAEF,eAAO,MAAM,eAAe,GAC1B,MAAM,IAAI,EACV,cAAc,MAAM,KACnB;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,EAsBtC,CAAC;AAEF,eAAO,MAAM,YAAY,GAAI,MAAM,IAAI,WAGtC,CAAC;AAEF,eAAO,MAAM,gBAAgB,GAAI,MAAM,IAAI,WAG1C,CAAC;AAIF,wBAAiB,oBAAoB,CAAC,QAAQ,EAAE,MAAM,kCAMrD;AAED,eAAO,MAAM,gBAAgB,GAC3B,MAAM,IAAI,GAAG,SAAS,EACtB,OAAM,eAAe,CAAC,MAAM,CAAU,uBAUvC,CAAC;AAEF;;;;;;;GAOG;AAEH,eAAO,MAAM,gBAAgB,GAAI,aAAa,IAAI,EAAE,OAAO,CAAC,GAAG,CAAC,CAAC,KAAG,IAEnE,CAAC;AAEF,eAAO,MAAM,wBAAwB,GAAI,OAAO,IAAI,EAAE,QAAQ,MAAM,WAMnE,CAAC"}
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../../src/components/DateTime/Picker/utils.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAEnD,OAAO,KAAK,eAAe,MAAM,oBAAoB,CAAC;AAEtD,eAAO,MAAM,gBAAgB,GAAI,cAAc,YAAY,EAAE,YAAY,MAAM,eAO9E,CAAC;AAEF,eAAO,MAAM,WAAW,GAAI,MAAM,IAAI,YAErC,CAAC;AAEF,eAAO,MAAM,cAAc,GAAI,MAAM,IAAI,EAAE,cAAc,YAAY,KAAG,IAAI,EAQ3E,CAAC;AAEF,eAAO,MAAM,eAAe,GAC1B,MAAM,IAAI,EACV,cAAc,YAAY,KACzB;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,EAsBtC,CAAC;AAEF,eAAO,MAAM,YAAY,GAAI,MAAM,IAAI,WAGtC,CAAC;AAEF,eAAO,MAAM,gBAAgB,GAAI,MAAM,IAAI,WAG1C,CAAC;AAIF,wBAAiB,oBAAoB,CAAC,QAAQ,EAAE,MAAM,kCAMrD;AAED,eAAO,MAAM,gBAAgB,GAC3B,MAAM,IAAI,GAAG,SAAS,EACtB,OAAM,eAAe,CAAC,MAAM,CAAU,uBAUvC,CAAC;AAEF;;;;;;;GAOG;AAEH,eAAO,MAAM,gBAAgB,GAAI,aAAa,IAAI,EAAE,OAAO,CAAC,GAAG,CAAC,CAAC,KAAG,IAEnE,CAAC;AAEF,eAAO,MAAM,wBAAwB,GAAI,OAAO,IAAI,EAAE,QAAQ,MAAM,WAMnE,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"utils.js","sourceRoot":"","sources":["../../../../src/components/D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;;;;GAOG;AAEH,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,WAAiB,EAAE,KAAa,EAAQ,EAAE;IACzE,OAAO,KAAK,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC,GAAG,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC,MAAM,EAAE,CAAC;AAC7D,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,KAAW,EAAE,MAAc,EAAE,EAAE;IACtE,OAAO,KAAK,CAAC,cAAc,CAAC,MAAM,EAAE;QAClC,KAAK,EAAE,MAAM;QACb,IAAI,EAAE,SAAS;QACf,QAAQ,EAAE,KAAK;KAChB,CAAC,CAAC;AACL,CAAC,CAAC","sourcesContent":["import dayjs from 'dayjs';\n\nimport { cap, range } from '../../../utils';\nimport { getDayOfWeek, getWeek, getWeekdays, getWeekYear } from '../Input/utils';\n\nimport type DatePickerProps from './DatePicker.types';\n\nexport const getLocalizedDays = (calendarType: string, localeTag?: string) => {\n return getWeekdays(calendarType).map(weekdayDate => {\n return [\n cap(weekdayDate.toLocaleString(localeTag, { weekday: 'long' })),\n cap(weekdayDate.toLocaleString(localeTag, { weekday: 'short' }))\n ];\n });\n};\n\nexport const isValidDate = (date: Date) => {\n return date.toString() !== 'Invalid Date';\n};\n\nexport const getDaysOfMonth = (date: Date, calendarType: string): Date[] => {\n const firstDayInMonth = new Date(Date.UTC(date.getUTCFullYear(), date.getUTCMonth(), 1));\n const startingWeekDay = getDayOfWeek(firstDayInMonth, calendarType, 'UTC');\n\n // 6 rows * 7 days = 42\n return range(1 - startingWeekDay, 42 - startingWeekDay).map((day: number) => {\n return new Date(Date.UTC(date.getUTCFullYear(), date.getUTCMonth(), day));\n });\n};\n\nexport const getWeeksOfMonth = (\n date: Date,\n calendarType: string\n): { weekNo: number; weekYear: number }[] => {\n const weekdays = [];\n const year = date.getUTCFullYear();\n const month = date.getUTCMonth();\n const dayInLastWeek = new Date(Date.UTC(year, month, 36));\n const lastWeek = getWeek(dayInLastWeek, calendarType, 'UTC');\n\n let day;\n let currentWeek;\n let iterator = 1;\n\n do {\n day = new Date(Date.UTC(year, month, iterator));\n currentWeek = {\n weekNo: getWeek(day, calendarType, 'UTC'),\n weekYear: getWeekYear(day, calendarType, 'UTC')\n };\n weekdays.push(currentWeek);\n iterator += 7;\n } while (currentWeek.weekNo !== lastWeek);\n\n return weekdays;\n};\n\nexport const getNextMonth = (date: Date) => {\n const next = new Date(Date.UTC(date.getUTCFullYear(), date.getUTCMonth() + 1, 1));\n return next.getUTCMonth();\n};\n\nexport const getPreviousMonth = (date: Date) => {\n const prev = new Date(Date.UTC(date.getUTCFullYear(), date.getUTCMonth() - 1, 1));\n return prev.getUTCMonth();\n};\n\nconst DAY_IN_MILLISECONDS = 86400000;\n\nexport function* getIntervalGenerator(interval: number) {\n const current = new Date(0);\n while (current.getTime() < DAY_IN_MILLISECONDS) {\n yield new Date(current);\n current.setTime(current.getTime() + interval);\n }\n}\n\nexport const toDateTimeString = (\n date: Date | undefined,\n mode: DatePickerProps['mode'] = 'date'\n) => {\n return date\n ? date.toLocaleString(\n undefined,\n mode === 'datetime'\n ? { dateStyle: 'medium', timeStyle: 'medium', timeZone: 'UTC' }\n : { dateStyle: 'medium', timeZone: 'UTC' }\n )\n : undefined;\n};\n\n/**\n * Shifts date forward or backward. It sets the day of month\n * to the last day of the resulted month if it does not contain the calculated day,\n * ie. 2022-01-31 -> 2022-02-28.\n * @param currentDate a date to advance by month\n * @param shift determines whether it is the next month or the previous month\n * @returns new Date object with advanced month\n */\n\nexport const shiftDateByMonth = (currentDate: Date, shift: 1 | -1): Date => {\n return dayjs.utc(currentDate).add(shift, 'month').toDate();\n};\n\nexport const getCurrentMonthYearLabel = (value: Date, locale: string) => {\n return value.toLocaleString(locale, {\n month: 'long',\n year: 'numeric',\n timeZone: 'UTC'\n });\n};\n"]}
1
+ {"version":3,"file":"utils.js","sourceRoot":"","sources":["../../../../src/components/DateTime/Picker/utils.ts"],"names":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CAAC,MAAM,gBAAgB,GAAG,CAAC,WAAiB,EAAE,KAAa,EAAQ,EAAE;IACzE,OAAO,KAAK,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC,GAAG,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC,MAAM,EAAE,CAAC;AAC7D,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,KAAW,EAAE,MAAc,EAAE,EAAE;IACtE,OAAO,KAAK,CAAC,cAAc,CAAC,MAAM,EAAE;QAClC,KAAK,EAAE,MAAM;QACb,IAAI,EAAE,SAAS;QACf,QAAQ,EAAE,KAAK;KAChB,CAAC,CAAC;AACL,CAAC,CAAC","sourcesContent":["import dayjs from 'dayjs';\n\nimport { cap, range } from '../../../utils';\nimport { getDayOfWeek, getWeek, getWeekdays, getWeekYear } from '../Input/utils';\nimport type { CalendarType } from '../Input/local';\n\nimport type DatePickerProps from './DatePicker.types';\n\nexport const getLocalizedDays = (calendarType: CalendarType, localeTag?: string) => {\n return getWeekdays(calendarType).map(weekdayDate => {\n return [\n cap(weekdayDate.toLocaleString(localeTag, { weekday: 'long' })),\n cap(weekdayDate.toLocaleString(localeTag, { weekday: 'short' }))\n ];\n });\n};\n\nexport const isValidDate = (date: Date) => {\n return date.toString() !== 'Invalid Date';\n};\n\nexport const getDaysOfMonth = (date: Date, calendarType: CalendarType): Date[] => {\n const firstDayInMonth = new Date(Date.UTC(date.getUTCFullYear(), date.getUTCMonth(), 1));\n const startingWeekDay = getDayOfWeek(firstDayInMonth, calendarType, 'UTC');\n\n // 6 rows * 7 days = 42\n return range(1 - startingWeekDay, 42 - startingWeekDay).map((day: number) => {\n return new Date(Date.UTC(date.getUTCFullYear(), date.getUTCMonth(), day));\n });\n};\n\nexport const getWeeksOfMonth = (\n date: Date,\n calendarType: CalendarType\n): { weekNo: number; weekYear: number }[] => {\n const weekdays = [];\n const year = date.getUTCFullYear();\n const month = date.getUTCMonth();\n const dayInLastWeek = new Date(Date.UTC(year, month, 36));\n const lastWeek = getWeek(dayInLastWeek, calendarType, 'UTC');\n\n let day;\n let currentWeek;\n let iterator = 1;\n\n do {\n day = new Date(Date.UTC(year, month, iterator));\n currentWeek = {\n weekNo: getWeek(day, calendarType, 'UTC'),\n weekYear: getWeekYear(day, calendarType, 'UTC')\n };\n weekdays.push(currentWeek);\n iterator += 7;\n } while (currentWeek.weekNo !== lastWeek);\n\n return weekdays;\n};\n\nexport const getNextMonth = (date: Date) => {\n const next = new Date(Date.UTC(date.getUTCFullYear(), date.getUTCMonth() + 1, 1));\n return next.getUTCMonth();\n};\n\nexport const getPreviousMonth = (date: Date) => {\n const prev = new Date(Date.UTC(date.getUTCFullYear(), date.getUTCMonth() - 1, 1));\n return prev.getUTCMonth();\n};\n\nconst DAY_IN_MILLISECONDS = 86400000;\n\nexport function* getIntervalGenerator(interval: number) {\n const current = new Date(0);\n while (current.getTime() < DAY_IN_MILLISECONDS) {\n yield new Date(current);\n current.setTime(current.getTime() + interval);\n }\n}\n\nexport const toDateTimeString = (\n date: Date | undefined,\n mode: DatePickerProps['mode'] = 'date'\n) => {\n return date\n ? date.toLocaleString(\n undefined,\n mode === 'datetime'\n ? { dateStyle: 'medium', timeStyle: 'medium', timeZone: 'UTC' }\n : { dateStyle: 'medium', timeZone: 'UTC' }\n )\n : undefined;\n};\n\n/**\n * Shifts date forward or backward. It sets the day of month\n * to the last day of the resulted month if it does not contain the calculated day,\n * ie. 2022-01-31 -> 2022-02-28.\n * @param currentDate a date to advance by month\n * @param shift determines whether it is the next month or the previous month\n * @returns new Date object with advanced month\n */\n\nexport const shiftDateByMonth = (currentDate: Date, shift: 1 | -1): Date => {\n return dayjs.utc(currentDate).add(shift, 'month').toDate();\n};\n\nexport const getCurrentMonthYearLabel = (value: Date, locale: string) => {\n return value.toLocaleString(locale, {\n month: 'long',\n year: 'numeric',\n timeZone: 'UTC'\n });\n};\n"]}
@@ -1,13 +1,14 @@
1
1
  import type { TranslationFunction, TranslationPack } from '../../i18n';
2
2
  import type { ExcludeStrict } from '../../types';
3
3
  import type { DateTimeFormat, DateTimeVariant } from './DateTime.types';
4
+ import { type CalendarType } from './Input/local';
4
5
  import type { ClockFormat } from './Input/utils';
5
6
  type DateTimeFormatOptions = {
6
7
  locale: string;
7
8
  format: DateTimeFormat;
8
9
  timeZone?: string;
9
10
  clockFormat?: ClockFormat;
10
- calendarType?: string;
11
+ calendarType?: CalendarType;
11
12
  } & ({
12
13
  variant: ExcludeStrict<DateTimeVariant, 'quarteryear'>;
13
14
  t?: TranslationFunction<TranslationPack>;
@@ -38,5 +39,11 @@ export declare function formatDuration(valueInMs: number, { locale, significantU
38
39
  * @returns Current date and time value adjusted for local time zone.
39
40
  */
40
41
  export declare const getAdjustedUTCDateTime: () => Date;
42
+ /**
43
+ * @param timeZone - IANA timezone string (e.g. "America/New_York")
44
+ * @returns Current date and time for the given timezone, with wall-clock time
45
+ * encoded in UTC fields — matching the convention used by DateTime inputs.
46
+ */
47
+ export declare const getAdjustedUTCDateTimeForTimezone: (timeZone: string) => Date;
41
48
  export {};
42
49
  //# sourceMappingURL=utils.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../src/components/DateTime/utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AACvE,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAGjD,OAAO,KAAK,EAAmB,cAAc,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AASzF,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAajD,KAAK,qBAAqB,GAAG;IAC3B,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,cAAc,CAAC;IACvB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB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