@maas/vue-equipment 1.0.0-beta.5 → 1.0.0-beta.7
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/composables/index.d.ts +5 -5
- package/dist/composables/index.js +14 -8
- package/dist/composables/index.js.map +1 -1
- package/dist/nuxt/module.json +1 -1
- package/dist/nuxt/module.mjs +2 -2
- package/dist/plugins/.turbo/turbo-lint.log +2 -2
- package/dist/plugins/MagicAccordion/demo/data/footer.json +1 -1
- package/dist/plugins/MagicAccordion/src/components/MagicAccordionContent.vue.d.ts +3 -3
- package/dist/plugins/MagicAccordion/src/components/MagicAccordionProvider.vue.d.ts +2 -2
- package/dist/plugins/MagicAccordion/src/components/MagicAccordionTrigger.vue +4 -5
- package/dist/plugins/MagicAccordion/src/components/MagicAccordionTrigger.vue.d.ts +3 -157
- package/dist/plugins/MagicAccordion/src/components/MagicAccordionView.vue.d.ts +2 -2
- 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 +32 -0
- package/dist/plugins/MagicCommand/src/components/MagicCommandItem.vue +0 -4
- package/dist/plugins/MagicCommand/src/components/MagicCommandItem.vue.d.ts +3 -8
- package/dist/plugins/MagicCommand/src/components/MagicCommandProvider.vue +3 -6
- package/dist/plugins/MagicCommand/src/components/MagicCommandProvider.vue.d.ts +3 -87
- package/dist/plugins/MagicCommand/src/components/MagicCommandRenderer.vue +7 -7
- package/dist/plugins/MagicCommand/src/components/MagicCommandRenderer.vue.d.ts +1 -4
- package/dist/plugins/MagicCommand/src/components/MagicCommandTrigger.vue +3 -4
- package/dist/plugins/MagicCommand/src/components/MagicCommandTrigger.vue.d.ts +3 -157
- package/dist/plugins/MagicCommand/src/components/MagicCommandView.vue.d.ts +3 -3
- 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 +3 -3
- package/dist/plugins/MagicCookie/src/components/MagicCookieView.vue.d.ts +3 -3
- package/dist/plugins/MagicCookie/src/symbols/index.d.ts +2 -2
- package/dist/plugins/MagicDraggable/src/components/MagicDraggable.vue +10 -12
- package/dist/plugins/MagicDraggable/src/components/MagicDraggable.vue.d.ts +3 -24
- package/dist/plugins/MagicDraggable/src/composables/private/useDraggableDrag.d.ts +2 -2
- package/dist/plugins/MagicDraggable/src/composables/private/useDraggableDrag.mjs +3 -3
- package/dist/plugins/MagicDraggable/src/composables/private/useDraggableScrollLock.mjs +2 -2
- package/dist/plugins/MagicDraggable/src/composables/private/useDraggableSnap.d.ts +3 -3
- package/dist/plugins/MagicDraggable/src/composables/private/useDraggableSnap.mjs +12 -15
- package/dist/plugins/MagicDraggable/src/types/index.d.ts +1 -1
- package/dist/plugins/MagicDrawer/src/components/MagicDrawer.vue +20 -21
- package/dist/plugins/MagicDrawer/src/components/MagicDrawer.vue.d.ts +188 -0
- package/dist/plugins/MagicDrawer/src/composables/private/useDrawerDOM.mjs +2 -2
- 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 +25 -0
- 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.d.ts +27 -0
- package/dist/plugins/MagicMenu/src/components/MagicMenuContent.vue +3 -6
- package/dist/plugins/MagicMenu/src/components/MagicMenuContent.vue.d.ts +56 -0
- package/dist/plugins/MagicMenu/src/components/MagicMenuFloat.vue +5 -7
- package/dist/plugins/MagicMenu/src/components/MagicMenuFloat.vue.d.ts +53 -0
- package/dist/plugins/MagicMenu/src/components/MagicMenuItem.vue +1 -12
- package/dist/plugins/MagicMenu/src/components/MagicMenuItem.vue.d.ts +3 -8
- package/dist/plugins/MagicMenu/src/components/MagicMenuProvider.vue +6 -6
- package/dist/plugins/MagicMenu/src/components/MagicMenuProvider.vue.d.ts +1 -85
- package/dist/plugins/MagicMenu/src/components/MagicMenuRemote.vue.d.ts +2 -2
- package/dist/plugins/MagicMenu/src/components/MagicMenuTrigger.vue +3 -4
- package/dist/plugins/MagicMenu/src/components/MagicMenuTrigger.vue.d.ts +3 -157
- package/dist/plugins/MagicMenu/src/components/MagicMenuView.vue.d.ts +3 -3
- 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 +2 -2
- package/dist/plugins/MagicMenu/src/composables/private/useMenuTrigger.d.ts +1 -1
- package/dist/plugins/MagicMenu/src/symbols/index.d.ts +4 -4
- package/dist/plugins/MagicModal/src/components/MagicModal.vue +6 -6
- package/dist/plugins/MagicModal/src/components/MagicModal.vue.d.ts +60 -0
- package/dist/plugins/MagicModal/src/composables/private/useModalDOM.mjs +2 -2
- package/dist/plugins/MagicNoise/src/components/MagicNoise.vue +13 -13
- package/dist/plugins/MagicNoise/src/components/MagicNoise.vue.d.ts +1 -5
- 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/MagicPlayer/src/components/MagicPlayerAudio.vue +14 -8
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerAudio.vue.d.ts +1 -4
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerAudioControls.vue +20 -20
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerAudioControls.vue.d.ts +34 -0
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerDisplayTime.vue.d.ts +1 -1
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerMuxPopover.vue +19 -8
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerMuxPopover.vue.d.ts +1 -4
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerOverlay.vue.d.ts +35 -0
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerPoster.vue.d.ts +5 -5
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerProvider.vue +3 -4
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerProvider.vue.d.ts +6 -11
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerTimeline.vue.d.ts +1 -1
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerVideo.vue +3 -4
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerVideo.vue.d.ts +1 -4
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerVideoControls.vue +23 -24
- package/dist/plugins/MagicPlayer/src/components/MagicPlayerVideoControls.vue.d.ts +73 -0
- package/dist/plugins/MagicPlayer/src/components/icons/FullscreenEnter.vue.d.ts +1 -1
- package/dist/plugins/MagicPlayer/src/components/icons/FullscreenExit.vue.d.ts +1 -1
- package/dist/plugins/MagicPlayer/src/components/icons/Pause.vue.d.ts +1 -1
- package/dist/plugins/MagicPlayer/src/components/icons/Play.vue.d.ts +1 -1
- package/dist/plugins/MagicPlayer/src/components/icons/VolumeOff.vue.d.ts +1 -1
- package/dist/plugins/MagicPlayer/src/components/icons/VolumeOn.vue.d.ts +1 -1
- package/dist/plugins/MagicPlayer/src/components/icons/Waiting.vue.d.ts +1 -1
- 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 +4 -10
- package/dist/plugins/MagicScroll/src/components/MagicScrollMotion.vue +7 -7
- package/dist/plugins/MagicScroll/src/components/MagicScrollMotion.vue.d.ts +4 -10
- package/dist/plugins/MagicScroll/src/components/MagicScrollProvider.vue.d.ts +3 -3
- package/dist/plugins/MagicScroll/src/components/MagicScrollScene.vue +18 -10
- package/dist/plugins/MagicScroll/src/components/MagicScrollScene.vue.d.ts +4 -9
- 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 +9 -10
- package/dist/plugins/MagicToast/src/components/MagicToastProvider.vue.d.ts +1 -59
- package/dist/plugins/MagicToast/src/components/MagicToastView.vue +5 -8
- package/dist/plugins/MagicToast/src/components/MagicToastView.vue.d.ts +3 -8
- package/dist/plugins/MagicToast/src/composables/private/useToastDrag.mjs +21 -21
- package/dist/plugins/MagicToast/src/composables/private/useToastScrollLock.mjs +2 -2
- package/dist/plugins/MagicToast/src/types/index.d.ts +1 -1
- package/dist/plugins/MagicToast/src/utils/defaultOptions.mjs +1 -1
- package/dist/utils/index.d.ts +2 -2
- package/dist/utils/index.js.map +1 -1
- package/package.json +3 -3
|
@@ -7,175 +7,21 @@ interface MagicMenuTriggerProps {
|
|
|
7
7
|
trigger?: Interaction[];
|
|
8
8
|
asChild?: boolean;
|
|
9
9
|
}
|
|
10
|
-
declare const elRef: import("vue").Ref<import("vue").CreateComponentPublicInstanceWithMixins<Readonly<import("vue").ExtractPropTypes<{
|
|
11
|
-
asChild: {
|
|
12
|
-
type: BooleanConstructor;
|
|
13
|
-
default: boolean;
|
|
14
|
-
};
|
|
15
|
-
as: {
|
|
16
|
-
type: import("vue").PropType<import("@maas/vue-primitive").ElementOrComponent>;
|
|
17
|
-
default: string;
|
|
18
|
-
};
|
|
19
|
-
}>>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
20
|
-
[key: string]: any;
|
|
21
|
-
}>, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {
|
|
22
|
-
asChild: boolean;
|
|
23
|
-
as: import("@maas/vue-primitive").ElementOrComponent;
|
|
24
|
-
}, true, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
|
|
25
|
-
P: {};
|
|
26
|
-
B: {};
|
|
27
|
-
D: {};
|
|
28
|
-
C: {};
|
|
29
|
-
M: {};
|
|
30
|
-
Defaults: {};
|
|
31
|
-
}, Readonly<import("vue").ExtractPropTypes<{
|
|
32
|
-
asChild: {
|
|
33
|
-
type: BooleanConstructor;
|
|
34
|
-
default: boolean;
|
|
35
|
-
};
|
|
36
|
-
as: {
|
|
37
|
-
type: import("vue").PropType<import("@maas/vue-primitive").ElementOrComponent>;
|
|
38
|
-
default: string;
|
|
39
|
-
};
|
|
40
|
-
}>>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
41
|
-
[key: string]: any;
|
|
42
|
-
}>, {}, {}, {}, {
|
|
43
|
-
asChild: boolean;
|
|
44
|
-
as: import("@maas/vue-primitive").ElementOrComponent;
|
|
45
|
-
}> | undefined, import("vue").CreateComponentPublicInstanceWithMixins<Readonly<import("vue").ExtractPropTypes<{
|
|
46
|
-
asChild: {
|
|
47
|
-
type: BooleanConstructor;
|
|
48
|
-
default: boolean;
|
|
49
|
-
};
|
|
50
|
-
as: {
|
|
51
|
-
type: import("vue").PropType<import("@maas/vue-primitive").ElementOrComponent>;
|
|
52
|
-
default: string;
|
|
53
|
-
};
|
|
54
|
-
}>>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
55
|
-
[key: string]: any;
|
|
56
|
-
}>, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {
|
|
57
|
-
asChild: boolean;
|
|
58
|
-
as: import("@maas/vue-primitive").ElementOrComponent;
|
|
59
|
-
}, true, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
|
|
60
|
-
P: {};
|
|
61
|
-
B: {};
|
|
62
|
-
D: {};
|
|
63
|
-
C: {};
|
|
64
|
-
M: {};
|
|
65
|
-
Defaults: {};
|
|
66
|
-
}, Readonly<import("vue").ExtractPropTypes<{
|
|
67
|
-
asChild: {
|
|
68
|
-
type: BooleanConstructor;
|
|
69
|
-
default: boolean;
|
|
70
|
-
};
|
|
71
|
-
as: {
|
|
72
|
-
type: import("vue").PropType<import("@maas/vue-primitive").ElementOrComponent>;
|
|
73
|
-
default: string;
|
|
74
|
-
};
|
|
75
|
-
}>>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
76
|
-
[key: string]: any;
|
|
77
|
-
}>, {}, {}, {}, {
|
|
78
|
-
asChild: boolean;
|
|
79
|
-
as: import("@maas/vue-primitive").ElementOrComponent;
|
|
80
|
-
}> | undefined>;
|
|
81
10
|
declare const mappedViewId: import("vue").ComputedRef<string | undefined>;
|
|
82
11
|
declare const view: import("../types").MenuView | undefined;
|
|
83
12
|
declare const mappedDisabled: import("vue").ComputedRef<boolean>;
|
|
84
13
|
declare const mappedTabindex: import("vue").ComputedRef<0 | undefined>;
|
|
85
14
|
declare const onMouseenter: () => void, onClick: (e: MouseEvent) => void;
|
|
86
15
|
declare const __VLS_ctx: InstanceType<__VLS_PickNotAny<typeof __VLS_self, new () => {}>>;
|
|
87
|
-
declare
|
|
88
|
-
asChild: {
|
|
89
|
-
type: BooleanConstructor;
|
|
90
|
-
default: boolean;
|
|
91
|
-
};
|
|
92
|
-
as: {
|
|
93
|
-
type: import("vue").PropType<import("@maas/vue-primitive").ElementOrComponent>;
|
|
94
|
-
default: string;
|
|
95
|
-
};
|
|
96
|
-
}, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
97
|
-
[key: string]: any;
|
|
98
|
-
}>, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
99
|
-
asChild: {
|
|
100
|
-
type: BooleanConstructor;
|
|
101
|
-
default: boolean;
|
|
102
|
-
};
|
|
103
|
-
as: {
|
|
104
|
-
type: import("vue").PropType<import("@maas/vue-primitive").ElementOrComponent>;
|
|
105
|
-
default: string;
|
|
106
|
-
};
|
|
107
|
-
}>>, {
|
|
108
|
-
asChild: boolean;
|
|
109
|
-
as: import("@maas/vue-primitive").ElementOrComponent;
|
|
110
|
-
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
111
|
-
declare const __VLS_2: import("vue/jsx-runtime").JSX.Element & {
|
|
112
|
-
__ctx?: ({
|
|
113
|
-
attrs?: any;
|
|
114
|
-
slots?: Readonly<{
|
|
115
|
-
[name: string]: import("vue").Slot<any> | undefined;
|
|
116
|
-
}> | undefined;
|
|
117
|
-
emit?: ((event: string, ...args: any[]) => void) | undefined;
|
|
118
|
-
} & {
|
|
119
|
-
props?: (Partial<{
|
|
120
|
-
asChild: boolean;
|
|
121
|
-
as: import("@maas/vue-primitive").ElementOrComponent;
|
|
122
|
-
}> & Omit<{
|
|
123
|
-
readonly asChild: boolean;
|
|
124
|
-
readonly as: import("@maas/vue-primitive").ElementOrComponent;
|
|
125
|
-
} & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, "asChild" | "as"> & Record<string, unknown>) | undefined;
|
|
126
|
-
expose?(exposed: import("vue").CreateComponentPublicInstanceWithMixins<Readonly<import("vue").ExtractPropTypes<{
|
|
127
|
-
asChild: {
|
|
128
|
-
type: BooleanConstructor;
|
|
129
|
-
default: boolean;
|
|
130
|
-
};
|
|
131
|
-
as: {
|
|
132
|
-
type: import("vue").PropType<import("@maas/vue-primitive").ElementOrComponent>;
|
|
133
|
-
default: string;
|
|
134
|
-
};
|
|
135
|
-
}>>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
136
|
-
[key: string]: any;
|
|
137
|
-
}>, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {
|
|
138
|
-
asChild: boolean;
|
|
139
|
-
as: import("@maas/vue-primitive").ElementOrComponent;
|
|
140
|
-
}, true, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
|
|
141
|
-
P: {};
|
|
142
|
-
B: {};
|
|
143
|
-
D: {};
|
|
144
|
-
C: {};
|
|
145
|
-
M: {};
|
|
146
|
-
Defaults: {};
|
|
147
|
-
}, Readonly<import("vue").ExtractPropTypes<{
|
|
148
|
-
asChild: {
|
|
149
|
-
type: BooleanConstructor;
|
|
150
|
-
default: boolean;
|
|
151
|
-
};
|
|
152
|
-
as: {
|
|
153
|
-
type: import("vue").PropType<import("@maas/vue-primitive").ElementOrComponent>;
|
|
154
|
-
default: string;
|
|
155
|
-
};
|
|
156
|
-
}>>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
157
|
-
[key: string]: any;
|
|
158
|
-
}>, {}, {}, {}, {
|
|
159
|
-
asChild: boolean;
|
|
160
|
-
as: import("@maas/vue-primitive").ElementOrComponent;
|
|
161
|
-
}>): void;
|
|
162
|
-
}) | undefined;
|
|
163
|
-
};
|
|
164
|
-
declare var __VLS_6: (Parameters<NonNullable<(typeof __VLS_5)["expose"]>>[0] | null);
|
|
165
|
-
declare var __VLS_11: {
|
|
16
|
+
declare var __VLS_13: {
|
|
166
17
|
viewActive: boolean | undefined;
|
|
167
18
|
triggerDisabled: boolean;
|
|
168
19
|
};
|
|
169
|
-
declare var __VLS_5: __VLS_PickFunctionalComponentCtx<typeof __VLS_0, typeof __VLS_2>;
|
|
170
20
|
type __VLS_Slots = __VLS_PrettifyGlobal<__VLS_OmitStringIndex<typeof __VLS_ctx.$slots> & {
|
|
171
|
-
default?: (props: typeof
|
|
21
|
+
default?: (props: typeof __VLS_13) => any;
|
|
172
22
|
}>;
|
|
173
|
-
type __VLS_TemplateRefs = {
|
|
174
|
-
elRef: typeof __VLS_6;
|
|
175
|
-
};
|
|
176
23
|
declare const __VLS_self: import("vue").DefineComponent<MagicMenuTriggerProps, {
|
|
177
24
|
Primitive: typeof Primitive;
|
|
178
|
-
elRef: typeof elRef;
|
|
179
25
|
mappedViewId: typeof mappedViewId;
|
|
180
26
|
view: typeof view;
|
|
181
27
|
mappedDisabled: typeof mappedDisabled;
|
|
@@ -183,7 +29,7 @@ declare const __VLS_self: import("vue").DefineComponent<MagicMenuTriggerProps, {
|
|
|
183
29
|
onMouseenter: typeof onMouseenter;
|
|
184
30
|
onClick: typeof onClick;
|
|
185
31
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicMenuTriggerProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
186
|
-
declare const __VLS_component: import("vue").DefineComponent<MagicMenuTriggerProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicMenuTriggerProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false,
|
|
32
|
+
declare const __VLS_component: import("vue").DefineComponent<MagicMenuTriggerProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicMenuTriggerProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
187
33
|
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
188
34
|
export default _default;
|
|
189
35
|
type __VLS_WithSlots<T, S> = T & {
|
|
@@ -6,17 +6,17 @@ interface MagicMenuViewProps {
|
|
|
6
6
|
declare const mappedId: import("vue").ComputedRef<string>;
|
|
7
7
|
declare const view: import("../types").MenuView;
|
|
8
8
|
declare const __VLS_ctx: InstanceType<__VLS_PickNotAny<typeof __VLS_self, new () => {}>>;
|
|
9
|
-
declare var
|
|
9
|
+
declare var __VLS_1: {
|
|
10
10
|
viewActive: boolean;
|
|
11
11
|
};
|
|
12
12
|
type __VLS_Slots = __VLS_PrettifyGlobal<__VLS_OmitStringIndex<typeof __VLS_ctx.$slots> & {
|
|
13
|
-
default?: (props: typeof
|
|
13
|
+
default?: (props: typeof __VLS_1) => any;
|
|
14
14
|
}>;
|
|
15
15
|
declare const __VLS_self: import("vue").DefineComponent<MagicMenuViewProps, {
|
|
16
16
|
mappedId: typeof mappedId;
|
|
17
17
|
view: typeof view;
|
|
18
18
|
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicMenuViewProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
19
|
-
declare const __VLS_component: import("vue").DefineComponent<MagicMenuViewProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicMenuViewProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {},
|
|
19
|
+
declare const __VLS_component: import("vue").DefineComponent<MagicMenuViewProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicMenuViewProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
20
20
|
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
21
21
|
export default _default;
|
|
22
22
|
type __VLS_WithSlots<T, S> = T & {
|
|
@@ -7,9 +7,9 @@ export declare function useMenuCursor(view: MenuView, debug?: boolean): {
|
|
|
7
7
|
x: number;
|
|
8
8
|
y: number;
|
|
9
9
|
}[]>;
|
|
10
|
-
isInsideFrom: import("vue").
|
|
11
|
-
isInsideTo: import("vue").
|
|
12
|
-
isInsideTriangle: import("vue").
|
|
10
|
+
isInsideFrom: import("vue").ShallowRef<boolean, boolean>;
|
|
11
|
+
isInsideTo: import("vue").ShallowRef<boolean, boolean>;
|
|
12
|
+
isInsideTriangle: import("vue").ShallowRef<boolean, boolean>;
|
|
13
13
|
initialize: () => void;
|
|
14
14
|
destroy: () => void;
|
|
15
15
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ref } from "vue";
|
|
1
|
+
import { ref, shallowRef } from "vue";
|
|
2
2
|
import { useEventListener } from "@vueuse/core";
|
|
3
3
|
export function useMenuCursor(view, debug = false) {
|
|
4
4
|
let cancelListener = new AbortController();
|
|
@@ -7,9 +7,9 @@ export function useMenuCursor(view, debug = false) {
|
|
|
7
7
|
{ x: 0, y: 0 },
|
|
8
8
|
{ x: 0, y: 0 }
|
|
9
9
|
]);
|
|
10
|
-
const isInsideFrom =
|
|
11
|
-
const isInsideTo =
|
|
12
|
-
const isInsideTriangle =
|
|
10
|
+
const isInsideFrom = shallowRef(false);
|
|
11
|
+
const isInsideTo = shallowRef(false);
|
|
12
|
+
const isInsideTriangle = shallowRef(false);
|
|
13
13
|
function extendTriangle(vertices, pixelAmount) {
|
|
14
14
|
const [a, b, c] = vertices;
|
|
15
15
|
switch (view?.placement) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { ref } from "vue";
|
|
1
|
+
import { ref, shallowRef } from "vue";
|
|
2
2
|
import { useScrollLock } from "@vueuse/core";
|
|
3
3
|
import { matchClass } from "@maas/vue-equipment/utils";
|
|
4
|
-
const scrollLock = typeof window !== "undefined" ? useScrollLock(document?.documentElement) :
|
|
4
|
+
const scrollLock = typeof window !== "undefined" ? useScrollLock(document?.documentElement) : shallowRef(false);
|
|
5
5
|
export function useMenuDOM() {
|
|
6
6
|
const positionFixedElements = ref([]);
|
|
7
7
|
function lockScroll() {
|
|
@@ -7,7 +7,7 @@ type UseMenuTriggerArgs = {
|
|
|
7
7
|
itemId?: string;
|
|
8
8
|
mappedDisabled: ComputedRef<boolean>;
|
|
9
9
|
mappedTrigger: ComputedRef<Interaction[]>;
|
|
10
|
-
elRef: Ref<InstanceType<typeof Primitive> |
|
|
10
|
+
elRef: Ref<InstanceType<typeof Primitive> | null>;
|
|
11
11
|
};
|
|
12
12
|
export declare function useMenuTrigger(args: UseMenuTriggerArgs): {
|
|
13
13
|
onMouseenter: () => void;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import type { InjectionKey, MaybeRef } from 'vue';
|
|
1
|
+
import type { InjectionKey, MaybeRef, Ref } from 'vue';
|
|
2
2
|
declare const MagicMenuInstanceId: InjectionKey<MaybeRef<string>>;
|
|
3
3
|
declare const MagicMenuParentTree: InjectionKey<string[]>;
|
|
4
4
|
declare const MagicMenuViewId: InjectionKey<string>;
|
|
5
|
-
declare const MagicMenuViewActive: InjectionKey<
|
|
5
|
+
declare const MagicMenuViewActive: InjectionKey<Ref<boolean>>;
|
|
6
6
|
declare const MagicMenuContentId: InjectionKey<string>;
|
|
7
7
|
declare const MagicMenuItemId: InjectionKey<string>;
|
|
8
|
-
declare const MagicMenuItemActive: InjectionKey<
|
|
8
|
+
declare const MagicMenuItemActive: InjectionKey<Ref<boolean>>;
|
|
9
9
|
declare const MagicMenuChannelId: InjectionKey<string>;
|
|
10
|
-
declare const MagicMenuChannelActive: InjectionKey<
|
|
10
|
+
declare const MagicMenuChannelActive: InjectionKey<Ref<boolean>>;
|
|
11
11
|
export { MagicMenuInstanceId, MagicMenuParentTree, MagicMenuViewId, MagicMenuViewActive, MagicMenuContentId, MagicMenuItemId, MagicMenuItemActive, MagicMenuChannelId, MagicMenuChannelActive, };
|
|
@@ -3,7 +3,8 @@ import { defineComponent as _defineComponent } from "vue";
|
|
|
3
3
|
import { unref as _unref, renderSlot as _renderSlot, vShow as _vShow, withModifiers as _withModifiers, createElementVNode as _createElementVNode, withDirectives as _withDirectives, Transition as _Transition, withCtx as _withCtx, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, resolveDynamicComponent as _resolveDynamicComponent, createVNode as _createVNode, mergeProps as _mergeProps, Teleport as _Teleport } from "vue";
|
|
4
4
|
const _hoisted_1 = ["data-id"];
|
|
5
5
|
import {
|
|
6
|
-
|
|
6
|
+
useTemplateRef,
|
|
7
|
+
shallowRef,
|
|
7
8
|
watch,
|
|
8
9
|
nextTick,
|
|
9
10
|
toValue,
|
|
@@ -36,7 +37,7 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
36
37
|
}
|
|
37
38
|
});
|
|
38
39
|
const mappedOptions = customDefu(__props.options, defaultOptions);
|
|
39
|
-
const modalRef =
|
|
40
|
+
const modalRef = useTemplateRef("modal");
|
|
40
41
|
const {
|
|
41
42
|
trapFocus,
|
|
42
43
|
releaseFocus,
|
|
@@ -49,8 +50,8 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
49
50
|
focusTrap: mappedOptions.focusTrap
|
|
50
51
|
});
|
|
51
52
|
const { isActive, close } = useMagicModal(__props.id);
|
|
52
|
-
const innerActive =
|
|
53
|
-
const wrapperActive =
|
|
53
|
+
const innerActive = shallowRef(false);
|
|
54
|
+
const wrapperActive = shallowRef(false);
|
|
54
55
|
const {
|
|
55
56
|
onBeforeEnter,
|
|
56
57
|
onEnter,
|
|
@@ -113,8 +114,7 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
113
114
|
disabled: _unref(mappedOptions).teleport?.disabled
|
|
114
115
|
}, [
|
|
115
116
|
_createElementVNode("div", _mergeProps({
|
|
116
|
-
|
|
117
|
-
ref: modalRef,
|
|
117
|
+
ref: "modal",
|
|
118
118
|
class: "magic-modal",
|
|
119
119
|
"data-id": toValue(_ctx.id)
|
|
120
120
|
}, _ctx.$attrs, {
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { toValue, type MaybeRef } from 'vue';
|
|
2
|
+
import type { MagicModalOptions } from './../types/index.js';
|
|
3
|
+
import '@maas/vue-equipment/utils/css/animations/fade-in.css';
|
|
4
|
+
import '@maas/vue-equipment/utils/css/animations/fade-out.css';
|
|
5
|
+
interface MagicModalProps {
|
|
6
|
+
id: MaybeRef<string>;
|
|
7
|
+
props?: Record<string, unknown>;
|
|
8
|
+
options?: MagicModalOptions;
|
|
9
|
+
}
|
|
10
|
+
declare const mappedOptions: Omit<MagicModalOptions, keyof MagicModalOptions> & Omit<import("../../../../utils").RequireAll<MagicModalOptions>, keyof MagicModalOptions> & {
|
|
11
|
+
transition: {
|
|
12
|
+
content?: string;
|
|
13
|
+
backdrop?: string;
|
|
14
|
+
};
|
|
15
|
+
backdrop: boolean;
|
|
16
|
+
tag: "dialog" | "div";
|
|
17
|
+
focusTrap: boolean | import("focus-trap").Options;
|
|
18
|
+
scrollLock: boolean | {
|
|
19
|
+
padding: boolean;
|
|
20
|
+
};
|
|
21
|
+
teleport: {
|
|
22
|
+
target?: string;
|
|
23
|
+
disabled?: boolean;
|
|
24
|
+
};
|
|
25
|
+
keyListener: {
|
|
26
|
+
close?: string[] | false;
|
|
27
|
+
};
|
|
28
|
+
};
|
|
29
|
+
declare const close: () => void;
|
|
30
|
+
declare const innerActive: import("vue").ShallowRef<boolean, boolean>;
|
|
31
|
+
declare const wrapperActive: import("vue").ShallowRef<boolean, boolean>;
|
|
32
|
+
declare const onBeforeEnter: () => void, onEnter: () => void, onAfterEnter: () => Promise<void>, onBeforeLeave: () => void, onLeave: () => void, onAfterLeave: () => void;
|
|
33
|
+
declare const __VLS_ctx: InstanceType<__VLS_PickNotAny<typeof __VLS_self, new () => {}>>;
|
|
34
|
+
declare var __VLS_9: {}, __VLS_32: {};
|
|
35
|
+
type __VLS_Slots = __VLS_PrettifyGlobal<__VLS_OmitStringIndex<typeof __VLS_ctx.$slots> & {
|
|
36
|
+
backdrop?: (props: typeof __VLS_9) => any;
|
|
37
|
+
} & {
|
|
38
|
+
default?: (props: typeof __VLS_32) => any;
|
|
39
|
+
}>;
|
|
40
|
+
declare const __VLS_self: import("vue").DefineComponent<MagicModalProps, {
|
|
41
|
+
toValue: typeof toValue;
|
|
42
|
+
mappedOptions: typeof mappedOptions;
|
|
43
|
+
close: typeof close;
|
|
44
|
+
innerActive: typeof innerActive;
|
|
45
|
+
wrapperActive: typeof wrapperActive;
|
|
46
|
+
onBeforeEnter: typeof onBeforeEnter;
|
|
47
|
+
onEnter: typeof onEnter;
|
|
48
|
+
onAfterEnter: typeof onAfterEnter;
|
|
49
|
+
onBeforeLeave: typeof onBeforeLeave;
|
|
50
|
+
onLeave: typeof onLeave;
|
|
51
|
+
onAfterLeave: typeof onAfterLeave;
|
|
52
|
+
}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicModalProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
53
|
+
declare const __VLS_component: import("vue").DefineComponent<MagicModalProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicModalProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
54
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
55
|
+
export default _default;
|
|
56
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
57
|
+
new (): {
|
|
58
|
+
$slots: S;
|
|
59
|
+
};
|
|
60
|
+
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ref } from "vue";
|
|
1
|
+
import { ref, shallowRef } from "vue";
|
|
2
2
|
import { defu } from "defu";
|
|
3
3
|
import { useScrollLock } from "@vueuse/core";
|
|
4
4
|
import { useFocusTrap } from "@vueuse/integrations/useFocusTrap";
|
|
@@ -8,7 +8,7 @@ const defaultOptions = {
|
|
|
8
8
|
focusTarget: void 0,
|
|
9
9
|
scrollLock: true
|
|
10
10
|
};
|
|
11
|
-
const scrollLock = typeof window !== "undefined" ? useScrollLock(document?.documentElement) :
|
|
11
|
+
const scrollLock = typeof window !== "undefined" ? useScrollLock(document?.documentElement) : shallowRef(false);
|
|
12
12
|
export function useModalDOM(args) {
|
|
13
13
|
const positionFixedElements = ref([]);
|
|
14
14
|
const mappedOptions = defu(args, defaultOptions);
|
|
@@ -3,7 +3,15 @@ import { defineComponent as _defineComponent } from "vue";
|
|
|
3
3
|
import { unref as _unref, createElementVNode as _createElementVNode, openBlock as _openBlock, createElementBlock as _createElementBlock } from "vue";
|
|
4
4
|
const _hoisted_1 = ["data-loading"];
|
|
5
5
|
const _hoisted_2 = { class: "magic-noise__inner" };
|
|
6
|
-
|
|
6
|
+
const _hoisted_3 = {
|
|
7
|
+
ref: "canvas",
|
|
8
|
+
class: "magic-noise__canvas"
|
|
9
|
+
};
|
|
10
|
+
const _hoisted_4 = {
|
|
11
|
+
ref: "offCanvas",
|
|
12
|
+
class: "magic-noise__off-canvas"
|
|
13
|
+
};
|
|
14
|
+
import { onMounted, onUnmounted, watch, useTemplateRef } from "vue";
|
|
7
15
|
import { useResizeObserver, useDebounceFn } from "@vueuse/core";
|
|
8
16
|
import { useNoiseApi } from "../composables/private/useNoiseApi";
|
|
9
17
|
export default /* @__PURE__ */ _defineComponent({
|
|
@@ -13,8 +21,8 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
13
21
|
pause: { type: Boolean, required: false, default: false }
|
|
14
22
|
},
|
|
15
23
|
setup(__props) {
|
|
16
|
-
const canvasRef =
|
|
17
|
-
const offCanvasRef =
|
|
24
|
+
const canvasRef = useTemplateRef("canvas");
|
|
25
|
+
const offCanvasRef = useTemplateRef("offCanvas");
|
|
18
26
|
const noiseApi = useNoiseApi({
|
|
19
27
|
canvasRef,
|
|
20
28
|
offCanvasRef,
|
|
@@ -58,22 +66,14 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
58
66
|
_createElementVNode("div", _hoisted_2, [
|
|
59
67
|
_createElementVNode(
|
|
60
68
|
"canvas",
|
|
61
|
-
|
|
62
|
-
ref_key: "canvasRef",
|
|
63
|
-
ref: canvasRef,
|
|
64
|
-
class: "magic-noise__canvas"
|
|
65
|
-
},
|
|
69
|
+
_hoisted_3,
|
|
66
70
|
null,
|
|
67
71
|
512
|
|
68
72
|
/* NEED_PATCH */
|
|
69
73
|
),
|
|
70
74
|
_createElementVNode(
|
|
71
75
|
"canvas",
|
|
72
|
-
|
|
73
|
-
ref_key: "offCanvasRef",
|
|
74
|
-
ref: offCanvasRef,
|
|
75
|
-
class: "magic-noise__off-canvas"
|
|
76
|
-
},
|
|
76
|
+
_hoisted_4,
|
|
77
77
|
null,
|
|
78
78
|
512
|
|
79
79
|
/* NEED_PATCH */
|
|
@@ -3,9 +3,5 @@ interface MagicNoiseProps {
|
|
|
3
3
|
options?: MagicNoiseOptions;
|
|
4
4
|
pause?: boolean;
|
|
5
5
|
}
|
|
6
|
-
|
|
7
|
-
canvasRef: typeof __VLS_nativeElements['canvas'];
|
|
8
|
-
offCanvasRef: typeof __VLS_nativeElements['canvas'];
|
|
9
|
-
};
|
|
10
|
-
declare const _default: import("vue").DefineComponent<MagicNoiseProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicNoiseProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, __VLS_TemplateRefs, HTMLDivElement>;
|
|
6
|
+
declare const _default: import("vue").DefineComponent<MagicNoiseProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<MagicNoiseProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
11
7
|
export default _default;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { type Ref, type MaybeRef } from 'vue';
|
|
2
2
|
import type { MagicNoiseOptions, RafControls } from '../../types/index.js';
|
|
3
3
|
type UseNoiseApiArgs = {
|
|
4
|
-
canvasRef: Ref<HTMLCanvasElement |
|
|
5
|
-
offCanvasRef: Ref<HTMLCanvasElement |
|
|
4
|
+
canvasRef: Ref<HTMLCanvasElement | null>;
|
|
5
|
+
offCanvasRef: Ref<HTMLCanvasElement | null>;
|
|
6
6
|
options?: MaybeRef<MagicNoiseOptions>;
|
|
7
7
|
};
|
|
8
8
|
export declare function useNoiseApi({ canvasRef, offCanvasRef, options, }: UseNoiseApiArgs): {
|
|
@@ -11,7 +11,7 @@ export declare function useNoiseApi({ canvasRef, offCanvasRef, options, }: UseNo
|
|
|
11
11
|
rotateAndTransfer: () => void;
|
|
12
12
|
throttledDraw: () => void;
|
|
13
13
|
throttledRotateAndTransfer: () => void;
|
|
14
|
-
isReady:
|
|
14
|
+
isReady: import("vue").ShallowRef<boolean, boolean>;
|
|
15
15
|
drawControls: import("vue").ShallowRef<RafControls | undefined, RafControls | undefined>;
|
|
16
16
|
transferControls: import("vue").ShallowRef<RafControls | undefined, RafControls | undefined>;
|
|
17
17
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { shallowRef,
|
|
1
|
+
import { shallowRef, reactive } from "vue";
|
|
2
2
|
import { defu } from "defu";
|
|
3
3
|
import {
|
|
4
4
|
useElementSize,
|
|
@@ -14,7 +14,7 @@ export function useNoiseApi({
|
|
|
14
14
|
}) {
|
|
15
15
|
const tiles = shallowRef([]);
|
|
16
16
|
const pixels = shallowRef([]);
|
|
17
|
-
const isReady =
|
|
17
|
+
const isReady = shallowRef(false);
|
|
18
18
|
const context = shallowRef(null);
|
|
19
19
|
const offContext = shallowRef(null);
|
|
20
20
|
const { width, height } = useElementSize(canvasRef);
|
|
@@ -1,7 +1,17 @@
|
|
|
1
1
|
<script>
|
|
2
2
|
import { defineComponent as _defineComponent } from "vue";
|
|
3
3
|
import { openBlock as _openBlock, createElementBlock as _createElementBlock } from "vue";
|
|
4
|
-
|
|
4
|
+
const _hoisted_1 = {
|
|
5
|
+
ref: "el",
|
|
6
|
+
class: "magic-player-audio"
|
|
7
|
+
};
|
|
8
|
+
import {
|
|
9
|
+
useTemplateRef,
|
|
10
|
+
shallowRef,
|
|
11
|
+
inject,
|
|
12
|
+
onMounted,
|
|
13
|
+
onBeforeUnmount
|
|
14
|
+
} from "vue";
|
|
5
15
|
import { useIntersectionObserver } from "@vueuse/core";
|
|
6
16
|
import { usePlayerAudioApi } from "../composables/private/usePlayerAudioApi";
|
|
7
17
|
import { usePlayerMediaApi } from "../composables/private/usePlayerMediaApi";
|
|
@@ -18,8 +28,8 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
18
28
|
if (!injectedOptions) {
|
|
19
29
|
throw new Error("MagicPlayerVideo must be used within a MagicPlayerProvider");
|
|
20
30
|
}
|
|
21
|
-
const elRef =
|
|
22
|
-
const pausedByIntersection =
|
|
31
|
+
const elRef = useTemplateRef("el");
|
|
32
|
+
const pausedByIntersection = shallowRef(false);
|
|
23
33
|
const { initialize, destroy } = usePlayerRuntime({
|
|
24
34
|
id: injectedId,
|
|
25
35
|
mediaRef: elRef,
|
|
@@ -57,11 +67,7 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
57
67
|
return (_ctx, _cache) => {
|
|
58
68
|
return _openBlock(), _createElementBlock(
|
|
59
69
|
"audio",
|
|
60
|
-
|
|
61
|
-
ref_key: "elRef",
|
|
62
|
-
ref: elRef,
|
|
63
|
-
class: "magic-player-audio"
|
|
64
|
-
},
|
|
70
|
+
_hoisted_1,
|
|
65
71
|
null,
|
|
66
72
|
512
|
|
67
73
|
/* NEED_PATCH */
|
|
@@ -1,5 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
elRef: typeof __VLS_nativeElements['audio'];
|
|
3
|
-
};
|
|
4
|
-
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, __VLS_TemplateRefs, HTMLAudioElement>;
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
5
2
|
export default _default;
|
|
@@ -4,22 +4,30 @@ import { unref as _unref, renderSlot as _renderSlot, createVNode as _createVNode
|
|
|
4
4
|
const _hoisted_1 = ["data-touched", "data-playing", "data-paused", "data-waiting", "data-idle", "data-hover"];
|
|
5
5
|
const _hoisted_2 = { class: "magic-player-audio-controls__bar" };
|
|
6
6
|
const _hoisted_3 = {
|
|
7
|
+
ref: "bar",
|
|
8
|
+
class: "magic-player-audio-controls__bar--inner"
|
|
9
|
+
};
|
|
10
|
+
const _hoisted_4 = {
|
|
7
11
|
class: "magic-player-audio-controls__item -shrink-0",
|
|
8
12
|
"data-slot": "play-toggle"
|
|
9
13
|
};
|
|
10
|
-
const
|
|
14
|
+
const _hoisted_5 = {
|
|
11
15
|
class: "magic-player-audio-controls__item -shrink-0",
|
|
12
16
|
"data-slot": "display-time-current"
|
|
13
17
|
};
|
|
14
|
-
const
|
|
18
|
+
const _hoisted_6 = {
|
|
15
19
|
class: "magic-player-audio-controls__item -grow",
|
|
16
20
|
"data-slot": "timeline"
|
|
17
21
|
};
|
|
18
|
-
const
|
|
22
|
+
const _hoisted_7 = {
|
|
23
|
+
ref: "track",
|
|
24
|
+
class: "magic-player-audio-controls__timeline"
|
|
25
|
+
};
|
|
26
|
+
const _hoisted_8 = {
|
|
19
27
|
class: "magic-player-audio-controls__item -shrink-0",
|
|
20
28
|
"data-slot": "display-time-duration"
|
|
21
29
|
};
|
|
22
|
-
import { computed,
|
|
30
|
+
import { computed, inject, provide, useTemplateRef } from "vue";
|
|
23
31
|
import { useIdle } from "@vueuse/core";
|
|
24
32
|
import { usePlayerMediaApi } from "../composables/private/usePlayerMediaApi";
|
|
25
33
|
import { usePlayerAudioApi } from "../composables/private/usePlayerAudioApi";
|
|
@@ -40,8 +48,8 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
40
48
|
"MagicAudioPlayerControls must be nested inside MagicAudioPlayer or be passed an id as a prop."
|
|
41
49
|
);
|
|
42
50
|
}
|
|
43
|
-
const barRef =
|
|
44
|
-
const trackRef =
|
|
51
|
+
const barRef = useTemplateRef("bar");
|
|
52
|
+
const trackRef = useTemplateRef("track");
|
|
45
53
|
const { playing, waiting } = usePlayerMediaApi({
|
|
46
54
|
id: mappedId.value
|
|
47
55
|
});
|
|
@@ -70,13 +78,9 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
70
78
|
_createElementVNode("div", _hoisted_2, [
|
|
71
79
|
_createElementVNode(
|
|
72
80
|
"div",
|
|
73
|
-
|
|
74
|
-
ref_key: "barRef",
|
|
75
|
-
ref: barRef,
|
|
76
|
-
class: "magic-player-audio-controls__bar--inner"
|
|
77
|
-
},
|
|
81
|
+
_hoisted_3,
|
|
78
82
|
[
|
|
79
|
-
_createElementVNode("div",
|
|
83
|
+
_createElementVNode("div", _hoisted_4, [
|
|
80
84
|
!_unref(playing) ? (_openBlock(), _createElementBlock("button", {
|
|
81
85
|
key: 0,
|
|
82
86
|
onClick: _cache[0] || (_cache[0] = //@ts-ignore
|
|
@@ -95,17 +99,13 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
95
99
|
])
|
|
96
100
|
]))
|
|
97
101
|
]),
|
|
98
|
-
_createElementVNode("div",
|
|
102
|
+
_createElementVNode("div", _hoisted_5, [
|
|
99
103
|
_createVNode(_component_magic_player_display_time, { type: "current" })
|
|
100
104
|
]),
|
|
101
|
-
_createElementVNode("div",
|
|
105
|
+
_createElementVNode("div", _hoisted_6, [
|
|
102
106
|
_createElementVNode(
|
|
103
107
|
"div",
|
|
104
|
-
|
|
105
|
-
ref_key: "trackRef",
|
|
106
|
-
ref: trackRef,
|
|
107
|
-
class: "magic-player-audio-controls__timeline"
|
|
108
|
-
},
|
|
108
|
+
_hoisted_7,
|
|
109
109
|
[
|
|
110
110
|
_createVNode(_component_magic_player_timeline)
|
|
111
111
|
],
|
|
@@ -113,7 +113,7 @@ export default /* @__PURE__ */ _defineComponent({
|
|
|
113
113
|
/* NEED_PATCH */
|
|
114
114
|
)
|
|
115
115
|
]),
|
|
116
|
-
_createElementVNode("div",
|
|
116
|
+
_createElementVNode("div", _hoisted_8, [
|
|
117
117
|
_createVNode(_component_magic_player_display_time, { type: "duration" })
|
|
118
118
|
])
|
|
119
119
|
],
|