diff --git a/striker-ui/components/Files/Files.tsx b/striker-ui/components/Files/Files.tsx index 4f64bab7..61385fb7 100644 --- a/striker-ui/components/Files/Files.tsx +++ b/striker-ui/components/Files/Files.tsx @@ -1,16 +1,14 @@ import { useEffect, useState } from 'react'; -import { Box, IconButton } from '@mui/material'; +import { Box } from '@mui/material'; import { Add as AddIcon, Check as CheckIcon, Edit as EditIcon, } from '@mui/icons-material'; -import { styled } from '@mui/material/styles'; import EventEmitter from 'events'; import API_BASE_URL from '../../lib/consts/API_BASE_URL'; import { BLUE } from '../../lib/consts/DEFAULT_THEME'; -import ICON_BUTTON_STYLE from '../../lib/consts/ICON_BUTTON_STYLE'; import FileEditForm from './FileEditForm'; import FileList from './FileList'; @@ -21,8 +19,7 @@ import Spinner from '../Spinner'; import { HeaderText } from '../Text'; import fetchJSON from '../../lib/fetchers/fetchJSON'; - -const StyledIconButton = styled(IconButton)(ICON_BUTTON_STYLE); +import IconButton from '../IconButton'; const Files = (): JSX.Element => { const [rawFilesOverview, setRawFilesOverview] = useState([]); @@ -108,13 +105,13 @@ const Files = (): JSX.Element => { > {!isEditMode && ( - + - + )} - + {isEditMode ? : } - + {fetchRawFilesError && ( diff --git a/striker-ui/lib/consts/ICON_BUTTON_STYLE.ts b/striker-ui/lib/consts/ICON_BUTTON_STYLE.ts deleted file mode 100644 index 1e3b9bc5..00000000 --- a/striker-ui/lib/consts/ICON_BUTTON_STYLE.ts +++ /dev/null @@ -1,12 +0,0 @@ -import { BLACK, BORDER_RADIUS, GREY } from './DEFAULT_THEME'; - -const ICON_BUTTON_STYLE: Readonly> = { - borderRadius: BORDER_RADIUS, - backgroundColor: GREY, - '&:hover': { - backgroundColor: GREY, - }, - color: BLACK, -}; - -export default ICON_BUTTON_STYLE;