southnote-mini-sdk 1.0.21 → 1.0.22
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/app.js +1 -22
- package/assets/file/badwords.js +1 -63008
- package/assets/file/rules.js +1 -38
- package/components/bottomSheet/bottomSheet.js +1 -473
- package/components/experience-item/experience-item.js +1 -105
- package/components/grid-item/grid-item.js +1 -8
- package/components/post-item/post-item.js +1 -1086
- package/components/wiki-renderer/wiki-renderer.js +1 -636
- package/components/wiki-tabs/wiki-tabs.js +1 -52
- package/index.js +1 -49
- package/package.json +2 -22
- package/pages/addGame/addGame.js +1 -454
- package/pages/addSubject/addSubject.js +1 -199
- package/pages/commonLogin/commonLogin.js +1 -269
- package/pages/copyOfficial/copyOfficial.js +1 -25
- package/pages/demo/demo.js +1 -23
- package/pages/game/game.js +1 -1305
- package/pages/home/home.js +1 -665
- package/pages/lottery-winners/lottery-winners.js +1 -60
- package/pages/message/messageCommentsAndAt/messageCommentsAndAt.js +1 -178
- package/pages/message/messageEntire/messageEntire.js +1 -112
- package/pages/message/messageLikeAndCollect/messageLikeAndCollect.js +1 -147
- package/pages/message/messageNewFans/messageNewFans.js +1 -139
- package/pages/officialWebview/officialWebview.js +1 -13
- package/pages/post/post.js +1 -1856
- package/pages/post-editor/post-editor.js +1 -465
- package/pages/postDialog/postDialog.js +1 -560
- package/pages/report-category/report-category.js +1 -29
- package/pages/report-form/report-form.js +1 -65
- package/pages/sevenDaySignDetail/sevenDaySignDetail.js +1 -273
- package/pages/topic/topic.js +1 -266
- package/pages/user/user.js +1 -939
- package/pages/userDatum/userDatum.js +1 -24
- package/pages/userGameLib/userGameLib.js +1 -105
- package/pages/webview/webview.js +1 -25
- package/pages/wheelActivivty/wheelActivivty.js +1 -492
- package/pages/wiki/wiki.js +1 -138
- package/request/JKRequest.js +1 -177
- package/services/home.js +1 -603
- package/utils/auth.js +1 -17
- package/utils/base64.js +1 -67
- package/utils/compressImage.js +1 -41
- package/utils/exp.js +1 -49
- package/utils/formatPost.js +1 -18
- package/utils/parseContent.js +1 -191
- package/utils/query-select.js +1 -9
- package/utils/sensitive.js +1 -82
|
@@ -1,465 +1 @@
|
|
|
1
|
-
import {
|
|
2
|
-
publishPostNew,
|
|
3
|
-
getUploadToken
|
|
4
|
-
} from "../../services/home"
|
|
5
|
-
import sensitive from '../../utils/sensitive'
|
|
6
|
-
import {
|
|
7
|
-
compressImages
|
|
8
|
-
} from "../../utils/compressImage"
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
Page({
|
|
12
|
-
data: {
|
|
13
|
-
content: '',
|
|
14
|
-
images: [],
|
|
15
|
-
emojiVisible: false,
|
|
16
|
-
emojiList: [],
|
|
17
|
-
textareaHeight: 'calc(100vh - 230rpx)', // 默认高度
|
|
18
|
-
selectedTopic: null,
|
|
19
|
-
selectedGame: null,
|
|
20
|
-
cursor: 0,
|
|
21
|
-
// 新增
|
|
22
|
-
keyboardHeight: 0,
|
|
23
|
-
isKeyboardVisible: false,
|
|
24
|
-
showGameOption: false,
|
|
25
|
-
|
|
26
|
-
},
|
|
27
|
-
|
|
28
|
-
// 防重复点击
|
|
29
|
-
isSubmitting: false,
|
|
30
|
-
|
|
31
|
-
onLoad(options) {
|
|
32
|
-
const gameId = options.gameId;
|
|
33
|
-
const gameName = decodeURIComponent(options.gameName || '');
|
|
34
|
-
if (gameId && gameName) {
|
|
35
|
-
|
|
36
|
-
this.setData({
|
|
37
|
-
gameId,
|
|
38
|
-
selectedGame: {
|
|
39
|
-
id: gameId,
|
|
40
|
-
name: gameName
|
|
41
|
-
}
|
|
42
|
-
});
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
const windowInfo = wx.getWindowInfo()
|
|
46
|
-
const safeArea = windowInfo.safeArea
|
|
47
|
-
const safeHeight = safeArea.height
|
|
48
|
-
const safeTop = safeArea.top
|
|
49
|
-
const safeBottom = windowInfo.screenHeight - safeArea.bottom
|
|
50
|
-
console.log('safeHeight:', safeHeight)
|
|
51
|
-
console.log('safeBottom:', safeBottom)
|
|
52
|
-
this.setData({
|
|
53
|
-
safeBottomHeight: safeBottom
|
|
54
|
-
})
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
// wx.getSystemInfo({
|
|
60
|
-
// success: (res) => {
|
|
61
|
-
// // 安全区域信息
|
|
62
|
-
// const safeArea = res.safeArea;
|
|
63
|
-
// const safeHeight = safeArea.height; // 安全区域高度
|
|
64
|
-
// const safeTop = safeArea.top; // 安全区顶部 y 坐标
|
|
65
|
-
// const safeBottom = res.screenHeight - safeArea.bottom; // 底部安全区高度(手势栏)
|
|
66
|
-
|
|
67
|
-
// console.log('safeHeight:', safeHeight);
|
|
68
|
-
// console.log('safeBottom:', safeBottom);
|
|
69
|
-
// this.setData({
|
|
70
|
-
// safeBottomHeight: safeBottom
|
|
71
|
-
// })
|
|
72
|
-
// }
|
|
73
|
-
// });
|
|
74
|
-
|
|
75
|
-
// 初始化emoji列表,例如44个
|
|
76
|
-
let list = [];
|
|
77
|
-
for (let i = 1; i <= 44; i++) {
|
|
78
|
-
let num = i.toString().padStart(3, '0');
|
|
79
|
-
list.push(`../emoji/smile${num}.png`);
|
|
80
|
-
}
|
|
81
|
-
this.setData({
|
|
82
|
-
emojiList: list
|
|
83
|
-
});
|
|
84
|
-
|
|
85
|
-
// 监听键盘高度变化(确保微信基础库支持)
|
|
86
|
-
wx.onKeyboardHeightChange(res => {
|
|
87
|
-
const height = res.height || 0;
|
|
88
|
-
if (height > 0) {
|
|
89
|
-
// 键盘弹起:互斥,隐藏 emoji 面板
|
|
90
|
-
this.setData({
|
|
91
|
-
keyboardHeight: height,
|
|
92
|
-
isKeyboardVisible: true,
|
|
93
|
-
emojiVisible: false
|
|
94
|
-
}, this.updateTextareaHeight);
|
|
95
|
-
} else {
|
|
96
|
-
// 键盘收起
|
|
97
|
-
this.setData({
|
|
98
|
-
keyboardHeight: 0,
|
|
99
|
-
isKeyboardVisible: false
|
|
100
|
-
}, this.updateTextareaHeight);
|
|
101
|
-
}
|
|
102
|
-
});
|
|
103
|
-
},
|
|
104
|
-
|
|
105
|
-
onShow() {
|
|
106
|
-
this.insertSelectedTopic();
|
|
107
|
-
},
|
|
108
|
-
removeSelectedGame() {
|
|
109
|
-
this.setData({
|
|
110
|
-
selectedGame: null
|
|
111
|
-
});
|
|
112
|
-
},
|
|
113
|
-
/** 计算高度(考虑键盘互斥、emoji、图片) */
|
|
114
|
-
updateTextareaHeight() {
|
|
115
|
-
const {
|
|
116
|
-
emojiVisible,
|
|
117
|
-
images,
|
|
118
|
-
keyboardHeight,
|
|
119
|
-
isKeyboardVisible
|
|
120
|
-
} = this.data;
|
|
121
|
-
|
|
122
|
-
// 优先:键盘
|
|
123
|
-
if (isKeyboardVisible && keyboardHeight > 0) {
|
|
124
|
-
// 留出工具栏高度(约100rpx)用于显示按钮 — 因为键盘单位是 px,这里直接用 px
|
|
125
|
-
const reservedPx = 190 + 40; // 你可以调整这个值微调显示
|
|
126
|
-
let height;
|
|
127
|
-
if (images.length > 0) {
|
|
128
|
-
// 有图并且键盘弹出
|
|
129
|
-
height = `calc(100vh - ${keyboardHeight + reservedPx}px)`;
|
|
130
|
-
} else {
|
|
131
|
-
// 无图并且键盘弹出
|
|
132
|
-
height = `calc(100vh - ${keyboardHeight + 90+30}px)`;
|
|
133
|
-
}
|
|
134
|
-
this.setData({
|
|
135
|
-
textareaHeight: height
|
|
136
|
-
});
|
|
137
|
-
return;
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
// 如果显示 emoji(并且键盘未显示)
|
|
141
|
-
if (emojiVisible && images.length > 0) {
|
|
142
|
-
this.setData({
|
|
143
|
-
textareaHeight: 'calc(100vh - 840rpx)'
|
|
144
|
-
});
|
|
145
|
-
} else if (emojiVisible) {
|
|
146
|
-
this.setData({
|
|
147
|
-
textareaHeight: 'calc(100vh - 660rpx)'
|
|
148
|
-
});
|
|
149
|
-
} else if (images.length > 0) {
|
|
150
|
-
this.setData({
|
|
151
|
-
textareaHeight: 'calc(100vh - 410rpx)'
|
|
152
|
-
});
|
|
153
|
-
} else {
|
|
154
|
-
this.setData({
|
|
155
|
-
textareaHeight: 'calc(100vh - 240rpx)'
|
|
156
|
-
});
|
|
157
|
-
}
|
|
158
|
-
},
|
|
159
|
-
|
|
160
|
-
onInput(e) {
|
|
161
|
-
this.setData({
|
|
162
|
-
content: e.detail.value,
|
|
163
|
-
cursor: e.detail.cursor // 输入时光标位置
|
|
164
|
-
});
|
|
165
|
-
},
|
|
166
|
-
|
|
167
|
-
handleBlur(e) {
|
|
168
|
-
this.setData({
|
|
169
|
-
cursor: e.detail.cursor
|
|
170
|
-
});
|
|
171
|
-
// 注意:键盘高度变化由 onKeyboardHeightChange 处理,不在这里改 isKeyboardVisible
|
|
172
|
-
},
|
|
173
|
-
|
|
174
|
-
async chooseImage() {
|
|
175
|
-
// 选择图片前隐藏键盘(与 emoji 互斥)
|
|
176
|
-
try {
|
|
177
|
-
wx.hideKeyboard();
|
|
178
|
-
} catch (e) {
|
|
179
|
-
/* ignore */
|
|
180
|
-
}
|
|
181
|
-
|
|
182
|
-
wx.chooseMedia({
|
|
183
|
-
count: 9 - this.data.images.length,
|
|
184
|
-
mediaType: ['image'],
|
|
185
|
-
sourceType: ['album', 'camera'],
|
|
186
|
-
success: async (res) => {
|
|
187
|
-
const newImages = [];
|
|
188
|
-
|
|
189
|
-
for (let file of res.tempFiles) {
|
|
190
|
-
|
|
191
|
-
const compressed = await compressImages(file.tempFilePath);
|
|
192
|
-
|
|
193
|
-
// 获取压缩后的文件信息
|
|
194
|
-
const info = await new Promise((resolve, reject) => {
|
|
195
|
-
wx.getFileInfo({
|
|
196
|
-
filePath: compressed,
|
|
197
|
-
success: resolve,
|
|
198
|
-
fail: reject
|
|
199
|
-
});
|
|
200
|
-
});
|
|
201
|
-
|
|
202
|
-
console.log('压缩后图片路径:', compressed);
|
|
203
|
-
console.log('压缩后大小(字节):', info.size);
|
|
204
|
-
console.log('压缩后大小(MB):', (info.size / 1024 / 1024).toFixed(2));
|
|
205
|
-
newImages.push(compressed);
|
|
206
|
-
}
|
|
207
|
-
|
|
208
|
-
const images = this.data.images.concat(newImages);
|
|
209
|
-
|
|
210
|
-
this.setData({
|
|
211
|
-
images
|
|
212
|
-
}, this.updateTextareaHeight);
|
|
213
|
-
},
|
|
214
|
-
fail: (err) => {
|
|
215
|
-
console.error('选择图片失败:', err);
|
|
216
|
-
}
|
|
217
|
-
});
|
|
218
|
-
},
|
|
219
|
-
|
|
220
|
-
removeImage(e) {
|
|
221
|
-
let index = e.currentTarget.dataset.index;
|
|
222
|
-
let images = this.data.images;
|
|
223
|
-
images.splice(index, 1);
|
|
224
|
-
this.setData({
|
|
225
|
-
images
|
|
226
|
-
}, this.updateTextareaHeight);
|
|
227
|
-
},
|
|
228
|
-
|
|
229
|
-
toggleEmoji() {
|
|
230
|
-
// 如果要打开 emoji,需要先隐藏键盘(互斥),并拿到回调后再显示 emoji
|
|
231
|
-
if (!this.data.emojiVisible) {
|
|
232
|
-
// 打开 emoji:先隐藏键盘
|
|
233
|
-
try {
|
|
234
|
-
wx.hideKeyboard({
|
|
235
|
-
success: () => {
|
|
236
|
-
this.setData({
|
|
237
|
-
emojiVisible: true,
|
|
238
|
-
isKeyboardVisible: false,
|
|
239
|
-
keyboardHeight: 0
|
|
240
|
-
}, this.updateTextareaHeight);
|
|
241
|
-
},
|
|
242
|
-
fail: () => {
|
|
243
|
-
// 即便 hideKeyboard 失败,也打开 emoji
|
|
244
|
-
this.setData({
|
|
245
|
-
emojiVisible: true,
|
|
246
|
-
isKeyboardVisible: false,
|
|
247
|
-
keyboardHeight: 0
|
|
248
|
-
}, this.updateTextareaHeight);
|
|
249
|
-
}
|
|
250
|
-
});
|
|
251
|
-
} catch (e) {
|
|
252
|
-
this.setData({
|
|
253
|
-
emojiVisible: true,
|
|
254
|
-
isKeyboardVisible: false,
|
|
255
|
-
keyboardHeight: 0
|
|
256
|
-
}, this.updateTextareaHeight);
|
|
257
|
-
}
|
|
258
|
-
} else {
|
|
259
|
-
// 关闭 emoji(不打开键盘)
|
|
260
|
-
this.setData({
|
|
261
|
-
emojiVisible: false
|
|
262
|
-
}, this.updateTextareaHeight);
|
|
263
|
-
}
|
|
264
|
-
},
|
|
265
|
-
|
|
266
|
-
chooseGame() {
|
|
267
|
-
wx.navigateTo({
|
|
268
|
-
url: '../addGame/addGame',
|
|
269
|
-
})
|
|
270
|
-
},
|
|
271
|
-
|
|
272
|
-
selectEmoji(e) {
|
|
273
|
-
let index = e.currentTarget.dataset.index;
|
|
274
|
-
let emojiText = `[/` + (index + 1) + `]`;
|
|
275
|
-
|
|
276
|
-
// 延迟执行,确保 cursor 已经更新
|
|
277
|
-
setTimeout(() => {
|
|
278
|
-
const {
|
|
279
|
-
content,
|
|
280
|
-
cursor
|
|
281
|
-
} = this.data;
|
|
282
|
-
const newContent = content.slice(0, cursor) + emojiText + content.slice(cursor);
|
|
283
|
-
|
|
284
|
-
this.setData({
|
|
285
|
-
content: newContent,
|
|
286
|
-
cursor: cursor + emojiText.length // 光标移动到表情末尾
|
|
287
|
-
});
|
|
288
|
-
}, 100);
|
|
289
|
-
},
|
|
290
|
-
|
|
291
|
-
chooseTopic() {
|
|
292
|
-
// 打开主题页面前隐藏键盘,保持互斥逻辑
|
|
293
|
-
try {
|
|
294
|
-
wx.hideKeyboard();
|
|
295
|
-
} catch (e) {}
|
|
296
|
-
wx.navigateTo({
|
|
297
|
-
url: '../addSubject/addSubject',
|
|
298
|
-
});
|
|
299
|
-
},
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
toBase64(str) {
|
|
304
|
-
const chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';
|
|
305
|
-
let result = '';
|
|
306
|
-
let i = 0;
|
|
307
|
-
|
|
308
|
-
str = unescape(encodeURIComponent(str)); // 处理中文
|
|
309
|
-
|
|
310
|
-
while (i < str.length) {
|
|
311
|
-
const byte1 = str.charCodeAt(i++);
|
|
312
|
-
const byte2 = str.charCodeAt(i++);
|
|
313
|
-
const byte3 = str.charCodeAt(i++);
|
|
314
|
-
|
|
315
|
-
const enc1 = byte1 >> 2;
|
|
316
|
-
const enc2 = ((byte1 & 3) << 4) | (byte2 >> 4);
|
|
317
|
-
const enc3 = isNaN(byte2) ? 64 : (((byte2 & 15) << 2) | (byte3 >> 6));
|
|
318
|
-
const enc4 = isNaN(byte3) ? 64 : (byte3 & 63);
|
|
319
|
-
|
|
320
|
-
result += chars.charAt(enc1);
|
|
321
|
-
result += chars.charAt(enc2);
|
|
322
|
-
result += enc3 === 64 ? '=' : chars.charAt(enc3);
|
|
323
|
-
result += enc4 === 64 ? '=' : chars.charAt(enc4);
|
|
324
|
-
}
|
|
325
|
-
|
|
326
|
-
return result;
|
|
327
|
-
},
|
|
328
|
-
|
|
329
|
-
insertSelectedTopic() {
|
|
330
|
-
const topic = this.data.selectedTopic;
|
|
331
|
-
if (!topic || !topic.name) return;
|
|
332
|
-
|
|
333
|
-
const content = this.data.content;
|
|
334
|
-
const cursor = this.data.cursor || content.length;
|
|
335
|
-
const topicText = `#${topic.name}#`;
|
|
336
|
-
|
|
337
|
-
const newContent = content.slice(0, cursor) + topicText + content.slice(cursor);
|
|
338
|
-
|
|
339
|
-
this.setData({
|
|
340
|
-
content: newContent,
|
|
341
|
-
cursor: cursor + topicText.length,
|
|
342
|
-
selectedTopic: null
|
|
343
|
-
});
|
|
344
|
-
},
|
|
345
|
-
|
|
346
|
-
async submitPost() {
|
|
347
|
-
if (this.isSubmitting) return;
|
|
348
|
-
this.isSubmitting = true;
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
try {
|
|
352
|
-
const {
|
|
353
|
-
content,
|
|
354
|
-
images,
|
|
355
|
-
selectedGame
|
|
356
|
-
} = this.data;
|
|
357
|
-
|
|
358
|
-
if (!content && images.length === 0) {
|
|
359
|
-
return wx.showToast({
|
|
360
|
-
title: '请输入帖子内容',
|
|
361
|
-
icon: 'error'
|
|
362
|
-
});
|
|
363
|
-
}
|
|
364
|
-
|
|
365
|
-
// 敏感词检测
|
|
366
|
-
const hit = sensitive.detect(content)
|
|
367
|
-
if (hit) {
|
|
368
|
-
return wx.showToast({
|
|
369
|
-
title: `敏感词 ${sensitive.mask(hit)}`,
|
|
370
|
-
icon: 'none'
|
|
371
|
-
})
|
|
372
|
-
}
|
|
373
|
-
|
|
374
|
-
wx.showLoading({
|
|
375
|
-
title: '发布中...',
|
|
376
|
-
mask: true
|
|
377
|
-
});
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
let tokenId = null;
|
|
381
|
-
|
|
382
|
-
if (images.length > 0) {
|
|
383
|
-
tokenId = await this.uploadImagesToOSS(images);
|
|
384
|
-
console.log('上传成功:', tokenId);
|
|
385
|
-
}
|
|
386
|
-
|
|
387
|
-
await publishPostNew(this.toBase64(content), tokenId, false, selectedGame?.id).catch(err => {
|
|
388
|
-
this.isSubmitting = false;
|
|
389
|
-
});
|
|
390
|
-
wx.hideLoading();
|
|
391
|
-
|
|
392
|
-
setTimeout(() => {
|
|
393
|
-
wx.showToast({
|
|
394
|
-
title: '发布成功',
|
|
395
|
-
icon: 'success'
|
|
396
|
-
});
|
|
397
|
-
}, 200);
|
|
398
|
-
|
|
399
|
-
wx.navigateBack();
|
|
400
|
-
} catch (err) {
|
|
401
|
-
wx.hideLoading();
|
|
402
|
-
console.error("发布失败:", err);
|
|
403
|
-
wx.showToast({
|
|
404
|
-
title: '发布失败',
|
|
405
|
-
icon: 'none'
|
|
406
|
-
});
|
|
407
|
-
} finally {
|
|
408
|
-
this.isSubmitting = false;
|
|
409
|
-
}
|
|
410
|
-
},
|
|
411
|
-
|
|
412
|
-
async uploadImagesToOSS(images) {
|
|
413
|
-
try {
|
|
414
|
-
const tokenRes = await getUploadToken(images.map(() => 1), false);
|
|
415
|
-
const {
|
|
416
|
-
host,
|
|
417
|
-
list,
|
|
418
|
-
accessid,
|
|
419
|
-
id
|
|
420
|
-
} = tokenRes.data;
|
|
421
|
-
|
|
422
|
-
const uploadPromises = images.map((filePath, i) => {
|
|
423
|
-
const {
|
|
424
|
-
dir,
|
|
425
|
-
policy,
|
|
426
|
-
signature
|
|
427
|
-
} = list[i];
|
|
428
|
-
|
|
429
|
-
return new Promise((resolve, reject) => {
|
|
430
|
-
wx.uploadFile({
|
|
431
|
-
url: host,
|
|
432
|
-
filePath,
|
|
433
|
-
name: 'file',
|
|
434
|
-
formData: {
|
|
435
|
-
key: dir,
|
|
436
|
-
policy,
|
|
437
|
-
OSSAccessKeyId: accessid,
|
|
438
|
-
signature,
|
|
439
|
-
success_action_status: '200'
|
|
440
|
-
},
|
|
441
|
-
success(res) {
|
|
442
|
-
if (res.statusCode === 200) {
|
|
443
|
-
resolve();
|
|
444
|
-
} else {
|
|
445
|
-
reject(res);
|
|
446
|
-
}
|
|
447
|
-
},
|
|
448
|
-
fail(err) {
|
|
449
|
-
reject(err);
|
|
450
|
-
}
|
|
451
|
-
});
|
|
452
|
-
});
|
|
453
|
-
});
|
|
454
|
-
|
|
455
|
-
await Promise.all(uploadPromises);
|
|
456
|
-
return id;
|
|
457
|
-
} catch (err) {
|
|
458
|
-
console.error('上传失败', err);
|
|
459
|
-
wx.showToast({
|
|
460
|
-
title: '上传失败' + err,
|
|
461
|
-
})
|
|
462
|
-
throw err;
|
|
463
|
-
}
|
|
464
|
-
}
|
|
465
|
-
});
|
|
1
|
+
const _0x4e6608=_0x1944;(function(_0x364ac,_0x2397ae){const _0xe4450=_0x1944,_0x35cf0f=_0x364ac();while(!![]){try{const _0xf71d4d=-parseInt(_0xe4450(0x1aa))/0x1*(-parseInt(_0xe4450(0x1b5))/0x2)+parseInt(_0xe4450(0x156))/0x3*(parseInt(_0xe4450(0x187))/0x4)+parseInt(_0xe4450(0x182))/0x5*(parseInt(_0xe4450(0x142))/0x6)+-parseInt(_0xe4450(0x151))/0x7+-parseInt(_0xe4450(0x19e))/0x8+parseInt(_0xe4450(0x166))/0x9*(-parseInt(_0xe4450(0x155))/0xa)+-parseInt(_0xe4450(0x162))/0xb*(-parseInt(_0xe4450(0x1a8))/0xc);if(_0xf71d4d===_0x2397ae)break;else _0x35cf0f['push'](_0x35cf0f['shift']());}catch(_0x442943){_0x35cf0f['push'](_0x35cf0f['shift']());}}}(_0x2146,0xea43c));import{publishPostNew,getUploadToken}from'../../services/home';import _0x40777f from'../../utils/sensitive';function _0x1944(_0x5d78c3,_0x2aec84){_0x5d78c3=_0x5d78c3-0x135;const _0x2146b6=_0x2146();let _0x19446e=_0x2146b6[_0x5d78c3];if(_0x1944['bEOYZJ']===undefined){var _0x19f14d=function(_0x31d1a7){const _0x367694='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x47d6e2='',_0x220d35='';for(let _0x36aaf9=0x0,_0x5192b2,_0x151c69,_0x14065c=0x0;_0x151c69=_0x31d1a7['charAt'](_0x14065c++);~_0x151c69&&(_0x5192b2=_0x36aaf9%0x4?_0x5192b2*0x40+_0x151c69:_0x151c69,_0x36aaf9++%0x4)?_0x47d6e2+=String['fromCharCode'](0xff&_0x5192b2>>(-0x2*_0x36aaf9&0x6)):0x0){_0x151c69=_0x367694['indexOf'](_0x151c69);}for(let _0x5aab0f=0x0,_0x3f42ff=_0x47d6e2['length'];_0x5aab0f<_0x3f42ff;_0x5aab0f++){_0x220d35+='%'+('00'+_0x47d6e2['charCodeAt'](_0x5aab0f)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x220d35);};_0x1944['iHHIhW']=_0x19f14d,_0x1944['tkaOTL']={},_0x1944['bEOYZJ']=!![];}const _0x50a4c5=_0x2146b6[0x0],_0x668a2d=_0x5d78c3+_0x50a4c5,_0xd95f04=_0x1944['tkaOTL'][_0x668a2d];return!_0xd95f04?(_0x19446e=_0x1944['iHHIhW'](_0x19446e),_0x1944['tkaOTL'][_0x668a2d]=_0x19446e):_0x19446e=_0xd95f04,_0x19446e;}import{compressImages}from'../../utils/compressImage';function _0x2146(){const _0x1614be=['zMLSzq','ywXS','t25Oy3m','s1fVvwO','AgvJsuK','DxbKyxrLvgv4DgfYzwfizwLNAhq','ntm5mty1owfou2jQAq','yxH1Ave','lNbUzW','Aw1Hz2u','nde3mfLPtwjrsq','nJnnyLzTs3C','y3vYC29Y','tNDZz0C','AgLKzuTLEwjVyxjK','vM1rreK','zgf0yq','DvrwAKy','Aw1Hz2vZ','y2fSyYGXmdb2AcaTidi0mhjWEcK','BwfZAW','C1LJq3i','zxjYB3i','mZC5mZLnEMv1vuO','DMfSDwu','wwnTCNe','DgvTCezPBgvqyxrO','mJu4nZvdrLfcB1i','ChvZAa','5y6l57YP5zco5AsN5Bcp77YitulVViK6','AgLKzuXVywrPBMC','DxbSB2fKsw1Hz2vZvg9pu1m','ywLQu1q','zgv0ywLS','y2fSyYGXmdb2AcaTia','Aw5KzxG','BMfTzq','DK9gwLe','DuDJz3u','Dg9gAxHLza','C2XPy2u','z2fTzu5HBwu','BfzMqKK','zgv0zwn0','vgHLrei','CgfKu3rHCNq','q0DmvMW','z2fTzuLK','BwfW','B1bnDxq','zuH2txe','Bg9N','ChGP','6ycj5OUP5zU+54Mh5AsX6lsL77YA','AwPgCNu','nJqZmdvvtw5Pq1a','DgTjy0i','y3vYCMvUDfrHCMDLDa','u0PYru8','swXxtLC','mtG1mtqWu01tz1v3','6k+36l6t5ywL5BIw5A2q5yAf5A65','y2fSyYGXmdb2AcaTidG0mhjWEcK','lI4VywrKr2fTzs9Hzgrhyw1L','AMXbEKu','5lIk5lYG5AsX6lsL','BM9Uzq','Bhz2ufq','lI4VywrKu3vIAMvJDc9HzgrtDwjQzwn0','y2HHCKnVzgvbDa','rvjJz1y','t01OEfq','AgvPz2H0','5y6l57YP5zco5zU+54Mh6lEV5B6eoG','D3DTBxC','qLPpqM8','BKjkree','C2vSzwn0zwruB3bPyW','sLzWC24','Dg9W','qLLuEgq','yM90Dg9T','y2fSyYGXmdb2AcaTidqXmhjWEcK','mtuXmJy4mZjPr0zkEMK','z2v0v2LUzg93sw5MBW','yxLPt1q','wxrVAgm','C3bSAwnL','AxntDwjTAxr0Aw5N','Agzlz0G','y2f0y2G','v0jJCxG','CvjqB0O','mZuWnhjbDvbyza','y2fSyYGXmdb2AcaTidiZmhjWEcK','ntfADfLXv00','wuHdt0K','u2LbrM0','vwvyCeK','Dg9cyxnLnJq','BgvUz3rO','vu1yD1a','ywXIDw0','BMf2AwDHDgvuBW','zgf0yxnLDa','B2H4te0','ndK4ntHYswvrzxi','rKjXq3K','lI4Vzw1VAMKVC21PBgu','rgzyEMW','yxbfz3C','DgvTCezPBgvZ','DxbSB2fKrMLSzq','5Pwp5OsF6k+nia','Dg9tDhjPBMC','wKH6rfO','zNL2ruG','zK5ZsKG','tefYz0W','5y+r5BId5lITlI4U','y2fSyYGXmdb2AcaTidy2mhjWEcK','y29UDgvUDa','DePYvMu','C3rHDhvZq29Kzq','C2v0rgf0yq','5lIk5lYG5OIq5yQFoG','y2HHCKf0','BMf2AwDHDgvcywnR','nZmYsxvIwMDZ','C2L6zq','C2fMzujVDhrVBtO','z2v0rMLSzuLUzM8','C2fMzuHLAwDODdO','C2nYzwvUsgvPz2H0','C2HVD1rVyxn0','Ee5LCMq','u21cAeK'];_0x2146=function(){return _0x1614be;};return _0x2146();}Page({'data':{'content':'','images':[],'emojiVisible':![],'emojiList':[],'textareaHeight':_0x4e6608(0x1a9),'selectedTopic':null,'selectedGame':null,'cursor':0x0,'keyboardHeight':0x0,'isKeyboardVisible':![],'showGameOption':![]},'isSubmitting':![],'onLoad'(_0x3e9910){const _0x5d9ac7=_0x4e6608,_0x1f1949={'hfKgH':function(_0x48a346,_0x8c7eab){return _0x48a346(_0x8c7eab);},'OMhxT':function(_0x255eeb,_0x1381ab){return _0x255eeb&&_0x1381ab;},'KQoUj':function(_0x41df97,_0x20fe6a){return _0x41df97-_0x20fe6a;},'sYcCr':_0x5d9ac7(0x146),'qRPoJ':function(_0x40f8c9,_0x356ded){return _0x40f8c9<=_0x356ded;}},_0x5b7f42=_0x3e9910[_0x5d9ac7(0x17a)],_0x2756d8=_0x1f1949[_0x5d9ac7(0x1a4)](decodeURIComponent,_0x3e9910[_0x5d9ac7(0x174)]||'');_0x1f1949[_0x5d9ac7(0x192)](_0x5b7f42,_0x2756d8)&&this[_0x5d9ac7(0x13e)]({'gameId':_0x5b7f42,'selectedGame':{'id':_0x5b7f42,'name':_0x2756d8}});const _0x3b193f=wx[_0x5d9ac7(0x19f)](),_0x1aeb76=_0x3b193f['safeArea'],_0x1c2579=_0x1aeb76[_0x5d9ac7(0x193)],_0x5b98a8=_0x1aeb76[_0x5d9ac7(0x19a)],_0x22fadb=_0x1f1949[_0x5d9ac7(0x14e)](_0x3b193f[_0x5d9ac7(0x147)],_0x1aeb76[_0x5d9ac7(0x19c)]);console[_0x5d9ac7(0x17e)](_0x1f1949[_0x5d9ac7(0x160)],_0x1c2579),console[_0x5d9ac7(0x17e)](_0x5d9ac7(0x144),_0x22fadb),this[_0x5d9ac7(0x13e)]({'safeBottomHeight':_0x22fadb});let _0x15b7ca=[];for(let _0xf2a77c=0x1;_0x1f1949[_0x5d9ac7(0x1a7)](_0xf2a77c,0x2c);_0xf2a77c++){let _0x53c744=_0xf2a77c[_0x5d9ac7(0x1bd)]()[_0x5d9ac7(0x178)](0x3,'0');_0x15b7ca[_0x5d9ac7(0x167)](_0x5d9ac7(0x1b7)+_0x53c744+_0x5d9ac7(0x153));}this[_0x5d9ac7(0x13e)]({'emojiList':_0x15b7ca}),wx['onKeyboardHeightChange'](_0x226fcb=>{const _0x33bfc6=_0x5d9ac7,_0x5daa58=_0x226fcb[_0x33bfc6(0x193)]||0x0;_0x5daa58>0x0?this[_0x33bfc6(0x13e)]({'keyboardHeight':_0x5daa58,'isKeyboardVisible':!![],'emojiVisible':![]},this['updateTextareaHeight']):this[_0x33bfc6(0x13e)]({'keyboardHeight':0x0,'isKeyboardVisible':![]},this[_0x33bfc6(0x150)]);});},'onShow'(){this['insertSelectedTopic']();},'removeSelectedGame'(){const _0x3b8dfe=_0x4e6608;this[_0x3b8dfe(0x13e)]({'selectedGame':null});},'updateTextareaHeight'(){const _0x3297e7=_0x4e6608,_0x23eb65={'eHvMq':function(_0x4bc475,_0x58b3bf){return _0x4bc475>_0x58b3bf;},'tJrVe':function(_0x220964,_0x594c2a){return _0x220964+_0x594c2a;},'Ytohc':function(_0x496fde,_0x42bcd6){return _0x496fde>_0x42bcd6;},'BZOBo':_0x3297e7(0x189),'WBcqx':_0x3297e7(0x13a),'ijFru':function(_0x3f6d25,_0x2540fd){return _0x3f6d25>_0x2540fd;},'axuiQ':_0x3297e7(0x15e)},{emojiVisible:_0x168386,images:_0x14daea,keyboardHeight:_0x389268,isKeyboardVisible:_0x6ac5cf}=this['data'];if(_0x6ac5cf&&_0x23eb65[_0x3297e7(0x17d)](_0x389268,0x0)){const _0x159671=_0x23eb65[_0x3297e7(0x13c)](0xbe,0x28);let _0xa3e0e9;_0x23eb65[_0x3297e7(0x17d)](_0x14daea[_0x3297e7(0x1af)],0x0)?_0xa3e0e9=_0x3297e7(0x16d)+(_0x389268+_0x159671)+_0x3297e7(0x17f):_0xa3e0e9=_0x3297e7(0x16d)+_0x23eb65[_0x3297e7(0x13c)](_0x23eb65[_0x3297e7(0x13c)](_0x389268,0x5a),0x1e)+'px)';this[_0x3297e7(0x13e)]({'textareaHeight':_0xa3e0e9});return;}if(_0x168386&&_0x23eb65[_0x3297e7(0x1a1)](_0x14daea['length'],0x0))this['setData']({'textareaHeight':_0x23eb65[_0x3297e7(0x196)]});else{if(_0x168386)this['setData']({'textareaHeight':_0x23eb65[_0x3297e7(0x1a6)]});else _0x23eb65[_0x3297e7(0x181)](_0x14daea['length'],0x0)?this[_0x3297e7(0x13e)]({'textareaHeight':_0x3297e7(0x19d)}):this[_0x3297e7(0x13e)]({'textareaHeight':_0x23eb65[_0x3297e7(0x152)]});}},'onInput'(_0x5d2a1e){const _0xa6af14=_0x4e6608;this['setData']({'content':_0x5d2a1e[_0xa6af14(0x16c)][_0xa6af14(0x163)],'cursor':_0x5d2a1e['detail'][_0xa6af14(0x157)]});},'handleBlur'(_0x4f49ef){const _0x4f6fac=_0x4e6608;this['setData']({'cursor':_0x4f49ef[_0x4f6fac(0x16c)]['cursor']});},async 'chooseImage'(){const _0xce11f1=_0x4e6608,_0x489a94={'IlWNW':function(_0x615adb,_0x235ba7){return _0x615adb(_0x235ba7);},'RIrwG':_0xce11f1(0x194),'FkcXJ':_0xce11f1(0x168),'SmBhI':function(_0x12da10,_0x48008b){return _0x12da10/_0x48008b;},'Onhcs':_0xce11f1(0x180),'oPMut':function(_0x465853,_0x1619a2){return _0x465853-_0x1619a2;},'YHCOI':_0xce11f1(0x154),'nBJDA':_0xce11f1(0x1b1),'xNerd':'camera'};try{wx['hideKeyboard']();}catch(_0x339105){}wx['chooseMedia']({'count':_0x489a94[_0xce11f1(0x17c)](0x9,this['data']['images']['length']),'mediaType':[_0x489a94[_0xce11f1(0x1ab)]],'sourceType':[_0x489a94[_0xce11f1(0x197)],_0x489a94[_0xce11f1(0x149)]],'success':async _0x168790=>{const _0x58dc2c=_0xce11f1,_0x339d34=[];for(let _0x10adc8 of _0x168790[_0x58dc2c(0x1ba)]){const _0xb9c2e2=await _0x489a94[_0x58dc2c(0x186)](compressImages,_0x10adc8[_0x58dc2c(0x165)]),_0x44b682=await new Promise((_0x20937f,_0x53e5f8)=>{const _0x2dde38=_0x58dc2c;wx[_0x2dde38(0x145)]({'filePath':_0xb9c2e2,'success':_0x20937f,'fail':_0x53e5f8});});console['log'](_0x489a94['RIrwG'],_0xb9c2e2),console[_0x58dc2c(0x17e)]('压缩后大小(字节):',_0x44b682[_0x58dc2c(0x143)]),console['log'](_0x489a94['FkcXJ'],(_0x489a94[_0x58dc2c(0x14a)](_0x44b682[_0x58dc2c(0x143)],0x400)/0x400)[_0x58dc2c(0x172)](0x2)),_0x339d34[_0x58dc2c(0x167)](_0xb9c2e2);}const _0x11dbfa=this[_0x58dc2c(0x15b)][_0x58dc2c(0x15d)]['concat'](_0x339d34);this[_0x58dc2c(0x13e)]({'images':_0x11dbfa},this[_0x58dc2c(0x150)]);},'fail':_0x2afdbe=>{const _0x235d67=_0xce11f1;console[_0x235d67(0x161)](_0x489a94[_0x235d67(0x14d)],_0x2afdbe);}});},'removeImage'(_0x3d5b41){const _0x27c2b9=_0x4e6608;let _0x289e79=_0x3d5b41[_0x27c2b9(0x184)][_0x27c2b9(0x1b3)]['index'],_0xd0fa99=this['data'][_0x27c2b9(0x15d)];_0xd0fa99[_0x27c2b9(0x1a2)](_0x289e79,0x1),this[_0x27c2b9(0x13e)]({'images':_0xd0fa99},this['updateTextareaHeight']);},'toggleEmoji'(){const _0x36a7e0=_0x4e6608;if(!this[_0x36a7e0(0x15b)]['emojiVisible'])try{wx[_0x36a7e0(0x159)]({'success':()=>{const _0x9a4687=_0x36a7e0;this[_0x9a4687(0x13e)]({'emojiVisible':!![],'isKeyboardVisible':![],'keyboardHeight':0x0},this['updateTextareaHeight']);},'fail':()=>{const _0x2ba4e9=_0x36a7e0;this[_0x2ba4e9(0x13e)]({'emojiVisible':!![],'isKeyboardVisible':![],'keyboardHeight':0x0},this['updateTextareaHeight']);}});}catch(_0x16905c){this[_0x36a7e0(0x13e)]({'emojiVisible':!![],'isKeyboardVisible':![],'keyboardHeight':0x0},this['updateTextareaHeight']);}else this[_0x36a7e0(0x13e)]({'emojiVisible':![]},this[_0x36a7e0(0x150)]);},'chooseGame'(){const _0x2df100=_0x4e6608;wx[_0x2df100(0x1b2)]({'url':_0x2df100(0x18a)});},'selectEmoji'(_0x33cecf){const _0xf7794f=_0x4e6608,_0x99e5bb={'UeXpI':function(_0xd9a0c6,_0x3412fc){return _0xd9a0c6+_0x3412fc;},'jlAzE':function(_0x1b3ce2,_0x56734c){return _0x1b3ce2+_0x56734c;},'GqWSY':function(_0x352148,_0xe719f0){return _0x352148+_0xe719f0;}};let _0x4ae945=_0x33cecf[_0xf7794f(0x184)][_0xf7794f(0x1b3)][_0xf7794f(0x16e)],_0x38f8eb=_0x99e5bb['GqWSY']('[/',_0x4ae945+0x1)+']';setTimeout(()=>{const _0x27c738=_0xf7794f,{content:_0x51561a,cursor:_0x5bac6b}=this[_0x27c738(0x15b)],_0x491057=_0x99e5bb[_0x27c738(0x1ad)](_0x51561a['slice'](0x0,_0x5bac6b)+_0x38f8eb,_0x51561a['slice'](_0x5bac6b));this[_0x27c738(0x13e)]({'content':_0x491057,'cursor':_0x99e5bb[_0x27c738(0x18b)](_0x5bac6b,_0x38f8eb[_0x27c738(0x1af)])});},0x64);},'chooseTopic'(){const _0x6b05e2=_0x4e6608,_0x474e85={'NwsgG':_0x6b05e2(0x18f)};try{wx['hideKeyboard']();}catch(_0x4799de){}wx['navigateTo']({'url':_0x474e85[_0x6b05e2(0x158)]});},'toBase64'(_0x47d8fa){const _0x5926f5=_0x4e6608,_0x4b6312={'lVfBI':'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/','BYTxd':function(_0x5df19a,_0x382bc3){return _0x5df19a(_0x382bc3);},'SiAFm':function(_0x4c079b,_0x3c2e64){return _0x4c079b(_0x3c2e64);},'VmQDI':function(_0x45a92f,_0x3bc983){return _0x45a92f<_0x3bc983;},'uTVjF':function(_0xa581e,_0x534d09){return _0xa581e|_0x534d09;},'iXgpT':function(_0x579e78,_0x2da8b9){return _0x579e78<<_0x2da8b9;},'ZHzDZ':function(_0x5ac303,_0x3fcecf){return _0x5ac303&_0x3fcecf;},'CfuOE':function(_0xa7fa0c,_0x352f9b){return _0xa7fa0c(_0x352f9b);},'vOFZQ':function(_0x100e40,_0x332615){return _0x100e40|_0x332615;},'pMLvo':function(_0x103624,_0x2f14d8){return _0x103624<<_0x2f14d8;},'CGLVl':function(_0x42825e,_0x471629){return _0x42825e&_0x471629;},'lvvPT':function(_0x5604ba,_0x437e3e){return _0x5604ba(_0x437e3e);},'FBqCy':function(_0x10fddd,_0x4d329d){return _0x10fddd&_0x4d329d;},'ERcgV':function(_0x2bb4d0,_0x9bdcf6){return _0x2bb4d0===_0x9bdcf6;}},_0x3a4ab3=_0x4b6312[_0x5926f5(0x175)];let _0x20c368='',_0x199a64=0x0;_0x47d8fa=_0x4b6312[_0x5926f5(0x19b)](unescape,_0x4b6312[_0x5926f5(0x1ac)](encodeURIComponent,_0x47d8fa));while(_0x4b6312[_0x5926f5(0x15a)](_0x199a64,_0x47d8fa[_0x5926f5(0x1af)])){const _0x4b151d=_0x47d8fa[_0x5926f5(0x190)](_0x199a64++),_0x1f6e91=_0x47d8fa[_0x5926f5(0x190)](_0x199a64++),_0x4a24a9=_0x47d8fa[_0x5926f5(0x190)](_0x199a64++),_0x4e8d6a=_0x4b151d>>0x2,_0x23fb0e=_0x4b6312[_0x5926f5(0x15c)](_0x4b6312['iXgpT'](_0x4b6312[_0x5926f5(0x135)](_0x4b151d,0x3),0x4),_0x1f6e91>>0x4),_0x2b90b8=_0x4b6312['CfuOE'](isNaN,_0x1f6e91)?0x40:_0x4b6312[_0x5926f5(0x170)](_0x4b6312['pMLvo'](_0x4b6312[_0x5926f5(0x179)](_0x1f6e91,0xf),0x2),_0x4a24a9>>0x6),_0x4c8d81=_0x4b6312[_0x5926f5(0x18e)](isNaN,_0x4a24a9)?0x40:_0x4b6312[_0x5926f5(0x1b6)](_0x4a24a9,0x3f);_0x20c368+=_0x3a4ab3[_0x5926f5(0x140)](_0x4e8d6a),_0x20c368+=_0x3a4ab3[_0x5926f5(0x140)](_0x23fb0e),_0x20c368+=_0x4b6312[_0x5926f5(0x191)](_0x2b90b8,0x40)?'=':_0x3a4ab3['charAt'](_0x2b90b8),_0x20c368+=_0x4c8d81===0x40?'=':_0x3a4ab3['charAt'](_0x4c8d81);}return _0x20c368;},'insertSelectedTopic'(){const _0x1504bc=_0x4e6608,_0x18d290={'hecII':function(_0x4cd8c2,_0x28a1b8){return _0x4cd8c2+_0x28a1b8;},'fyvEH':function(_0x3b10b3,_0x44a8d4){return _0x3b10b3+_0x44a8d4;}},_0x86c66e=this[_0x1504bc(0x15b)][_0x1504bc(0x198)];if(!_0x86c66e||!_0x86c66e['name'])return;const _0x1771cf=this['data'][_0x1504bc(0x13b)],_0x33224d=this['data'][_0x1504bc(0x157)]||_0x1771cf['length'],_0x361466='#'+_0x86c66e[_0x1504bc(0x16f)]+'#',_0x3d4723=_0x18d290['hecII'](_0x18d290[_0x1504bc(0x14f)](_0x1771cf[_0x1504bc(0x173)](0x0,_0x33224d),_0x361466),_0x1771cf[_0x1504bc(0x173)](_0x33224d));this[_0x1504bc(0x13e)]({'content':_0x3d4723,'cursor':_0x18d290[_0x1504bc(0x136)](_0x33224d,_0x361466['length']),'selectedTopic':null});},async 'submitPost'(){const _0x3cac8d=_0x4e6608,_0x538265={'ayiOT':'发布成功','ZEHfD':'success','TheDB':function(_0x2c570a,_0xf0714d){return _0x2c570a===_0xf0714d;},'bhicf':_0x3cac8d(0x188),'SJrEO':_0x3cac8d(0x18d),'IhBJH':_0x3cac8d(0x139),'WQQIq':function(_0x1cc3b5,_0x1b22bb){return _0x1cc3b5>_0x1b22bb;},'uGcgu':_0x3cac8d(0x13f),'IQkSW':function(_0x114318,_0x28df12,_0x58e79c,_0x5f1d66,_0x9e077a){return _0x114318(_0x28df12,_0x58e79c,_0x5f1d66,_0x9e077a);},'apEgw':function(_0x489342,_0x1d8ec4,_0x2cb24e){return _0x489342(_0x1d8ec4,_0x2cb24e);},'JVpsn':'发布失败:','DfXzl':'发布失败'};if(this['isSubmitting'])return;this[_0x3cac8d(0x1a3)]=!![];try{const {content:_0x208be0,images:_0x381b48,selectedGame:_0x5d9947}=this['data'];if(!_0x208be0&&_0x538265[_0x3cac8d(0x177)](_0x381b48[_0x3cac8d(0x1af)],0x0))return wx[_0x3cac8d(0x148)]({'title':_0x538265['bhicf'],'icon':_0x3cac8d(0x161)});const _0x5ee6e7=_0x40777f[_0x3cac8d(0x176)](_0x208be0);if(_0x5ee6e7)return wx[_0x3cac8d(0x148)]({'title':_0x3cac8d(0x1bc)+_0x40777f[_0x3cac8d(0x15f)](_0x5ee6e7),'icon':_0x538265[_0x3cac8d(0x185)]});wx['showLoading']({'title':_0x538265['IhBJH'],'mask':!![]});let _0x38cae9=null;_0x538265['WQQIq'](_0x381b48[_0x3cac8d(0x1af)],0x0)&&(_0x38cae9=await this[_0x3cac8d(0x16a)](_0x381b48),console['log'](_0x538265[_0x3cac8d(0x171)],_0x38cae9)),await _0x538265['IQkSW'](publishPostNew,this[_0x3cac8d(0x1ae)](_0x208be0),_0x38cae9,![],_0x5d9947?.['id'])[_0x3cac8d(0x1a5)](_0x4c8f4e=>{this['isSubmitting']=![];}),wx[_0x3cac8d(0x169)](),_0x538265[_0x3cac8d(0x1b9)](setTimeout,()=>{const _0x3b1a09=_0x3cac8d;wx[_0x3b1a09(0x148)]({'title':_0x538265[_0x3b1a09(0x1a0)],'icon':_0x538265['ZEHfD']});},0xc8),wx[_0x3cac8d(0x141)]();}catch(_0x39f4e6){wx[_0x3cac8d(0x169)](),console[_0x3cac8d(0x161)](_0x538265[_0x3cac8d(0x199)],_0x39f4e6),wx[_0x3cac8d(0x148)]({'title':_0x538265[_0x3cac8d(0x1b8)],'icon':_0x538265[_0x3cac8d(0x185)]});}finally{this[_0x3cac8d(0x1a3)]=![];}},async 'uploadImagesToOSS'(_0x4ab7a0){const _0x2c5fac=_0x4e6608,_0x5bf312={'MpXog':function(_0x346ae5,_0x121cab){return _0x346ae5(_0x121cab);},'tkIcB':function(_0x354db5,_0x48e4f0){return _0x354db5(_0x48e4f0);},'ohxLM':_0x2c5fac(0x14b),'aijST':'200','wwmmw':function(_0x311b7a,_0x9340c3,_0x374b63){return _0x311b7a(_0x9340c3,_0x374b63);},'LArgL':_0x2c5fac(0x18c),'UMXwP':function(_0x4f9568,_0x5047b8){return _0x4f9568+_0x5047b8;}};try{const _0x133b45=await _0x5bf312[_0x2c5fac(0x195)](getUploadToken,_0x4ab7a0[_0x2c5fac(0x17b)](()=>0x1),![]),{host:_0x4caca2,list:_0x29aa4c,accessid:_0x56cfaa,id:_0x457a89}=_0x133b45[_0x2c5fac(0x15b)],_0x2ac253=_0x4ab7a0[_0x2c5fac(0x17b)]((_0x4627fc,_0x49fd17)=>{const {dir:_0xa6af3,policy:_0x5ed69b,signature:_0x324c0d}=_0x29aa4c[_0x49fd17];return new Promise((_0x26fbec,_0x2032d2)=>{const _0x124a29=_0x1944,_0x5ab441={'Ycmrq':function(_0xbc888e,_0x16016a){return _0x5bf312['MpXog'](_0xbc888e,_0x16016a);},'fNsJH':function(_0xfb7921,_0x7075ca){const _0x4f7b59=_0x1944;return _0x5bf312[_0x4f7b59(0x183)](_0xfb7921,_0x7075ca);}};wx[_0x124a29(0x1bb)]({'url':_0x4caca2,'filePath':_0x4627fc,'name':_0x5bf312[_0x124a29(0x1b4)],'formData':{'key':_0xa6af3,'policy':_0x5ed69b,'OSSAccessKeyId':_0x56cfaa,'signature':_0x324c0d,'success_action_status':_0x5bf312[_0x124a29(0x16b)]},'success'(_0x79672a){const _0x22ae28=_0x124a29;_0x79672a[_0x22ae28(0x13d)]===0xc8?_0x26fbec():_0x5ab441[_0x22ae28(0x164)](_0x2032d2,_0x79672a);},'fail'(_0x53f729){const _0x59b3d6=_0x124a29;_0x5ab441[_0x59b3d6(0x137)](_0x2032d2,_0x53f729);}});});});return await Promise[_0x2c5fac(0x14c)](_0x2ac253),_0x457a89;}catch(_0x2bc1cb){console[_0x2c5fac(0x161)](_0x5bf312[_0x2c5fac(0x138)],_0x2bc1cb),wx[_0x2c5fac(0x148)]({'title':_0x5bf312[_0x2c5fac(0x1b0)](_0x2c5fac(0x18c),_0x2bc1cb)});throw _0x2bc1cb;}}});
|