@astral/ui 1.16.3 → 1.18.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/ActionCell/ActionCell.js +19 -39
- package/ActionCell/styles.js +5 -7
- package/Alert/Alert.js +11 -22
- package/Alert/styles.js +17 -20
- package/Autocomplete/Autocomplete.js +23 -34
- package/BackdropStack/hooks/useBackdropStackToggle/useBackdropStackToggle.js +11 -12
- package/BackdropStack/services/BackdropStackManager/BackdropStackManager.js +17 -19
- package/Badge/Badge.js +5 -16
- package/Badge/styled.d.ts +2 -16
- package/Badge/styled.js +26 -31
- package/Button/Button.js +10 -21
- package/Button/styles.js +16 -22
- package/ButtonBase/ButtonBase.js +7 -18
- package/ButtonBase/styles.d.ts +3 -3
- package/ButtonBase/styles.js +68 -73
- package/Checkbox/Checkbox.js +6 -17
- package/Checkbox/icons.js +8 -19
- package/Checkbox/styled.js +47 -32
- package/Chevron/Chevron.js +3 -14
- package/Chevron/styles.js +11 -18
- package/CircularProgress/CircularProgress.js +7 -18
- package/CircularProgress/CircularProgressStory.js +4 -4
- package/CircularProgress/CircularProgressStoryTemplate.js +4 -15
- package/Collapse/Collapse.js +1 -1
- package/ConfigProvider/ConfigProvider.js +7 -19
- package/ContentState/ContentState.d.ts +1 -1
- package/ContentState/ContentState.js +12 -24
- package/ContentState/styles.js +8 -7
- package/DashboardLayout/DashboardLayout.js +7 -7
- package/DashboardLayout/DashboardLayoutStory.js +5 -16
- package/DashboardLayout/DashboardLayoutStoryTemplate.js +4 -15
- package/DashboardLayout/Header/Header.js +9 -20
- package/DashboardLayout/Header/styles.js +17 -20
- package/DashboardLayout/Main/Main.js +5 -17
- package/DashboardLayout/Main/styled.js +7 -7
- package/DashboardLayout/Sidebar/Sidebar.js +13 -24
- package/DashboardLayout/Sidebar/SidebarNav/SidebarNav.js +5 -16
- package/DashboardLayout/Sidebar/SidebarToggler/SidebarToggleButton/SidebarToggleButton.js +7 -18
- package/DashboardLayout/Sidebar/SidebarToggler/SidebarToggleButton/styles.js +13 -11
- package/DashboardLayout/Sidebar/SidebarToggler/SidebarToggler.js +8 -19
- package/DashboardLayout/Sidebar/SidebarToggler/styled.js +11 -12
- package/DashboardLayout/Sidebar/styles.js +16 -24
- package/DashboardLayout/styles.js +11 -9
- package/DataGrid/DataGrid.js +25 -50
- package/DataGrid/DataGridBody/DataGridBody.d.ts +2 -2
- package/DataGrid/DataGridBody/DataGridBody.js +19 -31
- package/DataGrid/DataGridBody/styles.js +9 -13
- package/DataGrid/DataGridCell/DataGridCell.d.ts +2 -2
- package/DataGrid/DataGridCell/DataGridCell.js +7 -19
- package/DataGrid/DataGridHead/DataGridHead.d.ts +2 -2
- package/DataGrid/DataGridHead/DataGridHead.js +15 -28
- package/DataGrid/DataGridHeadColumn/DataGridHeadColumn.js +9 -21
- package/DataGrid/DataGridHeadColumn/styles.js +23 -23
- package/DataGrid/DataGridLoader/DataGridLoader.js +3 -4
- package/DataGrid/DataGridLoader/styles.js +22 -15
- package/DataGrid/DataGridNoData/DataGridNoData.js +5 -17
- package/DataGrid/DataGridNoData/styles.js +29 -17
- package/DataGrid/styles.js +12 -13
- package/DataGrid/types.d.ts +1 -1
- package/DataGridPagination/DataGridPagination.js +11 -22
- package/DataGridPagination/styles.js +11 -15
- package/DatePicker/DatePicker.js +22 -33
- package/DatePicker/DatePickerDay/DatePickerDay.js +4 -15
- package/DatePicker/DatePickerDay/styled.js +6 -8
- package/DatePicker/DatePickerHeader/DatePickerHeader.js +12 -23
- package/DatePicker/DatePickerHeader/styled.js +10 -9
- package/DatePicker/styled.js +94 -70
- package/DatePickerProvider/DatePickerProvider.js +4 -4
- package/Description/Description.js +5 -6
- package/Description/Name/Name.js +5 -16
- package/Description/Value/Value.js +6 -17
- package/Description/styles.js +14 -13
- package/Dialog/Dialog.js +8 -19
- package/DialogActions/DialogActions.js +6 -17
- package/DialogTitle/DialogTitle.js +8 -19
- package/Divider/Divider.js +1 -1
- package/DropdownButton/DropdownButton.js +11 -22
- package/ErrorBoundary/ErrorBoundary.js +19 -48
- package/Fab/Fab.js +7 -18
- package/Fab/styles.js +33 -37
- package/Fade/Fade.js +1 -1
- package/FormControlLabel/FormControlLabel.js +4 -15
- package/FormControlLabel/styled.js +10 -11
- package/FormHelperText/FormHelperText.js +6 -6
- package/FormHelperText/styled.js +16 -18
- package/GlobalStyles/GlobalStyles.js +12 -25
- package/Grid/Grid.js +5 -16
- package/Grid/styled.js +5 -11
- package/Grow/Grow.js +1 -1
- package/IconButton/IconButton.js +6 -17
- package/IconButton/styles.js +15 -21
- package/IconDropdownButton/IconDropdownButton.js +10 -21
- package/List/List.js +4 -15
- package/ListItem/ListItem.js +4 -15
- package/ListItem/styles.js +19 -32
- package/ListItemAvatar/ListItemAvatar.js +1 -1
- package/ListItemButton/ListItemButton.js +5 -16
- package/ListItemIcon/ListItemIcon.js +5 -16
- package/ListItemIcon/styled.js +5 -11
- package/ListItemSecondaryAction/ListItemSecondaryAction.js +1 -1
- package/ListItemText/ListItemText.js +4 -15
- package/ListSubheader/ListSubheader.js +1 -1
- package/LocalizationProvider/LocalizationProvider.js +6 -18
- package/MaskField/MaskField.js +12 -23
- package/Menu/Menu.js +1 -1
- package/MenuGroup/MenuGroup.js +7 -18
- package/MenuGroup/stories/Icons.js +8 -19
- package/MenuGroup/stories/styled.js +12 -17
- package/MenuGroup/styled.js +14 -21
- package/MenuItem/MenuItem.js +5 -16
- package/MenuItem/styled.js +5 -11
- package/MenuList/MenuList.js +5 -16
- package/MenuList/styled.js +10 -17
- package/NavMenu/NavMenu.js +7 -18
- package/NavMenu/NavMenuItem/NavMenuItem.js +13 -25
- package/NavMenu/NavMenuItem/NavMenuItemButton/NavMenuItemButton.js +8 -19
- package/NavMenu/NavMenuItem/NavMenuItemButton/styles.js +29 -30
- package/NavMenu/NavMenuItem/NavMenuItemList/NavMenuItemList.js +8 -19
- package/Notification/Notification.js +6 -37
- package/Notification/NotificationContainer/NotificationContainer.js +7 -18
- package/Notification/NotificationContainer/styled.js +16 -7
- package/Notification/NotificationTemplate/NotificationTemplate.js +10 -22
- package/Notification/NotificationTemplate/styled.js +51 -51
- package/Notification/NotificationTemplate/utils/getActionsDirection/getActionsDirection.js +2 -2
- package/Notification/NotificationTemplate/utils/getNotificationTemplateStyles/getNotificationTemplateStyles.js +3 -3
- package/Notification/constants/notificationVariant.js +7 -18
- package/Notification/constants/positions.js +1 -1
- package/Notification/styled.js +18 -27
- package/Notification/utils/getNotificationIconByVariant/getNotificationIconByVariant.js +5 -6
- package/Notification/utils/notificationTemplatePropsCreator/notificationTemplatePropsCreator.js +2 -13
- package/OverflowTypography/OverflowTypography.js +13 -22
- package/OverflowTypography/hooks/useOverflowed/useOverflowed.js +13 -16
- package/OverflowTypography/styles.js +14 -12
- package/Pagination/Pagination.js +4 -15
- package/Placeholder/Placeholder.js +4 -16
- package/Placeholder/styles.js +70 -82
- package/Product/Product.js +6 -17
- package/Profile/Profile.js +10 -21
- package/Profile/styled.js +32 -36
- package/Radio/Icon.js +6 -17
- package/Radio/Radio.d.ts +1 -1
- package/Radio/Radio.js +7 -18
- package/Radio/styled.js +43 -32
- package/Select/Select.js +16 -26
- package/Select/styled.js +36 -31
- package/SideDialog/SideDialog.js +6 -17
- package/SideDialog/styled.js +8 -8
- package/Slide/Slide.js +1 -1
- package/SwipeableDrawer/SwipeableDrawer.js +5 -16
- package/SwipeableDrawer/styles.js +73 -78
- package/Tab/Tab.js +1 -1
- package/Table/Table.js +5 -16
- package/Table/TableBody/TableBody.js +1 -1
- package/Table/TableCell/TableCell.js +1 -1
- package/Table/TableContainer/TableContainer.js +1 -1
- package/Table/TableFooter/TableFooter.js +1 -1
- package/Table/TableHead/TableHead.js +1 -1
- package/Table/TableRow/TableRow.js +1 -1
- package/Table/TableSortLabel/TableSortLabel.js +1 -1
- package/Tabs/Tabs.js +1 -1
- package/Tag/Tag.js +7 -18
- package/Tag/styled.js +84 -60
- package/TextArea/TextArea.js +6 -17
- package/TextField/TextField.js +11 -22
- package/ThemeProvider/ThemeProvider.js +7 -18
- package/Tooltip/Tooltip.js +7 -18
- package/Tooltip/styled.js +43 -58
- package/Typography/Typography.js +8 -19
- package/Zoom/Zoom.js +1 -1
- package/esm/ActionCell/ActionCell.js +11 -31
- package/esm/ActionCell/styles.js +4 -6
- package/esm/Alert/Alert.js +4 -15
- package/esm/Alert/styles.js +15 -18
- package/esm/Autocomplete/Autocomplete.js +12 -23
- package/esm/Autocomplete/constants.js +1 -1
- package/esm/BackdropStack/hooks/useBackdropStackToggle/useBackdropStackToggle.js +8 -9
- package/esm/BackdropStack/services/BackdropStackManager/BackdropStackManager.js +17 -19
- package/esm/Badge/Badge.js +3 -14
- package/esm/Badge/styled.d.ts +2 -16
- package/esm/Badge/styled.js +25 -30
- package/esm/Button/Button.js +4 -15
- package/esm/Button/styles.js +13 -19
- package/esm/ButtonBase/ButtonBase.js +3 -14
- package/esm/ButtonBase/styles.d.ts +3 -3
- package/esm/ButtonBase/styles.js +66 -71
- package/esm/Checkbox/Checkbox.js +3 -14
- package/esm/Checkbox/icons.js +6 -17
- package/esm/Checkbox/styled.js +45 -30
- package/esm/Chevron/Chevron.js +1 -12
- package/esm/Chevron/styles.js +10 -17
- package/esm/CircularProgress/CircularProgress.js +4 -15
- package/esm/CircularProgress/CircularProgressStory.js +2 -2
- package/esm/CircularProgress/CircularProgressStoryTemplate.js +2 -13
- package/esm/ConfigProvider/ConfigProvider.js +5 -17
- package/esm/ContentState/ContentState.d.ts +1 -1
- package/esm/ContentState/ContentState.js +6 -18
- package/esm/ContentState/styles.js +7 -6
- package/esm/DashboardLayout/DashboardLayout.js +2 -2
- package/esm/DashboardLayout/DashboardLayoutStory.js +3 -14
- package/esm/DashboardLayout/DashboardLayoutStoryTemplate.js +2 -13
- package/esm/DashboardLayout/Header/Header.js +4 -15
- package/esm/DashboardLayout/Header/styles.js +16 -19
- package/esm/DashboardLayout/Main/Main.js +2 -14
- package/esm/DashboardLayout/Main/styled.js +6 -6
- package/esm/DashboardLayout/Sidebar/Sidebar.js +6 -17
- package/esm/DashboardLayout/Sidebar/SidebarNav/SidebarNav.js +3 -14
- package/esm/DashboardLayout/Sidebar/SidebarToggler/SidebarToggleButton/SidebarToggleButton.js +3 -14
- package/esm/DashboardLayout/Sidebar/SidebarToggler/SidebarToggleButton/styles.js +11 -9
- package/esm/DashboardLayout/Sidebar/SidebarToggler/SidebarToggler.js +4 -15
- package/esm/DashboardLayout/Sidebar/SidebarToggler/styled.js +9 -10
- package/esm/DashboardLayout/Sidebar/styles.js +15 -23
- package/esm/DashboardLayout/styles.js +10 -8
- package/esm/DataGrid/DataGrid.js +17 -42
- package/esm/DataGrid/DataGridBody/DataGridBody.d.ts +2 -2
- package/esm/DataGrid/DataGridBody/DataGridBody.js +13 -25
- package/esm/DataGrid/DataGridBody/styles.js +8 -12
- package/esm/DataGrid/DataGridCell/DataGridCell.d.ts +2 -2
- package/esm/DataGrid/DataGridCell/DataGridCell.js +3 -15
- package/esm/DataGrid/DataGridHead/DataGridHead.d.ts +2 -2
- package/esm/DataGrid/DataGridHead/DataGridHead.js +8 -21
- package/esm/DataGrid/DataGridHeadColumn/DataGridHeadColumn.js +4 -16
- package/esm/DataGrid/DataGridHeadColumn/styles.js +21 -21
- package/esm/DataGrid/DataGridLoader/DataGridLoader.js +1 -2
- package/esm/DataGrid/DataGridLoader/styles.js +19 -12
- package/esm/DataGrid/DataGridNoData/DataGridNoData.js +3 -15
- package/esm/DataGrid/DataGridNoData/styles.js +27 -15
- package/esm/DataGrid/styles.js +11 -12
- package/esm/DataGrid/types.d.ts +1 -1
- package/esm/DataGridPagination/DataGridPagination.js +7 -18
- package/esm/DataGridPagination/styles.js +9 -13
- package/esm/DatePicker/DatePicker.js +11 -22
- package/esm/DatePicker/DatePickerDay/DatePickerDay.js +2 -13
- package/esm/DatePicker/DatePickerDay/styled.js +4 -6
- package/esm/DatePicker/DatePickerHeader/DatePickerHeader.js +5 -16
- package/esm/DatePicker/DatePickerHeader/styled.js +8 -7
- package/esm/DatePicker/styled.js +93 -69
- package/esm/DatePickerProvider/DatePickerProvider.js +2 -2
- package/esm/Description/Description.js +1 -2
- package/esm/Description/Name/Name.js +3 -14
- package/esm/Description/Value/Value.js +4 -15
- package/esm/Description/styles.js +13 -12
- package/esm/Dialog/Dialog.js +5 -16
- package/esm/DialogActions/DialogActions.js +3 -14
- package/esm/DialogTitle/DialogTitle.js +4 -15
- package/esm/DropdownButton/DropdownButton.js +4 -15
- package/esm/ErrorBoundary/ErrorBoundary.js +14 -43
- package/esm/Fab/Fab.js +3 -14
- package/esm/Fab/styles.js +31 -35
- package/esm/FormControlLabel/FormControlLabel.js +2 -13
- package/esm/FormControlLabel/styled.js +8 -9
- package/esm/FormHelperText/FormHelperText.js +3 -3
- package/esm/FormHelperText/styled.js +14 -16
- package/esm/GlobalStyles/GlobalStyles.js +8 -21
- package/esm/Grid/Grid.js +3 -14
- package/esm/Grid/styled.js +3 -9
- package/esm/IconButton/IconButton.js +3 -14
- package/esm/IconButton/styles.js +14 -20
- package/esm/IconDropdownButton/IconDropdownButton.js +4 -15
- package/esm/List/List.js +2 -13
- package/esm/ListItem/ListItem.js +2 -13
- package/esm/ListItem/styles.js +17 -30
- package/esm/ListItemButton/ListItemButton.js +2 -13
- package/esm/ListItemIcon/ListItemIcon.js +2 -13
- package/esm/ListItemIcon/styled.js +3 -9
- package/esm/ListItemText/ListItemText.js +2 -13
- package/esm/LocalizationProvider/LocalizationProvider.js +2 -14
- package/esm/MaskField/MaskField.js +9 -20
- package/esm/MenuGroup/MenuGroup.js +4 -15
- package/esm/MenuGroup/stories/Icons.js +7 -18
- package/esm/MenuGroup/stories/styled.js +9 -14
- package/esm/MenuGroup/styled.js +12 -19
- package/esm/MenuItem/MenuItem.js +3 -14
- package/esm/MenuItem/styled.js +3 -9
- package/esm/MenuList/MenuList.js +3 -14
- package/esm/MenuList/styled.js +8 -15
- package/esm/NavMenu/NavMenu.js +3 -14
- package/esm/NavMenu/NavMenuItem/NavMenuItem.js +8 -20
- package/esm/NavMenu/NavMenuItem/NavMenuItemButton/NavMenuItemButton.js +3 -14
- package/esm/NavMenu/NavMenuItem/NavMenuItemButton/styles.js +25 -26
- package/esm/NavMenu/NavMenuItem/NavMenuItemList/NavMenuItemList.js +4 -15
- package/esm/Notification/Notification.js +5 -36
- package/esm/Notification/NotificationContainer/NotificationContainer.js +2 -13
- package/esm/Notification/NotificationContainer/styled.js +15 -6
- package/esm/Notification/NotificationTemplate/NotificationTemplate.js +6 -18
- package/esm/Notification/NotificationTemplate/styled.js +48 -48
- package/esm/Notification/NotificationTemplate/utils/getActionsDirection/getActionsDirection.js +2 -2
- package/esm/Notification/NotificationTemplate/utils/getNotificationTemplateStyles/getNotificationTemplateStyles.js +3 -3
- package/esm/Notification/constants/defaultNotificationProps.js +1 -1
- package/esm/Notification/constants/notificationVariant.js +5 -16
- package/esm/Notification/constants/positions.js +1 -1
- package/esm/Notification/styled.js +20 -29
- package/esm/Notification/utils/getNotificationIconByVariant/getNotificationIconByVariant.js +2 -3
- package/esm/Notification/utils/notificationTemplatePropsCreator/notificationTemplatePropsCreator.js +2 -13
- package/esm/OverflowTypography/OverflowTypography.js +9 -18
- package/esm/OverflowTypography/hooks/useOverflowed/useOverflowed.js +11 -14
- package/esm/OverflowTypography/styles.js +13 -11
- package/esm/Pagination/Pagination.js +2 -13
- package/esm/Placeholder/Placeholder.js +2 -14
- package/esm/Placeholder/styles.js +68 -80
- package/esm/Product/Product.js +3 -14
- package/esm/Profile/Profile.js +4 -15
- package/esm/Profile/styled.js +30 -34
- package/esm/Radio/Icon.js +4 -15
- package/esm/Radio/Radio.d.ts +1 -1
- package/esm/Radio/Radio.js +3 -14
- package/esm/Radio/styled.js +41 -30
- package/esm/Select/Select.js +8 -18
- package/esm/Select/styled.js +34 -29
- package/esm/SideDialog/SideDialog.js +3 -14
- package/esm/SideDialog/styled.js +6 -6
- package/esm/SwipeableDrawer/SwipeableDrawer.js +3 -14
- package/esm/SwipeableDrawer/styles.js +71 -76
- package/esm/Table/Table.js +3 -14
- package/esm/Tag/Tag.js +3 -14
- package/esm/Tag/styled.js +82 -58
- package/esm/TextArea/TextArea.js +3 -14
- package/esm/TextField/TextField.js +7 -18
- package/esm/ThemeProvider/ThemeProvider.js +3 -14
- package/esm/Tooltip/Tooltip.js +3 -14
- package/esm/Tooltip/styled.js +39 -54
- package/esm/Typography/Typography.js +4 -15
- package/esm/hooks/useMenu.js +7 -8
- package/esm/theme/baseTheme/baseTheme.js +7 -7
- package/esm/theme/baseTheme/baseTheme.test.js +12 -12
- package/esm/theme/breakpoints.js +1 -1
- package/esm/theme/components/MuiAlert.js +7 -12
- package/esm/theme/components/MuiAutocomplete.js +13 -20
- package/esm/theme/components/MuiButton.js +42 -43
- package/esm/theme/components/MuiButtonBase.js +1 -1
- package/esm/theme/components/MuiCircularProgress.js +3 -4
- package/esm/theme/components/MuiDialog.js +3 -5
- package/esm/theme/components/MuiDialogActions.js +2 -3
- package/esm/theme/components/MuiDialogContent.js +2 -3
- package/esm/theme/components/MuiDialogTitle.js +2 -3
- package/esm/theme/components/MuiFormHelperText.js +2 -3
- package/esm/theme/components/MuiFormLabel.js +2 -2
- package/esm/theme/components/MuiInputBase.js +2 -3
- package/esm/theme/components/MuiInputLabel.js +2 -3
- package/esm/theme/components/MuiListItemButton.js +2 -3
- package/esm/theme/components/MuiListItemText.js +2 -2
- package/esm/theme/components/MuiLoadingButton.js +10 -12
- package/esm/theme/components/MuiMenu.js +3 -5
- package/esm/theme/components/MuiMenuItem.js +2 -3
- package/esm/theme/components/MuiOutlinedInput.js +7 -12
- package/esm/theme/components/MuiPaginationItem.js +5 -7
- package/esm/theme/components/MuiTab.js +2 -3
- package/esm/theme/components/MuiTableCell.js +2 -2
- package/esm/theme/components/MuiTableHead.js +3 -4
- package/esm/theme/components/MuiTableRow.js +2 -3
- package/esm/theme/components/MuiTabs.js +3 -4
- package/esm/theme/components/MuiTypography.js +1 -1
- package/esm/theme/components/components.js +64 -35
- package/esm/theme/constants.js +1 -1
- package/esm/theme/elevation.js +1 -1
- package/esm/theme/hooks/useTheme/index.js +1 -1
- package/esm/theme/palette/brandPalette.js +16 -17
- package/esm/theme/palette/palette.js +3 -15
- package/esm/theme/shape.js +1 -1
- package/esm/theme/typography.js +4 -5
- package/hooks/useMenu.js +8 -9
- package/package.json +14 -14
- package/theme/baseTheme/baseTheme.js +14 -14
- package/theme/baseTheme/baseTheme.test.js +14 -14
- package/theme/components/MuiAlert.js +6 -11
- package/theme/components/MuiAutocomplete.js +13 -20
- package/theme/components/MuiButton.js +43 -44
- package/theme/components/MuiCircularProgress.js +2 -3
- package/theme/components/MuiDialog.js +2 -4
- package/theme/components/MuiDialogActions.js +1 -2
- package/theme/components/MuiDialogContent.js +1 -2
- package/theme/components/MuiDialogTitle.js +1 -2
- package/theme/components/MuiFormHelperText.js +1 -2
- package/theme/components/MuiFormLabel.js +1 -1
- package/theme/components/MuiInputBase.js +1 -2
- package/theme/components/MuiInputLabel.js +1 -2
- package/theme/components/MuiListItemButton.js +1 -2
- package/theme/components/MuiListItemText.js +1 -1
- package/theme/components/MuiLoadingButton.js +12 -14
- package/theme/components/MuiMenu.js +2 -4
- package/theme/components/MuiMenuItem.js +1 -2
- package/theme/components/MuiOutlinedInput.js +6 -11
- package/theme/components/MuiPaginationItem.js +4 -6
- package/theme/components/MuiTab.js +1 -2
- package/theme/components/MuiTableCell.js +1 -1
- package/theme/components/MuiTableHead.js +2 -3
- package/theme/components/MuiTableRow.js +1 -2
- package/theme/components/MuiTabs.js +2 -3
- package/theme/components/components.js +64 -35
- package/theme/hooks/useTheme/index.js +2 -2
- package/theme/palette/brandPalette.js +17 -18
- package/theme/palette/palette.js +5 -17
- package/theme/typography.js +3 -4
- package/docs/Case/Case.d.ts +0 -8
- package/docs/Case/Case.js +0 -31
- package/docs/Case/index.d.ts +0 -1
- package/docs/Case/index.js +0 -17
- package/docs/Case/styles.d.ts +0 -5
- package/docs/Case/styles.js +0 -16
- package/docs/ExampleTemplate/ExampleTemplate.d.ts +0 -13
- package/docs/ExampleTemplate/ExampleTemplate.js +0 -26
- package/docs/ExampleTemplate/index.d.ts +0 -1
- package/docs/ExampleTemplate/index.js +0 -17
- package/docs/ExampleTemplate/styles.d.ts +0 -9
- package/docs/ExampleTemplate/styles.js +0 -13
- package/docs/index.d.ts +0 -2
- package/docs/index.js +0 -18
- package/esm/docs/Case/Case.d.ts +0 -8
- package/esm/docs/Case/Case.js +0 -27
- package/esm/docs/Case/index.d.ts +0 -1
- package/esm/docs/Case/index.js +0 -1
- package/esm/docs/Case/styles.d.ts +0 -5
- package/esm/docs/Case/styles.js +0 -13
- package/esm/docs/ExampleTemplate/ExampleTemplate.d.ts +0 -13
- package/esm/docs/ExampleTemplate/ExampleTemplate.js +0 -22
- package/esm/docs/ExampleTemplate/index.d.ts +0 -1
- package/esm/docs/ExampleTemplate/index.js +0 -1
- package/esm/docs/ExampleTemplate/styles.d.ts +0 -9
- package/esm/docs/ExampleTemplate/styles.js +0 -10
- package/esm/docs/index.d.ts +0 -2
- package/esm/docs/index.js +0 -2
|
@@ -1,26 +1,24 @@
|
|
|
1
1
|
import { loadingButtonClasses } from '@mui/lab';
|
|
2
2
|
import { ButtonStates } from '../../ButtonBase';
|
|
3
3
|
import { getBgColor } from '../../ButtonBase/styles';
|
|
4
|
-
export
|
|
4
|
+
export const MuiLoadingButton = {
|
|
5
5
|
defaultProps: {
|
|
6
6
|
disableRipple: true,
|
|
7
7
|
},
|
|
8
8
|
styleOverrides: {
|
|
9
|
-
root
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
return _b = {},
|
|
15
|
-
_b["&.".concat(loadingButtonClasses.loading)] = {
|
|
9
|
+
root({ ownerState, theme }) {
|
|
10
|
+
const customVariant = ownerState.variant;
|
|
11
|
+
const customColor = ownerState.color;
|
|
12
|
+
return {
|
|
13
|
+
[`&.${loadingButtonClasses.loading}`]: {
|
|
16
14
|
backgroundColor: getBgColor({
|
|
17
|
-
customColor
|
|
18
|
-
customVariant
|
|
19
|
-
theme
|
|
15
|
+
customColor,
|
|
16
|
+
customVariant,
|
|
17
|
+
theme,
|
|
20
18
|
buttonState: ButtonStates.Default,
|
|
21
19
|
}),
|
|
22
20
|
},
|
|
23
|
-
|
|
21
|
+
};
|
|
24
22
|
},
|
|
25
23
|
},
|
|
26
24
|
};
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
export
|
|
1
|
+
export const MuiMenu = {
|
|
2
2
|
defaultProps: {
|
|
3
3
|
autoFocus: false,
|
|
4
4
|
},
|
|
5
5
|
styleOverrides: {
|
|
6
|
-
paper
|
|
7
|
-
var theme = _a.theme;
|
|
6
|
+
paper({ theme }) {
|
|
8
7
|
return {
|
|
9
8
|
marginTop: theme.spacing(2),
|
|
10
9
|
'&.MuiPaper-root': {
|
|
@@ -13,8 +12,7 @@ export var MuiMenu = {
|
|
|
13
12
|
},
|
|
14
13
|
};
|
|
15
14
|
},
|
|
16
|
-
list
|
|
17
|
-
var theme = _a.theme;
|
|
15
|
+
list({ theme }) {
|
|
18
16
|
return {
|
|
19
17
|
padding: theme.spacing(1, 0),
|
|
20
18
|
};
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
export
|
|
1
|
+
export const MuiOutlinedInput = {
|
|
2
2
|
defaultProps: {
|
|
3
3
|
notched: false,
|
|
4
4
|
},
|
|
5
5
|
styleOverrides: {
|
|
6
|
-
root
|
|
7
|
-
var theme = _a.theme;
|
|
6
|
+
root({ theme }) {
|
|
8
7
|
return {
|
|
9
8
|
fontSize: theme.typography.pxToRem(14),
|
|
10
9
|
borderRadius: theme.shape.small,
|
|
@@ -30,8 +29,7 @@ export var MuiOutlinedInput = {
|
|
|
30
29
|
},
|
|
31
30
|
};
|
|
32
31
|
},
|
|
33
|
-
input
|
|
34
|
-
var theme = _a.theme;
|
|
32
|
+
input({ theme }) {
|
|
35
33
|
return {
|
|
36
34
|
height: 20,
|
|
37
35
|
padding: theme.spacing(2.5, 2),
|
|
@@ -45,27 +43,24 @@ export var MuiOutlinedInput = {
|
|
|
45
43
|
},
|
|
46
44
|
};
|
|
47
45
|
},
|
|
48
|
-
inputSizeSmall
|
|
49
|
-
var theme = _a.theme;
|
|
46
|
+
inputSizeSmall({ theme }) {
|
|
50
47
|
return {
|
|
51
48
|
paddingBlock: theme.spacing(1.5),
|
|
52
49
|
paddingInline: theme.spacing(2),
|
|
53
50
|
};
|
|
54
51
|
},
|
|
55
|
-
notchedOutline
|
|
56
|
-
var theme = _a.theme;
|
|
52
|
+
notchedOutline({ theme }) {
|
|
57
53
|
return {
|
|
58
54
|
borderWidth: 2,
|
|
59
55
|
borderColor: theme.palette.grey[300],
|
|
60
56
|
};
|
|
61
57
|
},
|
|
62
|
-
multiline
|
|
58
|
+
multiline() {
|
|
63
59
|
return {
|
|
64
60
|
padding: 0,
|
|
65
61
|
};
|
|
66
62
|
},
|
|
67
|
-
inputMultiline
|
|
68
|
-
var theme = _a.theme;
|
|
63
|
+
inputMultiline({ theme }) {
|
|
69
64
|
return {
|
|
70
65
|
padding: theme.spacing(2),
|
|
71
66
|
};
|
|
@@ -1,14 +1,12 @@
|
|
|
1
|
-
export
|
|
1
|
+
export const MuiPaginationItem = {
|
|
2
2
|
styleOverrides: {
|
|
3
|
-
root
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
return _b = {},
|
|
7
|
-
_b['&.Mui-selected'] = {
|
|
3
|
+
root({ theme }) {
|
|
4
|
+
return {
|
|
5
|
+
['&.Mui-selected']: {
|
|
8
6
|
backgroundColor: theme.palette.grey['900'],
|
|
9
7
|
color: theme.palette.primary.contrastText,
|
|
10
8
|
},
|
|
11
|
-
|
|
9
|
+
};
|
|
12
10
|
},
|
|
13
11
|
},
|
|
14
12
|
};
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
export
|
|
1
|
+
export const MuiTableHead = {
|
|
2
2
|
styleOverrides: {
|
|
3
|
-
root
|
|
4
|
-
var theme = _a.theme;
|
|
3
|
+
root({ theme }) {
|
|
5
4
|
return {
|
|
6
5
|
th: {
|
|
7
|
-
borderBottom:
|
|
6
|
+
borderBottom: `2px solid ${theme.palette.grey['300']}`,
|
|
8
7
|
},
|
|
9
8
|
};
|
|
10
9
|
},
|
|
@@ -1,13 +1,12 @@
|
|
|
1
|
-
export
|
|
1
|
+
export const MuiTabs = {
|
|
2
2
|
styleOverrides: {
|
|
3
|
-
root
|
|
3
|
+
root() {
|
|
4
4
|
return {
|
|
5
5
|
minHeight: 38,
|
|
6
6
|
height: 38,
|
|
7
7
|
};
|
|
8
8
|
},
|
|
9
|
-
indicator
|
|
10
|
-
var theme = _a.theme;
|
|
9
|
+
indicator({ theme }) {
|
|
11
10
|
return {
|
|
12
11
|
borderRadius: theme.shape.small,
|
|
13
12
|
};
|
|
@@ -24,47 +24,76 @@ import { MuiListItemButton } from './MuiListItemButton';
|
|
|
24
24
|
import { MuiListItemText } from './MuiListItemText';
|
|
25
25
|
import { MuiTab } from './MuiTab';
|
|
26
26
|
import { MuiTabs } from './MuiTabs';
|
|
27
|
-
|
|
28
|
-
styleOverrides:
|
|
29
|
-
|
|
30
|
-
|
|
27
|
+
const getMuiCssBaseline = (fontUrls) => ({
|
|
28
|
+
styleOverrides: `
|
|
29
|
+
@font-face {
|
|
30
|
+
font-family: 'Ubuntu';
|
|
31
|
+
font-style: 'normal';
|
|
32
|
+
font-weight: 300;
|
|
33
|
+
font-display: swap;
|
|
34
|
+
src: url(${fontUrls.light.woff2}) format('woff2'), url(${fontUrls.light.woff}) format('woff');
|
|
35
|
+
}
|
|
36
|
+
@font-face {
|
|
37
|
+
font-family: 'Ubuntu';
|
|
38
|
+
font-style: 'normal';
|
|
39
|
+
font-weight: 400;
|
|
40
|
+
font-display: swap;
|
|
41
|
+
src: url(${fontUrls.regular.woff2}) format('woff2'), url(${fontUrls.regular.woff}) format('woff');
|
|
42
|
+
}
|
|
43
|
+
@font-face {
|
|
44
|
+
font-family: 'Ubuntu';
|
|
45
|
+
font-style: 'normal';
|
|
46
|
+
font-weight: 500;
|
|
47
|
+
font-display: swap;
|
|
48
|
+
src: url(${fontUrls.medium.woff2}) format('woff2'), url(${fontUrls.medium.woff}) format('woff');
|
|
49
|
+
}
|
|
50
|
+
@font-face {
|
|
51
|
+
font-family: 'Ubuntu';
|
|
52
|
+
font-style: 'normal';
|
|
53
|
+
font-weight: 700;
|
|
54
|
+
font-display: swap;
|
|
55
|
+
src: url(${fontUrls.bold.woff2}) format('woff2'), url(${fontUrls.bold.woff}) format('woff');
|
|
56
|
+
}
|
|
57
|
+
`,
|
|
58
|
+
});
|
|
59
|
+
const MuiCheckbox = {
|
|
31
60
|
defaultProps: {
|
|
32
61
|
disableRipple: true,
|
|
33
62
|
},
|
|
34
63
|
};
|
|
35
|
-
|
|
64
|
+
const MuiRadio = {
|
|
36
65
|
defaultProps: {
|
|
37
66
|
disableRipple: true,
|
|
38
67
|
},
|
|
39
68
|
};
|
|
40
|
-
export
|
|
69
|
+
export const getComponents = (fontUrls) => ({
|
|
41
70
|
MuiCssBaseline: getMuiCssBaseline(fontUrls),
|
|
42
|
-
MuiAlert
|
|
43
|
-
MuiButton
|
|
44
|
-
MuiButtonBase
|
|
45
|
-
MuiLoadingButton
|
|
46
|
-
MuiTypography
|
|
47
|
-
MuiInputBase
|
|
48
|
-
MuiInputLabel
|
|
49
|
-
MuiOutlinedInput
|
|
50
|
-
MuiFormLabel
|
|
51
|
-
MuiFormHelperText
|
|
52
|
-
MuiAutocomplete
|
|
53
|
-
MuiCheckbox
|
|
54
|
-
MuiMenu
|
|
55
|
-
MuiMenuItem
|
|
56
|
-
MuiRadio
|
|
57
|
-
MuiDialog
|
|
58
|
-
MuiDialogTitle
|
|
59
|
-
MuiDialogContent
|
|
60
|
-
MuiDialogActions
|
|
61
|
-
MuiTableCell
|
|
62
|
-
MuiTableHead
|
|
63
|
-
MuiTableRow
|
|
64
|
-
MuiPaginationItem
|
|
65
|
-
MuiCircularProgress
|
|
66
|
-
MuiListItemButton
|
|
67
|
-
MuiListItemText
|
|
68
|
-
MuiTab
|
|
69
|
-
MuiTabs
|
|
70
|
-
});
|
|
71
|
+
MuiAlert,
|
|
72
|
+
MuiButton,
|
|
73
|
+
MuiButtonBase,
|
|
74
|
+
MuiLoadingButton,
|
|
75
|
+
MuiTypography,
|
|
76
|
+
MuiInputBase,
|
|
77
|
+
MuiInputLabel,
|
|
78
|
+
MuiOutlinedInput,
|
|
79
|
+
MuiFormLabel,
|
|
80
|
+
MuiFormHelperText,
|
|
81
|
+
MuiAutocomplete,
|
|
82
|
+
MuiCheckbox,
|
|
83
|
+
MuiMenu,
|
|
84
|
+
MuiMenuItem,
|
|
85
|
+
MuiRadio,
|
|
86
|
+
MuiDialog,
|
|
87
|
+
MuiDialogTitle,
|
|
88
|
+
MuiDialogContent,
|
|
89
|
+
MuiDialogActions,
|
|
90
|
+
MuiTableCell,
|
|
91
|
+
MuiTableHead,
|
|
92
|
+
MuiTableRow,
|
|
93
|
+
MuiPaginationItem,
|
|
94
|
+
MuiCircularProgress,
|
|
95
|
+
MuiListItemButton,
|
|
96
|
+
MuiListItemText,
|
|
97
|
+
MuiTab,
|
|
98
|
+
MuiTabs,
|
|
99
|
+
});
|
package/esm/theme/constants.js
CHANGED
package/esm/theme/elevation.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { useTheme as useEmotionTheme } from '@emotion/react';
|
|
2
2
|
// any необходим для коннекта темы
|
|
3
3
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
4
|
-
export
|
|
4
|
+
export const useTheme = () => useEmotionTheme();
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
var _a;
|
|
2
1
|
import { Brand } from '../constants';
|
|
3
|
-
|
|
2
|
+
const defaultBrandPalette = {
|
|
4
3
|
secondary: '#55B8F0',
|
|
5
4
|
900: '#0F52B8',
|
|
6
5
|
800: '#2165CC',
|
|
@@ -12,7 +11,7 @@ var defaultBrandPalette = {
|
|
|
12
11
|
200: '#C5DCFF',
|
|
13
12
|
100: '#E1EDFF',
|
|
14
13
|
};
|
|
15
|
-
|
|
14
|
+
const edoPalette = {
|
|
16
15
|
secondary: '#5653FF',
|
|
17
16
|
900: '#5D3FD4',
|
|
18
17
|
800: '#6746EB',
|
|
@@ -24,7 +23,7 @@ var edoPalette = {
|
|
|
24
23
|
200: '#E0D9FF',
|
|
25
24
|
100: '#EFEBFF',
|
|
26
25
|
};
|
|
27
|
-
|
|
26
|
+
const kedoPalette = {
|
|
28
27
|
secondary: '#5653FF',
|
|
29
28
|
900: '#5D3FD4',
|
|
30
29
|
800: '#6746EB',
|
|
@@ -36,7 +35,7 @@ var kedoPalette = {
|
|
|
36
35
|
200: '#E0D9FF',
|
|
37
36
|
100: '#EFEBFF',
|
|
38
37
|
};
|
|
39
|
-
|
|
38
|
+
const ao5Palette = {
|
|
40
39
|
secondary: '#14A5D3',
|
|
41
40
|
900: '#0068B2',
|
|
42
41
|
800: '#0074C6',
|
|
@@ -48,7 +47,7 @@ var ao5Palette = {
|
|
|
48
47
|
200: '#C1E2F8',
|
|
49
48
|
100: '#DFF0FB',
|
|
50
49
|
};
|
|
51
|
-
|
|
50
|
+
const ofdPalette = {
|
|
52
51
|
secondary: '#22BDEE',
|
|
53
52
|
900: '#1F78D6',
|
|
54
53
|
800: '#2285EE',
|
|
@@ -60,7 +59,7 @@ var ofdPalette = {
|
|
|
60
59
|
200: '#D1E7FF',
|
|
61
60
|
100: '#E7F3FF',
|
|
62
61
|
};
|
|
63
|
-
|
|
62
|
+
const signPalette = {
|
|
64
63
|
secondary: '#4099AC',
|
|
65
64
|
900: '#325D89',
|
|
66
65
|
800: '#376798',
|
|
@@ -72,7 +71,7 @@ var signPalette = {
|
|
|
72
71
|
200: '#D3E1EF',
|
|
73
72
|
100: '#E8EFF7',
|
|
74
73
|
};
|
|
75
|
-
|
|
74
|
+
const lkpPalette = {
|
|
76
75
|
secondary: '#00BDB2',
|
|
77
76
|
900: '#009E71',
|
|
78
77
|
800: '#00B07E',
|
|
@@ -84,12 +83,12 @@ var lkpPalette = {
|
|
|
84
83
|
200: '#CAF1E6',
|
|
85
84
|
100: '#E3F8F2',
|
|
86
85
|
};
|
|
87
|
-
export
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
86
|
+
export const brandPalette = {
|
|
87
|
+
[Brand.DEFAULT]: defaultBrandPalette,
|
|
88
|
+
[Brand.AO5]: ao5Palette,
|
|
89
|
+
[Brand.EDO]: edoPalette,
|
|
90
|
+
[Brand.KEDO]: kedoPalette,
|
|
91
|
+
[Brand.OFD]: ofdPalette,
|
|
92
|
+
[Brand.SIGN]: signPalette,
|
|
93
|
+
[Brand.LKP]: lkpPalette,
|
|
94
|
+
};
|
|
@@ -1,19 +1,7 @@
|
|
|
1
|
-
var __assign = (this && this.__assign) || function () {
|
|
2
|
-
__assign = Object.assign || function(t) {
|
|
3
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
-
s = arguments[i];
|
|
5
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
-
t[p] = s[p];
|
|
7
|
-
}
|
|
8
|
-
return t;
|
|
9
|
-
};
|
|
10
|
-
return __assign.apply(this, arguments);
|
|
11
|
-
};
|
|
12
1
|
import { Brand } from '../constants';
|
|
13
2
|
import { brandPalette } from './brandPalette';
|
|
14
|
-
export
|
|
15
|
-
|
|
16
|
-
var brandColors = brandPalette[brand];
|
|
3
|
+
export const getPalette = (brand = Brand.DEFAULT) => {
|
|
4
|
+
const brandColors = brandPalette[brand];
|
|
17
5
|
return {
|
|
18
6
|
red: {
|
|
19
7
|
900: '#E64343',
|
|
@@ -48,7 +36,7 @@ export var getPalette = function (brand) {
|
|
|
48
36
|
200: '#FBE6CC',
|
|
49
37
|
100: '#FEF3E6',
|
|
50
38
|
},
|
|
51
|
-
primary:
|
|
39
|
+
primary: Object.assign({ main: brandColors[800], dark: brandColors[900], contrastText: '#FFF' }, brandColors),
|
|
52
40
|
secondary: {
|
|
53
41
|
main: brandColors.secondary,
|
|
54
42
|
dark: brandColors[900],
|
package/esm/theme/shape.js
CHANGED
package/esm/theme/typography.js
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
const HTML_FONT_SIZE = 14;
|
|
2
2
|
// Т.к. нет досутпа к теме, написал функцию для конвертации px в rem
|
|
3
|
-
export
|
|
4
|
-
|
|
5
|
-
return "".concat(fontSize / htmlFontSize, "rem");
|
|
3
|
+
export const pxToRem = (fontSize, htmlFontSize = HTML_FONT_SIZE) => {
|
|
4
|
+
return `${fontSize / htmlFontSize}rem`;
|
|
6
5
|
};
|
|
7
|
-
export
|
|
6
|
+
export const typography = {
|
|
8
7
|
fontSize: 14,
|
|
9
8
|
htmlFontSize: 14,
|
|
10
9
|
fontWeightLight: 300,
|
package/hooks/useMenu.js
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.useMenu = void 0;
|
|
4
|
-
|
|
5
|
-
function useMenu(ref) {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
(0, react_1.useEffect)(function () {
|
|
4
|
+
const react_1 = require("react");
|
|
5
|
+
function useMenu(ref = null) {
|
|
6
|
+
const [open, setOpen] = (0, react_1.useState)(false);
|
|
7
|
+
const anchorRef = (0, react_1.useRef)(null);
|
|
8
|
+
(0, react_1.useEffect)(() => {
|
|
10
9
|
if (!ref) {
|
|
11
10
|
return;
|
|
12
11
|
}
|
|
@@ -17,8 +16,8 @@ function useMenu(ref) {
|
|
|
17
16
|
ref.current = anchorRef.current;
|
|
18
17
|
}
|
|
19
18
|
}, [ref]);
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
return { open
|
|
19
|
+
const handleCloseMenu = () => setOpen(false);
|
|
20
|
+
const handleOpenMenu = () => setOpen(true);
|
|
21
|
+
return { open, anchorRef, handleCloseMenu, handleOpenMenu };
|
|
23
22
|
}
|
|
24
23
|
exports.useMenu = useMenu;
|
package/package.json
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@astral/ui",
|
|
3
|
+
"version": "1.18.0",
|
|
3
4
|
"browser": "./src/index.ts",
|
|
5
|
+
"main": "./index.js",
|
|
4
6
|
"dependencies": {
|
|
5
|
-
"@astral/icons": "^1.
|
|
7
|
+
"@astral/icons": "^1.18.0",
|
|
6
8
|
"@emotion/cache": "11.7.1",
|
|
7
9
|
"@emotion/react": "11.9.0",
|
|
8
10
|
"@emotion/server": "11.4.0",
|
|
@@ -21,17 +23,6 @@
|
|
|
21
23
|
"peerDependencies": {
|
|
22
24
|
"react": ">=17.0.0"
|
|
23
25
|
},
|
|
24
|
-
"exports": {
|
|
25
|
-
".": {
|
|
26
|
-
"import": "./esm/index.js",
|
|
27
|
-
"require": "./index.js"
|
|
28
|
-
},
|
|
29
|
-
"./server": {
|
|
30
|
-
"import": "./esm/server/index.js",
|
|
31
|
-
"require": "./server/index.js"
|
|
32
|
-
}
|
|
33
|
-
},
|
|
34
|
-
"version": "1.16.3",
|
|
35
26
|
"author": "Astral.Soft",
|
|
36
27
|
"license": "MIT",
|
|
37
28
|
"repository": {
|
|
@@ -44,6 +35,15 @@
|
|
|
44
35
|
"keywords": [],
|
|
45
36
|
"sideEffects": false,
|
|
46
37
|
"types": "./esm/index.d.ts",
|
|
47
|
-
"
|
|
48
|
-
"
|
|
38
|
+
"module": "./esm/index.js",
|
|
39
|
+
"exports": {
|
|
40
|
+
".": {
|
|
41
|
+
"import": "./esm/index.js",
|
|
42
|
+
"require": "./index.js"
|
|
43
|
+
},
|
|
44
|
+
"./server": {
|
|
45
|
+
"import": "./esm/server/index.js",
|
|
46
|
+
"require": "./server/index.js"
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
49
|
}
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.createTheme = void 0;
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
4
|
+
const styles_1 = require("@mui/material/styles");
|
|
5
|
+
const lodash_es_1 = require("lodash-es");
|
|
6
|
+
const typography_1 = require("../typography");
|
|
7
|
+
const palette_1 = require("../palette");
|
|
8
|
+
const components_1 = require("../components");
|
|
9
|
+
const constants_1 = require("../constants");
|
|
10
|
+
const elevation_1 = require("../elevation");
|
|
11
|
+
const shape_1 = require("../shape");
|
|
12
|
+
const breakpoints_1 = require("../breakpoints");
|
|
13
|
+
const createTheme = (params) => {
|
|
14
|
+
const { brand, options, fontsUrls, breakpoints = breakpoints_1.defaultBreakpoints, } = params;
|
|
15
|
+
const themeOptions = {
|
|
16
16
|
typography: typography_1.typography,
|
|
17
|
-
breakpoints
|
|
17
|
+
breakpoints,
|
|
18
18
|
spacing: constants_1.SPACING,
|
|
19
19
|
palette: (0, palette_1.getPalette)(brand),
|
|
20
20
|
components: (0, components_1.getComponents)(fontsUrls),
|
|
21
21
|
};
|
|
22
|
-
|
|
22
|
+
const muiTheme = (0, styles_1.createTheme)((0, lodash_es_1.merge)({}, themeOptions, options));
|
|
23
23
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
24
24
|
return (0, lodash_es_1.merge)(muiTheme, { elevation: elevation_1.elevation, shape: shape_1.shape });
|
|
25
25
|
};
|