srcdev-nuxt-components 2.2.8 → 2.3.1
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.
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
.auto-rotate {
|
|
2
|
+
animation: autoRotateAnimation;
|
|
3
|
+
animation-timeline: view();
|
|
4
|
+
}
|
|
5
|
+
@keyframes autoRotateAnimation {
|
|
6
|
+
from {
|
|
7
|
+
transform: rotate(0deg);
|
|
8
|
+
}
|
|
9
|
+
to {
|
|
10
|
+
transform: rotate(360deg);
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
.auto-show {
|
|
14
|
+
animation: autoShowAnimation both;
|
|
15
|
+
animation-timeline: view(70% 5%);
|
|
16
|
+
}
|
|
17
|
+
@keyframes autoShowAnimation {
|
|
18
|
+
from {
|
|
19
|
+
opacity: 0;
|
|
20
|
+
transform: translateY(200px) scale(0.3);
|
|
21
|
+
}
|
|
22
|
+
to {
|
|
23
|
+
opacity: 1;
|
|
24
|
+
transform: translateY(0) scale(1);
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
.auto-bLur {
|
|
28
|
+
animation: autoBlurAnimation linear both;
|
|
29
|
+
animation-timeline: view();
|
|
30
|
+
}
|
|
31
|
+
@keyframes autoBlurAnimation {
|
|
32
|
+
0% {
|
|
33
|
+
filter: blur(40px);
|
|
34
|
+
}
|
|
35
|
+
45%,
|
|
36
|
+
55% {
|
|
37
|
+
filter: blur(0px);
|
|
38
|
+
}
|
|
39
|
+
100% {
|
|
40
|
+
filter: blur(40px);
|
|
41
|
+
}
|
|
42
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<component :is="tag" class="clipped-panel" :class="[elementClasses]">
|
|
2
|
+
<component :is="tag" class="clipped-panel" :class="[variant, elementClasses]">
|
|
3
3
|
<slot name="default"></slot>
|
|
4
4
|
</component>
|
|
5
5
|
</template>
|
|
@@ -17,6 +17,13 @@ const props = defineProps({
|
|
|
17
17
|
return TAGS_ALLOWED.includes(value);
|
|
18
18
|
},
|
|
19
19
|
},
|
|
20
|
+
variant: {
|
|
21
|
+
type: String,
|
|
22
|
+
default: 'square',
|
|
23
|
+
validator(value: string) {
|
|
24
|
+
return ['circle-cutout', 'rectangle', 'square'].includes(value);
|
|
25
|
+
},
|
|
26
|
+
},
|
|
20
27
|
styleClassPassthrough: {
|
|
21
28
|
type: Array as PropType<string[]>,
|
|
22
29
|
default: () => [],
|
|
@@ -45,15 +52,20 @@ watch(
|
|
|
45
52
|
/* box-shadow: 5px 5px 5px 5px white; */
|
|
46
53
|
|
|
47
54
|
aspect-ratio: 1;
|
|
48
|
-
width: 200px;
|
|
49
55
|
|
|
56
|
+
&.rectangle {
|
|
57
|
+
|
|
58
|
+
--_max-x-position: 300px;
|
|
59
|
+
--_curve-radius: 10px;
|
|
60
|
+
|
|
61
|
+
clip-path: path('M 10, 50 L 140, 50 A 10, 10, 0, 0, 0 150, 40 L 150, 10 A 10, 10, 0, 0, 1 160, 0 L 290, 0 A 10, 10, 0, 0, 1 300, 10 L 300, 190 A 10, 10, 0, 0, 1 290, 200 L 10, 200 A 10, 10, 0, 0, 1 0, 190 L 0, 60 A 10, 10, 0, 0, 1 10, 50 Z');
|
|
62
|
+
width: 300px;
|
|
63
|
+
}
|
|
50
64
|
&.square {
|
|
51
65
|
/* clip-path: path('M 10, 50 L 90, 50 A 10, 10, 0, 0, 0 100, 40 L 100, 10 L 110, 0 L 190, 0 L 200, 10 L 200, 190 L 190, 200 L 10, 200 L 0, 190 L 0, 60 L 10, 50 Z'); */
|
|
52
|
-
clip-path: path(
|
|
53
|
-
|
|
54
|
-
);
|
|
66
|
+
clip-path: path('M 10, 50 L 90, 50 A 10, 10, 0, 0, 0 100, 40 L 100, 10 A 10, 10, 0, 0, 1 110, 0 L 190, 0 A 10, 10, 0, 0, 1 200, 10 L 200, 190 A 10, 10, 0, 0, 1 190, 200 L 10, 200 A 10, 10, 0, 0, 1 0, 190 L 0, 60 A 10, 10, 0, 0, 1 10, 50 Z');
|
|
67
|
+
width: 200px;
|
|
55
68
|
}
|
|
56
|
-
|
|
57
69
|
&.circle-cutout {
|
|
58
70
|
clip-path: path('M Z');
|
|
59
71
|
}
|
package/package.json
CHANGED