@okta/odyssey-react-mui 1.21.1 → 1.22.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.
- package/CHANGELOG.md +19 -0
- package/dist/Autocomplete.js +76 -38
- package/dist/Autocomplete.js.map +1 -1
- package/dist/Checkbox.js +26 -11
- package/dist/Checkbox.js.map +1 -1
- package/dist/CheckboxGroup.js +14 -3
- package/dist/CheckboxGroup.js.map +1 -1
- package/dist/DataTable/DataTable.js +10 -2
- package/dist/DataTable/DataTable.js.map +1 -1
- package/dist/DataTable/useScrollIndication.js +2 -2
- package/dist/DataTable/useScrollIndication.js.map +1 -1
- package/dist/Field.js +3 -1
- package/dist/Field.js.map +1 -1
- package/dist/OdysseyCacheProvider.js +4 -3
- package/dist/OdysseyCacheProvider.js.map +1 -1
- package/dist/OdysseyProvider.js +6 -3
- package/dist/OdysseyProvider.js.map +1 -1
- package/dist/OdysseyThemeProvider.js +3 -2
- package/dist/OdysseyThemeProvider.js.map +1 -1
- package/dist/Pagination/Pagination.js +1 -1
- package/dist/Pagination/Pagination.js.map +1 -1
- package/dist/Radio.js +34 -7
- package/dist/Radio.js.map +1 -1
- package/dist/RadioGroup.js +17 -5
- package/dist/RadioGroup.js.map +1 -1
- package/dist/Select.js +53 -31
- package/dist/Select.js.map +1 -1
- package/dist/ToastStack.js.map +1 -1
- package/dist/{createShadowRootElement.js → createShadowDomElements.js} +22 -6
- package/dist/createShadowDomElements.js.map +1 -0
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/index.scss +5 -5
- package/dist/labs/AppTile.js +124 -0
- package/dist/labs/AppTile.js.map +1 -0
- package/dist/labs/DataView/BulkActionsMenu.js.map +1 -0
- package/dist/labs/{DataComponents/StackContent.js → DataView/CardLayoutContent.js} +14 -14
- package/dist/labs/DataView/CardLayoutContent.js.map +1 -0
- package/dist/labs/{DataComponents/StackCard.js → DataView/DataCard.js} +6 -6
- package/dist/labs/DataView/DataCard.js.map +1 -0
- package/dist/labs/{DataComponents → DataView}/DataTable.js +6 -2
- package/dist/labs/DataView/DataTable.js.map +1 -0
- package/dist/labs/{DataComponents → DataView}/DataView.js +27 -17
- package/dist/labs/DataView/DataView.js.map +1 -0
- package/dist/labs/DataView/DetailPanel.js.map +1 -0
- package/dist/labs/DataView/LayoutSwitcher.js.map +1 -0
- package/dist/labs/DataView/RowActions.js.map +1 -0
- package/dist/labs/{DataComponents/TableContent.js → DataView/TableLayoutContent.js} +17 -17
- package/dist/labs/DataView/TableLayoutContent.js.map +1 -0
- package/dist/labs/{DataComponents → DataView}/TableSettings.js +2 -2
- package/dist/labs/DataView/TableSettings.js.map +1 -0
- package/dist/labs/DataView/componentTypes.js.map +1 -0
- package/dist/labs/{DataComponents → DataView}/constants.js +2 -2
- package/dist/labs/DataView/constants.js.map +1 -0
- package/dist/labs/DataView/dataTypes.js.map +1 -0
- package/dist/labs/{DataComponents → DataView}/fetchData.js +2 -2
- package/dist/labs/DataView/fetchData.js.map +1 -0
- package/dist/labs/{DataComponents → DataView}/index.js +0 -1
- package/dist/labs/DataView/index.js.map +1 -0
- package/dist/labs/DataView/tableConstants.js.map +1 -0
- package/dist/labs/DataView/useFilterConversion.js.map +1 -0
- package/dist/labs/SideNav/CollapseIcon.js +44 -0
- package/dist/labs/SideNav/CollapseIcon.js.map +1 -0
- package/dist/labs/SideNav/SideNav.js +246 -0
- package/dist/labs/SideNav/SideNav.js.map +1 -0
- package/dist/labs/SideNav/SideNavFooterContent.js +49 -0
- package/dist/labs/SideNav/SideNavFooterContent.js.map +1 -0
- package/dist/labs/SideNav/SideNavHeader.js +58 -0
- package/dist/labs/SideNav/SideNavHeader.js.map +1 -0
- package/dist/labs/SideNav/SideNavItemContent.js +157 -0
- package/dist/labs/SideNav/SideNavItemContent.js.map +1 -0
- package/dist/labs/SideNav/SideNavItemLinkContent.js +71 -0
- package/dist/labs/SideNav/SideNavItemLinkContent.js.map +1 -0
- package/dist/labs/SideNav/index.js +14 -0
- package/dist/labs/SideNav/index.js.map +1 -0
- package/dist/labs/SideNav/types.js +2 -0
- package/dist/labs/SideNav/types.js.map +1 -0
- package/dist/labs/Switch.js +70 -16
- package/dist/labs/Switch.js.map +1 -1
- package/dist/labs/index.js +3 -2
- package/dist/labs/index.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_cs.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_cs.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_da.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_da.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_de.js +16 -2
- package/dist/properties/ts/odyssey-react-mui_de.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_el.js +18 -4
- package/dist/properties/ts/odyssey-react-mui_el.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_es.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_es.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_fi.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_fi.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_fr.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_fr.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_ht.js +18 -4
- package/dist/properties/ts/odyssey-react-mui_ht.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_hu.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_hu.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_id.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_id.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_it.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_it.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_ja.js +16 -2
- package/dist/properties/ts/odyssey-react-mui_ja.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_ko.js +16 -2
- package/dist/properties/ts/odyssey-react-mui_ko.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_ms.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_ms.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_nb.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_nb.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_nl_NL.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_nl_NL.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_pl.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_pl.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_pt_BR.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_pt_BR.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_ro.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_ro.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_ru.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_ru.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_sv.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_sv.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_th.js +16 -2
- package/dist/properties/ts/odyssey-react-mui_th.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_tr.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_tr.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_uk.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_uk.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_vi.js +17 -3
- package/dist/properties/ts/odyssey-react-mui_vi.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_zh_CN.js +16 -2
- package/dist/properties/ts/odyssey-react-mui_zh_CN.js.map +1 -1
- package/dist/properties/ts/odyssey-react-mui_zh_TW.js +16 -2
- package/dist/properties/ts/odyssey-react-mui_zh_TW.js.map +1 -1
- package/dist/src/Autocomplete.d.ts.map +1 -1
- package/dist/src/Checkbox.d.ts +2 -2
- package/dist/src/Checkbox.d.ts.map +1 -1
- package/dist/src/CheckboxGroup.d.ts +3 -3
- package/dist/src/CheckboxGroup.d.ts.map +1 -1
- package/dist/src/DataTable/DataTable.d.ts +9 -1
- package/dist/src/DataTable/DataTable.d.ts.map +1 -1
- package/dist/src/Field.d.ts +3 -2
- package/dist/src/Field.d.ts.map +1 -1
- package/dist/src/OdysseyCacheProvider.d.ts +7 -3
- package/dist/src/OdysseyCacheProvider.d.ts.map +1 -1
- package/dist/src/OdysseyProvider.d.ts +1 -1
- package/dist/src/OdysseyProvider.d.ts.map +1 -1
- package/dist/src/OdysseyThemeProvider.d.ts +3 -1
- package/dist/src/OdysseyThemeProvider.d.ts.map +1 -1
- package/dist/src/Pagination/Pagination.d.ts.map +1 -1
- package/dist/src/Radio.d.ts +6 -8
- package/dist/src/Radio.d.ts.map +1 -1
- package/dist/src/RadioGroup.d.ts +4 -5
- package/dist/src/RadioGroup.d.ts.map +1 -1
- package/dist/src/Select.d.ts +2 -2
- package/dist/src/Select.d.ts.map +1 -1
- package/dist/src/ToastStack.d.ts +2 -2
- package/dist/src/ToastStack.d.ts.map +1 -1
- package/dist/src/{createShadowRootElement.d.ts → createShadowDomElements.d.ts} +6 -1
- package/dist/src/createShadowDomElements.d.ts.map +1 -0
- package/dist/src/index.d.ts +1 -1
- package/dist/src/labs/AppTile.d.ts +39 -0
- package/dist/src/labs/AppTile.d.ts.map +1 -0
- package/dist/src/labs/DataView/BulkActionsMenu.d.ts.map +1 -0
- package/dist/src/labs/{DataComponents/StackContent.d.ts → DataView/CardLayoutContent.d.ts} +7 -7
- package/dist/src/labs/DataView/CardLayoutContent.d.ts.map +1 -0
- package/dist/src/labs/{DataComponents/StackCard.d.ts → DataView/DataCard.d.ts} +4 -4
- package/dist/src/labs/DataView/DataCard.d.ts.map +1 -0
- package/dist/src/labs/DataView/DataTable.d.ts +16 -0
- package/dist/src/labs/DataView/DataTable.d.ts.map +1 -0
- package/dist/src/labs/{DataComponents → DataView}/DataView.d.ts +1 -1
- package/dist/src/labs/DataView/DataView.d.ts.map +1 -0
- package/dist/src/labs/{DataComponents → DataView}/DetailPanel.d.ts +2 -2
- package/dist/src/labs/DataView/DetailPanel.d.ts.map +1 -0
- package/dist/src/labs/DataView/LayoutSwitcher.d.ts.map +1 -0
- package/dist/src/labs/DataView/RowActions.d.ts.map +1 -0
- package/dist/src/labs/{DataComponents/TableContent.d.ts → DataView/TableLayoutContent.d.ts} +7 -7
- package/dist/src/labs/DataView/TableLayoutContent.d.ts.map +1 -0
- package/dist/src/labs/{DataComponents → DataView}/TableSettings.d.ts +3 -3
- package/dist/src/labs/DataView/TableSettings.d.ts.map +1 -0
- package/dist/src/labs/{DataComponents → DataView}/componentTypes.d.ts +11 -9
- package/dist/src/labs/DataView/componentTypes.d.ts.map +1 -0
- package/dist/src/labs/{DataComponents → DataView}/constants.d.ts +1 -1
- package/dist/src/labs/DataView/constants.d.ts.map +1 -0
- package/dist/src/labs/DataView/dataTypes.d.ts.map +1 -0
- package/dist/src/labs/{DataComponents → DataView}/fetchData.d.ts +1 -1
- package/dist/src/labs/DataView/fetchData.d.ts.map +1 -0
- package/dist/src/labs/{DataComponents → DataView}/index.d.ts +0 -1
- package/dist/src/labs/DataView/index.d.ts.map +1 -0
- package/dist/src/labs/DataView/tableConstants.d.ts.map +1 -0
- package/dist/src/labs/{DataComponents → DataView}/useFilterConversion.d.ts +2 -2
- package/dist/src/labs/DataView/useFilterConversion.d.ts.map +1 -0
- package/dist/src/labs/SideNav/CollapseIcon.d.ts +17 -0
- package/dist/src/labs/SideNav/CollapseIcon.d.ts.map +1 -0
- package/dist/src/labs/SideNav/SideNav.d.ts +15 -0
- package/dist/src/labs/SideNav/SideNav.d.ts.map +1 -0
- package/dist/src/labs/SideNav/SideNavFooterContent.d.ts +17 -0
- package/dist/src/labs/SideNav/SideNavFooterContent.d.ts.map +1 -0
- package/dist/src/labs/SideNav/SideNavHeader.d.ts +16 -0
- package/dist/src/labs/SideNav/SideNavHeader.d.ts.map +1 -0
- package/dist/src/labs/SideNav/SideNavItemContent.d.ts +33 -0
- package/dist/src/labs/SideNav/SideNavItemContent.d.ts.map +1 -0
- package/dist/src/labs/SideNav/SideNavItemLinkContent.d.ts +16 -0
- package/dist/src/labs/SideNav/SideNavItemLinkContent.d.ts.map +1 -0
- package/dist/src/labs/SideNav/index.d.ts +14 -0
- package/dist/src/labs/SideNav/index.d.ts.map +1 -0
- package/dist/src/labs/{SideNav.d.ts → SideNav/types.d.ts} +31 -33
- package/dist/src/labs/SideNav/types.d.ts.map +1 -0
- package/dist/src/labs/Switch.d.ts +5 -1
- package/dist/src/labs/Switch.d.ts.map +1 -1
- package/dist/src/labs/index.d.ts +2 -1
- package/dist/src/labs/index.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_cs.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_cs.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_da.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_da.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_de.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_de.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_el.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_el.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_es.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_es.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_fi.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_fi.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_fr.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_fr.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_ht.d.ts +16 -2
- package/dist/src/properties/ts/odyssey-react-mui_ht.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_hu.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_hu.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_id.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_id.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_it.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_it.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_ja.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_ja.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_ko.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_ko.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_ms.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_ms.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_nb.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_nb.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_nl_NL.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_nl_NL.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_pl.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_pl.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_pt_BR.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_pt_BR.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_ro.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_ro.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_ru.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_ru.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_sv.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_sv.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_th.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_th.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_tr.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_tr.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_uk.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_uk.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_vi.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_vi.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_zh_CN.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_zh_CN.d.ts.map +1 -1
- package/dist/src/properties/ts/odyssey-react-mui_zh_TW.d.ts +15 -1
- package/dist/src/properties/ts/odyssey-react-mui_zh_TW.d.ts.map +1 -1
- package/dist/src/theme/components.d.ts +3 -1
- package/dist/src/theme/components.d.ts.map +1 -1
- package/dist/src/theme/createOdysseyMuiTheme.d.ts +3 -1
- package/dist/src/theme/createOdysseyMuiTheme.d.ts.map +1 -1
- package/dist/theme/components.js +236 -151
- package/dist/theme/components.js.map +1 -1
- package/dist/theme/createOdysseyMuiTheme.js +3 -2
- package/dist/theme/createOdysseyMuiTheme.js.map +1 -1
- package/dist/tsconfig.production.tsbuildinfo +1 -1
- package/package.json +3 -4
- package/src/Autocomplete.tsx +108 -45
- package/src/Checkbox.tsx +39 -9
- package/src/CheckboxGroup.tsx +20 -4
- package/src/DataTable/DataTable.tsx +24 -1
- package/src/DataTable/useScrollIndication.tsx +2 -2
- package/src/Field.tsx +5 -2
- package/src/OdysseyCacheProvider.tsx +18 -4
- package/src/OdysseyProvider.tsx +6 -3
- package/src/OdysseyThemeProvider.tsx +6 -2
- package/src/Pagination/Pagination.tsx +3 -1
- package/src/Radio.tsx +42 -13
- package/src/RadioGroup.tsx +26 -7
- package/src/Select.tsx +78 -45
- package/src/ToastStack.tsx +2 -2
- package/src/{createShadowRootElement.ts → createShadowDomElements.ts} +24 -5
- package/src/index.ts +1 -1
- package/src/labs/AppTile.tsx +200 -0
- package/src/labs/{DataComponents/StackContent.tsx → DataView/CardLayoutContent.tsx} +24 -19
- package/src/labs/{DataComponents/StackCard.tsx → DataView/DataCard.tsx} +7 -7
- package/src/labs/{DataComponents → DataView}/DataTable.tsx +8 -4
- package/src/labs/{DataComponents → DataView}/DataView.tsx +49 -19
- package/src/labs/{DataComponents → DataView}/DetailPanel.tsx +2 -2
- package/src/labs/{DataComponents/TableContent.tsx → DataView/TableLayoutContent.tsx} +31 -26
- package/src/labs/{DataComponents → DataView}/TableSettings.tsx +5 -4
- package/src/labs/{DataComponents → DataView}/componentTypes.ts +11 -9
- package/src/labs/{DataComponents → DataView}/constants.tsx +2 -2
- package/src/labs/{DataComponents → DataView}/fetchData.ts +3 -3
- package/src/labs/{DataComponents → DataView}/index.tsx +0 -1
- package/src/labs/{DataComponents → DataView}/useFilterConversion.ts +2 -2
- package/src/labs/SideNav/CollapseIcon.tsx +48 -0
- package/src/labs/SideNav/SideNav.tsx +350 -0
- package/src/labs/SideNav/SideNavFooterContent.tsx +64 -0
- package/src/labs/SideNav/SideNavHeader.tsx +65 -0
- package/src/labs/SideNav/SideNavItemContent.tsx +216 -0
- package/src/labs/SideNav/SideNavItemLinkContent.tsx +87 -0
- package/src/labs/SideNav/index.ts +15 -0
- package/src/labs/SideNav/types.ts +125 -0
- package/src/labs/Switch.tsx +85 -31
- package/src/labs/index.ts +3 -1
- package/src/properties/translations/odyssey-react-mui_cs.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_da.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_de.properties +14 -2
- package/src/properties/translations/odyssey-react-mui_el.properties +16 -4
- package/src/properties/translations/odyssey-react-mui_es.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_fi.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_fr.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_ht.properties +17 -6
- package/src/properties/translations/odyssey-react-mui_hu.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_id.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_it.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_ja.properties +14 -2
- package/src/properties/translations/odyssey-react-mui_ko.properties +14 -2
- package/src/properties/translations/odyssey-react-mui_ms.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_nb.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_nl_NL.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_pl.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_pt_BR.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_ro.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_ru.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_sv.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_th.properties +14 -2
- package/src/properties/translations/odyssey-react-mui_tr.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_uk.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_vi.properties +15 -3
- package/src/properties/translations/odyssey-react-mui_zh_CN.properties +14 -2
- package/src/properties/translations/odyssey-react-mui_zh_TW.properties +14 -2
- package/src/properties/ts/odyssey-react-mui_cs.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_da.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_de.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_el.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_es.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_fi.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_fr.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_ht.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_hu.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_id.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_it.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_ja.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_ko.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_ms.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_nb.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_nl_NL.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_pl.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_pt_BR.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_ro.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_ru.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_sv.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_th.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_tr.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_uk.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_vi.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_zh_CN.ts +1 -1
- package/src/properties/ts/odyssey-react-mui_zh_TW.ts +1 -1
- package/src/theme/components.tsx +245 -155
- package/src/theme/createOdysseyMuiTheme.ts +4 -1
- package/dist/createShadowRootElement.js.map +0 -1
- package/dist/labs/DataComponents/BulkActionsMenu.js.map +0 -1
- package/dist/labs/DataComponents/DataStack.js +0 -85
- package/dist/labs/DataComponents/DataStack.js.map +0 -1
- package/dist/labs/DataComponents/DataTable.js.map +0 -1
- package/dist/labs/DataComponents/DataView.js.map +0 -1
- package/dist/labs/DataComponents/DetailPanel.js.map +0 -1
- package/dist/labs/DataComponents/LayoutSwitcher.js.map +0 -1
- package/dist/labs/DataComponents/RowActions.js.map +0 -1
- package/dist/labs/DataComponents/StackCard.js.map +0 -1
- package/dist/labs/DataComponents/StackContent.js.map +0 -1
- package/dist/labs/DataComponents/TableContent.js.map +0 -1
- package/dist/labs/DataComponents/TableSettings.js.map +0 -1
- package/dist/labs/DataComponents/componentTypes.js.map +0 -1
- package/dist/labs/DataComponents/constants.js.map +0 -1
- package/dist/labs/DataComponents/dataTypes.js.map +0 -1
- package/dist/labs/DataComponents/fetchData.js.map +0 -1
- package/dist/labs/DataComponents/index.js.map +0 -1
- package/dist/labs/DataComponents/tableConstants.js.map +0 -1
- package/dist/labs/DataComponents/useFilterConversion.js.map +0 -1
- package/dist/labs/SideNav.js +0 -478
- package/dist/labs/SideNav.js.map +0 -1
- package/dist/src/createShadowRootElement.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/BulkActionsMenu.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/DataStack.d.ts +0 -20
- package/dist/src/labs/DataComponents/DataStack.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/DataTable.d.ts +0 -16
- package/dist/src/labs/DataComponents/DataTable.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/DataView.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/DetailPanel.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/LayoutSwitcher.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/RowActions.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/StackCard.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/StackContent.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/TableContent.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/TableSettings.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/componentTypes.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/constants.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/dataTypes.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/fetchData.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/index.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/tableConstants.d.ts.map +0 -1
- package/dist/src/labs/DataComponents/useFilterConversion.d.ts.map +0 -1
- package/dist/src/labs/SideNav.d.ts.map +0 -1
- package/src/labs/DataComponents/DataStack.tsx +0 -105
- package/src/labs/SideNav.tsx +0 -745
- /package/dist/labs/{DataComponents → DataView}/BulkActionsMenu.js +0 -0
- /package/dist/labs/{DataComponents → DataView}/DetailPanel.js +0 -0
- /package/dist/labs/{DataComponents → DataView}/LayoutSwitcher.js +0 -0
- /package/dist/labs/{DataComponents → DataView}/RowActions.js +0 -0
- /package/dist/labs/{DataComponents → DataView}/componentTypes.js +0 -0
- /package/dist/labs/{DataComponents → DataView}/dataTypes.js +0 -0
- /package/dist/labs/{DataComponents → DataView}/tableConstants.js +0 -0
- /package/dist/labs/{DataComponents → DataView}/useFilterConversion.js +0 -0
- /package/dist/src/labs/{DataComponents → DataView}/BulkActionsMenu.d.ts +0 -0
- /package/dist/src/labs/{DataComponents → DataView}/LayoutSwitcher.d.ts +0 -0
- /package/dist/src/labs/{DataComponents → DataView}/RowActions.d.ts +0 -0
- /package/dist/src/labs/{DataComponents → DataView}/dataTypes.d.ts +0 -0
- /package/dist/src/labs/{DataComponents → DataView}/tableConstants.d.ts +0 -0
- /package/src/labs/{DataComponents → DataView}/BulkActionsMenu.tsx +0 -0
- /package/src/labs/{DataComponents → DataView}/LayoutSwitcher.tsx +0 -0
- /package/src/labs/{DataComponents → DataView}/RowActions.tsx +0 -0
- /package/src/labs/{DataComponents → DataView}/dataTypes.ts +0 -0
- /package/src/labs/{DataComponents → DataView}/tableConstants.tsx +0 -0
|
@@ -41,7 +41,7 @@ import {
|
|
|
41
41
|
} from "../../icons.generated";
|
|
42
42
|
import { Box } from "../../Box";
|
|
43
43
|
import { Button } from "../../Button";
|
|
44
|
-
import {
|
|
44
|
+
import { TableLayoutProps, TableState, UniversalProps } from "./componentTypes";
|
|
45
45
|
import { DataTableCell } from "./dataTypes";
|
|
46
46
|
import {
|
|
47
47
|
dataTableImmutableSettings,
|
|
@@ -64,8 +64,8 @@ const RowActionsContainer = styled("div")(() => ({
|
|
|
64
64
|
display: "flex",
|
|
65
65
|
}));
|
|
66
66
|
|
|
67
|
-
export type
|
|
68
|
-
columns:
|
|
67
|
+
export type TableLayoutContentProps = {
|
|
68
|
+
columns: TableLayoutProps["columns"];
|
|
69
69
|
data: MRT_RowData[];
|
|
70
70
|
draggingRow?: MRT_Row<MRT_RowData> | null;
|
|
71
71
|
emptyState: ReactNode;
|
|
@@ -121,12 +121,12 @@ export type TableContentProps = {
|
|
|
121
121
|
rowSelection: MRT_RowSelectionState;
|
|
122
122
|
setRowSelection: Dispatch<SetStateAction<MRT_RowSelectionState>>;
|
|
123
123
|
setTableState: Dispatch<SetStateAction<TableState>>;
|
|
124
|
-
|
|
124
|
+
tableLayoutOptions: TableLayoutProps;
|
|
125
125
|
tableState: TableState;
|
|
126
126
|
totalRows: UniversalProps["totalRows"];
|
|
127
127
|
};
|
|
128
128
|
|
|
129
|
-
const
|
|
129
|
+
const TableLayoutContent = ({
|
|
130
130
|
columns,
|
|
131
131
|
data,
|
|
132
132
|
draggingRow,
|
|
@@ -144,10 +144,10 @@ const TableContent = ({
|
|
|
144
144
|
rowSelection,
|
|
145
145
|
setRowSelection,
|
|
146
146
|
setTableState,
|
|
147
|
-
|
|
147
|
+
tableLayoutOptions,
|
|
148
148
|
tableState,
|
|
149
149
|
totalRows,
|
|
150
|
-
}:
|
|
150
|
+
}: TableLayoutContentProps) => {
|
|
151
151
|
const [isTableContainerScrolledToStart, setIsTableContainerScrolledToStart] =
|
|
152
152
|
useState(true);
|
|
153
153
|
const [isTableContainerScrolledToEnd, setIsTableContainerScrolledToEnd] =
|
|
@@ -220,8 +220,8 @@ const TableContent = ({
|
|
|
220
220
|
row.index + (pagination.pageIndex - 1) * pagination.pageSize;
|
|
221
221
|
return (
|
|
222
222
|
<RowActionsContainer>
|
|
223
|
-
{
|
|
224
|
-
{(
|
|
223
|
+
{tableLayoutOptions.rowActionButtons?.(row)}
|
|
224
|
+
{(tableLayoutOptions.rowActionMenuItems || hasRowReordering) && (
|
|
225
225
|
<MenuButton
|
|
226
226
|
ariaLabel={t("table.moreactions.arialabel")}
|
|
227
227
|
buttonVariant="floating"
|
|
@@ -232,7 +232,7 @@ const TableContent = ({
|
|
|
232
232
|
<RowActions
|
|
233
233
|
isRowReorderingDisabled={isRowReorderingDisabled}
|
|
234
234
|
row={row}
|
|
235
|
-
rowActionMenuItems={
|
|
235
|
+
rowActionMenuItems={tableLayoutOptions.rowActionMenuItems}
|
|
236
236
|
rowIndex={currentIndex}
|
|
237
237
|
totalRows={totalRows}
|
|
238
238
|
updateRowOrder={
|
|
@@ -251,7 +251,7 @@ const TableContent = ({
|
|
|
251
251
|
pagination.pageIndex,
|
|
252
252
|
pagination.pageSize,
|
|
253
253
|
t,
|
|
254
|
-
|
|
254
|
+
tableLayoutOptions,
|
|
255
255
|
totalRows,
|
|
256
256
|
updateRowOrder,
|
|
257
257
|
],
|
|
@@ -270,15 +270,15 @@ const TableContent = ({
|
|
|
270
270
|
const shouldDisplayRowActions = useMemo(
|
|
271
271
|
() =>
|
|
272
272
|
(hasRowReordering === true && onReorderRows) ||
|
|
273
|
-
|
|
274
|
-
|
|
273
|
+
tableLayoutOptions.rowActionButtons ||
|
|
274
|
+
tableLayoutOptions.rowActionMenuItems
|
|
275
275
|
? true
|
|
276
276
|
: false,
|
|
277
277
|
[
|
|
278
278
|
hasRowReordering,
|
|
279
279
|
onReorderRows,
|
|
280
|
-
|
|
281
|
-
|
|
280
|
+
tableLayoutOptions.rowActionButtons,
|
|
281
|
+
tableLayoutOptions.rowActionMenuItems,
|
|
282
282
|
],
|
|
283
283
|
);
|
|
284
284
|
|
|
@@ -323,10 +323,10 @@ const TableContent = ({
|
|
|
323
323
|
className: "ods-actions-cell",
|
|
324
324
|
children: (
|
|
325
325
|
<Box sx={{ display: "flex", visibility: "hidden" }}>
|
|
326
|
-
{
|
|
327
|
-
|
|
326
|
+
{tableLayoutOptions.rowActionButtons &&
|
|
327
|
+
tableLayoutOptions.rowActionButtons({ id: null })}
|
|
328
328
|
{((hasRowReordering === true && onReorderRows) ||
|
|
329
|
-
|
|
329
|
+
tableLayoutOptions.rowActionMenuItems) && (
|
|
330
330
|
<Box>
|
|
331
331
|
<Button
|
|
332
332
|
endIcon={<MoreIcon />}
|
|
@@ -345,7 +345,7 @@ const TableContent = ({
|
|
|
345
345
|
muiTableProps: {
|
|
346
346
|
ref: tableContentRef,
|
|
347
347
|
className:
|
|
348
|
-
!shouldDisplayRowActions &&
|
|
348
|
+
!shouldDisplayRowActions && tableLayoutOptions.hasColumnResizing
|
|
349
349
|
? "ods-hide-spacer-column"
|
|
350
350
|
: "",
|
|
351
351
|
},
|
|
@@ -355,11 +355,16 @@ const TableContent = ({
|
|
|
355
355
|
muiTableBodyProps: () => ({
|
|
356
356
|
className: rowDensityClassName,
|
|
357
357
|
}),
|
|
358
|
-
enableColumnResizing:
|
|
358
|
+
enableColumnResizing: tableLayoutOptions.hasColumnResizing,
|
|
359
359
|
defaultColumn: {
|
|
360
360
|
Cell: defaultCell,
|
|
361
361
|
},
|
|
362
|
-
enableRowActions:
|
|
362
|
+
enableRowActions:
|
|
363
|
+
(hasRowReordering === true && onReorderRows) ||
|
|
364
|
+
tableLayoutOptions.rowActionButtons ||
|
|
365
|
+
tableLayoutOptions.rowActionMenuItems
|
|
366
|
+
? true
|
|
367
|
+
: false,
|
|
363
368
|
renderRowActions: ({ row }) => renderRowActions({ row }),
|
|
364
369
|
enableRowOrdering: hasRowReordering && Boolean(onReorderRows),
|
|
365
370
|
enableRowDragging: hasRowReordering && Boolean(onReorderRows),
|
|
@@ -395,7 +400,7 @@ const TableContent = ({
|
|
|
395
400
|
sx: dragHandleStyles,
|
|
396
401
|
...dragHandleText,
|
|
397
402
|
}),
|
|
398
|
-
renderDetailPanel:
|
|
403
|
+
renderDetailPanel: tableLayoutOptions.renderDetailPanel,
|
|
399
404
|
enableRowVirtualization: data.length >= 50,
|
|
400
405
|
muiTableHeadCellProps: ({ column: currentColumn }) => ({
|
|
401
406
|
className: tableState.columnSorting.find(
|
|
@@ -407,7 +412,7 @@ const TableContent = ({
|
|
|
407
412
|
muiTableBodyCellProps: ({ column }) => ({
|
|
408
413
|
className: column.getIsResizing() ? "isResizing" : "",
|
|
409
414
|
}),
|
|
410
|
-
enableSorting:
|
|
415
|
+
enableSorting: tableLayoutOptions.hasSorting === true, // I don't know why this needs to be true, but it still works if undefined otherwise
|
|
411
416
|
onSortingChange: (sortingUpdater) => {
|
|
412
417
|
const newSortVal =
|
|
413
418
|
typeof sortingUpdater === "function"
|
|
@@ -441,7 +446,7 @@ const TableContent = ({
|
|
|
441
446
|
);
|
|
442
447
|
};
|
|
443
448
|
|
|
444
|
-
const
|
|
445
|
-
|
|
449
|
+
const MemoizedTableLayoutContent = memo(TableLayoutContent);
|
|
450
|
+
MemoizedTableLayoutContent.displayName = "TableLayoutContent";
|
|
446
451
|
|
|
447
|
-
export {
|
|
452
|
+
export { MemoizedTableLayoutContent as TableLayoutContent };
|
|
@@ -19,22 +19,23 @@ import { densityValues } from "./constants";
|
|
|
19
19
|
import { ListIcon, ShowIcon } from "../../icons.generated";
|
|
20
20
|
import { MenuButton } from "../../MenuButton";
|
|
21
21
|
import { MenuItem } from "../../MenuItem";
|
|
22
|
-
import {
|
|
22
|
+
import { TableLayoutProps, TableState } from "./componentTypes";
|
|
23
23
|
|
|
24
24
|
export type TableSettingsProps = {
|
|
25
25
|
setTableState: Dispatch<SetStateAction<TableState>>;
|
|
26
|
-
|
|
26
|
+
tableLayoutOptions: TableLayoutProps;
|
|
27
27
|
tableState: TableState;
|
|
28
28
|
};
|
|
29
29
|
|
|
30
30
|
const TableSettings = ({
|
|
31
31
|
setTableState,
|
|
32
|
-
|
|
32
|
+
tableLayoutOptions,
|
|
33
33
|
tableState,
|
|
34
34
|
}: TableSettingsProps) => {
|
|
35
35
|
const { t } = useTranslation();
|
|
36
36
|
|
|
37
|
-
const { hasChangeableDensity, hasColumnVisibility, columns } =
|
|
37
|
+
const { hasChangeableDensity, hasColumnVisibility, columns } =
|
|
38
|
+
tableLayoutOptions;
|
|
38
39
|
const { rowDensity, columnVisibility } = tableState;
|
|
39
40
|
|
|
40
41
|
const changeRowDensity = useCallback<(value: MRT_DensityState) => void>(
|
|
@@ -19,7 +19,7 @@ import {
|
|
|
19
19
|
MRT_VisibilityState,
|
|
20
20
|
} from "material-react-table";
|
|
21
21
|
|
|
22
|
-
import { availableLayouts,
|
|
22
|
+
import { availableLayouts, availableCardLayouts } from "./constants";
|
|
23
23
|
import { DataFilter } from "../DataFilters";
|
|
24
24
|
import {
|
|
25
25
|
DataGetDataType,
|
|
@@ -31,15 +31,17 @@ import { DataTableRowActionsProps } from "../../DataTable/DataTableRowActions";
|
|
|
31
31
|
import { MenuButtonProps } from "../..";
|
|
32
32
|
import { paginationTypeValues } from "../DataTablePagination";
|
|
33
33
|
import { ReactNode } from "react";
|
|
34
|
-
import {
|
|
34
|
+
import { DataCardProps } from "./DataCard";
|
|
35
35
|
|
|
36
36
|
export type DataLayout = (typeof availableLayouts)[number];
|
|
37
|
-
export type
|
|
37
|
+
export type CardLayout = (typeof availableCardLayouts)[number];
|
|
38
38
|
|
|
39
39
|
export type AvailableLayouts = DataLayout[];
|
|
40
|
-
export type
|
|
40
|
+
export type AvailableCardLayouts = CardLayout[];
|
|
41
41
|
|
|
42
42
|
export type UniversalProps = {
|
|
43
|
+
additionalActionButton?: ReactNode;
|
|
44
|
+
additionalActionMenuItems?: ReactNode;
|
|
43
45
|
bulkActionMenuItems?: (
|
|
44
46
|
selectedRows: MRT_RowSelectionState,
|
|
45
47
|
) => MenuButtonProps["children"];
|
|
@@ -77,7 +79,7 @@ export type UniversalProps = {
|
|
|
77
79
|
totalRows?: number;
|
|
78
80
|
};
|
|
79
81
|
|
|
80
|
-
export type
|
|
82
|
+
export type TableLayoutProps = {
|
|
81
83
|
columns: DataTableColumn<MRT_RowData>[];
|
|
82
84
|
hasChangeableDensity?: boolean;
|
|
83
85
|
hasColumnResizing?: boolean;
|
|
@@ -89,8 +91,8 @@ export type TableProps = {
|
|
|
89
91
|
rowActionMenuItems?: DataTableRowActionsProps["rowActionMenuItems"];
|
|
90
92
|
};
|
|
91
93
|
|
|
92
|
-
export type
|
|
93
|
-
|
|
94
|
+
export type CardLayoutProps = {
|
|
95
|
+
itemProps: (row: MRT_RowData) => DataCardProps;
|
|
94
96
|
maxGridColumns?: number;
|
|
95
97
|
renderDetailPanel?: (props: { row: MRT_RowData }) => ReactNode;
|
|
96
98
|
rowActionMenuItems?: DataTableRowActionsProps["rowActionMenuItems"];
|
|
@@ -99,8 +101,8 @@ export type StackProps = {
|
|
|
99
101
|
export type ViewProps<L extends DataLayout> = {
|
|
100
102
|
availableLayouts?: L[];
|
|
101
103
|
initialLayout?: L;
|
|
102
|
-
|
|
103
|
-
|
|
104
|
+
cardLayoutOptions?: CardLayoutProps;
|
|
105
|
+
tableLayoutOptions?: TableLayoutProps;
|
|
104
106
|
};
|
|
105
107
|
|
|
106
108
|
export type TableState = {
|
|
@@ -14,11 +14,11 @@ import { MRT_DensityState } from "material-react-table";
|
|
|
14
14
|
|
|
15
15
|
export type DataViewLayout = "list" | "grid" | "table";
|
|
16
16
|
|
|
17
|
-
export const
|
|
17
|
+
export const availableCardLayouts: DataViewLayout[] = ["list", "grid"];
|
|
18
18
|
export const availableTableLayouts: DataViewLayout[] = ["table"];
|
|
19
19
|
export const availableLayouts: DataViewLayout[] = [
|
|
20
20
|
...availableTableLayouts,
|
|
21
|
-
...
|
|
21
|
+
...availableCardLayouts,
|
|
22
22
|
];
|
|
23
23
|
|
|
24
24
|
export const densityValues: MRT_DensityState[] = [
|
|
@@ -23,7 +23,7 @@ type DataRequestType = {
|
|
|
23
23
|
getData: UniversalProps["getData"];
|
|
24
24
|
setData: Dispatch<SetStateAction<MRT_RowData[]>>;
|
|
25
25
|
setErrorMessage: Dispatch<SetStateAction<UniversalProps["errorMessage"]>>;
|
|
26
|
-
setIsLoading
|
|
26
|
+
setIsLoading?: Dispatch<SetStateAction<boolean>>;
|
|
27
27
|
};
|
|
28
28
|
|
|
29
29
|
export const fetchData = async ({
|
|
@@ -34,7 +34,7 @@ export const fetchData = async ({
|
|
|
34
34
|
setErrorMessage,
|
|
35
35
|
setIsLoading,
|
|
36
36
|
}: DataRequestType) => {
|
|
37
|
-
setIsLoading(true);
|
|
37
|
+
setIsLoading?.(true);
|
|
38
38
|
setErrorMessage(errorMessageProp);
|
|
39
39
|
try {
|
|
40
40
|
const incomingData = await getData?.(dataQueryParams);
|
|
@@ -42,6 +42,6 @@ export const fetchData = async ({
|
|
|
42
42
|
} catch (error) {
|
|
43
43
|
setErrorMessage(typeof error === "string" ? error : t("table.error"));
|
|
44
44
|
} finally {
|
|
45
|
-
setIsLoading(false);
|
|
45
|
+
setIsLoading?.(false);
|
|
46
46
|
}
|
|
47
47
|
};
|
|
@@ -10,7 +10,6 @@
|
|
|
10
10
|
* See the License for the specific language governing permissions and limitations under the License.
|
|
11
11
|
*/
|
|
12
12
|
|
|
13
|
-
export { DataStack, type DataStackProps } from "./DataStack";
|
|
14
13
|
export { DataTable, type DataTableProps } from "./DataTable";
|
|
15
14
|
export { DataView, type DataViewProps } from "./DataView";
|
|
16
15
|
|
|
@@ -15,10 +15,10 @@ import { MRT_RowData } from "material-react-table";
|
|
|
15
15
|
|
|
16
16
|
import { DataFilter } from "../DataFilters";
|
|
17
17
|
import { DataTableColumn } from "../../DataTable";
|
|
18
|
-
import { UniversalProps,
|
|
18
|
+
import { UniversalProps, TableLayoutProps } from "./componentTypes";
|
|
19
19
|
|
|
20
20
|
type FilterConversionType = {
|
|
21
|
-
columns?:
|
|
21
|
+
columns?: TableLayoutProps["columns"];
|
|
22
22
|
filters?: UniversalProps["filters"];
|
|
23
23
|
};
|
|
24
24
|
|
|
@@ -0,0 +1,48 @@
|
|
|
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 { memo, useMemo, ReactElement } from "react";
|
|
14
|
+
import { CollapseLeftIcon } from "../../icons.generated";
|
|
15
|
+
import { Box } from "../../Box";
|
|
16
|
+
import { Button } from "../../Button";
|
|
17
|
+
import { useOdysseyDesignTokens } from "../../OdysseyDesignTokensContext";
|
|
18
|
+
|
|
19
|
+
const CollapseIcon = ({ onClick }: { onClick?(): void }): ReactElement => {
|
|
20
|
+
const odysseyDesignTokens = useOdysseyDesignTokens();
|
|
21
|
+
|
|
22
|
+
const collapseButtonStyles = useMemo(
|
|
23
|
+
() => ({
|
|
24
|
+
"& > button": {
|
|
25
|
+
height: odysseyDesignTokens.Spacing6,
|
|
26
|
+
width: odysseyDesignTokens.Spacing6,
|
|
27
|
+
color: odysseyDesignTokens.HueNeutral400,
|
|
28
|
+
},
|
|
29
|
+
}),
|
|
30
|
+
[odysseyDesignTokens],
|
|
31
|
+
);
|
|
32
|
+
|
|
33
|
+
return (
|
|
34
|
+
<Box sx={collapseButtonStyles}>
|
|
35
|
+
<Button
|
|
36
|
+
tabIndex={0}
|
|
37
|
+
variant="secondary"
|
|
38
|
+
onClick={onClick}
|
|
39
|
+
startIcon={<CollapseLeftIcon />}
|
|
40
|
+
ariaLabel="collapse side navigation"
|
|
41
|
+
/>
|
|
42
|
+
</Box>
|
|
43
|
+
);
|
|
44
|
+
};
|
|
45
|
+
const MemoizedCollapseIcon = memo(CollapseIcon);
|
|
46
|
+
MemoizedCollapseIcon.displayName = "CollapseIcon";
|
|
47
|
+
|
|
48
|
+
export { MemoizedCollapseIcon as CollapseIcon };
|