Skip to content

Commit

Permalink
Cleanup paddings and many other things (#470)
Browse files Browse the repository at this point in the history
* unrelated: Unite Verification page

* urelated: remove test page

* unrelated: resolve eslint warning

* resolve #284: set nicer paddings to layout
  • Loading branch information
Matushl authored Nov 23, 2024
1 parent 3e4b6a9 commit 50e3d44
Show file tree
Hide file tree
Showing 12 changed files with 15 additions and 109 deletions.
9 changes: 0 additions & 9 deletions src/components/Latex/LatexExample.module.scss

This file was deleted.

9 changes: 0 additions & 9 deletions src/components/Latex/LatexExample.module.scss.d.ts

This file was deleted.

22 changes: 0 additions & 22 deletions src/components/Latex/LatexExample.tsx

This file was deleted.

10 changes: 9 additions & 1 deletion src/components/PageLayout/PageLayout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,15 @@ export const PageLayout: FC<PageLayoutProps> = ({contentWidth = 2, title = '', c
<Grid xs={0} md={3} sx={{position: 'relative', display: {xs: 'none', md: 'block'}}}>
<StromLogo />
</Grid>
<Grid xs={12} md={contentWidth * 3} sx={{py: 2, px: 1, ...sx}}>
<Grid
xs={12}
md={contentWidth * 3}
sx={{
py: {xs: 4, md: 8, lg: 12},
px: 2,
...sx,
}}
>
{children}
</Grid>
</Grid>
Expand Down
4 changes: 0 additions & 4 deletions src/components/PagePlaceholder/PagePlaceholder.module.scss

This file was deleted.

This file was deleted.

11 changes: 0 additions & 11 deletions src/components/PagePlaceholder/PagePlaceholder.tsx

This file was deleted.

4 changes: 2 additions & 2 deletions src/components/Profile/ProfileForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@ export const ProfileForm: FC = () => {
parent_phone: profile?.parent_phone ?? '',
new_school_description: '',
without_school: profile?.school_id === 1,
school: ({id: profile?.school.code, label: profile?.school.verbose_name} as SelectOption) ?? null,
school: profile ? ({id: profile.school.code, label: profile.school.verbose_name} as SelectOption) : null,
school_not_found: profile?.school_id === 0,
grade: ({id: profile?.grade, label: profile?.grade_name} as SelectOption) ?? null,
grade: profile ? ({id: profile.grade, label: profile.grade_name} as SelectOption) : null,
}

const {handleSubmit, control, watch, setValue} = useForm<ProfileFormValues>({
Expand Down
10 changes: 2 additions & 8 deletions src/pages/malynar/verifikacia/[[...params]].tsx
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
import {NextPage} from 'next'

import {PageLayout} from '@/components/PageLayout/PageLayout'

import {Verification} from '../../../components/Verification/Verification'
import Page from '../../strom/verifikacia/[[...params]]'

const Verifikacia: NextPage = () => {
return (
<PageLayout title="Verifikácia" contentWidth={2}>
<Verification />
</PageLayout>
)
return <Page />
}

export default Verifikacia
10 changes: 2 additions & 8 deletions src/pages/matik/verifikacia/[[...params]].tsx
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
import {NextPage} from 'next'

import {PageLayout} from '@/components/PageLayout/PageLayout'

import {Verification} from '../../../components/Verification/Verification'
import Page from '../../strom/verifikacia/[[...params]]'

const Verifikacia: NextPage = () => {
return (
<PageLayout title="Verifikácia" contentWidth={2}>
<Verification />
</PageLayout>
)
return <Page />
}

export default Verifikacia
14 changes: 0 additions & 14 deletions src/pages/test/index.tsx

This file was deleted.

12 changes: 0 additions & 12 deletions src/pages/test/latex.tsx

This file was deleted.

0 comments on commit 50e3d44

Please sign in to comment.