@monotykamary/dsh-client-ui-settings-plugins 0.1.0-rc.8 → 0.1.0

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/README.i18n.yaml CHANGED
@@ -2,5 +2,5 @@
2
2
  # side as of the last confirmed-consistent state. Both languages carry equal authority;
3
3
  # after editing either side, bring the other along and re-record with:
4
4
  # pnpm run verify-translation-pairing --write packages/client/ui-settings-plugins/README.md
5
- README.md: 92ba426b6bee3ae73e184dfcfd418e889bd47086
6
- README.zh.md: dc319ea9f128016b6df821575cb4d75740f04579
5
+ README.md: 0ee0edbebadad8e8e895002cd9eb60a20f45809d
6
+ README.zh.md: b57fe9522dcc37b67f494199b3bb6ef0cf4a2a54
package/README.md CHANGED
@@ -20,7 +20,7 @@ A card stages what the user types and writes it only when they save. Each contro
20
20
 
21
21
  Saving writes each staged field through the client settings scope, which fences every write with the namespace revision it read, so a form that has drifted from the document is refused rather than overwriting a concurrent change. The Host is the only authority on whether a value was accepted — its validators own the constraints no schema can express — so the card reads the section back afterwards and reports a save that did not land, keeping those drafts for the user to correct.
22
22
 
23
- A key can also be written from another surface — the Models page addresses the same reference — which changes no settings section, so the card re-reads on the forwarded `credentials/updated` event for the reference it watches.
23
+ A key can also be written from another surface — the Models page addresses the same reference — which changes no settings section, so the card re-reads on the forwarded `credentials/reference-updated` event for the reference it watches.
24
24
 
25
25
  A field's presence in the raw user layer — not its value — is what marks it overridden; a reset clears that field so it re-inherits the composition layer. Secret-role fields never ride a response, so a key control starts blank, reports only whether one is configured, and writes through the credentials domain rather than the settings section; a blank draft writes nothing and keeps the stored key.
26
26
 
package/README.zh.md CHANGED
@@ -20,7 +20,7 @@
20
20
 
21
21
  保存时,每个暂存字段都通过客户端 settings scope 写入,该 scope 用读取时的命名空间 revision 为每次写入设栅,因此已与文档脱节的表单会被拒绝,而不是覆盖并发变更。某个值是否被接受只有 Host 说了算——schema 表达不了的约束归它的校验器所有——因此卡片在写入后回读分节,报告没有落盘的保存,并保留这些草稿供用户修改。
22
22
 
23
- 密钥也可能从别的表层写入——模型页寻址的是同一个引用——而那不改变任何 settings 分节,因此卡片会在转发来的 `credentials/updated` 事件报告它所关注的引用时重读。
23
+ 密钥也可能从别的表层写入——模型页寻址的是同一个引用——而那不改变任何 settings 分节,因此卡片会在转发来的 `credentials/reference-updated` 事件报告它所关注的引用时重读。
24
24
 
25
25
  字段是否被覆盖,取决于它是否出现在原始用户层中,而非取决于它的值;重置会清除该字段,使其重新继承组装层。secret 角色的字段绝不搭乘响应,因此密钥控件初始为空、只报告是否已配置,并经由 credentials 领域而非 settings 分节写入;空草稿不写入任何东西,保留已存密钥。
26
26
 
@@ -32,6 +32,8 @@
32
32
 
33
33
  无;该包既不组装也不发送提供方请求。
34
34
 
35
+ <a id="known-limitations-and-deferred-work"></a>
36
+
35
37
  ## 已知限制与暂缓事项
36
38
 
37
39
  - **只有宿主平面的插件会出现**——由 agent preset 挂载的插件把配置内联在该 preset 的 `agent.cordis.yml` 中,且根本无法注册 settings 命名空间(同一 preset 挂载第二个会话时会因重复注册而失败),因此本分区不会列出它。编辑那些值仍是 preset 编辑器的职责。
package/lib/client.js CHANGED
@@ -9,8 +9,8 @@ window.__ModuleLoader__.load({
9
9
  let react = require("react");
10
10
  let _monotykamary_dsh_client_ui_primitives = require("@monotykamary/dsh-client-ui-primitives");
11
11
  let _monotykamary_dsh_client_runtime_client = require("@monotykamary/dsh-client-runtime/client");
12
- //#region \0dsh-css:/Users/monotykamary/VCS/working-remote/open-source/deepseek-harness/packages/client/ui-settings-plugins/src/client/fields.module.css.mjs
13
- const css$2 = ".tp98LG_field{flex-direction:column;gap:6px;padding:12px 0;display:flex}.tp98LG_field+.tp98LG_field{border-top:1px solid var(--dsw-alias-border-l2)}.tp98LG_head{align-items:center;gap:8px;display:flex}.tp98LG_label{min-width:0;color:var(--dsw-alias-label-primary);flex:1;font-size:13px;font-weight:500;line-height:1.5}.tp98LG_badges{align-items:center;gap:8px;display:inline-flex}.tp98LG_badge{white-space:nowrap;background:var(--dsw-alias-bg-module-platform);color:var(--dsw-alias-label-secondary);border-radius:999px;padding:1px 8px;font-size:11px;font-weight:500;line-height:17px}.tp98LG_badgeMuted{white-space:nowrap;color:var(--dsw-alias-label-tertiary);border-radius:999px;padding:1px 8px;font-size:11px;line-height:17px}.tp98LG_reset{font:inherit;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:none;padding:0;font-size:12px;line-height:1.5}.tp98LG_reset:hover:not(:disabled){color:var(--dsw-alias-label-primary)}.tp98LG_reset:disabled{cursor:default}.tp98LG_input{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-3);height:34px;font:inherit;color:var(--dsw-alias-label-primary);border-radius:8px;padding:0 12px;font-size:13px;line-height:1.5}.tp98LG_input:focus-visible{border-color:var(--dsw-alias-brand-primary);outline:none}.tp98LG_input:disabled{color:var(--dsw-alias-label-tertiary);cursor:default}.tp98LG_inputInvalid{border-color:var(--dsw-alias-label-error);}.tp98LG_invalid{color:var(--dsw-alias-label-error);margin:0;font-size:12px;line-height:1.5}.tp98LG_hint{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:1.5}";
12
+ //#region \0dsh-css:/home/runner/work/deepseek-harness/deepseek-harness/packages/client/ui-settings-plugins/src/client/fields.module.css.mjs
13
+ const css$2 = ".At1oFq_field{flex-direction:column;gap:6px;padding:12px 0;display:flex}.At1oFq_field+.At1oFq_field{border-top:1px solid var(--dsw-alias-border-l2)}.At1oFq_head{align-items:center;gap:8px;display:flex}.At1oFq_label{min-width:0;color:var(--dsw-alias-label-primary);flex:1;font-size:13px;font-weight:500;line-height:1.5}.At1oFq_badges{align-items:center;gap:8px;display:inline-flex}.At1oFq_badge{white-space:nowrap;background:var(--dsw-alias-bg-module-platform);color:var(--dsw-alias-label-secondary);border-radius:999px;padding:1px 8px;font-size:11px;font-weight:500;line-height:17px}.At1oFq_badgeMuted{white-space:nowrap;color:var(--dsw-alias-label-tertiary);border-radius:999px;padding:1px 8px;font-size:11px;line-height:17px}.At1oFq_reset{font:inherit;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:none;padding:0;font-size:12px;line-height:1.5}.At1oFq_reset:hover:not(:disabled){color:var(--dsw-alias-label-primary)}.At1oFq_reset:disabled{cursor:default}.At1oFq_input{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-3);height:34px;font:inherit;color:var(--dsw-alias-label-primary);border-radius:8px;padding:0 12px;font-size:13px;line-height:1.5}.At1oFq_input:focus-visible{border-color:var(--dsw-alias-brand-primary);outline:none}.At1oFq_input:disabled{color:var(--dsw-alias-label-tertiary);cursor:default}.At1oFq_inputInvalid{border-color:var(--dsw-alias-label-error);}.At1oFq_invalid{color:var(--dsw-alias-label-error);margin:0;font-size:12px;line-height:1.5}.At1oFq_hint{color:var(--dsw-alias-label-tertiary);margin:0;font-size:12px;line-height:1.5}";
14
14
  const tagId$2 = "@monotykamary/dsh-client-ui-settings-plugins/fields.module.css";
15
15
  if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$2) + "]") === null) {
16
16
  const tag = document.createElement("style");
@@ -20,17 +20,17 @@ window.__ModuleLoader__.load({
20
20
  document.head.appendChild(tag);
21
21
  }
22
22
  var fields_module_css_default = {
23
- "badgeMuted": "tp98LG_badgeMuted",
24
- "input": "tp98LG_input",
25
- "reset": "tp98LG_reset",
26
- "field": "tp98LG_field",
27
- "inputInvalid": "tp98LG_inputInvalid",
28
- "invalid": "tp98LG_invalid",
29
- "badge": "tp98LG_badge",
30
- "hint": "tp98LG_hint",
31
- "badges": "tp98LG_badges",
32
- "label": "tp98LG_label",
33
- "head": "tp98LG_head"
23
+ "badge": "At1oFq_badge",
24
+ "badgeMuted": "At1oFq_badgeMuted",
25
+ "badges": "At1oFq_badges",
26
+ "field": "At1oFq_field",
27
+ "head": "At1oFq_head",
28
+ "hint": "At1oFq_hint",
29
+ "input": "At1oFq_input",
30
+ "inputInvalid": "At1oFq_inputInvalid",
31
+ "invalid": "At1oFq_invalid",
32
+ "label": "At1oFq_label",
33
+ "reset": "At1oFq_reset"
34
34
  };
35
35
  //#endregion
36
36
  //#region lib/types/client/fields.js
@@ -136,7 +136,7 @@ window.__ModuleLoader__.load({
136
136
  });
137
137
  }
138
138
  //#endregion
139
- //#region ../../../../../../../Library/pnpm/store/v11/links/@/clsx/2.1.1/2b14a624e52246853e8086215d43767b3f05a70db70d9393672d28f32b6c54a6/node_modules/clsx/dist/clsx.mjs
139
+ //#region ../../../node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.mjs
140
140
  function r(e) {
141
141
  var t, f, n = "";
142
142
  if ("string" == typeof e || "number" == typeof e) n += e;
@@ -151,8 +151,8 @@ window.__ModuleLoader__.load({
151
151
  return n;
152
152
  }
153
153
  //#endregion
154
- //#region \0dsh-css:/Users/monotykamary/VCS/working-remote/open-source/deepseek-harness/packages/client/ui-settings-plugins/src/client/PluginCard.module.css.mjs
155
- const css$1 = ".fgHXXa_card{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-3);border-radius:12px;list-style:none;transition:border-color .16s,background .16s}.fgHXXa_card:hover{border-color:var(--dsw-alias-label-dimmed)}.fgHXXa_cardOpen{background:var(--dsw-alias-bg-layer-2);border-color:var(--dsw-alias-label-dimmed)}.fgHXXa_header{appearance:none;width:100%;font:inherit;color:inherit;text-align:left;cursor:pointer;background:0 0;border:0;border-radius:12px;align-items:center;gap:12px;padding:14px 16px;display:flex}.fgHXXa_header:focus-visible{outline:2px solid var(--dsw-alias-brand-primary);outline-offset:-2px}.fgHXXa_headText{flex-direction:column;flex:1;gap:4px;min-width:0;display:flex}.fgHXXa_name{color:var(--dsw-alias-label-primary);font-size:15px;font-weight:600;line-height:1.4}.fgHXXa_description{color:var(--dsw-alias-label-tertiary);font-size:13px;line-height:1.5}.fgHXXa_chevron{color:var(--dsw-alias-label-tertiary);flex:none;transition:transform .16s}.fgHXXa_chevronOpen{transform:rotate(180deg)}.fgHXXa_body{border-top:1px solid var(--dsw-alias-border-l2);margin:0 16px;padding-bottom:8px}.fgHXXa_readOnly{color:var(--dsw-alias-label-tertiary);margin:12px 0 0;font-size:12px;line-height:1.5}.fgHXXa_pending{white-space:nowrap;background:var(--dsw-alias-bg-module-platform);color:var(--dsw-alias-label-secondary);border-radius:999px;flex:none;padding:1px 8px;font-size:11px;font-weight:500;line-height:17px}.fgHXXa_footer{border-top:1px solid var(--dsw-alias-border-l2);justify-content:flex-end;align-items:center;gap:8px;padding:12px 0 4px;display:flex}.fgHXXa_failed{min-width:0;color:var(--dsw-alias-label-error);flex:1;margin:0;font-size:12px;line-height:1.5}.fgHXXa_discard,.fgHXXa_save{appearance:none;font:inherit;cursor:pointer;border:1px solid #0000;border-radius:8px;padding:5px 14px;font-size:13px;line-height:1.5}.fgHXXa_discard{border-color:var(--dsw-alias-border-l2);color:var(--dsw-alias-label-secondary);background:0 0}.fgHXXa_discard:hover:not(:disabled){color:var(--dsw-alias-label-primary);border-color:var(--dsw-alias-label-dimmed)}.fgHXXa_save{background:var(--dsw-alias-label-primary);color:var(--dsw-alias-bg-layer-3)}.fgHXXa_discard:disabled,.fgHXXa_save:disabled{opacity:.4;cursor:default}.fgHXXa_discard:focus-visible,.fgHXXa_save:focus-visible{outline:2px solid var(--dsw-alias-brand-primary);outline-offset:1px}";
154
+ //#region \0dsh-css:/home/runner/work/deepseek-harness/deepseek-harness/packages/client/ui-settings-plugins/src/client/PluginCard.module.css.mjs
155
+ const css$1 = ".YyYd_a_card{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-3);border-radius:12px;list-style:none;transition:border-color .16s,background .16s}.YyYd_a_card:hover{border-color:var(--dsw-alias-label-dimmed)}.YyYd_a_cardOpen{background:var(--dsw-alias-bg-layer-2);border-color:var(--dsw-alias-label-dimmed)}.YyYd_a_header{appearance:none;width:100%;font:inherit;color:inherit;text-align:left;cursor:pointer;background:0 0;border:0;border-radius:12px;align-items:center;gap:12px;padding:14px 16px;display:flex}.YyYd_a_header:focus-visible{outline:2px solid var(--dsw-alias-brand-primary);outline-offset:-2px}.YyYd_a_headText{flex-direction:column;flex:1;gap:4px;min-width:0;display:flex}.YyYd_a_name{color:var(--dsw-alias-label-primary);font-size:15px;font-weight:600;line-height:1.4}.YyYd_a_description{color:var(--dsw-alias-label-tertiary);font-size:13px;line-height:1.5}.YyYd_a_chevron{color:var(--dsw-alias-label-tertiary);flex:none;transition:transform .16s}.YyYd_a_chevronOpen{transform:rotate(180deg)}.YyYd_a_body{border-top:1px solid var(--dsw-alias-border-l2);margin:0 16px;padding-bottom:8px}.YyYd_a_readOnly{color:var(--dsw-alias-label-tertiary);margin:12px 0 0;font-size:12px;line-height:1.5}.YyYd_a_pending{white-space:nowrap;background:var(--dsw-alias-bg-module-platform);color:var(--dsw-alias-label-secondary);border-radius:999px;flex:none;padding:1px 8px;font-size:11px;font-weight:500;line-height:17px}.YyYd_a_footer{border-top:1px solid var(--dsw-alias-border-l2);justify-content:flex-end;align-items:center;gap:8px;padding:12px 0 4px;display:flex}.YyYd_a_failed{min-width:0;color:var(--dsw-alias-label-error);flex:1;margin:0;font-size:12px;line-height:1.5}.YyYd_a_discard,.YyYd_a_save{appearance:none;font:inherit;cursor:pointer;border:1px solid #0000;border-radius:8px;padding:5px 14px;font-size:13px;line-height:1.5}.YyYd_a_discard{border-color:var(--dsw-alias-border-l2);color:var(--dsw-alias-label-secondary);background:0 0}.YyYd_a_discard:hover:not(:disabled){color:var(--dsw-alias-label-primary);border-color:var(--dsw-alias-label-dimmed)}.YyYd_a_save{background:var(--dsw-alias-label-primary);color:var(--dsw-alias-bg-layer-3)}.YyYd_a_discard:disabled,.YyYd_a_save:disabled{opacity:.4;cursor:default}.YyYd_a_discard:focus-visible,.YyYd_a_save:focus-visible{outline:2px solid var(--dsw-alias-brand-primary);outline-offset:1px}";
156
156
  const tagId$1 = "@monotykamary/dsh-client-ui-settings-plugins/PluginCard.module.css";
157
157
  if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$1) + "]") === null) {
158
158
  const tag = document.createElement("style");
@@ -162,21 +162,21 @@ window.__ModuleLoader__.load({
162
162
  document.head.appendChild(tag);
163
163
  }
164
164
  var PluginCard_module_css_default = {
165
- "description": "fgHXXa_description",
166
- "pending": "fgHXXa_pending",
167
- "chevron": "fgHXXa_chevron",
168
- "failed": "fgHXXa_failed",
169
- "header": "fgHXXa_header",
170
- "headText": "fgHXXa_headText",
171
- "chevronOpen": "fgHXXa_chevronOpen",
172
- "cardOpen": "fgHXXa_cardOpen",
173
- "footer": "fgHXXa_footer",
174
- "discard": "fgHXXa_discard",
175
- "name": "fgHXXa_name",
176
- "body": "fgHXXa_body",
177
- "save": "fgHXXa_save",
178
- "card": "fgHXXa_card",
179
- "readOnly": "fgHXXa_readOnly"
165
+ "body": "YyYd_a_body",
166
+ "card": "YyYd_a_card",
167
+ "cardOpen": "YyYd_a_cardOpen",
168
+ "chevron": "YyYd_a_chevron",
169
+ "chevronOpen": "YyYd_a_chevronOpen",
170
+ "description": "YyYd_a_description",
171
+ "discard": "YyYd_a_discard",
172
+ "failed": "YyYd_a_failed",
173
+ "footer": "YyYd_a_footer",
174
+ "headText": "YyYd_a_headText",
175
+ "header": "YyYd_a_header",
176
+ "name": "YyYd_a_name",
177
+ "pending": "YyYd_a_pending",
178
+ "readOnly": "YyYd_a_readOnly",
179
+ "save": "YyYd_a_save"
180
180
  };
181
181
  //#endregion
182
182
  //#region lib/types/client/PluginCard.js
@@ -231,7 +231,10 @@ window.__ModuleLoader__.load({
231
231
  className: PluginCard_module_css_default.pending,
232
232
  children: props.t("unsaved")
233
233
  }) : null,
234
- (0, react_jsx_runtime.jsx)(_monotykamary_dsh_client_ui_primitives.IconChevronDownOutline14, { className: clsx(PluginCard_module_css_default.chevron, open && PluginCard_module_css_default.chevronOpen) })
234
+ (0, react_jsx_runtime.jsx)(_monotykamary_dsh_client_ui_primitives.ChevronDown, {
235
+ size: 14,
236
+ className: clsx(PluginCard_module_css_default.chevron, open && PluginCard_module_css_default.chevronOpen)
237
+ })
235
238
  ]
236
239
  }), open ? (0, react_jsx_runtime.jsxs)("div", {
237
240
  className: PluginCard_module_css_default.body,
@@ -360,8 +363,8 @@ window.__ModuleLoader__.load({
360
363
  });
361
364
  }
362
365
  //#endregion
363
- //#region \0dsh-css:/Users/monotykamary/VCS/working-remote/open-source/deepseek-harness/packages/client/ui-settings-plugins/src/client/PluginsSettingsSection.module.css.mjs
364
- const css = ".NYK7ya_section{max-width:760px;color:var(--dsw-alias-label-primary);flex-direction:column;gap:12px;display:flex}.NYK7ya_heading{margin:0;font-size:18px;font-weight:600}.NYK7ya_intro{color:var(--dsw-alias-label-tertiary);margin:0;font-size:13px}.NYK7ya_tabs{border-bottom:1px solid var(--dsw-alias-border-l2);align-items:flex-end;gap:22px;margin-top:2px;display:flex}.NYK7ya_tab{color:var(--dsw-alias-label-tertiary);font:inherit;cursor:pointer;background:0 0;border:0;padding:7px 1px 9px;font-size:13px;line-height:20px;position:relative}.NYK7ya_tab:hover,.NYK7ya_tab[data-active=true]{color:var(--dsw-alias-label-primary)}.NYK7ya_tab[data-active=true]:after,.NYK7ya_tab:focus-visible:after{background:var(--dsw-alias-label-primary);content:\"\";border-radius:2px 2px 0 0;height:2px;position:absolute;bottom:-1px;left:0;right:0}.NYK7ya_tab:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary);outline-offset:2px;color:var(--dsw-alias-label-primary);border-radius:2px}.NYK7ya_panel{min-width:0;padding-top:2px}.NYK7ya_cards{flex-direction:column;gap:10px;margin:0;padding:0;list-style:none;display:flex}.NYK7ya_empty{color:var(--dsw-alias-label-tertiary);margin:0;font-size:13px}";
366
+ //#region \0dsh-css:/home/runner/work/deepseek-harness/deepseek-harness/packages/client/ui-settings-plugins/src/client/PluginsSettingsSection.module.css.mjs
367
+ const css = ".pbvGtq_section{max-width:760px;color:var(--dsw-alias-label-primary);flex-direction:column;gap:12px;display:flex}.pbvGtq_heading{margin:0;font-size:18px;font-weight:600}.pbvGtq_intro{color:var(--dsw-alias-label-tertiary);margin:0;font-size:13px}.pbvGtq_tabs{border-bottom:1px solid var(--dsw-alias-border-l2);align-items:flex-end;gap:22px;margin-top:2px;display:flex}.pbvGtq_tab{color:var(--dsw-alias-label-tertiary);font:inherit;cursor:pointer;background:0 0;border:0;padding:7px 1px 9px;font-size:13px;line-height:20px;position:relative}.pbvGtq_tab:hover,.pbvGtq_tab[data-active=true]{color:var(--dsw-alias-label-primary)}.pbvGtq_tab[data-active=true]:after,.pbvGtq_tab:focus-visible:after{background:var(--dsw-alias-label-primary);content:\"\";border-radius:2px 2px 0 0;height:2px;position:absolute;bottom:-1px;left:0;right:0}.pbvGtq_tab:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary);outline-offset:2px;color:var(--dsw-alias-label-primary);border-radius:2px}.pbvGtq_panel{min-width:0;padding-top:2px}.pbvGtq_cards{flex-direction:column;gap:10px;margin:0;padding:0;list-style:none;display:flex}.pbvGtq_empty{color:var(--dsw-alias-label-tertiary);margin:0;font-size:13px}";
365
368
  const tagId = "@monotykamary/dsh-client-ui-settings-plugins/PluginsSettingsSection.module.css";
366
369
  if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId) + "]") === null) {
367
370
  const tag = document.createElement("style");
@@ -371,14 +374,14 @@ window.__ModuleLoader__.load({
371
374
  document.head.appendChild(tag);
372
375
  }
373
376
  var PluginsSettingsSection_module_css_default = {
374
- "panel": "NYK7ya_panel",
375
- "intro": "NYK7ya_intro",
376
- "tab": "NYK7ya_tab",
377
- "tabs": "NYK7ya_tabs",
378
- "cards": "NYK7ya_cards",
379
- "section": "NYK7ya_section",
380
- "empty": "NYK7ya_empty",
381
- "heading": "NYK7ya_heading"
377
+ "cards": "pbvGtq_cards",
378
+ "empty": "pbvGtq_empty",
379
+ "heading": "pbvGtq_heading",
380
+ "intro": "pbvGtq_intro",
381
+ "panel": "pbvGtq_panel",
382
+ "section": "pbvGtq_section",
383
+ "tab": "pbvGtq_tab",
384
+ "tabs": "pbvGtq_tabs"
382
385
  };
383
386
  //#endregion
384
387
  //#region lib/types/client/ConfigurablePluginsTab.js
@@ -920,47 +923,28 @@ window.__ModuleLoader__.load({
920
923
  * is never dispatched, so a plugin this deployment did not compose leaves no
921
924
  * trace and does not count toward the empty line.
922
925
  */
923
- /** Reads the served namespaces and pairs them with the cards that claim them. */
926
+ /** Derives the served namespaces from the shared describe mirror and pairs them with the cards that claim them. */
924
927
  var ConfigurablePluginsTabController = class {
925
- api;
928
+ describeFace;
926
929
  entries;
927
930
  store = (0, _monotykamary_dsh_client_runtime_client.createSnapshotStore)({
928
931
  loaded: false,
929
932
  namespaces: []
930
933
  });
931
- /** Last Host answer; kept so a slot mutation republishes without a wire read. */
932
- served = [];
933
- loaded = false;
934
- generation = 0;
935
934
  disposed = false;
935
+ unsubscribe;
936
936
  /**
937
- * @param api - settings wire face.
937
+ * @param describeFace - the shared mirror's describe face; its refreshes
938
+ * (document commits, reconnects) are what keep the served set current.
938
939
  * @param entries - reads the cards currently registered into the section's slot.
939
940
  */
940
- constructor(api, entries) {
941
- this.api = api;
941
+ constructor(describeFace, entries) {
942
+ this.describeFace = describeFace;
942
943
  this.entries = entries;
943
- }
944
- /** Opaque read of {@link disposed}: control flow cannot narrow it across awaits. */
945
- isDisposed() {
946
- return this.disposed;
947
- }
948
- /**
949
- * Re-read the served namespaces from the Host and republish.
950
- * @returns settlement after the read, or immediately once disposed.
951
- */
952
- async load() {
953
- if (this.isDisposed()) return;
954
- const generation = ++this.generation;
955
- let response;
956
- try {
957
- response = await this.api.settings.describe({});
958
- } catch (_settingsReadFailure) {
959
- return;
960
- }
961
- if (this.isDisposed() || generation !== this.generation || !response.result.ok) return;
962
- this.served = response.result.value.namespaces.map((view) => view.ns);
963
- this.loaded = true;
944
+ this.unsubscribe = describeFace.subscribe(() => {
945
+ this.publish();
946
+ });
947
+ describeFace.ensure();
964
948
  this.publish();
965
949
  }
966
950
  /** Republish after the slot ledger changed; a card registered late joins here. */
@@ -968,10 +952,10 @@ window.__ModuleLoader__.load({
968
952
  if (this.disposed) return;
969
953
  this.publish();
970
954
  }
971
- /** Stop publishing; an in-flight read settles without touching the store. */
955
+ /** Stop publishing and stop following the mirror. */
972
956
  dispose() {
973
957
  this.disposed = true;
974
- this.generation += 1;
958
+ this.unsubscribe();
975
959
  }
976
960
  /**
977
961
  * Build the face the tab's slot registration injects.
@@ -981,12 +965,15 @@ window.__ModuleLoader__.load({
981
965
  return { hooks: { configurablePlugins: this.store } };
982
966
  }
983
967
  publish() {
984
- const served = new Set(this.served);
968
+ if (this.disposed) return;
969
+ const mirrored = this.describeFace.getSnapshot();
970
+ const loaded = mirrored.view !== void 0;
971
+ const served = new Set(mirrored.view?.namespaces.map((view) => view.ns) ?? []);
985
972
  const namespaces = this.entries().flatMap((entry) => entry.options.key !== void 0 && served.has(entry.options.key) ? [entry.options.key] : []);
986
973
  const previous = this.store.getSnapshot();
987
- if (previous.loaded === this.loaded && previous.namespaces.length === namespaces.length && previous.namespaces.every((ns, index) => ns === namespaces[index])) return;
974
+ if (previous.loaded === loaded && previous.namespaces.length === namespaces.length && previous.namespaces.every((ns, index) => ns === namespaces[index])) return;
988
975
  this.store.set({
989
- loaded: this.loaded,
976
+ loaded,
990
977
  namespaces
991
978
  });
992
979
  }
@@ -1251,23 +1238,16 @@ window.__ModuleLoader__.load({
1251
1238
  const bash = new BashCardController(ctx.settingsScope.bind({ namespace: SHELL_NS }));
1252
1239
  const agentLoop = new AgentLoopCardController(ctx.settingsScope.bind({ namespace: AGENT_LOOP_NS }));
1253
1240
  const webSearch = new WebSearchCardController(ctx.settingsScope.bind({ namespace: WEB_SEARCH_NS }), api);
1254
- ctx.effect(() => ctx.remote.$on("credentials/updated", (ref) => {
1241
+ ctx.effect(() => ctx.remote.$on("credentials/reference-updated", (ref) => {
1255
1242
  webSearch.refreshCredential(ref);
1256
1243
  }), "ui-settings-plugins: credential invalidations");
1257
- const configurable = new ConfigurablePluginsTabController(api, () => ctx.slots.entries("settings.plugin.item"));
1244
+ const configurable = new ConfigurablePluginsTabController(ctx.settingsScope.describe(), () => ctx.slots.entries("settings.plugin.item"));
1258
1245
  ctx.effect(() => () => {
1259
1246
  configurable.dispose();
1260
1247
  }, "ui-settings-plugins: tab directory");
1261
- ctx.effect(() => ctx.remote.$on("settings/document-updated", () => {
1262
- configurable.load();
1263
- }), "ui-settings-plugins: served-namespace invalidations");
1264
- ctx.effect(() => ctx.on("connection/reset", () => {
1265
- configurable.load();
1266
- }), "ui-settings-plugins: served-namespace reconnect");
1267
1248
  ctx.effect(() => ctx.slots.subscribe("settings.plugin.item", () => {
1268
1249
  configurable.refresh();
1269
1250
  }), "ui-settings-plugins: card ledger");
1270
- configurable.load();
1271
1251
  let tabsVersion = -1;
1272
1252
  let tabsRevision = -1;
1273
1253
  let tabs = [];
@@ -9,7 +9,7 @@
9
9
  * is never dispatched, so a plugin this deployment did not compose leaves no
10
10
  * trace and does not count toward the empty line.
11
11
  */
12
- import type { IApiClient } from '@monotykamary/dsh-client-connection/client';
12
+ import type { SettingsDescribeFace } from '@monotykamary/dsh-client-ui-settings/client';
13
13
  import type { StoredEntry } from '@monotykamary/dsh-client-ui-slots';
14
14
  import { type SnapshotStore } from '@monotykamary/dsh-client-runtime/client';
15
15
  /** What the section renders. */
@@ -38,31 +38,22 @@ export interface ConfigurablePluginsTabFace {
38
38
  configurablePlugins: SnapshotStore<ConfigurablePluginsTabState>;
39
39
  };
40
40
  }
41
- /** Reads the served namespaces and pairs them with the cards that claim them. */
41
+ /** Derives the served namespaces from the shared describe mirror and pairs them with the cards that claim them. */
42
42
  export declare class ConfigurablePluginsTabController {
43
- private readonly api;
43
+ private readonly describeFace;
44
44
  private readonly entries;
45
45
  private readonly store;
46
- /** Last Host answer; kept so a slot mutation republishes without a wire read. */
47
- private served;
48
- private loaded;
49
- private generation;
50
46
  private disposed;
47
+ private readonly unsubscribe;
51
48
  /**
52
- * @param api - settings wire face.
49
+ * @param describeFace - the shared mirror's describe face; its refreshes
50
+ * (document commits, reconnects) are what keep the served set current.
53
51
  * @param entries - reads the cards currently registered into the section's slot.
54
52
  */
55
- constructor(api: Pick<IApiClient, 'settings'>, entries: () => readonly StoredEntry[]);
56
- /** Opaque read of {@link disposed}: control flow cannot narrow it across awaits. */
57
- private isDisposed;
58
- /**
59
- * Re-read the served namespaces from the Host and republish.
60
- * @returns settlement after the read, or immediately once disposed.
61
- */
62
- load(): Promise<void>;
53
+ constructor(describeFace: SettingsDescribeFace, entries: () => readonly StoredEntry[]);
63
54
  /** Republish after the slot ledger changed; a card registered late joins here. */
64
55
  refresh(): void;
65
- /** Stop publishing; an in-flight read settles without touching the store. */
56
+ /** Stop publishing and stop following the mirror. */
66
57
  dispose(): void;
67
58
  /**
68
59
  * Build the face the tab's slot registration injects.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@monotykamary/dsh-client-ui-settings-plugins",
3
3
  "description": "Plugins settings section with feature-owned tabs and configurable host-plane plugin cards",
4
- "version": "0.1.0-rc.8",
4
+ "version": "0.1.0",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -43,32 +43,27 @@
43
43
  },
44
44
  "license": "MIT",
45
45
  "peerDependencies": {
46
- "react": "^18.2.0",
46
+ "@monotykamary/dsh-client-connection": "^0.1.0",
47
+ "@monotykamary/dsh-client-runtime": "^0.1.0",
48
+ "@monotykamary/dsh-client-locale": "^0.1.0",
49
+ "@monotykamary/dsh-invariants": "^0.1.0",
47
50
  "@monotykamary/cordis": "^4.0.1",
48
- "@monotykamary/dsh-api-remotes": "^0.1.0-rc.8",
49
- "@monotykamary/dsh-client-ui-slots": "^0.1.0-rc.8",
50
- "@monotykamary/dsh-client-runtime": "^0.1.0-rc.8",
51
- "@monotykamary/dsh-client-locale": "^0.1.0-rc.8",
52
- "@monotykamary/dsh-client-ui-settings": "^0.1.0-rc.8",
53
- "@monotykamary/dsh-client-connection": "^0.1.0-rc.8",
54
- "@monotykamary/dsh-client-ui-primitives": "^0.1.0-rc.8",
55
- "@monotykamary/dsh-client-web-react": "^0.1.0-rc.8",
56
- "@monotykamary/dsh-invariants": "^0.1.0-rc.8"
51
+ "@monotykamary/dsh-client-ui-settings": "^0.1.0",
52
+ "@monotykamary/dsh-api-remotes": "^0.1.0"
57
53
  },
58
54
  "devDependencies": {
59
55
  "@types/react": "~18.3.1",
60
56
  "react": "^18.2.0",
57
+ "@monotykamary/dsh-api-remotes": "^0.1.0",
61
58
  "@monotykamary/cordis": "^4.0.1",
62
- "@monotykamary/dsh-api-remotes": "^0.1.0-rc.8",
63
- "@monotykamary/dsh-client-runtime": "^0.1.0-rc.8",
64
- "@monotykamary/dsh-client-locale": "^0.1.0-rc.8",
65
- "@monotykamary/dsh-client-connection": "^0.1.0-rc.8",
66
- "@monotykamary/dsh-client-ui-primitives": "^0.1.0-rc.8",
67
- "@monotykamary/dsh-client-ui-settings": "^0.1.0-rc.8",
68
- "@monotykamary/dsh-client-web-react": "^0.1.0-rc.8",
69
- "@monotykamary/dsh-client-test-runtime": "^0.1.0-rc.8",
70
- "@monotykamary/dsh-client-ui-slots": "^0.1.0-rc.8",
71
- "@monotykamary/dsh-invariants": "^0.1.0-rc.8"
59
+ "@monotykamary/dsh-client-connection": "^0.1.0",
60
+ "@monotykamary/dsh-client-runtime": "^0.1.0",
61
+ "@monotykamary/dsh-client-locale": "^0.1.0",
62
+ "@monotykamary/dsh-client-test-runtime": "^0.1.0",
63
+ "@monotykamary/dsh-client-ui-primitives": "^0.1.0",
64
+ "@monotykamary/dsh-client-ui-settings": "^0.1.0",
65
+ "@monotykamary/dsh-client-ui-slots": "^0.1.0",
66
+ "@monotykamary/dsh-invariants": "^0.1.0"
72
67
  },
73
68
  "files": [
74
69
  "lib/index.js",