Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 9 additions & 3 deletions src/components/ApplicationLayout/ApplicationLayout.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
import { FC, ReactNode } from 'react';

import { useUnit } from 'effector-react';
import { ThemeProvider } from '@gravity-ui/uikit';
import { cn } from '@bem-react/classname';
import { $theme } from '@/model';

import '@gravity-ui/uikit/styles/fonts.css';
import '@gravity-ui/uikit/styles/styles.css';

import './ApplicationLayout.css';
import { $theme } from '@/model';
import { useUnit } from 'effector-react';

const bem = cn('ApplicationLayout');

Expand All @@ -17,5 +19,9 @@ type ApplicationLayoutProps = {
export const ApplicationLayout: FC<ApplicationLayoutProps> = ({ children }) => {
const theme = useUnit($theme);

return <div className={bem(null, ['g-root', `g-root_theme_${theme}`])}>{children}</div>;
return (
<ThemeProvider theme={theme}>
<div className={bem()}>{children}</div>
</ThemeProvider>
);
};
7 changes: 7 additions & 0 deletions src/components/Header/Header.css
Original file line number Diff line number Diff line change
@@ -1,9 +1,16 @@
.Header {
position: sticky;
top: 0;

padding: var(--g-spacing-4) var(--g-spacing-8);

display: flex;
gap: var(--g-spacing-6);
justify-content: space-between;

background: var(--g-color-base-background);

z-index: 1;
}

.Header-Left,
Expand Down
3 changes: 3 additions & 0 deletions src/components/ProjectLayout/ProjectLayout.css
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@
flex: 1;
min-height: 0;
background-color: var(--g-color-base-background);

max-height: 100vh;
box-sizing: border-box;
}

.ProjectLayout-Content {
Expand Down
3 changes: 0 additions & 3 deletions src/index.css
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
html,
body,
.root {
overflow: hidden;

height: 100%;
margin: 0;
padding: 0;
}
Expand Down