UNPKG

@kitten-science/kitten-scientists

Version:

Add-on for the wonderful incremental browser game: https://kittensgame.com/web/

26 lines 1.21 kB
import type { SettingOptions } from "../../settings/Settings.js"; import { Fieldset } from "./Fieldset.js"; import { RadioItem } from "./RadioItem.js"; import { UiComponent, type UiComponentOptions } from "./UiComponent.js"; export type OptionsListItemOptions = ThisType<OptionsListItem> & UiComponentOptions & { readonly onCheck?: (isBatchProcess?: boolean) => void; readonly readOnly?: boolean; }; export declare class OptionsListItem<TSetting extends SettingOptions = SettingOptions> extends UiComponent { readonly options: OptionsListItemOptions; readonly fieldset: Fieldset; readonly setting: TSetting; readonly _items: Array<RadioItem>; /** * Construct a new options setting element. * This is a list of options, where the selected option will be put into the setting. * * @param host The userscript instance. * @param label The label on the setting element. * @param setting The setting this element is linked to. * @param options Options for the list item. */ constructor(parent: UiComponent, label: string, setting: TSetting, options?: OptionsListItemOptions); toString(): string; } //# sourceMappingURL=OptionsListItem.d.ts.map