Skip to content

Commit 91b3fd1

Browse files
committed
frontend: ListItemLink: Update divider look
Signed-off-by: Oleksandr Dubenko <[email protected]>
1 parent 0a796b9 commit 91b3fd1

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

frontend/src/components/Sidebar/ListItemLink.tsx

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ interface ListItemLinkProps {
1818
iconOnly?: boolean;
1919
hasParent?: boolean;
2020
fullWidth?: boolean;
21+
divider?: boolean;
2122
containerProps?: {
2223
[prop: string]: any;
2324
};
@@ -98,6 +99,7 @@ export default function ListItemLink(props: ListItemLinkProps) {
9899
theme.palette.sidebar.color ??
99100
theme.palette.getContrastText(theme.palette.sidebar.background),
100101
margin: 0,
102+
border: 'none',
101103
borderRadius: theme.shape.borderRadius + 'px',
102104
height: iconOnly ? '50px' : undefined,
103105
opacity: hasParent ? 0.9 : 1.0,
@@ -107,6 +109,18 @@ export default function ListItemLink(props: ListItemLinkProps) {
107109
color: 'currentColor',
108110
},
109111

112+
':before': other.divider
113+
? {
114+
content: '""',
115+
position: 'absolute',
116+
bottom: 0,
117+
left: theme.shape.borderRadius + 'px',
118+
right: theme.shape.borderRadius + 'px',
119+
height: '1px',
120+
background: alpha(theme.palette.sidebar.color, 0.15),
121+
}
122+
: undefined,
123+
110124
'&.Mui-selected': hasParent
111125
? {
112126
':before': {

0 commit comments

Comments
 (0)