Add support for type number on TextFields

This commit is contained in:
Daniel Roth
2017-04-07 13:17:57 +02:00
parent 374e200f7c
commit 2e2233326a
2 changed files with 10 additions and 1 deletions
+4 -1
View File
@@ -1,6 +1,6 @@
// Type definitions for material-ui v0.16.0
// Project: https://github.com/callemall/material-ui
// Definitions by: Nathan Brown <https://github.com/ngbrown>, Oliver Herrmann <https://github.com/herrmanno>
// Definitions by: Nathan Brown <https://github.com/ngbrown>, Oliver Herrmann <https://github.com/herrmanno>, Daniel Roth <https://github.com/DaIgeb>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.2
@@ -1796,6 +1796,9 @@ declare namespace __MaterialUI {
underlineStyle?: React.CSSProperties;
value?: string | number;
autoFocus?: boolean;
min?: number;
max?: number;
step?: number;
}
export class TextField extends React.Component<TextFieldProps, {}> {
blur(): void;
+6
View File
@@ -4740,6 +4740,12 @@ const TextFieldExampleSimple = () => (
<TextField
hintText="Full width"
fullWidth={true}
/><br />
<TextField
type="number"
min={5}
max={50}
step={5}
/>
</div>
);