UNPKG

@cn-ui/core

Version:

The @cn-ui/core is a collection of UI components and utilities for building modern web applications with SolidJS.

86 lines (85 loc) 4.33 kB
import type { SelectOptionsType } from "@cn-ui/reactive"; export declare const SelectCtx: { use<D = { multi: import("solid-js").Accessor<boolean>; options: import("solid-js").Accessor<SelectOptionsType[]>; optionsIdMap: import("@cn-ui/reactive").ComputedAtom<Map<string, SelectOptionsType>>; selected: () => SelectOptionsType[]; getId: (item: SelectOptionsType) => any; selectedMap: import("@cn-ui/reactive").Atom<Map<string, SelectOptionsType>>; toggle: (item: SelectOptionsType, state?: boolean) => boolean; select: (item: SelectOptionsType) => boolean; unselect: (item: SelectOptionsType) => boolean; toggleById: (id: string, state?: boolean) => boolean; selectById: (item: string) => boolean; unselectById: (item: string) => boolean; clearAll(): void; selectAll(): void; isAllSelected(): boolean; isNoneSelected(): boolean; isIndeterminate(): boolean; isSelected: (item: SelectOptionsType) => boolean; isSelectedById: (id: string) => boolean; disabledMap: import("@cn-ui/reactive").Atom<Map<string, SelectOptionsType>>; isDisabled(item: SelectOptionsType): boolean; isDisabledById(id: string): boolean; disable: (item: SelectOptionsType) => void; disableById: (id: string) => void; syncIdArrayModel(model: import("@cn-ui/reactive").Atom<string[]>): void; }>(): D; id: symbol; Provider: import("solid-js").ContextProviderComponent<{ multi: import("solid-js").Accessor<boolean>; options: import("solid-js").Accessor<SelectOptionsType[]>; optionsIdMap: import("@cn-ui/reactive").ComputedAtom<Map<string, SelectOptionsType>>; selected: () => SelectOptionsType[]; getId: (item: SelectOptionsType) => any; selectedMap: import("@cn-ui/reactive").Atom<Map<string, SelectOptionsType>>; toggle: (item: SelectOptionsType, state?: boolean) => boolean; select: (item: SelectOptionsType) => boolean; unselect: (item: SelectOptionsType) => boolean; toggleById: (id: string, state?: boolean) => boolean; selectById: (item: string) => boolean; unselectById: (item: string) => boolean; clearAll(): void; selectAll(): void; isAllSelected(): boolean; isNoneSelected(): boolean; isIndeterminate(): boolean; isSelected: (item: SelectOptionsType) => boolean; isSelectedById: (id: string) => boolean; disabledMap: import("@cn-ui/reactive").Atom<Map<string, SelectOptionsType>>; isDisabled(item: SelectOptionsType): boolean; isDisabledById(id: string): boolean; disable: (item: SelectOptionsType) => void; disableById: (id: string) => void; syncIdArrayModel(model: import("@cn-ui/reactive").Atom<string[]>): void; } | undefined>; defaultValue: { multi: import("solid-js").Accessor<boolean>; options: import("solid-js").Accessor<SelectOptionsType[]>; optionsIdMap: import("@cn-ui/reactive").ComputedAtom<Map<string, SelectOptionsType>>; selected: () => SelectOptionsType[]; getId: (item: SelectOptionsType) => any; selectedMap: import("@cn-ui/reactive").Atom<Map<string, SelectOptionsType>>; toggle: (item: SelectOptionsType, state?: boolean) => boolean; select: (item: SelectOptionsType) => boolean; unselect: (item: SelectOptionsType) => boolean; toggleById: (id: string, state?: boolean) => boolean; selectById: (item: string) => boolean; unselectById: (item: string) => boolean; clearAll(): void; selectAll(): void; isAllSelected(): boolean; isNoneSelected(): boolean; isIndeterminate(): boolean; isSelected: (item: SelectOptionsType) => boolean; isSelectedById: (id: string) => boolean; disabledMap: import("@cn-ui/reactive").Atom<Map<string, SelectOptionsType>>; isDisabled(item: SelectOptionsType): boolean; isDisabledById(id: string): boolean; disable: (item: SelectOptionsType) => void; disableById: (id: string) => void; syncIdArrayModel(model: import("@cn-ui/reactive").Atom<string[]>): void; } | undefined; };