@webitel/ui-sdk 25.8.21 → 25.8.22
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/ui-sdk.css +1 -1
- package/dist/ui-sdk.js +21 -15
- package/dist/ui-sdk.umd.cjs +1 -1
- package/package.json +1 -1
- package/src/components/transitions/cases/wt-replace-transition.vue +10 -3
- package/src/components/transitions/wt-transition.vue +32 -14
- package/types/components/transitions/cases/wt-replace-transition.vue.d.ts +2 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@webitel/ui-sdk",
|
|
3
|
-
"version": "25.8.
|
|
3
|
+
"version": "25.8.22",
|
|
4
4
|
"private": false,
|
|
5
5
|
"scripts": {
|
|
6
6
|
"make-all": "npm version patch --git-tag-version false && npm run build && (npm run build:types || true) && (npm run lint:fix || true) && npm run publish-lib",
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<wt-transition
|
|
3
|
-
|
|
4
|
-
:duration="
|
|
3
|
+
:appear="appear"
|
|
4
|
+
:duration="duration"
|
|
5
|
+
:mode="mode"
|
|
5
6
|
:name="transitionName"
|
|
7
|
+
class="wt-replace-transition"
|
|
6
8
|
>
|
|
7
9
|
<template #default>
|
|
8
10
|
<slot />
|
|
@@ -16,11 +18,12 @@ import { computed } from 'vue';
|
|
|
16
18
|
import WtTransition from '../wt-transition.vue';
|
|
17
19
|
|
|
18
20
|
const props = defineProps({
|
|
19
|
-
// can choose replace pattern [opacity, slide ets]
|
|
21
|
+
// can choose replace pattern [opacity, slide-up ets]
|
|
20
22
|
// ATTENTION!! need to add another names(patterns) to <wt-transition/>, now we have fade-opacity only
|
|
21
23
|
pattern: {
|
|
22
24
|
type: String,
|
|
23
25
|
default: 'opacity',
|
|
26
|
+
options: ['opacity', 'slide-up'],
|
|
24
27
|
},
|
|
25
28
|
duration: {
|
|
26
29
|
type: String,
|
|
@@ -30,6 +33,10 @@ const props = defineProps({
|
|
|
30
33
|
type: Boolean,
|
|
31
34
|
default: false,
|
|
32
35
|
},
|
|
36
|
+
mode: {
|
|
37
|
+
type: String,
|
|
38
|
+
default: 'out-in',
|
|
39
|
+
},
|
|
33
40
|
});
|
|
34
41
|
|
|
35
42
|
const transitionName = computed(() => `fade-${props.pattern}`);
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<transition
|
|
3
|
+
:appear="appear"
|
|
4
|
+
:class="[`wt-transition--${duration}`]"
|
|
5
|
+
:mode="mode"
|
|
6
|
+
:name="name"
|
|
3
7
|
class="wt-transition"
|
|
4
|
-
:class="[`wt-transition--${props.duration}`]"
|
|
5
|
-
:mode="props.mode"
|
|
6
|
-
:appear="props.appear"
|
|
7
|
-
:name="props.name"
|
|
8
8
|
>
|
|
9
9
|
<slot />
|
|
10
10
|
</transition>
|
|
@@ -32,16 +32,6 @@ const props = defineProps({
|
|
|
32
32
|
</script>
|
|
33
33
|
|
|
34
34
|
<style lang="scss" scoped>
|
|
35
|
-
.fade-opacity-enter-active,
|
|
36
|
-
.fade-opacity-leave-active {
|
|
37
|
-
transition: opacity;
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
.fade-opacity-enter,
|
|
41
|
-
.fade-opacity-leave-to {
|
|
42
|
-
opacity: 0;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
35
|
.wt-transition {
|
|
46
36
|
&--fast {
|
|
47
37
|
transition-duration: var(--transition-fast);
|
|
@@ -53,4 +43,32 @@ const props = defineProps({
|
|
|
53
43
|
transition-duration: var(--transition-slow);
|
|
54
44
|
}
|
|
55
45
|
}
|
|
46
|
+
|
|
47
|
+
// opacity
|
|
48
|
+
.fade-opacity-enter-active,
|
|
49
|
+
.fade-opacity-leave-active {
|
|
50
|
+
transition: opacity;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.fade-opacity-enter,
|
|
54
|
+
.fade-opacity-leave-to {
|
|
55
|
+
opacity: 0;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
// slide-up
|
|
59
|
+
.fade-slide-up-enter-active,
|
|
60
|
+
.fade-slide-up-leave-active {
|
|
61
|
+
transition-timing-function: ease;
|
|
62
|
+
transition-property: transform;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.fade-slide-up-enter-from,
|
|
66
|
+
.fade-slide-up-leave-to {
|
|
67
|
+
transform: translateY(100%);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.fade-slide-up-enter-to,
|
|
71
|
+
.fade-slide-up-leave-from {
|
|
72
|
+
transform: translateY(0);
|
|
73
|
+
}
|
|
56
74
|
</style>
|
|
@@ -5,10 +5,12 @@ type __VLS_WithSlots<T, S> = T & (new () => {
|
|
|
5
5
|
});
|
|
6
6
|
declare const __VLS_component: import("vue").DefineComponent<{}, {
|
|
7
7
|
pattern: string;
|
|
8
|
+
mode: string;
|
|
8
9
|
appear: boolean;
|
|
9
10
|
duration: string;
|
|
10
11
|
$props: {
|
|
11
12
|
readonly pattern?: string;
|
|
13
|
+
readonly mode?: string;
|
|
12
14
|
readonly appear?: boolean;
|
|
13
15
|
readonly duration?: string;
|
|
14
16
|
};
|