File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed
Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change 11import classnames from 'classnames' ;
2+ import { INPUT_TYPES } from '../utils/constants' ;
23import PropTypes from 'prop-types' ;
34import React from 'react' ;
45
@@ -22,7 +23,7 @@ FormInput.displayName = 'FormInput';
2223
2324FormInput . propTypes = {
2425 className : PropTypes . string ,
25- state : PropTypes . string
26+ state : PropTypes . oneOf ( INPUT_TYPES )
2627} ;
2728
2829FormInput . propDescriptions = {
Original file line number Diff line number Diff line change @@ -16,6 +16,16 @@ export const BADGE_MODIFIERS = [
1616 'filled'
1717] ;
1818
19+ export const INPUT_TYPES = [
20+ 'normal' ,
21+ 'valid' ,
22+ 'invalid' ,
23+ 'warning' ,
24+ 'help' ,
25+ 'disabled' ,
26+ 'readonly'
27+ ] ;
28+
1929export const LABEL_TYPES = [
2030 'success' ,
2131 'warning' ,
You can’t perform that action at this time.
0 commit comments