@pega/cosmos-react-core 4.0.0-dev.1.2 → 4.0.0-dev.10.1

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 (586) hide show
  1. package/lib/components/Actions/Actions.d.ts.map +1 -1
  2. package/lib/components/Actions/Actions.js +11 -5
  3. package/lib/components/Actions/Actions.js.map +1 -1
  4. package/lib/components/AdditionalInfo/AdditionalInfo.d.ts +2 -0
  5. package/lib/components/AdditionalInfo/AdditionalInfo.d.ts.map +1 -1
  6. package/lib/components/AdditionalInfo/AdditionalInfo.js +24 -15
  7. package/lib/components/AdditionalInfo/AdditionalInfo.js.map +1 -1
  8. package/lib/components/AppShell/AppHeader.d.ts.map +1 -1
  9. package/lib/components/AppShell/AppHeader.js +4 -3
  10. package/lib/components/AppShell/AppHeader.js.map +1 -1
  11. package/lib/components/AppShell/AppHeader.styles.d.ts +2 -0
  12. package/lib/components/AppShell/AppHeader.styles.d.ts.map +1 -1
  13. package/lib/components/AppShell/AppHeader.styles.js +43 -33
  14. package/lib/components/AppShell/AppHeader.styles.js.map +1 -1
  15. package/lib/components/AppShell/AppShell.d.ts.map +1 -1
  16. package/lib/components/AppShell/AppShell.js +37 -13
  17. package/lib/components/AppShell/AppShell.js.map +1 -1
  18. package/lib/components/AppShell/AppShell.styles.d.ts +4 -1
  19. package/lib/components/AppShell/AppShell.styles.d.ts.map +1 -1
  20. package/lib/components/AppShell/AppShell.styles.js +57 -20
  21. package/lib/components/AppShell/AppShell.styles.js.map +1 -1
  22. package/lib/components/AppShell/AppShell.types.d.ts +30 -0
  23. package/lib/components/AppShell/AppShell.types.d.ts.map +1 -1
  24. package/lib/components/AppShell/AppShell.types.js.map +1 -1
  25. package/lib/components/AppShell/AppShellContext.d.ts +2 -0
  26. package/lib/components/AppShell/AppShellContext.d.ts.map +1 -1
  27. package/lib/components/AppShell/AppShellContext.js +2 -0
  28. package/lib/components/AppShell/AppShellContext.js.map +1 -1
  29. package/lib/components/AppShell/AppShellList.d.ts +1 -1
  30. package/lib/components/AppShell/AppShellList.d.ts.map +1 -1
  31. package/lib/components/AppShell/AppShellList.js +6 -2
  32. package/lib/components/AppShell/AppShellList.js.map +1 -1
  33. package/lib/components/AppShell/AppShellList.styles.d.ts +1 -1
  34. package/lib/components/AppShell/AppShellList.styles.d.ts.map +1 -1
  35. package/lib/components/AppShell/AppShellList.styles.js +21 -19
  36. package/lib/components/AppShell/AppShellList.styles.js.map +1 -1
  37. package/lib/components/AppShell/AppShellSearch.styles.js +1 -1
  38. package/lib/components/AppShell/AppShellSearch.styles.js.map +1 -1
  39. package/lib/components/AppShell/ContextSwitcher.d.ts +6 -0
  40. package/lib/components/AppShell/ContextSwitcher.d.ts.map +1 -0
  41. package/lib/components/AppShell/ContextSwitcher.js +18 -0
  42. package/lib/components/AppShell/ContextSwitcher.js.map +1 -0
  43. package/lib/components/AppShell/Drawer.d.ts.map +1 -1
  44. package/lib/components/AppShell/Drawer.js +8 -9
  45. package/lib/components/AppShell/Drawer.js.map +1 -1
  46. package/lib/components/AppShell/Drawer.styles.d.ts.map +1 -1
  47. package/lib/components/AppShell/Drawer.styles.js +7 -4
  48. package/lib/components/AppShell/Drawer.styles.js.map +1 -1
  49. package/lib/components/AppShell/NavigationList.d.ts.map +1 -1
  50. package/lib/components/AppShell/NavigationList.js +15 -12
  51. package/lib/components/AppShell/NavigationList.js.map +1 -1
  52. package/lib/components/AppShell/NavigationListItemWrapper.d.ts.map +1 -1
  53. package/lib/components/AppShell/NavigationListItemWrapper.js +4 -2
  54. package/lib/components/AppShell/NavigationListItemWrapper.js.map +1 -1
  55. package/lib/components/AppShell/index.d.ts +2 -1
  56. package/lib/components/AppShell/index.d.ts.map +1 -1
  57. package/lib/components/AppShell/index.js +1 -0
  58. package/lib/components/AppShell/index.js.map +1 -1
  59. package/lib/components/Avatar/Avatar.d.ts +1 -1
  60. package/lib/components/Avatar/Avatar.d.ts.map +1 -1
  61. package/lib/components/Backdrop/Backdrop.d.ts.map +1 -1
  62. package/lib/components/Backdrop/Backdrop.js +22 -2
  63. package/lib/components/Backdrop/Backdrop.js.map +1 -1
  64. package/lib/components/Badges/Count.d.ts +2 -2
  65. package/lib/components/Badges/Count.d.ts.map +1 -1
  66. package/lib/components/Badges/Count.js +22 -25
  67. package/lib/components/Badges/Count.js.map +1 -1
  68. package/lib/components/Badges/Selection.js +1 -1
  69. package/lib/components/Badges/Selection.js.map +1 -1
  70. package/lib/components/Badges/Tag.js +1 -1
  71. package/lib/components/Badges/Tag.js.map +1 -1
  72. package/lib/components/Banner/Banner.d.ts +28 -21
  73. package/lib/components/Banner/Banner.d.ts.map +1 -1
  74. package/lib/components/Banner/Banner.js +138 -96
  75. package/lib/components/Banner/Banner.js.map +1 -1
  76. package/lib/components/Banner/index.d.ts +1 -1
  77. package/lib/components/Banner/index.d.ts.map +1 -1
  78. package/lib/components/Banner/index.js.map +1 -1
  79. package/lib/components/Button/Button.d.ts +1 -1
  80. package/lib/components/Button/Button.d.ts.map +1 -1
  81. package/lib/components/Card/Card.d.ts +4 -7
  82. package/lib/components/Card/Card.d.ts.map +1 -1
  83. package/lib/components/Card/Card.js +2 -9
  84. package/lib/components/Card/Card.js.map +1 -1
  85. package/lib/components/ComboBox/ComboBox.styles.d.ts.map +1 -1
  86. package/lib/components/ComboBox/ComboBox.styles.js +0 -3
  87. package/lib/components/ComboBox/ComboBox.styles.js.map +1 -1
  88. package/lib/components/ComboBox/MultiSelectInput/MultiSelectInput.d.ts.map +1 -1
  89. package/lib/components/ComboBox/MultiSelectInput/MultiSelectInput.js +1 -3
  90. package/lib/components/ComboBox/MultiSelectInput/MultiSelectInput.js.map +1 -1
  91. package/lib/components/Configuration/Configuration.d.ts +4 -1
  92. package/lib/components/Configuration/Configuration.d.ts.map +1 -1
  93. package/lib/components/Configuration/Configuration.js +2 -0
  94. package/lib/components/Configuration/Configuration.js.map +1 -1
  95. package/lib/components/CreditCard/CreditCard.types.d.ts +1 -1
  96. package/lib/components/CreditCard/CreditCard.types.d.ts.map +1 -1
  97. package/lib/components/DateTime/DateTime.types.d.ts +10 -7
  98. package/lib/components/DateTime/DateTime.types.d.ts.map +1 -1
  99. package/lib/components/DateTime/DateTime.types.js.map +1 -1
  100. package/lib/components/DateTime/Input/DateInput.d.ts.map +1 -1
  101. package/lib/components/DateTime/Input/DateInput.js +19 -4
  102. package/lib/components/DateTime/Input/DateInput.js.map +1 -1
  103. package/lib/components/DateTime/Input/DateRangeInput.d.ts +4 -2
  104. package/lib/components/DateTime/Input/DateRangeInput.d.ts.map +1 -1
  105. package/lib/components/DateTime/Input/DateRangeInput.js +71 -34
  106. package/lib/components/DateTime/Input/DateRangeInput.js.map +1 -1
  107. package/lib/components/DateTime/Input/DateTimeInput.d.ts.map +1 -1
  108. package/lib/components/DateTime/Input/DateTimeInput.js +26 -5
  109. package/lib/components/DateTime/Input/DateTimeInput.js.map +1 -1
  110. package/lib/components/DateTime/Input/DayOfWeekInput.d.ts +1 -1
  111. package/lib/components/DateTime/Input/DayOfWeekInput.d.ts.map +1 -1
  112. package/lib/components/DateTime/Input/Duration/NumberUnit.d.ts +1 -1
  113. package/lib/components/DateTime/Input/Duration/NumberUnit.d.ts.map +1 -1
  114. package/lib/components/DateTime/Input/Duration/Time.d.ts +1 -1
  115. package/lib/components/DateTime/Input/Duration/Time.d.ts.map +1 -1
  116. package/lib/components/DateTime/Input/MonthInput.d.ts.map +1 -1
  117. package/lib/components/DateTime/Input/MonthInput.js +8 -3
  118. package/lib/components/DateTime/Input/MonthInput.js.map +1 -1
  119. package/lib/components/DateTime/Input/PartInput.d.ts.map +1 -1
  120. package/lib/components/DateTime/Input/PartInput.js +2 -2
  121. package/lib/components/DateTime/Input/PartInput.js.map +1 -1
  122. package/lib/components/DateTime/Input/TimeInput.d.ts.map +1 -1
  123. package/lib/components/DateTime/Input/TimeInput.js +13 -3
  124. package/lib/components/DateTime/Input/TimeInput.js.map +1 -1
  125. package/lib/components/DateTime/Input/TimeRangeInput.d.ts +4 -2
  126. package/lib/components/DateTime/Input/TimeRangeInput.d.ts.map +1 -1
  127. package/lib/components/DateTime/Input/TimeRangeInput.js +70 -27
  128. package/lib/components/DateTime/Input/TimeRangeInput.js.map +1 -1
  129. package/lib/components/DateTime/Input/WeekInput.d.ts.map +1 -1
  130. package/lib/components/DateTime/Input/WeekInput.js +7 -2
  131. package/lib/components/DateTime/Input/WeekInput.js.map +1 -1
  132. package/lib/components/DateTime/Input/usePickerButton.d.ts.map +1 -1
  133. package/lib/components/DateTime/Input/usePickerButton.js +19 -27
  134. package/lib/components/DateTime/Input/usePickerButton.js.map +1 -1
  135. package/lib/components/DateTime/Input/utils.d.ts +2 -2
  136. package/lib/components/DateTime/Input/utils.d.ts.map +1 -1
  137. package/lib/components/DateTime/Input/utils.js +6 -17
  138. package/lib/components/DateTime/Input/utils.js.map +1 -1
  139. package/lib/components/DateTime/Picker/Calendar.d.ts.map +1 -1
  140. package/lib/components/DateTime/Picker/Calendar.js +3 -1
  141. package/lib/components/DateTime/Picker/Calendar.js.map +1 -1
  142. package/lib/components/DateTime/Picker/DatePicker.d.ts.map +1 -1
  143. package/lib/components/DateTime/Picker/DatePicker.js +2 -8
  144. package/lib/components/DateTime/Picker/DatePicker.js.map +1 -1
  145. package/lib/components/DateTime/Picker/TimePicker.d.ts +1 -1
  146. package/lib/components/DateTime/Picker/TimePicker.d.ts.map +1 -1
  147. package/lib/components/DateTime/Picker/TimePicker.js +1 -1
  148. package/lib/components/DateTime/Picker/TimePicker.js.map +1 -1
  149. package/lib/components/Dialog/Dialog.d.ts +3 -30
  150. package/lib/components/Dialog/Dialog.d.ts.map +1 -1
  151. package/lib/components/Dialog/Dialog.js +7 -147
  152. package/lib/components/Dialog/Dialog.js.map +1 -1
  153. package/lib/components/Dialog/Dialog.styles.d.ts +3 -0
  154. package/lib/components/Dialog/Dialog.styles.d.ts.map +1 -0
  155. package/lib/components/Dialog/Dialog.styles.js +18 -0
  156. package/lib/components/Dialog/Dialog.styles.js.map +1 -0
  157. package/lib/components/Dialog/Dialog.types.d.ts +87 -0
  158. package/lib/components/Dialog/Dialog.types.d.ts.map +1 -0
  159. package/lib/components/Dialog/Dialog.types.js +3 -0
  160. package/lib/components/Dialog/Dialog.types.js.map +1 -0
  161. package/lib/components/Dialog/FormDialog.d.ts +7 -0
  162. package/lib/components/Dialog/FormDialog.d.ts.map +1 -0
  163. package/lib/components/Dialog/FormDialog.js +58 -0
  164. package/lib/components/Dialog/FormDialog.js.map +1 -0
  165. package/lib/components/Dialog/InfoDialog.d.ts +6 -0
  166. package/lib/components/Dialog/InfoDialog.d.ts.map +1 -0
  167. package/lib/components/Dialog/InfoDialog.js +43 -0
  168. package/lib/components/Dialog/InfoDialog.js.map +1 -0
  169. package/lib/components/Dialog/index.d.ts +3 -2
  170. package/lib/components/Dialog/index.d.ts.map +1 -1
  171. package/lib/components/Dialog/index.js +2 -2
  172. package/lib/components/Dialog/index.js.map +1 -1
  173. package/lib/components/Drawer/Drawer.d.ts +1 -1
  174. package/lib/components/Drawer/Drawer.d.ts.map +1 -1
  175. package/lib/components/EmojiPicker/EmojiPicker.d.ts +1 -1
  176. package/lib/components/EmojiPicker/EmojiPicker.d.ts.map +1 -1
  177. package/lib/components/FieldGroup/FieldGroup.d.ts.map +1 -1
  178. package/lib/components/FieldGroup/FieldGroup.js +2 -1
  179. package/lib/components/FieldGroup/FieldGroup.js.map +1 -1
  180. package/lib/components/FieldValueList/FieldValueList.d.ts +2 -2
  181. package/lib/components/FieldValueList/FieldValueList.d.ts.map +1 -1
  182. package/lib/components/FieldValueList/FieldValueList.js +5 -36
  183. package/lib/components/FieldValueList/FieldValueList.js.map +1 -1
  184. package/lib/components/FieldValueList/index.d.ts +1 -1
  185. package/lib/components/FieldValueList/index.d.ts.map +1 -1
  186. package/lib/components/FieldValueList/index.js.map +1 -1
  187. package/lib/components/File/utils.d.ts +1 -1
  188. package/lib/components/File/utils.d.ts.map +1 -1
  189. package/lib/components/Flex/Flex.d.ts +2 -2
  190. package/lib/components/Flex/Flex.d.ts.map +1 -1
  191. package/lib/components/FormControl/FormControl.d.ts +4 -0
  192. package/lib/components/FormControl/FormControl.d.ts.map +1 -1
  193. package/lib/components/FormControl/FormControl.js +3 -1
  194. package/lib/components/FormControl/FormControl.js.map +1 -1
  195. package/lib/components/FormControl/index.d.ts +1 -0
  196. package/lib/components/FormControl/index.d.ts.map +1 -1
  197. package/lib/components/FormControl/index.js.map +1 -1
  198. package/lib/components/Grid/Grid.types.d.ts +2 -2
  199. package/lib/components/Grid/Grid.types.d.ts.map +1 -1
  200. package/lib/components/HTML/HTML.d.ts.map +1 -1
  201. package/lib/components/HTML/HTML.js +1 -0
  202. package/lib/components/HTML/HTML.js.map +1 -1
  203. package/lib/components/Icon/iconNames.d.ts +2 -2
  204. package/lib/components/Icon/iconNames.d.ts.map +1 -1
  205. package/lib/components/Icon/iconNames.js +2 -0
  206. package/lib/components/Icon/iconNames.js.map +1 -1
  207. package/lib/components/Icon/icons/user-question-mark-solid.icon.d.ts +4 -0
  208. package/lib/components/Icon/icons/user-question-mark-solid.icon.d.ts.map +1 -0
  209. package/lib/components/Icon/icons/user-question-mark-solid.icon.js +6 -0
  210. package/lib/components/Icon/icons/user-question-mark-solid.icon.js.map +1 -0
  211. package/lib/components/Icon/icons/user-question-mark.icon.d.ts +4 -0
  212. package/lib/components/Icon/icons/user-question-mark.icon.d.ts.map +1 -0
  213. package/lib/components/Icon/icons/user-question-mark.icon.js +6 -0
  214. package/lib/components/Icon/icons/user-question-mark.icon.js.map +1 -0
  215. package/lib/components/Lightbox/Lightbox.styles.js +2 -2
  216. package/lib/components/Lightbox/Lightbox.styles.js.map +1 -1
  217. package/lib/components/Link/Link.d.ts.map +1 -1
  218. package/lib/components/Link/Link.js +13 -4
  219. package/lib/components/Link/Link.js.map +1 -1
  220. package/lib/components/List/CommaSeparatedList.d.ts.map +1 -1
  221. package/lib/components/List/CommaSeparatedList.js +5 -37
  222. package/lib/components/List/CommaSeparatedList.js.map +1 -1
  223. package/lib/components/List/List.d.ts.map +1 -1
  224. package/lib/components/List/List.js +11 -1
  225. package/lib/components/List/List.js.map +1 -1
  226. package/lib/components/ListToolbar/ListToolbar.d.ts.map +1 -1
  227. package/lib/components/ListToolbar/ListToolbar.js +106 -68
  228. package/lib/components/ListToolbar/ListToolbar.js.map +1 -1
  229. package/lib/components/ListToolbar/ListToolbar.styles.d.ts +5 -1
  230. package/lib/components/ListToolbar/ListToolbar.styles.d.ts.map +1 -1
  231. package/lib/components/ListToolbar/ListToolbar.styles.js +50 -5
  232. package/lib/components/ListToolbar/ListToolbar.styles.js.map +1 -1
  233. package/lib/components/ListToolbar/ListToolbar.types.d.ts +5 -5
  234. package/lib/components/ListToolbar/ListToolbar.types.d.ts.map +1 -1
  235. package/lib/components/ListToolbar/ListToolbar.types.js.map +1 -1
  236. package/lib/components/LiveLog/Context.d.ts +3 -0
  237. package/lib/components/LiveLog/Context.d.ts.map +1 -0
  238. package/lib/components/LiveLog/Context.js +9 -0
  239. package/lib/components/LiveLog/Context.js.map +1 -0
  240. package/lib/components/LiveLog/LiveLog.d.ts +10 -0
  241. package/lib/components/LiveLog/LiveLog.d.ts.map +1 -0
  242. package/lib/components/LiveLog/LiveLog.js +99 -0
  243. package/lib/components/LiveLog/LiveLog.js.map +1 -0
  244. package/lib/components/LiveLog/LiveLog.styles.d.ts +3 -0
  245. package/lib/components/LiveLog/LiveLog.styles.d.ts.map +1 -0
  246. package/lib/components/LiveLog/LiveLog.styles.js +9 -0
  247. package/lib/components/LiveLog/LiveLog.styles.js.map +1 -0
  248. package/lib/components/LiveLog/LiveLog.types.d.ts +93 -0
  249. package/lib/components/LiveLog/LiveLog.types.d.ts.map +1 -0
  250. package/lib/components/LiveLog/LiveLog.types.js +2 -0
  251. package/lib/components/LiveLog/LiveLog.types.js.map +1 -0
  252. package/lib/components/LiveLog/index.d.ts +4 -0
  253. package/lib/components/LiveLog/index.d.ts.map +1 -0
  254. package/lib/components/LiveLog/index.js +3 -0
  255. package/lib/components/LiveLog/index.js.map +1 -0
  256. package/lib/components/Location/CurrentLocationButton.d.ts +1 -1
  257. package/lib/components/Location/CurrentLocationButton.d.ts.map +1 -1
  258. package/lib/components/Location/LocationInput.d.ts.map +1 -1
  259. package/lib/components/Location/LocationInput.js +1 -2
  260. package/lib/components/Location/LocationInput.js.map +1 -1
  261. package/lib/components/Location/LocationView.d.ts.map +1 -1
  262. package/lib/components/Location/LocationView.js +4 -4
  263. package/lib/components/Location/LocationView.js.map +1 -1
  264. package/lib/components/Location/MapsContext.d.ts +1 -1
  265. package/lib/components/Location/MapsContext.d.ts.map +1 -1
  266. package/lib/components/Location/utils.d.ts +1 -1
  267. package/lib/components/Location/utils.d.ts.map +1 -1
  268. package/lib/components/Location/utils.js.map +1 -1
  269. package/lib/components/Menu/Menu.js +3 -3
  270. package/lib/components/Menu/Menu.js.map +1 -1
  271. package/lib/components/Menu/Menu.styles.js +1 -1
  272. package/lib/components/Menu/Menu.styles.js.map +1 -1
  273. package/lib/components/Menu/Menu.types.d.ts +3 -5
  274. package/lib/components/Menu/Menu.types.d.ts.map +1 -1
  275. package/lib/components/Menu/Menu.types.js.map +1 -1
  276. package/lib/components/Menu/MenuList.d.ts.map +1 -1
  277. package/lib/components/Menu/MenuList.js +4 -3
  278. package/lib/components/Menu/MenuList.js.map +1 -1
  279. package/lib/components/MenuButton/MenuButton.d.ts.map +1 -1
  280. package/lib/components/MenuButton/MenuButton.js +26 -5
  281. package/lib/components/MenuButton/MenuButton.js.map +1 -1
  282. package/lib/components/Modal/Modal.d.ts.map +1 -1
  283. package/lib/components/Modal/Modal.js +6 -8
  284. package/lib/components/Modal/Modal.js.map +1 -1
  285. package/lib/components/Modal/Modal.types.d.ts +2 -1
  286. package/lib/components/Modal/Modal.types.d.ts.map +1 -1
  287. package/lib/components/Modal/Modal.types.js.map +1 -1
  288. package/lib/components/Number/NumberInput.types.d.ts +3 -1
  289. package/lib/components/Number/NumberInput.types.d.ts.map +1 -1
  290. package/lib/components/Number/NumberInput.types.js.map +1 -1
  291. package/lib/components/Number/NumberRangeInput.d.ts.map +1 -1
  292. package/lib/components/Number/NumberRangeInput.js +71 -4
  293. package/lib/components/Number/NumberRangeInput.js.map +1 -1
  294. package/lib/components/PageTemplates/CategorySubPage.d.ts.map +1 -1
  295. package/lib/components/PageTemplates/CategorySubPage.js +15 -4
  296. package/lib/components/PageTemplates/CategorySubPage.js.map +1 -1
  297. package/lib/components/PageTemplates/CategorySubPage.styles.d.ts.map +1 -1
  298. package/lib/components/PageTemplates/CategorySubPage.styles.js +5 -0
  299. package/lib/components/PageTemplates/CategorySubPage.styles.js.map +1 -1
  300. package/lib/components/PageTemplates/DashboardPage.d.ts.map +1 -1
  301. package/lib/components/PageTemplates/DashboardPage.js +16 -2
  302. package/lib/components/PageTemplates/DashboardPage.js.map +1 -1
  303. package/lib/components/PageTemplates/PageTemplates.d.ts.map +1 -1
  304. package/lib/components/PageTemplates/PageTemplates.js +20 -3
  305. package/lib/components/PageTemplates/PageTemplates.js.map +1 -1
  306. package/lib/components/Popover/Popover.d.ts +1 -1
  307. package/lib/components/Popover/Popover.d.ts.map +1 -1
  308. package/lib/components/Popover/Popover.js +2 -5
  309. package/lib/components/Popover/Popover.js.map +1 -1
  310. package/lib/components/Popover/Popover.styles.d.ts +0 -1
  311. package/lib/components/Popover/Popover.styles.d.ts.map +1 -1
  312. package/lib/components/Popover/Popover.styles.js +0 -6
  313. package/lib/components/Popover/Popover.styles.js.map +1 -1
  314. package/lib/components/Popover/modifiers.d.ts +0 -2
  315. package/lib/components/Popover/modifiers.d.ts.map +1 -1
  316. package/lib/components/Popover/modifiers.js +1 -32
  317. package/lib/components/Popover/modifiers.js.map +1 -1
  318. package/lib/components/Progress/Bar.d.ts +0 -3
  319. package/lib/components/Progress/Bar.d.ts.map +1 -1
  320. package/lib/components/Progress/Bar.js +1 -54
  321. package/lib/components/Progress/Bar.js.map +1 -1
  322. package/lib/components/Progress/Ellipsis.d.ts +0 -1
  323. package/lib/components/Progress/Ellipsis.d.ts.map +1 -1
  324. package/lib/components/Progress/Ellipsis.js +1 -72
  325. package/lib/components/Progress/Ellipsis.js.map +1 -1
  326. package/lib/components/Progress/Progress.d.ts.map +1 -1
  327. package/lib/components/Progress/Progress.js +99 -60
  328. package/lib/components/Progress/Progress.js.map +1 -1
  329. package/lib/components/Progress/Progress.styles.d.ts +12 -0
  330. package/lib/components/Progress/Progress.styles.d.ts.map +1 -0
  331. package/lib/components/Progress/Progress.styles.js +217 -0
  332. package/lib/components/Progress/Progress.styles.js.map +1 -0
  333. package/lib/components/Progress/Progress.types.d.ts +19 -2
  334. package/lib/components/Progress/Progress.types.d.ts.map +1 -1
  335. package/lib/components/Progress/Progress.types.js.map +1 -1
  336. package/lib/components/Progress/Ring.d.ts +0 -3
  337. package/lib/components/Progress/Ring.d.ts.map +1 -1
  338. package/lib/components/Progress/Ring.js +1 -58
  339. package/lib/components/Progress/Ring.js.map +1 -1
  340. package/lib/components/Progress/index.d.ts +1 -3
  341. package/lib/components/Progress/index.d.ts.map +1 -1
  342. package/lib/components/Progress/index.js +1 -3
  343. package/lib/components/Progress/index.js.map +1 -1
  344. package/lib/components/QRCode/QRCode.d.ts +14 -0
  345. package/lib/components/QRCode/QRCode.d.ts.map +1 -0
  346. package/lib/components/QRCode/QRCode.js +39 -0
  347. package/lib/components/QRCode/QRCode.js.map +1 -0
  348. package/lib/components/QRCode/index.d.ts +3 -0
  349. package/lib/components/QRCode/index.d.ts.map +1 -0
  350. package/lib/components/QRCode/index.js +2 -0
  351. package/lib/components/QRCode/index.js.map +1 -0
  352. package/lib/components/RadioCheck/RadioCheck.js +1 -1
  353. package/lib/components/RadioCheck/RadioCheck.js.map +1 -1
  354. package/lib/components/SearchInput/SearchInput.d.ts +2 -2
  355. package/lib/components/SearchInput/SearchInput.d.ts.map +1 -1
  356. package/lib/components/SearchInput/SearchInput.js +28 -8
  357. package/lib/components/SearchInput/SearchInput.js.map +1 -1
  358. package/lib/components/SearchInput/SearchInput.styles.js +1 -1
  359. package/lib/components/SearchInput/SearchInput.styles.js.map +1 -1
  360. package/lib/components/ShowMoreLess/ShowMoreLess.d.ts +9 -0
  361. package/lib/components/ShowMoreLess/ShowMoreLess.d.ts.map +1 -0
  362. package/lib/components/ShowMoreLess/ShowMoreLess.js +41 -0
  363. package/lib/components/ShowMoreLess/ShowMoreLess.js.map +1 -0
  364. package/lib/components/ShowMoreLess/index.d.ts +3 -0
  365. package/lib/components/ShowMoreLess/index.d.ts.map +1 -0
  366. package/lib/components/ShowMoreLess/index.js +2 -0
  367. package/lib/components/ShowMoreLess/index.js.map +1 -0
  368. package/lib/components/SkipLinks/SkipLinks.d.ts.map +1 -1
  369. package/lib/components/SkipLinks/SkipLinks.js +3 -26
  370. package/lib/components/SkipLinks/SkipLinks.js.map +1 -1
  371. package/lib/components/Slider/Slider.styles.d.ts +1 -1
  372. package/lib/components/Slider/Slider.styles.d.ts.map +1 -1
  373. package/lib/components/Tabs/Tab.js +2 -2
  374. package/lib/components/Tabs/Tab.js.map +1 -1
  375. package/lib/components/Tabs/Tabs.d.ts.map +1 -1
  376. package/lib/components/Tabs/Tabs.js +8 -10
  377. package/lib/components/Tabs/Tabs.js.map +1 -1
  378. package/lib/components/TextArea/TextArea.js +2 -2
  379. package/lib/components/TextArea/TextArea.js.map +1 -1
  380. package/lib/components/Toaster/Context.d.ts +1 -0
  381. package/lib/components/Toaster/Context.d.ts.map +1 -1
  382. package/lib/components/Toaster/Context.js.map +1 -1
  383. package/lib/components/Toaster/Toaster.d.ts.map +1 -1
  384. package/lib/components/Toaster/Toaster.js +6 -2
  385. package/lib/components/Toaster/Toaster.js.map +1 -1
  386. package/lib/components/Tree/StandardTree.d.ts.map +1 -1
  387. package/lib/components/Tree/StandardTree.js +70 -27
  388. package/lib/components/Tree/StandardTree.js.map +1 -1
  389. package/lib/components/Tree/StandardTree.styles.d.ts +1 -0
  390. package/lib/components/Tree/StandardTree.styles.d.ts.map +1 -1
  391. package/lib/components/Tree/StandardTree.styles.js +32 -18
  392. package/lib/components/Tree/StandardTree.styles.js.map +1 -1
  393. package/lib/components/Tree/StandardTree.types.d.ts +28 -1
  394. package/lib/components/Tree/StandardTree.types.d.ts.map +1 -1
  395. package/lib/components/Tree/StandardTree.types.js.map +1 -1
  396. package/lib/components/Tree/Tree.d.ts +2 -2
  397. package/lib/components/Tree/Tree.d.ts.map +1 -1
  398. package/lib/components/Tree/helpers.d.ts +11 -9
  399. package/lib/components/Tree/helpers.d.ts.map +1 -1
  400. package/lib/components/Tree/helpers.js +25 -5
  401. package/lib/components/Tree/helpers.js.map +1 -1
  402. package/lib/components/Tree/index.d.ts +1 -1
  403. package/lib/components/Tree/index.d.ts.map +1 -1
  404. package/lib/components/Tree/index.js.map +1 -1
  405. package/lib/components/URL/URLDisplay.d.ts +2 -2
  406. package/lib/components/URL/URLDisplay.d.ts.map +1 -1
  407. package/lib/components/URL/URLDisplay.js +8 -1
  408. package/lib/components/URL/URLDisplay.js.map +1 -1
  409. package/lib/hooks/index.d.ts +1 -0
  410. package/lib/hooks/index.d.ts.map +1 -1
  411. package/lib/hooks/index.js +1 -0
  412. package/lib/hooks/index.js.map +1 -1
  413. package/lib/hooks/useActiveDescendant.d.ts +2 -2
  414. package/lib/hooks/useActiveDescendant.d.ts.map +1 -1
  415. package/lib/hooks/useArrows.d.ts.map +1 -1
  416. package/lib/hooks/useArrows.js +3 -3
  417. package/lib/hooks/useArrows.js.map +1 -1
  418. package/lib/hooks/useBreakpoint.d.ts.map +1 -1
  419. package/lib/hooks/useBreakpoint.js +3 -2
  420. package/lib/hooks/useBreakpoint.js.map +1 -1
  421. package/lib/hooks/useEvent.d.ts +2 -2
  422. package/lib/hooks/useEvent.d.ts.map +1 -1
  423. package/lib/hooks/useI18n.d.ts +88 -19
  424. package/lib/hooks/useI18n.d.ts.map +1 -1
  425. package/lib/hooks/useLiveLog.d.ts +8 -0
  426. package/lib/hooks/useLiveLog.d.ts.map +1 -0
  427. package/lib/hooks/useLiveLog.js +16 -0
  428. package/lib/hooks/useLiveLog.js.map +1 -0
  429. package/lib/hooks/useOverride.d.ts +1 -1
  430. package/lib/hooks/useOverride.d.ts.map +1 -1
  431. package/lib/hooks/useScrollStick.d.ts +1 -1
  432. package/lib/hooks/useScrollStick.d.ts.map +1 -1
  433. package/lib/i18n/default.d.ts +88 -19
  434. package/lib/i18n/default.d.ts.map +1 -1
  435. package/lib/i18n/default.js +98 -27
  436. package/lib/i18n/default.js.map +1 -1
  437. package/lib/i18n/i18n.d.ts +90 -21
  438. package/lib/i18n/i18n.d.ts.map +1 -1
  439. package/lib/i18n/translate.d.ts +1 -1
  440. package/lib/i18n/translate.d.ts.map +1 -1
  441. package/lib/index.d.ts +6 -1
  442. package/lib/index.d.ts.map +1 -1
  443. package/lib/index.js +6 -1
  444. package/lib/index.js.map +1 -1
  445. package/lib/register-contexts.js +2 -0
  446. package/lib/register-contexts.js.map +1 -1
  447. package/lib/styles/gradients.d.ts +1 -1
  448. package/lib/styles/gradients.d.ts.map +1 -1
  449. package/lib/styles/utils.d.ts +1 -1
  450. package/lib/styles/utils.d.ts.map +1 -1
  451. package/lib/styles/utils.js +10 -10
  452. package/lib/styles/utils.js.map +1 -1
  453. package/lib/theme/ThemeMachine.d.ts +3 -3
  454. package/lib/theme/ThemeMachine.d.ts.map +1 -1
  455. package/lib/theme/ThemeMachine.js +30 -30
  456. package/lib/theme/ThemeMachine.js.map +1 -1
  457. package/lib/theme/theme.d.ts +45 -75
  458. package/lib/theme/theme.d.ts.map +1 -1
  459. package/lib/theme/themeDefinition.json +14 -30
  460. package/lib/theme/themeOverrides.schema.json +1 -4
  461. package/lib/theme/themes/darkTheme.json +4 -1
  462. package/lib/theme/themes/legacyBuildTheme.json +2 -3
  463. package/lib/types/types.d.ts +19 -11
  464. package/lib/types/types.d.ts.map +1 -1
  465. package/lib/types/types.js.map +1 -1
  466. package/lib/utils/bindAll.d.ts +4 -0
  467. package/lib/utils/bindAll.d.ts.map +1 -0
  468. package/lib/utils/bindAll.js +9 -0
  469. package/lib/utils/bindAll.js.map +1 -0
  470. package/lib/utils/cap.d.ts +4 -0
  471. package/lib/utils/cap.d.ts.map +1 -0
  472. package/lib/utils/cap.js +6 -0
  473. package/lib/utils/cap.js.map +1 -0
  474. package/lib/utils/createStringMatcher.d.ts +10 -0
  475. package/lib/utils/createStringMatcher.d.ts.map +1 -0
  476. package/lib/utils/createStringMatcher.js +21 -0
  477. package/lib/utils/createStringMatcher.js.map +1 -0
  478. package/lib/utils/createUID.d.ts +4 -0
  479. package/lib/utils/createUID.d.ts.map +1 -0
  480. package/lib/utils/createUID.js +6 -0
  481. package/lib/utils/createUID.js.map +1 -0
  482. package/lib/utils/debounce.d.ts +4 -0
  483. package/lib/utils/debounce.d.ts.map +1 -0
  484. package/lib/utils/debounce.js +14 -0
  485. package/lib/utils/debounce.js.map +1 -0
  486. package/lib/utils/deepGet.d.ts +3 -0
  487. package/lib/utils/deepGet.d.ts.map +1 -0
  488. package/lib/utils/deepGet.js +15 -0
  489. package/lib/utils/deepGet.js.map +1 -0
  490. package/lib/utils/deepObjectComparison.d.ts +4 -0
  491. package/lib/utils/deepObjectComparison.d.ts.map +1 -0
  492. package/lib/utils/deepObjectComparison.js +35 -0
  493. package/lib/utils/deepObjectComparison.js.map +1 -0
  494. package/lib/utils/defineSmartGetter.d.ts +3 -0
  495. package/lib/utils/defineSmartGetter.d.ts.map +1 -0
  496. package/lib/utils/defineSmartGetter.js +14 -0
  497. package/lib/utils/defineSmartGetter.js.map +1 -0
  498. package/lib/utils/documentIsAvailable.d.ts +3 -0
  499. package/lib/utils/documentIsAvailable.d.ts.map +1 -0
  500. package/lib/utils/documentIsAvailable.js +3 -0
  501. package/lib/utils/documentIsAvailable.js.map +1 -0
  502. package/lib/utils/escapeRegExp.d.ts +8 -0
  503. package/lib/utils/escapeRegExp.d.ts.map +1 -0
  504. package/lib/utils/escapeRegExp.js +8 -0
  505. package/lib/utils/escapeRegExp.js.map +1 -0
  506. package/lib/utils/focusHeadingOrContainer.d.ts +8 -0
  507. package/lib/utils/focusHeadingOrContainer.d.ts.map +1 -0
  508. package/lib/utils/focusHeadingOrContainer.js +29 -0
  509. package/lib/utils/focusHeadingOrContainer.js.map +1 -0
  510. package/lib/utils/formatListToLocaleString.d.ts +15 -0
  511. package/lib/utils/formatListToLocaleString.d.ts.map +1 -0
  512. package/lib/utils/formatListToLocaleString.js +17 -0
  513. package/lib/utils/formatListToLocaleString.js.map +1 -0
  514. package/lib/utils/getActiveElement.d.ts +8 -0
  515. package/lib/utils/getActiveElement.d.ts.map +1 -0
  516. package/lib/utils/getActiveElement.js +18 -0
  517. package/lib/utils/getActiveElement.js.map +1 -0
  518. package/lib/utils/getFocusables.d.ts +9 -0
  519. package/lib/utils/getFocusables.d.ts.map +1 -0
  520. package/lib/utils/getFocusables.js +15 -0
  521. package/lib/utils/getFocusables.js.map +1 -0
  522. package/lib/utils/getScrollbarWidth.d.ts +4 -0
  523. package/lib/utils/getScrollbarWidth.d.ts.map +1 -0
  524. package/lib/utils/getScrollbarWidth.js +17 -0
  525. package/lib/utils/getScrollbarWidth.js.map +1 -0
  526. package/lib/utils/hasProp.d.ts +4 -0
  527. package/lib/utils/hasProp.d.ts.map +1 -0
  528. package/lib/utils/hasProp.js +6 -0
  529. package/lib/utils/hasProp.js.map +1 -0
  530. package/lib/utils/index.d.ts +27 -1
  531. package/lib/utils/index.d.ts.map +1 -1
  532. package/lib/utils/index.js +27 -1
  533. package/lib/utils/index.js.map +1 -1
  534. package/lib/utils/loadScript.d.ts +3 -0
  535. package/lib/utils/loadScript.d.ts.map +1 -0
  536. package/lib/utils/loadScript.js +9 -0
  537. package/lib/utils/loadScript.js.map +1 -0
  538. package/lib/utils/navigatorIsAvailable.d.ts +3 -0
  539. package/lib/utils/navigatorIsAvailable.d.ts.map +1 -0
  540. package/lib/utils/navigatorIsAvailable.js +3 -0
  541. package/lib/utils/navigatorIsAvailable.js.map +1 -0
  542. package/lib/utils/normalizeElements.d.ts +9 -0
  543. package/lib/utils/normalizeElements.d.ts.map +1 -0
  544. package/lib/utils/normalizeElements.js +14 -0
  545. package/lib/utils/normalizeElements.js.map +1 -0
  546. package/lib/utils/range.d.ts +4 -0
  547. package/lib/utils/range.d.ts.map +1 -0
  548. package/lib/utils/range.js +8 -0
  549. package/lib/utils/range.js.map +1 -0
  550. package/lib/utils/reflow.d.ts +4 -0
  551. package/lib/utils/reflow.d.ts.map +1 -0
  552. package/lib/utils/reflow.js +7 -0
  553. package/lib/utils/reflow.js.map +1 -0
  554. package/lib/utils/replaceMatchWithElement.d.ts +4 -0
  555. package/lib/utils/replaceMatchWithElement.d.ts.map +1 -0
  556. package/lib/utils/replaceMatchWithElement.js +32 -0
  557. package/lib/utils/replaceMatchWithElement.js.map +1 -0
  558. package/lib/utils/sameOrigin.d.ts +7 -0
  559. package/lib/utils/sameOrigin.d.ts.map +1 -0
  560. package/lib/utils/sameOrigin.js +25 -0
  561. package/lib/utils/sameOrigin.js.map +1 -0
  562. package/lib/utils/testElForOverflow.d.ts +4 -0
  563. package/lib/utils/testElForOverflow.d.ts.map +1 -0
  564. package/lib/utils/testElForOverflow.js +6 -0
  565. package/lib/utils/testElForOverflow.js.map +1 -0
  566. package/lib/utils/triple.d.ts +12 -0
  567. package/lib/utils/triple.d.ts.map +1 -0
  568. package/lib/utils/triple.js +13 -0
  569. package/lib/utils/triple.js.map +1 -0
  570. package/lib/utils/tryCatch.d.ts +5 -0
  571. package/lib/utils/tryCatch.d.ts.map +1 -0
  572. package/lib/utils/tryCatch.js +16 -0
  573. package/lib/utils/tryCatch.js.map +1 -0
  574. package/lib/utils/windowIsAvailable.d.ts +3 -0
  575. package/lib/utils/windowIsAvailable.d.ts.map +1 -0
  576. package/lib/utils/windowIsAvailable.js +3 -0
  577. package/lib/utils/windowIsAvailable.js.map +1 -0
  578. package/package.json +4 -2
  579. package/lib/components/ListToolbar/QueryOptionPopover.d.ts +0 -12
  580. package/lib/components/ListToolbar/QueryOptionPopover.d.ts.map +0 -1
  581. package/lib/components/ListToolbar/QueryOptionPopover.js +0 -36
  582. package/lib/components/ListToolbar/QueryOptionPopover.js.map +0 -1
  583. package/lib/utils/utils.d.ts +0 -93
  584. package/lib/utils/utils.d.ts.map +0 -1
  585. package/lib/utils/utils.js +0 -287
  586. package/lib/utils/utils.js.map +0 -1
@@ -1,36 +1,6 @@
1
1
  import { deepGet, defineSmartGetter } from '../utils';
2
2
  export const resetToInitial = Symbol.for('@pega/cosmos-react-core.theme.resetToInitial');
3
3
  class ThemeMachine {
4
- constructor({ theme = {}, parent, definition }) {
5
- Object.defineProperty(this, "parent", {
6
- enumerable: true,
7
- configurable: true,
8
- writable: true,
9
- value: void 0
10
- });
11
- Object.defineProperty(this, "definition", {
12
- enumerable: true,
13
- configurable: true,
14
- writable: true,
15
- value: void 0
16
- });
17
- Object.defineProperty(this, "overrides", {
18
- enumerable: true,
19
- configurable: true,
20
- writable: true,
21
- value: void 0
22
- });
23
- Object.defineProperty(this, "theme", {
24
- enumerable: true,
25
- configurable: true,
26
- writable: true,
27
- value: void 0
28
- });
29
- this.parent = parent ?? null;
30
- this.definition = parent ? parent.definition : definition;
31
- this.overrides = new Map();
32
- this.theme = this.constructTheme(theme);
33
- }
34
4
  overrideInTree(keys) {
35
5
  let ancestor = this;
36
6
  const fullProp = keys.join('.');
@@ -89,6 +59,36 @@ class ThemeMachine {
89
59
  };
90
60
  return constructForNode();
91
61
  }
62
+ constructor({ theme = {}, parent, definition }) {
63
+ Object.defineProperty(this, "parent", {
64
+ enumerable: true,
65
+ configurable: true,
66
+ writable: true,
67
+ value: void 0
68
+ });
69
+ Object.defineProperty(this, "definition", {
70
+ enumerable: true,
71
+ configurable: true,
72
+ writable: true,
73
+ value: void 0
74
+ });
75
+ Object.defineProperty(this, "overrides", {
76
+ enumerable: true,
77
+ configurable: true,
78
+ writable: true,
79
+ value: void 0
80
+ });
81
+ Object.defineProperty(this, "theme", {
82
+ enumerable: true,
83
+ configurable: true,
84
+ writable: true,
85
+ value: void 0
86
+ });
87
+ this.parent = parent ?? null;
88
+ this.definition = parent ? parent.definition : definition;
89
+ this.overrides = new Map();
90
+ this.theme = this.constructTheme(theme);
91
+ }
92
92
  }
93
93
  export default ThemeMachine;
94
94
  //# sourceMappingURL=ThemeMachine.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ThemeMachine.js","sourceRoot":"","sources":["../../src/theme/ThemeMachine.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AAwBtD,MAAM,CAAC,MAAM,cAAc,GAAG,MAAM,CAAC,GAAG,CAAC,8CAA8C,CAAC,CAAC;AAYzF,MAAM,YAAY;IAiFhB,YAAY,EACV,KAAK,GAAG,EAA+B,EACvC,MAAM,EACN,UAAU,EAOqE;QA1FjF;;;;;WAA4C;QAE5C;;;;;WAAuB;QAEvB;;;;;WAAgC;QAEhC;;;;;WAAyC;QAqFvC,IAAI,CAAC,MAAM,GAAG,MAAM,IAAI,IAAI,CAAC;QAC7B,IAAI,CAAC,UAAU,GAAG,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC,CAAC,UAAU,CAAC;QAC1D,IAAI,CAAC,SAAS,GAAG,IAAI,GAAG,EAAE,CAAC;QAC3B,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;IAC1C,CAAC;IAvFD,cAAc,CAAC,IAAc;QAC3B,IAAI,QAAQ,GAAwC,IAAI,CAAC;QACzD,MAAM,QAAQ,GAAG,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QAEhC,OAAO,QAAQ,EAAE;YACf,0CAA0C;YAC1C,OAAO,CAAC,QAAQ,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;YAE9B,IAAI,QAAQ,CAAC,SAAS,CAAC,GAAG,CAAC,QAAQ,CAAC;gBAAE,OAAO,CAAC,CAAC,QAAQ,CAAC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;gBAED,qEAAqE;qBAChE,IAAI,IAAI,CAAC,cAAc,CAAC,QAAQ,CAAC,EAAE;oBACtC,wCAAwC;oBACxC,iBAAiB,CAAC,SAAS,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC,MAAO,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC;iBAChF;gBAED,uCAAuC;qBAClC,IAAI,OAAO,CAAC,KAAK,KAAK,WAAW,EAAE;oBACtC,4DAA4D;oBAC5D,iBAAiB,CAAC,SAAS,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,EAAE,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;iBACzF;gBAED,qCAAqC;qBAChC,IAAI,OAAO,CAAC,KAAK,KAAK,SAAS,EAAE;oBACpC,6CAA6C;oBAC7C,SAAS,CAAC,GAAG,CAAC,GAAG,OAAO,CAAC,MAAM,CAAC;iBACjC;YACH,CAAC,CAAC,CAAC;YAEH,OAAO,SAAS,CAAC;QACnB,CAAC,CAAC;QAEF,OAAO,gBAAgB,EAA8B,CAAC;IACxD,CAAC;CAkBF;AAED,eAAe,YAAY,CAAC","sourcesContent":["import { deepGet, defineSmartGetter } from '../utils';\nimport { DeepPartial } from '../types';\n\nexport interface ThemeLeaf<Value> {\n $type: string;\n $value: Value;\n $constant?: boolean;\n $comment?: string;\n}\n\nexport type ThemeDefinition = {\n [key: string]: ThemeLeaf<unknown> | ThemeDefinition;\n};\n\nexport type ToThemeIFace<Node, Extension = never> = Node extends ThemeLeaf<infer LeafVal>\n ? (LeafVal extends null ? LeafVal | string : LeafVal) | Extension\n : Node extends object\n ? {\n readonly [Key in Exclude<keyof Node, '$comment'>]: ToThemeIFace<Node[Key], Extension>;\n }\n : Node | Extension;\n\nexport type SettableTheme<Def extends ThemeDefinition> = DeepPartial<ToThemeIFace<Def, symbol>>;\n\nexport const resetToInitial = Symbol.for('@pega/cosmos-react-core.theme.resetToInitial');\n\nexport interface ThemeMachineLike<Definition extends ThemeDefinition> {\n parent: ThemeMachineLike<Definition> | null;\n\n definition: Definition;\n\n overrides: Map<string, boolean>;\n\n readonly theme: ToThemeIFace<Definition>;\n}\n\nclass ThemeMachine<Definition extends ThemeDefinition> implements ThemeMachineLike<Definition> {\n parent: ThemeMachineLike<Definition> | null;\n\n definition: Definition;\n\n overrides: Map<string, boolean>;\n\n readonly theme: ToThemeIFace<Definition>;\n\n overrideInTree(keys: string[]): boolean {\n let ancestor: ThemeMachineLike<Definition> | null = this;\n const fullProp = keys.join('.');\n\n while (ancestor) {\n // Trigger getters in the ancestor themes.\n deepGet(ancestor.theme, keys);\n\n if (ancestor.overrides.has(fullProp)) return !!ancestor.overrides.get(fullProp);\n ancestor = ancestor.parent;\n }\n\n return false;\n }\n\n constructTheme(theme: SettableTheme<Definition>): ToThemeIFace<Definition> {\n const constructForNode = (keys: string[] = []) => {\n const themeNode: Record<string, any> = {};\n\n Object.keys(deepGet(this.definition, keys)).forEach(key => {\n // Ignore comment nodes.\n if (key === '$comment') return;\n\n const propKeys = [...keys, key];\n const defNode: Record<string, any> = deepGet(this.definition, propKeys);\n\n // If it is not a leaf node of the theme definition...\n if (defNode.$type === undefined) {\n // recursively run for child nodes.\n defineSmartGetter(themeNode, key, () => constructForNode(propKeys));\n return;\n }\n\n const themeValue = deepGet(theme, propKeys);\n\n // If a theme value was set for this ThemeMachine...\n if (themeValue !== undefined) {\n // set overrides to true, unless it is being reset.\n this.overrides.set(propKeys.join('.'), themeValue !== resetToInitial);\n }\n\n // If a theme value was set for this ThemeMachine, is not being reset, and is for a non-constant property...\n if (themeValue !== undefined && themeValue !== resetToInitial && !defNode.$constant) {\n // set to the provided value.\n themeNode[key] = themeValue;\n }\n\n // If the property has been overridden in the tree (and not reset)...\n else if (this.overrideInTree(propKeys)) {\n // set to the value in the parent theme.\n defineSmartGetter(themeNode, key, () => deepGet(this.parent!.theme, propKeys));\n }\n\n // If the property type is inherited...\n else if (defNode.$type === 'inherited') {\n // set to the value of the inherited property in this theme.\n defineSmartGetter(themeNode, key, () => deepGet(this.theme, defNode.$value.split('.')));\n }\n\n // If the property type is literal...\n else if (defNode.$type === 'literal') {\n // set to the value listed in the definition.\n themeNode[key] = defNode.$value;\n }\n });\n\n return themeNode;\n };\n\n return constructForNode() as ToThemeIFace<Definition>;\n }\n\n constructor({\n theme = {} as SettableTheme<Definition>,\n parent,\n definition\n }:\n | {\n theme?: SettableTheme<Definition>;\n parent: ThemeMachineLike<Definition>;\n definition?: never;\n }\n | { theme?: SettableTheme<Definition>; parent?: never; definition: Definition }) {\n this.parent = parent ?? null;\n this.definition = parent ? parent.definition : definition;\n this.overrides = new Map();\n this.theme = this.constructTheme(theme);\n }\n}\n\nexport default ThemeMachine;\n"]}
1
+ {"version":3,"file":"ThemeMachine.js","sourceRoot":"","sources":["../../src/theme/ThemeMachine.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,iBAAiB,EAAE,MAAM,UAAU,CAAC;AAwBtD,MAAM,CAAC,MAAM,cAAc,GAAG,MAAM,CAAC,GAAG,CAAC,8CAA8C,CAAC,CAAC;AAYzF,MAAM,YAAY;IAShB,cAAc,CAAC,IAAc;QAC3B,IAAI,QAAQ,GAAwC,IAAI,CAAC;QACzD,MAAM,QAAQ,GAAG,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QAEhC,OAAO,QAAQ,EAAE;YACf,0CAA0C;YAC1C,OAAO,CAAC,QAAQ,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;YAE9B,IAAI,QAAQ,CAAC,SAAS,CAAC,GAAG,CAAC,QAAQ,CAAC;gBAAE,OAAO,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;YAChF,QAAQ,GAAG,QAAQ,CAAC,MAAM,CAAC;SAC5B;QAED,OAAO,KAAK,CAAC;IACf,CAAC;IA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,GAAG,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC,MAAO,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC;iBAChF;gBAED,uCAAuC;qBAClC,IAAI,OAAO,CAAC,KAAK,KAAK,WAAW,EAAE;oBACtC,4DAA4D;oBAC5D,iBAAiB,CAAC,SAAS,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,EAAE,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;iBACzF;gBAED,qCAAqC;qBAChC,IAAI,OAAO,CAAC,KAAK,KAAK,SAAS,EAAE;oBACpC,6CAA6C;oBAC7C,SAAS,CAAC,GAAG,CAAC,GAAG,OAAO,CAAC,MAAM,CAAC;iBACjC;YACH,CAAC,CAAC,CAAC;YAEH,OAAO,SAAS,CAAC;QACnB,CAAC,CAAC;QAEF,OAAO,gBAAgB,EAA8B,CAAC;IACxD,CAAC;IAED,YAAY,EACV,KAAK,GAAG,EAA+B,EACvC,MAAM,EACN,UAAU,EAOqE;QA1FjF;;;;;WAA4C;QAE5C;;;;;WAAuB;QAEvB;;;;;WAAgC;QAEhC;;;;;WAAyC;QAqFvC,IAAI,CAAC,MAAM,GAAG,MAAM,IAAI,IAAI,CAAC;QAC7B,IAAI,CAAC,UAAU,GAAG,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC,CAAC,UAAU,CAAC;QAC1D,IAAI,CAAC,SAAS,GAAG,IAAI,GAAG,EAAE,CAAC;QAC3B,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;IAC1C,CAAC;CACF;AAED,eAAe,YAAY,CAAC","sourcesContent":["import { deepGet, defineSmartGetter } from '../utils';\nimport { DeepPartial } from '../types';\n\nexport interface ThemeLeaf<Value> {\n $type: string;\n $value: Value;\n $constant?: boolean;\n $comment?: string;\n}\n\nexport type ThemeDefinition = {\n [key: string]: ThemeLeaf<unknown> | ThemeDefinition;\n};\n\nexport type ToThemeIFace<Node, Extension = never> = Node extends ThemeLeaf<infer LeafVal>\n ? (LeafVal extends null ? LeafVal | string : LeafVal) | Extension\n : Node extends object\n ? {\n readonly [Key in Exclude<keyof Node, '$comment'>]: ToThemeIFace<Node[Key], Extension>;\n }\n : Node | Extension;\n\nexport type SettableTheme<Def extends ThemeDefinition> = DeepPartial<ToThemeIFace<Def, symbol>>;\n\nexport const resetToInitial = Symbol.for('@pega/cosmos-react-core.theme.resetToInitial');\n\nexport interface ThemeMachineLike<Definition extends ThemeDefinition> {\n parent: ThemeMachineLike<Definition> | null;\n\n definition: Definition;\n\n overrides: Map<string, boolean>;\n\n readonly theme: ToThemeIFace<Definition>;\n}\n\nclass ThemeMachine<Definition extends ThemeDefinition> implements ThemeMachineLike<Definition> {\n parent: ThemeMachineLike<Definition> | null;\n\n definition: Definition;\n\n overrides: Map<string, boolean>;\n\n readonly theme: ToThemeIFace<Definition>;\n\n overrideInTree(keys: string[]): boolean {\n let ancestor: ThemeMachineLike<Definition> | null = this;\n const fullProp = keys.join('.');\n\n while (ancestor) {\n // Trigger getters in the ancestor themes.\n deepGet(ancestor.theme, keys);\n\n if (ancestor.overrides.has(fullProp)) return !!ancestor.overrides.get(fullProp);\n ancestor = ancestor.parent;\n }\n\n return false;\n }\n\n constructTheme(theme: SettableTheme<Definition>): ToThemeIFace<Definition> {\n const constructForNode = (keys: string[] = []) => {\n const themeNode: Record<string, any> = {};\n\n Object.keys(deepGet(this.definition, keys)).forEach(key => {\n // Ignore comment nodes.\n if (key === '$comment') return;\n\n const propKeys = [...keys, key];\n const defNode: Record<string, any> = deepGet(this.definition, propKeys);\n\n // If it is not a leaf node of the theme definition...\n if (defNode.$type === undefined) {\n // recursively run for child nodes.\n defineSmartGetter(themeNode, key, () => constructForNode(propKeys));\n return;\n }\n\n const themeValue = deepGet(theme, propKeys);\n\n // If a theme value was set for this ThemeMachine...\n if (themeValue !== undefined) {\n // set overrides to true, unless it is being reset.\n this.overrides.set(propKeys.join('.'), themeValue !== resetToInitial);\n }\n\n // If a theme value was set for this ThemeMachine, is not being reset, and is for a non-constant property...\n if (themeValue !== undefined && themeValue !== resetToInitial && !defNode.$constant) {\n // set to the provided value.\n themeNode[key] = themeValue;\n }\n\n // If the property has been overridden in the tree (and not reset)...\n else if (this.overrideInTree(propKeys)) {\n // set to the value in the parent theme.\n defineSmartGetter(themeNode, key, () => deepGet(this.parent!.theme, propKeys));\n }\n\n // If the property type is inherited...\n else if (defNode.$type === 'inherited') {\n // set to the value of the inherited property in this theme.\n defineSmartGetter(themeNode, key, () => deepGet(this.theme, defNode.$value.split('.')));\n }\n\n // If the property type is literal...\n else if (defNode.$type === 'literal') {\n // set to the value listed in the definition.\n themeNode[key] = defNode.$value;\n }\n });\n\n return themeNode;\n };\n\n return constructForNode() as ToThemeIFace<Definition>;\n }\n\n constructor({\n theme = {} as SettableTheme<Definition>,\n parent,\n definition\n }:\n | {\n theme?: SettableTheme<Definition>;\n parent: ThemeMachineLike<Definition>;\n definition?: never;\n }\n | { theme?: SettableTheme<Definition>; parent?: never; definition: Definition }) {\n this.parent = parent ?? null;\n this.definition = parent ? parent.definition : definition;\n this.overrides = new Map();\n this.theme = this.constructTheme(theme);\n }\n}\n\nexport default ThemeMachine;\n"]}
@@ -1,6 +1,6 @@
1
1
  import ThemeMachine, { ToThemeIFace, SettableTheme } from './ThemeMachine';
2
2
  import defaultThemeDefinition from './themeDefinition.json';
3
- export declare type DefaultThemeDefinition = typeof defaultThemeDefinition;
3
+ export type DefaultThemeDefinition = typeof defaultThemeDefinition;
4
4
  export { defaultThemeDefinition as themeDefinition };
5
5
  export declare const BaseThemeMachine: ThemeMachine<{
6
6
  base: {
@@ -411,19 +411,23 @@ export declare const BaseThemeMachine: ThemeMachine<{
411
411
  $type: string;
412
412
  $value: string;
413
413
  };
414
- "focus-inverted": {
414
+ "focus-group": {
415
415
  $type: string;
416
416
  $value: string;
417
417
  };
418
- "focus-solid": {
418
+ "focus-group-inset": {
419
419
  $type: string;
420
420
  $value: string;
421
421
  };
422
- "focus-filter": {
422
+ "focus-inset": {
423
+ $type: string;
424
+ $value: string;
425
+ };
426
+ "focus-solid": {
423
427
  $type: string;
424
428
  $value: string;
425
429
  };
426
- "focus-inverted-filter": {
430
+ "focus-filter": {
427
431
  $type: string;
428
432
  $value: string;
429
433
  };
@@ -592,27 +596,7 @@ export declare const BaseThemeMachine: ThemeMachine<{
592
596
  };
593
597
  };
594
598
  count: {
595
- base: {
596
- foreground: {
597
- $type: string;
598
- $value: string;
599
- };
600
- background: {
601
- $type: string;
602
- $value: string;
603
- };
604
- };
605
- interactive: {
606
- foreground: {
607
- $type: string;
608
- $value: string;
609
- };
610
- background: {
611
- $type: string;
612
- $value: string;
613
- };
614
- };
615
- inverted: {
599
+ default: {
616
600
  foreground: {
617
601
  $type: string;
618
602
  $value: string;
@@ -1578,6 +1562,7 @@ export declare const WorkTheme: {
1578
1562
  readonly dark: string;
1579
1563
  readonly light: string;
1580
1564
  readonly "background-color": string;
1565
+ readonly success: string;
1581
1566
  readonly "app-background": string;
1582
1567
  readonly "primary-background": string;
1583
1568
  readonly "secondary-background": string;
@@ -1586,7 +1571,6 @@ export declare const WorkTheme: {
1586
1571
  readonly "brand-secondary": string;
1587
1572
  readonly urgent: string;
1588
1573
  readonly warn: string;
1589
- readonly success: string;
1590
1574
  readonly pending: string;
1591
1575
  readonly info: string;
1592
1576
  readonly interactive: string;
@@ -1620,10 +1604,11 @@ export declare const WorkTheme: {
1620
1604
  readonly focus: string;
1621
1605
  readonly "high-filter": string;
1622
1606
  readonly "low-filter": string;
1623
- readonly "focus-inverted": string;
1607
+ readonly "focus-group": string;
1608
+ readonly "focus-group-inset": string;
1609
+ readonly "focus-inset": string;
1624
1610
  readonly "focus-solid": string;
1625
1611
  readonly "focus-filter": string;
1626
- readonly "focus-inverted-filter": string;
1627
1612
  };
1628
1613
  readonly breakpoints: {
1629
1614
  readonly xs: string;
@@ -1770,19 +1755,19 @@ export declare const WorkTheme: {
1770
1755
  readonly "touch-width": string;
1771
1756
  };
1772
1757
  readonly banner: {
1773
- readonly urgent: {
1758
+ readonly warning: {
1774
1759
  readonly background: string;
1775
1760
  };
1776
1761
  readonly success: {
1777
1762
  readonly background: string;
1778
1763
  };
1779
- readonly info: {
1764
+ readonly urgent: {
1780
1765
  readonly background: string;
1781
1766
  };
1782
- readonly "icon-color": string;
1783
- readonly warning: {
1767
+ readonly info: {
1784
1768
  readonly background: string;
1785
1769
  };
1770
+ readonly "icon-color": string;
1786
1771
  };
1787
1772
  readonly "app-shell": {
1788
1773
  readonly header: {
@@ -1801,23 +1786,23 @@ export declare const WorkTheme: {
1801
1786
  readonly base: {
1802
1787
  readonly "border-color": string;
1803
1788
  };
1804
- readonly urgent: {
1789
+ readonly success: {
1805
1790
  readonly background: string;
1806
1791
  };
1807
- readonly success: {
1792
+ readonly urgent: {
1808
1793
  readonly background: string;
1809
1794
  };
1810
1795
  };
1811
1796
  readonly status: {
1812
- readonly urgent: {
1797
+ readonly success: {
1813
1798
  readonly background: string;
1814
1799
  readonly foreground: string;
1815
1800
  };
1816
- readonly warn: {
1801
+ readonly urgent: {
1817
1802
  readonly background: string;
1818
1803
  readonly foreground: string;
1819
1804
  };
1820
- readonly success: {
1805
+ readonly warn: {
1821
1806
  readonly background: string;
1822
1807
  readonly foreground: string;
1823
1808
  };
@@ -1831,7 +1816,7 @@ export declare const WorkTheme: {
1831
1816
  };
1832
1817
  };
1833
1818
  readonly count: {
1834
- readonly base: {
1819
+ readonly default: {
1835
1820
  readonly background: string;
1836
1821
  readonly foreground: string;
1837
1822
  };
@@ -1839,14 +1824,6 @@ export declare const WorkTheme: {
1839
1824
  readonly background: string;
1840
1825
  readonly foreground: string;
1841
1826
  };
1842
- readonly interactive: {
1843
- readonly background: string;
1844
- readonly foreground: string;
1845
- };
1846
- readonly inverted: {
1847
- readonly background: string;
1848
- readonly foreground: string;
1849
- };
1850
1827
  };
1851
1828
  readonly tag: {
1852
1829
  readonly background: string;
@@ -1938,13 +1915,13 @@ export declare const WorkTheme: {
1938
1915
  readonly error: {
1939
1916
  readonly "status-color": string;
1940
1917
  };
1941
- readonly success: {
1918
+ readonly warning: {
1942
1919
  readonly "status-color": string;
1943
1920
  };
1944
- readonly pending: {
1921
+ readonly success: {
1945
1922
  readonly "status-color": string;
1946
1923
  };
1947
- readonly warning: {
1924
+ readonly pending: {
1948
1925
  readonly "status-color": string;
1949
1926
  };
1950
1927
  };
@@ -2153,6 +2130,7 @@ export declare const defaultThemeProp: Readonly<{
2153
2130
  readonly dark: string;
2154
2131
  readonly light: string;
2155
2132
  readonly "background-color": string;
2133
+ readonly success: string;
2156
2134
  readonly "app-background": string;
2157
2135
  readonly "primary-background": string;
2158
2136
  readonly "secondary-background": string;
@@ -2161,7 +2139,6 @@ export declare const defaultThemeProp: Readonly<{
2161
2139
  readonly "brand-secondary": string;
2162
2140
  readonly urgent: string;
2163
2141
  readonly warn: string;
2164
- readonly success: string;
2165
2142
  readonly pending: string;
2166
2143
  readonly info: string;
2167
2144
  readonly interactive: string;
@@ -2195,10 +2172,11 @@ export declare const defaultThemeProp: Readonly<{
2195
2172
  readonly focus: string;
2196
2173
  readonly "high-filter": string;
2197
2174
  readonly "low-filter": string;
2198
- readonly "focus-inverted": string;
2175
+ readonly "focus-group": string;
2176
+ readonly "focus-group-inset": string;
2177
+ readonly "focus-inset": string;
2199
2178
  readonly "focus-solid": string;
2200
2179
  readonly "focus-filter": string;
2201
- readonly "focus-inverted-filter": string;
2202
2180
  };
2203
2181
  readonly breakpoints: {
2204
2182
  readonly xs: string;
@@ -2345,19 +2323,19 @@ export declare const defaultThemeProp: Readonly<{
2345
2323
  readonly "touch-width": string;
2346
2324
  };
2347
2325
  readonly banner: {
2348
- readonly urgent: {
2326
+ readonly warning: {
2349
2327
  readonly background: string;
2350
2328
  };
2351
2329
  readonly success: {
2352
2330
  readonly background: string;
2353
2331
  };
2354
- readonly info: {
2332
+ readonly urgent: {
2355
2333
  readonly background: string;
2356
2334
  };
2357
- readonly "icon-color": string;
2358
- readonly warning: {
2335
+ readonly info: {
2359
2336
  readonly background: string;
2360
2337
  };
2338
+ readonly "icon-color": string;
2361
2339
  };
2362
2340
  readonly "app-shell": {
2363
2341
  readonly header: {
@@ -2376,23 +2354,23 @@ export declare const defaultThemeProp: Readonly<{
2376
2354
  readonly base: {
2377
2355
  readonly "border-color": string;
2378
2356
  };
2379
- readonly urgent: {
2357
+ readonly success: {
2380
2358
  readonly background: string;
2381
2359
  };
2382
- readonly success: {
2360
+ readonly urgent: {
2383
2361
  readonly background: string;
2384
2362
  };
2385
2363
  };
2386
2364
  readonly status: {
2387
- readonly urgent: {
2365
+ readonly success: {
2388
2366
  readonly background: string;
2389
2367
  readonly foreground: string;
2390
2368
  };
2391
- readonly warn: {
2369
+ readonly urgent: {
2392
2370
  readonly background: string;
2393
2371
  readonly foreground: string;
2394
2372
  };
2395
- readonly success: {
2373
+ readonly warn: {
2396
2374
  readonly background: string;
2397
2375
  readonly foreground: string;
2398
2376
  };
@@ -2406,7 +2384,7 @@ export declare const defaultThemeProp: Readonly<{
2406
2384
  };
2407
2385
  };
2408
2386
  readonly count: {
2409
- readonly base: {
2387
+ readonly default: {
2410
2388
  readonly background: string;
2411
2389
  readonly foreground: string;
2412
2390
  };
@@ -2414,14 +2392,6 @@ export declare const defaultThemeProp: Readonly<{
2414
2392
  readonly background: string;
2415
2393
  readonly foreground: string;
2416
2394
  };
2417
- readonly interactive: {
2418
- readonly background: string;
2419
- readonly foreground: string;
2420
- };
2421
- readonly inverted: {
2422
- readonly background: string;
2423
- readonly foreground: string;
2424
- };
2425
2395
  };
2426
2396
  readonly tag: {
2427
2397
  readonly background: string;
@@ -2513,13 +2483,13 @@ export declare const defaultThemeProp: Readonly<{
2513
2483
  readonly error: {
2514
2484
  readonly "status-color": string;
2515
2485
  };
2516
- readonly success: {
2486
+ readonly warning: {
2517
2487
  readonly "status-color": string;
2518
2488
  };
2519
- readonly pending: {
2489
+ readonly success: {
2520
2490
  readonly "status-color": string;
2521
2491
  };
2522
- readonly warning: {
2492
+ readonly pending: {
2523
2493
  readonly "status-color": string;
2524
2494
  };
2525
2495
  };
@@ -2633,7 +2603,7 @@ export declare const defaultThemeProp: Readonly<{
2633
2603
  };
2634
2604
  };
2635
2605
  }>;
2636
- export declare type DefaultSettableTheme = SettableTheme<typeof defaultThemeDefinition>;
2606
+ export type DefaultSettableTheme = SettableTheme<typeof defaultThemeDefinition>;
2637
2607
  declare module 'styled-components' {
2638
2608
  interface DefaultTheme extends ToThemeIFace<typeof defaultThemeDefinition> {
2639
2609
  }
@@ -1 +1 @@
1
- {"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../src/theme/theme.ts"],"names":[],"mappings":"AAAA,OAAO,YAAY,EAAE,EAAE,YAAY,EAAE,aAAa,EAAkB,MAAM,gBAAgB,CAAC;AAC3F,OAAO,sBAAsB,MAAM,wBAAwB,CAAC;AAE5D,oBAAY,sBAAsB,GAAG,OAAO,sBAAsB,CAAC;AAEnE,OAAO,EAAE,sBAAsB,IAAI,eAAe,EAAE,CAAC;AAErD,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAAsC,CAAC;AAEpE,MAAM,MAAM,oBAAoB,GAAG,aAAa,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAGhF,OAAO,QAAQ,mBAAmB,CAAC;IACjC,UAAiB,YAAa,SAAQ,YAAY,CAAC,OAAO,sBAAsB,CAAC;KAAG;CACrF"}
@@ -279,11 +279,19 @@
279
279
  },
280
280
  "focus": {
281
281
  "$type": "literal",
282
- "$value": "0 0 0 0.125rem rgba(0, 118, 209, 0.30)"
282
+ "$value": "0 0 0 0.11rem #fff, 0 0 0 0.18rem #076bc9, 0 0 0 0.3rem #076bc91a"
283
283
  },
284
- "focus-inverted": {
284
+ "focus-group": {
285
285
  "$type": "literal",
286
- "$value": "0 0 0 0.125rem rgba(255, 255, 255, 0.30)"
286
+ "$value": "0 0 0 0.125rem #076bc966"
287
+ },
288
+ "focus-group-inset": {
289
+ "$type": "literal",
290
+ "$value": "inset 0 0 0 0.125rem #076bc966"
291
+ },
292
+ "focus-inset": {
293
+ "$type": "literal",
294
+ "$value": "inset 0 0 0 0.11rem #fff, inset 0 0 0 0.18rem #076bc9, inset 0 0 0 0.3rem #076bc91a"
287
295
  },
288
296
  "focus-solid": {
289
297
  "$type": "literal",
@@ -292,10 +300,6 @@
292
300
  "focus-filter": {
293
301
  "$type": "literal",
294
302
  "$value": "drop-shadow(0 0 0.125rem rgba(0, 118, 209, 0.30))"
295
- },
296
- "focus-inverted-filter": {
297
- "$type": "literal",
298
- "$value": "drop-shadow(0 0 0.125rem rgba(255, 255, 255, 0.30))"
299
303
  }
300
304
  },
301
305
  "z-index": {
@@ -462,34 +466,14 @@
462
466
  }
463
467
  },
464
468
  "count": {
465
- "base": {
466
- "foreground": {
467
- "$type": "inherited",
468
- "$value": "base.colors.slate.extra-dark"
469
- },
470
- "background": {
471
- "$type": "inherited",
472
- "$value": "base.colors.slate.light"
473
- }
474
- },
475
- "interactive": {
476
- "foreground": {
477
- "$type": "inherited",
478
- "$value": "base.palette.light"
479
- },
480
- "background": {
481
- "$type": "inherited",
482
- "$value": "base.palette.interactive"
483
- }
484
- },
485
- "inverted": {
469
+ "default": {
486
470
  "foreground": {
487
471
  "$type": "inherited",
488
- "$value": "base.palette.light"
472
+ "$value": "base.colors.slate.dark"
489
473
  },
490
474
  "background": {
491
475
  "$type": "inherited",
492
- "$value": "base.palette.interactive"
476
+ "$value": "base.colors.slate.extra-light"
493
477
  }
494
478
  },
495
479
  "urgent": {
@@ -360,14 +360,11 @@
360
360
  "focus": {
361
361
  "type": "string"
362
362
  },
363
- "focus-inverted": {
363
+ "focus-inset": {
364
364
  "type": "string"
365
365
  },
366
366
  "focus-filter": {
367
367
  "type": "string"
368
- },
369
- "focus-inverted-filter": {
370
- "type": "string"
371
368
  }
372
369
  },
373
370
  "additionalProperties": false
@@ -20,7 +20,10 @@
20
20
  "dark": "#ffffff"
21
21
  },
22
22
  "shadow": {
23
- "focus": "0 0 0.25rem rgba(255, 255, 255, 0.95)"
23
+ "focus": "0 0 0 0.11rem #fff, 0 0 0 0.18rem #71c1ff, 0 0 0 0.3rem #71c1ff1a",
24
+ "focus-inset": "inset 0 0 0 0.11rem #fff, inset 0 0 0 0.18rem #71c1ff, inset 0 0 0 0.3rem #71c1ff1a",
25
+ "focus-group": "0 0 0 0.125rem #71c1ff99",
26
+ "focus-group-inset": "inset 0 0 0 0.125rem #71c1ff99"
24
27
  }
25
28
  },
26
29
  "components": {
@@ -6,9 +6,8 @@
6
6
  },
7
7
  "shadow": {
8
8
  "focus": "0 0 0 0.0625rem #295ED9",
9
- "focus-inverted": "0 0 0 0.0625rem #ffffff",
10
- "focus-filter": "drop-shadow(0.0625rem 0px 0px #295ED9) drop-shadow(-0.0625rem 0px 0px #295ED9) drop-shadow(0px 0.0625rem 0px #295ED9) drop-shadow(0px -0.0625rem 0px #295ED9)",
11
- "focus-inverted-filter": "drop-shadow(0.0625rem 0px 0px #ffffff) drop-shadow(-0.0625rem 0px 0px #ffffff) drop-shadow(0px 0.0625rem 0px #ffffff) drop-shadow(0px -0.0625rem 0px #ffffff)"
9
+ "focus-inset": "inset 0 0 0 0.0625rem #295ED9",
10
+ "focus-filter": "drop-shadow(0.0625rem 0px 0px #295ED9) drop-shadow(-0.0625rem 0px 0px #295ED9) drop-shadow(0px 0.0625rem 0px #295ED9) drop-shadow(0px -0.0625rem 0px #295ED9)"
12
11
  }
13
12
  },
14
13
  "components": {
@@ -9,7 +9,7 @@ export interface ForwardProps {
9
9
  export interface NoChildrenProp {
10
10
  children?: never;
11
11
  }
12
- export declare type HTMLTag = keyof JSX.IntrinsicElements;
12
+ export type HTMLTag = keyof JSX.IntrinsicElements;
13
13
  export interface AsProp {
14
14
  /** HTML tag or React Component to render the component as. */
15
15
  as?: ElementType;
@@ -26,27 +26,35 @@ export interface Action extends ForwardProps {
26
26
  /** A location to navigate to. Passing an href will render a Link styled as a Button. */
27
27
  href?: string;
28
28
  /** Called when the Action is clicked. */
29
- onClick?: (id: string, e: MouseEvent<HTMLButtonElement | HTMLAnchorElement | HTMLInputElement>) => void;
29
+ onClick?: (id: string, e: MouseEvent<HTMLButtonElement | HTMLAnchorElement | HTMLInputElement>,
30
+ /**
31
+ * If the action was rendered as an item in a menu the associated menuButton element will be provided.
32
+ * Often necessary for focus purposes.
33
+ */
34
+ menuButton?: HTMLButtonElement) => void;
30
35
  /** Determines if the Action will be disabled. */
31
36
  disabled?: boolean;
32
37
  }
33
- export declare type OmitStrict<T, K extends keyof T> = Pick<T, Exclude<keyof T, K>>;
34
- export declare type PartialByKey<T extends object, K extends keyof T> = OmitStrict<T, K> & Partial<Pick<T, K>>;
35
- export declare type RequiredByKey<T extends object, K extends keyof T> = OmitStrict<T, K> & Required<Pick<T, K>>;
36
- export declare type DeepPartial<T> = T extends (infer U)[] ? DeepPartial<U>[] : T extends object ? {
38
+ export type OmitStrict<T, K extends keyof T> = Pick<T, Exclude<keyof T, K>>;
39
+ export type PartialByKey<T extends object, K extends keyof T> = OmitStrict<T, K> & Partial<Pick<T, K>>;
40
+ export type RequiredByKey<T extends object, K extends keyof T> = OmitStrict<T, K> & Required<Pick<T, K>>;
41
+ export type DeepPartial<T> = T extends (infer U)[] ? DeepPartial<U>[] : T extends object ? {
37
42
  [K in keyof T]?: DeepPartial<T[K]>;
38
43
  } : T;
39
- export declare type DeepRequired<T> = T extends (infer U)[] ? DeepRequired<U>[] : T extends Function ? T : T extends object ? {
44
+ export type DeepRequired<T> = T extends (infer U)[] ? DeepRequired<U>[] : T extends Function ? T : T extends object ? {
40
45
  [K in keyof T]-?: DeepRequired<T[K]>;
41
46
  } : T;
42
- export declare type RequireAtLeastOne<T, Keys extends keyof T = keyof T> = Pick<T, Exclude<keyof T, Keys>> & {
47
+ export type Mutable<T> = {
48
+ -readonly [P in keyof T]: T[P];
49
+ };
50
+ export type RequireAtLeastOne<T, Keys extends keyof T = keyof T> = Pick<T, Exclude<keyof T, Keys>> & {
43
51
  [K in Keys]-?: Required<Pick<T, K>> & Partial<Pick<T, Exclude<Keys, K>>>;
44
52
  }[Keys];
45
- export declare type DeferInfer<T> = T & {
53
+ export type DeferInfer<T> = T & {
46
54
  [K in keyof T]: T[K];
47
55
  };
48
- export declare type PropsWithDefaults<Props extends object = {}, Defaults extends keyof Props = never> = OmitStrict<Props, Defaults> & Required<Pick<Props, Defaults>>;
49
- export declare type PrettyPrint<T> = T extends object ? {
56
+ export type PropsWithDefaults<Props extends object = {}, Defaults extends keyof Props = never> = OmitStrict<Props, Defaults> & Required<Pick<Props, Defaults>>;
57
+ export type PrettyPrint<T> = T extends object ? {
50
58
  [K in keyof T]: T[K];
51
59
  } : T;
52
60
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/types/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAEhD,MAAM,WAAW,SAAS;IACxB,8BAA8B;IAC9B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,YAAY;IAC3B,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;CACzB;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,EAAE,KAAK,CAAC;CAClB;AAED,oBAAY,OAAO,GAAG,MAAM,GAAG,CAAC,iBAAiB,CAAC;AAClD,MAAM,WAAW,MAAM;IACrB,8DAA8D;IAC9D,EAAE,CAAC,EAAE,WAAW,CAAC;IACjB,sEAAsE;IACtE,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B;AAED,MAAM,WAAW,MAAO,SAAQ,YAAY;IAC1C,4EAA4E;IAC5E,EAAE,EAAE,MAAM,CAAC;IACX,sCAAsC;IACtC,IAAI,EAAE,MAAM,CAAC;IACb,qDAAqD;IACrD,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,wFAAwF;IACxF,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,yCAAyC;IACzC,OAAO,CAAC,EAAE,CACR,EAAE,EAAE,MAAM,EACV,CAAC,EAAE,UAAU,CAAC,iBAAiB,GAAG,iBAAiB,GAAG,gBAAgB,CAAC,KACpE,IAAI,CAAC;IACV,iDAAiD;IACjD,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAGD,oBAAY,UAAU,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,CAAC,IAAI,IAAI,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CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CACrB,GACD,CAAC,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/types/types.ts"],"names":[],"mappings":"","sourcesContent":["import { ElementType, MouseEvent } from 'react';\n\nexport interface BaseProps {\n /** Additional CSS classes. */\n className?: string;\n}\n\nexport interface ForwardProps {\n [prop: string]: unknown;\n}\n\nexport interface NoChildrenProp {\n children?: never;\n}\n\nexport type HTMLTag = keyof JSX.IntrinsicElements;\nexport interface AsProp {\n /** HTML tag or React Component to render the component as. */\n as?: ElementType;\n /** HTML tag or React Component to finally render the component as. */\n forwardedAs?: ElementType;\n}\n\nexport interface Action extends ForwardProps {\n /** A string to uniquely identify this Action within the onClick handler. */\n id: string;\n /** The text content of the Action. */\n text: string;\n /** The name of the Cosmos Icon to render, if any. */\n icon?: string;\n /** A location to navigate to. Passing an href will render a Link styled as a Button. */\n href?: string;\n /** Called when the Action is clicked. */\n onClick?: (\n id: string,\n e: MouseEvent<HTMLButtonElement | HTMLAnchorElement | HTMLInputElement>\n ) => void;\n /** Determines if the Action will be disabled. */\n disabled?: boolean;\n}\n\n// https://github.com/microsoft/TypeScript/issues/30825\nexport type OmitStrict<T, K extends keyof T> = Pick<T, Exclude<keyof T, K>>;\nexport type PartialByKey<T extends object, K extends keyof T> = OmitStrict<T, K> &\n Partial<Pick<T, K>>;\nexport type RequiredByKey<T extends object, K extends keyof T> = OmitStrict<T, K> &\n Required<Pick<T, K>>;\n\nexport type DeepPartial<T> = T extends (infer U)[]\n ? DeepPartial<U>[]\n : T extends object\n ? { [K in keyof T]?: DeepPartial<T[K]> }\n : T;\n\nexport type DeepRequired<T> = T extends (infer U)[]\n ? DeepRequired<U>[]\n : T extends Function\n ? T\n : T extends object\n ? { [K in keyof T]-?: DeepRequired<T[K]> }\n : T;\n\n// https://stackoverflow.com/a/49725198\nexport type RequireAtLeastOne<T, Keys extends keyof T = keyof T> = Pick<T, Exclude<keyof T, Keys>> &\n {\n [K in Keys]-?: Required<Pick<T, K>> & Partial<Pick<T, Exclude<Keys, K>>>;\n }[Keys];\n\n// Lowers type inference precedence without changing the type.\n// https://github.com/Microsoft/TypeScript/issues/14829#issue-216577598\nexport type DeferInfer<T> = T & { [K in keyof T]: T[K] };\n\n/* eslint-disable @typescript-eslint/ban-types */\nexport type PropsWithDefaults<\n Props extends object = {},\n Defaults extends keyof Props = never\n> = OmitStrict<Props, Defaults> & Required<Pick<Props, Defaults>>;\n/* eslint-enable @typescript-eslint/ban-types */\n\nexport type PrettyPrint<T> = T extends object\n ? {\n [K in keyof T]: T[K];\n }\n : T;\n"]}
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/types/types.ts"],"names":[],"mappings":"","sourcesContent":["import { ElementType, MouseEvent } from 'react';\n\nexport interface BaseProps {\n /** Additional CSS classes. */\n className?: string;\n}\n\nexport interface ForwardProps {\n [prop: string]: unknown;\n}\n\nexport interface NoChildrenProp {\n children?: never;\n}\n\nexport type HTMLTag = keyof JSX.IntrinsicElements;\nexport interface AsProp {\n /** HTML tag or React Component to render the component as. */\n as?: ElementType;\n /** HTML tag or React Component to finally render the component as. */\n forwardedAs?: ElementType;\n}\n\nexport interface Action extends ForwardProps {\n /** A string to uniquely identify this Action within the onClick handler. */\n id: string;\n /** The text content of the Action. */\n text: string;\n /** The name of the Cosmos Icon to render, if any. */\n icon?: string;\n /** A location to navigate to. Passing an href will render a Link styled as a Button. */\n href?: string;\n /** Called when the Action is clicked. */\n onClick?: (\n id: string,\n e: MouseEvent<HTMLButtonElement | HTMLAnchorElement | HTMLInputElement>,\n /**\n * If the action was rendered as an item in a menu the associated menuButton element will be provided.\n * Often necessary for focus purposes.\n */\n menuButton?: HTMLButtonElement\n ) => void;\n /** Determines if the Action will be disabled. */\n disabled?: boolean;\n}\n\n// https://github.com/microsoft/TypeScript/issues/30825\nexport type OmitStrict<T, K extends keyof T> = Pick<T, Exclude<keyof T, K>>;\nexport type PartialByKey<T extends object, K extends keyof T> = OmitStrict<T, K> &\n Partial<Pick<T, K>>;\nexport type RequiredByKey<T extends object, K extends keyof T> = OmitStrict<T, K> &\n Required<Pick<T, K>>;\n\nexport type DeepPartial<T> = T extends (infer U)[]\n ? DeepPartial<U>[]\n : T extends object\n ? { [K in keyof T]?: DeepPartial<T[K]> }\n : T;\n\nexport type DeepRequired<T> = T extends (infer U)[]\n ? DeepRequired<U>[]\n : T extends Function\n ? T\n : T extends object\n ? { [K in keyof T]-?: DeepRequired<T[K]> }\n : T;\n\nexport type Mutable<T> = {\n -readonly [P in keyof T]: T[P];\n};\n\n// https://stackoverflow.com/a/49725198\nexport type RequireAtLeastOne<T, Keys extends keyof T = keyof T> = Pick<T, Exclude<keyof T, Keys>> &\n {\n [K in Keys]-?: Required<Pick<T, K>> & Partial<Pick<T, Exclude<Keys, K>>>;\n }[Keys];\n\n// Lowers type inference precedence without changing the type.\n// https://github.com/Microsoft/TypeScript/issues/14829#issue-216577598\nexport type DeferInfer<T> = T & { [K in keyof T]: T[K] };\n\n/* eslint-disable @typescript-eslint/ban-types */\nexport type PropsWithDefaults<\n Props extends object = {},\n Defaults extends keyof Props = never\n> = OmitStrict<Props, Defaults> & Required<Pick<Props, Defaults>>;\n/* eslint-enable @typescript-eslint/ban-types */\n\nexport type PrettyPrint<T> = T extends object\n ? {\n [K in keyof T]: T[K];\n }\n : T;\n"]}