mirror of
https://github.com/toeverything/AFFiNE.git
synced 2024-12-19 15:31:36 +03:00
fix: forward isActive prop in tab
This commit is contained in:
parent
a53a340d16
commit
9e9b8f78f0
@ -11,15 +11,15 @@ const StyledTabs = styled('div')({
|
|||||||
cursor: 'pointer',
|
cursor: 'pointer',
|
||||||
});
|
});
|
||||||
|
|
||||||
const StyledDivider = styled(Divider)<{ isActive?: boolean }>(
|
const StyledDivider = styled(Divider, {
|
||||||
({ isActive }) => {
|
shouldForwardProp: (prop: string) => !['isActive'].includes(prop),
|
||||||
return {
|
})<{ isActive?: boolean }>(({ isActive }) => {
|
||||||
flex: 1,
|
return {
|
||||||
backgroundColor: isActive ? '#3E6FDB' : '#ECF1FB',
|
flex: 1,
|
||||||
borderWidth: '2px',
|
backgroundColor: isActive ? '#3E6FDB' : '#ECF1FB',
|
||||||
};
|
borderWidth: '2px',
|
||||||
}
|
};
|
||||||
);
|
});
|
||||||
|
|
||||||
const TAB_TITLE = {
|
const TAB_TITLE = {
|
||||||
PAGES: 'pages',
|
PAGES: 'pages',
|
||||||
|
Loading…
Reference in New Issue
Block a user