You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Specify if the control should be disabled, or not
63
68
*/
64
69
disabled: PropTypes.bool,
70
+
65
71
/**
66
72
* Provide text that is used alongside the control label for additional help
67
73
*/
68
74
helperText: PropTypes.node,
75
+
69
76
/**
70
77
* Specify whether you want the underlying label to be visually hidden
71
78
*/
72
79
hideLabel: PropTypes.bool,
80
+
73
81
/**
74
82
* Provide a description for up/down icons that can be read by screen readers
75
83
*/
76
84
iconDescription: PropTypes.string.isRequired,
85
+
77
86
/**
78
87
* Specify a custom `id` for the input
79
88
*/
80
89
id: PropTypes.string.isRequired,
90
+
81
91
/**
82
92
* Specify if the currently value is invalid.
83
93
*/
84
94
invalid: PropTypes.bool,
95
+
85
96
/**
86
97
* Message which is displayed if the value is invalid.
87
98
*/
88
99
invalidText: PropTypes.node,
100
+
89
101
/**
90
102
* `true` to use the mobile variant.
91
103
*/
92
-
isMobile: PropTypes.bool,
104
+
isMobile: deprecate(
105
+
PropTypes.bool,
106
+
`The \`isMobile\` prop no longer needed as the default NumberInput styles are now identical to the mobile variant styles. This prop will be removed in the next major version of \`carbon-components-react\``
107
+
),
108
+
93
109
/**
94
110
* Generic `label` that will be used as the textual representation of what
95
111
* this field is for
96
112
*/
97
113
label: PropTypes.node,
114
+
98
115
/**
99
116
* `true` to use the light version.
100
117
*/
101
118
light: PropTypes.bool,
119
+
102
120
/**
103
121
* The maximum value.
104
122
*/
105
123
max: PropTypes.number,
124
+
106
125
/**
107
126
* The minimum value.
108
127
*/
109
128
min: PropTypes.number,
129
+
110
130
/**
111
131
* The new value is available in 'imaginaryTarget.value'
112
132
* i.e. to get the value: evt.imaginaryTarget.value
@@ -120,34 +140,42 @@ class NumberInput extends Component {
120
140
onChange: !useControlledStateWithValue
121
141
? PropTypes.func
122
142
: requiredIfValueExists(PropTypes.func),
143
+
123
144
/**
124
145
* Provide an optional function to be called when the up/down button is clicked
125
146
*/
126
147
onClick: PropTypes.func,
148
+
127
149
/**
128
150
* Specify if the component should be read-only
129
151
*/
130
152
readOnly: PropTypes.bool,
153
+
131
154
/**
132
155
* Specify the size of the Number Input. Currently supports either `sm` or `xl` as an option.
133
156
*/
134
157
size: PropTypes.oneOf(['sm','xl']),
158
+
135
159
/**
136
160
* Specify how much the valus should increase/decrease upon clicking on up/down button
137
161
*/
138
162
step: PropTypes.number,
163
+
139
164
/**
140
165
* Provide custom text for the component for each translation id
0 commit comments