platformforge 0.1.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (659) hide show
  1. platformforge/__init__.py +7 -0
  2. platformforge/__main__.py +5 -0
  3. platformforge/_forge_portal.py +913 -0
  4. platformforge/_graphstudio.py +376 -0
  5. platformforge/_graphview.py +181 -0
  6. platformforge/_installkit.py +1706 -0
  7. platformforge/agents/__init__.py +156 -0
  8. platformforge/agents/bench.py +61 -0
  9. platformforge/agents/contextpack.py +137 -0
  10. platformforge/agents/contracts.py +394 -0
  11. platformforge/agents/coordinators.py +98 -0
  12. platformforge/agents/critic.py +113 -0
  13. platformforge/agents/debate.py +161 -0
  14. platformforge/agents/executors.py +160 -0
  15. platformforge/agents/guardian.py +48 -0
  16. platformforge/agents/mirrors.py +240 -0
  17. platformforge/agents/orchestrator.py +295 -0
  18. platformforge/agents/planner.py +116 -0
  19. platformforge/agents/playbook.py +51 -0
  20. platformforge/agents/referee.py +132 -0
  21. platformforge/agents/reviewers.py +113 -0
  22. platformforge/agents/roster.py +893 -0
  23. platformforge/agents/runledger.py +85 -0
  24. platformforge/agents/runstore.py +74 -0
  25. platformforge/agents/specialists.py +73 -0
  26. platformforge/agents/taskspec.py +94 -0
  27. platformforge/agents/uniqueness.py +115 -0
  28. platformforge/agents/verifier.py +106 -0
  29. platformforge/aiplat/__init__.py +4 -0
  30. platformforge/aiplat/models.py +175 -0
  31. platformforge/analytics/__init__.py +6 -0
  32. platformforge/analytics/capacity.py +109 -0
  33. platformforge/analytics/debt.py +92 -0
  34. platformforge/analytics/dx.py +69 -0
  35. platformforge/analytics/finops_v4.py +171 -0
  36. platformforge/analytics/goldenpath.py +131 -0
  37. platformforge/analytics/history.py +233 -0
  38. platformforge/analytics/measurement.py +149 -0
  39. platformforge/analytics/models.py +127 -0
  40. platformforge/analytics/opsanalytics.py +119 -0
  41. platformforge/analytics/policyintel.py +139 -0
  42. platformforge/analytics/reliability.py +106 -0
  43. platformforge/analytics/soak.py +135 -0
  44. platformforge/analytics/store.py +254 -0
  45. platformforge/bench.py +174 -0
  46. platformforge/cases/__init__.py +13 -0
  47. platformforge/cases/casefile.py +106 -0
  48. platformforge/cases/context_audit.py +134 -0
  49. platformforge/cases/ledgers.py +174 -0
  50. platformforge/cases/replay.py +142 -0
  51. platformforge/cases/routing_audit.py +162 -0
  52. platformforge/caveman/__init__.py +11 -0
  53. platformforge/caveman/compress.py +156 -0
  54. platformforge/cicd/__init__.py +16 -0
  55. platformforge/cicd/backstage.py +51 -0
  56. platformforge/cicd/dockerfile.py +64 -0
  57. platformforge/cicd/github_actions.py +122 -0
  58. platformforge/cicd/gitlab_ci.py +56 -0
  59. platformforge/cicd/gitops.py +130 -0
  60. platformforge/cli/__init__.py +0 -0
  61. platformforge/cli/fleetcmd.py +457 -0
  62. platformforge/cli/main.py +3832 -0
  63. platformforge/cloud/__init__.py +8 -0
  64. platformforge/cloud/aws.py +254 -0
  65. platformforge/cloud/common.py +69 -0
  66. platformforge/cloud/multicloud.py +143 -0
  67. platformforge/collect/__init__.py +11 -0
  68. platformforge/collect/detect.py +254 -0
  69. platformforge/context/__init__.py +10 -0
  70. platformforge/context/capsule.py +60 -0
  71. platformforge/context/gateway.py +227 -0
  72. platformforge/context/refs.py +49 -0
  73. platformforge/context/sufficiency.py +50 -0
  74. platformforge/core/__init__.py +1 -0
  75. platformforge/core/hashing.py +39 -0
  76. platformforge/core/ownership.py +220 -0
  77. platformforge/core/receipts.py +74 -0
  78. platformforge/core/redaction.py +97 -0
  79. platformforge/core/store.py +119 -0
  80. platformforge/core/workspace.py +89 -0
  81. platformforge/data/contracts/agent-handoff.schema.json +26 -0
  82. platformforge/data/contracts/agent-run.schema.json +27 -0
  83. platformforge/data/contracts/agent-spec.schema.json +43 -0
  84. platformforge/data/contracts/capability.schema.json +23 -0
  85. platformforge/data/contracts/change-event.schema.json +22 -0
  86. platformforge/data/contracts/change-intent.schema.json +62 -0
  87. platformforge/data/contracts/change-plan.schema.json +43 -0
  88. platformforge/data/contracts/collector-receipt.schema.json +36 -0
  89. platformforge/data/contracts/context-pack.schema.json +29 -0
  90. platformforge/data/contracts/debate.schema.json +31 -0
  91. platformforge/data/contracts/distribution-manifest-v1.schema.json +81 -0
  92. platformforge/data/contracts/drift-event.schema.json +21 -0
  93. platformforge/data/contracts/fact.schema.json +35 -0
  94. platformforge/data/contracts/finding.schema.json +20 -0
  95. platformforge/data/contracts/graph-v2.schema.json +67 -0
  96. platformforge/data/contracts/graph.schema.json +40 -0
  97. platformforge/data/contracts/install-receipt-v1.schema.json +49 -0
  98. platformforge/data/contracts/observation.schema.json +93 -0
  99. platformforge/data/contracts/receipt.schema.json +21 -0
  100. platformforge/data/contracts/recommendation.schema.json +32 -0
  101. platformforge/data/contracts/refusal.schema.json +16 -0
  102. platformforge/data/contracts/slo-contract.schema.json +25 -0
  103. platformforge/data/contracts/task-spec.schema.json +37 -0
  104. platformforge/data/contracts/workspace-manifest-v1.schema.json +62 -0
  105. platformforge/data/evals/cases/agent-budget-exhaustion/case.yaml +6 -0
  106. platformforge/data/evals/cases/agent-conflicting-specialists/case.yaml +11 -0
  107. platformforge/data/evals/cases/agent-fleet-optimization/case.yaml +13 -0
  108. platformforge/data/evals/cases/agent-host-no-subagents/case.yaml +6 -0
  109. platformforge/data/evals/cases/agent-incident-multi/case.yaml +13 -0
  110. platformforge/data/evals/cases/agent-missing-evidence/case.yaml +6 -0
  111. platformforge/data/evals/cases/agent-multi-domain-audit/case.yaml +14 -0
  112. platformforge/data/evals/cases/agent-production-change/case.yaml +15 -0
  113. platformforge/data/evals/cases/agent-security-mandatory/case.yaml +12 -0
  114. platformforge/data/evals/cases/agent-simple-iac/case.yaml +14 -0
  115. platformforge/data/evals/cases/approval-integrity-seal/case.yaml +6 -0
  116. platformforge/data/evals/cases/capacity-hot/case.yaml +7 -0
  117. platformforge/data/evals/cases/capacity-hot/fixture/capacity.json +5 -0
  118. platformforge/data/evals/cases/catalog-noowner/case.yaml +7 -0
  119. platformforge/data/evals/cases/catalog-noowner/fixture/catalog-info.yaml +6 -0
  120. platformforge/data/evals/cases/contract-fact/case.yaml +5 -0
  121. platformforge/data/evals/cases/contract-fact/fixture/doc.json +2 -0
  122. platformforge/data/evals/cases/cosign-unverified/case.yaml +8 -0
  123. platformforge/data/evals/cases/cosign-unverified/fixture/sig.json +33 -0
  124. platformforge/data/evals/cases/expected-delta-refusal/case.yaml +6 -0
  125. platformforge/data/evals/cases/finops-noattr/case.yaml +9 -0
  126. platformforge/data/evals/cases/finops-noattr/fixture/costs.json +7 -0
  127. platformforge/data/evals/cases/fleet-inv-absent-allocation-unknown/case.yaml +7 -0
  128. platformforge/data/evals/cases/fleet-inv-centrality-not-criticality/case.yaml +7 -0
  129. platformforge/data/evals/cases/fleet-inv-correlation-not-causality/case.yaml +7 -0
  130. platformforge/data/evals/cases/fleet-inv-dx-no-person-metrics/case.yaml +7 -0
  131. platformforge/data/evals/cases/fleet-inv-federation-restricted-denied/case.yaml +7 -0
  132. platformforge/data/evals/cases/fleet-inv-federation-secret-denied/case.yaml +7 -0
  133. platformforge/data/evals/cases/fleet-inv-history-window-deterministic/case.yaml +7 -0
  134. platformforge/data/evals/cases/fleet-inv-low-util-not-deletable/case.yaml +7 -0
  135. platformforge/data/evals/cases/fleet-inv-member-key-deterministic/case.yaml +7 -0
  136. platformforge/data/evals/cases/fleet-inv-missing-denominator/case.yaml +7 -0
  137. platformforge/data/evals/cases/fleet-inv-partial-coverage-visible/case.yaml +7 -0
  138. platformforge/data/evals/cases/fleet-inv-plan-changeintent-only/case.yaml +7 -0
  139. platformforge/data/evals/cases/fleet-inv-report-all-cited/case.yaml +7 -0
  140. platformforge/data/evals/cases/fleet-inv-small-sample-confidence/case.yaml +7 -0
  141. platformforge/data/evals/cases/fleet-inv-uncertain-optimization-suppressed/case.yaml +7 -0
  142. platformforge/data/evals/cases/gha-dangerous/case.yaml +12 -0
  143. platformforge/data/evals/cases/gha-dangerous/fixture/.github/workflows/ci.yaml +11 -0
  144. platformforge/data/evals/cases/gitops-v2/case.yaml +11 -0
  145. platformforge/data/evals/cases/gitops-v2/fixture/argo.yaml +41 -0
  146. platformforge/data/evals/cases/graph-k8s-blast/case.yaml +7 -0
  147. platformforge/data/evals/cases/graph-k8s-blast/fixture/deploy.yaml +15 -0
  148. platformforge/data/evals/cases/iac-module-nopin/case.yaml +8 -0
  149. platformforge/data/evals/cases/iac-module-nopin/fixture/main.tf +3 -0
  150. platformforge/data/evals/cases/iac-plan-replace/case.yaml +8 -0
  151. platformforge/data/evals/cases/iac-plan-replace/fixture/plan.json +12 -0
  152. platformforge/data/evals/cases/iac-sg-open/case.yaml +8 -0
  153. platformforge/data/evals/cases/iac-sg-open/fixture/main.tf +9 -0
  154. platformforge/data/evals/cases/iam-oidc/case.yaml +8 -0
  155. platformforge/data/evals/cases/iam-oidc/fixture/policy.json +11 -0
  156. platformforge/data/evals/cases/iam-wildcard-positive/case.yaml +8 -0
  157. platformforge/data/evals/cases/iam-wildcard-positive/fixture/policy.json +3 -0
  158. platformforge/data/evals/cases/k8s-bad-actor/case.yaml +19 -0
  159. platformforge/data/evals/cases/k8s-bad-actor/fixture/app.yaml +97 -0
  160. platformforge/data/evals/cases/k8s-beta-api/case.yaml +8 -0
  161. platformforge/data/evals/cases/k8s-beta-api/fixture/cr.yaml +7 -0
  162. platformforge/data/evals/cases/k8s-dep-api-boundary/case.yaml +15 -0
  163. platformforge/data/evals/cases/k8s-dep-api-boundary/fixture/app.yaml +25 -0
  164. platformforge/data/evals/cases/k8s-dep-api-clean/case.yaml +12 -0
  165. platformforge/data/evals/cases/k8s-dep-api-clean/fixture/app.yaml +29 -0
  166. platformforge/data/evals/cases/k8s-dep-api-unknown/case.yaml +11 -0
  167. platformforge/data/evals/cases/k8s-dep-api-unknown/fixture/app.yaml +25 -0
  168. platformforge/data/evals/cases/k8s-dep-api-v120/case.yaml +12 -0
  169. platformforge/data/evals/cases/k8s-dep-api-v120/fixture/app.yaml +25 -0
  170. platformforge/data/evals/cases/k8s-dep-api-v129/case.yaml +9 -0
  171. platformforge/data/evals/cases/k8s-dep-api-v129/fixture/app.yaml +25 -0
  172. platformforge/data/evals/cases/k8s-hpa-noreq/case.yaml +8 -0
  173. platformforge/data/evals/cases/k8s-hpa-noreq/fixture/app.yaml +28 -0
  174. platformforge/data/evals/cases/k8s-limits-boundary/case.yaml +10 -0
  175. platformforge/data/evals/cases/k8s-limits-boundary/fixture/app.yaml +15 -0
  176. platformforge/data/evals/cases/k8s-limits-negative/case.yaml +8 -0
  177. platformforge/data/evals/cases/k8s-limits-negative/fixture/deploy.yaml +15 -0
  178. platformforge/data/evals/cases/k8s-limits-positive/case.yaml +8 -0
  179. platformforge/data/evals/cases/k8s-limits-positive/fixture/deploy.yaml +14 -0
  180. platformforge/data/evals/cases/k8s-nopdb/case.yaml +7 -0
  181. platformforge/data/evals/cases/k8s-nopdb/fixture/app.yaml +34 -0
  182. platformforge/data/evals/cases/knowledge-registry/case.yaml +10 -0
  183. platformforge/data/evals/cases/kyverno-dep/case.yaml +10 -0
  184. platformforge/data/evals/cases/kyverno-dep/fixture/pol.yaml +18 -0
  185. platformforge/data/evals/cases/kyverno-legacy/case.yaml +8 -0
  186. platformforge/data/evals/cases/kyverno-legacy/fixture/pol.yaml +7 -0
  187. platformforge/data/evals/cases/live-aws-collect/case.yaml +11 -0
  188. platformforge/data/evals/cases/live-aws-collect/fixture/aws/ec2_describe-vpcs.json +15 -0
  189. platformforge/data/evals/cases/live-aws-collect/fixture/aws/iam_list-users.denied.txt +1 -0
  190. platformforge/data/evals/cases/live-aws-collect/fixture/aws/sts_get-caller-identity.json +5 -0
  191. platformforge/data/evals/cases/live-drift/case.yaml +8 -0
  192. platformforge/data/evals/cases/live-drift/fixture/after.json +22 -0
  193. platformforge/data/evals/cases/live-drift/fixture/before.json +22 -0
  194. platformforge/data/evals/cases/live-incident/case.yaml +7 -0
  195. platformforge/data/evals/cases/live-incident/fixture/changes.json +8 -0
  196. platformforge/data/evals/cases/live-incident/fixture/incident.json +7 -0
  197. platformforge/data/evals/cases/live-k8s-collect/case.yaml +10 -0
  198. platformforge/data/evals/cases/live-k8s-collect/fixture/kubectl/get_configmaps.denied.txt +1 -0
  199. platformforge/data/evals/cases/live-k8s-collect/fixture/kubectl/get_deployments.apps.json +25 -0
  200. platformforge/data/evals/cases/live-k8s-collect/fixture/kubectl/get_pods.json +17 -0
  201. platformforge/data/evals/cases/live-k8s-collect/fixture/kubectl/get_secrets.json +13 -0
  202. platformforge/data/evals/cases/live-multicluster/case.yaml +7 -0
  203. platformforge/data/evals/cases/live-multicluster/fixture/clusters.json +6 -0
  204. platformforge/data/evals/cases/live-plan/case.yaml +7 -0
  205. platformforge/data/evals/cases/live-plan/fixture/drift.json +8 -0
  206. platformforge/data/evals/cases/live-reconcile/case.yaml +7 -0
  207. platformforge/data/evals/cases/live-reconcile/fixture/desired.json +7 -0
  208. platformforge/data/evals/cases/live-reconcile/fixture/observed.json +18 -0
  209. platformforge/data/evals/cases/live-secrets-boundary/case.yaml +8 -0
  210. platformforge/data/evals/cases/live-secrets-boundary/fixture/envelope.json +16 -0
  211. platformforge/data/evals/cases/live-temporal-graph/case.yaml +10 -0
  212. platformforge/data/evals/cases/live-temporal-graph/fixture/graph.json +22 -0
  213. platformforge/data/evals/cases/ops-approval/case.yaml +6 -0
  214. platformforge/data/evals/cases/ops-convergence/case.yaml +6 -0
  215. platformforge/data/evals/cases/ops-execution-safety/case.yaml +6 -0
  216. platformforge/data/evals/cases/ops-intent/case.yaml +6 -0
  217. platformforge/data/evals/cases/ops-planning/case.yaml +6 -0
  218. platformforge/data/evals/cases/ops-policy/case.yaml +6 -0
  219. platformforge/data/evals/cases/ops-rollback/case.yaml +6 -0
  220. platformforge/data/evals/cases/ops-verification/case.yaml +6 -0
  221. platformforge/data/evals/cases/rollback-argocd-revision/case.yaml +6 -0
  222. platformforge/data/evals/cases/rollback-blind-inverse/case.yaml +6 -0
  223. platformforge/data/evals/cases/rollback-git-commit/case.yaml +6 -0
  224. platformforge/data/evals/cases/rollback-impossible/case.yaml +6 -0
  225. platformforge/data/evals/cases/rollback-k8s-annotation-restore/case.yaml +6 -0
  226. platformforge/data/evals/cases/rollback-k8s-scale/case.yaml +6 -0
  227. platformforge/data/evals/cases/rollback-material-tamper/case.yaml +6 -0
  228. platformforge/data/evals/cases/rollback-terraform-replan/case.yaml +6 -0
  229. platformforge/data/evals/cases/rollback-unknown/case.yaml +6 -0
  230. platformforge/data/evals/cases/routing-specialist/case.yaml +9 -0
  231. platformforge/data/evals/cases/rtk-roundtrip/case.yaml +5 -0
  232. platformforge/data/evals/cases/rtk-roundtrip/fixture/verbose.txt +300 -0
  233. platformforge/data/evals/cases/sbom-vuln/case.yaml +9 -0
  234. platformforge/data/evals/cases/sbom-vuln/fixture/sbom.json +9 -0
  235. platformforge/data/evals/cases/secret-prose-mixed/fixture/app.env +1 -0
  236. platformforge/data/evals/cases/secret-prose-mixed/fixture/policy-notes.md +7 -0
  237. platformforge/data/evals/cases/secrets-noleak/case.yaml +5 -0
  238. platformforge/data/evals/cases/secrets-noleak/fixture/app.env +2 -0
  239. platformforge/data/evals/cases/slo-fastburn/case.yaml +8 -0
  240. platformforge/data/evals/cases/slo-fastburn/fixture/events.yaml +2 -0
  241. platformforge/data/evals/cases/slo-fastburn/fixture/slo.yaml +4 -0
  242. platformforge/data/evals/cases/slo-noinput/case.yaml +8 -0
  243. platformforge/data/evals/cases/slo-noinput/fixture/events.yaml +1 -0
  244. platformforge/data/evals/cases/slo-noinput/fixture/slo.yaml +4 -0
  245. platformforge/data/evals/cases/sot-conflict/case.yaml +6 -0
  246. platformforge/data/evals/cases/token-budget/case.yaml +6 -0
  247. platformforge/data/evals/cases/token-budget/fixture/big.py +50 -0
  248. platformforge/data/evals/cases/xr-delete/case.yaml +8 -0
  249. platformforge/data/evals/cases/xr-delete/fixture/xr.yaml +10 -0
  250. platformforge/data/evals/cases/xr-graph-chain/case.yaml +8 -0
  251. platformforge/data/evals/cases/xr-graph-chain/fixture/xrd.yaml +90 -0
  252. platformforge/data/evals/cases/xr-negative-crd/case.yaml +8 -0
  253. platformforge/data/evals/cases/xr-negative-crd/fixture/widget.yaml +19 -0
  254. platformforge/data/evals/cases/xr-upbound-mr/case.yaml +8 -0
  255. platformforge/data/evals/cases/xr-upbound-mr/fixture/bucket.yaml +12 -0
  256. platformforge/data/evals/qpt-bench/change-review/case.yaml +5 -0
  257. platformforge/data/evals/qpt-bench/change-review/fixture/plan.json +9 -0
  258. platformforge/data/evals/qpt-bench/gha-security/case.yaml +5 -0
  259. platformforge/data/evals/qpt-bench/gha-security/fixture/ci.yml +10 -0
  260. platformforge/data/evals/qpt-bench/iam-investigate/case.yaml +5 -0
  261. platformforge/data/evals/qpt-bench/iam-investigate/fixture/policy.json +6 -0
  262. platformforge/data/evals/qpt-bench/incident-analysis/case.yaml +5 -0
  263. platformforge/data/evals/qpt-bench/incident-analysis/fixture/query.json +5 -0
  264. platformforge/data/evals/qpt-bench/incident-analysis/fixture/rules.yaml +6 -0
  265. platformforge/data/evals/qpt-bench/k8s-review/case.yaml +6 -0
  266. platformforge/data/evals/qpt-bench/k8s-review/fixture/deploy.yaml +15 -0
  267. platformforge/data/evals/qpt-bench/tf-security/case.yaml +5 -0
  268. platformforge/data/evals/qpt-bench/tf-security/fixture/main.tf +17 -0
  269. platformforge/data/knowledge/aws/eks.yaml +20 -0
  270. platformforge/data/knowledge/aws/iam.yaml +28 -0
  271. platformforge/data/knowledge/aws/network-exposure.yaml +19 -0
  272. platformforge/data/knowledge/aws/organizations.yaml +19 -0
  273. platformforge/data/knowledge/crossplane/composition-providers.yaml +20 -0
  274. platformforge/data/knowledge/crossplane/managed-resources.yaml +26 -0
  275. platformforge/data/knowledge/crossplane/v1-v2.yaml +25 -0
  276. platformforge/data/knowledge/kubernetes/api-deprecations.yaml +33 -0
  277. platformforge/data/knowledge/kubernetes/autoscaling-rbac.yaml +27 -0
  278. platformforge/data/knowledge/kubernetes/gateway-api.yaml +20 -0
  279. platformforge/data/knowledge/kubernetes/pod-security.yaml +26 -0
  280. platformforge/data/knowledge/sources.yaml +516 -0
  281. platformforge/data/knowledge/terraform/lifecycle.yaml +18 -0
  282. platformforge/data/knowledge/terraform/plan-semantics.yaml +26 -0
  283. platformforge/data/lab/chaos-pod-kill/chaos.yaml +3 -0
  284. platformforge/data/lab/chaos-pod-kill/facts.json +13 -0
  285. platformforge/data/lab/fleets/acme/capacity.yaml +35 -0
  286. platformforge/data/lab/fleets/acme/costs.yaml +25 -0
  287. platformforge/data/lab/fleets/acme/events.yaml +41 -0
  288. platformforge/data/lab/fleets/acme/fleet.yaml +51 -0
  289. platformforge/data/lab/fleets/acme/graph.yaml +45 -0
  290. platformforge/data/lab/fleets/acme/policies.yaml +28 -0
  291. platformforge/data/lab/fleets/acme/requests.yaml +24 -0
  292. platformforge/data/lab/scenarios/argo-bad-rollout/expected.yaml +6 -0
  293. platformforge/data/lab/scenarios/argo-bad-rollout/fixture/app.yaml +9 -0
  294. platformforge/data/lab/scenarios/aws-dump/expected.yaml +19 -0
  295. platformforge/data/lab/scenarios/aws-dump/fixture/compute.json +4 -0
  296. platformforge/data/lab/scenarios/aws-dump/fixture/iam.json +7 -0
  297. platformforge/data/lab/scenarios/aws-dump/fixture/network.json +6 -0
  298. platformforge/data/lab/scenarios/aws-dump/fixture/org.json +4 -0
  299. platformforge/data/lab/scenarios/aws-dump/fixture/storage.json +4 -0
  300. platformforge/data/lab/scenarios/container-unsigned/expected.yaml +5 -0
  301. platformforge/data/lab/scenarios/container-unsigned/fixture/supply.json +11 -0
  302. platformforge/data/lab/scenarios/cost-idle-workload/expected.yaml +5 -0
  303. platformforge/data/lab/scenarios/cost-idle-workload/fixture/costs.json +12 -0
  304. platformforge/data/lab/scenarios/crossplane-platform/expected.yaml +16 -0
  305. platformforge/data/lab/scenarios/crossplane-platform/fixture/negative.yaml +18 -0
  306. platformforge/data/lab/scenarios/crossplane-platform/fixture/xrd.yaml +90 -0
  307. platformforge/data/lab/scenarios/demo-platform/expected.yaml +16 -0
  308. platformforge/data/lab/scenarios/demo-platform/fixture/.github/workflows/ci.yml +10 -0
  309. platformforge/data/lab/scenarios/demo-platform/fixture/deploy.yaml +16 -0
  310. platformforge/data/lab/scenarios/demo-platform/fixture/infra.tf +5 -0
  311. platformforge/data/lab/scenarios/fleet-ai/expected.yaml +12 -0
  312. platformforge/data/lab/scenarios/fleet-capacity/expected.yaml +12 -0
  313. platformforge/data/lab/scenarios/fleet-cost/expected.yaml +18 -0
  314. platformforge/data/lab/scenarios/fleet-federation/expected.yaml +11 -0
  315. platformforge/data/lab/scenarios/fleet-golden-path/expected.yaml +18 -0
  316. platformforge/data/lab/scenarios/fleet-op-hotspot/expected.yaml +11 -0
  317. platformforge/data/lab/scenarios/fleet-ownership/expected.yaml +17 -0
  318. platformforge/data/lab/scenarios/fleet-partial/expected.yaml +10 -0
  319. platformforge/data/lab/scenarios/fleet-policy-friction/expected.yaml +10 -0
  320. platformforge/data/lab/scenarios/fleet-recurring-incident/expected.yaml +12 -0
  321. platformforge/data/lab/scenarios/fleet-report/expected.yaml +13 -0
  322. platformforge/data/lab/scenarios/fleet-risk/expected.yaml +18 -0
  323. platformforge/data/lab/scenarios/gitops-drift/expected.yaml +6 -0
  324. platformforge/data/lab/scenarios/gitops-drift/fixture/app.yaml +12 -0
  325. platformforge/data/lab/scenarios/k8s-bad-readiness/expected.yaml +6 -0
  326. platformforge/data/lab/scenarios/k8s-bad-readiness/fixture/deploy.yaml +23 -0
  327. platformforge/data/lab/scenarios/k8s-bad-readiness/fixture/netpol.yaml +9 -0
  328. platformforge/data/lab/scenarios/k8s-missing-limits/expected.yaml +6 -0
  329. platformforge/data/lab/scenarios/k8s-missing-limits/fixture/deploy.yaml +26 -0
  330. platformforge/data/lab/scenarios/k8s-missing-limits/fixture/netpol.yaml +9 -0
  331. platformforge/data/lab/scenarios/k8s-single-replica/expected.yaml +5 -0
  332. platformforge/data/lab/scenarios/k8s-single-replica/fixture/deploy.yaml +26 -0
  333. platformforge/data/lab/scenarios/k8s-single-replica/fixture/netpol.yaml +4 -0
  334. platformforge/data/lab/scenarios/live-aws-collect/expected.yaml +4 -0
  335. platformforge/data/lab/scenarios/live-aws-collect/fixture/aws/ec2_describe-vpcs.json +15 -0
  336. platformforge/data/lab/scenarios/live-aws-collect/fixture/aws/iam_list-users.denied.txt +1 -0
  337. platformforge/data/lab/scenarios/live-aws-collect/fixture/aws/sts_get-caller-identity.json +5 -0
  338. platformforge/data/lab/scenarios/live-k8s-collect/expected.yaml +4 -0
  339. platformforge/data/lab/scenarios/live-k8s-collect/fixture/kubectl/get_configmaps.denied.txt +1 -0
  340. platformforge/data/lab/scenarios/live-k8s-collect/fixture/kubectl/get_deployments.apps.json +25 -0
  341. platformforge/data/lab/scenarios/live-k8s-collect/fixture/kubectl/get_pods.json +17 -0
  342. platformforge/data/lab/scenarios/live-k8s-collect/fixture/kubectl/get_secrets.json +13 -0
  343. platformforge/data/lab/scenarios/live-kind/expected.yaml +14 -0
  344. platformforge/data/lab/scenarios/live-kind/fixture/kubectl/get_configmaps.denied.txt +1 -0
  345. platformforge/data/lab/scenarios/live-kind/fixture/kubectl/get_deployments.apps.json +25 -0
  346. platformforge/data/lab/scenarios/live-kind/fixture/kubectl/get_pods.json +17 -0
  347. platformforge/data/lab/scenarios/live-kind/fixture/kubectl/get_secrets.json +13 -0
  348. platformforge/data/lab/scenarios/network-policy-missing/expected.yaml +6 -0
  349. platformforge/data/lab/scenarios/network-policy-missing/fixture/deploy.yaml +26 -0
  350. platformforge/data/lab/scenarios/ops-bad-rollout/expected.yaml +3 -0
  351. platformforge/data/lab/scenarios/ops-bad-rollout/fixture/ops.yaml +33 -0
  352. platformforge/data/lab/scenarios/ops-break-glass/expected.yaml +3 -0
  353. platformforge/data/lab/scenarios/ops-break-glass/fixture/ops.yaml +21 -0
  354. platformforge/data/lab/scenarios/ops-broken-selector/expected.yaml +3 -0
  355. platformforge/data/lab/scenarios/ops-broken-selector/fixture/ops.yaml +21 -0
  356. platformforge/data/lab/scenarios/ops-changed-plan-hash/expected.yaml +3 -0
  357. platformforge/data/lab/scenarios/ops-changed-plan-hash/fixture/ops.yaml +20 -0
  358. platformforge/data/lab/scenarios/ops-conflicting-operation/expected.yaml +3 -0
  359. platformforge/data/lab/scenarios/ops-conflicting-operation/fixture/ops.yaml +21 -0
  360. platformforge/data/lab/scenarios/ops-expired-approval/expected.yaml +3 -0
  361. platformforge/data/lab/scenarios/ops-expired-approval/fixture/ops.yaml +20 -0
  362. platformforge/data/lab/scenarios/ops-partial-failure/expected.yaml +3 -0
  363. platformforge/data/lab/scenarios/ops-partial-failure/fixture/ops.yaml +24 -0
  364. platformforge/data/lab/scenarios/ops-policy-denial/expected.yaml +3 -0
  365. platformforge/data/lab/scenarios/ops-policy-denial/fixture/ops.yaml +17 -0
  366. platformforge/data/lab/scenarios/ops-replica-drift/expected.yaml +3 -0
  367. platformforge/data/lab/scenarios/ops-replica-drift/fixture/ops.yaml +28 -0
  368. platformforge/data/lab/scenarios/ops-rollback-annotate/expected.yaml +3 -0
  369. platformforge/data/lab/scenarios/ops-rollback-annotate/fixture/ops.yaml +41 -0
  370. platformforge/data/lab/scenarios/ops-rollback-gitops/expected.yaml +3 -0
  371. platformforge/data/lab/scenarios/ops-rollback-gitops/fixture/ops.yaml +38 -0
  372. platformforge/data/lab/scenarios/ops-rollback-impossible/expected.yaml +3 -0
  373. platformforge/data/lab/scenarios/ops-rollback-impossible/fixture/ops.yaml +34 -0
  374. platformforge/data/lab/scenarios/ops-rollback-scale/expected.yaml +3 -0
  375. platformforge/data/lab/scenarios/ops-rollback-scale/fixture/ops.yaml +40 -0
  376. platformforge/data/lab/scenarios/ops-rollback-terraform/expected.yaml +3 -0
  377. platformforge/data/lab/scenarios/ops-rollback-terraform/fixture/ops.yaml +38 -0
  378. platformforge/data/lab/scenarios/ops-rollback-terraform/fixture/tf/tfplan.bin +1 -0
  379. platformforge/data/lab/scenarios/ops-stale-observation/expected.yaml +3 -0
  380. platformforge/data/lab/scenarios/ops-stale-observation/fixture/ops.yaml +20 -0
  381. platformforge/data/lab/scenarios/secret-exposure/expected.yaml +5 -0
  382. platformforge/data/lab/scenarios/secret-exposure/fixture/app.env +2 -0
  383. platformforge/data/lab/scenarios/slo-burn/expected.yaml +5 -0
  384. platformforge/data/lab/scenarios/slo-burn/fixture/events.yaml +2 -0
  385. platformforge/data/lab/scenarios/slo-burn/fixture/slo.yaml +4 -0
  386. platformforge/data/lab/scenarios/terraform-iam-wildcard/expected.yaml +5 -0
  387. platformforge/data/lab/scenarios/terraform-iam-wildcard/fixture/policy.json +14 -0
  388. platformforge/data/lab/scenarios/terraform-public-bucket/expected.yaml +6 -0
  389. platformforge/data/lab/scenarios/terraform-public-bucket/fixture/main.tf +5 -0
  390. platformforge/data/portable_skills/platformforge-agents/SKILL.md +47 -0
  391. platformforge/data/portable_skills/platformforge-change/SKILL.md +41 -0
  392. platformforge/data/portable_skills/platformforge-core/SKILL.md +62 -0
  393. platformforge/data/portable_skills/platformforge-economy/SKILL.md +42 -0
  394. platformforge/data/portable_skills/platformforge-finops/SKILL.md +34 -0
  395. platformforge/data/portable_skills/platformforge-fleet/SKILL.md +39 -0
  396. platformforge/data/portable_skills/platformforge-governance/SKILL.md +76 -0
  397. platformforge/data/portable_skills/platformforge-graph/SKILL.md +46 -0
  398. platformforge/data/portable_skills/platformforge-lab/SKILL.md +39 -0
  399. platformforge/data/portable_skills/platformforge-sdd/SKILL.md +39 -0
  400. platformforge/data/portable_skills/platformforge-security/SKILL.md +38 -0
  401. platformforge/data/portable_skills/platformforge-sre/SKILL.md +41 -0
  402. platformforge/data/rules/catalog/finops.yaml +26 -0
  403. platformforge/data/rules/catalog/gitops.yaml +161 -0
  404. platformforge/data/rules/catalog/iac.yaml +84 -0
  405. platformforge/data/rules/catalog/k8s.yaml +322 -0
  406. platformforge/data/rules/catalog/orchestration.yaml +99 -0
  407. platformforge/data/rules/catalog/product.yaml +42 -0
  408. platformforge/data/rules/catalog/routing.yaml +122 -0
  409. platformforge/data/rules/catalog/security.yaml +159 -0
  410. platformforge/data/rules/catalog/sre.yaml +67 -0
  411. platformforge/diagnose/__init__.py +75 -0
  412. platformforge/distribution/__init__.py +18 -0
  413. platformforge/distribution/bundle.py +127 -0
  414. platformforge/distribution/hostflow.py +247 -0
  415. platformforge/distribution/models.py +80 -0
  416. platformforge/distribution/service.py +225 -0
  417. platformforge/economy/__init__.py +27 -0
  418. platformforge/economy/bench.py +66 -0
  419. platformforge/economy/budget.py +198 -0
  420. platformforge/economy/cache.py +287 -0
  421. platformforge/economy/checkpoint.py +112 -0
  422. platformforge/economy/collection.py +142 -0
  423. platformforge/economy/doctor.py +207 -0
  424. platformforge/economy/engine.py +158 -0
  425. platformforge/economy/envelope.py +61 -0
  426. platformforge/economy/fleetpack.py +86 -0
  427. platformforge/economy/ledger.py +232 -0
  428. platformforge/economy/plan.py +131 -0
  429. platformforge/economy/pricing.py +101 -0
  430. platformforge/economy/qpt.py +286 -0
  431. platformforge/economy/reconcile.py +86 -0
  432. platformforge/economy/verifyplan.py +107 -0
  433. platformforge/economy/waste.py +123 -0
  434. platformforge/evals/__init__.py +16 -0
  435. platformforge/evals/coverage.py +140 -0
  436. platformforge/evals/fleet_invariants.py +260 -0
  437. platformforge/evals/ops_invariants.py +158 -0
  438. platformforge/evals/runner.py +541 -0
  439. platformforge/federation/__init__.py +4 -0
  440. platformforge/federation/node.py +135 -0
  441. platformforge/finops/__init__.py +14 -0
  442. platformforge/finops/alloc.py +31 -0
  443. platformforge/finops/costs.py +79 -0
  444. platformforge/finops/focus.py +100 -0
  445. platformforge/finops/graph_cost.py +51 -0
  446. platformforge/finops/ingest.py +144 -0
  447. platformforge/finops/insights.py +193 -0
  448. platformforge/finops/unit.py +36 -0
  449. platformforge/fleet/__init__.py +5 -0
  450. platformforge/fleet/loader.py +73 -0
  451. platformforge/fleet/models.py +155 -0
  452. platformforge/fleet/orggraph.py +172 -0
  453. platformforge/fleet/query.py +154 -0
  454. platformforge/forge/__init__.py +9 -0
  455. platformforge/forge/collect.py +88 -0
  456. platformforge/forge/delegate.py +77 -0
  457. platformforge/forge/manifest.py +106 -0
  458. platformforge/freeze/__init__.py +22 -0
  459. platformforge/freeze/exceptions.py +56 -0
  460. platformforge/freeze/manifest.py +167 -0
  461. platformforge/freeze/snapshots.py +108 -0
  462. platformforge/graph/__init__.py +39 -0
  463. platformforge/graph/backend.py +174 -0
  464. platformforge/graph/bench.py +245 -0
  465. platformforge/graph/build.py +130 -0
  466. platformforge/graph/delivery.py +183 -0
  467. platformforge/graph/diff.py +292 -0
  468. platformforge/graph/events.py +116 -0
  469. platformforge/graph/migrate.py +44 -0
  470. platformforge/graph/model.py +264 -0
  471. platformforge/graph/persist.py +97 -0
  472. platformforge/graph/query.py +290 -0
  473. platformforge/graph/temporal.py +78 -0
  474. platformforge/graph/vocab.py +63 -0
  475. platformforge/graphview.py +94 -0
  476. platformforge/iac/__init__.py +7 -0
  477. platformforge/iac/drift.py +53 -0
  478. platformforge/iac/plan.py +84 -0
  479. platformforge/iac/terraform.py +123 -0
  480. platformforge/install/__init__.py +1 -0
  481. platformforge/install/service.py +421 -0
  482. platformforge/k8s/__init__.py +8 -0
  483. platformforge/k8s/helm.py +152 -0
  484. platformforge/k8s/hubble.py +87 -0
  485. platformforge/k8s/manifests.py +513 -0
  486. platformforge/knowledge/__init__.py +1 -0
  487. platformforge/knowledge/packs.py +157 -0
  488. platformforge/knowledge/registry.py +249 -0
  489. platformforge/knowledge/select.py +127 -0
  490. platformforge/lab/__init__.py +5 -0
  491. platformforge/lab/chaos.py +71 -0
  492. platformforge/lab/fleetlab.py +351 -0
  493. platformforge/lab/opslab.py +271 -0
  494. platformforge/lab/runner.py +219 -0
  495. platformforge/live/__init__.py +36 -0
  496. platformforge/live/budget.py +92 -0
  497. platformforge/live/capability.py +80 -0
  498. platformforge/live/collectors/__init__.py +6 -0
  499. platformforge/live/collectors/aws.py +370 -0
  500. platformforge/live/collectors/aws_transport.py +98 -0
  501. platformforge/live/collectors/k8s.py +389 -0
  502. platformforge/live/collectors/k8s_transport.py +85 -0
  503. platformforge/live/cursors.py +48 -0
  504. platformforge/live/drift.py +130 -0
  505. platformforge/live/envelope.py +85 -0
  506. platformforge/live/federation.py +113 -0
  507. platformforge/live/fixtures.py +168 -0
  508. platformforge/live/identity.py +258 -0
  509. platformforge/live/incident.py +200 -0
  510. platformforge/live/models.py +435 -0
  511. platformforge/live/reconcile.py +382 -0
  512. platformforge/live/remediate.py +169 -0
  513. platformforge/live/store.py +256 -0
  514. platformforge/live/topology.py +249 -0
  515. platformforge/mcp/__init__.py +7 -0
  516. platformforge/mcp/parity.py +69 -0
  517. platformforge/mcp/registry.py +427 -0
  518. platformforge/mcp/server.py +84 -0
  519. platformforge/mcp/tools.py +732 -0
  520. platformforge/models/__init__.py +21 -0
  521. platformforge/models/base.py +214 -0
  522. platformforge/observe/__init__.py +26 -0
  523. platformforge/observe/capacity.py +39 -0
  524. platformforge/observe/dr.py +67 -0
  525. platformforge/observe/grafana.py +76 -0
  526. platformforge/observe/incident.py +58 -0
  527. platformforge/observe/otel.py +135 -0
  528. platformforge/observe/postmortem.py +72 -0
  529. platformforge/observe/prometheus.py +88 -0
  530. platformforge/observe/slo.py +125 -0
  531. platformforge/ops/__init__.py +8 -0
  532. platformforge/ops/actions.py +215 -0
  533. platformforge/ops/analytics.py +83 -0
  534. platformforge/ops/approval.py +275 -0
  535. platformforge/ops/autorem.py +101 -0
  536. platformforge/ops/config.py +175 -0
  537. platformforge/ops/engine.py +758 -0
  538. platformforge/ops/envelope.py +135 -0
  539. platformforge/ops/executors/__init__.py +1 -0
  540. platformforge/ops/executors/base.py +211 -0
  541. platformforge/ops/executors/git.py +77 -0
  542. platformforge/ops/executors/gitops.py +134 -0
  543. platformforge/ops/executors/terraform.py +84 -0
  544. platformforge/ops/gates.py +135 -0
  545. platformforge/ops/goldenpath.py +180 -0
  546. platformforge/ops/material.py +181 -0
  547. platformforge/ops/models.py +421 -0
  548. platformforge/ops/operation.py +335 -0
  549. platformforge/ops/opgraph.py +233 -0
  550. platformforge/ops/policy.py +275 -0
  551. platformforge/ops/preconditions.py +109 -0
  552. platformforge/ops/registry.py +101 -0
  553. platformforge/ops/risk.py +216 -0
  554. platformforge/ops/rollback.py +287 -0
  555. platformforge/ops/rollback_builders.py +163 -0
  556. platformforge/ops/runbook.py +269 -0
  557. platformforge/ops/simulate.py +125 -0
  558. platformforge/ops/source_of_truth.py +198 -0
  559. platformforge/ops/store.py +157 -0
  560. platformforge/ops/verify.py +190 -0
  561. platformforge/optimize/__init__.py +4 -0
  562. platformforge/optimize/engine.py +109 -0
  563. platformforge/optimize/models.py +68 -0
  564. platformforge/optimize/scan.py +196 -0
  565. platformforge/plan/__init__.py +107 -0
  566. platformforge/portable_cli.py +199 -0
  567. platformforge/portal_adapter.py +740 -0
  568. platformforge/portal_assets/chunk-7_l-b4Tr.js +1 -0
  569. platformforge/portal_assets/chunk-B0Iad6pD.js +1 -0
  570. platformforge/portal_assets/chunk-B605XnCF.js +1 -0
  571. platformforge/portal_assets/chunk-B7N3TXcn.js +1 -0
  572. platformforge/portal_assets/chunk-BAj6yGem.js +1 -0
  573. platformforge/portal_assets/chunk-BGUitn2r.js +1 -0
  574. platformforge/portal_assets/chunk-BVKnCv85.js +1 -0
  575. platformforge/portal_assets/chunk-BYyM9V_w.js +1 -0
  576. platformforge/portal_assets/chunk-BaQMhq-G.js +1 -0
  577. platformforge/portal_assets/chunk-BavOrxVm.js +1 -0
  578. platformforge/portal_assets/chunk-Bb0C24YV.js +1 -0
  579. platformforge/portal_assets/chunk-BfCFGPzs.js +1 -0
  580. platformforge/portal_assets/chunk-C2t4OUVu.js +1 -0
  581. platformforge/portal_assets/chunk-C3pI4QjU.js +1 -0
  582. platformforge/portal_assets/chunk-C4gpbtbP.js +1 -0
  583. platformforge/portal_assets/chunk-CGWeHhKY.js +1 -0
  584. platformforge/portal_assets/chunk-CJCT86Dr.js +1 -0
  585. platformforge/portal_assets/chunk-CXcsLDPJ.js +1 -0
  586. platformforge/portal_assets/chunk-CcjxoLxw.js +1 -0
  587. platformforge/portal_assets/chunk-D-gBPXHa.js +1 -0
  588. platformforge/portal_assets/chunk-D3eZogIe.js +1 -0
  589. platformforge/portal_assets/chunk-DQU0VyoQ.js +1 -0
  590. platformforge/portal_assets/chunk-DqWNkF1O.js +1 -0
  591. platformforge/portal_assets/chunk-DuPPkSIE.js +3 -0
  592. platformforge/portal_assets/chunk-DyIHOW_a.js +1 -0
  593. platformforge/portal_assets/chunk-Fx4zSGL5.js +1 -0
  594. platformforge/portal_assets/chunk-UBKt05Rg.js +1 -0
  595. platformforge/portal_assets/chunk-htnJDQEY.js +1 -0
  596. platformforge/portal_assets/chunk-kXRFMGqe.js +1 -0
  597. platformforge/portal_assets/chunk-qe3u763a.js +1 -0
  598. platformforge/portal_assets/favicon.ico +0 -0
  599. platformforge/portal_assets/index.html +13 -0
  600. platformforge/portal_assets/main-QDFVZK3T.js +5 -0
  601. platformforge/portal_assets/styles-MQEBDFDX.css +1 -0
  602. platformforge/product/__init__.py +10 -0
  603. platformforge/product/backstage.py +49 -0
  604. platformforge/product/catalog.py +74 -0
  605. platformforge/product/crossplane.py +341 -0
  606. platformforge/product/golden_paths/__init__.py +5 -0
  607. platformforge/product/golden_paths/engine.py +97 -0
  608. platformforge/product/golden_paths/library.yaml +198 -0
  609. platformforge/product/golden_paths/model.py +84 -0
  610. platformforge/product/maturity.py +107 -0
  611. platformforge/product/scorecards.py +84 -0
  612. platformforge/resources.py +36 -0
  613. platformforge/risk/__init__.py +5 -0
  614. platformforge/risk/engine.py +95 -0
  615. platformforge/risk/signals.py +49 -0
  616. platformforge/routing/__init__.py +13 -0
  617. platformforge/routing/decision.py +191 -0
  618. platformforge/routing/router.py +328 -0
  619. platformforge/rtk/__init__.py +9 -0
  620. platformforge/rtk/compact.py +127 -0
  621. platformforge/rtk/parsers.py +199 -0
  622. platformforge/rules/__init__.py +5 -0
  623. platformforge/rules/engine.py +345 -0
  624. platformforge/sandbox/__init__.py +7 -0
  625. platformforge/sandbox/env.py +151 -0
  626. platformforge/sandbox/review.py +92 -0
  627. platformforge/sdd/__init__.py +8 -0
  628. platformforge/sdd/lifecycle.py +239 -0
  629. platformforge/security/__init__.py +19 -0
  630. platformforge/security/cosign.py +67 -0
  631. platformforge/security/iam.py +112 -0
  632. platformforge/security/identity.py +84 -0
  633. platformforge/security/kyverno.py +106 -0
  634. platformforge/security/sbom.py +59 -0
  635. platformforge/security/scan.py +63 -0
  636. platformforge/security/slsa.py +86 -0
  637. platformforge/security/supply.py +62 -0
  638. platformforge/tokensave/__init__.py +20 -0
  639. platformforge/tokensave/budget.py +62 -0
  640. platformforge/tokensave/estimate.py +21 -0
  641. platformforge/tokensave/index.py +172 -0
  642. platformforge/tokensave/ledger.py +121 -0
  643. platformforge/tokensave/packs.py +285 -0
  644. platformforge/ui/__init__.py +28 -0
  645. platformforge/ui/app.py +465 -0
  646. platformforge/ui/home.py +113 -0
  647. platformforge/ui/i18n.py +143 -0
  648. platformforge/ui/kit.py +689 -0
  649. platformforge/ui/screen.py +628 -0
  650. platformforge/ui/tui.py +94 -0
  651. platformforge/ui/wizard.py +309 -0
  652. platformforge/workspace/__init__.py +13 -0
  653. platformforge/workspace/models.py +35 -0
  654. platformforge/workspace/service.py +69 -0
  655. platformforge-0.1.0.dist-info/METADATA +212 -0
  656. platformforge-0.1.0.dist-info/RECORD +659 -0
  657. platformforge-0.1.0.dist-info/WHEEL +4 -0
  658. platformforge-0.1.0.dist-info/entry_points.txt +3 -0
  659. platformforge-0.1.0.dist-info/licenses/LICENSE +21 -0
@@ -0,0 +1 @@
1
+ import{$ as ah,At as sl,B as Te$1,Et as pl,F as RD,G as XI,H as UI,It as yg,K as YI,Lt as yh,Nt as vh,O as LD,Ot as ry,P as Qu,Rt as zI,U as Vv,V as Tg,Y as Zi,Z as _E,_t as jn,c as $i,dt as hg,f as CE,g as Eg,gt as jI,jt as uh,kt as sh,m as DD,q as Yu,s as $I,st as g,u as BI,vt as kD,xt as ml,y as HI,yt as ki}from"./main-QDFVZK3T.js";import{t as _}from"./chunk-BaQMhq-G.js";import{t as w}from"./chunk-BVKnCv85.js";import{t as I}from"./chunk-DyIHOW_a.js";import{t as _$1}from"./chunk-C4gpbtbP.js";import{i as Zt,n as De$1,r as Yt,t as At}from"./chunk-kXRFMGqe.js";var $=()=>[];var oe=(n,i)=>i[0];var re=(n,i)=>i.id;var te=(n,i)=>i.path;var le=(n,i)=>i.path??i;var ee=(n,i)=>i.member;function de(n,i){if(n&1&&(ki(0,`span`,3),DD(1),pl()),n&2){let e=XI();Vv(),ml(`· `,e.operation)}}function ce(n,i){if(n&1&&(ki(0,`div`,6)(1,`dt`),DD(2),kD(3,`t`),pl(),ki(4,`dd`),DD(5),pl()()),n&2){let e=i.$implicit;Vv(2),yh(LD(3,2,e[0])),Vv(3),yh(e[1])}}function se(n,i){if(n&1&&(ki(0,`span`,14),DD(1),pl()),n&2){let e=XI().$implicit;Vv(),yh(e.detail)}}function pe(n,i){n&1&&(ki(0,`span`,15),DD(1),kD(2,`t`),pl()),n&2&&(Vv(),yh(LD(2,1,`fdoc.repairable`)))}function _e(n,i){if(n&1&&(ki(0,`li`),ah(1,`ui-state-badge`,12),ki(2,`code`,13),DD(3),pl(),jI(4,se,2,1,`span`,14),jI(5,pe,3,3,`span`,15),pl()),n&2){let e=i.$implicit;Vv(),sh(`state`,e.status??`unverified`)(`labelOverride`,e.status??null),Vv(2),yh(e.id),Vv(),HI(e.detail?4:-1),Vv(),HI(e.repairable?5:-1)}}function me(n,i){if(n&1&&(ki(0,`h3`),DD(1),kD(2,`t`),pl(),ki(3,`ul`,11),$I(4,_e,6,5,`li`,null,re),pl()),n&2){let e=XI();Vv(),yh(LD(2,1,`fdoc.checks`)),Vv(3),zI(e.checks)}}function ue(n,i){if(n&1&&(ki(0,`div`,20),ah(1,`ui-state-badge`,12),ki(2,`code`),DD(3),pl()()),n&2){let e=i.$implicit;Vv(),sh(`state`,e.status??`modified`)(`labelOverride`,e.status??null),Vv(2),yh(e.path)}}function ge(n,i){if(n&1&&(ki(0,`h3`),DD(1),kD(2,`t`),pl(),ki(3,`p`,16)(4,`span`,17),DD(5),pl(),ki(6,`span`,18),DD(7),kD(8,`t`),pl(),ki(9,`span`,19),DD(10),kD(11,`t`),pl()(),$I(12,ue,4,3,`div`,20,te)),n&2){let e=XI(),l=XI(2);Vv(),yh(LD(2,6,`fdoc.drift`)),Vv(4),ml(`ok `,e.ok),Vv(2),vh(``,LD(8,8,`fdoc.modified`),` `,e.modified?.length??0),Vv(3),vh(``,LD(11,10,`fdoc.missing`),` `,e.missing?.length??0),Vv(2),zI(l.driftFiles(e))}}function fe(n,i){n&1&&jI(0,ge,14,12),n&2&&HI(i.ok!==void 0?0:-1)}function xe(n,i){if(n&1&&(ki(0,`div`,20)(1,`code`),DD(2),pl()()),n&2){let e=i.$implicit;Vv(2),yh(e.path??e)}}function ve(n,i){if(n&1&&(ki(0,`p`,22),DD(1),kD(2,`t`),pl()),n&2){let e=XI(2);Vv(),vh(`… `,e.list.length-8,` `,LD(2,2,`fdoc.more`))}}function ye(n,i){if(n&1&&(ki(0,`h3`),DD(1),kD(2,`t`),pl(),ki(3,`p`,21),DD(4),pl(),$I(5,xe,3,1,`div`,20,le),jI(7,ve,3,4,`p`,22)),n&2){let e=XI();Vv(),yh(LD(2,3,e.label)),Vv(3),yh(e.list.length),Vv(),zI(e.list.slice(0,8)),Vv(2),HI(e.list.length>8?7:-1)}}function Ce(n,i){n&1&&jI(0,ye,8,5),n&2&&HI(i.list.length?0:-1)}function be(n,i){if(n&1&&(ki(0,`code`),DD(1),pl()),n&2){let e=XI();Vv(),yh(e.install_root??e.manifest)}}function Se(n,i){n&1&&(ki(0,`span`,22),DD(1),kD(2,`t`),pl()),n&2&&(Vv(),yh(LD(2,1,`fdoc.portal.vendored`)))}function ke(n,i){if(n&1&&(ki(0,`h3`),DD(1),kD(2,`t`),pl(),ki(3,`p`,23),ah(4,`ui-state-badge`,12),jI(5,be,2,1,`code`)(6,Se,3,3,`span`,22),pl()),n&2){let e=i;Vv(),yh(LD(2,4,`fdoc.portal`)),Vv(3),sh(`state`,e.state??`unverified`)(`labelOverride`,e.state??null),Vv(),HI(e.install_root||e.manifest?5:e.state===`vendored`?6:-1)}}function he(n,i){if(n&1&&(ki(0,`div`,20)(1,`code`),DD(2),pl()()),n&2){let e=i.$implicit;Vv(2),yh(e.path)}}function Pe(n,i){if(n&1&&(ki(0,`div`,20),ah(1,`ui-state-badge`,24),ki(2,`code`),DD(3),pl(),DD(4),pl()),n&2){let e=i.$implicit;Vv(),sh(`labelOverride`,`conflict`),Vv(2),yh(e.member),Vv(),vh(` `,e.forge_id,`: `,e.decision,` `)}}function Ee(n,i){if(n&1&&(ki(0,`div`,20),ah(1,`ui-state-badge`,25),ki(2,`code`),DD(3),pl()()),n&2){let e=i.$implicit;Vv(),sh(`labelOverride`,`unknown`),Vv(2),yh(e)}}function Te(n,i){if(n&1&&(ki(0,`div`,20),ah(1,`ui-state-badge`,12),ki(2,`code`),DD(3),pl()()),n&2){let e=i.$implicit;Vv(),sh(`state`,e.status??`unverified`)(`labelOverride`,e.status??null),Vv(2),yh(e.member)}}function we(n,i){if(n&1&&(ki(0,`h3`),DD(1),kD(2,`t`),pl(),$I(3,he,3,1,`div`,20,te),$I(5,Pe,5,4,`div`,20,ee),$I(7,Ee,4,2,`div`,20,BI),$I(9,Te,4,3,`div`,20,ee)),n&2){let e=i;Vv(),yh(LD(2,1,`fdoc.workspace`)),Vv(2),zI(e.members??RD(3,$)),Vv(2),zI(e.conflicts??RD(4,$)),Vv(2),zI(e.unknown_members??RD(5,$)),Vv(2),zI(e.member_results??RD(6,$))}}function Ie(n,i){if(n&1&&(ki(0,`p`,7),DD(1),kD(2,`t`),ah(3,`ui-state-badge`,4),pl()),n&2){let e=XI();Vv(),ml(` `,LD(2,2,`fdoc.verification`),` `),Vv(2),sh(`state`,e.verification.status)}}function Ne(n,i){if(n&1&&(ki(0,`p`),DD(1),pl()),n&2){let e=XI(2);Vv(),yh(e.error.detail)}}function Me(n,i){if(n&1&&(ki(0,`p`,26),DD(1),kD(2,`t`),pl()),n&2){let e=XI(2);Vv(),vh(``,LD(2,2,`fdoc.unlock`),` `,e.error.unlock)}}function Oe(n,i){if(n&1&&(ki(0,`div`,8)(1,`p`)(2,`code`),DD(3),pl()(),jI(4,Ne,2,1,`p`),jI(5,Me,3,4,`p`,26),pl()),n&2){let e=XI();Vv(3),yh(e.error.kind),Vv(),HI(e.error.detail?4:-1),Vv(),HI(e.error.unlock?5:-1)}}function Fe(n,i){if(n&1&&(ki(0,`p`,9),ah(1,`ui-icon`,27),DD(2),kD(3,`t`),ki(4,`code`),DD(5),pl()()),n&2){let e=XI();Vv(),sh(`size`,13),Vv(),ml(` `,LD(3,3,`fdoc.repair`),` `),Vv(3),yh(e.repair_hint)}}function Be(n,i){if(n&1&&(ki(0,`div`,0)(1,`div`,1)(2,`span`,2),DD(3),pl(),jI(4,de,2,1,`span`,3),ah(5,`ui-state-badge`,4),pl(),ki(6,`dl`,5),$I(7,ce,6,4,`div`,6,oe),pl(),jI(9,me,6,3),jI(10,fe,1,1),jI(11,Ce,1,1),jI(12,ke,7,6),jI(13,we,11,7),jI(14,Ie,4,4,`p`,7),jI(15,Oe,6,3,`div`,8),jI(16,Fe,6,5,`p`,9),ki(17,`details`,10)(18,`summary`),DD(19),kD(20,`t`),pl(),ki(21,`pre`),DD(22),pl()()()),n&2){let e,l,p,S,x=i,T=XI();Vv(3),yh(x.forge_id??`forge`),Vv(),HI(x.operation?4:-1),Vv(),sh(`state`,x.status??`unverified`),Vv(2),zI(T.meta(x)),Vv(2),HI(x.checks?.length?9:-1),Vv(),HI((e=x.drift)?10:-1,e),Vv(),HI((l=T.files(x))?11:-1,l),Vv(),HI((p=x.forge_portal)?12:-1,p),Vv(),HI((S=x.workspace)?13:-1,S),Vv(),HI(x.verification?.status?14:-1),Vv(),HI(x.error&&(x.error.kind||x.error.detail)?15:-1),Vv(),HI(x.repair_hint?16:-1),Vv(3),yh(LD(20,13,`fdoc.raw`)),Vv(3),yh(T.raw())}}var z=class n{doc=Zi.required();raw=Te$1(``);ngOnChanges(){this.raw.set(JSON.stringify(this.doc(),null,2))}meta(i){let e=[];i.target_root&&e.push([`doc.target`,i.target_root]),i.scope&&e.push([`doc.scope`,i.scope]),i.version&&e.push([`doc.version`,i.version]);let l=i.context?.profile??i.profile;return l&&e.push([`doc.profile`,l]),i.state_dir&&e.push([`doc.state_dir`,i.state_dir]),i.ledger_entries!==void 0&&e.push([`doc.managed`,`${i.ledger_entries}`]),e}driftFiles(i){return[...i.modified??[],...i.missing??[]].slice(0,8)}files(i){return i.managed_files?{label:`fdoc.managed_files`,list:i.managed_files}:i.planned_files?{label:`fdoc.planned_files`,list:i.planned_files}:null}static ɵfac=function(e){return new(e||n)};static ɵcmp=sl({type:n,selectors:[[`ui-forge-doc`]],inputs:{doc:[1,`doc`]},features:[ry],decls:1,vars:1,consts:[[1,`fdoc`],[1,`fdoc__head`],[1,`fdoc__title`],[1,`fdoc__op`],[3,`state`],[1,`fdoc__meta`],[1,`kv`],[1,`fdoc__verif`],[1,`fdoc__refusal`],[1,`fdoc__repair`],[1,`fdoc__raw`],[1,`fdoc__checks`],[3,`state`,`labelOverride`],[1,`cid`],[1,`detail`],[1,`repairable`],[1,`fdoc__drift`],[1,`ok`],[1,`warn`],[1,`bad`],[1,`fdoc__file`],[1,`fdoc__count`],[1,`muted`],[1,`fdoc__portal`],[`state`,`degraded`,3,`labelOverride`],[`state`,`unverified`,3,`labelOverride`],[1,`unlock`],[`name`,`refresh`,3,`size`]],template:function(e,l){if(e&1&&jI(0,Be,23,15,`div`,0),e&2){let p;HI((p=l.doc())?0:-1,p)}},dependencies:[I,Eg,yg],styles:[`.fdoc[_ngcontent-%COMP%]{font-size:var(--%NS%font-sm)}.fdoc__head[_ngcontent-%COMP%]{display:flex;align-items:baseline;gap:var(--%NS%space-2);margin-bottom:var(--%NS%space-3)}.fdoc__title[_ngcontent-%COMP%]{font-weight:700;font-size:var(--%NS%font-lg);letter-spacing:-.01em}.fdoc__op[_ngcontent-%COMP%]{color:var(--%NS%fg-muted);font-weight:600}.fdoc__meta[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:var(--%NS%space-2) var(--%NS%space-4);margin:0 0 var(--%NS%space-3)}.kv[_ngcontent-%COMP%] dt[_ngcontent-%COMP%]{font-size:var(--%NS%font-xs);color:var(--%NS%fg-muted);text-transform:uppercase;letter-spacing:.04em}.kv[_ngcontent-%COMP%] dd[_ngcontent-%COMP%]{margin:0;font-weight:550;word-break:break-all}h3[_ngcontent-%COMP%]{margin:var(--%NS%space-3) 0 var(--%NS%space-2);font-size:var(--%NS%font-xs);font-weight:700;text-transform:uppercase;letter-spacing:.06em;color:var(--%NS%fg-muted)}.fdoc__checks[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0;display:grid;gap:var(--%NS%space-2)}.fdoc__checks[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{display:flex;align-items:baseline;gap:var(--%NS%space-2);flex-wrap:wrap}.cid[_ngcontent-%COMP%]{font-weight:650}.detail[_ngcontent-%COMP%]{color:var(--%NS%fg-muted)}.repairable[_ngcontent-%COMP%]{color:var(--%NS%accent);font-size:var(--%NS%font-xs);font-weight:650}.fdoc__drift[_ngcontent-%COMP%]{display:flex;gap:var(--%NS%space-3);font-weight:650}.ok[_ngcontent-%COMP%]{color:var(--%NS%ok)}.warn[_ngcontent-%COMP%]{color:var(--%NS%warn)}.bad[_ngcontent-%COMP%]{color:var(--%NS%bad)}.fdoc__file[_ngcontent-%COMP%]{display:flex;align-items:baseline;gap:var(--%NS%space-2);padding:2px 0}.fdoc__count[_ngcontent-%COMP%]{font-weight:650;margin:0}.fdoc__portal[_ngcontent-%COMP%], .fdoc__verif[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--%NS%space-2)}.fdoc__refusal[_ngcontent-%COMP%]{border-left:3px solid var(--%NS%bad);padding:var(--%NS%space-1) var(--%NS%space-3);margin:var(--%NS%space-3) 0;color:var(--%NS%bad)}.fdoc__refusal[_ngcontent-%COMP%] .unlock[_ngcontent-%COMP%]{color:var(--%NS%accent)}.fdoc__repair[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--%NS%space-2);color:var(--%NS%accent)}.fdoc__raw[_ngcontent-%COMP%]{margin-top:var(--%NS%space-4)}.fdoc__raw[_ngcontent-%COMP%] pre[_ngcontent-%COMP%]{background:var(--%NS%bg);border:1px solid var(--%NS%border);border-radius:var(--%NS%radius-md);padding:var(--%NS%space-3);overflow-x:auto;font-size:var(--%NS%font-xs)}.muted[_ngcontent-%COMP%]{color:var(--%NS%fg-muted)}`]})};var De=(n,i)=>i[0];var Ue=(n,i)=>i.id;function $e(n,i){n&1&&(ki(0,`section`,11),ah(1,`div`,30),ki(2,`p`,21),DD(3),kD(4,`t`),pl()()),n&2&&(Vv(3),yh(LD(4,1,`tasks.executing`)))}function ze(n,i){if(n&1){let e=YI();ki(0,`section`,12)(1,`h2`),DD(2),kD(3,`t`),pl(),ki(4,`p`)(5,`code`),DD(6),pl(),DD(7),pl(),ki(8,`p`,21),DD(9),kD(10,`t`),pl(),ki(11,`div`,31)(12,`button`,32),uh(`click`,function(){Yu(e);let p=XI();return Qu(p.regenerate())}),ah(13,`ui-icon`,2),DD(14),kD(15,`t`),pl(),ki(16,`button`,33),uh(`click`,function(){Yu(e);let p=XI();return Qu(p.stale.set(null))}),DD(17),kD(18,`t`),pl()()()}if(n&2){let e=i,l=XI();Vv(2),yh(LD(3,8,`tasks.stale.title`)),Vv(4),yh(e.body.code),Vv(),ml(` `,e.body.message,` `),Vv(2),yh(LD(10,10,`tasks.stale.hint`)),Vv(3),sh(`disabled`,l.busy()),Vv(),sh(`size`,14),Vv(),ml(` `,LD(15,12,`tasks.stale.regenerate`),` `),Vv(3),yh(LD(18,14,`state.close`))}}function Re(n,i){if(n&1&&(ki(0,`div`,35)(1,`dt`)(2,`code`),DD(3),pl()(),ki(4,`dd`),DD(5),pl()()),n&2){let e=i.$implicit;Vv(3),yh(e[0]),Vv(2),yh(e[1])}}function Ve(n,i){if(n&1){let e=YI();ki(0,`section`,13)(1,`h2`),DD(2),kD(3,`t`),pl(),ki(4,`p`,21),DD(5),kD(6,`t`),pl(),ki(7,`dl`,34)(8,`div`,35)(9,`dt`),DD(10),kD(11,`t`),pl(),ki(12,`dd`),DD(13),pl()(),ki(14,`div`,35)(15,`dt`),DD(16),kD(17,`t`),pl(),ki(18,`dd`)(19,`code`),DD(20),pl()()(),ki(21,`div`,35)(22,`dt`),DD(23),kD(24,`t`),pl(),ki(25,`dd`),DD(26),pl()(),ki(27,`div`,35)(28,`dt`),DD(29),kD(30,`t`),pl(),ki(31,`dd`,36)(32,`code`),DD(33),pl()()(),$I(34,Re,6,2,`div`,35,De),pl(),ki(36,`details`,37)(37,`summary`),DD(38),kD(39,`t`),pl(),ki(40,`pre`),DD(41),pl()(),ki(42,`div`,31)(43,`button`,38),uh(`click`,function(){let p=Yu(e),S=XI();return Qu(S.execute(p.plan,p.plan_token))}),ah(44,`ui-icon`,10),DD(45),kD(46,`t`),pl(),ki(47,`button`,33),uh(`click`,function(){Yu(e);let p=XI();return Qu(p.pending.set(null))}),DD(48),kD(49,`t`),pl()()()}if(n&2){let e=i,l=XI();Vv(2),yh(LD(3,17,`tasks.plan`)),Vv(3),yh(LD(6,19,`tasks.plan.review`)),Vv(5),yh(LD(11,21,`tasks.plan.task`)),Vv(3),yh(l.planField(e.plan,`label`)||l.planField(e.plan,`verb`)),Vv(3),yh(LD(17,23,`tasks.plan.verb`)),Vv(4),yh(l.planField(e.plan,`verb`)),Vv(3),yh(LD(24,25,`tasks.plan.intent`)),Vv(3),yh(l.planField(e.plan,`intent`)),Vv(3),yh(LD(30,27,`tasks.correlation`)),Vv(2),$i(`title`,l.realCorrelation(l.planCorrelation(e))),Vv(2),yh(l.planCorrelation(e)),Vv(),zI(l.planArgs(e.plan)),Vv(4),yh(LD(39,29,`fdoc.raw`)),Vv(3),yh(l.planText(e.plan)),Vv(2),sh(`disabled`,l.busy()),Vv(),sh(`size`,14),Vv(),ml(` `,LD(46,31,`tasks.execute`),` `),Vv(3),yh(LD(49,33,`state.cancel`))}}function Ae(n,i){if(n&1&&ah(0,`ui-state-badge`,41),n&2){let e=XI(),l=XI();sh(`state`,l.stageKind(e.task.stage))(`labelOverride`,e.task.stage)}}function je(n,i){if(n&1&&(ki(0,`span`,21),DD(1),pl()),n&2){let e=XI();Vv(),ml(`exit `,e.task.exit_code)}}function Le(n,i){if(n&1&&(ki(0,`span`),DD(1),pl()),n&2){let e=XI();Vv(),yh(e.detail)}}function Je(n,i){if(n&1&&(ki(0,`div`,35)(1,`dt`),DD(2),kD(3,`t`),pl(),ki(4,`dd`),DD(5),pl()(),ki(6,`div`,35)(7,`dt`),DD(8),kD(9,`t`),pl(),ki(10,`dd`,47),DD(11),pl()()),n&2){let e=XI(),l=XI();Vv(2),yh(LD(3,4,`table.task`)),Vv(3),yh(e.task.label),Vv(3),yh(LD(9,6,`table.duration`)),Vv(3),yh(l.duration(e.task))}}function Ke(n,i){if(n&1&&DD(0),n&2){let e=XI(2);ml(` — `,e.unlock,` `)}}function qe(n,i){if(n&1&&(ki(0,`p`,42)(1,`code`),DD(2),pl(),jI(3,Ke,1,1),pl()),n&2){let e=XI();Vv(2),yh(e.refusal??e.task.refusal),Vv(),HI(e.unlock?3:-1)}}function He(n,i){if(n&1&&(ki(0,`li`)(1,`code`),DD(2),pl(),ki(3,`code`,48),DD(4),pl(),ki(5,`span`),DD(6),pl()()),n&2){let e=i.$implicit;Vv(2),yh(e.status),Vv(2),yh(e.kind),Vv(2),yh(e.path)}}function Ge(n,i){if(n&1&&(ki(0,`ul`,43),$I(1,He,7,3,`li`,null,UI),pl()),n&2){let e=XI();Vv(),zI(e.actions)}}function Qe(n,i){n&1&&ah(0,`ui-forge-doc`,44),n&2&&sh(`doc`,i)}function We(n,i){if(n&1){let e=YI();ki(0,`section`,14)(1,`h2`),DD(2),kD(3,`t`),pl(),ki(4,`p`,39),ah(5,`ui-state-badge`,40),jI(6,Ae,1,2,`ui-state-badge`,41),jI(7,je,2,1,`span`,21),jI(8,Le,2,1,`span`),pl(),ki(9,`dl`,34)(10,`div`,35)(11,`dt`),DD(12),kD(13,`t`),pl(),ki(14,`dd`,36)(15,`code`),DD(16),pl()()(),jI(17,Je,12,8),pl(),jI(18,qe,4,2,`p`,42),jI(19,Ge,3,0,`ul`,43),jI(20,Qe,1,1,`ui-forge-doc`,44),ki(21,`details`,37)(22,`summary`),DD(23),kD(24,`t`),pl(),ki(25,`pre`),DD(26),pl()(),ki(27,`div`,31)(28,`button`,45),uh(`click`,function(){let p=Yu(e),S=XI();return Qu(S.exportReceipt(p))}),ah(29,`ui-icon`,46),DD(30),kD(31,`t`),pl(),ki(32,`button`,33),uh(`click`,function(){Yu(e);let p=XI();return Qu(p.receipt.set(null))}),DD(33),kD(34,`t`),pl()()()}if(n&2){let e,l=i,p=XI();Vv(2),yh(LD(3,17,`tasks.result`)),Vv(3),sh(`state`,l.status),Vv(),HI(l.task?.stage?6:-1),Vv(),HI(l.task?.exit_code!==null&&l.task?.exit_code!==void 0?7:-1),Vv(),HI(l.detail?8:-1),Vv(4),yh(LD(13,19,`tasks.correlation`)),Vv(2),$i(`title`,p.realCorrelation(p.receiptCorrelation(l))),Vv(2),yh(p.receiptCorrelation(l)),Vv(),HI(l.task?17:-1),Vv(),HI(l.refusal||l.task?.refusal?18:-1),Vv(),HI(l.actions?.length?19:-1),Vv(),HI((e=p.receiptDoc(l))?20:-1,e),Vv(3),yh(LD(24,21,`fdoc.raw`)),Vv(3),yh(p.receiptText(l)),Vv(3),sh(`size`,14),Vv(),ml(` `,LD(31,23,`tasks.export`),` `),Vv(3),yh(LD(34,25,`state.close`))}}function Xe(n,i){if(n&1){let e=YI();ki(0,`ui-error`,49),uh(`retry`,function(){Yu(e);let p=XI();return Qu(p.load())}),pl()}n&2&&sh(`error`,i)}function Ye(n,i){n&1&&ah(0,`div`,28)}function Ze(n,i){if(n&1&&(ki(0,`tr`)(1,`td`),DD(2),pl(),ki(3,`td`)(4,`code`),DD(5),pl()(),ki(6,`td`),ah(7,`ui-state-badge`,41),pl(),ki(8,`td`,36)(9,`code`),DD(10),pl()(),ki(11,`td`,47),DD(12),pl(),ki(13,`td`),DD(14),pl()()),n&2){let e=i.$implicit,l=XI(2);Vv(2),yh(e.label),Vv(3),yh(e.verb),Vv(2),sh(`state`,l.stageKind(e.stage))(`labelOverride`,e.stage),Vv(),$i(`title`,e.correlation_id??null),Vv(2),yh(e.correlation_id??`—`),Vv(2),yh(l.duration(e)),Vv(2),yh(e.exit_code??`—`)}}function et(n,i){if(n&1&&(ki(0,`table`,29)(1,`thead`)(2,`tr`)(3,`th`)(4,`span`,50),DD(5),kD(6,`t`),pl()(),ki(7,`th`),DD(8),kD(9,`t`),pl(),ki(10,`th`),DD(11),kD(12,`t`),pl(),ki(13,`th`),DD(14),kD(15,`t`),pl(),ki(16,`th`),DD(17),kD(18,`t`),pl(),ki(19,`th`),DD(20),kD(21,`t`),pl()()(),ki(22,`tbody`),$I(23,Ze,15,8,`tr`,null,Ue),pl()()),n&2){let e=XI();Vv(5),yh(LD(6,6,`table.task`)),Vv(3),yh(LD(9,8,`table.verb`)),Vv(3),yh(LD(12,10,`table.stage`)),Vv(3),yh(LD(15,12,`table.correlation`)),Vv(3),yh(LD(18,14,`table.duration`)),Vv(3),yh(LD(21,16,`table.exit`)),Vv(3),zI(e.tasks())}}function tt(n,i){n&1&&(ah(0,`ui-empty`,51),kD(1,`t`)),n&2&&sh(`title`,LD(1,1,`tasks.empty`))}function nt(n,i){if(n&1&&jI(0,tt,2,3,`ui-empty`,51),n&2){let e=XI();HI(e.loading()?-1:0)}}var ne=class n{api=g(hg);intent=Te$1(``);pending=Te$1(null);receipt=Te$1(null);tasks=Te$1([]);error=Te$1(null);stale=Te$1(null);busy=Te$1(!1);executing=Te$1(!1);loading=Te$1(!0);constructor(){this.load()}async load(){try{this.tasks.set(await Tg(this.api.tasks()))}catch(i){this.error.set(i instanceof jn?i:new jn(0))}finally{this.loading.set(!1)}}async plan(){if(!(this.busy()||!this.intent().trim())){this.busy.set(!0),this.error.set(null),this.stale.set(null),this.receipt.set(null);try{let i=await Tg(this.api.tasksPlan({intent:this.intent()})),e=i.correlation_id;this.pending.set({plan_token:i.plan_token,plan:i.plan,correlation_id:typeof e==`string`&&e?e:null})}catch(i){this.error.set(i instanceof jn?i:new jn(0))}finally{this.busy.set(!1)}}}async execute(i,e){if(!this.busy()){this.busy.set(!0),this.executing.set(!0),this.error.set(null);try{this.receipt.set(await Tg(this.api.tasksExecute(i,e))),this.pending.set(null),await this.load()}catch(l){let p=l instanceof jn?l:new jn(0);p.body.code===`PORTAL-PLAN-STALE`?(this.pending.set(null),this.stale.set(p)):this.error.set(p)}finally{this.busy.set(!1),this.executing.set(!1)}}}async regenerate(){this.busy()||!this.stale()||(this.stale.set(null),await this.plan())}exportReceipt(i){let e=new Blob([JSON.stringify(i,null,2)],{type:`application/json`}),l=URL.createObjectURL(e),p=document.createElement(`a`);p.href=l,p.download=i.task?.id?`receipt-${i.task.id}.json`:`receipt.json`,p.click(),URL.revokeObjectURL(l)}planText(i){return JSON.stringify(i,null,2)}receiptText(i){return JSON.stringify(i,null,2)}planCorrelation(i){if(i.correlation_id)return i.correlation_id;let e=i.plan.correlation_id;return typeof e==`string`&&e?e:`—`}receiptCorrelation(i){let e=i.task?.correlation_id;if(e)return e;let l=i.correlation_id;return typeof l==`string`&&l?l:`—`}realCorrelation(i){return i===`—`?null:i}duration(i){if(!i.started_at||!i.finished_at)return`—`;let e=Date.parse(i.finished_at)-Date.parse(i.started_at);if(!Number.isFinite(e)||e<0)return`—`;if(e<1e3)return`${e} ms`;let l=e/1e3;if(l<60)return`${Number(l.toFixed(1))} s`;let p=Math.floor(l/60);return`${p}m ${Math.round(l-p*60)}s`}planField(i,e){let l=i[e];return l==null?``:String(l)}planArgs(i){let e=i.args;return!e||typeof e!=`object`?[]:Object.entries(e).map(([l,p])=>[l,typeof p==`object`?JSON.stringify(p):String(p)])}receiptDoc(i){let e=i.task?.receipt;return e&&typeof e==`object`?e:null}stageKind(i){let e=(i||``).toLowerCase();return e===`completed`?`supported`:[`failed`,`refused`,`cancelled`].includes(e)?`error`:[`awaiting_approval`,`partial`].includes(e)?`warn`:[`running`,`planning`,`verifying`].includes(e)?`info`:`muted`}static ɵfac=function(e){return new(e||n)};static ɵcmp=sl({type:n,selectors:[[`page-tasks`]],decls:67,vars:59,consts:[[3,`title`,`subtitle`],[1,`btn`,3,`click`,`disabled`],[`name`,`refresh`,3,`size`],[`data-section`,`intent`,1,`card`],[`for`,`intent`,1,`lbl`],[1,`intent-row`],[1,`search-field`,`intent-field`],[`name`,`terminal`,3,`size`],[`id`,`intent`,`type`,`text`,1,`input`,3,`ngModelChange`,`keydown.enter`,`placeholder`,`ngModel`,`disabled`],[`data-action`,`plan`,1,`btn`,`btn--primary`,3,`click`,`disabled`],[`name`,`tasks`,3,`size`],[`role`,`status`,`aria-live`,`polite`,`data-section`,`running`,1,`card`,`running`],[`role`,`alert`,`data-section`,`stale`,1,`card`,`stale`],[`data-lift`,``,`data-section`,`plan`,1,`card`],[`data-lift`,``,`data-section`,`receipt`,`aria-live`,`polite`,1,`card`],[3,`error`],[`aria-labelledby`,`ops-h`,`data-section`,`ops`,1,`card`,`ops`],[`id`,`ops-h`],[1,`ops__list`],[`data-op`,`plan`,1,`op`],[1,`op__body`],[1,`muted`],[`state`,`supported`],[`data-op`,`execute`,1,`op`],[`data-op`,`cancel`,`data-state`,`unverified`,1,`op`],[`state`,`unverified`],[1,`muted`,`limits`],[`data-section`,`history`,1,`card`],[1,`skeleton`,`skeleton--block`],[1,`table`],[`aria-hidden`,`true`,1,`running__spinner`],[1,`row`],[`data-action`,`regenerate`,1,`btn`,`btn--primary`,3,`click`,`disabled`],[1,`btn`,3,`click`],[1,`plan-card`],[1,`kv`],[1,`corr`],[1,`raw`],[`data-action`,`execute`,1,`btn`,`btn--primary`,3,`click`,`disabled`],[1,`receipt__status`],[3,`state`],[3,`state`,`labelOverride`],[`role`,`alert`,1,`refusal`],[1,`actions`],[3,`doc`],[`data-action`,`export`,1,`btn`,3,`click`],[`name`,`install`,3,`size`],[1,`num`],[1,`actions__kind`],[3,`retry`,`error`],[1,`sr-only`],[`icon`,`tasks`,3,`title`]],template:function(e,l){if(e&1&&(ki(0,`ui-page-header`,0),kD(1,`t`),kD(2,`t`),ki(3,`button`,1),uh(`click`,function(){return l.load()}),ah(4,`ui-icon`,2),DD(5),kD(6,`t`),pl()(),ki(7,`section`,3)(8,`label`,4),DD(9),kD(10,`t`),pl(),ki(11,`div`,5)(12,`div`,6),ah(13,`ui-icon`,7),ki(14,`input`,8),kD(15,`t`),CE(),uh(`ngModelChange`,function(S){return l.intent.set(S)})(`keydown.enter`,function(){return l.plan()}),pl()(),ki(16,`button`,9),uh(`click`,function(){return l.plan()}),ah(17,`ui-icon`,10),DD(18),kD(19,`t`),pl()()(),jI(20,$e,5,3,`section`,11),jI(21,ze,19,16,`section`,12),jI(22,Ve,50,35,`section`,13),jI(23,We,35,27,`section`,14),jI(24,Xe,1,1,`ui-error`,15),ki(25,`section`,16)(26,`h2`,17),DD(27),kD(28,`t`),pl(),ki(29,`ul`,18)(30,`li`,19)(31,`span`,20)(32,`strong`),DD(33),kD(34,`t`),pl(),ki(35,`small`,21),DD(36),kD(37,`t`),pl()(),ah(38,`ui-state-badge`,22),pl(),ki(39,`li`,23)(40,`span`,20)(41,`strong`),DD(42),kD(43,`t`),pl(),ki(44,`small`,21),DD(45),kD(46,`t`),pl()(),ah(47,`ui-state-badge`,22),pl(),ki(48,`li`,24)(49,`span`,20)(50,`strong`),DD(51),kD(52,`t`),pl(),ki(53,`small`,21),DD(54),kD(55,`t`),pl()(),ah(56,`ui-state-badge`,25),pl()(),ki(57,`p`,26),DD(58),kD(59,`t`),pl()(),ki(60,`section`,27)(61,`h2`),DD(62),kD(63,`t`),pl(),jI(64,Ye,1,0,`div`,28),jI(65,et,25,18,`table`,29)(66,nt,1,1),pl()),e&2){let p,S,x,T;sh(`title`,LD(1,29,`tasks.title`))(`subtitle`,LD(2,31,`tasks.subtitle`)),Vv(3),sh(`disabled`,l.busy()),Vv(),sh(`size`,15),Vv(),ml(` `,LD(6,33,`state.refresh`),` `),Vv(4),yh(LD(10,35,`tasks.intent.label`)),Vv(4),sh(`size`,15),Vv(),sh(`placeholder`,LD(15,37,`tasks.intent.placeholder`))(`ngModel`,l.intent())(`disabled`,l.busy()),_E(),Vv(2),sh(`disabled`,l.busy()||!l.intent().trim()),Vv(),sh(`size`,14),Vv(),ml(` `,LD(19,39,`tasks.intent.run`),` `),Vv(2),HI(l.executing()?20:-1),Vv(),HI((p=l.stale())?21:-1,p),Vv(),HI((S=l.pending())?22:-1,S),Vv(),HI((x=l.receipt())?23:-1,x),Vv(),HI((T=l.error())?24:-1,T),Vv(3),yh(LD(28,41,`tasks.ops.title`)),Vv(6),yh(LD(34,43,`tasks.intent.run`)),Vv(3),yh(LD(37,45,`tasks.ops.plan.hint`)),Vv(6),yh(LD(43,47,`tasks.execute`)),Vv(3),yh(LD(46,49,`tasks.ops.execute.hint`)),Vv(6),yh(LD(52,51,`state.cancel`)),Vv(3),yh(LD(55,53,`tasks.ops.cancel.hint`)),Vv(4),yh(LD(59,55,`tasks.limits`)),Vv(4),yh(LD(63,57,`tasks.recent`)),Vv(2),HI(l.loading()?64:-1),Vv(),HI(l.tasks().length?65:66)}},dependencies:[Zt,De$1,Yt,At,_$1,I,_,w,Eg,z,yg],styles:[`.card[_ngcontent-%COMP%]{margin-bottom:var(--%NS%space-4)}h2[_ngcontent-%COMP%]{margin:0 0 var(--%NS%space-3);font-size:var(--%NS%font-lg);font-weight:650;letter-spacing:-.01em}.lbl[_ngcontent-%COMP%]{display:block;font-weight:600;margin-bottom:var(--%NS%space-2)}.intent-row[_ngcontent-%COMP%]{display:flex;gap:var(--%NS%space-2)}.intent-field[_ngcontent-%COMP%]{flex:1;max-width:none;margin-bottom:0}.plan-card[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:var(--%NS%space-2) var(--%NS%space-4);margin:var(--%NS%space-3) 0}.kv[_ngcontent-%COMP%] dt[_ngcontent-%COMP%]{font-size:var(--%NS%font-xs);color:var(--%NS%fg-muted);text-transform:uppercase;letter-spacing:.04em}.kv[_ngcontent-%COMP%] dd[_ngcontent-%COMP%]{margin:0;font-weight:550;word-break:break-all}.corr[_ngcontent-%COMP%]{max-width:170px}.corr[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.num[_ngcontent-%COMP%]{font-variant-numeric:tabular-nums;white-space:nowrap}.raw[_ngcontent-%COMP%]{margin:var(--%NS%space-2) 0}.raw[_ngcontent-%COMP%] pre[_ngcontent-%COMP%]{background:var(--%NS%bg);border:1px solid var(--%NS%border);border-radius:var(--%NS%radius-md);padding:var(--%NS%space-3);overflow-x:auto;font-size:var(--%NS%font-xs)}.row[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:var(--%NS%space-2);margin-top:var(--%NS%space-3)}.muted[_ngcontent-%COMP%]{color:var(--%NS%fg-muted)}.limits[_ngcontent-%COMP%]{margin:var(--%NS%space-3) 0 0;font-size:var(--%NS%font-xs)}.refusal[_ngcontent-%COMP%]{color:var(--%NS%warn)}.receipt__status[_ngcontent-%COMP%]{display:flex;align-items:center;flex-wrap:wrap;gap:var(--%NS%space-3)}.running[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--%NS%space-3)}.running[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0}.running__spinner[_ngcontent-%COMP%]{width:18px;height:18px;flex:none;border-radius:50%;border:2px solid var(--%NS%accent-bg);border-top-color:var(--%NS%accent);animation:_ngcontent-%COMP%_fg-spin .8s linear infinite}@keyframes _ngcontent-%COMP%_fg-spin{to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){.running__spinner[_ngcontent-%COMP%]{animation:none;border-top-color:var(--%NS%border-strong)}}.stale[_ngcontent-%COMP%]{border-left:3px solid var(--%NS%warn)}.stale[_ngcontent-%COMP%] p[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{color:var(--%NS%warn)}.actions[_ngcontent-%COMP%]{font-family:var(--%NS%font-mono);font-size:var(--%NS%font-sm);list-style:none;padding:0;margin:0 0 var(--%NS%space-3);display:grid;gap:6px;max-height:200px;overflow:auto}.actions[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{display:flex;gap:var(--%NS%space-2);overflow-wrap:anywhere}.actions[_ngcontent-%COMP%] li[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{color:var(--%NS%accent);flex:none}.actions__kind[_ngcontent-%COMP%]{color:var(--%NS%fg-muted)!important}.ops__list[_ngcontent-%COMP%]{list-style:none;padding:0;margin:0;display:grid;gap:var(--%NS%space-2)}.op[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:var(--%NS%space-3);padding:var(--%NS%space-3);border:1px solid var(--%NS%border);border-radius:var(--%NS%radius-md)}.op[data-state=unverified][_ngcontent-%COMP%]{border-style:dashed;opacity:.8}.op__body[_ngcontent-%COMP%]{display:grid;gap:2px;min-width:0}.op__body[_ngcontent-%COMP%] small[_ngcontent-%COMP%]{color:var(--%NS%fg-muted)}`]})};export{ne as TasksPage};
@@ -0,0 +1 @@
1
+ import{$ as ah,At as sl,Bt as zr,Et as pl,Mt as us,R as SL,T as JI,U as Vv,Y as Zi,c as $i,g as Eg,it as eD,jt as uh,kt as sh,st as g,yt as ki}from"./main-QDFVZK3T.js";var C=[`*`];var h=class l{i18n=g(us);placeholder=Zi(``);query=SL(``);label=zr(()=>{let e=this.placeholder();if(!e)return``;let t=this.i18n.t(e);return t.startsWith(`⟪`)?e:t});onQuery(e){this.query.set(e.target.value)}static ɵfac=function(t){return new(t||l)};static ɵcmp=sl({type:l,selectors:[[`ui-filter-bar`]],inputs:{placeholder:[1,`placeholder`],query:[1,`query`]},outputs:{query:`queryChange`},ngContentSelectors:C,decls:6,vars:4,consts:[[1,`fb`],[1,`fb__search`],[`name`,`search`,3,`size`],[`type`,`search`,1,`input`,`fb__input`,3,`input`,`value`,`placeholder`],[1,`fb__chips`]],template:function(t,n){t&1&&(JI(),ki(0,`div`,0)(1,`div`,1),ah(2,`ui-icon`,2),ki(3,`input`,3),uh(`input`,function(M){return n.onQuery(M)}),pl()(),ki(4,`div`,4),eD(5),pl()()),t&2&&(Vv(2),sh(`size`,15),Vv(),sh(`value`,n.query())(`placeholder`,n.label()),$i(`aria-label`,n.label()||null))},dependencies:[Eg],styles:[`.fb[_ngcontent-%COMP%]{display:grid;gap:var(--%NS%space-2);margin-bottom:var(--%NS%space-4)}.fb__search[_ngcontent-%COMP%]{position:relative;max-width:360px}.fb__search[_ngcontent-%COMP%] ui-icon[_ngcontent-%COMP%]{position:absolute;left:10px;top:50%;translate:0 -50%;color:var(--%NS%fg-muted);pointer-events:none}.fb__input[_ngcontent-%COMP%]{padding-left:32px}.fb__chips[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:var(--%NS%space-2)}.fb__chips[_ngcontent-%COMP%]:empty{display:none}`]})};export{h as t};
@@ -0,0 +1 @@
1
+ import{$ as ah,At as sl,B as Te$1,Bt as zr,Dt as qf,Et as pl,G as XI,H as UI,I as SD,It as yg,K as YI,Lt as yh,Nt as vh,O as LD,P as Qu,Rt as zI,U as Vv,V as Tg,_ as FD,c as $i,dt as hg,g as Eg,gt as jI,h as Dh,jt as uh,kt as sh,l as AD,m as DD,q as Yu,r as g$1,s as $I,st as g,u as BI,vt as kD,w as Ih,xt as ml,y as HI,yt as ki}from"./main-QDFVZK3T.js";import{a as l,n as c}from"./chunk-DQU0VyoQ.js";import{t as h}from"./chunk-DqWNkF1O.js";import{t as _}from"./chunk-BaQMhq-G.js";import{t as w}from"./chunk-BVKnCv85.js";import{t as I}from"./chunk-DyIHOW_a.js";import{t as _$1}from"./chunk-C4gpbtbP.js";import{t as h$1}from"./chunk-CJCT86Dr.js";var Pe=`forge/FederatedGraph/v1`;var J=[`forge`,`capability`,`skill`,`agent`,`mcp`,`host`,`operation`];var be=[`bootstrap`,`graphs`,`capabilities`,`skills`,`agents`,`mcp`,`hosts`,`tasks`];var Y={bootstrap:`GET /api/v1/bootstrap`,graphs:`GET /api/v1/graphs`,capabilities:`GET /api/v1/capabilities`,skills:`GET /api/v1/skills`,agents:`GET /api/v1/agents`,mcp:`GET /api/v1/mcp/servers`,hosts:`GET /api/v1/hosts`,tasks:`GET /api/v1/tasks`};function xe(n,t){let e=n.edges.filter(d=>d.source===t||d.target===t),r=new Set([t]);for(let d of e)r.add(d.source),r.add(d.target);return{nodes:r,edges:e}}var z=(n,t)=>n<t?-1:n>t?1:0;var Fe=new Set([`the-forge`,`api-forge`,`spark-forge-aws`,`spark-forge-azure`,`platform-forge`,`forge-doctor-data`,`forge-doctor-api`]);var Ee=[`origin`,`forge`,`forge_id`,`provider`,`source_provider`];function v(n){return typeof n==`string`&&n.trim()?n.trim():null}function W(n,t){for(let r of Ee){let d=v(n[r]);if(d)return d}let e=v(n.source);return e&&(Fe.has(e)||t.has(e))?e:null}function Ce(n){let t={};for(let i of be){let a=n.availability?.[i];if(a)t[i]=a;else if(i===`bootstrap`)t[i]=v(n.servingForge)?`loaded`:`unverified`;else t[i]=(i===`capabilities`?n.capabilities:i===`skills`?n.skills:i===`agents`?n.agents:i===`mcp`?n.mcp:i===`hosts`?n.hosts:i===`tasks`?n.tasks:n.graphViews)!=null?`loaded`:`unavailable`}let e=new Map,r=new Map,d=new Set;function _(i,a,c,m,x=!1){let w=`${i}:${a}`,q=e.get(w);return q?(q.evidence.add(m),q.flagged||=x):e.set(w,{label:c,kind:i,evidence:new Set([m]),flagged:x}),w}function k(i,a){return d.add(i),_(`forge`,i,i,a)}function E(i,a){if(e.has(i)){e.get(i).evidence.add(a);return}let c=i.indexOf(`:`);_(i.slice(0,c),i.slice(c+1),i.slice(c+1),a)}function A(i,a,c,m){E(i,m),E(a,m);let x=`${i}|${c}|${a}`;r.has(x)||r.set(x,{id:x,source:i,target:a,kind:c,evidence:m})}let R=v(n.servingForge);R&&k(R,`bootstrap`);for(let i of n.graphViews??[]){if(!i||typeof i!=`object`)continue;let a=i.descriptor,c=a&&typeof a==`object`?v(a.provider_id):null;c&&k(c,`graphs`);let m=i.nodes;if(Array.isArray(m))for(let x of m){let w=x&&typeof x==`object`?v(x.source_provider):null;w&&k(w,`graphs`)}}for(let i of n.capabilities??[]){let a=v(i?.id);a&&(_(`capability`,a,a,`capabilities`,i.state===`unverified`),R&&A(`forge:${R}`,`capability:${a}`,`declares`,`capabilities`))}for(let i of n.skills??[]){let a=v(i?.id)??v(i?.name);if(!a)continue;_(`skill`,a,v(i?.name)??a,`skills`,i.state===`unverified`);let c=W(i,d);c&&A(`skill:${a}`,`forge:${c}`,`origin`,`skills`)}let K=new Map;for(let i of n.skills??[]){let a=v(i?.name),c=v(i?.id);if(a&&c){let m=K.get(a)??[];m.push(c),K.set(a,m)}}let we=i=>{if(e.has(`skill:${i}`))return`skill:${i}`;let a=K.get(i);return a?.length?`skill:${[...a].sort(z)[0]}`:`skill:${i}`};for(let i of n.agents??[]){let a=v(i?.id)??v(i?.name);if(!a)continue;_(`agent`,a,v(i?.name)??a,`agents`,i.state===`unverified`);let c=W(i,d);c&&A(`agent:${a}`,`forge:${c}`,`origin`,`agents`);let m=new Set;for(let x of i.skills??[]){let w=v(x);!w||m.has(w)||(m.add(w),A(`agent:${a}`,we(w),`associated`,`agents`))}}for(let i of n.mcp??[]){let a=v(i?.id);if(!a)continue;_(`mcp`,a,a,`mcp`);let c=v(i.host);c&&A(`mcp:${a}`,`host:${c}`,`bound_to`,`mcp`)}for(let i of n.hosts??[]){let a=v(i?.host);a&&_(`host`,a,a,`hosts`)}for(let i of n.tasks??[]){let a=v(i?.id);if(!a)continue;_(`operation`,a,v(i?.label)??v(i?.verb)??a,`tasks`);let m=W(i,d);m&&A(`operation:${a}`,`forge:${m}`,`origin`,`tasks`)}let Z=[...e.entries()].map(([i,a])=>{let c=[...a.evidence].sort(z);return{id:i,kind:a.kind,label:a.label,evidence:c,unverified:a.flagged||!c.some(m=>t[m]===`loaded`)}}).sort((i,a)=>z(i.id,a.id)),Ne=[...r.values()].sort((i,a)=>z(i.id,a.id)),ee=Object.fromEntries(J.map(i=>[i,0]));for(let i of Z)ee[i.kind]+=1;let te={};for(let i of be)te[i]={state:t[i],endpoint:Y[i]};return{schema:Pe,nodes:Z,edges:Ne,counts:ee,sources:te}}var Se=n=>({count:n});var X=(n,t)=>t.id;function Oe(n,t){if(n&1){let e=YI();ki(0,`ui-error`,6),uh(`retry`,function(){Yu(e);let d=XI();return Qu(d.load())}),pl()}n&2&&sh(`error`,t)}function Me(n,t){n&1&&(ki(0,`div`,4),kD(1,`t`),ah(2,`ui-skeleton`,7),pl()),n&2&&($i(`aria-label`,LD(1,2,`state.loading`)),Vv(2),sh(`lines`,2))}function Ge(n,t){if(n&1&&(ki(0,`a`,10),DD(1),kD(2,`t`),ah(3,`ui-icon`,12),pl()),n&2){let e=XI(2);sh(`href`,e.studio_url,qf),Vv(),ml(` `,LD(2,3,`graph.open`),` `),Vv(2),sh(`size`,14)}}function Te(n,t){if(n&1&&(ki(0,`li`)(1,`strong`),ah(2,`ui-icon`,13),DD(3),pl(),ki(4,`span`,14),DD(5),kD(6,`t`),kD(7,`t`),pl()()),n&2){let e=t.$implicit,r=XI(3);Vv(2),sh(`size`,14),Vv(),yh(r.viewName(e)),Vv(2),vh(` `,FD(6,4,`graph.nodes`,AD(10,Se,r.viewNodes(e))),` · `,FD(7,7,`graph.edges`,AD(12,Se,r.viewEdges(e))),` `)}}function Ie(n,t){if(n&1&&(ki(0,`section`,8),jI(1,Ge,4,5,`a`,10),ki(2,`ul`,11),$I(3,Te,8,14,`li`,null,UI),pl()()),n&2){let e=XI();Vv(),HI(e.studio_url?1:-1),Vv(2),zI(e.views)}}function Be(n,t){if(n&1&&(ah(0,`ui-empty`,9),kD(1,`t`),kD(2,`t`)),n&2){let e=XI();sh(`title`,LD(1,2,`graph.unavailable`))(`hint`,e.availability.unlock??LD(2,4,`graph.buildHint`))}}function De(n,t){n&1&&jI(0,Ie,5,1,`section`,8)(1,Be,3,6,`ui-empty`,9),n&2&&HI(t.availability.state===`available`?0:1)}function Ae(n,t){if(n&1&&(ki(0,`li`)(1,`code`),DD(2),pl(),ah(3,`ui-state-badge`,24),kD(4,`t`),pl()),n&2){let e=t.$implicit,r=XI(2);$i(`data-source`,e.id)(`data-state`,e.info.state),Vv(2),yh(e.info.endpoint),Vv(),sh(`state`,r.sourceBadge(e.info.state))(`labelOverride`,LD(4,5,`graph.source.`+e.info.state))}}function Re(n,t){if(n&1){let e=YI();ki(0,`button`,26),uh(`click`,function(){let d=Yu(e).$implicit,_=XI(3);return Qu(_.toggleKind(d))}),DD(1),pl()}if(n&2){let e=t.$implicit,r=XI(2),d=XI();$i(`data-tone`,d.kind()===e?`accent`:null)(`aria-pressed`,d.kind()===e)(`data-kind-chip`,e),Vv(),vh(` `,e,` · `,r.counts[e],` `)}}function Ve(n,t){if(n&1){let e=YI();ki(0,`ui-filter-bar`,25),kD(1,`t`),Dh(`queryChange`,function(d){Yu(e);let _=XI(2);return SD(_.query,d)||(_.query=d),Qu(d)}),ki(2,`button`,26),uh(`click`,function(){Yu(e);let d=XI(2);return Qu(d.kind.set(null))}),DD(3),kD(4,`t`),pl(),$I(5,Re,2,5,`button`,27,BI),pl()}if(n&2){let e=XI(),r=XI();Ih(`query`,r.query),sh(`placeholder`,LD(1,6,`graph.fed.search`)),Vv(2),$i(`data-tone`,r.kind()===null?`accent`:null)(`aria-pressed`,r.kind()===null),Vv(),vh(` `,LD(4,8,`state.all`),` · `,e.nodes.length,` `),Vv(2),zI(r.kindOptions(e))}}function $e(n,t){n&1&&ah(0,`ui-state-badge`,29)}function ze(n,t){if(n&1&&(ki(0,`code`),DD(1),pl()),n&2){let e=t.$implicit,r=XI(3);Vv(),yh(r.endpointFor(e))}}function Ke(n,t){if(n&1){let e=YI();ki(0,`li`)(1,`button`,36),uh(`click`,function(){let d=Yu(e).$implicit,_=XI(3);return Qu(_.selectId(d.source))}),DD(2),pl(),ki(3,`code`),DD(4),pl(),ki(5,`button`,36),uh(`click`,function(){let d=Yu(e).$implicit,_=XI(3);return Qu(_.selectId(d.target))}),DD(6),pl(),ki(7,`code`,37),DD(8),pl()()}if(n&2){let e=t.$implicit,r=XI(3);Vv(2),ml(` `,r.label(e.source),` `),Vv(2),yh(e.kind),Vv(2),ml(` `,r.label(e.target),` `),Vv(2),yh(r.endpointFor(e.evidence))}}function qe(n,t){n&1&&(ki(0,`li`,14),DD(1),kD(2,`t`),pl()),n&2&&(Vv(),yh(LD(2,1,`graph.fed.noImpact`)))}function je(n,t){if(n&1){let e=YI();ki(0,`section`,21)(1,`header`,28)(2,`h2`),ah(3,`ui-icon`,13),DD(4),jI(5,$e,1,0,`ui-state-badge`,29),pl(),ki(6,`button`,30),kD(7,`t`),uh(`click`,function(){Yu(e);let d=XI(2);return Qu(d.selected.set(null))}),ah(8,`ui-icon`,31),pl()(),ki(9,`dl`,32)(10,`div`)(11,`dt`),DD(12),kD(13,`t`),pl(),ki(14,`dd`)(15,`code`),DD(16),pl()()(),ki(17,`div`)(18,`dt`),DD(19),kD(20,`t`),pl(),ki(21,`dd`)(22,`code`),DD(23),pl()()(),ki(24,`div`)(25,`dt`),DD(26),kD(27,`t`),pl(),ki(28,`dd`),ah(29,`ui-state-badge`,24),kD(30,`t`),pl()(),ki(31,`div`)(32,`dt`),DD(33),kD(34,`t`),pl(),ki(35,`dd`,33),$I(36,ze,2,1,`code`,null,BI),pl()()(),ki(38,`h3`,34),DD(39),kD(40,`t`),pl(),ki(41,`ul`,35),$I(42,Ke,9,4,`li`,null,X,!1,qe,3,3,`li`,14),pl()()}if(n&2){let e=t,r=XI(2);Vv(3),sh(`size`,15),Vv(),ml(``,e.label,` `),Vv(),HI(e.unverified?5:-1),Vv(),$i(`aria-label`,LD(7,15,`state.close`)),Vv(2),sh(`size`,14),Vv(4),yh(LD(13,17,`table.id`)),Vv(4),yh(e.id),Vv(3),yh(LD(20,19,`graph.fed.kind`)),Vv(4),yh(e.kind),Vv(3),yh(LD(27,21,`graph.fed.verification`)),Vv(3),sh(`state`,e.unverified?`unverified`:`ok`)(`labelOverride`,LD(30,23,e.unverified?`state.unverified`:`graph.fed.observed`)),Vv(4),yh(LD(34,25,`skills.evidence`)),Vv(3),zI(e.evidence),Vv(3),yh(LD(40,27,`graph.fed.impact`)),Vv(3),zI(r.impact().edges)}}function He(n,t){n&1&&ah(0,`ui-state-badge`,29)}function Ue(n,t){if(n&1){let e=YI();ki(0,`li`)(1,`button`,38),uh(`click`,function(){let d=Yu(e).$implicit,_=XI(3);return Qu(_.select(d))}),ki(2,`span`,39),DD(3),pl(),ki(4,`span`,40),DD(5),pl(),ki(6,`code`,41),DD(7),pl(),jI(8,He,1,0,`ui-state-badge`,29),pl()()}if(n&2){let e=t.$implicit,r=XI(3);Vv(),$i(`data-unverified`,e.unverified||null)(`data-selected`,r.selected()?.id===e.id||null)(`data-neighbor`,r.isNeighbor(e)||null),Vv(2),yh(e.kind),Vv(2),yh(e.label),Vv(2),yh(e.id),Vv(),HI(e.unverified?8:-1)}}function Le(n,t){n&1&&(ki(0,`li`,14),DD(1),kD(2,`t`),pl()),n&2&&(Vv(),yh(LD(2,1,`graph.fed.empty`)))}function We(n,t){if(n&1&&(ki(0,`ul`,22),$I(1,Ue,9,7,`li`,null,X,!1,Le,3,3,`li`,14),pl()),n&2){let e=XI(2);Vv(),zI(e.filtered())}}function Je(n,t){n&1&&(ah(0,`ui-empty`,23),kD(1,`t`)),n&2&&sh(`title`,LD(1,1,`graph.fed.none`))}function Ye(n,t){if(n&1){let e=YI();ki(0,`section`,5)(1,`header`,15)(2,`h2`),ah(3,`ui-icon`,16),DD(4),kD(5,`t`),ki(6,`span`,17),DD(7),kD(8,`t`),pl()(),ki(9,`button`,18),uh(`click`,function(){Yu(e);let d=XI();return Qu(d.exportGraph())}),ah(10,`ui-icon`,12),DD(11),kD(12,`t`),pl()(),ki(13,`ul`,19),kD(14,`t`),$I(15,Ae,5,7,`li`,null,X),pl(),ki(17,`p`,14),DD(18),kD(19,`t`),pl(),jI(20,Ve,7,10,`ui-filter-bar`,20),jI(21,je,45,29,`section`,21),jI(22,We,4,1,`ul`,22)(23,Je,2,3,`ui-empty`,23),pl()}if(n&2){let e,r=t,d=XI();Vv(3),sh(`size`,15),Vv(),ml(` `,LD(5,11,`graph.fed.title`),` `),Vv(3),yh(LD(8,13,`graph.federated`)),Vv(2),sh(`disabled`,!r.nodes.length),Vv(),sh(`size`,14),Vv(),ml(` `,LD(12,15,`graph.fed.export`),` `),Vv(2),$i(`aria-label`,LD(14,17,`graph.fed.sources`)),Vv(2),zI(d.sourceList(r)),Vv(3),yh(LD(19,19,`graph.fed.evidenceNote`)),Vv(2),HI(r.nodes.length?20:-1),Vv(),HI((e=d.selected())?21:-1,e),Vv(),HI(r.nodes.length?22:23)}}var Q=n=>n.normalize(`NFD`).replace(new RegExp(`\\p{Diacritic}`,`gu`),``).toLowerCase().trim();var ke=class n{api=g(hg);store=g(g$1);bundle=Te$1(null);error=Te$1(null);loading=Te$1(!0);fed=Te$1(null);query=Te$1(``);kind=Te$1(null);selected=Te$1(null);srcs=[{id:`capabilities`,src:new l},{id:`skills`,src:new l},{id:`agents`,src:new l},{id:`mcp`,src:new l},{id:`hosts`,src:new l},{id:`tasks`,src:new l}];nodeById=zr(()=>{let t=new Map;for(let e of this.fed()?.nodes??[])t.set(e.id,e);return t});impact=zr(()=>{let t=this.selected(),e=this.fed();return!t||!e?{nodes:new Set,edges:[]}:xe(e,t.id)});filtered=zr(()=>{let t=this.fed();if(!t)return[];let e=Q(this.query()),r=this.kind();return t.nodes.filter(d=>r!==null&&d.kind!==r?!1:e?Q(d.id).includes(e)||Q(d.label).includes(e):!0)});constructor(){this.load()}async load(){this.error.set(null),this.loading.set(!0),this.selected.set(null);let t=Tg(this.api.graphs()).then(e=>this.bundle.set(e)).catch(e=>{this.bundle.set(null),this.error.set(c(e))});await Promise.allSettled([t,...this.srcs.map(e=>e.src.load(()=>this.read(e.id)))]),this.loading.set(!1),this.rebuild()}read(t){switch(t){case`capabilities`:return this.api.capabilities();case`skills`:return this.api.skills();case`agents`:return this.api.agents();case`mcp`:return this.api.mcpServers();case`hosts`:return this.api.hosts();case`tasks`:return this.api.tasks()}}rebuild(){let t=E=>E.data()!==null?`loaded`:E.unavailable()?`unavailable`:`unverified`,e=this.error(),r=this.bundle(),d=r?r.availability.state===`available`||r.availability.state===`no_graph`?`loaded`:`unverified`:e&&(e.status===404||e.body.code===`PORTAL-NOT-FOUND`)?`unavailable`:`unverified`,_=this.store.descriptor(),k={};for(let E of this.srcs)k[E.id]=t(E.src);k.graphs=d,k.bootstrap=_?`loaded`:`unverified`,this.fed.set(Ce({capabilities:this.data(`capabilities`),skills:this.data(`skills`),agents:this.data(`agents`),mcp:this.data(`mcp`),hosts:this.data(`hosts`),tasks:this.data(`tasks`),graphViews:this.bundle()?.views??null,servingForge:_?.forge_id??null,availability:k}))}data(t){return this.srcs.find(e=>e.id===t)?.src.data()??null}select(t){this.selected.set(t)}selectId(t){let e=this.nodeById().get(t);e&&this.selected.set(e)}isNeighbor(t){let e=this.selected();return e!==null&&e.id!==t.id&&this.impact().nodes.has(t.id)}toggleKind(t){this.kind.set(this.kind()===t?null:t)}kindOptions(t){return J.filter(e=>(t.counts[e]??0)>0)}label(t){return this.nodeById().get(t)?.label??t}endpointFor(t){return Y[t]}sourceList(t){return Object.entries(t.sources).map(([e,r])=>({id:e,info:r}))}sourceBadge(t){return t===`loaded`?`ok`:t===`unavailable`?`muted`:`warn`}exportJson(){return JSON.stringify(this.fed(),null,2)}exportGraph(){if(!this.fed())return;let t=document.createElement(`a`);t.href=`data:application/json;charset=utf-8,${encodeURIComponent(this.exportJson())}`,t.download=`forge-federated-graph.json`,t.click()}viewName(t){return String(t.view??t.name??`view`)}viewNodes(t){let e=t.nodes;return Array.isArray(e)?e.length:Number(t.node_count??0)}viewEdges(t){let e=t.edges;return Array.isArray(e)?e.length:Number(t.edge_count??0)}static ɵfac=function(e){return new(e||n)};static ɵcmp=sl({type:n,selectors:[[`page-graph`]],decls:11,vars:14,consts:[[3,`title`,`subtitle`],[1,`btn`,3,`click`],[`name`,`refresh`,3,`size`],[3,`error`],[`role`,`status`],[`data-section`,`federated`,1,`card`,`fed`],[3,`retry`,`error`],[`kind`,`card`,3,`lines`],[1,`card`],[`icon`,`graph`,3,`title`,`hint`],[`target`,`_blank`,`rel`,`noopener`,1,`btn`,`btn--primary`,3,`href`],[1,`views`],[`name`,`external`,3,`size`],[`name`,`graph`,3,`size`],[1,`muted`],[1,`fed__head`],[`name`,`network`,3,`size`],[1,`chip`],[1,`btn`,3,`click`,`disabled`],[`data-strip`,`sources`,1,`fed__sources`],[3,`query`,`placeholder`],[`data-section`,`inspector`,`aria-live`,`polite`,1,`card`,`fed__detail`],[`data-list`,`nodes`,1,`fed__nodes`],[`icon`,`network`,3,`title`],[3,`state`,`labelOverride`],[3,`queryChange`,`query`,`placeholder`],[`type`,`button`,1,`fg-pill`,3,`click`],[`type`,`button`,1,`fg-pill`],[1,`fed__detail-head`],[`state`,`unverified`],[1,`icon-btn`,3,`click`],[`name`,`chevron-right`,3,`size`],[1,`kv`],[1,`fed__evidence`],[1,`fed__impact`,`muted`],[1,`fed__edges`],[`type`,`button`,1,`chip-link`,3,`click`],[1,`fed__edge-ev`],[`type`,`button`,1,`fed__node`,3,`click`],[1,`fed__kind`],[1,`fed__label`],[1,`fed__id`]],template:function(e,r){if(e&1&&(ki(0,`ui-page-header`,0),kD(1,`t`),kD(2,`t`),ki(3,`button`,1),uh(`click`,function(){return r.load()}),ah(4,`ui-icon`,2),DD(5),kD(6,`t`),pl()(),jI(7,Oe,1,1,`ui-error`,3),jI(8,Me,3,4,`div`,4),jI(9,De,2,1),jI(10,Ye,24,21,`section`,5)),e&2){let d,_,k;sh(`title`,LD(1,8,`graph.title`))(`subtitle`,LD(2,10,`graph.subtitle`)),Vv(4),sh(`size`,15),Vv(),ml(` `,LD(6,12,`state.refresh`),` `),Vv(2),HI((d=r.error())?7:-1,d),Vv(),HI(r.loading()?8:-1),Vv(),HI((_=r.bundle())?9:-1,_),Vv(),HI((k=r.fed())?10:-1,k)}},dependencies:[_$1,I,_,w,Eg,h,h$1,yg],styles:[`.views[_ngcontent-%COMP%]{list-style:none;padding:0;margin:var(--%NS%space-4) 0 0;display:grid}.views[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;gap:var(--%NS%space-3);padding:var(--%NS%space-2) var(--%NS%space-3);border-radius:var(--%NS%radius-md)}.views[_ngcontent-%COMP%] li[_ngcontent-%COMP%] + li[_ngcontent-%COMP%]{border-top:1px solid var(--%NS%border)}.views[_ngcontent-%COMP%] li[_ngcontent-%COMP%]:hover{background:var(--%NS%bg-hover)}.views[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:var(--%NS%space-2)}.muted[_ngcontent-%COMP%]{color:var(--%NS%fg-muted);font-size:var(--%NS%font-sm)}.fed[_ngcontent-%COMP%]{margin-top:var(--%NS%space-3)}.fed__head[_ngcontent-%COMP%], .fed__detail-head[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;gap:var(--%NS%space-2);flex-wrap:wrap}.fed[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0;font-size:var(--%NS%font-lg);font-weight:650;display:inline-flex;align-items:center;gap:var(--%NS%space-2)}.views[_ngcontent-%COMP%] strong[_ngcontent-%COMP%] ui-icon[_ngcontent-%COMP%], .fed__head[_ngcontent-%COMP%] ui-icon[_ngcontent-%COMP%], .fed__detail-head[_ngcontent-%COMP%] ui-icon[_ngcontent-%COMP%]{color:var(--%NS%accent)}.chip[_ngcontent-%COMP%], .fed__kind[_ngcontent-%COMP%], .chip-link[_ngcontent-%COMP%]{font-size:var(--%NS%font-xs);font-weight:700;color:var(--%NS%accent);background:var(--%NS%accent-bg);border-radius:var(--%NS%radius-pill);padding:1px 8px;flex:none}.chip-link[_ngcontent-%COMP%]{border:0;cursor:pointer}.fed__sources[_ngcontent-%COMP%]{list-style:none;display:flex;flex-wrap:wrap;gap:var(--%NS%space-2) var(--%NS%space-3);padding:0;margin:var(--%NS%space-2) 0;font-size:var(--%NS%font-xs)}.fed__sources[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{display:inline-flex;gap:var(--%NS%space-2)}.fed__nodes[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(auto-fill,minmax(240px,1fr));gap:var(--%NS%space-2)}.fed__node[_ngcontent-%COMP%]{width:100%;display:flex;align-items:center;gap:var(--%NS%space-2);padding:var(--%NS%space-2);border:1px solid var(--%NS%border);border-radius:var(--%NS%radius-md);color:var(--%NS%fg);font:inherit;text-align:left;cursor:pointer}.fed__node[_ngcontent-%COMP%]:hover{border-color:var(--%NS%accent)}.fed__node[data-unverified][_ngcontent-%COMP%]{border-style:dashed;opacity:.72}.fed__node[data-selected][_ngcontent-%COMP%]{border-color:var(--%NS%accent);box-shadow:0 0 0 1px var(--%NS%accent)}.fed__node[data-neighbor][_ngcontent-%COMP%]{border-color:var(--%NS%info);box-shadow:0 0 0 1px var(--%NS%info)}.fed__label[_ngcontent-%COMP%], .fed__id[_ngcontent-%COMP%]{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}.fed__label[_ngcontent-%COMP%]{font-weight:600}.fed__id[_ngcontent-%COMP%]{margin-left:auto;color:var(--%NS%fg-muted);font-size:var(--%NS%font-xs)}.fed__detail[_ngcontent-%COMP%]{margin:var(--%NS%space-4) 0;border-left:3px solid var(--%NS%accent)}.kv[_ngcontent-%COMP%]{display:grid;gap:var(--%NS%space-2);margin:0}.kv[_ngcontent-%COMP%] div[_ngcontent-%COMP%]{display:flex;align-items:baseline;gap:var(--%NS%space-3)}.kv[_ngcontent-%COMP%] dt[_ngcontent-%COMP%]{min-width:7rem;color:var(--%NS%fg-muted);font-size:var(--%NS%font-sm);flex:none}.kv[_ngcontent-%COMP%] dd[_ngcontent-%COMP%]{margin:0}.fed__evidence[_ngcontent-%COMP%], .fed__edges[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;align-items:center;gap:var(--%NS%space-1) var(--%NS%space-2)}.fed__impact[_ngcontent-%COMP%]{margin:var(--%NS%space-2) 0;font-weight:650}.fed__edges[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0;display:grid;gap:var(--%NS%space-1);font-size:var(--%NS%font-sm)}.fed__edge-ev[_ngcontent-%COMP%]{color:var(--%NS%fg-muted);font-size:var(--%NS%font-xs)}`]})};export{ke as GraphPage};
@@ -0,0 +1 @@
1
+ import{$ as ah,At as sl,B as Te,Et as pl,G as XI,H as UI,It as yg,K as YI,Lt as yh,O as LD,P as Qu,Rt as zI,U as Vv,V as Tg,_t as jn,c as $i,d as CD,dt as hg,g as Eg,gt as jI,jt as uh,kt as sh,m as DD,mt as ih,q as Yu,r as g$1,s as $I,st as g,v as Gi,vt as kD,xt as ml,y as HI,yt as ki}from"./main-QDFVZK3T.js";import{t as w}from"./chunk-BVKnCv85.js";import{t as I}from"./chunk-DyIHOW_a.js";import{t as _}from"./chunk-C4gpbtbP.js";var E=(o,p)=>p.id;var q=(o,p)=>p.provider;function J(o,p){o&1&&(ki(0,`section`,3),ah(1,`div`,8)(2,`div`,9)(3,`div`,10),pl())}function K(o,p){if(o&1){let e=YI();ki(0,`label`,21)(1,`input`,31),uh(`change`,function(){let s=Yu(e).$implicit,_=XI(2);return Qu(_.scope.set(s.id))}),pl(),ki(2,`span`)(3,`strong`),DD(4),kD(5,`t`),pl(),ki(6,`small`),DD(7),kD(8,`t`),pl()()()}if(o&2){let e=p.$implicit,c=XI(2);$i(`data-active`,c.scope()===e.id||null),Vv(),sh(`value`,e.id)(`checked`,c.scope()===e.id),Vv(3),yh(LD(5,5,e.label)),Vv(3),yh(LD(8,7,e.hint))}}function L(o,p){if(o&1){let e=YI();ki(0,`label`,21)(1,`input`,32),uh(`change`,function(){let s=Yu(e).$implicit,_=XI(2);return Qu(_.host.set(s.id))}),pl(),ki(2,`span`)(3,`strong`),DD(4),kD(5,`t`),pl(),ki(6,`small`),DD(7),kD(8,`t`),pl()()()}if(o&2){let e=p.$implicit,c=XI(2);$i(`data-active`,c.host()===e.id||null),Vv(),sh(`value`,e.id)(`checked`,c.host()===e.id),Vv(3),yh(LD(5,5,e.label)),Vv(3),yh(LD(8,7,e.hint))}}function Q(o,p){if(o&1){let e=YI();ki(0,`label`,21)(1,`input`,33),uh(`change`,function(){let s=Yu(e).$implicit,_=XI(2);return Qu(_.profile.set(s.id))}),pl(),ki(2,`span`)(3,`strong`),DD(4),kD(5,`t`),pl(),ki(6,`small`),DD(7),kD(8,`t`),pl()()()}if(o&2){let e=p.$implicit,c=XI(2);$i(`data-active`,c.profile()===e.id||null),Vv(),sh(`value`,e.id)(`checked`,c.profile()===e.id),Vv(3),yh(LD(5,5,e.label)),Vv(3),yh(LD(8,7,e.hint))}}function W(o,p){if(o&1){let e=YI();ki(0,`label`,21)(1,`input`,34),uh(`change`,function(){let s=Yu(e).$implicit,_=XI(2);return Qu(_.gatewayProfile.set(s.id))}),pl(),ki(2,`span`)(3,`strong`),DD(4),kD(5,`t`),pl(),ki(6,`small`),DD(7),kD(8,`t`),pl()()()}if(o&2){let e=p.$implicit,c=XI(2);$i(`data-active`,c.gatewayProfile()===e.id||null),Vv(),sh(`value`,e.id)(`checked`,c.gatewayProfile()===e.id),Vv(3),yh(LD(5,5,e.label)),Vv(3),yh(LD(8,7,e.hint))}}function X(o,p){if(o&1){let e=YI();ki(0,`label`,23)(1,`input`,35),uh(`change`,function(){let s=Yu(e).$implicit,_=XI(2);return Qu(_.toggle(s.id))}),pl(),ki(2,`span`)(3,`strong`),DD(4),kD(5,`t`),pl(),ki(6,`small`),DD(7),kD(8,`t`),pl()()()}if(o&2){let e=p.$implicit,c=XI(2);$i(`data-active`,c.selected().has(e.id)||null),Vv(),sh(`checked`,c.selected().has(e.id)),Vv(3),yh(LD(5,4,e.label)),Vv(3),yh(LD(8,6,e.hint))}}function Y(o,p){if(o&1&&(ki(0,`small`),DD(1),pl()),o&2){let e=XI().$implicit;Vv(),yh(e.notes[0])}}function Z(o,p){if(o&1&&(ki(0,`li`,36)(1,`div`,37)(2,`span`,38),ah(3,`ui-icon`,39),pl(),ki(4,`div`)(5,`strong`),DD(6),pl(),ki(7,`small`),DD(8),kD(9,`t`),pl()()(),ah(10,`ui-state-badge`,40),ki(11,`div`,41)(12,`span`),DD(13),kD(14,`t`),kD(15,`t`),pl(),jI(16,Y,2,1,`small`),pl()()),o&2){let e=p.$implicit;Vv(3),sh(`size`,13),Vv(3),yh(e.provider),Vv(2),yh(e.cli||e.checkout||LD(9,7,`state.unknown`)),Vv(2),sh(`state`,e.state||e.status||`unknown`),Vv(2),$i(`data-present`,e.mcp?`true`:null),Vv(),yh(e.mcp?LD(14,9,`federation.mcpReady`):LD(15,11,`federation.mcpAbsent`)),Vv(3),HI(e.notes?.length?16:-1)}}function ee(o,p){if(o&1&&(ki(0,`ul`,28),$I(1,Z,17,13,`li`,36,q),pl()),o&2){let e=XI();Vv(),zI(e.specialists)}}function te(o,p){o&1&&(ki(0,`p`,29),DD(1),kD(2,`t`),pl()),o&2&&(Vv(),yh(LD(2,1,`federation.empty`)))}function ie(o,p){if(o&1){let e=YI();ki(0,`section`,11),kD(1,`t`),ki(2,`div`,12)(3,`span`,13),DD(4),pl(),ki(5,`span`,14),DD(6),kD(7,`t`),pl()(),ki(8,`div`,12)(9,`span`,13),DD(10),pl(),ki(11,`span`,14),DD(12),kD(13,`t`),pl()(),ki(14,`div`,12)(15,`span`,13),DD(16),pl(),ki(17,`span`,14),DD(18),kD(19,`t`),pl()(),ki(20,`div`,12)(21,`span`,13),DD(22),pl(),ki(23,`span`,14),DD(24),kD(25,`t`),pl()()(),ki(26,`div`,15)(27,`section`,16)(28,`div`,17)(29,`div`)(30,`h2`),DD(31),kD(32,`t`),pl(),ki(33,`p`,18),DD(34),kD(35,`t`),pl()(),ki(36,`span`,19),DD(37),kD(38,`t`),pl()(),ki(39,`h3`),DD(40),kD(41,`t`),pl(),ki(42,`div`,20),kD(43,`t`),$I(44,K,9,9,`label`,21,E),pl(),ki(46,`h3`),DD(47),kD(48,`t`),pl(),ki(49,`div`,20),kD(50,`t`),$I(51,L,9,9,`label`,21,E),pl(),ki(53,`h3`),DD(54),kD(55,`t`),pl(),ki(56,`div`,20),kD(57,`t`),$I(58,Q,9,9,`label`,21,E),pl(),ki(60,`h3`),DD(61),kD(62,`t`),pl(),ki(63,`div`,20),kD(64,`t`),$I(65,W,9,9,`label`,21,E),pl(),ki(67,`h3`),DD(68),kD(69,`t`),pl(),ki(70,`div`,22),$I(71,X,9,8,`label`,23,E),pl(),ki(73,`div`,24)(74,`button`,25),uh(`click`,function(){Yu(e);let s=XI();return Qu(s.plan())}),ah(75,`ui-icon`,26),DD(76),kD(77,`t`),pl(),ki(78,`span`,18),DD(79),kD(80,`t`),pl()()(),ki(81,`aside`,27)(82,`div`,17)(83,`div`)(84,`h2`),DD(85),kD(86,`t`),pl(),ki(87,`p`,18),DD(88),kD(89,`t`),pl()()(),jI(90,ee,3,0,`ul`,28)(91,te,3,3,`p`,29),ki(92,`p`,30),DD(93),pl()()()}if(o&2){let e=p,c=XI();ih(`aria-label`,CD(LD(1,38,`federation.summary`))),Vv(2),Gi(`--%NS%stat-rail`,`var(--accent)`),Vv(2),yh(e.summary.catalog),Vv(2),yh(LD(7,40,`federation.catalog`)),Vv(2),Gi(`--%NS%stat-rail`,`var(--ok)`),Vv(2),yh(e.summary.installed),Vv(2),yh(LD(13,42,`federation.installed`)),Vv(2),Gi(`--%NS%stat-rail`,`var(--info)`),Vv(2),yh(e.summary.with_mcp),Vv(2),yh(LD(19,44,`federation.mcp`)),Vv(2),Gi(`--%NS%stat-rail`,`var(--fg-muted)`),Vv(2),yh(e.summary.with_checkout),Vv(2),yh(LD(25,46,`federation.checkouts`)),Vv(7),yh(LD(32,48,`federation.setup.title`)),Vv(3),yh(LD(35,50,`federation.setup.hint`)),Vv(3),yh(LD(38,52,`federation.governed`)),Vv(3),yh(LD(41,54,`install.scope`)),Vv(2),$i(`aria-label`,LD(43,56,`install.scope`)),Vv(2),zI(c.scopes),Vv(3),yh(LD(48,58,`federation.host`)),Vv(2),$i(`aria-label`,LD(50,60,`federation.host`)),Vv(2),zI(c.hosts),Vv(3),yh(LD(55,62,`federation.profile`)),Vv(2),$i(`aria-label`,LD(57,64,`federation.profile`)),Vv(2),zI(c.profiles),Vv(3),yh(LD(62,66,`federation.executionProfile`)),Vv(2),$i(`aria-label`,LD(64,68,`federation.executionProfile`)),Vv(2),zI(c.gatewayProfiles),Vv(3),yh(LD(69,70,`federation.components`)),Vv(3),zI(c.componentOptions),Vv(3),sh(`disabled`,c.busy()),Vv(),sh(`size`,15),Vv(),ml(` `,LD(77,72,`federation.plan`),` `),Vv(3),yh(LD(80,74,`federation.planHint`)),Vv(6),yh(LD(86,76,`federation.specialists`)),Vv(3),yh(LD(89,78,`federation.specialistsHint`)),Vv(2),HI(e.specialists.length?90:91),Vv(3),yh(e.registry.path)}}function ne(o,p){if(o&1&&(ki(0,`li`)(1,`code`),DD(2),pl(),ki(3,`span`),DD(4),pl()()),o&2){let e=p.$implicit;Vv(2),yh(e.status),Vv(2),yh(e.path)}}function ae(o,p){if(o&1&&(ki(0,`ul`,43),$I(1,ne,5,2,`li`,null,UI),pl()),o&2){let e=XI();Vv(),zI(e.actions)}}function oe(o,p){if(o&1){let e=YI();ki(0,`section`,4)(1,`div`,17)(2,`div`)(3,`h2`),DD(4),kD(5,`t`),pl(),ki(6,`p`,18),DD(7),kD(8,`t`),pl()(),ah(9,`ui-state-badge`,40),pl(),ki(10,`dl`,42)(11,`div`)(12,`dt`),DD(13),kD(14,`t`),pl(),ki(15,`dd`),DD(16),pl()(),ki(17,`div`)(18,`dt`),DD(19),kD(20,`t`),pl(),ki(21,`dd`),DD(22),pl()(),ki(23,`div`)(24,`dt`),DD(25),kD(26,`t`),pl(),ki(27,`dd`),DD(28),pl()(),ki(29,`div`)(30,`dt`),DD(31),kD(32,`t`),pl(),ki(33,`dd`),DD(34),kD(35,`t`),pl()(),ki(36,`div`)(37,`dt`),DD(38),kD(39,`t`),pl(),ki(40,`dd`),DD(41),pl()()(),jI(42,ae,3,0,`ul`,43),ki(43,`div`,24)(44,`button`,25),uh(`click`,function(){let s=Yu(e),_=XI();return Qu(_.apply(s))}),ah(45,`ui-icon`,39),DD(46),kD(47,`t`),pl(),ki(48,`button`,1),uh(`click`,function(){Yu(e);let s=XI();return Qu(s.reset())}),DD(49),kD(50,`t`),pl()()()}if(o&2){let e=p,c=XI();Vv(4),yh(LD(5,19,`federation.review`)),Vv(3),yh(LD(8,21,`federation.reviewHint`)),Vv(2),sh(`state`,e.status),Vv(4),yh(LD(14,23,`install.scope`)),Vv(3),yh(e.plan.scope),Vv(3),yh(LD(20,25,`federation.host`)),Vv(3),yh(e.plan.host),Vv(3),yh(LD(26,27,`federation.profile`)),Vv(3),yh(e.plan.profile),Vv(3),yh(LD(32,29,`federation.executionProfile`)),Vv(3),yh(e.plan.gateway_profile||LD(35,31,`state.unknown`)),Vv(4),yh(LD(39,33,`federation.actions`)),Vv(3),yh(e.actions.length),Vv(),HI(e.actions.length?42:-1),Vv(2),sh(`disabled`,c.busy()),Vv(),sh(`size`,15),Vv(),ml(``,LD(47,35,`federation.apply`),` `),Vv(2),sh(`disabled`,c.busy()),Vv(),ml(` `,LD(50,37,`state.cancel`),` `)}}function re(o,p){o&1&&(ki(0,`section`,5),ah(1,`div`,44),DD(2),kD(3,`t`),pl()),o&2&&(Vv(2),ml(` `,LD(3,1,`federation.running`),` `))}function le(o,p){if(o&1&&(ki(0,`section`,6)(1,`h2`),DD(2),kD(3,`t`),pl(),ki(4,`p`),ah(5,`ui-state-badge`,40),ki(6,`span`),DD(7),kD(8,`t`),pl()()()),o&2){let e=p;Vv(2),yh(LD(3,3,`federation.receipt`)),Vv(3),sh(`state`,e.status),Vv(2),yh(e.detail||LD(8,5,`federation.receiptHint`))}}function de(o,p){if(o&1){let e=YI();ki(0,`ui-error`,45),uh(`retry`,function(){Yu(e);let s=XI();return Qu(s.load())}),pl()}if(o&2){let e=XI();sh(`error`,e.error())}}var U=class o{api=g(hg);store=g(g$1);snapshot=Te(null);planResult=Te(null);result=Te(null);error=Te(null);phase=Te(`loading`);busy=Te(!0);scope=Te(`project`);host=Te(`all`);profile=Te(`recommended`);gatewayProfile=Te(`balanced`);selected=Te(new Set([`skills`,`agents`,`mcp`,`tui`,`graph-studio`]));scopes=[{id:`project`,label:`install.scope.project`,hint:`install.scope.project.hint`},{id:`workspace`,label:`install.scope.workspace`,hint:`install.scope.workspace.hint`},{id:`user`,label:`install.scope.user`,hint:`install.scope.user.hint`}];hosts=[{id:`all`,label:`federation.host.all`,hint:`federation.host.allHint`},{id:`none`,label:`federation.host.none`,hint:`federation.host.noneHint`},{id:`claude`,label:`federation.host.claude`,hint:`federation.host.detected`},{id:`devin`,label:`federation.host.devin`,hint:`federation.host.detected`},{id:`codex`,label:`federation.host.codex`,hint:`federation.host.detected`},{id:`copilot`,label:`federation.host.copilot`,hint:`federation.host.detected`}];profiles=[{id:`minimal`,label:`federation.profile.minimal`,hint:`federation.profile.minimalHint`},{id:`recommended`,label:`federation.profile.recommended`,hint:`federation.profile.recommendedHint`},{id:`full`,label:`federation.profile.full`,hint:`federation.profile.fullHint`}];gatewayProfiles=[{id:`economy`,label:`federation.execution.economy`,hint:`federation.execution.economyHint`},{id:`balanced`,label:`federation.execution.balanced`,hint:`federation.execution.balancedHint`},{id:`deep`,label:`federation.execution.deep`,hint:`federation.execution.deepHint`}];componentOptions=[{id:`skills`,label:`federation.component.skills`,hint:`federation.component.skillsHint`},{id:`agents`,label:`federation.component.agents`,hint:`federation.component.agentsHint`},{id:`mcp`,label:`federation.component.mcp`,hint:`federation.component.mcpHint`},{id:`tui`,label:`federation.component.tui`,hint:`federation.component.tuiHint`},{id:`graph-studio`,label:`federation.component.graph`,hint:`federation.component.graphHint`}];constructor(){this.load()}async load(){this.phase.set(`loading`),this.busy.set(!0),this.error.set(null);try{this.snapshot.set(await Tg(this.api.federation())),this.phase.set(`idle`)}catch(p){this.fail(p)}finally{this.busy.set(!1)}}toggle(p){let e=new Set(this.selected());e.has(p)?e.delete(p):e.add(p),this.selected.set(e)}async plan(){this.phase.set(`planning`),this.busy.set(!0),this.error.set(null);try{let p={scope:this.scope(),host:this.host(),profile:this.profile(),gateway_profile:this.gatewayProfile(),components:Object.fromEntries([...this.selected()].map(e=>[e,!0]))};this.planResult.set(await Tg(this.api.federationPlan(p))),this.phase.set(`review`)}catch(p){this.fail(p)}finally{this.busy.set(!1)}}async apply(p){this.phase.set(`running`),this.busy.set(!0),this.error.set(null);try{this.result.set(await Tg(this.api.federationInstallAuto(p.plan,p.plan_token))),await Promise.all([this.load(),this.store.refreshHealth()]),this.phase.set(`done`)}catch(e){this.fail(e)}finally{this.busy.set(!1)}}reset(){this.phase.set(`idle`),this.planResult.set(null),this.result.set(null),this.error.set(null)}fail(p){this.error.set(p instanceof jn?p:new jn(0)),this.phase.set(`error`)}static ɵfac=function(e){return new(e||o)};static ɵcmp=sl({type:o,selectors:[[`page-federation`]],decls:13,vars:16,consts:[[3,`title`,`subtitle`],[1,`btn`,3,`click`,`disabled`],[`name`,`refresh`,3,`size`],[`role`,`status`,`aria-live`,`polite`,1,`card`,`loading`],[`data-lift`,``,1,`card`,`plan`],[`role`,`status`,`aria-live`,`polite`,1,`card`,`running`],[`data-lift`,``,1,`card`,`receipt`],[3,`error`],[1,`skeleton`,`skeleton--line`,2,`width`,`42%`],[1,`skeleton`,`skeleton--line`,2,`width`,`78%`],[1,`skeleton`,`skeleton--block`],[1,`stats`,3,`aria-label`],[1,`stat`],[1,`stat__value`],[1,`stat__label`],[1,`layout`],[1,`card`,`setup-card`],[1,`card__heading`],[1,`muted`],[1,`eyebrow`],[`role`,`radiogroup`,1,`choices`],[1,`choice`],[1,`component-grid`],[1,`component`],[1,`actions-row`],[1,`btn`,`btn--primary`,3,`click`,`disabled`],[`name`,`install`,3,`size`],[1,`card`,`specialist-card`],[1,`specialists`],[1,`empty`],[1,`registry`,`mono`],[`type`,`radio`,`name`,`federation-scope`,3,`change`,`value`,`checked`],[`type`,`radio`,`name`,`federation-host`,3,`change`,`value`,`checked`],[`type`,`radio`,`name`,`federation-profile`,3,`change`,`value`,`checked`],[`type`,`radio`,`name`,`federation-execution-profile`,3,`change`,`value`,`checked`],[`type`,`checkbox`,3,`change`,`checked`],[1,`specialist`],[1,`specialist__main`],[`aria-hidden`,`true`,1,`specialist__mark`],[`name`,`check`,3,`size`],[3,`state`],[1,`specialist__meta`],[1,`review-grid`],[1,`actions`],[`aria-hidden`,`true`,1,`running__spinner`],[3,`retry`,`error`]],template:function(e,c){if(e&1&&(ki(0,`ui-page-header`,0),kD(1,`t`),kD(2,`t`),ki(3,`button`,1),uh(`click`,function(){return c.load()}),ah(4,`ui-icon`,2),DD(5),kD(6,`t`),pl()(),jI(7,J,4,0,`section`,3)(8,ie,94,80),jI(9,oe,51,39,`section`,4),jI(10,re,4,3,`section`,5),jI(11,le,9,7,`section`,6),jI(12,de,1,1,`ui-error`,7)),e&2){let s,_,F;sh(`title`,LD(1,10,`federation.title`))(`subtitle`,LD(2,12,`federation.subtitle`)),Vv(3),sh(`disabled`,c.busy()),Vv(),sh(`size`,15),Vv(),ml(` `,LD(6,14,`state.refresh`),` `),Vv(2),HI(c.phase()===`loading`&&!c.snapshot()?7:(s=c.snapshot())?8:-1,s),Vv(2),HI((_=c.phase()===`review`&&c.planResult())?9:-1,_),Vv(),HI(c.phase()===`running`?10:-1),Vv(),HI((F=c.phase()===`done`&&c.result())?11:-1,F),Vv(),HI(c.phase()===`error`?12:-1)}},dependencies:[_,I,w,Eg,yg],styles:[`.stats[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));gap:var(--%NS%space-4);margin-bottom:var(--%NS%space-5)}.layout[_ngcontent-%COMP%]{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(300px,.75fr);gap:var(--%NS%space-4);align-items:start}.card[_ngcontent-%COMP%]{margin-bottom:var(--%NS%space-4)}.card__heading[_ngcontent-%COMP%]{display:flex;justify-content:space-between;gap:var(--%NS%space-4);align-items:flex-start}.card[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0 0 var(--%NS%space-2);font-size:var(--%NS%font-lg);font-weight:650}.card[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]{margin:var(--%NS%space-5) 0 var(--%NS%space-2);font-size:var(--%NS%font-sm);color:var(--%NS%fg-muted);text-transform:uppercase;letter-spacing:.06em}.card[_ngcontent-%COMP%] h3[_ngcontent-%COMP%]:first-of-type{margin-top:var(--%NS%space-4)}.muted[_ngcontent-%COMP%]{color:var(--%NS%fg-muted)}.eyebrow[_ngcontent-%COMP%]{color:var(--%NS%accent-strong);background:var(--%NS%accent-bg);border-radius:var(--%NS%radius-pill);padding:4px 9px;font-size:var(--%NS%font-xs);font-weight:700;white-space:nowrap}.choices[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));gap:var(--%NS%space-2)}.choice[_ngcontent-%COMP%], .component[_ngcontent-%COMP%]{display:flex;gap:var(--%NS%space-2);align-items:flex-start;padding:var(--%NS%space-3);border:1px solid var(--%NS%border);border-radius:var(--%NS%radius-md);cursor:pointer;transition:border-color var(--%NS%motion-fast),background var(--%NS%motion-fast)}.choice[_ngcontent-%COMP%]:hover, .component[_ngcontent-%COMP%]:hover, .choice[data-active][_ngcontent-%COMP%], .component[data-active][_ngcontent-%COMP%]{border-color:var(--%NS%accent);background:var(--%NS%accent-bg)}.choice[_ngcontent-%COMP%] input[_ngcontent-%COMP%], .component[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{margin-top:3px;accent-color:var(--%NS%accent);flex:none}.choice[_ngcontent-%COMP%] span[_ngcontent-%COMP%], .component[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{display:grid;gap:3px}.choice[_ngcontent-%COMP%] small[_ngcontent-%COMP%], .component[_ngcontent-%COMP%] small[_ngcontent-%COMP%]{color:var(--%NS%fg-muted);line-height:1.35}.component-grid[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(auto-fit,minmax(210px,1fr));gap:var(--%NS%space-2)}.actions-row[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:var(--%NS%space-3);align-items:center;margin-top:var(--%NS%space-5)}.specialists[_ngcontent-%COMP%]{list-style:none;padding:0;margin:var(--%NS%space-4) 0;display:grid;gap:var(--%NS%space-2)}.specialist[_ngcontent-%COMP%]{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:5px var(--%NS%space-2);padding:var(--%NS%space-3);border:1px solid var(--%NS%border);border-radius:var(--%NS%radius-md)}.specialist__main[_ngcontent-%COMP%]{display:flex;gap:var(--%NS%space-2);align-items:center;min-width:0}.specialist__main[_ngcontent-%COMP%] div[_ngcontent-%COMP%]{display:grid;min-width:0}.specialist__main[_ngcontent-%COMP%] small[_ngcontent-%COMP%]{color:var(--%NS%fg-muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.specialist__mark[_ngcontent-%COMP%]{display:grid;place-items:center;width:24px;height:24px;border-radius:50%;color:var(--%NS%ok);background:var(--%NS%ok-bg);flex:none}.specialist__meta[_ngcontent-%COMP%]{grid-column:1/-1;display:flex;gap:var(--%NS%space-2);flex-wrap:wrap;color:var(--%NS%fg-muted);font-size:var(--%NS%font-xs)}.specialist__meta[_ngcontent-%COMP%] [data-present][_ngcontent-%COMP%]{color:var(--%NS%ok)}.specialist__meta[_ngcontent-%COMP%] small[_ngcontent-%COMP%]{width:100%;overflow-wrap:anywhere}.registry[_ngcontent-%COMP%]{border-top:1px solid var(--%NS%border);padding-top:var(--%NS%space-3);color:var(--%NS%fg-muted);overflow-wrap:anywhere;font-size:var(--%NS%font-xs)}.review-grid[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:var(--%NS%space-3);margin:var(--%NS%space-4) 0}.review-grid[_ngcontent-%COMP%] div[_ngcontent-%COMP%]{display:grid;gap:4px;padding:var(--%NS%space-3);background:var(--%NS%bg-sunken);border-radius:var(--%NS%radius-md)}.review-grid[_ngcontent-%COMP%] dt[_ngcontent-%COMP%]{color:var(--%NS%fg-muted);font-size:var(--%NS%font-xs)}.review-grid[_ngcontent-%COMP%] dd[_ngcontent-%COMP%]{margin:0;font-weight:650;overflow-wrap:anywhere}.actions[_ngcontent-%COMP%]{display:grid;gap:6px;list-style:none;padding:0;max-height:240px;overflow:auto}.actions[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{display:flex;gap:var(--%NS%space-2);padding:7px 0;border-bottom:1px solid var(--%NS%border);overflow-wrap:anywhere}.actions[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{color:var(--%NS%accent-strong);flex:none}.running[_ngcontent-%COMP%], .loading[_ngcontent-%COMP%]{display:grid;gap:var(--%NS%space-3)}.running[_ngcontent-%COMP%]{place-items:center;min-height:100px}.receipt[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--%NS%space-2)}.empty[_ngcontent-%COMP%]{color:var(--%NS%fg-muted);padding:var(--%NS%space-5) 0}@media(max-width:820px){.layout[_ngcontent-%COMP%]{grid-template-columns:1fr}}@media(max-width:520px){.choices[_ngcontent-%COMP%], .component-grid[_ngcontent-%COMP%]{grid-template-columns:1fr}.card__heading[_ngcontent-%COMP%]{display:block}.eyebrow[_ngcontent-%COMP%]{display:inline-block;margin-top:var(--%NS%space-3)}}@media(prefers-reduced-motion:reduce){.choice[_ngcontent-%COMP%], .component[_ngcontent-%COMP%]{transition:none}}`]})};export{U as FederationPage};
@@ -0,0 +1 @@
1
+ import{$ as ah,At as sl,B as Te,Bt as zr,Et as pl,F as RD,G as XI,I as SD,It as yg,K as YI,Lt as yh,Nt as vh,O as LD,P as Qu,Rt as zI,U as Vv,V as Tg,Y as Zi,_t as jn,c as $i,dt as hg,g as Eg,gt as jI,h as Dh,jt as uh,kt as sh,l as AD,m as DD,q as Yu,r as g$1,s as $I,st as g,t as Nt,u as BI,vt as kD,w as Ih,xt as ml,y as HI,yt as ki}from"./main-QDFVZK3T.js";import{t as h}from"./chunk-DqWNkF1O.js";import{t as _}from"./chunk-BaQMhq-G.js";import{t as w}from"./chunk-BVKnCv85.js";import{t as I}from"./chunk-DyIHOW_a.js";import{t as _$1}from"./chunk-C4gpbtbP.js";import{t as h$1}from"./chunk-CJCT86Dr.js";var Z=()=>[`/skills`];var ee=t=>({q:t});var te=(t,o)=>o.id;function ie(t,o){if(t&1){let e=YI();ki(0,`ui-error`,6),uh(`retry`,function(){Yu(e);let p=XI();return Qu(p.load())}),pl()}t&2&&sh(`error`,o)}function ne(t,o){t&1&&(ki(0,`section`,4),kD(1,`t`),ah(2,`ui-skeleton`,7),pl()),t&2&&($i(`aria-label`,LD(1,2,`state.loading`)),Vv(2),sh(`lines`,3))}function ae(t,o){if(t&1){let e=YI();ki(0,`button`,9),uh(`click`,function(){let p=Yu(e).$implicit,v=XI(2);return Qu(v.toggleDomain(p))}),DD(1),pl()}if(t&2){let e=o.$implicit,r=XI(2);$i(`data-tone`,r.domain()===e?`accent`:null)(`aria-pressed`,r.domain()===e),Vv(),ml(` `,e,` `)}}function oe(t,o){if(t&1&&(ki(0,`option`,17),DD(1),pl()),t&2){let e=o.$implicit,r=XI(3);sh(`value`,e)(`selected`,r.skill()===e),Vv(),yh(e)}}function re(t,o){if(t&1){let e=YI();ki(0,`select`,15),kD(1,`t`),uh(`change`,function(p){Yu(e);let v=XI(2);return Qu(v.onSkill(p))}),ki(2,`option`,16),DD(3),kD(4,`t`),kD(5,`t`),pl(),$I(6,oe,2,3,`option`,17,BI),pl()}if(t&2){let e=XI(2);sh(`value`,e.skill()??``),$i(`aria-label`,LD(1,4,`agents.skills`)),Vv(3),vh(``,LD(4,6,`agents.skills`),`: `,LD(5,8,`state.all`)),Vv(3),zI(e.skillOptions())}}function le(t,o){if(t&1&&(ki(0,`a`,28),DD(1),pl()),t&2){let e=o.$implicit;sh(`routerLink`,RD(3,Z))(`queryParams`,AD(4,ee,e)),Vv(),yh(e)}}function de(t,o){if(t&1&&(ki(0,`span`,23),$I(1,le,2,6,`a`,28,BI),pl()),t&2){let e=XI();Vv(),zI(e.skills)}}function se(t,o){t&1&&(DD(0),kD(1,`t`)),t&2&&ml(` `,LD(1,1,`state.none`),` `)}function pe(t,o){if(t&1&&(DD(0),ki(1,`code`),DD(2),pl(),ki(3,`span`,29),DD(4),kD(5,`t`),pl()),t&2){let e=o;ml(` `,e.forge_name,` `),Vv(2),ml(`(`,e.forge_id,`)`),Vv(2),yh(LD(5,3,`explorer.serving`))}}function ce(t,o){t&1&&ah(0,`ui-state-badge`,24)}function me(t,o){if(t&1&&DD(0),t&2){let e=XI();ml(` `,e.hosts.join(`, `),` `)}}function ge(t,o){t&1&&ah(0,`ui-state-badge`,24)}function _e(t,o){if(t&1){let e=YI();ki(0,`section`,12)(1,`header`,18)(2,`h2`),ah(3,`ui-icon`,19),DD(4),pl(),ki(5,`button`,20),kD(6,`t`),uh(`click`,function(){Yu(e);let p=XI(2);return Qu(p.selected.set(null))}),ah(7,`ui-icon`,21),pl()(),ki(8,`dl`,22)(9,`div`)(10,`dt`),DD(11),kD(12,`t`),pl(),ki(13,`dd`)(14,`code`),DD(15),pl()()(),ki(16,`div`)(17,`dt`),DD(18),kD(19,`t`),pl(),ki(20,`dd`),DD(21),kD(22,`t`),pl()(),ki(23,`div`)(24,`dt`),DD(25),kD(26,`t`),pl(),ki(27,`dd`),DD(28),kD(29,`t`),pl()(),ki(30,`div`)(31,`dt`),DD(32),kD(33,`t`),pl(),ki(34,`dd`),DD(35),kD(36,`t`),pl()(),ki(37,`div`)(38,`dt`),DD(39),kD(40,`t`),pl(),ki(41,`dd`),DD(42),kD(43,`t`),pl()(),ki(44,`div`)(45,`dt`),DD(46),kD(47,`t`),pl(),ki(48,`dd`),jI(49,de,3,0,`span`,23)(50,se,2,3),pl()(),ki(51,`div`)(52,`dt`),DD(53),kD(54,`t`),pl(),ki(55,`dd`),jI(56,pe,6,5)(57,ce,1,0,`ui-state-badge`,24),pl()(),ki(58,`div`)(59,`dt`),DD(60),kD(61,`t`),pl(),ki(62,`dd`),jI(63,me,1,1)(64,ge,1,0,`ui-state-badge`,24),pl()(),ki(65,`div`)(66,`dt`),DD(67),kD(68,`t`),pl(),ki(69,`dd`),ah(70,`ui-state-badge`,25),pl()(),ki(71,`div`)(72,`dt`),DD(73),kD(74,`t`),pl(),ki(75,`dd`,26),ah(76,`ui-state-badge`,24),ki(77,`small`,27),DD(78),kD(79,`t`),pl()()(),ki(80,`div`)(81,`dt`),DD(82),kD(83,`t`),pl(),ki(84,`dd`,26),ah(85,`ui-state-badge`,24),ki(86,`small`,27),DD(87),kD(88,`t`),pl()()(),ki(89,`div`)(90,`dt`),DD(91),kD(92,`t`),pl(),ki(93,`dd`,26),ah(94,`ui-state-badge`,24),ki(95,`small`,27),DD(96),kD(97,`t`),pl()()(),ki(98,`div`)(99,`dt`),DD(100),kD(101,`t`),pl(),ki(102,`dd`,26),ah(103,`ui-state-badge`,24),ki(104,`small`,27),DD(105),kD(106,`t`),pl()()(),ki(107,`div`)(108,`dt`),DD(109),kD(110,`t`),pl(),ki(111,`dd`)(112,`code`),DD(113,`GET /api/v1/agents`),pl()()()()()}if(t&2){let e,r=o,p=XI(2);Vv(3),sh(`size`,15),Vv(),yh(r.name||r.id),Vv(),$i(`aria-label`,LD(6,32,`state.close`)),Vv(2),sh(`size`,14),Vv(4),yh(LD(12,34,`table.id`)),Vv(4),yh(r.id),Vv(3),yh(LD(19,36,`agents.role`)),Vv(3),yh(r.role||LD(22,38,`state.absent`)),Vv(4),yh(LD(26,40,`agents.responsibility`)),Vv(3),yh(r.description||LD(29,42,`state.absent`)),Vv(4),yh(LD(33,44,`agents.authority`)),Vv(3),yh(r.authority??LD(36,46,`state.absent`)),Vv(4),yh(LD(40,48,`agents.domains`)),Vv(3),yh(r.domains.length?r.domains.join(`, `):LD(43,50,`state.none`)),Vv(4),yh(LD(47,52,`agents.skills`)),Vv(3),HI(r.skills.length?49:50),Vv(4),yh(LD(54,54,`agents.origin`)),Vv(3),HI((e=p.store.descriptor())?56:57,e),Vv(4),yh(LD(61,56,`agents.compatibleHosts`)),Vv(3),HI(r.hosts.length?63:64),Vv(4),yh(LD(68,58,`skills.state`)),Vv(3),sh(`state`,r.state===`available`?`supported`:`unverified`)(`labelOverride`,r.state),Vv(3),yh(LD(74,60,`agents.tools`)),Vv(5),yh(LD(79,62,`agents.notExposed`)),Vv(4),yh(LD(83,64,`agents.permissions`)),Vv(5),yh(LD(88,66,`agents.notExposed`)),Vv(4),yh(LD(92,68,`agents.deps`)),Vv(5),yh(LD(97,70,`agents.notExposed`)),Vv(4),yh(LD(101,72,`settings.version`)),Vv(5),yh(LD(106,74,`agents.notExposed`)),Vv(4),yh(LD(110,76,`agents.evidence`))}}function ue(t,o){if(t&1&&(ki(0,`p`,32)(1,`span`),DD(2),kD(3,`t`),pl(),DD(4),pl()),t&2){let e=XI().$implicit;Vv(2),ml(``,LD(3,2,`agents.domains`),`:`),Vv(2),ml(` `,e.domains.join(`, `),` `)}}function xe(t,o){if(t&1&&(ki(0,`p`,32)(1,`span`),DD(2),kD(3,`t`),pl(),DD(4),pl()),t&2){let e=XI().$implicit;Vv(2),ml(``,LD(3,2,`agents.skills`),`:`),Vv(2),ml(` `,e.skills.join(`, `),` `)}}function ye(t,o){if(t&1){let e=YI();ki(0,`article`,14)(1,`header`,30)(2,`h2`),ah(3,`ui-icon`,19),DD(4),pl(),ah(5,`ui-state-badge`,25),pl(),ki(6,`p`,31),DD(7),pl(),ki(8,`p`,27),DD(9),pl(),jI(10,ue,5,4,`p`,32),jI(11,xe,5,4,`p`,32),ki(12,`div`,33)(13,`button`,34),uh(`click`,function(){let p=Yu(e).$implicit,v=XI(2);return Qu(v.selected.set(p))}),DD(14),kD(15,`t`),ah(16,`ui-icon`,21),pl()()()}if(t&2){let e=o.$implicit;Vv(3),sh(`size`,15),Vv(),yh(e.name||e.id),Vv(),sh(`state`,e.state===`available`?`supported`:`unverified`)(`labelOverride`,e.state),Vv(2),yh(e.role),Vv(2),yh(e.description),Vv(),HI(e.domains.length?10:-1),Vv(),HI(e.skills.length?11:-1),Vv(3),ml(` `,LD(15,10,`agents.detail`),` `),Vv(2),sh(`size`,13)}}function ve(t,o){t&1&&(ah(0,`ui-empty`,5),kD(1,`t`)),t&2&&sh(`title`,LD(1,1,`agents.empty`))}function fe(t,o){if(t&1&&jI(0,ve,2,3,`ui-empty`,5),t&2){let e=XI(2);HI(e.loading()?-1:0)}}function Ce(t,o){if(t&1){let e=YI();ki(0,`ui-filter-bar`,8),Dh(`queryChange`,function(p){Yu(e);let v=XI();return SD(v.query,p)||(v.query=p),Qu(p)}),ki(1,`button`,9),uh(`click`,function(){Yu(e);let p=XI();return Qu(p.domain.set(null))}),DD(2),kD(3,`t`),pl(),$I(4,ae,2,3,`button`,10,BI),jI(6,re,8,10,`select`,11),pl(),jI(7,_e,114,78,`section`,12),ki(8,`section`,13),$I(9,ye,17,12,`article`,14,te,!1,fe,1,1),pl()}if(t&2){let e,r=XI();Ih(`query`,r.query),Vv(),$i(`data-tone`,r.domain()===null?`accent`:null)(`aria-pressed`,r.domain()===null),Vv(),ml(` `,LD(3,7,`state.all`),` `),Vv(2),zI(r.domainOptions()),Vv(2),HI(r.skillOptions().length?6:-1),Vv(),HI((e=r.selected())?7:-1,e),Vv(2),zI(r.filtered())}}function be(t,o){t&1&&(ah(0,`ui-empty`,5),kD(1,`t`)),t&2&&sh(`title`,LD(1,1,`agents.none`))}var X=t=>t.normalize(`NFD`).replace(new RegExp(`\\p{Diacritic}`,`gu`),``).toLowerCase().trim();var Y=class t{api=g(hg);store=g(g$1);q=Zi(``);agents=Te([]);error=Te(null);query=Te(``);domain=Te(null);skill=Te(null);selected=Te(null);loading=Te(!0);domainOptions=zr(()=>{let o=new Set;for(let e of this.agents())for(let r of e.domains)o.add(r);return[...o].sort()});skillOptions=zr(()=>{let o=new Set;for(let e of this.agents())for(let r of e.skills)o.add(r);return[...o].sort()});filtered=zr(()=>{let o=X(this.query()),e=this.domain(),r=this.skill();return this.agents().filter(p=>e!==null&&!p.domains.includes(e)||r!==null&&!p.skills.includes(r)?!1:o?[p.id,p.name,p.role,p.description,...p.domains,...p.skills,...p.hosts].map(X).join(` `).includes(o):!0)});constructor(){this.load()}ngOnInit(){let o=this.q();o&&this.query.set(o)}async load(){this.error.set(null),this.loading.set(!0);try{this.agents.set(await Tg(this.api.agents()))}catch(o){this.error.set(o instanceof jn?o:new jn(0))}finally{this.loading.set(!1)}}toggleDomain(o){this.domain.set(this.domain()===o?null:o)}onSkill(o){let e=o.target.value;this.skill.set(e||null)}static ɵfac=function(e){return new(e||t)};static ɵcmp=sl({type:t,selectors:[[`page-agents`]],inputs:{q:[1,`q`]},decls:11,vars:13,consts:[[3,`title`,`subtitle`],[1,`btn`,3,`click`],[`name`,`refresh`,3,`size`],[3,`error`],[`role`,`status`,1,`grid`],[`icon`,`agents`,3,`title`],[3,`retry`,`error`],[`kind`,`card`,3,`lines`],[`placeholder`,`agents.search`,3,`queryChange`,`query`],[`type`,`button`,1,`fg-pill`,3,`click`],[`type`,`button`,1,`fg-pill`],[1,`input`,`sel`,3,`value`],[`data-section`,`agent-detail`,`aria-live`,`polite`,1,`card`,`detail`],[1,`grid`],[`data-lift`,``,1,`card`],[1,`input`,`sel`,3,`change`,`value`],[`value`,``],[3,`value`,`selected`],[1,`detail__head`],[`name`,`agents`,3,`size`],[1,`icon-btn`,3,`click`],[`name`,`chevron-right`,3,`size`],[1,`kv`],[1,`links`],[`state`,`UNVERIFIED`],[3,`state`,`labelOverride`],[1,`unv-cell`],[1,`muted`],[1,`chip-link`,3,`routerLink`,`queryParams`],[1,`chip`],[1,`head`],[1,`role`],[1,`tags`],[1,`row`],[1,`btn`,`btn--mini`,3,`click`]],template:function(e,r){if(e&1&&(ki(0,`ui-page-header`,0),kD(1,`t`),kD(2,`t`),ki(3,`button`,1),uh(`click`,function(){return r.load()}),ah(4,`ui-icon`,2),DD(5),kD(6,`t`),pl()(),jI(7,ie,1,1,`ui-error`,3),jI(8,ne,3,4,`section`,4),jI(9,Ce,12,9)(10,be,2,3,`ui-empty`,5)),e&2){let p;sh(`title`,LD(1,7,`agents.title`))(`subtitle`,LD(2,9,`agents.subtitle`)),Vv(4),sh(`size`,15),Vv(),ml(` `,LD(6,11,`state.refresh`),` `),Vv(2),HI((p=r.error())?7:-1,p),Vv(),HI(r.loading()?8:-1),Vv(),HI(r.agents().length?9:!r.error()&&!r.loading()?10:-1)}},dependencies:[Nt,_$1,I,_,w,Eg,h,h$1,yg],styles:[`.grid[_ngcontent-%COMP%]{display:grid;gap:var(--%NS%space-4);grid-template-columns:repeat(auto-fill,minmax(300px,1fr))}.head[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;gap:var(--%NS%space-2)}h2[_ngcontent-%COMP%]{margin:0;font-size:var(--%NS%font-lg);font-weight:650;letter-spacing:-.01em;display:inline-flex;align-items:center;gap:var(--%NS%space-2)}h2[_ngcontent-%COMP%] ui-icon[_ngcontent-%COMP%]{color:var(--%NS%accent)}.role[_ngcontent-%COMP%]{color:var(--%NS%accent);font-size:var(--%NS%font-sm);margin:4px 0}.muted[_ngcontent-%COMP%]{color:var(--%NS%fg-muted);margin:0}.tags[_ngcontent-%COMP%]{font-size:var(--%NS%font-xs);color:var(--%NS%fg-muted);margin:4px 0 0}.tags[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-weight:600}.sel[_ngcontent-%COMP%]{width:auto;min-width:12rem;padding-block:2px;font-size:var(--%NS%font-xs)}.row[_ngcontent-%COMP%]{margin-top:var(--%NS%space-3);display:flex;justify-content:flex-end}.btn--mini[_ngcontent-%COMP%]{padding:2px var(--%NS%space-2);font-size:var(--%NS%font-xs);gap:4px}.detail[_ngcontent-%COMP%]{margin-bottom:var(--%NS%space-4);border-left:3px solid var(--%NS%accent)}.detail__head[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;gap:var(--%NS%space-2);margin-bottom:var(--%NS%space-3)}.kv[_ngcontent-%COMP%]{display:grid;gap:var(--%NS%space-2);margin:0}.kv[_ngcontent-%COMP%] div[_ngcontent-%COMP%]{display:flex;align-items:baseline;gap:var(--%NS%space-3)}.kv[_ngcontent-%COMP%] dt[_ngcontent-%COMP%]{min-width:9rem;color:var(--%NS%fg-muted);font-size:var(--%NS%font-sm);flex:none}.kv[_ngcontent-%COMP%] dd[_ngcontent-%COMP%]{margin:0;min-width:0}.unv-cell[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--%NS%space-2)}.links[_ngcontent-%COMP%]{display:inline-flex;flex-wrap:wrap;gap:4px}.chip-link[_ngcontent-%COMP%]{font-size:var(--%NS%font-xs);font-weight:600;color:var(--%NS%accent);background:var(--%NS%accent-bg);border-radius:var(--%NS%radius-pill);padding:1px 8px;text-decoration:none}.chip-link[_ngcontent-%COMP%]:hover{text-decoration:underline}.chip[_ngcontent-%COMP%]{font-size:var(--%NS%font-xs);font-weight:700;color:var(--%NS%accent);background:var(--%NS%accent-bg);border-radius:var(--%NS%radius-pill);padding:1px 8px;margin-left:4px}`]})};export{Y as AgentsPage};
@@ -0,0 +1 @@
1
+ import{$ as ah,At as sl,B as Te,Bt as zr,Et as pl,G as XI,I as SD,It as yg,K as YI,Lt as yh,O as LD,P as Qu,Rt as zI,U as Vv,V as Tg,Y as Zi,_t as jn,c as $i,dt as hg,g as Eg,gt as jI,h as Dh,jt as uh,kt as sh,m as DD,q as Yu,r as g$1,s as $I,st as g,u as BI,vt as kD,w as Ih,xt as ml,y as HI,yt as ki}from"./main-QDFVZK3T.js";import{t as h}from"./chunk-DqWNkF1O.js";import{t as _}from"./chunk-BaQMhq-G.js";import{t as w$1}from"./chunk-BVKnCv85.js";import{t as I}from"./chunk-DyIHOW_a.js";import{t as _$1}from"./chunk-C4gpbtbP.js";import{t as h$1}from"./chunk-CJCT86Dr.js";function w(e){return e.normalize(`NFD`).replace(new RegExp(`\\p{Diacritic}`,`gu`),``).toLowerCase().replace(/[^a-z0-9]+/g,` `).trim()}function te(e){let i=new Set;if(!e)return i;for(let t of w(e).split(/[^a-z0-9]+/))t&&i.add(t);return i}function ne(e,i){if(e.size===0||i.size===0)return null;let t=0;for(let p of e)i.has(p)&&t++;let a=e.size+i.size-t;return a===0?null:t/a}function ae(e){return{entry:e,key:w(e.name||e.id),origin:e.origin?w(e.origin):null,version:e.version?w(e.version):null,desc:te(e.description)}}function re(e,i,t){let a=[],p=ne(e.desc,i.desc),m=e.origin!==null&&i.origin!==null&&e.origin===i.origin,f=e.origin!==null&&i.origin!==null&&e.origin!==i.origin,C=e.version!==null&&i.version!==null&&e.version!==i.version,y=p!==null&&p>=t,E;return m&&!C||y?(E=`possible-duplicate`,m&&a.push(`same origin (${e.origin})`),e.version!==null&&i.version!==null&&e.version===i.version&&a.push(`same version (${e.version})`),(e.version===null||i.version===null)&&a.push(`version unverified`),y&&a.push(`description similarity ${p.toFixed(2)} >= ${t}`),f&&a.push(`origins differ (${e.origin} vs ${i.origin})`),C&&a.push(`versions differ (${e.version} vs ${i.version})`)):(E=`same-name-different-entity`,f&&a.push(`different origins (${e.origin} vs ${i.origin})`),C&&a.push(`different versions (${e.version} vs ${i.version})`),p!==null?a.push(`description similarity ${p.toFixed(2)} < ${t}`):a.push(`description unverified — similarity not measurable`),!m&&!f&&a.push(`origin unverified`)),{a:e.entry.id,b:i.entry.id,verdict:E,reasons:a,similarity:p}}function X(e,i=.8){let t=new Map;for(let p of e){let m=ae(p),f=m.key;if(!f)continue;let C=t.get(f);C?C.push(m):t.set(f,[m])}let a=[];for(let[p,m]of t){if(m.length<2)continue;let f=[];for(let y=0;y<m.length;y++)for(let E=y+1;E<m.length;E++)f.push(re(m[y],m[E],i));let C=f.some(y=>y.verdict===`possible-duplicate`)?`possible-duplicate`:`same-name-different-entity`;a.push({key:p,entries:m.map(y=>y.entry),kind:C,pairs:f})}return a}var ie=(e,i)=>i.id;var le=(e,i)=>i.key;var oe=(e,i)=>i.a+`|`+i.b;function de(e,i){if(e&1){let t=YI();ki(0,`ui-error`,6),uh(`retry`,function(){Yu(t);let p=XI();return Qu(p.load())}),pl()}e&2&&sh(`error`,i)}function se(e,i){e&1&&(ki(0,`div`,4),kD(1,`t`),ah(2,`ui-skeleton`,7),pl()),e&2&&($i(`aria-label`,LD(1,2,`state.loading`)),Vv(2),sh(`lines`,2))}function pe(e,i){if(e&1){let t=YI();ki(0,`button`,9),uh(`click`,function(){let p=Yu(t).$implicit,m=XI(2);return Qu(m.toggleDomain(p))}),DD(1),pl()}if(e&2){let t=i.$implicit,a=XI(2);$i(`data-tone`,a.domain()===t?`accent`:null)(`aria-pressed`,a.domain()===t),Vv(),ml(` `,t,` `)}}function ce(e,i){if(e&1){let t=YI();ki(0,`button`,24),uh(`click`,function(){let p=Yu(t).$implicit,m=XI(4);return Qu(m.pick(p.id))}),DD(1),pl()}if(e&2){let t=i.$implicit;Vv(),ml(` `,t.name||t.id,` `)}}function me(e,i){if(e&1&&(ki(0,`li`)(1,`code`),DD(2),pl(),DD(3,` ↔ `),ki(4,`code`),DD(5),pl(),DD(6),pl()),e&2){let t=i.$implicit;Vv(2),yh(t.a),Vv(3),yh(t.b),Vv(),ml(` — `,t.reasons.join(`; `),` `)}}function ue(e,i){if(e&1&&(ki(0,`li`),ah(1,`ui-state-badge`,20),kD(2,`t`),ki(3,`span`,21),$I(4,ce,2,1,`button`,22,ie),pl(),ki(6,`ul`,23),$I(7,me,7,3,`li`,null,oe),pl()()),e&2){let t=i.$implicit;Vv(),sh(`state`,t.kind===`possible-duplicate`?`unverified`:`warn`)(`labelOverride`,LD(2,2,t.kind===`possible-duplicate`?`skills.dedup.possible`:`skills.dedup.different`)),Vv(3),zI(t.entries),Vv(3),zI(t.pairs)}}function _e(e,i){if(e&1&&(ki(0,`section`,11)(1,`header`,16)(2,`h2`),ah(3,`ui-icon`,17),DD(4),kD(5,`t`),pl(),ki(6,`span`,18),DD(7),kD(8,`t`),pl()(),ki(9,`ul`,19),$I(10,ue,9,4,`li`,null,le),pl()()),e&2){let t=XI(2);Vv(3),sh(`size`,15),Vv(),yh(LD(5,3,`skills.dedup.title`)),Vv(3),yh(LD(8,5,`skills.dedup.hint`)),Vv(3),zI(t.findings())}}function ge(e,i){if(e&1&&(DD(0),ki(1,`code`),DD(2),pl(),ki(3,`span`,32),DD(4),kD(5,`t`),pl()),e&2){let t=i;ml(` `,t.forge_name,` `),Vv(2),ml(`(`,t.forge_id,`)`),Vv(2),yh(LD(5,3,`explorer.serving`))}}function fe(e,i){e&1&&ah(0,`ui-state-badge`,30)}function ye(e,i){if(e&1&&DD(0),e&2){let t=XI();ml(` `,t.hosts.join(`, `),` `)}}function ve(e,i){e&1&&ah(0,`ui-state-badge`,30)}function xe(e,i){if(e&1&&(ki(0,`span`,18),DD(1),pl()),e&2){let t=XI();Vv(),ml(` · `,t.source)}}function Se(e,i){if(e&1){let t=YI();ki(0,`section`,12)(1,`header`,25)(2,`h2`),ah(3,`ui-icon`,26),DD(4),pl(),ki(5,`button`,27),kD(6,`t`),uh(`click`,function(){Yu(t);let p=XI(2);return Qu(p.selected.set(null))}),ah(7,`ui-icon`,28),pl()(),ki(8,`dl`,29)(9,`div`)(10,`dt`),DD(11),kD(12,`t`),pl(),ki(13,`dd`)(14,`code`),DD(15),pl()()(),ki(16,`div`)(17,`dt`),DD(18),kD(19,`t`),pl(),ki(20,`dd`),DD(21),kD(22,`t`),pl()(),ki(23,`div`)(24,`dt`),DD(25),kD(26,`t`),pl(),ki(27,`dd`),DD(28),kD(29,`t`),pl()(),ki(30,`div`)(31,`dt`),DD(32),kD(33,`t`),pl(),ki(34,`dd`),ah(35,`ui-state-badge`,20),pl()(),ki(36,`div`)(37,`dt`),DD(38),kD(39,`t`),pl(),ki(40,`dd`),jI(41,ge,6,5)(42,fe,1,0,`ui-state-badge`,30),pl()(),ki(43,`div`)(44,`dt`),DD(45),kD(46,`t`),pl(),ki(47,`dd`),jI(48,ye,1,1)(49,ve,1,0,`ui-state-badge`,30),pl()(),ki(50,`div`)(51,`dt`),DD(52),kD(53,`t`),pl(),ki(54,`dd`,31),ah(55,`ui-state-badge`,30),ki(56,`small`,18),DD(57),kD(58,`t`),pl()()(),ki(59,`div`)(60,`dt`),DD(61),kD(62,`t`),pl(),ki(63,`dd`,31),ah(64,`ui-state-badge`,30),ki(65,`small`,18),DD(66),kD(67,`t`),pl()()(),ki(68,`div`)(69,`dt`),DD(70),kD(71,`t`),pl(),ki(72,`dd`,31),ah(73,`ui-state-badge`,30),ki(74,`small`,18),DD(75),kD(76,`t`),pl()()(),ki(77,`div`)(78,`dt`),DD(79),kD(80,`t`),pl(),ki(81,`dd`,31),ah(82,`ui-state-badge`,30),ki(83,`small`,18),DD(84),kD(85,`t`),pl()()(),ki(86,`div`)(87,`dt`),DD(88),kD(89,`t`),pl(),ki(90,`dd`,31),ah(91,`ui-state-badge`,30),ki(92,`small`,18),DD(93),kD(94,`t`),pl()()(),ki(95,`div`)(96,`dt`),DD(97),kD(98,`t`),pl(),ki(99,`dd`)(100,`code`),DD(101,`GET /api/v1/skills`),pl(),jI(102,xe,2,1,`span`,18),pl()()()()}if(e&2){let t,a=i,p=XI(2);Vv(3),sh(`size`,15),Vv(),yh(a.name||a.id),Vv(),$i(`aria-label`,LD(6,29,`state.close`)),Vv(2),sh(`size`,14),Vv(4),yh(LD(12,31,`table.id`)),Vv(4),yh(a.id),Vv(3),yh(LD(19,33,`skills.domain`)),Vv(3),yh(a.domain??LD(22,35,`state.absent`)),Vv(4),yh(LD(26,37,`skills.detail.description`)),Vv(3),yh(a.description||LD(29,39,`state.absent`)),Vv(4),yh(LD(33,41,`skills.state`)),Vv(3),sh(`state`,p.mapState(a.state))(`labelOverride`,a.state),Vv(3),yh(LD(39,43,`skills.origin`)),Vv(3),HI((t=p.store.descriptor())?41:42,t),Vv(4),yh(LD(46,45,`skills.compatibility`)),Vv(3),HI(a.hosts.length?48:49),Vv(4),yh(LD(53,47,`settings.version`)),Vv(5),yh(LD(58,49,`skills.notExposed`)),Vv(4),yh(LD(62,51,`skills.prerequisites`)),Vv(5),yh(LD(67,53,`skills.notExposed`)),Vv(4),yh(LD(71,55,`skills.fileValidation`)),Vv(5),yh(LD(76,57,`skills.notExposed`)),Vv(4),yh(LD(80,59,`skills.deps`)),Vv(5),yh(LD(85,61,`skills.notExposed`)),Vv(4),yh(LD(89,63,`skills.actions`)),Vv(5),yh(LD(94,65,`skills.actionsUnverified`)),Vv(4),yh(LD(98,67,`skills.evidence`)),Vv(5),HI(a.source?102:-1)}}function Ce(e,i){if(e&1&&DD(0),e&2){let t=XI().$implicit;ml(` `,t.hosts.join(`, `),` `)}}function ke(e,i){e&1&&ah(0,`ui-state-badge`,30)}function be(e,i){if(e&1){let t=YI();ki(0,`tr`)(1,`td`)(2,`strong`),DD(3),pl(),ki(4,`code`,33),DD(5),pl(),ki(6,`p`,18),DD(7),pl()(),ki(8,`td`),DD(9),pl(),ki(10,`td`),ah(11,`ui-state-badge`,20),pl(),ki(12,`td`),jI(13,Ce,1,1)(14,ke,1,0,`ui-state-badge`,30),pl(),ki(15,`td`)(16,`button`,27),kD(17,`t`),uh(`click`,function(){let p=Yu(t).$implicit,m=XI(2);return Qu(m.selected.set(p))}),ah(18,`ui-icon`,28),pl()()()}if(e&2){let t=i.$implicit,a=XI(2);$i(`data-dup`,a.dupIds().has(t.id)||null),Vv(3),yh(t.name||t.id),Vv(2),yh(t.id),Vv(2),yh(t.description),Vv(2),yh(t.domain??`—`),Vv(2),sh(`state`,a.mapState(t.state))(`labelOverride`,t.state),Vv(2),HI(t.hosts.length?13:14),Vv(3),$i(`aria-label`,LD(17,10,`state.viewDetails`)),Vv(2),sh(`size`,15)}}function he(e,i){e&1&&(ki(0,`tr`)(1,`td`,34),ah(2,`ui-empty`,5),kD(3,`t`),pl()()),e&2&&(Vv(2),sh(`title`,LD(3,1,`skills.empty`)))}function Ee(e,i){if(e&1&&jI(0,he,4,3,`tr`),e&2){let t=XI(2);HI(t.loading()?-1:0)}}function Pe(e,i){if(e&1){let t=YI();ki(0,`ui-filter-bar`,8),Dh(`queryChange`,function(p){Yu(t);let m=XI();return SD(m.query,p)||(m.query=p),Qu(p)}),ki(1,`button`,9),uh(`click`,function(){Yu(t);let p=XI();return Qu(p.domain.set(null))}),DD(2),kD(3,`t`),pl(),$I(4,pe,2,3,`button`,10,BI),pl(),jI(6,_e,12,7,`section`,11),jI(7,Se,103,69,`section`,12),ki(8,`div`,13)(9,`table`,14)(10,`thead`)(11,`tr`)(12,`th`),DD(13),kD(14,`t`),pl(),ki(15,`th`),DD(16),kD(17,`t`),pl(),ki(18,`th`),DD(19),kD(20,`t`),pl(),ki(21,`th`),DD(22),kD(23,`t`),pl(),ki(24,`th`)(25,`span`,15),DD(26),kD(27,`t`),pl()()()(),ki(28,`tbody`),$I(29,be,19,12,`tr`,null,ie,!1,Ee,1,1),pl()()()}if(e&2){let t,a=XI();Ih(`query`,a.query),Vv(),$i(`data-tone`,a.domain()===null?`accent`:null)(`aria-pressed`,a.domain()===null),Vv(),ml(` `,LD(3,12,`state.all`),` `),Vv(2),zI(a.domainOptions()),Vv(2),HI(a.findings().length?6:-1),Vv(),HI((t=a.selected())?7:-1,t),Vv(6),yh(LD(14,14,`table.id`)),Vv(3),yh(LD(17,16,`skills.domain`)),Vv(3),yh(LD(20,18,`skills.state`)),Vv(3),yh(LD(23,20,`skills.hosts`)),Vv(4),yh(LD(27,22,`state.viewDetails`)),Vv(3),zI(a.filtered())}}function Ie(e,i){e&1&&(ah(0,`ui-empty`,5),kD(1,`t`)),e&2&&sh(`title`,LD(1,1,`skills.none`))}var Z=e=>e.normalize(`NFD`).replace(new RegExp(`\\p{Diacritic}`,`gu`),``).toLowerCase().trim();var ee=class e{api=g(hg);store=g(g$1);q=Zi(``);skills=Te([]);error=Te(null);query=Te(``);domain=Te(null);selected=Te(null);loading=Te(!0);domainOptions=zr(()=>{let i=new Set;for(let t of this.skills())t.domain&&i.add(t.domain);return[...i].sort()});filtered=zr(()=>{let i=Z(this.query()),t=this.domain();return this.skills().filter(a=>t!==null&&a.domain!==t?!1:i?[a.id,a.name,a.domain??``,a.description,...a.hosts].map(Z).join(` `).includes(i):!0)});findings=zr(()=>X(this.skills().map(i=>({id:i.id,name:i.name||i.id,origin:this.store.descriptor()?.forge_id??null,version:null,description:i.description}))));dupIds=zr(()=>{let i=new Set;for(let t of this.findings())for(let a of t.entries)i.add(a.id);return i});constructor(){this.load()}ngOnInit(){let i=this.q();i&&this.query.set(i)}async load(){this.error.set(null),this.loading.set(!0);try{this.skills.set(await Tg(this.api.skills()))}catch(i){this.error.set(i instanceof jn?i:new jn(0))}finally{this.loading.set(!1)}}toggleDomain(i){this.domain.set(this.domain()===i?null:i)}pick(i){let t=this.skills().find(a=>a.id===i);t&&this.selected.set(t)}mapState(i){return[`invoked`,`available`,`installed`,`registered`].includes(i)?`supported`:i===`unverified`?`unverified`:`not_applicable`}static ɵfac=function(t){return new(t||e)};static ɵcmp=sl({type:e,selectors:[[`page-skills`]],inputs:{q:[1,`q`]},decls:11,vars:13,consts:[[3,`title`,`subtitle`],[1,`btn`,3,`click`],[`name`,`refresh`,3,`size`],[3,`error`],[`role`,`status`],[`icon`,`skills`,3,`title`],[3,`retry`,`error`],[`kind`,`card`,3,`lines`],[`placeholder`,`skills.search`,3,`queryChange`,`query`],[`type`,`button`,1,`fg-pill`,3,`click`],[`type`,`button`,1,`fg-pill`],[`data-section`,`dedup`,1,`card`,`dedup`],[`data-section`,`skill-detail`,`aria-live`,`polite`,1,`card`,`detail`],[1,`card`,`card--table`],[1,`table`],[1,`sr-only`],[1,`dedup__head`],[`name`,`diff`,3,`size`],[1,`muted`],[1,`dedup__list`],[3,`state`,`labelOverride`],[1,`dedup__names`],[`type`,`button`,1,`chip-link`],[1,`dedup__reasons`],[`type`,`button`,1,`chip-link`,3,`click`],[1,`detail__head`],[`name`,`skills`,3,`size`],[1,`icon-btn`,3,`click`],[`name`,`chevron-right`,3,`size`],[1,`kv`],[`state`,`UNVERIFIED`],[1,`unv-cell`],[1,`chip`],[1,`slug`],[`colspan`,`5`]],template:function(t,a){if(t&1&&(ki(0,`ui-page-header`,0),kD(1,`t`),kD(2,`t`),ki(3,`button`,1),uh(`click`,function(){return a.load()}),ah(4,`ui-icon`,2),DD(5),kD(6,`t`),pl()(),jI(7,de,1,1,`ui-error`,3),jI(8,se,3,4,`div`,4),jI(9,Pe,32,24)(10,Ie,2,3,`ui-empty`,5)),t&2){let p;sh(`title`,LD(1,7,`skills.title`))(`subtitle`,LD(2,9,`skills.subtitle`)),Vv(4),sh(`size`,15),Vv(),ml(` `,LD(6,11,`state.refresh`),` `),Vv(2),HI((p=a.error())?7:-1,p),Vv(),HI(a.loading()?8:-1),Vv(),HI(a.skills().length?9:!a.error()&&!a.loading()?10:-1)}},dependencies:[_$1,I,_,w$1,Eg,h,h$1,yg],styles:[`.muted[_ngcontent-%COMP%]{color:var(--%NS%fg-muted);margin:4px 0 0;font-size:var(--%NS%font-sm)}.slug[_ngcontent-%COMP%]{display:block;color:var(--%NS%fg-muted);font-size:var(--%NS%font-xs)}.card--table[_ngcontent-%COMP%]{padding:var(--%NS%space-3);overflow-x:auto}.card--table[_ngcontent-%COMP%] .table[_ngcontent-%COMP%]{min-width:560px}tr[data-dup][_ngcontent-%COMP%] td[_ngcontent-%COMP%]:first-child{border-left:3px solid var(--%NS%warn)}.dedup[_ngcontent-%COMP%]{margin-bottom:var(--%NS%space-4);border-left:3px solid var(--%NS%warn)}.dedup__head[_ngcontent-%COMP%]{display:flex;align-items:baseline;gap:var(--%NS%space-3);flex-wrap:wrap;margin-bottom:var(--%NS%space-2)}.dedup__head[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0;font-size:var(--%NS%font-lg);font-weight:650;display:inline-flex;align-items:center;gap:var(--%NS%space-2)}.dedup__head[_ngcontent-%COMP%] h2[_ngcontent-%COMP%] ui-icon[_ngcontent-%COMP%]{color:var(--%NS%warn)}.dedup__list[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0;display:grid;gap:var(--%NS%space-3)}.dedup__list[_ngcontent-%COMP%] > li[_ngcontent-%COMP%]{display:grid;gap:4px}.dedup__names[_ngcontent-%COMP%]{display:inline-flex;flex-wrap:wrap;gap:4px}.dedup__reasons[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0;font-size:var(--%NS%font-xs);color:var(--%NS%fg-muted);display:grid;gap:2px}.detail[_ngcontent-%COMP%]{margin-bottom:var(--%NS%space-4);border-left:3px solid var(--%NS%accent)}.detail__head[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;gap:var(--%NS%space-2);margin-bottom:var(--%NS%space-3)}.detail__head[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0;font-size:var(--%NS%font-lg);font-weight:650;display:inline-flex;align-items:center;gap:var(--%NS%space-2)}.detail__head[_ngcontent-%COMP%] h2[_ngcontent-%COMP%] ui-icon[_ngcontent-%COMP%]{color:var(--%NS%accent)}.kv[_ngcontent-%COMP%]{display:grid;gap:var(--%NS%space-2);margin:0}.kv[_ngcontent-%COMP%] div[_ngcontent-%COMP%]{display:flex;align-items:baseline;gap:var(--%NS%space-3)}.kv[_ngcontent-%COMP%] dt[_ngcontent-%COMP%]{min-width:9rem;color:var(--%NS%fg-muted);font-size:var(--%NS%font-sm);flex:none}.kv[_ngcontent-%COMP%] dd[_ngcontent-%COMP%]{margin:0;min-width:0}.unv-cell[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--%NS%space-2)}.chip-link[_ngcontent-%COMP%]{font-size:var(--%NS%font-xs);font-weight:600;color:var(--%NS%accent);background:var(--%NS%accent-bg);border-radius:var(--%NS%radius-pill);padding:1px 8px;border:0;cursor:pointer}.chip[_ngcontent-%COMP%]{font-size:var(--%NS%font-xs);font-weight:700;color:var(--%NS%accent);background:var(--%NS%accent-bg);border-radius:var(--%NS%radius-pill);padding:1px 8px;margin-left:4px}`]})};export{ee as SkillsPage};
@@ -0,0 +1 @@
1
+ import{B as Te,D as K,V as Tg,_t as jn}from"./main-QDFVZK3T.js";function c(e){return e instanceof jn?e:new jn(0)}function p(e){return e.status===404||e.body.code===`PORTAL-NOT-FOUND`}var l=class{data=Te(null);error=Te(null);unavailable=Te(!1);loading=Te(!1);attempted=Te(!1);loadedAt=Te(null);async load(r){this.loading.set(!0),this.error.set(null),this.unavailable.set(!1);try{this.data.set(await Tg(r())),this.loadedAt.set(new Date().toISOString())}catch(n){let i=c(n);p(i)?this.unavailable.set(!0):this.error.set(i)}finally{this.loading.set(!1),this.attempted.set(!0)}}};function y(e){let r=new Date(e);return Number.isNaN(r.getTime())?e:r.toLocaleTimeString()}var g=[`version`,`revision`,`ref`,`release`];function f(e){for(let r of g){let n=e[r];if(typeof n==`string`&&n.trim())return n;if(typeof n==`number`)return String(n)}return null}function w(e,r,n){let i=[],a=new Set;e&&(a.add(e.forge_id),i.push({id:e.forge_id,serving:!0,registryOnly:!1,name:e.forge_name,cli:e.cli,state:r?.state,version:e.forge_version,checkout:void 0,mcp:void 0,specialist:null}));for(let t of n?.specialists??[])a.add(t.provider),i.push({id:t.provider,serving:!1,registryOnly:!1,name:null,cli:t.cli??null,state:t.state??t.status,version:f(t),checkout:t.checkout,mcp:t.mcp,specialist:t});for(let t of n?.installed_forges??[])a.has(t)||(a.add(t),i.push({id:t,serving:!1,registryOnly:!0,name:null,cli:null,state:void 0,version:null,checkout:void 0,mcp:void 0,specialist:null}));return i}function k(){return[{id:`skills`,icon:`skills`,labelKey:`skills.title`,endpoint:`GET /api/v1/skills`,src:new l},{id:`agents`,icon:`agents`,labelKey:`agents.title`,endpoint:`GET /api/v1/agents`,src:new l},{id:`mcp`,icon:`mcp`,labelKey:`mcp.title`,endpoint:`GET /api/v1/mcp/servers`,src:new l},{id:`hosts`,icon:`hosts`,labelKey:`hosts.title`,endpoint:`GET /api/v1/hosts`,src:new l}]}function T(e,r){switch(r){case`skills`:return e.skills().pipe(K(n=>n.length));case`agents`:return e.agents().pipe(K(n=>n.length));case`mcp`:return e.mcpServers().pipe(K(n=>n.length));case`hosts`:return e.hosts().pipe(K(n=>n.length))}}export{l as a,k as i,c as n,w as o,f as r,y as s,T as t};
@@ -0,0 +1 @@
1
+ import{At as sl,Bt as zr,G as XI,Rt as zI,Y as Zi,c as $i,ct as gh,gt as jI,lt as gl,pt as hl,s as $I,u as BI,y as HI,zt as zi}from"./main-QDFVZK3T.js";function k(n,t){n&1&&zi(0,`span`,0)}function b(n,t){n&1&&(hl(0,`span`,1),zi(1,`span`,2),hl(2,`span`,4),zi(3,`span`,5)(4,`span`,6),gl()())}function x(n,t){n&1&&zi(0,`span`,2)}function v(n,t){if(n&1&&zi(0,`span`,7),n&2){let e=XI().$implicit,a=XI();gh(`s--short`,e===a.lastLine()&&a.lines()>1)}}function C(n,t){if(n&1&&jI(0,k,1,0,`span`,0)(1,b,5,0,`span`,1)(2,x,1,0,`span`,2)(3,v,1,2,`span`,3),n&2){let e,a=XI();HI((e=a.kind())===`card`?0:e===`row`?1:e===`avatar`?2:3)}}var h=class n{kind=Zi(`text`);lines=Zi(1,{transform:t=>{let e=Math.floor(Number(t));return Number.isFinite(e)&&e>=1?e:1}});repeats=zr(()=>Array.from({length:this.lines()},(t,e)=>e));lastLine=zr(()=>this.lines()-1);static ɵfac=function(e){return new(e||n)};static ɵcmp=sl({type:n,selectors:[[`ui-skeleton`]],hostAttrs:[`aria-hidden`,`true`],hostVars:1,hostBindings:function(e,a){e&2&&$i(`data-kind`,a.kind())},inputs:{kind:[1,`kind`],lines:[1,`lines`]},decls:2,vars:0,consts:[[1,`s`,`s--card`],[1,`s-row`],[1,`s`,`s--avatar`],[1,`s`,`s--line`,3,`s--short`],[1,`s-row__lines`],[1,`s`,`s--line`,`s--rowtitle`],[1,`s`,`s--line`,`s--short`],[1,`s`,`s--line`]],template:function(e,a){e&1&&$I(0,C,4,1,null,null,BI),e&2&&zI(a.repeats())},styles:[`[_nghost-%COMP%]{display:grid;gap:var(--%NS%space-2);pointer-events:none}[data-kind="card"][_nghost-%COMP%], [data-kind="row"][_nghost-%COMP%]{gap:var(--%NS%space-3)}[data-kind="avatar"][_nghost-%COMP%]{display:flex;flex-wrap:wrap;gap:var(--%NS%space-2)}.s[_ngcontent-%COMP%]{display:block;background:var(--%NS%skeleton, var(--%NS%bg-hover));border-radius:var(--%NS%radius-md)}.s--line[_ngcontent-%COMP%]{height:.8rem;margin:var(--%NS%space-1) 0}.s--short[_ngcontent-%COMP%]{width:62%}.s--rowtitle[_ngcontent-%COMP%]{width:44%}.s--card[_ngcontent-%COMP%]{min-height:7rem;border-radius:var(--%NS%radius-lg);border:1px solid var(--%NS%border)}.s--avatar[_ngcontent-%COMP%]{width:36px;height:36px;border-radius:50%;flex:none}.s-row[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--%NS%space-3)}.s-row__lines[_ngcontent-%COMP%]{display:grid;gap:6px;flex:1;min-width:0}`]})};export{h as t};
@@ -0,0 +1,3 @@
1
+ import{$ as ah,At as sl,B as Te,Bt as zr,Et as pl,G as XI,Ht as l,It as yg,K as YI,Lt as yh,Nt as vh,O as LD,P as Qu,Rt as zI,U as Vv,Vt as k,_ as FD,c as $i,ct as gh,dt as hg,g as Eg,gt as jI,jt as uh,kt as sh,l as AD,m as DD,q as Yu,s as $I,st as g,u as BI,vt as kD,xt as ml,y as HI,yt as ki}from"./main-QDFVZK3T.js";import{a as l$1,s as y}from"./chunk-DQU0VyoQ.js";import{t as h}from"./chunk-DqWNkF1O.js";import{t as _}from"./chunk-BaQMhq-G.js";import{t as w}from"./chunk-BVKnCv85.js";import{t as I}from"./chunk-DyIHOW_a.js";import{t as _$1}from"./chunk-C4gpbtbP.js";var ee=n=>({time:n});var T=(n,i)=>i.file;var te=(n,i)=>i.forge+`/`+i.scenario_id;var ne=(n,i)=>i.id;function ie(n,i){n&1&&(ki(0,`section`,3),ah(1,`ui-state-badge`,6),ki(2,`span`,7),DD(3),kD(4,`t`),pl()()),n&2&&(Vv(3),yh(LD(4,1,`lab.unavailable`)))}function ae(n,i){if(n&1){let e=YI();ki(0,`ui-error`,8),uh(`retry`,function(){Yu(e);let d=XI();return Qu(d.load())}),pl()}n&2&&sh(`error`,i)}function oe(n,i){n&1&&(ki(0,`section`,5),ah(1,`ui-skeleton`,9),pl()),n&2&&(Vv(),sh(`lines`,3))}function re(n,i){if(n&1&&(ki(0,`span`),DD(1),pl()),n&2){let e=XI();Vv(),ml(` · `,e.dir)}}function le(n,i){if(n&1&&(ki(0,`span`),DD(1),kD(2,`t`),pl()),n&2){let e=XI(2);Vv(),ml(` · `,FD(2,1,`common.updatedAt`,AD(4,ee,e.stamp(i))))}}function ce(n,i){n&1&&(ah(0,`ui-empty`,11),kD(1,`t`),kD(2,`t`)),n&2&&sh(`title`,LD(1,2,`lab.empty.title`))(`hint`,LD(2,4,`lab.empty.subtitle`))}function de(n,i){if(n&1&&(ki(0,`option`,17),DD(1),pl()),n&2){let e=i.$implicit;sh(`value`,e.file),Vv(),yh(e.file)}}function pe(n,i){if(n&1&&(ki(0,`option`,17),DD(1),pl()),n&2){let e=i.$implicit;sh(`value`,e.file),Vv(),yh(e.file)}}function se(n,i){if(n&1){let e=YI();ki(0,`tr`)(1,`td`)(2,`code`),DD(3),pl()(),ki(4,`td`),DD(5),pl(),ki(6,`td`),DD(7),pl(),ki(8,`td`,30),DD(9),pl(),ki(10,`td`,31),DD(11),pl(),ki(12,`td`),DD(13),pl(),ki(14,`td`)(15,`button`,32),uh(`click`,function(){let d=Yu(e).$implicit,_=XI(3);return Qu(_.exportJson(d))}),DD(16),kD(17,`t`),pl()()()}if(n&2){let e=i.$implicit,o=XI(3);gh(`sel`,e.file===o.runA()),Vv(3),yh(e.file),Vv(2),yh(e.forges.length),Vv(2),yh(o.countOf(e,null)),Vv(2),yh(o.countOf(e,`pass`)),Vv(2),yh(o.countOf(e,`fail`)),Vv(2),yh(o.countOf(e,`skipped`)),Vv(3),yh(LD(17,9,`lab.export.json`))}}function me(n,i){if(n&1){let e=YI();ki(0,`button`,24),uh(`click`,function(){let d=Yu(e).$implicit,_=XI(3);return Qu(_.forge.set(d))}),DD(1),pl()}if(n&2){let e=i.$implicit,o=XI(3);gh(`on`,o.forge()===e),Vv(),yh(e)}}function _e(n,i){if(n&1&&(ki(0,`span`,35),DD(1),pl()),n&2){let e=i.$implicit,o=XI().$implicit,d=XI(3);$i(`title`,e),Vv(),vh(` `,e,`=`,d.metricText(o,e),` `)}}function ue(n,i){if(n&1&&(ki(0,`tr`)(1,`td`)(2,`code`),DD(3),pl()(),ki(4,`td`),DD(5),pl(),ki(6,`td`),ah(7,`ui-state-badge`,33),pl(),ki(8,`td`),DD(9),pl(),ki(10,`td`,34),$I(11,_e,2,3,`span`,35,BI),pl(),ki(13,`td`,7),DD(14),pl()()),n&2){let e=i.$implicit,o=XI(3);Vv(3),yh(e.forge),Vv(2),yh(e.scenario_id),Vv(2),sh(`state`,o.badgeFor(e.verdict)),Vv(2),yh(e.duration_ms!=null?e.duration_ms+`ms`:`—`),Vv(2),zI(o.metricKeys(e)),Vv(3),yh(e.detail||`—`)}}function xe(n,i){if(n&1&&(ki(0,`tr`)(1,`td`)(2,`code`),DD(3),pl(),DD(4),pl(),ki(5,`td`),ah(6,`ui-state-badge`,33),pl(),ki(7,`td`),ah(8,`ui-state-badge`,33),pl()()),n&2){let e=i.$implicit,o=XI(4);Vv(3),yh(e.forge),Vv(),ml(` `,e.id),Vv(2),sh(`state`,o.badgeFor(e.a)),Vv(2),sh(`state`,o.badgeFor(e.b))}}function fe(n,i){if(n&1){let e=YI();ki(0,`section`,27)(1,`div`,13)(2,`h2`),ah(3,`ui-icon`,36),DD(4),kD(5,`t`),pl(),ki(6,`button`,32),uh(`click`,function(){Yu(e);let d=XI(3);return Qu(d.exportComparisonMd())}),DD(7),kD(8,`t`),pl()(),ki(9,`table`,19)(10,`thead`)(11,`tr`)(12,`th`),DD(13),kD(14,`t`),pl(),ki(15,`th`),DD(16),pl(),ki(17,`th`),DD(18),pl()()(),ki(19,`tbody`),$I(20,xe,9,4,`tr`,null,ne),pl()()()}if(n&2){let e=XI(3);Vv(3),sh(`size`,15),Vv(),yh(LD(5,6,`lab.compare.title`)),Vv(3),yh(LD(8,8,`lab.export.md`)),Vv(6),yh(LD(14,10,`lab.col.scenario`)),Vv(3),yh(e.runA()),Vv(2),yh(e.runB()),Vv(2),zI(e.comparison())}}function be(n,i){if(n&1){let e=YI();ki(0,`details`,38)(1,`summary`)(2,`code`),DD(3),pl(),ki(4,`button`,32),uh(`click`,function(d){let _=Yu(e).$implicit;return XI(4).exportReport(_.file,_.content),Qu(d.preventDefault())}),DD(5),kD(6,`t`),pl()(),ki(7,`pre`,39),DD(8),pl()()}if(n&2){let e=i.$implicit;Vv(3),yh(e.file),Vv(2),ml(` `,LD(6,3,`lab.export.md`),` `),Vv(3),yh(e.content)}}function ge(n,i){if(n&1&&(ki(0,`section`,28)(1,`div`,13)(2,`h2`),ah(3,`ui-icon`,37),DD(4),kD(5,`t`),pl()(),$I(6,be,9,5,`details`,38,T),pl()),n&2){let e=XI(2);Vv(3),sh(`size`,15),Vv(),yh(LD(5,2,`lab.reports`)),Vv(2),zI(e.reports)}}function ye(n,i){if(n&1&&(ki(0,`p`,7),DD(1),pl()),n&2){let e=i.$implicit;Vv(),yh(e)}}function Ce(n,i){if(n&1&&(ki(0,`section`,29)(1,`h2`),DD(2),kD(3,`t`),pl(),$I(4,ye,2,1,`p`,7,BI),pl()),n&2){let e=XI(2);Vv(2),yh(LD(3,1,`lab.notes`)),Vv(2),zI(e.notes)}}function ve(n,i){if(n&1){let e=YI();ki(0,`section`,12)(1,`div`,13)(2,`h2`),ah(3,`ui-icon`,14),DD(4),kD(5,`t`),pl(),ki(6,`div`,15)(7,`label`),DD(8),kD(9,`t`),ki(10,`select`,16),uh(`change`,function(d){Yu(e);let _=XI(2);return Qu(_.runA.set(d.target.value))}),$I(11,de,2,2,`option`,17,T),pl()(),ki(13,`label`),DD(14),kD(15,`t`),ki(16,`select`,16),uh(`change`,function(d){Yu(e);let _=XI(2);return Qu(_.runB.set(d.target.value))}),ki(17,`option`,18),DD(18,`—`),pl(),$I(19,pe,2,2,`option`,17,T),pl()()()(),ki(21,`table`,19)(22,`thead`)(23,`tr`)(24,`th`),DD(25),kD(26,`t`),pl(),ki(27,`th`),DD(28),kD(29,`t`),pl(),ki(30,`th`),DD(31),kD(32,`t`),pl(),ki(33,`th`),DD(34),kD(35,`t`),pl(),ki(36,`th`),DD(37),kD(38,`t`),pl(),ki(39,`th`),DD(40),kD(41,`t`),pl(),ah(42,`th`),pl()(),ki(43,`tbody`),$I(44,se,18,11,`tr`,20,T),pl()()(),ki(46,`section`,21)(47,`div`,13)(48,`h2`),ah(49,`ui-icon`,22),DD(50),kD(51,`t`),pl(),ki(52,`div`,23)(53,`button`,24),uh(`click`,function(){Yu(e);let d=XI(2);return Qu(d.forge.set(``))}),DD(54),kD(55,`t`),pl(),$I(56,me,2,3,`button`,25,BI),pl()(),ki(58,`table`,26)(59,`thead`)(60,`tr`)(61,`th`),DD(62),kD(63,`t`),pl(),ki(64,`th`),DD(65),kD(66,`t`),pl(),ki(67,`th`),DD(68),kD(69,`t`),pl(),ki(70,`th`),DD(71),kD(72,`t`),pl(),ki(73,`th`),DD(74),kD(75,`t`),pl(),ki(76,`th`),DD(77),kD(78,`t`),pl()()(),ki(79,`tbody`),$I(80,ue,15,5,`tr`,null,te),pl()()(),jI(82,fe,22,12,`section`,27),jI(83,ge,8,4,`section`,28),jI(84,Ce,6,3,`section`,29)}if(n&2){let e=XI(),o=XI();Vv(3),sh(`size`,15),Vv(),yh(LD(5,26,`lab.runs`)),Vv(4),ml(``,LD(9,28,`lab.compare.a`),` `),Vv(2),sh(`value`,o.runA()),Vv(),zI(e.runs),Vv(3),ml(``,LD(15,30,`lab.compare.b`),` `),Vv(2),sh(`value`,o.runB()),Vv(3),zI(e.runs),Vv(6),yh(LD(26,32,`lab.col.file`)),Vv(3),yh(LD(29,34,`lab.col.forges`)),Vv(3),yh(LD(32,36,`lab.col.scenarios`)),Vv(3),yh(LD(35,38,`lab.col.pass`)),Vv(3),yh(LD(38,40,`lab.col.fail`)),Vv(3),yh(LD(41,42,`lab.col.skipped`)),Vv(4),zI(e.runs),Vv(5),sh(`size`,15),Vv(),yh(LD(51,44,`lab.catalog`)),Vv(3),gh(`on`,!o.forge()),Vv(),yh(LD(55,46,`lab.filter.all`)),Vv(2),zI(o.forgeNames()),Vv(6),yh(LD(63,48,`lab.col.forge`)),Vv(3),yh(LD(66,50,`lab.col.scenario`)),Vv(3),yh(LD(69,52,`lab.col.verdict`)),Vv(3),yh(LD(72,54,`lab.col.duration`)),Vv(3),yh(LD(75,56,`lab.col.metrics`)),Vv(3),yh(LD(78,58,`lab.col.detail`)),Vv(3),zI(o.scenarioRows()),Vv(2),HI(o.comparison().length?82:-1),Vv(),HI(e.reports.length?83:-1),Vv(),HI(e.notes.length?84:-1)}}function Se(n,i){if(n&1&&(ki(0,`p`,10)(1,`code`),DD(2,`GET /api/v1/lab`),pl(),jI(3,re,2,1,`span`),jI(4,le,3,6,`span`),pl(),jI(5,ce,3,6,`ui-empty`,11)(6,ve,85,60)),n&2){let e,o=i,d=XI();Vv(3),HI(o.dir?3:-1),Vv(),HI((e=d.src.loadedAt())?4:-1,e),Vv(),HI(o.runs.length?6:5)}}var Z=class n{api=g(hg);src=new l$1;data=zr(()=>this.src.data());forge=Te(``);runA=Te(``);runB=Te(``);ngOnInit(){this.load()}async load(){await this.src.load(()=>this.api.lab())}forgeNames(){let i=this.data();if(!i)return[];let e=new Set;for(let o of i.runs)for(let d of o.forges)d.forge&&e.add(d.forge);return[...e].sort()}scenarioRows(){let i=this.data(),e=he(this,`a`),o=[],d=this.runA()||e;for(let _ of i?.runs??[])if(!(d&&_.file!==d)){for(let f of _.forges)if(!(this.forge()&&f.forge!==this.forge()))for(let E of f.results??[])o.push(l(k({},E),{forge:f.forge??`?`,runFile:_.file}))}return o}countOf(i,e){let o=0;for(let d of i.forges)for(let _ of d.results??[])(e===null||_.verdict===e)&&o++;return o}comparison(){let i=this.data(),e=[];if(!i||!this.runA()||!this.runB()||this.runA()===this.runB())return e;let o=f=>{let E=new Map,O=i.runs.find(I=>I.file===f);for(let I of O?.forges??[])for(let M of I.results??[])E.set(`${I.forge}|${M.scenario_id}`,M.verdict);return E},d=o(this.runA()),_=o(this.runB());for(let f of new Set([...d.keys(),..._.keys()])){let[E,O]=f.split(`|`);e.push({forge:E,id:O,a:d.get(f)??`absent`,b:_.get(f)??`absent`})}return e.sort((f,E)=>f.id.localeCompare(E.id))}metricKeys(i){return Object.keys(i.metrics??{})}metricText(i,e){let o=i.metrics?.[e];return!o||o.state!==`measured`||o.value===null?`—`:`${o.value}${o.unit&&o.unit!==`ratio`?o.unit:``}`}badgeFor(i){return i===`pass`?`PASS`:i===`fail`?`FAIL`:i===`not_applicable`?`not_applicable`:`SKIPPED`}exportJson(i){let e=this.data()?.runs.find(o=>o.file===i.file);e&&this.download(i.file.replace(/\.jsonl$/,`.json`),JSON.stringify(e,null,2),`application/json`)}exportReport(i,e){this.download(i,e,`text/markdown`)}exportComparisonMd(){let i=[`# Lab comparison ${this.runA()} vs ${this.runB()}`,``,`| scenario | A | B |`,`|---|---|---|`];for(let e of this.comparison())i.push(`| ${e.forge}/${e.id} | ${e.a} | ${e.b} |`);this.download(`lab-compare-${this.runA()}-vs-${this.runB()}.md`,i.join(`
2
+ `)+`
3
+ `,`text/markdown`)}download(i,e,o){let d=document.createElement(`a`);d.href=URL.createObjectURL(new Blob([e],{type:o})),d.download=i,d.click(),URL.revokeObjectURL(d.href)}stamp=y;static ɵfac=function(e){return new(e||n)};static ɵcmp=sl({type:n,selectors:[[`page-lab`]],decls:11,vars:15,consts:[[3,`title`,`subtitle`],[1,`btn`,3,`click`,`disabled`],[`name`,`refresh`,3,`size`],[`data-section`,`unavailable`,`role`,`note`,1,`card`,`unv`],[3,`error`],[`role`,`status`,1,`card`],[`state`,`UNVERIFIED`],[1,`muted`],[3,`retry`,`error`],[`kind`,`row`,3,`lines`],[1,`src`],[`icon`,`pulse`,`data-section`,`empty`,3,`title`,`hint`],[`data-section`,`runs`,1,`card`],[1,`sec__head`],[`name`,`history`,3,`size`],[1,`row`],[3,`change`,`value`],[3,`value`],[`value`,``],[1,`tbl`],[3,`sel`],[`data-section`,`catalog`,1,`card`],[`name`,`compass`,3,`size`],[1,`chips`],[1,`chip`,3,`click`],[1,`chip`,3,`on`],[`data-table`,`scenarios`,1,`tbl`],[`data-section`,`compare`,1,`card`],[`data-section`,`reports`,1,`card`],[`data-section`,`notes`,1,`card`],[1,`ok`],[1,`bad`],[1,`btn`,`sm`,3,`click`],[3,`state`],[1,`metrics`],[1,`metric`],[`name`,`graph`,3,`size`],[`name`,`tasks`,3,`size`],[1,`rep`],[1,`rep__body`]],template:function(e,o){if(e&1&&(ki(0,`ui-page-header`,0),kD(1,`t`),kD(2,`t`),ki(3,`button`,1),uh(`click`,function(){return o.load()}),ah(4,`ui-icon`,2),DD(5),kD(6,`t`),pl()(),jI(7,ie,5,3,`section`,3),jI(8,ae,1,1,`ui-error`,4),jI(9,oe,2,1,`section`,5),jI(10,Se,7,3)),e&2){let d,_;sh(`title`,LD(1,9,`lab.title`))(`subtitle`,LD(2,11,`lab.subtitle`)),Vv(3),sh(`disabled`,o.src.loading()),Vv(),sh(`size`,15),Vv(),ml(` `,LD(6,13,`state.refresh`),` `),Vv(2),HI(o.src.unavailable()?7:-1),Vv(),HI((d=o.src.error())?8:-1,d),Vv(),HI(o.src.loading()&&!o.data()?9:-1),Vv(),HI((_=o.data())?10:-1,_)}},dependencies:[_$1,I,_,w,Eg,h,yg],styles:[`.unv[_ngcontent-%COMP%]{display:flex;gap:10px;align-items:center}.src[_ngcontent-%COMP%]{color:var(--%NS%muted,#888);font-size:12px}.sec__head[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;flex-wrap:wrap;gap:8px}.row[_ngcontent-%COMP%]{display:flex;gap:12px;align-items:center}.chips[_ngcontent-%COMP%]{display:flex;gap:6px;flex-wrap:wrap}.chip[_ngcontent-%COMP%]{padding:3px 10px;border-radius:99px;border:1px solid var(--%NS%line,#444);background:none;cursor:pointer}.chip.on[_ngcontent-%COMP%]{background:var(--%NS%accent,#4f8cff);color:#fff}.tbl[_ngcontent-%COMP%]{width:100%;border-collapse:collapse;font-size:13px}.tbl[_ngcontent-%COMP%] th[_ngcontent-%COMP%], .tbl[_ngcontent-%COMP%] td[_ngcontent-%COMP%]{text-align:left;padding:6px 8px;border-bottom:1px solid var(--%NS%line,#333)}.ok[_ngcontent-%COMP%]{color:var(--%NS%ok,#4caf50)}.bad[_ngcontent-%COMP%]{color:var(--%NS%bad,#f44336)}.sel[_ngcontent-%COMP%]{background:color-mix(in srgb,var(--%NS%accent,#4f8cff) 10%,transparent)}.metrics[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:4px;max-width:420px}.metric[_ngcontent-%COMP%]{font-size:11px;padding:1px 6px;border:1px solid var(--%NS%line,#444);border-radius:4px}.rep__body[_ngcontent-%COMP%]{max-height:340px;overflow:auto;font-size:12px;white-space:pre-wrap}select[_ngcontent-%COMP%]{margin-left:6px}.muted[_ngcontent-%COMP%]{color:var(--%NS%muted,#888)}`]})};function he(n,i){let e=n.data();return e?.runs.length?e.runs[e.runs.length-1].file:``}export{Z as LabPage};
@@ -0,0 +1 @@
1
+ import{At as sl,Bt as zr,Lt as yh,Mt as us,U as Vv,Y as Zi,c as $i,lt as gl,m as DD,pt as hl,st as g}from"./main-QDFVZK3T.js";var b={VERIFIED:`ok`,ACTIVE:`ok`,CONFIGURED:`ok`,INSTALLED:`info`,DEGRADED:`warn`,BLOCKED:`warn`,NOT_INSTALLED:`muted`,FAILED:`error`,INVOCATION_VERIFIED:`ok`,HANDSHAKE_VERIFIED:`ok`,TOOLS_DISCOVERED:`ok`,DETECTED:`info`,MCP_REGISTERED:`ok`,EXECUTION_VERIFIED:`ok`,NOT_DETECTED:`muted`,STARTING:`info`,NOT_CONFIGURED:`muted`,supported:`ok`,unverified:`warn`,unsupported:`error`,not_applicable:`muted`,PASS:`ok`,FAIL:`error`,UNVERIFIED:`warn`,NOT_APPLICABLE:`muted`,READY:`ok`,PARTIAL:`warn`,MISSING:`muted`,INVALID:`error`,UNSET:`muted`,ok:`ok`,warn:`warn`,error:`error`,info:`info`,muted:`muted`};var u={VERIFIED:`installState.`,ACTIVE:`installState.`,CONFIGURED:`installState.`,INSTALLED:`installState.`,DEGRADED:`installState.`,BLOCKED:`installState.`,NOT_INSTALLED:`installState.`,FAILED:`installState.`,INVOCATION_VERIFIED:`mcpState.`,HANDSHAKE_VERIFIED:`mcpState.`,TOOLS_DISCOVERED:`mcpState.`,STARTING:`mcpState.`,NOT_CONFIGURED:`mcpState.`,DETECTED:`hostState.`,MCP_REGISTERED:`hostState.`,EXECUTION_VERIFIED:`hostState.`,NOT_DETECTED:`hostState.`,supported:`state.supported`,unverified:`state.unverified`,unsupported:`state.unsupported`,not_applicable:`state.notApplicable`,READY:`environmentState.`,PARTIAL:`environmentState.`,MISSING:`environmentState.`,INVALID:`environmentState.`,UNSET:`environmentState.`};var I=class o{i18n=g(us);state=Zi.required();labelOverride=Zi(null);kind=zr(()=>b[this.state()]??`muted`);label=zr(()=>{let a=this.labelOverride();if(a)return a;let e=this.state(),t=u[e];return t===void 0?e:t.endsWith(`.`)?this.i18n.t(`${t}${e}`):this.i18n.t(t)});static ɵfac=function(e){return new(e||o)};static ɵcmp=sl({type:o,selectors:[[`ui-state-badge`]],inputs:{state:[1,`state`],labelOverride:[1,`labelOverride`]},decls:2,vars:2,consts:[[`role`,`status`,1,`badge`]],template:function(e,t){e&1&&(hl(0,`span`,0),DD(1),gl()),e&2&&($i(`data-kind`,t.kind()),Vv(),yh(t.label()))},styles:[`.badge[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:6px;padding:2px 10px;border-radius:var(--%NS%radius-pill);font-size:var(--%NS%font-xs);font-weight:650;letter-spacing:.02em;border:1px solid color-mix(in srgb,var(--%NS%badge-fg, var(--%NS%fg-muted)) 35%,transparent);color:var(--%NS%badge-fg, var(--%NS%fg-muted));background:var(--%NS%badge-bg, transparent);white-space:nowrap}.badge[_ngcontent-%COMP%]:before{content:"";width:6px;height:6px;border-radius:50%;background:var(--%NS%badge-fg, var(--%NS%fg-muted));box-shadow:0 0 0 2px color-mix(in srgb,var(--%NS%badge-fg, var(--%NS%fg-muted)) 25%,transparent)}.badge[data-kind=ok][_ngcontent-%COMP%]{--%NS%badge-fg: var(--%NS%ok);--%NS%badge-bg: var(--%NS%ok-bg)}.badge[data-kind=warn][_ngcontent-%COMP%]{--%NS%badge-fg: var(--%NS%warn);--%NS%badge-bg: var(--%NS%warn-bg)}.badge[data-kind=error][_ngcontent-%COMP%]{--%NS%badge-fg: var(--%NS%error);--%NS%badge-bg: var(--%NS%error-bg)}.badge[data-kind=info][_ngcontent-%COMP%]{--%NS%badge-fg: var(--%NS%info);--%NS%badge-bg: var(--%NS%info-bg)}`]})};export{I as t};
@@ -0,0 +1 @@
1
+ import{$ as ah,At as sl,B as Te,Bt as zr,Et as pl,F as RD,G as XI,Ht as l,It as yg,K as YI,Lt as yh,O as LD,P as Qu,Rt as zI,U as Vv,V as Tg,Vt as k,_ as FD,_t as jn,a as f,c as $i,ct as gh,dt as hg,g as Eg,gt as jI,jt as uh,kt as sh,l as AD,m as DD,q as Yu,s as $I,st as g,u as BI,vt as kD,xt as ml,y as HI,yt as ki}from"./main-QDFVZK3T.js";import{a as l$1,s as y}from"./chunk-DQU0VyoQ.js";import{t as h}from"./chunk-DqWNkF1O.js";import{t as _}from"./chunk-BaQMhq-G.js";import{t as w}from"./chunk-BVKnCv85.js";import{t as I}from"./chunk-DyIHOW_a.js";import{t as _$1}from"./chunk-C4gpbtbP.js";var et=()=>[1,2,3];var Z=t=>({time:t});var nt=(t,i)=>i.host;var it=(t,i)=>i.id;function at(t,i){if(t&1){let e=YI();ki(0,`ui-error`,6),uh(`retry`,function(){Yu(e);let _=XI();return Qu(_.load())}),pl()}t&2&&sh(`error`,i)}function ot(t,i){t&1&&(ki(0,`section`,4),ah(1,`ui-state-badge`,7),ki(2,`p`,8),DD(3),kD(4,`t`),pl()()),t&2&&(Vv(3),yh(LD(4,1,`hosts.ops.unsupported`)))}function rt(t,i){t&1&&ah(0,`ui-skeleton`,9)}function ct(t,i){t&1&&(ki(0,`section`,5),$I(1,rt,1,0,`ui-skeleton`,9,BI),pl()),t&2&&(Vv(),zI(RD(0,et)))}function lt(t,i){if(t&1&&(ki(0,`p`,14),DD(1),kD(2,`t`),pl()),t&2){let e=XI(2);Vv(),yh(FD(2,1,`common.updatedAt`,AD(4,Z,e.stamp(i))))}}function st(t,i){t&1&&ah(0,`ui-icon`,32),t&2&&sh(`size`,11)}function dt(t,i){if(t&1&&(ki(0,`li`)(1,`span`,31),jI(2,st,1,1,`ui-icon`,32),pl(),DD(3),kD(4,`t`),pl()),t&2){let e=i.$implicit,r=i.$index,_=XI().$implicit,d=XI(2);$i(`data-state`,d.stageState(_,r))(`aria-current`,d.stageState(_,r)===`active`?`step`:null),Vv(2),HI(d.stageState(_,r)===`done`?2:-1),Vv(),ml(` `,LD(4,4,`hostState.`+e.state),` `)}}function pt(t,i){if(t&1&&(ki(0,`li`,24)(1,`span`,31),ah(2,`ui-icon`,33),pl(),DD(3),kD(4,`t`),pl()),t&2){let e=XI().$implicit;$i(`data-state`,i),Vv(2),sh(`size`,11),Vv(),ml(` `,LD(4,3,`hostState.`+e.integration),` `)}}function mt(t,i){t&1&&ah(0,`ui-state-badge`,7)}function _t(t,i){if(t&1&&(DD(0),kD(1,`t`)),t&2){let e=XI().$implicit,r=XI(2);ml(` `,LD(1,1,r.authLabel(e)),` `)}}function gt(t,i){if(t&1&&(ki(0,`div`,26)(1,`dt`),DD(2),kD(3,`t`),pl(),ki(4,`dd`)(5,`code`),DD(6),pl()()()),t&2){let e=XI().$implicit;Vv(2),yh(LD(3,2,`hosts.commandHint`)),Vv(4),yh(e.command_hint)}}function ut(t,i){if(t&1&&(ki(0,`p`,8),DD(1),pl()),t&2){let e=XI().$implicit;Vv(),yh(e.detail)}}function yt(t,i){if(t&1&&(ki(0,`span`,34),ah(1,`ui-state-badge`,22)(2,`ui-icon`,35)(3,`ui-state-badge`,22),pl()),t&2){let e=XI(),r=XI().$implicit;Vv(),sh(`state`,e.from),Vv(),sh(`size`,12),Vv(),sh(`state`,r.integration)}}function Ct(t,i){if(t&1&&(ki(0,`p`,27),ah(1,`ui-icon`,32),ki(2,`span`),DD(3),kD(4,`t`),pl(),jI(5,yt,4,3,`span`,34),pl()),t&2){let e=i,r=XI(3);Vv(),sh(`size`,12),Vv(2),yh(FD(4,3,`common.updatedAt`,AD(6,Z,r.stamp(e.at)))),Vv(2),HI(e.changed&&e.from?5:-1)}}function xt(t,i){if(t&1){let e=YI();ki(0,`div`,37)(1,`p`,38),ah(2,`ui-icon`,29),DD(3),kD(4,`t`),pl(),ki(5,`button`,39),kD(6,`t`),uh(`click`,function(){Yu(e);let _=XI(),d=XI().$implicit,v=XI(2);return Qu(v.copyCommand(d.host,_.command))}),ah(7,`ui-icon`,40),DD(8),kD(9,`t`),pl()(),ki(10,`code`,41),DD(11),pl()}if(t&2){let e=XI(),r=XI().$implicit,_=XI(2);Vv(2),sh(`size`,13),Vv(),ml(``,LD(4,7,`hosts.launch.copyHint`),` `),Vv(2),$i(`aria-label`,LD(6,9,`state.copy`)),Vv(2),sh(`name`,_.copied()===r.host?`check`:`copy`)(`size`,13),Vv(),ml(` `,LD(9,11,_.copied()===r.host?`state.copied`:`state.copy`),` `),Vv(3),yh(e.command)}}function vt(t,i){if(t&1&&DD(0),t&2){let e=XI(2);ml(` — `,e.detail,` `)}}function ft(t,i){if(t&1&&(ki(0,`p`,36)(1,`strong`),DD(2),kD(3,`t`),pl(),ki(4,`code`),DD(5),pl(),jI(6,vt,1,1),pl()),t&2){let e=XI();Vv(2),yh(LD(3,3,`install.refused`)),Vv(3),yh(e.refusal),Vv(),HI(e.detail?6:-1)}}function ht(t,i){if(t&1&&(ki(0,`span`),DD(1),pl()),t&2){let e=XI(2);Vv(),ml(`— `,e.detail)}}function St(t,i){if(t&1&&(ki(0,`p`,8),DD(1),kD(2,`t`),jI(3,ht,2,1,`span`),pl()),t&2){let e=XI();Vv(),ml(` `,LD(2,2,`hosts.launch.unavailable`),` `),Vv(2),HI(e.detail?3:-1)}}function bt(t,i){if(t&1&&(ki(0,`div`,30),jI(1,xt,12,13)(2,ft,7,5,`p`,36)(3,St,4,4,`p`,8),pl()),t&2){let e=i;$i(`data-kind`,e.command?`command`:e.refusal?`refusal`:`none`),Vv(),HI(e.command?1:e.refusal?2:3)}}function Pt(t,i){if(t&1){let e=YI();ki(0,`article`,16)(1,`header`,20)(2,`h2`),ah(3,`ui-icon`,21),DD(4),pl(),ah(5,`ui-state-badge`,22),pl(),ki(6,`ol`,23),kD(7,`t`),$I(8,dt,5,6,`li`,null,it),jI(10,pt,5,5,`li`,24),pl(),ki(11,`dl`,25)(12,`div`)(13,`dt`),DD(14),kD(15,`t`),pl(),ki(16,`dd`),DD(17),kD(18,`t`),pl()(),ki(19,`div`)(20,`dt`),DD(21),kD(22,`t`),pl(),ki(23,`dd`),DD(24),kD(25,`t`),pl()(),ki(26,`div`)(27,`dt`),DD(28),kD(29,`t`),pl(),ki(30,`dd`),ah(31,`ui-state-badge`,22),pl()(),ki(32,`div`)(33,`dt`),DD(34),kD(35,`t`),pl(),ki(36,`dd`),jI(37,mt,1,0,`ui-state-badge`,7)(38,_t,2,3),pl()(),ki(39,`div`)(40,`dt`),DD(41),kD(42,`t`),pl(),ki(43,`dd`),DD(44),kD(45,`t`),pl()(),jI(46,gt,7,4,`div`,26),pl(),jI(47,ut,2,1,`p`,8),jI(48,Ct,6,8,`p`,27),ki(49,`div`,28)(50,`button`,1),uh(`click`,function(){let _=Yu(e).$implicit,d=XI(2);return Qu(d.requestIntegration(_))}),ah(51,`ui-icon`,29),DD(52),kD(53,`t`),pl()(),jI(54,bt,4,2,`div`,30),pl()}if(t&2){let e,r,_,d=i.$implicit,v=XI(2);$i(`data-off`,!d.detected||null)(`data-host`,d.host),Vv(3),sh(`size`,16),Vv(),yh(d.host),Vv(),sh(`state`,d.integration),Vv(),$i(`aria-label`,LD(7,27,`hosts.integration`))(`data-lc`,d.host),Vv(2),zI(v.stages),Vv(2),HI((e=v.terminalState(d))?10:-1,e),Vv(4),yh(LD(15,29,`hosts.detected`)),Vv(3),yh(LD(18,31,d.detected?`state.yes`:`state.no`)),Vv(4),yh(LD(22,33,`hosts.version`)),Vv(3),yh(d.version??LD(25,35,`state.unknown`)),Vv(4),yh(LD(29,37,`hosts.supported`)),Vv(3),sh(`state`,d.supported?`supported`:`unsupported`),Vv(3),yh(LD(35,39,`hosts.auth`)),Vv(3),HI(d.logged_in===null?37:38),Vv(4),yh(LD(42,41,`hosts.launchable`)),Vv(3),yh(LD(45,43,d.launchable?`state.yes`:`state.no`)),Vv(2),HI(d.command_hint?46:-1),Vv(),HI(d.detail?47:-1),Vv(),HI((r=v.checks()[d.host])?48:-1,r),Vv(2),gh(`btn--primary`,d.detected),sh(`disabled`,v.launchBusy()!==null),Vv(),sh(`size`,14),Vv(),ml(` `,LD(53,45,`hosts.request`),` `),Vv(2),HI((_=v.launch()[d.host])?54:-1,_)}}function Ot(t,i){t&1&&(ah(0,`ui-empty`,42),kD(1,`t`),kD(2,`t`)),t&2&&sh(`title`,LD(1,2,`empty.noData`))(`hint`,LD(2,4,`empty.noData.hint`))}function Et(t,i){if(t&1&&jI(0,Ot,3,6,`ui-empty`,42),t&2){let e=XI(2);HI(!e.src.error()&&!e.src.loading()?0:-1)}}function Mt(t,i){if(t&1&&(ki(0,`li`),ah(1,`ui-state-badge`,7),ki(2,`span`,43)(3,`strong`),DD(4),kD(5,`t`),pl(),ki(6,`small`),DD(7),kD(8,`t`),pl()()()),t&2){let e=i.$implicit;Vv(4),yh(LD(5,2,e)),Vv(3),yh(LD(8,4,`hosts.ops.unsupported`))}}function Nt(t,i){if(t&1&&(ki(0,`section`,10)(1,`h2`,11),DD(2),kD(3,`t`),pl(),ki(4,`div`,12)(5,`span`,13)(6,`strong`),DD(7),pl(),DD(8),kD(9,`t`),pl(),ki(10,`span`,13)(11,`strong`),DD(12),pl(),DD(13),kD(14,`t`),pl(),ki(15,`span`,13)(16,`strong`),DD(17),pl(),DD(18),kD(19,`t`),pl()(),jI(20,lt,3,6,`p`,14),pl(),ki(21,`section`,15),$I(22,Pt,55,47,`article`,16,nt,!1,Et,1,1),pl(),ki(25,`section`,17)(26,`h2`,18),DD(27),kD(28,`t`),pl(),ki(29,`ul`,19),$I(30,Mt,9,6,`li`,null,BI),pl()()),t&2){let e,r=XI();Vv(2),yh(LD(3,11,`dashboard.inventory`)),Vv(5),yh(r.summary().detected),Vv(),ml(` `,LD(9,13,`hosts.detected`),` `),Vv(4),yh(r.summary().integrated),Vv(),ml(` `,LD(14,15,`hosts.installed`),` `),Vv(2),$i(`data-warn`,r.summary().unknown>0||null),Vv(2),yh(r.summary().unknown),Vv(),ml(` `,LD(19,17,`hosts.auth.unknown`),` `),Vv(2),HI((e=r.src.loadedAt())?20:-1,e),Vv(2),zI(i),Vv(5),yh(LD(28,19,`install.ops.title`)),Vv(3),zI(r.capabilities)}}var It=[{id:`detect`,state:`DETECTED`},{id:`install`,state:`INSTALLED`},{id:`configure`,state:`CONFIGURED`},{id:`mcp`,state:`MCP_REGISTERED`},{id:`handshake`,state:`HANDSHAKE_VERIFIED`},{id:`tools`,state:`TOOLS_DISCOVERED`},{id:`exec`,state:`EXECUTION_VERIFIED`}];var wt={DETECTED:0,INSTALLED:1,CONFIGURED:2,MCP_REGISTERED:3,HANDSHAKE_VERIFIED:4,TOOLS_DISCOVERED:5,EXECUTION_VERIFIED:6};var Tt=new Set([`INSTALLED`,`CONFIGURED`,`MCP_REGISTERED`,`HANDSHAKE_VERIFIED`,`TOOLS_DISCOVERED`,`EXECUTION_VERIFIED`]);var Y=class t{api=g(hg);toast=g(f);src=new l$1;hosts=zr(()=>this.src.data());checks=Te({});launch=Te({});launchBusy=Te(null);copied=Te(null);stages=It;capabilities=[`hosts.ops.plan`,`hosts.ops.files`,`hosts.ops.fix`,`hosts.ops.disable`];summary=zr(()=>{let i=this.hosts()??[];return{detected:i.filter(e=>e.detected).length,integrated:i.filter(e=>Tt.has(e.integration)).length,unknown:i.filter(e=>e.logged_in===null).length}});constructor(){this.load()}async load(){let i=this.src.data()??[];await this.src.load(()=>this.api.hosts());let e=this.src.data();if(!e)return;let r=this.src.loadedAt()??new Date().toISOString(),_=k({},this.checks());for(let d of e){let v=i.find(tt=>tt.host===d.host),B=v&&v.integration!==d.integration?v.integration:null;_[d.host]={at:r,changed:B!==null,from:B}}this.checks.set(_)}stageIndex(i){return wt[i]??-1}stageState(i,e){let r=this.stageIndex(i.integration);return e<r?`done`:e===r?`active`:`todo`}terminalState(i){return i.integration===`FAILED`?`error`:i.integration===`BLOCKED`?`warn`:null}authLabel(i){return i.logged_in===null?`hosts.auth.unknown`:i.logged_in?`hosts.auth.signedIn`:`hosts.auth.signedOut`}async requestIntegration(i){if(this.launchBusy()===null){this.launchBusy.set(i.host);try{let e=await Tg(this.api.hostsLaunch(i.host)),r={command:e.command??null,refusal:e.refusal??null,detail:e.detail??null,at:new Date().toISOString()};this.launch.update(_=>l(k({},_),{[i.host]:r})),r.command?this.toast.show(`notify.success`,`success`):r.refusal?this.toast.show(r.refusal,`error`):this.toast.show(`hosts.launch.unavailable`,`info`)}catch(e){this.src.error.set(e instanceof jn?e:new jn(0))}finally{this.launchBusy.set(null)}}}async copyCommand(i,e){try{await navigator.clipboard.writeText(e),this.copied.set(i),this.toast.show(`state.copied`,`success`),setTimeout(()=>{this.copied()===i&&this.copied.set(null)},1600)}catch{this.toast.show(`error.generic`,`error`)}}stamp=y;static ɵfac=function(e){return new(e||t)};static ɵcmp=sl({type:t,selectors:[[`page-hosts`]],decls:11,vars:15,consts:[[3,`title`,`subtitle`],[1,`btn`,3,`click`,`disabled`],[`name`,`refresh`,3,`size`],[3,`error`],[`role`,`note`,1,`card`,`unverified-panel`],[`role`,`status`,`aria-live`,`polite`,1,`grid`],[3,`retry`,`error`],[`state`,`unverified`],[1,`muted`],[`kind`,`card`],[`aria-labelledby`,`summary-h`,1,`card`,`summary`],[`id`,`summary-h`],[1,`stats`],[1,`stat`],[1,`probe`,`muted`],[1,`grid`],[`data-lift`,``,1,`card`,`host`],[`aria-labelledby`,`caps-h`,1,`card`],[`id`,`caps-h`],[1,`capability`],[1,`card__head`],[`name`,`hosts`,3,`size`],[3,`state`],[1,`lc`],[1,`terminal`],[1,`kv`],[1,`kv__cmd`],[1,`checked`],[1,`row`],[`name`,`terminal`,3,`size`],[1,`outcome`],[`aria-hidden`,`true`,1,`dot`],[`name`,`check`,3,`size`],[`name`,`alert`,3,`size`],[1,`transition`],[`name`,`chevron-right`,3,`size`],[`role`,`alert`,1,`refusal`],[1,`outcome__head`],[1,`outcome__title`],[1,`btn`,`btn--mini`,3,`click`],[3,`name`,`size`],[1,`outcome__cmd`],[`icon`,`hosts`,3,`title`,`hint`],[1,`capability__body`,`muted`]],template:function(e,r){if(e&1&&(ki(0,`ui-page-header`,0),kD(1,`t`),kD(2,`t`),ki(3,`button`,1),uh(`click`,function(){return r.load()}),ah(4,`ui-icon`,2),DD(5),kD(6,`t`),pl()(),jI(7,at,1,1,`ui-error`,3),jI(8,ot,5,3,`section`,4),jI(9,ct,3,1,`section`,5),jI(10,Nt,32,21)),e&2){let _,d;sh(`title`,LD(1,9,`hosts.title`))(`subtitle`,LD(2,11,`hosts.subtitle`)),Vv(3),sh(`disabled`,r.src.loading()),Vv(),sh(`size`,15),Vv(),ml(` `,LD(6,13,`state.refresh`),` `),Vv(2),HI((_=r.src.error())?7:-1,_),Vv(),HI(r.src.unavailable()?8:-1),Vv(),HI(r.src.loading()&&!r.hosts()?9:-1),Vv(),HI((d=r.hosts())?10:-1,d)}},dependencies:[_$1,I,_,w,Eg,h,yg],styles:[`.card[_ngcontent-%COMP%]{margin-bottom:var(--%NS%space-4)}.card[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0;font-size:var(--%NS%font-lg);font-weight:650;letter-spacing:-.01em}.card[_ngcontent-%COMP%] > h2[_ngcontent-%COMP%]{margin-bottom:var(--%NS%space-3)}.stats[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:var(--%NS%space-2)}.stat[_ngcontent-%COMP%]{display:inline-flex;align-items:baseline;gap:6px;padding:var(--%NS%space-2) var(--%NS%space-3);border:1px solid var(--%NS%border);border-radius:var(--%NS%radius-pill);font-size:var(--%NS%font-sm);color:var(--%NS%fg-muted)}.stat[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{color:var(--%NS%fg);font-size:var(--%NS%font-md)}.stat[data-warn][_ngcontent-%COMP%], .stat[data-warn][_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{color:var(--%NS%warn)}.stat[data-warn][_ngcontent-%COMP%]{border-color:color-mix(in srgb,var(--%NS%warn) 45%,transparent)}.probe[_ngcontent-%COMP%]{margin:var(--%NS%space-2) 0 0;font-size:var(--%NS%font-xs)}.grid[_ngcontent-%COMP%]{display:grid;gap:var(--%NS%space-4);grid-template-columns:repeat(auto-fit,minmax(300px,1fr));margin-bottom:var(--%NS%space-4)}.host[data-off][_ngcontent-%COMP%]{opacity:.55;filter:grayscale(.6)}.card__head[_ngcontent-%COMP%], .outcome__head[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:center;gap:var(--%NS%space-2)}.card__head[_ngcontent-%COMP%]{margin-bottom:var(--%NS%space-3)}.card__head[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{text-transform:capitalize;display:inline-flex;align-items:center;gap:var(--%NS%space-2)}.card__head[_ngcontent-%COMP%] ui-icon[_ngcontent-%COMP%]{color:var(--%NS%accent)}.lc[_ngcontent-%COMP%]{list-style:none;margin:0 0 var(--%NS%space-3);padding:0;display:grid}.lc[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{position:relative;display:flex;align-items:center;gap:var(--%NS%space-2);padding:3px 0;color:var(--%NS%fg-muted);font-size:var(--%NS%font-xs)}.lc[_ngcontent-%COMP%] li[_ngcontent-%COMP%]:not(:last-child):after{content:"";position:absolute;left:7px;top:21px;bottom:-3px;width:2px;border-radius:1px;background:var(--%NS%border)}.lc[_ngcontent-%COMP%] .dot[_ngcontent-%COMP%]{position:relative;display:grid;place-items:center;width:16px;height:16px;flex:none;border-radius:50%;border:1.5px solid var(--%NS%border-strong);background:var(--%NS%bg-elevated)}.lc[_ngcontent-%COMP%] li[data-state=done][_ngcontent-%COMP%], .lc[_ngcontent-%COMP%] li[data-state=active][_ngcontent-%COMP%]{color:var(--%NS%fg)}.lc[_ngcontent-%COMP%] li[data-state=done][_ngcontent-%COMP%] .dot[_ngcontent-%COMP%]{background:var(--%NS%ok);border-color:var(--%NS%ok);color:#fff}.lc[_ngcontent-%COMP%] li[data-state=done][_ngcontent-%COMP%]:not(:last-child):after{background:var(--%NS%ok)}.lc[_ngcontent-%COMP%] li[data-state=active][_ngcontent-%COMP%]{font-weight:650}.lc[_ngcontent-%COMP%] li[data-state=active][_ngcontent-%COMP%] .dot[_ngcontent-%COMP%]{border-color:var(--%NS%accent);box-shadow:0 0 0 3px color-mix(in srgb,var(--%NS%accent) 15%,transparent)}.lc[_ngcontent-%COMP%] li[data-state=warn][_ngcontent-%COMP%], .lc[_ngcontent-%COMP%] li[data-state=error][_ngcontent-%COMP%]{margin-top:2px;font-weight:600}.lc[_ngcontent-%COMP%] li[data-state=warn][_ngcontent-%COMP%]{color:var(--%NS%warn)}.lc[_ngcontent-%COMP%] li[data-state=error][_ngcontent-%COMP%]{color:var(--%NS%error)}.lc[_ngcontent-%COMP%] li[data-state=warn][_ngcontent-%COMP%] .dot[_ngcontent-%COMP%], .lc[_ngcontent-%COMP%] li[data-state=error][_ngcontent-%COMP%] .dot[_ngcontent-%COMP%]{color:#fff}.lc[_ngcontent-%COMP%] li[data-state=warn][_ngcontent-%COMP%] .dot[_ngcontent-%COMP%]{background:var(--%NS%warn);border-color:var(--%NS%warn)}.lc[_ngcontent-%COMP%] li[data-state=error][_ngcontent-%COMP%] .dot[_ngcontent-%COMP%]{background:var(--%NS%error);border-color:var(--%NS%error)}.kv[_ngcontent-%COMP%]{display:grid;gap:6px;margin:0 0 var(--%NS%space-3)}.kv[_ngcontent-%COMP%] div[_ngcontent-%COMP%]{display:flex;justify-content:space-between;gap:var(--%NS%space-2)}.kv[_ngcontent-%COMP%] dt[_ngcontent-%COMP%]{color:var(--%NS%fg-muted)}.kv[_ngcontent-%COMP%] dd[_ngcontent-%COMP%]{margin:0}.kv__cmd[_ngcontent-%COMP%] code[_ngcontent-%COMP%], .outcome__cmd[_ngcontent-%COMP%], .refusal[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{font-family:var(--%NS%font-mono);font-size:var(--%NS%font-xs);overflow-wrap:anywhere}.muted[_ngcontent-%COMP%]{color:var(--%NS%fg-muted)}.checked[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--%NS%space-2);flex-wrap:wrap;margin:0 0 var(--%NS%space-2);font-size:var(--%NS%font-xs);color:var(--%NS%fg-muted)}.checked[_ngcontent-%COMP%] ui-icon[_ngcontent-%COMP%]{color:var(--%NS%ok)}.transition[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:4px;color:var(--%NS%fg-muted)}.row[_ngcontent-%COMP%]{margin-top:var(--%NS%space-3)}.outcome[_ngcontent-%COMP%]{margin-top:var(--%NS%space-3);padding:var(--%NS%space-3);border:1px solid color-mix(in srgb,var(--%NS%accent) 35%,transparent);border-radius:var(--%NS%radius-md);background:var(--%NS%accent-bg);display:grid;gap:4px}.outcome[data-kind=refusal][_ngcontent-%COMP%]{border-color:color-mix(in srgb,var(--%NS%warn) 45%,transparent);background:var(--%NS%warn-bg)}.outcome__title[_ngcontent-%COMP%]{margin:0;font-size:var(--%NS%font-xs);font-weight:600;color:var(--%NS%accent);display:inline-flex;align-items:center;gap:6px}.btn--mini[_ngcontent-%COMP%]{padding:2px var(--%NS%space-2);font-size:var(--%NS%font-xs);gap:4px}.outcome__cmd[_ngcontent-%COMP%]{font-size:var(--%NS%font-sm);word-break:break-all}.refusal[_ngcontent-%COMP%]{margin:0;color:var(--%NS%warn)}.unverified-panel[_ngcontent-%COMP%]{display:flex;gap:var(--%NS%space-3)}.capability[_ngcontent-%COMP%]{list-style:none;padding:0;margin:0;display:grid;gap:var(--%NS%space-2)}.capability[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--%NS%space-3);padding:var(--%NS%space-3);border:1px dashed var(--%NS%border);border-radius:var(--%NS%radius-md)}.capability__body[_ngcontent-%COMP%]{display:grid;gap:2px}`]})};export{Y as HostsPage};
@@ -0,0 +1 @@
1
+ import{$ as ah,At as sl,Bt as zr,Et as pl,G as XI,It as yg,K as YI,Lt as yh,Nt as vh,O as LD,P as Qu,Rt as zI,U as Vv,_ as FD,c as $i,dt as hg,g as Eg,gt as jI,jt as uh,kt as sh,l as AD,m as DD,q as Yu,r as g$1,s as $I,st as g,t as Nt,vt as kD,xt as ml,y as HI,yt as ki}from"./main-QDFVZK3T.js";import{a as l,o as w,s as y}from"./chunk-DQU0VyoQ.js";import{t as h}from"./chunk-DqWNkF1O.js";import{t as _}from"./chunk-BaQMhq-G.js";import{t as w$1}from"./chunk-BVKnCv85.js";import{t as I}from"./chunk-DyIHOW_a.js";import{t as _$1}from"./chunk-C4gpbtbP.js";var J=e=>({time:e});var K=e=>[`/forges`,e];var Q=(e,o)=>o.id;function W(e,o){if(e&1&&(ki(0,`span`),DD(1),kD(2,`t`),pl()),e&2){let i=XI();Vv(),ml(` · `,FD(2,1,`common.updatedAt`,AD(4,J,i.stamp(o))))}}function X(e,o){if(e&1&&(ki(0,`p`,5)(1,`span`),DD(2),kD(3,`t`),pl(),ki(4,`span`),DD(5),kD(6,`t`),pl(),ki(7,`span`),DD(8),kD(9,`t`),pl(),ki(10,`span`),DD(11),kD(12,`t`),pl()()),e&2){let i=o;Vv(2),vh(``,LD(3,8,`federation.catalog`),`: `,i.summary.catalog),Vv(3),vh(``,LD(6,10,`federation.installed`),`: `,i.summary.installed),Vv(3),vh(``,LD(9,12,`federation.mcp`),`: `,i.summary.with_mcp),Vv(3),vh(``,LD(12,14,`federation.checkouts`),`: `,i.summary.with_checkout)}}function Y(e,o){e&1&&(ki(0,`div`,6),ah(1,`ui-state-badge`,11),ki(2,`span`),DD(3),kD(4,`t`),pl()()),e&2&&(Vv(3),yh(LD(4,1,`federation.unavailable`)))}function Z(e,o){if(e&1){let i=YI();ki(0,`ui-error`,12),uh(`retry`,function(){Yu(i);let x=XI();return Qu(x.load())}),pl()}e&2&&sh(`error`,o)}function ee(e,o){e&1&&(ki(0,`div`,8),kD(1,`t`),ah(2,`ui-skeleton`,13),pl()),e&2&&($i(`aria-label`,LD(1,2,`state.loading`)),Vv(2),sh(`lines`,4))}function te(e,o){e&1&&ah(0,`ui-icon`,17),e&2&&sh(`size`,15)}function ie(e,o){e&1&&(ki(0,`span`,20),DD(1),kD(2,`t`),pl()),e&2&&(Vv(),yh(LD(2,1,`explorer.serving`)))}function ne(e,o){e&1&&(ki(0,`span`,21),DD(1),kD(2,`t`),pl()),e&2&&(Vv(),yh(LD(2,1,`explorer.registryOnly`)))}function ae(e,o){e&1&&ah(0,`ui-state-badge`,11)}function oe(e,o){e&1&&(ki(0,`span`,23),DD(1),kD(2,`t`),pl()),e&2&&(Vv(),yh(LD(2,1,`state.absent`)))}function re(e,o){if(e&1&&(ki(0,`code`,24),DD(1),pl()),e&2){let i=XI().$implicit;$i(`title`,i.checkout),Vv(),yh(i.checkout)}}function le(e,o){e&1&&ah(0,`ui-state-badge`,11)}function pe(e,o){if(e&1&&(ki(0,`span`,23),DD(1),kD(2,`t`),pl()),e&2){let i=XI().$implicit;Vv(),yh(LD(2,1,i.mcp===null?`federation.mcpAbsent`:`federation.mcpReady`))}}function de(e,o){if(e&1&&(ki(0,`tr`)(1,`td`)(2,`div`,16),jI(3,te,1,1,`ui-icon`,17),ki(4,`div`,18)(5,`strong`),DD(6),pl(),ki(7,`code`,19),DD(8),pl()(),jI(9,ie,3,3,`span`,20),jI(10,ne,3,3,`span`,21),pl()(),ki(11,`td`),ah(12,`ui-state-badge`,22),pl(),ki(13,`td`),DD(14),pl(),ki(15,`td`),jI(16,ae,1,0,`ui-state-badge`,11)(17,oe,3,3,`span`,23)(18,re,2,2,`code`,24),pl(),ki(19,`td`),jI(20,le,1,0,`ui-state-badge`,11)(21,pe,3,3,`span`,23),pl(),ki(22,`td`)(23,`a`,25),kD(24,`t`),ah(25,`ui-icon`,26),pl()()()),e&2){let i=o.$implicit;$i(`data-serving`,i.serving||null),Vv(3),HI(i.serving?3:-1),Vv(3),yh(i.name??i.id),Vv(2),yh(i.id),Vv(),HI(i.serving?9:-1),Vv(),HI(i.registryOnly?10:-1),Vv(2),sh(`state`,i.state??`UNVERIFIED`),Vv(2),yh(i.version??`—`),Vv(2),HI(i.checkout===void 0?16:i.checkout===null?17:18),Vv(4),HI(i.mcp===void 0?20:21),Vv(3),sh(`routerLink`,AD(15,K,i.id)),$i(`aria-label`,LD(24,13,`state.viewDetails`)),Vv(2),sh(`size`,15)}}function ce(e,o){if(e&1&&(ki(0,`div`,9)(1,`table`,14)(2,`thead`)(3,`tr`)(4,`th`),DD(5),kD(6,`t`),pl(),ki(7,`th`),DD(8),kD(9,`t`),pl(),ki(10,`th`),DD(11),kD(12,`t`),pl(),ki(13,`th`),DD(14),kD(15,`t`),pl(),ki(16,`th`),DD(17),kD(18,`t`),pl(),ki(19,`th`)(20,`span`,15),DD(21),kD(22,`t`),pl()()()(),ki(23,`tbody`),$I(24,de,26,17,`tr`,null,Q),pl()()()),e&2){let i=XI();Vv(5),yh(LD(6,6,`table.id`)),Vv(3),yh(LD(9,8,`skills.state`)),Vv(3),yh(LD(12,10,`settings.version`)),Vv(3),yh(LD(15,12,`explorer.checkout`)),Vv(3),yh(LD(18,14,`mcp.title`)),Vv(4),yh(LD(22,16,`state.viewDetails`)),Vv(3),zI(i.rows())}}function me(e,o){e&1&&(ah(0,`ui-empty`,10),kD(1,`t`)),e&2&&sh(`title`,LD(1,1,`explorer.empty`))}var q=class e{api=g(hg);store=g(g$1);fed=new l;rows=zr(()=>w(this.store.descriptor(),this.store.health(),this.fed.data()));stamp=y;constructor(){this.load()}async load(){await Promise.allSettled([this.store.refreshHealth(),this.fed.load(()=>this.api.federation())])}static ɵfac=function(i){return new(i||e)};static ɵcmp=sl({type:e,selectors:[[`page-explorer`]],decls:18,vars:16,consts:[[3,`title`,`subtitle`],[1,`btn`,3,`click`],[`name`,`refresh`,3,`size`],[`data-section`,`forges`,1,`card`],[1,`src`],[1,`sum`],[`role`,`note`,1,`unv`],[3,`error`],[`role`,`status`],[1,`table-wrap`],[`icon`,`network`,3,`title`],[`state`,`UNVERIFIED`],[3,`retry`,`error`],[`kind`,`row`,3,`lines`],[1,`table`],[1,`sr-only`],[1,`id`],[`name`,`gem`,3,`size`],[1,`id__text`],[1,`id__slug`],[1,`chip`],[1,`chip`,`chip--mut`],[3,`state`],[1,`muted`],[1,`path`],[1,`icon-btn`,3,`routerLink`],[`name`,`chevron-right`,3,`size`]],template:function(i,c){if(i&1&&(ki(0,`ui-page-header`,0),kD(1,`t`),kD(2,`t`),ki(3,`button`,1),uh(`click`,function(){return c.load()}),ah(4,`ui-icon`,2),DD(5),kD(6,`t`),pl()(),ki(7,`section`,3)(8,`p`,4)(9,`code`),DD(10,`bootstrap · GET /api/v1/federation`),pl(),jI(11,W,3,6,`span`),pl(),jI(12,X,13,16,`p`,5),jI(13,Y,5,3,`div`,6),jI(14,Z,1,1,`ui-error`,7),jI(15,ee,3,4,`div`,8),jI(16,ce,26,18,`div`,9)(17,me,2,3,`ui-empty`,10),pl()),i&2){let x,E,h;sh(`title`,LD(1,10,`explorer.title`))(`subtitle`,LD(2,12,`explorer.subtitle`)),Vv(4),sh(`size`,15),Vv(),ml(` `,LD(6,14,`state.refresh`),` `),Vv(6),HI((x=c.fed.loadedAt())?11:-1,x),Vv(),HI((E=c.fed.data())?12:-1,E),Vv(),HI(c.fed.unavailable()?13:-1),Vv(),HI((h=c.fed.error())?14:-1,h),Vv(),HI(c.fed.loading()&&!c.fed.data()?15:-1),Vv(),HI(c.rows().length?16:c.fed.attempted()&&!c.fed.loading()&&!c.fed.error()&&!c.fed.unavailable()?17:-1)}},dependencies:[Nt,_$1,I,_,w$1,Eg,h,yg],styles:[`.card[_ngcontent-%COMP%]{padding:var(--%NS%space-3)}.src[_ngcontent-%COMP%]{margin:0 0 var(--%NS%space-2);padding:0 var(--%NS%space-2);font-size:var(--%NS%font-xs);color:var(--%NS%fg-muted)}.sum[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:var(--%NS%space-2) var(--%NS%space-4);margin:0 0 var(--%NS%space-3);padding:0 var(--%NS%space-2);font-size:var(--%NS%font-xs);color:var(--%NS%fg-muted)}.unv[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--%NS%space-3);padding:var(--%NS%space-3);margin:0 var(--%NS%space-2) var(--%NS%space-3);border:1px dashed color-mix(in srgb,var(--%NS%warn) 55%,transparent);border-radius:var(--%NS%radius-md);background:var(--%NS%warn-bg);font-size:var(--%NS%font-sm)}.table-wrap[_ngcontent-%COMP%]{overflow-x:auto}.table[_ngcontent-%COMP%]{min-width:640px}.id[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--%NS%space-2);min-width:0}.id[_ngcontent-%COMP%] ui-icon[_ngcontent-%COMP%]{color:var(--%NS%accent);flex:none}.id__text[_ngcontent-%COMP%]{display:grid;min-width:0}.id__slug[_ngcontent-%COMP%]{color:var(--%NS%fg-muted);font-size:var(--%NS%font-xs);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.chip[_ngcontent-%COMP%]{flex:none;font-size:var(--%NS%font-xs);font-weight:700;color:var(--%NS%accent);background:var(--%NS%accent-bg);border-radius:var(--%NS%radius-pill);padding:1px 8px}.chip--mut[_ngcontent-%COMP%]{color:var(--%NS%fg-muted);background:var(--%NS%bg-hover)}.muted[_ngcontent-%COMP%]{color:var(--%NS%fg-muted)}.path[_ngcontent-%COMP%]{display:inline-block;max-width:38ch;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:bottom}`]})};export{q as ExplorerPage};
@@ -0,0 +1 @@
1
+ import{$ as ah,At as sl,B as Te,Et as pl,G as XI,It as yg,K as YI,Lt as yh,O as LD,P as Qu,Rt as zI,U as Vv,V as Tg,Z as _E,_ as FD,_t as jn,dt as hg,f as CE,g as Eg,gt as jI,jt as uh,kt as sh,l as AD,m as DD,q as Yu,s as $I,st as g,vt as kD,xt as ml,y as HI,yt as ki}from"./main-QDFVZK3T.js";import{t as _}from"./chunk-BaQMhq-G.js";import{t as w}from"./chunk-BVKnCv85.js";import{t as _$1}from"./chunk-C4gpbtbP.js";import{i as Zt,n as De,r as Yt,t as At}from"./chunk-kXRFMGqe.js";var G=e=>({count:e});var J=(e,i)=>i.path;function L(e,i){if(e&1){let n=YI();ki(0,`ui-error`,9),uh(`retry`,function(){Yu(n);let c=XI();return Qu(c.search())}),pl()}e&2&&sh(`error`,i)}function Q(e,i){if(e&1&&(ki(0,`article`,11)(1,`h2`),DD(2),pl(),ki(3,`p`,10),DD(4),pl(),ki(5,`footer`)(6,`code`),DD(7),pl(),ki(8,`span`,13),DD(9),pl()()()),e&2){let n=i.$implicit;Vv(2),yh(n.title),Vv(2),yh(n.excerpt),Vv(3),yh(n.path),Vv(2),yh(n.category)}}function R(e,i){e&1&&(ah(0,`ui-empty`,12),kD(1,`t`)),e&2&&sh(`title`,LD(1,1,`knowledge.empty`))}function W(e,i){if(e&1&&(ki(0,`p`,10),DD(1),kD(2,`t`),pl(),$I(3,Q,10,4,`article`,11,J,!1,R,2,3,`ui-empty`,12)),e&2){let n=XI();Vv(),yh(FD(2,2,`knowledge.results`,AD(5,G,n.hits().length))),Vv(2),zI(n.hits())}}var $=class e{api=g(hg);query=Te(``);hits=Te([]);searched=Te(!1);error=Te(null);busy=Te(!1);async search(){if(this.query().trim()){this.busy.set(!0),this.error.set(null);try{this.hits.set(await Tg(this.api.docsSearch(this.query()))),this.searched.set(!0)}catch(i){this.error.set(i instanceof jn?i:new jn(0))}finally{this.busy.set(!1)}}}static ɵfac=function(n){return new(n||e)};static ɵcmp=sl({type:e,selectors:[[`page-knowledge`]],decls:18,vars:21,consts:[[3,`title`,`subtitle`],[1,`card`],[`for`,`q`,1,`lbl`],[1,`row`],[1,`search-field`,`q-field`],[`name`,`search`,3,`size`],[`id`,`q`,`type`,`search`,1,`input`,3,`ngModelChange`,`keydown.enter`,`placeholder`,`ngModel`],[1,`btn`,`btn--primary`,3,`click`,`disabled`],[3,`error`],[3,`retry`,`error`],[1,`muted`],[`data-lift`,``,1,`card`,`hit`],[`icon`,`knowledge`,3,`title`],[1,`cat`]],template:function(n,o){if(n&1&&(ah(0,`ui-page-header`,0),kD(1,`t`),kD(2,`t`),ki(3,`section`,1)(4,`label`,2),DD(5),kD(6,`t`),pl(),ki(7,`div`,3)(8,`div`,4),ah(9,`ui-icon`,5),ki(10,`input`,6),kD(11,`t`),CE(),uh(`ngModelChange`,function(U){return o.query.set(U)})(`keydown.enter`,function(){return o.search()}),pl()(),ki(12,`button`,7),uh(`click`,function(){return o.search()}),ah(13,`ui-icon`,5),DD(14),kD(15,`t`),pl()()(),jI(16,L,1,1,`ui-error`,8),jI(17,W,6,7)),n&2){let c;sh(`title`,LD(1,11,`knowledge.title`))(`subtitle`,LD(2,13,`knowledge.subtitle`)),Vv(5),yh(LD(6,15,`knowledge.search`)),Vv(4),sh(`size`,15),Vv(),sh(`placeholder`,LD(11,17,`knowledge.placeholder`))(`ngModel`,o.query()),_E(),Vv(2),sh(`disabled`,o.busy()||!o.query().trim()),Vv(),sh(`size`,14),Vv(),ml(` `,LD(15,19,`knowledge.search`),` `),Vv(2),HI((c=o.error())?16:-1,c),Vv(),HI(o.searched()?17:-1)}},dependencies:[Zt,De,Yt,At,_$1,_,w,Eg,yg],styles:[`.card[_ngcontent-%COMP%]{margin-bottom:var(--%NS%space-4)}.lbl[_ngcontent-%COMP%]{display:block;font-weight:600;margin-bottom:var(--%NS%space-2)}.row[_ngcontent-%COMP%]{display:flex;gap:var(--%NS%space-2)}.q-field[_ngcontent-%COMP%]{flex:1;max-width:none;margin-bottom:0}.hit[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0 0 6px;font-size:var(--%NS%font-lg);font-weight:650;letter-spacing:-.01em}.hit[_ngcontent-%COMP%] footer[_ngcontent-%COMP%]{display:flex;justify-content:space-between;gap:var(--%NS%space-2);margin-top:var(--%NS%space-3);font-size:var(--%NS%font-xs)}.hit[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{color:var(--%NS%fg-muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.cat[_ngcontent-%COMP%]{color:var(--%NS%accent);font-weight:600;flex-shrink:0;background:var(--%NS%accent-bg);border:1px solid color-mix(in srgb,var(--%NS%accent) 30%,transparent);border-radius:var(--%NS%radius-pill);padding:1px var(--%NS%space-2)}.muted[_ngcontent-%COMP%]{color:var(--%NS%fg-muted)}`]})};export{$ as KnowledgePage};
@@ -0,0 +1 @@
1
+ import{A as NL,B as Te$1,Bt as zr,C as If,D as K$1,Ft as yd,Ht as l,J as Zg,L as SI,M as Or,N as Qe$1,Ot as ry,Pt as xD,Q as _L,S as Ie$1,St as nh,Tt as ot$1,Vt as k,W as Wr,at as ee,b as He$1,bt as ko,c as $i,ct as gh,et as al,ht as il,j as Oo,jt as uh,nt as bI,ot as fc,st as g$1,tt as b$1,ut as he$1,wt as oe,x as Hr}from"./main-QDFVZK3T.js";var Ce=(()=>{class n{_renderer;_elementRef;onChange=t=>{};onTouched=()=>{};constructor(t,r){this._renderer=t,this._elementRef=r}setProperty(t,r){this._renderer.setProperty(this._elementRef.nativeElement,t,r)}registerOnTouched(t){this.onTouched=t}registerOnChange(t){this.onChange=t}setDisabledState(t){this.setProperty(`disabled`,t)}static ɵfac=function(r){return new(r||n)(Hr(fc),Hr(Or))};static ɵdir=bI({type:n})}return n})();var Le=(()=>{class n extends Ce{static ɵfac=(()=>{let t;return function(i){return(t||(t=If(n)))(i||n)}})();static ɵdir=bI({type:n,features:[nh]})}return n})();var Ve=new b$1(``);var Be={provide:Ve,useExisting:Oo(()=>De),multi:!0};function Ue(){let n=Qe$1()?Qe$1().getUserAgent():``;return/android (\d+)/.test(n.toLowerCase())}var He=new b$1(``);var De=(()=>{class n extends Ce{_compositionMode;_composing=!1;constructor(t,r,i){super(t,r),this._compositionMode=i,this._compositionMode??=!Ue()}writeValue(t){let r=t??``;this.setProperty(`value`,r)}_handleInput(t){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(t)}_compositionStart(){this._composing=!0}_compositionEnd(t){this._composing=!1,this._compositionMode&&this.onChange(t)}static ɵfac=function(r){return new(r||n)(Hr(fc),Hr(Or),Hr(He,8))};static ɵdir=bI({type:n,selectors:[[`input`,`formControlName`,``,3,`type`,`checkbox`,3,`ngNoCva`,``],[`textarea`,`formControlName`,``,3,`ngNoCva`,``],[`input`,`formControl`,``,3,`type`,`checkbox`,3,`ngNoCva`,``],[`textarea`,`formControl`,``,3,`ngNoCva`,``],[`input`,`ngModel`,``,3,`type`,`checkbox`,3,`ngNoCva`,``],[`textarea`,`ngModel`,``,3,`ngNoCva`,``],[``,`ngDefaultControl`,``]],hostBindings:function(r,i){r&1&&uh(`input`,function(l){return i._handleInput(l.target.value)})(`blur`,function(){return i.onTouched()})(`compositionstart`,function(){return i._compositionStart()})(`compositionend`,function(l){return i._compositionEnd(l.target.value)})},standalone:!1,features:[xD([Be]),nh]})}return n})();function X(n){return n==null||Z(n)===0}function Z(n){return n==null?null:Array.isArray(n)||typeof n==`string`?n.length:n instanceof Set?n.size:null}var Ae=new b$1(``);var $e=new b$1(``);var qe=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;var H=class{static min(e){return We(e)}static max(e){return ze(e)}static required(e){return be(e)}static requiredTrue(e){return Ye(e)}static email(e){return Xe(e)}static minLength(e){return Ze(e)}static maxLength(e){return Ke(e)}static pattern(e){return Qe(e)}static nullValidator(e){return O()}static compose(e){return Fe(e)}static composeAsync(e){return we(e)}};function We(n){return e=>{if(e.value==null||n==null)return null;let t=parseFloat(e.value);return!isNaN(t)&&t<n?{min:{min:n,actual:e.value}}:null}}function ze(n){return e=>{if(e.value==null||n==null)return null;let t=parseFloat(e.value);return!isNaN(t)&&t>n?{max:{max:n,actual:e.value}}:null}}function be(n){return X(n.value)?{required:!0}:null}function Ye(n){return n.value===!0?null:{required:!0}}function Xe(n){return X(n.value)||qe.test(n.value)?null:{email:!0}}function Ze(n){return e=>{let t=e.value?.length??Z(e.value);return t===null||t===0?null:t<n?{minlength:{requiredLength:n,actualLength:t}}:null}}function Ke(n){return e=>{let t=e.value?.length??Z(e.value);return t!==null&&t>n?{maxlength:{requiredLength:n,actualLength:t}}:null}}function Qe(n){if(!n)return O;let e,t;return typeof n==`string`?(t=``,n.charAt(0)!==`^`&&(t+=`^`),t+=n,n.charAt(n.length-1)!==`$`&&(t+=`$`),e=new RegExp(t)):(t=n.toString(),e=n),r=>{if(X(r.value))return null;let i=r.value;return e.test(i)?null:{pattern:{requiredPattern:t,actualValue:i}}}}function O(n){return null}function Me(n){return n!=null}function Ee(n){return il(n)?ot$1(n):n}function Ne(n){let e={};return n.forEach(t=>{e=t!=null?k(k({},e),t):e}),Object.keys(e).length===0?null:e}function Ie(n,e){return e.map(t=>t(n))}function Je(n){return!n.validate}function Se(n){return n.map(e=>Je(e)?e:t=>e.validate(t))}function Fe(n){if(!n)return null;let e=n.filter(Me);return e.length==0?null:function(t){return Ne(Ie(t,e))}}function Oe(n){return n!=null?Fe(Se(n)):null}function we(n){if(!n)return null;let e=n.filter(Me);return e.length==0?null:function(t){let r=Ie(t,e).map(Ee);return Zg(r).pipe(K$1(Ne))}}function Re(n){return n!=null?we(Se(n)):null}function he(n,e){return n===null?[e]:Array.isArray(n)?[...n,e]:[n,e]}function et(n){return n._rawValidators}function tt(n){return n._rawAsyncValidators}function $(n){return n?Array.isArray(n)?n:[n]:[]}function w(n,e){return Array.isArray(n)?n.includes(e):n===e}function pe(n,e){let t=$(e);return $(n).forEach(i=>{w(t,i)||t.push(i)}),t}function fe(n,e){return $(e).filter(t=>!w(n,t))}var R=class{get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators=[];_rawAsyncValidators=[];_setValidators(e){this._rawValidators=e||[],this._composedValidatorFn=Oe(this._rawValidators)}_setAsyncValidators(e){this._rawAsyncValidators=e||[],this._composedAsyncValidatorFn=Re(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_onDestroyCallbacks=[];_registerOnDestroy(e){this._onDestroyCallbacks.push(e)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(e=>e()),this._onDestroyCallbacks=[]}reset(e=void 0){this.control?.reset(e)}hasError(e,t){return this.control?this.control.hasError(e,t):!1}getError(e,t){return this.control?this.control.getError(e,t):null}};var q=class extends R{name;get formDirective(){return null}get path(){return null}};var C=`VALID`;var F=`INVALID`;var g=`PENDING`;var V=`DISABLED`;var p=class{};var x=class extends p{value;source;constructor(e,t){super(),this.value=e,this.source=t}};var D=class extends p{pristine;source;constructor(e,t){super(),this.pristine=e,this.source=t}};var A=class extends p{touched;source;constructor(e,t){super(),this.touched=e,this.source=t}};var m=class extends p{status;source;constructor(e,t){super(),this.status=e,this.source=t}};var b=class extends p{source;constructor(e){super(),this.source=e}};function nt(n){return(T(n)?n.validators:n)||null}function rt(n){return Array.isArray(n)?Oe(n):n||null}function it(n,e){return(T(e)?e.asyncValidators:n)||null}function ot(n){return Array.isArray(n)?Re(n):n||null}function T(n){return n!=null&&!Array.isArray(n)&&typeof n==`object`}var W=class{_pendingDirty=!1;_hasOwnPendingAsyncValidator=null;_pendingTouched=!1;_onCollectionChange=()=>{};_updateOn;_hasRequired=Te$1(!1);_parent=null;_asyncValidationSubscription;_composedValidatorFn;_composedAsyncValidatorFn;_rawValidators;_rawAsyncValidators;value;constructor(e,t){this._assignValidators(e),this._assignAsyncValidators(t)}get validator(){return this._composedValidatorFn}set validator(e){this._rawValidators=this._composedValidatorFn=e,this._updateHasRequiredValidator()}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(e){this._rawAsyncValidators=this._composedAsyncValidatorFn=e}get parent(){return this._parent}get status(){return Wr(this.statusReactive)}set status(e){Wr(()=>this.statusReactive.set(e))}_status=zr(()=>this.statusReactive());statusReactive=Te$1(void 0);get valid(){return this.status===C}get invalid(){return this.status===F}get pending(){return this.status===g}get disabled(){return this.status===V}get enabled(){return this.status!==V}errors;get pristine(){return Wr(this.pristineReactive)}set pristine(e){Wr(()=>this.pristineReactive.set(e))}_pristine=zr(()=>this.pristineReactive());pristineReactive=Te$1(!0);get dirty(){return!this.pristine}get touched(){return Wr(this.touchedReactive)}set touched(e){Wr(()=>this.touchedReactive.set(e))}_touched=zr(()=>this.touchedReactive());touchedReactive=Te$1(!1);get untouched(){return!this.touched}_events=new oe;events=this._events.asObservable();valueChanges;statusChanges;get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:`change`}setValidators(e){this._assignValidators(e)}setAsyncValidators(e){this._assignAsyncValidators(e)}addValidators(e){this.setValidators(pe(e,this._rawValidators))}addAsyncValidators(e){this.setAsyncValidators(pe(e,this._rawAsyncValidators))}removeValidators(e){this.setValidators(fe(e,this._rawValidators))}removeAsyncValidators(e){this.setAsyncValidators(fe(e,this._rawAsyncValidators))}hasValidator(e){return w(this._rawValidators,e)}hasAsyncValidator(e){return w(this._rawAsyncValidators,e)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(e={}){let t=this.touched===!1;this.touched=!0;let r=e.sourceControl??this;e.onlySelf||this._parent?.markAsTouched(l(k({},e),{sourceControl:r})),t&&e.emitEvent!==!1&&this._events.next(new A(!0,r))}markAllAsDirty(e={}){this.markAsDirty({onlySelf:!0,emitEvent:e.emitEvent,sourceControl:this}),this._forEachChild(t=>t.markAllAsDirty(e))}markAllAsTouched(e={}){this.markAsTouched({onlySelf:!0,emitEvent:e.emitEvent,sourceControl:this}),this._forEachChild(t=>t.markAllAsTouched(e))}markAsUntouched(e={}){let t=this.touched===!0;this.touched=!1,this._pendingTouched=!1;let r=e.sourceControl??this;this._forEachChild(i=>{i.markAsUntouched({onlySelf:!0,emitEvent:e.emitEvent,sourceControl:r})}),e.onlySelf||this._parent?._updateTouched(e,r),t&&e.emitEvent!==!1&&this._events.next(new A(!1,r))}markAsDirty(e={}){let t=this.pristine===!0;this.pristine=!1;let r=e.sourceControl??this;e.onlySelf||this._parent?.markAsDirty(l(k({},e),{sourceControl:r})),t&&e.emitEvent!==!1&&this._events.next(new D(!1,r))}markAsPristine(e={}){let t=this.pristine===!1;this.pristine=!0,this._pendingDirty=!1;let r=e.sourceControl??this;this._forEachChild(i=>{i.markAsPristine({onlySelf:!0,emitEvent:e.emitEvent})}),e.onlySelf||this._parent?._updatePristine(e,r),t&&e.emitEvent!==!1&&this._events.next(new D(!0,r))}markAsPending(e={}){this.status=g;let t=e.sourceControl??this;e.emitEvent!==!1&&(this._events.next(new m(this.status,t)),this.statusChanges.emit(this.status)),e.onlySelf||this._parent?.markAsPending(l(k({},e),{sourceControl:t}))}disable(e={}){let t=this._parentMarkedDirty(e.onlySelf);this.status=V,this.errors=null,this._forEachChild(i=>{i.disable(l(k({},e),{onlySelf:!0}))}),this._updateValue();let r=e.sourceControl??this;e.emitEvent!==!1&&(this._events.next(new x(this.value,r)),this._events.next(new m(this.status,r)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(l(k({},e),{skipPristineCheck:t}),this),this._onDisabledChange.forEach(i=>i(!0))}enable(e={}){let t=this._parentMarkedDirty(e.onlySelf);this.status=C,this._forEachChild(r=>{r.enable(l(k({},e),{onlySelf:!0}))}),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent}),this._updateAncestors(l(k({},e),{skipPristineCheck:t}),this),this._onDisabledChange.forEach(r=>r(!1))}_updateAncestors(e,t){e.onlySelf||(this._parent?.updateValueAndValidity(e),e.skipPristineCheck||this._parent?._updatePristine({},t),this._parent?._updateTouched({},t))}setParent(e){this._parent=e}getRawValue(){return this.value}updateValueAndValidity(e={}){if(this._setInitialStatus(),this._updateValue(),this.enabled){let r=this._cancelExistingSubscription();this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===C||this.status===g)&&this._runAsyncValidator(r,e.emitEvent)}let t=e.sourceControl??this;e.emitEvent!==!1&&(this._events.next(new x(this.value,t)),this._events.next(new m(this.status,t)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),e.onlySelf||this._parent?.updateValueAndValidity(l(k({},e),{sourceControl:t}))}_updateTreeValidity(e={emitEvent:!0}){this._forEachChild(t=>t._updateTreeValidity(e)),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?V:C}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(e,t){if(this.asyncValidator){this.status=g,this._hasOwnPendingAsyncValidator={emitEvent:t!==!1,shouldHaveEmitted:e!==!1};let r=Ee(this.asyncValidator(this));this._asyncValidationSubscription=r.subscribe(i=>{this._hasOwnPendingAsyncValidator=null,this.setErrors(i,{emitEvent:t,shouldHaveEmitted:e})})}}_cancelExistingSubscription(){if(this._asyncValidationSubscription){this._asyncValidationSubscription.unsubscribe();let e=(this._hasOwnPendingAsyncValidator?.emitEvent||this._hasOwnPendingAsyncValidator?.shouldHaveEmitted)??!1;return this._hasOwnPendingAsyncValidator=null,e}return!1}setErrors(e,t={}){this.errors=e,this._updateControlsErrors(t.emitEvent!==!1,this,t.shouldHaveEmitted)}get(e){let t=e;return t==null||(Array.isArray(t)||(t=t.split(`.`)),t.length===0)?null:t.reduce((r,i)=>r&&r._find(i),this)}getError(e,t){let r=t?this.get(t):this;return r?.errors?r.errors[e]:null}hasError(e,t){return!!this.getError(e,t)}get root(){let e=this;for(;e._parent;)e=e._parent;return e}_updateControlsErrors(e,t,r){this.status=this._calculateStatus(),e&&this.statusChanges.emit(this.status),(e||r)&&this._events.next(new m(this.status,t)),this._parent&&this._parent._updateControlsErrors(e,t,r)}_initObservables(){this.valueChanges=new He$1,this.statusChanges=new He$1}_calculateStatus(){return this._allControlsDisabled()?V:this.errors?F:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(g)?g:this._anyControlsHaveStatus(F)?F:C}_anyControlsHaveStatus(e){return this._anyControls(t=>t.status===e)}_anyControlsDirty(){return this._anyControls(e=>e.dirty)}_anyControlsTouched(){return this._anyControls(e=>e.touched)}_updatePristine(e,t){let r=!this._anyControlsDirty(),i=this.pristine!==r;this.pristine=r,e.onlySelf||this._parent?._updatePristine(e,t),i&&this._events.next(new D(this.pristine,t))}_updateTouched(e={},t){this.touched=this._anyControlsTouched(),this._events.next(new A(this.touched,t)),e.onlySelf||this._parent?._updateTouched(e,t)}_onDisabledChange=[];_registerOnCollectionChange(e){this._onCollectionChange=e}_setUpdateStrategy(e){T(e)&&e.updateOn!=null&&(this._updateOn=e.updateOn)}_parentMarkedDirty(e){return!e&&!!this._parent?.dirty&&!this._parent._anyControlsDirty()}_find(e){return null}_assignValidators(e){this._rawValidators=Array.isArray(e)?e.slice():e,this._composedValidatorFn=rt(this._rawValidators),this._updateHasRequiredValidator()}_assignAsyncValidators(e){this._rawAsyncValidators=Array.isArray(e)?e.slice():e,this._composedAsyncValidatorFn=ot(this._rawAsyncValidators)}_updateHasRequiredValidator(){Wr(()=>this._hasRequired.set(this.hasValidator(H.required)))}};function st(n){return n.tagName===`INPUT`||n.tagName===`SELECT`||n.tagName===`TEXTAREA`}function at(n,e,t,r){switch(t){case`name`:n.setAttribute(e,t,r);break;case`disabled`:case`readonly`:case`required`:r?n.setAttribute(e,t,``):n.removeAttribute(e,t);break;case`max`:case`min`:case`minLength`:case`maxLength`:r!==void 0?n.setAttribute(e,t,r.toString()):n.removeAttribute(e,t)}}var z=class{kind;context;control;message;constructor({kind:e,context:t,control:r}){this.kind=e,this.context=t,this.control=r}};var lt=(()=>{class n{_validator=O;_onChange;_enabled;ngOnChanges(t){if(this.inputName in t){let r=this.normalizeInput(t[this.inputName].currentValue);this._enabled=this.enabled(r),this._validator=this._enabled?this.createValidator(r):O,this._onChange?.()}}validate(t){return this._validator(t)}registerOnValidatorChange(t){this._onChange=t}enabled(t){return t!=null}static ɵfac=function(r){return new(r||n)};static ɵdir=bI({type:n,features:[ry]})}return n})();var ut={provide:Ae,useExisting:Oo(()=>xe),multi:!0};var xe=(()=>{class n extends lt{required;inputName=`required`;normalizeInput=NL;createValidator=t=>be;enabled(t){return t}static ɵfac=(()=>{let t;return function(i){return(t||(t=If(n)))(i||n)}})();static ɵdir=bI({type:n,selectors:[[``,`required`,``,`formControlName`,``,3,`type`,`checkbox`],[``,`required`,``,`formControl`,``,3,`type`,`checkbox`],[``,`required`,``,`ngModel`,``,3,`type`,`checkbox`]],hostVars:1,hostBindings:function(r,i){r&2&&$i(`required`,i._enabled?``:null)},inputs:{required:`required`},standalone:!1,features:[xD([ut]),nh]})}return n})();var dt=new b$1(``);var Te=new b$1(``,{factory:()=>K});var K=`always`;function ct(n,e){return[...e.path,n]}function ge(n,e,t=K){pt(n,e),e.valueAccessor.writeValue(n.value),(n.disabled||t===`always`)&&e.valueAccessor.setDisabledState?.(n.disabled),ft(n,e),mt(n,e),gt(n,e),ht(n,e)}function me(n,e){n.forEach(t=>{t.registerOnValidatorChange&&t.registerOnValidatorChange(e)})}function ht(n,e){if(e.valueAccessor.setDisabledState){let t=r=>{e.valueAccessor.setDisabledState(r)};n.registerOnDisabledChange(t),e._registerOnDestroy(()=>{n._unregisterOnDisabledChange(t)})}}function pt(n,e){let t=et(n);e.validator!==null?n.setValidators(he(t,e.validator)):typeof t==`function`&&n.setValidators([t]);let r=tt(n);e.asyncValidator!==null?n.setAsyncValidators(he(r,e.asyncValidator)):typeof r==`function`&&n.setAsyncValidators([r]);let i=()=>n.updateValueAndValidity();me(e._rawValidators,i),me(e._rawAsyncValidators,i)}function ft(n,e){e.valueAccessor.registerOnChange(t=>{n._pendingValue=t,n._pendingChange=!0,n._pendingDirty=!0,n.updateOn===`change`&&Pe(n,e)})}function gt(n,e){e.valueAccessor.registerOnTouched(()=>{n._pendingTouched=!0,n.updateOn===`blur`&&n._pendingChange&&Pe(n,e),n.updateOn!==`submit`&&n.markAsTouched()})}function Pe(n,e){n._pendingDirty&&n.markAsDirty(),n.setValue(n._pendingValue,{emitModelToViewChange:!1}),e.viewToModelUpdate(n._pendingValue),n._pendingChange=!1}function mt(n,e){let t=(r,i)=>{e.valueAccessor.writeValue(r),i&&e.viewToModelUpdate(r)};n.registerOnChange(t),e._registerOnDestroy(()=>{n._unregisterOnChange(t)})}function yt(n,e){if(!Object.hasOwn(n,`model`))return!1;let t=n.model;return t.isFirstChange()?!0:!Object.is(e,t.currentValue)}function vt(n){return Object.getPrototypeOf(n.constructor)===Le}function _t(n,e){if(!e)return null;let t,r,i;return e.forEach(o=>{o.constructor===De?t=o:vt(o)?r=o:i=o}),i||r||t||null}var Ct={provide:dt,useFactory:()=>{let n=g$1(y,{self:!0});return{setParseErrors:e=>{n.setParseErrorSource(e)},set onReset(e){n.onReset=e}}}};var y=class extends R{_parent=null;name=null;valueAccessor=null;isCustomControlBased=!1;userOnReset;resetSubscription;set onReset(e){this.userOnReset=e,this.resetSubscription?.unsubscribe(),this.resetSubscription=void 0,this.control&&(this.resetSubscription=this.control.events.subscribe(t=>{t instanceof b&&this.control&&this.userOnReset?.(this.control.value)}),this.subscription?.add(this.resetSubscription))}isNativeFormElement=!1;rawValueAccessors;_selectedValueAccessor=null;get selectedValueAccessor(){return this._selectedValueAccessor??=_t(this,this.rawValueAccessors)}parseErrorsValidator=null;renderer;injector;requiredValidatorViaDi;subscription;customControlBindings=null;constructor(e,t,r){super(),this.injector=e,this.renderer=t,this.rawValueAccessors=r,this.injector?.get(he$1)?.onDestroy(()=>{this.removeParseErrorsValidator(this.control),this.subscription?.unsubscribe()})}setupCustomControl(){this.subscription?.unsubscribe();let e=this.injector?.get(_L);if(!this.control||!e)return;let t=e.markForCheck.bind(e);this.subscription=new ee,this.subscription.add(this.control.valueChanges.subscribe(t)),this.subscription.add(this.control.statusChanges.subscribe(t)),this.resetSubscription?.unsubscribe(),this.resetSubscription=void 0,this.userOnReset&&(this.resetSubscription=this.control.events.subscribe(r=>{r instanceof b&&this.control&&this.userOnReset?.(this.control.value)}),this.subscription.add(this.resetSubscription)),this.parseErrorsValidator&&this.control.addValidators(this.parseErrorsValidator)}ngControlCreate(e){!e.nativeElement.hasAttribute?.(`ngNoCva`)&&(this.rawValueAccessors&&this.rawValueAccessors.length>0||this.valueAccessor!==null)||!e.customControl||(this.isCustomControlBased=!0,e.listenToCustomControlModel(i=>{this.control?.markAsDirty(),this.control?.setValue(i,{emitModelToViewChange:!1}),this.viewToModelUpdate(i)}),e.listenToCustomControlOutput(`touch`,()=>{this.control?.markAsTouched()}),this.customControlBindings={},this.isNativeFormElement=st(e.nativeElement),this.requiredValidatorViaDi=this._rawValidators.find(i=>i instanceof xe))}ngControlUpdate(e,t){if(!this.isCustomControlBased)return;let r=this.control,i=this.customControlBindings;Object.is(i.value,r.value)||(i.value=r.value,e.setCustomControlModelInput(r.value)),this.bindControlProperty(e,i,`touched`,r.touched),this.bindControlProperty(e,i,`dirty`,r.dirty),this.bindControlProperty(e,i,`valid`,r.valid),this.bindControlProperty(e,i,`invalid`,r.invalid),this.bindControlProperty(e,i,`pending`,r.pending),this.bindControlProperty(e,i,`disabled`,r.disabled),this.shouldBindRequired&&this.bindControlProperty(e,i,`required`,this.isRequired);let o=r.errors;if(i.errors!==o){i.errors=o;let l=this._convertErrors(o);e.setInputOnDirectives(`errors`,l)}}get isRequired(){return(this.requiredValidatorViaDi?._enabled||this.control?._hasRequired())??!1}get shouldBindRequired(){return!0}bindControlProperty(e,t,r,i){if(t[r]===i)return;t[r]=i;let o=e.setInputOnDirectives(r,i);this.isNativeFormElement&&!o&&(r===`disabled`||r===`required`)&&this.renderer&&at(this.renderer,e.nativeElement,r,i)}_convertErrors(e){if(e===null)return[];let t=this.control;return Object.entries(e).map(([r,i])=>new z({context:i,kind:r,control:t}))}setParseErrorSource(e){if(e===void 0)return;let t=null,r=zr(()=>{let i=e();return i.length===0?null:i.reduce((o,l)=>(o[l.kind]=l,o),{})});this.parseErrorsValidator=(()=>t).bind(this),yd(()=>{t=r(),this.control?.updateValueAndValidity({emitEvent:!1})},{injector:this.injector})}removeParseErrorsValidator(e){this.parseErrorsValidator&&(e?.removeValidators(this.parseErrorsValidator),e?.updateValueAndValidity({emitEvent:!1}))}};var Y=class{_cd;constructor(e){this._cd=e}get isTouched(){return this._cd?.control?._touched?.(),!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return this._cd?.control?._pristine?.(),!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return this._cd?.control?._status?.(),!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return this._cd?._submitted?.(),!!this._cd?.submitted}};var Yt=(()=>{class n extends Y{constructor(t){super(t)}static ɵfac=function(r){return new(r||n)(Hr(y,2))};static ɵdir=bI({type:n,selectors:[[``,`formControlName`,``],[``,`ngModel`,``],[``,`formControl`,``]],hostVars:14,hostBindings:function(r,i){r&2&&gh(`ng-untouched`,i.isUntouched)(`ng-touched`,i.isTouched)(`ng-pristine`,i.isPristine)(`ng-dirty`,i.isDirty)(`ng-valid`,i.isValid)(`ng-invalid`,i.isInvalid)(`ng-pending`,i.isPending)},standalone:!1,features:[nh]})}return n})();function ye(n,e){let t=n.indexOf(e);t>-1&&n.splice(t,1)}function ve(n){return typeof n==`object`&&n!==null&&Object.keys(n).length===2&&`value`in n&&`disabled`in n}var Vt=class extends W{defaultValue=null;_onChange=[];_pendingValue;_pendingChange=!1;constructor(e=null,t,r){super(nt(t),it(r,t)),this._applyFormState(e),this._setUpdateStrategy(t),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),T(t)&&(t.nonNullable||t.initialValueIsDefault)&&(ve(e)?this.defaultValue=e.value:this.defaultValue=e)}setValue(e,t={}){Wr(()=>{this.value=this._pendingValue=e,this._onChange.length&&t.emitModelToViewChange!==!1&&this._onChange.forEach(r=>r(this.value,t.emitViewToModelChange!==!1)),this.updateValueAndValidity(t)})}patchValue(e,t={}){this.setValue(e,t)}reset(e=this.defaultValue,t={}){this._applyFormState(e),this.markAsPristine(t),this.markAsUntouched(t),this.setValue(this.value,t),t.overwriteDefaultValue&&(this.defaultValue=this.value),this._pendingChange=!1,t?.emitEvent!==!1&&this._events.next(new b(this))}_updateValue(){}_anyControls(e){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(e){this._onChange.push(e)}_unregisterOnChange(e){ye(this._onChange,e)}registerOnDisabledChange(e){this._onDisabledChange.push(e)}_unregisterOnDisabledChange(e){ye(this._onDisabledChange,e)}_forEachChild(e){}_syncPendingControls(){return this.updateOn===`submit`&&(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),this._pendingChange)?(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),!0):!1}_applyFormState(e){ve(e)?(this.value=this._pendingValue=e.value,e.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=e}};var Dt={provide:y,useExisting:Oo(()=>At)};var _e=Promise.resolve();var At=(()=>{class n extends y{_changeDetectorRef;callSetDisabledState;control=new Vt;static ngAcceptInputType_isDisabled;_registered=!1;_ngModelInjector;viewModel;name=``;isDisabled;model;options;update=new He$1;constructor(t,r,i,o,l,je,Ge,ke){super(Ge,ke,o),this._changeDetectorRef=l,this.callSetDisabledState=je,this._parent=t,this._setValidators(r),this._setAsyncValidators(i)}ngOnChanges(t){if(this._registered,this._checkForErrors(),!this._registered||`name`in t){if(this._registered&&(this._checkName(),this.formDirective)){let r=t.name.previousValue;this.formDirective.removeControl({name:r,path:this._getPath(r)})}this._setUpControl()}`isDisabled`in t&&this._updateDisabled(t),yt(t,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective?.removeControl(this)}ɵngControlCreate(t){super.ngControlCreate(t)}ɵngControlUpdate(t){super.ngControlUpdate(t,!1)}get shouldBindRequired(){return!1}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(t){this.viewModel=t,this.update.emit(t)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&this.options.updateOn!=null&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!!(this.options&&this.options.standalone)}_setUpStandalone(){this.isCustomControlBased?this.setupCustomControl():(this.valueAccessor??=this.selectedValueAccessor,ge(this.control,this,this.callSetDisabledState)),this.control.updateValueAndValidity({emitEvent:!1})}_setupWithForm(t){this.isCustomControlBased?this.setupCustomControl():(this.valueAccessor??=this.selectedValueAccessor,ge(this.control,this,t))}_checkForErrors(){this._checkName()}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),!this._isStandalone()&&this.name}_updateValue(t){_e.then(()=>{this.control.setValue(t,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(t){let r=t.isDisabled.currentValue,i=r!==0&&NL(r);_e.then(()=>{i&&!this.control.disabled?this.control.disable():!i&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(t){return this._parent?ct(t,this._parent):[t]}static ɵfac=function(r){return new(r||n)(Hr(q,9),Hr(Ae,10),Hr($e,10),Hr(Ve,10),Hr(_L,8),Hr(Te,8),Hr(Ie$1,8),Hr(fc,8))};static ɵdir=bI({type:n,selectors:[[``,`ngModel`,``,3,`formControlName`,``,3,`formControl`,``]],inputs:{name:`name`,isDisabled:[0,`disabled`,`isDisabled`],model:[0,`ngModel`,`model`],options:[0,`ngModelOptions`,`options`]},outputs:{update:`ngModelChange`},exportAs:[`ngModel`],standalone:!1,features:[xD([Dt,Ct]),nh,ry,SI(null)]})}return n})();var bt=(()=>{class n{static ɵfac=function(r){return new(r||n)};static ɵmod=al({type:n});static ɵinj=ko({})}return n})();var Zt=(()=>{class n{static withConfig(t){return{ngModule:n,providers:[{provide:Te,useValue:t.callSetDisabledState??K}]}}static ɵfac=function(r){return new(r||n)};static ɵmod=al({type:n});static ɵinj=ko({imports:[bt]})}return n})();export{Zt as i,De as n,Yt as r,At as t};
@@ -0,0 +1 @@
1
+ import{$ as ah,At as sl,Bt as zr,Ct as oD,Et as pl,G as XI,It as yg,K as YI,Lt as yh,Nt as vh,O as LD,P as Qu,Rt as zI,U as Vv,_ as FD,c as $i,dt as hg,ft as hh,g as Eg,gt as jI,jt as uh,kt as sh,l as AD,m as DD,p as CL,q as Yu,r as g$1,s as $I,st as g,t as Nt,v as Gi,vt as kD,xt as ml,y as HI,yt as ki}from"./main-QDFVZK3T.js";import{a as l,o as w,s as y}from"./chunk-DQU0VyoQ.js";import{t as h}from"./chunk-DqWNkF1O.js";import{t as _}from"./chunk-BaQMhq-G.js";import{t as w$1}from"./chunk-BVKnCv85.js";import{t as I}from"./chunk-DyIHOW_a.js";import{t as _$1}from"./chunk-C4gpbtbP.js";import{t as E}from"./chunk-Bb0C24YV.js";var N=e=>({time:e});var re=e=>[`/forges`,e];var F=(e,o)=>o.id;function de(e,o){e&1&&(ki(0,`div`,3),kD(1,`t`),ah(2,`ui-skeleton`,4)(3,`ui-skeleton`,5),pl()),e&2&&($i(`aria-label`,LD(1,2,`state.loading`)),Vv(3),sh(`lines`,4))}function le(e,o){e&1&&(ki(0,`code`,9),DD(1),pl()),e&2&&(Vv(),ml(`v`,o))}function se(e,o){e&1&&(ki(0,`span`,10),DD(1),kD(2,`t`),pl()),e&2&&(Vv(),yh(LD(2,1,`settings.federated`)))}function pe(e,o){e&1&&(DD(0),kD(1,`t`)),e&2&&ml(` `,o.profile??LD(1,1,`state.none`),` `)}function ce(e,o){e&1&&ah(0,`ui-state-badge`,16)}function me(e,o){e&1&&ah(0,`ui-state-badge`,13),e&2&&sh(`state`,o.state)}function _e(e,o){e&1&&ah(0,`ui-state-badge`,17)}function ue(e,o){if(e&1&&(ki(0,`span`),DD(1),kD(2,`t`),pl()),e&2){let n=XI(2);Vv(),ml(` · `,FD(2,1,`common.updatedAt`,AD(4,N,n.stamp(o))))}}function ge(e,o){if(e&1&&(ki(0,`span`),DD(1),kD(2,`t`),pl()),e&2){let n=XI(2);Vv(),ml(` · `,FD(2,1,`common.updatedAt`,AD(4,N,n.stamp(o))))}}function ve(e,o){if(e&1&&(ki(0,`span`),DD(1),kD(2,`t`),pl()),e&2){let n=XI(2);Vv(),ml(` · `,FD(2,1,`common.updatedAt`,AD(4,N,n.stamp(o))))}}function fe(e,o){e&1&&(ki(0,`div`,27),ah(1,`ui-state-badge`,16),ki(2,`span`),DD(3),kD(4,`t`),pl()()),e&2&&(Vv(3),yh(LD(4,1,`federation.unavailable`)))}function xe(e,o){if(e&1){let n=YI();ki(0,`ui-error`,40),uh(`retry`,function(){Yu(n);let f=XI(2);return Qu(f.loadFederation())}),pl()}e&2&&sh(`error`,o)}function be(e,o){e&1&&(ki(0,`div`,29),ah(1,`ui-skeleton`,5),pl()),e&2&&(Vv(),sh(`lines`,3))}function ye(e,o){e&1&&(ki(0,`span`,43),DD(1),kD(2,`t`),pl()),e&2&&(Vv(),yh(LD(2,1,`explorer.serving`)))}function he(e,o){e&1&&ah(0,`ui-state-badge`,16)}function Ce(e,o){e&1&&(ki(0,`span`,44),DD(1),kD(2,`t`),pl()),e&2&&(Vv(),yh(LD(2,1,`state.absent`)))}function Se(e,o){if(e&1&&(ki(0,`code`,45),DD(1),pl()),e&2){let n=XI().$implicit;$i(`title`,n.checkout),Vv(),yh(n.checkout)}}function ke(e,o){e&1&&ah(0,`ui-state-badge`,16)}function Ee(e,o){if(e&1&&(ki(0,`span`,44),DD(1),kD(2,`t`),pl()),e&2){let n=XI().$implicit;Vv(),yh(LD(2,1,n.mcp===null?`federation.mcpAbsent`:`federation.mcpReady`))}}function Pe(e,o){if(e&1&&(ki(0,`tr`)(1,`td`)(2,`a`,42),DD(3),pl(),jI(4,ye,3,3,`span`,43),pl(),ki(5,`td`),ah(6,`ui-state-badge`,13),pl(),ki(7,`td`),jI(8,he,1,0,`ui-state-badge`,16)(9,Ce,3,3,`span`,44)(10,Se,2,2,`code`,45),pl(),ki(11,`td`),jI(12,ke,1,0,`ui-state-badge`,16)(13,Ee,3,3,`span`,44),pl()()),e&2){let n=o.$implicit;$i(`data-serving`,n.serving||null),Vv(2),sh(`routerLink`,AD(7,re,n.id)),Vv(),yh(n.name??n.id),Vv(),HI(n.serving?4:-1),Vv(2),sh(`state`,n.state??`UNVERIFIED`),Vv(2),HI(n.checkout===void 0?8:n.checkout===null?9:10),Vv(4),HI(n.mcp===void 0?12:13)}}function Ne(e,o){if(e&1&&(ki(0,`div`,30)(1,`table`,41)(2,`thead`)(3,`tr`)(4,`th`),DD(5),kD(6,`t`),pl(),ki(7,`th`),DD(8),kD(9,`t`),pl(),ki(10,`th`),DD(11),kD(12,`t`),pl(),ki(13,`th`),DD(14),kD(15,`t`),pl()()(),ki(16,`tbody`),$I(17,Pe,14,9,`tr`,null,F),pl()()()),e&2){let n=XI(2);Vv(5),yh(LD(6,4,`table.id`)),Vv(3),yh(LD(9,6,`skills.state`)),Vv(3),yh(LD(12,8,`explorer.checkout`)),Vv(3),yh(LD(15,10,`mcp.title`)),Vv(3),zI(n.forgesRows())}}function we(e,o){e&1&&(ah(0,`ui-empty`,31),kD(1,`t`)),e&2&&sh(`title`,LD(1,1,`federation.empty`))}function De(e,o){if(e&1&&(ki(0,`span`),DD(1),kD(2,`t`),pl()),e&2){let n=XI(2);Vv(),ml(` · `,FD(2,1,`common.updatedAt`,AD(4,N,n.stamp(o))))}}function Ie(e,o){if(e&1&&(ki(0,`span`,46),ah(1,`ui-icon`,47),ki(2,`span`,48),DD(3),pl(),ah(4,`i`,49),pl()),e&2){let n=o.$implicit,v=XI(3);$i(`data-state`,n.state)(`title`,n.state),Vv(),sh(`name`,v.capIcon(n.id))(`size`,15),Vv(2),yh(n.id)}}function Te(e,o){if(e&1&&(ki(0,`div`,35),$I(1,Ie,5,5,`span`,46,F),pl()),e&2){let n=XI(2);Vv(),zI(n.store.capabilities())}}function Be(e,o){e&1&&(ah(0,`ui-empty`,36),kD(1,`t`)),e&2&&sh(`title`,LD(1,1,`dashboard.none`))}function Me(e,o){if(e&1&&(ki(0,`span`,38),DD(1),pl()),e&2){let n=XI(2);$i(`data-failures`,n.failures()),Vv(),yh(n.failures())}}function Oe(e,o){if(e&1&&(ki(0,`span`),DD(1),kD(2,`t`),pl()),e&2){let n=XI(2);Vv(),ml(` · `,FD(2,1,`common.updatedAt`,AD(4,N,n.stamp(o))))}}function Fe(e,o){e&1&&(ki(0,`div`,27),ah(1,`ui-state-badge`,16),ki(2,`span`),DD(3),kD(4,`t`),pl()()),e&2&&(Vv(3),yh(LD(4,1,`federation.unavailable`)))}function ze(e,o){if(e&1){let n=YI();ki(0,`ui-error`,40),uh(`retry`,function(){Yu(n);let f=XI(2);return Qu(f.loadTasks())}),pl()}e&2&&sh(`error`,o)}function Ve(e,o){e&1&&(ki(0,`div`,29),ah(1,`ui-skeleton`,5),pl()),e&2&&(Vv(),sh(`lines`,3))}function Ae(e,o){if(e&1&&(ki(0,`tr`)(1,`td`),DD(2),pl(),ki(3,`td`)(4,`code`),DD(5),pl()(),ki(6,`td`),ah(7,`ui-state-badge`,50),pl(),ki(8,`td`),DD(9),pl()()),e&2){let n=o.$implicit,v=XI(3);$i(`data-fail`,v.taskFailed(n)||null),Vv(2),yh(n.label),Vv(3),yh(n.verb),Vv(2),sh(`state`,v.taskState(n))(`labelOverride`,n.stage),Vv(2),yh(n.exit_code??`—`)}}function Re(e,o){if(e&1&&(ki(0,`div`,30)(1,`table`,41)(2,`thead`)(3,`tr`)(4,`th`),DD(5),kD(6,`t`),pl(),ki(7,`th`),DD(8),kD(9,`t`),pl(),ki(10,`th`),DD(11),kD(12,`t`),pl(),ki(13,`th`),DD(14),kD(15,`t`),pl()()(),ki(16,`tbody`),$I(17,Ae,10,6,`tr`,null,F),pl()()()),e&2){let n=XI(2);Vv(5),yh(LD(6,4,`table.task`)),Vv(3),yh(LD(9,6,`table.verb`)),Vv(3),yh(LD(12,8,`table.stage`)),Vv(3),yh(LD(15,10,`table.exit`)),Vv(3),zI(n.recentTasks())}}function Le(e,o){e&1&&(ah(0,`ui-empty`,39),kD(1,`t`)),e&2&&sh(`title`,LD(1,1,`tasks.empty`))}function Ue(e,o){if(e&1){let n=YI();ki(0,`section`,6)(1,`div`,7)(2,`div`,8)(3,`strong`),DD(4),pl(),jI(5,le,2,1,`code`,9),jI(6,se,3,3,`span`,10),pl(),ki(7,`button`,11),kD(8,`t`),uh(`click`,function(){Yu(n);let f=XI();return Qu(f.store.refreshHealth())}),ah(9,`ui-icon`,2),pl()(),ki(10,`div`,12),ah(11,`ui-state-badge`,13),ki(12,`span`,14),ah(13,`ui-icon`,15),DD(14),kD(15,`t`),pl(),ki(16,`span`,14),DD(17),kD(18,`t`),jI(19,pe,2,3)(20,ce,1,0,`ui-state-badge`,16),pl(),ki(21,`span`,14),DD(22),kD(23,`t`),jI(24,me,1,1,`ui-state-badge`,13)(25,_e,1,0,`ui-state-badge`,17),pl()(),ki(26,`p`,18)(27,`code`),DD(28,`bootstrap · GET /api/v1/installation/status`),pl(),jI(29,ue,3,6,`span`),pl()(),ki(30,`section`,19)(31,`div`,20)(32,`div`,21)(33,`span`,22),ah(34,`ui-state-badge`,13),pl(),ki(35,`span`,23),DD(36),kD(37,`t`),pl()(),ki(38,`div`,21)(39,`span`,22),DD(40),pl(),ki(41,`span`,23),DD(42),kD(43,`t`),pl()(),ki(44,`div`,21)(45,`span`,22),DD(46),pl(),ki(47,`span`,23),DD(48),kD(49,`t`),pl()(),ki(50,`div`,21)(51,`span`,22),DD(52),pl(),ki(53,`span`,23),DD(54),kD(55,`t`),pl()()(),ki(56,`p`,18)(57,`code`),DD(58,`bootstrap · GET /api/v1/installation/status`),pl(),jI(59,ge,3,6,`span`),pl()(),ki(60,`section`,24)(61,`div`,25)(62,`div`)(63,`h2`),DD(64),kD(65,`t`),pl(),ki(66,`p`,18)(67,`code`),DD(68,`GET /api/v1/federation`),pl(),jI(69,ve,3,6,`span`),pl()(),ki(70,`button`,11),kD(71,`t`),uh(`click`,function(){Yu(n);let f=XI();return Qu(f.loadFederation())}),ah(72,`ui-icon`,2),pl()(),ki(73,`p`,26),DD(74),kD(75,`t`),pl(),jI(76,fe,5,3,`div`,27),jI(77,xe,1,1,`ui-error`,28),jI(78,be,2,1,`div`,29),jI(79,Ne,19,12,`div`,30)(80,we,2,3,`ui-empty`,31),ki(81,`a`,32),DD(82),kD(83,`t`),ah(84,`ui-icon`,33),pl()(),ki(85,`section`,34)(86,`div`,25)(87,`div`)(88,`h2`),DD(89),kD(90,`t`),pl(),ki(91,`p`,18)(92,`code`),DD(93,`bootstrap`),pl(),jI(94,De,3,6,`span`),pl()(),ki(95,`button`,11),kD(96,`t`),uh(`click`,function(){Yu(n);let f=XI();return Qu(f.store.refreshHealth())}),ah(97,`ui-icon`,2),pl()(),jI(98,Te,3,0,`div`,35)(99,Be,2,3,`ui-empty`,36),pl(),ah(100,`inventory-panel`),ki(101,`section`,37)(102,`div`,25)(103,`div`)(104,`h2`),DD(105),kD(106,`t`),jI(107,Me,2,2,`span`,38),pl(),ki(108,`p`,18)(109,`code`),DD(110,`GET /api/v1/tasks`),pl(),jI(111,Oe,3,6,`span`),pl()(),ki(112,`button`,11),kD(113,`t`),uh(`click`,function(){Yu(n);let f=XI();return Qu(f.loadTasks())}),ah(114,`ui-icon`,2),pl()(),jI(115,Fe,5,3,`div`,27),jI(116,ze,1,1,`ui-error`,28),jI(117,Ve,2,1,`div`,29),jI(118,Re,19,12,`div`,30)(119,Le,2,3,`ui-empty`,39),pl()}if(e&2){let n,v,f,z,V,A,R,L,U,$,s=XI();Vv(4),yh(s.store.forgeName()),Vv(),HI((n=s.descriptor()?.forge_version)?5:-1,n),Vv(),HI(s.store.federated()?6:-1),Vv(),$i(`aria-label`,LD(8,57,`state.refresh`)),Vv(2),sh(`size`,14),Vv(2),sh(`state`,s.health()?.state??`UNVERIFIED`),Vv(2),sh(`size`,13),Vv(),ml(``,s.store.workspace()?.name??LD(15,59,`dashboard.noWorkspace`),` `),Vv(3),ml(` `,LD(18,61,`dashboard.profile`),`: `),Vv(2),HI((v=s.health())?19:20,v),Vv(3),ml(` `,LD(23,63,`dashboard.accountEnvironment`),` `),Vv(2),HI((f=s.store.accountEnvironment())?24:25,f),Vv(5),HI((z=s.store.refreshedAt())?29:-1,z),Vv(3),Gi(`--%NS%stat-rail`,`var(--accent)`),Vv(2),sh(`state`,s.health()?.state??`UNVERIFIED`),Vv(2),yh(LD(37,65,`dashboard.stat.state`)),Vv(2),Gi(`--%NS%stat-rail`,`var(--ok)`),Vv(2),vh(``,s.capsSupported(),`/`,s.store.capabilities().length),Vv(2),yh(LD(43,67,`dashboard.stat.capabilities`)),Vv(2),Gi(`--%NS%stat-rail`,`var(--info)`),Vv(2),vh(``,s.checksOk(),`/`,s.health()?.checks.length??0),Vv(2),yh(LD(49,69,`dashboard.stat.checks`)),Vv(2),Gi(`--%NS%stat-rail`,`var(--fg-muted)`),Vv(2),yh(s.descriptor()?.portal_version??`—`),Vv(2),yh(LD(55,71,`dashboard.stat.portal`)),Vv(5),HI((V=s.store.refreshedAt())?59:-1,V),Vv(5),yh(LD(65,73,`dashboard.forges`)),Vv(5),HI((A=s.fed.loadedAt())?69:-1,A),Vv(),$i(`aria-label`,LD(71,75,`state.refresh`)),Vv(2),sh(`size`,14),Vv(2),yh(LD(75,77,`dashboard.forges.hint`)),Vv(2),HI(s.fed.unavailable()?76:-1),Vv(),HI((R=s.fed.error())?77:-1,R),Vv(),HI(s.fed.loading()&&!s.fed.data()?78:-1),Vv(),HI(s.forgesRows().length?79:s.fed.attempted()&&!s.fed.loading()&&!s.fed.error()?80:-1),Vv(3),ml(` `,LD(83,79,`state.viewDetails`)),Vv(2),sh(`size`,14),Vv(5),yh(LD(90,81,`dashboard.capabilities`)),Vv(5),HI((L=s.store.refreshedAt())?94:-1,L),Vv(),$i(`aria-label`,LD(96,83,`state.refresh`)),Vv(2),sh(`size`,14),Vv(),HI(s.store.capabilities().length?98:99),Vv(7),ml(` `,LD(106,85,`tasks.recent`),` `),Vv(2),HI(s.failures()?107:-1),Vv(4),HI((U=s.tasksSrc.loadedAt())?111:-1,U),Vv(),$i(`aria-label`,LD(113,87,`state.refresh`)),Vv(2),sh(`size`,14),Vv(),HI(s.tasksSrc.unavailable()?115:-1),Vv(),HI(($=s.tasksSrc.error())?116:-1,$),Vv(),HI(s.tasksSrc.loading()&&!s.tasksSrc.data()?117:-1),Vv(),HI(s.recentTasks().length?118:s.tasksSrc.attempted()&&!s.tasksSrc.loading()&&!s.tasksSrc.error()&&!s.tasksSrc.unavailable()?119:-1)}}var oe=class e{store=g(g$1);api=g(hg);fed=new l;tasksSrc=new l;inventory=CL(E);health=zr(()=>this.store.health());descriptor=zr(()=>this.store.descriptor());forgesRows=zr(()=>w(this.descriptor(),this.health(),this.fed.data()).slice(0,8));recentTasks=zr(()=>[...this.tasksSrc.data()??[]].sort((o,n)=>n.started_at.localeCompare(o.started_at)).slice(0,6));failures=zr(()=>this.recentTasks().filter(o=>this.taskFailed(o)).length);capsSupported=zr(()=>this.store.capabilities().filter(o=>o.state===`supported`).length);checksOk=zr(()=>(this.health()?.checks??[]).filter(o=>o.state===`PASS`).length);stamp=y;capIcons={tasks:`tasks`,graph:`graph`,mcp:`mcp`,skills:`skills`,agents:`agents`,knowledge:`knowledge`,hosts:`hosts`,install:`install`,profiles:`profiles`,federation:`network`,scan:`search`,analyze:`search`,docs:`knowledge`};constructor(){this.refreshAll()}async refreshAll(){await Promise.allSettled([this.store.refreshHealth(),this.loadFederation(),this.loadTasks(),this.inventory()?.loadCounts()??Promise.resolve()])}async loadFederation(){await this.fed.load(()=>this.api.federation())}async loadTasks(){await this.tasksSrc.load(()=>this.api.tasks())}taskFailed(o){let n=(o.stage||``).toLowerCase();return[`failed`,`refused`,`cancelled`].includes(n)?!0:o.exit_code!==null&&o.exit_code!==0}taskState(o){let n=(o.stage||``).toLowerCase();return n===`completed`?`supported`:[`failed`,`refused`,`cancelled`].includes(n)?`error`:[`awaiting_approval`,`partial`].includes(n)?`warn`:[`running`,`planning`,`verifying`,`started`,`selected`].includes(n)?`info`:`muted`}capIcon(o){return this.capIcons[o]??`check`}static ɵfac=function(n){return new(n||e)};static ɵcmp=sl({type:e,selectors:[[`page-dashboard`]],viewQuery:function(n,v){n&1&&hh(v.inventory,E,5),n&2&&oD()},decls:9,vars:11,consts:[[3,`title`,`subtitle`],[1,`btn`,3,`click`],[`name`,`refresh`,3,`size`],[`role`,`status`,1,`boot`],[`kind`,`card`],[`kind`,`row`,3,`lines`],[`data-section`,`status`,1,`card`,`status`],[1,`status__top`],[1,`status__id`],[1,`ver`],[1,`fed`],[1,`icon-btn`,3,`click`],[1,`status__meta`],[3,`state`],[1,`meta`],[`name`,`folder`,3,`size`],[`state`,`UNVERIFIED`],[`state`,`MISSING`],[1,`src`],[`data-section`,`stats`],[1,`stats`,`stagger`],[1,`stat`],[1,`stat__value`],[1,`stat__label`],[`data-section`,`forges`,1,`card`],[1,`sec__head`],[1,`muted`,`sec__hint`],[`role`,`note`,1,`unv`],[3,`error`],[`role`,`status`],[1,`table-wrap`],[`icon`,`network`,3,`title`],[`routerLink`,`/forges`,1,`more`],[`name`,`chevron-right`,3,`size`],[`data-section`,`capabilities`,1,`card`],[1,`caps`],[`icon`,`dashboard`,3,`title`],[`data-section`,`tasks`,1,`card`],[1,`failn`],[`icon`,`tasks`,3,`title`],[3,`retry`,`error`],[1,`table`],[1,`link`,3,`routerLink`],[1,`chip`],[1,`muted`],[1,`path`],[1,`cap`],[3,`name`,`size`],[1,`cap__id`],[`aria-hidden`,`true`,1,`cap__dot`],[3,`state`,`labelOverride`]],template:function(n,v){n&1&&(ki(0,`ui-page-header`,0),kD(1,`t`),kD(2,`t`),ki(3,`button`,1),uh(`click`,function(){return v.refreshAll()}),ah(4,`ui-icon`,2),DD(5),kD(6,`t`),pl()(),jI(7,de,4,4,`div`,3)(8,Ue,120,89)),n&2&&(sh(`title`,LD(1,5,`dashboard.title`))(`subtitle`,LD(2,7,`dashboard.subtitle`)),Vv(4),sh(`size`,15),Vv(),ml(` `,LD(6,9,`state.refresh`),` `),Vv(2),HI(v.store.status()===`booting`&&!v.health()?7:8))},dependencies:[Nt,_$1,I,_,w$1,Eg,h,E,yg],styles:[`.card[_ngcontent-%COMP%], .boot[_ngcontent-%COMP%]{margin-bottom:var(--%NS%space-4)}.status__top[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:flex-start;gap:var(--%NS%space-3)}.status__id[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--%NS%space-2);font-size:var(--%NS%font-lg);font-weight:700;letter-spacing:-.01em;min-width:0}.ver[_ngcontent-%COMP%]{font-size:var(--%NS%font-xs);font-weight:600;background:var(--%NS%accent-bg);color:var(--%NS%accent-strong);border-radius:var(--%NS%radius-pill);padding:1px 8px}.fed[_ngcontent-%COMP%]{font-size:var(--%NS%font-xs);font-weight:700;color:var(--%NS%accent);border:1px solid color-mix(in srgb,var(--%NS%accent) 55%,transparent);border-radius:var(--%NS%radius-pill);padding:1px 8px;background:var(--%NS%accent-bg)}.status__meta[_ngcontent-%COMP%]{display:flex;align-items:center;flex-wrap:wrap;gap:var(--%NS%space-2) var(--%NS%space-4);margin-top:var(--%NS%space-3)}.meta[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:6px;font-size:var(--%NS%font-sm);color:var(--%NS%fg-muted)}.src[_ngcontent-%COMP%]{margin:var(--%NS%space-3) 0 0;font-size:var(--%NS%font-xs);color:var(--%NS%fg-muted)}.sec__head[_ngcontent-%COMP%]{display:flex;justify-content:space-between;align-items:flex-start;gap:var(--%NS%space-3)}.sec__head[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0;font-size:var(--%NS%font-lg);font-weight:650}.sec__head[_ngcontent-%COMP%] .src[_ngcontent-%COMP%]{margin-top:4px}.sec__hint[_ngcontent-%COMP%]{margin:2px 0 var(--%NS%space-3);font-size:var(--%NS%font-sm)}.muted[_ngcontent-%COMP%]{color:var(--%NS%fg-muted)}.stats[_ngcontent-%COMP%]{display:grid;grid-template-columns:repeat(auto-fit,minmax(170px,1fr));gap:var(--%NS%space-4);margin-bottom:var(--%NS%space-4)}.unv[_ngcontent-%COMP%]{display:flex;align-items:center;gap:var(--%NS%space-3);padding:var(--%NS%space-3);margin-bottom:var(--%NS%space-3);border:1px dashed color-mix(in srgb,var(--%NS%warn) 55%,transparent);border-radius:var(--%NS%radius-md);background:var(--%NS%warn-bg);font-size:var(--%NS%font-sm)}.table-wrap[_ngcontent-%COMP%]{overflow-x:auto;margin-top:var(--%NS%space-2)}.path[_ngcontent-%COMP%]{display:inline-block;max-width:34ch;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;vertical-align:bottom}.chip[_ngcontent-%COMP%]{margin-left:6px;font-size:var(--%NS%font-xs);font-weight:700;color:var(--%NS%accent);background:var(--%NS%accent-bg);border-radius:var(--%NS%radius-pill);padding:1px 8px}.more[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:4px;margin-top:var(--%NS%space-3);font-size:var(--%NS%font-sm);font-weight:600;text-decoration:none}.failn[_ngcontent-%COMP%]{display:inline-grid;place-items:center;min-width:20px;height:20px;margin-left:6px;padding:0 6px;border-radius:var(--%NS%radius-pill);background:var(--%NS%error-bg);color:var(--%NS%error);font-size:var(--%NS%font-xs);font-weight:700;vertical-align:2px}tr[data-fail][_ngcontent-%COMP%] td[_ngcontent-%COMP%]{background:color-mix(in srgb,var(--%NS%error-bg) 55%,transparent)}.caps[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:var(--%NS%space-2);margin-top:var(--%NS%space-3)}inventory-panel[_ngcontent-%COMP%]{display:block;margin-bottom:var(--%NS%space-4)}`]})};export{oe as DashboardPage};
Binary file
@@ -0,0 +1,13 @@
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="utf-8"/>
5
+ <title>ForgePortalApp</title>
6
+ <base href="/"/>
7
+ <meta name="viewport" content="width=device-width, initial-scale=1"/>
8
+ <link rel="icon" type="image/x-icon" href="favicon.ico"/>
9
+ <link rel="stylesheet" href="styles-MQEBDFDX.css"></head>
10
+ <body>
11
+ <app-root></app-root>
12
+ <script src="main-QDFVZK3T.js" type="module"></script></body>
13
+ </html>