blob: a79feaf8df621c9fd5df757edd90e9e2d2d6f889 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
import { FC } from 'react';
import styles from './no-script.module.scss';
export type NoScriptProps = {
/**
* The noscript message.
*/
message: string;
/**
* The message position. Default: initial.
*/
position?: 'initial' | 'top';
};
export const NoScript: FC<NoScriptProps> = ({
message,
position = 'initial',
}) => {
const positionClass = styles[`noscript--${position}`];
return <div className={`${styles.noscript} ${positionClass}`}>{message}</div>;
};
|