@shijiu/jsview-vue-samples 2.2.373 → 2.2.426-test.0
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/Basic/components/text/TextDirection.vue +0 -1
- package/ColorSpace/App.vue +2 -2
- package/CssPreprocessor/Stylus/components/stylus-group1/StylusOperations.vue +0 -1
- package/CssPreprocessor/utils/ContentBlock.vue +3 -3
- package/CssPreprocessor/utils/{FontStyle.css → FontConfig.css} +3 -3
- package/CssPreprocessor/utils/TitleBar.vue +2 -2
- package/CustomShader/App.vue +2 -2
- package/DemoHomepage/views/Homepage.vue +0 -4
- package/DivMetroPerformance/components/ContentItem.vue +0 -1
- package/FlexCellDemo/TestFrame1.vue +0 -4
- package/GiftRain/App.vue +0 -3
- package/HashParams/App.vue +0 -1
- package/JsvPreDownloader/App.vue +0 -2
- package/Marquee/App.vue +2 -2
- package/MetroWidgetDemos/MassiveItems/ContentItem.vue +0 -1
- package/MetroWidgetDemos/PerformanceTest/components/ContentItem.vue +0 -1
- package/MetroWidgetDemos/PerformanceTest/components/MyTab.vue +18 -17
- package/PosterPacker/App.vue +2 -2
- package/PosterPacker/tools/geniePakcer/Genie.vue +2 -2
- package/PosterPacker/tools/vortexPacker/Vortex.vue +14 -14
- package/ScaleDownNeon/App.vue +13 -10
- package/SceneTransition/App.vue +5 -4
- package/TextureAnimation/App.vue +6 -16
- package/TextureSize/App.vue +5 -6
- package/ViewOpacity/App.vue +4 -5
- package/package.json +1 -1
package/ColorSpace/App.vue
CHANGED
|
@@ -10,7 +10,7 @@ const router = useRouter();
|
|
|
10
10
|
const onKeyDown = (ev) => {
|
|
11
11
|
// 8:Backspace, 27:Escape, 10000:盒子返回键
|
|
12
12
|
if (ev.keyCode == 8 || ev.keyCode == 27 || ev.keyCode == 10000) {
|
|
13
|
-
window.
|
|
13
|
+
window.JsvCoreApi?.setRenderGlobalConfig({
|
|
14
14
|
texCache: -1,
|
|
15
15
|
});
|
|
16
16
|
|
|
@@ -123,4 +123,4 @@ const onKeyDown = (ev) => {
|
|
|
123
123
|
color: #ffffff;
|
|
124
124
|
font-size: 20;
|
|
125
125
|
}
|
|
126
|
-
</style>
|
|
126
|
+
</style>
|
|
@@ -44,10 +44,10 @@ const titleStyle = {
|
|
|
44
44
|
|
|
45
45
|
<template>
|
|
46
46
|
<div :style=props.style>
|
|
47
|
-
<div class="container-
|
|
47
|
+
<div class="container-config" :style=titleStyle>
|
|
48
48
|
{{ title }}
|
|
49
49
|
</div>
|
|
50
|
-
<div class="content-
|
|
50
|
+
<div class="content-config" :style="{
|
|
51
51
|
top: titleStyle.lineHeight,
|
|
52
52
|
width: props.style.width, height: props.style.height - 18,
|
|
53
53
|
backgroundColor: 'rgba(0,0,0,' + blockOpacity + ')'
|
|
@@ -59,5 +59,5 @@ const titleStyle = {
|
|
|
59
59
|
|
|
60
60
|
<style>
|
|
61
61
|
/* css文件要单独放到没有scoped设置的style标签中,规避css属性redefine的warning */
|
|
62
|
-
@import "./
|
|
62
|
+
@import "./FontConfig.css";
|
|
63
63
|
</style>
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
|
|
2
|
-
.title-
|
|
2
|
+
.title-config {
|
|
3
3
|
color:#877c4a;
|
|
4
4
|
font-family: 黑体;
|
|
5
5
|
font-size: 16;
|
|
6
6
|
text-align: center;
|
|
7
7
|
}
|
|
8
8
|
|
|
9
|
-
.container-
|
|
9
|
+
.container-config {
|
|
10
10
|
color: #FFFFFF;
|
|
11
11
|
font-family: 黑体;
|
|
12
12
|
font-size: 16;
|
|
13
13
|
}
|
|
14
14
|
|
|
15
|
-
.content-
|
|
15
|
+
.content-config {
|
|
16
16
|
color: #000000;
|
|
17
17
|
font-family: 黑体;
|
|
18
18
|
font-size: 10;
|
|
@@ -8,7 +8,7 @@ const props = defineProps({
|
|
|
8
8
|
<template>
|
|
9
9
|
<div>
|
|
10
10
|
<template v-for="(title, index) in props.titleData" :key="index">
|
|
11
|
-
<div class='title-
|
|
11
|
+
<div class='title-config title-range' :style="{ left: props.style.width * index }">
|
|
12
12
|
{{ title }}
|
|
13
13
|
</div>
|
|
14
14
|
</template>
|
|
@@ -25,5 +25,5 @@ const props = defineProps({
|
|
|
25
25
|
</style>
|
|
26
26
|
<style>
|
|
27
27
|
/* css文件要单独放到没有scoped设置的style标签中,规避css属性redefine的warning */
|
|
28
|
-
@import "./
|
|
28
|
+
@import "./FontConfig.css";
|
|
29
29
|
</style>
|
package/CustomShader/App.vue
CHANGED
|
@@ -112,11 +112,11 @@ const onKeyDown = (ev) => {
|
|
|
112
112
|
};
|
|
113
113
|
|
|
114
114
|
onMounted(() => {
|
|
115
|
-
window.
|
|
115
|
+
window.JsvCoreApi.enableFpsDisplay(true);
|
|
116
116
|
});
|
|
117
117
|
|
|
118
118
|
onUnmounted(() => {
|
|
119
|
-
window.
|
|
119
|
+
window.JsvCoreApi.enableFpsDisplay(false);
|
|
120
120
|
});
|
|
121
121
|
</script>
|
|
122
122
|
|
|
@@ -19,10 +19,6 @@ let vInvToken = setInterval(() => {
|
|
|
19
19
|
rIndex.value++;
|
|
20
20
|
rMyWidth.value = cWidth[rIndex.value % cWidth.length];
|
|
21
21
|
rMyHeight.value = cHeight[rIndex.value % cHeight.length];
|
|
22
|
-
if (!window.JsView) {
|
|
23
|
-
// PC模拟环境要通过key来刷新确保界面flex正常
|
|
24
|
-
rRefreshId.value = rIndex.value;
|
|
25
|
-
}
|
|
26
22
|
}, 2000);
|
|
27
23
|
|
|
28
24
|
onUnmounted(() => {
|
package/GiftRain/App.vue
CHANGED
package/HashParams/App.vue
CHANGED
package/JsvPreDownloader/App.vue
CHANGED
|
@@ -144,7 +144,6 @@ const onKeyDown = (ev) => {
|
|
|
144
144
|
font-size: 30;
|
|
145
145
|
white-space: pre-wrap;
|
|
146
146
|
text-overflow: clip;
|
|
147
|
-
overflow: hidden;
|
|
148
147
|
}
|
|
149
148
|
.block {
|
|
150
149
|
width: 170;
|
|
@@ -154,6 +153,5 @@ const onKeyDown = (ev) => {
|
|
|
154
153
|
font-size: 24;
|
|
155
154
|
white-space: pre-wrap;
|
|
156
155
|
text-overflow: clip;
|
|
157
|
-
overflow: hidden;
|
|
158
156
|
}
|
|
159
157
|
</style>
|
package/Marquee/App.vue
CHANGED
|
@@ -24,7 +24,7 @@ const style = {
|
|
|
24
24
|
const style2 = Object.assign({ textAlign: "center" }, style);
|
|
25
25
|
const style3 = Object.assign({ textAlign: "end" }, style);
|
|
26
26
|
const longText =
|
|
27
|
-
"
|
|
27
|
+
"1.石室诗士施氏,嗜狮,誓食十狮。2.施氏时时适市视狮。3.十时,适十狮适市。4.是时,适施氏适市。5.施氏视是十狮,恃矢势,使是十狮逝世。6.氏拾是十狮尸,适石室。7.石室湿,氏使侍拭石室。8.石室拭,施氏始试食是十狮尸。9.食时,始识是十狮尸,实十石狮尸。10.试释是事。";
|
|
28
28
|
const shortText = "测试文字";
|
|
29
29
|
const littleLongText = "君不见,黄河之水天上来,奔流到海不复回。";
|
|
30
30
|
const rtlText = 'ABC انجليزي "abc" سعر الملابس 180 ';
|
|
@@ -784,7 +784,7 @@ onMounted(() => {
|
|
|
784
784
|
top: 210,
|
|
785
785
|
width: width,
|
|
786
786
|
height: height,
|
|
787
|
-
backgroundColor: '#FFFFFF'
|
|
787
|
+
backgroundColor: '#FFFFFF',
|
|
788
788
|
}"
|
|
789
789
|
>
|
|
790
790
|
<jsv-marquee
|
|
@@ -12,7 +12,7 @@ const props = defineProps({
|
|
|
12
12
|
name: String,
|
|
13
13
|
onEdgeDown: Function,
|
|
14
14
|
onItemFocus: Function,
|
|
15
|
-
})
|
|
15
|
+
});
|
|
16
16
|
|
|
17
17
|
let activeId = shallowRef(0);
|
|
18
18
|
let focused = shallowRef(false);
|
|
@@ -25,7 +25,7 @@ const tab1Class = computed(() => {
|
|
|
25
25
|
} else {
|
|
26
26
|
return "text-normal item-normal";
|
|
27
27
|
}
|
|
28
|
-
})
|
|
28
|
+
});
|
|
29
29
|
const tab2Class = computed(() => {
|
|
30
30
|
if (activeId.value == 1) {
|
|
31
31
|
return focused.value
|
|
@@ -34,7 +34,7 @@ const tab2Class = computed(() => {
|
|
|
34
34
|
} else {
|
|
35
35
|
return "text-normal item-normal";
|
|
36
36
|
}
|
|
37
|
-
})
|
|
37
|
+
});
|
|
38
38
|
const tab3Class = computed(() => {
|
|
39
39
|
if (activeId.value == 2) {
|
|
40
40
|
return focused.value
|
|
@@ -43,8 +43,7 @@ const tab3Class = computed(() => {
|
|
|
43
43
|
} else {
|
|
44
44
|
return "text-normal item-normal";
|
|
45
45
|
}
|
|
46
|
-
})
|
|
47
|
-
|
|
46
|
+
});
|
|
48
47
|
|
|
49
48
|
const onKeyDown = (ev) => {
|
|
50
49
|
switch (ev.keyCode) {
|
|
@@ -54,35 +53,37 @@ const onKeyDown = (ev) => {
|
|
|
54
53
|
activeId.value = 2;
|
|
55
54
|
}
|
|
56
55
|
props.onItemFocus(activeId.value);
|
|
57
|
-
|
|
56
|
+
return true;
|
|
58
57
|
case 39:
|
|
59
58
|
activeId.value++;
|
|
60
59
|
if (activeId.value > 2) {
|
|
61
60
|
activeId.value = 0;
|
|
62
61
|
}
|
|
63
62
|
props.onItemFocus(activeId.value);
|
|
64
|
-
|
|
63
|
+
return true;
|
|
65
64
|
case 40:
|
|
66
65
|
props.onEdgeDown();
|
|
67
|
-
|
|
66
|
+
return true;
|
|
68
67
|
}
|
|
69
|
-
}
|
|
68
|
+
};
|
|
70
69
|
const onFocus = () => {
|
|
71
70
|
focused.value = true;
|
|
72
|
-
}
|
|
71
|
+
};
|
|
73
72
|
const onBlur = () => {
|
|
74
73
|
focused.value = false;
|
|
75
|
-
}
|
|
74
|
+
};
|
|
76
75
|
const actionDefines = {
|
|
77
76
|
onBlur,
|
|
78
77
|
onFocus,
|
|
79
|
-
onKeyDown
|
|
80
|
-
}
|
|
81
|
-
|
|
78
|
+
onKeyDown,
|
|
79
|
+
};
|
|
82
80
|
</script>
|
|
83
81
|
|
|
84
82
|
<template>
|
|
85
|
-
<jsv-focus-block
|
|
83
|
+
<jsv-focus-block
|
|
84
|
+
:name="props.name"
|
|
85
|
+
:onAction="actionDefines"
|
|
86
|
+
></jsv-focus-block>
|
|
86
87
|
<div :class="tab1Class">Tab1</div>
|
|
87
88
|
<div :class="tab2Class" :style="{ left: 220 }">Tab2</div>
|
|
88
89
|
<div :class="tab3Class" :style="{ left: 440 }">Tab3</div>
|
|
@@ -115,6 +116,6 @@ const actionDefines = {
|
|
|
115
116
|
.item-normal {
|
|
116
117
|
width: 200;
|
|
117
118
|
height: 50;
|
|
118
|
-
background-color: #
|
|
119
|
+
background-color: #87cecb;
|
|
119
120
|
}
|
|
120
|
-
</style>
|
|
121
|
+
</style>
|
package/PosterPacker/App.vue
CHANGED
|
@@ -114,11 +114,11 @@ const myEnd = () => {
|
|
|
114
114
|
console.log("动画结束");
|
|
115
115
|
};
|
|
116
116
|
onMounted(() => {
|
|
117
|
-
window.
|
|
117
|
+
window.JsvCoreApi.enableFpsDisplay(true);
|
|
118
118
|
});
|
|
119
119
|
|
|
120
120
|
onUnmounted(() => {
|
|
121
|
-
window.
|
|
121
|
+
window.JsvCoreApi.enableFpsDisplay(false);
|
|
122
122
|
});
|
|
123
123
|
</script>
|
|
124
124
|
|
|
@@ -609,7 +609,7 @@ watchEffect(() => {
|
|
|
609
609
|
console.log("rShow", rShow.value);
|
|
610
610
|
});
|
|
611
611
|
onMounted(() => {
|
|
612
|
-
window.
|
|
612
|
+
window.JsvCoreApi.enableFpsDisplay(true);
|
|
613
613
|
});
|
|
614
614
|
|
|
615
615
|
onUnmounted(() => {
|
|
@@ -618,7 +618,7 @@ onUnmounted(() => {
|
|
|
618
618
|
vNextTickStartAnimTimer = -1;
|
|
619
619
|
}
|
|
620
620
|
|
|
621
|
-
window.
|
|
621
|
+
window.JsvCoreApi.enableFpsDisplay(false);
|
|
622
622
|
});
|
|
623
623
|
onBeforeUnmount(() => {
|
|
624
624
|
cStyleShell.removeRule("contract");
|
|
@@ -50,7 +50,7 @@ let myY = 0.5;
|
|
|
50
50
|
let keyNum = shallowRef(0);
|
|
51
51
|
//ref
|
|
52
52
|
const rWidgetRef = shallowRef();
|
|
53
|
-
let vSTRENGTH =
|
|
53
|
+
let vSTRENGTH = "10.";
|
|
54
54
|
//替换
|
|
55
55
|
let replacedShader = shallowRef(
|
|
56
56
|
vortexShader
|
|
@@ -58,28 +58,28 @@ let replacedShader = shallowRef(
|
|
|
58
58
|
.replace(/\$\{myCustomCenterY\}/g, myY)
|
|
59
59
|
.replace(/\$\{STRENGTH\}/g, vSTRENGTH)
|
|
60
60
|
);
|
|
61
|
-
console.log(9998,vortexShader);
|
|
61
|
+
console.log(9998, vortexShader);
|
|
62
62
|
|
|
63
63
|
//随机替换
|
|
64
64
|
const getRandomDecimal = () => {
|
|
65
65
|
myX = 0.9;
|
|
66
66
|
myY = 0.1;
|
|
67
67
|
//根据x轴的位置确定转数
|
|
68
|
-
if(myX>=0.8||myX<=0.2){
|
|
69
|
-
console.log(
|
|
70
|
-
vSTRENGTH =
|
|
71
|
-
}else if(myX>0.2<=0.4){
|
|
72
|
-
|
|
73
|
-
}else if(myX >=0.6 && myX < 0.8
|
|
74
|
-
|
|
75
|
-
}else if(myX>0.4 && myX<0.6){
|
|
76
|
-
vSTRENGTH =
|
|
68
|
+
if (myX >= 0.8 || myX <= 0.2) {
|
|
69
|
+
console.log("很小或很大");
|
|
70
|
+
vSTRENGTH = "40.";
|
|
71
|
+
} else if (myX > 0.2 <= 0.4) {
|
|
72
|
+
vSTRENGTH = "30.";
|
|
73
|
+
} else if (myX >= 0.6 && myX < 0.8) {
|
|
74
|
+
vSTRENGTH = "30.";
|
|
75
|
+
} else if (myX > 0.4 && myX < 0.6) {
|
|
76
|
+
vSTRENGTH = "10.";
|
|
77
77
|
}
|
|
78
78
|
|
|
79
79
|
replacedShader.value = vortexShader
|
|
80
80
|
.replace(/\$\{myCustomCenterX\}/g, myX)
|
|
81
81
|
.replace(/\$\{myCustomCenterY\}/g, myY)
|
|
82
|
-
.replace(/\$\{STRENGTH\}/g, vSTRENGTH)
|
|
82
|
+
.replace(/\$\{STRENGTH\}/g, vSTRENGTH);
|
|
83
83
|
keyNum.value += 1;
|
|
84
84
|
};
|
|
85
85
|
//接收外部设定中心点
|
|
@@ -118,11 +118,11 @@ const rShaderInfo = computed(() => {
|
|
|
118
118
|
return cShaderSettings;
|
|
119
119
|
});
|
|
120
120
|
onMounted(() => {
|
|
121
|
-
window.
|
|
121
|
+
window.JsvCoreApi.enableFpsDisplay(true);
|
|
122
122
|
});
|
|
123
123
|
|
|
124
124
|
onUnmounted(() => {
|
|
125
|
-
window.
|
|
125
|
+
window.JsvCoreApi.enableFpsDisplay(false);
|
|
126
126
|
});
|
|
127
127
|
//向父组件暴露方法
|
|
128
128
|
defineExpose({
|
package/ScaleDownNeon/App.vue
CHANGED
|
@@ -9,19 +9,22 @@
|
|
|
9
9
|
import { useRouter } from "vue-router";
|
|
10
10
|
const router = useRouter();
|
|
11
11
|
|
|
12
|
-
const test1 =
|
|
13
|
-
|
|
14
|
-
const
|
|
15
|
-
|
|
12
|
+
const test1 =
|
|
13
|
+
"url(https://qcast-image.oss-cn-qingdao.aliyuncs.com/JsViewVideo/ImageTestSample/ScaleDownTest/test_1.jpeg)";
|
|
14
|
+
const test2 =
|
|
15
|
+
"url(https://qcast-image.oss-cn-qingdao.aliyuncs.com/JsViewVideo/ImageTestSample/ScaleDownTest/test_2.jpeg)";
|
|
16
|
+
const test3 =
|
|
17
|
+
"url(https://qcast-image.oss-cn-qingdao.aliyuncs.com/JsViewVideo/ImageTestSample/ScaleDownTest/test_3.jpeg)";
|
|
18
|
+
const test4 =
|
|
19
|
+
"url(https://qcast-image.oss-cn-qingdao.aliyuncs.com/JsViewVideo/ImageTestSample/ScaleDownTest/test_4.jpeg)";
|
|
16
20
|
|
|
17
21
|
const onKeyDown = (ev) => {
|
|
18
22
|
// 8:Backspace, 27:Escape, 10000:盒子返回键
|
|
19
23
|
if (ev.keyCode == 8 || ev.keyCode == 27 || ev.keyCode == 10000) {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
}
|
|
24
|
+
// 关掉TextureCache(通过将waterLevel设置成-1)
|
|
25
|
+
window.JsvCoreApi.setRenderGlobalConfig({
|
|
26
|
+
texCache: -1,
|
|
27
|
+
});
|
|
25
28
|
|
|
26
29
|
router.go(-1); // 有router时,回退
|
|
27
30
|
return true;
|
|
@@ -104,4 +107,4 @@ const style2 = {
|
|
|
104
107
|
.top250 {
|
|
105
108
|
top: 250;
|
|
106
109
|
}
|
|
107
|
-
</style>
|
|
110
|
+
</style>
|
package/SceneTransition/App.vue
CHANGED
|
@@ -18,7 +18,9 @@
|
|
|
18
18
|
</div>
|
|
19
19
|
<!-- 文字说明 -->
|
|
20
20
|
<div class="textLong" :style="{ left: 20, top: 20 }">
|
|
21
|
-
{{
|
|
21
|
+
{{
|
|
22
|
+
"操作说明:按【下】键进行随机碎片下落过渡效果。按【上】键进行过渡还原。"
|
|
23
|
+
}}
|
|
22
24
|
</div>
|
|
23
25
|
<div class="text" :style="{ left: 810, top: 20 }">{{ "素材展示" }}</div>
|
|
24
26
|
<div class="text" :style="{ left: 400, top: 500 }">
|
|
@@ -133,8 +135,7 @@ const onKeyDown = (ev) => {
|
|
|
133
135
|
boxSwitch.value = false;
|
|
134
136
|
}, 1000);
|
|
135
137
|
}
|
|
136
|
-
|
|
137
|
-
break;
|
|
138
|
+
return true;
|
|
138
139
|
|
|
139
140
|
//按方向键上调用组件的恢复函数
|
|
140
141
|
case 38:
|
|
@@ -142,7 +143,7 @@ const onKeyDown = (ev) => {
|
|
|
142
143
|
control.value.fireNeEvent();
|
|
143
144
|
down.value = false;
|
|
144
145
|
}
|
|
145
|
-
|
|
146
|
+
return true;
|
|
146
147
|
default:
|
|
147
148
|
break;
|
|
148
149
|
}
|
package/TextureAnimation/App.vue
CHANGED
|
@@ -1,13 +1,8 @@
|
|
|
1
1
|
<script setup>
|
|
2
|
-
import {
|
|
3
|
-
jJsvRuntimeBridge,
|
|
4
|
-
getKeyFramesGroup,
|
|
5
|
-
JsvTextureAnim,
|
|
6
|
-
DefaultKeyCodeMap,
|
|
7
|
-
} from "jsview";
|
|
2
|
+
import { jJsvRuntimeBridge, getKeyFramesGroup, JsvTextureAnim } from "jsview";
|
|
8
3
|
import img from "./assets/borderOpacity.png";
|
|
9
4
|
import swipLight from "./assets/swipLight.png";
|
|
10
|
-
import { onMounted, onBeforeUnmount
|
|
5
|
+
import { onMounted, onBeforeUnmount } from "vue";
|
|
11
6
|
import { useRouter } from "vue-router";
|
|
12
7
|
const router = useRouter();
|
|
13
8
|
const styleShell = getKeyFramesGroup();
|
|
@@ -18,9 +13,6 @@ const borderRadius = 40;
|
|
|
18
13
|
const repeat = -1;
|
|
19
14
|
const duration = 3000;
|
|
20
15
|
|
|
21
|
-
let sTranslateTextureRef = shallowRef(null);
|
|
22
|
-
let sTranslateTextureTrigger = shallowRef(1);
|
|
23
|
-
|
|
24
16
|
const translateAnim =
|
|
25
17
|
"{from {transform: translate3d(-100%, -50%, 0);} to {transform: translate3d(100%, 50%, 0);}}";
|
|
26
18
|
const rotateAnim =
|
|
@@ -38,9 +30,6 @@ const onKeyDown = (ev) => {
|
|
|
38
30
|
// 8:Backspace, 27:Escape, 10000:盒子返回键
|
|
39
31
|
if (ev.keyCode == 8 || ev.keyCode == 27 || ev.keyCode == 10000) {
|
|
40
32
|
router?.go(-1); // 有router时,是从DemoHomepage进入,回退
|
|
41
|
-
} else if (ev.keyCode == DefaultKeyCodeMap.Ok) {
|
|
42
|
-
sTranslateTextureRef.value.start();
|
|
43
|
-
sTranslateTextureTrigger.value = sTranslateTextureTrigger.value + 1;
|
|
44
33
|
}
|
|
45
34
|
return true;
|
|
46
35
|
};
|
|
@@ -79,7 +68,6 @@ onBeforeUnmount(() => {
|
|
|
79
68
|
}"
|
|
80
69
|
/>
|
|
81
70
|
<jsv-texture-anim
|
|
82
|
-
ref="sTranslateTextureRef"
|
|
83
71
|
:src="img"
|
|
84
72
|
:width="300"
|
|
85
73
|
:height="150"
|
|
@@ -87,16 +75,18 @@ onBeforeUnmount(() => {
|
|
|
87
75
|
:duration="duration"
|
|
88
76
|
:transform="null"
|
|
89
77
|
:borderRadius="borderRadius"
|
|
78
|
+
:repeat="repeat"
|
|
90
79
|
:autoStart="true"
|
|
91
80
|
></jsv-texture-anim>
|
|
92
81
|
<div
|
|
93
|
-
:key="sTranslateTextureTrigger"
|
|
94
82
|
:style="{
|
|
95
83
|
width: 300,
|
|
96
84
|
height: 150,
|
|
97
85
|
backgroundColor: 'rgba(255,0,0,0.5)',
|
|
98
86
|
transform: null,
|
|
99
|
-
animation: `texture-anim-translate ${
|
|
87
|
+
animation: `texture-anim-translate ${
|
|
88
|
+
duration / 1000
|
|
89
|
+
}s linear infinite`,
|
|
100
90
|
}"
|
|
101
91
|
/>
|
|
102
92
|
</div>
|
package/TextureSize/App.vue
CHANGED
|
@@ -10,11 +10,10 @@ const router = useRouter();
|
|
|
10
10
|
const onKeyDown = (ev) => {
|
|
11
11
|
// 8:Backspace, 27:Escape, 10000:盒子返回键
|
|
12
12
|
if (ev.keyCode == 8 || ev.keyCode == 27 || ev.keyCode == 10000) {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
}
|
|
13
|
+
// 关掉TextureCache(通过将waterLevel设置成-1)
|
|
14
|
+
window.JsvCoreApi.setRenderGlobalConfig({
|
|
15
|
+
texCache: -1,
|
|
16
|
+
});
|
|
18
17
|
|
|
19
18
|
router.go(-1); // 有router时,回退
|
|
20
19
|
return true;
|
|
@@ -129,4 +128,4 @@ const onKeyDown = (ev) => {
|
|
|
129
128
|
color: #ffffff;
|
|
130
129
|
font-size: 20;
|
|
131
130
|
}
|
|
132
|
-
</style>
|
|
131
|
+
</style>
|
package/ViewOpacity/App.vue
CHANGED
|
@@ -18,11 +18,10 @@ const test2 =
|
|
|
18
18
|
const onKeyDown = (ev) => {
|
|
19
19
|
// 8:Backspace, 27:Escape, 10000:盒子返回键
|
|
20
20
|
if (ev.keyCode == 8 || ev.keyCode == 27 || ev.keyCode == 10000) {
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
}
|
|
21
|
+
// 关掉TextureCache(通过将waterLevel设置成-1)
|
|
22
|
+
window.JsvCoreApi.setRenderGlobalConfig({
|
|
23
|
+
texCache: -1,
|
|
24
|
+
});
|
|
26
25
|
|
|
27
26
|
router.go(-1); // 有router时,回退
|
|
28
27
|
return true;
|