@maas/vue-equipment 0.24.6 → 0.24.8
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/dist/nuxt/module.json +1 -1
- package/dist/plugins/MagicDrawer/src/components/MagicDrawer.vue +1 -1
- package/dist/plugins/MagicDrawer/src/composables/private/useDrawerDrag.mjs +1 -1
- package/dist/plugins/MagicDrawer/src/composables/private/useDrawerSnap.mjs +2 -2
- package/dist/plugins/MagicDrawer/src/composables/useDrawerApi.d.ts +1 -1
- package/dist/plugins/MagicDrawer/src/composables/useDrawerApi.mjs +6 -2
- package/dist/plugins/MagicDrawer/src/types/index.d.ts +1 -0
- package/dist/plugins/MagicDrawer/src/utils/defaultOptions.mjs +2 -1
- package/dist/plugins/MagicModal/src/utils/defaultOptions.mjs +2 -1
- package/package.json +1 -1
package/dist/nuxt/module.json
CHANGED
|
@@ -148,7 +148,7 @@ export function useDrawerSnap(args) {
|
|
|
148
148
|
}
|
|
149
149
|
}
|
|
150
150
|
async function snapTo(args2) {
|
|
151
|
-
const { snapPoint, interpolate: interpolate2, duration
|
|
151
|
+
const { snapPoint, interpolate: interpolate2, duration } = args2;
|
|
152
152
|
await nextTick();
|
|
153
153
|
switch (position) {
|
|
154
154
|
case "top":
|
|
@@ -189,7 +189,7 @@ export function useDrawerSnap(args) {
|
|
|
189
189
|
}
|
|
190
190
|
}
|
|
191
191
|
async function interpolateDragged(args2) {
|
|
192
|
-
const { to, duration =
|
|
192
|
+
const { to, duration = toValue(snap).duration } = args2;
|
|
193
193
|
const snapPoint = snapPointsMap.value[to];
|
|
194
194
|
useDrawerEmitter().emit("beforeSnap", { id: toValue(id), snapPoint });
|
|
195
195
|
switch (position) {
|
|
@@ -13,7 +13,7 @@ export declare function useDrawerApi(id?: MaybeRef<string>, options?: UseDrawerA
|
|
|
13
13
|
}>;
|
|
14
14
|
open: () => void;
|
|
15
15
|
close: () => void;
|
|
16
|
-
snapTo: (snapPoint: SnapPoint) => void;
|
|
16
|
+
snapTo: (snapPoint: SnapPoint, duration?: number) => void;
|
|
17
17
|
trapFocus: () => void;
|
|
18
18
|
releaseFocus: () => void;
|
|
19
19
|
lockScroll: () => void;
|
|
@@ -37,8 +37,12 @@ export function useDrawerApi(id, options) {
|
|
|
37
37
|
function close() {
|
|
38
38
|
removeInstance(mappedId.value);
|
|
39
39
|
}
|
|
40
|
-
function snapTo(snapPoint) {
|
|
41
|
-
useDrawerEmitter().emit("snapTo", {
|
|
40
|
+
function snapTo(snapPoint, duration) {
|
|
41
|
+
useDrawerEmitter().emit("snapTo", {
|
|
42
|
+
id: mappedId.value,
|
|
43
|
+
snapPoint,
|
|
44
|
+
duration
|
|
45
|
+
});
|
|
42
46
|
}
|
|
43
47
|
function trapFocus() {
|
|
44
48
|
if (focusTrap) {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@maas/vue-equipment",
|
|
3
3
|
"description": "A magic collection of Vue composables, plugins, components and directives",
|
|
4
|
-
"version": "0.24.
|
|
4
|
+
"version": "0.24.8",
|
|
5
5
|
"author": "Robin Scholz <https://github.com/robinscholz>, Christoph Jeworutzki <https://github.com/ChristophJeworutzki>",
|
|
6
6
|
"devDependencies": {
|
|
7
7
|
"@antfu/ni": "^0.21.12",
|