@agnos-ui/core 0.10.0-next.1 → 0.10.0-next.3
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/{accordion-_zen-g8l.js → accordion-47EpOD36.js} +4 -3
- package/{accordion-B5LiN1uy.cjs → accordion-nxveC0GZ.cjs} +4 -3
- package/{alert-B-jQDQcB.cjs → alert-AhaliJ17.cjs} +1 -1
- package/{alert-gGz2CDS9.js → alert-anMaigvi.js} +1 -1
- package/{collapse-BV4kD3j9.js → collapse-CrfvGo_T.js} +2 -2
- package/{collapse-gLiT080Y.cjs → collapse-Da_27YUU.cjs} +2 -2
- package/{common-D3QcdJ6S.cjs → common-B5jS-Ih_.cjs} +1 -1
- package/{common-DK0ADNTX.js → common-CCxNtFNM.js} +1 -1
- package/components/accordion/index.cjs +1 -1
- package/components/accordion/index.js +1 -1
- package/components/alert/index.cjs +1 -1
- package/components/alert/index.js +1 -1
- package/components/carousel/index.cjs +2 -2
- package/components/carousel/index.js +2 -2
- package/components/collapse/index.cjs +1 -1
- package/components/collapse/index.js +1 -1
- package/components/drawer/drawer.d.ts +32 -25
- package/components/drawer/index.cjs +1 -1
- package/components/drawer/index.js +1 -1
- package/components/modal/index.cjs +1 -1
- package/components/modal/index.js +1 -1
- package/components/pagination/index.cjs +1 -1
- package/components/pagination/index.js +1 -1
- package/components/progressbar/index.cjs +1 -1
- package/components/progressbar/index.js +1 -1
- package/components/rating/index.cjs +1 -1
- package/components/rating/index.js +1 -1
- package/components/select/index.cjs +1 -1
- package/components/select/index.js +1 -1
- package/components/slider/index.cjs +1 -1
- package/components/slider/index.js +1 -1
- package/components/toast/index.cjs +1 -1
- package/components/toast/index.js +1 -1
- package/components/tree/index.cjs +1 -1
- package/components/tree/index.js +1 -1
- package/{dom-C2gi9OCP.cjs → dom-Cm9_uROp.cjs} +76 -6
- package/{dom-Bcg9ORcA.js → dom-DD1hAVZy.js} +76 -6
- package/drawer-Caz4Uypu.js +291 -0
- package/{drawer-DP7UPojk.cjs → drawer-DOi0TqZC.cjs} +131 -91
- package/index.cjs +16 -14
- package/index.js +21 -19
- package/{modal-DiXZXYjR.cjs → modal-B_3Uxplo.cjs} +5 -5
- package/{modal-CAvQW-vo.js → modal-cKd3qUn1.js} +5 -5
- package/package.json +1 -1
- package/{pagination-DvZ2rLsz.cjs → pagination-2Vor6JPZ.cjs} +2 -2
- package/{pagination-BKbMROV6.js → pagination-DlOyP_2C.js} +2 -2
- package/{progressbar-D8zIcm9n.js → progressbar-B5g76eMV.js} +2 -2
- package/{progressbar-i9xfAxb7.cjs → progressbar-DyBRINco.cjs} +2 -2
- package/{rating-DmG4oUkr.cjs → rating-C0y1j4SC.cjs} +2 -2
- package/{rating-DEXTGWCU.js → rating-C7C4-p4B.js} +2 -2
- package/{select-MFjAnIt7.cjs → select-Dhsb9msC.cjs} +1 -1
- package/{select-Bw68Xdu5.js → select-nnl00UWY.js} +1 -1
- package/services/floatingUI.cjs +1 -1
- package/services/floatingUI.js +1 -1
- package/services/focusElement.cjs +1 -1
- package/services/focusElement.js +1 -1
- package/services/focustrack.cjs +1 -1
- package/services/focustrack.js +1 -1
- package/services/matchMedia.cjs +1 -1
- package/services/matchMedia.js +1 -1
- package/services/navManager.cjs +1 -1
- package/services/navManager.js +1 -1
- package/services/pointerdownPosition.cjs +60 -0
- package/services/pointerdownPosition.d.ts +42 -0
- package/services/pointerdownPosition.js +60 -0
- package/services/portal.cjs +1 -1
- package/services/portal.js +1 -1
- package/services/resizeObserver.cjs +40 -20
- package/services/resizeObserver.d.ts +10 -2
- package/services/resizeObserver.js +41 -21
- package/services/siblingsInert.cjs +1 -1
- package/services/siblingsInert.js +1 -1
- package/services/transitions/baseTransitions.cjs +2 -2
- package/services/transitions/baseTransitions.js +2 -2
- package/services/transitions/collapse.cjs +11 -15
- package/services/transitions/collapse.js +11 -15
- package/services/transitions/cssTransitions.cjs +1 -1
- package/services/transitions/cssTransitions.js +1 -1
- package/services/transitions/simpleClassTransition.cjs +1 -1
- package/services/transitions/simpleClassTransition.js +1 -1
- package/{slider-Cx50Eghd.js → slider-B4WrdTeE.js} +121 -170
- package/{slider-Dl4Trh32.cjs → slider-DTO58syz.cjs} +120 -169
- package/{toaster-_p1GTtHI.js → toaster-CRPErgI2.js} +3 -3
- package/{toaster-UDglac7x.cjs → toaster-CT148JSJ.cjs} +3 -3
- package/{tree-rGHtmCnS.cjs → tree-C4l2Wqny.cjs} +2 -2
- package/{tree-DV0tfPlZ.js → tree-CHpFqJPx.js} +2 -2
- package/types.cjs +2 -2
- package/types.d.ts +22 -3
- package/types.js +2 -2
- package/utils/directive.cjs +1 -1
- package/utils/directive.d.ts +2 -2
- package/utils/directive.js +1 -1
- package/utils/internal/dom.d.ts +2 -0
- package/utils/internal/ssrHTMLElement.d.ts +7 -1
- package/utils/stores.cjs +1 -1
- package/utils/stores.js +1 -1
- package/utils/writables.cjs +2 -1
- package/utils/writables.d.ts +7 -0
- package/utils/writables.js +6 -5
- package/{writables-DcGT98a7.cjs → writables-Dt68gADJ.cjs} +4 -0
- package/{writables-e0tyaQpe.js → writables-Is1bF1Vt.js} +10 -6
- package/drawer-D5SO73ew.js +0 -251
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
const tansu = require("@amadeus-it-group/tansu");
|
|
3
|
+
const services_focusElement = require("./services/focusElement.cjs");
|
|
4
|
+
const services_pointerdownPosition = require("./services/pointerdownPosition.cjs");
|
|
3
5
|
const services_portal = require("./services/portal.cjs");
|
|
4
6
|
const services_siblingsInert = require("./services/siblingsInert.cjs");
|
|
5
7
|
const services_transitions_baseTransitions = require("./services/transitions/baseTransitions.cjs");
|
|
6
|
-
const utils_directive = require("./dom-
|
|
8
|
+
const utils_directive = require("./dom-Cm9_uROp.cjs");
|
|
7
9
|
const utils_func = require("./utils/func.cjs");
|
|
8
10
|
const scrollbars = require("./scrollbars-CT87iv_6.cjs");
|
|
9
11
|
const utils_stores = require("./utils/stores.cjs");
|
|
10
12
|
const utils_widget = require("./utils/widget.cjs");
|
|
11
|
-
const utils_writables = require("./writables-
|
|
12
|
-
const services_focusElement = require("./services/focusElement.cjs");
|
|
13
|
+
const utils_writables = require("./writables-Dt68gADJ.cjs");
|
|
13
14
|
function getDrawerDefaultConfig() {
|
|
14
15
|
return {
|
|
15
16
|
...defaultDrawerConfig
|
|
@@ -28,14 +29,15 @@ const defaultDrawerConfig = {
|
|
|
28
29
|
verticalTransition: utils_func.noop,
|
|
29
30
|
onHidden: utils_func.noop,
|
|
30
31
|
onShown: utils_func.noop,
|
|
31
|
-
|
|
32
|
-
height: 200,
|
|
33
|
-
onWidthChange: utils_func.noop,
|
|
34
|
-
onHeightChange: utils_func.noop,
|
|
32
|
+
onSizeChange: utils_func.noop,
|
|
35
33
|
onVisibleChange: utils_func.noop,
|
|
34
|
+
onMinimizedChange: utils_func.noop,
|
|
35
|
+
onMaximizedChange: utils_func.noop,
|
|
36
|
+
onResizingChange: utils_func.noop,
|
|
36
37
|
resizable: false,
|
|
37
38
|
backdrop: true,
|
|
38
|
-
bodyScroll: false
|
|
39
|
+
bodyScroll: false,
|
|
40
|
+
size: null
|
|
39
41
|
};
|
|
40
42
|
const configValidator = {
|
|
41
43
|
animated: utils_writables.typeBoolean,
|
|
@@ -50,14 +52,15 @@ const configValidator = {
|
|
|
50
52
|
container: utils_writables.typeHTMLElementOrNull,
|
|
51
53
|
onHidden: utils_writables.typeFunction,
|
|
52
54
|
onShown: utils_writables.typeFunction,
|
|
53
|
-
|
|
54
|
-
height: utils_writables.typeNumberInRangeFactory(0, Infinity),
|
|
55
|
-
onWidthChange: utils_writables.typeFunction,
|
|
56
|
-
onHeightChange: utils_writables.typeFunction,
|
|
55
|
+
onSizeChange: utils_writables.typeFunction,
|
|
57
56
|
onVisibleChange: utils_writables.typeFunction,
|
|
57
|
+
onMinimizedChange: utils_writables.typeFunction,
|
|
58
|
+
onMaximizedChange: utils_writables.typeFunction,
|
|
59
|
+
onResizingChange: utils_writables.typeFunction,
|
|
58
60
|
resizable: utils_writables.typeBoolean,
|
|
59
61
|
backdrop: utils_writables.typeBoolean,
|
|
60
|
-
bodyScroll: utils_writables.typeBoolean
|
|
62
|
+
bodyScroll: utils_writables.typeBoolean,
|
|
63
|
+
size: utils_writables.typeNumberOrNull
|
|
61
64
|
};
|
|
62
65
|
const createDrawer = utils_widget.createWidgetFactory("drawer", (config) => {
|
|
63
66
|
const [
|
|
@@ -71,71 +74,69 @@ const createDrawer = utils_widget.createWidgetFactory("drawer", (config) => {
|
|
|
71
74
|
visible$: requestedVisible$,
|
|
72
75
|
container$,
|
|
73
76
|
className$,
|
|
77
|
+
size$: _dirtySize$,
|
|
74
78
|
animated$,
|
|
75
79
|
ariaDescribedBy$,
|
|
76
80
|
ariaLabelledBy$,
|
|
77
81
|
onHidden$,
|
|
78
82
|
onShown$,
|
|
79
|
-
|
|
80
|
-
height$: _dirtyHeight$,
|
|
81
|
-
onWidthChange$,
|
|
82
|
-
onHeightChange$,
|
|
83
|
+
onSizeChange$,
|
|
83
84
|
onVisibleChange$,
|
|
85
|
+
onMinimizedChange$,
|
|
86
|
+
onMaximizedChange$,
|
|
87
|
+
onResizingChange$,
|
|
84
88
|
...stateProps
|
|
85
89
|
},
|
|
86
90
|
patch
|
|
87
91
|
] = utils_stores.writablesForProps(defaultDrawerConfig, config, configValidator);
|
|
88
|
-
const
|
|
89
|
-
|
|
90
|
-
|
|
92
|
+
const size$ = utils_stores.bindableProp(_dirtySize$, onSizeChange$, (value) => value ? Math.round(value) : value);
|
|
93
|
+
const isVertical$ = tansu.computed(() => {
|
|
94
|
+
const isVertical = ["block-start", "block-end"].some((placement) => className$().includes(placement));
|
|
95
|
+
return isVertical;
|
|
91
96
|
});
|
|
92
97
|
const transition = services_transitions_baseTransitions.createTransition({
|
|
93
98
|
props: {
|
|
94
99
|
animated: animated$,
|
|
95
100
|
animatedOnInit: animated$,
|
|
96
|
-
transition: tansu.asWritable(tansu.computed(() => isVertical() ? verticalTransition$() : transition$())),
|
|
101
|
+
transition: tansu.asWritable(tansu.computed(() => isVertical$() ? verticalTransition$() : transition$())),
|
|
97
102
|
visible: requestedVisible$,
|
|
98
103
|
onVisibleChange: onVisibleChange$,
|
|
99
104
|
onHidden: onHidden$,
|
|
100
105
|
onShown: onShown$
|
|
101
106
|
}
|
|
102
107
|
});
|
|
103
|
-
const width$ = utils_stores.bindableProp(_dirtyWidth$, onWidthChange$);
|
|
104
|
-
const height$ = utils_stores.bindableProp(_dirtyHeight$, onHeightChange$);
|
|
105
108
|
const drawerPortalDirective = utils_directive.bindDirective(
|
|
106
109
|
services_portal.portal,
|
|
107
110
|
tansu.computed(() => ({ container: container$() }))
|
|
108
111
|
);
|
|
109
|
-
const
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
112
|
+
const { directive: drawerElementDirective, element$: drawerElement$ } = utils_directive.createBrowserStoreDirective();
|
|
113
|
+
const drawerAttributeDirective = utils_directive.mergeDirectives(
|
|
114
|
+
drawerElementDirective,
|
|
115
|
+
utils_directive.createAttributesDirective(() => ({
|
|
116
|
+
attributes: {
|
|
117
|
+
class: className$,
|
|
118
|
+
role: tansu.readable("dialog"),
|
|
119
|
+
"aria-describedby": ariaDescribedBy$,
|
|
120
|
+
"aria-labelledby": ariaLabelledBy$,
|
|
121
|
+
"aria-modal": tansu.readable("true"),
|
|
122
|
+
tabIndex: tansu.readable("-1")
|
|
123
|
+
},
|
|
124
|
+
styles: {
|
|
125
|
+
position: tansu.computed(() => {
|
|
126
|
+
const container = container$();
|
|
127
|
+
return container && utils_directive.isBrowserHTMLElement(container) && container !== document.body ? "relative" : "fixed";
|
|
128
|
+
}),
|
|
129
|
+
outline: tansu.readable("none")
|
|
130
|
+
},
|
|
131
|
+
events: {
|
|
132
|
+
keydown: async (e) => {
|
|
133
|
+
if (e.key === "Escape") {
|
|
134
|
+
await transition.api.hide();
|
|
135
|
+
}
|
|
129
136
|
}
|
|
130
137
|
}
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
const containerDirective = utils_directive.createAttributesDirective(() => ({
|
|
134
|
-
styles: {
|
|
135
|
-
width: tansu.computed(() => isVertical() ? "100%" : `${width$()}px`),
|
|
136
|
-
height: tansu.computed(() => isVertical() ? `${height$()}px` : "100%")
|
|
137
|
-
}
|
|
138
|
-
}));
|
|
138
|
+
}))
|
|
139
|
+
);
|
|
139
140
|
const backdropTransition = services_transitions_baseTransitions.createTransition({
|
|
140
141
|
props: {
|
|
141
142
|
animated: animated$,
|
|
@@ -169,55 +170,93 @@ const createDrawer = utils_widget.createWidgetFactory("drawer", (config) => {
|
|
|
169
170
|
"data-agnos-ignore-inert": utils_stores.true$
|
|
170
171
|
},
|
|
171
172
|
events: {
|
|
172
|
-
click: async () =>
|
|
173
|
-
await transition.api.hide();
|
|
174
|
-
}
|
|
173
|
+
click: async () => await transition.api.hide()
|
|
175
174
|
}
|
|
176
175
|
}));
|
|
177
|
-
const direction = tansu.computed(() => ["inline-start", "block-start"].some((placement) => className$().includes(placement)) ? 1 : -1);
|
|
178
|
-
const
|
|
179
|
-
const
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
}
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
176
|
+
const direction$ = tansu.computed(() => ["inline-start", "block-start"].some((placement) => className$().includes(placement)) ? 1 : -1);
|
|
177
|
+
const isMinimized$ = tansu.writable(void 0);
|
|
178
|
+
const isMaximized$ = tansu.writable(void 0);
|
|
179
|
+
function setSize(size) {
|
|
180
|
+
const drawerElement = drawerElement$();
|
|
181
|
+
const isVertical = isVertical$();
|
|
182
|
+
size = Math.round(Math.max(0, size));
|
|
183
|
+
drawerElement.style[isVertical ? "height" : "width"] = `${size}px`;
|
|
184
|
+
const elementSize = Math.round(drawerElement[isVertical ? "offsetHeight" : "offsetWidth"]);
|
|
185
|
+
size$.set(elementSize);
|
|
186
|
+
isMinimized$.set(size != null && (size < elementSize || size === 0));
|
|
187
|
+
isMaximized$.set(!!size && size > elementSize);
|
|
188
|
+
return elementSize;
|
|
189
|
+
}
|
|
190
|
+
const splitterDirective = utils_directive.mergeDirectives(
|
|
191
|
+
services_pointerdownPosition.createPointerdownPositionDirective((event) => {
|
|
192
|
+
const drawerElement = drawerElement$();
|
|
193
|
+
const isVertical = isVertical$();
|
|
194
|
+
const startSize = drawerElement[isVertical ? "offsetHeight" : "offsetWidth"];
|
|
195
|
+
const clientXorY = isVertical ? "clientY" : "clientX";
|
|
196
|
+
const startPos = event[clientXorY];
|
|
197
|
+
const direction = direction$();
|
|
198
|
+
onResizingChange$()(true);
|
|
199
|
+
return {
|
|
200
|
+
onMove(event2) {
|
|
201
|
+
setSize(startSize + direction * (event2[clientXorY] - startPos));
|
|
202
|
+
},
|
|
203
|
+
onEnd() {
|
|
204
|
+
drawerElement.style[isVertical ? "height" : "width"] = "";
|
|
205
|
+
onResizingChange$()(false);
|
|
206
|
+
}
|
|
207
|
+
};
|
|
208
|
+
}),
|
|
209
|
+
utils_directive.createAttributesDirective(() => ({
|
|
210
|
+
events: {
|
|
211
|
+
keydown: (e) => {
|
|
212
|
+
const { key } = e;
|
|
213
|
+
const size = size$() || drawerElement$()?.[isVertical$() ? "offsetHeight" : "offsetWidth"];
|
|
214
|
+
if (size != null) {
|
|
215
|
+
switch (key) {
|
|
216
|
+
case "ArrowLeft":
|
|
217
|
+
case "ArrowDown":
|
|
218
|
+
onResizingChange$()(true);
|
|
219
|
+
setSize(size - 10);
|
|
220
|
+
onResizingChange$()(false);
|
|
221
|
+
break;
|
|
222
|
+
case "ArrowRight":
|
|
223
|
+
case "ArrowUp":
|
|
224
|
+
onResizingChange$()(true);
|
|
225
|
+
setSize(size + 10);
|
|
226
|
+
onResizingChange$()(false);
|
|
227
|
+
break;
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
}
|
|
200
231
|
}
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
const updateDimension = (e) => {
|
|
204
|
-
if (!isVertical() && e.clientX > 0) {
|
|
205
|
-
dimension.set(startDimension() + direction() * (e.clientX - startPos()));
|
|
206
|
-
width$.set(dimension());
|
|
207
|
-
} else if (isVertical() && e.clientY > 0) {
|
|
208
|
-
dimension.set(startDimension() + direction() * (e.clientY - startPos()));
|
|
209
|
-
height$.set(dimension());
|
|
210
|
-
}
|
|
211
|
-
};
|
|
232
|
+
}))
|
|
233
|
+
);
|
|
212
234
|
const visible$ = transition.stores.visible$;
|
|
213
235
|
const transitioning$ = tansu.computed(() => transition.stores.transitioning$() || backdropTransition.stores.transitioning$());
|
|
214
236
|
const hidden$ = tansu.computed(() => !transitioning$() && !visible$());
|
|
237
|
+
const minSizeAction$ = tansu.computed(() => {
|
|
238
|
+
const isMinimized = isMinimized$();
|
|
239
|
+
if (isMinimized != null) {
|
|
240
|
+
tansu.untrack(() => onMinimizedChange$()(isMinimized));
|
|
241
|
+
}
|
|
242
|
+
});
|
|
243
|
+
const maxSizeAction$ = tansu.computed(() => {
|
|
244
|
+
const isMaximized = isMaximized$();
|
|
245
|
+
if (isMaximized != null) {
|
|
246
|
+
tansu.untrack(() => onMaximizedChange$()(isMaximized));
|
|
247
|
+
}
|
|
248
|
+
});
|
|
249
|
+
const action$ = tansu.computed(() => {
|
|
250
|
+
minSizeAction$();
|
|
251
|
+
maxSizeAction$();
|
|
252
|
+
});
|
|
215
253
|
const widget = {
|
|
216
254
|
...utils_stores.stateStores({
|
|
217
255
|
...stateProps,
|
|
218
256
|
backdropClass$,
|
|
219
257
|
className$,
|
|
220
258
|
container$,
|
|
259
|
+
size$,
|
|
221
260
|
visible$,
|
|
222
261
|
backdropHidden$,
|
|
223
262
|
hidden$
|
|
@@ -228,15 +267,16 @@ const createDrawer = utils_widget.createWidgetFactory("drawer", (config) => {
|
|
|
228
267
|
close: transition.api.hide
|
|
229
268
|
},
|
|
230
269
|
directives: {
|
|
231
|
-
containerDirective,
|
|
232
270
|
drawerPortalDirective,
|
|
233
271
|
drawerDirective: utils_directive.mergeDirectives(
|
|
234
|
-
|
|
272
|
+
utils_directive.directiveSubscribe(action$),
|
|
273
|
+
drawerAttributeDirective,
|
|
235
274
|
utils_directive.bindDirective(
|
|
236
275
|
services_siblingsInert.siblingsInert,
|
|
237
276
|
tansu.computed(() => !bodyScroll$())
|
|
238
277
|
),
|
|
239
|
-
|
|
278
|
+
// This directive must come after the attribute directive, to ensure that all the classes and attributes are applied for the transition
|
|
279
|
+
transition.directives.directive,
|
|
240
280
|
services_focusElement.focusElement
|
|
241
281
|
),
|
|
242
282
|
backdropPortalDirective,
|
package/index.cjs
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const types = require("./types.cjs");
|
|
4
|
-
const accordion = require("./accordion-
|
|
5
|
-
const alert = require("./alert-
|
|
6
|
-
const collapse = require("./collapse-
|
|
7
|
-
const modal = require("./modal-
|
|
8
|
-
const pagination = require("./pagination-
|
|
9
|
-
const progressbar = require("./progressbar-
|
|
10
|
-
const rating = require("./rating-
|
|
11
|
-
const select = require("./select-
|
|
12
|
-
const slider = require("./slider-
|
|
13
|
-
const toaster = require("./toaster-
|
|
14
|
-
const tree = require("./tree-
|
|
15
|
-
const drawer = require("./drawer-
|
|
4
|
+
const accordion = require("./accordion-nxveC0GZ.cjs");
|
|
5
|
+
const alert = require("./alert-AhaliJ17.cjs");
|
|
6
|
+
const collapse = require("./collapse-Da_27YUU.cjs");
|
|
7
|
+
const modal = require("./modal-B_3Uxplo.cjs");
|
|
8
|
+
const pagination = require("./pagination-2Vor6JPZ.cjs");
|
|
9
|
+
const progressbar = require("./progressbar-DyBRINco.cjs");
|
|
10
|
+
const rating = require("./rating-C0y1j4SC.cjs");
|
|
11
|
+
const select = require("./select-Dhsb9msC.cjs");
|
|
12
|
+
const slider = require("./slider-DTO58syz.cjs");
|
|
13
|
+
const toaster = require("./toaster-CT148JSJ.cjs");
|
|
14
|
+
const tree = require("./tree-C4l2Wqny.cjs");
|
|
15
|
+
const drawer = require("./drawer-DOi0TqZC.cjs");
|
|
16
16
|
const config = require("./config.cjs");
|
|
17
17
|
const services_extendWidget = require("./services/extendWidget.cjs");
|
|
18
18
|
const services_floatingUI = require("./services/floatingUI.cjs");
|
|
@@ -27,9 +27,9 @@ const services_hash = require("./services/hash.cjs");
|
|
|
27
27
|
const services_transitions_baseTransitions = require("./services/transitions/baseTransitions.cjs");
|
|
28
28
|
const services_transitions_cssTransitions = require("./services/transitions/cssTransitions.cjs");
|
|
29
29
|
const services_transitions_simpleClassTransition = require("./services/transitions/simpleClassTransition.cjs");
|
|
30
|
-
const utils_directive = require("./dom-
|
|
30
|
+
const utils_directive = require("./dom-Cm9_uROp.cjs");
|
|
31
31
|
const utils_stores = require("./utils/stores.cjs");
|
|
32
|
-
const utils_writables = require("./writables-
|
|
32
|
+
const utils_writables = require("./writables-Dt68gADJ.cjs");
|
|
33
33
|
exports.FACTORY_WIDGET_NAME = types.FACTORY_WIDGET_NAME;
|
|
34
34
|
exports.INVALID_VALUE = types.INVALID_VALUE;
|
|
35
35
|
exports.createAccordion = accordion.createAccordion;
|
|
@@ -76,6 +76,7 @@ exports.getKeyName = services_navManager.getKeyName;
|
|
|
76
76
|
exports.isInternalInputNavigation = services_navManager.isInternalInputNavigation;
|
|
77
77
|
exports.portal = services_portal.portal;
|
|
78
78
|
exports.createResizeObserver = services_resizeObserver.createResizeObserver;
|
|
79
|
+
exports.createResizeObserverMap = services_resizeObserver.createResizeObserverMap;
|
|
79
80
|
exports.siblingsInert = services_siblingsInert.siblingsInert;
|
|
80
81
|
exports.hash$ = services_hash.hash$;
|
|
81
82
|
exports.createTransition = services_transitions_baseTransitions.createTransition;
|
|
@@ -130,5 +131,6 @@ exports.typeFunction = utils_writables.typeFunction;
|
|
|
130
131
|
exports.typeHTMLElementOrNull = utils_writables.typeHTMLElementOrNull;
|
|
131
132
|
exports.typeNumber = utils_writables.typeNumber;
|
|
132
133
|
exports.typeNumberInRangeFactory = utils_writables.typeNumberInRangeFactory;
|
|
134
|
+
exports.typeNumberOrNull = utils_writables.typeNumberOrNull;
|
|
133
135
|
exports.typeString = utils_writables.typeString;
|
|
134
136
|
exports.typeStringOrNull = utils_writables.typeStringOrNull;
|
package/index.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { FACTORY_WIDGET_NAME, INVALID_VALUE } from "./types.js";
|
|
2
|
-
import { a, c, f, g } from "./accordion-
|
|
3
|
-
import { c as c2, g as g2 } from "./alert-
|
|
4
|
-
import { c as c3, g as g3 } from "./collapse-
|
|
5
|
-
import { c as c4, g as g4, a as a2, b, m } from "./modal-
|
|
6
|
-
import { c as c5, g as g5 } from "./pagination-
|
|
7
|
-
import { c as c6, g as g6 } from "./progressbar-
|
|
8
|
-
import { c as c7, g as g7 } from "./rating-
|
|
9
|
-
import { c as c8, g as g8 } from "./select-
|
|
10
|
-
import { c as c9, g as g9 } from "./slider-
|
|
11
|
-
import { T, c as c10, d, g as g10 } from "./toaster-
|
|
12
|
-
import { c as c11, g as g11 } from "./tree-
|
|
13
|
-
import { c as c12, g as g12 } from "./drawer-
|
|
2
|
+
import { a, c, f, g } from "./accordion-47EpOD36.js";
|
|
3
|
+
import { c as c2, g as g2 } from "./alert-anMaigvi.js";
|
|
4
|
+
import { c as c3, g as g3 } from "./collapse-CrfvGo_T.js";
|
|
5
|
+
import { c as c4, g as g4, a as a2, b, m } from "./modal-cKd3qUn1.js";
|
|
6
|
+
import { c as c5, g as g5 } from "./pagination-DlOyP_2C.js";
|
|
7
|
+
import { c as c6, g as g6 } from "./progressbar-B5g76eMV.js";
|
|
8
|
+
import { c as c7, g as g7 } from "./rating-C7C4-p4B.js";
|
|
9
|
+
import { c as c8, g as g8 } from "./select-nnl00UWY.js";
|
|
10
|
+
import { c as c9, g as g9 } from "./slider-B4WrdTeE.js";
|
|
11
|
+
import { T, c as c10, d, g as g10 } from "./toaster-CRPErgI2.js";
|
|
12
|
+
import { c as c11, g as g11 } from "./tree-CHpFqJPx.js";
|
|
13
|
+
import { c as c12, g as g12 } from "./drawer-Caz4Uypu.js";
|
|
14
14
|
import { createWidgetsConfig, mergeInto } from "./config.js";
|
|
15
15
|
import { extendWidgetProps } from "./services/extendWidget.js";
|
|
16
16
|
import { createFloatingUI } from "./services/floatingUI.js";
|
|
@@ -19,15 +19,15 @@ import { createIntersection } from "./services/intersection.js";
|
|
|
19
19
|
import { createMatchMedia } from "./services/matchMedia.js";
|
|
20
20
|
import { createNavManager, getKeyName, isInternalInputNavigation } from "./services/navManager.js";
|
|
21
21
|
import { portal } from "./services/portal.js";
|
|
22
|
-
import { createResizeObserver } from "./services/resizeObserver.js";
|
|
22
|
+
import { createResizeObserver, createResizeObserverMap } from "./services/resizeObserver.js";
|
|
23
23
|
import { siblingsInert } from "./services/siblingsInert.js";
|
|
24
24
|
import { hash$ } from "./services/hash.js";
|
|
25
25
|
import { createTransition, noAnimation } from "./services/transitions/baseTransitions.js";
|
|
26
26
|
import { createCSSTransition, getTransitionDurationMs, hasTransition } from "./services/transitions/cssTransitions.js";
|
|
27
27
|
import { createSimpleClassTransition } from "./services/transitions/simpleClassTransition.js";
|
|
28
|
-
import { q, a as a3, c as c13, b as b2, s, p, h, l, j, f as f2, g as g13, k, t, d as d2, e, i, m as m2, n, o, r, u } from "./dom-
|
|
28
|
+
import { q, a as a3, c as c13, b as b2, s, p, h, l, j, f as f2, g as g13, k, t, d as d2, e, i, m as m2, n, o, r, u } from "./dom-DD1hAVZy.js";
|
|
29
29
|
import { bindableDerived, bindableProp, createPatch, false$, findChangedProperties, idWithDefault, isStore, mergeConfigStores, normalizeConfigStores, stateStores, toReadableStore, toWritableStore, true$, writableWithDefault, writablesForProps, writablesWithDefault } from "./utils/stores.js";
|
|
30
|
-
import {
|
|
30
|
+
import { k as k2, t as t2, j as j2, c as c14, d as d3, h as h2, i as i2, a as a4, b as b3, g as g14, e as e2, f as f3 } from "./writables-Is1bF1Vt.js";
|
|
31
31
|
export {
|
|
32
32
|
FACTORY_WIDGET_NAME,
|
|
33
33
|
INVALID_VALUE,
|
|
@@ -62,6 +62,7 @@ export {
|
|
|
62
62
|
c6 as createProgressbar,
|
|
63
63
|
c7 as createRating,
|
|
64
64
|
createResizeObserver,
|
|
65
|
+
createResizeObserverMap,
|
|
65
66
|
c8 as createSelect,
|
|
66
67
|
createSimpleClassTransition,
|
|
67
68
|
c9 as createSlider,
|
|
@@ -70,7 +71,7 @@ export {
|
|
|
70
71
|
c10 as createToast,
|
|
71
72
|
createTransition,
|
|
72
73
|
c11 as createTree,
|
|
73
|
-
|
|
74
|
+
k2 as createTypeEnum,
|
|
74
75
|
createWidgetsConfig,
|
|
75
76
|
d as defaultToasterProps,
|
|
76
77
|
t as directiveAttributes,
|
|
@@ -119,13 +120,14 @@ export {
|
|
|
119
120
|
toReadableStore,
|
|
120
121
|
toWritableStore,
|
|
121
122
|
true$,
|
|
122
|
-
|
|
123
|
+
j2 as typeArray,
|
|
123
124
|
c14 as typeBoolean,
|
|
124
125
|
d3 as typeBooleanOrNull,
|
|
125
|
-
|
|
126
|
-
|
|
126
|
+
h2 as typeFunction,
|
|
127
|
+
i2 as typeHTMLElementOrNull,
|
|
127
128
|
a4 as typeNumber,
|
|
128
129
|
b3 as typeNumberInRangeFactory,
|
|
130
|
+
g14 as typeNumberOrNull,
|
|
129
131
|
e2 as typeString,
|
|
130
132
|
f3 as typeStringOrNull,
|
|
131
133
|
writableWithDefault,
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
const tansu = require("@amadeus-it-group/tansu");
|
|
3
|
-
const utils_writables = require("./writables-
|
|
3
|
+
const utils_writables = require("./writables-Dt68gADJ.cjs");
|
|
4
4
|
const utils_stores = require("./utils/stores.cjs");
|
|
5
5
|
const services_transitions_baseTransitions = require("./services/transitions/baseTransitions.cjs");
|
|
6
6
|
const promise = require("./promise-CxCD3NYv.cjs");
|
|
7
7
|
const utils_func = require("./utils/func.cjs");
|
|
8
8
|
const scrollbars = require("./scrollbars-CT87iv_6.cjs");
|
|
9
|
-
const utils_directive = require("./dom-
|
|
9
|
+
const utils_directive = require("./dom-Cm9_uROp.cjs");
|
|
10
10
|
const services_portal = require("./services/portal.cjs");
|
|
11
11
|
const services_siblingsInert = require("./services/siblingsInert.cjs");
|
|
12
12
|
const utils_widget = require("./utils/widget.cjs");
|
|
13
13
|
const services_focusElement = require("./services/focusElement.cjs");
|
|
14
|
-
const modalOutsideClick = Symbol();
|
|
15
|
-
const modalCloseButtonClick = Symbol();
|
|
16
|
-
const modalCloseEscape = Symbol();
|
|
14
|
+
const modalOutsideClick = /* @__PURE__ */ Symbol();
|
|
15
|
+
const modalCloseButtonClick = /* @__PURE__ */ Symbol();
|
|
16
|
+
const modalCloseEscape = /* @__PURE__ */ Symbol();
|
|
17
17
|
const defaultConfig = {
|
|
18
18
|
animated: true,
|
|
19
19
|
ariaCloseButtonLabel: "Close",
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { computed, readable } from "@amadeus-it-group/tansu";
|
|
2
|
-
import { c as typeBoolean,
|
|
2
|
+
import { c as typeBoolean, h as typeFunction, e as typeString, i as typeHTMLElementOrNull } from "./writables-Is1bF1Vt.js";
|
|
3
3
|
import { writablesForProps, stateStores } from "./utils/stores.js";
|
|
4
4
|
import { createTransition } from "./services/transitions/baseTransitions.js";
|
|
5
5
|
import { p as promiseFromStore } from "./promise-Y53vc4Ia.js";
|
|
6
6
|
import { noop } from "./utils/func.js";
|
|
7
7
|
import { r as removeScrollbars, a as revertScrollbars } from "./scrollbars-CcxSrnCx.js";
|
|
8
|
-
import { a as bindDirective, r as registrationArray, p as createAttributesDirective, n as mergeDirectives, d as directiveSubscribe, c as bindDirectiveNoArg, b as browserDirective } from "./dom-
|
|
8
|
+
import { a as bindDirective, r as registrationArray, p as createAttributesDirective, n as mergeDirectives, d as directiveSubscribe, c as bindDirectiveNoArg, b as browserDirective } from "./dom-DD1hAVZy.js";
|
|
9
9
|
import { portal } from "./services/portal.js";
|
|
10
10
|
import { siblingsInert } from "./services/siblingsInert.js";
|
|
11
11
|
import { createWidgetFactory } from "./utils/widget.js";
|
|
12
12
|
import { focusElement } from "./services/focusElement.js";
|
|
13
|
-
const modalOutsideClick = Symbol();
|
|
14
|
-
const modalCloseButtonClick = Symbol();
|
|
15
|
-
const modalCloseEscape = Symbol();
|
|
13
|
+
const modalOutsideClick = /* @__PURE__ */ Symbol();
|
|
14
|
+
const modalCloseButtonClick = /* @__PURE__ */ Symbol();
|
|
15
|
+
const modalCloseEscape = /* @__PURE__ */ Symbol();
|
|
16
16
|
const defaultConfig = {
|
|
17
17
|
animated: true,
|
|
18
18
|
ariaCloseButtonLabel: "Close",
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
const tansu = require("@amadeus-it-group/tansu");
|
|
3
3
|
const utils_stores = require("./utils/stores.cjs");
|
|
4
|
-
const utils_writables = require("./writables-
|
|
4
|
+
const utils_writables = require("./writables-Dt68gADJ.cjs");
|
|
5
5
|
const utils_func = require("./utils/func.cjs");
|
|
6
|
-
const utils_directive = require("./dom-
|
|
6
|
+
const utils_directive = require("./dom-Cm9_uROp.cjs");
|
|
7
7
|
const utils_widget = require("./utils/widget.cjs");
|
|
8
8
|
const PAGE_LINK_DEFAULT = "#";
|
|
9
9
|
const defaultConfig = {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { computed } from "@amadeus-it-group/tansu";
|
|
2
2
|
import { writablesForProps, bindableProp, stateStores, true$ } from "./utils/stores.js";
|
|
3
|
-
import {
|
|
3
|
+
import { m as isNumber, e as typeString, h as typeFunction, c as typeBoolean, a as typeNumber, l as clamp } from "./writables-Is1bF1Vt.js";
|
|
4
4
|
import { noop } from "./utils/func.js";
|
|
5
|
-
import { p as createAttributesDirective } from "./dom-
|
|
5
|
+
import { p as createAttributesDirective } from "./dom-DD1hAVZy.js";
|
|
6
6
|
import { createWidgetFactory } from "./utils/widget.js";
|
|
7
7
|
const PAGE_LINK_DEFAULT = "#";
|
|
8
8
|
const defaultConfig = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { l as clamp, h as typeFunction, e as typeString, a as typeNumber } from "./writables-Is1bF1Vt.js";
|
|
2
2
|
import { writablesForProps, stateStores } from "./utils/stores.js";
|
|
3
3
|
import { computed, readable } from "@amadeus-it-group/tansu";
|
|
4
|
-
import { p as createAttributesDirective } from "./dom-
|
|
4
|
+
import { p as createAttributesDirective } from "./dom-DD1hAVZy.js";
|
|
5
5
|
import { createWidgetFactory } from "./utils/widget.js";
|
|
6
6
|
const defaultConfig = {
|
|
7
7
|
min: 0,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
const utils_writables = require("./writables-
|
|
2
|
+
const utils_writables = require("./writables-Dt68gADJ.cjs");
|
|
3
3
|
const utils_stores = require("./utils/stores.cjs");
|
|
4
4
|
const tansu = require("@amadeus-it-group/tansu");
|
|
5
|
-
const utils_directive = require("./dom-
|
|
5
|
+
const utils_directive = require("./dom-Cm9_uROp.cjs");
|
|
6
6
|
const utils_widget = require("./utils/widget.cjs");
|
|
7
7
|
const defaultConfig = {
|
|
8
8
|
min: 0,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
const tansu = require("@amadeus-it-group/tansu");
|
|
3
3
|
const types = require("./types.cjs");
|
|
4
|
-
const utils_directive = require("./dom-
|
|
5
|
-
const utils_writables = require("./writables-
|
|
4
|
+
const utils_directive = require("./dom-Cm9_uROp.cjs");
|
|
5
|
+
const utils_writables = require("./writables-Dt68gADJ.cjs");
|
|
6
6
|
const utils_func = require("./utils/func.cjs");
|
|
7
7
|
const utils_stores = require("./utils/stores.cjs");
|
|
8
8
|
const utils_widget = require("./utils/widget.cjs");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { computed, writable, readable } from "@amadeus-it-group/tansu";
|
|
2
2
|
import { INVALID_VALUE } from "./types.js";
|
|
3
|
-
import { p as createAttributesDirective } from "./dom-
|
|
4
|
-
import { e as typeString,
|
|
3
|
+
import { p as createAttributesDirective } from "./dom-DD1hAVZy.js";
|
|
4
|
+
import { e as typeString, h as typeFunction, c as typeBoolean, a as typeNumber, l as clamp, m as isNumber } from "./writables-Is1bF1Vt.js";
|
|
5
5
|
import { noop } from "./utils/func.js";
|
|
6
6
|
import { writablesForProps, bindableProp, stateStores, true$ } from "./utils/stores.js";
|
|
7
7
|
import { createWidgetFactory } from "./utils/widget.js";
|
|
@@ -4,7 +4,7 @@ const dom = require("@floating-ui/dom");
|
|
|
4
4
|
const services_floatingUI = require("./services/floatingUI.cjs");
|
|
5
5
|
const services_focustrack = require("./services/focustrack.cjs");
|
|
6
6
|
const services_navManager = require("./services/navManager.cjs");
|
|
7
|
-
const utils_directive = require("./dom-
|
|
7
|
+
const utils_directive = require("./dom-Cm9_uROp.cjs");
|
|
8
8
|
const utils_func = require("./utils/func.cjs");
|
|
9
9
|
const utils_stores = require("./utils/stores.cjs");
|
|
10
10
|
const utils_widget = require("./utils/widget.cjs");
|
|
@@ -3,7 +3,7 @@ import { offset, autoPlacement, size } from "@floating-ui/dom";
|
|
|
3
3
|
import { createFloatingUI } from "./services/floatingUI.js";
|
|
4
4
|
import { createHasFocus } from "./services/focustrack.js";
|
|
5
5
|
import { createNavManager } from "./services/navManager.js";
|
|
6
|
-
import { v as generateId, n as mergeDirectives, p as createAttributesDirective, a as bindDirective } from "./dom-
|
|
6
|
+
import { v as generateId, n as mergeDirectives, p as createAttributesDirective, a as bindDirective } from "./dom-DD1hAVZy.js";
|
|
7
7
|
import { noop } from "./utils/func.js";
|
|
8
8
|
import { writablesForProps, bindableProp, bindableDerived, stateStores, true$ } from "./utils/stores.js";
|
|
9
9
|
import { createWidgetFactory } from "./utils/widget.js";
|
package/services/floatingUI.cjs
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const tansu = require("@amadeus-it-group/tansu");
|
|
4
4
|
const dom = require("@floating-ui/dom");
|
|
5
|
-
const utils_directive = require("../dom-
|
|
5
|
+
const utils_directive = require("../dom-Cm9_uROp.cjs");
|
|
6
6
|
const promise = require("../promise-CxCD3NYv.cjs");
|
|
7
7
|
const utils_stores = require("../utils/stores.cjs");
|
|
8
8
|
const defaultConfig = {
|
package/services/floatingUI.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { computed, derived } from "@amadeus-it-group/tansu";
|
|
2
2
|
import { arrow, autoUpdate, computePosition } from "@floating-ui/dom";
|
|
3
|
-
import { l as createBrowserStoreDirective, n as mergeDirectives, d as directiveSubscribe } from "../dom-
|
|
3
|
+
import { l as createBrowserStoreDirective, n as mergeDirectives, d as directiveSubscribe } from "../dom-DD1hAVZy.js";
|
|
4
4
|
import { a as promiseStoreToValueStore } from "../promise-Y53vc4Ia.js";
|
|
5
5
|
import { writablesForProps, stateStores } from "../utils/stores.js";
|
|
6
6
|
const defaultConfig = {
|