UNPKG

@kitten-science/kitten-scientists

Version:

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

38 lines 1.55 kB
import type { Setting } from "../../settings/Settings.js"; import type { Cycle } from "../../types/index.js"; import { SettingsList, type SettingsListOptions } from "./SettingsList.js"; import type { UiComponent } from "./UiComponent.js"; export type SettingWithCycles = Record<Cycle, Setting>; export type CyclesListOptions = ThisType<CyclesList> & SettingsListOptions & { /** * Called when a cycle is checked. * * @param label The label on the cycle element. * @param setting The setting associated with the cycle. */ readonly onCheckCycle?: (label: string, setting: Setting, isBatchProcess?: boolean) => void; /** * Called when a cycle is unchecked. * * @param label The label on the cycle element. * @param setting The setting associated with the cycle. */ readonly onUnCheckCycle?: (label: string, setting: Setting, isBatchProcess?: boolean) => void; }; /** * A list of settings correlating to the planetary cycles in the game. */ export declare class CyclesList extends SettingsList { readonly options: CyclesListOptions; readonly setting: SettingWithCycles; /** * Constructs a `SeasonsList`. * * @param host A reference to the host. * @param setting The settings that correlate to this list. * @param behavior Control cycle check box log output * @param options Options for this list. */ constructor(parent: UiComponent, setting: SettingWithCycles, options?: CyclesListOptions); } //# sourceMappingURL=CyclesList.d.ts.map