fix: os.selectの型定義の上で default が文字列である問題を修正
This commit is contained in:
parent
c803f842ba
commit
38491f418c
|
@ -77,7 +77,7 @@ type Select = {
|
||||||
sectionTitle: string;
|
sectionTitle: string;
|
||||||
items: SelectItem[];
|
items: SelectItem[];
|
||||||
})[];
|
})[];
|
||||||
default: string | null;
|
default: any | null;
|
||||||
};
|
};
|
||||||
|
|
||||||
type Result = string | number | true | null;
|
type Result = string | number | true | null;
|
||||||
|
|
|
@ -478,7 +478,7 @@ type SelectItem<C> = {
|
||||||
export function select<C = unknown>(props: {
|
export function select<C = unknown>(props: {
|
||||||
title?: string;
|
title?: string;
|
||||||
text?: string;
|
text?: string;
|
||||||
default: string;
|
default: C;
|
||||||
items: (SelectItem<C> | {
|
items: (SelectItem<C> | {
|
||||||
sectionTitle: string;
|
sectionTitle: string;
|
||||||
items: SelectItem<C>[];
|
items: SelectItem<C>[];
|
||||||
|
@ -491,7 +491,7 @@ export function select<C = unknown>(props: {
|
||||||
export function select<C = unknown>(props: {
|
export function select<C = unknown>(props: {
|
||||||
title?: string;
|
title?: string;
|
||||||
text?: string;
|
text?: string;
|
||||||
default?: string | null;
|
default?: C | null;
|
||||||
items: (SelectItem<C> | {
|
items: (SelectItem<C> | {
|
||||||
sectionTitle: string;
|
sectionTitle: string;
|
||||||
items: SelectItem<C>[];
|
items: SelectItem<C>[];
|
||||||
|
@ -504,7 +504,7 @@ export function select<C = unknown>(props: {
|
||||||
export function select<C = unknown>(props: {
|
export function select<C = unknown>(props: {
|
||||||
title?: string;
|
title?: string;
|
||||||
text?: string;
|
text?: string;
|
||||||
default?: string | null;
|
default?: C | null;
|
||||||
items: (SelectItem<C> | {
|
items: (SelectItem<C> | {
|
||||||
sectionTitle: string;
|
sectionTitle: string;
|
||||||
items: SelectItem<C>[];
|
items: SelectItem<C>[];
|
||||||
|
|
Loading…
Reference in New Issue