diff --git a/frontend/src/components/AccountTable/AccountTable.js b/frontend/src/components/AccountTable/AccountTable.js index c386f86..0439d07 100644 --- a/frontend/src/components/AccountTable/AccountTable.js +++ b/frontend/src/components/AccountTable/AccountTable.js @@ -49,6 +49,17 @@ import Menu from '@mui/material/Menu' import MenuItem from '@mui/material/MenuItem' import CheckBoxOutlineBlankIcon from '@mui/icons-material/CheckBoxOutlineBlank' import CheckBoxIcon from '@mui/icons-material/CheckBox' +import { styled } from '@mui/material/styles' + +const StyledMTableToolbar = styled(MTableToolbar)(({ theme }) => ({ + backgroundColor: theme.palette.action.hover, + minHeight: '0 !important', + padding: '0 !important', + margin: '0', + '& .MuiInputBase-input': { + padding: '0 !important', + }, +})) function StatusIconButton(props) { const handleClick = e => { @@ -741,7 +752,7 @@ export default function Account(props) { const exportData = () => { const [cols, data] = getTableData() - ExportCsv(cols, data, 'download') + ExportCsv(cols, data, `${account.name} Transactions`) } const onSelectionChange = data => { @@ -757,7 +768,114 @@ export default function Account(props) { gridTemplateRows: 'auto 1fr auto', height: '100vh', }} - title={} + title={ + + + + + + + + {popupState => ( + <> + + + + Mark Cleared + + + + Mark Uncleared + + + + Delete Transactions + + + + )} + + + + + + } options={{ padding: 'dense', draggable: false, @@ -803,113 +921,18 @@ export default function Account(props) { backgroundColor: theme.palette.background.default, }} > - + + - - - - - - - - {popupState => ( - <> - - - - Mark Cleared - - - - Mark Uncleared - - - - Delete Transactions - - - - )} - - - - - + searchFieldVariant="outlined" + /> diff --git a/frontend/src/components/AccountTable/AccountTableHeader.js b/frontend/src/components/AccountTable/AccountTableHeader.js index a993f7b..fae9f04 100644 --- a/frontend/src/components/AccountTable/AccountTableHeader.js +++ b/frontend/src/components/AccountTable/AccountTableHeader.js @@ -45,123 +45,125 @@ export default function BudgetTableHeader({ accountId, name }) { return ( - -
-

- {account.name} -

- - - setAccountName(e.target.value)} - /> - - - - - -
+ + +
+

+ {account.name} +

+ + + setAccountName(e.target.value)} + /> + + + + + +
+ +
+ + + {intlFormat(account.cleared)} + + + Cleared + + +
+ +
+
+ +
+ + + {intlFormat(account.uncleared)} + + + Uncleared + + +
+ +
=
+ +
+ + + {intlFormat(account.balance)} + + + Working Balance + + +
+
- - - {intlFormat(account.cleared)} - - - Cleared - - -
- -
+
- -
- - - {intlFormat(account.uncleared)} - - - Uncleared - - -
- -
=
- -
- - - {intlFormat(account.balance)} - - - Working Balance - - -
- -
- + + + )} + + + + } components={{ Toolbar: props => ( - + + + + - - - - - {popupState => ( - <> - - - - )} - - - - - ), Row: props => ( diff --git a/frontend/src/components/BudgetTable/BudgetTableHeader.js b/frontend/src/components/BudgetTable/BudgetTableHeader.js index b3e4ba5..351e60d 100644 --- a/frontend/src/components/BudgetTable/BudgetTableHeader.js +++ b/frontend/src/components/BudgetTable/BudgetTableHeader.js @@ -66,7 +66,7 @@ export default function BudgetTableHeader(props) { // backgroundColor: theme.palette.background.default }} > - +