UNPKG

wix-style-react

Version:
22 lines 1.01 kB
import React from 'react'; import PropTypes from 'prop-types'; import { st, classes } from './Footnote.st.css'; import Divider from '../../../Divider'; import { useBaseModalLayoutContext } from '../../BaseModalLayoutContext'; export const Footnote = ({ dataHook, className, children }) => { const { footnoteClassName, footnote = children } = useBaseModalLayoutContext(); return ((footnote && (React.createElement("div", { "data-hook": dataHook, className: st(classes.root, footnoteClassName, className) }, React.createElement(Divider, null), React.createElement("div", { className: classes.innerContent }, footnote)))) || null); }; Footnote.displayName = 'BaseModalLayout.Footnote'; Footnote.propTypes = { /** additional css classes */ className: PropTypes.string, /** data hook for testing */ dataHook: PropTypes.string, /** a footnote node, to be rendered at the very bottom of the modal */ footnote: PropTypes.node, }; //# sourceMappingURL=Footnote.js.map