diff --git a/src/components/HTMLEngineProvider/BaseHTMLEngineProvider.js b/src/components/HTMLEngineProvider/BaseHTMLEngineProvider.js index 456cd1ecf3f0..4f4f18d53da5 100755 --- a/src/components/HTMLEngineProvider/BaseHTMLEngineProvider.js +++ b/src/components/HTMLEngineProvider/BaseHTMLEngineProvider.js @@ -14,12 +14,17 @@ import fontFamily from '../../styles/fontFamily'; const propTypes = { /** Whether text elements should be selectable */ textSelectable: PropTypes.bool, + + /** Handle line breaks according to the HTML standard (default on web) */ + enableExperimentalBRCollapsing: PropTypes.bool, + children: PropTypes.node, }; const defaultProps = { textSelectable: false, children: null, + enableExperimentalBRCollapsing: false, }; // Declare nonstandard tags and their content model here @@ -70,6 +75,7 @@ const BaseHTMLEngineProvider = (props) => { defaultViewProps={defaultViewProps} renderers={htmlRenderers} computeEmbeddedMaxWidth={HTMLEngineUtils.computeEmbeddedMaxWidth} + enableExperimentalBRCollapsing={props.enableExperimentalBRCollapsing} > {props.children} diff --git a/src/components/HTMLEngineProvider/index.native.js b/src/components/HTMLEngineProvider/index.native.js index 3c8c0949515d..a285a313e900 100755 --- a/src/components/HTMLEngineProvider/index.native.js +++ b/src/components/HTMLEngineProvider/index.native.js @@ -3,7 +3,7 @@ import BaseHTMLEngineProvider from './BaseHTMLEngineProvider'; import {propTypes, defaultProps} from './htmlEnginePropTypes'; const HTMLEngineProvider = props => ( - + {props.children} );