Merge pull request #32157 from tzarger/react-widgets

Add busySpinner to Combobox Props
This commit is contained in:
Benjamin Lichtman
2019-01-24 08:50:37 -08:00
committed by GitHub
3 changed files with 13 additions and 1 deletions
+2 -1
View File
@@ -1,4 +1,4 @@
// Type definitions for react-widgets 4.2
// Type definitions for react-widgets 4.3
// Project: https://github.com/jquense/react-widgets
// Definitions by: Rogier Schouten <https://github.com/rogierschouten>
// Balázs Sándor <https://github.com/sanyatuning>
@@ -6,6 +6,7 @@
// Andrew Makarov <https://github.com/r3nya>
// Maxime Billemaz <https://github.com/MBillemaz>
// Georg Steinmetz <https://github.com/georg94>
// Troy Zarger <https://github.com/tzarger>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.8
+5
View File
@@ -139,6 +139,11 @@ interface ComboBoxProps extends ReactWidgetsCommonDropdownProps<ComboBoxClass>,
* spinner gif, useful when loading data via an ajax call.
*/
busy?: boolean;
/**
* An optional ReactNode to override the spinner gif element when the busy property
* is set to true.
*/
busySpinner?: React.ReactNode;
/**
* The speed, in milliseconds, of the dropdown animation.
*/
@@ -78,6 +78,12 @@ class Test extends React.Component<React.Props<{}>> {
delay={300}
name="box"
/>
<Combobox
busy
busySpinner={
<span className="fas fa-sync fa-spin" />
}
/>
<DateTimePicker
autoFocus
open="date"