mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-13 04:48:53 +00:00
feat: support bookmark (#2458)
Co-authored-by: himself65 <himself65@outlook.com>
This commit is contained in:
@@ -13,6 +13,7 @@ export type IconMenuProps = PropsWithChildren<{
|
||||
endIcon?: ReactElement;
|
||||
iconSize?: [number, number];
|
||||
disabled?: boolean;
|
||||
active?: boolean;
|
||||
}> &
|
||||
HTMLAttributes<HTMLButtonElement>;
|
||||
|
||||
|
||||
@@ -51,7 +51,8 @@ export const StyledContent = styled('div')(() => {
|
||||
export const StyledMenuItem = styled('button')<{
|
||||
isDir?: boolean;
|
||||
disabled?: boolean;
|
||||
}>(({ isDir = false, disabled = false }) => {
|
||||
active?: boolean;
|
||||
}>(({ isDir = false, disabled = false, active = false }) => {
|
||||
return {
|
||||
width: '100%',
|
||||
borderRadius: '5px',
|
||||
@@ -82,5 +83,11 @@ export const StyledMenuItem = styled('button')<{
|
||||
: {
|
||||
backgroundColor: 'var(--affine-hover-color)',
|
||||
},
|
||||
|
||||
...(active && !disabled
|
||||
? {
|
||||
backgroundColor: 'var(--affine-hover-color)',
|
||||
}
|
||||
: {}),
|
||||
};
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user