dsh-side-chat-plus 0.4.2 → 0.4.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 +19 -0
- package/README.md +3 -3
- package/README.zh.md +3 -3
- package/dsh.plugin.json +1 -1
- package/lib/client-registry.js +102 -92
- package/lib/client-registry.js.map +1 -1
- package/lib/client.js +105 -95
- package/lib/client.js.map +1 -1
- package/lib/index.js +27 -16
- package/package.json +20 -20
- package/src/client/index.tsx +25 -3
- package/src/index.ts +24 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,22 @@
|
|
|
1
|
+
# 0.4.3
|
|
2
|
+
|
|
3
|
+
- 对照 DSH `0.1.7-rc.1` 做了一轮完整功能回归:宿主侧 `/sidechat/api` 的 start / followup / stop /
|
|
4
|
+
history / list / state / commands / summarize / inject / attachment / selectModel /
|
|
5
|
+
selectPermission / settings.get / settings.update / dispose 全部实测通过;「推理期间临时取消归档、
|
|
6
|
+
本轮结束恢复归档」的门禁流程在 rc.1 上仍按要求工作(侧边会话不出现在会话列表)。
|
|
7
|
+
- 修复「右侧栏服务缺失时侧边聊天彻底不可用」:默认偏好是停靠新版右侧栏,但部署里没有
|
|
8
|
+
`sidebarRight` / `sidebarRightTabs` 服务时,此前只写一条“已回退为浮动面板”的错误提示,既不注册
|
|
9
|
+
停靠入口、也不渲染浮动面板——而提示本身就在面板里,用户什么也看不到。现在真的回退到经典浮动
|
|
10
|
+
面板,提示只用于解释停靠偏好为何未生效。
|
|
11
|
+
- 修复「启动失败会留下幽灵侧边聊天」:`sidechat.start` 原先先创建并持久化侧边会话、再校验提示里的
|
|
12
|
+
图片,图片被拒时既返回 500,又留下一个没有任何消息的侧边聊天(写入记录,之后还会被复用)。
|
|
13
|
+
现在图片在创建会话之前处理,失败返回 400 `bad-image`,且不创建任何会话。
|
|
14
|
+
- `sidechat.history` 对不存在或已删除的侧边聊天返回 404 `not-found`,不再把这种正常的客户端缺席
|
|
15
|
+
报成 500 `internal`。
|
|
16
|
+
- 开发依赖与 CI 对齐到 `0.1.7-rc.1`(此前 `0.1.7-alpha.1`);typecheck、构建(含
|
|
17
|
+
`check-seed-exports` 对真实 DSH 安装的校验)与测试均在 rc.1 类型下通过。
|
|
18
|
+
- 新增 3 条回归测试:图片被拒不留会话且 list 为空、history 返回 404、合法图片仍能正常启动。
|
|
19
|
+
|
|
1
20
|
# 0.4.2
|
|
2
21
|
|
|
3
22
|
- 0.4.1 被 CI 从「修复提交之前」的提交打包发布(tag 先指向旧提交、随后才被强制更新),因此 npm 上的 0.4.1
|
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# dsh-side-chat — 侧边聊天 (Side chat)
|
|
2
2
|
|
|
3
|
-
Targets DSH **0.1.7-
|
|
3
|
+
Targets DSH **0.1.7-rc.1**. See [compatibility changes](CHANGELOG.md).
|
|
4
4
|
|
|
5
5
|
An **enhanced version of a Codex-style side chat** for
|
|
6
6
|
[DSH](https://www.deepseek.com): a dedicated, agentic chat in a right-side
|
|
@@ -106,7 +106,7 @@ and you never have to answer before you're ready.
|
|
|
106
106
|
|
|
107
107
|
- [Node.js](https://nodejs.org) ≥ 20
|
|
108
108
|
- [pnpm](https://pnpm.io)
|
|
109
|
-
- DSH `0.1.7-
|
|
109
|
+
- DSH `0.1.7-rc.1` (`^0.1.7-0`).
|
|
110
110
|
- `pnpm build` ends with `check-seed-exports`, which compares the client
|
|
111
111
|
bundle's frozen-module-table imports against a real DSH install. Set
|
|
112
112
|
`DSH_INSTALL` (or pass `--shell`) when the install is not discoverable via
|
|
@@ -139,7 +139,7 @@ The package name is `dsh-side-chat-plus` (the plain `dsh-side-chat` name on npm
|
|
|
139
139
|
belongs to a different maintainer, so the release is published under the
|
|
140
140
|
`-plus` name).
|
|
141
141
|
|
|
142
|
-
> **Registry dependencies.** Local and CI builds use exact DSH `0.1.7-
|
|
142
|
+
> **Registry dependencies.** Local and CI builds use exact DSH `0.1.7-rc.1` development dependencies and the checked-in lockfile. No local harness checkout or CI-only overrides are required.
|
|
143
143
|
|
|
144
144
|
## Deploy
|
|
145
145
|
|
package/README.zh.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# dsh-side-chat — 侧边聊天(Side chat)
|
|
2
2
|
|
|
3
|
-
当前适配 DSH **0.1.7-
|
|
3
|
+
当前适配 DSH **0.1.7-rc.1**,详见[兼容性变更](CHANGELOG.md)。
|
|
4
4
|
|
|
5
5
|
一个 [DSH](https://www.deepseek.com) 网页插件,**Codex 式侧边聊天的强化版本**:
|
|
6
6
|
在右侧面板提供按主会话隔离的独立聊天,具备 Codex 式的智能体能力——继承主会话的
|
|
@@ -71,7 +71,7 @@ Codex 式能力之上,额外支持针对当前**问题弹框**的侧边聊天
|
|
|
71
71
|
|
|
72
72
|
- [Node.js](https://nodejs.org) ≥ 20
|
|
73
73
|
- [pnpm](https://pnpm.io)
|
|
74
|
-
- DSH `0.1.7-
|
|
74
|
+
- DSH `0.1.7-rc.1` (`^0.1.7-0`).
|
|
75
75
|
- `pnpm build` 最后会跑 `check-seed-exports`:把客户端 bundle 对冻结模块表的
|
|
76
76
|
引用与一份真实 DSH 安装做比对。若 `dsh` 不在 `PATH` 上而探测不到安装目录,
|
|
77
77
|
可设 `DSH_INSTALL`(或传 `--shell`);找不到目标时会跳过而不是失败。
|
|
@@ -99,7 +99,7 @@ pnpm build
|
|
|
99
99
|
|
|
100
100
|
包名为 `dsh-side-chat-plus`(npm 上的裸名 `dsh-side-chat` 属于另一维护者,因此发布以 `-plus` 命名)。
|
|
101
101
|
|
|
102
|
-
> **registry 依赖说明。** 本地和 CI 使用精确的 DSH `0.1.7-
|
|
102
|
+
> **registry 依赖说明。** 本地和 CI 使用精确的 DSH `0.1.7-rc.1` 开发依赖和同一份锁文件,无需本地 harness checkout 或 CI 专用 overrides。
|
|
103
103
|
|
|
104
104
|
## 部署
|
|
105
105
|
|
package/dsh.plugin.json
CHANGED
package/lib/client-registry.js
CHANGED
|
@@ -20,14 +20,14 @@ window.__ModuleLoader__.load({
|
|
|
20
20
|
document.head.appendChild(tag);
|
|
21
21
|
}
|
|
22
22
|
var AttachmentRail_module_css_default = {
|
|
23
|
-
"root": "J5tleW_root",
|
|
24
|
-
"rail": "J5tleW_rail",
|
|
25
|
-
"thumbnail": "J5tleW_thumbnail",
|
|
26
23
|
"item": "J5tleW_item",
|
|
27
24
|
"arrow": "J5tleW_arrow",
|
|
25
|
+
"thumbnail": "J5tleW_thumbnail",
|
|
28
26
|
"arrowRight": "J5tleW_arrowRight",
|
|
27
|
+
"root": "J5tleW_root",
|
|
29
28
|
"arrowLeft": "J5tleW_arrowLeft",
|
|
30
|
-
"remove": "J5tleW_remove"
|
|
29
|
+
"remove": "J5tleW_remove",
|
|
30
|
+
"rail": "J5tleW_rail"
|
|
31
31
|
};
|
|
32
32
|
//#endregion
|
|
33
33
|
//#region src/client/attachments/AttachmentRail.tsx
|
|
@@ -173,11 +173,11 @@ window.__ModuleLoader__.load({
|
|
|
173
173
|
document.head.appendChild(tag);
|
|
174
174
|
}
|
|
175
175
|
var DropOverlay_module_css_default = {
|
|
176
|
-
"
|
|
177
|
-
"title": "_9H6qrq_title",
|
|
178
|
-
"wrap": "_9H6qrq_wrap",
|
|
176
|
+
"illustration": "_9H6qrq_illustration",
|
|
179
177
|
"desc": "_9H6qrq_desc",
|
|
180
|
-
"
|
|
178
|
+
"title": "_9H6qrq_title",
|
|
179
|
+
"mask": "_9H6qrq_mask",
|
|
180
|
+
"wrap": "_9H6qrq_wrap"
|
|
181
181
|
};
|
|
182
182
|
//#endregion
|
|
183
183
|
//#region src/client/attachments/DropOverlay.tsx
|
|
@@ -322,8 +322,8 @@ window.__ModuleLoader__.load({
|
|
|
322
322
|
var ImageLightbox_module_css_default = {
|
|
323
323
|
"backdrop": "_5IyjUq_backdrop",
|
|
324
324
|
"close": "_5IyjUq_close",
|
|
325
|
-
"
|
|
326
|
-
"
|
|
325
|
+
"mask": "_5IyjUq_mask",
|
|
326
|
+
"image": "_5IyjUq_image"
|
|
327
327
|
};
|
|
328
328
|
//#endregion
|
|
329
329
|
//#region src/client/attachments/ImageLightbox.tsx
|
|
@@ -389,8 +389,8 @@ window.__ModuleLoader__.load({
|
|
|
389
389
|
}
|
|
390
390
|
var MessageImage_module_css_default = {
|
|
391
391
|
"gallery": "_1H6WSq_gallery",
|
|
392
|
-
"error": "_1H6WSq_error",
|
|
393
392
|
"frame": "_1H6WSq_frame",
|
|
393
|
+
"error": "_1H6WSq_error",
|
|
394
394
|
"loading": "_1H6WSq_loading"
|
|
395
395
|
};
|
|
396
396
|
//#endregion
|
|
@@ -760,101 +760,101 @@ window.__ModuleLoader__.load({
|
|
|
760
760
|
document.head.appendChild(tag);
|
|
761
761
|
}
|
|
762
762
|
var client_module_css_default = {
|
|
763
|
-
"
|
|
764
|
-
"
|
|
765
|
-
"
|
|
766
|
-
"
|
|
767
|
-
"
|
|
768
|
-
"panelListItemRemove": "yw4T5a_panelListItemRemove",
|
|
769
|
-
"panelListItemLabel": "yw4T5a_panelListItemLabel",
|
|
770
|
-
"messageUser": "yw4T5a_messageUser",
|
|
771
|
-
"modelSelectLabel": "yw4T5a_modelSelectLabel",
|
|
772
|
-
"panelComposer": "yw4T5a_panelComposer",
|
|
773
|
-
"settingsBringOption": "yw4T5a_settingsBringOption",
|
|
774
|
-
"modelSelectMenu": "yw4T5a_modelSelectMenu",
|
|
775
|
-
"panelListItemDot": "yw4T5a_panelListItemDot",
|
|
776
|
-
"modelCheck": "yw4T5a_modelCheck",
|
|
777
|
-
"panelIconButton": "yw4T5a_panelIconButton",
|
|
778
|
-
"questionOptionDesc": "yw4T5a_questionOptionDesc",
|
|
779
|
-
"chevronOpen": "yw4T5a_chevronOpen",
|
|
780
|
-
"questionDetail": "yw4T5a_questionDetail",
|
|
781
|
-
"questionFab": "yw4T5a_questionFab",
|
|
782
|
-
"questionHeaderActions": "yw4T5a_questionHeaderActions",
|
|
763
|
+
"panelResize": "yw4T5a_panelResize",
|
|
764
|
+
"modelCellValue": "yw4T5a_modelCellValue",
|
|
765
|
+
"panelClose": "yw4T5a_panelClose",
|
|
766
|
+
"questionOption": "yw4T5a_questionOption",
|
|
767
|
+
"questionDelete": "yw4T5a_questionDelete",
|
|
783
768
|
"reasoningSummary": "yw4T5a_reasoningSummary",
|
|
784
|
-
"
|
|
785
|
-
"
|
|
786
|
-
"
|
|
787
|
-
"
|
|
769
|
+
"modelCheck": "yw4T5a_modelCheck",
|
|
770
|
+
"settingsToggle": "yw4T5a_settingsToggle",
|
|
771
|
+
"modelEmpty": "yw4T5a_modelEmpty",
|
|
772
|
+
"messageUserText": "yw4T5a_messageUserText",
|
|
773
|
+
"messageAssistant": "yw4T5a_messageAssistant",
|
|
774
|
+
"panelAttachment": "yw4T5a_panelAttachment",
|
|
788
775
|
"modelGroupTitle": "yw4T5a_modelGroupTitle",
|
|
789
|
-
"
|
|
790
|
-
"panelListActions": "yw4T5a_panelListActions",
|
|
791
|
-
"panelRunningPulse": "yw4T5a_panelRunningPulse",
|
|
792
|
-
"collapsedHandle": "yw4T5a_collapsedHandle",
|
|
776
|
+
"panelRunningClock": "yw4T5a_panelRunningClock",
|
|
793
777
|
"modelGroup": "yw4T5a_modelGroup",
|
|
794
|
-
"
|
|
795
|
-
"
|
|
796
|
-
"modelOption": "yw4T5a_modelOption",
|
|
797
|
-
"modelDescription": "yw4T5a_modelDescription",
|
|
778
|
+
"questionToggle": "yw4T5a_questionToggle",
|
|
779
|
+
"modelOptionCopy": "yw4T5a_modelOptionCopy",
|
|
798
780
|
"modelSelect": "yw4T5a_modelSelect",
|
|
799
|
-
"
|
|
781
|
+
"questionHeaderText": "yw4T5a_questionHeaderText",
|
|
782
|
+
"modelDescription": "yw4T5a_modelDescription",
|
|
783
|
+
"settingsRowText": "yw4T5a_settingsRowText",
|
|
784
|
+
"settingsBringOption": "yw4T5a_settingsBringOption",
|
|
785
|
+
"questionDetail": "yw4T5a_questionDetail",
|
|
786
|
+
"modelCellLabel": "yw4T5a_modelCellLabel",
|
|
787
|
+
"settingsSection": "yw4T5a_settingsSection",
|
|
800
788
|
"settingsBringOptionActive": "yw4T5a_settingsBringOptionActive",
|
|
801
|
-
"
|
|
802
|
-
"questionBlock": "yw4T5a_questionBlock",
|
|
803
|
-
"modelOptionCopy": "yw4T5a_modelOptionCopy",
|
|
804
|
-
"settingsPromptInput": "yw4T5a_settingsPromptInput",
|
|
805
|
-
"questionOption": "yw4T5a_questionOption",
|
|
806
|
-
"messageActions": "yw4T5a_messageActions",
|
|
807
|
-
"panelFooter": "yw4T5a_panelFooter",
|
|
808
|
-
"modelCell": "yw4T5a_modelCell",
|
|
809
|
-
"panelToolbar": "yw4T5a_panelToolbar",
|
|
810
|
-
"questionBlockActions": "yw4T5a_questionBlockActions",
|
|
811
|
-
"panelList": "yw4T5a_panelList",
|
|
812
|
-
"modelGroups": "yw4T5a_modelGroups",
|
|
789
|
+
"panelListItemRemove": "yw4T5a_panelListItemRemove",
|
|
813
790
|
"questionOptionLabel": "yw4T5a_questionOptionLabel",
|
|
814
|
-
"
|
|
815
|
-
"
|
|
816
|
-
"
|
|
791
|
+
"panelListItem": "yw4T5a_panelListItem",
|
|
792
|
+
"panelDispose": "yw4T5a_panelDispose",
|
|
793
|
+
"modelOption": "yw4T5a_modelOption",
|
|
794
|
+
"panelError": "yw4T5a_panelError",
|
|
817
795
|
"questionBody": "yw4T5a_questionBody",
|
|
818
|
-
"
|
|
819
|
-
"
|
|
820
|
-
"
|
|
821
|
-
"
|
|
822
|
-
"
|
|
823
|
-
"selectionMenu": "yw4T5a_selectionMenu",
|
|
824
|
-
"panelRunningClock": "yw4T5a_panelRunningClock",
|
|
825
|
-
"reasoningBody": "yw4T5a_reasoningBody",
|
|
826
|
-
"modelCellValue": "yw4T5a_modelCellValue",
|
|
827
|
-
"settingsRowDesc": "yw4T5a_settingsRowDesc",
|
|
796
|
+
"messageUser": "yw4T5a_messageUser",
|
|
797
|
+
"questionHeaderActions": "yw4T5a_questionHeaderActions",
|
|
798
|
+
"modelGroups": "yw4T5a_modelGroups",
|
|
799
|
+
"panelIconButton": "yw4T5a_panelIconButton",
|
|
800
|
+
"modelOptionSelected": "yw4T5a_modelOptionSelected",
|
|
828
801
|
"panelAttachmentRail": "yw4T5a_panelAttachmentRail",
|
|
829
|
-
"
|
|
830
|
-
"
|
|
831
|
-
"messageUserText": "yw4T5a_messageUserText",
|
|
802
|
+
"questionOptionText": "yw4T5a_questionOptionText",
|
|
803
|
+
"questionBlockActions": "yw4T5a_questionBlockActions",
|
|
832
804
|
"modelName": "yw4T5a_modelName",
|
|
833
|
-
"
|
|
834
|
-
"
|
|
835
|
-
"
|
|
836
|
-
"
|
|
837
|
-
"
|
|
805
|
+
"panelConflictHidden": "yw4T5a_panelConflictHidden",
|
|
806
|
+
"panelEmpty": "yw4T5a_panelEmpty",
|
|
807
|
+
"chevronOpen": "yw4T5a_chevronOpen",
|
|
808
|
+
"settingsRow": "yw4T5a_settingsRow",
|
|
809
|
+
"primary": "yw4T5a_primary",
|
|
810
|
+
"messageActions": "yw4T5a_messageActions",
|
|
811
|
+
"questionBringButton": "yw4T5a_questionBringButton",
|
|
812
|
+
"panelListActions": "yw4T5a_panelListActions",
|
|
813
|
+
"reasoningBody": "yw4T5a_reasoningBody",
|
|
814
|
+
"modelSelectMenu": "yw4T5a_modelSelectMenu",
|
|
815
|
+
"panelTextarea": "yw4T5a_panelTextarea",
|
|
816
|
+
"questionFab": "yw4T5a_questionFab",
|
|
817
|
+
"panelAttachmentRemove": "yw4T5a_panelAttachmentRemove",
|
|
838
818
|
"panelAttachmentText": "yw4T5a_panelAttachmentText",
|
|
839
819
|
"panelListItemRow": "yw4T5a_panelListItemRow",
|
|
840
|
-
"
|
|
820
|
+
"panelFooter": "yw4T5a_panelFooter",
|
|
821
|
+
"panelList": "yw4T5a_panelList",
|
|
822
|
+
"questionItemCollapsed": "yw4T5a_questionItemCollapsed",
|
|
823
|
+
"panelListItemActive": "yw4T5a_panelListItemActive",
|
|
824
|
+
"questionHeader": "yw4T5a_questionHeader",
|
|
841
825
|
"panelRunningDot": "yw4T5a_panelRunningDot",
|
|
842
|
-
"
|
|
843
|
-
"
|
|
844
|
-
"
|
|
845
|
-
"
|
|
826
|
+
"panelLookup": "yw4T5a_panelLookup",
|
|
827
|
+
"panelListItemLabel": "yw4T5a_panelListItemLabel",
|
|
828
|
+
"panelRunningPulse": "yw4T5a_panelRunningPulse",
|
|
829
|
+
"questionDeleteAll": "yw4T5a_questionDeleteAll",
|
|
830
|
+
"settingsRowTitle": "yw4T5a_settingsRowTitle",
|
|
831
|
+
"panelListItemDot": "yw4T5a_panelListItemDot",
|
|
832
|
+
"collapsedHandle": "yw4T5a_collapsedHandle",
|
|
833
|
+
"panelTranscript": "yw4T5a_panelTranscript",
|
|
834
|
+
"modelSelectTrigger": "yw4T5a_modelSelectTrigger",
|
|
835
|
+
"settingsRowDesc": "yw4T5a_settingsRowDesc",
|
|
836
|
+
"settingsBringMode": "yw4T5a_settingsBringMode",
|
|
837
|
+
"selectionButton": "yw4T5a_selectionButton",
|
|
838
|
+
"settingsPromptInput": "yw4T5a_settingsPromptInput",
|
|
846
839
|
"panelEmbedded": "yw4T5a_panelEmbedded",
|
|
840
|
+
"panelHeader": "yw4T5a_panelHeader",
|
|
841
|
+
"panel": "yw4T5a_panel",
|
|
842
|
+
"panelListDeleteAll": "yw4T5a_panelListDeleteAll",
|
|
847
843
|
"panelRunning": "yw4T5a_panelRunning",
|
|
848
844
|
"panelTitle": "yw4T5a_panelTitle",
|
|
849
|
-
"
|
|
850
|
-
"
|
|
845
|
+
"panelToolbar": "yw4T5a_panelToolbar",
|
|
846
|
+
"questionItem": "yw4T5a_questionItem",
|
|
847
|
+
"questionOptionDesc": "yw4T5a_questionOptionDesc",
|
|
848
|
+
"modelSelectLabel": "yw4T5a_modelSelectLabel",
|
|
849
|
+
"panelHeaderActions": "yw4T5a_panelHeaderActions",
|
|
850
|
+
"questionBlock": "yw4T5a_questionBlock",
|
|
851
|
+
"panelComposer": "yw4T5a_panelComposer",
|
|
851
852
|
"messageInsertButton": "yw4T5a_messageInsertButton",
|
|
853
|
+
"modelCell": "yw4T5a_modelCell",
|
|
852
854
|
"modelSelectEffort": "yw4T5a_modelSelectEffort",
|
|
853
|
-
"
|
|
854
|
-
"
|
|
855
|
-
"
|
|
856
|
-
"panelTextarea": "yw4T5a_panelTextarea",
|
|
857
|
-
"settingsToggle": "yw4T5a_settingsToggle"
|
|
855
|
+
"selectionMenu": "yw4T5a_selectionMenu",
|
|
856
|
+
"modelCellChevron": "yw4T5a_modelCellChevron",
|
|
857
|
+
"questionFabDot": "yw4T5a_questionFabDot"
|
|
858
858
|
};
|
|
859
859
|
//#endregion
|
|
860
860
|
//#region \0dsh-css:/home/runner/work/dsh-side-chat/dsh-side-chat/src/client/layout.css.mjs
|
|
@@ -916,6 +916,7 @@ window.__ModuleLoader__.load({
|
|
|
916
916
|
let prefs = { ...SUBCHAT_PREFS_DEFAULTS };
|
|
917
917
|
let mainQuestion = null;
|
|
918
918
|
let dismissedQuestionIds = [];
|
|
919
|
+
let dockAvailable = true;
|
|
919
920
|
const bySession = /* @__PURE__ */ new Map();
|
|
920
921
|
const listeners = /* @__PURE__ */ new Set();
|
|
921
922
|
let dockLaunch = null;
|
|
@@ -925,7 +926,8 @@ window.__ModuleLoader__.load({
|
|
|
925
926
|
anchor,
|
|
926
927
|
prefs,
|
|
927
928
|
mainQuestion,
|
|
928
|
-
dismissedQuestionIds
|
|
929
|
+
dismissedQuestionIds,
|
|
930
|
+
dockAvailable
|
|
929
931
|
};
|
|
930
932
|
const notify = () => {
|
|
931
933
|
snapshot = {
|
|
@@ -934,7 +936,8 @@ window.__ModuleLoader__.load({
|
|
|
934
936
|
anchor,
|
|
935
937
|
prefs,
|
|
936
938
|
mainQuestion,
|
|
937
|
-
dismissedQuestionIds
|
|
939
|
+
dismissedQuestionIds,
|
|
940
|
+
dockAvailable
|
|
938
941
|
};
|
|
939
942
|
for (const fn of [...listeners]) fn();
|
|
940
943
|
};
|
|
@@ -1001,6 +1004,11 @@ window.__ModuleLoader__.load({
|
|
|
1001
1004
|
setDockLaunch(fn) {
|
|
1002
1005
|
dockLaunch = fn;
|
|
1003
1006
|
},
|
|
1007
|
+
setDockAvailable(available) {
|
|
1008
|
+
if (available === dockAvailable) return;
|
|
1009
|
+
dockAvailable = available;
|
|
1010
|
+
notify();
|
|
1011
|
+
},
|
|
1004
1012
|
setActive(childId) {
|
|
1005
1013
|
panel = {
|
|
1006
1014
|
...panel,
|
|
@@ -2652,7 +2660,7 @@ window.__ModuleLoader__.load({
|
|
|
2652
2660
|
props.store.openPanel(snap.panel.parentSessionId);
|
|
2653
2661
|
}
|
|
2654
2662
|
}),
|
|
2655
|
-
snap.prefs.panelHome === "floating" && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(SidechatPanel, {
|
|
2663
|
+
(snap.prefs.panelHome === "floating" || !snap.dockAvailable) && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(SidechatPanel, {
|
|
2656
2664
|
store: props.store,
|
|
2657
2665
|
t: props.t,
|
|
2658
2666
|
formatDuration: props.formatDuration,
|
|
@@ -3133,9 +3141,11 @@ window.__ModuleLoader__.load({
|
|
|
3133
3141
|
const sidebarRightTabs = ctx.get("sidebarRightTabs") ?? sidebarRight?.tabs;
|
|
3134
3142
|
if (sidebarRight === void 0 || sidebarRightTabs === void 0) {
|
|
3135
3143
|
phase = "unavailable";
|
|
3144
|
+
store.setDockAvailable(false);
|
|
3136
3145
|
store.patch({ error: translate(activeLocale, "dock.unavailable") });
|
|
3137
3146
|
return;
|
|
3138
3147
|
}
|
|
3148
|
+
store.setDockAvailable(true);
|
|
3139
3149
|
const dockT = (key) => translate(activeLocale, key);
|
|
3140
3150
|
const disposeType = sidebarRightTabs.register({
|
|
3141
3151
|
id: SIDEBAR_TAB_ID,
|