From 9f8fec17236227e19f43dbc8f8484acdf8f9b48c Mon Sep 17 00:00:00 2001 From: eric Date: Mon, 28 Sep 2026 23:52:00 -0500 Subject: [PATCH] Ship portal PC/H5 acceptance, VIP ScrollReader, admin analytics and ops anchors. Adds /api/health, ntfy notify on config save, /admin/analytics charts, and deploy smoke for miniprogram config/API. Co-authored-by: Cursor --- .cursor/rules/nomadro-charter.mdc | 30 +- .cursor/rules/remote-config-offline.mdc | 37 + .cursor/rules/wechat-miniprogram.mdc | 7 +- .env.example | 28 + AGENTS.md | 6 +- README.md | 170 +- app/admin/admin-shell.tsx | 149 + app/admin/admin.module.css | 571 ++- app/admin/analytics/page.tsx | 266 ++ app/admin/config/page.tsx | 199 + app/admin/layout.tsx | 3 +- app/admin/miniprogram/page.tsx | 98 + app/admin/ops/page.tsx | 69 + app/admin/orders/page.tsx | 53 + app/admin/page.tsx | 231 +- app/admin/users/page.tsx | 71 + app/admin/verticals/page.tsx | 77 + app/api/admin/analytics/route.ts | 117 + app/api/admin/config/route.ts | 41 + app/api/admin/login/route.ts | 36 + app/api/admin/logout/route.ts | 12 + app/api/admin/notify/route.ts | 43 + app/api/admin/orders/route.ts | 41 + app/api/admin/overview/route.ts | 82 + app/api/admin/session/route.ts | 16 + app/api/admin/users/route.ts | 68 + app/api/config/route.ts | 12 + app/api/health/route.ts | 25 + app/api/pay/route.ts | 65 +- app/book/layout.tsx | 8 +- app/community/book/ebook-globals.css | 186 +- app/community/book/layout.tsx | 2 +- app/community/layout.tsx | 23 +- app/globals.css | 47 +- app/hub.css | 85 +- app/layout.tsx | 27 +- app/nav/page.tsx | 7 +- app/vip/cloudphone/components/Footer.tsx | 3 +- app/vip/cloudphone/components/Header.tsx | 7 +- .../components/sections/CTASection.tsx | 3 +- .../components/sections/CurriculumSection.tsx | 3 +- .../cloudphone/components/sections/Hero.tsx | 5 +- .../[moduleIndex]/[lessonIndex]/page.tsx | 3 +- app/vip/cloudphone/pay/page.tsx | 5 +- .../components/content/EbookViewer.module.css | 345 +- app/vip/components/content/EbookViewer.tsx | 37 +- app/vip/data/vip.mock.ts | 27 +- .../cloudphone => ebook-cloudphone}/page.tsx | 0 app/vip/ebook-read/page.tsx | 30 + app/vip/ebook/VipEbookShell.tsx | 67 + app/vip/ebook/open/page.tsx | 21 + app/vip/ebook/page.tsx | 44 +- app/vip/lib/ebook.ts | 37 +- app/vip/lib/loadVipEbookBook.ts | 100 + app/vip/lib/resolveVipDataFile.ts | 17 + app/vip/lib/triggerPay.ts | 36 +- app/vip/lib/vipPath.ts | 25 + app/vip/page.tsx | 13 +- app/vip/providers/ThemeProvider.tsx | 30 +- app/vip/theme-init.ts | 21 +- app/vip/topic/components/TopicCurriculum.tsx | 3 +- app/vip/topic/components/TopicHeader.tsx | 3 +- app/vip/topic/components/TopicHero.tsx | 3 +- app/vip/vip/components/VipHeader.tsx | 33 +- .../components/dashboard/ContinueLearning.tsx | 5 +- .../vip/components/landing/LandingHero.tsx | 7 +- app/vip/vip/components/vip.module.css | 141 +- apps/api/app/main.py | 100 +- apps/api/app/wx_virtual_pay.py | 136 + apps/ebook/package.json | 1 + apps/ebook/src/app/globals.css | 335 +- apps/ebook/src/components/BookRoutes.tsx | 44 + apps/ebook/src/components/BookSearch.tsx | 10 +- apps/ebook/src/components/ChapterMenu.tsx | 20 +- apps/ebook/src/components/ChapterSidebar.tsx | 24 +- apps/ebook/src/components/ContinueReading.tsx | 20 +- .../ebook/src/components/CoverChapterGrid.tsx | 10 +- apps/ebook/src/components/CoverPage.tsx | 41 +- apps/ebook/src/components/GrowthKit.tsx | 10 +- apps/ebook/src/components/LocaleSwitcher.tsx | 27 +- apps/ebook/src/components/MarkdownContent.tsx | 31 +- apps/ebook/src/components/Providers.tsx | 1 + apps/ebook/src/components/ReaderLayout.tsx | 4 + .../src/components/ScrollReaderShell.tsx | 4 +- .../src/components/ScrollReadingTracker.tsx | 6 +- apps/ebook/src/components/ThemeToggle.tsx | 35 +- apps/miniprogram/README.md | 116 + apps/miniprogram/babel.config.js | 3 + apps/miniprogram/config/index.ts | 70 + apps/miniprogram/package.json | 45 + apps/miniprogram/project.config.json | 13 + apps/miniprogram/project.tt.json | 13 + apps/miniprogram/src/app.config.ts | 35 + apps/miniprogram/src/app.scss | 6 + apps/miniprogram/src/app.tsx | 17 + apps/miniprogram/src/assets/icons/1psim.webp | Bin 0 -> 3872 bytes apps/miniprogram/src/assets/icons/3x-ui.webp | Bin 0 -> 1458 bytes apps/miniprogram/src/assets/icons/9esim.webp | Bin 0 -> 1254 bytes .../miniprogram/src/assets/icons/aapanel.webp | Bin 0 -> 1970 bytes .../src/assets/icons/action-cam.webp | Bin 0 -> 794 bytes .../miniprogram/src/assets/icons/adsense.webp | Bin 0 -> 3068 bytes .../src/assets/icons/ai-glasses.webp | Bin 0 -> 682 bytes apps/miniprogram/src/assets/icons/aliyun.webp | Bin 0 -> 934 bytes apps/miniprogram/src/assets/icons/bmc.webp | Bin 0 -> 1586 bytes apps/miniprogram/src/assets/icons/bwh.webp | Bin 0 -> 1354 bytes .../miniprogram/src/assets/icons/chatgpt.webp | Bin 0 -> 1378 bytes .../src/assets/icons/cloud-phone.webp | Bin 0 -> 724 bytes .../src/assets/icons/cloudflare.webp | Bin 0 -> 1302 bytes .../src/assets/icons/colocrossing.webp | Bin 0 -> 2270 bytes apps/miniprogram/src/assets/icons/creem.webp | Bin 0 -> 1242 bytes apps/miniprogram/src/assets/icons/drone.webp | Bin 0 -> 772 bytes apps/miniprogram/src/assets/icons/dsx.webp | Bin 0 -> 2212 bytes apps/miniprogram/src/assets/icons/ffmpeg.webp | Bin 0 -> 1200 bytes apps/miniprogram/src/assets/icons/frp.webp | Bin 0 -> 910 bytes apps/miniprogram/src/assets/icons/ga.webp | Bin 0 -> 1876 bytes apps/miniprogram/src/assets/icons/gpu.webp | Bin 0 -> 1070 bytes apps/miniprogram/src/assets/icons/grok.webp | Bin 0 -> 2824 bytes .../miniprogram/src/assets/icons/iproyal.webp | Bin 0 -> 522 bytes apps/miniprogram/src/assets/icons/jms.webp | Bin 0 -> 1750 bytes .../src/assets/icons/lineageos.webp | Bin 0 -> 798 bytes apps/miniprogram/src/assets/icons/lisa.webp | Bin 0 -> 1252 bytes apps/miniprogram/src/assets/icons/mihomo.webp | Bin 0 -> 2858 bytes .../miniprogram/src/assets/icons/mini-pc.webp | Bin 0 -> 370 bytes .../src/assets/icons/namesilo.webp | Bin 0 -> 942 bytes .../src/assets/icons/nomad-book.webp | Bin 0 -> 832 bytes .../src/assets/icons/nomadcna.webp | Bin 0 -> 1520 bytes .../src/assets/icons/nomadlist.webp | Bin 0 -> 600 bytes .../miniprogram/src/assets/icons/nomadro.webp | Bin 0 -> 3394 bytes .../src/assets/icons/nowpayments.webp | Bin 0 -> 236 bytes apps/miniprogram/src/assets/icons/obs.webp | Bin 0 -> 1212 bytes apps/miniprogram/src/assets/icons/okx.webp | Bin 0 -> 926 bytes apps/miniprogram/src/assets/icons/paypal.webp | Bin 0 -> 616 bytes .../src/assets/icons/proxy-cheap.webp | Bin 0 -> 1000 bytes apps/miniprogram/src/assets/icons/qcloud.webp | Bin 0 -> 1486 bytes .../src/assets/icons/racknerd.webp | Bin 0 -> 776 bytes apps/miniprogram/src/components/Chrome.tsx | 20 + apps/miniprogram/src/components/DestCard.tsx | 47 + .../src/components/DestinationsSection.tsx | 120 + .../src/components/MarkdownView.scss | 52 + .../src/components/MarkdownView.tsx | 121 + .../src/components/MiniModuleGate.tsx | 40 + .../src/components/PayResultSheet.scss | 139 + .../src/components/PayResultSheet.tsx | 51 + .../src/components/ReaderSettings.scss | 173 + .../src/components/ReaderSettings.tsx | 95 + apps/miniprogram/src/data/homeStatic.ts | 35 + apps/miniprogram/src/data/links.json | 585 +++ apps/miniprogram/src/data/localCatalog.ts | 810 ++++ apps/miniprogram/src/data/offlineBook.ts | 52 + .../src/data/remoteConfig.defaults.ts | 77 + apps/miniprogram/src/modules/index.ts | 6 + .../src/modules/reader/constants.ts | 8 + apps/miniprogram/src/modules/reader/index.ts | 1 + .../src/modules/reader/scrollJump.ts | 29 + .../src/pages/book/index.config.ts | 3 + apps/miniprogram/src/pages/book/index.scss | 278 ++ apps/miniprogram/src/pages/book/index.tsx | 182 + .../src/pages/community/index.config.ts | 1 + .../src/pages/community/index.scss | 9 + .../miniprogram/src/pages/community/index.tsx | 273 ++ .../src/pages/destination/index.config.ts | 1 + .../src/pages/destination/index.scss | 1 + .../src/pages/destination/index.tsx | 75 + .../src/pages/destinations/index.config.ts | 1 + .../src/pages/destinations/index.scss | 1 + .../src/pages/destinations/index.tsx | 34 + .../src/pages/index/index.config.ts | 3 + apps/miniprogram/src/pages/index/index.scss | 90 + apps/miniprogram/src/pages/index/index.tsx | 86 + .../src/pages/meetups/index.config.ts | 1 + apps/miniprogram/src/pages/meetups/index.scss | 1 + apps/miniprogram/src/pages/meetups/index.tsx | 119 + .../src/pages/mine/index.config.ts | 1 + apps/miniprogram/src/pages/mine/index.scss | 1 + apps/miniprogram/src/pages/mine/index.tsx | 159 + .../miniprogram/src/pages/nav/index.config.ts | 1 + apps/miniprogram/src/pages/nav/index.scss | 145 + apps/miniprogram/src/pages/nav/index.tsx | 136 + .../src/pages/reader/index.config.ts | 3 + apps/miniprogram/src/pages/reader/index.scss | 710 +++ apps/miniprogram/src/pages/reader/index.tsx | 733 ++++ .../miniprogram/src/pages/vip/index.config.ts | 1 + apps/miniprogram/src/pages/vip/index.scss | 19 + apps/miniprogram/src/pages/vip/index.tsx | 68 + apps/miniprogram/src/services/api.ts | 197 + apps/miniprogram/src/services/ebookApi.ts | 164 + apps/miniprogram/src/services/remoteConfig.ts | 110 + apps/miniprogram/src/styles/ebook.scss | 30 + apps/miniprogram/src/styles/h5-theme.scss | 653 +++ .../miniprogram/src/utils/communityRequest.ts | 28 + apps/miniprogram/src/utils/config.ts | 38 + apps/miniprogram/src/utils/ebookPayFlow.ts | 185 + apps/miniprogram/src/utils/ebookRequest.ts | 9 + apps/miniprogram/src/utils/imageSizeCache.ts | 17 + apps/miniprogram/src/utils/markdown.ts | 317 ++ apps/miniprogram/src/utils/pay.ts | 6 + apps/miniprogram/src/utils/payFeedback.ts | 154 + apps/miniprogram/src/utils/payFlow.ts | 185 + apps/miniprogram/src/utils/readerPrefs.ts | 155 + apps/miniprogram/src/utils/readingProgress.ts | 60 + apps/miniprogram/src/utils/request.ts | 195 + apps/miniprogram/src/utils/track.ts | 97 + apps/miniprogram/src/utils/virtualPay.ts | 144 + apps/miniprogram/tsconfig.json | 16 + apps/miniprogram/xhs/release/app.js | 1059 +++++ apps/miniprogram/xhs/release/book/app.js | 3797 +++++++++++++++++ .../miniprogram/xhs/release/book/book-data.js | 116 + apps/miniprogram/xhs/release/book/index.html | 196 + apps/miniprogram/xhs/release/book/markdown.js | 274 ++ apps/miniprogram/xhs/release/book/styles.css | 1435 +++++++ .../xhs/release/book/xhs-bridge.js | 639 +++ apps/miniprogram/xhs/release/icons/1psim.webp | Bin 0 -> 3872 bytes apps/miniprogram/xhs/release/icons/3x-ui.webp | Bin 0 -> 1458 bytes apps/miniprogram/xhs/release/icons/9esim.webp | Bin 0 -> 1254 bytes .../xhs/release/icons/aapanel.webp | Bin 0 -> 1970 bytes .../xhs/release/icons/action-cam.webp | Bin 0 -> 794 bytes .../xhs/release/icons/adsense.webp | Bin 0 -> 3068 bytes .../xhs/release/icons/ai-glasses.webp | Bin 0 -> 682 bytes .../miniprogram/xhs/release/icons/aliyun.webp | Bin 0 -> 934 bytes apps/miniprogram/xhs/release/icons/bmc.webp | Bin 0 -> 1586 bytes apps/miniprogram/xhs/release/icons/bwh.webp | Bin 0 -> 1354 bytes .../xhs/release/icons/chatgpt.webp | Bin 0 -> 1378 bytes .../xhs/release/icons/cloud-phone.webp | Bin 0 -> 724 bytes .../xhs/release/icons/cloudflare.webp | Bin 0 -> 1302 bytes .../xhs/release/icons/colocrossing.webp | Bin 0 -> 2270 bytes apps/miniprogram/xhs/release/icons/creem.webp | Bin 0 -> 1242 bytes apps/miniprogram/xhs/release/icons/drone.webp | Bin 0 -> 772 bytes apps/miniprogram/xhs/release/icons/dsx.webp | Bin 0 -> 2212 bytes .../miniprogram/xhs/release/icons/ffmpeg.webp | Bin 0 -> 1200 bytes apps/miniprogram/xhs/release/icons/frp.webp | Bin 0 -> 910 bytes apps/miniprogram/xhs/release/icons/ga.webp | Bin 0 -> 1876 bytes apps/miniprogram/xhs/release/icons/gpu.webp | Bin 0 -> 1070 bytes apps/miniprogram/xhs/release/icons/grok.webp | Bin 0 -> 2824 bytes .../xhs/release/icons/iproyal.webp | Bin 0 -> 522 bytes apps/miniprogram/xhs/release/icons/jms.webp | Bin 0 -> 1750 bytes .../xhs/release/icons/lineageos.webp | Bin 0 -> 798 bytes apps/miniprogram/xhs/release/icons/lisa.webp | Bin 0 -> 1252 bytes .../miniprogram/xhs/release/icons/mihomo.webp | Bin 0 -> 2858 bytes .../xhs/release/icons/mini-pc.webp | Bin 0 -> 370 bytes .../xhs/release/icons/namesilo.webp | Bin 0 -> 942 bytes .../xhs/release/icons/nomad-book.webp | Bin 0 -> 832 bytes .../xhs/release/icons/nomadcna.webp | Bin 0 -> 1520 bytes .../xhs/release/icons/nomadlist.webp | Bin 0 -> 600 bytes .../xhs/release/icons/nomadro.webp | Bin 0 -> 3394 bytes .../xhs/release/icons/nowpayments.webp | Bin 0 -> 236 bytes apps/miniprogram/xhs/release/icons/obs.webp | Bin 0 -> 1212 bytes apps/miniprogram/xhs/release/icons/okx.webp | Bin 0 -> 926 bytes .../miniprogram/xhs/release/icons/paypal.webp | Bin 0 -> 616 bytes .../xhs/release/icons/proxy-cheap.webp | Bin 0 -> 1000 bytes .../miniprogram/xhs/release/icons/qcloud.webp | Bin 0 -> 1486 bytes .../xhs/release/icons/racknerd.webp | Bin 0 -> 776 bytes apps/miniprogram/xhs/release/index.html | 129 + apps/miniprogram/xhs/release/styles.css | 944 ++++ apps/miniprogram/xhs/scripts/assemble.py | 71 + apps/miniprogram/xhs/scripts/pack.py | 34 + apps/miniprogram/xhs/scripts/sync_data.py | 57 + apps/miniprogram/xhs/tool/app.js | 470 ++ apps/miniprogram/xhs/tool/book-app.js | 3797 +++++++++++++++++ apps/miniprogram/xhs/tool/book-styles.css | 1435 +++++++ apps/miniprogram/xhs/tool/book.html | 196 + apps/miniprogram/xhs/tool/book/book-data.js | 116 + apps/miniprogram/xhs/tool/book/markdown.js | 274 ++ apps/miniprogram/xhs/tool/book/xhs-bridge.js | 639 +++ apps/miniprogram/xhs/tool/icons/1psim.webp | Bin 0 -> 3872 bytes apps/miniprogram/xhs/tool/icons/3x-ui.webp | Bin 0 -> 1458 bytes apps/miniprogram/xhs/tool/icons/9esim.webp | Bin 0 -> 1254 bytes apps/miniprogram/xhs/tool/icons/aapanel.webp | Bin 0 -> 1970 bytes .../xhs/tool/icons/action-cam.webp | Bin 0 -> 794 bytes apps/miniprogram/xhs/tool/icons/adsense.webp | Bin 0 -> 3068 bytes .../xhs/tool/icons/ai-glasses.webp | Bin 0 -> 682 bytes apps/miniprogram/xhs/tool/icons/aliyun.webp | Bin 0 -> 934 bytes apps/miniprogram/xhs/tool/icons/bmc.webp | Bin 0 -> 1586 bytes apps/miniprogram/xhs/tool/icons/bwh.webp | Bin 0 -> 1354 bytes apps/miniprogram/xhs/tool/icons/chatgpt.webp | Bin 0 -> 1378 bytes .../xhs/tool/icons/cloud-phone.webp | Bin 0 -> 724 bytes .../xhs/tool/icons/cloudflare.webp | Bin 0 -> 1302 bytes .../xhs/tool/icons/colocrossing.webp | Bin 0 -> 2270 bytes apps/miniprogram/xhs/tool/icons/creem.webp | Bin 0 -> 1242 bytes apps/miniprogram/xhs/tool/icons/drone.webp | Bin 0 -> 772 bytes apps/miniprogram/xhs/tool/icons/dsx.webp | Bin 0 -> 2212 bytes apps/miniprogram/xhs/tool/icons/ffmpeg.webp | Bin 0 -> 1200 bytes apps/miniprogram/xhs/tool/icons/frp.webp | Bin 0 -> 910 bytes apps/miniprogram/xhs/tool/icons/ga.webp | Bin 0 -> 1876 bytes apps/miniprogram/xhs/tool/icons/gpu.webp | Bin 0 -> 1070 bytes apps/miniprogram/xhs/tool/icons/grok.webp | Bin 0 -> 2824 bytes apps/miniprogram/xhs/tool/icons/iproyal.webp | Bin 0 -> 522 bytes apps/miniprogram/xhs/tool/icons/jms.webp | Bin 0 -> 1750 bytes .../miniprogram/xhs/tool/icons/lineageos.webp | Bin 0 -> 798 bytes apps/miniprogram/xhs/tool/icons/lisa.webp | Bin 0 -> 1252 bytes apps/miniprogram/xhs/tool/icons/mihomo.webp | Bin 0 -> 2858 bytes apps/miniprogram/xhs/tool/icons/mini-pc.webp | Bin 0 -> 370 bytes apps/miniprogram/xhs/tool/icons/namesilo.webp | Bin 0 -> 942 bytes .../xhs/tool/icons/nomad-book.webp | Bin 0 -> 832 bytes apps/miniprogram/xhs/tool/icons/nomadcna.webp | Bin 0 -> 1520 bytes .../miniprogram/xhs/tool/icons/nomadlist.webp | Bin 0 -> 600 bytes apps/miniprogram/xhs/tool/icons/nomadro.webp | Bin 0 -> 3394 bytes .../xhs/tool/icons/nowpayments.webp | Bin 0 -> 236 bytes apps/miniprogram/xhs/tool/icons/obs.webp | Bin 0 -> 1212 bytes apps/miniprogram/xhs/tool/icons/okx.webp | Bin 0 -> 926 bytes apps/miniprogram/xhs/tool/icons/paypal.webp | Bin 0 -> 616 bytes .../xhs/tool/icons/proxy-cheap.webp | Bin 0 -> 1000 bytes apps/miniprogram/xhs/tool/icons/qcloud.webp | Bin 0 -> 1486 bytes apps/miniprogram/xhs/tool/icons/racknerd.webp | Bin 0 -> 776 bytes apps/miniprogram/xhs/tool/index.html | 129 + apps/miniprogram/xhs/tool/nav-data.js | 586 +++ apps/miniprogram/xhs/tool/styles.css | 944 ++++ apps/navmini/src/App.tsx | 78 +- apps/navmini/src/styles/global.css | 253 +- apps/nomadvip/app/api/pay/route.ts | 65 +- .../components/content/EbookViewer.module.css | 345 +- .../app/components/content/EbookViewer.tsx | 37 +- apps/nomadvip/app/data/vip.mock.ts | 2 +- apps/nomadvip/app/globals.css | 67 +- apps/nomadvip/app/layout.tsx | 4 +- apps/nomadvip/app/lib/ebook.ts | 36 +- apps/nomadvip/app/lib/remoteConfigBridge.ts | 40 + apps/nomadvip/app/lib/triggerPay.ts | 50 +- apps/nomadvip/app/providers/ThemeProvider.tsx | 30 +- apps/nomadvip/app/theme-init.ts | 21 +- .../nomadvip/app/vip/components/VipHeader.tsx | 33 +- .../app/vip/components/landing/LandingCTA.tsx | 17 +- .../vip/components/landing/LandingHero.tsx | 7 +- .../app/vip/components/vip.module.css | 141 +- apps/nomadvip/lib/content/ebook.ts | 29 +- .../frontend/src/app/book/ebook-globals.css | 186 +- .../nomadweb/frontend/src/app/book/layout.tsx | 2 +- .../frontend/src/app/book/thanks/page.tsx | 5 +- .../frontend/src/app/changelog/page.tsx | 7 +- .../src/app/destinations/[slug]/page.tsx | 3 +- apps/nomadweb/frontend/src/app/error.tsx | 5 +- apps/nomadweb/frontend/src/app/globals.css | 2 +- apps/nomadweb/frontend/src/app/login/page.tsx | 10 +- apps/nomadweb/frontend/src/app/not-found.tsx | 11 +- .../frontend/src/app/privacy/page.tsx | 3 +- .../frontend/src/app/profile/page.tsx | 45 +- apps/nomadweb/frontend/src/app/tools/page.tsx | 5 +- .../frontend/src/components/AboutClient.tsx | 9 +- .../src/components/AiAssistantClient.tsx | 11 +- .../src/components/BlogDetailClient.tsx | 9 +- .../frontend/src/components/ChatClient.tsx | 15 +- .../src/components/ChatThreadClient.tsx | 15 +- .../frontend/src/components/Community.tsx | 7 +- .../src/components/CommunityHubClient.tsx | 11 +- .../src/components/CommunityNewClient.tsx | 11 +- .../frontend/src/components/CompareClient.tsx | 21 +- .../frontend/src/components/CompareModal.tsx | 5 +- .../src/components/ContentSubmitClient.tsx | 9 +- .../frontend/src/components/CookieConsent.tsx | 5 +- .../frontend/src/components/DatingClient.tsx | 29 +- .../src/components/DatingLikesClient.tsx | 11 +- .../components/DestinationDetailClient.tsx | 7 +- .../src/components/DestinationMatcher.tsx | 7 +- .../frontend/src/components/Destinations.tsx | 3 +- .../src/components/DigitalCourseClient.tsx | 13 +- .../src/components/DigitalDayClient.tsx | 9 +- .../src/components/DigitalHomeClient.tsx | 11 +- .../src/components/DigitalJobsClient.tsx | 9 +- .../src/components/DigitalLessonClient.tsx | 15 +- .../src/components/DiscussionDetailClient.tsx | 3 +- .../frontend/src/components/FAQSection.tsx | 9 +- .../src/components/FeedbackClient.tsx | 5 +- .../src/components/FeedbackWidget.tsx | 3 +- .../frontend/src/components/Footer.tsx | 47 +- .../frontend/src/components/GigPostClient.tsx | 11 +- .../frontend/src/components/GigsClient.tsx | 15 +- .../frontend/src/components/GlobalSearch.tsx | 3 +- .../frontend/src/components/JoinClient.tsx | 13 +- .../src/components/JoinPaidClient.tsx | 11 +- .../src/components/KeyboardShortcuts.tsx | 7 +- .../frontend/src/components/Lifestyle.tsx | 5 +- .../src/components/MeetupLiveClient.tsx | 15 +- .../frontend/src/components/MeetupsClient.tsx | 19 +- .../src/components/MeetupsHostClient.tsx | 11 +- .../src/components/MemberMapClient.tsx | 13 +- .../src/components/MemberProfileClient.tsx | 9 +- .../src/components/MovePlanClient.tsx | 15 +- .../frontend/src/components/Navbar.tsx | 102 +- .../src/components/NextStopClient.tsx | 5 +- .../frontend/src/components/NomadDigest.tsx | 11 +- .../components/NotificationSettingsClient.tsx | 5 +- .../src/components/NotificationsClient.tsx | 15 +- .../frontend/src/components/PricingClient.tsx | 7 +- .../src/components/RecentlyViewed.tsx | 5 +- .../frontend/src/components/ReportClient.tsx | 19 +- .../frontend/src/components/SectionNav.tsx | 3 +- .../src/components/ServicesClient.tsx | 5 +- .../frontend/src/components/SiteShell.tsx | 5 +- .../frontend/src/components/StaticPage.tsx | 9 +- .../src/components/ToolRunnerClient.tsx | 9 +- .../frontend/src/components/ToolsStrip.tsx | 3 +- .../frontend/src/components/TripPlanner.tsx | 9 +- .../src/components/VideoDetailClient.tsx | 5 +- .../frontend/src/components/VideosClient.tsx | 5 +- .../frontend/src/components/VisaWizard.tsx | 9 +- .../frontend/src/components/WorldMap.tsx | 7 +- .../src/components/ebook/BuyEbook.tsx | 3 +- .../src/components/ebook/CoverPage.tsx | 9 +- .../src/components/ebook/LocaleSwitcher.tsx | 27 +- .../src/components/ebook/Providers.tsx | 1 + .../src/components/ebook/ThemeToggle.tsx | 34 +- apps/nomadweb/frontend/src/lib/authNext.ts | 22 +- .../frontend/src/lib/communityPath.ts | 98 + apps/payjsapi/app/config.py | 14 +- apps/payjsapi/app/payment/creem.py | 118 + apps/payjsapi/app/payment/factory.py | 44 +- apps/payjsapi/app/payment/nowpayments.py | 109 + apps/payjsapi/app/routers/nomadvip.py | 27 +- components/locale-provider.tsx | 2 +- components/module-boundary.tsx | 15 + components/module-gate.tsx | 71 + components/portal-topbar.module.css | 78 + components/portal-topbar.tsx | 61 + components/sections/hero.tsx | 42 +- components/social-follow.module.css | 190 + components/social-follow.tsx | 141 + components/theme-provider.tsx | 95 + components/theme-toggle.tsx | 20 + components/umami-analytics.tsx | 3 +- content/book/book.json | 73 + content/book/chapters/00-preface.md | 31 + content/book/chapters/01-first-remote.md | 39 + content/book/chapters/02-chiangmai.md | 44 + content/book/chapters/03-gear.md | 45 + content/book/chapters/04-homelab.md | 48 + content/book/chapters/05-network.md | 59 + content/book/chapters/06-epilogue.md | 49 + content/book/en/book.json | 73 + content/book/features.json | 94 + content/book/site.json | 8 + data/remote-config.json | 26 + deploy/README.md | 72 +- deploy/observability/README.md | 69 +- deploy/observability/_upload_next_deploy.py | 125 + deploy/observability/healthcheck.sh | 20 +- deploy/observability/notify-ntfy.sh | 4 +- lib/admin-auth.ts | 67 + lib/i18n.ts | 224 +- lib/ntfy.ts | 53 + lib/remote-config-store.ts | 31 + lib/remote-config.ts | 98 + lib/use-remote-config.ts | 91 + next.config.ts | 13 + package.json | 1 + packages/pb/src/index.ts | 18 +- packages/sdk/package.json | 2 +- packages/sdk/src/index.ts | 44 +- packages/sdk/src/remote-config.ts | 24 + pnpm-lock.yaml | 108 + public/wechat-oa-qr.png | Bin 0 -> 775 bytes scripts/fix-community-paths.mjs | 116 + scripts/fix-miniprogram-imports.mjs | 88 + tsconfig.json | 1 + 452 files changed, 34770 insertions(+), 1498 deletions(-) create mode 100644 .cursor/rules/remote-config-offline.mdc create mode 100644 .env.example create mode 100644 app/admin/admin-shell.tsx create mode 100644 app/admin/analytics/page.tsx create mode 100644 app/admin/config/page.tsx create mode 100644 app/admin/miniprogram/page.tsx create mode 100644 app/admin/ops/page.tsx create mode 100644 app/admin/orders/page.tsx create mode 100644 app/admin/users/page.tsx create mode 100644 app/admin/verticals/page.tsx create mode 100644 app/api/admin/analytics/route.ts create mode 100644 app/api/admin/config/route.ts create mode 100644 app/api/admin/login/route.ts create mode 100644 app/api/admin/logout/route.ts create mode 100644 app/api/admin/notify/route.ts create mode 100644 app/api/admin/orders/route.ts create mode 100644 app/api/admin/overview/route.ts create mode 100644 app/api/admin/session/route.ts create mode 100644 app/api/admin/users/route.ts create mode 100644 app/api/config/route.ts create mode 100644 app/api/health/route.ts rename app/vip/{ebook/cloudphone => ebook-cloudphone}/page.tsx (100%) create mode 100644 app/vip/ebook-read/page.tsx create mode 100644 app/vip/ebook/VipEbookShell.tsx create mode 100644 app/vip/ebook/open/page.tsx create mode 100644 app/vip/lib/loadVipEbookBook.ts create mode 100644 app/vip/lib/resolveVipDataFile.ts create mode 100644 app/vip/lib/vipPath.ts create mode 100644 apps/api/app/wx_virtual_pay.py create mode 100644 apps/ebook/src/components/BookRoutes.tsx create mode 100644 apps/miniprogram/README.md create mode 100644 apps/miniprogram/babel.config.js create mode 100644 apps/miniprogram/config/index.ts create mode 100644 apps/miniprogram/package.json create mode 100644 apps/miniprogram/project.config.json create mode 100644 apps/miniprogram/project.tt.json create mode 100644 apps/miniprogram/src/app.config.ts create mode 100644 apps/miniprogram/src/app.scss create mode 100644 apps/miniprogram/src/app.tsx create mode 100644 apps/miniprogram/src/assets/icons/1psim.webp create mode 100644 apps/miniprogram/src/assets/icons/3x-ui.webp create mode 100644 apps/miniprogram/src/assets/icons/9esim.webp create mode 100644 apps/miniprogram/src/assets/icons/aapanel.webp create mode 100644 apps/miniprogram/src/assets/icons/action-cam.webp create mode 100644 apps/miniprogram/src/assets/icons/adsense.webp create mode 100644 apps/miniprogram/src/assets/icons/ai-glasses.webp create mode 100644 apps/miniprogram/src/assets/icons/aliyun.webp create mode 100644 apps/miniprogram/src/assets/icons/bmc.webp create mode 100644 apps/miniprogram/src/assets/icons/bwh.webp create mode 100644 apps/miniprogram/src/assets/icons/chatgpt.webp create mode 100644 apps/miniprogram/src/assets/icons/cloud-phone.webp create mode 100644 apps/miniprogram/src/assets/icons/cloudflare.webp create mode 100644 apps/miniprogram/src/assets/icons/colocrossing.webp create mode 100644 apps/miniprogram/src/assets/icons/creem.webp create mode 100644 apps/miniprogram/src/assets/icons/drone.webp create mode 100644 apps/miniprogram/src/assets/icons/dsx.webp create mode 100644 apps/miniprogram/src/assets/icons/ffmpeg.webp create mode 100644 apps/miniprogram/src/assets/icons/frp.webp create mode 100644 apps/miniprogram/src/assets/icons/ga.webp create mode 100644 apps/miniprogram/src/assets/icons/gpu.webp create mode 100644 apps/miniprogram/src/assets/icons/grok.webp create mode 100644 apps/miniprogram/src/assets/icons/iproyal.webp create mode 100644 apps/miniprogram/src/assets/icons/jms.webp create mode 100644 apps/miniprogram/src/assets/icons/lineageos.webp create mode 100644 apps/miniprogram/src/assets/icons/lisa.webp create mode 100644 apps/miniprogram/src/assets/icons/mihomo.webp create mode 100644 apps/miniprogram/src/assets/icons/mini-pc.webp create mode 100644 apps/miniprogram/src/assets/icons/namesilo.webp create mode 100644 apps/miniprogram/src/assets/icons/nomad-book.webp create mode 100644 apps/miniprogram/src/assets/icons/nomadcna.webp create mode 100644 apps/miniprogram/src/assets/icons/nomadlist.webp create mode 100644 apps/miniprogram/src/assets/icons/nomadro.webp create mode 100644 apps/miniprogram/src/assets/icons/nowpayments.webp create mode 100644 apps/miniprogram/src/assets/icons/obs.webp create mode 100644 apps/miniprogram/src/assets/icons/okx.webp create mode 100644 apps/miniprogram/src/assets/icons/paypal.webp create mode 100644 apps/miniprogram/src/assets/icons/proxy-cheap.webp create mode 100644 apps/miniprogram/src/assets/icons/qcloud.webp create mode 100644 apps/miniprogram/src/assets/icons/racknerd.webp create mode 100644 apps/miniprogram/src/components/Chrome.tsx create mode 100644 apps/miniprogram/src/components/DestCard.tsx create mode 100644 apps/miniprogram/src/components/DestinationsSection.tsx create mode 100644 apps/miniprogram/src/components/MarkdownView.scss create mode 100644 apps/miniprogram/src/components/MarkdownView.tsx create mode 100644 apps/miniprogram/src/components/MiniModuleGate.tsx create mode 100644 apps/miniprogram/src/components/PayResultSheet.scss create mode 100644 apps/miniprogram/src/components/PayResultSheet.tsx create mode 100644 apps/miniprogram/src/components/ReaderSettings.scss create mode 100644 apps/miniprogram/src/components/ReaderSettings.tsx create mode 100644 apps/miniprogram/src/data/homeStatic.ts create mode 100644 apps/miniprogram/src/data/links.json create mode 100644 apps/miniprogram/src/data/localCatalog.ts create mode 100644 apps/miniprogram/src/data/offlineBook.ts create mode 100644 apps/miniprogram/src/data/remoteConfig.defaults.ts create mode 100644 apps/miniprogram/src/modules/index.ts create mode 100644 apps/miniprogram/src/modules/reader/constants.ts create mode 100644 apps/miniprogram/src/modules/reader/index.ts create mode 100644 apps/miniprogram/src/modules/reader/scrollJump.ts create mode 100644 apps/miniprogram/src/pages/book/index.config.ts create mode 100644 apps/miniprogram/src/pages/book/index.scss create mode 100644 apps/miniprogram/src/pages/book/index.tsx create mode 100644 apps/miniprogram/src/pages/community/index.config.ts create mode 100644 apps/miniprogram/src/pages/community/index.scss create mode 100644 apps/miniprogram/src/pages/community/index.tsx create mode 100644 apps/miniprogram/src/pages/destination/index.config.ts create mode 100644 apps/miniprogram/src/pages/destination/index.scss create mode 100644 apps/miniprogram/src/pages/destination/index.tsx create mode 100644 apps/miniprogram/src/pages/destinations/index.config.ts create mode 100644 apps/miniprogram/src/pages/destinations/index.scss create mode 100644 apps/miniprogram/src/pages/destinations/index.tsx create mode 100644 apps/miniprogram/src/pages/index/index.config.ts create mode 100644 apps/miniprogram/src/pages/index/index.scss create mode 100644 apps/miniprogram/src/pages/index/index.tsx create mode 100644 apps/miniprogram/src/pages/meetups/index.config.ts create mode 100644 apps/miniprogram/src/pages/meetups/index.scss create mode 100644 apps/miniprogram/src/pages/meetups/index.tsx create mode 100644 apps/miniprogram/src/pages/mine/index.config.ts create mode 100644 apps/miniprogram/src/pages/mine/index.scss create mode 100644 apps/miniprogram/src/pages/mine/index.tsx create mode 100644 apps/miniprogram/src/pages/nav/index.config.ts create mode 100644 apps/miniprogram/src/pages/nav/index.scss create mode 100644 apps/miniprogram/src/pages/nav/index.tsx create mode 100644 apps/miniprogram/src/pages/reader/index.config.ts create mode 100644 apps/miniprogram/src/pages/reader/index.scss create mode 100644 apps/miniprogram/src/pages/reader/index.tsx create mode 100644 apps/miniprogram/src/pages/vip/index.config.ts create mode 100644 apps/miniprogram/src/pages/vip/index.scss create mode 100644 apps/miniprogram/src/pages/vip/index.tsx create mode 100644 apps/miniprogram/src/services/api.ts create mode 100644 apps/miniprogram/src/services/ebookApi.ts create mode 100644 apps/miniprogram/src/services/remoteConfig.ts create mode 100644 apps/miniprogram/src/styles/ebook.scss create mode 100644 apps/miniprogram/src/styles/h5-theme.scss create mode 100644 apps/miniprogram/src/utils/communityRequest.ts create mode 100644 apps/miniprogram/src/utils/config.ts create mode 100644 apps/miniprogram/src/utils/ebookPayFlow.ts create mode 100644 apps/miniprogram/src/utils/ebookRequest.ts create mode 100644 apps/miniprogram/src/utils/imageSizeCache.ts create mode 100644 apps/miniprogram/src/utils/markdown.ts create mode 100644 apps/miniprogram/src/utils/pay.ts create mode 100644 apps/miniprogram/src/utils/payFeedback.ts create mode 100644 apps/miniprogram/src/utils/payFlow.ts create mode 100644 apps/miniprogram/src/utils/readerPrefs.ts create mode 100644 apps/miniprogram/src/utils/readingProgress.ts create mode 100644 apps/miniprogram/src/utils/request.ts create mode 100644 apps/miniprogram/src/utils/track.ts create mode 100644 apps/miniprogram/src/utils/virtualPay.ts create mode 100644 apps/miniprogram/tsconfig.json create mode 100644 apps/miniprogram/xhs/release/app.js create mode 100644 apps/miniprogram/xhs/release/book/app.js create mode 100644 apps/miniprogram/xhs/release/book/book-data.js create mode 100644 apps/miniprogram/xhs/release/book/index.html create mode 100644 apps/miniprogram/xhs/release/book/markdown.js create mode 100644 apps/miniprogram/xhs/release/book/styles.css create mode 100644 apps/miniprogram/xhs/release/book/xhs-bridge.js create mode 100644 apps/miniprogram/xhs/release/icons/1psim.webp create mode 100644 apps/miniprogram/xhs/release/icons/3x-ui.webp create mode 100644 apps/miniprogram/xhs/release/icons/9esim.webp create mode 100644 apps/miniprogram/xhs/release/icons/aapanel.webp create mode 100644 apps/miniprogram/xhs/release/icons/action-cam.webp create mode 100644 apps/miniprogram/xhs/release/icons/adsense.webp create mode 100644 apps/miniprogram/xhs/release/icons/ai-glasses.webp create mode 100644 apps/miniprogram/xhs/release/icons/aliyun.webp create mode 100644 apps/miniprogram/xhs/release/icons/bmc.webp create mode 100644 apps/miniprogram/xhs/release/icons/bwh.webp create mode 100644 apps/miniprogram/xhs/release/icons/chatgpt.webp create mode 100644 apps/miniprogram/xhs/release/icons/cloud-phone.webp create mode 100644 apps/miniprogram/xhs/release/icons/cloudflare.webp create mode 100644 apps/miniprogram/xhs/release/icons/colocrossing.webp create mode 100644 apps/miniprogram/xhs/release/icons/creem.webp create mode 100644 apps/miniprogram/xhs/release/icons/drone.webp create mode 100644 apps/miniprogram/xhs/release/icons/dsx.webp create mode 100644 apps/miniprogram/xhs/release/icons/ffmpeg.webp create mode 100644 apps/miniprogram/xhs/release/icons/frp.webp create mode 100644 apps/miniprogram/xhs/release/icons/ga.webp create mode 100644 apps/miniprogram/xhs/release/icons/gpu.webp create mode 100644 apps/miniprogram/xhs/release/icons/grok.webp create mode 100644 apps/miniprogram/xhs/release/icons/iproyal.webp create mode 100644 apps/miniprogram/xhs/release/icons/jms.webp create mode 100644 apps/miniprogram/xhs/release/icons/lineageos.webp create mode 100644 apps/miniprogram/xhs/release/icons/lisa.webp create mode 100644 apps/miniprogram/xhs/release/icons/mihomo.webp create mode 100644 apps/miniprogram/xhs/release/icons/mini-pc.webp create mode 100644 apps/miniprogram/xhs/release/icons/namesilo.webp create mode 100644 apps/miniprogram/xhs/release/icons/nomad-book.webp create mode 100644 apps/miniprogram/xhs/release/icons/nomadcna.webp create mode 100644 apps/miniprogram/xhs/release/icons/nomadlist.webp create mode 100644 apps/miniprogram/xhs/release/icons/nomadro.webp create mode 100644 apps/miniprogram/xhs/release/icons/nowpayments.webp create mode 100644 apps/miniprogram/xhs/release/icons/obs.webp create mode 100644 apps/miniprogram/xhs/release/icons/okx.webp create mode 100644 apps/miniprogram/xhs/release/icons/paypal.webp create mode 100644 apps/miniprogram/xhs/release/icons/proxy-cheap.webp create mode 100644 apps/miniprogram/xhs/release/icons/qcloud.webp create mode 100644 apps/miniprogram/xhs/release/icons/racknerd.webp create mode 100644 apps/miniprogram/xhs/release/index.html create mode 100644 apps/miniprogram/xhs/release/styles.css create mode 100644 apps/miniprogram/xhs/scripts/assemble.py create mode 100644 apps/miniprogram/xhs/scripts/pack.py create mode 100644 apps/miniprogram/xhs/scripts/sync_data.py create mode 100644 apps/miniprogram/xhs/tool/app.js create mode 100644 apps/miniprogram/xhs/tool/book-app.js create mode 100644 apps/miniprogram/xhs/tool/book-styles.css create mode 100644 apps/miniprogram/xhs/tool/book.html create mode 100644 apps/miniprogram/xhs/tool/book/book-data.js create mode 100644 apps/miniprogram/xhs/tool/book/markdown.js create mode 100644 apps/miniprogram/xhs/tool/book/xhs-bridge.js create mode 100644 apps/miniprogram/xhs/tool/icons/1psim.webp create mode 100644 apps/miniprogram/xhs/tool/icons/3x-ui.webp create mode 100644 apps/miniprogram/xhs/tool/icons/9esim.webp create mode 100644 apps/miniprogram/xhs/tool/icons/aapanel.webp create mode 100644 apps/miniprogram/xhs/tool/icons/action-cam.webp create mode 100644 apps/miniprogram/xhs/tool/icons/adsense.webp create mode 100644 apps/miniprogram/xhs/tool/icons/ai-glasses.webp create mode 100644 apps/miniprogram/xhs/tool/icons/aliyun.webp create mode 100644 apps/miniprogram/xhs/tool/icons/bmc.webp create mode 100644 apps/miniprogram/xhs/tool/icons/bwh.webp create mode 100644 apps/miniprogram/xhs/tool/icons/chatgpt.webp create mode 100644 apps/miniprogram/xhs/tool/icons/cloud-phone.webp create mode 100644 apps/miniprogram/xhs/tool/icons/cloudflare.webp create mode 100644 apps/miniprogram/xhs/tool/icons/colocrossing.webp create mode 100644 apps/miniprogram/xhs/tool/icons/creem.webp create mode 100644 apps/miniprogram/xhs/tool/icons/drone.webp create mode 100644 apps/miniprogram/xhs/tool/icons/dsx.webp create mode 100644 apps/miniprogram/xhs/tool/icons/ffmpeg.webp create mode 100644 apps/miniprogram/xhs/tool/icons/frp.webp create mode 100644 apps/miniprogram/xhs/tool/icons/ga.webp create mode 100644 apps/miniprogram/xhs/tool/icons/gpu.webp create mode 100644 apps/miniprogram/xhs/tool/icons/grok.webp create mode 100644 apps/miniprogram/xhs/tool/icons/iproyal.webp create mode 100644 apps/miniprogram/xhs/tool/icons/jms.webp create mode 100644 apps/miniprogram/xhs/tool/icons/lineageos.webp create mode 100644 apps/miniprogram/xhs/tool/icons/lisa.webp create mode 100644 apps/miniprogram/xhs/tool/icons/mihomo.webp create mode 100644 apps/miniprogram/xhs/tool/icons/mini-pc.webp create mode 100644 apps/miniprogram/xhs/tool/icons/namesilo.webp create mode 100644 apps/miniprogram/xhs/tool/icons/nomad-book.webp create mode 100644 apps/miniprogram/xhs/tool/icons/nomadcna.webp create mode 100644 apps/miniprogram/xhs/tool/icons/nomadlist.webp create mode 100644 apps/miniprogram/xhs/tool/icons/nomadro.webp create mode 100644 apps/miniprogram/xhs/tool/icons/nowpayments.webp create mode 100644 apps/miniprogram/xhs/tool/icons/obs.webp create mode 100644 apps/miniprogram/xhs/tool/icons/okx.webp create mode 100644 apps/miniprogram/xhs/tool/icons/paypal.webp create mode 100644 apps/miniprogram/xhs/tool/icons/proxy-cheap.webp create mode 100644 apps/miniprogram/xhs/tool/icons/qcloud.webp create mode 100644 apps/miniprogram/xhs/tool/icons/racknerd.webp create mode 100644 apps/miniprogram/xhs/tool/index.html create mode 100644 apps/miniprogram/xhs/tool/nav-data.js create mode 100644 apps/miniprogram/xhs/tool/styles.css create mode 100644 apps/nomadvip/app/lib/remoteConfigBridge.ts create mode 100644 apps/nomadweb/frontend/src/lib/communityPath.ts create mode 100644 apps/payjsapi/app/payment/creem.py create mode 100644 apps/payjsapi/app/payment/nowpayments.py create mode 100644 components/module-boundary.tsx create mode 100644 components/module-gate.tsx create mode 100644 components/portal-topbar.module.css create mode 100644 components/portal-topbar.tsx create mode 100644 components/social-follow.module.css create mode 100644 components/social-follow.tsx create mode 100644 components/theme-provider.tsx create mode 100644 components/theme-toggle.tsx create mode 100644 content/book/book.json create mode 100644 content/book/chapters/00-preface.md create mode 100644 content/book/chapters/01-first-remote.md create mode 100644 content/book/chapters/02-chiangmai.md create mode 100644 content/book/chapters/03-gear.md create mode 100644 content/book/chapters/04-homelab.md create mode 100644 content/book/chapters/05-network.md create mode 100644 content/book/chapters/06-epilogue.md create mode 100644 content/book/en/book.json create mode 100644 content/book/features.json create mode 100644 content/book/site.json create mode 100644 data/remote-config.json create mode 100644 deploy/observability/_upload_next_deploy.py create mode 100644 lib/admin-auth.ts create mode 100644 lib/ntfy.ts create mode 100644 lib/remote-config-store.ts create mode 100644 lib/remote-config.ts create mode 100644 lib/use-remote-config.ts create mode 100644 packages/sdk/src/remote-config.ts create mode 100644 public/wechat-oa-qr.png create mode 100644 scripts/fix-community-paths.mjs create mode 100644 scripts/fix-miniprogram-imports.mjs diff --git a/.cursor/rules/nomadro-charter.mdc b/.cursor/rules/nomadro-charter.mdc index 3256cb9..e1a9857 100644 --- a/.cursor/rules/nomadro-charter.mdc +++ b/.cursor/rules/nomadro-charter.mdc @@ -5,18 +5,32 @@ alwaysApply: true # Nomadro 章程 +## 远程配置 + 离线兜底(强制) + +- 前端内容/元素/页面开关与文案 → 后端配置,`/admin/config` 可改 +- 网络异常、小红书纯前端工具 → 必须包内/本地 catalog 兜底(见 `.cursor/rules/remote-config-offline.mdc`) + ## 定位 -`nomadro` 统一集成四个垂直项目,集成优先于各自优化;门户优化完成后再反哺垂直仓。 +`nomadro` **统一集成**四个垂直项目:整合优先于各自优化;统一页面、统一规范、统一管理后台。 -| 垂直 | 本仓路径 | 门户入口 | 说明 | -|------|----------|----------|------| -| 导航 navmini | `apps/navmini` | `/nav` | H5 + 小程序 | -| 电子书 ebook | `apps/ebook` | `/book` | Next + FastAPI | -| 社群 nomadweb | `apps/nomadweb` | `/community` | Next + FastAPI | -| 私域会员 nomadvip | `apps/nomadvip` | `/vip` | Next + payjsapi | +### 端形态(强制对齐) -支付后端:`apps/payjsapi`(FastAPI)。数据库默认 PocketBase。 +每个垂直 + 本门户默认都是: + +1. **主端 PC / H5**(Next.js) +2. **子项目小程序**:微信 / 抖音 / 小红书(Taro + React) + +| 垂直 | 本仓路径 | PC/H5 门户入口 | 小程序子项目(参考) | +|------|----------|----------------|----------------------| +| 导航 navmini | `apps/navmini` | `/nav` | `weapp` / `tt` / `xhs` | +| 电子书 ebook | `apps/ebook` | `/book` | `wemini` / `dymini` / `redmini` | +| 社群 nomadweb | `apps/nomadweb` | `/community` | `wemini` / `dymini` / `redmini` | +| 私域会员 nomadvip | `apps/nomadvip` | `/vip` | 并入 `apps/miniprogram` VIP 页 | +| **门户 nomadro** | 本仓根 | `/` + 上表挂载 | **`apps/miniprogram`**(三端统一整合) | + +支付后端:`apps/payjsapi`(FastAPI)。数据库默认 PocketBase。 +整合方式:同进程 App Router 挂载垂直源码,**禁止** iframe / 反代嵌套。小程序以垂直仓为参考,能力收敛进 `apps/miniprogram`。 ## 默认技术栈 diff --git a/.cursor/rules/remote-config-offline.mdc b/.cursor/rules/remote-config-offline.mdc new file mode 100644 index 0000000..6dad69d --- /dev/null +++ b/.cursor/rules/remote-config-offline.mdc @@ -0,0 +1,37 @@ +--- +description: 前端内容后台可配;网络异常与纯前端端必须离线兜底 +alwaysApply: true +--- + +# 远程配置 + 离线兜底 + +## 强制 + +1. **前端内容/元素/页面须可被后端配置** + - 文案、入口开关、Tab/模块显隐、运营位、价格展示、功能 flag 等,默认走远程配置(API / PocketBase / 统一 `remote-config`)。 + - **管理后台**(`/admin`)必须能动态开关、修改;禁止只写死在前端且无法运营改。 + - 允许「默认值内置在客户端」作为离线/首屏种子,但线上以服务端配置覆盖。 + +2. **网络异常必须有离线数据兜底** + - 列表/详情/配置请求:失败、超时、空响应 → 使用打包内或本地缓存的 catalog(如 `localCatalog`、`links.json`、小红书 `book-data.js`)。 + - 用户可感知:可标「离线模式 / 本地数据」,但页面不能白屏崩掉。 + +3. **纯前端端(尤其小红书小工具 / redmini / xhs minitool)** + - 默认按**离线优先**:构建时把内容打进包(assemble/pack);有网再尝试拉配置刷新缓存。 + - 禁止假设运行时一定能访问业务 API。 + +## 实现约定 + +| 层 | 约定 | +|---|---| +| 配置键 | 统一 `NomadroRemoteConfig`(modules/pages/flags/copy) | +| 拉取 | `GET /v1/config` 或门户 `/api/config`;客户端缓存 `storage` | +| 管理 | `/admin/config` 读写;鉴权同后台会话 | +| 兜底顺序 | 内存缓存 → localStorage/Storage → 包内静态 JSON → 最小硬编码 | +| 垂直参考 | `nomadweb` `localCatalog`、`navmini` links、`ebook/redmini` book-data | + +## 反模式 + +- 新页面只有硬编码文案、无配置键、后台改不了 +- `fetch` 失败直接空白页、无 fallback +- 小红书工具依赖在线 API 才能打开首页 diff --git a/.cursor/rules/wechat-miniprogram.mdc b/.cursor/rules/wechat-miniprogram.mdc index 16944bf..fa6f5f4 100644 --- a/.cursor/rules/wechat-miniprogram.mdc +++ b/.cursor/rules/wechat-miniprogram.mdc @@ -1,18 +1,21 @@ --- description: 微信/抖音/小红书小程序与 Taro、虚拟支付配置 -globs: "**/wemini/**,**/dymini/**,**/redmini/**,**/weapp/**,**/tt/**,**/xhs/**" +globs: "**/wemini/**,**/dymini/**,**/redmini/**,**/weapp/**,**/tt/**,**/xhs/**,**/miniprogram/**" alwaysApply: false --- # 小程序 / Taro - 框架:Taro + React;UI 优先 Taro UI +- 统一仓:`apps/miniprogram`(三端) +- **远程配置**:模块/文案走 `/api/config`;`/admin/config` 可动态开关 +- **离线兜底**:网络失败用包内 catalog;小红书 minitool **离线优先**(见 `remote-config-offline.mdc`) - 文档:微信 https://developers.weixin.qq.com/miniprogram/dev/framework/ ;Taro https://docs.taro.zone/docs/GETTING-STARTED ;Taro UI https://taro-ui.jd.com - 小红书:https://miniapp-sandbox.xiaohongshu.com/minitool/doc - 抖音:https://developer.open-douyin.com/docs/resource/zh-CN/mini-app/introduction/usage-guide - 虚拟支付(个人主体):https://developers.weixin.qq.com/miniprogram/dev/platform-capabilities/business-capabilities/virtual-payment/person — 部署前按文末清单验收 -## 微信配置(写入环境变量,勿提交到公开 README) +## 微信配置(本项目允许写入 README;运行时仍可用环境变量覆盖) ``` WX_APPID=wxa55815dd741a540d diff --git a/.env.example b/.env.example new file mode 100644 index 0000000..fc103f7 --- /dev/null +++ b/.env.example @@ -0,0 +1,28 @@ +# Copy to .env.local — never commit real secrets + +# Admin panel +NOMADRO_ADMIN_PASSWORD=change-me +NOMADRO_ADMIN_SESSION_SECRET=change-me-session +# Optional PocketBase admin token for /admin/users +# PB_ADMIN_TOKEN= + +# WeChat miniprogram virtual pay (apps/api) +WX_APPID=wxa55815dd741a540d +WX_APPSECRET=bf71025c209e7567d49268bc427ba22b +WX_OFFER_ID=1450642200 +WX_SANDBOX_APPKEY=0wB3HV3sfKVTEgomZ6BIbgsN8Mlbv5Bn +WX_LIVE_APPKEY=CBi5tdkkSWuvkDvWJNnSjrGmeYE3xlsg +# 1=sandbox 0=live +WX_PAY_ENV=1 + +# Observability (production) +# NOMADRO_PUBLIC_ORIGIN=https://nomadro.cn +# NEXT_PUBLIC_UMAMI_WEBSITE_ID= +# NEXT_PUBLIC_UMAMI_SCRIPT_URL=https://umami.nomadro.cn/script.js +# NTFY_BASE_URL=https://ntfy.nomadro.cn +# NTFY_TOPIC=nomadro +# NTFY_TOKEN= + +# Overseas pay (payjsapi) +# CREEM_API_KEY= +# NOWPAYMENTS_API_KEY= diff --git a/AGENTS.md b/AGENTS.md index 85ac481..d6befef 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,7 +1,9 @@ # Nomadro agent notes -Follow `.cursor/rules/*.mdc` (charter, modular-design, UI, payments, deploy, WeChat). +Follow `.cursor/rules/*.mdc` (charter, modular-design, UI, payments, deploy, WeChat, **remote-config-offline**). + +Remote UI config: frontend modules/copy/flags come from backend (`/api/config`, `/admin/config`); always ship offline defaults. Xiaohongshu / pure-frontend packs must work offline. Integrate verticals via `node scripts/integrate-apps.mjs` after structural changes under `apps/`. -Do not commit secrets (`.env.local`, live payment keys). WeChat keys live in env / wechat rule for agent use only. +Do not commit secrets in git history for production if avoidable; this project may document WeChat keys in README per owner request. diff --git a/README.md b/README.md index 5451d59..a48bcb5 100644 --- a/README.md +++ b/README.md @@ -1,86 +1,148 @@ # Nomadro -中文数字游民操作系统(主域 [nomadro.cn](https://nomadro.cn))。本仓把四个垂直产品统一进一个 Next 门户,再逐步统一 FastAPI / PocketBase / 支付 / 管理后台 / 小程序。 +中文数字游民操作系统(主域 [nomadro.cn](https://nomadro.cn))。 -## 四个垂直 × 门户入口 +**整合优先**:把四个垂直产品统一成「一套 PC/H5 门户 + 一套三端小程序 + 一套管理后台」,规范/配置/支付/主题一致。 -| 产品 | 源码 | 门户路径 | 小程序 | -|------|------|----------|--------| -| 出海导航 | `apps/navmini` | `/nav` | weapp / tt / xhs | -| 数字游民小册 | `apps/ebook` | `/book` | wemini / dymini / redmini | -| 旅居社群 | `apps/nomadweb` | `/community` | wemini / dymini / redmini | -| 私域会员(异度星球) | `apps/nomadvip` | `/vip` | (后续 Taro) | -| 支付网关 | `apps/payjsapi` | FastAPI(`api.*`) | — | +## 端形态(与四个垂直一致) -同进程 App Router 挂载,**禁止 iframe / 反代嵌套**。详见 `apps/README.md`、`.cursor/rules/`。 +| 层 | 技术 | 说明 | +|----|------|------| +| **主端 PC/H5** | Next.js | 门户 `/` 挂载 `/nav` `/book` `/community` `/vip` | +| **子项目小程序** | Taro React | 微信 / 抖音 / 小红书 → `apps/miniprogram`(对照 `apps/*/wemini|dymini|redmini|weapp`) | +| **统一后台** | `/admin` | 编排 + **远程配置**开关页面/文案 | +| **API/SDK** | FastAPI + `@nomadro/sdk` | 给其他项目复用 | + +## 四个垂直 × 门户 × 小程序 + +| 产品 | 源码 | PC/H5 | 垂直小程序参考 | 统一小程序 | +|------|------|-------|----------------|------------| +| 出海导航 | `apps/navmini` | `/nav` | weapp / tt / xhs | `apps/miniprogram` nav | +| 数字游民小册 | `apps/ebook` | `/book` | wemini / dymini / redmini | book + reader + 虚拟支付 | +| 旅居社群 | `apps/nomadweb` | `/community` | wemini / dymini / redmini | community / destinations / meetups | +| 私域会员 | `apps/nomadvip` | `/vip` | (并入统一仓) | vip 页 | +| 支付网关 | `apps/payjsapi` | FastAPI | — | — | + +同进程 App Router 挂载,**禁止 iframe / 反代嵌套**。小程序以垂直仓为参考源做整合。 ## 默认技术栈 -- **Web**:Next.js 16 + React 19(前端)· FastAPI(后端)· PocketBase(数据库) -- **支付**:海外 Creem / NOWPayments;国内 zpay(PC/H5)、xpay(微信内);VIP 现网经 `payjsapi` -- **体验**:深色科技风、日夜主题、emoji/SVG/动效、D3 / three.js / WebGL·PWA 等 -- **i18n**:默认中/英,可扩展日/越/泰等 -- **运维**:Caddy / Docker / Umami / Uptime-Kuma / ntfy / SeaweedFS / webhook -- **Git**:https://git.nomadro.cn (管理员 `hackrobot`) +- **Web**:Next.js · FastAPI · PocketBase +- **支付**:海外 Creem / NOWPayments;国内 zpay(PC/H5)、xpay(微信内);小程序虚拟支付(OfferID) +- **体验**:深色科技风、日/夜 `nomadro-theme`、emoji/SVG/动效、D3 / three / WebGL·PWA +- **i18n**:zh / en / ja / vi / th +- **配置**:`data/remote-config.json` → `/api/config`;`/admin/config` 可改;客户端离线默认兜底 +- **运维**:Caddy / Docker / Umami / Uptime-Kuma / ntfy / SeaweedFS +- **Git**:https://git.nomadro.cn(`hackrobot`)· 生产 `82.157.112.245` ## 本地开发(Windows) ```bash pnpm install +# 复制 .env.example → .env.local,至少设 NOMADRO_ADMIN_PASSWORD pnpm dev ``` -打开: +| 地址 | 用途 | +|------|------| +| http://localhost:3000 | 门户首页(入口受远程配置控制) | +| http://localhost:3000/nav | 出海导航 | +| http://localhost:3000/book | 数字游民小册 | +| http://localhost:3000/community | 旅居社群 | +| http://localhost:3000/vip | 会员深链(开发快捷 / 非公开入口) | +| http://localhost:3000/admin | 统一后台(需登录) | +| http://localhost:3000/admin/config | 模块开关 / 文案 / VIP 价 | +| http://localhost:3000/admin/analytics | 探针图表 / 即时 ntfy | +| http://localhost:3000/api/config | 公开远程配置 JSON | +| http://localhost:3000/api/health | 健康锚点(Uptime-Kuma) | -- http://localhost:3000 -- http://localhost:3000/nav -- http://localhost:3000/book -- http://localhost:3000/community -- http://localhost:3000/vip -- http://localhost:3000/admin - -支付 API(可选): +小程序(**PC/H5 验收通过后再做**): ```bash -cd apps/payjsapi -python -m venv venv -# Windows: .\venv\Scripts\activate -pip install -r requirements.txt -python run.py +cd apps/miniprogram && pnpm install +pnpm dev:weapp # 微信开发者工具打开 dist/weapp · AppID wxa55815dd741a540d +pnpm dev:tt # 抖音开发者工具打开 dist/tt · AppID tt995defe007255b2701 +pnpm build:xhs # 小红书:xhs/release 离线包 → 小红书开发者工具导入 ``` -重新镜像垂直路由到门户(改过 apps 源码结构后): +密钥、Tab、虚拟支付与三端验收细节:[`apps/miniprogram/README.md`](./apps/miniprogram/README.md)。 -```bash -node scripts/integrate-apps.mjs -``` +## 本地验收顺序(推荐) + +先过 **PC/H5**,没问题再逐个验 **微信 → 抖音 → 小红书** 开发者工具。暂不部署线上,除非明确要求。 + +### ① PC / H5(本机浏览器) + +1. [ ] `pnpm dev` 后首页可开,品牌/入口卡片来自 `/api/config`(断网刷新仍有离线默认,不白屏) +2. [ ] `/nav` `/book` `/community` `/vip` 均可打开;日夜主题切换正常 +3. [ ] `/admin` 用 `NOMADRO_ADMIN_PASSWORD` 登录;总览能看到远程配置摘要与四垂直入口 +4. [ ] `/admin/config`:关掉某一模块(如 `book`)→ 刷新对应 PC 页应友好提示「暂时无法打开」;再打开恢复 +5. [ ] 首页入口仅导航 / 小册 / 社群(无公开收费入口);开发模式顶栏可见 VIP / Admin / Config +6. [ ] 社媒弹窗:中文环境公众号二维码;海外倾向 X 关注 +7. [ ] 移动宽度(约 375):各垂直顶栏有 logo 回首页 + 主题/语言等;`/book` 主按钮对比清晰可读 + +### ② 三端小程序(本地开发者工具) + +门户仍可用 `pnpm dev` 提供 `/api/config`;小程序优先打本机或线上 `nomadro.cn/api/config`,失败走包内默认。 + +| 顺序 | 平台 | 命令 | 开发者工具导入目录 | AppID | +|------|------|------|--------------------|-------| +| 1 | 微信 | `pnpm dev:weapp` | `apps/miniprogram/dist/weapp` | `wxa55815dd741a540d` | +| 2 | 抖音 | `pnpm dev:tt` | `apps/miniprogram/dist/tt` | `tt995defe007255b2701` | +| 3 | 小红书 | `pnpm build:xhs` | `apps/miniprogram/xhs/release`(离线优先) | 见小红书后台 / README | + +每端建议勾选: + +1. [ ] 首页能开;模块卡片与远程配置一致;断网/关 API 仍可用离线配置 +2. [ ] Tab:首页 / 导航 / 小册 / 社群 / 我的;导航 links、小册封面→阅读器、社群列表不白屏 +3. [ ] VIP / 小册虚拟支付:沙箱 `WX_PAY_ENV=1`(仅微信;抖音/小红书按各端能力测可测部分) +4. [ ] `/admin/config` 关闭某模块后,对应小程序页显示「已关闭」闸门 + +完整密钥表与支付清单见 [`apps/miniprogram/README.md`](./apps/miniprogram/README.md)。 ## 开发流程(强制) -1. 本地改完并调试确认 -2. 部署到腾讯云 `82.157.112.245`(`ubuntu`)并线上冒烟 -3. 更新本 README / 相关文档 +1. 本地 PC/H5 验收 +2. 本地三端小程序开发者工具验收 +3. 再部署 `82.157.112.245` 并线上冒烟 +4. 更新本 README -当前门户开发分支:`pre1`(远程 `nomadro/pre1`)。 +分支常见:`pre1`。日常门户发布: -## 域名 - -主域 `nomadro.cn`,二级 DNS 在 Cloudflare(`admin` `api` `vip` `pocketbase` `umami` `uptimekuma` `ntfy` `git` `nav` `ebook` …)。需要新子域时再加解析。 - -## 项目结构(简要) - -``` -app/ # 门户路由(/nav /book /community /vip /admin + VIP /api/*) -apps/ # 垂直业务(互不深耦) -packages/ # 共享模块 @nomadro/pay|pb|sdk -components/ lib/ # 门户壳与 i18n -deploy/ # 部署与可观测脚本 -.cursor/rules/ # Agent 开发规范 -scripts/integrate-apps.mjs +```bash +pnpm build +python deploy/observability/_upload_next_deploy.py ``` -共享包说明见 [`packages/README.md`](./packages/README.md)。管理后台:[/admin](http://localhost:3000/admin)。 +观测栈(Umami / Uptime-Kuma / ntfy / SeaweedFS):[`deploy/observability/README.md`](./deploy/observability/README.md)。 +小程序联调依赖线上 `https://nomadro.cn/api/config` 与 `https://api.nomadro.cn`(支付/鉴权)。 + +### 章程落地状态 + +| 项 | 状态 | +|---|---| +| PC/H5 挂载四垂直 | ✅ | +| 模块闸门吃远程配置 | ✅ `ModuleGate` / `MiniModuleGate` | +| 统一主题 + 社媒弹窗 | ✅ | +| 统一后台 + 远程配置 | ✅ `/admin` + `/admin/config` + `/admin/analytics` | +| 观测锚点 / ntfy | ✅ `/api/health` · Umami · Kuma · 配置变更推送 | +| 统一小程序三端(对照垂直整合) | ✅ `apps/miniprogram` | +| 离线兜底 | ✅ catalog / offlineBook / xhs 包 | +| Creem/NOWPayments 适配器 | ✅(需密钥) | +| 备份一键面板 | ⚠️ 脚本在 `deploy/backup` | +| 全量 i18n 渗入垂直 UI | ⚠️ 进行中 | + +### 近期全局升级要点 + +- 全站默认夜间 + `nomadro-theme` 日夜切换(门户 /nav /book /community /vip /admin) +- PC 四垂直 + 小程序页:远程配置开关闸门;VIP 价/CTA/`payEnabled` 跟配置 +- 社群挂载路径用 `communityPath()` 统一前缀(论坛 → `/community/community`) +- 门户社媒关注弹窗:国内公众号 QR(`/wechat-oa-qr.png`)/ 海外 X +- `@nomadro/sdk`:`createNomadroClient`、路由常量、主题键、locales、remote-config 类型 +- 支付分流:国内 zpay / xpay(xorpay);海外 Creem / NOWPayments;小程序虚拟支付见 `apps/api` + `apps/miniprogram` +- 门户 i18n:`zh` / `en` / `ja` / `vi` / `th` +- 备份回滚:见 [`deploy/backup/README.md`](./deploy/backup/README.md) ## 部署 -生产机:`82.157.112.245`。细节见 [`deploy/README.md`](./deploy/README.md)。 +生产机:`82.157.112.245`。细节见 [`deploy/README.md`](./deploy/README.md)。**仅在本地 PC/H5 + 三端小程序验收通过后再上。** diff --git a/app/admin/admin-shell.tsx b/app/admin/admin-shell.tsx new file mode 100644 index 0000000..eb69054 --- /dev/null +++ b/app/admin/admin-shell.tsx @@ -0,0 +1,149 @@ +"use client"; + +import Link from "next/link"; +import { usePathname, useRouter } from "next/navigation"; +import { useCallback, useEffect, useState, type ReactNode } from "react"; +import { ThemeToggle } from "~/components/theme-toggle"; +import styles from "./admin.module.css"; + +const NAV = [ + { href: "/admin", label: "总览", emoji: "📡" }, + { href: "/admin/config", label: "远程配置", emoji: "⚙️" }, + { href: "/admin/users", label: "用户", emoji: "👥" }, + { href: "/admin/orders", label: "订单/支付", emoji: "💳" }, + { href: "/admin/verticals", label: "垂直业务", emoji: "🧩" }, + { href: "/admin/miniprogram", label: "小程序", emoji: "📱" }, + { href: "/admin/analytics", label: "统计", emoji: "📈" }, + { href: "/admin/ops", label: "运维", emoji: "🛠️" }, +] as const; + +export function AdminShell({ children }: { children: ReactNode }) { + const pathname = usePathname(); + const router = useRouter(); + const [ready, setReady] = useState(false); + const [authed, setAuthed] = useState(false); + const [configured, setConfigured] = useState(true); + const [password, setPassword] = useState(""); + const [error, setError] = useState(""); + const [busy, setBusy] = useState(false); + + const check = useCallback(async () => { + const res = await fetch("/api/admin/session", { cache: "no-store" }); + const data = await res.json().catch(() => ({})); + setConfigured(Boolean(data.configured)); + setAuthed(Boolean(data.ok)); + setReady(true); + }, []); + + useEffect(() => { + void check(); + }, [check]); + + async function onLogin(e: React.FormEvent) { + e.preventDefault(); + setBusy(true); + setError(""); + try { + const res = await fetch("/api/admin/login", { + method: "POST", + headers: { "Content-Type": "application/json" }, + body: JSON.stringify({ password }), + }); + const data = await res.json().catch(() => ({})); + if (!res.ok || !data.ok) { + setError(data.error || "登录失败"); + return; + } + setAuthed(true); + setPassword(""); + router.refresh(); + } finally { + setBusy(false); + } + } + + async function onLogout() { + await fetch("/api/admin/logout", { method: "POST" }); + setAuthed(false); + } + + if (!ready) { + return ( +
+

加载会话…

+
+ ); + } + + if (!authed) { + return ( +
+
+

🔐 Nomadro Admin

+

统一管理后台

+

+ {configured + ? "输入管理员密码进入编排面板" + : "请先在 .env.local 配置 NOMADRO_ADMIN_PASSWORD"} +

+
+ setPassword(e.target.value)} + placeholder="管理员密码" + autoComplete="current-password" + disabled={!configured || busy} + /> + {error ?

{error}

: null} + +
+ + ← 返回门户 + +
+
+ ); + } + + return ( +
+
+ +
{children}
+
+
+ ); +} diff --git a/app/admin/admin.module.css b/app/admin/admin.module.css index 3174fb7..bc92c7c 100644 --- a/app/admin/admin.module.css +++ b/app/admin/admin.module.css @@ -1,11 +1,80 @@ .shell { + --admin-bg: #0a0e17; + --admin-card: rgba(17, 24, 39, 0.7); + --admin-text: #f1f5f9; + --admin-muted: #94a3b8; + --admin-accent: #4ecdc4; + --admin-coral: #ff6b6b; + --admin-amber: #ffe66d; + --admin-border: rgba(255, 255, 255, 0.08); + --admin-gradient: linear-gradient(135deg, #ff6b6b 0%, #ffe66d 50%, #4ecdc4 100%); + min-height: 100vh; - padding: 2.5rem 1.25rem 4rem; + padding: 1.25rem 1.25rem 4rem; background: - radial-gradient(ellipse 80% 50% at 50% -20%, #1a3a4a 0%, transparent 55%), - linear-gradient(180deg, #0c0c0f 0%, #12141a 100%); - color: #e8eaed; - font-family: ui-sans-serif, system-ui, sans-serif; + radial-gradient(ellipse 70% 45% at 12% -10%, rgba(255, 107, 107, 0.18), transparent 55%), + radial-gradient(ellipse 60% 40% at 90% 0%, rgba(78, 205, 196, 0.16), transparent 50%), + radial-gradient(ellipse 50% 35% at 50% 100%, rgba(255, 230, 109, 0.08), transparent 55%), + var(--admin-bg); + color: var(--admin-text); + font-family: var(--font-outfit), var(--font-noto-sc), ui-sans-serif, system-ui, sans-serif; + transition: background 0.25s ease, color 0.25s ease; +} + +:global(html.light) .shell { + --admin-bg: #f8fafc; + --admin-card: rgba(255, 255, 255, 0.88); + --admin-text: #0f172a; + --admin-muted: #64748b; + --admin-accent: #0d9488; + --admin-coral: #e11d48; + --admin-amber: #d97706; + --admin-border: rgba(15, 23, 42, 0.08); + --admin-gradient: linear-gradient(135deg, #e11d48 0%, #d97706 50%, #0d9488 100%); + background: + radial-gradient(ellipse 70% 45% at 12% -10%, rgba(225, 29, 72, 0.08), transparent 55%), + radial-gradient(ellipse 60% 40% at 90% 0%, rgba(13, 148, 136, 0.1), transparent 50%), + var(--admin-bg); +} + +.topBar { + max-width: 960px; + margin: 0 auto 1.5rem; + display: flex; + align-items: center; + justify-content: space-between; + gap: 1rem; +} + +.brand { + font-weight: 800; + font-size: 1.15rem; + letter-spacing: -0.02em; + text-decoration: none; + background: var(--admin-gradient); + -webkit-background-clip: text; + background-clip: text; + color: transparent; +} + +.topActions { + display: flex; + align-items: center; + gap: 8px; +} + +.chip { + display: inline-flex; + align-items: center; + min-height: 36px; + padding: 0 12px; + border-radius: 10px; + border: 1px solid rgba(78, 205, 196, 0.28); + background: rgba(78, 205, 196, 0.1); + color: var(--admin-accent); + font-size: 0.8rem; + font-weight: 700; + text-decoration: none; } .hero { @@ -17,18 +86,26 @@ letter-spacing: 0.12em; text-transform: uppercase; font-size: 0.75rem; - color: #f59e0b; + color: var(--admin-accent); margin: 0 0 0.5rem; } .title { font-size: clamp(1.75rem, 4vw, 2.5rem); margin: 0 0 0.5rem; - font-weight: 700; + font-weight: 800; + letter-spacing: -0.02em; +} + +.titleAccent { + background: var(--admin-gradient); + -webkit-background-clip: text; + background-clip: text; + color: transparent; } .sub { - color: #9aa3b2; + color: var(--admin-muted); max-width: 42rem; line-height: 1.55; margin: 0; @@ -43,17 +120,18 @@ } .card { - border: 1px solid rgba(255, 255, 255, 0.08); - background: rgba(255, 255, 255, 0.03); - border-radius: 14px; + border: 1px solid var(--admin-border); + background: var(--admin-card); + border-radius: 16px; padding: 1.15rem 1.2rem; - backdrop-filter: blur(8px); - transition: transform 0.2s ease, border-color 0.2s ease; + backdrop-filter: blur(18px); + transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease; } .card:hover { - transform: translateY(-2px); - border-color: rgba(245, 158, 11, 0.45); + transform: translateY(-3px); + border-color: rgba(78, 205, 196, 0.35); + box-shadow: 0 0 40px rgba(78, 205, 196, 0.12); } .cardTop { @@ -70,11 +148,12 @@ .cardTitle { font-size: 1.05rem; margin: 0; + font-weight: 700; } .cardNote { margin: 0 0 1rem; - color: #9aa3b2; + color: var(--admin-muted); font-size: 0.88rem; line-height: 1.45; min-height: 2.6em; @@ -90,20 +169,26 @@ display: inline-flex; align-items: center; justify-content: center; - min-height: 40px; + min-height: 44px; padding: 0.4rem 0.85rem; - border-radius: 8px; - background: #f59e0b; - color: #111; - font-weight: 600; + border-radius: 10px; + background: var(--admin-accent); + color: #0a0e17; + font-weight: 700; font-size: 0.85rem; text-decoration: none; + transition: opacity 0.15s ease, transform 0.15s ease; +} + +.btn:hover { + opacity: 0.92; + transform: translateY(-1px); } .ghost { background: transparent; - color: #e8eaed; - border: 1px solid rgba(255, 255, 255, 0.18); + color: var(--admin-text); + border: 1px solid var(--admin-border); } .disabled { @@ -115,24 +200,454 @@ max-width: 960px; margin: 2.25rem auto 0; padding: 1.25rem 1.35rem; - border: 1px solid rgba(255, 255, 255, 0.08); - border-radius: 14px; - background: rgba(0, 0, 0, 0.25); + border: 1px solid var(--admin-border); + border-radius: 16px; + background: var(--admin-card); + backdrop-filter: blur(18px); } .metaTitle { margin: 0 0 0.75rem; font-size: 1.05rem; + font-weight: 700; } .metaList { margin: 0; padding-left: 1.1rem; - color: #9aa3b2; + color: var(--admin-muted); line-height: 1.7; } .code { - color: #fbbf24; + color: var(--admin-amber); font-size: 0.85em; } + +.statusRow { + display: flex; + flex-wrap: wrap; + gap: 0.5rem; + margin-top: 1rem; +} + +.pill { + display: inline-flex; + align-items: center; + min-height: 32px; + padding: 0 0.75rem; + border-radius: 999px; + font-size: 0.78rem; + font-weight: 700; + border: 1px solid var(--admin-border); + background: rgba(255, 255, 255, 0.04); +} + +.pillOk { + color: #4ecdc4; + border-color: rgba(78, 205, 196, 0.35); + background: rgba(78, 205, 196, 0.1); +} + +.pillBad { + color: #ff6b6b; + border-color: rgba(255, 107, 107, 0.35); + background: rgba(255, 107, 107, 0.1); +} + +.pillMute { + color: var(--admin-muted); +} + +.ops { + max-width: 960px; + margin: 2rem auto 0; +} + +.opsGrid { + display: grid; + grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); + gap: 0.75rem; + margin-top: 0.85rem; +} + +.opsCard { + display: flex; + flex-direction: column; + gap: 0.25rem; + padding: 0.9rem 0.85rem; + border-radius: 14px; + border: 1px solid var(--admin-border); + background: var(--admin-card); + text-decoration: none; + color: inherit; + transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease; + min-height: 88px; +} + +.opsCard:hover { + transform: translateY(-2px); + border-color: rgba(78, 205, 196, 0.35); + box-shadow: 0 0 28px rgba(78, 205, 196, 0.12); +} + +.opsCard span { + font-size: 1.2rem; +} + +.opsCard strong { + font-size: 0.92rem; +} + +.opsCard em { + font-style: normal; + font-size: 0.75rem; + color: var(--admin-muted); +} + +.frame { + max-width: 1180px; + margin: 0 auto; + display: grid; + grid-template-columns: 220px 1fr; + gap: 1.25rem; + align-items: start; +} + +@media (max-width: 860px) { + .frame { + grid-template-columns: 1fr; + } + .sidebar { + position: sticky; + top: 0; + z-index: 5; + } + .sideNav { + display: flex; + flex-wrap: wrap; + gap: 6px; + } + .sideLink { + flex: 0 0 auto; + } +} + +.sidebar { + padding: 1rem; + border-radius: 16px; + border: 1px solid var(--admin-border); + background: var(--admin-card); + backdrop-filter: blur(12px); +} + +.sideHint { + margin: 0.35rem 0 1rem; + font-size: 0.75rem; + color: var(--admin-muted); +} + +.sideNav { + display: flex; + flex-direction: column; + gap: 4px; +} + +.sideLink { + display: flex; + align-items: center; + gap: 8px; + min-height: 44px; + padding: 0 12px; + border-radius: 10px; + color: var(--admin-text); + text-decoration: none; + font-size: 0.9rem; + font-weight: 600; + border: 1px solid transparent; +} + +.sideLink:hover { + background: rgba(78, 205, 196, 0.08); +} + +.sideLinkActive { + border-color: rgba(78, 205, 196, 0.35); + background: rgba(78, 205, 196, 0.12); + color: var(--admin-accent); +} + +.sideFoot { + margin-top: 1.25rem; + display: flex; + align-items: center; + gap: 8px; + flex-wrap: wrap; +} + +.main { + min-width: 0; +} + +.loginCard { + max-width: 420px; + margin: 12vh auto 0; + padding: 1.75rem; + border-radius: 18px; + border: 1px solid var(--admin-border); + background: var(--admin-card); + backdrop-filter: blur(16px); + animation: adminIn 0.45s ease both; +} + +@keyframes adminIn { + from { + opacity: 0; + transform: translateY(12px); + } + to { + opacity: 1; + transform: none; + } +} + +.eyebrow { + margin: 0; + font-size: 0.8rem; + color: var(--admin-muted); + letter-spacing: 0.04em; +} + +.loginTitle { + margin: 0.4rem 0 0.5rem; + font-size: 1.6rem; + letter-spacing: -0.03em; +} + +.loginForm { + display: flex; + flex-direction: column; + gap: 10px; + margin-top: 1.25rem; +} + +.input { + min-height: 44px; + padding: 0 14px; + border-radius: 10px; + border: 1px solid var(--admin-border); + background: rgba(0, 0, 0, 0.25); + color: var(--admin-text); + font-size: 1rem; +} + +:global(html.light) .input { + background: #fff; +} + +.primaryBtn, +.ghostBtn { + min-height: 44px; + padding: 0 16px; + border-radius: 10px; + font-weight: 700; + cursor: pointer; + border: 1px solid transparent; +} + +.primaryBtn { + background: var(--admin-gradient); + color: #0a0e17; + border: none; +} + +.ghostBtn { + background: transparent; + border-color: var(--admin-border); + color: var(--admin-muted); +} + +.error { + margin: 0; + color: var(--admin-coral); + font-size: 0.85rem; +} + +.backLink { + display: inline-block; + margin-top: 1rem; + color: var(--admin-muted); + font-size: 0.85rem; +} + +.pageTitle { + margin: 0 0 0.35rem; + font-size: 1.45rem; + letter-spacing: -0.02em; +} + +.pageLead { + margin: 0 0 1.25rem; + color: var(--admin-muted); + font-size: 0.9rem; +} + +.table { + width: 100%; + border-collapse: collapse; + font-size: 0.85rem; +} + +.table th, +.table td { + text-align: left; + padding: 10px 12px; + border-bottom: 1px solid var(--admin-border); +} + +.table th { + color: var(--admin-muted); + font-weight: 600; +} + +.badgeOk, +.badgeBad, +.badgeMute { + display: inline-flex; + align-items: center; + min-height: 24px; + padding: 0 8px; + border-radius: 999px; + font-size: 0.72rem; + font-weight: 700; +} + +.badgeOk { + background: rgba(78, 205, 196, 0.15); + color: var(--admin-accent); +} + +.badgeBad { + background: rgba(255, 107, 107, 0.15); + color: var(--admin-coral); +} + +.badgeMute { + background: rgba(148, 163, 184, 0.12); + color: var(--admin-muted); +} + +.grid2 { + display: grid; + grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); + gap: 12px; +} + +.panel { + padding: 1rem 1.1rem; + border-radius: 14px; + border: 1px solid var(--admin-border); + background: var(--admin-card); +} + +.panel h3 { + margin: 0 0 0.5rem; + font-size: 0.95rem; +} + +.muted { + color: var(--admin-muted); + font-size: 0.85rem; +} + +.listPlain { + margin: 0; + padding-left: 1.1rem; + color: var(--admin-muted); + font-size: 0.85rem; + line-height: 1.55; +} + +.anchorNav { + display: flex; + flex-wrap: wrap; + gap: 8px; + margin: 0 0 1rem; +} + +.anchorNav a { + min-height: 36px; + padding: 0 12px; + display: inline-flex; + align-items: center; + border-radius: 999px; + border: 1px solid var(--admin-border); + color: var(--admin-muted); + text-decoration: none; + font-size: 0.8rem; + font-weight: 600; +} + +.anchorNav a:hover { + color: var(--admin-accent); + border-color: rgba(78, 205, 196, 0.4); +} + +.statBig { + margin: 0; + font-size: 2rem; + font-weight: 800; + letter-spacing: -0.03em; + background: var(--admin-gradient); + -webkit-background-clip: text; + background-clip: text; + color: transparent; +} + +.chartWrap { + overflow-x: auto; +} + +.chartWrap svg { + width: 100%; + min-width: 480px; + height: auto; +} + +.chartLabel, +.chartValue { + fill: var(--admin-muted); + font-size: 11px; + font-family: ui-sans-serif, system-ui, sans-serif; +} + +.donutWrap { + display: flex; + align-items: center; + gap: 1rem; + flex-wrap: wrap; +} + +.donutNum { + fill: var(--admin-text); + font-size: 18px; + font-weight: 800; +} + +.donutCap { + fill: var(--admin-muted); + font-size: 11px; +} + +.textarea { + width: 100%; + margin-top: 8px; + padding: 10px 12px; + border-radius: 12px; + border: 1px solid var(--admin-border); + background: rgba(0, 0, 0, 0.25); + color: var(--admin-text); + font: inherit; + resize: vertical; +} + diff --git a/app/admin/analytics/page.tsx b/app/admin/analytics/page.tsx new file mode 100644 index 0000000..0443c55 --- /dev/null +++ b/app/admin/analytics/page.tsx @@ -0,0 +1,266 @@ +"use client"; + +import Link from "next/link"; +import { useCallback, useEffect, useMemo, useState } from "react"; +import styles from "../admin.module.css"; + +type Latency = { key: string; ok: boolean; latencyMs: number; status: number }; +type AnalyticsPayload = { + generatedAt?: string; + charts?: { + latencies: Latency[]; + modules: { + total: number; + enabled: number; + disabled: number; + items: { id: string; title: string; enabled: boolean }[]; + }; + flags?: Record; + copy?: { vipPriceFen?: number; homeBrand?: string }; + }; + anchors?: Record; + ntfy?: { configured: boolean }; +}; + +function LatencyBars({ rows }: { rows: Latency[] }) { + const max = Math.max(1, ...rows.map((r) => r.latencyMs)); + return ( +
+ + {rows.map((r, i) => { + const y = 12 + i * 36; + const w = Math.max(4, (r.latencyMs / max) * 420); + return ( + + + {r.key} + + + + {r.latencyMs}ms · {r.ok ? "OK" : "DOWN"} + + + ); + })} + +
+ ); +} + +function ModuleDonut({ enabled, disabled }: { enabled: number; disabled: number }) { + const total = Math.max(1, enabled + disabled); + const r = 54; + const c = 2 * Math.PI * r; + const en = (enabled / total) * c; + return ( +
+ + + + + {enabled}/{total} + + + 模块开 + + +
    +
  • ● 已开 {enabled}
  • +
  • ○ 已关 {disabled}
  • +
+
+ ); +} + +export default function AdminAnalyticsPage() { + const [data, setData] = useState(null); + const [err, setErr] = useState(""); + const [ntfyMsg, setNtfyMsg] = useState("后台手动测试 · 请确认手机/桌面已订阅 topic"); + const [ntfyBusy, setNtfyBusy] = useState(false); + const [ntfyResult, setNtfyResult] = useState(""); + + const load = useCallback(() => { + setErr(""); + fetch("/api/admin/analytics", { cache: "no-store" }) + .then(async (r) => { + const j = await r.json(); + if (!r.ok) throw new Error(j.error || r.statusText); + setData(j); + }) + .catch((e) => setErr(e instanceof Error ? e.message : String(e))); + }, []); + + useEffect(() => { + load(); + const t = window.setInterval(load, 60_000); + return () => window.clearInterval(t); + }, [load]); + + const latencies = data?.charts?.latencies || []; + const modules = data?.charts?.modules; + const okCount = useMemo(() => latencies.filter((l) => l.ok).length, [latencies]); + + async function sendNtfy() { + setNtfyBusy(true); + setNtfyResult(""); + try { + const res = await fetch("/api/admin/notify", { + method: "POST", + headers: { "Content-Type": "application/json" }, + body: JSON.stringify({ + title: "Nomadro 后台", + message: ntfyMsg, + tags: "chart_with_upwards_trend,nomadro", + priority: "high", + }), + }); + const j = await res.json().catch(() => ({})); + setNtfyResult(j.ok ? "✅ 已推送 ntfy" : `❌ ${j.error || j.skipped || res.status}`); + } finally { + setNtfyBusy(false); + } + } + + return ( + <> +

+ 📈 统计分析 +

+

+ 探针延迟 · 模块开关 · Umami / Uptime-Kuma · 即时 ntfy。生成于{" "} + {data?.generatedAt ? new Date(data.generatedAt).toLocaleString() : "…"} + {" · "} + +

+ {err ?

{err}

: null} + + + +
+
+

探针健康

+

+ {okCount}/{latencies.length || "—"} +

+

OK / 全部探测点

+
+
+

VIP 展示价

+

+ ¥{(((data?.charts?.copy?.vipPriceFen || 0) as number) / 100).toFixed(0)} +

+

{data?.charts?.copy?.homeBrand || "nomadro"}

+
+
+ +
+

服务延迟(ms)

+ {latencies.length ? :

加载中…

} +
+ +
+
+

模块开关

+ {modules ? ( + + ) : ( +

…

+ )} +
    + {(modules?.items || []).map((m) => ( +
  • + {m.enabled ? "●" : "○"} {m.title || m.id} +
  • + ))} +
+
+ +
+

即时 ntfy

+

+ 配置:{data?.ntfy?.configured ? "已就绪" : "缺 NTFY_* env(仍可试推公网 topic)"} +

+ +
+ + + +
+
+
+ + + + + +
+
+
+

正在打开…

+
+ + + + + diff --git a/apps/miniprogram/xhs/release/book/markdown.js b/apps/miniprogram/xhs/release/book/markdown.js new file mode 100644 index 0000000..564ab46 --- /dev/null +++ b/apps/miniprogram/xhs/release/book/markdown.js @@ -0,0 +1,274 @@ +/** + * Lightweight markdown → HTML for offline 小红书小工具. + * No eval / network / Worker. + */ +(function (global) { + function themeColors(theme) { + if (theme === "light") { + return { + text: "#1e1630", + muted: "#6d6286", + accent: "#db2777", + accentSoft: "rgba(219,39,119,.1)", + code: "#7c3aed", + strong: "#120f1d", + }; + } + if (theme === "sepia") { + return { + text: "#3d2f1f", + muted: "#8a7358", + accent: "#c2410c", + accentSoft: "rgba(194,65,12,.12)", + code: "#c2410c", + strong: "#2a1f14", + }; + } + return { + text: "#f3eefc", + muted: "#b4a9c8", + accent: "#ff7ab6", + accentSoft: "rgba(255,122,182,.14)", + code: "#c4b5fd", + strong: "#ffffff", + }; + } + + function escapeHtml(s) { + return String(s) + .replace(/&/g, "&") + .replace(//g, ">"); + } + + function inline(s, c) { + return escapeHtml(s) + .replace(/\*\*(.+?)\*\*/g, '$1') + .replace(/\*(.+?)\*/g, '$1') + .replace(/`([^`]+)`/g, '$1'); + } + + function markdownToHtml(src, opts) { + opts = opts || {}; + var dropCap = opts.dropCap !== false; + var c = themeColors(opts.theme || "dark"); + var text = String(src || "").replace(/\r\n/g, "\n"); + text = text.replace(//g, ""); + text = text.replace(//gi, "> 🎬 视频请在异度世界公众号查看"); + text = text.replace(//gi, "> 🖼 配图已省略(离线版)"); + text = text.replace(/!\[[^\]]*\]\([^)]+\)/g, "> 🖼 配图已省略(离线版)"); + + var lines = text.split("\n"); + var out = []; + var inCode = false; + var codeBuf = []; + var inUl = false; + var inOl = false; + var olIndex = 0; + var inQuote = false; + var quoteBuf = []; + var paraCount = 0; + var skippedChapterTitle = false; + + function closeLists() { + if (inUl) { + out.push(""); + inUl = false; + } + if (inOl) { + out.push(""); + inOl = false; + olIndex = 0; + } + } + + function flushQuote() { + if (!inQuote) return; + var body = quoteBuf.map(function (q) { + return inline(q, c); + }).join("
"); + out.push('
' + body + "
"); + inQuote = false; + quoteBuf = []; + } + + function isTableSep(line) { + return /^\s*\|?[\s:-]+\|[\s|:-]*\|?\s*$/.test(line); + } + + function splitRow(line) { + var s = line.trim(); + if (s.charAt(0) === "|") s = s.slice(1); + if (s.charAt(s.length - 1) === "|") s = s.slice(0, -1); + return s.split("|").map(function (cell) { + return cell.trim(); + }); + } + + function renderTable(rows) { + if (!rows.length) return; + var html = ['
']; + rows[0].forEach(function (cell) { + html.push(""); + }); + html.push(""); + for (var r = 1; r < rows.length; r++) { + html.push(""); + rows[r].forEach(function (cell) { + html.push(""); + }); + html.push(""); + } + html.push("
" + inline(cell, c) + "
" + inline(cell, c) + "
"); + out.push(html.join("")); + } + + for (var i = 0; i < lines.length; i++) { + var raw = lines[i]; + var line = raw; + + if (/^```/.test(line)) { + flushQuote(); + closeLists(); + if (inCode) { + out.push('
' + escapeHtml(codeBuf.join("\n")) + "
"); + codeBuf = []; + inCode = false; + } else { + inCode = true; + } + continue; + } + if (inCode) { + codeBuf.push(line); + continue; + } + + // GFM table + if ( + line.indexOf("|") !== -1 && + i + 1 < lines.length && + isTableSep(lines[i + 1]) + ) { + flushQuote(); + closeLists(); + var rows = [splitRow(line)]; + i += 1; // skip separator + while (i + 1 < lines.length && lines[i + 1].indexOf("|") !== -1 && lines[i + 1].trim()) { + i += 1; + if (isTableSep(lines[i])) continue; + rows.push(splitRow(lines[i])); + } + renderTable(rows); + continue; + } + + if (/^\s*>\s?/.test(line)) { + closeLists(); + inQuote = true; + quoteBuf.push(line.replace(/^\s*>\s?/, "")); + continue; + } + if (inQuote) flushQuote(); + + if (/^\s*---+\s*$/.test(line) || /^\s*\*\*\*+\s*$/.test(line)) { + closeLists(); + out.push('
'); + continue; + } + + var h1 = /^#\s+(.+)$/.exec(line); + if (h1) { + closeLists(); + if (!skippedChapterTitle) { + skippedChapterTitle = true; + continue; + } + out.push("

" + inline(h1[1], c) + "

"); + continue; + } + var h2 = /^##\s+(.+)$/.exec(line); + if (h2) { + closeLists(); + // Chapter title already shown in reader chrome — skip first ## + if (!skippedChapterTitle) { + skippedChapterTitle = true; + continue; + } + out.push("

" + inline(h2[1], c) + "

"); + continue; + } + var h3 = /^###\s+(.+)$/.exec(line); + if (h3) { + closeLists(); + out.push("

" + inline(h3[1], c) + "

"); + continue; + } + + var task = /^\s*[-*+]\s+\[([ xX])\]\s+(.+)$/.exec(line); + if (task) { + if (inOl) { + out.push(""); + inOl = false; + olIndex = 0; + } + if (!inUl) { + out.push('
'); + inUl = true; + } + var mark = /x/i.test(task[1]) ? "☑" : "☐"; + out.push("
" + mark + " " + inline(task[2], c) + "
"); + continue; + } + + var ul = /^\s*[-*+]\s+(.+)$/.exec(line); + if (ul) { + if (inOl) { + out.push("
"); + inOl = false; + olIndex = 0; + } + if (!inUl) { + out.push('
'); + inUl = true; + } + out.push("
• " + inline(ul[1], c) + "
"); + continue; + } + var ol = /^\s*(\d+)\.\s+(.+)$/.exec(line); + if (ol) { + if (inUl) { + out.push("
"); + inUl = false; + } + if (!inOl) { + out.push('
'); + inOl = true; + olIndex = 0; + } + olIndex += 1; + out.push("
" + olIndex + ". " + inline(ol[2], c) + "
"); + continue; + } + + if (!line.trim()) { + closeLists(); + continue; + } + + closeLists(); + paraCount += 1; + var cls = dropCap && paraCount === 1 ? ' class="dropcap"' : ""; + out.push("" + inline(line.trim(), c) + "

"); + } + + flushQuote(); + closeLists(); + if (inCode) { + out.push('
' + escapeHtml(codeBuf.join("\n")) + "
"); + } + return out.join(""); + } + + global.MarkdownLite = { markdownToHtml: markdownToHtml, themeColors: themeColors }; +})(window); diff --git a/apps/miniprogram/xhs/release/book/styles.css b/apps/miniprogram/xhs/release/book/styles.css new file mode 100644 index 0000000..3cbecde --- /dev/null +++ b/apps/miniprogram/xhs/release/book/styles.css @@ -0,0 +1,1435 @@ +:root { + --safe-top: 0px; + --safe-bottom: 0px; + --r-bg: #0c0b12; + --r-bg2: #15101f; + --r-text: #f3eefc; + --r-muted: #b4a9c8; + --r-accent: #ff7ab6; + --r-accent2: #a78bfa; + --r-soft: rgba(255, 255, 255, 0.06); + --r-border: rgba(255, 255, 255, 0.1); + --r-paper: rgba(28, 22, 45, 0.92); + --r-chrome: rgba(12, 11, 18, 0.94); +} + +*, +*::before, +*::after { + box-sizing: border-box; + margin: 0; + padding: 0; +} + +html, +body { + height: 100%; + min-height: 100%; + min-height: 100vh; + font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", + "Hiragino Sans GB", "Microsoft YaHei", sans-serif; + background: #0a0910; + color: #f3eefc; + -webkit-font-smoothing: antialiased; + -webkit-tap-highlight-color: transparent; +} + +button, +input { + font: inherit; + color: inherit; +} + +button { + border: 0; + background: none; + cursor: pointer; +} + +.is-hidden { + display: none !important; +} + +.file-hidden { + position: absolute; + width: 1px; + height: 1px; + opacity: 0; + overflow: hidden; + z-index: -1; +} + +.view { + min-height: 100%; + min-height: 100vh; +} + +/* —— Home —— */ +.home { + position: relative; + background: + radial-gradient(820px 460px at 12% -8%, rgba(167, 139, 250, 0.3), transparent 58%), + radial-gradient(720px 420px at 100% 0%, rgba(244, 114, 182, 0.24), transparent 52%), + linear-gradient(168deg, #0a0910 0%, #14101c 46%, #0e0c14 100%); +} + +.home.loading { + display: -webkit-flex; + display: flex; + -webkit-flex-direction: column; + flex-direction: column; + -webkit-align-items: center; + align-items: center; + -webkit-justify-content: center; + justify-content: center; + padding: 48px; +} + +.loading-text { + position: relative; + z-index: 2; + font-size: 18px; + color: #e8dff8; +} + +.bg-layer { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + overflow: hidden; + pointer-events: none; +} + +.orb { + position: absolute; + border-radius: 50%; + opacity: 0.7; + -webkit-animation: aurora 10s ease-in-out infinite; + animation: aurora 10s ease-in-out infinite; +} + +.orb-a { + width: 280px; + height: 280px; + left: -90px; + top: 40px; + background: radial-gradient(circle, rgba(167, 139, 250, 0.5), transparent 70%); +} + +.orb-b { + width: 320px; + height: 320px; + right: -110px; + top: 220px; + background: radial-gradient(circle, rgba(244, 114, 182, 0.42), transparent 70%); + -webkit-animation-delay: 1.4s; + animation-delay: 1.4s; +} + +.veil { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + background: linear-gradient(180deg, transparent 55%, rgba(10, 9, 16, 0.72) 100%); +} + +.stage { + position: relative; + z-index: 1; + min-height: 100%; + min-height: 100vh; + padding: 28px; + padding-top: 80px; + padding-top: calc(var(--app-pad-top, 80px) + 12px); + padding-bottom: 40px; + padding-bottom: calc(40px + var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 0px))); + display: -webkit-flex; + display: flex; + -webkit-flex-direction: column; + flex-direction: column; + -webkit-align-items: center; + align-items: center; +} + +.brand-block { + text-align: center; + margin-bottom: 28px; +} + +.brand { + font-size: 28px; + font-weight: 700; + letter-spacing: 0.18em; + color: #e9d5ff; +} + +.brand-line { + margin-top: 8px; + font-size: 13px; + color: #9f93b8; + letter-spacing: 0.06em; +} + +.cover-wrap { + position: relative; + width: 58%; + max-width: 220px; + margin: 8px 0 28px; +} + +.cover-glow { + position: absolute; + top: -18%; + right: -18%; + bottom: -18%; + left: -18%; + border-radius: 50%; + -webkit-filter: blur(28px); + filter: blur(28px); + opacity: 0.85; + background: rgba(219, 39, 119, 0.45); +} + +/* Chrome 61: padding-box ratio instead of aspect-ratio */ +.cover { + position: relative; + display: block; + width: 100%; + height: 0; + padding-top: 133.33%; + border-radius: 18px; + overflow: hidden; + box-shadow: 0 24px 48px rgba(0, 0, 0, 0.45); + background: linear-gradient(155deg, #1a0b2e 0%, #6d28d9 42%, #db2777 100%); +} + +.cover-shine, +.cover-emoji, +.cover-title { + position: absolute; + left: 0; + right: 0; +} + +.cover-shine { + top: 0; + bottom: 0; + background: linear-gradient(125deg, rgba(255, 255, 255, 0.22) 0%, transparent 42%); + pointer-events: none; +} + +.cover-emoji { + top: 36%; + font-size: 52px; + line-height: 1; + text-align: center; +} + +.cover-title { + bottom: 20px; + padding: 0 16px; + font-size: 15px; + font-weight: 600; + text-align: center; + line-height: 1.35; + color: #fce7f3; +} + +.copy { + text-align: center; + max-width: 320px; +} + +.copy .title { + margin-bottom: 10px; + font-size: 22px; + font-weight: 700; + line-height: 1.35; + color: #f8f4ff; +} + +.tease { + font-size: 14px; + line-height: 1.6; + color: #b4a9c8; +} + +.author { + margin-top: 10px; + font-size: 12px; + color: #8b7fa8; +} + +.cta-area { + margin-top: auto; + width: 100%; + max-width: 320px; + padding-top: 36px; + display: -webkit-flex; + display: flex; + -webkit-flex-direction: column; + flex-direction: column; + -webkit-align-items: center; + align-items: center; +} + +.cta { + width: 100%; + height: 52px; + margin-bottom: 12px; + border-radius: 999px; + font-size: 16px; + font-weight: 600; + color: #1a0b2e; + background: linear-gradient(120deg, #fce7f3, #e9d5ff 40%, #c4b5fd); + box-shadow: 0 12px 32px rgba(167, 139, 250, 0.35); +} + +.resume-hint { + font-size: 12px; + color: #8b7fa8; +} + +.home-xhs { + display: -webkit-flex; + display: flex; + -webkit-justify-content: center; + justify-content: center; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; + gap: 8px; + margin-top: 14px; +} + +.home-xhs-btn { + padding: 8px 12px; + border-radius: 999px; + border: 1px solid rgba(255, 255, 255, 0.18); + background: rgba(255, 255, 255, 0.06); + color: #f3eefc; + font-size: 12px; +} + +.home-time { + margin-top: 10px; + font-size: 12px; + color: rgba(243, 238, 252, 0.55); +} + +/* —— Reader —— */ +.reader { + position: relative; + background: var(--r-bg); + color: var(--r-text); +} + +.reader.theme-sepia { + background: #f3e9d7; + --r-bg: #f3e9d7; + --r-bg2: #e8dcc4; + --r-text: #3d2f1f; + --r-muted: #8a7358; + --r-accent: #c2410c; + --r-accent2: #b45309; + --r-soft: rgba(120, 80, 40, 0.08); + --r-border: rgba(120, 80, 40, 0.16); + --r-paper: rgba(255, 252, 245, 0.95); + --r-chrome: rgba(243, 233, 215, 0.96); +} + +.reader.theme-light { + background: #f7f4fb; + --r-bg: #f7f4fb; + --r-bg2: #eee8f6; + --r-text: #1e1630; + --r-muted: #6d6286; + --r-accent: #db2777; + --r-accent2: #7c3aed; + --r-soft: rgba(30, 22, 48, 0.05); + --r-border: rgba(30, 22, 48, 0.1); + --r-paper: rgba(255, 255, 255, 0.96); + --r-chrome: rgba(247, 244, 251, 0.96); +} + +.reader-bg { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + pointer-events: none; + background: + radial-gradient(520px 260px at 10% -8%, rgba(167, 139, 250, 0.22), transparent 55%), + radial-gradient(480px 240px at 100% 0%, rgba(244, 114, 182, 0.18), transparent 50%), + linear-gradient(180deg, var(--r-bg2), var(--r-bg)); + z-index: 0; +} + +.topbar { + position: fixed; + top: 0; + left: 0; + right: 0; + z-index: 40; + /* --app-pad-top 由 JS 写入:状态栏 + 小红书宿主返回/分享行 */ + padding-top: 80px; + padding-top: var(--app-pad-top, 80px); + padding-right: 12px; + padding-bottom: 8px; + padding-left: 12px; + display: -webkit-flex; + display: flex; + -webkit-align-items: center; + align-items: center; + background: var(--r-chrome); + border-bottom: 1px solid var(--r-border); + box-sizing: border-box; + -webkit-transition: -webkit-transform 0.22s ease, opacity 0.22s ease; + transition: transform 0.22s ease, opacity 0.22s ease; +} + +.reader.chrome-hidden .topbar { + -webkit-transform: translateY(-110%); + transform: translateY(-110%); + pointer-events: none; + opacity: 0; +} + +.reader.chrome-hidden .top-fab { + opacity: 0; + pointer-events: none; +} + +.topbar-progress { + position: absolute; + left: 0; + right: 0; + bottom: 0; + height: 2px; + background: var(--r-soft); + overflow: hidden; +} + +.topbar-progress-fill { + display: block; + height: 100%; + width: 0%; + background: linear-gradient(90deg, var(--r-accent), var(--r-accent2)); +} + +.top-btn { + width: 44px; + height: 44px; + margin-right: 8px; + border-radius: 12px; + background: var(--r-soft); + border: 1px solid var(--r-border); + display: -webkit-flex; + display: flex; + -webkit-align-items: center; + align-items: center; + -webkit-justify-content: center; + justify-content: center; + -webkit-flex-shrink: 0; + flex-shrink: 0; +} + +.top-btn:last-of-type { + margin-right: 0; + margin-left: 8px; +} + +.top-ico { + font-size: 18px; + color: var(--r-text); + line-height: 1; + font-weight: 600; +} + +.top-center { + -webkit-flex: 1; + flex: 1; + min-width: 0; + text-align: left; + background: transparent; + border: 0; + padding: 0; +} + +.top-title { + font-size: 15px; + color: var(--r-text); + font-weight: 600; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + line-height: 1.25; +} + +.top-sub { + margin-top: 1px; + font-size: 11px; + color: var(--r-muted); + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; +} + +.reader-body { + position: relative; + z-index: 1; + padding: 16px; + /* 顶栏:安全区 + 宿主行 + 按钮行(~52) */ + padding-top: 140px; + padding-top: calc(var(--app-pad-top, 80px) + 60px); + padding-bottom: 48px; + padding-bottom: calc(48px + var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 0px))); + max-width: 720px; + margin: 0 auto; + box-sizing: border-box; +} + +.paper { + background: var(--r-paper); + border: 1px solid var(--r-border); + border-radius: 20px; + padding: 16px 14px 20px; + box-shadow: 0 16px 40px rgba(0, 0, 0, 0.18); +} + +.hero-card { + padding: 4px 2px 12px; + margin-bottom: 8px; + border-bottom: 1px dashed var(--r-border); +} + +.hero-emoji { + display: block; + font-size: 28px; + line-height: 1; +} + +.hero-title { + display: block; + margin-top: 6px; + font-size: 22px; + font-weight: 700; + color: var(--r-text); + line-height: 1.25; +} + +.hero-sub { + display: block; + margin-top: 4px; + font-size: 13px; + color: var(--r-muted); + line-height: 1.4; +} + +.hero-stats { + margin-top: 12px; + display: -webkit-flex; + display: flex; +} + +.stat { + -webkit-flex: 1; + flex: 1; + padding: 8px 2px; + margin-right: 4px; + border-radius: 12px; + background: var(--r-soft); + text-align: center; +} + +.stat:last-child { + margin-right: 0; +} + +.stat-n { + display: block; + font-size: 15px; + font-weight: 700; + color: var(--r-text); + line-height: 1.2; +} + +.stat-l { + display: block; + margin-top: 1px; + font-size: 11px; + color: var(--r-muted); +} + +.hero-tip { + display: block; + margin-top: 10px; + text-align: center; + font-size: 12px; + color: var(--r-muted); +} + +.chapter-block { + padding-top: 4px; +} + +.chapter-divider { + display: -webkit-flex; + display: flex; + -webkit-justify-content: center; + justify-content: center; + margin: 18px 0 14px; +} + +.chapter-divider-text { + font-size: 14px; + letter-spacing: 0.45em; + color: var(--r-muted); + opacity: 0.65; +} + +.chapter-hero { + margin-bottom: 10px; + padding-bottom: 10px; + border-bottom: 1px dashed var(--r-border); +} + +.chapter-hero-top { + display: -webkit-flex; + display: flex; + -webkit-align-items: center; + align-items: center; + -webkit-justify-content: space-between; + justify-content: space-between; +} + +.chapter-hero-emoji { + font-size: 28px; + line-height: 1; +} + +.chapter-ring { + display: -webkit-flex; + display: flex; + -webkit-align-items: baseline; + align-items: baseline; + padding: 6px 12px; + border-radius: 999px; + background: var(--r-soft); + border: 1px solid var(--r-border); +} + +.chapter-ring-n { + font-size: 15px; + font-weight: 700; + color: var(--r-accent); + margin-right: 2px; +} + +.chapter-ring-t { + font-size: 12px; + color: var(--r-muted); +} + +.chapter-title { + display: block; + margin-top: 8px; + font-size: 20px; + font-weight: 700; + color: var(--r-text); + line-height: 1.3; +} + +.chapter-meta { + display: block; + margin-top: 4px; + font-size: 12px; + color: var(--r-muted); +} + +.md-wrap { + padding: 0; +} + +.next-peek { + margin-top: 16px; + padding: 12px 14px; + border-radius: 14px; + border: 1px dashed var(--r-border); + background: var(--r-soft); + width: 100%; + text-align: left; + color: inherit; +} + +.next-peek-label { + display: block; + font-size: 11px; + letter-spacing: 0.12em; + color: var(--r-muted); +} + +.next-peek-title { + display: block; + margin-top: 4px; + font-size: 15px; + font-weight: 600; + color: var(--r-text); + line-height: 1.35; +} + +.fin { + margin: 28px 0 24px; + padding: 20px 10px 12px; + text-align: center; + border-top: 1px dashed var(--r-border); +} + +.fin-emoji { + display: block; + font-size: 28px; +} + +.fin-title { + display: block; + margin-top: 6px; + font-size: 20px; + color: var(--r-text); + font-weight: 700; +} + +.fin-desc { + display: block; + margin-top: 4px; + font-size: 13px; + color: var(--r-muted); + font-style: italic; +} + +.fin-actions { + margin-top: 14px; + display: -webkit-flex; + display: flex; + gap: 10px; + -webkit-justify-content: center; + justify-content: center; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; +} + +.fin-btn { + padding: 10px 18px; + border-radius: 999px; + background: linear-gradient(135deg, var(--r-accent), var(--r-accent2)); + color: #fff; + font-size: 14px; + font-weight: 600; +} + +.fin-btn.ghost { + background: var(--r-soft); + border: 1px solid var(--r-border); + color: var(--r-text); +} + +.md-body { + font-size: 16px; + line-height: 1.7; + color: var(--r-text); + word-break: break-word; +} + +.md-body h2, +.md-body h3 { + margin: 1.2em 0 0.55em; + line-height: 1.35; +} + +.md-body h2 { + font-size: 1.18em; +} + +.md-body h3 { + font-size: 1.08em; + color: var(--r-muted); +} + +.md-body p { + margin: 0 0 0.85em; +} + +.md-body p.dropcap:first-letter, +.md-body .dropcap:first-letter { + float: left; + font-size: 2.4em; + line-height: 0.85; + padding: 0.08em 0.12em 0 0; + font-weight: 700; + color: var(--r-accent); +} + +.md-quote { + margin: 10px 0; + padding: 10px 12px; + border-radius: 0 12px 12px 0; + background: var(--r-soft); + border-left: 3px solid var(--r-accent); + color: var(--r-muted); + font-style: italic; +} + +.md-list { + margin: 0 0 0.85em; + padding-left: 1.1em; +} + +.md-list div { + margin: 0.25em 0; +} + +.md-code { + color: var(--r-accent2); + background: var(--r-soft); + padding: 0 4px; + border-radius: 4px; + font-size: 0.92em; +} + +.md-pre { + margin: 12px 0; + padding: 12px; + border-radius: 10px; + background: var(--r-soft); + border: 1px solid var(--r-border); + overflow-x: auto; + font-size: 0.88em; + line-height: 1.5; + white-space: pre-wrap; +} + +.md-hr { + border: 0; + border-top: 1px solid var(--r-border); + margin: 18px 0; +} + +.md-table-wrap { + margin: 12px 0 16px; + overflow-x: auto; + -webkit-overflow-scrolling: touch; + border-radius: 10px; + border: 1px solid var(--r-border); +} + +.md-table { + width: 100%; + border-collapse: collapse; + font-size: 0.92em; + line-height: 1.45; +} + +.md-table th, +.md-table td { + padding: 8px 10px; + text-align: left; + border-bottom: 1px solid var(--r-border); + vertical-align: top; + white-space: nowrap; +} + +.md-table th { + background: var(--r-soft); + color: var(--r-accent); + font-weight: 600; +} + +.md-table tr:last-child td { + border-bottom: 0; +} + +.reader-foot { + margin-top: 20px; + text-align: center; +} + +.foot-tip { + margin-bottom: 12px; + font-size: 12px; + color: var(--r-muted); +} + +.ghost-btn { + display: inline-block; + margin: 0 6px 8px; + padding: 10px 18px; + border-radius: 999px; + border: 1px solid var(--r-border); + color: var(--r-accent); + background: var(--r-soft); + font-size: 13px; +} + +.top-fab { + position: fixed; + right: 18px; + bottom: 24px; + bottom: calc(24px + var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 0px))); + z-index: 30; + width: 56px; + height: 56px; + border-radius: 50%; + background: var(--r-paper); + border: 1px solid var(--r-border); + display: -webkit-flex; + display: flex; + -webkit-align-items: center; + align-items: center; + -webkit-justify-content: center; + justify-content: center; + box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18); +} + +.top-fab-text { + font-size: 22px; + color: var(--r-accent); + font-weight: 700; +} + +/* —— TOC drawer(对齐微信小程序 reader drawer) —— */ +.drawer-mask { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + background: rgba(8, 6, 14, 0.55); + z-index: 100; +} + +.drawer { + position: absolute; + top: 0; + left: 0; + width: 78%; + max-width: 540px; + height: 100%; + background: + radial-gradient(360px 180px at 0% 0%, rgba(167, 139, 250, 0.18), transparent 55%), + linear-gradient(180deg, #1a1428, #120e1c 40%, #0c0b12); + padding: 22px 0 12px; + padding-top: 80px; + padding-top: calc(var(--app-pad-top, 80px) + 12px); + box-sizing: border-box; + display: -webkit-flex; + display: flex; + -webkit-flex-direction: column; + flex-direction: column; + color: #f3eefc; + -webkit-animation: drawer-in 0.24s cubic-bezier(0.22, 1, 0.36, 1) both; + animation: drawer-in 0.24s cubic-bezier(0.22, 1, 0.36, 1) both; +} + +.drawer.theme-sepia { + background: linear-gradient(180deg, #f6edd9, #efe3cb); + color: #3d2f1f; +} + +.drawer.theme-light { + background: linear-gradient(180deg, #faf8ff, #f0ebf8); + color: #1e1630; +} + +@-webkit-keyframes drawer-in { + from { -webkit-transform: translateX(-100%); transform: translateX(-100%); } + to { -webkit-transform: translateX(0); transform: translateX(0); } +} + +@keyframes drawer-in { + from { -webkit-transform: translateX(-100%); transform: translateX(-100%); } + to { -webkit-transform: translateX(0); transform: translateX(0); } +} + +.drawer-hero { + padding: 0 16px 10px; +} + +.drawer-brand { + display: block; + font-size: 12px; + letter-spacing: 1px; + color: var(--r-accent); +} + +.drawer-title { + display: block; + margin-top: 2px; + font-size: 22px; + font-weight: 700; +} + +.drawer-meter { + margin-top: 10px; + height: 4px; + border-radius: 999px; + background: rgba(255, 255, 255, 0.08); + overflow: hidden; +} + +.theme-sepia .drawer-meter, +.theme-light .drawer-meter { + background: rgba(0, 0, 0, 0.08); +} + +.drawer-meter-fill { + height: 100%; + width: 0%; + border-radius: inherit; + background: linear-gradient(90deg, var(--r-accent), var(--r-accent2)); +} + +.drawer-stats { + margin-top: 6px; + display: -webkit-flex; + display: flex; + -webkit-justify-content: space-between; + justify-content: space-between; + font-size: 12px; + color: var(--r-muted); +} + +.drawer-search { + display: block; + width: 100%; + margin-top: 10px; + height: 44px; + padding: 0 14px; + border-radius: 12px; + background: rgba(255, 255, 255, 0.06); + border: 1px solid var(--r-border); + font-size: 15px; + color: inherit; + outline: none; + box-sizing: border-box; +} + +.theme-sepia .drawer-search, +.theme-light .drawer-search { + background: rgba(0, 0, 0, 0.04); +} + +.drawer-list { + -webkit-flex: 1; + flex: 1; + height: 0; + min-height: 0; + padding: 4px 10px 24px; + box-sizing: border-box; + overflow-y: auto; + -webkit-overflow-scrolling: touch; +} + +.drawer-item { + display: -webkit-flex; + display: flex; + -webkit-align-items: flex-start; + align-items: flex-start; + padding: 10px; + margin-bottom: 2px; + border-radius: 12px; + width: 100%; + text-align: left; + color: inherit; + background: transparent; +} + +.drawer-item.active { + background: rgba(255, 122, 182, 0.12); +} + +.theme-sepia .drawer-item.active { + background: rgba(194, 65, 12, 0.1); +} + +.theme-light .drawer-item.active { + background: rgba(219, 39, 119, 0.08); +} + +.drawer-idx { + font-size: 14px; + color: var(--r-muted); + font-weight: 600; + padding-top: 2px; + min-width: 36px; + margin-right: 10px; +} + +.drawer-body { + -webkit-flex: 1; + flex: 1; + min-width: 0; +} + +.drawer-name { + display: block; + font-size: 15px; + line-height: 1.35; +} + +/* —— Settings sheet(对齐 ReaderSettings) —— */ +.rs-mask { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + z-index: 120; + background: rgba(8, 6, 14, 0.55); + display: -webkit-flex; + display: flex; + -webkit-align-items: flex-end; + align-items: flex-end; +} + +.rs-sheet { + width: 100%; + padding: 16px 20px 20px; + padding-bottom: 20px; + padding-bottom: calc(20px + var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 0px))); + border-radius: 22px 22px 0 0; + background: + radial-gradient(420px 160px at 50% 0%, rgba(255, 122, 182, 0.16), transparent 60%), + linear-gradient(180deg, #1a1428 0%, #120e1c 60%, #0c0b12 100%); + border-top: 1px solid rgba(255, 255, 255, 0.12); + -webkit-animation: rs-up 0.26s cubic-bezier(0.22, 1, 0.36, 1) both; + animation: rs-up 0.26s cubic-bezier(0.22, 1, 0.36, 1) both; + box-sizing: border-box; +} + +.rs-sheet.theme-sepia { + background: linear-gradient(180deg, #f6edd9 0%, #efe3cb 100%); + border-top-color: rgba(120, 80, 40, 0.18); +} + +.rs-sheet.theme-light { + background: linear-gradient(180deg, #faf8ff 0%, #f0ebf8 100%); + border-top-color: rgba(30, 22, 48, 0.1); +} + +@-webkit-keyframes rs-up { + from { -webkit-transform: translateY(100%); transform: translateY(100%); } + to { -webkit-transform: translateY(0); transform: translateY(0); } +} + +@keyframes rs-up { + from { -webkit-transform: translateY(100%); transform: translateY(100%); } + to { -webkit-transform: translateY(0); transform: translateY(0); } +} + +.rs-handle { + width: 40px; + height: 4px; + border-radius: 999px; + background: rgba(255, 255, 255, 0.2); + margin: 0 auto 14px; +} + +.theme-sepia .rs-handle, +.theme-light .rs-handle { + background: rgba(0, 0, 0, 0.14); +} + +.rs-title { + display: block; + text-align: center; + font-size: 20px; + font-weight: 700; + color: #faf7ff; +} + +.theme-sepia .rs-title { color: #3d2f1f; } +.theme-light .rs-title { color: #1e1630; } + +.rs-sub { + display: block; + text-align: center; + margin-top: 4px; + margin-bottom: 18px; + font-size: 13px; + color: #b4a9c8; +} + +.theme-sepia .rs-sub { color: #8a7358; } +.theme-light .rs-sub { color: #6d6286; } + +.rs-row { + margin-bottom: 14px; +} + +.rs-label { + display: block; + margin-bottom: 8px; + font-size: 13px; + color: #b4a9c8; +} + +.theme-sepia .rs-label, +.theme-light .rs-label { + color: inherit; + opacity: 0.7; +} + +.rs-seg { + display: -webkit-flex; + display: flex; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; +} + +.rs-seg button { + min-width: 52px; + height: 40px; + padding: 0 12px; + margin-right: 8px; + margin-bottom: 8px; + border-radius: 12px; + background: rgba(255, 255, 255, 0.06); + border: 1px solid rgba(255, 255, 255, 0.1); + color: #f3eefc; + font-size: 14px; +} + +.theme-sepia .rs-seg button, +.theme-light .rs-seg button { + background: rgba(0, 0, 0, 0.04); + border-color: rgba(0, 0, 0, 0.08); + color: inherit; +} + +.rs-seg button.on { + border-color: #ff7ab6; + color: #ff7ab6; + background: rgba(255, 122, 182, 0.12); +} + +.rs-actions { + margin-top: 8px; + padding-top: 8px; + border-top: 1px solid rgba(255, 255, 255, 0.08); +} + +.rs-cap { + margin: 10px 2px 0; + font-size: 11px; + color: var(--r-muted); + letter-spacing: 0.02em; +} + +.rs-section { + margin: 14px 2px 4px; + font-size: 12px; + font-weight: 700; + letter-spacing: 0.14em; + color: var(--r-accent); + text-transform: uppercase; +} + +.cam-mask, +.journal-mask { + position: fixed; + inset: 0; + z-index: 80; + background: rgba(0, 0, 0, 0.72); + display: -webkit-flex; + display: flex; + -webkit-align-items: flex-end; + align-items: flex-end; + -webkit-justify-content: center; + justify-content: center; +} + +.cam-sheet, +.journal-sheet { + width: 100%; + max-width: 520px; + max-height: 92%; + overflow: auto; + padding: 18px 16px 28px; + border-radius: 18px 18px 0 0; + background: #16121f; + color: #f3eefc; + box-sizing: border-box; +} + +.cam-title, +.journal-sheet .rs-title { + font-size: 18px; + font-weight: 700; +} + +.cam-sub { + margin-top: 4px; + font-size: 12px; + color: #b4a9c8; +} + +.cam-stage { + position: relative; + margin-top: 12px; + width: 100%; + padding-top: 133%; + border-radius: 14px; + overflow: hidden; + background: #0a0910; +} + +.cam-video, +.cam-canvas, +.cam-preview { + position: absolute; + left: 0; + top: 0; + width: 100%; + height: 100%; + object-fit: cover; +} + +.cam-tip { + margin-top: 10px; + font-size: 12px; + color: #b4a9c8; +} + +.cam-actions { + margin-top: 14px; + display: -webkit-flex; + display: flex; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; + gap: 8px; + -webkit-justify-content: center; + justify-content: center; +} + +.journal-input { + display: block; + width: 100%; + margin-top: 12px; + padding: 12px; + border-radius: 12px; + border: 1px solid rgba(255, 255, 255, 0.12); + background: rgba(255, 255, 255, 0.04); + color: inherit; + resize: vertical; + min-height: 120px; + box-sizing: border-box; +} + +.drawer-tabs { + display: -webkit-flex; + display: flex; + margin-top: 10px; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; +} + +.drawer-tab { + -webkit-flex: 1 1 22%; + flex: 1 1 22%; + min-width: 64px; + height: 36px; + margin: 0 6px 6px 0; + border-radius: 10px; + background: rgba(255, 255, 255, 0.04); + border: 1px solid rgba(255, 255, 255, 0.08); + color: #b4a9c8; + font-size: 12px; +} + +.drawer-tab.on { + background: rgba(255, 122, 182, 0.12); + border-color: rgba(255, 122, 182, 0.35); + color: #ff7ab6; +} + +.note-item { + display: block; + width: 100%; + text-align: left; + padding: 12px 10px; + margin-bottom: 8px; + border-radius: 12px; + background: var(--r-soft); + border: 1px solid var(--r-border); + color: inherit; +} + +.note-item-title { + display: block; + font-size: 13px; + font-weight: 600; + color: var(--r-text); +} + +.note-item-body { + display: block; + margin-top: 4px; + font-size: 12px; + color: var(--r-muted); + line-height: 1.45; +} + +.note-item-actions { + display: -webkit-flex; + display: flex; + gap: 8px; + margin-top: 8px; +} + +.note-chip { + padding: 4px 10px; + border-radius: 999px; + font-size: 11px; + background: rgba(255, 122, 182, 0.12); + border: 1px solid rgba(255, 122, 182, 0.3); + color: #ff7ab6; +} + +.note-chip.ghost { + background: rgba(255, 255, 255, 0.04); + border-color: rgba(255, 255, 255, 0.12); + color: var(--r-muted); +} + +.rs-action { + display: block; + width: 100%; + height: 44px; + margin-bottom: 8px; + border-radius: 12px; + background: rgba(255, 122, 182, 0.14); + border: 1px solid rgba(255, 122, 182, 0.35); + color: #ffb4d6; + font-size: 14px; + font-weight: 600; +} + +.rs-action.ghost { + background: rgba(255, 255, 255, 0.04); + border-color: rgba(255, 255, 255, 0.1); + color: #b4a9c8; + font-weight: 500; +} + +@-webkit-keyframes aurora { + 0%, 100% { -webkit-transform: translateY(0) scale(1); transform: translateY(0) scale(1); } + 50% { -webkit-transform: translateY(18px) scale(1.06); transform: translateY(18px) scale(1.06); } +} + +@keyframes aurora { + 0%, 100% { -webkit-transform: translateY(0) scale(1); transform: translateY(0) scale(1); } + 50% { -webkit-transform: translateY(18px) scale(1.06); transform: translateY(18px) scale(1.06); } +} diff --git a/apps/miniprogram/xhs/release/book/xhs-bridge.js b/apps/miniprogram/xhs/release/book/xhs-bridge.js new file mode 100644 index 0000000..ee7811f --- /dev/null +++ b/apps/miniprogram/xhs/release/book/xhs-bridge.js @@ -0,0 +1,639 @@ +/** + * Official XHS miniTool bridge helpers (Chrome 61 / ES2017). + * Prefer window.xhs.miniTool Storage (9.46+); fall back to localStorage. + */ +(function (global) { + "use strict"; + + var STORAGE_MIN = 9460; + var COMMENT_MIN = 9490; + var FILE_MIN = 9490; + + function readBuildVersion(launchOptions) { + var env = launchOptions && launchOptions.miniToolEnv; + return Number(env && env.buildVersion) || 0; + } + + function getClientVersion(buildVersion) { + return Math.floor((Number(buildVersion) || 0) / 1000); + } + + function isClientVersionAtLeast(buildVersion, minimum) { + return getClientVersion(buildVersion) >= minimum; + } + + function getMiniTool() { + return global.xhs && global.xhs.miniTool ? global.xhs.miniTool : null; + } + + function getBuildVersion() { + var xhs = global.xhs; + var sync = readBuildVersion(xhs && xhs.launchOptions); + if (sync) { + return Promise.resolve(sync); + } + var mt = getMiniTool(); + if (!mt || typeof mt.getLaunchOptions !== "function") { + return Promise.resolve(0); + } + return Promise.resolve(mt.getLaunchOptions()) + .then(function (opts) { + return readBuildVersion(opts); + }) + .catch(function () { + return 0; + }); + } + + function setLocalData(key, data, encrypt) { + var serialized; + try { + serialized = JSON.stringify(data); + } catch (e) { + return Promise.resolve(false); + } + if (typeof serialized !== "string") return Promise.resolve(false); + var useEncrypt = !!encrypt; + + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + isClientVersionAtLeast(buildVersion, STORAGE_MIN) && + mt && + typeof mt.setStorage === "function" + ) { + var payload = { key: key, data: serialized }; + if (useEncrypt) payload.encrypt = true; + return Promise.resolve(mt.setStorage(payload)) + .then(function () { + return true; + }) + .catch(function () { + return writeBrowser(key, serialized); + }); + } + return writeBrowser(key, serialized); + }); + } + + function writeBrowser(key, serialized) { + try { + global.localStorage.setItem(key, serialized); + return true; + } catch (e) { + return false; + } + } + + function getLocalData(key, fallback, encrypt) { + var useEncrypt = !!encrypt; + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + isClientVersionAtLeast(buildVersion, STORAGE_MIN) && + mt && + typeof mt.getStorage === "function" + ) { + var payload = { key: key }; + if (useEncrypt) payload.encrypt = true; + return Promise.resolve(mt.getStorage(payload)) + .then(function (res) { + var raw = res && res.data; + if (raw != null && raw !== "") { + try { + return JSON.parse(raw); + } catch (e) { + return fallback; + } + } + // Retry without encrypt (migration), then browser + if (useEncrypt) { + return Promise.resolve(mt.getStorage({ key: key })) + .then(function (res2) { + var raw2 = res2 && res2.data; + if (raw2 != null && raw2 !== "") { + try { + var parsed = JSON.parse(raw2); + return setLocalData(key, parsed, true).then(function () { + return parsed; + }); + } catch (e2) { + return readBrowser(key, fallback); + } + } + return readBrowser(key, fallback); + }) + .catch(function () { + return readBrowser(key, fallback); + }); + } + var fromBrowser = readBrowser(key, null); + if (fromBrowser == null) return fallback; + return writeNative(mt, key, JSON.stringify(fromBrowser), false).then( + function () { + return fromBrowser; + }, + function () { + return fromBrowser; + } + ); + }) + .catch(function () { + return readBrowser(key, fallback); + }); + } + return readBrowser(key, fallback); + }); + } + + function writeNative(mt, key, serialized, encrypt) { + if (!mt || typeof mt.setStorage !== "function") { + return Promise.resolve(false); + } + var payload = { key: key, data: serialized }; + if (encrypt) payload.encrypt = true; + return Promise.resolve(mt.setStorage(payload)).then( + function () { + return true; + }, + function () { + return false; + } + ); + } + + function readBrowser(key, fallback) { + try { + var raw = global.localStorage.getItem(key); + if (raw == null || raw === "") return fallback; + return JSON.parse(raw); + } catch (e) { + return fallback; + } + } + + function removeLocalData(key) { + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + isClientVersionAtLeast(buildVersion, STORAGE_MIN) && + mt && + typeof mt.removeStorage === "function" + ) { + return Promise.resolve(mt.removeStorage({ key: key })) + .then(function () { + removeBrowser(key); + return true; + }) + .catch(function () { + return removeBrowser(key); + }); + } + return removeBrowser(key); + }); + } + + function clearLocalData() { + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + isClientVersionAtLeast(buildVersion, STORAGE_MIN) && + mt && + typeof mt.clearStorage === "function" + ) { + return Promise.resolve(mt.clearStorage()) + .then(function () { + clearBrowser(); + return true; + }) + .catch(function () { + return clearBrowser(); + }); + } + return clearBrowser(); + }); + } + + function removeBrowser(key) { + try { + global.localStorage.removeItem(key); + return true; + } catch (e) { + return false; + } + } + + function clearBrowser() { + try { + global.localStorage.clear(); + return true; + } catch (e) { + return false; + } + } + + function getLaunchOptions() { + var xhs = global.xhs; + if (xhs && xhs.launchOptions) { + return Promise.resolve(xhs.launchOptions); + } + var mt = getMiniTool(); + if (!mt || typeof mt.getLaunchOptions !== "function") { + return Promise.resolve(null); + } + return Promise.resolve(mt.getLaunchOptions()).catch(function () { + return null; + }); + } + + /** Read miniToolSnapshotInfo from launch options (comment re-entry, §3.9). */ + function readSnapshotInfo(launchOptions) { + if (!launchOptions) return null; + var raw = + launchOptions.miniToolSnapshotInfo || + (launchOptions.query && launchOptions.query.miniToolSnapshotInfo) || + (launchOptions.referrerInfo && + launchOptions.referrerInfo.miniToolSnapshotInfo) || + (launchOptions.extraData && launchOptions.extraData.miniToolSnapshotInfo); + if (!raw) return null; + if (typeof raw === "object") return raw; + try { + return JSON.parse(raw); + } catch (e) { + return null; + } + } + + function callApi(name, options) { + var mt = getMiniTool(); + if (!mt || typeof mt[name] !== "function") { + return Promise.reject({ errMsg: name + ":fail not available" }); + } + return Promise.resolve(mt[name](options || {})); + } + + function writeTempFile(dataUrl) { + return callApi("writeTempFile", { data: dataUrl }).then(function (res) { + return (res && res.filePath) || dataUrl; + }); + } + + function saveImageToPhotosAlbum(filePath) { + return callApi("saveImageToPhotosAlbum", { filePath: filePath }); + } + + function postNote(opts) { + return callApi("postNote", opts); + } + + function canPostComment(buildVersion) { + var mt = getMiniTool(); + return ( + isClientVersionAtLeast(buildVersion, COMMENT_MIN) && + mt && + typeof mt.interactionOpenApi === "function" + ); + } + + function postComment(payload, saveToAlbum) { + return callApi("interactionOpenApi", { + payload: payload, + saveToAlbum: saveToAlbum !== false + }); + } + + function getStorageInfo() { + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + !isClientVersionAtLeast(buildVersion, STORAGE_MIN) || + !mt || + typeof mt.getStorageInfo !== "function" + ) { + return null; + } + return Promise.resolve(mt.getStorageInfo()).catch(function () { + return null; + }); + }); + } + + function canUseFileSystem(buildVersion) { + var mt = getMiniTool(); + return ( + isClientVersionAtLeast(buildVersion, FILE_MIN) && + mt && + typeof mt.writeFile === "function" && + typeof mt.readFile === "function" + ); + } + + function getUserDataPath() { + return getLaunchOptions().then(function (opts) { + var env = opts && opts.miniToolEnv; + return (env && env.userDataPath) || ""; + }); + } + + function ensureDir(dirPath) { + var mt = getMiniTool(); + if (!mt || typeof mt.mkdir !== "function") { + return Promise.resolve(false); + } + return Promise.resolve(mt.mkdir({ dirPath: dirPath, recursive: true })) + .then(function () { + return true; + }) + .catch(function () { + return false; + }); + } + + function writeUtf8File(relativePath, data) { + return getBuildVersion().then(function (bv) { + if (!canUseFileSystem(bv)) { + return Promise.reject({ errMsg: "writeFile:fail version" }); + } + return getUserDataPath().then(function (root) { + if (!root) return Promise.reject({ errMsg: "writeFile:fail no path" }); + var rel = String(relativePath || "").replace(/^\/+/, ""); + var parts = rel.split("/"); + var dir = + parts.length > 1 ? root + "/" + parts.slice(0, -1).join("/") : root; + var filePath = root + "/" + rel; + return ensureDir(dir).then(function () { + return callApi("writeFile", { + filePath: filePath, + data: typeof data === "string" ? data : JSON.stringify(data), + encoding: "utf8" + }).then(function () { + return filePath; + }); + }); + }); + }); + } + + function appendUtf8File(relativePath, data) { + return getBuildVersion().then(function (bv) { + if (!canUseFileSystem(bv)) { + return Promise.reject({ errMsg: "appendFile:fail version" }); + } + var mt = getMiniTool(); + if (!mt || typeof mt.appendFile !== "function") { + // Fallback: read + write + return readUtf8File(relativePath).then(function (prev) { + return writeUtf8File( + relativePath, + (prev || "") + (typeof data === "string" ? data : String(data)) + ); + }); + } + return getUserDataPath().then(function (root) { + if (!root) return Promise.reject({ errMsg: "appendFile:fail no path" }); + var rel = String(relativePath || "").replace(/^\/+/, ""); + var parts = rel.split("/"); + var dir = + parts.length > 1 ? root + "/" + parts.slice(0, -1).join("/") : root; + var filePath = root + "/" + rel; + return ensureDir(dir).then(function () { + return callApi("appendFile", { + filePath: filePath, + data: typeof data === "string" ? data : String(data), + encoding: "utf8" + }).then(function () { + return filePath; + }); + }); + }); + }); + } + + function postVideoNote(opts) { + var videoRes = { video_url: opts.videoPath }; + if (opts.coverPath) videoRes.cover_url = opts.coverPath; + return callApi("postNote", { + title: opts.title, + content: opts.content, + pageType: "video_publish", + mediaInfo: { + video_resources: videoRes + } + }); + } + + function readUtf8File(relativePath) { + return getBuildVersion().then(function (bv) { + if (!canUseFileSystem(bv)) { + return Promise.resolve(null); + } + return getUserDataPath().then(function (root) { + if (!root) return null; + var filePath = root + "/" + String(relativePath || "").replace(/^\/+/, ""); + return callApi("readFile", { filePath: filePath, encoding: "utf8" }) + .then(function (res) { + return res && res.data != null ? res.data : null; + }) + .catch(function () { + return null; + }); + }); + }); + } + + /** Write dataURL to temp, then optionally persist via saveFile (9.49+). */ + function persistImage(dataUrl, relativePath) { + return writeTempFile(dataUrl).then(function (tempPath) { + return getBuildVersion().then(function (bv) { + var mt = getMiniTool(); + if ( + !relativePath || + !isClientVersionAtLeast(bv, FILE_MIN) || + !mt || + typeof mt.saveFile !== "function" + ) { + return tempPath; + } + return getUserDataPath().then(function (root) { + if (!root) return tempPath; + var dest = root + "/" + String(relativePath).replace(/^\/+/, ""); + var dir = dest.replace(/\/[^/]+$/, ""); + return ensureDir(dir).then(function () { + return callApi("saveFile", { + tempFilePath: tempPath, + filePath: dest + }) + .then(function (res) { + return (res && res.savedFilePath) || dest || tempPath; + }) + .catch(function () { + return tempPath; + }); + }); + }); + }); + }); + } + + function getFileStorageInfo() { + return getBuildVersion().then(function (bv) { + var mt = getMiniTool(); + if ( + !isClientVersionAtLeast(bv, FILE_MIN) || + !mt || + typeof mt.getFileStorageInfo !== "function" + ) { + return null; + } + return Promise.resolve(mt.getFileStorageInfo()).catch(function () { + return null; + }); + }); + } + + function unlinkFile(relativeOrAbsPath) { + return getBuildVersion().then(function (bv) { + var mt = getMiniTool(); + if ( + !isClientVersionAtLeast(bv, FILE_MIN) || + !mt || + typeof mt.unlink !== "function" + ) { + return false; + } + var path = String(relativeOrAbsPath || ""); + if (!path) return false; + var p = Promise.resolve(path); + if (path.indexOf("/") !== 0 && path.indexOf("usr") !== 0) { + p = getUserDataPath().then(function (root) { + return root ? root + "/" + path.replace(/^\/+/, "") : path; + }); + } + return p.then(function (filePath) { + return callApi("unlink", { filePath: filePath }) + .then(function () { + return true; + }) + .catch(function () { + return false; + }); + }); + }); + } + + function readDirList(relativeDir) { + return getBuildVersion().then(function (bv) { + var mt = getMiniTool(); + if ( + !isClientVersionAtLeast(bv, FILE_MIN) || + !mt || + typeof mt.readDir !== "function" + ) { + return []; + } + return getUserDataPath().then(function (root) { + if (!root) return []; + var dirPath = + root + + (relativeDir + ? "/" + String(relativeDir).replace(/^\/+|\/+$/g, "") + : ""); + return callApi("readDir", { dirPath: dirPath }) + .then(function (res) { + var files = (res && res.files) || []; + return files.map(function (f) { + if (typeof f === "string") { + return { name: f, path: dirPath + "/" + f }; + } + var name = f.name || f.fileName || String(f); + return { + name: name, + path: f.path || f.filePath || dirPath + "/" + name, + isDir: !!(f.isDir || f.isDirectory) + }; + }); + }) + .catch(function () { + return []; + }); + }); + }); + } + + function cleanupShareDir() { + return readDirList("share").then(function (files) { + var chain = Promise.resolve(0); + for (var i = 0; i < files.length; i++) { + (function (file) { + if (file.isDir) return; + chain = chain.then(function (n) { + return callApi("unlink", { filePath: file.path }) + .then(function () { + return n + 1; + }) + .catch(function () { + return n; + }); + }); + })(files[i]); + } + return chain; + }); + } + + /** Convert File / Blob to data URL (offline, no network). */ + function blobToDataUrl(blob) { + return new Promise(function (resolve, reject) { + if (!blob) { + reject({ errMsg: "blobToDataUrl:fail empty" }); + return; + } + try { + var reader = new FileReader(); + reader.onload = function () { + resolve(reader.result); + }; + reader.onerror = function () { + reject({ errMsg: "blobToDataUrl:fail read" }); + }; + reader.readAsDataURL(blob); + } catch (e) { + reject({ errMsg: "blobToDataUrl:fail " + (e && e.message) }); + } + }); + } + + global.XhsBridge = { + getBuildVersion: getBuildVersion, + getClientVersion: getClientVersion, + isClientVersionAtLeast: isClientVersionAtLeast, + setLocalData: setLocalData, + getLocalData: getLocalData, + removeLocalData: removeLocalData, + clearLocalData: clearLocalData, + getStorageInfo: getStorageInfo, + getFileStorageInfo: getFileStorageInfo, + getLaunchOptions: getLaunchOptions, + readSnapshotInfo: readSnapshotInfo, + writeTempFile: writeTempFile, + saveImageToPhotosAlbum: saveImageToPhotosAlbum, + postNote: postNote, + canPostComment: canPostComment, + postComment: postComment, + canUseFileSystem: canUseFileSystem, + getUserDataPath: getUserDataPath, + writeUtf8File: writeUtf8File, + appendUtf8File: appendUtf8File, + readUtf8File: readUtf8File, + persistImage: persistImage, + unlinkFile: unlinkFile, + readDirList: readDirList, + cleanupShareDir: cleanupShareDir, + blobToDataUrl: blobToDataUrl, + postVideoNote: postVideoNote, + getMiniTool: getMiniTool, + STORAGE_MIN: STORAGE_MIN, + COMMENT_MIN: COMMENT_MIN, + FILE_MIN: FILE_MIN + }; +})(window); diff --git a/apps/miniprogram/xhs/release/icons/1psim.webp b/apps/miniprogram/xhs/release/icons/1psim.webp new file mode 100644 index 0000000000000000000000000000000000000000..a64841a19818f8ead26f500917662e3726997305 GIT binary patch literal 3872 z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file mode 100644 index 0000000000000000000000000000000000000000..6ef85adf470884040df4309c59712843f96a0977 GIT binary patch literal 1458 zcmV;j1x@-=Nk&Gh1pok7MM6+kP&go-1pokW9{`;JDqsL$06vvKnnJis~G{>u7*{gU;r^dsm2`vKNv=mF)u?6>{G)?$Yi_ND3B zl%x12U|4d088_k1PV<}Q7JgB6N_48woGRBg`|V~K+Ju7wm!juYDVctiEB=`WYvEC2 z+7)>UaXq-#C0PZAqXzQr`Rd-UzD&k#jAGXx3bzspip6Yxt@h;A^vm zxW76{K&VPqC&()85IukoVY?z;o>-TepNof)S&fiM4Cr*b^>3Q=Ye#3B-fhuHmp_Vv z*ttPM|FrR~lhi*dzfBZYY_eGQm;YuS@GE()fW#aorR{~F3OS@Gc|0?e`j-JX$g@8w za*v=6w<8N{p31?~RGF`;0W22rK6GtmStx54R{2*dxY%|HZFuNn+s(0t#1A(se_D1d zLS?&6Pg&^?`NOMZTq7Ltjpxo(CPu(E2vo~LU6oNBLL~?0^>vi0iKvf$mC##q{_iCJ zEkf;6(F80}qDRdP4pBXT@Y;tlv1)8@a;#r z7|bL_gJh{G^!yM!HR85P%ZvAhWxmlsr8F@`Hv1U3j3iu=B8|&9j*cPm6N2s{9qn`; z;Dru>q*K!;evLatMeB%#EZ+jrnRShr^Q*47_{0bq56>*_+DfO&{}P~5X(nq)wQ2zvBbK|11-AVmv6Adopg zGq*OXRPS|nkSF9oBS9)zy#g+T_pjo7O=PEAz93ImPhD0q`S%A={PEXK5k#k$h!9qX zZvm*W*;4!tp`%H98iHSQU_e#z1dn7!P4~=sCTIU!xGVyH{#;l8Axtwo$;DlT6HffE zF+gQW{-Q`K+VGt7^&1u!SQAMW)Od|>ZE0(4XK;@9^{E_4tmtl-+RU>^+MfZnC_1;0 z;4(f%&+0W+cnjsf~OLH@Il+zw^-9Rm@O{{O~5waDcaTS|VtcPPThQd4XUk*yp@$fUthbYVv7 zSz#?$T>Yn|3dJ{!3Be~IqdJqu>fQpfO=H=@X5LcPhd@P=ePP7}6F-WTG5p$lH9uSTVW0K`k0$9ajS zUX~v8nL~%+Rfs*k*!4o3^&$F8`J3#w9v2LI&g(Ec>ZKFfE4?@1n^5mWg!K8-)LnP1 zu57XwU9AbP!CLVWu!P=VNq_uXax=&sIuL+)P)(sF$q5Rai~@d9w<~L!Sn`si8@L=* M+Z}8o9{>OV0OM`LhyVZp literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/9esim.webp b/apps/miniprogram/xhs/release/icons/9esim.webp new file mode 100644 index 0000000000000000000000000000000000000000..e26050680cd9c270da0df759b114fff2c4346c25 GIT binary patch literal 1254 zcmVbQsU*fmd{RetmJgF}GKOtS0hTZ<{WxGAfcuCSzGT$TL zPa3ykLzC#+#Q)mxFS})zc+z`|a!=w*UL6^eC3-shfGf8d5MTgghx{!`J05oew$KK? zT}q82#8!TW{rD_X@{aN+kgMWQUjSk2QeO7QPkW6pB4Q*#bJX{V7tfHH|*;y&1&lj;QDMT}c6bH6hir!A00 zy&>(Ji|w4|ct+jd9ybqPUQ97M#V}UYx^!T+1N0W5S`rn@H8P;xhA&;D7i=L`>|>#e zGgTG&&sK_E1G2+>W+8d{S#?YZEQI1N%>>8yxf8yZZ`sK(k7TQm?O@dyCNkMhYOSbn zC`-XZ?ai=VgJw1i#SL(m>=nkC_B7=2yJn5}qbfIM$>&Zl%Y634=SJ-A|Cbd?T?Ro6 z9(L_};j#a@{=3waH&~8#jfE-j-fI)Fjr#|tr(hSx?nWlVQiRqb zB?Mo;GMTPo`Va~{#+f1W>7d{c`=1sl(+7_i-kmBC4q8Y@22>AfX(+=47Dd@ z?)I?d968;O?%IKoRa!y(91>#UC(l^8$RrZFRc+(|gq+w!|5yBHhQ3}imnR>IE`u!% z88O+vb=!>y@1@Z%nHiPSPzHR!nfxH&#XyyP?ThIRd{b~h?~p{1XJHa}FzSwQA4_nW zTe~J?M&%G;76C7Z2Lwtm1V%v|!&6VoC2tMz#jmGHsITjJXesAz9*V30N5B6;NoXrp z4*7qo7O?Uzmck#RnW5O^5IaRXGT!uE<`@SKD7m=rE$-lnjPeamU}&m@DnHE036FdFCU&{N% zZc4SC9nyRiU-~S?mj-yA-0?I#c!~$M-gSoEWaPIK0*6QX+)SfseJz~FKea$FwIe3g QDJ1~5>W~xY^peOx0K5!mng9R* literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/aapanel.webp b/apps/miniprogram/xhs/release/icons/aapanel.webp new file mode 100644 index 0000000000000000000000000000000000000000..75eabea951d2d14ce0189d66af59eb3398a5db95 GIT binary patch literal 1970 zcmV;j2Tk}=Nk&Gh2LJ$9MM6+kP&go-2LJ%jAOM{KDqsL$06vvGm`Ej~qMW!uuto+Tt7)CT~N6YkGnxUS%gM3Rl>3NV3orzx-5-J z!iXJyx!8^0eT~bhd%L+nr6VpbM(9o}*0+o|9(Tv6knzw6WvBg%zw;C9ne*iqQ&qLm zoI<)+M}wcvO;1WlkV$2;lBDjIg?hFc%6NR~xzT^rvVPYUFrBVeM1;f%bs=X+w}jNAC;$Nd{dXWdjf~H+LxIVb{$JN8=+4^r$;o5n&g1f~f5m5JOZ{)e zf1-hy5!ZNaamwdWfp8rUh^9K*Z{DD7s!n#@7Z6M{ziN-V|EIpf6H@=DRyKV^BkVB! zl?cc^mB?bHpYFtSDQ|du)mlM?0yur*Tja?>0xw8jx53*ykeh8l{sIc8Ud!v58`Z!E zOa$PI37&|3Owe=9%v-&^hXEm4lDb$UAG-15F460n+AS*ti_|Rf;Um%{{2HCb^c&M| zkLJ0*NFaIdpY;A*rC<0vE(1%E6MCjN7*MXpZvl&~moCx^RN3;EdtBpQD~d?Z6wj(; zFLR!C*-ZGn+h=mK30pPWaJhQOY)2Y~i~#lbqGIn?()VO|%`~4LX?8vI00=+`-ZJr9 z9D7AN`~PZHtE_6rKQsztM;C0*APx)Fl!cagbPc9Y)6Xhgl=|+M+}pXYu)cq;1Pr%Y zkGijEgI=k6Bo&+>8$|q>{)_I=GA@gOdFADcm;UXRvLrq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ji;f@TK1{tbKdC1(nHA6b7dRwc)qI+pELG-)nFH*FLN0lBBtmJ1_lkA^$-#dA^fUbS|U-8ZmdDOEuiNF;%6eTj-*) z!_XrEP!dd`Qw*z9kVzOHml>=Uli ziBnt6ZnS9z{>u**lI)Yjm|2#%P_a*Mhu#AmwNM$p{=@I5QJ#MyOFoU@|3C(IJj;zh z{!<*)ofX&87N6%udB5fd6&sdj@y{~dT35gJx;+!Ixo-s_B>7IR@-#AW+w{s@h|HJ= z$=Mc!7{~JXoTQ`*lQIFYH&SB<2%vPQ*0HAzCd!M99s1qQc2vn&_Zwhj89=6!-Ax5^ YXR4yCLWJh%6GE0ZSITf_fB*mh0BX~9wEzGB literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/adsense.webp b/apps/miniprogram/xhs/release/icons/adsense.webp new file mode 100644 index 0000000000000000000000000000000000000000..d6dcd29840489b7b879e32e0a81c2fb0a7127717 GIT binary patch literal 3068 zcmVG6)|f{hxVpb>BpVv^khBe1jDv%Bf+^RrxUvWz)g3E=>G&{U(dI1 zM2|)at$tmJ5-YD4^;NQncxGft%IdjWV zS$~yS)PT)E0R+1~v-lU`1x5%E2!nay@7g|q{XQs>fYHsujeV#89j=D3{G`kb=H{_9 z82Y^s{40=Ibe20vGc>p*FcLu*->-q=w)+)NsT#PZ=!%~HeixbRb0c091YJaLIkMTC zSwqP@aoiV?+2Q_X(J=1SKKvN;Em>eLZ)V@1?d~`=7iOm8y(L8Oj+0i7q>s`&RZAMq zc2)tjd?Sl?Pa1g=M#u~)yshA5miuWamnGg+CWO69$h~&M#M13*^yItH+*O##J7I>x zn>NB@~pdau^ zQ6MVQ=Bz1YVP<76w5aifq|t0ICMBp6T@raxQ)x`X-L)ETdLoYnqpMOTCe_n&&vuSk z+id`vQkCxUiRUZK{!q$@@~*p;EZZq;!j=`7I$Bu>Px(dIRV9gp$-qK`YjisUOV!pt zoHGW5u>FazYQpbs=`8?wq=g#`)kizQ0Sy@@7VfPPs7LP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git a/apps/miniprogram/xhs/release/icons/ai-glasses.webp b/apps/miniprogram/xhs/release/icons/ai-glasses.webp new file mode 100644 index 0000000000000000000000000000000000000000..63c57a12c1f41f3072141d81c7c489dc07198694 GIT binary patch literal 682 zcmV;b0#*G|Nk&GZ0ssJ4MM6+kP&go#0ssI|4*;D3DqsL$06vvOol2#nqM@c%+mNsl ziD>{9*R2pg8HrCzyFHUVZ6<1{A)$FRb;@!xHKOIb?MS=zd&f(i6_MPlwvN79ll?R;yd z#1t{g@RYVbF$ZI$QRM7r-!#@SL#KaT3LZ^+X{%8L@si!)gqQ~smhZ{$@Vk zFLGY9Z*NW^R8+k^gC(p4`0TS^R&#TL$ZCgmNH$p?wI$j8EsGRfb1;58+(f&*BeZWJ z)-D)rWTA?01<|_Z5sx?3OoeLGKoCcwnbDRJqVrn+S!Q8MvpDpjU+H{XcMuz1L|zPY z?kr#jkgI-fYC&HM4i4i3k=|Lk#i|vt<5A8#n$lcSrM8Wha5hBIs;irLy*YI`K7&Jy z`(LpQJp`0{wgN-};2e5epIw@13fpqqq}CftIg}U1KPiYa`WVWMgV+@BXuc^G?DFB* z4w?|3R7bnHcBTuFQ2B;T)8>4TWqb~0jBqy-bzcQs5fC>m_c({7SN7D9TU|DrxY-_v zP>8-h*tWr38a+#`T~wSS{xO ziD&@T@zH)~s|(%#CVv%rc{xe}PV^Z~vj481fFAKkf5dXI#DdhX>*kEjM}FLOlCLSpYapUvq@x2&Hkuq$iESo%=Py%UwcI_NXsXG1hCHbWV-V)&|9?V5k zX&Rft-&4$tEF5WPOW*K$s@r_nCv9nfyZHQjN8v`a*6kFdxbgPnv^6IHh#%v17Wc^T z!t>t$fe(NJO#<#fcA%e21D1qym9<0AffJSh7);k6wOhMX7ro?PX*lUmzq;S8orQK& zd^{_M0Wa#Dl=H7MQ^`3KbnIEN_N6PoKmfDe@WTQW!SJ| zA{Tww_V(pR<|^XNy_3Ey;nGd%sg8bJv1vm3ITK=3JqSo?>(Z|nBkshL!F9)Xw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QT8%Ut~Tk^4c`dTnC+W;-HQG+qceh- zDom$BEY{FOj9Er6UvZZbQmjB2>2{MWtLjlUN(0A-Kk0sXGeD)w>l&Xfy>X3t0aY<= z!v4m0m9AbUCb*b*l`~dgCO83IY^=QB+7UU-pYm1@Ej^?t4H6i;mVYeRkA(gWVT{)y z=d>nl0ff=qUH3K{ZA(O+C*Yb)%&J8?u@dH5az5MRUS?MqeMM)cdmaOW9)~aFD}PRs zeh%vkX}@;74e`5wCKcVH>CBUjN%=l#^6X5K5~1;`sux0MlIJqv-~zGs@ZQODV=DPD z^?FN|_P+>7SL-@jV7~N<_POHt?iW-7Uf}zw*8w|eS+|cb|2jQJuQw4byBn2* zZx(A9R>jj5w{p~BG_lpIa~}T)M7j7>Xrj2yN0!M01uU1^=|r-HFOm=i(-UHP$$`HQ zhuWW&-EL@nZjGm9j(zGG(7oMukp&vI>@`XNtt5mC0JeM$IZ9f2kj7e4wp-I%yd*SI z{aynlcd&#doWKF%?lkKkKM6s`hFJ`te(KV_B}0l%8E7QwagLVUeMm1%gRAlx1jbrR zuXYl%jJ+@Q%2~;L_>Mu^Ys9{6<>Po&o$*I_`)Vo;zef8lE}f3QuNk_PwW1bjXKPw5 zKyzH>KkEVBYT$XBJ~5!ZJ9M)K&<=_(b7j}MfZaOfoOQA$lkrq-n=`cE_QGXd@I*kn z{`{^eXUzJXk1z*)6%Ned%_Pm<^O8ur5^r#6PY=!UI||!y%|1c)L5^edN?oIRg(@)X zAU{&iU&}o+P_1Aa9~pK6(Ub>qVF72xIbf9~Yd@08fvv0zuJO|Zgm&<|JX^uU$mfZo M<1id3000000H_F|5C8xG literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/chatgpt.webp b/apps/miniprogram/xhs/release/icons/chatgpt.webp new file mode 100644 index 0000000000000000000000000000000000000000..4d86031239b0e670f3925eca522858e3297585c1 GIT binary patch literal 1378 zcmV-o1)cg*Nk&Fm1pok7MM6+kP&gn?1pokW833IDDqsL$06vvOn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s=}an42W;PBd#FFzKqVAmUw|_7hHuvN-Gd zzg<3X$zgE*b$&F{rs_|`l*R)Zo4UM=^l$p;=kN*^?8Z%K*EH7UO9No@2bP)C+*f5G kr;u7Z$&}Og6z$nDtALJ*(NSyT>@1gySNl;c`gH&R0Ho%&tpET3 literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/cloud-phone.webp b/apps/miniprogram/xhs/release/icons/cloud-phone.webp new file mode 100644 index 0000000000000000000000000000000000000000..34036ed163710ad5d5ee953993d49de017641883 GIT binary patch literal 724 zcmV;_0xSJeNk&G@0ssJ4MM6+kP&il$0000G0001A003VA06|PpNcjK&00DrSZQHWt ze%|-Pr4eaPa}uoZk3nPs*8zxRm+UUl-Pyulc``Td5itRH?S=9gnZ$rm5-ZO`EORL5v;8cy;LQPh>iitbasUFLJ#k#$0}um zUJ+DV-s3y`P7Xyrm*>63Z%G9QqeX!L z0RH@4GHpQEr7&{bS1{5v1QU0B<84%W9sh^cR}2z+86qgetLLWxBhVt`OaOO)0^@8R z1S@K_`7FpTSf<sO$C2=3X%iKO+8Z)s1{eh9jxw0MYHs& zeLQr^F}5KJfbkF>)Ge&(lGM6JbU@@S1f$*un7!cp*sr&5%OLp34gylMpq#$NP(}h% zKbHsKCUR?odI0@Ye^h)8bZ!UO{o@7B$&rN)+6jJzgg$rcl+GdkthFC5z7dF@LwWSjEs=GyKR3=$q5yrvsoIHO7FOm>i-6!E{<)<}+ppysTLzk$Vn zSLZYkqM)g}Cju<{k2X{zVCelMIg2fbz8)jvoMqHK24eYms)b{Q!H*!uzxoPqp5DEqSANSAQ5TOKMvyM-Ty4&%ekfZzE z$24lLHkMMNYIh5``DUh?l1g_oI1)Okqoc%}C~!3M$LjIp#trY?s-iwNJ)fj<1t2TI z@BjV$(#k&Njq(`GP6rM%Sy>sWiBZ?v9j%3|$u|Lt&Z~2(vm_|I9|wTwj%rF)gvAbF z0f~27$k`y4y=Xw%)lU382$ZG*Wt*PI1K?COaqbHC-FfeqGXay}Nn36T4BC0;KLY>^ zBJiiLAqPRpaUTKUeSWHL=DKIVsSl{lWB!mq7n1R;U zReB;QumkXpoU;;TzdMM*g95~~<1c2P3Xy{MvM~Emgp~OSn13&-t@jVL&xH%LaH96K zfTOt^v&1VlX{`um?#)JGowt1h+FPbIl@Y=him?`n`6M5#09H^qAhZGi01y%YodGIf z0AK(ad)FnW3CVTpe7(*C#CN3!m=CZIdoMxzz#Gb+ zxtJ-vsmPiidAvC?H^|=$aT#PQH0n{NT@1`E&X-K1h=KnI)39QG3tf%H$hp5%lvLDT0!L6z|p4GXTpyX7~X9`<%c43UAaU zPvqrAj--CP{fV})14>j^?@+l6(L(V>eYS;?QkIC@pGrb*65LNIL`Z+XY=k(ljm@h6 zpTNcK-$(mPU|LMm0m*LPfO8TPm?)7|gZ7)XN#EZf3>;QIIQ@b+o_~U8VbJl-H&EUo zF>3txzZ!5g;R`iVIlYbVx5m~NQQ^@u?gr}N^tQG3=OExS#z8My2D$P%;xnl|cTT!= zR1-OOBx44wv{?#}#m+bkm)~p-FsiuEtaKR^Dm(WXiprE=KVKw_9IM>^n&Cc(!+`b6 zRoq|DN>zlQQew!S((FnDAA~5zMJWXP^Id*xVLx(aO73MRI*z(`l>289zScJyVp&hr z!0~R!OGfUierE8>lgGi0@^0lz&VZNxRO*L9ity`tq=l?$<9Uk{#X7e~7$tZx!7ryv zt^Ss7@F-nk+ayGDqlBJ#LgO2=%eOpnAcdW~QIJ{-fhcOv$@Dn|!nf4;~H6rgUFkNMD{wIm;tic`ET)FHTJ#uU6Ad&n|I~u6wNA~q% zC3TFjqfp}?$8%8@Dv*jM@)zqh$wNH+E6!xuaeqB3^}5*Yt5O6Nx6W`$X8-y;mcXCb M6S3Qv5C8xG0INuR_5c6? literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/colocrossing.webp b/apps/miniprogram/xhs/release/icons/colocrossing.webp new file mode 100644 index 0000000000000000000000000000000000000000..06dd41c529e2c28287e90ff546844db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^Y!C6 zXPW;)Zk?`taMB}ugG&|aaftA*VRjLl#`n)L7zWlG%zl&RSr3M1X5qB+}oZms_ z(g9!yMzh3OKY0qO%*|)6#`4!9SP+&@-;nrw<75S(d)Ma&6$>Cb4py*B zjp;dBH+1@auu?ztZoMFcr0ubb2UXH3 zoRT7C)`9qJ+wXiP^Obq`$irYk*J+RJ8$$!2FQbo*Ivf~V4<|o8CBG>|nf-+*U_1-k zpXHp%y~0ydw~XGdAud>dkk$v{-VV1QeBZ}oL4LV;ldGavIQ$8^vlTKQldu4~U?BOv z`M$zXvrPV#csh!4@%Nb&eU@0g%k&NZFKL%M|iEV%@UQ&Dr(I8hQfTGKRp7*#Cd|KJP-?FCSX}gD& zRG|%VG!JG6$^l3PDy0|fEG4ot{P^$H5ORa!xG%C**^uzjxf9_`G=|NEN`k^VV7_3s z@~DW7)HcH?KM)IVEG{=KH?ooqUu$zq5Bp^`t>JjmBn`RQsy=YCH4Ez6PC}$4|M6=L z4g%|(RJJDvJJ=|0=eZqBLD1K{C-oO+?qE7BK<}!NtWSwlam1r0gi5W(KRBn8A<_qD zHGKoHF$raj8gs?v%S^ulXm1UV$5|CP7BNnYC?D&d4Br0J09gOMjXqf?d^ipEW_vrg zV_rjs7;Sjm6Vtq*P!{=g=`>F@l_Dy{cU6Qzg+&tLFL#q!{gJHXd;awI#nOR~y0G(89v sF*D;-M}>)6naJ7(;f!)CkEtQYa>xEgNhzsG;svFGS{1_swMYN}0Q^O4vH$=8 literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/creem.webp b/apps/miniprogram/xhs/release/icons/creem.webp new file mode 100644 index 0000000000000000000000000000000000000000..f8b751ecf8a21e654e78c5726542bad5b55c169c GIT binary patch literal 1242 zcmV<01SR`YNk&G}1ONb6MM6+kP&il$0000G0001A003VA06|PpNZbPe00E#xYkQ$V z`YP47?e4K{8#~*!ZQJ&&?3tx)+h*ISAQmbA?1Vl-a>NX%{oZ94~7rUVR z0WD4Hg(>T91jk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%Tm3U;$7m&$7{c2Dha<)(k0J`m@P=imwzXV^@jw?LvC5Ksi{~ z>#mzt0$Z(8^{@fiwjx!mhP*DbPAboWXjyj0z9fLA3O!FwYi-yp?_FY*8NaYdZ7rlr zq2tHIYFu7vi^dNbpO$I=sObDfo0JS!RM!jP`9Me8&j>>bCRt1VS6ZmDGXMYp0002y CN_EWu literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/dsx.webp b/apps/miniprogram/xhs/release/icons/dsx.webp new file mode 100644 index 0000000000000000000000000000000000000000..de1e117cabcf7c8c50034c8eeeb6a7470bdd5f73 GIT binary patch literal 2212 zcmV;V2wV43Nk>2mk-_I zzu>KJNdxq3(AU;}!T+!waoZFnv6#E?@v$26EsUK8?uo7s#&Fu7TZ7@5MZV&I^v&u; zKH$#32_KRR1xP&$DQXPc1$`BJ%tS6;UHnC;o|4>7R~9fqK5hK(p&8b-1|BDH?@3>V z)^_8kvdijg5IN{Q9O9c$iUV`RcepQEgRKcjByukh+}hFt%fVvW6i!8`UvD1#Y}vQO z_mZahy{vgBKvtKe`I9pJu)erg-M>pTt6?j#q z&0;!;JH)U6{_k$)?!f=WKfi9L@S(u8$R$6Rr0Abqd;=w_0PL{IHT><&;@P2AvLBRB*xfp`puWDb~G*P%?uHcPrZ-I~G?6u(?36w&%B+Y$g z%Y$X%pW}) z8K7kc&5z%))>oLNd>=|KopWxj_*l>vxu?%2bEsO>s@*_yEy36sVI)uO`t|j->mBq? z#j&t4*C;_n(PI9c4>g?#321hwH25@V&iA^!OWMG3j{y!3)jxMQnfUQ-(IFA#?t#-u zZhE5!iJ|D%y!GI$&(HzErZ|)MZa9Yd@5ziUZ0$m%*0fpk9;_gC#IP>Os|O%D&PVou&WEQlFljisXs!t^>bqU&7j|Q14LcuNuE#KNc{gBf9gb zw$MrOb+4-8`$Io@4SmsLa06B-vIkY7q{#A0u&^D_efY_$>G{Z)UoFT;u4+W>n?0Vo zT@B9%qWI%^?{hJVY{T8>A5q5j1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UBGWg!<37AGW2}Z@RQ0gqys!Y mfcqLK9_w}p%-+o~|K=>o&@MuBZ1nPkt{05?z)#l3xBvho-ewE{ literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/ffmpeg.webp b/apps/miniprogram/xhs/release/icons/ffmpeg.webp new file mode 100644 index 0000000000000000000000000000000000000000..8599db3886c7290bcf2adab963ac170ff6142745 GIT binary patch literal 1200 zcmV;h1W)@?Nk&Gf1ONb6MM6+kP&go*1ONcA766?ADqsL$06vvMnMkFiA|WcdT==jO ziDm%M5V=xPS>T@mUAlf_KVUs?wB$FX@DwyNWiL4nCS~}+Eh)1)@&TwXNyKTXh+6*e zu4y&%5V5e992$cYN_ZP9=JK}**yC{vGRA4N@aRFksn&hVoDMVTZ(}oi)PUJwR2#!y z#x3-X7z6gbND`|x04Ve%Jq_5hT*}`8H>aW45CHMr5`zTTIJ8Eg^vluO$(h_=y>h+$Z`sp;t{V8jJYsB4n)^2WzwuFT`(;K7!h%6BA7g9fQ@<(cM!Gl5Rv! zkcLN1DO+-V`8-e4MOw5hEhjHOe;7jsW{ah(DZexvpIgL;sLbHB zI!xeSys>vUK32p)#Rn$m)W9oUsMnr|eFc{kCIo7=_ADyMWh#3xxx8s+IVT&TDtIjw zRvOYA>P%MZ>4ZIZW+9q$+8HFa2dHabM`l?`JK;tahqhU}m%?A3-Epw(1Cj*{HfSTp z(dbK&ewB<2*+}22Gu=SPfTJS+Zga%YP4%;;A#*44zgcBhML%6fgCT2$k%0 zNObx}65-TBxQ{n(N&=%vpqy%yg6F+8y+7KbhmQ+J;qhzx18DG*N|4zlio zkr}k8hGQpbGIu?6PBC5c-N2m#5_mV-sXJ-6jl_7&US&4OKr1QzIVZ?L%&T@(fSy?$ zG{Es58a8ocR2Gz63yk)nHzxku7y+&&MagmMrt@=u!(7ZRg1N=x<(tC{xKf;cIRpNXkI$2ed@#6_w?ceP@0Y>;G44DY{87f9T8RZadTNen%X}_KURH zpWmY)Sn49lL4RBd`xwy9zCr{SXyl>&!_;25?ADaO8(;iYcC7VCFv#Sb&zz(Ykq28Y OAcGwATbrN-{r~_#B1|&? literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/frp.webp b/apps/miniprogram/xhs/release/icons/frp.webp new file mode 100644 index 0000000000000000000000000000000000000000..c6547fe433248c3b777a6a63b6b6185229559da7 GIT binary patch literal 910 zcmV;919ALPNk&G70{{S5MM6+kP&il$0000G0001A003VA06|PpNZ$Ye00DqwZF^$n zO9pp$uiR}5v{X*V9$13bv@C#{EwBPQI(LV$do%g^KdI1&m;iiBSF&Bukgeq@RCNk& zE`gS&vHlQ+k=VDh4Fs|j>K|z-dL0F#G97EW){rK1(=h210F5nLx@oxw1(6dgOHMAXOhKrE zyGjTGckvw^09H^qAbVn?METO<1*$0xVn4zLWJ%?Dm!{T+abGjZ8+Vcw;Xbh(iPLOj7W(g0 z#b0~t6nW16UtA+A{&VX^m3wt$^&-CVjL2|MA2r1&s&7bD^)DhK$JA4KwsNZ^E&j z($tKYSLFJT%+C%jw|Ay(k>8w;BB7hhx_^kPFoOp~zQ!B3GPa!Qu--nfsk8+7W*Qr2 z#Fu+aw>4Iom(3C$=jLJoE4qf~4G{q~Eq2IIYIknwwG(=X&n=(*>%aQL0w7=W=-XH(~0Du^{!vFvP literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/ga.webp b/apps/miniprogram/xhs/release/icons/ga.webp new file mode 100644 index 0000000000000000000000000000000000000000..4bc3288e8dc2efa051798c5b31644878c00517b5 GIT binary patch literal 1876 zcmV-a2dnr}Nk&FY2LJ$9MM6+kP&il$0000G0001A003VA06|PpNQMLe01fbMZQI+n z*|r_$Re%eHRW)_}*Gs*#fdH;{PLKlN_)6|N5fKxBe;*PFB4!ThA@B(+t%-wk>G`(Q zS`mBSb;)6nHq}B)FhC(5cCC%+ATWUIn{|~--?Nl}-#$FrbT9yztDAYL$yydt2;M(G zZPRfoZ%U&g00mH0NkqHd+L#PIyD)Gq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>^t860a0!=C zO@OH?kLK4~686>1U6VeXgME4oSMs)PO9~F{_w#7LFr40Ovx{&=jUa9LA^M(UCb0Jn zibLg*jUz!n1%Qj#^F#>zaKAct3B+DxCak;pDBFbg%6ZD==WZeN_COppM;WyO-Ru@n OZUU?^H(q~_7ytk}D|~za literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/gpu.webp b/apps/miniprogram/xhs/release/icons/gpu.webp new file mode 100644 index 0000000000000000000000000000000000000000..4e0757ecc0a6bef81cc13fa6c543a78508b1833d GIT binary patch literal 1070 zcmV+}1kw9aNk&E{1ONb6MM6+kP&gnO1ONc=766?ADqsL$06vvOol2#nqM@fY3m~u( zi9in*MLP0(Li!lv0QW88iR;`=8BlgSCe1 z7E!YlhZtQ7c!wMg&fRZB*`ruwEHRSlhPiZBI zHd6M@DAZc98SDT6{`!yrG_!bD_Y-A2|LCc|-5{%{sL-&@JszjtL3^xw55IG;H)&~( zZGvX750kNuj>?s0-kN!s|2a?St0898F!o)&QoOk)qbtzP${@|42?y1Q@e)dEqpr@{zyxuv|!l z@CIQDJ~-MU_$g!=TGNb3zQHBdMZeTt>{p<8z(N<#y@M(j4Btlyw0T+)bR8LIb*<{f zN__AO%STi+V7wB%10GfZ5k@5=T#3PegP}t4w&Z-d!BsGw;i7TZI z0(RJ~K8XOGh&xrRK&f;kp|G>`$28tdV0bporOZ*2+)do zEoNsnX@{NB!{m?{>MXsTRmFB?72O@x1aEZAA20Tr?Iel%HB}bXZn46;@n&`pW`+j3 z{WG~Ea#nmbC+9aoS-uc^FWV7WT-DMD=p;RG%8wqdFL5|hC=Y@b3O?t1X|Mn3J=veM zWQvy2U(6>iPbz9#1QA0e59;SwaZM+$;SC(}4iLLeZg7HCAB~)U#khD*qQ}GJ%R9jb zZfRLIf9#8b#$Iw0Rbm1cvn&whRX52C?^xP5>XV2zqYPH$+@$rqr&e!$+lJoM;4!^XY9bRm?38*N49v3R4cHQgTQcD@S8t6Sjj=c}@ z1Oszt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(5p`*6nrUm>VkgtZj!2m+#p0k88K9x$8%CXaoLClDoxqAJ#`UjVJ zd;%;0NC0mU{eGSa(Q2gZ%4(z&y9U9wnCsX#m|PT19CT)q^o_Gm|DSara3D3ZC{qT= zlI?W!MvjBW)M9D&-`3SPHpz~FEbi-qXgpS$B^iNEVdMbEz?0M$vv=>dKl*jCssZN1 z0{>t4v3i7v2$d8KLS4rjPmyE>dH;4@$Z7yUAA2|%sfWU0LUx3NvF-l{TG{g5{qhGH zIRKDZDHAfXEdGN!rp-;aY|4b7Kp@0_Fdg@0__!{+2h!iaef{z6AFpnpZO6LKE}zw2 zZ{_zd>W@cw|M|OOwZ+%GQd#f5YFEvDhp#$TP&gng0RRAS2>_h|DqsL$06vvQoJ*yv zBCMuVnlX?PiD?bVxd0G6+$)L&53u*pA1E!qnUTvBn_C0asby?+cnDXDE5E>byoJFG zANtZw%O9Cs6KxoYZ?=E{{@>ZH10u^y33aV&v^1G(e1P(qm7PO0w673X!HMf@8dUYk zxxb&(nov3-OL_qNu#LqBIY4~M{g7?HUFMWOwI&t!>7^&sU@LXKk73c^{UTa6dkev{ z_o=>He%3vs624wtRs8V$ZmGm-P~4EZqj3>b|K%x?ly+T!j>-lTuINJk|Cw_#RZcrZ zI7IE0@z`e=xzDV)SaX!T4OYXtzyk|qiNd{lPoU~P>L@qwB-x#qfnA(Qve6M=zyi)1 a+K~jR{83*OOn>;O^U@*omA!mQ00012a%fHf literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/iproyal.webp b/apps/miniprogram/xhs/release/icons/iproyal.webp new file mode 100644 index 0000000000000000000000000000000000000000..22747a153904c606cf0c86befc43e56be5e841e8 GIT binary patch literal 522 zcmV+l0`>h;Nk&Ej0ssJ4MM6+kP&gp=0RRB-4FH`1DqsL$06vvOok^vmqM|HwdC;&D ziDUrGfjT7YG}~o4+Vs?U_q~__j&t2^<1P9O^e_8Ykb6K7^YcS$Ko#R2;?5$Q1Ms{t z0QXvq_mXAmvFO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nOm-D+OdrI%NxFXve9ep!@e3O0jEb@A;l@?I=!LV z?>#gFI%KThZ}*S=0rJ6*l{LDg7q!)EyJ;SY$K3$|gEyCIK`>z*QsD+M+W(xp`tcJU(bQAevV&|a?;Xxmvz$j# zLQbgzus*AWFI00^e21#ixeIErH6%gzk|Rw<*(Y%7s^8oR$)D$M|>B8V;#E+d=}ynGttcxI0B3@ zev~zM)egV911vziEh!12Dq$X#0E33)#q zgYOfFUmWdmFxy)zwGcB62C9>yrrI@isNq+9b!rRYKC}4FioZYa9=mZyjphQpAkKK> ze6*1Byl3)IK2)RF|1WWFt#saJ9U2hqI-3gI}G_qFXZ(4>4JKqpmiQOUv3bM~LDS zGC23A2AVvCdiPLLcCJtJcO7Sh$*&0qj+Ii7SVN4qp_uuf?8-i~naQKSM_&L7zw%{0 zZ*J6YHuctGnLvR%8jT?Cy&aS4O{~~0SAF%n4ooCbC zHRy=FZu+VBGNRr4I_3+j{Yr)u58f?yHCU3xbUfHVXi;3iT5<(QgR2ia435YgB|L{h zGQ4MVcw`-jg~kWsO>4M|RYlESD|G}6FrOH70ciuIla7}QjIo~T%x?9c=v+de<~Um0 Ih*8J@04)Qmq5uE@ literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/mini-pc.webp b/apps/miniprogram/xhs/release/icons/mini-pc.webp new file mode 100644 index 0000000000000000000000000000000000000000..f3038b050768bff58bc2d05f1bb55a5d3370f435 GIT binary patch literal 370 zcmV-&0ge7rNk&F$0RRA3MM6+kP&go70RRB-3jmz~DqsL$06vvMnn`>=OHdK+C*quP35ilS?Fxj0hk~n(Hkwo#?_<}yGDZOB!KChTVTTvQ5o z_Bh~?oaCdUvqgQQ!xB1F0BPHpf)H+xQV*a2{`R+7%T72`IHYJ*zL$aLPo)ciBYOfv z&g}RM3Hg%YiS}by##bS@R8{$dty!lWEh8H|xr9HbeO`kch*z7I=&xA&eD5bs8384m z@7t?bCH8lR!A^BJNV}gZDAQQMYKi9uY6O7L#6r4Z&u*hQVtY<{^bH*+PmQdOA#Ycl z_HZ^bvZORp4E0jr(QpNVK6!s)j!YxZT*ZO$mw}wil#BZ)<+iq1u8V{}lgEGLsMr4P zcJ=dnl9n$1q$$5=9i!QO3X=Pg1 QCv%^2rIa7X7a#xt0Qp9#`Tzg` literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/namesilo.webp b/apps/miniprogram/xhs/release/icons/namesilo.webp new file mode 100644 index 0000000000000000000000000000000000000000..f29a994e2fa0f5601d58f4bc28a83c5f8ef812c1 GIT binary patch literal 942 zcmV;f15x}^Nk&Gd0{{S5MM6+kP&go(0{{RJ6abw8DqsL$06vvImq;a}q9HK#?69yB ziDLlG^s~Q2@Onhsqt6`rPwCI-2XEizItRQ0fSf?Pr^w#%S0Vn7#D0>=lKCO}JN4ux zv%j8ko930nusbB}c5N>u%FYrmq;Kb4UXY-A#3Tk+pq-GZ`b|3PgEm3vtH`a*@3t(w0p~4~zvFHAyN5w@pBXj41p-|)~Io7D7>6`5@k}WHzZlMoA^-)H> z`L5@@-4$w-10P=_PgO<+x>xUzT@H&KjVMFwk1aXhLxGZz6!Ww^ku=1)GvxzG0Y*TX zl6FL0P5fPh4ZR{@J-y|#j-I`e+{Bg;bgNsw*uV{Vho7oG#p`Yb_a&gc3+vAzno>9V zf@sSN$<%jl9IYVIR*lE*PCKa8tl%knuqS1_dwC#^p@dSgtg`aBvHMyLHCfTG)7Cv{ zZ)DC9w+S}H#~FDt{cUIXB%4L6>MH-F`W{Ey+A5TUzyjm1;tM@ZLl=p~T+$$;Vm}W~ zyuby2@Ejlh{z1fD0u0r}57q$VfnQ-}mbAr3TO^!Zox89(>17N#zpAk&l`U9e|=d z`YvEo_NU2U>Oau$>iJyT=`YpsgmgoDHhJ(r|I7UpexSX>6Wy4$G?T@mL2>KhvU+b_ z+O3GZffr1@oQS{p6vq~S0-rPt=xB?i`_khH^QgEH!7}*S7;Xm_T0%c;Z)@1VqflO~48gF(eR^ljAC3z>uD QH4-ire}1@3t6%^C08Yo+;Q#;t literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/nomad-book.webp b/apps/miniprogram/xhs/release/icons/nomad-book.webp new file mode 100644 index 0000000000000000000000000000000000000000..b4959884d8bbcdfc81e67f56837e220120927032 GIT binary patch literal 832 zcmV-G1Hb%INk&FE0{{S5MM6+kP&il$0000G0001A003VA06|PpNE!hE00DqpZQC*D z`L=^1SW0ZGkZi{@1q2<~W(#&|7~A=RpXYyeQAA7t^g6oZ`!DIbv}8T~ycg?oz)aD# zR+W~otab{+#_lA^n_**o7n10i*MO0%q?(`BBm9zXTxb%DlJJ7i5|fle8YU#^85LiF zRnDVyA!(l}j7s7|0K^@$8v%4l>K(v3w`Dl1+{(6YNxnVKF1pWd=at=aid~|{t}6fi z|NXbdu9{+(cwzUn&u%BiF4D!W%~9c2vSF3m641%59T1nyt_6T$X8rhj#OoA_-aM^(;;J7;i;m^8^~y`_0%qFU zqdQNjnl);vr=3Wf4SE4qP&gp?0RRB74gj42DqsL$06uLplSU*XA)zoB2mpW$i9i}v zKqw{lXUZCLwgi0DdH{LgbSM9g>m~F6^1${k{l@){_JC-Cq`jH)o9G(eK^*^6PTdH($_~v}5$1b!wS;1x7Kd z;j9JNU=!tZ<`KGleaD6S2hW9`80YQTKEFnrA`DO_$_>Vt@iYI5zsdpsS7r`ADIFXL z?39mk*PiAWPd4pz*>?7_FM-($TM%h%Wf10#39`60ZjJP4dCZ#qmoeVn96X&~u^Xnb zllK^B5_%g-B`l*pD)dK#L5jmW z^mgI`7fz?|gCSQ-$a`dd2xgJ)01s58N{*3pyK?xDuP>w*F;{Pqj(lf*nXp~mxo@ZO zU%7HmI*|qR9N+V)m~Y25=THk0Mexa@w=chrif!@iazB{s!>leY49pg_X|!&V9iW*# z{0vtP&T3!yFZCdKvh;-K=JHnwil82;>O8IuX2-8hFG4HuD^SDMkExWlZ%%yid2sll K0uccvfB*pWEs^H{ literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/nomadcna.webp b/apps/miniprogram/xhs/release/icons/nomadcna.webp new file mode 100644 index 0000000000000000000000000000000000000000..285782ef69e2785798fd6a1451fe5b79d20fe2dd GIT binary patch literal 1520 zcmV{8;2*#{K>s=6UxXhodv~Bu&-d5)CEjnr%|O2t{zd)+^80`&0DeFHAO1gp4y8Tm z^1b5*@y}on%D?n|mVcf7n)93VPq07pFYBFby&HdMPv7WNYitxpPcc^L29F~5@m1TC zb7J(#yE%^M^|jxK8=wto#@z^&N{xt z8|40}U2OT841t1>pmhegvU$f>`8qd)Rjy1dH&@!P}QSP{XW&G-R(po!of zj485?ZN`u z|Ch)`tV7rzAE%a@pXZ9FPto( zftD)n6|?qx_6Rq-J`?03W#NKg1s_d!#9iYy@mwvTz*GEOcwq%7QF^8 z&D9vP{J?2T)S653j3cywbuQ(7N<>cQTQUVa@MM;p|5uAmv^*#+*c^(qedRVAkU;&u z8mMxSM~ImkV@JMK%prdU`G_i7f*Z52#S=V9c|{Vx8h=lxuWOLGh1)*t^!h%tHLDrpq9oR#(bf2O;*FaJsZHWB7qdj8jB-Y$zGIo1FPz*BP zBjq|`F7bNL{54NcWBX0@21KpS^~MkNZ8*Iz2q=7#Yule!0lX;k7?OP_7W{G zkMh&0{xITzMwT85n0<=7b+C+DT7%1n7f3W4Su0_aRiJ!{gSnOwRryG=aR6(*18vcs zuI9$&5dKnDSy!1qpQ&*WiefD@b#xt#B_f2fI$;JI9X5YEp?uUkBRFB7tx$gn2XHbW WudTveFTLOb4oAD@gA&+a0002rPx3hc literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/nomadlist.webp b/apps/miniprogram/xhs/release/icons/nomadlist.webp new file mode 100644 index 0000000000000000000000000000000000000000..640d92f459940397df3274c2214d9b922e56cbc4 GIT binary patch literal 600 zcmV-e0;l~_Nk&Fc0ssJ4MM6+kP&gn&0ssK84gj42DqsL$06vvMpGu{pqamml8W6A& ziDUrEroes>bF*)kfGUpoigbYU0p}0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Pq_FLJTh(`CmlUXAO+@F{Xkim%Rs#WnhT9u%NJZshp{- af+Zu15`FqpjZ~c3Z9U*PW7H6_0000l=2Ef% literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/okx.webp b/apps/miniprogram/xhs/release/icons/okx.webp new file mode 100644 index 0000000000000000000000000000000000000000..85aa2e3d0cb8bcd3d344248c06534fe7694b1b8e GIT binary patch literal 926 zcmV;P17ZA9Nk&GN0{{S5MM6+kP&gop0{{S!7yz9CDqsL$06vvQno6akq9La$NU#!# zX#f_={$KwA+n@Gd$lDjc&;C>Btp5wW$%}u!ajDxG_5sjY7v6iHKY9=Pi`XyuKlQKo z{Qg7Shs+h_7r$6M)D2$s;ti)z3ssT*`+UcA89vWBmy^b=p zwu-4nLgq8`?IGp>{`upAncYtsX>ihQIAHycOd~^l&|lz@Y;w_=g(@(dg*I8^Z*gDZ zsMZ-g<|1?GCB%gO;dd*pxaz}X%i`x{n=QnzjPtzLRWKh6jtR_NrV^i;gVs;=k zBr>-GL^k;V$T@J7G*HaHCPjT`#j^$pbTsRG07FQHxjW}(#eOU(P#4M-<|GzwQ#6hu zN2U4~_SvL5^Wwe6P!L_;6|zn5gD%y1rfVIKbX1|xw&-+8jC@dSxk*GI143DyBmU!2 z?>SXb@x>PPb-B(t1u&!(ZWvkb-G7gnFf_h~K=)6K5(e!e-qORBVmXvdo+dzor9m29 zM@tFFY6u%+nYU}w#NH$c06gq+5B^6P)y_^>bkZ9%lcnPlk<9y`wBtO`E`R_400HFD A3IG5A literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/paypal.webp b/apps/miniprogram/xhs/release/icons/paypal.webp new file mode 100644 index 0000000000000000000000000000000000000000..3cc416e6def56828fbad268bcecfed2bada0a8d7 GIT binary patch literal 616 zcmV-u0+;<#Nk&Fs0ssJ4MM6+kP&gn|0ssJT4gj42DqsL$06vvMoJl34qaiLe37D`F zi9xmivooX8YB(WD@I1hI!)do2n)h8X5{zEj%qMe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`UV`lO5ERO8Htzg2|f75 z?AJTGeR#a-BhMWGzD8AB<-|rTHM)0|v1{BB$$Zzi2}yjRQY8n21GbCYc6emIF-;hm zkwzw&a%$T==JB3MoDR9fIFjeYTW6u<#?AsYsOY)@c?5GOOOMIJ;^amECMPSV!^UIx z7SIXmmF=$9?}gRhN$n6lP3fL)JBCq!#fc-s;Lor=vDTvuhREo8Mzs!qY>z4pr;0T_7d!+w*Vc)>!^PuERr;i|cI}~j>hmpV`SJUU?8%M|ZDnps@S&0{qMu^34Kgbw6%wzf7F$%53Cy-m)U3x`KxH>~hD+nf4 zDi#x8xD#>^9?v{x|C{Kd%;F|Y$my7OFC-@Ez*-gL@+Fa>{OIxJaXPecPxs=h>pM!+e{Ij@sLch!b56FmLJrDs5j+z|prW(uht>E4geu5KczErJ42EJh>GNh{bX#fnhXjOK! oS9c+U#^gkNX*mUFazklEOZPC^`SqXdQPE=)PiATJ;yG9V08UfmdjJ3c literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/release/icons/racknerd.webp b/apps/miniprogram/xhs/release/icons/racknerd.webp new file mode 100644 index 0000000000000000000000000000000000000000..2262856f58adf2dc12bbee62ea22624b2a900dd4 GIT binary patch literal 776 zcmV+j1NZz=Nk&Eh0{{S5MM6+kP&gp;0ssJT5dfV5DqsL$06vvOoJ*ynqM@c)DHyO4 ziDdxQ*-Rl9S0q6nJ!~VWzFV}JW{|CYhur4+H&qT|J7{{6c`iIyf z^^kT|Tv3zY8Tz5HAeD|JnK&c3OHYW7#|;wsVN>-}4TrHhgX9^iV}6+IyC&iGe9s@@ zyelSsK>dYkoQ{VSNgK~bitqpc{`r$p)sequ_`afjiIz5)H`JFUan4>kVZxrRV@U`G z^Tmo$>$4j4rk(nZGi(pvHyt9Gokbbf8ZjFB4~RDHP2N?U9sr)h{&+Mtet_y8#r3h7 zz}fvU-@%bA^g{*j#zUruA=6SGDXulH81$s@aj_`*E+}6@U4s^y8*5H`^MA7bQ-Xv@C z?bWo}A9X~@C9gxi1$!=~rVzX{?z;m1)gOBt{^Ce=cj`N@5=*B`hB&^^QGP7RCH|f1 zxx=vD@j3zF_c7U~cQEhaZFbyX9Y3cJvZQ>D0qrBgw00g49z!@2?t&L%HHVuhZ#ztvbG906m>?N`c=j59ai`acoEyli zaGonGGVse$lHjRhe$KHd)&B?yaI{_K-KqM+3zLCfcY^liJH@$=qo^v&w|499^5l!e zoZAg93K8;pQgYCA@3{VQpKJaalDl{kyx1=5D+v`Dlq@!6X?Ia3>ewJxMTq@_QxOU? zJ-__P`sy@|e3}l + + + + + + 游民导航 + + + +

+ + +
+ +
+ +
+

游民导航

+

数字游民

+
+
+ +
+ + + +
+
+
+
+ + + + + +
+
+ + + + diff --git a/apps/miniprogram/xhs/release/styles.css b/apps/miniprogram/xhs/release/styles.css new file mode 100644 index 0000000..ced7909 --- /dev/null +++ b/apps/miniprogram/xhs/release/styles.css @@ -0,0 +1,944 @@ +:root, +[data-theme="light"] { + --bg: #e9eef4; + --bg-elevated: #f7fafc; + --ink: #15202b; + --ink-muted: #5b6b7c; + --ink-faint: #8a98a8; + --line: rgba(21, 32, 43, 0.08); + --surface: rgba(255, 255, 255, 0.88); + --surface-solid: #ffffff; + --accent: #0d8f7b; + --accent-deep: #0a6e5f; + --accent-soft: rgba(13, 143, 123, 0.12); + --glow-a: rgba(13, 143, 123, 0.2); + --glow-b: rgba(56, 120, 180, 0.14); + --shadow: 0 8px 24px rgba(21, 32, 43, 0.08); + --shadow-card: 0 1px 2px rgba(21, 32, 43, 0.04), 0 6px 16px rgba(21, 32, 43, 0.04); + --toast-bg: #15202b; + --toast-ink: #f4f7fa; + --chip: rgba(21, 32, 43, 0.045); + --chip-active: #15202b; + --chip-active-ink: #f7fafc; + --topbar-bg: rgba(233, 238, 244, 0.9); + --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", + "Microsoft YaHei", "Noto Sans SC", sans-serif; + --radius: 14px; + --app-pad-top: 80px; + --safe-bottom: env(safe-area-inset-bottom, 0px); +} + +[data-theme="dark"] { + --bg: #0a0f14; + --bg-elevated: #121820; + --ink: #e8eef4; + --ink-muted: #8b99a8; + --ink-faint: #5d6c7c; + --line: rgba(232, 238, 244, 0.1); + --surface: rgba(18, 24, 32, 0.92); + --surface-solid: #121820; + --accent: #3dceb8; + --accent-deep: #2aa892; + --accent-soft: rgba(61, 206, 184, 0.14); + --glow-a: rgba(61, 206, 184, 0.14); + --glow-b: rgba(70, 130, 200, 0.12); + --shadow: 0 10px 28px rgba(0, 0, 0, 0.35); + --shadow-card: 0 1px 0 rgba(255, 255, 255, 0.03), 0 8px 20px rgba(0, 0, 0, 0.28); + --toast-bg: #e8eef4; + --toast-ink: #0a0f14; + --chip: rgba(232, 238, 244, 0.06); + --chip-active: #e8eef4; + --chip-active-ink: #0a0f14; + --topbar-bg: rgba(10, 15, 20, 0.9); +} + +*, +*::before, +*::after { + box-sizing: border-box; +} + +html, +body { + margin: 0; + min-height: 100%; + background: var(--bg); + color: var(--ink); + font-family: var(--font); + -webkit-font-smoothing: antialiased; + -webkit-tap-highlight-color: transparent; +} + +button { + font: inherit; + color: inherit; + border: none; + background: none; + padding: 0; + cursor: pointer; +} + +img { + display: block; +} + +.app-shell { + position: relative; + min-height: 100vh; + isolation: isolate; +} + +.bg-glow { + position: fixed; + inset: 0; + pointer-events: none; + z-index: 0; + overflow: hidden; + background: + radial-gradient(680px 380px at 8% -12%, var(--glow-a), transparent 58%), + radial-gradient(560px 320px at 100% 4%, var(--glow-b), transparent 55%), + var(--bg); +} + +.orb { + position: absolute; + border-radius: 50%; + opacity: 0.5; +} + +.orb-a { + width: 200px; + height: 200px; + left: -60px; + top: 18%; + background: radial-gradient(circle, var(--glow-a), transparent 70%); +} + +.orb-b { + width: 240px; + height: 240px; + right: -80px; + top: 42%; + background: radial-gradient(circle, var(--glow-b), transparent 70%); +} + +.topbar { + position: sticky; + top: 0; + z-index: 30; + display: flex; + align-items: center; + gap: 10px; + padding: calc(var(--app-pad-top) + 8px) 12px 10px; + background: var(--topbar-bg); + backdrop-filter: blur(14px); + -webkit-backdrop-filter: blur(14px); + border-bottom: 1px solid var(--line); +} + +.icon-btn { + width: 36px; + height: 36px; + border-radius: 11px; + background: var(--surface); + border: 1px solid var(--line); + box-shadow: var(--shadow-card); + display: grid; + place-items: center; + flex-shrink: 0; + font-size: 1rem; +} + +.icon-btn:active { + transform: scale(0.94); +} + +.menu-bars { + display: flex; + flex-direction: column; + gap: 3.5px; + width: 14px; +} + +.menu-bars i { + display: block; + height: 1.5px; + border-radius: 1px; + background: var(--ink); +} + +.brand-mark { + display: flex; + align-items: center; + gap: 8px; + min-width: 0; + flex: 1; +} + +.brand-logo { + width: 28px; + height: 28px; + border-radius: 8px; + object-fit: cover; + border: 1px solid var(--line); +} + +.brand-text { + min-width: 0; + display: flex; + flex-direction: column; + align-items: flex-start; + justify-content: center; + gap: 2px; +} + +.brand-name { + margin: 0; + font-size: 1rem; + font-weight: 700; + letter-spacing: -0.02em; + line-height: 1.2; +} + +.brand-current { + margin: 0; + max-width: 100%; + font-size: 0.72rem; + font-weight: 600; + letter-spacing: -0.01em; + line-height: 1.25; + color: var(--accent-deep); + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} + +[data-theme="dark"] .brand-current { + color: var(--accent); +} + +.page { + position: relative; + z-index: 1; + padding: 12px 12px calc(72px + var(--safe-bottom)); +} + +.cat-panel + .cat-panel { + margin-top: 22px; +} + +.cat-panel { + scroll-margin-top: calc(var(--app-pad-top) + 52px); +} + +.cat-heading { + display: flex; + align-items: center; + gap: 8px; + margin: 0 0 10px; + padding-left: 10px; + position: relative; +} + +.cat-heading::before { + content: ""; + position: absolute; + left: 0; + top: 0.25em; + bottom: 0.25em; + width: 3px; + border-radius: 99px; + background: var(--accent); +} + +.cat-heading h2 { + margin: 0; + font-size: 1.05rem; + font-weight: 700; +} + +.cat-count { + font-size: 0.66rem; + font-weight: 700; + color: var(--accent-deep); + background: var(--accent-soft); + padding: 2px 7px; + border-radius: 999px; +} + +[data-theme="dark"] .cat-count { + color: var(--accent); +} + +.group-block + .group-block { + margin-top: 12px; +} + +.group-title { + margin: 0 0 7px; + font-size: 0.7rem; + font-weight: 700; + letter-spacing: 0.04em; + text-transform: uppercase; + color: var(--ink-faint); +} + +.link-grid { + display: grid; + grid-template-columns: repeat(2, minmax(0, 1fr)); + gap: 7px; +} + +.link-card { + display: flex; + align-items: center; + gap: 8px; + width: 100%; + min-width: 0; + text-align: left; + padding: 9px; + border-radius: var(--radius); + background: var(--surface); + border: 1px solid var(--line); + box-shadow: var(--shadow-card); +} + +.link-card:active { + transform: scale(0.978); +} + +.link-icon-wrap { + width: 34px; + height: 34px; + border-radius: 10px; + overflow: hidden; + border: 1px solid var(--line); + background: var(--chip); + flex-shrink: 0; +} + +.link-icon { + width: 100%; + height: 100%; + object-fit: cover; +} + +.link-meta { + min-width: 0; + flex: 1; +} + +.link-title { + display: block; + font-size: 0.82rem; + font-weight: 700; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} + +.link-desc { + display: block; + margin-top: 2px; + font-size: 0.65rem; + color: var(--ink-muted); + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} + +.footer { + margin-top: 28px; + padding-top: 14px; + border-top: 1px solid var(--line); + text-align: center; + font-size: 0.7rem; + color: var(--ink-faint); +} + +.drawer-root { + position: fixed; + inset: 0; + z-index: 60; + pointer-events: none; +} + +.drawer-root.open { + pointer-events: auto; +} + +.drawer-mask { + position: absolute; + inset: 0; + background: rgba(8, 12, 18, 0.46); + opacity: 0; + transition: opacity 0.22s ease; +} + +.drawer-root.open .drawer-mask { + opacity: 1; +} + +.drawer-panel { + position: absolute; + top: 0; + left: 0; + bottom: 0; + width: min(80vw, 300px); + background: var(--bg-elevated); + border-right: 1px solid var(--line); + box-shadow: var(--shadow); + transform: translateX(-104%); + transition: transform 0.26s cubic-bezier(0.22, 1, 0.36, 1); + display: flex; + flex-direction: column; + padding: calc(var(--app-pad-top) + 4px) 0 calc(16px + var(--safe-bottom)); +} + +.drawer-root.open .drawer-panel { + transform: translateX(0); +} + +.drawer-head { + display: flex; + align-items: center; + justify-content: space-between; + gap: 10px; + padding: 4px 12px 12px; + border-bottom: 1px solid var(--line); +} + +.drawer-brand-wrap { + display: flex; + align-items: center; + gap: 8px; + min-width: 0; +} + +.drawer-brand-wrap img { + width: 28px; + height: 28px; + border-radius: 8px; + object-fit: cover; + border: 1px solid var(--line); +} + +.drawer-brand { + display: block; + font-weight: 700; + font-size: 1rem; +} + +.drawer-sub { + display: block; + margin-top: 2px; + font-size: 0.68rem; + color: var(--ink-muted); +} + +.drawer-nav { + padding: 12px 10px; + overflow-y: auto; + -webkit-overflow-scrolling: touch; +} + +.drawer-item { + display: flex; + align-items: center; + gap: 10px; + width: 100%; + text-align: left; + padding: 12px; + border-radius: 12px; + color: var(--ink-muted); + margin-bottom: 4px; +} + +.drawer-item.active { + background: var(--accent-soft); + color: var(--accent); +} + +.drawer-item-title { + flex: 1; + font-size: 0.92rem; + font-weight: 600; + color: inherit; +} + +.drawer-item.active .drawer-item-title { + color: var(--ink); +} + +.drawer-item-count { + font-size: 0.68rem; + font-weight: 650; + background: var(--chip); + color: var(--ink-faint); + padding: 2px 7px; + border-radius: 999px; +} + +.back-top { + position: fixed; + right: 14px; + bottom: calc(18px + var(--safe-bottom)); + width: 40px; + height: 40px; + border-radius: 14px; + background: var(--chip-active); + color: var(--chip-active-ink); + box-shadow: var(--shadow); + opacity: 0; + pointer-events: none; + transform: translateY(8px); + transition: opacity 0.2s ease, transform 0.2s ease; + z-index: 40; + font-size: 1rem; +} + +.back-top.show { + opacity: 1; + pointer-events: auto; + transform: translateY(0); +} + +/* Link detail sheet */ +.sheet-root { + position: fixed; + inset: 0; + z-index: 70; + pointer-events: none; +} + +.sheet-root.open { + pointer-events: auto; +} + +.sheet-mask { + position: absolute; + inset: 0; + background: rgba(8, 12, 18, 0.48); + opacity: 0; + transition: opacity 0.22s ease; +} + +.sheet-root.open .sheet-mask { + opacity: 1; +} + +.sheet-panel { + position: absolute; + left: 0; + right: 0; + bottom: 0; + max-height: min(86vh, 640px); + overflow-y: auto; + -webkit-overflow-scrolling: touch; + background: var(--bg-elevated); + border-radius: 20px 20px 0 0; + border: 1px solid var(--line); + border-bottom: none; + box-shadow: var(--shadow); + padding: 10px 16px calc(16px + var(--safe-bottom)); + transform: translateY(108%); + transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1); + display: flex; + flex-direction: column; + gap: 12px; +} + +.sheet-root.open .sheet-panel { + transform: translateY(0); +} + +.sheet-handle { + width: 36px; + height: 4px; + border-radius: 99px; + background: var(--chip); + margin: 0 auto 4px; +} + +.sheet-head { + display: flex; + align-items: center; + gap: 12px; +} + +.sheet-icon { + width: 44px; + height: 44px; + border-radius: 12px; + object-fit: cover; + border: 1px solid var(--line); + background: var(--chip); + flex-shrink: 0; +} + +.sheet-head-text { + min-width: 0; + flex: 1; +} + +.sheet-title { + margin: 0; + font-size: 1.05rem; + font-weight: 700; + letter-spacing: -0.02em; +} + +.sheet-sub { + margin: 4px 0 0; + font-size: 0.78rem; + color: var(--ink-muted); + line-height: 1.35; +} + +/* Visual guide steps */ +.guide-steps { + list-style: none; + margin: 0; + padding: 10px; + border-radius: 14px; + background: var(--chip); + border: 1px solid var(--line); + display: flex; + flex-direction: column; + gap: 8px; +} + +.guide-step { + display: flex; + align-items: flex-start; + gap: 10px; + opacity: 0.42; + transition: opacity 0.25s ease, transform 0.25s ease; + transform: translateX(0); +} + +.guide-step.is-active { + opacity: 1; + transform: translateX(2px); +} + +.guide-step.is-done { + opacity: 0.78; +} + +.guide-step.is-done .guide-num { + background: var(--accent); + color: #fff; +} + +.guide-num { + width: 24px; + height: 24px; + border-radius: 50%; + flex-shrink: 0; + display: grid; + place-items: center; + font-size: 0.75rem; + font-weight: 800; + background: var(--surface-solid); + border: 1px solid var(--line); + color: var(--ink-muted); +} + +.guide-step.is-active .guide-num { + background: var(--chip-active); + color: var(--chip-active-ink); + border-color: transparent; + box-shadow: 0 0 0 4px var(--accent-soft); + animation: num-pop 0.35s ease; +} + +.guide-text { + display: flex; + flex-direction: column; + gap: 2px; + min-width: 0; + padding-top: 1px; +} + +.guide-text strong { + font-size: 0.84rem; + font-weight: 750; + color: var(--ink); +} + +.guide-text em { + font-style: normal; + font-size: 0.72rem; + color: var(--ink-muted); +} + +.sheet-label { + margin: 0 0 8px; + font-size: 0.7rem; + font-weight: 700; + letter-spacing: 0.04em; + text-transform: uppercase; + color: var(--ink-faint); +} + +.url-stage { + position: relative; +} + +.sheet-url-wrap { + position: relative; +} + +.sheet-url-box { + padding: 14px 12px; + border-radius: 14px; + background: color-mix(in srgb, var(--accent) 8%, var(--surface-solid)); + border: 2px solid color-mix(in srgb, var(--accent) 45%, var(--line)); + font-size: 0.86rem; + line-height: 1.5; + word-break: break-all; + user-select: text; + -webkit-user-select: text; + color: var(--ink); + transition: box-shadow 0.25s ease, border-color 0.25s ease, background 0.25s ease; + position: relative; + z-index: 1; +} + +.sheet-url-box.is-pulse { + animation: url-pulse 1.4s ease-in-out infinite; +} + +.sheet-url-box.is-selected { + border-color: var(--accent); + background: color-mix(in srgb, var(--accent) 16%, var(--surface-solid)); + box-shadow: 0 0 0 4px var(--accent-soft); + animation: none; +} + +.finger-ico { + font-size: 1.75rem; + line-height: 1; + filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.2)); +} + +.finger-btn.is-hidden, +.finger-url.is-hidden { + display: none !important; +} + +/* 第一步:仅小手,悬浮在绿色按钮上方,朝下指 */ +.sheet-actions-wrap { + position: relative; + padding-top: 36px; +} + +.finger-btn { + position: absolute; + left: 22%; + top: 0; + z-index: 3; + pointer-events: none; + display: flex; + align-items: center; + justify-content: center; + animation: finger-bounce-down 1.1s ease-in-out infinite; +} + +.finger-btn .finger-ico { + display: block; +} + +/* 第二步:小手紧贴网址区下沿朝上指,文案在右边 */ +.sheet-url-wrap.is-pointing { + padding-bottom: 34px; +} + +.finger-url { + position: absolute; + left: 6px; + top: auto; + bottom: 0; + z-index: 3; + pointer-events: none; + display: flex; + flex-direction: row; + align-items: center; + gap: 8px; + max-width: calc(100% - 12px); + animation: finger-nudge-up 1.05s ease-in-out infinite; +} + +.finger-url .finger-ico { + flex-shrink: 0; +} + +.finger-url .finger-bubble { + max-width: 150px; + padding: 6px 9px; + border-radius: 10px; + background: var(--chip-active); + color: var(--chip-active-ink); + font-size: 0.68rem; + font-weight: 700; + line-height: 1.3; + text-align: left; + box-shadow: var(--shadow); + position: relative; +} + +.finger-url .finger-bubble::before { + content: ""; + position: absolute; + left: -4px; + top: 50%; + width: 8px; + height: 8px; + background: var(--chip-active); + transform: translateY(-50%) rotate(45deg); +} + +.sheet-status { + margin: 10px 0 0; + min-height: 1.2em; + font-size: 0.78rem; + font-weight: 650; + color: var(--accent-deep); + line-height: 1.4; +} + +[data-theme="dark"] .sheet-status { + color: var(--accent); +} + +.sheet-status.is-error { + color: #c44; +} + +.sheet-actions { + display: grid; + grid-template-columns: 1.7fr 0.9fr; + gap: 8px; +} + +.sheet-btn { + min-height: 48px; + border-radius: 14px; + border: 1px solid var(--line); + background: var(--surface); + font-size: 0.9rem; + font-weight: 650; + padding: 8px 10px; +} + +.sheet-btn.primary { + background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 88%, #fff), var(--accent-deep)); + color: #fff; + border-color: transparent; + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + gap: 2px; +} + +.sheet-btn.primary.pulse { + animation: cta-pulse 1.5s ease-in-out infinite; +} + +.sheet-btn.primary.is-done { + animation: none; + background: var(--chip); + color: var(--ink); + border: 1px solid var(--line); +} + +.sheet-btn-main { + font-size: 0.92rem; + font-weight: 800; +} + +.sheet-btn-sub { + font-size: 0.66rem; + font-weight: 600; + opacity: 0.88; +} + +.sheet-btn:active { + transform: scale(0.98); +} + +@keyframes url-pulse { + 0%, + 100% { + box-shadow: 0 0 0 0 var(--accent-soft); + } + 50% { + box-shadow: 0 0 0 6px var(--accent-soft); + } +} + +@keyframes cta-pulse { + 0%, + 100% { + transform: scale(1); + box-shadow: 0 0 0 0 rgba(13, 143, 123, 0.35); + } + 50% { + transform: scale(1.015); + box-shadow: 0 0 0 8px rgba(13, 143, 123, 0); + } +} + +@keyframes finger-bounce-down { + 0%, + 100% { + transform: translateY(0); + } + 50% { + transform: translateY(6px); + } +} + +@keyframes finger-nudge-up { + 0%, + 100% { + transform: translateY(0); + } + 50% { + transform: translateY(-6px); + } +} + +@keyframes num-pop { + from { + transform: scale(0.7); + } + to { + transform: scale(1); + } +} + +.toast { + position: fixed; + left: 50%; + bottom: calc(28px + var(--safe-bottom)); + transform: translateX(-50%) translateY(10px); + padding: 9px 16px; + border-radius: 999px; + background: var(--toast-bg); + color: var(--toast-ink); + font-size: 0.8rem; + font-weight: 600; + opacity: 0; + pointer-events: none; + transition: opacity 0.2s ease, transform 0.2s ease; + z-index: 80; + box-shadow: var(--shadow); +} + +.toast.show { + opacity: 1; + transform: translateX(-50%) translateY(0); +} diff --git a/apps/miniprogram/xhs/scripts/assemble.py b/apps/miniprogram/xhs/scripts/assemble.py new file mode 100644 index 0000000..71de272 --- /dev/null +++ b/apps/miniprogram/xhs/scripts/assemble.py @@ -0,0 +1,71 @@ +#!/usr/bin/env python3 +"""Assemble xhs/release/ (flat + relative paths, classic script only).""" +from __future__ import annotations + +import shutil +import sys +from pathlib import Path +from subprocess import check_call + +ROOT = Path(__file__).resolve().parents[1] +SRC = ROOT / "tool" +OUT = ROOT / "release" + + +def main() -> int: + check_call([sys.executable, str(ROOT / "scripts" / "sync_data.py")]) + + OUT.mkdir(parents=True, exist_ok=True) + + data_js = (SRC / "nav-data.js").read_text(encoding="utf-8") + app_js = (SRC / "app.js").read_text(encoding="utf-8") + bundle = ( + "/* bundled classic script for xhs minitool */\n" + + data_js + + "\n" + + app_js + + "\n" + ) + + shutil.copy2(SRC / "index.html", OUT / "index.html") + shutil.copy2(SRC / "styles.css", OUT / "styles.css") + (OUT / "app.js").write_text(bundle, encoding="utf-8") + + icons_src = SRC / "icons" + icons_dst = OUT / "icons" + if icons_dst.exists(): + shutil.rmtree(icons_dst, ignore_errors=True) + if icons_src.is_dir(): + shutil.copytree(icons_src, icons_dst) + + # 电子书离线包(对齐 ebook/redmini) + book_out = OUT / "book" + if book_out.exists(): + shutil.rmtree(book_out, ignore_errors=True) + book_out.mkdir(parents=True, exist_ok=True) + for name, dest in [ + ("book.html", "index.html"), + ("book-styles.css", "styles.css"), + ("book-app.js", "app.js"), + ]: + src_f = SRC / name + if src_f.is_file(): + shutil.copy2(src_f, book_out / dest) + book_data_dir = SRC / "book" + if book_data_dir.is_dir(): + for f in book_data_dir.iterdir(): + if f.is_file(): + shutil.copy2(f, book_out / f.name) + + print(f"assembled {OUT}") + total = 0 + for p in sorted(OUT.rglob("*")): + if p.is_file(): + total += p.stat().st_size + print(f" {p.relative_to(OUT).as_posix()}\t{p.stat().st_size}") + print(f"total {total / 1024:.1f} KB") + return 0 + + +if __name__ == "__main__": + raise SystemExit(main()) diff --git a/apps/miniprogram/xhs/scripts/pack.py b/apps/miniprogram/xhs/scripts/pack.py new file mode 100644 index 0000000..4a919fb --- /dev/null +++ b/apps/miniprogram/xhs/scripts/pack.py @@ -0,0 +1,34 @@ +#!/usr/bin/env python3 +"""Pack release/ contents into uploadable zip (index.html at zip root).""" +from __future__ import annotations + +import sys +import zipfile +from pathlib import Path + +ROOT = Path(__file__).resolve().parents[1] +TOOL = ROOT / "release" +OUT = ROOT / "dist" / "youmin-nav-xhs-tool.zip" + + +def main() -> int: + out = Path(sys.argv[1]) if len(sys.argv) > 1 else OUT + out.parent.mkdir(parents=True, exist_ok=True) + if out.exists(): + out.unlink() + + files = sorted(p for p in TOOL.rglob("*") if p.is_file()) + if not files: + print("release/ is empty — run: python scripts/assemble.py", file=sys.stderr) + return 1 + + with zipfile.ZipFile(out, "w", compression=zipfile.ZIP_DEFLATED) as zf: + for p in files: + zf.write(p, p.relative_to(TOOL).as_posix()) + + print(f"packed {out} ({out.stat().st_size / 1024:.1f} KB) entries={len(files)}") + return 0 + + +if __name__ == "__main__": + raise SystemExit(main()) diff --git a/apps/miniprogram/xhs/scripts/sync_data.py b/apps/miniprogram/xhs/scripts/sync_data.py new file mode 100644 index 0000000..f494909 --- /dev/null +++ b/apps/miniprogram/xhs/scripts/sync_data.py @@ -0,0 +1,57 @@ +#!/usr/bin/env python3 +"""Sync links.json + icons into xhs/tool for offline packaging. +Aligned with apps/navmini/xhs/scripts/sync_data.py — paths adapted for apps/miniprogram. +""" +from __future__ import annotations + +import json +import shutil +import sys +from pathlib import Path + +ROOT = Path(__file__).resolve().parents[1] # xhs/ +MINI = ROOT.parent # apps/miniprogram +NAVMINI = MINI.parent / "navmini" + +SRC_JSON = MINI / "src" / "data" / "links.json" +if not SRC_JSON.is_file(): + SRC_JSON = NAVMINI / "src" / "data" / "links.json" + +SRC_ICONS = MINI / "src" / "assets" / "icons" +if not SRC_ICONS.is_dir(): + SRC_ICONS = NAVMINI / "public" / "icons" + +TOOL = ROOT / "tool" +OUT_ICONS = TOOL / "icons" +OUT_DATA = TOOL / "nav-data.js" + + +def main() -> int: + if not SRC_JSON.is_file(): + print(f"missing {SRC_JSON}", file=sys.stderr) + return 1 + + data = json.loads(SRC_JSON.read_text(encoding="utf-8")) + OUT_ICONS.mkdir(parents=True, exist_ok=True) + + for old in OUT_ICONS.glob("*"): + if old.is_file(): + old.unlink() + + if SRC_ICONS.is_dir(): + for icon in SRC_ICONS.glob("*"): + if icon.is_file(): + shutil.copy2(icon, OUT_ICONS / icon.name) + + payload = json.dumps(data, ensure_ascii=False, indent=2) + OUT_DATA.write_text( + f"/* auto-generated — do not edit */\nwindow.__NAV_DATA__ = {payload};\n", + encoding="utf-8", + ) + print(f"wrote {OUT_DATA} categories={len(data.get('categories') or [])}") + print(f"icons from {SRC_ICONS} -> {OUT_ICONS}") + return 0 + + +if __name__ == "__main__": + raise SystemExit(main()) diff --git a/apps/miniprogram/xhs/tool/app.js b/apps/miniprogram/xhs/tool/app.js new file mode 100644 index 0000000..d8f981f --- /dev/null +++ b/apps/miniprogram/xhs/tool/app.js @@ -0,0 +1,470 @@ +/* 游民导航 · 小红书小工具(纯离线 classic script) */ +(function () { + "use strict"; + + var data = window.NAV_DATA || {}; + var categories = data.categories || []; + var state = { + theme: "light", + activeId: categories[0] ? categories[0].id : "", + drawerOpen: false, + sheetOpen: false, + currentLink: null, + jumping: false, + }; + + var els = {}; + + function $(id) { + return document.getElementById(id); + } + + function qs(sel, root) { + return (root || document).querySelector(sel); + } + + function escapeHtml(str) { + return String(str == null ? "" : str) + .replace(/&/g, "&") + .replace(//g, ">") + .replace(/"/g, """); + } + + function applySafeArea() { + try { + var root = document.documentElement; + var probe = document.createElement("div"); + probe.style.cssText = + "position:absolute;visibility:hidden;pointer-events:none;padding-top:constant(safe-area-inset-top);padding-top:env(safe-area-inset-top);"; + document.body.appendChild(probe); + var envTop = parseFloat(window.getComputedStyle(probe).paddingTop) || 0; + document.body.removeChild(probe); + + // 小红书宿主顶栏(返回 / 分享)常盖住内容;Android 上 env 常为 0 + var status = envTop > 0 ? envTop : 28; + var hostBar = 44; + var padTop = Math.max(status + hostBar, 72); + root.style.setProperty("--app-pad-top", padTop + "px"); + root.style.setProperty("--safe-area-inset-top", status + "px"); + } catch (e) { + document.documentElement.style.setProperty("--app-pad-top", "80px"); + } + } + + function readTheme() { + try { + var saved = localStorage.getItem("navmini-xhs-theme"); + if (saved === "light" || saved === "dark") return saved; + } catch (e) {} + return "light"; + } + + function setTheme(theme) { + state.theme = theme; + document.documentElement.setAttribute("data-theme", theme); + try { + localStorage.setItem("navmini-xhs-theme", theme); + } catch (e) {} + if (els.themeIcon) { + els.themeIcon.textContent = theme === "dark" ? "☀" : "☾"; + } + } + + function showToast(msg) { + if (!els.toast) return; + els.toast.textContent = msg; + els.toast.classList.add("show"); + clearTimeout(showToast._t); + showToast._t = setTimeout(function () { + els.toast.classList.remove("show"); + }, 1600); + } + + /** 选中网址文本(容器禁用程序化写入剪贴板,仅做文本选中) */ + function selectUrlText() { + try { + var node = els.sheetUrlBox; + if (!node) return false; + var range = document.createRange(); + range.selectNodeContents(node); + var sel = window.getSelection(); + if (!sel) return false; + sel.removeAllRanges(); + sel.addRange(range); + return true; + } catch (e) { + return false; + } + } + + function setGuideStep(step) { + var items = els.guideSteps + ? els.guideSteps.querySelectorAll(".guide-step") + : []; + for (var i = 0; i < items.length; i++) { + var n = i + 1; + items[i].classList.toggle("is-active", n === step); + items[i].classList.toggle("is-done", n < step); + } + } + + function setGuideUi(phase) { + // phase: idle | selected + var selected = phase === "selected"; + if (els.sheetUrlBox) { + els.sheetUrlBox.classList.toggle("is-pulse", !selected); + els.sheetUrlBox.classList.toggle("is-selected", selected); + } + if (els.sheetSelect) { + els.sheetSelect.classList.toggle("pulse", !selected); + els.sheetSelect.classList.toggle("is-done", selected); + } + if (els.sheetSelectLabel) { + els.sheetSelectLabel.textContent = selected + ? "② 已选中 · 再点可重选" + : "① 点我选中网址"; + } + if (els.sheetSelectSub) { + els.sheetSelectSub.textContent = selected + ? "下一步:手指按住蓝色网址区" + : "选中后请按住网址复制"; + } + // 第一步:只显示向下指按钮的小手;第二步:小手上移指网址,文案在右边 + if (els.fingerBtn) { + els.fingerBtn.classList.toggle("is-hidden", selected); + els.fingerBtn.setAttribute("aria-hidden", selected ? "true" : "false"); + } + if (els.fingerUrl) { + els.fingerUrl.classList.toggle("is-hidden", !selected); + els.fingerUrl.setAttribute("aria-hidden", selected ? "false" : "true"); + } + if (els.sheetUrlWrap) { + els.sheetUrlWrap.classList.toggle("is-pointing", selected); + } + setGuideStep(selected ? 2 : 1); + } + + function findCategory(id) { + for (var i = 0; i < categories.length; i++) { + if (categories[i].id === id) return categories[i]; + } + return categories[0] || null; + } + + function countLinks(cat) { + var n = 0; + var groups = cat.groups || []; + for (var i = 0; i < groups.length; i++) { + n += (groups[i].links || []).length; + } + return n; + } + + function renderDrawer() { + var html = ""; + for (var i = 0; i < categories.length; i++) { + var cat = categories[i]; + var active = cat.id === state.activeId ? " active" : ""; + html += + '"; + } + els.drawerNav.innerHTML = html; + } + + function renderContent() { + var html = ""; + for (var i = 0; i < categories.length; i++) { + var cat = categories[i]; + html += + '
' + + '

' + + escapeHtml(cat.title) + + '

' + + countLinks(cat) + + "
"; + + var groups = cat.groups || []; + for (var g = 0; g < groups.length; g++) { + var group = groups[g]; + html += + '

' + + escapeHtml(group.title) + + '

"; + } + html += "
"; + } + els.content.innerHTML = html; + } + + function setDrawer(open) { + state.drawerOpen = open; + els.drawer.classList.toggle("open", open); + els.drawer.setAttribute("aria-hidden", open ? "false" : "true"); + document.body.style.overflow = open || state.sheetOpen ? "hidden" : ""; + } + + function setSheet(open) { + state.sheetOpen = open; + els.sheet.classList.toggle("open", open); + els.sheet.setAttribute("aria-hidden", open ? "false" : "true"); + document.body.style.overflow = open || state.drawerOpen ? "hidden" : ""; + } + + function findLink(catId, groupId, linkId) { + var cat = findCategory(catId); + if (!cat) return null; + var groups = cat.groups || []; + for (var i = 0; i < groups.length; i++) { + if (groups[i].id !== groupId) continue; + var links = groups[i].links || []; + for (var j = 0; j < links.length; j++) { + if (links[j].id === linkId) return links[j]; + } + } + return null; + } + + function openLink(link) { + // 容器禁止打开外链 / 跳转其他小工具(见能力清单 §4.2),一律走复制引导 + openLinkSheet(link); + } + + function openLinkSheet(link) { + state.currentLink = link; + els.sheetIcon.src = link.icon || "./icons/_brand.webp"; + els.sheetTitle.textContent = link.title || ""; + els.sheetSub.textContent = link.subtitle || ""; + els.sheetUrlBox.textContent = link.href || ""; + els.sheetStatus.textContent = "按步骤操作:先点绿色按钮选中网址"; + els.sheetStatus.classList.remove("is-error"); + setGuideUi("idle"); + setSheet(true); + } + + function markSelected() { + if (!state.currentLink) return; + if (selectUrlText()) { + setGuideUi("selected"); + els.sheetStatus.textContent = + "已选中蓝色区域 · 请用手指按住网址,在菜单里点「复制」"; + els.sheetStatus.classList.remove("is-error"); + showToast("已选中,请按住复制"); + // 短暂强调第 3 步 + setTimeout(function () { + setGuideStep(3); + var s2 = els.guideSteps && els.guideSteps.querySelector('[data-step="2"]'); + if (s2) s2.classList.add("is-done"); + }, 1600); + } else { + setGuideUi("idle"); + els.sheetStatus.textContent = "自动选中失败,请手指直接按住蓝色网址文字"; + els.sheetStatus.classList.add("is-error"); + setGuideStep(2); + } + } + + function jumpToCategory(id) { + state.activeId = id; + setPill(); + renderDrawer(); + setDrawer(false); + state.jumping = true; + var el = document.getElementById("cat-" + id); + if (el) { + el.scrollIntoView({ behavior: "smooth", block: "start" }); + } + setTimeout(function () { + state.jumping = false; + }, 700); + } + + function setPill() { + var cat = findCategory(state.activeId); + if (els.brandCurrent && cat) { + els.brandCurrent.textContent = cat.title; + } + } + + function onScroll() { + var y = window.scrollY || document.documentElement.scrollTop || 0; + els.backTop.classList.toggle("show", y > 480); + + if (state.jumping) return; + var marker = 100; + var current = categories[0] ? categories[0].id : ""; + for (var i = 0; i < categories.length; i++) { + var el = document.getElementById("cat-" + categories[i].id); + if (!el) continue; + if (el.getBoundingClientRect().top <= marker) { + current = categories[i].id; + } else { + break; + } + } + if (current && current !== state.activeId) { + state.activeId = current; + setPill(); + renderDrawer(); + } + } + + function bind() { + els.btnMenu.addEventListener("click", function () { + setDrawer(true); + }); + els.drawerMask.addEventListener("click", function () { + setDrawer(false); + }); + els.drawerClose.addEventListener("click", function () { + setDrawer(false); + }); + els.btnTheme.addEventListener("click", function () { + setTheme(state.theme === "dark" ? "light" : "dark"); + }); + els.backTop.addEventListener("click", function () { + window.scrollTo({ top: 0, behavior: "smooth" }); + }); + + els.drawerNav.addEventListener("click", function (e) { + var btn = e.target.closest(".drawer-item"); + if (!btn) return; + jumpToCategory(btn.getAttribute("data-cat")); + }); + + els.content.addEventListener("click", function (e) { + var btn = e.target.closest(".link-card"); + if (!btn) return; + var link = findLink( + btn.getAttribute("data-cat"), + btn.getAttribute("data-group"), + btn.getAttribute("data-id") + ); + if (link) openLink(link); + }); + + els.sheetMask.addEventListener("click", function () { + setSheet(false); + }); + els.sheetClose.addEventListener("click", function () { + setSheet(false); + }); + els.sheetSelect.addEventListener("click", function () { + markSelected(); + }); + + els.sheetUrlBox.addEventListener("click", function () { + markSelected(); + }); + + // 用户开始触碰网址区时,推进到第 2/3 步提示 + els.sheetUrlBox.addEventListener("touchstart", function () { + if (els.sheetUrlBox.classList.contains("is-selected")) { + setGuideStep(3); + var s2 = els.guideSteps && els.guideSteps.querySelector('[data-step="2"]'); + if (s2) s2.classList.add("is-done"); + els.sheetStatus.textContent = "按住不放,在弹出菜单中点「复制」"; + } + }, { passive: true }); + + window.addEventListener("scroll", onScroll, { passive: true }); + } + + function init() { + els = { + brandName: $("brand-name"), + brandCurrent: $("brand-current"), + brandLogo: $("brand-logo"), + footer: $("footer"), + content: $("content"), + drawer: $("drawer"), + drawerNav: $("drawer-nav"), + drawerMask: $("drawer-mask"), + drawerClose: $("drawer-close"), + drawerBrand: $("drawer-brand"), + drawerSub: $("drawer-sub"), + btnMenu: $("btn-menu"), + btnTheme: $("btn-theme"), + themeIcon: $("theme-icon"), + backTop: $("back-top"), + sheet: $("sheet"), + sheetMask: $("sheet-mask"), + sheetIcon: $("sheet-icon"), + sheetTitle: $("sheet-title"), + sheetSub: $("sheet-sub"), + sheetUrlBox: $("sheet-url-box"), + sheetStatus: $("sheet-status"), + sheetSelect: $("sheet-select"), + sheetSelectLabel: $("sheet-select-label"), + sheetSelectSub: $("sheet-select-sub"), + sheetClose: $("sheet-close"), + guideSteps: $("guide-steps"), + sheetUrlWrap: $("sheet-url-wrap"), + fingerBtn: $("finger-btn"), + fingerUrl: $("finger-url"), + toast: $("toast"), + }; + + applySafeArea(); + setTheme(readTheme()); + + var brand = data.brand || "游民导航"; + els.brandName.textContent = brand; + els.footer.textContent = data.footer || ""; + els.drawerBrand.textContent = brand; + els.drawerSub.textContent = data.tagline || ""; + if (data.brandIcon && els.brandLogo) { + els.brandLogo.src = data.brandIcon; + } + + renderDrawer(); + renderContent(); + setPill(); + bind(); + onScroll(); + } + + if (document.readyState === "loading") { + document.addEventListener("DOMContentLoaded", init); + } else { + init(); + } +})(); diff --git a/apps/miniprogram/xhs/tool/book-app.js b/apps/miniprogram/xhs/tool/book-app.js new file mode 100644 index 0000000..eecaf17 --- /dev/null +++ b/apps/miniprogram/xhs/tool/book-app.js @@ -0,0 +1,3797 @@ +/* bundled classic script for xhs minitool */ +// Auto-generated by scripts/build_book_data.py — do not edit by hand. +var BOOK_DATA = { + "id": "nomad-solopreneur", + "title": "数字游民 · 一人公司小册", + "subtitle": "写给想把生活与工作重新排布的人", + "author": "Eric的云游日记", + "cover_emoji": "🌏", + "description": "数字游民与一人公司行动地图:地理套利、技能变现、内容资产与30天清单。", + "tags": [ + "数字游民", + "一人公司", + "远程工作", + "副业" + ], + "chapter_count": 16, + "word_count": 3390, + "is_free": true, + "chapters": [ + { + "id": "c1", + "title": "写在前面", + "order": 1, + "content": "> 写给想把生活与工作重新排布的人 \n> 整理自 Eric的云游日记 · 仅供参考 · 持续更新\n\n---\n\n## 写在前面\n\n\n你手里这份小册,不是「一夜暴富教程」,而是一份**把技能做成可带走的收入**的行动地图。\n\n数字游民(Digital Nomad)的本质很简单:\n\n- 收入主要来自互联网与远程协作\n- 人不被一座城市、一份坐班绑死\n- 用**地理套利**把收入换成更舒服的生活与节奏\n\n一人公司(Solopreneur)则是另一半拼图:\n\n| 维度 | 为什么适合普通人 |\n|------|------------------|\n| 启动成本 | 一部电脑 + 稳定网络就能开工 |\n| 交付形态 | 内容、咨询、小产品、远程服务 |\n| 商业模式 | 少而精的客户,或可复用的数字资产 |\n| 时间自由 | 交付可异步,不必坐班打卡 |\n| 地理套利 | 在生活成本友好的城市,也能稳住现金流 |\n\n**声明:**\n\n- 文中不涉及收费课程强推,也不做账号买卖中介\n- 平台与税务规则会变,请以官方最新政策为准\n- 灰色手段风险极高,后文只作踩坑警示,不鼓励模仿\n\n一个人走得快,一群人走得远。欢迎把这份小册当成随身笔记本,边读边改成你自己的版本。\n\n---\n" + }, + { + "id": "c2", + "title": "目录", + "order": 2, + "content": "## 目录\n\n> 请用右上角「目」打开章节列表跳转。\n\n" + }, + { + "id": "c3", + "title": "一、为什么普通人适合做「一人公司」", + "order": 3, + "content": "## 一、为什么普通人适合做「一人公司」\n\n\n### 1.1 杠杆变了\n\n过去普通人创业,往往先要资金、团队、仓库。今天更常见的路径是:\n\n- 先卖**时间与专业**(咨询、远程岗位、项目制)\n- 再沉淀成**可复用资产**(模板、手册、小工具、课程笔记)\n- 最后用资产降低「必须人肉交付」的比例\n\n一人公司不是「单打独斗很酷」,而是:**用最小组织,把价值交付跑通**。\n\n### 1.2 你真正卖的是什么\n\n多数成功的一人公司,卖的不是「神秘方法」,而是:\n\n1. **确定性**:帮客户少踩坑、少决策成本 \n2. **结果感**:交付物清晰(文档、方案、成品) \n3. **信任**:真实经历与稳定输出 \n\n如果你还在找「风口」,不如先问:我过去三年反复帮别人解决的问题是什么?\n\n### 1.3 三种起步形态\n\n1. **远程岗位 / 项目制**:最稳,先换现金流 \n2. **内容 + 产品**:把方法论写成可售卖资产 \n3. **小工具 / 自动化**:用产品服务一小群人 \n\n三种可以叠加,但新手建议:**先有一个能稳定收款的主引擎**。\n\n---\n" + }, + { + "id": "c4", + "title": "二、数字游民视角:地理套利与生活设计", + "order": 4, + "content": "## 二、数字游民视角:地理套利与生活设计\n\n\n### 2.1 什么是地理套利\n\n数字游民最本质的优势,不是「环球旅行发朋友圈」,而是:\n\n**高购买力收入 × 友好生活成本地区 = 更大的自由现金流**\n\n常见组合:\n\n- 远程收入 → 在国内三四线 / 生活成本友好城市生活 \n- 错峰旅居:淡季交通与房租更松 \n- 把「城市」当成可切换的操作系统,而不是身份标签 \n\n国内常见第一站:气候友好、物价相对友好、网络与快递顺畅的城市。出国旅居请自行评估安全、签证与医疗,不要用幸存者偏差安慰自己。\n\n### 2.2 生活设计先于「逃逸」\n\n真正可持续的游民生活,通常先回答:\n\n1. 每月**最低生存成本**是多少? \n2. 收入波动时,能撑几个月? \n3. 健康、社交、专注环境如何保障? \n\n「先辞职再想办法」很少是好策略。更稳的是:副业跑通 → 缓冲金到位 → 再调整工作形态。\n\n### 2.3 节奏比地点更重要\n\n换城市解决不了拖延与分心。游民需要的是:\n\n- 固定的深度工作时段 \n- 可随身带走的工具与资料 \n- 每周一次复盘:收入、精力、关系 \n\n地点是风景,节奏才是系统。\n\n---\n" + }, + { + "id": "c5", + "title": "三、选一条可带走的能力:技能盘点", + "order": 5, + "content": "## 三、选一条可带走的能力:技能盘点\n\n\n### 3.1 能力四象限\n\n把你的技能放进四个格子:\n\n| | 你喜欢 | 你不喜欢 |\n|--|--------|----------|\n| **别人愿意付费** | ★ 优先发展 | 可短期现金牛 |\n| **别人不愿付费** | 爱好,控制投入 | 尽快减少 |\n\n一人公司的主航道,尽量落在「喜欢 × 可付费」。\n\n### 3.2 可带走能力的特征\n\n- 不依赖本地实体店面 \n- 交付可线上完成或可邮寄数字化 \n- 结果可验证(作品集、案例、前后对比) \n\n例如:写作与编辑、设计与演示、研究与报告、自动化与小工具、教学与陪跑、运营与内容策划。\n\n### 3.3 写出你的「一句话供给」\n\n模板:\n\n> 我帮助【谁】,在【场景】下,完成【结果】,方式是【方法】。\n\n写不清楚,就很难定价,也很难被转介绍。\n\n---\n" + }, + { + "id": "c6", + "title": "四、收入结构:现金牛、被动底座与试验田", + "order": 6, + "content": "## 四、收入结构:现金牛、被动底座与试验田\n\n\n### 4.1 三种发动机\n\n成熟一点的一人公司,收入通常分层:\n\n```\n远程工作 / 接单(现金牛)\n +\n可复用数字产品(被动底座)\n +\n试验中的新产品(试验田)\n────────────────\n更稳的自由现金流\n```\n\n- **现金牛**:保证这个月能活 \n- **被动底座**:睡后仍可能产生的复利 \n- **试验田**:允许失败的小预算探索 \n\n### 4.2 别过早「只做被动」\n\n被动收入大多是主动交付的副产品。先有人愿意为你的时间付钱,再谈产品化。\n\n### 4.3 每周收入复盘三个数\n\n1. 本周进账 \n2. 本周有效深度工作小时 \n3. 下周唯一最重要目标 \n\n简单到能坚持,比复杂表格有用。\n\n---\n" + }, + { + "id": "c7", + "title": "五、内容资产:把经历写成可复用产品", + "order": 7, + "content": "## 五、内容资产:把经历写成可复用产品\n\n\n### 5.1 内容不是表演,是资产生产线\n\n你写过的踩坑、清单、模板、复盘,都可以变成:\n\n- 公开笔记(建立信任) \n- 付费手册 / 模板包 \n- 陪跑与咨询的「说明书」 \n\n### 5.2 最小内容系统\n\n每周固定产出即可,例如:\n\n1. 1 篇深度复盘(问题 → 过程 → 结论) \n2. 3 条短更新(工具、书摘、工作流) \n3. 1 次整理:把旧笔记升级成模板 \n\n持续比爆款重要。\n\n### 5.3 产品化三步\n\n1. **文档化**:把口头经验写成步骤 \n2. **模板化**:别人填空就能用 \n3. **服务化**:仍搞不定的人,可加咨询档 \n\n从文档走到服务,客单价自然抬升。\n\n---\n" + }, + { + "id": "c8", + "title": "六、远程工作与接单:先稳住现金流", + "order": 8, + "content": "## 六、远程工作与接单:先稳住现金流\n\n\n### 6.1 远程岗位的好处\n\n- 收入相对可预期 \n- 强迫你建立异步协作习惯 \n- 为一人公司提供「安全垫」 \n\n### 6.2 接单的注意事项\n\n- 范围写清楚(Scope) \n- 修改次数与交付节点写进约定 \n- 预付款 / 阶段款,避免尾款黑洞 \n\n### 6.3 作品集怎么做才有用\n\n不要堆数量,展示:\n\n1. 背景与约束 \n2. 你做了什么关键决策 \n3. 可感知的结果 \n\n三到五个扎实案例,胜过二十个截图。\n\n---\n" + }, + { + "id": "c9", + "title": "七、工具栈:够用就好,别被软件绑架", + "order": 9, + "content": "## 七、工具栈:够用就好,别被软件绑架\n\n\n### 7.1 最小工具箱\n\n- 笔记与知识库(能全文搜索) \n- 任务清单(今天只看三件事) \n- 文档与云盘(可跨设备) \n- 日历(保护深度工作块) \n\n能跑通闭环之前,少追新工具。\n\n### 7.2 自动化的正确时机\n\n当你第三次重复同一操作,再自动化。过早自动化,等于给错误流程加速。\n\n### 7.3 AI 的用法\n\n适合:\n\n- 起草、摘要、对照检查 \n- 生成提纲与检查清单 \n\n不适合:\n\n- 代替你对客户结果负责 \n- 输出你自己都看不懂的方案 \n\nAI 是副驾驶,方向盘还在你手里。\n\n---\n" + }, + { + "id": "c10", + "title": "八、时间与精力:副业实验的正确姿势", + "order": 10, + "content": "## 八、时间与精力:副业实验的正确姿势\n\n\n### 8.1 副业实验协议\n\n对大多数上班族:\n\n1. 每周固定 6~10 小时实验窗 \n2. 连续 8~12 周再评估去留 \n3. 用「可验证里程碑」代替感觉 \n\n例如:完成作品集、收到第一笔小额付款、沉淀出第一份可售模板。\n\n### 8.2 精力管理三原则\n\n- 难事先做 \n- 社交型任务集中处理 \n- 睡眠与运动是生产力,不是奖励 \n\n### 8.3 防止自我压榨\n\n一人公司最常见的失败不是没单,而是燃尽。给自己定:\n\n- 每周休息日不可谈判 \n- 深度工作有上限(健康优先) \n\n---\n" + }, + { + "id": "c11", + "title": "九、定价、边界与客户管理", + "order": 11, + "content": "## 九、定价、边界与客户管理\n\n\n### 9.1 定价从成本倒推不够\n\n还要看:\n\n- 你替代了客户多少决策成本 \n- 市场同类交付的价格带 \n- 你是否提供售后与迭代 \n\n早期可以略低换案例,但要有「涨价日程」。\n\n### 9.2 边界清单(建议抄进笔记)\n\n- 不接什么类型的需求 \n- 沟通时段 \n- 修改次数 \n- 延期如何处理 \n\n边界清晰,关系更久。\n\n### 9.3 客户分级\n\n- A:愿付费、沟通顺、可复购 \n- B:可做,但不优先 \n- C:消耗大、价值低 → 礼貌拒绝 \n\n一人公司的自由,很大程度来自「会拒绝」。\n\n---\n" + }, + { + "id": "c12", + "title": "十、合规与财务:别等到卡款才慌", + "order": 12, + "content": "## 十、合规与财务:别等到卡款才慌\n\n\n### 10.1 基础习惯\n\n- 收支分账记录 \n- 合同 / 聊天记录留存 \n- 发票与税务按你所在地规则处理 \n\n### 10.2 缓冲金\n\n建议至少准备:**3~6 个月最低生活成本**。游民生活波动更大,缓冲金是自由的地基。\n\n### 10.3 别碰的灰区\n\n账号买卖、虚假流量、欺诈性承诺、违规跨境操作等,短期看似捷径,长期是地雷。知道即可,不要当主策略。\n\n---\n" + }, + { + "id": "c13", + "title": "十一、赛道灵感:普通人能落地的方向", + "order": 13, + "content": "## 十一、赛道灵感:普通人能落地的方向\n\n\n### 11.1 兜底方向(示例)\n\n1. **写作与内容策划**:帮小团队做选题、文案、手册 \n2. **效率与自动化**:帮人整理工作流、表格、小脚本 \n3. **垂直咨询**:你有真实从业经验的领域陪跑 \n\n### 11.2 「元能力」:教别人复盘\n\n如果你暂时没有强垂直:\n\n> 把「如何建立可持续的一人工作系统」本身做成内容与产品。\n\n但请建立在真实实践上,而不是空转概念。\n\n### 11.3 本地优势也能在线卖\n\n你熟悉的城市、行业、语言、审美,都可以变成线上可交付的信息差产品——关键是**可验证、可复用、可持续更新**。\n\n---\n" + }, + { + "id": "c14", + "title": "十二、从副业到一人公司:扩展路径", + "order": 14, + "content": "## 十二、从副业到一人公司:扩展路径\n\n\n### 12.1 升级阶梯\n\n```\n副业实验\n → 稳定月入覆盖部分生活成本\n → 产品化(模板 / 手册)\n → 提高客单价或减少人肉交付\n → 可选:减班 / 远程 / 旅居\n```\n\n每一步都要有数字,而不是口号。\n\n### 12.2 一人公司的组织原则\n\n- 默认外包非核心 \n- 文档先于口头约定 \n- 系统优先于英雄主义加班 \n\n### 12.3 收入拼图(理想态)\n\n```\n远程工作 / 接单(现金牛)\n +\n数字产品 / 模板(被动底座)\n +\n小社群或陪跑(高信任)\n────────────────\n地理套利下的自由现金流\n```\n\n---\n" + }, + { + "id": "c15", + "title": "十三、30 天行动清单", + "order": 15, + "content": "## 十三、30 天行动清单\n\n\n### 第 1 周:盘点与定位\n\n- [ ] 写出技能四象限 \n- [ ] 完成「一句话供给」 \n- [ ] 算出每月最低生活成本与缓冲金缺口 \n\n### 第 2 周:作品与可信度\n\n- [ ] 整理 3 个案例(或练习项目) \n- [ ] 搭一个简单主页 / 简介页(不必复杂) \n- [ ] 公开更新 2 次真实复盘 \n\n### 第 3 周:第一次交易\n\n- [ ] 给出明确报价与边界 \n- [ ] 完成 1 次小额交付或预售模板 \n- [ ] 记录耗时,为定价校准 \n\n### 第 4 周:系统化\n\n- [ ] 固化每周工作节奏 \n- [ ] 把重复内容做成模板 \n- [ ] 复盘:保留 / 调整 / 放弃什么 \n\n完成不了全部也没关系——**完成「第一次诚实交付」比完美计划重要。**\n\n---\n" + }, + { + "id": "c16", + "title": "十四、结语:自由是设计出来的", + "order": 16, + "content": "## 十四、结语:自由是设计出来的\n\n\n书店里很少有一本「刚好适合你」的人生说明书。这本小册只做一件事:把分散的经验,收成一份可执行的底稿。\n\n数字游民与一人公司改变生活的方式,通常不是戏剧性的一夜翻盘,而是:\n\n> 某天你发现:收入不再完全绑在工位上; \n> 你的笔记、模板与信誉,开始替你工作; \n> 你可以选择城市,而不是被城市选择。\n\n它也会伴随试错:报价踩坑、客户消耗、自我管理失败……这些都是真实成本,不是营销话术。\n\n**给你的最终建议:**\n\n1. 把一人公司当**长期资产**,不是彩票 \n2. 先稳住**现金牛**,再谈被动与旅居 \n3. 用文档与边界保护精力 \n4. 小步产品化,持续复盘 \n5. 灰产捷径可以「知道」,但不要当成主策略 \n\n后续可能更新:选题与定价实验、远程协作清单、一人公司财务表等。\n\n---\n\n### 附录 A:关键概念速查\n\n| 项目 | 说明 |\n|------|------|\n| 地理套利 | 收入与生活成本不在同一「坐标系」 |\n| 现金牛 | 短期稳定进账的引擎 |\n| 被动底座 | 可复用、可重复销售的数字资产 |\n| 试验田 | 小预算试错区 |\n| 一人公司 | 以个人为核心的最小商业系统 |\n| 缓冲金 | 3~6 个月最低生活成本建议 |\n\n### 附录 B:读法建议\n\n1. 先通读「写在前面」与「结语」定方向 \n2. 按 30 天清单执行,而不是只收藏 \n3. 每章只带走一个可立刻做的动作 \n\n---\n\n*完 · 愿你把自由设计成可执行的系统。*\n" + } + ] +}; + +/** + * Lightweight markdown → HTML for offline 小红书小工具. + * No eval / network / Worker. + */ +(function (global) { + function themeColors(theme) { + if (theme === "light") { + return { + text: "#1e1630", + muted: "#6d6286", + accent: "#db2777", + accentSoft: "rgba(219,39,119,.1)", + code: "#7c3aed", + strong: "#120f1d", + }; + } + if (theme === "sepia") { + return { + text: "#3d2f1f", + muted: "#8a7358", + accent: "#c2410c", + accentSoft: "rgba(194,65,12,.12)", + code: "#c2410c", + strong: "#2a1f14", + }; + } + return { + text: "#f3eefc", + muted: "#b4a9c8", + accent: "#ff7ab6", + accentSoft: "rgba(255,122,182,.14)", + code: "#c4b5fd", + strong: "#ffffff", + }; + } + + function escapeHtml(s) { + return String(s) + .replace(/&/g, "&") + .replace(//g, ">"); + } + + function inline(s, c) { + return escapeHtml(s) + .replace(/\*\*(.+?)\*\*/g, '$1') + .replace(/\*(.+?)\*/g, '$1') + .replace(/`([^`]+)`/g, '$1'); + } + + function markdownToHtml(src, opts) { + opts = opts || {}; + var dropCap = opts.dropCap !== false; + var c = themeColors(opts.theme || "dark"); + var text = String(src || "").replace(/\r\n/g, "\n"); + text = text.replace(//g, ""); + text = text.replace(//gi, "> 🎬 视频请在异度世界公众号查看"); + text = text.replace(//gi, "> 🖼 配图已省略(离线版)"); + text = text.replace(/!\[[^\]]*\]\([^)]+\)/g, "> 🖼 配图已省略(离线版)"); + + var lines = text.split("\n"); + var out = []; + var inCode = false; + var codeBuf = []; + var inUl = false; + var inOl = false; + var olIndex = 0; + var inQuote = false; + var quoteBuf = []; + var paraCount = 0; + var skippedChapterTitle = false; + + function closeLists() { + if (inUl) { + out.push("
"); + inUl = false; + } + if (inOl) { + out.push(""); + inOl = false; + olIndex = 0; + } + } + + function flushQuote() { + if (!inQuote) return; + var body = quoteBuf.map(function (q) { + return inline(q, c); + }).join("
"); + out.push('
' + body + "
"); + inQuote = false; + quoteBuf = []; + } + + function isTableSep(line) { + return /^\s*\|?[\s:-]+\|[\s|:-]*\|?\s*$/.test(line); + } + + function splitRow(line) { + var s = line.trim(); + if (s.charAt(0) === "|") s = s.slice(1); + if (s.charAt(s.length - 1) === "|") s = s.slice(0, -1); + return s.split("|").map(function (cell) { + return cell.trim(); + }); + } + + function renderTable(rows) { + if (!rows.length) return; + var html = ['
']; + rows[0].forEach(function (cell) { + html.push(""); + }); + html.push(""); + for (var r = 1; r < rows.length; r++) { + html.push(""); + rows[r].forEach(function (cell) { + html.push(""); + }); + html.push(""); + } + html.push("
" + inline(cell, c) + "
" + inline(cell, c) + "
"); + out.push(html.join("")); + } + + for (var i = 0; i < lines.length; i++) { + var raw = lines[i]; + var line = raw; + + if (/^```/.test(line)) { + flushQuote(); + closeLists(); + if (inCode) { + out.push('
' + escapeHtml(codeBuf.join("\n")) + "
"); + codeBuf = []; + inCode = false; + } else { + inCode = true; + } + continue; + } + if (inCode) { + codeBuf.push(line); + continue; + } + + // GFM table + if ( + line.indexOf("|") !== -1 && + i + 1 < lines.length && + isTableSep(lines[i + 1]) + ) { + flushQuote(); + closeLists(); + var rows = [splitRow(line)]; + i += 1; // skip separator + while (i + 1 < lines.length && lines[i + 1].indexOf("|") !== -1 && lines[i + 1].trim()) { + i += 1; + if (isTableSep(lines[i])) continue; + rows.push(splitRow(lines[i])); + } + renderTable(rows); + continue; + } + + if (/^\s*>\s?/.test(line)) { + closeLists(); + inQuote = true; + quoteBuf.push(line.replace(/^\s*>\s?/, "")); + continue; + } + if (inQuote) flushQuote(); + + if (/^\s*---+\s*$/.test(line) || /^\s*\*\*\*+\s*$/.test(line)) { + closeLists(); + out.push('
'); + continue; + } + + var h1 = /^#\s+(.+)$/.exec(line); + if (h1) { + closeLists(); + if (!skippedChapterTitle) { + skippedChapterTitle = true; + continue; + } + out.push("

" + inline(h1[1], c) + "

"); + continue; + } + var h2 = /^##\s+(.+)$/.exec(line); + if (h2) { + closeLists(); + // Chapter title already shown in reader chrome — skip first ## + if (!skippedChapterTitle) { + skippedChapterTitle = true; + continue; + } + out.push("

" + inline(h2[1], c) + "

"); + continue; + } + var h3 = /^###\s+(.+)$/.exec(line); + if (h3) { + closeLists(); + out.push("

" + inline(h3[1], c) + "

"); + continue; + } + + var task = /^\s*[-*+]\s+\[([ xX])\]\s+(.+)$/.exec(line); + if (task) { + if (inOl) { + out.push(""); + inOl = false; + olIndex = 0; + } + if (!inUl) { + out.push('
'); + inUl = true; + } + var mark = /x/i.test(task[1]) ? "☑" : "☐"; + out.push("
" + mark + " " + inline(task[2], c) + "
"); + continue; + } + + var ul = /^\s*[-*+]\s+(.+)$/.exec(line); + if (ul) { + if (inOl) { + out.push("
"); + inOl = false; + olIndex = 0; + } + if (!inUl) { + out.push('
'); + inUl = true; + } + out.push("
• " + inline(ul[1], c) + "
"); + continue; + } + var ol = /^\s*(\d+)\.\s+(.+)$/.exec(line); + if (ol) { + if (inUl) { + out.push("
"); + inUl = false; + } + if (!inOl) { + out.push('
'); + inOl = true; + olIndex = 0; + } + olIndex += 1; + out.push("
" + olIndex + ". " + inline(ol[2], c) + "
"); + continue; + } + + if (!line.trim()) { + closeLists(); + continue; + } + + closeLists(); + paraCount += 1; + var cls = dropCap && paraCount === 1 ? ' class="dropcap"' : ""; + out.push("" + inline(line.trim(), c) + "

"); + } + + flushQuote(); + closeLists(); + if (inCode) { + out.push('
' + escapeHtml(codeBuf.join("\n")) + "
"); + } + return out.join(""); + } + + global.MarkdownLite = { markdownToHtml: markdownToHtml, themeColors: themeColors }; +})(window); + +/** + * Official XHS miniTool bridge helpers (Chrome 61 / ES2017). + * Prefer window.xhs.miniTool Storage (9.46+); fall back to localStorage. + */ +(function (global) { + "use strict"; + + var STORAGE_MIN = 9460; + var COMMENT_MIN = 9490; + var FILE_MIN = 9490; + + function readBuildVersion(launchOptions) { + var env = launchOptions && launchOptions.miniToolEnv; + return Number(env && env.buildVersion) || 0; + } + + function getClientVersion(buildVersion) { + return Math.floor((Number(buildVersion) || 0) / 1000); + } + + function isClientVersionAtLeast(buildVersion, minimum) { + return getClientVersion(buildVersion) >= minimum; + } + + function getMiniTool() { + return global.xhs && global.xhs.miniTool ? global.xhs.miniTool : null; + } + + function getBuildVersion() { + var xhs = global.xhs; + var sync = readBuildVersion(xhs && xhs.launchOptions); + if (sync) { + return Promise.resolve(sync); + } + var mt = getMiniTool(); + if (!mt || typeof mt.getLaunchOptions !== "function") { + return Promise.resolve(0); + } + return Promise.resolve(mt.getLaunchOptions()) + .then(function (opts) { + return readBuildVersion(opts); + }) + .catch(function () { + return 0; + }); + } + + function setLocalData(key, data, encrypt) { + var serialized; + try { + serialized = JSON.stringify(data); + } catch (e) { + return Promise.resolve(false); + } + if (typeof serialized !== "string") return Promise.resolve(false); + var useEncrypt = !!encrypt; + + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + isClientVersionAtLeast(buildVersion, STORAGE_MIN) && + mt && + typeof mt.setStorage === "function" + ) { + var payload = { key: key, data: serialized }; + if (useEncrypt) payload.encrypt = true; + return Promise.resolve(mt.setStorage(payload)) + .then(function () { + return true; + }) + .catch(function () { + return writeBrowser(key, serialized); + }); + } + return writeBrowser(key, serialized); + }); + } + + function writeBrowser(key, serialized) { + try { + global.localStorage.setItem(key, serialized); + return true; + } catch (e) { + return false; + } + } + + function getLocalData(key, fallback, encrypt) { + var useEncrypt = !!encrypt; + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + isClientVersionAtLeast(buildVersion, STORAGE_MIN) && + mt && + typeof mt.getStorage === "function" + ) { + var payload = { key: key }; + if (useEncrypt) payload.encrypt = true; + return Promise.resolve(mt.getStorage(payload)) + .then(function (res) { + var raw = res && res.data; + if (raw != null && raw !== "") { + try { + return JSON.parse(raw); + } catch (e) { + return fallback; + } + } + // Retry without encrypt (migration), then browser + if (useEncrypt) { + return Promise.resolve(mt.getStorage({ key: key })) + .then(function (res2) { + var raw2 = res2 && res2.data; + if (raw2 != null && raw2 !== "") { + try { + var parsed = JSON.parse(raw2); + return setLocalData(key, parsed, true).then(function () { + return parsed; + }); + } catch (e2) { + return readBrowser(key, fallback); + } + } + return readBrowser(key, fallback); + }) + .catch(function () { + return readBrowser(key, fallback); + }); + } + var fromBrowser = readBrowser(key, null); + if (fromBrowser == null) return fallback; + return writeNative(mt, key, JSON.stringify(fromBrowser), false).then( + function () { + return fromBrowser; + }, + function () { + return fromBrowser; + } + ); + }) + .catch(function () { + return readBrowser(key, fallback); + }); + } + return readBrowser(key, fallback); + }); + } + + function writeNative(mt, key, serialized, encrypt) { + if (!mt || typeof mt.setStorage !== "function") { + return Promise.resolve(false); + } + var payload = { key: key, data: serialized }; + if (encrypt) payload.encrypt = true; + return Promise.resolve(mt.setStorage(payload)).then( + function () { + return true; + }, + function () { + return false; + } + ); + } + + function readBrowser(key, fallback) { + try { + var raw = global.localStorage.getItem(key); + if (raw == null || raw === "") return fallback; + return JSON.parse(raw); + } catch (e) { + return fallback; + } + } + + function removeLocalData(key) { + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + isClientVersionAtLeast(buildVersion, STORAGE_MIN) && + mt && + typeof mt.removeStorage === "function" + ) { + return Promise.resolve(mt.removeStorage({ key: key })) + .then(function () { + removeBrowser(key); + return true; + }) + .catch(function () { + return removeBrowser(key); + }); + } + return removeBrowser(key); + }); + } + + function clearLocalData() { + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + isClientVersionAtLeast(buildVersion, STORAGE_MIN) && + mt && + typeof mt.clearStorage === "function" + ) { + return Promise.resolve(mt.clearStorage()) + .then(function () { + clearBrowser(); + return true; + }) + .catch(function () { + return clearBrowser(); + }); + } + return clearBrowser(); + }); + } + + function removeBrowser(key) { + try { + global.localStorage.removeItem(key); + return true; + } catch (e) { + return false; + } + } + + function clearBrowser() { + try { + global.localStorage.clear(); + return true; + } catch (e) { + return false; + } + } + + function getLaunchOptions() { + var xhs = global.xhs; + if (xhs && xhs.launchOptions) { + return Promise.resolve(xhs.launchOptions); + } + var mt = getMiniTool(); + if (!mt || typeof mt.getLaunchOptions !== "function") { + return Promise.resolve(null); + } + return Promise.resolve(mt.getLaunchOptions()).catch(function () { + return null; + }); + } + + /** Read miniToolSnapshotInfo from launch options (comment re-entry, §3.9). */ + function readSnapshotInfo(launchOptions) { + if (!launchOptions) return null; + var raw = + launchOptions.miniToolSnapshotInfo || + (launchOptions.query && launchOptions.query.miniToolSnapshotInfo) || + (launchOptions.referrerInfo && + launchOptions.referrerInfo.miniToolSnapshotInfo) || + (launchOptions.extraData && launchOptions.extraData.miniToolSnapshotInfo); + if (!raw) return null; + if (typeof raw === "object") return raw; + try { + return JSON.parse(raw); + } catch (e) { + return null; + } + } + + function callApi(name, options) { + var mt = getMiniTool(); + if (!mt || typeof mt[name] !== "function") { + return Promise.reject({ errMsg: name + ":fail not available" }); + } + return Promise.resolve(mt[name](options || {})); + } + + function writeTempFile(dataUrl) { + return callApi("writeTempFile", { data: dataUrl }).then(function (res) { + return (res && res.filePath) || dataUrl; + }); + } + + function saveImageToPhotosAlbum(filePath) { + return callApi("saveImageToPhotosAlbum", { filePath: filePath }); + } + + function postNote(opts) { + return callApi("postNote", opts); + } + + function canPostComment(buildVersion) { + var mt = getMiniTool(); + return ( + isClientVersionAtLeast(buildVersion, COMMENT_MIN) && + mt && + typeof mt.interactionOpenApi === "function" + ); + } + + function postComment(payload, saveToAlbum) { + return callApi("interactionOpenApi", { + payload: payload, + saveToAlbum: saveToAlbum !== false + }); + } + + function getStorageInfo() { + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + !isClientVersionAtLeast(buildVersion, STORAGE_MIN) || + !mt || + typeof mt.getStorageInfo !== "function" + ) { + return null; + } + return Promise.resolve(mt.getStorageInfo()).catch(function () { + return null; + }); + }); + } + + function canUseFileSystem(buildVersion) { + var mt = getMiniTool(); + return ( + isClientVersionAtLeast(buildVersion, FILE_MIN) && + mt && + typeof mt.writeFile === "function" && + typeof mt.readFile === "function" + ); + } + + function getUserDataPath() { + return getLaunchOptions().then(function (opts) { + var env = opts && opts.miniToolEnv; + return (env && env.userDataPath) || ""; + }); + } + + function ensureDir(dirPath) { + var mt = getMiniTool(); + if (!mt || typeof mt.mkdir !== "function") { + return Promise.resolve(false); + } + return Promise.resolve(mt.mkdir({ dirPath: dirPath, recursive: true })) + .then(function () { + return true; + }) + .catch(function () { + return false; + }); + } + + function writeUtf8File(relativePath, data) { + return getBuildVersion().then(function (bv) { + if (!canUseFileSystem(bv)) { + return Promise.reject({ errMsg: "writeFile:fail version" }); + } + return getUserDataPath().then(function (root) { + if (!root) return Promise.reject({ errMsg: "writeFile:fail no path" }); + var rel = String(relativePath || "").replace(/^\/+/, ""); + var parts = rel.split("/"); + var dir = + parts.length > 1 ? root + "/" + parts.slice(0, -1).join("/") : root; + var filePath = root + "/" + rel; + return ensureDir(dir).then(function () { + return callApi("writeFile", { + filePath: filePath, + data: typeof data === "string" ? data : JSON.stringify(data), + encoding: "utf8" + }).then(function () { + return filePath; + }); + }); + }); + }); + } + + function appendUtf8File(relativePath, data) { + return getBuildVersion().then(function (bv) { + if (!canUseFileSystem(bv)) { + return Promise.reject({ errMsg: "appendFile:fail version" }); + } + var mt = getMiniTool(); + if (!mt || typeof mt.appendFile !== "function") { + // Fallback: read + write + return readUtf8File(relativePath).then(function (prev) { + return writeUtf8File( + relativePath, + (prev || "") + (typeof data === "string" ? data : String(data)) + ); + }); + } + return getUserDataPath().then(function (root) { + if (!root) return Promise.reject({ errMsg: "appendFile:fail no path" }); + var rel = String(relativePath || "").replace(/^\/+/, ""); + var parts = rel.split("/"); + var dir = + parts.length > 1 ? root + "/" + parts.slice(0, -1).join("/") : root; + var filePath = root + "/" + rel; + return ensureDir(dir).then(function () { + return callApi("appendFile", { + filePath: filePath, + data: typeof data === "string" ? data : String(data), + encoding: "utf8" + }).then(function () { + return filePath; + }); + }); + }); + }); + } + + function postVideoNote(opts) { + var videoRes = { video_url: opts.videoPath }; + if (opts.coverPath) videoRes.cover_url = opts.coverPath; + return callApi("postNote", { + title: opts.title, + content: opts.content, + pageType: "video_publish", + mediaInfo: { + video_resources: videoRes + } + }); + } + + function readUtf8File(relativePath) { + return getBuildVersion().then(function (bv) { + if (!canUseFileSystem(bv)) { + return Promise.resolve(null); + } + return getUserDataPath().then(function (root) { + if (!root) return null; + var filePath = root + "/" + String(relativePath || "").replace(/^\/+/, ""); + return callApi("readFile", { filePath: filePath, encoding: "utf8" }) + .then(function (res) { + return res && res.data != null ? res.data : null; + }) + .catch(function () { + return null; + }); + }); + }); + } + + /** Write dataURL to temp, then optionally persist via saveFile (9.49+). */ + function persistImage(dataUrl, relativePath) { + return writeTempFile(dataUrl).then(function (tempPath) { + return getBuildVersion().then(function (bv) { + var mt = getMiniTool(); + if ( + !relativePath || + !isClientVersionAtLeast(bv, FILE_MIN) || + !mt || + typeof mt.saveFile !== "function" + ) { + return tempPath; + } + return getUserDataPath().then(function (root) { + if (!root) return tempPath; + var dest = root + "/" + String(relativePath).replace(/^\/+/, ""); + var dir = dest.replace(/\/[^/]+$/, ""); + return ensureDir(dir).then(function () { + return callApi("saveFile", { + tempFilePath: tempPath, + filePath: dest + }) + .then(function (res) { + return (res && res.savedFilePath) || dest || tempPath; + }) + .catch(function () { + return tempPath; + }); + }); + }); + }); + }); + } + + function getFileStorageInfo() { + return getBuildVersion().then(function (bv) { + var mt = getMiniTool(); + if ( + !isClientVersionAtLeast(bv, FILE_MIN) || + !mt || + typeof mt.getFileStorageInfo !== "function" + ) { + return null; + } + return Promise.resolve(mt.getFileStorageInfo()).catch(function () { + return null; + }); + }); + } + + function unlinkFile(relativeOrAbsPath) { + return getBuildVersion().then(function (bv) { + var mt = getMiniTool(); + if ( + !isClientVersionAtLeast(bv, FILE_MIN) || + !mt || + typeof mt.unlink !== "function" + ) { + return false; + } + var path = String(relativeOrAbsPath || ""); + if (!path) return false; + var p = Promise.resolve(path); + if (path.indexOf("/") !== 0 && path.indexOf("usr") !== 0) { + p = getUserDataPath().then(function (root) { + return root ? root + "/" + path.replace(/^\/+/, "") : path; + }); + } + return p.then(function (filePath) { + return callApi("unlink", { filePath: filePath }) + .then(function () { + return true; + }) + .catch(function () { + return false; + }); + }); + }); + } + + function readDirList(relativeDir) { + return getBuildVersion().then(function (bv) { + var mt = getMiniTool(); + if ( + !isClientVersionAtLeast(bv, FILE_MIN) || + !mt || + typeof mt.readDir !== "function" + ) { + return []; + } + return getUserDataPath().then(function (root) { + if (!root) return []; + var dirPath = + root + + (relativeDir + ? "/" + String(relativeDir).replace(/^\/+|\/+$/g, "") + : ""); + return callApi("readDir", { dirPath: dirPath }) + .then(function (res) { + var files = (res && res.files) || []; + return files.map(function (f) { + if (typeof f === "string") { + return { name: f, path: dirPath + "/" + f }; + } + var name = f.name || f.fileName || String(f); + return { + name: name, + path: f.path || f.filePath || dirPath + "/" + name, + isDir: !!(f.isDir || f.isDirectory) + }; + }); + }) + .catch(function () { + return []; + }); + }); + }); + } + + function cleanupShareDir() { + return readDirList("share").then(function (files) { + var chain = Promise.resolve(0); + for (var i = 0; i < files.length; i++) { + (function (file) { + if (file.isDir) return; + chain = chain.then(function (n) { + return callApi("unlink", { filePath: file.path }) + .then(function () { + return n + 1; + }) + .catch(function () { + return n; + }); + }); + })(files[i]); + } + return chain; + }); + } + + /** Convert File / Blob to data URL (offline, no network). */ + function blobToDataUrl(blob) { + return new Promise(function (resolve, reject) { + if (!blob) { + reject({ errMsg: "blobToDataUrl:fail empty" }); + return; + } + try { + var reader = new FileReader(); + reader.onload = function () { + resolve(reader.result); + }; + reader.onerror = function () { + reject({ errMsg: "blobToDataUrl:fail read" }); + }; + reader.readAsDataURL(blob); + } catch (e) { + reject({ errMsg: "blobToDataUrl:fail " + (e && e.message) }); + } + }); + } + + global.XhsBridge = { + getBuildVersion: getBuildVersion, + getClientVersion: getClientVersion, + isClientVersionAtLeast: isClientVersionAtLeast, + setLocalData: setLocalData, + getLocalData: getLocalData, + removeLocalData: removeLocalData, + clearLocalData: clearLocalData, + getStorageInfo: getStorageInfo, + getFileStorageInfo: getFileStorageInfo, + getLaunchOptions: getLaunchOptions, + readSnapshotInfo: readSnapshotInfo, + writeTempFile: writeTempFile, + saveImageToPhotosAlbum: saveImageToPhotosAlbum, + postNote: postNote, + canPostComment: canPostComment, + postComment: postComment, + canUseFileSystem: canUseFileSystem, + getUserDataPath: getUserDataPath, + writeUtf8File: writeUtf8File, + appendUtf8File: appendUtf8File, + readUtf8File: readUtf8File, + persistImage: persistImage, + unlinkFile: unlinkFile, + readDirList: readDirList, + cleanupShareDir: cleanupShareDir, + blobToDataUrl: blobToDataUrl, + postVideoNote: postVideoNote, + getMiniTool: getMiniTool, + STORAGE_MIN: STORAGE_MIN, + COMMENT_MIN: COMMENT_MIN, + FILE_MIN: FILE_MIN + }; +})(window); + +(function () { + "use strict"; + + var PROGRESS_KEY = "yidu_reading_progress"; + var PREFS_KEY = "yidu_reader_prefs"; + var BOOKMARKS_KEY = "yidu_bookmarks"; + var NOTES_KEY = "yidu_clip_notes"; + var STREAK_KEY = "yidu_checkin_streak"; + var JOURNAL_KEY = "yidu_journal"; + var TIME_KEY = "yidu_read_time"; + var WORKS_KEY = "yidu_works"; + var NOTES_FILE = "notes/clips.json"; + var JOURNAL_FILE = "notes/journal.json"; + var Bridge = window.XhsBridge; + var FONT_SIZES = [ + { label: "小", value: 15 }, + { label: "中", value: 16 }, + { label: "大", value: 17 }, + { label: "特", value: 18 } + ]; + var LINE_HEIGHTS = [ + { label: "紧", value: "1.55" }, + { label: "适", value: "1.7" }, + { label: "疏", value: "1.9" } + ]; + var FONTS = [ + { label: "黑", value: "sans", css: "'PingFang SC','Hiragino Sans GB','Microsoft YaHei',sans-serif" }, + { label: "宋", value: "serif", css: "'Songti SC','STSong','SimSun',serif" } + ]; + var THEMES = [ + { label: "夜", value: "dark" }, + { label: "暖", value: "sepia" }, + { label: "昼", value: "light" } + ]; + var DEFAULT_PREFS = { + fontSize: 16, + lineHeight: "1.7", + fontFamily: "sans", + theme: "dark" + }; + + var CHAPTER_EMOJIS = ["📖", "✨", "🔥", "💡", "🎯", "🚀", "💎", "🧭", "🌙", "⚡", "🎬", "☁️"]; + + var state = { + book: null, + prefs: null, + progress: null, + bookmarks: [], + notes: [], + journal: [], + works: [], + readTime: { date: "", seconds: 0, total: 0 }, + readTick: null, + streak: { days: 0, lastDate: "" }, + drawerTab: "chapters", + activeChapter: 0, + saveTimer: null, + bound: false, + scrollPct: 0, + buildVersion: 0, + jumpLockUntil: 0, + chromeHidden: false, + camStream: null, + camShot: null + }; + + var el = {}; + + function $(id) { + return document.getElementById(id); + } + + function on(node, eventName, handler) { + if (!node || typeof node.addEventListener !== "function") return false; + node.addEventListener(eventName, handler); + return true; + } + + function copyObj(src) { + var out = {}; + for (var k in src) { + if (Object.prototype.hasOwnProperty.call(src, k)) out[k] = src[k]; + } + return out; + } + + function setHidden(node, hidden) { + if (!node) return; + if (hidden) { + if (node.classList) node.classList.add("is-hidden"); + else node.className += " is-hidden"; + node.style.display = "none"; + } else { + if (node.classList) node.classList.remove("is-hidden"); + else node.className = String(node.className || "").replace(/\bis-hidden\b/g, ""); + node.style.display = ""; + } + } + + function loadPrefs() { + return Bridge.getLocalData(PREFS_KEY, null).then(function (raw) { + if (!raw || typeof raw !== "object") return copyObj(DEFAULT_PREFS); + return { + fontSize: Number(raw.fontSize) || DEFAULT_PREFS.fontSize, + lineHeight: String(raw.lineHeight || DEFAULT_PREFS.lineHeight), + fontFamily: raw.fontFamily || DEFAULT_PREFS.fontFamily, + theme: raw.theme || DEFAULT_PREFS.theme + }; + }); + } + + function savePrefs(prefs) { + state.prefs = prefs; + return Bridge.setLocalData(PREFS_KEY, prefs); + } + + function getProgress(bookId) { + return Bridge.getLocalData(PROGRESS_KEY, null).then(function (raw) { + if (!raw || raw.bookId !== bookId) return null; + return raw; + }); + } + + function saveProgress(partial) { + return getProgress(partial.bookId).then(function (prev) { + prev = prev || {}; + var readSet = {}; + var i; + var ids = prev.readChapterIds || []; + for (i = 0; i < ids.length; i++) readSet[ids[i]] = true; + ids = partial.readChapterIds || []; + for (i = 0; i < ids.length; i++) readSet[ids[i]] = true; + if (partial.chapterId) readSet[partial.chapterId] = true; + var keys = []; + for (var k in readSet) { + if (Object.prototype.hasOwnProperty.call(readSet, k)) keys.push(k); + } + var next = { + bookId: partial.bookId, + chapterId: partial.chapterId, + chapterIndex: partial.chapterIndex, + scrollPercent: partial.scrollPercent, + readChapterIds: keys, + updatedAt: Date.now() + }; + state.progress = next; + return Bridge.setLocalData(PROGRESS_KEY, next).then(function () { + return next; + }); + }); + } + + function loadBookmarks() { + return Bridge.getLocalData(BOOKMARKS_KEY, []).then(function (list) { + state.bookmarks = Array.isArray(list) ? list : []; + return state.bookmarks; + }); + } + + function saveBookmarks() { + return Bridge.setLocalData(BOOKMARKS_KEY, state.bookmarks || []); + } + + function loadNotes() { + return Bridge.getLocalData(NOTES_KEY, null).then(function (list) { + if (Array.isArray(list) && list.length) { + state.notes = list; + return state.notes; + } + // Fallback: filesystem backup (9.49+) + return Bridge.readUtf8File(NOTES_FILE).then(function (raw) { + if (!raw) { + state.notes = []; + return state.notes; + } + try { + var parsed = JSON.parse(raw); + state.notes = Array.isArray(parsed) ? parsed : []; + } catch (e) { + state.notes = []; + } + if (state.notes.length) { + return Bridge.setLocalData(NOTES_KEY, state.notes).then(function () { + return state.notes; + }); + } + return state.notes; + }); + }); + } + + function syncNotesToFs(list) { + if (!Bridge.canUseFileSystem(state.buildVersion)) { + return Promise.resolve(false); + } + return Bridge.writeUtf8File(NOTES_FILE, JSON.stringify(list || [])).then( + function () { + return true; + }, + function () { + return false; + } + ); + } + + function saveNotes() { + var list = state.notes || []; + return Bridge.setLocalData(NOTES_KEY, list).then(function (ok) { + return syncNotesToFs(list).then(function () { + return ok; + }); + }); + } + + function loadJournal() { + return Bridge.getLocalData(JOURNAL_KEY, null, true).then(function (list) { + if (Array.isArray(list) && list.length) { + state.journal = list; + return state.journal; + } + return Bridge.readUtf8File(JOURNAL_FILE).then(function (raw) { + if (!raw) { + state.journal = []; + return state.journal; + } + try { + var parsed = JSON.parse(raw); + state.journal = Array.isArray(parsed) ? parsed : []; + } catch (e) { + state.journal = []; + } + if (state.journal.length) { + return Bridge.setLocalData(JOURNAL_KEY, state.journal, true).then( + function () { + return state.journal; + } + ); + } + return state.journal; + }); + }); + } + + function saveJournal() { + var list = state.journal || []; + return Bridge.setLocalData(JOURNAL_KEY, list, true).then(function (ok) { + if (Bridge.canUseFileSystem(state.buildVersion)) { + return Bridge.writeUtf8File(JOURNAL_FILE, JSON.stringify(list)).then( + function () { + return ok; + }, + function () { + return ok; + } + ); + } + return ok; + }); + } + + function loadReadTime() { + return Bridge.getLocalData(TIME_KEY, null).then(function (raw) { + var today = todayKey(); + if (raw && typeof raw === "object") { + state.readTime = { + date: String(raw.date || ""), + seconds: Number(raw.seconds) || 0, + total: Number(raw.total) || 0 + }; + if (state.readTime.date !== today) { + state.readTime.date = today; + state.readTime.seconds = 0; + } + } else { + state.readTime = { date: today, seconds: 0, total: 0 }; + } + return state.readTime; + }); + } + + function saveReadTime() { + return Bridge.setLocalData(TIME_KEY, state.readTime || {}); + } + + function todayReadMinutes() { + return Math.max( + 0, + Math.floor(((state.readTime && state.readTime.seconds) || 0) / 60) + ); + } + + function totalReadMinutes() { + return Math.max( + 0, + Math.floor(((state.readTime && state.readTime.total) || 0) / 60) + ); + } + + function startReadTimer() { + stopReadTimer(); + state.readTick = setInterval(function () { + if ( + !el.reader || + (el.reader.classList && el.reader.classList.contains("is-hidden")) + ) { + return; + } + var today = todayKey(); + if (!state.readTime) state.readTime = { date: today, seconds: 0, total: 0 }; + if (state.readTime.date !== today) { + state.readTime.date = today; + state.readTime.seconds = 0; + } + state.readTime.seconds += 15; + state.readTime.total += 15; + saveReadTime(); + if (el.homeTime && !el.home.classList.contains("is-hidden")) { + updateHomeTimeLabel(); + } + }, 15000); + } + + function stopReadTimer() { + if (state.readTick) { + clearInterval(state.readTick); + state.readTick = null; + } + } + + function updateHomeTimeLabel() { + if (!el.homeTime) return; + var m = todayReadMinutes(); + var t = totalReadMinutes(); + if (m <= 0 && t <= 0) { + el.homeTime.textContent = ""; + return; + } + el.homeTime.textContent = + "今日已读约 " + Math.max(1, Math.round(m) || 1) + " 分钟 · 累计 " + Math.max(1, Math.round(t) || 1) + " 分钟"; + } + + function loadWorks() { + return Bridge.getLocalData(WORKS_KEY, []).then(function (list) { + state.works = Array.isArray(list) ? list : []; + return state.works; + }); + } + + function saveWorks() { + return Bridge.setLocalData(WORKS_KEY, (state.works || []).slice(0, 40)); + } + + function registerWork(item) { + if (!item || !item.path) return Promise.resolve(); + var list = state.works || []; + list = list.filter(function (w) { + return w.path !== item.path; + }); + list.unshift({ + id: item.id || "w_" + Date.now(), + title: item.title || "作品", + path: item.path, + kind: item.kind || "image", + updatedAt: Date.now() + }); + state.works = list.slice(0, 40); + return saveWorks(); + } + + function refreshWorksFromFs() { + if (!Bridge.canUseFileSystem(state.buildVersion)) { + return Promise.resolve(state.works || []); + } + return Bridge.readDirList("share").then(function (files) { + var known = {}; + var i; + for (i = 0; i < (state.works || []).length; i++) { + known[state.works[i].path] = state.works[i]; + } + for (i = 0; i < files.length; i++) { + var f = files[i]; + if (f.isDir) continue; + if (!known[f.path]) { + known[f.path] = { + id: "w_fs_" + i, + title: f.name || "生成图", + path: f.path, + kind: "image", + updatedAt: Date.now() + }; + } + } + var merged = []; + for (var k in known) { + if (Object.prototype.hasOwnProperty.call(known, k)) merged.push(known[k]); + } + merged.sort(function (a, b) { + return (b.updatedAt || 0) - (a.updatedAt || 0); + }); + state.works = merged.slice(0, 40); + return saveWorks().then(function () { + return state.works; + }); + }); + } + + function refreshStorageCap() { + if (!el.storageCap) return; + Promise.all([Bridge.getStorageInfo(), Bridge.getFileStorageInfo()]).then( + function (pair) { + var info = pair[0]; + var fileInfo = pair[1]; + var parts = []; + if (info) { + parts.push( + "缓存 " + + (Number(info.currentSize) || 0) + + "/" + + (Number(info.limitSize) || 10240) + + " KB" + ); + } else { + parts.push("缓存 · 需客户端 9.46+"); + } + parts.push("摘录 " + (state.notes || []).length + " 条"); + if (state.streak && state.streak.days) { + parts.push("连续打卡 " + state.streak.days + " 天"); + } + if (fileInfo) { + var usedMb = ((Number(fileInfo.usedBytes) || 0) / 1024 / 1024).toFixed(1); + var limitMb = ((Number(fileInfo.limitBytes) || 0) / 1024 / 1024).toFixed(0); + parts.push("文件 " + usedMb + "/" + limitMb + " MB"); + } + el.storageCap.textContent = parts.join(" · "); + } + ); + } + + function todayKey() { + var d = new Date(); + var m = d.getMonth() + 1; + var day = d.getDate(); + return ( + d.getFullYear() + + "-" + + (m < 10 ? "0" + m : m) + + "-" + + (day < 10 ? "0" + day : day) + ); + } + + function yesterdayKey() { + var d = new Date(Date.now() - 86400000); + var m = d.getMonth() + 1; + var day = d.getDate(); + return ( + d.getFullYear() + + "-" + + (m < 10 ? "0" + m : m) + + "-" + + (day < 10 ? "0" + day : day) + ); + } + + function loadStreak() { + return Bridge.getLocalData(STREAK_KEY, null).then(function (raw) { + if (raw && typeof raw === "object") { + state.streak = { + days: Number(raw.days) || 0, + lastDate: String(raw.lastDate || "") + }; + } else { + state.streak = { days: 0, lastDate: "" }; + } + return state.streak; + }); + } + + function bumpStreak() { + var today = todayKey(); + var s = state.streak || { days: 0, lastDate: "" }; + if (s.lastDate === today) { + return Promise.resolve(s); + } + if (s.lastDate === yesterdayKey()) { + s.days = (Number(s.days) || 0) + 1; + } else { + s.days = 1; + } + s.lastDate = today; + state.streak = s; + return Bridge.setLocalData(STREAK_KEY, s).then(function () { + return s; + }); + } + + function formatAgo(ts) { + var diff = Math.max(0, Date.now() - ts); + var m = Math.floor(diff / 60000); + if (m < 1) return "刚刚"; + if (m < 60) return m + " 分钟前"; + var h = Math.floor(m / 60); + if (h < 24) return h + " 小时前"; + return Math.floor(h / 24) + " 天前"; + } + + function coverPaletteFromSeed(seed) { + var palettes = [ + { from: "#1a0b2e", via: "#6d28d9", to: "#db2777", glow: "rgba(219,39,119,.45)", ink: "#fce7f3" }, + { from: "#0b1226", via: "#1d4ed8", to: "#06b6d4", glow: "rgba(6,182,212,.4)", ink: "#e0f2fe" }, + { from: "#1c0a12", via: "#be185d", to: "#f59e0b", glow: "rgba(245,158,11,.4)", ink: "#fff7ed" }, + { from: "#0c1424", via: "#4338ca", to: "#818cf8", glow: "rgba(129,140,248,.42)", ink: "#eef2ff" } + ]; + var h = 2166136261; + var s = seed || "book"; + for (var i = 0; i < s.length; i++) { + h ^= s.charCodeAt(i); + h = (h * 16777619) | 0; + } + return palettes[Math.abs(h) % palettes.length]; + } + + function showBootError(msg) { + setHidden(el.boot, false); + setHidden(el.home, true); + setHidden(el.reader, true); + if (el.bootText) el.bootText.textContent = msg || "打开失败"; + } + + function showView(name) { + setHidden(el.boot, true); + setHidden(el.home, name !== "home"); + setHidden(el.reader, name !== "reader"); + if (name === "home") { + try { + window.scrollTo(0, 0); + } catch (e) {} + } + } + + function getBookData() { + if (typeof BOOK_DATA !== "undefined" && BOOK_DATA && BOOK_DATA.chapters) return BOOK_DATA; + if (window.BOOK_DATA && window.BOOK_DATA.chapters) return window.BOOK_DATA; + return null; + } + + function escapeText(s) { + return String(s) + .replace(/&/g, "&") + .replace(//g, ">"); + } + + function chapterMinutes(content) { + var n = (String(content || "").match(/[\u4e00-\u9fff]/g) || []).length; + return Math.max(1, Math.round(n / 400)); + } + + function renderHome() { + var book = state.book; + getProgress(book.id).then(function (progress) { + state.progress = progress; + var palette = coverPaletteFromSeed(book.id + "|" + book.title); + if (el.coverGlow) el.coverGlow.style.background = palette.glow; + if (el.cover) { + el.cover.style.background = + "linear-gradient(155deg, " + palette.from + " 0%, " + palette.via + " 42%, " + palette.to + " 100%)"; + } + if (el.coverEmoji) el.coverEmoji.textContent = book.cover_emoji || "🌏"; + if (el.coverTitle) { + el.coverTitle.textContent = book.title; + el.coverTitle.style.color = palette.ink; + } + if (el.homeTitle) el.homeTitle.textContent = book.title; + var tease = (book.subtitle || book.description || "").trim(); + if (tease.length > 48) tease = tease.slice(0, 48) + "…"; + if (el.homeTease) el.homeTease.textContent = tease || "翻开第一页,故事才刚刚开始。"; + if (el.homeAuthor) el.homeAuthor.textContent = book.author || ""; + if (progress && progress.chapterId) { + if (el.btnStart) el.btnStart.textContent = "继续阅读"; + if (el.homeHint) { + var chTitle = ""; + var chapters = book.chapters || []; + var ci = + typeof progress.chapterIndex === "number" + ? progress.chapterIndex + : -1; + if (ci < 0) { + for (var hi = 0; hi < chapters.length; hi++) { + if (chapters[hi].id === progress.chapterId) { + ci = hi; + break; + } + } + } + if (ci >= 0 && chapters[ci]) chTitle = chapters[ci].title || ""; + if (chTitle.length > 16) chTitle = chTitle.slice(0, 16) + "…"; + var pct = Math.max(0, Math.min(100, Math.round(Number(progress.scrollPercent) || 0))); + var ago = progress.updatedAt ? formatAgo(progress.updatedAt) : ""; + var parts = []; + if (chTitle) parts.push("第" + (ci + 1) + "章「" + chTitle + "」"); + if (pct > 0) parts.push(pct + "%"); + if (ago) parts.push(ago); + el.homeHint.textContent = + parts.length > 0 ? "上次 · " + parts.join(" · ") : "接着上次的地方"; + } + } else { + if (el.btnStart) el.btnStart.textContent = "开始阅读"; + if (el.homeHint) el.homeHint.textContent = "点一下,直接进入正文"; + } + updateHomeTimeLabel(); + showView("home"); + }); + } + + function applyReaderChrome() { + var prefs = state.prefs; + var font = FONTS[0]; + var i; + for (i = 0; i < FONTS.length; i++) { + if (FONTS[i].value === prefs.fontFamily) font = FONTS[i]; + } + if (el.reader) el.reader.className = "view reader theme-" + prefs.theme; + if (el.tocDrawer) { + el.tocDrawer.className = "drawer theme-" + prefs.theme; + } + if (el.settingsSheet) { + el.settingsSheet.className = "rs-sheet theme-" + prefs.theme; + } + if (el.paper) { + el.paper.style.fontSize = prefs.fontSize + "px"; + el.paper.style.lineHeight = prefs.lineHeight; + el.paper.style.fontFamily = font.css; + } + } + + function pad2(n) { + return n < 10 ? "0" + n : String(n); + } + + function renderToc(filter) { + if (!el.tocList) return; + var q = String(filter || "").trim().toLowerCase(); + var html = []; + if (state.drawerTab === "works") { + var works = state.works || []; + for (var w = 0; w < works.length; w++) { + var work = works[w]; + if (q && String(work.title || "").toLowerCase().indexOf(q) === -1) continue; + html.push( + '
' + + escapeText(work.title || "作品") + + '' + + escapeText(work.kind || "image") + + " · " + + formatAgo(work.updatedAt || Date.now()) + + '
' + + '' + + '' + + '
' + ); + } + el.tocList.innerHTML = + html.join("") || + '

还没有作品。保存金句图 / 打卡后会出现在这里(需 9.49+ 文件能力)。

'; + updateDrawerMeta(); + return; + } + if (state.drawerTab === "journal") { + var journals = state.journal || []; + for (var j = 0; j < journals.length; j++) { + var je = journals[j]; + if (q && String(je.text || "").toLowerCase().indexOf(q) === -1) continue; + html.push( + '
' + + escapeText(je.date || "日记") + + (je.chapterTitle ? " · " + escapeText(je.chapterTitle) : "") + + '' + + escapeText((je.text || "").slice(0, 80)) + + (je.text && je.text.length > 80 ? "…" : "") + + '
' + + '' + + '
' + ); + } + el.tocList.innerHTML = + html.join("") || + '

还没有日记。在设置里点「写阅读日记」。

'; + updateDrawerMeta(); + return; + } + if (state.drawerTab === "notes") { + var notes = state.notes || []; + for (var n = 0; n < notes.length; n++) { + var note = notes[n]; + if ( + q && + String(note.title || "").toLowerCase().indexOf(q) === -1 && + String(note.text || "").toLowerCase().indexOf(q) === -1 + ) { + continue; + } + html.push( + '
' + + escapeText(note.title || "摘录") + + '' + + escapeText((note.text || "").slice(0, 72)) + + (note.text && note.text.length > 72 ? "…" : "") + + '
' + + '' + + '' + + (Bridge.canPostComment(state.buildVersion) + ? '' + : "") + + '
' + ); + } + el.tocList.innerHTML = + html.join("") || + '

还没有摘录。在设置里点「摘录本章」,可发小红书笔记。

'; + updateDrawerMeta(); + return; + } + if (state.drawerTab === "bookmarks") { + var marks = state.bookmarks || []; + for (var b = 0; b < marks.length; b++) { + var m = marks[b]; + if (q && String(m.title || "").toLowerCase().indexOf(q) === -1) continue; + html.push( + '" + ); + } + el.tocList.innerHTML = + html.join("") || '

还没有收藏,在设置里点「收藏本章」

'; + updateDrawerMeta(); + return; + } + var chapters = state.book.chapters || []; + for (var i = 0; i < chapters.length; i++) { + var ch = chapters[i]; + if (q && ch.title.toLowerCase().indexOf(q) === -1) continue; + var active = i === state.activeChapter ? " active" : ""; + var emoji = CHAPTER_EMOJIS[i % CHAPTER_EMOJIS.length]; + var starred = isBookmarked(ch.id) ? " ★" : ""; + html.push( + '" + ); + } + el.tocList.innerHTML = html.join("") || '

没有匹配的章节

'; + updateDrawerMeta(); + } + + function isBookmarked(chapterId) { + var list = state.bookmarks || []; + for (var i = 0; i < list.length; i++) { + if (list[i].chapterId === chapterId) return true; + } + return false; + } + + function toggleBookmark() { + var ch = (state.book.chapters || [])[state.activeChapter]; + if (!ch) return; + var list = state.bookmarks || []; + var next = []; + var found = false; + for (var i = 0; i < list.length; i++) { + if (list[i].chapterId === ch.id) { + found = true; + } else { + next.push(list[i]); + } + } + if (!found) { + next.unshift({ + chapterId: ch.id, + chapterIndex: state.activeChapter, + title: ch.title, + updatedAt: Date.now() + }); + } + state.bookmarks = next; + saveBookmarks().then(function () { + if (el.btnBookmark) { + el.btnBookmark.textContent = found ? "收藏本章" : "取消收藏"; + } + alert(found ? "已取消收藏" : "已收藏本章"); + }); + } + + function setDrawerTab(tab) { + if (tab === "bookmarks") state.drawerTab = "bookmarks"; + else if (tab === "notes") state.drawerTab = "notes"; + else if (tab === "journal") state.drawerTab = "journal"; + else if (tab === "works") state.drawerTab = "works"; + else state.drawerTab = "chapters"; + if (el.tabChapters) { + el.tabChapters.className = "drawer-tab" + (state.drawerTab === "chapters" ? " on" : ""); + } + if (el.tabBookmarks) { + el.tabBookmarks.className = "drawer-tab" + (state.drawerTab === "bookmarks" ? " on" : ""); + } + if (el.tabNotes) { + el.tabNotes.className = "drawer-tab" + (state.drawerTab === "notes" ? " on" : ""); + } + if (el.tabJournal) { + el.tabJournal.className = "drawer-tab" + (state.drawerTab === "journal" ? " on" : ""); + } + if (el.tabWorks) { + el.tabWorks.className = "drawer-tab" + (state.drawerTab === "works" ? " on" : ""); + } + if (el.tocFilter) { + el.tocFilter.placeholder = + state.drawerTab === "notes" + ? "搜索摘录" + : state.drawerTab === "bookmarks" + ? "搜索收藏" + : state.drawerTab === "journal" + ? "搜索日记" + : state.drawerTab === "works" + ? "搜索作品" + : "搜索章节"; + } + if (state.drawerTab === "works") { + refreshWorksFromFs().then(function () { + renderToc(el.tocFilter ? el.tocFilter.value : ""); + }); + return; + } + renderToc(el.tocFilter ? el.tocFilter.value : ""); + } + + function updateDrawerMeta() { + var chapters = (state.book && state.book.chapters) || []; + var total = chapters.length || 1; + var pct = Math.max( + state.scrollPct || 0, + Math.round(((state.activeChapter + 1) / total) * 100) + ); + if (el.drawerMeter) el.drawerMeter.style.width = pct + "%"; + if (el.drawerStatLeft) el.drawerStatLeft.textContent = "进度 " + pct + "%"; + if (el.drawerStatRight) { + el.drawerStatRight.textContent = + state.activeChapter + 1 + " / " + chapters.length + " 章"; + } + } + + function remainingMinutes() { + var chapters = (state.book && state.book.chapters) || []; + var sum = 0; + for (var i = state.activeChapter; i < chapters.length; i++) { + sum += chapterMinutes(chapters[i].content); + } + return Math.max(1, sum); + } + + function updateProgressUI() { + if (!state.book || !el.paper) return; + var locked = Date.now() < (state.jumpLockUntil || 0); + var chapters = state.book.chapters || []; + var doc = document.documentElement; + var scrollY = window.pageYOffset || doc.scrollTop || 0; + var max = Math.max(1, (doc.scrollHeight || 1) - (window.innerHeight || 1)); + var pct = Math.min(100, Math.round((scrollY / max) * 100)); + state.scrollPct = pct; + if (el.topbarBar) el.topbarBar.style.width = pct + "%"; + + var blocks = el.paper.querySelectorAll(".chapter-block"); + var active = state.activeChapter || 0; + var topbarH = topbarOffset(); + if (!locked) { + active = 0; + for (var i = 0; i < blocks.length; i++) { + var rect = blocks[i].getBoundingClientRect(); + if (rect.top <= topbarH + 24) active = i; + } + state.activeChapter = active; + } + var ch = chapters[active]; + if (ch) { + var emoji = CHAPTER_EMOJIS[active % CHAPTER_EMOJIS.length]; + if (el.chapterTitle) el.chapterTitle.textContent = emoji + " " + ch.title; + if (el.progressLabel) { + el.progressLabel.textContent = + active + 1 + "/" + chapters.length + " · 约剩 " + remainingMinutes() + " 分钟"; + } + updateDrawerMeta(); + if (!locked) { + if (state.saveTimer) clearTimeout(state.saveTimer); + state.saveTimer = setTimeout(function () { + saveProgress({ + bookId: state.book.id, + chapterId: ch.id, + chapterIndex: active, + scrollPercent: pct, + readChapterIds: [ch.id] + }); + }, 280); + } + } + setHidden(el.btnTop, scrollY < 420); + } + + function topbarOffset() { + var h = (el.topbar && el.topbar.offsetHeight) || 0; + if (h > 0) return h; + try { + var pad = parseFloat( + window.getComputedStyle(document.documentElement).getPropertyValue("--app-pad-top") + ); + if (!isNaN(pad) && pad > 0) return pad + 44; + } catch (e) {} + return 96; + } + + function scrollToY(y) { + try { + if (typeof window.scrollTo === "function") { + window.scrollTo(0, Math.max(0, y)); + } else { + document.documentElement.scrollTop = Math.max(0, y); + document.body.scrollTop = Math.max(0, y); + } + } catch (e) {} + } + + function jumpToChapter(idx, opts) { + opts = opts || {}; + var chapters = (state.book && state.book.chapters) || []; + if (idx < 0 || idx >= chapters.length) return; + var ch = chapters[idx]; + var target = $("ch-" + ch.id); + if (!target) return; + state.jumpLockUntil = Date.now() + (opts.lockMs || 520); + state.activeChapter = idx; + var rect = target.getBoundingClientRect(); + var current = window.pageYOffset || document.documentElement.scrollTop || 0; + var y = Math.max(0, current + rect.top - topbarOffset()); + scrollToY(y); + if (opts.update !== false) { + setTimeout(function () { + updateProgressUI(); + }, 60); + } + } + + function restoreScrollPercent(pct) { + pct = Math.max(0, Math.min(100, Number(pct) || 0)); + if (pct <= 0) return; + state.jumpLockUntil = Date.now() + 700; + setTimeout(function () { + try { + var doc = document.documentElement; + var max = Math.max(0, (doc.scrollHeight || 0) - (window.innerHeight || 0)); + if (max > 0) scrollToY(Math.round(max * (pct / 100))); + } catch (e) {} + setTimeout(function () { + updateProgressUI(); + }, 80); + }, 40); + } + + function openToc(open) { + setHidden(el.tocMask, !open); + if (open) { + applyReaderChrome(); + renderToc(el.tocFilter ? el.tocFilter.value : ""); + } + } + + function openSettings(open) { + setHidden(el.settingsMask, !open); + if (open) { + applyReaderChrome(); + refreshStorageCap(); + } + } + + function buildSeg(container, items, current, onPick) { + if (!container) return; + container.innerHTML = ""; + for (var i = 0; i < items.length; i++) { + (function (item) { + var btn = document.createElement("button"); + btn.type = "button"; + btn.textContent = item.label; + if (item.value === current) btn.className = "on"; + on(btn, "click", function () { + onPick(item.value); + }); + container.appendChild(btn); + })(items[i]); + } + } + + function refreshPrefSegs() { + buildSeg(el.prefSize, FONT_SIZES, state.prefs.fontSize, function (v) { + var next = copyObj(state.prefs); + next.fontSize = v; + savePrefs(next); + applyReaderChrome(); + refreshPrefSegs(); + }); + buildSeg(el.prefLh, LINE_HEIGHTS, state.prefs.lineHeight, function (v) { + var next = copyObj(state.prefs); + next.lineHeight = v; + savePrefs(next); + applyReaderChrome(); + refreshPrefSegs(); + }); + buildSeg(el.prefFont, FONTS, state.prefs.fontFamily, function (v) { + var next = copyObj(state.prefs); + next.fontFamily = v; + savePrefs(next); + applyReaderChrome(); + refreshPrefSegs(); + }); + buildSeg(el.prefTheme, THEMES, state.prefs.theme, function (v) { + var next = copyObj(state.prefs); + next.theme = v; + savePrefs(next); + applyReaderChrome(); + refreshPrefSegs(); + }); + } + + function renderReader(jumpToProgress) { + var book = state.book; + var chapters = book.chapters || []; + applyReaderChrome(); + if (!window.MarkdownLite || typeof window.MarkdownLite.markdownToHtml !== "function") { + showBootError("渲染模块未加载"); + return; + } + + var totalMins = Math.max(1, Math.round((book.word_count || 0) / 400)); + if (!book.word_count) { + totalMins = 0; + for (var t = 0; t < chapters.length; t++) totalMins += chapterMinutes(chapters[t].content); + totalMins = Math.max(1, totalMins); + } + + var html = []; + html.push( + '
' + + '' + + escapeText(book.cover_emoji || "🌏") + + "" + + '' + + escapeText(book.title || "") + + "" + + '' + + escapeText(book.subtitle || "") + + "" + + '
' + + '
' + + chapters.length + + '章节
' + + '
' + + Math.max(1, Math.round((book.word_count || 5000) / 1000)) + + 'k字数
' + + '
' + + totalMins + + '分钟
' + + '
' + + remainingMinutes() + + '余下
' + + "
" + + '点左右翻页 · 点中间显隐顶栏' + + "
" + ); + + for (var i = 0; i < chapters.length; i++) { + var ch = chapters[i]; + var mins = chapterMinutes(ch.content); + var emoji = CHAPTER_EMOJIS[i % CHAPTER_EMOJIS.length]; + var next = chapters[i + 1]; + var nextEmoji = CHAPTER_EMOJIS[(i + 1) % CHAPTER_EMOJIS.length]; + html.push('
'); + if (i > 0) { + html.push( + '
· · ·
' + ); + } + html.push( + '
' + + '
' + + '' + + emoji + + "" + + '' + + pad2(i + 1) + + '/' + + chapters.length + + "" + + "
" + + '' + + escapeText(ch.title) + + "" + + '约 ' + + mins + + " 分钟 · 第 " + + (i + 1) + + " 章" + + "
" + + '
' + + window.MarkdownLite.markdownToHtml(ch.content, { + theme: state.prefs.theme, + dropCap: true + }) + + "
" + ); + if (next) { + html.push( + '" + ); + } + html.push("
"); + } + + html.push( + '
' + + '✨' + + '全书读完' + + '数字游民 · 一人公司 · 慢慢翻完也很棒' + + '
' + + '' + + '' + + '' + + "
" + ); + + if (el.paper) el.paper.innerHTML = html.join(""); + renderToc(""); + showView("reader"); + setTimeout(function () { + if (jumpToProgress && state.progress && state.progress.chapterId) { + var idx = findChapterIndex(state.progress.chapterId); + if (idx < 0 && typeof state.progress.chapterIndex === "number") { + idx = state.progress.chapterIndex; + } + if (idx < 0) idx = 0; + state.activeChapter = idx; + var pct = Number(state.progress.scrollPercent) || 0; + if (pct > 2) { + restoreScrollPercent(pct); + } else { + jumpToChapter(idx, { lockMs: 600 }); + } + } else { + scrollToY(0); + state.activeChapter = 0; + updateProgressUI(); + } + }, 30); + } + + function goRead() { + getProgress(state.book.id).then(function (progress) { + state.progress = progress; + if (progress) { + var idx = + typeof progress.chapterIndex === "number" + ? progress.chapterIndex + : findChapterIndex(progress.chapterId); + if (idx >= 0) state.activeChapter = idx; + } + renderReader(true); + refreshPrefSegs(); + syncActionLabels(); + startReadTimer(); + }); + } + + function goHome() { + stopReadTimer(); + saveReadTime(); + openToc(false); + openSettings(false); + closeCam(); + closeJournalSheet(); + renderHome(); + } + + function syncActionLabels() { + var ch = (state.book.chapters || [])[state.activeChapter]; + if (el.btnBookmark) { + el.btnBookmark.textContent = + ch && isBookmarked(ch.id) ? "取消收藏" : "收藏本章"; + } + var showComment = Bridge.canPostComment(state.buildVersion); + if (el.btnComment) setHidden(el.btnComment, !showComment); + if (el.btnCommentText) setHidden(el.btnCommentText, !showComment); + } + + function chapterExcerpt(ch, maxLen) { + maxLen = maxLen || 100; + var raw = String((ch && ch.content) || "") + .replace(/```[\s\S]*?```/g, " ") + .replace(/`[^`]+`/g, " ") + .replace(/!\[[^\]]*\]\([^)]*\)/g, " ") + .replace(/\[[^\]]*\]\([^)]*\)/g, " ") + .replace(/[#>*_\-~|]/g, " ") + .replace(/\s+/g, " ") + .trim(); + if (raw.length <= maxLen) return raw; + return raw.slice(0, maxLen) + "…"; + } + + function makeQuoteCard() { + var book = state.book; + var ch = (book.chapters || [])[state.activeChapter]; + return makeTextCard({ + brand: "异度世界", + title: book.title, + subtitle: ch ? ch.title : book.subtitle || "", + body: chapterExcerpt(ch, 110), + foot: "异度星球 · 离线阅读" + }); + } + + function makeTextCard(opts) { + var canvas = document.createElement("canvas"); + canvas.width = 1080; + canvas.height = 1440; + var ctx = canvas.getContext("2d"); + if (!ctx) return null; + var g = ctx.createLinearGradient(0, 0, 1080, 1440); + g.addColorStop(0, "#1a0b2e"); + g.addColorStop(0.45, "#6d28d9"); + g.addColorStop(1, "#db2777"); + ctx.fillStyle = g; + ctx.fillRect(0, 0, 1080, 1440); + ctx.fillStyle = "rgba(255,255,255,0.12)"; + ctx.beginPath(); + ctx.arc(900, 180, 140, 0, Math.PI * 2); + ctx.fill(); + ctx.fillStyle = "#fce7f3"; + ctx.font = "700 56px sans-serif"; + ctx.fillText(opts.brand || "异度世界", 96, 220); + ctx.font = "600 44px sans-serif"; + wrapFillText(ctx, opts.title || "", 96, 320, 880, 58); + if (opts.subtitle) { + ctx.fillStyle = "rgba(252,231,243,0.88)"; + ctx.font = "400 34px sans-serif"; + wrapFillText(ctx, opts.subtitle, 96, 480, 880, 48); + } + if (opts.body) { + ctx.fillStyle = "rgba(255,255,255,0.78)"; + ctx.font = "400 32px sans-serif"; + wrapFillText(ctx, "「" + opts.body + "」", 96, 640, 880, 46); + } + if (opts.stats) { + ctx.fillStyle = "rgba(255,255,255,0.9)"; + ctx.font = "600 40px sans-serif"; + wrapFillText(ctx, opts.stats, 96, 980, 880, 52); + } + ctx.fillStyle = "rgba(255,255,255,0.55)"; + ctx.font = "400 28px sans-serif"; + ctx.fillText(opts.foot || "异度星球 · 离线阅读", 96, 1320); + return canvas.toDataURL("image/png"); + } + + function makeCheckinCard() { + var book = state.book; + var chapters = book.chapters || []; + var ch = chapters[state.activeChapter]; + var pct = state.scrollPct || 0; + var readN = ((state.progress && state.progress.readChapterIds) || []).length; + if (!readN) readN = state.activeChapter + 1; + var streakDays = (state.streak && state.streak.days) || 0; + var stats = + "进度 " + + pct + + "% · 已读 " + + readN + + "/" + + chapters.length + + " 章 · 约剩 " + + remainingMinutes() + + " 分钟"; + if (streakDays > 0) { + stats += " · 连续 " + streakDays + " 天"; + } + var mins = todayReadMinutes(); + if (mins > 0) { + stats += " · 今日 " + mins + " 分钟"; + } + return makeTextCard({ + brand: "阅读打卡", + title: book.title, + subtitle: ch ? "正在读 · " + ch.title : book.subtitle || "", + body: chapterExcerpt(ch, 90), + stats: stats, + foot: "异度星球 · 小红书小工具" + }); + } + + function makeFinishCard() { + var book = state.book; + var chapters = book.chapters || []; + var totalMins = 0; + for (var i = 0; i < chapters.length; i++) { + totalMins += chapterMinutes(chapters[i].content); + } + return makeTextCard({ + brand: "读完证书", + title: book.title, + subtitle: "共 " + chapters.length + " 章 · 约 " + totalMins + " 分钟", + body: "我在异度星球读完了这本书", + stats: "✨ 全书通关 · " + todayKey(), + foot: "异度星球 · 小红书小工具" + }); + } + + function makeCoverCard() { + var book = state.book; + return makeTextCard({ + brand: "异度世界", + title: book.title, + subtitle: book.subtitle || "", + body: (book.description || "").slice(0, 80) || chapterExcerpt(book.chapters && book.chapters[0], 80), + foot: "异度星球 · 离线阅读" + }); + } + + function requireMiniTool(actionLabel) { + if (!Bridge.getMiniTool()) { + alert("请在小红书 App 内使用「" + (actionLabel || "此功能") + "」"); + return false; + } + return true; + } + + function dataUrlToPath(dataUrl, persistRel) { + if (persistRel && Bridge.canUseFileSystem(state.buildVersion)) { + return Bridge.persistImage(dataUrl, persistRel).then(function (path) { + registerWork({ + title: persistRel.indexOf("selfie") >= 0 ? "自拍打卡" : "生成图", + path: path, + kind: "image" + }); + return path; + }); + } + return Bridge.writeTempFile(dataUrl).catch(function () { + return dataUrl; + }); + } + + function postImagesNote(title, content, dataUrls) { + if (!requireMiniTool("发笔记")) return Promise.resolve(); + var urls = dataUrls || []; + var chain = Promise.resolve([]); + var i; + for (i = 0; i < urls.length; i++) { + (function (dataUrl, index) { + chain = chain.then(function (acc) { + return dataUrlToPath(dataUrl, "share/img_" + index + ".png").then( + function (path) { + acc.push({ url: path }); + return acc; + } + ); + }); + })(urls[i], i); + } + return chain + .then(function (images) { + if (!images.length) throw { errMsg: "无图片可发布" }; + return Bridge.postNote({ + title: String(title || "").slice(0, 20), + content: String(content || "").slice(0, 1000), + pageType: "photo_publish", + mediaInfo: { image_resources: images.slice(0, 18) } + }); + }) + .catch(function (err) { + alert((err && err.errMsg) || "发笔记失败"); + }); + } + + function postCheckinNote() { + openSettings(false); + var book = state.book; + var ch = (book.chapters || [])[state.activeChapter]; + bumpStreak().then(function (streak) { + var card = makeCheckinCard(); + if (!card) { + alert("无法生成打卡图"); + return; + } + var title = "今日阅读打卡"; + var content = + "📖 阅读打卡 · 《" + + book.title + + "》\n" + + (ch ? "章节:" + ch.title + "\n" : "") + + "进度:" + + (state.scrollPct || 0) + + "% · 约剩 " + + remainingMinutes() + + " 分钟\n" + + (streak && streak.days ? "连续打卡:" + streak.days + " 天\n" : "") + + (todayReadMinutes() > 0 + ? "今日已读约:" + todayReadMinutes() + " 分钟\n" + : "") + + "\n#阅读打卡 #数字游民 #一人公司"; + refreshStorageCap(); + postImagesNote(title, content, [card]); + }); + } + + function postFinishNote() { + var book = state.book; + var card = makeFinishCard(); + if (!card) { + alert("无法生成证书"); + return; + } + bumpStreak().then(function (streak) { + var content = + "🎓 我读完了《" + + book.title + + "》!\n共 " + + (book.chapters || []).length + + " 章\n" + + (streak && streak.days ? "连续阅读 " + streak.days + " 天\n" : "") + + "\n来自小工具「异度星球」\n#读完打卡 #数字游民 #一人公司"; + postImagesNote("读完证书", content, [card]); + }); + } + + function openPhotoPicker() { + if (!requireMiniTool("配图发笔记")) return; + openSettings(false); + if (!el.inputPhoto) { + alert("选图组件未就绪"); + return; + } + try { + el.inputPhoto.value = ""; + el.inputPhoto.click(); + } catch (e) { + alert("无法打开相册,请重试"); + } + } + + function onPhotoPicked(ev) { + var input = ev && ev.target; + var file = input && input.files && input.files[0]; + if (!file) return; + Bridge.blobToDataUrl(file) + .then(function (dataUrl) { + var quote = makeQuoteCard(); + var imgs = [dataUrl]; + if (quote) imgs.push(quote); + var book = state.book; + var ch = (book.chapters || [])[state.activeChapter]; + var content = + "配图分享 · 《" + + book.title + + "》" + + (ch ? " · " + ch.title : "") + + "\n\n来自小工具「异度星球」\n#数字游民 #一人公司"; + return postImagesNote((book.title || "异度星球").slice(0, 20), content, imgs); + }) + .catch(function (err) { + alert((err && err.errMsg) || "读取图片失败"); + }); + } + + function openVideoPicker() { + if (!requireMiniTool("选视频发笔记")) return; + openSettings(false); + if (!el.inputVideo) { + alert("选视频组件未就绪"); + return; + } + try { + el.inputVideo.value = ""; + el.inputVideo.click(); + } catch (e) { + alert("无法打开相册,请重试"); + } + } + + function onVideoPicked(ev) { + var input = ev && ev.target; + var file = input && input.files && input.files[0]; + if (!file) return; + if (!requireMiniTool("选视频发笔记")) return; + var book = state.book; + var ch = (book.chapters || [])[state.activeChapter]; + var cover = makeQuoteCard(); + Bridge.blobToDataUrl(file) + .then(function (videoDataUrl) { + return Bridge.writeTempFile(videoDataUrl).then(function (videoPath) { + var coverP = cover + ? Bridge.writeTempFile(cover).catch(function () { + return cover; + }) + : Promise.resolve(""); + return coverP.then(function (coverPath) { + return Bridge.postVideoNote({ + title: (book.title || "异度星球").slice(0, 20), + content: + "视频分享 · 《" + + book.title + + "》" + + (ch ? " · " + ch.title : "") + + "\n\n来自小工具「异度星球」\n#数字游民 #一人公司", + videoPath: videoPath, + coverPath: coverPath || undefined + }); + }); + }); + }) + .catch(function (err) { + alert((err && err.errMsg) || "视频发笔记失败"); + }); + } + + function stopCam() { + if (state.camStream && state.camStream.getTracks) { + var tracks = state.camStream.getTracks(); + for (var i = 0; i < tracks.length; i++) { + try { + tracks[i].stop(); + } catch (e) {} + } + } + state.camStream = null; + if (el.camVideo) { + try { + el.camVideo.srcObject = null; + } catch (e2) {} + } + } + + function openCam() { + if (!requireMiniTool("自拍打卡")) return; + openSettings(false); + state.camShot = null; + setHidden(el.camMask, false); + setHidden(el.camVideo, false); + setHidden(el.camPreview, true); + if (el.camTip) el.camTip.textContent = "正在打开摄像头…"; + var nav = navigator; + var getMedia = + (nav.mediaDevices && nav.mediaDevices.getUserMedia + ? function (c) { + return nav.mediaDevices.getUserMedia(c); + } + : null) || + nav.getUserMedia || + nav.webkitGetUserMedia || + nav.mozGetUserMedia; + if (!getMedia) { + if (el.camTip) el.camTip.textContent = "当前环境不支持摄像头"; + return; + } + var constraints = { video: { facingMode: "user" }, audio: false }; + var p; + if (nav.mediaDevices && nav.mediaDevices.getUserMedia) { + p = nav.mediaDevices.getUserMedia(constraints); + } else { + p = new Promise(function (resolve, reject) { + getMedia.call(nav, constraints, resolve, reject); + }); + } + p.then(function (stream) { + state.camStream = stream; + if (el.camVideo) { + el.camVideo.srcObject = stream; + var playP = el.camVideo.play && el.camVideo.play(); + if (playP && playP.catch) playP.catch(function () {}); + } + if (el.camTip) el.camTip.textContent = "对准画面后点「拍照」"; + }).catch(function () { + if (el.camTip) el.camTip.textContent = "摄像头授权失败,请在系统弹窗中允许"; + }); + } + + function closeCam() { + stopCam(); + state.camShot = null; + setHidden(el.camMask, true); + } + + function snapCam() { + if (!el.camVideo || !el.camCanvas) return; + var video = el.camVideo; + var w = video.videoWidth || 720; + var h = video.videoHeight || 960; + if (!w || !h) { + if (el.camTip) el.camTip.textContent = "画面未就绪,请稍候再拍"; + return; + } + var canvas = el.camCanvas; + canvas.width = 1080; + canvas.height = 1440; + var ctx = canvas.getContext("2d"); + if (!ctx) return; + var scale = Math.max(1080 / w, 1440 / h); + var dw = w * scale; + var dh = h * scale; + var dx = (1080 - dw) / 2; + var dy = (1440 - dh) / 2; + ctx.drawImage(video, dx, dy, dw, dh); + var g = ctx.createLinearGradient(0, 1100, 0, 1440); + g.addColorStop(0, "rgba(0,0,0,0)"); + g.addColorStop(1, "rgba(26,11,46,0.92)"); + ctx.fillStyle = g; + ctx.fillRect(0, 1000, 1080, 440); + ctx.fillStyle = "#fce7f3"; + ctx.font = "700 48px sans-serif"; + ctx.fillText("自拍打卡", 72, 1180); + ctx.font = "600 36px sans-serif"; + wrapFillText(ctx, state.book.title || "", 72, 1240, 920, 44); + var ch = (state.book.chapters || [])[state.activeChapter]; + ctx.fillStyle = "rgba(255,255,255,0.8)"; + ctx.font = "400 28px sans-serif"; + ctx.fillText( + (ch ? ch.title + " · " : "") + + "进度 " + + (state.scrollPct || 0) + + "%" + + (state.streak && state.streak.days ? " · 连续" + state.streak.days + "天" : ""), + 72, + 1360 + ); + state.camShot = canvas.toDataURL("image/jpeg", 0.92); + if (el.camPreview) { + el.camPreview.src = state.camShot; + setHidden(el.camPreview, false); + } + setHidden(el.camVideo, true); + stopCam(); + if (el.camTip) el.camTip.textContent = "已拍照 · 可发笔记或存相册"; + } + + function postCamShot() { + if (!state.camShot) { + alert("请先拍照"); + return; + } + bumpStreak().then(function (streak) { + var book = state.book; + var ch = (book.chapters || [])[state.activeChapter]; + var content = + "📷 自拍打卡 · 《" + + book.title + + "》\n" + + (ch ? "章节:" + ch.title + "\n" : "") + + "进度:" + + (state.scrollPct || 0) + + "%\n" + + (streak && streak.days ? "连续打卡:" + streak.days + " 天\n" : "") + + "\n#自拍打卡 #数字游民 #一人公司打卡"; + postImagesNote("自拍打卡", content, [state.camShot]).then(function () { + closeCam(); + }); + }); + } + + function saveCamAlbum() { + if (!state.camShot) { + alert("请先拍照"); + return; + } + dataUrlToPath(state.camShot, "share/selfie.jpg") + .then(function (path) { + return Bridge.saveImageToPhotosAlbum(path); + }) + .then(function () { + alert("已保存到相册"); + }) + .catch(function (err) { + alert((err && err.errMsg) || "保存失败"); + }); + } + + function openJournalSheet() { + openSettings(false); + setHidden(el.journalMask, false); + if (el.journalInput) { + el.journalInput.value = ""; + try { + el.journalInput.focus(); + } catch (e) {} + } + } + + function closeJournalSheet() { + setHidden(el.journalMask, true); + } + + function saveJournalEntry(andShare) { + var text = el.journalInput ? String(el.journalInput.value || "").trim() : ""; + if (!text) { + alert("请先写一点内容"); + return; + } + if (text.length > 800) text = text.slice(0, 800); + var ch = (state.book.chapters || [])[state.activeChapter]; + var entry = { + id: "j_" + Date.now(), + date: todayKey(), + text: text, + chapterId: ch && ch.id, + chapterTitle: ch && ch.title, + bookId: state.book.id, + updatedAt: Date.now() + }; + state.journal = [entry].concat(state.journal || []).slice(0, 60); + saveJournal().then(function () { + // Best-effort append log line for 9.49+ filesystem + if (Bridge.canUseFileSystem(state.buildVersion)) { + Bridge.appendUtf8File( + "notes/journal.log", + todayKey() + "\t" + text.replace(/\n/g, " ") + "\n" + ).catch(function () {}); + } + refreshStorageCap(); + if (andShare) { + shareJournalEntry(entry); + } else { + alert("日记已保存 · 可在侧栏「日记」查看"); + closeJournalSheet(); + openToc(true); + setDrawerTab("journal"); + } + }); + } + + function findJournal(id) { + var list = state.journal || []; + for (var i = 0; i < list.length; i++) { + if (list[i].id === id) return list[i]; + } + return null; + } + + function shareJournalEntry(entry) { + if (!entry) return; + var card = makeTextCard({ + brand: "阅读日记", + title: state.book.title, + subtitle: (entry.date || "") + (entry.chapterTitle ? " · " + entry.chapterTitle : ""), + body: entry.text || "", + foot: "异度星球 · 日记" + }); + if (!card) return; + var content = + "📔 阅读日记 · 《" + + state.book.title + + "》\n" + + (entry.date ? entry.date + "\n" : "") + + "\n" + + (entry.text || "") + + "\n\n#数字游民 #一人公司日记"; + postImagesNote("阅读日记", content, [card]).then(function () { + closeJournalSheet(); + }); + } + + function deleteJournalEntry(id) { + state.journal = (state.journal || []).filter(function (j) { + return j.id !== id; + }); + saveJournal().then(function () { + renderToc(el.tocFilter ? el.tocFilter.value : ""); + refreshStorageCap(); + }); + } + + function shareAllClipsNote() { + openSettings(false); + var notes = state.notes || []; + if (!notes.length) { + alert("还没有摘录,先点「摘录本章」"); + return; + } + var imgs = []; + var texts = []; + var max = Math.min(notes.length, 9); + for (var i = 0; i < max; i++) { + var n = notes[i]; + var card = makeTextCard({ + brand: "摘录 " + (i + 1), + title: state.book.title, + subtitle: n.title || "", + body: n.text || "", + foot: "异度星球 · 摘录本" + }); + if (card) imgs.push(card); + texts.push((i + 1) + ". " + (n.text || "").slice(0, 40)); + } + if (!imgs.length) { + alert("无法生成摘录图"); + return; + } + var content = + "我的阅读摘录 · 《" + + state.book.title + + "》\n共 " + + notes.length + + " 条(发布 " + + imgs.length + + " 图)\n\n" + + texts.join("\n") + + "\n\n#数字游民 #一人公司摘录"; + postImagesNote("阅读摘录", content, imgs); + } + + function saveAllClipsAlbum() { + openSettings(false); + var notes = state.notes || []; + if (!notes.length) { + alert("还没有摘录"); + return; + } + if (!requireMiniTool("存相册")) return; + var max = Math.min(notes.length, 9); + var chain = Promise.resolve(0); + for (var i = 0; i < max; i++) { + (function (note, index) { + chain = chain.then(function (count) { + var card = makeTextCard({ + brand: "摘录", + title: state.book.title, + subtitle: note.title || "", + body: note.text || "", + foot: "异度星球 · 摘录本" + }); + if (!card) return count; + return dataUrlToPath(card, "notes/batch_" + index + ".png") + .then(function (path) { + return Bridge.saveImageToPhotosAlbum(path).then(function () { + return count + 1; + }); + }) + .catch(function () { + return count; + }); + }); + })(notes[i], i); + } + chain.then(function (count) { + alert(count > 0 ? "已保存 " + count + " 张到相册" : "保存失败"); + }); + } + + function clipChapter() { + var book = state.book; + var ch = (book.chapters || [])[state.activeChapter]; + if (!ch) return; + var text = chapterExcerpt(ch, 160); + if (!text) { + alert("本章暂无可摘录正文"); + return; + } + var note = { + id: "n_" + Date.now(), + bookId: book.id, + chapterId: ch.id, + chapterIndex: state.activeChapter, + title: ch.title, + text: text, + updatedAt: Date.now() + }; + state.notes = [note].concat(state.notes || []).slice(0, 40); + saveNotes().then(function () { + alert("已摘录到侧栏「摘录」· 可发笔记 / 存相册 / 发评论"); + refreshStorageCap(); + openSettings(false); + openToc(true); + setDrawerTab("notes"); + }); + } + + function findNote(id) { + var list = state.notes || []; + for (var i = 0; i < list.length; i++) { + if (list[i].id === id) return list[i]; + } + return null; + } + + function shareNoteItem(note) { + if (!note) return; + var card = makeTextCard({ + brand: "摘录", + title: state.book.title, + subtitle: note.title || "", + body: note.text || "", + foot: "异度星球 · 摘录本" + }); + if (!card) return; + var content = + "摘录自《" + + state.book.title + + "》" + + (note.title ? " · " + note.title : "") + + "\n\n「" + + (note.text || "") + + "」\n\n#数字游民 #一人公司摘录"; + postImagesNote("阅读摘录", content, [card]); + } + + function saveNoteToAlbum(note) { + if (!note || !requireMiniTool("存相册")) return; + var card = makeTextCard({ + brand: "摘录", + title: state.book.title, + subtitle: note.title || "", + body: note.text || "", + foot: "异度星球 · 摘录本" + }); + if (!card) return; + dataUrlToPath(card, "notes/" + note.id + ".png") + .then(function (path) { + return Bridge.saveImageToPhotosAlbum(path); + }) + .then(function () { + alert("已保存到相册"); + }) + .catch(function (err) { + alert((err && err.errMsg) || "保存失败"); + }); + } + + function commentNoteItem(note) { + if (!note) return; + if (!Bridge.canPostComment(state.buildVersion)) { + alert("当前客户端需 9.49+ 才支持发评论"); + return; + } + var card = makeTextCard({ + brand: "摘录", + title: state.book.title, + subtitle: note.title || "", + body: note.text || "", + foot: "异度星球" + }); + if (!card) return; + Bridge.writeTempFile(card) + .then(function (filePath) { + return Bridge.postComment( + { + action: "post_comment", + content: "「" + (note.text || "").slice(0, 80) + "」 #数字游民", + media_bean: [{ media_type: "image", cover_image_url: filePath }], + miniToolSnapshotInfo: JSON.stringify({ + bookId: state.book.id, + chapterId: note.chapterId, + chapterIndex: note.chapterIndex, + page: "reader", + noteId: note.id + }).slice(0, 2000) + }, + true + ); + }) + .catch(function (err) { + alert((err && err.errMsg) || "唤起评论失败"); + }); + } + + function deleteNoteItem(id) { + state.notes = (state.notes || []).filter(function (n) { + return n.id !== id; + }); + saveNotes().then(function () { + renderToc(el.tocFilter ? el.tocFilter.value : ""); + refreshStorageCap(); + }); + } + + function multiShareNote() { + openSettings(false); + var cover = makeCoverCard(); + var quote = makeQuoteCard(); + var checkin = makeCheckinCard(); + var imgs = []; + if (cover) imgs.push(cover); + if (quote) imgs.push(quote); + if (checkin) imgs.push(checkin); + if (!imgs.length) { + alert("无法生成图片"); + return; + } + var book = state.book; + var ch = (book.chapters || [])[state.activeChapter]; + var content = + "正在读《" + + book.title + + "》" + + (ch ? " · " + ch.title : "") + + "\n进度 " + + (state.scrollPct || 0) + + "%\n\n来自小工具「异度星球」· 多图笔记\n#数字游民 #一人公司"; + postImagesNote((book.title || "异度星球").slice(0, 20), content, imgs); + } + + function saveQuoteCard() { + var dataUrl = makeQuoteCard(); + if (!dataUrl) { + alert("无法生成图片"); + return; + } + if (!requireMiniTool("保存金句图")) return; + dataUrlToPath(dataUrl, "share/quote.png") + .then(function (filePath) { + return Bridge.saveImageToPhotosAlbum(filePath); + }) + .then(function () { + alert("已保存到相册"); + }) + .catch(function (err) { + Bridge.saveImageToPhotosAlbum(dataUrl) + .then(function () { + alert("已保存到相册"); + }) + .catch(function (err2) { + alert((err2 && err2.errMsg) || (err && err.errMsg) || "保存失败"); + }); + }); + } + + function shareNote() { + var book = state.book; + var ch = (book.chapters || [])[state.activeChapter]; + var title = (book.title || "异度星球").slice(0, 20); + var excerpt = chapterExcerpt(ch, 80); + var content = + "我在读《" + + book.title + + "》" + + (ch ? " · " + ch.title : "") + + (excerpt ? "\n\n「" + excerpt + "」" : "") + + "\n\n来自小工具「异度星球」· 异度世界"; + var dataUrl = makeQuoteCard(); + if (!dataUrl) { + alert("无法生成分享图"); + return; + } + postImagesNote(title, content, [dataUrl]); + } + + function postCommentExcerpt() { + var book = state.book; + var ch = (book.chapters || [])[state.activeChapter]; + var text = + "正在读《" + book.title + "》" + (ch ? " · " + ch.title : "") + " #数字游民"; + if (!Bridge.canPostComment(state.buildVersion)) { + alert("当前客户端版本需 9.49+ 才支持发评论"); + return; + } + var dataUrl = makeQuoteCard(); + var snap = { + bookId: book.id, + chapterId: ch && ch.id, + chapterIndex: state.activeChapter, + scrollPercent: state.scrollPct || 0, + page: "reader" + }; + var snapStr = JSON.stringify(snap); + if (snapStr.length > 2000) { + snap = { bookId: book.id, chapterId: ch && ch.id, page: "reader" }; + snapStr = JSON.stringify(snap); + } + Bridge.writeTempFile(dataUrl) + .then(function (filePath) { + return Bridge.postComment( + { + action: "post_comment", + content: text, + media_bean: [ + { media_type: "image", cover_image_url: filePath } + ], + miniToolSnapshotInfo: snapStr + }, + true + ); + }) + .catch(function (err) { + alert((err && err.errMsg) || "唤起评论失败"); + }); + } + + function postTextComment() { + var book = state.book; + var ch = (book.chapters || [])[state.activeChapter]; + if (!Bridge.canPostComment(state.buildVersion)) { + alert("当前客户端版本需 9.49+ 才支持发评论"); + return; + } + var excerpt = chapterExcerpt(ch, 60); + var text = + "正在读《" + + book.title + + "》" + + (ch ? " · " + ch.title : "") + + (excerpt ? "\n「" + excerpt + "」" : "") + + "\n进度 " + + (state.scrollPct || 0) + + "%" + + (todayReadMinutes() > 0 ? " · 今日已读" + todayReadMinutes() + "分钟" : "") + + " #异度星球"; + var snapStr = JSON.stringify({ + bookId: book.id, + chapterId: ch && ch.id, + chapterIndex: state.activeChapter, + scrollPercent: state.scrollPct || 0, + page: "reader" + }).slice(0, 2000); + Bridge.postComment( + { + action: "post_comment", + content: text, + miniToolSnapshotInfo: snapStr + }, + false + ).catch(function (err) { + alert((err && err.errMsg) || "唤起评论失败"); + }); + } + + function findWork(id) { + var list = state.works || []; + for (var i = 0; i < list.length; i++) { + if (list[i].id === id) return list[i]; + } + return null; + } + + function openWorksPanel() { + openSettings(false); + openToc(true); + setDrawerTab("works"); + } + + function shareWorkItem(work) { + if (!work || !work.path) return; + if (!requireMiniTool("再发笔记")) return; + Bridge.postNote({ + title: (work.title || "异度星球").slice(0, 20), + content: "来自小工具「异度星球」作品库\n#异度星球", + pageType: "photo_publish", + mediaInfo: { image_resources: [{ url: work.path }] } + }).catch(function (err) { + alert((err && err.errMsg) || "发笔记失败"); + }); + } + + function saveWorkAlbum(work) { + if (!work || !work.path) return; + if (!requireMiniTool("存相册")) return; + Bridge.saveImageToPhotosAlbum(work.path) + .then(function () { + alert("已保存到相册"); + }) + .catch(function (err) { + alert((err && err.errMsg) || "保存失败"); + }); + } + + function deleteWorkItem(id) { + var work = findWork(id); + state.works = (state.works || []).filter(function (w) { + return w.id !== id; + }); + saveWorks().then(function () { + if (work && work.path && Bridge.canUseFileSystem(state.buildVersion)) { + Bridge.unlinkFile(work.path).catch(function () {}); + } + renderToc(el.tocFilter ? el.tocFilter.value : ""); + }); + } + + function cleanupGeneratedFiles() { + if (!Bridge.canUseFileSystem(state.buildVersion)) { + alert("需客户端 9.49+ 才支持清理文件缓存"); + return; + } + if (!confirm("清理 share/ 下生成的临时图片?作品列表也会同步刷新")) return; + Bridge.cleanupShareDir().then(function (n) { + state.works = []; + return saveWorks().then(function () { + alert("已清理 " + (n || 0) + " 个文件"); + refreshStorageCap(); + }); + }); + } + + function clearLocalData() { + if (!confirm("清除阅读进度、收藏、摘录和日记?(阅读设置与打卡天数会保留)")) return; + Promise.all([ + Bridge.removeLocalData(PROGRESS_KEY), + Bridge.removeLocalData(BOOKMARKS_KEY), + Bridge.removeLocalData(NOTES_KEY), + Bridge.removeLocalData(JOURNAL_KEY) + ]).then(function () { + state.progress = null; + state.bookmarks = []; + state.notes = []; + state.journal = []; + syncNotesToFs([]); + if (Bridge.canUseFileSystem(state.buildVersion)) { + Bridge.writeUtf8File(JOURNAL_FILE, "[]").catch(function () {}); + } + alert("已清除进度、收藏、摘录与日记"); + syncActionLabels(); + refreshStorageCap(); + goHome(); + }); + } + + function closestTocItem(node) { + while (node && node.nodeType === 1) { + if (node.classList && node.classList.contains("drawer-item")) return node; + node = node.parentNode; + } + return null; + } + + function wrapFillText(ctx, text, x, y, maxWidth, lineHeight) { + var chars = String(text || "").split(""); + var line = ""; + var cy = y; + for (var i = 0; i < chars.length; i++) { + var test = line + chars[i]; + if (ctx.measureText(test).width > maxWidth && line) { + ctx.fillText(line, x, cy); + line = chars[i]; + cy += lineHeight; + } else { + line = test; + } + } + if (line) ctx.fillText(line, x, cy); + } + + function readCssPx(value) { + if (!value) return 0; + var n = parseFloat(String(value).replace("px", "").trim()); + return isNaN(n) ? 0 : n; + } + + function measureEnvInsetTop() { + try { + var probe = document.createElement("div"); + probe.style.cssText = + "position:absolute;visibility:hidden;pointer-events:none;padding-top:constant(safe-area-inset-top);padding-top:env(safe-area-inset-top);"; + document.body.appendChild(probe); + var px = readCssPx(window.getComputedStyle(probe).paddingTop); + document.body.removeChild(probe); + return px; + } catch (e) { + return 0; + } + } + + function applySafeArea() { + try { + var root = document.documentElement; + var fromVar = 0; + try { + fromVar = readCssPx( + window.getComputedStyle(root).getPropertyValue("--safe-area-inset-top") + ); + } catch (e1) {} + var fromEnv = measureEnvInsetTop(); + var status = fromVar || fromEnv || 0; + if (status < 20) status = 32; + var hostChrome = 48; + var padTop = status + hostChrome; + root.style.setProperty("--app-pad-top", padTop + "px"); + root.style.setProperty("--safe-area-inset-top", status + "px"); + } catch (e) { + try { + document.documentElement.style.setProperty("--app-pad-top", "80px"); + } catch (e2) {} + } + } + + function collectEls() { + el.boot = $("view-boot"); + el.bootText = $("boot-text"); + el.home = $("view-home"); + el.reader = $("view-reader"); + el.coverGlow = $("cover-glow"); + el.cover = $("btn-cover"); + el.coverEmoji = $("cover-emoji"); + el.coverTitle = $("cover-title"); + el.homeTitle = $("home-title"); + el.homeTease = $("home-tease"); + el.homeAuthor = $("home-author"); + el.homeHint = $("home-hint"); + el.homeTime = $("home-time"); + el.homeCheckin = $("home-checkin"); + el.homeJournal = $("home-journal"); + el.homeWorks = $("home-works"); + el.btnStart = $("btn-start"); + el.btnToc = $("btn-toc"); + el.btnTocTitle = $("btn-toc-title"); + el.btnSettings = $("btn-settings"); + el.btnTop = $("btn-top"); + el.btnShare = $("btn-share-note"); + el.btnSaveCardFoot = $("btn-save-card-foot"); + el.btnBookmark = $("btn-bookmark"); + el.btnSaveCard = $("btn-save-card"); + el.btnShareSettings = $("btn-share-settings"); + el.btnComment = $("btn-comment"); + el.btnCommentText = $("btn-comment-text"); + el.btnWorks = $("btn-works"); + el.btnCleanupFiles = $("btn-cleanup-files"); + el.btnCheckin = $("btn-checkin"); + el.btnSelfie = $("btn-selfie"); + el.btnPhotoNote = $("btn-photo-note"); + el.btnVideoNote = $("btn-video-note"); + el.btnJournal = $("btn-journal"); + el.btnClipNote = $("btn-clip-note"); + el.btnClipsShare = $("btn-clips-share"); + el.btnClipsAlbum = $("btn-clips-album"); + el.btnMultiShare = $("btn-multi-share"); + el.btnClearData = $("btn-clear-data"); + el.btnBackHome = $("btn-back-home"); + el.tabChapters = $("tab-chapters"); + el.tabBookmarks = $("tab-bookmarks"); + el.tabNotes = $("tab-notes"); + el.tabJournal = $("tab-journal"); + el.tabWorks = $("tab-works"); + el.storageCap = $("storage-cap"); + el.inputPhoto = $("input-photo"); + el.inputVideo = $("input-video"); + el.camMask = $("cam-mask"); + el.camVideo = $("cam-video"); + el.camCanvas = $("cam-canvas"); + el.camPreview = $("cam-preview"); + el.camTip = $("cam-tip"); + el.btnCamSnap = $("btn-cam-snap"); + el.btnCamPost = $("btn-cam-post"); + el.btnCamAlbum = $("btn-cam-album"); + el.btnCamClose = $("btn-cam-close"); + el.journalMask = $("journal-mask"); + el.journalSheet = $("journal-sheet"); + el.journalInput = $("journal-input"); + el.btnJournalSave = $("btn-journal-save"); + el.btnJournalPost = $("btn-journal-post"); + el.btnJournalClose = $("btn-journal-close"); + el.chapterTitle = $("reader-chapter-title"); + el.progressLabel = $("reader-progress-label"); + el.topbarBar = $("topbar-bar"); + el.topbar = $("topbar"); + el.paper = $("paper"); + el.tocMask = $("toc-mask"); + el.tocDrawer = $("toc-drawer"); + el.tocFilter = $("toc-filter"); + el.tocList = $("toc-list"); + el.drawerMeter = $("drawer-meter-fill"); + el.drawerStatLeft = $("drawer-stat-left"); + el.drawerStatRight = $("drawer-stat-right"); + el.settingsMask = $("settings-mask"); + el.settingsSheet = $("settings-sheet"); + el.prefSize = $("pref-size"); + el.prefLh = $("pref-lh"); + el.prefFont = $("pref-font"); + el.prefTheme = $("pref-theme"); + } + + function bind() { + if (state.bound) return; + state.bound = true; + on(el.btnStart, "click", goRead); + on(el.cover, "click", goRead); + on(el.btnToc, "click", function () { + openToc(true); + }); + on(el.btnTocTitle, "click", function () { + openToc(true); + }); + on(el.tocMask, "click", function () { + openToc(false); + }); + on(el.tocDrawer, "click", function (ev) { + if (ev && ev.stopPropagation) ev.stopPropagation(); + }); + on(el.btnSettings, "click", function () { + refreshPrefSegs(); + syncActionLabels(); + openSettings(true); + }); + on(el.settingsMask, "click", function (ev) { + if (ev.target === el.settingsMask) openSettings(false); + }); + on(el.settingsSheet, "click", function (ev) { + if (ev && ev.stopPropagation) ev.stopPropagation(); + }); + on(el.btnTop, "click", function () { + jumpToChapter(0); + }); + on(el.btnShare, "click", shareNote); + on(el.btnSaveCardFoot, "click", saveQuoteCard); + on(el.btnBookmark, "click", toggleBookmark); + on(el.btnSaveCard, "click", saveQuoteCard); + on(el.btnShareSettings, "click", shareNote); + on(el.btnComment, "click", postCommentExcerpt); + on(el.btnCommentText, "click", postTextComment); + on(el.btnWorks, "click", openWorksPanel); + on(el.btnCleanupFiles, "click", cleanupGeneratedFiles); + on(el.btnCheckin, "click", postCheckinNote); + on(el.btnSelfie, "click", openCam); + on(el.btnPhotoNote, "click", openPhotoPicker); + on(el.btnVideoNote, "click", openVideoPicker); + on(el.btnJournal, "click", openJournalSheet); + on(el.homeCheckin, "click", function () { + goRead(); + setTimeout(function () { + postCheckinNote(); + }, 400); + }); + on(el.homeJournal, "click", function () { + goRead(); + setTimeout(function () { + openJournalSheet(); + }, 400); + }); + on(el.homeWorks, "click", function () { + goRead(); + setTimeout(function () { + openWorksPanel(); + }, 400); + }); + on(el.btnClipNote, "click", clipChapter); + on(el.btnClipsShare, "click", shareAllClipsNote); + on(el.btnClipsAlbum, "click", saveAllClipsAlbum); + on(el.btnMultiShare, "click", multiShareNote); + on(el.inputPhoto, "change", onPhotoPicked); + on(el.inputVideo, "change", onVideoPicked); + on(el.btnCamSnap, "click", snapCam); + on(el.btnCamPost, "click", postCamShot); + on(el.btnCamAlbum, "click", saveCamAlbum); + on(el.btnCamClose, "click", closeCam); + on(el.btnJournalSave, "click", function () { + saveJournalEntry(false); + }); + on(el.btnJournalPost, "click", function () { + saveJournalEntry(true); + }); + on(el.btnJournalClose, "click", closeJournalSheet); + on(el.journalMask, "click", function (ev) { + if (ev.target === el.journalMask) closeJournalSheet(); + }); + on(el.btnClearData, "click", clearLocalData); + on(el.btnBackHome, "click", goHome); + on(el.tabChapters, "click", function () { + setDrawerTab("chapters"); + }); + on(el.tabBookmarks, "click", function () { + setDrawerTab("bookmarks"); + }); + on(el.tabNotes, "click", function () { + setDrawerTab("notes"); + }); + on(el.tabJournal, "click", function () { + setDrawerTab("journal"); + }); + on(el.tabWorks, "click", function () { + setDrawerTab("works"); + }); + on(el.tocFilter, "input", function () { + renderToc(el.tocFilter.value); + }); + on(el.tocList, "click", function (ev) { + var node = ev.target; + while (node && node !== el.tocList) { + var wAct = node.getAttribute && node.getAttribute("data-work-act"); + if (wAct) { + var wid = node.getAttribute("data-work-id"); + var work = findWork(wid); + if (wAct === "share") shareWorkItem(work); + else if (wAct === "album") saveWorkAlbum(work); + else if (wAct === "del") deleteWorkItem(wid); + return; + } + var jAct = node.getAttribute && node.getAttribute("data-journal-act"); + if (jAct) { + var jid = node.getAttribute("data-journal-id"); + if (jAct === "share") shareJournalEntry(findJournal(jid)); + else if (jAct === "del") deleteJournalEntry(jid); + return; + } + var act = node.getAttribute && node.getAttribute("data-note-act"); + if (act) { + var nid = node.getAttribute("data-note-id"); + var note = findNote(nid); + if (act === "share") shareNoteItem(note); + else if (act === "album") saveNoteToAlbum(note); + else if (act === "comment") commentNoteItem(note); + else if (act === "del") deleteNoteItem(nid); + return; + } + if (node.classList && node.classList.contains("drawer-item")) { + var idx = Number(node.getAttribute("data-idx") || 0); + openToc(false); + jumpToChapter(idx); + return; + } + node = node.parentNode; + } + }); + on(el.paper, "click", function (ev) { + var node = ev.target; + while (node && node !== el.paper) { + if (node.getAttribute && node.getAttribute("data-fin") === "share") { + postFinishNote(); + return; + } + if (node.getAttribute && node.getAttribute("data-fin") === "restart") { + jumpToChapter(0); + return; + } + if (node.getAttribute && node.getAttribute("data-fin") === "home") { + goHome(); + return; + } + if (node.classList && node.classList.contains("next-peek")) { + var idx = Number(node.getAttribute("data-next-idx") || 0); + jumpToChapter(idx); + return; + } + node = node.parentNode; + } + handleReaderTap(ev); + }); + var touchStart = null; + on(el.paper, "touchstart", function (ev) { + var t = ev.touches && ev.touches[0]; + if (!t) return; + touchStart = { x: t.clientX, y: t.clientY, t: Date.now() }; + }); + on(el.paper, "touchend", function (ev) { + if (!touchStart) return; + var t = ev.changedTouches && ev.changedTouches[0]; + if (!t) { + touchStart = null; + return; + } + var dx = Math.abs(t.clientX - touchStart.x); + var dy = Math.abs(t.clientY - touchStart.y); + var dt = Date.now() - touchStart.t; + touchStart = null; + if (dx > 12 || dy > 12 || dt > 450) return; + // synthetic path already handled by click on most WebViews + }); + on(window, "scroll", function () { + if (el.reader && (!el.reader.classList || !el.reader.classList.contains("is-hidden"))) { + updateProgressUI(); + } + }); + } + + function setChromeHidden(hidden) { + state.chromeHidden = !!hidden; + if (!el.reader) return; + if (hidden) { + if (el.reader.classList) el.reader.classList.add("chrome-hidden"); + else el.reader.className += " chrome-hidden"; + } else { + if (el.reader.classList) el.reader.classList.remove("chrome-hidden"); + else + el.reader.className = String(el.reader.className || "").replace( + /\bchrome-hidden\b/g, + "" + ); + } + } + + function handleReaderTap(ev) { + if (!ev) return; + var node = ev.target; + while (node && node !== el.paper) { + if ( + node.tagName === "BUTTON" || + node.tagName === "A" || + (node.classList && + (node.classList.contains("next-peek") || node.classList.contains("fin-btn"))) + ) { + return; + } + node = node.parentNode; + } + var x = ev.clientX; + if (typeof x !== "number") return; + var w = window.innerWidth || 360; + var zone = w / 3; + if (x < zone) { + scrollToY((window.pageYOffset || 0) - Math.round((window.innerHeight || 600) * 0.85)); + setTimeout(updateProgressUI, 40); + } else if (x > w - zone) { + scrollToY((window.pageYOffset || 0) + Math.round((window.innerHeight || 600) * 0.85)); + setTimeout(updateProgressUI, 40); + } else { + setChromeHidden(!state.chromeHidden); + } + } + + function findChapterIndex(chapterId) { + var chapters = (state.book && state.book.chapters) || []; + for (var i = 0; i < chapters.length; i++) { + if (chapters[i].id === chapterId) return i; + } + return -1; + } + + function applySnapshot(snap) { + if (!snap || snap.page !== "reader") return false; + if (snap.bookId && state.book && snap.bookId !== state.book.id) return false; + var idx = + typeof snap.chapterIndex === "number" + ? snap.chapterIndex + : findChapterIndex(snap.chapterId); + if (idx < 0) idx = 0; + state.activeChapter = idx; + var pct = Number(snap.scrollPercent) || 0; + getProgress(state.book.id).then(function (progress) { + state.progress = progress || { + bookId: state.book.id, + chapterId: snap.chapterId, + chapterIndex: idx, + scrollPercent: pct + }; + if (!progress && snap.chapterId) { + state.progress.chapterId = snap.chapterId; + state.progress.scrollPercent = pct; + } else if (progress && pct > 0) { + state.progress.scrollPercent = pct; + state.progress.chapterId = snap.chapterId || progress.chapterId; + state.progress.chapterIndex = idx; + } + renderReader(true); + refreshPrefSegs(); + syncActionLabels(); + }); + return true; + } + + function boot() { + try { + if (!Bridge) { + if ($("boot-text")) $("boot-text").textContent = "桥接模块未加载"; + return; + } + collectEls(); + applySafeArea(); + if (!el.boot || !el.home || !el.btnStart) { + if (el.bootText) el.bootText.textContent = "页面结构异常"; + return; + } + var book = getBookData(); + if (!book) { + showBootError("内容未加载"); + return; + } + if (!window.MarkdownLite) { + showBootError("渲染模块未加载"); + return; + } + state.book = book; + Bridge.getBuildVersion() + .then(function (v) { + state.buildVersion = v || 0; + return Promise.all([ + loadPrefs(), + loadBookmarks(), + loadNotes(), + loadJournal(), + loadStreak(), + loadReadTime(), + loadWorks(), + Bridge.getLaunchOptions() + ]); + }) + .then(function (tuple) { + state.prefs = tuple[0] || copyObj(DEFAULT_PREFS); + bind(); + refreshStorageCap(); + var snap = Bridge.readSnapshotInfo(tuple[7]); + if (snap && applySnapshot(snap)) { + startReadTimer(); + return; + } + renderHome(); + }) + .catch(function (err) { + showBootError("启动错误: " + (err && err.message ? err.message : String(err))); + }); + } catch (err) { + var msg = err && err.message ? err.message : String(err); + showBootError("启动错误: " + msg); + } + } + + if (document.readyState === "loading") { + on(document, "DOMContentLoaded", boot); + } else { + boot(); + } +})(); + diff --git a/apps/miniprogram/xhs/tool/book-styles.css b/apps/miniprogram/xhs/tool/book-styles.css new file mode 100644 index 0000000..3cbecde --- /dev/null +++ b/apps/miniprogram/xhs/tool/book-styles.css @@ -0,0 +1,1435 @@ +:root { + --safe-top: 0px; + --safe-bottom: 0px; + --r-bg: #0c0b12; + --r-bg2: #15101f; + --r-text: #f3eefc; + --r-muted: #b4a9c8; + --r-accent: #ff7ab6; + --r-accent2: #a78bfa; + --r-soft: rgba(255, 255, 255, 0.06); + --r-border: rgba(255, 255, 255, 0.1); + --r-paper: rgba(28, 22, 45, 0.92); + --r-chrome: rgba(12, 11, 18, 0.94); +} + +*, +*::before, +*::after { + box-sizing: border-box; + margin: 0; + padding: 0; +} + +html, +body { + height: 100%; + min-height: 100%; + min-height: 100vh; + font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", + "Hiragino Sans GB", "Microsoft YaHei", sans-serif; + background: #0a0910; + color: #f3eefc; + -webkit-font-smoothing: antialiased; + -webkit-tap-highlight-color: transparent; +} + +button, +input { + font: inherit; + color: inherit; +} + +button { + border: 0; + background: none; + cursor: pointer; +} + +.is-hidden { + display: none !important; +} + +.file-hidden { + position: absolute; + width: 1px; + height: 1px; + opacity: 0; + overflow: hidden; + z-index: -1; +} + +.view { + min-height: 100%; + min-height: 100vh; +} + +/* —— Home —— */ +.home { + position: relative; + background: + radial-gradient(820px 460px at 12% -8%, rgba(167, 139, 250, 0.3), transparent 58%), + radial-gradient(720px 420px at 100% 0%, rgba(244, 114, 182, 0.24), transparent 52%), + linear-gradient(168deg, #0a0910 0%, #14101c 46%, #0e0c14 100%); +} + +.home.loading { + display: -webkit-flex; + display: flex; + -webkit-flex-direction: column; + flex-direction: column; + -webkit-align-items: center; + align-items: center; + -webkit-justify-content: center; + justify-content: center; + padding: 48px; +} + +.loading-text { + position: relative; + z-index: 2; + font-size: 18px; + color: #e8dff8; +} + +.bg-layer { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + overflow: hidden; + pointer-events: none; +} + +.orb { + position: absolute; + border-radius: 50%; + opacity: 0.7; + -webkit-animation: aurora 10s ease-in-out infinite; + animation: aurora 10s ease-in-out infinite; +} + +.orb-a { + width: 280px; + height: 280px; + left: -90px; + top: 40px; + background: radial-gradient(circle, rgba(167, 139, 250, 0.5), transparent 70%); +} + +.orb-b { + width: 320px; + height: 320px; + right: -110px; + top: 220px; + background: radial-gradient(circle, rgba(244, 114, 182, 0.42), transparent 70%); + -webkit-animation-delay: 1.4s; + animation-delay: 1.4s; +} + +.veil { + position: absolute; + top: 0; + right: 0; + bottom: 0; + left: 0; + background: linear-gradient(180deg, transparent 55%, rgba(10, 9, 16, 0.72) 100%); +} + +.stage { + position: relative; + z-index: 1; + min-height: 100%; + min-height: 100vh; + padding: 28px; + padding-top: 80px; + padding-top: calc(var(--app-pad-top, 80px) + 12px); + padding-bottom: 40px; + padding-bottom: calc(40px + var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 0px))); + display: -webkit-flex; + display: flex; + -webkit-flex-direction: column; + flex-direction: column; + -webkit-align-items: center; + align-items: center; +} + +.brand-block { + text-align: center; + margin-bottom: 28px; +} + +.brand { + font-size: 28px; + font-weight: 700; + letter-spacing: 0.18em; + color: #e9d5ff; +} + +.brand-line { + margin-top: 8px; + font-size: 13px; + color: #9f93b8; + letter-spacing: 0.06em; +} + +.cover-wrap { + position: relative; + width: 58%; + max-width: 220px; + margin: 8px 0 28px; +} + +.cover-glow { + position: absolute; + top: -18%; + right: -18%; + bottom: -18%; + left: -18%; + border-radius: 50%; + -webkit-filter: blur(28px); + filter: blur(28px); + opacity: 0.85; + background: rgba(219, 39, 119, 0.45); +} + +/* Chrome 61: padding-box ratio instead of aspect-ratio */ +.cover { + position: relative; + display: block; + width: 100%; + height: 0; + padding-top: 133.33%; + border-radius: 18px; + overflow: hidden; + box-shadow: 0 24px 48px rgba(0, 0, 0, 0.45); + background: linear-gradient(155deg, #1a0b2e 0%, #6d28d9 42%, #db2777 100%); +} + +.cover-shine, +.cover-emoji, +.cover-title { + position: absolute; + left: 0; + right: 0; +} + +.cover-shine { + top: 0; + bottom: 0; + background: linear-gradient(125deg, rgba(255, 255, 255, 0.22) 0%, transparent 42%); + pointer-events: none; +} + +.cover-emoji { + top: 36%; + font-size: 52px; + line-height: 1; + text-align: center; +} + +.cover-title { + bottom: 20px; + padding: 0 16px; + font-size: 15px; + font-weight: 600; + text-align: center; + line-height: 1.35; + color: #fce7f3; +} + +.copy { + text-align: center; + max-width: 320px; +} + +.copy .title { + margin-bottom: 10px; + font-size: 22px; + font-weight: 700; + line-height: 1.35; + color: #f8f4ff; +} + +.tease { + font-size: 14px; + line-height: 1.6; + color: #b4a9c8; +} + +.author { + margin-top: 10px; + font-size: 12px; + color: #8b7fa8; +} + +.cta-area { + margin-top: auto; + width: 100%; + max-width: 320px; + padding-top: 36px; + display: -webkit-flex; + display: flex; + -webkit-flex-direction: column; + flex-direction: column; + -webkit-align-items: center; + align-items: center; +} + +.cta { + width: 100%; + height: 52px; + margin-bottom: 12px; + border-radius: 999px; + font-size: 16px; + font-weight: 600; + color: #1a0b2e; + background: linear-gradient(120deg, #fce7f3, #e9d5ff 40%, #c4b5fd); + box-shadow: 0 12px 32px rgba(167, 139, 250, 0.35); +} + +.resume-hint { + font-size: 12px; + color: #8b7fa8; +} + +.home-xhs { + display: -webkit-flex; + display: flex; + -webkit-justify-content: center; + justify-content: center; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; + gap: 8px; + margin-top: 14px; +} + +.home-xhs-btn { + padding: 8px 12px; + border-radius: 999px; + border: 1px solid rgba(255, 255, 255, 0.18); + background: rgba(255, 255, 255, 0.06); + color: #f3eefc; + font-size: 12px; +} + +.home-time { + margin-top: 10px; + font-size: 12px; + color: rgba(243, 238, 252, 0.55); +} + +/* —— Reader —— */ +.reader { + position: relative; + background: var(--r-bg); + color: var(--r-text); +} + +.reader.theme-sepia { + background: #f3e9d7; + --r-bg: #f3e9d7; + --r-bg2: #e8dcc4; + --r-text: #3d2f1f; + --r-muted: #8a7358; + --r-accent: #c2410c; + --r-accent2: #b45309; + --r-soft: rgba(120, 80, 40, 0.08); + --r-border: rgba(120, 80, 40, 0.16); + --r-paper: rgba(255, 252, 245, 0.95); + --r-chrome: rgba(243, 233, 215, 0.96); +} + +.reader.theme-light { + background: #f7f4fb; + --r-bg: #f7f4fb; + --r-bg2: #eee8f6; + --r-text: #1e1630; + --r-muted: #6d6286; + --r-accent: #db2777; + --r-accent2: #7c3aed; + --r-soft: rgba(30, 22, 48, 0.05); + --r-border: rgba(30, 22, 48, 0.1); + --r-paper: rgba(255, 255, 255, 0.96); + --r-chrome: rgba(247, 244, 251, 0.96); +} + +.reader-bg { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + pointer-events: none; + background: + radial-gradient(520px 260px at 10% -8%, rgba(167, 139, 250, 0.22), transparent 55%), + radial-gradient(480px 240px at 100% 0%, rgba(244, 114, 182, 0.18), transparent 50%), + linear-gradient(180deg, var(--r-bg2), var(--r-bg)); + z-index: 0; +} + +.topbar { + position: fixed; + top: 0; + left: 0; + right: 0; + z-index: 40; + /* --app-pad-top 由 JS 写入:状态栏 + 小红书宿主返回/分享行 */ + padding-top: 80px; + padding-top: var(--app-pad-top, 80px); + padding-right: 12px; + padding-bottom: 8px; + padding-left: 12px; + display: -webkit-flex; + display: flex; + -webkit-align-items: center; + align-items: center; + background: var(--r-chrome); + border-bottom: 1px solid var(--r-border); + box-sizing: border-box; + -webkit-transition: -webkit-transform 0.22s ease, opacity 0.22s ease; + transition: transform 0.22s ease, opacity 0.22s ease; +} + +.reader.chrome-hidden .topbar { + -webkit-transform: translateY(-110%); + transform: translateY(-110%); + pointer-events: none; + opacity: 0; +} + +.reader.chrome-hidden .top-fab { + opacity: 0; + pointer-events: none; +} + +.topbar-progress { + position: absolute; + left: 0; + right: 0; + bottom: 0; + height: 2px; + background: var(--r-soft); + overflow: hidden; +} + +.topbar-progress-fill { + display: block; + height: 100%; + width: 0%; + background: linear-gradient(90deg, var(--r-accent), var(--r-accent2)); +} + +.top-btn { + width: 44px; + height: 44px; + margin-right: 8px; + border-radius: 12px; + background: var(--r-soft); + border: 1px solid var(--r-border); + display: -webkit-flex; + display: flex; + -webkit-align-items: center; + align-items: center; + -webkit-justify-content: center; + justify-content: center; + -webkit-flex-shrink: 0; + flex-shrink: 0; +} + +.top-btn:last-of-type { + margin-right: 0; + margin-left: 8px; +} + +.top-ico { + font-size: 18px; + color: var(--r-text); + line-height: 1; + font-weight: 600; +} + +.top-center { + -webkit-flex: 1; + flex: 1; + min-width: 0; + text-align: left; + background: transparent; + border: 0; + padding: 0; +} + +.top-title { + font-size: 15px; + color: var(--r-text); + font-weight: 600; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + line-height: 1.25; +} + +.top-sub { + margin-top: 1px; + font-size: 11px; + color: var(--r-muted); + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; +} + +.reader-body { + position: relative; + z-index: 1; + padding: 16px; + /* 顶栏:安全区 + 宿主行 + 按钮行(~52) */ + padding-top: 140px; + padding-top: calc(var(--app-pad-top, 80px) + 60px); + padding-bottom: 48px; + padding-bottom: calc(48px + var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 0px))); + max-width: 720px; + margin: 0 auto; + box-sizing: border-box; +} + +.paper { + background: var(--r-paper); + border: 1px solid var(--r-border); + border-radius: 20px; + padding: 16px 14px 20px; + box-shadow: 0 16px 40px rgba(0, 0, 0, 0.18); +} + +.hero-card { + padding: 4px 2px 12px; + margin-bottom: 8px; + border-bottom: 1px dashed var(--r-border); +} + +.hero-emoji { + display: block; + font-size: 28px; + line-height: 1; +} + +.hero-title { + display: block; + margin-top: 6px; + font-size: 22px; + font-weight: 700; + color: var(--r-text); + line-height: 1.25; +} + +.hero-sub { + display: block; + margin-top: 4px; + font-size: 13px; + color: var(--r-muted); + line-height: 1.4; +} + +.hero-stats { + margin-top: 12px; + display: -webkit-flex; + display: flex; +} + +.stat { + -webkit-flex: 1; + flex: 1; + padding: 8px 2px; + margin-right: 4px; + border-radius: 12px; + background: var(--r-soft); + text-align: center; +} + +.stat:last-child { + margin-right: 0; +} + +.stat-n { + display: block; + font-size: 15px; + font-weight: 700; + color: var(--r-text); + line-height: 1.2; +} + +.stat-l { + display: block; + margin-top: 1px; + font-size: 11px; + color: var(--r-muted); +} + +.hero-tip { + display: block; + margin-top: 10px; + text-align: center; + font-size: 12px; + color: var(--r-muted); +} + +.chapter-block { + padding-top: 4px; +} + +.chapter-divider { + display: -webkit-flex; + display: flex; + -webkit-justify-content: center; + justify-content: center; + margin: 18px 0 14px; +} + +.chapter-divider-text { + font-size: 14px; + letter-spacing: 0.45em; + color: var(--r-muted); + opacity: 0.65; +} + +.chapter-hero { + margin-bottom: 10px; + padding-bottom: 10px; + border-bottom: 1px dashed var(--r-border); +} + +.chapter-hero-top { + display: -webkit-flex; + display: flex; + -webkit-align-items: center; + align-items: center; + -webkit-justify-content: space-between; + justify-content: space-between; +} + +.chapter-hero-emoji { + font-size: 28px; + line-height: 1; +} + +.chapter-ring { + display: -webkit-flex; + display: flex; + -webkit-align-items: baseline; + align-items: baseline; + padding: 6px 12px; + border-radius: 999px; + background: var(--r-soft); + border: 1px solid var(--r-border); +} + +.chapter-ring-n { + font-size: 15px; + font-weight: 700; + color: var(--r-accent); + margin-right: 2px; +} + +.chapter-ring-t { + font-size: 12px; + color: var(--r-muted); +} + +.chapter-title { + display: block; + margin-top: 8px; + font-size: 20px; + font-weight: 700; + color: var(--r-text); + line-height: 1.3; +} + +.chapter-meta { + display: block; + margin-top: 4px; + font-size: 12px; + color: var(--r-muted); +} + +.md-wrap { + padding: 0; +} + +.next-peek { + margin-top: 16px; + padding: 12px 14px; + border-radius: 14px; + border: 1px dashed var(--r-border); + background: var(--r-soft); + width: 100%; + text-align: left; + color: inherit; +} + +.next-peek-label { + display: block; + font-size: 11px; + letter-spacing: 0.12em; + color: var(--r-muted); +} + +.next-peek-title { + display: block; + margin-top: 4px; + font-size: 15px; + font-weight: 600; + color: var(--r-text); + line-height: 1.35; +} + +.fin { + margin: 28px 0 24px; + padding: 20px 10px 12px; + text-align: center; + border-top: 1px dashed var(--r-border); +} + +.fin-emoji { + display: block; + font-size: 28px; +} + +.fin-title { + display: block; + margin-top: 6px; + font-size: 20px; + color: var(--r-text); + font-weight: 700; +} + +.fin-desc { + display: block; + margin-top: 4px; + font-size: 13px; + color: var(--r-muted); + font-style: italic; +} + +.fin-actions { + margin-top: 14px; + display: -webkit-flex; + display: flex; + gap: 10px; + -webkit-justify-content: center; + justify-content: center; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; +} + +.fin-btn { + padding: 10px 18px; + border-radius: 999px; + background: linear-gradient(135deg, var(--r-accent), var(--r-accent2)); + color: #fff; + font-size: 14px; + font-weight: 600; +} + +.fin-btn.ghost { + background: var(--r-soft); + border: 1px solid var(--r-border); + color: var(--r-text); +} + +.md-body { + font-size: 16px; + line-height: 1.7; + color: var(--r-text); + word-break: break-word; +} + +.md-body h2, +.md-body h3 { + margin: 1.2em 0 0.55em; + line-height: 1.35; +} + +.md-body h2 { + font-size: 1.18em; +} + +.md-body h3 { + font-size: 1.08em; + color: var(--r-muted); +} + +.md-body p { + margin: 0 0 0.85em; +} + +.md-body p.dropcap:first-letter, +.md-body .dropcap:first-letter { + float: left; + font-size: 2.4em; + line-height: 0.85; + padding: 0.08em 0.12em 0 0; + font-weight: 700; + color: var(--r-accent); +} + +.md-quote { + margin: 10px 0; + padding: 10px 12px; + border-radius: 0 12px 12px 0; + background: var(--r-soft); + border-left: 3px solid var(--r-accent); + color: var(--r-muted); + font-style: italic; +} + +.md-list { + margin: 0 0 0.85em; + padding-left: 1.1em; +} + +.md-list div { + margin: 0.25em 0; +} + +.md-code { + color: var(--r-accent2); + background: var(--r-soft); + padding: 0 4px; + border-radius: 4px; + font-size: 0.92em; +} + +.md-pre { + margin: 12px 0; + padding: 12px; + border-radius: 10px; + background: var(--r-soft); + border: 1px solid var(--r-border); + overflow-x: auto; + font-size: 0.88em; + line-height: 1.5; + white-space: pre-wrap; +} + +.md-hr { + border: 0; + border-top: 1px solid var(--r-border); + margin: 18px 0; +} + +.md-table-wrap { + margin: 12px 0 16px; + overflow-x: auto; + -webkit-overflow-scrolling: touch; + border-radius: 10px; + border: 1px solid var(--r-border); +} + +.md-table { + width: 100%; + border-collapse: collapse; + font-size: 0.92em; + line-height: 1.45; +} + +.md-table th, +.md-table td { + padding: 8px 10px; + text-align: left; + border-bottom: 1px solid var(--r-border); + vertical-align: top; + white-space: nowrap; +} + +.md-table th { + background: var(--r-soft); + color: var(--r-accent); + font-weight: 600; +} + +.md-table tr:last-child td { + border-bottom: 0; +} + +.reader-foot { + margin-top: 20px; + text-align: center; +} + +.foot-tip { + margin-bottom: 12px; + font-size: 12px; + color: var(--r-muted); +} + +.ghost-btn { + display: inline-block; + margin: 0 6px 8px; + padding: 10px 18px; + border-radius: 999px; + border: 1px solid var(--r-border); + color: var(--r-accent); + background: var(--r-soft); + font-size: 13px; +} + +.top-fab { + position: fixed; + right: 18px; + bottom: 24px; + bottom: calc(24px + var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 0px))); + z-index: 30; + width: 56px; + height: 56px; + border-radius: 50%; + background: var(--r-paper); + border: 1px solid var(--r-border); + display: -webkit-flex; + display: flex; + -webkit-align-items: center; + align-items: center; + -webkit-justify-content: center; + justify-content: center; + box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18); +} + +.top-fab-text { + font-size: 22px; + color: var(--r-accent); + font-weight: 700; +} + +/* —— TOC drawer(对齐微信小程序 reader drawer) —— */ +.drawer-mask { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + background: rgba(8, 6, 14, 0.55); + z-index: 100; +} + +.drawer { + position: absolute; + top: 0; + left: 0; + width: 78%; + max-width: 540px; + height: 100%; + background: + radial-gradient(360px 180px at 0% 0%, rgba(167, 139, 250, 0.18), transparent 55%), + linear-gradient(180deg, #1a1428, #120e1c 40%, #0c0b12); + padding: 22px 0 12px; + padding-top: 80px; + padding-top: calc(var(--app-pad-top, 80px) + 12px); + box-sizing: border-box; + display: -webkit-flex; + display: flex; + -webkit-flex-direction: column; + flex-direction: column; + color: #f3eefc; + -webkit-animation: drawer-in 0.24s cubic-bezier(0.22, 1, 0.36, 1) both; + animation: drawer-in 0.24s cubic-bezier(0.22, 1, 0.36, 1) both; +} + +.drawer.theme-sepia { + background: linear-gradient(180deg, #f6edd9, #efe3cb); + color: #3d2f1f; +} + +.drawer.theme-light { + background: linear-gradient(180deg, #faf8ff, #f0ebf8); + color: #1e1630; +} + +@-webkit-keyframes drawer-in { + from { -webkit-transform: translateX(-100%); transform: translateX(-100%); } + to { -webkit-transform: translateX(0); transform: translateX(0); } +} + +@keyframes drawer-in { + from { -webkit-transform: translateX(-100%); transform: translateX(-100%); } + to { -webkit-transform: translateX(0); transform: translateX(0); } +} + +.drawer-hero { + padding: 0 16px 10px; +} + +.drawer-brand { + display: block; + font-size: 12px; + letter-spacing: 1px; + color: var(--r-accent); +} + +.drawer-title { + display: block; + margin-top: 2px; + font-size: 22px; + font-weight: 700; +} + +.drawer-meter { + margin-top: 10px; + height: 4px; + border-radius: 999px; + background: rgba(255, 255, 255, 0.08); + overflow: hidden; +} + +.theme-sepia .drawer-meter, +.theme-light .drawer-meter { + background: rgba(0, 0, 0, 0.08); +} + +.drawer-meter-fill { + height: 100%; + width: 0%; + border-radius: inherit; + background: linear-gradient(90deg, var(--r-accent), var(--r-accent2)); +} + +.drawer-stats { + margin-top: 6px; + display: -webkit-flex; + display: flex; + -webkit-justify-content: space-between; + justify-content: space-between; + font-size: 12px; + color: var(--r-muted); +} + +.drawer-search { + display: block; + width: 100%; + margin-top: 10px; + height: 44px; + padding: 0 14px; + border-radius: 12px; + background: rgba(255, 255, 255, 0.06); + border: 1px solid var(--r-border); + font-size: 15px; + color: inherit; + outline: none; + box-sizing: border-box; +} + +.theme-sepia .drawer-search, +.theme-light .drawer-search { + background: rgba(0, 0, 0, 0.04); +} + +.drawer-list { + -webkit-flex: 1; + flex: 1; + height: 0; + min-height: 0; + padding: 4px 10px 24px; + box-sizing: border-box; + overflow-y: auto; + -webkit-overflow-scrolling: touch; +} + +.drawer-item { + display: -webkit-flex; + display: flex; + -webkit-align-items: flex-start; + align-items: flex-start; + padding: 10px; + margin-bottom: 2px; + border-radius: 12px; + width: 100%; + text-align: left; + color: inherit; + background: transparent; +} + +.drawer-item.active { + background: rgba(255, 122, 182, 0.12); +} + +.theme-sepia .drawer-item.active { + background: rgba(194, 65, 12, 0.1); +} + +.theme-light .drawer-item.active { + background: rgba(219, 39, 119, 0.08); +} + +.drawer-idx { + font-size: 14px; + color: var(--r-muted); + font-weight: 600; + padding-top: 2px; + min-width: 36px; + margin-right: 10px; +} + +.drawer-body { + -webkit-flex: 1; + flex: 1; + min-width: 0; +} + +.drawer-name { + display: block; + font-size: 15px; + line-height: 1.35; +} + +/* —— Settings sheet(对齐 ReaderSettings) —— */ +.rs-mask { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + z-index: 120; + background: rgba(8, 6, 14, 0.55); + display: -webkit-flex; + display: flex; + -webkit-align-items: flex-end; + align-items: flex-end; +} + +.rs-sheet { + width: 100%; + padding: 16px 20px 20px; + padding-bottom: 20px; + padding-bottom: calc(20px + var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 0px))); + border-radius: 22px 22px 0 0; + background: + radial-gradient(420px 160px at 50% 0%, rgba(255, 122, 182, 0.16), transparent 60%), + linear-gradient(180deg, #1a1428 0%, #120e1c 60%, #0c0b12 100%); + border-top: 1px solid rgba(255, 255, 255, 0.12); + -webkit-animation: rs-up 0.26s cubic-bezier(0.22, 1, 0.36, 1) both; + animation: rs-up 0.26s cubic-bezier(0.22, 1, 0.36, 1) both; + box-sizing: border-box; +} + +.rs-sheet.theme-sepia { + background: linear-gradient(180deg, #f6edd9 0%, #efe3cb 100%); + border-top-color: rgba(120, 80, 40, 0.18); +} + +.rs-sheet.theme-light { + background: linear-gradient(180deg, #faf8ff 0%, #f0ebf8 100%); + border-top-color: rgba(30, 22, 48, 0.1); +} + +@-webkit-keyframes rs-up { + from { -webkit-transform: translateY(100%); transform: translateY(100%); } + to { -webkit-transform: translateY(0); transform: translateY(0); } +} + +@keyframes rs-up { + from { -webkit-transform: translateY(100%); transform: translateY(100%); } + to { -webkit-transform: translateY(0); transform: translateY(0); } +} + +.rs-handle { + width: 40px; + height: 4px; + border-radius: 999px; + background: rgba(255, 255, 255, 0.2); + margin: 0 auto 14px; +} + +.theme-sepia .rs-handle, +.theme-light .rs-handle { + background: rgba(0, 0, 0, 0.14); +} + +.rs-title { + display: block; + text-align: center; + font-size: 20px; + font-weight: 700; + color: #faf7ff; +} + +.theme-sepia .rs-title { color: #3d2f1f; } +.theme-light .rs-title { color: #1e1630; } + +.rs-sub { + display: block; + text-align: center; + margin-top: 4px; + margin-bottom: 18px; + font-size: 13px; + color: #b4a9c8; +} + +.theme-sepia .rs-sub { color: #8a7358; } +.theme-light .rs-sub { color: #6d6286; } + +.rs-row { + margin-bottom: 14px; +} + +.rs-label { + display: block; + margin-bottom: 8px; + font-size: 13px; + color: #b4a9c8; +} + +.theme-sepia .rs-label, +.theme-light .rs-label { + color: inherit; + opacity: 0.7; +} + +.rs-seg { + display: -webkit-flex; + display: flex; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; +} + +.rs-seg button { + min-width: 52px; + height: 40px; + padding: 0 12px; + margin-right: 8px; + margin-bottom: 8px; + border-radius: 12px; + background: rgba(255, 255, 255, 0.06); + border: 1px solid rgba(255, 255, 255, 0.1); + color: #f3eefc; + font-size: 14px; +} + +.theme-sepia .rs-seg button, +.theme-light .rs-seg button { + background: rgba(0, 0, 0, 0.04); + border-color: rgba(0, 0, 0, 0.08); + color: inherit; +} + +.rs-seg button.on { + border-color: #ff7ab6; + color: #ff7ab6; + background: rgba(255, 122, 182, 0.12); +} + +.rs-actions { + margin-top: 8px; + padding-top: 8px; + border-top: 1px solid rgba(255, 255, 255, 0.08); +} + +.rs-cap { + margin: 10px 2px 0; + font-size: 11px; + color: var(--r-muted); + letter-spacing: 0.02em; +} + +.rs-section { + margin: 14px 2px 4px; + font-size: 12px; + font-weight: 700; + letter-spacing: 0.14em; + color: var(--r-accent); + text-transform: uppercase; +} + +.cam-mask, +.journal-mask { + position: fixed; + inset: 0; + z-index: 80; + background: rgba(0, 0, 0, 0.72); + display: -webkit-flex; + display: flex; + -webkit-align-items: flex-end; + align-items: flex-end; + -webkit-justify-content: center; + justify-content: center; +} + +.cam-sheet, +.journal-sheet { + width: 100%; + max-width: 520px; + max-height: 92%; + overflow: auto; + padding: 18px 16px 28px; + border-radius: 18px 18px 0 0; + background: #16121f; + color: #f3eefc; + box-sizing: border-box; +} + +.cam-title, +.journal-sheet .rs-title { + font-size: 18px; + font-weight: 700; +} + +.cam-sub { + margin-top: 4px; + font-size: 12px; + color: #b4a9c8; +} + +.cam-stage { + position: relative; + margin-top: 12px; + width: 100%; + padding-top: 133%; + border-radius: 14px; + overflow: hidden; + background: #0a0910; +} + +.cam-video, +.cam-canvas, +.cam-preview { + position: absolute; + left: 0; + top: 0; + width: 100%; + height: 100%; + object-fit: cover; +} + +.cam-tip { + margin-top: 10px; + font-size: 12px; + color: #b4a9c8; +} + +.cam-actions { + margin-top: 14px; + display: -webkit-flex; + display: flex; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; + gap: 8px; + -webkit-justify-content: center; + justify-content: center; +} + +.journal-input { + display: block; + width: 100%; + margin-top: 12px; + padding: 12px; + border-radius: 12px; + border: 1px solid rgba(255, 255, 255, 0.12); + background: rgba(255, 255, 255, 0.04); + color: inherit; + resize: vertical; + min-height: 120px; + box-sizing: border-box; +} + +.drawer-tabs { + display: -webkit-flex; + display: flex; + margin-top: 10px; + -webkit-flex-wrap: wrap; + flex-wrap: wrap; +} + +.drawer-tab { + -webkit-flex: 1 1 22%; + flex: 1 1 22%; + min-width: 64px; + height: 36px; + margin: 0 6px 6px 0; + border-radius: 10px; + background: rgba(255, 255, 255, 0.04); + border: 1px solid rgba(255, 255, 255, 0.08); + color: #b4a9c8; + font-size: 12px; +} + +.drawer-tab.on { + background: rgba(255, 122, 182, 0.12); + border-color: rgba(255, 122, 182, 0.35); + color: #ff7ab6; +} + +.note-item { + display: block; + width: 100%; + text-align: left; + padding: 12px 10px; + margin-bottom: 8px; + border-radius: 12px; + background: var(--r-soft); + border: 1px solid var(--r-border); + color: inherit; +} + +.note-item-title { + display: block; + font-size: 13px; + font-weight: 600; + color: var(--r-text); +} + +.note-item-body { + display: block; + margin-top: 4px; + font-size: 12px; + color: var(--r-muted); + line-height: 1.45; +} + +.note-item-actions { + display: -webkit-flex; + display: flex; + gap: 8px; + margin-top: 8px; +} + +.note-chip { + padding: 4px 10px; + border-radius: 999px; + font-size: 11px; + background: rgba(255, 122, 182, 0.12); + border: 1px solid rgba(255, 122, 182, 0.3); + color: #ff7ab6; +} + +.note-chip.ghost { + background: rgba(255, 255, 255, 0.04); + border-color: rgba(255, 255, 255, 0.12); + color: var(--r-muted); +} + +.rs-action { + display: block; + width: 100%; + height: 44px; + margin-bottom: 8px; + border-radius: 12px; + background: rgba(255, 122, 182, 0.14); + border: 1px solid rgba(255, 122, 182, 0.35); + color: #ffb4d6; + font-size: 14px; + font-weight: 600; +} + +.rs-action.ghost { + background: rgba(255, 255, 255, 0.04); + border-color: rgba(255, 255, 255, 0.1); + color: #b4a9c8; + font-weight: 500; +} + +@-webkit-keyframes aurora { + 0%, 100% { -webkit-transform: translateY(0) scale(1); transform: translateY(0) scale(1); } + 50% { -webkit-transform: translateY(18px) scale(1.06); transform: translateY(18px) scale(1.06); } +} + +@keyframes aurora { + 0%, 100% { -webkit-transform: translateY(0) scale(1); transform: translateY(0) scale(1); } + 50% { -webkit-transform: translateY(18px) scale(1.06); transform: translateY(18px) scale(1.06); } +} diff --git a/apps/miniprogram/xhs/tool/book.html b/apps/miniprogram/xhs/tool/book.html new file mode 100644 index 0000000..9f8f36d --- /dev/null +++ b/apps/miniprogram/xhs/tool/book.html @@ -0,0 +1,196 @@ + + + + + + 异度星球 + + + +
+ + + + + + + +
+
+
+

正在打开…

+
+
+ + + + diff --git a/apps/miniprogram/xhs/tool/book/book-data.js b/apps/miniprogram/xhs/tool/book/book-data.js new file mode 100644 index 0000000..a8e2380 --- /dev/null +++ b/apps/miniprogram/xhs/tool/book/book-data.js @@ -0,0 +1,116 @@ +// Auto-generated by scripts/build_book_data.py — do not edit by hand. +var BOOK_DATA = { + "id": "nomad-solopreneur", + "title": "数字游民 · 一人公司小册", + "subtitle": "写给想把生活与工作重新排布的人", + "author": "Eric的云游日记", + "cover_emoji": "🌏", + "description": "数字游民与一人公司行动地图:地理套利、技能变现、内容资产与30天清单。", + "tags": [ + "数字游民", + "一人公司", + "远程工作", + "副业" + ], + "chapter_count": 16, + "word_count": 3390, + "is_free": true, + "chapters": [ + { + "id": "c1", + "title": "写在前面", + "order": 1, + "content": "> 写给想把生活与工作重新排布的人 \n> 整理自 Eric的云游日记 · 仅供参考 · 持续更新\n\n---\n\n## 写在前面\n\n\n你手里这份小册,不是「一夜暴富教程」,而是一份**把技能做成可带走的收入**的行动地图。\n\n数字游民(Digital Nomad)的本质很简单:\n\n- 收入主要来自互联网与远程协作\n- 人不被一座城市、一份坐班绑死\n- 用**地理套利**把收入换成更舒服的生活与节奏\n\n一人公司(Solopreneur)则是另一半拼图:\n\n| 维度 | 为什么适合普通人 |\n|------|------------------|\n| 启动成本 | 一部电脑 + 稳定网络就能开工 |\n| 交付形态 | 内容、咨询、小产品、远程服务 |\n| 商业模式 | 少而精的客户,或可复用的数字资产 |\n| 时间自由 | 交付可异步,不必坐班打卡 |\n| 地理套利 | 在生活成本友好的城市,也能稳住现金流 |\n\n**声明:**\n\n- 文中不涉及收费课程强推,也不做账号买卖中介\n- 平台与税务规则会变,请以官方最新政策为准\n- 灰色手段风险极高,后文只作踩坑警示,不鼓励模仿\n\n一个人走得快,一群人走得远。欢迎把这份小册当成随身笔记本,边读边改成你自己的版本。\n\n---\n" + }, + { + "id": "c2", + "title": "目录", + "order": 2, + "content": "## 目录\n\n> 请用右上角「目」打开章节列表跳转。\n\n" + }, + { + "id": "c3", + "title": "一、为什么普通人适合做「一人公司」", + "order": 3, + "content": "## 一、为什么普通人适合做「一人公司」\n\n\n### 1.1 杠杆变了\n\n过去普通人创业,往往先要资金、团队、仓库。今天更常见的路径是:\n\n- 先卖**时间与专业**(咨询、远程岗位、项目制)\n- 再沉淀成**可复用资产**(模板、手册、小工具、课程笔记)\n- 最后用资产降低「必须人肉交付」的比例\n\n一人公司不是「单打独斗很酷」,而是:**用最小组织,把价值交付跑通**。\n\n### 1.2 你真正卖的是什么\n\n多数成功的一人公司,卖的不是「神秘方法」,而是:\n\n1. **确定性**:帮客户少踩坑、少决策成本 \n2. **结果感**:交付物清晰(文档、方案、成品) \n3. **信任**:真实经历与稳定输出 \n\n如果你还在找「风口」,不如先问:我过去三年反复帮别人解决的问题是什么?\n\n### 1.3 三种起步形态\n\n1. **远程岗位 / 项目制**:最稳,先换现金流 \n2. **内容 + 产品**:把方法论写成可售卖资产 \n3. **小工具 / 自动化**:用产品服务一小群人 \n\n三种可以叠加,但新手建议:**先有一个能稳定收款的主引擎**。\n\n---\n" + }, + { + "id": "c4", + "title": "二、数字游民视角:地理套利与生活设计", + "order": 4, + "content": "## 二、数字游民视角:地理套利与生活设计\n\n\n### 2.1 什么是地理套利\n\n数字游民最本质的优势,不是「环球旅行发朋友圈」,而是:\n\n**高购买力收入 × 友好生活成本地区 = 更大的自由现金流**\n\n常见组合:\n\n- 远程收入 → 在国内三四线 / 生活成本友好城市生活 \n- 错峰旅居:淡季交通与房租更松 \n- 把「城市」当成可切换的操作系统,而不是身份标签 \n\n国内常见第一站:气候友好、物价相对友好、网络与快递顺畅的城市。出国旅居请自行评估安全、签证与医疗,不要用幸存者偏差安慰自己。\n\n### 2.2 生活设计先于「逃逸」\n\n真正可持续的游民生活,通常先回答:\n\n1. 每月**最低生存成本**是多少? \n2. 收入波动时,能撑几个月? \n3. 健康、社交、专注环境如何保障? \n\n「先辞职再想办法」很少是好策略。更稳的是:副业跑通 → 缓冲金到位 → 再调整工作形态。\n\n### 2.3 节奏比地点更重要\n\n换城市解决不了拖延与分心。游民需要的是:\n\n- 固定的深度工作时段 \n- 可随身带走的工具与资料 \n- 每周一次复盘:收入、精力、关系 \n\n地点是风景,节奏才是系统。\n\n---\n" + }, + { + "id": "c5", + "title": "三、选一条可带走的能力:技能盘点", + "order": 5, + "content": "## 三、选一条可带走的能力:技能盘点\n\n\n### 3.1 能力四象限\n\n把你的技能放进四个格子:\n\n| | 你喜欢 | 你不喜欢 |\n|--|--------|----------|\n| **别人愿意付费** | ★ 优先发展 | 可短期现金牛 |\n| **别人不愿付费** | 爱好,控制投入 | 尽快减少 |\n\n一人公司的主航道,尽量落在「喜欢 × 可付费」。\n\n### 3.2 可带走能力的特征\n\n- 不依赖本地实体店面 \n- 交付可线上完成或可邮寄数字化 \n- 结果可验证(作品集、案例、前后对比) \n\n例如:写作与编辑、设计与演示、研究与报告、自动化与小工具、教学与陪跑、运营与内容策划。\n\n### 3.3 写出你的「一句话供给」\n\n模板:\n\n> 我帮助【谁】,在【场景】下,完成【结果】,方式是【方法】。\n\n写不清楚,就很难定价,也很难被转介绍。\n\n---\n" + }, + { + "id": "c6", + "title": "四、收入结构:现金牛、被动底座与试验田", + "order": 6, + "content": "## 四、收入结构:现金牛、被动底座与试验田\n\n\n### 4.1 三种发动机\n\n成熟一点的一人公司,收入通常分层:\n\n```\n远程工作 / 接单(现金牛)\n +\n可复用数字产品(被动底座)\n +\n试验中的新产品(试验田)\n────────────────\n更稳的自由现金流\n```\n\n- **现金牛**:保证这个月能活 \n- **被动底座**:睡后仍可能产生的复利 \n- **试验田**:允许失败的小预算探索 \n\n### 4.2 别过早「只做被动」\n\n被动收入大多是主动交付的副产品。先有人愿意为你的时间付钱,再谈产品化。\n\n### 4.3 每周收入复盘三个数\n\n1. 本周进账 \n2. 本周有效深度工作小时 \n3. 下周唯一最重要目标 \n\n简单到能坚持,比复杂表格有用。\n\n---\n" + }, + { + "id": "c7", + "title": "五、内容资产:把经历写成可复用产品", + "order": 7, + "content": "## 五、内容资产:把经历写成可复用产品\n\n\n### 5.1 内容不是表演,是资产生产线\n\n你写过的踩坑、清单、模板、复盘,都可以变成:\n\n- 公开笔记(建立信任) \n- 付费手册 / 模板包 \n- 陪跑与咨询的「说明书」 \n\n### 5.2 最小内容系统\n\n每周固定产出即可,例如:\n\n1. 1 篇深度复盘(问题 → 过程 → 结论) \n2. 3 条短更新(工具、书摘、工作流) \n3. 1 次整理:把旧笔记升级成模板 \n\n持续比爆款重要。\n\n### 5.3 产品化三步\n\n1. **文档化**:把口头经验写成步骤 \n2. **模板化**:别人填空就能用 \n3. **服务化**:仍搞不定的人,可加咨询档 \n\n从文档走到服务,客单价自然抬升。\n\n---\n" + }, + { + "id": "c8", + "title": "六、远程工作与接单:先稳住现金流", + "order": 8, + "content": "## 六、远程工作与接单:先稳住现金流\n\n\n### 6.1 远程岗位的好处\n\n- 收入相对可预期 \n- 强迫你建立异步协作习惯 \n- 为一人公司提供「安全垫」 \n\n### 6.2 接单的注意事项\n\n- 范围写清楚(Scope) \n- 修改次数与交付节点写进约定 \n- 预付款 / 阶段款,避免尾款黑洞 \n\n### 6.3 作品集怎么做才有用\n\n不要堆数量,展示:\n\n1. 背景与约束 \n2. 你做了什么关键决策 \n3. 可感知的结果 \n\n三到五个扎实案例,胜过二十个截图。\n\n---\n" + }, + { + "id": "c9", + "title": "七、工具栈:够用就好,别被软件绑架", + "order": 9, + "content": "## 七、工具栈:够用就好,别被软件绑架\n\n\n### 7.1 最小工具箱\n\n- 笔记与知识库(能全文搜索) \n- 任务清单(今天只看三件事) \n- 文档与云盘(可跨设备) \n- 日历(保护深度工作块) \n\n能跑通闭环之前,少追新工具。\n\n### 7.2 自动化的正确时机\n\n当你第三次重复同一操作,再自动化。过早自动化,等于给错误流程加速。\n\n### 7.3 AI 的用法\n\n适合:\n\n- 起草、摘要、对照检查 \n- 生成提纲与检查清单 \n\n不适合:\n\n- 代替你对客户结果负责 \n- 输出你自己都看不懂的方案 \n\nAI 是副驾驶,方向盘还在你手里。\n\n---\n" + }, + { + "id": "c10", + "title": "八、时间与精力:副业实验的正确姿势", + "order": 10, + "content": "## 八、时间与精力:副业实验的正确姿势\n\n\n### 8.1 副业实验协议\n\n对大多数上班族:\n\n1. 每周固定 6~10 小时实验窗 \n2. 连续 8~12 周再评估去留 \n3. 用「可验证里程碑」代替感觉 \n\n例如:完成作品集、收到第一笔小额付款、沉淀出第一份可售模板。\n\n### 8.2 精力管理三原则\n\n- 难事先做 \n- 社交型任务集中处理 \n- 睡眠与运动是生产力,不是奖励 \n\n### 8.3 防止自我压榨\n\n一人公司最常见的失败不是没单,而是燃尽。给自己定:\n\n- 每周休息日不可谈判 \n- 深度工作有上限(健康优先) \n\n---\n" + }, + { + "id": "c11", + "title": "九、定价、边界与客户管理", + "order": 11, + "content": "## 九、定价、边界与客户管理\n\n\n### 9.1 定价从成本倒推不够\n\n还要看:\n\n- 你替代了客户多少决策成本 \n- 市场同类交付的价格带 \n- 你是否提供售后与迭代 \n\n早期可以略低换案例,但要有「涨价日程」。\n\n### 9.2 边界清单(建议抄进笔记)\n\n- 不接什么类型的需求 \n- 沟通时段 \n- 修改次数 \n- 延期如何处理 \n\n边界清晰,关系更久。\n\n### 9.3 客户分级\n\n- A:愿付费、沟通顺、可复购 \n- B:可做,但不优先 \n- C:消耗大、价值低 → 礼貌拒绝 \n\n一人公司的自由,很大程度来自「会拒绝」。\n\n---\n" + }, + { + "id": "c12", + "title": "十、合规与财务:别等到卡款才慌", + "order": 12, + "content": "## 十、合规与财务:别等到卡款才慌\n\n\n### 10.1 基础习惯\n\n- 收支分账记录 \n- 合同 / 聊天记录留存 \n- 发票与税务按你所在地规则处理 \n\n### 10.2 缓冲金\n\n建议至少准备:**3~6 个月最低生活成本**。游民生活波动更大,缓冲金是自由的地基。\n\n### 10.3 别碰的灰区\n\n账号买卖、虚假流量、欺诈性承诺、违规跨境操作等,短期看似捷径,长期是地雷。知道即可,不要当主策略。\n\n---\n" + }, + { + "id": "c13", + "title": "十一、赛道灵感:普通人能落地的方向", + "order": 13, + "content": "## 十一、赛道灵感:普通人能落地的方向\n\n\n### 11.1 兜底方向(示例)\n\n1. **写作与内容策划**:帮小团队做选题、文案、手册 \n2. **效率与自动化**:帮人整理工作流、表格、小脚本 \n3. **垂直咨询**:你有真实从业经验的领域陪跑 \n\n### 11.2 「元能力」:教别人复盘\n\n如果你暂时没有强垂直:\n\n> 把「如何建立可持续的一人工作系统」本身做成内容与产品。\n\n但请建立在真实实践上,而不是空转概念。\n\n### 11.3 本地优势也能在线卖\n\n你熟悉的城市、行业、语言、审美,都可以变成线上可交付的信息差产品——关键是**可验证、可复用、可持续更新**。\n\n---\n" + }, + { + "id": "c14", + "title": "十二、从副业到一人公司:扩展路径", + "order": 14, + "content": "## 十二、从副业到一人公司:扩展路径\n\n\n### 12.1 升级阶梯\n\n```\n副业实验\n → 稳定月入覆盖部分生活成本\n → 产品化(模板 / 手册)\n → 提高客单价或减少人肉交付\n → 可选:减班 / 远程 / 旅居\n```\n\n每一步都要有数字,而不是口号。\n\n### 12.2 一人公司的组织原则\n\n- 默认外包非核心 \n- 文档先于口头约定 \n- 系统优先于英雄主义加班 \n\n### 12.3 收入拼图(理想态)\n\n```\n远程工作 / 接单(现金牛)\n +\n数字产品 / 模板(被动底座)\n +\n小社群或陪跑(高信任)\n────────────────\n地理套利下的自由现金流\n```\n\n---\n" + }, + { + "id": "c15", + "title": "十三、30 天行动清单", + "order": 15, + "content": "## 十三、30 天行动清单\n\n\n### 第 1 周:盘点与定位\n\n- [ ] 写出技能四象限 \n- [ ] 完成「一句话供给」 \n- [ ] 算出每月最低生活成本与缓冲金缺口 \n\n### 第 2 周:作品与可信度\n\n- [ ] 整理 3 个案例(或练习项目) \n- [ ] 搭一个简单主页 / 简介页(不必复杂) \n- [ ] 公开更新 2 次真实复盘 \n\n### 第 3 周:第一次交易\n\n- [ ] 给出明确报价与边界 \n- [ ] 完成 1 次小额交付或预售模板 \n- [ ] 记录耗时,为定价校准 \n\n### 第 4 周:系统化\n\n- [ ] 固化每周工作节奏 \n- [ ] 把重复内容做成模板 \n- [ ] 复盘:保留 / 调整 / 放弃什么 \n\n完成不了全部也没关系——**完成「第一次诚实交付」比完美计划重要。**\n\n---\n" + }, + { + "id": "c16", + "title": "十四、结语:自由是设计出来的", + "order": 16, + "content": "## 十四、结语:自由是设计出来的\n\n\n书店里很少有一本「刚好适合你」的人生说明书。这本小册只做一件事:把分散的经验,收成一份可执行的底稿。\n\n数字游民与一人公司改变生活的方式,通常不是戏剧性的一夜翻盘,而是:\n\n> 某天你发现:收入不再完全绑在工位上; \n> 你的笔记、模板与信誉,开始替你工作; \n> 你可以选择城市,而不是被城市选择。\n\n它也会伴随试错:报价踩坑、客户消耗、自我管理失败……这些都是真实成本,不是营销话术。\n\n**给你的最终建议:**\n\n1. 把一人公司当**长期资产**,不是彩票 \n2. 先稳住**现金牛**,再谈被动与旅居 \n3. 用文档与边界保护精力 \n4. 小步产品化,持续复盘 \n5. 灰产捷径可以「知道」,但不要当成主策略 \n\n后续可能更新:选题与定价实验、远程协作清单、一人公司财务表等。\n\n---\n\n### 附录 A:关键概念速查\n\n| 项目 | 说明 |\n|------|------|\n| 地理套利 | 收入与生活成本不在同一「坐标系」 |\n| 现金牛 | 短期稳定进账的引擎 |\n| 被动底座 | 可复用、可重复销售的数字资产 |\n| 试验田 | 小预算试错区 |\n| 一人公司 | 以个人为核心的最小商业系统 |\n| 缓冲金 | 3~6 个月最低生活成本建议 |\n\n### 附录 B:读法建议\n\n1. 先通读「写在前面」与「结语」定方向 \n2. 按 30 天清单执行,而不是只收藏 \n3. 每章只带走一个可立刻做的动作 \n\n---\n\n*完 · 愿你把自由设计成可执行的系统。*\n" + } + ] +}; diff --git a/apps/miniprogram/xhs/tool/book/markdown.js b/apps/miniprogram/xhs/tool/book/markdown.js new file mode 100644 index 0000000..564ab46 --- /dev/null +++ b/apps/miniprogram/xhs/tool/book/markdown.js @@ -0,0 +1,274 @@ +/** + * Lightweight markdown → HTML for offline 小红书小工具. + * No eval / network / Worker. + */ +(function (global) { + function themeColors(theme) { + if (theme === "light") { + return { + text: "#1e1630", + muted: "#6d6286", + accent: "#db2777", + accentSoft: "rgba(219,39,119,.1)", + code: "#7c3aed", + strong: "#120f1d", + }; + } + if (theme === "sepia") { + return { + text: "#3d2f1f", + muted: "#8a7358", + accent: "#c2410c", + accentSoft: "rgba(194,65,12,.12)", + code: "#c2410c", + strong: "#2a1f14", + }; + } + return { + text: "#f3eefc", + muted: "#b4a9c8", + accent: "#ff7ab6", + accentSoft: "rgba(255,122,182,.14)", + code: "#c4b5fd", + strong: "#ffffff", + }; + } + + function escapeHtml(s) { + return String(s) + .replace(/&/g, "&") + .replace(//g, ">"); + } + + function inline(s, c) { + return escapeHtml(s) + .replace(/\*\*(.+?)\*\*/g, '$1') + .replace(/\*(.+?)\*/g, '$1') + .replace(/`([^`]+)`/g, '$1'); + } + + function markdownToHtml(src, opts) { + opts = opts || {}; + var dropCap = opts.dropCap !== false; + var c = themeColors(opts.theme || "dark"); + var text = String(src || "").replace(/\r\n/g, "\n"); + text = text.replace(//g, ""); + text = text.replace(//gi, "> 🎬 视频请在异度世界公众号查看"); + text = text.replace(//gi, "> 🖼 配图已省略(离线版)"); + text = text.replace(/!\[[^\]]*\]\([^)]+\)/g, "> 🖼 配图已省略(离线版)"); + + var lines = text.split("\n"); + var out = []; + var inCode = false; + var codeBuf = []; + var inUl = false; + var inOl = false; + var olIndex = 0; + var inQuote = false; + var quoteBuf = []; + var paraCount = 0; + var skippedChapterTitle = false; + + function closeLists() { + if (inUl) { + out.push("
"); + inUl = false; + } + if (inOl) { + out.push(""); + inOl = false; + olIndex = 0; + } + } + + function flushQuote() { + if (!inQuote) return; + var body = quoteBuf.map(function (q) { + return inline(q, c); + }).join("
"); + out.push('
' + body + "
"); + inQuote = false; + quoteBuf = []; + } + + function isTableSep(line) { + return /^\s*\|?[\s:-]+\|[\s|:-]*\|?\s*$/.test(line); + } + + function splitRow(line) { + var s = line.trim(); + if (s.charAt(0) === "|") s = s.slice(1); + if (s.charAt(s.length - 1) === "|") s = s.slice(0, -1); + return s.split("|").map(function (cell) { + return cell.trim(); + }); + } + + function renderTable(rows) { + if (!rows.length) return; + var html = ['
']; + rows[0].forEach(function (cell) { + html.push(""); + }); + html.push(""); + for (var r = 1; r < rows.length; r++) { + html.push(""); + rows[r].forEach(function (cell) { + html.push(""); + }); + html.push(""); + } + html.push("
" + inline(cell, c) + "
" + inline(cell, c) + "
"); + out.push(html.join("")); + } + + for (var i = 0; i < lines.length; i++) { + var raw = lines[i]; + var line = raw; + + if (/^```/.test(line)) { + flushQuote(); + closeLists(); + if (inCode) { + out.push('
' + escapeHtml(codeBuf.join("\n")) + "
"); + codeBuf = []; + inCode = false; + } else { + inCode = true; + } + continue; + } + if (inCode) { + codeBuf.push(line); + continue; + } + + // GFM table + if ( + line.indexOf("|") !== -1 && + i + 1 < lines.length && + isTableSep(lines[i + 1]) + ) { + flushQuote(); + closeLists(); + var rows = [splitRow(line)]; + i += 1; // skip separator + while (i + 1 < lines.length && lines[i + 1].indexOf("|") !== -1 && lines[i + 1].trim()) { + i += 1; + if (isTableSep(lines[i])) continue; + rows.push(splitRow(lines[i])); + } + renderTable(rows); + continue; + } + + if (/^\s*>\s?/.test(line)) { + closeLists(); + inQuote = true; + quoteBuf.push(line.replace(/^\s*>\s?/, "")); + continue; + } + if (inQuote) flushQuote(); + + if (/^\s*---+\s*$/.test(line) || /^\s*\*\*\*+\s*$/.test(line)) { + closeLists(); + out.push('
'); + continue; + } + + var h1 = /^#\s+(.+)$/.exec(line); + if (h1) { + closeLists(); + if (!skippedChapterTitle) { + skippedChapterTitle = true; + continue; + } + out.push("

" + inline(h1[1], c) + "

"); + continue; + } + var h2 = /^##\s+(.+)$/.exec(line); + if (h2) { + closeLists(); + // Chapter title already shown in reader chrome — skip first ## + if (!skippedChapterTitle) { + skippedChapterTitle = true; + continue; + } + out.push("

" + inline(h2[1], c) + "

"); + continue; + } + var h3 = /^###\s+(.+)$/.exec(line); + if (h3) { + closeLists(); + out.push("

" + inline(h3[1], c) + "

"); + continue; + } + + var task = /^\s*[-*+]\s+\[([ xX])\]\s+(.+)$/.exec(line); + if (task) { + if (inOl) { + out.push(""); + inOl = false; + olIndex = 0; + } + if (!inUl) { + out.push('
'); + inUl = true; + } + var mark = /x/i.test(task[1]) ? "☑" : "☐"; + out.push("
" + mark + " " + inline(task[2], c) + "
"); + continue; + } + + var ul = /^\s*[-*+]\s+(.+)$/.exec(line); + if (ul) { + if (inOl) { + out.push("
"); + inOl = false; + olIndex = 0; + } + if (!inUl) { + out.push('
'); + inUl = true; + } + out.push("
• " + inline(ul[1], c) + "
"); + continue; + } + var ol = /^\s*(\d+)\.\s+(.+)$/.exec(line); + if (ol) { + if (inUl) { + out.push("
"); + inUl = false; + } + if (!inOl) { + out.push('
'); + inOl = true; + olIndex = 0; + } + olIndex += 1; + out.push("
" + olIndex + ". " + inline(ol[2], c) + "
"); + continue; + } + + if (!line.trim()) { + closeLists(); + continue; + } + + closeLists(); + paraCount += 1; + var cls = dropCap && paraCount === 1 ? ' class="dropcap"' : ""; + out.push("" + inline(line.trim(), c) + "

"); + } + + flushQuote(); + closeLists(); + if (inCode) { + out.push('
' + escapeHtml(codeBuf.join("\n")) + "
"); + } + return out.join(""); + } + + global.MarkdownLite = { markdownToHtml: markdownToHtml, themeColors: themeColors }; +})(window); diff --git a/apps/miniprogram/xhs/tool/book/xhs-bridge.js b/apps/miniprogram/xhs/tool/book/xhs-bridge.js new file mode 100644 index 0000000..ee7811f --- /dev/null +++ b/apps/miniprogram/xhs/tool/book/xhs-bridge.js @@ -0,0 +1,639 @@ +/** + * Official XHS miniTool bridge helpers (Chrome 61 / ES2017). + * Prefer window.xhs.miniTool Storage (9.46+); fall back to localStorage. + */ +(function (global) { + "use strict"; + + var STORAGE_MIN = 9460; + var COMMENT_MIN = 9490; + var FILE_MIN = 9490; + + function readBuildVersion(launchOptions) { + var env = launchOptions && launchOptions.miniToolEnv; + return Number(env && env.buildVersion) || 0; + } + + function getClientVersion(buildVersion) { + return Math.floor((Number(buildVersion) || 0) / 1000); + } + + function isClientVersionAtLeast(buildVersion, minimum) { + return getClientVersion(buildVersion) >= minimum; + } + + function getMiniTool() { + return global.xhs && global.xhs.miniTool ? global.xhs.miniTool : null; + } + + function getBuildVersion() { + var xhs = global.xhs; + var sync = readBuildVersion(xhs && xhs.launchOptions); + if (sync) { + return Promise.resolve(sync); + } + var mt = getMiniTool(); + if (!mt || typeof mt.getLaunchOptions !== "function") { + return Promise.resolve(0); + } + return Promise.resolve(mt.getLaunchOptions()) + .then(function (opts) { + return readBuildVersion(opts); + }) + .catch(function () { + return 0; + }); + } + + function setLocalData(key, data, encrypt) { + var serialized; + try { + serialized = JSON.stringify(data); + } catch (e) { + return Promise.resolve(false); + } + if (typeof serialized !== "string") return Promise.resolve(false); + var useEncrypt = !!encrypt; + + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + isClientVersionAtLeast(buildVersion, STORAGE_MIN) && + mt && + typeof mt.setStorage === "function" + ) { + var payload = { key: key, data: serialized }; + if (useEncrypt) payload.encrypt = true; + return Promise.resolve(mt.setStorage(payload)) + .then(function () { + return true; + }) + .catch(function () { + return writeBrowser(key, serialized); + }); + } + return writeBrowser(key, serialized); + }); + } + + function writeBrowser(key, serialized) { + try { + global.localStorage.setItem(key, serialized); + return true; + } catch (e) { + return false; + } + } + + function getLocalData(key, fallback, encrypt) { + var useEncrypt = !!encrypt; + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + isClientVersionAtLeast(buildVersion, STORAGE_MIN) && + mt && + typeof mt.getStorage === "function" + ) { + var payload = { key: key }; + if (useEncrypt) payload.encrypt = true; + return Promise.resolve(mt.getStorage(payload)) + .then(function (res) { + var raw = res && res.data; + if (raw != null && raw !== "") { + try { + return JSON.parse(raw); + } catch (e) { + return fallback; + } + } + // Retry without encrypt (migration), then browser + if (useEncrypt) { + return Promise.resolve(mt.getStorage({ key: key })) + .then(function (res2) { + var raw2 = res2 && res2.data; + if (raw2 != null && raw2 !== "") { + try { + var parsed = JSON.parse(raw2); + return setLocalData(key, parsed, true).then(function () { + return parsed; + }); + } catch (e2) { + return readBrowser(key, fallback); + } + } + return readBrowser(key, fallback); + }) + .catch(function () { + return readBrowser(key, fallback); + }); + } + var fromBrowser = readBrowser(key, null); + if (fromBrowser == null) return fallback; + return writeNative(mt, key, JSON.stringify(fromBrowser), false).then( + function () { + return fromBrowser; + }, + function () { + return fromBrowser; + } + ); + }) + .catch(function () { + return readBrowser(key, fallback); + }); + } + return readBrowser(key, fallback); + }); + } + + function writeNative(mt, key, serialized, encrypt) { + if (!mt || typeof mt.setStorage !== "function") { + return Promise.resolve(false); + } + var payload = { key: key, data: serialized }; + if (encrypt) payload.encrypt = true; + return Promise.resolve(mt.setStorage(payload)).then( + function () { + return true; + }, + function () { + return false; + } + ); + } + + function readBrowser(key, fallback) { + try { + var raw = global.localStorage.getItem(key); + if (raw == null || raw === "") return fallback; + return JSON.parse(raw); + } catch (e) { + return fallback; + } + } + + function removeLocalData(key) { + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + isClientVersionAtLeast(buildVersion, STORAGE_MIN) && + mt && + typeof mt.removeStorage === "function" + ) { + return Promise.resolve(mt.removeStorage({ key: key })) + .then(function () { + removeBrowser(key); + return true; + }) + .catch(function () { + return removeBrowser(key); + }); + } + return removeBrowser(key); + }); + } + + function clearLocalData() { + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + isClientVersionAtLeast(buildVersion, STORAGE_MIN) && + mt && + typeof mt.clearStorage === "function" + ) { + return Promise.resolve(mt.clearStorage()) + .then(function () { + clearBrowser(); + return true; + }) + .catch(function () { + return clearBrowser(); + }); + } + return clearBrowser(); + }); + } + + function removeBrowser(key) { + try { + global.localStorage.removeItem(key); + return true; + } catch (e) { + return false; + } + } + + function clearBrowser() { + try { + global.localStorage.clear(); + return true; + } catch (e) { + return false; + } + } + + function getLaunchOptions() { + var xhs = global.xhs; + if (xhs && xhs.launchOptions) { + return Promise.resolve(xhs.launchOptions); + } + var mt = getMiniTool(); + if (!mt || typeof mt.getLaunchOptions !== "function") { + return Promise.resolve(null); + } + return Promise.resolve(mt.getLaunchOptions()).catch(function () { + return null; + }); + } + + /** Read miniToolSnapshotInfo from launch options (comment re-entry, §3.9). */ + function readSnapshotInfo(launchOptions) { + if (!launchOptions) return null; + var raw = + launchOptions.miniToolSnapshotInfo || + (launchOptions.query && launchOptions.query.miniToolSnapshotInfo) || + (launchOptions.referrerInfo && + launchOptions.referrerInfo.miniToolSnapshotInfo) || + (launchOptions.extraData && launchOptions.extraData.miniToolSnapshotInfo); + if (!raw) return null; + if (typeof raw === "object") return raw; + try { + return JSON.parse(raw); + } catch (e) { + return null; + } + } + + function callApi(name, options) { + var mt = getMiniTool(); + if (!mt || typeof mt[name] !== "function") { + return Promise.reject({ errMsg: name + ":fail not available" }); + } + return Promise.resolve(mt[name](options || {})); + } + + function writeTempFile(dataUrl) { + return callApi("writeTempFile", { data: dataUrl }).then(function (res) { + return (res && res.filePath) || dataUrl; + }); + } + + function saveImageToPhotosAlbum(filePath) { + return callApi("saveImageToPhotosAlbum", { filePath: filePath }); + } + + function postNote(opts) { + return callApi("postNote", opts); + } + + function canPostComment(buildVersion) { + var mt = getMiniTool(); + return ( + isClientVersionAtLeast(buildVersion, COMMENT_MIN) && + mt && + typeof mt.interactionOpenApi === "function" + ); + } + + function postComment(payload, saveToAlbum) { + return callApi("interactionOpenApi", { + payload: payload, + saveToAlbum: saveToAlbum !== false + }); + } + + function getStorageInfo() { + return getBuildVersion().then(function (buildVersion) { + var mt = getMiniTool(); + if ( + !isClientVersionAtLeast(buildVersion, STORAGE_MIN) || + !mt || + typeof mt.getStorageInfo !== "function" + ) { + return null; + } + return Promise.resolve(mt.getStorageInfo()).catch(function () { + return null; + }); + }); + } + + function canUseFileSystem(buildVersion) { + var mt = getMiniTool(); + return ( + isClientVersionAtLeast(buildVersion, FILE_MIN) && + mt && + typeof mt.writeFile === "function" && + typeof mt.readFile === "function" + ); + } + + function getUserDataPath() { + return getLaunchOptions().then(function (opts) { + var env = opts && opts.miniToolEnv; + return (env && env.userDataPath) || ""; + }); + } + + function ensureDir(dirPath) { + var mt = getMiniTool(); + if (!mt || typeof mt.mkdir !== "function") { + return Promise.resolve(false); + } + return Promise.resolve(mt.mkdir({ dirPath: dirPath, recursive: true })) + .then(function () { + return true; + }) + .catch(function () { + return false; + }); + } + + function writeUtf8File(relativePath, data) { + return getBuildVersion().then(function (bv) { + if (!canUseFileSystem(bv)) { + return Promise.reject({ errMsg: "writeFile:fail version" }); + } + return getUserDataPath().then(function (root) { + if (!root) return Promise.reject({ errMsg: "writeFile:fail no path" }); + var rel = String(relativePath || "").replace(/^\/+/, ""); + var parts = rel.split("/"); + var dir = + parts.length > 1 ? root + "/" + parts.slice(0, -1).join("/") : root; + var filePath = root + "/" + rel; + return ensureDir(dir).then(function () { + return callApi("writeFile", { + filePath: filePath, + data: typeof data === "string" ? data : JSON.stringify(data), + encoding: "utf8" + }).then(function () { + return filePath; + }); + }); + }); + }); + } + + function appendUtf8File(relativePath, data) { + return getBuildVersion().then(function (bv) { + if (!canUseFileSystem(bv)) { + return Promise.reject({ errMsg: "appendFile:fail version" }); + } + var mt = getMiniTool(); + if (!mt || typeof mt.appendFile !== "function") { + // Fallback: read + write + return readUtf8File(relativePath).then(function (prev) { + return writeUtf8File( + relativePath, + (prev || "") + (typeof data === "string" ? data : String(data)) + ); + }); + } + return getUserDataPath().then(function (root) { + if (!root) return Promise.reject({ errMsg: "appendFile:fail no path" }); + var rel = String(relativePath || "").replace(/^\/+/, ""); + var parts = rel.split("/"); + var dir = + parts.length > 1 ? root + "/" + parts.slice(0, -1).join("/") : root; + var filePath = root + "/" + rel; + return ensureDir(dir).then(function () { + return callApi("appendFile", { + filePath: filePath, + data: typeof data === "string" ? data : String(data), + encoding: "utf8" + }).then(function () { + return filePath; + }); + }); + }); + }); + } + + function postVideoNote(opts) { + var videoRes = { video_url: opts.videoPath }; + if (opts.coverPath) videoRes.cover_url = opts.coverPath; + return callApi("postNote", { + title: opts.title, + content: opts.content, + pageType: "video_publish", + mediaInfo: { + video_resources: videoRes + } + }); + } + + function readUtf8File(relativePath) { + return getBuildVersion().then(function (bv) { + if (!canUseFileSystem(bv)) { + return Promise.resolve(null); + } + return getUserDataPath().then(function (root) { + if (!root) return null; + var filePath = root + "/" + String(relativePath || "").replace(/^\/+/, ""); + return callApi("readFile", { filePath: filePath, encoding: "utf8" }) + .then(function (res) { + return res && res.data != null ? res.data : null; + }) + .catch(function () { + return null; + }); + }); + }); + } + + /** Write dataURL to temp, then optionally persist via saveFile (9.49+). */ + function persistImage(dataUrl, relativePath) { + return writeTempFile(dataUrl).then(function (tempPath) { + return getBuildVersion().then(function (bv) { + var mt = getMiniTool(); + if ( + !relativePath || + !isClientVersionAtLeast(bv, FILE_MIN) || + !mt || + typeof mt.saveFile !== "function" + ) { + return tempPath; + } + return getUserDataPath().then(function (root) { + if (!root) return tempPath; + var dest = root + "/" + String(relativePath).replace(/^\/+/, ""); + var dir = dest.replace(/\/[^/]+$/, ""); + return ensureDir(dir).then(function () { + return callApi("saveFile", { + tempFilePath: tempPath, + filePath: dest + }) + .then(function (res) { + return (res && res.savedFilePath) || dest || tempPath; + }) + .catch(function () { + return tempPath; + }); + }); + }); + }); + }); + } + + function getFileStorageInfo() { + return getBuildVersion().then(function (bv) { + var mt = getMiniTool(); + if ( + !isClientVersionAtLeast(bv, FILE_MIN) || + !mt || + typeof mt.getFileStorageInfo !== "function" + ) { + return null; + } + return Promise.resolve(mt.getFileStorageInfo()).catch(function () { + return null; + }); + }); + } + + function unlinkFile(relativeOrAbsPath) { + return getBuildVersion().then(function (bv) { + var mt = getMiniTool(); + if ( + !isClientVersionAtLeast(bv, FILE_MIN) || + !mt || + typeof mt.unlink !== "function" + ) { + return false; + } + var path = String(relativeOrAbsPath || ""); + if (!path) return false; + var p = Promise.resolve(path); + if (path.indexOf("/") !== 0 && path.indexOf("usr") !== 0) { + p = getUserDataPath().then(function (root) { + return root ? root + "/" + path.replace(/^\/+/, "") : path; + }); + } + return p.then(function (filePath) { + return callApi("unlink", { filePath: filePath }) + .then(function () { + return true; + }) + .catch(function () { + return false; + }); + }); + }); + } + + function readDirList(relativeDir) { + return getBuildVersion().then(function (bv) { + var mt = getMiniTool(); + if ( + !isClientVersionAtLeast(bv, FILE_MIN) || + !mt || + typeof mt.readDir !== "function" + ) { + return []; + } + return getUserDataPath().then(function (root) { + if (!root) return []; + var dirPath = + root + + (relativeDir + ? "/" + String(relativeDir).replace(/^\/+|\/+$/g, "") + : ""); + return callApi("readDir", { dirPath: dirPath }) + .then(function (res) { + var files = (res && res.files) || []; + return files.map(function (f) { + if (typeof f === "string") { + return { name: f, path: dirPath + "/" + f }; + } + var name = f.name || f.fileName || String(f); + return { + name: name, + path: f.path || f.filePath || dirPath + "/" + name, + isDir: !!(f.isDir || f.isDirectory) + }; + }); + }) + .catch(function () { + return []; + }); + }); + }); + } + + function cleanupShareDir() { + return readDirList("share").then(function (files) { + var chain = Promise.resolve(0); + for (var i = 0; i < files.length; i++) { + (function (file) { + if (file.isDir) return; + chain = chain.then(function (n) { + return callApi("unlink", { filePath: file.path }) + .then(function () { + return n + 1; + }) + .catch(function () { + return n; + }); + }); + })(files[i]); + } + return chain; + }); + } + + /** Convert File / Blob to data URL (offline, no network). */ + function blobToDataUrl(blob) { + return new Promise(function (resolve, reject) { + if (!blob) { + reject({ errMsg: "blobToDataUrl:fail empty" }); + return; + } + try { + var reader = new FileReader(); + reader.onload = function () { + resolve(reader.result); + }; + reader.onerror = function () { + reject({ errMsg: "blobToDataUrl:fail read" }); + }; + reader.readAsDataURL(blob); + } catch (e) { + reject({ errMsg: "blobToDataUrl:fail " + (e && e.message) }); + } + }); + } + + global.XhsBridge = { + getBuildVersion: getBuildVersion, + getClientVersion: getClientVersion, + isClientVersionAtLeast: isClientVersionAtLeast, + setLocalData: setLocalData, + getLocalData: getLocalData, + removeLocalData: removeLocalData, + clearLocalData: clearLocalData, + getStorageInfo: getStorageInfo, + getFileStorageInfo: getFileStorageInfo, + getLaunchOptions: getLaunchOptions, + readSnapshotInfo: readSnapshotInfo, + writeTempFile: writeTempFile, + saveImageToPhotosAlbum: saveImageToPhotosAlbum, + postNote: postNote, + canPostComment: canPostComment, + postComment: postComment, + canUseFileSystem: canUseFileSystem, + getUserDataPath: getUserDataPath, + writeUtf8File: writeUtf8File, + appendUtf8File: appendUtf8File, + readUtf8File: readUtf8File, + persistImage: persistImage, + unlinkFile: unlinkFile, + readDirList: readDirList, + cleanupShareDir: cleanupShareDir, + blobToDataUrl: blobToDataUrl, + postVideoNote: postVideoNote, + getMiniTool: getMiniTool, + STORAGE_MIN: STORAGE_MIN, + COMMENT_MIN: COMMENT_MIN, + FILE_MIN: FILE_MIN + }; +})(window); diff --git a/apps/miniprogram/xhs/tool/icons/1psim.webp b/apps/miniprogram/xhs/tool/icons/1psim.webp new file mode 100644 index 0000000000000000000000000000000000000000..a64841a19818f8ead26f500917662e3726997305 GIT binary patch literal 3872 zcmV+*58v=oNk&E(4*&pHMM6+kP&il$0000G0001A003VA06|PpNaz9p009m;wr#7C zqoT;n5VHrs%nUJS-2?FQBs%KYcFY(u+aXQB4jE&2tNvQ0a#Miqz{Rk4$Vq88(d=PsS-s!*7xp4Ule6eA~o zIiIR<(5sF`aMLu_+lfj+r0S+==xxln<9t^o!Mwr@wuY2Nul2VlrSV@^#i2NG>09Sj zD!gpz5Zq*ZlS$cJN9J9j!C5aeDW9XUkxwk#$^?O{V7WMOEE5c_8FI-frCkg%s>;Dl zuKD450>b(cb8Mjf*i8xsQNI2EY3DORV$blOX{&xaLn0Gb4W1-k%QTj{Hju=9&IATi zJ%}6ZTL(>f+JJSAC>0#2!%6s8-^(F(%2xHYZn}HWHji@SyzG;g;BhHbi z&x;cy1J7oH$#tfhyn|^=QMcL5?C-9NNv5i2ws;)XmZ+G7HpfwIDazPp<0Ue^G;;AT z)H#x=X2LC*;Bq8KaBV4Sg!#Q891n??u_=;|u?^48d!@KU`OdTt*i=oM`3ZYNpX%8^ zu<1vIPxuD@BKRAEf3NYsOZeYa{Qm;}e{BlHm%z`fz~_bV^IGtEIrO~Z6v&Ih=XK%p()f9G___dmT?4)@ z17BByuZzLg_2BE0@O4%6x-fiQ8@?`&-dBLz7jbcIlM29n9Sf4)sN}ws1xNGur5x=| zVF**auLiy^h*nTIA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Urm_epug5=n5+@AV1gHwvGqI(ZbN{p5q`(>EWLe=6wfh5UPrJ2+5nw) zj!3M)M_?$8G+#s&1FaF{(abndk|4j*NrL{y7{j4{vI*4LfbBtTp1WTxI>9ErH-;}C z8T`ljUjyYOMk9y#tfJm=raB~@ zUY1b!I4$a;F{Itkxf8D6*kT0gDyQL9zT4V&=lcwTmIwM}Jirj(w0Vk{xD5u`0_2+U iNiGf&&suC6pY7sHq%{E+&Ea(}n9k{7Kj2wvSO5Sb7O4#Y literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/3x-ui.webp b/apps/miniprogram/xhs/tool/icons/3x-ui.webp new file mode 100644 index 0000000000000000000000000000000000000000..6ef85adf470884040df4309c59712843f96a0977 GIT binary patch literal 1458 zcmV;j1x@-=Nk&Gh1pok7MM6+kP&go-1pokW9{`;JDqsL$06vvKnnJis~G{>u7*{gU;r^dsm2`vKNv=mF)u?6>{G)?$Yi_ND3B zl%x12U|4d088_k1PV<}Q7JgB6N_48woGRBg`|V~K+Ju7wm!juYDVctiEB=`WYvEC2 z+7)>UaXq-#C0PZAqXzQr`Rd-UzD&k#jAGXx3bzspip6Yxt@h;A^vm zxW76{K&VPqC&()85IukoVY?z;o>-TepNof)S&fiM4Cr*b^>3Q=Ye#3B-fhuHmp_Vv z*ttPM|FrR~lhi*dzfBZYY_eGQm;YuS@GE()fW#aorR{~F3OS@Gc|0?e`j-JX$g@8w za*v=6w<8N{p31?~RGF`;0W22rK6GtmStx54R{2*dxY%|HZFuNn+s(0t#1A(se_D1d zLS?&6Pg&^?`NOMZTq7Ltjpxo(CPu(E2vo~LU6oNBLL~?0^>vi0iKvf$mC##q{_iCJ zEkf;6(F80}qDRdP4pBXT@Y;tlv1)8@a;#r z7|bL_gJh{G^!yM!HR85P%ZvAhWxmlsr8F@`Hv1U3j3iu=B8|&9j*cPm6N2s{9qn`; z;Dru>q*K!;evLatMeB%#EZ+jrnRShr^Q*47_{0bq56>*_+DfO&{}P~5X(nq)wQ2zvBbK|11-AVmv6Adopg zGq*OXRPS|nkSF9oBS9)zy#g+T_pjo7O=PEAz93ImPhD0q`S%A={PEXK5k#k$h!9qX zZvm*W*;4!tp`%H98iHSQU_e#z1dn7!P4~=sCTIU!xGVyH{#;l8Axtwo$;DlT6HffE zF+gQW{-Q`K+VGt7^&1u!SQAMW)Od|>ZE0(4XK;@9^{E_4tmtl-+RU>^+MfZnC_1;0 z;4(f%&+0W+cnjsf~OLH@Il+zw^-9Rm@O{{O~5waDcaTS|VtcPPThQd4XUk*yp@$fUthbYVv7 zSz#?$T>Yn|3dJ{!3Be~IqdJqu>fQpfO=H=@X5LcPhd@P=ePP7}6F-WTG5p$lH9uSTVW0K`k0$9ajS zUX~v8nL~%+Rfs*k*!4o3^&$F8`J3#w9v2LI&g(Ec>ZKFfE4?@1n^5mWg!K8-)LnP1 zu57XwU9AbP!CLVWu!P=VNq_uXax=&sIuL+)P)(sF$q5Rai~@d9w<~L!Sn`si8@L=* M+Z}8o9{>OV0OM`LhyVZp literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/9esim.webp b/apps/miniprogram/xhs/tool/icons/9esim.webp new file mode 100644 index 0000000000000000000000000000000000000000..e26050680cd9c270da0df759b114fff2c4346c25 GIT binary patch literal 1254 zcmVbQsU*fmd{RetmJgF}GKOtS0hTZ<{WxGAfcuCSzGT$TL zPa3ykLzC#+#Q)mxFS})zc+z`|a!=w*UL6^eC3-shfGf8d5MTgghx{!`J05oew$KK? zT}q82#8!TW{rD_X@{aN+kgMWQUjSk2QeO7QPkW6pB4Q*#bJX{V7tfHH|*;y&1&lj;QDMT}c6bH6hir!A00 zy&>(Ji|w4|ct+jd9ybqPUQ97M#V}UYx^!T+1N0W5S`rn@H8P;xhA&;D7i=L`>|>#e zGgTG&&sK_E1G2+>W+8d{S#?YZEQI1N%>>8yxf8yZZ`sK(k7TQm?O@dyCNkMhYOSbn zC`-XZ?ai=VgJw1i#SL(m>=nkC_B7=2yJn5}qbfIM$>&Zl%Y634=SJ-A|Cbd?T?Ro6 z9(L_};j#a@{=3waH&~8#jfE-j-fI)Fjr#|tr(hSx?nWlVQiRqb zB?Mo;GMTPo`Va~{#+f1W>7d{c`=1sl(+7_i-kmBC4q8Y@22>AfX(+=47Dd@ z?)I?d968;O?%IKoRa!y(91>#UC(l^8$RrZFRc+(|gq+w!|5yBHhQ3}imnR>IE`u!% z88O+vb=!>y@1@Z%nHiPSPzHR!nfxH&#XyyP?ThIRd{b~h?~p{1XJHa}FzSwQA4_nW zTe~J?M&%G;76C7Z2Lwtm1V%v|!&6VoC2tMz#jmGHsITjJXesAz9*V30N5B6;NoXrp z4*7qo7O?Uzmck#RnW5O^5IaRXGT!uE<`@SKD7m=rE$-lnjPeamU}&m@DnHE036FdFCU&{N% zZc4SC9nyRiU-~S?mj-yA-0?I#c!~$M-gSoEWaPIK0*6QX+)SfseJz~FKea$FwIe3g QDJ1~5>W~xY^peOx0K5!mng9R* literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/aapanel.webp b/apps/miniprogram/xhs/tool/icons/aapanel.webp new file mode 100644 index 0000000000000000000000000000000000000000..75eabea951d2d14ce0189d66af59eb3398a5db95 GIT binary patch literal 1970 zcmV;j2Tk}=Nk&Gh2LJ$9MM6+kP&go-2LJ%jAOM{KDqsL$06vvGm`Ej~qMW!uuto+Tt7)CT~N6YkGnxUS%gM3Rl>3NV3orzx-5-J z!iXJyx!8^0eT~bhd%L+nr6VpbM(9o}*0+o|9(Tv6knzw6WvBg%zw;C9ne*iqQ&qLm zoI<)+M}wcvO;1WlkV$2;lBDjIg?hFc%6NR~xzT^rvVPYUFrBVeM1;f%bs=X+w}jNAC;$Nd{dXWdjf~H+LxIVb{$JN8=+4^r$;o5n&g1f~f5m5JOZ{)e zf1-hy5!ZNaamwdWfp8rUh^9K*Z{DD7s!n#@7Z6M{ziN-V|EIpf6H@=DRyKV^BkVB! zl?cc^mB?bHpYFtSDQ|du)mlM?0yur*T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i=SJ(J^t01>%ud5=a&$8r-a9kE!vQ0{r z(Qq(RxIyS)5-ve|f*0ROOWn_JW(?}7`DG2Z=LN^mp`piVVkDJ@y~SOtjY6cB;~bHk3f=3w=4a?K0Hl|C}of|jailc&M?mSA3A2 z*&@AHevLc-=bfAu!e-8k7*CI`P&=;^D$ki2jZ~lrQ^P}?9k8EMFP5g+oShn2Ljwlr zdTp{xAu)>%Ow}n08j24t)5FkM&eOJrfB^pcA%I~zQ_;x`8Uea#L%9%L`olh#YJb5C>fMV|73 z2CqRHFTx@0^*Imz8ZN#L(5|PhC^RyX*JI=;sOk3GM-%QCYOTz0`@dWte+P-FbB}5A z4Ji;f@TK1{tbKdC1(nHA6b7dRwc)qI+pELG-)nFH*FLN0lBBtmJ1_lkA^$-#dA^fUbS|U-8ZmdDOEuiNF;%6eTj-*) z!_XrEP!dd`Qw*z9kVzOHml>=Uli ziBnt6ZnS9z{>u**lI)Yjm|2#%P_a*Mhu#AmwNM$p{=@I5QJ#MyOFoU@|3C(IJj;zh z{!<*)ofX&87N6%udB5fd6&sdj@y{~dT35gJx;+!Ixo-s_B>7IR@-#AW+w{s@h|HJ= z$=Mc!7{~JXoTQ`*lQIFYH&SB<2%vPQ*0HAzCd!M99s1qQc2vn&_Zwhj89=6!-Ax5^ YXR4yCLWJh%6GE0ZSITf_fB*mh0BX~9wEzGB literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/adsense.webp b/apps/miniprogram/xhs/tool/icons/adsense.webp new file mode 100644 index 0000000000000000000000000000000000000000..d6dcd29840489b7b879e32e0a81c2fb0a7127717 GIT binary patch literal 3068 zcmVG6)|f{hxVpb>BpVv^khBe1jDv%Bf+^RrxUvWz)g3E=>G&{U(dI1 zM2|)at$tmJ5-YD4^;NQncxGft%IdjWV zS$~yS)PT)E0R+1~v-lU`1x5%E2!nay@7g|q{XQs>fYHsujeV#89j=D3{G`kb=H{_9 z82Y^s{40=Ibe20vGc>p*FcLu*->-q=w)+)NsT#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^8dlDD!70>E%oqD71!Lqtjc8-4S=IR%s zYzTn)hZ?cuC0fAaV?ZG2_M_q-F~;_3MZe>I9C#*kzb9Y(W%H=fAb|2`8D5i-@f5SD zC|J)LG=*C4N5r560R>+w&QQ5?q4ce*94tOva}Y9GgiEC`2q{B%ruN5f8g|^pCHHO?TXH%78}mmGzU7d zGM@9O?Y_nGl-f5UpTh3m))T>ldrUo3H{pDDq4-9Gd-i4GaT_ppF*mkCHfiLW0$Z`< z3ZayA=(p{CZ^G2x>kfC@PSf}WO~1_KmO^{~n!-G0xUQDx^SH43mNUIo0N-7rCdpvZ KjXZw{2mk<_59l8N literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/ai-glasses.webp b/apps/miniprogram/xhs/tool/icons/ai-glasses.webp new file mode 100644 index 0000000000000000000000000000000000000000..63c57a12c1f41f3072141d81c7c489dc07198694 GIT binary patch literal 682 zcmV;b0#*G|Nk&GZ0ssJ4MM6+kP&go#0ssI|4*;D3DqsL$06vvOol2#nqM@c%+mNsl ziD>{9*R2pg8HrCzyFHUVZ6<1{A)$FRb;@!xHKOIb?MS=zd&f(i6_MPlwvN79ll?R;yd z#1t{g@RYVbF$ZI$QRM7r-!#@SL#KaT3LZ^+X{%8L@si!)gqQ~smhZ{$@Vk zFLGY9Z*NW^R8+k^gC(p4`0TS^R&#TL$ZCgmNH$p?wI$j8EsGRfb1;58+(f&*BeZWJ z)-D)rWTA?01<|_Z5sx?3OoeLGKoCcwnbDRJqVrn+S!Q8MvpDpjU+H{XcMuz1L|zPY z?kr#jkgI-fYC&HM4i4i3k=|Lk#i|vt<5A8#n$lcSrM8Wha5hBIs;irLy*YI`K7&Jy z`(LpQJp`0{wgN-};2e5epIw@13fpqqq}CftIg}U1KPiYa`WVWMgV+@BXuc^G?DFB* z4w?|3R7bnHcBTuFQ2B;T)8>4TWqb~0jBqy-bzcQs5fC>m_c({7SN7D9TU|DrxY-_v zP>8-h*tWr38a+#`T~wSS{xO ziD&@T@z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`cE_QGXd@I*kn z{`{^eXUzJXk1z*)6%Ned%_Pm<^O8ur5^r#6PY=!UI||!y%|1c)L5^edN?oIRg(@)X zAU{&iU&}o+P_1Aa9~pK6(Ub>qVF72xIbf9~Yd@08fvv0zuJO|Zgm&<|JX^uU$mfZo M<1id3000000H_F|5C8xG literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/chatgpt.webp b/apps/miniprogram/xhs/tool/icons/chatgpt.webp new file mode 100644 index 0000000000000000000000000000000000000000..4d86031239b0e670f3925eca522858e3297585c1 GIT binary patch literal 1378 zcmV-o1)cg*Nk&Fm1pok7MM6+kP&gn?1pokW833IDDqsL$06vvOnMtLjA|WcatWdBL ziD>{8z#XOkknq>X_qe4Daev2u0REGN{ilD$ep+xgfDfvj?D~gwEv{1_9;<)Qc-i`M z*e~^~txu&YEbNQay|2%vX9R*MZ~SA{t69x2f(c38T{HXcJBmk<6=_-%wgHQ@lIQT# zuT6IN-1KmV1NG0(?h|t+CqOa*uLPr1B~Te~gcL`Q%YL;S4*{;GT(G6i2Hq?UJJc0G zDMXiT!yL1*3Gc`W=m|n6$1*p>Nm)cML;!kY_LTqt{`>X_oOZ?UrtoT7w|d0c2ot;c zd|19hl7}W(9(^V}1p8?Q%Rbk$8bE{GojDIw!w8&|C+M32GQ)=LH@mF~9Jk9^lV zfm(!X)NkzYcdGjLO^Y(n%tQUdT%qOj{C}VidIq1U&+K`O_flzz>$A{J zn!ijec0pHgn|+GQE_F?7qGLWDgarSw zIRmP@Cw205REetpqMqAu^NB1#0BFXgQ_3rob3NX^oIk^VEO;B>8rI5+RidE9Gp$gm zZHr*xU-kIskVlo*ukQuYb(5`KW{d^7lSMPnEkVE&0OC9=EMvx@Id;p;X8oBjiYo%V z3O_xJXTqKo2!B0sKY4d35&Sz%b@<}vZOADR=fipzcH2#&35zTp9#u~OEjxkjx}7## zKzJgA{w>uAC9f*7fMHy&)v|m{EfO0B6>U>Fu_*d+7+;R|@c4N?<{vE24cBVfLfOPh ziKbL&<~y;_Ceze8ZyctT-droiXG|M%2%L7N(2YHnWvL)k>kgdA2ujpY$LcxRi)jjO zQqG&YsAFAMy!d8HmSIno&6Y>ug<_BY(;Y>>^cCG|CQEcM4cpD z?Mok0F^ysn3q^-Zj5_AhSx`EyQ}%-N8`lKLu?@A}el1!>=}vz5laz7+e9HaIl3Amn ztWjdOG)a_`C=OeegUE>U;g0f|q5x)%b}(qC+}~ZfO!$dIJr?ty1aH-*$$XgHwJQVb zWc9okPwD1?w?<8&?bx|VMuII=l8c}gA9MqE7Q|7}iqxdJwL^cx*B1E@QuFb%bz+g6 z?Xnru4lYkAkJx+c6+C;axw6h`u${F^#s=}an42W;PBd#FFzKqVAmUw|_7hHuvN-Gd zzg<3X$zgE*b$&F{rs_|`l*R)Zo4UM=^l$p;=kN*^?8Z%K*EH7UO9No@2bP)C+*f5G kr;u7Z$&}Og6z$nDtALJ*(NSyT>@1gySNl;c`gH&R0Ho%&tpET3 literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/cloud-phone.webp b/apps/miniprogram/xhs/tool/icons/cloud-phone.webp new file mode 100644 index 0000000000000000000000000000000000000000..34036ed163710ad5d5ee953993d49de017641883 GIT binary patch literal 724 zcmV;_0xSJeNk&G@0ssJ4MM6+kP&il$0000G0001A003VA06|PpNcjK&00DrSZQHWt ze%|-Pr4eaPa}uoZk3nPs*8zxRm+UUl-Pyulc``Td5itRH?S=9gnZ$rm5-ZO`EORL5v;8cy;LQPh>iitbasUFLJ#k#$0}um zUJ+DV-s3y`P7Xyrm*>63Z%G9QqeX!L z0RH@4GHpQEr7&{bS1{5v1QU0B<84%W9sh^cR}2z+86qgetLLWxBhVt`OaOO)0^@8R z1S@K_`7FpTSf<sO$C2=3X%iKO+8Z)s1{eh9jxw0MYHs& zeLQr^F}5KJfbkF>)Ge&(lGM6JbU@@S1f$*un7!cp*sr&5%OLp34gylMpq#$NP(}h% zKbHsKCUR?odI0@Ye^h)8bZ!UO{o@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xRO*L9ity`tq=l?$<9Uk{#X7e~7$tZx!7ryv zt^Ss7@F-nk+ayGDqlBJ#LgO2=%eOpnAcdW~QIJ{-fhcOv$@Dn|!nf4;~H6rgUFkNMD{wIm;tic`ET)FHTJ#uU6Ad&n|I~u6wNA~q% zC3TFjqfp}?$8%8@Dv*jM@)zqh$wNH+E6!xuaeqB3^}5*Yt5O6Nx6W`$X8-y;mcXCb M6S3Qv5C8xG0INuR_5c6? literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/colocrossing.webp b/apps/miniprogram/xhs/tool/icons/colocrossing.webp new file mode 100644 index 0000000000000000000000000000000000000000..06dd41c529e2c28287e90ff546844db4b9b30ca0 GIT binary patch literal 2270 zcmV<42qE`UNk&H22mk1QPgpbfZ)?u1&%UWrouwAud*!U&JhCjyQdk|2u-?p5mStIT zt7XPH!zx;;F7rZ9FNZ-ySVcJ9!@Bh~jII{e%~uQ1VJ+(Ca{gbxa=)mh9Qd`YE@s7JSSj(C8kXm}}3rB6S+2NmhK`p&72Z!LR zYU=YOqiz@-ujw|N4`_jYHWdSi;|EI(u8H?%qyaUHkF0=!vD9^~mL6Chb0)kly)h1> zezyT{S=Pz&`5g5E0{&X1*km<5%V zv5yMvMD$`T^P==oGN;lqu94mvOX5RnYw!LIFlAKQhM;@!2kG;8FTo+w8)I?0I?FvR zox-C0Od6h!_v>a3k?vjut97XKXd-$@d_npeiJFOzOWz>lR%vh|)~^9>l)gw%(^);& z;7Yw1{82iAs1qD24VcrA1}F9F4ZXn!rR&J*O&`?!RY|=pa+h>SJ!k8x@2ki+!Ta;3 z3O+1-lBhRhSR<2(UTi=*tX{B-)Nto~E!3H$e&t*y{oSY=Y%aaLXfFiclWri@Nn9rV zio_<$b%$AhUe_~hBh8JA5$@U2nJv*_Y*aB zJVD3csyNlohVx53uqp;%tp1RS_9i$uQ(jh6qnE9M(HX0M=uPe1#e%KptKI(bR?8cU zOg-y4E!0%wBVk9HX4n_z^%WVfCXolDz)&D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+&tLFL#q!{gJHXd;awI#nOR~y0G(89v sF*D;-M}>)6naJ7(;f!)CkEtQYa>xEgNhzsG;svFGS{1_swMYN}0Q^O4vH$=8 literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/creem.webp b/apps/miniprogram/xhs/tool/icons/creem.webp new file mode 100644 index 0000000000000000000000000000000000000000..f8b751ecf8a21e654e78c5726542bad5b55c169c GIT binary patch literal 1242 zcmV<01SR`YNk&G}1ONb6MM6+kP&il$0000G0001A003VA06|PpNZbPe00E#xYkQ$V z`YP47?e4K{8#~*!ZQJ&&?3tx)+h*ISAQmbA?1Vl-a>NX%{oZ94~7rUVR z0WD4Hg(>T91jkcqcOz|O;T?c6vEw2AZe$+}bzfz}4K~lyV_J$j%_6?UW zsSxcueC-%uR4=bUCZy6a|1v|hvweMKGI5o5?r6>9!qjC0$7SerIB0jqf6GL-g6Kmm z;bvcqr~PJV(p*?p?~CzJv>94;iAR7Pw)LK-E_4W%02%OiA1Y$sua7{3#cNb}?MPHv z+Kd6QR?vVyLJbakHBr(g;0(>;4HEpwC8&b!^B(?*zX+S79a@jp7)H+k2aoKe=8+lN zIKvl*&w5fJz!k8;L;GWJ^Uz9qL?0Fh)@BpOm}wDQ>|>RMU~PWYU1S_x=*pnXm_3P1 z^LTDRrOiWXuascy)ClhMG5&wBvhGnJUlu{NmXGsLWuZu(9>J5%R?vW-6}(S4q@+az z?o`s@u@VRBtWKtZ+MV>PB)FfAB9adY%PrLKrKbBaW=jtP!TxNn*oT%r)=&5ijtGp<+-A{vu)y#!))4&RPw2Hp_wV;aPG#*037U~%S zR5R^!*tgbPD_fDPQ7MeMycqi*I7tsw$y-EW%w?8mfVEe7xdK!rF7vvdW?be8&V+p&( z-ejefI1J2;`J0lVc6LMCy)x~eC)e=yc8b)m5BYmLMbr6Iw)}th1ubRk1XfTuAkY8+ z0I&)GodGIf0AK(2HM&+YudO~?|#iMn|1(n$5=qamugVip+vanz;`qhn%@7>{52HGntJHWdC!=CVEUUDz$Tu|wcng5WVs=a{7MI%7tiMKQE*$u@!clP~>0sH6| zyng}&VBskRJ-bDZ6I>yAwOSE<6IyoEaV|;avtE{urQc>c`qSx%h52INyfdJGTYgC6AdpAAYJlsg#`-l&*aR6Yp(<}BHb;Ok z-7ouO1#RNNQTwn&cQ-q!3cjFZlwp*lg04lySiMvNiKfCUY=gaK8DPhT$>2374On8K z$fIYS_E{|T^^YPGV8a?(TEV^eI#Hadj@h$qlI-`kz|3-w#~A8MGVi=KEJ6fvNkuto zPj7T6h1TDC6eJQhA9;p)$z}Qs$18TJ`;Qb6PUeYteBZGHbZ`LUi9xP2Io^J%IW&KJ zXA{tjW0b1}*mdM7v%Tm3U;$7m&$7{c2Dha<)(k0J`m@P=imwzXV^@jw?LvC5Ksi{~ z>#mzt0$Z(8^{@fiwjx!mhP*DbPAboWXjyj0z9fLA3O!FwYi-yp?_FY*8NaYdZ7rlr zq2tHIYFu7vi^dNbpO$I=sObDfo0JS!RM!jP`9Me8&j>>bCRt1VS6ZmDGXMYp0002y CN_EWu literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/dsx.webp b/apps/miniprogram/xhs/tool/icons/dsx.webp new file mode 100644 index 0000000000000000000000000000000000000000..de1e117cabcf7c8c50034c8eeeb6a7470bdd5f73 GIT binary patch literal 2212 zcmV;V2wV43Nk>2mk-_I zzu>KJNdxq3(AU;}!T+!waoZFnv6#E?@v$26EsUK8?uo7s#&Fu7TZ7@5MZV&I^v&u; zKH$#32_KRR1xP&$DQXPc1$`BJ%tS6;UHnC;o|4>7R~9fqK5hK(p&8b-1|BDH?@3>V z)^_8kvdijg5IN{Q9O9c$iUV`RcepQEgRKcjByukh+}hFt%fVvW6i!8`UvD1#Y}vQO z_mZahy{vgBKvtKe`I9pJu)erg-M>pTt6?j#q z&0;!;JH)U6{_k$)?!f=WKfi9L@S(u8$R$6Rr0Abqd;=w_0PL{IHT><&;@P2AvLBRB*xfp`puWDb~G*P%?uHcPrZ-I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=EQd!Z(b;!^cZw8EQ zrz2tu{3gz8gbdh%paLY|L?5Dx8B}cGWNJ3X#a%nhaUY@F4xj&E(KQahDzou?=V36U zeH)No|+gF3a6 zL2j>1e}LMr)u2GlSY#pcrZucji_s)aeXfE%FE93GUy+HC>z&uOpli@pwT?=&*uXs4 zLE68zalj|T+NLX47Dy4qguSn}7tKlFz{Mq%m3@SA_nYy8ufG!!Nz->Lwh*nZ%;gGr zd;mb|@=^L+h8B8Dsxb#Xt+8D1(ui(aaY%R==e84DaolW}V#C$X^!EG^iT=7B zhEUMKaH;lolfCDW9l)@(3^a2}@@@*tQTkh7RDbBBuyGr3hrO{wdXKAt7k- zHu~uUDlL_@1cUBGWg!<37AGW2}Z@RQ0gqys!Y mfcqLK9_w}p%-+o~|K=>o&@MuBZ1nPkt{05?z)#l3xBvho-ewE{ literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/ffmpeg.webp b/apps/miniprogram/xhs/tool/icons/ffmpeg.webp new file mode 100644 index 0000000000000000000000000000000000000000..8599db3886c7290bcf2adab963ac170ff6142745 GIT binary patch literal 1200 zcmV;h1W)@?Nk&Gf1ONb6MM6+kP&go*1ONcA766?ADqsL$06vvMnMkFiA|WcdT==jO ziDm%M5V=xPS>T@mUAlf_KVUs?wB$FX@DwyNWiL4nCS~}+Eh)1)@&TwXNyKTXh+6*e zu4y&%5V5e992$cYN_ZP9=JK}**yC{vGRA4N@aRFksn&hVoDMVTZ(}oi)PUJwR2#!y z#x3-X7z6gbND`|x04Ve%Jq_5hT*}`8H>aW45CHMr5`zTTIJ8Eg^vluO$(h_=y>h+$Z`sp;t{V8jJYsB4n)^2WzwuFT`(;K7!h%6BA7g9fQ@<(cM!Gl5Rv! zkcLN1DO+-V`8-e4MOw5hEhjHOe;7jsW{ah(DZexvpIgL;sLbHB zI!xeSys>vUK32p)#Rn$m)W9oUsMnr|eFc{kCIo7=_ADyMWh#3xxx8s+IVT&TDtIjw zRvOYA>P%MZ>4ZIZW+9q$+8HFa2dHabM`l?`JK;tahqhU}m%?A3-Epw(1Cj*{HfSTp z(dbK&ewB<2*+}22Gu=SPfTJS+Zga%YP4%;;A#*44zgcBhML%6fgCT2$k%0 zNObx}65-TBxQ{n(N&=%vpqy%yg6F+8y+7KbhmQ+J;qhzx18DG*N|4zlio zkr}k8hGQpbGIu?6PBC5c-N2m#5_mV-sXJ-6jl_7&US&4OKr1QzIVZ?L%&T@(fSy?$ zG{Es58a8ocR2Gz63yk)nHzxku7y+&&MagmMrt@=u!(7ZRg1N=x<(tC{xKf;cIRpNXkI$2ed@#6_w?ceP@0Y>;G44DY{87f9T8RZadTNen%X}_KURH zpWmY)Sn49lL4RBd`xwy9zCr{SXyl>&!_;25?ADaO8(;iYcC7VCFv#Sb&zz(Ykq28Y OAcGwATbrN-{r~_#B1|&? literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/frp.webp b/apps/miniprogram/xhs/tool/icons/frp.webp new file mode 100644 index 0000000000000000000000000000000000000000..c6547fe433248c3b777a6a63b6b6185229559da7 GIT binary patch literal 910 zcmV;919ALPNk&G70{{S5MM6+kP&il$0000G0001A003VA06|PpNZ$Ye00DqwZF^$n zO9pp$uiR}5v{X*V9$13bv@C#{EwBPQI(LV$do%g^KdI1&m;iiBSF&Bukgeq@RCNk& zE`gS&vHlQ+k=VDh4Fs|j>K|z-dL0F#G97EW){rK1(=h210F5nLx@oxw1(6dgOHMAXOhKrE zyGjTGckvw^09H^qAbVn?METO<1*$0xVn4zLWJ%?Dm!{T+abGjZ8+Vcw;Xbh(iPLOj7W(g0 z#b0~t6nW16UtA+A{&VX^m3wt$^&-CVjL2|MA2r1&s&7bD^)DhK$JA4KwsNZ^E&j z($tKYSLFJT%+C%jw|Ay(k>8w;BB7hhx_^kPFoOp~zQ!B3GPa!Qu--nfsk8+7W*Qr2 z#Fu+aw>4Iom(3C$=jLJoE4qf~4G{q~Eq2IIYIknwwG(=X&n=(*>%aQL0w7=W=-XH(~0Du^{!vFvP literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/ga.webp b/apps/miniprogram/xhs/tool/icons/ga.webp new file mode 100644 index 0000000000000000000000000000000000000000..4bc3288e8dc2efa051798c5b31644878c00517b5 GIT binary patch literal 1876 zcmV-a2dnr}Nk&FY2LJ$9MM6+kP&il$0000G0001A003VA06|PpNQMLe01fbMZQI+n z*|r_$Re%eHRW)_}*Gs*#fdH;{PLKlN_)6|N5fKxBe;*PFB4!ThA@B(+t%-wk>G`(Q zS`mBSb;)6nHq}B)FhC(5cCC%+ATWUIn{|~--?Nl}-#$FrbT9yztDAYL$yydt2;M(G zZPRfoZ%U&g00mH0NkqHd+L#PIyD)Gq<6FI`S2OqYXp@m$uC+Zf2Ih;K3;+DkrenR7 zt;OKQqN4qFmyXpETa3&XlKr7eg$l=>y>D>-<`dzwQmmxFa*FqU3Rs?W;22=3k18h%mPe5 zovv%qv?GAE5}`drCeY6(iky2pN|gp(B`OnBp%^N+9@A zq%}F`ohPNl1Ww2knuY)#LjsXUK?pEAXG!NYK_?XeA~A&kftd#(GKgqYWC-HcA~RxK z@0G?W(*yvRFg$t>tudBuk32)uAur^Z7>>wt0MYt-0_THJYFOwyGQ}vdJH*<+ZctQW z47#543_v(`W;V{YJqsGqv?xk7fC+%#9Z@TwIcB*T6OJvJ5`a52T+h@9-dT^ae%HjJ zE(Z_*eqrcL0N5Vwd?AK4yN2e=ldlctOEbtH-(yjYvYSn;7qbBXj*m94Gn{tMZ{pWq zhHc+B;<5nHzkJ4v>tfj5Bj47e{MRmIML8S7PoJS);H-Um#?|lHkbSdlloluNAF*Dq zXvp^QUEF4)A|Lk0p3Axrd?Nj8@Abl*^PgWG)Nh#wF(|f&BXohYq1ksfh-H=$101N? zMHnSU0odL>ba`E9DFxf+7jyI##gyG2Vi&q(B`vD0toid<-e8y zPZ50k;v(ZLLm3QYgyUv!A#j!ihTCR)h+rlFU@`(f@N?I>z>$E-*-%ToV6?;6h}^)WNyP zn3$apj7b4jP&go<0ssKe5dfV5DqsL$06vvKnn|UmqMy<%+W;@t#`M$W< zsjixA2DG2o7r!l#Q2BGdBZ6W-YZ}n-r|s(ODD%VD>lOV z^}W!(cs*Qp;IW^=s+Wl^Z>5QTMU;jYX-&x;@OptHb2vnO9U@6-6}?Wx=A-jSKIe$6 z>tea&uN^#52zdT?I1`fmec9G?D6m$WzZ?L60$>4?zM8OC>`fY=yYJE8#JwU5|KNWQ zfnZG%FXR42kRu#1N3ymj_{_dw!$c8Bck>HwR!);_LKM_aIeFy!s1BjJs2?>$hsM7D zZ~x;)$Xn0M@00$vl?~xj_=V0b+dv+-%T=XSq`u2v7NWq|L%}-^Q<)fu`Nc0N+J$APR>^t860a0!=C zO@OH?kLK4~686>1U6VeXgME4oSMs)PO9~F{_w#7LFr40Ovx{&=jUa9LA^M(UCb0Jn zibLg*jUz!n1%Qj#^F#>zaKAct3B+DxCak;pDBFbg%6ZD==WZeN_COppM;WyO-Ru@n OZUU?^H(q~_7ytk}D|~za literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/gpu.webp b/apps/miniprogram/xhs/tool/icons/gpu.webp new file mode 100644 index 0000000000000000000000000000000000000000..4e0757ecc0a6bef81cc13fa6c543a78508b1833d GIT binary patch literal 1070 zcmV+}1kw9aNk&E{1ONb6MM6+kP&gnO1ONc=766?ADqsL$06vvOol2#nqM@fY3m~u( zi9in*MLP0(Li!lv0QW88iR;`=8BlgSCe1 z7E!YlhZtQ7c!wMg&fRZB*`ruwEHRSlhPiZBI zHd6M@DAZc98SDT6{`!yrG_!bD_Y-A2|LCc|-5{%{sL-&@JszjtL3^xw55IG;H)&~( zZGvX750kNuj>?s0-kN!s|2a?St0898F!o)&QoOk)qbtzP${@|42?y1Q@e)dEqpr@{zyxuv|!l z@CIQDJ~-MU_$g!=TGNb3zQHBdMZeTt>{p<8z(N<#y@M(j4Btlyw0T+)bR8LIb*<{f zN__AO%STi+V7wB%10GfZ5k@5=T#3PegP}t4w&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!T4OYXtzyk|qiNd{lPoU~P>L@qwB-x#qfnA(Qve6M=zyi)1 a+K~jR{83*OOn>;O^U@*omA!mQ00012a%fHf literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/iproyal.webp b/apps/miniprogram/xhs/tool/icons/iproyal.webp new file mode 100644 index 0000000000000000000000000000000000000000..22747a153904c606cf0c86befc43e56be5e841e8 GIT binary patch literal 522 zcmV+l0`>h;Nk&Ej0ssJ4MM6+kP&gp=0RRB-4FH`1DqsL$06vvOok^vmqM|HwdC;&D ziDUrGfjT7YG}~o4+Vs?U_q~__j&t2^<1P9O^e_8Ykb6K7^YcS$Ko#R2;?5$Q1Ms{t z0QXvq_mXAmvFOPH!s1M-g*mD+8l*?aNfjzqT-WXsV!!vszfv*6qwYWe{`x9^9c&fe z#U`O;j$Y(iV7&nOtk@c9K0XKsj%35;p)dNS9QfT|@QXL!g?2_&EvaOgx zfHO7WXc?UMqX$DI=n!A~>+1C$EQA)3fW5C(o};VIQ{|Q`E%bTQWKqC7jHjqhPQvf6 zo&0{DfFSxN7?JAS)e67lUcOI$cuuC8+y@fv`Hu2dUZl+Ze~m+tXtNZ2oSx=9k^CO9 zjDAJ|H$Rhz-~ZQ!Y>q+zn|d)V{U9j0P|1pe(;D`Jgnf%gCS{BOJR=FXzi2Ka=31Z9 z8_^stw{$l*T_1f|bo~D`oL~BYqLy8`<#N~nVoZrU36i^;fH1`Sk2l017Kpp8JX;!r zSVC`jdF>2Xgb$0iv$xQ?lo`>jaeV1sr8eGnz!24&7ya_{S;85IJRoJT8a}_}wYBI# z8TJZtw&>};^hIvkem%eSJR|WQ(GX4ZdG+Z3aT_T9e3U_*z!nwx`j9+0v)c{w7C(U&Uy>=!_6;>f`A{)zrK2^e_Q(t=hNw5`(NaK1AkY)=>K!=V#&lAM2FNZ zUe3w)+K=8)I^V+o0pGPy+s6L9g0$YPf7Cxss`d=^r?f>f)^pXsZbp>V^@n7sDO`suF^?T8Pq#l29vsl2RKD@!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/apps/miniprogram/xhs/tool/icons/mini-pc.webp new file mode 100644 index 0000000000000000000000000000000000000000..f3038b050768bff58bc2d05f1bb55a5d3370f435 GIT binary patch literal 370 zcmV-&0ge7rNk&F$0RRA3MM6+kP&go70RRB-3jmz~DqsL$06vvMnn`>=OHdK+C*quP35ilS?Fxj0hk~n(Hkwo#?_<}yGDZOB!KChTVTTvQ5o z_Bh~?oaCdUvqgQQ!xB1F0BPHpf)H+xQV*a2{`R+7%T72`IHYJ*zL$aLPo)ciBYOfv z&g}RM3Hg%YiS}by##bS@R8{$dty!lWEh8H|xr9HbeO`kch*z7I=&xA&eD5bs8384m z@7t?bCH8lR!A^BJNV}gZDAQQMYKi9uY6O7L#6r4Z&u*hQVtY<{^bH*+PmQdOA#Ycl z_HZ^bvZORp4E0jr(QpNVK6!s)j!YxZT*ZO$mw}wil#BZ)<+iq1u8V{}lgEGLsMr4P zcJ=dnl9n$1q$$5=9i!QO3X=Pg1 QCv%^2rIa7X7a#xt0Qp9#`Tzg` literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/namesilo.webp b/apps/miniprogram/xhs/tool/icons/namesilo.webp new file mode 100644 index 0000000000000000000000000000000000000000..f29a994e2fa0f5601d58f4bc28a83c5f8ef812c1 GIT binary patch literal 942 zcmV;f15x}^Nk&Gd0{{S5MM6+kP&go(0{{RJ6abw8DqsL$06vvImq;a}q9HK#?69yB ziDLlG^s~Q2@Onhsqt6`rPwCI-2XEizItRQ0fSf?Pr^w#%S0Vn7#D0>=lKCO}JN4ux zv%j8ko930nusbB}c5N>u%FYrmq;Kb4UXY-A#3Tk+pq-GZ`b|3PgEm3vtH`a*@3t(w0p~4~zvFHAyN5w@pBXj41p-|)~Io7D7>6`5@k}WHzZlMoA^-)H> z`L5@@-4$w-10P=_PgO<+x>xUzT@H&KjVMFwk1aXhLxGZz6!Ww^ku=1)GvxzG0Y*TX zl6FL0P5fPh4ZR{@J-y|#j-I`e+{Bg;bgNsw*uV{Vho7oG#p`Yb_a&gc3+vAzno>9V zf@sSN$<%jl9IYVIR*lE*PCKa8tl%knuqS1_dwC#^p@dSgtg`aBvHMyLHCfTG)7Cv{ zZ)DC9w+S}H#~FDt{cUIXB%4L6>MH-F`W{Ey+A5TUzyjm1;tM@ZLl=p~T+$$;Vm}W~ zyuby2@Ejlh{z1fD0u0r}57q$VfnQ-}mbAr3TO^!Zox89(>17N#zpAk&l`U9e|=d z`YvEo_NU2U>Oau$>iJyT=`YpsgmgoDHhJ(r|I7UpexSX>6Wy4$G?T@mL2>KhvU+b_ z+O3GZffr1@oQS{p6vq~S0-rPt=xB?i`_khH^QgEH!7}*S7;Xm_T0%c;Z)@1VqflO~48gF(eR^ljAC3z>uD QH4-ire}1@3t6%^C08Yo+;Q#;t literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/nomad-book.webp b/apps/miniprogram/xhs/tool/icons/nomad-book.webp new file mode 100644 index 0000000000000000000000000000000000000000..b4959884d8bbcdfc81e67f56837e220120927032 GIT binary patch literal 832 zcmV-G1Hb%INk&FE0{{S5MM6+kP&il$0000G0001A003VA06|PpNE!hE00DqpZQC*D z`L=^1SW0ZGkZi{@1q2<~W(#&|7~A=RpXYyeQAA7t^g6oZ`!DIbv}8T~ycg?oz)aD# zR+W~otab{+#_lA^n_**o7n10i*MO0%q?(`BBm9zXTxb%DlJJ7i5|fle8YU#^85LiF zRnDVyA!(l}j7s7|0K^@$8v%4l>K(v3w`Dl1+{(6YNxnVKF1pWd=at=aid~|{t}6fi z|NXbdu9{+(cwzUn&u%BiF4D!W%~9c2vSF3m641%59T1nyt_6T$X8rhj#OoA_-aM^(;;J7;i;m^8^~y`_0%qFU zqdQNjnl);vr=3Wf4SE4qP&gp?0RRB74gj42DqsL$06uLplSU*XA)zoB2mpW$i9i}v zKqw{lXUZCLwgi0DdH{LgbSM9g>m~F6^1${k{l@){_JC-Cq`jH)o9G(eK^*^6PTdH($_~v}5$1b!wS;1x7Kd z;j9JNU=!tZ<`KGleaD6S2hW9`80YQTKEFnrA`DO_$_>Vt@iYI5zsdpsS7r`ADIFXL z?39mk*PiAWPd4pz*>?7_FM-($TM%h%Wf10#39`60ZjJP4dCZ#qmoeVn96X&~u^Xnb zllK^B5_%g-B`l*pD)dK#L5jmW z^mgI`7fz?|gCSQ-$a`dd2xgJ)01s58N{*3pyK?xDuP>w*F;{Pqj(lf*nXp~mxo@ZO zU%7HmI*|qR9N+V)m~Y25=THk0Mexa@w=chrif!@iazB{s!>leY49pg_X|!&V9iW*# z{0vtP&T3!yFZCdKvh;-K=JHnwil82;>O8IuX2-8hFG4HuD^SDMkExWlZ%%yid2sll K0uccvfB*pWEs^H{ literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/nomadcna.webp b/apps/miniprogram/xhs/tool/icons/nomadcna.webp new file mode 100644 index 0000000000000000000000000000000000000000..285782ef69e2785798fd6a1451fe5b79d20fe2dd GIT binary patch literal 1520 zcmV{8;2*#{K>s=6UxXhodv~Bu&-d5)CEjnr%|O2t{zd)+^80`&0DeFHAO1gp4y8Tm z^1b5*@y}on%D?n|mVcf7n)93VPq07pFYBFby&HdMPv7WNYitxpPcc^L29F~5@m1TC zb7J(#yE%^M^|jxK8=wto#@z^&N{xt z8|40}U2OT841t1>pmhegvU$f>`8qd)Rjy1dH&@!P}QSP{XW&G-R(po!of zj485?ZN`u z|Ch)`tV7rzAE%a@pXZ9FPto( zftD)n6|?qx_6Rq-J`?03W#NKg1s_d!#9iYy@mwvTz*GEOcwq%7QF^8 z&D9vP{J?2T)S653j3cywbuQ(7N<>cQTQUVa@MM;p|5uAmv^*#+*c^(qedRVAkU;&u z8mMxSM~ImkV@JMK%prdU`G_i7f*Z52#S=V9c|{Vx8h=lxuWOLGh1)*t^!h%tHLDrpq9oR#(bf2O;*FaJsZHWB7qdj8jB-Y$zGIo1FPz*BP zBjq|`F7bNL{54NcWBX0@21KpS^~MkNZ8*Iz2q=7#Yule!0lX;k7?OP_7W{G zkMh&0{xITzMwT85n0<=7b+C+DT7%1n7f3W4Su0_aRiJ!{gSnOwRryG=aR6(*18vcs zuI9$&5dKnDSy!1qpQ&*WiefD@b#xt#B_f2fI$;JI9X5YEp?uUkBRFB7tx$gn2XHbW WudTveFTLOb4oAD@gA&+a0002rPx3hc literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/nomadlist.webp b/apps/miniprogram/xhs/tool/icons/nomadlist.webp new file mode 100644 index 0000000000000000000000000000000000000000..640d92f459940397df3274c2214d9b922e56cbc4 GIT binary patch literal 600 zcmV-e0;l~_Nk&Fc0ssJ4MM6+kP&gn&0ssK84gj42DqsL$06vvMpGu{pqamml8W6A& ziDUrEroes>bF*)kfGUpoigbYU0p}0V0n~xKcl$8I1!yQGHvPJ)IN8NpR*!)V^zfsB zAGh!8-v;vrqWHznk$he7_y7`0V&X*7zO)3_fI|4}QSrYram8<4#{-~j&1 zxBv1C7|R|{|KC79^aJleEZ5v~d@4@Q{kFEHtY!S9Rk8SFIb8=OUHcZQfO#@pgJE#S z+?$s@>VcR6xckw691HxG6~~U*BVwD)fgzD@kE27(W-?HN*~|zNAix@Pg7kscQoj)A zx$l7bt+rVkt@gLA6VLFW1{d3%i(I8`T!;P*SPR_O+fLKXwc01zp0bGLHc58AK|6_h%Mm8z?$pU03$KyN-(=Ax)WW2(ll4LSts46)63I;&NmL4t&{tm?0v2| zOvUm~`OD;1_u0Al((&9xgd)c+c`OtLvxr*dYC!PSyp`tAUBpc^}?utQK+Dxvu~=UIoRr^0oQRwQbwBZQHhO+qP}nwryKu#vlK8)tOnD|J~k1!~~%CAq4;klh3!}#yjk~+YXzo zw7^sm0744rzQhP%;#H5m@3ViEeU|=TJ#xzWQwtzTx+N(9Q}6c3KQxlmK1tFz_@$%g z7a)cX#elTxor7pBS=EevS}B?fjr#hYlR#qVNQ@Y5t9NNsHDiNjn$7t4c{4(ybU>nD zy^m;`jXg9~U{2F8p9g#L%XMDIcdQ zTU(TRVwBjPgr$FCHnzD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4MVdo8MK4a7KJM@|>*{b()2kyOjM*n(f_9n8@&6dbK>BriW8v_zHxtis4R-<wXRSnX%zx0^?a}Q zuXc0ePwk6*djEMr|Ef+4IgwpeX+|sYJs2qAWImlv`R()y^|x2sKzy0r?;z8PsWX~4 z7(t&0eL%Hm>0sf6!!jSL+3%*cLuQIVNdQEW0C||yZv>_Cb|5pRM0G~H_@$}iKlLZj zz>328``kFu-cF#2&m!<^?o=yp$$4ZdwBb2|H}wa<{S@fW4@({Y)8zDYLt>#^4L#r4 zM{hMTKqwK=R0kx;3=%?)L9J{ZPBEK1QGDI(gg9@?7a|SpNEq3KG0M|Q)YT6ul8M8! zD=<2!sVz?rPR_aA( z1~03~lI0~AWp|3f;3mZR?Pq_FLJTh(`CmlUXAO+@F{Xkim%Rs#WnhT9u%NJZshp{- af+Zu15`FqpjZ~c3Z9U*PW7H6_0000l=2Ef% literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/okx.webp b/apps/miniprogram/xhs/tool/icons/okx.webp new file mode 100644 index 0000000000000000000000000000000000000000..85aa2e3d0cb8bcd3d344248c06534fe7694b1b8e GIT binary patch literal 926 zcmV;P17ZA9Nk&GN0{{S5MM6+kP&gop0{{S!7yz9CDqsL$06vvQno6akq9La$NU#!# zX#f_={$KwA+n@Gd$lDjc&;C>Btp5wW$%}u!ajDxG_5sjY7v6iHKY9=Pi`XyuKlQKo z{Qg7Shs+h_7r$6M)D2$s;ti)z3ssT*`+UcA89vWBmy^b=p zwu-4nLgq8`?IGp>{`upAncYtsX>ihQIAHycOd~^l&|lz@Y;w_=g(@(dg*I8^Z*gDZ zsMZ-g<|1?GCB%gO;dd*pxaz}X%i`x{n=QnzjPtzLRWKh6jtR_NrV^i;gVs;=k zBr>-GL^k;V$T@J7G*HaHCPjT`#j^$pbTsRG07FQHxjW}(#eOU(P#4M-<|GzwQ#6hu zN2U4~_SvL5^Wwe6P!L_;6|zn5gD%y1rfVIKbX1|xw&-+8jC@dSxk*GI143DyBmU!2 z?>SXb@x>PPb-B(t1u&!(ZWvkb-G7gnFf_h~K=)6K5(e!e-qORBVmXvdo+dzor9m29 zM@tFFY6u%+nYU}w#NH$c06gq+5B^6P)y_^>bkZ9%lcnPlk<9y`wBtO`E`R_400HFD A3IG5A literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/paypal.webp b/apps/miniprogram/xhs/tool/icons/paypal.webp new file mode 100644 index 0000000000000000000000000000000000000000..3cc416e6def56828fbad268bcecfed2bada0a8d7 GIT binary patch literal 616 zcmV-u0+;<#Nk&Fs0ssJ4MM6+kP&gn|0ssJT4gj42DqsL$06vvMoJl34qaiLe37D`F zi9xmivooX8YB(WD@I1hI!)do2n)h8X5{zEj%qMe1&m11XZ9`Hyd!sk32b`WQIA0V= zjT1}MmaovRT2prs61c&J81_5L5aj3mvrXK&9;aC@=4@Lk0{_?4R z|CWFI4g9yx&-xW8M8%S4yxRu7aX&o!4v|}0JS`VU!Nm(PPr@eCi>CR#pT65X)D%L} z0caPWDy%x;6wl8lk|OLfZ|-2S@;RwgNR8JB{^&UiXy~Fk6yNCFQOI=BhP8(n+YP*L zLw!{!=ovzU<$n(2xpeZAv}C8?;l(ecnRzDIV_TASZ(nL`;mOvm4$NYKYT`u)FKf)D z&5}6%MYf|9JkYM+tZnyQ+k`ZtI*Judwts)z5$hUH4OmgvjpfE`8s=z9cx8TsCwe;` z8C;dlie`3^f!A2}_pHYeisEQ-072INRan^ct}%1B>pqk-I>?|zdN_QOAk$6Ot0kLe z^J{(dx+dl=B!>Cz7qWxJLp?C&bCib-85fGN)w|bsw|e(8?C#{lMMwN3*FCH~(UA7k zzKTvPDzs4{l^kR3TYZkwe<*%F)L?gWgg#UoZ4WfUVM?S}Lgsp~ttc3Rj&E}M4A6Z53fLENyvI%mXcZ5{NJk|U?n^Am^-rBZc1F&`t z4m_dzJ;p*Fh2%pX|9?s&!;}KNk&HC0{{S5MM6+kP&gpe0{{T969An7DqsL$06vvMol2#nqOhp*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2Cu5w3a z8!+ZHHUVA^1LXP_7eL0I1=G88hn~u|4&h3yHqI#tz4^UC>18r6I`lCA;-TK#5m zG#3e8&x{E(D@lURU(vmKUBAhrj%VEzTH0-WwvPKjR?~Ep&Gqb3ZEKjNn(;h{NXKGs zTY<_!XL~Z&%SEeg50_FyMTJQxVfML>m9&jcTEZ_%^?w|OZj60YKyiiTE#WmY45=Y2 z>+wn#t8cHx`>K_j&n%3OvhHg3YhBOlu^W2fZ3@Q-eT8Y_oTDa%v>5BB1af zYRpb0N*r!Bb7<&#Gj6E)GVCc!Dn&D;5|EU_+brwoM3JhU``_eH2DRz-wYk2!U=0Pm ze9g_A8lJ4kR7;HhXwb&W6ltoAxKMc_nv$g#tkqx{;WZsE`UV`lO5ERO8Htzg2|f75 z?AJTGeR#a-BhMWGzD8AB<-|rTHM)0|v1{BB$$Zzi2}yjRQY8n21GbCYc6emIF-;hm zkwzw&a%$T==JB3MoDR9fIFjeYTW6u<#?AsYsOY)@c?5GOOOMIJ;^amECMPSV!^UIx z7SIXmmF=$9?}gRhN$n6lP3fL)JBCq!#fc-s;Lor=vDTvuhREo8Mzs!qY>z4pr;0T_7d!+w*Vc)>!^PuERr;i|cI}~j>hmpV`SJUU?8%M|ZDnps@S&0{qMu^34Kgbw6%wzf7F$%53Cy-m)U3x`KxH>~hD+nf4 zDi#x8xD#>^9?v{x|C{Kd%;F|Y$my7OFC-@Ez*-gL@+Fa>{OIxJaXPecPxs=h>pM!+e{Ij@sLch!b56FmLJrDs5j+z|prW(uht>E4geu5KczErJ42EJh>GNh{bX#fnhXjOK! oS9c+U#^gkNX*mUFazklEOZPC^`SqXdQPE=)PiATJ;yG9V08UfmdjJ3c literal 0 HcmV?d00001 diff --git a/apps/miniprogram/xhs/tool/icons/racknerd.webp b/apps/miniprogram/xhs/tool/icons/racknerd.webp new file mode 100644 index 0000000000000000000000000000000000000000..2262856f58adf2dc12bbee62ea22624b2a900dd4 GIT binary patch literal 776 zcmV+j1NZz=Nk&Eh0{{S5MM6+kP&gp;0ssJT5dfV5DqsL$06vvOoJ*ynqM@c)DHyO4 ziDdxQ*-Rl9S0q6nJ!~VWzFV}JW{|CYhur4+H&qT|J7{{6c`iIyf z^^kT|Tv3zY8Tz5HAeD|JnK&c3OHYW7#|;wsVN>-}4TrHhgX9^iV}6+IyC&iGe9s@@ zyelSsK>dYkoQ{VSNgK~bitqpc{`r$p)sequ_`afjiIz5)H`JFUan4>kVZxrRV@U`G z^Tmo$>$4j4rk(nZGi(pvHyt9Gokbbf8ZjFB4~RDHP2N?U9sr)h{&+Mtet_y8#r3h7 zz}fvU-@%bA^g{*j#zUruA=6SGDXulH81$s@aj_`*E+}6@U4s^y8*5H`^MA7bQ-Xv@C z?bWo}A9X~@C9gxi1$!=~rVzX{?z;m1)gOBt{^Ce=cj`N@5=*B`hB&^^QGP7RCH|f1 zxx=vD@j3zF_c7U~cQEhaZFbyX9Y3cJvZQ>D0qrBgw00g49z!@2?t&L%HHVuhZ#ztvbG906m>?N`c=j59ai`acoEyli zaGonGGVse$lHjRhe$KHd)&B?yaI{_K-KqM+3zLCfcY^liJH@$=qo^v&w|499^5l!e zoZAg93K8;pQgYCA@3{VQpKJaalDl{kyx1=5D+v`Dlq@!6X?Ia3>ewJxMTq@_QxOU? zJ-__P`sy@|e3}l + + + + + + 游民导航 + + + +

+ + +
+ +
+ +
+

游民导航

+

数字游民

+
+
+ +
+ + + +
+
+
+
+ + + + + +
+
+ + + + diff --git a/apps/miniprogram/xhs/tool/nav-data.js b/apps/miniprogram/xhs/tool/nav-data.js new file mode 100644 index 0000000..a2c43a3 --- /dev/null +++ b/apps/miniprogram/xhs/tool/nav-data.js @@ -0,0 +1,586 @@ +/* auto-generated — do not edit */ +window.__NAV_DATA__ = { + "brand": "游民导航", + "tagline": "数字游民工具与出海资源合集", + "footer": "2026 游民导航", + "categories": [ + { + "id": "nomad", + "title": "数字游民", + "emoji": "✦", + "groups": [ + { + "id": "community", + "title": "游民社区", + "links": [ + { + "id": "nomadro", + "title": "nomadro", + "subtitle": "出海导航", + "href": "https://nomadro.com", + "icon": "/icons/nomadro.webp" + }, + { + "id": "nomadlist", + "title": "nomadlist", + "subtitle": "海外最大的数字游民社区", + "href": "https://nomads.com?ref=https://nomadro.com", + "icon": "/icons/nomadlist.webp" + }, + { + "id": "nomadcna", + "title": "nomadcna", + "subtitle": "国内数字游民社区", + "href": "https://meetup.hackrobot.cn", + "icon": "/icons/nomadcna.webp" + } + ] + }, + { + "id": "toolbox", + "title": "工具箱", + "links": [ + { + "id": "chatgpt", + "title": "ChatGPT", + "subtitle": "OpenAI 开发的人工智能聊天机器人", + "href": "https://chat.openai.com/", + "icon": "/icons/chatgpt.webp" + }, + { + "id": "grok", + "title": "Grok", + "subtitle": "xAI 免费 AI 助手,追求真实与客观", + "href": "https://grok.com/", + "icon": "/icons/grok.webp" + } + ] + }, + { + "id": "us-phone", + "title": "美国手机号", + "links": [ + { + "id": "1psim", + "title": "1psim", + "subtitle": "低成本 2.5$/m,支持 eSIM 和实体卡(邮寄中国)", + "href": "https://1psim.com/7GARRL", + "icon": "/icons/1psim.webp" + }, + { + "id": "yesim", + "title": "yesim", + "subtitle": "美国手机号,3$/m", + "href": "https://yesim.app/?partner_id=1948", + "icon": "/icons/yesim.webp" + }, + { + "id": "tello", + "title": "tello", + "subtitle": "最低 5$/m,支持 eSIM", + "href": "https://tello.com/", + "icon": "/icons/tello.webp" + }, + { + "id": "9esim", + "title": "9esim", + "subtitle": "让任何手机支持 eSIM,可写数据的 SIM 实体卡", + "href": "https://www.9esim.com/?coupon=XIAOSHUANGERIC2", + "icon": "/icons/9esim.webp" + } + ] + }, + { + "id": "finance", + "title": "金融收款", + "links": [ + { + "id": "wise", + "title": "wise", + "subtitle": "线上开通境外银行账户(身份证即可)", + "href": "https://wise.com/invite/amc/xiaoshuangh", + "icon": "/icons/wise.webp" + }, + { + "id": "okx", + "title": "OKX 交易所", + "subtitle": "加密货币交易所", + "href": "https://okx.com/join/84999861", + "icon": "/icons/okx.webp" + }, + { + "id": "safepal", + "title": "safepal (U卡)", + "subtitle": "邀请码 104809,出海神卡,加密货币与法币转换", + "href": "https://www.safepal.com/zh-cn/", + "icon": "/icons/safepal.webp" + }, + { + "id": "paypal", + "title": "paypal", + "subtitle": "出海收款必备,TikTok 提现、佣金提现", + "href": "https://py.pl/1tyAwY", + "icon": "/icons/paypal.webp" + }, + { + "id": "bmc", + "title": "buy me coffee", + "subtitle": "赞助收款平台", + "href": "https://www.buymeacoffee.com/invite/xiaoshuangi", + "icon": "/icons/bmc.webp" + } + ] + } + ] + }, + { + "id": "studio", + "title": "工作室", + "emoji": "☕", + "groups": [ + { + "id": "proxy", + "title": "科学上网", + "links": [ + { + "id": "jms", + "title": "just my socks", + "subtitle": "老牌网络代理服务", + "href": "https://justmysocks.net/members/aff.php?aff=12475", + "icon": "/icons/jms.webp" + }, + { + "id": "ykk", + "title": "Ykk Cloud", + "subtitle": "性价比高的网络加速服务", + "href": "https://panel.ykkk.best/#/register?code=xYQebIgT", + "icon": "/icons/ykk.webp" + } + ] + }, + { + "id": "vps", + "title": "VPS 服务器", + "links": [ + { + "id": "vultr", + "title": "vultr", + "subtitle": "可按分钟计费的服务器(可支付宝)", + "href": "https://www.vultr.com/?ref=8985003", + "icon": "/icons/vultr.webp" + }, + { + "id": "bwh", + "title": "bandwagonhost", + "subtitle": "针对中国线路优化的高质量 VPS", + "href": "https://bandwagonhost.com/aff.php?aff=25463", + "icon": "/icons/bwh.webp" + }, + { + "id": "racknerd", + "title": "RackNerd", + "subtitle": "最便宜的美国 VPS 服务器", + "href": "https://my.racknerd.com/aff.php?aff=15630", + "icon": "/icons/racknerd.webp" + }, + { + "id": "qcloud", + "title": "腾讯云", + "subtitle": "腾讯服务器,国内速度快", + "href": "https://curl.qcloud.com/BZZ2MBTN", + "icon": "/icons/qcloud.webp" + }, + { + "id": "aliyun", + "title": "阿里云", + "subtitle": "阿里巴巴旗下 VPS 服务器", + "href": "https://www.aliyun.com/minisite/goods?userCode=dii0ofzg", + "icon": "/icons/aliyun.webp" + }, + { + "id": "colocrossing", + "title": "colocrossing", + "subtitle": "美国 VPS 服务商", + "href": "https://cloud.colocrossing.com/aff.php?aff=1846", + "icon": "/icons/colocrossing.webp" + } + ] + }, + { + "id": "resi-ip", + "title": "静态住宅 IP", + "links": [ + { + "id": "iproyal", + "title": "iproyal", + "subtitle": "静态住宅 IP,出海必备", + "href": "https://iproyal.cn/?r=nomadro", + "icon": "/icons/iproyal.webp" + }, + { + "id": "proxy-cheap", + "title": "proxy-cheap", + "subtitle": "便宜的住宅 IP", + "href": "https://app.proxy-cheap.com/r/bmcMoY", + "icon": "/icons/proxy-cheap.webp" + }, + { + "id": "smartproxy", + "title": "smartproxy", + "subtitle": "静态住宅 IP 服务商", + "href": "https://www.smartproxy.org/register/?invitation_code=7RXPLM", + "icon": "/icons/smartproxy.webp" + } + ] + }, + { + "id": "resi-vps", + "title": "住宅 VPS 服务器", + "links": [ + { + "id": "lisa", + "title": "lisa", + "subtitle": "住宅 IP 服务器,TikTok 必备", + "href": "https://lisahost.com/aff.php?aff=7566", + "icon": "/icons/lisa.webp" + }, + { + "id": "voyracloud", + "title": "voyracloud", + "subtitle": "静态住宅 IP 服务器", + "href": "https://www.voyracloud.com/?ref_code=2LJPRTE5", + "icon": "/icons/voyracloud.webp" + } + ] + }, + { + "id": "hardware", + "title": "硬件", + "links": [ + { + "id": "rpi", + "title": "树莓派", + "subtitle": "无与伦比的 ARM 开发板", + "href": "https://uland.taobao.com/coupon/edetail?e=5hkWkiThOmClhHvvyUNXZfh8CuWt5YH5OVuOuRD5gLJMmdsrkidbOWBzzpT26idJPSbzO0ArF68ertbZl9wqRUbeJevxT02sHgNIxyFsmaMOsi2OxhyQb%2BhYUTTNN7GRRSHvQe2jOLZ9pbNCYX0I%2BPP%2BWUTgK%2F%2B0I%2BtaUgbudUxA%2B536asYsLWVfKa%2BhVnND4NyB1fwjO3bJLf667Yy8Q5jB6TX2HR3Qrq8LCw4Dujjqyaqc1rGLUwdQHHM8iY%2BUDMxLRSiIntldeBz90au3REAmOgZ0RtdnfeSBK3KXa0%2FA9snq37kKL6zL4bZ3EAS%2F2oYsLHTsIOxroXBFP6oz%2BA%3D%3D&traceId=213e032e17650447230113327e0c4f&union_lens=lensId%3APUB%401765044691%400b521400_0da4_19af4dca231_da77%400290EZjuZ2xbgOlH3NTYAyI%40eyJmbG9vcklkIjoyMDg3MTcxMDEwLCJzcG1CIjoiiX3BvcnRhbF92Ml90b29sX3NlbGVjdGlvbmxpc3RfZGV0YWlsX2luZGV4X2h0bSIsInNyY0Zsb29ySWQiiOiiI4MDY2NCJ9", + "icon": "/icons/rpi.webp" + }, + { + "id": "mini-pc", + "title": "迷你主机", + "subtitle": "具有性价比的 X86 小主机", + "href": "https://s.click.taobao.com/t?e=m%3D2%26s%3DCb1Quo%2F0Wb5w4vFB6t2Z2ueEDrYVVa64YUrQeSeIhnK53hKxp7mNFuhCZFSw9yq2woqx0EHqItb0JlhLk0Jl4eVWmNyHytKdTKJ80yOOA0Mtd0e5Ku7CIDk5ffgV5fRI1qrpxiwMoCNxc1AtbZGVS936JshS%2F%2FIdwgQgG5hIzyLNEPXytV9ALtCLThlbPuuZLb93Df8fOziGg7JVKZos%2BjLJJgRsfWlWtajntMnDLEHhuApO%2F8klJ62RdK%2B6%2FP7Z6k6s3rDgsC6jO9AJYjY8CXJ%2BwEVkOqHFPSJJXArlDuzso5nyPLY4NPiLqets6lIJ", + "icon": "/icons/mini-pc.webp" + }, + { + "id": "gpu", + "title": "GPU 显卡", + "subtitle": "AI 时代的算力基础设施", + "href": "https://union-click.jd.com/jdc?e=618%7Cpc%7C&p=JF8BATUJK1olXwEDUFZVCkkRC18IGloWWwALV19aAUonRzBQRQQlBENHFRxWFlVPRjtUBABAQlRcCEBdCUoUBWkBGFoSVAcdDRsBVXsQB29pbiZRKGMHKlclCEgVWghcGV91UQoyVW5dCUoWAmYPHl4RbTYCU24fZp-esLulkIK0yd6n5V1eOEonA2kPH1oQWQUFV19VCnsQA2Y4El0dWQ4LU1hBC00SCmcJK2slXjYFVFdJDjlWUXsOaWslXTYBZF5cCEoQAGoLH1kRQQYHV1lbAFcXBWgMGl4RXgUKUllYOEkWAmsBK2vL05J3IB9Uajl8UStqSz4dFQ9jitDJGTlnA2sPH0olImF5ECFaSU0VVAdNQDxuW09KFiw8SyljbW1jcih3JWNxNlwaS0hqWBhoX2sQbQEEVW4", + "icon": "/icons/gpu.webp" + } + ] + }, + { + "id": "software", + "title": "软件", + "links": [ + { + "id": "3x-ui", + "title": "3X-UI", + "subtitle": "科学上网仪表盘", + "href": "https://github.com/MHSanaei/3x-ui", + "icon": "/icons/3x-ui.webp" + }, + { + "id": "mihomo", + "title": "虚空终端 mihomo", + "subtitle": "代理软件以及配置 wiki", + "href": "https://wiki.metacubex.one/config/", + "icon": "/icons/mihomo.webp" + }, + { + "id": "frp", + "title": "frp", + "subtitle": "高性能内网穿透", + "href": "https://gofrp.org/zh-cn/docs/", + "icon": "/icons/frp.webp" + }, + { + "id": "wireguard", + "title": "wireguard", + "subtitle": "P2P 打洞组网", + "href": "https://github.com/WireGuard/wireguard-go", + "icon": "/icons/wireguard.webp" + }, + { + "id": "lineageos", + "title": "lineageos (pi5)", + "subtitle": "树莓派的安卓 LineageOS", + "href": "https://konstakang.com/devices/rpi5/", + "icon": "/icons/lineageos.webp" + } + ] + }, + { + "id": "gear", + "title": "数码装备", + "links": [ + { + "id": "ai-glasses", + "title": "AI 眼镜", + "subtitle": "第一视角拍摄", + "href": "https://union-click.jd.com/jdc?e=618%7Cpc%7C&p=JF8BATkJK1olXw8AXVxfCU8UA18IGloVWwcKXFlZDUgnRzBQRQQlBENHFRxWFlVPRjtUBABAQlRcCEBdCUoXBW4AE1wRWAUdDRsBVXtwXw1pZzNKAmZgFFwlYUh8UzVBZyZlUQoyVW5dCUoWAmYPHl4RbTYCU24fZpO9hbeBtYKjxt-jwInikZ-fjV8JK1sTWgIDUVtVAEkVA2w4HFscbQ8EXFpVAUwRH2wOHlIdXDYyZF1tD0seF2l6WgkBW3QyZF5tC3sXAm8AGFsVXAEBXEJdDUMVB24UG10SWQcHUVZbAE8fCl8KGloRVDYyitPtY0JrQAYIYj0dXGZKMVc5T5Was35jYlMVXQUTZAQOch9SZTMNbC9gIGdQJi5VCzkRSCpfWDUXVAJlDQoCbw1gcG9qRwYdHnYyUW5aDEgn", + "icon": "/icons/ai-glasses.webp" + }, + { + "id": "action-cam", + "title": "运动相机", + "subtitle": "骑行记录仪", + "href": "https://union-click.jd.com/jdc?e=618%7Cpc%7C&p=JF8BASgJK1olXDYCVV9eCE0UB28ME1slGVlaCgFtUQ5SQi0DBUVNGFJeSwUIFxlJX3EIGloWXQABUF5ZAEsIWipURmt3CFhXIQkpbChuRy8JGDpRJUJQDwkbBEcnAl8IGloUXA8FUVtZOHsXBF9edVsUXAcDVV1fDEonAl8IHVwRXAMGVVpaDEsUM2gIEmscWw4GXFdaDlcUBWoBE1olbTYBZFldAV8RcS5aD11nbTYCZF1tCEoXAmsNHl8UXQQeVF1ZDE0UH28OHF8UWAIDUVddCkgnAW4JH1IlbdiMwDxcaAJfBTlNTRpCBHpHLhyDht8GcR8BHFIUTDZ6NSMpYRJweWtBfAUXC2JyXBkpfTNRWi1mGV4UAlgENFpeDA13cRRcTAJLbQMyU1peOA", + "icon": "/icons/action-cam.webp" + }, + { + "id": "drone", + "title": "无人机", + "subtitle": "天空视角", + "href": "https://union-click.jd.com/jdc?e=618%7Cpc%7C&p=JF8BASgJK1olXDYCVV9eAUIeB2YMH14lGVlaCgFtUQ5SQi0DBUVNGFJeSwUIFxlJX3EIGloWVA8LUFdZDE4IWipURmtCHHVEABsFVChPYRJAbVhlGRhbFRgLBEcnAl8IGloUXA8FUVtZOHsXBF9edVsUXAcDVV1fDEonAl8IHVwRXAMGVVdbC04VM2gIEmscWw4GXFdaDlcUBWoBE1olbTYBZFldAV8RcS5aD11nbTYCZF1tCEoXAmgLHlgRXgIeVFpfDU0UH28OHF8UWAIDUlteAUwnAW4JH1IlbdiMwCQvcipMBxJhfV9HGgF3FVaDht8GfxgBGVkRTDZUCjsVbzBTYRJbeRkWGG9WAx02D0JcUy5mGRNRFEJiUwgldStzfx1wTj1GbQMyU1peOA", + "icon": "/icons/drone.webp" + } + ] + } + ] + }, + { + "id": "overseas", + "title": "出海掘金", + "emoji": "◎", + "groups": [ + { + "id": "tiktok", + "title": "TikTok", + "links": [ + { + "id": "tiktok", + "title": "TikTok", + "subtitle": "全球直播平台", + "href": "https://www.tiktok.com/", + "icon": "/icons/tiktok.webp" + }, + { + "id": "cloud-phone", + "title": "云手机", + "subtitle": "用开源硬件打造云手机", + "href": "https://www.hackrobot.cn/", + "icon": "/icons/cloud-phone.webp" + }, + { + "id": "vcam", + "title": "vcam 虚拟摄像头", + "subtitle": "Xposed 模块,替换摄像头视频流", + "href": "https://pan.baidu.com/s/1NW4GMGA3cxfUQNWZPD9vOg?pwd=live", + "icon": "/icons/vcam.webp" + } + ] + }, + { + "id": "youtube", + "title": "YouTube", + "links": [ + { + "id": "youtube", + "title": "YouTube", + "subtitle": "全球最大的视频网站", + "href": "https://www.youtube.com/", + "icon": "/icons/youtube.webp" + }, + { + "id": "smmfollows", + "title": "smmfollows", + "subtitle": "刷粉刷量平台", + "href": "https://smmfollows.com/ref/dfugq", + "icon": "/icons/smmfollows.webp" + }, + { + "id": "yt-auto-dismiss", + "title": "YouTube Studio Auto Dismiss", + "subtitle": "油猴脚本,无人直播辅助", + "href": "https://greasyfork.org/zh-CN/scripts/557378-youtube-studio-auto-dismiss", + "icon": "/icons/yt-auto-dismiss.webp" + } + ] + }, + { + "id": "web", + "title": "Web 网站", + "links": [ + { + "id": "namesilo", + "title": "namesilo", + "subtitle": "注册域名", + "href": "https://www.namesilo.com/?rid=3bd4047mc", + "icon": "/icons/namesilo.webp" + }, + { + "id": "aapanel", + "title": "aapanel", + "subtitle": "宝塔面板", + "href": "https://www.aapanel.com?referral_code=wcn04vez", + "icon": "/icons/aapanel.webp" + }, + { + "id": "cloudflare", + "title": "Cloudflare", + "subtitle": "互联网基础节点", + "href": "https://www.cloudflare.com/", + "icon": "/icons/cloudflare.webp" + }, + { + "id": "ga", + "title": "Google Analytics", + "subtitle": "网站流量统计服务", + "href": "https://analytics.google.com/", + "icon": "/icons/ga.webp" + }, + { + "id": "adsense", + "title": "Google AdSense", + "subtitle": "Google 广告服务", + "href": "https://www.google.com/adsense/", + "icon": "/icons/adsense.webp" + } + ] + } + ] + }, + { + "id": "live", + "title": "无人直播", + "emoji": "▷", + "groups": [ + { + "id": "live-soft", + "title": "软件", + "links": [ + { + "id": "obs", + "title": "OBS", + "subtitle": "免费开源:录屏 / 推流直播", + "href": "https://pan.quark.cn/s/03e89f1bbc9b", + "icon": "/icons/obs.webp" + }, + { + "id": "ffmpeg", + "title": "ffmpeg", + "subtitle": "命令行视频处理 / 推流,Python 自动化", + "href": "https://www.ffmpeg.org/download.html", + "icon": "/icons/ffmpeg.webp" + }, + { + "id": "srs", + "title": "SRS", + "subtitle": "开源直播服务器,拉流推流中转", + "href": "https://ossrs.io/", + "icon": "/icons/srs.webp" + } + ] + } + ] + }, + { + "id": "pay", + "title": "支付网关", + "emoji": "◇", + "groups": [ + { + "id": "merchant", + "title": "小微商户", + "links": [ + { + "id": "nowpayments", + "title": "NOWPayments", + "subtitle": "加密货币收款", + "href": "https://account.nowpayments.io/create-account?link_id=3680795921", + "icon": "/icons/nowpayments.webp" + }, + { + "id": "creem", + "title": "Creem", + "subtitle": "软件出海收款,税务合规", + "href": "https://www.creem.io/", + "icon": "/icons/creem.webp" + }, + { + "id": "stripe", + "title": "Stripe", + "subtitle": "全球在线支付", + "href": "https://stripe.com/", + "icon": "/icons/stripe.webp" + }, + { + "id": "zpay", + "title": "z-pay", + "subtitle": "支持独角数卡 · 易支付", + "href": "https://z-pay.cn/?uid=22119", + "icon": "/icons/zpay.webp" + }, + { + "id": "xorpay", + "title": "xorpay", + "subtitle": "支持收银台支付", + "href": "https://xorpay.com?r=nomadro", + "icon": "/icons/xorpay.webp" + } + ] + } + ] + }, + { + "id": "books", + "title": "书籍", + "emoji": "◈", + "groups": [ + { + "id": "handbook", + "title": "手册", + "links": [ + { + "id": "nomad-book", + "title": "数字游民手册", + "subtitle": "复制链接后在小红书打开", + "href": "https://www.xiaohongshu.com/s/poster?bgimg=https%3A%2F%2Fsns-redskillhub-s1.xhscdn.com%2Fred_app_image%2F1040g4m8325ke1q36l0404a4druqrlvd5valvb80%3Fsign%3Dbc0c41c2e219f6ca904f52176bd17f54%26t%3D6c9a7a85&xhsshare=&appuid=5acc75ba4eacab15c751fda5&apptime=1790527237&deeplink=xhsdiscover%3A%2F%2FminiTool%2F6ab8984da1e3af0015584e92%3Fsource%3Dh5%26page_key%3D28%26xhsMpScreenMode%3Dfull%26share_id%3D5e90e5979b054c8baf8b3db4c8993d79%26share_channel%3Dcopy_link", + "icon": "/icons/nomad-book.webp", + "action": "copy" + } + ] + } + ] + }, + { + "id": "forum", + "title": "论坛社区", + "emoji": "◉", + "groups": [ + { + "id": "blog", + "title": "博客", + "links": [ + { + "id": "yidu", + "title": "异度世界", + "subtitle": "独立博客,Hugo 搭建", + "href": "https://blog.hackrobot.cn", + "icon": "/icons/yidu.webp" + }, + { + "id": "dsx", + "title": "大师兄", + "subtitle": "AI 实践", + "href": "https://dsx2016.com", + "icon": "/icons/dsx.webp" + } + ] + } + ] + } + ] +}; diff --git a/apps/miniprogram/xhs/tool/styles.css b/apps/miniprogram/xhs/tool/styles.css new file mode 100644 index 0000000..ced7909 --- /dev/null +++ b/apps/miniprogram/xhs/tool/styles.css @@ -0,0 +1,944 @@ +:root, +[data-theme="light"] { + --bg: #e9eef4; + --bg-elevated: #f7fafc; + --ink: #15202b; + --ink-muted: #5b6b7c; + --ink-faint: #8a98a8; + --line: rgba(21, 32, 43, 0.08); + --surface: rgba(255, 255, 255, 0.88); + --surface-solid: #ffffff; + --accent: #0d8f7b; + --accent-deep: #0a6e5f; + --accent-soft: rgba(13, 143, 123, 0.12); + --glow-a: rgba(13, 143, 123, 0.2); + --glow-b: rgba(56, 120, 180, 0.14); + --shadow: 0 8px 24px rgba(21, 32, 43, 0.08); + --shadow-card: 0 1px 2px rgba(21, 32, 43, 0.04), 0 6px 16px rgba(21, 32, 43, 0.04); + --toast-bg: #15202b; + --toast-ink: #f4f7fa; + --chip: rgba(21, 32, 43, 0.045); + --chip-active: #15202b; + --chip-active-ink: #f7fafc; + --topbar-bg: rgba(233, 238, 244, 0.9); + --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", + "Microsoft YaHei", "Noto Sans SC", sans-serif; + --radius: 14px; + --app-pad-top: 80px; + --safe-bottom: env(safe-area-inset-bottom, 0px); +} + +[data-theme="dark"] { + --bg: #0a0f14; + --bg-elevated: #121820; + --ink: #e8eef4; + --ink-muted: #8b99a8; + --ink-faint: #5d6c7c; + --line: rgba(232, 238, 244, 0.1); + --surface: rgba(18, 24, 32, 0.92); + --surface-solid: #121820; + --accent: #3dceb8; + --accent-deep: #2aa892; + --accent-soft: rgba(61, 206, 184, 0.14); + --glow-a: rgba(61, 206, 184, 0.14); + --glow-b: rgba(70, 130, 200, 0.12); + --shadow: 0 10px 28px rgba(0, 0, 0, 0.35); + --shadow-card: 0 1px 0 rgba(255, 255, 255, 0.03), 0 8px 20px rgba(0, 0, 0, 0.28); + --toast-bg: #e8eef4; + --toast-ink: #0a0f14; + --chip: rgba(232, 238, 244, 0.06); + --chip-active: #e8eef4; + --chip-active-ink: #0a0f14; + --topbar-bg: rgba(10, 15, 20, 0.9); +} + +*, +*::before, +*::after { + box-sizing: border-box; +} + +html, +body { + margin: 0; + min-height: 100%; + background: var(--bg); + color: var(--ink); + font-family: var(--font); + -webkit-font-smoothing: antialiased; + -webkit-tap-highlight-color: transparent; +} + +button { + font: inherit; + color: inherit; + border: none; + background: none; + padding: 0; + cursor: pointer; +} + +img { + display: block; +} + +.app-shell { + position: relative; + min-height: 100vh; + isolation: isolate; +} + +.bg-glow { + position: fixed; + inset: 0; + pointer-events: none; + z-index: 0; + overflow: hidden; + background: + radial-gradient(680px 380px at 8% -12%, var(--glow-a), transparent 58%), + radial-gradient(560px 320px at 100% 4%, var(--glow-b), transparent 55%), + var(--bg); +} + +.orb { + position: absolute; + border-radius: 50%; + opacity: 0.5; +} + +.orb-a { + width: 200px; + height: 200px; + left: -60px; + top: 18%; + background: radial-gradient(circle, var(--glow-a), transparent 70%); +} + +.orb-b { + width: 240px; + height: 240px; + right: -80px; + top: 42%; + background: radial-gradient(circle, var(--glow-b), transparent 70%); +} + +.topbar { + position: sticky; + top: 0; + z-index: 30; + display: flex; + align-items: center; + gap: 10px; + padding: calc(var(--app-pad-top) + 8px) 12px 10px; + background: var(--topbar-bg); + backdrop-filter: blur(14px); + -webkit-backdrop-filter: blur(14px); + border-bottom: 1px solid var(--line); +} + +.icon-btn { + width: 36px; + height: 36px; + border-radius: 11px; + background: var(--surface); + border: 1px solid var(--line); + box-shadow: var(--shadow-card); + display: grid; + place-items: center; + flex-shrink: 0; + font-size: 1rem; +} + +.icon-btn:active { + transform: scale(0.94); +} + +.menu-bars { + display: flex; + flex-direction: column; + gap: 3.5px; + width: 14px; +} + +.menu-bars i { + display: block; + height: 1.5px; + border-radius: 1px; + background: var(--ink); +} + +.brand-mark { + display: flex; + align-items: center; + gap: 8px; + min-width: 0; + flex: 1; +} + +.brand-logo { + width: 28px; + height: 28px; + border-radius: 8px; + object-fit: cover; + border: 1px solid var(--line); +} + +.brand-text { + min-width: 0; + display: flex; + flex-direction: column; + align-items: flex-start; + justify-content: center; + gap: 2px; +} + +.brand-name { + margin: 0; + font-size: 1rem; + font-weight: 700; + letter-spacing: -0.02em; + line-height: 1.2; +} + +.brand-current { + margin: 0; + max-width: 100%; + font-size: 0.72rem; + font-weight: 600; + letter-spacing: -0.01em; + line-height: 1.25; + color: var(--accent-deep); + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} + +[data-theme="dark"] .brand-current { + color: var(--accent); +} + +.page { + position: relative; + z-index: 1; + padding: 12px 12px calc(72px + var(--safe-bottom)); +} + +.cat-panel + .cat-panel { + margin-top: 22px; +} + +.cat-panel { + scroll-margin-top: calc(var(--app-pad-top) + 52px); +} + +.cat-heading { + display: flex; + align-items: center; + gap: 8px; + margin: 0 0 10px; + padding-left: 10px; + position: relative; +} + +.cat-heading::before { + content: ""; + position: absolute; + left: 0; + top: 0.25em; + bottom: 0.25em; + width: 3px; + border-radius: 99px; + background: var(--accent); +} + +.cat-heading h2 { + margin: 0; + font-size: 1.05rem; + font-weight: 700; +} + +.cat-count { + font-size: 0.66rem; + font-weight: 700; + color: var(--accent-deep); + background: var(--accent-soft); + padding: 2px 7px; + border-radius: 999px; +} + +[data-theme="dark"] .cat-count { + color: var(--accent); +} + +.group-block + .group-block { + margin-top: 12px; +} + +.group-title { + margin: 0 0 7px; + font-size: 0.7rem; + font-weight: 700; + letter-spacing: 0.04em; + text-transform: uppercase; + color: var(--ink-faint); +} + +.link-grid { + display: grid; + grid-template-columns: repeat(2, minmax(0, 1fr)); + gap: 7px; +} + +.link-card { + display: flex; + align-items: center; + gap: 8px; + width: 100%; + min-width: 0; + text-align: left; + padding: 9px; + border-radius: var(--radius); + background: var(--surface); + border: 1px solid var(--line); + box-shadow: var(--shadow-card); +} + +.link-card:active { + transform: scale(0.978); +} + +.link-icon-wrap { + width: 34px; + height: 34px; + border-radius: 10px; + overflow: hidden; + border: 1px solid var(--line); + background: var(--chip); + flex-shrink: 0; +} + +.link-icon { + width: 100%; + height: 100%; + object-fit: cover; +} + +.link-meta { + min-width: 0; + flex: 1; +} + +.link-title { + display: block; + font-size: 0.82rem; + font-weight: 700; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} + +.link-desc { + display: block; + margin-top: 2px; + font-size: 0.65rem; + color: var(--ink-muted); + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; +} + +.footer { + margin-top: 28px; + padding-top: 14px; + border-top: 1px solid var(--line); + text-align: center; + font-size: 0.7rem; + color: var(--ink-faint); +} + +.drawer-root { + position: fixed; + inset: 0; + z-index: 60; + pointer-events: none; +} + +.drawer-root.open { + pointer-events: auto; +} + +.drawer-mask { + position: absolute; + inset: 0; + background: rgba(8, 12, 18, 0.46); + opacity: 0; + transition: opacity 0.22s ease; +} + +.drawer-root.open .drawer-mask { + opacity: 1; +} + +.drawer-panel { + position: absolute; + top: 0; + left: 0; + bottom: 0; + width: min(80vw, 300px); + background: var(--bg-elevated); + border-right: 1px solid var(--line); + box-shadow: var(--shadow); + transform: translateX(-104%); + transition: transform 0.26s cubic-bezier(0.22, 1, 0.36, 1); + display: flex; + flex-direction: column; + padding: calc(var(--app-pad-top) + 4px) 0 calc(16px + var(--safe-bottom)); +} + +.drawer-root.open .drawer-panel { + transform: translateX(0); +} + +.drawer-head { + display: flex; + align-items: center; + justify-content: space-between; + gap: 10px; + padding: 4px 12px 12px; + border-bottom: 1px solid var(--line); +} + +.drawer-brand-wrap { + display: flex; + align-items: center; + gap: 8px; + min-width: 0; +} + +.drawer-brand-wrap img { + width: 28px; + height: 28px; + border-radius: 8px; + object-fit: cover; + border: 1px solid var(--line); +} + +.drawer-brand { + display: block; + font-weight: 700; + font-size: 1rem; +} + +.drawer-sub { + display: block; + margin-top: 2px; + font-size: 0.68rem; + color: var(--ink-muted); +} + +.drawer-nav { + padding: 12px 10px; + overflow-y: auto; + -webkit-overflow-scrolling: touch; +} + +.drawer-item { + display: flex; + align-items: center; + gap: 10px; + width: 100%; + text-align: left; + padding: 12px; + border-radius: 12px; + color: var(--ink-muted); + margin-bottom: 4px; +} + +.drawer-item.active { + background: var(--accent-soft); + color: var(--accent); +} + +.drawer-item-title { + flex: 1; + font-size: 0.92rem; + font-weight: 600; + color: inherit; +} + +.drawer-item.active .drawer-item-title { + color: var(--ink); +} + +.drawer-item-count { + font-size: 0.68rem; + font-weight: 650; + background: var(--chip); + color: var(--ink-faint); + padding: 2px 7px; + border-radius: 999px; +} + +.back-top { + position: fixed; + right: 14px; + bottom: calc(18px + var(--safe-bottom)); + width: 40px; + height: 40px; + border-radius: 14px; + background: var(--chip-active); + color: var(--chip-active-ink); + box-shadow: var(--shadow); + opacity: 0; + pointer-events: none; + transform: translateY(8px); + transition: opacity 0.2s ease, transform 0.2s ease; + z-index: 40; + font-size: 1rem; +} + +.back-top.show { + opacity: 1; + pointer-events: auto; + transform: translateY(0); +} + +/* Link detail sheet */ +.sheet-root { + position: fixed; + inset: 0; + z-index: 70; + pointer-events: none; +} + +.sheet-root.open { + pointer-events: auto; +} + +.sheet-mask { + position: absolute; + inset: 0; + background: rgba(8, 12, 18, 0.48); + opacity: 0; + transition: opacity 0.22s ease; +} + +.sheet-root.open .sheet-mask { + opacity: 1; +} + +.sheet-panel { + position: absolute; + left: 0; + right: 0; + bottom: 0; + max-height: min(86vh, 640px); + overflow-y: auto; + -webkit-overflow-scrolling: touch; + background: var(--bg-elevated); + border-radius: 20px 20px 0 0; + border: 1px solid var(--line); + border-bottom: none; + box-shadow: var(--shadow); + padding: 10px 16px calc(16px + var(--safe-bottom)); + transform: translateY(108%); + transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1); + display: flex; + flex-direction: column; + gap: 12px; +} + +.sheet-root.open .sheet-panel { + transform: translateY(0); +} + +.sheet-handle { + width: 36px; + height: 4px; + border-radius: 99px; + background: var(--chip); + margin: 0 auto 4px; +} + +.sheet-head { + display: flex; + align-items: center; + gap: 12px; +} + +.sheet-icon { + width: 44px; + height: 44px; + border-radius: 12px; + object-fit: cover; + border: 1px solid var(--line); + background: var(--chip); + flex-shrink: 0; +} + +.sheet-head-text { + min-width: 0; + flex: 1; +} + +.sheet-title { + margin: 0; + font-size: 1.05rem; + font-weight: 700; + letter-spacing: -0.02em; +} + +.sheet-sub { + margin: 4px 0 0; + font-size: 0.78rem; + color: var(--ink-muted); + line-height: 1.35; +} + +/* Visual guide steps */ +.guide-steps { + list-style: none; + margin: 0; + padding: 10px; + border-radius: 14px; + background: var(--chip); + border: 1px solid var(--line); + display: flex; + flex-direction: column; + gap: 8px; +} + +.guide-step { + display: flex; + align-items: flex-start; + gap: 10px; + opacity: 0.42; + transition: opacity 0.25s ease, transform 0.25s ease; + transform: translateX(0); +} + +.guide-step.is-active { + opacity: 1; + transform: translateX(2px); +} + +.guide-step.is-done { + opacity: 0.78; +} + +.guide-step.is-done .guide-num { + background: var(--accent); + color: #fff; +} + +.guide-num { + width: 24px; + height: 24px; + border-radius: 50%; + flex-shrink: 0; + display: grid; + place-items: center; + font-size: 0.75rem; + font-weight: 800; + background: var(--surface-solid); + border: 1px solid var(--line); + color: var(--ink-muted); +} + +.guide-step.is-active .guide-num { + background: var(--chip-active); + color: var(--chip-active-ink); + border-color: transparent; + box-shadow: 0 0 0 4px var(--accent-soft); + animation: num-pop 0.35s ease; +} + +.guide-text { + display: flex; + flex-direction: column; + gap: 2px; + min-width: 0; + padding-top: 1px; +} + +.guide-text strong { + font-size: 0.84rem; + font-weight: 750; + color: var(--ink); +} + +.guide-text em { + font-style: normal; + font-size: 0.72rem; + color: var(--ink-muted); +} + +.sheet-label { + margin: 0 0 8px; + font-size: 0.7rem; + font-weight: 700; + letter-spacing: 0.04em; + text-transform: uppercase; + color: var(--ink-faint); +} + +.url-stage { + position: relative; +} + +.sheet-url-wrap { + position: relative; +} + +.sheet-url-box { + padding: 14px 12px; + border-radius: 14px; + background: color-mix(in srgb, var(--accent) 8%, var(--surface-solid)); + border: 2px solid color-mix(in srgb, var(--accent) 45%, var(--line)); + font-size: 0.86rem; + line-height: 1.5; + word-break: break-all; + user-select: text; + -webkit-user-select: text; + color: var(--ink); + transition: box-shadow 0.25s ease, border-color 0.25s ease, background 0.25s ease; + position: relative; + z-index: 1; +} + +.sheet-url-box.is-pulse { + animation: url-pulse 1.4s ease-in-out infinite; +} + +.sheet-url-box.is-selected { + border-color: var(--accent); + background: color-mix(in srgb, var(--accent) 16%, var(--surface-solid)); + box-shadow: 0 0 0 4px var(--accent-soft); + animation: none; +} + +.finger-ico { + font-size: 1.75rem; + line-height: 1; + filter: drop-shadow(0 3px 6px rgba(0, 0, 0, 0.2)); +} + +.finger-btn.is-hidden, +.finger-url.is-hidden { + display: none !important; +} + +/* 第一步:仅小手,悬浮在绿色按钮上方,朝下指 */ +.sheet-actions-wrap { + position: relative; + padding-top: 36px; +} + +.finger-btn { + position: absolute; + left: 22%; + top: 0; + z-index: 3; + pointer-events: none; + display: flex; + align-items: center; + justify-content: center; + animation: finger-bounce-down 1.1s ease-in-out infinite; +} + +.finger-btn .finger-ico { + display: block; +} + +/* 第二步:小手紧贴网址区下沿朝上指,文案在右边 */ +.sheet-url-wrap.is-pointing { + padding-bottom: 34px; +} + +.finger-url { + position: absolute; + left: 6px; + top: auto; + bottom: 0; + z-index: 3; + pointer-events: none; + display: flex; + flex-direction: row; + align-items: center; + gap: 8px; + max-width: calc(100% - 12px); + animation: finger-nudge-up 1.05s ease-in-out infinite; +} + +.finger-url .finger-ico { + flex-shrink: 0; +} + +.finger-url .finger-bubble { + max-width: 150px; + padding: 6px 9px; + border-radius: 10px; + background: var(--chip-active); + color: var(--chip-active-ink); + font-size: 0.68rem; + font-weight: 700; + line-height: 1.3; + text-align: left; + box-shadow: var(--shadow); + position: relative; +} + +.finger-url .finger-bubble::before { + content: ""; + position: absolute; + left: -4px; + top: 50%; + width: 8px; + height: 8px; + background: var(--chip-active); + transform: translateY(-50%) rotate(45deg); +} + +.sheet-status { + margin: 10px 0 0; + min-height: 1.2em; + font-size: 0.78rem; + font-weight: 650; + color: var(--accent-deep); + line-height: 1.4; +} + +[data-theme="dark"] .sheet-status { + color: var(--accent); +} + +.sheet-status.is-error { + color: #c44; +} + +.sheet-actions { + display: grid; + grid-template-columns: 1.7fr 0.9fr; + gap: 8px; +} + +.sheet-btn { + min-height: 48px; + border-radius: 14px; + border: 1px solid var(--line); + background: var(--surface); + font-size: 0.9rem; + font-weight: 650; + padding: 8px 10px; +} + +.sheet-btn.primary { + background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 88%, #fff), var(--accent-deep)); + color: #fff; + border-color: transparent; + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + gap: 2px; +} + +.sheet-btn.primary.pulse { + animation: cta-pulse 1.5s ease-in-out infinite; +} + +.sheet-btn.primary.is-done { + animation: none; + background: var(--chip); + color: var(--ink); + border: 1px solid var(--line); +} + +.sheet-btn-main { + font-size: 0.92rem; + font-weight: 800; +} + +.sheet-btn-sub { + font-size: 0.66rem; + font-weight: 600; + opacity: 0.88; +} + +.sheet-btn:active { + transform: scale(0.98); +} + +@keyframes url-pulse { + 0%, + 100% { + box-shadow: 0 0 0 0 var(--accent-soft); + } + 50% { + box-shadow: 0 0 0 6px var(--accent-soft); + } +} + +@keyframes cta-pulse { + 0%, + 100% { + transform: scale(1); + box-shadow: 0 0 0 0 rgba(13, 143, 123, 0.35); + } + 50% { + transform: scale(1.015); + box-shadow: 0 0 0 8px rgba(13, 143, 123, 0); + } +} + +@keyframes finger-bounce-down { + 0%, + 100% { + transform: translateY(0); + } + 50% { + transform: translateY(6px); + } +} + +@keyframes finger-nudge-up { + 0%, + 100% { + transform: translateY(0); + } + 50% { + transform: translateY(-6px); + } +} + +@keyframes num-pop { + from { + transform: scale(0.7); + } + to { + transform: scale(1); + } +} + +.toast { + position: fixed; + left: 50%; + bottom: calc(28px + var(--safe-bottom)); + transform: translateX(-50%) translateY(10px); + padding: 9px 16px; + border-radius: 999px; + background: var(--toast-bg); + color: var(--toast-ink); + font-size: 0.8rem; + font-weight: 600; + opacity: 0; + pointer-events: none; + transition: opacity 0.2s ease, transform 0.2s ease; + z-index: 80; + box-shadow: var(--shadow); +} + +.toast.show { + opacity: 1; + transform: translateX(-50%) translateY(0); +} diff --git a/apps/navmini/src/App.tsx b/apps/navmini/src/App.tsx index 82c6dc5..2575dbb 100644 --- a/apps/navmini/src/App.tsx +++ b/apps/navmini/src/App.tsx @@ -9,11 +9,11 @@ const nav = config as NavConfig type Theme = 'light' | 'dark' function readTheme(): Theme { + const shared = localStorage.getItem('nomadro-theme') + if (shared === 'light' || shared === 'dark') return shared const saved = localStorage.getItem('navmini-theme') if (saved === 'light' || saved === 'dark') return saved - return window.matchMedia('(prefers-color-scheme: dark)').matches - ? 'dark' - : 'light' + return 'dark' } function countLinks(cat: NavCategory) { @@ -62,6 +62,28 @@ function IconMoon() { ) } +function PortalLogoMark() { + return ( + + + + + + + + + + + + + ) +} + function IconUp() { return ( @@ -77,7 +99,7 @@ function IconUp() { } export default function App() { - const [theme, setTheme] = useState('light') + const [theme, setTheme] = useState('dark') const [activeId, setActiveId] = useState(nav.categories[0]?.id ?? '') const [drawerOpen, setDrawerOpen] = useState(false) const [toast, setToast] = useState('') @@ -92,9 +114,12 @@ export default function App() { useEffect(() => { document.documentElement.dataset.theme = theme + document.documentElement.classList.remove('light', 'dark') + document.documentElement.classList.add(theme) localStorage.setItem('navmini-theme', theme) + localStorage.setItem('nomadro-theme', theme) const meta = document.querySelector('meta[name="theme-color"]') - if (meta) meta.setAttribute('content', theme === 'dark' ? '#0a0f14' : '#e9eef4') + if (meta) meta.setAttribute('content', theme === 'dark' ? '#0a0e17' : '#f8fafc') }, [theme]) useEffect(() => { @@ -231,35 +256,30 @@ export default function App() { -
- -
-

{nav.brand}

-

- {activeCategory.title} -

-
-
+ + + nomadro + + · + + 导航 +

{activeCategory.title}

- +
+ +
diff --git a/apps/navmini/src/styles/global.css b/apps/navmini/src/styles/global.css index fba4877..09d7a92 100644 --- a/apps/navmini/src/styles/global.css +++ b/apps/navmini/src/styles/global.css @@ -1,4 +1,38 @@ +/* Default = hub night mode; light is opt-in via data-theme */ :root, +[data-theme='dark'] { + --bg: #0a0e17; + --bg-elevated: #111827; + --ink: #f1f5f9; + --ink-muted: #94a3b8; + --ink-faint: #64748b; + --line: rgba(255, 255, 255, 0.08); + --surface: rgba(17, 24, 39, 0.7); + --surface-solid: #111827; + --surface-hover: rgba(17, 24, 39, 0.92); + --accent: #4ecdc4; + --accent-deep: #2bb8ae; + --accent-soft: rgba(78, 205, 196, 0.14); + --glow-a: rgba(255, 107, 107, 0.28); + --glow-b: rgba(78, 205, 196, 0.22); + --glow-c: rgba(255, 230, 109, 0.18); + --hub-gradient-text: linear-gradient(135deg, #ff6b6b 0%, #ffe66d 50%, #4ecdc4 100%); + --shadow: 0 0 40px rgba(78, 205, 196, 0.12); + --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.3); + --toast-bg: #f1f5f9; + --toast-ink: #0a0e17; + --chip: rgba(255, 255, 255, 0.05); + --chip-active: rgba(78, 205, 196, 0.16); + --chip-active-ink: #4ecdc4; + --topbar-bg: rgba(10, 14, 23, 0.85); + --rail: #4ecdc4; + --font-display: var(--font-outfit), 'Sora', system-ui, sans-serif; + --font-body: var(--font-noto-sc), 'Manrope', 'PingFang SC', 'Noto Sans SC', system-ui, sans-serif; + --radius: 14px; + --max-w: 560px; + --rail-w: 0px; +} + [data-theme='light'] { --bg: #e9eef4; --bg-elevated: #f7fafc; @@ -14,6 +48,8 @@ --accent-soft: rgba(13, 143, 123, 0.12); --glow-a: rgba(13, 143, 123, 0.2); --glow-b: rgba(56, 120, 180, 0.14); + --glow-c: rgba(13, 143, 123, 0.08); + --hub-gradient-text: none; --shadow: 0 8px 24px rgba(21, 32, 43, 0.06); --shadow-card: 0 1px 2px rgba(21, 32, 43, 0.04), 0 6px 16px rgba(21, 32, 43, 0.04); --toast-bg: #15202b; @@ -25,41 +61,12 @@ --rail: #0d8f7b; --font-display: 'Sora', system-ui, sans-serif; --font-body: 'Manrope', 'PingFang SC', 'Noto Sans SC', system-ui, sans-serif; - --radius: 14px; - --max-w: 560px; - --rail-w: 0px; } -[data-theme='dark'] { - --bg: #0a0f14; - --bg-elevated: #121820; - --ink: #e8eef4; - --ink-muted: #8b99a8; - --ink-faint: #5d6c7c; - --line: rgba(232, 238, 244, 0.1); - --surface: rgba(18, 24, 32, 0.88); - --surface-solid: #121820; - --surface-hover: #18212c; - --accent: #3dceb8; - --accent-deep: #2aa892; - --accent-soft: rgba(61, 206, 184, 0.14); - --glow-a: rgba(61, 206, 184, 0.14); - --glow-b: rgba(70, 130, 200, 0.12); - --shadow: 0 10px 28px rgba(0, 0, 0, 0.35); - --shadow-card: 0 1px 0 rgba(255, 255, 255, 0.03), 0 8px 20px rgba(0, 0, 0, 0.28); - --toast-bg: #e8eef4; - --toast-ink: #0a0f14; - --chip: rgba(232, 238, 244, 0.06); - --chip-active: #e8eef4; - --chip-active-ink: #0a0f14; - --topbar-bg: rgba(10, 15, 20, 0.82); - --rail: #3dceb8; -} - -*, -*::before, -*::after { - box-sizing: border-box; +.navmini-root { + min-height: 100dvh; + background: var(--bg, #0a0e17); + color: var(--ink, #f1f5f9); } html, @@ -115,7 +122,7 @@ button { background: radial-gradient(680px 380px at 8% -12%, var(--glow-a), transparent 58%), radial-gradient(560px 320px at 100% 4%, var(--glow-b), transparent 55%), - radial-gradient(420px 280px at 50% 100%, rgba(13, 143, 123, 0.06), transparent 60%), + radial-gradient(420px 280px at 50% 100%, var(--glow-c, rgba(13, 143, 123, 0.06)), transparent 60%), var(--bg); } @@ -130,6 +137,11 @@ button { animation: grain 8s steps(6) infinite; } +[data-theme='dark'] .bg-glow::after { + opacity: 0.22; + mix-blend-mode: overlay; +} + .orb { position: absolute; border-radius: 50%; @@ -161,24 +173,41 @@ button { height: 180px; left: 35%; bottom: 8%; - background: radial-gradient(circle, rgba(13, 143, 123, 0.18), transparent 70%); + background: radial-gradient(circle, var(--glow-c, rgba(13, 143, 123, 0.18)), transparent 70%); animation: drift-c 14s ease-in-out infinite; } +[data-theme='dark'] .orb-a { + opacity: 0.7; + filter: blur(48px); +} + +[data-theme='dark'] .orb-b { + opacity: 0.65; + filter: blur(52px); +} + +[data-theme='dark'] .orb-c { + opacity: 0.55; + filter: blur(44px); +} + .topbar { - padding: 10px 14px; + padding: 0.75rem 1rem; } .brand-row { display: flex; align-items: center; gap: 10px; + max-width: 1200px; + margin: 0 auto; } .icon-btn { - width: 36px; - height: 36px; - border-radius: 11px; + width: 44px; + height: 44px; + border-radius: 12px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-card); @@ -206,12 +235,65 @@ button { display: block; } -.brand-mark { - display: flex; +/* 对齐 VIP 顶栏:logo 回首页,始终可见 */ +.nav-portal-logo { + display: inline-flex; align-items: center; - gap: 10px; + gap: 0.45rem; min-width: 0; + min-height: 44px; flex: 1; + text-decoration: none; + color: inherit; + font-weight: 800; + font-size: 1.05rem; + letter-spacing: -0.02em; +} + +.nav-portal-mark { + width: 28px; + height: 28px; + flex-shrink: 0; +} + +.nav-portal-brand { + font-family: var(--font-display); + background: var(--hub-gradient-text); + -webkit-background-clip: text; + background-clip: text; + color: transparent; +} + +[data-theme='light'] .nav-portal-brand { + background: none; + -webkit-background-clip: unset; + background-clip: unset; + color: var(--ink); +} + +.nav-portal-sep { + opacity: 0.45; + font-weight: 500; + flex-shrink: 0; +} + +.nav-portal-section { + font-weight: 600; + opacity: 0.9; + font-size: 0.95rem; + flex-shrink: 0; +} + +.nav-top-actions { + display: inline-flex; + align-items: center; + gap: 0.4rem; + margin-left: auto; + flex-shrink: 0; +} + +.brand-mark { + display: none; } .brand-mark img { @@ -240,6 +322,31 @@ button { font-weight: 700; letter-spacing: -0.02em; line-height: 1.2; + background: var(--hub-gradient-text); + -webkit-background-clip: text; + background-clip: text; + color: transparent; + background-size: 200% auto; + animation: nav-gradient-shift 4s ease-in-out infinite; +} + +[data-theme='light'] .brand-name { + background: none; + -webkit-background-clip: unset; + background-clip: unset; + color: var(--ink); + -webkit-text-fill-color: unset; + animation: none; +} + +@keyframes nav-gradient-shift { + 0%, + 100% { + background-position: 0% center; + } + 50% { + background-position: 100% center; + } } .brand-current { @@ -301,9 +408,9 @@ html { .sticky-stack { position: sticky; top: 0; - z-index: 30; - width: min(100%, var(--max-w)); - margin: 0 auto; + z-index: 50; + width: 100%; + margin: 0; background: var(--topbar-bg); backdrop-filter: blur(18px) saturate(1.2); -webkit-backdrop-filter: blur(18px) saturate(1.2); @@ -597,6 +704,19 @@ html { box-shadow: 0 8px 22px rgba(13, 143, 123, 0.1); } +[data-theme='dark'] .link-card { + backdrop-filter: blur(18px); + -webkit-backdrop-filter: blur(18px); +} + +[data-theme='dark'] .link-card:hover { + border-color: rgba(78, 205, 196, 0.35); + box-shadow: + 0 0 40px rgba(78, 205, 196, 0.15), + 0 8px 32px rgba(0, 0, 0, 0.3); + transform: translateY(-2px); +} + .link-card:hover .link-icon-wrap { transform: scale(1.06) rotate(-2deg); } @@ -1048,6 +1168,29 @@ html { box-shadow: var(--shadow-card); } + [data-theme='dark'] .desktop-rail-item.active { + border: 1px solid rgba(78, 205, 196, 0.28); + box-shadow: 0 0 24px rgba(78, 205, 196, 0.12); + } + + [data-theme='dark'] .pc-section-label, + :root:not([data-theme='light']) .pc-section-label { + background: var(--hub-gradient-text); + -webkit-background-clip: text; + background-clip: text; + color: transparent; + background-size: 200% auto; + animation: nav-gradient-shift 4s ease-in-out infinite; + } + + [data-theme='light'] .pc-section-label { + background: none; + -webkit-background-clip: unset; + background-clip: unset; + color: var(--ink); + animation: none; + } + .desktop-rail-emoji { width: 1.2em; text-align: center; @@ -1076,8 +1219,8 @@ html { display: none; } - .brand-mark { - display: none; + .nav-portal-logo { + flex: 0 1 auto; } .pc-section-label { @@ -1106,21 +1249,11 @@ html { } .topbar { - padding: 14px 28px 14px 22px; + padding: 1rem 1.5rem; } - .brand-mark img, - .brand-logo { - width: 32px; - height: 32px; - } - - .brand-name { - font-size: 1.12rem; - } - - .brand-current { - font-size: 0.78rem; + .brand-row { + max-width: none; } .page { diff --git a/apps/nomadvip/app/api/pay/route.ts b/apps/nomadvip/app/api/pay/route.ts index 1c9dfd5..8992548 100644 --- a/apps/nomadvip/app/api/pay/route.ts +++ b/apps/nomadvip/app/api/pay/route.ts @@ -106,16 +106,35 @@ async function createPayOrder( signal: controller.signal, }).finally(() => clearTimeout(timeout)); const data = await res.json().catch(() => ({})); - const statusOk = data?.status === "ok" || data?.status === "success" || (res.ok && (data?.xorpay_params || data?.params)); - console.log("[pay] createPayOrder 响应 http=%s status=%s hasParams=%s", res.status, data?.status, !!(data?.xorpay_params || data?.params)); + const redirectUrl = data?.redirect_url || ""; + const statusOk = + data?.status === "ok" || + data?.status === "success" || + (res.ok && (data?.xorpay_params || data?.params || redirectUrl)); + console.log( + "[pay] createPayOrder 响应 http=%s status=%s hasParams=%s redirect=%s", + res.status, + data?.status, + !!(data?.xorpay_params || data?.params), + !!redirectUrl, + ); if (!res.ok || !statusOk) { const errMsg = data?.detail || data?.msg || data?.error || "支付创建失败"; console.error("[pay] createPayOrder 失败:", errMsg, "body=", JSON.stringify(data).slice(0, 300)); throw new Error(errMsg); } + // Overseas: redirect_url only + if (redirectUrl && (data.provider === "creem" || data.provider === "nowpayments")) { + return { + params: { order_id: String(data.order_id || "") }, + payUrl: redirectUrl, + redirectUrl, + provider: data.provider as string, + }; + } // xorpay: xorpay_params + xorpay_url | zpay: params + pay_url const params = (data.xorpay_params ?? data.params) || {}; - const payUrl = data.xorpay_url || data.pay_url || ""; + const payUrl = data.xorpay_url || data.pay_url || redirectUrl || ""; if (!params || typeof params !== "object" || Object.keys(params).length === 0) { console.error("[pay] createPayOrder 参数为空 data.keys=", Object.keys(data || {})); throw new Error("payjsapi 未返回支付参数"); @@ -123,6 +142,7 @@ async function createPayOrder( return { params: params as Record, payUrl, + redirectUrl: redirectUrl || undefined, provider: data.provider || "zpay", }; } @@ -162,9 +182,20 @@ export async function POST(request: NextRequest) { const device = String(body?.device || "pc"); const wechatNick = String(body?.wechat_nick || body?.nick || body?.user_name || "").trim(); const wechatAvatar = String(body?.wechat_avatar || body?.avatar || "").trim(); - // 渠道规则:pc/手机浏览器 -> zpay,仅微信内 -> xorpay + const requestedProvider = String(body?.provider || "").trim().toLowerCase(); + // 渠道:显式 provider 优先;否则 pc/H5→zpay,微信内→xorpay;海外 creem/nowpayments 由前端 resolvePayProvider 传入 const effectiveProvider = - device === "wechat" ? "xorpay" : "zpay"; + requestedProvider === "creem" || + requestedProvider === "nowpayments" || + requestedProvider === "zpay" || + requestedProvider === "xorpay" || + requestedProvider === "xpay" + ? requestedProvider === "xpay" + ? "xorpay" + : requestedProvider + : device === "wechat" + ? "xorpay" + : "zpay"; const accept = request.headers.get("accept") || ""; const wantHtml = String(body?.html) === "1" || accept.includes("text/html"); const preferJson = String(body?.prefer_json) === "1"; @@ -442,8 +473,8 @@ h2{color:#1e293b;margin:0 0 8px;font-size:1.5rem;} return NextResponse.json({ ok: false, error: errMsg }, { status: 500 }); } - // xorpay:调用 payh5 获取收银台参数 - const { params, payUrl, provider } = await createPayOrder( + // xorpay / creem / nowpayments:调用 payh5 获取收银台参数或跳转 URL + const { params, payUrl, provider, redirectUrl } = await createPayOrder( apiUrl, user_id, wechat_userid || undefined, @@ -455,6 +486,26 @@ h2{color:#1e293b;margin:0 0 8px;font-size:1.5rem;} effectiveProvider ); + if (redirectUrl && (provider === "creem" || provider === "nowpayments")) { + if (!wantHtml) { + const orderId = String(params?.order_id || "").trim(); + const res = NextResponse.json({ + ok: true, + redirect_url: redirectUrl, + provider, + order_id: orderId, + }); + if (orderId) setPayOrderCookie(res, orderId); + setAnonymousUserCookie(res, request, user_id); + return res; + } + const res = NextResponse.redirect(redirectUrl, 302); + const orderId = String(params?.order_id || "").trim(); + if (orderId) setPayOrderCookie(res, orderId); + setAnonymousUserCookie(res, request, user_id); + return res; + } + if (!params || Object.keys(params).length === 0) { if (wantHtml) { return new NextResponse(buildErrorHtml("支付参数为空"), { diff --git a/apps/nomadvip/app/components/content/EbookViewer.module.css b/apps/nomadvip/app/components/content/EbookViewer.module.css index b17562e..ded3e36 100644 --- a/apps/nomadvip/app/components/content/EbookViewer.module.css +++ b/apps/nomadvip/app/components/content/EbookViewer.module.css @@ -1,26 +1,31 @@ -/* 电子书阅读器 - 支持深色主题,可复用到 digital/nomadvip/nomadlms */ +/* VIP 电子书阅读器 — 深色纸面高对比,不被 github-markdown 白底浅字坑 */ + +.readerRoot { + min-height: 100vh; + background: #0a0e17; + color: #e8eef7; +} .readingProgress { position: fixed; top: 0; left: 0; - height: 4px; - background: linear-gradient(90deg, var(--accent) 0%, #00f2fe 100%); + height: 3px; + background: linear-gradient(90deg, #ff6b6b, #ffe66d, #4ecdc4); z-index: 201; transition: width 0.15s linear; - border-radius: 0 4px 4px 0; } .readingTime { font-size: 12px; font-weight: 400; - color: var(--muted-foreground); + color: #94a3b8; margin-left: 4px; } .headerSpacer { width: 100%; - height: 88px; + height: 56px; } .header { @@ -29,28 +34,31 @@ left: 0; right: 0; z-index: 100; - height: 88px; - background: var(--card); - backdrop-filter: blur(12px); - -webkit-backdrop-filter: blur(12px); - border-bottom: 1px solid var(--border); + height: 56px; + background: rgba(10, 14, 23, 0.92); + backdrop-filter: blur(16px); + -webkit-backdrop-filter: blur(16px); + border-bottom: 1px solid rgba(255, 255, 255, 0.1); display: flex; - flex-direction: row; align-items: center; justify-content: space-between; } .headerLeft { - width: 100px; + width: 48px; + height: 44px; + margin-left: 4px; display: flex; align-items: center; justify-content: center; - color: var(--foreground); + color: #f1f5f9; cursor: pointer; + border-radius: 10px; } .headerLeft:hover { - color: var(--accent); + color: #ffe66d; + background: rgba(255, 255, 255, 0.06); } .headerMiddle { @@ -58,52 +66,67 @@ display: flex; align-items: center; justify-content: center; - font-size: 16px; - font-weight: 600; - color: var(--foreground); - letter-spacing: 2px; + font-size: 15px; + font-weight: 700; + color: #f8fafc; + letter-spacing: 0.04em; } .headerRight { - width: 40px; - height: 40px; - padding: 0; - display: flex; + display: inline-flex; align-items: center; justify-content: center; - color: var(--accent); + gap: 6px; + min-height: 40px; + min-width: 40px; + padding: 0 12px; + margin-right: 10px; + color: #0a0e17; cursor: pointer; - margin-right: 8px; - background: var(--accent-muted, rgba(245, 158, 11, 0.15)); - border-radius: 50%; - transition: all 0.2s ease; + background: linear-gradient(135deg, #ffe66d, #ff6b6b); + border: none; + border-radius: 999px; + font-weight: 700; + font-size: 13px; + transition: transform 0.15s ease, opacity 0.15s ease; } .headerRight:hover { - background: var(--accent-muted, rgba(245, 158, 11, 0.25)); + opacity: 0.92; + transform: translateY(-1px); } .headerRightActive { - background: var(--accent) !important; - color: var(--accent-foreground) !important; + background: #4ecdc4 !important; + color: #0a0e17 !important; } .headerRightText { - display: none; - margin-left: 4px; + display: inline; } .chunkEnter { - animation: chunkAppear 0.5s ease-out both; + animation: chunkAppear 0.45s ease-out both; } @keyframes chunkAppear { - from { opacity: 0; transform: translateY(20px); } - to { opacity: 1; transform: translateY(0); } + from { + opacity: 0; + transform: translateY(12px); + } + to { + opacity: 1; + transform: translateY(0); + } } .chunkPlaceholder { - background: var(--muted); + background: linear-gradient( + 90deg, + rgba(255, 255, 255, 0.04), + rgba(255, 255, 255, 0.1), + rgba(255, 255, 255, 0.04) + ); background-size: 200% 100%; animation: shimmer 1.8s ease infinite; border-radius: 12px; @@ -111,52 +134,72 @@ } @keyframes shimmer { - 0% { background-position: 200% 0; } - 100% { background-position: -200% 0; } + 0% { + background-position: 200% 0; + } + 100% { + background-position: -200% 0; + } } .backToTop { position: fixed; - bottom: 120px; - right: 30px; - width: 56px; - height: 56px; - background: var(--card); - backdrop-filter: blur(10px); - border: 1px solid var(--border); + bottom: calc(24px + env(safe-area-inset-bottom)); + right: 16px; + width: 48px; + height: 48px; + background: rgba(17, 24, 39, 0.95); + border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 50%; display: flex; align-items: center; justify-content: center; - box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1); + box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35); cursor: pointer; z-index: 50; - color: var(--accent); - transition: transform 0.2s, box-shadow 0.2s; -} - -.backToTop:hover { - transform: translateY(-2px); - box-shadow: 0 6px 24px rgba(0, 0, 0, 0.15); + color: #ffe66d; } .book { - padding: 30px; - max-width: 100%; + padding: 20px 16px 96px; + max-width: 820px; + margin: 0 auto; + min-height: calc(100vh - 56px); + background: transparent; } -.markdownBody { +/* 强制可读:深色底 + 浅色字,覆盖 github-markdown 白底 */ +.markdownBody, +.markdownBody.markdown-body { font-size: 16px !important; line-height: 1.85 !important; - color: var(--foreground) !important; + color: #e8eef7 !important; + background-color: transparent !important; word-wrap: break-word; + box-sizing: border-box; +} + +.markdownBody h1, +.markdownBody h2, +.markdownBody h3, +.markdownBody h4, +.markdownBody h5, +.markdownBody h6, +.markdownBody p, +.markdownBody li, +.markdownBody td, +.markdownBody th, +.markdownBody strong, +.markdownBody em, +.markdownBody span { + color: #e8eef7 !important; } .markdownBody h1 { - font-size: 24px !important; + font-size: 1.65rem !important; font-weight: 800; - color: var(--foreground); - margin: 28px 0 10px; + margin: 1.75rem 0 0.75rem; + letter-spacing: 0.02em; } .markdownBody h1::after { @@ -164,65 +207,116 @@ display: block; width: 40px; height: 3px; - background: linear-gradient(90deg, var(--accent), #00f2fe); + background: linear-gradient(90deg, #ff6b6b, #ffe66d, #4ecdc4); border-radius: 3px; - margin-top: 8px; + margin-top: 10px; } .markdownBody h2 { - font-size: 21px !important; + font-size: 1.3rem !important; font-weight: 700; - color: var(--foreground); - margin: 22px 0 9px; - padding-bottom: 12px; - border-bottom: 1px solid var(--border); + margin: 1.5rem 0 0.65rem; + padding-bottom: 10px; + border-bottom: 1px solid rgba(255, 255, 255, 0.12); } -.markdownBody h3 { font-size: 18px !important; font-weight: 600; margin: 18px 0 7px; } -.markdownBody h4, .markdownBody h5, .markdownBody h6 { font-size: 16px !important; margin: 14px 0 6px; } -.markdownBody p { font-size: 16px !important; margin-bottom: 10px; line-height: 1.9; } +.markdownBody h3 { + font-size: 1.1rem !important; + font-weight: 600; + margin: 1.25rem 0 0.5rem; +} + +.markdownBody p { + margin-bottom: 0.85rem; + line-height: 1.9; +} .markdownBody blockquote { - margin: 28px 0; - padding: 20px 24px 20px 30px; - background: var(--muted); + margin: 1.25rem 0; + padding: 14px 16px 14px 18px; + background: rgba(255, 230, 109, 0.08); border-radius: 0 12px 12px 0; - color: var(--muted-foreground); - border-left: 4px solid var(--accent); + color: #cbd5e1 !important; + border-left: 4px solid #ffe66d; +} + +.markdownBody blockquote p { + color: #cbd5e1 !important; + margin-bottom: 0.35rem; } .markdownBody pre { - margin: 28px 0; - padding: 28px 24px; - background: var(--background); - border: 1px solid var(--border); + margin: 1.25rem 0; + padding: 16px; + background: #0c1220 !important; + border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 12px; overflow-x: auto; } .markdownBody pre code { - font-family: var(--font-geist-mono), monospace; + font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px !important; - color: var(--foreground); + color: #e2e8f0 !important; background: none !important; } .markdownBody code { - font-family: var(--font-geist-mono), monospace; - font-size: 14px !important; + font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; + font-size: 0.9em !important; padding: 2px 6px; - background: var(--muted); - color: var(--accent); + background: rgba(255, 230, 109, 0.12) !important; + color: #ffe66d !important; border-radius: 6px; } -.markdownBody a { color: var(--accent); } -.markdownBody a:hover { text-decoration: underline; } -.markdownBody img { display: block; margin: 28px auto; max-width: 100%; border-radius: 8px; } -.markdownBody ul, .markdownBody ol { margin: 16px 0; padding-left: 40px; } -.markdownBody table { width: 100%; margin: 28px 0; border-collapse: collapse; border-radius: 8px; } -.markdownBody th { background: var(--muted); font-weight: 600; padding: 16px 20px; border: 1px solid var(--border); } -.markdownBody td { padding: 14px 20px; border: 1px solid var(--border); } +.markdownBody a { + color: #4ecdc4 !important; +} + +.markdownBody a:hover { + text-decoration: underline; +} + +.markdownBody img { + display: block; + margin: 1.25rem auto; + max-width: 100%; + border-radius: 10px; +} + +.markdownBody ul, +.markdownBody ol { + margin: 0.85rem 0; + padding-left: 1.5rem; + color: #e8eef7 !important; +} + +.markdownBody table { + width: 100%; + margin: 1.25rem 0; + border-collapse: collapse; +} + +.markdownBody th { + background: rgba(255, 255, 255, 0.06); + font-weight: 600; + padding: 12px 14px; + border: 1px solid rgba(255, 255, 255, 0.1); + color: #f8fafc !important; +} + +.markdownBody td { + padding: 10px 14px; + border: 1px solid rgba(255, 255, 255, 0.1); + color: #e2e8f0 !important; +} + +.markdownBody hr { + border: none; + border-top: 1px solid rgba(255, 255, 255, 0.12); + margin: 1.5rem 0; +} .drawer { position: fixed; @@ -231,22 +325,24 @@ bottom: 0; width: 280px; max-width: 85vw; - background: var(--card); - border-left: 1px solid var(--border); - box-shadow: -4px 0 24px rgba(0, 0, 0, 0.15); + background: #111827; + border-left: 1px solid rgba(255, 255, 255, 0.1); + box-shadow: -8px 0 32px rgba(0, 0, 0, 0.45); z-index: 150; - padding-top: 88px; + padding-top: 56px; overflow-y: auto; transform: translateX(100%); transition: transform 0.3s ease; } -.drawerOpen { transform: translateX(0); } +.drawerOpen { + transform: translateX(0); +} .drawerMask { position: fixed; inset: 0; - background: rgba(0, 0, 0, 0.4); + background: rgba(0, 0, 0, 0.55); z-index: 140; opacity: 0; pointer-events: none; @@ -259,36 +355,39 @@ } .drawerItem { - padding: 16px 20px; - border-bottom: 1px solid var(--border); - color: var(--foreground); + padding: 14px 18px; + border-bottom: 1px solid rgba(255, 255, 255, 0.08); + color: #e2e8f0; cursor: pointer; - font-size: 15px; - transition: background 0.15s; + font-size: 14px; + line-height: 1.4; + min-height: 44px; } .drawerItem:hover { - background: var(--muted); + background: rgba(255, 255, 255, 0.06); + color: #ffe66d; } @media (min-width: 768px) { - .headerSpacer { height: 56px; } - .header { height: 56px; } - .progressBar { top: 56px; } - .headerMiddle { font-size: 18px; } - .headerRight { - width: auto; - height: 34px; - padding: 0 14px; - margin-right: 16px; - border-radius: 17px; - font-size: 13px; + .book { + padding: 28px 32px 96px; + } + .markdownBody { + max-width: 720px; + margin: 0 auto; + } + .markdownBody h1 { + font-size: 1.9rem !important; + } + .markdownBody h2 { + font-size: 1.4rem !important; + } + .drawer { + width: 320px; + } + .backToTop { + right: 28px; + bottom: 36px; } - .headerRightText { display: inline; } - .book { padding: 30px 60px; } - .markdownBody { max-width: 800px; margin: 0 auto; } - .markdownBody h1 { font-size: 28px !important; } - .markdownBody h2 { font-size: 23px !important; } - .drawer { padding-top: 56px; width: 300px; } - .backToTop { width: 44px; height: 44px; bottom: 40px; right: 40px; } } diff --git a/apps/nomadvip/app/components/content/EbookViewer.tsx b/apps/nomadvip/app/components/content/EbookViewer.tsx index e812926..0c22843 100644 --- a/apps/nomadvip/app/components/content/EbookViewer.tsx +++ b/apps/nomadvip/app/components/content/EbookViewer.tsx @@ -88,6 +88,27 @@ export function EbookViewer({ data, config }: EbookViewerProps) { return () => window.removeEventListener("scroll", onScroll); }, [estimatedMin]); + // 深链:/vip/ebook/read#章节id + useEffect(() => { + const hash = decodeURIComponent(window.location.hash.slice(1)); + if (!hash) return; + setForceShowAll(true); + const tryScroll = () => { + const el = document.getElementById(hash); + if (!el) return false; + el.scrollIntoView({ behavior: "auto", block: "start" }); + return true; + }; + if (!tryScroll()) { + const timers = [80, 200, 450, 900, 1600].map((ms) => + window.setTimeout(() => { + tryScroll(); + }, ms), + ); + return () => timers.forEach(clearTimeout); + } + }, []); + const handleJump = useCallback((index: number) => { setForceShowAll(true); setShowDrawer(false); @@ -99,6 +120,10 @@ export function EbookViewer({ data, config }: EbookViewerProps) { const targets = h1s.length > 0 ? h1s : h2s; const el = targets[index] as HTMLElement; if (el) { + const id = el.id; + if (id) { + history.replaceState(null, "", `#${id}`); + } try { el.scrollIntoView({ behavior: "smooth", block: "start" }); } catch { @@ -117,13 +142,13 @@ export function EbookViewer({ data, config }: EbookViewerProps) { }, []); return ( - <> +
-
- - +
+ + @@ -139,7 +164,7 @@ export function EbookViewer({ data, config }: EbookViewerProps) { onClick={() => setShowDrawer(!showDrawer)} aria-label="目录" > - + @@ -195,6 +220,6 @@ export function EbookViewer({ data, config }: EbookViewerProps) { )} - +
); } diff --git a/apps/nomadvip/app/data/vip.mock.ts b/apps/nomadvip/app/data/vip.mock.ts index 88b6df3..3e288bc 100644 --- a/apps/nomadvip/app/data/vip.mock.ts +++ b/apps/nomadvip/app/data/vip.mock.ts @@ -56,7 +56,7 @@ export const TOPICS_DISPLAY = [ { id: "tools", icon: "🛒", title: "设备自助下单", desc: "开箱即用", href: "https://store.hackrobot.cn/", locked: true }, ] as const; -/** 电子书展示 - 首页展示用(门户挂载在 /vip/ebook,勿链到门户 /book) */ +/** 电子书展示 — VIP 内路径(门户挂载后为 /vip/ebook,同 /book UI) */ export const EBOOKS_DISPLAY = [ { id: "1", title: "数字游民", desc: "地理套利与自动化杠杆", href: vipPath("/ebook"), free: true }, { id: "2", title: "云手机", desc: "低成本工作室搭建指南", href: vipPath("/ebook/cloudphone"), locked: true }, diff --git a/apps/nomadvip/app/globals.css b/apps/nomadvip/app/globals.css index 08fbe70..a8e8188 100644 --- a/apps/nomadvip/app/globals.css +++ b/apps/nomadvip/app/globals.css @@ -2,38 +2,53 @@ @import "github-markdown-css/github-markdown.css"; @import "animate.css"; +/* + * VIP 视觉对齐门户 hub:深色科技底 + 珊瑚/琥珀/青绿渐变; + * 琥珀 #f59e0b 保留为会员强调色。默认即夜间。 + */ :root, -.light { - --font-geist-sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, - "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif, - "Apple Color Emoji", "Segoe UI Emoji"; +.dark { + --font-geist-sans: var(--font-outfit), var(--font-noto-sc), ui-sans-serif, + system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, + "Noto Sans", "Liberation Sans", sans-serif, "Apple Color Emoji", + "Segoe UI Emoji"; --font-geist-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; - --background: #fafafa; - --foreground: #171717; - --card: #ffffff; - --card-foreground: #171717; - --muted: #f4f4f5; - --muted-foreground: #71717a; - --border: #e4e4e7; - --accent: #f59e0b; - --accent-foreground: #1c1917; - --accent-muted: rgba(245, 158, 11, 0.2); - --gradient-accent: rgba(251, 191, 36, 0.15); -} - -.dark { - --background: #0c0c0f; - --foreground: #fafafa; - --card: rgba(255, 255, 255, 0.05); - --card-foreground: #fafafa; + --background: #0a0e17; + --foreground: #f1f5f9; + --card: rgba(17, 24, 39, 0.7); + --card-foreground: #f1f5f9; --muted: rgba(255, 255, 255, 0.05); - --muted-foreground: #a1a1aa; + --muted-foreground: #94a3b8; --border: rgba(255, 255, 255, 0.08); --accent: #f59e0b; --accent-foreground: #1c1917; --accent-muted: rgba(245, 158, 11, 0.2); --gradient-accent: rgba(251, 191, 36, 0.15); + --hub-accent-1: #ff6b6b; + --hub-accent-2: #ffe66d; + --hub-accent-3: #4ecdc4; + --hub-gradient-text: linear-gradient(135deg, #ff6b6b 0%, #ffe66d 50%, #4ecdc4 100%); + --hub-glow: 0 0 40px rgba(78, 205, 196, 0.15); +} + +.light { + --background: #f8fafc; + --foreground: #0f172a; + --card: rgba(255, 255, 255, 0.85); + --card-foreground: #0f172a; + --muted: #f1f5f9; + --muted-foreground: #64748b; + --border: rgba(15, 23, 42, 0.08); + --accent: #d97706; + --accent-foreground: #fffbeb; + --accent-muted: rgba(217, 119, 6, 0.15); + --gradient-accent: rgba(245, 158, 11, 0.12); + --hub-accent-1: #ff6b6b; + --hub-accent-2: #d97706; + --hub-accent-3: #0d9488; + --hub-gradient-text: linear-gradient(135deg, #ff6b6b 0%, #d97706 50%, #0d9488 100%); + --hub-glow: 0 0 40px rgba(13, 148, 136, 0.12); } @keyframes gradient-shift { @@ -84,3 +99,9 @@ body { font-family: var(--font-geist-sans), system-ui, sans-serif; transition: background-color 0.2s ease, color 0.2s ease; } + +.vip-root { + font-family: var(--font-geist-sans), system-ui, sans-serif; + background: var(--background); + color: var(--foreground); +} diff --git a/apps/nomadvip/app/layout.tsx b/apps/nomadvip/app/layout.tsx index b5b9ee4..07acecd 100644 --- a/apps/nomadvip/app/layout.tsx +++ b/apps/nomadvip/app/layout.tsx @@ -5,8 +5,8 @@ import { httpsUpgradeScript } from "./https-upgrade"; import { themeInitScript } from "./theme-init"; export const metadata: Metadata = { - title: "异度星球", - description: "数字游民社群", + title: "nomadro VIP", + description: "私域会员 · 全模块解锁 · 抱团出海", }; export default function RootLayout({ diff --git a/apps/nomadvip/app/lib/ebook.ts b/apps/nomadvip/app/lib/ebook.ts index 8a89d96..ad03846 100644 --- a/apps/nomadvip/app/lib/ebook.ts +++ b/apps/nomadvip/app/lib/ebook.ts @@ -1,3 +1,6 @@ +/** + * 电子书 Markdown 解析 - 共享模块 + */ import { marked } from "marked"; export interface EbookChunk { @@ -12,7 +15,33 @@ export interface EbookData { export function parseEbookMarkdown(source: string): EbookData { const html = marked.parse(source, { breaks: true, gfm: true }) as string; - const lazyHtml = html.replace(/(); + lazyHtml = lazyHtml.replace( + /<(h[12])(\s[^>]*)?>([\s\S]*?)<\/\1>/gi, + (_m, tag: string, attrs = "", inner: string) => { + if (/\sid\s*=/i.test(attrs || "")) { + return `<${tag}${attrs || ""}>${inner}`; + } + const plain = inner.replace(/<[^>]+>/g, "").trim(); + let base = + plain + .toLowerCase() + .replace(/\s+/g, "-") + .replace(/[^\w\u4e00-\u9fff-]+/g, "") + .replace(/-+/g, "-") + .replace(/^-|-$/g, "") + .slice(0, 80) || "section"; + let id = base; + let n = 2; + while (used.has(id)) { + id = `${base}-${n++}`; + } + used.add(id); + return `<${tag}${attrs || ""} id="${id}">${inner}`; + }, + ); let rawChunks = lazyHtml.split(/(?=])/i).filter((c) => c.trim()); if (rawChunks.length <= 1) { @@ -41,3 +70,8 @@ export function parseEbookMarkdown(source: string): EbookData { return { chunks, headers }; } + +/** 估算阅读时间(字/分钟,中文约 300-500) */ +export function estimateReadingMinutes(textLength: number, wpm = 400): number { + return Math.max(1, Math.ceil(textLength / wpm)); +} diff --git a/apps/nomadvip/app/lib/remoteConfigBridge.ts b/apps/nomadvip/app/lib/remoteConfigBridge.ts new file mode 100644 index 0000000..5e49afc --- /dev/null +++ b/apps/nomadvip/app/lib/remoteConfigBridge.ts @@ -0,0 +1,40 @@ +/** + * 读取门户写入的远程配置缓存(与 ~/lib/use-remote-config CACHE_KEY 对齐) + * VIP 垂直仓不直接依赖门户路径,只读 localStorage。 + */ +const WEB_CACHE_KEY = "nomadro_web_remote_config_v1"; + +export type VipRemoteCopy = { + vipPriceFen?: number; + vipProductId?: string; + vipCta?: string; + payEnabled?: boolean; +}; + +export function readPortalRemoteCopy(): VipRemoteCopy { + if (typeof window === "undefined") return {}; + try { + const raw = localStorage.getItem(WEB_CACHE_KEY); + if (!raw) return {}; + const parsed = JSON.parse(raw) as { + config?: { + copy?: { + vipPriceFen?: number; + vipProductId?: string; + vipCta?: string; + }; + flags?: { payEnabled?: boolean }; + }; + }; + const copy = parsed?.config?.copy || {}; + const flags = parsed?.config?.flags || {}; + return { + vipPriceFen: Number(copy.vipPriceFen) || undefined, + vipProductId: copy.vipProductId, + vipCta: copy.vipCta, + payEnabled: flags.payEnabled, + }; + } catch { + return {}; + } +} diff --git a/apps/nomadvip/app/lib/triggerPay.ts b/apps/nomadvip/app/lib/triggerPay.ts index a7d89b8..92ff42b 100644 --- a/apps/nomadvip/app/lib/triggerPay.ts +++ b/apps/nomadvip/app/lib/triggerPay.ts @@ -8,6 +8,9 @@ */ import { getPayEnv, getDeviceFromEnv } from "@vip/app/lib/payEnv"; import { getPaymentConfig } from "@vip/config/services.config"; +import { resolvePayProvider } from "@nomadro/pay"; +import { isChinaUser } from "is-china-user"; +import { readPortalRemoteCopy } from "@vip/app/lib/remoteConfigBridge"; const ANONYMOUS_USER_COOKIE = "nomadvip_anon_uid"; const ANONYMOUS_USER_COOKIE_MAX_AGE = 60 * 60 * 24 * 30; @@ -161,6 +164,7 @@ function redirectToPayZpay(params: { type: string; channel: "alipay" | "wxpay"; device: "pc" | "h5" | "wechat"; + provider: string; }) { const form = document.createElement("form"); form.method = "POST"; @@ -177,7 +181,7 @@ function redirectToPayZpay(params: { ["type", params.type], ["channel", params.channel], ["device", params.device], - ["provider", "zpay"], + ["provider", params.provider], ["html", "1"], ]; fields.forEach(([k, v]) => { @@ -191,7 +195,7 @@ function redirectToPayZpay(params: { form.submit(); } -async function redirectToPayZpayH5( +async function redirectToPayH5( params: { user_id: string; wechat_userid?: string; @@ -201,6 +205,7 @@ async function redirectToPayZpayH5( total_fee: number; type: string; channel: "alipay" | "wxpay"; + provider: string; }, onPendingOrder?: (orderId: string) => void ): Promise { @@ -210,7 +215,6 @@ async function redirectToPayZpayH5( body: JSON.stringify({ ...params, device: "h5", - provider: "zpay", html: "0", }), }); @@ -263,6 +267,7 @@ function payWechatXorpaySync(params: { total_fee: number; type: string; channel: "alipay" | "wxpay"; + provider?: string; }) { const form = document.createElement("form"); form.method = "POST"; @@ -279,7 +284,7 @@ function payWechatXorpaySync(params: { ["type", params.type], ["channel", params.channel], ["device", "wechat"], - ["provider", "xorpay"], + ["provider", params.provider || "xorpay"], ["html", "1"], ]; fields.forEach(([k, v]) => { @@ -316,13 +321,35 @@ export async function triggerPay( (getStorage("wechatUserId") || "").trim() || (getStorage("userid") || "").trim(); const isPayTestMode = getStorage(VIP_PAY_TEST_MODE_KEY) === "1"; - const totalFee = isPayTestMode ? 100 : getPaymentConfig().defaultAmount ?? 8800; + const remote = readPortalRemoteCopy(); + if (remote.payEnabled === false) { + if (typeof window !== "undefined") { + window.alert("支付通道已在管理后台关闭"); + } + return; + } + const totalFee = isPayTestMode + ? 100 + : remote.vipPriceFen && remote.vipPriceFen > 0 + ? remote.vipPriceFen + : getPaymentConfig().defaultAmount ?? 8800; const profile = getDisplayProfile(); const shouldShowLaunchOverlay = device !== "wechat" && !!(profile.avatar || "").trim(); if (shouldShowLaunchOverlay) { showPayLaunchOverlay(profile.displayName, profile.avatar); } + + const china = + typeof window !== "undefined" ? Boolean(isChinaUser()) : true; + const resolved = resolvePayProvider({ + isChinaUser: china, + userAgent: typeof navigator !== "undefined" ? navigator.userAgent : undefined, + }); + // Backend aliases: xpay → xorpay + const apiProvider = + resolved.provider === "xpay" ? "xorpay" : resolved.provider; + const base = { user_id: userId, wechat_userid: wechatUserId || undefined, @@ -331,13 +358,22 @@ export async function triggerPay( return_url: returnUrl, total_fee: totalFee, type: "vip", - channel: "wxpay" as const, + channel: resolved.channel, + provider: apiProvider, }; + + // Overseas: always redirect via JSON so Creem/NOWPayments can return checkout URL + if (apiProvider === "creem" || apiProvider === "nowpayments") { + await redirectToPayH5({ ...base, channel: "wxpay" }, onPendingOrder); + return; + } + if (device === "wechat") { payWechatXorpaySync(base); } else if (device === "h5") { - await redirectToPayZpayH5(base, onPendingOrder); + await redirectToPayH5(base, onPendingOrder); } else { redirectToPayZpay({ ...base, device }); } } + diff --git a/apps/nomadvip/app/providers/ThemeProvider.tsx b/apps/nomadvip/app/providers/ThemeProvider.tsx index b9fd397..8ad01e9 100644 --- a/apps/nomadvip/app/providers/ThemeProvider.tsx +++ b/apps/nomadvip/app/providers/ThemeProvider.tsx @@ -19,27 +19,39 @@ type ThemeContextValue = { const ThemeContext = createContext(null); const STORAGE_KEY = "nomadvip-theme"; +const SHARED_KEY = "nomadro-theme"; +const DEFAULT_THEME: ThemeMode = "dark"; function getSystemTheme(): "light" | "dark" { - if (typeof window === "undefined") return "light"; + if (typeof window === "undefined") return "dark"; return window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light"; } +function resolveMode(mode: ThemeMode): "light" | "dark" { + if (mode === "system") return getSystemTheme(); + return mode; +} + function getStoredTheme(): ThemeMode { - if (typeof window === "undefined") return "system"; - return (localStorage.getItem(STORAGE_KEY) as ThemeMode) || "system"; + if (typeof window === "undefined") return DEFAULT_THEME; + const raw = + (localStorage.getItem(SHARED_KEY) as ThemeMode | null) || + (localStorage.getItem(STORAGE_KEY) as ThemeMode | null); + if (raw === "light" || raw === "dark" || raw === "system") return raw; + return DEFAULT_THEME; } export function ThemeProvider({ children }: { children: React.ReactNode }) { - const [theme, setThemeState] = useState("system"); - const [resolvedTheme, setResolvedTheme] = useState<"light" | "dark">("light"); + const [theme, setThemeState] = useState(DEFAULT_THEME); + const [resolvedTheme, setResolvedTheme] = useState<"light" | "dark">("dark"); const applyTheme = useCallback((mode: "light" | "dark") => { const root = document.documentElement; root.classList.remove("light", "dark"); root.classList.add(mode); + root.dataset.theme = mode; setResolvedTheme(mode); }, []); @@ -47,9 +59,8 @@ export function ThemeProvider({ children }: { children: React.ReactNode }) { (newTheme: ThemeMode) => { setThemeState(newTheme); localStorage.setItem(STORAGE_KEY, newTheme); - const resolved = - newTheme === "system" ? getSystemTheme() : newTheme; - applyTheme(resolved); + localStorage.setItem(SHARED_KEY, newTheme); + applyTheme(resolveMode(newTheme)); }, [applyTheme] ); @@ -57,8 +68,7 @@ export function ThemeProvider({ children }: { children: React.ReactNode }) { useEffect(() => { const stored = getStoredTheme(); setThemeState(stored); - const resolved = stored === "system" ? getSystemTheme() : stored; - applyTheme(resolved); + applyTheme(resolveMode(stored)); const media = window.matchMedia("(prefers-color-scheme: dark)"); const handler = () => { diff --git a/apps/nomadvip/app/theme-init.ts b/apps/nomadvip/app/theme-init.ts index a48b58b..240bc1c 100644 --- a/apps/nomadvip/app/theme-init.ts +++ b/apps/nomadvip/app/theme-init.ts @@ -1,10 +1,25 @@ /** * 主题初始化 - 在 React 水合前执行,避免主题闪烁 + * 优先读全局 nomadro-theme,回退 nomadvip-theme;默认夜间 */ export const themeInitScript = ` (function() { - var theme = localStorage.getItem('nomadvip-theme'); - var resolved = theme === 'light' ? 'light' : (theme === 'dark' ? 'dark' : (window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light')); - document.documentElement.classList.add(resolved); + try { + var theme = localStorage.getItem('nomadro-theme') || localStorage.getItem('nomadvip-theme'); + var resolved = theme === 'light' + ? 'light' + : (theme === 'dark' + ? 'dark' + : (theme === 'system' + ? (window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light') + : 'dark')); + var root = document.documentElement; + root.classList.remove('light', 'dark'); + root.classList.add(resolved); + root.dataset.theme = resolved; + } catch (e) { + document.documentElement.classList.add('dark'); + document.documentElement.dataset.theme = 'dark'; + } })(); `; diff --git a/apps/nomadvip/app/vip/components/VipHeader.tsx b/apps/nomadvip/app/vip/components/VipHeader.tsx index e9dec2d..d1416fd 100644 --- a/apps/nomadvip/app/vip/components/VipHeader.tsx +++ b/apps/nomadvip/app/vip/components/VipHeader.tsx @@ -13,6 +13,28 @@ function getAvatarLetter(email: string): string { return local.slice(0, 1).toUpperCase(); } +function LogoIcon() { + return ( + + + + + + + + + + + + + ); +} + type VipHeaderProps = { isLoggedIn: boolean; userName?: string | null; @@ -53,8 +75,9 @@ export function VipHeader({ return (
- - 🌍 异度星球 + + + nomadro