@teammodlr/ui-kit 2.1.15 → 2.1.17
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/lib/components/modal/Modal.vue.d.ts +10 -0
- package/lib/index.cjs.js +7 -7
- package/lib/index.es.js +1374 -1367
- package/package.json +1 -1
- package/src/components/modal/Modal.vue +12 -4
- package/src/components/modal/examples/basic.vue +5 -1
package/package.json
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
:leave-active-class="fade.leaveActive"
|
|
7
7
|
:enter-from-class="fade.enterFrom"
|
|
8
8
|
:leave-to-class="fade.leaveTo">
|
|
9
|
-
<div class="ui-modal" v-if="isOpen">
|
|
9
|
+
<div class="ui-modal" v-if="isOpen" :style="{ zIndex: zIndex }">
|
|
10
10
|
<div :class="style.mask" :style="{ zIndex: zIndex }"></div>
|
|
11
11
|
<div
|
|
12
12
|
tabIndex="-1"
|
|
@@ -30,6 +30,7 @@
|
|
|
30
30
|
:class="computedContainerClasses"
|
|
31
31
|
@mousedown="onContentMouseDown"
|
|
32
32
|
@mouseup="onContentMouseUp"
|
|
33
|
+
v-bind="$attrs"
|
|
33
34
|
ref="target">
|
|
34
35
|
<template v-if="loading">
|
|
35
36
|
<slot name="loading"> Loading...</slot>
|
|
@@ -54,7 +55,7 @@
|
|
|
54
55
|
<slot name="body"></slot>
|
|
55
56
|
<slot></slot>
|
|
56
57
|
</div>
|
|
57
|
-
<div :class="style.footer">
|
|
58
|
+
<div :class="style.footer" v-if="hasFooter">
|
|
58
59
|
<slot name="footer"></slot>
|
|
59
60
|
</div>
|
|
60
61
|
</div>
|
|
@@ -93,6 +94,10 @@ export default defineComponent({
|
|
|
93
94
|
type: Boolean,
|
|
94
95
|
default: false
|
|
95
96
|
},
|
|
97
|
+
wrapClassName: {
|
|
98
|
+
type: String,
|
|
99
|
+
default: ''
|
|
100
|
+
},
|
|
96
101
|
// @deprecated
|
|
97
102
|
canClickOutside: {
|
|
98
103
|
type: Boolean,
|
|
@@ -131,6 +136,7 @@ export default defineComponent({
|
|
|
131
136
|
const wrapperRef = shallowRef<HTMLDivElement>();
|
|
132
137
|
const zIndex = ref(props.zIndex ?? nextZIndex());
|
|
133
138
|
const hasSidebar = computed(() => !!slots.sidebar);
|
|
139
|
+
const hasFooter = computed(() => !!slots.footer);
|
|
134
140
|
const transformOrigin = ref<string>();
|
|
135
141
|
|
|
136
142
|
const contentStyleRef = computed(() => {
|
|
@@ -159,7 +165,8 @@ export default defineComponent({
|
|
|
159
165
|
style.wrapper,
|
|
160
166
|
{
|
|
161
167
|
[style.centeredWrapper]: props.centered
|
|
162
|
-
}
|
|
168
|
+
},
|
|
169
|
+
props.wrapClassName
|
|
163
170
|
];
|
|
164
171
|
});
|
|
165
172
|
|
|
@@ -292,7 +299,8 @@ export default defineComponent({
|
|
|
292
299
|
fade,
|
|
293
300
|
contentStyleRef,
|
|
294
301
|
wrapperRef,
|
|
295
|
-
hasSidebar
|
|
302
|
+
hasSidebar,
|
|
303
|
+
hasFooter
|
|
296
304
|
};
|
|
297
305
|
}
|
|
298
306
|
});
|