File tree 10 files changed +15
-15
lines changed
createCreatableSelectComponent
createCreatableSelectChildrenComponent
createSearchableMultiSelectComponent
createSearchableMultiSelectChildrenComponent
createSearchableSelectComponent
createSearchableSelectChildrenComponent
createSplitButtonComponent 10 files changed +15
-15
lines changed Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ import type { ControlStyle } from '../../../types/ControlStyle'
11
11
import { createInputComponent } from '../../createInputComponent'
12
12
import { Hitbox } from '../../Hitbox'
13
13
14
- type Instance < T extends null | number | string > = React . FunctionComponent < {
14
+ type Instance < T extends null | boolean | number | string > = React . FunctionComponent < {
15
15
readonly options : ReadonlyArray < {
16
16
readonly value : T
17
17
readonly label : string
@@ -39,7 +39,7 @@ const globalStyles = StyleSheet.create({
39
39
} )
40
40
41
41
export const createCreatableSelectChildrenComponent = <
42
- T extends null | number | string
42
+ T extends null | boolean | number | string
43
43
> (
44
44
controlStyle : ControlStyle
45
45
) : Instance < T > & { readonly creatableSelectChildren : Introspection } => {
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ import type { CreatableSelectProps } from '../../types/CreatableSelectProps'
15
15
* @returns The created React component.
16
16
*/
17
17
export function createCreatableSelectComponent <
18
- T extends null | number | string
18
+ T extends null | boolean | number | string
19
19
> (
20
20
controlStyle : ControlStyle ,
21
21
rightIcon : null | SvgIcon
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ import type { ControlStyle } from '../../../types/ControlStyle'
11
11
import { createInputComponent } from '../../createInputComponent'
12
12
import { Hitbox } from '../../Hitbox'
13
13
14
- type Instance < T extends null | number | string > = React . FunctionComponent < {
14
+ type Instance < T extends null | boolean | number | string > = React . FunctionComponent < {
15
15
readonly options : ReadonlyArray < {
16
16
readonly value : T
17
17
readonly label : string
@@ -40,7 +40,7 @@ const globalStyles = StyleSheet.create({
40
40
} )
41
41
42
42
export const createSearchableMultiSelectChildrenComponent = <
43
- T extends null | number | string
43
+ T extends null | boolean | number | string
44
44
> (
45
45
controlStyle : ControlStyle
46
46
) : Instance < T > & { readonly searchableMultiSelectChildren : Introspection } => {
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ import type { SearchableMultiSelectProps } from '../../types/SearchableMultiSele
15
15
* @returns The created React component.
16
16
*/
17
17
export function createSearchableMultiSelectComponent <
18
- T extends null | number | string
18
+ T extends null | boolean | number | string
19
19
> (
20
20
controlStyle : ControlStyle ,
21
21
rightIcon : null | SvgIcon
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ import type { ControlStyle } from '../../../types/ControlStyle'
11
11
import { createInputComponent } from '../../createInputComponent'
12
12
import { Hitbox } from '../../Hitbox'
13
13
14
- type Instance < T extends null | number | string > = React . FunctionComponent < {
14
+ type Instance < T extends null | boolean | number | string > = React . FunctionComponent < {
15
15
readonly options : ReadonlyArray < {
16
16
readonly value : T
17
17
readonly label : string
@@ -37,7 +37,7 @@ const globalStyles = StyleSheet.create({
37
37
} )
38
38
39
39
export const createSearchableSelectChildrenComponent = <
40
- T extends null | number | string
40
+ T extends null | boolean | number | string
41
41
> (
42
42
controlStyle : ControlStyle
43
43
) : Instance < T > & { readonly searchableSelectChildren : Introspection } => {
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ import type { SearchableSelectProps } from '../../types/SearchableSelectProps'
15
15
* @returns The created React component.
16
16
*/
17
17
export function createSearchableSelectComponent <
18
- T extends null | number | string
18
+ T extends null | boolean | number | string
19
19
> (
20
20
controlStyle : ControlStyle ,
21
21
rightIcon : null | SvgIcon
Original file line number Diff line number Diff line change @@ -157,7 +157,7 @@ const createButtonTextStyleInstance = (
157
157
}
158
158
}
159
159
160
- type Instance < TValue extends null | number | string > = React . FunctionComponent <
160
+ type Instance < TValue extends null | boolean | number | string > = React . FunctionComponent <
161
161
React . PropsWithChildren < {
162
162
/**
163
163
* The currently selected value.
@@ -193,7 +193,7 @@ React.PropsWithChildren<{
193
193
} ) >
194
194
>
195
195
196
- type SegmentInstance < TValue extends null | number | string > =
196
+ type SegmentInstance < TValue extends null | boolean | number | string > =
197
197
React . FunctionComponent < {
198
198
/**
199
199
* The value of the segment.
@@ -223,7 +223,7 @@ type SegmentInstance<TValue extends null | number | string> =
223
223
*/
224
224
export const createSplitButtonComponent = <
225
225
TType extends string ,
226
- TValue extends null | number | string
226
+ TValue extends null | boolean | number | string
227
227
> (
228
228
splitButtonStyle : SplitButtonStyle < TType >
229
229
) : Instance < TValue > & {
Original file line number Diff line number Diff line change 2
2
* Props to be given to creatable select components.
3
3
* @template T The value of a listed option.
4
4
*/
5
- export interface CreatableSelectProps < T extends null | number | string > {
5
+ export interface CreatableSelectProps < T extends null | boolean | number | string > {
6
6
/**
7
7
* When true, it will not be possible to select an option. It will otherwise
8
8
* be possible to do so.
Original file line number Diff line number Diff line change 9
9
*/
10
10
export interface CustomTextTableColumn <
11
11
TKey extends string ,
12
- TRow extends { readonly [ TKeyItem in TKey ] : null | number | string } ,
12
+ TRow extends { readonly [ TKeyItem in TKey ] : null | boolean | number | string } ,
13
13
TContext
14
14
> {
15
15
/**
Original file line number Diff line number Diff line change 1
1
/**
2
2
* A value within a table which can be used to key a row.
3
3
*/
4
- export type KeyableTableCell = null | number | string
4
+ export type KeyableTableCell = null | boolean | number | string
You can’t perform that action at this time.
0 commit comments