karin-plugin-kkk 2.35.0 → 2.36.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,12 +1,12 @@
1
1
  import { i as __toESM } from "./rolldown-runtime.js";
2
- import { $ as SiGooglephotos, $n as ArrowDownToLine, $t as RefreshCw, A as RiHashtag, An as Download, At as Users, B as RiThumbUpFill, Bn as CircleFadingArrowUp, Bt as Square, C as AiFillHeart, Cn as Gift, Ct as format, D as Markdown, Dn as Eye, Dt as X, E as AiOutlineVideoCamera, En as FilePlay, Et as Zap, F as RiMessage3Fill, Fn as Code, Ft as TriangleAlert, G as RiVideoLine, Gn as Check, Gt as Shield, H as RiTrophyFill, Hn as CircleCheck, Ht as Sparkles, I as RiPieChart2Fill, In as Clock, It as Trash2, J as SiSamsung, Jn as Calendar, Jt as Settings2, K as SiXiaomi, Kn as ChartColumn, Kt as ShieldCheck, L as RiShareForwardFill, Ln as Clock3, Lt as Terminal, M as RiHeart3Line, Mn as Cpu, Mt as UsersRound, N as RiHeartLine, Nn as CornerDownLeft, Nt as UserPlus, O as RiArrowRightFill, On as EyeOff, Ot as WandSparkles, P as RiLiveLine, Pn as Copy, Pt as Upload, Q as SiHonor, Qn as BellRing, Qt as RotateCcw, R as RiStarFill, Rn as Clapperboard, Rt as Sun, S as BiImage, Sn as GitBranch, St as formatDistanceToNow, T as AiFillStar, Tn as FileText, Tt as twMerge, U as RiUserFollowLine, Un as CircleCheckBig, Ut as Smartphone, V as RiTiktokFill, Vn as CircleEllipsis, Vt as SquarePen, W as RiVerifiedBadgeFill, Wn as CircleAlert, Wt as ShoppingBag, X as SiOneplus, Xn as Bot, Xt as ScanLine, Y as SiOppo, Yn as Box, Yt as Search, Z as SiHuawei, Zn as Bookmark, Zt as Save, _ as MdSchedule, _n as LayoutTemplate, _t as t, a as VictoryScatter, an as Play, ar as require_react, at as r$1, b as FaTiktok, bn as Heart, bt as parse, c as VictoryChart, cn as Music, cr as Xhshow, ct as e$1, d as VictoryTheme, dn as MessageCircle, dt as n, en as Radio, er as Chip, et as SiGithub, f as rehypeHighlight, fn as Menu, ft as e, g as MdLocationOn, gn as Link, gt as c, h as MdLightbulbOutline, hn as LoaderCircle, ht as o$3, i as require_heic_decode, in as Plus, ir as require_server_node, it as o$2, j as RiHeart3Fill, jn as Crown, jt as User, k as RiGroupLine, kn as ExternalLink, kt as Video, l as VictoryAxis, ln as Moon, lr as zod_default, lt as m, m as MdInfoOutline, mn as MapPin, mt as o$1, n as require_lib, nn as QrCode, nr as clsx, nt as SiApple, o as VictoryPie, on as Pencil, or as require_protobufjs, ot as o, p as MdFitScreen, pn as Maximize, pt as a$1, q as SiVivo, qn as Camera, qt as Share2, r as require_jpeg_js, rn as Puzzle, rr as require_jsx_runtime, rt as SiAnthropic, s as VictoryLine, sn as Palette, sr as Chalk, st as o$4, t as createProxyMiddleware, tn as Quote, tr as Button, tt as SiBilibili, u as VictoryLabel, un as Monitor, ut as a, v as FaCommentDots, vn as Info, vt as r, w as AiFillPushpin, wn as Gamepad2, wt as differenceInSeconds, x as FaUserGroup, xn as Hash, xt as fromUnixTime, y as FaMusic, yn as Image$1, yt as zhCN, z as RiStarLine, zn as CircleQuestionMark, zt as Star } from "./vendor.js";
2
+ import { $ as SiGooglephotos, $n as require_jsx_runtime, $t as Puzzle, A as RiHashtag, An as Copy, At as Upload, B as RiThumbUpFill, Bn as CircleAlert, Bt as ShoppingBag, C as AiFillHeart, Cn as Eye, Ct as X, D as Markdown, Dn as Crown, Dt as UsersRound, E as AiOutlineVideoCamera, En as Download, Et as Users, F as RiMessage3Fill, Fn as CircleQuestionMark, Ft as Star, G as RiVideoLine, Gn as Box, Gt as Search, H as RiTrophyFill, Hn as ChartColumn, Ht as ShieldCheck, I as RiPieChart2Fill, In as CircleFadingArrowUp, It as Square, J as SiSamsung, Jn as BellRing, Jt as RotateCcw, K as SiXiaomi, Kn as Bot, Kt as ScanLine, L as RiShareForwardFill, Ln as CircleEllipsis, Lt as SquarePen, M as RiHeart3Line, Mn as Clock, Mt as Trash2, N as RiHeartLine, Nn as Clock3, Nt as Terminal, O as RiArrowRightFill, On as Cpu, Ot as User, P as RiLiveLine, Pn as Clapperboard, Pt as Sun, Q as SiHonor, Qn as clsx, Qt as QrCode, R as RiStarFill, Rn as CircleCheck, Rt as Sparkles, S as BiImage, Sn as FilePlay, St as Zap, T as AiFillStar, Tn as ExternalLink, Tt as Video, U as RiUserFollowLine, Un as Camera, Ut as Share2, V as RiTiktokFill, Vn as Check, Vt as Shield, W as RiVerifiedBadgeFill, Wn as Calendar, Wt as Settings2, X as SiOneplus, Xn as Chip, Xt as Radio, Y as SiOppo, Yn as ArrowDownToLine, Yt as RefreshCw, Z as SiHuawei, Zn as Button, Zt as Quote, _ as MdSchedule, _n as Hash, _t as fromUnixTime, a as VictoryScatter, an as Moon, ar as FingerprintGenerator, at as r, b as FaTiktok, bn as Gamepad2, bt as differenceInSeconds, c as VictoryChart, cn as Menu, ct as m, d as VictoryTheme, dn as LoaderCircle, dt as e, en as Plus, er as require_server_node, et as SiGithub, f as rehypeHighlight, fn as Link, ft as a$1, g as MdLocationOn, gn as Heart, gt as parse, h as MdLightbulbOutline, hn as Image$1, ht as zhCN, i as require_heic_decode, in as Music, ir as CryptoConfig, it as o$2, j as RiHeart3Fill, jn as Code, jt as TriangleAlert, k as RiGroupLine, kn as CornerDownLeft, kt as UserPlus, l as VictoryAxis, ln as Maximize, lt as a, m as MdInfoOutline, mn as Info, mt as c, n as require_lib, nn as Pencil, nr as require_protobufjs, nt as SiApple, o as VictoryPie, on as Monitor, or as Xhshow, ot as o, p as MdFitScreen, pn as LayoutTemplate, pt as o$1, q as SiVivo, qn as Bookmark, qt as Save, r as require_jpeg_js, rn as Palette, rr as Chalk, rt as SiAnthropic, s as VictoryLine, sn as MessageCircle, sr as zod_default, st as o$3, t as createProxyMiddleware, tn as Play, tr as require_react, tt as SiBilibili, u as VictoryLabel, un as MapPin, ut as n, v as FaCommentDots, vn as GitBranch, vt as formatDistanceToNow, w as AiFillPushpin, wn as EyeOff, wt as WandSparkles, x as FaUserGroup, xn as FileText, xt as twMerge, y as FaMusic, yn as Gift, yt as format, z as RiStarLine, zn as CircleCheckBig, zt as Smartphone } from "./vendor.js";
3
3
  import "node:module";
4
4
  import fs from "node:fs";
5
5
  import path, { resolve } from "node:path";
6
- import URL$2, { fileURLToPath } from "node:url";
6
+ import URL$1, { fileURLToPath } from "node:url";
7
7
  import karin$1, { BOT_CONNECT, app, authMiddleware, checkPkgUpdate, checkPort, common, config, createBadRequestResponse, createNotFoundResponse, createServerErrorResponse, createSuccessResponse, db, defineConfig, ffmpeg, ffprobe, hooks, karin, karinPathHtml, karinPathTemp, logger, logger as logger$1, logs, mkdirSync, parseChangelog, range, render, restart, segment, updatePkg, watch } from "node-karin";
8
8
  import { EventEmitter } from "node:events";
9
- import crypto from "node:crypto";
9
+ import crypto, { createCipheriv, createHash, randomBytes, randomUUID } from "node:crypto";
10
10
  import axios, { AxiosError } from "node-karin/axios";
11
11
  import os, { platform } from "node:os";
12
12
  import express from "node-karin/express";
@@ -1379,12 +1379,194 @@ var KuaishouMethodRoutes = {
1379
1379
  emojiList: "/fetch_emoji_list"
1380
1380
  };
1381
1381
  //#endregion
1382
+ //#region ../amagi/packages/core/src/platform/xiaohongshu/sign/config.ts
1383
+ /** 初始化签名配置。 */
1384
+ var createXiaohongshuCryptoConfig = () => new CryptoConfig().withOverrides({
1385
+ DATA_WEB_BUILD: "6.12.3",
1386
+ SIGNATURE_DATA_TEMPLATE: {
1387
+ x0: "4.3.5",
1388
+ x1: "xhs-pc-web",
1389
+ x2: "Windows",
1390
+ x3: "",
1391
+ x4: ""
1392
+ },
1393
+ SIGNATURE_XSCOMMON_TEMPLATE: {
1394
+ s0: 5,
1395
+ s1: "",
1396
+ x0: "1",
1397
+ x1: "4.3.5",
1398
+ x2: "Windows",
1399
+ x3: "xhs-pc-web",
1400
+ x4: "6.12.3",
1401
+ x5: "",
1402
+ x6: "",
1403
+ x7: "",
1404
+ x8: "",
1405
+ x9: -596800761,
1406
+ x10: 0,
1407
+ x11: "normal"
1408
+ }
1409
+ });
1410
+ //#endregion
1411
+ //#region ../amagi/packages/core/src/platform/xiaohongshu/sign/guestCookie.ts
1412
+ /** @see https://github.com/Cialle/RedCrack */
1413
+ /** 小红书 Web 端游客会话初始化使用的浏览器请求头。 */
1414
+ var GUEST_HEADERS = {
1415
+ accept: "application/json, text/plain, */*",
1416
+ "accept-language": "zh-CN,zh;q=0.9,en;q=0.8,en-GB;q=0.7,en-US;q=0.6",
1417
+ "content-type": "application/json;charset=UTF-8",
1418
+ origin: "https://www.xiaohongshu.com",
1419
+ priority: "u=1, i",
1420
+ referer: "https://www.xiaohongshu.com/",
1421
+ "sec-ch-ua": "\"Microsoft Edge\";v=\"141\", \"Not?A_Brand\";v=\"8\", \"Chromium\";v=\"141\"",
1422
+ "sec-ch-ua-mobile": "?0",
1423
+ "sec-ch-ua-platform": "\"Windows\"",
1424
+ "sec-fetch-dest": "empty",
1425
+ "sec-fetch-mode": "cors",
1426
+ "sec-fetch-site": "same-site",
1427
+ "user-agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/141.0.0.0 Safari/537.36 Edg/141.0.0.0"
1428
+ };
1429
+ /** 生成 a1 随机段时使用的 Web 端字符集。 */
1430
+ var COOKIE_RANDOM_CHARS = "abcdefghijklmnopqrstuvwxyz1234567890";
1431
+ /** 将 Cookie Jar 序列化为可直接写入 HTTP Cookie 请求头的字符串。 */
1432
+ var toCookieString = (cookies) => Object.entries(cookies).map(([key, value]) => `${key}=${value}`).join("; ");
1433
+ /** 将响应头中的 Set-Cookie 字段合并到当前游客会话的 Cookie Jar。 */
1434
+ var updateCookiesFromResponse = (cookies, setCookie) => {
1435
+ const headers = Array.isArray(setCookie) ? setCookie : setCookie ? [setCookie] : [];
1436
+ for (const header of headers) {
1437
+ const [nameValue] = header.split(";", 1);
1438
+ const separatorIndex = nameValue.indexOf("=");
1439
+ if (separatorIndex > 0) cookies[nameValue.slice(0, separatorIndex).trim()] = nameValue.slice(separatorIndex + 1).trim();
1440
+ }
1441
+ };
1442
+ /** 按小红书 Web 端规则生成 a1,以及由 a1 派生的 webId。 */
1443
+ var generateA1AndWebId = () => {
1444
+ const source = `${Date.now().toString(16)}${Array.from(randomBytes(30), (byte) => COOKIE_RANDOM_CHARS[byte % 36]).join("")}5000`;
1445
+ const a1 = `${source}${crc32(source)}`.slice(0, 52);
1446
+ return {
1447
+ a1,
1448
+ webId: createHash("md5").update(a1).digest("hex")
1449
+ };
1450
+ };
1451
+ /** 计算与浏览器端实现兼容的无符号 CRC32 校验值。 */
1452
+ var crc32 = (input) => {
1453
+ let value = 4294967295;
1454
+ for (const byte of Buffer.from(input)) {
1455
+ value ^= byte;
1456
+ for (let bit = 0; bit < 8; bit += 1) value = value & 1 ? value >>> 1 ^ 3988292384 : value >>> 1;
1457
+ }
1458
+ return (value ^ 4294967295) >>> 0;
1459
+ };
1460
+ /** 从 scripting 接口返回的 VMP 数据中解码 websectiga Cookie。 */
1461
+ var generateWebsectiga = (payload) => {
1462
+ const bMatch = payload.match(/"b":"(.*?)",/);
1463
+ const dMatch = payload.match(/"d":(.*?)\}\)/);
1464
+ if (!bMatch || !dMatch) throw new Error("小红书 scripting 响应格式异常,无法生成 websectiga");
1465
+ const decoderData = JSON.parse(dMatch[1]);
1466
+ const encoded = Buffer.from(bMatch[1], "base64").toString("utf8");
1467
+ const logicList = [];
1468
+ for (let index = 0; index < encoded.length; index += 5) logicList.push(Array.from(encoded.slice(index, index + 5), (char) => char.charCodeAt(0) - 1));
1469
+ const start = decoderData[92];
1470
+ const end = decoderData[93];
1471
+ const target = logicList.slice(start, end + 1);
1472
+ const key = Array.from({ length: 64 }, (_, index) => {
1473
+ const item = target[675 + index * 2];
1474
+ if (!item) throw new Error("小红书 scripting 响应缺少 websectiga 解码数据");
1475
+ return decoderData[item[2]];
1476
+ });
1477
+ return Array.from({ length: 8 }, (_, group) => {
1478
+ const offset = 56 - group * 8;
1479
+ return String.fromCharCode(...key.slice(offset, offset + 8));
1480
+ }).join("");
1481
+ };
1482
+ /** 将浏览器指纹编码为 webprofile 接口要求的 DES-ECB profileData。 */
1483
+ var encryptProfileData = (fingerprint, desKey) => {
1484
+ const encoded = Buffer.from(JSON.stringify(fingerprint)).toString("base64");
1485
+ const blockSize = 8;
1486
+ const padding = blockSize - encoded.length % blockSize;
1487
+ const plaintext = Buffer.concat([Buffer.from(encoded), Buffer.alloc(padding)]);
1488
+ const cipher = createCipheriv("des-ede3", Buffer.from(desKey.repeat(3)), null);
1489
+ cipher.setAutoPadding(false);
1490
+ return Buffer.concat([cipher.update(plaintext), cipher.final()]).toString("hex");
1491
+ };
1492
+ /** 将 scripting 的 JSON 或 JSONP 响应统一还原为结构化数据。 */
1493
+ var unwrapScriptingResponse = (data) => {
1494
+ if (typeof data === "string") {
1495
+ const json = data.match(/^[^(]+\((.*)\)$/s)?.[1];
1496
+ return JSON.parse(json ?? data);
1497
+ }
1498
+ return data;
1499
+ };
1500
+ /**
1501
+ * 创建小红书 Web 端游客会话 Cookie。
1502
+ *
1503
+ * 该流程对应 Web 端首次访问时的 Cookie 初始化:生成 a1/webId,完成
1504
+ * scripting、webprofile 与 activate 三个会话请求,并返回最终 Cookie 字符串。
1505
+ */
1506
+ var createXiaohongshuGuestCookie = async (requestConfig) => {
1507
+ const cryptoConfig = createXiaohongshuCryptoConfig();
1508
+ const signer = new Xhshow(cryptoConfig);
1509
+ const cookies = {
1510
+ ...generateA1AndWebId(),
1511
+ webBuild: cryptoConfig.DATA_WEB_BUILD,
1512
+ xsecappid: "xhs-pc-web",
1513
+ loadts: String(Date.now()),
1514
+ abRequestId: randomUUID()
1515
+ };
1516
+ const { headers: requestHeaders, params: _params, ...transportConfig } = requestConfig ?? {};
1517
+ /** 发送会话初始化请求,并将响应中的 Set-Cookie 合并回当前 Cookie Jar。 */
1518
+ const request = async (url, data, signed = false) => {
1519
+ const signatureHeaders = signed ? signer.signHeadersPost(new URL(url).pathname, cookies, "xhs-pc-web", data) : {};
1520
+ const response = await axios({
1521
+ ...transportConfig,
1522
+ method: "POST",
1523
+ url,
1524
+ data,
1525
+ validateStatus: () => true,
1526
+ headers: {
1527
+ ...GUEST_HEADERS,
1528
+ ...requestHeaders,
1529
+ ...signatureHeaders,
1530
+ Cookie: toCookieString(cookies)
1531
+ }
1532
+ });
1533
+ updateCookiesFromResponse(cookies, response.headers["set-cookie"]);
1534
+ if (response.status < 200 || response.status >= 300) throw new Error(`小红书游客会话初始化失败:${url} 返回 HTTP ${response.status}`);
1535
+ return response.data;
1536
+ };
1537
+ const scriptingData = unwrapScriptingResponse(await request("https://as.xiaohongshu.com/api/sec/v1/scripting", {
1538
+ callFrom: "web",
1539
+ callback: "seccallback"
1540
+ })).data;
1541
+ if (!scriptingData?.data || !scriptingData.secPoisonId) throw new Error("小红书 scripting 响应缺少游客会话数据");
1542
+ cookies.websectiga = generateWebsectiga(scriptingData.data);
1543
+ cookies.sec_poison_id = scriptingData.secPoisonId;
1544
+ const fingerprint = new FingerprintGenerator(cryptoConfig).generate(cookies, GUEST_HEADERS["user-agent"]);
1545
+ await request(cryptoConfig.GID_URL, {
1546
+ platform: cryptoConfig.DATA_PLATFORM,
1547
+ profileData: encryptProfileData(fingerprint, cryptoConfig.DES_KEY),
1548
+ sdkVersion: cryptoConfig.DATA_SDK_VERSION,
1549
+ svn: cryptoConfig.DATA_SVN
1550
+ }, true);
1551
+ await request("https://edith.xiaohongshu.com/api/sns/web/v1/login/activate", {}, true);
1552
+ if (!cookies.web_session) throw new Error("小红书游客会话初始化失败:未获取到 web_session");
1553
+ return toCookieString(cookies);
1554
+ };
1555
+ //#endregion
1382
1556
  //#region ../amagi/packages/core/src/platform/xiaohongshu/sign/index.ts
1383
1557
  /**
1384
1558
  * 小红书签名算法类
1385
1559
  */
1386
1560
  var xiaohongshuSign = class {
1387
- static client = new Xhshow();
1561
+ static client = new Xhshow(createXiaohongshuCryptoConfig());
1562
+ /**
1563
+ * 创建包含 web_session 的小红书 Web 端游客 Cookie。
1564
+ *
1565
+ * `requestConfig` 会透传到游客会话初始化请求,可用于配置代理、超时等传输参数。
1566
+ */
1567
+ static createGuestCookie(requestConfig) {
1568
+ return createXiaohongshuGuestCookie(requestConfig);
1569
+ }
1388
1570
  /**
1389
1571
  * 生成GET请求的X-S签名
1390
1572
  * @param path - API路径
@@ -3288,7 +3470,7 @@ var XBogus = class {
3288
3470
  * @returns 包含完整URL、X-Bogus值和使用的User-Agent的元组
3289
3471
  */
3290
3472
  getXBogus(url, ua) {
3291
- const parsedUrl = new URL$2.URL(url);
3473
+ const parsedUrl = new URL$1.URL(url);
3292
3474
  const urlPath = parsedUrl.pathname + parsedUrl.search;
3293
3475
  const currentUa = ua ?? this.defaultUa;
3294
3476
  const rc4EncryptedUa = this.rc4Encrypt(this.uaKey, currentUa);
@@ -4236,7 +4418,7 @@ var DouyinData = async (data, cookie, requestConfig) => {
4236
4418
  if (isInvalidResponse) {
4237
4419
  const desc = `抖音${typeStr}搜索返回无有效数据,疑似触发反爬机制,你的抖音Cookie可能已经失效!`;
4238
4420
  const warningMessage = `
4239
- 获取响应数据失败!原因:${logger$2.yellow(`${typeStr}搜索返回无有效数据,疑似触发反爬机制`)}
4421
+ 获取响应数据失败!原因:${typeStr}搜索返回无有效数据,疑似触发反爬机制
4240
4422
  请求类型:「${data.methodType}」
4241
4423
  搜索关键词:「${data.query}」
4242
4424
  请求URL:${url}
@@ -4255,12 +4437,12 @@ var DouyinData = async (data, cookie, requestConfig) => {
4255
4437
  if (!list || list.length === 0) {
4256
4438
  const desc = `抖音${typeStr}搜索接口第一次请求就返回空数组,可能该关键词无搜索结果或触发风控限制,你的抖音Cookie可能已经失效!`;
4257
4439
  const warningMessage = `
4258
- 获取响应数据失败!原因:${logger$2.yellow(`${typeStr}搜索接口第一次请求就返回空数组,你的抖音Cookie可能已经失效!`)}
4440
+ 获取响应数据失败!原因:${typeStr}搜索接口第一次请求就返回空数组,你的抖音Cookie可能已经失效!
4259
4441
  请求类型:「${data.methodType}」
4260
4442
  搜索关键词:「${data.query}」
4261
4443
  请求URL:${url}
4262
4444
  `;
4263
- logger$2.warn(warningMessage);
4445
+ emitLogWarn(warningMessage);
4264
4446
  return {
4265
4447
  data: raw,
4266
4448
  amagiError: {
@@ -4351,7 +4533,7 @@ var DouyinData = async (data, cookie, requestConfig) => {
4351
4533
  });
4352
4534
  currentStart = currentEnd;
4353
4535
  }
4354
- logger$2.debug(`弹幕数据需要分${segments.length}段获取,总时长:${totalDuration}ms`);
4536
+ emitLogDebug(`弹幕数据需要分${segments.length}段获取,总时长:${totalDuration}ms`);
4355
4537
  const segmentPromises = segments.map(async (segment, index) => {
4356
4538
  const url = douyinApiUrls.getDanmakuList({
4357
4539
  aweme_id: data.aweme_id,
@@ -4364,10 +4546,10 @@ var DouyinData = async (data, cookie, requestConfig) => {
4364
4546
  ...baseRequestConfig,
4365
4547
  url: buildSignedUrl(url, signType, userAgent)
4366
4548
  });
4367
- logger$2.debug(`弹幕第${index + 1}段获取成功 (${segment.start}ms-${segment.end}ms)`);
4549
+ emitLogDebug(`弹幕第${index + 1}段获取成功 (${segment.start}ms-${segment.end}ms)`);
4368
4550
  return segmentData;
4369
4551
  } catch (error) {
4370
- logger$2.debug(`弹幕第${index + 1}段获取失败 (${segment.start}ms-${segment.end}ms):`, error);
4552
+ emitLogDebug(`弹幕第${index + 1}段获取失败 (${segment.start}ms-${segment.end}ms):`, error);
4371
4553
  return null;
4372
4554
  }
4373
4555
  });
@@ -4396,7 +4578,7 @@ var DouyinData = async (data, cookie, requestConfig) => {
4396
4578
  extra: finalExtra,
4397
4579
  log_pb: finalLogPb
4398
4580
  };
4399
- logger$2.debug(`弹幕数据合并完成,共获取${mergedDanmakuList.length}条弹幕`);
4581
+ emitLogDebug(`弹幕数据合并完成,共获取${mergedDanmakuList.length}条弹幕`);
4400
4582
  return finalDanmakuData;
4401
4583
  }
4402
4584
  default: {
@@ -4408,7 +4590,7 @@ var DouyinData = async (data, cookie, requestConfig) => {
4408
4590
  url
4409
4591
  });
4410
4592
  }
4411
- logger$2.warn(`未知的抖音数据接口:「${logger$2.red(data.methodType)}」`);
4593
+ emitLogWarn(`未知的抖音数据接口:「${data.methodType}」`);
4412
4594
  return null;
4413
4595
  }
4414
4596
  }
@@ -4476,11 +4658,11 @@ var GlobalGetData$3 = async (type, config) => {
4476
4658
  requestUrl: config.url
4477
4659
  };
4478
4660
  warningMessage = `
4479
- 获取响应数据失败!原因:${logger$2.yellow("接口返回内容为空,你的抖音ck可能已经失效!")}
4661
+ 获取响应数据失败!原因:接口返回内容为空,你的抖音ck可能已经失效!
4480
4662
  请求类型:「${type}」
4481
4663
  请求URL:${config.url}
4482
4664
  `;
4483
- logger$2.warn(warningMessage);
4665
+ emitLogWarn(warningMessage);
4484
4666
  const cookieError = new Error(Err.errorDescription);
4485
4667
  Object.assign(cookieError, {
4486
4668
  code: douoyinAPIErrorCode.COOKIE,
@@ -4497,11 +4679,11 @@ var GlobalGetData$3 = async (type, config) => {
4497
4679
  requestUrl: config.url
4498
4680
  };
4499
4681
  warningMessage = `
4500
- 获取响应数据失败!原因:${logger$2.yellow(filterReason)}
4682
+ 获取响应数据失败!原因:${filterReason}
4501
4683
  请求类型:「${type}」
4502
4684
  请求URL:${config.url}
4503
4685
  `;
4504
- logger$2.warn(warningMessage);
4686
+ emitLogWarn(warningMessage);
4505
4687
  const filterError = new Error(Err.errorDescription);
4506
4688
  Object.assign(filterError, {
4507
4689
  code: douoyinAPIErrorCode.FILTER,
@@ -7166,7 +7348,7 @@ var KuaishouData = async (data, cookie, requestConfig) => {
7166
7348
  }
7167
7349
  case "emojiList": return fetchKuaishouGraphqlPayload(data.methodType, kuaishouApiUrls.emojiList());
7168
7350
  default:
7169
- logger$2.warn(`Unknown Kuaishou API method: "${logger$2.red(data.methodType)}"`);
7351
+ emitLogWarn(`Unknown Kuaishou API method: "${data.methodType}"`);
7170
7352
  return null;
7171
7353
  }
7172
7354
  };
@@ -7205,12 +7387,12 @@ var GlobalGetData$2 = async (type, options, config) => {
7205
7387
  requestBody: JSON.stringify(options.data)
7206
7388
  };
7207
7389
  warningMessage = `
7208
- 获取响应数据失败!原因:${logger$2.yellow("接口返回内容为空,你的快手ck可能已经失效!")}
7390
+ 获取响应数据失败!原因:接口返回内容为空,你的快手ck可能已经失效!
7209
7391
  请求类型:「${type}」
7210
7392
  请求URL:${options.url}
7211
7393
  请求参数:${JSON.stringify(options.data, null, 2)}
7212
7394
  `;
7213
- logger$2.warn(warningMessage);
7395
+ emitLogWarn(warningMessage);
7214
7396
  const cookieError = new Error(Err.errorDescription);
7215
7397
  Object.assign(cookieError, {
7216
7398
  code: kuaishouAPIErrorCode.COOKIE,
@@ -7437,6 +7619,13 @@ function createBoundKuaishouFetcher(cookie, requestConfig) {
7437
7619
  }
7438
7620
  //#endregion
7439
7621
  //#region ../amagi/packages/core/src/platform/xiaohongshu/getdata.ts
7622
+ /** 小红书返回 code=-100,表示当前登录 Cookie 已失效。 */
7623
+ var XiaohongshuLoginExpiredError = class extends Error {
7624
+ constructor() {
7625
+ super("小红书登录 Cookie 已过期");
7626
+ this.name = "XiaohongshuLoginExpiredError";
7627
+ }
7628
+ };
7440
7629
  /**
7441
7630
  * 小红书数据获取函数
7442
7631
  * @param data - 请求数据参数
@@ -7445,131 +7634,143 @@ function createBoundKuaishouFetcher(cookie, requestConfig) {
7445
7634
  * @returns 返回小红书数据
7446
7635
  */
7447
7636
  var XiaohongshuData = async (data, cookie, requestConfig) => {
7448
- const defHeaders = getXiaohongshuDefaultConfig(cookie)["headers"];
7449
- const baseRequestConfig = {
7450
- method: "POST",
7451
- timeout: 1e4,
7452
- ...requestConfig,
7453
- headers: {
7454
- ...defHeaders,
7455
- ...requestConfig?.headers ?? {}
7456
- }
7457
- };
7458
- const xiaohongshuApiUrls = createXiaohongshuApiUrls();
7459
- switch (data.methodType) {
7460
- case "homeFeed": return await GlobalGetData$1(data.methodType, {
7461
- ...baseRequestConfig,
7462
- url: xiaohongshuApiUrls.homeFeed(data).Url,
7463
- data: JSON.stringify(xiaohongshuApiUrls.homeFeed(data).Body),
7464
- headers: {
7465
- ...baseRequestConfig.headers,
7466
- "x-s": xiaohongshuSign.generateXSPost(xiaohongshuApiUrls.homeFeed(data).apiPath, xiaohongshuSign.extractA1FromCookie(cookie ?? ""), "xhs-pc-web", xiaohongshuApiUrls.homeFeed(data).Body),
7467
- "x-s-common": xiaohongshuSign.generateXSCommon(cookie ?? ""),
7468
- "x-t": xiaohongshuSign.generateXT()
7469
- }
7470
- });
7471
- case "noteDetail": return await GlobalGetData$1(data.methodType, {
7472
- ...baseRequestConfig,
7473
- url: xiaohongshuApiUrls.noteDetail(data).Url,
7474
- data: xiaohongshuApiUrls.noteDetail(data).Body,
7637
+ /** 使用指定 Cookie 构建一次完整的小红书 API 请求。 */
7638
+ const requestWithCookie = async (requestCookie) => {
7639
+ const defHeaders = getXiaohongshuDefaultConfig(requestCookie)["headers"];
7640
+ const baseRequestConfig = {
7641
+ method: "POST",
7642
+ timeout: 1e4,
7643
+ ...requestConfig,
7475
7644
  headers: {
7476
- ...baseRequestConfig.headers,
7477
- "x-s": xiaohongshuSign.generateXSPost(xiaohongshuApiUrls.noteDetail(data).apiPath, xiaohongshuSign.extractA1FromCookie(cookie ?? ""), "xhs-pc-web", xiaohongshuApiUrls.noteDetail(data).Body),
7478
- "x-s-common": xiaohongshuSign.generateXSCommon(cookie ?? ""),
7479
- "x-t": xiaohongshuSign.generateXT()
7645
+ ...defHeaders,
7646
+ ...requestConfig?.headers ?? {}
7480
7647
  }
7481
- });
7482
- case "noteComments": {
7483
- const baseRequestConfig = {
7484
- method: "GET",
7485
- timeout: 1e4,
7486
- ...requestConfig,
7487
- headers: {
7488
- ...defHeaders,
7489
- ...requestConfig?.headers ?? {}
7490
- }
7491
- };
7492
- return await GlobalGetData$1(data.methodType, {
7648
+ };
7649
+ const xiaohongshuApiUrls = createXiaohongshuApiUrls();
7650
+ switch (data.methodType) {
7651
+ case "homeFeed": return await GlobalGetData$1(data.methodType, {
7493
7652
  ...baseRequestConfig,
7494
- url: xiaohongshuApiUrls.noteComments(data).Url,
7653
+ url: xiaohongshuApiUrls.homeFeed(data).Url,
7654
+ data: JSON.stringify(xiaohongshuApiUrls.homeFeed(data).Body),
7495
7655
  headers: {
7496
7656
  ...baseRequestConfig.headers,
7497
- "x-s": xiaohongshuSign.generateXSGet(xiaohongshuApiUrls.noteComments(data).apiPath, xiaohongshuSign.extractA1FromCookie(cookie ?? ""), "xhs-pc-web"),
7498
- "x-s-common": xiaohongshuSign.generateXSCommon(cookie ?? ""),
7657
+ "x-s": xiaohongshuSign.generateXSPost(xiaohongshuApiUrls.homeFeed(data).apiPath, xiaohongshuSign.extractA1FromCookie(requestCookie), "xhs-pc-web", xiaohongshuApiUrls.homeFeed(data).Body),
7658
+ "x-s-common": xiaohongshuSign.generateXSCommon(requestCookie),
7499
7659
  "x-t": xiaohongshuSign.generateXT()
7500
7660
  }
7501
7661
  });
7502
- }
7503
- case "userProfile": {
7504
- const baseRequestConfig = {
7505
- method: "GET",
7506
- timeout: 1e4,
7507
- ...requestConfig,
7662
+ case "noteDetail": return await GlobalGetData$1(data.methodType, {
7663
+ ...baseRequestConfig,
7664
+ url: xiaohongshuApiUrls.noteDetail(data).Url,
7665
+ data: xiaohongshuApiUrls.noteDetail(data).Body,
7508
7666
  headers: {
7509
- ...defHeaders,
7510
- ...requestConfig?.headers ?? {}
7667
+ ...baseRequestConfig.headers,
7668
+ "x-s": xiaohongshuSign.generateXSPost(xiaohongshuApiUrls.noteDetail(data).apiPath, xiaohongshuSign.extractA1FromCookie(requestCookie), "xhs-pc-web", xiaohongshuApiUrls.noteDetail(data).Body),
7669
+ "x-s-common": xiaohongshuSign.generateXSCommon(requestCookie),
7670
+ "x-t": xiaohongshuSign.generateXT()
7511
7671
  }
7512
- };
7513
- return {
7514
- code: 0,
7515
- data: extractCreatorInfoFromHtml(await GlobalGetData$1(data.methodType, {
7672
+ });
7673
+ case "noteComments": {
7674
+ const baseRequestConfig = {
7675
+ method: "GET",
7676
+ timeout: 1e4,
7677
+ ...requestConfig,
7678
+ headers: {
7679
+ ...defHeaders,
7680
+ ...requestConfig?.headers ?? {}
7681
+ }
7682
+ };
7683
+ return await GlobalGetData$1(data.methodType, {
7516
7684
  ...baseRequestConfig,
7517
- url: xiaohongshuApiUrls.userProfile(data).Url,
7685
+ url: xiaohongshuApiUrls.noteComments(data).Url,
7518
7686
  headers: {
7519
7687
  ...baseRequestConfig.headers,
7520
- "x-s": xiaohongshuSign.generateXSGet(xiaohongshuApiUrls.userProfile(data).apiPath, xiaohongshuSign.extractA1FromCookie(cookie ?? ""), "xhs-pc-web"),
7521
- "x-s-common": xiaohongshuSign.generateXSCommon(cookie ?? ""),
7688
+ "x-s": xiaohongshuSign.generateXSGet(xiaohongshuApiUrls.noteComments(data).apiPath, xiaohongshuSign.extractA1FromCookie(requestCookie), "xhs-pc-web"),
7689
+ "x-s-common": xiaohongshuSign.generateXSCommon(requestCookie),
7522
7690
  "x-t": xiaohongshuSign.generateXT()
7523
7691
  }
7524
- })),
7525
- msg: "success"
7526
- };
7527
- }
7528
- case "userNoteList": return await GlobalGetData$1(data.methodType, {
7529
- ...baseRequestConfig,
7530
- method: "GET",
7531
- url: xiaohongshuApiUrls.userNoteList(data).Url,
7532
- headers: {
7533
- ...baseRequestConfig.headers,
7534
- "x-b3-traceid": xiaohongshuSign.generateXB3Traceid(),
7535
- "x-s": xiaohongshuSign.generateXSGet(xiaohongshuApiUrls.userNoteList(data).apiPath, xiaohongshuSign.extractA1FromCookie(cookie ?? ""), "xhs-pc-web"),
7536
- "x-s-common": xiaohongshuSign.generateXSCommon(cookie ?? ""),
7537
- "x-t": xiaohongshuSign.generateXT()
7692
+ });
7538
7693
  }
7539
- });
7540
- case "emojiList": {
7541
- const baseRequestConfig = {
7694
+ case "userProfile": {
7695
+ const baseRequestConfig = {
7696
+ method: "GET",
7697
+ timeout: 1e4,
7698
+ ...requestConfig,
7699
+ headers: {
7700
+ ...defHeaders,
7701
+ ...requestConfig?.headers ?? {}
7702
+ }
7703
+ };
7704
+ return {
7705
+ code: 0,
7706
+ data: extractCreatorInfoFromHtml(await GlobalGetData$1(data.methodType, {
7707
+ ...baseRequestConfig,
7708
+ url: xiaohongshuApiUrls.userProfile(data).Url,
7709
+ headers: {
7710
+ ...baseRequestConfig.headers,
7711
+ "x-s": xiaohongshuSign.generateXSGet(xiaohongshuApiUrls.userProfile(data).apiPath, xiaohongshuSign.extractA1FromCookie(requestCookie), "xhs-pc-web"),
7712
+ "x-s-common": xiaohongshuSign.generateXSCommon(requestCookie),
7713
+ "x-t": xiaohongshuSign.generateXT()
7714
+ }
7715
+ })),
7716
+ msg: "success"
7717
+ };
7718
+ }
7719
+ case "userNoteList": return await GlobalGetData$1(data.methodType, {
7720
+ ...baseRequestConfig,
7542
7721
  method: "GET",
7543
- timeout: 1e4,
7544
- ...requestConfig,
7722
+ url: xiaohongshuApiUrls.userNoteList(data).Url,
7545
7723
  headers: {
7546
- ...defHeaders,
7547
- ...requestConfig?.headers ?? {}
7724
+ ...baseRequestConfig.headers,
7725
+ "x-b3-traceid": xiaohongshuSign.generateXB3Traceid(),
7726
+ "x-s": xiaohongshuSign.generateXSGet(xiaohongshuApiUrls.userNoteList(data).apiPath, xiaohongshuSign.extractA1FromCookie(requestCookie), "xhs-pc-web"),
7727
+ "x-s-common": xiaohongshuSign.generateXSCommon(requestCookie),
7728
+ "x-t": xiaohongshuSign.generateXT()
7548
7729
  }
7549
- };
7550
- return await GlobalGetData$1(data.methodType, {
7730
+ });
7731
+ case "emojiList": {
7732
+ const baseRequestConfig = {
7733
+ method: "GET",
7734
+ timeout: 1e4,
7735
+ ...requestConfig,
7736
+ headers: {
7737
+ ...defHeaders,
7738
+ ...requestConfig?.headers ?? {}
7739
+ }
7740
+ };
7741
+ return await GlobalGetData$1(data.methodType, {
7742
+ ...baseRequestConfig,
7743
+ url: xiaohongshuApiUrls.emojiList(data).Url,
7744
+ headers: {
7745
+ ...baseRequestConfig.headers,
7746
+ "x-s": xiaohongshuSign.generateXSGet(xiaohongshuApiUrls.emojiList(data).apiPath, xiaohongshuSign.extractA1FromCookie(requestCookie), "xhs-pc-web"),
7747
+ "x-s-common": xiaohongshuSign.generateXSCommon(requestCookie),
7748
+ "x-t": xiaohongshuSign.generateXT()
7749
+ }
7750
+ });
7751
+ }
7752
+ case "searchNotes": return await GlobalGetData$1(data.methodType, {
7551
7753
  ...baseRequestConfig,
7552
- url: xiaohongshuApiUrls.emojiList(data).Url,
7754
+ url: xiaohongshuApiUrls.searchNotes(data).Url,
7755
+ data: xiaohongshuApiUrls.searchNotes(data).Body,
7553
7756
  headers: {
7554
7757
  ...baseRequestConfig.headers,
7555
- "x-s": xiaohongshuSign.generateXSGet(xiaohongshuApiUrls.emojiList(data).apiPath, xiaohongshuSign.extractA1FromCookie(cookie ?? ""), "xhs-pc-web"),
7556
- "x-s-common": xiaohongshuSign.generateXSCommon(cookie ?? ""),
7758
+ "x-s": xiaohongshuSign.generateXSPost(xiaohongshuApiUrls.searchNotes(data).apiPath, xiaohongshuSign.extractA1FromCookie(requestCookie), "xhs-pc-web"),
7759
+ "x-s-common": xiaohongshuSign.generateXSCommon(requestCookie),
7557
7760
  "x-t": xiaohongshuSign.generateXT()
7558
7761
  }
7559
7762
  });
7763
+ default: throw new Error(`Unknown Xiaohongshu API method: "${data.methodType}"`);
7560
7764
  }
7561
- case "searchNotes": return await GlobalGetData$1(data.methodType, {
7562
- ...baseRequestConfig,
7563
- url: xiaohongshuApiUrls.searchNotes(data).Url,
7564
- data: xiaohongshuApiUrls.searchNotes(data).Body,
7565
- headers: {
7566
- ...baseRequestConfig.headers,
7567
- "x-s": xiaohongshuSign.generateXSPost(xiaohongshuApiUrls.searchNotes(data).apiPath, xiaohongshuSign.extractA1FromCookie(cookie ?? ""), "xhs-pc-web"),
7568
- "x-s-common": xiaohongshuSign.generateXSCommon(cookie ?? ""),
7569
- "x-t": xiaohongshuSign.generateXT()
7570
- }
7571
- });
7572
- default: throw new Error(`Unknown Xiaohongshu API method: "${logger$2.red(data.methodType)}"`);
7765
+ };
7766
+ const userCookie = cookie?.trim();
7767
+ if (!userCookie) return requestWithCookie(await xiaohongshuSign.createGuestCookie(requestConfig));
7768
+ try {
7769
+ return await requestWithCookie(userCookie);
7770
+ } catch (error) {
7771
+ if (!(error instanceof XiaohongshuLoginExpiredError)) throw error;
7772
+ emitLogWarn("小红书用户 Cookie 已过期,切换游客 Cookie 后重试请求");
7773
+ return requestWithCookie(await xiaohongshuSign.createGuestCookie(requestConfig));
7573
7774
  }
7574
7775
  };
7575
7776
  /**
@@ -7591,10 +7792,12 @@ var GlobalGetData$1 = async (methodType, config) => {
7591
7792
  throw networkError;
7592
7793
  }
7593
7794
  if (typeof response === "string" && response.includes("<html>")) return response;
7795
+ if (response.code === -100) throw new XiaohongshuLoginExpiredError();
7594
7796
  if (response.code !== 0) throw new Error(`API request failed: ${response.data?.msg ?? response.msg ?? "Unknown error"}, code: ${response.code}`);
7595
7797
  return response;
7596
7798
  } catch (error) {
7597
- logger$2.error(`Xiaohongshu API request failed [${methodType}]:`, error.message);
7799
+ if (error instanceof XiaohongshuLoginExpiredError) throw error;
7800
+ emitLogError(`Xiaohongshu API request failed [${methodType}]:`, error.message);
7598
7801
  return {
7599
7802
  code: 500,
7600
7803
  message: "error",
@@ -8523,7 +8726,7 @@ var fetchBilibili = async (data, cookie, requestConfig) => {
8523
8726
  ...baseRequestConfig,
8524
8727
  url: checkStatusUrl
8525
8728
  })).data === null) {
8526
- logger$2.error("评论区未开放");
8729
+ emitLogError("评论区未开放");
8527
8730
  return {
8528
8731
  code: 404,
8529
8732
  message: "评论区未开放",
@@ -8554,7 +8757,7 @@ var fetchBilibili = async (data, cookie, requestConfig) => {
8554
8757
  } else isEnd = true;
8555
8758
  requestCount++;
8556
8759
  if (isEnd || currentComments.length === 0 || !nextPaginationStr) {
8557
- logger$2.info("已到达评论末尾或无更多评论");
8760
+ emitLogInfo("已到达评论末尾或无更多评论");
8558
8761
  break;
8559
8762
  }
8560
8763
  }
@@ -8794,7 +8997,7 @@ var fetchBilibili = async (data, cookie, requestConfig) => {
8794
8997
  }
8795
8998
  }
8796
8999
  default:
8797
- logger$2.warn(`未知的B站数据接口:「${logger$2.red(data.methodType)}」`);
9000
+ emitLogWarn(`未知的B站数据接口:「${data.methodType}」`);
8798
9001
  return null;
8799
9002
  }
8800
9003
  };
@@ -8830,11 +9033,11 @@ var GlobalGetData = async (type, options, retryCount = 0) => {
8830
9033
  requestUrl: options.url
8831
9034
  };
8832
9035
  warningMessage = `
8833
- 获取响应数据失败!原因:${logger$2.yellow("接口返回内容为空,你的B站ck可能已经失效!")}
9036
+ 获取响应数据失败!原因:接口返回内容为空,你的B站ck可能已经失效!
8834
9037
  请求类型:「${type}」
8835
9038
  请求URL:${options.url}
8836
9039
  `;
8837
- logger$2.warn(warningMessage);
9040
+ emitLogWarn(warningMessage);
8838
9041
  const riskError = new Error(Err.errorDescription);
8839
9042
  Object.assign(riskError, {
8840
9043
  code: bilibiliAPIErrorCode.RISK_CONTROL_FAILED,
@@ -8856,12 +9059,12 @@ var GlobalGetData = async (type, options, retryCount = 0) => {
8856
9059
  responseCode: result.code
8857
9060
  };
8858
9061
  warningMessage = `
8859
- 获取响应数据失败!原因:${logger$2.yellow(errorMessage)}
9062
+ 获取响应数据失败!原因:${errorMessage}
8860
9063
  错误代码:${result.code}
8861
9064
  请求类型:「${type}」
8862
9065
  请求URL:${options.url}
8863
9066
  `;
8864
- logger$2.warn(warningMessage);
9067
+ emitLogWarn(warningMessage);
8865
9068
  const apiError = new Error(Err.errorDescription);
8866
9069
  Object.assign(apiError, {
8867
9070
  code: result.code,
@@ -16943,8 +17146,9 @@ var BilibiliReserveCard = ({ reserve }) => {
16943
17146
  }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
16944
17147
  className: "shrink-0",
16945
17148
  children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Button, {
16946
- className: `text-5xl font-normal px-8 py-5 h-auto min-w-0 ${reserve.buttonText === "已结束" ? "bg-surface-secondary/70 text-muted" : "bg-[#fb7299] text-white"}`,
16947
- children: [reserve.buttonText !== "已结束" && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(BellRing, { className: "scale-180 mr-4" }), reserve.buttonText]
17149
+ size: "lg",
17150
+ className: `font-normal scale-200 mr-15 rounded-xl ${reserve.buttonText === "已结束" ? "bg-surface-secondary/70 text-muted" : "bg-[#fb7299] text-white"}`,
17151
+ children: [reserve.buttonText !== "已结束" && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(BellRing, { size: 330 }), reserve.buttonText]
16948
17152
  })
16949
17153
  })]
16950
17154
  })
@@ -19032,6 +19236,69 @@ var BilibiliVideoInfo = import_react.memo((props) => {
19032
19236
  });
19033
19237
  BilibiliVideoInfo.displayName = "BilibiliVideoInfo";
19034
19238
  //#endregion
19239
+ //#region ../template/src/components/platforms/douyin/Icons.tsx
19240
+ var svgProps = (size, { weight: _weight, ...props }) => ({
19241
+ width: size,
19242
+ height: size,
19243
+ fill: "none",
19244
+ xmlns: "http://www.w3.org/2000/svg",
19245
+ ...props
19246
+ });
19247
+ /** 抖音官方点赞图标,提取自 packages/template/icon.html。 */
19248
+ var DouyinLikeIcon = ({ size = 36, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
19249
+ viewBox: "0 0 891 816",
19250
+ ...svgProps(size, props),
19251
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", {
19252
+ fill: "currentColor",
19253
+ d: "M453.036 88.712C493.774 30.664 560.66 0 634.251 0 774.403 0 890.972 121.59 890.972 266.137v.054c.01-.02.019-.04.028-.06 0 4.121-.07 7.241-.122 9.537-.072 3.151-.108 4.747.122 5.247-.531 30.403-5.778 55.522-15.101 88.712-5.289 5.96-10.204 17.184-15.1 29.572-7.724 11.998-10.647 17.81-15.101 29.57a546.67 546.67 0 0 1-14.452 22.974c-37.449 56.8-87.537 113.33-137.579 163.509-78.331 79.025-158.123 144.805-192.835 173.422-9.585 7.901-15.732 12.969-17.464 14.7-12.301 12.303-24.603 12.611-36.905 12.619-.324.004-.649.006-.977.006-25.236 0-37.854-12.619-50.472-25.237-.963-.963-3.413-2.984-7.156-5.979-38.233-28.184-124.273-96.997-205.116-180C121.066 542.02 61.622 470.007 29.092 399.588 16.474 374.351.731 314.264 0 280.922c.269-.267.227-1.873.144-5.078C.083 273.498 0 270.297 0 266.137 0 121.524 116.502 0 256.721 0c73.458 0 140.405 30.664 196.315 88.712Z"
19254
+ })
19255
+ });
19256
+ /** 抖音官方评论图标,提取自 packages/template/icon.html。 */
19257
+ var DouyinCommentIcon = ({ size = 36, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
19258
+ viewBox: "-24.75 -11.25 22.5 22.31",
19259
+ ...svgProps(size, props),
19260
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", {
19261
+ fill: "currentColor",
19262
+ d: " M-4.644999980926514,4.482999801635742 C-7.25,7.818999767303467 -13.482000350952148,8.300000190734863 -13.482000350952148,8.300000190734863 C-13.482000350952148,8.300000190734863 -14.413999557495117,11.48799991607666 -12.135000228881836,10.821000099182129 C-9.855999946594238,10.154000282287598 -7.25,8.152000427246094 -4.644999980926514,4.482999801635742z M-17.36,-1.04 C-17.36,-0.16 -18.07,0.56 -18.96,0.56 C-18.96,0.56 -18.96,0.56 -18.96,0.56 C-19.85,0.56 -20.57,-0.16 -20.57,-1.04 C-20.57,-1.92 -19.85,-2.64 -18.96,-2.64 C-18.07,-2.64 -17.36,-1.92 -17.36,-1.04z M-11.89,-1.04 C-11.89,-0.16 -12.61,0.56 -13.5,0.56 C-13.5,0.56 -13.5,0.56 -13.5,0.56 C-14.39,0.56 -15.11,-0.16 -15.11,-1.04 C-15.11,-1.92 -14.39,-2.64 -13.5,-2.64 C-12.61,-2.64 -11.89,-1.92 -11.89,-1.04z M-6.43,-1.04 C-6.43,-0.16 -7.15,0.56 -8.04,0.56 C-8.04,0.56 -8.04,0.56 -8.04,0.56 C-8.92,0.56 -9.64,-0.16 -9.64,-1.04 C-9.64,-1.92 -8.92,-2.64 -8.04,-2.64 C-7.15,-2.64 -6.43,-1.92 -6.43,-1.04z M-5.79,5.98 C-3.56,3.75 -2.25,1.42 -2.25,-1.29 C-2.25,-6.79 -7.29,-11.25 -13.5,-11.25 C-19.71,-11.25 -24.75,-6.79 -24.75,-1.29 C-24.75,4.21 -19.55,7.99 -13.34,7.99 C-13.34,7.99 -13.34,11.06 -13.34,11.06 C-13.34,11.06 -8.51,8.72 -5.79,5.98z"
19263
+ })
19264
+ });
19265
+ /** 抖音官方收藏图标,提取自 packages/template/icon.html。 */
19266
+ var DouyinFavoriteIcon = ({ size = 36, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
19267
+ viewBox: "-2.285 -1.439 104.57 99.703",
19268
+ ...svgProps(size, props),
19269
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", {
19270
+ fill: "currentColor",
19271
+ d: "M43.79199981689453,4.316999912261963 C45.93899917602539,-1.4390000104904175 54.06100082397461,-1.4390000104904175 56.20800018310547,4.316999912261963 C56.20800018310547,4.316999912261963 65.927001953125,30.375 65.927001953125,30.375 C65.927001953125,30.375 93.6510009765625,31.59000015258789 93.6510009765625,31.59000015258789 C99.7750015258789,31.857999801635742 102.28500366210938,39.60200119018555 97.48799896240234,43.428001403808594 C97.48799896240234,43.428001403808594 75.77100372314453,60.74700164794922 75.77100372314453,60.74700164794922 C75.77100372314453,60.74700164794922 83.18599700927734,87.55599975585938 83.18599700927734,87.55599975585938 C84.8239974975586,93.47799682617188 78.25299835205078,98.26399993896484 73.14099884033203,94.87200164794922 C73.14099884033203,94.87200164794922 50,79.51799774169922 50,79.51799774169922 C50,79.51799774169922 26.858999252319336,94.87200164794922 26.858999252319336,94.87200164794922 C21.746999740600586,98.26399993896484 15.175999641418457,93.47799682617188 16.81399917602539,87.55599975585938 C16.81399917602539,87.55599975585938 24.229000091552734,60.74700164794922 24.229000091552734,60.74700164794922 C24.229000091552734,60.74700164794922 2.51200008392334,43.428001403808594 2.51200008392334,43.428001403808594 C-2.2850000858306885,39.60200119018555 0.22499999403953552,31.857999801635742 6.348999977111816,31.59000015258789 C6.348999977111816,31.59000015258789 34.073001861572266,30.375 34.073001861572266,30.375 C34.073001861572266,30.375 43.79199981689453,4.316999912261963 43.79199981689453,4.316999912261963z"
19272
+ })
19273
+ });
19274
+ /** 抖音官方分享图标,提取自 packages/template/icon.html。 */
19275
+ var DouyinShareIcon = ({ size = 36, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
19276
+ viewBox: "-13.517 -10.558 25.734 22.375",
19277
+ ...svgProps(size, props),
19278
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", {
19279
+ fill: "currentColor",
19280
+ d: "M.815 4.762V-4.93s-6.033-.564-10.06 3.755c-4.027 4.319-4.272 12.992-1.597 8.919C-8.062 3.511.815 4.762.815 4.762Zm9.699-1.767c1.655-1.461 1.703-3.887.107-5.413L3.706-9.032C2.11-10.558.815-10.264.815-8.375v3.421c.009 6.839 0 6.039 0 6.039 0 2.208 0 5.452 0 7.24 0 1.788 1.343 2.053 2.998.591l6.701-5.921Z"
19281
+ })
19282
+ });
19283
+ /** 抖音官方推荐图标。 */
19284
+ var DouyinRecommendIcon = ({ size = 36, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
19285
+ viewBox: "0 0 27 27",
19286
+ ...svgProps(size, props),
19287
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", {
19288
+ fill: "currentColor",
19289
+ d: "M18.544 22.86H8.42V9.697l5.821-5.821a1.79 1.79 0 0 1 2.531 0c.118.118.215.278.291.48.076.203.114.397.114.583v.354l-1.114 4.404h5.518c.54 0 1.012.203 1.417.608.405.405.608.877.608 1.417v2.025a2.059 2.059 0 0 1-.152.759l-3.037 7.137c-.152.338-.405.625-.76.861a1.978 1.978 0 0 1-1.113.354ZM6.79 9.697V22.86H4.366a1.625 1.625 0 0 1-1.625-1.625v-9.91c0-.898.728-1.626 1.625-1.626H6.79Z"
19290
+ })
19291
+ });
19292
+ /** 抖音官方更多图标,提取自 packages/template/icon.html。 */
19293
+ var DouyinMoreIcon = ({ size = 36, ...props }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("svg", {
19294
+ viewBox: "0 0 36 36",
19295
+ ...svgProps(size, props),
19296
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("path", {
19297
+ fill: "currentColor",
19298
+ d: "M13.556 17.778a1.778 1.778 0 1 1-3.556 0 1.778 1.778 0 0 1 3.556 0Zm6.222 0a1.778 1.778 0 1 1-3.556 0 1.778 1.778 0 0 1 3.556 0Zm4.444 1.778a1.778 1.778 0 1 0 0-3.556 1.778 1.778 0 0 0 0 3.556Z"
19299
+ })
19300
+ });
19301
+ //#endregion
19035
19302
  //#region ../template/src/components/platforms/douyin/ArticleWork.tsx
19036
19303
  /**
19037
19304
  * 抖音Logo头部组件
@@ -19173,22 +19440,22 @@ var InfoSection$2 = (props) => {
19173
19440
  children: [
19174
19441
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19175
19442
  className: "flex gap-2 items-center",
19176
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Heart, { className: "w-11 h-11 text-like" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.dianzan, "点赞"] })]
19443
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 44 }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.dianzan, "点赞"] })]
19177
19444
  }),
19178
19445
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: "·" }),
19179
19446
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19180
19447
  className: "flex gap-2 items-center",
19181
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(MessageCircle, { className: "w-11 h-11 text-comment" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.pinglun, "评论"] })]
19448
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinCommentIcon, { size: 44 }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.pinglun, "评论"] })]
19182
19449
  }),
19183
19450
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: "·" }),
19184
19451
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19185
19452
  className: "flex gap-2 items-center",
19186
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Bookmark, { className: "w-11 h-11" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.shouchang, "收藏"] })]
19453
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinFavoriteIcon, { size: 44 }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.shouchang, "收藏"] })]
19187
19454
  }),
19188
19455
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: "·" }),
19189
19456
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19190
19457
  className: "flex gap-2 items-center",
19191
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Share2, { className: "w-11 h-11 text-success" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.share, "分享"] })]
19458
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinShareIcon, { size: 44 }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.share, "分享"] })]
19192
19459
  })
19193
19460
  ]
19194
19461
  }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
@@ -19236,7 +19503,7 @@ var UserInfoSection$1 = (props) => {
19236
19503
  children: [
19237
19504
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19238
19505
  className: "flex gap-1 items-center",
19239
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Heart, { className: "w-7 h-7 text-like" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
19506
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 28 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
19240
19507
  className: "text-muted",
19241
19508
  children: "获赞"
19242
19509
  })]
@@ -19422,28 +19689,28 @@ var VideoInfoHeader = (props) => {
19422
19689
  children: [
19423
19690
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19424
19691
  className: "flex items-center gap-4 text-foreground/50",
19425
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Heart, { size: 48 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
19692
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 48 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
19426
19693
  className: "text-5xl font-medium text-foreground/90",
19427
19694
  children: formatDouyinCommentDiggCount(props.Statistics.digg_count)
19428
19695
  })]
19429
19696
  }),
19430
19697
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19431
19698
  className: "flex items-center gap-4 text-foreground/50",
19432
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(MessageCircle, { size: 48 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
19699
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinCommentIcon, { size: 48 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
19433
19700
  className: "text-5xl font-medium text-foreground/90",
19434
19701
  children: formatDouyinCommentDiggCount(props.Statistics.comment_count)
19435
19702
  })]
19436
19703
  }),
19437
19704
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19438
19705
  className: "flex items-center gap-4 text-foreground/50",
19439
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Share2, { size: 48 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
19706
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinShareIcon, { size: 48 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
19440
19707
  className: "text-5xl font-medium text-foreground/90",
19441
19708
  children: formatDouyinCommentDiggCount(props.Statistics.share_count)
19442
19709
  })]
19443
19710
  }),
19444
19711
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19445
19712
  className: "flex items-center gap-4 text-foreground/50",
19446
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Star, { size: 48 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
19713
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinFavoriteIcon, { size: 48 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
19447
19714
  className: "text-5xl font-medium text-foreground/90",
19448
19715
  children: formatDouyinCommentDiggCount(props.Statistics.collect_count)
19449
19716
  })]
@@ -19583,7 +19850,7 @@ var ReplyItemComponent = ({ reply, depth = 0, isLast, maxDepth = 6 }) => {
19583
19850
  className: "flex items-center h-12.5",
19584
19851
  children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19585
19852
  className: "flex items-center text-muted",
19586
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(CircleEllipsis, {
19853
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinMoreIcon, {
19587
19854
  size: 45,
19588
19855
  className: "mr-5"
19589
19856
  }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
@@ -19689,10 +19956,7 @@ var ReplyItemComponent = ({ reply, depth = 0, isLast, maxDepth = 6 }) => {
19689
19956
  }),
19690
19957
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19691
19958
  className: "flex gap-2 items-center",
19692
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Heart, {
19693
- size: 40,
19694
- className: "text-muted"
19695
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
19959
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 40 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
19696
19960
  className: "text-4xl select-text",
19697
19961
  children: formatDouyinCommentDiggCount(reply.digg_count)
19698
19962
  })]
@@ -19796,10 +20060,7 @@ var CommentItemComponent$1 = (props) => {
19796
20060
  }),
19797
20061
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19798
20062
  className: "flex gap-2 items-center transition-colors cursor-pointer",
19799
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Heart, {
19800
- size: 44,
19801
- className: "text-muted"
19802
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
20063
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 44 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
19803
20064
  className: "text-4xl select-text",
19804
20065
  children: formatDouyinCommentDiggCount(props.digg_count)
19805
20066
  })]
@@ -19941,22 +20202,22 @@ var InfoSection$1 = (props) => {
19941
20202
  children: [
19942
20203
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19943
20204
  className: "flex gap-2 items-center",
19944
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Heart, { className: "w-11 h-11 text-like" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.dianzan, "点赞"] })]
20205
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 44 }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.dianzan, "点赞"] })]
19945
20206
  }),
19946
20207
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: "·" }),
19947
20208
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19948
20209
  className: "flex gap-2 items-center",
19949
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(MessageCircle, { className: "w-11 h-11 text-comment" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.pinglun, "评论"] })]
20210
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinCommentIcon, { size: 44 }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.pinglun, "评论"] })]
19950
20211
  }),
19951
20212
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: "·" }),
19952
20213
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19953
20214
  className: "flex gap-2 items-center",
19954
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Bookmark, { className: "w-11 h-11" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.shouchang, "收藏"] })]
20215
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinFavoriteIcon, { size: 44 }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.shouchang, "收藏"] })]
19955
20216
  }),
19956
20217
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: "·" }),
19957
20218
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
19958
20219
  className: "flex gap-2 items-center",
19959
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Share2, { className: "w-11 h-11 text-success" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.share, "分享"] })]
20220
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinShareIcon, { size: 44 }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: [props.data.share, "分享"] })]
19960
20221
  })
19961
20222
  ]
19962
20223
  }),
@@ -20015,10 +20276,7 @@ var UserInfoSection = (props) => {
20015
20276
  children: [
20016
20277
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
20017
20278
  className: "flex gap-1 items-center",
20018
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Heart, {
20019
- size: 28,
20020
- className: "text-like"
20021
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
20279
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 28 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
20022
20280
  className: "text-muted",
20023
20281
  children: "获赞"
20024
20282
  })]
@@ -20287,10 +20545,7 @@ var DouyinFavoriteList = (props) => {
20287
20545
  }),
20288
20546
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
20289
20547
  className: "absolute -bottom-3 -right-3 bg-rose-500 text-white px-5 py-2 rounded-full border-[5px] border-white font-bold text-xl shadow-xl flex items-center gap-2",
20290
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(RiHeart3Fill, {
20291
- size: 20,
20292
- className: "fill-current"
20293
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: "赞了" })]
20548
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 20 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: "赞了" })]
20294
20549
  })
20295
20550
  ]
20296
20551
  }),
@@ -20314,10 +20569,7 @@ var DouyinFavoriteList = (props) => {
20314
20569
  className: "mt-6 flex flex-col items-center gap-2 text-rose-500",
20315
20570
  children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
20316
20571
  className: "flex items-center gap-3",
20317
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(RiHeart3Fill, {
20318
- size: 40,
20319
- className: "fill-current"
20320
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
20572
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 40 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
20321
20573
  className: "text-4xl font-bold",
20322
20574
  children: "刚刚赞了这个作品"
20323
20575
  })]
@@ -20424,24 +20676,24 @@ var DouyinFavoriteList = (props) => {
20424
20676
  className: "grid grid-cols-5 gap-6 z-10",
20425
20677
  children: [
20426
20678
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$3, {
20427
- icon: RiHeart3Fill,
20679
+ icon: DouyinLikeIcon,
20428
20680
  value: props.data.dianzan,
20429
- iconClassName: "text-rose-500/80"
20681
+ iconColor: "#FE2C55"
20430
20682
  }),
20431
20683
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$3, {
20432
- icon: RiThumbUpFill,
20684
+ icon: DouyinRecommendIcon,
20433
20685
  value: props.data.tuijian
20434
20686
  }),
20435
20687
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$3, {
20436
- icon: RiMessage3Fill,
20688
+ icon: DouyinCommentIcon,
20437
20689
  value: props.data.pinglun
20438
20690
  }),
20439
20691
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$3, {
20440
- icon: RiStarFill,
20692
+ icon: DouyinFavoriteIcon,
20441
20693
  value: props.data.shouchang
20442
20694
  }),
20443
20695
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$3, {
20444
- icon: RiShareForwardFill,
20696
+ icon: DouyinShareIcon,
20445
20697
  value: props.data.share
20446
20698
  })
20447
20699
  ]
@@ -20454,11 +20706,12 @@ var DouyinFavoriteList = (props) => {
20454
20706
  });
20455
20707
  };
20456
20708
  /** 统计项小组件 */
20457
- var StatItem$3 = ({ icon: IconComponent, value, iconClassName }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
20709
+ var StatItem$3 = ({ icon: IconComponent, value, iconColor }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
20458
20710
  className: "flex flex-col items-center justify-center gap-2 py-6 rounded-3xl bg-surface",
20459
20711
  children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(IconComponent, {
20460
20712
  size: 48,
20461
- className: `opacity-90 ${iconClassName || "text-muted"}`
20713
+ color: iconColor,
20714
+ className: "opacity-90"
20462
20715
  }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
20463
20716
  className: "text-2xl font-bold text-foreground/70 mt-1",
20464
20717
  children: value
@@ -20727,22 +20980,22 @@ var DouyinDynamicStatus$1 = (props) => {
20727
20980
  className: "flex gap-6 items-center text-5xl tracking-normal select-text text-foreground/70",
20728
20981
  children: [
20729
20982
  {
20730
- icon: o$3,
20983
+ icon: DouyinLikeIcon,
20731
20984
  value: dianzan,
20732
20985
  label: "点赞"
20733
20986
  },
20734
20987
  {
20735
- icon: t,
20988
+ icon: DouyinCommentIcon,
20736
20989
  value: pinglun,
20737
20990
  label: "评论"
20738
20991
  },
20739
20992
  {
20740
- icon: r,
20993
+ icon: DouyinFavoriteIcon,
20741
20994
  value: shouchang,
20742
20995
  label: "收藏"
20743
20996
  },
20744
20997
  {
20745
- icon: e$1,
20998
+ icon: DouyinShareIcon,
20746
20999
  value: share,
20747
21000
  label: "分享"
20748
21001
  }
@@ -20911,19 +21164,19 @@ var DouyinDynamicFooter$1 = (props) => {
20911
21164
  className: "text-3xl flex gap-6 items-center text-foreground/70",
20912
21165
  children: [
20913
21166
  {
20914
- icon: o$3,
21167
+ icon: DouyinLikeIcon,
20915
21168
  iconSize: 36,
20916
21169
  label: "获赞",
20917
21170
  value: 获赞
20918
21171
  },
20919
21172
  {
20920
- icon: o$4,
21173
+ icon: o$3,
20921
21174
  iconSize: 36,
20922
21175
  label: "关注",
20923
21176
  value: 关注
20924
21177
  },
20925
21178
  {
20926
- icon: r$1,
21179
+ icon: r,
20927
21180
  iconSize: 36,
20928
21181
  label: "粉丝",
20929
21182
  value: 粉丝
@@ -21186,10 +21439,7 @@ var InfoSection = ({ data }) => {
21186
21439
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
21187
21440
  className: "flex items-center gap-1.5",
21188
21441
  children: [
21189
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Heart, {
21190
- size: 28,
21191
- className: "text-foreground/20"
21192
- }),
21442
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 28 }),
21193
21443
  data.like_count,
21194
21444
  "点赞"
21195
21445
  ]
@@ -21301,7 +21551,7 @@ var BottomSection = ({ data }) => {
21301
21551
  className: "flex flex-col gap-2 px-6 py-3 rounded-2xl bg-default/45",
21302
21552
  children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
21303
21553
  className: "flex items-center gap-2",
21304
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Heart, { size: 28 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
21554
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 28 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
21305
21555
  className: "text-foreground/40",
21306
21556
  children: "获赞"
21307
21557
  })]
@@ -21463,7 +21713,7 @@ var MusicAuthorInfoSection = ({ avatarUrl, username, userShortId, totalFavorited
21463
21713
  }),
21464
21714
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
21465
21715
  className: "flex gap-2 items-center",
21466
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Heart, { className: "w-8 h-8 text-like" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: ["获赞: ", totalFavorited] })]
21716
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 32 }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", { children: ["获赞: ", totalFavorited] })]
21467
21717
  }),
21468
21718
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
21469
21719
  className: "flex gap-2 items-center",
@@ -21855,10 +22105,7 @@ var DouyinRecommendList = (props) => {
21855
22105
  }),
21856
22106
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
21857
22107
  className: "absolute -bottom-3 -right-3 bg-emerald-500 text-white px-5 py-2 rounded-full border-[5px] border-white font-bold text-xl shadow-xl flex items-center gap-2",
21858
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(RiThumbUpFill, {
21859
- size: 20,
21860
- className: "fill-current"
21861
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: "推荐" })]
22108
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinRecommendIcon, { size: 20 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: "推荐" })]
21862
22109
  })
21863
22110
  ]
21864
22111
  }),
@@ -21882,10 +22129,7 @@ var DouyinRecommendList = (props) => {
21882
22129
  className: "mt-6 flex flex-col items-center gap-2 text-emerald-500",
21883
22130
  children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
21884
22131
  className: "flex items-center gap-3",
21885
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(RiThumbUpFill, {
21886
- size: 40,
21887
- className: "fill-current"
21888
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
22132
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinRecommendIcon, { size: 40 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
21889
22133
  className: "text-4xl font-bold",
21890
22134
  children: "刚刚推荐了这个作品"
21891
22135
  })]
@@ -21992,24 +22236,24 @@ var DouyinRecommendList = (props) => {
21992
22236
  className: "grid grid-cols-5 gap-6 z-10",
21993
22237
  children: [
21994
22238
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$2, {
21995
- icon: RiHeart3Fill,
22239
+ icon: DouyinLikeIcon,
21996
22240
  value: props.data.dianzan
21997
22241
  }),
21998
22242
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$2, {
21999
- icon: RiThumbUpFill,
22243
+ icon: DouyinRecommendIcon,
22000
22244
  value: props.data.tuijian,
22001
- iconClassName: "text-emerald-500/80"
22245
+ iconColor: "#13C15A"
22002
22246
  }),
22003
22247
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$2, {
22004
- icon: RiMessage3Fill,
22248
+ icon: DouyinCommentIcon,
22005
22249
  value: props.data.pinglun
22006
22250
  }),
22007
22251
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$2, {
22008
- icon: RiStarFill,
22252
+ icon: DouyinFavoriteIcon,
22009
22253
  value: props.data.shouchang
22010
22254
  }),
22011
22255
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$2, {
22012
- icon: RiShareForwardFill,
22256
+ icon: DouyinShareIcon,
22013
22257
  value: props.data.share
22014
22258
  })
22015
22259
  ]
@@ -22022,11 +22266,12 @@ var DouyinRecommendList = (props) => {
22022
22266
  });
22023
22267
  };
22024
22268
  /** 统计项小组件 */
22025
- var StatItem$2 = ({ icon: IconComponent, value, iconClassName }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
22269
+ var StatItem$2 = ({ icon: IconComponent, value, iconColor }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
22026
22270
  className: "flex flex-col items-center justify-center gap-2 py-6 rounded-3xl bg-surface",
22027
22271
  children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(IconComponent, {
22028
22272
  size: 48,
22029
- className: `opacity-90 ${iconClassName || "text-muted"}`
22273
+ color: iconColor,
22274
+ className: "opacity-90"
22030
22275
  }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
22031
22276
  className: "text-2xl font-bold text-foreground/70 mt-1",
22032
22277
  children: value
@@ -22043,12 +22288,12 @@ var pushTypeConfig = {
22043
22288
  favorite: {
22044
22289
  label: "喜欢列表",
22045
22290
  color: "bg-[#d94f50]/5 text-[#b04546] border-[#d94f50]/12",
22046
- icon: Heart
22291
+ icon: DouyinLikeIcon
22047
22292
  },
22048
22293
  recommend: {
22049
22294
  label: "推荐列表",
22050
22295
  color: "bg-[#c9943a]/5 text-[#a07d30] border-[#c9943a]/12",
22051
- icon: Sparkles
22296
+ icon: DouyinRecommendIcon
22052
22297
  },
22053
22298
  live: {
22054
22299
  label: "直播状态",
@@ -22182,7 +22427,7 @@ var DouyinUserItem = (props) => {
22182
22427
  label: "粉丝"
22183
22428
  },
22184
22429
  {
22185
- icon: Heart,
22430
+ icon: DouyinLikeIcon,
22186
22431
  value: props.total_favorited,
22187
22432
  label: "获赞"
22188
22433
  },
@@ -22454,19 +22699,19 @@ var VideoCard = ({ video }) => {
22454
22699
  children: [
22455
22700
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
22456
22701
  className: "flex items-center gap-2 text-foreground/70",
22457
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(AiFillHeart, { size: 34 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: formatCount(video.statistics.like_count) })]
22702
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 34 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: formatCount(video.statistics.like_count) })]
22458
22703
  }),
22459
22704
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
22460
22705
  className: "flex items-center gap-2 text-foreground/70",
22461
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(FaCommentDots, { size: 34 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: formatCount(video.statistics.comment_count) })]
22706
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinCommentIcon, { size: 34 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: formatCount(video.statistics.comment_count) })]
22462
22707
  }),
22463
22708
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
22464
22709
  className: "flex items-center gap-2 text-foreground/70",
22465
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(AiFillStar, { size: 34 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: formatCount(video.statistics.collect_count) })]
22710
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinFavoriteIcon, { size: 34 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: formatCount(video.statistics.collect_count) })]
22466
22711
  }),
22467
22712
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
22468
22713
  className: "flex items-center gap-2 text-foreground/70",
22469
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(RiShareForwardFill, { size: 34 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: formatCount(video.statistics.share_count) })]
22714
+ children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinShareIcon, { size: 34 }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: formatCount(video.statistics.share_count) })]
22470
22715
  })
22471
22716
  ]
22472
22717
  })
@@ -22572,10 +22817,7 @@ var DouyinUserVideoList = (prpos) => {
22572
22817
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", {
22573
22818
  className: "flex items-center gap-2",
22574
22819
  children: [
22575
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AiFillHeart, {
22576
- size: 28,
22577
- className: "text-muted"
22578
- }),
22820
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 28 }),
22579
22821
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
22580
22822
  className: "text-muted",
22581
22823
  children: "获赞"
@@ -22792,19 +23034,19 @@ var DouyinVideoInfo = import_react.memo((props) => {
22792
23034
  className: "flex items-center gap-14 shrink-0",
22793
23035
  children: [
22794
23036
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$1, {
22795
- icon: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Heart, { size: 48 }),
23037
+ icon: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinLikeIcon, { size: 48 }),
22796
23038
  value: props.data.statistics.digg_count
22797
23039
  }),
22798
23040
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$1, {
22799
- icon: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(MessageCircle, { size: 48 }),
23041
+ icon: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinCommentIcon, { size: 48 }),
22800
23042
  value: props.data.statistics.comment_count
22801
23043
  }),
22802
23044
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$1, {
22803
- icon: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Star, { size: 48 }),
23045
+ icon: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinFavoriteIcon, { size: 48 }),
22804
23046
  value: props.data.statistics.collect_count
22805
23047
  }),
22806
23048
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatItem$1, {
22807
- icon: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Share2, { size: 48 }),
23049
+ icon: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(DouyinShareIcon, { size: 48 }),
22808
23050
  value: props.data.statistics.share_count
22809
23051
  })
22810
23052
  ]
@@ -23060,22 +23302,22 @@ var DouyinDynamicStatus = (props) => {
23060
23302
  className: "flex gap-6 items-center text-5xl tracking-normal select-text text-foreground/70",
23061
23303
  children: [
23062
23304
  {
23063
- icon: o$3,
23305
+ icon: DouyinLikeIcon,
23064
23306
  value: dianzan,
23065
23307
  label: "点赞"
23066
23308
  },
23067
23309
  {
23068
- icon: t,
23310
+ icon: DouyinCommentIcon,
23069
23311
  value: pinglun,
23070
23312
  label: "评论"
23071
23313
  },
23072
23314
  {
23073
- icon: r,
23315
+ icon: DouyinFavoriteIcon,
23074
23316
  value: shouchang,
23075
23317
  label: "收藏"
23076
23318
  },
23077
23319
  {
23078
- icon: e$1,
23320
+ icon: DouyinShareIcon,
23079
23321
  value: share,
23080
23322
  label: "分享"
23081
23323
  }
@@ -23085,7 +23327,7 @@ var DouyinDynamicStatus = (props) => {
23085
23327
  className: "flex gap-2 items-end",
23086
23328
  children: [
23087
23329
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Icon, {
23088
- size: 50,
23330
+ size: 46,
23089
23331
  weight: "fill",
23090
23332
  className: "mt-2"
23091
23333
  }),
@@ -23245,19 +23487,19 @@ var DouyinDynamicFooter = (props) => {
23245
23487
  className: "text-3xl flex gap-6 items-center text-foreground/70",
23246
23488
  children: [
23247
23489
  {
23248
- icon: o$3,
23490
+ icon: DouyinLikeIcon,
23249
23491
  iconSize: 36,
23250
23492
  label: "获赞",
23251
23493
  value: 获赞
23252
23494
  },
23253
23495
  {
23254
- icon: o$4,
23496
+ icon: o$3,
23255
23497
  iconSize: 36,
23256
23498
  label: "关注",
23257
23499
  value: 关注
23258
23500
  },
23259
23501
  {
23260
- icon: r$1,
23502
+ icon: r,
23261
23503
  iconSize: 36,
23262
23504
  label: "粉丝",
23263
23505
  value: 粉丝
@@ -25266,10 +25508,11 @@ var convertAnsiToHtml = (text) => {
25266
25508
  let currentStyles = { classes: [] };
25267
25509
  let match;
25268
25510
  const escapeHtml = (str) => str.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&#039;");
25511
+ const formatLogContent = (content) => escapeHtml(content).replace(/([\u3400-\u9fff\uf900-\ufaff\u3000-\u303f\uff00-\uffef]+)/g, "<span class=\"font-[HarmonyOSHans-Regular]\">$1</span>");
25269
25512
  const makeSpan = (content) => {
25270
25513
  const hasClass = currentStyles.classes.length > 0, hasInline = currentStyles.inlineColor;
25271
- if (!hasClass && !hasInline) return escapeHtml(content);
25272
- return `<span${hasClass ? ` class="${currentStyles.classes.join(" ")}"` : ""}${hasInline ? ` style="color: ${currentStyles.inlineColor}"` : ""}>${escapeHtml(content)}</span>`;
25514
+ if (!hasClass && !hasInline) return formatLogContent(content);
25515
+ return `<span${hasClass ? ` class="${currentStyles.classes.join(" ")}"` : ""}${hasInline ? ` style="color: ${currentStyles.inlineColor}"` : ""}>${formatLogContent(content)}</span>`;
25273
25516
  };
25274
25517
  while ((match = ansiRegex.exec(text)) !== null) {
25275
25518
  if (match.index > lastIndex) result += makeSpan(text.substring(lastIndex, match.index));
@@ -32592,7 +32835,7 @@ var webConfig = defineConfig({
32592
32835
  }]
32593
32836
  },
32594
32837
  page: {
32595
- url: process.env.NODE_ENV === "development" ? "http://192.168.1.8:5176/kkk/assets/karin-config" : "/kkk/assets/karin-config",
32838
+ url: process.env.NODE_ENV === "development" ? "http://localhost:5176/kkk/assets/karin-config" : "/kkk/assets/karin-config",
32596
32839
  title: "kkk插件配置管理",
32597
32840
  description: "使用 kkk 插件自带的配置管理页面"
32598
32841
  }