@lunit/oui 1.0.1-alpha.9 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.git-ftp-include +1 -0
- package/package.json +11 -7
- package/src/assets/ic-bell-noti-outlined-20px.tsx +21 -0
- package/src/assets/ic-close-large-outlined-20px.tsx +17 -0
- package/src/assets/ic-close-small-outlined-20px.tsx +17 -0
- package/src/assets/ic-download-pdf-outlined-20px.tsx +18 -0
- package/src/assets/ic-ellipse-outlined-20px.tsx +17 -0
- package/src/assets/ic-filter-noti-outlined-20px.tsx +21 -0
- package/src/assets/ic-hide-large-outlined-20px.tsx +13 -0
- package/src/assets/ic-hide-small-outlined-20px.tsx +17 -0
- package/src/assets/ic-information-large-outlined-20px.tsx +17 -0
- package/src/assets/ic-information-small-outlined-20px.tsx +17 -0
- package/src/assets/ic-manufacturer-outlined-20px.tsx +19 -0
- package/src/assets/ic-rectangle-outlined-20px.tsx +17 -0
- package/src/assets/ic-refresh-left-outlined-20px.tsx +17 -0
- package/src/assets/ic-refresh-right-outlined-20px.tsx +13 -0
- package/src/assets/ic-show-large-outlined-20px.tsx +17 -0
- package/src/assets/ic-show-small-outlined-20px.tsx +17 -0
- package/src/assets/ic_bell_noti=outlined_20px.svg +5 -0
- package/src/assets/ic_close_large=outlined_20px.svg +4 -0
- package/src/assets/ic_close_small=outlined_20px.svg +4 -0
- package/src/assets/ic_download_pdf=outlined_20px.svg +7 -0
- package/src/assets/ic_ellipse=outlined_20px.svg +4 -0
- package/src/assets/ic_filter_noti=outlined_20px.svg +5 -0
- package/src/assets/ic_hide_large=outlined_20px.svg +4 -0
- package/src/assets/ic_hide_small=outlined_20px.svg +4 -0
- package/src/assets/ic_information_large=outlined_20px.svg +4 -0
- package/src/assets/ic_information_small=outlined_20px.svg +4 -0
- package/src/assets/ic_manufacturer=outlined_20px.svg +3 -0
- package/src/assets/ic_rectangle=outlined_20px.svg +4 -0
- package/src/assets/ic_refresh_left=outlined_20px.svg +4 -0
- package/src/assets/ic_refresh_right=outlined_20px.svg +4 -0
- package/src/assets/ic_show_large=outlined_20px.svg +4 -0
- package/src/assets/ic_show_small=outlined_20px.svg +4 -0
- package/src/assets/index.ts +16 -0
- package/src/components/Alert/Alert.styled.ts +44 -0
- package/src/components/Alert/Alert.tsx +39 -0
- package/src/components/Alert/Alert.types.ts +5 -0
- package/src/components/Alert/Alert.utils.tsx +43 -0
- package/src/components/Alert/index.ts +5 -0
- package/src/components/BaseTextField/BaseTextField.styled.ts +110 -0
- package/src/components/BaseTextField/BaseTextField.types.ts +25 -0
- package/src/components/BaseTextField/BaseTextField.utils.ts +10 -0
- package/src/components/Button/BaseButton.tsx +19 -0
- package/src/components/Button/Button.tsx +117 -0
- package/src/components/Button/Button.types.ts +36 -0
- package/src/components/Button/Button.utils.ts +13 -0
- package/src/components/Button/index.ts +6 -0
- package/src/components/Button/styleds/BaseButton.styled.ts +57 -0
- package/src/components/Button/styleds/ContainedButton.styled.ts +123 -0
- package/src/components/Button/styleds/GhostButton.styled.ts +139 -0
- package/src/components/Button/styleds/IconButton.styled.ts +25 -0
- package/src/components/Button/styleds/OutlinedButton.styled.ts +144 -0
- package/src/components/Card/Card.styled.tsx +18 -0
- package/src/components/Card/Card.tsx +18 -0
- package/src/components/Card/Card.types.ts +10 -0
- package/src/components/Card/index.ts +5 -0
- package/src/components/Checkbox/Checkbox.styled.tsx +27 -0
- package/src/components/Checkbox/Checkbox.tsx +64 -0
- package/src/components/Checkbox/Checkbox.types.ts +16 -0
- package/src/components/Checkbox/Checkbox.utils.tsx +42 -0
- package/src/components/Checkbox/index.ts +5 -0
- package/src/components/Chip/Chip.styled.ts +120 -0
- package/src/components/Chip/Chip.tsx +33 -0
- package/src/components/Chip/Chip.types.ts +18 -0
- package/src/components/Chip/Chip.utils.tsx +50 -0
- package/src/components/Chip/index.ts +4 -0
- package/src/components/DataTable/DataTable.styled.ts +66 -0
- package/src/components/DataTable/DataTable.tsx +29 -0
- package/src/components/DataTable/index.ts +1 -0
- package/src/components/DatePicker/DatePicker.styled.ts +19 -0
- package/src/components/DatePicker/DatePicker.tsx +194 -0
- package/src/components/DatePicker/DatePicker.types.ts +8 -0
- package/src/components/DatePicker/index.ts +4 -0
- package/src/components/Dialog/Dialog.styled.ts +87 -0
- package/src/components/Dialog/Dialog.tsx +111 -0
- package/src/components/Dialog/Dialog.types.ts +19 -0
- package/src/components/Dialog/index.ts +5 -0
- package/src/components/Divider/Divider.styled.ts +24 -0
- package/src/components/Divider/Divider.tsx +13 -0
- package/src/components/Divider/Divider.types.ts +7 -0
- package/src/components/Divider/index.ts +5 -0
- package/src/components/Dropdown/Dropdown.styled.tsx +127 -0
- package/src/components/Dropdown/Dropdown.tsx +116 -0
- package/src/components/Dropdown/Dropdown.types.ts +31 -0
- package/src/components/Dropdown/Dropdown.utils.ts +13 -0
- package/src/components/Dropdown/DropdownItem.styled.tsx +66 -0
- package/src/components/Dropdown/DropdownItem.tsx +45 -0
- package/src/components/Dropdown/DropdownItem.types.ts +14 -0
- package/src/components/Dropdown/DropdownItem.utils.ts +14 -0
- package/src/components/Dropdown/DropdownSubtitle.styled.ts +13 -0
- package/src/components/Dropdown/DropdownSubtitle.tsx +9 -0
- package/src/components/Dropdown/DropdownSubtitle.types.ts +6 -0
- package/src/components/Dropdown/IconDropdown.styled.tsx +82 -0
- package/src/components/Dropdown/IconDropdown.tsx +56 -0
- package/src/components/Dropdown/IconDropdown.types.ts +22 -0
- package/src/components/Dropdown/index.ts +22 -0
- package/src/components/FileDnDZone/FileDnDZone.styled.ts +43 -0
- package/src/components/FileDnDZone/FileDnDZone.tsx +81 -0
- package/src/components/FileDnDZone/FileDnDZone.types.ts +14 -0
- package/src/components/FileDnDZone/FileDnDZone.utils.ts +3 -0
- package/src/components/FileDnDZone/index.ts +5 -0
- package/src/components/List/List.styled.ts +31 -0
- package/src/components/List/List.tsx +71 -0
- package/src/components/List/List.types.ts +24 -0
- package/src/components/List/List.utils.ts +14 -0
- package/src/components/List/ListItem.styled.tsx +61 -0
- package/src/components/List/ListItem.tsx +66 -0
- package/src/components/List/ListItem.types.ts +40 -0
- package/src/components/List/ListItemCaption.styled.tsx +7 -0
- package/src/components/List/ListItemCaption.tsx +18 -0
- package/src/components/List/ListItemCaption.types.ts +2 -0
- package/src/components/List/index.ts +8 -0
- package/src/components/LoadingIndicator/LoadingIndicator.styled.tsx +40 -0
- package/src/components/LoadingIndicator/LoadingIndicator.tsx +44 -0
- package/src/components/LoadingIndicator/LoadingIndicator.types.ts +7 -0
- package/src/components/LoadingIndicator/assets/DnaLoadingAnimation.json +769 -0
- package/src/components/LoadingIndicator/assets/DotLoadingAnimation.json +426 -0
- package/src/components/LoadingIndicator/index.ts +5 -0
- package/src/components/Menu/Menu.styled.tsx +42 -0
- package/src/components/Menu/Menu.tsx +28 -0
- package/src/components/Menu/Menu.types.ts +18 -0
- package/src/components/Menu/MenuItem.styled.ts +62 -0
- package/src/components/Menu/MenuItem.tsx +45 -0
- package/src/components/Menu/MenuItem.types.ts +14 -0
- package/src/components/Menu/index.ts +5 -0
- package/src/components/MuiCssBaseline.ts +78 -0
- package/src/components/MuiInputBase.ts +25 -0
- package/src/components/MuiOutlinedInput.ts +57 -0
- package/src/components/MuiTextField.ts +17 -0
- package/src/components/Pagination/Pagination.styled.tsx +71 -0
- package/src/components/Pagination/Pagination.tsx +182 -0
- package/src/components/Pagination/Pagination.types.ts +39 -0
- package/src/components/Pagination/index.ts +2 -0
- package/src/components/ProductLabel/ProductLabel.styled.ts +61 -0
- package/src/components/ProductLabel/ProductLabel.tsx +57 -0
- package/src/components/ProductLabel/ProductLabel.types.ts +10 -0
- package/src/components/ProductLabel/index.ts +5 -0
- package/src/components/Progress/CircularProgress.styled.ts +10 -0
- package/src/components/Progress/CircularProgress.tsx +15 -0
- package/src/components/Progress/CircularProgress.types.ts +6 -0
- package/src/components/Progress/LinearProgress.styled.ts +15 -0
- package/src/components/Progress/LinearProgress.tsx +16 -0
- package/src/components/Progress/LinearProgress.types.ts +7 -0
- package/src/components/Progress/index.ts +4 -0
- package/src/components/Radio/Radio.styled.ts +35 -0
- package/src/components/Radio/Radio.tsx +60 -0
- package/src/components/Radio/Radio.types.ts +15 -0
- package/src/components/Radio/RadioGroup.styled.ts +6 -0
- package/src/components/Radio/RadioGroup.tsx +23 -0
- package/src/components/Radio/RadioGroup.types.ts +10 -0
- package/src/components/Radio/index.ts +7 -0
- package/src/components/Stepper/Stepper.styled.ts +38 -0
- package/src/components/Stepper/Stepper.tsx +24 -0
- package/src/components/Stepper/Stepper.types.ts +13 -0
- package/src/components/Stepper/index.ts +5 -0
- package/src/components/TabbedPanel/TabbedPanel.styled.ts +129 -0
- package/src/components/TabbedPanel/TabbedPanel.tsx +70 -0
- package/src/components/TabbedPanel/TabbedPanel.types.ts +36 -0
- package/src/components/TabbedPanel/TabbedPanel.utils.ts +21 -0
- package/src/components/TabbedPanel/index.ts +5 -0
- package/src/components/TextField/TextArea.styled.tsx +36 -0
- package/src/components/TextField/TextArea.tsx +35 -0
- package/src/components/TextField/TextArea.types.ts +28 -0
- package/src/components/TextField/TextInput.styled.tsx +115 -0
- package/src/components/TextField/TextInput.tsx +27 -0
- package/src/components/TextField/TextInput.types.ts +46 -0
- package/src/components/TextField/TextInput.utils.ts +7 -0
- package/src/components/TextField/components/Buttons.tsx +26 -0
- package/src/components/TextField/components/NormalTextInput.tsx +95 -0
- package/src/components/TextField/components/PasswordInput.tsx +92 -0
- package/src/components/TextField/index.ts +7 -0
- package/src/components/Tooltip/Tooltip.styled.tsx +36 -0
- package/src/components/Tooltip/Tooltip.tsx +58 -0
- package/src/components/Tooltip/Tooltip.types.ts +24 -0
- package/src/components/Tooltip/Tooltip.utils.ts +46 -0
- package/src/components/Tooltip/index.ts +5 -0
- package/src/components/UploadManager/UploadManager.styled.ts +49 -0
- package/src/components/UploadManager/UploadManager.tsx +271 -0
- package/src/components/UploadManager/UploadManager.types.ts +16 -0
- package/src/components/UploadManager/index.ts +5 -0
- package/src/components/index.ts +23 -0
- package/src/foundations/index.ts +4 -0
- package/src/foundations/palette.ts +418 -0
- package/src/foundations/spacing.ts +5 -0
- package/src/foundations/styles.ts +9 -0
- package/src/foundations/typography.ts +492 -0
- package/src/icons/BellNoti/index.tsx +28 -0
- package/src/icons/CloseLarge/index.tsx +28 -0
- package/src/icons/CloseSmall/index.tsx +28 -0
- package/src/icons/DownloadPdf/index.tsx +28 -0
- package/src/icons/Ellipse/index.tsx +28 -0
- package/src/icons/FilterNoti/index.tsx +28 -0
- package/src/icons/HideLarge/index.tsx +28 -0
- package/src/icons/HideSmall/index.tsx +28 -0
- package/src/icons/InformationLarge/index.tsx +28 -0
- package/src/icons/InformationSmall/index.tsx +28 -0
- package/src/icons/Manufacturer/index.tsx +28 -0
- package/src/icons/Rectangle/index.tsx +28 -0
- package/src/icons/RefreshLeft/index.tsx +28 -0
- package/src/icons/RefreshRight/index.tsx +28 -0
- package/src/icons/ShowLarge/index.tsx +28 -0
- package/src/icons/ShowSmall/index.tsx +28 -0
- package/src/icons/index.ts +180 -0
- package/src/index.ts +4 -0
- package/src/react-app-env.d.ts +71 -0
- package/src/reportWebVitals.ts +15 -0
- package/src/setupTests.ts +5 -0
- package/src/systems/drawer.ts +27 -0
- package/src/systems/index.ts +7 -0
- package/src/theme.ts +22 -0
- package/dist/assets/ic-bell-noti-outlined-20px.js.map +0 -1
- package/dist/assets/ic-close-large-outlined-20px.js.map +0 -1
- package/dist/assets/ic-close-small-outlined-20px.js.map +0 -1
- package/dist/assets/ic-download-pdf-outlined-20px.js.map +0 -1
- package/dist/assets/ic-ellipse-outlined-20px.js.map +0 -1
- package/dist/assets/ic-filter-noti-outlined-20px.js.map +0 -1
- package/dist/assets/ic-hide-large-outlined-20px.js.map +0 -1
- package/dist/assets/ic-hide-small-outlined-20px.js.map +0 -1
- package/dist/assets/ic-information-large-outlined-20px.js.map +0 -1
- package/dist/assets/ic-information-small-outlined-20px.js.map +0 -1
- package/dist/assets/ic-manufacturer-outlined-20px.js.map +0 -1
- package/dist/assets/ic-rectangle-outlined-20px.js.map +0 -1
- package/dist/assets/ic-refresh-left-outlined-20px.js.map +0 -1
- package/dist/assets/ic-refresh-right-outlined-20px.js.map +0 -1
- package/dist/assets/ic-show-large-outlined-20px.js.map +0 -1
- package/dist/assets/ic-show-small-outlined-20px.js.map +0 -1
- package/dist/assets/index.js.map +0 -1
- package/dist/components/Alert/Alert.js.map +0 -1
- package/dist/components/Alert/Alert.styled.js.map +0 -1
- package/dist/components/Alert/Alert.types.js.map +0 -1
- package/dist/components/Alert/Alert.utils.js.map +0 -1
- package/dist/components/Alert/index.js.map +0 -1
- package/dist/components/BaseTextField/BaseTextField.styled.js.map +0 -1
- package/dist/components/BaseTextField/BaseTextField.types.js.map +0 -1
- package/dist/components/BaseTextField/BaseTextField.utils.js.map +0 -1
- package/dist/components/Button/BaseButton.js.map +0 -1
- package/dist/components/Button/Button.js.map +0 -1
- package/dist/components/Button/Button.types.js.map +0 -1
- package/dist/components/Button/Button.utils.js.map +0 -1
- package/dist/components/Button/index.js.map +0 -1
- package/dist/components/Button/styleds/BaseButton.styled.js.map +0 -1
- package/dist/components/Button/styleds/ContainedButton.styled.js.map +0 -1
- package/dist/components/Button/styleds/GhostButton.styled.js.map +0 -1
- package/dist/components/Button/styleds/IconButton.styled.js.map +0 -1
- package/dist/components/Button/styleds/OutlinedButton.styled.js.map +0 -1
- package/dist/components/Card/Card.js.map +0 -1
- package/dist/components/Card/Card.styled.js.map +0 -1
- package/dist/components/Card/Card.types.js.map +0 -1
- package/dist/components/Card/index.js.map +0 -1
- package/dist/components/Checkbox/Checkbox.js.map +0 -1
- package/dist/components/Checkbox/Checkbox.styled.js.map +0 -1
- package/dist/components/Checkbox/Checkbox.types.js.map +0 -1
- package/dist/components/Checkbox/Checkbox.utils.js.map +0 -1
- package/dist/components/Checkbox/index.js.map +0 -1
- package/dist/components/Chip/Chip.js.map +0 -1
- package/dist/components/Chip/Chip.styled.js.map +0 -1
- package/dist/components/Chip/Chip.types.js.map +0 -1
- package/dist/components/Chip/Chip.utils.js.map +0 -1
- package/dist/components/Chip/index.js.map +0 -1
- package/dist/components/DataTable/DataTable.js.map +0 -1
- package/dist/components/DataTable/DataTable.styled.js.map +0 -1
- package/dist/components/DataTable/index.js.map +0 -1
- package/dist/components/DatePicker/DatePicker.js.map +0 -1
- package/dist/components/DatePicker/DatePicker.styled.js.map +0 -1
- package/dist/components/DatePicker/DatePicker.types.js.map +0 -1
- package/dist/components/DatePicker/index.js.map +0 -1
- package/dist/components/Dialog/Dialog.js.map +0 -1
- package/dist/components/Dialog/Dialog.styled.js.map +0 -1
- package/dist/components/Dialog/Dialog.types.js.map +0 -1
- package/dist/components/Dialog/index.js.map +0 -1
- package/dist/components/Divider/Divider.js.map +0 -1
- package/dist/components/Divider/Divider.styled.js.map +0 -1
- package/dist/components/Divider/Divider.types.js.map +0 -1
- package/dist/components/Divider/index.js.map +0 -1
- package/dist/components/Dropdown/Dropdown.js.map +0 -1
- package/dist/components/Dropdown/Dropdown.styled.js.map +0 -1
- package/dist/components/Dropdown/Dropdown.types.js.map +0 -1
- package/dist/components/Dropdown/Dropdown.utils.js.map +0 -1
- package/dist/components/Dropdown/DropdownItem.js.map +0 -1
- package/dist/components/Dropdown/DropdownItem.styled.js.map +0 -1
- package/dist/components/Dropdown/DropdownItem.types.js.map +0 -1
- package/dist/components/Dropdown/DropdownItem.utils.js.map +0 -1
- package/dist/components/Dropdown/DropdownSubtitle.js.map +0 -1
- package/dist/components/Dropdown/DropdownSubtitle.styled.js.map +0 -1
- package/dist/components/Dropdown/DropdownSubtitle.types.js.map +0 -1
- package/dist/components/Dropdown/IconDropdown.js.map +0 -1
- package/dist/components/Dropdown/IconDropdown.styled.js.map +0 -1
- package/dist/components/Dropdown/IconDropdown.types.js.map +0 -1
- package/dist/components/Dropdown/index.js.map +0 -1
- package/dist/components/FileDnDZone/FileDnDZone.js.map +0 -1
- package/dist/components/FileDnDZone/FileDnDZone.styled.js.map +0 -1
- package/dist/components/FileDnDZone/FileDnDZone.types.js.map +0 -1
- package/dist/components/FileDnDZone/FileDnDZone.utils.js.map +0 -1
- package/dist/components/FileDnDZone/index.js.map +0 -1
- package/dist/components/List/List.js.map +0 -1
- package/dist/components/List/List.styled.js.map +0 -1
- package/dist/components/List/List.types.js.map +0 -1
- package/dist/components/List/List.utils.js.map +0 -1
- package/dist/components/List/ListItem.js.map +0 -1
- package/dist/components/List/ListItem.styled.js.map +0 -1
- package/dist/components/List/ListItem.types.js.map +0 -1
- package/dist/components/List/ListItemCaption.js.map +0 -1
- package/dist/components/List/ListItemCaption.styled.js.map +0 -1
- package/dist/components/List/ListItemCaption.types.js.map +0 -1
- package/dist/components/List/index.js.map +0 -1
- package/dist/components/LoadingIndicator/LoadingIndicator.js.map +0 -1
- package/dist/components/LoadingIndicator/LoadingIndicator.styled.js.map +0 -1
- package/dist/components/LoadingIndicator/LoadingIndicator.types.js.map +0 -1
- package/dist/components/LoadingIndicator/index.js.map +0 -1
- package/dist/components/Menu/Menu.js.map +0 -1
- package/dist/components/Menu/Menu.styled.js.map +0 -1
- package/dist/components/Menu/Menu.types.js.map +0 -1
- package/dist/components/Menu/MenuItem.js.map +0 -1
- package/dist/components/Menu/MenuItem.styled.js.map +0 -1
- package/dist/components/Menu/MenuItem.types.js.map +0 -1
- package/dist/components/Menu/index.js.map +0 -1
- package/dist/components/MuiCssBaseline.js.map +0 -1
- package/dist/components/MuiInputBase.js.map +0 -1
- package/dist/components/MuiOutlinedInput.js.map +0 -1
- package/dist/components/MuiTextField.js.map +0 -1
- package/dist/components/Pagination/Pagination.js.map +0 -1
- package/dist/components/Pagination/Pagination.styled.js.map +0 -1
- package/dist/components/Pagination/Pagination.types.js.map +0 -1
- package/dist/components/Pagination/index.js.map +0 -1
- package/dist/components/ProductLabel/ProductLabel.js.map +0 -1
- package/dist/components/ProductLabel/ProductLabel.styled.js.map +0 -1
- package/dist/components/ProductLabel/ProductLabel.types.js.map +0 -1
- package/dist/components/ProductLabel/index.js.map +0 -1
- package/dist/components/Progress/CircularProgress.js.map +0 -1
- package/dist/components/Progress/CircularProgress.styled.js.map +0 -1
- package/dist/components/Progress/CircularProgress.types.js.map +0 -1
- package/dist/components/Progress/LinearProgress.js.map +0 -1
- package/dist/components/Progress/LinearProgress.styled.js.map +0 -1
- package/dist/components/Progress/LinearProgress.types.js.map +0 -1
- package/dist/components/Progress/index.js.map +0 -1
- package/dist/components/Radio/Radio.js.map +0 -1
- package/dist/components/Radio/Radio.styled.js.map +0 -1
- package/dist/components/Radio/Radio.types.js.map +0 -1
- package/dist/components/Radio/RadioGroup.js.map +0 -1
- package/dist/components/Radio/RadioGroup.styled.js.map +0 -1
- package/dist/components/Radio/RadioGroup.types.js.map +0 -1
- package/dist/components/Radio/index.js.map +0 -1
- package/dist/components/Stepper/Stepper.js.map +0 -1
- package/dist/components/Stepper/Stepper.styled.js.map +0 -1
- package/dist/components/Stepper/Stepper.types.js.map +0 -1
- package/dist/components/Stepper/index.js.map +0 -1
- package/dist/components/TabbedPanel/TabbedPanel.js.map +0 -1
- package/dist/components/TabbedPanel/TabbedPanel.styled.js.map +0 -1
- package/dist/components/TabbedPanel/TabbedPanel.types.js.map +0 -1
- package/dist/components/TabbedPanel/TabbedPanel.utils.js.map +0 -1
- package/dist/components/TabbedPanel/index.js.map +0 -1
- package/dist/components/TextField/TextArea.js.map +0 -1
- package/dist/components/TextField/TextArea.styled.js.map +0 -1
- package/dist/components/TextField/TextArea.types.js.map +0 -1
- package/dist/components/TextField/TextInput.js.map +0 -1
- package/dist/components/TextField/TextInput.styled.js.map +0 -1
- package/dist/components/TextField/TextInput.types.js.map +0 -1
- package/dist/components/TextField/TextInput.utils.js.map +0 -1
- package/dist/components/TextField/components/Buttons.js.map +0 -1
- package/dist/components/TextField/components/NormalTextInput.js.map +0 -1
- package/dist/components/TextField/components/PasswordInput.js.map +0 -1
- package/dist/components/TextField/index.js.map +0 -1
- package/dist/components/Tooltip/Tooltip.js.map +0 -1
- package/dist/components/Tooltip/Tooltip.styled.js.map +0 -1
- package/dist/components/Tooltip/Tooltip.types.js.map +0 -1
- package/dist/components/Tooltip/Tooltip.utils.js.map +0 -1
- package/dist/components/Tooltip/index.js.map +0 -1
- package/dist/components/UploadManager/UploadManager.js.map +0 -1
- package/dist/components/UploadManager/UploadManager.styled.js.map +0 -1
- package/dist/components/UploadManager/UploadManager.types.js.map +0 -1
- package/dist/components/UploadManager/index.js.map +0 -1
- package/dist/components/index.js.map +0 -1
- package/dist/foundations/index.js.map +0 -1
- package/dist/foundations/palette.js.map +0 -1
- package/dist/foundations/spacing.js.map +0 -1
- package/dist/foundations/styles.js.map +0 -1
- package/dist/foundations/typography.js.map +0 -1
- package/dist/icons/BellNoti/index.js.map +0 -1
- package/dist/icons/CloseLarge/index.js.map +0 -1
- package/dist/icons/CloseSmall/index.js.map +0 -1
- package/dist/icons/DownloadPdf/index.js.map +0 -1
- package/dist/icons/Ellipse/index.js.map +0 -1
- package/dist/icons/FilterNoti/index.js.map +0 -1
- package/dist/icons/HideLarge/index.js.map +0 -1
- package/dist/icons/HideSmall/index.js.map +0 -1
- package/dist/icons/InformationLarge/index.js.map +0 -1
- package/dist/icons/InformationSmall/index.js.map +0 -1
- package/dist/icons/Manufacturer/index.js.map +0 -1
- package/dist/icons/Rectangle/index.js.map +0 -1
- package/dist/icons/RefreshLeft/index.js.map +0 -1
- package/dist/icons/RefreshRight/index.js.map +0 -1
- package/dist/icons/ShowLarge/index.js.map +0 -1
- package/dist/icons/ShowSmall/index.js.map +0 -1
- package/dist/icons/index.js.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/reportWebVitals.js.map +0 -1
- package/dist/setupTests.js.map +0 -1
- package/dist/systems/drawer.js.map +0 -1
- package/dist/systems/index.js.map +0 -1
- package/dist/theme.js.map +0 -1
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
import { ButtonBase, styled } from '@mui/material';
|
|
2
|
+
import type { Theme } from '@mui/material';
|
|
3
|
+
import { baseButtonStyle, baseLargeStyle, baseSmallStyle } from './BaseButton.styled';
|
|
4
|
+
import { baseLargeIconStyle, baseMediumIconStyle, baseSmallIconStyle } from './IconButton.styled';
|
|
5
|
+
import type { BaseButtonProps } from '../Button.types';
|
|
6
|
+
|
|
7
|
+
const outlinedPrimaryStyle = (theme: Theme, focusOutline: boolean | undefined) => {
|
|
8
|
+
const mainColor = theme.palette.lunitTeal[40];
|
|
9
|
+
return {
|
|
10
|
+
...baseButtonStyle(theme, false),
|
|
11
|
+
backgroundColor: 'transparent',
|
|
12
|
+
color: mainColor,
|
|
13
|
+
border: `1px solid ${mainColor}`,
|
|
14
|
+
'&:hover': {
|
|
15
|
+
backgroundColor: theme.palette.neutralGrey[70],
|
|
16
|
+
opacity: 0.8,
|
|
17
|
+
},
|
|
18
|
+
'&:disabled': {
|
|
19
|
+
color: mainColor,
|
|
20
|
+
backgroundColor: 'transparent',
|
|
21
|
+
opacity: 0.4,
|
|
22
|
+
},
|
|
23
|
+
'&:focus': {
|
|
24
|
+
border: `1px solid ${mainColor}`,
|
|
25
|
+
outline: focusOutline ? `2px solid ${mainColor}` : 'none',
|
|
26
|
+
},
|
|
27
|
+
'&:focus-visible': {
|
|
28
|
+
border: `1px solid ${mainColor}`,
|
|
29
|
+
outline: focusOutline ? `2px solid ${mainColor}` : 'none',
|
|
30
|
+
},
|
|
31
|
+
};
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
const outlinedSecondaryStyle = (theme: Theme, focusOutline: boolean | undefined) => {
|
|
35
|
+
const mainColor = theme.palette.neutralGrey[25];
|
|
36
|
+
return {
|
|
37
|
+
backgroundColor: 'transparent',
|
|
38
|
+
color: mainColor,
|
|
39
|
+
border: `1px solid ${mainColor}`,
|
|
40
|
+
'&:hover': {
|
|
41
|
+
backgroundColor: theme.palette.neutralGrey[70],
|
|
42
|
+
opacity: 0.8,
|
|
43
|
+
},
|
|
44
|
+
'&:disabled': {
|
|
45
|
+
backgroundColor: 'transparent',
|
|
46
|
+
color: mainColor,
|
|
47
|
+
opacity: 0.4,
|
|
48
|
+
},
|
|
49
|
+
'&:focus': {
|
|
50
|
+
border: `1px solid ${mainColor}`,
|
|
51
|
+
outline: focusOutline ? `2px solid ${mainColor}` : 'none',
|
|
52
|
+
},
|
|
53
|
+
'&:focus-visible': {
|
|
54
|
+
border: `1px solid ${mainColor}`,
|
|
55
|
+
outline: focusOutline ? `2px solid ${mainColor}` : 'none',
|
|
56
|
+
},
|
|
57
|
+
};
|
|
58
|
+
};
|
|
59
|
+
const outlinedErrorStyle = (theme: Theme, focusOutline: boolean | undefined) => {
|
|
60
|
+
const mainColor = theme.palette.red[5];
|
|
61
|
+
return {
|
|
62
|
+
backgroundColor: 'transparent',
|
|
63
|
+
color: mainColor,
|
|
64
|
+
border: `1px solid ${mainColor}`,
|
|
65
|
+
'&:hover': {
|
|
66
|
+
backgroundColor: theme.palette.neutralGrey[70],
|
|
67
|
+
opacity: 0.8,
|
|
68
|
+
},
|
|
69
|
+
'&:disabled': {
|
|
70
|
+
backgroundColor: 'transparent',
|
|
71
|
+
color: mainColor,
|
|
72
|
+
opacity: 0.4,
|
|
73
|
+
},
|
|
74
|
+
'&:focus': {
|
|
75
|
+
border: `1px solid ${mainColor}`,
|
|
76
|
+
outline: focusOutline ? `2px solid ${mainColor}` : 'none',
|
|
77
|
+
},
|
|
78
|
+
'&:focus-visible': {
|
|
79
|
+
border: `1px solid ${mainColor}`,
|
|
80
|
+
outline: focusOutline ? `2px solid ${mainColor}` : 'none',
|
|
81
|
+
},
|
|
82
|
+
};
|
|
83
|
+
};
|
|
84
|
+
|
|
85
|
+
const BaseOutlinedButton = styled(ButtonBase, {
|
|
86
|
+
shouldForwardProp: (prop) =>
|
|
87
|
+
!['color', 'variant', 'size', 'focusOutline', 'isIconOnly'].includes(prop.toString()),
|
|
88
|
+
})<BaseButtonProps>(({ theme, color, size, focusOutline, isIconOnly }) => {
|
|
89
|
+
let resultStyle = outlinedPrimaryStyle(theme, focusOutline);
|
|
90
|
+
|
|
91
|
+
// Apply icon sizing if icon only
|
|
92
|
+
if (isIconOnly) {
|
|
93
|
+
if (size === 'small') {
|
|
94
|
+
resultStyle = {
|
|
95
|
+
...resultStyle,
|
|
96
|
+
...baseSmallIconStyle,
|
|
97
|
+
};
|
|
98
|
+
} else if (size === 'large') {
|
|
99
|
+
resultStyle = {
|
|
100
|
+
...resultStyle,
|
|
101
|
+
...baseLargeIconStyle,
|
|
102
|
+
};
|
|
103
|
+
} else {
|
|
104
|
+
resultStyle = {
|
|
105
|
+
...resultStyle,
|
|
106
|
+
...baseMediumIconStyle,
|
|
107
|
+
};
|
|
108
|
+
}
|
|
109
|
+
} else {
|
|
110
|
+
// Apply label or icon-label
|
|
111
|
+
if (size === 'small') {
|
|
112
|
+
resultStyle = {
|
|
113
|
+
...resultStyle,
|
|
114
|
+
...baseSmallStyle,
|
|
115
|
+
};
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
if (size === 'large') {
|
|
119
|
+
resultStyle = {
|
|
120
|
+
...resultStyle,
|
|
121
|
+
...baseLargeStyle,
|
|
122
|
+
};
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
// Apply color
|
|
127
|
+
if (color === 'error') {
|
|
128
|
+
resultStyle = {
|
|
129
|
+
...resultStyle,
|
|
130
|
+
...outlinedErrorStyle(theme, focusOutline),
|
|
131
|
+
};
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
if (color === 'secondary') {
|
|
135
|
+
resultStyle = {
|
|
136
|
+
...resultStyle,
|
|
137
|
+
...outlinedSecondaryStyle(theme, focusOutline),
|
|
138
|
+
};
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
return resultStyle;
|
|
142
|
+
});
|
|
143
|
+
|
|
144
|
+
export { outlinedPrimaryStyle, outlinedSecondaryStyle, outlinedErrorStyle, BaseOutlinedButton };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Card as MuiCard, styled } from '@mui/material';
|
|
3
|
+
import type { CardProps } from './Card.types';
|
|
4
|
+
|
|
5
|
+
const BaseCard = styled(({ ...props }: CardProps) => <MuiCard {...props} />)(
|
|
6
|
+
({ theme, size = 'large', selected }) => ({
|
|
7
|
+
width: size === 'small' ? '480px' : '520px',
|
|
8
|
+
height: size === 'small' ? '156px' : '284px',
|
|
9
|
+
cursor: 'pointer',
|
|
10
|
+
borderRadius: '8px',
|
|
11
|
+
backgroundColor: !selected ? theme.palette.neutralGrey[85] : theme.palette.neutralGrey[75],
|
|
12
|
+
'&:hover': {
|
|
13
|
+
backgroundColor: theme.palette.neutralGrey[75],
|
|
14
|
+
},
|
|
15
|
+
}),
|
|
16
|
+
);
|
|
17
|
+
|
|
18
|
+
export default BaseCard;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import BaseCard from './Card.styled';
|
|
3
|
+
import type { CardProps } from './Card.types';
|
|
4
|
+
|
|
5
|
+
function Card({ size, selected, onClick, children, ...props }: CardProps) {
|
|
6
|
+
return (
|
|
7
|
+
<BaseCard
|
|
8
|
+
size={size}
|
|
9
|
+
selected={selected}
|
|
10
|
+
onClick={onClick}
|
|
11
|
+
{...props}
|
|
12
|
+
>
|
|
13
|
+
{children}
|
|
14
|
+
</BaseCard>
|
|
15
|
+
);
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export default Card;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { styled, Box, Checkbox } from '@mui/material';
|
|
2
|
+
|
|
3
|
+
export const Container = styled(Box, {
|
|
4
|
+
shouldForwardProp: (prop) => prop !== 'touchRippleRef',
|
|
5
|
+
})(({ theme }) => ({
|
|
6
|
+
display: 'inline-flex',
|
|
7
|
+
gap: theme.spacing(2),
|
|
8
|
+
}));
|
|
9
|
+
|
|
10
|
+
export const StyledCheckbox = styled(Checkbox)(({ theme }) => ({
|
|
11
|
+
width: '22px',
|
|
12
|
+
height: '22px',
|
|
13
|
+
padding: 0,
|
|
14
|
+
'&.Mui-disabled, &.Mui-disabled + .MuiTypography-root': {
|
|
15
|
+
opacity: 0.4,
|
|
16
|
+
},
|
|
17
|
+
'&.Mui-focusVisible > .checkbox-icon': {
|
|
18
|
+
borderRadius: '4px',
|
|
19
|
+
boxShadow: `0 0 0 1px ${theme.palette.lunitTeal[10]}`,
|
|
20
|
+
},
|
|
21
|
+
}));
|
|
22
|
+
|
|
23
|
+
export const iconStyle = {
|
|
24
|
+
display: 'inline-block',
|
|
25
|
+
width: '18px',
|
|
26
|
+
height: '18px',
|
|
27
|
+
};
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import React, { forwardRef } from 'react';
|
|
2
|
+
import { Typography } from '@mui/material';
|
|
3
|
+
import clsx from 'clsx';
|
|
4
|
+
import { Container, StyledCheckbox } from './Checkbox.styled';
|
|
5
|
+
import type { CheckboxProps } from './Checkbox.types';
|
|
6
|
+
import { UncheckedIcon, CheckedIcon, IndeterminateIcon } from './Checkbox.utils';
|
|
7
|
+
|
|
8
|
+
const Checkbox = forwardRef<HTMLSpanElement, CheckboxProps>(
|
|
9
|
+
(
|
|
10
|
+
{
|
|
11
|
+
value,
|
|
12
|
+
name,
|
|
13
|
+
checked,
|
|
14
|
+
defaultChecked,
|
|
15
|
+
disabled,
|
|
16
|
+
required,
|
|
17
|
+
indeterminate,
|
|
18
|
+
onChange,
|
|
19
|
+
onChangeCapture,
|
|
20
|
+
label,
|
|
21
|
+
inputProps,
|
|
22
|
+
inputRef,
|
|
23
|
+
...rootProps
|
|
24
|
+
}: CheckboxProps,
|
|
25
|
+
ref,
|
|
26
|
+
) => {
|
|
27
|
+
return (
|
|
28
|
+
<Container
|
|
29
|
+
{...rootProps}
|
|
30
|
+
className={clsx('checkbox', rootProps.className)}
|
|
31
|
+
component={label != null ? 'label' : 'span'}
|
|
32
|
+
ref={ref}
|
|
33
|
+
>
|
|
34
|
+
<StyledCheckbox
|
|
35
|
+
disableRipple
|
|
36
|
+
icon={<UncheckedIcon />}
|
|
37
|
+
checkedIcon={<CheckedIcon />}
|
|
38
|
+
indeterminateIcon={<IndeterminateIcon />}
|
|
39
|
+
value={value}
|
|
40
|
+
name={name}
|
|
41
|
+
checked={indeterminate ? true : checked}
|
|
42
|
+
defaultChecked={defaultChecked}
|
|
43
|
+
disabled={disabled}
|
|
44
|
+
required={required}
|
|
45
|
+
indeterminate={indeterminate}
|
|
46
|
+
onChange={onChange}
|
|
47
|
+
onChangeCapture={onChangeCapture}
|
|
48
|
+
inputProps={inputProps}
|
|
49
|
+
inputRef={inputRef}
|
|
50
|
+
/>
|
|
51
|
+
{label && (
|
|
52
|
+
<Typography
|
|
53
|
+
variant="body5"
|
|
54
|
+
sx={{ display: 'flex', alignItems: 'center' }}
|
|
55
|
+
>
|
|
56
|
+
{label}
|
|
57
|
+
</Typography>
|
|
58
|
+
)}
|
|
59
|
+
</Container>
|
|
60
|
+
);
|
|
61
|
+
},
|
|
62
|
+
);
|
|
63
|
+
|
|
64
|
+
export default Checkbox;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { BoxProps, CheckboxProps as MuiCheckboxProps } from '@mui/material';
|
|
2
|
+
|
|
3
|
+
export interface CheckboxProps extends Omit<BoxProps<'span'>, 'onChange' | 'onChangeCapture'> {
|
|
4
|
+
value?: MuiCheckboxProps['value'];
|
|
5
|
+
name?: MuiCheckboxProps['name'];
|
|
6
|
+
checked?: MuiCheckboxProps['checked'];
|
|
7
|
+
defaultChecked?: MuiCheckboxProps['defaultChecked'];
|
|
8
|
+
disabled?: MuiCheckboxProps['disabled'];
|
|
9
|
+
required?: MuiCheckboxProps['required'];
|
|
10
|
+
indeterminate?: MuiCheckboxProps['indeterminate'];
|
|
11
|
+
onChange?: MuiCheckboxProps['onChange'];
|
|
12
|
+
onChangeCapture?: MuiCheckboxProps['onChangeCapture'];
|
|
13
|
+
label?: string;
|
|
14
|
+
inputProps?: MuiCheckboxProps['inputProps'];
|
|
15
|
+
inputRef?: MuiCheckboxProps['inputRef'];
|
|
16
|
+
}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Box } from '@mui/material';
|
|
3
|
+
import { iconStyle } from './Checkbox.styled';
|
|
4
|
+
|
|
5
|
+
export const UncheckedIcon = () => {
|
|
6
|
+
return (
|
|
7
|
+
<Box
|
|
8
|
+
component="span"
|
|
9
|
+
className="checkbox-icon"
|
|
10
|
+
sx={{
|
|
11
|
+
...iconStyle,
|
|
12
|
+
background: `url("data:image/svg+xml,%0A%3Csvg width='18' height='18' viewBox='0 0 18 18' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M14 1.5H4C2.61929 1.5 1.5 2.61929 1.5 4V14C1.5 15.3807 2.61929 16.5 4 16.5H14C15.3807 16.5 16.5 15.3807 16.5 14V4C16.5 2.61929 15.3807 1.5 14 1.5ZM4 0C1.79086 0 0 1.79086 0 4V14C0 16.2091 1.79086 18 4 18H14C16.2091 18 18 16.2091 18 14V4C18 1.79086 16.2091 0 14 0H4Z' fill='%2399999B'/%3E%3C/svg%3E%0A")`,
|
|
13
|
+
}}
|
|
14
|
+
/>
|
|
15
|
+
);
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
export const CheckedIcon = () => {
|
|
19
|
+
return (
|
|
20
|
+
<Box
|
|
21
|
+
component="span"
|
|
22
|
+
className="checkbox-icon"
|
|
23
|
+
sx={{
|
|
24
|
+
...iconStyle,
|
|
25
|
+
background: `url("data:image/svg+xml,%0A%3Csvg width='18' height='18' viewBox='0 0 18 18' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M4 0C1.79086 0 0 1.79086 0 4V14C0 16.2091 1.79086 18 4 18H14C16.2091 18 18 16.2091 18 14V4C18 1.79086 16.2091 0 14 0H4ZM14.2516 7.14413C14.6074 6.72168 14.5533 6.09083 14.1309 5.73508C13.7084 5.37933 13.0776 5.43341 12.7218 5.85586L8.31824 11.0851L5.14993 8.37556C4.7302 8.01661 4.09895 8.06588 3.74 8.48561C3.38105 8.90533 3.43032 9.53658 3.85005 9.89553L7.78416 13.26C7.98672 13.4332 8.25006 13.5184 8.51571 13.4967C8.78135 13.4749 9.02732 13.348 9.19901 13.1441L14.2516 7.14413Z' fill='%2300C9EA'/%3E%3C/svg%3E%0A")`,
|
|
26
|
+
}}
|
|
27
|
+
/>
|
|
28
|
+
);
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
export const IndeterminateIcon = () => {
|
|
32
|
+
return (
|
|
33
|
+
<Box
|
|
34
|
+
component="span"
|
|
35
|
+
className="checkbox-icon"
|
|
36
|
+
sx={{
|
|
37
|
+
...iconStyle,
|
|
38
|
+
background: `url("data:image/svg+xml,%0A%3Csvg width='18' height='18' viewBox='0 0 18 18' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Crect width='18' height='18' rx='4' fill='%2300C9EA'/%3E%3Cpath d='M3 9C3 8.44772 3.44772 8 4 8H14C14.5523 8 15 8.44772 15 9V9C15 9.55228 14.5523 10 14 10H4C3.44772 10 3 9.55228 3 9V9Z' fill='white'/%3E%3C/svg%3E%0A")`,
|
|
39
|
+
}}
|
|
40
|
+
/>
|
|
41
|
+
);
|
|
42
|
+
};
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
import { Chip as MUIChip } from '@mui/material';
|
|
2
|
+
import { styled } from '@mui/material/styles';
|
|
3
|
+
import tinycolor from 'tinycolor2';
|
|
4
|
+
import theme from '../../theme';
|
|
5
|
+
import { ChipProps } from './Chip.types';
|
|
6
|
+
|
|
7
|
+
const StyledChip = styled(MUIChip, {
|
|
8
|
+
shouldForwardProp: (prop) => prop !== 'disableRipple',
|
|
9
|
+
})<ChipProps>(({ className }) => {
|
|
10
|
+
return {
|
|
11
|
+
height: '24px',
|
|
12
|
+
|
|
13
|
+
// Preset Colors
|
|
14
|
+
'&.presetDefault.MuiChip-colorDefault': {
|
|
15
|
+
backgroundColor: theme.palette.neutralGrey[70],
|
|
16
|
+
color: theme.palette.neutralGrey[25],
|
|
17
|
+
},
|
|
18
|
+
|
|
19
|
+
'&.presetUploaded': {
|
|
20
|
+
backgroundColor: theme.palette.analysisStatus.Uploaded,
|
|
21
|
+
color: theme.palette.lunitTeal[90],
|
|
22
|
+
},
|
|
23
|
+
|
|
24
|
+
'&.presetAnalyzing': {
|
|
25
|
+
backgroundColor: theme.palette.analysisStatus.Analyzing,
|
|
26
|
+
color: theme.palette.purple[80],
|
|
27
|
+
},
|
|
28
|
+
|
|
29
|
+
'&.presetAnalyzed': {
|
|
30
|
+
backgroundColor: theme.palette.analysisStatus.Analyzed,
|
|
31
|
+
color: theme.palette.green[50],
|
|
32
|
+
},
|
|
33
|
+
|
|
34
|
+
'&.presetFailed': {
|
|
35
|
+
color: theme.palette.neutralGrey[0],
|
|
36
|
+
backgroundColor: `${tinycolor(theme.palette.analysisStatus.FailedEnabled).setAlpha(0.5)}`,
|
|
37
|
+
border: `1px solid ${theme.palette.analysisStatus.FailedEnabled}`,
|
|
38
|
+
|
|
39
|
+
'&.MuiChip-clickable:hover': {
|
|
40
|
+
backgroundColor: `${tinycolor(theme.palette.analysisStatus.FailedHover).setAlpha(0.5)}`,
|
|
41
|
+
border: `1px solid ${theme.palette.analysisStatus.FailedHover}`,
|
|
42
|
+
},
|
|
43
|
+
'&.MuiChip-clickable:active': {
|
|
44
|
+
backgroundColor: theme.palette.analysisStatus.FailedSelected,
|
|
45
|
+
border: `1px solid ${theme.palette.analysisStatus.FailedSelected}`,
|
|
46
|
+
},
|
|
47
|
+
},
|
|
48
|
+
|
|
49
|
+
'&.presetReady': {
|
|
50
|
+
color: theme.palette.neutralGrey[0],
|
|
51
|
+
backgroundColor: `${tinycolor(theme.palette.analysisStatus.Ready).setAlpha(0.5)}`,
|
|
52
|
+
border: `1px solid ${theme.palette.analysisStatus.Ready}`,
|
|
53
|
+
'&.MuiChip-clickable:hover': {
|
|
54
|
+
backgroundColor: `${tinycolor(theme.palette.analysisStatus.ReadyHover).setAlpha(0.5)}`,
|
|
55
|
+
border: `1px solid ${theme.palette.analysisStatus.ReadyHover}`,
|
|
56
|
+
},
|
|
57
|
+
'&.MuiChip-clickable:active': {
|
|
58
|
+
backgroundColor: theme.palette.analysisStatus.ReadySelected,
|
|
59
|
+
border: `1px solid ${theme.palette.analysisStatus.ReadySelected}`,
|
|
60
|
+
},
|
|
61
|
+
},
|
|
62
|
+
|
|
63
|
+
'&.presetInferred': {
|
|
64
|
+
color: theme.palette.neutralGrey[0],
|
|
65
|
+
backgroundColor: `${tinycolor(theme.palette.analysisStatus.Inferred).setAlpha(0.5)}`,
|
|
66
|
+
border: `1px solid ${theme.palette.analysisStatus.Inferred}`,
|
|
67
|
+
'&.MuiChip-clickable:hover': {
|
|
68
|
+
backgroundColor: `${tinycolor(theme.palette.analysisStatus.InferredHover).setAlpha(0.5)}`,
|
|
69
|
+
border: `1px solid ${theme.palette.analysisStatus.InferredHover}`,
|
|
70
|
+
},
|
|
71
|
+
'&.MuiChip-clickable:active': {
|
|
72
|
+
backgroundColor: theme.palette.analysisStatus.InferredSelected,
|
|
73
|
+
border: `1px solid ${theme.palette.analysisStatus.InferredSelected}`,
|
|
74
|
+
},
|
|
75
|
+
},
|
|
76
|
+
|
|
77
|
+
'&.presetInvalid': {
|
|
78
|
+
color: theme.palette.neutralGrey[0],
|
|
79
|
+
backgroundColor: `${tinycolor(theme.palette.analysisStatus.Invalid).setAlpha(0.5)}`,
|
|
80
|
+
border: `1px solid ${tinycolor(theme.palette.analysisStatus.Invalid).setAlpha(0.5)}`,
|
|
81
|
+
'&.MuiChip-clickable:hover': {
|
|
82
|
+
backgroundColor: `${tinycolor(theme.palette.analysisStatus.InvalidHover).setAlpha(0.5)}`,
|
|
83
|
+
border: `1px solid ${theme.palette.neutralGrey[0]}`,
|
|
84
|
+
},
|
|
85
|
+
'&.MuiChip-clickable:active': {
|
|
86
|
+
backgroundColor: theme.palette.analysisStatus.InvalidSelected,
|
|
87
|
+
border: `1px solid ${theme.palette.neutralGrey[0]}`,
|
|
88
|
+
},
|
|
89
|
+
},
|
|
90
|
+
|
|
91
|
+
// Label Font
|
|
92
|
+
'.MuiChip-label': {
|
|
93
|
+
fontStyle: 'normal',
|
|
94
|
+
fontWeight: className === 'presetDefault' ? '400' : '500',
|
|
95
|
+
fontSize: '14px',
|
|
96
|
+
lineHeight: '20px',
|
|
97
|
+
},
|
|
98
|
+
|
|
99
|
+
// Icons position
|
|
100
|
+
'.MuiChip-icon': {
|
|
101
|
+
height: '18px',
|
|
102
|
+
marginRight: '-7px',
|
|
103
|
+
color: 'unset', // used default set by preset
|
|
104
|
+
},
|
|
105
|
+
|
|
106
|
+
'.MuiChip-deleteIcon': {
|
|
107
|
+
height: '18px',
|
|
108
|
+
width: '18px',
|
|
109
|
+
marginLeft: '-7px',
|
|
110
|
+
color: theme.palette.neutralGrey[0],
|
|
111
|
+
'&:hover': {
|
|
112
|
+
color: theme.palette.neutralGrey[0],
|
|
113
|
+
borderRadius: '50%',
|
|
114
|
+
backgroundColor: theme.palette.neutralGrey[90],
|
|
115
|
+
},
|
|
116
|
+
},
|
|
117
|
+
};
|
|
118
|
+
});
|
|
119
|
+
|
|
120
|
+
export default StyledChip;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { CloseSmall } from '../../icons';
|
|
3
|
+
import StyledChip from './Chip.styled';
|
|
4
|
+
import type { ChipProps } from './Chip.types';
|
|
5
|
+
import { presetMap } from './Chip.utils';
|
|
6
|
+
|
|
7
|
+
function Chip({ preset, label, icon, onDelete, onClick, ...otherProps }: ChipProps) {
|
|
8
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
9
|
+
const overwrittenProps: any = {
|
|
10
|
+
label,
|
|
11
|
+
icon,
|
|
12
|
+
onDelete,
|
|
13
|
+
onClick,
|
|
14
|
+
};
|
|
15
|
+
// Remove undefined properties
|
|
16
|
+
Object.keys(overwrittenProps).forEach((key) =>
|
|
17
|
+
overwrittenProps[key] === undefined ? delete overwrittenProps[key] : {},
|
|
18
|
+
);
|
|
19
|
+
|
|
20
|
+
const newPreset = preset?.includes('failed') ? 'failed' : preset;
|
|
21
|
+
|
|
22
|
+
const customProps = {
|
|
23
|
+
disableRipple: true,
|
|
24
|
+
deleteIcon: <CloseSmall />,
|
|
25
|
+
...presetMap[newPreset || 'default'],
|
|
26
|
+
...overwrittenProps,
|
|
27
|
+
...otherProps,
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
return <StyledChip {...customProps} />;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export default Chip;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { ChipProps as MuiChipProps } from '@mui/material';
|
|
2
|
+
|
|
3
|
+
export type ChipsPreset =
|
|
4
|
+
| 'default'
|
|
5
|
+
| 'uploaded'
|
|
6
|
+
| 'analyzing'
|
|
7
|
+
| 'analyzed'
|
|
8
|
+
| 'analysis_failed'
|
|
9
|
+
| 'qc_failed'
|
|
10
|
+
| 'ready'
|
|
11
|
+
| 'inferred'
|
|
12
|
+
| 'inferencing'
|
|
13
|
+
| 'invalid';
|
|
14
|
+
|
|
15
|
+
export interface ChipProps extends MuiChipProps {
|
|
16
|
+
preset?: ChipsPreset;
|
|
17
|
+
label?: string;
|
|
18
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Error16, StartT2 } from '../../icons';
|
|
3
|
+
|
|
4
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
5
|
+
const presetMap: any = {
|
|
6
|
+
default: {
|
|
7
|
+
className: 'presetDefault',
|
|
8
|
+
label: 'label',
|
|
9
|
+
color: 'default',
|
|
10
|
+
},
|
|
11
|
+
uploaded: {
|
|
12
|
+
className: 'presetUploaded',
|
|
13
|
+
label: 'Uploaded',
|
|
14
|
+
},
|
|
15
|
+
analyzing: {
|
|
16
|
+
className: 'presetAnalyzing',
|
|
17
|
+
label: 'Analyzing',
|
|
18
|
+
},
|
|
19
|
+
analyzed: {
|
|
20
|
+
className: 'presetAnalyzed',
|
|
21
|
+
label: 'Analyzed',
|
|
22
|
+
},
|
|
23
|
+
failed: {
|
|
24
|
+
className: 'presetFailed',
|
|
25
|
+
label: 'Failed',
|
|
26
|
+
icon: <Error16 />,
|
|
27
|
+
},
|
|
28
|
+
ready: {
|
|
29
|
+
className: 'presetReady',
|
|
30
|
+
label: 'Ready',
|
|
31
|
+
icon: <StartT2 />,
|
|
32
|
+
},
|
|
33
|
+
inferred: {
|
|
34
|
+
className: 'presetInferred',
|
|
35
|
+
label: 'Inferred',
|
|
36
|
+
icon: <StartT2 />,
|
|
37
|
+
},
|
|
38
|
+
inferencing: {
|
|
39
|
+
className: 'presetAnalyzing',
|
|
40
|
+
label: 'Analyzing',
|
|
41
|
+
},
|
|
42
|
+
invalid: {
|
|
43
|
+
className: 'presetInvalid',
|
|
44
|
+
label: 'Invalid',
|
|
45
|
+
icon: <Error16 />,
|
|
46
|
+
},
|
|
47
|
+
};
|
|
48
|
+
|
|
49
|
+
// eslint-disable-next-line import/prefer-default-export
|
|
50
|
+
export { presetMap };
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { styled } from '@mui/material/styles';
|
|
2
|
+
|
|
3
|
+
const DataGridContainer = styled('div')(({ theme }) => ({
|
|
4
|
+
height: '100%',
|
|
5
|
+
width: '100%',
|
|
6
|
+
'.MuiDataGrid-root': {
|
|
7
|
+
border: 'none',
|
|
8
|
+
overflowY: 'hidden',
|
|
9
|
+
borderRadius: 0,
|
|
10
|
+
'.MuiDataGrid-withBorderColor': {
|
|
11
|
+
borderColor: theme.palette.neutralGrey[80],
|
|
12
|
+
},
|
|
13
|
+
'.MuiDataGrid-withBorder': {
|
|
14
|
+
borderRight: `1px solid ${theme.palette.neutralGrey[80]}`,
|
|
15
|
+
padding: theme.spacing(0, 2),
|
|
16
|
+
height: '40px',
|
|
17
|
+
'&:last-child': { borderRight: 'none' },
|
|
18
|
+
},
|
|
19
|
+
'.MuiDataGrid-row': {
|
|
20
|
+
'&:last-child .MuiDataGrid-cell': {
|
|
21
|
+
borderBottom: `1px solid ${theme.palette.neutralGrey[80]}`,
|
|
22
|
+
},
|
|
23
|
+
'.MuiDataGrid-cellCheckbox': {
|
|
24
|
+
borderRight: 0,
|
|
25
|
+
},
|
|
26
|
+
'&:hover': { backgroundColor: theme.palette.others.RowHover },
|
|
27
|
+
'&.Mui-selected': {
|
|
28
|
+
backgroundColor: theme.palette.others.RowHover,
|
|
29
|
+
border: 'transparent',
|
|
30
|
+
'&:hover': { backgroundColor: theme.palette.others.RowHover },
|
|
31
|
+
},
|
|
32
|
+
'& .hover-shown': { opacity: 0 },
|
|
33
|
+
'&:hover .hover-shown, & .hover-shown.menu-active': { opacity: 1 },
|
|
34
|
+
},
|
|
35
|
+
'.MuiDataGrid-cell': {
|
|
36
|
+
...theme.typography.body5,
|
|
37
|
+
borderBottom: `1px solid ${theme.palette.neutralGrey[80]}`,
|
|
38
|
+
padding: theme.spacing(0, 2),
|
|
39
|
+
'&:focus, &:focus-within, &:focus-visible': { outline: 'none' },
|
|
40
|
+
},
|
|
41
|
+
'.MuiDataGrid-columnSeparator': { position: 'relative' },
|
|
42
|
+
'.MuiDataGrid-iconSeparator': { display: 'none' },
|
|
43
|
+
'.MuiDataGrid-columnHeader': {
|
|
44
|
+
'&:focus': { outline: 'none' },
|
|
45
|
+
},
|
|
46
|
+
'.MuiDataGrid-columnHeaderTitleContainer': {
|
|
47
|
+
padding: 0,
|
|
48
|
+
'&:focus': { outline: 'none' },
|
|
49
|
+
},
|
|
50
|
+
},
|
|
51
|
+
'.MuiDataGrid-columnHeaders': {
|
|
52
|
+
borderTop: `1px solid ${theme.palette.neutralGrey[80]}`,
|
|
53
|
+
borderBottom: `1px solid ${theme.palette.neutralGrey[80]}`,
|
|
54
|
+
borderRadius: 0,
|
|
55
|
+
'&:focus': { outline: 'none' },
|
|
56
|
+
'.MuiDataGrid-columnHeaderCheckbox': {
|
|
57
|
+
borderRight: 0,
|
|
58
|
+
},
|
|
59
|
+
},
|
|
60
|
+
'.MuiDataGrid-columnHeaderTitle': {
|
|
61
|
+
...theme.typography.body_b1,
|
|
62
|
+
color: theme.palette.neutralGrey[40],
|
|
63
|
+
},
|
|
64
|
+
}));
|
|
65
|
+
|
|
66
|
+
export default DataGridContainer;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { DataGrid } from '@mui/x-data-grid';
|
|
3
|
+
import { DataGridProps } from '@mui/x-data-grid';
|
|
4
|
+
import DataGridContainer from './DataTable.styled';
|
|
5
|
+
import { Checkbox } from '../Checkbox';
|
|
6
|
+
|
|
7
|
+
function DataTable({ rows, columns, ...otherProps }: DataGridProps) {
|
|
8
|
+
return (
|
|
9
|
+
<DataGridContainer>
|
|
10
|
+
<DataGrid
|
|
11
|
+
rows={rows}
|
|
12
|
+
columns={columns}
|
|
13
|
+
columnHeaderHeight={40}
|
|
14
|
+
rowHeight={40}
|
|
15
|
+
showColumnVerticalBorder
|
|
16
|
+
showCellVerticalBorder
|
|
17
|
+
disableColumnMenu
|
|
18
|
+
hideFooter
|
|
19
|
+
slots={{
|
|
20
|
+
noRowsOverlay: () => <div />,
|
|
21
|
+
baseCheckbox: Checkbox,
|
|
22
|
+
}}
|
|
23
|
+
{...otherProps}
|
|
24
|
+
/>
|
|
25
|
+
</DataGridContainer>
|
|
26
|
+
);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export default DataTable;
|