From dac66d0de306a9598cce805830113bde92af3133 Mon Sep 17 00:00:00 2001 From: Jacob Froman Date: Fri, 15 Dec 2017 10:00:21 -0600 Subject: [PATCH] Add style prop CommonApiProps --- types/rc-slider/README.md | 2 +- types/rc-slider/index.d.ts | 6 ++++++ types/rc-slider/rc-slider-tests.tsx | 1 + 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/types/rc-slider/README.md b/types/rc-slider/README.md index f51d31a6b6..622c75a90e 100644 --- a/types/rc-slider/README.md +++ b/types/rc-slider/README.md @@ -5,7 +5,7 @@ This package contains type definitions for rc-slider (https://github.com/react-component/slider). Additional Details - * Last updated: Tue, 24 Oct 2017 + * Last updated: Fri, 15 Dec 2017 * Dependencies: react * Global values: none diff --git a/types/rc-slider/index.d.ts b/types/rc-slider/index.d.ts index f64ae8c03c..f2010b3ec9 100644 --- a/types/rc-slider/index.d.ts +++ b/types/rc-slider/index.d.ts @@ -3,6 +3,7 @@ // Definitions by: Marcinkus Mantas // Alexander Mattoni // Austin Turner +// Jacob Froman // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.3 @@ -91,6 +92,11 @@ export interface CommonApiProps { */ tipFormatter?: ((value: any) => any | undefined) | null; + /** + * The style used for the background and container. (both for slider(Object) and range(Array of Object), the array will be used for mutli handle follow element order) + */ + style?: React.CSSProperties[] | React.CSSProperties; + /** * The style used for handle. (both for slider(Object) and range(Array of Object), the array will be used for mutli handle follow element order) */ diff --git a/types/rc-slider/rc-slider-tests.tsx b/types/rc-slider/rc-slider-tests.tsx index 84c9997be6..e08a674dca 100644 --- a/types/rc-slider/rc-slider-tests.tsx +++ b/types/rc-slider/rc-slider-tests.tsx @@ -35,6 +35,7 @@ ReactDOM.render( onAfterChange={() => { }} defaultValue={0.1} value={0.1} + style={{backgroundColor: 'plum'}} dotStyle={{backgroundColor: 'antiquewhite'}} activeDotStyle={{backgroundColor: 'antiquewhite'}} />,