@maas/vue-equipment 1.0.0-beta.1 → 1.0.0-beta.11
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/README.md +2 -2
- package/dist/composables/index.d.ts +5 -5
- package/dist/composables/index.js +23 -13
- package/dist/composables/index.js.map +1 -1
- package/dist/nuxt/module.json +1 -1
- package/dist/nuxt/module.mjs +9 -2
- package/dist/plugins/.turbo/turbo-lint.log +1 -9
- package/dist/plugins/MagicAccordion/demo/data/footer.json +1 -1
- package/dist/plugins/MagicAccordion/src/components/MagicAccordionContent.vue.d.ts +33 -22
- package/dist/plugins/MagicAccordion/src/components/MagicAccordionProvider.vue +2 -2
- package/dist/plugins/MagicAccordion/src/components/MagicAccordionProvider.vue.d.ts +12 -21
- package/dist/plugins/MagicAccordion/src/components/MagicAccordionTrigger.vue +15 -13
- package/dist/plugins/MagicAccordion/src/components/MagicAccordionTrigger.vue.d.ts +23 -59
- package/dist/plugins/MagicAccordion/src/components/MagicAccordionView.vue +2 -1
- package/dist/plugins/MagicAccordion/src/components/MagicAccordionView.vue.d.ts +17 -22
- package/dist/plugins/MagicAccordion/src/composables/private/useAccordionTrigger.d.ts +1 -1
- package/dist/plugins/MagicAccordion/src/symbols/index.d.ts +2 -2
- package/dist/plugins/MagicCommand/src/components/MagicCommandContent.vue +11 -4
- package/dist/plugins/MagicCommand/src/components/MagicCommandContent.vue.d.ts +24 -13
- package/dist/plugins/MagicCommand/src/components/MagicCommandDrawer.vue.d.ts +12 -21
- package/dist/plugins/MagicCommand/src/components/MagicCommandItem.vue +0 -4
- package/dist/plugins/MagicCommand/src/components/MagicCommandItem.vue.d.ts +29 -28
- package/dist/plugins/MagicCommand/src/components/MagicCommandModal.vue.d.ts +12 -21
- package/dist/plugins/MagicCommand/src/components/MagicCommandProvider.vue +5 -7
- package/dist/plugins/MagicCommand/src/components/MagicCommandProvider.vue.d.ts +12 -58
- package/dist/plugins/MagicCommand/src/components/MagicCommandRenderer.vue +7 -7
- package/dist/plugins/MagicCommand/src/components/MagicCommandTrigger.vue +7 -6
- package/dist/plugins/MagicCommand/src/components/MagicCommandTrigger.vue.d.ts +25 -60
- package/dist/plugins/MagicCommand/src/components/MagicCommandView.vue +2 -2
- package/dist/plugins/MagicCommand/src/components/MagicCommandView.vue.d.ts +15 -22
- package/dist/plugins/MagicCommand/src/composables/private/useCommandScroll.d.ts +2 -2
- package/dist/plugins/MagicCommand/src/composables/private/useCommandState.mjs +1 -1
- package/dist/plugins/MagicCommand/src/composables/private/useCommandTrigger.d.ts +1 -1
- package/dist/plugins/MagicCommand/src/symbols/index.d.ts +4 -4
- package/dist/plugins/MagicCommand/src/types/index.d.ts +1 -1
- package/dist/plugins/MagicCookie/src/components/MagicCookieItem.vue.d.ts +13 -22
- package/dist/plugins/MagicCookie/src/components/MagicCookieProvider.vue.d.ts +9 -21
- package/dist/plugins/MagicCookie/src/components/MagicCookieView.vue.d.ts +21 -12
- package/dist/plugins/MagicCookie/src/symbols/index.d.ts +2 -2
- package/dist/plugins/MagicDraggable/src/components/MagicDraggable.vue +20 -26
- package/dist/plugins/MagicDraggable/src/components/MagicDraggable.vue.d.ts +94 -23
- package/dist/plugins/MagicDraggable/src/composables/private/useDraggableDrag.d.ts +2 -2
- package/dist/plugins/MagicDraggable/src/composables/private/useDraggableDrag.mjs +9 -5
- package/dist/plugins/MagicDraggable/src/composables/private/useDraggableScrollLock.mjs +34 -14
- package/dist/plugins/MagicDraggable/src/composables/private/useDraggableSnap.d.ts +6 -4
- package/dist/plugins/MagicDraggable/src/composables/private/useDraggableSnap.mjs +54 -19
- package/dist/plugins/MagicDraggable/src/composables/private/useDraggableState.mjs +4 -4
- package/dist/plugins/MagicDraggable/src/types/index.d.ts +1 -1
- package/dist/plugins/MagicDraggable/src/utils/defaultOptions.mjs +1 -1
- package/dist/plugins/MagicDrawer/src/components/MagicDrawer.vue +33 -24
- package/dist/plugins/MagicDrawer/src/components/MagicDrawer.vue.d.ts +165 -24
- package/dist/plugins/MagicDrawer/src/composables/private/useDrawerDOM.mjs +34 -14
- package/dist/plugins/MagicDrawer/src/composables/private/useDrawerDrag.d.ts +2 -2
- package/dist/plugins/MagicDrawer/src/composables/private/useDrawerDrag.mjs +3 -3
- package/dist/plugins/MagicDrawer/src/composables/private/useDrawerGuards.d.ts +1 -1
- package/dist/plugins/MagicDrawer/src/composables/private/useDrawerGuards.mjs +28 -10
- package/dist/plugins/MagicDrawer/src/composables/private/useDrawerProgress.d.ts +2 -2
- package/dist/plugins/MagicDrawer/src/composables/private/useDrawerSnap.d.ts +3 -3
- package/dist/plugins/MagicDrawer/src/composables/private/useDrawerSnap.mjs +16 -14
- package/dist/plugins/MagicDrawer/src/composables/private/useDrawerWheel.d.ts +1 -1
- package/dist/plugins/MagicMarquee/src/components/MagicMarquee.vue +15 -15
- package/dist/plugins/MagicMarquee/src/components/MagicMarquee.vue.d.ts +14 -25
- package/dist/plugins/MagicMarquee/src/composables/private/useMarqueeApi.d.ts +1 -1
- package/dist/plugins/MagicMarquee/src/composables/private/useMarqueeApi.mjs +8 -2
- package/dist/plugins/MagicMenu/src/components/MagicMenuChannel.vue +4 -5
- package/dist/plugins/MagicMenu/src/components/MagicMenuChannel.vue.d.ts +18 -21
- package/dist/plugins/MagicMenu/src/components/MagicMenuContent.vue +3 -6
- package/dist/plugins/MagicMenu/src/components/MagicMenuContent.vue.d.ts +41 -24
- package/dist/plugins/MagicMenu/src/components/MagicMenuFloat.vue +5 -7
- package/dist/plugins/MagicMenu/src/components/MagicMenuFloat.vue.d.ts +40 -25
- package/dist/plugins/MagicMenu/src/components/MagicMenuItem.vue +3 -14
- package/dist/plugins/MagicMenu/src/components/MagicMenuItem.vue.d.ts +31 -28
- package/dist/plugins/MagicMenu/src/components/MagicMenuProvider.vue +19 -8
- package/dist/plugins/MagicMenu/src/components/MagicMenuProvider.vue.d.ts +12 -58
- package/dist/plugins/MagicMenu/src/components/MagicMenuRemote.vue +28 -38
- package/dist/plugins/MagicMenu/src/components/MagicMenuRemote.vue.d.ts +19 -23
- package/dist/plugins/MagicMenu/src/components/MagicMenuTrigger.vue +29 -19
- package/dist/plugins/MagicMenu/src/components/MagicMenuTrigger.vue.d.ts +27 -60
- package/dist/plugins/MagicMenu/src/components/MagicMenuView.vue +2 -2
- package/dist/plugins/MagicMenu/src/components/MagicMenuView.vue.d.ts +15 -22
- package/dist/plugins/MagicMenu/src/composables/private/useMenuCallback.mjs +1 -1
- package/dist/plugins/MagicMenu/src/composables/private/useMenuChannel.mjs +15 -5
- package/dist/plugins/MagicMenu/src/composables/private/useMenuCursor.d.ts +3 -3
- package/dist/plugins/MagicMenu/src/composables/private/useMenuCursor.mjs +4 -4
- package/dist/plugins/MagicMenu/src/composables/private/useMenuDOM.mjs +35 -15
- package/dist/plugins/MagicMenu/src/composables/private/useMenuTrigger.d.ts +1 -1
- package/dist/plugins/MagicMenu/src/composables/private/useMenuView.mjs +18 -6
- package/dist/plugins/MagicMenu/src/symbols/index.d.ts +4 -4
- package/dist/plugins/MagicMenu/src/utils/modeDelayDefaults.d.ts +2 -2
- package/dist/plugins/MagicMenu/src/utils/modeDelayDefaults.mjs +2 -2
- package/dist/plugins/MagicModal/src/components/MagicModal.vue +9 -9
- package/dist/plugins/MagicModal/src/components/MagicModal.vue.d.ts +44 -22
- package/dist/plugins/MagicModal/src/composables/private/useModalDOM.mjs +34 -14
- package/dist/plugins/MagicNoise/src/components/MagicNoise.vue +14 -14
- package/dist/plugins/MagicNoise/src/components/MagicNoise.vue.d.ts +1 -10
- package/dist/plugins/MagicNoise/src/composables/private/useNoiseApi.d.ts +3 -3
- package/dist/plugins/MagicNoise/src/composables/private/useNoiseApi.mjs +2 -2
- package/dist/plugins/MagicPie/index.d.ts +7 -0
- package/dist/plugins/MagicPie/index.mjs +8 -0
- package/dist/plugins/MagicPie/nuxt.d.ts +2 -0
- package/dist/plugins/MagicPie/nuxt.mjs +23 -0
- package/dist/plugins/MagicPie/src/components/MagicPie.vue +202 -0
- package/dist/plugins/MagicPie/src/components/MagicPie.vue.d.ts +7 -0
- package/dist/plugins/MagicPie/src/composables/private/usePieState.d.ts +6 -0
- package/dist/plugins/MagicPie/src/composables/private/usePieState.mjs +33 -0
- package/dist/plugins/MagicPie/src/composables/useMagicPie.d.ts +13 -0
- package/dist/plugins/MagicPie/src/composables/useMagicPie.mjs +43 -0
- package/dist/plugins/MagicPie/src/types/index.d.ts +9 -0
- package/dist/plugins/MagicPie/src/types/index.mjs +0 -0
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerAudio.vue +14 -8
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerAudioControls.vue +32 -38
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerAudioControls.vue.d.ts +27 -26
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerDisplayTime.vue.d.ts +1 -10
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerMuxPopover.vue +19 -8
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerMuxPopover.vue.d.ts +1 -10
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerOverlay.vue +2 -2
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerOverlay.vue.d.ts +29 -14
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerPoster.vue.d.ts +13 -11
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerProvider.vue +3 -4
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerProvider.vue.d.ts +23 -23
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerVideo.vue +3 -4
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerVideoControls.vue +24 -25
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerVideoControls.vue.d.ts +61 -33
- package/dist/plugins/MagicPlayer/src/composables/private/usePlayerAudioApi.d.ts +2 -2
- package/dist/plugins/MagicPlayer/src/composables/private/usePlayerAudioApi.mjs +3 -3
- package/dist/plugins/MagicPlayer/src/composables/private/usePlayerControlsApi.d.ts +10 -10
- package/dist/plugins/MagicPlayer/src/composables/private/usePlayerControlsApi.mjs +15 -9
- package/dist/plugins/MagicPlayer/src/composables/private/usePlayerMediaApi.d.ts +13 -13
- package/dist/plugins/MagicPlayer/src/composables/private/usePlayerMediaApi.mjs +18 -11
- package/dist/plugins/MagicPlayer/src/composables/private/usePlayerRuntime.d.ts +3 -3
- package/dist/plugins/MagicPlayer/src/composables/private/usePlayerRuntime.mjs +3 -3
- package/dist/plugins/MagicPlayer/src/composables/private/usePlayerVideoApi.d.ts +6 -6
- package/dist/plugins/MagicPlayer/src/composables/private/usePlayerVideoApi.mjs +4 -4
- package/dist/plugins/MagicPlayer/src/composables/useMagicPlayer.d.ts +20 -20
- package/dist/plugins/MagicScroll/src/components/MagicScrollCollision.vue +17 -8
- package/dist/plugins/MagicScroll/src/components/MagicScrollCollision.vue.d.ts +9 -23
- package/dist/plugins/MagicScroll/src/components/MagicScrollMotion.vue +11 -11
- package/dist/plugins/MagicScroll/src/components/MagicScrollMotion.vue.d.ts +9 -23
- package/dist/plugins/MagicScroll/src/components/MagicScrollProvider.vue.d.ts +45 -37
- package/dist/plugins/MagicScroll/src/components/MagicScrollScene.vue +18 -10
- package/dist/plugins/MagicScroll/src/components/MagicScrollScene.vue.d.ts +13 -24
- package/dist/plugins/MagicScroll/src/composables/private/useCollisionDetection.d.ts +2 -2
- package/dist/plugins/MagicScroll/src/composables/private/useCollisionDetection.mjs +3 -3
- package/dist/plugins/MagicScroll/src/composables/private/useScrollApi.mjs +14 -4
- package/dist/plugins/MagicScroll/src/symbols/index.d.ts +1 -1
- package/dist/plugins/MagicToast/src/components/MagicToastProvider.vue +23 -29
- package/dist/plugins/MagicToast/src/components/MagicToastProvider.vue.d.ts +1 -10
- package/dist/plugins/MagicToast/src/components/MagicToastView.vue +8 -11
- package/dist/plugins/MagicToast/src/components/MagicToastView.vue.d.ts +24 -23
- package/dist/plugins/MagicToast/src/composables/private/useToastCallback.d.ts +2 -2
- package/dist/plugins/MagicToast/src/composables/private/useToastCallback.mjs +5 -5
- package/dist/plugins/MagicToast/src/composables/private/useToastDrag.mjs +22 -22
- package/dist/plugins/MagicToast/src/composables/private/useToastScrollLock.mjs +33 -15
- package/dist/plugins/MagicToast/src/composables/useMagicToast.d.ts +1 -0
- package/dist/plugins/MagicToast/src/composables/useMagicToast.mjs +10 -2
- package/dist/plugins/MagicToast/src/types/index.d.ts +1 -1
- package/dist/plugins/MagicToast/src/utils/defaultOptions.mjs +1 -1
- package/dist/plugins/index.d.ts +1 -0
- package/dist/plugins/index.mjs +1 -0
- package/dist/utils/index.d.ts +9 -4
- package/dist/utils/index.js +39 -3
- package/dist/utils/index.js.map +1 -1
- package/package.json +16 -7
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { Primitive } from '@maas/vue-primitive';
|
|
1
2
|
import type { Interaction, Action } from '../types/index.js';
|
|
2
3
|
interface MagicCommandTriggerProps {
|
|
3
4
|
viewId?: string;
|
|
@@ -7,68 +8,32 @@ interface MagicCommandTriggerProps {
|
|
|
7
8
|
trigger?: Interaction[];
|
|
8
9
|
asChild?: boolean;
|
|
9
10
|
}
|
|
10
|
-
declare
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
elRef: import("vue").CreateComponentPublicInstanceWithMixins<Readonly<import("vue").ExtractPropTypes<{
|
|
20
|
-
asChild: {
|
|
21
|
-
type: BooleanConstructor;
|
|
22
|
-
default: boolean;
|
|
23
|
-
};
|
|
24
|
-
as: {
|
|
25
|
-
type: import("vue").PropType<import("@maas/vue-primitive").ElementOrComponent>;
|
|
26
|
-
default: string;
|
|
27
|
-
};
|
|
28
|
-
}>>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
29
|
-
[key: string]: any;
|
|
30
|
-
}>, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {
|
|
31
|
-
asChild: boolean;
|
|
32
|
-
as: import("@maas/vue-primitive").ElementOrComponent;
|
|
33
|
-
}, true, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
|
|
34
|
-
P: {};
|
|
35
|
-
B: {};
|
|
36
|
-
D: {};
|
|
37
|
-
C: {};
|
|
38
|
-
M: {};
|
|
39
|
-
Defaults: {};
|
|
40
|
-
}, Readonly<import("vue").ExtractPropTypes<{
|
|
41
|
-
asChild: {
|
|
42
|
-
type: BooleanConstructor;
|
|
43
|
-
default: boolean;
|
|
44
|
-
};
|
|
45
|
-
as: {
|
|
46
|
-
type: import("vue").PropType<import("@maas/vue-primitive").ElementOrComponent>;
|
|
47
|
-
default: string;
|
|
48
|
-
};
|
|
49
|
-
}>>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
50
|
-
[key: string]: any;
|
|
51
|
-
}>, {}, {}, {}, {
|
|
52
|
-
asChild: boolean;
|
|
53
|
-
as: import("@maas/vue-primitive").ElementOrComponent;
|
|
54
|
-
}> | null;
|
|
55
|
-
};
|
|
56
|
-
rootEl: any;
|
|
11
|
+
declare const mappedViewId: import("vue").ComputedRef<string | undefined>;
|
|
12
|
+
declare const view: import("../types").CommandView | undefined;
|
|
13
|
+
declare const mappedActive: import("vue").ComputedRef<boolean>;
|
|
14
|
+
declare const mappedDisabled: import("vue").ComputedRef<boolean>;
|
|
15
|
+
declare const onMouseenter: () => Promise<void>, onClick: (e: MouseEvent) => Promise<void>;
|
|
16
|
+
declare const __VLS_ctx: InstanceType<__VLS_PickNotAny<typeof __VLS_self, new () => {}>>;
|
|
17
|
+
declare var __VLS_12: {
|
|
18
|
+
viewActive: boolean | undefined;
|
|
19
|
+
triggerDisabled: boolean;
|
|
57
20
|
};
|
|
58
|
-
type
|
|
59
|
-
|
|
60
|
-
|
|
21
|
+
type __VLS_Slots = __VLS_PrettifyGlobal<__VLS_OmitStringIndex<typeof __VLS_ctx.$slots> & {
|
|
22
|
+
default?: (props: typeof __VLS_12) => any;
|
|
23
|
+
}>;
|
|
24
|
+
declare const __VLS_self: import("vue").DefineComponent<MagicCommandTriggerProps, {
|
|
25
|
+
Primitive: typeof Primitive;
|
|
26
|
+
mappedViewId: typeof mappedViewId;
|
|
27
|
+
view: typeof view;
|
|
28
|
+
mappedActive: typeof mappedActive;
|
|
29
|
+
mappedDisabled: typeof mappedDisabled;
|
|
30
|
+
onMouseenter: typeof onMouseenter;
|
|
31
|
+
onClick: typeof onClick;
|
|
32
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicCommandTriggerProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
33
|
+
declare const __VLS_component: import("vue").DefineComponent<MagicCommandTriggerProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicCommandTriggerProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
34
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
61
35
|
export default _default;
|
|
62
|
-
type
|
|
63
|
-
type __VLS_TypePropsToOption<T> = {
|
|
64
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
65
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
66
|
-
} : {
|
|
67
|
-
type: import('vue').PropType<T[K]>;
|
|
68
|
-
required: true;
|
|
69
|
-
};
|
|
70
|
-
};
|
|
71
|
-
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
36
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
72
37
|
new (): {
|
|
73
38
|
$slots: S;
|
|
74
39
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<script>
|
|
2
2
|
import { defineComponent as _defineComponent } from "vue";
|
|
3
3
|
import { unref as _unref, renderSlot as _renderSlot, openBlock as _openBlock, createElementBlock as _createElementBlock } from "vue";
|
|
4
|
-
const _hoisted_1 = ["id"];
|
|
4
|
+
const _hoisted_1 = ["data-id"];
|
|
5
5
|
import { computed, inject, onBeforeUnmount, provide, useId, watch } from "vue";
|
|
6
6
|
import { useCommandView } from "../composables/private/useCommandView";
|
|
7
7
|
import {
|
|
@@ -47,7 +47,7 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
47
47
|
});
|
|
48
48
|
return (_ctx, _cache) => {
|
|
49
49
|
return _openBlock(), _createElementBlock("div", {
|
|
50
|
-
id: mappedId.value,
|
|
50
|
+
"data-id": mappedId.value,
|
|
51
51
|
class: "magic-menu-view"
|
|
52
52
|
}, [
|
|
53
53
|
_renderSlot(_ctx.$slots, "default", {
|
|
@@ -2,30 +2,23 @@ interface MagicCommandViewProps {
|
|
|
2
2
|
id?: string;
|
|
3
3
|
initial?: boolean;
|
|
4
4
|
}
|
|
5
|
-
declare
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
}): any;
|
|
11
|
-
};
|
|
12
|
-
refs: {};
|
|
13
|
-
rootEl: HTMLDivElement;
|
|
5
|
+
declare const mappedId: import("vue").ComputedRef<string>;
|
|
6
|
+
declare const view: import("../types").CommandView;
|
|
7
|
+
declare const __VLS_ctx: InstanceType<__VLS_PickNotAny<typeof __VLS_self, new () => {}>>;
|
|
8
|
+
declare var __VLS_1: {
|
|
9
|
+
viewActive: boolean;
|
|
14
10
|
};
|
|
15
|
-
type
|
|
16
|
-
|
|
17
|
-
|
|
11
|
+
type __VLS_Slots = __VLS_PrettifyGlobal<__VLS_OmitStringIndex<typeof __VLS_ctx.$slots> & {
|
|
12
|
+
default?: (props: typeof __VLS_1) => any;
|
|
13
|
+
}>;
|
|
14
|
+
declare const __VLS_self: import("vue").DefineComponent<MagicCommandViewProps, {
|
|
15
|
+
mappedId: typeof mappedId;
|
|
16
|
+
view: typeof view;
|
|
17
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicCommandViewProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
18
|
+
declare const __VLS_component: import("vue").DefineComponent<MagicCommandViewProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicCommandViewProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
19
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
18
20
|
export default _default;
|
|
19
|
-
type
|
|
20
|
-
type __VLS_TypePropsToOption<T> = {
|
|
21
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
22
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
23
|
-
} : {
|
|
24
|
-
type: import('vue').PropType<T[K]>;
|
|
25
|
-
required: true;
|
|
26
|
-
};
|
|
27
|
-
};
|
|
28
|
-
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
21
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
29
22
|
new (): {
|
|
30
23
|
$slots: S;
|
|
31
24
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type MaybeRef } from 'vue';
|
|
1
|
+
import { type MaybeRef, type Ref } from 'vue';
|
|
2
2
|
interface IsElementAboveArgs {
|
|
3
3
|
element: MaybeRef<HTMLElement>;
|
|
4
4
|
ancestor?: HTMLElement;
|
|
@@ -15,7 +15,7 @@ interface ScrollInFromBottomArgs {
|
|
|
15
15
|
element: MaybeRef<HTMLElement>;
|
|
16
16
|
ancestor?: HTMLElement;
|
|
17
17
|
}
|
|
18
|
-
export declare function useCommandScroll(parent:
|
|
18
|
+
export declare function useCommandScroll(parent: Ref<HTMLElement | null>): {
|
|
19
19
|
findElement: (id: string) => HTMLElement | null;
|
|
20
20
|
findScrollableAncestor: (element: HTMLElement | null) => HTMLElement | undefined;
|
|
21
21
|
isElementAbove: (args: IsElementAboveArgs) => boolean;
|
|
@@ -8,7 +8,7 @@ type UseCommandTriggerArgs = {
|
|
|
8
8
|
mappedActive?: ComputedRef<boolean>;
|
|
9
9
|
trigger: Interaction[];
|
|
10
10
|
action: Action;
|
|
11
|
-
elRef: Ref<InstanceType<typeof Primitive> |
|
|
11
|
+
elRef: Ref<InstanceType<typeof Primitive> | null>;
|
|
12
12
|
};
|
|
13
13
|
export declare function useCommandTrigger(args: UseCommandTriggerArgs): {
|
|
14
14
|
onMouseenter: () => Promise<void>;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import type { InjectionKey, MaybeRef } from 'vue';
|
|
1
|
+
import type { InjectionKey, MaybeRef, Ref } from 'vue';
|
|
2
2
|
import type { MagicCommandOptions } from '../types/index.js';
|
|
3
3
|
declare const MagicCommandInstanceId: InjectionKey<MaybeRef<string>>;
|
|
4
4
|
declare const MagicCommandParentTree: InjectionKey<string[]>;
|
|
5
5
|
declare const MagicCommandViewId: InjectionKey<string>;
|
|
6
|
-
declare const MagicCommandViewActive: InjectionKey<
|
|
6
|
+
declare const MagicCommandViewActive: InjectionKey<Ref<boolean>>;
|
|
7
7
|
declare const MagicCommandContentId: InjectionKey<string>;
|
|
8
8
|
declare const MagicCommandItemId: InjectionKey<string>;
|
|
9
|
-
declare const MagicCommandItemActive: InjectionKey<
|
|
10
|
-
declare const MagicCommandItemDisabled: InjectionKey<
|
|
9
|
+
declare const MagicCommandItemActive: InjectionKey<Ref<boolean>>;
|
|
10
|
+
declare const MagicCommandItemDisabled: InjectionKey<Ref<boolean>>;
|
|
11
11
|
declare const MagicCommandProviderOptions: InjectionKey<MagicCommandOptions>;
|
|
12
12
|
export { MagicCommandInstanceId, MagicCommandParentTree, MagicCommandViewId, MagicCommandViewActive, MagicCommandContentId, MagicCommandItemId, MagicCommandItemActive, MagicCommandItemDisabled, MagicCommandProviderOptions, };
|
|
@@ -3,30 +3,21 @@ interface MagicCookieItemProps {
|
|
|
3
3
|
optional?: boolean;
|
|
4
4
|
maxAge?: number;
|
|
5
5
|
}
|
|
6
|
-
declare
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
item: import("../types").CookieItem;
|
|
11
|
-
}): any;
|
|
12
|
-
};
|
|
13
|
-
refs: {};
|
|
14
|
-
rootEl: HTMLDivElement;
|
|
6
|
+
declare const item: import("../types").CookieItem;
|
|
7
|
+
declare const __VLS_ctx: InstanceType<__VLS_PickNotAny<typeof __VLS_self, new () => {}>>;
|
|
8
|
+
declare var __VLS_1: {
|
|
9
|
+
item: import("../types").CookieItem;
|
|
15
10
|
};
|
|
16
|
-
type
|
|
17
|
-
|
|
18
|
-
|
|
11
|
+
type __VLS_Slots = __VLS_PrettifyGlobal<__VLS_OmitStringIndex<typeof __VLS_ctx.$slots> & {
|
|
12
|
+
default?: (props: typeof __VLS_1) => any;
|
|
13
|
+
}>;
|
|
14
|
+
declare const __VLS_self: import("vue").DefineComponent<MagicCookieItemProps, {
|
|
15
|
+
item: typeof item;
|
|
16
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicCookieItemProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
17
|
+
declare const __VLS_component: import("vue").DefineComponent<MagicCookieItemProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicCookieItemProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
18
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
19
19
|
export default _default;
|
|
20
|
-
type
|
|
21
|
-
type __VLS_TypePropsToOption<T> = {
|
|
22
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
23
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
24
|
-
} : {
|
|
25
|
-
type: import('vue').PropType<T[K]>;
|
|
26
|
-
required: true;
|
|
27
|
-
};
|
|
28
|
-
};
|
|
29
|
-
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
20
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
30
21
|
new (): {
|
|
31
22
|
$slots: S;
|
|
32
23
|
};
|
|
@@ -4,28 +4,16 @@ type MagicCookieProviderProps = {
|
|
|
4
4
|
id: MaybeRef<string>;
|
|
5
5
|
options?: MagicCookieOptions;
|
|
6
6
|
};
|
|
7
|
-
declare
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
16
|
-
declare const __VLS_component: import("vue").DefineComponent<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<MagicCookieProviderProps>>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<MagicCookieProviderProps>>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
17
|
-
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
7
|
+
declare const __VLS_ctx: InstanceType<__VLS_PickNotAny<typeof __VLS_self, new () => {}>>;
|
|
8
|
+
declare var __VLS_6: {};
|
|
9
|
+
type __VLS_Slots = __VLS_PrettifyGlobal<__VLS_OmitStringIndex<typeof __VLS_ctx.$slots> & {
|
|
10
|
+
default?: (props: typeof __VLS_6) => any;
|
|
11
|
+
}>;
|
|
12
|
+
declare const __VLS_self: import("vue").DefineComponent<MagicCookieProviderProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicCookieProviderProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
13
|
+
declare const __VLS_component: import("vue").DefineComponent<MagicCookieProviderProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicCookieProviderProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
14
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
18
15
|
export default _default;
|
|
19
|
-
type
|
|
20
|
-
type __VLS_TypePropsToOption<T> = {
|
|
21
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
22
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
23
|
-
} : {
|
|
24
|
-
type: import('vue').PropType<T[K]>;
|
|
25
|
-
required: true;
|
|
26
|
-
};
|
|
27
|
-
};
|
|
28
|
-
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
16
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
29
17
|
new (): {
|
|
30
18
|
$slots: S;
|
|
31
19
|
};
|
|
@@ -1,20 +1,29 @@
|
|
|
1
|
+
import { AutoSize } from '@maas/vue-autosize';
|
|
1
2
|
import '@maas/vue-equipment/utils/css/animations/fade-in.css';
|
|
2
3
|
import '@maas/vue-equipment/utils/css/animations/auto-size-out.css';
|
|
3
|
-
declare
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
}): any;
|
|
9
|
-
};
|
|
10
|
-
refs: {};
|
|
11
|
-
rootEl: HTMLDivElement;
|
|
4
|
+
declare const state: import("../types").CookieState;
|
|
5
|
+
declare const onBeforeEnter: () => void, onEnter: () => void, onAfterEnter: () => Promise<void>, onBeforeLeave: () => void, onLeave: () => void, onAfterLeave: () => void;
|
|
6
|
+
declare const __VLS_ctx: InstanceType<__VLS_PickNotAny<typeof __VLS_self, new () => {}>>;
|
|
7
|
+
declare var __VLS_18: {
|
|
8
|
+
viewActive: boolean;
|
|
12
9
|
};
|
|
13
|
-
type
|
|
10
|
+
type __VLS_Slots = __VLS_PrettifyGlobal<__VLS_OmitStringIndex<typeof __VLS_ctx.$slots> & {
|
|
11
|
+
default?: (props: typeof __VLS_18) => any;
|
|
12
|
+
}>;
|
|
13
|
+
declare const __VLS_self: import("vue").DefineComponent<{}, {
|
|
14
|
+
AutoSize: typeof AutoSize;
|
|
15
|
+
state: typeof state;
|
|
16
|
+
onBeforeEnter: typeof onBeforeEnter;
|
|
17
|
+
onEnter: typeof onEnter;
|
|
18
|
+
onAfterEnter: typeof onAfterEnter;
|
|
19
|
+
onBeforeLeave: typeof onBeforeLeave;
|
|
20
|
+
onLeave: typeof onLeave;
|
|
21
|
+
onAfterLeave: typeof onAfterLeave;
|
|
22
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
14
23
|
declare const __VLS_component: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
15
|
-
declare const _default:
|
|
24
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
16
25
|
export default _default;
|
|
17
|
-
type
|
|
26
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
18
27
|
new (): {
|
|
19
28
|
$slots: S;
|
|
20
29
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { InjectionKey, MaybeRef } from 'vue';
|
|
1
|
+
import type { InjectionKey, MaybeRef, Ref } from 'vue';
|
|
2
2
|
declare const MagicCookieInstanceId: InjectionKey<MaybeRef<string>>;
|
|
3
3
|
declare const MagicCookieItemId: InjectionKey<string>;
|
|
4
|
-
declare const MagicCookieItemActive: InjectionKey<
|
|
4
|
+
declare const MagicCookieItemActive: InjectionKey<Ref<boolean>>;
|
|
5
5
|
export { MagicCookieInstanceId, MagicCookieItemId, MagicCookieItemActive };
|
|
@@ -1,12 +1,16 @@
|
|
|
1
1
|
<script>
|
|
2
2
|
import { defineComponent as _defineComponent } from "vue";
|
|
3
3
|
import { unref as _unref, renderSlot as _renderSlot, openBlock as _openBlock, createElementBlock as _createElementBlock, createCommentVNode as _createCommentVNode, resolveDynamicComponent as _resolveDynamicComponent, normalizeStyle as _normalizeStyle, withCtx as _withCtx, createBlock as _createBlock, createElementVNode as _createElementVNode, mergeProps as _mergeProps } from "vue";
|
|
4
|
-
const _hoisted_1 = ["id"];
|
|
4
|
+
const _hoisted_1 = ["data-id", "data-dragging", "data-disabled"];
|
|
5
5
|
const _hoisted_2 = {
|
|
6
|
+
ref: "wrapper",
|
|
7
|
+
class: "magic-draggable__wrapper"
|
|
8
|
+
};
|
|
9
|
+
const _hoisted_3 = {
|
|
6
10
|
key: 0,
|
|
7
11
|
class: "magic-draggable__overlay"
|
|
8
12
|
};
|
|
9
|
-
import {
|
|
13
|
+
import { useTemplateRef, computed, toValue, toRefs } from "vue";
|
|
10
14
|
import { defu } from "defu";
|
|
11
15
|
import { useDraggableDrag } from "../composables/private/useDraggableDrag";
|
|
12
16
|
import { useDraggableState } from "../composables/private/useDraggableState";
|
|
@@ -22,8 +26,8 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
22
26
|
},
|
|
23
27
|
setup(__props) {
|
|
24
28
|
const mappedOptions = defu(__props.options, defaultOptions);
|
|
25
|
-
const elRef =
|
|
26
|
-
const wrapperRef =
|
|
29
|
+
const elRef = useTemplateRef("el");
|
|
30
|
+
const wrapperRef = useTemplateRef("wrapper");
|
|
27
31
|
const { initializeState } = useDraggableState(__props.id);
|
|
28
32
|
const state = initializeState();
|
|
29
33
|
const { dragging } = toRefs(state);
|
|
@@ -57,27 +61,17 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
57
61
|
}
|
|
58
62
|
return (_ctx, _cache) => {
|
|
59
63
|
return _openBlock(), _createElementBlock("div", _mergeProps({
|
|
60
|
-
id: toValue(_ctx.id),
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
{
|
|
65
|
-
"-dragging": _unref(dragging),
|
|
66
|
-
"-disabled": disabled.value
|
|
67
|
-
}
|
|
68
|
-
]
|
|
64
|
+
"data-id": toValue(_ctx.id),
|
|
65
|
+
"data-dragging": _unref(dragging),
|
|
66
|
+
"data-disabled": disabled.value,
|
|
67
|
+
class: "magic-draggable"
|
|
69
68
|
}, _ctx.$attrs), [
|
|
70
69
|
_createElementVNode(
|
|
71
70
|
"div",
|
|
72
|
-
|
|
73
|
-
ref_key: "wrapperRef",
|
|
74
|
-
ref: wrapperRef,
|
|
75
|
-
class: "magic-draggable__wrapper"
|
|
76
|
-
},
|
|
71
|
+
_hoisted_2,
|
|
77
72
|
[
|
|
78
73
|
(_openBlock(), _createBlock(_resolveDynamicComponent(_unref(mappedOptions).tag), {
|
|
79
|
-
|
|
80
|
-
ref: elRef,
|
|
74
|
+
ref: "el",
|
|
81
75
|
class: "magic-draggable__drag",
|
|
82
76
|
style: _normalizeStyle(_unref(style)),
|
|
83
77
|
onPointerdown: guardedPointerdown,
|
|
@@ -85,7 +79,7 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
85
79
|
}, {
|
|
86
80
|
default: _withCtx(() => [
|
|
87
81
|
_renderSlot(_ctx.$slots, "default"),
|
|
88
|
-
_unref(hasDragged) ? (_openBlock(), _createElementBlock("div",
|
|
82
|
+
_unref(hasDragged) ? (_openBlock(), _createElementBlock("div", _hoisted_3)) : _createCommentVNode("v-if", true)
|
|
89
83
|
]),
|
|
90
84
|
_: 3
|
|
91
85
|
/* FORWARDED */
|
|
@@ -114,7 +108,7 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
114
108
|
border: none;
|
|
115
109
|
}
|
|
116
110
|
|
|
117
|
-
.magic-draggable
|
|
111
|
+
.magic-draggable[data-disabled='true'] {
|
|
118
112
|
pointer-events: none;
|
|
119
113
|
}
|
|
120
114
|
|
|
@@ -125,7 +119,7 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
125
119
|
}
|
|
126
120
|
|
|
127
121
|
.magic-draggable__drag {
|
|
128
|
-
cursor: grab;
|
|
122
|
+
cursor: (--magic-draggable-cursor, grab);
|
|
129
123
|
user-select: none;
|
|
130
124
|
pointer-events: auto;
|
|
131
125
|
position: relative;
|
|
@@ -136,12 +130,12 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
136
130
|
touch-action: none;
|
|
137
131
|
}
|
|
138
132
|
|
|
139
|
-
.magic-draggable
|
|
140
|
-
cursor: grabbing;
|
|
133
|
+
.magic-draggable[data-dragging='true'] .magic-draggable__drag {
|
|
134
|
+
cursor: (--magic-draggable-cursor-dragging, grabbing);
|
|
141
135
|
user-select: none;
|
|
142
136
|
}
|
|
143
137
|
|
|
144
|
-
.magic-draggable
|
|
138
|
+
.magic-draggable[data-disabled='true'] .magic-draggable__drag {
|
|
145
139
|
cursor: default;
|
|
146
140
|
}
|
|
147
141
|
|
|
@@ -1,35 +1,106 @@
|
|
|
1
|
-
import { type MaybeRef } from 'vue';
|
|
1
|
+
import { toValue, type MaybeRef } from 'vue';
|
|
2
2
|
import type { MagicDraggableOptions } from '../types/index.js';
|
|
3
3
|
interface MagicDraggableProps {
|
|
4
4
|
id: MaybeRef<string>;
|
|
5
5
|
options?: MagicDraggableOptions;
|
|
6
6
|
}
|
|
7
|
-
declare
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
7
|
+
declare const mappedOptions: Omit<MagicDraggableOptions, keyof MagicDraggableOptions> & Omit<import("../types").DraggableDefaultOptions, keyof MagicDraggableOptions> & {
|
|
8
|
+
threshold: ({
|
|
9
|
+
lock?: number;
|
|
10
|
+
distance?: number;
|
|
11
|
+
momentum?: number;
|
|
12
|
+
idle?: number;
|
|
13
|
+
} & import("../../../../utils").RequireAll<{
|
|
14
|
+
lock?: number;
|
|
15
|
+
distance?: number;
|
|
16
|
+
momentum?: number;
|
|
17
|
+
idle?: number;
|
|
18
|
+
}>) | (Omit<{
|
|
19
|
+
lock?: number;
|
|
20
|
+
distance?: number;
|
|
21
|
+
momentum?: number;
|
|
22
|
+
idle?: number;
|
|
23
|
+
}, "lock" | "distance" | "momentum" | "idle"> & Omit<{
|
|
24
|
+
lock?: number;
|
|
25
|
+
distance?: number;
|
|
26
|
+
momentum?: number;
|
|
27
|
+
idle?: number;
|
|
28
|
+
} & import("../../../../utils").RequireAll<{
|
|
29
|
+
lock?: number;
|
|
30
|
+
distance?: number;
|
|
31
|
+
momentum?: number;
|
|
32
|
+
idle?: number;
|
|
33
|
+
}>, "lock" | "distance" | "momentum" | "idle"> & {
|
|
34
|
+
lock: number;
|
|
35
|
+
distance: number;
|
|
36
|
+
momentum: number;
|
|
37
|
+
idle: number;
|
|
38
|
+
});
|
|
39
|
+
disabled: boolean;
|
|
40
|
+
animation: ({
|
|
41
|
+
snap?: {
|
|
42
|
+
duration?: number;
|
|
43
|
+
easing?: (t: number) => number;
|
|
44
|
+
};
|
|
45
|
+
} & import("../../../../utils").RequireAll<{
|
|
46
|
+
snap?: {
|
|
47
|
+
duration?: number;
|
|
48
|
+
easing?: (t: number) => number;
|
|
49
|
+
};
|
|
50
|
+
}>) | (Omit<{
|
|
51
|
+
snap?: {
|
|
52
|
+
duration?: number;
|
|
53
|
+
easing?: (t: number) => number;
|
|
54
|
+
};
|
|
55
|
+
}, "snap"> & Omit<{
|
|
56
|
+
snap?: {
|
|
57
|
+
duration?: number;
|
|
58
|
+
easing?: (t: number) => number;
|
|
59
|
+
};
|
|
60
|
+
} & import("../../../../utils").RequireAll<{
|
|
61
|
+
snap?: {
|
|
62
|
+
duration?: number;
|
|
63
|
+
easing?: (t: number) => number;
|
|
64
|
+
};
|
|
65
|
+
}>, "snap"> & {
|
|
66
|
+
snap: {
|
|
67
|
+
duration?: number;
|
|
68
|
+
easing?: (t: number) => number;
|
|
69
|
+
};
|
|
70
|
+
});
|
|
71
|
+
tag: "div" | "dialog";
|
|
72
|
+
scrollLock: boolean | {
|
|
73
|
+
padding: boolean;
|
|
11
74
|
};
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
elRef: unknown;
|
|
75
|
+
snapPoints: import("../types").DraggableSnapPoint[];
|
|
76
|
+
initial: {
|
|
77
|
+
snapPoint?: import("../types").DraggableSnapPoint;
|
|
16
78
|
};
|
|
17
|
-
rootEl: any;
|
|
18
79
|
};
|
|
19
|
-
|
|
20
|
-
declare const
|
|
21
|
-
declare const
|
|
80
|
+
declare const dragging: import("vue").Ref<boolean, boolean>;
|
|
81
|
+
declare const disabled: import("vue").ComputedRef<boolean>;
|
|
82
|
+
declare const style: import("vue").ComputedRef<string>, hasDragged: import("vue").ComputedRef<boolean>;
|
|
83
|
+
declare function guardedPointerdown(event: PointerEvent): void;
|
|
84
|
+
declare function guardedClick(event: PointerEvent): void;
|
|
85
|
+
declare const __VLS_ctx: InstanceType<__VLS_PickNotAny<typeof __VLS_self, new () => {}>>;
|
|
86
|
+
declare var __VLS_12: {};
|
|
87
|
+
type __VLS_Slots = __VLS_PrettifyGlobal<__VLS_OmitStringIndex<typeof __VLS_ctx.$slots> & {
|
|
88
|
+
default?: (props: typeof __VLS_12) => any;
|
|
89
|
+
}>;
|
|
90
|
+
declare const __VLS_self: import("vue").DefineComponent<MagicDraggableProps, {
|
|
91
|
+
toValue: typeof toValue;
|
|
92
|
+
mappedOptions: typeof mappedOptions;
|
|
93
|
+
dragging: typeof dragging;
|
|
94
|
+
disabled: typeof disabled;
|
|
95
|
+
style: typeof style;
|
|
96
|
+
hasDragged: typeof hasDragged;
|
|
97
|
+
guardedPointerdown: typeof guardedPointerdown;
|
|
98
|
+
guardedClick: typeof guardedClick;
|
|
99
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicDraggableProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
100
|
+
declare const __VLS_component: import("vue").DefineComponent<MagicDraggableProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicDraggableProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
101
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
22
102
|
export default _default;
|
|
23
|
-
type
|
|
24
|
-
type __VLS_TypePropsToOption<T> = {
|
|
25
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
26
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
27
|
-
} : {
|
|
28
|
-
type: import('vue').PropType<T[K]>;
|
|
29
|
-
required: true;
|
|
30
|
-
};
|
|
31
|
-
};
|
|
32
|
-
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
103
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
33
104
|
new (): {
|
|
34
105
|
$slots: S;
|
|
35
106
|
};
|
|
@@ -2,8 +2,8 @@ import { type Ref, type MaybeRef } from 'vue';
|
|
|
2
2
|
import type { DraggableDefaultOptions } from '../../types/index.js';
|
|
3
3
|
type UseDraggableDragArgs = {
|
|
4
4
|
id: MaybeRef<string>;
|
|
5
|
-
elRef: Ref<HTMLElement |
|
|
6
|
-
wrapperRef: Ref<HTMLDivElement |
|
|
5
|
+
elRef: Ref<HTMLElement | null>;
|
|
6
|
+
wrapperRef: Ref<HTMLDivElement | null>;
|
|
7
7
|
threshold: MaybeRef<DraggableDefaultOptions['threshold']>;
|
|
8
8
|
snapPoints: MaybeRef<DraggableDefaultOptions['snapPoints']>;
|
|
9
9
|
animation: MaybeRef<DraggableDefaultOptions['animation']>;
|