CoastalCommitsPastes/client/components/note/index.tsx
Max Leiter 55c5ecfe6c
Update to next 13, switch to pnpm (#127)
* switch to pnpm

* dep improvements, style fixes, next/link codemod

* server: upgrade sqlite
2022-11-08 00:28:19 -08:00

17 lines
357 B
TypeScript

import styles from "./note.module.css"
const Note = ({
type = "info",
children,
...props
}: {
type: "info" | "warning" | "error"
children: React.ReactNode
} & React.ComponentProps<"div">) => (
<div className={`${styles.note} ${styles[type]}`} {...props}>
<strong className={styles.type}>{type}:</strong>
{children}
</div>
)
export default Note