Skip to content

Commit

Permalink
fix: adjust some windows style issues (#2454)
Browse files Browse the repository at this point in the history
  • Loading branch information
pengx17 authored and himself65 committed May 25, 2023
1 parent 341b18d commit b37049d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -191,10 +191,11 @@ export const windowAppControl = style({
WebkitAppRegion: 'no-drag',
cursor: 'pointer',
display: 'inline-flex',
width: '32px',
width: '42px',
height: '32px',
alignItems: 'center',
justifyContent: 'center',
borderRadius: '2px',
borderRadius: '4px',
selectors: {
'&[data-type="close"]:hover': {
background: 'var(--affine-error-color)',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,11 @@ export type SidebarHeaderProps = {
export const SidebarHeader = (props: SidebarHeaderProps) => {
const [open, setOpen] = useAtom(appSidebarOpenAtom);
const environment = getEnvironment();
const isMacosDesktop = environment.isDesktop && environment.isMacOs;
return (
<div
className={navHeaderStyle}
data-is-macos-electron={isMacosDesktop}
data-open={open}
>
{isMacosDesktop && (
<div className={navHeaderStyle} data-open={open}>
{environment.isDesktop && (
<>
{environment.isMacOs && <div style={{ flex: 1 }} />}
<IconButton
size="middle"
data-testid="app-sidebar-arrow-button-back"
Expand All @@ -57,6 +53,8 @@ export const SidebarHeader = (props: SidebarHeaderProps) => {
>
<ArrowRightSmallIcon />
</IconButton>

{!environment.isMacOs && <div style={{ flex: 1 }} />}
</>
)}
<IconButton
Expand Down

0 comments on commit b37049d

Please sign in to comment.