@shijiu/jsview-vue 0.9.426 → 0.9.502

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.
Files changed (63) hide show
  1. package/dom/bin/jsview-browser-debug-dom.min.js +1 -1
  2. package/dom/bin/jsview-dom.min.js +1 -1
  3. package/dom/jsv-browser-debug-dom.js_1 +8 -0
  4. package/dom/jsv-dom.js_1 +6 -0
  5. package/dom/jsv-forge-define.js_1 +6 -0
  6. package/dom/target_core_revision.js +3 -3
  7. package/package.json +1 -1
  8. package/patches/node_modules/@vue/cli-service/lib/config/assets.js +1 -1
  9. package/patches/node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.js +4 -1
  10. package/samples/ColorSpace/App.vue +4 -4
  11. package/samples/DemoHomepage/router.js +17 -2
  12. package/samples/FilterDemo/App.vue +121 -0
  13. package/samples/GridDemo/App.vue +183 -0
  14. package/samples/GridDemo/ButtonBlock.vue +111 -0
  15. package/samples/GridDemo/FocusItem.vue +56 -0
  16. package/samples/GridDemo/Item.vue +101 -0
  17. package/samples/NinePatchDemo/App.vue +146 -0
  18. package/samples/NinePatchDemo/Item.vue +70 -0
  19. package/samples/NinePatchDemo/assets/border.png +0 -0
  20. package/samples/TouchSample/App.vue +137 -0
  21. package/samples/TouchSample/Item.vue +101 -0
  22. package/samples/TouchSample/MetroWidgetHorizontal.vue +144 -0
  23. package/samples/TouchSample/MetroWidgetVertical.vue +144 -0
  24. package/samples/TouchSample/TouchContainerHorizontal.vue +159 -0
  25. package/samples/TouchSample/TouchContainerVertical.vue +159 -0
  26. package/samples/TouchSample/data.js +81 -0
  27. package/samples/{ColorSpace → assets}/bmpDemo.bmp +0 -0
  28. package/samples/{ColorSpace → assets}/jpegDemo.jpeg +0 -0
  29. package/samples/{ColorSpace → assets}/pngDemo.png +0 -0
  30. package/samples/{ColorSpace → assets}/pngNoAlphaDemo.png +0 -0
  31. package/samples/assets/webpDemo.webp +0 -0
  32. package/scripts/jsview-jsmap-serve.js +63 -0
  33. package/scripts/jsview-post-build.js +50 -3
  34. package/scripts/jsview-post-install.js +22 -0
  35. package/utils/JsViewEngineWidget/JsvFocusBlock.vue +7 -5
  36. package/utils/JsViewEngineWidget/JsvFocusManager.js +5 -0
  37. package/utils/JsViewEngineWidget/MetroWidget/ItemView.vue +7 -14
  38. package/utils/JsViewEngineWidget/MetroWidget/MetroWidget.vue +214 -89
  39. package/utils/JsViewEngineWidget/MetroWidget/RootView.vue +4 -3
  40. package/utils/JsViewEngineWidget/SimpleWidget/SimpleWidget.vue +2 -0
  41. package/utils/JsViewEngineWidget/TemplateParser.js +8 -6
  42. package/utils/JsViewPlugin/JsvPlayer/GetVersion.js +20 -0
  43. package/utils/JsViewPlugin/JsvPlayer/JsvMedia.js +220 -85
  44. package/utils/JsViewPlugin/JsvPlayer/JsvPlayer.vue +43 -14
  45. package/utils/JsViewPlugin/JsvPlayer/JsvPlayerBrowser.vue +25 -12
  46. package/utils/JsViewPlugin/JsvPlayer/index.js +4 -0
  47. package/utils/JsViewPlugin/JsvPlayer/version.js +19 -0
  48. package/utils/JsViewVueTools/DebugTool.js +24 -0
  49. package/utils/JsViewVueTools/NinePatchHelper.js +44 -0
  50. package/utils/JsViewVueTools/TypeCheckAndSet.js +27 -0
  51. package/utils/JsViewVueWidget/BrowserDebugWidget/BrowserQrcode.vue +19 -8
  52. package/utils/JsViewVueWidget/BrowserDebugWidget/JsvApic/BrowserApic.vue +1 -1
  53. package/utils/JsViewVueWidget/JsvApic/JsvApic.vue +2 -2
  54. package/utils/JsViewVueWidget/JsvFilterView.vue +73 -0
  55. package/utils/JsViewVueWidget/JsvGrid.vue +573 -0
  56. package/utils/JsViewVueWidget/JsvInput/JsvInput.vue +7 -0
  57. package/utils/JsViewVueWidget/JsvNinePatch.vue +2 -2
  58. package/utils/JsViewVueWidget/JsvQrcode/JsvQrcode.vue +12 -3
  59. package/utils/JsViewVueWidget/JsvSpray/JsvSpray.vue +1 -1
  60. package/utils/JsViewVueWidget/JsvTextureAnim/CommonType.js +8 -0
  61. package/utils/JsViewVueWidget/JsvTextureAnim/JsvTextureAnim.vue +171 -38
  62. package/utils/JsViewVueWidget/JsvTextureAnim/index.js +3 -2
  63. package/utils/JsViewVueWidget/JsvTouchContainer.vue +184 -0
@@ -0,0 +1,137 @@
1
+ <!--
2
+ * @Author: ChenChanghua
3
+ * @Date: 2022-04-10 21:20:39
4
+ * @LastEditors: ChenChanghua
5
+ * @LastEditTime: 2022-04-11 09:51:24
6
+ * @Description: file content
7
+ -->
8
+ <script>
9
+ import JsvTouchContainer from "jsview/utils/JsViewVueWidget/JsvTouchContainer.vue";
10
+ import MetroWidgetHorizontal from "./MetroWidgetHorizontal.vue";
11
+ import MetroWidgetVertical from "./MetroWidgetVertical.vue";
12
+ import TouchContainerHorizontal from "./TouchContainerHorizontal.vue";
13
+ import TouchContainerVertical from "./TouchContainerVertical.vue";
14
+ import { jJsvRuntimeBridge } from "jsview/utils/JsViewVueTools/JsvRuntimeBridge";
15
+
16
+ export default {
17
+ components: {
18
+ MetroWidgetHorizontal,
19
+ MetroWidgetVertical,
20
+ TouchContainerHorizontal,
21
+ JsvTouchContainer,
22
+ TouchContainerVertical,
23
+ },
24
+ data() {
25
+ return {
26
+ metroVerticalVisible: false,
27
+ metroHorizontalVisible: true,
28
+ touchContainerHorizontalVisible: false,
29
+ touchContainerVerticalVisible: false,
30
+ head: "SimpleWidget 横向",
31
+ };
32
+ },
33
+ setup() {
34
+ const tabList = [
35
+ "SimpleWidget 横向",
36
+ "SimpleWidget 纵向",
37
+ "TouchContainer 横向",
38
+ "TouchContainer 纵向",
39
+ ];
40
+ return {
41
+ tabList,
42
+ };
43
+ },
44
+ methods: {
45
+ _onClick(id) {
46
+ switch (id) {
47
+ case 0:
48
+ this.head = "SimpleWidget 横向";
49
+ this.metroVerticalVisible = false;
50
+ this.metroHorizontalVisible = true;
51
+ this.touchContainerHorizontalVisible = false;
52
+ this.touchContainerVerticalVisible = false;
53
+ break;
54
+ case 1:
55
+ this.head = "SimpleWidget 纵向";
56
+ this.metroVerticalVisible = true;
57
+ this.metroHorizontalVisible = false;
58
+ this.touchContainerHorizontalVisible = false;
59
+ this.touchContainerVerticalVisible = false;
60
+ break;
61
+ case 2:
62
+ this.head = "TouchContainer 横向";
63
+ this.metroVerticalVisible = false;
64
+ this.metroHorizontalVisible = false;
65
+ this.touchContainerHorizontalVisible = true;
66
+ this.touchContainerVerticalVisible = false;
67
+ break;
68
+ case 3:
69
+ this.head = "TouchContainer 纵向";
70
+ this.metroVerticalVisible = false;
71
+ this.metroHorizontalVisible = false;
72
+ this.touchContainerHorizontalVisible = false;
73
+ this.touchContainerVerticalVisible = true;
74
+ break;
75
+ default:
76
+ break;
77
+ }
78
+ return true;
79
+ },
80
+ },
81
+ mounted() {
82
+ jJsvRuntimeBridge.notifyPageLoaded();
83
+ },
84
+ };
85
+ </script>
86
+
87
+ <template>
88
+ <div
89
+ :style="{
90
+ width: 1280,
91
+ height: 720 * 2,
92
+ backgroundColor: '#1b2697',
93
+ }"
94
+ >
95
+ <jsv-touch-container
96
+ v-for="(title, index) of tabList"
97
+ :key="'tab' + index"
98
+ :style="{
99
+ left: 50 + 300 * index,
100
+ top: 10,
101
+ width: 280,
102
+ height: 50,
103
+ backgroundColor: '#ff0000',
104
+ fontSize: 18,
105
+ lineHeight: '50px',
106
+ }"
107
+ :onClick="
108
+ () => {
109
+ return this._onClick(index);
110
+ }
111
+ "
112
+ :direction="DIRECTION_DISABLE"
113
+ >
114
+ {{ title }}
115
+ </jsv-touch-container>
116
+
117
+ <div
118
+ :style="{
119
+ left: 30,
120
+ top: 60,
121
+ width: 400,
122
+ height: 50,
123
+ fontSize: 30,
124
+ lineHeight: '50px',
125
+ color: '#f0ef29',
126
+ }"
127
+ >
128
+ {{ head }}
129
+ </div>
130
+ <div :style="{ left: 30, top: 120 }">
131
+ <metro-widget-horizontal v-if="metroHorizontalVisible" />
132
+ <metro-widget-vertical v-if="metroVerticalVisible" />
133
+ <touch-container-horizontal v-if="touchContainerHorizontalVisible" />
134
+ <touch-container-vertical v-if="touchContainerVerticalVisible" />
135
+ </div>
136
+ </div>
137
+ </template>
@@ -0,0 +1,101 @@
1
+ <!--
2
+ * @Author: ChenChanghua
3
+ * @Date: 2022-04-10 21:21:43
4
+ * @LastEditors: ChenChanghua
5
+ * @LastEditTime: 2022-04-10 21:21:44
6
+ * @Description: file content
7
+ -->
8
+ <script>
9
+ import { getPositionRelativeToView } from "jsview/utils/JsViewEngineWidget";
10
+ function randomColor() {
11
+ let randomColor = Math.round(Math.random() * 2 ** 24).toString(16);
12
+ return (
13
+ "#" + new Array(6 - randomColor.length).fill("0").join("") + randomColor
14
+ );
15
+ }
16
+ export default {
17
+ props: {
18
+ data: Object,
19
+ query: Object,
20
+ onEdge: Function,
21
+ onAction: Object,
22
+ test: Object,
23
+ },
24
+ data() {
25
+ return {
26
+ focused: false,
27
+ };
28
+ },
29
+ setup() {
30
+ return {
31
+ randomColor,
32
+ }
33
+ },
34
+ computed: {
35
+ style() {
36
+ return {
37
+ width: this.data.width,
38
+ height: this.data.height,
39
+ color: "#FFFFFF",
40
+ backgroundColor: this.focused ? "#FF0000" : this.data.color,
41
+ };
42
+ },
43
+ },
44
+ methods: {
45
+ onFocus() {
46
+ this.focused = true;
47
+ console.log("cchtest item onfocus", this.data)
48
+ },
49
+
50
+ onBlur() {
51
+ this.focused = false;
52
+ },
53
+
54
+ onClick() {
55
+ console.log(`item ${this.query.id} clicked`);
56
+ }
57
+ },
58
+ created() {
59
+ // console.log("cchtest item created", this.data.content)
60
+ this.onAction.register("onFocus", this.onFocus);
61
+ this.onAction.register("onBlur", this.onBlur);
62
+ this.onAction.register("onClick", this.onClick);
63
+ },
64
+ mounted() {
65
+ // console.log("cchtest item mounted", this.data.content)
66
+ },
67
+ beforeUnmount() {
68
+ // console.log("cchtest item unmount", this.data.content)
69
+ },
70
+ updated() {
71
+ // console.log("cchtest item update", this.data.content)
72
+ }
73
+ };
74
+ </script>
75
+
76
+ <template>
77
+ <div ref="element" :class="focused ? 'focus' : 'blur'" :style="style">
78
+ {{ data.content }}
79
+ </div>
80
+ <div :style="{
81
+ left: data.width/2,
82
+ top: data.height/2,
83
+ width: 10,
84
+ height: 10,
85
+ backgroundColor: focused ? '#000000' : '#FF0000'
86
+ }"/>
87
+ </template>
88
+
89
+ <style scoped>
90
+ .focus {
91
+ transform: scale3d(1.0, 1.0, 1);
92
+ transition: transform 0.25s linear;
93
+ font-size: 30px;
94
+ }
95
+
96
+ .blur {
97
+ transform: scale3d(1, 1, 1);
98
+ transition: transform 0.25s linear;
99
+ font-size: 30px;
100
+ }
101
+ </style>
@@ -0,0 +1,144 @@
1
+ <script>
2
+ import {
3
+ HORIZONTAL,
4
+ MetroWidget,
5
+ WholePageSlide,
6
+ SeamlessSlide,
7
+ FixPositionSlide,
8
+ } from "jsview/utils/JsViewEngineWidget";
9
+
10
+ import Item from "./Item.vue";
11
+
12
+ import { metroWidgetH, measures } from "./data.js";
13
+ import { ref } from "vue";
14
+
15
+ export default {
16
+ components: {
17
+ MetroWidget,
18
+ Item,
19
+ },
20
+ setup() {
21
+ return {
22
+ measures,
23
+ name: "/metroWidgetH",
24
+ direction: HORIZONTAL,
25
+ wholePageSlide: new WholePageSlide({
26
+ speed: 1.5,
27
+ }),
28
+ seamlessSlide: new SeamlessSlide({
29
+ startPercent: 0.4,
30
+ endPercent: 0.6,
31
+ speed: 0.5,
32
+ }),
33
+ fixPositionSlide: new FixPositionSlide({
34
+ fixPercent: 0.5,
35
+ speed: 0.5,
36
+ }),
37
+ token: ref(0),
38
+ CONST_ITEM_WIDTH: 100,
39
+ CONST_ITEM_HEIGHT: 200,
40
+ };
41
+ },
42
+ methods: {
43
+ _provideData() {
44
+ return metroWidgetH;
45
+ },
46
+ },
47
+
48
+ mounted() {},
49
+ };
50
+ </script>
51
+
52
+ <template>
53
+ <div class="rootSize">
54
+ <div :style="{ width: 1280, height: 720, left: 50, }">
55
+ <div
56
+ :style="{
57
+ top: 0,
58
+ width: 200,
59
+ height: 40,
60
+ fontSize: 25,
61
+ lineHeight: '40px',
62
+ color: '#fff753',
63
+ }"
64
+ >
65
+ 整页滑动
66
+ </div>
67
+ <div
68
+ :style="{
69
+ top: 50,
70
+ width: CONST_ITEM_WIDTH * 10 + 20,
71
+ height: CONST_ITEM_HEIGHT + 20,
72
+ backgroundColor: '#ff0000',
73
+ }"
74
+ >
75
+ <metro-widget
76
+ name="simpleWidgetHorizontal1"
77
+ :width="CONST_ITEM_WIDTH * 10 + 20"
78
+ :height="CONST_ITEM_HEIGHT + 20"
79
+ :direction="direction"
80
+ :measures="measures"
81
+ :provideData="_provideData"
82
+ :padding="{ top: 10, left: 10, right: 10, bottom: 10 }"
83
+ :enableTouch="true"
84
+ :flingPageWidth="CONST_ITEM_WIDTH * 10"
85
+ >
86
+ <template #renderItem="{ data, query, onEdge, onAction }">
87
+ <item
88
+ :data="data"
89
+ :query="query"
90
+ :onEdge="onEdge"
91
+ :onAction="onAction"
92
+ /> </template
93
+ ></metro-widget>
94
+ </div>
95
+ <div
96
+ :style="{
97
+ top: CONST_ITEM_HEIGHT + 100,
98
+ width: 200,
99
+ height: 40,
100
+ fontSize: 25,
101
+ lineHeight: '40px',
102
+ color: '#fff753',
103
+ }"
104
+ >
105
+ 普通滑动
106
+ </div>
107
+ <div
108
+ :style="{
109
+ top: CONST_ITEM_HEIGHT + 100 + 50,
110
+ width: CONST_ITEM_WIDTH * 10 + 20,
111
+ height: CONST_ITEM_HEIGHT + 20,
112
+ backgroundColor: '#ff0000',
113
+ }"
114
+ >
115
+ <metro-widget
116
+ name="simpleWidgetHorizontal2"
117
+ :width="CONST_ITEM_WIDTH * 10 + 20"
118
+ :height="CONST_ITEM_HEIGHT + 20"
119
+ :direction="direction"
120
+ :measures="measures"
121
+ :provideData="_provideData"
122
+ :padding="{ top: 10, left: 10, right: 10, bottom: 10 }"
123
+ :enableTouch="true"
124
+ >
125
+ <template #renderItem="{ data, query, onEdge, onAction }">
126
+ <item
127
+ :data="data"
128
+ :query="query"
129
+ :onEdge="onEdge"
130
+ :onAction="onAction"
131
+ /> </template
132
+ ></metro-widget>
133
+ </div>
134
+ </div>
135
+ </div>
136
+ </template>
137
+
138
+ <style scoped>
139
+ .rootSize {
140
+ width: 1920;
141
+ height: 1080;
142
+ background-color: #334c4c;
143
+ }
144
+ </style>
@@ -0,0 +1,144 @@
1
+ <script>
2
+ import {
3
+ VERTICAL,
4
+ MetroWidget,
5
+ WholePageSlide,
6
+ SeamlessSlide,
7
+ FixPositionSlide,
8
+ } from "jsview/utils/JsViewEngineWidget";
9
+
10
+ import Item from "./Item.vue";
11
+
12
+ import { metroWidgetV, measures } from "./data.js";
13
+ import { ref } from "vue";
14
+
15
+ export default {
16
+ components: {
17
+ MetroWidget,
18
+ Item,
19
+ },
20
+ setup() {
21
+ return {
22
+ measures,
23
+ name: "/metroWidgetH",
24
+ direction: VERTICAL,
25
+ wholePageSlide: new WholePageSlide({
26
+ speed: 1.5,
27
+ }),
28
+ seamlessSlide: new SeamlessSlide({
29
+ startPercent: 0.4,
30
+ endPercent: 0.6,
31
+ speed: 0.5,
32
+ }),
33
+ fixPositionSlide: new FixPositionSlide({
34
+ fixPercent: 0.5,
35
+ speed: 0.5,
36
+ }),
37
+ token: ref(0),
38
+ CONST_ITEM_WIDTH: 300,
39
+ CONST_ITEM_HEIGHT: 100,
40
+ };
41
+ },
42
+ methods: {
43
+ _provideData() {
44
+ return metroWidgetV;
45
+ },
46
+ },
47
+
48
+ mounted() {},
49
+ };
50
+ </script>
51
+
52
+ <template>
53
+ <div class="rootSize">
54
+ <div :style="{ width: 1280, height: 720, left: 50, overflow: 'hidden' }">
55
+ <div
56
+ :style="{
57
+ left: 0,
58
+ width: 200,
59
+ height: 40,
60
+ fontSize: 25,
61
+ lineHeight: '40px',
62
+ color: '#fff753',
63
+ }"
64
+ >
65
+ 整页滑动
66
+ </div>
67
+ <div
68
+ :style="{
69
+ left: 200,
70
+ width: CONST_ITEM_WIDTH + 20,
71
+ height: CONST_ITEM_HEIGHT * 5 + 20,
72
+ backgroundColor: '#ff0000',
73
+ }"
74
+ >
75
+ <metro-widget
76
+ name="simpleWidgetVertical1"
77
+ :width="CONST_ITEM_WIDTH + 20"
78
+ :height="CONST_ITEM_HEIGHT * 5 + 20"
79
+ :direction="direction"
80
+ :measures="measures"
81
+ :provideData="_provideData"
82
+ :padding="{ top: 10, left: 10, right: 10, bottom: 10 }"
83
+ :enableTouch="true"
84
+ :flingPageWidth="CONST_ITEM_HEIGHT * 5"
85
+ >
86
+ <template #renderItem="{ data, query, onEdge, onAction }">
87
+ <item
88
+ :data="data"
89
+ :query="query"
90
+ :onEdge="onEdge"
91
+ :onAction="onAction"
92
+ /> </template
93
+ ></metro-widget>
94
+ </div>
95
+ <div
96
+ :style="{
97
+ left: 600,
98
+ width: 200,
99
+ height: 40,
100
+ fontSize: 25,
101
+ lineHeight: '40px',
102
+ color: '#fff753',
103
+ }"
104
+ >
105
+ 普通滑动
106
+ </div>
107
+ <div
108
+ :style="{
109
+ left: 800,
110
+ width: CONST_ITEM_WIDTH + 20,
111
+ height: CONST_ITEM_HEIGHT * 5 + 20,
112
+ backgroundColor: '#ff0000',
113
+ }"
114
+ >
115
+ <metro-widget
116
+ name="simpleWidgetVertical2"
117
+ :width="CONST_ITEM_WIDTH + 20"
118
+ :height="CONST_ITEM_HEIGHT * 5 + 20"
119
+ :direction="direction"
120
+ :measures="measures"
121
+ :provideData="_provideData"
122
+ :padding="{ top: 10, left: 10, right: 10, bottom: 10 }"
123
+ :enableTouch="true"
124
+ >
125
+ <template #renderItem="{ data, query, onEdge, onAction }">
126
+ <item
127
+ :data="data"
128
+ :query="query"
129
+ :onEdge="onEdge"
130
+ :onAction="onAction"
131
+ /> </template
132
+ ></metro-widget>
133
+ </div>
134
+ </div>
135
+ </div>
136
+ </template>
137
+
138
+ <style scoped>
139
+ .rootSize {
140
+ width: 1920;
141
+ height: 1080;
142
+ background-color: #334c4c;
143
+ }
144
+ </style>
@@ -0,0 +1,159 @@
1
+ <!--
2
+ * @Author: ChenChanghua
3
+ * @Date: 2022-04-10 21:21:02
4
+ * @LastEditors: ChenChanghua
5
+ * @LastEditTime: 2022-04-11 10:05:35
6
+ * @Description: file content
7
+ -->
8
+ <script>
9
+ import JsvTouchContainer, {
10
+ DIRECTION_VERTICAL,
11
+ DIRECTION_HORIZONTAL,
12
+ DIRECTION_DISABLE,
13
+ } from "jsview/utils/JsViewVueWidget/JsvTouchContainer.vue";
14
+ import { touchContainerH, measures } from "./data.js";
15
+ function randomColor() {
16
+ let randomColor = Math.round(Math.random() * 2 ** 24).toString(16);
17
+ return (
18
+ "#" + new Array(6 - randomColor.length).fill("0").join("") + randomColor
19
+ );
20
+ }
21
+ export default {
22
+ components: {
23
+ JsvTouchContainer,
24
+ },
25
+ setup() {
26
+ return {
27
+ DIRECTION_VERTICAL,
28
+ DIRECTION_HORIZONTAL,
29
+ DIRECTION_DISABLE,
30
+ touchContainerH,
31
+ measures,
32
+ randomColor,
33
+ };
34
+ },
35
+ methods: {
36
+ _onClick(msg) {
37
+ console.log(`_onClick:${JSON.stringify(msg)}`);
38
+ return true;
39
+ },
40
+ },
41
+ };
42
+ </script>
43
+
44
+ <template>
45
+ <div :style="{ width: 1280, height: 720, overflow: 'hidden' }">
46
+ <jsv-touch-container
47
+ :style="{ width: 1280, height: 720 * 2, backgroundColor: '#7b7a1c' }"
48
+ :direction="DIRECTION_VERTICAL"
49
+ :dragLimitArea="{ x: 0, y: 0, width: 1280, height: 720 }"
50
+ >
51
+ <div
52
+ :style="{
53
+ left: 30,
54
+ top: 0,
55
+ width: 400,
56
+ height: 30,
57
+ fontSize: 18,
58
+ lineHeight: '30px',
59
+ color: '#f0ef29',
60
+ }"
61
+ >
62
+ 整屏幕滑动
63
+ </div>
64
+ <jsv-touch-container
65
+ :style="{
66
+ left: 0,
67
+ top: 40,
68
+ width: (1280 - 60) * 5,
69
+ height: 220,
70
+ backgroundColor: 'rgba(255,0,0,0.5)',
71
+ }"
72
+ :direction="DIRECTION_HORIZONTAL"
73
+ :flingPageWidth="1280 - 60"
74
+ :dragLimitArea="{ x: 0, y: 0, width: 1280 - 60, height: 220 }"
75
+ >
76
+ <div
77
+ v-for="(tabList, tabIndex) in touchContainerH"
78
+ :key="'tab' + tabIndex"
79
+ :style="{
80
+ left: (1280 - 60) * tabIndex,
81
+ top: 0,
82
+ width: 1280 - 60,
83
+ height: 220,
84
+ backgroundColor: randomColor(),
85
+ }"
86
+ >
87
+ <jsv-touch-container
88
+ v-for="(item, itemIndex) in tabList"
89
+ :key="'tab' + tabIndex + '-' + itemIndex"
90
+ :style="{
91
+ left: item.left,
92
+ top: item.top,
93
+ width: item.width,
94
+ height: item.height,
95
+ backgroundColor: item.backgroundColor,
96
+ fontSize: 18,
97
+ }"
98
+ :onClick="_onClick"
99
+ :direction="DIRECTION_DISABLE"
100
+ >{{ item.content }}</jsv-touch-container
101
+ >
102
+ </div>
103
+ </jsv-touch-container>
104
+
105
+ <div
106
+ :style="{
107
+ left: 30,
108
+ top: 280,
109
+ width: 400,
110
+ height: 40,
111
+ fontSize: 18,
112
+ lineHeight: '40px',
113
+ color: '#f0ef29',
114
+ }"
115
+ >
116
+ 左右滑动
117
+ </div>
118
+ <jsv-touch-container
119
+ :style="{
120
+ left: 0,
121
+ top: 320,
122
+ width: (1280 - 60) * 5,
123
+ height: 220,
124
+ backgroundColor: '#1d9797',
125
+ }"
126
+ :direction="DIRECTION_HORIZONTAL"
127
+ :dragLimitArea="{ x: 0, y: 0, width: 1280 - 60, height: 220 }"
128
+ >
129
+ <div
130
+ v-for="(tabList, tabIndex) in touchContainerH"
131
+ :key="'tab' + tabIndex"
132
+ :style="{
133
+ left: (1280 - 60) * tabIndex,
134
+ top: 0,
135
+ width: 1280 - 60,
136
+ height: 220,
137
+ backgroundColor: randomColor(),
138
+ }"
139
+ >
140
+ <jsv-touch-container
141
+ v-for="(item, itemIndex) in tabList"
142
+ :key="'tab' + tabIndex + '-' + itemIndex"
143
+ :style="{
144
+ left: item.left,
145
+ top: item.top,
146
+ width: item.width,
147
+ height: item.height,
148
+ backgroundColor: item.backgroundColor,
149
+ fontSize: 18,
150
+ }"
151
+ :onClick="_onClick"
152
+ :direction="DIRECTION_DISABLE"
153
+ >{{ item.content }}</jsv-touch-container
154
+ >
155
+ </div>
156
+ </jsv-touch-container>
157
+ </jsv-touch-container>
158
+ </div>
159
+ </template>