@sparkelf/dsh-dataops-managed 0.3.39 → 0.3.41

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/lib/client.js CHANGED
@@ -97,7 +97,7 @@ window.__ModuleLoader__.load({
97
97
  //#region src/client/model-sync-client.ts
98
98
  /** Same-origin model-sync calls from the DataOps settings surface. */
99
99
  /** Route the plugin's Host half serves for model sharing. */
100
- const MODEL_SYNC_PATH = "/integrations/dataops/model-sync";
100
+ const MODEL_SYNC_PATH = "integrations/dataops/model-sync";
101
101
  /** Narrow a response body to the status shape, rejecting anything else. */
102
102
  function asStatus$2(value) {
103
103
  if (typeof value !== "object" || value === null || Array.isArray(value)) return null;
@@ -163,7 +163,7 @@ window.__ModuleLoader__.load({
163
163
  //#region src/client/workspace-limits-client.ts
164
164
  /** Same-origin workspace-limits calls from the DataOps settings surface. */
165
165
  /** Route the plugin's Host half serves for workspace limits. */
166
- const WORKSPACE_LIMITS_PATH = "/integrations/dataops/workspace-limits";
166
+ const WORKSPACE_LIMITS_PATH = "integrations/dataops/workspace-limits";
167
167
  /** Narrow a response body to the status, rejecting anything else. */
168
168
  function asStatus$1(value) {
169
169
  if (typeof value !== "object" || value === null || Array.isArray(value)) return null;
@@ -237,7 +237,7 @@ window.__ModuleLoader__.load({
237
237
  //#region src/client/tool-timeout-client.ts
238
238
  /** Same-origin tool-call timeout calls from the DataOps settings surface. */
239
239
  /** Route the plugin's Host half serves for the tool-call timeout. */
240
- const TOOL_TIMEOUT_PATH = "/integrations/dataops/tool-timeout";
240
+ const TOOL_TIMEOUT_PATH = "integrations/dataops/tool-timeout";
241
241
  /** Narrow a response body to the timeout, rejecting anything else. */
242
242
  function asTimeout(value) {
243
243
  if (typeof value !== "object" || value === null || Array.isArray(value)) return null;
@@ -540,17 +540,17 @@ window.__ModuleLoader__.load({
540
540
  //#endregion
541
541
  //#region src/client/review-client.ts
542
542
  /** Caller identity and review capability. */
543
- const REVIEW_CONTEXT_PATH = "/integrations/dataops/review-context";
543
+ const REVIEW_CONTEXT_PATH = "integrations/dataops/review-context";
544
544
  /** Notification list and read receipts. */
545
- const NOTIFICATIONS_PATH = "/integrations/dataops/review-notifications";
545
+ const NOTIFICATIONS_PATH = "integrations/dataops/review-notifications";
546
546
  /** AI scan and the human decision. */
547
- const REVIEW_ACTION_PATH = "/integrations/dataops/review";
547
+ const REVIEW_ACTION_PATH = "integrations/dataops/review";
548
548
  /** Role matrix, members, departments, and resource scopes. */
549
- const RBAC_PATH = "/integrations/dataops/rbac";
549
+ const RBAC_PATH = "integrations/dataops/rbac";
550
550
  /** The three plaza-review switches in the DataOps settings panel. */
551
- const REVIEW_SETTINGS_PATH = "/integrations/dataops/review-settings";
551
+ const REVIEW_SETTINGS_PATH = "integrations/dataops/review-settings";
552
552
  /** Department CRUD bridge (task-67). */
553
- const DEPARTMENTS_PATH = "/integrations/dataops/departments";
553
+ const DEPARTMENTS_PATH = "integrations/dataops/departments";
554
554
  /** The product defaults, used until DataOps returns its own value. */
555
555
  const DEFAULT_REVIEW_SETTINGS = {
556
556
  skillPlaza: true,
@@ -834,22 +834,22 @@ window.__ModuleLoader__.load({
834
834
  document.head.appendChild(tag);
835
835
  }
836
836
  var ManagedDataOpsSection_module_css_default = {
837
- "row": "_2dqzjG_row",
838
- "label": "_2dqzjG_label",
839
- "fields": "_2dqzjG_fields",
840
- "copy": "_2dqzjG_copy",
841
- "refusal": "_2dqzjG_refusal",
837
+ "card": "_2dqzjG_card",
842
838
  "reviewRows": "_2dqzjG_reviewRows",
843
- "title": "_2dqzjG_title",
844
- "reviewHint": "_2dqzjG_reviewHint",
839
+ "label": "_2dqzjG_label",
845
840
  "status": "_2dqzjG_status",
846
- "reviewActions": "_2dqzjG_reviewActions",
841
+ "copy": "_2dqzjG_copy",
842
+ "row": "_2dqzjG_row",
847
843
  "heading": "_2dqzjG_heading",
848
- "reviewRow": "_2dqzjG_reviewRow",
844
+ "fields": "_2dqzjG_fields",
849
845
  "meta": "_2dqzjG_meta",
850
- "card": "_2dqzjG_card",
846
+ "reviewActions": "_2dqzjG_reviewActions",
847
+ "reviewHint": "_2dqzjG_reviewHint",
848
+ "refusal": "_2dqzjG_refusal",
851
849
  "actions": "_2dqzjG_actions",
852
- "section": "_2dqzjG_section"
850
+ "section": "_2dqzjG_section",
851
+ "title": "_2dqzjG_title",
852
+ "reviewRow": "_2dqzjG_reviewRow"
853
853
  };
854
854
  //#endregion
855
855
  //#region src/client/ReviewSettingsCard.tsx
@@ -1502,15 +1502,10 @@ window.__ModuleLoader__.load({
1502
1502
  function sortNotifications(items) {
1503
1503
  return [...items].sort((left, right) => right.createdAt.localeCompare(left.createdAt));
1504
1504
  }
1505
- /** The tab a notification should open, when its resource has one. */
1506
- function notificationTab(item) {
1507
- if (item.type === "submitted" || item.type === "review_pending" || item.type === "ai_report_ready" || item.type === "ai_report") return "pending";
1508
- if (item.type === "approved" || item.type === "published" || item.type === "shared") return "approved";
1509
- }
1510
1505
  //#endregion
1511
1506
  //#region src/client/skill-plaza-client.ts
1512
1507
  /** Route the plugin's Host half serves for the plaza. */
1513
- const SKILL_PLAZA_PATH = "/integrations/dataops/skill-plaza";
1508
+ const SKILL_PLAZA_PATH = "integrations/dataops/skill-plaza";
1514
1509
  /** Narrow an unknown value to a plaza entry. */
1515
1510
  function asSkill(value) {
1516
1511
  if (typeof value !== "object" || value === null || Array.isArray(value)) return null;
@@ -1592,136 +1587,10 @@ window.__ModuleLoader__.load({
1592
1587
  return await response.json();
1593
1588
  }
1594
1589
  //#endregion
1595
- //#region src/client/review-notification-store.ts
1590
+ //#region \0dsh-css:/root/projects/dsh-plugins-plus/packages/dataops-managed/src/client/SkillPlazaSection.module.css.mjs
1596
1591
  init_review_demo();
1597
- /**
1598
- * One process-wide notification store shared by every bell.
1599
- *
1600
- * The skill plaza and the workflow plaza are separate React trees, but they show the same
1601
- * inbox; keeping the read state in one store is what stops a badge in one place from staying
1602
- * unread after the other opened the row.
1603
- */
1604
- const DEMO_ITEMS = [
1605
- {
1606
- id: "demo-1",
1607
- type: "review_pending",
1608
- title: "技能「SQL 取数助手」等待审核",
1609
- body: "来自研发部 · 提交于 10 分钟前",
1610
- resourceKind: "skill",
1611
- resourceId: 101,
1612
- read: false,
1613
- createdAt: "2026-10-23T04:50:00.000Z"
1614
- },
1615
- {
1616
- id: "demo-2",
1617
- type: "ai_report",
1618
- title: "AI 风险报告已生成",
1619
- body: "风险等级:中 · 2 条建议",
1620
- resourceKind: "skill",
1621
- resourceId: 101,
1622
- read: false,
1623
- createdAt: "2026-10-23T04:49:00.000Z"
1624
- },
1625
- {
1626
- id: "demo-3",
1627
- type: "approved",
1628
- title: "工作流「每日经营日报」已通过",
1629
- body: "审核人:admin",
1630
- resourceKind: "workflow",
1631
- resourceId: "wf-1",
1632
- read: true,
1633
- createdAt: "2026-10-22T09:10:00.000Z"
1634
- }
1635
- ];
1636
- let state = {
1637
- status: "idle",
1638
- items: [],
1639
- unread: 0
1640
- };
1641
- const listeners = /* @__PURE__ */ new Set();
1642
- function publish(next) {
1643
- state = next;
1644
- for (const listener of listeners) listener();
1645
- }
1646
- /** Current snapshot for `useSyncExternalStore`. */
1647
- function notificationSnapshot() {
1648
- return state;
1649
- }
1650
- /** Subscribe to store changes. */
1651
- function subscribeNotifications(listener) {
1652
- listeners.add(listener);
1653
- return () => {
1654
- listeners.delete(listener);
1655
- };
1656
- }
1657
- /** Load the inbox once; a second caller joins the first request. */
1658
- let inflight;
1659
- function loadNotifications() {
1660
- if (inflight !== void 0) return inflight;
1661
- publish({
1662
- ...state,
1663
- status: "loading"
1664
- });
1665
- inflight = (async () => {
1666
- try {
1667
- if (reviewDemoMode()) {
1668
- publish({
1669
- status: "ready",
1670
- items: sortNotifications(DEMO_ITEMS),
1671
- unread: unreadCount(DEMO_ITEMS)
1672
- });
1673
- return;
1674
- }
1675
- const result = await fetchNotifications();
1676
- if (result === null) {
1677
- publish({
1678
- status: "unavailable",
1679
- items: [],
1680
- unread: 0
1681
- });
1682
- return;
1683
- }
1684
- publish({
1685
- status: "ready",
1686
- items: sortNotifications(result.items),
1687
- unread: unreadCount(result.items)
1688
- });
1689
- } catch {
1690
- publish({
1691
- status: "unavailable",
1692
- items: [],
1693
- unread: 0
1694
- });
1695
- } finally {
1696
- inflight = void 0;
1697
- }
1698
- })();
1699
- return inflight;
1700
- }
1701
- /** Mark one row or the whole inbox read, optimistically. */
1702
- async function markRead(ids) {
1703
- const items = ids === "all" ? state.items.map((item) => ({
1704
- ...item,
1705
- read: true
1706
- })) : state.items.map((item) => ids.includes(item.id) ? {
1707
- ...item,
1708
- read: true
1709
- } : item);
1710
- publish({
1711
- ...state,
1712
- items,
1713
- unread: unreadCount(items)
1714
- });
1715
- try {
1716
- if (!await markNotificationsRead(ids)) await loadNotifications();
1717
- } catch {
1718
- await loadNotifications();
1719
- }
1720
- }
1721
- //#endregion
1722
- //#region \0dsh-css:/root/projects/dsh-plugins-plus/packages/dataops-managed/src/client/NotificationBell.module.css.mjs
1723
- const css$4 = ".tE0trG_bell{width:26px;height:26px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:0;border-radius:6px;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex;position:relative}.tE0trG_bell:hover{background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary)}.tE0trG_bell:focus-visible{outline:2px solid var(--dsw-alias-brand-primary);outline-offset:1px}.tE0trG_badge{background:var(--dsw-alias-state-error-primary);color:#fff;text-align:center;border-radius:7px;min-width:14px;height:14px;padding:0 3px;font-size:9px;font-weight:600;line-height:14px;position:absolute;top:0;right:-2px}.tE0trG_dialog{flex-direction:column;width:min(520px,100vw - 32px);height:70vh;max-height:70vh;display:flex;overflow:hidden}.tE0trG_demo{background:var(--dsw-alias-state-warn-secondary);color:var(--dsw-alias-state-warn-primary);border-radius:4px;margin:0 0 8px;padding:5px 8px;font-size:11px}.tE0trG_empty{color:var(--dsw-alias-label-tertiary);text-align:center;margin:0;padding:18px 0;font-size:12px;line-height:18px}.tE0trG_list{flex-direction:column;flex:none;gap:6px;max-height:calc(70vh - 210px);margin:0;padding:0;list-style:none;display:flex;overflow-y:auto}.tE0trG_row{width:100%;color:var(--dsw-alias-label-secondary);text-align:left;cursor:pointer;background:0 0;border:0;border-radius:0;align-items:flex-start;gap:9px;padding:4px 2px;display:flex}.tE0trG_row:hover .tE0trG_rowTitle{color:var(--dsw-alias-state-business-primary)}.tE0trG_rowIcon{width:18px;height:18px;color:var(--dsw-alias-label-secondary);flex:none;justify-content:center;align-items:center;margin-top:1px;display:inline-flex}.tE0trG_rowIcon[data-tone=success]{color:var(--dsw-alias-state-success-primary)}.tE0trG_rowIcon[data-tone=danger]{color:var(--dsw-alias-state-error-primary)}.tE0trG_rowIcon[data-tone=warn]{color:var(--dsw-alias-state-warn-primary)}.tE0trG_rowIcon[data-tone=info]{color:var(--dsw-alias-state-business-primary)}.tE0trG_dot{background:var(--dsw-alias-state-business-primary);border-radius:50%;flex:none;width:6px;height:6px}.tE0trG_rowBody{flex-direction:column;flex:1;gap:2px;min-width:0;display:flex}.tE0trG_rowTitle{color:var(--dsw-alias-label-primary);font-size:12px;font-weight:500;line-height:18px}.tE0trG_rowText{color:var(--dsw-alias-label-secondary);font-size:11px;line-height:16px}.tE0trG_rowMeta{flex:none;align-items:center;gap:6px;margin-top:2px;display:flex}.tE0trG_rowTime{color:var(--dsw-alias-label-tertiary);flex:none;font-size:10px;line-height:16px}.tE0trG_actions{justify-content:flex-end;gap:6px;display:flex}.tE0trG_button,.tE0trG_linkButton{cursor:pointer;border-radius:5px;height:28px;padding:0 10px;font-size:12px}.tE0trG_button{border:1px solid var(--dsw-alias-border-l2);color:var(--dsw-alias-label-primary);background:0 0}.tE0trG_linkButton{color:var(--dsw-alias-state-business-primary);background:0 0;border:0}.tE0trG_pager{color:var(--dsw-alias-label-secondary);justify-content:flex-end;align-items:center;gap:8px;padding-top:8px;font-size:11px;display:flex}.tE0trG_pager button{border:1px solid var(--dsw-alias-border-l2);height:24px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border-radius:4px;padding:0 8px;font-size:11px}.tE0trG_pager button:disabled{opacity:.4;cursor:default}";
1724
- const tagId$4 = "@sparkelf/dsh-dataops-managed/NotificationBell.module.css";
1592
+ const css$4 = "._9FdZvq_section{box-sizing:border-box;flex-direction:column;width:100%;max-width:960px;margin:0 auto;display:flex}._9FdZvq_head{flex-direction:column;margin-bottom:8px;display:flex}._9FdZvq_title{color:var(--dsw-alias-label-primary);align-items:baseline;gap:8px;margin:0;font-size:14px;font-weight:500;line-height:20px;display:flex}._9FdZvq_titleCount{color:var(--dsw-alias-label-tertiary);font-size:12px;font-weight:400}._9FdZvq_status{text-align:center;color:var(--dsw-alias-label-tertiary);margin:0;padding:20px 0;font-size:13px;line-height:20px}._9FdZvq_departmentBar{align-items:center;gap:8px;margin-bottom:10px;display:inline-flex}._9FdZvq_departmentLabel{color:var(--dsw-alias-label-secondary);font-size:12px;line-height:18px}._9FdZvq_departmentSelect{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-1);height:28px;color:var(--dsw-alias-label-primary);font:inherit;border-radius:8px;padding:0 8px;font-size:12px;line-height:18px}._9FdZvq_departmentSelect:focus-visible{outline:2px solid var(--dsw-alias-brand-primary);outline-offset:1px}._9FdZvq_notice{color:var(--dsw-alias-state-business-primary);margin:4px 0 0;font-size:12px;line-height:18px}._9FdZvq_cards{grid-template-columns:repeat(auto-fill,minmax(272px,1fr));grid-auto-rows:max-content;align-content:start;align-items:stretch;gap:12px;margin:0;padding:0;list-style:none;display:grid}._9FdZvq_card{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-1);border-radius:10px;flex-direction:column;align-self:stretch;gap:10px;min-width:0;height:auto;padding:12px;display:flex}._9FdZvq_cardTop{justify-content:space-between;align-items:center;gap:10px;min-height:28px;display:flex}._9FdZvq_cardIcon{background:var(--dsw-alias-bg-layer-2);width:28px;height:28px;color:var(--dsw-alias-label-secondary);border-radius:50%;flex:none;place-items:center;display:grid}._9FdZvq_cardTitle{text-overflow:ellipsis;white-space:nowrap;flex:1;min-width:0;font-size:14px;font-weight:600;line-height:20px;overflow:hidden}._9FdZvq_mine{flex:none}._9FdZvq_cardDesc{min-height:36px;color:var(--dsw-alias-label-secondary);-webkit-line-clamp:2;-webkit-box-orient:vertical;font-size:12px;line-height:18px;display:-webkit-box;overflow:hidden}._9FdZvq_cardMarks{flex-wrap:wrap;align-content:flex-start;gap:6px;min-height:20px;display:flex}._9FdZvq_mark{background:color-mix(in srgb, var(--dsw-alias-state-business-primary) 14%, var(--dsw-alias-bg-layer-1));color:var(--dsw-alias-state-business-primary);white-space:nowrap;border:0;border-radius:4px;padding:2px 7px;font-size:11px;font-weight:500;line-height:16px}._9FdZvq_cardEnd{flex:none;align-items:center;gap:4px;margin-top:auto;padding-top:4px;display:flex}._9FdZvq_detailButton{margin-left:auto}._9FdZvq_detail{flex-direction:column;gap:12px;margin:0;display:flex}._9FdZvq_dialog{width:min(560px,100%)}._9FdZvq_detailRow{flex-direction:column;gap:2px;display:flex}._9FdZvq_detailLabel{color:var(--dsw-alias-label-caption);font-size:11px;line-height:16px}._9FdZvq_detailValue{max-height:160px;color:var(--dsw-alias-label-secondary);white-space:pre-wrap;overflow-wrap:anywhere;margin:0;font-size:12px;line-height:18px;overflow:auto}._9FdZvq_empty{text-align:center;flex-direction:column;align-items:center;gap:10px;padding:28px 16px 32px;display:flex}._9FdZvq_emptyIcon{border:.5px solid var(--dsw-alias-border-l3);width:56px;height:56px;color:var(--dsw-alias-label-tertiary);border-radius:14px;justify-content:center;align-items:center;display:inline-flex}._9FdZvq_emptyText{color:var(--dsw-alias-label-tertiary);margin:0;font-size:13px;line-height:20px}._9FdZvq_headRow{align-items:center;gap:6px;display:flex}._9FdZvq_headRow ._9FdZvq_title{flex:none}._9FdZvq_demoTag{background:var(--dsw-alias-state-warn-secondary);color:var(--dsw-alias-state-warn-primary);border-radius:4px;padding:1px 6px;font-size:10px;line-height:16px}._9FdZvq_tabs{border-bottom:1px solid var(--dsw-alias-border-l1);align-items:center;gap:2px;margin-bottom:8px;display:flex}._9FdZvq_tab{height:30px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:0;border-bottom:2px solid #0000;align-items:center;gap:5px;padding:0 9px;font-size:12px;display:inline-flex}._9FdZvq_tab:hover{color:var(--dsw-alias-label-primary)}._9FdZvq_tabActive{color:var(--dsw-alias-state-business-primary);border-bottom-color:var(--dsw-alias-state-business-primary);font-weight:500}._9FdZvq_tabCount{background:var(--dsw-alias-bg-layer-2);color:var(--dsw-alias-label-tertiary);border-radius:7px;padding:0 4px;font-size:10px;line-height:14px}._9FdZvq_tagTop{text-overflow:ellipsis;white-space:nowrap;border:1px solid var(--dsw-alias-border-l2);max-width:40%;color:var(--dsw-alias-label-secondary);border-radius:4px;flex:none;padding:1px 6px;font-size:10px;line-height:16px;overflow:hidden}._9FdZvq_sharedTag{color:#fff;background:#0e6b3a;border-radius:4px;padding:2px 7px;font-size:11px;font-weight:600;line-height:16px}._9FdZvq_pendingTag{color:#fff;background:#7a4a00;border-radius:4px;padding:2px 7px;font-size:11px;font-weight:600;line-height:16px}._9FdZvq_rejectedTag{color:#fff;background:#a8231b;border-radius:4px;padding:2px 7px;font-size:11px;font-weight:600;line-height:16px}._9FdZvq_reviewButton{margin-left:auto}._9FdZvq_reviewNote{border-left:3px solid var(--dsw-alias-state-error-primary);background:color-mix(in srgb, var(--dsw-alias-state-error-primary) 10%, var(--dsw-alias-bg-layer-1));color:var(--dsw-alias-label-primary);margin:0;padding:6px 8px;font-size:11px;line-height:16px}._9FdZvq_auditDialog{width:min(640px,100vw - 32px)}._9FdZvq_audit{flex-direction:column;gap:14px;display:flex}._9FdZvq_auditFooter{justify-content:flex-end;gap:6px;display:flex}._9FdZvq_risk{border:1px solid var(--dsw-alias-border-l1);background:var(--dsw-alias-bg-layer-1);border-radius:6px;flex-direction:column;gap:8px;padding:10px;display:flex}._9FdZvq_riskHead{justify-content:space-between;align-items:center;gap:8px;font-size:12px;display:flex}._9FdZvq_riskEmpty,._9FdZvq_riskFailed{color:var(--dsw-alias-label-tertiary);margin:0;font-size:11px;line-height:16px}._9FdZvq_riskFailed{color:var(--dsw-alias-state-error-primary)}._9FdZvq_riskSummary{color:var(--dsw-alias-label-secondary);flex-wrap:wrap;align-items:center;gap:6px;font-size:12px;line-height:18px;display:flex}._9FdZvq_riskScore{color:var(--dsw-alias-label-primary);font-weight:600}._9FdZvq_severity{background:var(--dsw-alias-bg-layer-2);color:var(--dsw-alias-label-secondary);text-transform:uppercase;border-radius:3px;padding:0 5px;font-size:10px;line-height:16px}._9FdZvq_severity[data-severity=high],._9FdZvq_severity[data-severity=critical]{background:var(--dsw-alias-state-error-secondary);color:var(--dsw-alias-state-error-primary)}._9FdZvq_severity[data-severity=medium]{background:var(--dsw-alias-state-warn-secondary);color:var(--dsw-alias-state-warn-primary)}._9FdZvq_findings{flex-direction:column;gap:6px;margin:0;padding:0;list-style:none;display:flex}._9FdZvq_finding{flex-wrap:wrap;align-items:baseline;gap:5px;font-size:11px;line-height:16px;display:flex}._9FdZvq_findingText{color:var(--dsw-alias-label-secondary);flex-basis:100%}._9FdZvq_findingHint{color:var(--dsw-alias-label-tertiary);flex-basis:100%}._9FdZvq_noteField{color:var(--dsw-alias-label-secondary);flex-direction:column;gap:5px;font-size:12px;display:flex}._9FdZvq_noteField textarea{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-base);min-height:64px;color:var(--dsw-alias-label-primary);font:inherit;resize:vertical;border-radius:5px;padding:7px 9px}._9FdZvq_reviewError{color:var(--dsw-alias-state-error-primary);margin:0;font-size:11px}";
1593
+ const tagId$4 = "@sparkelf/dsh-dataops-managed/SkillPlazaSection.module.css";
1725
1594
  if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$4) + "]") === null) {
1726
1595
  const tag = document.createElement("style");
1727
1596
  tag.dataset.plugin = "@sparkelf/dsh-dataops-managed";
@@ -1729,383 +1598,75 @@ window.__ModuleLoader__.load({
1729
1598
  tag.textContent = css$4;
1730
1599
  document.head.appendChild(tag);
1731
1600
  }
1732
- var NotificationBell_module_css_default = {
1733
- "demo": "tE0trG_demo",
1734
- "row": "tE0trG_row",
1735
- "linkButton": "tE0trG_linkButton",
1736
- "dot": "tE0trG_dot",
1737
- "rowBody": "tE0trG_rowBody",
1738
- "empty": "tE0trG_empty",
1739
- "rowText": "tE0trG_rowText",
1740
- "rowMeta": "tE0trG_rowMeta",
1741
- "list": "tE0trG_list",
1742
- "bell": "tE0trG_bell",
1743
- "actions": "tE0trG_actions",
1744
- "dialog": "tE0trG_dialog",
1745
- "button": "tE0trG_button",
1746
- "rowTitle": "tE0trG_rowTitle",
1747
- "rowTime": "tE0trG_rowTime",
1748
- "badge": "tE0trG_badge",
1749
- "pager": "tE0trG_pager",
1750
- "rowIcon": "tE0trG_rowIcon"
1601
+ var SkillPlazaSection_module_css_default = {
1602
+ "tabCount": "_9FdZvq_tabCount",
1603
+ "riskEmpty": "_9FdZvq_riskEmpty",
1604
+ "riskScore": "_9FdZvq_riskScore",
1605
+ "auditFooter": "_9FdZvq_auditFooter",
1606
+ "cardEnd": "_9FdZvq_cardEnd",
1607
+ "mine": "_9FdZvq_mine",
1608
+ "titleCount": "_9FdZvq_titleCount",
1609
+ "detailValue": "_9FdZvq_detailValue",
1610
+ "sharedTag": "_9FdZvq_sharedTag",
1611
+ "card": "_9FdZvq_card",
1612
+ "title": "_9FdZvq_title",
1613
+ "cardIcon": "_9FdZvq_cardIcon",
1614
+ "headRow": "_9FdZvq_headRow",
1615
+ "tabs": "_9FdZvq_tabs",
1616
+ "cardMarks": "_9FdZvq_cardMarks",
1617
+ "detailLabel": "_9FdZvq_detailLabel",
1618
+ "rejectedTag": "_9FdZvq_rejectedTag",
1619
+ "detailButton": "_9FdZvq_detailButton",
1620
+ "reviewButton": "_9FdZvq_reviewButton",
1621
+ "reviewNote": "_9FdZvq_reviewNote",
1622
+ "head": "_9FdZvq_head",
1623
+ "departmentLabel": "_9FdZvq_departmentLabel",
1624
+ "emptyIcon": "_9FdZvq_emptyIcon",
1625
+ "findings": "_9FdZvq_findings",
1626
+ "dialog": "_9FdZvq_dialog",
1627
+ "pendingTag": "_9FdZvq_pendingTag",
1628
+ "auditDialog": "_9FdZvq_auditDialog",
1629
+ "departmentSelect": "_9FdZvq_departmentSelect",
1630
+ "detailRow": "_9FdZvq_detailRow",
1631
+ "riskHead": "_9FdZvq_riskHead",
1632
+ "departmentBar": "_9FdZvq_departmentBar",
1633
+ "finding": "_9FdZvq_finding",
1634
+ "cardTitle": "_9FdZvq_cardTitle",
1635
+ "findingText": "_9FdZvq_findingText",
1636
+ "riskSummary": "_9FdZvq_riskSummary",
1637
+ "noteField": "_9FdZvq_noteField",
1638
+ "section": "_9FdZvq_section",
1639
+ "empty": "_9FdZvq_empty",
1640
+ "mark": "_9FdZvq_mark",
1641
+ "tagTop": "_9FdZvq_tagTop",
1642
+ "cardDesc": "_9FdZvq_cardDesc",
1643
+ "riskFailed": "_9FdZvq_riskFailed",
1644
+ "severity": "_9FdZvq_severity",
1645
+ "status": "_9FdZvq_status",
1646
+ "audit": "_9FdZvq_audit",
1647
+ "findingHint": "_9FdZvq_findingHint",
1648
+ "reviewError": "_9FdZvq_reviewError",
1649
+ "notice": "_9FdZvq_notice",
1650
+ "tab": "_9FdZvq_tab",
1651
+ "detail": "_9FdZvq_detail",
1652
+ "cards": "_9FdZvq_cards",
1653
+ "emptyText": "_9FdZvq_emptyText",
1654
+ "cardTop": "_9FdZvq_cardTop",
1655
+ "tabActive": "_9FdZvq_tabActive",
1656
+ "risk": "_9FdZvq_risk",
1657
+ "demoTag": "_9FdZvq_demoTag"
1751
1658
  };
1752
1659
  //#endregion
1753
- //#region src/client/NotificationBell.tsx
1754
- /** Colour tone and glyph for one notification type, matching the automation-task rows. */
1755
- function notificationTone(type) {
1756
- if (type === "approved" || type === "published" || type === "success") return "success";
1757
- if (type === "rejected") return "danger";
1758
- if (type === "unpublished") return "warn";
1759
- return "info";
1760
- }
1761
- function NotificationIcon({ tone }) {
1762
- if (tone === "success") return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", {
1763
- width: "14",
1764
- height: "14",
1765
- viewBox: "0 0 16 16",
1766
- fill: "none",
1767
- "aria-hidden": "true",
1768
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("circle", {
1769
- cx: "8",
1770
- cy: "8",
1771
- r: "6.2",
1772
- stroke: "currentColor",
1773
- strokeWidth: "1.3"
1774
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
1775
- d: "m5.3 8.1 1.8 1.8 3.6-3.8",
1776
- stroke: "currentColor",
1777
- strokeWidth: "1.3",
1778
- strokeLinecap: "round",
1779
- strokeLinejoin: "round"
1780
- })]
1781
- });
1782
- if (tone === "danger") return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", {
1783
- width: "14",
1784
- height: "14",
1785
- viewBox: "0 0 16 16",
1786
- fill: "none",
1787
- "aria-hidden": "true",
1788
- children: [
1789
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
1790
- d: "M8 2.3 14 13H2L8 2.3Z",
1791
- stroke: "currentColor",
1792
- strokeWidth: "1.3",
1793
- strokeLinejoin: "round"
1794
- }),
1795
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
1796
- d: "M8 6v3.1",
1797
- stroke: "currentColor",
1798
- strokeWidth: "1.3",
1799
- strokeLinecap: "round"
1800
- }),
1801
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("circle", {
1802
- cx: "8",
1803
- cy: "11.2",
1804
- r: ".7",
1805
- fill: "currentColor"
1806
- })
1807
- ]
1808
- });
1809
- if (tone === "warn") return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", {
1810
- width: "14",
1811
- height: "14",
1812
- viewBox: "0 0 16 16",
1813
- fill: "none",
1814
- "aria-hidden": "true",
1815
- children: [
1816
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("circle", {
1817
- cx: "8",
1818
- cy: "8",
1819
- r: "6.2",
1820
- stroke: "currentColor",
1821
- strokeWidth: "1.3"
1822
- }),
1823
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
1824
- d: "M8 4.8v3.6",
1825
- stroke: "currentColor",
1826
- strokeWidth: "1.3",
1827
- strokeLinecap: "round"
1828
- }),
1829
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("circle", {
1830
- cx: "8",
1831
- cy: "11.1",
1832
- r: ".7",
1833
- fill: "currentColor"
1834
- })
1835
- ]
1836
- });
1837
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", {
1838
- width: "14",
1839
- height: "14",
1840
- viewBox: "0 0 16 16",
1841
- fill: "none",
1842
- "aria-hidden": "true",
1843
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
1844
- d: "M4 2.5h5l3 3v8H4v-11Z",
1845
- stroke: "currentColor",
1846
- strokeWidth: "1.2",
1847
- strokeLinejoin: "round"
1848
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
1849
- d: "M9 2.5v3h3M6 8h4M6 10.5h3",
1850
- stroke: "currentColor",
1851
- strokeWidth: "1.2",
1852
- strokeLinecap: "round"
1853
- })]
1854
- });
1855
- }
1856
- /**
1857
- * A bell with an unread badge and the shared inbox.
1858
- *
1859
- * The bell is a button rather than a menu so keyboard focus and Escape follow the dialog
1860
- * conventions the rest of the page already uses. Rows mark themselves read when opened;
1861
- * "全部已读" is the one bulk action.
1862
- */
1863
- function NotificationBell({ label, onOpen }) {
1864
- const state = (0, react.useSyncExternalStore)(subscribeNotifications, notificationSnapshot, notificationSnapshot);
1865
- const [open, setOpen] = (0, react.useState)(false);
1866
- const [page, setPage] = (0, react.useState)(0);
1867
- const items = sortNotifications(state.items);
1868
- const unread = unreadCount(items);
1869
- const pages = Math.max(1, Math.ceil(items.length / 20));
1870
- const visible = items.slice(page * 20, page * 20 + 20);
1871
- (0, react.useEffect)(() => {
1872
- if (page >= pages) setPage(pages - 1);
1873
- }, [page, pages]);
1874
- (0, react.useEffect)(() => {
1875
- loadNotifications();
1876
- }, []);
1877
- const openOne = (item) => {
1878
- markRead([item.id]);
1879
- setOpen(false);
1880
- onOpen?.(item);
1881
- };
1882
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
1883
- type: "button",
1884
- className: NotificationBell_module_css_default.bell,
1885
- "aria-label": unread === 0 ? label : label + "," + String(unread) + " 条未读",
1886
- title: label,
1887
- "data-notification-bell": "",
1888
- "data-unread": unread,
1889
- onClick: () => {
1890
- setOpen(true);
1891
- setPage(0);
1892
- loadNotifications();
1893
- },
1894
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", {
1895
- width: "16",
1896
- height: "16",
1897
- viewBox: "0 0 16 16",
1898
- fill: "none",
1899
- "aria-hidden": "true",
1900
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
1901
- d: "M8 2.2a4.1 4.1 0 0 0-4.1 4.1v2.3L2.7 10.8a.6.6 0 0 0 .5.9h9.6a.6.6 0 0 0 .5-.9L12.1 8.6V6.3A4.1 4.1 0 0 0 8 2.2Z",
1902
- stroke: "currentColor",
1903
- strokeWidth: "1.2",
1904
- strokeLinejoin: "round"
1905
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
1906
- d: "M6.4 13.2a1.7 1.7 0 0 0 3.2 0",
1907
- stroke: "currentColor",
1908
- strokeWidth: "1.2",
1909
- strokeLinecap: "round"
1910
- })]
1911
- }), unread === 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1912
- className: NotificationBell_module_css_default.badge,
1913
- children: unread > 99 ? "99+" : unread
1914
- })]
1915
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_deepseek_ai_dsh_client_ui_primitives.Modal, {
1916
- open,
1917
- onClose: () => {
1918
- setOpen(false);
1919
- },
1920
- title: label,
1921
- closeLabel: "关闭",
1922
- className: NotificationBell_module_css_default.dialog,
1923
- footer: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
1924
- className: NotificationBell_module_css_default.actions,
1925
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
1926
- type: "button",
1927
- className: NotificationBell_module_css_default.linkButton,
1928
- onClick: () => {
1929
- markRead("all");
1930
- },
1931
- children: "全部已读"
1932
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
1933
- type: "button",
1934
- className: NotificationBell_module_css_default.button,
1935
- onClick: () => {
1936
- setOpen(false);
1937
- },
1938
- children: "关闭"
1939
- })]
1940
- }),
1941
- children: [
1942
- reviewDemoMode() ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
1943
- className: NotificationBell_module_css_default.demo,
1944
- children: "演示数据 · 后端契约到达后自动切换"
1945
- }) : null,
1946
- state.status === "unavailable" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
1947
- className: NotificationBell_module_css_default.empty,
1948
- children: "通知服务待后端联调(task-35);上线后这里会显示审核、上架与 AI 报告事件。"
1949
- }) : null,
1950
- state.status !== "unavailable" && items.length === 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
1951
- className: NotificationBell_module_css_default.empty,
1952
- children: "暂无通知。"
1953
- }) : null,
1954
- items.length === 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("ul", {
1955
- className: NotificationBell_module_css_default.list,
1956
- children: visible.map((item) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("li", { children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
1957
- type: "button",
1958
- className: NotificationBell_module_css_default.row,
1959
- onClick: () => {
1960
- openOne(item);
1961
- },
1962
- children: [
1963
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1964
- className: NotificationBell_module_css_default.rowIcon,
1965
- "data-tone": notificationTone(item.type),
1966
- "aria-hidden": "true",
1967
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(NotificationIcon, { tone: notificationTone(item.type) })
1968
- }),
1969
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
1970
- className: NotificationBell_module_css_default.rowBody,
1971
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1972
- className: NotificationBell_module_css_default.rowTitle,
1973
- children: item.title
1974
- }), item.body === void 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1975
- className: NotificationBell_module_css_default.rowText,
1976
- children: item.body
1977
- })]
1978
- }),
1979
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
1980
- className: NotificationBell_module_css_default.rowMeta,
1981
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1982
- className: NotificationBell_module_css_default.rowTime,
1983
- children: item.createdAt.slice(0, 16).replace("T", " ")
1984
- }), item.read ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
1985
- className: NotificationBell_module_css_default.dot,
1986
- "aria-hidden": "true"
1987
- })]
1988
- })
1989
- ]
1990
- }) }, item.id))
1991
- }),
1992
- items.length === 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
1993
- className: NotificationBell_module_css_default.pager,
1994
- children: [
1995
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
1996
- type: "button",
1997
- disabled: page === 0,
1998
- onClick: () => {
1999
- setPage((current) => Math.max(0, current - 1));
2000
- },
2001
- children: "上一页"
2002
- }),
2003
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", { children: [
2004
- "第 ",
2005
- page + 1,
2006
- " / ",
2007
- pages,
2008
- " 页 · 共 ",
2009
- items.length,
2010
- " 条"
2011
- ] }),
2012
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
2013
- type: "button",
2014
- disabled: page >= pages - 1,
2015
- onClick: () => {
2016
- setPage((current) => Math.min(pages - 1, current + 1));
2017
- },
2018
- children: "下一页"
2019
- })
2020
- ]
2021
- })
2022
- ]
2023
- })] });
2024
- }
2025
- /** The automation page's seat: the same inbox under the workflow plaza's heading. */
2026
- function WorkflowPlazaBell() {
2027
- return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(NotificationBell, { label: "自动化任务通知" });
2028
- }
2029
- //#endregion
2030
- //#region \0dsh-css:/root/projects/dsh-plugins-plus/packages/dataops-managed/src/client/SkillPlazaSection.module.css.mjs
2031
- const css$3 = "._9FdZvq_section{box-sizing:border-box;flex-direction:column;width:100%;max-width:960px;margin:0 auto;display:flex}._9FdZvq_head{flex-direction:column;margin-bottom:8px;display:flex}._9FdZvq_title{color:var(--dsw-alias-label-primary);align-items:baseline;gap:8px;margin:0;font-size:14px;font-weight:500;line-height:20px;display:flex}._9FdZvq_titleCount{color:var(--dsw-alias-label-tertiary);font-size:12px;font-weight:400}._9FdZvq_status{text-align:center;color:var(--dsw-alias-label-tertiary);margin:0;padding:20px 0;font-size:13px;line-height:20px}._9FdZvq_departmentBar{align-items:center;gap:8px;margin-bottom:10px;display:inline-flex}._9FdZvq_departmentLabel{color:var(--dsw-alias-label-secondary);font-size:12px;line-height:18px}._9FdZvq_departmentSelect{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-1);height:28px;color:var(--dsw-alias-label-primary);font:inherit;border-radius:8px;padding:0 8px;font-size:12px;line-height:18px}._9FdZvq_departmentSelect:focus-visible{outline:2px solid var(--dsw-alias-brand-primary);outline-offset:1px}._9FdZvq_notice{color:var(--dsw-alias-state-business-primary);margin:4px 0 0;font-size:12px;line-height:18px}._9FdZvq_cards{grid-template-columns:repeat(auto-fill,minmax(272px,1fr));grid-auto-rows:max-content;align-content:start;align-items:stretch;gap:12px;margin:0;padding:0;list-style:none;display:grid}._9FdZvq_card{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-1);border-radius:10px;flex-direction:column;align-self:stretch;gap:10px;min-width:0;height:auto;padding:12px;display:flex}._9FdZvq_cardTop{justify-content:space-between;align-items:center;gap:10px;min-height:28px;display:flex}._9FdZvq_cardIcon{background:var(--dsw-alias-bg-layer-2);width:28px;height:28px;color:var(--dsw-alias-label-secondary);border-radius:50%;flex:none;place-items:center;display:grid}._9FdZvq_cardTitle{text-overflow:ellipsis;white-space:nowrap;flex:1;min-width:0;font-size:14px;font-weight:600;line-height:20px;overflow:hidden}._9FdZvq_mine{flex:none}._9FdZvq_cardDesc{min-height:36px;color:var(--dsw-alias-label-secondary);-webkit-line-clamp:2;-webkit-box-orient:vertical;font-size:12px;line-height:18px;display:-webkit-box;overflow:hidden}._9FdZvq_cardMarks{flex-wrap:wrap;align-content:flex-start;gap:6px;min-height:20px;display:flex}._9FdZvq_mark{background:color-mix(in srgb, var(--dsw-alias-state-business-primary) 14%, var(--dsw-alias-bg-layer-1));color:var(--dsw-alias-state-business-primary);white-space:nowrap;border:0;border-radius:4px;padding:2px 7px;font-size:11px;font-weight:500;line-height:16px}._9FdZvq_cardEnd{flex:none;align-items:center;gap:4px;margin-top:auto;padding-top:4px;display:flex}._9FdZvq_detailButton{margin-left:auto}._9FdZvq_detail{flex-direction:column;gap:12px;margin:0;display:flex}._9FdZvq_dialog{width:min(560px,100%)}._9FdZvq_detailRow{flex-direction:column;gap:2px;display:flex}._9FdZvq_detailLabel{color:var(--dsw-alias-label-caption);font-size:11px;line-height:16px}._9FdZvq_detailValue{max-height:160px;color:var(--dsw-alias-label-secondary);white-space:pre-wrap;overflow-wrap:anywhere;margin:0;font-size:12px;line-height:18px;overflow:auto}._9FdZvq_empty{text-align:center;flex-direction:column;align-items:center;gap:10px;padding:28px 16px 32px;display:flex}._9FdZvq_emptyIcon{border:.5px solid var(--dsw-alias-border-l3);width:56px;height:56px;color:var(--dsw-alias-label-tertiary);border-radius:14px;justify-content:center;align-items:center;display:inline-flex}._9FdZvq_emptyText{color:var(--dsw-alias-label-tertiary);margin:0;font-size:13px;line-height:20px}._9FdZvq_headRow{align-items:center;gap:6px;display:flex}._9FdZvq_headRow ._9FdZvq_title{flex:none}._9FdZvq_demoTag{background:var(--dsw-alias-state-warn-secondary);color:var(--dsw-alias-state-warn-primary);border-radius:4px;padding:1px 6px;font-size:10px;line-height:16px}._9FdZvq_tabs{border-bottom:1px solid var(--dsw-alias-border-l1);align-items:center;gap:2px;margin-bottom:8px;display:flex}._9FdZvq_tab{height:30px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:0;border-bottom:2px solid #0000;align-items:center;gap:5px;padding:0 9px;font-size:12px;display:inline-flex}._9FdZvq_tab:hover{color:var(--dsw-alias-label-primary)}._9FdZvq_tabActive{color:var(--dsw-alias-state-business-primary);border-bottom-color:var(--dsw-alias-state-business-primary);font-weight:500}._9FdZvq_tabCount{background:var(--dsw-alias-bg-layer-2);color:var(--dsw-alias-label-tertiary);border-radius:7px;padding:0 4px;font-size:10px;line-height:14px}._9FdZvq_tagTop{text-overflow:ellipsis;white-space:nowrap;border:1px solid var(--dsw-alias-border-l2);max-width:40%;color:var(--dsw-alias-label-secondary);border-radius:4px;flex:none;padding:1px 6px;font-size:10px;line-height:16px;overflow:hidden}._9FdZvq_sharedTag{color:#fff;background:#0e6b3a;border-radius:4px;padding:2px 7px;font-size:11px;font-weight:600;line-height:16px}._9FdZvq_pendingTag{color:#fff;background:#7a4a00;border-radius:4px;padding:2px 7px;font-size:11px;font-weight:600;line-height:16px}._9FdZvq_rejectedTag{color:#fff;background:#a8231b;border-radius:4px;padding:2px 7px;font-size:11px;font-weight:600;line-height:16px}._9FdZvq_reviewButton{margin-left:auto}._9FdZvq_reviewNote{border-left:3px solid var(--dsw-alias-state-error-primary);background:color-mix(in srgb, var(--dsw-alias-state-error-primary) 10%, var(--dsw-alias-bg-layer-1));color:var(--dsw-alias-label-primary);margin:0;padding:6px 8px;font-size:11px;line-height:16px}._9FdZvq_auditDialog{width:min(640px,100vw - 32px)}._9FdZvq_audit{flex-direction:column;gap:14px;display:flex}._9FdZvq_auditFooter{justify-content:flex-end;gap:6px;display:flex}._9FdZvq_risk{border:1px solid var(--dsw-alias-border-l1);background:var(--dsw-alias-bg-layer-1);border-radius:6px;flex-direction:column;gap:8px;padding:10px;display:flex}._9FdZvq_riskHead{justify-content:space-between;align-items:center;gap:8px;font-size:12px;display:flex}._9FdZvq_riskEmpty,._9FdZvq_riskFailed{color:var(--dsw-alias-label-tertiary);margin:0;font-size:11px;line-height:16px}._9FdZvq_riskFailed{color:var(--dsw-alias-state-error-primary)}._9FdZvq_riskSummary{color:var(--dsw-alias-label-secondary);flex-wrap:wrap;align-items:center;gap:6px;font-size:12px;line-height:18px;display:flex}._9FdZvq_riskScore{color:var(--dsw-alias-label-primary);font-weight:600}._9FdZvq_severity{background:var(--dsw-alias-bg-layer-2);color:var(--dsw-alias-label-secondary);text-transform:uppercase;border-radius:3px;padding:0 5px;font-size:10px;line-height:16px}._9FdZvq_severity[data-severity=high],._9FdZvq_severity[data-severity=critical]{background:var(--dsw-alias-state-error-secondary);color:var(--dsw-alias-state-error-primary)}._9FdZvq_severity[data-severity=medium]{background:var(--dsw-alias-state-warn-secondary);color:var(--dsw-alias-state-warn-primary)}._9FdZvq_findings{flex-direction:column;gap:6px;margin:0;padding:0;list-style:none;display:flex}._9FdZvq_finding{flex-wrap:wrap;align-items:baseline;gap:5px;font-size:11px;line-height:16px;display:flex}._9FdZvq_findingText{color:var(--dsw-alias-label-secondary);flex-basis:100%}._9FdZvq_findingHint{color:var(--dsw-alias-label-tertiary);flex-basis:100%}._9FdZvq_noteField{color:var(--dsw-alias-label-secondary);flex-direction:column;gap:5px;font-size:12px;display:flex}._9FdZvq_noteField textarea{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-base);min-height:64px;color:var(--dsw-alias-label-primary);font:inherit;resize:vertical;border-radius:5px;padding:7px 9px}._9FdZvq_reviewError{color:var(--dsw-alias-state-error-primary);margin:0;font-size:11px}";
2032
- const tagId$3 = "@sparkelf/dsh-dataops-managed/SkillPlazaSection.module.css";
2033
- if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$3) + "]") === null) {
2034
- const tag = document.createElement("style");
2035
- tag.dataset.plugin = "@sparkelf/dsh-dataops-managed";
2036
- tag.dataset.pluginCss = tagId$3;
2037
- tag.textContent = css$3;
2038
- document.head.appendChild(tag);
2039
- }
2040
- var SkillPlazaSection_module_css_default = {
2041
- "tab": "_9FdZvq_tab",
2042
- "severity": "_9FdZvq_severity",
2043
- "detailRow": "_9FdZvq_detailRow",
2044
- "cards": "_9FdZvq_cards",
2045
- "finding": "_9FdZvq_finding",
2046
- "emptyText": "_9FdZvq_emptyText",
2047
- "riskEmpty": "_9FdZvq_riskEmpty",
2048
- "findingText": "_9FdZvq_findingText",
2049
- "findingHint": "_9FdZvq_findingHint",
2050
- "tabCount": "_9FdZvq_tabCount",
2051
- "departmentSelect": "_9FdZvq_departmentSelect",
2052
- "departmentBar": "_9FdZvq_departmentBar",
2053
- "cardTop": "_9FdZvq_cardTop",
2054
- "riskFailed": "_9FdZvq_riskFailed",
2055
- "titleCount": "_9FdZvq_titleCount",
2056
- "riskHead": "_9FdZvq_riskHead",
2057
- "findings": "_9FdZvq_findings",
2058
- "noteField": "_9FdZvq_noteField",
2059
- "reviewError": "_9FdZvq_reviewError",
2060
- "rejectedTag": "_9FdZvq_rejectedTag",
2061
- "cardMarks": "_9FdZvq_cardMarks",
2062
- "cardIcon": "_9FdZvq_cardIcon",
2063
- "risk": "_9FdZvq_risk",
2064
- "auditDialog": "_9FdZvq_auditDialog",
2065
- "mine": "_9FdZvq_mine",
2066
- "section": "_9FdZvq_section",
2067
- "mark": "_9FdZvq_mark",
2068
- "dialog": "_9FdZvq_dialog",
2069
- "detailValue": "_9FdZvq_detailValue",
2070
- "empty": "_9FdZvq_empty",
2071
- "tabs": "_9FdZvq_tabs",
2072
- "pendingTag": "_9FdZvq_pendingTag",
2073
- "riskScore": "_9FdZvq_riskScore",
2074
- "riskSummary": "_9FdZvq_riskSummary",
2075
- "cardEnd": "_9FdZvq_cardEnd",
2076
- "demoTag": "_9FdZvq_demoTag",
2077
- "detailButton": "_9FdZvq_detailButton",
2078
- "detail": "_9FdZvq_detail",
2079
- "cardDesc": "_9FdZvq_cardDesc",
2080
- "headRow": "_9FdZvq_headRow",
2081
- "sharedTag": "_9FdZvq_sharedTag",
2082
- "reviewNote": "_9FdZvq_reviewNote",
2083
- "audit": "_9FdZvq_audit",
2084
- "departmentLabel": "_9FdZvq_departmentLabel",
2085
- "auditFooter": "_9FdZvq_auditFooter",
2086
- "status": "_9FdZvq_status",
2087
- "title": "_9FdZvq_title",
2088
- "emptyIcon": "_9FdZvq_emptyIcon",
2089
- "tagTop": "_9FdZvq_tagTop",
2090
- "head": "_9FdZvq_head",
2091
- "tabActive": "_9FdZvq_tabActive",
2092
- "card": "_9FdZvq_card",
2093
- "reviewButton": "_9FdZvq_reviewButton",
2094
- "cardTitle": "_9FdZvq_cardTitle",
2095
- "notice": "_9FdZvq_notice",
2096
- "detailLabel": "_9FdZvq_detailLabel"
2097
- };
2098
- //#endregion
2099
- //#region src/client/SkillPlazaSection.tsx
2100
- /** Tab counts from the same visible rows the cards render. */
2101
- function countsOf(skills) {
2102
- const counted = reviewCounts(skills);
2103
- return {
2104
- approved: counted.approved,
2105
- pending: counted.pending,
2106
- rejected: skills.filter((row) => row.reviewStatus === "rejected").length,
2107
- total: counted.all
2108
- };
1660
+ //#region src/client/SkillPlazaSection.tsx
1661
+ /** Tab counts from the same visible rows the cards render. */
1662
+ function countsOf(skills) {
1663
+ const counted = reviewCounts(skills);
1664
+ return {
1665
+ approved: counted.approved,
1666
+ pending: counted.pending,
1667
+ rejected: skills.filter((row) => row.reviewStatus === "rejected").length,
1668
+ total: counted.all
1669
+ };
2109
1670
  }
2110
1671
  /**
2111
1672
  * The department a plaza row belongs to.
@@ -2487,26 +2048,16 @@ window.__ModuleLoader__.load({
2487
2048
  className: SkillPlazaSection_module_css_default.head,
2488
2049
  children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
2489
2050
  className: SkillPlazaSection_module_css_default.headRow,
2490
- children: [
2491
- /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("h2", {
2492
- className: SkillPlazaSection_module_css_default.title,
2493
- children: [t("plazaTitle"), count === null ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2494
- className: SkillPlazaSection_module_css_default.titleCount,
2495
- children: count
2496
- })]
2497
- }),
2498
- reviewDemoMode() ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2499
- className: SkillPlazaSection_module_css_default.demoTag,
2500
- children: t("plazaDemo")
2501
- }) : null,
2502
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)(NotificationBell, {
2503
- label: t("plazaTitle") + "通知",
2504
- onOpen: (item) => {
2505
- const next = notificationTab(item);
2506
- if (next !== void 0) setTab(next);
2507
- }
2508
- })
2509
- ]
2051
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("h2", {
2052
+ className: SkillPlazaSection_module_css_default.title,
2053
+ children: [t("plazaTitle"), count === null ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2054
+ className: SkillPlazaSection_module_css_default.titleCount,
2055
+ children: count
2056
+ })]
2057
+ }), reviewDemoMode() ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
2058
+ className: SkillPlazaSection_module_css_default.demoTag,
2059
+ children: t("plazaDemo")
2060
+ }) : null]
2510
2061
  })
2511
2062
  });
2512
2063
  if (state.kind === "unavailable") return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("section", {
@@ -2748,28 +2299,28 @@ window.__ModuleLoader__.load({
2748
2299
  }
2749
2300
  //#endregion
2750
2301
  //#region \0dsh-css:/root/projects/dsh-plugins-plus/packages/dataops-managed/src/client/WanxiangBrand.module.css.mjs
2751
- const css$2 = ".s0HPxG_mark{color:inherit;flex:none;display:block;overflow:visible}.s0HPxG_animatedMark{cursor:pointer}.s0HPxG_mark g{transform-box:fill-box;transform-origin:50%}.s0HPxG_sidebarName{min-width:0;height:24px;color:inherit;align-items:center;gap:6px;display:inline-flex}.s0HPxG_sidebarName>:first-child{flex:0 auto;min-width:0;max-width:102px}.s0HPxG_wordmark{letter-spacing:.01em;white-space:nowrap;text-overflow:ellipsis;font-family:PingFang SC,HarmonyOS Sans SC,Microsoft YaHei,Noto Sans CJK SC,Source Han Sans SC,sans-serif;font-weight:600;line-height:1;display:block;overflow:hidden}.s0HPxG_harness{flex:none;display:block;overflow:visible}@keyframes s0HPxG_unit-top{0%,to{transform:translate(0)}50%{transform:translateY(-2px)}}@keyframes s0HPxG_unit-left{0%,to{transform:translate(0)}50%{transform:translate(-2px,1px)}}@keyframes s0HPxG_unit-right{0%,to{transform:translate(0)}50%{transform:translate(2px,1px)}}@keyframes s0HPxG_unit-core{0%,to{transform:translate(0)}50%{transform:translateY(2px)}}@media (hover:hover) and (prefers-reduced-motion:no-preference){.s0HPxG_animatedMark:hover .s0HPxG_unitTop{animation:1.6s ease-in-out infinite s0HPxG_unit-top}.s0HPxG_animatedMark:hover .s0HPxG_unitLeft{animation:1.6s ease-in-out infinite s0HPxG_unit-left}.s0HPxG_animatedMark:hover .s0HPxG_unitRight{animation:1.6s ease-in-out infinite s0HPxG_unit-right}.s0HPxG_animatedMark:hover .s0HPxG_unitCore{animation:1.6s ease-in-out infinite s0HPxG_unit-core}}@media (prefers-reduced-motion:reduce){.s0HPxG_animatedMark,.s0HPxG_animatedMark g{animation:none!important;transform:none!important}}";
2752
- const tagId$2 = "@sparkelf/dsh-dataops-managed/WanxiangBrand.module.css";
2753
- if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$2) + "]") === null) {
2302
+ const css$3 = ".s0HPxG_mark{color:inherit;flex:none;display:block;overflow:visible}.s0HPxG_animatedMark{cursor:pointer}.s0HPxG_mark g{transform-box:fill-box;transform-origin:50%}.s0HPxG_sidebarName{min-width:0;height:24px;color:inherit;align-items:center;gap:6px;display:inline-flex}.s0HPxG_sidebarName>:first-child{flex:0 auto;min-width:0;max-width:102px}.s0HPxG_wordmark{letter-spacing:.01em;white-space:nowrap;text-overflow:ellipsis;font-family:PingFang SC,HarmonyOS Sans SC,Microsoft YaHei,Noto Sans CJK SC,Source Han Sans SC,sans-serif;font-weight:600;line-height:1;display:block;overflow:hidden}.s0HPxG_harness{flex:none;display:block;overflow:visible}@keyframes s0HPxG_unit-top{0%,to{transform:translate(0)}50%{transform:translateY(-2px)}}@keyframes s0HPxG_unit-left{0%,to{transform:translate(0)}50%{transform:translate(-2px,1px)}}@keyframes s0HPxG_unit-right{0%,to{transform:translate(0)}50%{transform:translate(2px,1px)}}@keyframes s0HPxG_unit-core{0%,to{transform:translate(0)}50%{transform:translateY(2px)}}@media (hover:hover) and (prefers-reduced-motion:no-preference){.s0HPxG_animatedMark:hover .s0HPxG_unitTop{animation:1.6s ease-in-out infinite s0HPxG_unit-top}.s0HPxG_animatedMark:hover .s0HPxG_unitLeft{animation:1.6s ease-in-out infinite s0HPxG_unit-left}.s0HPxG_animatedMark:hover .s0HPxG_unitRight{animation:1.6s ease-in-out infinite s0HPxG_unit-right}.s0HPxG_animatedMark:hover .s0HPxG_unitCore{animation:1.6s ease-in-out infinite s0HPxG_unit-core}}@media (prefers-reduced-motion:reduce){.s0HPxG_animatedMark,.s0HPxG_animatedMark g{animation:none!important;transform:none!important}}";
2303
+ const tagId$3 = "@sparkelf/dsh-dataops-managed/WanxiangBrand.module.css";
2304
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$3) + "]") === null) {
2754
2305
  const tag = document.createElement("style");
2755
2306
  tag.dataset.plugin = "@sparkelf/dsh-dataops-managed";
2756
- tag.dataset.pluginCss = tagId$2;
2757
- tag.textContent = css$2;
2307
+ tag.dataset.pluginCss = tagId$3;
2308
+ tag.textContent = css$3;
2758
2309
  document.head.appendChild(tag);
2759
2310
  }
2760
2311
  var WanxiangBrand_module_css_default = {
2761
- "unit-right": "s0HPxG_unit-right",
2762
2312
  "unitCore": "s0HPxG_unitCore",
2313
+ "mark": "s0HPxG_mark",
2314
+ "unit-left": "s0HPxG_unit-left",
2763
2315
  "sidebarName": "s0HPxG_sidebarName",
2764
2316
  "unit-top": "s0HPxG_unit-top",
2765
- "mark": "s0HPxG_mark",
2766
2317
  "harness": "s0HPxG_harness",
2318
+ "unit-core": "s0HPxG_unit-core",
2767
2319
  "wordmark": "s0HPxG_wordmark",
2320
+ "unit-right": "s0HPxG_unit-right",
2321
+ "unitLeft": "s0HPxG_unitLeft",
2768
2322
  "unitTop": "s0HPxG_unitTop",
2769
2323
  "unitRight": "s0HPxG_unitRight",
2770
- "unit-left": "s0HPxG_unit-left",
2771
- "unit-core": "s0HPxG_unit-core",
2772
- "unitLeft": "s0HPxG_unitLeft",
2773
2324
  "animatedMark": "s0HPxG_animatedMark"
2774
2325
  };
2775
2326
  //#endregion
@@ -3177,102 +2728,102 @@ window.__ModuleLoader__.load({
3177
2728
  }
3178
2729
  //#endregion
3179
2730
  //#region \0dsh-css:/root/projects/dsh-plugins-plus/packages/dataops-managed/src/client/PermissionCenterSection.module.css.mjs
3180
- const css$1 = ".PNbOqW_page{box-sizing:border-box;flex-direction:column;gap:14px;width:100%;max-width:clamp(1000px,60vw,1200px);min-height:0;margin:0 auto;padding:24px;display:flex}.PNbOqW_head{justify-content:space-between;align-items:center;gap:12px;display:flex}.PNbOqW_headText{min-width:0}.PNbOqW_headActions{flex:none;align-items:center;gap:8px;display:flex}.PNbOqW_title{color:var(--dsw-alias-label-primary);margin:0;font-size:20px;font-weight:600;line-height:28px}.PNbOqW_subtitle{color:var(--dsw-alias-label-tertiary);align-items:center;gap:6px;margin:3px 0 0;font-size:12px;display:flex}.PNbOqW_demo{color:#9a5b00;background:#fff3e0;border-radius:4px;padding:1px 6px;font-size:10px;line-height:16px}.PNbOqW_tabs{border-bottom:1px solid var(--dsw-alias-border-l1);scrollbar-width:none;flex-wrap:nowrap;align-items:center;gap:0;display:flex;overflow:auto hidden}.PNbOqW_tabs::-webkit-scrollbar{display:none}.PNbOqW_tabGroup{flex:none;align-items:center;gap:4px;display:flex}.PNbOqW_tabDivider{background:#ffffff1f;flex:none;align-self:center;width:1px;height:14px;margin:0 12px}.PNbOqW_tab{height:34px;color:var(--dsw-alias-label-secondary,#8ea6c6);cursor:pointer;white-space:nowrap;background:0 0;border:0;border-bottom:2px solid #0000;border-radius:4px 4px 0 0;align-items:center;gap:6px;padding:0 10px;font-size:13px;font-weight:400;display:inline-flex}.PNbOqW_tab:hover{background:#ffffff0a}.PNbOqW_tabActive{color:var(--dsw-alias-label-primary,#fff);border-bottom-color:var(--dsw-alias-brand-primary,#2563eb);font-weight:600}.PNbOqW_tabBadge{background:var(--dsw-alias-bg-layer-2);min-width:18px;height:16px;color:var(--dsw-alias-label-caption);font-variant-numeric:tabular-nums;border-radius:999px;justify-content:center;align-items:center;padding:0 5px;font-size:10px;font-weight:500;display:inline-flex}.PNbOqW_notice,.PNbOqW_waiting{background:var(--dsw-alias-bg-layer-1);color:var(--dsw-alias-label-secondary);border-radius:5px;margin:0;padding:8px 10px;font-size:12px}.PNbOqW_waiting{border:1px dashed var(--dsw-alias-border-l2);color:var(--dsw-alias-label-tertiary)}.PNbOqW_panel{border:1px solid var(--dsw-alias-border-l1);background:var(--dsw-alias-bg-layer-1);border-radius:8px;flex-direction:column;gap:10px;min-height:0;padding:14px;display:flex}.PNbOqW_sectionTitle{margin:0;font-size:13px;font-weight:600}.PNbOqW_matrixHead{justify-content:space-between;align-items:center;gap:12px;display:flex}.PNbOqW_matrixHeadLeft{align-items:center;gap:8px;display:flex}.PNbOqW_matrixTool{width:24px;height:24px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:0;border-radius:6px;place-items:center;padding:0;font-size:15px;line-height:1;display:inline-grid}.PNbOqW_matrixTool:hover{color:var(--dsw-alias-label-primary);background:#ffffff0f}.PNbOqW_matrixToolActive{color:#2563eb;background:#2563eb26}.PNbOqW_matrixPermHead{text-align:left;white-space:normal;min-width:116px;max-width:140px;font-weight:500}.PNbOqW_matrixRoleHead,.PNbOqW_matrixRoleCell{white-space:nowrap}.PNbOqW_roleSearchWrap{flex:none;width:240px;max-width:100%;display:inline-flex;position:relative}.PNbOqW_roleSearchIcon{color:#8ea6c6;pointer-events:none;width:16px;height:16px;transition:color .12s;position:absolute;top:50%;left:10px;transform:translateY(-50%)}.PNbOqW_roleSearchWrap:focus-within .PNbOqW_roleSearchIcon{color:#2563eb}.PNbOqW_roleSearch{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-2);width:100%;height:30px;color:var(--dsw-alias-label-primary);font:var(--dsw-font-xxs-12);border-radius:6px;outline:none;padding:0 10px 0 34px}.PNbOqW_roleSearch::placeholder{color:var(--dsw-alias-label-caption)}.PNbOqW_roleSearch:focus{border-color:var(--dsw-alias-brand-primary,#2563eb)}.PNbOqW_empty{text-align:center;color:var(--dsw-alias-label-caption);margin:0;padding:28px 12px;font-size:12px}.PNbOqW_matrixScroll,.PNbOqW_tableScroll{overscroll-behavior:contain;scrollbar-gutter:stable;max-height:clamp(280px,100dvh - 340px,520px);overflow:auto}.PNbOqW_matrix,.PNbOqW_table{border-collapse:collapse;width:100%;font-size:12px}.PNbOqW_matrix th,.PNbOqW_matrix td,.PNbOqW_table th,.PNbOqW_table td{border-bottom:1px solid var(--dsw-alias-border-l1);text-align:left;vertical-align:top;padding:7px 9px}.PNbOqW_matrix th,.PNbOqW_table th{background:var(--dsw-alias-bg-layer-2);color:var(--dsw-alias-label-secondary);white-space:nowrap;font-weight:600}.PNbOqW_permission{white-space:nowrap;color:var(--dsw-alias-label-secondary);align-items:center;gap:5px;font-size:11px;line-height:20px;display:flex}.PNbOqW_panelFoot{flex-wrap:wrap;justify-content:flex-end;align-items:center;gap:6px;display:flex}.PNbOqW_readOnly{color:var(--dsw-alias-label-tertiary);margin-right:auto;font-size:11px}.PNbOqW_muted{color:var(--dsw-alias-label-tertiary);font-size:11px}.PNbOqW_departments{flex-direction:column;gap:4px;margin:0;padding:0;list-style:none;display:flex}.PNbOqW_department{border-bottom:1px solid var(--dsw-alias-border-l1);justify-content:space-between;align-items:center;gap:12px;padding:9px 8px;font-size:12px;display:flex}.PNbOqW_deptAdmins{align-items:center;gap:5px;display:flex}.PNbOqW_adminTag{color:var(--dsw-alias-state-business-primary);background:#ecf1fc;border-radius:4px;padding:1px 6px;font-size:11px}.PNbOqW_empty{text-align:center;color:var(--dsw-alias-label-tertiary);margin:0;padding:40px 0}.PNbOqW_matrixScroll{overscroll-behavior:contain;scrollbar-gutter:stable;max-height:clamp(280px,100dvh - 340px,520px);overflow:auto}.PNbOqW_matrix thead th{z-index:2;position:sticky;top:0}.PNbOqW_matrix thead th:first-child,.PNbOqW_matrix tbody th{background:var(--dsw-alias-bg-layer-2);min-width:132px;position:sticky;left:0}.PNbOqW_matrix thead th:first-child{z-index:3}.PNbOqW_matrix tbody th{z-index:1;background:var(--dsw-alias-bg-layer-1)}.PNbOqW_protected{background:var(--dsw-alias-bg-layer-2);color:var(--dsw-alias-label-tertiary);white-space:nowrap;border-radius:3px;margin-left:5px;padding:0 5px;font-size:10px;font-weight:500;line-height:16px;display:inline-block}tr[data-locked=true] td{opacity:.62}.PNbOqW_pager{justify-content:flex-end;align-items:center;gap:8px;padding-top:8px;display:flex}.PNbOqW_dialog{width:min(560px,100vw - 32px)}.PNbOqW_dialogBody{flex-direction:column;gap:10px;display:flex}.PNbOqW_dialogHint{color:var(--dsw-alias-label-secondary);margin:0;font-size:12px;line-height:18px}.PNbOqW_search{box-sizing:border-box;border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-base);width:100%;height:30px;color:var(--dsw-alias-label-primary);font:var(--dsw-font-xs-13);border-radius:5px;padding:0 9px}.PNbOqW_candidates{flex-direction:column;gap:2px;max-height:260px;margin:0;padding:0;list-style:none;display:flex;overflow:auto}.PNbOqW_candidate{cursor:pointer;border-radius:5px;align-items:center;gap:7px;padding:6px 7px;font-size:12px;display:flex}.PNbOqW_candidate:hover{background:var(--dsw-alias-interactive-bg-hover)}.PNbOqW_error{color:var(--dsw-alias-state-error-primary);margin:0;font-size:11px;line-height:16px}.PNbOqW_dialogFooter{justify-content:flex-end;gap:6px;display:flex}.PNbOqW_matrixNote{color:var(--dsw-alias-label-tertiary);margin:6px 0 0;font-size:11px;line-height:16px}.PNbOqW_panelHead{justify-content:space-between;align-items:center;gap:10px;display:flex}.PNbOqW_treeRoot,.PNbOqW_treeChildren{margin:0;padding:0;list-style:none}.PNbOqW_treeChildren{border-left:1px solid var(--dsw-alias-border-l1);margin-left:18px}.PNbOqW_treeRow{border-bottom:1px solid var(--dsw-alias-border-l1);align-items:center;gap:7px;min-height:34px;font-size:12px;display:flex}.PNbOqW_treeToggle,.PNbOqW_treeSpacer{flex:none;justify-content:center;align-items:center;width:18px;height:18px;display:inline-flex}.PNbOqW_treeToggle{color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:0;border-radius:3px;font-size:11px}.PNbOqW_treeToggle:hover{background:var(--dsw-alias-interactive-bg-hover)}.PNbOqW_treeName{color:var(--dsw-alias-label-primary);white-space:nowrap;font-weight:600}.PNbOqW_treeActions{align-items:center;gap:2px;margin-left:auto;display:flex}.PNbOqW_field{color:var(--dsw-alias-label-secondary);flex-direction:column;gap:5px;font-size:12px;display:flex}.PNbOqW_field input,.PNbOqW_field select{box-sizing:border-box;border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-base);width:100%;height:30px;color:var(--dsw-alias-label-primary);font:var(--dsw-font-xs-13);border-radius:5px;padding:0 9px}.PNbOqW_field input:disabled{opacity:.65}.PNbOqW_matrixModule{vertical-align:top;background:var(--dsw-alias-bg-layer-2);min-width:96px;color:var(--dsw-alias-label-secondary);text-align:left;border-right:1px solid var(--dsw-alias-border-l1);padding:10px 9px;font-size:12px;font-weight:600}.PNbOqW_matrixGroup th{background:var(--dsw-alias-bg-layer-2);color:var(--dsw-alias-label-secondary);text-align:left;padding:7px 9px;font-size:12px;font-weight:600}.PNbOqW_matrixPermission{white-space:nowrap;min-width:230px}.PNbOqW_scopeBadge{border-radius:3px;margin-left:6px;padding:0 5px;font-size:10px;font-weight:500;line-height:16px;display:inline-block}.PNbOqW_scopeBadge[data-scope=department]{background:color-mix(in srgb, var(--dsw-alias-state-business-primary) 14%, var(--dsw-alias-bg-layer-1));color:var(--dsw-alias-state-business-primary)}.PNbOqW_scopeBadge[data-scope=global]{background:color-mix(in srgb, var(--dsw-alias-state-warn-primary) 16%, var(--dsw-alias-bg-layer-1));color:var(--dsw-alias-state-warn-primary)}.PNbOqW_onlyAdmin{color:var(--dsw-alias-label-tertiary);white-space:nowrap;margin-left:4px;font-size:10px}.PNbOqW_permCopy{max-width:100%;color:var(--dsw-alias-label-primary);font:inherit;text-align:left;cursor:pointer;background:0 0;border:0;align-items:center;gap:2px;padding:0;display:inline-flex}.PNbOqW_permCopy:hover span:first-child{color:var(--dsw-alias-state-business-primary);text-decoration:underline dotted}.PNbOqW_permDescription{color:var(--dsw-alias-label-tertiary);white-space:normal;margin-top:2px;font-size:10px;font-weight:400;line-height:15px;display:block}.PNbOqW_copied{color:var(--dsw-alias-state-success-primary);margin-left:4px;font-size:10px}.PNbOqW_combobox{min-width:132px;position:relative}.PNbOqW_comboboxTrigger{box-sizing:border-box;border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-base);width:100%;height:28px;color:var(--dsw-alias-label-primary);font:var(--dsw-font-xs-13);text-align:left;cursor:pointer;border-radius:5px;justify-content:space-between;align-items:center;gap:8px;padding:0 8px;display:flex}.PNbOqW_comboboxTrigger:hover:not(:disabled){border-color:var(--dsw-alias-state-business-primary)}.PNbOqW_comboboxTrigger:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary);outline-offset:1px}.PNbOqW_comboboxTrigger:disabled{opacity:.55;cursor:default}.PNbOqW_comboboxPlaceholder{color:var(--dsw-alias-label-tertiary)}.PNbOqW_comboboxMenu{z-index:30;box-sizing:border-box;border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-1);border-radius:7px;width:max(100%,220px);padding:5px;position:absolute;top:calc(100% + 4px);left:0;box-shadow:0 8px 24px #00000038}.PNbOqW_comboboxSearch{box-sizing:border-box;border:1px solid var(--dsw-alias-border-l1);background:var(--dsw-alias-bg-base);width:100%;height:28px;color:var(--dsw-alias-label-primary);font:var(--dsw-font-xs-13);border-radius:4px;padding:0 7px}.PNbOqW_comboboxList{max-height:210px;margin:4px 0 0;padding:0;list-style:none;overflow:auto}.PNbOqW_comboboxOption{width:100%;color:var(--dsw-alias-label-primary);text-align:left;cursor:pointer;background:0 0;border:0;border-radius:4px;align-items:center;gap:5px;padding:6px;font-size:12px;line-height:18px;display:flex}.PNbOqW_comboboxOptionActive,.PNbOqW_comboboxOption:hover{background:var(--dsw-alias-interactive-bg-hover)}.PNbOqW_comboboxCheck{width:13px;color:var(--dsw-alias-state-business-primary);flex:none;font-size:11px}.PNbOqW_comboboxHint{color:var(--dsw-alias-label-tertiary);margin-left:auto;font-size:10px}.PNbOqW_comboboxEmpty{color:var(--dsw-alias-label-tertiary);padding:9px 7px;font-size:11px}.PNbOqW_rowActions{white-space:nowrap;align-items:center;gap:4px;display:flex}.PNbOqW_detailGrid{grid-template-columns:92px minmax(0,1fr);gap:8px 12px;margin:0;font-size:12px;line-height:18px;display:grid}.PNbOqW_detailGrid dt{color:var(--dsw-alias-label-tertiary)}.PNbOqW_detailGrid dd{color:var(--dsw-alias-label-primary);overflow-wrap:anywhere;margin:0}.PNbOqW_roleCell{flex-direction:column;gap:6px;display:flex}.PNbOqW_roleTags{flex-wrap:wrap;gap:4px;display:flex}.PNbOqW_roleTag{background:var(--dsw-alias-bg-layer-2);color:var(--dsw-alias-label-secondary);border-radius:4px;align-items:center;gap:4px;padding:1px 6px;font-size:11px;line-height:18px;display:inline-flex}.PNbOqW_roleRevoke{width:14px;height:14px;color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:0;border-radius:3px;padding:0;font-size:12px;line-height:1}.PNbOqW_roleRevoke:hover{color:var(--dsw-alias-state-danger,#b91c1c);background:#ffffff14}.PNbOqW_roleGrant{align-items:center;gap:6px;display:flex}.PNbOqW_roleGrant select{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-2);height:26px;color:var(--dsw-alias-label-primary);border-radius:5px;padding:0 6px;font-size:11px}";
3181
- const tagId$1 = "@sparkelf/dsh-dataops-managed/PermissionCenterSection.module.css";
3182
- if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$1) + "]") === null) {
2731
+ const css$2 = ".PNbOqW_page{box-sizing:border-box;flex-direction:column;gap:14px;width:100%;max-width:clamp(1000px,60vw,1200px);min-height:0;margin:0 auto;padding:24px;display:flex}.PNbOqW_head{justify-content:space-between;align-items:center;gap:12px;display:flex}.PNbOqW_headText{min-width:0}.PNbOqW_headActions{flex:none;align-items:center;gap:8px;display:flex}.PNbOqW_title{color:var(--dsw-alias-label-primary);margin:0;font-size:20px;font-weight:600;line-height:28px}.PNbOqW_subtitle{color:var(--dsw-alias-label-tertiary);align-items:center;gap:6px;margin:3px 0 0;font-size:12px;display:flex}.PNbOqW_demo{color:#9a5b00;background:#fff3e0;border-radius:4px;padding:1px 6px;font-size:10px;line-height:16px}.PNbOqW_tabs{border-bottom:1px solid var(--dsw-alias-border-l1);scrollbar-width:none;flex-wrap:nowrap;align-items:center;gap:0;display:flex;overflow:auto hidden}.PNbOqW_tabs::-webkit-scrollbar{display:none}.PNbOqW_tabGroup{flex:none;align-items:center;gap:4px;display:flex}.PNbOqW_tabDivider{background:#ffffff1f;flex:none;align-self:center;width:1px;height:14px;margin:0 12px}.PNbOqW_tab{height:34px;color:var(--dsw-alias-label-secondary,#8ea6c6);cursor:pointer;white-space:nowrap;background:0 0;border:0;border-bottom:2px solid #0000;border-radius:4px 4px 0 0;align-items:center;gap:6px;padding:0 10px;font-size:13px;font-weight:400;display:inline-flex}.PNbOqW_tab:hover{background:#ffffff0a}.PNbOqW_tabActive{color:var(--dsw-alias-label-primary,#fff);border-bottom-color:var(--dsw-alias-brand-primary,#2563eb);font-weight:600}.PNbOqW_tabBadge{background:var(--dsw-alias-bg-layer-2);min-width:18px;height:16px;color:var(--dsw-alias-label-caption);font-variant-numeric:tabular-nums;border-radius:999px;justify-content:center;align-items:center;padding:0 5px;font-size:10px;font-weight:500;display:inline-flex}.PNbOqW_notice,.PNbOqW_waiting{background:var(--dsw-alias-bg-layer-1);color:var(--dsw-alias-label-secondary);border-radius:5px;margin:0;padding:8px 10px;font-size:12px}.PNbOqW_waiting{border:1px dashed var(--dsw-alias-border-l2);color:var(--dsw-alias-label-tertiary)}.PNbOqW_panel{border:1px solid var(--dsw-alias-border-l1);background:var(--dsw-alias-bg-layer-1);border-radius:8px;flex-direction:column;gap:10px;min-height:0;padding:14px;display:flex}.PNbOqW_sectionTitle{margin:0;font-size:13px;font-weight:600}.PNbOqW_matrixHead{justify-content:space-between;align-items:center;gap:12px;display:flex}.PNbOqW_matrixHeadLeft{align-items:center;gap:8px;display:flex}.PNbOqW_matrixTool{width:24px;height:24px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:0;border-radius:6px;place-items:center;padding:0;font-size:15px;line-height:1;display:inline-grid}.PNbOqW_matrixTool:hover{color:var(--dsw-alias-label-primary);background:#ffffff0f}.PNbOqW_matrixToolActive{color:#2563eb;background:#2563eb26}.PNbOqW_matrixPermHead{text-align:left;white-space:normal;min-width:116px;max-width:140px;font-weight:500}.PNbOqW_matrixRoleHead,.PNbOqW_matrixRoleCell{white-space:nowrap}.PNbOqW_roleSearchWrap{flex:none;width:240px;max-width:100%;display:inline-flex;position:relative}.PNbOqW_roleSearchIcon{color:#8ea6c6;pointer-events:none;width:16px;height:16px;transition:color .12s;position:absolute;top:50%;left:10px;transform:translateY(-50%)}.PNbOqW_roleSearchWrap:focus-within .PNbOqW_roleSearchIcon{color:#2563eb}.PNbOqW_roleSearch{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-2);width:100%;height:30px;color:var(--dsw-alias-label-primary);font:var(--dsw-font-xxs-12);border-radius:6px;outline:none;padding:0 10px 0 34px}.PNbOqW_roleSearch::placeholder{color:var(--dsw-alias-label-caption)}.PNbOqW_roleSearch:focus{border-color:var(--dsw-alias-brand-primary,#2563eb)}.PNbOqW_empty{text-align:center;color:var(--dsw-alias-label-caption);margin:0;padding:28px 12px;font-size:12px}.PNbOqW_matrixScroll,.PNbOqW_tableScroll{overscroll-behavior:contain;scrollbar-gutter:stable;max-height:clamp(280px,100dvh - 340px,520px);overflow:auto}.PNbOqW_matrix,.PNbOqW_table{border-collapse:collapse;width:100%;font-size:12px}.PNbOqW_matrix th,.PNbOqW_matrix td,.PNbOqW_table th,.PNbOqW_table td{border-bottom:1px solid var(--dsw-alias-border-l1);text-align:left;vertical-align:top;padding:7px 9px}.PNbOqW_matrix th,.PNbOqW_table th{background:var(--dsw-alias-bg-layer-2);color:var(--dsw-alias-label-secondary);white-space:nowrap;font-weight:600}.PNbOqW_permission{white-space:nowrap;color:var(--dsw-alias-label-secondary);align-items:center;gap:5px;font-size:11px;line-height:20px;display:flex}.PNbOqW_panelFoot{flex-wrap:wrap;justify-content:flex-end;align-items:center;gap:6px;display:flex}.PNbOqW_readOnly{color:var(--dsw-alias-label-tertiary);margin-right:auto;font-size:11px}.PNbOqW_muted{color:var(--dsw-alias-label-tertiary);font-size:11px}.PNbOqW_departments{flex-direction:column;gap:4px;margin:0;padding:0;list-style:none;display:flex}.PNbOqW_department{border-bottom:1px solid var(--dsw-alias-border-l1);justify-content:space-between;align-items:center;gap:12px;padding:9px 8px;font-size:12px;display:flex}.PNbOqW_deptAdmins{align-items:center;gap:5px;display:flex}.PNbOqW_adminTag{color:var(--dsw-alias-state-business-primary);background:#ecf1fc;border-radius:4px;padding:1px 6px;font-size:11px}.PNbOqW_empty{text-align:center;color:var(--dsw-alias-label-tertiary);margin:0;padding:40px 0}.PNbOqW_matrixScroll{overscroll-behavior:contain;scrollbar-gutter:stable;max-height:clamp(280px,100dvh - 340px,520px);overflow:auto}.PNbOqW_matrix thead th{z-index:2;position:sticky;top:0}.PNbOqW_matrix thead th:first-child,.PNbOqW_matrix tbody th{background:var(--dsw-alias-bg-layer-2);min-width:132px;position:sticky;left:0}.PNbOqW_matrix thead th:first-child{z-index:3}.PNbOqW_matrix tbody th{z-index:1;background:var(--dsw-alias-bg-layer-1)}.PNbOqW_protected{background:var(--dsw-alias-bg-layer-2);color:var(--dsw-alias-label-tertiary);white-space:nowrap;border-radius:3px;margin-left:5px;padding:0 5px;font-size:10px;font-weight:500;line-height:16px;display:inline-block}tr[data-locked=true] td{opacity:.62}.PNbOqW_pager{justify-content:flex-end;align-items:center;gap:8px;padding-top:8px;display:flex}.PNbOqW_dialog{width:min(560px,100vw - 32px)}.PNbOqW_dialogBody{flex-direction:column;gap:10px;display:flex}.PNbOqW_dialogHint{color:var(--dsw-alias-label-secondary);margin:0;font-size:12px;line-height:18px}.PNbOqW_search{box-sizing:border-box;border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-base);width:100%;height:30px;color:var(--dsw-alias-label-primary);font:var(--dsw-font-xs-13);border-radius:5px;padding:0 9px}.PNbOqW_candidates{flex-direction:column;gap:2px;max-height:260px;margin:0;padding:0;list-style:none;display:flex;overflow:auto}.PNbOqW_candidate{cursor:pointer;border-radius:5px;align-items:center;gap:7px;padding:6px 7px;font-size:12px;display:flex}.PNbOqW_candidate:hover{background:var(--dsw-alias-interactive-bg-hover)}.PNbOqW_error{color:var(--dsw-alias-state-error-primary);margin:0;font-size:11px;line-height:16px}.PNbOqW_dialogFooter{justify-content:flex-end;gap:6px;display:flex}.PNbOqW_matrixNote{color:var(--dsw-alias-label-tertiary);margin:6px 0 0;font-size:11px;line-height:16px}.PNbOqW_panelHead{justify-content:space-between;align-items:center;gap:10px;display:flex}.PNbOqW_treeRoot,.PNbOqW_treeChildren{margin:0;padding:0;list-style:none}.PNbOqW_treeChildren{border-left:1px solid var(--dsw-alias-border-l1);margin-left:18px}.PNbOqW_treeRow{border-bottom:1px solid var(--dsw-alias-border-l1);align-items:center;gap:7px;min-height:34px;font-size:12px;display:flex}.PNbOqW_treeToggle,.PNbOqW_treeSpacer{flex:none;justify-content:center;align-items:center;width:18px;height:18px;display:inline-flex}.PNbOqW_treeToggle{color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:0;border-radius:3px;font-size:11px}.PNbOqW_treeToggle:hover{background:var(--dsw-alias-interactive-bg-hover)}.PNbOqW_treeName{color:var(--dsw-alias-label-primary);white-space:nowrap;font-weight:600}.PNbOqW_treeActions{align-items:center;gap:2px;margin-left:auto;display:flex}.PNbOqW_field{color:var(--dsw-alias-label-secondary);flex-direction:column;gap:5px;font-size:12px;display:flex}.PNbOqW_field input,.PNbOqW_field select{box-sizing:border-box;border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-base);width:100%;height:30px;color:var(--dsw-alias-label-primary);font:var(--dsw-font-xs-13);border-radius:5px;padding:0 9px}.PNbOqW_field input:disabled{opacity:.65}.PNbOqW_matrixModule{vertical-align:top;background:var(--dsw-alias-bg-layer-2);min-width:96px;color:var(--dsw-alias-label-secondary);text-align:left;border-right:1px solid var(--dsw-alias-border-l1);padding:10px 9px;font-size:12px;font-weight:600}.PNbOqW_matrixGroup th{background:var(--dsw-alias-bg-layer-2);color:var(--dsw-alias-label-secondary);text-align:left;padding:7px 9px;font-size:12px;font-weight:600}.PNbOqW_matrixPermission{white-space:nowrap;min-width:230px}.PNbOqW_scopeBadge{border-radius:3px;margin-left:6px;padding:0 5px;font-size:10px;font-weight:500;line-height:16px;display:inline-block}.PNbOqW_scopeBadge[data-scope=department]{background:color-mix(in srgb, var(--dsw-alias-state-business-primary) 14%, var(--dsw-alias-bg-layer-1));color:var(--dsw-alias-state-business-primary)}.PNbOqW_scopeBadge[data-scope=global]{background:color-mix(in srgb, var(--dsw-alias-state-warn-primary) 16%, var(--dsw-alias-bg-layer-1));color:var(--dsw-alias-state-warn-primary)}.PNbOqW_onlyAdmin{color:var(--dsw-alias-label-tertiary);white-space:nowrap;margin-left:4px;font-size:10px}.PNbOqW_permCopy{max-width:100%;color:var(--dsw-alias-label-primary);font:inherit;text-align:left;cursor:pointer;background:0 0;border:0;align-items:center;gap:2px;padding:0;display:inline-flex}.PNbOqW_permCopy:hover span:first-child{color:var(--dsw-alias-state-business-primary);text-decoration:underline dotted}.PNbOqW_permDescription{color:var(--dsw-alias-label-tertiary);white-space:normal;margin-top:2px;font-size:10px;font-weight:400;line-height:15px;display:block}.PNbOqW_copied{color:var(--dsw-alias-state-success-primary);margin-left:4px;font-size:10px}.PNbOqW_combobox{min-width:132px;position:relative}.PNbOqW_comboboxTrigger{box-sizing:border-box;border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-base);width:100%;height:28px;color:var(--dsw-alias-label-primary);font:var(--dsw-font-xs-13);text-align:left;cursor:pointer;border-radius:5px;justify-content:space-between;align-items:center;gap:8px;padding:0 8px;display:flex}.PNbOqW_comboboxTrigger:hover:not(:disabled){border-color:var(--dsw-alias-state-business-primary)}.PNbOqW_comboboxTrigger:focus-visible{outline:2px solid var(--dsw-alias-state-business-primary);outline-offset:1px}.PNbOqW_comboboxTrigger:disabled{opacity:.55;cursor:default}.PNbOqW_comboboxPlaceholder{color:var(--dsw-alias-label-tertiary)}.PNbOqW_comboboxMenu{z-index:30;box-sizing:border-box;border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-1);border-radius:7px;width:max(100%,220px);padding:5px;position:absolute;top:calc(100% + 4px);left:0;box-shadow:0 8px 24px #00000038}.PNbOqW_comboboxSearch{box-sizing:border-box;border:1px solid var(--dsw-alias-border-l1);background:var(--dsw-alias-bg-base);width:100%;height:28px;color:var(--dsw-alias-label-primary);font:var(--dsw-font-xs-13);border-radius:4px;padding:0 7px}.PNbOqW_comboboxList{max-height:210px;margin:4px 0 0;padding:0;list-style:none;overflow:auto}.PNbOqW_comboboxOption{width:100%;color:var(--dsw-alias-label-primary);text-align:left;cursor:pointer;background:0 0;border:0;border-radius:4px;align-items:center;gap:5px;padding:6px;font-size:12px;line-height:18px;display:flex}.PNbOqW_comboboxOptionActive,.PNbOqW_comboboxOption:hover{background:var(--dsw-alias-interactive-bg-hover)}.PNbOqW_comboboxCheck{width:13px;color:var(--dsw-alias-state-business-primary);flex:none;font-size:11px}.PNbOqW_comboboxHint{color:var(--dsw-alias-label-tertiary);margin-left:auto;font-size:10px}.PNbOqW_comboboxEmpty{color:var(--dsw-alias-label-tertiary);padding:9px 7px;font-size:11px}.PNbOqW_rowActions{white-space:nowrap;align-items:center;gap:4px;display:flex}.PNbOqW_detailGrid{grid-template-columns:92px minmax(0,1fr);gap:8px 12px;margin:0;font-size:12px;line-height:18px;display:grid}.PNbOqW_detailGrid dt{color:var(--dsw-alias-label-tertiary)}.PNbOqW_detailGrid dd{color:var(--dsw-alias-label-primary);overflow-wrap:anywhere;margin:0}.PNbOqW_roleCell{flex-direction:column;gap:6px;display:flex}.PNbOqW_roleTags{flex-wrap:wrap;gap:4px;display:flex}.PNbOqW_roleTag{background:var(--dsw-alias-bg-layer-2);color:var(--dsw-alias-label-secondary);border-radius:4px;align-items:center;gap:4px;padding:1px 6px;font-size:11px;line-height:18px;display:inline-flex}.PNbOqW_roleRevoke{width:14px;height:14px;color:var(--dsw-alias-label-tertiary);cursor:pointer;background:0 0;border:0;border-radius:3px;padding:0;font-size:12px;line-height:1}.PNbOqW_roleRevoke:hover{color:var(--dsw-alias-state-danger,#b91c1c);background:#ffffff14}.PNbOqW_roleGrant{align-items:center;gap:6px;display:flex}.PNbOqW_roleGrant select{border:1px solid var(--dsw-alias-border-l2);background:var(--dsw-alias-bg-layer-2);height:26px;color:var(--dsw-alias-label-primary);border-radius:5px;padding:0 6px;font-size:11px}";
2732
+ const tagId$2 = "@sparkelf/dsh-dataops-managed/PermissionCenterSection.module.css";
2733
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$2) + "]") === null) {
3183
2734
  const tag = document.createElement("style");
3184
2735
  tag.dataset.plugin = "@sparkelf/dsh-dataops-managed";
3185
- tag.dataset.pluginCss = tagId$1;
3186
- tag.textContent = css$1;
2736
+ tag.dataset.pluginCss = tagId$2;
2737
+ tag.textContent = css$2;
3187
2738
  document.head.appendChild(tag);
3188
2739
  }
3189
2740
  var PermissionCenterSection_module_css_default = {
3190
- "comboboxPlaceholder": "PNbOqW_comboboxPlaceholder",
3191
- "tab": "PNbOqW_tab",
3192
- "adminTag": "PNbOqW_adminTag",
3193
- "dialogHint": "PNbOqW_dialogHint",
3194
- "permission": "PNbOqW_permission",
3195
- "panelHead": "PNbOqW_panelHead",
3196
- "matrixScroll": "PNbOqW_matrixScroll",
3197
- "candidates": "PNbOqW_candidates",
3198
- "matrixGroup": "PNbOqW_matrixGroup",
3199
- "headActions": "PNbOqW_headActions",
3200
- "rowActions": "PNbOqW_rowActions",
3201
- "error": "PNbOqW_error",
3202
- "tabDivider": "PNbOqW_tabDivider",
3203
- "comboboxEmpty": "PNbOqW_comboboxEmpty",
3204
- "demo": "PNbOqW_demo",
2741
+ "title": "PNbOqW_title",
2742
+ "matrixRoleCell": "PNbOqW_matrixRoleCell",
2743
+ "dialogBody": "PNbOqW_dialogBody",
3205
2744
  "onlyAdmin": "PNbOqW_onlyAdmin",
3206
- "tabBadge": "PNbOqW_tabBadge",
3207
- "pager": "PNbOqW_pager",
3208
- "comboboxSearch": "PNbOqW_comboboxSearch",
2745
+ "tabs": "PNbOqW_tabs",
3209
2746
  "waiting": "PNbOqW_waiting",
3210
- "roleCell": "PNbOqW_roleCell",
3211
- "tabGroup": "PNbOqW_tabGroup",
3212
- "matrixRoleCell": "PNbOqW_matrixRoleCell",
3213
- "treeRoot": "PNbOqW_treeRoot",
3214
- "empty": "PNbOqW_empty",
3215
- "matrixPermission": "PNbOqW_matrixPermission",
3216
- "scopeBadge": "PNbOqW_scopeBadge",
3217
- "subtitle": "PNbOqW_subtitle",
3218
- "roleGrant": "PNbOqW_roleGrant",
3219
- "comboboxHint": "PNbOqW_comboboxHint",
2747
+ "panelFoot": "PNbOqW_panelFoot",
2748
+ "departments": "PNbOqW_departments",
2749
+ "dialog": "PNbOqW_dialog",
3220
2750
  "comboboxMenu": "PNbOqW_comboboxMenu",
3221
- "field": "PNbOqW_field",
3222
- "matrixRoleHead": "PNbOqW_matrixRoleHead",
3223
- "table": "PNbOqW_table",
3224
- "comboboxOption": "PNbOqW_comboboxOption",
3225
- "comboboxOptionActive": "PNbOqW_comboboxOptionActive",
2751
+ "head": "PNbOqW_head",
3226
2752
  "matrixModule": "PNbOqW_matrixModule",
3227
- "roleSearchIcon": "PNbOqW_roleSearchIcon",
3228
- "title": "PNbOqW_title",
3229
- "treeActions": "PNbOqW_treeActions",
3230
- "dialogFooter": "PNbOqW_dialogFooter",
3231
- "treeRow": "PNbOqW_treeRow",
3232
- "permDescription": "PNbOqW_permDescription",
2753
+ "matrixPermHead": "PNbOqW_matrixPermHead",
2754
+ "permCopy": "PNbOqW_permCopy",
2755
+ "tabDivider": "PNbOqW_tabDivider",
3233
2756
  "copied": "PNbOqW_copied",
3234
- "candidate": "PNbOqW_candidate",
3235
- "roleSearch": "PNbOqW_roleSearch",
2757
+ "comboboxList": "PNbOqW_comboboxList",
2758
+ "roleGrant": "PNbOqW_roleGrant",
2759
+ "comboboxTrigger": "PNbOqW_comboboxTrigger",
2760
+ "headActions": "PNbOqW_headActions",
2761
+ "comboboxOption": "PNbOqW_comboboxOption",
2762
+ "comboboxEmpty": "PNbOqW_comboboxEmpty",
2763
+ "matrixGroup": "PNbOqW_matrixGroup",
2764
+ "matrixToolActive": "PNbOqW_matrixToolActive",
2765
+ "empty": "PNbOqW_empty",
3236
2766
  "detailGrid": "PNbOqW_detailGrid",
3237
- "matrix": "PNbOqW_matrix",
3238
- "tabs": "PNbOqW_tabs",
3239
- "permCopy": "PNbOqW_permCopy",
3240
2767
  "muted": "PNbOqW_muted",
3241
- "combobox": "PNbOqW_combobox",
2768
+ "notice": "PNbOqW_notice",
2769
+ "tab": "PNbOqW_tab",
2770
+ "permDescription": "PNbOqW_permDescription",
2771
+ "matrixRoleHead": "PNbOqW_matrixRoleHead",
2772
+ "comboboxOptionActive": "PNbOqW_comboboxOptionActive",
2773
+ "roleTags": "PNbOqW_roleTags",
2774
+ "matrixHead": "PNbOqW_matrixHead",
2775
+ "protected": "PNbOqW_protected",
2776
+ "scopeBadge": "PNbOqW_scopeBadge",
3242
2777
  "treeToggle": "PNbOqW_treeToggle",
3243
- "roleTag": "PNbOqW_roleTag",
3244
- "matrixHeadLeft": "PNbOqW_matrixHeadLeft",
3245
- "tableScroll": "PNbOqW_tableScroll",
3246
- "treeName": "PNbOqW_treeName",
3247
- "head": "PNbOqW_head",
2778
+ "roleSearchIcon": "PNbOqW_roleSearchIcon",
2779
+ "treeRoot": "PNbOqW_treeRoot",
2780
+ "matrixTool": "PNbOqW_matrixTool",
2781
+ "matrix": "PNbOqW_matrix",
2782
+ "candidates": "PNbOqW_candidates",
2783
+ "demo": "PNbOqW_demo",
2784
+ "panel": "PNbOqW_panel",
3248
2785
  "headText": "PNbOqW_headText",
3249
- "tabActive": "PNbOqW_tabActive",
3250
- "readOnly": "PNbOqW_readOnly",
2786
+ "dialogFooter": "PNbOqW_dialogFooter",
2787
+ "tabBadge": "PNbOqW_tabBadge",
3251
2788
  "sectionTitle": "PNbOqW_sectionTitle",
3252
- "department": "PNbOqW_department",
3253
- "protected": "PNbOqW_protected",
3254
- "matrixPermHead": "PNbOqW_matrixPermHead",
3255
- "dialog": "PNbOqW_dialog",
3256
- "dialogBody": "PNbOqW_dialogBody",
3257
- "matrixTool": "PNbOqW_matrixTool",
3258
- "search": "PNbOqW_search",
3259
2789
  "treeChildren": "PNbOqW_treeChildren",
3260
- "departments": "PNbOqW_departments",
3261
- "matrixHead": "PNbOqW_matrixHead",
3262
- "panelFoot": "PNbOqW_panelFoot",
3263
- "comboboxTrigger": "PNbOqW_comboboxTrigger",
3264
- "comboboxList": "PNbOqW_comboboxList",
3265
- "comboboxCheck": "PNbOqW_comboboxCheck",
3266
- "roleRevoke": "PNbOqW_roleRevoke",
3267
- "treeSpacer": "PNbOqW_treeSpacer",
2790
+ "pager": "PNbOqW_pager",
2791
+ "error": "PNbOqW_error",
3268
2792
  "roleSearchWrap": "PNbOqW_roleSearchWrap",
3269
- "notice": "PNbOqW_notice",
2793
+ "table": "PNbOqW_table",
2794
+ "tabGroup": "PNbOqW_tabGroup",
2795
+ "readOnly": "PNbOqW_readOnly",
3270
2796
  "deptAdmins": "PNbOqW_deptAdmins",
3271
- "matrixToolActive": "PNbOqW_matrixToolActive",
3272
- "matrixNote": "PNbOqW_matrixNote",
2797
+ "tabActive": "PNbOqW_tabActive",
2798
+ "search": "PNbOqW_search",
2799
+ "subtitle": "PNbOqW_subtitle",
2800
+ "treeSpacer": "PNbOqW_treeSpacer",
2801
+ "roleTag": "PNbOqW_roleTag",
3273
2802
  "page": "PNbOqW_page",
3274
- "roleTags": "PNbOqW_roleTags",
3275
- "panel": "PNbOqW_panel"
2803
+ "roleSearch": "PNbOqW_roleSearch",
2804
+ "comboboxCheck": "PNbOqW_comboboxCheck",
2805
+ "treeRow": "PNbOqW_treeRow",
2806
+ "matrixPermission": "PNbOqW_matrixPermission",
2807
+ "candidate": "PNbOqW_candidate",
2808
+ "comboboxPlaceholder": "PNbOqW_comboboxPlaceholder",
2809
+ "comboboxSearch": "PNbOqW_comboboxSearch",
2810
+ "roleCell": "PNbOqW_roleCell",
2811
+ "treeActions": "PNbOqW_treeActions",
2812
+ "dialogHint": "PNbOqW_dialogHint",
2813
+ "treeName": "PNbOqW_treeName",
2814
+ "panelHead": "PNbOqW_panelHead",
2815
+ "adminTag": "PNbOqW_adminTag",
2816
+ "matrixHeadLeft": "PNbOqW_matrixHeadLeft",
2817
+ "tableScroll": "PNbOqW_tableScroll",
2818
+ "department": "PNbOqW_department",
2819
+ "rowActions": "PNbOqW_rowActions",
2820
+ "matrixNote": "PNbOqW_matrixNote",
2821
+ "comboboxHint": "PNbOqW_comboboxHint",
2822
+ "combobox": "PNbOqW_combobox",
2823
+ "matrixScroll": "PNbOqW_matrixScroll",
2824
+ "field": "PNbOqW_field",
2825
+ "permission": "PNbOqW_permission",
2826
+ "roleRevoke": "PNbOqW_roleRevoke"
3276
2827
  };
3277
2828
  //#endregion
3278
2829
  //#region src/client/combobox.ts
@@ -4778,143 +4329,467 @@ window.__ModuleLoader__.load({
4778
4329
  /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
4779
4330
  variant: "outline",
4780
4331
  size: "sm",
4781
- disabled: page >= pages - 1,
4332
+ disabled: page >= pages - 1,
4333
+ onClick: () => {
4334
+ onChange(page + 1);
4335
+ },
4336
+ children: "下一页"
4337
+ })
4338
+ ]
4339
+ });
4340
+ }
4341
+ /** The four role labels, so the header does not show a backend code. */
4342
+ function roleLabel(role) {
4343
+ switch (role) {
4344
+ case "SUPER_ADMIN": return "超级管理员";
4345
+ case "ADMIN": return "管理员";
4346
+ case "DEPT_ADMIN": return "部门管理员";
4347
+ default: return "应用人员";
4348
+ }
4349
+ }
4350
+ //#endregion
4351
+ //#region src/client/PermissionCenterIcon.tsx
4352
+ /**
4353
+ * The sidebar glyph for the permission centre.
4354
+ *
4355
+ * The entry is hidden for a caller the Host reports as an ordinary user. This is a navigation
4356
+ * affordance, not the authorization decision: every permission-centre endpoint re-checks the
4357
+ * caller, and the page itself refuses to render without a management role.
4358
+ */
4359
+ function PermissionCenterIcon() {
4360
+ const [allowed, setAllowed] = (0, react.useState)(true);
4361
+ (0, react.useEffect)(() => {
4362
+ let live = true;
4363
+ if (reviewDemoMode() || canSeeManagedSettings()) {
4364
+ setAllowed(true);
4365
+ return () => {
4366
+ live = false;
4367
+ };
4368
+ }
4369
+ fetchReviewContext().then((context) => {
4370
+ if (!live) return;
4371
+ setAllowed(context !== null && context.role !== "APP_USER");
4372
+ }).catch(() => {
4373
+ if (live) setAllowed(false);
4374
+ });
4375
+ return () => {
4376
+ live = false;
4377
+ };
4378
+ }, []);
4379
+ if (!allowed) return null;
4380
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", {
4381
+ width: "18",
4382
+ height: "18",
4383
+ viewBox: "0 0 18 18",
4384
+ fill: "none",
4385
+ "aria-hidden": "true",
4386
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
4387
+ d: "M9 2.2 14.5 4v4.4c0 3.1-2.1 5.6-5.5 7.4-3.4-1.8-5.5-4.3-5.5-7.4V4L9 2.2Z",
4388
+ stroke: "currentColor",
4389
+ strokeWidth: "1.2",
4390
+ strokeLinejoin: "round"
4391
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
4392
+ d: "m6.7 8.8 1.6 1.6 3-3.1",
4393
+ stroke: "currentColor",
4394
+ strokeWidth: "1.2",
4395
+ strokeLinecap: "round",
4396
+ strokeLinejoin: "round"
4397
+ })]
4398
+ });
4399
+ }
4400
+ //#endregion
4401
+ //#region src/client/workspace-upgrade-client.ts
4402
+ /** Same-origin calls for the workspace image upgrade banner. */
4403
+ /** Route the plugin's Host half serves for upgrade detection and start. */
4404
+ const WORKSPACE_UPGRADE_PATH = "integrations/dataops/workspace-upgrade";
4405
+ /** Narrow an unknown response into the status contract. */
4406
+ function asStatus(value) {
4407
+ if (typeof value !== "object" || value === null || Array.isArray(value)) return null;
4408
+ const record = value;
4409
+ const imageStatus = record.imageStatus;
4410
+ if (imageStatus !== "CURRENT" && imageStatus !== "UPDATE_AVAILABLE" && imageStatus !== "NOT_RUNNING" && imageStatus !== "UNKNOWN") return null;
4411
+ const sessions = Array.isArray(record.activeSessions) ? record.activeSessions.flatMap((entry) => {
4412
+ if (typeof entry !== "object" || entry === null || Array.isArray(entry)) return [];
4413
+ const session = entry;
4414
+ if (typeof session.sessionId !== "string" || session.sessionId.trim() === "") return [];
4415
+ return [{
4416
+ sessionId: session.sessionId.trim(),
4417
+ ...typeof session.title === "string" && session.title.trim() !== "" ? { title: session.title.trim() } : {},
4418
+ ...typeof session.cwd === "string" && session.cwd.trim() !== "" ? { cwd: session.cwd.trim() } : {}
4419
+ }];
4420
+ }) : [];
4421
+ return {
4422
+ imageStatus,
4423
+ configuredImage: typeof record.configuredImage === "string" ? record.configuredImage : "",
4424
+ activeSessions: sessions
4425
+ };
4426
+ }
4427
+ /**
4428
+ * Read the workspace upgrade preview.
4429
+ * @returns the status, or null when the Host route is not ready or not connected.
4430
+ */
4431
+ async function fetchWorkspaceUpgrade() {
4432
+ const response = await fetch(WORKSPACE_UPGRADE_PATH, {
4433
+ credentials: "same-origin",
4434
+ headers: { accept: "application/json" }
4435
+ });
4436
+ if (response.status === 503 || response.status === 401) return null;
4437
+ if (!response.ok) throw new Error(`workspace upgrade preview failed with HTTP ${String(response.status)}`);
4438
+ return asStatus(await response.json());
4439
+ }
4440
+ /**
4441
+ * Ask the Host to snapshot sessions and recreate the workspace container.
4442
+ * @returns the accepted hand-off summary.
4443
+ */
4444
+ async function requestWorkspaceUpgrade() {
4445
+ const response = await fetch(WORKSPACE_UPGRADE_PATH, {
4446
+ method: "POST",
4447
+ credentials: "same-origin",
4448
+ headers: {
4449
+ "content-type": "application/json",
4450
+ accept: "application/json"
4451
+ },
4452
+ body: JSON.stringify({ force: true })
4453
+ });
4454
+ const body = await response.json().catch(() => null);
4455
+ if (!response.ok) {
4456
+ const message = typeof body?.error === "string" ? body.error : `workspace upgrade failed with HTTP ${String(response.status)}`;
4457
+ throw new Error(message);
4458
+ }
4459
+ return {
4460
+ accepted: body?.accepted === true,
4461
+ upgradeId: typeof body?.upgradeId === "string" ? body.upgradeId : "",
4462
+ sessions: typeof body?.sessions === "number" ? body.sessions : 0
4463
+ };
4464
+ }
4465
+ //#endregion
4466
+ //#region \0dsh-css:/root/projects/dsh-plugins-plus/packages/dataops-managed/src/client/WorkspaceUpgradePrompt.module.css.mjs
4467
+ const css$1 = ".razUfG_banner{z-index:40;border:.5px solid var(--dsw-alias-settings-card-stroke);border-radius:var(--dsw-radius-xl);background:var(--dsw-alias-settings-card-fill);width:min(680px,100vw - 32px);color:var(--dsw-alias-label-primary);justify-content:space-between;align-items:center;gap:20px;padding:10px 12px 10px 16px;display:flex;position:fixed;top:16px;left:50%;transform:translate(-50%);box-shadow:0 8px 28px #0000001f}.razUfG_copy{flex-direction:column;gap:2px;min-width:0;display:flex}.razUfG_title{font-size:13px;font-weight:600;line-height:22px}.razUfG_body{color:var(--dsw-alias-label-secondary);font-size:12px;line-height:18px}.razUfG_actions{flex:none;align-items:center;gap:4px;display:flex}.razUfG_dialogBody{flex-direction:column;gap:12px;min-width:min(420px,70vw);display:flex}.razUfG_dialogText{color:var(--dsw-alias-label-secondary);margin:0;font-size:13px;line-height:22px}.razUfG_sessionList{border-radius:var(--dsw-radius-lg);background:var(--dsw-alias-bg-layer-1);flex-direction:column;gap:4px;max-height:220px;margin:0;padding:8px 10px;list-style:none;display:flex;overflow:auto}.razUfG_sessionRow{flex-direction:column;gap:1px;min-width:0;display:flex}.razUfG_sessionTitle{color:var(--dsw-alias-label-primary);text-overflow:ellipsis;white-space:nowrap;font-size:12px;line-height:18px;overflow:hidden}.razUfG_sessionPath{color:var(--dsw-alias-label-tertiary);text-overflow:ellipsis;white-space:nowrap;font-size:11px;line-height:16px;overflow:hidden}.razUfG_error{color:var(--dsw-alias-state-error-primary);margin:0;font-size:12px;line-height:18px}";
4468
+ const tagId$1 = "@sparkelf/dsh-dataops-managed/WorkspaceUpgradePrompt.module.css";
4469
+ if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId$1) + "]") === null) {
4470
+ const tag = document.createElement("style");
4471
+ tag.dataset.plugin = "@sparkelf/dsh-dataops-managed";
4472
+ tag.dataset.pluginCss = tagId$1;
4473
+ tag.textContent = css$1;
4474
+ document.head.appendChild(tag);
4475
+ }
4476
+ var WorkspaceUpgradePrompt_module_css_default = {
4477
+ "sessionPath": "razUfG_sessionPath",
4478
+ "actions": "razUfG_actions",
4479
+ "sessionList": "razUfG_sessionList",
4480
+ "sessionTitle": "razUfG_sessionTitle",
4481
+ "body": "razUfG_body",
4482
+ "dialogBody": "razUfG_dialogBody",
4483
+ "title": "razUfG_title",
4484
+ "dialogText": "razUfG_dialogText",
4485
+ "banner": "razUfG_banner",
4486
+ "copy": "razUfG_copy",
4487
+ "sessionRow": "razUfG_sessionRow",
4488
+ "error": "razUfG_error"
4489
+ };
4490
+ //#endregion
4491
+ //#region src/client/WorkspaceUpgradePrompt.tsx
4492
+ /**
4493
+ * Workspace image upgrade banner and confirmation dialog.
4494
+ *
4495
+ * The banner is deliberately quiet: it tells the user a newer workspace image exists and
4496
+ * leaves the current session usable. Only the explicit upgrade action opens the dialog
4497
+ * that can interrupt running sessions.
4498
+ *
4499
+ * @module WorkspaceUpgradePrompt
4500
+ */
4501
+ /** How often to re-read the image status while the page is open. */
4502
+ const POLL_MS = 3e4;
4503
+ /** Wait before a reload so the restarted workspace has a chance to come back. */
4504
+ const RELOAD_DELAY_MS = 12e3;
4505
+ /**
4506
+ * Render the banner and its upgrade dialog.
4507
+ * @param props.t - localized copy resolver.
4508
+ * @returns the banner while an image update is available, otherwise null.
4509
+ */
4510
+ function WorkspaceUpgradePrompt(props) {
4511
+ const { t } = props;
4512
+ const [status, setStatus] = (0, react.useState)(null);
4513
+ const [dismissed, setDismissed] = (0, react.useState)(false);
4514
+ const [dialogOpen, setDialogOpen] = (0, react.useState)(false);
4515
+ const [busy, setBusy] = (0, react.useState)(false);
4516
+ const [notice, setNotice] = (0, react.useState)("");
4517
+ const [error, setError] = (0, react.useState)("");
4518
+ const refresh = (0, react.useCallback)(async () => {
4519
+ try {
4520
+ const next = await fetchWorkspaceUpgrade();
4521
+ if (next !== null) setStatus(next);
4522
+ } catch {}
4523
+ }, []);
4524
+ (0, react.useEffect)(() => {
4525
+ let cancelled = false;
4526
+ const tick = async () => {
4527
+ if (cancelled) return;
4528
+ await refresh();
4529
+ };
4530
+ tick();
4531
+ const timer = setInterval(() => {
4532
+ tick();
4533
+ }, POLL_MS);
4534
+ return () => {
4535
+ cancelled = true;
4536
+ clearInterval(timer);
4537
+ };
4538
+ }, [refresh]);
4539
+ const available = status?.imageStatus === "UPDATE_AVAILABLE";
4540
+ const sessionCount = status?.activeSessions.length ?? 0;
4541
+ const warning = (0, react.useMemo)(() => t("upgradeSessionsWarning").replace("{count}", String(sessionCount)), [sessionCount, t]);
4542
+ const openDialog = (0, react.useCallback)(() => {
4543
+ setError("");
4544
+ setDialogOpen(true);
4545
+ }, []);
4546
+ const closeDialog = (0, react.useCallback)(() => {
4547
+ if (busy) return;
4548
+ setDialogOpen(false);
4549
+ }, [busy]);
4550
+ const upgrade = (0, react.useCallback)(async () => {
4551
+ setBusy(true);
4552
+ setError("");
4553
+ try {
4554
+ await requestWorkspaceUpgrade();
4555
+ setDialogOpen(false);
4556
+ setNotice(t("upgradeStarted"));
4557
+ setDismissed(true);
4558
+ window.setTimeout(() => {
4559
+ window.location.reload();
4560
+ }, RELOAD_DELAY_MS);
4561
+ } catch (cause) {
4562
+ if (cause instanceof TypeError) {
4563
+ setDialogOpen(false);
4564
+ setNotice(t("upgradeStarted"));
4565
+ setDismissed(true);
4566
+ window.setTimeout(() => {
4567
+ window.location.reload();
4568
+ }, RELOAD_DELAY_MS);
4569
+ return;
4570
+ }
4571
+ setError(cause instanceof Error ? cause.message : t("upgradeFailed"));
4572
+ } finally {
4573
+ setBusy(false);
4574
+ }
4575
+ }, [t]);
4576
+ if (notice !== "") return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
4577
+ className: WorkspaceUpgradePrompt_module_css_default.banner,
4578
+ role: "status",
4579
+ "aria-live": "polite",
4580
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
4581
+ className: WorkspaceUpgradePrompt_module_css_default.title,
4582
+ children: notice
4583
+ })
4584
+ });
4585
+ if (!available || dismissed) return null;
4586
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
4587
+ className: WorkspaceUpgradePrompt_module_css_default.banner,
4588
+ role: "status",
4589
+ "aria-live": "polite",
4590
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
4591
+ className: WorkspaceUpgradePrompt_module_css_default.copy,
4592
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("strong", {
4593
+ className: WorkspaceUpgradePrompt_module_css_default.title,
4594
+ children: t("upgradeAvailableTitle")
4595
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
4596
+ className: WorkspaceUpgradePrompt_module_css_default.body,
4597
+ children: t("upgradeAvailableBody")
4598
+ })]
4599
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
4600
+ className: WorkspaceUpgradePrompt_module_css_default.actions,
4601
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
4602
+ variant: "primary",
4603
+ size: "sm",
4604
+ onClick: openDialog,
4605
+ children: t("upgradeAction")
4606
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
4607
+ variant: "ghost",
4608
+ size: "sm",
4782
4609
  onClick: () => {
4783
- onChange(page + 1);
4610
+ setDismissed(true);
4784
4611
  },
4785
- children: "下一页"
4786
- })
4787
- ]
4788
- });
4789
- }
4790
- /** The four role labels, so the header does not show a backend code. */
4791
- function roleLabel(role) {
4792
- switch (role) {
4793
- case "SUPER_ADMIN": return "超级管理员";
4794
- case "ADMIN": return "管理员";
4795
- case "DEPT_ADMIN": return "部门管理员";
4796
- default: return "应用人员";
4797
- }
4612
+ children: t("upgradeLater")
4613
+ })]
4614
+ })]
4615
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Modal, {
4616
+ open: dialogOpen,
4617
+ onClose: closeDialog,
4618
+ title: t("upgradeDialogTitle"),
4619
+ description: t("upgradeDialogBody"),
4620
+ closeLabel: t("upgradeCancel"),
4621
+ footer: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
4622
+ variant: "ghost",
4623
+ onClick: closeDialog,
4624
+ disabled: busy,
4625
+ children: t("upgradeCancel")
4626
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
4627
+ variant: "primary",
4628
+ onClick: () => {
4629
+ upgrade();
4630
+ },
4631
+ disabled: busy,
4632
+ children: busy ? t("upgradeBusy") : sessionCount === 0 ? t("upgradeAction") : t("upgradeConfirm")
4633
+ })] }),
4634
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
4635
+ className: WorkspaceUpgradePrompt_module_css_default.dialogBody,
4636
+ children: [
4637
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
4638
+ className: WorkspaceUpgradePrompt_module_css_default.dialogText,
4639
+ children: sessionCount === 0 ? t("upgradeNoSessions") : warning
4640
+ }),
4641
+ sessionCount > 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("ul", {
4642
+ className: WorkspaceUpgradePrompt_module_css_default.sessionList,
4643
+ children: status?.activeSessions.map((session) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("li", {
4644
+ className: WorkspaceUpgradePrompt_module_css_default.sessionRow,
4645
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
4646
+ className: WorkspaceUpgradePrompt_module_css_default.sessionTitle,
4647
+ children: session.title ?? session.sessionId
4648
+ }), session.cwd ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
4649
+ className: WorkspaceUpgradePrompt_module_css_default.sessionPath,
4650
+ children: session.cwd
4651
+ }) : null]
4652
+ }, session.sessionId))
4653
+ }) : null,
4654
+ error !== "" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
4655
+ className: WorkspaceUpgradePrompt_module_css_default.error,
4656
+ role: "alert",
4657
+ children: error
4658
+ }) : null
4659
+ ]
4660
+ })
4661
+ })] });
4798
4662
  }
4799
4663
  //#endregion
4800
- //#region src/client/PermissionCenterIcon.tsx
4664
+ //#region src/client/review-notification-store.ts
4801
4665
  /**
4802
- * The sidebar glyph for the permission centre.
4666
+ * One process-wide notification store shared by every bell.
4803
4667
  *
4804
- * The entry is hidden for a caller the Host reports as an ordinary user. This is a navigation
4805
- * affordance, not the authorization decision: every permission-centre endpoint re-checks the
4806
- * caller, and the page itself refuses to render without a management role.
4668
+ * The skill plaza and the workflow plaza are separate React trees, but they show the same
4669
+ * inbox; keeping the read state in one store is what stops a badge in one place from staying
4670
+ * unread after the other opened the row.
4807
4671
  */
4808
- function PermissionCenterIcon() {
4809
- const [allowed, setAllowed] = (0, react.useState)(() => canSeeManagedSettings() ? true : void 0);
4810
- (0, react.useEffect)(() => {
4811
- let live = true;
4812
- if (reviewDemoMode() || canSeeManagedSettings()) {
4813
- setAllowed(true);
4814
- return () => {
4815
- live = false;
4816
- };
4817
- }
4818
- fetchReviewContext().then((context) => {
4819
- if (!live) return;
4820
- setAllowed(context !== null && context.role !== "APP_USER");
4821
- }).catch(() => {
4822
- if (live) setAllowed(false);
4823
- });
4824
- return () => {
4825
- live = false;
4826
- };
4827
- }, []);
4828
- if (allowed !== true) return null;
4829
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", {
4830
- width: "18",
4831
- height: "18",
4832
- viewBox: "0 0 18 18",
4833
- fill: "none",
4834
- "aria-hidden": "true",
4835
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
4836
- d: "M9 2.2 14.5 4v4.4c0 3.1-2.1 5.6-5.5 7.4-3.4-1.8-5.5-4.3-5.5-7.4V4L9 2.2Z",
4837
- stroke: "currentColor",
4838
- strokeWidth: "1.2",
4839
- strokeLinejoin: "round"
4840
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
4841
- d: "m6.7 8.8 1.6 1.6 3-3.1",
4842
- stroke: "currentColor",
4843
- strokeWidth: "1.2",
4844
- strokeLinecap: "round",
4845
- strokeLinejoin: "round"
4846
- })]
4847
- });
4672
+ const DEMO_ITEMS = [
4673
+ {
4674
+ id: "demo-1",
4675
+ type: "review_pending",
4676
+ title: "技能「SQL 取数助手」等待审核",
4677
+ body: "来自研发部 · 提交于 10 分钟前",
4678
+ resourceKind: "skill",
4679
+ resourceId: 101,
4680
+ read: false,
4681
+ createdAt: "2026-10-23T04:50:00.000Z"
4682
+ },
4683
+ {
4684
+ id: "demo-2",
4685
+ type: "ai_report",
4686
+ title: "AI 风险报告已生成",
4687
+ body: "风险等级:中 · 2 条建议",
4688
+ resourceKind: "skill",
4689
+ resourceId: 101,
4690
+ read: false,
4691
+ createdAt: "2026-10-23T04:49:00.000Z"
4692
+ },
4693
+ {
4694
+ id: "demo-3",
4695
+ type: "approved",
4696
+ title: "工作流「每日经营日报」已通过",
4697
+ body: "审核人:admin",
4698
+ resourceKind: "workflow",
4699
+ resourceId: "wf-1",
4700
+ read: true,
4701
+ createdAt: "2026-10-22T09:10:00.000Z"
4702
+ }
4703
+ ];
4704
+ let state = {
4705
+ status: "idle",
4706
+ items: [],
4707
+ unread: 0
4708
+ };
4709
+ const listeners = /* @__PURE__ */ new Set();
4710
+ function publish(next) {
4711
+ state = next;
4712
+ for (const listener of listeners) listener();
4848
4713
  }
4849
- //#endregion
4850
- //#region src/client/workspace-upgrade-client.ts
4851
- /** Same-origin calls for the workspace image upgrade banner. */
4852
- /** Route the plugin's Host half serves for upgrade detection and start. */
4853
- const WORKSPACE_UPGRADE_PATH = "/integrations/dataops/workspace-upgrade";
4854
- /** Narrow an unknown response into the status contract. */
4855
- function asStatus(value) {
4856
- if (typeof value !== "object" || value === null || Array.isArray(value)) return null;
4857
- const record = value;
4858
- const imageStatus = record.imageStatus;
4859
- if (imageStatus !== "CURRENT" && imageStatus !== "UPDATE_AVAILABLE" && imageStatus !== "NOT_RUNNING" && imageStatus !== "UNKNOWN") return null;
4860
- const sessions = Array.isArray(record.activeSessions) ? record.activeSessions.flatMap((entry) => {
4861
- if (typeof entry !== "object" || entry === null || Array.isArray(entry)) return [];
4862
- const session = entry;
4863
- if (typeof session.sessionId !== "string" || session.sessionId.trim() === "") return [];
4864
- return [{
4865
- sessionId: session.sessionId.trim(),
4866
- ...typeof session.title === "string" && session.title.trim() !== "" ? { title: session.title.trim() } : {},
4867
- ...typeof session.cwd === "string" && session.cwd.trim() !== "" ? { cwd: session.cwd.trim() } : {}
4868
- }];
4869
- }) : [];
4870
- return {
4871
- imageStatus,
4872
- configuredImage: typeof record.configuredImage === "string" ? record.configuredImage : "",
4873
- activeSessions: sessions
4714
+ /** Current snapshot for `useSyncExternalStore`. */
4715
+ function notificationSnapshot() {
4716
+ return state;
4717
+ }
4718
+ /** Subscribe to store changes. */
4719
+ function subscribeNotifications(listener) {
4720
+ listeners.add(listener);
4721
+ return () => {
4722
+ listeners.delete(listener);
4874
4723
  };
4875
4724
  }
4876
- /**
4877
- * Read the workspace upgrade preview.
4878
- * @returns the status, or null when the Host route is not ready or not connected.
4879
- */
4880
- async function fetchWorkspaceUpgrade() {
4881
- const response = await fetch(WORKSPACE_UPGRADE_PATH, {
4882
- credentials: "same-origin",
4883
- headers: { accept: "application/json" }
4725
+ /** Load the inbox once; a second caller joins the first request. */
4726
+ let inflight;
4727
+ function loadNotifications() {
4728
+ if (inflight !== void 0) return inflight;
4729
+ publish({
4730
+ ...state,
4731
+ status: "loading"
4884
4732
  });
4885
- if (response.status === 503 || response.status === 401) return null;
4886
- if (!response.ok) throw new Error(`workspace upgrade preview failed with HTTP ${String(response.status)}`);
4887
- return asStatus(await response.json());
4733
+ inflight = (async () => {
4734
+ try {
4735
+ if (reviewDemoMode()) {
4736
+ publish({
4737
+ status: "ready",
4738
+ items: sortNotifications(DEMO_ITEMS),
4739
+ unread: unreadCount(DEMO_ITEMS)
4740
+ });
4741
+ return;
4742
+ }
4743
+ const result = await fetchNotifications();
4744
+ if (result === null) {
4745
+ publish({
4746
+ status: "unavailable",
4747
+ items: [],
4748
+ unread: 0
4749
+ });
4750
+ return;
4751
+ }
4752
+ publish({
4753
+ status: "ready",
4754
+ items: sortNotifications(result.items),
4755
+ unread: unreadCount(result.items)
4756
+ });
4757
+ } catch {
4758
+ publish({
4759
+ status: "unavailable",
4760
+ items: [],
4761
+ unread: 0
4762
+ });
4763
+ } finally {
4764
+ inflight = void 0;
4765
+ }
4766
+ })();
4767
+ return inflight;
4888
4768
  }
4889
- /**
4890
- * Ask the Host to snapshot sessions and recreate the workspace container.
4891
- * @returns the accepted hand-off summary.
4892
- */
4893
- async function requestWorkspaceUpgrade() {
4894
- const response = await fetch(WORKSPACE_UPGRADE_PATH, {
4895
- method: "POST",
4896
- credentials: "same-origin",
4897
- headers: {
4898
- "content-type": "application/json",
4899
- accept: "application/json"
4900
- },
4901
- body: JSON.stringify({ force: true })
4769
+ /** Mark one row or the whole inbox read, optimistically. */
4770
+ async function markRead(ids) {
4771
+ const items = ids === "all" ? state.items.map((item) => ({
4772
+ ...item,
4773
+ read: true
4774
+ })) : state.items.map((item) => ids.includes(item.id) ? {
4775
+ ...item,
4776
+ read: true
4777
+ } : item);
4778
+ publish({
4779
+ ...state,
4780
+ items,
4781
+ unread: unreadCount(items)
4902
4782
  });
4903
- const body = await response.json().catch(() => null);
4904
- if (!response.ok) {
4905
- const message = typeof body?.error === "string" ? body.error : `workspace upgrade failed with HTTP ${String(response.status)}`;
4906
- throw new Error(message);
4783
+ try {
4784
+ if (!await markNotificationsRead(ids)) await loadNotifications();
4785
+ } catch {
4786
+ await loadNotifications();
4907
4787
  }
4908
- return {
4909
- accepted: body?.accepted === true,
4910
- upgradeId: typeof body?.upgradeId === "string" ? body.upgradeId : "",
4911
- sessions: typeof body?.sessions === "number" ? body.sessions : 0
4912
- };
4913
4788
  }
4914
4789
  //#endregion
4915
- //#region \0dsh-css:/root/projects/dsh-plugins-plus/packages/dataops-managed/src/client/WorkspaceUpgradePrompt.module.css.mjs
4916
- const css = ".razUfG_banner{z-index:40;border:.5px solid var(--dsw-alias-settings-card-stroke);border-radius:var(--dsw-radius-xl);background:var(--dsw-alias-settings-card-fill);width:min(680px,100vw - 32px);color:var(--dsw-alias-label-primary);justify-content:space-between;align-items:center;gap:20px;padding:10px 12px 10px 16px;display:flex;position:fixed;top:16px;left:50%;transform:translate(-50%);box-shadow:0 8px 28px #0000001f}.razUfG_copy{flex-direction:column;gap:2px;min-width:0;display:flex}.razUfG_title{font-size:13px;font-weight:600;line-height:22px}.razUfG_body{color:var(--dsw-alias-label-secondary);font-size:12px;line-height:18px}.razUfG_actions{flex:none;align-items:center;gap:4px;display:flex}.razUfG_dialogBody{flex-direction:column;gap:12px;min-width:min(420px,70vw);display:flex}.razUfG_dialogText{color:var(--dsw-alias-label-secondary);margin:0;font-size:13px;line-height:22px}.razUfG_sessionList{border-radius:var(--dsw-radius-lg);background:var(--dsw-alias-bg-layer-1);flex-direction:column;gap:4px;max-height:220px;margin:0;padding:8px 10px;list-style:none;display:flex;overflow:auto}.razUfG_sessionRow{flex-direction:column;gap:1px;min-width:0;display:flex}.razUfG_sessionTitle{color:var(--dsw-alias-label-primary);text-overflow:ellipsis;white-space:nowrap;font-size:12px;line-height:18px;overflow:hidden}.razUfG_sessionPath{color:var(--dsw-alias-label-tertiary);text-overflow:ellipsis;white-space:nowrap;font-size:11px;line-height:16px;overflow:hidden}.razUfG_error{color:var(--dsw-alias-state-error-primary);margin:0;font-size:12px;line-height:18px}";
4917
- const tagId = "@sparkelf/dsh-dataops-managed/WorkspaceUpgradePrompt.module.css";
4790
+ //#region \0dsh-css:/root/projects/dsh-plugins-plus/packages/dataops-managed/src/client/NotificationBell.module.css.mjs
4791
+ const css = ".tE0trG_bell{width:26px;height:26px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border:0;border-radius:6px;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex;position:relative}.tE0trG_bell:hover{background:var(--dsw-alias-interactive-bg-hover);color:var(--dsw-alias-label-primary)}.tE0trG_bell:focus-visible{outline:2px solid var(--dsw-alias-brand-primary);outline-offset:1px}.tE0trG_badge{background:var(--dsw-alias-state-error-primary);color:#fff;text-align:center;border-radius:7px;min-width:14px;height:14px;padding:0 3px;font-size:9px;font-weight:600;line-height:14px;position:absolute;top:0;right:-2px}.tE0trG_dialog{flex-direction:column;width:min(520px,100vw - 32px);height:70vh;max-height:70vh;display:flex;overflow:hidden}.tE0trG_demo{background:var(--dsw-alias-state-warn-secondary);color:var(--dsw-alias-state-warn-primary);border-radius:4px;margin:0 0 8px;padding:5px 8px;font-size:11px}.tE0trG_empty{color:var(--dsw-alias-label-tertiary);text-align:center;margin:0;padding:18px 0;font-size:12px;line-height:18px}.tE0trG_list{flex-direction:column;flex:none;gap:6px;max-height:calc(70vh - 210px);margin:0;padding:0;list-style:none;display:flex;overflow-y:auto}.tE0trG_row{width:100%;color:var(--dsw-alias-label-secondary);text-align:left;cursor:pointer;background:0 0;border:0;border-radius:0;align-items:flex-start;gap:9px;padding:4px 2px;display:flex}.tE0trG_row:hover .tE0trG_rowTitle{color:var(--dsw-alias-state-business-primary)}.tE0trG_rowIcon{width:18px;height:18px;color:var(--dsw-alias-label-secondary);flex:none;justify-content:center;align-items:center;margin-top:1px;display:inline-flex}.tE0trG_rowIcon[data-tone=success]{color:var(--dsw-alias-state-success-primary)}.tE0trG_rowIcon[data-tone=danger]{color:var(--dsw-alias-state-error-primary)}.tE0trG_rowIcon[data-tone=warn]{color:var(--dsw-alias-state-warn-primary)}.tE0trG_rowIcon[data-tone=info]{color:var(--dsw-alias-state-business-primary)}.tE0trG_dot{background:var(--dsw-alias-state-business-primary);border-radius:50%;flex:none;width:6px;height:6px}.tE0trG_rowBody{flex-direction:column;flex:1;gap:2px;min-width:0;display:flex}.tE0trG_rowTitle{color:var(--dsw-alias-label-primary);font-size:12px;font-weight:500;line-height:18px}.tE0trG_rowText{color:var(--dsw-alias-label-secondary);font-size:11px;line-height:16px}.tE0trG_rowMeta{flex:none;align-items:center;gap:6px;margin-top:2px;display:flex}.tE0trG_rowTime{color:var(--dsw-alias-label-tertiary);flex:none;font-size:10px;line-height:16px}.tE0trG_actions{justify-content:flex-end;gap:6px;display:flex}.tE0trG_button,.tE0trG_linkButton{cursor:pointer;border-radius:5px;height:28px;padding:0 10px;font-size:12px}.tE0trG_button{border:1px solid var(--dsw-alias-border-l2);color:var(--dsw-alias-label-primary);background:0 0}.tE0trG_linkButton{color:var(--dsw-alias-state-business-primary);background:0 0;border:0}.tE0trG_pager{color:var(--dsw-alias-label-secondary);justify-content:flex-end;align-items:center;gap:8px;padding-top:8px;font-size:11px;display:flex}.tE0trG_pager button{border:1px solid var(--dsw-alias-border-l2);height:24px;color:var(--dsw-alias-label-secondary);cursor:pointer;background:0 0;border-radius:4px;padding:0 8px;font-size:11px}.tE0trG_pager button:disabled{opacity:.4;cursor:default}";
4792
+ const tagId = "@sparkelf/dsh-dataops-managed/NotificationBell.module.css";
4918
4793
  if (typeof document !== "undefined" && document.querySelector("style[data-plugin-css=" + JSON.stringify(tagId) + "]") === null) {
4919
4794
  const tag = document.createElement("style");
4920
4795
  tag.dataset.plugin = "@sparkelf/dsh-dataops-managed";
@@ -4922,193 +4797,303 @@ window.__ModuleLoader__.load({
4922
4797
  tag.textContent = css;
4923
4798
  document.head.appendChild(tag);
4924
4799
  }
4925
- var WorkspaceUpgradePrompt_module_css_default = {
4926
- "dialogBody": "razUfG_dialogBody",
4927
- "banner": "razUfG_banner",
4928
- "sessionList": "razUfG_sessionList",
4929
- "sessionPath": "razUfG_sessionPath",
4930
- "sessionRow": "razUfG_sessionRow",
4931
- "sessionTitle": "razUfG_sessionTitle",
4932
- "error": "razUfG_error",
4933
- "copy": "razUfG_copy",
4934
- "title": "razUfG_title",
4935
- "dialogText": "razUfG_dialogText",
4936
- "actions": "razUfG_actions",
4937
- "body": "razUfG_body"
4800
+ var NotificationBell_module_css_default = {
4801
+ "demo": "tE0trG_demo",
4802
+ "row": "tE0trG_row",
4803
+ "badge": "tE0trG_badge",
4804
+ "rowIcon": "tE0trG_rowIcon",
4805
+ "dialog": "tE0trG_dialog",
4806
+ "rowTitle": "tE0trG_rowTitle",
4807
+ "pager": "tE0trG_pager",
4808
+ "empty": "tE0trG_empty",
4809
+ "rowBody": "tE0trG_rowBody",
4810
+ "dot": "tE0trG_dot",
4811
+ "bell": "tE0trG_bell",
4812
+ "rowMeta": "tE0trG_rowMeta",
4813
+ "rowTime": "tE0trG_rowTime",
4814
+ "rowText": "tE0trG_rowText",
4815
+ "actions": "tE0trG_actions",
4816
+ "button": "tE0trG_button",
4817
+ "linkButton": "tE0trG_linkButton",
4818
+ "list": "tE0trG_list"
4938
4819
  };
4939
4820
  //#endregion
4940
- //#region src/client/WorkspaceUpgradePrompt.tsx
4941
- /**
4942
- * Workspace image upgrade banner and confirmation dialog.
4943
- *
4944
- * The banner is deliberately quiet: it tells the user a newer workspace image exists and
4945
- * leaves the current session usable. Only the explicit upgrade action opens the dialog
4946
- * that can interrupt running sessions.
4947
- *
4948
- * @module WorkspaceUpgradePrompt
4949
- */
4950
- /** How often to re-read the image status while the page is open. */
4951
- const POLL_MS = 3e4;
4952
- /** Wait before a reload so the restarted workspace has a chance to come back. */
4953
- const RELOAD_DELAY_MS = 12e3;
4954
- /**
4955
- * Render the banner and its upgrade dialog.
4956
- * @param props.t - localized copy resolver.
4957
- * @returns the banner while an image update is available, otherwise null.
4958
- */
4959
- function WorkspaceUpgradePrompt(props) {
4960
- const { t } = props;
4961
- const [status, setStatus] = (0, react.useState)(null);
4962
- const [dismissed, setDismissed] = (0, react.useState)(false);
4963
- const [dialogOpen, setDialogOpen] = (0, react.useState)(false);
4964
- const [busy, setBusy] = (0, react.useState)(false);
4965
- const [notice, setNotice] = (0, react.useState)("");
4966
- const [error, setError] = (0, react.useState)("");
4967
- const refresh = (0, react.useCallback)(async () => {
4968
- try {
4969
- const next = await fetchWorkspaceUpgrade();
4970
- if (next !== null) setStatus(next);
4971
- } catch {}
4972
- }, []);
4973
- (0, react.useEffect)(() => {
4974
- let cancelled = false;
4975
- const tick = async () => {
4976
- if (cancelled) return;
4977
- await refresh();
4978
- };
4979
- tick();
4980
- const timer = setInterval(() => {
4981
- tick();
4982
- }, POLL_MS);
4983
- return () => {
4984
- cancelled = true;
4985
- clearInterval(timer);
4986
- };
4987
- }, [refresh]);
4988
- const available = status?.imageStatus === "UPDATE_AVAILABLE";
4989
- const sessionCount = status?.activeSessions.length ?? 0;
4990
- const warning = (0, react.useMemo)(() => t("upgradeSessionsWarning").replace("{count}", String(sessionCount)), [sessionCount, t]);
4991
- const openDialog = (0, react.useCallback)(() => {
4992
- setError("");
4993
- setDialogOpen(true);
4994
- }, []);
4995
- const closeDialog = (0, react.useCallback)(() => {
4996
- if (busy) return;
4997
- setDialogOpen(false);
4998
- }, [busy]);
4999
- const upgrade = (0, react.useCallback)(async () => {
5000
- setBusy(true);
5001
- setError("");
5002
- try {
5003
- await requestWorkspaceUpgrade();
5004
- setDialogOpen(false);
5005
- setNotice(t("upgradeStarted"));
5006
- setDismissed(true);
5007
- window.setTimeout(() => {
5008
- window.location.reload();
5009
- }, RELOAD_DELAY_MS);
5010
- } catch (cause) {
5011
- if (cause instanceof TypeError) {
5012
- setDialogOpen(false);
5013
- setNotice(t("upgradeStarted"));
5014
- setDismissed(true);
5015
- window.setTimeout(() => {
5016
- window.location.reload();
5017
- }, RELOAD_DELAY_MS);
5018
- return;
5019
- }
5020
- setError(cause instanceof Error ? cause.message : t("upgradeFailed"));
5021
- } finally {
5022
- setBusy(false);
5023
- }
5024
- }, [t]);
5025
- if (notice !== "") return /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
5026
- className: WorkspaceUpgradePrompt_module_css_default.banner,
5027
- role: "status",
5028
- "aria-live": "polite",
5029
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
5030
- className: WorkspaceUpgradePrompt_module_css_default.title,
5031
- children: notice
5032
- })
4821
+ //#region src/client/NotificationBell.tsx
4822
+ /** Colour tone and glyph for one notification type, matching the automation-task rows. */
4823
+ function notificationTone(type) {
4824
+ if (type === "approved" || type === "published" || type === "success") return "success";
4825
+ if (type === "rejected") return "danger";
4826
+ if (type === "unpublished") return "warn";
4827
+ return "info";
4828
+ }
4829
+ function NotificationIcon({ tone }) {
4830
+ if (tone === "success") return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", {
4831
+ width: "14",
4832
+ height: "14",
4833
+ viewBox: "0 0 16 16",
4834
+ fill: "none",
4835
+ "aria-hidden": "true",
4836
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("circle", {
4837
+ cx: "8",
4838
+ cy: "8",
4839
+ r: "6.2",
4840
+ stroke: "currentColor",
4841
+ strokeWidth: "1.3"
4842
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
4843
+ d: "m5.3 8.1 1.8 1.8 3.6-3.8",
4844
+ stroke: "currentColor",
4845
+ strokeWidth: "1.3",
4846
+ strokeLinecap: "round",
4847
+ strokeLinejoin: "round"
4848
+ })]
4849
+ });
4850
+ if (tone === "danger") return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", {
4851
+ width: "14",
4852
+ height: "14",
4853
+ viewBox: "0 0 16 16",
4854
+ fill: "none",
4855
+ "aria-hidden": "true",
4856
+ children: [
4857
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
4858
+ d: "M8 2.3 14 13H2L8 2.3Z",
4859
+ stroke: "currentColor",
4860
+ strokeWidth: "1.3",
4861
+ strokeLinejoin: "round"
4862
+ }),
4863
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
4864
+ d: "M8 6v3.1",
4865
+ stroke: "currentColor",
4866
+ strokeWidth: "1.3",
4867
+ strokeLinecap: "round"
4868
+ }),
4869
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("circle", {
4870
+ cx: "8",
4871
+ cy: "11.2",
4872
+ r: ".7",
4873
+ fill: "currentColor"
4874
+ })
4875
+ ]
4876
+ });
4877
+ if (tone === "warn") return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", {
4878
+ width: "14",
4879
+ height: "14",
4880
+ viewBox: "0 0 16 16",
4881
+ fill: "none",
4882
+ "aria-hidden": "true",
4883
+ children: [
4884
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("circle", {
4885
+ cx: "8",
4886
+ cy: "8",
4887
+ r: "6.2",
4888
+ stroke: "currentColor",
4889
+ strokeWidth: "1.3"
4890
+ }),
4891
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
4892
+ d: "M8 4.8v3.6",
4893
+ stroke: "currentColor",
4894
+ strokeWidth: "1.3",
4895
+ strokeLinecap: "round"
4896
+ }),
4897
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("circle", {
4898
+ cx: "8",
4899
+ cy: "11.1",
4900
+ r: ".7",
4901
+ fill: "currentColor"
4902
+ })
4903
+ ]
4904
+ });
4905
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", {
4906
+ width: "14",
4907
+ height: "14",
4908
+ viewBox: "0 0 16 16",
4909
+ fill: "none",
4910
+ "aria-hidden": "true",
4911
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
4912
+ d: "M4 2.5h5l3 3v8H4v-11Z",
4913
+ stroke: "currentColor",
4914
+ strokeWidth: "1.2",
4915
+ strokeLinejoin: "round"
4916
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
4917
+ d: "M9 2.5v3h3M6 8h4M6 10.5h3",
4918
+ stroke: "currentColor",
4919
+ strokeWidth: "1.2",
4920
+ strokeLinecap: "round"
4921
+ })]
5033
4922
  });
5034
- if (!available || dismissed) return null;
5035
- return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
5036
- className: WorkspaceUpgradePrompt_module_css_default.banner,
5037
- role: "status",
5038
- "aria-live": "polite",
5039
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
5040
- className: WorkspaceUpgradePrompt_module_css_default.copy,
5041
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("strong", {
5042
- className: WorkspaceUpgradePrompt_module_css_default.title,
5043
- children: t("upgradeAvailableTitle")
5044
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
5045
- className: WorkspaceUpgradePrompt_module_css_default.body,
5046
- children: t("upgradeAvailableBody")
4923
+ }
4924
+ /**
4925
+ * A bell with an unread badge and the shared inbox.
4926
+ *
4927
+ * The bell is a button rather than a menu so keyboard focus and Escape follow the dialog
4928
+ * conventions the rest of the page already uses. Rows mark themselves read when opened;
4929
+ * "全部已读" is the one bulk action.
4930
+ */
4931
+ function NotificationBell({ label, onOpen }) {
4932
+ const state = (0, react.useSyncExternalStore)(subscribeNotifications, notificationSnapshot, notificationSnapshot);
4933
+ const [open, setOpen] = (0, react.useState)(false);
4934
+ const [page, setPage] = (0, react.useState)(0);
4935
+ const items = sortNotifications(state.items);
4936
+ const unread = unreadCount(items);
4937
+ const pages = Math.max(1, Math.ceil(items.length / 20));
4938
+ const visible = items.slice(page * 20, page * 20 + 20);
4939
+ (0, react.useEffect)(() => {
4940
+ if (page >= pages) setPage(pages - 1);
4941
+ }, [page, pages]);
4942
+ (0, react.useEffect)(() => {
4943
+ loadNotifications();
4944
+ }, []);
4945
+ const openOne = (item) => {
4946
+ markRead([item.id]);
4947
+ setOpen(false);
4948
+ onOpen?.(item);
4949
+ };
4950
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
4951
+ type: "button",
4952
+ className: NotificationBell_module_css_default.bell,
4953
+ "aria-label": unread === 0 ? label : label + "," + String(unread) + " 条未读",
4954
+ title: label,
4955
+ "data-notification-bell": "",
4956
+ "data-unread": unread,
4957
+ onClick: () => {
4958
+ setOpen(true);
4959
+ setPage(0);
4960
+ loadNotifications();
4961
+ },
4962
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsxs)("svg", {
4963
+ width: "16",
4964
+ height: "16",
4965
+ viewBox: "0 0 16 16",
4966
+ fill: "none",
4967
+ "aria-hidden": "true",
4968
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
4969
+ d: "M8 2.2a4.1 4.1 0 0 0-4.1 4.1v2.3L2.7 10.8a.6.6 0 0 0 .5.9h9.6a.6.6 0 0 0 .5-.9L12.1 8.6V6.3A4.1 4.1 0 0 0 8 2.2Z",
4970
+ stroke: "currentColor",
4971
+ strokeWidth: "1.2",
4972
+ strokeLinejoin: "round"
4973
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("path", {
4974
+ d: "M6.4 13.2a1.7 1.7 0 0 0 3.2 0",
4975
+ stroke: "currentColor",
4976
+ strokeWidth: "1.2",
4977
+ strokeLinecap: "round"
5047
4978
  })]
5048
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
5049
- className: WorkspaceUpgradePrompt_module_css_default.actions,
5050
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
5051
- variant: "primary",
5052
- size: "sm",
5053
- onClick: openDialog,
5054
- children: t("upgradeAction")
5055
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
5056
- variant: "ghost",
5057
- size: "sm",
4979
+ }), unread === 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
4980
+ className: NotificationBell_module_css_default.badge,
4981
+ children: unread > 99 ? "99+" : unread
4982
+ })]
4983
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(_deepseek_ai_dsh_client_ui_primitives.Modal, {
4984
+ open,
4985
+ onClose: () => {
4986
+ setOpen(false);
4987
+ },
4988
+ title: label,
4989
+ closeLabel: "关闭",
4990
+ className: NotificationBell_module_css_default.dialog,
4991
+ footer: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
4992
+ className: NotificationBell_module_css_default.actions,
4993
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
4994
+ type: "button",
4995
+ className: NotificationBell_module_css_default.linkButton,
5058
4996
  onClick: () => {
5059
- setDismissed(true);
4997
+ markRead("all");
5060
4998
  },
5061
- children: t("upgradeLater")
4999
+ children: "全部已读"
5000
+ }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
5001
+ type: "button",
5002
+ className: NotificationBell_module_css_default.button,
5003
+ onClick: () => {
5004
+ setOpen(false);
5005
+ },
5006
+ children: "关闭"
5062
5007
  })]
5063
- })]
5064
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Modal, {
5065
- open: dialogOpen,
5066
- onClose: closeDialog,
5067
- title: t("upgradeDialogTitle"),
5068
- description: t("upgradeDialogBody"),
5069
- closeLabel: t("upgradeCancel"),
5070
- footer: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
5071
- variant: "ghost",
5072
- onClick: closeDialog,
5073
- disabled: busy,
5074
- children: t("upgradeCancel")
5075
- }), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_deepseek_ai_dsh_client_ui_primitives.Button, {
5076
- variant: "primary",
5077
- onClick: () => {
5078
- upgrade();
5079
- },
5080
- disabled: busy,
5081
- children: busy ? t("upgradeBusy") : sessionCount === 0 ? t("upgradeAction") : t("upgradeConfirm")
5082
- })] }),
5083
- children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
5084
- className: WorkspaceUpgradePrompt_module_css_default.dialogBody,
5085
- children: [
5086
- /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
5087
- className: WorkspaceUpgradePrompt_module_css_default.dialogText,
5088
- children: sessionCount === 0 ? t("upgradeNoSessions") : warning
5089
- }),
5090
- sessionCount > 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("ul", {
5091
- className: WorkspaceUpgradePrompt_module_css_default.sessionList,
5092
- children: status?.activeSessions.map((session) => /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("li", {
5093
- className: WorkspaceUpgradePrompt_module_css_default.sessionRow,
5094
- children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
5095
- className: WorkspaceUpgradePrompt_module_css_default.sessionTitle,
5096
- children: session.title ?? session.sessionId
5097
- }), session.cwd ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
5098
- className: WorkspaceUpgradePrompt_module_css_default.sessionPath,
5099
- children: session.cwd
5100
- }) : null]
5101
- }, session.sessionId))
5102
- }) : null,
5103
- error !== "" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
5104
- className: WorkspaceUpgradePrompt_module_css_default.error,
5105
- role: "alert",
5106
- children: error
5107
- }) : null
5108
- ]
5109
- })
5008
+ }),
5009
+ children: [
5010
+ reviewDemoMode() ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
5011
+ className: NotificationBell_module_css_default.demo,
5012
+ children: "演示数据 · 后端契约到达后自动切换"
5013
+ }) : null,
5014
+ state.status === "unavailable" ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
5015
+ className: NotificationBell_module_css_default.empty,
5016
+ children: "通知服务待后端联调(task-35);上线后这里会显示审核、上架与 AI 报告事件。"
5017
+ }) : null,
5018
+ state.status !== "unavailable" && items.length === 0 ? /* @__PURE__ */ (0, react_jsx_runtime.jsx)("p", {
5019
+ className: NotificationBell_module_css_default.empty,
5020
+ children: "暂无通知。"
5021
+ }) : null,
5022
+ items.length === 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("ul", {
5023
+ className: NotificationBell_module_css_default.list,
5024
+ children: visible.map((item) => /* @__PURE__ */ (0, react_jsx_runtime.jsx)("li", { children: /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("button", {
5025
+ type: "button",
5026
+ className: NotificationBell_module_css_default.row,
5027
+ onClick: () => {
5028
+ openOne(item);
5029
+ },
5030
+ children: [
5031
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
5032
+ className: NotificationBell_module_css_default.rowIcon,
5033
+ "data-tone": notificationTone(item.type),
5034
+ "aria-hidden": "true",
5035
+ children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(NotificationIcon, { tone: notificationTone(item.type) })
5036
+ }),
5037
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
5038
+ className: NotificationBell_module_css_default.rowBody,
5039
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
5040
+ className: NotificationBell_module_css_default.rowTitle,
5041
+ children: item.title
5042
+ }), item.body === void 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
5043
+ className: NotificationBell_module_css_default.rowText,
5044
+ children: item.body
5045
+ })]
5046
+ }),
5047
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", {
5048
+ className: NotificationBell_module_css_default.rowMeta,
5049
+ children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
5050
+ className: NotificationBell_module_css_default.rowTime,
5051
+ children: item.createdAt.slice(0, 16).replace("T", " ")
5052
+ }), item.read ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
5053
+ className: NotificationBell_module_css_default.dot,
5054
+ "aria-hidden": "true"
5055
+ })]
5056
+ })
5057
+ ]
5058
+ }) }, item.id))
5059
+ }),
5060
+ items.length === 0 ? null : /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
5061
+ className: NotificationBell_module_css_default.pager,
5062
+ children: [
5063
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
5064
+ type: "button",
5065
+ disabled: page === 0,
5066
+ onClick: () => {
5067
+ setPage((current) => Math.max(0, current - 1));
5068
+ },
5069
+ children: "上一页"
5070
+ }),
5071
+ /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("span", { children: [
5072
+ "第 ",
5073
+ page + 1,
5074
+ " / ",
5075
+ pages,
5076
+ " 页 · 共 ",
5077
+ items.length,
5078
+ " 条"
5079
+ ] }),
5080
+ /* @__PURE__ */ (0, react_jsx_runtime.jsx)("button", {
5081
+ type: "button",
5082
+ disabled: page >= pages - 1,
5083
+ onClick: () => {
5084
+ setPage((current) => Math.min(pages - 1, current + 1));
5085
+ },
5086
+ children: "下一页"
5087
+ })
5088
+ ]
5089
+ })
5090
+ ]
5110
5091
  })] });
5111
5092
  }
5093
+ /** The automation page's seat: the same inbox under the workflow plaza's heading. */
5094
+ function WorkflowPlazaBell() {
5095
+ return /* @__PURE__ */ (0, react_jsx_runtime.jsx)(NotificationBell, { label: "自动化任务通知" });
5096
+ }
5112
5097
  //#endregion
5113
5098
  //#region src/client/ResourceCatalogSidebar.tsx
5114
5099
  /**
@@ -5577,7 +5562,7 @@ window.__ModuleLoader__.load({
5577
5562
  let live = true;
5578
5563
  const load = async () => {
5579
5564
  try {
5580
- const response = await fetch("/integrations/dataops/resource-tab/config", { cache: "no-store" });
5565
+ const response = await fetch("integrations/dataops/resource-tab/config", { cache: "no-store" });
5581
5566
  if (!response.ok) throw new Error("HTTP " + response.status.toString());
5582
5567
  const body = await response.json();
5583
5568
  if (!live) return;
@@ -5803,7 +5788,7 @@ window.__ModuleLoader__.load({
5803
5788
  */
5804
5789
  /** Tab id shared with the client registration. */
5805
5790
  const RESOURCE_TAB_TYPE = "dataops-resources";
5806
- const EVENTS_PATH = "/integrations/dataops/open-resource/events";
5791
+ const EVENTS_PATH = "integrations/dataops/open-resource/events";
5807
5792
  const isOpenResourceEvent = (value) => {
5808
5793
  if (typeof value !== "object" || value === null) return false;
5809
5794
  const record = value;
@@ -6173,7 +6158,7 @@ window.__ModuleLoader__.load({
6173
6158
  //#region src/client/index.ts
6174
6159
  const NS = "settings.dataops-managed";
6175
6160
  const AUTH_UPDATED_MESSAGE = "dataops-auth-updated";
6176
- const MANAGED_AUTH_PATH = "/integrations/dataops/managed-auth";
6161
+ const MANAGED_AUTH_PATH = "integrations/dataops/managed-auth";
6177
6162
  /** Sidebar entry and main page id for the permission centre. */
6178
6163
  const PERMISSION_PANEL_ID = "dataops-permissions";
6179
6164
  /** Required client services for the managed DataOps Settings section and the resource tab bridge. */
@@ -6212,6 +6197,36 @@ window.__ModuleLoader__.load({
6212
6197
  en
6213
6198
  }), "dataops-managed: settings copy");
6214
6199
  installWanxiangBranding(ctx);
6200
+ /**
6201
+ * The DSH logo returns to the portal page the reader entered from.
6202
+ *
6203
+ * The portal records `dataops.ai.returnTo` in sessionStorage before mounting this frame;
6204
+ * its shell owns the router, so this half only asks it to navigate. The menu label is
6205
+ * DSH-owned, hence the visible-text match rather than a stable id.
6206
+ */
6207
+ ctx.effect(() => {
6208
+ if (window.parent === window) return () => {};
6209
+ const onLogoClick = (event) => {
6210
+ const target = event.target;
6211
+ if (!(target instanceof Element)) return;
6212
+ let node = target;
6213
+ for (let depth = 0; node !== null && depth < 5; depth += 1, node = node.parentElement) {
6214
+ const rect = node.getBoundingClientRect();
6215
+ if (rect.top > 120 || rect.left > 360 || rect.width <= 0 || rect.width > 520) break;
6216
+ if (/万相AI中台|Wanxiang AI/i.test((node.textContent ?? "").trim())) {
6217
+ event.preventDefault();
6218
+ event.stopPropagation();
6219
+ window.parent.postMessage({
6220
+ type: "dataops:return-to",
6221
+ version: 1
6222
+ }, "*");
6223
+ return;
6224
+ }
6225
+ }
6226
+ };
6227
+ document.addEventListener("click", onLogoClick, true);
6228
+ return () => document.removeEventListener("click", onLogoClick, true);
6229
+ }, "dataops-managed: return-to logo");
6215
6230
  const t = ctx.locale.bind(NS);
6216
6231
  /**
6217
6232
  * Register the settings section only for the two administrator role labels.