@shijiu/jsview-vue-samples 2.2.201 → 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.
Files changed (103) hide show
  1. package/BakeViewDemo/App.vue +6 -1
  2. package/Basic/components/anim/AnimEasingCubicBezier.vue +56 -0
  3. package/Basic/components/anim/AnimGroup2.vue +33 -0
  4. package/Basic/components/panel/Panel2.vue +8 -3
  5. package/Basic/components/text/TextDirection.vue +0 -1
  6. package/ColorSpace/App.vue +2 -2
  7. package/CoupletsTest/widget/Banger/Maroon.vue +0 -1
  8. package/CoupletsTest/widget/Fireworks/Fireworks.vue +0 -2
  9. package/CssPreprocessor/Stylus/components/stylus-group1/StylusOperations.vue +0 -1
  10. package/CssPreprocessor/utils/ContentBlock.vue +3 -3
  11. package/CssPreprocessor/utils/{FontStyle.css → FontConfig.css} +3 -3
  12. package/CssPreprocessor/utils/TitleBar.vue +2 -2
  13. package/CustomShader/App.vue +32 -15
  14. package/CustomShader/pageFlip.glsl +3 -2
  15. package/DemoHomepage/App.vue +14 -5
  16. package/DemoHomepage/components/Item.vue +23 -12
  17. package/DemoHomepage/index.d.ts +5 -2
  18. package/DemoHomepage/router.js +97 -74
  19. package/DemoHomepage/views/Homepage.vue +0 -4
  20. package/DispersedFocusControl/App.vue +67 -0
  21. package/DispersedFocusControl/Button.vue +76 -0
  22. package/DispersedFocusControl/data.js +44 -0
  23. package/DivMetroPerformance/components/ContentItem.vue +0 -1
  24. package/DragBox/App.vue +148 -0
  25. package/FlexCellDemo/App.vue +47 -223
  26. package/FlexCellDemo/TestFrame1.vue +84 -0
  27. package/FlexCellDemo/TestFrame2.vue +100 -0
  28. package/FlexCellDemo/TestFrame3.vue +97 -0
  29. package/FlexCellDemo/TestFrame4.vue +60 -0
  30. package/FlexCellDemo/TestFrame5.vue +60 -0
  31. package/FlexCellDemo/images/6.jpg +0 -0
  32. package/FocusMoveStyle/App.vue +1 -0
  33. package/FocusMoveStyle/CreepFocus.vue +11 -1
  34. package/FocusMoveStyle/FoldableItem.vue +1 -1
  35. package/FullScreenFlex/App.vue +42 -0
  36. package/FullScreenFlex/TestFrame2.vue +107 -0
  37. package/FullScreenFlex/images/1.png +0 -0
  38. package/GiftRain/App.vue +0 -3
  39. package/HashHistory/App.vue +8 -4
  40. package/HashParams/App.vue +0 -1
  41. package/Input/App.vue +184 -97
  42. package/Input/InputPanel.vue +98 -82
  43. package/JsvPreDownloader/App.vue +0 -2
  44. package/LatexFormula/App.vue +97 -10
  45. package/Marquee/App.vue +2 -2
  46. package/MetroWidgetDemos/MassiveItems/ContentItem.vue +0 -1
  47. package/MetroWidgetDemos/PerformanceTest/components/ContentItem.vue +0 -1
  48. package/MetroWidgetDemos/PerformanceTest/components/MyTab.vue +18 -17
  49. package/MetroWidgetDemos/itemSizeUpdate/backward/Item.vue +1 -1
  50. package/MetroWidgetDemos/routeList.js +17 -17
  51. package/MindMap/App.vue +10 -1
  52. package/MindMap/data.js +34 -8
  53. package/Parkour/appConfig/jsview.config.mjs +0 -4
  54. package/PosterPacker/App.vue +207 -0
  55. package/PosterPacker/images/bg.jpg +0 -0
  56. package/PosterPacker/images/blue.png +0 -0
  57. package/PosterPacker/images/darkGreen.png +0 -0
  58. package/PosterPacker/images/left.png +0 -0
  59. package/PosterPacker/images/orange.png +0 -0
  60. package/PosterPacker/images/pink.png +0 -0
  61. package/PosterPacker/images/purple.png +0 -0
  62. package/PosterPacker/images/red.png +0 -0
  63. package/PosterPacker/images/right.png +0 -0
  64. package/PosterPacker/images/yellowGreen.png +0 -0
  65. package/PosterPacker/tools/geniePakcer/Genie.vue +686 -0
  66. package/PosterPacker/tools/geniePakcer/genieBottom.glsl +49 -0
  67. package/PosterPacker/tools/geniePakcer/genieLeft.glsl +50 -0
  68. package/PosterPacker/tools/geniePakcer/genieRight.glsl +57 -0
  69. package/PosterPacker/tools/geniePakcer/genieTop.glsl +50 -0
  70. package/PosterPacker/tools/particlePacker/Particle.vue +71 -0
  71. package/PosterPacker/tools/vortexPacker/Vortex.vue +135 -0
  72. package/PosterPacker/tools/vortexPacker/vortex.glsl +37 -0
  73. package/Preload/App.vue +1 -1
  74. package/ScaleDownNeon/App.vue +13 -10
  75. package/SceneTransition/App.vue +5 -4
  76. package/ScrollBoxTest/ClipBar.vue +1 -0
  77. package/ScrollBoxTest/NinePatchBar.vue +1 -0
  78. package/ScrollBoxTest/SizeDivBar.vue +1 -0
  79. package/SprayMove/App.vue +75 -0
  80. package/SprayMove/SprayMove.vue +173 -0
  81. package/SprayView/App.vue +8 -9
  82. package/TestNativeSharedView/App.vue +6 -4
  83. package/TextShadowDemo/App.vue +3 -3
  84. package/TextureAnimation/App.vue +237 -151
  85. package/TextureAnimation/App2.vue +66 -14
  86. package/TextureAnimation/assets/blackWhiteTurntable.png +0 -0
  87. package/TextureAnimation/assets/circleHaloMask.png +0 -0
  88. package/TextureSize/App.vue +5 -6
  89. package/TouchWidget/App.vue +79 -40
  90. package/TouchWidget/Item.vue +15 -3
  91. package/ViewOpacity/App.vue +4 -5
  92. package/index.d.ts +1 -1
  93. package/package.json +1 -1
  94. package/TextureAnimation/assets/mask.png +0 -0
  95. package/TextureAnimation/assets/php.jpg +0 -0
  96. package/TouchSample/App.vue +0 -136
  97. package/TouchSample/Item.vue +0 -102
  98. package/TouchSample/MetroWidgetHorizontal.vue +0 -144
  99. package/TouchSample/MetroWidgetVertical.vue +0 -144
  100. package/TouchSample/TouchContainerHorizontal.vue +0 -160
  101. package/TouchSample/TouchContainerVertical.vue +0 -160
  102. package/TouchSample/data.js +0 -81
  103. /package/TextureAnimation/assets/{php2.png → borderOpacity.png} +0 -0
@@ -1,144 +0,0 @@
1
- <script>
2
- import {
3
- VERTICAL,
4
- MetroWidget,
5
- WholePageSlide,
6
- SeamlessSlide,
7
- FixPositionSlide,
8
- } from "jsview";
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: 40,
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: 40,
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>
@@ -1,160 +0,0 @@
1
- <!--
2
- * @Author: ChenChanghua
3
- * @Date: 2022-04-10 21:21:02
4
- * @LastEditors: ChenChanghua
5
- * @LastEditTime: 2022-07-08 14:40:19
6
- * @Description: file content
7
- -->
8
- <script>
9
- import {
10
- JsvTouchContainer,
11
- DIRECTION_VERTICAL,
12
- DIRECTION_HORIZONTAL,
13
- DIRECTION_DISABLE,
14
- } from "jsview";
15
- import { touchContainerH, measures } from "./data.js";
16
- function randomColor() {
17
- let randomColor = Math.round(Math.random() * 2 ** 24).toString(16);
18
- return (
19
- "#" + new Array(6 - randomColor.length).fill("0").join("") + randomColor
20
- );
21
- }
22
- export default {
23
- components: {
24
- JsvTouchContainer,
25
- },
26
- setup() {
27
- return {
28
- DIRECTION_VERTICAL,
29
- DIRECTION_HORIZONTAL,
30
- DIRECTION_DISABLE,
31
- touchContainerH,
32
- measures,
33
- randomColor,
34
- };
35
- },
36
- methods: {
37
- _onClick(msg) {
38
- console.log(`_onClick:${JSON.stringify(msg)}`);
39
- return true;
40
- },
41
- },
42
- };
43
- </script>
44
-
45
- <template>
46
- <div :style="{ width: 1280, height: 720, overflow: 'hidden' }">
47
- <jsv-touch-container
48
- :style="{ width: 1280, height: 720 * 2, backgroundColor: '#7b7a1c' }"
49
- :direction="DIRECTION_VERTICAL"
50
- :dragLimitArea="{ x: 0, y: 0, width: 1280, height: 720 }"
51
- >
52
- <div
53
- :style="{
54
- left: 30,
55
- top: 0,
56
- width: 400,
57
- height: 30,
58
- fontSize: 18,
59
- lineHeight: 30,
60
- color: '#f0ef29',
61
- }"
62
- >
63
- 整屏幕滑动
64
- </div>
65
- <jsv-touch-container
66
- :style="{
67
- left: 0,
68
- top: 40,
69
- width: (1280 - 60) * 5,
70
- height: 220,
71
- backgroundColor: 'rgba(255,0,0,0.5)',
72
- }"
73
- :direction="DIRECTION_HORIZONTAL"
74
- :flingPageWidth="1280 - 60"
75
- :dragLimitArea="{ x: 0, y: 0, width: 1280 - 60, height: 220 }"
76
- >
77
- <div
78
- v-for="(tabList, tabIndex) in touchContainerH"
79
- :key="'tab' + tabIndex"
80
- :style="{
81
- left: (1280 - 60) * tabIndex,
82
- top: 0,
83
- width: 1280 - 60,
84
- height: 220,
85
- backgroundColor: randomColor(),
86
- }"
87
- >
88
- <jsv-touch-container
89
- v-for="(item, itemIndex) in tabList"
90
- :key="'tab' + tabIndex + '-' + itemIndex"
91
- :style="{
92
- left: item.left,
93
- top: item.top,
94
- width: item.width,
95
- height: item.height,
96
- backgroundColor: item.backgroundColor,
97
- fontSize: 18,
98
- }"
99
- :onClick="_onClick"
100
- :direction="DIRECTION_DISABLE"
101
- >{{ item.content }}</jsv-touch-container
102
- >
103
- </div>
104
- </jsv-touch-container>
105
-
106
- <div
107
- :style="{
108
- left: 30,
109
- top: 280,
110
- width: 400,
111
- height: 40,
112
- fontSize: 18,
113
- lineHeight: 40,
114
- color: '#f0ef29',
115
- }"
116
- >
117
- 左右滑动
118
- </div>
119
- <jsv-touch-container
120
- :style="{
121
- left: 0,
122
- top: 320,
123
- width: (1280 - 60) * 5,
124
- height: 220,
125
- backgroundColor: '#1d9797',
126
- }"
127
- :direction="DIRECTION_HORIZONTAL"
128
- :dragLimitArea="{ x: 0, y: 0, width: 1280 - 60, height: 220 }"
129
- >
130
- <div
131
- v-for="(tabList, tabIndex) in touchContainerH"
132
- :key="'tab' + tabIndex"
133
- :style="{
134
- left: (1280 - 60) * tabIndex,
135
- top: 0,
136
- width: 1280 - 60,
137
- height: 220,
138
- backgroundColor: randomColor(),
139
- }"
140
- >
141
- <jsv-touch-container
142
- v-for="(item, itemIndex) in tabList"
143
- :key="'tab' + tabIndex + '-' + itemIndex"
144
- :style="{
145
- left: item.left,
146
- top: item.top,
147
- width: item.width,
148
- height: item.height,
149
- backgroundColor: item.backgroundColor,
150
- fontSize: 18,
151
- }"
152
- :onClick="_onClick"
153
- :direction="DIRECTION_DISABLE"
154
- >{{ item.content }}</jsv-touch-container
155
- >
156
- </div>
157
- </jsv-touch-container>
158
- </jsv-touch-container>
159
- </div>
160
- </template>
@@ -1,160 +0,0 @@
1
- <!--
2
- * @Author: ChenChanghua
3
- * @Date: 2022-04-10 21:21:02
4
- * @LastEditors: ChenChanghua
5
- * @LastEditTime: 2022-04-11 09:04:26
6
- * @Description: file content
7
- -->
8
- <script>
9
- import {
10
- JsvTouchContainer,
11
- DIRECTION_VERTICAL,
12
- DIRECTION_HORIZONTAL,
13
- DIRECTION_DISABLE,
14
- } from "jsview";
15
- import { touchContainerV, measures } from "./data.js";
16
- function randomColor() {
17
- let randomColor = Math.round(Math.random() * 2 ** 24).toString(16);
18
- return (
19
- "#" + new Array(6 - randomColor.length).fill("0").join("") + randomColor
20
- );
21
- }
22
- export default {
23
- components: {
24
- JsvTouchContainer,
25
- },
26
- setup() {
27
- return {
28
- DIRECTION_VERTICAL,
29
- DIRECTION_HORIZONTAL,
30
- DIRECTION_DISABLE,
31
- touchContainerV,
32
- measures,
33
- randomColor,
34
- };
35
- },
36
- methods: {
37
- _onClick(msg) {
38
- console.log(`_onClick:${JSON.stringify(msg)}`);
39
- return true;
40
- },
41
- },
42
- };
43
- </script>
44
-
45
- <template>
46
- <div :style="{ width: 1280, height: 720, overflow: 'hidden' }">
47
- <jsv-touch-container
48
- :style="{ width: 1280, height: 720 * 2, backgroundColor: '#7b7a1c' }"
49
- :direction="DIRECTION_HORIZONTAL"
50
- :dragLimitArea="{ x: 0, y: 0, width: 1280, height: 720 }"
51
- >
52
- <div
53
- :style="{
54
- left: 30,
55
- top: 0,
56
- width: 400,
57
- height: 40,
58
- fontSize: 25,
59
- lineHeight: 40,
60
- color: '#f0ef29',
61
- }"
62
- >
63
- 整屏幕滑动
64
- </div>
65
- <jsv-touch-container
66
- :style="{
67
- left: 30,
68
- top: 50,
69
- width: 400,
70
- height: 500 * 5,
71
- backgroundColor: '#810000',
72
- }"
73
- :direction="DIRECTION_VERTICAL"
74
- :flingPageWidth="500"
75
- :dragLimitArea="{ x: 0, y: 0, width: 400, height: 500 }"
76
- >
77
- <div
78
- v-for="(tabList, tabIndex) in touchContainerV"
79
- :key="'tab' + tabIndex"
80
- :style="{
81
- left: 0,
82
- top: 500 * tabIndex,
83
- width: 400,
84
- height: 500,
85
- backgroundColor: randomColor(),
86
- }"
87
- >
88
- <jsv-touch-container
89
- v-for="(item, itemIndex) in tabList"
90
- :key="'tab' + tabIndex + '-' + itemIndex"
91
- :style="{
92
- left: item.left,
93
- top: item.top,
94
- width: item.width,
95
- height: item.height,
96
- backgroundColor: item.backgroundColor,
97
- fontSize: 18,
98
- }"
99
- :onClick="_onClick"
100
- :direction="DIRECTION_DISABLE"
101
- >{{ item.content }}</jsv-touch-container
102
- >
103
- </div>
104
- </jsv-touch-container>
105
-
106
- <div
107
- :style="{
108
- left: 530,
109
- top: 0,
110
- width: 400,
111
- height: 40,
112
- fontSize: 25,
113
- lineHeight: 40,
114
- color: '#f0ef29',
115
- }"
116
- >
117
- 上下滑动
118
- </div>
119
- <jsv-touch-container
120
- :style="{
121
- left: 530,
122
- top: 50,
123
- width: 400,
124
- height: 500 * 5,
125
- backgroundColor: '#810000',
126
- }"
127
- :direction="DIRECTION_VERTICAL"
128
- :dragLimitArea="{ x: 0, y: 0, width: 400, height: 500 }"
129
- >
130
- <div
131
- v-for="(tabList, tabIndex) in touchContainerV"
132
- :key="'tab' + tabIndex"
133
- :style="{
134
- left: 0,
135
- top: 500 * tabIndex,
136
- width: 400,
137
- height: 500,
138
- backgroundColor: randomColor(),
139
- }"
140
- >
141
- <jsv-touch-container
142
- v-for="(item, itemIndex) in tabList"
143
- :key="'tab' + tabIndex + '-' + itemIndex"
144
- :style="{
145
- left: item.left,
146
- top: item.top,
147
- width: item.width,
148
- height: item.height,
149
- backgroundColor: item.backgroundColor,
150
- fontSize: 18,
151
- }"
152
- :onClick="_onClick"
153
- :direction="DIRECTION_DISABLE"
154
- >{{ item.content }}</jsv-touch-container
155
- >
156
- </div>
157
- </jsv-touch-container>
158
- </jsv-touch-container>
159
- </div>
160
- </template>
@@ -1,81 +0,0 @@
1
- /*
2
- * @Author: ChenChanghua
3
- * @Date: 2022-04-10 21:23:15
4
- * @LastEditors: ChenChanghua
5
- * @LastEditTime: 2022-04-11 10:03:21
6
- * @Description: file content
7
- */
8
- function randomColor() {
9
- let randomColor = Math.round(Math.random() * 2 ** 24).toString(16);
10
- return (
11
- "#" + new Array(6 - randomColor.length).fill("0").join("") + randomColor
12
- );
13
- }
14
-
15
- const metroWidgetH = [];
16
- for (let i = 0; i < 500; i++) {
17
- metroWidgetH.push({
18
- content: i,
19
- id: i,
20
- width: 100,
21
- height: 200,
22
- color: randomColor(),
23
- });
24
- }
25
-
26
- const metroWidgetV = [];
27
- for (let i = 0; i < 500; i++) {
28
- metroWidgetV.push({
29
- content: i,
30
- id: i,
31
- width: 200,
32
- height: 100,
33
- color: randomColor(),
34
- });
35
- }
36
-
37
- const touchContainerH = [];
38
- for (let i = 0; i < 5; i++) {
39
- const tabData = [];
40
- for (let i = 0; i < 20; i++) {
41
- tabData.push({
42
- content: i,
43
- id: i,
44
- left: (122 / 2) * i,
45
- top: 10,
46
- width: 122 / 2 - 10,
47
- height: 200,
48
- backgroundColor: randomColor(),
49
- });
50
- }
51
- touchContainerH.push(tabData);
52
- }
53
-
54
- const touchContainerV = [];
55
- for (let i = 0; i < 5; i++) {
56
- const tabData = [];
57
- for (let i = 0; i < 20; i++) {
58
- tabData.push({
59
- content: i,
60
- id: i,
61
- left: 10,
62
- top: 50 * i,
63
- width: 300,
64
- height: 40,
65
- backgroundColor: randomColor(),
66
- });
67
- }
68
- touchContainerV.push(tabData);
69
- }
70
-
71
- function measures(item) {
72
- return item;
73
- }
74
-
75
- export {
76
- metroWidgetH,
77
- metroWidgetV,
78
- touchContainerH,
79
- touchContainerV,
80
- measures,
81
- };