Skip to content

Commit

Permalink
Pass 'dir' TextField prop through to input component
Browse files Browse the repository at this point in the history
  • Loading branch information
Gudahtt committed Sep 3, 2019
1 parent 047dbf4 commit 6fb873e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion ui/app/components/ui/text-field/text-field.component.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ const styles = {
}

const TextField = props => {
const { error, classes, material, startAdornment, largeLabel, ...textFieldProps } = props
const { error, classes, material, startAdornment, largeLabel, dir, ...textFieldProps } = props

return (
<MaterialTextField
Expand All @@ -91,6 +91,9 @@ const TextField = props => {
underline: material ? classes.materialUnderline : '',
focused: material ? '' : classes.inputFocused,
},
inputProps: {
dir,
},
}}
{...textFieldProps}
/>
Expand All @@ -104,6 +107,7 @@ TextField.defaultProps = {
TextField.propTypes = {
error: PropTypes.string,
classes: PropTypes.object,
dir: PropTypes.string,
material: PropTypes.bool,
startAdornment: PropTypes.element,
largeLabel: PropTypes.bool,
Expand Down

0 comments on commit 6fb873e

Please sign in to comment.