@okta/odyssey-react-mui 1.21.2 → 1.23.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 (593) hide show
  1. package/CHANGELOG.md +34 -0
  2. package/dist/@types/i18next.d.js.map +1 -1
  3. package/dist/Autocomplete.js +106 -38
  4. package/dist/Autocomplete.js.map +1 -1
  5. package/dist/Callout.js +12 -24
  6. package/dist/Callout.js.map +1 -1
  7. package/dist/Checkbox.js +26 -11
  8. package/dist/Checkbox.js.map +1 -1
  9. package/dist/CheckboxGroup.js +14 -3
  10. package/dist/CheckboxGroup.js.map +1 -1
  11. package/dist/DataTable/DataTable.js +10 -2
  12. package/dist/DataTable/DataTable.js.map +1 -1
  13. package/dist/DataTable/useScrollIndication.js +9 -5
  14. package/dist/DataTable/useScrollIndication.js.map +1 -1
  15. package/dist/Field.js +3 -1
  16. package/dist/Field.js.map +1 -1
  17. package/dist/FileUploader/FileUploadIllustration.js.map +1 -0
  18. package/dist/FileUploader/FileUploadPreview.js.map +1 -0
  19. package/dist/{labs/FileUpload.js → FileUploader/FileUploader.js} +6 -5
  20. package/dist/FileUploader/FileUploader.js.map +1 -0
  21. package/dist/FileUploader/index.js +13 -0
  22. package/dist/FileUploader/index.js.map +1 -0
  23. package/dist/OdysseyCacheProvider.js +4 -3
  24. package/dist/OdysseyCacheProvider.js.map +1 -1
  25. package/dist/OdysseyProvider.js +10 -3
  26. package/dist/OdysseyProvider.js.map +1 -1
  27. package/dist/OdysseyThemeProvider.js +3 -2
  28. package/dist/OdysseyThemeProvider.js.map +1 -1
  29. package/dist/Radio.js +33 -6
  30. package/dist/Radio.js.map +1 -1
  31. package/dist/RadioGroup.js +17 -5
  32. package/dist/RadioGroup.js.map +1 -1
  33. package/dist/Select.js +89 -31
  34. package/dist/Select.js.map +1 -1
  35. package/dist/{labs/Switch.js → Switch.js} +77 -23
  36. package/dist/Switch.js.map +1 -0
  37. package/dist/Tabs.js +7 -9
  38. package/dist/Tabs.js.map +1 -1
  39. package/dist/Tag.js +102 -4
  40. package/dist/Tag.js.map +1 -1
  41. package/dist/TextField.js +16 -39
  42. package/dist/TextField.js.map +1 -1
  43. package/dist/Toast.js +2 -2
  44. package/dist/Toast.js.map +1 -1
  45. package/dist/ToastStack.js.map +1 -1
  46. package/dist/createShadowDomElements.js +43 -0
  47. package/dist/createShadowDomElements.js.map +1 -0
  48. package/dist/i18n.js +1 -1
  49. package/dist/i18n.js.map +1 -1
  50. package/dist/index.js +3 -2
  51. package/dist/index.js.map +1 -1
  52. package/dist/index.scss +96 -8
  53. package/dist/labs/AppTile.js +124 -0
  54. package/dist/labs/AppTile.js.map +1 -0
  55. package/dist/labs/DataView/BulkActionsMenu.js.map +1 -0
  56. package/dist/labs/{DataComponents/StackContent.js → DataView/CardLayoutContent.js} +14 -14
  57. package/dist/labs/DataView/CardLayoutContent.js.map +1 -0
  58. package/dist/labs/{DataComponents/StackCard.js → DataView/DataCard.js} +6 -6
  59. package/dist/labs/DataView/DataCard.js.map +1 -0
  60. package/dist/labs/{DataComponents → DataView}/DataTable.js +6 -2
  61. package/dist/labs/DataView/DataTable.js.map +1 -0
  62. package/dist/labs/{DataComponents → DataView}/DataView.js +79 -30
  63. package/dist/labs/DataView/DataView.js.map +1 -0
  64. package/dist/labs/DataView/DetailPanel.js.map +1 -0
  65. package/dist/labs/DataView/LayoutSwitcher.js.map +1 -0
  66. package/dist/labs/DataView/RowActions.js.map +1 -0
  67. package/dist/labs/{DataComponents/TableContent.js → DataView/TableLayoutContent.js} +34 -20
  68. package/dist/labs/DataView/TableLayoutContent.js.map +1 -0
  69. package/dist/labs/{DataComponents → DataView}/TableSettings.js +2 -2
  70. package/dist/labs/DataView/TableSettings.js.map +1 -0
  71. package/dist/labs/DataView/componentTypes.js.map +1 -0
  72. package/dist/labs/{DataComponents → DataView}/constants.js +2 -2
  73. package/dist/labs/DataView/constants.js.map +1 -0
  74. package/dist/labs/DataView/dataTypes.js.map +1 -0
  75. package/dist/labs/DataView/fetchData.js.map +1 -0
  76. package/dist/labs/{DataComponents → DataView}/index.js +0 -1
  77. package/dist/labs/DataView/index.js.map +1 -0
  78. package/dist/labs/DataView/tableConstants.js.map +1 -0
  79. package/dist/labs/DataView/useFilterConversion.js.map +1 -0
  80. package/dist/labs/DateField.js +2 -0
  81. package/dist/labs/DateField.js.map +1 -1
  82. package/dist/labs/DatePicker.js +5 -1
  83. package/dist/labs/DatePicker.js.map +1 -1
  84. package/dist/labs/SideNav/CollapseIcon.js +44 -0
  85. package/dist/labs/SideNav/CollapseIcon.js.map +1 -0
  86. package/dist/labs/SideNav/OktaLogo.js +36 -0
  87. package/dist/labs/SideNav/OktaLogo.js.map +1 -0
  88. package/dist/labs/SideNav/SideNav.js +335 -0
  89. package/dist/labs/SideNav/SideNav.js.map +1 -0
  90. package/dist/labs/SideNav/SideNavFooterContent.js +49 -0
  91. package/dist/labs/SideNav/SideNavFooterContent.js.map +1 -0
  92. package/dist/labs/SideNav/SideNavHeader.js +81 -0
  93. package/dist/labs/SideNav/SideNavHeader.js.map +1 -0
  94. package/dist/labs/SideNav/SideNavItemContent.js +157 -0
  95. package/dist/labs/SideNav/SideNavItemContent.js.map +1 -0
  96. package/dist/labs/SideNav/SideNavItemLinkContent.js +71 -0
  97. package/dist/labs/SideNav/SideNavItemLinkContent.js.map +1 -0
  98. package/dist/labs/SideNav/index.js +14 -0
  99. package/dist/labs/SideNav/index.js.map +1 -0
  100. package/dist/labs/SideNav/types.js +2 -0
  101. package/dist/labs/SideNav/types.js.map +1 -0
  102. package/dist/labs/TopNav.js +2 -1
  103. package/dist/labs/TopNav.js.map +1 -1
  104. package/dist/labs/index.js +3 -4
  105. package/dist/labs/index.js.map +1 -1
  106. package/dist/labs/useDateFieldsTranslations.js +1 -1
  107. package/dist/labs/useDateFieldsTranslations.js.map +1 -1
  108. package/dist/properties/ts/odyssey-react-mui.js +3 -1
  109. package/dist/properties/ts/odyssey-react-mui.js.map +1 -1
  110. package/dist/properties/ts/odyssey-react-mui_cs.js +17 -3
  111. package/dist/properties/ts/odyssey-react-mui_cs.js.map +1 -1
  112. package/dist/properties/ts/odyssey-react-mui_da.js +17 -3
  113. package/dist/properties/ts/odyssey-react-mui_da.js.map +1 -1
  114. package/dist/properties/ts/odyssey-react-mui_de.js +16 -2
  115. package/dist/properties/ts/odyssey-react-mui_de.js.map +1 -1
  116. package/dist/properties/ts/odyssey-react-mui_el.js +18 -4
  117. package/dist/properties/ts/odyssey-react-mui_el.js.map +1 -1
  118. package/dist/properties/ts/odyssey-react-mui_es.js +17 -3
  119. package/dist/properties/ts/odyssey-react-mui_es.js.map +1 -1
  120. package/dist/properties/ts/odyssey-react-mui_fi.js +17 -3
  121. package/dist/properties/ts/odyssey-react-mui_fi.js.map +1 -1
  122. package/dist/properties/ts/odyssey-react-mui_fr.js +17 -3
  123. package/dist/properties/ts/odyssey-react-mui_fr.js.map +1 -1
  124. package/dist/properties/ts/odyssey-react-mui_ht.js +18 -4
  125. package/dist/properties/ts/odyssey-react-mui_ht.js.map +1 -1
  126. package/dist/properties/ts/odyssey-react-mui_hu.js +17 -3
  127. package/dist/properties/ts/odyssey-react-mui_hu.js.map +1 -1
  128. package/dist/properties/ts/odyssey-react-mui_id.js +17 -3
  129. package/dist/properties/ts/odyssey-react-mui_id.js.map +1 -1
  130. package/dist/properties/ts/odyssey-react-mui_it.js +17 -3
  131. package/dist/properties/ts/odyssey-react-mui_it.js.map +1 -1
  132. package/dist/properties/ts/odyssey-react-mui_ja.js +16 -2
  133. package/dist/properties/ts/odyssey-react-mui_ja.js.map +1 -1
  134. package/dist/properties/ts/odyssey-react-mui_ko.js +16 -2
  135. package/dist/properties/ts/odyssey-react-mui_ko.js.map +1 -1
  136. package/dist/properties/ts/odyssey-react-mui_ms.js +17 -3
  137. package/dist/properties/ts/odyssey-react-mui_ms.js.map +1 -1
  138. package/dist/properties/ts/odyssey-react-mui_nb.js +17 -3
  139. package/dist/properties/ts/odyssey-react-mui_nb.js.map +1 -1
  140. package/dist/properties/ts/odyssey-react-mui_nl_NL.js +17 -3
  141. package/dist/properties/ts/odyssey-react-mui_nl_NL.js.map +1 -1
  142. package/dist/properties/ts/odyssey-react-mui_pl.js +17 -3
  143. package/dist/properties/ts/odyssey-react-mui_pl.js.map +1 -1
  144. package/dist/properties/ts/odyssey-react-mui_pt_BR.js +17 -3
  145. package/dist/properties/ts/odyssey-react-mui_pt_BR.js.map +1 -1
  146. package/dist/properties/ts/odyssey-react-mui_ro.js +17 -3
  147. package/dist/properties/ts/odyssey-react-mui_ro.js.map +1 -1
  148. package/dist/properties/ts/odyssey-react-mui_ru.js +17 -3
  149. package/dist/properties/ts/odyssey-react-mui_ru.js.map +1 -1
  150. package/dist/properties/ts/odyssey-react-mui_sv.js +17 -3
  151. package/dist/properties/ts/odyssey-react-mui_sv.js.map +1 -1
  152. package/dist/properties/ts/odyssey-react-mui_th.js +16 -2
  153. package/dist/properties/ts/odyssey-react-mui_th.js.map +1 -1
  154. package/dist/properties/ts/odyssey-react-mui_tr.js +17 -3
  155. package/dist/properties/ts/odyssey-react-mui_tr.js.map +1 -1
  156. package/dist/properties/ts/odyssey-react-mui_uk.js +17 -3
  157. package/dist/properties/ts/odyssey-react-mui_uk.js.map +1 -1
  158. package/dist/properties/ts/odyssey-react-mui_vi.js +17 -3
  159. package/dist/properties/ts/odyssey-react-mui_vi.js.map +1 -1
  160. package/dist/properties/ts/odyssey-react-mui_zh_CN.js +16 -2
  161. package/dist/properties/ts/odyssey-react-mui_zh_CN.js.map +1 -1
  162. package/dist/properties/ts/odyssey-react-mui_zh_TW.js +16 -2
  163. package/dist/properties/ts/odyssey-react-mui_zh_TW.js.map +1 -1
  164. package/dist/src/Autocomplete.d.ts +30 -0
  165. package/dist/src/Autocomplete.d.ts.map +1 -1
  166. package/dist/src/Callout.d.ts +11 -23
  167. package/dist/src/Callout.d.ts.map +1 -1
  168. package/dist/src/Checkbox.d.ts +2 -2
  169. package/dist/src/Checkbox.d.ts.map +1 -1
  170. package/dist/src/CheckboxGroup.d.ts +3 -3
  171. package/dist/src/CheckboxGroup.d.ts.map +1 -1
  172. package/dist/src/DataTable/DataTable.d.ts +9 -1
  173. package/dist/src/DataTable/DataTable.d.ts.map +1 -1
  174. package/dist/src/DataTable/useScrollIndication.d.ts.map +1 -1
  175. package/dist/src/Field.d.ts +3 -2
  176. package/dist/src/Field.d.ts.map +1 -1
  177. package/dist/src/FileUploader/FileUploadIllustration.d.ts.map +1 -0
  178. package/dist/src/{labs → FileUploader}/FileUploadPreview.d.ts +2 -2
  179. package/dist/src/FileUploader/FileUploadPreview.d.ts.map +1 -0
  180. package/dist/src/{labs/FileUpload.d.ts → FileUploader/FileUploader.d.ts} +5 -4
  181. package/dist/src/FileUploader/FileUploader.d.ts.map +1 -0
  182. package/dist/src/FileUploader/index.d.ts +13 -0
  183. package/dist/src/FileUploader/index.d.ts.map +1 -0
  184. package/dist/src/NativeSelect.d.ts +1 -1
  185. package/dist/src/OdysseyCacheProvider.d.ts +7 -3
  186. package/dist/src/OdysseyCacheProvider.d.ts.map +1 -1
  187. package/dist/src/OdysseyProvider.d.ts +1 -1
  188. package/dist/src/OdysseyProvider.d.ts.map +1 -1
  189. package/dist/src/OdysseyThemeProvider.d.ts +3 -1
  190. package/dist/src/OdysseyThemeProvider.d.ts.map +1 -1
  191. package/dist/src/OdysseyTranslationProvider.d.ts +1 -1
  192. package/dist/src/OdysseyTranslationProvider.d.ts.map +1 -1
  193. package/dist/src/PasswordField.d.ts +1 -1
  194. package/dist/src/Radio.d.ts +6 -8
  195. package/dist/src/Radio.d.ts.map +1 -1
  196. package/dist/src/RadioGroup.d.ts +4 -5
  197. package/dist/src/RadioGroup.d.ts.map +1 -1
  198. package/dist/src/SearchField.d.ts +1 -1
  199. package/dist/src/Select.d.ts +38 -2
  200. package/dist/src/Select.d.ts.map +1 -1
  201. package/dist/src/{labs/Switch.d.ts → Switch.d.ts} +8 -4
  202. package/dist/src/Switch.d.ts.map +1 -0
  203. package/dist/src/Tabs.d.ts +6 -8
  204. package/dist/src/Tabs.d.ts.map +1 -1
  205. package/dist/src/Tag.d.ts +7 -1
  206. package/dist/src/Tag.d.ts.map +1 -1
  207. package/dist/src/TextField.d.ts +17 -40
  208. package/dist/src/TextField.d.ts.map +1 -1
  209. package/dist/src/ToastStack.d.ts +2 -2
  210. package/dist/src/ToastStack.d.ts.map +1 -1
  211. package/dist/src/{createShadowRootElement.d.ts → createShadowDomElements.d.ts} +6 -1
  212. package/dist/src/createShadowDomElements.d.ts.map +1 -0
  213. package/dist/src/i18n.d.ts +2 -2
  214. package/dist/src/i18n.d.ts.map +1 -1
  215. package/dist/src/index.d.ts +3 -2
  216. package/dist/src/index.d.ts.map +1 -1
  217. package/dist/src/labs/AppTile.d.ts +39 -0
  218. package/dist/src/labs/AppTile.d.ts.map +1 -0
  219. package/dist/src/labs/DataView/BulkActionsMenu.d.ts.map +1 -0
  220. package/dist/src/labs/{DataComponents/StackContent.d.ts → DataView/CardLayoutContent.d.ts} +7 -7
  221. package/dist/src/labs/DataView/CardLayoutContent.d.ts.map +1 -0
  222. package/dist/src/labs/{DataComponents/StackCard.d.ts → DataView/DataCard.d.ts} +4 -4
  223. package/dist/src/labs/DataView/DataCard.d.ts.map +1 -0
  224. package/dist/src/labs/DataView/DataTable.d.ts +16 -0
  225. package/dist/src/labs/DataView/DataTable.d.ts.map +1 -0
  226. package/dist/src/labs/{DataComponents → DataView}/DataView.d.ts +1 -1
  227. package/dist/src/labs/DataView/DataView.d.ts.map +1 -0
  228. package/dist/src/labs/{DataComponents → DataView}/DetailPanel.d.ts +2 -2
  229. package/dist/src/labs/DataView/DetailPanel.d.ts.map +1 -0
  230. package/dist/src/labs/DataView/LayoutSwitcher.d.ts.map +1 -0
  231. package/dist/src/labs/DataView/RowActions.d.ts.map +1 -0
  232. package/dist/src/labs/{DataComponents/TableContent.d.ts → DataView/TableLayoutContent.d.ts} +8 -7
  233. package/dist/src/labs/DataView/TableLayoutContent.d.ts.map +1 -0
  234. package/dist/src/labs/{DataComponents → DataView}/TableSettings.d.ts +3 -3
  235. package/dist/src/labs/DataView/TableSettings.d.ts.map +1 -0
  236. package/dist/src/labs/{DataComponents → DataView}/componentTypes.d.ts +21 -9
  237. package/dist/src/labs/DataView/componentTypes.d.ts.map +1 -0
  238. package/dist/src/labs/{DataComponents → DataView}/constants.d.ts +1 -1
  239. package/dist/src/labs/DataView/constants.d.ts.map +1 -0
  240. package/dist/src/labs/DataView/dataTypes.d.ts.map +1 -0
  241. package/dist/src/labs/DataView/fetchData.d.ts.map +1 -0
  242. package/dist/src/labs/{DataComponents → DataView}/index.d.ts +0 -1
  243. package/dist/src/labs/DataView/index.d.ts.map +1 -0
  244. package/dist/src/labs/DataView/tableConstants.d.ts.map +1 -0
  245. package/dist/src/labs/{DataComponents → DataView}/useFilterConversion.d.ts +2 -2
  246. package/dist/src/labs/DataView/useFilterConversion.d.ts.map +1 -0
  247. package/dist/src/labs/DateField.d.ts +2 -2
  248. package/dist/src/labs/DateField.d.ts.map +1 -1
  249. package/dist/src/labs/DatePicker.d.ts +2 -2
  250. package/dist/src/labs/DatePicker.d.ts.map +1 -1
  251. package/dist/src/labs/SideNav/CollapseIcon.d.ts +17 -0
  252. package/dist/src/labs/SideNav/CollapseIcon.d.ts.map +1 -0
  253. package/dist/src/labs/SideNav/OktaLogo.d.ts +14 -0
  254. package/dist/src/labs/SideNav/OktaLogo.d.ts.map +1 -0
  255. package/dist/src/labs/SideNav/SideNav.d.ts +16 -0
  256. package/dist/src/labs/SideNav/SideNav.d.ts.map +1 -0
  257. package/dist/{test-selectors/odysseyTestSelectors.js → src/labs/SideNav/SideNavFooterContent.d.ts} +6 -9
  258. package/dist/src/labs/SideNav/SideNavFooterContent.d.ts.map +1 -0
  259. package/dist/src/labs/SideNav/SideNavHeader.d.ts +16 -0
  260. package/dist/src/labs/SideNav/SideNavHeader.d.ts.map +1 -0
  261. package/dist/src/labs/SideNav/SideNavItemContent.d.ts +33 -0
  262. package/dist/src/labs/SideNav/SideNavItemContent.d.ts.map +1 -0
  263. package/dist/src/labs/SideNav/SideNavItemLinkContent.d.ts +16 -0
  264. package/dist/src/labs/SideNav/SideNavItemLinkContent.d.ts.map +1 -0
  265. package/dist/src/labs/SideNav/index.d.ts +14 -0
  266. package/dist/src/labs/SideNav/index.d.ts.map +1 -0
  267. package/dist/src/labs/{SideNav.d.ts → SideNav/types.d.ts} +54 -33
  268. package/dist/src/labs/SideNav/types.d.ts.map +1 -0
  269. package/dist/src/labs/TopNav.d.ts +1 -0
  270. package/dist/src/labs/TopNav.d.ts.map +1 -1
  271. package/dist/src/labs/index.d.ts +2 -3
  272. package/dist/src/labs/index.d.ts.map +1 -1
  273. package/dist/src/properties/ts/odyssey-react-mui.d.ts +2 -0
  274. package/dist/src/properties/ts/odyssey-react-mui.d.ts.map +1 -1
  275. package/dist/src/properties/ts/odyssey-react-mui_cs.d.ts +15 -1
  276. package/dist/src/properties/ts/odyssey-react-mui_cs.d.ts.map +1 -1
  277. package/dist/src/properties/ts/odyssey-react-mui_da.d.ts +15 -1
  278. package/dist/src/properties/ts/odyssey-react-mui_da.d.ts.map +1 -1
  279. package/dist/src/properties/ts/odyssey-react-mui_de.d.ts +15 -1
  280. package/dist/src/properties/ts/odyssey-react-mui_de.d.ts.map +1 -1
  281. package/dist/src/properties/ts/odyssey-react-mui_el.d.ts +15 -1
  282. package/dist/src/properties/ts/odyssey-react-mui_el.d.ts.map +1 -1
  283. package/dist/src/properties/ts/odyssey-react-mui_es.d.ts +15 -1
  284. package/dist/src/properties/ts/odyssey-react-mui_es.d.ts.map +1 -1
  285. package/dist/src/properties/ts/odyssey-react-mui_fi.d.ts +15 -1
  286. package/dist/src/properties/ts/odyssey-react-mui_fi.d.ts.map +1 -1
  287. package/dist/src/properties/ts/odyssey-react-mui_fr.d.ts +15 -1
  288. package/dist/src/properties/ts/odyssey-react-mui_fr.d.ts.map +1 -1
  289. package/dist/src/properties/ts/odyssey-react-mui_ht.d.ts +16 -2
  290. package/dist/src/properties/ts/odyssey-react-mui_ht.d.ts.map +1 -1
  291. package/dist/src/properties/ts/odyssey-react-mui_hu.d.ts +15 -1
  292. package/dist/src/properties/ts/odyssey-react-mui_hu.d.ts.map +1 -1
  293. package/dist/src/properties/ts/odyssey-react-mui_id.d.ts +15 -1
  294. package/dist/src/properties/ts/odyssey-react-mui_id.d.ts.map +1 -1
  295. package/dist/src/properties/ts/odyssey-react-mui_it.d.ts +15 -1
  296. package/dist/src/properties/ts/odyssey-react-mui_it.d.ts.map +1 -1
  297. package/dist/src/properties/ts/odyssey-react-mui_ja.d.ts +15 -1
  298. package/dist/src/properties/ts/odyssey-react-mui_ja.d.ts.map +1 -1
  299. package/dist/src/properties/ts/odyssey-react-mui_ko.d.ts +15 -1
  300. package/dist/src/properties/ts/odyssey-react-mui_ko.d.ts.map +1 -1
  301. package/dist/src/properties/ts/odyssey-react-mui_ms.d.ts +15 -1
  302. package/dist/src/properties/ts/odyssey-react-mui_ms.d.ts.map +1 -1
  303. package/dist/src/properties/ts/odyssey-react-mui_nb.d.ts +15 -1
  304. package/dist/src/properties/ts/odyssey-react-mui_nb.d.ts.map +1 -1
  305. package/dist/src/properties/ts/odyssey-react-mui_nl_NL.d.ts +15 -1
  306. package/dist/src/properties/ts/odyssey-react-mui_nl_NL.d.ts.map +1 -1
  307. package/dist/src/properties/ts/odyssey-react-mui_pl.d.ts +15 -1
  308. package/dist/src/properties/ts/odyssey-react-mui_pl.d.ts.map +1 -1
  309. package/dist/src/properties/ts/odyssey-react-mui_pt_BR.d.ts +15 -1
  310. package/dist/src/properties/ts/odyssey-react-mui_pt_BR.d.ts.map +1 -1
  311. package/dist/src/properties/ts/odyssey-react-mui_ro.d.ts +15 -1
  312. package/dist/src/properties/ts/odyssey-react-mui_ro.d.ts.map +1 -1
  313. package/dist/src/properties/ts/odyssey-react-mui_ru.d.ts +15 -1
  314. package/dist/src/properties/ts/odyssey-react-mui_ru.d.ts.map +1 -1
  315. package/dist/src/properties/ts/odyssey-react-mui_sv.d.ts +15 -1
  316. package/dist/src/properties/ts/odyssey-react-mui_sv.d.ts.map +1 -1
  317. package/dist/src/properties/ts/odyssey-react-mui_th.d.ts +15 -1
  318. package/dist/src/properties/ts/odyssey-react-mui_th.d.ts.map +1 -1
  319. package/dist/src/properties/ts/odyssey-react-mui_tr.d.ts +15 -1
  320. package/dist/src/properties/ts/odyssey-react-mui_tr.d.ts.map +1 -1
  321. package/dist/src/properties/ts/odyssey-react-mui_uk.d.ts +15 -1
  322. package/dist/src/properties/ts/odyssey-react-mui_uk.d.ts.map +1 -1
  323. package/dist/src/properties/ts/odyssey-react-mui_vi.d.ts +15 -1
  324. package/dist/src/properties/ts/odyssey-react-mui_vi.d.ts.map +1 -1
  325. package/dist/src/properties/ts/odyssey-react-mui_zh_CN.d.ts +15 -1
  326. package/dist/src/properties/ts/odyssey-react-mui_zh_CN.d.ts.map +1 -1
  327. package/dist/src/properties/ts/odyssey-react-mui_zh_TW.d.ts +15 -1
  328. package/dist/src/properties/ts/odyssey-react-mui_zh_TW.d.ts.map +1 -1
  329. package/dist/src/test-selectors/getByQuerySelector.d.ts +148 -0
  330. package/dist/src/test-selectors/getByQuerySelector.d.ts.map +1 -0
  331. package/dist/src/test-selectors/getComputedAccessibleErrorMessageText.d.ts +14 -0
  332. package/dist/src/test-selectors/getComputedAccessibleErrorMessageText.d.ts.map +1 -0
  333. package/dist/src/test-selectors/getComputedAccessibleText.d.ts +23 -0
  334. package/dist/src/test-selectors/getComputedAccessibleText.d.ts.map +1 -0
  335. package/dist/src/test-selectors/index.d.ts +2 -2
  336. package/dist/src/test-selectors/index.d.ts.map +1 -1
  337. package/{src/test-selectors/odysseyTestSelectors.ts → dist/src/test-selectors/interpolateString.d.ts} +4 -11
  338. package/dist/src/test-selectors/interpolateString.d.ts.map +1 -0
  339. package/dist/src/test-selectors/linkedHtmlSelectors.d.ts +24 -0
  340. package/dist/src/test-selectors/linkedHtmlSelectors.d.ts.map +1 -0
  341. package/dist/src/test-selectors/queryOdysseySelector.d.ts +5755 -0
  342. package/dist/src/test-selectors/queryOdysseySelector.d.ts.map +1 -0
  343. package/dist/src/test-selectors/querySelector.d.ts +59 -3613
  344. package/dist/src/test-selectors/querySelector.d.ts.map +1 -1
  345. package/dist/src/test-selectors/sanityChecks.d.ts +18 -0
  346. package/dist/src/test-selectors/sanityChecks.d.ts.map +1 -0
  347. package/dist/src/test-selectors/testSelector.d.ts +46 -0
  348. package/dist/src/test-selectors/testSelector.d.ts.map +1 -0
  349. package/dist/src/theme/components.d.ts +3 -1
  350. package/dist/src/theme/components.d.ts.map +1 -1
  351. package/dist/src/theme/createOdysseyMuiTheme.d.ts +3 -1
  352. package/dist/src/theme/createOdysseyMuiTheme.d.ts.map +1 -1
  353. package/dist/test-selectors/getByQuerySelector.js +64 -0
  354. package/dist/test-selectors/getByQuerySelector.js.map +1 -0
  355. package/dist/test-selectors/getComputedAccessibleErrorMessageText.js +25 -0
  356. package/dist/test-selectors/getComputedAccessibleErrorMessageText.js.map +1 -0
  357. package/dist/test-selectors/getComputedAccessibleText.js +24 -0
  358. package/dist/test-selectors/getComputedAccessibleText.js.map +1 -0
  359. package/dist/test-selectors/index.js +2 -2
  360. package/dist/test-selectors/index.js.map +1 -1
  361. package/dist/test-selectors/interpolateString.js +25 -0
  362. package/dist/test-selectors/interpolateString.js.map +1 -0
  363. package/dist/test-selectors/linkedHtmlSelectors.js +34 -0
  364. package/dist/test-selectors/linkedHtmlSelectors.js.map +1 -0
  365. package/dist/test-selectors/queryOdysseySelector.js +26 -0
  366. package/dist/test-selectors/queryOdysseySelector.js.map +1 -0
  367. package/dist/test-selectors/querySelector.js +82 -58
  368. package/dist/test-selectors/querySelector.js.map +1 -1
  369. package/dist/test-selectors/sanityChecks.js +33 -0
  370. package/dist/test-selectors/sanityChecks.js.map +1 -0
  371. package/dist/test-selectors/testSelector.js +2 -0
  372. package/dist/test-selectors/testSelector.js.map +1 -0
  373. package/dist/test-selectors/testSelectors.json +1 -1
  374. package/dist/theme/components.js +231 -146
  375. package/dist/theme/components.js.map +1 -1
  376. package/dist/theme/createOdysseyMuiTheme.js +3 -2
  377. package/dist/theme/createOdysseyMuiTheme.js.map +1 -1
  378. package/dist/tsconfig.production.tsbuildinfo +1 -1
  379. package/dist/tsconfig.tsbuildinfo +1 -1
  380. package/jest.setup.js +3 -0
  381. package/package.json +5 -5
  382. package/scripts/generateTestSelectorsJson.ts +1 -1
  383. package/src/@types/i18next.d.ts +1 -1
  384. package/src/Autocomplete.tsx +140 -45
  385. package/src/Callout.tsx +13 -25
  386. package/src/Checkbox.tsx +39 -9
  387. package/src/CheckboxGroup.tsx +20 -4
  388. package/src/DataTable/DataTable.tsx +24 -1
  389. package/src/DataTable/useScrollIndication.tsx +11 -4
  390. package/src/Field.tsx +5 -2
  391. package/src/{labs → FileUploader}/FileUploadPreview.tsx +3 -3
  392. package/src/{labs/FileUpload.tsx → FileUploader/FileUploader.tsx} +7 -6
  393. package/src/FileUploader/index.ts +13 -0
  394. package/src/OdysseyCacheProvider.test.tsx +1 -0
  395. package/src/OdysseyCacheProvider.tsx +18 -4
  396. package/src/OdysseyProvider.tsx +12 -4
  397. package/src/OdysseyThemeProvider.tsx +6 -2
  398. package/src/Radio.tsx +41 -12
  399. package/src/RadioGroup.tsx +26 -7
  400. package/src/Select.tsx +116 -45
  401. package/src/{labs/Switch.tsx → Switch.tsx} +95 -41
  402. package/src/Tabs.tsx +8 -10
  403. package/src/Tag.tsx +134 -3
  404. package/src/TextField.tsx +18 -41
  405. package/src/Toast.tsx +1 -1
  406. package/src/ToastStack.tsx +2 -2
  407. package/src/createShadowDomElements.ts +53 -0
  408. package/src/i18n.ts +3 -3
  409. package/src/index.ts +7 -2
  410. package/src/labs/AppTile.tsx +200 -0
  411. package/src/labs/{DataComponents/StackContent.tsx → DataView/CardLayoutContent.tsx} +24 -19
  412. package/src/labs/{DataComponents/StackCard.tsx → DataView/DataCard.tsx} +7 -7
  413. package/src/labs/{DataComponents → DataView}/DataTable.tsx +8 -4
  414. package/src/labs/DataView/DataView.test.tsx +158 -0
  415. package/src/labs/{DataComponents → DataView}/DataView.tsx +119 -42
  416. package/src/labs/{DataComponents → DataView}/DetailPanel.tsx +2 -2
  417. package/src/labs/{DataComponents/TableContent.tsx → DataView/TableLayoutContent.tsx} +59 -27
  418. package/src/labs/{DataComponents → DataView}/TableSettings.tsx +5 -4
  419. package/src/labs/{DataComponents → DataView}/componentTypes.ts +24 -9
  420. package/src/labs/{DataComponents → DataView}/constants.tsx +2 -2
  421. package/src/labs/{DataComponents → DataView}/index.tsx +0 -1
  422. package/src/labs/{DataComponents → DataView}/useFilterConversion.ts +2 -2
  423. package/src/labs/DateField.tsx +3 -0
  424. package/src/labs/DatePicker.tsx +12 -1
  425. package/src/labs/SideNav/CollapseIcon.tsx +48 -0
  426. package/src/labs/SideNav/OktaLogo.tsx +39 -0
  427. package/src/labs/SideNav/SideNav.tsx +486 -0
  428. package/src/labs/SideNav/SideNavFooterContent.tsx +64 -0
  429. package/src/labs/SideNav/SideNavHeader.tsx +88 -0
  430. package/src/labs/SideNav/SideNavItemContent.tsx +216 -0
  431. package/src/labs/SideNav/SideNavItemLinkContent.tsx +87 -0
  432. package/src/labs/SideNav/index.ts +15 -0
  433. package/src/labs/SideNav/types.ts +152 -0
  434. package/src/labs/TopNav.tsx +3 -1
  435. package/src/labs/index.ts +3 -4
  436. package/src/labs/useDateFieldsTranslations.ts +1 -1
  437. package/src/properties/odyssey-react-mui.properties +2 -1
  438. package/src/properties/translations/odyssey-react-mui_cs.properties +15 -3
  439. package/src/properties/translations/odyssey-react-mui_da.properties +15 -3
  440. package/src/properties/translations/odyssey-react-mui_de.properties +14 -2
  441. package/src/properties/translations/odyssey-react-mui_el.properties +16 -4
  442. package/src/properties/translations/odyssey-react-mui_es.properties +15 -3
  443. package/src/properties/translations/odyssey-react-mui_fi.properties +15 -3
  444. package/src/properties/translations/odyssey-react-mui_fr.properties +15 -3
  445. package/src/properties/translations/odyssey-react-mui_ht.properties +17 -6
  446. package/src/properties/translations/odyssey-react-mui_hu.properties +15 -3
  447. package/src/properties/translations/odyssey-react-mui_id.properties +15 -3
  448. package/src/properties/translations/odyssey-react-mui_it.properties +15 -3
  449. package/src/properties/translations/odyssey-react-mui_ja.properties +14 -2
  450. package/src/properties/translations/odyssey-react-mui_ko.properties +14 -2
  451. package/src/properties/translations/odyssey-react-mui_ms.properties +15 -3
  452. package/src/properties/translations/odyssey-react-mui_nb.properties +15 -3
  453. package/src/properties/translations/odyssey-react-mui_nl_NL.properties +15 -3
  454. package/src/properties/translations/odyssey-react-mui_pl.properties +15 -3
  455. package/src/properties/translations/odyssey-react-mui_pt_BR.properties +15 -3
  456. package/src/properties/translations/odyssey-react-mui_ro.properties +15 -3
  457. package/src/properties/translations/odyssey-react-mui_ru.properties +15 -3
  458. package/src/properties/translations/odyssey-react-mui_sv.properties +15 -3
  459. package/src/properties/translations/odyssey-react-mui_th.properties +14 -2
  460. package/src/properties/translations/odyssey-react-mui_tr.properties +15 -3
  461. package/src/properties/translations/odyssey-react-mui_uk.properties +15 -3
  462. package/src/properties/translations/odyssey-react-mui_vi.properties +15 -3
  463. package/src/properties/translations/odyssey-react-mui_zh_CN.properties +14 -2
  464. package/src/properties/translations/odyssey-react-mui_zh_TW.properties +14 -2
  465. package/src/properties/ts/odyssey-react-mui.ts +1 -1
  466. package/src/properties/ts/odyssey-react-mui_cs.ts +1 -1
  467. package/src/properties/ts/odyssey-react-mui_da.ts +1 -1
  468. package/src/properties/ts/odyssey-react-mui_de.ts +1 -1
  469. package/src/properties/ts/odyssey-react-mui_el.ts +1 -1
  470. package/src/properties/ts/odyssey-react-mui_es.ts +1 -1
  471. package/src/properties/ts/odyssey-react-mui_fi.ts +1 -1
  472. package/src/properties/ts/odyssey-react-mui_fr.ts +1 -1
  473. package/src/properties/ts/odyssey-react-mui_ht.ts +1 -1
  474. package/src/properties/ts/odyssey-react-mui_hu.ts +1 -1
  475. package/src/properties/ts/odyssey-react-mui_id.ts +1 -1
  476. package/src/properties/ts/odyssey-react-mui_it.ts +1 -1
  477. package/src/properties/ts/odyssey-react-mui_ja.ts +1 -1
  478. package/src/properties/ts/odyssey-react-mui_ko.ts +1 -1
  479. package/src/properties/ts/odyssey-react-mui_ms.ts +1 -1
  480. package/src/properties/ts/odyssey-react-mui_nb.ts +1 -1
  481. package/src/properties/ts/odyssey-react-mui_nl_NL.ts +1 -1
  482. package/src/properties/ts/odyssey-react-mui_pl.ts +1 -1
  483. package/src/properties/ts/odyssey-react-mui_pt_BR.ts +1 -1
  484. package/src/properties/ts/odyssey-react-mui_ro.ts +1 -1
  485. package/src/properties/ts/odyssey-react-mui_ru.ts +1 -1
  486. package/src/properties/ts/odyssey-react-mui_sv.ts +1 -1
  487. package/src/properties/ts/odyssey-react-mui_th.ts +1 -1
  488. package/src/properties/ts/odyssey-react-mui_tr.ts +1 -1
  489. package/src/properties/ts/odyssey-react-mui_uk.ts +1 -1
  490. package/src/properties/ts/odyssey-react-mui_vi.ts +1 -1
  491. package/src/properties/ts/odyssey-react-mui_zh_CN.ts +1 -1
  492. package/src/properties/ts/odyssey-react-mui_zh_TW.ts +1 -1
  493. package/src/test-selectors/getByQuerySelector.ts +176 -0
  494. package/src/test-selectors/getComputedAccessibleErrorMessageText.ts +52 -0
  495. package/src/test-selectors/getComputedAccessibleText.ts +36 -0
  496. package/src/test-selectors/index.ts +2 -2
  497. package/src/test-selectors/interpolateString.ts +41 -0
  498. package/src/test-selectors/linkedHtmlSelectors.ts +73 -0
  499. package/src/test-selectors/queryOdysseySelector.ts +36 -0
  500. package/src/test-selectors/querySelector.ts +221 -170
  501. package/src/test-selectors/sanityChecks.ts +53 -0
  502. package/src/test-selectors/testSelector.ts +143 -0
  503. package/src/theme/components.tsx +238 -150
  504. package/src/theme/createOdysseyMuiTheme.ts +4 -1
  505. package/dist/createShadowRootElement.js +0 -26
  506. package/dist/createShadowRootElement.js.map +0 -1
  507. package/dist/labs/DataComponents/BulkActionsMenu.js.map +0 -1
  508. package/dist/labs/DataComponents/DataStack.js +0 -85
  509. package/dist/labs/DataComponents/DataStack.js.map +0 -1
  510. package/dist/labs/DataComponents/DataTable.js.map +0 -1
  511. package/dist/labs/DataComponents/DataView.js.map +0 -1
  512. package/dist/labs/DataComponents/DetailPanel.js.map +0 -1
  513. package/dist/labs/DataComponents/LayoutSwitcher.js.map +0 -1
  514. package/dist/labs/DataComponents/RowActions.js.map +0 -1
  515. package/dist/labs/DataComponents/StackCard.js.map +0 -1
  516. package/dist/labs/DataComponents/StackContent.js.map +0 -1
  517. package/dist/labs/DataComponents/TableContent.js.map +0 -1
  518. package/dist/labs/DataComponents/TableSettings.js.map +0 -1
  519. package/dist/labs/DataComponents/componentTypes.js.map +0 -1
  520. package/dist/labs/DataComponents/constants.js.map +0 -1
  521. package/dist/labs/DataComponents/dataTypes.js.map +0 -1
  522. package/dist/labs/DataComponents/fetchData.js.map +0 -1
  523. package/dist/labs/DataComponents/index.js.map +0 -1
  524. package/dist/labs/DataComponents/tableConstants.js.map +0 -1
  525. package/dist/labs/DataComponents/useFilterConversion.js.map +0 -1
  526. package/dist/labs/FileUpload.js.map +0 -1
  527. package/dist/labs/FileUploadIllustration.js.map +0 -1
  528. package/dist/labs/FileUploadPreview.js.map +0 -1
  529. package/dist/labs/SideNav.js +0 -478
  530. package/dist/labs/SideNav.js.map +0 -1
  531. package/dist/labs/Switch.js.map +0 -1
  532. package/dist/src/createShadowRootElement.d.ts.map +0 -1
  533. package/dist/src/labs/DataComponents/BulkActionsMenu.d.ts.map +0 -1
  534. package/dist/src/labs/DataComponents/DataStack.d.ts +0 -20
  535. package/dist/src/labs/DataComponents/DataStack.d.ts.map +0 -1
  536. package/dist/src/labs/DataComponents/DataTable.d.ts +0 -16
  537. package/dist/src/labs/DataComponents/DataTable.d.ts.map +0 -1
  538. package/dist/src/labs/DataComponents/DataView.d.ts.map +0 -1
  539. package/dist/src/labs/DataComponents/DetailPanel.d.ts.map +0 -1
  540. package/dist/src/labs/DataComponents/LayoutSwitcher.d.ts.map +0 -1
  541. package/dist/src/labs/DataComponents/RowActions.d.ts.map +0 -1
  542. package/dist/src/labs/DataComponents/StackCard.d.ts.map +0 -1
  543. package/dist/src/labs/DataComponents/StackContent.d.ts.map +0 -1
  544. package/dist/src/labs/DataComponents/TableContent.d.ts.map +0 -1
  545. package/dist/src/labs/DataComponents/TableSettings.d.ts.map +0 -1
  546. package/dist/src/labs/DataComponents/componentTypes.d.ts.map +0 -1
  547. package/dist/src/labs/DataComponents/constants.d.ts.map +0 -1
  548. package/dist/src/labs/DataComponents/dataTypes.d.ts.map +0 -1
  549. package/dist/src/labs/DataComponents/fetchData.d.ts.map +0 -1
  550. package/dist/src/labs/DataComponents/index.d.ts.map +0 -1
  551. package/dist/src/labs/DataComponents/tableConstants.d.ts.map +0 -1
  552. package/dist/src/labs/DataComponents/useFilterConversion.d.ts.map +0 -1
  553. package/dist/src/labs/FileUpload.d.ts.map +0 -1
  554. package/dist/src/labs/FileUploadIllustration.d.ts.map +0 -1
  555. package/dist/src/labs/FileUploadPreview.d.ts.map +0 -1
  556. package/dist/src/labs/SideNav.d.ts.map +0 -1
  557. package/dist/src/labs/Switch.d.ts.map +0 -1
  558. package/dist/src/test-selectors/featureTestSelector.d.ts +0 -31
  559. package/dist/src/test-selectors/featureTestSelector.d.ts.map +0 -1
  560. package/dist/src/test-selectors/odysseyTestSelectors.d.ts +0 -120
  561. package/dist/src/test-selectors/odysseyTestSelectors.d.ts.map +0 -1
  562. package/dist/test-selectors/featureTestSelector.js +0 -2
  563. package/dist/test-selectors/featureTestSelector.js.map +0 -1
  564. package/dist/test-selectors/odysseyTestSelectors.js.map +0 -1
  565. package/src/createShadowRootElement.ts +0 -31
  566. package/src/labs/DataComponents/DataStack.tsx +0 -105
  567. package/src/labs/SideNav.tsx +0 -745
  568. package/src/test-selectors/featureTestSelector.ts +0 -41
  569. /package/dist/{labs → FileUploader}/FileUploadIllustration.js +0 -0
  570. /package/dist/{labs → FileUploader}/FileUploadPreview.js +0 -0
  571. /package/dist/labs/{DataComponents → DataView}/BulkActionsMenu.js +0 -0
  572. /package/dist/labs/{DataComponents → DataView}/DetailPanel.js +0 -0
  573. /package/dist/labs/{DataComponents → DataView}/LayoutSwitcher.js +0 -0
  574. /package/dist/labs/{DataComponents → DataView}/RowActions.js +0 -0
  575. /package/dist/labs/{DataComponents → DataView}/componentTypes.js +0 -0
  576. /package/dist/labs/{DataComponents → DataView}/dataTypes.js +0 -0
  577. /package/dist/labs/{DataComponents → DataView}/fetchData.js +0 -0
  578. /package/dist/labs/{DataComponents → DataView}/tableConstants.js +0 -0
  579. /package/dist/labs/{DataComponents → DataView}/useFilterConversion.js +0 -0
  580. /package/dist/src/{labs → FileUploader}/FileUploadIllustration.d.ts +0 -0
  581. /package/dist/src/labs/{DataComponents → DataView}/BulkActionsMenu.d.ts +0 -0
  582. /package/dist/src/labs/{DataComponents → DataView}/LayoutSwitcher.d.ts +0 -0
  583. /package/dist/src/labs/{DataComponents → DataView}/RowActions.d.ts +0 -0
  584. /package/dist/src/labs/{DataComponents → DataView}/dataTypes.d.ts +0 -0
  585. /package/dist/src/labs/{DataComponents → DataView}/fetchData.d.ts +0 -0
  586. /package/dist/src/labs/{DataComponents → DataView}/tableConstants.d.ts +0 -0
  587. /package/src/{labs → FileUploader}/FileUploadIllustration.tsx +0 -0
  588. /package/src/labs/{DataComponents → DataView}/BulkActionsMenu.tsx +0 -0
  589. /package/src/labs/{DataComponents → DataView}/LayoutSwitcher.tsx +0 -0
  590. /package/src/labs/{DataComponents → DataView}/RowActions.tsx +0 -0
  591. /package/src/labs/{DataComponents → DataView}/dataTypes.ts +0 -0
  592. /package/src/labs/{DataComponents → DataView}/fetchData.ts +0 -0
  593. /package/src/labs/{DataComponents → DataView}/tableConstants.tsx +0 -0
@@ -0,0 +1,157 @@
1
+ /*!
2
+ * Copyright (c) 2024-present, Okta, Inc. and/or its affiliates. All rights reserved.
3
+ * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the "License.")
4
+ *
5
+ * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.
6
+ * Unless required by applicable law or agreed to in writing, software
7
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
8
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
9
+ *
10
+ * See the License for the specific language governing permissions and limitations under the License.
11
+ */
12
+
13
+ import styled from "@emotion/styled";
14
+ import { useRef, useImperativeHandle, useCallback, memo } from "react";
15
+ import { Link } from "../../Link.js";
16
+ import { useOdysseyDesignTokens } from "../../OdysseyDesignTokensContext.js";
17
+ import { SideNavItemLinkContent } from "./SideNavItemLinkContent.js";
18
+ import { jsx as _jsx } from "react/jsx-runtime";
19
+ export const SideNavListItemContainer = styled("li", {
20
+ shouldForwardProp: prop => prop !== "odysseyDesignTokens" && prop !== "isSelected" && prop !== "isDisabled"
21
+ })(({
22
+ odysseyDesignTokens,
23
+ isSelected,
24
+ isDisabled
25
+ }) => ({
26
+ display: "flex",
27
+ alignItems: "center",
28
+ cursor: isDisabled ? "default" : "pointer",
29
+ pointerEvents: isDisabled ? "none" : "auto",
30
+ backgroundColor: isSelected ? odysseyDesignTokens.HueNeutral50 : "unset",
31
+ margin: `${odysseyDesignTokens.Spacing1} 0`,
32
+ "&:last-child": {
33
+ marginBottom: odysseyDesignTokens.Spacing2
34
+ },
35
+ "& a": {
36
+ display: "flex",
37
+ alignItems: "center",
38
+ width: "100%",
39
+ minHeight: "48px",
40
+ padding: `${odysseyDesignTokens.Spacing3} ${odysseyDesignTokens.Spacing4}`,
41
+ color: `${odysseyDesignTokens.TypographyColorHeading} !important`,
42
+ pointerEvents: isDisabled ? "none" : "auto"
43
+ },
44
+ "& a:hover": {
45
+ textDecoration: "none",
46
+ cursor: isDisabled ? "default" : "pointer",
47
+ backgroundColor: !isDisabled ? odysseyDesignTokens.HueNeutral50 : "inherit"
48
+ },
49
+ "& a:focus-visible": {
50
+ outlineOffset: 0,
51
+ borderRadius: 0,
52
+ outlineWidth: odysseyDesignTokens.FocusOutlineWidthMain,
53
+ backgroundColor: !isDisabled ? odysseyDesignTokens.HueNeutral50 : "inherit"
54
+ }
55
+ }));
56
+ const scrollToNode = node => {
57
+ if (node) {
58
+ node?.scrollIntoView({
59
+ behavior: "instant",
60
+ block: "center",
61
+ inline: "nearest"
62
+ });
63
+ }
64
+ };
65
+ const SideNavItemContent = ({
66
+ id,
67
+ label,
68
+ href,
69
+ target,
70
+ startIcon,
71
+ severity,
72
+ statusLabel,
73
+ endIcon,
74
+ onClick,
75
+ isSelected,
76
+ isDisabled,
77
+ scrollRef
78
+ }) => {
79
+ const localScrollRef = useRef(null);
80
+ useImperativeHandle(scrollRef, () => {
81
+ return {
82
+ scrollIntoView: () => {
83
+ scrollToNode(localScrollRef.current);
84
+ }
85
+ };
86
+ }, []);
87
+ const odysseyDesignTokens = useOdysseyDesignTokens();
88
+ const NavItemContentClickContainer = styled("div", {
89
+ shouldForwardProp: prop => prop !== "odysseyDesignTokens"
90
+ })(() => ({
91
+ display: "flex",
92
+ alignItems: "center",
93
+ width: "100%",
94
+ minHeight: "48px",
95
+ padding: `${odysseyDesignTokens.Spacing3} ${odysseyDesignTokens.Spacing4}`,
96
+ color: `${isDisabled ? odysseyDesignTokens.TypographyColorDisabled : odysseyDesignTokens.TypographyColorHeading} !important`,
97
+ "&:focus-visible": {
98
+ borderRadius: 0,
99
+ outlineColor: odysseyDesignTokens.FocusOutlineColorPrimary,
100
+ outlineStyle: odysseyDesignTokens.FocusOutlineStyle,
101
+ outlineWidth: odysseyDesignTokens.FocusOutlineWidthMain,
102
+ backgroundColor: odysseyDesignTokens.HueNeutral50,
103
+ textDecoration: "none"
104
+ }
105
+ }));
106
+ const sideNavItemContentKeyHandler = useCallback(event => {
107
+ if (event?.key === "Enter") {
108
+ event.preventDefault();
109
+ onClick?.();
110
+ }
111
+ }, [onClick]);
112
+ return _jsx(SideNavListItemContainer, {
113
+ ref: localScrollRef,
114
+ id: id,
115
+ disabled: isDisabled,
116
+ "aria-disabled": isDisabled,
117
+ isDisabled: isDisabled,
118
+ isSelected: isSelected,
119
+ odysseyDesignTokens: odysseyDesignTokens,
120
+ children: isDisabled ? _jsx(NavItemContentClickContainer, {
121
+ children: _jsx(SideNavItemLinkContent, {
122
+ label: label,
123
+ startIcon: startIcon,
124
+ endIcon: endIcon,
125
+ statusLabel: statusLabel,
126
+ severity: severity
127
+ })
128
+ }) : !href ? _jsx(NavItemContentClickContainer, {
129
+ role: "button",
130
+ tabIndex: 0,
131
+ onClick: onClick,
132
+ onKeyDown: sideNavItemContentKeyHandler,
133
+ children: _jsx(SideNavItemLinkContent, {
134
+ label: label,
135
+ startIcon: startIcon,
136
+ endIcon: endIcon,
137
+ statusLabel: statusLabel,
138
+ severity: severity
139
+ })
140
+ }) : _jsx(Link, {
141
+ href: href,
142
+ target: target,
143
+ onClick: onClick,
144
+ children: _jsx(SideNavItemLinkContent, {
145
+ label: label,
146
+ startIcon: startIcon,
147
+ endIcon: endIcon,
148
+ statusLabel: statusLabel,
149
+ severity: severity
150
+ })
151
+ })
152
+ }, id);
153
+ };
154
+ const MemoizedSideNavItemContent = memo(SideNavItemContent);
155
+ MemoizedSideNavItemContent.displayName = "SideNavItemContent";
156
+ export { MemoizedSideNavItemContent as SideNavItemContent };
157
+ //# sourceMappingURL=SideNavItemContent.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SideNavItemContent.js","names":["styled","useRef","useImperativeHandle","useCallback","memo","Link","useOdysseyDesignTokens","SideNavItemLinkContent","jsx","_jsx","SideNavListItemContainer","shouldForwardProp","prop","odysseyDesignTokens","isSelected","isDisabled","display","alignItems","cursor","pointerEvents","backgroundColor","HueNeutral50","margin","Spacing1","marginBottom","Spacing2","width","minHeight","padding","Spacing3","Spacing4","color","TypographyColorHeading","textDecoration","outlineOffset","borderRadius","outlineWidth","FocusOutlineWidthMain","scrollToNode","node","scrollIntoView","behavior","block","inline","SideNavItemContent","id","label","href","target","startIcon","severity","statusLabel","endIcon","onClick","scrollRef","localScrollRef","current","NavItemContentClickContainer","TypographyColorDisabled","outlineColor","FocusOutlineColorPrimary","outlineStyle","FocusOutlineStyle","sideNavItemContentKeyHandler","event","key","preventDefault","ref","disabled","children","role","tabIndex","onKeyDown","MemoizedSideNavItemContent","displayName"],"sources":["../../../src/labs/SideNav/SideNavItemContent.tsx"],"sourcesContent":["/*!\n * Copyright (c) 2024-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nimport styled from \"@emotion/styled\";\nimport {\n useRef,\n useImperativeHandle,\n useCallback,\n memo,\n KeyboardEvent,\n} from \"react\";\nimport { Link } from \"../../Link\";\nimport {\n type DesignTokens,\n useOdysseyDesignTokens,\n} from \"../../OdysseyDesignTokensContext\";\nimport { SideNavItemLinkContent } from \"./SideNavItemLinkContent\";\nimport type { SideNavItem } from \"./types\";\n\nexport const SideNavListItemContainer = styled(\"li\", {\n shouldForwardProp: (prop) =>\n prop !== \"odysseyDesignTokens\" &&\n prop !== \"isSelected\" &&\n prop !== \"isDisabled\",\n})<{\n odysseyDesignTokens: DesignTokens;\n isSelected?: boolean;\n disabled?: boolean;\n isDisabled?: boolean;\n}>(({ odysseyDesignTokens, isSelected, isDisabled }) => ({\n display: \"flex\",\n alignItems: \"center\",\n cursor: isDisabled ? \"default\" : \"pointer\",\n pointerEvents: isDisabled ? \"none\" : \"auto\",\n backgroundColor: isSelected ? odysseyDesignTokens.HueNeutral50 : \"unset\",\n margin: `${odysseyDesignTokens.Spacing1} 0`,\n \"&:last-child\": {\n marginBottom: odysseyDesignTokens.Spacing2,\n },\n \"& a\": {\n display: \"flex\",\n alignItems: \"center\",\n width: \"100%\",\n minHeight: \"48px\",\n padding: `${odysseyDesignTokens.Spacing3} ${odysseyDesignTokens.Spacing4}`,\n color: `${odysseyDesignTokens.TypographyColorHeading} !important`,\n pointerEvents: isDisabled ? \"none\" : \"auto\",\n },\n \"& a:hover\": {\n textDecoration: \"none\",\n cursor: isDisabled ? \"default\" : \"pointer\",\n backgroundColor: !isDisabled ? odysseyDesignTokens.HueNeutral50 : \"inherit\",\n },\n \"& a:focus-visible\": {\n outlineOffset: 0,\n borderRadius: 0,\n outlineWidth: odysseyDesignTokens.FocusOutlineWidthMain,\n backgroundColor: !isDisabled ? odysseyDesignTokens.HueNeutral50 : \"inherit\",\n },\n}));\n\nconst scrollToNode = (node: HTMLElement | null) => {\n if (node) {\n node?.scrollIntoView({\n behavior: \"instant\",\n block: \"center\",\n inline: \"nearest\",\n });\n }\n};\n\ntype ScrollIntoViewHandle = {\n scrollIntoView: () => void;\n};\n\nconst SideNavItemContent = ({\n id,\n label,\n href,\n target,\n startIcon,\n severity,\n statusLabel,\n endIcon,\n onClick,\n isSelected,\n isDisabled,\n scrollRef,\n}: Pick<\n SideNavItem,\n | \"id\"\n | \"label\"\n | \"href\"\n | \"target\"\n | \"startIcon\"\n | \"severity\"\n | \"statusLabel\"\n | \"endIcon\"\n | \"onClick\"\n | \"isSelected\"\n | \"isDisabled\"\n> & {\n /**\n * The ref used to scroll to this item\n */\n scrollRef?: React.RefObject<ScrollIntoViewHandle>;\n}) => {\n const localScrollRef = useRef<HTMLLIElement>(null);\n useImperativeHandle(\n scrollRef,\n () => {\n return {\n scrollIntoView: () => {\n scrollToNode(localScrollRef.current);\n },\n };\n },\n [],\n );\n const odysseyDesignTokens = useOdysseyDesignTokens();\n\n const NavItemContentClickContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n })(() => ({\n display: \"flex\",\n alignItems: \"center\",\n width: \"100%\",\n minHeight: \"48px\",\n padding: `${odysseyDesignTokens.Spacing3} ${odysseyDesignTokens.Spacing4}`,\n color: `${isDisabled ? odysseyDesignTokens.TypographyColorDisabled : odysseyDesignTokens.TypographyColorHeading} !important`,\n \"&:focus-visible\": {\n borderRadius: 0,\n outlineColor: odysseyDesignTokens.FocusOutlineColorPrimary,\n outlineStyle: odysseyDesignTokens.FocusOutlineStyle,\n outlineWidth: odysseyDesignTokens.FocusOutlineWidthMain,\n backgroundColor: odysseyDesignTokens.HueNeutral50,\n textDecoration: \"none\",\n },\n }));\n\n const sideNavItemContentKeyHandler = useCallback(\n (event: KeyboardEvent<HTMLDivElement>) => {\n if (event?.key === \"Enter\") {\n event.preventDefault();\n onClick?.();\n }\n },\n [onClick],\n );\n\n return (\n <SideNavListItemContainer\n ref={localScrollRef}\n id={id}\n key={id}\n disabled={isDisabled}\n aria-disabled={isDisabled}\n isDisabled={isDisabled}\n isSelected={isSelected}\n odysseyDesignTokens={odysseyDesignTokens}\n >\n {\n // Use Link for nav items with links and div for disabled or non-link items\n isDisabled ? (\n <NavItemContentClickContainer>\n <SideNavItemLinkContent\n label={label}\n startIcon={startIcon}\n endIcon={endIcon}\n statusLabel={statusLabel}\n severity={severity}\n />\n </NavItemContentClickContainer>\n ) : !href ? (\n <NavItemContentClickContainer\n role=\"button\"\n tabIndex={0}\n onClick={onClick}\n onKeyDown={sideNavItemContentKeyHandler}\n >\n <SideNavItemLinkContent\n label={label}\n startIcon={startIcon}\n endIcon={endIcon}\n statusLabel={statusLabel}\n severity={severity}\n />\n </NavItemContentClickContainer>\n ) : (\n <Link href={href} target={target} onClick={onClick}>\n <SideNavItemLinkContent\n label={label}\n startIcon={startIcon}\n endIcon={endIcon}\n statusLabel={statusLabel}\n severity={severity}\n />\n </Link>\n )\n }\n </SideNavListItemContainer>\n );\n};\nconst MemoizedSideNavItemContent = memo(SideNavItemContent);\nMemoizedSideNavItemContent.displayName = \"SideNavItemContent\";\n\nexport { MemoizedSideNavItemContent as Side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,EAAC,QAAQ;MACbC,QAAQ,EAAE,CAAE;MACZlB,OAAO,EAAEA,OAAQ;MACjBmB,SAAS,EAAET,4BAA6B;MAAAM,QAAA,EAExC5D,IAAA,CAACF,sBAAsB;QACrBuC,KAAK,EAAEA,KAAM;QACbG,SAAS,EAAEA,SAAU;QACrBG,OAAO,EAAEA,OAAQ;QACjBD,WAAW,EAAEA,WAAY;QACzBD,QAAQ,EAAEA;MAAS,CACpB;IAAC,CAC0B,CAAC,GAE/BzC,IAAA,CAACJ,IAAI;MAAC0C,IAAI,EAAEA,IAAK;MAACC,MAAM,EAAEA,MAAO;MAACK,OAAO,EAAEA,OAAQ;MAAAgB,QAAA,EACjD5D,IAAA,CAACF,sBAAsB;QACrBuC,KAAK,EAAEA,KAAM;QACbG,SAAS,EAAEA,SAAU;QACrBG,OAAO,EAAEA,OAAQ;QACjBD,WAAW,EAAEA,WAAY;QACzBD,QAAQ,EAAEA;MAAS,CACpB;IAAC,CACE;EACP,GA5CEL,EA8CmB,CAAC;AAE/B,CAAC;AACD,MAAM4B,0BAA0B,GAAGrE,IAAI,CAACwC,kBAAkB,CAAC;AAC3D6B,0BAA0B,CAACC,WAAW,GAAG,oBAAoB;AAE7D,SAASD,0BAA0B,IAAI7B,kBAAkB"}
@@ -0,0 +1,71 @@
1
+ /*!
2
+ * Copyright (c) 2024-present, Okta, Inc. and/or its affiliates. All rights reserved.
3
+ * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the "License.")
4
+ *
5
+ * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.
6
+ * Unless required by applicable law or agreed to in writing, software
7
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
8
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
9
+ *
10
+ * See the License for the specific language governing permissions and limitations under the License.
11
+ */
12
+
13
+ import styled from "@emotion/styled";
14
+ import { memo, useMemo } from "react";
15
+ import { useOdysseyDesignTokens } from "../../OdysseyDesignTokensContext.js";
16
+ import { Box } from "../../Box.js";
17
+ import { Status } from "../../Status.js";
18
+ import { jsx as _jsx } from "react/jsx-runtime";
19
+ import { jsxs as _jsxs } from "react/jsx-runtime";
20
+ import { Fragment as _Fragment } from "react/jsx-runtime";
21
+ const SideNavItemLabelContainer = styled("div", {
22
+ shouldForwardProp: prop => prop !== "odysseyDesignTokens" && prop !== "isIconVisible"
23
+ })(({
24
+ odysseyDesignTokens,
25
+ isIconVisible
26
+ }) => ({
27
+ width: "100%",
28
+ display: "flex",
29
+ flexWrap: "wrap",
30
+ alignItems: "center",
31
+ fontSize: odysseyDesignTokens.TypographyScale0,
32
+ fontWeight: odysseyDesignTokens.TypographyWeightHeading,
33
+ marginLeft: isIconVisible ? odysseyDesignTokens.Spacing2 : 0,
34
+ "& a": {
35
+ color: `${odysseyDesignTokens.TypographyColorHeading} !important`,
36
+ fontSize: odysseyDesignTokens.TypographyScale0
37
+ },
38
+ "& a:hover": {
39
+ textDecoration: "none",
40
+ cursor: "pointer"
41
+ }
42
+ }));
43
+ const SideNavItemLinkContent = ({
44
+ label,
45
+ startIcon,
46
+ endIcon,
47
+ severity,
48
+ statusLabel
49
+ }) => {
50
+ const odysseyDesignTokens = useOdysseyDesignTokens();
51
+ const sideNavItemContentStyles = useMemo(() => ({
52
+ marginLeft: odysseyDesignTokens.Spacing2
53
+ }), [odysseyDesignTokens]);
54
+ return _jsxs(_Fragment, {
55
+ children: [startIcon && startIcon, _jsxs(SideNavItemLabelContainer, {
56
+ odysseyDesignTokens: odysseyDesignTokens,
57
+ isIconVisible: Boolean(startIcon),
58
+ children: [label, severity && _jsx(Box, {
59
+ sx: sideNavItemContentStyles,
60
+ children: _jsx(Status, {
61
+ severity: severity,
62
+ label: statusLabel || ""
63
+ })
64
+ })]
65
+ }), endIcon && endIcon]
66
+ });
67
+ };
68
+ const MemoizedSideNavItemLinkContent = memo(SideNavItemLinkContent);
69
+ MemoizedSideNavItemLinkContent.displayName = "SideNavItemLinkContent";
70
+ export { MemoizedSideNavItemLinkContent as SideNavItemLinkContent };
71
+ //# sourceMappingURL=SideNavItemLinkContent.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SideNavItemLinkContent.js","names":["styled","memo","useMemo","useOdysseyDesignTokens","Box","Status","jsx","_jsx","jsxs","_jsxs","Fragment","_Fragment","SideNavItemLabelContainer","shouldForwardProp","prop","odysseyDesignTokens","isIconVisible","width","display","flexWrap","alignItems","fontSize","TypographyScale0","fontWeight","TypographyWeightHeading","marginLeft","Spacing2","color","TypographyColorHeading","textDecoration","cursor","SideNavItemLinkContent","label","startIcon","endIcon","severity","statusLabel","sideNavItemContentStyles","children","Boolean","sx","MemoizedSideNavItemLinkContent","displayName"],"sources":["../../../src/labs/SideNav/SideNavItemLinkContent.tsx"],"sourcesContent":["/*!\n * Copyright (c) 2024-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nimport styled from \"@emotion/styled\";\nimport { memo, ReactNode, useMemo } from \"react\";\nimport {\n type DesignTokens,\n useOdysseyDesignTokens,\n} from \"../../OdysseyDesignTokensContext\";\nimport { Box } from \"../../Box\";\nimport { Status } from \"../../Status\";\nimport type { SideNavItem } from \"./types\";\n\nconst SideNavItemLabelContainer = styled(\"div\", {\n shouldForwardProp: (prop) =>\n prop !== \"odysseyDesignTokens\" && prop !== \"isIconVisible\",\n})<{\n odysseyDesignTokens: DesignTokens;\n isIconVisible: boolean;\n}>(({ odysseyDesignTokens, isIconVisible }) => ({\n width: \"100%\",\n display: \"flex\",\n flexWrap: \"wrap\",\n alignItems: \"center\",\n fontSize: odysseyDesignTokens.TypographyScale0,\n fontWeight: odysseyDesignTokens.TypographyWeightHeading,\n marginLeft: isIconVisible ? odysseyDesignTokens.Spacing2 : 0,\n \"& a\": {\n color: `${odysseyDesignTokens.TypographyColorHeading} !important`,\n fontSize: odysseyDesignTokens.TypographyScale0,\n },\n \"& a:hover\": {\n textDecoration: \"none\",\n cursor: \"pointer\",\n },\n}));\n\nconst SideNavItemLinkContent = ({\n label,\n startIcon,\n endIcon,\n severity,\n statusLabel,\n}: Pick<\n SideNavItem,\n \"label\" | \"startIcon\" | \"endIcon\" | \"severity\" | \"statusLabel\"\n>): ReactNode => {\n const odysseyDesignTokens = useOdysseyDesignTokens();\n\n const sideNavItemContentStyles = useMemo(\n () => ({\n marginLeft: odysseyDesignTokens.Spacing2,\n }),\n [odysseyDesignTokens],\n );\n\n return (\n <>\n {startIcon && startIcon}\n <SideNavItemLabelContainer\n odysseyDesignTokens={odysseyDesignTokens}\n isIconVisible={Boolean(startIcon)}\n >\n {label}\n {severity && (\n <Box sx={sideNavItemContentStyles}>\n <Status severity={severity} label={statusLabel || \"\"} />\n </Box>\n )}\n </SideNavItemLabelContainer>\n {endIcon && endIcon}\n </>\n );\n};\nconst MemoizedSideNavItemLinkContent = memo(SideNavItemLinkContent);\nMemoizedSideNavItemLinkContent.displayName = \"SideNavItemLinkContent\";\n\nexport { MemoizedSideNavItemLinkContent as SideNavItemLinkContent };\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAOA,MAAM,MAAM,iBAAiB;AACpC,SAASC,IAAI,EAAaC,OAAO,QAAQ,OAAO;AAAC,SAG/CC,sBAAsB;AAAA,SAEfC,GAAG;AAAA,SACHC,MAAM;AAAA,SAAAC,GAAA,IAAAC,IAAA;AAAA,SAAAC,IAAA,IAAAC,KAAA;AAAA,SAAAC,QAAA,IAAAC,SAAA;AAGf,MAAMC,yBAAyB,GAAGZ,MAAM,CAAC,KAAK,EAAE;EAC9Ca,iBAAi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QAAS;UAACH,KAAK,EAAEI,WAAW,IAAI;QAAG,CAAE;MAAC,CACrD,CACN;IAAA,CACwB,CAAC,EAC3BF,OAAO,IAAIA,OAAO;EAAA,CACnB,CAAC;AAEP,CAAC;AACD,MAAMO,8BAA8B,GAAGxC,IAAI,CAAC8B,sBAAsB,CAAC;AACnEU,8BAA8B,CAACC,WAAW,GAAG,wBAAwB;AAErE,SAASD,8BAA8B,IAAIV,sBAAsB"}
@@ -0,0 +1,14 @@
1
+ /*!
2
+ * Copyright (c) 2024-present, Okta, Inc. and/or its affiliates. All rights reserved.
3
+ * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the "License.")
4
+ *
5
+ * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.
6
+ * Unless required by applicable law or agreed to in writing, software
7
+ * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
8
+ * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
9
+ *
10
+ * See the License for the specific language governing permissions and limitations under the License.
11
+ */
12
+ export { SideNav } from "./SideNav.js";
13
+ export * from "./types.js";
14
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":["SideNav"],"sources":["../../../src/labs/SideNav/index.ts"],"sourcesContent":["/*!\n * Copyright (c) 2024-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nexport { SideNav } from \"./SideNav\";\n\nexport * from \"./types\";\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAVA,SAYSA,OAAO;AAAA"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","names":[],"sources":["../../../src/labs/SideNav/types.ts"],"sourcesContent":["/*!\n * Copyright (c) 2024-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nimport type { ReactElement } from \"react\";\nimport type { HtmlProps } from \"../../HtmlProps\";\nimport type { statusSeverityValues } from \"../../Status\";\n\nexport type SideNavProps = {\n /**\n * Side Nav header text that is usually reserved to show the App name\n */\n navHeaderText: string;\n /**\n * Determines whether the side nav is collapsible\n */\n isCollapsible?: boolean;\n /**\n * Triggers when the side nav is collapsed\n */\n onCollapse?(): void;\n /**\n * Triggers when the side nav is expanded\n */\n onExpand?(): void;\n /**\n * Nav items in the side nav\n */\n sideNavItems: SideNavItem[];\n /**\n * A CSS length string indicating the customizable expanded width of the SideNav container.\n * (it will be smaller if isCollapsible and collapsed)\n */\n expandedWidth?: string;\n /**\n * An optional logo to display in the header. If not provided, will default to the Okta logo\n */\n logo?: ReactElement;\n} & (\n | {\n /**\n * Footer items in the side nav\n */\n footerItems?: SideNavFooterItem[];\n /**\n * footerComponent cannot be used if footerItems are defined\n */\n footerComponent?: never;\n }\n | {\n /**\n * footerItems cannot be used if footerComponent is defined\n */\n footerItems?: never;\n /**\n * The component to display as the footer; if present the `footerItems` are ignored and not rendered.\n */\n footerComponent?: ReactElement;\n }\n) &\n Pick<HtmlProps, \"testId\">;\n\nexport type SideNavItem = {\n id: string;\n label: string;\n /**\n * The icon element to display at the end of the Nav Item\n */\n endIcon?: ReactElement;\n /**\n * Whether the item is disabled. When set to true the nav item is set to Disabled color,\n * the link/item is not clickable, and item with children is not expandable.\n */\n isDisabled?: boolean;\n /**\n * Whether the item is active/selected\n */\n isSelected?: boolean;\n /**\n * Event fired when the nav item is clicked\n */\n onClick?(): void;\n /**\n * The status element to display after the label\n */\n severity?: (typeof statusSeverityValues)[number];\n /**\n * The icon element to display at the start of the Nav Item\n */\n startIcon?: ReactElement;\n /**\n * The label to display inside the status\n */\n statusLabel?: string;\n /**\n * The link target prop. e.g., \"_blank\"\n */\n target?: string;\n} & (\n | {\n /**\n * Determines if the side nav item is a section header\n */\n isSectionHeader: true;\n href?: never;\n children?: never;\n isDefaultExpanded?: never;\n isExpanded?: never;\n }\n | {\n /**\n * link added to the nav item. if it is undefined, static text will be displayed.\n * fires onClick event when it is passed\n */\n href: string;\n children?: never;\n isSectionHeader?: never;\n isDefaultExpanded?: never;\n isExpanded?: never;\n }\n | {\n /**\n * An array of side nav items to be displayed as children within Accordion\n */\n children?: SideNavItem[];\n /**\n * Whether the accordion (nav item with children) is expanded by default\n */\n isDefaultExpanded?: boolean;\n /**\n * If true, expands the accordion, otherwise collapse it.\n * Setting this prop enables control over the accordion.\n */\n isExpanded?: boolean;\n isSectionHeader?: never;\n href?: never;\n }\n);\n\nexport type SideNavFooterItem = {\n href?: string;\n id: string;\n label: string;\n};\n"],"mappings":""}
@@ -19,6 +19,7 @@ import { Subordinate } from "../Typography.js";
19
19
  import { jsx as _jsx } from "react/jsx-runtime";
20
20
  import { jsxs as _jsxs } from "react/jsx-runtime";
21
21
  import { createElement as _createElement } from "react";
22
+ export const TOP_NAV_HEIGHT_TOKEN = "Spacing9";
22
23
  const UserProfileContainer = styled("div", {
23
24
  shouldForwardProp: prop => prop !== "odysseyDesignTokens"
24
25
  })(({
@@ -210,7 +211,7 @@ const TopNavContainer = styled("div", {
210
211
  display: "flex",
211
212
  alignItems: "center",
212
213
  backgroundColor: odysseyDesignTokens.HueNeutralWhite,
213
- height: odysseyDesignTokens.Spacing9
214
+ height: odysseyDesignTokens[TOP_NAV_HEIGHT_TOKEN]
214
215
  }));
215
216
  const SearchFieldContainer = styled("div", {
216
217
  shouldForwardProp: prop => prop !== "odysseyDesignTokens"
@@ -1 +1 @@
1
- {"version":3,"file":"TopNav.js","names":["styled","memo","useMemo","useCallback","QuestionCircleIcon","SettingsIcon","Link","useOdysseyDesignTokens","Subordinate","jsx","_jsx","jsxs","_jsxs","createElement","_createElement","UserProfileContainer","shouldForwardProp","prop","odysseyDesignTokens","display","alignItems","paddingRight","Spacing4","UserProfileIconContainer","Spacing2","UserProfileInfoContainer","flexDirection","UserProfile","profileIcon","userName","orgName","children","color","TopNavListContainer","padding","listStyle","listStyleType","TopNavItemLabelContainer","flexWrap","fontSize","TypographyScale0","fontWeight","TypographyWeightHeading","TopNavListItemContainer","isDisabled","cursor","pointerEvents","TypographyColorDisabled","TypographyColorHeading","textDecoration","backgroundColor","HueNeutral50","outlineOffset","borderRadius","outlineWidth","FocusOutlineWidthMain","NavItemContentClickContainer","width","outlineColor","FocusOutlineColorPrimary","outlineStyle","FocusOutlineStyle","TopNavItemContent","id","label","href","target","onClick","topNavItemContentKeyHandler","event","key","preventDefault","stopPropagation","role","tabIndex","onKeyDown","LinkAndProfileWrapper","marginLeft","AdditionalLinkContainerWithBorder","marginRight","Spacing3","borderRight","BorderWidthMain","HueNeutral200","LinkContainer","TopNavContainer","HueNeutralWhite","height","Spacing9","SearchFieldContainer","AdditionalNavItemContainer","TopNav","SearchFieldComponent","topNavLinkItems","AdditionalNavItemComponent","settingsPageHref","helpPageHref","userProfile","processedNavItems","map","item","ariaLabel","MemoizedTopNav","displayName"],"sources":["../../src/labs/TopNav.tsx"],"sourcesContent":["/*!\n * Copyright (c) 2022-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nimport styled from \"@emotion/styled\";\nimport {\n memo,\n useMemo,\n ReactElement,\n useCallback,\n MouseEventHandler,\n KeyboardEventHandler,\n} from \"react\";\n\nimport type { HtmlProps } from \"../HtmlProps\";\nimport { QuestionCircleIcon, SettingsIcon } from \"../icons.generated\";\nimport { Link } from \"../Link\";\nimport {\n DesignTokens,\n useOdysseyDesignTokens,\n} from \"../OdysseyDesignTokensContext\";\nimport { Subordinate } from \"../Typography\";\n\nexport type TopNavLinkItem = {\n id: string;\n label: string;\n /**\n * link added to the nav item. if it is undefined, static text will be displayed.\n * fires onClick event when it is passed\n */\n href?: string;\n /**\n * determines whether the link item is diabled\n */\n isDisabled?: boolean;\n /**\n * Event fired when the nav item is clicked\n */\n onClick?: MouseEventHandler<HTMLAnchorElement> &\n MouseEventHandler<HTMLDivElement> &\n KeyboardEventHandler<HTMLDivElement>;\n /**\n * The link target prop. e.g., \"_blank\"\n */\n target?: string;\n};\n\nexport type UserProfileProps = {\n /**\n * Logged in user profile icon to be displayed in the top nav\n */\n profileIcon?: ReactElement;\n /**\n * Logged in user info to be displayed in the top nav\n */\n userName: string;\n /**\n * Org name of the logged in user\n */\n orgName: string;\n};\n\nexport type TopNavProps = {\n /**\n * Pass in a SearchField component with the variant=\"filled\" prop set\n */\n SearchFieldComponent?: ReactElement;\n /**\n * Nav links in the top nav\n */\n topNavLinkItems: TopNavLinkItem[];\n /**\n * Pass in an additional component like `Button` that will be displayed after the nav link items\n */\n AdditionalNavItemComponent?: ReactElement;\n /**\n * URL to settings page.\n */\n settingsPageHref?: string;\n /**\n * URL to the help page.\n */\n helpPageHref?: string;\n /**\n * Displays user account info\n */\n userProfile?: UserProfileProps;\n} & Pick<HtmlProps, \"testId\">;\n\nconst UserProfileContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})(({ odysseyDesignTokens }: { odysseyDesignTokens: DesignTokens }) => ({\n display: \"flex\",\n alignItems: \"center\",\n paddingRight: odysseyDesignTokens.Spacing4,\n}));\n\nconst UserProfileIconContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})(({ odysseyDesignTokens }: { odysseyDesignTokens: DesignTokens }) => ({\n display: \"flex\",\n paddingRight: odysseyDesignTokens.Spacing2,\n}));\n\nconst UserProfileInfoContainer = styled(\"div\")(() => ({\n display: \"flex\",\n flexDirection: \"column\",\n}));\n\nconst UserProfile = ({ profileIcon, userName, orgName }: UserProfileProps) => {\n const odysseyDesignTokens = useOdysseyDesignTokens();\n\n return (\n <UserProfileContainer odysseyDesignTokens={odysseyDesignTokens}>\n {profileIcon && (\n <UserProfileIconContainer odysseyDesignTokens={odysseyDesignTokens}>\n {profileIcon}\n </UserProfileIconContainer>\n )}\n <UserProfileInfoContainer>\n <Subordinate color=\"textPrimary\">{userName}</Subordinate>\n <Subordinate color=\"textSecondary\">{orgName}</Subordinate>\n </UserProfileInfoContainer>\n </UserProfileContainer>\n );\n};\n\nconst TopNavListContainer = styled(\"ul\")(() => ({\n padding: 0,\n listStyle: \"none\",\n listStyleType: \"none\",\n display: \"flex\",\n alignItems: \"center\",\n}));\n\nconst TopNavItemLabelContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n display: \"flex\",\n flexWrap: \"wrap\",\n alignItems: \"center\",\n fontSize: odysseyDesignTokens.TypographyScale0,\n fontWeight: odysseyDesignTokens.TypographyWeightHeading,\n}));\n\nconst TopNavListItemContainer = styled(\"li\", {\n shouldForwardProp: (prop) =>\n prop !== \"odysseyDesignTokens\" && prop !== \"isDisabled\",\n})<{\n odysseyDesignTokens: DesignTokens;\n isDisabled?: boolean;\n}>(({ odysseyDesignTokens, isDisabled }) => ({\n display: \"flex\",\n alignItems: \"center\",\n cursor: isDisabled ? \"default\" : \"pointer\",\n pointerEvents: isDisabled ? \"none\" : \"auto\",\n color: `${isDisabled ? odysseyDesignTokens.TypographyColorDisabled : odysseyDesignTokens.TypographyColorHeading} !important`,\n \"& a\": {\n display: \"flex\",\n alignItems: \"center\",\n padding: `${odysseyDesignTokens.Spacing2} ${odysseyDesignTokens.Spacing4}`,\n color: `${odysseyDesignTokens.TypographyColorHeading} !important`,\n },\n \"& a:hover\": {\n textDecoration: \"none\",\n backgroundColor: !isDisabled ? odysseyDesignTokens.HueNeutral50 : \"inherit\",\n },\n \"& div[role='button']:hover\": {\n backgroundColor: !isDisabled ? odysseyDesignTokens.HueNeutral50 : \"inherit\",\n },\n \"& a:focus-visible\": {\n outlineOffset: 0,\n borderRadius: 0,\n outlineWidth: odysseyDesignTokens.FocusOutlineWidthMain,\n backgroundColor: !isDisabled ? odysseyDesignTokens.HueNeutral50 : \"inherit\",\n },\n}));\n\nconst NavItemContentClickContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n display: \"flex\",\n alignItems: \"center\",\n width: \"100%\",\n padding: `${odysseyDesignTokens.Spacing2} ${odysseyDesignTokens.Spacing4}`,\n \"&:focus-visible\": {\n borderRadius: 0,\n outlineColor: odysseyDesignTokens.FocusOutlineColorPrimary,\n outlineStyle: odysseyDesignTokens.FocusOutlineStyle,\n outlineWidth: odysseyDesignTokens.FocusOutlineWidthMain,\n backgroundColor: odysseyDesignTokens.HueNeutral50,\n textDecoration: \"none\",\n },\n}));\n\nconst TopNavItemContent = ({\n id,\n label,\n href,\n target,\n onClick,\n isDisabled,\n}: TopNavLinkItem) => {\n const odysseyDesignTokens = useOdysseyDesignTokens();\n\n const topNavItemContentKeyHandler = useCallback<\n KeyboardEventHandler<HTMLDivElement>\n >(\n (event) => {\n if (event?.key === \"Enter\") {\n event.preventDefault();\n event.stopPropagation();\n onClick?.(event);\n }\n },\n [onClick],\n );\n\n return (\n <TopNavListItemContainer\n id={id}\n key={id}\n aria-disabled={isDisabled}\n isDisabled={isDisabled}\n odysseyDesignTokens={odysseyDesignTokens}\n >\n {\n // Use Link for nav items with links and div for disabled or non-link items\n isDisabled ? (\n <NavItemContentClickContainer\n odysseyDesignTokens={odysseyDesignTokens}\n >\n <TopNavItemLabelContainer odysseyDesignTokens={odysseyDesignTokens}>\n {label}\n </TopNavItemLabelContainer>\n </NavItemContentClickContainer>\n ) : !href ? (\n <NavItemContentClickContainer\n odysseyDesignTokens={odysseyDesignTokens}\n role=\"button\"\n tabIndex={0}\n onClick={onClick}\n onKeyDown={topNavItemContentKeyHandler}\n >\n <TopNavItemLabelContainer odysseyDesignTokens={odysseyDesignTokens}>\n {label}\n </TopNavItemLabelContainer>\n </NavItemContentClickContainer>\n ) : (\n <Link href={href} target={target} onClick={onClick}>\n <TopNavItemLabelContainer odysseyDesignTokens={odysseyDesignTokens}>\n {label}\n </TopNavItemLabelContainer>\n </Link>\n )\n }\n </TopNavListItemContainer>\n );\n};\n\nconst LinkAndProfileWrapper = styled(\"div\")(() => ({\n display: \"flex\",\n alignItems: \"center\",\n marginLeft: \"auto\",\n}));\n\nconst AdditionalLinkContainerWithBorder = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n display: \"flex\",\n alignItems: \"center\",\n marginRight: odysseyDesignTokens.Spacing3,\n borderRight: `${odysseyDesignTokens.BorderWidthMain} solid ${odysseyDesignTokens.HueNeutral200}`,\n}));\n\nconst LinkContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n paddingRight: odysseyDesignTokens.Spacing3,\n \"& a\": {\n color: `${odysseyDesignTokens.TypographyColorHeading} !important`,\n },\n}));\n\nconst TopNavContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n display: \"flex\",\n alignItems: \"center\",\n backgroundColor: odysseyDesignTokens.HueNeutralWhite,\n height: odysseyDesignTokens.Spacing9,\n}));\n\nconst SearchFieldContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n width: \"350px\",\n padding: `${odysseyDesignTokens.Spacing2} ${odysseyDesignTokens.Spacing3}`,\n}));\n\nconst AdditionalNavItemContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n padding: `0 ${odysseyDesignTokens.Spacing3}`,\n}));\n\nconst TopNav = ({\n SearchFieldComponent,\n topNavLinkItems,\n AdditionalNavItemComponent,\n settingsPageHref,\n helpPageHref,\n userProfile,\n}: TopNavProps) => {\n const odysseyDesignTokens = useOdysseyDesignTokens();\n\n const processedNavItems = useMemo(\n () =>\n topNavLinkItems.map((item) => (\n <TopNavItemContent {...item} key={item.id} />\n )),\n [topNavLinkItems],\n );\n\n return (\n <TopNavContainer odysseyDesignTokens={odysseyDesignTokens}>\n {SearchFieldComponent && (\n <SearchFieldContainer odysseyDesignTokens={odysseyDesignTokens}>\n {SearchFieldComponent}\n </SearchFieldContainer>\n )}\n <TopNavListContainer>\n {processedNavItems?.map((item) => item)}\n </TopNavListContainer>\n <LinkAndProfileWrapper>\n {(AdditionalNavItemComponent || settingsPageHref || helpPageHref) && (\n <AdditionalLinkContainerWithBorder\n odysseyDesignTokens={odysseyDesignTokens}\n >\n {AdditionalNavItemComponent && (\n <AdditionalNavItemContainer\n odysseyDesignTokens={odysseyDesignTokens}\n >\n {AdditionalNavItemComponent}\n </AdditionalNavItemContainer>\n )}\n {settingsPageHref && (\n <LinkContainer odysseyDesignTokens={odysseyDesignTokens}>\n <Link href={settingsPageHref} ariaLabel=\"settings page\">\n <SettingsIcon />\n </Link>\n </LinkContainer>\n )}\n {helpPageHref && (\n <LinkContainer odysseyDesignTokens={odysseyDesignTokens}>\n <Link href={helpPageHref} ariaLabel=\"help page\">\n <QuestionCircleIcon />\n </Link>\n </LinkContainer>\n )}\n </AdditionalLinkContainerWithBorder>\n )}\n {userProfile && <UserProfile {...userProfile} />}\n </LinkAndProfileWrapper>\n </TopNavContainer>\n );\n};\n\nconst MemoizedTopNav = memo(TopNav);\nMemoizedTopNav.displayName = \"TopNav\";\n\nexport { MemoizedTopNav as TopNav };\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAOA,MAAM,MAAM,iBAAiB;AACpC,SACEC,IAAI,EACJC,OAAO,EAEPC,WAAW,QAGN,OAAO;AAAC,SAGNC,kBAAkB,EAAEC,YAAY;AAAA,SAChCC,IAAI;AAAA,SAGXC,sBAAsB;AAAA,SAEfC,WAAW;AAAA,SAAAC,GAAA,IAAAC,IAAA;AAAA,SAAAC,IAAA,IAAAC,KAAA;AAAA,SAAAC,aAAA,IAAAC,cAAA;AAoEpB,MAAMC,oBAAoB,GAAGf,MAAM,CAAC,KAAK,EAAE;EACzCgB,iBAAiB,EAAGC,IAAI,IAAKA,IAAI,KAAK;AACxC,CAAC,CAAC,CAAC,CAAC;EAAEC;AAA2D,CAAC,MAAM;EACtEC,OAAO,EAAE,MAAM;EACfC,UAAU,EAAE,QAAQ;EACpBC,YAAY,EAAEH,mBAAmB,CAACI;AACpC,CAAC,CAAC,CAAC;AAEH,MAAMC,wBAAwB,GAAGvB,MAAM,CAAC,KAAK,EAAE;EAC7CgB,iBAAiB,EAAGC,IAAI,IAAKA,IAAI,KAAK;AACxC,CAA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B,IAAA,CAACL,YAAY,IAAE;UAAC,CACZ;QAAC,CACM,CAChB,EACA2F,YAAY,IACXtF,IAAA,CAAC0E,aAAa;UAAClE,mBAAmB,EAAEA,mBAAoB;UAAAa,QAAA,EACtDrB,IAAA,CAACJ,IAAI;YAAC2D,IAAI,EAAE+B,YAAa;YAACK,SAAS,EAAC,WAAW;YAAAtE,QAAA,EAC7CrB,IAAA,CAACN,kBAAkB,IAAE;UAAC,CAClB;QAAC,CACM,CAChB;MAAA,CACgC,CACpC,EACA6F,WAAW,IAAIvF,IAAA,CAACiB,WAAW;QAAA,GAAKsE;MAAW,CAAG,CAAC;IAAA,CAC3B,CAAC;EAAA,CACT,CAAC;AAEtB,CAAC;AAED,MAAMK,cAAc,GAAGrG,IAAI,CAAC0F,MAAM,CAAC;AACnCW,cAAc,CAACC,WAAW,GAAG,QAAQ;AAErC,SAASD,cAAc,IAAIX,MAAM"}
1
+ {"version":3,"file":"TopNav.js","names":["styled","memo","useMemo","useCallback","QuestionCircleIcon","SettingsIcon","Link","useOdysseyDesignTokens","Subordinate","jsx","_jsx","jsxs","_jsxs","createElement","_createElement","TOP_NAV_HEIGHT_TOKEN","UserProfileContainer","shouldForwardProp","prop","odysseyDesignTokens","display","alignItems","paddingRight","Spacing4","UserProfileIconContainer","Spacing2","UserProfileInfoContainer","flexDirection","UserProfile","profileIcon","userName","orgName","children","color","TopNavListContainer","padding","listStyle","listStyleType","TopNavItemLabelContainer","flexWrap","fontSize","TypographyScale0","fontWeight","TypographyWeightHeading","TopNavListItemContainer","isDisabled","cursor","pointerEvents","TypographyColorDisabled","TypographyColorHeading","textDecoration","backgroundColor","HueNeutral50","outlineOffset","borderRadius","outlineWidth","FocusOutlineWidthMain","NavItemContentClickContainer","width","outlineColor","FocusOutlineColorPrimary","outlineStyle","FocusOutlineStyle","TopNavItemContent","id","label","href","target","onClick","topNavItemContentKeyHandler","event","key","preventDefault","stopPropagation","role","tabIndex","onKeyDown","LinkAndProfileWrapper","marginLeft","AdditionalLinkContainerWithBorder","marginRight","Spacing3","borderRight","BorderWidthMain","HueNeutral200","LinkContainer","TopNavContainer","HueNeutralWhite","height","SearchFieldContainer","AdditionalNavItemContainer","TopNav","SearchFieldComponent","topNavLinkItems","AdditionalNavItemComponent","settingsPageHref","helpPageHref","userProfile","processedNavItems","map","item","ariaLabel","MemoizedTopNav","displayName"],"sources":["../../src/labs/TopNav.tsx"],"sourcesContent":["/*!\n * Copyright (c) 2022-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nimport styled from \"@emotion/styled\";\nimport {\n memo,\n useMemo,\n ReactElement,\n useCallback,\n MouseEventHandler,\n KeyboardEventHandler,\n} from \"react\";\n\nimport type { HtmlProps } from \"../HtmlProps\";\nimport { QuestionCircleIcon, SettingsIcon } from \"../icons.generated\";\nimport { Link } from \"../Link\";\nimport {\n DesignTokens,\n useOdysseyDesignTokens,\n} from \"../OdysseyDesignTokensContext\";\nimport { Subordinate } from \"../Typography\";\n\nexport const TOP_NAV_HEIGHT_TOKEN = \"Spacing9\";\n\nexport type TopNavLinkItem = {\n id: string;\n label: string;\n /**\n * link added to the nav item. if it is undefined, static text will be displayed.\n * fires onClick event when it is passed\n */\n href?: string;\n /**\n * determines whether the link item is diabled\n */\n isDisabled?: boolean;\n /**\n * Event fired when the nav item is clicked\n */\n onClick?: MouseEventHandler<HTMLAnchorElement> &\n MouseEventHandler<HTMLDivElement> &\n KeyboardEventHandler<HTMLDivElement>;\n /**\n * The link target prop. e.g., \"_blank\"\n */\n target?: string;\n};\n\nexport type UserProfileProps = {\n /**\n * Logged in user profile icon to be displayed in the top nav\n */\n profileIcon?: ReactElement;\n /**\n * Logged in user info to be displayed in the top nav\n */\n userName: string;\n /**\n * Org name of the logged in user\n */\n orgName: string;\n};\n\nexport type TopNavProps = {\n /**\n * Pass in a SearchField component with the variant=\"filled\" prop set\n */\n SearchFieldComponent?: ReactElement;\n /**\n * Nav links in the top nav\n */\n topNavLinkItems: TopNavLinkItem[];\n /**\n * Pass in an additional component like `Button` that will be displayed after the nav link items\n */\n AdditionalNavItemComponent?: ReactElement;\n /**\n * URL to settings page.\n */\n settingsPageHref?: string;\n /**\n * URL to the help page.\n */\n helpPageHref?: string;\n /**\n * Displays user account info\n */\n userProfile?: UserProfileProps;\n} & Pick<HtmlProps, \"testId\">;\n\nconst UserProfileContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})(({ odysseyDesignTokens }: { odysseyDesignTokens: DesignTokens }) => ({\n display: \"flex\",\n alignItems: \"center\",\n paddingRight: odysseyDesignTokens.Spacing4,\n}));\n\nconst UserProfileIconContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})(({ odysseyDesignTokens }: { odysseyDesignTokens: DesignTokens }) => ({\n display: \"flex\",\n paddingRight: odysseyDesignTokens.Spacing2,\n}));\n\nconst UserProfileInfoContainer = styled(\"div\")(() => ({\n display: \"flex\",\n flexDirection: \"column\",\n}));\n\nconst UserProfile = ({ profileIcon, userName, orgName }: UserProfileProps) => {\n const odysseyDesignTokens = useOdysseyDesignTokens();\n\n return (\n <UserProfileContainer odysseyDesignTokens={odysseyDesignTokens}>\n {profileIcon && (\n <UserProfileIconContainer odysseyDesignTokens={odysseyDesignTokens}>\n {profileIcon}\n </UserProfileIconContainer>\n )}\n <UserProfileInfoContainer>\n <Subordinate color=\"textPrimary\">{userName}</Subordinate>\n <Subordinate color=\"textSecondary\">{orgName}</Subordinate>\n </UserProfileInfoContainer>\n </UserProfileContainer>\n );\n};\n\nconst TopNavListContainer = styled(\"ul\")(() => ({\n padding: 0,\n listStyle: \"none\",\n listStyleType: \"none\",\n display: \"flex\",\n alignItems: \"center\",\n}));\n\nconst TopNavItemLabelContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n display: \"flex\",\n flexWrap: \"wrap\",\n alignItems: \"center\",\n fontSize: odysseyDesignTokens.TypographyScale0,\n fontWeight: odysseyDesignTokens.TypographyWeightHeading,\n}));\n\nconst TopNavListItemContainer = styled(\"li\", {\n shouldForwardProp: (prop) =>\n prop !== \"odysseyDesignTokens\" && prop !== \"isDisabled\",\n})<{\n odysseyDesignTokens: DesignTokens;\n isDisabled?: boolean;\n}>(({ odysseyDesignTokens, isDisabled }) => ({\n display: \"flex\",\n alignItems: \"center\",\n cursor: isDisabled ? \"default\" : \"pointer\",\n pointerEvents: isDisabled ? \"none\" : \"auto\",\n color: `${isDisabled ? odysseyDesignTokens.TypographyColorDisabled : odysseyDesignTokens.TypographyColorHeading} !important`,\n \"& a\": {\n display: \"flex\",\n alignItems: \"center\",\n padding: `${odysseyDesignTokens.Spacing2} ${odysseyDesignTokens.Spacing4}`,\n color: `${odysseyDesignTokens.TypographyColorHeading} !important`,\n },\n \"& a:hover\": {\n textDecoration: \"none\",\n backgroundColor: !isDisabled ? odysseyDesignTokens.HueNeutral50 : \"inherit\",\n },\n \"& div[role='button']:hover\": {\n backgroundColor: !isDisabled ? odysseyDesignTokens.HueNeutral50 : \"inherit\",\n },\n \"& a:focus-visible\": {\n outlineOffset: 0,\n borderRadius: 0,\n outlineWidth: odysseyDesignTokens.FocusOutlineWidthMain,\n backgroundColor: !isDisabled ? odysseyDesignTokens.HueNeutral50 : \"inherit\",\n },\n}));\n\nconst NavItemContentClickContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n display: \"flex\",\n alignItems: \"center\",\n width: \"100%\",\n padding: `${odysseyDesignTokens.Spacing2} ${odysseyDesignTokens.Spacing4}`,\n \"&:focus-visible\": {\n borderRadius: 0,\n outlineColor: odysseyDesignTokens.FocusOutlineColorPrimary,\n outlineStyle: odysseyDesignTokens.FocusOutlineStyle,\n outlineWidth: odysseyDesignTokens.FocusOutlineWidthMain,\n backgroundColor: odysseyDesignTokens.HueNeutral50,\n textDecoration: \"none\",\n },\n}));\n\nconst TopNavItemContent = ({\n id,\n label,\n href,\n target,\n onClick,\n isDisabled,\n}: TopNavLinkItem) => {\n const odysseyDesignTokens = useOdysseyDesignTokens();\n\n const topNavItemContentKeyHandler = useCallback<\n KeyboardEventHandler<HTMLDivElement>\n >(\n (event) => {\n if (event?.key === \"Enter\") {\n event.preventDefault();\n event.stopPropagation();\n onClick?.(event);\n }\n },\n [onClick],\n );\n\n return (\n <TopNavListItemContainer\n id={id}\n key={id}\n aria-disabled={isDisabled}\n isDisabled={isDisabled}\n odysseyDesignTokens={odysseyDesignTokens}\n >\n {\n // Use Link for nav items with links and div for disabled or non-link items\n isDisabled ? (\n <NavItemContentClickContainer\n odysseyDesignTokens={odysseyDesignTokens}\n >\n <TopNavItemLabelContainer odysseyDesignTokens={odysseyDesignTokens}>\n {label}\n </TopNavItemLabelContainer>\n </NavItemContentClickContainer>\n ) : !href ? (\n <NavItemContentClickContainer\n odysseyDesignTokens={odysseyDesignTokens}\n role=\"button\"\n tabIndex={0}\n onClick={onClick}\n onKeyDown={topNavItemContentKeyHandler}\n >\n <TopNavItemLabelContainer odysseyDesignTokens={odysseyDesignTokens}>\n {label}\n </TopNavItemLabelContainer>\n </NavItemContentClickContainer>\n ) : (\n <Link href={href} target={target} onClick={onClick}>\n <TopNavItemLabelContainer odysseyDesignTokens={odysseyDesignTokens}>\n {label}\n </TopNavItemLabelContainer>\n </Link>\n )\n }\n </TopNavListItemContainer>\n );\n};\n\nconst LinkAndProfileWrapper = styled(\"div\")(() => ({\n display: \"flex\",\n alignItems: \"center\",\n marginLeft: \"auto\",\n}));\n\nconst AdditionalLinkContainerWithBorder = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n display: \"flex\",\n alignItems: \"center\",\n marginRight: odysseyDesignTokens.Spacing3,\n borderRight: `${odysseyDesignTokens.BorderWidthMain} solid ${odysseyDesignTokens.HueNeutral200}`,\n}));\n\nconst LinkContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n paddingRight: odysseyDesignTokens.Spacing3,\n \"& a\": {\n color: `${odysseyDesignTokens.TypographyColorHeading} !important`,\n },\n}));\n\nconst TopNavContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n display: \"flex\",\n alignItems: \"center\",\n backgroundColor: odysseyDesignTokens.HueNeutralWhite,\n height: odysseyDesignTokens[TOP_NAV_HEIGHT_TOKEN],\n}));\n\nconst SearchFieldContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n width: \"350px\",\n padding: `${odysseyDesignTokens.Spacing2} ${odysseyDesignTokens.Spacing3}`,\n}));\n\nconst AdditionalNavItemContainer = styled(\"div\", {\n shouldForwardProp: (prop) => prop !== \"odysseyDesignTokens\",\n})<{\n odysseyDesignTokens: DesignTokens;\n}>(({ odysseyDesignTokens }) => ({\n padding: `0 ${odysseyDesignTokens.Spacing3}`,\n}));\n\nconst TopNav = ({\n SearchFieldComponent,\n topNavLinkItems,\n AdditionalNavItemComponent,\n settingsPageHref,\n helpPageHref,\n userProfile,\n}: TopNavProps) => {\n const odysseyDesignTokens = useOdysseyDesignTokens();\n\n const processedNavItems = useMemo(\n () =>\n topNavLinkItems.map((item) => (\n <TopNavItemContent {...item} key={item.id} />\n )),\n [topNavLinkItems],\n );\n\n return (\n <TopNavContainer odysseyDesignTokens={odysseyDesignTokens}>\n {SearchFieldComponent && (\n <SearchFieldContainer odysseyDesignTokens={odysseyDesignTokens}>\n {SearchFieldComponent}\n </SearchFieldContainer>\n )}\n <TopNavListContainer>\n {processedNavItems?.map((item) => item)}\n </TopNavListContainer>\n <LinkAndProfileWrapper>\n {(AdditionalNavItemComponent || settingsPageHref || helpPageHref) && (\n <AdditionalLinkContainerWithBorder\n odysseyDesignTokens={odysseyDesignTokens}\n >\n {AdditionalNavItemComponent && (\n <AdditionalNavItemContainer\n odysseyDesignTokens={odysseyDesignTokens}\n >\n {AdditionalNavItemComponent}\n </AdditionalNavItemContainer>\n )}\n {settingsPageHref && (\n <LinkContainer odysseyDesignTokens={odysseyDesignTokens}>\n <Link href={settingsPageHref} ariaLabel=\"settings page\">\n <SettingsIcon />\n </Link>\n </LinkContainer>\n )}\n {helpPageHref && (\n <LinkContainer odysseyDesignTokens={odysseyDesignTokens}>\n <Link href={helpPageHref} ariaLabel=\"help page\">\n <QuestionCircleIcon />\n </Link>\n </LinkContainer>\n )}\n </AdditionalLinkContainerWithBorder>\n )}\n {userProfile && <UserProfile {...userProfile} />}\n </LinkAndProfileWrapper>\n </TopNavContainer>\n );\n};\n\nconst MemoizedTopNav = memo(TopNav);\nMemoizedTopNav.displayName = \"TopNav\";\n\nexport { MemoizedTopNav as TopNav };\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAOA,MAAM,MAAM,iBAAiB;AACpC,SACEC,IAAI,EACJC,OAAO,EAEPC,WAAW,QAGN,OAAO;AAAC,SAGNC,kBAAkB,EAAEC,YAAY;AAAA,SAChCC,IAAI;AAAA,SAGXC,sBAAsB;AAAA,S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iBAAiB,EAAEC,GAAG,CAAEC,IAAI,IAAKA,IAAI;IAAC,CACpB,CAAC,EACtBxF,KAAA,CAACiE,qBAAqB;MAAA7C,QAAA,GACnB,CAAC8D,0BAA0B,IAAIC,gBAAgB,IAAIC,YAAY,KAC9DpF,KAAA,CAACmE,iCAAiC;QAChC5D,mBAAmB,EAAEA,mBAAoB;QAAAa,QAAA,GAExC8D,0BAA0B,IACzBpF,IAAA,CAACgF,0BAA0B;UACzBvE,mBAAmB,EAAEA,mBAAoB;UAAAa,QAAA,EAExC8D;QAA0B,CACD,CAC7B,EACAC,gBAAgB,IACfrF,IAAA,CAAC2E,aAAa;UAAClE,mBAAmB,EAAEA,mBAAoB;UAAAa,QAAA,EACtDtB,IAAA,CAACJ,IAAI;YAAC4D,IAAI,EAAE6B,gBAAiB;YAACM,SAAS,EAAC,eAAe;YAAArE,QAAA,EACrDtB,IAAA,CAACL,YAAY,IAAE;UAAC,CACZ;QAAC,CACM,CAChB,EACA2F,YAAY,IACXtF,IAAA,CAAC2E,aAAa;UAAClE,mBAAmB,EAAEA,mBAAoB;UAAAa,QAAA,EACtDtB,IAAA,CAACJ,IAAI;YAAC4D,IAAI,EAAE8B,YAAa;YAACK,SAAS,EAAC,WAAW;YAAArE,QAAA,EAC7CtB,IAAA,CAACN,kBAAkB,IAAE;UAAC,CAClB;QAAC,CACM,CAChB;MAAA,CACgC,CACpC,EACA6F,WAAW,IAAIvF,IAAA,CAACkB,WAAW;QAAA,GAAKqE;MAAW,CAAG,CAAC;IAAA,CAC3B,CAAC;EAAA,CACT,CAAC;AAEtB,CAAC;AAED,MAAMK,cAAc,GAAGrG,IAAI,CAAC0F,MAAM,CAAC;AACnCW,cAAc,CAACC,WAAW,GAAG,QAAQ;AAErC,SAASD,cAAc,IAAIX,MAAM"}
@@ -12,20 +12,19 @@
12
12
 
13
13
  export { AdapterDateFns } from "@mui/x-date-pickers/AdapterDateFns";
14
14
  export { LocalizationProvider } from "@mui/x-date-pickers";
15
+ export * from "./AppTile.js";
15
16
  export * from "./DatePicker.js";
16
17
  export * from "./datePickerTheme.js";
17
- export * from "./DataComponents/index.js";
18
+ export * from "./DataView/index.js";
18
19
  export * from "./DataTablePagination.js";
19
20
  export * from "./DataFilters.js";
20
- export * from "./FileUpload.js";
21
21
  export * from "./Layout.js";
22
22
  export * from "./materialReactTableTypes.js";
23
23
  export * from "./StaticTable.js";
24
24
  export * from "./PageTemplate.js";
25
25
  export * from "./PaginatedTable.js";
26
26
  export * from "./GroupPicker.js";
27
- export * from "./Switch.js";
28
27
  export * from "./NavAccordion.js";
29
- export * from "./SideNav.js";
28
+ export * from "./SideNav/index.js";
30
29
  export * from "./TopNav.js";
31
30
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["AdapterDateFns","LocalizationProvider"],"sources":["../../src/labs/index.ts"],"sourcesContent":["/*!\n * Copyright (c) 2022-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nexport { AdapterDateFns } from \"@mui/x-date-pickers/AdapterDateFns\";\nexport { LocalizationProvider } from \"@mui/x-date-pickers\";\nexport type { LocalizationProviderProps } from \"@mui/x-date-pickers\";\n\nexport * from \"./DatePicker\";\nexport * from \"./datePickerTheme\";\n\nexport * from \"./DataComponents\";\n\n/** @deprecated Will be removed in a future Odyssey version in lieu of the one shipping with DataTable */\nexport * from \"./DataTablePagination\";\nexport * from \"./DataFilters\";\nexport * from \"./FileUpload\";\nexport * from \"./Layout\";\nexport * from \"./materialReactTableTypes\";\n/** @deprecated Will be removed in a future Odyssey version in lieu of DataTable */\nexport * from \"./StaticTable\";\nexport * from \"./PageTemplate\";\n/** @deprecated Will be removed in a future Odyssey version in lieu of DataTable */\nexport * from \"./PaginatedTable\";\n\nexport * from \"./GroupPicker\";\n\nexport * from \"./Switch\";\n\nexport * from \"./NavAccordion\";\nexport * from \"./SideNav\";\nexport * from \"./TopNav\";\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,SAASA,cAAc,QAAQ,oCAAoC;AACnE,SAASC,oBAAoB,QAAQ,qBAAqB;AAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA"}
1
+ {"version":3,"file":"index.js","names":["AdapterDateFns","LocalizationProvider"],"sources":["../../src/labs/index.ts"],"sourcesContent":["/*!\n * Copyright (c) 2022-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nexport { AdapterDateFns } from \"@mui/x-date-pickers/AdapterDateFns\";\nexport { LocalizationProvider } from \"@mui/x-date-pickers\";\nexport type { LocalizationProviderProps } from \"@mui/x-date-pickers\";\n\nexport * from \"./AppTile\";\n\nexport * from \"./DatePicker\";\nexport * from \"./datePickerTheme\";\n\nexport * from \"./DataView\";\n\n/** @deprecated Will be removed in a future Odyssey version in lieu of the one shipping with DataTable */\nexport * from \"./DataTablePagination\";\nexport * from \"./DataFilters\";\nexport * from \"./Layout\";\nexport * from \"./materialReactTableTypes\";\n/** @deprecated Will be removed in a future Odyssey version in lieu of DataTable */\nexport * from \"./StaticTable\";\nexport * from \"./PageTemplate\";\n/** @deprecated Will be removed in a future Odyssey version in lieu of DataTable */\nexport * from \"./PaginatedTable\";\n\nexport * from \"./GroupPicker\";\n\nexport * from \"./NavAccordion\";\nexport * from \"./SideNav\";\nexport * from \"./TopNav\";\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,SAASA,cAAc,QAAQ,oCAAoC;AACnE,SAASC,oBAAoB,QAAQ,qBAAqB;AAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA"}
@@ -32,7 +32,7 @@ export const useDateFieldsTranslations = () => {
32
32
  empty: `${t("picker.labels.empty")}`,
33
33
  end: `${t("picker.labels.range.end")}`,
34
34
  endDate: `${t("picker.labels.range.enddate")}`,
35
- endTime: `${t("picker.labels.range.endTime")}`,
35
+ endTime: `${t("picker.labels.range.endtime")}`,
36
36
  fieldClearLabel: `${t("picker.labels.field.clear")}`,
37
37
  fieldDayPlaceholder: () => `${t("picker.field.placeholder.day")}`,
38
38
  fieldMonthPlaceholder: () => `${t("picker.field.placeholder.month")}`,
@@ -1 +1 @@
1
- {"version":3,"file":"useDateFieldsTranslations.js","names":["useTranslation","useDateFieldsTranslations","t","calendarViewSwitchingButtonAriaLabel","view","calendarWeekNumberHeaderLabel","calendarWeekNumberHeaderText","calendarWeekNumberAriaLabelText","calendarWeekNumberText","cancelButtonLabel","clearButtonLabel","clockLabelText","time","adapter","format","datePickerToolbarTitle","dateRangePickerToolbarTitle","dateTableLabel","dateTimePickerToolbarTitle","day","empty","end","endDate","endTime","fieldClearLabel","fieldDayPlaceholder","fieldMonthPlaceholder","fieldYearPlaceholder","fieldHoursPlaceholder","fieldMinutesPlaceholder","fieldSecondsPlaceholder","fieldMeridiemPlaceholder","fieldWeekDayPlaceholder","hours","hoursClockNumberText","meridiem","minutes","minutesClockNumberText","month","nextMonth","okButtonLabel","openDatePickerDialogue","value","utils","isValid","openNextView","openPreviousView","openTimePickerDialogue","previousMonth","seconds","secondsClockNumberText","selectViewText","start","startDate","startTime","todayButtonLabel","timePickerToolbarTitle","timeTableLabel","weekDay","year"],"sources":["../../src/labs/useDateFieldsTranslations.ts"],"sourcesContent":["/*!\n * Copyright (c) 2024-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nimport { PickersLocaleText } from \"@mui/x-date-pickers\";\nimport { DateTime } from \"luxon\";\nimport { useTranslation } from \"react-i18next\";\n\nexport type DateFieldsTranslations = PickersLocaleText<DateTime>;\n\nexport const useDateFieldsTranslations = (): DateFieldsTranslations => {\n const { t } = useTranslation();\n\n return {\n calendarViewSwitchingButtonAriaLabel: (view) =>\n view === \"year\"\n ? `${t(\"picker.view.navigation.switch.calendarview\")}`\n : `${t(\"picker.view.navigation.switch.yearview\")}`,\n // not translated because we aren't using it\n calendarWeekNumberHeaderLabel: \"\",\n calendarWeekNumberHeaderText: \"\",\n calendarWeekNumberAriaLabelText: () => \"\",\n calendarWeekNumberText: () => \"\",\n\n cancelButtonLabel: `${t(\"picker.labels.action.cancel\")}`,\n clearButtonLabel: `${t(\"clear.text\")}`,\n clockLabelText: (view, time, adapter) =>\n `${t(\"picker.labels.select\")} ${view}. ${\n time === null\n ? `${t(\"picker.labels.clock.empty\")}`\n : `${t(\"picker.labels.clock.selected\")} ${adapter.format(time, \"fullTime\")}`\n }`,\n datePickerToolbarTitle: `${t(\"picker.date.toolbar.title\")}`,\n dateRangePickerToolbarTitle: `${t(\"picker.daterange.toolbar.title\")}`,\n dateTableLabel: `${t(\"picker.labels.table.date\")}`,\n dateTimePickerToolbarTitle: `${t(\"picker.datetime.toolbar.title\")}`,\n day: `${t(\"picker.view.name.day\")}`,\n empty: `${t(\"picker.labels.empty\")}`,\n end: `${t(\"picker.labels.range.end\")}`,\n endDate: `${t(\"picker.labels.range.enddate\")}`,\n endTime: `${t(\"picker.labels.range.endTime\")}`,\n fieldClearLabel: `${t(\"picker.labels.field.clear\")}`,\n fieldDayPlaceholder: () => `${t(\"picker.field.placeholder.day\")}`,\n fieldMonthPlaceholder: () => `${t(\"picker.field.placeholder.month\")}`,\n fieldYearPlaceholder: () => `${t(\"picker.field.placeholder.year\")}`,\n fieldHoursPlaceholder: () => `${t(\"picker.field.placeholder.hours\")}`,\n fieldMinutesPlaceholder: () => `${t(\"picker.field.placeholder.minutes\")}`,\n fieldSecondsPlaceholder: () => `${t(\"picker.field.placeholder.seconds\")}`,\n fieldMeridiemPlaceholder: () => `${t(\"picker.field.placeholder.meridiem\")}`,\n // not translated because we aren't using it\n fieldWeekDayPlaceholder: () => \"\",\n hours: `${t(\"picker.view.name.hours\")}`,\n hoursClockNumberText: (hours) =>\n `${hours} ${t(\"picker.labels.clock.hours\")}`,\n meridiem: `${t(\"picker.view.name.meridiem\")}`,\n minutes: `${t(\"picker.view.name.minutes\")}`,\n minutesClockNumberText: (minutes) =>\n `${minutes} ${t(\"picker.labels.clock.minutes\")}`,\n month: `${t(\"picker.view.name.month\")}`,\n nextMonth: `${t(\"picker.calendar.navigation.nextmonth\")}`,\n okButtonLabel: `${t(\"picker.labels.action.apply\")}`,\n openDatePickerDialogue: (value, utils) =>\n value !== null && utils.isValid(value)\n ? `${t(\"picker.labels.date.choose\")}, ${t(\"picker.labels.date.selected\")} ${utils.format(value, \"fullDate\")}`\n : `${t(\"picker.labels.date.choose\")}`,\n openNextView: `${t(\"picker.view.navigation.open.nextview\")}`,\n openPreviousView: `${t(\"picker.view.navigation.open.previousview\")}`,\n openTimePickerDialogue: (value, utils) =>\n value !== null && utils.isValid(value)\n ? `${t(\"picker.labels.time.choose\")}, ${t(\"picker.labels.time.selected\")} ${utils.format(value, \"fullTime\")}`\n : `${t(\"picker.labels.time.choose\")}`,\n previousMonth: `${t(\"picker.calendar.navigation.previousmonth\")}`,\n seconds: `${t(\"picker.view.name.seconds\")}`,\n secondsClockNumberText: (seconds) =>\n `${seconds} ${t(\"picker.labels.clock.seconds\")}`,\n selectViewText: (view) => `${t(\"picker.labels.select\")} ${view}`,\n start: `${t(\"picker.labels.range.start\")}`,\n startDate: `${t(\"picker.labels.range.startdate\")}`,\n startTime: `${t(\"picker.labels.range.starttime\")}`,\n todayButtonLabel: `${t(\"picker.labels.action.today\")}`,\n timePickerToolbarTitle: `${t(\"picker.time.toolbar.title\")}`,\n timeTableLabel: `${t(\"picker.labels.table.time\")}`,\n weekDay: `${t(\"picker.view.name.weekday\")}`,\n year: `${t(\"picker.view.name.year\")}`,\n };\n};\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAIA,SAASA,cAAc,QAAQ,eAAe;AAI9C,OAAO,MAAMC,yBAAyB,GAAGA,CAAA,KAA8B;EACrE,MAAM;IAAEC;EAAE,CAAC,GAAGF,cAAc,CAAC,CAAC;EAE9B,OAAO;IACLG,oCAAoC,EAAGC,IAAI,IACzCA,IAAI,KAAK,MAAM,GACV,GAAEF,CAAC,CAAC,4CAA4C,CAAE,EAAC,GACnD,GAAEA,CAAC,CAAC,wCAAwC,CAAE,EAAC;IAEtDG,6BAA6B,EAAE,EAAE;IACjCC,4BAA4B,EAAE,EAAE;IAChCC,+BAA+B,EAAEA,CAAA,KAAM,EAAE;IACzCC,sBAAsB,EAAEA,CAAA,KAAM,EAAE;IAEhCC,iBAAiB,EAAG,GAAEP,CAAC,CAAC,6BAA6B,CAAE,EAAC;IACxDQ,gBAAgB,EAAG,GAAER,CAAC,CAAC,YAAY,CAAE,EAAC;IACtCS,cAAc,EAAEA,CAACP,IAAI,EAAEQ,IAAI,EAAEC,OAAO,KACjC,GAAE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KAAK,IAAI,IAAIC,KAAK,CAACC,OAAO,CAACF,KAAK,CAAC,GACjC,GAAExC,CAAC,CAAC,2BAA2B,CAAE,KAAIA,CAAC,CAAC,6BAA6B,CAAE,IAAGyC,KAAK,CAAC7B,MAAM,CAAC4B,KAAK,EAAE,UAAU,CAAE,EAAC,GAC1G,GAAExC,CAAC,CAAC,2BAA2B,CAAE,EAAC;IACzC8C,aAAa,EAAG,GAAE9C,CAAC,CAAC,0CAA0C,CAAE,EAAC;IACjE+C,OAAO,EAAG,GAAE/C,CAAC,CAAC,0BAA0B,CAAE,EAAC;IAC3CgD,sBAAsB,EAAGD,OAAO,IAC7B,GAAEA,OAAQ,IAAG/C,CAAC,CAAC,6BAA6B,CAAE,EAAC;IAClDiD,cAAc,EAAG/C,IAAI,IAAM,GAAEF,CAAC,CAAC,sBAAsB,CAAE,IAAGE,IAAK,EAAC;IAChEgD,KAAK,EAAG,GAAElD,CAAC,CAAC,2BAA2B,CAAE,EAAC;IAC1CmD,SAAS,EAAG,GAAEnD,CAAC,CAAC,+BAA+B,CAAE,EAAC;IAClDoD,SAAS,EAAG,GAAEpD,CAAC,CAAC,+BAA+B,CAAE,EAAC;IAClDqD,gBAAgB,EAAG,GAAErD,CAAC,CAAC,4BAA4B,CAAE,EAAC;IACtDsD,sBAAsB,EAAG,GAAEtD,CAAC,CAAC,2BAA2B,CAAE,EAAC;IAC3DuD,cAAc,EAAG,GAAEvD,CAAC,CAAC,0BAA0B,CAAE,EAAC;IAClDwD,OAAO,EAAG,GAAExD,CAAC,CAAC,0BAA0B,CAAE,EAAC;IAC3CyD,IAAI,EAAG,GAAEzD,CAAC,CAAC,uBAAuB,CAAE;EACtC,CAAC;AACH,CAAC"}
1
+ {"version":3,"file":"useDateFieldsTranslations.js","names":["useTranslation","useDateFieldsTranslations","t","calendarViewSwitchingButtonAriaLabel","view","calendarWeekNumberHeaderLabel","calendarWeekNumberHeaderText","calendarWeekNumberAriaLabelText","calendarWeekNumberText","cancelButtonLabel","clearButtonLabel","clockLabelText","time","adapter","format","datePickerToolbarTitle","dateRangePickerToolbarTitle","dateTableLabel","dateTimePickerToolbarTitle","day","empty","end","endDate","endTime","fieldClearLabel","fieldDayPlaceholder","fieldMonthPlaceholder","fieldYearPlaceholder","fieldHoursPlaceholder","fieldMinutesPlaceholder","fieldSecondsPlaceholder","fieldMeridiemPlaceholder","fieldWeekDayPlaceholder","hours","hoursClockNumberText","meridiem","minutes","minutesClockNumberText","month","nextMonth","okButtonLabel","openDatePickerDialogue","value","utils","isValid","openNextView","openPreviousView","openTimePickerDialogue","previousMonth","seconds","secondsClockNumberText","selectViewText","start","startDate","startTime","todayButtonLabel","timePickerToolbarTitle","timeTableLabel","weekDay","year"],"sources":["../../src/labs/useDateFieldsTranslations.ts"],"sourcesContent":["/*!\n * Copyright (c) 2024-present, Okta, Inc. and/or its affiliates. All rights reserved.\n * The Okta software accompanied by this notice is provided pursuant to the Apache License, Version 2.0 (the \"License.\")\n *\n * You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0.\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n *\n * See the License for the specific language governing permissions and limitations under the License.\n */\n\nimport { PickersLocaleText } from \"@mui/x-date-pickers\";\nimport { DateTime } from \"luxon\";\nimport { useTranslation } from \"react-i18next\";\n\nexport type DateFieldsTranslations = PickersLocaleText<DateTime>;\n\nexport const useDateFieldsTranslations = (): DateFieldsTranslations => {\n const { t } = useTranslation();\n\n return {\n calendarViewSwitchingButtonAriaLabel: (view) =>\n view === \"year\"\n ? `${t(\"picker.view.navigation.switch.calendarview\")}`\n : `${t(\"picker.view.navigation.switch.yearview\")}`,\n // not translated because we aren't using it\n calendarWeekNumberHeaderLabel: \"\",\n calendarWeekNumberHeaderText: \"\",\n calendarWeekNumberAriaLabelText: () => \"\",\n calendarWeekNumberText: () => \"\",\n\n cancelButtonLabel: `${t(\"picker.labels.action.cancel\")}`,\n clearButtonLabel: `${t(\"clear.text\")}`,\n clockLabelText: (view, time, adapter) =>\n `${t(\"picker.labels.select\")} ${view}. ${\n time === null\n ? `${t(\"picker.labels.clock.empty\")}`\n : `${t(\"picker.labels.clock.selected\")} ${adapter.format(time, \"fullTime\")}`\n }`,\n datePickerToolbarTitle: `${t(\"picker.date.toolbar.title\")}`,\n dateRangePickerToolbarTitle: `${t(\"picker.daterange.toolbar.title\")}`,\n dateTableLabel: `${t(\"picker.labels.table.date\")}`,\n dateTimePickerToolbarTitle: `${t(\"picker.datetime.toolbar.title\")}`,\n day: `${t(\"picker.view.name.day\")}`,\n empty: `${t(\"picker.labels.empty\")}`,\n end: `${t(\"picker.labels.range.end\")}`,\n endDate: `${t(\"picker.labels.range.enddate\")}`,\n endTime: `${t(\"picker.labels.range.endtime\")}`,\n fieldClearLabel: `${t(\"picker.labels.field.clear\")}`,\n fieldDayPlaceholder: () => `${t(\"picker.field.placeholder.day\")}`,\n fieldMonthPlaceholder: () => `${t(\"picker.field.placeholder.month\")}`,\n fieldYearPlaceholder: () => `${t(\"picker.field.placeholder.year\")}`,\n fieldHoursPlaceholder: () => `${t(\"picker.field.placeholder.hours\")}`,\n fieldMinutesPlaceholder: () => `${t(\"picker.field.placeholder.minutes\")}`,\n fieldSecondsPlaceholder: () => `${t(\"picker.field.placeholder.seconds\")}`,\n fieldMeridiemPlaceholder: () => `${t(\"picker.field.placeholder.meridiem\")}`,\n // not translated because we aren't using it\n fieldWeekDayPlaceholder: () => \"\",\n hours: `${t(\"picker.view.name.hours\")}`,\n hoursClockNumberText: (hours) =>\n `${hours} ${t(\"picker.labels.clock.hours\")}`,\n meridiem: `${t(\"picker.view.name.meridiem\")}`,\n minutes: `${t(\"picker.view.name.minutes\")}`,\n minutesClockNumberText: (minutes) =>\n `${minutes} ${t(\"picker.labels.clock.minutes\")}`,\n month: `${t(\"picker.view.name.month\")}`,\n nextMonth: `${t(\"picker.calendar.navigation.nextmonth\")}`,\n okButtonLabel: `${t(\"picker.labels.action.apply\")}`,\n openDatePickerDialogue: (value, utils) =>\n value !== null && utils.isValid(value)\n ? `${t(\"picker.labels.date.choose\")}, ${t(\"picker.labels.date.selected\")} ${utils.format(value, \"fullDate\")}`\n : `${t(\"picker.labels.date.choose\")}`,\n openNextView: `${t(\"picker.view.navigation.open.nextview\")}`,\n openPreviousView: `${t(\"picker.view.navigation.open.previousview\")}`,\n openTimePickerDialogue: (value, utils) =>\n value !== null && utils.isValid(value)\n ? `${t(\"picker.labels.time.choose\")}, ${t(\"picker.labels.time.selected\")} ${utils.format(value, \"fullTime\")}`\n : `${t(\"picker.labels.time.choose\")}`,\n previousMonth: `${t(\"picker.calendar.navigation.previousmonth\")}`,\n seconds: `${t(\"picker.view.name.seconds\")}`,\n secondsClockNumberText: (seconds) =>\n `${seconds} ${t(\"picker.labels.clock.seconds\")}`,\n selectViewText: (view) => `${t(\"picker.labels.select\")} ${view}`,\n start: `${t(\"picker.labels.range.start\")}`,\n startDate: `${t(\"picker.labels.range.startdate\")}`,\n startTime: `${t(\"picker.labels.range.starttime\")}`,\n todayButtonLabel: `${t(\"picker.labels.action.today\")}`,\n timePickerToolbarTitle: `${t(\"picker.time.toolbar.title\")}`,\n timeTableLabel: `${t(\"picker.labels.table.time\")}`,\n weekDay: `${t(\"picker.view.name.weekday\")}`,\n year: `${t(\"picker.view.name.year\")}`,\n };\n};\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAIA,SAASA,cAAc,QAAQ,eAAe;AAI9C,OAAO,MAAMC,yBAAyB,GAAGA,CAAA,KAA8B;EACrE,MAAM;IAAEC;EAAE,CAAC,GAAGF,cAAc,CAAC,CAAC;EAE9B,OAAO;IACLG,oCAAoC,EAAGC,IAAI,IACzCA,IAAI,KAAK,MAAM,GACV,GAAEF,CAAC,CAAC,4CAA4C,CAAE,EAAC,GACnD,GAAEA,CAAC,CAAC,wCAAwC,CA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C,CAAC,0BAA0B,CAAE,EAAC;IAClDwD,OAAO,EAAG,GAAExD,CAAC,CAAC,0BAA0B,CAAE,EAAC;IAC3CyD,IAAI,EAAG,GAAEzD,CAAC,CAAC,uBAAuB,CAAE;EACtC,CAAC;AACH,CAAC"}
@@ -24,7 +24,8 @@ export const translation = {
24
24
  "picker.labels.action.today": "Today",
25
25
  "picker.labels.clock.empty": "No time selected",
26
26
  "picker.labels.clock.hours": "hours",
27
- "picker.labels.clock.minutes": "seconds",
27
+ "picker.labels.clock.minutes": "minutes",
28
+ "picker.labels.clock.seconds": "seconds",
28
29
  "picker.labels.clock.selected": "Selected time is",
29
30
  "picker.labels.date.choose": "Choose date",
30
31
  "picker.labels.date.selected": "Selected date is",
@@ -40,6 +41,7 @@ export const translation = {
40
41
  "picker.labels.table.date": "pick date",
41
42
  "picker.labels.table.time": "pick time",
42
43
  "picker.labels.time.choose": "Choose time",
44
+ "picker.labels.time.selected": "selected time is",
43
45
  "picker.time.toolbar.title": "Select time",
44
46
  "picker.view.name.day": "Day",
45
47
  "picker.view.name.hours": "Hours",
@@ -1 +1 @@
1
- {"version":3,"file":"odyssey-react-mui.js","names":["translation"],"sources":["../../../src/properties/ts/odyssey-react-mui.ts"],"sourcesContent":["export const translation = {\"breadcrumbs.home.text\":\"Home\",\"breadcrumbs.label.text\":\"Breadcrumbs\",\"close.text\":\"Close\",\"clear.text\":\"Clear\",\"open.text\":\"Open\",\"picker.calendar.navigation.nextmonth\":\"Next month\",\"picker.calendar.navigation.previousmonth\":\"Previous month\",\"picker.date.toolbar.title\":\"Selected date\",\"picker.daterange.toolbar.title\":\"Select date range\",\"picker.datetime.toolbar.title\":\"Select date & time\",\"picker.error.invalid\":\"Correct the date format or select the date from the calendar.\",\"picker.error.mindate\":\"Date entered is earlier than allowed dates. Select a date from the range available in the calendar.\",\"picker.error.maxdate\":\"Date entered is later than the allowed dates. Select a date from the range available in the calendar.\",\"picker.field.placeholder.day\":\"DD\",\"picker.field.placeholder.hours\":\"hh\",\"picker.field.placeholder.meridiem\":\"aa\",\"picker.field.placeholder.minutes\":\"mm\",\"picker.field.placeholder.month\":\"MM\",\"picker.field.placeholder.seconds\":\"ss\",\"picker.field.placeholder.year\":\"YYYY\",\"picker.labels.action.apply\":\"Apply\",\"picker.labels.action.cancel\":\"Cancel\",\"picker.labels.action.today\":\"Today\",\"picker.labels.clock.empty\":\"No time selected\",\"picker.labels.clock.hours\":\"hours\",\"picker.labels.clock.minutes\":\"seconds\",\"picker.labels.clock.selected\":\"Selected time is\",\"picker.labels.date.choose\":\"Choose date\",\"picker.labels.date.selected\":\"Selected date is\",\"picker.labels.empty\":\"Empty\",\"picker.labels.field.clear\":\"Clear value\",\"picker.labels.range.end\":\"End\",\"picker.labels.range.enddate\":\"End date\",\"picker.labels.range.endtime\":\"End time\",\"picker.labels.range.start\":\"Start\",\"picker.labels.range.startdate\":\"Start date\",\"picker.labels.range.starttime\":\"Start time\",\"picker.labels.select\":\"Select\",\"picker.labels.table.date\":\"pick date\",\"picker.labels.table.time\":\"pick time\",\"picker.labels.time.choose\":\"Choose time\",\"picker.time.toolbar.title\":\"Select time\",\"picker.view.name.day\":\"Day\",\"picker.view.name.hours\":\"Hours\",\"picker.view.name.meridiem\":\"Meridiem\",\"picker.view.name.minutes\":\"Minutes\",\"picker.view.name.month\":\"Month\",\"picker.view.name.seconds\":\"Seconds\",\"picker.view.name.weekday\":\"Week day\",\"picker.view.name.year\":\"Year\",\"picker.view.navigation.open.nextview\":\"Open next view\",\"picker.view.navigation.open.previousview\":\"Open previous view\",\"picker.view.navigation.switch.calendarview\":\"year view is open, switch to calendar view\",\"picker.view.navigation.switch.yearview\":\"calendar view is open, switch to year view\",\"fielderror.screenreader.text\":\"Error\",\"fieldlabel.optional.text\":\"Optional\",\"fieldlabel.required.text\":\"Required\",\"filters.clear.label\":\"Clear filters\",\"filters.filter.any\":\"Any\",\"filters.filter.clear\":\"Clear filter\",\"filters.filters.arialabel\":\"Filters\",\"filters.menuitem.any\":\"Any {{label}}\",\"filters.menuitem.selected\":\"{{selected}} selected\",\"filters.search.label\":\"Search\",\"fileupload.button.text\":\"Add files\",\"fileupload.prompt.text\":\"Drag and drop files here or click to add files\",\"fileupload.removefile.text\":\"Remove file\",\"passwordfield.icon.label.hide\":\"Hide password\",\"passwordfield.icon.label.show\":\"Show password\",\"severity.error\":\"error\",\"severity.info\":\"info\",\"severity.success\":\"success\",\"severity.warning\":\"warning\",\"switch.active\":\"Active\",\"switch.inactive\":\"Inactive\",\"table.columnvisibility.arialabel\":\"Show/hide columns\",\"table.density.arialabel\":\"Table density\",\"table.draghandle.arialabel\":\"Drag row to reorder. Or, press space or enter to start and stop reordering and esc to cancel.\",\"table.draghandle.tooltip\":\"Drag row or press space/enter key to start and stop reordering\",\"table.actions\":\"Actions\",\"table.error\":\"Error loading data.\",\"table.fetchedrows.text\":\"Fetched {{totalRows}} row\",\"table.fetchedrows.text_plural\":\"Fetched {{totalRows}} total rows\",\"table.moreactions.arialabel\":\"More actions\",\"table.noresults.heading\":\"There are no results.\",\"table.noresults.text\":\"Try a different query.\",\"table.reorder.backward\":\"Send backward\",\"table.reorder.forward\":\"Bring forward\",\"table.reorder.toback\":\"Send to back\",\"table.reorder.tofront\":\"Bring to front\",\"table.rows.text\":\"{{totalRows}} row\",\"table.rows.text_plural\":\"{{totalRows}} rows\",\"pagination.loadmore\":\"Show more\",\"pagination.next\":\"Next page\",\"pagination.previous\":\"Previous page\",\"pagination.page\":\"Page\",\"pagination.rowsperpage\":\"Rows per page\",\"pagination.rowswithtotal\":\"{{firstRow}}-{{lastRow}} of {{totalRows}} rows\",\"pagination.rowswithouttotal\":\"{{firstRow}}-{{lastRow}} rows\",\"table.actions.selectall\":\"Select all\",\"table.actions.selectnone\":\"Select none\",\"table.actions.selectsome\":\"{{selectedRowCount}} selected\",\"table.rowexpansion.expand\":\"Expand\",\"table.rowexpansion.expandall\":\"Expand all\",\"table.rowexpansion.collapse\":\"Collapse\",\"table.rowexpansion.coll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,eAAe;EAAC,uBAAuB,EAAC,eAAe;EAAC,sBAAsB,EAAC,cAAc;EAAC,uBAAuB,EAAC,gBAAgB;EAAC,iBAAiB,EAAC,mBAAmB;EAAC,wBAAwB,EAAC,oBAAoB;EAAC,qBAAqB,EAAC,WAAW;EAAC,iBAAiB,EAAC,WAAW;EAAC,qBAAqB,EAAC,eAAe;EAAC,iBAAiB,EAAC,MAAM;EAAC,wBAAwB,EAAC,eAAe;EAAC,0BAA0B,EAAC,gDAAgD;EAAC,6BAA6B,EAAC,+BAA+B;EAAC,yBAAyB,EAAC,YAAY;EAAC,0BAA0B,EAAC,aAAa;EAAC,0BAA0B,EAAC,+BAA+B;EAAC,2BAA2B,EAAC,QAAQ;EAAC,8BAA8B,EAAC,YAAY;EAAC,6BAA6B,EAAC,UAAU;EAAC,gCAAgC,EAAC,cAAc;EAAC,uBAAuB,EAAC,OAAO;EAAC,sBAAsB,EAAC,MAAM;EAAC,sBAAsB,EAAC;AAAM,CAAC"}
1
+ {"version":3,"file":"odyssey-react-mui.js","names":["translation"],"sources":["../../../src/properties/ts/odyssey-react-mui.ts"],"sourcesContent":["export const translation = {\"breadcrumbs.home.text\":\"Home\",\"breadcrumbs.label.text\":\"Breadcrumbs\",\"close.text\":\"Close\",\"clear.text\":\"Clear\",\"open.text\":\"Open\",\"picker.calendar.navigation.nextmonth\":\"Next month\",\"picker.calendar.navigation.previousmonth\":\"Previous month\",\"picker.date.toolbar.title\":\"Selected date\",\"picker.daterange.toolbar.title\":\"Select date range\",\"picker.datetime.toolbar.title\":\"Select date & time\",\"picker.error.invalid\":\"Correct the date format or select the date from the calendar.\",\"picker.error.mindate\":\"Date entered is earlier than allowed dates. Select a date from the range available in the calendar.\",\"picker.error.maxdate\":\"Date entered is later than the allowed dates. Select a date from the range available in the calendar.\",\"picker.field.placeholder.day\":\"DD\",\"picker.field.placeholder.hours\":\"hh\",\"picker.field.placeholder.meridiem\":\"aa\",\"picker.field.placeholder.minutes\":\"mm\",\"picker.field.placeholder.month\":\"MM\",\"picker.field.placeholder.seconds\":\"ss\",\"picker.field.placeholder.year\":\"YYYY\",\"picker.labels.action.apply\":\"Apply\",\"picker.labels.action.cancel\":\"Cancel\",\"picker.labels.action.today\":\"Today\",\"picker.labels.clock.empty\":\"No time selected\",\"picker.labels.clock.hours\":\"hours\",\"picker.labels.clock.minutes\":\"minutes\",\"picker.labels.clock.seconds\":\"seconds\",\"picker.labels.clock.selected\":\"Selected time is\",\"picker.labels.date.choose\":\"Choose date\",\"picker.labels.date.selected\":\"Selected date is\",\"picker.labels.empty\":\"Empty\",\"picker.labels.field.clear\":\"Clear value\",\"picker.labels.range.end\":\"End\",\"picker.labels.range.enddate\":\"End date\",\"picker.labels.range.endtime\":\"End time\",\"picker.labels.range.start\":\"Start\",\"picker.labels.range.startdate\":\"Start date\",\"picker.labels.range.starttime\":\"Start time\",\"picker.labels.select\":\"Select\",\"picker.labels.table.date\":\"pick date\",\"picker.labels.table.time\":\"pick time\",\"picker.labels.time.choose\":\"Choose time\",\"picker.labels.time.selected\":\"selected time is\",\"picker.time.toolbar.title\":\"Select time\",\"picker.view.name.day\":\"Day\",\"picker.view.name.hours\":\"Hours\",\"picker.view.name.meridiem\":\"Meridiem\",\"picker.view.name.minutes\":\"Minutes\",\"picker.view.name.month\":\"Month\",\"picker.view.name.seconds\":\"Seconds\",\"picker.view.name.weekday\":\"Week day\",\"picker.view.name.year\":\"Year\",\"picker.view.navigation.open.nextview\":\"Open next view\",\"picker.view.navigation.open.previousview\":\"Open previous view\",\"picker.view.navigation.switch.calendarview\":\"year view is open, switch to calendar view\",\"picker.view.navigation.switch.yearview\":\"calendar view is open, switch to year view\",\"fielderror.screenreader.text\":\"Error\",\"fieldlabel.optional.text\":\"Optional\",\"fieldlabel.required.text\":\"Required\",\"filters.clear.label\":\"Clear filters\",\"filters.filter.any\":\"Any\",\"filters.filter.clear\":\"Clear filter\",\"filters.filters.arialabel\":\"Filters\",\"filters.menuitem.any\":\"Any {{label}}\",\"filters.menuitem.selected\":\"{{selected}} selected\",\"filters.search.label\":\"Search\",\"fileupload.button.text\":\"Add files\",\"fileupload.prompt.text\":\"Drag and drop files here or click to add files\",\"fileupload.removefile.text\":\"Remove file\",\"passwordfield.icon.label.hide\":\"Hide password\",\"passwordfield.icon.label.show\":\"Show password\",\"severity.error\":\"error\",\"severity.info\":\"info\",\"severity.success\":\"success\",\"severity.warning\":\"warning\",\"switch.active\":\"Active\",\"switch.inactive\":\"Inactive\",\"table.columnvisibility.arialabel\":\"Show/hide columns\",\"table.density.arialabel\":\"Table density\",\"table.draghandle.arialabel\":\"Drag row to reorder. Or, press space or enter to start and stop reordering and esc to cancel.\",\"table.draghandle.tooltip\":\"Drag row or press space/enter key to start and stop reordering\",\"table.actions\":\"Actions\",\"table.error\":\"Error loading data.\",\"table.fetchedrows.text\":\"Fetched {{totalRows}} row\",\"table.fetchedrows.text_plural\":\"Fetched {{totalRows}} total rows\",\"table.moreactions.arialabel\":\"More actions\",\"table.noresults.heading\":\"There are no results.\",\"table.noresults.text\":\"Try a different query.\",\"table.reorder.backward\":\"Send backward\",\"table.reorder.forward\":\"Bring forward\",\"table.reorder.toback\":\"Send to back\",\"table.reorder.tofront\":\"Bring to front\",\"table.rows.text\":\"{{totalRows}} row\",\"table.rows.text_plural\":\"{{totalRows}} rows\",\"pagination.loadmore\":\"Show more\",\"pagination.next\":\"Next page\",\"pagination.previous\":\"Previous page\",\"pagination.page\":\"Page\",\"pagination.rowsperpage\":\"Rows per page\",\"pagination.rowswithtotal\":\"{{firstRow}}-{{lastRow}} of {{totalRows}} rows\",\"pagination.rowswithouttotal\":\"{{firstRow}}-{{lastRow}} rows\",\"table.actions.selectall\":\"Select all\",\"table.actions.selectnone\":\"Select none\",\"table.actions.selectsome\":\"{{selectedRowCount}} selected\",\"table.rowexpansion.expand\":\"Expand\",\"table.rowexpansion.expandall\":\"Expand all\",\"table.rowexpansion.collapse\":\"Collapse\",\"table.rowexpansion.collapseall\":\"Collapse all\",\"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