fix: position of sidebar switch button (#3995)

Co-authored-by: Alex Yang <himself65@outlook.com>
This commit is contained in:
Camol 2023-08-28 23:58:59 +08:00 committed by GitHub
parent b9c3a11a95
commit e92d27549a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -19,10 +19,10 @@ export const SidebarHeader = (props: SidebarHeaderProps) => {
const open = useAtomValue(appSidebarOpenAtom);
return (
<div className={navHeaderStyle} data-open={open}>
<div style={{ flex: 1 }} />
{open && <SidebarSwitch />}
{environment.isDesktop && (
<>
{environment.isMacOs && <div style={{ flex: 1 }} />}
<IconButton
data-testid="app-sidebar-arrow-button-back"
disabled={props.router?.history.current === 0}