Skip to content

Commit c8503fc

Browse files
Merge pull request #1193 from topcoder-platform/PM-1616
Add max length to other payment types
2 parents 86eb547 + 80c9371 commit c8503fc

File tree

2 files changed

+3
-0
lines changed
  • src
    • apps/copilots/src/pages/copilot-request-form
    • libs/ui/lib/components/form/form-groups/form-input/input-text

2 files changed

+3
-0
lines changed

src/apps/copilots/src/pages/copilot-request-form/index.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -605,6 +605,7 @@ const CopilotRequestForm: FC<{}> = () => {
605605
onChange={bind(handleFormValueChange, this, 'otherPaymentType')}
606606
error={formErrors.otherPaymentType}
607607
tabIndex={0}
608+
maxLength={8}
608609
/>
609610
)}
610611
</div>

src/libs/ui/lib/components/form/form-groups/form-input/input-text/InputText.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ export interface InputTextProps {
3737
readonly forceUpdateValue?: boolean
3838
readonly inputControl?: UseFormRegisterReturn
3939
readonly isLoading?: boolean
40+
readonly maxLength?: number
4041
}
4142

4243
const InputText: FC<InputTextProps> = (props: InputTextProps) => {
@@ -70,6 +71,7 @@ const InputText: FC<InputTextProps> = (props: InputTextProps) => {
7071
onBlur={props.inputControl ? props.inputControl.onBlur : props.onBlur}
7172
onChange={props.inputControl ? props.inputControl.onChange : props.onChange}
7273
name={props.inputControl ? props.inputControl.name : props.name}
74+
maxLength={props.maxLength}
7375
/>
7476
)
7577

0 commit comments

Comments
 (0)