studiograph 1.3.48-next.7 → 1.3.48-next.8

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 (42) hide show
  1. package/dist/agent/orchestrator.d.ts +0 -15
  2. package/dist/agent/orchestrator.js +0 -36
  3. package/dist/agent/orchestrator.js.map +1 -1
  4. package/dist/server/routes/chat.js +0 -15
  5. package/dist/server/routes/chat.js.map +1 -1
  6. package/dist/web/_app/immutable/assets/{2.DmRPkMc6.css → 2.o5gSwzab.css} +1 -1
  7. package/dist/web/_app/immutable/chunks/{D2r_hvjo.js → B8hOuFij.js} +1 -1
  8. package/dist/web/_app/immutable/chunks/{DBSXodjU.js → Bfo6RqaU.js} +1 -1
  9. package/dist/web/_app/immutable/chunks/BhITy8Ob.js +1 -0
  10. package/dist/web/_app/immutable/chunks/{Dorm8yxd.js → C0sydYgk.js} +1 -1
  11. package/dist/web/_app/immutable/chunks/{DwUxJIAB.js → CLqUMZPz.js} +1 -1
  12. package/dist/web/_app/immutable/chunks/{ClycA1eF.js → CQkYg8-S.js} +1 -1
  13. package/dist/web/_app/immutable/chunks/{BkamqjcK.js → CphCg7fT.js} +1 -1
  14. package/dist/web/_app/immutable/chunks/{CcIrHMQa.js → D6Nem_cG.js} +1 -1
  15. package/dist/web/_app/immutable/chunks/{aUD7w84P.js → DD2tihyk.js} +1 -1
  16. package/dist/web/_app/immutable/chunks/{C_VTHosK.js → DXkIVPyE.js} +1 -1
  17. package/dist/web/_app/immutable/chunks/{eRwSnfMR.js → DgdEvonR.js} +5 -5
  18. package/dist/web/_app/immutable/chunks/DnwCyrLk.js +1 -0
  19. package/dist/web/_app/immutable/chunks/{CgAQQk9h.js → TD9yh6MS.js} +1 -1
  20. package/dist/web/_app/immutable/chunks/ViFs0DQu.js +1 -0
  21. package/dist/web/_app/immutable/entry/{app.T0VdLhy6.js → app.Du6g7Mr2.js} +2 -2
  22. package/dist/web/_app/immutable/entry/start.TPt2P_nk.js +1 -0
  23. package/dist/web/_app/immutable/nodes/{0.Dd51fsl8.js → 0.DV8AwAKh.js} +2 -2
  24. package/dist/web/_app/immutable/nodes/{1.CtmuxWSC.js → 1.CN-rwte7.js} +1 -1
  25. package/dist/web/_app/immutable/nodes/{10.Bcf_kG65.js → 10.Ddsi2sfy.js} +1 -1
  26. package/dist/web/_app/immutable/nodes/2.D8h1KFna.js +301 -0
  27. package/dist/web/_app/immutable/nodes/{3.C7HTnX4o.js → 3.CsU37T7i.js} +1 -1
  28. package/dist/web/_app/immutable/nodes/{4.yTFNBCtd.js → 4.D__Fcytd.js} +4 -4
  29. package/dist/web/_app/immutable/nodes/{5.D79xZoLD.js → 5.2KakKOP0.js} +1 -1
  30. package/dist/web/_app/immutable/nodes/{6.C3Timz00.js → 6.LOCHateX.js} +1 -1
  31. package/dist/web/_app/immutable/nodes/{7.boN94cNC.js → 7.CkBvkHa0.js} +1 -1
  32. package/dist/web/_app/immutable/nodes/8.C_OINojh.js +1 -0
  33. package/dist/web/_app/immutable/nodes/{9.4amnhfWL.js → 9.x7pkEaJB.js} +1 -1
  34. package/dist/web/_app/version.json +1 -1
  35. package/dist/web/index.html +6 -6
  36. package/package.json +1 -1
  37. package/dist/web/_app/immutable/chunks/BuErvqAd.js +0 -1
  38. package/dist/web/_app/immutable/chunks/D213c0G8.js +0 -1
  39. package/dist/web/_app/immutable/chunks/TyzEVmmX.js +0 -1
  40. package/dist/web/_app/immutable/entry/start.BTQQ66DM.js +0 -1
  41. package/dist/web/_app/immutable/nodes/2.Cs8CpStw.js +0 -301
  42. package/dist/web/_app/immutable/nodes/8.B9Bdfd6O.js +0 -1
@@ -10,7 +10,6 @@ import { WorkspaceConfig } from '../core/types.js';
10
10
  import { GitUser } from '../services/git.js';
11
11
  import { type MutationEvent } from './tools/graph-tools.js';
12
12
  import type { AuthUser } from '../services/auth-service.js';
13
- import { type AgentRole } from './role-loader.js';
14
13
  export interface AgentConfig {
15
14
  workspacePath: string;
16
15
  workspaceConfig: WorkspaceConfig;
@@ -46,8 +45,6 @@ export declare class AgentOrchestrator {
46
45
  private _currentUser;
47
46
  private authService;
48
47
  private recentMemory?;
49
- private roles;
50
- private activeRole;
51
48
  private currentSessionId;
52
49
  private sessionsDir;
53
50
  constructor(config: AgentConfig);
@@ -101,18 +98,6 @@ export declare class AgentOrchestrator {
101
98
  * Set a callback for highlight_entities tool events (used by SSE streaming).
102
99
  */
103
100
  setHighlightCallback(cb: ((ids: string[]) => void) | null): void;
104
- /**
105
- * Get available roles.
106
- */
107
- getRoles(): AgentRole[];
108
- /**
109
- * Get the currently active role name.
110
- */
111
- getActiveRole(): string;
112
- /**
113
- * Switch the agent to a different role. Rebuilds the system prompt.
114
- */
115
- switchRole(roleName: string): void;
116
101
  /**
117
102
  * Emit a highlight event (called by graph-tools highlight_entities).
118
103
  */
@@ -26,7 +26,6 @@ import { createOpsTools } from './tools/ops-tools.js';
26
26
  import { createPermissionTools } from './tools/permission-tools.js';
27
27
  import { AuthService } from '../services/auth-service.js';
28
28
  import { loadUserConfig, resolveApiKey, resolveProvider, resolveModelId } from '../core/user-config.js';
29
- import { loadRoles } from './role-loader.js';
30
29
  export class AgentOrchestrator {
31
30
  workspacePath;
32
31
  workspaceManager;
@@ -41,8 +40,6 @@ export class AgentOrchestrator {
41
40
  _currentUser = null;
42
41
  authService;
43
42
  recentMemory;
44
- roles = [];
45
- activeRole = 'general';
46
43
  currentSessionId = null;
47
44
  sessionsDir;
48
45
  constructor(config) {
@@ -63,9 +60,6 @@ export class AgentOrchestrator {
63
60
  this.toolsDirs = [userToolsDir, workspaceToolsDir, ...(config.toolsDirs ?? [])];
64
61
  // Use shared workspace manager if provided, otherwise create one
65
62
  this.workspaceManager = config.workspaceManager ?? new WorkspaceManager(this.workspacePath, this.config, this.gitUser);
66
- // Load role definitions
67
- const bundledRolesDir = join(__dirname, 'roles');
68
- this.roles = loadRoles(bundledRolesDir);
69
63
  // Initialize Pi-Mono agent (async tools loaded in createAgent)
70
64
  this.agent = this.createAgent();
71
65
  }
@@ -196,11 +190,6 @@ export class AgentOrchestrator {
196
190
  if (eagerContent) {
197
191
  parts.push(eagerContent);
198
192
  }
199
- // Inject active role prompt
200
- const role = this.roles.find(r => r.name === this.activeRole);
201
- if (role && role.prompt) {
202
- parts.push(`## Active Role: ${role.label}\n\n${role.prompt}`);
203
- }
204
193
  // Append skill index for on-demand skills
205
194
  const index = buildSkillIndexPrompt(skillIndex);
206
195
  if (index) {
@@ -305,31 +294,6 @@ ${repoList}`;
305
294
  setHighlightCallback(cb) {
306
295
  this._highlightCallback = cb;
307
296
  }
308
- /**
309
- * Get available roles.
310
- */
311
- getRoles() {
312
- return this.roles;
313
- }
314
- /**
315
- * Get the currently active role name.
316
- */
317
- getActiveRole() {
318
- return this.activeRole;
319
- }
320
- /**
321
- * Switch the agent to a different role. Rebuilds the system prompt.
322
- */
323
- switchRole(roleName) {
324
- const role = this.roles.find(r => r.name === roleName);
325
- if (!role)
326
- return;
327
- this.activeRole = roleName;
328
- // Rebuild system prompt with new role
329
- const skillIndex = loadSkillIndex(this.skillsDirs);
330
- const systemPrompt = this.buildSystemPrompt(skillIndex, [], this.recentMemory);
331
- this.agent.setSystemPrompt(systemPrompt);
332
- }
333
297
  /**
334
298
  * Emit a highlight event (called by graph-tools highlight_entities).
335
299
  */
@@ -1 +1 @@
1
- {"version":3,"file":"orchestrator.js","sourceRoot":"","sources":["../../src/agent/orchestrator.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,WAAW,EAAE,aAAa,EAAE,SAAS,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,IAAI,CAAC;AAC3G,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AACrC,OAAO,EAAE,OAAO,EAAE,MAAM,IAAI,CAAC;AAC7B,OAAO,EAAE,aAAa,EAAE,MAAM,KAAK,CAAC;AAEpC,MAAM,UAAU,GAAG,aAAa,C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AC;IACH,CAAC;CACF"}
@@ -7,21 +7,6 @@
7
7
  * Single agent instance per server process (single-user v1).
8
8
  */
9
9
  export async function registerChatRoutes(fastify, agent, memoryService) {
10
- // GET /api/chat/roles — list available agent roles
11
- fastify.get('/api/chat/roles', async (_req, reply) => {
12
- return reply.send({
13
- roles: agent.getRoles(),
14
- activeRole: agent.getActiveRole(),
15
- });
16
- });
17
- // POST /api/chat/roles — switch active role
18
- fastify.post('/api/chat/roles', async (req, reply) => {
19
- const { role } = req.body ?? {};
20
- if (!role)
21
- return reply.status(400).send({ error: 'role is required' });
22
- agent.switchRole(role);
23
- return reply.send({ ok: true, activeRole: agent.getActiveRole() });
24
- });
25
10
  // POST /api/chat — send message, get full response
26
11
  fastify.post('/api/chat', async (req, reply) => {
27
12
  const { message } = req.body;
@@ -1 +1 @@
1
- {"version":3,"file":"chat.js","sourceRoot":"","sources":["../../../src/server/routes/chat.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAaH,MAAM,CAAC,KAAK,UAAU,kBAAkB,CACtC,OAAwB,EACxB,KAAwB,EACxB,aAA6B;IAE7B,mDAAmD;IACnD,OAAO,CAAC,GAAG,CAAC,iBAAiB,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,EAAE;QACnD,OAAO,KAAK,CAAC,IAAI,CAAC;YAChB,KAAK,EAAE,KAAK,CAAC,QAAQ,EAAE;YACvB,UAAU,EAAE,KAAK,CAAC,aAAa,EAAE;SAClC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;IAEH,4CAA4C;IAC5C,OAAO,CAAC,IAAI,CACV,iBAAiB,EACjB,KAAK,EAAE,GAAG,EAAE,KAAK,EAAE,EAAE;QACnB,MAAM,EAAE,IAAI,EAAE,GAAG,GAAG,CAAC,IAAI,IAAI,EAAE,CAAC;QAChC,IAAI,CAAC,IAAI;YAAE,OAAO,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,kBAA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px}.resize-handle.svelte-tfh9g9:hover,.resize-handle.active.svelte-tfh9g9{background:var(--color-accent);opacity:.3}.resize-handle.active.svelte-tfh9g9{opacity:.5}.radio-item{position:relative;display:flex;align-items:center;justify-content:center;width:16px;height:16px;border-radius:50%;border:1.5px solid var(--color-text-tertiary);background:none;outline:none;flex-shrink:0;cursor:pointer}.radio-item[data-state=checked]{border-color:var(--color-accent)}.radio-item:focus-visible{box-shadow:0 0 0 2px var(--color-accent)}.radio-dot.svelte-l8hbh2{width:8px;height:8px;border-radius:50%;background:var(--color-accent)}.entity-body{padding:16px 24px 24px;display:flex;flex-direction:column;gap:20px;overflow-x:hidden}.type-section.svelte-ak7t5k{display:flex;flex-direction:column;gap:8px}.type-section-label.svelte-ak7t5k{font-size:11px;font-weight:600;text-transform:uppercase;letter-spacing:.05em;color:var(--color-text-tertiary)}.type-grid.svelte-ak7t5k{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.type-grid.svelte-ak7t5k .type-card{display:flex;flex-direction:column;align-items:flex-start;gap:10px;padding:12px;height:auto;border-radius:8px;text-align:left;color:var(--color-text-secondary);justify-content:flex-start}.type-grid.svelte-ak7t5k .type-card:hover{background:var(--color-bg-hover);border-color:var(--color-border-strong)}.type-grid.svelte-ak7t5k .type-card:hover .type-name{color:var(--color-text-primary)}.type-dot.svelte-ak7t5k{width:8px;height:8px;border-radius:50%}.type-info.svelte-ak7t5k{display:flex;flex-direction:column;gap:2px}.type-name.svelte-ak7t5k{font-size:14px;font-weight:500;color:var(--color-text-secondary)}.type-desc.svelte-ak7t5k{font-size:12px;color:var(--color-text-tertiary);line-height:1.3}.sidebar.svelte-6dohdz{position:relative;flex-shrink:0;display:flex;flex-direction:column;overflow:hidden;background:var(--color-bg);border-right:1px solid var(--color-border);transition:width .15s ease}.sidebar.collapsed.svelte-6dohdz{overflow:visible}.rail.svelte-6dohdz{display:flex;flex-direction:column;align-items:center;padding:8px 0;gap:4px;height:100%}.rail-spacer.svelte-6dohdz{flex:1}.rail-btn{width:36px!important;height:36px!important;display:flex!important;align-items:center;justify-content:center;border-radius:8px}.rail-btn:hover{background:var(--color-bg-hover)!important}.rail.svelte-6dohdz .workspace-icon:where(.svelte-6dohdz){width:28px;height:28px;font-size:14px}.sidebar-header.svelte-6dohdz{height:var(--row-height);display:flex;align-items:center;gap:11px;padding:0 12px 0 19px;border-bottom:1px solid var(--color-border);flex-shrink:0}.header-actions.svelte-6dohdz{margin-left:auto;display:flex;align-items:center}.sidebar-header.svelte-6dohdz .home-btn{display:inline-flex;align-items:center;gap:11px;padding:0;min-width:0;text-align:left;border-radius:0;height:auto;background:transparent!important}.sidebar-header.svelte-6dohdz .home-btn:hover .workspace-icon{opacity:.8}.sidebar-header.svelte-6dohdz .home-btn:hover .workspace-name{color:var(--color-text-secondary)}.workspace-icon.svelte-6dohdz{width:22px;height:22px;border-radius:50%;background:var(--color-accent, #e05050);color:#fff;display:flex;align-items:center;justify-content:center;font-weight:600;font-size:11px;flex-shrink:0}.workspace-name.svelte-6dohdz{flex:1;font-size:14px;font-weight:600;color:var(--color-text-primary)}.settings-nav.svelte-6dohdz{display:flex;flex-direction:column;flex:1;padding-top:0}.settings-nav.svelte-6dohdz button[data-slot=tabs-trigger]{display:flex;align-items:center;width:100%;height:var(--row-height);padding:0 12px 0 19px;gap:11px;border:none;background:transparent;cursor:pointer;font-family:inherit;font-size:14px;color:var(--color-text-secondary);transition:color .15s,background .15s}.settings-nav.svelte-6dohdz button[data-slot=tabs-trigger]:hover{background:var(--color-bg-hover);color:var(--color-text-primary)}.settings-nav.svelte-6dohdz button[data-slot=tabs-trigger][data-state=active]{background:var(--color-bg-hover);color:var(--color-text-primary);font-weight:500}.settings-nav.svelte-6dohdz button[data-slot=tabs-trigger] svg{width:14px;height:14px;flex-shrink:0;box-sizing:content-box;padding:0 4px}.filter-bar.svelte-6dohdz{position:relative;display:flex;align-items:center;height:var(--row-height);padding:0 12px 0 52px;border-bottom:1px solid var(--color-border);flex-shrink:0}.filter-icon.svelte-6dohdz{position:absolute;left:22px;top:50%;transform:translateY(-50%);display:flex;align-items:center;justify-content:center;width:16px;color:var(--color-text-tertiary)}.filter-bar.svelte-6dohdz .filter-input{flex:1;background:transparent;border:none;outline:none;padding:0;margin:0;font-size:14px;line-height:1.4;height:auto;border-radius:0}.filter-bar.svelte-6dohdz .filter-clear{width:20px;height:20px;flex-shrink:0}.filter-bar.svelte-6dohdz .sort-toggle{width:28px;height:28px;flex-shrink:0;margin-left:4px}.filter-bar.svelte-6dohdz .sort-toggle.active{color:var(--color-accent, #e05050)}.repo-type-icon.svelte-6dohdz{display:inline-flex;align-items:center;color:var(--color-text-tertiary);margin-right:6px;flex-shrink:0;align-self:center}.tree.svelte-6dohdz{flex:1;overflow-y:auto;padding-top:0}.tree-group.svelte-6dohdz{display:flex;flex-direction:column}.tree-group.svelte-6dohdz+.tree-group:where(.svelte-6dohdz){margin-top:0}.repo-row{display:flex;align-items:baseline;height:var(--row-height);line-height:var(--row-height);width:100%;padding:0 12px 0 20px;border:none;background:transparent;font-family:inherit;text-align:left;border-left:2px solid transparent;border-radius:0;gap:0;justify-content:flex-start}.repo-row:hover,.repo-row.focused{background:var(--color-bg-hover)}.repo-row.repo-active{border-left-color:var(--active-color)}.repo-name.svelte-6dohdz{font-size:14px;color:var(--color-text-secondary)}.repo-row.repo-active .repo-name.svelte-6dohdz,.repo-row.repo-active .repo-type-icon.svelte-6dohdz{font-weight:600;color:var(--color-text-primary)}.tree-row{position:relative;display:flex;align-items:baseline;height:var(--row-height);line-height:var(--row-height);padding-right:40px;color:var(--color-text-secondary);font-size:14px;border:none;background:transparent;font-family:inherit;text-align:left;width:100%;border-left:2px solid transparent;border-radius:0;gap:0;justify-content:flex-start}.tree-row:hover,.tree-row.focused{background:var(--color-bg-hover)}.tree-row.selected{background:var(--color-bg-selected);border-left-color:var(--active-color);color:var(--color-text-primary);font-weight:600}.row-chevron.svelte-6dohdz{display:inline-flex;align-items:center;justify-content:center;align-self:center;width:16px;height:16px;flex-shrink:0;margin-right:14px;color:var(--color-text-tertiary);transition:transform .15s}.row-chevron.open.svelte-6dohdz{transform:rotate(90deg)}.row-label.svelte-6dohdz{flex:1;overflow:hidden;white-space:nowrap;mask-image:linear-gradient(to right,black calc(100% - 16px),transparent 100%);-webkit-mask-image:linear-gradient(to right,black calc(100% - 16px),transparent 100%)}.item-count.svelte-6dohdz{font-size:12px;font-weight:400;color:var(--color-text-tertiary);margin-left:8px;flex-shrink:0;opacity:0;transition:opacity .15s}.tree-row:hover .item-count.svelte-6dohdz,.repo-row-wrapper.svelte-6dohdz:hover .item-count:where(.svelte-6dohdz),.repo-row-wrapper.svelte-6dohdz:has(.repo-actions-btn.menu-open) .item-count:where(.svelte-6dohdz),.type-header-wrapper.svelte-6dohdz:hover .item-count:where(.svelte-6dohdz),.type-header-wrapper.svelte-6dohdz:has(.type-actions-btn.menu-open) .item-count:where(.svelte-6dohdz),.entity-row-wrapper.svelte-6dohdz:hover .item-count:where(.svelte-6dohdz),.entity-row-wrapper.svelte-6dohdz:has(.entity-actions-btn.menu-open) .item-count:where(.svelte-6dohdz){opacity:1}.indent-group.svelte-6dohdz{position:relative}.indent-group.svelte-6dohdz:before{content:"";position:absolute;left:var(--guide-left);top:0;bottom:0;width:1px;background:var(--color-border);pointer-events:none}.loading-row.svelte-6dohdz{height:var(--row-height);display:flex;align-items:center;font-size:14px;color:var(--color-text-tertiary)}.type-header-row{color:var(--color-text-secondary);border-left:2px solid transparent}.type-header-row.type-active{color:var(--color-text-primary);font-weight:600}.type-header-row .row-label.svelte-6dohdz{flex:none;mask-image:none;-webkit-mask-image:none}.entity-type-dot.svelte-6dohdz{width:6px;height:6px;border-radius:3px;flex-shrink:0;margin-right:2px}.new-entity-row{color:var(--color-text-tertiary);align-items:center}.new-entity-row:hover{color:var(--color-text-secondary)}.entity-row-wrapper.svelte-6dohdz{position:relative;display:flex;align-items:center}.entity-row-wrapper.svelte-6dohdz .tree-row{flex:1;min-width:0}.entity-row-wrapper.svelte-6dohdz .entity-actions-btn{display:none;width:28px;height:28px;position:absolute;right:12px;flex-shrink:0;padding:0;border:none;background:none;cursor:pointer;color:var(--color-text-tertiary);border-radius:4px;align-items:center;justify-content:center}.entity-row-wrapper.svelte-6dohdz .entity-actions-btn:hover{background:var(--color-bg-hover);color:var(--color-text-primary)}.entity-row-wrapper.svelte-6dohdz:hover .tree-row,.entity-row-wrapper.svelte-6dohdz:has(.entity-actions-btn.menu-open) .tree-row{background:var(--color-bg-hover)}.entity-row-wrapper.svelte-6dohdz:hover .entity-actions-btn,.entity-row-wrapper.svelte-6dohdz .entity-actions-btn.menu-open{display:inline-flex}.entity-type-dot.svelte-6dohdz{width:6px;height:6px;border-radius:50%;flex-shrink:0;margin-right:19px;align-self:center}.recent-time.svelte-6dohdz{font-size:12px;color:var(--color-text-tertiary);position:absolute;right:26px;top:50%;transform:translate(50%,-50%);white-space:nowrap}.entity-row-wrapper.svelte-6dohdz:hover .recent-time:where(.svelte-6dohdz){display:none}.presence-stack.svelte-6dohdz{display:flex;align-items:center;gap:-4px;margin-left:auto;flex-shrink:0;align-self:center}.presence-avatar.svelte-6dohdz{width:18px;height:18px;border-radius:50%;font-size:10px;font-weight:600;color:#fff;background:var(--color-accent);display:flex;align-items:center;justify-content:center;margin-left:-3px;border:1px solid var(--color-bg);box-sizing:border-box;flex-shrink:0;align-self:center}.presence-stack.svelte-6dohdz .presence-avatar:where(.svelte-6dohdz):first-child{margin-left:4px}.repo-row .presence-stack.svelte-6dohdz{margin-right:28px}.presence-avatar.svelte-6dohdz:nth-child(1){z-index:3}.presence-avatar.svelte-6dohdz:nth-child(2){z-index:2}.presence-avatar.svelte-6dohdz:nth-child(3){z-index:1}.filter-match.svelte-6dohdz{background:var(--color-accent, #e05050);color:#fff;border-radius:2px;padding:0}.no-results.svelte-6dohdz{padding:24px 16px;font-size:14px;color:var(--color-text-tertiary);text-align:center}.repo-row .repo-rename-input{flex:1;min-width:0;height:100%;padding:0 6px;margin:0;border:1px solid var(--color-accent, #e05050);border-radius:3px;font-size:14px;font-weight:600}.repo-row-wrapper.svelte-6dohdz{position:relative;display:flex;align-items:center}.repo-row-wrapper.drop-target.svelte-6dohdz{outline:2px solid var(--color-accent, #e05050);outline-offset:-2px;border-radius:6px;background:#e0505014}.import-modal{max-width:480px}.import-modal .dialog-header{flex-direction:column;align-items:flex-start;gap:4px}.import-modal-body.svelte-6dohdz{padding:16px 24px 8px}.import-modal .dialog-footer{border-top:none}.import-file-list.svelte-6dohdz{display:flex;flex-direction:column;max-height:240px;overflow-y:auto}.import-file-row.svelte-6dohdz{display:flex;align-items:center;gap:10px;padding:10px 12px;border-bottom:1px solid var(--color-border)}.import-file-icon.svelte-6dohdz{flex-shrink:0;color:var(--color-text-tertiary)}.import-file-info.svelte-6dohdz{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}.import-file-name.svelte-6dohdz{font-size:14px;color:var(--color-text-primary);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.import-file-size.svelte-6dohdz{font-size:12px;color:var(--color-text-tertiary)}.import-file-remove.svelte-6dohdz{flex-shrink:0;background:none;border:none;color:var(--color-text-tertiary);cursor:pointer;padding:4px;border-radius:4px;display:flex;align-items:center;justify-content:center}.import-file-remove.svelte-6dohdz:hover{color:var(--color-text-primary);background:var(--color-bg-hover)}.import-drop-zone.svelte-6dohdz{border:1px solid var(--color-border, #333);border-radius:0;padding:40px 16px;text-align:center;color:var(--color-text-tertiary);font-size:15px;min-height:180px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;transition:background .15s}.import-drop-zone-compact.svelte-6dohdz{min-height:0;padding:14px 16px;border-top:none}.import-hint.svelte-6dohdz{font-size:13px;color:var(--color-text-tertiary);margin:0}.file-picker-link.svelte-6dohdz{background:none;border:none;color:var(--color-accent, #e05050);cursor:pointer;text-decoration:underline;font-size:15px;padding:0}.file-picker-link-sm.svelte-6dohdz{font-size:13px}.repo-row-wrapper.svelte-6dohdz .repo-row{flex:1;min-width:0}.repo-row-wrapper.svelte-6dohdz .repo-actions-btn{display:none;width:28px;height:28px;position:absolute;right:12px;flex-shrink:0;padding:0;border:none;background:none;cursor:pointer;color:var(--color-text-tertiary);border-radius:4px;align-items:center;justify-content:center}.repo-row-wrapper.svelte-6dohdz .repo-actions-btn:hover{background:var(--color-bg-hover);color:var(--color-text-primary)}.repo-row-wrapper.svelte-6dohdz:hover .repo-row,.repo-row-wrapper.svelte-6dohdz:has(.repo-actions-btn.menu-open) .repo-row{background:var(--color-bg-hover)}.repo-row-wrapper.svelte-6dohdz:hover .repo-actions-btn,.repo-row-wrapper.svelte-6dohdz .repo-actions-btn.menu-open{display:inline-flex}.type-header-wrapper.svelte-6dohdz{position:relative;display:flex;align-items:center}.type-header-wrapper.svelte-6dohdz .type-header-row{flex:1;min-width:0}.type-header-wrapper.svelte-6dohdz .type-actions-btn{display:none;width:24px;height:24px;position:absolute;right:12px;flex-shrink:0;padding:0;border:none;background:none;cursor:pointer;color:var(--color-text-tertiary);border-radius:4px;align-items:center;justify-content:center}.type-header-wrapper.svelte-6dohdz .type-actions-btn:hover{background:var(--color-bg-hover);color:var(--color-text-primary)}.type-header-wrapper.svelte-6dohdz:hover .type-header-row,.type-header-wrapper.svelte-6dohdz:has(.type-actions-btn.menu-open) .type-header-row{background:var(--color-bg-hover)}.type-header-wrapper.svelte-6dohdz:hover .type-actions-btn,.type-header-wrapper.svelte-6dohdz .type-actions-btn.menu-open{display:inline-flex}.repo-actions-menu{min-width:120px;padding:4px;border-radius:6px;background:var(--color-bg-elevated);border:1px solid var(--color-border);box-shadow:0 4px 12px #00000026;z-index:1000}.repo-menu-item{display:flex;align-items:center;gap:8px;padding:6px 8px;border-radius:4px;cursor:pointer;font-size:13px;color:var(--color-text-primary)}.repo-menu-item:hover{background:var(--color-bg-hover)}.repo-menu-item-danger{color:var(--color-error, #e55)}.new-collection-btn,.new-collection-btn .repo-name.svelte-6dohdz,.new-collection-btn .row-chevron.svelte-6dohdz{color:var(--color-text-tertiary)}.new-collection-btn:hover,.new-collection-btn:hover .repo-name.svelte-6dohdz{color:var(--color-text-secondary)}.new-collection-row.svelte-6dohdz{display:flex;align-items:center;height:var(--row-height);padding:0 12px 0 20px;border-left:2px solid transparent}.new-collection-row.svelte-6dohdz .new-collection-input{flex:1;height:100%;padding:0 0 0 30px;margin-top:-1px;border:none;background:transparent;font-size:14px;border-radius:0}.new-collection-row.svelte-6dohdz .new-collection-clear{width:20px;height:20px;flex-shrink:0;margin-right:4px}.new-collection-row.svelte-6dohdz .private-toggle{width:20px;height:20px;flex-shrink:0;margin-left:auto;margin-right:4px;color:var(--color-text-secondary)}.new-collection-row.svelte-6dohdz .private-toggle.active{color:var(--color-accent, #e05050)}@keyframes svelte-6dohdz-shake{0%,to{transform:translate(0)}20%{transform:translate(-4px)}40%{transform:translate(4px)}60%{transform:translate(-3px)}80%{transform:translate(2px)}}.new-collection-row.svelte-6dohdz .new-collection-input.shake{animation:svelte-6dohdz-shake .3s ease-in-out}.sidebar-footer.svelte-6dohdz{display:flex;align-items:center;height:var(--row-height);padding:0 12px 0 19px;border-top:1px solid var(--color-border);flex-shrink:0;gap:8px;margin-top:auto}.user-email.svelte-6dohdz{flex:1;font-size:13px;color:var(--color-text-tertiary);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.sidebar-footer.svelte-6dohdz .footer-icon-btn{width:28px;height:28px}.transfer-header-col.svelte-6dohdz{display:flex;flex-direction:column;gap:4px}.transfer-list.svelte-6dohdz{display:flex;flex-direction:column;gap:2px}.transfer-list-item.svelte-6dohdz{display:flex;align-items:center;gap:10px;width:100%;padding:8px 12px;border-radius:6px;color:var(--color-text);font-size:13px;cursor:pointer}.transfer-list-item.svelte-6dohdz:hover{background:var(--color-bg-hover)}.entity-floating-tooltip.svelte-6dohdz{position:fixed;z-index:1000;transform:translateY(-50%);display:flex;flex-direction:column;gap:2px;padding:6px 10px;border-radius:6px;background:var(--color-bg-elevated);border:1px solid var(--color-border);box-shadow:0 4px 16px #0000004d;pointer-events:none;min-width:120px;max-width:260px}.entity-floating-tooltip.fading.svelte-6dohdz{opacity:0;transition:opacity .12s ease-out}.entity-tooltip-title.svelte-6dohdz{font-size:13px;font-weight:600;color:var(--color-text-primary)}.entity-tooltip-meta.svelte-6dohdz{font-size:13px;color:var(--color-text-tertiary)}.views-section.svelte-6dohdz{display:flex;flex-direction:column;padding:4px 8px;border-bottom:1px solid var(--color-border)}.views-personal.svelte-6dohdz{border-top:1px solid var(--color-border);padding-top:4px}.section-header.svelte-6dohdz{display:flex;align-items:center;padding:6px 12px 2px}.views-section.svelte-6dohdz .section-label:where(.svelte-6dohdz){flex:1;font-size:11px;font-weight:600;text-transform:uppercase;letter-spacing:.05em;color:var(--color-text-tertiary)}.section-add-btn{display:flex!important;align-items:center;justify-content:center;width:24px!important;height:24px!important;border:none!important;background:none!important;color:var(--color-text-tertiary);cursor:pointer;border-radius:4px;padding:0!important}.section-add-btn:hover{background:var(--color-bg-hover)!important;color:var(--color-text-primary)}.tree-row.view-row{gap:8px!important;align-items:center!important;padding-left:12px!important}.view-row svg{color:var(--color-text-tertiary);flex-shrink:0}.view-row.selected svg{color:var(--color-accent)}.collections-header.svelte-6dohdz{display:flex;align-items:center;padding:0 8px 0 0;border-top:1px solid var(--color-border)}.collections-toggle.svelte-6dohdz{display:flex;align-items:center;gap:4px;flex:1;padding:6px 12px;border:none;background:none;cursor:pointer;color:var(--color-text-tertiary);font-size:11px;font-weight:600;text-transform:uppercase;letter-spacing:.05em}.collections-toggle.svelte-6dohdz:hover{color:var(--color-text-secondary)}.collections-header.svelte-6dohdz .row-chevron:where(.svelte-6dohdz){transition:transform .15s}.collections-header.svelte-6dohdz .row-chevron.open:where(.svelte-6dohdz){transform:rotate(90deg)}.collections-label.svelte-6dohdz{flex:1;text-align:left}.chat-panel.svelte-1xwj6s7{position:relative;flex-shrink:0;display:flex;flex-direction:column;background:var(--color-bg);border-left:1px solid var(--color-border)}.chat-panel.chat-full.svelte-1xwj6s7{width:100%;min-width:0;flex:1;border-left:none}.chat-full.svelte-1xwj6s7 .chat-messages:where(.svelte-1xwj6s7){padding-left:calc((100% - 720px)/2);padding-right:calc((100% - 720px)/2)}.chat-full.svelte-1xwj6s7 .chat-input-area:where(.svelte-1xwj6s7){padding-left:calc((100% - 720px)/2);padding-right:calc((100% - 720px)/2)}.chat-header.svelte-1xwj6s7{height:var(--row-height);display:flex;align-items:center;justify-content:space-between;padding:0 16px;border-bottom:1px solid var(--color-border);position:relative;flex-shrink:0}.chat-header-left.svelte-1xwj6s7,.chat-header-right.svelte-1xwj6s7{display:flex;align-items:center;gap:2px}.history-active{color:var(--color-accent, #e05050)!important}.history-active:not(:hover){background:transparent!important}.session-dropdown.svelte-1xwj6s7{position:absolute;top:100%;left:0;right:0;z-index:10;box-shadow:0 4px 12px #0000001f}.session-list.svelte-1xwj6s7{max-height:240px;overflow-y:auto;background:var(--color-bg);border-bottom:1px solid var(--color-border)}.session-row.svelte-1xwj6s7{position:relative;display:flex;align-items:center}.session-row.svelte-1xwj6s7 .session-item{display:flex;align-items:center;justify-content:flex-start;flex:1;min-width:0;padding:0 32px 0 16px;height:var(--row-height);line-height:var(--row-height);font-size:14px;color:var(--color-text-secondary);text-align:left;border-radius:0}.session-row.svelte-1xwj6s7:hover .session-item{background:var(--color-bg-hover)}.session-row.svelte-1xwj6s7 .session-item.active{background:var(--color-bg-hover);color:var(--color-text-primary);font-weight:500}.session-row.svelte-1xwj6s7 .session-delete-btn{display:none;width:20px;height:20px;position:absolute;right:6px;flex-shrink:0;padding:0}.session-row.svelte-1xwj6s7 .session-delete-btn:hover{color:var(--color-error, #e55)}.session-row.svelte-1xwj6s7:hover .session-delete-btn{display:flex}.session-title.svelte-1xwj6s7{flex:1;overflow:hidden;white-space:nowrap;min-width:0;mask-image:linear-gradient(to right,black calc(100% - 24px),transparent 100%);-webkit-mask-image:linear-gradient(to right,black calc(100% - 24px),transparent 100%)}.chat-messages.svelte-1xwj6s7{flex:1;overflow-y:auto;padding:24px 16px;display:flex;flex-direction:column;gap:32px}.empty-state.svelte-1xwj6s7{flex:1;display:flex;align-items:center;justify-content:center;color:var(--color-text-tertiary);font-size:14px}.seed-prompts.svelte-1xwj6s7{display:flex;flex-direction:column;gap:8px;width:100%}.seed-prompts.svelte-1xwj6s7 .seed-prompt{font-size:14px;line-height:20px;padding:9px 13px;min-height:var(--row-height);height:auto;border-radius:8px;color:var(--color-text-secondary);text-align:left;white-space:normal;justify-content:flex-start}.seed-prompts.svelte-1xwj6s7 .seed-prompt:hover{background:var(--color-bg-hover);color:var(--color-text-primary)}.message-group.svelte-1xwj6s7{display:flex;flex-direction:column;gap:16px}.user-bubble.svelte-1xwj6s7{background:var(--color-bg-surface);border-radius:8px;padding:12px 14px;font-size:14px;line-height:22px;color:var(--color-text-primary)}.agent-content.svelte-1xwj6s7{display:flex;flex-direction:column;gap:14px;position:relative}.msg-actions.svelte-1xwj6s7{display:flex;gap:2px;align-self:flex-start}.copy-btn.svelte-1xwj6s7{display:flex;align-items:center;justify-content:center;background:none;border:none;color:var(--color-text-tertiary);cursor:pointer;padding:4px;border-radius:4px;align-self:flex-start}.copy-btn.svelte-1xwj6s7:hover{color:var(--color-text-primary);background:var(--color-bg-hover)}.tool-calls.svelte-1xwj6s7{display:flex;flex-direction:column;gap:4px}.tool-call.svelte-1xwj6s7{font-family:var(--font-mono);font-size:12px;color:var(--color-accent)}.agent-text.svelte-1xwj6s7{font-size:14px;line-height:22px;color:var(--color-text-primary)}.prose.svelte-1xwj6s7 h1{font-size:18px;font-weight:600;color:var(--color-text-primary);margin:24px 0 12px}.prose.svelte-1xwj6s7 h2{font-size:16px;font-weight:600;color:var(--color-text-primary);margin:22px 0 10px}.prose.svelte-1xwj6s7 h3{font-size:15px;font-weight:600;color:var(--color-text-primary);margin:20px 0 8px}.prose.svelte-1xwj6s7 p{margin:0 0 14px}.prose.svelte-1xwj6s7 p:last-child{margin-bottom:0}.prose.svelte-1xwj6s7 strong{font-weight:600}.prose.svelte-1xwj6s7 ul,.prose.svelte-1xwj6s7 ol{padding-left:20px;margin:0 0 14px;color:var(--color-text-primary)}.prose.svelte-1xwj6s7 ul{list-style-type:disc}.prose.svelte-1xwj6s7 ol{list-style-type:decimal}.prose.svelte-1xwj6s7 li{margin-bottom:6px}.prose.svelte-1xwj6s7 table{width:100%;border-collapse:collapse;font-size:13px;margin:16px 0}.prose.svelte-1xwj6s7 th,.prose.svelte-1xwj6s7 td{border:1px solid var(--color-border);padding:4px 8px;text-align:left;vertical-align:top}.prose.svelte-1xwj6s7 th{font-weight:600}.prose.svelte-1xwj6s7 pre{background:var(--color-bg-surface);border-radius:6px;padding:10px 12px;overflow-x:auto;margin:16px 0;font-family:var(--font-mono);font-size:13px;line-height:18px}.prose.svelte-1xwj6s7 code{font-family:var(--font-mono);font-size:13px;background:var(--color-bg-surface);padding:1px 4px;border-radius:3px}.prose.svelte-1xwj6s7 pre code{background:none;padding:0}.prose.svelte-1xwj6s7 a{color:var(--color-link)}.prose.svelte-1xwj6s7 blockquote{border-left:3px solid var(--color-accent);padding-left:12px;margin:16px 0;color:var(--color-text-secondary)}.prose.svelte-1xwj6s7 hr{border:none;border-top:1px solid var(--color-border);margin:24px 0}.streaming-dot.svelte-1xwj6s7{display:inline-block;width:8px;height:8px;background:var(--color-accent);border-radius:4px;animation:svelte-1xwj6s7-pulse 1s ease-in-out infinite}@keyframes svelte-1xwj6s7-pulse{0%,to{opacity:.3}50%{opacity:1}}.context-chip.svelte-1xwj6s7{font-size:12px;color:var(--color-text-tertiary);padding:0 2px 4px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.chat-input-area.svelte-1xwj6s7{padding:12px 16px 16px}.text-input.svelte-1xwj6s7{display:flex;align-items:flex-end;min-height:var(--row-height);max-height:140px;padding:0 0 0 13px;background:transparent;border:1px solid var(--color-border);border-radius:8px;transition:border-color .15s}.text-input.svelte-1xwj6s7:focus-within{border-color:var(--color-accent)}.send-btn{color:var(--color-text-tertiary);margin:6px;flex-shrink:0;pointer-events:none}.send-btn.send-active{pointer-events:auto;color:#fff;background:var(--color-accent);border-radius:6px}.stop-btn{color:#fff;background:var(--color-accent);border-radius:6px}.input-field.svelte-1xwj6s7{flex:1;background:transparent;border:none;outline:none;font-family:inherit;font-size:14px;line-height:20px;color:var(--color-text-primary);resize:none;overflow-y:auto;padding:9px 0;max-height:120px;field-sizing:content}.input-field.svelte-1xwj6s7::placeholder{color:var(--color-text-tertiary)}.input-field.svelte-1xwj6s7:disabled{opacity:.5}.role-selector{display:flex!important;align-items:center;gap:4px;padding:2px 8px!important;border:none!important;background:none!important;color:var(--color-text-tertiary);font-size:12px;font-weight:500;cursor:pointer;border-radius:4px;height:24px!important}.role-selector:hover{background:var(--color-bg-hover)!important;color:var(--color-text-secondary)}.role-label.svelte-1xwj6s7{white-space:nowrap}.role-menu{min-width:200px;max-width:280px;padding:4px;border-radius:8px;background:var(--color-bg-elevated);border:1px solid var(--color-border);box-shadow:0 8px 24px #0000004d;z-index:1000}.role-menu-item{display:flex;flex-direction:column;gap:2px;padding:8px 10px;border-radius:6px;cursor:pointer}.role-menu-item:hover,.role-menu-item.role-active{background:var(--color-bg-hover)}.role-item-label{font-size:13px;font-weight:500;color:var(--color-text-primary)}.role-active .role-item-label{color:var(--color-accent)}.role-item-desc{font-size:11px;color:var(--color-text-tertiary);line-height:1.3}.search-dialog{display:flex;flex-direction:column;max-height:min(560px,70vh)}.search-header.svelte-1xems06{display:flex;align-items:center;height:52px;padding:0 16px;gap:10px;border-bottom:1px solid var(--color-border);flex-shrink:0}.search-header.svelte-1xems06 svg{color:var(--color-text-tertiary);flex-shrink:0}.search-header.svelte-1xems06 .search-input{flex:1;font-size:16px;line-height:20px;border:none;background:transparent;box-shadow:none;padding:0;height:auto}.search-header.svelte-1xems06 .search-input:focus{box-shadow:none;border:none}.esc-badge.svelte-1xems06{font-family:var(--font-sans);font-size:12px;line-height:1;padding:3px 6px;border-radius:4px;background:var(--color-bg-surface);border:1px solid var(--color-border);color:var(--color-text-tertiary)}.results-list.svelte-1xems06{flex:1;overflow-y:auto;min-height:0;padding:4px 0}.section-label.svelte-1xems06{display:flex;align-items:center;gap:6px;padding:8px 16px 4px;font-size:11px;font-weight:600;text-transform:uppercase;letter-spacing:.05em;color:var(--color-text-tertiary)}.section-dot.svelte-1xems06{width:6px;height:6px;border-radius:50%;flex-shrink:0}.section-count.svelte-1xems06{font-weight:400;opacity:.6}.empty-results.svelte-1xems06{padding:24px 16px;text-align:center;font-size:14px;color:var(--color-text-tertiary)}.results-list.svelte-1xems06 .result-row{display:flex;align-items:center;padding:6px 16px;width:100%;text-align:left;border-radius:0;height:auto;justify-content:flex-start;gap:10px}.results-list.svelte-1xems06 .result-row:hover,.results-list.svelte-1xems06 .result-row.selected{background:var(--color-bg-hover)}.result-dot.svelte-1xems06{width:8px;height:8px;border-radius:50%;flex-shrink:0}.result-body.svelte-1xems06{flex:1;min-width:0;display:flex;align-items:center;gap:8px}.result-title.svelte-1xems06{font-size:14px;font-weight:500;color:var(--color-text-primary);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.result-type.svelte-1xems06,.result-date.svelte-1xems06{font-size:12px;color:var(--color-text-tertiary);flex-shrink:0}.result-status.svelte-1xems06{font-size:11px;font-weight:500;padding:1px 6px;border-radius:3px;background:var(--color-badge-bg);color:var(--color-badge-text);flex-shrink:0}.search-footer.svelte-1xems06{display:flex;align-items:center;height:39px;padding:0 16px;gap:16px;border-top:1px solid var(--color-border);flex-shrink:0}.shortcut-group.svelte-1xems06{display:flex;align-items:center;gap:4px}.shortcut-key.svelte-1xems06{display:inline-flex;align-items:center;justify-content:center;min-width:20px;height:20px;padding:0 4px;border-radius:4px;background:var(--color-bg-surface);border:1px solid var(--color-border);color:var(--color-text-tertiary)}.shortcut-label.svelte-1xems06{font-size:12px;color:var(--color-text-tertiary);margin-left:2px}.app-frame.svelte-vr1z90{width:100vw;height:100vh;display:flex;flex-direction:column;overflow:hidden;background:var(--color-bg)}.app-body.svelte-vr1z90{flex:1;display:flex;min-height:0;overflow:hidden}.main-content.svelte-vr1z90{flex:1;display:flex;flex-direction:column;min-width:0;min-height:0;overflow:hidden}#sg-chrome-footer{flex-shrink:0}
1
+ .resize-handle.svelte-tfh9g9{position:absolute;top:0;bottom:0;width:6px;cursor:col-resize;z-index:10}.resize-handle.right.svelte-tfh9g9{right:-3px}.resize-handle.left.svelte-tfh9g9{left:-3px}.resize-handle.svelte-tfh9g9:hover,.resize-handle.active.svelte-tfh9g9{background:var(--color-accent);opacity:.3}.resize-handle.active.svelte-tfh9g9{opacity:.5}.radio-item{position:relative;display:flex;align-items:center;justify-content:center;width:16px;height:16px;border-radius:50%;border:1.5px solid var(--color-text-tertiary);background:none;outline:none;flex-shrink:0;cursor:pointer}.radio-item[data-state=checked]{border-color:var(--color-accent)}.radio-item:focus-visible{box-shadow:0 0 0 2px var(--color-accent)}.radio-dot.svelte-l8hbh2{width:8px;height:8px;border-radius:50%;background:var(--color-accent)}.entity-body{padding:16px 24px 24px;display:flex;flex-direction:column;gap:20px;overflow-x:hidden}.type-section.svelte-ak7t5k{display:flex;flex-direction:column;gap:8px}.type-section-label.svelte-ak7t5k{font-size:11px;font-weight:600;text-transform:uppercase;letter-spacing:.05em;color:var(--color-text-tertiary)}.type-grid.svelte-ak7t5k{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.type-grid.svelte-ak7t5k .type-card{display:flex;flex-direction:column;align-items:flex-start;gap:10px;padding:12px;height:auto;border-radius:8px;text-align:left;color:var(--color-text-secondary);justify-content:flex-start}.type-grid.svelte-ak7t5k .type-card:hover{background:var(--color-bg-hover);border-color:var(--color-border-strong)}.type-grid.svelte-ak7t5k .type-card:hover .type-name{color:var(--color-text-primary)}.type-dot.svelte-ak7t5k{width:8px;height:8px;border-radius:50%}.type-info.svelte-ak7t5k{display:flex;flex-direction:column;gap:2px}.type-name.svelte-ak7t5k{font-size:14px;font-weight:500;color:var(--color-text-secondary)}.type-desc.svelte-ak7t5k{font-size:12px;color:var(--color-text-tertiary);line-height:1.3}.sidebar.svelte-6dohdz{position:relative;flex-shrink:0;display:flex;flex-direction:column;overflow:hidden;background:var(--color-bg);border-right:1px solid var(--color-border);transition:width .15s ease}.sidebar.collapsed.svelte-6dohdz{overflow:visible}.rail.svelte-6dohdz{display:flex;flex-direction:column;align-items:center;padding:8px 0;gap:4px;height:100%}.rail-spacer.svelte-6dohdz{flex:1}.rail-btn{width:36px!important;height:36px!important;display:flex!important;align-items:center;justify-content:center;border-radius:8px}.rail-btn:hover{background:var(--color-bg-hover)!important}.rail.svelte-6dohdz .workspace-icon:where(.svelte-6dohdz){width:28px;height:28px;font-size:14px}.sidebar-header.svelte-6dohdz{height:var(--row-height);display:flex;align-items:center;gap:11px;padding:0 12px 0 19px;border-bottom:1px solid var(--color-border);flex-shrink:0}.header-actions.svelte-6dohdz{margin-left:auto;display:flex;align-items:center}.sidebar-header.svelte-6dohdz .home-btn{display:inline-flex;align-items:center;gap:11px;padding:0;min-width:0;text-align:left;border-radius:0;height:auto;background:transparent!important}.sidebar-header.svelte-6dohdz .home-btn:hover .workspace-icon{opacity:.8}.sidebar-header.svelte-6dohdz .home-btn:hover .workspace-name{color:var(--color-text-secondary)}.workspace-icon.svelte-6dohdz{width:22px;height:22px;border-radius:50%;background:var(--color-accent, #e05050);color:#fff;display:flex;align-items:center;justify-content:center;font-weight:600;font-size:11px;flex-shrink:0}.workspace-name.svelte-6dohdz{flex:1;font-size:14px;font-weight:600;color:var(--color-text-primary)}.settings-nav.svelte-6dohdz{display:flex;flex-direction:column;flex:1;padding-top:0}.settings-nav.svelte-6dohdz button[data-slot=tabs-trigger]{display:flex;align-items:center;width:100%;height:var(--row-height);padding:0 12px 0 19px;gap:11px;border:none;background:transparent;cursor:pointer;font-family:inherit;font-size:14px;color:var(--color-text-secondary);transition:color .15s,background .15s}.settings-nav.svelte-6dohdz button[data-slot=tabs-trigger]:hover{background:var(--color-bg-hover);color:var(--color-text-primary)}.settings-nav.svelte-6dohdz button[data-slot=tabs-trigger][data-state=active]{background:var(--color-bg-hover);color:var(--color-text-primary);font-weight:500}.settings-nav.svelte-6dohdz button[data-slot=tabs-trigger] svg{width:14px;height:14px;flex-shrink:0;box-sizing:content-box;padding:0 4px}.filter-bar.svelte-6dohdz{position:relative;display:flex;align-items:center;height:var(--row-height);padding:0 12px 0 52px;border-bottom:1px solid var(--color-border);flex-shrink:0}.filter-icon.svelte-6dohdz{position:absolute;left:22px;top:50%;transform:translateY(-50%);display:flex;align-items:center;justify-content:center;width:16px;color:var(--color-text-tertiary)}.filter-bar.svelte-6dohdz .filter-input{flex:1;background:transparent;border:none;outline:none;padding:0;margin:0;font-size:14px;line-height:1.4;height:auto;border-radius:0}.filter-bar.svelte-6dohdz .filter-clear{width:20px;height:20px;flex-shrink:0}.filter-bar.svelte-6dohdz .sort-toggle{width:28px;height:28px;flex-shrink:0;margin-left:4px}.filter-bar.svelte-6dohdz .sort-toggle.active{color:var(--color-accent, #e05050)}.repo-type-icon.svelte-6dohdz{display:inline-flex;align-items:center;color:var(--color-text-tertiary);margin-right:6px;flex-shrink:0;align-self:center}.tree.svelte-6dohdz{flex:1;overflow-y:auto;padding-top:0}.tree-group.svelte-6dohdz{display:flex;flex-direction:column}.tree-group.svelte-6dohdz+.tree-group:where(.svelte-6dohdz){margin-top:0}.repo-row{display:flex;align-items:baseline;height:var(--row-height);line-height:var(--row-height);width:100%;padding:0 12px 0 20px;border:none;background:transparent;font-family:inherit;text-align:left;border-left:2px solid transparent;border-radius:0;gap:0;justify-content:flex-start}.repo-row:hover,.repo-row.focused{background:var(--color-bg-hover)}.repo-row.repo-active{border-left-color:var(--active-color)}.repo-name.svelte-6dohdz{font-size:14px;color:var(--color-text-secondary)}.repo-row.repo-active .repo-name.svelte-6dohdz,.repo-row.repo-active .repo-type-icon.svelte-6dohdz{font-weight:600;color:var(--color-text-primary)}.tree-row{position:relative;display:flex;align-items:baseline;height:var(--row-height);line-height:var(--row-height);padding-right:40px;color:var(--color-text-secondary);font-size:14px;border:none;background:transparent;font-family:inherit;text-align:left;width:100%;border-left:2px solid transparent;border-radius:0;gap:0;justify-content:flex-start}.tree-row:hover,.tree-row.focused{background:var(--color-bg-hover)}.tree-row.selected{background:var(--color-bg-selected);border-left-color:var(--active-color);color:var(--color-text-primary);font-weight:600}.row-chevron.svelte-6dohdz{display:inline-flex;align-items:center;justify-content:center;align-self:center;width:16px;height:16px;flex-shrink:0;margin-right:14px;color:var(--color-text-tertiary);transition:transform .15s}.row-chevron.open.svelte-6dohdz{transform:rotate(90deg)}.row-label.svelte-6dohdz{flex:1;overflow:hidden;white-space:nowrap;mask-image:linear-gradient(to right,black calc(100% - 16px),transparent 100%);-webkit-mask-image:linear-gradient(to right,black calc(100% - 16px),transparent 100%)}.item-count.svelte-6dohdz{font-size:12px;font-weight:400;color:var(--color-text-tertiary);margin-left:8px;flex-shrink:0;opacity:0;transition:opacity .15s}.tree-row:hover .item-count.svelte-6dohdz,.repo-row-wrapper.svelte-6dohdz:hover .item-count:where(.svelte-6dohdz),.repo-row-wrapper.svelte-6dohdz:has(.repo-actions-btn.menu-open) .item-count:where(.svelte-6dohdz),.type-header-wrapper.svelte-6dohdz:hover .item-count:where(.svelte-6dohdz),.type-header-wrapper.svelte-6dohdz:has(.type-actions-btn.menu-open) .item-count:where(.svelte-6dohdz),.entity-row-wrapper.svelte-6dohdz:hover .item-count:where(.svelte-6dohdz),.entity-row-wrapper.svelte-6dohdz:has(.entity-actions-btn.menu-open) .item-count:where(.svelte-6dohdz){opacity:1}.indent-group.svelte-6dohdz{position:relative}.indent-group.svelte-6dohdz:before{content:"";position:absolute;left:var(--guide-left);top:0;bottom:0;width:1px;background:var(--color-border);pointer-events:none}.loading-row.svelte-6dohdz{height:var(--row-height);display:flex;align-items:center;font-size:14px;color:var(--color-text-tertiary)}.type-header-row{color:var(--color-text-secondary);border-left:2px solid transparent}.type-header-row.type-active{color:var(--color-text-primary);font-weight:600}.type-header-row .row-label.svelte-6dohdz{flex:none;mask-image:none;-webkit-mask-image:none}.entity-type-dot.svelte-6dohdz{width:6px;height:6px;border-radius:3px;flex-shrink:0;margin-right:2px}.new-entity-row{color:var(--color-text-tertiary);align-items:center}.new-entity-row:hover{color:var(--color-text-secondary)}.entity-row-wrapper.svelte-6dohdz{position:relative;display:flex;align-items:center}.entity-row-wrapper.svelte-6dohdz .tree-row{flex:1;min-width:0}.entity-row-wrapper.svelte-6dohdz .entity-actions-btn{display:none;width:28px;height:28px;position:absolute;right:12px;flex-shrink:0;padding:0;border:none;background:none;cursor:pointer;color:var(--color-text-tertiary);border-radius:4px;align-items:center;justify-content:center}.entity-row-wrapper.svelte-6dohdz .entity-actions-btn:hover{background:var(--color-bg-hover);color:var(--color-text-primary)}.entity-row-wrapper.svelte-6dohdz:hover .tree-row,.entity-row-wrapper.svelte-6dohdz:has(.entity-actions-btn.menu-open) .tree-row{background:var(--color-bg-hover)}.entity-row-wrapper.svelte-6dohdz:hover .entity-actions-btn,.entity-row-wrapper.svelte-6dohdz .entity-actions-btn.menu-open{display:inline-flex}.entity-type-dot.svelte-6dohdz{width:6px;height:6px;border-radius:50%;flex-shrink:0;margin-right:19px;align-self:center}.recent-time.svelte-6dohdz{font-size:12px;color:var(--color-text-tertiary);position:absolute;right:26px;top:50%;transform:translate(50%,-50%);white-space:nowrap}.entity-row-wrapper.svelte-6dohdz:hover .recent-time:where(.svelte-6dohdz){display:none}.presence-stack.svelte-6dohdz{display:flex;align-items:center;gap:-4px;margin-left:auto;flex-shrink:0;align-self:center}.presence-avatar.svelte-6dohdz{width:18px;height:18px;border-radius:50%;font-size:10px;font-weight:600;color:#fff;background:var(--color-accent);display:flex;align-items:center;justify-content:center;margin-left:-3px;border:1px solid var(--color-bg);box-sizing:border-box;flex-shrink:0;align-self:center}.presence-stack.svelte-6dohdz .presence-avatar:where(.svelte-6dohdz):first-child{margin-left:4px}.repo-row .presence-stack.svelte-6dohdz{margin-right:28px}.presence-avatar.svelte-6dohdz:nth-child(1){z-index:3}.presence-avatar.svelte-6dohdz:nth-child(2){z-index:2}.presence-avatar.svelte-6dohdz:nth-child(3){z-index:1}.filter-match.svelte-6dohdz{background:var(--color-accent, #e05050);color:#fff;border-radius:2px;padding:0}.no-results.svelte-6dohdz{padding:24px 16px;font-size:14px;color:var(--color-text-tertiary);text-align:center}.repo-row .repo-rename-input{flex:1;min-width:0;height:100%;padding:0 6px;margin:0;border:1px solid var(--color-accent, #e05050);border-radius:3px;font-size:14px;font-weight:600}.repo-row-wrapper.svelte-6dohdz{position:relative;display:flex;align-items:center}.repo-row-wrapper.drop-target.svelte-6dohdz{outline:2px solid var(--color-accent, #e05050);outline-offset:-2px;border-radius:6px;background:#e0505014}.import-modal{max-width:480px}.import-modal .dialog-header{flex-direction:column;align-items:flex-start;gap:4px}.import-modal-body.svelte-6dohdz{padding:16px 24px 8px}.import-modal .dialog-footer{border-top:none}.import-file-list.svelte-6dohdz{display:flex;flex-direction:column;max-height:240px;overflow-y:auto}.import-file-row.svelte-6dohdz{display:flex;align-items:center;gap:10px;padding:10px 12px;border-bottom:1px solid var(--color-border)}.import-file-icon.svelte-6dohdz{flex-shrink:0;color:var(--color-text-tertiary)}.import-file-info.svelte-6dohdz{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}.import-file-name.svelte-6dohdz{font-size:14px;color:var(--color-text-primary);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.import-file-size.svelte-6dohdz{font-size:12px;color:var(--color-text-tertiary)}.import-file-remove.svelte-6dohdz{flex-shrink:0;background:none;border:none;color:var(--color-text-tertiary);cursor:pointer;padding:4px;border-radius:4px;display:flex;align-items:center;justify-content:center}.import-file-remove.svelte-6dohdz:hover{color:var(--color-text-primary);background:var(--color-bg-hover)}.import-drop-zone.svelte-6dohdz{border:1px solid var(--color-border, #333);border-radius:0;padding:40px 16px;text-align:center;color:var(--color-text-tertiary);font-size:15px;min-height:180px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;transition:background .15s}.import-drop-zone-compact.svelte-6dohdz{min-height:0;padding:14px 16px;border-top:none}.import-hint.svelte-6dohdz{font-size:13px;color:var(--color-text-tertiary);margin:0}.file-picker-link.svelte-6dohdz{background:none;border:none;color:var(--color-accent, #e05050);cursor:pointer;text-decoration:underline;font-size:15px;padding:0}.file-picker-link-sm.svelte-6dohdz{font-size:13px}.repo-row-wrapper.svelte-6dohdz .repo-row{flex:1;min-width:0}.repo-row-wrapper.svelte-6dohdz .repo-actions-btn{display:none;width:28px;height:28px;position:absolute;right:12px;flex-shrink:0;padding:0;border:none;background:none;cursor:pointer;color:var(--color-text-tertiary);border-radius:4px;align-items:center;justify-content:center}.repo-row-wrapper.svelte-6dohdz .repo-actions-btn:hover{background:var(--color-bg-hover);color:var(--color-text-primary)}.repo-row-wrapper.svelte-6dohdz:hover .repo-row,.repo-row-wrapper.svelte-6dohdz:has(.repo-actions-btn.menu-open) .repo-row{background:var(--color-bg-hover)}.repo-row-wrapper.svelte-6dohdz:hover .repo-actions-btn,.repo-row-wrapper.svelte-6dohdz .repo-actions-btn.menu-open{display:inline-flex}.type-header-wrapper.svelte-6dohdz{position:relative;display:flex;align-items:center}.type-header-wrapper.svelte-6dohdz .type-header-row{flex:1;min-width:0}.type-header-wrapper.svelte-6dohdz .type-actions-btn{display:none;width:24px;height:24px;position:absolute;right:12px;flex-shrink:0;padding:0;border:none;background:none;cursor:pointer;color:var(--color-text-tertiary);border-radius:4px;align-items:center;justify-content:center}.type-header-wrapper.svelte-6dohdz .type-actions-btn:hover{background:var(--color-bg-hover);color:var(--color-text-primary)}.type-header-wrapper.svelte-6dohdz:hover .type-header-row,.type-header-wrapper.svelte-6dohdz:has(.type-actions-btn.menu-open) .type-header-row{background:var(--color-bg-hover)}.type-header-wrapper.svelte-6dohdz:hover .type-actions-btn,.type-header-wrapper.svelte-6dohdz .type-actions-btn.menu-open{display:inline-flex}.repo-actions-menu{min-width:120px;padding:4px;border-radius:6px;background:var(--color-bg-elevated);border:1px solid var(--color-border);box-shadow:0 4px 12px #00000026;z-index:1000}.repo-menu-item{display:flex;align-items:center;gap:8px;padding:6px 8px;border-radius:4px;cursor:pointer;font-size:13px;color:var(--color-text-primary)}.repo-menu-item:hover{background:var(--color-bg-hover)}.repo-menu-item-danger{color:var(--color-error, #e55)}.new-collection-btn,.new-collection-btn .repo-name.svelte-6dohdz,.new-collection-btn .row-chevron.svelte-6dohdz{color:var(--color-text-tertiary)}.new-collection-btn:hover,.new-collection-btn:hover .repo-name.svelte-6dohdz{color:var(--color-text-secondary)}.new-collection-row.svelte-6dohdz{display:flex;align-items:center;height:var(--row-height);padding:0 12px 0 20px;border-left:2px solid transparent}.new-collection-row.svelte-6dohdz .new-collection-input{flex:1;height:100%;padding:0 0 0 30px;margin-top:-1px;border:none;background:transparent;font-size:14px;border-radius:0}.new-collection-row.svelte-6dohdz .new-collection-clear{width:20px;height:20px;flex-shrink:0;margin-right:4px}.new-collection-row.svelte-6dohdz .private-toggle{width:20px;height:20px;flex-shrink:0;margin-left:auto;margin-right:4px;color:var(--color-text-secondary)}.new-collection-row.svelte-6dohdz .private-toggle.active{color:var(--color-accent, #e05050)}@keyframes svelte-6dohdz-shake{0%,to{transform:translate(0)}20%{transform:translate(-4px)}40%{transform:translate(4px)}60%{transform:translate(-3px)}80%{transform:translate(2px)}}.new-collection-row.svelte-6dohdz .new-collection-input.shake{animation:svelte-6dohdz-shake .3s ease-in-out}.sidebar-footer.svelte-6dohdz{display:flex;align-items:center;height:var(--row-height);padding:0 12px 0 19px;border-top:1px solid var(--color-border);flex-shrink:0;gap:8px;margin-top:auto}.user-email.svelte-6dohdz{flex:1;font-size:13px;color:var(--color-text-tertiary);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.sidebar-footer.svelte-6dohdz .footer-icon-btn{width:28px;height:28px}.transfer-header-col.svelte-6dohdz{display:flex;flex-direction:column;gap:4px}.transfer-list.svelte-6dohdz{display:flex;flex-direction:column;gap:2px}.transfer-list-item.svelte-6dohdz{display:flex;align-items:center;gap:10px;width:100%;padding:8px 12px;border-radius:6px;color:var(--color-text);font-size:13px;cursor:pointer}.transfer-list-item.svelte-6dohdz:hover{background:var(--color-bg-hover)}.entity-floating-tooltip.svelte-6dohdz{position:fixed;z-index:1000;transform:translateY(-50%);display:flex;flex-direction:column;gap:2px;padding:6px 10px;border-radius:6px;background:var(--color-bg-elevated);border:1px solid var(--color-border);box-shadow:0 4px 16px #0000004d;pointer-events:none;min-width:120px;max-width:260px}.entity-floating-tooltip.fading.svelte-6dohdz{opacity:0;transition:opacity .12s ease-out}.entity-tooltip-title.svelte-6dohdz{font-size:13px;font-weight:600;color:var(--color-text-primary)}.entity-tooltip-meta.svelte-6dohdz{font-size:13px;color:var(--color-text-tertiary)}.views-section.svelte-6dohdz{display:flex;flex-direction:column;padding:4px 8px;border-bottom:1px solid var(--color-border)}.views-personal.svelte-6dohdz{border-top:1px solid var(--color-border);padding-top:4px}.section-header.svelte-6dohdz{display:flex;align-items:center;padding:6px 12px 2px}.views-section.svelte-6dohdz .section-label:where(.svelte-6dohdz){flex:1;font-size:11px;font-weight:600;text-transform:uppercase;letter-spacing:.05em;color:var(--color-text-tertiary)}.section-add-btn{display:flex!important;align-items:center;justify-content:center;width:24px!important;height:24px!important;border:none!important;background:none!important;color:var(--color-text-tertiary);cursor:pointer;border-radius:4px;padding:0!important}.section-add-btn:hover{background:var(--color-bg-hover)!important;color:var(--color-text-primary)}.tree-row.view-row{gap:8px!important;align-items:center!important;padding-left:12px!important}.view-row svg{color:var(--color-text-tertiary);flex-shrink:0}.view-row.selected svg{color:var(--color-accent)}.collections-header.svelte-6dohdz{display:flex;align-items:center;padding:0 8px 0 0;border-top:1px solid var(--color-border)}.collections-toggle.svelte-6dohdz{display:flex;align-items:center;gap:4px;flex:1;padding:6px 12px;border:none;background:none;cursor:pointer;color:var(--color-text-tertiary);font-size:11px;font-weight:600;text-transform:uppercase;letter-spacing:.05em}.collections-toggle.svelte-6dohdz:hover{color:var(--color-text-secondary)}.collections-header.svelte-6dohdz .row-chevron:where(.svelte-6dohdz){transition:transform .15s}.collections-header.svelte-6dohdz .row-chevron.open:where(.svelte-6dohdz){transform:rotate(90deg)}.collections-label.svelte-6dohdz{flex:1;text-align:left}.chat-panel.svelte-1xwj6s7{position:relative;flex-shrink:0;display:flex;flex-direction:column;background:var(--color-bg);border-left:1px solid var(--color-border)}.chat-panel.chat-full.svelte-1xwj6s7{width:100%;min-width:0;flex:1;border-left:none}.chat-full.svelte-1xwj6s7 .chat-messages:where(.svelte-1xwj6s7){padding-left:calc((100% - 720px)/2);padding-right:calc((100% - 720px)/2)}.chat-full.svelte-1xwj6s7 .chat-input-area:where(.svelte-1xwj6s7){padding-left:calc((100% - 720px)/2);padding-right:calc((100% - 720px)/2)}.chat-header.svelte-1xwj6s7{height:var(--row-height);display:flex;align-items:center;justify-content:space-between;padding:0 16px;border-bottom:1px solid var(--color-border);position:relative;flex-shrink:0}.chat-header-left.svelte-1xwj6s7,.chat-header-right.svelte-1xwj6s7{display:flex;align-items:center;gap:2px}.history-active{color:var(--color-accent, #e05050)!important}.history-active:not(:hover){background:transparent!important}.session-dropdown.svelte-1xwj6s7{position:absolute;top:100%;left:0;right:0;z-index:10;box-shadow:0 4px 12px #0000001f}.session-list.svelte-1xwj6s7{max-height:240px;overflow-y:auto;background:var(--color-bg);border-bottom:1px solid var(--color-border)}.session-row.svelte-1xwj6s7{position:relative;display:flex;align-items:center}.session-row.svelte-1xwj6s7 .session-item{display:flex;align-items:center;justify-content:flex-start;flex:1;min-width:0;padding:0 32px 0 16px;height:var(--row-height);line-height:var(--row-height);font-size:14px;color:var(--color-text-secondary);text-align:left;border-radius:0}.session-row.svelte-1xwj6s7:hover .session-item{background:var(--color-bg-hover)}.session-row.svelte-1xwj6s7 .session-item.active{background:var(--color-bg-hover);color:var(--color-text-primary);font-weight:500}.session-row.svelte-1xwj6s7 .session-delete-btn{display:none;width:20px;height:20px;position:absolute;right:6px;flex-shrink:0;padding:0}.session-row.svelte-1xwj6s7 .session-delete-btn:hover{color:var(--color-error, #e55)}.session-row.svelte-1xwj6s7:hover .session-delete-btn{display:flex}.session-title.svelte-1xwj6s7{flex:1;overflow:hidden;white-space:nowrap;min-width:0;mask-image:linear-gradient(to right,black calc(100% - 24px),transparent 100%);-webkit-mask-image:linear-gradient(to right,black calc(100% - 24px),transparent 100%)}.chat-messages.svelte-1xwj6s7{flex:1;overflow-y:auto;padding:24px 16px;display:flex;flex-direction:column;gap:32px}.empty-state.svelte-1xwj6s7{flex:1;display:flex;align-items:center;justify-content:center;color:var(--color-text-tertiary);font-size:14px}.seed-prompts.svelte-1xwj6s7{display:flex;flex-direction:column;gap:8px;width:100%}.seed-prompts.svelte-1xwj6s7 .seed-prompt{font-size:14px;line-height:20px;padding:9px 13px;min-height:var(--row-height);height:auto;border-radius:8px;color:var(--color-text-secondary);text-align:left;white-space:normal;justify-content:flex-start}.seed-prompts.svelte-1xwj6s7 .seed-prompt:hover{background:var(--color-bg-hover);color:var(--color-text-primary)}.message-group.svelte-1xwj6s7{display:flex;flex-direction:column;gap:16px}.user-bubble.svelte-1xwj6s7{background:var(--color-bg-surface);border-radius:8px;padding:12px 14px;font-size:14px;line-height:22px;color:var(--color-text-primary)}.agent-content.svelte-1xwj6s7{display:flex;flex-direction:column;gap:14px;position:relative}.msg-actions.svelte-1xwj6s7{display:flex;gap:2px;align-self:flex-start}.copy-btn.svelte-1xwj6s7{display:flex;align-items:center;justify-content:center;background:none;border:none;color:var(--color-text-tertiary);cursor:pointer;padding:4px;border-radius:4px;align-self:flex-start}.copy-btn.svelte-1xwj6s7:hover{color:var(--color-text-primary);background:var(--color-bg-hover)}.tool-calls.svelte-1xwj6s7{display:flex;flex-direction:column;gap:4px}.tool-call.svelte-1xwj6s7{font-family:var(--font-mono);font-size:12px;color:var(--color-accent)}.agent-text.svelte-1xwj6s7{font-size:14px;line-height:22px;color:var(--color-text-primary)}.prose.svelte-1xwj6s7 h1{font-size:18px;font-weight:600;color:var(--color-text-primary);margin:24px 0 12px}.prose.svelte-1xwj6s7 h2{font-size:16px;font-weight:600;color:var(--color-text-primary);margin:22px 0 10px}.prose.svelte-1xwj6s7 h3{font-size:15px;font-weight:600;color:var(--color-text-primary);margin:20px 0 8px}.prose.svelte-1xwj6s7 p{margin:0 0 14px}.prose.svelte-1xwj6s7 p:last-child{margin-bottom:0}.prose.svelte-1xwj6s7 strong{font-weight:600}.prose.svelte-1xwj6s7 ul,.prose.svelte-1xwj6s7 ol{padding-left:20px;margin:0 0 14px;color:var(--color-text-primary)}.prose.svelte-1xwj6s7 ul{list-style-type:disc}.prose.svelte-1xwj6s7 ol{list-style-type:decimal}.prose.svelte-1xwj6s7 li{margin-bottom:6px}.prose.svelte-1xwj6s7 table{width:100%;border-collapse:collapse;font-size:13px;margin:16px 0}.prose.svelte-1xwj6s7 th,.prose.svelte-1xwj6s7 td{border:1px solid var(--color-border);padding:4px 8px;text-align:left;vertical-align:top}.prose.svelte-1xwj6s7 th{font-weight:600}.prose.svelte-1xwj6s7 pre{background:var(--color-bg-surface);border-radius:6px;padding:10px 12px;overflow-x:auto;margin:16px 0;font-family:var(--font-mono);font-size:13px;line-height:18px}.prose.svelte-1xwj6s7 code{font-family:var(--font-mono);font-size:13px;background:var(--color-bg-surface);padding:1px 4px;border-radius:3px}.prose.svelte-1xwj6s7 pre code{background:none;padding:0}.prose.svelte-1xwj6s7 a{color:var(--color-link)}.prose.svelte-1xwj6s7 blockquote{border-left:3px solid var(--color-accent);padding-left:12px;margin:16px 0;color:var(--color-text-secondary)}.prose.svelte-1xwj6s7 hr{border:none;border-top:1px solid var(--color-border);margin:24px 0}.streaming-dot.svelte-1xwj6s7{display:inline-block;width:8px;height:8px;background:var(--color-accent);border-radius:4px;animation:svelte-1xwj6s7-pulse 1s ease-in-out infinite}@keyframes svelte-1xwj6s7-pulse{0%,to{opacity:.3}50%{opacity:1}}.context-chip.svelte-1xwj6s7{font-size:12px;color:var(--color-text-tertiary);padding:0 2px 4px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.chat-input-area.svelte-1xwj6s7{padding:12px 16px 16px}.text-input.svelte-1xwj6s7{display:flex;align-items:flex-end;min-height:var(--row-height);max-height:140px;padding:0 0 0 13px;background:transparent;border:1px solid var(--color-border);border-radius:8px;transition:border-color .15s}.text-input.svelte-1xwj6s7:focus-within{border-color:var(--color-accent)}.send-btn{color:var(--color-text-tertiary);margin:6px;flex-shrink:0;pointer-events:none}.send-btn.send-active{pointer-events:auto;color:#fff;background:var(--color-accent);border-radius:6px}.stop-btn{color:#fff;background:var(--color-accent);border-radius:6px}.input-field.svelte-1xwj6s7{flex:1;background:transparent;border:none;outline:none;font-family:inherit;font-size:14px;line-height:20px;color:var(--color-text-primary);resize:none;overflow-y:auto;padding:9px 0;max-height:120px;field-sizing:content}.input-field.svelte-1xwj6s7::placeholder{color:var(--color-text-tertiary)}.input-field.svelte-1xwj6s7:disabled{opacity:.5}.search-dialog{display:flex;flex-direction:column;max-height:min(560px,70vh)}.search-header.svelte-1xems06{display:flex;align-items:center;height:52px;padding:0 16px;gap:10px;border-bottom:1px solid var(--color-border);flex-shrink:0}.search-header.svelte-1xems06 svg{color:var(--color-text-tertiary);flex-shrink:0}.search-header.svelte-1xems06 .search-input{flex:1;font-size:16px;line-height:20px;border:none;background:transparent;box-shadow:none;padding:0;height:auto}.search-header.svelte-1xems06 .search-input:focus{box-shadow:none;border:none}.esc-badge.svelte-1xems06{font-family:var(--font-sans);font-size:12px;line-height:1;padding:3px 6px;border-radius:4px;background:var(--color-bg-surface);border:1px solid var(--color-border);color:var(--color-text-tertiary)}.results-list.svelte-1xems06{flex:1;overflow-y:auto;min-height:0;padding:4px 0}.section-label.svelte-1xems06{display:flex;align-items:center;gap:6px;padding:8px 16px 4px;font-size:11px;font-weight:600;text-transform:uppercase;letter-spacing:.05em;color:var(--color-text-tertiary)}.section-dot.svelte-1xems06{width:6px;height:6px;border-radius:50%;flex-shrink:0}.section-count.svelte-1xems06{font-weight:400;opacity:.6}.empty-results.svelte-1xems06{padding:24px 16px;text-align:center;font-size:14px;color:var(--color-text-tertiary)}.results-list.svelte-1xems06 .result-row{display:flex;align-items:center;padding:6px 16px;width:100%;text-align:left;border-radius:0;height:auto;justify-content:flex-start;gap:10px}.results-list.svelte-1xems06 .result-row:hover,.results-list.svelte-1xems06 .result-row.selected{background:var(--color-bg-hover)}.result-dot.svelte-1xems06{width:8px;height:8px;border-radius:50%;flex-shrink:0}.result-body.svelte-1xems06{flex:1;min-width:0;display:flex;align-items:center;gap:8px}.result-title.svelte-1xems06{font-size:14px;font-weight:500;color:var(--color-text-primary);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.result-type.svelte-1xems06,.result-date.svelte-1xems06{font-size:12px;color:var(--color-text-tertiary);flex-shrink:0}.result-status.svelte-1xems06{font-size:11px;font-weight:500;padding:1px 6px;border-radius:3px;background:var(--color-badge-bg);color:var(--color-badge-text);flex-shrink:0}.search-footer.svelte-1xems06{display:flex;align-items:center;height:39px;padding:0 16px;gap:16px;border-top:1px solid var(--color-border);flex-shrink:0}.shortcut-group.svelte-1xems06{display:flex;align-items:center;gap:4px}.shortcut-key.svelte-1xems06{display:inline-flex;align-items:center;justify-content:center;min-width:20px;height:20px;padding:0 4px;border-radius:4px;background:var(--color-bg-surface);border:1px solid var(--color-border);color:var(--color-text-tertiary)}.shortcut-label.svelte-1xems06{font-size:12px;color:var(--color-text-tertiary);margin-left:2px}.app-frame.svelte-vr1z90{width:100vw;height:100vh;display:flex;flex-direction:column;overflow:hidden;background:var(--color-bg)}.app-body.svelte-vr1z90{flex:1;display:flex;min-height:0;overflow:hidden}.main-content.svelte-vr1z90{flex:1;display:flex;flex-direction:column;min-width:0;min-height:0;overflow:hidden}#sg-chrome-footer{flex-shrink:0}
@@ -1 +1 @@
1
- import{a as f,s as W,f as $,p as ce,c as F,b as ee,t as de}from"./A_CBh12A.js";import{i as ue}from"./knL6qj16.js";import{p as U,l as J,s as N,d as R,g as s,a as fe,c as z,n as q,r as O,b as Z,m as Q,t as G,h as A,ah as le,u as L,e as ye,f as we,i as pe}from"./BV_5EeTy.js";import{i as B}from"./BDEGO3ce.js";import{a as K,s as T}from"./kWZOPH0u.js";import{l as X,p as d,r as ve,s as me}from"./X6Q7ETGH.js";import{f as ge,n as oe,M as Me,h as x,m as se,j as xe,k as Ce,l as Ae,F as Se,o as ze,P as Oe,p as Fe,q as be,D as Re,r as Ie,s as Ve}from"./eRwSnfMR.js";import{r as he}from"./DBSXodjU.js";import{c as Y}from"./bStkEd6T.js";import{A as ke,a as Ee,b as He,c as Le,d as Ke,e as Te,f as Be,g as Ue}from"./D213c0G8.js";import{b as Pe}from"./CVUPZdJX.js";var Ze=$("<title> </title>"),De=$('<svg><!><path d="M26,4h-4V2h-2v2h-8V2h-2v2H6C4.9,4,4,4.9,4,6v20c0,1.1,0.9,2,2,2h20c1.1,0,2-0.9,2-2V6C28,4.9,27.1,4,26,4z M26,26H6V12h20 V26z M26,10H6V6h4v2h2V6h8v2h2V6h4V10z"></path></svg>');function yt(v,e){const r=X(e,["children","$$slots","$$events","$$legacy"]),_=X(r,["size","title"]);U(e,!1);const i=Q(),g=Q();let m=d(e,"size",8,16),u=d(e,"title",8,void 0);J(()=>(R(r),R(u())),()=>{N(i,r["aria-label"]||r["aria-labelledby"]||u())}),J(()=>(s(i),R(r)),()=>{N(g,{"aria-hidden":s(i)?void 0:!0,role:s(i)?"img":void 0,focusable:Number(r.tabindex)===0?!0:void 0})}),fe(),ue();var l=De();K(l,()=>({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",preserveAspectRatio:"xMidYMid meet",width:m(),height:m(),...s(g),..._}));var b=z(l);{var p=h=>{var n=Ze(),t=z(n,!0);O(n),G(()=>W(t,u())),f(h,n)};B(b,h=>{u()&&h(p)})}q(),O(l),f(v,l),Z()}var je=$("<title> </title>"),Ne=$('<svg><!><path d="M17 15 17 5 15 5 15 15 5 15 5 17 15 17 15 27 17 27 17 17 27 17 27 15 17 15z"></path></svg>');function wt(v,e){const r=X(e,["children","$$slots","$$events","$$legacy"]),_=X(r,["size","title"]);U(e,!1);const i=Q(),g=Q();let m=d(e,"size",8,16),u=d(e,"title",8,void 0);J(()=>(R(r),R(u())),()=>{N(i,r["aria-label"]||r["aria-labelledby"]||u())}),J(()=>(s(i),R(r)),()=>{N(g,{"aria-hidden":s(i)?void 0:!0,role:s(i)?"img":void 0,focusable:Number(r.tabindex)===0?!0:void 0})}),fe(),ue();var l=Ne();K(l,()=>({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",preserveAspectRatio:"xMidYMid meet",width:m(),height:m(),...s(g),..._}));var b=z(l);{var p=h=>{var n=je(),t=z(n,!0);O(n),G(()=>W(t,u())),f(h,n)};B(b,h=>{u()&&h(p)})}q(),O(l),f(v,l),Z()}var Ye=ee("<div><!></div>");function We(v,e){const r=ce();U(e,!0);let _=d(e,"ref",15,null),i=d(e,"id",19,()=>ge(r)),g=d(e,"disabled",3,!1),m=d(e,"onSelect",3,oe),u=d(e,"closeOnSelect",3,!0),l=ve(e,["$$slots","$$events","$$legacy","child","children","ref","id","disabled","onSelect","closeOnSelect"]);const b=Me.create({id:x(()=>i()),disabled:x(()=>g()),onSelect:x(()=>m()),ref:x(()=>_(),a=>_(a)),closeOnSelect:x(()=>u())}),p=L(()=>se(l,b.props));var h=F(),n=A(h);{var t=a=>{var c=F(),w=A(c);T(w,()=>e.child,()=>({props:s(p)})),f(a,c)},o=a=>{var c=Ye();K(c,()=>({...s(p)}));var w=z(c);T(w,()=>e.children??le),O(c),f(a,c)};B(n,a=>{e.child?a(t):a(o,!1)})}f(v,h),Z()}var qe=ee("<div><!></div>");function Ge(v,e){const r=ce();U(e,!0);let _=d(e,"ref",15,null),i=d(e,"id",19,()=>ge(r)),g=ve(e,["$$slots","$$events","$$legacy","ref","id","child","children"]);const m=xe.create({id:x(()=>i()),ref:x(()=>_(),n=>_(n))}),u=L(()=>se(g,m.props));var l=F(),b=A(l);{var p=n=>{var t=F(),o=A(t);T(o,()=>e.child,()=>({props:s(u)})),f(n,t)},h=n=>{var t=qe();K(t,()=>({...s(u)}));var o=z(t);T(o,()=>e.children??le),O(t),f(n,t)};B(b,n=>{e.child?n(p):n(h,!1)})}f(v,l),Z()}function Je(v,e){U(e,!0);let r=d(e,"open",15,!1),_=d(e,"dir",3,"ltr"),i=d(e,"onOpenChange",3,oe),g=d(e,"onOpenChangeComplete",3,oe),m=d(e,"_internal_variant",3,"dropdown-menu");const u=Ce.create({variant:x(()=>m()),dir:x(()=>_()),onClose:()=>{r(!1),i()(!1)}});Ae.create({open:x(()=>r(),l=>{r(l),i()(l)}),onOpenChangeComplete:x(()=>g())},u),Se(v,{children:(l,b)=>{var p=F(),h=A(p);T(h,()=>e.children??le),f(l,p)},$$slots:{default:!0}}),Z()}var Qe=ee("<div><div><!></div></div>"),Xe=ee("<div><div><!></div></div>");function $e(v,e){const r=ce();U(e,!0);let _=d(e,"id",19,()=>ge(r)),i=d(e,"ref",15,null),g=d(e,"loop",3,!0),m=d(e,"onInteractOutside",3,oe),u=d(e,"onEscapeKeydown",3,oe),l=d(e,"onCloseAutoFocus",3,oe),b=d(e,"forceMount",3,!1),p=d(e,"trapFocus",3,!1),h=ve(e,["$$slots","$$events","$$legacy","id","child","children","ref","loop","onInteractOutside","onEscapeKeydown","onCloseAutoFocus","forceMount","trapFocus","style"]);const n=ze.create({id:x(()=>_()),loop:x(()=>g()),ref:x(()=>i(),y=>i(y)),onCloseAutoFocus:x(()=>l())}),t=L(()=>se(h,n.props));function o(y){if(n.handleInteractOutside(y),!y.defaultPrevented&&(m()(y),!y.defaultPrevented)){if(y.target&&y.target instanceof Element){const te=`[${n.parentMenu.root.getBitsAttr("sub-content")}]`;if(y.target.closest(te))return}n.parentMenu.onClose()}}function a(y){u()(y),!y.defaultPrevented&&n.parentMenu.onClose()}var c=F(),w=A(c);{var S=y=>{Oe(y,me(()=>s(t),()=>n.popperProps,{get ref(){return n.opts.ref},get enabled(){return n.parentMenu.opts.open.current},onInteractOutside:o,onEscapeKeydown:a,get trapFocus(){return p()},get loop(){return g()},forceMount:!0,get id(){return _()},get shouldRender(){return n.shouldRender},popper:(re,D)=>{let ie=()=>D?.().props,I=()=>D?.().wrapperProps;const V=L(()=>se(ie(),{style:be("dropdown-menu")},{style:e.style}));var j=F(),k=A(j);{var E=M=>{var P=F(),C=A(P);{let ne=L(()=>({props:s(V),wrapperProps:I(),...n.snippetProps}));T(C,()=>e.child,()=>s(ne))}f(M,P)},H=M=>{var P=Qe();K(P,()=>({...I()}));var C=z(P);K(C,()=>({...s(V)}));var ne=z(C);T(ne,()=>e.children??le),O(C),O(P),f(M,P)};B(k,M=>{e.child?M(E):M(H,!1)})}f(re,j)},$$slots:{popper:!0}}))},ae=y=>{Fe(y,me(()=>s(t),()=>n.popperProps,{get ref(){return n.opts.ref},get open(){return n.parentMenu.opts.open.current},onInteractOutside:o,onEscapeKeydown:a,get trapFocus(){return p()},get loop(){return g()},forceMount:!1,get id(){return _()},get shouldRender(){return n.shouldRender},popper:(re,D)=>{let ie=()=>D?.().props,I=()=>D?.().wrapperProps;const V=L(()=>se(ie(),{style:be("dropdown-menu")},{style:e.style}));var j=F(),k=A(j);{var E=M=>{var P=F(),C=A(P);{let ne=L(()=>({props:s(V),wrapperProps:I(),...n.snippetProps}));T(C,()=>e.child,()=>s(ne))}f(M,P)},H=M=>{var P=Xe();K(P,()=>({...I()}));var C=z(P);K(C,()=>({...s(V)}));var ne=z(C);T(ne,()=>e.children??le),O(C),O(P),f(M,P)};B(k,M=>{e.child?M(E):M(H,!1)})}f(re,j)},$$slots:{popper:!0}}))};B(w,y=>{b()?y(S):b()||y(ae,1)})}f(v,c),Z()}var et=ee("<button><!></button>");function tt(v,e){const r=ce();U(e,!0);let _=d(e,"id",19,()=>ge(r)),i=d(e,"ref",15,null),g=d(e,"disabled",3,!1),m=d(e,"type",3,"button"),u=ve(e,["$$slots","$$events","$$legacy","id","ref","child","children","disabled","type"]);const l=Re.create({id:x(()=>_()),disabled:x(()=>g()??!1),ref:x(()=>i(),p=>i(p))}),b=L(()=>se(u,l.props,{type:m()}));Ie(v,{get id(){return _()},get ref(){return l.opts.ref},children:(p,h)=>{var n=F(),t=A(n);{var o=c=>{var w=F(),S=A(w);T(S,()=>e.child,()=>({props:s(b)})),f(c,w)},a=c=>{var w=et();K(w,()=>({...s(b)}));var S=z(w);T(S,()=>e.children??le),O(w),f(c,w)};B(t,c=>{e.child?c(o):c(a,!1)})}f(p,n)},$$slots:{default:!0}}),Z()}const Mt=Je,xt=tt,Ct=Ve,At=$e,St=We,zt=Ge;function rt(){let v=ye(we({})),e=null,r=null;function _(t,o,a){r&&(clearInterval(r),r=null),e=`${t}/${o}/${a}`,g("enter",t,o,a),r=setInterval(()=>{e&&g("heartbeat",t,o,a)},3e4)}function i(){if(r&&(clearInterval(r),r=null),e){const[t,o,a]=e.split("/");t&&o&&a&&g("leave",t,o,a),e=null}}function g(t,o,a,c){he.send({type:"presence",action:t,repo:o,entityType:a,entityId:c})}function m(t){const o=`${t.repo}/${t.entityType}/${t.entityId}`,a=s(v)[o]??[];if(t.action==="leave")s(v)[o]=a.filter(c=>c.id!==t.user.id);else{const c=a.findIndex(w=>w.id===t.user.id);c>=0?(a[c]=t.user,s(v)[o]=[...a]):s(v)[o]=[...a,t.user]}}function u(){if(N(v,{},!0),!e)return;const[t,o,a]=e.split("/");t&&o&&a&&g("enter",t,o,a)}function l(t,o,a,c){const w=`${t}/${o}/${a}`,S=s(v)[w]??[];return c?S.filter(ae=>ae.id!==c):S}function b(t,o){const a=new Map;for(const[c,w]of Object.entries(s(v)))if(c.startsWith(t))for(const S of w)(!o||S.id!==o)&&a.set(S.id,S);return[...a.values()]}function p(t,o){return b(`${t}/`,o)}function h(t){const o=new Map;for(const a of Object.values(s(v)))for(const c of a)(!t||c.id!==t)&&o.set(c.id,c);return[...o.values()]}const n=L(()=>{const t=new Map;for(const o of Object.values(s(v)))for(const a of o)t.set(a.id,a);return[...t.values()]});return{enter:_,leave:i,handlePresenceEvent:m,resetAndResend:u,getPresence:l,getPresenceByPrefix:b,getRepoPresence:p,getAllUsers:h,get allUsers(){return s(n)}}}const _e=rt();he.setPresenceHandler(v=>_e.handlePresenceEvent(v));he.addConnectHandler(()=>_e.resetAndResend());typeof window<"u"&&window.addEventListener("beforeunload",()=>_e.leave());var nt=$("<title> </title>"),at=$('<svg><!><path d="M25,12H20v2h5a1.0008,1.0008,0,0,1,1,1v2H22a3.0033,3.0033,0,0,0-3,3v1a3.0033,3.0033,0,0,0,3,3h6V15A3.0033,3.0033,0,0,0,25,12ZM22,22a1.0008,1.0008,0,0,1-1-1V20a1.0008,1.0008,0,0,1,1-1h4v3Z"></path><path d="M16,24h2L12,7H10L4,24H6l1.6936-5h6.6135ZM8.3711,17l2.4966-7.3711.2668.0005L13.63,17Z"></path></svg>');function Ot(v,e){const r=X(e,["children","$$slots","$$events","$$legacy"]),_=X(r,["size","title"]);U(e,!1);const i=Q(),g=Q();let m=d(e,"size",8,16),u=d(e,"title",8,void 0);J(()=>(R(r),R(u())),()=>{N(i,r["aria-label"]||r["aria-labelledby"]||u())}),J(()=>(s(i),R(r)),()=>{N(g,{"aria-hidden":s(i)?void 0:!0,role:s(i)?"img":void 0,focusable:Number(r.tabindex)===0?!0:void 0})}),fe(),ue();var l=at();K(l,()=>({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",preserveAspectRatio:"xMidYMid meet",width:m(),height:m(),...s(g),..._}));var b=z(l);{var p=h=>{var n=nt(),t=z(n,!0);O(n),G(()=>W(t,u())),f(h,n)};B(b,h=>{u()&&h(p)})}q(2),O(l),f(v,l),Z()}var ot=ee("<!> <!>",1),st=ee("<!> <!>",1),lt=ee("<!> <!>",1);function Ft(v,e){U(e,!0);let r=d(e,"open",15),_=d(e,"confirmLabel",3,"Confirm"),i=d(e,"cancelLabel",3,"Cancel"),g=d(e,"destructive",3,!1);var m=F(),u=A(m);Y(u,()=>Ue,(l,b)=>{b(l,{onOpenChange:p=>{p||e.oncancel()},get open(){return r()},set open(p){r(p)},children:(p,h)=>{var n=F(),t=A(n);Y(t,()=>ke,(o,a)=>{a(o,{children:(c,w)=>{var S=lt(),ae=A(S);Y(ae,()=>Ee,(te,re)=>{re(te,{children:(D,ie)=>{var I=ot(),V=A(I);Y(V,()=>He,(k,E)=>{E(k,{children:(H,M)=>{q();var P=de();G(()=>W(P,e.title)),f(H,P)},$$slots:{default:!0}})});var j=pe(V,2);Y(j,()=>Le,(k,E)=>{E(k,{children:(H,M)=>{q();var P=de();G(()=>W(P,e.message)),f(H,P)},$$slots:{default:!0}})}),f(D,I)},$$slots:{default:!0}})});var y=pe(ae,2);Y(y,()=>Ke,(te,re)=>{re(te,{children:(D,ie)=>{var I=st(),V=A(I);{let k=L(()=>Pe({variant:"ghost"}));Y(V,()=>Te,(E,H)=>{H(E,{get class(){return s(k)},get onclick(){return e.oncancel},children:(M,P)=>{q();var C=de();G(()=>W(C,i())),f(M,C)},$$slots:{default:!0}})})}var j=pe(V,2);{let k=L(()=>Pe({variant:g()?"destructive":"accent"}));Y(j,()=>Be,(E,H)=>{H(E,{get class(){return s(k)},get onclick(){return e.onconfirm},children:(M,P)=>{q();var C=de();G(()=>W(C,_())),f(M,C)},$$slots:{default:!0}})})}f(D,I)},$$slots:{default:!0}})}),f(c,S)},$$slots:{default:!0}})}),f(p,n)},$$slots:{default:!0}})}),f(v,m),Z()}var it=$("<title> </title>"),dt=$('<svg><!><path d="M16,30A14,14,0,1,1,30,16,14,14,0,0,1,16,30ZM16,4A12,12,0,1,0,28,16,12,12,0,0,0,16,4Z"></path><path d="M20.59 22 15 16.41 15 7 17 7 17 15.58 22 20.59 20.59 22z"></path></svg>');function Rt(v,e){const r=X(e,["children","$$slots","$$events","$$legacy"]),_=X(r,["size","title"]);U(e,!1);const i=Q(),g=Q();let m=d(e,"size",8,16),u=d(e,"title",8,void 0);J(()=>(R(r),R(u())),()=>{N(i,r["aria-label"]||r["aria-labelledby"]||u())}),J(()=>(s(i),R(r)),()=>{N(g,{"aria-hidden":s(i)?void 0:!0,role:s(i)?"img":void 0,focusable:Number(r.tabindex)===0?!0:void 0})}),fe(),ue();var l=dt();K(l,()=>({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",preserveAspectRatio:"xMidYMid meet",width:m(),height:m(),...s(g),..._}));var b=z(l);{var p=h=>{var n=it(),t=z(n,!0);O(n),G(()=>W(t,u())),f(h,n)};B(b,h=>{u()&&h(p)})}q(2),O(l),f(v,l),Z()}export{wt as A,At as C,St as I,Ct as P,Mt as R,zt as S,xt as T,Ot as a,yt as b,Rt as c,Ft as d,_e as p};
1
+ import{a as f,s as W,f as $,p as ce,c as F,b as ee,t as de}from"./A_CBh12A.js";import{i as ue}from"./knL6qj16.js";import{p as U,l as J,s as N,d as R,g as s,a as fe,c as z,n as q,r as O,b as Z,m as Q,t as G,h as A,ah as le,u as L,e as ye,f as we,i as pe}from"./BV_5EeTy.js";import{i as B}from"./BDEGO3ce.js";import{a as K,s as T}from"./kWZOPH0u.js";import{l as X,p as d,r as ve,s as me}from"./X6Q7ETGH.js";import{f as ge,n as oe,M as Me,h as x,m as se,j as xe,k as Ce,l as Ae,F as Se,o as ze,P as Oe,p as Fe,q as be,D as Re,r as Ie,s as Ve}from"./DgdEvonR.js";import{r as he}from"./Bfo6RqaU.js";import{c as Y}from"./bStkEd6T.js";import{A as ke,a as Ee,b as He,c as Le,d as Ke,e as Te,f as Be,g as Ue}from"./ViFs0DQu.js";import{b as Pe}from"./CVUPZdJX.js";var Ze=$("<title> </title>"),De=$('<svg><!><path d="M26,4h-4V2h-2v2h-8V2h-2v2H6C4.9,4,4,4.9,4,6v20c0,1.1,0.9,2,2,2h20c1.1,0,2-0.9,2-2V6C28,4.9,27.1,4,26,4z M26,26H6V12h20 V26z M26,10H6V6h4v2h2V6h8v2h2V6h4V10z"></path></svg>');function yt(v,e){const r=X(e,["children","$$slots","$$events","$$legacy"]),_=X(r,["size","title"]);U(e,!1);const i=Q(),g=Q();let m=d(e,"size",8,16),u=d(e,"title",8,void 0);J(()=>(R(r),R(u())),()=>{N(i,r["aria-label"]||r["aria-labelledby"]||u())}),J(()=>(s(i),R(r)),()=>{N(g,{"aria-hidden":s(i)?void 0:!0,role:s(i)?"img":void 0,focusable:Number(r.tabindex)===0?!0:void 0})}),fe(),ue();var l=De();K(l,()=>({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",preserveAspectRatio:"xMidYMid meet",width:m(),height:m(),...s(g),..._}));var b=z(l);{var p=h=>{var n=Ze(),t=z(n,!0);O(n),G(()=>W(t,u())),f(h,n)};B(b,h=>{u()&&h(p)})}q(),O(l),f(v,l),Z()}var je=$("<title> </title>"),Ne=$('<svg><!><path d="M17 15 17 5 15 5 15 15 5 15 5 17 15 17 15 27 17 27 17 17 27 17 27 15 17 15z"></path></svg>');function wt(v,e){const r=X(e,["children","$$slots","$$events","$$legacy"]),_=X(r,["size","title"]);U(e,!1);const i=Q(),g=Q();let m=d(e,"size",8,16),u=d(e,"title",8,void 0);J(()=>(R(r),R(u())),()=>{N(i,r["aria-label"]||r["aria-labelledby"]||u())}),J(()=>(s(i),R(r)),()=>{N(g,{"aria-hidden":s(i)?void 0:!0,role:s(i)?"img":void 0,focusable:Number(r.tabindex)===0?!0:void 0})}),fe(),ue();var l=Ne();K(l,()=>({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",preserveAspectRatio:"xMidYMid meet",width:m(),height:m(),...s(g),..._}));var b=z(l);{var p=h=>{var n=je(),t=z(n,!0);O(n),G(()=>W(t,u())),f(h,n)};B(b,h=>{u()&&h(p)})}q(),O(l),f(v,l),Z()}var Ye=ee("<div><!></div>");function We(v,e){const r=ce();U(e,!0);let _=d(e,"ref",15,null),i=d(e,"id",19,()=>ge(r)),g=d(e,"disabled",3,!1),m=d(e,"onSelect",3,oe),u=d(e,"closeOnSelect",3,!0),l=ve(e,["$$slots","$$events","$$legacy","child","children","ref","id","disabled","onSelect","closeOnSelect"]);const b=Me.create({id:x(()=>i()),disabled:x(()=>g()),onSelect:x(()=>m()),ref:x(()=>_(),a=>_(a)),closeOnSelect:x(()=>u())}),p=L(()=>se(l,b.props));var h=F(),n=A(h);{var t=a=>{var c=F(),w=A(c);T(w,()=>e.child,()=>({props:s(p)})),f(a,c)},o=a=>{var c=Ye();K(c,()=>({...s(p)}));var w=z(c);T(w,()=>e.children??le),O(c),f(a,c)};B(n,a=>{e.child?a(t):a(o,!1)})}f(v,h),Z()}var qe=ee("<div><!></div>");function Ge(v,e){const r=ce();U(e,!0);let _=d(e,"ref",15,null),i=d(e,"id",19,()=>ge(r)),g=ve(e,["$$slots","$$events","$$legacy","ref","id","child","children"]);const m=xe.create({id:x(()=>i()),ref:x(()=>_(),n=>_(n))}),u=L(()=>se(g,m.props));var l=F(),b=A(l);{var p=n=>{var t=F(),o=A(t);T(o,()=>e.child,()=>({props:s(u)})),f(n,t)},h=n=>{var t=qe();K(t,()=>({...s(u)}));var o=z(t);T(o,()=>e.children??le),O(t),f(n,t)};B(b,n=>{e.child?n(p):n(h,!1)})}f(v,l),Z()}function Je(v,e){U(e,!0);let r=d(e,"open",15,!1),_=d(e,"dir",3,"ltr"),i=d(e,"onOpenChange",3,oe),g=d(e,"onOpenChangeComplete",3,oe),m=d(e,"_internal_variant",3,"dropdown-menu");const u=Ce.create({variant:x(()=>m()),dir:x(()=>_()),onClose:()=>{r(!1),i()(!1)}});Ae.create({open:x(()=>r(),l=>{r(l),i()(l)}),onOpenChangeComplete:x(()=>g())},u),Se(v,{children:(l,b)=>{var p=F(),h=A(p);T(h,()=>e.children??le),f(l,p)},$$slots:{default:!0}}),Z()}var Qe=ee("<div><div><!></div></div>"),Xe=ee("<div><div><!></div></div>");function $e(v,e){const r=ce();U(e,!0);let _=d(e,"id",19,()=>ge(r)),i=d(e,"ref",15,null),g=d(e,"loop",3,!0),m=d(e,"onInteractOutside",3,oe),u=d(e,"onEscapeKeydown",3,oe),l=d(e,"onCloseAutoFocus",3,oe),b=d(e,"forceMount",3,!1),p=d(e,"trapFocus",3,!1),h=ve(e,["$$slots","$$events","$$legacy","id","child","children","ref","loop","onInteractOutside","onEscapeKeydown","onCloseAutoFocus","forceMount","trapFocus","style"]);const n=ze.create({id:x(()=>_()),loop:x(()=>g()),ref:x(()=>i(),y=>i(y)),onCloseAutoFocus:x(()=>l())}),t=L(()=>se(h,n.props));function o(y){if(n.handleInteractOutside(y),!y.defaultPrevented&&(m()(y),!y.defaultPrevented)){if(y.target&&y.target instanceof Element){const te=`[${n.parentMenu.root.getBitsAttr("sub-content")}]`;if(y.target.closest(te))return}n.parentMenu.onClose()}}function a(y){u()(y),!y.defaultPrevented&&n.parentMenu.onClose()}var c=F(),w=A(c);{var S=y=>{Oe(y,me(()=>s(t),()=>n.popperProps,{get ref(){return n.opts.ref},get enabled(){return n.parentMenu.opts.open.current},onInteractOutside:o,onEscapeKeydown:a,get trapFocus(){return p()},get loop(){return g()},forceMount:!0,get id(){return _()},get shouldRender(){return n.shouldRender},popper:(re,D)=>{let ie=()=>D?.().props,I=()=>D?.().wrapperProps;const V=L(()=>se(ie(),{style:be("dropdown-menu")},{style:e.style}));var j=F(),k=A(j);{var E=M=>{var P=F(),C=A(P);{let ne=L(()=>({props:s(V),wrapperProps:I(),...n.snippetProps}));T(C,()=>e.child,()=>s(ne))}f(M,P)},H=M=>{var P=Qe();K(P,()=>({...I()}));var C=z(P);K(C,()=>({...s(V)}));var ne=z(C);T(ne,()=>e.children??le),O(C),O(P),f(M,P)};B(k,M=>{e.child?M(E):M(H,!1)})}f(re,j)},$$slots:{popper:!0}}))},ae=y=>{Fe(y,me(()=>s(t),()=>n.popperProps,{get ref(){return n.opts.ref},get open(){return n.parentMenu.opts.open.current},onInteractOutside:o,onEscapeKeydown:a,get trapFocus(){return p()},get loop(){return g()},forceMount:!1,get id(){return _()},get shouldRender(){return n.shouldRender},popper:(re,D)=>{let ie=()=>D?.().props,I=()=>D?.().wrapperProps;const V=L(()=>se(ie(),{style:be("dropdown-menu")},{style:e.style}));var j=F(),k=A(j);{var E=M=>{var P=F(),C=A(P);{let ne=L(()=>({props:s(V),wrapperProps:I(),...n.snippetProps}));T(C,()=>e.child,()=>s(ne))}f(M,P)},H=M=>{var P=Xe();K(P,()=>({...I()}));var C=z(P);K(C,()=>({...s(V)}));var ne=z(C);T(ne,()=>e.children??le),O(C),O(P),f(M,P)};B(k,M=>{e.child?M(E):M(H,!1)})}f(re,j)},$$slots:{popper:!0}}))};B(w,y=>{b()?y(S):b()||y(ae,1)})}f(v,c),Z()}var et=ee("<button><!></button>");function tt(v,e){const r=ce();U(e,!0);let _=d(e,"id",19,()=>ge(r)),i=d(e,"ref",15,null),g=d(e,"disabled",3,!1),m=d(e,"type",3,"button"),u=ve(e,["$$slots","$$events","$$legacy","id","ref","child","children","disabled","type"]);const l=Re.create({id:x(()=>_()),disabled:x(()=>g()??!1),ref:x(()=>i(),p=>i(p))}),b=L(()=>se(u,l.props,{type:m()}));Ie(v,{get id(){return _()},get ref(){return l.opts.ref},children:(p,h)=>{var n=F(),t=A(n);{var o=c=>{var w=F(),S=A(w);T(S,()=>e.child,()=>({props:s(b)})),f(c,w)},a=c=>{var w=et();K(w,()=>({...s(b)}));var S=z(w);T(S,()=>e.children??le),O(w),f(c,w)};B(t,c=>{e.child?c(o):c(a,!1)})}f(p,n)},$$slots:{default:!0}}),Z()}const Mt=Je,xt=tt,Ct=Ve,At=$e,St=We,zt=Ge;function rt(){let v=ye(we({})),e=null,r=null;function _(t,o,a){r&&(clearInterval(r),r=null),e=`${t}/${o}/${a}`,g("enter",t,o,a),r=setInterval(()=>{e&&g("heartbeat",t,o,a)},3e4)}function i(){if(r&&(clearInterval(r),r=null),e){const[t,o,a]=e.split("/");t&&o&&a&&g("leave",t,o,a),e=null}}function g(t,o,a,c){he.send({type:"presence",action:t,repo:o,entityType:a,entityId:c})}function m(t){const o=`${t.repo}/${t.entityType}/${t.entityId}`,a=s(v)[o]??[];if(t.action==="leave")s(v)[o]=a.filter(c=>c.id!==t.user.id);else{const c=a.findIndex(w=>w.id===t.user.id);c>=0?(a[c]=t.user,s(v)[o]=[...a]):s(v)[o]=[...a,t.user]}}function u(){if(N(v,{},!0),!e)return;const[t,o,a]=e.split("/");t&&o&&a&&g("enter",t,o,a)}function l(t,o,a,c){const w=`${t}/${o}/${a}`,S=s(v)[w]??[];return c?S.filter(ae=>ae.id!==c):S}function b(t,o){const a=new Map;for(const[c,w]of Object.entries(s(v)))if(c.startsWith(t))for(const S of w)(!o||S.id!==o)&&a.set(S.id,S);return[...a.values()]}function p(t,o){return b(`${t}/`,o)}function h(t){const o=new Map;for(const a of Object.values(s(v)))for(const c of a)(!t||c.id!==t)&&o.set(c.id,c);return[...o.values()]}const n=L(()=>{const t=new Map;for(const o of Object.values(s(v)))for(const a of o)t.set(a.id,a);return[...t.values()]});return{enter:_,leave:i,handlePresenceEvent:m,resetAndResend:u,getPresence:l,getPresenceByPrefix:b,getRepoPresence:p,getAllUsers:h,get allUsers(){return s(n)}}}const _e=rt();he.setPresenceHandler(v=>_e.handlePresenceEvent(v));he.addConnectHandler(()=>_e.resetAndResend());typeof window<"u"&&window.addEventListener("beforeunload",()=>_e.leave());var nt=$("<title> </title>"),at=$('<svg><!><path d="M25,12H20v2h5a1.0008,1.0008,0,0,1,1,1v2H22a3.0033,3.0033,0,0,0-3,3v1a3.0033,3.0033,0,0,0,3,3h6V15A3.0033,3.0033,0,0,0,25,12ZM22,22a1.0008,1.0008,0,0,1-1-1V20a1.0008,1.0008,0,0,1,1-1h4v3Z"></path><path d="M16,24h2L12,7H10L4,24H6l1.6936-5h6.6135ZM8.3711,17l2.4966-7.3711.2668.0005L13.63,17Z"></path></svg>');function Ot(v,e){const r=X(e,["children","$$slots","$$events","$$legacy"]),_=X(r,["size","title"]);U(e,!1);const i=Q(),g=Q();let m=d(e,"size",8,16),u=d(e,"title",8,void 0);J(()=>(R(r),R(u())),()=>{N(i,r["aria-label"]||r["aria-labelledby"]||u())}),J(()=>(s(i),R(r)),()=>{N(g,{"aria-hidden":s(i)?void 0:!0,role:s(i)?"img":void 0,focusable:Number(r.tabindex)===0?!0:void 0})}),fe(),ue();var l=at();K(l,()=>({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",preserveAspectRatio:"xMidYMid meet",width:m(),height:m(),...s(g),..._}));var b=z(l);{var p=h=>{var n=nt(),t=z(n,!0);O(n),G(()=>W(t,u())),f(h,n)};B(b,h=>{u()&&h(p)})}q(2),O(l),f(v,l),Z()}var ot=ee("<!> <!>",1),st=ee("<!> <!>",1),lt=ee("<!> <!>",1);function Ft(v,e){U(e,!0);let r=d(e,"open",15),_=d(e,"confirmLabel",3,"Confirm"),i=d(e,"cancelLabel",3,"Cancel"),g=d(e,"destructive",3,!1);var m=F(),u=A(m);Y(u,()=>Ue,(l,b)=>{b(l,{onOpenChange:p=>{p||e.oncancel()},get open(){return r()},set open(p){r(p)},children:(p,h)=>{var n=F(),t=A(n);Y(t,()=>ke,(o,a)=>{a(o,{children:(c,w)=>{var S=lt(),ae=A(S);Y(ae,()=>Ee,(te,re)=>{re(te,{children:(D,ie)=>{var I=ot(),V=A(I);Y(V,()=>He,(k,E)=>{E(k,{children:(H,M)=>{q();var P=de();G(()=>W(P,e.title)),f(H,P)},$$slots:{default:!0}})});var j=pe(V,2);Y(j,()=>Le,(k,E)=>{E(k,{children:(H,M)=>{q();var P=de();G(()=>W(P,e.message)),f(H,P)},$$slots:{default:!0}})}),f(D,I)},$$slots:{default:!0}})});var y=pe(ae,2);Y(y,()=>Ke,(te,re)=>{re(te,{children:(D,ie)=>{var I=st(),V=A(I);{let k=L(()=>Pe({variant:"ghost"}));Y(V,()=>Te,(E,H)=>{H(E,{get class(){return s(k)},get onclick(){return e.oncancel},children:(M,P)=>{q();var C=de();G(()=>W(C,i())),f(M,C)},$$slots:{default:!0}})})}var j=pe(V,2);{let k=L(()=>Pe({variant:g()?"destructive":"accent"}));Y(j,()=>Be,(E,H)=>{H(E,{get class(){return s(k)},get onclick(){return e.onconfirm},children:(M,P)=>{q();var C=de();G(()=>W(C,_())),f(M,C)},$$slots:{default:!0}})})}f(D,I)},$$slots:{default:!0}})}),f(c,S)},$$slots:{default:!0}})}),f(p,n)},$$slots:{default:!0}})}),f(v,m),Z()}var it=$("<title> </title>"),dt=$('<svg><!><path d="M16,30A14,14,0,1,1,30,16,14,14,0,0,1,16,30ZM16,4A12,12,0,1,0,28,16,12,12,0,0,0,16,4Z"></path><path d="M20.59 22 15 16.41 15 7 17 7 17 15.58 22 20.59 20.59 22z"></path></svg>');function Rt(v,e){const r=X(e,["children","$$slots","$$events","$$legacy"]),_=X(r,["size","title"]);U(e,!1);const i=Q(),g=Q();let m=d(e,"size",8,16),u=d(e,"title",8,void 0);J(()=>(R(r),R(u())),()=>{N(i,r["aria-label"]||r["aria-labelledby"]||u())}),J(()=>(s(i),R(r)),()=>{N(g,{"aria-hidden":s(i)?void 0:!0,role:s(i)?"img":void 0,focusable:Number(r.tabindex)===0?!0:void 0})}),fe(),ue();var l=dt();K(l,()=>({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",preserveAspectRatio:"xMidYMid meet",width:m(),height:m(),...s(g),..._}));var b=z(l);{var p=h=>{var n=it(),t=z(n,!0);O(n),G(()=>W(t,u())),f(h,n)};B(b,h=>{u()&&h(p)})}q(2),O(l),f(v,l),Z()}export{wt as A,At as C,St as I,Ct as P,Mt as R,zt as S,xt as T,Ot as a,yt as b,Rt as c,Ft as d,_e as p};
@@ -1,2 +1,2 @@
1
1
  const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./DYjiTWHA.js","./BV_5EeTy.js","./BsrRU3u_.js","./CX29MJnv.js"])))=>i.map(i=>d[i]);
2
- import{_ as J}from"./PPVm8Dsz.js";import{g as S,s as a,e as T}from"./BV_5EeTy.js";import{i as M}from"./TyzEVmmX.js";import{h as I,w as l}from"./BsrRU3u_.js";import{a as j}from"./CE4jaZ4F.js";import{n as h}from"./tl7OBIop.js";import{t as s}from"./BAv2eo78.js";const F=800;function L(){let t=T(!1),n=T(null),e=T(null),r=null,o=null,m=!1;function U(u,p,d,c){r&&r.repo===u&&r.type===p&&r.id===d?(c.data!==void 0&&(r.payload.data=c.data),c.content!==void 0&&(r.payload.content=c.content)):r={repo:u,type:p,id:d,payload:{...c}},B()}function B(){o&&clearTimeout(o),o=setTimeout(b,F)}async function b(){if(o=null,!m&&r){const{repo:u,type:p,id:d,payload:c}=r;r=null,m=!0,a(t,!0),a(e,null);try{if(await I(u,p,d,c),a(n,new Date,!0),c.data?.name){const g=l.repos.find(O=>O.name===u)?.entities.find(O=>O.id===d);g&&(g.title=c.data.name)}}catch(f){a(e,f.message??"Save failed",!0);const g=f.status??f.statusCode;(!g||g>=500)&&(r={repo:u,type:p,id:d,payload:c})}finally{a(t,!1),m=!1,r&&b()}}}function R(){o&&(clearTimeout(o),o=null),r&&b()}async function W(u,p,d,c){a(t,!0),a(e,null);try{const f=await I(u,p,d,c);return a(n,new Date,!0),f}catch(f){return a(e,f.message??"Save failed",!0),null}finally{a(t,!1)}}function x(){a(e,null),a(n,null),r=null,o&&(clearTimeout(o),o=null)}return{get saving(){return S(t)},get lastSaved(){return S(n)},get error(){return S(e)},get hasPending(){return!!(r||m)},scheduleAutoSave:U,flush:R,saveEntity:W,reset:x}}const V=L();let i=null,D=null,P=null,k=[],E=null,w=1e3,_=T(!1),C=T(null);const y=new Map,$={},A={};function N(t,n){y.delete(t);const e=n.entities.length,r=e===1?`${t} updated ${n.entities[0]}`:`${t} updated ${e} entities`;s(r)}function G(t){for(const[n,e]of y)e.repo===t&&(clearTimeout(e.timer),y.delete(n))}function Y(t){const n=j.user?.displayName;if(t.type==="sync_progress"){const e=$[t.repo];if(e){const r=t.message.trim(),o=r.match(/^Syncing from source:\s*(.+)$/i);o&&(A[t.repo]=`Syncing ${o[1].trim()}…`);const m=A[t.repo]??`Syncing ${t.repo}…`;s.loading(m,{id:e,description:r,duration:36e5})}return}if(t.type==="entity_change"){if(n&&t.actor===n&&t.source==="api"){l.refreshEntities(t.repo);return}if(l.refreshEntities(t.repo),h.selectedRepo===t.repo&&h.selectedType===t.entityType&&h.selectedId===t.entityId){V.hasPending?s(`${t.actor} also saved changes to this entity`):M();return}const r=y.get(t.actor);if(r)clearTimeout(r.timer),r.entities.includes(t.entityId)||r.entities.push(t.entityId),r.timer=setTimeout(()=>N(t.actor,r),1e4);else{const o={entities:[t.entityId],repo:t.repo,timer:setTimeout(()=>N(t.actor,o),1e4)};y.set(t.actor,o)}return}if(t.type==="session_commit"){if(n&&t.actor===n){a(C,t.timestamp,!0);return}const e=t.entities.length,r=e===1?`${t.actor} saved changes to ${t.entities[0]}`:`${t.actor} saved ${e} changes in ${t.repo}`;s(r),l.refreshEntities(t.repo);return}if(t.type==="sync_complete"){if(G(t.repo),!$[t.repo]){const e=t.created+t.updated+t.deleted,r=e===0?`Sync complete · no changes in ${t.repo}`:`Sync complete · ${e} ${e===1?"entity":"entities"} from ${t.source}`;s.success(r)}l.refreshEntities(t.repo);return}if(t.type==="collection_created"){s(`${t.actor} created collection ${t.repo}`),l.refreshEntities(t.repo);return}if(t.type==="collection_deleted"){s(`${t.actor} deleted collection ${t.repo}`);return}if(t.type==="repo_sync"){s(`${t.actor} pushed to ${t.repo}`),l.refreshEntities(t.repo);return}if(t.type==="presence"){D?.(t);return}if(t.type==="online"){P?.(t);return}if(t.type==="insights_updated"){J(()=>import("./DYjiTWHA.js"),__vite__mapDeps([0,1,2,3]),import.meta.url).then(e=>e.insightsStore.load());return}if(t.type==="access_granted"||t.type==="access_revoked"){t.type==="access_revoked"&&h.selectedRepo===t.repo&&h.deselect(),l.load();return}}function H(){if(typeof window>"u"||i&&(i.readyState===WebSocket.OPEN||i.readyState===WebSocket.CONNECTING))return;const n=`${window.location.protocol==="https:"?"wss:":"ws:"}//${window.location.host}/ws`;i=new WebSocket(n),i.binaryType="arraybuffer",i.onopen=()=>{a(_,!0),w=1e3,l.refreshAll();for(const e of k)e()},i.onmessage=e=>{if(!(e.data instanceof ArrayBuffer))try{const r=JSON.parse(e.data);if(r?.type==="ping"){i?.send(JSON.stringify({type:"pong"}));return}const o=r;o.type&&o.type!=="toast"&&Y(o)}catch{}},i.onclose=()=>{a(_,!1),i=null,E=setTimeout(()=>{w=Math.min(w*2,1e4),H()},w)},i.onerror=()=>{}}function q(){E&&(clearTimeout(E),E=null),i&&(i.close(),i=null),a(_,!1);for(const[,t]of y)clearTimeout(t.timer);y.clear()}function z(t,n=4e3){s(t,{duration:n})}function K(t,n){const e=crypto.randomUUID();return n?.loading?s.loading(t,{id:e,duration:36e5}):s(t,{id:e}),e}function Q(t,n,e){if(e?.loading){s.loading(n,{id:t});return}/failed|error/i.test(n)?s.error(n,{id:t,duration:e?.duration??6e3}):s.success(n,{id:t,duration:e?.duration??4e3})}function X(t){const n=crypto.randomUUID();$[t]=n,s.loading(`Syncing ${t}…`,{id:n,duration:36e5})}function Z(t,n,e){const r=$[t];r&&(delete $[t],delete A[t],e?s.error(n,{id:r,duration:6e3}):s.success(n,{id:r,duration:4e3}))}function v(t){D=t}function tt(t){P=t}function et(t){k.push(t)}function rt(t){i?.readyState===WebSocket.OPEN&&i.send(JSON.stringify(t))}const ut={get connected(){return S(_)},get lastAutoSaved(){return S(C)},get ws(){return i},connect:H,disconnect:q,showToast:z,showPersistentToast:K,updateToast:Q,startSyncToast:X,finishSyncToast:Z,send:rt,setPresenceHandler:v,setOnlineHandler:tt,addConnectHandler:et};export{V as e,ut as r};
2
+ import{_ as J}from"./PPVm8Dsz.js";import{g as S,s as a,e as T}from"./BV_5EeTy.js";import{i as M}from"./DnwCyrLk.js";import{h as I,w as l}from"./BsrRU3u_.js";import{a as j}from"./CE4jaZ4F.js";import{n as h}from"./tl7OBIop.js";import{t as s}from"./BAv2eo78.js";const F=800;function L(){let t=T(!1),n=T(null),e=T(null),r=null,o=null,m=!1;function U(u,p,d,c){r&&r.repo===u&&r.type===p&&r.id===d?(c.data!==void 0&&(r.payload.data=c.data),c.content!==void 0&&(r.payload.content=c.content)):r={repo:u,type:p,id:d,payload:{...c}},B()}function B(){o&&clearTimeout(o),o=setTimeout(b,F)}async function b(){if(o=null,!m&&r){const{repo:u,type:p,id:d,payload:c}=r;r=null,m=!0,a(t,!0),a(e,null);try{if(await I(u,p,d,c),a(n,new Date,!0),c.data?.name){const g=l.repos.find(O=>O.name===u)?.entities.find(O=>O.id===d);g&&(g.title=c.data.name)}}catch(f){a(e,f.message??"Save failed",!0);const g=f.status??f.statusCode;(!g||g>=500)&&(r={repo:u,type:p,id:d,payload:c})}finally{a(t,!1),m=!1,r&&b()}}}function R(){o&&(clearTimeout(o),o=null),r&&b()}async function W(u,p,d,c){a(t,!0),a(e,null);try{const f=await I(u,p,d,c);return a(n,new Date,!0),f}catch(f){return a(e,f.message??"Save failed",!0),null}finally{a(t,!1)}}function x(){a(e,null),a(n,null),r=null,o&&(clearTimeout(o),o=null)}return{get saving(){return S(t)},get lastSaved(){return S(n)},get error(){return S(e)},get hasPending(){return!!(r||m)},scheduleAutoSave:U,flush:R,saveEntity:W,reset:x}}const V=L();let i=null,D=null,P=null,k=[],E=null,w=1e3,_=T(!1),C=T(null);const y=new Map,$={},A={};function N(t,n){y.delete(t);const e=n.entities.length,r=e===1?`${t} updated ${n.entities[0]}`:`${t} updated ${e} entities`;s(r)}function G(t){for(const[n,e]of y)e.repo===t&&(clearTimeout(e.timer),y.delete(n))}function Y(t){const n=j.user?.displayName;if(t.type==="sync_progress"){const e=$[t.repo];if(e){const r=t.message.trim(),o=r.match(/^Syncing from source:\s*(.+)$/i);o&&(A[t.repo]=`Syncing ${o[1].trim()}…`);const m=A[t.repo]??`Syncing ${t.repo}…`;s.loading(m,{id:e,description:r,duration:36e5})}return}if(t.type==="entity_change"){if(n&&t.actor===n&&t.source==="api"){l.refreshEntities(t.repo);return}if(l.refreshEntities(t.repo),h.selectedRepo===t.repo&&h.selectedType===t.entityType&&h.selectedId===t.entityId){V.hasPending?s(`${t.actor} also saved changes to this entity`):M();return}const r=y.get(t.actor);if(r)clearTimeout(r.timer),r.entities.includes(t.entityId)||r.entities.push(t.entityId),r.timer=setTimeout(()=>N(t.actor,r),1e4);else{const o={entities:[t.entityId],repo:t.repo,timer:setTimeout(()=>N(t.actor,o),1e4)};y.set(t.actor,o)}return}if(t.type==="session_commit"){if(n&&t.actor===n){a(C,t.timestamp,!0);return}const e=t.entities.length,r=e===1?`${t.actor} saved changes to ${t.entities[0]}`:`${t.actor} saved ${e} changes in ${t.repo}`;s(r),l.refreshEntities(t.repo);return}if(t.type==="sync_complete"){if(G(t.repo),!$[t.repo]){const e=t.created+t.updated+t.deleted,r=e===0?`Sync complete · no changes in ${t.repo}`:`Sync complete · ${e} ${e===1?"entity":"entities"} from ${t.source}`;s.success(r)}l.refreshEntities(t.repo);return}if(t.type==="collection_created"){s(`${t.actor} created collection ${t.repo}`),l.refreshEntities(t.repo);return}if(t.type==="collection_deleted"){s(`${t.actor} deleted collection ${t.repo}`);return}if(t.type==="repo_sync"){s(`${t.actor} pushed to ${t.repo}`),l.refreshEntities(t.repo);return}if(t.type==="presence"){D?.(t);return}if(t.type==="online"){P?.(t);return}if(t.type==="insights_updated"){J(()=>import("./DYjiTWHA.js"),__vite__mapDeps([0,1,2,3]),import.meta.url).then(e=>e.insightsStore.load());return}if(t.type==="access_granted"||t.type==="access_revoked"){t.type==="access_revoked"&&h.selectedRepo===t.repo&&h.deselect(),l.load();return}}function H(){if(typeof window>"u"||i&&(i.readyState===WebSocket.OPEN||i.readyState===WebSocket.CONNECTING))return;const n=`${window.location.protocol==="https:"?"wss:":"ws:"}//${window.location.host}/ws`;i=new WebSocket(n),i.binaryType="arraybuffer",i.onopen=()=>{a(_,!0),w=1e3,l.refreshAll();for(const e of k)e()},i.onmessage=e=>{if(!(e.data instanceof ArrayBuffer))try{const r=JSON.parse(e.data);if(r?.type==="ping"){i?.send(JSON.stringify({type:"pong"}));return}const o=r;o.type&&o.type!=="toast"&&Y(o)}catch{}},i.onclose=()=>{a(_,!1),i=null,E=setTimeout(()=>{w=Math.min(w*2,1e4),H()},w)},i.onerror=()=>{}}function q(){E&&(clearTimeout(E),E=null),i&&(i.close(),i=null),a(_,!1);for(const[,t]of y)clearTimeout(t.timer);y.clear()}function z(t,n=4e3){s(t,{duration:n})}function K(t,n){const e=crypto.randomUUID();return n?.loading?s.loading(t,{id:e,duration:36e5}):s(t,{id:e}),e}function Q(t,n,e){if(e?.loading){s.loading(n,{id:t});return}/failed|error/i.test(n)?s.error(n,{id:t,duration:e?.duration??6e3}):s.success(n,{id:t,duration:e?.duration??4e3})}function X(t){const n=crypto.randomUUID();$[t]=n,s.loading(`Syncing ${t}…`,{id:n,duration:36e5})}function Z(t,n,e){const r=$[t];r&&(delete $[t],delete A[t],e?s.error(n,{id:r,duration:6e3}):s.success(n,{id:r,duration:4e3}))}function v(t){D=t}function tt(t){P=t}function et(t){k.push(t)}function rt(t){i?.readyState===WebSocket.OPEN&&i.send(JSON.stringify(t))}const ut={get connected(){return S(_)},get lastAutoSaved(){return S(C)},get ws(){return i},connect:H,disconnect:q,showToast:z,showPersistentToast:K,updateToast:Q,startSyncToast:X,finishSyncToast:Z,send:rt,setPresenceHandler:v,setOnlineHandler:tt,addConnectHandler:et};export{V as e,ut as r};
@@ -0,0 +1 @@
1
+ import{o as Kt,c as x,a as p,p as dt,b as B,s as ht,f as It}from"./A_CBh12A.js";import{u as h,g as o,aa as ut,a3 as Ft,s as u,e as V,a9 as Lt,p as U,h as C,b as W,c as E,ah as tt,r as K,i as ct,l as Nt,d as rt,a as Bt,n as Ut,m as _t,t as lt}from"./BV_5EeTy.js";import{s as D,a as J}from"./kWZOPH0u.js";import{i as F}from"./BDEGO3ce.js";import{p as r,s as et,r as ot,l as Ct}from"./X6Q7ETGH.js";import{L as Wt,N as zt,C as xt,a as gt,A as pt,O as qt,Q as X,R as j,E as wt,S as nt,U as Pt,V as Ht,W as Ot,X as Tt,Y as kt,Z as Yt,_ as Gt,$ as Jt,a0 as Qt,b as Mt,G as At,c as Xt,a1 as Zt,w as Q,q as jt,a2 as $t,a3 as St,a4 as Rt,J as te,h as v,d as ee,H as oe,f as ft,n as q,P as se,p as ie,m as $,F as re,r as ne,s as ae}from"./DgdEvonR.js";import{c as it}from"./bStkEd6T.js";import{c as Vt}from"./CVUPZdJX.js";import{i as he}from"./knL6qj16.js";import{e as le}from"./CI5sVAIC.js";class de{#t=()=>{};#e=h(()=>this.#t());constructor(t,e){let s;e!==void 0&&(s=e),this.#t=()=>{try{return s}finally{s=t()}}}get current(){return o(this.#e)}}function ue(b){ut(()=>Ft(()=>b()))}class ce{#t;#e=h(()=>this.#t.candidateValues());#o;constructor(t){this.#t=t,this.#o=Wt("",{afterMs:1e3,getWindow:this.#t.getWindow}),this.handleTypeaheadSearch=this.handleTypeaheadSearch.bind(this),this.resetTypeahead=this.resetTypeahead.bind(this)}handleTypeaheadSearch(t){if(!this.#t.enabled()||!o(this.#e).length)return;this.#o.current=this.#o.current+t;const e=this.#t.getCurrentItem(),s=o(this.#e).find(a=>a===e)??"",n=o(this.#e).map(a=>a??""),l=zt(n,this.#o.current,s),i=o(this.#e).find(a=>a===l);return i&&this.#t.onMatch(i),i}resetTypeahead(){this.#o.current=""}}const ge=[j,Ht,Ot],pe=[X,Tt,kt],fe=[...ge,...pe],ve=ee({component:"select",parts:["trigger","content","item","viewport","scroll-up-button","scroll-down-button","group","group-label","separator","arrow","input","content-wrapper","item-text","value"]}),st=new xt("Select.Root | Combobox.Root"),me=new xt("Select.Content | Combobox.Content");class Dt{opts;#t=V(!1);get touchedInput(){return o(this.#t)}set touchedInput(t){u(this.#t,t,!0)}#e=V(null);get inputNode(){return o(this.#e)}set inputNode(t){u(this.#e,t,!0)}#o=V(null);get contentNode(){return o(this.#o)}set contentNode(t){u(this.#o,t,!0)}contentPresence;#s=V(null);get viewportNode(){return o(this.#s)}set viewportNode(t){u(this.#s,t,!0)}#i=V(null);get triggerNode(){return o(this.#i)}set triggerNode(t){u(this.#i,t,!0)}#r=V("");get valueId(){return o(this.#r)}set valueId(t){u(this.#r,t,!0)}#n=V(null);get highlightedNode(){return o(this.#n)}set highlightedNode(t){u(this.#n,t,!0)}#a=h(()=>this.highlightedNode?this.highlightedNode.getAttribute("data-value"):null);get highlightedValue(){return o(this.#a)}set highlightedValue(t){u(this.#a,t)}#h=h(()=>{if(this.highlightedNode)return this.highlightedNode.id});get highlightedId(){return o(this.#h)}set highlightedId(t){u(this.#h,t)}#l=h(()=>this.highlightedNode?this.highlightedNode.getAttribute("data-label"):null);get highlightedLabel(){return o(this.#l)}set highlightedLabel(t){u(this.#l,t)}#d=V(!1);get contentIsPositioned(){return o(this.#d)}set contentIsPositioned(t){u(this.#d,t,!0)}isUsingKeyboard=!1;isCombobox=!1;domContext=new pt(()=>null);constructor(t){this.opts=t,this.isCombobox=t.isCombobox,this.contentPresence=new te({ref:v(()=>this.contentNode),open:this.opts.open,onComplete:()=>{this.opts.onOpenChangeComplete.current(this.opts.open.current)}}),Lt(()=>{this.opts.open.current||this.setHighlightedNode(null)})}setHighlightedNode(t,e=!1){this.highlightedNode=t,t&&(this.isUsingKeyboard||e)&&this.scrollHighlightedNodeIntoView(t)}scrollHighlightedNodeIntoView(t){!this.viewportNode||!this.contentIsPositioned||t.scrollIntoView({block:this.opts.scrollAlignment.current})}getCandidateNodes(){const t=this.contentNode;return t?Array.from(t.querySelectorAll(`[${this.getBitsAttr("item")}]:not([data-disabled])`)):[]}setHighlightedToFirstCandidate(t=!1){this.setHighlightedNode(null);let e=this.getCandidateNodes();if(e.length){if(this.viewportNode){const s=this.viewportNode.getBoundingClientRect();e=e.filter(n=>{if(!this.viewportNode)return!1;const l=n.getBoundingClientRect();return l.right<=s.right&&l.left>=s.left&&l.bottom<=s.bottom&&l.top>=s.top})}this.setHighlightedNode(e[0],t)}}getNodeByValue(t){return this.getCandidateNodes().find(s=>s.dataset.value===t)??null}setOpen(t){this.opts.open.current=t}toggleOpen(){this.opts.open.current=!this.opts.open.current}handleOpen(){this.setOpen(!0)}handleClose(){this.setHighlightedNode(null),this.setOpen(!1)}toggleMenu(){this.toggleOpen()}getBitsAttr=t=>ve.getAttr(t,this.isCombobox?"combobox":void 0)}class be extends Dt{opts;isMulti=!1;#t=h(()=>this.opts.value.current!=="");get hasValue(){return o(this.#t)}set hasValue(t){u(this.#t,t)}#e=h(()=>this.opts.items.current.length?this.opts.items.current.find(t=>t.value===this.opts.value.current)?.label??"":"");get currentLabel(){return o(this.#e)}set currentLabel(t){u(this.#e,t)}#o=h(()=>this.opts.items.current.length?this.opts.items.current.filter(e=>!e.disabled).map(e=>e.label):[]);get candidateLabels(){return o(this.#o)}set candidateLabels(t){u(this.#o,t)}#s=h(()=>!(this.isMulti||this.opts.items.current.length===0));get dataTypeaheadEnabled(){return o(this.#s)}set dataTypeaheadEnabled(t){u(this.#s,t)}constructor(t){super(t),this.opts=t,ut(()=>{!this.opts.open.current&&this.highlightedNode&&this.setHighlightedNode(null)}),Q(()=>this.opts.open.current,()=>{this.opts.open.current&&this.setInitialHighlightedNode()})}includesItem(t){return this.opts.value.current===t}toggleItem(t,e=t){const s=this.includesItem(t)?"":t;this.opts.value.current=s,s!==""&&(this.opts.inputValue.current=e)}setInitialHighlightedNode(){Rt(()=>{if(!(this.highlightedNode&&this.domContext.getDocument().contains(this.highlightedNode))){if(this.opts.value.current!==""){const t=this.getNodeByValue(this.opts.value.current);if(t){this.setHighlightedNode(t,!0);return}}this.setHighlightedToFirstCandidate(!0)}})}}class ye extends Dt{opts;isMulti=!0;#t=h(()=>this.opts.value.current.length>0);get hasValue(){return o(this.#t)}set hasValue(t){u(this.#t,t)}constructor(t){super(t),this.opts=t,ut(()=>{!this.opts.open.current&&this.highlightedNode&&this.setHighlightedNode(null)}),Q(()=>this.opts.open.current,()=>{this.opts.open.current&&this.setInitialHighlightedNode()})}includesItem(t){return this.opts.value.current.includes(t)}toggleItem(t,e=t){this.includesItem(t)?this.opts.value.current=this.opts.value.current.filter(s=>s!==t):this.opts.value.current=[...this.opts.value.current,t],this.opts.inputValue.current=e}setInitialHighlightedNode(){Rt(()=>{if(this.domContext&&!(this.highlightedNode&&this.domContext.getDocument().contains(this.highlightedNode))){if(this.opts.value.current.length&&this.opts.value.current[0]!==""){const t=this.getNodeByValue(this.opts.value.current[0]);if(t){this.setHighlightedNode(t,!0);return}}this.setHighlightedToFirstCandidate(!0)}})}}class Ne{static create(t){const{type:e,...s}=t,n=e==="single"?new be(s):new ye(s);return st.set(n)}}class vt{static create(t){return new vt(t,st.get())}opts;root;attachment;#t;#e;constructor(t,e){this.opts=t,this.root=e,this.attachment=gt(t.ref,s=>this.root.triggerNode=s),this.root.domContext=new pt(t.ref),this.#t=new qt({getCurrentItem:()=>this.root.highlightedNode,onMatch:s=>{this.root.setHighlightedNode(s)},getActiveElement:()=>this.root.domContext.getActiveElement(),getWindow:()=>this.root.domContext.getWindow()}),this.#e=new ce({getCurrentItem:()=>this.root.isMulti?"":this.root.currentLabel,onMatch:s=>{if(this.root.isMulti||!this.root.opts.items.current)return;const n=this.root.opts.items.current.find(l=>l.label===s);n&&(this.root.opts.value.current=n.value)},enabled:()=>!this.root.isMulti&&this.root.dataTypeaheadEnabled,candidateValues:()=>this.root.isMulti?[]:this.root.candidateLabels,getWindow:()=>this.root.domContext.getWindow()}),this.onkeydown=this.onkeydown.bind(this),this.onpointerdown=this.onpointerdown.bind(this),this.onpointerup=this.onpointerup.bind(this),this.onclick=this.onclick.bind(this)}#o(){this.root.opts.open.current=!0,this.#e.resetTypeahead(),this.#t.resetTypeahead()}#s(t){this.#o()}#i(){const t=this.root.highlightedValue===this.root.opts.value.current;return!this.root.opts.allowDeselect.current&&t&&!this.root.isMulti?(this.root.handleClose(),!0):(this.root.highlightedValue!==null&&this.root.toggleItem(this.root.highlightedValue,this.root.highlightedLabel??void 0),!this.root.isMulti&&!t?(this.root.handleClose(),!0):!1)}onkeydown(t){if(this.root.isUsingKeyboard=!0,(t.key===X||t.key===j)&&t.preventDefault(),!this.root.opts.open.current){if(t.key===wt||t.key===nt||t.key===j||t.key===X)t.preventDefault(),this.root.handleOpen();else if(!this.root.isMulti&&this.root.dataTypeaheadEnabled){this.#e.handleTypeaheadSearch(t.key);return}if(this.root.hasValue)return;const i=this.root.getCandidateNodes();if(!i.length)return;if(t.key===j){const a=i[0];this.root.setHighlightedNode(a)}else if(t.key===X){const a=i[i.length-1];this.root.setHighlightedNode(a)}return}if(t.key===Pt){this.root.handleClose();return}if((t.key===wt||t.key===nt&&this.#t.search==="")&&!t.isComposing&&(t.preventDefault(),this.#i()))return;if(t.key===X&&t.altKey&&this.root.handleClose(),fe.includes(t.key)){t.preventDefault();const i=this.root.getCandidateNodes(),a=this.root.highlightedNode,y=a?i.indexOf(a):-1,w=this.root.opts.loop.current;let m;if(t.key===j?m=Yt(i,y,w):t.key===X?m=Gt(i,y,w):t.key===Tt?m=Jt(i,y,10,w):t.key===Ht?m=Qt(i,y,10,w):t.key===Ot?m=i[0]:t.key===kt&&(m=i[i.length-1]),!m)return;this.root.setHighlightedNode(m);return}const e=t.ctrlKey||t.altKey||t.metaKey,s=t.key.length===1,n=t.key===nt,l=this.root.getCandidateNodes();if(t.key!==Pt){if(!e&&(s||n)){!this.#t.handleTypeaheadSearch(t.key,l)&&n&&(t.preventDefault(),this.#i());return}this.root.highlightedNode||this.root.setHighlightedToFirstCandidate()}}onclick(t){t.currentTarget.focus()}onpointerdown(t){if(this.root.opts.disabled.current)return;if(t.pointerType==="touch")return t.preventDefault();const e=t.target;e?.hasPointerCapture(t.pointerId)&&e?.releasePointerCapture(t.pointerId),t.button===0&&t.ctrlKey===!1&&(this.root.opts.open.current===!1?this.#s(t):this.root.handleClose())}onpointerup(t){this.root.opts.disabled.current||(t.preventDefault(),t.pointerType==="touch"&&(this.root.opts.open.current===!1?this.#s(t):this.root.handleClose()))}#r=h(()=>({id:this.opts.id.current,disabled:this.root.opts.disabled.current?!0:void 0,"aria-haspopup":"listbox","aria-expanded":Xt(this.root.opts.open.current),"aria-activedescendant":this.root.highlightedId,"data-state":At(this.root.opts.open.current),"data-disabled":Mt(this.root.opts.disabled.current),"data-placeholder":this.root.hasValue?void 0:"",[this.root.getBitsAttr("trigger")]:"",onpointerdown:this.onpointerdown,onkeydown:this.onkeydown,onclick:this.onclick,onpointerup:this.onpointerup,...this.attachment}));get props(){return o(this.#r)}set props(t){u(this.#r,t)}}class mt{static create(t){return me.set(new mt(t,st.get()))}opts;root;attachment;#t=V(!1);get isPositioned(){return o(this.#t)}set isPositioned(t){u(this.#t,t,!0)}domContext;constructor(t,e){this.opts=t,this.root=e,this.attachment=gt(t.ref,s=>this.root.contentNode=s),this.domContext=new pt(this.opts.ref),this.root.domContext===null&&(this.root.domContext=this.domContext),Zt(()=>{this.root.contentNode=null,this.root.contentIsPositioned=!1,this.isPositioned=!1}),Q(()=>this.root.opts.open.current,()=>{this.root.opts.open.current||(this.root.contentIsPositioned=!1,this.isPositioned=!1)}),Q([()=>this.isPositioned,()=>this.root.highlightedNode],()=>{!this.isPositioned||!this.root.highlightedNode||this.root.scrollHighlightedNodeIntoView(this.root.highlightedNode)}),this.onpointermove=this.onpointermove.bind(this)}onpointermove(t){this.root.isUsingKeyboard=!1}#e=h(()=>jt(this.root.isCombobox?"combobox":"select"));onInteractOutside=t=>{if(t.target===this.root.triggerNode||t.target===this.root.inputNode){t.preventDefault();return}this.opts.onInteractOutside.current(t),!t.defaultPrevented&&this.root.handleClose()};onEscapeKeydown=t=>{this.opts.onEscapeKeydown.current(t),!t.defaultPrevented&&this.root.handleClose()};onOpenAutoFocus=t=>{t.preventDefault()};onCloseAutoFocus=t=>{t.preventDefault()};get shouldRender(){return this.root.contentPresence.shouldRender}#o=h(()=>({open:this.root.opts.open.current}));get snippetProps(){return o(this.#o)}set snippetProps(t){u(this.#o,t)}#s=h(()=>({id:this.opts.id.current,role:"listbox","aria-multiselectable":this.root.isMulti?"true":void 0,"data-state":At(this.root.opts.open.current),[this.root.getBitsAttr("content")]:"",style:{display:"flex",flexDirection:"column",outline:"none",boxSizing:"border-box",pointerEvents:"auto",...o(this.#e)},onpointermove:this.onpointermove,...this.attachment}));get props(){return o(this.#s)}set props(t){u(this.#s,t)}popperProps={onInteractOutside:this.onInteractOutside,onEscapeKeydown:this.onEscapeKeydown,onOpenAutoFocus:this.onOpenAutoFocus,onCloseAutoFocus:this.onCloseAutoFocus,trapFocus:!1,loop:!1,onPlaced:()=>{this.root.opts.open.current&&(this.root.contentIsPositioned=!0,this.isPositioned=!0)}}}class bt{static create(t){return new bt(t,st.get())}opts;root;attachment;#t=h(()=>this.root.includesItem(this.opts.value.current));get isSelected(){return o(this.#t)}set isSelected(t){u(this.#t,t)}#e=h(()=>this.root.highlightedValue===this.opts.value.current);get isHighlighted(){return o(this.#e)}set isHighlighted(t){u(this.#e,t)}prevHighlighted=new de(()=>this.isHighlighted);#o=V(!1);get mounted(){return o(this.#o)}set mounted(t){u(this.#o,t,!0)}constructor(t,e){this.opts=t,this.root=e,this.attachment=gt(t.ref),Q([()=>this.isHighlighted,()=>this.prevHighlighted.current],()=>{this.isHighlighted?this.opts.onHighlight.current():this.prevHighlighted.current&&this.opts.onUnhighlight.current()}),Q(()=>this.mounted,()=>{this.mounted&&this.root.setInitialHighlightedNode()}),this.onpointerdown=this.onpointerdown.bind(this),this.onpointerup=this.onpointerup.bind(this),this.onpointermove=this.onpointermove.bind(this)}handleSelect(){if(this.opts.disabled.current)return;const t=this.opts.value.current===this.root.opts.value.current;if(!this.root.opts.allowDeselect.current&&t&&!this.root.isMulti){this.root.handleClose();return}this.root.toggleItem(this.opts.value.current,this.opts.label.current),!this.root.isMulti&&!t&&this.root.handleClose()}#s=h(()=>({selected:this.isSelected,highlighted:this.isHighlighted}));get snippetProps(){return o(this.#s)}set snippetProps(t){u(this.#s,t)}onpointerdown(t){t.preventDefault()}onpointerup(t){if(!(t.defaultPrevented||!this.opts.ref.current)){if(t.pointerType==="touch"&&!$t){Kt(this.opts.ref.current,"click",()=>{this.handleSelect(),this.root.setHighlightedNode(this.opts.ref.current)},{once:!0});return}t.preventDefault(),this.handleSelect(),t.pointerType==="touch"&&this.root.setHighlightedNode(this.opts.ref.current)}}onpointermove(t){t.pointerType!=="touch"&&this.root.highlightedNode!==this.opts.ref.current&&this.root.setHighlightedNode(this.opts.ref.current)}#i=h(()=>({id:this.opts.id.current,role:"option","aria-selected":this.root.includesItem(this.opts.value.current)?"true":void 0,"data-value":this.opts.value.current,"data-disabled":Mt(this.opts.disabled.current),"data-highlighted":this.root.highlightedValue===this.opts.value.current&&!this.opts.disabled.current?"":void 0,"data-selected":this.root.includesItem(this.opts.value.current)?"":void 0,"data-label":this.opts.label.current,[this.root.getBitsAttr("item")]:"",onpointermove:this.onpointermove,onpointerdown:this.onpointerdown,onpointerup:this.onpointerup,...this.attachment}));get props(){return o(this.#i)}set props(t){u(this.#i,t)}}class yt{static create(t){return new yt(t,st.get())}opts;root;#t=h(()=>this.root.opts.name.current!=="");get shouldRender(){return o(this.#t)}set shouldRender(t){u(this.#t,t)}constructor(t,e){this.opts=t,this.root=e,this.onfocus=this.onfocus.bind(this)}onfocus(t){t.preventDefault(),this.root.isCombobox?this.root.inputNode?.focus():this.root.triggerNode?.focus()}#e=h(()=>({disabled:St(this.root.opts.disabled.current),required:St(this.root.opts.required.current),name:this.root.opts.name.current,value:this.opts.value.current,onfocus:this.onfocus}));get props(){return o(this.#e)}set props(t){u(this.#e,t)}}function at(b,t){U(t,!0);let e=r(t,"value",15);const s=yt.create({value:v(()=>e())});var n=x(),l=C(n);{var i=a=>{oe(a,et(()=>s.props,{get autocomplete(){return t.autocomplete},get value(){return e()},set value(y){e(y)}}))};F(l,a=>{s.shouldRender&&a(i)})}p(b,n),W()}var _e=B("<div><div><!></div></div>"),Ce=B("<div><div><!></div></div>");function we(b,t){const e=dt();U(t,!0);let s=r(t,"id",19,()=>ft(e)),n=r(t,"ref",15,null),l=r(t,"forceMount",3,!1),i=r(t,"side",3,"bottom"),a=r(t,"onInteractOutside",3,q),y=r(t,"onEscapeKeydown",3,q),w=r(t,"preventScroll",3,!1),m=ot(t,["$$slots","$$events","$$legacy","id","ref","forceMount","side","onInteractOutside","onEscapeKeydown","children","child","preventScroll","style"]);const d=mt.create({id:v(()=>s()),ref:v(()=>n(),f=>n(f)),onInteractOutside:v(()=>a()),onEscapeKeydown:v(()=>y())}),S=h(()=>$(m,d.props));var H=x(),M=C(H);{var T=f=>{se(f,et(()=>o(S),()=>d.popperProps,{get ref(){return d.opts.ref},get side(){return i()},get enabled(){return d.root.opts.open.current},get id(){return s()},get preventScroll(){return w()},forceMount:!0,get shouldRender(){return d.shouldRender},popper:(g,N)=>{let L=()=>N?.().props,Y=()=>N?.().wrapperProps;const _=h(()=>$(L(),{style:d.props.style},{style:t.style}));var A=x(),z=C(A);{var G=P=>{var I=x(),k=C(I);{let R=h(()=>({props:o(_),wrapperProps:Y(),...d.snippetProps}));D(k,()=>t.child,()=>o(R))}p(P,I)},Z=P=>{var I=_e();J(I,()=>({...Y()}));var k=E(I);J(k,()=>({...o(_)}));var R=E(k);D(R,()=>t.children??tt),K(k),K(I),p(P,I)};F(z,P=>{t.child?P(G):P(Z,!1)})}p(g,A)},$$slots:{popper:!0}}))},O=f=>{ie(f,et(()=>o(S),()=>d.popperProps,{get ref(){return d.opts.ref},get side(){return i()},get open(){return d.root.opts.open.current},get id(){return s()},get preventScroll(){return w()},forceMount:!1,get shouldRender(){return d.shouldRender},popper:(g,N)=>{let L=()=>N?.().props,Y=()=>N?.().wrapperProps;const _=h(()=>$(L(),{style:d.props.style},{style:t.style}));var A=x(),z=C(A);{var G=P=>{var I=x(),k=C(I);{let R=h(()=>({props:o(_),wrapperProps:Y(),...d.snippetProps}));D(k,()=>t.child,()=>o(R))}p(P,I)},Z=P=>{var I=Ce();J(I,()=>({...Y()}));var k=E(I);J(k,()=>({...o(_)}));var R=E(k);D(R,()=>t.children??tt),K(k),K(I),p(P,I)};F(z,P=>{t.child?P(G):P(Z,!1)})}p(g,A)},$$slots:{popper:!0}}))};F(M,f=>{l()?f(T):l()||f(O,1)})}p(b,H),W()}function Pe(b,t){U(t,!0);let e=r(t,"mounted",15,!1),s=r(t,"onMountedChange",3,q);ue(()=>(e(!0),s()(!0),()=>{e(!1),s()(!1)})),W()}var Se=B("<div><!></div>"),Ie=B("<!> <!>",1);function Ge(b,t){const e=dt();U(t,!0);let s=r(t,"id",19,()=>ft(e)),n=r(t,"ref",15,null),l=r(t,"label",19,()=>t.value),i=r(t,"disabled",3,!1),a=r(t,"onHighlight",3,q),y=r(t,"onUnhighlight",3,q),w=ot(t,["$$slots","$$events","$$legacy","id","ref","value","label","disabled","children","child","onHighlight","onUnhighlight"]);const m=bt.create({id:v(()=>s()),ref:v(()=>n(),f=>n(f)),value:v(()=>t.value),disabled:v(()=>i()),label:v(()=>l()),onHighlight:v(()=>a()),onUnhighlight:v(()=>y())}),d=h(()=>$(w,m.props));var S=Ie(),H=C(S);{var M=f=>{var c=x(),g=C(c);{let N=h(()=>({props:o(d),...m.snippetProps}));D(g,()=>t.child,()=>o(N))}p(f,c)},T=f=>{var c=Se();J(c,()=>({...o(d)}));var g=E(c);D(g,()=>t.children??tt,()=>m.snippetProps),K(c),p(f,c)};F(H,f=>{t.child?f(M):f(T,!1)})}var O=ct(H,2);Pe(O,{get mounted(){return m.mounted},set mounted(f){m.mounted=f}}),p(b,S),W()}var xe=B("<!> <!>",1);function He(b,t){U(t,!0);let e=r(t,"value",15),s=r(t,"onValueChange",3,q),n=r(t,"name",3,""),l=r(t,"disabled",3,!1),i=r(t,"open",15,!1),a=r(t,"onOpenChange",3,q),y=r(t,"onOpenChangeComplete",3,q),w=r(t,"loop",3,!1),m=r(t,"scrollAlignment",3,"nearest"),d=r(t,"required",3,!1),S=r(t,"items",19,()=>[]),H=r(t,"allowDeselect",3,!1);function M(){e()===void 0&&e(t.type==="single"?"":[])}M(),Q.pre(()=>e(),()=>{M()});let T=V("");const O=Ne.create({type:t.type,value:v(()=>e(),_=>{e(_),s()(_)}),disabled:v(()=>l()),required:v(()=>d()),open:v(()=>i(),_=>{i(_),a()(_)}),loop:v(()=>w()),scrollAlignment:v(()=>m()),name:v(()=>n()),isCombobox:!1,items:v(()=>S()),allowDeselect:v(()=>H()),inputValue:v(()=>o(T),_=>u(T,_,!0)),onOpenChangeComplete:v(()=>y())});var f=xe(),c=C(f);re(c,{children:(_,A)=>{var z=x(),G=C(z);D(G,()=>t.children??tt),p(_,z)},$$slots:{default:!0}});var g=ct(c,2);{var N=_=>{var A=x(),z=C(A);{var G=P=>{at(P,{get autocomplete(){return t.autocomplete}})},Z=P=>{var I=x(),k=C(I);le(k,16,()=>O.opts.value.current,R=>R,(R,Et)=>{at(R,{get value(){return Et},get autocomplete(){return t.autocomplete}})}),p(P,I)};F(z,P=>{O.opts.value.current.length===0?P(G):P(Z,!1)})}p(_,A)},L=h(()=>Array.isArray(O.opts.value.current)),Y=_=>{at(_,{get autocomplete(){return t.autocomplete},get value(){return O.opts.value.current},set value(A){O.opts.value.current=A}})};F(g,_=>{o(L)?_(N):_(Y,!1)})}p(b,f),W()}var Oe=B("<button><!></button>");function Te(b,t){const e=dt();U(t,!0);let s=r(t,"id",19,()=>ft(e)),n=r(t,"ref",15,null),l=r(t,"type",3,"button"),i=ot(t,["$$slots","$$events","$$legacy","id","ref","child","children","type"]);const a=vt.create({id:v(()=>s()),ref:v(()=>n(),d=>n(d))}),y=h(()=>$(i,a.props,{type:l()}));var w=x(),m=C(w);it(m,()=>ne,(d,S)=>{S(d,{get id(){return s()},get ref(){return a.opts.ref},children:(H,M)=>{var T=x(),O=C(T);{var f=g=>{var N=x(),L=C(N);D(L,()=>t.child,()=>({props:o(y)})),p(g,N)},c=g=>{var N=Oe();J(N,()=>({...o(y)}));var L=E(N);D(L,()=>t.children??tt),K(N),p(g,N)};F(O,g=>{t.child?g(f):g(c,!1)})}p(H,T)},$$slots:{default:!0}})}),p(b,w),W()}var ke=It("<title> </title>"),Me=It('<svg><!><path d="M16 22 6 12 7.4 10.6 16 19.2 24.6 10.6 26 12z"></path></svg>');function Ae(b,t){const e=Ct(t,["children","$$slots","$$events","$$legacy"]),s=Ct(e,["size","title"]);U(t,!1);const n=_t(),l=_t();let i=r(t,"size",8,16),a=r(t,"title",8,void 0);Nt(()=>(rt(e),rt(a())),()=>{u(n,e["aria-label"]||e["aria-labelledby"]||a())}),Nt(()=>(o(n),rt(e)),()=>{u(l,{"aria-hidden":o(n)?void 0:!0,role:o(n)?"img":void 0,focusable:Number(e.tabindex)===0?!0:void 0})}),Bt(),he();var y=Me();J(y,()=>({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor",preserveAspectRatio:"xMidYMid meet",width:i(),height:i(),...o(l),...s}));var w=E(y);{var m=d=>{var S=ke(),H=E(S,!0);K(S),lt(()=>ht(H,a())),p(d,S)};F(w,d=>{a()&&d(m)})}Ut(),K(y),p(b,y),W()}var Re=B("<span> </span>"),Ve=B('<span class="select-placeholder"> </span>'),De=B("<!> <!>",1);function Je(b,t){U(t,!0);let e=r(t,"placeholder",3,"Select..."),s=r(t,"size",3,"default"),n=ot(t,["$$slots","$$events","$$legacy","children","value","placeholder","class","size"]);var l=x(),i=C(l);{let a=h(()=>Vt("select-trigger",s()==="sm"&&"select-trigger-sm",t.class));it(i,()=>Te,(y,w)=>{w(y,et({get class(){return o(a)}},()=>n,{children:(m,d)=>{var S=De(),H=C(S);{var M=c=>{var g=x(),N=C(g);D(N,()=>t.children),p(c,g)},T=c=>{var g=Re(),N=E(g,!0);K(g),lt(()=>ht(N,t.value)),p(c,g)},O=c=>{var g=Ve(),N=E(g,!0);K(g),lt(()=>ht(N,e())),p(c,g)};F(H,c=>{t.children?c(M):t.value?c(T,1):c(O,!1)})}var f=ct(H,2);{let c=h(()=>s()==="sm"?12:14);Ae(f,{get size(){return o(c)},class:"select-chevron"})}p(m,S)},$$slots:{default:!0}}))})}p(b,l),W()}function Qe(b,t){U(t,!0);let e=r(t,"side",3,"bottom"),s=r(t,"sideOffset",3,4),n=ot(t,["$$slots","$$events","$$legacy","children","class","side","sideOffset"]);var l=x(),i=C(l);it(i,()=>ae,(a,y)=>{y(a,{children:(w,m)=>{var d=x(),S=C(d);{let H=h(()=>Vt("select-content",t.class));it(S,()=>we,(M,T)=>{T(M,et({get class(){return o(H)},get side(){return e()},get sideOffset(){return s()}},()=>n,{children:(O,f)=>{var c=x(),g=C(c);D(g,()=>t.children),p(O,c)},$$slots:{default:!0}}))})}p(w,d)},$$slots:{default:!0}})}),p(b,l),W()}const Xe=He;export{Xe as R,Ge as S,Je as a,Qe as b};
@@ -1 +1 @@
1
- import{c as h,a as i,s as k,b as x}from"./A_CBh12A.js";import{p as S,h as m,g as C,b as y,c as z,r as P,i as j,t as q,u as w}from"./BV_5EeTy.js";import{i as A}from"./BDEGO3ce.js";import{c as B}from"./bStkEd6T.js";import{p as D,s as E,r as F}from"./X6Q7ETGH.js";import{c as G}from"./CVUPZdJX.js";import{C as H}from"./CkCjn7QP.js";import{S as I}from"./BuErvqAd.js";var J=x('<span class="select-item-text"> </span> <!>',1);function U(o,e){S(e,!0);let n=D(e,"disabled",3,!1),d=F(e,["$$slots","$$events","$$legacy","value","label","disabled","class"]);var l=h(),f=m(l);{const u=(t,a)=>{let v=()=>a?.().selected;var c=J(),s=m(c),_=z(s,!0);P(s);var b=j(s,2);{var g=r=>{H(r,{size:12,class:"select-item-check"})};A(b,r=>{v()&&r(g)})}q(()=>k(_,e.label??e.value)),i(t,c)};let p=w(()=>G("select-item",e.class));B(f,()=>I,(t,a)=>{a(t,E({get value(){return e.value},get label(){return e.label},get disabled(){return n()},get class(){return C(p)}},()=>d,{children:u,$$slots:{default:!0}}))})}i(o,l),y()}export{U as S};
1
+ import{c as h,a as i,s as k,b as x}from"./A_CBh12A.js";import{p as S,h as m,g as C,b as y,c as z,r as P,i as j,t as q,u as w}from"./BV_5EeTy.js";import{i as A}from"./BDEGO3ce.js";import{c as B}from"./bStkEd6T.js";import{p as D,s as E,r as F}from"./X6Q7ETGH.js";import{c as G}from"./CVUPZdJX.js";import{C as H}from"./CkCjn7QP.js";import{S as I}from"./BhITy8Ob.js";var J=x('<span class="select-item-text"> </span> <!>',1);function U(o,e){S(e,!0);let n=D(e,"disabled",3,!1),d=F(e,["$$slots","$$events","$$legacy","value","label","disabled","class"]);var l=h(),f=m(l);{const u=(t,a)=>{let v=()=>a?.().selected;var c=J(),s=m(c),_=z(s,!0);P(s);var b=j(s,2);{var g=r=>{H(r,{size:12,class:"select-item-check"})};A(b,r=>{v()&&r(g)})}q(()=>k(_,e.label??e.value)),i(t,c)};let p=w(()=>G("select-item",e.class));B(f,()=>I,(t,a)=>{a(t,E({get value(){return e.value},get label(){return e.label},get disabled(){return n()},get class(){return C(p)}},()=>d,{children:u,$$slots:{default:!0}}))})}i(o,l),y()}export{U as S};
@@ -1,4 +1,4 @@
1
- import{e as h,f as U,s as a,g as t,az as x}from"./BV_5EeTy.js";import{i as H,g as L}from"./TyzEVmmX.js";import{n as y}from"./tl7OBIop.js";import{w as V}from"./BsrRU3u_.js";function W(g,c,o){fetch("/api/chat/stream",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(g),signal:o}).then(async n=>{if(!n.ok){c({type:"error",message:`HTTP ${n.status}`});return}const r=n.body?.getReader();if(!r){c({type:"error",message:"No response body"});return}const p=new TextDecoder;let m="";for(;;){const{done:k,value:O}=await r.read();if(k)break;m+=p.decode(O,{stream:!0});const A=m.split(`
1
+ import{e as h,f as U,s as a,g as t,az as x}from"./BV_5EeTy.js";import{i as H,g as L}from"./DnwCyrLk.js";import{n as y}from"./tl7OBIop.js";import{w as V}from"./BsrRU3u_.js";function W(g,c,o){fetch("/api/chat/stream",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(g),signal:o}).then(async n=>{if(!n.ok){c({type:"error",message:`HTTP ${n.status}`});return}const r=n.body?.getReader();if(!r){c({type:"error",message:"No response body"});return}const p=new TextDecoder;let m="";for(;;){const{done:k,value:O}=await r.read();if(k)break;m+=p.decode(O,{stream:!0});const A=m.split(`
2
2
  `);m=A.pop()??"";for(const C of A)if(C.startsWith("data: "))try{const f=JSON.parse(C.slice(6));c(f)}catch{}}}).catch(n=>{n.name!=="AbortError"&&c({type:"error",message:n.message})})}const D="sg-chat-sessions",J="sg-chat-version",X=14;function b(){try{const g=localStorage.getItem(D);if(!g)return[];if(localStorage.getItem(J)==="2")return JSON.parse(g);const n=JSON.parse(g).map(r=>({id:crypto.randomUUID(),createdAt:r.date+"T00:00:00.000Z",updatedAt:r.date+"T00:00:00.000Z",title:r.messages.find(p=>p.role==="user")?.content.slice(0,50)||"New chat",messages:r.messages}));return localStorage.setItem(D,JSON.stringify(n)),localStorage.setItem(J,"2"),n}catch{return[]}}function _(g){const o=[...g].sort((n,r)=>r.updatedAt.localeCompare(n.updatedAt)).slice(0,X);try{localStorage.setItem(D,JSON.stringify(o)),localStorage.setItem(J,"2")}catch{}}function N(g,c){const o=b(),n=c.map(({streaming:p,...m})=>m),r=o.findIndex(p=>p.id===g);r>=0&&(o[r].messages=n,o[r].updatedAt=new Date().toISOString()),_(o)}function B(){const c=b().sort((e,i)=>i.updatedAt.localeCompare(e.updatedAt))[0];let o=h(U(c?c.messages.map(e=>({...e,streaming:!1})):[])),n=h(U(c?.id??null)),r=h(!1),p=h(0),m=h(0),k=h(0),O=h(null),A=null,C=h(""),f=h(U(!!c));const R=new Set(["create_entity","update_entity","delete_entity","move_entity"]);function M(){$();const e=crypto.randomUUID();a(n,e,!0),a(o,[],!0),a(f,!1)}function E(){if(t(n)&&t(f))return t(n);const e=t(n)||crypto.randomUUID();a(n,e,!0);const i=new Date().toISOString(),d=b();return d.push({id:e,createdAt:i,updatedAt:i,title:"New chat",messages:[]}),_(d),a(f,!0),e}function K(e){if(!e.trim()||t(r))return;a(O,null);const i=E();t(o).push({role:"user",content:e}),t(o).push({role:"agent",content:"",segments:[],streaming:!0}),a(r,!0);const d=b(),l=d.find(s=>s.id===i);l&&l.title==="New chat"&&(l.title=e.slice(0,50),_(d)),N(i,t(o));let T=!1,w=null;A=new AbortController;const z=y.selectedSubPath?`${y.selectedRepo}/${y.selectedType}/${y.selectedId}/${y.selectedSubPath}`:y.selectedId?`${y.selectedRepo}/${y.selectedType}/${y.selectedId}`:null,P=t(o).slice(0,-2).map(s=>({role:s.role==="agent"?"assistant":s.role,content:s.content})),G={message:e,context:z??void 0,sessionId:i,history:P.length>0?P:void 0};W(G,s=>{if(!t(r))return;const u=t(o)[t(o).length-1];if(!u||u.role!=="agent")return;const S=u.segments;switch(s.type){case"token":{u.content+=s.text??"";const I=S[S.length-1];I&&I.type==="text"?I.content+=s.text??"":S.push({type:"text",content:s.text??""}),u.segments=S,x(m);break}case"tool_start":if(s.name){R.has(s.name)&&(T=!0);const I=S[S.length-1];I&&I.type==="tools"?I.names=[...I.names,s.name]:S.push({type:"tools",names:[s.name]}),u.segments=S,x(m)}break;case"mutation":T=!0,s.action==="created"&&s.repo&&s.entityType&&s.entityId&&(w={repo:s.repo,entityType:s.entityType,entityId:s.entityId}),window.StudioChrome?.emitMutation?.({action:s.action,repo:s.repo,entityType:s.entityType,entityId:s.entityId});break;case"highlight":a(O,s.entityIds&&s.entityIds.length>0?new Set(s.entityIds):null,!0);break;case"done":s.message&&!u.content&&(u.content=s.message,u.segments=[{type:"text",content:s.message}]),u.streaming=!1,a(r,!1),N(i,t(o)),T&&(H().then(()=>{x(p)}),V.refreshAll().then(()=>{w&&L(`/${w.repo}/${w.entityType}/${w.entityId}`)}));break;case"error":u.content+=`
3
3
 
4
4
  Error: ${s.message}`,u.streaming=!1,a(r,!1),N(i,t(o));break}},A.signal)}function $(){if(!t(r))return;fetch("/api/chat/abort",{method:"POST",credentials:"include"}).catch(()=>{}),A?.abort(),A=null,a(r,!1);const e=t(o)[t(o).length-1];e?.streaming&&(e.streaming=!1,t(n)&&N(t(n),t(o)))}function Y(){$(),a(o,[],!0),t(n)&&t(f)&&N(t(n),t(o))}function Z(e){const d=b().filter(l=>l.id!==e);if(_(d),t(n)===e){const l=d.sort((T,w)=>w.updatedAt.localeCompare(T.updatedAt));l.length>0?(a(n,l[0].id,!0),a(o,l[0].messages.map(T=>({...T,streaming:!1})),!0),a(f,!0)):(a(n,null),a(o,[],!0),a(f,!1))}}function j(e){const d=b().find(l=>l.id===e);d&&($(),a(n,d.id,!0),a(o,d.messages.map(l=>({...l,streaming:!1})),!0),a(f,!0))}function q(){return b().sort((e,i)=>i.updatedAt.localeCompare(e.updatedAt)).map(e=>({id:e.id,title:e.title,createdAt:e.createdAt,updatedAt:e.updatedAt,preview:e.messages.find(i=>i.role==="user")?.content.slice(0,80)||"",count:e.messages.length,active:e.id===t(n)}))}return{get messages(){return t(o)},get streaming(){return t(r)},get mutationCount(){return t(p)},get scrollTick(){return t(m)},get forceScroll(){return t(k)},triggerScroll(){x(k)},get highlightedIds(){return t(O)},get activeSessionId(){return t(n)},get draftInput(){return t(C)},set draftInput(e){a(C,e,!0)},send:K,stop:$,clear:Y,newSession:M,deleteSession:Z,getSessions:q,loadSession:j}}const te=B();export{te as chatStore};