fix(core): duplicate window controls in trash (#6329)

fix https://github.com/toeverything/AFFiNE/issues/6310
This commit is contained in:
EYHN
2024-03-27 02:37:53 +00:00
parent 54c06777a6
commit cccf864ed9
@@ -10,7 +10,6 @@ import {
} from '@affine/core/components/page-list'; } from '@affine/core/components/page-list';
import { usePageHeaderColsDef } from '@affine/core/components/page-list/header-col-def'; import { usePageHeaderColsDef } from '@affine/core/components/page-list/header-col-def';
import { Header } from '@affine/core/components/pure/header'; import { Header } from '@affine/core/components/pure/header';
import { WindowsAppControls } from '@affine/core/components/pure/header/windows-app-controls';
import { useBlockSuiteMetaHelper } from '@affine/core/hooks/affine/use-block-suite-meta-helper'; import { useBlockSuiteMetaHelper } from '@affine/core/hooks/affine/use-block-suite-meta-helper';
import { useBlockSuiteDocMeta } from '@affine/core/hooks/use-block-suite-page-meta'; import { useBlockSuiteDocMeta } from '@affine/core/hooks/use-block-suite-page-meta';
import { useAFFiNEI18N } from '@affine/i18n/hooks'; import { useAFFiNEI18N } from '@affine/i18n/hooks';
@@ -24,7 +23,6 @@ import { ViewBodyIsland, ViewHeaderIsland } from '../../modules/workbench';
import { EmptyPageList } from './page-list-empty'; import { EmptyPageList } from './page-list-empty';
import * as styles from './trash-page.css'; import * as styles from './trash-page.css';
const isWindowsDesktop = environment.isDesktop && environment.isWindows;
const TrashHeader = () => { const TrashHeader = () => {
const t = useAFFiNEI18N(); const t = useAFFiNEI18N();
return ( return (
@@ -35,13 +33,6 @@ const TrashHeader = () => {
{t['com.affine.workspaceSubPath.trash']()} {t['com.affine.workspaceSubPath.trash']()}
</div> </div>
} }
right={
isWindowsDesktop ? (
<div style={{ marginRight: -16 }}>
<WindowsAppControls />
</div>
) : null
}
/> />
); );
}; };