@stigmer/react 3.4.0 → 3.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (208) hide show
  1. package/agent/AgentDetailView.d.ts +14 -4
  2. package/agent/AgentDetailView.d.ts.map +1 -1
  3. package/agent/AgentDetailView.js +73 -11
  4. package/agent/AgentDetailView.js.map +1 -1
  5. package/agent/internal/agentToInput.d.ts +3 -0
  6. package/agent/internal/agentToInput.d.ts.map +1 -1
  7. package/agent/internal/agentToInput.js +21 -1
  8. package/agent/internal/agentToInput.js.map +1 -1
  9. package/agent/useAgentCount.d.ts +2 -0
  10. package/agent/useAgentCount.d.ts.map +1 -1
  11. package/agent/useAgentCount.js.map +1 -1
  12. package/api-key/ApiKeyListPanel.d.ts +8 -1
  13. package/api-key/ApiKeyListPanel.d.ts.map +1 -1
  14. package/api-key/ApiKeyListPanel.js +9 -7
  15. package/api-key/ApiKeyListPanel.js.map +1 -1
  16. package/api-key/CreateApiKeyForm.d.ts +7 -1
  17. package/api-key/CreateApiKeyForm.d.ts.map +1 -1
  18. package/api-key/CreateApiKeyForm.js +2 -2
  19. package/api-key/CreateApiKeyForm.js.map +1 -1
  20. package/datastore/useDatastoreCount.d.ts +2 -0
  21. package/datastore/useDatastoreCount.d.ts.map +1 -1
  22. package/datastore/useDatastoreCount.js.map +1 -1
  23. package/dependency-graph/DependencyTreeNode.d.ts.map +1 -1
  24. package/dependency-graph/DependencyTreeNode.js +8 -0
  25. package/dependency-graph/DependencyTreeNode.js.map +1 -1
  26. package/dependency-graph/types.d.ts +20 -8
  27. package/dependency-graph/types.d.ts.map +1 -1
  28. package/dependency-graph/useDependencyGraph.d.ts.map +1 -1
  29. package/dependency-graph/useDependencyGraph.js +21 -1
  30. package/dependency-graph/useDependencyGraph.js.map +1 -1
  31. package/index.d.ts +6 -4
  32. package/index.d.ts.map +1 -1
  33. package/index.js +6 -2
  34. package/index.js.map +1 -1
  35. package/internal/scroll-area.d.ts +4 -0
  36. package/internal/scroll-area.d.ts.map +1 -0
  37. package/internal/scroll-area.js +15 -0
  38. package/internal/scroll-area.js.map +1 -0
  39. package/internal/tooltip.d.ts +7 -0
  40. package/internal/tooltip.d.ts.map +1 -0
  41. package/internal/tooltip.js +31 -0
  42. package/internal/tooltip.js.map +1 -0
  43. package/manifest/ApplyManifestDialog.d.ts +10 -5
  44. package/manifest/ApplyManifestDialog.d.ts.map +1 -1
  45. package/manifest/ApplyManifestDialog.js +30 -13
  46. package/manifest/ApplyManifestDialog.js.map +1 -1
  47. package/manifest/useApplyManifest.d.ts +6 -2
  48. package/manifest/useApplyManifest.d.ts.map +1 -1
  49. package/manifest/useApplyManifest.js +5 -5
  50. package/manifest/useApplyManifest.js.map +1 -1
  51. package/mcp-server/McpServerDetailView.d.ts +38 -2
  52. package/mcp-server/McpServerDetailView.d.ts.map +1 -1
  53. package/mcp-server/McpServerDetailView.js +21 -5
  54. package/mcp-server/McpServerDetailView.js.map +1 -1
  55. package/mcp-server/StdioSandboxNotice.d.ts +12 -11
  56. package/mcp-server/StdioSandboxNotice.d.ts.map +1 -1
  57. package/mcp-server/StdioSandboxNotice.js +13 -12
  58. package/mcp-server/StdioSandboxNotice.js.map +1 -1
  59. package/mcp-server/index.d.ts +7 -0
  60. package/mcp-server/index.d.ts.map +1 -1
  61. package/mcp-server/index.js +9 -0
  62. package/mcp-server/index.js.map +1 -1
  63. package/mcp-server/steps/EnvironmentAuthStep.d.ts +4 -0
  64. package/mcp-server/steps/EnvironmentAuthStep.d.ts.map +1 -1
  65. package/mcp-server/steps/EnvironmentAuthStep.js +4 -0
  66. package/mcp-server/steps/EnvironmentAuthStep.js.map +1 -1
  67. package/mcp-server/steps/IdentityTransportStep.d.ts +6 -0
  68. package/mcp-server/steps/IdentityTransportStep.d.ts.map +1 -1
  69. package/mcp-server/steps/IdentityTransportStep.js +7 -1
  70. package/mcp-server/steps/IdentityTransportStep.js.map +1 -1
  71. package/mcp-server/steps/ReviewStep.d.ts +5 -0
  72. package/mcp-server/steps/ReviewStep.d.ts.map +1 -1
  73. package/mcp-server/steps/ReviewStep.js +16 -2
  74. package/mcp-server/steps/ReviewStep.js.map +1 -1
  75. package/mcp-server/useMcpServerCount.d.ts +2 -0
  76. package/mcp-server/useMcpServerCount.d.ts.map +1 -1
  77. package/mcp-server/useMcpServerCount.js.map +1 -1
  78. package/package.json +4 -4
  79. package/resource-creation/CreationPicker.d.ts.map +1 -1
  80. package/resource-creation/CreationPicker.js +3 -3
  81. package/resource-creation/CreationPicker.js.map +1 -1
  82. package/resource-creation/WizardNav.d.ts.map +1 -1
  83. package/resource-creation/WizardNav.js +1 -1
  84. package/resource-creation/WizardNav.js.map +1 -1
  85. package/resource-creation/templates/mcp-server-templates.d.ts.map +1 -1
  86. package/resource-creation/templates/mcp-server-templates.js +17 -14
  87. package/resource-creation/templates/mcp-server-templates.js.map +1 -1
  88. package/resource-detail/Section.d.ts +8 -1
  89. package/resource-detail/Section.d.ts.map +1 -1
  90. package/resource-detail/Section.js +2 -2
  91. package/resource-detail/Section.js.map +1 -1
  92. package/resource-workbench/components/ResourceWorkbench.d.ts +9 -1
  93. package/resource-workbench/components/ResourceWorkbench.d.ts.map +1 -1
  94. package/resource-workbench/components/ResourceWorkbench.js +2 -1
  95. package/resource-workbench/components/ResourceWorkbench.js.map +1 -1
  96. package/resource-workbench/hooks/useResourceCollection.d.ts +9 -0
  97. package/resource-workbench/hooks/useResourceCollection.d.ts.map +1 -1
  98. package/resource-workbench/hooks/useResourceCollection.js +2 -2
  99. package/resource-workbench/hooks/useResourceCollection.js.map +1 -1
  100. package/search/useResourceCount.d.ts +7 -0
  101. package/search/useResourceCount.d.ts.map +1 -1
  102. package/search/useResourceCount.js +2 -1
  103. package/search/useResourceCount.js.map +1 -1
  104. package/session/NewSessionViewer.d.ts.map +1 -1
  105. package/session/NewSessionViewer.js +17 -3
  106. package/session/NewSessionViewer.js.map +1 -1
  107. package/session/SessionViewer.d.ts +2 -1
  108. package/session/SessionViewer.d.ts.map +1 -1
  109. package/session/SessionViewer.js +19 -11
  110. package/session/SessionViewer.js.map +1 -1
  111. package/session/SessionViewerLayout.d.ts +90 -0
  112. package/session/SessionViewerLayout.d.ts.map +1 -0
  113. package/session/SessionViewerLayout.js +32 -0
  114. package/session/SessionViewerLayout.js.map +1 -0
  115. package/session/index.d.ts +4 -0
  116. package/session/index.d.ts.map +1 -1
  117. package/session/index.js +10 -0
  118. package/session/index.js.map +1 -1
  119. package/session/useSessionRailViews.d.ts +2 -2
  120. package/sidebar/SettingsSidebar.d.ts +62 -0
  121. package/sidebar/SettingsSidebar.d.ts.map +1 -0
  122. package/sidebar/SettingsSidebar.js +60 -0
  123. package/sidebar/SettingsSidebar.js.map +1 -0
  124. package/sidebar/WorkspaceSidebar.d.ts +87 -0
  125. package/sidebar/WorkspaceSidebar.d.ts.map +1 -0
  126. package/sidebar/WorkspaceSidebar.js +95 -0
  127. package/sidebar/WorkspaceSidebar.js.map +1 -0
  128. package/sidebar/chrome.d.ts +48 -0
  129. package/sidebar/chrome.d.ts.map +1 -0
  130. package/sidebar/chrome.js +32 -0
  131. package/sidebar/chrome.js.map +1 -0
  132. package/sidebar/index.d.ts +6 -0
  133. package/sidebar/index.d.ts.map +1 -0
  134. package/sidebar/index.js +9 -0
  135. package/sidebar/index.js.map +1 -0
  136. package/sidebar/types.d.ts +54 -0
  137. package/sidebar/types.d.ts.map +1 -0
  138. package/sidebar/types.js +2 -0
  139. package/sidebar/types.js.map +1 -0
  140. package/skill/useSkillCount.d.ts +2 -0
  141. package/skill/useSkillCount.d.ts.map +1 -1
  142. package/skill/useSkillCount.js.map +1 -1
  143. package/src/agent/AgentDetailView.tsx +198 -11
  144. package/src/agent/__tests__/AgentDetailView.datastores.test.tsx +166 -0
  145. package/src/agent/internal/__tests__/agentToInput.test.ts +154 -0
  146. package/src/agent/internal/agentToInput.ts +25 -7
  147. package/src/agent/useAgentCount.ts +2 -0
  148. package/src/api-key/ApiKeyListPanel.tsx +17 -4
  149. package/src/api-key/CreateApiKeyForm.tsx +8 -1
  150. package/src/api-key/__tests__/CreateApiKeyForm.test.tsx +58 -0
  151. package/src/datastore/useDatastoreCount.ts +2 -0
  152. package/src/dependency-graph/DependencyTreeNode.tsx +8 -0
  153. package/src/dependency-graph/__tests__/useDependencyGraph.test.ts +108 -0
  154. package/src/dependency-graph/types.ts +20 -8
  155. package/src/dependency-graph/useDependencyGraph.ts +23 -1
  156. package/src/index.ts +24 -0
  157. package/src/internal/scroll-area.tsx +37 -0
  158. package/src/internal/tooltip.tsx +66 -0
  159. package/src/manifest/ApplyManifestDialog.tsx +40 -16
  160. package/src/manifest/__tests__/ApplyManifestDialog.test.tsx +147 -0
  161. package/src/manifest/__tests__/useApplyManifest.test.tsx +6 -6
  162. package/src/manifest/useApplyManifest.ts +12 -8
  163. package/src/mcp-server/McpServerDetailView.tsx +52 -4
  164. package/src/mcp-server/StdioSandboxNotice.tsx +16 -14
  165. package/src/mcp-server/__tests__/McpServerDetailView.test.tsx +345 -0
  166. package/src/mcp-server/__tests__/StdioSandboxNotice.test.tsx +3 -2
  167. package/src/mcp-server/index.ts +13 -0
  168. package/src/mcp-server/steps/EnvironmentAuthStep.tsx +4 -0
  169. package/src/mcp-server/steps/IdentityTransportStep.tsx +16 -1
  170. package/src/mcp-server/steps/ReviewStep.tsx +18 -1
  171. package/src/mcp-server/useMcpServerCount.ts +2 -0
  172. package/src/resource-creation/CreationPicker.tsx +7 -0
  173. package/src/resource-creation/WizardNav.tsx +1 -0
  174. package/src/resource-creation/templates/mcp-server-templates.ts +17 -14
  175. package/src/resource-detail/Section.tsx +9 -1
  176. package/src/resource-workbench/components/ResourceWorkbench.tsx +13 -0
  177. package/src/resource-workbench/hooks/useResourceCollection.ts +11 -1
  178. package/src/search/useResourceCount.ts +9 -1
  179. package/src/session/NewSessionViewer.tsx +48 -61
  180. package/src/session/SessionViewer.tsx +71 -86
  181. package/src/session/SessionViewerLayout.tsx +131 -0
  182. package/src/session/__tests__/SessionViewerLayout.test.tsx +140 -0
  183. package/src/session/index.ts +14 -0
  184. package/src/session/useSessionRailViews.tsx +2 -2
  185. package/src/sidebar/SettingsSidebar.tsx +173 -0
  186. package/src/sidebar/WorkspaceSidebar.tsx +386 -0
  187. package/src/sidebar/__tests__/SettingsSidebar.test.tsx +107 -0
  188. package/src/sidebar/__tests__/WorkspaceSidebar.test.tsx +236 -0
  189. package/src/sidebar/chrome.tsx +129 -0
  190. package/src/sidebar/index.ts +16 -0
  191. package/src/sidebar/types.ts +55 -0
  192. package/src/skill/useSkillCount.ts +2 -0
  193. package/src/test/__tests__/samples.test.ts +161 -2
  194. package/src/test/index.ts +1 -1
  195. package/src/test/samples.ts +157 -14
  196. package/src/workflow/useWorkflowCount.ts +2 -0
  197. package/styles.css +1 -1
  198. package/test/index.d.ts +1 -1
  199. package/test/index.d.ts.map +1 -1
  200. package/test/index.js +1 -1
  201. package/test/index.js.map +1 -1
  202. package/test/samples.d.ts +100 -7
  203. package/test/samples.d.ts.map +1 -1
  204. package/test/samples.js +133 -14
  205. package/test/samples.js.map +1 -1
  206. package/workflow/useWorkflowCount.d.ts +2 -0
  207. package/workflow/useWorkflowCount.d.ts.map +1 -1
  208. package/workflow/useWorkflowCount.js.map +1 -1
@@ -0,0 +1,62 @@
1
+ import type { ReactNode } from "react";
2
+ import type { Organization } from "@stigmer/protos/ai/stigmer/tenancy/organization/v1/api_pb";
3
+ import type { SettingsNavGroup } from "../settings/settings-nav.js";
4
+ import type { RenderSidebarLink } from "./types.js";
5
+ /** Props for {@link SettingsSidebar}. */
6
+ export interface SettingsSidebarProps {
7
+ /**
8
+ * Grouped settings navigation to render. The console passes
9
+ * `useSettingsNavGroups()` (permission-aware); deterministic hosts
10
+ * pass `SETTINGS_NAV_GROUPS` or a fixture subset.
11
+ */
12
+ readonly groups: readonly SettingsNavGroup[];
13
+ /**
14
+ * Current pathname for active-row matching: a row is active when the
15
+ * path equals its `href` or sits under `href + "/"`. Omit for hosts
16
+ * with no location (deterministic embeds pass the depicted route).
17
+ */
18
+ readonly activePath?: string | null;
19
+ /** Renders each interactive row. See {@link RenderSidebarLink}. */
20
+ readonly renderLink: RenderSidebarLink;
21
+ /**
22
+ * "Back to Sessions" target — the last workspace-zone location, so
23
+ * leaving settings restores where the user was. @default "/"
24
+ */
25
+ readonly backHref?: string;
26
+ /** Footer content — typically the host app's `UserMenu` wrapper. */
27
+ readonly footer: ReactNode;
28
+ /** Reflected as `aria-expanded` on the collapse toggle. @default true */
29
+ readonly isOpen?: boolean;
30
+ /** Called when the collapse toggle is pressed. */
31
+ readonly onCollapse?: () => void;
32
+ /** Passed through to the embedded `OrgSwitcher`. */
33
+ readonly onOrgChanged?: (org: Organization) => void;
34
+ }
35
+ /**
36
+ * The console's settings-zone (management) sidebar: org switcher, a
37
+ * "Back to Sessions" exit, and grouped settings navigation driven by
38
+ * the SDK's settings-nav model, with a user footer.
39
+ *
40
+ * Like {@link WorkspaceSidebar}, this is the exact component the web
41
+ * console, desktop app, and documentation tours all render; hosts vary
42
+ * only `renderLink`, `groups`, and the `footer` slot.
43
+ *
44
+ * Row identifiers passed to `renderLink` are the settings route
45
+ * basenames (`"api-keys"`, `"members"`, …) plus `"back-to-sessions"`,
46
+ * so consumers can address specific rows without parsing hrefs.
47
+ *
48
+ * @example
49
+ * ```tsx
50
+ * <SettingsSidebar
51
+ * groups={useSettingsNavGroups()}
52
+ * activePath={usePathname()}
53
+ * backHref={lastSessionZonePath ?? "/"}
54
+ * renderLink={({ href, children, ...rest }) => (
55
+ * <Link href={href} {...rest}>{children}</Link>
56
+ * )}
57
+ * footer={<UserMenu />}
58
+ * />
59
+ * ```
60
+ */
61
+ export declare function SettingsSidebar({ groups, activePath, renderLink, backHref, footer, isOpen, onCollapse, onOrgChanged, }: SettingsSidebarProps): import("react/jsx-runtime").JSX.Element;
62
+ //# sourceMappingURL=SettingsSidebar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SettingsSidebar.d.ts","sourceRoot":"","sources":["../../src/sidebar/SettingsSidebar.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2DAA2D,CAAC;AAC9F,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAC;AAEpE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAMpD,yCAAyC;AACzC,MAAM,WAAW,oBAAoB;IACnC;;;;OAIG;IACH,QAAQ,CAAC,MAAM,EAAE,SAAS,gBAAgB,EAAE,CAAC;IAC7C;;;;OAIG;IACH,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACpC,mEAAmE;IACnE,QAAQ,CAAC,UAAU,EAAE,iBAAiB,CAAC;IACvC;;;OAGG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B,oEAAoE;IACpE,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC;IAC3B,yEAAyE;IACzE,QAAQ,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC;IAC1B,kDAAkD;IAClD,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,IAAI,CAAC;IACjC,oDAAoD;IACpD,QAAQ,CAAC,YAAY,CAAC,EAAE,CAAC,GAAG,EAAE,YAAY,KAAK,IAAI,CAAC;CACrD;AAED;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,wBAAgB,eAAe,CAAC,EAC9B,MAAM,EACN,UAAiB,EACjB,UAAU,EACV,QAAc,EACd,MAAM,EACN,MAAa,EACb,UAAU,EACV,YAAY,GACb,EAAE,oBAAoB,2CA4DtB"}
@@ -0,0 +1,60 @@
1
+ "use client";
2
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
3
+ import { ArrowLeft } from "lucide-react";
4
+ import { SidebarChrome, SidebarSeparator, navRowClassName } from "./chrome.js";
5
+ /**
6
+ * The console's settings-zone (management) sidebar: org switcher, a
7
+ * "Back to Sessions" exit, and grouped settings navigation driven by
8
+ * the SDK's settings-nav model, with a user footer.
9
+ *
10
+ * Like {@link WorkspaceSidebar}, this is the exact component the web
11
+ * console, desktop app, and documentation tours all render; hosts vary
12
+ * only `renderLink`, `groups`, and the `footer` slot.
13
+ *
14
+ * Row identifiers passed to `renderLink` are the settings route
15
+ * basenames (`"api-keys"`, `"members"`, …) plus `"back-to-sessions"`,
16
+ * so consumers can address specific rows without parsing hrefs.
17
+ *
18
+ * @example
19
+ * ```tsx
20
+ * <SettingsSidebar
21
+ * groups={useSettingsNavGroups()}
22
+ * activePath={usePathname()}
23
+ * backHref={lastSessionZonePath ?? "/"}
24
+ * renderLink={({ href, children, ...rest }) => (
25
+ * <Link href={href} {...rest}>{children}</Link>
26
+ * )}
27
+ * footer={<UserMenu />}
28
+ * />
29
+ * ```
30
+ */
31
+ export function SettingsSidebar({ groups, activePath = null, renderLink, backHref = "/", footer, isOpen = true, onCollapse, onOrgChanged, }) {
32
+ return (_jsxs(SidebarChrome, { ariaLabel: "Management navigation", isOpen: isOpen, onCollapse: onCollapse, onOrgChanged: onOrgChanged, footer: footer, children: [_jsx("div", { className: "flex-none px-3 py-1", children: renderLink({
33
+ id: "back-to-sessions",
34
+ href: backHref,
35
+ active: false,
36
+ className: navRowClassName(false, { muted: true }),
37
+ "aria-current": undefined,
38
+ children: (_jsxs(_Fragment, { children: [_jsx(ArrowLeft, { className: "size-4 shrink-0" }), "Back to Sessions"] })),
39
+ }) }), _jsx(SidebarSeparator, {}), _jsx("div", { className: "flex flex-col gap-4 px-3 py-1", children: groups.map((group) => (_jsxs("div", { className: "flex flex-col gap-0.5", children: [_jsx("span", { className: "text-sidebar-muted-foreground px-2 pb-1 text-[11px] font-medium tracking-wider uppercase", children: group.label }), group.items.map((item) => {
40
+ const active = activePath != null &&
41
+ (activePath === item.href ||
42
+ activePath.startsWith(`${item.href}/`));
43
+ return (_jsx(SettingsNavRow, { href: item.href, label: item.label, icon: _jsx(item.icon, { className: "size-4 shrink-0" }), active: active, renderLink: renderLink }, item.href));
44
+ })] }, group.label))) }), _jsx("div", { className: "flex-1" })] }));
45
+ }
46
+ // ---------------------------------------------------------------------------
47
+ // Internals
48
+ // ---------------------------------------------------------------------------
49
+ function SettingsNavRow({ href, label, icon, active, renderLink, }) {
50
+ return renderLink({
51
+ // Route basename as the stable id: "/settings/api-keys" → "api-keys".
52
+ id: href.slice(href.lastIndexOf("/") + 1),
53
+ href,
54
+ active,
55
+ className: navRowClassName(active),
56
+ "aria-current": active ? "page" : undefined,
57
+ children: (_jsxs(_Fragment, { children: [icon, label] })),
58
+ });
59
+ }
60
+ //# sourceMappingURL=SettingsSidebar.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SettingsSidebar.js","sourceRoot":"","sources":["../../src/sidebar/SettingsSidebar.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAGb,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAGzC,OAAO,EAAE,aAAa,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAsC/E;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,MAAM,UAAU,eAAe,CAAC,EAC9B,MAAM,EACN,UAAU,GAAG,IAAI,EACjB,UAAU,EACV,QAAQ,GAAG,GAAG,EACd,MAAM,EACN,MAAM,GAAG,IAAI,EACb,UAAU,EACV,YAAY,GACS;IACrB,OAAO,CACL,MAAC,aAAa,IACZ,SAAS,EAAC,uBAAuB,EACjC,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,UAAU,EACtB,YAAY,EAAE,YAAY,EAC1B,MAAM,EAAE,MAAM,aAGd,cAAK,SAAS,EAAC,qBAAqB,YACjC,UAAU,CAAC;oBACV,EAAE,EAAE,kBAAkB;oBACtB,IAAI,EAAE,QAAQ;oBACd,MAAM,EAAE,KAAK;oBACb,SAAS,E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,CAAC,KAAK,CAAC,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;QACzC,IAAI;QACJ,MAAM;QACN,SAAS,EAAE,eAAe,CAAC,MAAM,CAAC;QAClC,cAAc,EAAE,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,SAAS;QAC3C,QAAQ,EAAE,CACR,8BACG,IAAI,EACJ,KAAK,IACL,CACJ;KACF,CAAC,CAAC;AACL,CAAC"}
@@ -0,0 +1,87 @@
1
+ import { type ReactNode } from "react";
2
+ import type { Organization } from "@stigmer/protos/ai/stigmer/tenancy/organization/v1/api_pb";
3
+ import type { RecentActivityEntry } from "../activity/types.js";
4
+ import type { RenderSidebarLink } from "./types.js";
5
+ /** Primary navigation destinations in the workspace sidebar. */
6
+ export type WorkspaceNavId = "new-session" | "dashboard" | "library";
7
+ /**
8
+ * Recent-activity data for the sidebar's Recents section — the return
9
+ * shape of `useRecentActivity`, narrowed to what the sidebar renders.
10
+ * Deterministic hosts pass frozen fixture entries instead.
11
+ */
12
+ export interface WorkspaceSidebarActivity {
13
+ readonly entries: readonly RecentActivityEntry[];
14
+ /** True during the initial fetch; renders loading skeletons. */
15
+ readonly isLoading?: boolean;
16
+ /** Non-null when the fetch failed; renders an inline alert. */
17
+ readonly error?: {
18
+ readonly message: string;
19
+ } | null;
20
+ }
21
+ /** Props for {@link WorkspaceSidebar}. */
22
+ export interface WorkspaceSidebarProps {
23
+ /**
24
+ * Which primary nav row is the current location, or `null`/omitted
25
+ * when none is (e.g. inside a session). The sidebar renders state
26
+ * only — the host decides what "active" means for its routes.
27
+ */
28
+ readonly activeNav?: WorkspaceNavId | null;
29
+ /** Renders each interactive row. See {@link RenderSidebarLink}. */
30
+ readonly renderLink: RenderSidebarLink;
31
+ /** Recent activity entries plus fetch state. */
32
+ readonly recentActivity: WorkspaceSidebarActivity;
33
+ /** Session id highlighted in Recents, if a session is open. */
34
+ readonly activeSessionId?: string | null;
35
+ /** Workflow-execution id highlighted in Recents, if one is open. */
36
+ readonly activeExecutionId?: string | null;
37
+ /**
38
+ * Optional trailing accessory per recents row — e.g. the desktop
39
+ * app's "running in background" pulse dot. Rendered after the
40
+ * timestamp column, inside the row.
41
+ */
42
+ readonly renderEntryAccessory?: (entry: RecentActivityEntry) => ReactNode;
43
+ /** Footer content — typically the host app's `UserMenu` wrapper. */
44
+ readonly footer: ReactNode;
45
+ /** Reflected as `aria-expanded` on the collapse toggle. @default true */
46
+ readonly isOpen?: boolean;
47
+ /** Called when the collapse toggle is pressed. */
48
+ readonly onCollapse?: () => void;
49
+ /** Passed through to the embedded `OrgSwitcher`. */
50
+ readonly onOrgChanged?: (org: Organization) => void;
51
+ /**
52
+ * Reference instant for time bucketing ("Today"/"Yesterday") and
53
+ * relative stamps ("2h"). Defaults to the live clock. **Deterministic
54
+ * hosts (documentation embeds, video export) must pass a frozen
55
+ * instant** — otherwise the depicted times drift with every replay.
56
+ */
57
+ readonly now?: Date;
58
+ }
59
+ /**
60
+ * The console's workspace-zone sidebar: org switcher, primary navigation
61
+ * (New Session / Dashboard / Library), time-bucketed recent activity,
62
+ * and a user footer.
63
+ *
64
+ * This is the same component the Stigmer web console and desktop app
65
+ * render — hosts differ only in what they return from `renderLink`
66
+ * (their router's link), what they pass as `recentActivity` (live hook
67
+ * data or frozen fixtures), and the `footer` slot. Documentation tours
68
+ * render it too, which is the point: the depicted chrome cannot drift
69
+ * from the product because it *is* the product (stigmer/stigmer#317).
70
+ *
71
+ * Layout note: the sidebar fills its container's height and defines no
72
+ * width — the console's app shell owns the `w-70` (280px) column.
73
+ *
74
+ * @example
75
+ * ```tsx
76
+ * <WorkspaceSidebar
77
+ * activeNav="library"
78
+ * renderLink={({ href, children, ...rest }) => (
79
+ * <Link href={href} {...rest}>{children}</Link>
80
+ * )}
81
+ * recentActivity={useRecentActivity()}
82
+ * footer={<UserMenu />}
83
+ * />
84
+ * ```
85
+ */
86
+ export declare function WorkspaceSidebar({ activeNav, renderLink, recentActivity, activeSessionId, activeExecutionId, renderEntryAccessory, footer, isOpen, onCollapse, onOrgChanged, now, }: WorkspaceSidebarProps): import("react/jsx-runtime").JSX.Element;
87
+ //# sourceMappingURL=WorkspaceSidebar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WorkspaceSidebar.d.ts","sourceRoot":"","sources":["../../src/sidebar/WorkspaceSidebar.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAiB,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAStD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2DAA2D,CAAC;AAC9F,OAAO,KAAK,EAAE,mBAAmB,EAAuB,MAAM,sBAAsB,CAAC;AAYrF,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAMpD,gEAAgE;AAChE,MAAM,MAAM,cAAc,GAAG,aAAa,GAAG,WAAW,GAAG,SAAS,CAAC;AAErE;;;;GAIG;AACH,MAAM,WAAW,wBAAwB;IACvC,QAAQ,CAAC,OAAO,EAAE,SAAS,mBAAmB,EAAE,CAAC;IACjD,gEAAgE;IAChE,QAAQ,CAAC,SAAS,CAAC,EAAE,OAAO,CAAC;IAC7B,+DAA+D;IAC/D,QAAQ,CAAC,KAAK,CAAC,EAAE;QAAE,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC;CACtD;AAED,0CAA0C;AAC1C,MAAM,WAAW,qBAAqB;IACpC;;;;OAIG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,cAAc,GAAG,IAAI,CAAC;IAC3C,mEAAmE;IACnE,QAAQ,CAAC,UAAU,EAAE,iBAAiB,CAAC;IACvC,gDAAgD;IAChD,QAAQ,CAAC,cAAc,EAAE,wBAAwB,CAAC;IAClD,+DAA+D;IAC/D,QAAQ,CAAC,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzC,oEAAoE;IACpE,QAAQ,CAAC,iBAAiB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3C;;;;OAIG;IACH,QAAQ,CAAC,oBAAoB,CAAC,EAAE,CAAC,KAAK,EAAE,mBAAmB,KAAK,SAAS,CAAC;IAC1E,oEAAoE;IACpE,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC;IAC3B,yEAAyE;IACzE,QAAQ,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC;IAC1B,kDAAkD;IAClD,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,IAAI,CAAC;IACjC,oDAAoD;IACpD,QAAQ,CAAC,YAAY,CAAC,EAAE,CAAC,GAAG,EAAE,YAAY,KAAK,IAAI,CAAC;IACpD;;;;;OAKG;IACH,QAAQ,CAAC,GAAG,CAAC,EAAE,IAAI,CAAC;CACrB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,wBAAgB,gBAAgB,CAAC,EAC/B,SAAgB,EAChB,UAAU,EACV,cAAc,EACd,eAAsB,EACtB,iBAAwB,EACxB,oBAAoB,EACpB,MAAM,EACN,MAAa,EACb,UAAU,EACV,YAAY,EACZ,GAAG,GACJ,EAAE,qBAAqB,2CAqEvB"}
@@ -0,0 +1,95 @@
1
+ "use client";
2
+ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
3
+ import { memo, useMemo } from "react";
4
+ import { Plus, LayoutDashboard, Library, MessageSquare, Workflow, } from "lucide-react";
5
+ import { groupRecentActivityByTime } from "../activity/group-activity.js";
6
+ import { formatRelativeTime } from "../activity/format-relative-time.js";
7
+ import { recentActivityStatusBadge } from "../activity/entry-status-badge.js";
8
+ import { ScrollArea } from "../internal/scroll-area.js";
9
+ import { Tooltip, TooltipProvider, TooltipTrigger, TooltipContent, } from "../internal/tooltip.js";
10
+ import { SidebarChrome, SidebarSeparator, navRowClassName } from "./chrome.js";
11
+ /**
12
+ * The console's workspace-zone sidebar: org switcher, primary navigation
13
+ * (New Session / Dashboard / Library), time-bucketed recent activity,
14
+ * and a user footer.
15
+ *
16
+ * This is the same component the Stigmer web console and desktop app
17
+ * render — hosts differ only in what they return from `renderLink`
18
+ * (their router's link), what they pass as `recentActivity` (live hook
19
+ * data or frozen fixtures), and the `footer` slot. Documentation tours
20
+ * render it too, which is the point: the depicted chrome cannot drift
21
+ * from the product because it *is* the product (stigmer/stigmer#317).
22
+ *
23
+ * Layout note: the sidebar fills its container's height and defines no
24
+ * width — the console's app shell owns the `w-70` (280px) column.
25
+ *
26
+ * @example
27
+ * ```tsx
28
+ * <WorkspaceSidebar
29
+ * activeNav="library"
30
+ * renderLink={({ href, children, ...rest }) => (
31
+ * <Link href={href} {...rest}>{children}</Link>
32
+ * )}
33
+ * recentActivity={useRecentActivity()}
34
+ * footer={<UserMenu />}
35
+ * />
36
+ * ```
37
+ */
38
+ export function WorkspaceSidebar({ activeNav = null, renderLink, recentActivity, activeSessionId = null, activeExecutionId = null, renderEntryAccessory, footer, isOpen = true, onCollapse, onOrgChanged, now, }) {
39
+ const { entries, isLoading = false, error = null } = recentActivity;
40
+ const groups = useMemo(() => groupRecentActivityByTime(entries, now), [entries, now]);
41
+ return (_jsxs(SidebarChrome, { ariaLabel: "Main navigation", isOpen: isOpen, onCollapse: onCollapse, onOrgChanged: onOrgChanged, footer: footer, children: [_jsx(PrimaryNavRow, { id: "new-session", href: "/", label: "New Session", icon: Plus, active: activeNav === "new-session", renderLink: renderLink }), _jsx(PrimaryNavRow, { id: "dashboard", href: "/dashboard", label: "Dashboard", icon: LayoutDashboard, active: activeNav === "dashboard", renderLink: renderLink }), _jsx(PrimaryNavRow, { id: "library", href: "/library", label: "Library", icon: Library, active: activeNav === "library", renderLink: renderLink }), _jsx(SidebarSeparator, {}), _jsx(ScrollArea, { className: "flex-1", children: _jsxs("div", { className: "p-3", children: [_jsx("p", { className: "text-sidebar-muted-foreground mb-2 px-1 text-[11px] font-semibold tracking-wider uppercase", children: "Recents" }), isLoading ? (_jsx(RecentsSkeletons, {})) : error ? (_jsx(RecentsError, { message: error.message })) : groups.length === 0 ? (_jsx(RecentsEmptyState, {})) : (_jsx(ActivityGroupList, { groups: groups, activeSessionId: activeSessionId, activeExecutionId: activeExecutionId, renderLink: renderLink, renderEntryAccessory: renderEntryAccessory, now: now }))] }) })] }));
42
+ }
43
+ // ---------------------------------------------------------------------------
44
+ // Internals
45
+ // ---------------------------------------------------------------------------
46
+ function PrimaryNavRow({ id, href, label, icon: Icon, active, renderLink, }) {
47
+ return (_jsx("div", { className: "flex-none px-3 py-1", children: renderLink({
48
+ id,
49
+ href,
50
+ active,
51
+ className: navRowClassName(active),
52
+ "aria-current": active ? "page" : undefined,
53
+ children: (_jsxs(_Fragment, { children: [_jsx(Icon, { className: "size-4 shrink-0" }), label] })),
54
+ }) }));
55
+ }
56
+ function ActivityGroupList({ groups, activeSessionId, activeExecutionId, renderLink, renderEntryAccessory, now, }) {
57
+ return (_jsx(TooltipProvider, { children: _jsx("div", { className: "space-y-4", children: groups.map((group) => (_jsxs("div", { children: [_jsx("p", { className: "text-sidebar-muted-foreground mb-1 px-2 text-[10px] font-medium tracking-wider uppercase", children: group.label }), _jsx("ul", { className: "space-y-0.5", role: "list", children: group.entries.map((entry) => (_jsx(ActivityEntry, { entry: entry, activeSessionId: activeSessionId, activeExecutionId: activeExecutionId, renderLink: renderLink, renderEntryAccessory: renderEntryAccessory, now: now }, entry.id))) })] }, group.label))) }) }));
58
+ }
59
+ const ActivityEntry = memo(function ActivityEntry({ entry, activeSessionId, activeExecutionId, renderLink, renderEntryAccessory, now, }) {
60
+ const isSession = entry.type === "session";
61
+ const isActive = isSession
62
+ ? entry.id === activeSessionId
63
+ : entry.id === activeExecutionId;
64
+ const href = isSession ? `/sessions/${entry.id}` : `/executions/${entry.id}`;
65
+ const TypeIcon = isSession ? MessageSquare : Workflow;
66
+ const statusBadge = recentActivityStatusBadge(entry);
67
+ const row = renderLink({
68
+ id: entry.id,
69
+ href,
70
+ active: isActive,
71
+ "aria-current": isActive ? "page" : undefined,
72
+ entry,
73
+ className: cnActivityRow(isActive),
74
+ children: (_jsxs(_Fragment, { children: [_jsx(TypeIcon, { className: "mt-0.5 size-3 shrink-0 opacity-50", "aria-hidden": "true" }), _jsx("span", { className: "line-clamp-2 flex-1", children: entry.subject }), _jsxs("span", { className: "flex shrink-0 flex-col items-end gap-0.5 text-[10px] leading-tight", children: [_jsx("span", { className: "text-sidebar-muted-foreground tabular-nums", children: formatRelativeTime(entry.updatedAt, now) }), statusBadge && (_jsx("span", { className: statusBadge.tone === "destructive"
75
+ ? "text-destructive"
76
+ : "text-sidebar-muted-foreground", children: statusBadge.label }))] }), renderEntryAccessory?.(entry)] })),
77
+ });
78
+ return (_jsx("li", { children: _jsxs(Tooltip, { children: [_jsx(TooltipTrigger, { render: row }), _jsx(TooltipContent, { side: "right", sideOffset: 12, children: entry.subject })] }) }));
79
+ });
80
+ /** Recents rows are denser than primary nav: 12px text, top-aligned icon. */
81
+ function cnActivityRow(active) {
82
+ return active
83
+ ? "flex items-start gap-2 rounded-lg px-2 py-1.5 text-xs transition-colors bg-sidebar-accent text-sidebar-accent-foreground font-medium"
84
+ : "flex items-start gap-2 rounded-lg px-2 py-1.5 text-xs transition-colors text-sidebar-foreground hover:bg-sidebar-accent hover:text-sidebar-accent-foreground";
85
+ }
86
+ function RecentsSkeletons() {
87
+ return (_jsx("div", { className: "space-y-2 px-2", "aria-busy": "true", "aria-label": "Loading sessions", children: Array.from({ length: 5 }, (_, i) => (_jsx("div", { className: "bg-sidebar-muted h-5 animate-pulse rounded", style: { width: `${70 + Math.sin(i * 1.5) * 20}%` } }, i))) }));
88
+ }
89
+ function RecentsError({ message }) {
90
+ return (_jsxs(_Fragment, { children: [_jsx("p", { className: "text-destructive mb-4 px-2 text-xs", role: "alert", children: message }), _jsx(RecentsEmptyState, {})] }));
91
+ }
92
+ function RecentsEmptyState() {
93
+ return (_jsxs("div", { className: "flex flex-col items-center gap-2 py-8 text-center", children: [_jsx(MessageSquare, { className: "text-sidebar-muted-foreground size-8" }), _jsx("p", { className: "text-sidebar-muted-foreground text-xs", children: "No recent activity" })] }));
94
+ }
95
+ //# sourceMappingURL=WorkspaceSidebar.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WorkspaceSidebar.js","sourceRoot":"","sources":["../../src/sidebar/WorkspaceSidebar.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb,OAAO,EAAE,IAAI,EAAE,OAAO,EAAkB,MAAM,OAAO,CAAC;AACtD,OAAO,EACL,IAAI,EACJ,eAAe,EACf,OAAO,EACP,aAAa,EACb,QAAQ,GAET,MAAM,cAAc,CAAC;AAGtB,OAAO,EAAE,yBAAyB,EAAE,MAAM,+BAA+B,CAAC;AAC1E,OAAO,EAAE,kBAAkB,EAAE,MAAM,qCAAqC,CAAC;AACzE,OAAO,EAAE,yBAAyB,EAAE,MAAM,mCAAmC,CAAC;AAC9E,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AACxD,OAAO,EACL,OAAO,EACP,eAAe,EACf,cAAc,EACd,cAAc,GACf,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,aAAa,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AA8D/E;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,MAAM,UAAU,gBAAgB,CAAC,EAC/B,SAAS,GAAG,IAAI,EAChB,UAAU,EACV,cAAc,EACd,eAAe,GAAG,IAAI,EACtB,iBAAiB,GAAG,IAAI,EACxB,oBAAoB,EACpB,MAAM,EACN,MAAM,GAAG,IAAI,EACb,UAAU,EACV,YAAY,EACZ,GAAG,GACmB;IACtB,MAAM,EAAE,OAAO,EAAE,SAAS,GAAG,KAAK,EAAE,KAAK,GAAG,IAAI,EAAE,GAAG,cAAc,CAAC;IAEpE,MAAM,MAAM,GAAG,OAAO,CACpB,GAAG,EAAE,CAAC,yBAAyB,CAAC,OAAO,EAAE,GAAG,CAAC,EAC7C,CAAC,OAAO,EAAE,GAAG,CA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EAAC,mDAAmD,aAChE,KAAC,aAAa,IAAC,SAAS,EAAC,sCAAsC,GAAG,EAClE,YAAG,SAAS,EAAC,uCAAuC,mCAAuB,IACvE,CACP,CAAC;AACJ,CAAC"}
@@ -0,0 +1,48 @@
1
+ import type { ReactNode } from "react";
2
+ import type { Organization } from "@stigmer/protos/ai/stigmer/tenancy/organization/v1/api_pb";
3
+ /** Props shared by both sidebar variants' outer chrome. */
4
+ export interface SidebarChromeProps {
5
+ /** Accessible name for the `<nav>` landmark. */
6
+ readonly ariaLabel: string;
7
+ /**
8
+ * Whether the sidebar is currently expanded, reflected as
9
+ * `aria-expanded` on the collapse toggle. @default true
10
+ */
11
+ readonly isOpen?: boolean;
12
+ /**
13
+ * Called when the collapse toggle is pressed. The sidebar renders the
14
+ * toggle either way (it is part of the depicted chrome); hosts that
15
+ * cannot collapse (fixed embeds) simply omit the handler.
16
+ */
17
+ readonly onCollapse?: () => void;
18
+ /** Passed through to {@link OrgSwitcher}. */
19
+ readonly onOrgChanged?: (org: Organization) => void;
20
+ /**
21
+ * Footer content — typically the host app's `UserMenu` wrapper, which
22
+ * bridges auth, theming, and routing. A slot rather than a built-in
23
+ * because every host wires those systems differently (DD-004).
24
+ */
25
+ readonly footer: ReactNode;
26
+ readonly children: ReactNode;
27
+ }
28
+ /**
29
+ * Outer sidebar frame: `<nav>` container, top row, content, footer band.
30
+ *
31
+ * The `id="sidebar"` / `aria-controls` pairing matches the console's DOM
32
+ * contract (the app shell's floating "Open sidebar" button targets it);
33
+ * only one sidebar renders at a time, so the id cannot collide.
34
+ */
35
+ export declare function SidebarChrome({ ariaLabel, isOpen, onCollapse, onOrgChanged, footer, children, }: SidebarChromeProps): import("react/jsx-runtime").JSX.Element;
36
+ /** Hairline separator between sidebar sections. */
37
+ export declare function SidebarSeparator(): import("react/jsx-runtime").JSX.Element;
38
+ /**
39
+ * The one nav-row class recipe both sidebars share: 14px medium labels,
40
+ * 16px icons (sized by callers), 8px/6px padding, rounded row highlight.
41
+ *
42
+ * `muted` renders the resting label in the muted sidebar tone — used by
43
+ * "Back to Sessions", which is an exit, not a destination.
44
+ */
45
+ export declare function navRowClassName(active: boolean, { muted }?: {
46
+ muted?: boolean;
47
+ }): string;
48
+ //# sourceMappingURL=chrome.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"chrome.d.ts","sourceRoot":"","sources":["../../src/sidebar/chrome.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAGvC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2DAA2D,CAAC;AAc9F,2DAA2D;AAC3D,MAAM,WAAW,kBAAkB;IACjC,gDAAgD;IAChD,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B;;;OAGG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,OAAO,CAAC;IAC1B;;;;OAIG;IACH,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,IAAI,CAAC;IACjC,6CAA6C;IAC7C,QAAQ,CAAC,YAAY,CAAC,EAAE,CAAC,GAAG,EAAE,YAAY,KAAK,IAAI,CAAC;IACpD;;;;OAIG;IACH,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC;IAC3B,QAAQ,CAAC,QAAQ,EAAE,SAAS,CAAC;CAC9B;AAED;;;;;;GAMG;AACH,wBAAgB,aAAa,CAAC,EAC5B,SAAS,EACT,MAAa,EACb,UAAU,EACV,YAAY,EACZ,MAAM,EACN,QAAQ,GACT,EAAE,kBAAkB,2CAsCpB;AAED,mDAAmD;AACnD,wBAAgB,gBAAgB,4CAM/B;AAED;;;;;;GAMG;AACH,wBAAgB,eAAe,CAC7B,MAAM,EAAE,OAAO,EACf,EAAE,KAAa,EAAE,GAAE;IAAE,KAAK,CAAC,EAAE,OAAO,CAAA;CAAO,GAC1C,MAAM,CAUR"}
@@ -0,0 +1,32 @@
1
+ "use client";
2
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
3
+ import { PanelLeft } from "lucide-react";
4
+ import { cn } from "@stigmer/theme";
5
+ import { OrgSwitcher } from "../organization/OrgSwitcher.js";
6
+ /**
7
+ * Outer sidebar frame: `<nav>` container, top row, content, footer band.
8
+ *
9
+ * The `id="sidebar"` / `aria-controls` pairing matches the console's DOM
10
+ * contract (the app shell's floating "Open sidebar" button targets it);
11
+ * only one sidebar renders at a time, so the id cannot collide.
12
+ */
13
+ export function SidebarChrome({ ariaLabel, isOpen = true, onCollapse, onOrgChanged, footer, children, }) {
14
+ return (_jsxs("nav", { id: "sidebar", "aria-label": ariaLabel, className: "bg-sidebar text-sidebar-foreground flex h-full flex-col", children: [_jsxs("div", { className: "flex flex-none items-center gap-1 px-2 py-2", children: [_jsx("button", { type: "button", onClick: onCollapse, "aria-expanded": isOpen, "aria-controls": "sidebar", "aria-label": "Collapse sidebar", className: cn("inline-flex size-7 shrink-0 items-center justify-center rounded-md", "text-sidebar-foreground transition-colors motion-reduce:transition-none", "hover:bg-sidebar-accent hover:text-sidebar-accent-foreground", "aria-expanded:bg-sidebar-accent aria-expanded:text-sidebar-accent-foreground", "focus-visible:ring-sidebar-ring focus-visible:ring-2 focus-visible:outline-none"), children: _jsx(PanelLeft, { className: "size-4" }) }), _jsx("div", { className: "min-w-0 flex-1", children: _jsx(OrgSwitcher, { onOrgChanged: onOrgChanged }) })] }), children, _jsx("div", { className: "border-sidebar-border flex-none border-t px-3 py-2", children: footer })] }));
15
+ }
16
+ /** Hairline separator between sidebar sections. */
17
+ export function SidebarSeparator() {
18
+ return (_jsx("div", { className: "px-3 py-1", children: _jsx("div", { className: "bg-sidebar-border h-px" }) }));
19
+ }
20
+ /**
21
+ * The one nav-row class recipe both sidebars share: 14px medium labels,
22
+ * 16px icons (sized by callers), 8px/6px padding, rounded row highlight.
23
+ *
24
+ * `muted` renders the resting label in the muted sidebar tone — used by
25
+ * "Back to Sessions", which is an exit, not a destination.
26
+ */
27
+ export function navRowClassName(active, { muted = false } = {}) {
28
+ return cn("flex items-center gap-2 rounded-lg px-2 py-1.5 text-sm font-medium transition-colors", active
29
+ ? "bg-sidebar-accent text-sidebar-accent-foreground"
30
+ : cn(muted ? "text-sidebar-muted-foreground" : "text-sidebar-foreground", "hover:bg-sidebar-accent hover:text-sidebar-accent-foreground"));
31
+ }
32
+ //# sourceMappingURL=chrome.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"chrome.js","sourceRoot":"","sources":["../../src/sidebar/chrome.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAGb,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,EAAE,EAAE,MAAM,gBAAgB,CAAC;AAEpC,OAAO,EAAE,WAAW,EAAE,MAAM,gCAAgC,CAAC;AAuC7D;;;;;;GAMG;AACH,MAAM,UAAU,aAAa,CAAC,EAC5B,SAAS,EACT,MAAM,GAAG,IAAI,EACb,UAAU,EACV,YAAY,EACZ,MAAM,EACN,QAAQ,GACW;IACnB,OAAO,CACL,eACE,EAAE,EAAC,SAAS,gBACA,SAAS,EACrB,SAAS,EAAC,yDAAyD,aAGnE,eAAK,SAAS,EAAC,6CAA6C,aAC1D,iBACE,IAAI,EAAC,QAAQ,EACb,OAAO,EAAE,UAAU,mBACJ,MAAM,mBACP,SAAS,gBACZ,kBAAkB,EAC7B,SAAS,EAAE,EAAE,CACX,oEAAoE,EACpE,yEAAyE,EACzE,8DAA8D,EAC9D,8EAA8E,EAC9E,iFAAiF,CAClF,YAED,KAAC,SAAS,IAAC,SAAS,EAAC,QAAQ,GAAG,GACzB,EACT,cAAK,SAAS,EAAC,gBAAgB,YAC7B,KAAC,WAAW,IAAC,YAAY,EAAE,YAAY,GAAI,GACvC,IACF,EAEL,QAAQ,EAGT,cAAK,SAAS,EAAC,oDAAoD,YAChE,MAAM,GACH,IACF,CACP,CAAC;AACJ,CAAC;AAED,mDAAmD;AACnD,MAAM,UAAU,gBAAgB;IAC9B,OAAO,CACL,cAAK,SAAS,EAAC,WAAW,YACxB,cAAK,SAAS,EAAC,wBAAwB,GAAG,GACtC,CACP,CAAC;AACJ,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,eAAe,CAC7B,MAAe,EACf,EAAE,KAAK,GAAG,KAAK,KAA0B,EAAE;IAE3C,OAAO,EAAE,CACP,sFAAsF,EACtF,MAAM;QACJ,CAAC,CAAC,kDAAkD;QACpD,CAAC,CAAC,EAAE,CACA,KAAK,CAAC,CAAC,CAAC,+BAA+B,CAAC,CAAC,CAAC,yBAAyB,EACnE,8DAA8D,CAC/D,CACN,CAAC;AACJ,CAAC"}
@@ -0,0 +1,6 @@
1
+ export { WorkspaceSidebar } from "./WorkspaceSidebar.js";
2
+ export type { WorkspaceSidebarProps, WorkspaceSidebarActivity, WorkspaceNavId, } from "./WorkspaceSidebar.js";
3
+ export { SettingsSidebar } from "./SettingsSidebar.js";
4
+ export type { SettingsSidebarProps } from "./SettingsSidebar.js";
5
+ export type { SidebarLinkRenderProps, RenderSidebarLink } from "./types.js";
6
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/sidebar/index.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AACzD,YAAY,EACV,qBAAqB,EACrB,wBAAwB,EACxB,cAAc,GACf,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AACvD,YAAY,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAC;AACjE,YAAY,EAAE,sBAAsB,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC"}
@@ -0,0 +1,9 @@
1
+ // Sidebar — the console's navigation chrome as shared SDK components.
2
+ //
3
+ // One source of truth for the sidebar the web console, desktop app, and
4
+ // documentation tours all render (stigmer/stigmer#317): hosts inject their
5
+ // router via `renderLink`, their data via props, and their user menu via
6
+ // the `footer` slot.
7
+ export { WorkspaceSidebar } from "./WorkspaceSidebar.js";
8
+ export { SettingsSidebar } from "./SettingsSidebar.js";
9
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/sidebar/index.ts"],"names":[],"mappings":"AAAA,sEAAsE;AACtE,EAAE;AACF,wEAAwE;AACxE,2EAA2E;AAC3E,yEAAyE;AACzE,qBAAqB;AAErB,OAAO,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC;AAMzD,OAAO,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC"}
@@ -0,0 +1,54 @@
1
+ import type { ReactElement, ReactNode } from "react";
2
+ import type { RecentActivityEntry } from "../activity/types.js";
3
+ /**
4
+ * Everything a sidebar hands to {@link RenderSidebarLink} to draw one
5
+ * interactive row.
6
+ *
7
+ * The sidebar owns the row's look (`className`, `children`) and state
8
+ * (`active`, `aria-current`); the consumer owns only the interactive
9
+ * element wrapping them. That split is what keeps one component serving
10
+ * three very different hosts: the web console returns `next/link`, the
11
+ * desktop app returns a `react-router` link, and documentation embeds
12
+ * return inert rows decorated with capture markers.
13
+ */
14
+ export interface SidebarLinkRenderProps {
15
+ /**
16
+ * Stable row identifier, for consumers that vary behavior per row:
17
+ * `"new-session"` / `"dashboard"` / `"library"` in the workspace
18
+ * sidebar, `"back-to-sessions"` or the settings route basename (e.g.
19
+ * `"api-keys"`) in the settings sidebar, and the entry id for recent
20
+ * activity rows.
21
+ */
22
+ readonly id: string;
23
+ /** Console route this row targets (e.g. `/library`, `/sessions/<id>`). */
24
+ readonly href: string;
25
+ /** Whether the row is the current location. */
26
+ readonly active: boolean;
27
+ /**
28
+ * Fully-styled row classes computed by the sidebar. Apply verbatim —
29
+ * the row's geometry and type scale are the product surface tours and
30
+ * embeds depict, so consumers must not restyle them.
31
+ */
32
+ readonly className: string;
33
+ /** `"page"` when active, for assistive tech. Spread onto the element. */
34
+ readonly "aria-current": "page" | undefined;
35
+ /** Row content (icon, label, timestamps). Render inside the element. */
36
+ readonly children: ReactNode;
37
+ /**
38
+ * The recent-activity entry behind this row. Present only for recents
39
+ * rows in the workspace sidebar — consumers use it to pick the right
40
+ * navigation flow (session viewer vs. execution viewer) without
41
+ * parsing `href`.
42
+ */
43
+ readonly entry?: RecentActivityEntry;
44
+ }
45
+ /**
46
+ * Renders one sidebar row as the consumer's interactive element.
47
+ *
48
+ * Must return a single element that spreads unknown props onto its
49
+ * underlying DOM node (all DOM elements, `next/link`, and `react-router`
50
+ * links qualify): the sidebar composes tooltip triggers around recents
51
+ * rows by cloning the returned element with merged event handlers.
52
+ */
53
+ export type RenderSidebarLink = (props: SidebarLinkRenderProps) => ReactElement;
54
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/sidebar/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACrD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;AAEhE;;;;;;;;;;GAUG;AACH,MAAM,WAAW,sBAAsB;IACrC;;;;;;OAMG;IACH,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,0EAA0E;IAC1E,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,+CAA+C;IAC/C,QAAQ,CAAC,MAAM,EAAE,OAAO,CAAC;IACzB;;;;OAIG;IACH,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,yEAAyE;IACzE,QAAQ,CAAC,cAAc,EAAE,MAAM,GAAG,SAAS,CAAC;IAC5C,wEAAwE;IACxE,QAAQ,CAAC,QAAQ,EAAE,SAAS,CAAC;IAC7B;;;;;OAKG;IACH,QAAQ,CAAC,KAAK,CAAC,EAAE,mBAAmB,CAAC;CACtC;AAED;;;;;;;GAOG;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,KAAK,EAAE,sBAAsB,KAAK,YAAY,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/sidebar/types.ts"],"names":[],"mappings":""}
@@ -12,6 +12,8 @@ export interface UseSkillCountOptions {
12
12
  * @default "org"
13
13
  */
14
14
  readonly scope?: ResourceListScope;
15
+ /** Opaque token that forces a recount when its value changes. */
16
+ readonly refetchToken?: unknown;
15
17
  }
16
18
  /** Return value of {@link useSkillCount}. */
17
19
  export interface UseSkillCountReturn {
@@ -1 +1 @@
1
- {"version":3,"file":"useSkillCount.d.ts","sourceRoot":"","sources":["../../src/skill/useSkillCount.ts"],"names":[],"mappings":"AAIA,OAAO,EAAoB,KAAK,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AAE9E,yCAAyC;AACzC,MAAM,WAAW,oBAAoB;IACnC,mDAAmD;IACnD,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB;;;;;;;OAOG;IACH,QAAQ,CAAC,KAAK,CAAC,EAAE,iBAAiB,CAAC;CACpC;AAED,6CAA6C;AAC7C,MAAM,WAAW,mBAAmB;IAClC;;;OAGG;IACH,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,CAAC;IACnC,iDAAiD;IACjD,QAAQ,CAAC,SAAS,EAAE,OAAO,CAAC;IAC5B,0EAA0E;IAC1E,QAAQ,CAAC,KAAK,EAAE,KAAK,GAAG,IAAI,CAAC;IAC7B,kEAAkE;IAClE,QAAQ,CAAC,OAAO,EAAE,MAAM,IAAI,CAAC;CAC9B;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,aAAa,CAC3B,GAAG,EAAE,MAAM,GAAG,IAAI,EAClB,OAAO,CAAC,EAAE,oBAAoB,GAC7B,mBAAmB,CAUrB"}
1
+ {"version":3,"file":"useSkillCount.d.ts","sourceRoot":"","sources":["../../src/skill/useSkillCount.ts"],"names":[],"mappings":"AAIA,OAAO,EAAoB,KAAK,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AAE9E,yCAAyC;AACzC,MAAM,WAAW,oBAAoB;IACnC,mDAAmD;IACnD,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IACxB;;;;;;;OAOG;IACH,QAAQ,CAAC,KAAK,CAAC,EAAE,iBAAiB,CAAC;IACnC,iEAAiE;IACjE,QAAQ,CAAC,YAAY,CAAC,EAAE,OAAO,CAAC;CACjC;AAED,6CAA6C;AAC7C,MAAM,WAAW,mBAAmB;IAClC;;;OAGG;IACH,QAAQ,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,CAAC;IACnC,iDAAiD;IACjD,QAAQ,CAAC,SAAS,EAAE,OAAO,CAAC;IAC5B,0EAA0E;IAC1E,QAAQ,CAAC,KAAK,EAAE,KAAK,GAAG,IAAI,CAAC;IAC7B,kEAAkE;IAClE,QAAQ,CAAC,OAAO,EAAE,MAAM,IAAI,CAAC;CAC9B;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,aAAa,CAC3B,GAAG,EAAE,MAAM,GAAG,IAAI,EAClB,OAAO,CAAC,EAAE,oBAAoB,GAC7B,mBAAmB,CAUrB"}
@@ -1 +1 @@
1
- {"version":3,"file":"useSkillCount.js","sourceRoot":"","sources":["../../src/skill/useSkillCount.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;AAEb,OAAO,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AACpC,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAE,gBAAgB,EAA0B,MAAM,oBAAoB,CAAC;AAgC9E;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAM,UAAU,aAAa,CAC3B,GAAkB,EAClB,OAA8B;IAE9B,MAAM,OAAO,GAAG,UAAU,EAAE,CAAC;IAE7B,MAAM,MAAM,GAAG,WAAW,CACxB,CAAC,MAAgD,EAAE,EAAE,CACnD,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,EAC5B,CAAC,OAAO,CAAC,CACV,CAAC;IAEF,OAAO,gBAAgB,CAAC,MAAM,EAAE,GAAG,EAAE,OAAO,CAAC,CAAC;AAChD,CAAC"}
1
+ {"version":3,"file":"useSkillCount.js","sourceRoot":"","sources":["../../src/skill/useSkillCount.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;AAEb,OAAO,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AACpC,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAE,gBAAgB,EAA0B,MAAM,oBAAoB,CAAC;AAkC9E;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAM,UAAU,aAAa,CAC3B,GAAkB,EAClB,OAA8B;IAE9B,MAAM,OAAO,GAAG,UAAU,EAAE,CAAC;IAE7B,MAAM,MAAM,GAAG,WAAW,CACxB,CAAC,MAAgD,EAAE,EAAE,CACnD,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,EAC5B,CAAC,OAAO,CAAC,CACV,CAAC;IAEF,OAAO,gBAAgB,CAAC,MAAM,EAAE,GAAG,EAAE,OAAO,CAAC,CAAC;AAChD,CAAC"}