@senguoyun/dsh-arkme 0.1.70 → 0.1.72

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 (82) hide show
  1. package/docs/calendar-tooltip-regression-2026-09-20.md +25 -0
  2. package/docs/calls-retention-contacts-responsive-regression-2026-09-20.md +40 -0
  3. package/docs/composer-focus-regression-2026-09-20.md +38 -0
  4. package/docs/conversation-header-regression-2026-09-20.md +22 -0
  5. package/docs/desktop-regression-2026-09-19.md +10 -0
  6. package/docs/dsh-rightbar-regression-2026-09-21.md +38 -0
  7. package/docs/harness-activity.md +8 -0
  8. package/docs/harness-quick-create.md +18 -0
  9. package/docs/harness-session-dropdown.md +12 -0
  10. package/docs/my-day-calendar.md +42 -1
  11. package/docs/private-chat-actions.md +10 -0
  12. package/docs/private-interaction-directory-regression-2026-09-20.md +38 -0
  13. package/docs/quick-add-hover-regression-2026-09-21.md +29 -0
  14. package/lib/arko-native-client.js +83 -3
  15. package/lib/client.js +2170 -1211
  16. package/lib/client.js.map +1 -1
  17. package/lib/harness-model-client.js +9 -0
  18. package/lib/harness-native-selection-client.js +83 -3
  19. package/lib/harness-sidebar-client.js +131 -11
  20. package/lib/index.js +60 -1
  21. package/lib/persistent-extension.js +1 -1
  22. package/lib/{persistent-runtime-DxKHwHTw.js → persistent-runtime-Cb8xQ4w0.js} +210 -8
  23. package/lib/types/arkme-service.d.ts +18 -2
  24. package/lib/types/arkme-service.d.ts.map +1 -1
  25. package/lib/types/client/ArkmeCalendarDateTooltip.d.ts +8 -0
  26. package/lib/types/client/ArkmeCalendarDateTooltip.d.ts.map +1 -0
  27. package/lib/types/client/ArkmeCalendarSurface.d.ts.map +1 -1
  28. package/lib/types/client/ArkmeCallDetailContent.d.ts +2 -1
  29. package/lib/types/client/ArkmeCallDetailContent.d.ts.map +1 -1
  30. package/lib/types/client/ArkmeCallSurface.d.ts +2 -1
  31. package/lib/types/client/ArkmeCallSurface.d.ts.map +1 -1
  32. package/lib/types/client/ArkmeDayTimeline.d.ts.map +1 -1
  33. package/lib/types/client/ArkmeDshMenu.d.ts +2 -0
  34. package/lib/types/client/ArkmeDshMenu.d.ts.map +1 -1
  35. package/lib/types/client/ArkmeNoteDetails.d.ts +10 -2
  36. package/lib/types/client/ArkmeNoteDetails.d.ts.map +1 -1
  37. package/lib/types/client/ArkmePersonalDayCalendar.d.ts.map +1 -1
  38. package/lib/types/client/ArkmeQuickAdd.d.ts +3 -1
  39. package/lib/types/client/ArkmeQuickAdd.d.ts.map +1 -1
  40. package/lib/types/client/ArkmeRetainedCallPage.d.ts +5 -0
  41. package/lib/types/client/ArkmeRetainedCallPage.d.ts.map +1 -0
  42. package/lib/types/client/ArkmeSidebar.d.ts.map +1 -1
  43. package/lib/types/client/ArkmeSourceBreadcrumb.d.ts +3 -1
  44. package/lib/types/client/ArkmeSourceBreadcrumb.d.ts.map +1 -1
  45. package/lib/types/client/ArkmeVirtualWorkspace.d.ts +4 -0
  46. package/lib/types/client/ArkmeVirtualWorkspace.d.ts.map +1 -1
  47. package/lib/types/client/api.d.ts +1 -1
  48. package/lib/types/client/api.d.ts.map +1 -1
  49. package/lib/types/client/calendar-activity-model.d.ts +25 -1
  50. package/lib/types/client/calendar-activity-model.d.ts.map +1 -1
  51. package/lib/types/client/call-history-refresh.d.ts +5 -0
  52. package/lib/types/client/call-history-refresh.d.ts.map +1 -0
  53. package/lib/types/client/conversation-header-layout.d.ts +4 -0
  54. package/lib/types/client/conversation-header-layout.d.ts.map +1 -0
  55. package/lib/types/client/day-activity-presentation.d.ts +6 -0
  56. package/lib/types/client/day-activity-presentation.d.ts.map +1 -0
  57. package/lib/types/client/documented-day-activity-reader.d.ts +21 -0
  58. package/lib/types/client/documented-day-activity-reader.d.ts.map +1 -0
  59. package/lib/types/client/harness-session-dropdown.d.ts.map +1 -1
  60. package/lib/types/client/harness-surface-viewport.d.ts.map +1 -1
  61. package/lib/types/client/locales/dynamic-en.d.ts.map +1 -1
  62. package/lib/types/client/menu-hover-region.d.ts.map +1 -1
  63. package/lib/types/client/multisource-day-activity-reader.d.ts +10 -0
  64. package/lib/types/client/multisource-day-activity-reader.d.ts.map +1 -1
  65. package/lib/types/client/private-interaction-directory.d.ts +18 -0
  66. package/lib/types/client/private-interaction-directory.d.ts.map +1 -0
  67. package/lib/types/client/realtime-client-events.d.ts.map +1 -1
  68. package/lib/types/client/use-documented-day-month.d.ts +13 -0
  69. package/lib/types/client/use-documented-day-month.d.ts.map +1 -0
  70. package/lib/types/client/use-private-interaction-directory.d.ts +16 -0
  71. package/lib/types/client/use-private-interaction-directory.d.ts.map +1 -0
  72. package/lib/types/host-api.d.ts.map +1 -1
  73. package/lib/types/services/calendar-service.d.ts +15 -1
  74. package/lib/types/services/calendar-service.d.ts.map +1 -1
  75. package/lib/types/services/call-history-service.d.ts +4 -1
  76. package/lib/types/services/call-history-service.d.ts.map +1 -1
  77. package/lib/types/services/chat-service.d.ts.map +1 -1
  78. package/lib/types/services/interwoven-service.d.ts +2 -1
  79. package/lib/types/services/interwoven-service.d.ts.map +1 -1
  80. package/lib/types/types.d.ts +38 -1
  81. package/lib/types/types.d.ts.map +1 -1
  82. package/package.json +5 -5
@@ -1456,6 +1456,14 @@ Arkme 账号|Arkme account
1456
1456
  return [line.slice(0, index), line.slice(index + 1)];
1457
1457
  }));
1458
1458
  Object.fromEntries(`
1459
+ {v0} 条相关消息|{v0} related messages
1460
+ 录音 {v0}|Recorded {v0}
1461
+ 始于前一天|Started the previous day
1462
+ 延续至下一天|Continues into the next day
1463
+ 暂无内容预览,展开查看详情|No preview available. Expand for details
1464
+ 已有摘要:|Existing summary:
1465
+ 群互动同步暂未完成,点击重试|Group interactions could not sync. Click to retry
1466
+ 较早群互动暂未加载,点击重试|Earlier group interactions are not loaded. Click to retry
1459
1467
  {v0}的头像|Avatar of {v0}
1460
1468
  {v0} 的头像|Avatar of {v0}
1461
1469
  {v0}头像|Avatar of {v0}
@@ -1502,6 +1510,7 @@ Arkme 账号|Arkme account
1502
1510
  {v0} 像素|{v0} px
1503
1511
  来源:{v0}|Source: {v0}
1504
1512
  私聊 {v0} 条|{v0} direct messages
1513
+ 多来源活动|Activity from multiple sources
1505
1514
  群聊互动 {v0} 条|{v0} group interactions
1506
1515
  查看地点:{v0}|View location: {v0}
1507
1516
  查看小结来源:{v0}|View recap source: {v0}
@@ -3724,6 +3724,14 @@ Arkme 账号|Arkme account
3724
3724
  return [line.slice(0, index), line.slice(index + 1)];
3725
3725
  }));
3726
3726
  Object.fromEntries(`
3727
+ {v0} 条相关消息|{v0} related messages
3728
+ 录音 {v0}|Recorded {v0}
3729
+ 始于前一天|Started the previous day
3730
+ 延续至下一天|Continues into the next day
3731
+ 暂无内容预览,展开查看详情|No preview available. Expand for details
3732
+ 已有摘要:|Existing summary:
3733
+ 群互动同步暂未完成,点击重试|Group interactions could not sync. Click to retry
3734
+ 较早群互动暂未加载,点击重试|Earlier group interactions are not loaded. Click to retry
3727
3735
  {v0}的头像|Avatar of {v0}
3728
3736
  {v0} 的头像|Avatar of {v0}
3729
3737
  {v0}头像|Avatar of {v0}
@@ -3770,6 +3778,7 @@ Arkme 账号|Arkme account
3770
3778
  {v0} 像素|{v0} px
3771
3779
  来源:{v0}|Source: {v0}
3772
3780
  私聊 {v0} 条|{v0} direct messages
3781
+ 多来源活动|Activity from multiple sources
3773
3782
  群聊互动 {v0} 条|{v0} group interactions
3774
3783
  查看地点:{v0}|View location: {v0}
3775
3784
  查看小结来源:{v0}|View recap source: {v0}
@@ -4087,6 +4096,19 @@ Arkme 用户 {v0}|Arkme user {v0}
4087
4096
  top,
4088
4097
  bottom
4089
4098
  });
4099
+ const left = Math.max(anchor.left, menu.left), right = Math.min(anchor.right, menu.right);
4100
+ if (anchor.bottom <= menu.top && menu.top - anchor.bottom <= 24) return contains({
4101
+ left,
4102
+ right,
4103
+ top: anchor.bottom,
4104
+ bottom: menu.top
4105
+ });
4106
+ if (menu.bottom <= anchor.top && anchor.top - menu.bottom <= 24) return contains({
4107
+ left,
4108
+ right,
4109
+ top: menu.bottom,
4110
+ bottom: anchor.top
4111
+ });
4090
4112
  return false;
4091
4113
  }
4092
4114
  //#endregion
@@ -4270,6 +4292,37 @@ Arkme 用户 {v0}|Arkme user {v0}
4270
4292
  document.removeEventListener("keydown", onKey);
4271
4293
  };
4272
4294
  }, [open]);
4295
+ (0, react.useEffect)(() => {
4296
+ if (!open || typeof document === "undefined") return;
4297
+ const own = root.current?.ownerDocument ?? document;
4298
+ if (typeof own?.addEventListener !== "function") return;
4299
+ let pending;
4300
+ const cancel = () => {
4301
+ if (pending !== void 0) {
4302
+ clearTimeout(pending);
4303
+ pending = void 0;
4304
+ }
4305
+ };
4306
+ const outside = (event) => {
4307
+ const target = event.target;
4308
+ if (!(target instanceof Node)) return;
4309
+ if (root.current?.contains(target) === true) return;
4310
+ if (menu.current?.contains(target) === true) return;
4311
+ cancel();
4312
+ pending = setTimeout(() => {
4313
+ pending = void 0;
4314
+ closeRef.current();
4315
+ }, 0);
4316
+ };
4317
+ const arrived = () => cancel();
4318
+ own.addEventListener("pointerdown", outside, true);
4319
+ own.addEventListener("pointerdown", arrived);
4320
+ return () => {
4321
+ cancel();
4322
+ own.removeEventListener("pointerdown", outside, true);
4323
+ own.removeEventListener("pointerdown", arrived);
4324
+ };
4325
+ }, [open]);
4273
4326
  (0, react.useEffect)(() => {
4274
4327
  if (!open || !props.point || typeof document === "undefined" || typeof document.createElement !== "function") return;
4275
4328
  const doc = props.pointDocument ?? document;
@@ -4298,11 +4351,33 @@ Arkme 用户 {v0}|Arkme user {v0}
4298
4351
  const anchor = props.hoverAnchor;
4299
4352
  if (!open || !anchor || typeof document === "undefined") return;
4300
4353
  const doc = anchor.ownerDocument;
4301
- const close = () => closeRef.current();
4354
+ let pending;
4355
+ const cancel = () => {
4356
+ if (pending !== void 0) {
4357
+ clearTimeout(pending);
4358
+ pending = void 0;
4359
+ }
4360
+ };
4361
+ const close = () => {
4362
+ cancel();
4363
+ closeRef.current();
4364
+ };
4365
+ const scheduleClose = () => {
4366
+ if (!props.hoverCloseDelayMs) {
4367
+ close();
4368
+ return;
4369
+ }
4370
+ if (pending === void 0) pending = setTimeout(close, props.hoverCloseDelayMs);
4371
+ };
4302
4372
  const move = (event) => {
4303
4373
  if (event.pointerType === "touch") return;
4374
+ if (!anchor.isConnected) {
4375
+ close();
4376
+ return;
4377
+ }
4304
4378
  const list = menu.current;
4305
- if (!anchor.isConnected || list && !inMenuHoverRegion(event.clientX, event.clientY, anchor.getBoundingClientRect(), list.getBoundingClientRect())) close();
4379
+ if (!list || inMenuHoverRegion(event.clientX, event.clientY, anchor.getBoundingClientRect(), list.getBoundingClientRect())) cancel();
4380
+ else scheduleClose();
4306
4381
  };
4307
4382
  const leave = (event) => {
4308
4383
  if (event.relatedTarget === null) close();
@@ -4318,12 +4393,17 @@ Arkme 用户 {v0}|Arkme user {v0}
4318
4393
  doc.addEventListener("pointerout", leave, true);
4319
4394
  doc.defaultView?.addEventListener("blur", close);
4320
4395
  return () => {
4396
+ cancel();
4321
4397
  observer.disconnect();
4322
4398
  doc.removeEventListener("pointermove", move, true);
4323
4399
  doc.removeEventListener("pointerout", leave, true);
4324
4400
  doc.defaultView?.removeEventListener("blur", close);
4325
4401
  };
4326
- }, [open, props.hoverAnchor]);
4402
+ }, [
4403
+ open,
4404
+ props.hoverAnchor,
4405
+ props.hoverCloseDelayMs
4406
+ ]);
4327
4407
  const actions = props.actions.filter((action) => !!action);
4328
4408
  const items = actions.map((action) => "type" in action ? action : {
4329
4409
  id: action.id,
@@ -300,6 +300,9 @@ body:has([data-arkme-self-topic-menu]) > [role="menu"] { z-index: 10030; }
300
300
  };
301
301
  }
302
302
  //#endregion
303
+ //#region src/client/conversation-header-layout.ts
304
+ const HARNESS_CONVERSATION_NAME = "DeepSeek Harness";
305
+ //#endregion
303
306
  //#region src/client/harness-session-dropdown.ts
304
307
  const PREFIX = "data-arkme-session-";
305
308
  const HEADER = "[data-slot=\"conversation.session.header\"] > header";
@@ -386,13 +389,34 @@ body:has([data-arkme-self-topic-menu]) > [role="menu"] { z-index: 10030; }
386
389
  const row = cluster?.parentElement;
387
390
  const nav = cluster?.querySelector(":scope > nav");
388
391
  if (!actions || !cluster || !row || !nav || row.parentElement !== header || cluster.children.length !== 2 || cluster.firstElementChild !== nav || cluster.lastElementChild !== actions) return [];
392
+ const utilities = [...row.children].filter((node) => node !== cluster && !node.hasAttribute("data-arkme-session-identity"));
389
393
  return [
394
+ [header, "header"],
390
395
  [row, "title-row"],
391
396
  [cluster, "title-cluster"],
392
397
  [actions, "summary"],
393
- [nav, "title-nav"]
398
+ [nav, "title-nav"],
399
+ ...utilities.map((node) => [node, "utilities"]),
400
+ ...utilities[0] ? [[utilities[0], "utilities-start"]] : []
394
401
  ];
395
402
  }
403
+ function selectedRowStatus(value) {
404
+ const slot = value.column.querySelector("[role=\"treeitem\"][aria-selected=\"true\"]")?.firstElementChild;
405
+ const dot = slot?.querySelector("[data-state]");
406
+ const state = dot?.getAttribute("data-state");
407
+ if (!slot || !dot || state === null || ![
408
+ "done",
409
+ "warning",
410
+ "ongoing",
411
+ "error",
412
+ "idle"
413
+ ].includes(state)) return void 0;
414
+ return {
415
+ dot,
416
+ labels: [...slot.querySelectorAll("span:not([data-state])")].map((node) => node.textContent?.trim() ?? "").filter((text) => text !== ""),
417
+ state
418
+ };
419
+ }
396
420
  /**
397
421
  * Presentation-only adapter: the native SidebarRoot, WorkspaceBrowser, their
398
422
  * live slots, handlers, menus, stores and React ancestry all stay mounted in
@@ -405,6 +429,7 @@ body:has([data-arkme-self-topic-menu]) > [role="menu"] { z-index: 10030; }
405
429
  if (!win || !doc.body) return () => {};
406
430
  let current;
407
431
  let title;
432
+ let statusSignature = "";
408
433
  let open = false;
409
434
  let external;
410
435
  let disposed = false;
@@ -423,6 +448,12 @@ body:has([data-arkme-self-topic-menu]) > [role="menu"] { z-index: 10030; }
423
448
  };
424
449
  const host = doc.createElement("span");
425
450
  mark(host, "anchor");
451
+ const identity = doc.createElement("span");
452
+ mark(identity, "identity");
453
+ identity.textContent = HARNESS_CONVERSATION_NAME;
454
+ identity.title = HARNESS_CONVERSATION_NAME;
455
+ identity.setAttribute("role", "heading");
456
+ identity.setAttribute("aria-level", "2");
426
457
  const trigger = doc.createElement("button");
427
458
  trigger.type = "button";
428
459
  trigger.setAttribute("aria-haspopup", "dialog");
@@ -430,6 +461,14 @@ body:has([data-arkme-self-topic-menu]) > [role="menu"] { z-index: 10030; }
430
461
  trigger.setAttribute("data-arkme-conversation-selector", "");
431
462
  mark(trigger, "trigger");
432
463
  const label = doc.createElement("span");
464
+ const status = doc.createElement("span");
465
+ mark(status, "status");
466
+ status.setAttribute("aria-hidden", "true");
467
+ const statusLabel = doc.createElement("span");
468
+ mark(statusLabel, "status-label");
469
+ statusLabel.setAttribute("aria-hidden", "true");
470
+ const labelText = doc.createElement("span");
471
+ label.append(status, labelText, statusLabel);
433
472
  const arrow = doc.createElement("span");
434
473
  const chevron = doc.createElementNS("http://www.w3.org/2000/svg", "svg");
435
474
  chevron.setAttribute("viewBox", "0 0 16 16");
@@ -478,16 +517,55 @@ body:has([data-arkme-self-topic-menu]) > [role="menu"] { z-index: 10030; }
478
517
  opacity: 1 !important; visibility: visible !important; transform: none !important;
479
518
  }
480
519
  [${PREFIX}anchor] { display: inline-flex; width: max-content; min-width: 0; max-width: 100%; }
481
- [${PREFIX}title-row] { align-items: flex-start; }
482
- [${PREFIX}title-cluster] { flex-direction: column; align-items: stretch; gap: 4px; }
483
- [${PREFIX}title-nav] { width: 100%; }
484
- [${PREFIX}summary] { min-width: 0; min-height: 18px; gap: 0; flex-wrap: wrap; color: var(--dsw-alias-label-secondary, #626872); font-size: 12px; line-height: 18px; }
520
+ /* The selected row's own status dot, mirrored beside the fixed title. Empty
521
+ when the session has no status, so the title keeps its full width. */
522
+ [${PREFIX}status] {
523
+ display: none; flex: none; width: 16px; height: 16px; margin-right: 6px;
524
+ align-items: center; justify-content: center; vertical-align: middle;
525
+ }
526
+ [${PREFIX}status]:not(:empty) { display: inline-flex; }
527
+ [${PREFIX}status-label] {
528
+ display: none; flex: none; min-width: 0; max-width: 96px; margin-left: 6px;
529
+ overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
530
+ color: var(--dsw-alias-label-secondary, #626872); font-size: 12px; font-weight: 500; line-height: 18px;
531
+ }
532
+ [${PREFIX}status-label]:not(:empty) { display: inline-block; }
533
+ [${PREFIX}header] { padding-left: 20px; padding-right: 20px; container: arkme-session-header / inline-size; }
534
+ [${PREFIX}title-row] {
535
+ --arkme-header-side: max(calc((100% - 8px) / 4), var(--arkme-header-utilities-width, 0px));
536
+ display: flex !important; flex-wrap: nowrap; gap: 4px; align-items: flex-start;
537
+ }
538
+ [${PREFIX}identity] {
539
+ flex: 0 0 var(--arkme-header-side); min-width: 0; max-width: 100%;
540
+ color: var(--dsw-alias-label-primary); font-size: 15px; font-weight: 600; line-height: 30px;
541
+ white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
542
+ }
543
+ [${PREFIX}identity][${PREFIX}fallback] { position: absolute; top: 10px; left: 20px; max-width: calc(25% - 24px); }
544
+ [${PREFIX}title-cluster] { flex: 0 0 max(0px, calc(100% - 2 * var(--arkme-header-side) - 8px)); min-width: 0; flex-direction: column; align-items: stretch; gap: 4px; }
545
+ [${PREFIX}utilities] { flex: 0 0 auto; min-width: 0; }
546
+ [${PREFIX}utilities-start] { margin-left: auto; }
547
+ /* Equal side reservations center both native rows without moving any of the
548
+ multiple upstream right-side control groups into a new grid row. */
549
+ [${PREFIX}title-nav] { width: 100%; display: flex; justify-content: center; }
550
+ [${PREFIX}title-nav] > * { min-width: 0; max-width: 100%; }
551
+ [${PREFIX}summary] { min-width: 0; height: 18px; min-height: 18px; gap: 0; flex-wrap: nowrap; overflow: hidden; white-space: nowrap; justify-content: center; color: var(--dsw-alias-label-secondary, #626872); font-size: 12px; line-height: 18px; }
552
+ [${PREFIX}summary] [data-slot="conversation.session.header.actions"] { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
485
553
  [${PREFIX}summary] [data-slot="conversation.session.header.actions"] > * { font-size: inherit; line-height: inherit; }
486
554
  [${PREFIX}turn-count] { display: inline-flex; align-items: center; white-space: nowrap; }
487
555
  [${PREFIX}summary] [data-slot="conversation.session.header.actions"] > * + [${PREFIX}turn-count]::before { content: '·'; margin: 0 7px; }
556
+ /* The embedded conversation can be much narrower than the browser. Keep
557
+ native controls in their React ancestry, wrapping only in that case. */
558
+ @container arkme-session-header (max-width: 360px) {
559
+ [${PREFIX}title-row] { flex-wrap: wrap; row-gap: 8px; }
560
+ [${PREFIX}identity] { flex-basis: calc(40% - 1.6px); }
561
+ [${PREFIX}title-cluster] { flex-basis: calc(60% - 2.4px); }
562
+ [${PREFIX}utilities] { margin-left: 0; margin-right: 0; max-width: 100%; flex-wrap: wrap; }
563
+ [${PREFIX}utilities-start] { margin-left: auto; }
564
+ [${PREFIX}title-nav] [${PREFIX}anchor] { display: inline-flex; min-width: 0; max-width: 100%; }
565
+ }
488
566
  [${PREFIX}anchor][${PREFIX}fallback] {
489
567
  width: max-content; position: absolute; top: 10px;
490
- left: 20px; z-index: 10; max-width: calc(100% - 40px);
568
+ left: 50%; transform: translateX(-50%); z-index: 10; max-width: calc(50% - 8px);
491
569
  }
492
570
  ${CONVERSATION_SELECTOR_CSS}
493
571
  [${PREFIX}column] [role="treeitem"][aria-selected]:hover { background: ${CONVERSATION_MENU_COLORS.hover}; }
@@ -515,11 +593,18 @@ body:has([data-arkme-self-topic-menu]) > [role="menu"] { z-index: 10030; }
515
593
  for (const cleanup of rowFocusCleanups.values()) cleanup();
516
594
  for (const [node, key] of toolbarMarks) node.removeAttribute(PREFIX + key);
517
595
  toolbarMarks = [];
518
- for (const [node, key] of summaryMarks) node.removeAttribute(PREFIX + key);
596
+ for (const [node, key] of summaryMarks) {
597
+ node.removeAttribute(PREFIX + key);
598
+ if (key === "title-row") node.style.removeProperty("--arkme-header-utilities-width");
599
+ }
519
600
  summaryMarks = [];
520
601
  title?.removeAttribute("data-arkme-session-native-title");
521
602
  title = void 0;
603
+ statusSignature = "";
604
+ status.replaceChildren();
605
+ statusLabel.textContent = "";
522
606
  host.remove();
607
+ identity.remove();
523
608
  if (current) {
524
609
  const { frame, column, root, brand, create, toggle } = current;
525
610
  for (const [node, key] of [
@@ -615,10 +700,24 @@ body:has([data-arkme-self-topic-menu]) > [role="menu"] { z-index: 10030; }
615
700
  variable(next.frame, "--arkme-session-rightbar", next.rightTrack);
616
701
  const header = next.center.querySelector(HEADER);
617
702
  const nextSummary = summaryLayout(header ?? void 0);
618
- for (const [node, key] of summaryMarks) if (!nextSummary.some(([nextNode, nextKey]) => node === nextNode && key === nextKey)) node.removeAttribute(PREFIX + key);
703
+ for (const [node, key] of summaryMarks) if (!nextSummary.some(([nextNode, nextKey]) => node === nextNode && key === nextKey)) {
704
+ node.removeAttribute(PREFIX + key);
705
+ if (key === "title-row") node.style.removeProperty("--arkme-header-utilities-width");
706
+ }
619
707
  summaryMarks = nextSummary;
620
708
  for (const [node, key] of summaryMarks) mark(node, key);
621
709
  const visibleHeader = header && header.getAttribute("aria-hidden") !== "true";
710
+ const titleRow = summaryMarks.find(([, key]) => key === "title-row")?.[0];
711
+ if (titleRow) {
712
+ const utilityNodes = summaryMarks.filter(([, key]) => key === "utilities").map(([node]) => node);
713
+ const utilityWidth = utilityNodes.reduce((sum, node) => sum + node.getBoundingClientRect().width, 0) + Math.max(0, utilityNodes.length - 1) * 4;
714
+ variable(titleRow, "--arkme-header-utilities-width", `${Math.ceil(utilityWidth)}px`);
715
+ identity.removeAttribute("data-arkme-session-fallback");
716
+ if (identity.parentElement !== titleRow) titleRow.prepend(identity);
717
+ } else if (!visibleHeader) {
718
+ mark(identity, "fallback");
719
+ if (identity.parentElement !== next.center) next.center.append(identity);
720
+ } else identity.remove();
622
721
  const nativeTitle = visibleHeader ? header?.querySelector("nav > :last-child > button:disabled") : void 0;
623
722
  if (title !== nativeTitle) {
624
723
  title?.removeAttribute("data-arkme-session-native-title");
@@ -637,9 +736,29 @@ body:has([data-arkme-self-topic-menu]) > [role="menu"] { z-index: 10030; }
637
736
  if (host.parentElement !== next.center) next.center.append(host);
638
737
  }
639
738
  const text = title?.textContent?.trim() || (visibleHeader ? next.copy.sessions : next.copy.blank);
640
- if (label.textContent !== text) label.textContent = text;
739
+ if (labelText.textContent !== text) labelText.textContent = text;
641
740
  trigger.title = text;
642
- trigger.setAttribute("aria-label", `${next.copy.choose}:${text}`);
741
+ const nativeStatus = selectedRowStatus(next);
742
+ const statusText = nativeStatus?.labels.join("、") ?? "";
743
+ const signature = nativeStatus === void 0 ? "" : `${nativeStatus.dot.outerHTML}\u0000${statusText}\u0000${nativeStatus.state}`;
744
+ if (statusSignature !== signature) {
745
+ statusSignature = signature;
746
+ status.replaceChildren();
747
+ statusLabel.textContent = "";
748
+ if (nativeStatus !== void 0) {
749
+ const mirror = nativeStatus.dot.cloneNode(true);
750
+ mark(mirror, "status-dot");
751
+ status.append(mirror);
752
+ statusLabel.textContent = nativeStatus.labels[0] ?? {
753
+ ongoing: next.copy.expand === "Open sidebar" ? "Running" : "进行中",
754
+ done: next.copy.expand === "Open sidebar" ? "Completed" : "已完成",
755
+ warning: next.copy.expand === "Open sidebar" ? "Needs attention" : "等待处理",
756
+ error: next.copy.expand === "Open sidebar" ? "Error" : "出错",
757
+ idle: next.copy.expand === "Open sidebar" ? "Idle" : "空闲"
758
+ }[nativeStatus.state];
759
+ }
760
+ }
761
+ trigger.setAttribute("aria-label", statusText === "" ? `${next.copy.choose}:${text}` : `${next.copy.choose}:${text}(${statusText})`);
643
762
  position();
644
763
  }
645
764
  function schedule() {
@@ -754,7 +873,8 @@ body:has([data-arkme-self-topic-menu]) > [role="menu"] { z-index: 10030; }
754
873
  "aria-hidden",
755
874
  "aria-selected",
756
875
  "disabled",
757
- "data-slot"
876
+ "data-slot",
877
+ "data-state"
758
878
  ]
759
879
  });
760
880
  doc.addEventListener("pointerdown", pointer, true);
package/lib/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { A as inspectNativeBundleArtifactV3, At as parseArkmeRecordReeditAttachments, Ct as isRecentEmojiId, D as bundleSha256, Dt as retryAfterMillis, E as arkmeSandboxEntryId, Et as ArkmePluginError, F as assertExtensionArtifactSize, Ft as __esmMin, G as validateVoiceprintPcm16Wav, I as canonicalExtensionJson, It as __exportAll, J as arkmeRequiredLinkMetadataFallback, K as arkmeExtensionShareRefFromLink, L as sha256Hex, Lt as __require, M as packLocalNativeBundleDirectoryV3, Mt as registerDSHAgentInputRecordSync, N as readNativeBundleTarballV3, Nt as createDesktopLifecycleReader, O as canonicalBundleJson, Ot as recordOwnerId, P as renderArkmeSandboxHostEntry, Pt as __commonJSMin, Q as ARKME_PROVIDER_CONTRACT_VERSION, R as unpackArkmeExtension, Rt as __toCommonJS, S as ARKME_BUNDLE_ARTIFACT_KIND, St as recordingImportFileNameKey, T as ArkmeBundleArtifactError, Tt as registerManagedAiProvider, U as ARKME_EXTENSION_RUNTIME_UNAVAILABLE_MESSAGE, W as ArkmeService, X as arkmeRichBackgroundSound, Y as arkmeFileBackgroundSound, Z as ARKME_DEFAULT_SHARE_WEBSITE, _ as arkmeClientContentDigest, _t as isRecordingInstantOnOrAfterUnixEpoch, at as cachedMemberItem, b as verifyExtensionResolutionSignature, bt as sameRecordingImportIdentity, c as persistentExtensionBundleDirectory, ct as ARKME_RUNTIME_INSTANCE_ID, d as readPersistentExtensionActivation, dt as arkmeNormalizedFileMimeType, f as refreshPersistentClientWrapper, ft as arkmePickedFileKind, g as activeProfileExtensionOwnerConflicts, gt as ArkmeDirectMessageAdmissionError, h as renderArkmeBundleClientBundle, ht as SecretValue, i as invokePersistentArkmeExtension, it as applyMemberUpdate, j as packBundleFiles, jt as parseArkmeRecordReeditMentions, k as inspectBundleArtifact, kt as ArkmeRecordReeditDraftConflict, l as persistentExtensionPackageIdentity, lt as ARKME_TOOL_FILE_MAX_BYTES, m as writePersistentExtensionActivation, mt as ArkmeOutgoingCallError, nt as ARKME_WORLD_PUBLISH_MAX_IMAGES, o as persistentArkmeExtensionRuntimeState, ot as mergeMemberJoinEvents, p as repairPersistentExtensionInstallation, pt as isArkmeBotAvatarRef, q as arkmeIsGenericLinkMetadataTitle, r as deactivatePersistentArkmeExtension, rt as ARKME_WORLD_PUBLISH_MAX_IMAGE_BYTES, s as materializePersistentExtensionBundle, st as validateMemberUpdate, t as activatePersistentArkmeExtension, u as quarantinePersistentExtension, ut as arkmeCanInlineLocalFile, v as arkmeClientContentDigestFromSource, vt as isUnresolvedRecordingImportJob, w as ARKME_NATIVE_BUNDLE_ARTIFACT_KIND, wt as normalizeRecentEmojiIds, x as verifyNativeBundleResolutionSignature, y as verifyBundleResolutionSignature, yt as recordingImportFileKind, z as ARKME_EXTENSION_FORMAT } from "./persistent-runtime-DxKHwHTw.js";
1
+ import { A as inspectNativeBundleArtifactV3, At as parseArkmeRecordReeditAttachments, Ct as isRecentEmojiId, D as bundleSha256, Dt as retryAfterMillis, E as arkmeSandboxEntryId, Et as ArkmePluginError, F as assertExtensionArtifactSize, Ft as __esmMin, G as validateVoiceprintPcm16Wav, I as canonicalExtensionJson, It as __exportAll, J as arkmeRequiredLinkMetadataFallback, K as arkmeExtensionShareRefFromLink, L as sha256Hex, Lt as __require, M as packLocalNativeBundleDirectoryV3, Mt as registerDSHAgentInputRecordSync, N as readNativeBundleTarballV3, Nt as createDesktopLifecycleReader, O as canonicalBundleJson, Ot as recordOwnerId, P as renderArkmeSandboxHostEntry, Pt as __commonJSMin, Q as ARKME_PROVIDER_CONTRACT_VERSION, R as unpackArkmeExtension, Rt as __toCommonJS, S as ARKME_BUNDLE_ARTIFACT_KIND, St as recordingImportFileNameKey, T as ArkmeBundleArtifactError, Tt as registerManagedAiProvider, U as ARKME_EXTENSION_RUNTIME_UNAVAILABLE_MESSAGE, W as ArkmeService, X as arkmeRichBackgroundSound, Y as arkmeFileBackgroundSound, Z as ARKME_DEFAULT_SHARE_WEBSITE, _ as arkmeClientContentDigest, _t as isRecordingInstantOnOrAfterUnixEpoch, at as cachedMemberItem, b as verifyExtensionResolutionSignature, bt as sameRecordingImportIdentity, c as persistentExtensionBundleDirectory, ct as ARKME_RUNTIME_INSTANCE_ID, d as readPersistentExtensionActivation, dt as arkmeNormalizedFileMimeType, f as refreshPersistentClientWrapper, ft as arkmePickedFileKind, g as activeProfileExtensionOwnerConflicts, gt as ArkmeDirectMessageAdmissionError, h as renderArkmeBundleClientBundle, ht as SecretValue, i as invokePersistentArkmeExtension, it as applyMemberUpdate, j as packBundleFiles, jt as parseArkmeRecordReeditMentions, k as inspectBundleArtifact, kt as ArkmeRecordReeditDraftConflict, l as persistentExtensionPackageIdentity, lt as ARKME_TOOL_FILE_MAX_BYTES, m as writePersistentExtensionActivation, mt as ArkmeOutgoingCallError, nt as ARKME_WORLD_PUBLISH_MAX_IMAGES, o as persistentArkmeExtensionRuntimeState, ot as mergeMemberJoinEvents, p as repairPersistentExtensionInstallation, pt as isArkmeBotAvatarRef, q as arkmeIsGenericLinkMetadataTitle, r as deactivatePersistentArkmeExtension, rt as ARKME_WORLD_PUBLISH_MAX_IMAGE_BYTES, s as materializePersistentExtensionBundle, st as validateMemberUpdate, t as activatePersistentArkmeExtension, u as quarantinePersistentExtension, ut as arkmeCanInlineLocalFile, v as arkmeClientContentDigestFromSource, vt as isUnresolvedRecordingImportJob, w as ARKME_NATIVE_BUNDLE_ARTIFACT_KIND, wt as normalizeRecentEmojiIds, x as verifyNativeBundleResolutionSignature, y as verifyBundleResolutionSignature, yt as recordingImportFileKind, z as ARKME_EXTENSION_FORMAT } from "./persistent-runtime-Cb8xQ4w0.js";
2
2
  import { _ as parsePluginUpdateManifest, b as validatePluginUpdateServiceOrigin, d as writePluginUpdateLifecycleLog, f as PluginUpdateInstallStateStore, g as existingCachedPluginArtifactPath, h as downloadAndCachePluginArtifact, m as PluginUpdateArtifactError, n as buildTargetInstallArgs, o as reconcilePluginUpdaterProfilePolicy, p as ARKME_PLUGIN_PACKAGE_NAME$1, t as assertTargetArtifactIntegrity, u as detachManagedProfilePluginLink, v as pluginUpdateEndpointUrl, y as validatePluginUpdateArtifactOrigin } from "./plugin-updater-helper-Ny1szQA0.js";
3
3
  import { a as securePrivateDirectory, c as securePrivateFileSync, i as prepareProfilePackageManager, n as isArkmeProfilePackageName, o as securePrivateDirectorySync, r as localExtensionPnpmArgs, s as securePrivateFile, t as applyArkmeProfileBundlePolicy } from "./profile-bundle-policy-DLXDyohJ.js";
4
4
  import { i as invokeArkmeBundle, n as arkmeBundleActive, r as deactivateArkmeBundle } from "./bundle-runtime-CE73h3vS.js";
@@ -11462,6 +11462,38 @@ async function dispatchArkmeHostOperation(service, operation, params, updateMana
11462
11462
  ...stringParam(params, "remark").trim() === "" ? {} : { remark: stringParam(params, "remark") },
11463
11463
  ...stringParam(params, "requestUid").trim() === "" ? {} : { requestUid: stringParam(params, "requestUid") }
11464
11464
  });
11465
+ case "private-interaction.summary": {
11466
+ const sourceRef = stringParam(params, "sourceRef").trim();
11467
+ if (sourceRef === "") throw new ArkmePluginError("interaction-source-invalid", "请选择一个私聊联系人", false, 400);
11468
+ const expectedVersion = stringParam(params, "expectedVersion").trim();
11469
+ return await service.privateInteractionSummary(sourceRef, {
11470
+ ...expectedVersion === "" ? {} : { expectedVersion },
11471
+ ...requestSignal === void 0 ? {} : { signal: requestSignal }
11472
+ });
11473
+ }
11474
+ case "private-interaction.directory": {
11475
+ const cursor = stringParam(params, "cursor").trim();
11476
+ const expectedVersion = stringParam(params, "expectedVersion").trim();
11477
+ return await service.privateInteractionDirectory({
11478
+ limit: Math.min(100, Math.max(1, Math.trunc(numberParam(params, "limit", 100)))),
11479
+ ...cursor === "" ? {} : { cursor },
11480
+ ...expectedVersion === "" ? {} : { expectedVersion },
11481
+ ...requestSignal === void 0 ? {} : { signal: requestSignal }
11482
+ });
11483
+ }
11484
+ case "private-interaction.query": {
11485
+ const cursor = stringParam(params, "cursor").trim();
11486
+ const expectedVersion = stringParam(params, "expectedVersion").trim();
11487
+ const sourceRef = stringParam(params, "sourceRef").trim();
11488
+ return await service.queryPrivateInteractions({
11489
+ ...sourceRef === "" ? {} : { sourceRef },
11490
+ ...params.unreadOnly === void 0 ? {} : { unreadOnly: booleanParam(params, "unreadOnly") },
11491
+ limit: Math.min(50, Math.max(1, Math.trunc(numberParam(params, "limit", 30)))),
11492
+ ...cursor === "" ? {} : { cursor },
11493
+ ...expectedVersion === "" ? {} : { expectedVersion },
11494
+ ...requestSignal === void 0 ? {} : { signal: requestSignal }
11495
+ });
11496
+ }
11465
11497
  case "directory.list": {
11466
11498
  const countOnly = booleanParam(params, "countOnly");
11467
11499
  const cursor = stringParam(params, "cursor").trim();
@@ -11578,6 +11610,33 @@ async function dispatchArkmeHostOperation(service, operation, params, updateMana
11578
11610
  endDate: stringParam(params, "endDate"),
11579
11611
  ...stringParam(params, "timezone") === "" ? {} : { timezone: stringParam(params, "timezone") }
11580
11612
  });
11613
+ case "calendar.activity": {
11614
+ const source = params?.source;
11615
+ const mode = params?.mode;
11616
+ if (![
11617
+ "record",
11618
+ "chat",
11619
+ "call",
11620
+ "audio",
11621
+ "arko",
11622
+ "bot"
11623
+ ].includes(source) || ![
11624
+ "buckets",
11625
+ "details",
11626
+ "coverage",
11627
+ "transcripts"
11628
+ ].includes(mode)) throw new ArkmePluginError("calendar-activity-invalid", "我的一天数据源或读取模式无效", false, 400);
11629
+ const body = params?.body;
11630
+ if (body === null || typeof body !== "object" || Array.isArray(body)) throw new ArkmePluginError("calendar-activity-body-invalid", "我的一天请求参数无效", false, 400);
11631
+ return await service.calendarBuckets({
11632
+ activity: {
11633
+ source,
11634
+ mode,
11635
+ body
11636
+ },
11637
+ ...requestSignal === void 0 ? {} : { signal: requestSignal }
11638
+ });
11639
+ }
11581
11640
  case "calendar.day-recap": return await service.generateDayRecap(params, requestSignal);
11582
11641
  case "calendar.record-location": return await service.calendarRecordLocation(stringParam(params, "locationRef"), requestSignal);
11583
11642
  case "calendar.records": {
@@ -1,2 +1,2 @@
1
- import { a as persistentArkmeExtensionActive, i as invokePersistentArkmeExtension, n as applyPersistentArkmeHostExtension, o as persistentArkmeExtensionRuntimeState, r as deactivatePersistentArkmeExtension, t as activatePersistentArkmeExtension } from "./persistent-runtime-DxKHwHTw.js";
1
+ import { a as persistentArkmeExtensionActive, i as invokePersistentArkmeExtension, n as applyPersistentArkmeHostExtension, o as persistentArkmeExtensionRuntimeState, r as deactivatePersistentArkmeExtension, t as activatePersistentArkmeExtension } from "./persistent-runtime-Cb8xQ4w0.js";
2
2
  export { activatePersistentArkmeExtension, applyPersistentArkmeHostExtension, deactivatePersistentArkmeExtension, invokePersistentArkmeExtension, persistentArkmeExtensionActive, persistentArkmeExtensionRuntimeState };