File tree 3 files changed +13
-4
lines changed
3 files changed +13
-4
lines changed Original file line number Diff line number Diff line change @@ -35,6 +35,10 @@ export const useIndeterminate = ({
35
35
typeof indeterminateFromProps !== 'undefined'
36
36
) {
37
37
ref . current . checked = indeterminateFromProps ;
38
+
39
+ // fix needs to come from pretty-checkbox
40
+ // ref.current.indeterminate = indeterminateFromProps;
41
+
38
42
setStatus ( indeterminateFromProps ) ;
39
43
}
40
44
} , [ indeterminateFromProps , state ] ) ;
Original file line number Diff line number Diff line change 1
1
import * as React from 'react' ;
2
2
3
- type Colors = 'primary' | 'success' | 'info' | 'warning' | 'danger' ;
3
+ export type Colors = 'primary' | 'success' | 'info' | 'warning' | 'danger' ;
4
4
type ColorsOutline = 'primary-o' | 'success-o' | 'info-o' | 'warning-o' | 'danger-o' ;
5
5
6
- export type CommonProps < S > = React . InputHTMLAttributes < HTMLInputElement > & {
6
+ export type CommonProps < S > = Omit < React . InputHTMLAttributes < HTMLInputElement > , 'color' > & {
7
7
/**
8
8
* Set true to enable locked mode.
9
9
*/
Original file line number Diff line number Diff line change 1
- import { CommonProps } from './PCRCommonProps' ;
1
+ import { CommonProps , Colors } from './PCRCommonProps' ;
2
2
3
3
type Shape = 'fill' | 'slim' ;
4
4
5
- export type PCRSwitchProps < S = any > = Omit < CommonProps < S > , 'variation' | 'animation' > & {
5
+ export type PCRSwitchProps < S = any > = Omit < CommonProps < S > , 'variation' | 'animation' | 'color' > & {
6
6
/**
7
7
* The shape of the Switch.
8
8
*/
9
9
shape ?: Shape ;
10
10
11
+ /**
12
+ * Choose a color. Note: solid colors only for switch.
13
+ */
14
+ color : Colors ;
15
+
11
16
/**
12
17
* Switch has built-in animations. Do not specify
13
18
* an animation.
You can’t perform that action at this time.
0 commit comments