@michengai/dsh-im-connect 1.0.23 → 1.0.24
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 +4 -0
- package/CHANGELOG.zh-CN.md +4 -0
- package/client.js +44 -0
- package/lib/client.js +44 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 1.0.24 - 2026-11-03
|
|
4
|
+
|
|
5
|
+
- Integrate official native settings navigation icon slot: present dedicated instant messaging vector icon on newer hosts while maintaining graceful compatibility with older hosts to prevent dual icons.
|
|
6
|
+
|
|
3
7
|
## 1.0.23 - 2026-11-03
|
|
4
8
|
|
|
5
9
|
- Fix Telegram status emoji reactions not appearing on incoming messages (#55, PR #56): when sending messages to the Telegram bot, original messages now properly show status reactions (👀 processing / 🤔 waiting / 👍 finished / 👎 failed) as the assistant makes progress, resolving an issue where reaction updates were silently swallowed due to targeting event cursors instead of user message IDs.
|
package/CHANGELOG.zh-CN.md
CHANGED
|
@@ -4,6 +4,10 @@
|
|
|
4
4
|
|
|
5
5
|
以下记录近期发布的版本。Git 标签与 GitHub Release 现已和这些条目同步;历史条目继续保留原始发布提交链接。
|
|
6
6
|
|
|
7
|
+
## 1.0.24 - 2026-11-03
|
|
8
|
+
|
|
9
|
+
- 接入官方原生设置导航图标插槽:在 DSH 新版设置页中呈现专属即时通信矢量图标,并精准兼容老版宿主,彻底避免双图标重叠问题。
|
|
10
|
+
|
|
7
11
|
## 1.0.23 - 2026-11-03
|
|
8
12
|
|
|
9
13
|
- 修复 Telegram 消息状态表情无法显示的问题(#55,PR #56):给 Telegram 机器人发送消息后,原消息能正常显示「👀 思考中 / 🤔 等待确认 / 👍 已完成 / 👎 失败」等状态表情;此前因目标消息识别偏差导致表情更新一直被静默忽略。
|
package/client.js
CHANGED
|
@@ -4315,6 +4315,17 @@ window.__ModuleLoader__.load({
|
|
|
4315
4315
|
function applySettingsNavIcon(button, wantedLabel) {
|
|
4316
4316
|
const isOwn = isOwnNavRow(getNavButtonText(button), typeof wantedLabel === "function" ? wantedLabel() : wantedLabel);
|
|
4317
4317
|
if (isOwn) {
|
|
4318
|
+
const hasSlotIcon = Array.from((button && button.children) || []).some((child) =>
|
|
4319
|
+
child.tagName === "SPAN" &&
|
|
4320
|
+
((child.className && String(child.className).includes("navIcon")) || (typeof child.getAttribute === "function" && child.getAttribute("aria-hidden") === "true"))
|
|
4321
|
+
) || Boolean(button && typeof button.querySelector === "function" && button.querySelector('[class*="navIcon"]'));
|
|
4322
|
+
if (hasSlotIcon) {
|
|
4323
|
+
if (button.hasAttribute(NAV_ICON_MARKER)) {
|
|
4324
|
+
button.removeAttribute(NAV_ICON_MARKER);
|
|
4325
|
+
return true;
|
|
4326
|
+
}
|
|
4327
|
+
return false;
|
|
4328
|
+
}
|
|
4318
4329
|
if (button.getAttribute(NAV_ICON_MARKER) === "") return false;
|
|
4319
4330
|
button.setAttribute(NAV_ICON_MARKER, "");
|
|
4320
4331
|
return true;
|
|
@@ -4371,9 +4382,38 @@ window.__ModuleLoader__.load({
|
|
|
4371
4382
|
|
|
4372
4383
|
installSettingsNavIcon(ctx, () => t("settings.label"));
|
|
4373
4384
|
|
|
4385
|
+
function ImNavIcon({ size = 16 }) {
|
|
4386
|
+
return React.createElement(
|
|
4387
|
+
"svg",
|
|
4388
|
+
{
|
|
4389
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
4390
|
+
viewBox: "0 0 16 16",
|
|
4391
|
+
width: size,
|
|
4392
|
+
height: size,
|
|
4393
|
+
fill: "none",
|
|
4394
|
+
stroke: "currentColor",
|
|
4395
|
+
strokeWidth: 1.3,
|
|
4396
|
+
strokeLinecap: "round",
|
|
4397
|
+
strokeLinejoin: "round",
|
|
4398
|
+
},
|
|
4399
|
+
React.createElement("path", { d: "M5 6.75H11" }),
|
|
4400
|
+
React.createElement("path", { d: "M5 9H8" }),
|
|
4401
|
+
React.createElement("path", { d: "M2.37067 11.2497C1.5872 9.89252 1.32042 8.29798 1.61945 6.7597C1.91847 5.22141 2.76317 3.84293 3.99801 2.87809C5.23285 1.91325 6.7747 1.427 8.33964 1.50888C9.90458 1.59076 11.3873 2.23526 12.5147 3.32369C13.6422 4.41232 14.3384 5.8717 14.4751 7.43304C14.6118 8.99438 14.1797 10.5525 13.2585 11.8205C12.3372 13.0885 10.9889 13.9809 9.4617 14.3334C8.18666 14.6277 6.8587 14.529 5.64964 14.0601C5.17095 13.8745 4.76937 13.4929 4.26509 13.3963C3.67389 13.2832 2.95232 13.5595 2.0377 14.3334" }),
|
|
4402
|
+
);
|
|
4403
|
+
}
|
|
4404
|
+
|
|
4374
4405
|
let unregSettings = null;
|
|
4406
|
+
let unregSettingsIcon = null;
|
|
4375
4407
|
const mountSettingsSection = () => {
|
|
4376
4408
|
if (unregSettings) return;
|
|
4409
|
+
try {
|
|
4410
|
+
const iconRes = ctx.slots.register({
|
|
4411
|
+
name: "settings.section.icon",
|
|
4412
|
+
id: "im-assistant",
|
|
4413
|
+
locale: IM_LOCALE_NS,
|
|
4414
|
+
}, ImNavIcon);
|
|
4415
|
+
unregSettingsIcon = typeof iconRes === "function" ? iconRes : () => {};
|
|
4416
|
+
} catch {}
|
|
4377
4417
|
const res = (ctx.slots.register({
|
|
4378
4418
|
name: "settings.section",
|
|
4379
4419
|
id: "im-assistant",
|
|
@@ -4393,6 +4433,10 @@ window.__ModuleLoader__.load({
|
|
|
4393
4433
|
};
|
|
4394
4434
|
|
|
4395
4435
|
const unmountSettingsSection = () => {
|
|
4436
|
+
if (unregSettingsIcon) {
|
|
4437
|
+
try { unregSettingsIcon(); } catch {}
|
|
4438
|
+
unregSettingsIcon = null;
|
|
4439
|
+
}
|
|
4396
4440
|
if (!unregSettings) return;
|
|
4397
4441
|
try { unregSettings(); } catch {}
|
|
4398
4442
|
unregSettings = null;
|
package/lib/client.js
CHANGED
|
@@ -4717,6 +4717,17 @@ function observePluginUpdate(options) {
|
|
|
4717
4717
|
function applySettingsNavIcon(button, wantedLabel) {
|
|
4718
4718
|
const isOwn = isOwnNavRow(getNavButtonText(button), typeof wantedLabel === "function" ? wantedLabel() : wantedLabel);
|
|
4719
4719
|
if (isOwn) {
|
|
4720
|
+
const hasSlotIcon = Array.from((button && button.children) || []).some((child) =>
|
|
4721
|
+
child.tagName === "SPAN" &&
|
|
4722
|
+
((child.className && String(child.className).includes("navIcon")) || (typeof child.getAttribute === "function" && child.getAttribute("aria-hidden") === "true"))
|
|
4723
|
+
) || Boolean(button && typeof button.querySelector === "function" && button.querySelector('[class*="navIcon"]'));
|
|
4724
|
+
if (hasSlotIcon) {
|
|
4725
|
+
if (button.hasAttribute(NAV_ICON_MARKER)) {
|
|
4726
|
+
button.removeAttribute(NAV_ICON_MARKER);
|
|
4727
|
+
return true;
|
|
4728
|
+
}
|
|
4729
|
+
return false;
|
|
4730
|
+
}
|
|
4720
4731
|
if (button.getAttribute(NAV_ICON_MARKER) === "") return false;
|
|
4721
4732
|
button.setAttribute(NAV_ICON_MARKER, "");
|
|
4722
4733
|
return true;
|
|
@@ -4773,9 +4784,38 @@ function observePluginUpdate(options) {
|
|
|
4773
4784
|
|
|
4774
4785
|
installSettingsNavIcon(ctx, () => t("settings.label"));
|
|
4775
4786
|
|
|
4787
|
+
function ImNavIcon({ size = 16 }) {
|
|
4788
|
+
return React.createElement(
|
|
4789
|
+
"svg",
|
|
4790
|
+
{
|
|
4791
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
4792
|
+
viewBox: "0 0 16 16",
|
|
4793
|
+
width: size,
|
|
4794
|
+
height: size,
|
|
4795
|
+
fill: "none",
|
|
4796
|
+
stroke: "currentColor",
|
|
4797
|
+
strokeWidth: 1.3,
|
|
4798
|
+
strokeLinecap: "round",
|
|
4799
|
+
strokeLinejoin: "round",
|
|
4800
|
+
},
|
|
4801
|
+
React.createElement("path", { d: "M5 6.75H11" }),
|
|
4802
|
+
React.createElement("path", { d: "M5 9H8" }),
|
|
4803
|
+
React.createElement("path", { d: "M2.37067 11.2497C1.5872 9.89252 1.32042 8.29798 1.61945 6.7597C1.91847 5.22141 2.76317 3.84293 3.99801 2.87809C5.23285 1.91325 6.7747 1.427 8.33964 1.50888C9.90458 1.59076 11.3873 2.23526 12.5147 3.32369C13.6422 4.41232 14.3384 5.8717 14.4751 7.43304C14.6118 8.99438 14.1797 10.5525 13.2585 11.8205C12.3372 13.0885 10.9889 13.9809 9.4617 14.3334C8.18666 14.6277 6.8587 14.529 5.64964 14.0601C5.17095 13.8745 4.76937 13.4929 4.26509 13.3963C3.67389 13.2832 2.95232 13.5595 2.0377 14.3334" }),
|
|
4804
|
+
);
|
|
4805
|
+
}
|
|
4806
|
+
|
|
4776
4807
|
let unregSettings = null;
|
|
4808
|
+
let unregSettingsIcon = null;
|
|
4777
4809
|
const mountSettingsSection = () => {
|
|
4778
4810
|
if (unregSettings) return;
|
|
4811
|
+
try {
|
|
4812
|
+
const iconRes = ctx.slots.register({
|
|
4813
|
+
name: "settings.section.icon",
|
|
4814
|
+
id: "im-assistant",
|
|
4815
|
+
locale: IM_LOCALE_NS,
|
|
4816
|
+
}, ImNavIcon);
|
|
4817
|
+
unregSettingsIcon = typeof iconRes === "function" ? iconRes : () => {};
|
|
4818
|
+
} catch {}
|
|
4779
4819
|
const res = (ctx.slots.register({
|
|
4780
4820
|
name: "settings.section",
|
|
4781
4821
|
id: "im-assistant",
|
|
@@ -4795,6 +4835,10 @@ function observePluginUpdate(options) {
|
|
|
4795
4835
|
};
|
|
4796
4836
|
|
|
4797
4837
|
const unmountSettingsSection = () => {
|
|
4838
|
+
if (unregSettingsIcon) {
|
|
4839
|
+
try { unregSettingsIcon(); } catch {}
|
|
4840
|
+
unregSettingsIcon = null;
|
|
4841
|
+
}
|
|
4798
4842
|
if (!unregSettings) return;
|
|
4799
4843
|
try { unregSettings(); } catch {}
|
|
4800
4844
|
unregSettings = null;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@michengai/dsh-im-connect",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.24",
|
|
4
4
|
"description": "DSH IM Connect — 将主流即时通讯平台接入本机 DeepSeek Harness · Connect major messaging platforms to local DeepSeek Harness agents",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"packageManager": "pnpm@11.22.0",
|