@industry-theme/file-city-panel 0.2.44 → 0.2.46

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.
@@ -106,7 +106,7 @@ const createLucideIcon = (iconName, iconNode) => {
106
106
  * This source code is licensed under the ISC license.
107
107
  * See the LICENSE file in the root directory of this source tree.
108
108
  */
109
- const __iconNode$i = [
109
+ const __iconNode$p = [
110
110
  [
111
111
  "path",
112
112
  {
@@ -115,14 +115,32 @@ const __iconNode$i = [
115
115
  }
116
116
  ]
117
117
  ];
118
- const Activity = createLucideIcon("activity", __iconNode$i);
118
+ const Activity = createLucideIcon("activity", __iconNode$p);
119
119
  /**
120
120
  * @license lucide-react v0.552.0 - ISC
121
121
  *
122
122
  * This source code is licensed under the ISC license.
123
123
  * See the LICENSE file in the root directory of this source tree.
124
124
  */
125
- const __iconNode$h = [
125
+ const __iconNode$o = [
126
+ [
127
+ "path",
128
+ {
129
+ d: "M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",
130
+ key: "hh9hay"
131
+ }
132
+ ],
133
+ ["path", { d: "m3.3 7 8.7 5 8.7-5", key: "g66t2b" }],
134
+ ["path", { d: "M12 22V12", key: "d0xqtd" }]
135
+ ];
136
+ const Box = createLucideIcon("box", __iconNode$o);
137
+ /**
138
+ * @license lucide-react v0.552.0 - ISC
139
+ *
140
+ * This source code is licensed under the ISC license.
141
+ * See the LICENSE file in the root directory of this source tree.
142
+ */
143
+ const __iconNode$n = [
126
144
  ["path", { d: "M10 12h4", key: "a56b0p" }],
127
145
  ["path", { d: "M10 8h4", key: "1sr2af" }],
128
146
  ["path", { d: "M14 21v-3a2 2 0 0 0-4 0v3", key: "1rgiei" }],
@@ -135,55 +153,67 @@ const __iconNode$h = [
135
153
  ],
136
154
  ["path", { d: "M6 21V5a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v16", key: "16ra0t" }]
137
155
  ];
138
- const Building2 = createLucideIcon("building-2", __iconNode$h);
156
+ const Building2 = createLucideIcon("building-2", __iconNode$n);
139
157
  /**
140
158
  * @license lucide-react v0.552.0 - ISC
141
159
  *
142
160
  * This source code is licensed under the ISC license.
143
161
  * See the LICENSE file in the root directory of this source tree.
144
162
  */
145
- const __iconNode$g = [
163
+ const __iconNode$m = [
146
164
  ["path", { d: "M3 3v16a2 2 0 0 0 2 2h16", key: "c24i48" }],
147
165
  ["path", { d: "M18 17V9", key: "2bz60n" }],
148
166
  ["path", { d: "M13 17V5", key: "1frdt8" }],
149
167
  ["path", { d: "M8 17v-3", key: "17ska0" }]
150
168
  ];
151
- const ChartColumn = createLucideIcon("chart-column", __iconNode$g);
169
+ const ChartColumn = createLucideIcon("chart-column", __iconNode$m);
152
170
  /**
153
171
  * @license lucide-react v0.552.0 - ISC
154
172
  *
155
173
  * This source code is licensed under the ISC license.
156
174
  * See the LICENSE file in the root directory of this source tree.
157
175
  */
158
- const __iconNode$f = [["path", { d: "m6 9 6 6 6-6", key: "qrunsl" }]];
159
- const ChevronDown = createLucideIcon("chevron-down", __iconNode$f);
176
+ const __iconNode$l = [["path", { d: "m6 9 6 6 6-6", key: "qrunsl" }]];
177
+ const ChevronDown = createLucideIcon("chevron-down", __iconNode$l);
160
178
  /**
161
179
  * @license lucide-react v0.552.0 - ISC
162
180
  *
163
181
  * This source code is licensed under the ISC license.
164
182
  * See the LICENSE file in the root directory of this source tree.
165
183
  */
166
- const __iconNode$e = [["path", { d: "m9 18 6-6-6-6", key: "mthhwq" }]];
167
- const ChevronRight = createLucideIcon("chevron-right", __iconNode$e);
184
+ const __iconNode$k = [["path", { d: "m9 18 6-6-6-6", key: "mthhwq" }]];
185
+ const ChevronRight = createLucideIcon("chevron-right", __iconNode$k);
168
186
  /**
169
187
  * @license lucide-react v0.552.0 - ISC
170
188
  *
171
189
  * This source code is licensed under the ISC license.
172
190
  * See the LICENSE file in the root directory of this source tree.
173
191
  */
174
- const __iconNode$d = [
192
+ const __iconNode$j = [
175
193
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }],
176
194
  ["line", { x1: "12", x2: "12", y1: "8", y2: "12", key: "1pkeuh" }],
177
195
  ["line", { x1: "12", x2: "12.01", y1: "16", y2: "16", key: "4dfq90" }]
178
196
  ];
179
- const CircleAlert = createLucideIcon("circle-alert", __iconNode$d);
197
+ const CircleAlert = createLucideIcon("circle-alert", __iconNode$j);
180
198
  /**
181
199
  * @license lucide-react v0.552.0 - ISC
182
200
  *
183
201
  * This source code is licensed under the ISC license.
184
202
  * See the LICENSE file in the root directory of this source tree.
185
203
  */
186
- const __iconNode$c = [
204
+ const __iconNode$i = [
205
+ ["path", { d: "M15 3h6v6", key: "1q9fwt" }],
206
+ ["path", { d: "M10 14 21 3", key: "gplh6r" }],
207
+ ["path", { d: "M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6", key: "a6xqqp" }]
208
+ ];
209
+ const ExternalLink = createLucideIcon("external-link", __iconNode$i);
210
+ /**
211
+ * @license lucide-react v0.552.0 - ISC
212
+ *
213
+ * This source code is licensed under the ISC license.
214
+ * See the LICENSE file in the root directory of this source tree.
215
+ */
216
+ const __iconNode$h = [
187
217
  [
188
218
  "path",
189
219
  {
@@ -201,14 +231,14 @@ const __iconNode$c = [
201
231
  ],
202
232
  ["path", { d: "m2 2 20 20", key: "1ooewy" }]
203
233
  ];
204
- const EyeOff = createLucideIcon("eye-off", __iconNode$c);
234
+ const EyeOff = createLucideIcon("eye-off", __iconNode$h);
205
235
  /**
206
236
  * @license lucide-react v0.552.0 - ISC
207
237
  *
208
238
  * This source code is licensed under the ISC license.
209
239
  * See the LICENSE file in the root directory of this source tree.
210
240
  */
211
- const __iconNode$b = [
241
+ const __iconNode$g = [
212
242
  [
213
243
  "path",
214
244
  {
@@ -218,14 +248,14 @@ const __iconNode$b = [
218
248
  ],
219
249
  ["circle", { cx: "12", cy: "12", r: "3", key: "1v7zrd" }]
220
250
  ];
221
- const Eye = createLucideIcon("eye", __iconNode$b);
251
+ const Eye = createLucideIcon("eye", __iconNode$g);
222
252
  /**
223
253
  * @license lucide-react v0.552.0 - ISC
224
254
  *
225
255
  * This source code is licensed under the ISC license.
226
256
  * See the LICENSE file in the root directory of this source tree.
227
257
  */
228
- const __iconNode$a = [
258
+ const __iconNode$f = [
229
259
  [
230
260
  "path",
231
261
  {
@@ -236,14 +266,14 @@ const __iconNode$a = [
236
266
  ["path", { d: "M12 17h.01", key: "p32p05" }],
237
267
  ["path", { d: "M9.1 9a3 3 0 0 1 5.82 1c0 2-3 3-3 3", key: "mhlwft" }]
238
268
  ];
239
- const FileQuestionMark = createLucideIcon("file-question-mark", __iconNode$a);
269
+ const FileQuestionMark = createLucideIcon("file-question-mark", __iconNode$f);
240
270
  /**
241
271
  * @license lucide-react v0.552.0 - ISC
242
272
  *
243
273
  * This source code is licensed under the ISC license.
244
274
  * See the LICENSE file in the root directory of this source tree.
245
275
  */
246
- const __iconNode$9 = [
276
+ const __iconNode$e = [
247
277
  [
248
278
  "path",
249
279
  {
@@ -256,14 +286,14 @@ const __iconNode$9 = [
256
286
  ["path", { d: "M16 13H8", key: "t4e002" }],
257
287
  ["path", { d: "M16 17H8", key: "z1uh3a" }]
258
288
  ];
259
- const FileText = createLucideIcon("file-text", __iconNode$9);
289
+ const FileText = createLucideIcon("file-text", __iconNode$e);
260
290
  /**
261
291
  * @license lucide-react v0.552.0 - ISC
262
292
  *
263
293
  * This source code is licensed under the ISC license.
264
294
  * See the LICENSE file in the root directory of this source tree.
265
295
  */
266
- const __iconNode$8 = [
296
+ const __iconNode$d = [
267
297
  [
268
298
  "path",
269
299
  {
@@ -273,14 +303,14 @@ const __iconNode$8 = [
273
303
  ],
274
304
  ["path", { d: "M14 2v5a1 1 0 0 0 1 1h5", key: "wfsgrz" }]
275
305
  ];
276
- const File = createLucideIcon("file", __iconNode$8);
306
+ const File = createLucideIcon("file", __iconNode$d);
277
307
  /**
278
308
  * @license lucide-react v0.552.0 - ISC
279
309
  *
280
310
  * This source code is licensed under the ISC license.
281
311
  * See the LICENSE file in the root directory of this source tree.
282
312
  */
283
- const __iconNode$7 = [
313
+ const __iconNode$c = [
284
314
  [
285
315
  "path",
286
316
  {
@@ -289,71 +319,118 @@ const __iconNode$7 = [
289
319
  }
290
320
  ]
291
321
  ];
292
- const Folder = createLucideIcon("folder", __iconNode$7);
322
+ const Folder = createLucideIcon("folder", __iconNode$c);
293
323
  /**
294
324
  * @license lucide-react v0.552.0 - ISC
295
325
  *
296
326
  * This source code is licensed under the ISC license.
297
327
  * See the LICENSE file in the root directory of this source tree.
298
328
  */
299
- const __iconNode$6 = [
329
+ const __iconNode$b = [
300
330
  ["line", { x1: "6", x2: "6", y1: "3", y2: "15", key: "17qcm7" }],
301
331
  ["circle", { cx: "18", cy: "6", r: "3", key: "1h7g24" }],
302
332
  ["circle", { cx: "6", cy: "18", r: "3", key: "fqmcym" }],
303
333
  ["path", { d: "M18 9a9 9 0 0 1-9 9", key: "n2h4wq" }]
304
334
  ];
305
- const GitBranch = createLucideIcon("git-branch", __iconNode$6);
335
+ const GitBranch = createLucideIcon("git-branch", __iconNode$b);
306
336
  /**
307
337
  * @license lucide-react v0.552.0 - ISC
308
338
  *
309
339
  * This source code is licensed under the ISC license.
310
340
  * See the LICENSE file in the root directory of this source tree.
311
341
  */
312
- const __iconNode$5 = [
342
+ const __iconNode$a = [
313
343
  ["circle", { cx: "12", cy: "12", r: "3", key: "1v7zrd" }],
314
344
  ["line", { x1: "3", x2: "9", y1: "12", y2: "12", key: "1dyftd" }],
315
345
  ["line", { x1: "15", x2: "21", y1: "12", y2: "12", key: "oup4p8" }]
316
346
  ];
317
- const GitCommitHorizontal = createLucideIcon("git-commit-horizontal", __iconNode$5);
347
+ const GitCommitHorizontal = createLucideIcon("git-commit-horizontal", __iconNode$a);
318
348
  /**
319
349
  * @license lucide-react v0.552.0 - ISC
320
350
  *
321
351
  * This source code is licensed under the ISC license.
322
352
  * See the LICENSE file in the root directory of this source tree.
323
353
  */
324
- const __iconNode$4 = [
354
+ const __iconNode$9 = [
355
+ ["circle", { cx: "12", cy: "18", r: "3", key: "1mpf1b" }],
356
+ ["circle", { cx: "6", cy: "6", r: "3", key: "1lh9wr" }],
357
+ ["circle", { cx: "18", cy: "6", r: "3", key: "1h7g24" }],
358
+ ["path", { d: "M18 9v2c0 .6-.4 1-1 1H7c-.6 0-1-.4-1-1V9", key: "1uq4wg" }],
359
+ ["path", { d: "M12 12v3", key: "158kv8" }]
360
+ ];
361
+ const GitFork = createLucideIcon("git-fork", __iconNode$9);
362
+ /**
363
+ * @license lucide-react v0.552.0 - ISC
364
+ *
365
+ * This source code is licensed under the ISC license.
366
+ * See the LICENSE file in the root directory of this source tree.
367
+ */
368
+ const __iconNode$8 = [
325
369
  ["circle", { cx: "18", cy: "18", r: "3", key: "1xkwt0" }],
326
370
  ["circle", { cx: "6", cy: "6", r: "3", key: "1lh9wr" }],
327
371
  ["path", { d: "M13 6h3a2 2 0 0 1 2 2v7", key: "1yeb86" }],
328
372
  ["line", { x1: "6", x2: "6", y1: "9", y2: "21", key: "rroup" }]
329
373
  ];
330
- const GitPullRequest = createLucideIcon("git-pull-request", __iconNode$4);
374
+ const GitPullRequest = createLucideIcon("git-pull-request", __iconNode$8);
331
375
  /**
332
376
  * @license lucide-react v0.552.0 - ISC
333
377
  *
334
378
  * This source code is licensed under the ISC license.
335
379
  * See the LICENSE file in the root directory of this source tree.
336
380
  */
337
- const __iconNode$3 = [["path", { d: "M5 12h14", key: "1ays0h" }]];
338
- const Minus = createLucideIcon("minus", __iconNode$3);
381
+ const __iconNode$7 = [["path", { d: "M5 12h14", key: "1ays0h" }]];
382
+ const Minus = createLucideIcon("minus", __iconNode$7);
339
383
  /**
340
384
  * @license lucide-react v0.552.0 - ISC
341
385
  *
342
386
  * This source code is licensed under the ISC license.
343
387
  * See the LICENSE file in the root directory of this source tree.
344
388
  */
345
- const __iconNode$2 = [
389
+ const __iconNode$6 = [
390
+ [
391
+ "path",
392
+ {
393
+ d: "M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z",
394
+ key: "1a0edw"
395
+ }
396
+ ],
397
+ ["path", { d: "M12 22V12", key: "d0xqtd" }],
398
+ ["polyline", { points: "3.29 7 12 12 20.71 7", key: "ousv84" }],
399
+ ["path", { d: "m7.5 4.27 9 5.15", key: "1c824w" }]
400
+ ];
401
+ const Package = createLucideIcon("package", __iconNode$6);
402
+ /**
403
+ * @license lucide-react v0.552.0 - ISC
404
+ *
405
+ * This source code is licensed under the ISC license.
406
+ * See the LICENSE file in the root directory of this source tree.
407
+ */
408
+ const __iconNode$5 = [
346
409
  ["path", { d: "M5 12h14", key: "1ays0h" }],
347
410
  ["path", { d: "M12 5v14", key: "s699le" }]
348
411
  ];
349
- const Plus = createLucideIcon("plus", __iconNode$2);
412
+ const Plus = createLucideIcon("plus", __iconNode$5);
350
413
  /**
351
414
  * @license lucide-react v0.552.0 - ISC
352
415
  *
353
416
  * This source code is licensed under the ISC license.
354
417
  * See the LICENSE file in the root directory of this source tree.
355
418
  */
356
- const __iconNode$1 = [
419
+ const __iconNode$4 = [
420
+ ["path", { d: "m16 16 3-8 3 8c-.87.65-1.92 1-3 1s-2.13-.35-3-1Z", key: "7g6ntu" }],
421
+ ["path", { d: "m2 16 3-8 3 8c-.87.65-1.92 1-3 1s-2.13-.35-3-1Z", key: "ijws7r" }],
422
+ ["path", { d: "M7 21h10", key: "1b0cd5" }],
423
+ ["path", { d: "M12 3v18", key: "108xh3" }],
424
+ ["path", { d: "M3 7h2c2 0 5-1 7-2 2 1 5 2 7 2h2", key: "3gwbw2" }]
425
+ ];
426
+ const Scale = createLucideIcon("scale", __iconNode$4);
427
+ /**
428
+ * @license lucide-react v0.552.0 - ISC
429
+ *
430
+ * This source code is licensed under the ISC license.
431
+ * See the LICENSE file in the root directory of this source tree.
432
+ */
433
+ const __iconNode$3 = [
357
434
  ["path", { d: "M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7", key: "1m0v6g" }],
358
435
  [
359
436
  "path",
@@ -363,7 +440,34 @@ const __iconNode$1 = [
363
440
  }
364
441
  ]
365
442
  ];
366
- const SquarePen = createLucideIcon("square-pen", __iconNode$1);
443
+ const SquarePen = createLucideIcon("square-pen", __iconNode$3);
444
+ /**
445
+ * @license lucide-react v0.552.0 - ISC
446
+ *
447
+ * This source code is licensed under the ISC license.
448
+ * See the LICENSE file in the root directory of this source tree.
449
+ */
450
+ const __iconNode$2 = [
451
+ [
452
+ "path",
453
+ {
454
+ d: "M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",
455
+ key: "r04s7s"
456
+ }
457
+ ]
458
+ ];
459
+ const Star = createLucideIcon("star", __iconNode$2);
460
+ /**
461
+ * @license lucide-react v0.552.0 - ISC
462
+ *
463
+ * This source code is licensed under the ISC license.
464
+ * See the LICENSE file in the root directory of this source tree.
465
+ */
466
+ const __iconNode$1 = [
467
+ ["path", { d: "M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2", key: "975kel" }],
468
+ ["circle", { cx: "12", cy: "7", r: "4", key: "17ys0d" }]
469
+ ];
470
+ const User = createLucideIcon("user", __iconNode$1);
367
471
  /**
368
472
  * @license lucide-react v0.552.0 - ISC
369
473
  *
@@ -26183,133 +26287,1205 @@ const CodeCityPanelContent = ({
26183
26287
  const CodeCityPanel = (props) => {
26184
26288
  return /* @__PURE__ */ jsx(CodeCityPanelContent, { ...props });
26185
26289
  };
26186
- const focusBuildingTool = {
26187
- name: "focus_building",
26188
- description: "Focuses the camera on a specific file (building) in the file city visualization",
26189
- inputs: {
26190
- type: "object",
26191
- properties: {
26192
- filePath: {
26193
- type: "string",
26194
- description: "Path to the file to focus on"
26195
- },
26196
- animate: {
26197
- type: "boolean",
26198
- description: "Whether to animate the camera transition"
26199
- }
26200
- },
26201
- required: ["filePath"]
26202
- },
26203
- outputs: {
26204
- type: "object",
26205
- properties: {
26206
- success: { type: "boolean" },
26207
- message: { type: "string" }
26208
- }
26209
- },
26210
- tags: ["navigation", "camera", "focus"],
26211
- tool_call_template: {
26212
- call_template_type: "panel_event",
26213
- event_type: "industry-theme.file-city-panel:focus-building"
26290
+ const NpmIcon$1 = ({ size: size2 }) => /* @__PURE__ */ jsx("svg", { width: size2, height: size2, viewBox: "0 0 24 24", fill: "#CB3837", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ jsx("path", { d: "M1.763 0C.786 0 0 .786 0 1.763v20.474C0 23.214.786 24 1.763 24h20.474c.977 0 1.763-.786 1.763-1.763V1.763C24 .786 23.214 0 22.237 0zM5.13 5.323l13.837.019-.009 13.836h-3.464l.01-10.382h-3.456L12.04 19.17H5.113z" }) });
26291
+ const YarnIcon$1 = ({ size: size2 }) => /* @__PURE__ */ jsx("svg", { width: size2, height: size2, viewBox: "0 0 24 24", fill: "#2C8EBB", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ jsx("path", { d: "M12 0C5.375 0 0 5.375 0 12s5.375 12 12 12 12-5.375 12-12S18.625 0 12 0zm.768 4.105c.183 0 .363.053.525.157.125.083.287.185.755 1.154.31-.088.468-.042.551-.019.204.056.366.19.463.375.477.917.542 2.553.334 3.605-.241 1.232-.755 2.029-1.131 2.576.324.329.778.899 1.117 1.825.278.774.31 1.478.273 2.015a5.51 5.51 0 0 0 .602-.329c.593-.366 1.487-.917 2.553-.931.714-.009 1.269.445 1.353 1.103a1.23 1.23 0 0 1-.945 1.362c-.649.158-.95.278-1.821.843-1.232.797-2.539 1.242-3.012 1.39a1.686 1.686 0 0 1-.704.343c-.737.181-3.266.315-3.466.315h-.046c-.783 0-1.214-.241-1.45-.491-.658.329-1.51.19-2.122-.134a1.078 1.078 0 0 1-.58-1.153 1.243 1.243 0 0 1-.153-.195c-.162-.25-.528-.936-.454-1.946.056-.723.556-1.367.88-1.71a5.522 5.522 0 0 1 .408-2.256c.306-.727.885-1.348 1.32-1.737-.32-.537-.644-1.367-.329-2.21.227-.602.412-.936.82-1.08h-.005c.199-.074.389-.153.486-.259a3.418 3.418 0 0 1 2.298-1.103c.037-.093.079-.185.125-.283.31-.658.639-1.029 1.024-1.168a.94.94 0 0 1 .328-.06z" }) });
26292
+ const PnpmIcon$1 = ({ size: size2 }) => /* @__PURE__ */ jsx("svg", { width: size2, height: size2, viewBox: "0 0 24 24", fill: "#F69220", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ jsx("path", { d: "M0 0v7.5h7.5V0zm8.25 0v7.5h7.498V0zm8.25 0v7.5H24V0zM8.25 8.25v7.5h7.498v-7.5zm8.25 0v7.5H24v-7.5zM0 16.5V24h7.5v-7.5zm8.25 0V24h7.498v-7.5zm8.25 0V24H24v-7.5z" }) });
26293
+ const BunIcon$1 = ({ size: size2 }) => /* @__PURE__ */ jsx("svg", { width: size2, height: size2, viewBox: "0 0 24 24", fill: "#FBF0DF", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ jsx("path", { d: "M12 22.596c6.628 0 12-4.338 12-9.688 0-3.318-2.057-6.248-5.219-7.986-1.286-.715-2.297-1.357-3.139-1.89C14.058 2.025 13.08 1.404 12 1.404c-1.097 0-2.334.785-3.966 1.821a49.92 49.92 0 0 1-2.816 1.697C2.057 6.66 0 9.59 0 12.908c0 5.35 5.372 9.687 12 9.687v.001Z" }) });
26294
+ const PackageManagerIcon$1 = ({
26295
+ packageManager,
26296
+ size: size2 = 14,
26297
+ color: color2
26298
+ }) => {
26299
+ switch (packageManager) {
26300
+ case "npm":
26301
+ return /* @__PURE__ */ jsx(NpmIcon$1, { size: size2 });
26302
+ case "yarn":
26303
+ return /* @__PURE__ */ jsx(YarnIcon$1, { size: size2 });
26304
+ case "pnpm":
26305
+ return /* @__PURE__ */ jsx(PnpmIcon$1, { size: size2 });
26306
+ case "bun":
26307
+ return /* @__PURE__ */ jsx(BunIcon$1, { size: size2 });
26308
+ default:
26309
+ return /* @__PURE__ */ jsx(Package, { size: size2, color: color2 });
26214
26310
  }
26215
26311
  };
26216
- const selectDistrictTool = {
26217
- name: "select_district",
26218
- description: "Selects and highlights a directory (district) in the file city visualization",
26219
- inputs: {
26220
- type: "object",
26221
- properties: {
26222
- directoryPath: {
26223
- type: "string",
26224
- description: "Path to the directory to select"
26225
- },
26226
- expandChildren: {
26227
- type: "boolean",
26228
- description: "Whether to expand and show child buildings"
26229
- }
26230
- },
26231
- required: ["directoryPath"]
26232
- },
26233
- outputs: {
26234
- type: "object",
26235
- properties: {
26236
- success: { type: "boolean" },
26237
- selectedDistrict: { type: "string" }
26312
+ const shimmerKeyframes = `
26313
+ @keyframes feed-header-shimmer {
26314
+ 0% { background-position: -200% 0; }
26315
+ 100% { background-position: 200% 0; }
26316
+ }
26317
+ `;
26318
+ let shimmerStyleInjected = false;
26319
+ function injectShimmerStyles() {
26320
+ if (shimmerStyleInjected || typeof document === "undefined") return;
26321
+ const style2 = document.createElement("style");
26322
+ style2.textContent = shimmerKeyframes;
26323
+ document.head.appendChild(style2);
26324
+ shimmerStyleInjected = true;
26325
+ }
26326
+ const ShimmerBox = ({ width, height, borderRadius = 4, backgroundColor }) => /* @__PURE__ */ jsx(
26327
+ "div",
26328
+ {
26329
+ style: {
26330
+ width,
26331
+ height,
26332
+ borderRadius,
26333
+ background: `linear-gradient(90deg, ${backgroundColor} 25%, ${adjustBrightness(backgroundColor, 15)} 50%, ${backgroundColor} 75%)`,
26334
+ backgroundSize: "200% 100%",
26335
+ animation: "feed-header-shimmer 1.5s ease-in-out infinite"
26238
26336
  }
26239
- },
26240
- tags: ["selection", "district", "directory"],
26241
- tool_call_template: {
26242
- call_template_type: "panel_event",
26243
- event_type: "industry-theme.file-city-panel:select-district"
26244
26337
  }
26245
- };
26246
- const resetViewTool = {
26247
- name: "reset_view",
26248
- description: "Resets the file city view to the default camera position",
26249
- inputs: {
26250
- type: "object",
26251
- properties: {
26252
- animate: {
26253
- type: "boolean",
26254
- description: "Whether to animate the camera reset"
26255
- }
26256
- }
26257
- },
26258
- outputs: {
26259
- type: "object",
26260
- properties: {
26261
- success: { type: "boolean" }
26262
- }
26263
- },
26264
- tags: ["navigation", "camera", "reset"],
26265
- tool_call_template: {
26266
- call_template_type: "panel_event",
26267
- event_type: "industry-theme.file-city-panel:reset-view"
26338
+ );
26339
+ function adjustBrightness(color2, percent) {
26340
+ if (color2.startsWith("#")) {
26341
+ const num = parseInt(color2.slice(1), 16);
26342
+ const r = Math.min(255, (num >> 16 & 255) + percent);
26343
+ const g = Math.min(255, (num >> 8 & 255) + percent);
26344
+ const b = Math.min(255, (num & 255) + percent);
26345
+ return `#${(r << 16 | g << 8 | b).toString(16).padStart(6, "0")}`;
26268
26346
  }
26347
+ return color2;
26348
+ }
26349
+ const FeedProjectHeaderSkeleton = ({ compact = false }) => {
26350
+ const { theme: theme2 } = useTheme();
26351
+ React.useEffect(() => {
26352
+ injectShimmerStyles();
26353
+ }, []);
26354
+ const shimmerBg = theme2.colors.backgroundLight || "#2a2a2a";
26355
+ return /* @__PURE__ */ jsxs(
26356
+ "div",
26357
+ {
26358
+ style: {
26359
+ display: "flex",
26360
+ flexDirection: "column",
26361
+ gap: compact ? 8 : 12,
26362
+ padding: compact ? "10px 12px" : "14px 16px",
26363
+ backgroundColor: theme2.colors.background,
26364
+ borderBottom: `1px solid ${theme2.colors.border}`
26365
+ },
26366
+ children: [
26367
+ /* @__PURE__ */ jsxs("div", { style: { display: "flex", alignItems: "center", justifyContent: "space-between", gap: 12 }, children: [
26368
+ /* @__PURE__ */ jsxs("div", { style: { display: "flex", alignItems: "center", gap: 10 }, children: [
26369
+ /* @__PURE__ */ jsx(ShimmerBox, { width: compact ? 24 : 28, height: compact ? 24 : 28, borderRadius: "50%", backgroundColor: shimmerBg }),
26370
+ /* @__PURE__ */ jsx(ShimmerBox, { width: 120, height: compact ? 16 : 18, backgroundColor: shimmerBg })
26371
+ ] }),
26372
+ /* @__PURE__ */ jsxs("div", { style: { display: "flex", alignItems: "center", gap: 12 }, children: [
26373
+ /* @__PURE__ */ jsx(ShimmerBox, { width: 50, height: 14, backgroundColor: shimmerBg }),
26374
+ /* @__PURE__ */ jsx(ShimmerBox, { width: 70, height: 28, borderRadius: 4, backgroundColor: shimmerBg })
26375
+ ] })
26376
+ ] }),
26377
+ !compact && /* @__PURE__ */ jsxs("div", { style: { display: "flex", flexDirection: "column", gap: 4 }, children: [
26378
+ /* @__PURE__ */ jsx(ShimmerBox, { width: "100%", height: 12, backgroundColor: shimmerBg }),
26379
+ /* @__PURE__ */ jsx(ShimmerBox, { width: "75%", height: 12, backgroundColor: shimmerBg })
26380
+ ] }),
26381
+ /* @__PURE__ */ jsxs("div", { style: { display: "flex", alignItems: "center", gap: compact ? 12 : 16 }, children: [
26382
+ /* @__PURE__ */ jsx(ShimmerBox, { width: 45, height: 14, backgroundColor: shimmerBg }),
26383
+ /* @__PURE__ */ jsx(ShimmerBox, { width: 45, height: 14, backgroundColor: shimmerBg }),
26384
+ /* @__PURE__ */ jsx(ShimmerBox, { width: 45, height: 14, backgroundColor: shimmerBg }),
26385
+ /* @__PURE__ */ jsx(ShimmerBox, { width: 55, height: 14, backgroundColor: shimmerBg })
26386
+ ] }),
26387
+ /* @__PURE__ */ jsxs(
26388
+ "div",
26389
+ {
26390
+ style: {
26391
+ display: "flex",
26392
+ alignItems: "center",
26393
+ gap: compact ? 12 : 16,
26394
+ paddingTop: compact ? 4 : 8,
26395
+ borderTop: `1px solid ${theme2.colors.border}`
26396
+ },
26397
+ children: [
26398
+ /* @__PURE__ */ jsx(ShimmerBox, { width: 80, height: 14, backgroundColor: shimmerBg }),
26399
+ /* @__PURE__ */ jsx(ShimmerBox, { width: 60, height: 18, borderRadius: 4, backgroundColor: shimmerBg }),
26400
+ /* @__PURE__ */ jsx(ShimmerBox, { width: 90, height: 14, backgroundColor: shimmerBg })
26401
+ ]
26402
+ }
26403
+ )
26404
+ ]
26405
+ }
26406
+ );
26269
26407
  };
26270
- const codeCityPanelTools = [
26271
- focusBuildingTool,
26272
- selectDistrictTool,
26273
- resetViewTool
26274
- ];
26275
- const codeCityPanelToolsMetadata = {
26276
- id: "industry-theme.file-city-panel",
26277
- name: "File City Panel",
26278
- description: "Tools provided by the file city visualization panel extension",
26279
- tools: codeCityPanelTools
26280
- };
26281
- const panels = [
26282
- {
26283
- metadata: {
26284
- id: "principal-ade.file-city-panel",
26285
- name: "File City Map",
26286
- icon: "🏙️",
26287
- version: "0.2.0",
26288
- author: "Principal AI",
26289
- description: "3D visualization of repository structure using the File City metaphor",
26290
- // Data slices this panel depends on
26291
- // - fileTree: Required - repository file structure
26292
- // - fileCityColorModes: Optional - controls which color modes are available
26293
- // (if not provided, only fileTypes and git modes are shown)
26294
- slices: ["fileTree", "fileCityColorModes"],
26295
- // UTCP-compatible tools this panel exposes
26296
- tools: codeCityPanelTools
26297
- },
26298
- component: CodeCityPanel,
26299
- // Optional: Called when this specific panel is mounted
26300
- onMount: async (context) => {
26301
- var _a;
26302
- console.log(
26303
- "File City Panel mounted",
26304
- (_a = context.currentScope.repository) == null ? void 0 : _a.path
26305
- );
26306
- if (context.hasSlice("fileTree") && !context.isSliceLoading("fileTree")) {
26307
- await context.refresh("repository", "fileTree");
26308
- }
26309
- },
26310
- // Optional: Called when this specific panel is unmounted
26311
- onUnmount: async (_context) => {
26312
- console.log("File City Panel unmounting");
26408
+ function formatCount(count2) {
26409
+ if (count2 >= 1e6) {
26410
+ return `${(count2 / 1e6).toFixed(1)}m`;
26411
+ }
26412
+ if (count2 >= 1e3) {
26413
+ return `${(count2 / 1e3).toFixed(1)}k`;
26414
+ }
26415
+ return count2.toString();
26416
+ }
26417
+ const FeedProjectHeader = ({
26418
+ repo,
26419
+ rootPackage,
26420
+ onOpen,
26421
+ compact = false
26422
+ }) => {
26423
+ const { theme: theme2 } = useTheme();
26424
+ const fontSizeSmall = theme2.fontSizes[0];
26425
+ const fontSizeMedium = theme2.fontSizes[1];
26426
+ const fontSizeLarge = theme2.fontSizes[2] || theme2.fontSizes[1];
26427
+ const totalDeps = rootPackage ? (rootPackage.dependencyCount || 0) + (rootPackage.devDependencyCount || 0) : 0;
26428
+ return /* @__PURE__ */ jsxs(
26429
+ "div",
26430
+ {
26431
+ style: {
26432
+ display: "flex",
26433
+ flexDirection: "column",
26434
+ gap: compact ? 8 : 12,
26435
+ padding: compact ? "10px 12px" : "14px 16px",
26436
+ backgroundColor: theme2.colors.background,
26437
+ borderBottom: `1px solid ${theme2.colors.border}`,
26438
+ fontFamily: theme2.fonts.body
26439
+ },
26440
+ children: [
26441
+ /* @__PURE__ */ jsxs(
26442
+ "div",
26443
+ {
26444
+ style: {
26445
+ display: "flex",
26446
+ alignItems: "center",
26447
+ justifyContent: "space-between",
26448
+ gap: 12
26449
+ },
26450
+ children: [
26451
+ /* @__PURE__ */ jsxs("div", { style: { display: "flex", alignItems: "center", gap: 10, flex: 1, minWidth: 0 }, children: [
26452
+ repo.avatarUrl ? /* @__PURE__ */ jsx(
26453
+ "img",
26454
+ {
26455
+ src: repo.avatarUrl,
26456
+ alt: repo.owner,
26457
+ style: {
26458
+ width: compact ? 24 : 28,
26459
+ height: compact ? 24 : 28,
26460
+ borderRadius: repo.isOrganization ? "6px" : "50%",
26461
+ flexShrink: 0
26462
+ }
26463
+ }
26464
+ ) : /* @__PURE__ */ jsx(
26465
+ "div",
26466
+ {
26467
+ style: {
26468
+ width: compact ? 24 : 28,
26469
+ height: compact ? 24 : 28,
26470
+ borderRadius: repo.isOrganization ? "6px" : "50%",
26471
+ backgroundColor: theme2.colors.backgroundLight,
26472
+ display: "flex",
26473
+ alignItems: "center",
26474
+ justifyContent: "center",
26475
+ flexShrink: 0
26476
+ },
26477
+ children: repo.isOrganization ? /* @__PURE__ */ jsx(Building2, { size: 14, color: theme2.colors.textSecondary }) : /* @__PURE__ */ jsx(User, { size: 14, color: theme2.colors.textSecondary })
26478
+ }
26479
+ ),
26480
+ /* @__PURE__ */ jsx(
26481
+ "span",
26482
+ {
26483
+ style: {
26484
+ fontSize: compact ? fontSizeMedium : fontSizeLarge,
26485
+ fontWeight: 600,
26486
+ color: theme2.colors.text,
26487
+ overflow: "hidden",
26488
+ textOverflow: "ellipsis",
26489
+ whiteSpace: "nowrap"
26490
+ },
26491
+ title: repo.fullName,
26492
+ children: repo.name
26493
+ }
26494
+ )
26495
+ ] }),
26496
+ /* @__PURE__ */ jsxs("div", { style: { display: "flex", alignItems: "center", gap: 12, flexShrink: 0 }, children: [
26497
+ repo.license && /* @__PURE__ */ jsxs(
26498
+ "div",
26499
+ {
26500
+ style: {
26501
+ display: "flex",
26502
+ alignItems: "center",
26503
+ gap: 4,
26504
+ fontSize: fontSizeSmall,
26505
+ color: theme2.colors.textSecondary
26506
+ },
26507
+ children: [
26508
+ /* @__PURE__ */ jsx(Scale, { size: 12 }),
26509
+ /* @__PURE__ */ jsx("span", { children: repo.license })
26510
+ ]
26511
+ }
26512
+ ),
26513
+ onOpen && /* @__PURE__ */ jsxs(
26514
+ "button",
26515
+ {
26516
+ onClick: onOpen,
26517
+ style: {
26518
+ display: "flex",
26519
+ alignItems: "center",
26520
+ gap: 4,
26521
+ padding: "5px 12px",
26522
+ fontSize: fontSizeSmall,
26523
+ fontWeight: 500,
26524
+ fontFamily: theme2.fonts.body,
26525
+ color: "#ffffff",
26526
+ backgroundColor: theme2.colors.primary,
26527
+ border: "none",
26528
+ borderRadius: "4px",
26529
+ cursor: "pointer",
26530
+ flexShrink: 0,
26531
+ transition: "opacity 0.15s ease"
26532
+ },
26533
+ onMouseEnter: (e) => {
26534
+ e.currentTarget.style.opacity = "0.9";
26535
+ },
26536
+ onMouseLeave: (e) => {
26537
+ e.currentTarget.style.opacity = "1";
26538
+ },
26539
+ children: [
26540
+ /* @__PURE__ */ jsx(ExternalLink, { size: 14 }),
26541
+ "Open"
26542
+ ]
26543
+ }
26544
+ )
26545
+ ] })
26546
+ ]
26547
+ }
26548
+ ),
26549
+ repo.description && !compact && /* @__PURE__ */ jsx(
26550
+ "p",
26551
+ {
26552
+ style: {
26553
+ margin: 0,
26554
+ fontSize: fontSizeSmall,
26555
+ color: theme2.colors.textSecondary,
26556
+ lineHeight: 1.4,
26557
+ display: "-webkit-box",
26558
+ WebkitLineClamp: 2,
26559
+ WebkitBoxOrient: "vertical",
26560
+ overflow: "hidden"
26561
+ },
26562
+ title: repo.description,
26563
+ children: repo.description
26564
+ }
26565
+ ),
26566
+ /* @__PURE__ */ jsxs(
26567
+ "div",
26568
+ {
26569
+ style: {
26570
+ display: "flex",
26571
+ alignItems: "center",
26572
+ gap: compact ? 12 : 16,
26573
+ flexWrap: "wrap"
26574
+ },
26575
+ children: [
26576
+ /* @__PURE__ */ jsxs(
26577
+ "div",
26578
+ {
26579
+ style: {
26580
+ display: "flex",
26581
+ alignItems: "center",
26582
+ gap: 4,
26583
+ fontSize: fontSizeSmall,
26584
+ color: theme2.colors.textSecondary
26585
+ },
26586
+ title: `${repo.stars.toLocaleString()} stars`,
26587
+ children: [
26588
+ /* @__PURE__ */ jsx(Star, { size: 13 }),
26589
+ /* @__PURE__ */ jsx("span", { children: formatCount(repo.stars) })
26590
+ ]
26591
+ }
26592
+ ),
26593
+ /* @__PURE__ */ jsxs(
26594
+ "div",
26595
+ {
26596
+ style: {
26597
+ display: "flex",
26598
+ alignItems: "center",
26599
+ gap: 4,
26600
+ fontSize: fontSizeSmall,
26601
+ color: theme2.colors.textSecondary
26602
+ },
26603
+ title: `${repo.forks.toLocaleString()} forks`,
26604
+ children: [
26605
+ /* @__PURE__ */ jsx(GitFork, { size: 13 }),
26606
+ /* @__PURE__ */ jsx("span", { children: formatCount(repo.forks) })
26607
+ ]
26608
+ }
26609
+ ),
26610
+ repo.watchers !== void 0 && /* @__PURE__ */ jsxs(
26611
+ "div",
26612
+ {
26613
+ style: {
26614
+ display: "flex",
26615
+ alignItems: "center",
26616
+ gap: 4,
26617
+ fontSize: fontSizeSmall,
26618
+ color: theme2.colors.textSecondary
26619
+ },
26620
+ title: `${repo.watchers.toLocaleString()} watching`,
26621
+ children: [
26622
+ /* @__PURE__ */ jsx(Eye, { size: 13 }),
26623
+ /* @__PURE__ */ jsx("span", { children: formatCount(repo.watchers) })
26624
+ ]
26625
+ }
26626
+ ),
26627
+ repo.openIssues !== void 0 && repo.openIssues > 0 && /* @__PURE__ */ jsxs(
26628
+ "div",
26629
+ {
26630
+ style: {
26631
+ display: "flex",
26632
+ alignItems: "center",
26633
+ gap: 4,
26634
+ fontSize: fontSizeSmall,
26635
+ color: theme2.colors.textSecondary
26636
+ },
26637
+ title: `${repo.openIssues.toLocaleString()} open issues`,
26638
+ children: [
26639
+ /* @__PURE__ */ jsx(CircleAlert, { size: 13 }),
26640
+ /* @__PURE__ */ jsx("span", { children: formatCount(repo.openIssues) })
26641
+ ]
26642
+ }
26643
+ ),
26644
+ repo.htmlUrl && /* @__PURE__ */ jsxs(
26645
+ "a",
26646
+ {
26647
+ href: repo.htmlUrl,
26648
+ target: "_blank",
26649
+ rel: "noopener noreferrer",
26650
+ style: {
26651
+ display: "flex",
26652
+ alignItems: "center",
26653
+ gap: 4,
26654
+ fontSize: fontSizeSmall,
26655
+ color: theme2.colors.textSecondary,
26656
+ textDecoration: "none"
26657
+ },
26658
+ title: repo.htmlUrl,
26659
+ children: [
26660
+ /* @__PURE__ */ jsx(ExternalLink, { size: 12 }),
26661
+ /* @__PURE__ */ jsx("span", { children: "GitHub" })
26662
+ ]
26663
+ }
26664
+ )
26665
+ ]
26666
+ }
26667
+ ),
26668
+ rootPackage && /* @__PURE__ */ jsxs(
26669
+ "div",
26670
+ {
26671
+ style: {
26672
+ display: "flex",
26673
+ alignItems: "center",
26674
+ gap: compact ? 12 : 16,
26675
+ flexWrap: "wrap",
26676
+ paddingTop: compact ? 4 : 8,
26677
+ borderTop: `1px solid ${theme2.colors.border}`
26678
+ },
26679
+ children: [
26680
+ rootPackage.packageManager && /* @__PURE__ */ jsxs(
26681
+ "div",
26682
+ {
26683
+ style: {
26684
+ display: "flex",
26685
+ alignItems: "center",
26686
+ gap: 6
26687
+ },
26688
+ children: [
26689
+ /* @__PURE__ */ jsx(
26690
+ PackageManagerIcon$1,
26691
+ {
26692
+ packageManager: rootPackage.packageManager,
26693
+ size: 14,
26694
+ color: theme2.colors.textSecondary
26695
+ }
26696
+ ),
26697
+ rootPackage.name && /* @__PURE__ */ jsx(
26698
+ "span",
26699
+ {
26700
+ style: {
26701
+ fontSize: fontSizeSmall,
26702
+ color: theme2.colors.text,
26703
+ fontWeight: 500
26704
+ },
26705
+ children: rootPackage.name
26706
+ }
26707
+ ),
26708
+ rootPackage.version && /* @__PURE__ */ jsxs(
26709
+ "span",
26710
+ {
26711
+ style: {
26712
+ fontSize: fontSizeSmall,
26713
+ color: theme2.colors.textSecondary,
26714
+ backgroundColor: theme2.colors.backgroundLight,
26715
+ padding: "1px 5px",
26716
+ borderRadius: "3px"
26717
+ },
26718
+ children: [
26719
+ "v",
26720
+ rootPackage.version
26721
+ ]
26722
+ }
26723
+ )
26724
+ ]
26725
+ }
26726
+ ),
26727
+ rootPackage.isMonorepo && /* @__PURE__ */ jsxs(
26728
+ "span",
26729
+ {
26730
+ style: {
26731
+ display: "flex",
26732
+ alignItems: "center",
26733
+ gap: 4,
26734
+ fontSize: fontSizeSmall,
26735
+ color: "#8b5cf6",
26736
+ backgroundColor: "rgba(139, 92, 246, 0.15)",
26737
+ padding: "2px 6px",
26738
+ borderRadius: "4px"
26739
+ },
26740
+ children: [
26741
+ /* @__PURE__ */ jsx(GitBranch, { size: 12 }),
26742
+ rootPackage.packageCount ? `${rootPackage.packageCount} packages` : "monorepo"
26743
+ ]
26744
+ }
26745
+ ),
26746
+ totalDeps > 0 && /* @__PURE__ */ jsxs(
26747
+ "div",
26748
+ {
26749
+ style: {
26750
+ display: "flex",
26751
+ alignItems: "center",
26752
+ gap: 4,
26753
+ fontSize: fontSizeSmall,
26754
+ color: theme2.colors.textSecondary
26755
+ },
26756
+ title: `${rootPackage.dependencyCount || 0} prod, ${rootPackage.devDependencyCount || 0} dev dependencies`,
26757
+ children: [
26758
+ /* @__PURE__ */ jsx(Box, { size: 12 }),
26759
+ /* @__PURE__ */ jsxs("span", { children: [
26760
+ rootPackage.dependencyCount || 0,
26761
+ " deps",
26762
+ rootPackage.devDependencyCount ? ` + ${rootPackage.devDependencyCount} dev` : ""
26763
+ ] })
26764
+ ]
26765
+ }
26766
+ )
26767
+ ]
26768
+ }
26769
+ )
26770
+ ]
26771
+ }
26772
+ );
26773
+ };
26774
+ const FeedCodeCityPanelContent = ({
26775
+ context,
26776
+ actions: actions2,
26777
+ events
26778
+ }) => {
26779
+ var _a, _b, _c, _d, _e, _f, _g;
26780
+ const { theme: theme2 } = useTheme();
26781
+ const [cityData, setCityData] = useState(null);
26782
+ const [hoverInfo, setHoverInfo] = useState(null);
26783
+ const [highlightLayers, setHighlightLayers] = useState([]);
26784
+ const [loading, setLoading] = useState(false);
26785
+ const [containerSize, setContainerSize] = useState(null);
26786
+ const contentContainerRef = useRef(null);
26787
+ const feedProjectSlice = context.getSlice("feedProject");
26788
+ const LEGEND_MIN_SIZE = 200;
26789
+ const HOVER_BAR_HEIGHT = 48;
26790
+ useEffect(() => {
26791
+ const container = contentContainerRef.current;
26792
+ if (!container) return;
26793
+ const resizeObserver = new ResizeObserver((entries) => {
26794
+ for (const entry of entries) {
26795
+ const { width, height } = entry.contentRect;
26796
+ setContainerSize({ width, height });
26797
+ }
26798
+ });
26799
+ resizeObserver.observe(container);
26800
+ return () => resizeObserver.disconnect();
26801
+ }, []);
26802
+ const layout = useMemo(() => {
26803
+ if (!containerSize) {
26804
+ return { mapSize: 0, legendPosition: "bottom" };
26805
+ }
26806
+ const { width, height } = containerSize;
26807
+ const isLandscape = width > height;
26808
+ if (isLandscape) {
26809
+ const idealMapSize = height;
26810
+ const availableForLegend = width - idealMapSize;
26811
+ const legendNeedsMoreSpace = availableForLegend < LEGEND_MIN_SIZE;
26812
+ const mapSize = legendNeedsMoreSpace ? width - LEGEND_MIN_SIZE : idealMapSize;
26813
+ return { mapSize, legendPosition: "right" };
26814
+ } else {
26815
+ const idealMapHeight = width + HOVER_BAR_HEIGHT;
26816
+ const availableForLegend = height - idealMapHeight;
26817
+ const legendNeedsMoreSpace = availableForLegend < LEGEND_MIN_SIZE;
26818
+ const mapSize = legendNeedsMoreSpace ? height - LEGEND_MIN_SIZE : idealMapHeight;
26819
+ return { mapSize, legendPosition: "bottom" };
26820
+ }
26821
+ }, [containerSize]);
26822
+ const fileTreeSlice = context.getSlice("fileTree");
26823
+ useEffect(() => {
26824
+ if (!(fileTreeSlice == null ? void 0 : fileTreeSlice.data) || fileTreeSlice.loading) {
26825
+ return;
26826
+ }
26827
+ setLoading(true);
26828
+ try {
26829
+ const fileInfoList = fileTreeSlice.data.allFiles.map((file) => {
26830
+ const pathParts = file.path.split("/");
26831
+ const fileName = file.name || pathParts[pathParts.length - 1];
26832
+ const extension = fileName.includes(".") ? fileName.split(".").pop() || "" : "";
26833
+ return {
26834
+ path: file.path,
26835
+ name: fileName,
26836
+ extension,
26837
+ size: file.size || 1e3,
26838
+ lastModified: /* @__PURE__ */ new Date(),
26839
+ isDirectory: false,
26840
+ relativePath: file.path
26841
+ };
26842
+ });
26843
+ const fileSystemTree = buildFileSystemTreeFromFileInfoList(
26844
+ fileInfoList,
26845
+ fileTreeSlice.data.sha || "unknown"
26846
+ );
26847
+ const builder = new CodeCityBuilderWithGrid();
26848
+ const data = builder.buildCityFromFileSystem(fileSystemTree, "");
26849
+ setCityData(data);
26850
+ if (data.buildings) {
26851
+ const fileTypeLayers = distExports.createFileColorHighlightLayers(data.buildings);
26852
+ setHighlightLayers(fileTypeLayers);
26853
+ }
26854
+ } catch (error) {
26855
+ console.error("Error building city:", error);
26856
+ } finally {
26857
+ setLoading(false);
26858
+ }
26859
+ }, [fileTreeSlice == null ? void 0 : fileTreeSlice.data, fileTreeSlice == null ? void 0 : fileTreeSlice.loading]);
26860
+ const legendFileTypes = useMemo(() => {
26861
+ return highlightLayers.filter((layer) => layer.id.endsWith("-primary")).map((layer) => ({
26862
+ id: layer.id,
26863
+ name: layer.name,
26864
+ fillColor: layer.color,
26865
+ count: layer.items.length,
26866
+ enabled: layer.enabled
26867
+ }));
26868
+ }, [highlightLayers]);
26869
+ const toggleFileType = useCallback((id2) => {
26870
+ setHighlightLayers(
26871
+ (prev) => prev.map((layer) => {
26872
+ if (layer.id === id2 || layer.id === id2.replace("-primary", "-secondary")) {
26873
+ return { ...layer, enabled: !layer.enabled };
26874
+ }
26875
+ return layer;
26876
+ })
26877
+ );
26878
+ }, []);
26879
+ const handleHover = useCallback((info) => {
26880
+ setHoverInfo(info);
26881
+ }, []);
26882
+ const handleFileClick = useCallback(
26883
+ (filePath) => {
26884
+ if (actions2.openFile) {
26885
+ actions2.openFile(filePath);
26886
+ }
26887
+ },
26888
+ [actions2]
26889
+ );
26890
+ const handleOpen = useCallback(() => {
26891
+ var _a2;
26892
+ if (((_a2 = feedProjectSlice == null ? void 0 : feedProjectSlice.data) == null ? void 0 : _a2.repo) && events) {
26893
+ events.emit({
26894
+ type: "project:open",
26895
+ source: "feed-code-city-panel",
26896
+ timestamp: Date.now(),
26897
+ payload: {
26898
+ repo: feedProjectSlice.data.repo,
26899
+ rootPackage: feedProjectSlice.data.rootPackage
26900
+ }
26901
+ });
26902
+ }
26903
+ }, [events, feedProjectSlice == null ? void 0 : feedProjectSlice.data]);
26904
+ return /* @__PURE__ */ jsxs(
26905
+ "div",
26906
+ {
26907
+ style: {
26908
+ display: "flex",
26909
+ flexDirection: "column",
26910
+ height: "100%",
26911
+ width: "100%",
26912
+ backgroundColor: theme2.colors.background
26913
+ },
26914
+ children: [
26915
+ (feedProjectSlice == null ? void 0 : feedProjectSlice.loading) ? /* @__PURE__ */ jsx(FeedProjectHeaderSkeleton, {}) : ((_a = feedProjectSlice == null ? void 0 : feedProjectSlice.data) == null ? void 0 : _a.repo) ? /* @__PURE__ */ jsx(
26916
+ FeedProjectHeader,
26917
+ {
26918
+ repo: feedProjectSlice.data.repo,
26919
+ rootPackage: feedProjectSlice.data.rootPackage,
26920
+ onOpen: handleOpen
26921
+ }
26922
+ ) : null,
26923
+ /* @__PURE__ */ jsxs(
26924
+ "div",
26925
+ {
26926
+ ref: contentContainerRef,
26927
+ style: {
26928
+ flex: 1,
26929
+ width: "100%",
26930
+ position: "relative",
26931
+ overflow: "hidden",
26932
+ display: "flex",
26933
+ flexDirection: layout.legendPosition === "right" ? "row" : "column"
26934
+ },
26935
+ children: [
26936
+ /* @__PURE__ */ jsxs(
26937
+ "div",
26938
+ {
26939
+ style: {
26940
+ width: layout.legendPosition === "right" ? layout.mapSize : "100%",
26941
+ height: layout.legendPosition === "bottom" ? layout.mapSize : "100%",
26942
+ flexShrink: 0,
26943
+ position: "relative",
26944
+ display: "flex",
26945
+ flexDirection: "column"
26946
+ },
26947
+ children: [
26948
+ /* @__PURE__ */ jsx("div", { style: { flex: 1, position: "relative", minHeight: 0 }, children: loading ? /* @__PURE__ */ jsx(
26949
+ "div",
26950
+ {
26951
+ style: {
26952
+ display: "flex",
26953
+ alignItems: "center",
26954
+ justifyContent: "center",
26955
+ height: "100%",
26956
+ color: theme2.colors.textSecondary
26957
+ },
26958
+ children: "Loading repository structure..."
26959
+ }
26960
+ ) : !cityData ? /* @__PURE__ */ jsxs(
26961
+ "div",
26962
+ {
26963
+ style: {
26964
+ display: "flex",
26965
+ flexDirection: "column",
26966
+ alignItems: "center",
26967
+ justifyContent: "center",
26968
+ height: "100%",
26969
+ color: theme2.colors.textSecondary,
26970
+ gap: "12px"
26971
+ },
26972
+ children: [
26973
+ /* @__PURE__ */ jsx(Building2, { size: 32, style: { opacity: 0.5 } }),
26974
+ /* @__PURE__ */ jsx("div", { children: context.currentScope.repository ? "Building File City..." : "No repository loaded" })
26975
+ ]
26976
+ }
26977
+ ) : /* @__PURE__ */ jsx(
26978
+ distExports.ArchitectureMapHighlightLayers,
26979
+ {
26980
+ cityData,
26981
+ highlightLayers,
26982
+ showLayerControls: false,
26983
+ onLayerToggle: () => {
26984
+ },
26985
+ defaultDirectoryColor: "#111827",
26986
+ onFileClick: handleFileClick,
26987
+ showFileTypeIcons: true,
26988
+ className: "w-full h-full",
26989
+ showDirectoryLabels: true,
26990
+ onHover: handleHover,
26991
+ enableZoom: false,
26992
+ allowZoomToPath: true,
26993
+ zoomAnimationSpeed: 0.12
26994
+ }
26995
+ ) }),
26996
+ /* @__PURE__ */ jsx(
26997
+ "div",
26998
+ {
26999
+ style: {
27000
+ height: "48px",
27001
+ borderTop: `1px solid ${theme2.colors.border}`,
27002
+ backgroundColor: theme2.colors.background,
27003
+ display: "flex",
27004
+ alignItems: "center",
27005
+ padding: "0 12px",
27006
+ fontSize: theme2.fontSizes[0],
27007
+ fontFamily: theme2.fonts.body,
27008
+ color: theme2.colors.text,
27009
+ flexShrink: 0
27010
+ },
27011
+ children: hoverInfo && (hoverInfo.hoveredBuilding || hoverInfo.hoveredDistrict) ? /* @__PURE__ */ jsxs(Fragment, { children: [
27012
+ /* @__PURE__ */ jsxs(
27013
+ "div",
27014
+ {
27015
+ style: {
27016
+ flex: "1 1 auto",
27017
+ display: "flex",
27018
+ flexDirection: "column",
27019
+ gap: "1px",
27020
+ minWidth: 0
27021
+ },
27022
+ children: [
27023
+ /* @__PURE__ */ jsx(
27024
+ "div",
27025
+ {
27026
+ style: {
27027
+ fontWeight: 600,
27028
+ fontFamily: theme2.fonts.monospace,
27029
+ color: theme2.colors.primary,
27030
+ fontSize: theme2.fontSizes[1],
27031
+ overflow: "hidden",
27032
+ textOverflow: "ellipsis",
27033
+ whiteSpace: "nowrap"
27034
+ },
27035
+ children: ((_b = hoverInfo.fileTooltip) == null ? void 0 : _b.text) || ((_d = (_c = hoverInfo.hoveredDistrict) == null ? void 0 : _c.path) == null ? void 0 : _d.split("/").pop()) || ((_e = hoverInfo.hoveredDistrict) == null ? void 0 : _e.path) || "Unknown"
27036
+ }
27037
+ ),
27038
+ /* @__PURE__ */ jsx(
27039
+ "div",
27040
+ {
27041
+ style: {
27042
+ fontFamily: theme2.fonts.monospace,
27043
+ color: theme2.colors.textSecondary,
27044
+ fontSize: theme2.fontSizes[0],
27045
+ overflow: "hidden",
27046
+ textOverflow: "ellipsis",
27047
+ whiteSpace: "nowrap"
27048
+ },
27049
+ children: ((_f = hoverInfo.hoveredBuilding) == null ? void 0 : _f.path) || ((_g = hoverInfo.hoveredDistrict) == null ? void 0 : _g.path) || "/"
27050
+ }
27051
+ )
27052
+ ]
27053
+ }
27054
+ ),
27055
+ hoverInfo.hoveredDistrict && hoverInfo.fileCount !== null && /* @__PURE__ */ jsxs(
27056
+ "div",
27057
+ {
27058
+ style: {
27059
+ fontSize: theme2.fontSizes[0],
27060
+ color: theme2.colors.textSecondary,
27061
+ whiteSpace: "nowrap"
27062
+ },
27063
+ children: [
27064
+ hoverInfo.fileCount,
27065
+ " ",
27066
+ hoverInfo.fileCount === 1 ? "file" : "files"
27067
+ ]
27068
+ }
27069
+ )
27070
+ ] }) : /* @__PURE__ */ jsx("div", { style: { color: theme2.colors.textSecondary, fontStyle: "italic" }, children: "Hover over the map to see file details" })
27071
+ }
27072
+ )
27073
+ ]
27074
+ }
27075
+ ),
27076
+ /* @__PURE__ */ jsx(
27077
+ Legend,
27078
+ {
27079
+ fileTypes: legendFileTypes,
27080
+ onItemClick: toggleFileType,
27081
+ position: layout.legendPosition
27082
+ }
27083
+ )
27084
+ ]
27085
+ }
27086
+ )
27087
+ ]
27088
+ }
27089
+ );
27090
+ };
27091
+ const FeedCodeCityPanel = (props) => {
27092
+ return /* @__PURE__ */ jsx(FeedCodeCityPanelContent, { ...props });
27093
+ };
27094
+ const focusBuildingTool = {
27095
+ name: "focus_building",
27096
+ description: "Focuses the camera on a specific file (building) in the file city visualization",
27097
+ inputs: {
27098
+ type: "object",
27099
+ properties: {
27100
+ filePath: {
27101
+ type: "string",
27102
+ description: "Path to the file to focus on"
27103
+ },
27104
+ animate: {
27105
+ type: "boolean",
27106
+ description: "Whether to animate the camera transition"
27107
+ }
27108
+ },
27109
+ required: ["filePath"]
27110
+ },
27111
+ outputs: {
27112
+ type: "object",
27113
+ properties: {
27114
+ success: { type: "boolean" },
27115
+ message: { type: "string" }
27116
+ }
27117
+ },
27118
+ tags: ["navigation", "camera", "focus"],
27119
+ tool_call_template: {
27120
+ call_template_type: "panel_event",
27121
+ event_type: "industry-theme.file-city-panel:focus-building"
27122
+ }
27123
+ };
27124
+ const selectDistrictTool = {
27125
+ name: "select_district",
27126
+ description: "Selects and highlights a directory (district) in the file city visualization",
27127
+ inputs: {
27128
+ type: "object",
27129
+ properties: {
27130
+ directoryPath: {
27131
+ type: "string",
27132
+ description: "Path to the directory to select"
27133
+ },
27134
+ expandChildren: {
27135
+ type: "boolean",
27136
+ description: "Whether to expand and show child buildings"
27137
+ }
27138
+ },
27139
+ required: ["directoryPath"]
27140
+ },
27141
+ outputs: {
27142
+ type: "object",
27143
+ properties: {
27144
+ success: { type: "boolean" },
27145
+ selectedDistrict: { type: "string" }
27146
+ }
27147
+ },
27148
+ tags: ["selection", "district", "directory"],
27149
+ tool_call_template: {
27150
+ call_template_type: "panel_event",
27151
+ event_type: "industry-theme.file-city-panel:select-district"
27152
+ }
27153
+ };
27154
+ const resetViewTool = {
27155
+ name: "reset_view",
27156
+ description: "Resets the file city view to the default camera position",
27157
+ inputs: {
27158
+ type: "object",
27159
+ properties: {
27160
+ animate: {
27161
+ type: "boolean",
27162
+ description: "Whether to animate the camera reset"
27163
+ }
27164
+ }
27165
+ },
27166
+ outputs: {
27167
+ type: "object",
27168
+ properties: {
27169
+ success: { type: "boolean" }
27170
+ }
27171
+ },
27172
+ tags: ["navigation", "camera", "reset"],
27173
+ tool_call_template: {
27174
+ call_template_type: "panel_event",
27175
+ event_type: "industry-theme.file-city-panel:reset-view"
27176
+ }
27177
+ };
27178
+ const codeCityPanelTools = [
27179
+ focusBuildingTool,
27180
+ selectDistrictTool,
27181
+ resetViewTool
27182
+ ];
27183
+ const codeCityPanelToolsMetadata = {
27184
+ id: "industry-theme.file-city-panel",
27185
+ name: "File City Panel",
27186
+ description: "Tools provided by the file city visualization panel extension",
27187
+ tools: codeCityPanelTools
27188
+ };
27189
+ const NpmIcon = ({ size: size2 }) => /* @__PURE__ */ jsx("svg", { width: size2, height: size2, viewBox: "0 0 24 24", fill: "#CB3837", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ jsx("path", { d: "M1.763 0C.786 0 0 .786 0 1.763v20.474C0 23.214.786 24 1.763 24h20.474c.977 0 1.763-.786 1.763-1.763V1.763C24 .786 23.214 0 22.237 0zM5.13 5.323l13.837.019-.009 13.836h-3.464l.01-10.382h-3.456L12.04 19.17H5.113z" }) });
27190
+ const YarnIcon = ({ size: size2 }) => /* @__PURE__ */ jsx("svg", { width: size2, height: size2, viewBox: "0 0 24 24", fill: "#2C8EBB", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ jsx("path", { d: "M12 0C5.375 0 0 5.375 0 12s5.375 12 12 12 12-5.375 12-12S18.625 0 12 0zm.768 4.105c.183 0 .363.053.525.157.125.083.287.185.755 1.154.31-.088.468-.042.551-.019.204.056.366.19.463.375.477.917.542 2.553.334 3.605-.241 1.232-.755 2.029-1.131 2.576.324.329.778.899 1.117 1.825.278.774.31 1.478.273 2.015a5.51 5.51 0 0 0 .602-.329c.593-.366 1.487-.917 2.553-.931.714-.009 1.269.445 1.353 1.103a1.23 1.23 0 0 1-.945 1.362c-.649.158-.95.278-1.821.843-1.232.797-2.539 1.242-3.012 1.39a1.686 1.686 0 0 1-.704.343c-.737.181-3.266.315-3.466.315h-.046c-.783 0-1.214-.241-1.45-.491-.658.329-1.51.19-2.122-.134a1.078 1.078 0 0 1-.58-1.153 1.243 1.243 0 0 1-.153-.195c-.162-.25-.528-.936-.454-1.946.056-.723.556-1.367.88-1.71a5.522 5.522 0 0 1 .408-2.256c.306-.727.885-1.348 1.32-1.737-.32-.537-.644-1.367-.329-2.21.227-.602.412-.936.82-1.08h-.005c.199-.074.389-.153.486-.259a3.418 3.418 0 0 1 2.298-1.103c.037-.093.079-.185.125-.283.31-.658.639-1.029 1.024-1.168a.94.94 0 0 1 .328-.06z" }) });
27191
+ const PnpmIcon = ({ size: size2 }) => /* @__PURE__ */ jsx("svg", { width: size2, height: size2, viewBox: "0 0 24 24", fill: "#F69220", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ jsx("path", { d: "M0 0v7.5h7.5V0zm8.25 0v7.5h7.498V0zm8.25 0v7.5H24V0zM8.25 8.25v7.5h7.498v-7.5zm8.25 0v7.5H24v-7.5zM0 16.5V24h7.5v-7.5zm8.25 0V24h7.498v-7.5zm8.25 0V24H24v-7.5z" }) });
27192
+ const BunIcon = ({ size: size2 }) => /* @__PURE__ */ jsx("svg", { width: size2, height: size2, viewBox: "0 0 24 24", fill: "#FBF0DF", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ jsx("path", { d: "M12 22.596c6.628 0 12-4.338 12-9.688 0-3.318-2.057-6.248-5.219-7.986-1.286-.715-2.297-1.357-3.139-1.89C14.058 2.025 13.08 1.404 12 1.404c-1.097 0-2.334.785-3.966 1.821a49.92 49.92 0 0 1-2.816 1.697C2.057 6.66 0 9.59 0 12.908c0 5.35 5.372 9.687 12 9.687v.001Z" }) });
27193
+ const PackageManagerIcon = ({
27194
+ packageManager,
27195
+ size: size2 = 16,
27196
+ color: color2
27197
+ }) => {
27198
+ switch (packageManager) {
27199
+ case "npm":
27200
+ return /* @__PURE__ */ jsx(NpmIcon, { size: size2 });
27201
+ case "yarn":
27202
+ return /* @__PURE__ */ jsx(YarnIcon, { size: size2 });
27203
+ case "pnpm":
27204
+ return /* @__PURE__ */ jsx(PnpmIcon, { size: size2 });
27205
+ case "bun":
27206
+ return /* @__PURE__ */ jsx(BunIcon, { size: size2 });
27207
+ default:
27208
+ return /* @__PURE__ */ jsx(Package, { size: size2, color: color2 });
27209
+ }
27210
+ };
27211
+ const ProjectInfoHeader = ({
27212
+ project,
27213
+ onOpen,
27214
+ compact = false
27215
+ }) => {
27216
+ const { theme: theme2 } = useTheme();
27217
+ const totalDeps = (project.dependencyCount || 0) + (project.devDependencyCount || 0);
27218
+ const fontSizeSmall = theme2.fontSizes[0];
27219
+ const fontSizeMedium = theme2.fontSizes[1];
27220
+ const fontSizeLarge = theme2.fontSizes[2] || theme2.fontSizes[1];
27221
+ return /* @__PURE__ */ jsxs(
27222
+ "div",
27223
+ {
27224
+ style: {
27225
+ display: "flex",
27226
+ flexDirection: "column",
27227
+ gap: compact ? 4 : 8,
27228
+ padding: compact ? "8px 12px" : "12px 16px",
27229
+ backgroundColor: theme2.colors.background,
27230
+ borderBottom: `1px solid ${theme2.colors.border}`,
27231
+ fontFamily: theme2.fonts.body,
27232
+ minHeight: compact ? 48 : "auto"
27233
+ },
27234
+ children: [
27235
+ /* @__PURE__ */ jsxs(
27236
+ "div",
27237
+ {
27238
+ style: {
27239
+ display: "flex",
27240
+ alignItems: "center",
27241
+ justifyContent: "space-between",
27242
+ gap: 12
27243
+ },
27244
+ children: [
27245
+ /* @__PURE__ */ jsxs("div", { style: { display: "flex", alignItems: "center", gap: 8, flex: 1, minWidth: 0 }, children: [
27246
+ project.packageManager && /* @__PURE__ */ jsx("div", { style: { flexShrink: 0 }, children: /* @__PURE__ */ jsx(
27247
+ PackageManagerIcon,
27248
+ {
27249
+ packageManager: project.packageManager,
27250
+ size: compact ? 18 : 20,
27251
+ color: theme2.colors.textSecondary
27252
+ }
27253
+ ) }),
27254
+ /* @__PURE__ */ jsx(
27255
+ "span",
27256
+ {
27257
+ style: {
27258
+ fontSize: compact ? fontSizeMedium : fontSizeLarge,
27259
+ fontWeight: 600,
27260
+ color: theme2.colors.text,
27261
+ overflow: "hidden",
27262
+ textOverflow: "ellipsis",
27263
+ whiteSpace: "nowrap"
27264
+ },
27265
+ title: project.name,
27266
+ children: project.name
27267
+ }
27268
+ ),
27269
+ project.version && /* @__PURE__ */ jsxs(
27270
+ "span",
27271
+ {
27272
+ style: {
27273
+ fontSize: fontSizeSmall,
27274
+ color: theme2.colors.textSecondary,
27275
+ backgroundColor: theme2.colors.backgroundLight,
27276
+ padding: "2px 6px",
27277
+ borderRadius: "4px",
27278
+ flexShrink: 0
27279
+ },
27280
+ children: [
27281
+ "v",
27282
+ project.version
27283
+ ]
27284
+ }
27285
+ ),
27286
+ project.isMonorepo && /* @__PURE__ */ jsxs(
27287
+ "span",
27288
+ {
27289
+ style: {
27290
+ display: "flex",
27291
+ alignItems: "center",
27292
+ gap: 4,
27293
+ fontSize: fontSizeSmall,
27294
+ color: "#8b5cf6",
27295
+ backgroundColor: "rgba(139, 92, 246, 0.15)",
27296
+ padding: "2px 6px",
27297
+ borderRadius: "4px",
27298
+ flexShrink: 0
27299
+ },
27300
+ children: [
27301
+ /* @__PURE__ */ jsx(GitBranch, { size: 12 }),
27302
+ project.packageCount ? `${project.packageCount} packages` : "monorepo"
27303
+ ]
27304
+ }
27305
+ )
27306
+ ] }),
27307
+ onOpen && /* @__PURE__ */ jsxs(
27308
+ "button",
27309
+ {
27310
+ onClick: onOpen,
27311
+ style: {
27312
+ display: "flex",
27313
+ alignItems: "center",
27314
+ gap: 4,
27315
+ padding: "4px 10px",
27316
+ fontSize: fontSizeSmall,
27317
+ fontWeight: 500,
27318
+ fontFamily: theme2.fonts.body,
27319
+ color: "#ffffff",
27320
+ backgroundColor: theme2.colors.primary,
27321
+ border: "none",
27322
+ borderRadius: "4px",
27323
+ cursor: "pointer",
27324
+ flexShrink: 0,
27325
+ transition: "opacity 0.15s ease"
27326
+ },
27327
+ onMouseEnter: (e) => {
27328
+ e.currentTarget.style.opacity = "0.9";
27329
+ },
27330
+ onMouseLeave: (e) => {
27331
+ e.currentTarget.style.opacity = "1";
27332
+ },
27333
+ children: [
27334
+ /* @__PURE__ */ jsx(ExternalLink, { size: 14 }),
27335
+ "Open"
27336
+ ]
27337
+ }
27338
+ )
27339
+ ]
27340
+ }
27341
+ ),
27342
+ !compact && project.description && /* @__PURE__ */ jsx(
27343
+ "p",
27344
+ {
27345
+ style: {
27346
+ margin: 0,
27347
+ fontSize: fontSizeSmall,
27348
+ color: theme2.colors.textSecondary,
27349
+ overflow: "hidden",
27350
+ textOverflow: "ellipsis",
27351
+ whiteSpace: "nowrap"
27352
+ },
27353
+ title: project.description,
27354
+ children: project.description
27355
+ }
27356
+ ),
27357
+ /* @__PURE__ */ jsxs(
27358
+ "div",
27359
+ {
27360
+ style: {
27361
+ display: "flex",
27362
+ alignItems: "center",
27363
+ gap: compact ? 12 : 16,
27364
+ flexWrap: "wrap"
27365
+ },
27366
+ children: [
27367
+ project.license && /* @__PURE__ */ jsxs(
27368
+ "div",
27369
+ {
27370
+ style: {
27371
+ display: "flex",
27372
+ alignItems: "center",
27373
+ gap: 4,
27374
+ fontSize: fontSizeSmall,
27375
+ color: theme2.colors.textSecondary
27376
+ },
27377
+ title: `License: ${project.license}`,
27378
+ children: [
27379
+ /* @__PURE__ */ jsx(Scale, { size: 12 }),
27380
+ /* @__PURE__ */ jsx("span", { children: project.license })
27381
+ ]
27382
+ }
27383
+ ),
27384
+ totalDeps > 0 && /* @__PURE__ */ jsxs(
27385
+ "div",
27386
+ {
27387
+ style: {
27388
+ display: "flex",
27389
+ alignItems: "center",
27390
+ gap: 4,
27391
+ fontSize: fontSizeSmall,
27392
+ color: theme2.colors.textSecondary
27393
+ },
27394
+ title: `${project.dependencyCount || 0} prod, ${project.devDependencyCount || 0} dev dependencies`,
27395
+ children: [
27396
+ /* @__PURE__ */ jsx(Box, { size: 12 }),
27397
+ /* @__PURE__ */ jsxs("span", { children: [
27398
+ project.dependencyCount || 0,
27399
+ " deps",
27400
+ project.devDependencyCount ? ` + ${project.devDependencyCount} dev` : ""
27401
+ ] })
27402
+ ]
27403
+ }
27404
+ ),
27405
+ project.author && /* @__PURE__ */ jsxs(
27406
+ "div",
27407
+ {
27408
+ style: {
27409
+ display: "flex",
27410
+ alignItems: "center",
27411
+ gap: 4,
27412
+ fontSize: fontSizeSmall,
27413
+ color: theme2.colors.textSecondary
27414
+ },
27415
+ title: `Author: ${project.author}`,
27416
+ children: [
27417
+ /* @__PURE__ */ jsx(FileText, { size: 12 }),
27418
+ /* @__PURE__ */ jsx("span", { children: project.author })
27419
+ ]
27420
+ }
27421
+ )
27422
+ ]
27423
+ }
27424
+ )
27425
+ ]
27426
+ }
27427
+ );
27428
+ };
27429
+ const panels = [
27430
+ {
27431
+ metadata: {
27432
+ id: "principal-ade.file-city-panel",
27433
+ name: "File City Map",
27434
+ icon: "🏙️",
27435
+ version: "0.2.0",
27436
+ author: "Principal AI",
27437
+ description: "3D visualization of repository structure using the File City metaphor",
27438
+ // Data slices this panel depends on
27439
+ // - fileTree: Required - repository file structure
27440
+ // - fileCityColorModes: Optional - controls which color modes are available
27441
+ // (if not provided, only fileTypes and git modes are shown)
27442
+ slices: ["fileTree", "fileCityColorModes"],
27443
+ // UTCP-compatible tools this panel exposes
27444
+ tools: codeCityPanelTools
27445
+ },
27446
+ component: CodeCityPanel,
27447
+ // Optional: Called when this specific panel is mounted
27448
+ onMount: async (context) => {
27449
+ var _a;
27450
+ console.log(
27451
+ "File City Panel mounted",
27452
+ (_a = context.currentScope.repository) == null ? void 0 : _a.path
27453
+ );
27454
+ if (context.hasSlice("fileTree") && !context.isSliceLoading("fileTree")) {
27455
+ await context.refresh("repository", "fileTree");
27456
+ }
27457
+ },
27458
+ // Optional: Called when this specific panel is unmounted
27459
+ onUnmount: async (_context) => {
27460
+ console.log("File City Panel unmounting");
27461
+ }
27462
+ },
27463
+ {
27464
+ metadata: {
27465
+ id: "principal-ade.feed-file-city-panel",
27466
+ name: "Feed Project View",
27467
+ icon: "📦",
27468
+ version: "0.1.0",
27469
+ author: "Principal AI",
27470
+ description: "File City visualization with project header for feed view context",
27471
+ // Data slices this panel depends on
27472
+ // - fileTree: Required - repository file structure
27473
+ // - feedProject: Required - GitHub repo info and package details
27474
+ slices: ["fileTree", "feedProject"]
27475
+ },
27476
+ component: FeedCodeCityPanel,
27477
+ onMount: async (context) => {
27478
+ var _a;
27479
+ console.log(
27480
+ "Feed File City Panel mounted",
27481
+ (_a = context.currentScope.repository) == null ? void 0 : _a.path
27482
+ );
27483
+ if (context.hasSlice("fileTree") && !context.isSliceLoading("fileTree")) {
27484
+ await context.refresh("repository", "fileTree");
27485
+ }
27486
+ },
27487
+ onUnmount: async (_context) => {
27488
+ console.log("Feed File City Panel unmounting");
26313
27489
  }
26314
27490
  }
26315
27491
  ];
@@ -26322,6 +27498,10 @@ const onPackageUnload = async () => {
26322
27498
  export {
26323
27499
  COLOR_MODES,
26324
27500
  DEFAULT_COLOR_MODES,
27501
+ FeedCodeCityPanel,
27502
+ FeedProjectHeader,
27503
+ FeedProjectHeaderSkeleton,
27504
+ ProjectInfoHeader,
26325
27505
  QUALITY_COLOR_MODES,
26326
27506
  codeCityPanelTools,
26327
27507
  codeCityPanelToolsMetadata,