diff --git a/src/components/PressableWithSecondaryInteraction/index.js b/src/components/PressableWithSecondaryInteraction/index.js index a20355c49a8f..2771db6206ae 100644 --- a/src/components/PressableWithSecondaryInteraction/index.js +++ b/src/components/PressableWithSecondaryInteraction/index.js @@ -73,11 +73,12 @@ class PressableWithSecondaryInteraction extends Component { render() { const defaultPressableProps = _.omit(this.props, ['onSecondaryInteraction', 'children', 'onLongPress']); + const inlineStyle = this.props.inline ? styles.dInline : {}; // On Web, Text does not support LongPress events thus manage inline mode with styling instead of using Text. return ( (this.pressableRef = el)} // eslint-disable-next-line react/jsx-props-no-spreading {...defaultPressableProps} - style={(state) => [StyleUtils.parseStyleFromFunction(this.props.style, state), ...[this.props.inline && styles.dInline]]} + style={(state) => [StyleUtils.parseStyleFromFunction(this.props.style, state), inlineStyle]} > {this.props.children}