karin-plugin-kkk 2.45.2 → 2.45.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,13 @@
2
2
 
3
3
  # Changelog
4
4
 
5
+ ## [2.45.3](https://github.com/ikenxuan/karin-plugin-kkk/compare/v2.45.2...v2.45.3) (2026-11-11)
6
+
7
+
8
+ ### 🧰 其他更新
9
+
10
+ * 更新命令正则,支持「#订阅xx推送」 ([b342faa](https://github.com/ikenxuan/karin-plugin-kkk/commit/b342faa0b074ebe775feeac50abdc65474b0bed7))
11
+
5
12
  ## [2.45.2](https://github.com/ikenxuan/karin-plugin-kkk/compare/v2.45.1...v2.45.2) (2026-10-30)
6
13
 
7
14
 
@@ -1,10 +1,10 @@
1
1
  {
2
- "version": "2.45.2",
3
- "buildTime": "2026-10-30T08:40:41.138Z",
4
- "buildTimestamp": 1793349641139,
2
+ "version": "2.45.3",
3
+ "buildTime": "2026-11-11T13:06:50.218Z",
4
+ "buildTimestamp": 1794402410218,
5
5
  "name": "karin-plugin-kkk",
6
6
  "description": "Karin 的「抖音」「B 站」视频解析/动态推送插件",
7
7
  "homepage": "https://github.com/ikenxuan/karin-plugin-kkk",
8
- "commitHash": "08627f1081567933c82aad2fe5f7b75095687520",
9
- "shortCommitHash": "08627f10"
8
+ "commitHash": "e97c1c8b6da19d6e8159f2314ab2c87e888c265e",
9
+ "shortCommitHash": "e97c1c8b"
10
10
  }
@@ -12002,14 +12002,18 @@ var parseCredits = (raw) => {
12002
12002
  voiceCount: (/* @__PURE__ */ new Set([...cast.map((item) => item.actor), ...extras])).size
12003
12003
  };
12004
12004
  };
12005
+ /** staff 上游偶尔缺换行,把下一个职务粘在公司名后面(如「SUNRISE舞台设定」),截掉常见职务后缀 */
12006
+ var GLUED_STAFF_ROLE = /(总作画监督|作画监督|美术监督|摄影监督|音响监督|系列构成|舞台设定|人物设定|角色设定|人物设计|角色设计|色彩设计|制作人|制片人|监督|导演|脚本|编剧|分镜|演出|编集|编辑|企划|设定|设计)$/;
12005
12007
  /** 版权番剧没有 up_info 时,从制作人员里取制作公司:优先「动画制作」,其次「制作/製作」 */
12006
12008
  var parseMaker = (raw) => {
12007
12009
  let fallback = "";
12008
12010
  for (const line of (raw || "").split(/\r?\n/)) {
12009
12011
  const match = /^\s*(动画制作公司|动画制作|制作公司|制作|製作)[::]\s*(.+?)\s*$/.exec(line);
12010
12012
  if (!match) continue;
12011
- if (/动画制作/.test(match[1])) return match[2];
12012
- if (!fallback) fallback = match[2];
12013
+ const name = match[2].replace(GLUED_STAFF_ROLE, "").trim();
12014
+ if (!name) continue;
12015
+ if (/动画制作/.test(match[1])) return name;
12016
+ if (!fallback) fallback = name;
12013
12017
  }
12014
12018
  return fallback;
12015
12019
  };
@@ -39761,7 +39765,7 @@ var DouYinpush = class extends Base {
39761
39765
  const groupId = "groupId" in this.e && this.e.groupId ? this.e.groupId : "";
39762
39766
  const botId = this.e.selfId;
39763
39767
  try {
39764
- const inputDouyinId = this.e.msg.replace(/^#设置抖音推送/, "").trim();
39768
+ const inputDouyinId = this.e.msg.replace(/^#(?:设置|订阅)抖音推送/, "").trim();
39765
39769
  /** 处理抖音号 */
39766
39770
  const user_shortid = data.user_info.unique_id === "" ? data.user_info.short_id : data.user_info.unique_id;
39767
39771
  const sec_uid = data.user_info.sec_uid;
@@ -41676,12 +41680,12 @@ var HELP_MENU_CONFIG = [
41676
41680
  subGroups: [{
41677
41681
  title: "在群聊中再发送一次即可取消订阅",
41678
41682
  items: [{
41679
- title: "#设置抖音推送 + 抖音号",
41683
+ title: "#设置/订阅抖音推送 + 抖音号",
41680
41684
  description: "在群聊中发送以对该群订阅该抖音博主的作品更新",
41681
41685
  icon: "ph:bell-fill",
41682
41686
  roles: Config.douyin.push.permission === "all" ? ["member", "master"] : ["master"]
41683
41687
  }, {
41684
- title: "#设置B站推送 + UP主UID",
41688
+ title: "#设置/订阅B站推送 + UID",
41685
41689
  description: "在群聊中发送以对该群订阅该B站UP主的稿件/动态更新",
41686
41690
  icon: "ph:bell-fill",
41687
41691
  roles: Config.bilibili.push.permission === "all" ? ["member", "master"] : ["master"]
@@ -41812,7 +41816,7 @@ var handleForcePush = wrapWithErrorHandler(async (e) => {
41812
41816
  return true;
41813
41817
  }, { businessName: "强制推送" });
41814
41818
  var handleSetDouyinPush = wrapWithErrorHandler(async (e) => {
41815
- const query = e.msg.replace(/^#设置抖音推送/, "").trim();
41819
+ const query = e.msg.replace(/^#(?:设置|订阅)抖音推送/, "").trim();
41816
41820
  if (query === "开启" || query === "关闭") {
41817
41821
  const enable = query === "开启";
41818
41822
  Config.Modify("douyin", "push.switch", enable);
@@ -41825,7 +41829,7 @@ var handleSetDouyinPush = wrapWithErrorHandler(async (e) => {
41825
41829
  return true;
41826
41830
  }, { businessName: "设置抖音推送" });
41827
41831
  var handleSetBilibiliPush = wrapWithErrorHandler(async (e) => {
41828
- const query = e.msg.replace(/^#设置[bB]站推送/, "").replace(/^(?:[Uu][Ii][Dd]:)?/, "").trim();
41832
+ const query = e.msg.replace(/^#(?:设置|订阅)[bB]站推送/, "").replace(/^(?:[Uu][Ii][Dd]:)?/, "").trim();
41829
41833
  if (query === "开启" || query === "关闭") {
41830
41834
  const enable = query === "开启";
41831
41835
  Config.Modify("bilibili", "push.switch", enable);
@@ -41923,12 +41927,12 @@ var forcePush = karin.command(/#(抖音|B站)(全部)?强制推送/, handleForce
41923
41927
  perm: "master",
41924
41928
  event: "message.group"
41925
41929
  });
41926
- var setdyPush = karin.command(/^#设置抖音推送/, handleSetDouyinPush, {
41930
+ var setdyPush = karin.command(/^#(?:设置|订阅)抖音推送/, handleSetDouyinPush, {
41927
41931
  name: "kkk-推送功能-设置",
41928
41932
  event: "message.group",
41929
41933
  perm: Config.douyin.push.permission
41930
41934
  });
41931
- var setbiliPush = karin.command(/^#设置[bB]站推送/, handleSetBilibiliPush, {
41935
+ var setbiliPush = karin.command(/^#(?:设置|订阅)[bB]站推送/, handleSetBilibiliPush, {
41932
41936
  name: "kkk-推送功能-设置",
41933
41937
  event: "message.group",
41934
41938
  perm: Config.bilibili.push.permission
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "karin-plugin-kkk",
3
- "version": "2.45.2",
3
+ "version": "2.45.3",
4
4
  "description": "Karin 的「抖音」「B 站」视频解析/动态推送插件",
5
5
  "keywords": [
6
6
  "karin",
@@ -83,7 +83,7 @@
83
83
  "@lobehub/webfont-harmony-sans-sc": "^1.0.0",
84
84
  "emoji-datasource-apple": "16.0.0"
85
85
  },
86
- "timestamp": "2026-10-30T08:39:28.264Z",
86
+ "timestamp": "2026-11-11T13:06:11.606Z",
87
87
  "engines": {
88
88
  "node": ">=18.0.0"
89
89
  }