diff options
author | Stas Vilchik <stas-vilchik@users.noreply.github.com> | 2017-03-17 09:10:48 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-03-17 09:10:48 +0100 |
commit | de4365079bad2df3bdee2133576dc913ffbf1ab2 (patch) | |
tree | a522ccb952f0d37f454e8188e13b3dec3f731912 /server/sonar-web/src/main/js/components/controls/DateInput.js | |
parent | 6a03df65cc0c91a26150ea172a2c480e07326ea1 (diff) | |
download | sonarqube-de4365079bad2df3bdee2133576dc913ffbf1ab2.tar.gz sonarqube-de4365079bad2df3bdee2133576dc913ffbf1ab2.zip |
format code using prettier (#1774)
Diffstat (limited to 'server/sonar-web/src/main/js/components/controls/DateInput.js')
-rw-r--r-- | server/sonar-web/src/main/js/components/controls/DateInput.js | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/server/sonar-web/src/main/js/components/controls/DateInput.js b/server/sonar-web/src/main/js/components/controls/DateInput.js index 16bf61e51c1..7ceb11373e5 100644 --- a/server/sonar-web/src/main/js/components/controls/DateInput.js +++ b/server/sonar-web/src/main/js/components/controls/DateInput.js @@ -36,20 +36,20 @@ export default class DateInput extends React.Component { format: 'yy-mm-dd' }; - componentDidMount () { + componentDidMount() { this.attachDatePicker(); } - componentWillReceiveProps (nextProps) { + componentWillReceiveProps(nextProps) { this.refs.input.value = nextProps.value; } - handleChange () { + handleChange() { const { value } = this.refs.input; this.props.onChange(value); } - attachDatePicker () { + attachDatePicker() { const opts = { dateFormat: this.props.format, changeMonth: true, @@ -62,26 +62,26 @@ export default class DateInput extends React.Component { } } - render () { + render() { const inputProps = pick(this.props, ['placeholder', 'name']); /* eslint max-len: 0 */ return ( - <span className="date-input-control"> - <input - className="date-input-control-input" - ref="input" - type="text" - initialValue={this.props.value} - readOnly={true} - {...inputProps}/> - <span className="date-input-control-icon"> - <svg width="14" height="14" viewBox="0 0 16 16"> - <path - d="M5.5 6h2v2h-2V6zm3 0h2v2h-2V6zm3 0h2v2h-2V6zm-9 6h2v2h-2v-2zm3 0h2v2h-2v-2zm3 0h2v2h-2v-2zm-3-3h2v2h-2V9zm3 0h2v2h-2V9zm3 0h2v2h-2V9zm-9 0h2v2h-2V9zm11-9v1h-2V0h-7v1h-2V0h-2v16h15V0h-2zm1 15h-13V4h13v11z"/> - </svg> - </span> + <span className="date-input-control"> + <input + className="date-input-control-input" + ref="input" + type="text" + initialValue={this.props.value} + readOnly={true} + {...inputProps} + /> + <span className="date-input-control-icon"> + <svg width="14" height="14" viewBox="0 0 16 16"> + <path d="M5.5 6h2v2h-2V6zm3 0h2v2h-2V6zm3 0h2v2h-2V6zm-9 6h2v2h-2v-2zm3 0h2v2h-2v-2zm3 0h2v2h-2v-2zm-3-3h2v2h-2V9zm3 0h2v2h-2V9zm3 0h2v2h-2V9zm-9 0h2v2h-2V9zm11-9v1h-2V0h-7v1h-2V0h-2v16h15V0h-2zm1 15h-13V4h13v11z" /> + </svg> </span> + </span> ); } } |