aboutsummaryrefslogtreecommitdiff
path: root/input/select.d.ts
diff options
context:
space:
mode:
Diffstat (limited to 'input/select.d.ts')
-rw-r--r--input/select.d.ts33
1 files changed, 33 insertions, 0 deletions
diff --git a/input/select.d.ts b/input/select.d.ts
new file mode 100644
index 0000000..6a568f3
--- /dev/null
+++ b/input/select.d.ts
@@ -0,0 +1,33 @@
+import { WuiInputOption } from "./option.js";
+export interface WuiKeyValue {
+ [key: string]: string;
+}
+export interface WuiKeySelectOption {
+ [key: string]: WuiInputOption;
+}
+export interface WuiInputSelectOpts {
+ label: string;
+ name: string;
+ options: WuiKeySelectOption;
+ id?: string;
+ hint?: string;
+ is_disabled?: boolean;
+ onChangeHandler?: (key: string, value: string) => void;
+}
+export declare class WuiInputSelect {
+ opts: WuiInputSelectOpts;
+ el: HTMLElement;
+ private el_label;
+ private el_input;
+ private el_hint;
+ private el_hint_toggler;
+ private value_key;
+ private value;
+ constructor(opts: WuiInputSelectOpts);
+ private generateLabel;
+ private generateInput;
+ private generateHintToggler;
+ private generateHint;
+ private onClickHintToggler;
+ private onClickInput;
+}