diff options
Diffstat (limited to 'src/components/atoms/layout')
| -rw-r--r-- | src/components/atoms/layout/copyright.tsx | 4 | ||||
| -rw-r--r-- | src/components/atoms/layout/main.tsx | 6 | ||||
| -rw-r--r-- | src/components/atoms/layout/no-script.tsx | 4 | ||||
| -rw-r--r-- | src/components/atoms/layout/notice.tsx | 4 | ||||
| -rw-r--r-- | src/components/atoms/layout/section.tsx | 4 |
5 files changed, 13 insertions, 9 deletions
diff --git a/src/components/atoms/layout/copyright.tsx b/src/components/atoms/layout/copyright.tsx index 76252ee..f70695d 100644 --- a/src/components/atoms/layout/copyright.tsx +++ b/src/components/atoms/layout/copyright.tsx @@ -1,4 +1,4 @@ -import { ReactNode, VFC } from 'react'; +import { FC, ReactNode } from 'react'; import styles from './copyright.module.scss'; export type CopyrightDates = { @@ -32,7 +32,7 @@ export type CopyrightProps = { * * Renders a copyright information (owner, dates, license icon). */ -const Copyright: VFC<CopyrightProps> = ({ owner, dates, icon }) => { +const Copyright: FC<CopyrightProps> = ({ owner, dates, icon }) => { const getFormattedDate = (date: string) => { const datetime = new Date(date).toISOString(); diff --git a/src/components/atoms/layout/main.tsx b/src/components/atoms/layout/main.tsx index 4549328..d92a5c7 100644 --- a/src/components/atoms/layout/main.tsx +++ b/src/components/atoms/layout/main.tsx @@ -1,7 +1,11 @@ -import { FC } from 'react'; +import { FC, ReactNode } from 'react'; export type MainProps = { /** + * The main body. + */ + children: ReactNode; + /** * Set additional classnames to the main element. */ className?: string; diff --git a/src/components/atoms/layout/no-script.tsx b/src/components/atoms/layout/no-script.tsx index 6358cf8..a503e0c 100644 --- a/src/components/atoms/layout/no-script.tsx +++ b/src/components/atoms/layout/no-script.tsx @@ -1,4 +1,4 @@ -import { VFC } from 'react'; +import { FC } from 'react'; import styles from './no-script.module.scss'; export type NoScriptProps = { @@ -12,7 +12,7 @@ export type NoScriptProps = { position?: 'initial' | 'top'; }; -const NoScript: VFC<NoScriptProps> = ({ message, position = 'initial' }) => { +const NoScript: FC<NoScriptProps> = ({ message, position = 'initial' }) => { const positionClass = styles[`noscript--${position}`]; return <div className={`${styles.noscript} ${positionClass}`}>{message}</div>; diff --git a/src/components/atoms/layout/notice.tsx b/src/components/atoms/layout/notice.tsx index b6e09c5..115bd9c 100644 --- a/src/components/atoms/layout/notice.tsx +++ b/src/components/atoms/layout/notice.tsx @@ -1,4 +1,4 @@ -import { VFC } from 'react'; +import { FC } from 'react'; import styles from './notice.module.scss'; export type NoticeKind = 'error' | 'info' | 'success' | 'warning'; @@ -19,7 +19,7 @@ export type NoticeProps = { * * Render a colored message depending on notice kind. */ -const Notice: VFC<NoticeProps> = ({ kind, message }) => { +const Notice: FC<NoticeProps> = ({ kind, message }) => { const kindClass = `wrapper--${kind}`; return ( diff --git a/src/components/atoms/layout/section.tsx b/src/components/atoms/layout/section.tsx index f1bbb34..cb727ff 100644 --- a/src/components/atoms/layout/section.tsx +++ b/src/components/atoms/layout/section.tsx @@ -1,4 +1,4 @@ -import { ReactNode, VFC } from 'react'; +import { FC, ReactNode } from 'react'; import Heading from '../headings/heading'; import styles from './section.module.scss'; @@ -32,7 +32,7 @@ export type SectionProps = { * * Render a section element. */ -const Section: VFC<SectionProps> = ({ +const Section: FC<SectionProps> = ({ className = '', content, title, |
