export const Admonition = ({ props, children, }: { props: Record children: string }): string => { const type = props.type ? String(props.type) : 'note' return `${capitalize(type)}: ${children}` } const capitalize = (s: T) => (s[0].toUpperCase() + s.slice(1)) as Capitalize