unika-components 1.0.330 → 1.0.341
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.
|
@@ -76,11 +76,7 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
76
76
|
id: number;
|
|
77
77
|
}[];
|
|
78
78
|
};
|
|
79
|
-
|
|
80
|
-
textShadow?: undefined;
|
|
81
|
-
} | {
|
|
82
|
-
textShadow: string;
|
|
83
|
-
}>;
|
|
79
|
+
boxShadowStyle: import("vue").ComputedRef<string>;
|
|
84
80
|
animationStyle: import("vue").ComputedRef<{
|
|
85
81
|
animation?: undefined;
|
|
86
82
|
} | {
|
|
@@ -88,65 +84,35 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
88
84
|
}>;
|
|
89
85
|
textAniClasses: import("vue").ComputedRef<string[]>;
|
|
90
86
|
computedStyle: import("vue").ComputedRef<{
|
|
91
|
-
animation?: undefined;
|
|
92
|
-
textShadow?: undefined;
|
|
93
87
|
position: string;
|
|
94
|
-
fontSize: string;
|
|
95
|
-
lineHeight: number;
|
|
96
|
-
letterSpacing: string;
|
|
97
|
-
width: string;
|
|
98
|
-
height: string;
|
|
99
88
|
left: string;
|
|
100
89
|
top: string;
|
|
101
|
-
transform: string;
|
|
102
|
-
padding: string;
|
|
103
|
-
textIndent: string;
|
|
104
|
-
borderRadius: string;
|
|
105
|
-
} | {
|
|
106
|
-
animation: string;
|
|
107
|
-
textShadow?: undefined;
|
|
108
|
-
position: string;
|
|
109
|
-
fontSize: string;
|
|
110
|
-
lineHeight: number;
|
|
111
|
-
letterSpacing: string;
|
|
112
90
|
width: string;
|
|
113
91
|
height: string;
|
|
114
|
-
left: string;
|
|
115
|
-
top: string;
|
|
116
92
|
transform: string;
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
} | {
|
|
121
|
-
animation?: undefined;
|
|
122
|
-
textShadow: string;
|
|
123
|
-
position: string;
|
|
93
|
+
}>;
|
|
94
|
+
textCommonStyle: import("vue").ComputedRef<{
|
|
95
|
+
fontFamily: string;
|
|
124
96
|
fontSize: string;
|
|
125
97
|
lineHeight: number;
|
|
126
98
|
letterSpacing: string;
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
top: string;
|
|
131
|
-
transform: string;
|
|
99
|
+
textAlign: string;
|
|
100
|
+
color: string;
|
|
101
|
+
opacity: number;
|
|
132
102
|
padding: string;
|
|
133
103
|
textIndent: string;
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
position: string;
|
|
104
|
+
}>;
|
|
105
|
+
textEditorStyle: import("vue").ComputedRef<{
|
|
106
|
+
display: string;
|
|
107
|
+
fontFamily: string;
|
|
139
108
|
fontSize: string;
|
|
140
109
|
lineHeight: number;
|
|
141
110
|
letterSpacing: string;
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
top: string;
|
|
146
|
-
transform: string;
|
|
111
|
+
textAlign: string;
|
|
112
|
+
color: string;
|
|
113
|
+
opacity: number;
|
|
147
114
|
padding: string;
|
|
148
115
|
textIndent: string;
|
|
149
|
-
borderRadius: string;
|
|
150
116
|
}>;
|
|
151
117
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
152
118
|
element: {
|
|
@@ -134,6 +134,9 @@ export interface ElementData {
|
|
|
134
134
|
type: string;
|
|
135
135
|
textContent: string;
|
|
136
136
|
layerName: string;
|
|
137
|
+
sign: boolean;
|
|
138
|
+
signSort: number;
|
|
139
|
+
overturnType: number;
|
|
137
140
|
css: {
|
|
138
141
|
fontFamily: string;
|
|
139
142
|
fontSize: number;
|
|
@@ -162,6 +165,15 @@ export interface ElementData {
|
|
|
162
165
|
animation: string;
|
|
163
166
|
animation2: string;
|
|
164
167
|
};
|
|
168
|
+
triggers: {
|
|
169
|
+
event: string;
|
|
170
|
+
link: string;
|
|
171
|
+
go: string;
|
|
172
|
+
phone: string;
|
|
173
|
+
musicName: string;
|
|
174
|
+
musicLink: string;
|
|
175
|
+
musicHash: string;
|
|
176
|
+
};
|
|
165
177
|
properties: {
|
|
166
178
|
visible: boolean;
|
|
167
179
|
isLock: boolean;
|
|
@@ -1,91 +1,4 @@
|
|
|
1
1
|
|
|
2
|
-
.uni-image-component {
|
|
3
|
-
max-width: 100%;
|
|
4
|
-
}
|
|
5
|
-
.uni-image-mask-wrapper {
|
|
6
|
-
display: inline-block;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.uni-text {
|
|
10
|
-
white-space: pre-wrap;
|
|
11
|
-
word-break: break-all;
|
|
12
|
-
transform-origin: center;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
/* 文本动画类 */
|
|
16
|
-
.text-fadeIn {
|
|
17
|
-
animation: fadeIn 1s ease-in-out;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
.text-slideIn {
|
|
21
|
-
animation: slideIn 1s ease-in-out;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
.text-bounceIn {
|
|
25
|
-
animation: bounceIn 1s ease-in-out;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
/* 基础动画关键帧 */
|
|
29
|
-
@keyframes fadeIn {
|
|
30
|
-
from {
|
|
31
|
-
opacity: 0;
|
|
32
|
-
}
|
|
33
|
-
to {
|
|
34
|
-
opacity: 1;
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
@keyframes slideIn {
|
|
39
|
-
from {
|
|
40
|
-
transform: translateY(20px);
|
|
41
|
-
opacity: 0;
|
|
42
|
-
}
|
|
43
|
-
to {
|
|
44
|
-
transform: translateY(0);
|
|
45
|
-
opacity: 1;
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
@keyframes bounceIn {
|
|
50
|
-
0% {
|
|
51
|
-
transform: scale(0.3);
|
|
52
|
-
opacity: 0;
|
|
53
|
-
}
|
|
54
|
-
50% {
|
|
55
|
-
transform: scale(1.05);
|
|
56
|
-
opacity: 0.8;
|
|
57
|
-
}
|
|
58
|
-
70% {
|
|
59
|
-
transform: scale(0.9);
|
|
60
|
-
opacity: 0.9;
|
|
61
|
-
}
|
|
62
|
-
100% {
|
|
63
|
-
transform: scale(1);
|
|
64
|
-
opacity: 1;
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
.uni-video-component {
|
|
69
|
-
position: relative;
|
|
70
|
-
text-align: center;
|
|
71
|
-
}
|
|
72
|
-
.play-pause-button {
|
|
73
|
-
position: absolute;
|
|
74
|
-
top: 50%;
|
|
75
|
-
left: 50%;
|
|
76
|
-
transform: translate(-50%, -50%);
|
|
77
|
-
cursor: pointer;
|
|
78
|
-
font-size: 2rem;
|
|
79
|
-
color: #fff;
|
|
80
|
-
background: rgba(0, 0, 0, 0.6);
|
|
81
|
-
border-radius: 50%;
|
|
82
|
-
padding: 10px;
|
|
83
|
-
transition: background 0.3s;
|
|
84
|
-
}
|
|
85
|
-
.play-pause-button:hover {
|
|
86
|
-
background: rgba(0, 0, 0, 0.8);
|
|
87
|
-
}
|
|
88
|
-
|
|
89
2
|
.work-container {
|
|
90
3
|
position: relative;
|
|
91
4
|
overflow: hidden;
|
|
@@ -282,28 +195,82 @@
|
|
|
282
195
|
background-position: center;
|
|
283
196
|
will-change: transform;
|
|
284
197
|
}
|
|
285
|
-
|
|
286
|
-
.
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
}
|
|
292
|
-
|
|
293
|
-
.
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
198
|
+
|
|
199
|
+
.uni-image-component {
|
|
200
|
+
max-width: 100%;
|
|
201
|
+
}
|
|
202
|
+
.uni-image-mask-wrapper {
|
|
203
|
+
display: inline-block;
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
.ele-text {
|
|
207
|
+
position: relative;
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
.ani-wrap {
|
|
211
|
+
display: flex;
|
|
212
|
+
justify-content: center;
|
|
213
|
+
align-items: center;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
.text-common {
|
|
217
|
+
white-space: pre-wrap;
|
|
218
|
+
word-break: break-all;
|
|
219
|
+
transform-origin: center;
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
/* 文本动画类 */
|
|
223
|
+
.text-fadeIn {
|
|
224
|
+
animation: fadeIn 1s ease-in-out;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
.text-slideIn {
|
|
228
|
+
animation: slideIn 1s ease-in-out;
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
.text-bounceIn {
|
|
232
|
+
animation: bounceIn 1s ease-in-out;
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
/* 基础动画关键帧 */
|
|
236
|
+
@keyframes fadeIn {
|
|
237
|
+
from {
|
|
238
|
+
opacity: 0;
|
|
239
|
+
}
|
|
240
|
+
to {
|
|
241
|
+
opacity: 1;
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
@keyframes slideIn {
|
|
246
|
+
from {
|
|
247
|
+
transform: translateY(20px);
|
|
248
|
+
opacity: 0;
|
|
249
|
+
}
|
|
250
|
+
to {
|
|
251
|
+
transform: translateY(0);
|
|
252
|
+
opacity: 1;
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
@keyframes bounceIn {
|
|
257
|
+
0% {
|
|
258
|
+
transform: scale(0.3);
|
|
259
|
+
opacity: 0;
|
|
260
|
+
}
|
|
261
|
+
50% {
|
|
262
|
+
transform: scale(1.05);
|
|
263
|
+
opacity: 0.8;
|
|
264
|
+
}
|
|
265
|
+
70% {
|
|
266
|
+
transform: scale(0.9);
|
|
267
|
+
opacity: 0.9;
|
|
268
|
+
}
|
|
269
|
+
100% {
|
|
270
|
+
transform: scale(1);
|
|
271
|
+
opacity: 1;
|
|
272
|
+
}
|
|
273
|
+
}
|
|
307
274
|
|
|
308
275
|
|
|
309
276
|
.uni-calendar-component {
|
|
@@ -317,15 +284,26 @@
|
|
|
317
284
|
color: #666
|
|
318
285
|
}
|
|
319
286
|
|
|
320
|
-
.uni-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
}
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
287
|
+
.uni-video-component {
|
|
288
|
+
position: relative;
|
|
289
|
+
text-align: center;
|
|
290
|
+
}
|
|
291
|
+
.play-pause-button {
|
|
292
|
+
position: absolute;
|
|
293
|
+
top: 50%;
|
|
294
|
+
left: 50%;
|
|
295
|
+
transform: translate(-50%, -50%);
|
|
296
|
+
cursor: pointer;
|
|
297
|
+
font-size: 2rem;
|
|
298
|
+
color: #fff;
|
|
299
|
+
background: rgba(0, 0, 0, 0.6);
|
|
300
|
+
border-radius: 50%;
|
|
301
|
+
padding: 10px;
|
|
302
|
+
transition: background 0.3s;
|
|
303
|
+
}
|
|
304
|
+
.play-pause-button:hover {
|
|
305
|
+
background: rgba(0, 0, 0, 0.8);
|
|
306
|
+
}
|
|
329
307
|
|
|
330
308
|
.ant-input-number {
|
|
331
309
|
box-sizing: border-box;
|
|
@@ -364,6 +342,38 @@
|
|
|
364
342
|
|
|
365
343
|
.uni-build-up-component {
|
|
366
344
|
}
|
|
345
|
+
|
|
346
|
+
.like-button {
|
|
347
|
+
display: flex;
|
|
348
|
+
flex-direction: column;
|
|
349
|
+
align-items: center;
|
|
350
|
+
cursor: pointer;
|
|
351
|
+
}
|
|
352
|
+
|
|
353
|
+
.icon-heart {
|
|
354
|
+
font-size: 24px;
|
|
355
|
+
color: #e74c3c;
|
|
356
|
+
}
|
|
357
|
+
|
|
358
|
+
.liked {
|
|
359
|
+
color: #f00; /* 更改颜色以示已赞 */
|
|
360
|
+
}
|
|
361
|
+
|
|
362
|
+
.like-count {
|
|
363
|
+
margin-top: 4px;
|
|
364
|
+
font-size: 16px;
|
|
365
|
+
color: #333;
|
|
366
|
+
}
|
|
367
|
+
|
|
368
|
+
.effect {
|
|
369
|
+
width: 100%;
|
|
370
|
+
height: 100%;
|
|
371
|
+
}
|
|
372
|
+
|
|
373
|
+
.uni-lotties-component {
|
|
374
|
+
width: 100%;
|
|
375
|
+
height: 100%;
|
|
376
|
+
}
|
|
367
377
|
|
|
368
378
|
.uni-svg-component {
|
|
369
379
|
display: inline-block;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent, computed, openBlock, createElementBlock, normalizeClass, normalizeStyle as normalizeStyle$1, toDisplayString, createCommentVNode, ref, nextTick, withModifiers,
|
|
1
|
+
import { defineComponent, computed, openBlock, createElementBlock, normalizeClass, normalizeStyle as normalizeStyle$1, createElementVNode, toDisplayString, createCommentVNode, createStaticVNode, ref, nextTick, withModifiers, Fragment, renderList, createBlock, resolveDynamicComponent, normalizeProps, guardReactiveProps, watch, resolveComponent, createVNode, Transition, withCtx, withDirectives, vShow, createTextVNode, renderSlot, pushScopeId, popScopeId, toRefs, onMounted, onBeforeMount, onUnmounted, h as h$2, isVNode, Comment, Text, reactive, getCurrentInstance, onUpdated, inject, provide, unref, shallowRef, watchEffect, onBeforeUnmount, triggerRef, resolveDirective, cloneVNode, toRef, Teleport, isRef, toRaw, render as render$m, TransitionGroup, onBeforeUpdate, mergeProps } from 'vue';
|
|
2
2
|
import crypto from 'crypto';
|
|
3
3
|
|
|
4
4
|
var script$k = defineComponent({
|
|
@@ -10,17 +10,14 @@ var script$k = defineComponent({
|
|
|
10
10
|
}
|
|
11
11
|
},
|
|
12
12
|
setup(props) {
|
|
13
|
-
// 确保在解构之前检查 element 是否存在
|
|
14
13
|
const element = props.element || {};
|
|
15
14
|
const css = element.css || {};
|
|
16
15
|
const properties = element.properties || {};
|
|
17
16
|
// 计算阴影样式
|
|
18
|
-
const
|
|
17
|
+
const boxShadowStyle = computed(() => {
|
|
19
18
|
if (!properties.shadowSize)
|
|
20
|
-
return
|
|
21
|
-
return {
|
|
22
|
-
textShadow: `${properties.shadowX || 0}px ${properties.shadowY || 0}px ${properties.shadowBlur || 0}px ${properties.shadowColor || '#000'}`
|
|
23
|
-
};
|
|
19
|
+
return 'none';
|
|
20
|
+
return `${properties.shadowX || 0}px ${properties.shadowY || 0}px ${properties.shadowBlur || 0}px ${properties.shadowColor || '#000'}`;
|
|
24
21
|
});
|
|
25
22
|
// 计算动画样式
|
|
26
23
|
const animationStyle = computed(() => {
|
|
@@ -40,38 +37,80 @@ var script$k = defineComponent({
|
|
|
40
37
|
// 计算样式
|
|
41
38
|
const computedStyle = computed(() => ({
|
|
42
39
|
position: 'absolute',
|
|
43
|
-
fontSize: `${css.fontSize || 16}px`,
|
|
44
|
-
lineHeight: css.lineHeight || 1,
|
|
45
|
-
letterSpacing: `${css.letterSpacing || 0}px`,
|
|
46
|
-
width: `${css.width || 100}px`,
|
|
47
|
-
height: `${css.height || 0}px`,
|
|
48
40
|
left: `${css.left || 0}px`,
|
|
49
41
|
top: `${css.top || 0}px`,
|
|
42
|
+
width: `${css.width || 100}px`,
|
|
43
|
+
height: 'auto',
|
|
50
44
|
transform: `rotate(${css.transform || 0}deg)`,
|
|
45
|
+
}));
|
|
46
|
+
// 计算文本样式
|
|
47
|
+
const textCommonStyle = computed(() => ({
|
|
48
|
+
fontFamily: css.fontFamily || '微软雅黑',
|
|
49
|
+
fontSize: `${css.fontSize || 16}px`,
|
|
50
|
+
lineHeight: css.lineHeight || 1,
|
|
51
|
+
letterSpacing: `${css.letterSpacing || 0}px`,
|
|
52
|
+
textAlign: css.textAlign || 'center',
|
|
53
|
+
color: css.color || '#000',
|
|
54
|
+
opacity: properties.visible ? 1 : 0,
|
|
51
55
|
padding: `${css.padding || 0}px`,
|
|
52
56
|
textIndent: `${css.textIndent || 0}px`,
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
...
|
|
57
|
+
}));
|
|
58
|
+
const textEditorStyle = computed(() => ({
|
|
59
|
+
...textCommonStyle.value,
|
|
60
|
+
display: 'block', // 确保文本编辑器可见
|
|
56
61
|
}));
|
|
57
62
|
return {
|
|
58
63
|
css,
|
|
59
64
|
properties,
|
|
60
|
-
|
|
65
|
+
boxShadowStyle,
|
|
61
66
|
animationStyle,
|
|
62
67
|
textAniClasses,
|
|
63
|
-
computedStyle
|
|
68
|
+
computedStyle,
|
|
69
|
+
textCommonStyle,
|
|
70
|
+
textEditorStyle
|
|
64
71
|
};
|
|
65
72
|
}
|
|
66
73
|
});
|
|
67
74
|
|
|
75
|
+
const _hoisted_1$b = ["data-id", "data-pid", "data-type", "sign", "signsort", "layername"];
|
|
76
|
+
const _hoisted_2$3 = /*#__PURE__*/createStaticVNode("<div class=\"drag-point top-center\" data-v-55ed80cb></div><div class=\"drag-point bottom-center\" data-v-55ed80cb></div><div class=\"drag-point left-top\" data-v-55ed80cb></div><div class=\"drag-point left-center\" data-v-55ed80cb></div><div class=\"drag-point left-bottom\" data-v-55ed80cb></div><div class=\"drag-point right-top\" data-v-55ed80cb></div><div class=\"drag-point right-center\" data-v-55ed80cb></div><div class=\"drag-point right-bottom\" data-v-55ed80cb></div><div class=\"drag-point rotate-icon\" data-v-55ed80cb><i class=\"iconfont hb-xuanzhuan\" data-v-55ed80cb></i></div>", 9);
|
|
77
|
+
|
|
68
78
|
function render$l(_ctx, _cache, $props, $setup, $data, $options) {
|
|
69
79
|
return (_ctx.element && _ctx.properties.visible)
|
|
70
80
|
? (openBlock(), createElementBlock("div", {
|
|
71
81
|
key: 0,
|
|
72
|
-
class: normalizeClass([
|
|
73
|
-
|
|
74
|
-
|
|
82
|
+
class: normalizeClass(['ele-text', 'eles']),
|
|
83
|
+
"data-id": _ctx.element.id,
|
|
84
|
+
"data-pid": _ctx.element.pid,
|
|
85
|
+
"data-type": _ctx.element.type,
|
|
86
|
+
style: normalizeStyle$1(_ctx.computedStyle),
|
|
87
|
+
sign: _ctx.element.sign,
|
|
88
|
+
signsort: _ctx.element.signSort,
|
|
89
|
+
layername: _ctx.element.layerName
|
|
90
|
+
}, [
|
|
91
|
+
createElementVNode("div", {
|
|
92
|
+
class: "ani-wrap",
|
|
93
|
+
style: normalizeStyle$1({
|
|
94
|
+
borderRadius: `${_ctx.css.borderRadius || 0}px`,
|
|
95
|
+
borderColor: _ctx.css.borderColor,
|
|
96
|
+
borderStyle: _ctx.css.borderStyle,
|
|
97
|
+
borderWidth: `${_ctx.css.borderWidth || 0}px`,
|
|
98
|
+
boxShadow: _ctx.boxShadowStyle,
|
|
99
|
+
opacity: _ctx.properties.visible ? 1 : 0
|
|
100
|
+
})
|
|
101
|
+
}, [
|
|
102
|
+
createElementVNode("div", {
|
|
103
|
+
class: "text-common text-ani",
|
|
104
|
+
style: normalizeStyle$1(_ctx.textCommonStyle)
|
|
105
|
+
}, null, 4 /* STYLE */),
|
|
106
|
+
createElementVNode("div", {
|
|
107
|
+
contenteditable: "false",
|
|
108
|
+
class: "text-common text-editor",
|
|
109
|
+
style: normalizeStyle$1(_ctx.textEditorStyle)
|
|
110
|
+
}, toDisplayString(_ctx.element.textContent || '双击输入文字'), 5 /* TEXT, STYLE */)
|
|
111
|
+
], 4 /* STYLE */),
|
|
112
|
+
_hoisted_2$3
|
|
113
|
+
], 12 /* STYLE, PROPS */, _hoisted_1$b))
|
|
75
114
|
: createCommentVNode("v-if", true)
|
|
76
115
|
}
|
|
77
116
|
|
|
@@ -17,17 +17,14 @@
|
|
|
17
17
|
}
|
|
18
18
|
},
|
|
19
19
|
setup(props) {
|
|
20
|
-
// 确保在解构之前检查 element 是否存在
|
|
21
20
|
const element = props.element || {};
|
|
22
21
|
const css = element.css || {};
|
|
23
22
|
const properties = element.properties || {};
|
|
24
23
|
// 计算阴影样式
|
|
25
|
-
const
|
|
24
|
+
const boxShadowStyle = vue.computed(() => {
|
|
26
25
|
if (!properties.shadowSize)
|
|
27
|
-
return
|
|
28
|
-
return {
|
|
29
|
-
textShadow: `${properties.shadowX || 0}px ${properties.shadowY || 0}px ${properties.shadowBlur || 0}px ${properties.shadowColor || '#000'}`
|
|
30
|
-
};
|
|
26
|
+
return 'none';
|
|
27
|
+
return `${properties.shadowX || 0}px ${properties.shadowY || 0}px ${properties.shadowBlur || 0}px ${properties.shadowColor || '#000'}`;
|
|
31
28
|
});
|
|
32
29
|
// 计算动画样式
|
|
33
30
|
const animationStyle = vue.computed(() => {
|
|
@@ -47,38 +44,80 @@
|
|
|
47
44
|
// 计算样式
|
|
48
45
|
const computedStyle = vue.computed(() => ({
|
|
49
46
|
position: 'absolute',
|
|
50
|
-
fontSize: `${css.fontSize || 16}px`,
|
|
51
|
-
lineHeight: css.lineHeight || 1,
|
|
52
|
-
letterSpacing: `${css.letterSpacing || 0}px`,
|
|
53
|
-
width: `${css.width || 100}px`,
|
|
54
|
-
height: `${css.height || 0}px`,
|
|
55
47
|
left: `${css.left || 0}px`,
|
|
56
48
|
top: `${css.top || 0}px`,
|
|
49
|
+
width: `${css.width || 100}px`,
|
|
50
|
+
height: 'auto',
|
|
57
51
|
transform: `rotate(${css.transform || 0}deg)`,
|
|
52
|
+
}));
|
|
53
|
+
// 计算文本样式
|
|
54
|
+
const textCommonStyle = vue.computed(() => ({
|
|
55
|
+
fontFamily: css.fontFamily || '微软雅黑',
|
|
56
|
+
fontSize: `${css.fontSize || 16}px`,
|
|
57
|
+
lineHeight: css.lineHeight || 1,
|
|
58
|
+
letterSpacing: `${css.letterSpacing || 0}px`,
|
|
59
|
+
textAlign: css.textAlign || 'center',
|
|
60
|
+
color: css.color || '#000',
|
|
61
|
+
opacity: properties.visible ? 1 : 0,
|
|
58
62
|
padding: `${css.padding || 0}px`,
|
|
59
63
|
textIndent: `${css.textIndent || 0}px`,
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
...
|
|
64
|
+
}));
|
|
65
|
+
const textEditorStyle = vue.computed(() => ({
|
|
66
|
+
...textCommonStyle.value,
|
|
67
|
+
display: 'block', // 确保文本编辑器可见
|
|
63
68
|
}));
|
|
64
69
|
return {
|
|
65
70
|
css,
|
|
66
71
|
properties,
|
|
67
|
-
|
|
72
|
+
boxShadowStyle,
|
|
68
73
|
animationStyle,
|
|
69
74
|
textAniClasses,
|
|
70
|
-
computedStyle
|
|
75
|
+
computedStyle,
|
|
76
|
+
textCommonStyle,
|
|
77
|
+
textEditorStyle
|
|
71
78
|
};
|
|
72
79
|
}
|
|
73
80
|
});
|
|
74
81
|
|
|
82
|
+
const _hoisted_1$b = ["data-id", "data-pid", "data-type", "sign", "signsort", "layername"];
|
|
83
|
+
const _hoisted_2$3 = /*#__PURE__*/vue.createStaticVNode("<div class=\"drag-point top-center\" data-v-55ed80cb></div><div class=\"drag-point bottom-center\" data-v-55ed80cb></div><div class=\"drag-point left-top\" data-v-55ed80cb></div><div class=\"drag-point left-center\" data-v-55ed80cb></div><div class=\"drag-point left-bottom\" data-v-55ed80cb></div><div class=\"drag-point right-top\" data-v-55ed80cb></div><div class=\"drag-point right-center\" data-v-55ed80cb></div><div class=\"drag-point right-bottom\" data-v-55ed80cb></div><div class=\"drag-point rotate-icon\" data-v-55ed80cb><i class=\"iconfont hb-xuanzhuan\" data-v-55ed80cb></i></div>", 9);
|
|
84
|
+
|
|
75
85
|
function render$l(_ctx, _cache, $props, $setup, $data, $options) {
|
|
76
86
|
return (_ctx.element && _ctx.properties.visible)
|
|
77
87
|
? (vue.openBlock(), vue.createElementBlock("div", {
|
|
78
88
|
key: 0,
|
|
79
|
-
class: vue.normalizeClass([
|
|
80
|
-
|
|
81
|
-
|
|
89
|
+
class: vue.normalizeClass(['ele-text', 'eles']),
|
|
90
|
+
"data-id": _ctx.element.id,
|
|
91
|
+
"data-pid": _ctx.element.pid,
|
|
92
|
+
"data-type": _ctx.element.type,
|
|
93
|
+
style: vue.normalizeStyle(_ctx.computedStyle),
|
|
94
|
+
sign: _ctx.element.sign,
|
|
95
|
+
signsort: _ctx.element.signSort,
|
|
96
|
+
layername: _ctx.element.layerName
|
|
97
|
+
}, [
|
|
98
|
+
vue.createElementVNode("div", {
|
|
99
|
+
class: "ani-wrap",
|
|
100
|
+
style: vue.normalizeStyle({
|
|
101
|
+
borderRadius: `${_ctx.css.borderRadius || 0}px`,
|
|
102
|
+
borderColor: _ctx.css.borderColor,
|
|
103
|
+
borderStyle: _ctx.css.borderStyle,
|
|
104
|
+
borderWidth: `${_ctx.css.borderWidth || 0}px`,
|
|
105
|
+
boxShadow: _ctx.boxShadowStyle,
|
|
106
|
+
opacity: _ctx.properties.visible ? 1 : 0
|
|
107
|
+
})
|
|
108
|
+
}, [
|
|
109
|
+
vue.createElementVNode("div", {
|
|
110
|
+
class: "text-common text-ani",
|
|
111
|
+
style: vue.normalizeStyle(_ctx.textCommonStyle)
|
|
112
|
+
}, null, 4 /* STYLE */),
|
|
113
|
+
vue.createElementVNode("div", {
|
|
114
|
+
contenteditable: "false",
|
|
115
|
+
class: "text-common text-editor",
|
|
116
|
+
style: vue.normalizeStyle(_ctx.textEditorStyle)
|
|
117
|
+
}, vue.toDisplayString(_ctx.element.textContent || '双击输入文字'), 5 /* TEXT, STYLE */)
|
|
118
|
+
], 4 /* STYLE */),
|
|
119
|
+
_hoisted_2$3
|
|
120
|
+
], 12 /* STYLE, PROPS */, _hoisted_1$b))
|
|
82
121
|
: vue.createCommentVNode("v-if", true)
|
|
83
122
|
}
|
|
84
123
|
|