@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
package/src/Callout.tsx CHANGED
@@ -20,46 +20,34 @@ import {
20
20
  DesignTokens,
21
21
  useOdysseyDesignTokens,
22
22
  } from "./OdysseyDesignTokensContext";
23
- import { type FeatureTestSelector } from "./test-selectors";
23
+ import { type TestSelector } from "./test-selectors";
24
24
  import { Paragraph } from "./Typography";
25
25
  import { useUniqueId } from "./useUniqueId";
26
26
 
27
- export const CalloutTestSelectors = {
28
- feature: {
27
+ export const CalloutTestSelector = {
28
+ accessibleText: {
29
+ text: "description",
30
+ title: "label",
31
+ },
32
+ children: {
29
33
  link: {
30
- selector: {
34
+ elementSelector: {
31
35
  method: "ByRole",
32
36
  options: {
33
- name: "${linkText}",
37
+ linkText: "name",
34
38
  },
35
39
  role: "link",
36
- templateVariableNames: ["linkText"],
37
- },
38
- },
39
- text: {
40
- selector: {
41
- method: "ByText",
42
- templateVariableNames: ["text"],
43
- text: "${text}",
44
- },
45
- },
46
- title: {
47
- selector: {
48
- method: "ByText",
49
- templateVariableNames: ["title"],
50
- text: "${title}",
51
40
  },
52
41
  },
53
42
  },
54
- selector: {
43
+ elementSelector: {
55
44
  method: "ByRole",
56
45
  options: {
57
- name: "${title}",
46
+ title: "name",
58
47
  },
59
- role: "${role}",
60
- templateVariableNames: ["role", "title"],
48
+ role: ["alert", "status"],
61
49
  },
62
- } as const satisfies FeatureTestSelector;
50
+ } as const satisfies TestSelector;
63
51
 
64
52
  export const calloutRoleValues = ["status", "alert"] as const;
65
53
  export const calloutSeverityValues = [
package/src/Checkbox.tsx CHANGED
@@ -61,7 +61,10 @@ export type CheckboxProps = {
61
61
  * Callback fired when the blur event happens. Provides event value.
62
62
  */
63
63
  onBlur?: MuiFormControlLabelProps["onBlur"];
64
- } & Pick<FieldComponentProps, "hint" | "id" | "isDisabled" | "name"> &
64
+ } & Pick<
65
+ FieldComponentProps,
66
+ "hint" | "id" | "isDisabled" | "isReadOnly" | "name"
67
+ > &
65
68
  CheckedFieldProps<MuiCheckboxProps> &
66
69
  Pick<HtmlProps, "ariaLabel" | "ariaLabelledBy" | "testId" | "translate">;
67
70
 
@@ -74,6 +77,7 @@ const Checkbox = ({
74
77
  isDefaultChecked,
75
78
  isDisabled,
76
79
  isIndeterminate,
80
+ isReadOnly = false,
77
81
  isRequired,
78
82
  label: labelProp,
79
83
  hint,
@@ -102,13 +106,11 @@ const Checkbox = ({
102
106
  const localInputRef = useRef<HTMLInputElement>(null);
103
107
  useImperativeHandle(
104
108
  inputRef,
105
- () => {
106
- return {
107
- focus: () => {
108
- localInputRef.current?.focus();
109
- },
110
- };
111
- },
109
+ () => ({
110
+ focus: () => {
111
+ localInputRef.current?.focus();
112
+ },
113
+ }),
112
114
  [],
113
115
  );
114
116
 
@@ -136,6 +138,16 @@ const Checkbox = ({
136
138
  [onChangeProp],
137
139
  );
138
140
 
141
+ const onClick = useCallback<NonNullable<MuiCheckboxProps["onClick"]>>(
142
+ (event) => {
143
+ if (isReadOnly) {
144
+ event.stopPropagation();
145
+ event.preventDefault();
146
+ }
147
+ },
148
+ [isReadOnly],
149
+ );
150
+
139
151
  const onBlur = useCallback<NonNullable<MuiFormControlLabelProps["onBlur"]>>(
140
152
  (event) => {
141
153
  onBlurProp?.(event);
@@ -143,9 +155,22 @@ const Checkbox = ({
143
155
  [onBlurProp],
144
156
  );
145
157
 
158
+ const checkboxStyles = useMemo(
159
+ () => ({
160
+ alignItems: "flex-start",
161
+ ...(isReadOnly && {
162
+ cursor: "default",
163
+ "& .MuiTypography-root": {
164
+ cursor: "default",
165
+ },
166
+ }),
167
+ }),
168
+ [isReadOnly],
169
+ );
170
+
146
171
  return (
147
172
  <FormControlLabel
148
- sx={{ alignItems: "flex-start" }}
173
+ sx={checkboxStyles}
149
174
  aria-label={ariaLabel}
150
175
  aria-labelledby={ariaLabelledBy}
151
176
  className={
@@ -160,9 +185,14 @@ const Checkbox = ({
160
185
  {...inputValues}
161
186
  indeterminate={isIndeterminate}
162
187
  onChange={onChange}
188
+ onClick={
189
+ onClick as unknown as React.MouseEventHandler<HTMLButtonElement>
190
+ }
163
191
  required={isRequired}
164
192
  inputProps={{
165
193
  "data-se": testId,
194
+ "aria-readonly": isReadOnly,
195
+ readOnly: isReadOnly,
166
196
  }}
167
197
  disabled={isDisabled}
168
198
  inputRef={localInputRef}
@@ -10,9 +10,9 @@
10
10
  * See the License for the specific language governing permissions and limitations under the License.
11
11
  */
12
12
 
13
+ import React, { memo, ReactNode, useCallback, useMemo } from "react";
13
14
  import { FormGroup as MuiFormGroup } from "@mui/material";
14
- import { memo, ReactNode, useCallback } from "react";
15
-
15
+ import { CheckboxProps } from "./Checkbox";
16
16
  import { Field } from "./Field";
17
17
  import {
18
18
  FieldComponentProps,
@@ -41,6 +41,7 @@ export type CheckboxGroupProps = {
41
41
  | "HintLinkComponent"
42
42
  | "id"
43
43
  | "isDisabled"
44
+ | "isReadOnly"
44
45
  > &
45
46
  Pick<HtmlProps, "ariaDescribedBy" | "testId" | "translate">;
46
47
 
@@ -61,11 +62,26 @@ const CheckboxGroup = ({
61
62
  HintLinkComponent,
62
63
  id: idOverride,
63
64
  isDisabled,
65
+ isReadOnly = false,
64
66
  isRequired = false,
65
67
  label,
66
68
  testId,
67
69
  translate,
68
70
  }: CheckboxGroupProps) => {
71
+ const memoizedChildren = useMemo(
72
+ () =>
73
+ React.Children.map(children, (child) => {
74
+ if (React.isValidElement<CheckboxProps>(child)) {
75
+ return React.cloneElement(child, {
76
+ isReadOnly,
77
+ isDisabled: isDisabled || child.props.isDisabled,
78
+ });
79
+ }
80
+ return child;
81
+ }),
82
+ [children, isReadOnly, isDisabled],
83
+ );
84
+
69
85
  const renderFieldComponent = useCallback(
70
86
  ({
71
87
  ariaDescribedBy,
@@ -81,10 +97,10 @@ const CheckboxGroup = ({
81
97
  id={id}
82
98
  translate={translate}
83
99
  >
84
- {children}
100
+ {memoizedChildren}
85
101
  </MuiFormGroup>
86
102
  ),
87
- [children, testId, translate],
103
+ [memoizedChildren, testId, translate],
88
104
  );
89
105
 
90
106
  return (
@@ -102,6 +102,14 @@ export type DataTableRenderDetailPanelType = {
102
102
  };
103
103
 
104
104
  export type DataTableProps = {
105
+ /**
106
+ * An optional action button above the table.
107
+ */
108
+ additionalActionButton?: ReactNode;
109
+ /**
110
+ * MenuItems that go in an optional action menu above the table.
111
+ */
112
+ additionalActionMenuItems?: ReactNode;
105
113
  /**
106
114
  * Menu items to include in the bulk actions menu, which appears above the table if a row or rows are selected
107
115
  */
@@ -314,6 +322,8 @@ const ScrollableTableContainer = styled("div", {
314
322
  );
315
323
 
316
324
  const DataTable = ({
325
+ additionalActionButton,
326
+ additionalActionMenuItems,
317
327
  bulkActionMenuItems,
318
328
  columns,
319
329
  currentPage = 1,
@@ -876,7 +886,9 @@ const DataTable = ({
876
886
  hasFilters ||
877
887
  hasChangeableDensity ||
878
888
  hasColumnVisibility ||
879
- bulkActionMenuItems) && (
889
+ bulkActionMenuItems ||
890
+ additionalActionButton ||
891
+ additionalActionMenuItems) && (
880
892
  <Box sx={{ marginBottom: 5 }}>
881
893
  <DataFilters
882
894
  onChangeSearch={hasSearch ? setSearch : undefined}
@@ -898,6 +910,17 @@ const DataTable = ({
898
910
  setColumnVisibility={setColumnVisibility}
899
911
  />
900
912
  {bulkActionMenuItems && bulkActionMenuButton}
913
+ {additionalActionButton}
914
+ {additionalActionMenuItems && (
915
+ <MenuButton
916
+ endIcon={<MoreIcon />}
917
+ ariaLabel={t("table.moreactions.arialabel")}
918
+ buttonVariant="secondary"
919
+ menuAlignment="right"
920
+ >
921
+ {additionalActionMenuItems}
922
+ </MenuButton>
923
+ )}
901
924
  </>
902
925
  }
903
926
  />
@@ -17,6 +17,7 @@ import {
17
17
  useEffect,
18
18
  useRef,
19
19
  } from "react";
20
+ import { useOdysseyDesignTokens } from "../OdysseyDesignTokensContext";
20
21
 
21
22
  type UseScrollIndicationProps = {
22
23
  tableOuterContainer: HTMLDivElement | null;
@@ -36,6 +37,8 @@ export const useScrollIndication = ({
36
37
 
37
38
  const resizeObserverRef = useRef<ResizeObserver | null>(null);
38
39
 
40
+ const odysseyDesignTokens = useOdysseyDesignTokens();
41
+
39
42
  const checkScrollIndicators = useCallback(() => {
40
43
  if (!tableOuterContainer || !tableInnerContainer) return;
41
44
 
@@ -57,7 +60,10 @@ export const useScrollIndication = ({
57
60
  ]);
58
61
 
59
62
  useEffect(() => {
60
- if (resizeObserverRef.current) return; // Avoid creating multiple observers
63
+ // Avoid creating multiple observers or if ResizeObserver is unsupported
64
+ if (typeof ResizeObserver === "undefined" || resizeObserverRef.current) {
65
+ return;
66
+ }
61
67
 
62
68
  let debounceTimer: ReturnType<typeof setTimeout>;
63
69
 
@@ -73,14 +79,14 @@ export const useScrollIndication = ({
73
79
 
74
80
  setTableInnerContainerWidth(
75
81
  tableInnerContainer?.clientWidth
76
- ? `${tableInnerContainer.clientWidth}px`
82
+ ? `${tableInnerContainer.clientWidth - Number(odysseyDesignTokens.BorderWidthMain) * 2}px` // Account for the border on the outer container
77
83
  : "100%",
78
84
  );
79
85
  }, 100); // debounce delay
80
86
  });
81
87
 
82
- if (tableOuterContainer) {
83
- resizeObserverRef.current.observe(tableOuterContainer);
88
+ if (tableOuterContainer && tableOuterContainer.parentElement) {
89
+ resizeObserverRef.current.observe(tableOuterContainer.parentElement);
84
90
  }
85
91
 
86
92
  return () => {
@@ -101,6 +107,7 @@ export const useScrollIndication = ({
101
107
  tableInnerContainer,
102
108
  setIsTableContainerScrolledToStart,
103
109
  setIsTableContainerScrolledToEnd,
110
+ odysseyDesignTokens.BorderWidthMain,
104
111
  ]);
105
112
 
106
113
  useEffect(() => {
package/src/Field.tsx CHANGED
@@ -11,12 +11,10 @@
11
11
  */
12
12
 
13
13
  import { memo, ReactElement, useMemo } from "react";
14
-
15
14
  import {
16
15
  FormControl as MuiFormControl,
17
16
  FormLabel as MuiFormLabel,
18
17
  } from "@mui/material";
19
-
20
18
  import { FieldComponentProps } from "./FieldComponentProps";
21
19
  import { FieldError } from "./FieldError";
22
20
  import { FieldHint } from "./FieldHint";
@@ -35,6 +33,7 @@ export type RenderFieldComponentProps = {
35
33
  errorMessageElementId?: string;
36
34
  id: string;
37
35
  labelElementId: string;
36
+ isReadOnly?: boolean;
38
37
  };
39
38
 
40
39
  export type FieldProps = {
@@ -75,6 +74,7 @@ export type FieldProps = {
75
74
  errorMessageElementId,
76
75
  id,
77
76
  labelElementId,
77
+ isReadOnly,
78
78
  }: RenderFieldComponentProps) => ReactElement;
79
79
  };
80
80
 
@@ -91,6 +91,7 @@ const Field = ({
91
91
  isFullWidth = false,
92
92
  isRadioGroup = false,
93
93
  isOptional = false,
94
+ isReadOnly = false,
94
95
  label,
95
96
  renderFieldComponent,
96
97
  }: FieldProps &
@@ -104,6 +105,7 @@ const Field = ({
104
105
  | "isDisabled"
105
106
  | "isFullWidth"
106
107
  | "isOptional"
108
+ | "isReadOnly"
107
109
  > &
108
110
  Pick<HtmlProps, "ariaDescribedBy">) => {
109
111
  const { t } = useTranslation();
@@ -167,6 +169,7 @@ const Field = ({
167
169
  errorMessageElementId,
168
170
  id,
169
171
  labelElementId,
172
+ isReadOnly,
170
173
  })}
171
174
 
172
175
  {(errorMessage || errorMessageList) && (
@@ -15,7 +15,7 @@ import styled from "@emotion/styled";
15
15
  import { IconButton } from "@mui/material";
16
16
  import { useTranslation } from "react-i18next";
17
17
 
18
- import { FileUploadProps } from "./FileUpload";
18
+ import { FileUploaderProps } from "./FileUploader";
19
19
  import {
20
20
  useOdysseyDesignTokens,
21
21
  DesignTokens,
@@ -25,7 +25,7 @@ import { MuiPropsContext, MuiPropsContextType } from "../MuiPropsContext";
25
25
  import { Tooltip } from "../Tooltip";
26
26
 
27
27
  const PreviewContainer = styled.div<{
28
- isDisabled: FileUploadProps["isDisabled"];
28
+ isDisabled: FileUploaderProps["isDisabled"];
29
29
  odysseyDesignTokens: DesignTokens;
30
30
  }>(({ isDisabled, odysseyDesignTokens }) => ({
31
31
  color: isDisabled ? odysseyDesignTokens.TypographyColorDisabled : "inherit",
@@ -117,7 +117,7 @@ const UploadedFile = ({ name, onFileRemove }: UploadedFileProps) => {
117
117
 
118
118
  type FileUploadPreviewProps = {
119
119
  fileNames: string[];
120
- isDisabled: FileUploadProps["isDisabled"];
120
+ isDisabled: FileUploaderProps["isDisabled"];
121
121
  onFileRemove?: (name: string) => void;
122
122
  };
123
123
 
@@ -108,7 +108,7 @@ const CenterAlignedSupportText = styled.div({
108
108
  textAlign: "center",
109
109
  });
110
110
 
111
- export type FileUploadProps = {
111
+ export type FileUploaderProps = {
112
112
  /**
113
113
  * an array of file types the user is able to upload. @see https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/accept#unique_file_type_specifiers for examples
114
114
  */
@@ -140,7 +140,7 @@ export type FileUploadProps = {
140
140
  | "isOptional"
141
141
  >;
142
142
 
143
- const FileUpload = ({
143
+ const FileUploader = ({
144
144
  acceptedFileTypes,
145
145
  errorMessage,
146
146
  id,
@@ -153,7 +153,7 @@ const FileUpload = ({
153
153
  onChange,
154
154
  type,
155
155
  variant,
156
- }: FileUploadProps) => {
156
+ }: FileUploaderProps) => {
157
157
  const odysseyDesignTokens = useOdysseyDesignTokens();
158
158
  const { t } = useTranslation();
159
159
  const inputRef = useRef<HTMLInputElement>(null);
@@ -304,7 +304,8 @@ const FileUpload = ({
304
304
  );
305
305
  };
306
306
 
307
- const MemoizedFileUpload = memo(FileUpload);
308
- MemoizedFileUpload.displayName = "FileUpload";
307
+ const MemoizedFileUploader = memo(FileUploader);
308
+ MemoizedFileUploader.displayName = "FileUploader";
309
309
 
310
- export { MemoizedFileUpload as FileUpload };
310
+ export { MemoizedFileUploader as FileUpload };
311
+ export { MemoizedFileUploader as FileUploader };
@@ -0,0 +1,13 @@
1
+ /*!
2
+ * Copyright (c) 2022-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
+ export * from "./FileUploader";
@@ -11,6 +11,7 @@
11
11
  */
12
12
 
13
13
  import { render, screen } from "@testing-library/react";
14
+ import "@testing-library/jest-dom";
14
15
  import { Button } from "./";
15
16
  import { OdysseyCacheProvider } from "./OdysseyCacheProvider";
16
17
 
@@ -26,15 +26,19 @@ export type OdysseyCacheProviderProps = {
26
26
  /**
27
27
  * Emotion caches styles into the style element.
28
28
  * When enabling this prop, Emotion caches the styles at this element, rather than in <head>.
29
+ * @deprecated Use `EmotionRootElement` instead. This was incorrectly configured as an `HTMLStyleElement`, but then we're rendering `<style>` inside `<style>`. We need this to be a `<div>` instead.
29
30
  */
30
31
  emotionRoot?: HTMLStyleElement;
32
+ /**
33
+ * Emotion adds `<style>` elements into this DOM node. Normally, Emotion puts these in `document.head`.
34
+ * This is useful if you want to render into a Shadow DOM or iframe.
35
+ */
36
+ emotionRootElement?: HTMLElement;
31
37
  hasShadowDom?: boolean;
32
38
  nonce?: string;
33
39
  /**
34
40
  * Emotion renders into this HTML element.
35
41
  * When enabling this prop, Emotion renders at the top of this component rather than the bottom like it does in the HTML `<head>`.
36
- */
37
- /**
38
42
  * @deprecated Will be removed in a future Odyssey version. Use `hasShadowDomElement` instead.
39
43
  */
40
44
  shadowDomElement?: HTMLDivElement | HTMLElement;
@@ -44,6 +48,7 @@ export type OdysseyCacheProviderProps = {
44
48
  const OdysseyCacheProvider = ({
45
49
  children,
46
50
  emotionRoot,
51
+ emotionRootElement,
47
52
  hasShadowDom: hasShadowDomProp,
48
53
  nonce,
49
54
  shadowDomElement,
@@ -55,14 +60,23 @@ const OdysseyCacheProvider = ({
55
60
 
56
61
  const emotionCache = useMemo(() => {
57
62
  return createCache({
58
- ...(emotionRoot && { container: emotionRoot }),
63
+ ...((emotionRootElement || emotionRoot) && {
64
+ container: emotionRootElement || emotionRoot,
65
+ }),
59
66
  key: uniqueAlphabeticalId,
60
67
  nonce: nonce ?? window.cspNonce,
61
68
  prepend: true,
62
69
  speedy: hasShadowDom ? false : true, // <-- Needs to be set to false when shadow-dom is used!! https://github.com/emotion-js/emotion/issues/2053#issuecomment-713429122
63
70
  ...(stylisPlugins && { stylisPlugins }),
64
71
  });
65
- }, [emotionRoot, hasShadowDom, nonce, stylisPlugins, uniqueAlphabeticalId]);
72
+ }, [
73
+ emotionRoot,
74
+ emotionRootElement,
75
+ hasShadowDom,
76
+ nonce,
77
+ stylisPlugins,
78
+ uniqueAlphabeticalId,
79
+ ]);
66
80
 
67
81
  return <CacheProvider value={emotionCache}>{children}</CacheProvider>;
68
82
  };
@@ -27,6 +27,10 @@ import {
27
27
  } from "./OdysseyTranslationProvider";
28
28
  import { DefaultSupportedLanguages } from "./OdysseyTranslationProvider.types";
29
29
 
30
+ const scopedCssBaselineStyles = {
31
+ height: "inherit",
32
+ };
33
+
30
34
  export type OdysseyProviderProps<
31
35
  SupportedLanguages extends string = DefaultSupportedLanguages,
32
36
  > = OdysseyCacheProviderProps &
@@ -39,7 +43,9 @@ const OdysseyProvider = <SupportedLanguages extends string>({
39
43
  children,
40
44
  designTokensOverride,
41
45
  emotionRoot,
46
+ emotionRootElement,
42
47
  shadowDomElement,
48
+ shadowRootElement,
43
49
  languageCode,
44
50
  nonce,
45
51
  stylisPlugins,
@@ -47,17 +53,19 @@ const OdysseyProvider = <SupportedLanguages extends string>({
47
53
  translationOverrides,
48
54
  }: OdysseyProviderProps<SupportedLanguages>) => (
49
55
  <OdysseyCacheProvider
50
- nonce={nonce}
51
56
  emotionRoot={emotionRoot}
52
- hasShadowDom={Boolean(shadowDomElement)}
57
+ emotionRootElement={emotionRootElement}
58
+ hasShadowDom={Boolean(shadowRootElement || shadowDomElement)}
59
+ nonce={nonce}
53
60
  stylisPlugins={stylisPlugins}
54
61
  >
55
62
  <OdysseyThemeProvider
56
63
  designTokensOverride={designTokensOverride}
57
- shadowDomElement={shadowDomElement}
64
+ shadowRootElement={shadowRootElement || shadowDomElement}
58
65
  themeOverride={themeOverride}
59
66
  >
60
- <ScopedCssBaseline>
67
+ {/* This component creates a div; for flexibility of layout of children, make it inherit its parent's height */}
68
+ <ScopedCssBaseline sx={scopedCssBaselineStyles}>
61
69
  <OdysseyTranslationProvider<SupportedLanguages>
62
70
  languageCode={languageCode}
63
71
  translationOverrides={translationOverrides}
@@ -25,7 +25,9 @@ import { OdysseyDesignTokensContext } from "./OdysseyDesignTokensContext";
25
25
  export type OdysseyThemeProviderProps = {
26
26
  children: ReactNode;
27
27
  designTokensOverride?: DesignTokensOverride;
28
+ /** @deprecated Use `shadowRootElement` instead. */
28
29
  shadowDomElement?: HTMLDivElement | HTMLElement | undefined;
30
+ shadowRootElement?: HTMLDivElement | HTMLElement;
29
31
  themeOverride?: ThemeOptions;
30
32
  };
31
33
 
@@ -38,19 +40,21 @@ const OdysseyThemeProvider = ({
38
40
  children,
39
41
  designTokensOverride,
40
42
  shadowDomElement,
43
+ shadowRootElement,
41
44
  themeOverride,
42
45
  }: OdysseyThemeProviderProps) => {
43
46
  const odysseyTokens = useMemo(
44
47
  () => ({ ...Tokens, ...designTokensOverride }),
45
48
  [designTokensOverride],
46
49
  );
50
+
47
51
  const odysseyTheme = useMemo(
48
52
  () =>
49
53
  createOdysseyMuiTheme({
50
54
  odysseyTokens,
51
- shadowDomElement,
55
+ shadowRootElement: shadowRootElement || shadowDomElement,
52
56
  }),
53
- [odysseyTokens, shadowDomElement],
57
+ [odysseyTokens, shadowDomElement, shadowRootElement],
54
58
  );
55
59
 
56
60
  const customOdysseyTheme = useMemo(