@maas/vue-equipment 1.0.0-beta.14 → 1.0.0-beta.15

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.
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@maas/vue-equipment/nuxt",
3
3
  "configKey": "vueEquipment",
4
- "version": "1.0.0-beta.13",
4
+ "version": "1.0.0-beta.14",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "0.8.4",
7
7
  "unbuild": "unknown"
@@ -1,6 +1,6 @@
1
1
  <template>
2
2
  <div
3
- :data-id="toValue(id)"
3
+ :data-id="mappedId"
4
4
  :data-dragging="dragging"
5
5
  :data-disabled="disabled"
6
6
  class="magic-draggable"
@@ -23,7 +23,7 @@
23
23
  </template>
24
24
 
25
25
  <script setup>
26
- import { useTemplateRef, computed, toRefs } from "vue";
26
+ import { useTemplateRef, computed, toValue, toRefs } from "vue";
27
27
  import { defu } from "defu";
28
28
  import { useDraggableDrag } from "../composables/private/useDraggableDrag";
29
29
  import { useDraggableState } from "../composables/private/useDraggableState";
@@ -42,6 +42,7 @@ const { id, options = {} } = defineProps({
42
42
  }
43
43
  });
44
44
  const mappedOptions = defu(options, defaultOptions);
45
+ const mappedId = toValue(id);
45
46
  const elRef = useTemplateRef("el");
46
47
  const wrapperRef = useTemplateRef("wrapper");
47
48
  const { initializeState } = useDraggableState(id);
@@ -1,4 +1,4 @@
1
- import { toValue, type MaybeRef } from 'vue';
1
+ import { type MaybeRef } from 'vue';
2
2
  import type { MagicDraggableOptions } from '../types/index.js';
3
3
  interface MagicDraggableProps {
4
4
  id: MaybeRef<string>;
@@ -36,6 +36,10 @@ declare const mappedOptions: Omit<MagicDraggableOptions, keyof MagicDraggableOpt
36
36
  momentum: number;
37
37
  idle: number;
38
38
  });
39
+ tag: "dialog" | "div";
40
+ scrollLock: boolean | {
41
+ padding: boolean;
42
+ };
39
43
  disabled: boolean;
40
44
  animation: ({
41
45
  snap?: {
@@ -68,15 +72,12 @@ declare const mappedOptions: Omit<MagicDraggableOptions, keyof MagicDraggableOpt
68
72
  easing?: (t: number) => number;
69
73
  };
70
74
  });
71
- tag: "div" | "dialog";
72
- scrollLock: boolean | {
73
- padding: boolean;
74
- };
75
75
  snapPoints: import("../types/index.js").DraggableSnapPoint[];
76
76
  initial: {
77
77
  snapPoint?: import("../types/index.js").DraggableSnapPoint;
78
78
  };
79
79
  };
80
+ declare const mappedId: string;
80
81
  declare const dragging: import("vue").Ref<boolean, boolean>;
81
82
  declare const disabled: import("vue").ComputedRef<boolean>;
82
83
  declare const style: import("vue").ComputedRef<string>, hasDragged: import("vue").ComputedRef<boolean>;
@@ -88,8 +89,8 @@ type __VLS_Slots = __VLS_PrettifyGlobal<__VLS_OmitStringIndex<typeof __VLS_ctx.$
88
89
  default?: (props: typeof __VLS_12) => any;
89
90
  }>;
90
91
  declare const __VLS_self: import("vue").DefineComponent<MagicDraggableProps, {
91
- toValue: typeof toValue;
92
92
  mappedOptions: typeof mappedOptions;
93
+ mappedId: typeof mappedId;
93
94
  dragging: typeof dragging;
94
95
  disabled: typeof disabled;
95
96
  style: typeof style;
@@ -7,7 +7,7 @@
7
7
  <div
8
8
  ref="drawer"
9
9
  class="magic-drawer"
10
- :data-id="toValue(id)"
10
+ :data-id="mappedId"
11
11
  :data-dragging="dragging"
12
12
  :data-wheeling="wheeling"
13
13
  :data-disabled="disabled"
@@ -64,6 +64,7 @@ import {
64
64
  watch,
65
65
  computed,
66
66
  nextTick,
67
+ toValue,
67
68
  onBeforeMount,
68
69
  onBeforeUnmount,
69
70
  onUnmounted,
@@ -110,6 +111,7 @@ const { options = {}, id } = defineProps({
110
111
  }
111
112
  });
112
113
  const mappedOptions = customDefu(options, defaultOptions);
114
+ const mappedId = toValue(id);
113
115
  const elRef = useTemplateRef("el");
114
116
  const drawerRef = useTemplateRef("drawer");
115
117
  const wrapperRef = useTemplateRef("wrapper");
@@ -1,4 +1,4 @@
1
- import { toValue, type MaybeRef } from 'vue';
1
+ import { type MaybeRef } from 'vue';
2
2
  import type { MagicDrawerOptions } from '../types/index.js';
3
3
  import '@maas/vue-equipment/utils/css/animations/fade-in.css';
4
4
  import '@maas/vue-equipment/utils/css/animations/fade-out.css';
@@ -40,44 +40,8 @@ declare const mappedOptions: Omit<MagicDrawerOptions, keyof MagicDrawerOptions>
40
40
  distance: number;
41
41
  momentum: number;
42
42
  });
43
- transition: {
44
- content?: string;
45
- backdrop?: string;
46
- };
47
- disabled: boolean;
48
- animation: ({
49
- snap?: {
50
- duration?: number;
51
- easing?: (t: number) => number;
52
- };
53
- } & import("../../../../utils/index.js").RequireAll<{
54
- snap?: {
55
- duration?: number;
56
- easing?: (t: number) => number;
57
- };
58
- }>) | (Omit<{
59
- snap?: {
60
- duration?: number;
61
- easing?: (t: number) => number;
62
- };
63
- }, "snap"> & Omit<{
64
- snap?: {
65
- duration?: number;
66
- easing?: (t: number) => number;
67
- };
68
- } & import("../../../../utils/index.js").RequireAll<{
69
- snap?: {
70
- duration?: number;
71
- easing?: (t: number) => number;
72
- };
73
- }>, "snap"> & {
74
- snap: {
75
- duration?: number;
76
- easing?: (t: number) => number;
77
- };
78
- });
79
43
  backdrop: boolean;
80
- tag: "div" | "dialog";
44
+ tag: "dialog" | "div";
81
45
  focusTrap: boolean | import("focus-trap").Options;
82
46
  scrollLock: {
83
47
  padding: boolean;
@@ -114,6 +78,10 @@ declare const mappedOptions: Omit<MagicDrawerOptions, keyof MagicDrawerOptions>
114
78
  target?: string;
115
79
  disabled?: boolean;
116
80
  };
81
+ transition: {
82
+ content?: string;
83
+ backdrop?: string;
84
+ };
117
85
  keyListener: ({
118
86
  close?: string[] | false;
119
87
  } & import("../../../../utils/index.js").RequireAll<{
@@ -128,6 +96,38 @@ declare const mappedOptions: Omit<MagicDrawerOptions, keyof MagicDrawerOptions>
128
96
  close: (false | string[] | undefined) & (false | string[]);
129
97
  });
130
98
  position: "right" | "left" | "top" | "bottom";
99
+ disabled: boolean;
100
+ animation: ({
101
+ snap?: {
102
+ duration?: number;
103
+ easing?: (t: number) => number;
104
+ };
105
+ } & import("../../../../utils/index.js").RequireAll<{
106
+ snap?: {
107
+ duration?: number;
108
+ easing?: (t: number) => number;
109
+ };
110
+ }>) | (Omit<{
111
+ snap?: {
112
+ duration?: number;
113
+ easing?: (t: number) => number;
114
+ };
115
+ }, "snap"> & Omit<{
116
+ snap?: {
117
+ duration?: number;
118
+ easing?: (t: number) => number;
119
+ };
120
+ } & import("../../../../utils/index.js").RequireAll<{
121
+ snap?: {
122
+ duration?: number;
123
+ easing?: (t: number) => number;
124
+ };
125
+ }>, "snap"> & {
126
+ snap: {
127
+ duration?: number;
128
+ easing?: (t: number) => number;
129
+ };
130
+ });
131
131
  snapPoints: import("../types/index.js").DrawerSnapPoint[];
132
132
  initial: {
133
133
  open?: boolean;
@@ -138,6 +138,7 @@ declare const mappedOptions: Omit<MagicDrawerOptions, keyof MagicDrawerOptions>
138
138
  preventZoom: boolean;
139
139
  preventDragClose: boolean;
140
140
  };
141
+ declare const mappedId: string;
141
142
  declare const disabled: import("vue").ComputedRef<boolean>;
142
143
  declare const style: import("vue").ComputedRef<string>, hasDragged: import("vue").ComputedRef<boolean>;
143
144
  declare const dragging: import("vue").Ref<boolean, boolean>, wheeling: import("vue").Ref<boolean, boolean>;
@@ -157,8 +158,8 @@ type __VLS_Slots = __VLS_PrettifyGlobal<__VLS_OmitStringIndex<typeof __VLS_ctx.$
157
158
  default?: (props: typeof __VLS_35) => any;
158
159
  }>;
159
160
  declare const __VLS_self: import("vue").DefineComponent<MagicDrawerProps, {
160
- toValue: typeof toValue;
161
161
  mappedOptions: typeof mappedOptions;
162
+ mappedId: typeof mappedId;
162
163
  disabled: typeof disabled;
163
164
  style: typeof style;
164
165
  hasDragged: typeof hasDragged;
@@ -7,7 +7,7 @@
7
7
  <div
8
8
  ref="modal"
9
9
  class="magic-modal"
10
- :data-id="toValue(id)"
10
+ :data-id="mappedId"
11
11
  v-bind="$attrs"
12
12
  aria-modal="true"
13
13
  @click.self="close"
@@ -52,6 +52,7 @@ import {
52
52
  shallowRef,
53
53
  watch,
54
54
  nextTick,
55
+ toValue,
55
56
  onBeforeUnmount,
56
57
  onUnmounted
57
58
  } from "vue";
@@ -87,6 +88,7 @@ const { id, options = {} } = defineProps({
87
88
  }
88
89
  });
89
90
  const mappedOptions = customDefu(options, defaultOptions);
91
+ const mappedId = toValue(id);
90
92
  const modalRef = useTemplateRef("modal");
91
93
  const {
92
94
  trapFocus,
@@ -1,4 +1,4 @@
1
- import { toValue, type MaybeRef } from 'vue';
1
+ import { type MaybeRef } from 'vue';
2
2
  import type { MagicModalOptions } from './../types/index.js';
3
3
  import '@maas/vue-equipment/utils/css/animations/fade-in.css';
4
4
  import '@maas/vue-equipment/utils/css/animations/fade-out.css';
@@ -8,12 +8,8 @@ interface MagicModalProps {
8
8
  options?: MagicModalOptions;
9
9
  }
10
10
  declare const mappedOptions: Omit<MagicModalOptions, keyof MagicModalOptions> & Omit<import("../../../../utils/index.js").RequireAll<MagicModalOptions>, keyof MagicModalOptions> & {
11
- transition: {
12
- content?: string;
13
- backdrop?: string;
14
- };
15
11
  backdrop: boolean;
16
- tag: "div" | "dialog";
12
+ tag: "dialog" | "div";
17
13
  focusTrap: boolean | import("focus-trap").Options;
18
14
  scrollLock: boolean | {
19
15
  padding: boolean;
@@ -22,10 +18,15 @@ declare const mappedOptions: Omit<MagicModalOptions, keyof MagicModalOptions> &
22
18
  target?: string;
23
19
  disabled?: boolean;
24
20
  };
21
+ transition: {
22
+ content?: string;
23
+ backdrop?: string;
24
+ };
25
25
  keyListener: {
26
26
  close?: string[] | false;
27
27
  };
28
28
  };
29
+ declare const mappedId: string;
29
30
  declare const close: () => void;
30
31
  declare const innerActive: import("vue").ShallowRef<boolean, boolean>;
31
32
  declare const wrapperActive: import("vue").ShallowRef<boolean, boolean>;
@@ -38,8 +39,8 @@ type __VLS_Slots = __VLS_PrettifyGlobal<__VLS_OmitStringIndex<typeof __VLS_ctx.$
38
39
  default?: (props: typeof __VLS_32) => any;
39
40
  }>;
40
41
  declare const __VLS_self: import("vue").DefineComponent<MagicModalProps, {
41
- toValue: typeof toValue;
42
42
  mappedOptions: typeof mappedOptions;
43
+ mappedId: typeof mappedId;
43
44
  close: typeof close;
44
45
  innerActive: typeof innerActive;
45
46
  wrapperActive: typeof wrapperActive;
@@ -4,7 +4,7 @@
4
4
  :disabled="state.options.teleport?.disabled"
5
5
  >
6
6
  <div
7
- :data-id="toValue(id)"
7
+ :data-id="mappedId"
8
8
  :data-position="state.options.position"
9
9
  :data-expanded="state.expanded"
10
10
  class="magic-toast-provider"
@@ -43,6 +43,7 @@
43
43
 
44
44
  <script setup>
45
45
  import {
46
+ toValue,
46
47
  useTemplateRef,
47
48
  provide,
48
49
  watch,
@@ -70,6 +71,7 @@ const { id, options } = defineProps({
70
71
  required: false
71
72
  }
72
73
  });
74
+ const mappedId = toValue(id);
73
75
  defineOptions({
74
76
  inheritAttrs: false
75
77
  });
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@maas/vue-equipment",
3
3
  "description": "Our Frontend Toolkit, Free and Open Source",
4
- "version": "1.0.0-beta.14",
4
+ "version": "1.0.0-beta.15",
5
5
  "contributors": [
6
6
  {
7
7
  "name": "Robin Scholz",