@linxin666/dsh-client-ui-session-id 0.2.9 → 0.3.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.
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
  # node scripts/verify-docs.mjs --write <dir>
5
- README.md: c89aecce011b00c6fe413f052de859169f360be7
6
- README.zh.md: 344d6d62fd03bfe306917107a832a539a54e7d63
5
+ README.md: 3f202c1f99b79851bd6d10144eb60f27350021fc
6
+ README.zh.md: 3e9359161fe58b0a97e2926855a5ab1b9b6681af
package/README.md CHANGED
@@ -9,8 +9,11 @@ changes, nothing runs on the host.
9
9
 
10
10
  ## What it does
11
11
 
12
- - Adds a "Session ID" trigger beside the sidebar settings row (icon in the
13
- 56px rail, labeled row in the wide sidebar).
12
+ - Adds a "Session ID" trigger beside the sidebar settings row: an icon-only
13
+ button in both the 56px rail and the wide sidebar (the label stays as the
14
+ accessible name and hover tooltip).
15
+ - In the rail it stacks vertically with the update/remote actions on the rail
16
+ centerline; in the wide sidebar it sits inline with them.
14
17
  - Opens a centered panel listing every session: display title, full session id
15
18
  (monospace), and a per-row "Copy" button. The current session is marked.
16
19
  - A search box filters the list locally by title or id substring (read-only,
package/README.zh.md CHANGED
@@ -8,8 +8,10 @@
8
8
 
9
9
  ## 是什么
10
10
 
11
- - 在侧边栏底部的设置行旁边新增「会话 ID」入口(56px 收起态显示图标,展开态
12
- 显示带文字的整行按钮)。
11
+ - 在侧边栏底部的设置行旁边新增「会话 ID」入口:收起态与展开态都只显示
12
+ 图标按钮(文字保留为无障碍名称与悬停提示)。
13
+ - 收起态下与遥控/更新入口同列纵向堆叠、对齐轨道中轴;展开态下与其他底部
14
+ 入口同行横排。
13
15
  - 点击打开居中面板,列出全部会话:显示标题、完整会话 ID(等宽字体),每行
14
16
  一个「复制」按钮;当前会话有标记。
15
17
  - 面板顶部有搜索框,按标题或 ID 子串**本地**过滤(只读、不发起 host 查询),
package/lib/client.js CHANGED
@@ -84,7 +84,7 @@ window.__ModuleLoader__.load({
84
84
  const SESSION_ID_PART_SEARCH = "search";
85
85
  //#endregion
86
86
  //#region \0dsh-css:packages/dsh-session-id/src/client/session-id.module.css.mjs
87
- const css = ".-TNLea_trigger{width:36px;height:36px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:none;border-radius:50%;flex:none;justify-content:center;align-items:center;padding:0;transition:background-color .12s,color .12s,box-shadow .12s;display:inline-flex;position:relative}.-TNLea_trigger[data-wide=wide]{border-radius:8px;flex:auto;justify-content:flex-start;gap:8px;width:auto;min-width:0;padding:0 10px}.-TNLea_trigger[data-wide=wide] .-TNLea_triggerLabel{display:inline}.-TNLea_triggerLabel{white-space:nowrap;text-overflow:ellipsis;font-size:14px;line-height:20px;display:none;overflow:hidden}.-TNLea_trigger:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary)}.-TNLea_trigger:active:not(:disabled){background:var(--dsw-alias-interactive-bg-active)}.-TNLea_trigger:focus-visible{box-shadow:0 0 0 2px var(--dsw-alias-bg-layer-2), 0 0 0 4px var(--dsw-alias-brand-primary);outline:none}.-TNLea_overlay{z-index:1000;justify-content:center;align-items:center;display:flex;position:fixed;inset:0}.-TNLea_mask{background:var(--dsw-alias-bg-mask-1);backdrop-filter:var(--dsw-mask-blur);position:absolute;inset:0}.-TNLea_panel{z-index:1;box-sizing:border-box;background:var(--dsw-alias-bg-layer-2);width:560px;max-width:calc(100vw - 48px);max-height:calc(100vh - 48px);box-shadow:var(--dsw-shadow-lv3);color:var(--dsw-alias-label-primary);border-radius:24px;flex-direction:column;gap:14px;padding:24px;font-size:14px;line-height:22px;display:flex;position:relative}.-TNLea_header{align-items:flex-start;gap:12px;display:flex}.-TNLea_heading{flex:1;min-width:0}.-TNLea_title{margin:0;font-size:18px;font-weight:600;line-height:26px}.-TNLea_closeButton{width:28px;height:28px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:none;border-radius:8px;flex:none;justify-content:center;align-items:center;padding:0;transition:background-color .12s,color .12s;display:inline-flex}.-TNLea_closeButton:hover{background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary)}.-TNLea_closeButton:focus-visible{box-shadow:0 0 0 2px var(--dsw-alias-bg-layer-2), 0 0 0 4px var(--dsw-alias-brand-primary);outline:none}.-TNLea_search{box-sizing:border-box;border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-1);width:100%;height:32px;color:var(--dsw-alias-label-primary);border-radius:8px;flex:none;padding:0 10px;font-size:14px;line-height:20px}.-TNLea_search::placeholder{color:var(--dsw-alias-label-tertiary)}.-TNLea_search:focus-visible{box-shadow:0 0 0 2px var(--dsw-alias-bg-layer-2), 0 0 0 4px var(--dsw-alias-brand-primary);outline:none}.-TNLea_empty{text-align:center;color:var(--dsw-alias-label-tertiary);padding:24px 0}.-TNLea_list{flex-direction:column;gap:4px;display:flex;overflow:auto}.-TNLea_row{border-radius:10px;align-items:center;gap:10px;min-width:0;padding:8px 10px;display:flex}.-TNLea_row:hover{background:var(--dsw-alias-interactive-bg-hover)}.-TNLea_rowInfo{flex:1;min-width:0}.-TNLea_rowTitle{white-space:nowrap;text-overflow:ellipsis;color:var(--dsw-alias-label-primary);font-weight:500;display:block;overflow:hidden}.-TNLea_rowTitle.-TNLea_rowActive{color:var(--dsw-alias-brand-primary)}.-TNLea_rowId{white-space:nowrap;text-overflow:ellipsis;color:var(--dsw-alias-label-secondary);font-family:var(--dsw-font-mono,ui-monospace, SFMono-Regular, Menlo, Consolas, monospace);margin-top:2px;font-size:12px;line-height:18px;display:block;overflow:hidden}.-TNLea_rowMeta{color:var(--dsw-alias-label-tertiary);align-items:center;gap:8px;margin-top:2px;font-size:12px;line-height:18px;display:flex}.-TNLea_copyButton{height:28px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:none;border-radius:8px;flex:none;align-items:center;gap:4px;padding:0 10px;font-size:12px;line-height:18px;transition:background-color .12s,color .12s;display:inline-flex}.-TNLea_copyButton:hover{background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary)}.-TNLea_copyButton[data-copied=true]{color:var(--dsw-alias-brand-primary)}.-TNLea_copyButton[data-failed=true]{color:var(--dsw-alias-state-error-primary)}.-TNLea_copyButton:focus-visible{box-shadow:0 0 0 2px var(--dsw-alias-bg-layer-2), 0 0 0 4px var(--dsw-alias-brand-primary);outline:none}.-TNLea_icon{width:16px;height:16px}.-TNLea_iconSmall{width:12px;height:12px}";
87
+ const css = ".-TNLea_trigger{width:36px;height:36px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:none;border-radius:50%;flex:none;order:1;justify-content:center;align-items:center;padding:0;transition:background-color .12s,color .12s,box-shadow .12s;display:inline-flex;position:relative}.-TNLea_trigger:hover:not(:disabled){background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary)}.-TNLea_trigger:active:not(:disabled){background:var(--dsw-alias-interactive-bg-active)}.-TNLea_trigger:focus-visible{box-shadow:0 0 0 2px var(--dsw-alias-bg-layer-2), 0 0 0 4px var(--dsw-alias-brand-primary);outline:none}[class*=footerActions]:has([data-dsh-plugin=session-id][data-wide=rail]){flex-direction:column;align-items:center;gap:4px}.-TNLea_overlay{z-index:1000;justify-content:center;align-items:center;display:flex;position:fixed;inset:0}.-TNLea_mask{background:var(--dsw-alias-bg-mask-1);backdrop-filter:var(--dsw-mask-blur);position:absolute;inset:0}.-TNLea_panel{z-index:1;box-sizing:border-box;background:var(--dsw-alias-bg-layer-2);width:560px;max-width:calc(100vw - 48px);max-height:calc(100vh - 48px);box-shadow:var(--dsw-shadow-lv3);color:var(--dsw-alias-label-primary);border-radius:24px;flex-direction:column;gap:14px;padding:24px;font-size:14px;line-height:22px;display:flex;position:relative}.-TNLea_header{align-items:flex-start;gap:12px;display:flex}.-TNLea_heading{flex:1;min-width:0}.-TNLea_title{margin:0;font-size:18px;font-weight:600;line-height:26px}.-TNLea_closeButton{width:28px;height:28px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:none;border-radius:8px;flex:none;justify-content:center;align-items:center;padding:0;transition:background-color .12s,color .12s;display:inline-flex}.-TNLea_closeButton:hover{background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary)}.-TNLea_closeButton:focus-visible{box-shadow:0 0 0 2px var(--dsw-alias-bg-layer-2), 0 0 0 4px var(--dsw-alias-brand-primary);outline:none}.-TNLea_search{box-sizing:border-box;border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-1);width:100%;height:32px;color:var(--dsw-alias-label-primary);border-radius:8px;flex:none;padding:0 10px;font-size:14px;line-height:20px}.-TNLea_search::placeholder{color:var(--dsw-alias-label-tertiary)}.-TNLea_search:focus-visible{box-shadow:0 0 0 2px var(--dsw-alias-bg-layer-2), 0 0 0 4px var(--dsw-alias-brand-primary);outline:none}.-TNLea_empty{text-align:center;color:var(--dsw-alias-label-tertiary);padding:24px 0}.-TNLea_list{flex-direction:column;gap:4px;display:flex;overflow:auto}.-TNLea_row{border-radius:10px;align-items:center;gap:10px;min-width:0;padding:8px 10px;display:flex}.-TNLea_row:hover{background:var(--dsw-alias-interactive-bg-hover)}.-TNLea_rowInfo{flex:1;min-width:0}.-TNLea_rowTitle{white-space:nowrap;text-overflow:ellipsis;color:var(--dsw-alias-label-primary);font-weight:500;display:block;overflow:hidden}.-TNLea_rowTitle.-TNLea_rowActive{color:var(--dsw-alias-brand-primary)}.-TNLea_rowId{white-space:nowrap;text-overflow:ellipsis;color:var(--dsw-alias-label-secondary);font-family:var(--dsw-font-mono,ui-monospace, SFMono-Regular, Menlo, Consolas, monospace);margin-top:2px;font-size:12px;line-height:18px;display:block;overflow:hidden}.-TNLea_rowMeta{color:var(--dsw-alias-label-tertiary);align-items:center;gap:8px;margin-top:2px;font-size:12px;line-height:18px;display:flex}.-TNLea_copyButton{height:28px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:none;border-radius:8px;flex:none;align-items:center;gap:4px;padding:0 10px;font-size:12px;line-height:18px;transition:background-color .12s,color .12s;display:inline-flex}.-TNLea_copyButton:hover{background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary)}.-TNLea_copyButton[data-copied=true]{color:var(--dsw-alias-brand-primary)}.-TNLea_copyButton[data-failed=true]{color:var(--dsw-alias-state-error-primary)}.-TNLea_copyButton:focus-visible{box-shadow:0 0 0 2px var(--dsw-alias-bg-layer-2), 0 0 0 4px var(--dsw-alias-brand-primary);outline:none}.-TNLea_icon{width:16px;height:16px}.-TNLea_iconSmall{width:12px;height:12px}";
88
88
  const tagId = "@linxin666/dsh-client-ui-session-id/session-id.module.css";
89
89
  if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId) + "]") === null) {
90
90
  const tag = document.createElement("style");
@@ -113,8 +113,7 @@ window.__ModuleLoader__.load({
113
113
  "rowTitle": "-TNLea_rowTitle",
114
114
  "search": "-TNLea_search",
115
115
  "title": "-TNLea_title",
116
- "trigger": "-TNLea_trigger",
117
- "triggerLabel": "-TNLea_triggerLabel"
116
+ "trigger": "-TNLea_trigger"
118
117
  };
119
118
  //#endregion
120
119
  //#region src/client/SessionIdPanel.tsx
@@ -135,13 +134,20 @@ window.__ModuleLoader__.load({
135
134
  /** One session row: title + id + copy button with transient "copied" / failed state. */
136
135
  function SessionRow({ session, current, t }) {
137
136
  const [status, setStatus] = (0, react.useState)("idle");
137
+ const idleTimer = (0, react.useRef)(void 0);
138
138
  const active = session.id === current;
139
139
  const title = session.displayTitle || session.id;
140
+ (0, react.useEffect)(() => {
141
+ return () => {
142
+ window.clearTimeout(idleTimer.current);
143
+ };
144
+ }, []);
140
145
  const handleCopy = () => {
146
+ window.clearTimeout(idleTimer.current);
141
147
  (0, _deepseek_ai_dsh_client_ui_primitives.writeClipboard)(session.id).then((ok) => {
142
148
  if (ok) {
143
149
  setStatus("copied");
144
- window.setTimeout(() => {
150
+ idleTimer.current = window.setTimeout(() => {
145
151
  setStatus("idle");
146
152
  }, 1200);
147
153
  } else setStatus("failed");
@@ -254,10 +260,10 @@ window.__ModuleLoader__.load({
254
260
  //#endregion
255
261
  //#region src/client/SessionIdEntry.tsx
256
262
  /**
257
- * Sidebar footer entry for the session-id plugin: the trigger beside the
258
- * sidebar settings seat (wide row / rail icon) that opens the session-id
259
- * panel. Registered into the official `sidebar.footer.action` list slot
260
- * (declared by ui-sidebar, same seat dsh-remote-web-ui shares).
263
+ * Sidebar footer entry for the session-id plugin: the icon-only trigger
264
+ * beside the sidebar settings seat (wide row / rail circle) that opens the
265
+ * session-id panel. Registered into the official `sidebar.footer.action`
266
+ * list slot (declared by ui-sidebar, same seat dsh-remote-web-ui shares).
261
267
  */
262
268
  /**
263
269
  * Render the session-id seat trigger and panel.
@@ -266,7 +272,7 @@ window.__ModuleLoader__.load({
266
272
  */
267
273
  function SessionIdEntry({ wide, list, t }) {
268
274
  const [open, setOpen] = (0, react.useState)(false);
269
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
275
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
270
276
  type: "button",
271
277
  className: session_id_module_css_default.trigger,
272
278
  "data-dsh-plugin": SESSION_ID_PLUGIN_ATTR,
@@ -277,10 +283,7 @@ window.__ModuleLoader__.load({
277
283
  onClick: () => {
278
284
  setOpen(true);
279
285
  },
280
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(SessionIdIcon, {}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
281
- className: session_id_module_css_default.triggerLabel,
282
- children: t("entry.label")
283
- })]
286
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(SessionIdIcon, {})
284
287
  }), open && (0, react_dom.createPortal)(/* @__PURE__ */ (0, react_jsx_runtime.jsx)(SessionIdPanel, {
285
288
  list,
286
289
  onClose: () => {
@@ -351,22 +354,32 @@ window.__ModuleLoader__.load({
351
354
  * @param ctx - client root context.
352
355
  */
353
356
  function apply(ctx) {
354
- ctx.effect(() => ctx.locale.register(NS, {
355
- zh,
356
- en
357
- }), "session-id: dictionaries");
357
+ ctx.effect(() => {
358
+ try {
359
+ return ctx.locale.register(NS, {
360
+ zh,
361
+ en
362
+ });
363
+ } catch {
364
+ return () => {};
365
+ }
366
+ }, "session-id: dictionaries");
358
367
  ctx.slots.inject("sidebar.footer.action", () => {
359
368
  const sessions = ctx.get("sessions");
360
369
  const list = {
361
370
  getSnapshot: () => sessions.list.getSnapshot(),
362
371
  subscribe: (fn) => sessions.list.subscribe(fn)
363
372
  };
364
- return ctx.slots.register({
365
- name: "sidebar.footer.action",
366
- id: ENTRY_ID,
367
- locale: NS,
368
- inject: () => ({ list })
369
- }, SessionIdEntry);
373
+ try {
374
+ return ctx.slots.register({
375
+ name: "sidebar.footer.action",
376
+ id: ENTRY_ID,
377
+ locale: NS,
378
+ inject: () => ({ list })
379
+ }, SessionIdEntry);
380
+ } catch {
381
+ return () => {};
382
+ }
370
383
  });
371
384
  }
372
385
  //#endregion
package/lib/client.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"client.js","names":["css","css"],"sources":["../../../packages/dsh-session-id/src/client/icons.tsx","../../../packages/dsh-session-id/src/client/semantic.ts","../../../packages/dsh-session-id/src/client/SessionIdPanel.tsx","../../../packages/dsh-session-id/src/client/SessionIdEntry.tsx","../../../packages/dsh-session-id/src/client/locales.ts","../../../packages/dsh-session-id/src/client/index.ts"],"sourcesContent":["/**\n * Inline SVG icons for the session-id plugin (16px stroke style matching the\n * shell's nav icons; sized via className where a smaller variant is needed).\n */\nimport type { SVGProps } from 'react'\n\n/** Shared svg attrs for the 16px stroke icon family. */\nfunction iconProps(props: SVGProps<SVGSVGElement>): SVGProps<SVGSVGElement> {\n return {\n width: 16,\n height: 16,\n viewBox: '0 0 16 16',\n fill: 'none',\n stroke: 'currentColor',\n strokeWidth: 1.3,\n strokeLinecap: 'round',\n strokeLinejoin: 'round',\n 'aria-hidden': true,\n ...props,\n }\n}\n\n/** An ID-card / identifier glyph for the seat trigger and panel title. */\nexport function SessionIdIcon(props: SVGProps<SVGSVGElement>) {\n return (\n <svg {...iconProps(props)}>\n <rect x=\"1.5\" y=\"3.5\" width=\"13\" height=\"9\" rx=\"1.5\" />\n <path d=\"M4 6.5h2M4 9h2M7.5 6.5h4.5M7.5 9h4.5\" />\n </svg>\n )\n}\n\n/** Copy glyph. */\nexport function CopyIcon(props: SVGProps<SVGSVGElement>) {\n return (\n <svg {...iconProps(props)}>\n <rect x=\"5.5\" y=\"5.5\" width=\"9\" height=\"9\" rx=\"1.5\" />\n <path d=\"M2.5 10.5v-7A1.5 1.5 0 0 1 4 2h5.5\" />\n </svg>\n )\n}\n\n/** Check glyph for the transient copied state. */\nexport function CheckIcon(props: SVGProps<SVGSVGElement>) {\n return (\n <svg {...iconProps(props)}>\n <path d=\"M3 8.5 6.5 12l6.5-8\" />\n </svg>\n )\n}\n\n/** Close glyph for the panel header. */\nexport function CloseIcon(props: SVGProps<SVGSVGElement>) {\n return (\n <svg {...iconProps(props)}>\n <path d=\"M4 4l8 8M12 4l-8 8\" />\n </svg>\n )\n}\n","/**\n * Semantic attribute values for the session-id plugin (contract:\n * skins/skin-center/contracts/semantic-attrs-v1.md). Root containers carry\n * `data-dsh-plugin`; parts carry bare `data-dsh-part` values owned by the\n * plugin attribute.\n */\n\n/** Plugin short name stamped on the root container and the footer trigger. */\nexport const SESSION_ID_PLUGIN_ATTR = 'session-id'\n\n/** The sidebar footer seat trigger. */\nexport const SESSION_ID_PART_ENTRY = 'entry'\n\n/** The modal panel root. */\nexport const SESSION_ID_PART_PANEL = 'panel'\n\n/** One session list row. */\nexport const SESSION_ID_PART_ROW = 'row'\n\n/** The per-row copy button. */\nexport const SESSION_ID_PART_COPY = 'copy'\n\n/** The panel search input. */\nexport const SESSION_ID_PART_SEARCH = 'search'","/**\n * Session ID panel — a centered modal listing every session with its full id\n * and a copy button. Data rides the injected `sessionList` observable\n * (ctx.sessions.list, see SessionRuntime.list) read through\n * useSyncExternalStore, so the panel stays in sync with host list updates and\n * needs no per-session runtime wiring.\n */\nimport { useSyncExternalStore, useState } from 'react'\nimport type { PropsLocale } from '@deepseek-ai/dsh-client-ui-slots'\nimport type { SessionListState, SessionSummary } from '@deepseek-ai/dsh-client-runtime/client'\nimport { writeClipboard } from '@deepseek-ai/dsh-client-ui-primitives'\nimport { SessionIdIcon, CheckIcon, CopyIcon, CloseIcon } from './icons.tsx'\nimport { SESSION_ID_PART_COPY, SESSION_ID_PART_PANEL, SESSION_ID_PART_ROW, SESSION_ID_PART_SEARCH, SESSION_ID_PLUGIN_ATTR } from './semantic.ts'\nimport css from './session-id.module.css'\n\n/** The sessions-list read face injected by the plugin (ObservableSnapshot). */\nexport type SessionListReadSource = {\n getSnapshot(): SessionListState\n subscribe(fn: () => void): () => void\n}\n\n/** Panel props: the list source + the locale seat. */\nexport type SessionIdPanelProps = PropsLocale<'session-id'> & {\n list: SessionListReadSource\n onClose: () => void\n}\n\n/** Short relative label for a session's update time (zh/en shared w/ locales). */\nfunction relativeTimeLabel(updatedAt: number, now: number, t: PropsLocale<'session-id'>['t']): string {\n const diff = Math.max(0, now - updatedAt)\n const minute = 60_000\n const hour = 60 * minute\n const day = 24 * hour\n if (diff < minute) return t('panel.updatedAt', { t: t('panel.time.now') })\n if (diff < hour) return t('panel.updatedAt', { t: t('panel.time.minutes', { n: Math.floor(diff / minute) }) })\n if (diff < day) return t('panel.updatedAt', { t: t('panel.time.hours', { n: Math.floor(diff / hour) }) })\n return t('panel.updatedAt', { t: t('panel.time.days', { n: Math.floor(diff / day) }) })\n}\n\n/** Sort sessions by update time, newest first; blank rows sink to the bottom. */\nfunction sortSessions(list: SessionListState): SessionSummary[] {\n const rows = list.ids\n .map(id => list.byId[id])\n .filter((row): row is SessionSummary => row !== undefined)\n return [...rows].sort((a, b) => {\n if (a.blank !== b.blank) return a.blank ? 1 : -1\n return b.updatedAt - a.updatedAt\n })\n}\n\n/** One session row: title + id + copy button with transient \"copied\" / failed state. */\nfunction SessionRow({ session, current, t }: {\n session: SessionSummary\n current: string | undefined\n t: PropsLocale<'session-id'>['t']\n}) {\n const [status, setStatus] = useState<'idle' | 'copied' | 'failed'>('idle')\n const active = session.id === current\n const title = session.displayTitle || session.id\n\n const handleCopy = (): void => {\n // Copy must be gesture-driven; a failed write surfaces an actionable\n // message instead of silently swallowing the error (no permission\n // requests, no background retry).\n void writeClipboard(session.id).then((ok) => {\n if (ok) {\n setStatus('copied')\n window.setTimeout(() => { setStatus('idle') }, 1200)\n } else {\n setStatus('failed')\n }\n }).catch(() => {\n // A rejected write is the same actionable failure as ok === false.\n setStatus('failed')\n })\n }\n\n const copyLabel = status === 'copied' ? t('panel.copied')\n : status === 'failed' ? t('panel.copyFailed') : t('panel.copy')\n\n return (\n <div className={css.row} data-dsh-part={SESSION_ID_PART_ROW}>\n <span className={css.rowInfo}>\n <span className={`${css.rowTitle}${active ? ` ${css.rowActive}` : ''}`} title={title}>\n {title}\n </span>\n {active && <span className={css.rowMeta}>{t('panel.current')}</span>}\n <span className={css.rowId} title={session.id}>{session.id}</span>\n </span>\n <button\n type=\"button\"\n className={css.copyButton}\n data-dsh-part={SESSION_ID_PART_COPY}\n data-copied={status === 'copied' ? 'true' : undefined}\n data-failed={status === 'failed' ? 'true' : undefined}\n aria-label={`${copyLabel} ${session.id}`}\n onClick={handleCopy}\n >\n {status === 'copied' ? <CheckIcon className={css.iconSmall} /> : <CopyIcon className={css.iconSmall} />}\n {copyLabel}\n </button>\n </div>\n )\n}\n\n/**\n * Render the session-id panel body.\n * @param props - injected list source + locale seat + close callback.\n * @returns the modal panel.\n */\nexport function SessionIdPanel({ list, onClose, t }: SessionIdPanelProps) {\n const snapshot = useSyncExternalStore(list.subscribe, list.getSnapshot)\n const sorted = sortSessions(snapshot)\n const [search, setSearch] = useState('')\n\n // Local, read-only filter over the already-visible list (title or id\n // substring, case-insensitive) — no host API, no disk, no other profile.\n const query = search.trim().toLowerCase()\n const rows = query === ''\n ? sorted\n : sorted.filter(row => row.displayTitle.toLowerCase().includes(query) || row.id.toLowerCase().includes(query))\n\n return (\n <div className={css.overlay} role=\"presentation\" data-dsh-plugin={SESSION_ID_PLUGIN_ATTR}>\n <div className={css.mask} aria-hidden=\"true\" onClick={onClose} />\n <div className={css.panel} data-dsh-part={SESSION_ID_PART_PANEL} role=\"dialog\" aria-modal=\"true\" aria-label={t('panel.title')}>\n <div className={css.header}>\n <div className={css.heading}>\n <h2 className={css.title}>{t('panel.title')}</h2>\n </div>\n <button\n type=\"button\"\n className={css.closeButton}\n aria-label={t('panel.close')}\n onClick={onClose}\n >\n <CloseIcon className={css.icon} />\n </button>\n </div>\n <input\n type=\"search\"\n className={css.search}\n data-dsh-part={SESSION_ID_PART_SEARCH}\n placeholder={t('panel.search.placeholder')}\n aria-label={t('panel.search.aria')}\n value={search}\n onChange={(event) => { setSearch(event.target.value) }}\n />\n {rows.length === 0 ? (\n <div className={css.empty}>{query === '' ? t('panel.empty') : t('panel.noMatches')}</div>\n ) : (\n <div className={css.list}>\n {rows.map(row => (\n <SessionRow key={row.id} session={row} current={snapshot.current} t={t} />\n ))}\n </div>\n )}\n </div>\n </div>\n )\n}\n","/**\n * Sidebar footer entry for the session-id plugin: the trigger beside the\n * sidebar settings seat (wide row / rail icon) that opens the session-id\n * panel. Registered into the official `sidebar.footer.action` list slot\n * (declared by ui-sidebar, same seat dsh-remote-web-ui shares).\n */\nimport { useState } from 'react'\nimport { createPortal } from 'react-dom'\nimport type { PropsLocale } from '@deepseek-ai/dsh-client-ui-slots'\nimport { SessionIdPanel, type SessionListReadSource } from './SessionIdPanel.tsx'\nimport { SESSION_ID_PART_ENTRY, SESSION_ID_PLUGIN_ATTR } from './semantic.ts'\nimport { SessionIdIcon } from './icons.tsx'\nimport css from './session-id.module.css'\n\n/** Entry props: the footer seat's column state + injected list source + locale seat. */\nexport type SessionIdEntryProps = PropsLocale<'session-id'> & {\n /** Whether the sidebar renders wide content (false = 56px rail). */\n wide: boolean\n /** The sessions-list read face (ctx.sessions.list wrapped by the plugin). */\n list: SessionListReadSource\n}\n\n/**\n * Render the session-id seat trigger and panel.\n * @param props - composed slot props.\n * @returns the trigger and, when open, the panel portal.\n */\nexport function SessionIdEntry({ wide, list, t }: SessionIdEntryProps) {\n const [open, setOpen] = useState(false)\n\n const trigger = (\n <button\n type=\"button\"\n className={css.trigger}\n data-dsh-plugin={SESSION_ID_PLUGIN_ATTR}\n data-dsh-part={SESSION_ID_PART_ENTRY}\n data-wide={wide ? 'wide' : 'rail'}\n aria-label={t('entry.label')}\n title={t('entry.label')}\n onClick={() => { setOpen(true) }}\n >\n <SessionIdIcon />\n <span className={css.triggerLabel}>{t('entry.label')}</span>\n </button>\n )\n\n return (\n <>\n {trigger}\n {open && createPortal(\n <SessionIdPanel list={list} onClose={() => { setOpen(false) }} t={t} />,\n document.body,\n )}\n </>\n )\n}\n","/**\n * Locale dictionaries for the session-id plugin. `zh` is the key-set source of\n * truth; `en` keeps a full key-for-key mirror (packages/AGENTS.md bilingual\n * rules). Registered through ctx.locale.register(NS, { zh, en }).\n */\n\n/** Simplified Chinese dictionary (key-set source of truth). */\nexport const zh = {\n 'entry.label': '会话 ID',\n 'panel.title': '会话 ID',\n 'panel.empty': '暂无会话',\n 'panel.noMatches': '无匹配会话',\n 'panel.search.placeholder': '搜索标题或 ID…',\n 'panel.search.aria': '搜索会话',\n 'panel.close': '关闭',\n 'panel.copy': '复制',\n 'panel.copied': '已复制',\n 'panel.copyFailed': '复制失败,请重试',\n 'panel.current': '当前',\n 'panel.updatedAt': '更新于 {t}',\n 'panel.time.now': '刚刚',\n 'panel.time.minutes': '{n} 分钟前',\n 'panel.time.hours': '{n} 小时前',\n 'panel.time.days': '{n} 天前',\n}\n\n/** The session-id namespace key union. */\nexport type SessionIdKey = keyof typeof zh\n\n/** English dictionary, key-for-key complete against zh. */\nexport const en: Record<SessionIdKey, string> = {\n 'entry.label': 'Session ID',\n 'panel.title': 'Session IDs',\n 'panel.empty': 'No sessions',\n 'panel.noMatches': 'No matching sessions',\n 'panel.search.placeholder': 'Search title or ID…',\n 'panel.search.aria': 'Search sessions',\n 'panel.close': 'Close',\n 'panel.copy': 'Copy',\n 'panel.copied': 'Copied',\n 'panel.copyFailed': 'Copy failed, retry',\n 'panel.current': 'Current',\n 'panel.updatedAt': 'Updated {t}',\n 'panel.time.now': 'just now',\n 'panel.time.minutes': '{n}m ago',\n 'panel.time.hours': '{n}h ago',\n 'panel.time.days': '{n}d ago',\n}","/**\n * Session-id plugin — browser half. Registers the `session-id` dictionaries\n * and the sidebar-foot trigger (into the ui-sidebar-declared\n * `sidebar.footer.action` list slot) that opens the session-id panel. The\n * panel lists every session with its full id and a copy button.\n *\n * Export discipline (packages/AGENTS.md): the /client surface carries only\n * what cordis loading needs plus types.\n */\nimport type { ClientContext, ISessions } from '@deepseek-ai/dsh-client-runtime/client'\n// Type-only: pulls the locale plugin's Context merge (ctx.locale) and its\n// LocaleNamespaceMap merge table.\nimport type {} from '@deepseek-ai/dsh-client-locale/client'\n// Type-only: pulls the ui-sidebar SlotMap merge (the 'sidebar.footer.action' hole).\nimport type {} from '@deepseek-ai/dsh-client-ui-sidebar/client'\nimport { SessionIdEntry } from './SessionIdEntry.tsx'\nimport { en, zh, type SessionIdKey } from './locales.ts'\n\ndeclare module '@deepseek-ai/dsh-client-ui-slots' {\n interface LocaleNamespaceMap {\n /** Session-id surface copy. */\n 'session-id': SessionIdKey\n }\n}\n\n/** Dictionary namespace owned by this plugin. */\nconst NS = 'session-id'\n\n/** Unique occupant id inside the shared footer.action list slot. */\nconst ENTRY_ID = 'session-id'\n\n/** Services required by this plugin. */\nexport const inject = ['slots', 'locale', 'sessions']\n\n/**\n * Register the session-id surface.\n * @param ctx - client root context.\n */\nexport function apply(ctx: ClientContext): void {\n ctx.effect(() => ctx.locale.register(NS, { zh, en }), 'session-id: dictionaries')\n\n // Sidebar foot entry. The shell declares 'sidebar.footer.action' (list kind:\n // multiple occupants may share the seat); registration is declaration-aware\n // via slots.inject. The list read face (ctx.sessions.list) is injected as a\n // plain prop so the component can subscribe without per-session wiring.\n ctx.slots.inject('sidebar.footer.action', () => {\n // Read the browser sessions face explicitly (combined host/client program\n // shares the Cordis Context name; the explicit face keeps types correct).\n const sessions = ctx.get('sessions') as unknown as ISessions\n const list = {\n getSnapshot: () => sessions.list.getSnapshot(),\n subscribe: (fn: () => void) => sessions.list.subscribe(fn),\n }\n return ctx.slots.register({\n name: 'sidebar.footer.action',\n id: ENTRY_ID,\n locale: NS,\n inject: () => ({ list }),\n }, SessionIdEntry)\n })\n}\n\nexport type { SessionIdEntryProps } from './SessionIdEntry.tsx'\nexport type { SessionIdKey } from './locales.ts'\nexport type { SessionListReadSource, SessionIdPanelProps } from './SessionIdPanel.tsx'\n"],"mappings":";;;;;;;;;;;;EAOA,SAAS,UAAU,OAAyD;GAC1E,OAAO;IACL,OAAO;IACP,QAAQ;IACR,SAAS;IACT,MAAM;IACN,QAAQ;IACR,aAAa;IACb,eAAe;IACf,gBAAgB;IAChB,eAAe;IACf,GAAG;GACL;EACF;;EAGA,SAAgB,cAAc,OAAgC;GAC5D,OACE,iBAAA,GAAA,kBAAA,KAAA,CAAC,OAAD;IAAK,GAAI,UAAU,KAAK;cAAxB,CACE,iBAAA,GAAA,kBAAA,IAAA,CAAC,QAAD;KAAM,GAAE;KAAM,GAAE;KAAM,OAAM;KAAK,QAAO;KAAI,IAAG;IAAO,CAAA,GACtD,iBAAA,GAAA,kBAAA,IAAA,CAAC,QAAD,EAAM,GAAE,uCAAwC,CAAA,CAC7C;;EAET;;EAGA,SAAgB,SAAS,OAAgC;GACvD,OACE,iBAAA,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CACrD;IAKC,GACN,SAAA,GAAA,UAAA,aAAA,CACC,iBAAA,GAAA,kBAAA,IAAA,CAAC,gBAAD;IAAsB;IAAM,eAAe;KAAE,QAAQ,KAAK;IAAE;IAAM;GAAI,CAAA,GACtE,SAAS,IACX,CACA,EAAA,CAAA;EAEN;;;;;;;;;EChDA,MAAa,KAAK;GAChB,eAAe;GACf,eAAe;GACf,eAAe;GACf,mBAAmB;GACnB,4BAA4B;GAC5B,qBAAqB;GACrB,eAAe;GACf,cAAc;GACd,gBAAgB;GAChB,oBAAoB;GACpB,iBAAiB;GACjB,mBAAmB;GACnB,kBAAkB;GAClB,sBAAsB;GACtB,oBAAoB;GACpB,mBAAmB;EACrB;;EAMA,MAAa,KAAmC;GAC9C,eAAe;GACf,eAAe;GACf,eAAe;GACf,mBAAmB;GACnB,4BAA4B;GAC5B,qBAAqB;GACrB,eAAe;GACf,cAAc;GACd,gBAAgB;GAChB,oBAAoB;GACpB,iBAAiB;GACjB,mBAAmB;GACnB,kBAAkB;GAClB,sBAAsB;GACtB,oBAAoB;GACpB,mBAAmB;EACrB;;;;ECrBA,MAAM,KAAK;;EAGX,MAAM,WAAW;;EAGjB,MAAa,SAAS;GAAC;GAAS;GAAU;EAAU;;;;;EAMpD,SAAgB,MAAM,KAA0B;GAC9C,IAAI,aAAa,IAAI,OAAO,SAAS,IAAI;IAAE;IAAI;GAAG,CAAC,GAAG,0BAA0B;GAMhF,IAAI,MAAM,OAAO,+BAA+B;IAG9C,MAAM,WAAW,IAAI,IAAI,UAAU;IACnC,MAAM,OAAO;KACX,mBAAmB,SAAS,KAAK,YAAY;KAC7C,YAAY,OAAmB,SAAS,KAAK,UAAU,EAAE;IAC3D;IACA,OAAO,IAAI,MAAM,SAAS;KACxB,MAAM;KACN,IAAI;KACJ,QAAQ;KACR,eAAe,EAAE,KAAK;IACxB,GAAG,cAAc;GACnB,CAAC;EACH"}
1
+ {"version":3,"file":"client.js","names":["css","css"],"sources":["../../../packages/dsh-session-id/src/client/icons.tsx","../../../packages/dsh-session-id/src/client/semantic.ts","../../../packages/dsh-session-id/src/client/SessionIdPanel.tsx","../../../packages/dsh-session-id/src/client/SessionIdEntry.tsx","../../../packages/dsh-session-id/src/client/locales.ts","../../../packages/dsh-session-id/src/client/index.ts"],"sourcesContent":["/**\n * Inline SVG icons for the session-id plugin (16px stroke style matching the\n * shell's nav icons; sized via className where a smaller variant is needed).\n */\nimport type { SVGProps } from 'react'\n\n/** Shared svg attrs for the 16px stroke icon family. */\nfunction iconProps(props: SVGProps<SVGSVGElement>): SVGProps<SVGSVGElement> {\n return {\n width: 16,\n height: 16,\n viewBox: '0 0 16 16',\n fill: 'none',\n stroke: 'currentColor',\n strokeWidth: 1.3,\n strokeLinecap: 'round',\n strokeLinejoin: 'round',\n 'aria-hidden': true,\n ...props,\n }\n}\n\n/** An ID-card / identifier glyph for the seat trigger and panel title. */\nexport function SessionIdIcon(props: SVGProps<SVGSVGElement>) {\n return (\n <svg {...iconProps(props)}>\n <rect x=\"1.5\" y=\"3.5\" width=\"13\" height=\"9\" rx=\"1.5\" />\n <path d=\"M4 6.5h2M4 9h2M7.5 6.5h4.5M7.5 9h4.5\" />\n </svg>\n )\n}\n\n/** Copy glyph. */\nexport function CopyIcon(props: SVGProps<SVGSVGElement>) {\n return (\n <svg {...iconProps(props)}>\n <rect x=\"5.5\" y=\"5.5\" width=\"9\" height=\"9\" rx=\"1.5\" />\n <path d=\"M2.5 10.5v-7A1.5 1.5 0 0 1 4 2h5.5\" />\n </svg>\n )\n}\n\n/** Check glyph for the transient copied state. */\nexport function CheckIcon(props: SVGProps<SVGSVGElement>) {\n return (\n <svg {...iconProps(props)}>\n <path d=\"M3 8.5 6.5 12l6.5-8\" />\n </svg>\n )\n}\n\n/** Close glyph for the panel header. */\nexport function CloseIcon(props: SVGProps<SVGSVGElement>) {\n return (\n <svg {...iconProps(props)}>\n <path d=\"M4 4l8 8M12 4l-8 8\" />\n </svg>\n )\n}\n","/**\n * Semantic attribute values for the session-id plugin (contract:\n * skins/skin-center/contracts/semantic-attrs-v1.md). Root containers carry\n * `data-dsh-plugin`; parts carry bare `data-dsh-part` values owned by the\n * plugin attribute.\n */\n\n/** Plugin short name stamped on the root container and the footer trigger. */\nexport const SESSION_ID_PLUGIN_ATTR = 'session-id'\n\n/** The sidebar footer seat trigger. */\nexport const SESSION_ID_PART_ENTRY = 'entry'\n\n/** The modal panel root. */\nexport const SESSION_ID_PART_PANEL = 'panel'\n\n/** One session list row. */\nexport const SESSION_ID_PART_ROW = 'row'\n\n/** The per-row copy button. */\nexport const SESSION_ID_PART_COPY = 'copy'\n\n/** The panel search input. */\nexport const SESSION_ID_PART_SEARCH = 'search'","/**\n * Session ID panel — a centered modal listing every session with its full id\n * and a copy button. Data rides the injected `sessionList` observable\n * (ctx.sessions.list, see SessionRuntime.list) read through\n * useSyncExternalStore, so the panel stays in sync with host list updates and\n * needs no per-session runtime wiring.\n */\nimport { useEffect, useRef, useSyncExternalStore, useState } from 'react'\nimport type { PropsLocale } from '@deepseek-ai/dsh-client-ui-slots'\nimport type { SessionListState, SessionSummary } from '@deepseek-ai/dsh-client-runtime/client'\nimport { writeClipboard } from '@deepseek-ai/dsh-client-ui-primitives'\nimport { CheckIcon, CopyIcon, CloseIcon } from './icons.tsx'\nimport { SESSION_ID_PART_COPY, SESSION_ID_PART_PANEL, SESSION_ID_PART_ROW, SESSION_ID_PART_SEARCH, SESSION_ID_PLUGIN_ATTR } from './semantic.ts'\nimport css from './session-id.module.css'\n\n/** The sessions-list read face injected by the plugin (ObservableSnapshot). */\nexport type SessionListReadSource = {\n getSnapshot(): SessionListState\n subscribe(fn: () => void): () => void\n}\n\n/** Panel props: the list source + the locale seat. */\nexport type SessionIdPanelProps = PropsLocale<'session-id'> & {\n list: SessionListReadSource\n onClose: () => void\n}\n\n/** Short relative label for a session's update time (zh/en shared w/ locales). */\nfunction relativeTimeLabel(updatedAt: number, now: number, t: PropsLocale<'session-id'>['t']): string {\n const diff = Math.max(0, now - updatedAt)\n const minute = 60_000\n const hour = 60 * minute\n const day = 24 * hour\n if (diff < minute) return t('panel.updatedAt', { t: t('panel.time.now') })\n if (diff < hour) return t('panel.updatedAt', { t: t('panel.time.minutes', { n: Math.floor(diff / minute) }) })\n if (diff < day) return t('panel.updatedAt', { t: t('panel.time.hours', { n: Math.floor(diff / hour) }) })\n return t('panel.updatedAt', { t: t('panel.time.days', { n: Math.floor(diff / day) }) })\n}\n\n/** Sort sessions by update time, newest first; blank rows sink to the bottom. */\nfunction sortSessions(list: SessionListState): SessionSummary[] {\n const rows = list.ids\n .map(id => list.byId[id])\n .filter((row): row is SessionSummary => row !== undefined)\n return [...rows].sort((a, b) => {\n if (a.blank !== b.blank) return a.blank ? 1 : -1\n return b.updatedAt - a.updatedAt\n })\n}\n\n/** One session row: title + id + copy button with transient \"copied\" / failed state. */\nfunction SessionRow({ session, current, t }: {\n session: SessionSummary\n current: string | undefined\n t: PropsLocale<'session-id'>['t']\n}) {\n const [status, setStatus] = useState<'idle' | 'copied' | 'failed'>('idle')\n const idleTimer = useRef<number | undefined>(undefined)\n const active = session.id === current\n const title = session.displayTitle || session.id\n\n // A pending reset timer belongs to the previous copy; drop it when the row\n // leaves the DOM so nothing keeps running after unmount.\n useEffect(() => {\n return () => { window.clearTimeout(idleTimer.current) }\n }, [])\n\n const handleCopy = (): void => {\n // Clear the previous reset before a new write so rapid repeated clicks\n // never stack timers (only the latest copy reaches the idle reset).\n window.clearTimeout(idleTimer.current)\n // Copy must be gesture-driven; a failed write surfaces an actionable\n // message instead of silently swallowing the error (no permission\n // requests, no background retry).\n void writeClipboard(session.id).then((ok) => {\n if (ok) {\n setStatus('copied')\n idleTimer.current = window.setTimeout(() => { setStatus('idle') }, 1200)\n } else {\n setStatus('failed')\n }\n }).catch(() => {\n // A rejected write is the same actionable failure as ok === false.\n setStatus('failed')\n })\n }\n\n const copyLabel = status === 'copied' ? t('panel.copied')\n : status === 'failed' ? t('panel.copyFailed') : t('panel.copy')\n\n return (\n <div className={css.row} data-dsh-part={SESSION_ID_PART_ROW}>\n <span className={css.rowInfo}>\n <span className={`${css.rowTitle}${active ? ` ${css.rowActive}` : ''}`} title={title}>\n {title}\n </span>\n {active && <span className={css.rowMeta}>{t('panel.current')}</span>}\n <span className={css.rowId} title={session.id}>{session.id}</span>\n </span>\n <button\n type=\"button\"\n className={css.copyButton}\n data-dsh-part={SESSION_ID_PART_COPY}\n data-copied={status === 'copied' ? 'true' : undefined}\n data-failed={status === 'failed' ? 'true' : undefined}\n aria-label={`${copyLabel} ${session.id}`}\n onClick={handleCopy}\n >\n {status === 'copied' ? <CheckIcon className={css.iconSmall} /> : <CopyIcon className={css.iconSmall} />}\n {copyLabel}\n </button>\n </div>\n )\n}\n\n/**\n * Render the session-id panel body.\n * @param props - injected list source + locale seat + close callback.\n * @returns the modal panel.\n */\nexport function SessionIdPanel({ list, onClose, t }: SessionIdPanelProps) {\n const snapshot = useSyncExternalStore(list.subscribe, list.getSnapshot)\n const sorted = sortSessions(snapshot)\n const [search, setSearch] = useState('')\n\n // Local, read-only filter over the already-visible list (title or id\n // substring, case-insensitive) — no host API, no disk, no other profile.\n const query = search.trim().toLowerCase()\n const rows = query === ''\n ? sorted\n : sorted.filter(row => row.displayTitle.toLowerCase().includes(query) || row.id.toLowerCase().includes(query))\n\n return (\n <div className={css.overlay} role=\"presentation\" data-dsh-plugin={SESSION_ID_PLUGIN_ATTR}>\n <div className={css.mask} aria-hidden=\"true\" onClick={onClose} />\n <div className={css.panel} data-dsh-part={SESSION_ID_PART_PANEL} role=\"dialog\" aria-modal=\"true\" aria-label={t('panel.title')}>\n <div className={css.header}>\n <div className={css.heading}>\n <h2 className={css.title}>{t('panel.title')}</h2>\n </div>\n <button\n type=\"button\"\n className={css.closeButton}\n aria-label={t('panel.close')}\n onClick={onClose}\n >\n <CloseIcon className={css.icon} />\n </button>\n </div>\n <input\n type=\"search\"\n className={css.search}\n data-dsh-part={SESSION_ID_PART_SEARCH}\n placeholder={t('panel.search.placeholder')}\n aria-label={t('panel.search.aria')}\n value={search}\n onChange={(event) => { setSearch(event.target.value) }}\n />\n {rows.length === 0 ? (\n <div className={css.empty}>{query === '' ? t('panel.empty') : t('panel.noMatches')}</div>\n ) : (\n <div className={css.list}>\n {rows.map(row => (\n <SessionRow key={row.id} session={row} current={snapshot.current} t={t} />\n ))}\n </div>\n )}\n </div>\n </div>\n )\n}\n","/**\n * Sidebar footer entry for the session-id plugin: the icon-only trigger\n * beside the sidebar settings seat (wide row / rail circle) that opens the\n * session-id panel. Registered into the official `sidebar.footer.action`\n * list slot (declared by ui-sidebar, same seat dsh-remote-web-ui shares).\n */\nimport { useState } from 'react'\nimport { createPortal } from 'react-dom'\nimport type { PropsLocale } from '@deepseek-ai/dsh-client-ui-slots'\nimport { SessionIdPanel, type SessionListReadSource } from './SessionIdPanel.tsx'\nimport { SESSION_ID_PART_ENTRY, SESSION_ID_PLUGIN_ATTR } from './semantic.ts'\nimport { SessionIdIcon } from './icons.tsx'\nimport css from './session-id.module.css'\n\n/** Entry props: the footer seat's column state + injected list source + locale seat. */\nexport type SessionIdEntryProps = PropsLocale<'session-id'> & {\n /** Whether the sidebar renders wide content (false = 56px rail). */\n wide: boolean\n /** The sessions-list read face (ctx.sessions.list wrapped by the plugin). */\n list: SessionListReadSource\n}\n\n/**\n * Render the session-id seat trigger and panel.\n * @param props - composed slot props.\n * @returns the trigger and, when open, the panel portal.\n */\nexport function SessionIdEntry({ wide, list, t }: SessionIdEntryProps) {\n const [open, setOpen] = useState(false)\n\n const trigger = (\n <button\n type=\"button\"\n className={css.trigger}\n data-dsh-plugin={SESSION_ID_PLUGIN_ATTR}\n data-dsh-part={SESSION_ID_PART_ENTRY}\n data-wide={wide ? 'wide' : 'rail'}\n aria-label={t('entry.label')}\n title={t('entry.label')}\n onClick={() => { setOpen(true) }}\n >\n <SessionIdIcon />\n </button>\n )\n\n return (\n <>\n {trigger}\n {open && createPortal(\n <SessionIdPanel list={list} onClose={() => { setOpen(false) }} t={t} />,\n document.body,\n )}\n </>\n )\n}\n","/**\n * Locale dictionaries for the session-id plugin. `zh` is the key-set source of\n * truth; `en` keeps a full key-for-key mirror (packages/AGENTS.md bilingual\n * rules). Registered through ctx.locale.register(NS, { zh, en }).\n */\n\n/** Simplified Chinese dictionary (key-set source of truth). */\nexport const zh = {\n 'entry.label': '会话 ID',\n 'panel.title': '会话 ID',\n 'panel.empty': '暂无会话',\n 'panel.noMatches': '无匹配会话',\n 'panel.search.placeholder': '搜索标题或 ID…',\n 'panel.search.aria': '搜索会话',\n 'panel.close': '关闭',\n 'panel.copy': '复制',\n 'panel.copied': '已复制',\n 'panel.copyFailed': '复制失败,请重试',\n 'panel.current': '当前',\n 'panel.updatedAt': '更新于 {t}',\n 'panel.time.now': '刚刚',\n 'panel.time.minutes': '{n} 分钟前',\n 'panel.time.hours': '{n} 小时前',\n 'panel.time.days': '{n} 天前',\n}\n\n/** The session-id namespace key union. */\nexport type SessionIdKey = keyof typeof zh\n\n/** English dictionary, key-for-key complete against zh. */\nexport const en: Record<SessionIdKey, string> = {\n 'entry.label': 'Session ID',\n 'panel.title': 'Session IDs',\n 'panel.empty': 'No sessions',\n 'panel.noMatches': 'No matching sessions',\n 'panel.search.placeholder': 'Search title or ID…',\n 'panel.search.aria': 'Search sessions',\n 'panel.close': 'Close',\n 'panel.copy': 'Copy',\n 'panel.copied': 'Copied',\n 'panel.copyFailed': 'Copy failed, retry',\n 'panel.current': 'Current',\n 'panel.updatedAt': 'Updated {t}',\n 'panel.time.now': 'just now',\n 'panel.time.minutes': '{n}m ago',\n 'panel.time.hours': '{n}h ago',\n 'panel.time.days': '{n}d ago',\n}","/**\n * Session-id plugin — browser half. Registers the `session-id` dictionaries\n * and the sidebar-foot trigger (into the ui-sidebar-declared\n * `sidebar.footer.action` list slot) that opens the session-id panel. The\n * panel lists every session with its full id and a copy button.\n *\n * Export discipline (packages/AGENTS.md): the /client surface carries only\n * what cordis loading needs plus types.\n */\nimport type { ClientContext, ISessions } from '@deepseek-ai/dsh-client-runtime/client'\n// Type-only: pulls the locale plugin's Context merge (ctx.locale) and its\n// LocaleNamespaceMap merge table.\nimport type {} from '@deepseek-ai/dsh-client-locale/client'\n// Type-only: pulls the ui-sidebar SlotMap merge (the 'sidebar.footer.action' hole).\nimport type {} from '@deepseek-ai/dsh-client-ui-sidebar/client'\nimport { SessionIdEntry } from './SessionIdEntry.tsx'\nimport { en, zh, type SessionIdKey } from './locales.ts'\n\ndeclare module '@deepseek-ai/dsh-client-ui-slots' {\n interface LocaleNamespaceMap {\n /** Session-id surface copy. */\n 'session-id': SessionIdKey\n }\n}\n\n/** Dictionary namespace owned by this plugin. */\nconst NS = 'session-id'\n\n/** Unique occupant id inside the shared footer.action list slot. */\nconst ENTRY_ID = 'session-id'\n\n/** Services required by this plugin. */\nexport const inject = ['slots', 'locale', 'sessions']\n\n/**\n * Register the session-id surface.\n * @param ctx - client root context.\n */\nexport function apply(ctx: ClientContext): void {\n ctx.effect(() => {\n try {\n return ctx.locale.register(NS, { zh, en })\n } catch {\n return () => {}\n }\n }, 'session-id: dictionaries')\n\n // Sidebar foot entry. The shell declares 'sidebar.footer.action' (list kind:\n // multiple occupants may share the seat); registration is declaration-aware\n // via slots.inject. The list read face (ctx.sessions.list) is injected as a\n // plain prop so the component can subscribe without per-session wiring.\n ctx.slots.inject('sidebar.footer.action', () => {\n // Read the browser sessions face explicitly (combined host/client program\n // shares the Cordis Context name; the explicit face keeps types correct).\n const sessions = ctx.get('sessions') as unknown as ISessions\n const list = {\n getSnapshot: () => sessions.list.getSnapshot(),\n subscribe: (fn: () => void) => sessions.list.subscribe(fn),\n }\n try {\n return ctx.slots.register({\n name: 'sidebar.footer.action',\n id: ENTRY_ID,\n locale: NS,\n inject: () => ({ list }),\n }, SessionIdEntry)\n } catch {\n return () => {}\n }\n })\n}\n\nexport type { SessionIdEntryProps } from './SessionIdEntry.tsx'\nexport type { SessionIdKey } from './locales.ts'\nexport type { SessionListReadSource, SessionIdPanelProps }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gB;GAChB,oBAAoB;GACpB,iBAAiB;GACjB,mBAAmB;GACnB,kBAAkB;GAClB,sBAAsB;GACtB,oBAAoB;GACpB,mBAAmB;EACrB;;;;ECrBA,MAAM,KAAK;;EAGX,MAAM,WAAW;;EAGjB,MAAa,SAAS;GAAC;GAAS;GAAU;EAAU;;;;;EAMpD,SAAgB,MAAM,KAA0B;GAC9C,IAAI,aAAa;IACf,IAAI;KACF,OAAO,IAAI,OAAO,SAAS,IAAI;MAAE;MAAI;KAAG,CAAC;IAC3C,QAAQ;KACN,aAAa,CAAC;IAChB;GACF,GAAG,0BAA0B;GAM7B,IAAI,MAAM,OAAO,+BAA+B;IAG9C,MAAM,WAAW,IAAI,IAAI,UAAU;IACnC,MAAM,OAAO;KACX,mBAAmB,SAAS,KAAK,YAAY;KAC7C,YAAY,OAAmB,SAAS,KAAK,UAAU,EAAE;IAC3D;IACA,IAAI;KACF,OAAO,IAAI,MAAM,SAAS;MACxB,MAAM;MACN,IAAI;MACJ,QAAQ;MACR,eAAe,EAAE,KAAK;KACxB,GAAG,cAAc;IACnB,QAAQ;KACN,aAAa,CAAC;IAChB;GACF,CAAC;EACH"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@linxin666/dsh-client-ui-session-id",
3
3
  "description": "DSH web GUI plugin: sidebar-foot Session ID panel listing every session with its full id and one-click copy (browser-only; no source changes).",
4
- "version": "0.2.9",
4
+ "version": "0.3.1",
5
5
  "type": "module",
6
6
  "main": "lib/index.js",
7
7
  "types": "lib/types/index.d.ts",