@principal-ade/code-quality-panels 0.1.12 → 0.1.13

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.
@@ -1 +1 @@
1
- {"version":3,"file":"QualityHexagonPanel.d.ts","sourceRoot":"","sources":["../../src/panels/QualityHexagonPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAuQpD;;GAEG;AACH,eAAO,MAAM,mBAAmB,+BAA6B,CAAC"}
1
+ {"version":3,"file":"QualityHexagonPanel.d.ts","sourceRoot":"","sources":["../../src/panels/QualityHexagonPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AA0UpD;;GAEG;AACH,eAAO,MAAM,mBAAmB,+BAA6B,CAAC"}
@@ -1306,6 +1306,14 @@ const mockPackages = [
1306
1306
  }
1307
1307
  }
1308
1308
  ];
1309
+ const METRIC_OPTIONS$1 = [
1310
+ { key: "types", label: "Types", colorMode: "typescript" },
1311
+ { key: "documentation", label: "Docs", colorMode: "alexandria" },
1312
+ { key: "tests", label: "Tests", colorMode: "coverage" },
1313
+ { key: "deadCode", label: "Dead Code", colorMode: "knip" },
1314
+ { key: "formatting", label: "Format", colorMode: "prettier" },
1315
+ { key: "linting", label: "Linting", colorMode: "eslint" }
1316
+ ];
1309
1317
  const QualityHexagonPanelContent = ({
1310
1318
  context,
1311
1319
  events
@@ -1313,6 +1321,7 @@ const QualityHexagonPanelContent = ({
1313
1321
  var _a;
1314
1322
  const { theme } = useTheme();
1315
1323
  const [refreshingPackages, setRefreshingPackages] = React2__default.useState(/* @__PURE__ */ new Set());
1324
+ const [selectedMetric, setSelectedMetric] = React2__default.useState(null);
1316
1325
  const qualitySlice = context.getSlice("quality");
1317
1326
  const hasQualitySlice = context.hasSlice("quality");
1318
1327
  const isLoading = (qualitySlice == null ? void 0 : qualitySlice.loading) ?? false;
@@ -1341,6 +1350,31 @@ const QualityHexagonPanelContent = ({
1341
1350
  setRefreshingPackages(/* @__PURE__ */ new Set());
1342
1351
  }
1343
1352
  };
1353
+ const handleMetricChange = (metric) => {
1354
+ setSelectedMetric(metric);
1355
+ if (metric) {
1356
+ const option = METRIC_OPTIONS$1.find((o) => o.key === metric);
1357
+ if (option) {
1358
+ events.emit({
1359
+ type: "quality:colorMode:select",
1360
+ source: "principal-ade.quality-hexagon-panel",
1361
+ timestamp: Date.now(),
1362
+ payload: {
1363
+ colorMode: option.colorMode
1364
+ }
1365
+ });
1366
+ }
1367
+ } else {
1368
+ events.emit({
1369
+ type: "quality:colorMode:select",
1370
+ source: "principal-ade.quality-hexagon-panel",
1371
+ timestamp: Date.now(),
1372
+ payload: {
1373
+ colorMode: "fileTypes"
1374
+ }
1375
+ });
1376
+ }
1377
+ };
1344
1378
  React2__default.useEffect(() => {
1345
1379
  const unsubscribers = [
1346
1380
  events.on("principal-ade.quality-panel:refresh", async () => {
@@ -1388,46 +1422,69 @@ const QualityHexagonPanelContent = ({
1388
1422
  gap: 16
1389
1423
  },
1390
1424
  children: [
1391
- /* @__PURE__ */ jsxs("div", { style: { display: "flex", alignItems: "center", gap: 12 }, children: [
1392
- /* @__PURE__ */ jsx(Hexagon, { size: 24, color: tierColors[overallTier] }),
1393
- /* @__PURE__ */ jsx(
1394
- "h2",
1395
- {
1396
- style: {
1397
- margin: 0,
1398
- fontSize: 20,
1399
- fontWeight: 600,
1400
- color: theme.colors.text
1401
- },
1402
- children: "Code Quality"
1403
- }
1404
- ),
1405
- /* @__PURE__ */ jsx(
1406
- "span",
1425
+ /* @__PURE__ */ jsxs("div", { style: { display: "flex", alignItems: "center", justifyContent: "space-between", flexWrap: "wrap", gap: 12 }, children: [
1426
+ /* @__PURE__ */ jsxs("div", { style: { display: "flex", alignItems: "center", gap: 12 }, children: [
1427
+ /* @__PURE__ */ jsx(Hexagon, { size: 24, color: tierColors[overallTier] }),
1428
+ /* @__PURE__ */ jsx(
1429
+ "h2",
1430
+ {
1431
+ style: {
1432
+ margin: 0,
1433
+ fontSize: 20,
1434
+ fontWeight: 600,
1435
+ color: theme.colors.text
1436
+ },
1437
+ children: "Code Quality"
1438
+ }
1439
+ ),
1440
+ /* @__PURE__ */ jsx(
1441
+ "span",
1442
+ {
1443
+ title: "Platinum: 90%+ avg | Gold: 75%+ | Silver: 60%+ | Bronze: 40%+",
1444
+ style: {
1445
+ display: "inline-flex",
1446
+ alignItems: "center",
1447
+ justifyContent: "center",
1448
+ width: 18,
1449
+ height: 18,
1450
+ borderRadius: "50%",
1451
+ border: `1px solid ${theme.colors.border}`,
1452
+ fontSize: 12,
1453
+ color: theme.colors.textMuted,
1454
+ cursor: "help"
1455
+ },
1456
+ children: "?"
1457
+ }
1458
+ ),
1459
+ packages.length > 1 && /* @__PURE__ */ jsxs("span", { style: {
1460
+ fontSize: 14,
1461
+ color: theme.colors.textMuted
1462
+ }, children: [
1463
+ packages.length,
1464
+ " packages"
1465
+ ] })
1466
+ ] }),
1467
+ /* @__PURE__ */ jsxs(
1468
+ "select",
1407
1469
  {
1408
- title: "Platinum: 90%+ avg | Gold: 75%+ | Silver: 60%+ | Bronze: 40%+",
1470
+ value: selectedMetric ?? "",
1471
+ onChange: (e) => handleMetricChange(e.target.value ? e.target.value : null),
1409
1472
  style: {
1410
- display: "inline-flex",
1411
- alignItems: "center",
1412
- justifyContent: "center",
1413
- width: 18,
1414
- height: 18,
1415
- borderRadius: "50%",
1473
+ padding: "6px 12px",
1474
+ fontSize: 13,
1475
+ backgroundColor: theme.colors.background,
1476
+ color: theme.colors.text,
1416
1477
  border: `1px solid ${theme.colors.border}`,
1417
- fontSize: 12,
1418
- color: theme.colors.textMuted,
1419
- cursor: "help"
1478
+ borderRadius: 4,
1479
+ cursor: "pointer",
1480
+ outline: "none"
1420
1481
  },
1421
- children: "?"
1482
+ children: [
1483
+ /* @__PURE__ */ jsx("option", { value: "", children: "Show in File City..." }),
1484
+ METRIC_OPTIONS$1.map((option) => /* @__PURE__ */ jsx("option", { value: option.key, children: option.label }, option.key))
1485
+ ]
1422
1486
  }
1423
- ),
1424
- packages.length > 1 && /* @__PURE__ */ jsxs("span", { style: {
1425
- fontSize: 14,
1426
- color: theme.colors.textMuted
1427
- }, children: [
1428
- packages.length,
1429
- " packages"
1430
- ] })
1487
+ )
1431
1488
  ] }),
1432
1489
  /* @__PURE__ */ jsx("div", { style: { display: "flex", flexWrap: "wrap", gap: 16, minHeight: 0 }, children: isLoading ? /* @__PURE__ */ jsx("div", { style: {
1433
1490
  padding: 40,
@@ -1 +1 @@
1
- {"version":3,"file":"panels.bundle.js","sources":["../node_modules/lucide-react/dist/esm/shared/src/utils.js","../node_modules/lucide-react/dist/esm/defaultAttributes.js","../node_modules/lucide-react/dist/esm/Icon.js","../node_modules/lucide-react/dist/esm/createLucideIcon.js","../node_modules/lucide-react/dist/esm/icons/check.js","../node_modules/lucide-react/dist/esm/icons/chevron-right.js","../node_modules/lucide-react/dist/esm/icons/copy.js","../node_modules/lucide-react/dist/esm/icons/git-branch.js","../node_modules/lucide-react/dist/esm/icons/hexagon.js","../node_modules/lucide-react/dist/esm/icons/info.js","../node_modules/lucide-react/dist/esm/icons/terminal.js","../node_modules/lucide-react/dist/esm/icons/zap.js","../node_modules/@principal-ade/industry-theme/dist/esm/index.js","../node_modules/clsx/dist/clsx.mjs","../src/lib/utils.ts","../src/components/QualityHexagon.tsx","../src/components/QualityEmptyState.tsx","../src/panels/QualityHexagonPanel.tsx","../src/components/RepositoryQualityGrid.tsx","../src/panels/RepositoryQualityGridPanel.tsx","../src/index.tsx"],"sourcesContent":["/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nconst toKebabCase = (string) => string.replace(/([a-z0-9])([A-Z])/g, \"$1-$2\").toLowerCase();\nconst toCamelCase = (string) => string.replace(\n /^([A-Z])|[\\s-_]+(\\w)/g,\n (match, p1, p2) => p2 ? p2.toUpperCase() : p1.toLowerCase()\n);\nconst toPascalCase = (string) => {\n const camelCase = toCamelCase(string);\n return camelCase.charAt(0).toUpperCase() + camelCase.slice(1);\n};\nconst mergeClasses = (...classes) => classes.filter((className, index, array) => {\n return Boolean(className) && className.trim() !== \"\" && array.indexOf(className) === index;\n}).join(\" \").trim();\nconst hasA11yProp = (props) => {\n for (const prop in props) {\n if (prop.startsWith(\"aria-\") || prop === \"role\" || prop === \"title\") {\n return true;\n }\n }\n};\n\nexport { hasA11yProp, mergeClasses, toCamelCase, toKebabCase, toPascalCase };\n//# sourceMappingURL=utils.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nvar defaultAttributes = {\n xmlns: \"http://www.w3.org/2000/svg\",\n width: 24,\n height: 24,\n viewBox: \"0 0 24 24\",\n fill: \"none\",\n stroke: \"currentColor\",\n strokeWidth: 2,\n strokeLinecap: \"round\",\n strokeLinejoin: \"round\"\n};\n\nexport { defaultAttributes as default };\n//# sourceMappingURL=defaultAttributes.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport { forwardRef, createElement } from 'react';\nimport defaultAttributes from './defaultAttributes.js';\nimport { mergeClasses, hasA11yProp } from './shared/src/utils.js';\n\nconst Icon = forwardRef(\n ({\n color = \"currentColor\",\n size = 24,\n strokeWidth = 2,\n absoluteStrokeWidth,\n className = \"\",\n children,\n iconNode,\n ...rest\n }, ref) => createElement(\n \"svg\",\n {\n ref,\n ...defaultAttributes,\n width: size,\n height: size,\n stroke: color,\n strokeWidth: absoluteStrokeWidth ? Number(strokeWidth) * 24 / Number(size) : strokeWidth,\n className: mergeClasses(\"lucide\", className),\n ...!children && !hasA11yProp(rest) && { \"aria-hidden\": \"true\" },\n ...rest\n },\n [\n ...iconNode.map(([tag, attrs]) => createElement(tag, attrs)),\n ...Array.isArray(children) ? children : [children]\n ]\n )\n);\n\nexport { Icon as default };\n//# sourceMappingURL=Icon.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport { forwardRef, createElement } from 'react';\nimport { mergeClasses, toKebabCase, toPascalCase } from './shared/src/utils.js';\nimport Icon from './Icon.js';\n\nconst createLucideIcon = (iconName, iconNode) => {\n const Component = forwardRef(\n ({ className, ...props }, ref) => createElement(Icon, {\n ref,\n iconNode,\n className: mergeClasses(\n `lucide-${toKebabCase(toPascalCase(iconName))}`,\n `lucide-${iconName}`,\n className\n ),\n ...props\n })\n );\n Component.displayName = toPascalCase(iconName);\n return Component;\n};\n\nexport { createLucideIcon as default };\n//# sourceMappingURL=createLucideIcon.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [[\"path\", { d: \"M20 6 9 17l-5-5\", key: \"1gmf2c\" }]];\nconst Check = createLucideIcon(\"check\", __iconNode);\n\nexport { __iconNode, Check as default };\n//# sourceMappingURL=check.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [[\"path\", { d: \"m9 18 6-6-6-6\", key: \"mthhwq\" }]];\nconst ChevronRight = createLucideIcon(\"chevron-right\", __iconNode);\n\nexport { __iconNode, ChevronRight as default };\n//# sourceMappingURL=chevron-right.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\"rect\", { width: \"14\", height: \"14\", x: \"8\", y: \"8\", rx: \"2\", ry: \"2\", key: \"17jyea\" }],\n [\"path\", { d: \"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2\", key: \"zix9uf\" }]\n];\nconst Copy = createLucideIcon(\"copy\", __iconNode);\n\nexport { __iconNode, Copy as default };\n//# sourceMappingURL=copy.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\"line\", { x1: \"6\", x2: \"6\", y1: \"3\", y2: \"15\", key: \"17qcm7\" }],\n [\"circle\", { cx: \"18\", cy: \"6\", r: \"3\", key: \"1h7g24\" }],\n [\"circle\", { cx: \"6\", cy: \"18\", r: \"3\", key: \"fqmcym\" }],\n [\"path\", { d: \"M18 9a9 9 0 0 1-9 9\", key: \"n2h4wq\" }]\n];\nconst GitBranch = createLucideIcon(\"git-branch\", __iconNode);\n\nexport { __iconNode, GitBranch as default };\n//# sourceMappingURL=git-branch.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\n \"path\",\n {\n d: \"M21 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.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16z\",\n key: \"yt0hxn\"\n }\n ]\n];\nconst Hexagon = createLucideIcon(\"hexagon\", __iconNode);\n\nexport { __iconNode, Hexagon as default };\n//# sourceMappingURL=hexagon.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\"circle\", { cx: \"12\", cy: \"12\", r: \"10\", key: \"1mglay\" }],\n [\"path\", { d: \"M12 16v-4\", key: \"1dtifu\" }],\n [\"path\", { d: \"M12 8h.01\", key: \"e9boi3\" }]\n];\nconst Info = createLucideIcon(\"info\", __iconNode);\n\nexport { __iconNode, Info as default };\n//# sourceMappingURL=info.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\"path\", { d: \"M12 19h8\", key: \"baeox8\" }],\n [\"path\", { d: \"m4 17 6-6-6-6\", key: \"1yngyt\" }]\n];\nconst Terminal = createLucideIcon(\"terminal\", __iconNode);\n\nexport { __iconNode, Terminal as default };\n//# sourceMappingURL=terminal.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\n \"path\",\n {\n d: \"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z\",\n key: \"1xq2db\"\n }\n ]\n];\nconst Zap = createLucideIcon(\"zap\", __iconNode);\n\nexport { __iconNode, Zap as default };\n//# sourceMappingURL=zap.js.map\n","// src/glassmorphismTheme.ts\nvar glassmorphismTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n heading: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n monospace: '\"Fira Code\", \"SF Mono\", Monaco, Inconsolata, monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 600,\n bold: 700,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.6,\n heading: 1.3,\n tight: 1.4,\n relaxed: 1.8\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 8, 12, 16, 20, 24, 32, 40],\n shadows: [\n \"none\",\n \"0 8px 32px 0 rgba(31, 38, 135, 0.15)\",\n \"0 12px 40px 0 rgba(31, 38, 135, 0.2)\",\n \"0 16px 48px 0 rgba(31, 38, 135, 0.25)\",\n \"0 20px 56px 0 rgba(31, 38, 135, 0.3)\",\n \"0 24px 64px 0 rgba(31, 38, 135, 0.35)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"rgba(255, 255, 255, 0.95)\",\n background: \"rgba(255, 255, 255, 0.1)\",\n primary: \"rgba(99, 102, 241, 0.9)\",\n secondary: \"rgba(139, 92, 246, 0.9)\",\n accent: \"rgba(236, 72, 153, 0.9)\",\n highlight: \"rgba(99, 102, 241, 0.2)\",\n muted: \"rgba(255, 255, 255, 0.05)\",\n success: \"rgba(34, 197, 94, 0.9)\",\n warning: \"rgba(251, 146, 60, 0.9)\",\n error: \"rgba(239, 68, 68, 0.9)\",\n info: \"rgba(59, 130, 246, 0.9)\",\n border: \"rgba(255, 255, 255, 0.18)\",\n backgroundSecondary: \"rgba(255, 255, 255, 0.15)\",\n backgroundTertiary: \"rgba(255, 255, 255, 0.2)\",\n backgroundLight: \"rgba(255, 255, 255, 0.08)\",\n backgroundHover: \"rgba(255, 255, 255, 0.25)\",\n surface: \"rgba(255, 255, 255, 0.12)\",\n textSecondary: \"rgba(255, 255, 255, 0.8)\",\n textTertiary: \"rgba(255, 255, 255, 0.6)\",\n textMuted: \"rgba(255, 255, 255, 0.5)\",\n highlightBg: \"rgba(251, 191, 36, 0.3)\",\n highlightBorder: \"rgba(251, 191, 36, 0.5)\"\n },\n modes: {\n dark: {\n text: \"rgba(255, 255, 255, 0.95)\",\n background: \"rgba(0, 0, 0, 0.3)\",\n primary: \"rgba(129, 140, 248, 0.9)\",\n secondary: \"rgba(167, 139, 250, 0.9)\",\n accent: \"rgba(244, 114, 182, 0.9)\",\n highlight: \"rgba(129, 140, 248, 0.25)\",\n muted: \"rgba(0, 0, 0, 0.15)\",\n success: \"rgba(74, 222, 128, 0.9)\",\n warning: \"rgba(251, 191, 36, 0.9)\",\n error: \"rgba(248, 113, 113, 0.9)\",\n info: \"rgba(96, 165, 250, 0.9)\",\n border: \"rgba(255, 255, 255, 0.15)\",\n backgroundSecondary: \"rgba(0, 0, 0, 0.4)\",\n backgroundTertiary: \"rgba(0, 0, 0, 0.5)\",\n backgroundLight: \"rgba(0, 0, 0, 0.2)\",\n backgroundHover: \"rgba(255, 255, 255, 0.1)\",\n surface: \"rgba(0, 0, 0, 0.35)\",\n textSecondary: \"rgba(255, 255, 255, 0.8)\",\n textTertiary: \"rgba(255, 255, 255, 0.6)\",\n textMuted: \"rgba(255, 255, 255, 0.4)\",\n highlightBg: \"rgba(251, 191, 36, 0.35)\",\n highlightBorder: \"rgba(251, 191, 36, 0.6)\"\n },\n frosted: {\n text: \"rgba(31, 41, 55, 0.95)\",\n background: \"rgba(255, 255, 255, 0.3)\",\n primary: \"rgba(79, 70, 229, 0.95)\",\n secondary: \"rgba(124, 58, 237, 0.95)\",\n accent: \"rgba(219, 39, 119, 0.95)\",\n highlight: \"rgba(79, 70, 229, 0.15)\",\n muted: \"rgba(255, 255, 255, 0.4)\",\n success: \"rgba(16, 185, 129, 0.95)\",\n warning: \"rgba(245, 158, 11, 0.95)\",\n error: \"rgba(220, 38, 38, 0.95)\",\n info: \"rgba(37, 99, 235, 0.95)\",\n border: \"rgba(255, 255, 255, 0.5)\",\n backgroundSecondary: \"rgba(255, 255, 255, 0.4)\",\n backgroundTertiary: \"rgba(255, 255, 255, 0.5)\",\n backgroundLight: \"rgba(255, 255, 255, 0.25)\",\n backgroundHover: \"rgba(255, 255, 255, 0.6)\",\n surface: \"rgba(255, 255, 255, 0.35)\",\n textSecondary: \"rgba(31, 41, 55, 0.8)\",\n textTertiary: \"rgba(31, 41, 55, 0.6)\",\n textMuted: \"rgba(31, 41, 55, 0.5)\",\n highlightBg: \"rgba(251, 191, 36, 0.4)\",\n highlightBorder: \"rgba(251, 191, 36, 0.7)\"\n }\n },\n buttons: {\n primary: {\n color: \"white\",\n bg: \"primary\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"rgba(255, 255, 255, 0.2)\",\n \"&:hover\": {\n bg: \"secondary\"\n }\n },\n secondary: {\n color: \"text\",\n bg: \"rgba(255, 255, 255, 0.1)\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"rgba(255, 255, 255, 0.2)\",\n \"&:hover\": {\n bg: \"rgba(255, 255, 255, 0.2)\"\n }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"transparent\",\n \"&:hover\": {\n borderColor: \"rgba(255, 255, 255, 0.2)\",\n bg: \"rgba(255, 255, 255, 0.05)\"\n }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 3\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 3\n }\n }\n};\n// src/defaultThemes.ts\nvar defaultMarkdownTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n heading: '\"Crimson Text\", \"Georgia\", \"Times New Roman\", serif',\n monospace: '\"Fira Code\", \"SF Mono\", Monaco, Inconsolata, monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 600,\n bold: 700,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.6,\n heading: 1.3,\n tight: 1.25,\n relaxed: 1.75\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06)\",\n \"0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06)\",\n \"0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05)\",\n \"0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04)\",\n \"0 25px 50px -12px rgba(0, 0, 0, 0.25)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#1a1a1a\",\n background: \"#ffffff\",\n primary: \"#007acc\",\n secondary: \"#005a9e\",\n accent: \"#1a1a1a\",\n highlight: \"rgba(0, 122, 204, 0.1)\",\n muted: \"#f0f0f0\",\n success: \"#28a745\",\n warning: \"#ffc107\",\n error: \"#dc3545\",\n info: \"#17a2b8\",\n border: \"rgba(0, 0, 0, 0.1)\",\n backgroundSecondary: \"#f8f9fa\",\n backgroundTertiary: \"#e9ecef\",\n backgroundLight: \"rgba(0, 0, 0, 0.03)\",\n backgroundHover: \"rgba(0, 0, 0, 0.05)\",\n surface: \"#ffffff\",\n textSecondary: \"#555555\",\n textTertiary: \"#888888\",\n textMuted: \"#aaaaaa\",\n highlightBg: \"rgba(255, 235, 59, 0.3)\",\n highlightBorder: \"rgba(255, 235, 59, 0.6)\"\n },\n buttons: {\n primary: {\n color: \"white\",\n bg: \"primary\",\n \"&:hover\": { bg: \"secondary\" }\n },\n secondary: {\n color: \"primary\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"primary\",\n \"&:hover\": { bg: \"highlight\" }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n \"&:hover\": { bg: \"backgroundHover\" }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 2\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 2\n }\n }\n};\nvar defaultTerminalTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Courier New\", Courier, monospace',\n heading: '\"Courier New\", Courier, monospace',\n monospace: '\"Courier New\", Courier, monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 500,\n bold: 600,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.4,\n heading: 1.2,\n tight: 1.3,\n relaxed: 1.6\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 0 5px rgba(255, 193, 7, 0.1)\",\n \"0 0 10px rgba(255, 193, 7, 0.15)\",\n \"0 0 15px rgba(255, 193, 7, 0.2)\",\n \"0 0 20px rgba(255, 193, 7, 0.25)\",\n \"0 0 30px rgba(255, 193, 7, 0.3)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#ffc107\",\n background: \"#000000\",\n primary: \"#ffc107\",\n secondary: \"#ffb300\",\n accent: \"#ffffff\",\n highlight: \"rgba(255, 193, 7, 0.1)\",\n muted: \"#1a1a1a\",\n success: \"#4caf50\",\n warning: \"#ff9800\",\n error: \"#f44336\",\n info: \"#2196f3\",\n border: \"rgba(255, 193, 7, 0.2)\",\n backgroundSecondary: \"#0a0a0a\",\n backgroundTertiary: \"#111111\",\n backgroundLight: \"rgba(255, 193, 7, 0.03)\",\n backgroundHover: \"rgba(255, 193, 7, 0.05)\",\n surface: \"#050505\",\n textSecondary: \"#e0e0e0\",\n textTertiary: \"#b0b0b0\",\n textMuted: \"#808080\",\n highlightBg: \"rgba(255, 193, 7, 0.2)\",\n highlightBorder: \"rgba(255, 193, 7, 0.4)\"\n },\n buttons: {\n primary: {\n color: \"black\",\n bg: \"primary\",\n borderWidth: 0,\n \"&:hover\": { bg: \"secondary\" }\n },\n secondary: {\n color: \"primary\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"primary\",\n \"&:hover\": { bg: \"highlight\" }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n \"&:hover\": { bg: \"backgroundHover\" }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 0\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 0\n }\n }\n};\nvar defaultEditorTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Fira Code\", \"SF Mono\", Monaco, Inconsolata, monospace',\n heading: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n monospace: '\"Fira Code\", \"SF Mono\", Monaco, Inconsolata, monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 600,\n bold: 700,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.5,\n heading: 1.2,\n tight: 1.3,\n relaxed: 1.7\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 1px 2px rgba(0, 0, 0, 0.05)\",\n \"0 2px 4px rgba(0, 0, 0, 0.1)\",\n \"0 4px 8px rgba(0, 0, 0, 0.15)\",\n \"0 8px 16px rgba(0, 0, 0, 0.2)\",\n \"0 12px 24px rgba(0, 0, 0, 0.25)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#d4d4d4\",\n background: \"#1e1e1e\",\n primary: \"#569cd6\",\n secondary: \"#408ac9\",\n accent: \"#c586c0\",\n highlight: \"rgba(86, 156, 214, 0.1)\",\n muted: \"#2a2a2a\",\n success: \"#6a9955\",\n warning: \"#d18616\",\n error: \"#f44747\",\n info: \"#569cd6\",\n border: \"rgba(255, 255, 255, 0.1)\",\n backgroundSecondary: \"#252526\",\n backgroundTertiary: \"#333333\",\n backgroundLight: \"rgba(255, 255, 255, 0.03)\",\n backgroundHover: \"rgba(255, 255, 255, 0.05)\",\n surface: \"#252526\",\n textSecondary: \"#cccccc\",\n textTertiary: \"#999999\",\n textMuted: \"#666666\",\n highlightBg: \"rgba(255, 235, 59, 0.2)\",\n highlightBorder: \"rgba(255, 235, 59, 0.4)\"\n },\n buttons: {\n primary: {\n color: \"white\",\n bg: \"primary\",\n \"&:hover\": { bg: \"secondary\" }\n },\n secondary: {\n color: \"primary\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"primary\",\n \"&:hover\": { bg: \"highlight\" }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n \"&:hover\": { bg: \"backgroundHover\" }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 1\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 1\n }\n }\n};\n\n// src/themes.ts\nvar regalTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n heading: '\"Crimson Text\", \"Georgia\", \"Times New Roman\", serif',\n monospace: '\"Fira Code\", \"SF Mono\", Monaco, Inconsolata, monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 600,\n bold: 700,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.5,\n heading: 1.2,\n tight: 1.25,\n relaxed: 1.75\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06)\",\n \"0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06)\",\n \"0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05)\",\n \"0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04)\",\n \"0 25px 50px -12px rgba(0, 0, 0, 0.25)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#f1e8dc\",\n background: \"#1a1f2e\",\n primary: \"#d4a574\",\n secondary: \"#e0b584\",\n accent: \"#c9b8a3\",\n highlight: \"rgba(212, 165, 116, 0.15)\",\n muted: \"#8b7968\",\n success: \"#5c8a72\",\n warning: \"#d4a574\",\n error: \"#a85751\",\n info: \"#d4a574\",\n border: \"rgba(212, 165, 116, 0.2)\",\n backgroundSecondary: \"#212738\",\n backgroundTertiary: \"#2d3446\",\n backgroundLight: \"rgba(212, 165, 116, 0.08)\",\n backgroundHover: \"rgba(212, 165, 116, 0.15)\",\n surface: \"#212738\",\n textSecondary: \"#c9b8a3\",\n textTertiary: \"#8b7968\",\n textMuted: \"#8b7968\",\n highlightBg: \"rgba(255, 193, 7, 0.25)\",\n highlightBorder: \"rgba(255, 193, 7, 0.5)\"\n },\n buttons: {\n primary: {\n color: \"background\",\n bg: \"primary\",\n \"&:hover\": {\n bg: \"secondary\"\n }\n },\n secondary: {\n color: \"text\",\n bg: \"muted\",\n \"&:hover\": {\n bg: \"backgroundSecondary\"\n }\n },\n ghost: {\n color: \"primary\",\n bg: \"transparent\",\n \"&:hover\": {\n bg: \"muted\"\n }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"background\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 2\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 2\n }\n }\n};\nvar terminalTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"SF Mono\", \"Monaco\", \"Inconsolata\", \"Fira Code\", monospace',\n heading: '\"SF Mono\", \"Monaco\", \"Inconsolata\", \"Fira Code\", monospace',\n monospace: '\"SF Mono\", \"Monaco\", \"Inconsolata\", \"Fira Code\", monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 500,\n bold: 600,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.6,\n heading: 1.3,\n tight: 1.4,\n relaxed: 1.8\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 1px 2px 0 rgba(0, 0, 0, 0.05)\",\n \"0 2px 4px 0 rgba(0, 0, 0, 0.06)\",\n \"0 4px 6px 0 rgba(0, 0, 0, 0.07)\",\n \"0 8px 12px 0 rgba(0, 0, 0, 0.08)\",\n \"0 16px 24px 0 rgba(0, 0, 0, 0.10)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#e4e4e4\",\n background: \"rgba(10, 10, 10, 0.85)\",\n primary: \"#66b3ff\",\n secondary: \"#80c4ff\",\n accent: \"#66ff99\",\n highlight: \"rgba(102, 179, 255, 0.15)\",\n muted: \"rgba(26, 26, 26, 0.8)\",\n success: \"#66ff99\",\n warning: \"#ffcc66\",\n error: \"#ff6666\",\n info: \"#66b3ff\",\n border: \"rgba(255, 255, 255, 0.1)\",\n backgroundSecondary: \"rgba(15, 15, 15, 0.9)\",\n backgroundTertiary: \"rgba(20, 20, 20, 0.9)\",\n backgroundLight: \"rgba(255, 255, 255, 0.05)\",\n backgroundHover: \"rgba(102, 179, 255, 0.08)\",\n surface: \"rgba(15, 15, 15, 0.95)\",\n textSecondary: \"rgba(255, 255, 255, 0.7)\",\n textTertiary: \"rgba(255, 255, 255, 0.5)\",\n textMuted: \"rgba(255, 255, 255, 0.4)\",\n highlightBg: \"rgba(255, 235, 59, 0.25)\",\n highlightBorder: \"rgba(255, 235, 59, 0.5)\"\n },\n modes: {\n light: {\n text: \"#1a1a1a\",\n background: \"rgba(255, 255, 255, 0.9)\",\n primary: \"#0066cc\",\n secondary: \"#0052a3\",\n accent: \"#00cc88\",\n highlight: \"rgba(0, 102, 204, 0.08)\",\n muted: \"rgba(245, 245, 245, 0.8)\",\n success: \"#00cc88\",\n warning: \"#ffaa00\",\n error: \"#ff3333\",\n info: \"#0066cc\",\n border: \"rgba(0, 0, 0, 0.1)\",\n backgroundSecondary: \"rgba(250, 250, 250, 0.9)\",\n backgroundTertiary: \"rgba(245, 245, 245, 0.9)\",\n backgroundLight: \"rgba(0, 0, 0, 0.02)\",\n backgroundHover: \"rgba(0, 102, 204, 0.04)\",\n surface: \"rgba(255, 255, 255, 0.95)\",\n textSecondary: \"rgba(0, 0, 0, 0.6)\",\n textTertiary: \"rgba(0, 0, 0, 0.4)\",\n textMuted: \"rgba(0, 0, 0, 0.3)\",\n highlightBg: \"rgba(255, 235, 59, 0.3)\",\n highlightBorder: \"rgba(255, 235, 59, 0.6)\"\n }\n },\n buttons: {\n primary: {\n color: \"white\",\n bg: \"primary\",\n borderWidth: 0,\n \"&:hover\": {\n bg: \"secondary\"\n }\n },\n secondary: {\n color: \"primary\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"primary\",\n \"&:hover\": {\n bg: \"highlight\"\n }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n \"&:hover\": {\n bg: \"backgroundHover\"\n }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 1\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 1\n }\n }\n};\nvar matrixTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Courier New\", \"Courier\", \"Lucida Console\", \"Monaco\", monospace',\n heading: '\"Courier New\", \"Courier\", \"Lucida Console\", \"Monaco\", monospace',\n monospace: '\"Courier New\", \"Courier\", \"Lucida Console\", \"Monaco\", monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 500,\n bold: 600,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.5,\n heading: 1.2,\n tight: 1.3,\n relaxed: 1.7\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 0 5px rgba(0, 216, 53, 0.15)\",\n \"0 0 10px rgba(0, 216, 53, 0.2)\",\n \"0 0 15px rgba(0, 216, 53, 0.25)\",\n \"0 0 20px rgba(0, 216, 53, 0.3)\",\n \"0 0 30px rgba(0, 216, 53, 0.4)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#a8a8a8\",\n background: \"#000000\",\n primary: \"#00d835\",\n secondary: \"#00a828\",\n accent: \"#00d835\",\n highlight: \"rgba(0, 216, 53, 0.15)\",\n muted: \"#0a0a0a\",\n success: \"#00d835\",\n warning: \"#d4a000\",\n error: \"#d63333\",\n info: \"#00a8d6\",\n border: \"rgba(0, 216, 53, 0.2)\",\n backgroundSecondary: \"#0a0a0a\",\n backgroundTertiary: \"#111111\",\n backgroundLight: \"rgba(0, 216, 53, 0.03)\",\n backgroundHover: \"rgba(0, 216, 53, 0.08)\",\n surface: \"#050505\",\n textSecondary: \"#808080\",\n textTertiary: \"#606060\",\n textMuted: \"#484848\",\n highlightBg: \"rgba(0, 216, 53, 0.25)\",\n highlightBorder: \"rgba(0, 216, 53, 0.5)\"\n },\n buttons: {\n primary: {\n color: \"black\",\n bg: \"primary\",\n borderWidth: 0,\n \"&:hover\": {\n bg: \"secondary\"\n }\n },\n secondary: {\n color: \"primary\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"primary\",\n \"&:hover\": {\n bg: \"highlight\"\n }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n \"&:hover\": {\n bg: \"backgroundHover\"\n }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 0\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 0\n }\n }\n};\nvar matrixMinimalTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Courier New\", \"Courier\", \"Lucida Console\", \"Monaco\", monospace',\n heading: '\"Courier New\", \"Courier\", \"Lucida Console\", \"Monaco\", monospace',\n monospace: '\"Courier New\", \"Courier\", \"Lucida Console\", \"Monaco\", monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 500,\n bold: 600,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.5,\n heading: 1.2,\n tight: 1.3,\n relaxed: 1.7\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 1px 2px rgba(0, 0, 0, 0.05)\",\n \"0 2px 4px rgba(0, 0, 0, 0.1)\",\n \"0 4px 8px rgba(0, 0, 0, 0.15)\",\n \"0 8px 16px rgba(0, 0, 0, 0.2)\",\n \"0 0 20px rgba(0, 216, 53, 0.1)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#a8a8a8\",\n background: \"#000000\",\n primary: \"#b8b8b8\",\n secondary: \"#909090\",\n accent: \"#00d835\",\n highlight: \"rgba(0, 216, 53, 0.1)\",\n muted: \"#0a0a0a\",\n success: \"#00d835\",\n warning: \"#d4a000\",\n error: \"#d63333\",\n info: \"#00a8d6\",\n border: \"rgba(184, 184, 184, 0.1)\",\n backgroundSecondary: \"#0a0a0a\",\n backgroundTertiary: \"#111111\",\n backgroundLight: \"rgba(184, 184, 184, 0.02)\",\n backgroundHover: \"rgba(0, 216, 53, 0.05)\",\n surface: \"#050505\",\n textSecondary: \"#808080\",\n textTertiary: \"#606060\",\n textMuted: \"#484848\",\n highlightBg: \"rgba(0, 216, 53, 0.2)\",\n highlightBorder: \"rgba(0, 216, 53, 0.4)\"\n },\n buttons: {\n primary: {\n color: \"black\",\n bg: \"primary\",\n borderWidth: 0,\n \"&:hover\": {\n bg: \"secondary\"\n }\n },\n secondary: {\n color: \"primary\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"primary\",\n \"&:hover\": {\n bg: \"backgroundHover\"\n }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n \"&:hover\": {\n bg: \"backgroundHover\"\n }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 0\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 0\n }\n }\n};\nvar slateTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n heading: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n monospace: '\"Fira Code\", \"SF Mono\", Monaco, Inconsolata, monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 600,\n bold: 700,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.6,\n heading: 1.3,\n tight: 1.25,\n relaxed: 1.75\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 1px 3px 0 rgba(0, 0, 0, 0.2)\",\n \"0 4px 6px -1px rgba(0, 0, 0, 0.2)\",\n \"0 10px 15px -3px rgba(0, 0, 0, 0.2)\",\n \"0 20px 25px -5px rgba(0, 0, 0, 0.25)\",\n \"0 25px 50px -12px rgba(0, 0, 0, 0.3)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#9ca3af\",\n background: \"#1a1c1e\",\n primary: \"#d1d5db\",\n secondary: \"#6b7280\",\n accent: \"#f59e0b\",\n highlight: \"rgba(209, 213, 219, 0.15)\",\n muted: \"#2d3134\",\n success: \"#10b981\",\n warning: \"#f59e0b\",\n error: \"#ef4444\",\n info: \"#3b82f6\",\n border: \"rgba(156, 163, 175, 0.15)\",\n backgroundSecondary: \"#22252a\",\n backgroundTertiary: \"#2d3134\",\n backgroundLight: \"rgba(156, 163, 175, 0.05)\",\n backgroundHover: \"rgba(156, 163, 175, 0.1)\",\n surface: \"#1f2124\",\n textSecondary: \"#e5e7eb\",\n textTertiary: \"#6b7280\",\n textMuted: \"#4b5563\",\n highlightBg: \"rgba(245, 158, 11, 0.25)\",\n highlightBorder: \"rgba(245, 158, 11, 0.5)\"\n },\n buttons: {\n primary: {\n color: \"#1a1c1e\",\n bg: \"primary\",\n borderWidth: 0,\n \"&:hover\": {\n bg: \"#9ca3af\"\n }\n },\n secondary: {\n color: \"#e5e7eb\",\n bg: \"secondary\",\n borderWidth: 0,\n \"&:hover\": {\n bg: \"#4b5563\"\n }\n },\n ghost: {\n color: \"textSecondary\",\n bg: \"transparent\",\n \"&:hover\": {\n bg: \"backgroundHover\"\n }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\",\n color: \"textSecondary\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textTertiary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 3\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 3\n }\n }\n};\n// src/ThemeProvider.tsx\nimport React, { createContext, useContext, useState, useEffect } from \"react\";\n\n// src/themeHelpers.ts\nfunction overrideColors(theme, colors) {\n return {\n ...theme,\n colors: {\n ...theme.colors,\n ...colors\n }\n };\n}\nfunction makeTheme(baseTheme, overrides) {\n return {\n ...baseTheme,\n ...overrides,\n colors: {\n ...baseTheme.colors,\n ...overrides.colors\n },\n fonts: {\n ...baseTheme.fonts,\n ...overrides.fonts\n }\n };\n}\nfunction addMode(theme, modeName, colors, baseMode) {\n let baseColors;\n if (baseMode && theme.modes && theme.modes[baseMode]) {\n baseColors = {\n ...theme.colors,\n ...theme.modes[baseMode]\n };\n } else {\n baseColors = theme.colors;\n }\n const newMode = {\n ...baseColors,\n ...colors\n };\n return {\n ...theme,\n modes: {\n ...theme.modes,\n [modeName]: newMode\n }\n };\n}\nfunction getMode(theme, mode) {\n if (!mode || !theme.modes || !theme.modes[mode]) {\n return theme.colors;\n }\n return {\n ...theme.colors,\n ...theme.modes[mode]\n };\n}\n\n// src/ThemeProvider.tsx\nvar ThemeContext;\nvar getThemeContext = () => {\n if (typeof window !== \"undefined\") {\n const globalWindow = window;\n if (!globalWindow.__principlemd_theme_context__) {\n globalWindow.__principlemd_theme_context__ = createContext(undefined);\n }\n return globalWindow.__principlemd_theme_context__;\n } else {\n if (!ThemeContext) {\n ThemeContext = createContext(undefined);\n }\n return ThemeContext;\n }\n};\nvar ThemeContextSingleton = getThemeContext();\nvar useTheme = () => {\n const context = useContext(ThemeContextSingleton);\n if (!context) {\n throw new Error(\"useTheme must be used within a ThemeProvider\");\n }\n return context;\n};\nvar ThemeProvider = ({\n children,\n theme: customTheme = theme,\n initialMode\n}) => {\n const [mode, setMode] = useState(initialMode);\n const activeTheme = React.useMemo(() => {\n if (!mode || !customTheme.modes || !customTheme.modes[mode]) {\n return customTheme;\n }\n return {\n ...customTheme,\n colors: getMode(customTheme, mode)\n };\n }, [customTheme, mode]);\n useEffect(() => {\n if (!initialMode) {\n const savedMode = localStorage.getItem(\"principlemd-theme-mode\");\n if (savedMode) {\n setMode(savedMode);\n }\n }\n }, [initialMode]);\n useEffect(() => {\n if (mode) {\n localStorage.setItem(\"principlemd-theme-mode\", mode);\n } else {\n localStorage.removeItem(\"principlemd-theme-mode\");\n }\n }, [mode]);\n const value = {\n theme: activeTheme,\n mode,\n setMode\n };\n return /* @__PURE__ */ React.createElement(ThemeContextSingleton.Provider, {\n value\n }, children);\n};\nvar withTheme = (Component) => {\n return (props) => {\n const { theme: theme2 } = useTheme();\n return /* @__PURE__ */ React.createElement(Component, {\n ...props,\n theme: theme2\n });\n };\n};\n// src/utils.ts\nvar getColor = (theme2, colorKey) => {\n const colors = theme2.colors;\n const value = colors[colorKey];\n return typeof value === \"string\" ? value : colorKey;\n};\nvar getSpace = (theme2, index) => {\n return theme2.space[index] || 0;\n};\nvar getFontSize = (theme2, index) => {\n return theme2.fontSizes[index] || theme2.fontSizes[2];\n};\nvar getRadius = (theme2, index) => {\n return theme2.radii[index] || 0;\n};\nvar getShadow = (theme2, index) => {\n return theme2.shadows[index] || \"none\";\n};\nvar getZIndex = (theme2, index) => {\n return theme2.zIndices[index] || 0;\n};\nvar responsive = (values) => {\n return values.reduce((acc, value, index) => {\n if (index === 0) {\n return value;\n }\n return {\n ...acc,\n [`@media screen and (min-width: ${values[index - 1]})`]: value\n };\n }, {});\n};\nvar sx = (styles) => styles;\nvar createStyle = (theme2, styleObj) => {\n const processValue = (value) => {\n if (typeof value === \"string\") {\n if (value in theme2.colors) {\n return getColor(theme2, value);\n }\n return value;\n }\n if (typeof value === \"number\") {\n return value;\n }\n if (Array.isArray(value)) {\n return value.map(processValue);\n }\n if (typeof value === \"object\" && value !== null) {\n const processed2 = {};\n for (const [key, val] of Object.entries(value)) {\n processed2[key] = processValue(val);\n }\n return processed2;\n }\n return value;\n };\n const processed = {};\n for (const [key, val] of Object.entries(styleObj)) {\n processed[key] = processValue(val);\n }\n return processed;\n};\nvar mergeThemes = (baseTheme, ...overrides) => {\n return overrides.reduce((theme2, override) => ({\n space: override.space || theme2.space,\n fonts: { ...theme2.fonts, ...override.fonts || {} },\n fontSizes: override.fontSizes || theme2.fontSizes,\n fontWeights: { ...theme2.fontWeights, ...override.fontWeights || {} },\n lineHeights: { ...theme2.lineHeights, ...override.lineHeights || {} },\n breakpoints: override.breakpoints || theme2.breakpoints,\n sizes: override.sizes || theme2.sizes,\n radii: override.radii || theme2.radii,\n shadows: override.shadows || theme2.shadows,\n zIndices: override.zIndices || theme2.zIndices,\n colors: {\n ...theme2.colors,\n ...override.colors || {}\n },\n buttons: { ...theme2.buttons, ...override.buttons || {} },\n text: { ...theme2.text, ...override.text || {} },\n cards: { ...theme2.cards, ...override.cards || {} }\n }), baseTheme);\n};\n// src/ThemeShowcase.tsx\nimport React2 from \"react\";\nvar ThemeShowcase = ({\n theme: theme2,\n title,\n showValues = true,\n sections = [\"colors\", \"typography\", \"spacing\", \"shadows\", \"radii\"]\n}) => {\n const containerStyle = {\n fontFamily: theme2.fonts.body,\n color: theme2.colors.text,\n backgroundColor: theme2.colors.background,\n padding: theme2.space[4],\n minHeight: \"100vh\"\n };\n const sectionStyle = {\n marginBottom: theme2.space[5],\n padding: theme2.space[4],\n backgroundColor: theme2.colors.surface || theme2.colors.backgroundSecondary,\n borderRadius: theme2.radii[2],\n border: `1px solid ${theme2.colors.border}`\n };\n const headingStyle = {\n fontFamily: theme2.fonts.heading,\n fontSize: theme2.fontSizes[5],\n fontWeight: theme2.fontWeights.heading,\n marginBottom: theme2.space[3],\n color: theme2.colors.primary\n };\n const subheadingStyle = {\n fontFamily: theme2.fonts.heading,\n fontSize: theme2.fontSizes[3],\n fontWeight: theme2.fontWeights.medium,\n marginBottom: theme2.space[2],\n marginTop: theme2.space[3],\n color: theme2.colors.text\n };\n return /* @__PURE__ */ React2.createElement(\"div\", {\n style: containerStyle\n }, title && /* @__PURE__ */ React2.createElement(\"h1\", {\n style: {\n ...headingStyle,\n fontSize: theme2.fontSizes[6],\n marginBottom: theme2.space[4]\n }\n }, title), sections.includes(\"colors\") && /* @__PURE__ */ React2.createElement(\"div\", {\n style: sectionStyle\n }, /* @__PURE__ */ React2.createElement(\"h2\", {\n style: headingStyle\n }, \"Colors\"), /* @__PURE__ */ React2.createElement(\"h3\", {\n style: subheadingStyle\n }, \"Primary Colors\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"grid\",\n gridTemplateColumns: \"repeat(auto-fill, minmax(200px, 1fr))\",\n gap: theme2.space[3],\n marginBottom: theme2.space[3]\n }\n }, [\"text\", \"background\", \"primary\", \"secondary\", \"accent\", \"muted\"].map((key) => {\n const color = theme2.colors[key];\n if (!color)\n return null;\n return /* @__PURE__ */ React2.createElement(\"div\", {\n key,\n style: {\n display: \"flex\",\n alignItems: \"center\",\n padding: theme2.space[2],\n backgroundColor: theme2.colors.backgroundLight || theme2.colors.backgroundTertiary,\n borderRadius: theme2.radii[1]\n }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n width: 40,\n height: 40,\n backgroundColor: color,\n border: `1px solid ${theme2.colors.border}`,\n borderRadius: theme2.radii[1],\n marginRight: theme2.space[2]\n }\n }), /* @__PURE__ */ React2.createElement(\"div\", null, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n fontWeight: theme2.fontWeights.medium\n }\n }, key), showValues && /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[0],\n color: theme2.colors.textSecondary\n }\n }, color)));\n })), /* @__PURE__ */ React2.createElement(\"h3\", {\n style: subheadingStyle\n }, \"Status Colors\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"grid\",\n gridTemplateColumns: \"repeat(auto-fill, minmax(200px, 1fr))\",\n gap: theme2.space[3],\n marginBottom: theme2.space[3]\n }\n }, [\"success\", \"warning\", \"error\", \"info\"].map((key) => {\n const color = theme2.colors[key];\n if (!color)\n return null;\n return /* @__PURE__ */ React2.createElement(\"div\", {\n key,\n style: {\n display: \"flex\",\n alignItems: \"center\",\n padding: theme2.space[2],\n backgroundColor: theme2.colors.backgroundLight || theme2.colors.backgroundTertiary,\n borderRadius: theme2.radii[1]\n }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n width: 40,\n height: 40,\n backgroundColor: color,\n border: `1px solid ${theme2.colors.border}`,\n borderRadius: theme2.radii[1],\n marginRight: theme2.space[2]\n }\n }), /* @__PURE__ */ React2.createElement(\"div\", null, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n fontWeight: theme2.fontWeights.medium\n }\n }, key), showValues && /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[0],\n color: theme2.colors.textSecondary\n }\n }, color)));\n })), /* @__PURE__ */ React2.createElement(\"h3\", {\n style: subheadingStyle\n }, \"Background Colors\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"grid\",\n gridTemplateColumns: \"repeat(auto-fill, minmax(200px, 1fr))\",\n gap: theme2.space[3]\n }\n }, [\"backgroundSecondary\", \"backgroundTertiary\", \"backgroundLight\", \"backgroundHover\", \"surface\"].map((key) => {\n const color = theme2.colors[key];\n if (!color)\n return null;\n return /* @__PURE__ */ React2.createElement(\"div\", {\n key,\n style: {\n padding: theme2.space[3],\n backgroundColor: color,\n border: `1px solid ${theme2.colors.border}`,\n borderRadius: theme2.radii[1]\n }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n fontWeight: theme2.fontWeights.medium\n }\n }, key), showValues && /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[0],\n color: theme2.colors.textSecondary,\n marginTop: theme2.space[1]\n }\n }, color));\n }))), sections.includes(\"typography\") && /* @__PURE__ */ React2.createElement(\"div\", {\n style: sectionStyle\n }, /* @__PURE__ */ React2.createElement(\"h2\", {\n style: headingStyle\n }, \"Typography\"), /* @__PURE__ */ React2.createElement(\"h3\", {\n style: subheadingStyle\n }, \"Font Families\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: { marginBottom: theme2.space[4] }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.heading,\n fontSize: theme2.fontSizes[4],\n marginBottom: theme2.space[2]\n }\n }, \"Heading Font: \", showValues && /* @__PURE__ */ React2.createElement(\"span\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n color: theme2.colors.textSecondary\n }\n }, \" \", theme2.fonts.heading)), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.body,\n fontSize: theme2.fontSizes[2],\n marginBottom: theme2.space[2]\n }\n }, \"Body Font: \", showValues && /* @__PURE__ */ React2.createElement(\"span\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n color: theme2.colors.textSecondary\n }\n }, \" \", theme2.fonts.body)), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[2]\n }\n }, \"Monospace Font: \", showValues && /* @__PURE__ */ React2.createElement(\"span\", {\n style: {\n fontSize: theme2.fontSizes[1],\n color: theme2.colors.textSecondary\n }\n }, \" \", theme2.fonts.monospace))), /* @__PURE__ */ React2.createElement(\"h3\", {\n style: subheadingStyle\n }, \"Font Sizes\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: { marginBottom: theme2.space[4] }\n }, theme2.fontSizes.map((size, index) => /* @__PURE__ */ React2.createElement(\"div\", {\n key: index,\n style: {\n fontSize: size,\n lineHeight: theme2.lineHeights.body,\n marginBottom: theme2.space[1]\n }\n }, \"Size \", index, \": Sample Text \", showValues && `(${size}px)`))), /* @__PURE__ */ React2.createElement(\"h3\", {\n style: subheadingStyle\n }, \"Font Weights\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"grid\",\n gridTemplateColumns: \"repeat(auto-fit, minmax(150px, 1fr))\",\n gap: theme2.space[2]\n }\n }, Object.entries(theme2.fontWeights).map(([name, weight]) => /* @__PURE__ */ React2.createElement(\"div\", {\n key: name,\n style: {\n fontWeight: weight,\n fontSize: theme2.fontSizes[2]\n }\n }, name, \" \", showValues && `(${weight})`)))), sections.includes(\"spacing\") && /* @__PURE__ */ React2.createElement(\"div\", {\n style: sectionStyle\n }, /* @__PURE__ */ React2.createElement(\"h2\", {\n style: headingStyle\n }, \"Spacing\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: { display: \"flex\", flexDirection: \"column\", gap: theme2.space[2] }\n }, theme2.space.map((space, index) => /* @__PURE__ */ React2.createElement(\"div\", {\n key: index,\n style: { display: \"flex\", alignItems: \"center\" }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n width: 60,\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n color: theme2.colors.textSecondary\n }\n }, \"[\", index, \"]\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n height: 24,\n width: space,\n backgroundColor: theme2.colors.primary,\n borderRadius: theme2.radii[1]\n }\n }), showValues && /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n marginLeft: theme2.space[2],\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n color: theme2.colors.textSecondary\n }\n }, space, \"px\"))))), sections.includes(\"radii\") && /* @__PURE__ */ React2.createElement(\"div\", {\n style: sectionStyle\n }, /* @__PURE__ */ React2.createElement(\"h2\", {\n style: headingStyle\n }, \"Border Radii\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"grid\",\n gridTemplateColumns: \"repeat(auto-fill, minmax(100px, 1fr))\",\n gap: theme2.space[3]\n }\n }, theme2.radii.map((radius, index) => /* @__PURE__ */ React2.createElement(\"div\", {\n key: index,\n style: { textAlign: \"center\" }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n width: 80,\n height: 80,\n backgroundColor: theme2.colors.primary,\n borderRadius: radius,\n marginBottom: theme2.space[1],\n margin: \"0 auto\"\n }\n }), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[0],\n color: theme2.colors.textSecondary\n }\n }, \"[\", index, \"] \", showValues && `${radius}px`))))), sections.includes(\"shadows\") && /* @__PURE__ */ React2.createElement(\"div\", {\n style: sectionStyle\n }, /* @__PURE__ */ React2.createElement(\"h2\", {\n style: headingStyle\n }, \"Shadows\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"grid\",\n gridTemplateColumns: \"repeat(auto-fill, minmax(150px, 1fr))\",\n gap: theme2.space[4]\n }\n }, theme2.shadows.map((shadow, index) => /* @__PURE__ */ React2.createElement(\"div\", {\n key: index,\n style: { textAlign: \"center\" }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n width: 100,\n height: 100,\n backgroundColor: theme2.colors.background,\n boxShadow: shadow,\n borderRadius: theme2.radii[2],\n margin: \"0 auto\",\n marginBottom: theme2.space[2],\n border: `1px solid ${theme2.colors.border}`\n }\n }), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[0],\n color: theme2.colors.textSecondary\n }\n }, \"Shadow [\", index, \"]\"), showValues && /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[0],\n color: theme2.colors.textMuted,\n marginTop: theme2.space[1]\n }\n }, shadow === \"none\" ? \"none\" : \"...\"))))), theme2.modes && Object.keys(theme2.modes).length > 0 && /* @__PURE__ */ React2.createElement(\"div\", {\n style: sectionStyle\n }, /* @__PURE__ */ React2.createElement(\"h2\", {\n style: headingStyle\n }, \"Available Modes\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"flex\",\n gap: theme2.space[2],\n flexWrap: \"wrap\"\n }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n padding: `${theme2.space[2]}px ${theme2.space[3]}px`,\n backgroundColor: theme2.colors.primary,\n color: \"#ffffff\",\n borderRadius: theme2.radii[2],\n fontFamily: theme2.fonts.body,\n fontSize: theme2.fontSizes[1]\n }\n }, \"default\"), Object.keys(theme2.modes).map((modeName) => /* @__PURE__ */ React2.createElement(\"div\", {\n key: modeName,\n style: {\n padding: `${theme2.space[2]}px ${theme2.space[3]}px`,\n backgroundColor: theme2.colors.secondary,\n color: theme2.colors.text,\n borderRadius: theme2.radii[2],\n fontFamily: theme2.fonts.body,\n fontSize: theme2.fontSizes[1]\n }\n }, modeName)))));\n};\n\n// src/index.ts\nvar theme = terminalTheme;\nfunction scaleThemeFonts(theme2, scale) {\n const currentScale = theme2.fontScale || 1;\n const effectiveScale = scale / currentScale;\n return {\n ...theme2,\n fontSizes: theme2.fontSizes.map((size) => Math.round(size * effectiveScale)),\n fontScale: scale\n };\n}\nfunction increaseFontScale(theme2) {\n const currentScale = theme2.fontScale || 1;\n const newScale = Math.min(currentScale * 1.1, 2);\n return scaleThemeFonts(theme2, newScale);\n}\nfunction decreaseFontScale(theme2) {\n const currentScale = theme2.fontScale || 1;\n const newScale = Math.max(currentScale * 0.9, 0.5);\n return scaleThemeFonts(theme2, newScale);\n}\nfunction resetFontScale(theme2) {\n return scaleThemeFonts(theme2, 1);\n}\nvar src_default = theme;\nexport {\n withTheme,\n useTheme,\n theme,\n terminalTheme,\n sx,\n slateTheme,\n scaleThemeFonts,\n responsive,\n resetFontScale,\n regalTheme,\n overrideColors,\n mergeThemes,\n matrixTheme,\n matrixMinimalTheme,\n makeTheme,\n increaseFontScale,\n glassmorphismTheme,\n getZIndex,\n getSpace,\n getShadow,\n getRadius,\n getMode,\n getFontSize,\n getColor,\n defaultTerminalTheme,\n defaultMarkdownTheme,\n defaultEditorTheme,\n src_default as default,\n decreaseFontScale,\n createStyle,\n addMode,\n ThemeShowcase,\n ThemeProvider\n};\n","function r(e){var t,f,n=\"\";if(\"string\"==typeof e||\"number\"==typeof e)n+=e;else if(\"object\"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(f=r(e[t]))&&(n&&(n+=\" \"),n+=f)}else for(f in e)e[f]&&(n&&(n+=\" \"),n+=f);return n}export function clsx(){for(var e,t,f=0,n=\"\",o=arguments.length;f<o;f++)(e=arguments[f])&&(t=r(e))&&(n&&(n+=\" \"),n+=t);return n}export default clsx;","import { type ClassValue, clsx } from \"clsx\";\n\nexport function cn(...inputs: ClassValue[]) {\n return clsx(inputs);\n}\n","import * as React from 'react';\nimport { cn } from '../lib/utils';\nimport type { Theme } from '@principal-ade/industry-theme';\nimport type { QualityMetrics } from '@principal-ai/codebase-composition';\n\nexport type { QualityMetrics };\nexport type QualityTier = 'none' | 'bronze' | 'silver' | 'gold' | 'platinum';\nexport type MetricKey = 'types' | 'documentation' | 'tests' | 'deadCode' | 'formatting' | 'linting';\n\nexport interface VertexHoverInfo {\n key: MetricKey;\n label: string;\n value: number;\n color: string;\n}\n\ninterface QualityHexagonProps {\n metrics: QualityMetrics;\n tier: QualityTier;\n theme: Theme;\n showLabels?: boolean;\n showValues?: boolean;\n className?: string;\n onVertexHover?: (info: VertexHoverInfo) => void;\n onVertexLeave?: () => void;\n onVertexClick?: (info: VertexHoverInfo) => void;\n}\n\n// Helper to extract theme colors\nfunction getThemeColors(theme: Theme) {\n return {\n gridColor: theme.colors.border,\n axisColor: theme.colors.muted,\n textColor: theme.colors.text,\n scoreColor: theme.colors.text,\n tierColors: {\n none: { fill: theme.colors.muted, stroke: theme.colors.border, bg: theme.colors.backgroundLight },\n bronze: { fill: theme.colors.warning, stroke: theme.colors.warning, bg: theme.colors.backgroundLight },\n silver: { fill: theme.colors.secondary, stroke: theme.colors.secondary, bg: theme.colors.backgroundLight },\n gold: { fill: theme.colors.accent, stroke: theme.colors.accent, bg: theme.colors.backgroundLight },\n platinum: { fill: theme.colors.primary, stroke: theme.colors.primary, bg: theme.colors.backgroundLight }\n },\n metricColors: {\n types: theme.colors.warning,\n documentation: theme.colors.info,\n tests: theme.colors.success,\n deadCode: theme.colors.error,\n formatting: theme.colors.accent,\n linting: theme.colors.primary\n },\n qualityIndicators: {\n good: theme.colors.success,\n medium: theme.colors.warning,\n poor: theme.colors.error\n }\n };\n}\n\n// Metrics ordered clockwise from top-left\nconst getMetricConfig = (themeColors: ReturnType<typeof getThemeColors>) => [\n { key: 'types', label: 'Types', color: themeColors.metricColors.types, angle: -120 },\n { key: 'documentation', label: 'Docs', color: themeColors.metricColors.documentation, angle: -60 },\n { key: 'tests', label: 'Tests', color: themeColors.metricColors.tests, angle: 0 },\n { key: 'deadCode', label: 'Dead Code', color: themeColors.metricColors.deadCode, angle: 60 },\n { key: 'formatting', label: 'Format', color: themeColors.metricColors.formatting, angle: 120 },\n { key: 'linting', label: 'Linting', color: themeColors.metricColors.linting, angle: 180 }\n] as const;\n\nfunction calculateHexagonPoints(center: number, radius: number, metricConfig: ReturnType<typeof getMetricConfig>): string {\n return metricConfig\n .map(({ angle }) => {\n const radian = (angle * Math.PI) / 180;\n const x = center + radius * Math.cos(radian);\n const y = center + radius * Math.sin(radian);\n return `${x},${y}`;\n })\n .join(' ');\n}\n\nfunction calculateMetricPoint(\n center: number,\n radius: number,\n angle: number,\n value: number\n): { x: number; y: number } {\n const actualRadius = (radius * value) / 100;\n const radian = (angle * Math.PI) / 180;\n return {\n x: center + actualRadius * Math.cos(radian),\n y: center + actualRadius * Math.sin(radian)\n };\n}\n\nexport function QualityHexagon({\n metrics,\n tier,\n theme,\n showLabels = false,\n showValues = false,\n className,\n onVertexHover,\n onVertexLeave,\n onVertexClick,\n}: QualityHexagonProps) {\n const themeColors = getThemeColors(theme);\n const colors = themeColors.tierColors[tier] ?? themeColors.tierColors.none;\n const metricConfig = getMetricConfig(themeColors);\n // Use fixed internal coordinates for viewBox\n const viewBoxSize = 300;\n const center = viewBoxSize / 2;\n const radius = viewBoxSize * 0.28;\n const padding = viewBoxSize * 0.1;\n const fontSize = viewBoxSize * 0.04;\n const strokeWidth = viewBoxSize * 0.008;\n const dotSize = viewBoxSize * 0.015;\n\n const hexagonPoints = calculateHexagonPoints(center, radius, metricConfig);\n\n const dataPoints = metricConfig\n .map(({ key, angle }) => {\n let value = metrics[key as keyof QualityMetrics];\n // Invert dead code metric (less is better)\n if (key === 'deadCode') {\n value = 100 - value;\n }\n return calculateMetricPoint(center, radius, angle, value);\n })\n .map(p => `${p.x},${p.y}`)\n .join(' ');\n\n // Calculate average with inverted dead code\n const metricsForAverage = { ...metrics };\n metricsForAverage.deadCode = 100 - metricsForAverage.deadCode;\n const averageScore = Math.round(\n Object.values(metricsForAverage).reduce((a, b) => a + b, 0) / 6\n );\n\n const hexagon = (\n <svg\n viewBox={`0 0 ${viewBoxSize} ${viewBoxSize}`}\n className={cn('w-full h-full transition-all duration-300', className)}\n preserveAspectRatio=\"xMidYMid meet\"\n >\n {/* Grid lines */}\n <g className=\"opacity-20\">\n {[20, 40, 60, 80, 100].map((percent) => (\n <polygon\n key={percent}\n points={calculateHexagonPoints(center, (radius * percent) / 100, metricConfig)}\n fill=\"none\"\n stroke={themeColors.gridColor}\n strokeWidth={0.5}\n style={{ opacity: 0.4 }}\n />\n ))}\n </g>\n\n {/* Axes */}\n {metricConfig.map(({ angle }) => {\n const endPoint = calculateMetricPoint(center, radius, angle, 100);\n return (\n <line\n key={angle}\n x1={center}\n y1={center}\n x2={endPoint.x}\n y2={endPoint.y}\n stroke={themeColors.axisColor}\n strokeWidth={0.5}\n style={{ opacity: 0.5 }}\n />\n );\n })}\n\n {/* Outer hexagon */}\n <polygon\n points={hexagonPoints}\n fill=\"none\"\n stroke={colors.stroke}\n strokeWidth={strokeWidth}\n style={{ opacity: 0.3 }}\n />\n\n {/* Data polygon */}\n <polygon\n points={dataPoints}\n fill={colors.fill}\n fillOpacity={0.3}\n stroke={colors.stroke}\n strokeWidth={strokeWidth}\n style={{ transition: 'all 0.5s ease' }}\n />\n\n {/* Vertex dots */}\n {metricConfig.map(({ key, label, color, angle }) => {\n const rawValue = metrics[key as keyof QualityMetrics];\n let value = rawValue;\n // Invert dead code metric for display\n if (key === 'deadCode') {\n value = 100 - value;\n }\n const point = calculateMetricPoint(center, radius, angle, 100);\n const dataPoint = calculateMetricPoint(center, radius, angle, value);\n\n const vertexInfo: VertexHoverInfo = {\n key: key as MetricKey,\n label,\n value: rawValue,\n color,\n };\n\n const handleMouseEnter = () => {\n onVertexHover?.(vertexInfo);\n };\n\n const handleClick = (e: React.MouseEvent) => {\n e.stopPropagation();\n onVertexClick?.(vertexInfo);\n };\n\n return (\n <g\n key={key}\n onMouseEnter={handleMouseEnter}\n onMouseLeave={onVertexLeave}\n onClick={handleClick}\n style={{ cursor: (onVertexHover || onVertexClick) ? 'pointer' : 'default' }}\n >\n {/* Larger invisible hit area for easier hovering */}\n <circle\n cx={point.x}\n cy={point.y}\n r={dotSize * 2.5}\n fill=\"transparent\"\n />\n {/* Outer vertex marker */}\n <circle\n cx={point.x}\n cy={point.y}\n r={dotSize}\n fill=\"white\"\n stroke={colors.stroke}\n strokeWidth={1.5}\n />\n {/* Value indicator */}\n <circle\n cx={dataPoint.x}\n cy={dataPoint.y}\n r={dotSize * 0.7}\n fill={colors.fill}\n stroke={colors.stroke}\n strokeWidth={1}\n style={{ opacity: 0.9 }}\n />\n </g>\n );\n })}\n\n {/* Center score */}\n <text\n x={center}\n y={center}\n textAnchor=\"middle\"\n dominantBaseline=\"middle\"\n fill={themeColors.scoreColor}\n fontSize={fontSize * 1.5}\n fontWeight=\"600\"\n >\n {averageScore}\n </text>\n <text\n x={center}\n y={center + fontSize}\n textAnchor=\"middle\"\n dominantBaseline=\"middle\"\n fill={themeColors.textColor}\n fontSize={fontSize * 0.8}\n style={{ opacity: 0.6 }}\n >\n avg\n </text>\n\n {/* Labels */}\n {showLabels && (\n <>\n {metricConfig.map(({ key, label, angle }) => {\n const labelRadius = radius + padding * 1.2;\n const point = calculateMetricPoint(center, labelRadius, angle, 100);\n const value = metrics[key as keyof QualityMetrics];\n\n return (\n <text\n key={key}\n x={point.x}\n y={point.y}\n textAnchor=\"middle\"\n dominantBaseline=\"middle\"\n fill={themeColors.textColor}\n fontSize={fontSize}\n >\n {showValues ? `${value}%` : label}\n </text>\n );\n })}\n </>\n )}\n </svg>\n );\n\n // For non-interactive mode or when tooltips are not available, just return the hexagon\n return hexagon;\n}\n\nexport function QualityHexagonCompact({\n metrics,\n tier,\n theme,\n className\n}: Pick<QualityHexagonProps, 'metrics' | 'tier' | 'theme' | 'className'>) {\n return (\n <div className={cn('w-20 h-20', className)}>\n <QualityHexagon\n metrics={metrics}\n tier={tier}\n theme={theme}\n showLabels={false}\n showValues={false}\n />\n </div>\n );\n}\n\ninterface QualityHexagonDetailedProps extends Pick<QualityHexagonProps, 'metrics' | 'tier' | 'theme' | 'className'> {\n packageName?: string;\n packageVersion?: string;\n onRefresh?: () => void;\n isRefreshing?: boolean;\n}\n\nexport function QualityHexagonDetailed({\n metrics,\n tier,\n theme,\n className,\n packageName,\n packageVersion,\n onRefresh,\n isRefreshing = false,\n}: QualityHexagonDetailedProps) {\n const themeColors = getThemeColors(theme);\n const colors = themeColors.tierColors[tier] ?? themeColors.tierColors.none;\n const metricConfig = getMetricConfig(themeColors);\n\n const hasHeader = packageName || onRefresh;\n\n return (\n <div\n className={cn(className)}\n style={{\n display: 'flex',\n flexDirection: 'column',\n gap: 12,\n padding: 16,\n borderRadius: 8,\n backgroundColor: colors.bg,\n }}\n >\n {hasHeader && (\n <div style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n gap: 12,\n }}>\n {packageName ? (\n <div style={{ display: 'flex', flexDirection: 'column', gap: 2 }}>\n {packageName.startsWith('@') && packageName.includes('/') ? (\n <>\n <span style={{\n fontSize: 12,\n color: theme.colors.textMuted,\n }}>\n {packageName.split('/')[0]}\n </span>\n <span style={{\n fontSize: 14,\n fontWeight: 500,\n color: colors.stroke,\n }}>\n {packageName.split('/')[1]}\n </span>\n </>\n ) : (\n <span style={{\n fontSize: 14,\n fontWeight: 500,\n color: colors.stroke,\n }}>\n {packageName}\n </span>\n )}\n {packageVersion && (\n <span style={{\n fontSize: 12,\n color: theme.colors.textMuted,\n }}>\n v{packageVersion}\n </span>\n )}\n </div>\n ) : <span />}\n {onRefresh && (\n <button\n onClick={onRefresh}\n disabled={isRefreshing}\n style={{\n padding: 6,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n border: `1px solid ${theme.colors.border}`,\n borderRadius: 4,\n background: theme.colors.surface,\n color: theme.colors.textMuted,\n cursor: isRefreshing ? 'not-allowed' : 'pointer',\n opacity: isRefreshing ? 0.6 : 1,\n }}\n title=\"Refresh\"\n >\n <svg\n width=\"14\"\n height=\"14\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n strokeWidth=\"2\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n style={{\n animation: isRefreshing ? 'spin 1s linear infinite' : 'none',\n }}\n >\n <path d=\"M21 12a9 9 0 0 0-9-9 9.75 9.75 0 0 0-6.74 2.74L3 8\" />\n <path d=\"M3 3v5h5\" />\n <path d=\"M3 12a9 9 0 0 0 9 9 9.75 9.75 0 0 0 6.74-2.74L21 16\" />\n <path d=\"M16 16h5v5\" />\n </svg>\n </button>\n )}\n </div>\n )}\n\n <div style={{\n display: 'flex',\n flexWrap: 'wrap',\n alignItems: 'center',\n justifyContent: 'center',\n gap: 24,\n }}>\n <div style={{ flex: '1 1 200px', maxWidth: 300, aspectRatio: '1 / 1' }}>\n <QualityHexagon\n metrics={metrics}\n tier={tier}\n theme={theme}\n showLabels={true}\n showValues={false}\n />\n </div>\n\n <div style={{ flex: '1 1 200px', minWidth: 200, display: 'flex', flexDirection: 'column', gap: 8, padding: '8px 24px' }}>\n {metricConfig.map(({ key, label, color }) => {\n const value = metrics[key as keyof QualityMetrics];\n const displayValue = value;\n\n return (\n <div key={key} style={{ display: 'flex', alignItems: 'center', justifyContent: 'space-between', gap: 12 }}>\n <span style={{\n fontSize: 14,\n color: theme.colors.textMuted,\n }}>\n {label}{key === 'deadCode' ? ' ↓' : ''}\n </span>\n <span style={{\n fontSize: 14,\n fontWeight: 500,\n color: color,\n }}>\n {displayValue}%\n </span>\n </div>\n );\n })}\n </div>\n </div>\n </div>\n );\n}\n\ninterface QualityHexagonExpandableProps extends Pick<QualityHexagonProps, 'metrics' | 'tier' | 'theme' | 'className'> {\n packageName?: string;\n packageVersion?: string;\n packagePath?: string;\n onRefresh?: () => void;\n isRefreshing?: boolean;\n defaultExpanded?: boolean;\n /** Callback when the hexagon is expanded/collapsed */\n onExpandChange?: (expanded: boolean, info: { packageName?: string; packagePath?: string }) => void;\n}\n\nexport function QualityHexagonExpandable({\n metrics,\n tier,\n theme,\n className,\n packageName,\n packageVersion,\n packagePath,\n onRefresh,\n isRefreshing = false,\n defaultExpanded = false,\n onExpandChange,\n}: QualityHexagonExpandableProps) {\n const [expanded, setExpanded] = React.useState(defaultExpanded);\n\n const handleToggleExpand = React.useCallback(() => {\n const newExpanded = !expanded;\n setExpanded(newExpanded);\n onExpandChange?.(newExpanded, { packageName, packagePath });\n }, [expanded, onExpandChange, packageName, packagePath]);\n const themeColors = getThemeColors(theme);\n const colors = themeColors.tierColors[tier] ?? themeColors.tierColors.none;\n const metricConfig = getMetricConfig(themeColors);\n\n const hasHeader = packageName || onRefresh;\n\n return (\n <div\n className={cn(className)}\n style={{\n display: 'flex',\n flexDirection: 'column',\n gap: 12,\n padding: 16,\n borderRadius: 8,\n backgroundColor: colors.bg,\n flex: '1 1 200px',\n }}\n >\n {hasHeader && (\n <div style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n gap: 12,\n }}>\n {packageName ? (\n <div style={{ display: 'flex', flexDirection: 'column', gap: 2 }}>\n {packageName.startsWith('@') && packageName.includes('/') ? (\n <>\n <span style={{\n fontSize: 12,\n color: theme.colors.textMuted,\n }}>\n {packageName.split('/')[0]}\n </span>\n <span style={{\n fontSize: 14,\n fontWeight: 500,\n color: colors.stroke,\n }}>\n {packageName.split('/')[1]}\n </span>\n </>\n ) : (\n <span style={{\n fontSize: 14,\n fontWeight: 500,\n color: colors.stroke,\n }}>\n {packageName}\n </span>\n )}\n {packageVersion && (\n <span style={{\n fontSize: 12,\n color: theme.colors.textMuted,\n }}>\n v{packageVersion}\n </span>\n )}\n </div>\n ) : <span />}\n {onRefresh && (\n <button\n onClick={onRefresh}\n disabled={isRefreshing}\n style={{\n padding: 6,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n border: `1px solid ${theme.colors.border}`,\n borderRadius: 4,\n background: theme.colors.surface,\n color: theme.colors.textMuted,\n cursor: isRefreshing ? 'not-allowed' : 'pointer',\n opacity: isRefreshing ? 0.6 : 1,\n }}\n title=\"Refresh\"\n >\n <svg\n width=\"14\"\n height=\"14\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n strokeWidth=\"2\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n style={{\n animation: isRefreshing ? 'spin 1s linear infinite' : 'none',\n }}\n >\n <path d=\"M21 12a9 9 0 0 0-9-9 9.75 9.75 0 0 0-6.74 2.74L3 8\" />\n <path d=\"M3 3v5h5\" />\n <path d=\"M3 12a9 9 0 0 0 9 9 9.75 9.75 0 0 0 6.74-2.74L21 16\" />\n <path d=\"M16 16h5v5\" />\n </svg>\n </button>\n )}\n </div>\n )}\n\n {/* Clickable hexagon */}\n <div\n onClick={handleToggleExpand}\n style={{\n cursor: 'pointer',\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n }}\n >\n <div style={{ width: 200, height: 200 }}>\n <QualityHexagon\n metrics={metrics}\n tier={tier}\n theme={theme}\n showLabels={true}\n showValues={false}\n />\n </div>\n </div>\n\n {/* Expandable metrics breakdown */}\n <div\n style={{\n display: 'grid',\n gridTemplateRows: expanded ? '1fr' : '0fr',\n transition: 'grid-template-rows 0.3s ease',\n }}\n >\n <div style={{ overflow: 'hidden' }}>\n <div style={{\n display: 'flex',\n flexDirection: 'column',\n gap: 8,\n padding: '8px 24px',\n borderTop: `1px solid ${theme.colors.border}`,\n marginTop: 8,\n }}>\n {metricConfig.map(({ key, label, color }) => {\n const value = metrics[key as keyof QualityMetrics];\n\n return (\n <div\n key={key}\n style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n gap: 12,\n }}\n >\n <span style={{\n fontSize: 14,\n color: theme.colors.textMuted,\n }}>\n {label}{key === 'deadCode' ? ' ↓' : ''}\n </span>\n <span style={{\n fontSize: 14,\n fontWeight: 500,\n color: color,\n }}>\n {value}%\n </span>\n </div>\n );\n })}\n </div>\n </div>\n </div>\n\n {/* Expand/collapse indicator */}\n <div\n onClick={handleToggleExpand}\n style={{\n display: 'flex',\n justifyContent: 'center',\n cursor: 'pointer',\n padding: 4,\n }}\n >\n <svg\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke={theme.colors.textMuted}\n strokeWidth=\"2\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n style={{\n transform: expanded ? 'rotate(180deg)' : 'rotate(0deg)',\n transition: 'transform 0.3s ease',\n }}\n >\n <path d=\"m6 9 6 6 6-6\" />\n </svg>\n </div>\n </div>\n );\n}\n\n/**\n * Calculate the quality tier based on metrics\n */\nexport function calculateQualityTier(metrics: QualityMetrics): QualityTier {\n // Invert dead code for calculation (less is better)\n const metricsForAverage = { ...metrics };\n metricsForAverage.deadCode = 100 - metricsForAverage.deadCode;\n\n const average = Object.values(metricsForAverage).reduce((a, b) => a + b, 0) / 6;\n\n if (average >= 90) return 'platinum';\n if (average >= 75) return 'gold';\n if (average >= 60) return 'silver';\n if (average >= 40) return 'bronze';\n return 'none';\n}\n","import React from 'react';\nimport { Terminal, Copy, Check, ChevronRight, Zap, GitBranch, Info } from 'lucide-react';\nimport type { Theme } from '@principal-ade/industry-theme';\n\ninterface QualityEmptyStateProps {\n theme: Theme;\n hasWorkflow: boolean;\n}\n\nconst WORKFLOW_FILE_PATH = '.github/workflows/quality-lens.yml';\n\n/**\n * Check if a file path exists in a FileTree's allFiles array\n */\nexport function checkFileExistsInTree(\n treeData: { allFiles?: Array<{ relativePath?: string; path?: string }> } | undefined,\n targetPath: string\n): boolean {\n if (!treeData?.allFiles) return false;\n\n const normalizedTarget = targetPath.replace(/^\\//, '').toLowerCase();\n\n return treeData.allFiles.some((file) => {\n const filePath = (file.relativePath || file.path || '').toLowerCase();\n return filePath.endsWith(normalizedTarget) || filePath === normalizedTarget;\n });\n}\n\n/**\n * Copyable command line component\n */\nconst CommandLine: React.FC<{\n command: string;\n theme: Theme;\n label?: string;\n}> = ({ command, theme, label }) => {\n const [copied, setCopied] = React.useState(false);\n\n const handleCopy = async () => {\n try {\n await navigator.clipboard.writeText(command);\n setCopied(true);\n setTimeout(() => setCopied(false), 2000);\n } catch {\n console.log('Copy:', command);\n }\n };\n\n return (\n <div style={{ display: 'flex', flexDirection: 'column', gap: 4 }}>\n {label && (\n <span style={{ fontSize: 12, color: theme.colors.textMuted }}>{label}</span>\n )}\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n gap: 12,\n padding: '10px 14px',\n borderRadius: 6,\n backgroundColor: theme.colors.background,\n border: `1px solid ${theme.colors.border}`,\n fontFamily: 'monospace',\n fontSize: 13,\n }}\n >\n <code style={{ color: theme.colors.text }}>{command}</code>\n <button\n onClick={handleCopy}\n style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n padding: 4,\n border: 'none',\n backgroundColor: 'transparent',\n color: theme.colors.textMuted,\n cursor: 'pointer',\n }}\n title=\"Copy command\"\n >\n {copied ? (\n <Check size={16} color={theme.colors.success} />\n ) : (\n <Copy size={16} />\n )}\n </button>\n </div>\n </div>\n );\n};\n\n/**\n * Mini hexagon preview showing what metrics are tracked\n */\nconst MetricsPreview: React.FC<{ theme: Theme }> = ({ theme }) => {\n const metrics = [\n { key: 'tests', label: 'Tests', description: 'Test coverage & pass rate', icon: '🧪' },\n { key: 'linting', label: 'Linting', description: 'ESLint code quality', icon: '📝' },\n { key: 'types', label: 'Types', description: 'TypeScript type safety', icon: '🔷' },\n { key: 'formatting', label: 'Formatting', description: 'Prettier code style', icon: '✨' },\n { key: 'deadCode', label: 'Dead Code', description: 'Unused exports & deps', icon: '🧹' },\n { key: 'documentation', label: 'Docs', description: 'Code documentation', icon: '📚' },\n ];\n\n return (\n <div\n style={{\n display: 'grid',\n gridTemplateColumns: 'repeat(2, 1fr)',\n gap: 8,\n padding: 12,\n borderRadius: 8,\n backgroundColor: theme.colors.surface,\n border: `1px solid ${theme.colors.border}`,\n }}\n >\n {metrics.map((m) => (\n <div\n key={m.key}\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 8,\n padding: '6px 8px',\n borderRadius: 4,\n fontSize: 12,\n }}\n >\n <span style={{ fontSize: 14 }}>{m.icon}</span>\n <div style={{ display: 'flex', flexDirection: 'column' }}>\n <span style={{ fontWeight: 500, color: theme.colors.text }}>{m.label}</span>\n <span style={{ fontSize: 11, color: theme.colors.textMuted }}>{m.description}</span>\n </div>\n </div>\n ))}\n </div>\n );\n};\n\n/**\n * Empty state component for when no quality data is available\n */\nexport const QualityEmptyState: React.FC<QualityEmptyStateProps> = ({\n theme,\n hasWorkflow,\n}) => {\n const [showAdvanced, setShowAdvanced] = React.useState(false);\n\n if (hasWorkflow) {\n // Workflow exists but no data yet\n return (\n <div\n style={{\n display: 'flex',\n flexDirection: 'column',\n padding: '16px 0',\n gap: 16,\n width: '100%',\n }}\n >\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 8,\n padding: '10px 14px',\n borderRadius: 6,\n backgroundColor: `${theme.colors.success}15`,\n color: theme.colors.success,\n fontSize: 13,\n }}\n >\n <Check size={16} />\n <span>Workflow detected at {WORKFLOW_FILE_PATH}</span>\n </div>\n\n <p\n style={{\n margin: 0,\n fontSize: 14,\n color: theme.colors.textMuted,\n lineHeight: 1.5,\n }}\n >\n Quality metrics will appear here after your workflow runs. Push a commit to trigger it, or check the Actions tab for status.\n </p>\n\n <MetricsPreview theme={theme} />\n\n <div\n style={{\n display: 'flex',\n alignItems: 'flex-start',\n gap: 8,\n padding: '10px 14px',\n borderRadius: 6,\n backgroundColor: `${theme.colors.warning}10`,\n fontSize: 12,\n color: theme.colors.textMuted,\n }}\n >\n <Info size={14} style={{ flexShrink: 0, marginTop: 2 }} color={theme.colors.warning} />\n <div>\n <strong style={{ color: theme.colors.text }}>Using private npm packages?</strong>\n <br />\n Add <code style={{ backgroundColor: theme.colors.background, padding: '1px 4px', borderRadius: 3 }}>NPM_TOKEN</code> to your repository secrets and ensure the workflow has access to it.\n </div>\n </div>\n </div>\n );\n }\n\n // No workflow - show setup instructions\n return (\n <div\n style={{\n display: 'flex',\n flexDirection: 'column',\n padding: '16px 0',\n gap: 16,\n width: '100%',\n }}\n >\n {/* What you'll get */}\n <div>\n <h4\n style={{\n margin: '0 0 12px 0',\n fontSize: 14,\n fontWeight: 600,\n color: theme.colors.text,\n }}\n >\n Track 6 quality dimensions\n </h4>\n <MetricsPreview theme={theme} />\n </div>\n\n {/* Quick Start */}\n <div\n style={{\n display: 'flex',\n flexDirection: 'column',\n gap: 12,\n padding: 16,\n borderRadius: 8,\n backgroundColor: theme.colors.surface,\n border: `1px solid ${theme.colors.border}`,\n }}\n >\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 8,\n }}\n >\n <Zap size={18} color={theme.colors.primary} />\n <h4\n style={{\n margin: 0,\n fontSize: 14,\n fontWeight: 600,\n color: theme.colors.text,\n }}\n >\n Quick Start\n </h4>\n </div>\n\n <p\n style={{\n margin: 0,\n fontSize: 13,\n color: theme.colors.textMuted,\n lineHeight: 1.5,\n }}\n >\n Run this in your project directory to set up automated quality tracking:\n </p>\n\n <CommandLine\n command=\"npx @principal-ai/quality-lens-cli init\"\n theme={theme}\n />\n\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 6,\n fontSize: 12,\n color: theme.colors.textMuted,\n }}\n >\n <GitBranch size={14} />\n <span>Then commit and push to start tracking</span>\n </div>\n </div>\n\n {/* Advanced Options Toggle */}\n <button\n onClick={() => setShowAdvanced(!showAdvanced)}\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 6,\n padding: 0,\n border: 'none',\n backgroundColor: 'transparent',\n color: theme.colors.textMuted,\n fontSize: 13,\n cursor: 'pointer',\n }}\n >\n <ChevronRight\n size={14}\n style={{\n transform: showAdvanced ? 'rotate(90deg)' : 'none',\n transition: 'transform 0.2s',\n }}\n />\n <span>{showAdvanced ? 'Hide' : 'Show'} additional options</span>\n </button>\n\n {/* Advanced Options */}\n {showAdvanced && (\n <div\n style={{\n display: 'flex',\n flexDirection: 'column',\n gap: 16,\n padding: 16,\n borderRadius: 8,\n backgroundColor: theme.colors.surface,\n border: `1px solid ${theme.colors.border}`,\n }}\n >\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 8,\n }}\n >\n <Terminal size={18} color={theme.colors.text} />\n <h4\n style={{\n margin: 0,\n fontSize: 14,\n fontWeight: 600,\n color: theme.colors.text,\n }}\n >\n CLI Commands\n </h4>\n </div>\n\n <CommandLine\n command=\"npx @principal-ai/quality-lens-cli list\"\n theme={theme}\n label=\"See available quality tools in your project\"\n />\n\n <CommandLine\n command=\"npx @principal-ai/quality-lens-cli run . --install\"\n theme={theme}\n label=\"Run quality checks locally (auto-installs missing tools)\"\n />\n\n <CommandLine\n command=\"npm install -g @principal-ai/quality-lens-cli\"\n theme={theme}\n label=\"Install globally for faster repeated use\"\n />\n\n <div\n style={{\n display: 'flex',\n alignItems: 'flex-start',\n gap: 8,\n padding: '10px 14px',\n borderRadius: 6,\n backgroundColor: `${theme.colors.warning}10`,\n fontSize: 12,\n color: theme.colors.textMuted,\n }}\n >\n <Info size={14} style={{ flexShrink: 0, marginTop: 2 }} color={theme.colors.warning} />\n <div>\n <strong style={{ color: theme.colors.text }}>Private npm packages?</strong>\n <br />\n If your project uses private @org packages, add <code style={{ backgroundColor: theme.colors.background, padding: '1px 4px', borderRadius: 3 }}>NPM_TOKEN</code> to your GitHub repository secrets under Settings → Secrets → Actions, and set the workflow environment if needed.\n </div>\n </div>\n </div>\n )}\n </div>\n );\n};\n\nexport { WORKFLOW_FILE_PATH };\n","import React from 'react';\nimport { Hexagon } from 'lucide-react';\nimport { useTheme } from '@principal-ade/industry-theme';\nimport type { PanelComponentProps } from '../types';\nimport type { QualityMetrics } from '@principal-ai/codebase-composition';\nimport {\n QualityHexagonExpandable,\n QualityTier,\n calculateQualityTier,\n} from '../components/QualityHexagon';\nimport {\n QualityEmptyState,\n checkFileExistsInTree,\n WORKFLOW_FILE_PATH,\n} from '../components/QualityEmptyState';\n\n// Mock package data - in real usage, this would come from a quality slice\nconst mockPackages: Array<{\n name: string;\n version?: string;\n metrics: QualityMetrics;\n}> = [\n {\n name: '@principal-ade/code-quality-panels',\n version: '0.1.0',\n metrics: {\n tests: 75,\n deadCode: 15,\n linting: 85,\n formatting: 90,\n types: 88,\n documentation: 65,\n },\n },\n];\n\n// Package quality data shape from slice\ninterface PackageQuality {\n name: string;\n path?: string;\n version?: string;\n metrics: QualityMetrics;\n}\n\n// Slice data shape\ninterface QualitySliceData {\n packages: PackageQuality[];\n lastUpdated: string;\n}\n\n/**\n * QualityHexagonPanelContent - Internal component that uses theme\n */\nconst QualityHexagonPanelContent: React.FC<PanelComponentProps> = ({\n context,\n events,\n}) => {\n const { theme } = useTheme();\n const [refreshingPackages, setRefreshingPackages] = React.useState<Set<string>>(new Set());\n\n // Get quality data from context if available\n const qualitySlice = context.getSlice<QualitySliceData>('quality');\n const hasQualitySlice = context.hasSlice('quality');\n const isLoading = qualitySlice?.loading ?? false;\n\n // Get file tree to check for workflow presence\n const fileTreeSlice = context.getSlice<{ allFiles?: Array<{ relativePath?: string; path?: string }> }>('fileTree');\n const hasWorkflow = React.useMemo(() => {\n return checkFileExistsInTree(fileTreeSlice?.data ?? undefined, WORKFLOW_FILE_PATH);\n }, [fileTreeSlice?.data]);\n\n // Determine packages to display\n // - If slice exists and has data, use it\n // - If slice exists but is loading/empty, show empty\n // - If no slice at all, use mock data for demo\n const packages: PackageQuality[] = React.useMemo(() => {\n if (qualitySlice?.data?.packages) {\n return qualitySlice.data.packages;\n }\n if (hasQualitySlice) {\n // Slice exists but no data yet (loading or empty)\n return [];\n }\n // No slice - use mock for demo\n return mockPackages;\n }, [qualitySlice?.data?.packages, hasQualitySlice]);\n\n // Handle refresh for a specific package\n const handleRefreshPackage = async (packageName: string) => {\n setRefreshingPackages(prev => new Set(prev).add(packageName));\n try {\n if (context.hasSlice('quality')) {\n // In future, this could refresh just one package\n await context.refresh('repository', 'quality');\n }\n } finally {\n setRefreshingPackages(prev => {\n const next = new Set(prev);\n next.delete(packageName);\n return next;\n });\n }\n };\n\n // Handle refresh all\n const handleRefreshAll = async () => {\n const allNames = packages.map(p => p.name);\n setRefreshingPackages(new Set(allNames));\n try {\n if (context.hasSlice('quality')) {\n await context.refresh('repository', 'quality');\n }\n } finally {\n setRefreshingPackages(new Set());\n }\n };\n\n // Subscribe to events\n React.useEffect(() => {\n const unsubscribers = [\n events.on('principal-ade.quality-panel:refresh', async () => {\n await handleRefreshAll();\n }),\n ];\n\n return () => unsubscribers.forEach((unsub) => unsub());\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [events, context, packages]);\n\n // Tier colors for display\n const tierColors: Record<QualityTier, string> = {\n none: theme.colors.muted,\n bronze: theme.colors.warning,\n silver: theme.colors.secondary,\n gold: theme.colors.accent,\n platinum: theme.colors.primary,\n };\n\n // Calculate overall tier from all packages\n const overallTier = packages.length > 0\n ? calculateQualityTier(\n packages.reduce((acc, pkg) => ({\n tests: acc.tests + pkg.metrics.tests / packages.length,\n deadCode: acc.deadCode + pkg.metrics.deadCode / packages.length,\n linting: acc.linting + pkg.metrics.linting / packages.length,\n formatting: acc.formatting + pkg.metrics.formatting / packages.length,\n types: acc.types + pkg.metrics.types / packages.length,\n documentation: acc.documentation + pkg.metrics.documentation / packages.length,\n }), { tests: 0, deadCode: 0, linting: 0, formatting: 0, types: 0, documentation: 0 })\n )\n : 'none';\n\n return (\n <div\n style={{\n fontFamily: theme.fonts.body,\n height: '100%',\n minHeight: 0,\n backgroundColor: theme.colors.background,\n color: theme.colors.text,\n overflowY: 'auto',\n boxSizing: 'border-box',\n }}\n >\n <div\n style={{\n padding: 20,\n display: 'flex',\n flexDirection: 'column',\n gap: 16,\n }}\n >\n {/* Header */}\n <div style={{ display: 'flex', alignItems: 'center', gap: 12 }}>\n <Hexagon size={24} color={tierColors[overallTier]} />\n <h2\n style={{\n margin: 0,\n fontSize: 20,\n fontWeight: 600,\n color: theme.colors.text,\n }}\n >\n Code Quality\n </h2>\n <span\n title=\"Platinum: 90%+ avg | Gold: 75%+ | Silver: 60%+ | Bronze: 40%+\"\n style={{\n display: 'inline-flex',\n alignItems: 'center',\n justifyContent: 'center',\n width: 18,\n height: 18,\n borderRadius: '50%',\n border: `1px solid ${theme.colors.border}`,\n fontSize: 12,\n color: theme.colors.textMuted,\n cursor: 'help',\n }}\n >\n ?\n </span>\n {packages.length > 1 && (\n <span style={{\n fontSize: 14,\n color: theme.colors.textMuted,\n }}>\n {packages.length} packages\n </span>\n )}\n </div>\n\n {/* Quality Hexagons for each package */}\n <div style={{ display: 'flex', flexWrap: 'wrap', gap: 16, minHeight: 0 }}>\n {isLoading ? (\n <div style={{\n padding: 40,\n textAlign: 'center',\n color: theme.colors.textMuted,\n }}>\n Loading quality metrics...\n </div>\n ) : packages.length === 0 ? (\n <QualityEmptyState\n theme={theme}\n hasWorkflow={hasWorkflow}\n />\n ) : (\n packages.map((pkg) => {\n const tier = calculateQualityTier(pkg.metrics);\n // Use package path from slice data\n // For single-package repos, path is empty string (root)\n // For monorepos, path would be like \"packages/core\"\n const packagePath = pkg.path ?? '';\n return (\n <QualityHexagonExpandable\n key={pkg.name}\n metrics={pkg.metrics}\n tier={tier}\n theme={theme}\n packageName={pkg.name}\n packageVersion={pkg.version}\n packagePath={packagePath}\n onExpandChange={(expanded, info) => {\n // Emit package:select event for cross-panel filtering\n // When expanded, select this package; when collapsed, deselect\n events.emit({\n type: 'package:select',\n source: 'principal-ade.quality-hexagon-panel',\n timestamp: Date.now(),\n payload: expanded ? {\n packagePath: info.packagePath ?? '',\n packageName: info.packageName,\n } : null,\n });\n }}\n />\n );\n })\n )}\n </div>\n </div>\n </div>\n );\n};\n\n/**\n * QualityHexagonPanel - A panel for visualizing code quality metrics\n */\nexport const QualityHexagonPanel = QualityHexagonPanelContent;\n","import * as React from 'react';\nimport { cn } from '../lib/utils';\nimport type { Theme } from '@principal-ade/industry-theme';\nimport type { QualityMetrics } from '@principal-ai/codebase-composition';\nimport { QualityHexagon, calculateQualityTier, type QualityTier, type VertexHoverInfo, type MetricKey } from './QualityHexagon';\n\nexport type { VertexHoverInfo, MetricKey };\n\nconst METRIC_OPTIONS: Array<{ key: MetricKey; label: string }> = [\n { key: 'types', label: 'Types' },\n { key: 'documentation', label: 'Docs' },\n { key: 'tests', label: 'Tests' },\n { key: 'deadCode', label: 'Dead Code' },\n { key: 'formatting', label: 'Format' },\n { key: 'linting', label: 'Linting' },\n];\n\n/**\n * Represents a single package within a repository\n */\nexport interface PackageQualityItem {\n /** Package name (e.g., \"@acme/core\" or \"my-app\") */\n name: string;\n /** Optional version string */\n version?: string;\n /** Quality metrics for this package */\n metrics: QualityMetrics;\n}\n\n/**\n * Represents a repository with one or more packages\n */\nexport interface RepositoryQualityItem {\n /** Unique identifier for the repository */\n id: string;\n /** Repository name */\n name: string;\n /** Optional path to the repository */\n path?: string;\n /** Packages within this repository (monorepos have multiple) */\n packages: PackageQualityItem[];\n}\n\n/**\n * A flattened item for display in the grid\n */\nexport interface FlatGridItem {\n /** Unique key for React */\n key: string;\n /** Repository ID */\n repositoryId: string;\n /** Repository name */\n repositoryName: string;\n /** Repository path (for filtering in other panels) */\n repositoryPath?: string;\n /** Package name */\n packageName: string;\n /** Optional version */\n version?: string;\n /** Quality metrics */\n metrics: QualityMetrics;\n /** Calculated tier */\n tier: QualityTier;\n}\n\ninterface RepositoryQualityGridProps {\n /** Array of repositories with their packages */\n repositories: RepositoryQualityItem[];\n /** Theme from @principal-ade/industry-theme */\n theme: Theme;\n /** Callback when a grid item is clicked */\n onItemClick?: (item: FlatGridItem) => void;\n /** Callback when a hexagon vertex is clicked */\n onVertexClick?: (item: FlatGridItem, vertex: VertexHoverInfo) => void;\n /** Optional CSS class */\n className?: string;\n /** Show repository name in label (default: true) */\n showRepositoryName?: boolean;\n /** Show overall summary header (default: true) */\n showSummary?: boolean;\n}\n\ninterface RepositoryQualityGridItemProps {\n /** The flattened item to display */\n item: FlatGridItem;\n /** Theme */\n theme: Theme;\n /** Click handler for the card */\n onClick?: () => void;\n /** Click handler for hexagon vertices */\n onVertexClick?: (item: FlatGridItem, vertex: VertexHoverInfo) => void;\n /** Show repository name in label */\n showRepositoryName?: boolean;\n /** Selected metric to display (from dropdown) */\n selectedMetric?: MetricKey | null;\n /** Optional CSS class */\n className?: string;\n}\n\n/**\n * Flatten repositories into a single array of grid items\n */\nfunction flattenRepositories(repositories: RepositoryQualityItem[]): FlatGridItem[] {\n const items: FlatGridItem[] = [];\n\n for (const repo of repositories) {\n for (const pkg of repo.packages) {\n items.push({\n key: `${repo.id}:${pkg.name}`,\n repositoryId: repo.id,\n repositoryName: repo.name,\n repositoryPath: repo.path,\n packageName: pkg.name,\n version: pkg.version,\n metrics: pkg.metrics,\n tier: calculateQualityTier(pkg.metrics),\n });\n }\n }\n\n return items;\n}\n\n/**\n * Calculate overall tier from all items\n */\nfunction calculateOverallTier(items: FlatGridItem[]): QualityTier {\n if (items.length === 0) return 'none';\n\n const avgMetrics = items.reduce(\n (acc, item) => ({\n tests: acc.tests + item.metrics.tests / items.length,\n deadCode: acc.deadCode + item.metrics.deadCode / items.length,\n linting: acc.linting + item.metrics.linting / items.length,\n formatting: acc.formatting + item.metrics.formatting / items.length,\n types: acc.types + item.metrics.types / items.length,\n documentation: acc.documentation + item.metrics.documentation / items.length,\n }),\n { tests: 0, deadCode: 0, linting: 0, formatting: 0, types: 0, documentation: 0 }\n );\n\n return calculateQualityTier(avgMetrics);\n}\n\n/**\n * Format the display label for an item\n */\nfunction formatLabel(\n item: FlatGridItem,\n showRepositoryName: boolean,\n isSameAsRepo: boolean\n): string {\n if (!showRepositoryName || isSameAsRepo) {\n return item.packageName;\n }\n return `${item.repositoryName} / ${item.packageName}`;\n}\n\n/**\n * Individual grid item component\n */\n// Get color based on value (good/medium/poor)\nfunction getValueColor(value: number, key: MetricKey, theme: Theme): string {\n // For deadCode, lower is better (invert the logic)\n const effectiveValue = key === 'deadCode' ? 100 - value : value;\n\n if (effectiveValue >= 80) return theme.colors.success;\n if (effectiveValue >= 60) return theme.colors.warning;\n return theme.colors.error;\n}\n\nexport function RepositoryQualityGridItem({\n item,\n theme,\n onClick,\n onVertexClick,\n showRepositoryName = true,\n selectedMetric,\n className,\n}: RepositoryQualityGridItemProps) {\n const [hoveredVertex, setHoveredVertex] = React.useState<VertexHoverInfo | null>(null);\n const isSameAsRepo = item.packageName === item.repositoryName;\n const label = formatLabel(item, showRepositoryName, isSameAsRepo);\n\n const tierColors: Record<QualityTier, string> = {\n none: theme.colors.muted,\n bronze: theme.colors.warning,\n silver: theme.colors.secondary,\n gold: theme.colors.accent,\n platinum: theme.colors.primary,\n };\n\n // Get the display info - either from selected metric or hovered vertex\n const displayInfo = React.useMemo(() => {\n if (selectedMetric) {\n const option = METRIC_OPTIONS.find(o => o.key === selectedMetric);\n if (option) {\n const value = item.metrics[selectedMetric];\n return {\n label: option.label,\n value,\n valueColor: getValueColor(value, selectedMetric, theme),\n };\n }\n }\n if (hoveredVertex) {\n return {\n label: hoveredVertex.label,\n value: hoveredVertex.value,\n valueColor: getValueColor(hoveredVertex.value, hoveredVertex.key, theme),\n };\n }\n return null;\n }, [selectedMetric, hoveredVertex, item.metrics, theme]);\n\n return (\n <div\n className={cn(className)}\n onClick={onClick}\n style={{\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n gap: 8,\n padding: 12,\n borderRadius: 8,\n backgroundColor: theme.colors.surface,\n border: `1px solid ${theme.colors.border}`,\n cursor: onClick ? 'pointer' : 'default',\n transition: 'all 0.2s ease',\n }}\n onMouseEnter={(e) => {\n if (onClick) {\n e.currentTarget.style.borderColor = tierColors[item.tier];\n e.currentTarget.style.transform = 'translateY(-2px)';\n }\n }}\n onMouseLeave={(e) => {\n e.currentTarget.style.borderColor = theme.colors.border;\n e.currentTarget.style.transform = 'translateY(0)';\n setHoveredVertex(null);\n }}\n >\n {/* Metric info header */}\n <div\n style={{\n height: 24,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n gap: 8,\n width: '100%',\n minHeight: 24,\n }}\n >\n {displayInfo ? (\n <>\n <span\n style={{\n fontSize: 14,\n fontWeight: 500,\n color: theme.colors.text,\n }}\n >\n {displayInfo.label}\n </span>\n <span\n style={{\n fontSize: 14,\n fontWeight: 600,\n color: displayInfo.valueColor,\n }}\n >\n {displayInfo.value}%\n </span>\n </>\n ) : (\n <span style={{ fontSize: 12, color: theme.colors.textMuted }}>\n Hover a corner\n </span>\n )}\n </div>\n <div style={{ width: 200, height: 200 }}>\n <QualityHexagon\n metrics={item.metrics}\n tier={item.tier}\n theme={theme}\n showLabels={false}\n showValues={false}\n onVertexHover={setHoveredVertex}\n onVertexLeave={() => setHoveredVertex(null)}\n onVertexClick={onVertexClick ? (vertex) => onVertexClick(item, vertex) : undefined}\n />\n </div>\n <div\n style={{\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n gap: 2,\n }}\n >\n <span\n style={{\n fontSize: 12,\n fontWeight: 500,\n color: theme.colors.text,\n textAlign: 'center',\n }}\n >\n {label}\n </span>\n {item.version && (\n <span\n style={{\n fontSize: 10,\n color: theme.colors.textMuted,\n }}\n >\n v{item.version}\n </span>\n )}\n </div>\n </div>\n );\n}\n\n/**\n * RepositoryQualityGrid - Displays a flat grid of quality hexagons\n * for multiple repositories and their packages.\n *\n * Each hexagon shows the quality metrics for a single package,\n * labeled with \"repo / package\" format for clarity.\n */\n// Calculate average score for an item (with deadCode inverted)\nfunction calculateAverageScore(metrics: QualityMetrics): number {\n const adjusted = { ...metrics };\n adjusted.deadCode = 100 - adjusted.deadCode;\n return Object.values(adjusted).reduce((a, b) => a + b, 0) / 6;\n}\n\nexport function RepositoryQualityGrid({\n repositories,\n theme,\n onItemClick,\n onVertexClick,\n className,\n showRepositoryName = true,\n showSummary = true,\n}: RepositoryQualityGridProps) {\n const [selectedMetric, setSelectedMetric] = React.useState<MetricKey | null>(null);\n const items = React.useMemo(() => flattenRepositories(repositories), [repositories]);\n const overallTier = React.useMemo(() => calculateOverallTier(items), [items]);\n\n // Sort items based on selected metric or average\n const sortedItems = React.useMemo(() => {\n return [...items].sort((a, b) => {\n if (selectedMetric) {\n // Sort by selected metric (for deadCode, lower is better so invert)\n const aVal = selectedMetric === 'deadCode'\n ? 100 - a.metrics[selectedMetric]\n : a.metrics[selectedMetric];\n const bVal = selectedMetric === 'deadCode'\n ? 100 - b.metrics[selectedMetric]\n : b.metrics[selectedMetric];\n return bVal - aVal; // Descending (best first)\n } else {\n // Sort by average score\n return calculateAverageScore(b.metrics) - calculateAverageScore(a.metrics);\n }\n });\n }, [items, selectedMetric]);\n\n const tierColors: Record<QualityTier, string> = {\n none: theme.colors.muted,\n bronze: theme.colors.warning,\n silver: theme.colors.secondary,\n gold: theme.colors.accent,\n platinum: theme.colors.primary,\n };\n\n const tierLabels: Record<QualityTier, string> = {\n none: 'No Data',\n bronze: 'Bronze',\n silver: 'Silver',\n gold: 'Gold',\n platinum: 'Platinum',\n };\n\n if (items.length === 0) {\n return (\n <div\n className={cn(className)}\n style={{\n padding: 40,\n textAlign: 'center',\n color: theme.colors.textMuted,\n backgroundColor: theme.colors.background,\n borderRadius: 8,\n }}\n >\n No repositories to display\n </div>\n );\n }\n\n return (\n <div\n className={cn(className)}\n style={{\n display: 'flex',\n flexDirection: 'column',\n gap: 16,\n backgroundColor: theme.colors.background,\n fontFamily: theme.fonts.body,\n }}\n >\n {/* Summary Header */}\n {showSummary && (\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n flexWrap: 'wrap',\n gap: 12,\n padding: '12px 16px',\n backgroundColor: theme.colors.surface,\n border: `1px solid ${theme.colors.border}`,\n }}\n >\n <div style={{ display: 'flex', alignItems: 'center', gap: 12 }}>\n <span\n style={{\n fontSize: 14,\n fontWeight: 500,\n color: theme.colors.text,\n }}\n >\n {items.length} {items.length === 1 ? 'package' : 'packages'}\n </span>\n <span style={{ color: theme.colors.textMuted }}>•</span>\n <span\n style={{\n fontSize: 14,\n color: theme.colors.textMuted,\n }}\n >\n {repositories.length} {repositories.length === 1 ? 'repository' : 'repositories'}\n </span>\n </div>\n <div style={{ display: 'flex', alignItems: 'center', gap: 12 }}>\n {/* Metric dropdown */}\n <select\n value={selectedMetric ?? ''}\n onChange={(e) => setSelectedMetric(e.target.value ? e.target.value as MetricKey : null)}\n style={{\n padding: '4px 8px',\n fontSize: 13,\n backgroundColor: theme.colors.background,\n color: theme.colors.text,\n border: `1px solid ${theme.colors.border}`,\n borderRadius: 4,\n cursor: 'pointer',\n outline: 'none',\n }}\n >\n <option value=\"\">Select metric...</option>\n {METRIC_OPTIONS.map((option) => (\n <option key={option.key} value={option.key}>\n {option.label}\n </option>\n ))}\n </select>\n {/* Tier badge */}\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 8,\n padding: '4px 12px',\n backgroundColor: theme.colors.backgroundLight,\n borderRadius: 16,\n border: `1px solid ${tierColors[overallTier]}`,\n }}\n >\n <span\n style={{\n width: 8,\n height: 8,\n borderRadius: '50%',\n backgroundColor: tierColors[overallTier],\n }}\n />\n <span\n style={{\n fontSize: 13,\n fontWeight: 500,\n color: tierColors[overallTier],\n }}\n >\n {tierLabels[overallTier]}\n </span>\n </div>\n </div>\n </div>\n )}\n\n {/* Grid of Items */}\n <div\n style={{\n display: 'grid',\n gridTemplateColumns: 'repeat(auto-fill, minmax(220px, 1fr))',\n gap: 12,\n padding: 16,\n }}\n >\n {sortedItems.map((item) => (\n <RepositoryQualityGridItem\n key={item.key}\n item={item}\n theme={theme}\n onClick={onItemClick ? () => onItemClick(item) : undefined}\n onVertexClick={onVertexClick}\n showRepositoryName={showRepositoryName}\n selectedMetric={selectedMetric}\n />\n ))}\n </div>\n </div>\n );\n}\n","import React from 'react';\nimport { useTheme } from '@principal-ade/industry-theme';\nimport type { PanelComponentProps } from '../types';\nimport type { QualityMetrics } from '@principal-ai/codebase-composition';\nimport {\n RepositoryQualityGrid,\n type RepositoryQualityItem,\n type FlatGridItem,\n type VertexHoverInfo,\n} from '../components/RepositoryQualityGrid';\nimport { QualityEmptyState } from '../components/QualityEmptyState';\n\n// Repository quality data from slice\ninterface RepositoryQualityData {\n id: string;\n name: string;\n path?: string;\n packages: Array<{\n name: string;\n version?: string;\n metrics: QualityMetrics;\n }>;\n}\n\n// Slice data shape\ninterface RepositoriesQualitySliceData {\n repositories: RepositoryQualityData[];\n lastUpdated: string;\n}\n\n/**\n * RepositoryQualityGridPanelContent - Internal component that uses theme\n */\nconst RepositoryQualityGridPanelContent: React.FC<PanelComponentProps> = ({\n context,\n events,\n}) => {\n const { theme } = useTheme();\n\n // Track currently selected item for toggle behavior\n const [selectedItemKey, setSelectedItemKey] = React.useState<string | null>(null);\n\n // Get repositories quality data from context if available\n const qualitySlice = context.getSlice<RepositoriesQualitySliceData>('repositoriesQuality');\n const isLoading = qualitySlice?.loading ?? false;\n\n // Determine repositories to display\n const repositories: RepositoryQualityItem[] = React.useMemo(() => {\n if (qualitySlice?.data?.repositories) {\n return qualitySlice.data.repositories;\n }\n return [];\n }, [qualitySlice?.data?.repositories]);\n\n // Handle item click\n const handleItemClick = (item: FlatGridItem) => {\n const isDeselecting = selectedItemKey === item.key;\n\n events.emit({\n type: 'principal-ade.repository-quality-grid:item:click',\n source: 'principal-ade.repository-quality-grid-panel',\n timestamp: Date.now(),\n payload: isDeselecting ? null : {\n repositoryId: item.repositoryId,\n repositoryName: item.repositoryName,\n packageName: item.packageName,\n tier: item.tier,\n },\n });\n\n // Emit package:select event for cross-panel filtering (e.g., File City)\n // Clicking the same item again deselects (sends null payload)\n events.emit({\n type: 'package:select',\n source: 'principal-ade.repository-quality-grid-panel',\n timestamp: Date.now(),\n payload: isDeselecting ? null : (item.repositoryPath ? {\n packagePath: item.repositoryPath,\n packageName: item.packageName,\n } : null),\n });\n\n setSelectedItemKey(isDeselecting ? null : item.key);\n };\n\n // Handle vertex click\n const handleVertexClick = (item: FlatGridItem, vertex: VertexHoverInfo) => {\n events.emit({\n type: 'principal-ade.repository-quality-grid:vertex:click',\n source: 'principal-ade.repository-quality-grid-panel',\n timestamp: Date.now(),\n payload: {\n repositoryId: item.repositoryId,\n repositoryName: item.repositoryName,\n packageName: item.packageName,\n metric: vertex.key,\n label: vertex.label,\n value: vertex.value,\n },\n });\n };\n\n // Handle refresh\n const handleRefresh = async () => {\n if (context.hasSlice('repositoriesQuality')) {\n await context.refresh('workspace', 'repositoriesQuality');\n }\n };\n\n // Subscribe to events\n React.useEffect(() => {\n const unsubscribers = [\n events.on('principal-ade.repository-quality-grid:refresh', async () => {\n await handleRefresh();\n }),\n ];\n\n return () => unsubscribers.forEach((unsub) => unsub());\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [events, context]);\n\n return (\n <div\n style={{\n fontFamily: theme.fonts.body,\n height: '100%',\n minHeight: 0,\n backgroundColor: theme.colors.background,\n color: theme.colors.text,\n overflowY: 'auto',\n boxSizing: 'border-box',\n }}\n >\n {isLoading ? (\n <div\n style={{\n padding: 40,\n textAlign: 'center',\n color: theme.colors.textMuted,\n }}\n >\n Loading repository quality metrics...\n </div>\n ) : repositories.length === 0 ? (\n <div style={{ padding: 20 }}>\n <QualityEmptyState theme={theme} hasWorkflow={false} />\n </div>\n ) : (\n <RepositoryQualityGrid\n repositories={repositories}\n theme={theme}\n onItemClick={handleItemClick}\n onVertexClick={handleVertexClick}\n showRepositoryName={true}\n showSummary={true}\n />\n )}\n </div>\n );\n};\n\n/**\n * RepositoryQualityGridPanel - A panel for visualizing quality metrics\n * across multiple repositories in a flat grid layout.\n */\nexport const RepositoryQualityGridPanel = RepositoryQualityGridPanelContent;\n","import { QualityHexagonPanel } from './panels/QualityHexagonPanel';\nimport { RepositoryQualityGridPanel } from './panels/RepositoryQualityGridPanel';\nimport type { PanelDefinition, PanelContextValue } from './types';\n\n/**\n * Export array of panel definitions.\n * This is the required export for panel extensions.\n */\nexport const panels: PanelDefinition[] = [\n {\n metadata: {\n id: 'principal-ade.quality-hexagon-panel',\n name: 'Code Quality',\n icon: '⬡',\n version: '0.1.0',\n author: 'Principal ADE',\n description:\n 'Visualize code quality metrics using a hexagonal radar chart showing tests, types, linting, formatting, documentation, and dead code.',\n slices: ['quality'],\n tools: [],\n },\n component: QualityHexagonPanel,\n\n onMount: async (context: PanelContextValue) => {\n console.log(\n 'Quality Hexagon Panel mounted',\n context.currentScope.repository?.path\n );\n\n if (context.hasSlice('quality') && !context.isSliceLoading('quality')) {\n await context.refresh('repository', 'quality');\n }\n },\n\n onUnmount: async (_context: PanelContextValue) => {\n console.log('Quality Hexagon Panel unmounting');\n },\n },\n {\n metadata: {\n id: 'principal-ade.repository-quality-grid-panel',\n name: 'Repository Quality Grid',\n icon: '⬡',\n version: '0.1.0',\n author: 'Principal ADE',\n description:\n 'Display quality metrics for multiple repositories in a flat grid layout. Supports filtering by metric type, sorting, and comparing quality across projects.',\n slices: ['repositoriesQuality'],\n tools: [],\n },\n component: RepositoryQualityGridPanel,\n\n onMount: async (context: PanelContextValue) => {\n console.log('Repository Quality Grid Panel mounted');\n\n if (context.hasSlice('repositoriesQuality') && !context.isSliceLoading('repositoriesQuality')) {\n await context.refresh('workspace', 'repositoriesQuality');\n }\n },\n\n onUnmount: async (_context: PanelContextValue) => {\n console.log('Repository Quality Grid Panel unmounting');\n },\n },\n];\n\n/**\n * Optional: Called once when the entire package is loaded.\n */\nexport const onPackageLoad = async () => {\n console.log('Panel package loaded - Code Quality Panels');\n};\n\n/**\n * Optional: Called once when the package is unloaded.\n */\nexport const onPackageUnload = async () => {\n console.log('Panel package unloading - Code Quality Panels');\n};\n\n// Export components for direct usage\nexport {\n QualityHexagon,\n QualityHexagonCompact,\n QualityHexagonDetailed,\n QualityHexagonExpandable,\n calculateQualityTier,\n type QualityMetrics,\n type QualityTier,\n // Multi-repository grid components\n RepositoryQualityGrid,\n RepositoryQualityGridItem,\n type RepositoryQualityItem,\n type PackageQualityItem,\n type FlatGridItem,\n} from './components';\n\n// Export panels\nexport { QualityHexagonPanel } from './panels/QualityHexagonPanel';\nexport { RepositoryQualityGridPanel } from './panels/RepositoryQualityGridPanel';\n"],"names":["__iconNode","React","_a"],"mappings":";;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOA,MAAM,cAAc,CAAC,WAAW,OAAO,QAAQ,sBAAsB,OAAO,EAAE,YAAW;AACzF,MAAM,cAAc,CAAC,WAAW,OAAO;AAAA,EACrC;AAAA,EACA,CAAC,OAAO,IAAI,OAAO,KAAK,GAAG,YAAW,IAAK,GAAG,YAAW;AAC3D;AACA,MAAM,eAAe,CAAC,WAAW;AAC/B,QAAM,YAAY,YAAY,MAAM;AACpC,SAAO,UAAU,OAAO,CAAC,EAAE,YAAW,IAAK,UAAU,MAAM,CAAC;AAC9D;AACA,MAAM,eAAe,IAAI,YAAY,QAAQ,OAAO,CAAC,WAAW,OAAO,UAAU;AAC/E,SAAO,QAAQ,SAAS,KAAK,UAAU,KAAI,MAAO,MAAM,MAAM,QAAQ,SAAS,MAAM;AACvF,CAAC,EAAE,KAAK,GAAG,EAAE,KAAI;AACjB,MAAM,cAAc,CAAC,UAAU;AAC7B,aAAW,QAAQ,OAAO;AACxB,QAAI,KAAK,WAAW,OAAO,KAAK,SAAS,UAAU,SAAS,SAAS;AACnE,aAAO;AAAA,IACT;AAAA,EACF;AACF;ACzBA;AAAA;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ignoreList":[0,1,2,3,4,5,6,7,8,9,10,11,12,13]}
1
+ {"version":3,"file":"panels.bundle.js","sources":["../node_modules/lucide-react/dist/esm/shared/src/utils.js","../node_modules/lucide-react/dist/esm/defaultAttributes.js","../node_modules/lucide-react/dist/esm/Icon.js","../node_modules/lucide-react/dist/esm/createLucideIcon.js","../node_modules/lucide-react/dist/esm/icons/check.js","../node_modules/lucide-react/dist/esm/icons/chevron-right.js","../node_modules/lucide-react/dist/esm/icons/copy.js","../node_modules/lucide-react/dist/esm/icons/git-branch.js","../node_modules/lucide-react/dist/esm/icons/hexagon.js","../node_modules/lucide-react/dist/esm/icons/info.js","../node_modules/lucide-react/dist/esm/icons/terminal.js","../node_modules/lucide-react/dist/esm/icons/zap.js","../node_modules/@principal-ade/industry-theme/dist/esm/index.js","../node_modules/clsx/dist/clsx.mjs","../src/lib/utils.ts","../src/components/QualityHexagon.tsx","../src/components/QualityEmptyState.tsx","../src/panels/QualityHexagonPanel.tsx","../src/components/RepositoryQualityGrid.tsx","../src/panels/RepositoryQualityGridPanel.tsx","../src/index.tsx"],"sourcesContent":["/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nconst toKebabCase = (string) => string.replace(/([a-z0-9])([A-Z])/g, \"$1-$2\").toLowerCase();\nconst toCamelCase = (string) => string.replace(\n /^([A-Z])|[\\s-_]+(\\w)/g,\n (match, p1, p2) => p2 ? p2.toUpperCase() : p1.toLowerCase()\n);\nconst toPascalCase = (string) => {\n const camelCase = toCamelCase(string);\n return camelCase.charAt(0).toUpperCase() + camelCase.slice(1);\n};\nconst mergeClasses = (...classes) => classes.filter((className, index, array) => {\n return Boolean(className) && className.trim() !== \"\" && array.indexOf(className) === index;\n}).join(\" \").trim();\nconst hasA11yProp = (props) => {\n for (const prop in props) {\n if (prop.startsWith(\"aria-\") || prop === \"role\" || prop === \"title\") {\n return true;\n }\n }\n};\n\nexport { hasA11yProp, mergeClasses, toCamelCase, toKebabCase, toPascalCase };\n//# sourceMappingURL=utils.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nvar defaultAttributes = {\n xmlns: \"http://www.w3.org/2000/svg\",\n width: 24,\n height: 24,\n viewBox: \"0 0 24 24\",\n fill: \"none\",\n stroke: \"currentColor\",\n strokeWidth: 2,\n strokeLinecap: \"round\",\n strokeLinejoin: \"round\"\n};\n\nexport { defaultAttributes as default };\n//# sourceMappingURL=defaultAttributes.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport { forwardRef, createElement } from 'react';\nimport defaultAttributes from './defaultAttributes.js';\nimport { mergeClasses, hasA11yProp } from './shared/src/utils.js';\n\nconst Icon = forwardRef(\n ({\n color = \"currentColor\",\n size = 24,\n strokeWidth = 2,\n absoluteStrokeWidth,\n className = \"\",\n children,\n iconNode,\n ...rest\n }, ref) => createElement(\n \"svg\",\n {\n ref,\n ...defaultAttributes,\n width: size,\n height: size,\n stroke: color,\n strokeWidth: absoluteStrokeWidth ? Number(strokeWidth) * 24 / Number(size) : strokeWidth,\n className: mergeClasses(\"lucide\", className),\n ...!children && !hasA11yProp(rest) && { \"aria-hidden\": \"true\" },\n ...rest\n },\n [\n ...iconNode.map(([tag, attrs]) => createElement(tag, attrs)),\n ...Array.isArray(children) ? children : [children]\n ]\n )\n);\n\nexport { Icon as default };\n//# sourceMappingURL=Icon.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport { forwardRef, createElement } from 'react';\nimport { mergeClasses, toKebabCase, toPascalCase } from './shared/src/utils.js';\nimport Icon from './Icon.js';\n\nconst createLucideIcon = (iconName, iconNode) => {\n const Component = forwardRef(\n ({ className, ...props }, ref) => createElement(Icon, {\n ref,\n iconNode,\n className: mergeClasses(\n `lucide-${toKebabCase(toPascalCase(iconName))}`,\n `lucide-${iconName}`,\n className\n ),\n ...props\n })\n );\n Component.displayName = toPascalCase(iconName);\n return Component;\n};\n\nexport { createLucideIcon as default };\n//# sourceMappingURL=createLucideIcon.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [[\"path\", { d: \"M20 6 9 17l-5-5\", key: \"1gmf2c\" }]];\nconst Check = createLucideIcon(\"check\", __iconNode);\n\nexport { __iconNode, Check as default };\n//# sourceMappingURL=check.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [[\"path\", { d: \"m9 18 6-6-6-6\", key: \"mthhwq\" }]];\nconst ChevronRight = createLucideIcon(\"chevron-right\", __iconNode);\n\nexport { __iconNode, ChevronRight as default };\n//# sourceMappingURL=chevron-right.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\"rect\", { width: \"14\", height: \"14\", x: \"8\", y: \"8\", rx: \"2\", ry: \"2\", key: \"17jyea\" }],\n [\"path\", { d: \"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2\", key: \"zix9uf\" }]\n];\nconst Copy = createLucideIcon(\"copy\", __iconNode);\n\nexport { __iconNode, Copy as default };\n//# sourceMappingURL=copy.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\"line\", { x1: \"6\", x2: \"6\", y1: \"3\", y2: \"15\", key: \"17qcm7\" }],\n [\"circle\", { cx: \"18\", cy: \"6\", r: \"3\", key: \"1h7g24\" }],\n [\"circle\", { cx: \"6\", cy: \"18\", r: \"3\", key: \"fqmcym\" }],\n [\"path\", { d: \"M18 9a9 9 0 0 1-9 9\", key: \"n2h4wq\" }]\n];\nconst GitBranch = createLucideIcon(\"git-branch\", __iconNode);\n\nexport { __iconNode, GitBranch as default };\n//# sourceMappingURL=git-branch.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\n \"path\",\n {\n d: \"M21 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.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16z\",\n key: \"yt0hxn\"\n }\n ]\n];\nconst Hexagon = createLucideIcon(\"hexagon\", __iconNode);\n\nexport { __iconNode, Hexagon as default };\n//# sourceMappingURL=hexagon.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\"circle\", { cx: \"12\", cy: \"12\", r: \"10\", key: \"1mglay\" }],\n [\"path\", { d: \"M12 16v-4\", key: \"1dtifu\" }],\n [\"path\", { d: \"M12 8h.01\", key: \"e9boi3\" }]\n];\nconst Info = createLucideIcon(\"info\", __iconNode);\n\nexport { __iconNode, Info as default };\n//# sourceMappingURL=info.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\"path\", { d: \"M12 19h8\", key: \"baeox8\" }],\n [\"path\", { d: \"m4 17 6-6-6-6\", key: \"1yngyt\" }]\n];\nconst Terminal = createLucideIcon(\"terminal\", __iconNode);\n\nexport { __iconNode, Terminal as default };\n//# sourceMappingURL=terminal.js.map\n","/**\n * @license lucide-react v0.552.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n [\n \"path\",\n {\n d: \"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z\",\n key: \"1xq2db\"\n }\n ]\n];\nconst Zap = createLucideIcon(\"zap\", __iconNode);\n\nexport { __iconNode, Zap as default };\n//# sourceMappingURL=zap.js.map\n","// src/glassmorphismTheme.ts\nvar glassmorphismTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n heading: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n monospace: '\"Fira Code\", \"SF Mono\", Monaco, Inconsolata, monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 600,\n bold: 700,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.6,\n heading: 1.3,\n tight: 1.4,\n relaxed: 1.8\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 8, 12, 16, 20, 24, 32, 40],\n shadows: [\n \"none\",\n \"0 8px 32px 0 rgba(31, 38, 135, 0.15)\",\n \"0 12px 40px 0 rgba(31, 38, 135, 0.2)\",\n \"0 16px 48px 0 rgba(31, 38, 135, 0.25)\",\n \"0 20px 56px 0 rgba(31, 38, 135, 0.3)\",\n \"0 24px 64px 0 rgba(31, 38, 135, 0.35)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"rgba(255, 255, 255, 0.95)\",\n background: \"rgba(255, 255, 255, 0.1)\",\n primary: \"rgba(99, 102, 241, 0.9)\",\n secondary: \"rgba(139, 92, 246, 0.9)\",\n accent: \"rgba(236, 72, 153, 0.9)\",\n highlight: \"rgba(99, 102, 241, 0.2)\",\n muted: \"rgba(255, 255, 255, 0.05)\",\n success: \"rgba(34, 197, 94, 0.9)\",\n warning: \"rgba(251, 146, 60, 0.9)\",\n error: \"rgba(239, 68, 68, 0.9)\",\n info: \"rgba(59, 130, 246, 0.9)\",\n border: \"rgba(255, 255, 255, 0.18)\",\n backgroundSecondary: \"rgba(255, 255, 255, 0.15)\",\n backgroundTertiary: \"rgba(255, 255, 255, 0.2)\",\n backgroundLight: \"rgba(255, 255, 255, 0.08)\",\n backgroundHover: \"rgba(255, 255, 255, 0.25)\",\n surface: \"rgba(255, 255, 255, 0.12)\",\n textSecondary: \"rgba(255, 255, 255, 0.8)\",\n textTertiary: \"rgba(255, 255, 255, 0.6)\",\n textMuted: \"rgba(255, 255, 255, 0.5)\",\n highlightBg: \"rgba(251, 191, 36, 0.3)\",\n highlightBorder: \"rgba(251, 191, 36, 0.5)\"\n },\n modes: {\n dark: {\n text: \"rgba(255, 255, 255, 0.95)\",\n background: \"rgba(0, 0, 0, 0.3)\",\n primary: \"rgba(129, 140, 248, 0.9)\",\n secondary: \"rgba(167, 139, 250, 0.9)\",\n accent: \"rgba(244, 114, 182, 0.9)\",\n highlight: \"rgba(129, 140, 248, 0.25)\",\n muted: \"rgba(0, 0, 0, 0.15)\",\n success: \"rgba(74, 222, 128, 0.9)\",\n warning: \"rgba(251, 191, 36, 0.9)\",\n error: \"rgba(248, 113, 113, 0.9)\",\n info: \"rgba(96, 165, 250, 0.9)\",\n border: \"rgba(255, 255, 255, 0.15)\",\n backgroundSecondary: \"rgba(0, 0, 0, 0.4)\",\n backgroundTertiary: \"rgba(0, 0, 0, 0.5)\",\n backgroundLight: \"rgba(0, 0, 0, 0.2)\",\n backgroundHover: \"rgba(255, 255, 255, 0.1)\",\n surface: \"rgba(0, 0, 0, 0.35)\",\n textSecondary: \"rgba(255, 255, 255, 0.8)\",\n textTertiary: \"rgba(255, 255, 255, 0.6)\",\n textMuted: \"rgba(255, 255, 255, 0.4)\",\n highlightBg: \"rgba(251, 191, 36, 0.35)\",\n highlightBorder: \"rgba(251, 191, 36, 0.6)\"\n },\n frosted: {\n text: \"rgba(31, 41, 55, 0.95)\",\n background: \"rgba(255, 255, 255, 0.3)\",\n primary: \"rgba(79, 70, 229, 0.95)\",\n secondary: \"rgba(124, 58, 237, 0.95)\",\n accent: \"rgba(219, 39, 119, 0.95)\",\n highlight: \"rgba(79, 70, 229, 0.15)\",\n muted: \"rgba(255, 255, 255, 0.4)\",\n success: \"rgba(16, 185, 129, 0.95)\",\n warning: \"rgba(245, 158, 11, 0.95)\",\n error: \"rgba(220, 38, 38, 0.95)\",\n info: \"rgba(37, 99, 235, 0.95)\",\n border: \"rgba(255, 255, 255, 0.5)\",\n backgroundSecondary: \"rgba(255, 255, 255, 0.4)\",\n backgroundTertiary: \"rgba(255, 255, 255, 0.5)\",\n backgroundLight: \"rgba(255, 255, 255, 0.25)\",\n backgroundHover: \"rgba(255, 255, 255, 0.6)\",\n surface: \"rgba(255, 255, 255, 0.35)\",\n textSecondary: \"rgba(31, 41, 55, 0.8)\",\n textTertiary: \"rgba(31, 41, 55, 0.6)\",\n textMuted: \"rgba(31, 41, 55, 0.5)\",\n highlightBg: \"rgba(251, 191, 36, 0.4)\",\n highlightBorder: \"rgba(251, 191, 36, 0.7)\"\n }\n },\n buttons: {\n primary: {\n color: \"white\",\n bg: \"primary\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"rgba(255, 255, 255, 0.2)\",\n \"&:hover\": {\n bg: \"secondary\"\n }\n },\n secondary: {\n color: \"text\",\n bg: \"rgba(255, 255, 255, 0.1)\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"rgba(255, 255, 255, 0.2)\",\n \"&:hover\": {\n bg: \"rgba(255, 255, 255, 0.2)\"\n }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"transparent\",\n \"&:hover\": {\n borderColor: \"rgba(255, 255, 255, 0.2)\",\n bg: \"rgba(255, 255, 255, 0.05)\"\n }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 3\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 3\n }\n }\n};\n// src/defaultThemes.ts\nvar defaultMarkdownTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n heading: '\"Crimson Text\", \"Georgia\", \"Times New Roman\", serif',\n monospace: '\"Fira Code\", \"SF Mono\", Monaco, Inconsolata, monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 600,\n bold: 700,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.6,\n heading: 1.3,\n tight: 1.25,\n relaxed: 1.75\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06)\",\n \"0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06)\",\n \"0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05)\",\n \"0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04)\",\n \"0 25px 50px -12px rgba(0, 0, 0, 0.25)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#1a1a1a\",\n background: \"#ffffff\",\n primary: \"#007acc\",\n secondary: \"#005a9e\",\n accent: \"#1a1a1a\",\n highlight: \"rgba(0, 122, 204, 0.1)\",\n muted: \"#f0f0f0\",\n success: \"#28a745\",\n warning: \"#ffc107\",\n error: \"#dc3545\",\n info: \"#17a2b8\",\n border: \"rgba(0, 0, 0, 0.1)\",\n backgroundSecondary: \"#f8f9fa\",\n backgroundTertiary: \"#e9ecef\",\n backgroundLight: \"rgba(0, 0, 0, 0.03)\",\n backgroundHover: \"rgba(0, 0, 0, 0.05)\",\n surface: \"#ffffff\",\n textSecondary: \"#555555\",\n textTertiary: \"#888888\",\n textMuted: \"#aaaaaa\",\n highlightBg: \"rgba(255, 235, 59, 0.3)\",\n highlightBorder: \"rgba(255, 235, 59, 0.6)\"\n },\n buttons: {\n primary: {\n color: \"white\",\n bg: \"primary\",\n \"&:hover\": { bg: \"secondary\" }\n },\n secondary: {\n color: \"primary\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"primary\",\n \"&:hover\": { bg: \"highlight\" }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n \"&:hover\": { bg: \"backgroundHover\" }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 2\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 2\n }\n }\n};\nvar defaultTerminalTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Courier New\", Courier, monospace',\n heading: '\"Courier New\", Courier, monospace',\n monospace: '\"Courier New\", Courier, monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 500,\n bold: 600,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.4,\n heading: 1.2,\n tight: 1.3,\n relaxed: 1.6\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 0 5px rgba(255, 193, 7, 0.1)\",\n \"0 0 10px rgba(255, 193, 7, 0.15)\",\n \"0 0 15px rgba(255, 193, 7, 0.2)\",\n \"0 0 20px rgba(255, 193, 7, 0.25)\",\n \"0 0 30px rgba(255, 193, 7, 0.3)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#ffc107\",\n background: \"#000000\",\n primary: \"#ffc107\",\n secondary: \"#ffb300\",\n accent: \"#ffffff\",\n highlight: \"rgba(255, 193, 7, 0.1)\",\n muted: \"#1a1a1a\",\n success: \"#4caf50\",\n warning: \"#ff9800\",\n error: \"#f44336\",\n info: \"#2196f3\",\n border: \"rgba(255, 193, 7, 0.2)\",\n backgroundSecondary: \"#0a0a0a\",\n backgroundTertiary: \"#111111\",\n backgroundLight: \"rgba(255, 193, 7, 0.03)\",\n backgroundHover: \"rgba(255, 193, 7, 0.05)\",\n surface: \"#050505\",\n textSecondary: \"#e0e0e0\",\n textTertiary: \"#b0b0b0\",\n textMuted: \"#808080\",\n highlightBg: \"rgba(255, 193, 7, 0.2)\",\n highlightBorder: \"rgba(255, 193, 7, 0.4)\"\n },\n buttons: {\n primary: {\n color: \"black\",\n bg: \"primary\",\n borderWidth: 0,\n \"&:hover\": { bg: \"secondary\" }\n },\n secondary: {\n color: \"primary\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"primary\",\n \"&:hover\": { bg: \"highlight\" }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n \"&:hover\": { bg: \"backgroundHover\" }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 0\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 0\n }\n }\n};\nvar defaultEditorTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Fira Code\", \"SF Mono\", Monaco, Inconsolata, monospace',\n heading: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n monospace: '\"Fira Code\", \"SF Mono\", Monaco, Inconsolata, monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 600,\n bold: 700,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.5,\n heading: 1.2,\n tight: 1.3,\n relaxed: 1.7\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 1px 2px rgba(0, 0, 0, 0.05)\",\n \"0 2px 4px rgba(0, 0, 0, 0.1)\",\n \"0 4px 8px rgba(0, 0, 0, 0.15)\",\n \"0 8px 16px rgba(0, 0, 0, 0.2)\",\n \"0 12px 24px rgba(0, 0, 0, 0.25)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#d4d4d4\",\n background: \"#1e1e1e\",\n primary: \"#569cd6\",\n secondary: \"#408ac9\",\n accent: \"#c586c0\",\n highlight: \"rgba(86, 156, 214, 0.1)\",\n muted: \"#2a2a2a\",\n success: \"#6a9955\",\n warning: \"#d18616\",\n error: \"#f44747\",\n info: \"#569cd6\",\n border: \"rgba(255, 255, 255, 0.1)\",\n backgroundSecondary: \"#252526\",\n backgroundTertiary: \"#333333\",\n backgroundLight: \"rgba(255, 255, 255, 0.03)\",\n backgroundHover: \"rgba(255, 255, 255, 0.05)\",\n surface: \"#252526\",\n textSecondary: \"#cccccc\",\n textTertiary: \"#999999\",\n textMuted: \"#666666\",\n highlightBg: \"rgba(255, 235, 59, 0.2)\",\n highlightBorder: \"rgba(255, 235, 59, 0.4)\"\n },\n buttons: {\n primary: {\n color: \"white\",\n bg: \"primary\",\n \"&:hover\": { bg: \"secondary\" }\n },\n secondary: {\n color: \"primary\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"primary\",\n \"&:hover\": { bg: \"highlight\" }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n \"&:hover\": { bg: \"backgroundHover\" }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 1\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 1\n }\n }\n};\n\n// src/themes.ts\nvar regalTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n heading: '\"Crimson Text\", \"Georgia\", \"Times New Roman\", serif',\n monospace: '\"Fira Code\", \"SF Mono\", Monaco, Inconsolata, monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 600,\n bold: 700,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.5,\n heading: 1.2,\n tight: 1.25,\n relaxed: 1.75\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06)\",\n \"0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06)\",\n \"0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05)\",\n \"0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04)\",\n \"0 25px 50px -12px rgba(0, 0, 0, 0.25)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#f1e8dc\",\n background: \"#1a1f2e\",\n primary: \"#d4a574\",\n secondary: \"#e0b584\",\n accent: \"#c9b8a3\",\n highlight: \"rgba(212, 165, 116, 0.15)\",\n muted: \"#8b7968\",\n success: \"#5c8a72\",\n warning: \"#d4a574\",\n error: \"#a85751\",\n info: \"#d4a574\",\n border: \"rgba(212, 165, 116, 0.2)\",\n backgroundSecondary: \"#212738\",\n backgroundTertiary: \"#2d3446\",\n backgroundLight: \"rgba(212, 165, 116, 0.08)\",\n backgroundHover: \"rgba(212, 165, 116, 0.15)\",\n surface: \"#212738\",\n textSecondary: \"#c9b8a3\",\n textTertiary: \"#8b7968\",\n textMuted: \"#8b7968\",\n highlightBg: \"rgba(255, 193, 7, 0.25)\",\n highlightBorder: \"rgba(255, 193, 7, 0.5)\"\n },\n buttons: {\n primary: {\n color: \"background\",\n bg: \"primary\",\n \"&:hover\": {\n bg: \"secondary\"\n }\n },\n secondary: {\n color: \"text\",\n bg: \"muted\",\n \"&:hover\": {\n bg: \"backgroundSecondary\"\n }\n },\n ghost: {\n color: \"primary\",\n bg: \"transparent\",\n \"&:hover\": {\n bg: \"muted\"\n }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"background\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 2\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 2\n }\n }\n};\nvar terminalTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"SF Mono\", \"Monaco\", \"Inconsolata\", \"Fira Code\", monospace',\n heading: '\"SF Mono\", \"Monaco\", \"Inconsolata\", \"Fira Code\", monospace',\n monospace: '\"SF Mono\", \"Monaco\", \"Inconsolata\", \"Fira Code\", monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 500,\n bold: 600,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.6,\n heading: 1.3,\n tight: 1.4,\n relaxed: 1.8\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 1px 2px 0 rgba(0, 0, 0, 0.05)\",\n \"0 2px 4px 0 rgba(0, 0, 0, 0.06)\",\n \"0 4px 6px 0 rgba(0, 0, 0, 0.07)\",\n \"0 8px 12px 0 rgba(0, 0, 0, 0.08)\",\n \"0 16px 24px 0 rgba(0, 0, 0, 0.10)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#e4e4e4\",\n background: \"rgba(10, 10, 10, 0.85)\",\n primary: \"#66b3ff\",\n secondary: \"#80c4ff\",\n accent: \"#66ff99\",\n highlight: \"rgba(102, 179, 255, 0.15)\",\n muted: \"rgba(26, 26, 26, 0.8)\",\n success: \"#66ff99\",\n warning: \"#ffcc66\",\n error: \"#ff6666\",\n info: \"#66b3ff\",\n border: \"rgba(255, 255, 255, 0.1)\",\n backgroundSecondary: \"rgba(15, 15, 15, 0.9)\",\n backgroundTertiary: \"rgba(20, 20, 20, 0.9)\",\n backgroundLight: \"rgba(255, 255, 255, 0.05)\",\n backgroundHover: \"rgba(102, 179, 255, 0.08)\",\n surface: \"rgba(15, 15, 15, 0.95)\",\n textSecondary: \"rgba(255, 255, 255, 0.7)\",\n textTertiary: \"rgba(255, 255, 255, 0.5)\",\n textMuted: \"rgba(255, 255, 255, 0.4)\",\n highlightBg: \"rgba(255, 235, 59, 0.25)\",\n highlightBorder: \"rgba(255, 235, 59, 0.5)\"\n },\n modes: {\n light: {\n text: \"#1a1a1a\",\n background: \"rgba(255, 255, 255, 0.9)\",\n primary: \"#0066cc\",\n secondary: \"#0052a3\",\n accent: \"#00cc88\",\n highlight: \"rgba(0, 102, 204, 0.08)\",\n muted: \"rgba(245, 245, 245, 0.8)\",\n success: \"#00cc88\",\n warning: \"#ffaa00\",\n error: \"#ff3333\",\n info: \"#0066cc\",\n border: \"rgba(0, 0, 0, 0.1)\",\n backgroundSecondary: \"rgba(250, 250, 250, 0.9)\",\n backgroundTertiary: \"rgba(245, 245, 245, 0.9)\",\n backgroundLight: \"rgba(0, 0, 0, 0.02)\",\n backgroundHover: \"rgba(0, 102, 204, 0.04)\",\n surface: \"rgba(255, 255, 255, 0.95)\",\n textSecondary: \"rgba(0, 0, 0, 0.6)\",\n textTertiary: \"rgba(0, 0, 0, 0.4)\",\n textMuted: \"rgba(0, 0, 0, 0.3)\",\n highlightBg: \"rgba(255, 235, 59, 0.3)\",\n highlightBorder: \"rgba(255, 235, 59, 0.6)\"\n }\n },\n buttons: {\n primary: {\n color: \"white\",\n bg: \"primary\",\n borderWidth: 0,\n \"&:hover\": {\n bg: \"secondary\"\n }\n },\n secondary: {\n color: \"primary\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"primary\",\n \"&:hover\": {\n bg: \"highlight\"\n }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n \"&:hover\": {\n bg: \"backgroundHover\"\n }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 1\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 1\n }\n }\n};\nvar matrixTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Courier New\", \"Courier\", \"Lucida Console\", \"Monaco\", monospace',\n heading: '\"Courier New\", \"Courier\", \"Lucida Console\", \"Monaco\", monospace',\n monospace: '\"Courier New\", \"Courier\", \"Lucida Console\", \"Monaco\", monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 500,\n bold: 600,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.5,\n heading: 1.2,\n tight: 1.3,\n relaxed: 1.7\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 0 5px rgba(0, 216, 53, 0.15)\",\n \"0 0 10px rgba(0, 216, 53, 0.2)\",\n \"0 0 15px rgba(0, 216, 53, 0.25)\",\n \"0 0 20px rgba(0, 216, 53, 0.3)\",\n \"0 0 30px rgba(0, 216, 53, 0.4)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#a8a8a8\",\n background: \"#000000\",\n primary: \"#00d835\",\n secondary: \"#00a828\",\n accent: \"#00d835\",\n highlight: \"rgba(0, 216, 53, 0.15)\",\n muted: \"#0a0a0a\",\n success: \"#00d835\",\n warning: \"#d4a000\",\n error: \"#d63333\",\n info: \"#00a8d6\",\n border: \"rgba(0, 216, 53, 0.2)\",\n backgroundSecondary: \"#0a0a0a\",\n backgroundTertiary: \"#111111\",\n backgroundLight: \"rgba(0, 216, 53, 0.03)\",\n backgroundHover: \"rgba(0, 216, 53, 0.08)\",\n surface: \"#050505\",\n textSecondary: \"#808080\",\n textTertiary: \"#606060\",\n textMuted: \"#484848\",\n highlightBg: \"rgba(0, 216, 53, 0.25)\",\n highlightBorder: \"rgba(0, 216, 53, 0.5)\"\n },\n buttons: {\n primary: {\n color: \"black\",\n bg: \"primary\",\n borderWidth: 0,\n \"&:hover\": {\n bg: \"secondary\"\n }\n },\n secondary: {\n color: \"primary\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"primary\",\n \"&:hover\": {\n bg: \"highlight\"\n }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n \"&:hover\": {\n bg: \"backgroundHover\"\n }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 0\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 0\n }\n }\n};\nvar matrixMinimalTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Courier New\", \"Courier\", \"Lucida Console\", \"Monaco\", monospace',\n heading: '\"Courier New\", \"Courier\", \"Lucida Console\", \"Monaco\", monospace',\n monospace: '\"Courier New\", \"Courier\", \"Lucida Console\", \"Monaco\", monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 500,\n bold: 600,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.5,\n heading: 1.2,\n tight: 1.3,\n relaxed: 1.7\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 1px 2px rgba(0, 0, 0, 0.05)\",\n \"0 2px 4px rgba(0, 0, 0, 0.1)\",\n \"0 4px 8px rgba(0, 0, 0, 0.15)\",\n \"0 8px 16px rgba(0, 0, 0, 0.2)\",\n \"0 0 20px rgba(0, 216, 53, 0.1)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#a8a8a8\",\n background: \"#000000\",\n primary: \"#b8b8b8\",\n secondary: \"#909090\",\n accent: \"#00d835\",\n highlight: \"rgba(0, 216, 53, 0.1)\",\n muted: \"#0a0a0a\",\n success: \"#00d835\",\n warning: \"#d4a000\",\n error: \"#d63333\",\n info: \"#00a8d6\",\n border: \"rgba(184, 184, 184, 0.1)\",\n backgroundSecondary: \"#0a0a0a\",\n backgroundTertiary: \"#111111\",\n backgroundLight: \"rgba(184, 184, 184, 0.02)\",\n backgroundHover: \"rgba(0, 216, 53, 0.05)\",\n surface: \"#050505\",\n textSecondary: \"#808080\",\n textTertiary: \"#606060\",\n textMuted: \"#484848\",\n highlightBg: \"rgba(0, 216, 53, 0.2)\",\n highlightBorder: \"rgba(0, 216, 53, 0.4)\"\n },\n buttons: {\n primary: {\n color: \"black\",\n bg: \"primary\",\n borderWidth: 0,\n \"&:hover\": {\n bg: \"secondary\"\n }\n },\n secondary: {\n color: \"primary\",\n bg: \"transparent\",\n borderWidth: 1,\n borderStyle: \"solid\",\n borderColor: \"primary\",\n \"&:hover\": {\n bg: \"backgroundHover\"\n }\n },\n ghost: {\n color: \"text\",\n bg: \"transparent\",\n \"&:hover\": {\n bg: \"backgroundHover\"\n }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textSecondary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 0\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 0\n }\n }\n};\nvar slateTheme = {\n space: [0, 4, 8, 16, 32, 64, 128, 256, 512],\n fonts: {\n body: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n heading: '\"Inter\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, sans-serif',\n monospace: '\"Fira Code\", \"SF Mono\", Monaco, Inconsolata, monospace'\n },\n fontSizes: [12, 14, 16, 18, 20, 24, 32, 48, 64, 96],\n fontScale: 1,\n fontWeights: {\n body: 400,\n heading: 600,\n bold: 700,\n light: 300,\n medium: 500,\n semibold: 600\n },\n lineHeights: {\n body: 1.6,\n heading: 1.3,\n tight: 1.25,\n relaxed: 1.75\n },\n breakpoints: [\"640px\", \"768px\", \"1024px\", \"1280px\"],\n sizes: [16, 32, 64, 128, 256, 512, 768, 1024, 1536],\n radii: [0, 2, 4, 6, 8, 12, 16, 24],\n shadows: [\n \"none\",\n \"0 1px 3px 0 rgba(0, 0, 0, 0.2)\",\n \"0 4px 6px -1px rgba(0, 0, 0, 0.2)\",\n \"0 10px 15px -3px rgba(0, 0, 0, 0.2)\",\n \"0 20px 25px -5px rgba(0, 0, 0, 0.25)\",\n \"0 25px 50px -12px rgba(0, 0, 0, 0.3)\"\n ],\n zIndices: [0, 1, 10, 20, 30, 40, 50],\n colors: {\n text: \"#9ca3af\",\n background: \"#1a1c1e\",\n primary: \"#d1d5db\",\n secondary: \"#6b7280\",\n accent: \"#f59e0b\",\n highlight: \"rgba(209, 213, 219, 0.15)\",\n muted: \"#2d3134\",\n success: \"#10b981\",\n warning: \"#f59e0b\",\n error: \"#ef4444\",\n info: \"#3b82f6\",\n border: \"rgba(156, 163, 175, 0.15)\",\n backgroundSecondary: \"#22252a\",\n backgroundTertiary: \"#2d3134\",\n backgroundLight: \"rgba(156, 163, 175, 0.05)\",\n backgroundHover: \"rgba(156, 163, 175, 0.1)\",\n surface: \"#1f2124\",\n textSecondary: \"#e5e7eb\",\n textTertiary: \"#6b7280\",\n textMuted: \"#4b5563\",\n highlightBg: \"rgba(245, 158, 11, 0.25)\",\n highlightBorder: \"rgba(245, 158, 11, 0.5)\"\n },\n buttons: {\n primary: {\n color: \"#1a1c1e\",\n bg: \"primary\",\n borderWidth: 0,\n \"&:hover\": {\n bg: \"#9ca3af\"\n }\n },\n secondary: {\n color: \"#e5e7eb\",\n bg: \"secondary\",\n borderWidth: 0,\n \"&:hover\": {\n bg: \"#4b5563\"\n }\n },\n ghost: {\n color: \"textSecondary\",\n bg: \"transparent\",\n \"&:hover\": {\n bg: \"backgroundHover\"\n }\n }\n },\n text: {\n heading: {\n fontFamily: \"heading\",\n fontWeight: \"heading\",\n lineHeight: \"heading\",\n color: \"textSecondary\"\n },\n body: {\n fontFamily: \"body\",\n fontWeight: \"body\",\n lineHeight: \"body\"\n },\n caption: {\n fontSize: 1,\n color: \"textTertiary\"\n }\n },\n cards: {\n primary: {\n bg: \"surface\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 3\n },\n secondary: {\n bg: \"backgroundSecondary\",\n border: \"1px solid\",\n borderColor: \"border\",\n borderRadius: 3\n }\n }\n};\n// src/ThemeProvider.tsx\nimport React, { createContext, useContext, useState, useEffect } from \"react\";\n\n// src/themeHelpers.ts\nfunction overrideColors(theme, colors) {\n return {\n ...theme,\n colors: {\n ...theme.colors,\n ...colors\n }\n };\n}\nfunction makeTheme(baseTheme, overrides) {\n return {\n ...baseTheme,\n ...overrides,\n colors: {\n ...baseTheme.colors,\n ...overrides.colors\n },\n fonts: {\n ...baseTheme.fonts,\n ...overrides.fonts\n }\n };\n}\nfunction addMode(theme, modeName, colors, baseMode) {\n let baseColors;\n if (baseMode && theme.modes && theme.modes[baseMode]) {\n baseColors = {\n ...theme.colors,\n ...theme.modes[baseMode]\n };\n } else {\n baseColors = theme.colors;\n }\n const newMode = {\n ...baseColors,\n ...colors\n };\n return {\n ...theme,\n modes: {\n ...theme.modes,\n [modeName]: newMode\n }\n };\n}\nfunction getMode(theme, mode) {\n if (!mode || !theme.modes || !theme.modes[mode]) {\n return theme.colors;\n }\n return {\n ...theme.colors,\n ...theme.modes[mode]\n };\n}\n\n// src/ThemeProvider.tsx\nvar ThemeContext;\nvar getThemeContext = () => {\n if (typeof window !== \"undefined\") {\n const globalWindow = window;\n if (!globalWindow.__principlemd_theme_context__) {\n globalWindow.__principlemd_theme_context__ = createContext(undefined);\n }\n return globalWindow.__principlemd_theme_context__;\n } else {\n if (!ThemeContext) {\n ThemeContext = createContext(undefined);\n }\n return ThemeContext;\n }\n};\nvar ThemeContextSingleton = getThemeContext();\nvar useTheme = () => {\n const context = useContext(ThemeContextSingleton);\n if (!context) {\n throw new Error(\"useTheme must be used within a ThemeProvider\");\n }\n return context;\n};\nvar ThemeProvider = ({\n children,\n theme: customTheme = theme,\n initialMode\n}) => {\n const [mode, setMode] = useState(initialMode);\n const activeTheme = React.useMemo(() => {\n if (!mode || !customTheme.modes || !customTheme.modes[mode]) {\n return customTheme;\n }\n return {\n ...customTheme,\n colors: getMode(customTheme, mode)\n };\n }, [customTheme, mode]);\n useEffect(() => {\n if (!initialMode) {\n const savedMode = localStorage.getItem(\"principlemd-theme-mode\");\n if (savedMode) {\n setMode(savedMode);\n }\n }\n }, [initialMode]);\n useEffect(() => {\n if (mode) {\n localStorage.setItem(\"principlemd-theme-mode\", mode);\n } else {\n localStorage.removeItem(\"principlemd-theme-mode\");\n }\n }, [mode]);\n const value = {\n theme: activeTheme,\n mode,\n setMode\n };\n return /* @__PURE__ */ React.createElement(ThemeContextSingleton.Provider, {\n value\n }, children);\n};\nvar withTheme = (Component) => {\n return (props) => {\n const { theme: theme2 } = useTheme();\n return /* @__PURE__ */ React.createElement(Component, {\n ...props,\n theme: theme2\n });\n };\n};\n// src/utils.ts\nvar getColor = (theme2, colorKey) => {\n const colors = theme2.colors;\n const value = colors[colorKey];\n return typeof value === \"string\" ? value : colorKey;\n};\nvar getSpace = (theme2, index) => {\n return theme2.space[index] || 0;\n};\nvar getFontSize = (theme2, index) => {\n return theme2.fontSizes[index] || theme2.fontSizes[2];\n};\nvar getRadius = (theme2, index) => {\n return theme2.radii[index] || 0;\n};\nvar getShadow = (theme2, index) => {\n return theme2.shadows[index] || \"none\";\n};\nvar getZIndex = (theme2, index) => {\n return theme2.zIndices[index] || 0;\n};\nvar responsive = (values) => {\n return values.reduce((acc, value, index) => {\n if (index === 0) {\n return value;\n }\n return {\n ...acc,\n [`@media screen and (min-width: ${values[index - 1]})`]: value\n };\n }, {});\n};\nvar sx = (styles) => styles;\nvar createStyle = (theme2, styleObj) => {\n const processValue = (value) => {\n if (typeof value === \"string\") {\n if (value in theme2.colors) {\n return getColor(theme2, value);\n }\n return value;\n }\n if (typeof value === \"number\") {\n return value;\n }\n if (Array.isArray(value)) {\n return value.map(processValue);\n }\n if (typeof value === \"object\" && value !== null) {\n const processed2 = {};\n for (const [key, val] of Object.entries(value)) {\n processed2[key] = processValue(val);\n }\n return processed2;\n }\n return value;\n };\n const processed = {};\n for (const [key, val] of Object.entries(styleObj)) {\n processed[key] = processValue(val);\n }\n return processed;\n};\nvar mergeThemes = (baseTheme, ...overrides) => {\n return overrides.reduce((theme2, override) => ({\n space: override.space || theme2.space,\n fonts: { ...theme2.fonts, ...override.fonts || {} },\n fontSizes: override.fontSizes || theme2.fontSizes,\n fontWeights: { ...theme2.fontWeights, ...override.fontWeights || {} },\n lineHeights: { ...theme2.lineHeights, ...override.lineHeights || {} },\n breakpoints: override.breakpoints || theme2.breakpoints,\n sizes: override.sizes || theme2.sizes,\n radii: override.radii || theme2.radii,\n shadows: override.shadows || theme2.shadows,\n zIndices: override.zIndices || theme2.zIndices,\n colors: {\n ...theme2.colors,\n ...override.colors || {}\n },\n buttons: { ...theme2.buttons, ...override.buttons || {} },\n text: { ...theme2.text, ...override.text || {} },\n cards: { ...theme2.cards, ...override.cards || {} }\n }), baseTheme);\n};\n// src/ThemeShowcase.tsx\nimport React2 from \"react\";\nvar ThemeShowcase = ({\n theme: theme2,\n title,\n showValues = true,\n sections = [\"colors\", \"typography\", \"spacing\", \"shadows\", \"radii\"]\n}) => {\n const containerStyle = {\n fontFamily: theme2.fonts.body,\n color: theme2.colors.text,\n backgroundColor: theme2.colors.background,\n padding: theme2.space[4],\n minHeight: \"100vh\"\n };\n const sectionStyle = {\n marginBottom: theme2.space[5],\n padding: theme2.space[4],\n backgroundColor: theme2.colors.surface || theme2.colors.backgroundSecondary,\n borderRadius: theme2.radii[2],\n border: `1px solid ${theme2.colors.border}`\n };\n const headingStyle = {\n fontFamily: theme2.fonts.heading,\n fontSize: theme2.fontSizes[5],\n fontWeight: theme2.fontWeights.heading,\n marginBottom: theme2.space[3],\n color: theme2.colors.primary\n };\n const subheadingStyle = {\n fontFamily: theme2.fonts.heading,\n fontSize: theme2.fontSizes[3],\n fontWeight: theme2.fontWeights.medium,\n marginBottom: theme2.space[2],\n marginTop: theme2.space[3],\n color: theme2.colors.text\n };\n return /* @__PURE__ */ React2.createElement(\"div\", {\n style: containerStyle\n }, title && /* @__PURE__ */ React2.createElement(\"h1\", {\n style: {\n ...headingStyle,\n fontSize: theme2.fontSizes[6],\n marginBottom: theme2.space[4]\n }\n }, title), sections.includes(\"colors\") && /* @__PURE__ */ React2.createElement(\"div\", {\n style: sectionStyle\n }, /* @__PURE__ */ React2.createElement(\"h2\", {\n style: headingStyle\n }, \"Colors\"), /* @__PURE__ */ React2.createElement(\"h3\", {\n style: subheadingStyle\n }, \"Primary Colors\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"grid\",\n gridTemplateColumns: \"repeat(auto-fill, minmax(200px, 1fr))\",\n gap: theme2.space[3],\n marginBottom: theme2.space[3]\n }\n }, [\"text\", \"background\", \"primary\", \"secondary\", \"accent\", \"muted\"].map((key) => {\n const color = theme2.colors[key];\n if (!color)\n return null;\n return /* @__PURE__ */ React2.createElement(\"div\", {\n key,\n style: {\n display: \"flex\",\n alignItems: \"center\",\n padding: theme2.space[2],\n backgroundColor: theme2.colors.backgroundLight || theme2.colors.backgroundTertiary,\n borderRadius: theme2.radii[1]\n }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n width: 40,\n height: 40,\n backgroundColor: color,\n border: `1px solid ${theme2.colors.border}`,\n borderRadius: theme2.radii[1],\n marginRight: theme2.space[2]\n }\n }), /* @__PURE__ */ React2.createElement(\"div\", null, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n fontWeight: theme2.fontWeights.medium\n }\n }, key), showValues && /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[0],\n color: theme2.colors.textSecondary\n }\n }, color)));\n })), /* @__PURE__ */ React2.createElement(\"h3\", {\n style: subheadingStyle\n }, \"Status Colors\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"grid\",\n gridTemplateColumns: \"repeat(auto-fill, minmax(200px, 1fr))\",\n gap: theme2.space[3],\n marginBottom: theme2.space[3]\n }\n }, [\"success\", \"warning\", \"error\", \"info\"].map((key) => {\n const color = theme2.colors[key];\n if (!color)\n return null;\n return /* @__PURE__ */ React2.createElement(\"div\", {\n key,\n style: {\n display: \"flex\",\n alignItems: \"center\",\n padding: theme2.space[2],\n backgroundColor: theme2.colors.backgroundLight || theme2.colors.backgroundTertiary,\n borderRadius: theme2.radii[1]\n }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n width: 40,\n height: 40,\n backgroundColor: color,\n border: `1px solid ${theme2.colors.border}`,\n borderRadius: theme2.radii[1],\n marginRight: theme2.space[2]\n }\n }), /* @__PURE__ */ React2.createElement(\"div\", null, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n fontWeight: theme2.fontWeights.medium\n }\n }, key), showValues && /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[0],\n color: theme2.colors.textSecondary\n }\n }, color)));\n })), /* @__PURE__ */ React2.createElement(\"h3\", {\n style: subheadingStyle\n }, \"Background Colors\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"grid\",\n gridTemplateColumns: \"repeat(auto-fill, minmax(200px, 1fr))\",\n gap: theme2.space[3]\n }\n }, [\"backgroundSecondary\", \"backgroundTertiary\", \"backgroundLight\", \"backgroundHover\", \"surface\"].map((key) => {\n const color = theme2.colors[key];\n if (!color)\n return null;\n return /* @__PURE__ */ React2.createElement(\"div\", {\n key,\n style: {\n padding: theme2.space[3],\n backgroundColor: color,\n border: `1px solid ${theme2.colors.border}`,\n borderRadius: theme2.radii[1]\n }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n fontWeight: theme2.fontWeights.medium\n }\n }, key), showValues && /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[0],\n color: theme2.colors.textSecondary,\n marginTop: theme2.space[1]\n }\n }, color));\n }))), sections.includes(\"typography\") && /* @__PURE__ */ React2.createElement(\"div\", {\n style: sectionStyle\n }, /* @__PURE__ */ React2.createElement(\"h2\", {\n style: headingStyle\n }, \"Typography\"), /* @__PURE__ */ React2.createElement(\"h3\", {\n style: subheadingStyle\n }, \"Font Families\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: { marginBottom: theme2.space[4] }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.heading,\n fontSize: theme2.fontSizes[4],\n marginBottom: theme2.space[2]\n }\n }, \"Heading Font: \", showValues && /* @__PURE__ */ React2.createElement(\"span\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n color: theme2.colors.textSecondary\n }\n }, \" \", theme2.fonts.heading)), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.body,\n fontSize: theme2.fontSizes[2],\n marginBottom: theme2.space[2]\n }\n }, \"Body Font: \", showValues && /* @__PURE__ */ React2.createElement(\"span\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n color: theme2.colors.textSecondary\n }\n }, \" \", theme2.fonts.body)), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[2]\n }\n }, \"Monospace Font: \", showValues && /* @__PURE__ */ React2.createElement(\"span\", {\n style: {\n fontSize: theme2.fontSizes[1],\n color: theme2.colors.textSecondary\n }\n }, \" \", theme2.fonts.monospace))), /* @__PURE__ */ React2.createElement(\"h3\", {\n style: subheadingStyle\n }, \"Font Sizes\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: { marginBottom: theme2.space[4] }\n }, theme2.fontSizes.map((size, index) => /* @__PURE__ */ React2.createElement(\"div\", {\n key: index,\n style: {\n fontSize: size,\n lineHeight: theme2.lineHeights.body,\n marginBottom: theme2.space[1]\n }\n }, \"Size \", index, \": Sample Text \", showValues && `(${size}px)`))), /* @__PURE__ */ React2.createElement(\"h3\", {\n style: subheadingStyle\n }, \"Font Weights\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"grid\",\n gridTemplateColumns: \"repeat(auto-fit, minmax(150px, 1fr))\",\n gap: theme2.space[2]\n }\n }, Object.entries(theme2.fontWeights).map(([name, weight]) => /* @__PURE__ */ React2.createElement(\"div\", {\n key: name,\n style: {\n fontWeight: weight,\n fontSize: theme2.fontSizes[2]\n }\n }, name, \" \", showValues && `(${weight})`)))), sections.includes(\"spacing\") && /* @__PURE__ */ React2.createElement(\"div\", {\n style: sectionStyle\n }, /* @__PURE__ */ React2.createElement(\"h2\", {\n style: headingStyle\n }, \"Spacing\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: { display: \"flex\", flexDirection: \"column\", gap: theme2.space[2] }\n }, theme2.space.map((space, index) => /* @__PURE__ */ React2.createElement(\"div\", {\n key: index,\n style: { display: \"flex\", alignItems: \"center\" }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n width: 60,\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n color: theme2.colors.textSecondary\n }\n }, \"[\", index, \"]\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n height: 24,\n width: space,\n backgroundColor: theme2.colors.primary,\n borderRadius: theme2.radii[1]\n }\n }), showValues && /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n marginLeft: theme2.space[2],\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[1],\n color: theme2.colors.textSecondary\n }\n }, space, \"px\"))))), sections.includes(\"radii\") && /* @__PURE__ */ React2.createElement(\"div\", {\n style: sectionStyle\n }, /* @__PURE__ */ React2.createElement(\"h2\", {\n style: headingStyle\n }, \"Border Radii\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"grid\",\n gridTemplateColumns: \"repeat(auto-fill, minmax(100px, 1fr))\",\n gap: theme2.space[3]\n }\n }, theme2.radii.map((radius, index) => /* @__PURE__ */ React2.createElement(\"div\", {\n key: index,\n style: { textAlign: \"center\" }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n width: 80,\n height: 80,\n backgroundColor: theme2.colors.primary,\n borderRadius: radius,\n marginBottom: theme2.space[1],\n margin: \"0 auto\"\n }\n }), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[0],\n color: theme2.colors.textSecondary\n }\n }, \"[\", index, \"] \", showValues && `${radius}px`))))), sections.includes(\"shadows\") && /* @__PURE__ */ React2.createElement(\"div\", {\n style: sectionStyle\n }, /* @__PURE__ */ React2.createElement(\"h2\", {\n style: headingStyle\n }, \"Shadows\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"grid\",\n gridTemplateColumns: \"repeat(auto-fill, minmax(150px, 1fr))\",\n gap: theme2.space[4]\n }\n }, theme2.shadows.map((shadow, index) => /* @__PURE__ */ React2.createElement(\"div\", {\n key: index,\n style: { textAlign: \"center\" }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n width: 100,\n height: 100,\n backgroundColor: theme2.colors.background,\n boxShadow: shadow,\n borderRadius: theme2.radii[2],\n margin: \"0 auto\",\n marginBottom: theme2.space[2],\n border: `1px solid ${theme2.colors.border}`\n }\n }), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[0],\n color: theme2.colors.textSecondary\n }\n }, \"Shadow [\", index, \"]\"), showValues && /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n fontFamily: theme2.fonts.monospace,\n fontSize: theme2.fontSizes[0],\n color: theme2.colors.textMuted,\n marginTop: theme2.space[1]\n }\n }, shadow === \"none\" ? \"none\" : \"...\"))))), theme2.modes && Object.keys(theme2.modes).length > 0 && /* @__PURE__ */ React2.createElement(\"div\", {\n style: sectionStyle\n }, /* @__PURE__ */ React2.createElement(\"h2\", {\n style: headingStyle\n }, \"Available Modes\"), /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n display: \"flex\",\n gap: theme2.space[2],\n flexWrap: \"wrap\"\n }\n }, /* @__PURE__ */ React2.createElement(\"div\", {\n style: {\n padding: `${theme2.space[2]}px ${theme2.space[3]}px`,\n backgroundColor: theme2.colors.primary,\n color: \"#ffffff\",\n borderRadius: theme2.radii[2],\n fontFamily: theme2.fonts.body,\n fontSize: theme2.fontSizes[1]\n }\n }, \"default\"), Object.keys(theme2.modes).map((modeName) => /* @__PURE__ */ React2.createElement(\"div\", {\n key: modeName,\n style: {\n padding: `${theme2.space[2]}px ${theme2.space[3]}px`,\n backgroundColor: theme2.colors.secondary,\n color: theme2.colors.text,\n borderRadius: theme2.radii[2],\n fontFamily: theme2.fonts.body,\n fontSize: theme2.fontSizes[1]\n }\n }, modeName)))));\n};\n\n// src/index.ts\nvar theme = terminalTheme;\nfunction scaleThemeFonts(theme2, scale) {\n const currentScale = theme2.fontScale || 1;\n const effectiveScale = scale / currentScale;\n return {\n ...theme2,\n fontSizes: theme2.fontSizes.map((size) => Math.round(size * effectiveScale)),\n fontScale: scale\n };\n}\nfunction increaseFontScale(theme2) {\n const currentScale = theme2.fontScale || 1;\n const newScale = Math.min(currentScale * 1.1, 2);\n return scaleThemeFonts(theme2, newScale);\n}\nfunction decreaseFontScale(theme2) {\n const currentScale = theme2.fontScale || 1;\n const newScale = Math.max(currentScale * 0.9, 0.5);\n return scaleThemeFonts(theme2, newScale);\n}\nfunction resetFontScale(theme2) {\n return scaleThemeFonts(theme2, 1);\n}\nvar src_default = theme;\nexport {\n withTheme,\n useTheme,\n theme,\n terminalTheme,\n sx,\n slateTheme,\n scaleThemeFonts,\n responsive,\n resetFontScale,\n regalTheme,\n overrideColors,\n mergeThemes,\n matrixTheme,\n matrixMinimalTheme,\n makeTheme,\n increaseFontScale,\n glassmorphismTheme,\n getZIndex,\n getSpace,\n getShadow,\n getRadius,\n getMode,\n getFontSize,\n getColor,\n defaultTerminalTheme,\n defaultMarkdownTheme,\n defaultEditorTheme,\n src_default as default,\n decreaseFontScale,\n createStyle,\n addMode,\n ThemeShowcase,\n ThemeProvider\n};\n","function r(e){var t,f,n=\"\";if(\"string\"==typeof e||\"number\"==typeof e)n+=e;else if(\"object\"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(f=r(e[t]))&&(n&&(n+=\" \"),n+=f)}else for(f in e)e[f]&&(n&&(n+=\" \"),n+=f);return n}export function clsx(){for(var e,t,f=0,n=\"\",o=arguments.length;f<o;f++)(e=arguments[f])&&(t=r(e))&&(n&&(n+=\" \"),n+=t);return n}export default clsx;","import { type ClassValue, clsx } from \"clsx\";\n\nexport function cn(...inputs: ClassValue[]) {\n return clsx(inputs);\n}\n","import * as React from 'react';\nimport { cn } from '../lib/utils';\nimport type { Theme } from '@principal-ade/industry-theme';\nimport type { QualityMetrics } from '@principal-ai/codebase-composition';\n\nexport type { QualityMetrics };\nexport type QualityTier = 'none' | 'bronze' | 'silver' | 'gold' | 'platinum';\nexport type MetricKey = 'types' | 'documentation' | 'tests' | 'deadCode' | 'formatting' | 'linting';\n\nexport interface VertexHoverInfo {\n key: MetricKey;\n label: string;\n value: number;\n color: string;\n}\n\ninterface QualityHexagonProps {\n metrics: QualityMetrics;\n tier: QualityTier;\n theme: Theme;\n showLabels?: boolean;\n showValues?: boolean;\n className?: string;\n onVertexHover?: (info: VertexHoverInfo) => void;\n onVertexLeave?: () => void;\n onVertexClick?: (info: VertexHoverInfo) => void;\n}\n\n// Helper to extract theme colors\nfunction getThemeColors(theme: Theme) {\n return {\n gridColor: theme.colors.border,\n axisColor: theme.colors.muted,\n textColor: theme.colors.text,\n scoreColor: theme.colors.text,\n tierColors: {\n none: { fill: theme.colors.muted, stroke: theme.colors.border, bg: theme.colors.backgroundLight },\n bronze: { fill: theme.colors.warning, stroke: theme.colors.warning, bg: theme.colors.backgroundLight },\n silver: { fill: theme.colors.secondary, stroke: theme.colors.secondary, bg: theme.colors.backgroundLight },\n gold: { fill: theme.colors.accent, stroke: theme.colors.accent, bg: theme.colors.backgroundLight },\n platinum: { fill: theme.colors.primary, stroke: theme.colors.primary, bg: theme.colors.backgroundLight }\n },\n metricColors: {\n types: theme.colors.warning,\n documentation: theme.colors.info,\n tests: theme.colors.success,\n deadCode: theme.colors.error,\n formatting: theme.colors.accent,\n linting: theme.colors.primary\n },\n qualityIndicators: {\n good: theme.colors.success,\n medium: theme.colors.warning,\n poor: theme.colors.error\n }\n };\n}\n\n// Metrics ordered clockwise from top-left\nconst getMetricConfig = (themeColors: ReturnType<typeof getThemeColors>) => [\n { key: 'types', label: 'Types', color: themeColors.metricColors.types, angle: -120 },\n { key: 'documentation', label: 'Docs', color: themeColors.metricColors.documentation, angle: -60 },\n { key: 'tests', label: 'Tests', color: themeColors.metricColors.tests, angle: 0 },\n { key: 'deadCode', label: 'Dead Code', color: themeColors.metricColors.deadCode, angle: 60 },\n { key: 'formatting', label: 'Format', color: themeColors.metricColors.formatting, angle: 120 },\n { key: 'linting', label: 'Linting', color: themeColors.metricColors.linting, angle: 180 }\n] as const;\n\nfunction calculateHexagonPoints(center: number, radius: number, metricConfig: ReturnType<typeof getMetricConfig>): string {\n return metricConfig\n .map(({ angle }) => {\n const radian = (angle * Math.PI) / 180;\n const x = center + radius * Math.cos(radian);\n const y = center + radius * Math.sin(radian);\n return `${x},${y}`;\n })\n .join(' ');\n}\n\nfunction calculateMetricPoint(\n center: number,\n radius: number,\n angle: number,\n value: number\n): { x: number; y: number } {\n const actualRadius = (radius * value) / 100;\n const radian = (angle * Math.PI) / 180;\n return {\n x: center + actualRadius * Math.cos(radian),\n y: center + actualRadius * Math.sin(radian)\n };\n}\n\nexport function QualityHexagon({\n metrics,\n tier,\n theme,\n showLabels = false,\n showValues = false,\n className,\n onVertexHover,\n onVertexLeave,\n onVertexClick,\n}: QualityHexagonProps) {\n const themeColors = getThemeColors(theme);\n const colors = themeColors.tierColors[tier] ?? themeColors.tierColors.none;\n const metricConfig = getMetricConfig(themeColors);\n // Use fixed internal coordinates for viewBox\n const viewBoxSize = 300;\n const center = viewBoxSize / 2;\n const radius = viewBoxSize * 0.28;\n const padding = viewBoxSize * 0.1;\n const fontSize = viewBoxSize * 0.04;\n const strokeWidth = viewBoxSize * 0.008;\n const dotSize = viewBoxSize * 0.015;\n\n const hexagonPoints = calculateHexagonPoints(center, radius, metricConfig);\n\n const dataPoints = metricConfig\n .map(({ key, angle }) => {\n let value = metrics[key as keyof QualityMetrics];\n // Invert dead code metric (less is better)\n if (key === 'deadCode') {\n value = 100 - value;\n }\n return calculateMetricPoint(center, radius, angle, value);\n })\n .map(p => `${p.x},${p.y}`)\n .join(' ');\n\n // Calculate average with inverted dead code\n const metricsForAverage = { ...metrics };\n metricsForAverage.deadCode = 100 - metricsForAverage.deadCode;\n const averageScore = Math.round(\n Object.values(metricsForAverage).reduce((a, b) => a + b, 0) / 6\n );\n\n const hexagon = (\n <svg\n viewBox={`0 0 ${viewBoxSize} ${viewBoxSize}`}\n className={cn('w-full h-full transition-all duration-300', className)}\n preserveAspectRatio=\"xMidYMid meet\"\n >\n {/* Grid lines */}\n <g className=\"opacity-20\">\n {[20, 40, 60, 80, 100].map((percent) => (\n <polygon\n key={percent}\n points={calculateHexagonPoints(center, (radius * percent) / 100, metricConfig)}\n fill=\"none\"\n stroke={themeColors.gridColor}\n strokeWidth={0.5}\n style={{ opacity: 0.4 }}\n />\n ))}\n </g>\n\n {/* Axes */}\n {metricConfig.map(({ angle }) => {\n const endPoint = calculateMetricPoint(center, radius, angle, 100);\n return (\n <line\n key={angle}\n x1={center}\n y1={center}\n x2={endPoint.x}\n y2={endPoint.y}\n stroke={themeColors.axisColor}\n strokeWidth={0.5}\n style={{ opacity: 0.5 }}\n />\n );\n })}\n\n {/* Outer hexagon */}\n <polygon\n points={hexagonPoints}\n fill=\"none\"\n stroke={colors.stroke}\n strokeWidth={strokeWidth}\n style={{ opacity: 0.3 }}\n />\n\n {/* Data polygon */}\n <polygon\n points={dataPoints}\n fill={colors.fill}\n fillOpacity={0.3}\n stroke={colors.stroke}\n strokeWidth={strokeWidth}\n style={{ transition: 'all 0.5s ease' }}\n />\n\n {/* Vertex dots */}\n {metricConfig.map(({ key, label, color, angle }) => {\n const rawValue = metrics[key as keyof QualityMetrics];\n let value = rawValue;\n // Invert dead code metric for display\n if (key === 'deadCode') {\n value = 100 - value;\n }\n const point = calculateMetricPoint(center, radius, angle, 100);\n const dataPoint = calculateMetricPoint(center, radius, angle, value);\n\n const vertexInfo: VertexHoverInfo = {\n key: key as MetricKey,\n label,\n value: rawValue,\n color,\n };\n\n const handleMouseEnter = () => {\n onVertexHover?.(vertexInfo);\n };\n\n const handleClick = (e: React.MouseEvent) => {\n e.stopPropagation();\n onVertexClick?.(vertexInfo);\n };\n\n return (\n <g\n key={key}\n onMouseEnter={handleMouseEnter}\n onMouseLeave={onVertexLeave}\n onClick={handleClick}\n style={{ cursor: (onVertexHover || onVertexClick) ? 'pointer' : 'default' }}\n >\n {/* Larger invisible hit area for easier hovering */}\n <circle\n cx={point.x}\n cy={point.y}\n r={dotSize * 2.5}\n fill=\"transparent\"\n />\n {/* Outer vertex marker */}\n <circle\n cx={point.x}\n cy={point.y}\n r={dotSize}\n fill=\"white\"\n stroke={colors.stroke}\n strokeWidth={1.5}\n />\n {/* Value indicator */}\n <circle\n cx={dataPoint.x}\n cy={dataPoint.y}\n r={dotSize * 0.7}\n fill={colors.fill}\n stroke={colors.stroke}\n strokeWidth={1}\n style={{ opacity: 0.9 }}\n />\n </g>\n );\n })}\n\n {/* Center score */}\n <text\n x={center}\n y={center}\n textAnchor=\"middle\"\n dominantBaseline=\"middle\"\n fill={themeColors.scoreColor}\n fontSize={fontSize * 1.5}\n fontWeight=\"600\"\n >\n {averageScore}\n </text>\n <text\n x={center}\n y={center + fontSize}\n textAnchor=\"middle\"\n dominantBaseline=\"middle\"\n fill={themeColors.textColor}\n fontSize={fontSize * 0.8}\n style={{ opacity: 0.6 }}\n >\n avg\n </text>\n\n {/* Labels */}\n {showLabels && (\n <>\n {metricConfig.map(({ key, label, angle }) => {\n const labelRadius = radius + padding * 1.2;\n const point = calculateMetricPoint(center, labelRadius, angle, 100);\n const value = metrics[key as keyof QualityMetrics];\n\n return (\n <text\n key={key}\n x={point.x}\n y={point.y}\n textAnchor=\"middle\"\n dominantBaseline=\"middle\"\n fill={themeColors.textColor}\n fontSize={fontSize}\n >\n {showValues ? `${value}%` : label}\n </text>\n );\n })}\n </>\n )}\n </svg>\n );\n\n // For non-interactive mode or when tooltips are not available, just return the hexagon\n return hexagon;\n}\n\nexport function QualityHexagonCompact({\n metrics,\n tier,\n theme,\n className\n}: Pick<QualityHexagonProps, 'metrics' | 'tier' | 'theme' | 'className'>) {\n return (\n <div className={cn('w-20 h-20', className)}>\n <QualityHexagon\n metrics={metrics}\n tier={tier}\n theme={theme}\n showLabels={false}\n showValues={false}\n />\n </div>\n );\n}\n\ninterface QualityHexagonDetailedProps extends Pick<QualityHexagonProps, 'metrics' | 'tier' | 'theme' | 'className'> {\n packageName?: string;\n packageVersion?: string;\n onRefresh?: () => void;\n isRefreshing?: boolean;\n}\n\nexport function QualityHexagonDetailed({\n metrics,\n tier,\n theme,\n className,\n packageName,\n packageVersion,\n onRefresh,\n isRefreshing = false,\n}: QualityHexagonDetailedProps) {\n const themeColors = getThemeColors(theme);\n const colors = themeColors.tierColors[tier] ?? themeColors.tierColors.none;\n const metricConfig = getMetricConfig(themeColors);\n\n const hasHeader = packageName || onRefresh;\n\n return (\n <div\n className={cn(className)}\n style={{\n display: 'flex',\n flexDirection: 'column',\n gap: 12,\n padding: 16,\n borderRadius: 8,\n backgroundColor: colors.bg,\n }}\n >\n {hasHeader && (\n <div style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n gap: 12,\n }}>\n {packageName ? (\n <div style={{ display: 'flex', flexDirection: 'column', gap: 2 }}>\n {packageName.startsWith('@') && packageName.includes('/') ? (\n <>\n <span style={{\n fontSize: 12,\n color: theme.colors.textMuted,\n }}>\n {packageName.split('/')[0]}\n </span>\n <span style={{\n fontSize: 14,\n fontWeight: 500,\n color: colors.stroke,\n }}>\n {packageName.split('/')[1]}\n </span>\n </>\n ) : (\n <span style={{\n fontSize: 14,\n fontWeight: 500,\n color: colors.stroke,\n }}>\n {packageName}\n </span>\n )}\n {packageVersion && (\n <span style={{\n fontSize: 12,\n color: theme.colors.textMuted,\n }}>\n v{packageVersion}\n </span>\n )}\n </div>\n ) : <span />}\n {onRefresh && (\n <button\n onClick={onRefresh}\n disabled={isRefreshing}\n style={{\n padding: 6,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n border: `1px solid ${theme.colors.border}`,\n borderRadius: 4,\n background: theme.colors.surface,\n color: theme.colors.textMuted,\n cursor: isRefreshing ? 'not-allowed' : 'pointer',\n opacity: isRefreshing ? 0.6 : 1,\n }}\n title=\"Refresh\"\n >\n <svg\n width=\"14\"\n height=\"14\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n strokeWidth=\"2\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n style={{\n animation: isRefreshing ? 'spin 1s linear infinite' : 'none',\n }}\n >\n <path d=\"M21 12a9 9 0 0 0-9-9 9.75 9.75 0 0 0-6.74 2.74L3 8\" />\n <path d=\"M3 3v5h5\" />\n <path d=\"M3 12a9 9 0 0 0 9 9 9.75 9.75 0 0 0 6.74-2.74L21 16\" />\n <path d=\"M16 16h5v5\" />\n </svg>\n </button>\n )}\n </div>\n )}\n\n <div style={{\n display: 'flex',\n flexWrap: 'wrap',\n alignItems: 'center',\n justifyContent: 'center',\n gap: 24,\n }}>\n <div style={{ flex: '1 1 200px', maxWidth: 300, aspectRatio: '1 / 1' }}>\n <QualityHexagon\n metrics={metrics}\n tier={tier}\n theme={theme}\n showLabels={true}\n showValues={false}\n />\n </div>\n\n <div style={{ flex: '1 1 200px', minWidth: 200, display: 'flex', flexDirection: 'column', gap: 8, padding: '8px 24px' }}>\n {metricConfig.map(({ key, label, color }) => {\n const value = metrics[key as keyof QualityMetrics];\n const displayValue = value;\n\n return (\n <div key={key} style={{ display: 'flex', alignItems: 'center', justifyContent: 'space-between', gap: 12 }}>\n <span style={{\n fontSize: 14,\n color: theme.colors.textMuted,\n }}>\n {label}{key === 'deadCode' ? ' ↓' : ''}\n </span>\n <span style={{\n fontSize: 14,\n fontWeight: 500,\n color: color,\n }}>\n {displayValue}%\n </span>\n </div>\n );\n })}\n </div>\n </div>\n </div>\n );\n}\n\ninterface QualityHexagonExpandableProps extends Pick<QualityHexagonProps, 'metrics' | 'tier' | 'theme' | 'className'> {\n packageName?: string;\n packageVersion?: string;\n packagePath?: string;\n onRefresh?: () => void;\n isRefreshing?: boolean;\n defaultExpanded?: boolean;\n /** Callback when the hexagon is expanded/collapsed */\n onExpandChange?: (expanded: boolean, info: { packageName?: string; packagePath?: string }) => void;\n}\n\nexport function QualityHexagonExpandable({\n metrics,\n tier,\n theme,\n className,\n packageName,\n packageVersion,\n packagePath,\n onRefresh,\n isRefreshing = false,\n defaultExpanded = false,\n onExpandChange,\n}: QualityHexagonExpandableProps) {\n const [expanded, setExpanded] = React.useState(defaultExpanded);\n\n const handleToggleExpand = React.useCallback(() => {\n const newExpanded = !expanded;\n setExpanded(newExpanded);\n onExpandChange?.(newExpanded, { packageName, packagePath });\n }, [expanded, onExpandChange, packageName, packagePath]);\n const themeColors = getThemeColors(theme);\n const colors = themeColors.tierColors[tier] ?? themeColors.tierColors.none;\n const metricConfig = getMetricConfig(themeColors);\n\n const hasHeader = packageName || onRefresh;\n\n return (\n <div\n className={cn(className)}\n style={{\n display: 'flex',\n flexDirection: 'column',\n gap: 12,\n padding: 16,\n borderRadius: 8,\n backgroundColor: colors.bg,\n flex: '1 1 200px',\n }}\n >\n {hasHeader && (\n <div style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n gap: 12,\n }}>\n {packageName ? (\n <div style={{ display: 'flex', flexDirection: 'column', gap: 2 }}>\n {packageName.startsWith('@') && packageName.includes('/') ? (\n <>\n <span style={{\n fontSize: 12,\n color: theme.colors.textMuted,\n }}>\n {packageName.split('/')[0]}\n </span>\n <span style={{\n fontSize: 14,\n fontWeight: 500,\n color: colors.stroke,\n }}>\n {packageName.split('/')[1]}\n </span>\n </>\n ) : (\n <span style={{\n fontSize: 14,\n fontWeight: 500,\n color: colors.stroke,\n }}>\n {packageName}\n </span>\n )}\n {packageVersion && (\n <span style={{\n fontSize: 12,\n color: theme.colors.textMuted,\n }}>\n v{packageVersion}\n </span>\n )}\n </div>\n ) : <span />}\n {onRefresh && (\n <button\n onClick={onRefresh}\n disabled={isRefreshing}\n style={{\n padding: 6,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n border: `1px solid ${theme.colors.border}`,\n borderRadius: 4,\n background: theme.colors.surface,\n color: theme.colors.textMuted,\n cursor: isRefreshing ? 'not-allowed' : 'pointer',\n opacity: isRefreshing ? 0.6 : 1,\n }}\n title=\"Refresh\"\n >\n <svg\n width=\"14\"\n height=\"14\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke=\"currentColor\"\n strokeWidth=\"2\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n style={{\n animation: isRefreshing ? 'spin 1s linear infinite' : 'none',\n }}\n >\n <path d=\"M21 12a9 9 0 0 0-9-9 9.75 9.75 0 0 0-6.74 2.74L3 8\" />\n <path d=\"M3 3v5h5\" />\n <path d=\"M3 12a9 9 0 0 0 9 9 9.75 9.75 0 0 0 6.74-2.74L21 16\" />\n <path d=\"M16 16h5v5\" />\n </svg>\n </button>\n )}\n </div>\n )}\n\n {/* Clickable hexagon */}\n <div\n onClick={handleToggleExpand}\n style={{\n cursor: 'pointer',\n display: 'flex',\n justifyContent: 'center',\n alignItems: 'center',\n }}\n >\n <div style={{ width: 200, height: 200 }}>\n <QualityHexagon\n metrics={metrics}\n tier={tier}\n theme={theme}\n showLabels={true}\n showValues={false}\n />\n </div>\n </div>\n\n {/* Expandable metrics breakdown */}\n <div\n style={{\n display: 'grid',\n gridTemplateRows: expanded ? '1fr' : '0fr',\n transition: 'grid-template-rows 0.3s ease',\n }}\n >\n <div style={{ overflow: 'hidden' }}>\n <div style={{\n display: 'flex',\n flexDirection: 'column',\n gap: 8,\n padding: '8px 24px',\n borderTop: `1px solid ${theme.colors.border}`,\n marginTop: 8,\n }}>\n {metricConfig.map(({ key, label, color }) => {\n const value = metrics[key as keyof QualityMetrics];\n\n return (\n <div\n key={key}\n style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n gap: 12,\n }}\n >\n <span style={{\n fontSize: 14,\n color: theme.colors.textMuted,\n }}>\n {label}{key === 'deadCode' ? ' ↓' : ''}\n </span>\n <span style={{\n fontSize: 14,\n fontWeight: 500,\n color: color,\n }}>\n {value}%\n </span>\n </div>\n );\n })}\n </div>\n </div>\n </div>\n\n {/* Expand/collapse indicator */}\n <div\n onClick={handleToggleExpand}\n style={{\n display: 'flex',\n justifyContent: 'center',\n cursor: 'pointer',\n padding: 4,\n }}\n >\n <svg\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n stroke={theme.colors.textMuted}\n strokeWidth=\"2\"\n strokeLinecap=\"round\"\n strokeLinejoin=\"round\"\n style={{\n transform: expanded ? 'rotate(180deg)' : 'rotate(0deg)',\n transition: 'transform 0.3s ease',\n }}\n >\n <path d=\"m6 9 6 6 6-6\" />\n </svg>\n </div>\n </div>\n );\n}\n\n/**\n * Calculate the quality tier based on metrics\n */\nexport function calculateQualityTier(metrics: QualityMetrics): QualityTier {\n // Invert dead code for calculation (less is better)\n const metricsForAverage = { ...metrics };\n metricsForAverage.deadCode = 100 - metricsForAverage.deadCode;\n\n const average = Object.values(metricsForAverage).reduce((a, b) => a + b, 0) / 6;\n\n if (average >= 90) return 'platinum';\n if (average >= 75) return 'gold';\n if (average >= 60) return 'silver';\n if (average >= 40) return 'bronze';\n return 'none';\n}\n","import React from 'react';\nimport { Terminal, Copy, Check, ChevronRight, Zap, GitBranch, Info } from 'lucide-react';\nimport type { Theme } from '@principal-ade/industry-theme';\n\ninterface QualityEmptyStateProps {\n theme: Theme;\n hasWorkflow: boolean;\n}\n\nconst WORKFLOW_FILE_PATH = '.github/workflows/quality-lens.yml';\n\n/**\n * Check if a file path exists in a FileTree's allFiles array\n */\nexport function checkFileExistsInTree(\n treeData: { allFiles?: Array<{ relativePath?: string; path?: string }> } | undefined,\n targetPath: string\n): boolean {\n if (!treeData?.allFiles) return false;\n\n const normalizedTarget = targetPath.replace(/^\\//, '').toLowerCase();\n\n return treeData.allFiles.some((file) => {\n const filePath = (file.relativePath || file.path || '').toLowerCase();\n return filePath.endsWith(normalizedTarget) || filePath === normalizedTarget;\n });\n}\n\n/**\n * Copyable command line component\n */\nconst CommandLine: React.FC<{\n command: string;\n theme: Theme;\n label?: string;\n}> = ({ command, theme, label }) => {\n const [copied, setCopied] = React.useState(false);\n\n const handleCopy = async () => {\n try {\n await navigator.clipboard.writeText(command);\n setCopied(true);\n setTimeout(() => setCopied(false), 2000);\n } catch {\n console.log('Copy:', command);\n }\n };\n\n return (\n <div style={{ display: 'flex', flexDirection: 'column', gap: 4 }}>\n {label && (\n <span style={{ fontSize: 12, color: theme.colors.textMuted }}>{label}</span>\n )}\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n gap: 12,\n padding: '10px 14px',\n borderRadius: 6,\n backgroundColor: theme.colors.background,\n border: `1px solid ${theme.colors.border}`,\n fontFamily: 'monospace',\n fontSize: 13,\n }}\n >\n <code style={{ color: theme.colors.text }}>{command}</code>\n <button\n onClick={handleCopy}\n style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n padding: 4,\n border: 'none',\n backgroundColor: 'transparent',\n color: theme.colors.textMuted,\n cursor: 'pointer',\n }}\n title=\"Copy command\"\n >\n {copied ? (\n <Check size={16} color={theme.colors.success} />\n ) : (\n <Copy size={16} />\n )}\n </button>\n </div>\n </div>\n );\n};\n\n/**\n * Mini hexagon preview showing what metrics are tracked\n */\nconst MetricsPreview: React.FC<{ theme: Theme }> = ({ theme }) => {\n const metrics = [\n { key: 'tests', label: 'Tests', description: 'Test coverage & pass rate', icon: '🧪' },\n { key: 'linting', label: 'Linting', description: 'ESLint code quality', icon: '📝' },\n { key: 'types', label: 'Types', description: 'TypeScript type safety', icon: '🔷' },\n { key: 'formatting', label: 'Formatting', description: 'Prettier code style', icon: '✨' },\n { key: 'deadCode', label: 'Dead Code', description: 'Unused exports & deps', icon: '🧹' },\n { key: 'documentation', label: 'Docs', description: 'Code documentation', icon: '📚' },\n ];\n\n return (\n <div\n style={{\n display: 'grid',\n gridTemplateColumns: 'repeat(2, 1fr)',\n gap: 8,\n padding: 12,\n borderRadius: 8,\n backgroundColor: theme.colors.surface,\n border: `1px solid ${theme.colors.border}`,\n }}\n >\n {metrics.map((m) => (\n <div\n key={m.key}\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 8,\n padding: '6px 8px',\n borderRadius: 4,\n fontSize: 12,\n }}\n >\n <span style={{ fontSize: 14 }}>{m.icon}</span>\n <div style={{ display: 'flex', flexDirection: 'column' }}>\n <span style={{ fontWeight: 500, color: theme.colors.text }}>{m.label}</span>\n <span style={{ fontSize: 11, color: theme.colors.textMuted }}>{m.description}</span>\n </div>\n </div>\n ))}\n </div>\n );\n};\n\n/**\n * Empty state component for when no quality data is available\n */\nexport const QualityEmptyState: React.FC<QualityEmptyStateProps> = ({\n theme,\n hasWorkflow,\n}) => {\n const [showAdvanced, setShowAdvanced] = React.useState(false);\n\n if (hasWorkflow) {\n // Workflow exists but no data yet\n return (\n <div\n style={{\n display: 'flex',\n flexDirection: 'column',\n padding: '16px 0',\n gap: 16,\n width: '100%',\n }}\n >\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 8,\n padding: '10px 14px',\n borderRadius: 6,\n backgroundColor: `${theme.colors.success}15`,\n color: theme.colors.success,\n fontSize: 13,\n }}\n >\n <Check size={16} />\n <span>Workflow detected at {WORKFLOW_FILE_PATH}</span>\n </div>\n\n <p\n style={{\n margin: 0,\n fontSize: 14,\n color: theme.colors.textMuted,\n lineHeight: 1.5,\n }}\n >\n Quality metrics will appear here after your workflow runs. Push a commit to trigger it, or check the Actions tab for status.\n </p>\n\n <MetricsPreview theme={theme} />\n\n <div\n style={{\n display: 'flex',\n alignItems: 'flex-start',\n gap: 8,\n padding: '10px 14px',\n borderRadius: 6,\n backgroundColor: `${theme.colors.warning}10`,\n fontSize: 12,\n color: theme.colors.textMuted,\n }}\n >\n <Info size={14} style={{ flexShrink: 0, marginTop: 2 }} color={theme.colors.warning} />\n <div>\n <strong style={{ color: theme.colors.text }}>Using private npm packages?</strong>\n <br />\n Add <code style={{ backgroundColor: theme.colors.background, padding: '1px 4px', borderRadius: 3 }}>NPM_TOKEN</code> to your repository secrets and ensure the workflow has access to it.\n </div>\n </div>\n </div>\n );\n }\n\n // No workflow - show setup instructions\n return (\n <div\n style={{\n display: 'flex',\n flexDirection: 'column',\n padding: '16px 0',\n gap: 16,\n width: '100%',\n }}\n >\n {/* What you'll get */}\n <div>\n <h4\n style={{\n margin: '0 0 12px 0',\n fontSize: 14,\n fontWeight: 600,\n color: theme.colors.text,\n }}\n >\n Track 6 quality dimensions\n </h4>\n <MetricsPreview theme={theme} />\n </div>\n\n {/* Quick Start */}\n <div\n style={{\n display: 'flex',\n flexDirection: 'column',\n gap: 12,\n padding: 16,\n borderRadius: 8,\n backgroundColor: theme.colors.surface,\n border: `1px solid ${theme.colors.border}`,\n }}\n >\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 8,\n }}\n >\n <Zap size={18} color={theme.colors.primary} />\n <h4\n style={{\n margin: 0,\n fontSize: 14,\n fontWeight: 600,\n color: theme.colors.text,\n }}\n >\n Quick Start\n </h4>\n </div>\n\n <p\n style={{\n margin: 0,\n fontSize: 13,\n color: theme.colors.textMuted,\n lineHeight: 1.5,\n }}\n >\n Run this in your project directory to set up automated quality tracking:\n </p>\n\n <CommandLine\n command=\"npx @principal-ai/quality-lens-cli init\"\n theme={theme}\n />\n\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 6,\n fontSize: 12,\n color: theme.colors.textMuted,\n }}\n >\n <GitBranch size={14} />\n <span>Then commit and push to start tracking</span>\n </div>\n </div>\n\n {/* Advanced Options Toggle */}\n <button\n onClick={() => setShowAdvanced(!showAdvanced)}\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 6,\n padding: 0,\n border: 'none',\n backgroundColor: 'transparent',\n color: theme.colors.textMuted,\n fontSize: 13,\n cursor: 'pointer',\n }}\n >\n <ChevronRight\n size={14}\n style={{\n transform: showAdvanced ? 'rotate(90deg)' : 'none',\n transition: 'transform 0.2s',\n }}\n />\n <span>{showAdvanced ? 'Hide' : 'Show'} additional options</span>\n </button>\n\n {/* Advanced Options */}\n {showAdvanced && (\n <div\n style={{\n display: 'flex',\n flexDirection: 'column',\n gap: 16,\n padding: 16,\n borderRadius: 8,\n backgroundColor: theme.colors.surface,\n border: `1px solid ${theme.colors.border}`,\n }}\n >\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 8,\n }}\n >\n <Terminal size={18} color={theme.colors.text} />\n <h4\n style={{\n margin: 0,\n fontSize: 14,\n fontWeight: 600,\n color: theme.colors.text,\n }}\n >\n CLI Commands\n </h4>\n </div>\n\n <CommandLine\n command=\"npx @principal-ai/quality-lens-cli list\"\n theme={theme}\n label=\"See available quality tools in your project\"\n />\n\n <CommandLine\n command=\"npx @principal-ai/quality-lens-cli run . --install\"\n theme={theme}\n label=\"Run quality checks locally (auto-installs missing tools)\"\n />\n\n <CommandLine\n command=\"npm install -g @principal-ai/quality-lens-cli\"\n theme={theme}\n label=\"Install globally for faster repeated use\"\n />\n\n <div\n style={{\n display: 'flex',\n alignItems: 'flex-start',\n gap: 8,\n padding: '10px 14px',\n borderRadius: 6,\n backgroundColor: `${theme.colors.warning}10`,\n fontSize: 12,\n color: theme.colors.textMuted,\n }}\n >\n <Info size={14} style={{ flexShrink: 0, marginTop: 2 }} color={theme.colors.warning} />\n <div>\n <strong style={{ color: theme.colors.text }}>Private npm packages?</strong>\n <br />\n If your project uses private @org packages, add <code style={{ backgroundColor: theme.colors.background, padding: '1px 4px', borderRadius: 3 }}>NPM_TOKEN</code> to your GitHub repository secrets under Settings → Secrets → Actions, and set the workflow environment if needed.\n </div>\n </div>\n </div>\n )}\n </div>\n );\n};\n\nexport { WORKFLOW_FILE_PATH };\n","import React from 'react';\nimport { Hexagon } from 'lucide-react';\nimport { useTheme } from '@principal-ade/industry-theme';\nimport type { PanelComponentProps } from '../types';\nimport type { QualityMetrics } from '@principal-ai/codebase-composition';\nimport {\n QualityHexagonExpandable,\n QualityTier,\n calculateQualityTier,\n} from '../components/QualityHexagon';\nimport {\n QualityEmptyState,\n checkFileExistsInTree,\n WORKFLOW_FILE_PATH,\n} from '../components/QualityEmptyState';\n\n// Mock package data - in real usage, this would come from a quality slice\nconst mockPackages: Array<{\n name: string;\n version?: string;\n metrics: QualityMetrics;\n}> = [\n {\n name: '@principal-ade/code-quality-panels',\n version: '0.1.0',\n metrics: {\n tests: 75,\n deadCode: 15,\n linting: 85,\n formatting: 90,\n types: 88,\n documentation: 65,\n },\n },\n];\n\n// Package quality data shape from slice\ninterface PackageQuality {\n name: string;\n path?: string;\n version?: string;\n metrics: QualityMetrics;\n}\n\n// Slice data shape\ninterface QualitySliceData {\n packages: PackageQuality[];\n lastUpdated: string;\n}\n\n// Metric options for the dropdown\ntype MetricKey = 'types' | 'documentation' | 'tests' | 'deadCode' | 'formatting' | 'linting';\n\nconst METRIC_OPTIONS: Array<{ key: MetricKey; label: string; colorMode: string }> = [\n { key: 'types', label: 'Types', colorMode: 'typescript' },\n { key: 'documentation', label: 'Docs', colorMode: 'alexandria' },\n { key: 'tests', label: 'Tests', colorMode: 'coverage' },\n { key: 'deadCode', label: 'Dead Code', colorMode: 'knip' },\n { key: 'formatting', label: 'Format', colorMode: 'prettier' },\n { key: 'linting', label: 'Linting', colorMode: 'eslint' },\n];\n\n/**\n * QualityHexagonPanelContent - Internal component that uses theme\n */\nconst QualityHexagonPanelContent: React.FC<PanelComponentProps> = ({\n context,\n events,\n}) => {\n const { theme } = useTheme();\n const [refreshingPackages, setRefreshingPackages] = React.useState<Set<string>>(new Set());\n const [selectedMetric, setSelectedMetric] = React.useState<MetricKey | null>(null);\n\n // Get quality data from context if available\n const qualitySlice = context.getSlice<QualitySliceData>('quality');\n const hasQualitySlice = context.hasSlice('quality');\n const isLoading = qualitySlice?.loading ?? false;\n\n // Get file tree to check for workflow presence\n const fileTreeSlice = context.getSlice<{ allFiles?: Array<{ relativePath?: string; path?: string }> }>('fileTree');\n const hasWorkflow = React.useMemo(() => {\n return checkFileExistsInTree(fileTreeSlice?.data ?? undefined, WORKFLOW_FILE_PATH);\n }, [fileTreeSlice?.data]);\n\n // Determine packages to display\n // - If slice exists and has data, use it\n // - If slice exists but is loading/empty, show empty\n // - If no slice at all, use mock data for demo\n const packages: PackageQuality[] = React.useMemo(() => {\n if (qualitySlice?.data?.packages) {\n return qualitySlice.data.packages;\n }\n if (hasQualitySlice) {\n // Slice exists but no data yet (loading or empty)\n return [];\n }\n // No slice - use mock for demo\n return mockPackages;\n }, [qualitySlice?.data?.packages, hasQualitySlice]);\n\n // Handle refresh for a specific package\n const handleRefreshPackage = async (packageName: string) => {\n setRefreshingPackages(prev => new Set(prev).add(packageName));\n try {\n if (context.hasSlice('quality')) {\n // In future, this could refresh just one package\n await context.refresh('repository', 'quality');\n }\n } finally {\n setRefreshingPackages(prev => {\n const next = new Set(prev);\n next.delete(packageName);\n return next;\n });\n }\n };\n\n // Handle refresh all\n const handleRefreshAll = async () => {\n const allNames = packages.map(p => p.name);\n setRefreshingPackages(new Set(allNames));\n try {\n if (context.hasSlice('quality')) {\n await context.refresh('repository', 'quality');\n }\n } finally {\n setRefreshingPackages(new Set());\n }\n };\n\n // Handle metric selection change\n const handleMetricChange = (metric: MetricKey | null) => {\n setSelectedMetric(metric);\n\n if (metric) {\n const option = METRIC_OPTIONS.find(o => o.key === metric);\n if (option) {\n // Emit colorMode event for File City\n events.emit({\n type: 'quality:colorMode:select',\n source: 'principal-ade.quality-hexagon-panel',\n timestamp: Date.now(),\n payload: {\n colorMode: option.colorMode,\n },\n });\n }\n } else {\n // Clear selection - reset to fileTypes\n events.emit({\n type: 'quality:colorMode:select',\n source: 'principal-ade.quality-hexagon-panel',\n timestamp: Date.now(),\n payload: {\n colorMode: 'fileTypes',\n },\n });\n }\n };\n\n // Subscribe to events\n React.useEffect(() => {\n const unsubscribers = [\n events.on('principal-ade.quality-panel:refresh', async () => {\n await handleRefreshAll();\n }),\n ];\n\n return () => unsubscribers.forEach((unsub) => unsub());\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [events, context, packages]);\n\n // Tier colors for display\n const tierColors: Record<QualityTier, string> = {\n none: theme.colors.muted,\n bronze: theme.colors.warning,\n silver: theme.colors.secondary,\n gold: theme.colors.accent,\n platinum: theme.colors.primary,\n };\n\n // Calculate overall tier from all packages\n const overallTier = packages.length > 0\n ? calculateQualityTier(\n packages.reduce((acc, pkg) => ({\n tests: acc.tests + pkg.metrics.tests / packages.length,\n deadCode: acc.deadCode + pkg.metrics.deadCode / packages.length,\n linting: acc.linting + pkg.metrics.linting / packages.length,\n formatting: acc.formatting + pkg.metrics.formatting / packages.length,\n types: acc.types + pkg.metrics.types / packages.length,\n documentation: acc.documentation + pkg.metrics.documentation / packages.length,\n }), { tests: 0, deadCode: 0, linting: 0, formatting: 0, types: 0, documentation: 0 })\n )\n : 'none';\n\n return (\n <div\n style={{\n fontFamily: theme.fonts.body,\n height: '100%',\n minHeight: 0,\n backgroundColor: theme.colors.background,\n color: theme.colors.text,\n overflowY: 'auto',\n boxSizing: 'border-box',\n }}\n >\n <div\n style={{\n padding: 20,\n display: 'flex',\n flexDirection: 'column',\n gap: 16,\n }}\n >\n {/* Header */}\n <div style={{ display: 'flex', alignItems: 'center', justifyContent: 'space-between', flexWrap: 'wrap', gap: 12 }}>\n <div style={{ display: 'flex', alignItems: 'center', gap: 12 }}>\n <Hexagon size={24} color={tierColors[overallTier]} />\n <h2\n style={{\n margin: 0,\n fontSize: 20,\n fontWeight: 600,\n color: theme.colors.text,\n }}\n >\n Code Quality\n </h2>\n <span\n title=\"Platinum: 90%+ avg | Gold: 75%+ | Silver: 60%+ | Bronze: 40%+\"\n style={{\n display: 'inline-flex',\n alignItems: 'center',\n justifyContent: 'center',\n width: 18,\n height: 18,\n borderRadius: '50%',\n border: `1px solid ${theme.colors.border}`,\n fontSize: 12,\n color: theme.colors.textMuted,\n cursor: 'help',\n }}\n >\n ?\n </span>\n {packages.length > 1 && (\n <span style={{\n fontSize: 14,\n color: theme.colors.textMuted,\n }}>\n {packages.length} packages\n </span>\n )}\n </div>\n {/* Metric dropdown for File City color mode */}\n <select\n value={selectedMetric ?? ''}\n onChange={(e) => handleMetricChange(e.target.value ? e.target.value as MetricKey : null)}\n style={{\n padding: '6px 12px',\n fontSize: 13,\n backgroundColor: theme.colors.background,\n color: theme.colors.text,\n border: `1px solid ${theme.colors.border}`,\n borderRadius: 4,\n cursor: 'pointer',\n outline: 'none',\n }}\n >\n <option value=\"\">Show in File City...</option>\n {METRIC_OPTIONS.map((option) => (\n <option key={option.key} value={option.key}>\n {option.label}\n </option>\n ))}\n </select>\n </div>\n\n {/* Quality Hexagons for each package */}\n <div style={{ display: 'flex', flexWrap: 'wrap', gap: 16, minHeight: 0 }}>\n {isLoading ? (\n <div style={{\n padding: 40,\n textAlign: 'center',\n color: theme.colors.textMuted,\n }}>\n Loading quality metrics...\n </div>\n ) : packages.length === 0 ? (\n <QualityEmptyState\n theme={theme}\n hasWorkflow={hasWorkflow}\n />\n ) : (\n packages.map((pkg) => {\n const tier = calculateQualityTier(pkg.metrics);\n // Use package path from slice data\n // For single-package repos, path is empty string (root)\n // For monorepos, path would be like \"packages/core\"\n const packagePath = pkg.path ?? '';\n return (\n <QualityHexagonExpandable\n key={pkg.name}\n metrics={pkg.metrics}\n tier={tier}\n theme={theme}\n packageName={pkg.name}\n packageVersion={pkg.version}\n packagePath={packagePath}\n onExpandChange={(expanded, info) => {\n // Emit package:select event for cross-panel filtering\n // When expanded, select this package; when collapsed, deselect\n events.emit({\n type: 'package:select',\n source: 'principal-ade.quality-hexagon-panel',\n timestamp: Date.now(),\n payload: expanded ? {\n packagePath: info.packagePath ?? '',\n packageName: info.packageName,\n } : null,\n });\n }}\n />\n );\n })\n )}\n </div>\n </div>\n </div>\n );\n};\n\n/**\n * QualityHexagonPanel - A panel for visualizing code quality metrics\n */\nexport const QualityHexagonPanel = QualityHexagonPanelContent;\n","import * as React from 'react';\nimport { cn } from '../lib/utils';\nimport type { Theme } from '@principal-ade/industry-theme';\nimport type { QualityMetrics } from '@principal-ai/codebase-composition';\nimport { QualityHexagon, calculateQualityTier, type QualityTier, type VertexHoverInfo, type MetricKey } from './QualityHexagon';\n\nexport type { VertexHoverInfo, MetricKey };\n\nconst METRIC_OPTIONS: Array<{ key: MetricKey; label: string }> = [\n { key: 'types', label: 'Types' },\n { key: 'documentation', label: 'Docs' },\n { key: 'tests', label: 'Tests' },\n { key: 'deadCode', label: 'Dead Code' },\n { key: 'formatting', label: 'Format' },\n { key: 'linting', label: 'Linting' },\n];\n\n/**\n * Represents a single package within a repository\n */\nexport interface PackageQualityItem {\n /** Package name (e.g., \"@acme/core\" or \"my-app\") */\n name: string;\n /** Optional version string */\n version?: string;\n /** Quality metrics for this package */\n metrics: QualityMetrics;\n}\n\n/**\n * Represents a repository with one or more packages\n */\nexport interface RepositoryQualityItem {\n /** Unique identifier for the repository */\n id: string;\n /** Repository name */\n name: string;\n /** Optional path to the repository */\n path?: string;\n /** Packages within this repository (monorepos have multiple) */\n packages: PackageQualityItem[];\n}\n\n/**\n * A flattened item for display in the grid\n */\nexport interface FlatGridItem {\n /** Unique key for React */\n key: string;\n /** Repository ID */\n repositoryId: string;\n /** Repository name */\n repositoryName: string;\n /** Repository path (for filtering in other panels) */\n repositoryPath?: string;\n /** Package name */\n packageName: string;\n /** Optional version */\n version?: string;\n /** Quality metrics */\n metrics: QualityMetrics;\n /** Calculated tier */\n tier: QualityTier;\n}\n\ninterface RepositoryQualityGridProps {\n /** Array of repositories with their packages */\n repositories: RepositoryQualityItem[];\n /** Theme from @principal-ade/industry-theme */\n theme: Theme;\n /** Callback when a grid item is clicked */\n onItemClick?: (item: FlatGridItem) => void;\n /** Callback when a hexagon vertex is clicked */\n onVertexClick?: (item: FlatGridItem, vertex: VertexHoverInfo) => void;\n /** Optional CSS class */\n className?: string;\n /** Show repository name in label (default: true) */\n showRepositoryName?: boolean;\n /** Show overall summary header (default: true) */\n showSummary?: boolean;\n}\n\ninterface RepositoryQualityGridItemProps {\n /** The flattened item to display */\n item: FlatGridItem;\n /** Theme */\n theme: Theme;\n /** Click handler for the card */\n onClick?: () => void;\n /** Click handler for hexagon vertices */\n onVertexClick?: (item: FlatGridItem, vertex: VertexHoverInfo) => void;\n /** Show repository name in label */\n showRepositoryName?: boolean;\n /** Selected metric to display (from dropdown) */\n selectedMetric?: MetricKey | null;\n /** Optional CSS class */\n className?: string;\n}\n\n/**\n * Flatten repositories into a single array of grid items\n */\nfunction flattenRepositories(repositories: RepositoryQualityItem[]): FlatGridItem[] {\n const items: FlatGridItem[] = [];\n\n for (const repo of repositories) {\n for (const pkg of repo.packages) {\n items.push({\n key: `${repo.id}:${pkg.name}`,\n repositoryId: repo.id,\n repositoryName: repo.name,\n repositoryPath: repo.path,\n packageName: pkg.name,\n version: pkg.version,\n metrics: pkg.metrics,\n tier: calculateQualityTier(pkg.metrics),\n });\n }\n }\n\n return items;\n}\n\n/**\n * Calculate overall tier from all items\n */\nfunction calculateOverallTier(items: FlatGridItem[]): QualityTier {\n if (items.length === 0) return 'none';\n\n const avgMetrics = items.reduce(\n (acc, item) => ({\n tests: acc.tests + item.metrics.tests / items.length,\n deadCode: acc.deadCode + item.metrics.deadCode / items.length,\n linting: acc.linting + item.metrics.linting / items.length,\n formatting: acc.formatting + item.metrics.formatting / items.length,\n types: acc.types + item.metrics.types / items.length,\n documentation: acc.documentation + item.metrics.documentation / items.length,\n }),\n { tests: 0, deadCode: 0, linting: 0, formatting: 0, types: 0, documentation: 0 }\n );\n\n return calculateQualityTier(avgMetrics);\n}\n\n/**\n * Format the display label for an item\n */\nfunction formatLabel(\n item: FlatGridItem,\n showRepositoryName: boolean,\n isSameAsRepo: boolean\n): string {\n if (!showRepositoryName || isSameAsRepo) {\n return item.packageName;\n }\n return `${item.repositoryName} / ${item.packageName}`;\n}\n\n/**\n * Individual grid item component\n */\n// Get color based on value (good/medium/poor)\nfunction getValueColor(value: number, key: MetricKey, theme: Theme): string {\n // For deadCode, lower is better (invert the logic)\n const effectiveValue = key === 'deadCode' ? 100 - value : value;\n\n if (effectiveValue >= 80) return theme.colors.success;\n if (effectiveValue >= 60) return theme.colors.warning;\n return theme.colors.error;\n}\n\nexport function RepositoryQualityGridItem({\n item,\n theme,\n onClick,\n onVertexClick,\n showRepositoryName = true,\n selectedMetric,\n className,\n}: RepositoryQualityGridItemProps) {\n const [hoveredVertex, setHoveredVertex] = React.useState<VertexHoverInfo | null>(null);\n const isSameAsRepo = item.packageName === item.repositoryName;\n const label = formatLabel(item, showRepositoryName, isSameAsRepo);\n\n const tierColors: Record<QualityTier, string> = {\n none: theme.colors.muted,\n bronze: theme.colors.warning,\n silver: theme.colors.secondary,\n gold: theme.colors.accent,\n platinum: theme.colors.primary,\n };\n\n // Get the display info - either from selected metric or hovered vertex\n const displayInfo = React.useMemo(() => {\n if (selectedMetric) {\n const option = METRIC_OPTIONS.find(o => o.key === selectedMetric);\n if (option) {\n const value = item.metrics[selectedMetric];\n return {\n label: option.label,\n value,\n valueColor: getValueColor(value, selectedMetric, theme),\n };\n }\n }\n if (hoveredVertex) {\n return {\n label: hoveredVertex.label,\n value: hoveredVertex.value,\n valueColor: getValueColor(hoveredVertex.value, hoveredVertex.key, theme),\n };\n }\n return null;\n }, [selectedMetric, hoveredVertex, item.metrics, theme]);\n\n return (\n <div\n className={cn(className)}\n onClick={onClick}\n style={{\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n gap: 8,\n padding: 12,\n borderRadius: 8,\n backgroundColor: theme.colors.surface,\n border: `1px solid ${theme.colors.border}`,\n cursor: onClick ? 'pointer' : 'default',\n transition: 'all 0.2s ease',\n }}\n onMouseEnter={(e) => {\n if (onClick) {\n e.currentTarget.style.borderColor = tierColors[item.tier];\n e.currentTarget.style.transform = 'translateY(-2px)';\n }\n }}\n onMouseLeave={(e) => {\n e.currentTarget.style.borderColor = theme.colors.border;\n e.currentTarget.style.transform = 'translateY(0)';\n setHoveredVertex(null);\n }}\n >\n {/* Metric info header */}\n <div\n style={{\n height: 24,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n gap: 8,\n width: '100%',\n minHeight: 24,\n }}\n >\n {displayInfo ? (\n <>\n <span\n style={{\n fontSize: 14,\n fontWeight: 500,\n color: theme.colors.text,\n }}\n >\n {displayInfo.label}\n </span>\n <span\n style={{\n fontSize: 14,\n fontWeight: 600,\n color: displayInfo.valueColor,\n }}\n >\n {displayInfo.value}%\n </span>\n </>\n ) : (\n <span style={{ fontSize: 12, color: theme.colors.textMuted }}>\n Hover a corner\n </span>\n )}\n </div>\n <div style={{ width: 200, height: 200 }}>\n <QualityHexagon\n metrics={item.metrics}\n tier={item.tier}\n theme={theme}\n showLabels={false}\n showValues={false}\n onVertexHover={setHoveredVertex}\n onVertexLeave={() => setHoveredVertex(null)}\n onVertexClick={onVertexClick ? (vertex) => onVertexClick(item, vertex) : undefined}\n />\n </div>\n <div\n style={{\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n gap: 2,\n }}\n >\n <span\n style={{\n fontSize: 12,\n fontWeight: 500,\n color: theme.colors.text,\n textAlign: 'center',\n }}\n >\n {label}\n </span>\n {item.version && (\n <span\n style={{\n fontSize: 10,\n color: theme.colors.textMuted,\n }}\n >\n v{item.version}\n </span>\n )}\n </div>\n </div>\n );\n}\n\n/**\n * RepositoryQualityGrid - Displays a flat grid of quality hexagons\n * for multiple repositories and their packages.\n *\n * Each hexagon shows the quality metrics for a single package,\n * labeled with \"repo / package\" format for clarity.\n */\n// Calculate average score for an item (with deadCode inverted)\nfunction calculateAverageScore(metrics: QualityMetrics): number {\n const adjusted = { ...metrics };\n adjusted.deadCode = 100 - adjusted.deadCode;\n return Object.values(adjusted).reduce((a, b) => a + b, 0) / 6;\n}\n\nexport function RepositoryQualityGrid({\n repositories,\n theme,\n onItemClick,\n onVertexClick,\n className,\n showRepositoryName = true,\n showSummary = true,\n}: RepositoryQualityGridProps) {\n const [selectedMetric, setSelectedMetric] = React.useState<MetricKey | null>(null);\n const items = React.useMemo(() => flattenRepositories(repositories), [repositories]);\n const overallTier = React.useMemo(() => calculateOverallTier(items), [items]);\n\n // Sort items based on selected metric or average\n const sortedItems = React.useMemo(() => {\n return [...items].sort((a, b) => {\n if (selectedMetric) {\n // Sort by selected metric (for deadCode, lower is better so invert)\n const aVal = selectedMetric === 'deadCode'\n ? 100 - a.metrics[selectedMetric]\n : a.metrics[selectedMetric];\n const bVal = selectedMetric === 'deadCode'\n ? 100 - b.metrics[selectedMetric]\n : b.metrics[selectedMetric];\n return bVal - aVal; // Descending (best first)\n } else {\n // Sort by average score\n return calculateAverageScore(b.metrics) - calculateAverageScore(a.metrics);\n }\n });\n }, [items, selectedMetric]);\n\n const tierColors: Record<QualityTier, string> = {\n none: theme.colors.muted,\n bronze: theme.colors.warning,\n silver: theme.colors.secondary,\n gold: theme.colors.accent,\n platinum: theme.colors.primary,\n };\n\n const tierLabels: Record<QualityTier, string> = {\n none: 'No Data',\n bronze: 'Bronze',\n silver: 'Silver',\n gold: 'Gold',\n platinum: 'Platinum',\n };\n\n if (items.length === 0) {\n return (\n <div\n className={cn(className)}\n style={{\n padding: 40,\n textAlign: 'center',\n color: theme.colors.textMuted,\n backgroundColor: theme.colors.background,\n borderRadius: 8,\n }}\n >\n No repositories to display\n </div>\n );\n }\n\n return (\n <div\n className={cn(className)}\n style={{\n display: 'flex',\n flexDirection: 'column',\n gap: 16,\n backgroundColor: theme.colors.background,\n fontFamily: theme.fonts.body,\n }}\n >\n {/* Summary Header */}\n {showSummary && (\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'space-between',\n flexWrap: 'wrap',\n gap: 12,\n padding: '12px 16px',\n backgroundColor: theme.colors.surface,\n border: `1px solid ${theme.colors.border}`,\n }}\n >\n <div style={{ display: 'flex', alignItems: 'center', gap: 12 }}>\n <span\n style={{\n fontSize: 14,\n fontWeight: 500,\n color: theme.colors.text,\n }}\n >\n {items.length} {items.length === 1 ? 'package' : 'packages'}\n </span>\n <span style={{ color: theme.colors.textMuted }}>•</span>\n <span\n style={{\n fontSize: 14,\n color: theme.colors.textMuted,\n }}\n >\n {repositories.length} {repositories.length === 1 ? 'repository' : 'repositories'}\n </span>\n </div>\n <div style={{ display: 'flex', alignItems: 'center', gap: 12 }}>\n {/* Metric dropdown */}\n <select\n value={selectedMetric ?? ''}\n onChange={(e) => setSelectedMetric(e.target.value ? e.target.value as MetricKey : null)}\n style={{\n padding: '4px 8px',\n fontSize: 13,\n backgroundColor: theme.colors.background,\n color: theme.colors.text,\n border: `1px solid ${theme.colors.border}`,\n borderRadius: 4,\n cursor: 'pointer',\n outline: 'none',\n }}\n >\n <option value=\"\">Select metric...</option>\n {METRIC_OPTIONS.map((option) => (\n <option key={option.key} value={option.key}>\n {option.label}\n </option>\n ))}\n </select>\n {/* Tier badge */}\n <div\n style={{\n display: 'flex',\n alignItems: 'center',\n gap: 8,\n padding: '4px 12px',\n backgroundColor: theme.colors.backgroundLight,\n borderRadius: 16,\n border: `1px solid ${tierColors[overallTier]}`,\n }}\n >\n <span\n style={{\n width: 8,\n height: 8,\n borderRadius: '50%',\n backgroundColor: tierColors[overallTier],\n }}\n />\n <span\n style={{\n fontSize: 13,\n fontWeight: 500,\n color: tierColors[overallTier],\n }}\n >\n {tierLabels[overallTier]}\n </span>\n </div>\n </div>\n </div>\n )}\n\n {/* Grid of Items */}\n <div\n style={{\n display: 'grid',\n gridTemplateColumns: 'repeat(auto-fill, minmax(220px, 1fr))',\n gap: 12,\n padding: 16,\n }}\n >\n {sortedItems.map((item) => (\n <RepositoryQualityGridItem\n key={item.key}\n item={item}\n theme={theme}\n onClick={onItemClick ? () => onItemClick(item) : undefined}\n onVertexClick={onVertexClick}\n showRepositoryName={showRepositoryName}\n selectedMetric={selectedMetric}\n />\n ))}\n </div>\n </div>\n );\n}\n","import React from 'react';\nimport { useTheme } from '@principal-ade/industry-theme';\nimport type { PanelComponentProps } from '../types';\nimport type { QualityMetrics } from '@principal-ai/codebase-composition';\nimport {\n RepositoryQualityGrid,\n type RepositoryQualityItem,\n type FlatGridItem,\n type VertexHoverInfo,\n} from '../components/RepositoryQualityGrid';\nimport { QualityEmptyState } from '../components/QualityEmptyState';\n\n// Repository quality data from slice\ninterface RepositoryQualityData {\n id: string;\n name: string;\n path?: string;\n packages: Array<{\n name: string;\n version?: string;\n metrics: QualityMetrics;\n }>;\n}\n\n// Slice data shape\ninterface RepositoriesQualitySliceData {\n repositories: RepositoryQualityData[];\n lastUpdated: string;\n}\n\n/**\n * RepositoryQualityGridPanelContent - Internal component that uses theme\n */\nconst RepositoryQualityGridPanelContent: React.FC<PanelComponentProps> = ({\n context,\n events,\n}) => {\n const { theme } = useTheme();\n\n // Track currently selected item for toggle behavior\n const [selectedItemKey, setSelectedItemKey] = React.useState<string | null>(null);\n\n // Get repositories quality data from context if available\n const qualitySlice = context.getSlice<RepositoriesQualitySliceData>('repositoriesQuality');\n const isLoading = qualitySlice?.loading ?? false;\n\n // Determine repositories to display\n const repositories: RepositoryQualityItem[] = React.useMemo(() => {\n if (qualitySlice?.data?.repositories) {\n return qualitySlice.data.repositories;\n }\n return [];\n }, [qualitySlice?.data?.repositories]);\n\n // Handle item click\n const handleItemClick = (item: FlatGridItem) => {\n const isDeselecting = selectedItemKey === item.key;\n\n events.emit({\n type: 'principal-ade.repository-quality-grid:item:click',\n source: 'principal-ade.repository-quality-grid-panel',\n timestamp: Date.now(),\n payload: isDeselecting ? null : {\n repositoryId: item.repositoryId,\n repositoryName: item.repositoryName,\n packageName: item.packageName,\n tier: item.tier,\n },\n });\n\n // Emit package:select event for cross-panel filtering (e.g., File City)\n // Clicking the same item again deselects (sends null payload)\n events.emit({\n type: 'package:select',\n source: 'principal-ade.repository-quality-grid-panel',\n timestamp: Date.now(),\n payload: isDeselecting ? null : (item.repositoryPath ? {\n packagePath: item.repositoryPath,\n packageName: item.packageName,\n } : null),\n });\n\n setSelectedItemKey(isDeselecting ? null : item.key);\n };\n\n // Handle vertex click\n const handleVertexClick = (item: FlatGridItem, vertex: VertexHoverInfo) => {\n events.emit({\n type: 'principal-ade.repository-quality-grid:vertex:click',\n source: 'principal-ade.repository-quality-grid-panel',\n timestamp: Date.now(),\n payload: {\n repositoryId: item.repositoryId,\n repositoryName: item.repositoryName,\n packageName: item.packageName,\n metric: vertex.key,\n label: vertex.label,\n value: vertex.value,\n },\n });\n };\n\n // Handle refresh\n const handleRefresh = async () => {\n if (context.hasSlice('repositoriesQuality')) {\n await context.refresh('workspace', 'repositoriesQuality');\n }\n };\n\n // Subscribe to events\n React.useEffect(() => {\n const unsubscribers = [\n events.on('principal-ade.repository-quality-grid:refresh', async () => {\n await handleRefresh();\n }),\n ];\n\n return () => unsubscribers.forEach((unsub) => unsub());\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [events, context]);\n\n return (\n <div\n style={{\n fontFamily: theme.fonts.body,\n height: '100%',\n minHeight: 0,\n backgroundColor: theme.colors.background,\n color: theme.colors.text,\n overflowY: 'auto',\n boxSizing: 'border-box',\n }}\n >\n {isLoading ? (\n <div\n style={{\n padding: 40,\n textAlign: 'center',\n color: theme.colors.textMuted,\n }}\n >\n Loading repository quality metrics...\n </div>\n ) : repositories.length === 0 ? (\n <div style={{ padding: 20 }}>\n <QualityEmptyState theme={theme} hasWorkflow={false} />\n </div>\n ) : (\n <RepositoryQualityGrid\n repositories={repositories}\n theme={theme}\n onItemClick={handleItemClick}\n onVertexClick={handleVertexClick}\n showRepositoryName={true}\n showSummary={true}\n />\n )}\n </div>\n );\n};\n\n/**\n * RepositoryQualityGridPanel - A panel for visualizing quality metrics\n * across multiple repositories in a flat grid layout.\n */\nexport const RepositoryQualityGridPanel = RepositoryQualityGridPanelContent;\n","import { QualityHexagonPanel } from './panels/QualityHexagonPanel';\nimport { RepositoryQualityGridPanel } from './panels/RepositoryQualityGridPanel';\nimport type { PanelDefinition, PanelContextValue } from './types';\n\n/**\n * Export array of panel definitions.\n * This is the required export for panel extensions.\n */\nexport const panels: PanelDefinition[] = [\n {\n metadata: {\n id: 'principal-ade.quality-hexagon-panel',\n name: 'Code Quality',\n icon: '⬡',\n version: '0.1.0',\n author: 'Principal ADE',\n description:\n 'Visualize code quality metrics using a hexagonal radar chart showing tests, types, linting, formatting, documentation, and dead code.',\n slices: ['quality'],\n tools: [],\n },\n component: QualityHexagonPanel,\n\n onMount: async (context: PanelContextValue) => {\n console.log(\n 'Quality Hexagon Panel mounted',\n context.currentScope.repository?.path\n );\n\n if (context.hasSlice('quality') && !context.isSliceLoading('quality')) {\n await context.refresh('repository', 'quality');\n }\n },\n\n onUnmount: async (_context: PanelContextValue) => {\n console.log('Quality Hexagon Panel unmounting');\n },\n },\n {\n metadata: {\n id: 'principal-ade.repository-quality-grid-panel',\n name: 'Repository Quality Grid',\n icon: '⬡',\n version: '0.1.0',\n author: 'Principal ADE',\n description:\n 'Display quality metrics for multiple repositories in a flat grid layout. Supports filtering by metric type, sorting, and comparing quality across projects.',\n slices: ['repositoriesQuality'],\n tools: [],\n },\n component: RepositoryQualityGridPanel,\n\n onMount: async (context: PanelContextValue) => {\n console.log('Repository Quality Grid Panel mounted');\n\n if (context.hasSlice('repositoriesQuality') && !context.isSliceLoading('repositoriesQuality')) {\n await context.refresh('workspace', 'repositoriesQuality');\n }\n },\n\n onUnmount: async (_context: PanelContextValue) => {\n console.log('Repository Quality Grid Panel unmounting');\n },\n },\n];\n\n/**\n * Optional: Called once when the entire package is loaded.\n */\nexport const onPackageLoad = async () => {\n console.log('Panel package loaded - Code Quality Panels');\n};\n\n/**\n * Optional: Called once when the package is unloaded.\n */\nexport const onPackageUnload = async () => {\n console.log('Panel package unloading - Code Quality Panels');\n};\n\n// Export components for direct usage\nexport {\n QualityHexagon,\n QualityHexagonCompact,\n QualityHexagonDetailed,\n QualityHexagonExpandable,\n calculateQualityTier,\n type QualityMetrics,\n type QualityTier,\n // Multi-repository grid components\n RepositoryQualityGrid,\n RepositoryQualityGridItem,\n type RepositoryQualityItem,\n type PackageQualityItem,\n type FlatGridItem,\n} from './components';\n\n// Export panels\nexport { QualityHexagonPanel } from './panels/QualityHexagonPanel';\nexport { RepositoryQualityGridPanel } from './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D;","x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9,10,11,12,13]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@principal-ade/code-quality-panels",
3
- "version": "0.1.12",
3
+ "version": "0.1.13",
4
4
  "description": "Code quality visualization panels including QualityHexagon components",
5
5
  "type": "module",
6
6
  "main": "dist/panels.bundle.js",