UNPKG

@plone/volto

Version:
16 lines (14 loc) 333 B
import React from 'react'; import cx from 'classnames'; const TextWidget = ({ value, children, className }) => value ? ( <span className={cx(className, 'text', 'widget')} style={{ whiteSpace: 'pre-wrap' }} > {children ? children(value) : value} </span> ) : ( '' ); export default TextWidget;