dsh-bots 0.2.25 → 0.2.27

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.
Files changed (2) hide show
  1. package/lib/client.js +15 -6
  2. package/package.json +1 -1
package/lib/client.js CHANGED
@@ -289,7 +289,8 @@
289
289
  row on hover and shrink it on leave — width/height jitter the user read
290
290
  as flicker. Fixed 30px row + always-laid-out actions = zero geometry
291
291
  change; the same trick the native headerActions uses (max-width/opacity). */
292
- .dbs-secHead{position:relative;cursor:pointer;border-radius:8px;height:30px}
292
+ .dbs-secHead{position:relative;cursor:pointer;border-radius:8px;height:30px;margin-bottom:4px}
293
+ .dbs-secGroup+.dbs-secGroup{margin-top:10px}
293
294
  .dbs-secHead:hover{background:var(--dsw-alias-interactive-bg-hover)}
294
295
  .dbs-secHead .dbs-rowActions{display:inline-flex;visibility:hidden;opacity:0;pointer-events:none;transition:opacity .12s ease-out}
295
296
  .dbs-secHead:hover .dbs-rowActions,.dbs-secHead:focus-within .dbs-rowActions,.dbs-secHead[data-menu="true"] .dbs-rowActions{visibility:visible;opacity:1;pointer-events:auto}
@@ -1167,7 +1168,7 @@
1167
1168
  * are: creating the first bot or group never requires a trip to the
1168
1169
  * footer. `addAction` opens the same system-style modal as before.
1169
1170
  */
1170
- function sectionRows(label, list, addAction, menuKind, menuItems) {
1171
+ function sectionRows(label, list, addAction, menuKind, menuItems, icon) {
1171
1172
  const menuOpen = s.sectionMenu === menuKind;
1172
1173
  // Group-header collapse contract, mirrored from 「工作区|Bots」:
1173
1174
  // chevron + whole-row click toggle, body suppressed when closed.
@@ -1175,7 +1176,7 @@
1175
1176
  const toggle = () => {
1176
1177
  patch({ sectionMenu: null, sectionsOpen: { ...(s.sectionsOpen ?? {}), [menuKind]: !isOpen } });
1177
1178
  };
1178
- return e('div', { key: label }, e('div', {
1179
+ return e('div', { key: label, className: 'dbs-secGroup' }, e('div', {
1179
1180
  className: 'dbs-navBodyErr dbs-secHead', role: 'button', tabIndex: 0, 'aria-expanded': isOpen,
1180
1181
  'data-menu': menuOpen ? 'true' : 'false',
1181
1182
  // Native sectionHeader outdent: label at x=16 (12 sidebar
@@ -1188,7 +1189,7 @@
1188
1189
  ev.preventDefault();
1189
1190
  toggle();
1190
1191
  } },
1191
- }, e(Chevron, { open: isOpen }), e('span', { style: { flex: 1 } }, label),
1192
+ }, e(Chevron, { open: isOpen }), e('span', { className: 'dbs-slot' }, icon), e('span', { style: { flex: 1 } }, label),
1192
1193
  // Native workspace pattern: header actions appear on hover
1193
1194
  // (.dbs-rowActions is hover-gated in .dbs-secHead CSS); their
1194
1195
  // clicks must not fold the section with them.
@@ -1225,7 +1226,7 @@
1225
1226
  }, 'groups', [
1226
1227
  { label: t('group.new'), onClick: () => patch({ create: 'group', createName: '', createMembers: {}, createWorking: false, error: null }) },
1227
1228
  { label: t('list.refresh'), onClick: () => { void refreshAgents(); } },
1228
- ])
1229
+ ], e(PeopleGlyph, null))
1229
1230
  : null, s.agentsLoaded
1230
1231
  ? sectionRows(t('section.singles'), singles, {
1231
1232
  title: t('bot.new'),
@@ -1233,7 +1234,7 @@
1233
1234
  }, 'singles', [
1234
1235
  { label: t('bot.new'), onClick: () => patch({ create: 'bot', createName: '', createDesc: '', createWorking: false, error: null }) },
1235
1236
  { label: t('list.refresh'), onClick: () => { void refreshAgents(); } },
1236
- ])
1237
+ ], Ico('IconUserOutline16', { size: 14 }))
1237
1238
  : null);
1238
1239
  }
1239
1240
  // =========================================================
@@ -1482,6 +1483,14 @@
1482
1483
  return null;
1483
1484
  return e('div', { className: 'dbs-mediaRefs' }, imgs.map((r) => e(MediaImage, { key: r, path: r })), files.map((r) => e(FileChip, { key: r, path: r })));
1484
1485
  }
1486
+ /**
1487
+ * Two-person glyph for the 群聊 section: the primitives set has no
1488
+ * group icon (verified against the shell bundle), so this follows the
1489
+ * inline-SVG policy used by SettingsGlyph — 1.5px outline strokes.
1490
+ */
1491
+ function PeopleGlyph() {
1492
+ return e('svg', { viewBox: '0 0 16 16', width: '14', height: '14', 'aria-hidden': true }, e('g', { fill: 'none', stroke: 'currentColor', strokeWidth: 1.5, strokeLinecap: 'round' }, e('circle', { cx: 6.1, cy: 5.1, r: 2.6 }), e('path', { d: 'M1.7 13.6c0-2.8 2-4.8 4.4-4.8s4.4 2 4.4 4.8' }), e('path', { d: 'M10.7 2.9a2.7 2.7 0 0 1 0 4.6' }), e('path', { d: 'M11.9 9.1c1.6.7 2.6 2.3 2.6 4.5' })));
1493
+ }
1485
1494
  /**
1486
1495
  * Settings glyph — three sliders, drawn inline (the primitives package
1487
1496
  * exposes no verified gear export; same policy as SendUpIcon).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dsh-bots",
3
- "version": "0.2.25",
3
+ "version": "0.2.27",
4
4
  "description": "Multi-bot workbench for DeepSeek Harness: bridges the sdk-bots orchestration gateway (group chats, single bots) into the dsh web shell with official-styled UI.",
5
5
  "type": "module",
6
6
  "main": "lib/index.js",