@agnos-ui/svelte-bootstrap 0.10.0 → 0.11.0-next.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.
- package/components/accordion/Accordion.svelte +3 -1
- package/components/accordion/ItemDefaultStructure.svelte +2 -1
- package/components/accordion/accordion.gen.d.ts +18 -8
- package/components/alert/AlertDefaultStructure.svelte +1 -1
- package/components/alert/alert.gen.d.ts +2 -2
- package/components/carousel/Carousel.svelte +3 -1
- package/components/carousel/CarouselDefaultStructure.svelte +2 -1
- package/components/carousel/carousel.gen.d.ts +1 -1
- package/components/collapse/collapse.gen.d.ts +3 -3
- package/components/drawer/DrawerDefaultStructure.svelte +2 -3
- package/components/drawer/drawer.gen.d.ts +2 -2
- package/components/modal/modal.gen.d.ts +1 -1
- package/components/pagination/PaginationDefaultPages.svelte +2 -1
- package/components/pagination/PaginationDefaultStructure.svelte +2 -1
- package/components/progressbar/Progressbar.svelte +3 -1
- package/components/slider/SliderDefaultStructure.svelte +2 -1
- package/components/toast/ToastDefaultStructure.svelte +1 -1
- package/components/toast/toast.gen.d.ts +2 -2
- package/components/tree/Tree.svelte +3 -1
- package/components/tree/TreeDefaultStructure.svelte +2 -1
- package/config.gen.d.ts +0 -5
- package/index.d.ts +0 -1
- package/index.js +0 -1
- package/package.json +3 -3
- package/components/select/Select.svelte +0 -71
- package/components/select/Select.svelte.d.ts +0 -29
- package/components/select/index.d.ts +0 -3
- package/components/select/index.js +0 -3
- package/components/select/select.gen.d.ts +0 -435
- package/components/select/select.gen.js +0 -14
|
@@ -10,7 +10,9 @@ import {BROWSER as __AgnosUISveltePreprocess__BROWSER} from 'esm-env';
|
|
|
10
10
|
let {children, ...props}: Partial<AccordionProps> & {children: Snippet} = $props();
|
|
11
11
|
|
|
12
12
|
const {directives, api: accordionApi} = callWidgetFactory(createAccordion, {
|
|
13
|
-
props
|
|
13
|
+
get props() {
|
|
14
|
+
return props;
|
|
15
|
+
},
|
|
14
16
|
});
|
|
15
17
|
export const api: AccordionApi = accordionApi;
|
|
16
18
|
|
|
@@ -6,7 +6,8 @@ import {BROWSER as __AgnosUISveltePreprocess__BROWSER} from 'esm-env';
|
|
|
6
6
|
import {Slot} from '@agnos-ui/svelte-headless/slot';
|
|
7
7
|
|
|
8
8
|
let widget: AccordionItemContext = $props();
|
|
9
|
-
|
|
9
|
+
let state = $derived(widget.state);
|
|
10
|
+
let directives = $derived(widget.directives);
|
|
10
11
|
|
|
11
12
|
let headingTag = $derived(`h${state.headingLevel}`);
|
|
12
13
|
</script>
|
|
@@ -345,30 +345,37 @@ export interface AccordionApi {
|
|
|
345
345
|
* Given the itemId, will expand the corresponding accordion-item.
|
|
346
346
|
*
|
|
347
347
|
* If the itemId is not valid, nothing will happen.
|
|
348
|
+
* @returns A promise that resolves when the expand operation is completed.
|
|
348
349
|
*/
|
|
349
|
-
expand(itemId: string): void
|
|
350
|
+
expand(itemId: string): Promise<void>;
|
|
350
351
|
/**
|
|
351
352
|
* Given the itemId, will collapse the corresponding accordion-item.
|
|
352
353
|
*
|
|
353
354
|
* If the itemId is not valid, nothing will happen.
|
|
355
|
+
* @returns A promise that resolves when the collapse operation is completed.
|
|
354
356
|
*/
|
|
355
|
-
collapse(itemId: string): void
|
|
357
|
+
collapse(itemId: string): Promise<void>;
|
|
356
358
|
/**
|
|
357
359
|
* Given the itemId, will toggle the corresponding accordion-item.
|
|
358
360
|
*
|
|
361
|
+
* @returns A promise that resolves when the toggle operation is completed.
|
|
359
362
|
* If the itemId is not valid, nothing will happen.
|
|
360
363
|
*/
|
|
361
|
-
toggle(itemId: string): void
|
|
364
|
+
toggle(itemId: string): Promise<void>;
|
|
362
365
|
/**
|
|
363
366
|
* It will expand all the items in the accordion.
|
|
364
367
|
*
|
|
365
368
|
* If `closeOthers` is `true` it will expand only the last accordion-item.
|
|
369
|
+
*
|
|
370
|
+
* @returns A promise that resolves when all the expand operations are completed.
|
|
366
371
|
*/
|
|
367
|
-
expandAll(): void
|
|
372
|
+
expandAll(): Promise<void>;
|
|
368
373
|
/**
|
|
369
374
|
* It will collapse all the accordion-items in the accordion.
|
|
375
|
+
*
|
|
376
|
+
* @returns A promise that resolves when all the collapse operations are completed.
|
|
370
377
|
*/
|
|
371
|
-
collapseAll(): void
|
|
378
|
+
collapseAll(): Promise<void>;
|
|
372
379
|
/**
|
|
373
380
|
* Creates a new accordionItem.
|
|
374
381
|
*/
|
|
@@ -389,16 +396,19 @@ export interface AccordionDirectives {
|
|
|
389
396
|
export interface AccordionItemApi {
|
|
390
397
|
/**
|
|
391
398
|
* It will collapse the accordion-item.
|
|
399
|
+
* @returns A promise that resolves when the collapse operation is completed.
|
|
392
400
|
*/
|
|
393
|
-
collapse(): void
|
|
401
|
+
collapse(): Promise<void>;
|
|
394
402
|
/**
|
|
395
403
|
* It will expand the accordion-item.
|
|
404
|
+
* @returns A promise that resolves when the expand operation is completed.
|
|
396
405
|
*/
|
|
397
|
-
expand(): void
|
|
406
|
+
expand(): Promise<void>;
|
|
398
407
|
/**
|
|
399
408
|
* It will toggle the accordion-item.
|
|
409
|
+
* @returns A promise that resolves when the toggle operation is completed.
|
|
400
410
|
*/
|
|
401
|
-
toggle(): void
|
|
411
|
+
toggle(): Promise<void>;
|
|
402
412
|
/**
|
|
403
413
|
* Method to be called after the initialization to allow animations.
|
|
404
414
|
*/
|
|
@@ -175,11 +175,11 @@ export interface AlertApi {
|
|
|
175
175
|
/**
|
|
176
176
|
* Triggers alert closing programmatically (same as clicking on the close button (×)).
|
|
177
177
|
*/
|
|
178
|
-
close(): void
|
|
178
|
+
close(): Promise<void>;
|
|
179
179
|
/**
|
|
180
180
|
* Triggers the alert to be displayed for the user.
|
|
181
181
|
*/
|
|
182
|
-
open(): void
|
|
182
|
+
open(): Promise<void>;
|
|
183
183
|
}
|
|
184
184
|
/**
|
|
185
185
|
* Represents the directives for an alert component.
|
|
@@ -12,7 +12,9 @@ import {BROWSER as __AgnosUISveltePreprocess__BROWSER} from 'esm-env';
|
|
|
12
12
|
let props: Partial<CarouselProps<SlideData>> = $props();
|
|
13
13
|
|
|
14
14
|
const widget = callWidgetFactory(createCarousel<SlideData>, {
|
|
15
|
-
props
|
|
15
|
+
get props() {
|
|
16
|
+
return props;
|
|
17
|
+
},
|
|
16
18
|
defaultConfig: {
|
|
17
19
|
structure,
|
|
18
20
|
navigation,
|
|
@@ -6,7 +6,8 @@ import {BROWSER as __AgnosUISveltePreprocess__BROWSER} from 'esm-env';
|
|
|
6
6
|
import {Slot} from '@agnos-ui/svelte-headless/slot';
|
|
7
7
|
|
|
8
8
|
let widget: CarouselContext<SlideData> = $props();
|
|
9
|
-
let
|
|
9
|
+
let state = $derived(widget.state);
|
|
10
|
+
let directives = $derived(widget.directives);
|
|
10
11
|
</script>
|
|
11
12
|
|
|
12
13
|
<Slot content={state.navigation} props={widget} />
|
|
@@ -334,7 +334,7 @@ declare const export_createCarousel: WidgetFactory<CarouselWidget<{
|
|
|
334
334
|
id: string;
|
|
335
335
|
}>, <SlideData extends {
|
|
336
336
|
id: string;
|
|
337
|
-
}>(config?: PropsConfig<CarouselProps<SlideData>>) => CarouselWidget<SlideData>>;
|
|
337
|
+
}>(config?: PropsConfig<CarouselProps<SlideData>> | undefined) => CarouselWidget<SlideData>>;
|
|
338
338
|
export { export_createCarousel as createCarousel };
|
|
339
339
|
/**
|
|
340
340
|
* Represents the API for a carousel component.
|
|
@@ -112,15 +112,15 @@ export interface CollapseApi {
|
|
|
112
112
|
/**
|
|
113
113
|
* Triggers collapse closing programmatically.
|
|
114
114
|
*/
|
|
115
|
-
close(): void
|
|
115
|
+
close(): Promise<void>;
|
|
116
116
|
/**
|
|
117
117
|
* Triggers the collapse content to be displayed for the user.
|
|
118
118
|
*/
|
|
119
|
-
open(): void
|
|
119
|
+
open(): Promise<void>;
|
|
120
120
|
/**
|
|
121
121
|
* Toggles the collapse content visibility.
|
|
122
122
|
*/
|
|
123
|
-
toggle(): void
|
|
123
|
+
toggle(): Promise<void>;
|
|
124
124
|
}
|
|
125
125
|
/**
|
|
126
126
|
* Interface representing the directives used in a collapse component.
|
|
@@ -3,14 +3,13 @@
|
|
|
3
3
|
import type {DrawerContext} from './drawer.gen';
|
|
4
4
|
|
|
5
5
|
let widget: DrawerContext = $props();
|
|
6
|
-
let {state} = widget;
|
|
7
6
|
</script>
|
|
8
7
|
|
|
9
8
|
<div class="au-drawer-content">
|
|
10
9
|
<div class="au-drawer-header">
|
|
11
|
-
<Slot content={state.header} props={widget} />
|
|
10
|
+
<Slot content={widget.state.header} props={widget} />
|
|
12
11
|
</div>
|
|
13
12
|
<div class="au-drawer-body">
|
|
14
|
-
<Slot content={state.children} props={widget} />
|
|
13
|
+
<Slot content={widget.state.children} props={widget} />
|
|
15
14
|
</div>
|
|
16
15
|
</div>
|
|
@@ -320,9 +320,9 @@ export interface DrawerApi {
|
|
|
320
320
|
/**
|
|
321
321
|
* Trigger the opening of the drawer.
|
|
322
322
|
*/
|
|
323
|
-
open: () => void
|
|
323
|
+
open: () => Promise<void>;
|
|
324
324
|
/**
|
|
325
325
|
* Trigger the closing of the drawer.
|
|
326
326
|
*/
|
|
327
|
-
close: () => void
|
|
327
|
+
close: () => Promise<void>;
|
|
328
328
|
}
|
|
@@ -295,7 +295,7 @@ export type ModalWidget<Data> = Widget<ModalProps<Data>, ModalState<Data>, Modal
|
|
|
295
295
|
* @param config - config of the modal, either as a store or as an object containing values or stores.
|
|
296
296
|
* @returns a new modal widget instance
|
|
297
297
|
*/
|
|
298
|
-
declare const export_createModal: <Data>(config?: PropsConfig<ModalProps<Data>>) => ModalWidget<Data>;
|
|
298
|
+
declare const export_createModal: <Data>(config?: PropsConfig<ModalProps<Data>> | undefined) => ModalWidget<Data>;
|
|
299
299
|
export { export_createModal as createModal };
|
|
300
300
|
/**
|
|
301
301
|
* Value present in the {@link ModalBeforeCloseEvent.result|result} property of the {@link ModalProps.onBeforeClose|onBeforeClose} event
|
|
@@ -6,7 +6,8 @@ import {BROWSER as __AgnosUISveltePreprocess__BROWSER} from 'esm-env';
|
|
|
6
6
|
import {Slot} from '@agnos-ui/svelte-headless/slot';
|
|
7
7
|
|
|
8
8
|
let widget: PaginationContext = $props();
|
|
9
|
-
let
|
|
9
|
+
let state = $derived(widget.state);
|
|
10
|
+
let directives = $derived(widget.directives);
|
|
10
11
|
</script>
|
|
11
12
|
|
|
12
13
|
{#each state.pages as page}
|
|
@@ -6,7 +6,8 @@ import {BROWSER as __AgnosUISveltePreprocess__BROWSER} from 'esm-env';
|
|
|
6
6
|
import {Slot} from '@agnos-ui/svelte-headless/slot';
|
|
7
7
|
|
|
8
8
|
let widget: PaginationContext = $props();
|
|
9
|
-
let
|
|
9
|
+
let state = $derived(widget.state);
|
|
10
|
+
let directives = $derived(widget.directives);
|
|
10
11
|
|
|
11
12
|
let sizeClass = $derived(state.size ? `pagination-${state.size}` : '');
|
|
12
13
|
</script>
|
|
@@ -10,7 +10,9 @@ import {BROWSER as __AgnosUISveltePreprocess__BROWSER} from 'esm-env';
|
|
|
10
10
|
let props: Partial<ProgressbarProps> = $props();
|
|
11
11
|
|
|
12
12
|
const widget = callWidgetFactory(createProgressbar, {
|
|
13
|
-
props
|
|
13
|
+
get props() {
|
|
14
|
+
return props;
|
|
15
|
+
},
|
|
14
16
|
defaultConfig: {
|
|
15
17
|
structure,
|
|
16
18
|
},
|
|
@@ -6,7 +6,8 @@ import {BROWSER as __AgnosUISveltePreprocess__BROWSER} from 'esm-env';
|
|
|
6
6
|
import {Slot} from '@agnos-ui/svelte-headless/slot';
|
|
7
7
|
|
|
8
8
|
let widget: SliderContext = $props();
|
|
9
|
-
let
|
|
9
|
+
let state = $derived(widget.state);
|
|
10
|
+
let directives = $derived(widget.directives);
|
|
10
11
|
</script>
|
|
11
12
|
|
|
12
13
|
{#each state.progressDisplayOptions as option (option.id)}
|
|
@@ -6,7 +6,7 @@ import {BROWSER as __AgnosUISveltePreprocess__BROWSER} from 'esm-env';
|
|
|
6
6
|
import {Slot} from '@agnos-ui/svelte-headless/slot';
|
|
7
7
|
|
|
8
8
|
let widget: ToastContext = $props();
|
|
9
|
-
let state = widget.state;
|
|
9
|
+
let state = $derived(widget.state);
|
|
10
10
|
</script>
|
|
11
11
|
|
|
12
12
|
{#if state.header}
|
|
@@ -210,11 +210,11 @@ export interface ToastApi {
|
|
|
210
210
|
/**
|
|
211
211
|
* Triggers alert closing programmatically (same as clicking on the close button (×)).
|
|
212
212
|
*/
|
|
213
|
-
close(): void
|
|
213
|
+
close(): Promise<void>;
|
|
214
214
|
/**
|
|
215
215
|
* Triggers the alert to be displayed for the user.
|
|
216
216
|
*/
|
|
217
|
-
open(): void
|
|
217
|
+
open(): Promise<void>;
|
|
218
218
|
}
|
|
219
219
|
/**
|
|
220
220
|
* Interface representing the directives for a toast component.
|
|
@@ -6,7 +6,8 @@ import {BROWSER as __AgnosUISveltePreprocess__BROWSER} from 'esm-env';
|
|
|
6
6
|
import type {TreeContext} from './tree.gen';
|
|
7
7
|
|
|
8
8
|
let widget: TreeContext = $props();
|
|
9
|
-
let
|
|
9
|
+
let state = $derived(widget.state);
|
|
10
|
+
let directives = $derived(widget.directives);
|
|
10
11
|
</script>
|
|
11
12
|
|
|
12
13
|
<ul role="tree" use:__AgnosUISveltePreprocess__classDirective={"au-tree "+(state.className)} use:directives.navigationDirective {...__AgnosUISveltePreprocess__BROWSER ? {} : __AgnosUISveltePreprocess__ssrAttributes(directives.navigationDirective, [__AgnosUISveltePreprocess__classDirective, "au-tree "+(state.className)])}>
|
package/config.gen.d.ts
CHANGED
|
@@ -7,7 +7,6 @@ import type { ModalProps } from './components/modal';
|
|
|
7
7
|
import type { PaginationProps } from './components/pagination';
|
|
8
8
|
import type { ProgressbarProps } from './components/progressbar';
|
|
9
9
|
import type { RatingProps } from './components/rating';
|
|
10
|
-
import type { SelectProps } from './components/select';
|
|
11
10
|
import type { SliderProps } from './components/slider';
|
|
12
11
|
import type { ToastProps } from './components/toast';
|
|
13
12
|
import type { TreeProps } from './components/tree';
|
|
@@ -48,10 +47,6 @@ export type WidgetsConfig = {
|
|
|
48
47
|
* the rating widget config
|
|
49
48
|
*/
|
|
50
49
|
rating: RatingProps;
|
|
51
|
-
/**
|
|
52
|
-
* the select widget config
|
|
53
|
-
*/
|
|
54
|
-
select: SelectProps<any>;
|
|
55
50
|
/**
|
|
56
51
|
* the slider widget config
|
|
57
52
|
*/
|
package/index.d.ts
CHANGED
|
@@ -6,7 +6,6 @@ export * from './components/modal';
|
|
|
6
6
|
export * from './components/pagination';
|
|
7
7
|
export * from './components/progressbar';
|
|
8
8
|
export * from './components/rating';
|
|
9
|
-
export * from './components/select';
|
|
10
9
|
export * from './components/slider';
|
|
11
10
|
export * from './components/toast';
|
|
12
11
|
export * from './components/tree';
|
package/index.js
CHANGED
|
@@ -6,7 +6,6 @@ export * from './components/modal';
|
|
|
6
6
|
export * from './components/pagination';
|
|
7
7
|
export * from './components/progressbar';
|
|
8
8
|
export * from './components/rating';
|
|
9
|
-
export * from './components/select';
|
|
10
9
|
export * from './components/slider';
|
|
11
10
|
export * from './components/toast';
|
|
12
11
|
export * from './components/tree';
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agnos-ui/svelte-bootstrap",
|
|
3
3
|
"description": "Bootstrap-based component library for Svelte.",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.11.0-next.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./index.js",
|
|
7
7
|
"module": "./index.js",
|
|
@@ -49,8 +49,8 @@
|
|
|
49
49
|
}
|
|
50
50
|
},
|
|
51
51
|
"dependencies": {
|
|
52
|
-
"@agnos-ui/core-bootstrap": "0.
|
|
53
|
-
"@agnos-ui/svelte-headless": "0.
|
|
52
|
+
"@agnos-ui/core-bootstrap": "0.11.0-next.0",
|
|
53
|
+
"@agnos-ui/svelte-headless": "0.11.0-next.0"
|
|
54
54
|
},
|
|
55
55
|
"peerDependencies": {
|
|
56
56
|
"@amadeus-it-group/tansu": "^2.0.0",
|
|
@@ -1,71 +0,0 @@
|
|
|
1
|
-
<script lang="ts" generics="Item">
|
|
2
|
-
import {ssrAttributes as __AgnosUISveltePreprocess__ssrAttributes, classDirective as __AgnosUISveltePreprocess__classDirective} from '@agnos-ui/svelte-headless/utils/directive';
|
|
3
|
-
import {BROWSER as __AgnosUISveltePreprocess__BROWSER} from 'esm-env';
|
|
4
|
-
|
|
5
|
-
import {Slot} from '@agnos-ui/svelte-headless/slot';
|
|
6
|
-
import {callWidgetFactory} from '../../config';
|
|
7
|
-
import type {SelectApi, SelectItemContext, SelectProps, SelectWidget} from './select.gen';
|
|
8
|
-
import {createSelect} from './select.gen';
|
|
9
|
-
|
|
10
|
-
let {open = $bindable(false), filterText = $bindable(), selected = $bindable(), ...props}: Partial<SelectProps<Item>> = $props();
|
|
11
|
-
|
|
12
|
-
const widget = callWidgetFactory<SelectWidget<Item>>(createSelect, {
|
|
13
|
-
get props() {
|
|
14
|
-
return {...props, open, filterText, selected};
|
|
15
|
-
},
|
|
16
|
-
defaultConfig: {badgeLabel, itemLabel},
|
|
17
|
-
events: {
|
|
18
|
-
onOpenChange: function (isOpen: boolean): void {
|
|
19
|
-
open = isOpen;
|
|
20
|
-
},
|
|
21
|
-
onSelectedChange: (newSelection) => {
|
|
22
|
-
selected = newSelection;
|
|
23
|
-
},
|
|
24
|
-
onFilterTextChange: (value) => {
|
|
25
|
-
filterText = value;
|
|
26
|
-
},
|
|
27
|
-
},
|
|
28
|
-
});
|
|
29
|
-
export const api: SelectApi<Item> = widget.api;
|
|
30
|
-
const {
|
|
31
|
-
state,
|
|
32
|
-
directives: {
|
|
33
|
-
floatingDirective,
|
|
34
|
-
hasFocusDirective,
|
|
35
|
-
referenceDirective,
|
|
36
|
-
inputContainerDirective,
|
|
37
|
-
badgeAttributesDirective,
|
|
38
|
-
menuAttributesDirective,
|
|
39
|
-
itemAttributesDirective,
|
|
40
|
-
inputDirective,
|
|
41
|
-
},
|
|
42
|
-
} = widget;
|
|
43
|
-
</script>
|
|
44
|
-
|
|
45
|
-
{#snippet badgeLabel({itemContext}: SelectItemContext<Item>)}
|
|
46
|
-
{itemContext.item}
|
|
47
|
-
{/snippet}
|
|
48
|
-
{#snippet itemLabel({itemContext}: SelectItemContext<Item>)}
|
|
49
|
-
{itemContext.item}
|
|
50
|
-
{/snippet}
|
|
51
|
-
|
|
52
|
-
<div use:referenceDirective use:__AgnosUISveltePreprocess__classDirective={"au-select dropdown border border-1 p-1 mb-3 d-block "+(state.className)} {...__AgnosUISveltePreprocess__BROWSER ? {} : __AgnosUISveltePreprocess__ssrAttributes(referenceDirective, [__AgnosUISveltePreprocess__classDirective, "au-select dropdown border border-1 p-1 mb-3 d-block "+(state.className)])}>
|
|
53
|
-
<div use:hasFocusDirective use:inputContainerDirective use:__AgnosUISveltePreprocess__classDirective={"d-flex align-items-center flex-wrap gap-1"} {...__AgnosUISveltePreprocess__BROWSER ? {} : __AgnosUISveltePreprocess__ssrAttributes(hasFocusDirective, inputContainerDirective, [__AgnosUISveltePreprocess__classDirective, "d-flex align-items-center flex-wrap gap-1"])}>
|
|
54
|
-
{#each state.selectedContexts as itemContext (itemContext.id)}
|
|
55
|
-
<div use:badgeAttributesDirective={itemContext} {...__AgnosUISveltePreprocess__BROWSER ? {} : __AgnosUISveltePreprocess__ssrAttributes([badgeAttributesDirective, itemContext])}>
|
|
56
|
-
<Slot content={state.badgeLabel} props={{state, directives: widget.directives, api: widget.api, itemContext}} />
|
|
57
|
-
</div>
|
|
58
|
-
{/each}
|
|
59
|
-
<input value={state.filterText} use:inputDirective {...__AgnosUISveltePreprocess__BROWSER ? {} : __AgnosUISveltePreprocess__ssrAttributes(inputDirective)} />
|
|
60
|
-
</div>
|
|
61
|
-
{#if state.open && state.visibleItems.length > 0}
|
|
62
|
-
<ul use:hasFocusDirective use:floatingDirective use:menuAttributesDirective use:__AgnosUISveltePreprocess__classDirective={"dropdown-menu show"} {...__AgnosUISveltePreprocess__BROWSER ? {} : __AgnosUISveltePreprocess__ssrAttributes(hasFocusDirective, floatingDirective, menuAttributesDirective, [__AgnosUISveltePreprocess__classDirective, "dropdown-menu show"])}>
|
|
63
|
-
{#each state.visibleItems as itemContext (itemContext.id)}
|
|
64
|
-
{@const isHighlighted = itemContext === state.highlighted}
|
|
65
|
-
<li use:__AgnosUISveltePreprocess__classDirective={(['dropdown-item position-relative', {'text-bg-primary': isHighlighted}])} use:itemAttributesDirective={itemContext} {...__AgnosUISveltePreprocess__BROWSER ? {} : __AgnosUISveltePreprocess__ssrAttributes([itemAttributesDirective, itemContext], [__AgnosUISveltePreprocess__classDirective, (['dropdown-item position-relative', {'text-bg-primary': isHighlighted}])])}>
|
|
66
|
-
<Slot content={state.itemLabel} props={{state, directives: widget.directives, api: widget.api, itemContext}} />
|
|
67
|
-
</li>
|
|
68
|
-
{/each}
|
|
69
|
-
</ul>
|
|
70
|
-
{/if}
|
|
71
|
-
</div>
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import type { SelectApi, SelectProps } from './select.gen';
|
|
2
|
-
declare function $$render<Item>(): {
|
|
3
|
-
props: Partial<SelectProps<Item>>;
|
|
4
|
-
exports: {
|
|
5
|
-
api: SelectApi<Item>;
|
|
6
|
-
};
|
|
7
|
-
bindings: "open" | "selected" | "filterText";
|
|
8
|
-
slots: {};
|
|
9
|
-
events: {};
|
|
10
|
-
};
|
|
11
|
-
declare class __sveltets_Render<Item> {
|
|
12
|
-
props(): ReturnType<typeof $$render<Item>>['props'];
|
|
13
|
-
events(): ReturnType<typeof $$render<Item>>['events'];
|
|
14
|
-
slots(): ReturnType<typeof $$render<Item>>['slots'];
|
|
15
|
-
bindings(): "open" | "selected" | "filterText";
|
|
16
|
-
exports(): {
|
|
17
|
-
api: SelectApi<Item>;
|
|
18
|
-
};
|
|
19
|
-
}
|
|
20
|
-
interface $$IsomorphicComponent {
|
|
21
|
-
new <Item>(options: import('svelte').ComponentConstructorOptions<ReturnType<__sveltets_Render<Item>['props']>>): import('svelte').SvelteComponent<ReturnType<__sveltets_Render<Item>['props']>, ReturnType<__sveltets_Render<Item>['events']>, ReturnType<__sveltets_Render<Item>['slots']>> & {
|
|
22
|
-
$$bindings?: ReturnType<__sveltets_Render<Item>['bindings']>;
|
|
23
|
-
} & ReturnType<__sveltets_Render<Item>['exports']>;
|
|
24
|
-
<Item>(internal: unknown, props: ReturnType<__sveltets_Render<Item>['props']> & {}): ReturnType<__sveltets_Render<Item>['exports']>;
|
|
25
|
-
z_$$bindings?: ReturnType<__sveltets_Render<any>['bindings']>;
|
|
26
|
-
}
|
|
27
|
-
declare const Select: $$IsomorphicComponent;
|
|
28
|
-
type Select<Item> = InstanceType<typeof Select<Item>>;
|
|
29
|
-
export default Select;
|
|
@@ -1,435 +0,0 @@
|
|
|
1
|
-
import type { WidgetSlotContext, SlotContent, Widget, PropsConfig, Directive } from '@agnos-ui/svelte-headless/types';
|
|
2
|
-
import type { Placement } from '@floating-ui/dom';
|
|
3
|
-
import type { HasFocus } from '@agnos-ui/svelte-headless/services/focustrack';
|
|
4
|
-
import type { FloatingUI } from '@agnos-ui/svelte-headless/services/floatingUI';
|
|
5
|
-
/**
|
|
6
|
-
* Retrieve a shallow copy of the default Select config
|
|
7
|
-
* @returns the default Select config
|
|
8
|
-
*/
|
|
9
|
-
declare const export_getSelectDefaultConfig: () => SelectProps<any>;
|
|
10
|
-
export { export_getSelectDefaultConfig as getSelectDefaultConfig };
|
|
11
|
-
/**
|
|
12
|
-
* Interface for the slot context of the pagination widget
|
|
13
|
-
* @template Item - The type of the items in the Select component.
|
|
14
|
-
*/
|
|
15
|
-
export interface SelectContext<Item> extends WidgetSlotContext<SelectWidget<Item>> {
|
|
16
|
-
}
|
|
17
|
-
/**
|
|
18
|
-
* Represents the context for a select item, extending the base `SelectContext` with additional
|
|
19
|
-
* contextual data specific to an item.
|
|
20
|
-
*
|
|
21
|
-
* @template Item - The type of the item within the select context.
|
|
22
|
-
*/
|
|
23
|
-
export interface SelectItemContext<Item> extends SelectContext<Item> {
|
|
24
|
-
/**
|
|
25
|
-
* Contextual data related to an item
|
|
26
|
-
*/
|
|
27
|
-
itemContext: ItemContext<Item>;
|
|
28
|
-
}
|
|
29
|
-
/**
|
|
30
|
-
* Represents the state of a Select component.
|
|
31
|
-
*
|
|
32
|
-
* @template Item - The type of the items in the select component.
|
|
33
|
-
*/
|
|
34
|
-
export interface SelectState<Item> {
|
|
35
|
-
/**
|
|
36
|
-
* List of item contexts, to be displayed in the menu
|
|
37
|
-
*/
|
|
38
|
-
visibleItems: ItemContext<Item>[];
|
|
39
|
-
/**
|
|
40
|
-
* List of selected items to be display
|
|
41
|
-
*/
|
|
42
|
-
selectedContexts: ItemContext<Item>[];
|
|
43
|
-
/**
|
|
44
|
-
* Highlighted item context.
|
|
45
|
-
* It is designed to define the highlighted item in the dropdown menu
|
|
46
|
-
*/
|
|
47
|
-
highlighted: ItemContext<Item> | undefined;
|
|
48
|
-
/**
|
|
49
|
-
* Current placement of the dropdown
|
|
50
|
-
*/
|
|
51
|
-
placement: Placement | undefined;
|
|
52
|
-
/**
|
|
53
|
-
* id used for the input inside the select
|
|
54
|
-
*/
|
|
55
|
-
id: string | undefined;
|
|
56
|
-
/**
|
|
57
|
-
* aria-label used for the input inside the select
|
|
58
|
-
*
|
|
59
|
-
* @defaultValue `'Select'`
|
|
60
|
-
*/
|
|
61
|
-
ariaLabel: string | undefined;
|
|
62
|
-
/**
|
|
63
|
-
* List of selected item ids
|
|
64
|
-
*
|
|
65
|
-
* @defaultValue `[]`
|
|
66
|
-
*/
|
|
67
|
-
selected: Item[];
|
|
68
|
-
/**
|
|
69
|
-
* Filtered text to be display in the filter input
|
|
70
|
-
*
|
|
71
|
-
* @defaultValue `''`
|
|
72
|
-
*/
|
|
73
|
-
filterText: string;
|
|
74
|
-
/**
|
|
75
|
-
* true if the select is disabled
|
|
76
|
-
*
|
|
77
|
-
* @defaultValue `false`
|
|
78
|
-
*/
|
|
79
|
-
disabled: boolean;
|
|
80
|
-
/**
|
|
81
|
-
* true if the select is open
|
|
82
|
-
*
|
|
83
|
-
* @defaultValue `false`
|
|
84
|
-
*/
|
|
85
|
-
open: boolean;
|
|
86
|
-
/**
|
|
87
|
-
* Class to be added on the dropdown menu container
|
|
88
|
-
*
|
|
89
|
-
* @defaultValue `''`
|
|
90
|
-
*/
|
|
91
|
-
menuClassName: string;
|
|
92
|
-
/**
|
|
93
|
-
* Class to be added on menu items
|
|
94
|
-
*
|
|
95
|
-
* @defaultValue `''`
|
|
96
|
-
*/
|
|
97
|
-
menuItemClassName: string;
|
|
98
|
-
/**
|
|
99
|
-
* Class to be added on selected items (displayed in the input zone)
|
|
100
|
-
*
|
|
101
|
-
* @defaultValue `''`
|
|
102
|
-
*/
|
|
103
|
-
badgeClassName: string;
|
|
104
|
-
/**
|
|
105
|
-
* true if a loading process is being done
|
|
106
|
-
*
|
|
107
|
-
* @defaultValue `false`
|
|
108
|
-
*/
|
|
109
|
-
loading: boolean;
|
|
110
|
-
/**
|
|
111
|
-
* CSS classes to be applied on the widget main container
|
|
112
|
-
*
|
|
113
|
-
* @defaultValue `''`
|
|
114
|
-
*/
|
|
115
|
-
className: string;
|
|
116
|
-
/**
|
|
117
|
-
* The template to override the way each badge on the left of the input is displayed.
|
|
118
|
-
* This define the content of the badge inside the badge container.
|
|
119
|
-
*
|
|
120
|
-
* @defaultValue
|
|
121
|
-
* ```ts
|
|
122
|
-
* ({itemContext}: SelectItemContext<any>) => itemContext.item
|
|
123
|
-
* ```
|
|
124
|
-
*/
|
|
125
|
-
badgeLabel: SlotContent<SelectItemContext<Item>>;
|
|
126
|
-
/**
|
|
127
|
-
* The template to override the way each item is displayed in the list.
|
|
128
|
-
* This define the content of the badge inside the badge container.
|
|
129
|
-
*
|
|
130
|
-
* @defaultValue
|
|
131
|
-
* ```ts
|
|
132
|
-
* ({itemContext}: SelectItemContext<any>) => itemContext.item
|
|
133
|
-
* ```
|
|
134
|
-
*/
|
|
135
|
-
itemLabel: SlotContent<SelectItemContext<Item>>;
|
|
136
|
-
}
|
|
137
|
-
/**
|
|
138
|
-
* Represents the properties for the Select component.
|
|
139
|
-
*
|
|
140
|
-
* @template Item - The type of the items in the select component.
|
|
141
|
-
*/
|
|
142
|
-
export interface SelectProps<Item> {
|
|
143
|
-
/**
|
|
144
|
-
* List of available items for the dropdown
|
|
145
|
-
*
|
|
146
|
-
* @defaultValue `[]`
|
|
147
|
-
*/
|
|
148
|
-
items: Item[];
|
|
149
|
-
/**
|
|
150
|
-
* List of allowed placements for the dropdown.
|
|
151
|
-
* This refers to the [allowedPlacements from floating UI](https://floating-ui.com/docs/autoPlacement#allowedplacements), given the different [Placement possibilities](https://floating-ui.com/docs/computePosition#placement).
|
|
152
|
-
*
|
|
153
|
-
* @defaultValue
|
|
154
|
-
* ```ts
|
|
155
|
-
* ['bottom-start', 'top-start', 'bottom-end', 'top-end']
|
|
156
|
-
* ```
|
|
157
|
-
*/
|
|
158
|
-
allowedPlacements: Placement[];
|
|
159
|
-
/**
|
|
160
|
-
* Custom function to get the id of an item
|
|
161
|
-
* By default, the item is returned
|
|
162
|
-
*
|
|
163
|
-
* @defaultValue
|
|
164
|
-
* ```ts
|
|
165
|
-
* (item: any) => '' + item
|
|
166
|
-
* ```
|
|
167
|
-
*/
|
|
168
|
-
itemIdFn(item: Item): string;
|
|
169
|
-
/**
|
|
170
|
-
* Retrieves navigable elements within an HTML element containing badges and the input.
|
|
171
|
-
*
|
|
172
|
-
* @param node - HTMLElement that contains the badges and the input
|
|
173
|
-
*
|
|
174
|
-
* @defaultValue
|
|
175
|
-
* ```ts
|
|
176
|
-
* (node: HTMLElement) => node.querySelectorAll('.au-select-badge,input')
|
|
177
|
-
* ```
|
|
178
|
-
*/
|
|
179
|
-
navSelector(node: HTMLElement): NodeListOf<HTMLSpanElement | HTMLInputElement>;
|
|
180
|
-
/**
|
|
181
|
-
* Callback called dropdown open state change
|
|
182
|
-
* @param isOpen - updated open state
|
|
183
|
-
*
|
|
184
|
-
* @defaultValue
|
|
185
|
-
* ```ts
|
|
186
|
-
* () => {}
|
|
187
|
-
* ```
|
|
188
|
-
*/
|
|
189
|
-
onOpenChange(isOpen: boolean): void;
|
|
190
|
-
/**
|
|
191
|
-
* Callback called when the text filter change
|
|
192
|
-
* @param text - Filtered text
|
|
193
|
-
*
|
|
194
|
-
* @defaultValue
|
|
195
|
-
* ```ts
|
|
196
|
-
* () => {}
|
|
197
|
-
* ```
|
|
198
|
-
*/
|
|
199
|
-
onFilterTextChange(text: string): void;
|
|
200
|
-
/**
|
|
201
|
-
* Callback called when the selection change
|
|
202
|
-
*
|
|
203
|
-
* @defaultValue
|
|
204
|
-
* ```ts
|
|
205
|
-
* () => {}
|
|
206
|
-
* ```
|
|
207
|
-
*/
|
|
208
|
-
onSelectedChange(selected: Item[]): void;
|
|
209
|
-
/**
|
|
210
|
-
* id used for the input inside the select
|
|
211
|
-
*/
|
|
212
|
-
id: string | undefined;
|
|
213
|
-
/**
|
|
214
|
-
* aria-label used for the input inside the select
|
|
215
|
-
*
|
|
216
|
-
* @defaultValue `'Select'`
|
|
217
|
-
*/
|
|
218
|
-
ariaLabel: string | undefined;
|
|
219
|
-
/**
|
|
220
|
-
* List of selected item ids
|
|
221
|
-
*
|
|
222
|
-
* @defaultValue `[]`
|
|
223
|
-
*/
|
|
224
|
-
selected: Item[];
|
|
225
|
-
/**
|
|
226
|
-
* Filtered text to be display in the filter input
|
|
227
|
-
*
|
|
228
|
-
* @defaultValue `''`
|
|
229
|
-
*/
|
|
230
|
-
filterText: string;
|
|
231
|
-
/**
|
|
232
|
-
* true if the select is disabled
|
|
233
|
-
*
|
|
234
|
-
* @defaultValue `false`
|
|
235
|
-
*/
|
|
236
|
-
disabled: boolean;
|
|
237
|
-
/**
|
|
238
|
-
* true if the select is open
|
|
239
|
-
*
|
|
240
|
-
* @defaultValue `false`
|
|
241
|
-
*/
|
|
242
|
-
open: boolean;
|
|
243
|
-
/**
|
|
244
|
-
* Class to be added on the dropdown menu container
|
|
245
|
-
*
|
|
246
|
-
* @defaultValue `''`
|
|
247
|
-
*/
|
|
248
|
-
menuClassName: string;
|
|
249
|
-
/**
|
|
250
|
-
* Class to be added on menu items
|
|
251
|
-
*
|
|
252
|
-
* @defaultValue `''`
|
|
253
|
-
*/
|
|
254
|
-
menuItemClassName: string;
|
|
255
|
-
/**
|
|
256
|
-
* Class to be added on selected items (displayed in the input zone)
|
|
257
|
-
*
|
|
258
|
-
* @defaultValue `''`
|
|
259
|
-
*/
|
|
260
|
-
badgeClassName: string;
|
|
261
|
-
/**
|
|
262
|
-
* true if a loading process is being done
|
|
263
|
-
*
|
|
264
|
-
* @defaultValue `false`
|
|
265
|
-
*/
|
|
266
|
-
loading: boolean;
|
|
267
|
-
/**
|
|
268
|
-
* CSS classes to be applied on the widget main container
|
|
269
|
-
*
|
|
270
|
-
* @defaultValue `''`
|
|
271
|
-
*/
|
|
272
|
-
className: string;
|
|
273
|
-
/**
|
|
274
|
-
* The template to override the way each badge on the left of the input is displayed.
|
|
275
|
-
* This define the content of the badge inside the badge container.
|
|
276
|
-
*
|
|
277
|
-
* @defaultValue
|
|
278
|
-
* ```ts
|
|
279
|
-
* ({itemContext}: SelectItemContext<any>) => itemContext.item
|
|
280
|
-
* ```
|
|
281
|
-
*/
|
|
282
|
-
badgeLabel: SlotContent<SelectItemContext<Item>>;
|
|
283
|
-
/**
|
|
284
|
-
* The template to override the way each item is displayed in the list.
|
|
285
|
-
* This define the content of the badge inside the badge container.
|
|
286
|
-
*
|
|
287
|
-
* @defaultValue
|
|
288
|
-
* ```ts
|
|
289
|
-
* ({itemContext}: SelectItemContext<any>) => itemContext.item
|
|
290
|
-
* ```
|
|
291
|
-
*/
|
|
292
|
-
itemLabel: SlotContent<SelectItemContext<Item>>;
|
|
293
|
-
}
|
|
294
|
-
/**
|
|
295
|
-
* Represents a Select widget component.
|
|
296
|
-
*
|
|
297
|
-
* @template Item - The type of the items that the select widget will handle.
|
|
298
|
-
*/
|
|
299
|
-
export type SelectWidget<Item> = Widget<SelectProps<Item>, SelectState<Item>, SelectApi<Item>, SelectDirectives<Item>>;
|
|
300
|
-
/**
|
|
301
|
-
* Creates a new select widget instance.
|
|
302
|
-
* @param config - config of the modal, either as a store or as an object containing values or stores.
|
|
303
|
-
* @returns a new select widget instance
|
|
304
|
-
*/
|
|
305
|
-
declare const export_createSelect: <Item>(config?: PropsConfig<SelectProps<Item>>) => SelectWidget<Item>;
|
|
306
|
-
export { export_createSelect as createSelect };
|
|
307
|
-
/**
|
|
308
|
-
* Item representation built from the items provided in parameters
|
|
309
|
-
*
|
|
310
|
-
* @template T - The type of the Select Items
|
|
311
|
-
*/
|
|
312
|
-
export interface ItemContext<T> {
|
|
313
|
-
/**
|
|
314
|
-
* Original item given in the parameters
|
|
315
|
-
*/
|
|
316
|
-
item: T;
|
|
317
|
-
/**
|
|
318
|
-
* Unique id to identify the item
|
|
319
|
-
*/
|
|
320
|
-
id: string;
|
|
321
|
-
/**
|
|
322
|
-
* Specify if the item is checked
|
|
323
|
-
*/
|
|
324
|
-
selected: boolean;
|
|
325
|
-
}
|
|
326
|
-
/**
|
|
327
|
-
* Interface representing the API for a Select component.
|
|
328
|
-
*
|
|
329
|
-
* @template Item - The type of the Select Items
|
|
330
|
-
*/
|
|
331
|
-
export interface SelectApi<Item> {
|
|
332
|
-
/**
|
|
333
|
-
* Clear all the selected items
|
|
334
|
-
*/
|
|
335
|
-
clear(): void;
|
|
336
|
-
/**
|
|
337
|
-
* Clear the filter text
|
|
338
|
-
*/
|
|
339
|
-
clearText(): void;
|
|
340
|
-
/**
|
|
341
|
-
* Highlight the given item, if there is a corresponding match among the visible list
|
|
342
|
-
*/
|
|
343
|
-
highlight(item: Item): void;
|
|
344
|
-
/**
|
|
345
|
-
* Highlight the first item among the visible list
|
|
346
|
-
*/
|
|
347
|
-
highlightFirst(): void;
|
|
348
|
-
/**
|
|
349
|
-
* Highlight the previous item among the visible list
|
|
350
|
-
* Loop to the last item if needed
|
|
351
|
-
*/
|
|
352
|
-
highlightPrevious(): void;
|
|
353
|
-
/**
|
|
354
|
-
* Highlight the next item among the visible list.
|
|
355
|
-
* Loop to the first item if needed
|
|
356
|
-
*/
|
|
357
|
-
highlightNext(): void;
|
|
358
|
-
/**
|
|
359
|
-
* Highlight the last item among the visible list
|
|
360
|
-
*/
|
|
361
|
-
highlightLast(): void;
|
|
362
|
-
/**
|
|
363
|
-
* Select the provided item.
|
|
364
|
-
* The selected list is used to
|
|
365
|
-
* @param item - the item to select
|
|
366
|
-
*/
|
|
367
|
-
select(item: Item): void;
|
|
368
|
-
/**
|
|
369
|
-
* Unselect the provided item.
|
|
370
|
-
* @param item - the item to unselect
|
|
371
|
-
*/
|
|
372
|
-
unselect(item: Item): void;
|
|
373
|
-
/**
|
|
374
|
-
* Toggle the selection of an item
|
|
375
|
-
* @param item - the item to toggle
|
|
376
|
-
* @param selected - an optional boolean to enforce the selected/unselected state instead of toggling
|
|
377
|
-
*/
|
|
378
|
-
toggleItem(item: Item, selected?: boolean): void;
|
|
379
|
-
/**
|
|
380
|
-
* open the select
|
|
381
|
-
*/
|
|
382
|
-
open(): void;
|
|
383
|
-
/**
|
|
384
|
-
* close the select
|
|
385
|
-
*/
|
|
386
|
-
close(): void;
|
|
387
|
-
/**
|
|
388
|
-
* Toggle the dropdown menu
|
|
389
|
-
* @param isOpen - If specified, set the menu in the defined state.
|
|
390
|
-
*/
|
|
391
|
-
toggle(isOpen?: boolean): void;
|
|
392
|
-
}
|
|
393
|
-
/**
|
|
394
|
-
* Interface representing the directives used in the Select component.
|
|
395
|
-
*
|
|
396
|
-
* @template Item - The type of the Select Items
|
|
397
|
-
*/
|
|
398
|
-
export interface SelectDirectives<Item> {
|
|
399
|
-
/**
|
|
400
|
-
* Directive to be used in the input group and the menu containers
|
|
401
|
-
*/
|
|
402
|
-
hasFocusDirective: HasFocus['directive'];
|
|
403
|
-
/**
|
|
404
|
-
* Directive that enables dynamic positioning of menu element
|
|
405
|
-
*/
|
|
406
|
-
floatingDirective: FloatingUI['directives']['floatingDirective'];
|
|
407
|
-
/**
|
|
408
|
-
* A directive to be applied to the input group element serves as the base for menu positioning
|
|
409
|
-
*/
|
|
410
|
-
referenceDirective: FloatingUI['directives']['referenceDirective'];
|
|
411
|
-
/**
|
|
412
|
-
* A directive to be applied to the element that contains the badges and the input
|
|
413
|
-
*/
|
|
414
|
-
inputContainerDirective: Directive;
|
|
415
|
-
/**
|
|
416
|
-
* A directive that applies all the necessary attributes to the container badges
|
|
417
|
-
*/
|
|
418
|
-
badgeAttributesDirective: Directive<ItemContext<Item>>;
|
|
419
|
-
/**
|
|
420
|
-
* A directive that applies all the necessary attributes to the dropdown menu
|
|
421
|
-
*/
|
|
422
|
-
menuAttributesDirective: Directive;
|
|
423
|
-
/**
|
|
424
|
-
* A directive that applies all the necessary attributes to the dropdown item
|
|
425
|
-
*/
|
|
426
|
-
itemAttributesDirective: Directive<ItemContext<Item>>;
|
|
427
|
-
/**
|
|
428
|
-
* A directive to be applied to the input
|
|
429
|
-
*/
|
|
430
|
-
inputDirective: Directive;
|
|
431
|
-
/**
|
|
432
|
-
* A directive to be applied to a button that closes a badge
|
|
433
|
-
*/
|
|
434
|
-
badgeCloseButtonDirective: Directive<ItemContext<Item>>;
|
|
435
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { getSelectDefaultConfig, createSelect } from '@agnos-ui/core-bootstrap/components/select';
|
|
2
|
-
/**
|
|
3
|
-
* Retrieve a shallow copy of the default Select config
|
|
4
|
-
* @returns the default Select config
|
|
5
|
-
*/
|
|
6
|
-
const export_getSelectDefaultConfig = getSelectDefaultConfig;
|
|
7
|
-
export { export_getSelectDefaultConfig as getSelectDefaultConfig };
|
|
8
|
-
/**
|
|
9
|
-
* Creates a new select widget instance.
|
|
10
|
-
* @param config - config of the modal, either as a store or as an object containing values or stores.
|
|
11
|
-
* @returns a new select widget instance
|
|
12
|
-
*/
|
|
13
|
-
const export_createSelect = createSelect;
|
|
14
|
-
export { export_createSelect as createSelect };
|