-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #332 from UTDNebula/fix-load-on-enter
Fix load on enter
- Loading branch information
Showing
8 changed files
with
190 additions
and
148 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,13 @@ | ||
import { | ||
styled, | ||
TableSortLabel as _TableSortLabel, | ||
type TableSortLabelProps, | ||
useMediaQuery, | ||
} from '@mui/material'; | ||
import React from 'react'; | ||
|
||
function TableSortLabel(props: TableSortLabelProps) { | ||
//Selected arrow color | ||
const sortArrowColor = useMediaQuery('(prefers-color-scheme: dark)') | ||
? 'white' | ||
: 'black'; | ||
|
||
//Change arrow color for TableSortLabel | ||
const StyledTableSortLabel = styled(_TableSortLabel)({ | ||
'& .MuiTableSortLabel-icon': { | ||
opacity: 0.5, // Ensure the arrow is always visible | ||
}, | ||
'&.Mui-active .MuiTableSortLabel-icon': { | ||
color: sortArrowColor, // Brighten the arrow | ||
}, | ||
}); | ||
|
||
return <StyledTableSortLabel {...props} />; | ||
} | ||
|
||
export default TableSortLabel; | ||
import { styled, TableSortLabel } from '@mui/material'; | ||
|
||
//Change arrow color for TableSortLabel | ||
const StyledTableSortLabel = styled(TableSortLabel)({ | ||
'& .MuiTableSortLabel-icon': { | ||
opacity: 0.5, // Ensure the arrow is always visible | ||
}, | ||
'&.Mui-active .MuiTableSortLabel-icon': { | ||
color: 'var(--mui-palette-text-primary)', // Brighten the arrow | ||
}, | ||
}); | ||
|
||
export default StyledTableSortLabel; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.