xiaoe_mp_npm 1.0.21 → 1.0.22-test02
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/.prettierrc.js +32 -6
- package/miniprogram_dist/GoodsItem/index.json +6 -6
- package/miniprogram_dist/GoodsItem/index.wxs +18 -18
- package/miniprogram_dist/LiveGoodsList/Header/index.js +54 -54
- package/miniprogram_dist/LiveGoodsList/Header/index.json +6 -6
- package/miniprogram_dist/LiveGoodsList/Header/index.less +45 -45
- package/miniprogram_dist/LiveGoodsList/Header/index.scss +105 -105
- package/miniprogram_dist/LiveGoodsList/Header/index.wxml +32 -32
- package/miniprogram_dist/LiveGoodsList/README.md +9 -9
- package/miniprogram_dist/LiveGoodsList/index.json +8 -8
- package/miniprogram_dist/LiveGoodsList/index.less +53 -53
- package/miniprogram_dist/LiveGoodsList/index.scss +92 -92
- package/miniprogram_dist/Task/TaskBubble/index.js +2 -1
- package/miniprogram_dist/Task/TaskPopup/component/TaskItem/index.js +241 -166
- package/miniprogram_dist/Task/TaskPopup/component/TaskItem/index.scss +26 -0
- package/miniprogram_dist/Task/TaskPopup/component/TaskItem/index.wxml +27 -8
- package/miniprogram_dist/Task/TaskPopup/component/TaskItem/index.wxss +96 -0
- package/miniprogram_dist/Task/TaskPopup/component/TaskList/index.js +4 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/quizContent/index.js +132 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/quizContent/index.json +6 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/quizContent/index.scss +192 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/quizContent/index.wxml +65 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/quizContent/index.wxs +79 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/quizContent/index.wxss +521 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/quizRichText/index.js +47 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/quizRichText/index.json +6 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/quizRichText/index.scss +7 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/quizRichText/index.wxml +2 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/quizRichText/index.wxss +298 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/base.wxml +50 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/html2json.js +623 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/htmlparser.js +183 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/iframeParse.js +216 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/loop.wxml +3563 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/showdown.js +2364 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/wxDiscode.js +209 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/wxParse.js +269 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/wxParse.wxml +1276 -0
- package/miniprogram_dist/Task/TaskQuizPopup/components/wxParse/wxParse.wxss +316 -0
- package/miniprogram_dist/Task/TaskQuizPopup/index.js +232 -0
- package/miniprogram_dist/Task/TaskQuizPopup/index.json +8 -0
- package/miniprogram_dist/Task/TaskQuizPopup/index.scss +159 -0
- package/miniprogram_dist/Task/TaskQuizPopup/index.wxml +97 -0
- package/miniprogram_dist/Task/TaskQuizPopup/index.wxss +478 -0
- package/miniprogram_dist/Task/taskQuizRemindPopup/index.js +79 -0
- package/miniprogram_dist/Task/taskQuizRemindPopup/index.json +6 -0
- package/miniprogram_dist/Task/taskQuizRemindPopup/index.scss +108 -0
- package/miniprogram_dist/Task/taskQuizRemindPopup/index.wxml +27 -0
- package/miniprogram_dist/Task/taskQuizRemindPopup/index.wxss +286 -0
- package/miniprogram_dist/common/utils/tool.js +54 -48
- package/package.json +1 -1
- package/src/AliveInvite/LiveRoomVertical/index.wxss +252 -252
- package/src/CollectionAddress/index.wxss +5 -5
- package/src/ConfirmOrder/components/AddressEdit/index.wxss +120 -120
- package/src/ConfirmOrder/components/AddressManage/index.wxss +98 -98
- package/src/ConfirmOrder/components/AddressSelect/index.wxss +67 -67
- package/src/ConfirmOrder/components/ChoosePicker/index.wxss +18 -18
- package/src/ConfirmOrder/components/GoodsInfo/components/GoodsCommerce/components/entityGiftList/index.wxss +45 -45
- package/src/ConfirmOrder/components/GoodsInfo/components/GoodsCommerce/components/entityItem/index.wxss +100 -100
- package/src/ConfirmOrder/components/GoodsInfo/components/GoodsCommerce/index.wxss +55 -55
- package/src/ConfirmOrder/components/GoodsInfo/components/ImageData/index.wxss +13 -13
- package/src/ConfirmOrder/components/Header/index.wxss +26 -26
- package/src/ConfirmOrder/components/IntegralSelect/componenets/integralTips/index.wxss +85 -85
- package/src/ConfirmOrder/components/Invoice/components/InvoiceSelect/index.wxss +155 -155
- package/src/ConfirmOrder/components/Invoice/components/InvoiceTip/index.wxss +51 -51
- package/src/ConfirmOrder/components/ModeSelect/index.wxss +44 -44
- package/src/ConfirmOrder/components/PickupSelect/index.wxss +22 -22
- package/src/ConfirmOrder/components/SelectSite/index.wxss +82 -82
- package/src/ConfirmOrder/components/Shipper/index.wxss +76 -76
- package/src/ConfirmOrder/components/ShipperEdit/index.wxss +78 -78
- package/src/ConfirmOrder/components/WechatAddress/index.wxss +22 -22
- package/src/ConfirmOrder/index.wxss +5 -5
- package/src/CouponList/couponMsg/index.wxss +3 -3
- package/src/CustomPopup/index.wxss +22 -22
- package/src/GoodsItem/index.json +6 -6
- package/src/GoodsItem/index.wxs +18 -18
- package/src/LiveGoodsList/Header/index.js +54 -54
- package/src/LiveGoodsList/Header/index.json +6 -6
- package/src/LiveGoodsList/Header/index.less +45 -45
- package/src/LiveGoodsList/Header/index.scss +105 -105
- package/src/LiveGoodsList/Header/index.wxml +32 -32
- package/src/LiveGoodsList/README.md +9 -9
- package/src/LiveGoodsList/index.json +8 -8
- package/src/LiveGoodsList/index.less +53 -53
- package/src/LiveGoodsList/index.scss +92 -92
- package/src/LiveGoodsList/index.wxss +218 -218
- package/src/PayComplete/Components/CouponItem/index.wxss +122 -122
- package/src/PayComplete/Components/Header/index.wxss +27 -27
- package/src/PayComplete/Components/LeadGroup/index.wxss +33 -33
- package/src/PayComplete/Components/PayGifts/index.wxss +157 -157
- package/src/PayComplete/Components/PayState/earnIntegral/index.wxss +23 -23
- package/src/PayComplete/Components/PayState/index.wxss +20 -20
- package/src/PayComplete/index.wxss +27 -27
- package/src/PayModule/wechatLoading/index.wxss +57 -57
- package/src/Recommend/index.wxss +110 -110
- package/src/Sku/Header/index.wxss +27 -27
- package/src/Sku/goods-info/index.wxss +52 -52
- package/src/Sku/index/index.wxss +52 -52
- package/src/Sku/row-item/index.wxss +50 -50
- package/src/Sku/step/index.wxss +11 -11
- package/src/Task/TaskBubble/index.js +2 -1
- package/src/Task/TaskBubble/index.wxss +289 -289
- package/src/Task/TaskIcon/index.wxss +130 -130
- package/src/Task/TaskPopup/component/RewardList/index.wxss +18 -18
- package/src/Task/TaskPopup/component/TaskItem/index.js +241 -166
- package/src/Task/TaskPopup/component/TaskItem/index.scss +26 -0
- package/src/Task/TaskPopup/component/TaskItem/index.wxml +27 -8
- package/src/Task/TaskPopup/component/TaskItem/index.wxss +1 -394
- package/src/Task/TaskPopup/component/TaskList/index.js +4 -0
- package/src/Task/TaskPopup/component/TaskList/index.wxss +118 -118
- package/src/Task/TaskPopup/component/TaskType/index.wxss +110 -110
- package/src/Task/TaskPopup/index.wxss +406 -406
- package/src/Task/TaskQuizPopup/components/quizContent/index.js +132 -0
- package/src/Task/TaskQuizPopup/components/quizContent/index.json +6 -0
- package/src/Task/TaskQuizPopup/components/quizContent/index.scss +192 -0
- package/src/Task/TaskQuizPopup/components/quizContent/index.wxml +65 -0
- package/src/Task/TaskQuizPopup/components/quizContent/index.wxs +79 -0
- package/src/Task/TaskQuizPopup/components/quizContent/index.wxss +1 -0
- package/src/Task/TaskQuizPopup/components/quizRichText/index.js +47 -0
- package/src/Task/TaskQuizPopup/components/quizRichText/index.json +6 -0
- package/src/Task/TaskQuizPopup/components/quizRichText/index.scss +7 -0
- package/src/Task/TaskQuizPopup/components/quizRichText/index.wxml +2 -0
- package/src/Task/TaskQuizPopup/components/quizRichText/index.wxss +1 -0
- package/src/Task/TaskQuizPopup/components/wxParse/base.wxml +50 -0
- package/src/Task/TaskQuizPopup/components/wxParse/html2json.js +623 -0
- package/src/Task/TaskQuizPopup/components/wxParse/htmlparser.js +183 -0
- package/src/Task/TaskQuizPopup/components/wxParse/iframeParse.js +216 -0
- package/src/Task/TaskQuizPopup/components/wxParse/loop.wxml +3563 -0
- package/src/Task/TaskQuizPopup/components/wxParse/showdown.js +2364 -0
- package/src/Task/TaskQuizPopup/components/wxParse/wxDiscode.js +209 -0
- package/src/Task/TaskQuizPopup/components/wxParse/wxParse.js +269 -0
- package/src/Task/TaskQuizPopup/components/wxParse/wxParse.wxml +1276 -0
- package/src/Task/TaskQuizPopup/components/wxParse/wxParse.wxss +283 -0
- package/src/Task/TaskQuizPopup/index.js +232 -0
- package/src/Task/TaskQuizPopup/index.json +8 -0
- package/src/Task/TaskQuizPopup/index.scss +159 -0
- package/src/Task/TaskQuizPopup/index.wxml +97 -0
- package/src/Task/TaskQuizPopup/index.wxss +1 -0
- package/src/Task/taskQuizRemindPopup/index.js +79 -0
- package/src/Task/taskQuizRemindPopup/index.json +6 -0
- package/src/Task/taskQuizRemindPopup/index.scss +108 -0
- package/src/Task/taskQuizRemindPopup/index.wxml +27 -0
- package/src/Task/taskQuizRemindPopup/index.wxss +1 -0
- package/src/Task/taskReceivePopup/customPrizes/index.wxss +220 -220
- package/src/Task/taskReceivePopup/index.wxss +1 -1
- package/src/Task/taskReceivePopup/integral/index.wxss +94 -94
- package/src/common/css/theme.wxss +16 -16
- package/src/common/utils/tool.js +54 -48
- package/src/miniprogram_npm/miniprogram-computed/index.js +1 -0
|
@@ -0,0 +1,283 @@
|
|
|
1
|
+
|
|
2
|
+
.wxParse{
|
|
3
|
+
color: #666;
|
|
4
|
+
line-height: 1.8;
|
|
5
|
+
overflow: hidden;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.wxParse view{
|
|
9
|
+
white-space:pre-line;
|
|
10
|
+
word-wrap:break-word;
|
|
11
|
+
box-sizing: border-box;
|
|
12
|
+
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.wxParse view,
|
|
16
|
+
.wxParse navigator,
|
|
17
|
+
.wxParse text,
|
|
18
|
+
.wxParse image,
|
|
19
|
+
.wxParse video,
|
|
20
|
+
.wxParse input,
|
|
21
|
+
.wxParse button,
|
|
22
|
+
.wxParse checkbox,
|
|
23
|
+
.wxParse label,
|
|
24
|
+
.wxParse textarea,
|
|
25
|
+
.wxParse form,
|
|
26
|
+
.wxParse radio,
|
|
27
|
+
.wxParse navigator{
|
|
28
|
+
max-width: 100% !important;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
view{
|
|
32
|
+
word-wrap:break-word;
|
|
33
|
+
white-space:normal;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/* 是否需要可选中 */
|
|
37
|
+
.wxParse .user-select view,
|
|
38
|
+
.wxParse .user-select text{
|
|
39
|
+
user-select:text;
|
|
40
|
+
-webkit-user-select:text;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.wxParse-inline{
|
|
44
|
+
display: inline;
|
|
45
|
+
margin: 0;
|
|
46
|
+
padding: 0;
|
|
47
|
+
}
|
|
48
|
+
/*//标题 */
|
|
49
|
+
.wxParse-div{margin: 0;padding: 0;}
|
|
50
|
+
.wxParse-h1{ font-size:2em; margin: .67em 0 }
|
|
51
|
+
.wxParse-h2{ font-size:1.5em; margin: .75em 0 }
|
|
52
|
+
.wxParse-h3{ font-size:1.17em; margin: .83em 0 }
|
|
53
|
+
.wxParse-h4{ margin: 1.12em 0}
|
|
54
|
+
.wxParse-h5 { font-size:.83em; margin: 1.5em 0 }
|
|
55
|
+
.wxParse-h6{ font-size:.75em; margin: 1.67em 0 }
|
|
56
|
+
|
|
57
|
+
.wxParse-h1 {
|
|
58
|
+
font-size: 18px;
|
|
59
|
+
font-weight: 400;
|
|
60
|
+
margin-bottom: .9em;
|
|
61
|
+
}
|
|
62
|
+
.wxParse-h2 {
|
|
63
|
+
font-size: 16px;
|
|
64
|
+
font-weight: 400;
|
|
65
|
+
margin-bottom: .34em;
|
|
66
|
+
}
|
|
67
|
+
.wxParse-h3 {
|
|
68
|
+
font-weight: 400;
|
|
69
|
+
font-size: 15px;
|
|
70
|
+
margin-bottom: .34em;
|
|
71
|
+
}
|
|
72
|
+
.wxParse-h4 {
|
|
73
|
+
font-weight: 400;
|
|
74
|
+
font-size: 14px;
|
|
75
|
+
margin-bottom: .24em;
|
|
76
|
+
}
|
|
77
|
+
.wxParse-h5 {
|
|
78
|
+
font-weight: 400;
|
|
79
|
+
font-size: 13px;
|
|
80
|
+
margin-bottom: .14em;
|
|
81
|
+
}
|
|
82
|
+
.wxParse-h6 {
|
|
83
|
+
font-weight: 400;
|
|
84
|
+
font-size: 12px;
|
|
85
|
+
margin-bottom: .04em;
|
|
86
|
+
}
|
|
87
|
+
.wxParse-section {
|
|
88
|
+
width: 100%;
|
|
89
|
+
max-width: 100% !important;
|
|
90
|
+
box-sizing: border-box;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.wxParse-h1, .wxParse-h2, .wxParse-h3, .wxParse-h4, .wxParse-h5, .wxParse-h6, .wxParse-b, .wxParse-strong { font-weight: bolder }
|
|
94
|
+
|
|
95
|
+
.wxParse-i,.wxParse-cite,.wxParse-em,.wxParse-var,.wxParse-address{font-style:italic}
|
|
96
|
+
.wxParse-pre,.wxParse-tt,.wxParse-code,.wxParse-kbd,.wxParse-samp{font-family:monospace}
|
|
97
|
+
.wxParse-pre{white-space:pre}
|
|
98
|
+
.wxParse-big{font-size:1.17em}
|
|
99
|
+
.wxParse-small,.wxParse-sub,.wxParse-sup{font-size:.83em}
|
|
100
|
+
.wxParse-sub{vertical-align:sub}
|
|
101
|
+
.wxParse-sup{vertical-align:super}
|
|
102
|
+
.wxParse-s,.wxParse-strike,.wxParse-del{text-decoration:line-through}
|
|
103
|
+
/*wxparse-自定义个性化的css样式*/
|
|
104
|
+
/*增加video的css样式*/
|
|
105
|
+
.wxParse-strong,wxParse-s{display: inline}
|
|
106
|
+
.wxParse-a{
|
|
107
|
+
color: blue;
|
|
108
|
+
word-break:break-all;
|
|
109
|
+
overflow:auto;
|
|
110
|
+
text-decoration: underline;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
.wxParse-video{
|
|
114
|
+
text-align: center;
|
|
115
|
+
margin: 10px 0;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.wxParse-video-video, .wxParse-iframe-video{
|
|
119
|
+
width:100%;
|
|
120
|
+
margin-bottom: 10rpx;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
video.xiaoe-iframe-video {
|
|
124
|
+
/* width:686rpx; */
|
|
125
|
+
height:386rpx;
|
|
126
|
+
margin-bottom: 20rpx;
|
|
127
|
+
max-width: 100%;
|
|
128
|
+
box-sizing: border-box;
|
|
129
|
+
display: block;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
.xiaoe-iframe-audio {
|
|
133
|
+
margin-bottom: 20rpx;
|
|
134
|
+
max-width: 100%;
|
|
135
|
+
display: block;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
.wxParse-img{
|
|
139
|
+
/*background-color: #efefef;*/
|
|
140
|
+
overflow: hidden!important;
|
|
141
|
+
/*width:40px;
|
|
142
|
+
height: 40px;*/
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
.hidden{
|
|
146
|
+
visibility: hidden;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.box-center{
|
|
150
|
+
margin: 0 auto;
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
.wxParse-blockquote {
|
|
154
|
+
margin: 0;
|
|
155
|
+
padding:10px 0 10px 5px;
|
|
156
|
+
font-family:Courier, Calibri,"宋体";
|
|
157
|
+
background:#f5f5f5;
|
|
158
|
+
border-left: 3px solid #dbdbdb;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.wxParse-code,.wxParse-wxxxcode-style{
|
|
162
|
+
display: inline;
|
|
163
|
+
background:#f5f5f5;
|
|
164
|
+
}
|
|
165
|
+
.wxParse-ul{
|
|
166
|
+
margin: 20rpx 10rpx;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
.wxParse-li,.wxParse-li-inner{
|
|
170
|
+
display: flex;
|
|
171
|
+
align-items: baseline;
|
|
172
|
+
margin: 10rpx 0;
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
.wxParse-li .wxParse-li-init {
|
|
176
|
+
width: 90rpx;
|
|
177
|
+
height: 100%;
|
|
178
|
+
text-align: right;
|
|
179
|
+
overflow:hidden;
|
|
180
|
+
line-height:40rpx;
|
|
181
|
+
height:45rpx;
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
.wxParse-li-text{
|
|
185
|
+
align-items: center;
|
|
186
|
+
line-height: 20px;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
.wxParse-hr {
|
|
190
|
+
display: block;
|
|
191
|
+
unicode-bidi: isolate;
|
|
192
|
+
margin-block-start: 0.5em;
|
|
193
|
+
margin-block-end: 0.5em;
|
|
194
|
+
margin-inline-start: auto;
|
|
195
|
+
margin-inline-end: auto;
|
|
196
|
+
overflow: hidden;
|
|
197
|
+
border-style: inset;
|
|
198
|
+
border-width: 1px;
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
.wxParse-li-circle{
|
|
202
|
+
width: 10rpx;
|
|
203
|
+
height: 10rpx;
|
|
204
|
+
background-color: #333;
|
|
205
|
+
margin: 0rpx 32rpx 4rpx;
|
|
206
|
+
border-radius: 10rpx;
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
.wxParse-li-square{
|
|
210
|
+
width: 10rpx;
|
|
211
|
+
height: 10rpx;
|
|
212
|
+
background-color: #333;
|
|
213
|
+
margin: 0rpx 32rpx 4rpx;
|
|
214
|
+
}
|
|
215
|
+
.wxParse-li-ring{
|
|
216
|
+
width: 10rpx;
|
|
217
|
+
height: 10rpx;
|
|
218
|
+
border: 2rpx solid #333;
|
|
219
|
+
border-radius: 50%;
|
|
220
|
+
background-color: #fff;
|
|
221
|
+
margin: 0rpx 30rpx 3rpx;
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
/*.wxParse-table{
|
|
225
|
+
width: 100%;
|
|
226
|
+
height: 400px;
|
|
227
|
+
}
|
|
228
|
+
.wxParse-thead,.wxParse-tfoot,.wxParse-tr{
|
|
229
|
+
display: flex;
|
|
230
|
+
flex-direction: row;
|
|
231
|
+
}
|
|
232
|
+
.wxParse-th,.wxParse-td{
|
|
233
|
+
display: flex;
|
|
234
|
+
width: 580px;
|
|
235
|
+
overflow: auto;
|
|
236
|
+
}*/
|
|
237
|
+
|
|
238
|
+
.wxParse-u {
|
|
239
|
+
text-decoration: underline;
|
|
240
|
+
}
|
|
241
|
+
.wxParse-hide{
|
|
242
|
+
display: none;
|
|
243
|
+
}
|
|
244
|
+
.WxEmojiView{
|
|
245
|
+
align-items: center;
|
|
246
|
+
}
|
|
247
|
+
.wxEmoji{
|
|
248
|
+
width: 16px;
|
|
249
|
+
height:16px;
|
|
250
|
+
}
|
|
251
|
+
.wxParse-tr{
|
|
252
|
+
display: flex;
|
|
253
|
+
border-right:1px solid #e0e0e0;
|
|
254
|
+
border-bottom:1px solid #e0e0e0;
|
|
255
|
+
}
|
|
256
|
+
.wxParse-th,
|
|
257
|
+
.wxParse-td{
|
|
258
|
+
flex:1;
|
|
259
|
+
padding:5px;
|
|
260
|
+
font-size:28rpx;
|
|
261
|
+
border-left:1px solid #e0e0e0;
|
|
262
|
+
word-wrap:break-word;
|
|
263
|
+
}
|
|
264
|
+
.wxParse-td:last{
|
|
265
|
+
border-top:1px solid #e0e0e0;
|
|
266
|
+
}
|
|
267
|
+
.wxParse-th{
|
|
268
|
+
background:#f0f0f0;
|
|
269
|
+
border-top:1px solid #e0e0e0;
|
|
270
|
+
}
|
|
271
|
+
|
|
272
|
+
.img{
|
|
273
|
+
max-width: 100%;
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
.wxParse-br{
|
|
277
|
+
min-height: 1em;
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
/* p标签没换行 故设此样式 */
|
|
281
|
+
.wxParse-p{
|
|
282
|
+
min-height: 1em;
|
|
283
|
+
}
|
|
@@ -0,0 +1,232 @@
|
|
|
1
|
+
const computedBehavior = require('miniprogram-computed').behavior
|
|
2
|
+
import { rpxToVmin } from '../../common/utils/index.js'
|
|
3
|
+
import Dialog from '@vant/weapp/dialog/dialog';
|
|
4
|
+
|
|
5
|
+
// 奖励icon配置
|
|
6
|
+
const reward_config = {
|
|
7
|
+
1: {
|
|
8
|
+
label: '积分',
|
|
9
|
+
icon: 'https://commonresource-1252524126.cdn.xiaoeknow.com/image/ltrgz5y1064s.png',
|
|
10
|
+
},
|
|
11
|
+
2: {
|
|
12
|
+
label: '优惠券',
|
|
13
|
+
icon: 'https://commonresource-1252524126.cdn.xiaoeknow.com/image/ltrgz5y00wfn.png',
|
|
14
|
+
},
|
|
15
|
+
3: {
|
|
16
|
+
label: '红包',
|
|
17
|
+
icon: 'https://commonresource-1252524126.cdn.xiaoeknow.com/image/ltrgz5xy0i8g.png',
|
|
18
|
+
},
|
|
19
|
+
4: {
|
|
20
|
+
label: '课程',
|
|
21
|
+
icon: 'https://commonresource-1252524126.cdn.xiaoeknow.com/image/ltrgz5xu04is.png',
|
|
22
|
+
},
|
|
23
|
+
5: {
|
|
24
|
+
label: '奖品',
|
|
25
|
+
icon: 'https://commonresource-1252524126.cdn.xiaoeknow.com/image/ltrgz5xz08pf.png',
|
|
26
|
+
},
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
Component({
|
|
30
|
+
behaviors: [computedBehavior],
|
|
31
|
+
/**
|
|
32
|
+
* 组件的属性列表
|
|
33
|
+
*/
|
|
34
|
+
properties: {
|
|
35
|
+
showPopup:{
|
|
36
|
+
type: Boolean,
|
|
37
|
+
value: false
|
|
38
|
+
},
|
|
39
|
+
popPosition: {
|
|
40
|
+
type: String,
|
|
41
|
+
value: 'bottom'
|
|
42
|
+
},
|
|
43
|
+
orientation: {
|
|
44
|
+
type: String,
|
|
45
|
+
value: 'hor'
|
|
46
|
+
},
|
|
47
|
+
// 当前打开弹窗的任务
|
|
48
|
+
quiz_task_item: {
|
|
49
|
+
type: Object,
|
|
50
|
+
value: {}
|
|
51
|
+
},
|
|
52
|
+
// 当前任务的参与结果
|
|
53
|
+
join_result: {
|
|
54
|
+
type: Object,
|
|
55
|
+
value: {}
|
|
56
|
+
},
|
|
57
|
+
// 当前答题数组
|
|
58
|
+
show_quiz_list: {
|
|
59
|
+
type: Array,
|
|
60
|
+
value: []
|
|
61
|
+
},
|
|
62
|
+
// 当前查看解析的答题数组
|
|
63
|
+
show_quiz_analysis_list: {
|
|
64
|
+
type: Array,
|
|
65
|
+
value: []
|
|
66
|
+
},
|
|
67
|
+
// 整个任务列表数据
|
|
68
|
+
task_list: {
|
|
69
|
+
type: Array,
|
|
70
|
+
value: []
|
|
71
|
+
},
|
|
72
|
+
// 是否是结果解析
|
|
73
|
+
showAnalysis: {
|
|
74
|
+
type: Boolean,
|
|
75
|
+
value: false,
|
|
76
|
+
},
|
|
77
|
+
// 是否全屏互动
|
|
78
|
+
isFull: {
|
|
79
|
+
type: Boolean,
|
|
80
|
+
value: false
|
|
81
|
+
}
|
|
82
|
+
},
|
|
83
|
+
|
|
84
|
+
/**
|
|
85
|
+
* 组件的初始数据
|
|
86
|
+
*/
|
|
87
|
+
data: {
|
|
88
|
+
currentIndex: 0, // 当前题目的下标
|
|
89
|
+
total: 0, // 总题目数
|
|
90
|
+
quizList: [], // 题目内容
|
|
91
|
+
},
|
|
92
|
+
computed: {
|
|
93
|
+
customStyle({ popPosition, orientation }) {
|
|
94
|
+
const position = `position: ${orientation === 'ver' ? 'fixed' : 'absolute'}; left: 0; bottom: 0`
|
|
95
|
+
return popPosition === "bottom" ? `${position}; width: ${orientation === 'ver' ? '100%' : ''}; height: calc(100% - ${rpxToVmin(422)});` : "height: 100%;width: 100vmin;border-radius: 0;"
|
|
96
|
+
},
|
|
97
|
+
// 奖励图标
|
|
98
|
+
rewardIcon({ quiz_task_item }) {
|
|
99
|
+
const { reward_type } = quiz_task_item
|
|
100
|
+
return reward_config[reward_type]?.icon
|
|
101
|
+
},
|
|
102
|
+
|
|
103
|
+
// 奖励内容
|
|
104
|
+
rewardText({ quiz_task_item }) {
|
|
105
|
+
const { reward_type, reward_value } = quiz_task_item
|
|
106
|
+
const onlyOneType = [2, 4, 5]
|
|
107
|
+
if (onlyOneType.includes(reward_type)) {
|
|
108
|
+
return `+1 ${reward_config[reward_type]?.label}`
|
|
109
|
+
} else if (reward_type === 3) {
|
|
110
|
+
return `+${(reward_value.money / 100).toFixed(2)} ${reward_config[reward_type]?.label}`
|
|
111
|
+
} else {
|
|
112
|
+
return `+${reward_value} ${reward_config[reward_type]?.label}`
|
|
113
|
+
}
|
|
114
|
+
},
|
|
115
|
+
},
|
|
116
|
+
observers: {
|
|
117
|
+
showPopup(val) {
|
|
118
|
+
if (val) {
|
|
119
|
+
this.setData({
|
|
120
|
+
currentIndex: 0,
|
|
121
|
+
total: this.data.show_quiz_list.length,
|
|
122
|
+
quizList: this.data[this.data.showAnalysis ? 'show_quiz_analysis_list' : 'show_quiz_list'],
|
|
123
|
+
}, ()=> {
|
|
124
|
+
console.error('jer=========进入弹窗', this.data);
|
|
125
|
+
})
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
},
|
|
129
|
+
/**
|
|
130
|
+
* 组件的方法列表
|
|
131
|
+
*/
|
|
132
|
+
methods: {
|
|
133
|
+
closePop(){
|
|
134
|
+
this.triggerEvent("closePop")
|
|
135
|
+
this.setData({
|
|
136
|
+
currentIndex: 0,
|
|
137
|
+
total: 0,
|
|
138
|
+
quizList: [],
|
|
139
|
+
})
|
|
140
|
+
},
|
|
141
|
+
// 答题顺序恐惧
|
|
142
|
+
handleQuizOrder(e) {
|
|
143
|
+
let currentIndex = this.data.currentIndex;
|
|
144
|
+
switch (e.currentTarget.dataset.type) {
|
|
145
|
+
case "prev":
|
|
146
|
+
currentIndex--;
|
|
147
|
+
break;
|
|
148
|
+
case "next":
|
|
149
|
+
currentIndex++;
|
|
150
|
+
break;
|
|
151
|
+
case "submit":
|
|
152
|
+
Dialog.confirm({
|
|
153
|
+
context: this,
|
|
154
|
+
closeOnClickOverlay: false,
|
|
155
|
+
title: '确认提交?',
|
|
156
|
+
message: '提交后将无法修改答案,系统直接批改,确认要提交吗?',
|
|
157
|
+
confirmButtonText: '确认',
|
|
158
|
+
cancelButtonText: '取消',
|
|
159
|
+
confirmButtonColor: '#1472FF',
|
|
160
|
+
zIndex: 501,
|
|
161
|
+
})
|
|
162
|
+
.then(() => {
|
|
163
|
+
// 处理获取题目id和答案id
|
|
164
|
+
let params = this.data.quizList.map((item) => {
|
|
165
|
+
// 获取用户选择的答案
|
|
166
|
+
let userAnswer = [];
|
|
167
|
+
for (let index = 0; index < item.options.length; index++) {
|
|
168
|
+
const ele = item.options[index];
|
|
169
|
+
if (ele.selected) {
|
|
170
|
+
userAnswer.push(ele.op_id);
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
return {
|
|
174
|
+
qs_id: item.qs_id,
|
|
175
|
+
op_id: userAnswer,
|
|
176
|
+
};
|
|
177
|
+
});
|
|
178
|
+
// 获取列表中当前任务是否结束了,兼容提交前端校验
|
|
179
|
+
const taskFindItem =
|
|
180
|
+
this.data.task_list.find(
|
|
181
|
+
(item) => item.id === this.data.quiz_task_item.id
|
|
182
|
+
) || {};
|
|
183
|
+
if (taskFindItem.state === 2) {
|
|
184
|
+
this.closePop()
|
|
185
|
+
wx.showToast({
|
|
186
|
+
title: '当前答题已结束,无法继续提交',
|
|
187
|
+
icon: 'none',
|
|
188
|
+
duration: 1000,
|
|
189
|
+
})
|
|
190
|
+
return;
|
|
191
|
+
}
|
|
192
|
+
// 存储用户答案,用于接口请求参数
|
|
193
|
+
// 调用完成任务接口
|
|
194
|
+
this.triggerEvent("commonFulfilTasks", {
|
|
195
|
+
user_answer: params,
|
|
196
|
+
ids: [this.data.quiz_task_item.id],
|
|
197
|
+
taskItem: this.data.quiz_task_item,
|
|
198
|
+
})
|
|
199
|
+
})
|
|
200
|
+
.catch((err) => {
|
|
201
|
+
// 暂无操作
|
|
202
|
+
});
|
|
203
|
+
break;
|
|
204
|
+
|
|
205
|
+
default:
|
|
206
|
+
break;
|
|
207
|
+
}
|
|
208
|
+
this.setData({ currentIndex })
|
|
209
|
+
},
|
|
210
|
+
// 点击选项进行操作答题
|
|
211
|
+
clickOption(e) {
|
|
212
|
+
const index = e.detail
|
|
213
|
+
console.error('jer=============选择11111', index);
|
|
214
|
+
const tempQuizItem =
|
|
215
|
+
this.data.quizList[this.data.currentIndex];
|
|
216
|
+
// 多选题
|
|
217
|
+
if (tempQuizItem.qs_type === 1) {
|
|
218
|
+
tempQuizItem.options[index].selected = !tempQuizItem.options[index].selected
|
|
219
|
+
} else {
|
|
220
|
+
for (let i = 0; i < tempQuizItem.options.length; i++) {
|
|
221
|
+
tempQuizItem.options[i].selected = false;
|
|
222
|
+
}
|
|
223
|
+
tempQuizItem.options[index].selected = true;
|
|
224
|
+
}
|
|
225
|
+
this.setData({
|
|
226
|
+
quizList: this.data.quizList
|
|
227
|
+
}, ()=> {
|
|
228
|
+
console.error('jer============更改之后的数组', this.data.quizList);
|
|
229
|
+
})
|
|
230
|
+
},
|
|
231
|
+
}
|
|
232
|
+
})
|
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
$deviceWidth: 750;
|
|
2
|
+
|
|
3
|
+
@function vmin($rpx) {
|
|
4
|
+
@return #{$rpx * 100 / $deviceWidth}vmin;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
@mixin task-quiz-popup {
|
|
8
|
+
height: 100%;
|
|
9
|
+
.quiz-popup {
|
|
10
|
+
display: flex;
|
|
11
|
+
flex-direction: column;
|
|
12
|
+
align-items: center;
|
|
13
|
+
background-color: #f5f5f5;
|
|
14
|
+
border-radius: vmin(24) vmin(24) 0 0;
|
|
15
|
+
z-index: 500;
|
|
16
|
+
.content-header {
|
|
17
|
+
width: 100%;
|
|
18
|
+
height: vmin(96);
|
|
19
|
+
font-size: vmin(32);
|
|
20
|
+
font-weight: 500;
|
|
21
|
+
display: flex;
|
|
22
|
+
justify-content: center;
|
|
23
|
+
align-items: center;
|
|
24
|
+
position: relative;
|
|
25
|
+
.popup-close-icon {
|
|
26
|
+
width: vmin(32);
|
|
27
|
+
height: vmin(32);
|
|
28
|
+
position: absolute;
|
|
29
|
+
top: vmin(32);
|
|
30
|
+
right: vmin(32);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.popup-content{
|
|
35
|
+
flex: 1;
|
|
36
|
+
box-sizing: border-box;
|
|
37
|
+
overflow-y: overlay;
|
|
38
|
+
padding: 0 vmin(32);
|
|
39
|
+
width: 100%;
|
|
40
|
+
|
|
41
|
+
.reward-show-box {
|
|
42
|
+
display: flex;
|
|
43
|
+
padding: vmin(32) vmin(24);
|
|
44
|
+
flex-direction: column;
|
|
45
|
+
align-items: flex-start;
|
|
46
|
+
border-radius: vmin(16);
|
|
47
|
+
background: #fff;
|
|
48
|
+
color: #333333;
|
|
49
|
+
font-family: "PingFang SC";
|
|
50
|
+
font-size: vmin(28);
|
|
51
|
+
font-style: normal;
|
|
52
|
+
font-weight: 400;
|
|
53
|
+
margin-bottom: vmin(32);
|
|
54
|
+
line-height: vmin(40);
|
|
55
|
+
.reward-condition {
|
|
56
|
+
font-weight: 500;
|
|
57
|
+
.orange-color {
|
|
58
|
+
color: #ff5429;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
.reward-result {
|
|
62
|
+
display: flex;
|
|
63
|
+
align-items: center;
|
|
64
|
+
margin-top: vmin(8);
|
|
65
|
+
.reward-result-show {
|
|
66
|
+
margin-left: vmin(16);
|
|
67
|
+
color: #ff5429;
|
|
68
|
+
font-size: vmin(24);
|
|
69
|
+
display: inline-flex;
|
|
70
|
+
align-items: center;
|
|
71
|
+
|
|
72
|
+
.reward-img {
|
|
73
|
+
width: vmin(24);
|
|
74
|
+
height: vmin(24);
|
|
75
|
+
padding: vmin(4) 0;
|
|
76
|
+
vertical-align: top;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
.analysis-tip {
|
|
82
|
+
font-size: vmin(32);
|
|
83
|
+
color: #333333;
|
|
84
|
+
font-family: "PingFang SC";
|
|
85
|
+
font-style: normal;
|
|
86
|
+
font-weight: 500;
|
|
87
|
+
line-height: vmin(48);
|
|
88
|
+
margin-bottom: vmin(32);
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.content-footer {
|
|
93
|
+
width: 100%;
|
|
94
|
+
height: vmin(112);
|
|
95
|
+
font-size: vmin(32);
|
|
96
|
+
font-weight: 400;
|
|
97
|
+
color: #999;
|
|
98
|
+
line-height: vmin(40);
|
|
99
|
+
display: flex;
|
|
100
|
+
justify-content: center;
|
|
101
|
+
align-items: center;
|
|
102
|
+
padding: 0 vmin(32);
|
|
103
|
+
box-sizing: border-box;
|
|
104
|
+
view {
|
|
105
|
+
flex: 1;
|
|
106
|
+
height: vmin(80);
|
|
107
|
+
font-weight: 500;
|
|
108
|
+
line-height: vmin(80);
|
|
109
|
+
font-size: vmin(28);
|
|
110
|
+
text-align: center;
|
|
111
|
+
border-radius: vmin(40);
|
|
112
|
+
box-sizing: border-box;
|
|
113
|
+
}
|
|
114
|
+
.last-step {
|
|
115
|
+
margin-right: vmin(30);
|
|
116
|
+
}
|
|
117
|
+
.last-step,
|
|
118
|
+
.next-step {
|
|
119
|
+
color: #1472ff;
|
|
120
|
+
border: vmin(2) solid #1472ff;
|
|
121
|
+
}
|
|
122
|
+
.submit-step {
|
|
123
|
+
color: #fff;
|
|
124
|
+
background: #1472ff;
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.task-quiz-popup {
|
|
131
|
+
@include task-quiz-popup;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
// 竖屏pad
|
|
135
|
+
@media screen and (min-width: 768px) and (orientation: portrait) {
|
|
136
|
+
$deviceWidth: 1536 !global;
|
|
137
|
+
|
|
138
|
+
.task-quiz-popup {
|
|
139
|
+
@include task-quiz-popup;
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
// PC 放大适配
|
|
144
|
+
@media screen and (min-height: 630px) and (orientation: landscape) {
|
|
145
|
+
$deviceWidth: 1260 !global;
|
|
146
|
+
|
|
147
|
+
.task-quiz-popup {
|
|
148
|
+
@include task-quiz-popup;
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
// 横屏pad
|
|
153
|
+
@media screen and (min-height: 768px) and (orientation: landscape) {
|
|
154
|
+
$deviceWidth: 1536 !global;
|
|
155
|
+
|
|
156
|
+
.task-quiz-popup {
|
|
157
|
+
@include task-quiz-popup;
|
|
158
|
+
}
|
|
159
|
+
}
|