xiaoe_mp_npm 1.0.21 → 1.0.22-store1

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 (162) hide show
  1. package/.prettierrc.js +32 -6
  2. package/miniprogram_dist/Task/TaskBubble/index.js +2 -1
  3. package/miniprogram_dist/Task/TaskBubble/index.json +3 -3
  4. package/miniprogram_dist/Task/TaskBubble/index.scss +125 -125
  5. package/miniprogram_dist/Task/TaskBubble/index.wxml +22 -22
  6. package/miniprogram_dist/Task/TaskIcon/index.js +29 -29
  7. package/miniprogram_dist/Task/TaskIcon/index.json +4 -4
  8. package/miniprogram_dist/Task/TaskIcon/index.scss +70 -70
  9. package/miniprogram_dist/Task/TaskIcon/index.wxml +5 -5
  10. package/miniprogram_dist/Task/TaskPopup/component/RewardList/index.js +39 -39
  11. package/miniprogram_dist/Task/TaskPopup/component/RewardList/index.json +6 -6
  12. package/miniprogram_dist/Task/TaskPopup/component/RewardList/index.scss +39 -39
  13. package/miniprogram_dist/Task/TaskPopup/component/RewardList/index.wxml +19 -19
  14. package/miniprogram_dist/Task/TaskPopup/component/TaskItem/index.js +266 -168
  15. package/miniprogram_dist/Task/TaskPopup/component/TaskItem/index.json +5 -5
  16. package/miniprogram_dist/Task/TaskPopup/component/TaskItem/index.scss +26 -0
  17. package/miniprogram_dist/Task/TaskPopup/component/TaskItem/index.wxml +32 -13
  18. package/miniprogram_dist/Task/TaskPopup/component/TaskItem/index.wxs +7 -7
  19. package/miniprogram_dist/Task/TaskPopup/component/TaskItem/index.wxss +96 -0
  20. package/miniprogram_dist/Task/TaskPopup/component/TaskList/index.js +8 -0
  21. package/miniprogram_dist/Task/TaskPopup/component/TaskList/index.json +7 -7
  22. package/miniprogram_dist/Task/TaskPopup/component/TaskList/index.scss +66 -66
  23. package/miniprogram_dist/Task/TaskPopup/component/TaskList/index.wxml +1 -0
  24. package/miniprogram_dist/Task/TaskPopup/component/TaskType/index.js +4 -0
  25. package/miniprogram_dist/Task/TaskPopup/component/TaskType/index.json +9 -9
  26. package/miniprogram_dist/Task/TaskPopup/component/TaskType/index.scss +62 -62
  27. package/miniprogram_dist/Task/TaskPopup/component/TaskType/index.wxml +1 -0
  28. package/miniprogram_dist/Task/TaskPopup/index.js +76 -70
  29. package/miniprogram_dist/Task/TaskPopup/index.json +2 -2
  30. package/miniprogram_dist/Task/TaskPopup/index.scss +140 -140
  31. package/miniprogram_dist/Task/TaskPopup/index.wxml +1 -0
  32. package/miniprogram_dist/Task/TaskQuizPopup/components/quizContent/index.js +132 -0
  33. package/miniprogram_dist/Task/TaskQuizPopup/components/quizContent/index.json +6 -0
  34. package/miniprogram_dist/Task/TaskQuizPopup/components/quizContent/index.scss +192 -0
  35. package/miniprogram_dist/Task/TaskQuizPopup/components/quizContent/index.wxml +65 -0
  36. package/miniprogram_dist/Task/TaskQuizPopup/components/quizContent/index.wxs +79 -0
  37. package/miniprogram_dist/Task/TaskQuizPopup/components/quizContent/index.wxss +521 -0
  38. package/miniprogram_dist/Task/TaskQuizPopup/components/quizRichText/index.js +40 -0
  39. package/miniprogram_dist/Task/TaskQuizPopup/components/quizRichText/index.json +6 -0
  40. package/miniprogram_dist/Task/TaskQuizPopup/components/quizRichText/index.scss +7 -0
  41. package/miniprogram_dist/Task/TaskQuizPopup/components/quizRichText/index.wxml +2 -0
  42. package/miniprogram_dist/Task/TaskQuizPopup/components/quizRichText/index.wxss +298 -0
  43. package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/base.wxml +50 -0
  44. package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/html2json.js +623 -0
  45. package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/htmlparser.js +183 -0
  46. package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/iframeParse.js +216 -0
  47. package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/loop.wxml +3563 -0
  48. package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/showdown.js +2364 -0
  49. package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/wxDiscode.js +209 -0
  50. package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/wxParse.js +269 -0
  51. package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/wxParse.wxml +1276 -0
  52. package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/wxParse.wxss +316 -0
  53. package/miniprogram_dist/Task/TaskQuizPopup/index.js +225 -0
  54. package/miniprogram_dist/Task/TaskQuizPopup/index.json +8 -0
  55. package/miniprogram_dist/Task/TaskQuizPopup/index.scss +159 -0
  56. package/miniprogram_dist/Task/TaskQuizPopup/index.wxml +97 -0
  57. package/miniprogram_dist/Task/TaskQuizPopup/index.wxss +478 -0
  58. package/miniprogram_dist/Task/taskQuizRemindPopup/index.js +74 -0
  59. package/miniprogram_dist/Task/taskQuizRemindPopup/index.json +6 -0
  60. package/miniprogram_dist/Task/taskQuizRemindPopup/index.scss +108 -0
  61. package/miniprogram_dist/Task/taskQuizRemindPopup/index.wxml +27 -0
  62. package/miniprogram_dist/Task/taskQuizRemindPopup/index.wxss +286 -0
  63. package/miniprogram_dist/Task/taskReceivePopup/coupon/index.json +6 -6
  64. package/miniprogram_dist/Task/taskReceivePopup/coupon/index.wxs +48 -48
  65. package/miniprogram_dist/Task/taskReceivePopup/customPrizes/index.js +44 -44
  66. package/miniprogram_dist/Task/taskReceivePopup/customPrizes/index.json +6 -6
  67. package/miniprogram_dist/Task/taskReceivePopup/customPrizes/index.scss +106 -106
  68. package/miniprogram_dist/Task/taskReceivePopup/customPrizes/index.wxml +38 -38
  69. package/miniprogram_dist/Task/taskReceivePopup/customPrizes/index.wxs +48 -48
  70. package/miniprogram_dist/Task/taskReceivePopup/index.js +34 -34
  71. package/miniprogram_dist/Task/taskReceivePopup/index.json +13 -13
  72. package/miniprogram_dist/Task/taskReceivePopup/index.wxml +25 -25
  73. package/miniprogram_dist/Task/taskReceivePopup/integral/index.js +61 -61
  74. package/miniprogram_dist/Task/taskReceivePopup/integral/index.json +6 -6
  75. package/miniprogram_dist/Task/taskReceivePopup/integral/index.scss +60 -60
  76. package/miniprogram_dist/Task/taskReceivePopup/integral/index.wxml +12 -12
  77. package/miniprogram_dist/common/utils/tool.js +54 -48
  78. package/package.json +1 -1
  79. package/src/CustomPopup/index.wxss +22 -22
  80. package/src/Task/TaskBubble/index.js +2 -1
  81. package/src/Task/TaskBubble/index.json +3 -3
  82. package/src/Task/TaskBubble/index.scss +125 -125
  83. package/src/Task/TaskBubble/index.wxml +22 -22
  84. package/src/Task/TaskBubble/index.wxss +289 -289
  85. package/src/Task/TaskIcon/index.js +29 -29
  86. package/src/Task/TaskIcon/index.json +4 -4
  87. package/src/Task/TaskIcon/index.scss +70 -70
  88. package/src/Task/TaskIcon/index.wxml +5 -5
  89. package/src/Task/TaskIcon/index.wxss +130 -130
  90. package/src/Task/TaskPopup/component/RewardList/index.js +39 -39
  91. package/src/Task/TaskPopup/component/RewardList/index.json +6 -6
  92. package/src/Task/TaskPopup/component/RewardList/index.scss +39 -39
  93. package/src/Task/TaskPopup/component/RewardList/index.wxml +19 -19
  94. package/src/Task/TaskPopup/component/RewardList/index.wxss +18 -18
  95. package/src/Task/TaskPopup/component/TaskItem/index.js +266 -168
  96. package/src/Task/TaskPopup/component/TaskItem/index.json +5 -5
  97. package/src/Task/TaskPopup/component/TaskItem/index.scss +26 -0
  98. package/src/Task/TaskPopup/component/TaskItem/index.wxml +32 -13
  99. package/src/Task/TaskPopup/component/TaskItem/index.wxs +7 -7
  100. package/src/Task/TaskPopup/component/TaskItem/index.wxss +1 -394
  101. package/src/Task/TaskPopup/component/TaskList/index.js +8 -0
  102. package/src/Task/TaskPopup/component/TaskList/index.json +7 -7
  103. package/src/Task/TaskPopup/component/TaskList/index.scss +66 -66
  104. package/src/Task/TaskPopup/component/TaskList/index.wxml +1 -0
  105. package/src/Task/TaskPopup/component/TaskList/index.wxss +118 -118
  106. package/src/Task/TaskPopup/component/TaskType/index.js +4 -0
  107. package/src/Task/TaskPopup/component/TaskType/index.json +9 -9
  108. package/src/Task/TaskPopup/component/TaskType/index.scss +62 -62
  109. package/src/Task/TaskPopup/component/TaskType/index.wxml +1 -0
  110. package/src/Task/TaskPopup/component/TaskType/index.wxss +110 -110
  111. package/src/Task/TaskPopup/index.js +76 -70
  112. package/src/Task/TaskPopup/index.json +2 -2
  113. package/src/Task/TaskPopup/index.scss +140 -140
  114. package/src/Task/TaskPopup/index.wxml +1 -0
  115. package/src/Task/TaskQuizPopup/components/quizContent/index.js +132 -0
  116. package/src/Task/TaskQuizPopup/components/quizContent/index.json +6 -0
  117. package/src/Task/TaskQuizPopup/components/quizContent/index.scss +192 -0
  118. package/src/Task/TaskQuizPopup/components/quizContent/index.wxml +65 -0
  119. package/src/Task/TaskQuizPopup/components/quizContent/index.wxs +79 -0
  120. package/src/Task/TaskQuizPopup/components/quizContent/index.wxss +1 -0
  121. package/src/Task/TaskQuizPopup/components/quizRichText/index.js +40 -0
  122. package/src/Task/TaskQuizPopup/components/quizRichText/index.json +6 -0
  123. package/src/Task/TaskQuizPopup/components/quizRichText/index.scss +7 -0
  124. package/src/Task/TaskQuizPopup/components/quizRichText/index.wxml +2 -0
  125. package/src/Task/TaskQuizPopup/components/quizRichText/index.wxss +1 -0
  126. package/src/Task/TaskQuizPopup/components/wxParse/base.wxml +50 -0
  127. package/src/Task/TaskQuizPopup/components/wxParse/html2json.js +623 -0
  128. package/src/Task/TaskQuizPopup/components/wxParse/htmlparser.js +183 -0
  129. package/src/Task/TaskQuizPopup/components/wxParse/iframeParse.js +216 -0
  130. package/src/Task/TaskQuizPopup/components/wxParse/loop.wxml +3563 -0
  131. package/src/Task/TaskQuizPopup/components/wxParse/showdown.js +2364 -0
  132. package/src/Task/TaskQuizPopup/components/wxParse/wxDiscode.js +209 -0
  133. package/src/Task/TaskQuizPopup/components/wxParse/wxParse.js +269 -0
  134. package/src/Task/TaskQuizPopup/components/wxParse/wxParse.wxml +1276 -0
  135. package/src/Task/TaskQuizPopup/components/wxParse/wxParse.wxss +283 -0
  136. package/src/Task/TaskQuizPopup/index.js +225 -0
  137. package/src/Task/TaskQuizPopup/index.json +8 -0
  138. package/src/Task/TaskQuizPopup/index.scss +159 -0
  139. package/src/Task/TaskQuizPopup/index.wxml +97 -0
  140. package/src/Task/TaskQuizPopup/index.wxss +1 -0
  141. package/src/Task/taskQuizRemindPopup/index.js +74 -0
  142. package/src/Task/taskQuizRemindPopup/index.json +6 -0
  143. package/src/Task/taskQuizRemindPopup/index.scss +108 -0
  144. package/src/Task/taskQuizRemindPopup/index.wxml +27 -0
  145. package/src/Task/taskQuizRemindPopup/index.wxss +1 -0
  146. package/src/Task/taskReceivePopup/coupon/index.json +6 -6
  147. package/src/Task/taskReceivePopup/coupon/index.wxs +48 -48
  148. package/src/Task/taskReceivePopup/customPrizes/index.js +44 -44
  149. package/src/Task/taskReceivePopup/customPrizes/index.json +6 -6
  150. package/src/Task/taskReceivePopup/customPrizes/index.scss +106 -106
  151. package/src/Task/taskReceivePopup/customPrizes/index.wxml +38 -38
  152. package/src/Task/taskReceivePopup/customPrizes/index.wxs +48 -48
  153. package/src/Task/taskReceivePopup/index.js +34 -34
  154. package/src/Task/taskReceivePopup/index.json +13 -13
  155. package/src/Task/taskReceivePopup/index.wxml +25 -25
  156. package/src/Task/taskReceivePopup/index.wxss +1 -1
  157. package/src/Task/taskReceivePopup/integral/index.js +61 -61
  158. package/src/Task/taskReceivePopup/integral/index.json +6 -6
  159. package/src/Task/taskReceivePopup/integral/index.scss +60 -60
  160. package/src/Task/taskReceivePopup/integral/index.wxml +12 -12
  161. package/src/Task/taskReceivePopup/integral/index.wxss +94 -94
  162. package/src/common/utils/tool.js +54 -48
@@ -1,60 +1,60 @@
1
- @function vmin($rpx) {
2
- @return #{$rpx * 100 / $deviceWidth}vmin;
3
- }
4
-
5
- $deviceWidth: 750;
6
-
7
- @mixin integral-receive-popup {
8
- .receive-container {
9
- width: vmin(400);
10
- height: vmin(400);
11
- background-size: 100% 100%;
12
- background-image: url('https://commonresource-1252524126.cdn.xiaoeknow.com/image/loqj5js008xu.png');
13
- overflow: hidden;
14
- &__content-number {
15
- margin-top: vmin(336);
16
- font-weight: 500;
17
- text-align: center;
18
- color: #FFF5CC;
19
- font-size: vmin(48);
20
- line-height: vmin(48);
21
- }
22
- &__btn {
23
- width: vmin(296);
24
- height: vmin(80);
25
- text-align: center;
26
- line-height: vmin(80);
27
- border-radius: vmin(40);
28
- font-size: vmin(32);
29
- font-weight: 500;
30
- color: #fff;
31
- background: linear-gradient(270deg, #FF5820 0%, #FF4067 100%);
32
- margin: vmin(48) auto 0;
33
- }
34
- }
35
- &.integral-receive-popup-full .receive-container{
36
- transform: scale(0.8)
37
- }
38
- }
39
-
40
- .integral-receive-popup {
41
- @include integral-receive-popup;
42
- }
43
-
44
- // 竖屏pad
45
- @media screen and (min-width: 768px) and (orientation: portrait) {
46
- $deviceWidth: 1536 !global;
47
-
48
- .integral-receive-popup {
49
- @include integral-receive-popup;
50
- }
51
- }
52
-
53
- // 横屏pad
54
- @media screen and (min-height: 768px) and (orientation: landscape) {
55
- $deviceWidth: 1536 !global;
56
-
57
- .integral-receive-popup {
58
- @include integral-receive-popup;
59
- }
60
- }
1
+ @function vmin($rpx) {
2
+ @return #{$rpx * 100 / $deviceWidth}vmin;
3
+ }
4
+
5
+ $deviceWidth: 750;
6
+
7
+ @mixin integral-receive-popup {
8
+ .receive-container {
9
+ width: vmin(400);
10
+ height: vmin(400);
11
+ background-size: 100% 100%;
12
+ background-image: url('https://commonresource-1252524126.cdn.xiaoeknow.com/image/loqj5js008xu.png');
13
+ overflow: hidden;
14
+ &__content-number {
15
+ margin-top: vmin(336);
16
+ font-weight: 500;
17
+ text-align: center;
18
+ color: #FFF5CC;
19
+ font-size: vmin(48);
20
+ line-height: vmin(48);
21
+ }
22
+ &__btn {
23
+ width: vmin(296);
24
+ height: vmin(80);
25
+ text-align: center;
26
+ line-height: vmin(80);
27
+ border-radius: vmin(40);
28
+ font-size: vmin(32);
29
+ font-weight: 500;
30
+ color: #fff;
31
+ background: linear-gradient(270deg, #FF5820 0%, #FF4067 100%);
32
+ margin: vmin(48) auto 0;
33
+ }
34
+ }
35
+ &.integral-receive-popup-full .receive-container{
36
+ transform: scale(0.8)
37
+ }
38
+ }
39
+
40
+ .integral-receive-popup {
41
+ @include integral-receive-popup;
42
+ }
43
+
44
+ // 竖屏pad
45
+ @media screen and (min-width: 768px) and (orientation: portrait) {
46
+ $deviceWidth: 1536 !global;
47
+
48
+ .integral-receive-popup {
49
+ @include integral-receive-popup;
50
+ }
51
+ }
52
+
53
+ // 横屏pad
54
+ @media screen and (min-height: 768px) and (orientation: landscape) {
55
+ $deviceWidth: 1536 !global;
56
+
57
+ .integral-receive-popup {
58
+ @include integral-receive-popup;
59
+ }
60
+ }
@@ -1,12 +1,12 @@
1
- <van-popup
2
- show="{{true}}"
3
- round
4
- class="integral-receive-popup {{isFullScreen? 'integral-receive-popup-full' : ''}}"
5
- custom-style="background: unset"
6
- bind:close="closePopup"
7
- >
8
- <view class="receive-container" style="background-image: url({{awardImg}})">
9
- <view class="receive-container__content-number">+{{rewardValue}}</view>
10
- </view>
11
- <view class="receive-container__btn" catchtap="closePopup">开心收下</view>
12
- </van-popup>
1
+ <van-popup
2
+ show="{{true}}"
3
+ round
4
+ class="integral-receive-popup {{isFullScreen? 'integral-receive-popup-full' : ''}}"
5
+ custom-style="background: unset"
6
+ bind:close="closePopup"
7
+ >
8
+ <view class="receive-container" style="background-image: url({{awardImg}})">
9
+ <view class="receive-container__content-number">+{{rewardValue}}</view>
10
+ </view>
11
+ <view class="receive-container__btn" catchtap="closePopup">开心收下</view>
12
+ </van-popup>
@@ -1,66 +1,72 @@
1
1
  /*函数节流*/
2
2
  function throttle(fn, interval) {
3
- var enterTime = 0; //触发的时间
4
- var gapTime = interval || 300; //间隔时间,如果interval不传,则默认300ms
3
+ var enterTime = 0 //触发的时间
4
+ var gapTime = interval || 300 //间隔时间,如果interval不传,则默认300ms
5
5
  return function () {
6
- var context = this;
7
- var backTime = new Date(); //第一次函数return即触发的时间
6
+ var context = this
7
+ var backTime = new Date() //第一次函数return即触发的时间
8
8
  if (backTime - enterTime > gapTime) {
9
- fn.call(context, arguments);
10
- enterTime = backTime; //赋值给第一次触发的时间,这样就保存了第二次触发的时间
9
+ fn.call(context, arguments)
10
+ enterTime = backTime //赋值给第一次触发的时间,这样就保存了第二次触发的时间
11
11
  }
12
- };
12
+ }
13
13
  }
14
14
 
15
15
  /*函数防抖*/
16
16
  function debounce(func, wait, immediate) {
17
- let timer;
17
+ let timer
18
18
 
19
19
  return function () {
20
- //this指向debounce
21
- let context = this;
22
- //即参数,func,wait
23
- let args = arguments;
20
+ //this指向debounce
21
+ let context = this
22
+ //即参数,func,wait
23
+ let args = arguments
24
24
 
25
- //如果timer不为null, 清除定时器
26
- if (timer) clearTimeout(timer);
25
+ //如果timer不为null, 清除定时器
26
+ if (timer) clearTimeout(timer)
27
27
 
28
- //如果是立即执行
29
- if (immediate) {
30
- //定义callNow = !timer
31
- var callNow = !timer;
32
- //定义wait时间后把timer变为null
33
- //即在wait时间之后事件才会有效
34
- timer = setTimeout(() => {
35
- timer = null;
36
- }, wait)
37
- //如果callNow为true,即原本timer为null
38
- //那么执行func函数
39
- if (callNow) func.apply(context, args)
40
- } else {
41
- //如果是不立即执行
42
- //那就是每次重新定时
43
- timer = setTimeout(function () {
44
- func.apply(context, args)
45
- }, wait);
46
- }
28
+ //如果是立即执行
29
+ if (immediate) {
30
+ //定义callNow = !timer
31
+ var callNow = !timer
32
+ //定义wait时间后把timer变为null
33
+ //即在wait时间之后事件才会有效
34
+ timer = setTimeout(() => {
35
+ timer = null
36
+ }, wait)
37
+ //如果callNow为true,即原本timer为null
38
+ //那么执行func函数
39
+ if (callNow) func.apply(context, args)
40
+ } else {
41
+ //如果是不立即执行
42
+ //那就是每次重新定时
43
+ timer = setTimeout(function () {
44
+ func.apply(context, args)
45
+ }, wait)
46
+ }
47
47
  }
48
48
  }
49
- // }
50
- // function debounce(fn, interval) {
51
- // var timer;
52
- // var gapTime = interval || 1000; //间隔时间,如果interval不传,则默认1000ms
53
- // return function () {
54
- // clearTimeout(timer);
55
- // var context = this;
56
- // var args = arguments; //保存此处的arguments,因为setTimeout是全局的,arguments不是防抖函数需要的。
57
- // timer = setTimeout(function () {
58
- // fn.call(context, args);
59
- // }, gapTime);
60
- // };
61
- // }
49
+
50
+ /**
51
+ * 高并发请求打散
52
+ * @param delayHandler 目标并发量获取器
53
+ * @param options 配置项 { defaultDelay: 1000, useScatter: false }
54
+ * @param cb 回调函数
55
+ * @returns {number} 定时器
56
+ */
57
+ function scatterRequest(delayHandler, options, cb) {
58
+ let timer
59
+ const { defaultDelay = 1000, useScatter = false } = options
60
+ let delay = useScatter ? delayHandler() : defaultDelay // 默认并发量为1000
61
+ console.log(useScatter ? `[scatterRequest] High concurrency delay request: ${delay}` : '[scatterRequest] Disabled')
62
+ timer = setTimeout(() => {
63
+ cb()
64
+ }, delay)
65
+ return timer
66
+ }
62
67
 
63
68
  module.exports = {
64
69
  throttle,
65
- debounce
66
- };
70
+ debounce,
71
+ scatterRequest,
72
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xiaoe_mp_npm",
3
- "version": "1.0.21",
3
+ "version": "1.0.22-store1",
4
4
  "description": "",
5
5
  "main": "miniprogram_dist/index.js",
6
6
  "scripts": {
@@ -1,22 +1,22 @@
1
- .popup-content {
2
- height: 100%;
3
- }
4
- .popup-content .popup-header {
5
- width: 100%;
6
- position: sticky;
7
- top: 0;
8
- left: 0;
9
- background: #ffffff;
10
- height: 12.8vmin;
11
- }
12
- .popup-content .popup-cont {
13
- height: calc(100% - 12.8vmin);
14
- }
15
- .popup-content .popup-bottom {
16
- width: 100%;
17
- position: fixed;
18
- bottom: 0;
19
- left: 0;
20
- background: #ffffff;
21
- height: 12.8vmin;
22
- }
1
+ .popup-content {
2
+ height: 100%;
3
+ }
4
+ .popup-content .popup-header {
5
+ width: 100%;
6
+ position: sticky;
7
+ top: 0;
8
+ left: 0;
9
+ background: #ffffff;
10
+ height: 12.8vmin;
11
+ }
12
+ .popup-content .popup-cont {
13
+ height: calc(100% - 12.8vmin);
14
+ }
15
+ .popup-content .popup-bottom {
16
+ width: 100%;
17
+ position: fixed;
18
+ bottom: 0;
19
+ left: 0;
20
+ background: #ffffff;
21
+ height: 12.8vmin;
22
+ }
@@ -9,7 +9,8 @@ const task_title = {
9
9
  "6": "完成打赏",
10
10
  "7": "完成投票",
11
11
  "8": "完成问卷",
12
- "9": "完成签到"
12
+ "9": "完成签到",
13
+ "10": "完成答题"
13
14
  }
14
15
  }
15
16
  Component({
@@ -1,4 +1,4 @@
1
- {
2
- "component": true,
3
- "usingComponents": {}
1
+ {
2
+ "component": true,
3
+ "usingComponents": {}
4
4
  }
@@ -1,125 +1,125 @@
1
- @function vmin($rpx) {
2
- @return #{$rpx * 100 / $deviceWidth}vmin;
3
- }
4
-
5
- $deviceWidth: 750;
6
-
7
- @mixin barrage-container {
8
- color: #fff;
9
- font-size: vmin(20);
10
- .barrage-wrap {
11
- display: flex;
12
- .barrage-item {
13
- position: relative;
14
- background: linear-gradient(270deg, #ff552b00 0%, #ff552bc7 21.42%, #ff8b25eb 46.71%, #FC0 100%);
15
- height: vmin(64);
16
- font-size: vmin(24);
17
- line-height: vmin(64);
18
- border-radius: vmin(92);
19
- transition: 0.3s;
20
- transform: translateX(vmin(-500));
21
-
22
- .barrage-content {
23
- display: flex;
24
- align-items: center;
25
- }
26
-
27
- .task-completion-icon {
28
- width: vmin(48);
29
- height: vmin(48);
30
- border-radius: 50%;
31
- margin-left: vmin(10);
32
- margin-right: vmin(8);
33
- flex-shrink: 0;
34
- }
35
- .task-type {
36
- display: flex;
37
- flex-direction: column;
38
- margin-right: vmin(8);
39
- overflow: hidden;
40
- text-overflow: ellipsis;
41
- white-space: nowrap;
42
- view {
43
- width: 100%;
44
- overflow: hidden;
45
- text-overflow: ellipsis;
46
- white-space: nowrap;
47
- }
48
- }
49
- .prize-icon {
50
- width: vmin(56);
51
- height: vmin(56);
52
- display: flex;
53
- justify-content: center;
54
- align-items: center;
55
- margin: 0 vmin(8);
56
- }
57
- .prize-num {
58
- color: #FFF5CC;
59
- font-weight: 500;
60
- margin-right: vmin(8);
61
- }
62
- .right-arrow-icon{
63
- height: vmin(40);
64
- width: vmin(40);
65
- margin-right: vmin(52);
66
- }
67
- &.barrage-item-show {
68
- animation: taskFadeInLeft 1.5s both;
69
- }
70
- &.barrage-item-hide {
71
- animation: taskFadeOut 1.5s both;
72
- }
73
- }
74
- @keyframes taskFadeInLeft {
75
- 0% {
76
- transform: translateX(vmin(-500));
77
- opacity: 1;
78
- }
79
- 100% {
80
- transform: translateX(0);
81
- opacity: 1;
82
- }
83
- }
84
- @keyframes taskFadeOut {
85
- 0% {
86
- transform: translateX(0);
87
- opacity: 1;
88
- }
89
- 100% {
90
- transform: translateX(0);
91
- opacity: 0;
92
- }
93
- }
94
- @keyframes moveRight {
95
- from {
96
- transform: translateX(-100%);
97
- }
98
- to {
99
- transform: translateX(0);
100
- }
101
- }
102
- }
103
- }
104
-
105
- .barrage-container {
106
- @include barrage-container;
107
- }
108
-
109
- // 竖屏pad
110
- @media screen and (min-width: 768px) and (orientation: portrait) {
111
- $deviceWidth: 1536 !global;
112
-
113
- .barrage-container {
114
- @include barrage-container;
115
- }
116
- }
117
-
118
- // 横屏pad
119
- @media screen and (min-height: 768px) and (orientation: landscape) {
120
- $deviceWidth: 1536 !global;
121
-
122
- .barrage-container {
123
- @include barrage-container;
124
- }
125
- }
1
+ @function vmin($rpx) {
2
+ @return #{$rpx * 100 / $deviceWidth}vmin;
3
+ }
4
+
5
+ $deviceWidth: 750;
6
+
7
+ @mixin barrage-container {
8
+ color: #fff;
9
+ font-size: vmin(20);
10
+ .barrage-wrap {
11
+ display: flex;
12
+ .barrage-item {
13
+ position: relative;
14
+ background: linear-gradient(270deg, #ff552b00 0%, #ff552bc7 21.42%, #ff8b25eb 46.71%, #FC0 100%);
15
+ height: vmin(64);
16
+ font-size: vmin(24);
17
+ line-height: vmin(64);
18
+ border-radius: vmin(92);
19
+ transition: 0.3s;
20
+ transform: translateX(vmin(-500));
21
+
22
+ .barrage-content {
23
+ display: flex;
24
+ align-items: center;
25
+ }
26
+
27
+ .task-completion-icon {
28
+ width: vmin(48);
29
+ height: vmin(48);
30
+ border-radius: 50%;
31
+ margin-left: vmin(10);
32
+ margin-right: vmin(8);
33
+ flex-shrink: 0;
34
+ }
35
+ .task-type {
36
+ display: flex;
37
+ flex-direction: column;
38
+ margin-right: vmin(8);
39
+ overflow: hidden;
40
+ text-overflow: ellipsis;
41
+ white-space: nowrap;
42
+ view {
43
+ width: 100%;
44
+ overflow: hidden;
45
+ text-overflow: ellipsis;
46
+ white-space: nowrap;
47
+ }
48
+ }
49
+ .prize-icon {
50
+ width: vmin(56);
51
+ height: vmin(56);
52
+ display: flex;
53
+ justify-content: center;
54
+ align-items: center;
55
+ margin: 0 vmin(8);
56
+ }
57
+ .prize-num {
58
+ color: #FFF5CC;
59
+ font-weight: 500;
60
+ margin-right: vmin(8);
61
+ }
62
+ .right-arrow-icon{
63
+ height: vmin(40);
64
+ width: vmin(40);
65
+ margin-right: vmin(52);
66
+ }
67
+ &.barrage-item-show {
68
+ animation: taskFadeInLeft 1.5s both;
69
+ }
70
+ &.barrage-item-hide {
71
+ animation: taskFadeOut 1.5s both;
72
+ }
73
+ }
74
+ @keyframes taskFadeInLeft {
75
+ 0% {
76
+ transform: translateX(vmin(-500));
77
+ opacity: 1;
78
+ }
79
+ 100% {
80
+ transform: translateX(0);
81
+ opacity: 1;
82
+ }
83
+ }
84
+ @keyframes taskFadeOut {
85
+ 0% {
86
+ transform: translateX(0);
87
+ opacity: 1;
88
+ }
89
+ 100% {
90
+ transform: translateX(0);
91
+ opacity: 0;
92
+ }
93
+ }
94
+ @keyframes moveRight {
95
+ from {
96
+ transform: translateX(-100%);
97
+ }
98
+ to {
99
+ transform: translateX(0);
100
+ }
101
+ }
102
+ }
103
+ }
104
+
105
+ .barrage-container {
106
+ @include barrage-container;
107
+ }
108
+
109
+ // 竖屏pad
110
+ @media screen and (min-width: 768px) and (orientation: portrait) {
111
+ $deviceWidth: 1536 !global;
112
+
113
+ .barrage-container {
114
+ @include barrage-container;
115
+ }
116
+ }
117
+
118
+ // 横屏pad
119
+ @media screen and (min-height: 768px) and (orientation: landscape) {
120
+ $deviceWidth: 1536 !global;
121
+
122
+ .barrage-container {
123
+ @include barrage-container;
124
+ }
125
+ }
@@ -1,22 +1,22 @@
1
- <view class="barrage-container" catch:tap="bubbleClick" style="{{zIndex?'z-index:'+zIndex:''}}">
2
- <view class="barrage-wrap">
3
- <view class="barrage-item" animation="{{animationData}}">
4
- <view class="barrage-content">
5
- <image
6
- class="task-completion-icon"
7
- src="https://commonresource-1252524126.cdn.xiaoeknow.com/image/lopitz1y0c73.png"
8
- alt
9
- />
10
- <view wx:if="{{taskMsg.live_task.task_type === 1}}" class="task-type">观看时长</view>
11
- <view>{{ rewardValue }}</view>
12
- <image class="prize-icon" src="{{taskIconImg}}" alt="奖励" />
13
- <view class="prize-num">+{{ prizeNum }}</view>
14
- <image
15
- class="right-arrow-icon"
16
- src="https://commonresource-1252524126.cdn.xiaoeknow.com/image/lopitz1k0dzj.png"
17
- alt
18
- />
19
- </view>
20
- </view>
21
- </view>
22
- </view>
1
+ <view class="barrage-container" catch:tap="bubbleClick" style="{{zIndex?'z-index:'+zIndex:''}}">
2
+ <view class="barrage-wrap">
3
+ <view class="barrage-item" animation="{{animationData}}">
4
+ <view class="barrage-content">
5
+ <image
6
+ class="task-completion-icon"
7
+ src="https://commonresource-1252524126.cdn.xiaoeknow.com/image/lopitz1y0c73.png"
8
+ alt
9
+ />
10
+ <view wx:if="{{taskMsg.live_task.task_type === 1}}" class="task-type">观看时长</view>
11
+ <view>{{ rewardValue }}</view>
12
+ <image class="prize-icon" src="{{taskIconImg}}" alt="奖励" />
13
+ <view class="prize-num">+{{ prizeNum }}</view>
14
+ <image
15
+ class="right-arrow-icon"
16
+ src="https://commonresource-1252524126.cdn.xiaoeknow.com/image/lopitz1k0dzj.png"
17
+ alt
18
+ />
19
+ </view>
20
+ </view>
21
+ </view>
22
+ </view>