southnote-sdk 1.0.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.
- package/app.js +1 -0
- package/app.json +55 -0
- package/app.wxss +15 -0
- package/assets/file/badwords-compressed.js +1 -0
- package/assets/file/rules.js +1 -0
- package/assets/images/icons/age1.png +0 -0
- package/assets/images/icons/age2.png +0 -0
- package/assets/images/icons/age3.png +0 -0
- package/assets/images/icons/attachment.png +0 -0
- package/assets/images/icons/clear.png +0 -0
- package/assets/images/icons/edit_input.png +0 -0
- package/assets/images/icons/header_placeholder.png +0 -0
- package/assets/images/icons/home_collect.png +0 -0
- package/assets/images/icons/home_collected.png +0 -0
- package/assets/images/icons/home_comment.png +0 -0
- package/assets/images/icons/home_like.png +0 -0
- package/assets/images/icons/home_liked.png +0 -0
- package/assets/images/icons/home_message.png +0 -0
- package/assets/images/icons/home_share.png +0 -0
- package/assets/images/icons/icon_more.png +0 -0
- package/assets/images/icons/input_game.png +0 -0
- package/assets/images/icons/logo.png +0 -0
- package/assets/images/icons/lv1.png +0 -0
- package/assets/images/icons/lv2.png +0 -0
- package/assets/images/icons/lv3.png +0 -0
- package/assets/images/icons/lv4.png +0 -0
- package/assets/images/icons/search.png +0 -0
- package/assets/images/icons/sex1.png +0 -0
- package/assets/images/icons/sex2.png +0 -0
- package/assets/images/icons/sign_empty.png +0 -0
- package/assets/images/icons/sign_login.png +0 -0
- package/assets/wheel/wheel_bg.png +0 -0
- package/assets/wheel/wheel_bg2.png +0 -0
- package/assets/wheel/wheel_fore.png +0 -0
- package/assets/wheel/wheel_to.png +0 -0
- package/components/bottomSheet/bottomSheet.js +1 -0
- package/components/bottomSheet/bottomSheet.json +5 -0
- package/components/bottomSheet/bottomSheet.wxml +73 -0
- package/components/bottomSheet/bottomSheet.wxss +238 -0
- package/components/experience-item/experience-item.js +1 -0
- package/components/experience-item/experience-item.json +4 -0
- package/components/experience-item/experience-item.wxml +39 -0
- package/components/experience-item/experience-item.wxss +110 -0
- package/components/grid-item/grid-item.js +1 -0
- package/components/grid-item/grid-item.json +4 -0
- package/components/grid-item/grid-item.wxml +62 -0
- package/components/grid-item/grid-item.wxss +191 -0
- package/components/post-item/post-item.js +1 -0
- package/components/post-item/post-item.json +4 -0
- package/components/post-item/post-item.wxml +423 -0
- package/components/post-item/post-item.wxss +525 -0
- package/components/wiki-renderer/wiki-renderer.js +1 -0
- package/components/wiki-renderer/wiki-renderer.json +12 -0
- package/components/wiki-renderer/wiki-renderer.wxml +150 -0
- package/components/wiki-renderer/wiki-renderer.wxss +412 -0
- package/components/wiki-tabs/wiki-tabs.js +1 -0
- package/components/wiki-tabs/wiki-tabs.json +3 -0
- package/components/wiki-tabs/wiki-tabs.wxml +28 -0
- package/components/wiki-tabs/wiki-tabs.wxss +43 -0
- package/index.js +1 -0
- package/package.json +22 -0
- package/pages/addGame/addGame.js +1 -0
- package/pages/addGame/addGame.json +6 -0
- package/pages/addGame/addGame.wxml +71 -0
- package/pages/addGame/addGame.wxss +110 -0
- package/pages/addSubject/addSubject.js +1 -0
- package/pages/addSubject/addSubject.json +7 -0
- package/pages/addSubject/addSubject.wxml +78 -0
- package/pages/addSubject/addSubject.wxss +85 -0
- package/pages/commonLogin/commonLogin.js +1 -0
- package/pages/commonLogin/commonLogin.json +7 -0
- package/pages/commonLogin/commonLogin.wxml +57 -0
- package/pages/commonLogin/commonLogin.wxss +177 -0
- package/pages/copyOfficial/copyOfficial.js +1 -0
- package/pages/copyOfficial/copyOfficial.json +3 -0
- package/pages/copyOfficial/copyOfficial.wxml +22 -0
- package/pages/copyOfficial/copyOfficial.wxss +49 -0
- package/pages/demo/demo.js +1 -0
- package/pages/demo/demo.wxml +2 -0
- package/pages/emoji/smile001.png +0 -0
- package/pages/emoji/smile002.png +0 -0
- package/pages/emoji/smile003.png +0 -0
- package/pages/emoji/smile004.png +0 -0
- package/pages/emoji/smile005.png +0 -0
- package/pages/emoji/smile006.png +0 -0
- package/pages/emoji/smile007.png +0 -0
- package/pages/emoji/smile008.png +0 -0
- package/pages/emoji/smile009.png +0 -0
- package/pages/emoji/smile010.png +0 -0
- package/pages/emoji/smile011.png +0 -0
- package/pages/emoji/smile012.png +0 -0
- package/pages/emoji/smile013.png +0 -0
- package/pages/emoji/smile014.png +0 -0
- package/pages/emoji/smile015.png +0 -0
- package/pages/emoji/smile016.png +0 -0
- package/pages/emoji/smile017.png +0 -0
- package/pages/emoji/smile018.png +0 -0
- package/pages/emoji/smile019.png +0 -0
- package/pages/emoji/smile020.png +0 -0
- package/pages/emoji/smile021.png +0 -0
- package/pages/emoji/smile022.png +0 -0
- package/pages/emoji/smile023.png +0 -0
- package/pages/emoji/smile024.png +0 -0
- package/pages/emoji/smile025.png +0 -0
- package/pages/emoji/smile026.png +0 -0
- package/pages/emoji/smile027.png +0 -0
- package/pages/emoji/smile028.png +0 -0
- package/pages/emoji/smile029.png +0 -0
- package/pages/emoji/smile030.png +0 -0
- package/pages/emoji/smile031.png +0 -0
- package/pages/emoji/smile032.png +0 -0
- package/pages/emoji/smile033.png +0 -0
- package/pages/emoji/smile034.png +0 -0
- package/pages/emoji/smile035.png +0 -0
- package/pages/emoji/smile036.png +0 -0
- package/pages/emoji/smile037.png +0 -0
- package/pages/emoji/smile038.png +0 -0
- package/pages/emoji/smile039.png +0 -0
- package/pages/emoji/smile040.png +0 -0
- package/pages/emoji/smile041.png +0 -0
- package/pages/emoji/smile042.png +0 -0
- package/pages/emoji/smile043.png +0 -0
- package/pages/emoji/smile044.png +0 -0
- package/pages/emoji/smile045.png +0 -0
- package/pages/emoji/smile046.png +0 -0
- package/pages/emoji/smile047.png +0 -0
- package/pages/emoji/smile048.png +0 -0
- package/pages/emoji/smile049.png +0 -0
- package/pages/emoji/smile050.png +0 -0
- package/pages/emoji/smile051.png +0 -0
- package/pages/emoji/smile052.png +0 -0
- package/pages/game/game.js +1 -0
- package/pages/game/game.json +12 -0
- package/pages/game/game.wxml +350 -0
- package/pages/game/game.wxss +672 -0
- package/pages/lottery-winners/lottery-winners.js +1 -0
- package/pages/lottery-winners/lottery-winners.json +4 -0
- package/pages/lottery-winners/lottery-winners.wxml +53 -0
- package/pages/lottery-winners/lottery-winners.wxss +127 -0
- package/pages/officialWebview/officialWebview.js +1 -0
- package/pages/officialWebview/officialWebview.json +3 -0
- package/pages/officialWebview/officialWebview.wxml +2 -0
- package/pages/officialWebview/officialWebview.wxss +1 -0
- package/pages/post/post.js +1 -0
- package/pages/post/post.json +8 -0
- package/pages/post/post.wxml +686 -0
- package/pages/post/post.wxss +1003 -0
- package/pages/post-editor/post-editor.js +1 -0
- package/pages/post-editor/post-editor.json +6 -0
- package/pages/post-editor/post-editor.wxml +63 -0
- package/pages/post-editor/post-editor.wxss +195 -0
- package/pages/postDialog/postDialog.js +1 -0
- package/pages/postDialog/postDialog.json +6 -0
- package/pages/postDialog/postDialog.wxml +377 -0
- package/pages/postDialog/postDialog.wxss +979 -0
- package/pages/report-category/reporst-category.js +1 -0
- package/pages/report-category/reporst-category.json +3 -0
- package/pages/report-category/reporst-category.wxml +2 -0
- package/pages/report-category/reporst-category.wxss +1 -0
- package/pages/report-category/report-category.js +1 -0
- package/pages/report-category/report-category.json +4 -0
- package/pages/report-category/report-category.wxml +14 -0
- package/pages/report-category/report-category.wxss +43 -0
- package/pages/report-form/report-form.js +1 -0
- package/pages/report-form/report-form.json +3 -0
- package/pages/report-form/report-form.wxml +11 -0
- package/pages/report-form/report-form.wxss +44 -0
- package/pages/sevenDaySignDetail/sevenDaySignDetail.js +1 -0
- package/pages/sevenDaySignDetail/sevenDaySignDetail.json +3 -0
- package/pages/sevenDaySignDetail/sevenDaySignDetail.wxml +82 -0
- package/pages/sevenDaySignDetail/sevenDaySignDetail.wxss +173 -0
- package/pages/topic/topic.js +1 -0
- package/pages/topic/topic.json +6 -0
- package/pages/topic/topic.wxml +77 -0
- package/pages/topic/topic.wxss +162 -0
- package/pages/webview/webview.js +1 -0
- package/pages/webview/webview.json +3 -0
- package/pages/webview/webview.wxml +22 -0
- package/pages/webview/webview.wxss +50 -0
- package/pages/wheelActivivty/wheelActivivty.js +1 -0
- package/pages/wheelActivivty/wheelActivivty.json +8 -0
- package/pages/wheelActivivty/wheelActivivty.wxml +131 -0
- package/pages/wheelActivivty/wheelActivivty.wxss +459 -0
- package/pages/wiki/wiki.js +1 -0
- package/pages/wiki/wiki.json +6 -0
- package/pages/wiki/wiki.wxml +20 -0
- package/pages/wiki/wiki.wxss +44 -0
- package/request/JKRequest.js +1 -0
- package/services/home.js +1 -0
- package/towxml/config.js +291 -0
- package/towxml/decode.js +35 -0
- package/towxml/decode.json +11 -0
- package/towxml/decode.wxml +137 -0
- package/towxml/decode.wxss +0 -0
- package/towxml/img/img.js +98 -0
- package/towxml/img/img.json +3 -0
- package/towxml/img/img.wxml +1 -0
- package/towxml/img/img.wxss +0 -0
- package/towxml/index.js +19 -0
- package/towxml/latex/latex.js +53 -0
- package/towxml/latex/latex.json +5 -0
- package/towxml/latex/latex.wxml +1 -0
- package/towxml/latex/latex.wxss +0 -0
- package/towxml/parse/highlight/highlight.js +1 -0
- package/towxml/parse/highlight/index.js +8 -0
- package/towxml/parse/highlight/languages/bash.js +111 -0
- package/towxml/parse/highlight/languages/c-like.js +236 -0
- package/towxml/parse/highlight/languages/c.js +22 -0
- package/towxml/parse/highlight/languages/css.js +132 -0
- package/towxml/parse/highlight/languages/dart.js +134 -0
- package/towxml/parse/highlight/languages/go.js +63 -0
- package/towxml/parse/highlight/languages/htmlbars.js +80 -0
- package/towxml/parse/highlight/languages/java.js +125 -0
- package/towxml/parse/highlight/languages/javascript.js +265 -0
- package/towxml/parse/highlight/languages/json.js +52 -0
- package/towxml/parse/highlight/languages/less.js +148 -0
- package/towxml/parse/highlight/languages/nginx.js +101 -0
- package/towxml/parse/highlight/languages/php.js +161 -0
- package/towxml/parse/highlight/languages/python-repl.js +29 -0
- package/towxml/parse/highlight/languages/python.js +131 -0
- package/towxml/parse/highlight/languages/scss.js +122 -0
- package/towxml/parse/highlight/languages/shell.js +22 -0
- package/towxml/parse/highlight/languages/typescript.js +215 -0
- package/towxml/parse/highlight/languages/xml.js +139 -0
- package/towxml/parse/highlight/style/github.wxss +99 -0
- package/towxml/parse/highlight/style/monokai.wxss +70 -0
- package/towxml/parse/index.js +118 -0
- package/towxml/parse/markdown/index.js +67 -0
- package/towxml/parse/markdown/markdown.js +4 -0
- package/towxml/parse/markdown/plugins/echarts.js +11 -0
- package/towxml/parse/markdown/plugins/emoji.js +2 -0
- package/towxml/parse/markdown/plugins/ins.js +1 -0
- package/towxml/parse/markdown/plugins/latex.js +158 -0
- package/towxml/parse/markdown/plugins/mark.js +1 -0
- package/towxml/parse/markdown/plugins/sub.js +1 -0
- package/towxml/parse/markdown/plugins/sup.js +1 -0
- package/towxml/parse/markdown/plugins/todo.js +147 -0
- package/towxml/parse/markdown/plugins/yuml.js +20 -0
- package/towxml/parse/parse2/Parser.js +492 -0
- package/towxml/parse/parse2/Tokenizer.js +903 -0
- package/towxml/parse/parse2/domelementtype/index.js +55 -0
- package/towxml/parse/parse2/domhandler/index.js +145 -0
- package/towxml/parse/parse2/domhandler/node.js +474 -0
- package/towxml/parse/parse2/entities/decode.js +179 -0
- package/towxml/parse/parse2/entities/decode_codepoint.js +60 -0
- package/towxml/parse/parse2/entities/encode.js +77 -0
- package/towxml/parse/parse2/entities/escape.js +112 -0
- package/towxml/parse/parse2/entities/generated/decode-data-html.js +9 -0
- package/towxml/parse/parse2/entities/generated/decode-data-xml.js +9 -0
- package/towxml/parse/parse2/entities/generated/encode-html.js +12 -0
- package/towxml/parse/parse2/entities/index.js +137 -0
- package/towxml/parse/parse2/index.js +8 -0
- package/towxml/style/main.wxss +419 -0
- package/towxml/style/theme/dark.wxss +73 -0
- package/towxml/style/theme/light.wxss +63 -0
- package/towxml/table/table.js +11 -0
- package/towxml/table/table.json +6 -0
- package/towxml/table/table.wxml +24 -0
- package/towxml/table/table.wxss +0 -0
- package/towxml/todogroup/todogroup.js +20 -0
- package/towxml/todogroup/todogroup.json +6 -0
- package/towxml/todogroup/todogroup.wxml +12 -0
- package/towxml/todogroup/todogroup.wxss +3 -0
- package/towxml/towxml.js +22 -0
- package/towxml/towxml.json +6 -0
- package/towxml/towxml.wxml +5 -0
- package/towxml/towxml.wxss +8 -0
- package/towxml/yuml/yuml.js +51 -0
- package/towxml/yuml/yuml.json +5 -0
- package/towxml/yuml/yuml.wxml +5 -0
- package/towxml/yuml/yuml.wxss +0 -0
- package/utils/aes.js +1 -0
- package/utils/auth.js +1 -0
- package/utils/base64.js +1 -0
- package/utils/compressImage.js +1 -0
- package/utils/exp.js +1 -0
- package/utils/formatPost.js +1 -0
- package/utils/parseContent.js +1 -0
- package/utils/query-select.js +1 -0
- package/utils/sensitive.js +1 -0
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
<view class="wiki-root">
|
|
2
|
+
<block wx:for="{{parsedBlocks}}" wx:key="index" wx:for-index="index">
|
|
3
|
+
|
|
4
|
+
<!-- Banner -->
|
|
5
|
+
<swiper circular wx:if="{{item.type === 'banner'}}" class="banner-swipe" autoplay="true" interval="3000" indicator-dots="true" indicator-color="white" style="aspect-ratio: {{item.ratio}}">
|
|
6
|
+
<swiper-item wx:for="{{item.children}}" wx:key="id" wx:for-item="bannerItem">
|
|
7
|
+
<image src="{{bannerItem.image.url}}" mode="aspectFill" class="banner-img" />
|
|
8
|
+
</swiper-item>
|
|
9
|
+
</swiper>
|
|
10
|
+
|
|
11
|
+
<!-- 文本 -->
|
|
12
|
+
<view wx:if="{{item.type === 'text'}}" class="wiki-text">{{item.desc}}</view>
|
|
13
|
+
|
|
14
|
+
<!-- 富文本 / 表格:用 towxml 渲染 -->
|
|
15
|
+
<view wx:if="{{item.type === 'richText' || item.type === 'table'}}" class="wiki-richtext" catch:tap="onRichTextTap" data-index="{{index}}">
|
|
16
|
+
<towxml nodes="{{item.towxmlNodes}}" bind:linktap="onTowxmlLinkTap" />
|
|
17
|
+
</view>
|
|
18
|
+
|
|
19
|
+
<!-- 图片 -->
|
|
20
|
+
<view wx:if="{{item.type === 'image'}}" class="image-block" style="aspect-ratio: {{item.ratio}}">
|
|
21
|
+
<image wx:if="{{item.visible}}" src="{{item.url}}" mode="aspectFill" class="block-img" bindtap="onImageTap" data-jump="{{item.jump}}" />
|
|
22
|
+
</view>
|
|
23
|
+
|
|
24
|
+
<!-- 评分 type=6 -->
|
|
25
|
+
|
|
26
|
+
<view wx:if="{{item.type === 'score'}}" class="score-block">
|
|
27
|
+
<view class="score-header">
|
|
28
|
+
<text class="score-title">{{item.title}}</text>
|
|
29
|
+
<view class="score-edit-btn" bindtap="onOpenScoreModal" data-index="{{index}}">
|
|
30
|
+
<van-icon name="edit" size="22px" />
|
|
31
|
+
</view>
|
|
32
|
+
</view>
|
|
33
|
+
|
|
34
|
+
<view class="container-divider"></view>
|
|
35
|
+
|
|
36
|
+
<view class="score-body">
|
|
37
|
+
<van-rate value="{{item.averageScore}}" allow-half readonly color="#f5a623" void-color="#e0e0e0" size="32px" />
|
|
38
|
+
<view class="score-right">
|
|
39
|
+
<text class="score-avg">{{item.averageScore}}</text>
|
|
40
|
+
<text class="score-count">{{item.voteCount}} 评分</text>
|
|
41
|
+
</view>
|
|
42
|
+
</view>
|
|
43
|
+
</view>
|
|
44
|
+
|
|
45
|
+
<!-- 评分弹窗 -->
|
|
46
|
+
|
|
47
|
+
<view wx:if="{{scoreModal.visible}}" class="score-modal-mask" catchtap="onCloseScoreModal">
|
|
48
|
+
<view class="score-modal" catchtap="stopPropagation">
|
|
49
|
+
<text class="score-modal-title">{{scoreModal.title}}</text>
|
|
50
|
+
<van-rate value="{{scoreModal.selected}}" allow-half color="#f5a623" void-color="#e0e0e0" size="40px" bind:change="onSelectStar" />
|
|
51
|
+
<view class="score-modal-btns">
|
|
52
|
+
<view class="score-modal-cancel" bindtap="onCloseScoreModal">取消</view>
|
|
53
|
+
<view class="score-modal-confirm {{scoreModal.selected > 0 ? '' : 'disabled'}}" bindtap="onSubmitScore">确认</view>
|
|
54
|
+
</view>
|
|
55
|
+
</view>
|
|
56
|
+
</view>
|
|
57
|
+
|
|
58
|
+
<!-- Grid 菜单 -->
|
|
59
|
+
<view wx:if="{{item.type === 'grid' && item.title}}" class="menu-title" style="background-color: {{item.color}}; color: {{item.titleTextColor}}">{{item.title}}</view>
|
|
60
|
+
<view wx:if="{{item.type === 'grid'}}" class="menu-tabs">
|
|
61
|
+
|
|
62
|
+
<view class="grid" style="grid-template-columns: repeat({{item.count}}, 1fr)">
|
|
63
|
+
<view wx:for="{{item.children}}" wx:key="index" wx:for-index="gi" wx:for-item="gitem" class="grid-item" bindtap="onJump" data-jump="{{gitem.jump}}">
|
|
64
|
+
<grid-item data="{{gitem}}" />
|
|
65
|
+
</view>
|
|
66
|
+
</view>
|
|
67
|
+
</view>
|
|
68
|
+
|
|
69
|
+
<!-- Tabs(图标网格型) -->
|
|
70
|
+
<view wx:if="{{item.type === 'tabs' && item.title}}" class="menu-title" style="background-color: {{item.color}}; color: {{item.titleTextColor}}">{{item.title}}</view>
|
|
71
|
+
<wiki-tabs wx:if="{{item.type === 'tabs'}}" tabs="{{item.tabs}}" color="{{'#002fa7'}}" active="{{tabActiveMap[index]}}" bind:change="onVanTabChange" data-block-index="{{index}}" data-tab-type="tabs">
|
|
72
|
+
<view wx:for="{{item.tabs}}" wx:key="name" wx:for-item="tab" slot="{{tab.name}}">
|
|
73
|
+
<view class="grid" style="grid-template-columns: repeat({{item.count}}, 1fr)">
|
|
74
|
+
<view wx:for="{{tab.children}}" wx:key="index" wx:for-item="gitem" wx:for-index="gi" class="grid-item" bindtap="onJump" data-jump="{{gitem.jump}}">
|
|
75
|
+
<grid-item data="{{gitem}}" />
|
|
76
|
+
</view>
|
|
77
|
+
</view>
|
|
78
|
+
</view>
|
|
79
|
+
</wiki-tabs>
|
|
80
|
+
|
|
81
|
+
<!-- 内容型 Tabs(递归子块) -->
|
|
82
|
+
<view wx:if="{{item.type === 'content-tabs' && item.title}}" class="menu-title" style="background-color: {{item.color}}; color: {{item.titleTextColor}}">{{item.title}}</view>
|
|
83
|
+
<wiki-tabs wx:if="{{item.type === 'content-tabs'}}" tabs="{{item.tabs}}" color="{{'#002fa7'}}" active="{{tabActiveMap[index]}}" bind:change="onVanTabChange" data-block-index="{{index}}" data-tab-type="content-tabs">
|
|
84
|
+
<view wx:for="{{item.tabs}}" wx:key="name" wx:for-item="tab" slot="{{tab.name}}">
|
|
85
|
+
<wiki-renderer images="{{images}}" data="{{tab.children}}" game-id="{{gameId}}" wiki-users="{{wikiUsers}}" />
|
|
86
|
+
</view>
|
|
87
|
+
</wiki-tabs>
|
|
88
|
+
|
|
89
|
+
<!-- 筛选 Tabs -->
|
|
90
|
+
<view wx:if="{{item.type === 'filter-tabs' && item.title}}" class="menu-title" style="background-color: {{item.color}}; color: {{item.titleTextColor}}">{{item.title}}</view>
|
|
91
|
+
<view wx:if="{{item.type === 'filter-tabs'}}" class="menu-tabs">
|
|
92
|
+
<view class="filter-classes">
|
|
93
|
+
<view wx:for="{{item.classes}}" wx:key="index" wx:for-index="ci" wx:for-item="cls" class="filter-class">
|
|
94
|
+
<view wx:for="{{cls.allKeys}}" wx:key="index" wx:for-item="key" class="filter-btn {{filterMap[ci] === key || (!filterMap[ci] && key === '不限') ? 'active' : ''}}" bindtap="onFilterChange" data-ci="{{ci}}" data-key="{{key}}">{{key}}</view>
|
|
95
|
+
</view>
|
|
96
|
+
</view>
|
|
97
|
+
<view class="grid" style="grid-template-columns: repeat({{item.count}}, 1fr)">
|
|
98
|
+
<view wx:for="{{item.filteredChildren}}" wx:key="index" wx:for-item="gitem" wx:for-index="fi" class="grid-item" bindtap="onJump" data-jump="{{gitem.jump}}">
|
|
99
|
+
<grid-item data="{{gitem}}" />
|
|
100
|
+
</view>
|
|
101
|
+
</view>
|
|
102
|
+
</view>
|
|
103
|
+
|
|
104
|
+
<!-- 攻略组成员 -->
|
|
105
|
+
<view wx:if="{{item.type === 'info'}}" class="info">
|
|
106
|
+
<view wx:if="{{item.title}}" class="menu-title" style="background-color: {{item.color}}">{{item.title}}</view>
|
|
107
|
+
<view style="font-size: 14px; line-height: 1.7; margin-top: 10px">{{item.info}}</view>
|
|
108
|
+
<view class="info-users">
|
|
109
|
+
<view wx:for="{{wikiUsers}}" wx:key="nickname" wx:for-item="user" class="user-item">
|
|
110
|
+
<image src="{{user.avatar}}" class="user-avatar" />
|
|
111
|
+
<text class="user-name">{{user.nickname}}</text>
|
|
112
|
+
</view>
|
|
113
|
+
</view>
|
|
114
|
+
</view>
|
|
115
|
+
|
|
116
|
+
<!-- 折叠容器 -->
|
|
117
|
+
<view wx:if="{{item.type === 'container' && item.key === 'collapse'}}" class="wiki-container">
|
|
118
|
+
<view class="collapse-title" style="background-color: {{item.color}}; color: {{item.titleTextColor}}" bindtap="onToggleCollapse" data-index="{{index}}">
|
|
119
|
+
<text>{{item.title}}</text>
|
|
120
|
+
<text class="collapse-arrow {{collapseActive[index] ? 'open' : ''}}">▾</text>
|
|
121
|
+
</view>
|
|
122
|
+
<view wx:if="{{collapseActive[index]}}">
|
|
123
|
+
<wiki-renderer images="{{images}}" data="{{item.children}}" game-id="{{gameId}}" wiki-users="{{wikiUsers}}" />
|
|
124
|
+
</view>
|
|
125
|
+
</view>
|
|
126
|
+
|
|
127
|
+
<!-- 带背景色容器 / 普通容器 / 标题容器 -->
|
|
128
|
+
<view wx:if="{{item.type === 'container' && item.key !== 'collapse'}}">
|
|
129
|
+
<view wx:if="{{item.title}}" class="menu-title" style="background-color: {{item.color}}; color: {{item.titleTextColor}}">{{item.title}}</view>
|
|
130
|
+
<view wx:if="{{item.hasDivider}}" class="container-divider"></view>
|
|
131
|
+
<view class="wiki-container" style="background-color: {{item.key === 'hasBGC' ? item.color : ''}}">
|
|
132
|
+
<wiki-renderer images="{{images}}" data="{{item.children}}" game-id="{{gameId}}" wiki-users="{{wikiUsers}}" />
|
|
133
|
+
</view>
|
|
134
|
+
</view>
|
|
135
|
+
|
|
136
|
+
<!-- 左右布局 -->
|
|
137
|
+
<view wx:if="{{item.type === 'lr'}}" class="wiki-container">
|
|
138
|
+
<view wx:if="{{item.title}}" class="menu-title" style="background-color: {{item.color}}; color: {{item.titleTextColor}}">{{item.title}}</view>
|
|
139
|
+
<view class="lr-block">
|
|
140
|
+
<view class="lr-side" style="flex: {{item.percent / 100}}">
|
|
141
|
+
<wiki-renderer wx:if="{{item.left}}" images="{{images}}" data="{{[item.left]}}" game-id="{{gameId}}" wiki-users="{{wikiUsers}}" />
|
|
142
|
+
</view>
|
|
143
|
+
<view class="lr-side" style="flex: {{1 - item.percent / 100}}">
|
|
144
|
+
<wiki-renderer wx:if="{{item.right}}" images="{{images}}" data="{{[item.right]}}" game-id="{{gameId}}" wiki-users="{{wikiUsers}}" />
|
|
145
|
+
</view>
|
|
146
|
+
</view>
|
|
147
|
+
</view>
|
|
148
|
+
|
|
149
|
+
</block>
|
|
150
|
+
</view>
|
|
@@ -0,0 +1,412 @@
|
|
|
1
|
+
.wiki-root {}
|
|
2
|
+
|
|
3
|
+
/* Banner */
|
|
4
|
+
.banner-swipe {
|
|
5
|
+
border-radius: 8px;
|
|
6
|
+
overflow: hidden;
|
|
7
|
+
margin: 15px 0;
|
|
8
|
+
width: 100%;
|
|
9
|
+
height: auto;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.banner-img {
|
|
13
|
+
width: 100%;
|
|
14
|
+
height: 100%;
|
|
15
|
+
border-radius: 12px;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
/* Image */
|
|
19
|
+
.image-block {
|
|
20
|
+
position: relative;
|
|
21
|
+
margin: 15px 0;
|
|
22
|
+
width: 100%;
|
|
23
|
+
background-color: #e0e0e0;
|
|
24
|
+
border-radius: 10rpx;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.block-img {
|
|
28
|
+
width: 100%;
|
|
29
|
+
height: 100%;
|
|
30
|
+
border-radius: 12px;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
/* Text */
|
|
34
|
+
.wiki-text {
|
|
35
|
+
margin: 15px 0;
|
|
36
|
+
line-height: 2.0;
|
|
37
|
+
font-size: 14px;
|
|
38
|
+
color: black;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.wiki-richtext {
|
|
42
|
+
margin: 15px 0;
|
|
43
|
+
font-size: 14px;
|
|
44
|
+
line-height: 2.0;
|
|
45
|
+
padding: 0 10px;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/* Menu */
|
|
49
|
+
.menu-tabs {
|
|
50
|
+
background-color: #f5f5f5;
|
|
51
|
+
padding: 15px;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.menu-title {
|
|
55
|
+
font-size: 20px;
|
|
56
|
+
font-weight: bold;
|
|
57
|
+
text-align: left;
|
|
58
|
+
padding: 8px;
|
|
59
|
+
margin-top: 15px;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
/* Tabs */
|
|
63
|
+
.tab-bar {
|
|
64
|
+
display: flex;
|
|
65
|
+
flex-direction: row;
|
|
66
|
+
white-space: nowrap;
|
|
67
|
+
margin-bottom: 15px;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.tab-btn {
|
|
71
|
+
display: inline-block;
|
|
72
|
+
padding: 6px 16px;
|
|
73
|
+
margin-right: 8px;
|
|
74
|
+
border-radius: 16px;
|
|
75
|
+
background: #f5f5f5;
|
|
76
|
+
font-size: 14px;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.tab-btn-active {
|
|
80
|
+
background: #409eff;
|
|
81
|
+
color: white;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
/* Grid */
|
|
85
|
+
.grid {
|
|
86
|
+
display: grid;
|
|
87
|
+
gap: 0;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.grid-item {
|
|
91
|
+
padding: 6px 0;
|
|
92
|
+
text-align: center;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
/* Filter */
|
|
96
|
+
.filter-classes {
|
|
97
|
+
display: flex;
|
|
98
|
+
flex-direction: column;
|
|
99
|
+
gap: 8px;
|
|
100
|
+
margin: 15px 0;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.filter-class {
|
|
104
|
+
display: flex;
|
|
105
|
+
flex-wrap: wrap;
|
|
106
|
+
gap: 6px;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
.filter-btn {
|
|
110
|
+
padding: 4px 12px;
|
|
111
|
+
border: 1px solid #ccc;
|
|
112
|
+
border-radius: 12px;
|
|
113
|
+
background: #f5f5f5;
|
|
114
|
+
font-size: 14px;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.filter-btn.active {
|
|
118
|
+
background: #409eff;
|
|
119
|
+
color: white;
|
|
120
|
+
border-color: #409eff;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
/* Info */
|
|
124
|
+
.info {
|
|
125
|
+
margin-top: 15px;
|
|
126
|
+
padding: 10px;
|
|
127
|
+
border-radius: 12px;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.info-users {
|
|
131
|
+
display: flex;
|
|
132
|
+
flex-wrap: wrap;
|
|
133
|
+
gap: 10px;
|
|
134
|
+
background: white;
|
|
135
|
+
padding: 10px;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
.user-item {
|
|
139
|
+
display: flex;
|
|
140
|
+
flex-direction: column;
|
|
141
|
+
align-items: center;
|
|
142
|
+
gap: 6px;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
.user-avatar {
|
|
146
|
+
width: 40px;
|
|
147
|
+
height: 40px;
|
|
148
|
+
border-radius: 50%;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.user-name {
|
|
152
|
+
width: 60px;
|
|
153
|
+
text-align: center;
|
|
154
|
+
overflow: hidden;
|
|
155
|
+
text-overflow: ellipsis;
|
|
156
|
+
white-space: nowrap;
|
|
157
|
+
color: #a7a7a7;
|
|
158
|
+
font-size: 12px;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
/* Container */
|
|
162
|
+
.wiki-container {
|
|
163
|
+
padding: 5px;
|
|
164
|
+
border-radius: 12px;
|
|
165
|
+
background: #f8f8f8;
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
.collapse-title {
|
|
169
|
+
display: flex;
|
|
170
|
+
justify-content: space-between;
|
|
171
|
+
padding: 10px;
|
|
172
|
+
font-weight: bold;
|
|
173
|
+
border-radius: 8px;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.collapse-arrow {
|
|
177
|
+
transition: transform 0.2s;
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
.collapse-arrow.open {
|
|
181
|
+
transform: rotate(180deg);
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
/* LR */
|
|
185
|
+
.lr-block {
|
|
186
|
+
display: flex;
|
|
187
|
+
gap: 12px;
|
|
188
|
+
margin: 15px 0;
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
.lr-side {
|
|
192
|
+
display: flex;
|
|
193
|
+
flex-direction: column;
|
|
194
|
+
gap: 8px;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
.container-divider {
|
|
198
|
+
height: 1px;
|
|
199
|
+
background-color: #e0e0e0;
|
|
200
|
+
margin: 10px 0;
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
|
|
204
|
+
/* 评分块 */
|
|
205
|
+
.score-block {
|
|
206
|
+
margin: 15px 0;
|
|
207
|
+
padding: 15px 0px;
|
|
208
|
+
background: #fff;
|
|
209
|
+
border-radius: 12px;
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
.score-header {
|
|
213
|
+
display: flex;
|
|
214
|
+
justify-content: space-between;
|
|
215
|
+
align-items: center;
|
|
216
|
+
margin-bottom: 10px;
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
.score-title {
|
|
220
|
+
font-size: 20px;
|
|
221
|
+
font-weight: bold;
|
|
222
|
+
text-align: left;
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
.score-edit-btn {
|
|
226
|
+
padding: 4px 8px;
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
.score-edit-icon {
|
|
230
|
+
font-size: 18px;
|
|
231
|
+
color: #333;
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
|
|
235
|
+
|
|
236
|
+
.score-stars {
|
|
237
|
+
display: flex;
|
|
238
|
+
gap: 4px;
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
.score-star {
|
|
242
|
+
font-size: 32px;
|
|
243
|
+
color: #e0e0e0;
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
.score-star.filled {
|
|
247
|
+
color: #f5a623;
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
.score-right {
|
|
251
|
+
display: flex;
|
|
252
|
+
flex-direction: column;
|
|
253
|
+
align-items: flex-start;
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
.score-avg {
|
|
257
|
+
font-size: 28px;
|
|
258
|
+
font-weight: bold;
|
|
259
|
+
line-height: 1.2;
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
.score-count {
|
|
263
|
+
font-size: 12px;
|
|
264
|
+
color: #999;
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
/* 评分弹窗 */
|
|
268
|
+
/* 蒙层透明度 0.2 */
|
|
269
|
+
.score-modal-mask {
|
|
270
|
+
position: fixed;
|
|
271
|
+
inset: 0;
|
|
272
|
+
background: rgba(0, 0, 0, 0.2);
|
|
273
|
+
z-index: 999;
|
|
274
|
+
display: flex;
|
|
275
|
+
align-items: center;
|
|
276
|
+
justify-content: center;
|
|
277
|
+
}
|
|
278
|
+
|
|
279
|
+
/* score-body 改为 space-between */
|
|
280
|
+
.score-body {
|
|
281
|
+
display: flex;
|
|
282
|
+
align-items: center;
|
|
283
|
+
justify-content: space-between;
|
|
284
|
+
/* ← 关键改动 */
|
|
285
|
+
width: 100%;
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
.score-modal {
|
|
289
|
+
background: #fff;
|
|
290
|
+
border-radius: 16px;
|
|
291
|
+
padding: 24px 20px;
|
|
292
|
+
width: 72vw;
|
|
293
|
+
display: flex;
|
|
294
|
+
flex-direction: column;
|
|
295
|
+
align-items: center;
|
|
296
|
+
gap: 16px;
|
|
297
|
+
}
|
|
298
|
+
|
|
299
|
+
.score-modal-title {
|
|
300
|
+
font-size: 16px;
|
|
301
|
+
font-weight: bold;
|
|
302
|
+
text-align: center;
|
|
303
|
+
}
|
|
304
|
+
|
|
305
|
+
.score-modal-stars {
|
|
306
|
+
display: flex;
|
|
307
|
+
gap: 8px;
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
.score-modal-star {
|
|
311
|
+
font-size: 40px;
|
|
312
|
+
color: #e0e0e0;
|
|
313
|
+
}
|
|
314
|
+
|
|
315
|
+
.score-modal-star.filled {
|
|
316
|
+
color: #f5a623;
|
|
317
|
+
}
|
|
318
|
+
|
|
319
|
+
.score-modal-hint {
|
|
320
|
+
font-size: 13px;
|
|
321
|
+
color: #888;
|
|
322
|
+
}
|
|
323
|
+
|
|
324
|
+
.score-modal-btns {
|
|
325
|
+
display: flex;
|
|
326
|
+
gap: 12px;
|
|
327
|
+
width: 100%;
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
.score-modal-cancel,
|
|
331
|
+
.score-modal-confirm {
|
|
332
|
+
flex: 1;
|
|
333
|
+
text-align: center;
|
|
334
|
+
padding: 10px 0;
|
|
335
|
+
border-radius: 20px;
|
|
336
|
+
font-size: 15px;
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
.score-modal-cancel {
|
|
340
|
+
background: #f5f5f5;
|
|
341
|
+
color: #333;
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
.score-modal-confirm {
|
|
345
|
+
background: #002fa7;
|
|
346
|
+
color: #fff;
|
|
347
|
+
}
|
|
348
|
+
|
|
349
|
+
.score-modal-confirm.disabled {
|
|
350
|
+
background: #b0b0b0;
|
|
351
|
+
}
|
|
352
|
+
|
|
353
|
+
/* 星星容器:相对定位,用于叠加填充层 */
|
|
354
|
+
.star-wrap {
|
|
355
|
+
position: relative;
|
|
356
|
+
display: inline-flex;
|
|
357
|
+
align-items: center;
|
|
358
|
+
}
|
|
359
|
+
|
|
360
|
+
/* 填充层:绝对定位,从左边开始裁剪 */
|
|
361
|
+
.star-fill {
|
|
362
|
+
position: absolute;
|
|
363
|
+
left: 0;
|
|
364
|
+
top: 0;
|
|
365
|
+
overflow: hidden;
|
|
366
|
+
/* width 由内联 style 动态设置 0% / 50% / 100% */
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
/* 弹窗里的星星需要更大触控区 */
|
|
370
|
+
.modal-star {
|
|
371
|
+
margin: 0 4px;
|
|
372
|
+
}
|
|
373
|
+
|
|
374
|
+
/* 左半点击区 */
|
|
375
|
+
.star-tap-left {
|
|
376
|
+
position: absolute;
|
|
377
|
+
left: 0;
|
|
378
|
+
top: 0;
|
|
379
|
+
width: 50%;
|
|
380
|
+
height: 100%;
|
|
381
|
+
}
|
|
382
|
+
|
|
383
|
+
/* 右半点击区 */
|
|
384
|
+
.star-tap-right {
|
|
385
|
+
position: absolute;
|
|
386
|
+
right: 0;
|
|
387
|
+
top: 0;
|
|
388
|
+
width: 50%;
|
|
389
|
+
height: 100%;
|
|
390
|
+
}
|
|
391
|
+
|
|
392
|
+
/* wxss */
|
|
393
|
+
.star-wrap {
|
|
394
|
+
position: relative;
|
|
395
|
+
display: inline-flex;
|
|
396
|
+
width: 32px; /* 和 van-icon size 保持一致 */
|
|
397
|
+
height: 32px;
|
|
398
|
+
overflow: hidden; /* 不需要,填充层自己 overflow hidden */
|
|
399
|
+
}
|
|
400
|
+
|
|
401
|
+
.star-fill {
|
|
402
|
+
position: absolute;
|
|
403
|
+
left: 0;
|
|
404
|
+
top: 0;
|
|
405
|
+
overflow: hidden;
|
|
406
|
+
/* width 由 style 动态设置,此时 % 相对于 32px 父容器计算,正常生效 */
|
|
407
|
+
}
|
|
408
|
+
|
|
409
|
+
.modal-star {
|
|
410
|
+
width: 40px;
|
|
411
|
+
height: 40px;
|
|
412
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
function _0x3a9a(_0x10d80d,_0x2177a2){_0x10d80d=_0x10d80d-0x1e6;const _0x1da417=_0x1da4();let _0x3a9a1a=_0x1da417[_0x10d80d];if(_0x3a9a['OlOyDW']===undefined){var _0xa3d849=function(_0x2fcb00){const _0x5f5d9d='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x332f9e='',_0x59ef9b='';for(let _0x4066fd=0x0,_0x245ecd,_0x10d8b7,_0x2229fd=0x0;_0x10d8b7=_0x2fcb00['charAt'](_0x2229fd++);~_0x10d8b7&&(_0x245ecd=_0x4066fd%0x4?_0x245ecd*0x40+_0x10d8b7:_0x10d8b7,_0x4066fd++%0x4)?_0x332f9e+=String['fromCharCode'](0xff&_0x245ecd>>(-0x2*_0x4066fd&0x6)):0x0){_0x10d8b7=_0x5f5d9d['indexOf'](_0x10d8b7);}for(let _0x3aea47=0x0,_0x5755d5=_0x332f9e['length'];_0x3aea47<_0x5755d5;_0x3aea47++){_0x59ef9b+='%'+('00'+_0x332f9e['charCodeAt'](_0x3aea47)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x59ef9b);};_0x3a9a['DwHsFC']=_0xa3d849,_0x3a9a['cHLwPe']={},_0x3a9a['OlOyDW']=!![];}const _0x12f772=_0x1da417[0x0],_0x28cc57=_0x10d80d+_0x12f772,_0x2d4950=_0x3a9a['cHLwPe'][_0x28cc57];return!_0x2d4950?(_0x3a9a1a=_0x3a9a['DwHsFC'](_0x3a9a1a),_0x3a9a['cHLwPe'][_0x28cc57]=_0x3a9a1a):_0x3a9a1a=_0x2d4950,_0x3a9a1a;}function _0x1da4(){const _0x520bb1=['y2HHBMDL','mJu1mJmXm0H5Ag9Puq','zgf0yxnLDa','iZe5odLMyq','mte1mZbdrNHsy20','DhjPz2DLCKv2zw50','mZy4ndaYneLsAuPbvG','Aw5JBhvKzxm','y3vYCMvUDfrHCMDLDa','A1HdAha','mtq0nteZnM5Rt3fnrq','mZK3mKrOCvbQtq','BwfW','yxbWBhKTC2HHCMvK','BMfTzq','otm0oti2s05LvKv5','mvDjBNvgsa','mtKYnJa5nZjzB0fSwMG','vwLREMq','ywn0AxzLvgfI','zgf0yq','nJyXmtCYmfzmEeXfDa','C2v0rgf0yq'];_0x1da4=function(){return _0x520bb1;};return _0x1da4();}const _0x1f01dc=_0x3a9a;(function(_0x445a11,_0x2bd65e){const _0x37375b=_0x3a9a,_0xf8ee89=_0x445a11();while(!![]){try{const _0x2618d3=parseInt(_0x37375b(0x1f1))/0x1*(parseInt(_0x37375b(0x1f0))/0x2)+-parseInt(_0x37375b(0x1f9))/0x3+-parseInt(_0x37375b(0x1f6))/0x4+parseInt(_0x37375b(0x1fc))/0x5*(parseInt(_0x37375b(0x1ec))/0x6)+-parseInt(_0x37375b(0x1eb))/0x7+-parseInt(_0x37375b(0x1e7))/0x8+parseInt(_0x37375b(0x1f2))/0x9;if(_0x2618d3===_0x2bd65e)break;else _0xf8ee89['push'](_0xf8ee89['shift']());}catch(_0x165d29){_0xf8ee89['push'](_0xf8ee89['shift']());}}}(_0x1da4,0xeb3a3),Component({'options':{'styleIsolation':_0x1f01dc(0x1ee),'multipleSlots':!![]},'properties':{'tabs':{'type':Array,'value':[]},'color':{'type':String,'value':_0x1f01dc(0x1fb)},'active':{'type':String,'value':''}},'data':{'activeTab':''},'observers':{'tabs,\x20active':function(_0x22f80a,_0x1de016){const _0x1717eb=_0x1f01dc;if(!_0x22f80a||!_0x22f80a['length'])return;const _0x48d336=_0x22f80a[_0x1717eb(0x1ed)](_0x20a18e=>_0x20a18e['name']);if(_0x1de016&&_0x48d336[_0x1717eb(0x1e8)](_0x1de016))this[_0x1717eb(0x1f7)]({'activeTab':_0x1de016});else(!this[_0x1717eb(0x1f5)][_0x1717eb(0x1f4)]||!_0x48d336['includes'](this[_0x1717eb(0x1f5)]['activeTab']))&&this[_0x1717eb(0x1f7)]({'activeTab':_0x22f80a[0x0][_0x1717eb(0x1ef)]});}},'methods':{'onTabTap'(_0x5e50ea){const _0xdbd73d=_0x1f01dc,_0x179cce={'Uikzd':function(_0x585bcc,_0x2ad8e7){return _0x585bcc===_0x2ad8e7;},'kXChp':_0xdbd73d(0x1f8)},_0x119963=_0x5e50ea[_0xdbd73d(0x1e9)][_0xdbd73d(0x1fa)][_0xdbd73d(0x1ef)];if(_0x179cce[_0xdbd73d(0x1f3)](_0x119963,this[_0xdbd73d(0x1f5)][_0xdbd73d(0x1f4)]))return;this[_0xdbd73d(0x1f7)]({'activeTab':_0x119963}),this[_0xdbd73d(0x1e6)](_0x179cce[_0xdbd73d(0x1ea)],{'name':_0x119963});}}}));
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
<view class="wiki-tabs-root">
|
|
2
|
+
<!-- Tab 按钮栏 -->
|
|
3
|
+
<scroll-view scroll-x class="wiki-tabs-bar" enhanced="true" show-scrollbar="false">
|
|
4
|
+
<view class="wiki-tabs-bar-inner">
|
|
5
|
+
<view
|
|
6
|
+
wx:for="{{tabs}}"
|
|
7
|
+
wx:key="name"
|
|
8
|
+
wx:for-item="tab"
|
|
9
|
+
wx:for-index="ti"
|
|
10
|
+
class="wiki-tab-btn {{activeTab === tab.name ? 'active' : ''}}"
|
|
11
|
+
style="{{activeTab === tab.name ? 'background-color:' + (color || '#1989fa') + '; border-color:' + (color || '#1989fa') + ';' : ''}}"
|
|
12
|
+
bindtap="onTabTap"
|
|
13
|
+
data-name="{{tab.name}}"
|
|
14
|
+
>
|
|
15
|
+
<text class="wiki-tab-label {{activeTab === tab.name ? 'active' : ''}}">{{tab.name}}</text>
|
|
16
|
+
</view>
|
|
17
|
+
</view>
|
|
18
|
+
</scroll-view>
|
|
19
|
+
|
|
20
|
+
<!-- Tab 内容区 -->
|
|
21
|
+
<view class="wiki-tabs-content">
|
|
22
|
+
<block wx:for="{{tabs}}" wx:key="name" wx:for-item="tab">
|
|
23
|
+
<view wx:if="{{activeTab === tab.name}}">
|
|
24
|
+
<slot name="{{tab.name}}" />
|
|
25
|
+
</view>
|
|
26
|
+
</block>
|
|
27
|
+
</view>
|
|
28
|
+
</view>
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
.wiki-tabs-root {
|
|
2
|
+
width: 100%;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.wiki-tabs-bar {
|
|
6
|
+
width: 100%;
|
|
7
|
+
white-space: nowrap;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.wiki-tabs-bar-inner {
|
|
11
|
+
display: flex;
|
|
12
|
+
flex-direction: row;
|
|
13
|
+
align-items: center;
|
|
14
|
+
gap: 8rpx;
|
|
15
|
+
padding: 15px 0 15px;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.wiki-tab-btn {
|
|
19
|
+
flex-shrink: 0;
|
|
20
|
+
display: inline-flex;
|
|
21
|
+
align-items: center;
|
|
22
|
+
justify-content: center;
|
|
23
|
+
padding: 10rpx 28rpx;
|
|
24
|
+
border-radius: 40rpx;
|
|
25
|
+
border: 2rpx solid #d9d9d9;
|
|
26
|
+
background-color: #f5f5f5;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.wiki-tab-label {
|
|
30
|
+
font-size: 26rpx;
|
|
31
|
+
color: #555555;
|
|
32
|
+
font-weight: 400;
|
|
33
|
+
line-height: 1;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.wiki-tab-label.active {
|
|
37
|
+
color: #ffffff;
|
|
38
|
+
font-weight: 600;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.wiki-tabs-content {
|
|
42
|
+
width: 100%;
|
|
43
|
+
}
|
package/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const _0x324420=_0x3344;(function(_0x28a2e0,_0xe9eb){const _0x28f662=_0x3344,_0x10a322=_0x28a2e0();while(!![]){try{const _0x2b609f=-parseInt(_0x28f662(0x164))/0x1*(-parseInt(_0x28f662(0x139))/0x2)+parseInt(_0x28f662(0x157))/0x3+-parseInt(_0x28f662(0x150))/0x4*(-parseInt(_0x28f662(0x15e))/0x5)+-parseInt(_0x28f662(0x161))/0x6*(-parseInt(_0x28f662(0x162))/0x7)+-parseInt(_0x28f662(0x155))/0x8*(-parseInt(_0x28f662(0x14e))/0x9)+-parseInt(_0x28f662(0x135))/0xa*(-parseInt(_0x28f662(0x140))/0xb)+-parseInt(_0x28f662(0x14a))/0xc;if(_0x2b609f===_0xe9eb)break;else _0x10a322['push'](_0x10a322['shift']());}catch(_0x1c178b){_0x10a322['push'](_0x10a322['shift']());}}}(_0xb217,0xa361e));const {blueGuestLogin}=require('./services/home');function _0x3344(_0x5b5c96,_0x42a2ae){_0x5b5c96=_0x5b5c96-0x134;const _0xb21794=_0xb217();let _0x3344ad=_0xb21794[_0x5b5c96];if(_0x3344['JzKTnU']===undefined){var _0x11292a=function(_0x1bf993){const _0x2ef1fa='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x2f2743='',_0x509585='';for(let _0x43eb75=0x0,_0x343e9a,_0x31bfa0,_0x24f18f=0x0;_0x31bfa0=_0x1bf993['charAt'](_0x24f18f++);~_0x31bfa0&&(_0x343e9a=_0x43eb75%0x4?_0x343e9a*0x40+_0x31bfa0:_0x31bfa0,_0x43eb75++%0x4)?_0x2f2743+=String['fromCharCode'](0xff&_0x343e9a>>(-0x2*_0x43eb75&0x6)):0x0){_0x31bfa0=_0x2ef1fa['indexOf'](_0x31bfa0);}for(let _0x5733c6=0x0,_0x51c235=_0x2f2743['length'];_0x5733c6<_0x51c235;_0x5733c6++){_0x509585+='%'+('00'+_0x2f2743['charCodeAt'](_0x5733c6)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x509585);};_0x3344['mYThIn']=_0x11292a,_0x3344['fBeEtd']={},_0x3344['JzKTnU']=!![];}const _0x4f7c2b=_0xb21794[0x0],_0xbb98bb=_0x5b5c96+_0x4f7c2b,_0x43dd24=_0x3344['fBeEtd'][_0xbb98bb];return!_0x43dd24?(_0x3344ad=_0x3344['mYThIn'](_0x3344ad),_0x3344['fBeEtd'][_0xbb98bb]=_0x3344ad):_0x3344ad=_0x43dd24,_0x3344ad;}class GameSDK{constructor(){const _0x386ad7=_0x3344;this[_0x386ad7(0x167)]=null,this[_0x386ad7(0x165)]=!![],this[_0x386ad7(0x159)]=null,this['isInitialized']=![];}[_0x324420(0x134)](_0x55d309={}){const _0x18d219=_0x324420,_0x1da89d={'bUXkW':_0x18d219(0x15a),'ImXpE':function(_0x1cfdc4,_0x27e971){return _0x1cfdc4||_0x27e971;}},{game_id:_0x519bb2,use_book_login:use_book_login=!![],exit_listener:_0x1aeb2b}=_0x55d309;if(!_0x519bb2)throw new Error(_0x1da89d[_0x18d219(0x13e)]);return this['gameId']=_0x519bb2,this[_0x18d219(0x165)]=use_book_login,this[_0x18d219(0x159)]=_0x1da89d[_0x18d219(0x160)](_0x1aeb2b,null),this[_0x18d219(0x153)]=!![],this;}[_0x324420(0x13c)](_0x55707e={}){const _0x15f921=_0x324420,_0x2089ec={'ENtZC':_0x15f921(0x13b)};this[_0x15f921(0x168)]();if(this[_0x15f921(0x165)]){this[_0x15f921(0x151)](_0x15f921(0x13b),{});return;}const {cp_is_anonymous:_0x27e925,cp_uid:_0x3cac19,cp_nickname:_0x45e10d,cp_area:_0x4aa30f,timestamp:_0x25fb54,cp_sign:_0x3afcce}=_0x55707e;this['_loginThenNavigate']({'cp_is_anonymous':_0x27e925,'cp_uid':_0x3cac19,'cp_nickname':_0x45e10d,'cp_area':_0x4aa30f,'timestamp':_0x25fb54,'cp_sign':_0x3afcce},_0x2089ec[_0x15f921(0x137)],{});}[_0x324420(0x144)](_0x3599ca={}){const _0x57e7b6=_0x324420,_0x506dcc={'QYRTA':_0x57e7b6(0x145)};this['_checkInit']();if(this[_0x57e7b6(0x165)]){this['_navigate'](_0x57e7b6(0x145),{});return;}const {cp_wikiname:cp_wikiname='',cp_is_anonymous:_0x21234b,cp_uid:_0x116a71,cp_nickname:_0x57c709,cp_area:_0x3fe3c2,timestamp:_0x4c9294,cp_sign:_0x5e4df8}=_0x3599ca;this[_0x57e7b6(0x169)]({'cp_is_anonymous':_0x21234b,'cp_uid':_0x116a71,'cp_nickname':_0x57c709,'cp_area':_0x3fe3c2,'timestamp':_0x4c9294,'cp_sign':_0x5e4df8},_0x506dcc[_0x57e7b6(0x13f)],{'wikiname':cp_wikiname});}[_0x324420(0x169)](_0x7915b0,_0x55a28f,_0x11b511){const _0xce341b=_0x324420,_0x4ec0b8={'XyfCy':function(_0xe80f4e,_0x2457a6){return _0xe80f4e||_0x2457a6;},'NIerP':_0xce341b(0x138),'FjRVK':_0xce341b(0x147),'qQavl':'none','ObdjP':'token','qoEVM':_0xce341b(0x141),'bgnnP':_0xce341b(0x13a),'bjbOK':function(_0x280bcf,_0x31078a){return _0x280bcf(_0x31078a);}},{cp_is_anonymous:_0x33d287,cp_uid:_0x34a533,cp_nickname:_0x50fc38,cp_area:_0xba489f,timestamp:_0x20b8eb,cp_sign:_0x506a40}=_0x7915b0;wx[_0xce341b(0x15b)](_0x4ec0b8[_0xce341b(0x15f)]),wx[_0xce341b(0x15b)](_0x4ec0b8[_0xce341b(0x143)]),wx[_0xce341b(0x15b)](_0x4ec0b8['qoEVM']),_0x4ec0b8[_0xce341b(0x156)](blueGuestLogin,{'client':0x64,'is_anonymous':_0x33d287?0x1:0x0,'game_id':this['gameId'],'cp_uid':_0x34a533,'cp_nickname':_0x50fc38,'cp_area':_0xba489f,'timestamp':_0x20b8eb,'sign':_0x506a40})[_0xce341b(0x14d)](_0x3613fb=>{const _0x4a02a9=_0xce341b,{token:_0x475626,user_id:_0x590dbd,game_id:_0x52458a}=_0x3613fb['data']||{};if(_0x4ec0b8[_0x4a02a9(0x15d)](!_0x475626,!_0x590dbd)){console[_0x4a02a9(0x158)](_0x4ec0b8['NIerP'],_0x3613fb),wx[_0x4a02a9(0x163)]({'title':_0x4ec0b8[_0x4a02a9(0x13d)],'icon':_0x4ec0b8[_0x4a02a9(0x166)]});return;}wx['setStorageSync'](_0x4a02a9(0x13a),_0x590dbd),wx[_0x4a02a9(0x15c)](_0x4ec0b8[_0x4a02a9(0x143)],_0x475626),_0x52458a&&wx[_0x4a02a9(0x15c)](_0x4ec0b8['qoEVM'],_0x52458a),this[_0x4a02a9(0x151)](_0x55a28f,_0x11b511);})[_0xce341b(0x142)](_0x2cda4a=>{const _0x17df30=_0xce341b;console['error']('[SDK]\x20blueGuestLogin\x20failed:',_0x2cda4a),wx[_0x17df30(0x163)]({'title':_0x17df30(0x147),'icon':_0x4ec0b8[_0x17df30(0x166)]});});}[_0x324420(0x151)](_0x50dfe3,_0x9d089a){const _0x2ebebf=_0x324420,_0x213a45=this[_0x2ebebf(0x146)]({'gameId':this['gameId'],..._0x9d089a});wx[_0x2ebebf(0x149)]({'url':_0x2ebebf(0x136)+_0x50dfe3+'/'+_0x50dfe3+'?'+_0x213a45});}[_0x324420(0x168)](){const _0x13b00e=_0x324420,_0x50de0={'XUHFa':'SDK\x20not\x20initialized,\x20call\x20init()\x20first'};if(!this[_0x13b00e(0x153)])throw new Error(_0x50de0[_0x13b00e(0x14f)]);}[_0x324420(0x146)](_0x59e72f){const _0x5b326c=_0x324420;return Object[_0x5b326c(0x14b)](_0x59e72f)[_0x5b326c(0x14c)](_0x344ca5=>_0x59e72f[_0x344ca5]!==undefined&&_0x59e72f[_0x344ca5]!==null)[_0x5b326c(0x148)](_0x1b246e=>_0x1b246e+'='+encodeURIComponent(_0x59e72f[_0x1b246e]))[_0x5b326c(0x154)]('&');}}const sdk=new GameSDK();module[_0x324420(0x152)]=sdk;function _0xb217(){const _0x549d0f=['zMLSDgvY','DgHLBG','mJD4B1vXuMW','wfvirMe','mZq4DhjHrKv0','x25HDMLNyxrL','zxHWB3j0CW','AxnjBML0AwfSAxPLza','AM9PBG','mtC1ntK2me95BgXVtq','yMPIt0S','mtCXotuYnuXZt1HmAq','zxjYB3i','zxHPDeXPC3rLBMvY','z2fTzv9PzcbPCYbYzxf1AxjLza','CMvTB3zLu3rVCMfNzvn5BMm','C2v0u3rVCMfNzvn5BMm','whLMq3K','mJa3nJvnr3jXsNu','yMDUBLa','sw1yCeu','mtjPC3zKsvq','mtq4mJmWnNH4yvbmCq','C2HVD1rVyxn0','mK1gtMrqzG','DxnLqM9VA0XVz2LU','CvfHDMW','z2fTzuLK','x2nOzwnRsw5PDa','x2XVz2LUvgHLBK5HDMLNyxrL','Aw5PDa','mtCWmtm5mer2te5AsG','l21PBMLWCM9NCMfTx25WBs9ZB3v0Ag5VDguTBwLUAs1ZzgSVCgfNzxmV','ru50wKm','w1nes10GyMX1zuD1zxn0tg9NAw4GBwLZC2LUzYb0B2TLBI91C2vYx2LKoG','mJy4odC2D3ztvg5P','yxbWDwLK','z2fTzq','BMf2AwDHDgvuB0DHBwu','rMPsvKS','yLvyA1C','uvLsvee','mZnVCg56uuG','C2rRx2DHBwvFAwq','y2f0y2G','t2jKALa','BMf2AwDHDgvuB1DPA2K','D2LRAq','x2j1AwXKuxvLCNK','55M75B2v5AsX6lsL77Ym6k+36yEn6k+v','BwfW','BMf2AwDHDgvuBW','mJu1mtG3otjlzxruBLa','A2v5CW'];_0xb217=function(){return _0x549d0f;};return _0xb217();}
|
package/package.json
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "southnote-sdk",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "小南书SDK",
|
|
5
|
+
"main": "index.js",
|
|
6
|
+
"miniprogram": ".",
|
|
7
|
+
"keywords": [
|
|
8
|
+
"wechat",
|
|
9
|
+
"miniprogram",
|
|
10
|
+
"game",
|
|
11
|
+
"community"
|
|
12
|
+
],
|
|
13
|
+
"author": "你的名字",
|
|
14
|
+
"license": "MIT",
|
|
15
|
+
"dependencies": {
|
|
16
|
+
"pako": "^2.1.0",
|
|
17
|
+
"underscore": "^1.13.6"
|
|
18
|
+
},
|
|
19
|
+
"peerDependencies": {
|
|
20
|
+
"@vant/weapp": ">=1.0.0"
|
|
21
|
+
}
|
|
22
|
+
}
|