mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-16 17:46:18 +08:00
refactor: environment setup (#2898)
Co-authored-by: Simon He <57086651+Simon-He95@users.noreply.github.com>
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import { isDesktop } from '@affine/env/constant';
|
||||
import { clsx } from 'clsx';
|
||||
import type { FC, PropsWithChildren, ReactElement } from 'react';
|
||||
|
||||
@@ -22,7 +23,7 @@ export const AppContainer: FC<WorkspaceRootProps> = ({
|
||||
<div
|
||||
className={clsx(appStyle, {
|
||||
'noisy-background': noisyBackground,
|
||||
'blur-background': environment.isDesktop && useBlurBackground,
|
||||
'blur-background': isDesktop && useBlurBackground,
|
||||
})}
|
||||
data-noise-background={noisyBackground}
|
||||
data-is-resizing={resizing}
|
||||
@@ -40,7 +41,7 @@ export const MainContainer = (props: MainContainerProps): ReactElement => {
|
||||
return (
|
||||
<div
|
||||
className={clsx(mainContainerStyle, 'main-container', props.className)}
|
||||
data-is-desktop={environment.isDesktop}
|
||||
data-is-desktop={isDesktop}
|
||||
>
|
||||
{props.children}
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user