Skip to content

Commit

Permalink
fix theme types
Browse files Browse the repository at this point in the history
  • Loading branch information
siriwatknp committed Feb 22, 2024
1 parent d17ab03 commit aacd7b9
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 17 deletions.
17 changes: 1 addition & 16 deletions apps/zero-runtime-next-app/src/app/alert/page.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { styled } from '@mui/zero-runtime';
import Main from '@/components/Main';
import BasicAlerts from '../../../../../docs/data/material/components/alert/BasicAlerts';
import ColorAlerts from '../../../../../docs/data/material/components/alert/ColorAlerts';
import DescriptionAlerts from '../../../../../docs/data/material/components/alert/DescriptionAlerts';
Expand All @@ -7,21 +7,6 @@ import IconAlerts from '../../../../../docs/data/material/components/alert/IconA
import OutlinedAlerts from '../../../../../docs/data/material/components/alert/OutlinedAlerts';
import SimpleAlert from '../../../../../docs/data/material/components/alert/SimpleAlert';

const Main = styled('div')(({ theme }) => ({
display: 'flex',
flexDirection: 'column',
gap: '32px',
marginInline: 'auto',
maxWidth: '900px',
paddingBlock: '16px',
[theme.breakpoints.up('sm')]: {
paddingInline: '24px',
},
[theme.breakpoints.up('lg')]: {
paddingInline: '60px',
},
}));

export default function MaterialUILayout() {
return (
<Main>
Expand Down
18 changes: 18 additions & 0 deletions apps/zero-runtime-next-app/src/components/Main.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
import { styled } from '@mui/zero-runtime';

const Main = styled('div')(({ theme }) => ({
display: 'flex',
flexDirection: 'column',
gap: '32px',
marginInline: 'auto',
maxWidth: '900px',
paddingBlock: '16px',
[theme.breakpoints.up('sm')]: {
paddingInline: '24px',
},
[theme.breakpoints.up('lg')]: {
paddingInline: '60px',
},
}));

export default Main;
4 changes: 3 additions & 1 deletion packages/zero-runtime/src/theme.ts
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
export interface ThemeArgs {}
export interface ThemeArgs {
theme: any;
}

0 comments on commit aacd7b9

Please sign in to comment.