Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions src/projects/detail/components/JobPickerRow/JobPickerRow.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ const always = () => true
const never = () => false
const emptyError = () => ''

const MAX_NUMBER = Math.pow(2, 31) - 1

class JobPickerRow extends React.PureComponent {
constructor(props) {
super(props)
Expand Down Expand Up @@ -117,6 +119,7 @@ class JobPickerRow extends React.PureComponent {
value={value.title}
className={cn('tc-file-field__inputs', { error: isRowIncomplete && !value.title.trim() })}
name="title"
maxLength="128"
onChange={this.handleJobTitleChange}
placeholder="Job Title"
/>
Expand Down Expand Up @@ -147,7 +150,7 @@ class JobPickerRow extends React.PureComponent {
<PositiveNumberInput
styleName="noMargin"
className={cn('tc-file-field__inputs', { error: isRowIncomplete && value.people <= 0 })}
max={10000}
max={MAX_NUMBER}
value={value.people || ''}
onChange={this.handlePeopleChange}
onBlur={this.resetPeople}
Expand All @@ -163,7 +166,7 @@ class JobPickerRow extends React.PureComponent {
<PositiveNumberInput
styleName="noMargin"
className={cn('tc-file-field__inputs', {error: isRowIncomplete && value.duration <= 0 })}
max={10000}
max={MAX_NUMBER}
value={value.duration || ''}
onChange={this.handleDurationChange}
onBlur={this.resetDuration}
Expand Down