/*!
Copyright (C) 2025 HighLite
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see .
*/
export declare enum SettingsTypes {
checkbox = 0,
range = 1,
color = 2,
text = 3,
button = 4,
combobox = 5,
textarea = 6,
alert = 7,
warning = 8,
info = 9
}
interface BaseSettings {
text: string;
description?: string;
type: SettingsTypes;
value: T;
callback: Function;
validation?: (value: T) => boolean;
hidden?: boolean;
disabled?: boolean;
onLoaded?: Function;
}
interface RangeSettings extends BaseSettings {
type: SettingsTypes.range;
min: number;
max: number;
}
interface ComboBoxSettings extends BaseSettings {
type: SettingsTypes.combobox;
options: string[];
}
interface CheckboxSettings extends BaseSettings {
type: SettingsTypes.checkbox;
}
interface ButtonSettings extends BaseSettings {
type: SettingsTypes.button;
}
interface TextSettings extends BaseSettings {
type: SettingsTypes.text;
}
interface ColorSettings extends BaseSettings {
type: SettingsTypes.color;
}
interface TextAreaSettings extends BaseSettings {
type: SettingsTypes.textarea;
}
interface AlertSettings extends BaseSettings {
type: SettingsTypes.alert;
}
interface WarningSettings extends BaseSettings {
type: SettingsTypes.warning;
}
interface InfoSettings extends BaseSettings {
type: SettingsTypes.info;
}
export type PluginSettings = RangeSettings | ComboBoxSettings | CheckboxSettings | ButtonSettings | TextSettings | ColorSettings | TextAreaSettings | AlertSettings | WarningSettings | InfoSettings;
export {};