@marianmeres/stuic 2.63.0 → 2.64.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -33,6 +33,7 @@
|
|
|
33
33
|
|
|
34
34
|
export interface Props extends Record<string, any> {
|
|
35
35
|
trigger?: Snippet<[{ value: string; modal: ModalDialog }]>;
|
|
36
|
+
modal?: ModalDialog;
|
|
36
37
|
input?: HTMLInputElement;
|
|
37
38
|
value: string;
|
|
38
39
|
label?: SnippetWithId | THC;
|
|
@@ -123,6 +124,7 @@
|
|
|
123
124
|
|
|
124
125
|
let {
|
|
125
126
|
trigger,
|
|
127
|
+
modal = $bindable(),
|
|
126
128
|
input = $bindable(),
|
|
127
129
|
value = $bindable(), //
|
|
128
130
|
label = "",
|
|
@@ -181,6 +183,10 @@
|
|
|
181
183
|
}: Props = $props();
|
|
182
184
|
|
|
183
185
|
let modalDialog: ModalDialog = $state()!;
|
|
186
|
+
// Sync internal modal state to bindable prop for external access
|
|
187
|
+
$effect(() => {
|
|
188
|
+
modal = modalDialog;
|
|
189
|
+
});
|
|
184
190
|
let innerValue = $state("");
|
|
185
191
|
let isFetching = $state(false);
|
|
186
192
|
let isUnmounted = false;
|
|
@@ -17,6 +17,7 @@ export interface Props extends Record<string, any> {
|
|
|
17
17
|
value: string;
|
|
18
18
|
modal: ModalDialog;
|
|
19
19
|
}]>;
|
|
20
|
+
modal?: ModalDialog;
|
|
20
21
|
input?: HTMLInputElement;
|
|
21
22
|
value: string;
|
|
22
23
|
label?: SnippetWithId | THC;
|
|
@@ -65,6 +66,6 @@ export interface Props extends Record<string, any> {
|
|
|
65
66
|
itemIdPropName?: string;
|
|
66
67
|
onChange?: (value: string) => void;
|
|
67
68
|
}
|
|
68
|
-
declare const FieldOptions: import("svelte").Component<Props, {}, "value" | "input">;
|
|
69
|
+
declare const FieldOptions: import("svelte").Component<Props, {}, "value" | "input" | "modal">;
|
|
69
70
|
type FieldOptions = ReturnType<typeof FieldOptions>;
|
|
70
71
|
export default FieldOptions;
|