likec4 1.13.0 → 1.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1067) hide show
  1. package/README.md +4 -0
  2. package/dist/__app__/src/chunks/{-index-overview-DrWsHFH4.js → -index-overview-BwT9t8VB.js} +10 -10
  3. package/dist/__app__/src/chunks/{likec4-B4TbAFjc.js → likec4-zEZHE7gJ.js} +6 -0
  4. package/dist/__app__/src/chunks/{main-Bb3q3o7f.js → main-Q7z-4OPp.js} +1969 -829
  5. package/dist/__app__/src/chunks/{mantine-5H3V65ZR.js → mantine-Dx0sIYv1.js} +61 -63
  6. package/dist/__app__/src/chunks/{tanstack-router-C6UpMKjv.js → tanstack-router-CfO1HFS2.js} +1 -1
  7. package/dist/__app__/src/main.js +1 -1
  8. package/dist/__app__/src/style.css +1 -1
  9. package/dist/__app__/webcomponent/webcomponent.js +3106 -1962
  10. package/dist/chunks/prompt.mjs +1 -1
  11. package/dist/cli/index.mjs +18 -18
  12. package/dist/index.d.mts +114 -17
  13. package/dist/index.d.ts +114 -17
  14. package/dist/index.mjs +1 -1
  15. package/dist/shared/likec4.CozyJbyo.mjs +1824 -0
  16. package/icons/all.d.ts +0 -1
  17. package/icons/all.js +0 -2
  18. package/icons/aws/activate.js +9 -9
  19. package/icons/aws/alexa-for-business.js +10 -10
  20. package/icons/aws/amplify.js +2 -2
  21. package/icons/aws/apache-mxnet-on-aws.js +5 -5
  22. package/icons/aws/api-gateway.js +5 -5
  23. package/icons/aws/app-config.js +5 -5
  24. package/icons/aws/app-flow.js +5 -5
  25. package/icons/aws/app-mesh.js +4 -4
  26. package/icons/aws/app-runner.js +5 -5
  27. package/icons/aws/app-stream.js +10 -10
  28. package/icons/aws/app-sync.js +7 -7
  29. package/icons/aws/application-auto-scaling.js +4 -4
  30. package/icons/aws/application-composer.js +6 -6
  31. package/icons/aws/application-cost-profiler.js +4 -4
  32. package/icons/aws/application-discovery-service.js +10 -10
  33. package/icons/aws/application-migration-service.js +10 -10
  34. package/icons/aws/artifact.js +9 -9
  35. package/icons/aws/athena.js +7 -7
  36. package/icons/aws/audit-manager.js +5 -5
  37. package/icons/aws/augmented-ai-a2i.js +4 -4
  38. package/icons/aws/aurora.js +5 -5
  39. package/icons/aws/auto-scaling.js +2 -2
  40. package/icons/aws/backint-agent.js +5 -5
  41. package/icons/aws/backup.js +4 -4
  42. package/icons/aws/batch.js +5 -5
  43. package/icons/aws/billing-conductor.js +7 -7
  44. package/icons/aws/bottlerocket.js +5 -5
  45. package/icons/aws/braket.js +10 -10
  46. package/icons/aws/budgets.js +7 -7
  47. package/icons/aws/certificate-manager.js +10 -10
  48. package/icons/aws/chatbot.js +10 -10
  49. package/icons/aws/chime-sdk.js +4 -4
  50. package/icons/aws/chime-voice-connector.js +5 -5
  51. package/icons/aws/chime.js +4 -4
  52. package/icons/aws/clean-rooms.js +5 -5
  53. package/icons/aws/client-vpn.js +7 -7
  54. package/icons/aws/cloud-control-api.js +8 -8
  55. package/icons/aws/cloud-development-kit.js +7 -7
  56. package/icons/aws/cloud-directory.js +8 -8
  57. package/icons/aws/cloud-formation.js +6 -6
  58. package/icons/aws/cloud-front.js +2 -2
  59. package/icons/aws/cloud-hsm.js +4 -4
  60. package/icons/aws/cloud-map.js +2 -2
  61. package/icons/aws/cloud-search.js +2 -2
  62. package/icons/aws/cloud-shell.js +4 -4
  63. package/icons/aws/cloud-trail.js +8 -8
  64. package/icons/aws/cloud-wan.js +2 -2
  65. package/icons/aws/cloud-watch.js +2 -2
  66. package/icons/aws/cloud9.js +2 -2
  67. package/icons/aws/code-artifact.js +4 -4
  68. package/icons/aws/code-build.js +4 -4
  69. package/icons/aws/code-catalyst.js +10 -10
  70. package/icons/aws/code-commit.js +8 -8
  71. package/icons/aws/code-deploy.js +4 -4
  72. package/icons/aws/code-guru.js +4 -4
  73. package/icons/aws/code-pipeline.js +10 -10
  74. package/icons/aws/code-star.js +2 -2
  75. package/icons/aws/code-whisperer.js +6 -6
  76. package/icons/aws/cognito.js +9 -9
  77. package/icons/aws/command-line-interface.js +9 -9
  78. package/icons/aws/comprehend-medical.js +5 -5
  79. package/icons/aws/comprehend.js +5 -5
  80. package/icons/aws/compute-optimizer.js +4 -4
  81. package/icons/aws/config.js +2 -2
  82. package/icons/aws/connect.js +2 -2
  83. package/icons/aws/console-mobile-application.js +2 -2
  84. package/icons/aws/control-tower.js +2 -2
  85. package/icons/aws/corretto.js +5 -5
  86. package/icons/aws/cost-and-usage-report.js +5 -5
  87. package/icons/aws/cost-explorer.js +2 -2
  88. package/icons/aws/data-exchange.js +9 -9
  89. package/icons/aws/data-pipeline.js +5 -5
  90. package/icons/aws/data-sync.js +8 -8
  91. package/icons/aws/data-zone.js +8 -8
  92. package/icons/aws/database-migration-service.js +9 -9
  93. package/icons/aws/deep-composer.js +9 -9
  94. package/icons/aws/deep-learning-amis.js +5 -5
  95. package/icons/aws/deep-learning-containers.js +7 -7
  96. package/icons/aws/deep-lens.js +10 -10
  97. package/icons/aws/deep-racer.js +2 -2
  98. package/icons/aws/detective.js +6 -6
  99. package/icons/aws/dev-ops-guru.js +5 -5
  100. package/icons/aws/device-farm.js +7 -7
  101. package/icons/aws/direct-connect.js +7 -7
  102. package/icons/aws/directory-service.js +9 -9
  103. package/icons/aws/distro-for-open-telemetry.js +10 -10
  104. package/icons/aws/document-db.js +5 -5
  105. package/icons/aws/dynamo-db.js +2 -2
  106. package/icons/aws/ec2-auto-scaling.js +2 -2
  107. package/icons/aws/ec2-image-builder.js +7 -7
  108. package/icons/aws/ec2.js +2 -2
  109. package/icons/aws/ecs-anywhere.js +10 -10
  110. package/icons/aws/efs.js +4 -4
  111. package/icons/aws/eks-anywhere.js +4 -4
  112. package/icons/aws/eks-cloud.js +5 -5
  113. package/icons/aws/eks-distro.js +2 -2
  114. package/icons/aws/elasti-cache.js +7 -7
  115. package/icons/aws/elastic-beanstalk.js +7 -7
  116. package/icons/aws/elastic-block-store.js +4 -4
  117. package/icons/aws/elastic-container-registry.js +6 -6
  118. package/icons/aws/elastic-container-service.js +6 -6
  119. package/icons/aws/elastic-disaster-recovery.js +10 -10
  120. package/icons/aws/elastic-fabric-adapter.js +5 -5
  121. package/icons/aws/elastic-inference.js +2 -2
  122. package/icons/aws/elastic-kubernetes-service.js +5 -5
  123. package/icons/aws/elastic-load-balancing.js +5 -5
  124. package/icons/aws/elastic-transcoder.js +5 -5
  125. package/icons/aws/elemental-appliances-software.js +5 -5
  126. package/icons/aws/elemental-conductor.js +2 -2
  127. package/icons/aws/elemental-delta.js +5 -5
  128. package/icons/aws/elemental-link.js +7 -7
  129. package/icons/aws/elemental-live.js +5 -5
  130. package/icons/aws/elemental-media-connect.js +2 -2
  131. package/icons/aws/elemental-media-convert.js +4 -4
  132. package/icons/aws/elemental-media-live.js +4 -4
  133. package/icons/aws/elemental-media-package.js +4 -4
  134. package/icons/aws/elemental-media-store.js +4 -4
  135. package/icons/aws/elemental-media-tailor.js +6 -6
  136. package/icons/aws/elemental-server.js +10 -10
  137. package/icons/aws/emr.js +4 -4
  138. package/icons/aws/event-bridge.js +7 -7
  139. package/icons/aws/express-workflows.js +7 -7
  140. package/icons/aws/fargate.js +5 -5
  141. package/icons/aws/fault-injection-simulator.js +5 -5
  142. package/icons/aws/file-cache.js +5 -5
  143. package/icons/aws/fin-space.js +5 -5
  144. package/icons/aws/firewall-manager.js +4 -4
  145. package/icons/aws/forecast.js +10 -10
  146. package/icons/aws/fraud-detector.js +10 -10
  147. package/icons/aws/free-rtos.js +5 -5
  148. package/icons/aws/fsx-for-lustre.js +8 -8
  149. package/icons/aws/fsx-for-net-app-ontap.js +5 -5
  150. package/icons/aws/fsx-for-open-zfs.js +5 -5
  151. package/icons/aws/fsx-for-wfs.js +9 -9
  152. package/icons/aws/fsx.js +2 -2
  153. package/icons/aws/game-kit.js +10 -10
  154. package/icons/aws/game-lift.js +5 -5
  155. package/icons/aws/game-sparks.js +7 -7
  156. package/icons/aws/genomics-cli.js +10 -10
  157. package/icons/aws/global-accelerator.js +4 -4
  158. package/icons/aws/glue-data-brew.js +6 -6
  159. package/icons/aws/glue-elastic-views.js +5 -5
  160. package/icons/aws/glue.js +4 -4
  161. package/icons/aws/ground-station.js +7 -7
  162. package/icons/aws/guard-duty.js +2 -2
  163. package/icons/aws/health-lake.js +10 -10
  164. package/icons/aws/honeycode.js +5 -5
  165. package/icons/aws/iam-identity-center.js +7 -7
  166. package/icons/aws/identity-and-access-management.js +10 -10
  167. package/icons/aws/inspector.js +6 -6
  168. package/icons/aws/interactive-video-service.js +7 -7
  169. package/icons/aws/io-t-1-click.js +2 -2
  170. package/icons/aws/io-t-analytics.js +5 -5
  171. package/icons/aws/io-t-button.js +5 -5
  172. package/icons/aws/io-t-core.js +7 -7
  173. package/icons/aws/io-t-device-defender.js +9 -9
  174. package/icons/aws/io-t-device-management.js +7 -7
  175. package/icons/aws/io-t-edu-kit.js +2 -2
  176. package/icons/aws/io-t-events.js +6 -6
  177. package/icons/aws/io-t-express-link.js +5 -5
  178. package/icons/aws/io-t-fleet-wise.js +10 -10
  179. package/icons/aws/io-t-greengrass.js +7 -7
  180. package/icons/aws/io-t-robo-runner.js +10 -10
  181. package/icons/aws/io-t-site-wise.js +5 -5
  182. package/icons/aws/io-t-things-graph.js +2 -2
  183. package/icons/aws/io-t-twin-maker.js +12 -5
  184. package/icons/aws/iq.js +4 -4
  185. package/icons/aws/kendra.js +7 -7
  186. package/icons/aws/key-management-service.js +10 -10
  187. package/icons/aws/keyspaces.js +10 -10
  188. package/icons/aws/kinesis-data-analytics.js +8 -8
  189. package/icons/aws/kinesis-data-streams.js +9 -9
  190. package/icons/aws/kinesis-firehose.js +10 -10
  191. package/icons/aws/kinesis-video-streams.js +10 -10
  192. package/icons/aws/kinesis.js +9 -9
  193. package/icons/aws/lake-formation.js +2 -2
  194. package/icons/aws/lambda.js +5 -5
  195. package/icons/aws/launch-wizard.js +2 -2
  196. package/icons/aws/lex.js +5 -5
  197. package/icons/aws/license-manager.js +5 -5
  198. package/icons/aws/lightsail.js +5 -5
  199. package/icons/aws/local-zones.js +5 -5
  200. package/icons/aws/location-service.js +2 -2
  201. package/icons/aws/lookout-for-equipment.js +10 -10
  202. package/icons/aws/lookout-for-metrics.js +10 -10
  203. package/icons/aws/lookout-for-vision.js +10 -10
  204. package/icons/aws/lumberyard.js +4 -4
  205. package/icons/aws/macie.js +8 -8
  206. package/icons/aws/mainframe-modernization.js +10 -10
  207. package/icons/aws/managed-blockchain.js +2 -2
  208. package/icons/aws/managed-grafana.js +9 -9
  209. package/icons/aws/managed-service-for-prometheus.js +9 -9
  210. package/icons/aws/managed-services.js +2 -2
  211. package/icons/aws/managed-streaming-for-apache-kafka.js +5 -5
  212. package/icons/aws/managed-workflows-for-apache-airflow.js +4 -4
  213. package/icons/aws/management-console.js +10 -10
  214. package/icons/aws/memory-db-for-redis.js +10 -10
  215. package/icons/aws/migration-evaluator.js +4 -4
  216. package/icons/aws/migration-hub.js +8 -8
  217. package/icons/aws/monitron.js +5 -5
  218. package/icons/aws/mq.js +5 -5
  219. package/icons/aws/neptune.js +5 -5
  220. package/icons/aws/network-firewall.js +5 -5
  221. package/icons/aws/neuron.js +5 -5
  222. package/icons/aws/nice-dcv.js +2 -2
  223. package/icons/aws/nice-engin-frame.js +9 -9
  224. package/icons/aws/nimble-studio.js +7 -7
  225. package/icons/aws/nitro-enclaves.js +5 -5
  226. package/icons/aws/omics.js +10 -10
  227. package/icons/aws/open-3d-engine.js +5 -5
  228. package/icons/aws/open-search-service.js +7 -7
  229. package/icons/aws/ops-works.js +5 -5
  230. package/icons/aws/organizations.js +7 -7
  231. package/icons/aws/outposts-family.js +2 -2
  232. package/icons/aws/outposts-rack.js +10 -10
  233. package/icons/aws/outposts-servers.js +9 -9
  234. package/icons/aws/panorama.js +10 -10
  235. package/icons/aws/parallel-cluster.js +5 -5
  236. package/icons/aws/personal-health-dashboard.js +4 -4
  237. package/icons/aws/personalize.js +7 -7
  238. package/icons/aws/pinpoint-apis.js +8 -8
  239. package/icons/aws/pinpoint.js +8 -8
  240. package/icons/aws/polly.js +8 -8
  241. package/icons/aws/private-5g.js +9 -9
  242. package/icons/aws/private-certificate-authority.js +22 -11
  243. package/icons/aws/private-link.js +10 -10
  244. package/icons/aws/professional-services.js +7 -7
  245. package/icons/aws/proton.js +10 -10
  246. package/icons/aws/quantum-ledger-database.js +5 -5
  247. package/icons/aws/quick-sight.js +5 -5
  248. package/icons/aws/rds-on-vmware.js +5 -5
  249. package/icons/aws/rds.js +5 -5
  250. package/icons/aws/re-post.js +5 -5
  251. package/icons/aws/red-hat-open-shift-service-on-aws.js +5 -5
  252. package/icons/aws/redshift.js +7 -7
  253. package/icons/aws/rekognition.js +6 -6
  254. package/icons/aws/reserved-instance-reporting.js +7 -7
  255. package/icons/aws/resilience-hub.js +10 -10
  256. package/icons/aws/resource-access-manager.js +6 -6
  257. package/icons/aws/resource-explorer.js +7 -7
  258. package/icons/aws/robo-maker.js +10 -10
  259. package/icons/aws/route-53.js +5 -5
  260. package/icons/aws/s3-on-outposts.js +4 -4
  261. package/icons/aws/sage-maker-ground-truth.js +5 -5
  262. package/icons/aws/sage-maker-studio-lab.js +5 -5
  263. package/icons/aws/sage-maker.js +5 -5
  264. package/icons/aws/savings-plans.js +10 -10
  265. package/icons/aws/secrets-manager.js +10 -10
  266. package/icons/aws/security-hub.js +4 -4
  267. package/icons/aws/security-lake.js +7 -7
  268. package/icons/aws/server-migration-service.js +7 -7
  269. package/icons/aws/serverless-application-repository.js +10 -10
  270. package/icons/aws/service-catalog.js +5 -5
  271. package/icons/aws/service-management-connector.js +23 -12
  272. package/icons/aws/shield.js +7 -7
  273. package/icons/aws/signer.js +5 -5
  274. package/icons/aws/sim-space-weaver.js +4 -4
  275. package/icons/aws/simple-email-service.js +5 -5
  276. package/icons/aws/simple-notification-service.js +7 -7
  277. package/icons/aws/simple-queue-service.js +9 -9
  278. package/icons/aws/simple-storage-service-glacier.js +5 -5
  279. package/icons/aws/simple-storage-service.js +8 -8
  280. package/icons/aws/site-to-site-vpn.js +9 -9
  281. package/icons/aws/snowball-edge.js +4 -4
  282. package/icons/aws/snowball.js +5 -5
  283. package/icons/aws/snowcone.js +10 -10
  284. package/icons/aws/snowmobile.js +5 -5
  285. package/icons/aws/step-functions.js +5 -5
  286. package/icons/aws/storage-gateway.js +10 -10
  287. package/icons/aws/sumerian.js +4 -4
  288. package/icons/aws/supply-chain.js +7 -7
  289. package/icons/aws/support.js +2 -2
  290. package/icons/aws/systems-manager.js +10 -10
  291. package/icons/aws/tensor-flow-on-aws.js +5 -5
  292. package/icons/aws/textract.js +10 -10
  293. package/icons/aws/thinkbox-deadline.js +7 -7
  294. package/icons/aws/thinkbox-frost.js +4 -4
  295. package/icons/aws/thinkbox-krakatoa.js +10 -10
  296. package/icons/aws/thinkbox-sequoia.js +2 -2
  297. package/icons/aws/thinkbox-stoke.js +2 -2
  298. package/icons/aws/thinkbox-xmesh.js +2 -2
  299. package/icons/aws/timestream.js +7 -7
  300. package/icons/aws/tools-and-sdks.js +5 -5
  301. package/icons/aws/torch-serve.js +10 -10
  302. package/icons/aws/training-certification.js +5 -5
  303. package/icons/aws/transcribe.js +5 -5
  304. package/icons/aws/transfer-family.js +5 -5
  305. package/icons/aws/transit-gateway.js +7 -7
  306. package/icons/aws/translate.js +10 -10
  307. package/icons/aws/trusted-advisor.js +5 -5
  308. package/icons/aws/verified-access.js +7 -7
  309. package/icons/aws/verified-permissions.js +5 -5
  310. package/icons/aws/virtual-private-cloud.js +2 -2
  311. package/icons/aws/vmware-cloud-on-aws.js +5 -5
  312. package/icons/aws/vpc-lattice.js +5 -5
  313. package/icons/aws/waf.js +5 -5
  314. package/icons/aws/wavelength.js +6 -6
  315. package/icons/aws/well-architected-tool.js +5 -5
  316. package/icons/aws/wickr.js +2 -2
  317. package/icons/aws/work-docs-sdk.js +5 -5
  318. package/icons/aws/work-docs.js +5 -5
  319. package/icons/aws/work-link.js +2 -2
  320. package/icons/aws/work-mail.js +5 -5
  321. package/icons/aws/work-spaces-family.js +5 -5
  322. package/icons/aws/x-ray.js +7 -7
  323. package/icons/azure/abs-member.js +24 -13
  324. package/icons/azure/active-directory-connect-health.js +39 -22
  325. package/icons/azure/activity-log.js +5 -5
  326. package/icons/azure/administrative-units.js +43 -21
  327. package/icons/azure/advisor.js +5 -5
  328. package/icons/azure/ai-studio.js +6 -6
  329. package/icons/azure/aks-istio.js +55 -22
  330. package/icons/azure/alerts.js +12 -12
  331. package/icons/azure/all-resources.js +5 -5
  332. package/icons/azure/analysis-services.js +57 -24
  333. package/icons/azure/anomaly-detector.js +18 -7
  334. package/icons/azure/api-center.js +21 -10
  335. package/icons/azure/api-connections.js +42 -20
  336. package/icons/azure/api-management-services.js +42 -20
  337. package/icons/azure/api-proxy.js +7 -7
  338. package/icons/azure/app-compliance-automation.js +29 -18
  339. package/icons/azure/app-configuration.js +21 -10
  340. package/icons/azure/app-registrations.js +19 -19
  341. package/icons/azure/app-service-certificates.js +21 -10
  342. package/icons/azure/app-service-domains.js +5 -5
  343. package/icons/azure/app-service-environments.js +20 -9
  344. package/icons/azure/app-service-plans.js +45 -23
  345. package/icons/azure/app-services.js +51 -29
  346. package/icons/azure/app-space-component.js +5 -5
  347. package/icons/azure/app-space.js +9 -9
  348. package/icons/azure/applens.js +11 -11
  349. package/icons/azure/application-gateway-containers.js +65 -44
  350. package/icons/azure/application-gateways.js +47 -15
  351. package/icons/azure/application-group.js +5 -5
  352. package/icons/azure/application-insights.js +27 -16
  353. package/icons/azure/application-security-groups.js +23 -12
  354. package/icons/azure/aquila.js +42 -42
  355. package/icons/azure/arc-data-services.js +21 -10
  356. package/icons/azure/arc-kubernetes.js +109 -43
  357. package/icons/azure/arc-machines.js +5 -5
  358. package/icons/azure/arc-sql-managed-instance.js +34 -13
  359. package/icons/azure/arc-sql-server.js +9 -9
  360. package/icons/azure/atm-multistack.js +2 -2
  361. package/icons/azure/auto-scale.js +23 -12
  362. package/icons/azure/automanaged-vm.js +18 -18
  363. package/icons/azure/automation-accounts.js +4 -4
  364. package/icons/azure/availability-sets.js +35 -13
  365. package/icons/azure/avs-vm.js +6 -6
  366. package/icons/azure/azure-a.js +10 -10
  367. package/icons/azure/azure-ad-b2c.js +34 -34
  368. package/icons/azure/azure-api-for-fhir.js +21 -10
  369. package/icons/azure/azure-applied-ai-services.js +48 -27
  370. package/icons/azure/azure-arc.js +29 -29
  371. package/icons/azure/azure-attestation.js +18 -18
  372. package/icons/azure/azure-backup-center.js +7 -7
  373. package/icons/azure/azure-chaos-studio.js +62 -28
  374. package/icons/azure/azure-cloud-shell.js +24 -13
  375. package/icons/azure/azure-communication-services.js +40 -18
  376. package/icons/azure/azure-communications-gateway.js +16 -5
  377. package/icons/azure/azure-compute-galleries.js +20 -9
  378. package/icons/azure/azure-cosmos-db.js +16 -10
  379. package/icons/azure/azure-data-catalog.js +41 -19
  380. package/icons/azure/azure-data-explorer-clusters.js +74 -30
  381. package/icons/azure/azure-database-maria-db-server.js +29 -18
  382. package/icons/azure/azure-database-migration-services.js +45 -24
  383. package/icons/azure/azure-database-my-sql-server.js +21 -10
  384. package/icons/azure/azure-database-postgre-sql-server-group.js +2 -2
  385. package/icons/azure/azure-database-postgre-sql-server.js +4 -4
  386. package/icons/azure/azure-databox-gateway.js +19 -8
  387. package/icons/azure/azure-deployment-environments.js +38 -21
  388. package/icons/azure/azure-dev-ops.js +4 -4
  389. package/icons/azure/azure-dev-tunnels.js +42 -14
  390. package/icons/azure/azure-edge-hardware-center.js +23 -12
  391. package/icons/azure/azure-experimentation-studio.js +27 -16
  392. package/icons/azure/azure-fileshares.js +20 -20
  393. package/icons/azure/azure-firewall-manager.js +34 -23
  394. package/icons/azure/azure-hcp-cache.js +14 -14
  395. package/icons/azure/azure-hpc-workbenches.js +80 -36
  396. package/icons/azure/azure-hybrid-center.js +19 -8
  397. package/icons/azure/azure-information-protection.js +73 -29
  398. package/icons/azure/azure-io-t-operations.js +19 -8
  399. package/icons/azure/azure-lighthouse.js +5 -5
  400. package/icons/azure/azure-load-testing.js +38 -16
  401. package/icons/azure/azure-managed-grafana.js +5 -5
  402. package/icons/azure/azure-maps-accounts.js +11 -11
  403. package/icons/azure/azure-media-service.js +48 -31
  404. package/icons/azure/azure-migrate.js +24 -13
  405. package/icons/azure/azure-monitor-dashboard.js +16 -5
  406. package/icons/azure/azure-monitor-pipeline.js +76 -32
  407. package/icons/azure/azure-monitors-for-sap-solutions.js +45 -23
  408. package/icons/azure/azure-net-app-files.js +6 -6
  409. package/icons/azure/azure-network-function-manager-functions.js +73 -20
  410. package/icons/azure/azure-network-function-manager.js +64 -31
  411. package/icons/azure/azure-object-understanding.js +19 -8
  412. package/icons/azure/azure-open-ai.js +10 -10
  413. package/icons/azure/azure-operator-5g-core.js +49 -27
  414. package/icons/azure/azure-operator-insights.js +19 -8
  415. package/icons/azure/azure-operator-nexus.js +67 -34
  416. package/icons/azure/azure-operator-service-manager.js +21 -10
  417. package/icons/azure/azure-orbital.js +14 -14
  418. package/icons/azure/azure-programmable-connectivity.js +57 -34
  419. package/icons/azure/azure-purview-accounts.js +75 -31
  420. package/icons/azure/azure-quotas.js +25 -14
  421. package/icons/azure/azure-sentinel.js +4 -4
  422. package/icons/azure/azure-service-bus.js +19 -8
  423. package/icons/azure/azure-sphere.js +34 -23
  424. package/icons/azure/azure-spring-apps.js +75 -31
  425. package/icons/azure/azure-sql-edge.js +32 -21
  426. package/icons/azure/azure-sql-server-stretch-databases.js +55 -27
  427. package/icons/azure/azure-sql-vm.js +8 -8
  428. package/icons/azure/azure-sql.js +11 -11
  429. package/icons/azure/azure-stack-edge.js +23 -12
  430. package/icons/azure/azure-stack-hci-sizer.js +54 -21
  431. package/icons/azure/azure-stack.js +4 -4
  432. package/icons/azure/azure-storage-mover.js +89 -27
  433. package/icons/azure/azure-support-center-blue.js +39 -17
  434. package/icons/azure/azure-sustainability.js +53 -20
  435. package/icons/azure/azure-synapse-analytics.js +31 -20
  436. package/icons/azure/azure-video-indexer.js +42 -20
  437. package/icons/azure/azure-virtual-desktop.js +2 -2
  438. package/icons/azure/azure-vmware-solution.js +40 -18
  439. package/icons/azure/azure-workbooks.js +28 -22
  440. package/icons/azure/azurite.js +7 -7
  441. package/icons/azure/backlog.js +24 -24
  442. package/icons/azure/backup-vault.js +39 -17
  443. package/icons/azure/bare-metal-infrastructure.js +42 -20
  444. package/icons/azure/bastions.js +7 -7
  445. package/icons/azure/batch-accounts.js +4 -4
  446. package/icons/azure/batch-ai.js +7 -7
  447. package/icons/azure/biz-talk.js +11 -11
  448. package/icons/azure/blob-block.js +5 -5
  449. package/icons/azure/blob-page.js +2 -2
  450. package/icons/azure/blockchain-applications.js +21 -10
  451. package/icons/azure/blueprints.js +4 -4
  452. package/icons/azure/bot-services.js +6 -6
  453. package/icons/azure/branch.js +16 -5
  454. package/icons/azure/browser.js +6 -6
  455. package/icons/azure/bug.js +5 -5
  456. package/icons/azure/builds.js +7 -7
  457. package/icons/azure/cache-redis.js +11 -11
  458. package/icons/azure/cache.js +4 -4
  459. package/icons/azure/capacity.js +4 -4
  460. package/icons/azure/cdn-profiles.js +18 -7
  461. package/icons/azure/central-service-instance-for-sap.js +18 -7
  462. package/icons/azure/ceres.js +16 -16
  463. package/icons/azure/change-analysis.js +28 -28
  464. package/icons/azure/client-apps.js +4 -4
  465. package/icons/azure/cloud-services-classic.js +21 -10
  466. package/icons/azure/cloud-services-extended-support.js +50 -22
  467. package/icons/azure/cloud-test.js +7 -7
  468. package/icons/azure/code-optimization.js +13 -13
  469. package/icons/azure/code.js +30 -30
  470. package/icons/azure/cognitive-search.js +4 -4
  471. package/icons/azure/cognitive-services-decisions.js +74 -29
  472. package/icons/azure/cognitive-services.js +4 -4
  473. package/icons/azure/collaborative-service.js +63 -18
  474. package/icons/azure/commit.js +9 -9
  475. package/icons/azure/community-images.js +51 -18
  476. package/icons/azure/compliance-center.js +35 -13
  477. package/icons/azure/compliance.js +5 -5
  478. package/icons/azure/compute-fleet.js +19 -8
  479. package/icons/azure/computer-vision.js +20 -9
  480. package/icons/azure/conditional-access.js +5 -5
  481. package/icons/azure/confidential-ledgers.js +59 -26
  482. package/icons/azure/connected-cache.js +56 -34
  483. package/icons/azure/connected-vehicle-platform.js +77 -32
  484. package/icons/azure/connections.js +8 -8
  485. package/icons/azure/container-apps-environments.js +40 -18
  486. package/icons/azure/container-instances.js +4 -4
  487. package/icons/azure/container-registries.js +20 -9
  488. package/icons/azure/container-services-deprecated.js +125 -48
  489. package/icons/azure/content-moderators.js +35 -13
  490. package/icons/azure/content-safety.js +21 -10
  491. package/icons/azure/controls-horizontal.js +8 -8
  492. package/icons/azure/controls.js +26 -26
  493. package/icons/azure/cost-alerts.js +12 -12
  494. package/icons/azure/cost-analysis.js +4 -4
  495. package/icons/azure/cost-budgets.js +14 -14
  496. package/icons/azure/cost-export.js +19 -8
  497. package/icons/azure/cost-management-and-billing.js +20 -10
  498. package/icons/azure/cost-management.js +18 -7
  499. package/icons/azure/custom-ip-prefix.js +22 -5
  500. package/icons/azure/custom-vision.js +19 -8
  501. package/icons/azure/customer-lockbox-for-microsoft-azure.js +43 -21
  502. package/icons/azure/dashboard-hub.js +68 -35
  503. package/icons/azure/dashboard.js +5 -5
  504. package/icons/azure/data-box.js +5 -5
  505. package/icons/azure/data-collection-rules.js +35 -13
  506. package/icons/azure/data-factories.js +11 -5
  507. package/icons/azure/data-lake-analytics.js +19 -8
  508. package/icons/azure/data-lake-storage-gen1.js +28 -17
  509. package/icons/azure/data-lake-store-gen1.js +23 -12
  510. package/icons/azure/data-share-invitations.js +26 -15
  511. package/icons/azure/data-shares.js +22 -22
  512. package/icons/azure/database-instance-for-sap.js +36 -25
  513. package/icons/azure/ddo-s-protection-plans.js +18 -7
  514. package/icons/azure/dedicated-hsm.js +21 -10
  515. package/icons/azure/defender-cm-local-manager.js +78 -34
  516. package/icons/azure/defender-dcs-controller.js +60 -27
  517. package/icons/azure/defender-distributer-control-system.js +41 -19
  518. package/icons/azure/defender-engineering-station.js +78 -34
  519. package/icons/azure/defender-external-management.js +88 -44
  520. package/icons/azure/defender-freezer-monitor.js +137 -71
  521. package/icons/azure/defender-historian.js +5 -5
  522. package/icons/azure/defender-hmi.js +28 -17
  523. package/icons/azure/defender-industrial-packaging-system.js +49 -27
  524. package/icons/azure/defender-industrial-printer.js +33 -16
  525. package/icons/azure/defender-industrial-robot.js +122 -56
  526. package/icons/azure/defender-industrial-scale-system.js +42 -20
  527. package/icons/azure/defender-marquee.js +54 -24
  528. package/icons/azure/defender-meter.js +89 -34
  529. package/icons/azure/defender-plc.js +32 -21
  530. package/icons/azure/defender-pneumatic-device.js +46 -24
  531. package/icons/azure/defender-programable-board.js +87 -43
  532. package/icons/azure/defender-relay.js +30 -12
  533. package/icons/azure/defender-robot-controller.js +72 -28
  534. package/icons/azure/defender-rtu.js +5 -5
  535. package/icons/azure/defender-sensor.js +23 -12
  536. package/icons/azure/defender-slot.js +2 -2
  537. package/icons/azure/defender-web-guiding-system.js +188 -89
  538. package/icons/azure/detonation.js +22 -11
  539. package/icons/azure/dev-console.js +6 -6
  540. package/icons/azure/dev-ops-starter.js +7 -7
  541. package/icons/azure/dev-test-labs.js +7 -7
  542. package/icons/azure/device-compliance.js +46 -24
  543. package/icons/azure/device-configuration.js +56 -23
  544. package/icons/azure/device-enrollment.js +59 -27
  545. package/icons/azure/device-provisioning-services.js +23 -12
  546. package/icons/azure/device-security-apple.js +20 -9
  547. package/icons/azure/device-security-google.js +19 -8
  548. package/icons/azure/device-security-windows.js +20 -9
  549. package/icons/azure/device-update-io-t-hub.js +18 -7
  550. package/icons/azure/devices.js +23 -23
  551. package/icons/azure/diagnostics-settings.js +20 -9
  552. package/icons/azure/digital-twins.js +58 -25
  553. package/icons/azure/disk-encryption-sets.js +9 -9
  554. package/icons/azure/disk-pool.js +7 -7
  555. package/icons/azure/disks-classic.js +46 -35
  556. package/icons/azure/disks-snapshots.js +49 -27
  557. package/icons/azure/disks.js +5 -5
  558. package/icons/azure/dns-private-resolver.js +19 -8
  559. package/icons/azure/dns-security-policy.js +6 -6
  560. package/icons/azure/dns-zones.js +5 -5
  561. package/icons/azure/download.js +5 -5
  562. package/icons/azure/e-books.js +5 -5
  563. package/icons/azure/edge-management.js +35 -24
  564. package/icons/azure/education.js +2 -2
  565. package/icons/azure/elastic-job-agents.js +25 -14
  566. package/icons/azure/elastic-san.js +2 -2
  567. package/icons/azure/endpoint-analytics.js +23 -12
  568. package/icons/azure/enterprise-applications.js +42 -31
  569. package/icons/azure/entra-connect-health.js +33 -16
  570. package/icons/azure/entra-connect-sync.js +28 -28
  571. package/icons/azure/entra-connect.js +10 -10
  572. package/icons/azure/entra-domain-services.js +36 -30
  573. package/icons/azure/entra-global-secure-access.js +65 -26
  574. package/icons/azure/entra-id-protection.js +36 -25
  575. package/icons/azure/entra-identity-custom-roles.js +7 -7
  576. package/icons/azure/entra-identity-licenses.js +64 -31
  577. package/icons/azure/entra-identity-roles-and-administrators.js +44 -22
  578. package/icons/azure/entra-internet-access.js +69 -36
  579. package/icons/azure/entra-managed-identities.js +17 -11
  580. package/icons/azure/entra-private-access.js +77 -33
  581. package/icons/azure/entra-privleged-identity-management.js +39 -33
  582. package/icons/azure/entra-verified-id.js +39 -17
  583. package/icons/azure/error.js +9 -9
  584. package/icons/azure/event-grid-domains.js +24 -14
  585. package/icons/azure/event-grid-subscriptions.js +43 -33
  586. package/icons/azure/event-grid-topics.js +33 -11
  587. package/icons/azure/exchange-access.js +6 -6
  588. package/icons/azure/exchange-on-premises-access.js +22 -11
  589. package/icons/azure/express-route-circuits.js +44 -22
  590. package/icons/azure/express-route-direct.js +19 -8
  591. package/icons/azure/express-route-traffic-collector.js +30 -19
  592. package/icons/azure/extended-security-updates.js +18 -7
  593. package/icons/azure/extensions.js +11 -11
  594. package/icons/azure/face-apis.js +4 -4
  595. package/icons/azure/feature-previews.js +11 -11
  596. package/icons/azure/fhir-service.js +20 -20
  597. package/icons/azure/file.js +5 -5
  598. package/icons/azure/files.js +2 -2
  599. package/icons/azure/firewalls.js +4 -4
  600. package/icons/azure/folder-blank.js +18 -7
  601. package/icons/azure/folder-website.js +80 -41
  602. package/icons/azure/form-recognizers.js +5 -5
  603. package/icons/azure/free-services.js +7 -7
  604. package/icons/azure/front-door-and-cdn-profiles.js +19 -8
  605. package/icons/azure/ftp.js +5 -5
  606. package/icons/azure/function-apps.js +17 -17
  607. package/icons/azure/gear.js +11 -11
  608. package/icons/azure/genomics-accounts.js +23 -12
  609. package/icons/azure/genomics.js +8 -8
  610. package/icons/azure/globe-error.js +14 -14
  611. package/icons/azure/globe-success.js +5 -5
  612. package/icons/azure/globe-warning.js +5 -5
  613. package/icons/azure/groups.js +18 -18
  614. package/icons/azure/guide.js +6 -6
  615. package/icons/azure/hd-insight-clusters.js +54 -21
  616. package/icons/azure/hdi-aks-cluster.js +7 -7
  617. package/icons/azure/heart.js +6 -6
  618. package/icons/azure/help-and-support.js +37 -15
  619. package/icons/azure/host-groups.js +13 -13
  620. package/icons/azure/host-pools.js +6 -6
  621. package/icons/azure/hosts.js +13 -13
  622. package/icons/azure/ic-m-troubleshooting.js +5 -5
  623. package/icons/azure/identity-governance.js +23 -12
  624. package/icons/azure/identity-multi-factor-authentication.js +58 -12
  625. package/icons/azure/image-definitions.js +21 -10
  626. package/icons/azure/image-templates.js +18 -7
  627. package/icons/azure/image-versions.js +29 -18
  628. package/icons/azure/image.js +2 -2
  629. package/icons/azure/images.js +9 -9
  630. package/icons/azure/immersive-readers.js +37 -15
  631. package/icons/azure/import-export-jobs.js +10 -10
  632. package/icons/azure/industrial-io-t.js +75 -31
  633. package/icons/azure/information.js +5 -5
  634. package/icons/azure/infrastructure-backup.js +51 -29
  635. package/icons/azure/input-output.js +6 -6
  636. package/icons/azure/instance-pools.js +22 -11
  637. package/icons/azure/integration-accounts.js +35 -13
  638. package/icons/azure/integration-environments.js +5 -5
  639. package/icons/azure/integration-service-environments.js +58 -26
  640. package/icons/azure/internet-analyzer-profiles.js +23 -12
  641. package/icons/azure/intune-app-protection.js +50 -17
  642. package/icons/azure/intune-for-education.js +48 -15
  643. package/icons/azure/intune-trends.js +29 -18
  644. package/icons/azure/intune.js +9 -9
  645. package/icons/azure/io-t-edge.js +15 -15
  646. package/icons/azure/io-t-hub.js +2 -2
  647. package/icons/azure/ip-address-manager.js +31 -20
  648. package/icons/azure/ip-groups.js +11 -5
  649. package/icons/azure/journey-hub.js +21 -21
  650. package/icons/azure/key-vaults.js +6 -6
  651. package/icons/azure/keys.js +7 -7
  652. package/icons/azure/kubernetes-services.js +126 -49
  653. package/icons/azure/lab-accounts.js +37 -15
  654. package/icons/azure/lab-services.js +7 -7
  655. package/icons/azure/language-understanding.js +20 -9
  656. package/icons/azure/language.js +10 -10
  657. package/icons/azure/launch-portal.js +19 -8
  658. package/icons/azure/learn.js +4 -4
  659. package/icons/azure/load-balancer-hub.js +20 -9
  660. package/icons/azure/load-balancers.js +4 -4
  661. package/icons/azure/load-test.js +27 -16
  662. package/icons/azure/load-testing.js +7 -7
  663. package/icons/azure/local-network-gateways.js +15 -4
  664. package/icons/azure/location.js +5 -5
  665. package/icons/azure/log-analytics-query-pack.js +21 -10
  666. package/icons/azure/log-analytics-workspaces.js +40 -18
  667. package/icons/azure/log-streaming.js +20 -9
  668. package/icons/azure/logic-apps-custom-connector.js +57 -24
  669. package/icons/azure/logic-apps.js +23 -12
  670. package/icons/azure/machine-learning-studio-classic-web-services.js +24 -13
  671. package/icons/azure/machine-learning-studio-web-service-plans.js +52 -30
  672. package/icons/azure/machine-learning-studio-workspaces.js +24 -13
  673. package/icons/azure/machine-learning.js +5 -5
  674. package/icons/azure/machines-azure-arc.js +12 -12
  675. package/icons/azure/maintenance-configuration.js +7 -7
  676. package/icons/azure/managed-applications-center.js +24 -13
  677. package/icons/azure/managed-database.js +47 -25
  678. package/icons/azure/managed-desktop.js +17 -17
  679. package/icons/azure/managed-file-shares.js +21 -21
  680. package/icons/azure/managed-identities.js +40 -18
  681. package/icons/azure/managed-instance-apache-cassandra.js +83 -32
  682. package/icons/azure/managed-service-fabric.js +30 -19
  683. package/icons/azure/management-groups.js +18 -7
  684. package/icons/azure/management-portal.js +19 -13
  685. package/icons/azure/marketplace-management.js +21 -10
  686. package/icons/azure/marketplace.js +17 -17
  687. package/icons/azure/med-tech-service.js +49 -27
  688. package/icons/azure/media-file.js +15 -15
  689. package/icons/azure/media.js +9 -9
  690. package/icons/azure/mesh-applications.js +7 -7
  691. package/icons/azure/metrics-advisor.js +18 -7
  692. package/icons/azure/metrics.js +11 -11
  693. package/icons/azure/microsoft-defender-easm.js +11 -11
  694. package/icons/azure/microsoft-defender-for-cloud.js +25 -14
  695. package/icons/azure/microsoft-defender-for-io-t.js +19 -8
  696. package/icons/azure/microsoft-dev-box.js +41 -41
  697. package/icons/azure/mindaro.js +20 -20
  698. package/icons/azure/mission-landing-zone.js +5 -5
  699. package/icons/azure/mobile-engagement.js +34 -23
  700. package/icons/azure/mobile-networks.js +18 -7
  701. package/icons/azure/mobile.js +7 -7
  702. package/icons/azure/modular-data-center.js +42 -20
  703. package/icons/azure/module.js +2 -2
  704. package/icons/azure/monitor-health-models.js +57 -24
  705. package/icons/azure/monitor.js +6 -6
  706. package/icons/azure/multi-tenancy.js +51 -18
  707. package/icons/azure/multifactor-authentication.js +16 -16
  708. package/icons/azure/my-customers.js +18 -18
  709. package/icons/azure/nat.js +13 -2
  710. package/icons/azure/network-interfaces.js +18 -7
  711. package/icons/azure/network-managers.js +18 -7
  712. package/icons/azure/network-security-groups.js +22 -11
  713. package/icons/azure/network-security-perimeters.js +40 -18
  714. package/icons/azure/network-watcher.js +2 -2
  715. package/icons/azure/notification-hub-namespaces.js +18 -7
  716. package/icons/azure/notification-hubs.js +4 -4
  717. package/icons/azure/offers.js +6 -6
  718. package/icons/azure/on-premises-data-gateways.js +18 -7
  719. package/icons/azure/open-supply-chain-platform.js +90 -33
  720. package/icons/azure/operation-log-classic.js +19 -8
  721. package/icons/azure/oracle-database.js +40 -18
  722. package/icons/azure/os-images-classic.js +37 -15
  723. package/icons/azure/osconfig.js +23 -12
  724. package/icons/azure/partner-namespace.js +5 -5
  725. package/icons/azure/partner-registration.js +35 -13
  726. package/icons/azure/partner-topic.js +20 -9
  727. package/icons/azure/peering-service.js +5 -5
  728. package/icons/azure/peerings.js +20 -9
  729. package/icons/azure/personalizers.js +69 -25
  730. package/icons/azure/plans.js +4 -4
  731. package/icons/azure/policy.js +2 -2
  732. package/icons/azure/power-bi-embedded.js +21 -21
  733. package/icons/azure/power-platform.js +22 -22
  734. package/icons/azure/power-up.js +2 -2
  735. package/icons/azure/power.js +5 -5
  736. package/icons/azure/powershell.js +14 -14
  737. package/icons/azure/preview-features.js +44 -22
  738. package/icons/azure/private-endpoints.js +34 -23
  739. package/icons/azure/private-link-service.js +7 -7
  740. package/icons/azure/private-link-services.js +24 -24
  741. package/icons/azure/private-link.js +7 -7
  742. package/icons/azure/production-ready-database.js +5 -5
  743. package/icons/azure/public-ip-addresses-classic.js +33 -16
  744. package/icons/azure/public-ip-addresses.js +15 -15
  745. package/icons/azure/public-ip-prefixes.js +59 -27
  746. package/icons/azure/qn-a-makers.js +21 -10
  747. package/icons/azure/quickstart-center.js +50 -28
  748. package/icons/azure/recent.js +23 -23
  749. package/icons/azure/recovery-services-vaults.js +44 -22
  750. package/icons/azure/region-management.js +4 -4
  751. package/icons/azure/relays.js +13 -13
  752. package/icons/azure/remote-rendering.js +25 -25
  753. package/icons/azure/reservations.js +20 -20
  754. package/icons/azure/reserved-ip-addresses-classic.js +27 -10
  755. package/icons/azure/resource-explorer.js +16 -16
  756. package/icons/azure/resource-graph-explorer.js +54 -21
  757. package/icons/azure/resource-group-list.js +7 -7
  758. package/icons/azure/resource-guard.js +6 -6
  759. package/icons/azure/resource-linked.js +23 -12
  760. package/icons/azure/resource-management-private-link.js +25 -8
  761. package/icons/azure/resources-provider.js +2 -2
  762. package/icons/azure/restore-points-collections.js +57 -24
  763. package/icons/azure/restore-points.js +57 -24
  764. package/icons/azure/route-filters.js +4 -4
  765. package/icons/azure/route-tables.js +40 -18
  766. package/icons/azure/rtos.js +8 -8
  767. package/icons/azure/savings-plans.js +37 -15
  768. package/icons/azure/scheduler-job-collections.js +2 -2
  769. package/icons/azure/scheduler.js +24 -24
  770. package/icons/azure/scvmm-management-servers.js +24 -13
  771. package/icons/azure/search-grid.js +5 -5
  772. package/icons/azure/search.js +4 -4
  773. package/icons/azure/security-baselines.js +20 -9
  774. package/icons/azure/security.js +4 -4
  775. package/icons/azure/send-grid-accounts.js +29 -12
  776. package/icons/azure/server-farm.js +38 -27
  777. package/icons/azure/serverless-search.js +33 -22
  778. package/icons/azure/service-catalog-mad.js +25 -8
  779. package/icons/azure/service-endpoint-policies.js +31 -20
  780. package/icons/azure/service-fabric-clusters.js +69 -25
  781. package/icons/azure/service-health.js +21 -10
  782. package/icons/azure/service-providers.js +54 -21
  783. package/icons/azure/shared-image-galleries.js +19 -8
  784. package/icons/azure/signal-r.js +7 -7
  785. package/icons/azure/software-as-a-service.js +41 -19
  786. package/icons/azure/software-updates.js +11 -11
  787. package/icons/azure/solutions.js +4 -4
  788. package/icons/azure/sonic-dash.js +35 -13
  789. package/icons/azure/spatial-anchor-accounts.js +73 -29
  790. package/icons/azure/speech-services.js +19 -8
  791. package/icons/azure/spot-vm.js +11 -11
  792. package/icons/azure/spot-vmss.js +23 -12
  793. package/icons/azure/sql-data-warehouses.js +50 -22
  794. package/icons/azure/sql-database.js +28 -17
  795. package/icons/azure/sql-elastic-pools.js +17 -6
  796. package/icons/azure/sql-managed-instance.js +46 -24
  797. package/icons/azure/sql-server-registries.js +42 -31
  798. package/icons/azure/sql-server.js +5 -5
  799. package/icons/azure/ssd.js +11 -5
  800. package/icons/azure/ssh-keys.js +9 -9
  801. package/icons/azure/ssis-lift-and-shift-ir.js +19 -19
  802. package/icons/azure/stack-hci-premium.js +99 -33
  803. package/icons/azure/static-apps.js +6 -6
  804. package/icons/azure/stor-simple-data-managers.js +2 -2
  805. package/icons/azure/stor-simple-device-managers.js +30 -19
  806. package/icons/azure/storage-accounts-classic.js +27 -10
  807. package/icons/azure/storage-accounts.js +5 -5
  808. package/icons/azure/storage-actions.js +44 -22
  809. package/icons/azure/storage-azure-files.js +26 -9
  810. package/icons/azure/storage-container.js +11 -5
  811. package/icons/azure/storage-explorer.js +29 -18
  812. package/icons/azure/storage-functions.js +26 -9
  813. package/icons/azure/storage-queue.js +8 -2
  814. package/icons/azure/storage-sync-services.js +42 -20
  815. package/icons/azure/stream-analytics-jobs.js +5 -5
  816. package/icons/azure/subnet.js +15 -15
  817. package/icons/azure/subscriptions.js +5 -5
  818. package/icons/azure/system-topic.js +107 -28
  819. package/icons/azure/table.js +5 -5
  820. package/icons/azure/tag.js +4 -4
  821. package/icons/azure/tags.js +5 -5
  822. package/icons/azure/targets-management.js +21 -10
  823. package/icons/azure/template-specs.js +5 -5
  824. package/icons/azure/templates.js +4 -4
  825. package/icons/azure/tenant-properties.js +60 -21
  826. package/icons/azure/tenant-status.js +7 -7
  827. package/icons/azure/test-base.js +7 -7
  828. package/icons/azure/tfs-vc-repository.js +87 -32
  829. package/icons/azure/time-series-data-sets.js +35 -24
  830. package/icons/azure/time-series-insights-access-policies.js +15 -15
  831. package/icons/azure/time-series-insights-environments.js +13 -13
  832. package/icons/azure/time-series-insights-event-sources.js +36 -15
  833. package/icons/azure/toolbox.js +5 -5
  834. package/icons/azure/traffic-manager-profiles.js +23 -12
  835. package/icons/azure/translator-text.js +9 -9
  836. package/icons/azure/troubleshoot.js +9 -9
  837. package/icons/azure/universal-print.js +57 -18
  838. package/icons/azure/update-management-center.js +106 -40
  839. package/icons/azure/updates.js +6 -6
  840. package/icons/azure/user-privacy.js +33 -22
  841. package/icons/azure/user-settings.js +40 -18
  842. package/icons/azure/user-subscriptions.js +46 -24
  843. package/icons/azure/users.js +14 -14
  844. package/icons/azure/verifiable-credentials.js +32 -32
  845. package/icons/azure/verification-as-a-service.js +13 -13
  846. package/icons/azure/versions.js +18 -18
  847. package/icons/azure/video-analyzers.js +6 -6
  848. package/icons/azure/virtual-clusters.js +41 -19
  849. package/icons/azure/virtual-enclaves.js +4 -4
  850. package/icons/azure/virtual-instance-for-sap.js +27 -16
  851. package/icons/azure/virtual-machine.js +35 -13
  852. package/icons/azure/virtual-machines-classic.js +37 -15
  853. package/icons/azure/virtual-network-gateways.js +23 -12
  854. package/icons/azure/virtual-networks-classic.js +44 -22
  855. package/icons/azure/virtual-networks.js +46 -24
  856. package/icons/azure/virtual-router.js +2 -2
  857. package/icons/azure/virtual-visits-builder.js +17 -11
  858. package/icons/azure/virtual-wan-hub.js +26 -9
  859. package/icons/azure/virtual-wans.js +4 -4
  860. package/icons/azure/vm-app-definitions.js +7 -7
  861. package/icons/azure/vm-app-versions.js +59 -26
  862. package/icons/azure/vm-image-version.js +77 -33
  863. package/icons/azure/vm-images-classic.js +37 -15
  864. package/icons/azure/vm-scale-sets.js +34 -12
  865. package/icons/azure/wac-installer.js +31 -14
  866. package/icons/azure/wac.js +9 -9
  867. package/icons/azure/web-app-database.js +63 -46
  868. package/icons/azure/web-application-firewall-policies-waf.js +16 -10
  869. package/icons/azure/web-jobs.js +16 -16
  870. package/icons/azure/web-slots.js +4 -4
  871. package/icons/azure/web-test.js +54 -37
  872. package/icons/azure/website-power.js +55 -27
  873. package/icons/azure/website-staging.js +4 -4
  874. package/icons/azure/windows-notification-services.js +34 -23
  875. package/icons/azure/windows10-core-services.js +24 -13
  876. package/icons/azure/workbooks.js +2 -2
  877. package/icons/azure/worker-container-app.js +34 -12
  878. package/icons/azure/workflow.js +33 -22
  879. package/icons/azure/workspace-gateway.js +47 -25
  880. package/icons/azure/workspaces.js +4 -4
  881. package/icons/gcp/advanced-solutions-lab.js +72 -36
  882. package/icons/gcp/ai-hub.js +8 -8
  883. package/icons/gcp/api-analytics.js +6 -6
  884. package/icons/gcp/api-monetization.js +11 -11
  885. package/icons/gcp/apigee-api-platform.js +11 -11
  886. package/icons/gcp/app-engine.js +9 -9
  887. package/icons/gcp/assured-workloads.js +19 -13
  888. package/icons/gcp/auto-ml-tables.js +2 -2
  889. package/icons/gcp/auto-ml-translation.js +4 -4
  890. package/icons/gcp/auto-ml-video-intelligence.js +5 -5
  891. package/icons/gcp/auto-ml-vision.js +8 -8
  892. package/icons/gcp/auto-ml.js +5 -5
  893. package/icons/gcp/big-query.js +12 -12
  894. package/icons/gcp/bigtable.js +19 -19
  895. package/icons/gcp/cloud-apis.js +11 -11
  896. package/icons/gcp/cloud-armor.js +13 -13
  897. package/icons/gcp/cloud-audit-logs.js +31 -16
  898. package/icons/gcp/cloud-build.js +5 -5
  899. package/icons/gcp/cloud-cdn.js +16 -16
  900. package/icons/gcp/cloud-code.js +10 -10
  901. package/icons/gcp/cloud-composer.js +15 -9
  902. package/icons/gcp/cloud-data-fusion.js +8 -8
  903. package/icons/gcp/cloud-deployment-manager.js +13 -13
  904. package/icons/gcp/cloud-dns.js +13 -13
  905. package/icons/gcp/cloud-endpoints.js +21 -13
  906. package/icons/gcp/cloud-firewall-rules.js +7 -7
  907. package/icons/gcp/cloud-functions.js +37 -17
  908. package/icons/gcp/cloud-gpu.js +7 -7
  909. package/icons/gcp/cloud-healthcare-api.js +42 -9
  910. package/icons/gcp/cloud-hsm.js +15 -9
  911. package/icons/gcp/cloud-interconnect.js +11 -11
  912. package/icons/gcp/cloud-jobs-api.js +10 -10
  913. package/icons/gcp/cloud-load-balancing.js +13 -13
  914. package/icons/gcp/cloud-logging.js +30 -14
  915. package/icons/gcp/cloud-monitoring.js +12 -12
  916. package/icons/gcp/cloud-nat.js +12 -12
  917. package/icons/gcp/cloud-natural-language-api.js +34 -11
  918. package/icons/gcp/cloud-network.js +19 -13
  919. package/icons/gcp/cloud-optimization-ai-fleet-routing-api.js +32 -20
  920. package/icons/gcp/cloud-routes.js +5 -5
  921. package/icons/gcp/cloud-run.js +7 -7
  922. package/icons/gcp/cloud-scheduler.js +22 -9
  923. package/icons/gcp/cloud-spanner.js +6 -6
  924. package/icons/gcp/cloud-sql.js +9 -9
  925. package/icons/gcp/cloud-storage.js +16 -16
  926. package/icons/gcp/cloud-tasks.js +92 -20
  927. package/icons/gcp/cloud-test-lab.js +13 -13
  928. package/icons/gcp/cloud-tpu.js +64 -26
  929. package/icons/gcp/cloud-vision-api.js +36 -12
  930. package/icons/gcp/cloud-vpn.js +11 -11
  931. package/icons/gcp/compute-engine.js +19 -13
  932. package/icons/gcp/container-registry.js +114 -23
  933. package/icons/gcp/data-catalog.js +11 -11
  934. package/icons/gcp/data-labeling.js +27 -15
  935. package/icons/gcp/data-loss-prevention-api.js +19 -13
  936. package/icons/gcp/data-studio.js +24 -12
  937. package/icons/gcp/dataflow.js +22 -16
  938. package/icons/gcp/datapol.js +41 -20
  939. package/icons/gcp/dataprep.js +8 -8
  940. package/icons/gcp/dataproc.js +14 -14
  941. package/icons/gcp/datastore.js +35 -35
  942. package/icons/gcp/developer-portal.js +7 -7
  943. package/icons/gcp/error-reporting.js +38 -10
  944. package/icons/gcp/filestore.js +15 -7
  945. package/icons/gcp/firestore.js +25 -9
  946. package/icons/gcp/genomics.js +19 -19
  947. package/icons/gcp/google-kubernetes-engine.js +13 -13
  948. package/icons/gcp/identity-aware-proxy.js +12 -12
  949. package/icons/gcp/identity-platform.js +12 -12
  950. package/icons/gcp/iot-edge.js +35 -35
  951. package/icons/gcp/key-access-justifications.js +7 -7
  952. package/icons/gcp/kuberun.js +2 -2
  953. package/icons/gcp/managed-service-for-microsoft-active-directory.js +49 -14
  954. package/icons/gcp/memorystore.js +12 -12
  955. package/icons/gcp/my-cloud.js +5 -5
  956. package/icons/gcp/network-security.js +18 -12
  957. package/icons/gcp/network-tiers.js +44 -14
  958. package/icons/gcp/os-inventory-management.js +7 -7
  959. package/icons/gcp/partner-interconnect.js +12 -12
  960. package/icons/gcp/phishing-protection.js +27 -15
  961. package/icons/gcp/premium-network-tier.js +10 -10
  962. package/icons/gcp/profiler.js +15 -7
  963. package/icons/gcp/pub-sub.js +23 -23
  964. package/icons/gcp/quantum-engine.js +6 -6
  965. package/icons/gcp/quotas.js +32 -16
  966. package/icons/gcp/recommendations-ai.js +48 -16
  967. package/icons/gcp/runtime-config.js +31 -15
  968. package/icons/gcp/security-command-center.js +8 -8
  969. package/icons/gcp/security-health-advisor.js +26 -8
  970. package/icons/gcp/service-discovery.js +34 -24
  971. package/icons/gcp/speech-to-text.js +89 -17
  972. package/icons/gcp/text-to-speech.js +8 -8
  973. package/icons/gcp/tools-for-powershell.js +11 -11
  974. package/icons/gcp/trace.js +11 -11
  975. package/icons/gcp/traffic-director.js +38 -14
  976. package/icons/gcp/transfer-appliance.js +19 -7
  977. package/icons/gcp/virtual-private-cloud.js +21 -15
  978. package/icons/gcp/web-risk.js +43 -15
  979. package/icons/gcp/web-security-scanner.js +10 -10
  980. package/icons/tech/aarch64.js +2 -2
  981. package/icons/tech/ant-design.js +10 -10
  982. package/icons/tech/apache.js +119 -53
  983. package/icons/tech/apple-safari.js +5 -5
  984. package/icons/tech/argo-cd.js +21 -21
  985. package/icons/tech/astro.js +15 -15
  986. package/icons/tech/autodesk-maya.js +140 -51
  987. package/icons/tech/azure-devops.js +2 -2
  988. package/icons/tech/azure-sql-database.js +7 -7
  989. package/icons/tech/azure.js +11 -11
  990. package/icons/tech/bamboo.js +11 -11
  991. package/icons/tech/behance.js +2 -2
  992. package/icons/tech/bitbucket.js +2 -2
  993. package/icons/tech/bootstrap.js +27 -27
  994. package/icons/tech/chrome.js +25 -25
  995. package/icons/tech/clion.js +8 -8
  996. package/icons/tech/cloudflare-workers.js +53 -53
  997. package/icons/tech/confluence.js +11 -11
  998. package/icons/tech/d3js.js +40 -40
  999. package/icons/tech/data-grip.js +38 -38
  1000. package/icons/tech/data-spell.js +32 -32
  1001. package/icons/tech/dropwizard.js +24 -24
  1002. package/icons/tech/eclipse-ceylon.js +4 -4
  1003. package/icons/tech/eclipse-ide.js +31 -25
  1004. package/icons/tech/elixir.js +25 -25
  1005. package/icons/tech/file-zilla.js +19 -8
  1006. package/icons/tech/firefox.js +206 -182
  1007. package/icons/tech/flutter.js +2 -2
  1008. package/icons/tech/gimp.js +55 -43
  1009. package/icons/tech/github-codespaces.js +24 -24
  1010. package/icons/tech/gitpod.js +5 -5
  1011. package/icons/tech/go-land.js +15 -9
  1012. package/icons/tech/go.js +46 -37
  1013. package/icons/tech/grafana.js +5 -5
  1014. package/icons/tech/hardhat.js +6 -6
  1015. package/icons/tech/inkscape.js +192 -153
  1016. package/icons/tech/insomnia.js +10 -10
  1017. package/icons/tech/intellij-idea.js +9 -9
  1018. package/icons/tech/jeet.js +68 -40
  1019. package/icons/tech/jekyll.js +87 -42
  1020. package/icons/tech/jetbrains.js +34 -34
  1021. package/icons/tech/jira-align.js +18 -18
  1022. package/icons/tech/jira.js +18 -18
  1023. package/icons/tech/json.js +6 -6
  1024. package/icons/tech/kotlin.js +4 -4
  1025. package/icons/tech/ktor.js +7 -7
  1026. package/icons/tech/linux.js +47 -47
  1027. package/icons/tech/matlab.js +4 -4
  1028. package/icons/tech/maven.js +66 -66
  1029. package/icons/tech/minitab.js +5 -5
  1030. package/icons/tech/modx.js +14 -7
  1031. package/icons/tech/moodle.js +17 -11
  1032. package/icons/tech/nerog.js +35 -35
  1033. package/icons/tech/net.js +36 -36
  1034. package/icons/tech/ocaml.js +29 -29
  1035. package/icons/tech/opera.js +15 -15
  1036. package/icons/tech/photon-engine.js +2 -2
  1037. package/icons/tech/php-storm.js +23 -11
  1038. package/icons/tech/php.js +2 -2
  1039. package/icons/tech/powershell.js +7 -7
  1040. package/icons/tech/processing.js +5 -5
  1041. package/icons/tech/pycharm.js +10 -10
  1042. package/icons/tech/python-poetry.js +14 -14
  1043. package/icons/tech/python.js +13 -13
  1044. package/icons/tech/qodana.js +9 -9
  1045. package/icons/tech/r.js +4 -4
  1046. package/icons/tech/ren-py.js +202 -196
  1047. package/icons/tech/rider.js +12 -6
  1048. package/icons/tech/rollup-js.js +20 -20
  1049. package/icons/tech/ruby-mine.js +6 -6
  1050. package/icons/tech/ruby.js +38 -32
  1051. package/icons/tech/sdl.js +5 -5
  1052. package/icons/tech/solid-js.js +30 -30
  1053. package/icons/tech/sqlite.js +7 -7
  1054. package/icons/tech/tower.js +164 -152
  1055. package/icons/tech/v8.js +29 -29
  1056. package/icons/tech/vala.js +21 -21
  1057. package/icons/tech/vitejs.js +16 -16
  1058. package/icons/tech/vscode.js +11 -11
  1059. package/icons/tech/weblate.js +23 -23
  1060. package/icons/tech/webstorm.js +12 -12
  1061. package/icons/tech/xcode.js +331 -283
  1062. package/package.json +24 -24
  1063. package/react/index.d.ts +35 -2
  1064. package/react/index.mjs +2895 -1772
  1065. package/react/style.css +1 -1
  1066. package/dist/shared/likec4.Dgm8MxXR.mjs +0 -1816
  1067. package/icons/azure/arc-postgre-sql.js +0 -62
@@ -2,16 +2,16 @@ import { jsx, jsxs, Fragment as Fragment$1 } from "react/jsx-runtime";
2
2
  import * as React from "react";
3
3
  import { createContext as createContext$1, useContext as useContext$1, useId as useId$1, useEffect as useEffect$1, useCallback as useCallback$1, Component, useLayoutEffect as useLayoutEffect$1, useRef as useRef$1, useInsertionEffect, useMemo as useMemo$1, forwardRef as forwardRef$1, Fragment, createElement as createElement$1, Children, isValidElement, useState as useState$1, memo as memo$1, Suspense, lazy, useSyncExternalStore, StrictMode } from "react";
4
4
  import { createRoot } from "react-dom/client";
5
- import { L as Link, c as createRootRouteWithContext, S as ScrollRestoration, O as Outlet, a as createFileRoute, u as useRouter, b as useParams, d as useRouterState, i as isNotFound, n as notFound, R as RouterProvider, e as createRouter$1, f as createHashHistory, g as createBrowserHistory } from "./tanstack-router-C6UpMKjv.js";
6
- import { e as Container, f as Title, a as Text$4, G as Group, g as Button, t as themeToVars, h as useMantineStyleNonce, M as MantineContext, i as useMergedRef, j as useTimeout, c as clsx, B as Box, A as ActionIcon$1, P as Paper, k as Code, l as useTree, m as useComputedColorScheme, n as Popover, o as PopoverTarget, p as PopoverDropdown, S as ScrollAreaAutosize, q as Tree, T as ThemeIcon, r as useLocalStorage, s as useStateHistory, v as Space, w as SegmentedControl, x as useHotkeys, y as Tooltip$3, z as Menu, D as MenuTarget, E as MenuDropdown, F as MenuLabel, H as MenuDivider, J as Stack$1, K as TooltipGroup, L as MenuItem, N as CloseButton, O as keys$1, Q as ColorSwatch, R as Divider, U as Flex, V as CheckIcon, W as rem, X as Slider, Y as useDebouncedValue, Z as HoverCard, _ as HoverCardTarget, $ as UnstyledButton, a0 as HoverCardDropdown, a1 as Anchor, a2 as CopyButton$1, C as Card, b as CardSection, a3 as Spoiler, a4 as Badge, a5 as ButtonGroup, a6 as Tabs, a7 as TabsList, a8 as TabsTab, a9 as TabsPanel, aa as useHover, ab as FloatingIndicator, ac as useUncontrolled, ad as clampUseMovePosition, ae as useMove, af as ActionIconGroup, ag as Overlay, ah as Notification, ai as createTheme, aj as MantineProvider, ak as useInViewport, al as SimpleGrid, u as useMantineColorScheme, am as Drawer, an as ScrollArea, ao as Alert, ap as Select, aq as ModalRoot, ar as ModalOverlay, as as ModalContent, at as ModalBody, au as useMantineTheme, av as useMediaQuery, aw as useDisclosure, ax as LoadingOverlay, ay as useCallbackRef, az as Burger, aA as Loader } from "./mantine-5H3V65ZR.js";
5
+ import { L as Link, c as createRootRouteWithContext, S as ScrollRestoration, O as Outlet, a as createFileRoute, u as useRouter, b as useParams, d as useRouterState, i as isNotFound, n as notFound, R as RouterProvider, e as createRouter$1, f as createHashHistory, g as createBrowserHistory } from "./tanstack-router-CfO1HFS2.js";
6
+ import { e as Container, f as Title, a as Text$6, G as Group, g as Button, h as useMergedRef, t as themeToVars, i as useMantineStyleNonce, M as MantineContext, j as useComputedColorScheme, k as Popover, l as PopoverTarget, B as Box, T as ThemeIcon, m as PopoverDropdown, S as ScrollAreaAutosize, c as clsx, A as ActionIcon$1, n as Stack$1, o as useTree, p as Tree, q as useLocalStorage, r as useStateHistory, s as Space, v as SegmentedControl, w as useHotkeys, F as FocusTrap, x as Tooltip$3, y as Menu, z as MenuTarget, D as MenuDropdown, E as MenuLabel, H as MenuDivider, J as TooltipGroup, K as MenuItem, L as CloseButton, N as keys$1, O as ColorSwatch, Q as Divider, R as Flex, U as CheckIcon, V as rem, W as Slider, P as Paper, X as useDebouncedValue, Y as HoverCard, Z as HoverCardTarget, _ as UnstyledButton, $ as HoverCardDropdown, a0 as Anchor, a1 as CopyButton$1, C as Card, b as CardSection, a2 as Spoiler, a3 as Badge, a4 as ButtonGroup, a5 as Tabs, a6 as TabsList, a7 as TabsTab, a8 as TabsPanel, a9 as useHover, aa as FloatingIndicator, ab as useUncontrolled, ac as clampUseMovePosition, ad as useMove, ae as ActionIconGroup, af as Overlay, ag as Notification, ah as Code, ai as createTheme, aj as MantineProvider, ak as useInViewport, al as SimpleGrid, u as useMantineColorScheme, am as Drawer, an as ScrollArea, ao as Alert, ap as Select, aq as ModalRoot, ar as ModalOverlay, as as ModalContent, at as ModalBody, au as useMantineTheme, av as useMediaQuery, aw as useDisclosure, ax as LoadingOverlay, ay as useCallbackRef, az as Burger, aA as Loader } from "./mantine-Dx0sIYv1.js";
7
7
  import { withOverviewGraph, ComponentName, isDevelopment, krokiD2SvgUrl, basepath, useHashHistory } from "../const.js";
8
8
  import { useLikeC4ModelAtom } from "virtual:likec4/model";
9
- import { g as getDefaultExportFromCjs, d as useReactFlow, e as useStoreApi, f as useStore$1, h as useNodesData, j as getNodeDimensions, k as createWithEqualityFn, l as applyNodeChanges, m as applyEdgeChanges, n as getViewportForBounds, o as getBoundsOfRects, s as shallow$1, p as boxToRect, q as useStoreWithEqualityFn, M as MarkerType, H as Handle, P as Position, r as getBezierPath, B as BaseEdge, E as EdgeLabelRenderer, i as index, t as Panel$1, R as ReactFlowProvider, N as NodeToolbar, v as useOnViewportChange, b as Background, c as BackgroundVariant } from "./likec4-B4TbAFjc.js";
9
+ import { g as getDefaultExportFromCjs, d as useReactFlow, e as useStoreApi, f as useStore$1, h as useNodesData, j as getNodeDimensions, k as createWithEqualityFn, l as applyNodeChanges, m as applyEdgeChanges, n as getViewportForBounds, o as getBoundsOfRects, s as shallow$1, p as boxToRect, q as useStoreWithEqualityFn, M as MarkerType, H as Handle, P as Position, r as getBezierPath, B as BaseEdge, E as EdgeLabelRenderer, i as index, t as Panel$1, V as ViewportPortal, R as ReactFlowProvider, N as NodeToolbar, v as useOnViewportChange, b as Background, c as BackgroundVariant } from "./likec4-zEZHE7gJ.js";
10
10
  import { RenderIcon } from "../icons.js";
11
11
  import { usePreviewUrl } from "virtual:likec4/previews";
12
- var content = "_1u4wf800", image = "_1u4wf801", inner = "_1u4wf802", root$1 = "_1u4wf803", description$2 = "_1u4wf804", title$4 = "_1u4wf805";
12
+ var content = "_1u4wf800", image = "_1u4wf801", inner = "_1u4wf802", root = "_1u4wf803", description$2 = "_1u4wf804", title$4 = "_1u4wf805";
13
13
  function NotFound() {
14
- return /* @__PURE__ */ jsx(Container, { className: root$1, children: /* @__PURE__ */ jsxs("div", { className: inner, children: [
14
+ return /* @__PURE__ */ jsx(Container, { className: root, children: /* @__PURE__ */ jsxs("div", { className: inner, children: [
15
15
  /* @__PURE__ */ jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 362 145", className: image, children: /* @__PURE__ */ jsx(
16
16
  "path",
17
17
  {
@@ -21,7 +21,7 @@ function NotFound() {
21
21
  ) }),
22
22
  /* @__PURE__ */ jsxs("div", { className: content, children: [
23
23
  /* @__PURE__ */ jsx(Title, { className: title$4, children: "Nothing to see here" }),
24
- /* @__PURE__ */ jsx(Text$4, { c: "dimmed", size: "lg", ta: "center", className: description$2, children: "Page you are trying to open does not exist. You may have mistyped the address, or the page has been moved to another URL. If you think this is an error contact support." }),
24
+ /* @__PURE__ */ jsx(Text$6, { c: "dimmed", size: "lg", ta: "center", className: description$2, children: "Page you are trying to open does not exist. You may have mistyped the address, or the page has been moved to another URL. If you think this is an error contact support." }),
25
25
  /* @__PURE__ */ jsx(Group, { justify: "center", children: /* @__PURE__ */ jsx(Button, { component: Link, to: "/", search: !0, startTransition: !0, size: "md", children: "Take me back to home page" }) })
26
26
  ] })
27
27
  ] }) });
@@ -343,7 +343,7 @@ const variantPriorityOrder = [
343
343
  ease: [0.25, 0.1, 0.35, 1],
344
344
  duration: 0.3
345
345
  }, getDefaultTransition = (valueKey, { keyframes: keyframes2 }) => keyframes2.length > 2 ? keyframesTransition : transformProps.has(valueKey) ? valueKey.startsWith("scale") ? criticallyDampedSpring(keyframes2[1]) : underDampedSpring : ease;
346
- function getValueTransition(transition, key) {
346
+ function getValueTransition$1(transition, key) {
347
347
  return transition ? transition[key] || transition.default || transition : void 0;
348
348
  }
349
349
  const MotionGlobalConfig = {
@@ -354,7 +354,7 @@ function getFinalKeyframe(keyframes2, { repeat, repeatType = "loop" }, finalKeyf
354
354
  const resolvedKeyframes = keyframes2.filter(isNotNull), index2 = repeat && repeatType !== "loop" && repeat % 2 === 1 ? 0 : resolvedKeyframes.length - 1;
355
355
  return !index2 || finalKeyframe === void 0 ? resolvedKeyframes[index2] : finalKeyframe;
356
356
  }
357
- const noop$1 = (any) => any;
357
+ const noop$2 = (any) => any;
358
358
  function createRenderStep(runNextFrame) {
359
359
  let thisFrame = /* @__PURE__ */ new Set(), nextFrame = /* @__PURE__ */ new Set(), isProcessing = !1, flushNextFrame = !1;
360
360
  const toKeepAlive = /* @__PURE__ */ new WeakSet();
@@ -427,7 +427,7 @@ function createRenderBatcher(scheduleNextBatch, allowKeepAlive) {
427
427
  steps[stepsOrder[i2]].cancel(process2);
428
428
  }, state, steps };
429
429
  }
430
- const { schedule: frame, cancel: cancelFrame, state: frameData, steps: frameSteps } = createRenderBatcher(typeof requestAnimationFrame < "u" ? requestAnimationFrame : noop$1, !0), calcBezier = (t2, a1, a2) => (((1 - 3 * a2 + 3 * a1) * t2 + (3 * a2 - 6 * a1)) * t2 + 3 * a1) * t2, subdivisionPrecision = 1e-7, subdivisionMaxIterations = 12;
430
+ const { schedule: frame, cancel: cancelFrame, state: frameData, steps: frameSteps } = createRenderBatcher(typeof requestAnimationFrame < "u" ? requestAnimationFrame : noop$2, !0), calcBezier = (t2, a1, a2) => (((1 - 3 * a2 + 3 * a1) * t2 + (3 * a2 - 6 * a1)) * t2 + 3 * a1) * t2, subdivisionPrecision = 1e-7, subdivisionMaxIterations = 12;
431
431
  function binarySubdivide(x2, lowerBound, upperBound, mX1, mX2) {
432
432
  let currentX, currentT, i2 = 0;
433
433
  do
@@ -437,7 +437,7 @@ function binarySubdivide(x2, lowerBound, upperBound, mX1, mX2) {
437
437
  }
438
438
  function cubicBezier(mX1, mY1, mX2, mY2) {
439
439
  if (mX1 === mY1 && mX2 === mY2)
440
- return noop$1;
440
+ return noop$2;
441
441
  const getTForX = (aX) => binarySubdivide(aX, 0, 1, mX1, mX2);
442
442
  return (t2) => t2 === 0 || t2 === 1 ? t2 : calcBezier(getTForX(t2), mY1, mY2);
443
443
  }
@@ -445,7 +445,7 @@ const mirrorEasing = (easing) => (p2) => p2 <= 0.5 ? easing(2 * p2) / 2 : (2 - e
445
445
  function isNone(value) {
446
446
  return typeof value == "number" ? value === 0 : value !== null ? value === "none" || value === "0" || isZeroValueString(value) : !0;
447
447
  }
448
- let invariant$1 = noop$1;
448
+ let invariant$1 = noop$2;
449
449
  const isNumericalString = (v) => /^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(v), checkStringStartsWith = (token) => (key) => typeof key == "string" && key.startsWith(token), isCSSVariableName = /* @__PURE__ */ checkStringStartsWith("--"), startsAsVariableToken = /* @__PURE__ */ checkStringStartsWith("var(--"), isCSSVariableToken = (value) => startsAsVariableToken(value) ? singleCssVariableRegex.test(value.split("/*")[0].trim()) : !1, singleCssVariableRegex = /var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu, splitCSSVariableRegex = (
450
450
  // eslint-disable-next-line redos-detector/no-unsafe-regex -- false positive, as it can match a lot of words
451
451
  /^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u
@@ -1112,7 +1112,7 @@ function inertia({ keyframes: keyframes2, velocity = 0, power = 0.8, timeConstan
1112
1112
  };
1113
1113
  }
1114
1114
  const easeIn = /* @__PURE__ */ cubicBezier(0.42, 0, 1, 1), easeOut = /* @__PURE__ */ cubicBezier(0, 0, 0.58, 1), easeInOut = /* @__PURE__ */ cubicBezier(0.42, 0, 0.58, 1), isEasingArray = (ease2) => Array.isArray(ease2) && typeof ease2[0] != "number", isBezierDefinition = (easing) => Array.isArray(easing) && typeof easing[0] == "number", easingLookup = {
1115
- linear: noop$1,
1115
+ linear: noop$2,
1116
1116
  easeIn,
1117
1117
  easeInOut,
1118
1118
  easeOut,
@@ -1223,7 +1223,7 @@ function createMixers(output, ease2, customMixer) {
1223
1223
  for (let i2 = 0; i2 < numMixers; i2++) {
1224
1224
  let mixer = mixerFactory(output[i2], output[i2 + 1]);
1225
1225
  if (ease2) {
1226
- const easingFunction = Array.isArray(ease2) ? ease2[i2] || noop$1 : ease2;
1226
+ const easingFunction = Array.isArray(ease2) ? ease2[i2] || noop$2 : ease2;
1227
1227
  mixer = pipe(easingFunction, mixer);
1228
1228
  }
1229
1229
  mixers.push(mixer);
@@ -1618,11 +1618,11 @@ class AcceleratedAnimation extends BaseAnimation {
1618
1618
  else {
1619
1619
  const { resolved } = this;
1620
1620
  if (!resolved)
1621
- return noop$1;
1621
+ return noop$2;
1622
1622
  const { animation } = resolved;
1623
1623
  attachTimeline(animation, timeline);
1624
1624
  }
1625
- return noop$1;
1625
+ return noop$2;
1626
1626
  }
1627
1627
  play() {
1628
1628
  if (this.isStopped)
@@ -1749,7 +1749,7 @@ function isTransitionDefined({ when, delay: _delay, delayChildren, staggerChildr
1749
1749
  return !!Object.keys(transition).length;
1750
1750
  }
1751
1751
  const animateMotionValue = (name, value, target, transition = {}, element, isHandoff) => (onComplete) => {
1752
- const valueTransition = getValueTransition(transition, name) || {}, delay2 = valueTransition.delay || transition.delay || 0;
1752
+ const valueTransition = getValueTransition$1(transition, name) || {}, delay2 = valueTransition.delay || transition.delay || 0;
1753
1753
  let { elapsed = 0 } = transition;
1754
1754
  elapsed = elapsed - secondsToMilliseconds(delay2);
1755
1755
  let options = {
@@ -1825,7 +1825,7 @@ class MotionValue {
1825
1825
  * @internal
1826
1826
  */
1827
1827
  constructor(init, options = {}) {
1828
- this.version = "11.11.7", this.canTrackVelocity = null, this.events = {}, this.updateAndNotify = (v, render = !0) => {
1828
+ this.version = "11.11.9", this.canTrackVelocity = null, this.events = {}, this.updateAndNotify = (v, render = !0) => {
1829
1829
  const currentTime = time$1.now();
1830
1830
  this.updatedAt !== currentTime && this.setPrevFrameValue(), this.prev = this.current, this.setCurrent(v), this.current !== this.prev && this.events.change && this.events.change.notify(this.current), render && this.events.renderRequest && this.events.renderRequest.notify(this.current);
1831
1831
  }, this.hasAnimated = !1, this.setCurrent(init), this.owner = options.owner;
@@ -2032,20 +2032,12 @@ const isMotionValue = (value) => !!(value && value.getVelocity);
2032
2032
  function isWillChangeMotionValue(value) {
2033
2033
  return !!(isMotionValue(value) && value.add);
2034
2034
  }
2035
- function getWillChangeName(name) {
2036
- if (transformProps.has(name))
2037
- return "transform";
2038
- if (acceleratedValues.has(name))
2039
- return camelToDash(name);
2040
- }
2041
2035
  function addValueToWillChange(visualElement, key) {
2042
- var _a;
2043
2036
  if (!visualElement.applyWillChange)
2044
2037
  return;
2045
2038
  const willChange = visualElement.getValue("willChange");
2046
2039
  if (isWillChangeMotionValue(willChange))
2047
2040
  return willChange.add(key);
2048
- !(!((_a = visualElement.props.style) === null || _a === void 0) && _a.willChange) && getWillChangeName(key) && visualElement.setStaticValue("willChange", "transform");
2049
2041
  }
2050
2042
  function shouldBlockAnimation({ protectedKeys, needsAnimating }, key) {
2051
2043
  const shouldBlock = protectedKeys.hasOwnProperty(key) && needsAnimating[key] !== !0;
@@ -2062,7 +2054,7 @@ function animateTarget(visualElement, targetAndTransition, { delay: delay2 = 0,
2062
2054
  continue;
2063
2055
  const valueTransition = {
2064
2056
  delay: delay2,
2065
- ...getValueTransition(transition || {}, key)
2057
+ ...getValueTransition$1(transition || {}, key)
2066
2058
  };
2067
2059
  let isHandoff = !1;
2068
2060
  if (window.MotionHandoffAnimation) {
@@ -2846,11 +2838,11 @@ function getCurrentDirection(offset, lockThreshold = 10) {
2846
2838
  }
2847
2839
  class DragGesture extends Feature {
2848
2840
  constructor(node2) {
2849
- super(node2), this.removeGroupControls = noop$1, this.removeListeners = noop$1, this.controls = new VisualElementDragControls(node2);
2841
+ super(node2), this.removeGroupControls = noop$2, this.removeListeners = noop$2, this.controls = new VisualElementDragControls(node2);
2850
2842
  }
2851
2843
  mount() {
2852
2844
  const { dragControls } = this.node.getProps();
2853
- dragControls && (this.removeGroupControls = dragControls.subscribe(this.controls)), this.removeListeners = this.controls.addListeners() || noop$1;
2845
+ dragControls && (this.removeGroupControls = dragControls.subscribe(this.controls)), this.removeListeners = this.controls.addListeners() || noop$2;
2854
2846
  }
2855
2847
  unmount() {
2856
2848
  this.removeGroupControls(), this.removeListeners();
@@ -2861,7 +2853,7 @@ const asyncHandler = (handler) => (event, info) => {
2861
2853
  };
2862
2854
  class PanGesture extends Feature {
2863
2855
  constructor() {
2864
- super(...arguments), this.removePointerDownListener = noop$1;
2856
+ super(...arguments), this.removePointerDownListener = noop$2;
2865
2857
  }
2866
2858
  onPointerDown(pointerDownEvent) {
2867
2859
  this.session = new PanSession(pointerDownEvent, this.createPanHandlers(), {
@@ -3021,7 +3013,7 @@ function mixValues(target, follow, lead, progress2, shouldCrossfadeOpacity, isOn
3021
3013
  function getRadius(values, radiusName) {
3022
3014
  return values[radiusName] !== void 0 ? values[radiusName] : values.borderRadius;
3023
3015
  }
3024
- const easeCrossfadeIn = /* @__PURE__ */ compress(0, 0.5, circOut), easeCrossfadeOut = /* @__PURE__ */ compress(0.5, 0.95, noop$1);
3016
+ const easeCrossfadeIn = /* @__PURE__ */ compress(0, 0.5, circOut), easeCrossfadeOut = /* @__PURE__ */ compress(0.5, 0.95, noop$2);
3025
3017
  function compress(min2, max2, easing) {
3026
3018
  return (p2) => p2 < min2 ? 0 : p2 > max2 ? 1 : easing(progress(min2, max2, p2));
3027
3019
  }
@@ -3242,7 +3234,7 @@ function createProjectionNode$1({ attachResizeListener, defaultParent, measureSc
3242
3234
  if (this.options.layoutRoot || this.resumeFrom && this.resumeFrom.instance || hasOnlyRelativeTargetChanged || hasLayoutChanged && (targetChanged || !this.currentAnimation)) {
3243
3235
  this.resumeFrom && (this.resumingFrom = this.resumeFrom, this.resumingFrom.resumingFrom = void 0), this.setAnimationOrigin(delta, hasOnlyRelativeTargetChanged);
3244
3236
  const animationOptions = {
3245
- ...getValueTransition(layoutTransition, "layout"),
3237
+ ...getValueTransition$1(layoutTransition, "layout"),
3246
3238
  onPlay: onLayoutAnimationStart,
3247
3239
  onComplete: onLayoutAnimationComplete
3248
3240
  };
@@ -3735,7 +3727,7 @@ function hasOpacityCrossfade(node2) {
3735
3727
  const defaultLayoutTransition = {
3736
3728
  duration: 0.45,
3737
3729
  ease: [0.4, 0, 0.1, 1]
3738
- }, userAgentContains = (string) => typeof navigator < "u" && navigator.userAgent && navigator.userAgent.toLowerCase().includes(string), roundPoint = userAgentContains("applewebkit/") && !userAgentContains("chrome/") ? Math.round : noop$1;
3730
+ }, userAgentContains = (string) => typeof navigator < "u" && navigator.userAgent && navigator.userAgent.toLowerCase().includes(string), roundPoint = userAgentContains("applewebkit/") && !userAgentContains("chrome/") ? Math.round : noop$2;
3739
3731
  function roundAxis(axis) {
3740
3732
  axis.min = roundPoint(axis.min), axis.max = roundPoint(axis.max);
3741
3733
  }
@@ -3835,7 +3827,7 @@ function fireSyntheticPointerEvent(name, handler) {
3835
3827
  }
3836
3828
  class PressGesture extends Feature {
3837
3829
  constructor() {
3838
- super(...arguments), this.removeStartListeners = noop$1, this.removeEndListeners = noop$1, this.removeAccessibleListeners = noop$1, this.startPointerPress = (startEvent, startInfo) => {
3830
+ super(...arguments), this.removeStartListeners = noop$2, this.removeEndListeners = noop$2, this.removeAccessibleListeners = noop$2, this.startPointerPress = (startEvent, startInfo) => {
3839
3831
  if (this.isPressing)
3840
3832
  return;
3841
3833
  this.removeEndListeners();
@@ -3963,7 +3955,7 @@ const gestureAnimations = {
3963
3955
  hover: {
3964
3956
  Feature: HoverGesture
3965
3957
  }
3966
- }, layout$2 = {
3958
+ }, layout$3 = {
3967
3959
  layout: {
3968
3960
  ProjectionNode: HTMLProjectionNode,
3969
3961
  MeasureLayout
@@ -4231,6 +4223,12 @@ function useConstant(init) {
4231
4223
  const ref = useRef$1(null);
4232
4224
  return ref.current === null && (ref.current = init()), ref.current;
4233
4225
  }
4226
+ function getWillChangeName(name) {
4227
+ if (transformProps.has(name))
4228
+ return "transform";
4229
+ if (acceleratedValues.has(name))
4230
+ return camelToDash(name);
4231
+ }
4234
4232
  function makeState({ applyWillChange = !1, scrapeMotionValuesFromProps: scrapeMotionValuesFromProps2, createRenderState, onMount: onMount2 }, props2, context, presenceContext, isStatic) {
4235
4233
  const state = {
4236
4234
  latestValues: makeLatestValues(props2, context, presenceContext, isStatic ? !1 : applyWillChange, scrapeMotionValuesFromProps2),
@@ -4254,9 +4252,7 @@ function forEachDefinition(props2, definition, callback) {
4254
4252
  }
4255
4253
  function makeLatestValues(props2, context, presenceContext, shouldApplyWillChange, scrapeMotionValues) {
4256
4254
  var _a;
4257
- const values = {};
4258
- let applyWillChange = shouldApplyWillChange && ((_a = props2.style) === null || _a === void 0 ? void 0 : _a.willChange) === void 0;
4259
- const motionValues = scrapeMotionValues(props2, {});
4255
+ const values = {}, willChange = /* @__PURE__ */ new Set(), applyWillChange = shouldApplyWillChange && ((_a = props2.style) === null || _a === void 0 ? void 0 : _a.willChange) === void 0, motionValues = scrapeMotionValues(props2, {});
4260
4256
  for (const key in motionValues)
4261
4257
  values[key] = resolveMotionValue(motionValues[key]);
4262
4258
  let { initial, animate } = props2;
@@ -4276,13 +4272,12 @@ function makeLatestValues(props2, context, presenceContext, shouldApplyWillChang
4276
4272
  }
4277
4273
  for (const key in transitionEnd)
4278
4274
  values[key] = transitionEnd[key];
4279
- }), applyWillChange && animate && initial !== !1 && !isAnimationControls(animate) && forEachDefinition(props2, animate, (target) => {
4280
- for (const key in target)
4281
- if (getWillChangeName(key)) {
4282
- values.willChange = "transform";
4283
- return;
4284
- }
4285
- }), values;
4275
+ }), applyWillChange && (animate && initial !== !1 && !isAnimationControls(animate) && forEachDefinition(props2, animate, (target) => {
4276
+ for (const name in target) {
4277
+ const memberName = getWillChangeName(name);
4278
+ memberName && willChange.add(memberName);
4279
+ }
4280
+ }), willChange.size && (values.willChange = Array.from(willChange).join(","))), values;
4286
4281
  }
4287
4282
  const createHtmlRenderState = () => ({
4288
4283
  style: {},
@@ -4990,9 +4985,262 @@ const shouldInheritGroup = (inherit) => inherit === !0, shouldInheritId = (inher
4990
4985
  }, domMax = {
4991
4986
  ...domAnimation,
4992
4987
  ...drag,
4993
- ...layout$2
4988
+ ...layout$3
4989
+ };
4990
+ function resolveElements(elements, scope, selectorCache) {
4991
+ var _a;
4992
+ if (typeof elements == "string") {
4993
+ let root2 = document;
4994
+ scope && (invariant$1(!!scope.current), root2 = scope.current), selectorCache ? ((_a = selectorCache[elements]) !== null && _a !== void 0 || (selectorCache[elements] = root2.querySelectorAll(elements)), elements = selectorCache[elements]) : elements = root2.querySelectorAll(elements);
4995
+ } else elements instanceof Element && (elements = [elements]);
4996
+ return Array.from(elements || []);
4997
+ }
4998
+ function useUnmountEffect$1(callback) {
4999
+ return useEffect$1(() => () => callback(), []);
5000
+ }
5001
+ function createGeneratorEasing(options, scale2 = 100, createGenerator) {
5002
+ const generator = createGenerator({ ...options, keyframes: [0, scale2] }), duration = Math.min(calcGeneratorDuration(generator), maxGeneratorDuration);
5003
+ return {
5004
+ type: "keyframes",
5005
+ ease: (progress2) => generator.next(duration * progress2).value / scale2,
5006
+ duration: millisecondsToSeconds(duration)
5007
+ };
5008
+ }
5009
+ function isDOMKeyframes(keyframes2) {
5010
+ return typeof keyframes2 == "object" && !Array.isArray(keyframes2);
5011
+ }
5012
+ function resolveSubjects(subject, keyframes2, scope, selectorCache) {
5013
+ return typeof subject == "string" && isDOMKeyframes(keyframes2) ? resolveElements(subject, scope, selectorCache) : subject instanceof NodeList ? Array.from(subject) : Array.isArray(subject) ? subject : [subject];
5014
+ }
5015
+ function calcNextTime(current, next, prev, labels) {
5016
+ var _a;
5017
+ return typeof next == "number" ? next : next.startsWith("-") || next.startsWith("+") ? Math.max(0, current + parseFloat(next)) : next === "<" ? prev : (_a = labels.get(next)) !== null && _a !== void 0 ? _a : current;
5018
+ }
5019
+ const wrap = (min2, max2, v) => {
5020
+ const rangeSize = max2 - min2;
5021
+ return ((v - min2) % rangeSize + rangeSize) % rangeSize + min2;
4994
5022
  };
4995
- var rootClassName = "likec4-diagram-root", s$1 = { done: !1, hasNext: !1 };
5023
+ function getEasingForSegment(easing, i2) {
5024
+ return isEasingArray(easing) ? easing[wrap(0, easing.length, i2)] : easing;
5025
+ }
5026
+ function eraseKeyframes(sequence, startTime, endTime) {
5027
+ for (let i2 = 0; i2 < sequence.length; i2++) {
5028
+ const keyframe = sequence[i2];
5029
+ keyframe.at > startTime && keyframe.at < endTime && (removeItem(sequence, keyframe), i2--);
5030
+ }
5031
+ }
5032
+ function addKeyframes(sequence, keyframes2, easing, offset, startTime, endTime) {
5033
+ eraseKeyframes(sequence, startTime, endTime);
5034
+ for (let i2 = 0; i2 < keyframes2.length; i2++)
5035
+ sequence.push({
5036
+ value: keyframes2[i2],
5037
+ at: mixNumber$1(startTime, endTime, offset[i2]),
5038
+ easing: getEasingForSegment(easing, i2)
5039
+ });
5040
+ }
5041
+ function compareByTime(a2, b2) {
5042
+ return a2.at === b2.at ? a2.value === null ? 1 : b2.value === null ? -1 : 0 : a2.at - b2.at;
5043
+ }
5044
+ const defaultSegmentEasing = "easeInOut";
5045
+ function createAnimationsFromSequence(sequence, { defaultTransition = {}, ...sequenceTransition } = {}, scope, generators2) {
5046
+ const defaultDuration = defaultTransition.duration || 0.3, animationDefinitions = /* @__PURE__ */ new Map(), sequences = /* @__PURE__ */ new Map(), elementCache = {}, timeLabels = /* @__PURE__ */ new Map();
5047
+ let prevTime = 0, currentTime = 0, totalDuration = 0;
5048
+ for (let i2 = 0; i2 < sequence.length; i2++) {
5049
+ const segment = sequence[i2];
5050
+ if (typeof segment == "string") {
5051
+ timeLabels.set(segment, currentTime);
5052
+ continue;
5053
+ } else if (!Array.isArray(segment)) {
5054
+ timeLabels.set(segment.name, calcNextTime(currentTime, segment.at, prevTime, timeLabels));
5055
+ continue;
5056
+ }
5057
+ let [subject, keyframes2, transition = {}] = segment;
5058
+ transition.at !== void 0 && (currentTime = calcNextTime(currentTime, transition.at, prevTime, timeLabels));
5059
+ let maxDuration2 = 0;
5060
+ const resolveValueSequence = (valueKeyframes, valueTransition, valueSequence, elementIndex = 0, numSubjects = 0) => {
5061
+ const valueKeyframesAsList = keyframesAsList(valueKeyframes), { delay: delay2 = 0, times = defaultOffset(valueKeyframesAsList), type = "keyframes", ...remainingTransition } = valueTransition;
5062
+ let { ease: ease2 = defaultTransition.ease || "easeOut", duration } = valueTransition;
5063
+ const calculatedDelay = typeof delay2 == "function" ? delay2(elementIndex, numSubjects) : delay2, numKeyframes = valueKeyframesAsList.length, createGenerator = isGenerator(type) ? type : generators2?.[type];
5064
+ if (numKeyframes <= 2 && createGenerator) {
5065
+ let absoluteDelta = 100;
5066
+ if (numKeyframes === 2 && isNumberKeyframesArray(valueKeyframesAsList)) {
5067
+ const delta = valueKeyframesAsList[1] - valueKeyframesAsList[0];
5068
+ absoluteDelta = Math.abs(delta);
5069
+ }
5070
+ const springTransition = { ...remainingTransition };
5071
+ duration !== void 0 && (springTransition.duration = secondsToMilliseconds(duration));
5072
+ const springEasing = createGeneratorEasing(springTransition, absoluteDelta, createGenerator);
5073
+ ease2 = springEasing.ease, duration = springEasing.duration;
5074
+ }
5075
+ duration ?? (duration = defaultDuration);
5076
+ const startTime = currentTime + calculatedDelay, targetTime = startTime + duration;
5077
+ times.length === 1 && times[0] === 0 && (times[1] = 1);
5078
+ const remainder = times.length - valueKeyframesAsList.length;
5079
+ remainder > 0 && fillOffset(times, remainder), valueKeyframesAsList.length === 1 && valueKeyframesAsList.unshift(null), addKeyframes(valueSequence, valueKeyframesAsList, ease2, times, startTime, targetTime), maxDuration2 = Math.max(calculatedDelay + duration, maxDuration2), totalDuration = Math.max(targetTime, totalDuration);
5080
+ };
5081
+ if (isMotionValue(subject)) {
5082
+ const subjectSequence = getSubjectSequence(subject, sequences);
5083
+ resolveValueSequence(keyframes2, transition, getValueSequence("default", subjectSequence));
5084
+ } else {
5085
+ const subjects = resolveSubjects(subject, keyframes2, scope, elementCache), numSubjects = subjects.length;
5086
+ for (let subjectIndex = 0; subjectIndex < numSubjects; subjectIndex++) {
5087
+ keyframes2 = keyframes2, transition = transition;
5088
+ const thisSubject = subjects[subjectIndex], subjectSequence = getSubjectSequence(thisSubject, sequences);
5089
+ for (const key in keyframes2)
5090
+ resolveValueSequence(keyframes2[key], getValueTransition(transition, key), getValueSequence(key, subjectSequence), subjectIndex, numSubjects);
5091
+ }
5092
+ }
5093
+ prevTime = currentTime, currentTime += maxDuration2;
5094
+ }
5095
+ return sequences.forEach((valueSequences, element) => {
5096
+ for (const key in valueSequences) {
5097
+ const valueSequence = valueSequences[key];
5098
+ valueSequence.sort(compareByTime);
5099
+ const keyframes2 = [], valueOffset = [], valueEasing = [];
5100
+ for (let i2 = 0; i2 < valueSequence.length; i2++) {
5101
+ const { at, value, easing } = valueSequence[i2];
5102
+ keyframes2.push(value), valueOffset.push(progress(0, totalDuration, at)), valueEasing.push(easing || "easeOut");
5103
+ }
5104
+ valueOffset[0] !== 0 && (valueOffset.unshift(0), keyframes2.unshift(keyframes2[0]), valueEasing.unshift(defaultSegmentEasing)), valueOffset[valueOffset.length - 1] !== 1 && (valueOffset.push(1), keyframes2.push(null)), animationDefinitions.has(element) || animationDefinitions.set(element, {
5105
+ keyframes: {},
5106
+ transition: {}
5107
+ });
5108
+ const definition = animationDefinitions.get(element);
5109
+ definition.keyframes[key] = keyframes2, definition.transition[key] = {
5110
+ ...defaultTransition,
5111
+ duration: totalDuration,
5112
+ ease: valueEasing,
5113
+ times: valueOffset,
5114
+ ...sequenceTransition
5115
+ };
5116
+ }
5117
+ }), animationDefinitions;
5118
+ }
5119
+ function getSubjectSequence(subject, sequences) {
5120
+ return !sequences.has(subject) && sequences.set(subject, {}), sequences.get(subject);
5121
+ }
5122
+ function getValueSequence(name, sequences) {
5123
+ return sequences[name] || (sequences[name] = []), sequences[name];
5124
+ }
5125
+ function keyframesAsList(keyframes2) {
5126
+ return Array.isArray(keyframes2) ? keyframes2 : [keyframes2];
5127
+ }
5128
+ function getValueTransition(transition, key) {
5129
+ return transition && transition[key] ? {
5130
+ ...transition,
5131
+ ...transition[key]
5132
+ } : { ...transition };
5133
+ }
5134
+ const isNumber = (keyframe) => typeof keyframe == "number", isNumberKeyframesArray = (keyframes2) => keyframes2.every(isNumber);
5135
+ function isObjectKey(key, object2) {
5136
+ return key in object2;
5137
+ }
5138
+ class ObjectVisualElement extends VisualElement {
5139
+ constructor() {
5140
+ super(...arguments), this.type = "object";
5141
+ }
5142
+ readValueFromInstance(instance, key) {
5143
+ if (isObjectKey(key, instance)) {
5144
+ const value = instance[key];
5145
+ if (typeof value == "string" || typeof value == "number")
5146
+ return value;
5147
+ }
5148
+ }
5149
+ getBaseTargetFromProps() {
5150
+ }
5151
+ removeValueFromRenderState(key, renderState) {
5152
+ delete renderState.output[key];
5153
+ }
5154
+ measureInstanceViewportBox() {
5155
+ return createBox();
5156
+ }
5157
+ build(renderState, latestValues) {
5158
+ Object.assign(renderState.output, latestValues);
5159
+ }
5160
+ renderInstance(instance, { output }) {
5161
+ Object.assign(instance, output);
5162
+ }
5163
+ sortInstanceNodePosition() {
5164
+ return 0;
5165
+ }
5166
+ }
5167
+ function createDOMVisualElement(element) {
5168
+ const options = {
5169
+ presenceContext: null,
5170
+ props: {},
5171
+ visualState: {
5172
+ renderState: {
5173
+ transform: {},
5174
+ transformOrigin: {},
5175
+ style: {},
5176
+ vars: {},
5177
+ attrs: {}
5178
+ },
5179
+ latestValues: {}
5180
+ }
5181
+ }, node2 = isSVGElement(element) ? new SVGVisualElement(options) : new HTMLVisualElement(options);
5182
+ node2.mount(element), visualElementStore.set(element, node2);
5183
+ }
5184
+ function createObjectVisualElement(subject) {
5185
+ const options = {
5186
+ presenceContext: null,
5187
+ props: {},
5188
+ visualState: {
5189
+ renderState: {
5190
+ output: {}
5191
+ },
5192
+ latestValues: {}
5193
+ }
5194
+ }, node2 = new ObjectVisualElement(options);
5195
+ node2.mount(subject), visualElementStore.set(subject, node2);
5196
+ }
5197
+ function isSingleValue(subject, keyframes2) {
5198
+ return isMotionValue(subject) || typeof subject == "number" || typeof subject == "string" && !isDOMKeyframes(keyframes2);
5199
+ }
5200
+ function animateSubject(subject, keyframes2, options, scope) {
5201
+ const animations2 = [];
5202
+ if (isSingleValue(subject, keyframes2))
5203
+ animations2.push(animateSingleValue(subject, isDOMKeyframes(keyframes2) && keyframes2.default || keyframes2, options && (options.default || options)));
5204
+ else {
5205
+ const subjects = resolveSubjects(subject, keyframes2, scope), numSubjects = subjects.length;
5206
+ for (let i2 = 0; i2 < numSubjects; i2++) {
5207
+ const thisSubject = subjects[i2], createVisualElement = thisSubject instanceof Element ? createDOMVisualElement : createObjectVisualElement;
5208
+ visualElementStore.has(thisSubject) || createVisualElement(thisSubject);
5209
+ const visualElement = visualElementStore.get(thisSubject), transition = { ...options };
5210
+ "delay" in transition && typeof transition.delay == "function" && (transition.delay = transition.delay(i2, numSubjects)), animations2.push(...animateTarget(visualElement, { ...keyframes2, transition }, {}));
5211
+ }
5212
+ }
5213
+ return animations2;
5214
+ }
5215
+ function animateSequence(sequence, options, scope) {
5216
+ const animations2 = [];
5217
+ return createAnimationsFromSequence(sequence, options, scope, { spring }).forEach(({ keyframes: keyframes2, transition }, subject) => {
5218
+ animations2.push(...animateSubject(subject, keyframes2, transition));
5219
+ }), animations2;
5220
+ }
5221
+ function isSequence(value) {
5222
+ return Array.isArray(value) && Array.isArray(value[0]);
5223
+ }
5224
+ function createScopedAnimate(scope) {
5225
+ function scopedAnimate(subjectOrSequence, optionsOrKeyframes, options) {
5226
+ let animations2 = [];
5227
+ isSequence(subjectOrSequence) ? animations2 = animateSequence(subjectOrSequence, optionsOrKeyframes, scope) : animations2 = animateSubject(subjectOrSequence, optionsOrKeyframes, options, scope);
5228
+ const animation = new GroupPlaybackControls(animations2);
5229
+ return scope && scope.animations.push(animation), animation;
5230
+ }
5231
+ return scopedAnimate;
5232
+ }
5233
+ function useAnimate() {
5234
+ const scope = useConstant(() => ({
5235
+ current: null,
5236
+ // Will be hydrated by React
5237
+ animations: []
5238
+ })), animate = useConstant(() => createScopedAnimate(scope));
5239
+ return useUnmountEffect$1(() => {
5240
+ scope.animations.forEach((animation) => animation.stop());
5241
+ }), [scope, animate];
5242
+ }
5243
+ var rootClassName = "likec4-diagram-root", s$2 = { done: !1, hasNext: !1 };
4996
5244
  function x$1(t2, ...o2) {
4997
5245
  let n2 = t2, u2 = o2.map((e2) => "lazy" in e2 ? f$2(e2) : void 0), p2 = 0;
4998
5246
  for (; p2 < o2.length; ) {
@@ -5015,7 +5263,7 @@ function x$1(t2, ...o2) {
5015
5263
  }
5016
5264
  function A(t2, o2, n2) {
5017
5265
  if (n2.length === 0) return o2.push(t2), !1;
5018
- let u2 = t2, p2 = s$1, e2 = !1;
5266
+ let u2 = t2, p2 = s$2, e2 = !1;
5019
5267
  for (let [r2, a2] of n2.entries()) {
5020
5268
  let { index: y2, items: i2 } = a2;
5021
5269
  if (i2.push(u2), p2 = a2(u2, y2, i2), a2.index += 1, p2.hasNext) {
@@ -5049,23 +5297,30 @@ function f$1(t2, i2) {
5049
5297
  }
5050
5298
  throw new Error("Wrong number of arguments");
5051
5299
  }
5052
- function u$8(t2, n2, a2) {
5300
+ function i$8(...e2) {
5301
+ return f$1(o$7, e2);
5302
+ }
5303
+ function o$7() {
5304
+ let e2 = /* @__PURE__ */ new Set();
5305
+ return (t2) => e2.has(t2) ? s$2 : (e2.add(t2), { done: !1, hasNext: !0, next: t2 });
5306
+ }
5307
+ function u$9(t2, n2, a2) {
5053
5308
  let o2 = (r2) => t2(r2, ...n2);
5054
5309
  return a2 === void 0 ? o2 : Object.assign(o2, { lazy: a2, lazyArgs: n2 });
5055
5310
  }
5056
- function u$7(r2, n2, a2) {
5311
+ function u$8(r2, n2, a2) {
5057
5312
  let o2 = r2.length - n2.length;
5058
5313
  if (o2 === 0) return r2(...n2);
5059
- if (o2 === 1) return u$8(r2, n2, a2);
5314
+ if (o2 === 1) return u$9(r2, n2, a2);
5060
5315
  throw new Error("Wrong number of arguments");
5061
5316
  }
5062
5317
  function r$4(...n2) {
5063
- return u$7(Object.values, n2);
5318
+ return u$8(Object.values, n2);
5064
5319
  }
5065
- function u$6(...e2) {
5066
- return u$7(i$8, e2);
5320
+ function u$7(...e2) {
5321
+ return u$8(i$7, e2);
5067
5322
  }
5068
- function i$8(e2, a2) {
5323
+ function i$7(e2, a2) {
5069
5324
  let n2 = [];
5070
5325
  for (let [o2, r2] of e2.entries()) {
5071
5326
  if (!a2(r2, o2, e2)) break;
@@ -5073,34 +5328,27 @@ function i$8(e2, a2) {
5073
5328
  }
5074
5329
  return n2;
5075
5330
  }
5076
- function i$7(...e2) {
5077
- return f$1(o$7, e2);
5078
- }
5079
- function o$7() {
5080
- let e2 = /* @__PURE__ */ new Set();
5081
- return (t2) => e2.has(t2) ? s$1 : (e2.add(t2), { done: !1, hasNext: !0, next: t2 });
5082
- }
5083
5331
  function i$6(...e2) {
5084
- return u$7(r$3, e2);
5332
+ return u$8(r$3, e2);
5085
5333
  }
5086
5334
  var r$3 = (e2, t2) => e2.length >= t2, T$1 = { asc: (r2, n2) => r2 > n2, desc: (r2, n2) => r2 < n2 };
5087
5335
  function m$2(r2, n2) {
5088
5336
  let [e2, ...o2] = n2;
5089
- if (!s(e2)) {
5090
- let t2 = u$5(...o2);
5337
+ if (!s$1(e2)) {
5338
+ let t2 = u$6(...o2);
5091
5339
  return r2(e2, t2);
5092
5340
  }
5093
- let a2 = u$5(e2, ...o2);
5341
+ let a2 = u$6(e2, ...o2);
5094
5342
  return (t2) => r2(t2, a2);
5095
5343
  }
5096
- function u$5(r2, n2, ...e2) {
5097
- let o2 = typeof r2 == "function" ? r2 : r2[0], a2 = typeof r2 == "function" ? "asc" : r2[1], { [a2]: t2 } = T$1, i2 = n2 === void 0 ? void 0 : u$5(n2, ...e2);
5344
+ function u$6(r2, n2, ...e2) {
5345
+ let o2 = typeof r2 == "function" ? r2 : r2[0], a2 = typeof r2 == "function" ? "asc" : r2[1], { [a2]: t2 } = T$1, i2 = n2 === void 0 ? void 0 : u$6(n2, ...e2);
5098
5346
  return (y2, c) => {
5099
5347
  let l2 = o2(y2), p2 = o2(c);
5100
5348
  return t2(l2, p2) ? 1 : t2(p2, l2) ? -1 : i2?.(y2, c) ?? 0;
5101
5349
  };
5102
5350
  }
5103
- function s(r2) {
5351
+ function s$1(r2) {
5104
5352
  if (d$2(r2)) return !0;
5105
5353
  if (typeof r2 != "object" || !Array.isArray(r2)) return !1;
5106
5354
  let [n2, e2, ...o2] = r2;
@@ -5108,7 +5356,7 @@ function s(r2) {
5108
5356
  }
5109
5357
  var d$2 = (r2) => typeof r2 == "function" && r2.length === 1;
5110
5358
  function m$1(...r2) {
5111
- return u$7(o$6, r2);
5359
+ return u$8(o$6, r2);
5112
5360
  }
5113
5361
  function o$6(r2, t2) {
5114
5362
  let e2 = [...r2];
@@ -5119,11 +5367,11 @@ function a$3(...r2) {
5119
5367
  }
5120
5368
  var o$5 = (r2, n2) => [...r2].sort(n2);
5121
5369
  function l$2(...e2) {
5122
- return u$7(u$4, e2);
5370
+ return u$8(u$5, e2);
5123
5371
  }
5124
- var u$4 = (e2, a2, n2) => e2.reduce(a2, n2);
5372
+ var u$5 = (e2, a2, n2) => e2.reduce(a2, n2);
5125
5373
  function t$7(...e2) {
5126
- return u$7(r$2, e2);
5374
+ return u$8(r$2, e2);
5127
5375
  }
5128
5376
  function r$2(e2) {
5129
5377
  return [...e2].reverse();
@@ -5138,16 +5386,16 @@ function b(t2) {
5138
5386
  return t2(e2 * n2) / n2;
5139
5387
  };
5140
5388
  }
5141
- function p$2(...o2) {
5142
- return u$7(t$6, o2);
5389
+ function p$3(...o2) {
5390
+ return u$8(t$6, o2);
5143
5391
  }
5144
5392
  var t$6 = (o2, e2) => o2[e2];
5145
5393
  function t$5(...n2) {
5146
- return u$7(o$4, n2);
5394
+ return u$8(o$4, n2);
5147
5395
  }
5148
5396
  var o$4 = (n2) => n2.length === 1 ? n2[0] : void 0;
5149
5397
  function d$1(...r2) {
5150
- return u$7(i$5, r2);
5398
+ return u$8(i$5, r2);
5151
5399
  }
5152
5400
  var i$5 = (r2, t2) => {
5153
5401
  let a2 = [[], []];
@@ -5155,16 +5403,16 @@ var i$5 = (r2, t2) => {
5155
5403
  return a2;
5156
5404
  };
5157
5405
  function t$4(...n2) {
5158
- return u$7(Object.keys, n2);
5406
+ return u$8(Object.keys, n2);
5159
5407
  }
5160
5408
  function a$2(...e2) {
5161
- return u$7(n$5, e2);
5409
+ return u$8(n$5, e2);
5162
5410
  }
5163
5411
  var n$5 = (e2) => e2.at(-1);
5164
5412
  function m(...a2) {
5165
- return u$7(o$3, a2, p$1);
5413
+ return u$8(o$3, a2, p$2);
5166
5414
  }
5167
- var o$3 = (a2, e2) => a2.map(e2), p$1 = (a2) => (e2, r2, t2) => ({ done: !1, hasNext: !0, next: a2(e2, r2, t2) });
5415
+ var o$3 = (a2, e2) => a2.map(e2), p$2 = (a2) => (e2, r2, t2) => ({ done: !1, hasNext: !0, next: a2(e2, r2, t2) });
5168
5416
  function t$3(r2) {
5169
5417
  return typeof r2 == "string";
5170
5418
  }
@@ -5195,15 +5443,15 @@ function n$1(e2) {
5195
5443
  function n(e2) {
5196
5444
  return e2 === void 0 ? !0 : typeof e2 == "string" || Array.isArray(e2) ? e2.length === 0 : Object.keys(e2).length === 0;
5197
5445
  }
5198
- function u$3(...e2) {
5199
- return u$7(o$1, e2, i$4);
5446
+ function u$4(...e2) {
5447
+ return u$8(o$1, e2, i$4);
5200
5448
  }
5201
5449
  function o$1(e2, r2) {
5202
5450
  return e2.forEach(r2), e2;
5203
5451
  }
5204
5452
  var i$4 = (e2) => (r2, n2, t2) => (e2(r2, n2, t2), { done: !1, hasNext: !0, next: r2 });
5205
5453
  function i$3(...e2) {
5206
- return u$7(a$1, e2);
5454
+ return u$8(a$1, e2);
5207
5455
  }
5208
5456
  function a$1(e2, o2) {
5209
5457
  let r2 = {};
@@ -5211,9 +5459,9 @@ function a$1(e2, o2) {
5211
5459
  return r2;
5212
5460
  }
5213
5461
  function i$2(...e2) {
5214
- return u$7(p, e2);
5462
+ return u$8(p$1, e2);
5215
5463
  }
5216
- var p = (e2, a2) => {
5464
+ var p$1 = (e2, a2) => {
5217
5465
  let n2 = {};
5218
5466
  for (let [d2, t2] of e2.entries()) {
5219
5467
  let y2 = a2(t2, d2, e2);
@@ -5225,33 +5473,54 @@ var p = (e2, a2) => {
5225
5473
  return n2;
5226
5474
  };
5227
5475
  function T(...a2) {
5228
- return u$7(l, a2, y$2);
5476
+ return u$8(l, a2, y$3);
5229
5477
  }
5230
- var l = (a2, e2) => a2.filter(e2), y$2 = (a2) => (e2, t2, o2) => a2(e2, t2, o2) ? { done: !1, hasNext: !0, next: e2 } : s$1, e$1 = (n2) => Object.assign(n2, { single: !0 });
5478
+ var l = (a2, e2) => a2.filter(e2), y$3 = (a2) => (e2, t2, o2) => a2(e2, t2, o2) ? { done: !1, hasNext: !0, next: e2 } : s$2, e$1 = (n2) => Object.assign(n2, { single: !0 });
5231
5479
  function f(...e2) {
5232
- return u$7(i$1, e2, e$1(u$2));
5480
+ return u$8(i$1, e2, e$1(u$3));
5233
5481
  }
5234
- var i$1 = (e2, n2) => e2.find(n2), u$2 = (e2) => (n2, t2, o2) => e2(n2, t2, o2) ? { done: !0, hasNext: !0, next: n2 } : s$1;
5482
+ var i$1 = (e2, n2) => e2.find(n2), u$3 = (e2) => (n2, t2, o2) => e2(n2, t2, o2) ? { done: !0, hasNext: !0, next: n2 } : s$2;
5235
5483
  function d(...e2) {
5236
- return u$7(r$1, e2, e$1(o));
5484
+ return u$8(r$1, e2, e$1(o));
5237
5485
  }
5238
5486
  var r$1 = ([e2]) => e2, o = () => a, a = (e2) => ({ hasNext: !0, next: e2, done: !0 });
5239
5487
  function t$2(...r2) {
5240
- return u$7(Object.entries, r2);
5488
+ return u$8(Object.entries, r2);
5489
+ }
5490
+ function p(...n2) {
5491
+ return u$8(u$2, n2);
5492
+ }
5493
+ function u$2(n2, t2 = [], r2 = []) {
5494
+ if (typeof n2 == "function") return n2;
5495
+ if (typeof n2 != "object" || n2 === null || n2 instanceof Date || n2 instanceof RegExp) return structuredClone(n2);
5496
+ let o2 = t2.indexOf(n2);
5497
+ return o2 >= 0 ? r2[o2] : (t2.push(n2), Array.isArray(n2) ? y$2(n2, t2, r2) : s(n2, t2, r2));
5498
+ }
5499
+ function s(n2, t2, r2) {
5500
+ let o2 = {};
5501
+ r2.push(o2);
5502
+ for (let [e2, c] of Object.entries(n2)) o2[e2] = u$2(c, t2, r2);
5503
+ return o2;
5504
+ }
5505
+ function y$2(n2, t2, r2) {
5506
+ let o2 = [];
5507
+ r2.push(o2);
5508
+ for (let [e2, c] of n2.entries()) o2[e2] = u$2(c, t2, r2);
5509
+ return o2;
5241
5510
  }
5242
5511
  function t$1(...a2) {
5243
- return u$7(e, a2);
5512
+ return u$8(e, a2);
5244
5513
  }
5245
5514
  var e = (a2, o2) => o2.every((l2) => l2(a2));
5246
5515
  function y$1(...a2) {
5247
- return u$7(r, a2);
5516
+ return u$8(r, a2);
5248
5517
  }
5249
5518
  var r = (a2, o2) => o2.some((e2) => e2(a2));
5250
5519
  function u$1(...e2) {
5251
- return u$7(b(Math.ceil), e2);
5520
+ return u$8(b(Math.ceil), e2);
5252
5521
  }
5253
5522
  function u(...n2) {
5254
- return u$7(i, n2);
5523
+ return u$8(i, n2);
5255
5524
  }
5256
5525
  var i = (n2, { min: e2, max: r2 }) => e2 !== void 0 && n2 < e2 ? e2 : r2 !== void 0 && n2 > r2 ? r2 : n2;
5257
5526
  function nonNullable(value, message) {
@@ -5266,6 +5535,10 @@ function invariant(condition, message) {
5266
5535
  function nonexhaustive(value) {
5267
5536
  throw new Error(`NonExhaustive value: ${value}`);
5268
5537
  }
5538
+ var ElementKind;
5539
+ ((ElementKind2) => {
5540
+ ElementKind2.Group = "@group";
5541
+ })(ElementKind || (ElementKind = {}));
5269
5542
  const ElementShapes = [
5270
5543
  "rectangle",
5271
5544
  "person",
@@ -5320,6 +5593,13 @@ function extractStep(id2) {
5320
5593
  function getParallelStepsPrefix(id2) {
5321
5594
  return isStepEdgeId(id2) && id2.includes(".") ? id2.slice(0, id2.indexOf(".") + 1) : null;
5322
5595
  }
5596
+ var ComputedNode;
5597
+ ((ComputedNode2) => {
5598
+ function isNodesGroup(node2) {
5599
+ return node2.kind === ElementKind.Group;
5600
+ }
5601
+ ComputedNode2.isNodesGroup = isNodesGroup;
5602
+ })(ComputedNode || (ComputedNode = {}));
5323
5603
  function getBBoxCenter({
5324
5604
  x: x2,
5325
5605
  y: y2,
@@ -5331,6 +5611,13 @@ function getBBoxCenter({
5331
5611
  y: y2 + height / 2
5332
5612
  };
5333
5613
  }
5614
+ var DiagramNode;
5615
+ ((DiagramNode2) => {
5616
+ function isNodesGroup(node2) {
5617
+ return node2.kind === ElementKind.Group;
5618
+ }
5619
+ DiagramNode2.isNodesGroup = isNodesGroup;
5620
+ })(DiagramNode || (DiagramNode = {}));
5334
5621
  var naturalCompareLite = { exports: {} };
5335
5622
  naturalCompareLite.exports;
5336
5623
  /*
@@ -5376,6 +5663,22 @@ function isAncestor(...args) {
5376
5663
  const ancestor = isString(args[0]) ? args[0] : args[0].id;
5377
5664
  return (isString(args[1]) ? args[1] : args[1].id).startsWith(ancestor + ".");
5378
5665
  }
5666
+ function commonAncestor(first, second) {
5667
+ const parentA = parentFqn(first), parentB = parentFqn(second);
5668
+ if (parentA === parentB)
5669
+ return parentA;
5670
+ if (!parentA || !parentB)
5671
+ return null;
5672
+ const a2 = first.split("."), b2 = second.split(".");
5673
+ let ancestor = null;
5674
+ for (; a2.length > 1 && b2.length > 1 && a2[0] && a2[0] === b2[0]; )
5675
+ ancestor = ancestor ? `${ancestor}.${a2[0]}` : a2[0], a2.shift(), b2.shift();
5676
+ return ancestor;
5677
+ }
5678
+ function parentFqn(fqn) {
5679
+ const lastDot = fqn.lastIndexOf(".");
5680
+ return lastDot > 0 ? fqn.slice(0, lastDot) : null;
5681
+ }
5379
5682
  function ancestorsFqn(fqn) {
5380
5683
  const path = fqn.split(".");
5381
5684
  return path.pop(), path.length === 0 ? [] : path.reduce((acc, part, idx) => idx === 0 ? (acc.push(part), acc) : (acc.unshift(`${acc[0]}.${part}`), acc), []);
@@ -5526,6 +5829,17 @@ const blue$1 = {
5526
5829
  relationships: RelationshipColors,
5527
5830
  font: "Arial",
5528
5831
  shadow: "#0a0a0a"
5832
+ }, compareRelations = (a2, b2) => {
5833
+ const parentA = commonAncestor(a2.source, a2.target), parentB = commonAncestor(b2.source, b2.target);
5834
+ if (parentA && !parentB)
5835
+ return 1;
5836
+ if (!parentA && parentB)
5837
+ return -1;
5838
+ const compareParents = parentA && parentB ? compareFqnHierarchically(parentA, parentB) : 0;
5839
+ if (compareParents !== 0)
5840
+ return compareParents;
5841
+ const compareSource = compareFqnHierarchically(a2.source, b2.source);
5842
+ return compareSource !== 0 ? compareSource : compareFqnHierarchically(a2.target, b2.target);
5529
5843
  };
5530
5844
  function useSyncedRef(value) {
5531
5845
  const ref = useRef$1(value);
@@ -5562,7 +5876,8 @@ function useDebouncedCallback(callback, deps, delay2, maxWait = 0) {
5562
5876
  }), wrapped;
5563
5877
  }, [delay2, maxWait, ...deps]);
5564
5878
  }
5565
- const isBrowser = typeof window < "u" && typeof navigator < "u" && typeof document < "u", basicDepsComparator = (d1, d2) => {
5879
+ const noop$1 = () => {
5880
+ }, isBrowser = typeof window < "u" && typeof navigator < "u" && typeof document < "u", basicDepsComparator = (d1, d2) => {
5566
5881
  if (d1 === d2)
5567
5882
  return !0;
5568
5883
  if (d1.length !== d2.length)
@@ -5586,6 +5901,10 @@ function useFirstMountState() {
5586
5901
  }, []), isFirstMount.current;
5587
5902
  }
5588
5903
  const useIsomorphicLayoutEffect$1 = isBrowser ? useLayoutEffect$1 : useEffect$1;
5904
+ function useUpdateEffect$1(effect, deps) {
5905
+ const isFirstMount = useFirstMountState();
5906
+ useEffect$1(isFirstMount ? noop$1 : effect, deps);
5907
+ }
5589
5908
  function useAsync(asyncFn, initialValue) {
5590
5909
  const [state, setState] = useState$1({
5591
5910
  status: "not-executed",
@@ -5870,7 +6189,7 @@ class VectorImpl {
5870
6189
  function vector(source) {
5871
6190
  return VectorImpl.create(source);
5872
6191
  }
5873
- const ZIndexes$1 = {
6192
+ const ZIndexes$2 = {
5874
6193
  Compound: 2,
5875
6194
  Edge: 4,
5876
6195
  Element: 6
@@ -5930,14 +6249,22 @@ class Leaf extends Rect {
5930
6249
  }
5931
6250
  }
5932
6251
  function createLayoutConstraints(xyflowApi, editingNodeIds) {
5933
- const { parentLookup, nodeLookup } = xyflowApi.getState(), rects = /* @__PURE__ */ new Map(), traverse = new Array();
6252
+ const { parentLookup, nodeLookup } = xyflowApi.getState(), rects = /* @__PURE__ */ new Map(), ancestorsOf = (nodeId) => {
6253
+ const ancestors = [];
6254
+ let parent = nodeLookup.get(nodeId)?.parentId, parentNode;
6255
+ for (; parent && (parentNode = nodeLookup.get(parent)); )
6256
+ ancestors.push(parentNode.id), parent = parentNode.parentId;
6257
+ return ancestors;
6258
+ }, ancestorsOfDraggingNodes = new Set(
6259
+ editingNodeIds.flatMap(ancestorsOf)
6260
+ ), traverse = new Array();
5934
6261
  for (const [, xynode] of nodeLookup)
5935
6262
  e$3(xynode.parentId) && traverse.push({
5936
6263
  xynode,
5937
6264
  parent: null
5938
6265
  });
5939
6266
  for (; traverse.length > 0; ) {
5940
- const { xynode, parent } = traverse.shift(), shouldTraverse = !editingNodeIds.has(xynode.id) && xynode.type === "compound" && editingNodeIds.values().some((x2) => isAncestor(xynode.id, x2)), rect = shouldTraverse ? new Compound(xynode, parent) : new Leaf(xynode, parent);
6267
+ const { xynode, parent } = traverse.shift(), shouldTraverse = !editingNodeIds.includes(xynode.id) && xynode.type === "compound" && ancestorsOfDraggingNodes.has(xynode.id), rect = shouldTraverse ? new Compound(xynode, parent) : new Leaf(xynode, parent);
5941
6268
  rects.set(xynode.id, rect), shouldTraverse && parentLookup.get(xynode.id)?.forEach((child) => {
5942
6269
  traverse.push({
5943
6270
  xynode: child,
@@ -5984,9 +6311,14 @@ function createLayoutConstraints(xyflowApi, editingNodeIds) {
5984
6311
  function onMove(updater) {
5985
6312
  rectsToUpdate.length !== 0 && (animationFrameId ??= requestAnimationFrame(() => {
5986
6313
  animationFrameId = null, updater(
5987
- [
5988
- ...editingNodeIds.values().filter((id2) => rects.has(id2) && nodeLookup.has(id2)).map((id2) => ({ rect: nonNullable(rects.get(id2)), node: nodeLookup.get(id2) }))
5989
- ]
6314
+ x$1(
6315
+ editingNodeIds,
6316
+ T((id2) => rects.has(id2) && nodeLookup.has(id2)),
6317
+ m((id2) => ({
6318
+ rect: nonNullable(rects.get(id2)),
6319
+ node: nonNullable(nodeLookup.get(id2))
6320
+ }))
6321
+ )
5990
6322
  ), updateXYFlowNodes();
5991
6323
  }));
5992
6324
  }
@@ -6001,13 +6333,16 @@ function useLayoutConstraints() {
6001
6333
  onNodeDragStart: (_event, xynode) => {
6002
6334
  const { cancelSaveManualLayout, xystore } = diagramApi.getState(), { nodeLookup } = xystore.getState();
6003
6335
  cancelSaveManualLayout();
6004
- const draggingNodes = new Set(
6005
- nodeLookup.values().filter((x2) => x2.dragging === !0 || x2.id === xynode.id || x2.selected).filter((x2) => x2.draggable === !0).map((x2) => x2.id)
6336
+ const draggingNodes = x$1(
6337
+ Array.from(nodeLookup.values()),
6338
+ T((n2) => n2.dragging === !0 || n2.id === xynode.id || n2.selected === !0),
6339
+ T((n2) => n2.draggable !== !1),
6340
+ m((x2) => x2.id)
6006
6341
  );
6007
- solverRef.current = createLayoutConstraints(xystore, draggingNodes);
6342
+ i$6(draggingNodes, 1) && (solverRef.current = createLayoutConstraints(xystore, draggingNodes));
6008
6343
  },
6009
6344
  onNodeDrag: () => {
6010
- invariant(solverRef.current, "solverRef.current should be defined"), solverRef.current.onMove((nodes) => {
6345
+ solverRef.current?.onMove((nodes) => {
6011
6346
  nodes.forEach(({ rect, node: node2 }) => {
6012
6347
  rect.positionAbsolute = node2.internals.positionAbsolute;
6013
6348
  });
@@ -7002,38 +7337,47 @@ function diagramViewToXYFlowData(view, opts) {
7002
7337
  const ns = "", nodeById = (id2) => nonNullable(nodeLookup.get(id2), `Node not found: ${id2}`);
7003
7338
  let next;
7004
7339
  for (; next = traverse.shift(); ) {
7005
- const { node: node2, parent } = next, isCompound = i$6(node2.children, 1);
7340
+ const { node: node2, parent } = next, isCompound = i$6(node2.children, 1) || node2.kind == ElementKind.Group;
7006
7341
  isCompound && traverse.push(...node2.children.map((child) => ({ node: nodeById(child), parent: node2 })));
7007
7342
  const position2 = {
7008
7343
  x: node2.position[0],
7009
7344
  y: node2.position[1]
7010
7345
  };
7011
7346
  parent && (position2.x -= parent.position[0], position2.y -= parent.position[1]);
7012
- const id2 = ns + node2.id, draggable = opts.draggable;
7013
- xynodes.push({
7014
- id: id2,
7015
- type: isCompound ? "compound" : "element",
7016
- data: {
7017
- fqn: node2.id,
7018
- element: node2
7019
- },
7020
- draggable,
7021
- selectable: opts.selectable,
7347
+ const base = {
7348
+ id: ns + node2.id,
7349
+ draggable: opts.draggable,
7350
+ selectable: opts.selectable && node2.kind !== ElementKind.Group,
7022
7351
  focusable: opts.selectable && !isCompound,
7023
7352
  deletable: !1,
7024
7353
  position: position2,
7025
- zIndex: isCompound ? ZIndexes$1.Compound : ZIndexes$1.Element,
7354
+ zIndex: isCompound ? ZIndexes$2.Compound : ZIndexes$2.Element,
7026
7355
  width: node2.width,
7027
7356
  height: node2.height,
7028
- hidden: !visiblePredicate(node2),
7029
- // parentId: parent ? ns + parent.id : null,
7357
+ hidden: node2.kind !== ElementKind.Group && !visiblePredicate(node2),
7030
7358
  ...parent && {
7031
7359
  parentId: ns + parent.id
7032
- },
7033
- ...isCompound && {
7360
+ }
7361
+ };
7362
+ xynodes.push(
7363
+ isCompound ? {
7364
+ ...base,
7365
+ type: "compound",
7366
+ data: {
7367
+ fqn: node2.id,
7368
+ isViewGroup: node2.kind === ElementKind.Group,
7369
+ element: node2
7370
+ },
7034
7371
  dragHandle: ".likec4-compound-title"
7372
+ } : {
7373
+ ...base,
7374
+ type: "element",
7375
+ data: {
7376
+ fqn: node2.id,
7377
+ element: node2
7378
+ }
7035
7379
  }
7036
- });
7380
+ );
7037
7381
  }
7038
7382
  for (const edge of view.edges) {
7039
7383
  const source = edge.source, target = edge.target, id2 = ns + edge.id;
@@ -7046,7 +7390,7 @@ function diagramViewToXYFlowData(view, opts) {
7046
7390
  type: "relationship",
7047
7391
  source: ns + source,
7048
7392
  target: ns + target,
7049
- zIndex: ZIndexes$1.Edge,
7393
+ zIndex: ZIndexes$2.Edge,
7050
7394
  selectable: opts.selectable,
7051
7395
  hidden: !visiblePredicate(edge),
7052
7396
  deletable: !1,
@@ -7195,13 +7539,13 @@ function createDiagramStore(props2) {
7195
7539
  });
7196
7540
  update.xynodes = update.xynodes.map((update2) => {
7197
7541
  const existing = xynodes2.find((n2) => n2.id === update2.id);
7198
- return existing && existing.type === update2.type && deepEqual(existing.parentId ?? null, update2.parentId ?? null) ? existing.hidden === update2.hidden && existing.width === update2.width && existing.height === update2.height && deepEqual(existing.position, update2.position) && deepEqual(existing.data.element, update2.data.element) ? existing : {
7542
+ return existing && existing.type === update2.type && deepEqual(existing.parentId ?? null, update2.parentId ?? null) ? existing.width === update2.width && existing.height === update2.height && deepEqual(existing.hidden ?? !1, update2.hidden ?? !1) && deepEqual(existing.position, update2.position) && deepEqual(existing.data, update2.data) ? existing : {
7199
7543
  ...existing,
7200
7544
  ...update2
7201
7545
  } : update2;
7202
7546
  }), isSameView && !nextView.hasLayoutDrift && (update.xyedges = update.xyedges.map((update2) => {
7203
7547
  const existing = xyedges2.find((n2) => n2.id === update2.id);
7204
- return existing ? existing.hidden === update2.hidden && deepEqual(existing.data.label, update2.data.label) && deepEqual(existing.data.controlPoints, update2.data.controlPoints) && deepEqual(existing.data.edge, update2.data.edge) ? existing : {
7548
+ return existing ? deepEqual(existing.hidden ?? !1, update2.hidden ?? !1) && deepEqual(existing.data.label, update2.data.label) && deepEqual(existing.data.controlPoints, update2.data.controlPoints) && deepEqual(existing.data.edge, update2.data.edge) ? existing : {
7205
7549
  ...existing,
7206
7550
  ...update2,
7207
7551
  data: {
@@ -7488,17 +7832,11 @@ function createDiagramStore(props2) {
7488
7832
  "goForward"
7489
7833
  ), onNavigateTo(stepForward.viewId));
7490
7834
  },
7491
- openOverlay: (overlay2) => {
7492
- set(
7493
- {
7494
- activeOverlay: overlay2
7495
- },
7496
- noReplace,
7497
- "openOverlay"
7498
- );
7835
+ openOverlay: (overlay) => {
7836
+ deepEqual(overlay, get().activeOverlay) || set({ activeOverlay: overlay }, noReplace, "openOverlay");
7499
7837
  },
7500
7838
  closeOverlay: () => {
7501
- set(
7839
+ get().activeOverlay !== null && set(
7502
7840
  {
7503
7841
  activeOverlay: null
7504
7842
  },
@@ -7508,7 +7846,7 @@ function createDiagramStore(props2) {
7508
7846
  },
7509
7847
  fitDiagram: (duration = 500) => {
7510
7848
  const { fitViewPadding, view, xystore } = get(), { width: width2, height, panZoom, transform } = xystore.getState(), bounds = view.bounds, maxZoom = Math.max(1, transform[2]), viewport = getViewportForBounds(bounds, width2, height, MinZoom, maxZoom, fitViewPadding);
7511
- panZoom?.setViewport(viewport, { duration });
7849
+ panZoom?.setViewport(viewport, duration > 0 ? { duration } : void 0);
7512
7850
  },
7513
7851
  nextDynamicStep: (increment = 1) => {
7514
7852
  const { activeWalkthrough, xyedges: xyedges2, activateWalkthrough } = get(), stepId = activeWalkthrough?.stepId;
@@ -7586,18 +7924,18 @@ function createDiagramStore(props2) {
7586
7924
  ), get().fitDiagram());
7587
7925
  },
7588
7926
  onInit: (instance) => {
7589
- const { xyflow, initialized } = get();
7590
- (!initialized || xyflow !== instance) && set(
7927
+ const { xyflow, initialized, fitViewEnabled, fitDiagram } = get();
7928
+ (!initialized || xyflow !== instance) && (fitViewEnabled && fitDiagram(0), set(
7591
7929
  {
7592
7930
  xyflow: instance,
7593
7931
  initialized: !0
7594
7932
  },
7595
7933
  noReplace,
7596
7934
  "onInit"
7597
- );
7935
+ ));
7598
7936
  },
7599
7937
  highlightByElementNotation: (notation, onlyOfKind) => {
7600
- const { xynodes: xynodes2, xyedges: xyedges2 } = get(), dimmed2 = new StringSet(m(xyedges2, p$2("id")));
7938
+ const { xynodes: xynodes2, xyedges: xyedges2 } = get(), dimmed2 = new StringSet(m(xyedges2, p$3("id")));
7601
7939
  xynodes2.forEach(({ id: id2, data }) => {
7602
7940
  const node2 = data.element;
7603
7941
  (node2.shape !== notation.shape || node2.color !== notation.color || !notation.kinds.includes(node2.kind) || onlyOfKind && node2.kind !== onlyOfKind) && dimmed2.add(id2);
@@ -7638,7 +7976,12 @@ function createDiagramStore(props2) {
7638
7976
  }
7639
7977
  },
7640
7978
  align: (mode) => {
7641
- const { scheduleSaveManualLayout, xystore } = get(), { nodeLookup, parentLookup } = xystore.getState(), selectedNodes = new Set(nodeLookup.values().filter((n2) => n2.selected).map((n2) => n2.id)), nodesToAlign = new Set(selectedNodes.difference(new Set(parentLookup.keys()))), constraints = createLayoutConstraints(xystore, nodesToAlign);
7979
+ const { scheduleSaveManualLayout, xystore } = get(), { nodeLookup, parentLookup } = xystore.getState(), nodesToAlign = [...new Set(nodeLookup.values().filter((n2) => n2.selected).map((n2) => n2.id)).difference(new Set(parentLookup.keys()))];
7980
+ if (!i$6(nodesToAlign, 2)) {
7981
+ console.warn("At least 2 nodes must be selected to align");
7982
+ return;
7983
+ }
7984
+ const constraints = createLayoutConstraints(xystore, nodesToAlign);
7642
7985
  let getEdgePosition, getPosition, propertyToEdit;
7643
7986
  switch (mode) {
7644
7987
  case "Left":
@@ -7686,13 +8029,13 @@ function DiagramContextProvider({
7686
8029
  whereFilter,
7687
8030
  ...props2
7688
8031
  }) {
7689
- const containerRef = useRef$1(null), xystore = useXYStoreApi(), xyflow = useXYFlow(), store = useRef$1(), getContainer = useCallback$1(() => containerRef.current, [containerRef]);
7690
- return store.current || (store.current = createDiagramStore({
8032
+ const [scope, animate] = useAnimate(), containerRef = useRef$1(null), ref = useMergedRef(scope, containerRef), xystore = useXYStoreApi(), xyflow = useXYFlow(), store = useRef$1(), getContainer = useCallback$1(() => containerRef.current, [containerRef]);
8033
+ store.current || (store.current = createDiagramStore({
7691
8034
  xystore,
7692
8035
  xyflow,
7693
8036
  view,
7694
8037
  getContainer,
7695
- whereFilter: structuredClone(whereFilter),
8038
+ whereFilter: p(whereFilter),
7696
8039
  ...props2
7697
8040
  })), useUpdateEffect(
7698
8041
  () => store.current?.setState({ xyflow, xystore, getContainer }, !1, "update xyflow and xystore"),
@@ -7703,14 +8046,24 @@ function DiagramContextProvider({
7703
8046
  ), useUpdateEffect(
7704
8047
  () => {
7705
8048
  const current = store.current;
7706
- invariant(current, "DiagramContext.store.current is not defined"), deepEqual(whereFilter, current.getState().whereFilter) || current.setState({ whereFilter: structuredClone(whereFilter) }, !1, "update where filter"), current.getState().updateView(view);
8049
+ invariant(current, "DiagramContext.store.current is not defined"), deepEqual(whereFilter, current.getState().whereFilter) || current.setState({ whereFilter: p(whereFilter) }, !1, "update where filter"), current.getState().updateView(view);
7707
8050
  },
7708
8051
  [view, whereFilter],
7709
8052
  (a2, b2) => shallowEqual(a2[0], b2[0]) && deepEqual(a2[1], b2[1])
7710
- ), /* @__PURE__ */ jsx(
8053
+ );
8054
+ const api = store.current;
8055
+ return useEffect$1(() => api.subscribe((s2) => !!s2.activeOverlay, (isActiveOverlay) => {
8056
+ animate(".likec4-diagram .react-flow__renderer", {
8057
+ filter: isActiveOverlay ? "grayscale(0.85) brightness(0.5)" : "grayscale(0) brightness()",
8058
+ scale: isActiveOverlay ? 0.97 : 1,
8059
+ transform: isActiveOverlay ? "translateY(8px)" : "translateY(0)"
8060
+ }, {
8061
+ duration: isActiveOverlay ? 0.5 : 0.16
8062
+ });
8063
+ }), [api]), /* @__PURE__ */ jsx(
7711
8064
  "div",
7712
8065
  {
7713
- ref: containerRef,
8066
+ ref,
7714
8067
  className,
7715
8068
  ...keepAspectRatio && {
7716
8069
  style: {
@@ -7718,7 +8071,7 @@ function DiagramContextProvider({
7718
8071
  maxHeight: Math.ceil(view.bounds.height)
7719
8072
  }
7720
8073
  },
7721
- children: /* @__PURE__ */ jsx(DiagramContext.Provider, { value: store.current, children })
8074
+ children: /* @__PURE__ */ jsx(DiagramContext.Provider, { value: api, children })
7722
8075
  }
7723
8076
  );
7724
8077
  }
@@ -10865,8 +11218,7 @@ createGlobalThemeContract({
10865
11218
  borderRadius: "node-border-radius"
10866
11219
  }
10867
11220
  }, (value) => `xy-${value}`);
10868
- const mantine = themeToVars({});
10869
- function LikeC4CustomColors({ customColors }) {
11221
+ const mantine = themeToVars({}), LikeC4CustomColors = memo$1(({ customColors }) => {
10870
11222
  function toStyle(name, colorValues) {
10871
11223
  const rules = new Array(
10872
11224
  ...t$2(colorValues.elements).map(([key, value]) => `${stripCssVarReference(vars.element[key])}: ${value};`),
@@ -10885,9 +11237,10 @@ function LikeC4CustomColors({ customColors }) {
10885
11237
  }
10886
11238
  const styles = t$2(customColors).map(([name, color2]) => toStyle(name, color2)).join(`
10887
11239
  `), nonce = useMantineStyleNonce()?.();
10888
- return /* @__PURE__ */ jsx(Fragment$1, { children: /* @__PURE__ */ jsx("style", { type: "text/css", dangerouslySetInnerHTML: { __html: styles }, ...nonce && { nonce } }) });
10889
- }
10890
- var cssReactFlow = "_17jps3v0", cssDisablePan = "_17jps3v1", cssTransparentBg = "_17jps3v2", cssNoControls = "_17jps3v3";
11240
+ return /* @__PURE__ */ jsx(Fragment$1, { children: /* @__PURE__ */ jsx("style", { type: "text/css", dangerouslySetInnerHTML: { __html: styles }, nonce }) });
11241
+ }, deepEqual);
11242
+ LikeC4CustomColors.displayName = "LikeC4CustomColors";
11243
+ var cssReactFlow = "_17jps3v0", notInitialized = "_17jps3v1", cssDisablePan = "_17jps3v2", cssTransparentBg = "_17jps3v3", cssNoControls = "_17jps3v4";
10891
11244
  const LikeC4ModelContext = createContext$1(null);
10892
11245
  function useLikeC4Model(strict, type) {
10893
11246
  const model = useContext$1(LikeC4ModelContext);
@@ -11099,6 +11452,13 @@ var IconFolderOpen = createReactComponent("outline", "folder-open", "IconFolderO
11099
11452
  * See the LICENSE file in the root directory of this source tree.
11100
11453
  */
11101
11454
  var IconHelpCircle = createReactComponent("outline", "help-circle", "IconHelpCircle", [["path", { d: "M3 12a9 9 0 1 0 18 0a9 9 0 0 0 -18 0", key: "svg-0" }], ["path", { d: "M12 16v.01", key: "svg-1" }], ["path", { d: "M12 13a2 2 0 0 0 .914 -3.782a1.98 1.98 0 0 0 -2.414 .483", key: "svg-2" }]]);
11455
+ /**
11456
+ * @license @tabler/icons-react v3.17.0 - MIT
11457
+ *
11458
+ * This source code is licensed under the MIT license.
11459
+ * See the LICENSE file in the root directory of this source tree.
11460
+ */
11461
+ var IconInfoCircle = createReactComponent("outline", "info-circle", "IconInfoCircle", [["path", { d: "M3 12a9 9 0 1 0 18 0a9 9 0 0 0 -18 0", key: "svg-0" }], ["path", { d: "M12 9h.01", key: "svg-1" }], ["path", { d: "M11 12h1v4h1", key: "svg-2" }]]);
11102
11462
  /**
11103
11463
  * @license @tabler/icons-react v3.17.0 - MIT
11104
11464
  *
@@ -11280,126 +11640,25 @@ var IconPlayerStopFilled = createReactComponent("filled", "player-stop-filled",
11280
11640
  * This source code is licensed under the MIT license.
11281
11641
  * See the LICENSE file in the root directory of this source tree.
11282
11642
  */
11283
- var IconStarFilled = createReactComponent("filled", "star-filled", "IconStarFilled", [["path", { d: "M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z", key: "svg-0" }]]), dialog = "_1robbpb4";
11643
+ var IconStarFilled = createReactComponent("filled", "star-filled", "IconStarFilled", [["path", { d: "M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z", key: "svg-0" }]]);
11284
11644
  const OverlayContext = createContext$1({});
11285
11645
  function useOverlayDialog() {
11286
11646
  return useContext$1(OverlayContext);
11287
11647
  }
11288
- const OverlayDialog = forwardRef$1(({
11289
- className,
11290
- children,
11291
- onClose,
11292
- ...props2
11293
- }, forwardedRef) => {
11294
- const onCloseRef = useSyncedRef(onClose), api = useDiagramStoreApi(), [opened, setOpened] = useState$1(!1), dialogRef = useRef$1(null), ref = useMergedRef(dialogRef, forwardedRef);
11295
- useDebouncedEffect(
11296
- () => {
11297
- dialogRef.current?.showModal();
11298
- },
11299
- [],
11300
- 30
11301
- ), useDebouncedEffect(
11302
- () => {
11303
- setOpened(!0);
11304
- },
11305
- [],
11306
- 80
11307
- );
11308
- const { start: triggerOnClose } = useTimeout(() => {
11309
- onCloseRef.current?.();
11310
- }, 300), ctxValue = useMemo$1(() => ({
11311
- openOverlay: api.getState().openOverlay,
11312
- close: () => {
11313
- dialogRef.current?.close();
11314
- }
11315
- }), [api]);
11316
- return /* @__PURE__ */ jsx(OverlayContext.Provider, { value: ctxValue, children: /* @__PURE__ */ jsx(
11317
- "dialog",
11318
- {
11319
- "aria-modal": "true",
11320
- ref,
11321
- className: clsx(dialog, className),
11322
- onClick: (e2) => {
11323
- e2.target?.nodeName?.toUpperCase() === "DIALOG" && (e2.stopPropagation(), dialogRef.current?.close());
11324
- },
11325
- onClose: (e2) => {
11326
- e2.stopPropagation(), triggerOnClose();
11327
- },
11328
- ...props2,
11329
- children: children({
11330
- opened,
11331
- ...ctxValue
11332
- })
11333
- }
11334
- ) });
11335
- }), OverlayDialogCloseButton = () => {
11336
- const { close } = useOverlayDialog();
11337
- return /* @__PURE__ */ jsx(Box, { pos: "absolute", top: "1rem", right: "1rem", children: /* @__PURE__ */ jsx(
11338
- ActionIcon$1,
11339
- {
11340
- variant: "default",
11341
- size: "lg",
11342
- autoFocus: !0,
11343
- onClick: (e2) => {
11344
- e2.stopPropagation(), close();
11345
- },
11346
- children: /* @__PURE__ */ jsx(IconX, {})
11347
- }
11348
- ) });
11349
- };
11350
- var dependencyViewContainer = "_1m627kc0";
11351
- function EdgeDetailsOverlay({ edgeId }) {
11352
- const diagramApi = useDiagramStoreApi(), edge = useDiagramState((s2) => s2.xyedges.find((e2) => e2.id === edgeId));
11353
- return invariant(edge, `Edge with id ${edgeId} not found`), /* @__PURE__ */ jsx(
11354
- OverlayDialog,
11355
- {
11356
- onClose: () => {
11357
- diagramApi.getState().closeOverlay();
11358
- },
11359
- "data-likec4-color": "gray",
11360
- children: ({ close }) => /* @__PURE__ */ jsxs(Paper, { className: dependencyViewContainer, children: [
11361
- /* @__PURE__ */ jsx("div", { children: "edge" }),
11362
- /* @__PURE__ */ jsx(Code, { block: !0, children: JSON.stringify(edge, null, 2) }),
11363
- /* @__PURE__ */ jsx(
11364
- ActionIcon$1,
11365
- {
11366
- variant: "default",
11367
- color: "gray",
11368
- autoFocus: !0,
11369
- onClick: (e2) => {
11370
- e2.stopPropagation(), close();
11371
- },
11372
- children: /* @__PURE__ */ jsx(IconX, {})
11373
- }
11374
- )
11375
- ] })
11376
- }
11377
- );
11378
- }
11379
- var node = "_1nudxvt0", label = "_1nudxvt1";
11380
- const classes = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
11381
- __proto__: null,
11382
- get label() {
11383
- return label;
11384
- },
11385
- get node() {
11386
- return node;
11387
- }
11388
- }, Symbol.toStringTag, { value: "Module" })), SelectElement = ({
11389
- subject,
11390
- viewId,
11391
- scope,
11392
- onSelect
11648
+ var edgeSource = "qaevzq1 qaevzq0", edgeArrow = "qaevzq2 qaevzq0", edgeTarget = "qaevzq3 qaevzq0", edgeLabel$3 = "qaevzq4", edgeRow = "qaevzq5", edgeGrid = "qaevzq6", edgeDataGrid = "qaevzq7";
11649
+ const SelectEdge = ({
11650
+ edge,
11651
+ view
11393
11652
  }) => {
11394
- const viewport = useRef$1(null), data = useLikeC4ElementsTree(scope === "view" ? viewId : void 0), tree = useTree({
11395
- multiple: !1
11653
+ const overlay = useOverlayDialog(), viewport = useRef$1(null), theme2 = useComputedColorScheme(), edgeSource$1 = view.nodes.find((n2) => n2.id === edge.source), edgeTarget$1 = view.nodes.find((n2) => n2.id === edge.target), edges = view.edges.map((edge2) => {
11654
+ const source = view.nodes.find((n2) => n2.id === edge2.source), target = view.nodes.find((n2) => n2.id === edge2.target);
11655
+ return {
11656
+ id: edge2.id,
11657
+ source,
11658
+ target,
11659
+ label: edge2.label
11660
+ };
11396
11661
  });
11397
- useEffect$1(() => {
11398
- ancestorsFqn(subject.id).reverse().forEach((id2) => {
11399
- tree.expand(id2);
11400
- }), tree.select(subject.id);
11401
- }, [subject.id]);
11402
- const theme2 = useComputedColorScheme();
11403
11662
  return /* @__PURE__ */ jsxs(
11404
11663
  Popover,
11405
11664
  {
@@ -11411,89 +11670,93 @@ const classes = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePrope
11411
11670
  clickOutsideEvents: ["pointerdown", "mousedown", "click"],
11412
11671
  onOpen: () => {
11413
11672
  setTimeout(() => {
11414
- const item = viewport.current?.querySelector(`[data-value="${subject.id}"]`);
11415
- console.log("item", item), item?.scrollIntoView({ behavior: "instant", block: "nearest" });
11673
+ viewport.current?.querySelector(`[data-edge-id="${edge.id}"]`)?.scrollIntoView({ behavior: "instant", block: "nearest" });
11416
11674
  }, 100);
11417
11675
  },
11418
11676
  children: [
11419
- /* @__PURE__ */ jsx(PopoverTarget, { children: /* @__PURE__ */ jsx(
11677
+ /* @__PURE__ */ jsx(PopoverTarget, { children: /* @__PURE__ */ jsxs(
11420
11678
  Button,
11421
11679
  {
11422
11680
  size: "xs",
11423
11681
  variant: "light",
11424
11682
  color: theme2 === "light" ? "dark" : "gray",
11425
11683
  fw: "500",
11426
- maw: 250,
11427
11684
  style: { padding: "0.25rem 0.75rem" },
11428
11685
  rightSection: /* @__PURE__ */ jsx(IconSelector, { size: 16 }),
11429
- children: subject.title
11430
- }
11431
- ) }),
11432
- /* @__PURE__ */ jsx(PopoverDropdown, { p: 0, miw: 250, maw: 400, children: /* @__PURE__ */ jsx(ScrollAreaAutosize, { mah: "70vh", scrollbars: "y", type: "never", viewportRef: viewport, children: /* @__PURE__ */ jsx(
11433
- Tree,
11434
- {
11435
- allowRangeSelection: !1,
11436
- selectOnClick: !1,
11437
- tree,
11438
- data,
11439
- classNames: classes,
11440
- levelOffset: 8,
11441
- styles: {
11442
- label: {
11443
- paddingTop: 5,
11444
- paddingBottom: 6
11445
- }
11446
- },
11447
- renderNode: ({ node: node2, selected, expanded, elementProps, hasChildren }) => /* @__PURE__ */ jsxs(Group, { gap: 2, wrap: "nowrap", ...elementProps, py: "3", children: [
11686
+ children: [
11448
11687
  /* @__PURE__ */ jsx(
11449
- ActionIcon$1,
11688
+ Box,
11450
11689
  {
11451
- variant: "subtle",
11452
- size: 18,
11453
- c: "dimmed",
11454
- style: {
11455
- visibility: hasChildren ? "visible" : "hidden"
11690
+ className: edgeSource,
11691
+ maw: 160,
11692
+ p: 0,
11693
+ mod: {
11694
+ "likec4-color": edgeSource$1.color
11456
11695
  },
11457
- children: /* @__PURE__ */ jsx(
11458
- IconChevronRight,
11459
- {
11460
- stroke: 3.5,
11461
- style: {
11462
- transition: "transform 150ms ease",
11463
- transform: `rotate(${expanded ? "90deg" : "0"})`,
11464
- width: "80%"
11465
- }
11466
- }
11467
- )
11696
+ children: /* @__PURE__ */ jsx(Text$6, { component: "span", truncate: !0, children: edgeSource$1.title })
11468
11697
  }
11469
11698
  ),
11699
+ /* @__PURE__ */ jsx(ThemeIcon, { color: "dark", variant: "transparent", size: "xs", children: /* @__PURE__ */ jsx(IconArrowRight, { style: { width: "80%" } }) }),
11470
11700
  /* @__PURE__ */ jsx(
11471
11701
  Box,
11472
11702
  {
11473
- flex: "1 1 100%",
11474
- w: "100%",
11475
- onClick: (e2) => {
11476
- e2.stopPropagation(), onSelect(node2.value), tree.select(node2.value), tree.expand(node2.value);
11703
+ className: edgeTarget,
11704
+ maw: 160,
11705
+ p: 0,
11706
+ mod: {
11707
+ "likec4-color": edgeTarget$1.color
11477
11708
  },
11478
- children: /* @__PURE__ */ jsx(
11479
- Text$4,
11480
- {
11481
- fz: "sm",
11482
- fw: selected ? "600" : "400",
11483
- truncate: "end",
11484
- children: node2.label
11485
- }
11486
- )
11709
+ children: /* @__PURE__ */ jsx(Text$6, { component: "span", truncate: !0, children: edgeTarget$1.title })
11487
11710
  }
11488
11711
  )
11489
- ] })
11712
+ ]
11490
11713
  }
11491
- ) }) })
11714
+ ) }),
11715
+ /* @__PURE__ */ jsx(PopoverDropdown, { p: 0, miw: 250, maw: 420, children: /* @__PURE__ */ jsx(ScrollAreaAutosize, { mah: "70vh", scrollbars: "y", type: "never", viewportRef: viewport, children: /* @__PURE__ */ jsx(Box, { className: edgeGrid, p: "xs", children: edges.map((e2) => /* @__PURE__ */ jsxs(
11716
+ "div",
11717
+ {
11718
+ className: edgeRow,
11719
+ "data-selected": e2.id === edge.id,
11720
+ onClick: (event) => {
11721
+ event.stopPropagation(), overlay.openOverlay({
11722
+ edgeDetails: e2.id
11723
+ });
11724
+ },
11725
+ children: [
11726
+ /* @__PURE__ */ jsx(
11727
+ Box,
11728
+ {
11729
+ className: edgeSource,
11730
+ maw: 160,
11731
+ mod: {
11732
+ "edge-id": e2.id,
11733
+ "likec4-color": e2.source.color
11734
+ },
11735
+ children: /* @__PURE__ */ jsx(Text$6, { component: "span", truncate: !0, children: e2.source.title })
11736
+ }
11737
+ ),
11738
+ /* @__PURE__ */ jsx(Box, { className: edgeArrow, children: /* @__PURE__ */ jsx(ThemeIcon, { color: "dark", variant: "transparent", size: "xs", children: /* @__PURE__ */ jsx(IconArrowRight, { style: { width: "80%" } }) }) }),
11739
+ /* @__PURE__ */ jsx(
11740
+ Box,
11741
+ {
11742
+ className: edgeTarget,
11743
+ maw: 160,
11744
+ mod: {
11745
+ "likec4-color": e2.target.color
11746
+ },
11747
+ children: /* @__PURE__ */ jsx(Text$6, { component: "span", truncate: !0, children: e2.target.title })
11748
+ }
11749
+ ),
11750
+ /* @__PURE__ */ jsx(Box, { className: edgeLabel$3, children: /* @__PURE__ */ jsx(Text$6, { component: "span", truncate: !0, children: e2.label || "untitled" }) })
11751
+ ]
11752
+ },
11753
+ e2.id
11754
+ )) }) }) })
11492
11755
  ]
11493
11756
  }
11494
11757
  );
11495
11758
  };
11496
- var root = "likec4-relationships-xyflow", overlay = "kvs8dr1", DEFAULT_EDGE_NAME = "\0", GRAPH_NODE = "\0", EDGE_KEY_DELIM = "";
11759
+ var DEFAULT_EDGE_NAME = "\0", GRAPH_NODE = "\0", EDGE_KEY_DELIM = "";
11497
11760
  let Graph$a = class {
11498
11761
  _isDirected = !0;
11499
11762
  _isMultigraph = !1;
@@ -13293,8 +13556,8 @@ function positionY(g) {
13293
13556
  });
13294
13557
  }
13295
13558
  let acyclic = acyclic$1, normalize = normalize$1, rank = rank_1, normalizeRanks = util$d.normalizeRanks, parentDummyChains = parentDummyChains_1, removeEmptyRanks = util$d.removeEmptyRanks, nestingGraph = nestingGraph$1, addBorderSegments = addBorderSegments_1, coordinateSystem = coordinateSystem$1, order = order_1, position = position_1, util$1 = util$d, Graph$1 = graphlib.Graph;
13296
- var layout_1 = layout$1;
13297
- function layout$1(g, opts) {
13559
+ var layout_1 = layout$2;
13560
+ function layout$2(g, opts) {
13298
13561
  let time2 = opts && opts.debugTiming ? util$1.time : util$1.notime;
13299
13562
  time2("layout", () => {
13300
13563
  let layoutGraph = time2(" buildLayoutGraph", () => buildLayoutGraph(g));
@@ -13502,68 +13765,56 @@ var version = "1.1.4", dagre = {
13502
13765
  },
13503
13766
  version
13504
13767
  };
13505
- const dagre$1 = /* @__PURE__ */ getDefaultExportFromCjs(dagre), graphColumn = (c) => ({
13506
- name: c,
13507
- id: `__${c}`,
13508
- anchor: `__${c}::anchor`
13509
- }), Sizes = {
13768
+ const dagre$1 = /* @__PURE__ */ getDefaultExportFromCjs(dagre), Sizes$1 = {
13510
13769
  dagre: {
13511
13770
  ranksep: 40,
13512
- nodesep: 20,
13513
- edgesep: 20
13771
+ nodesep: 25,
13772
+ edgesep: 15
13514
13773
  },
13515
13774
  edgeLabel: {
13516
- width: 50
13775
+ width: 120
13517
13776
  },
13518
- emptyNodeOffset: 100,
13519
13777
  nodeWidth: 270,
13520
13778
  hodeHeight: 160,
13521
13779
  // Spacer between elements in a compound node
13522
13780
  // 0 means no spacer
13523
13781
  spacerHeight: 0,
13524
13782
  compoundLabelHeight: 5
13525
- }, ZIndexes = {
13526
- empty: 2,
13783
+ }, ZIndexes$1 = {
13527
13784
  compound: 2,
13528
13785
  edge: 3,
13529
13786
  element: 4,
13530
13787
  max: 5
13531
13788
  };
13532
- function createGraph() {
13789
+ function createGraph$1() {
13533
13790
  const g = new dagre$1.graphlib.Graph({
13534
13791
  directed: !0,
13535
13792
  compound: !0
13536
13793
  });
13537
13794
  return g.setGraph({
13538
- ...Sizes.dagre,
13795
+ ...Sizes$1.dagre,
13539
13796
  rankdir: "LR"
13540
- }), g.setDefaultEdgeLabel(() => ({ ...Sizes.edgeLabel })), g.setDefaultNodeLabel(() => ({})), ["incomers", "subject", "outgoers"].reduce((prev, column) => {
13541
- const c = graphColumn(column);
13542
- return g.setNode(c.id, {}), g.setNode(c.anchor, { width: 50, height: 5 }), g.setParent(c.anchor, c.id), prev && g.setEdge(prev, c.anchor), c.anchor;
13543
- }, null), g;
13797
+ }), g.setDefaultEdgeLabel(() => ({ ...Sizes$1.edgeLabel })), g.setDefaultNodeLabel(() => ({})), g;
13544
13798
  }
13545
- const sized = (height = Sizes.hodeHeight) => ({
13546
- width: Sizes.nodeWidth,
13799
+ const sized$1 = (height = Sizes$1.hodeHeight) => ({
13800
+ width: Sizes$1.nodeWidth,
13547
13801
  height
13548
- }), graphId = (node2) => ({
13802
+ }), graphId$1 = (node2) => ({
13549
13803
  id: node2.id,
13550
13804
  port: node2.type === "compound" ? `${node2.id}::port` : node2.id,
13551
- // port: `${node.id}::port`,
13552
- // For nested nodes
13553
13805
  body: `${node2.id}`,
13554
13806
  spacer: `${node2.id}:spacer`
13555
13807
  });
13556
- function nodeData(element, ctx) {
13808
+ function nodeData$1(element, ctx) {
13557
13809
  let diagramNode = ctx.diagramNodes.get(element.id);
13558
- const ancestor = diagramNode ?? (ctx.scope === "view" ? x$1(
13810
+ const ancestor = diagramNode ?? x$1(
13559
13811
  element.ancestors(),
13560
13812
  m((ancestor2) => ctx.diagramNodes.get(ancestor2.id)),
13561
13813
  T(n$4),
13562
13814
  d()
13563
- ) : void 0);
13815
+ );
13564
13816
  return {
13565
13817
  fqn: element.id,
13566
- existsInCurrentView: ctx.diagramNodes.has(element.id),
13567
13818
  element: {
13568
13819
  kind: element.kind,
13569
13820
  title: diagramNode?.title ?? element.title,
@@ -13573,67 +13824,42 @@ function nodeData(element, ctx) {
13573
13824
  },
13574
13825
  navigateTo: diagramNode?.navigateTo ?? d(element.viewsOf())?.id ?? null,
13575
13826
  ports: {
13576
- left: [],
13577
- right: []
13827
+ in: [],
13828
+ out: []
13578
13829
  }
13579
13830
  };
13580
13831
  }
13581
- function createEmptyNode(column, ctx) {
13582
- const id2 = `${column}::empty`, xynodes = ctx.columns[column];
13583
- let node2 = xynodes.get(id2);
13584
- if (node2)
13585
- return invariant(node2.type === "empty", "Node is not empty"), node2;
13586
- const xynode = {
13587
- type: "empty",
13588
- id: id2,
13589
- position: { x: 0, y: 0 },
13590
- data: {
13591
- column
13592
- },
13593
- zIndex: ZIndexes.empty
13594
- };
13595
- xynodes.set(id2, xynode);
13596
- const k = graphId(xynode);
13597
- return ctx.g.setNode(k.id, {
13598
- width: 230,
13599
- height: 130
13600
- }), ctx.g.setParent(k.id, graphColumn(column).id), xynode;
13601
- }
13602
- function createNode(column, nodeType, element, ctx) {
13603
- const xynodes = ctx.columns[column];
13604
- let node2 = xynodes.get(element.id);
13832
+ function createNode$1(nodeType, element, ctx) {
13833
+ let node2 = ctx.xynodes.get(element.id);
13605
13834
  if (node2)
13606
- return invariant(node2.type !== "empty", `Node ${element.id} is empty`), node2;
13835
+ return node2;
13607
13836
  const g = ctx.g, parent = x$1(
13608
13837
  element.ancestors(),
13609
- u$6((ancestor) => !isAncestor(ancestor.id, ctx.subjectId)),
13610
- f(
13611
- (ancestor) => ctx.diagramNodes.has(ancestor.id) || ctx.connected[column].has(ancestor.id) || ctx.scope === "global" && ctx.subjectElement.ascendingSiblings().some((s2) => s2.id === ancestor.id)
13612
- ),
13613
- (found) => found ? createNode(column, "compound", found, ctx) : null
13838
+ u$7((ancestor) => !isAncestor(ancestor.id, ctx.edge.source) && !isAncestor(ancestor.id, ctx.edge.target)),
13839
+ d(),
13840
+ (found) => found ? createNode$1("compound", found, ctx) : null
13614
13841
  ), xynode = {
13615
13842
  type: nodeType,
13616
- id: `${column}::${element.id}`,
13843
+ id: element.id,
13617
13844
  position: { x: 0, y: 0 },
13618
13845
  data: {
13619
- ...nodeData(element, ctx),
13620
- column
13846
+ ...nodeData$1(element, ctx)
13621
13847
  },
13622
- zIndex: ZIndexes[nodeType],
13848
+ zIndex: ZIndexes$1[nodeType],
13623
13849
  ...!!parent && { parentId: parent.id }
13624
13850
  };
13625
- xynodes.set(element.id, xynode);
13626
- const k = graphId(xynode);
13627
- g.setNode(k.id, sized()), xynode.type === "compound" && (g.setNode(k.id, {
13628
- padding: 40
13629
- }), g.setNode(k.port, {
13630
- width: Sizes.nodeWidth - Sizes.dagre.ranksep,
13631
- height: Sizes.compoundLabelHeight
13632
- }), g.setParent(k.port, k.id));
13633
- const parentGraphId = parent ? graphId(parent).body : graphColumn(column).id;
13634
- return g.setParent(k.id, parentGraphId), xynode;
13635
- }
13636
- function applyDagreLayout(g) {
13851
+ ctx.xynodes.set(element.id, xynode);
13852
+ const k = graphId$1(xynode);
13853
+ if (g.setNode(k.id, sized$1()), xynode.type === "compound" && (g.setNode(k.port, {
13854
+ width: Sizes$1.nodeWidth - Sizes$1.dagre.ranksep,
13855
+ height: Sizes$1.compoundLabelHeight
13856
+ }), g.setParent(k.port, k.id)), parent) {
13857
+ const parentGraphId = graphId$1(parent).body;
13858
+ g.setParent(k.id, parentGraphId);
13859
+ }
13860
+ return xynode;
13861
+ }
13862
+ function applyDagreLayout$1(g) {
13637
13863
  return dagre$1.layout(g), function nodeBounds(nodeId, relativeTo) {
13638
13864
  const { x: x2, y: y2, width: width2, height } = g.node(nodeId), pos = {
13639
13865
  position: {
@@ -13656,205 +13882,99 @@ function applyDagreLayout(g) {
13656
13882
  };
13657
13883
  };
13658
13884
  }
13659
- function addEdge(ctx, props2) {
13660
- const { source, target, relations } = props2, ids = relations.map((r2) => r2.id).join("_"), label2 = t$5(relations)?.title ?? "untitled", isMultiple = relations.length > 1, edge = {
13661
- id: `rel${ctx.edges.length + 1}_${ids}`,
13662
- type: "relation",
13663
- source,
13664
- target,
13665
- sourceHandle: target,
13666
- targetHandle: source,
13667
- data: {
13668
- relations
13669
- },
13670
- label: isMultiple ? `${relations.length} relationships` : label2,
13671
- zIndex: ZIndexes.edge,
13672
- markerEnd: {
13673
- type: MarkerType.ArrowClosed,
13674
- width: isMultiple ? 7 : 9
13675
- },
13676
- style: {
13677
- strokeWidth: isMultiple ? 5 : 2.2,
13678
- strokeDasharray: isMultiple ? void 0 : "5, 5"
13679
- }
13885
+ function layout$1(edgeId, view, likec4model) {
13886
+ const edge = view.edges.find((e2) => e2.id === edgeId);
13887
+ invariant(edge, "edge not found");
13888
+ const all = /* @__PURE__ */ new Set([edge.source, edge.target]), relations = edge.relations.map((r2) => {
13889
+ const relation = likec4model.relationship(r2).relationship;
13890
+ return all.add(relation.source), all.add(relation.target), relation;
13891
+ }).sort(compareRelations).reverse(), diagramNodes = new Map(view.nodes.map((n2) => [n2.id, n2])), g = createGraph$1(), ctx = {
13892
+ g,
13893
+ xynodes: /* @__PURE__ */ new Map(),
13894
+ edge,
13895
+ diagramNodes,
13896
+ edges: []
13680
13897
  };
13681
- ctx.edges.push(edge);
13682
- }
13683
- function processRelations(props2) {
13684
13898
  x$1(
13685
- props2.incoming,
13686
- i$2((r2) => r2.source),
13687
- t$2(),
13688
- m$1((a2, b2) => compareFqnHierarchically(a2[0], b2[0])),
13899
+ [...all],
13900
+ m$1(compareFqnHierarchically),
13689
13901
  t$7(),
13690
- u$3(([sourceId, relations]) => {
13691
- try {
13692
- props2.forEachIncoming(sourceId, relations);
13693
- } catch (e2) {
13694
- console.error("Error in forEachIncoming", e2);
13695
- }
13902
+ u$4((id2) => {
13903
+ const element = likec4model.element(id2);
13904
+ createNode$1("element", element, ctx);
13696
13905
  })
13697
- ), x$1(
13698
- props2.outgoing,
13699
- i$2((r2) => r2.target),
13700
- t$2(),
13701
- m$1((a2, b2) => compareFqnHierarchically(a2[0], b2[0])),
13702
- t$7(),
13703
- u$3(([targetId, relations]) => {
13704
- try {
13705
- props2.forEachOutgoing(targetId, relations);
13706
- } catch (e2) {
13707
- console.error("Error in forEachOutgoing", e2);
13906
+ ), relations.length === 1 && all.size < 4 && g.setDefaultEdgeLabel(() => ({ width: 250 }));
13907
+ for (const relation of relations) {
13908
+ const source = ctx.xynodes.get(relation.source);
13909
+ invariant(source, "source node not found");
13910
+ const target = ctx.xynodes.get(relation.target);
13911
+ invariant(target, "target node not found"), source.data.ports.out.push(target.id), target.data.ports.in.push(source.id), g.setEdge(graphId$1(source).port, graphId$1(target).port);
13912
+ const edge2 = {
13913
+ id: relation.id,
13914
+ type: "relation",
13915
+ source: source.id,
13916
+ target: target.id,
13917
+ sourceHandle: target.id,
13918
+ targetHandle: source.id,
13919
+ data: {
13920
+ relation
13921
+ },
13922
+ label: relation.title,
13923
+ zIndex: ZIndexes$1.edge,
13924
+ markerEnd: {
13925
+ type: MarkerType.ArrowClosed,
13926
+ width: 10
13927
+ },
13928
+ style: {
13929
+ strokeWidth: 2.2,
13930
+ strokeDasharray: "5, 5"
13708
13931
  }
13709
- })
13710
- );
13711
- }
13712
- function layout(subjectId, view, likec4model, scope) {
13713
- const diagramNodes = new Map(view.nodes.map((n2) => [n2.id, n2])), subjectElement = likec4model.element(subjectId);
13714
- diagramNodes.has(subjectId) || (scope = "global");
13715
- const g = createGraph(), ctx = {
13716
- scope,
13717
- g,
13718
- diagramNodes,
13719
- subjectId,
13720
- subjectElement,
13721
- connected: i$3(
13722
- ["incomers", "outgoers"],
13723
- (column) => new Set(subjectElement[column]().map((m2) => m2.id))
13724
- ),
13725
- columns: {
13726
- incomers: /* @__PURE__ */ new Map(),
13727
- outgoers: /* @__PURE__ */ new Map()
13728
- },
13729
- edges: []
13730
- }, subject = {
13731
- id: subjectElement.id,
13732
- type: "element",
13733
- position: { x: 0, y: 0 },
13734
- data: {
13735
- ...nodeData(subjectElement, ctx),
13736
- column: "subject"
13737
- },
13738
- zIndex: 3,
13739
- selectable: !1,
13740
- focusable: !1,
13741
- ...sized()
13742
- };
13743
- if (g.setNode(subject.id, sized()), g.setParent(subject.id, graphColumn("subject").id), processRelations({
13744
- // Based on the scope we pick relationships
13745
- ...scope === "global" ? {
13746
- incoming: subjectElement.incoming().map((r2) => r2.relationship),
13747
- outgoing: subjectElement.outgoing().map((r2) => r2.relationship)
13748
- } : {
13749
- incoming: likec4model.view(view.id).element(subjectId).incoming().flatMap((c) => c.relationships().map((r2) => r2.relationship)),
13750
- outgoing: likec4model.view(view.id).element(subjectId).outgoing().flatMap((c) => c.relationships().map((r2) => r2.relationship))
13751
- },
13752
- forEachIncoming(sourceId, relations) {
13753
- const source = createNode("incomers", "element", likec4model.element(sourceId), ctx);
13754
- g.setEdge(graphId(source).port, subject.id, {
13755
- weight: source.type === "compound" ? 0 : 1
13756
- });
13757
- const op = source.type === "compound" ? "unshift" : "push";
13758
- subject.data.ports.left[op]({
13759
- id: source.id,
13760
- type: "in"
13761
- }), source.data.ports.right.push({
13762
- id: subject.id,
13763
- type: "out"
13764
- }), addEdge(ctx, {
13765
- source: source.id,
13766
- target: subject.id,
13767
- relations
13768
- });
13769
- },
13770
- forEachOutgoing(targetId, relations) {
13771
- const target = createNode("outgoers", "element", likec4model.element(targetId), ctx);
13772
- g.setEdge(subjectElement.id, graphId(target).port, {
13773
- weight: target.type === "compound" ? 2 : 1
13774
- });
13775
- const op = target.type === "compound" ? "unshift" : "push";
13776
- subject.data.ports.right[op]({
13777
- id: target.id,
13778
- type: "out"
13779
- }), target.data.ports.left.push({
13780
- id: subject.id,
13781
- type: "in"
13782
- }), addEdge(ctx, {
13783
- source: subjectElement.id,
13784
- target: target.id,
13785
- relations
13786
- });
13787
- }
13788
- }), ctx.columns.incomers.size == 0) {
13789
- const source = createEmptyNode("incomers", ctx);
13790
- g.setEdge(graphId(source).port, subject.id);
13791
- }
13792
- if (ctx.columns.outgoers.size == 0) {
13793
- const target = createEmptyNode("outgoers", ctx);
13794
- g.setEdge(subject.id, graphId(target).port);
13932
+ };
13933
+ ctx.edges.push(edge2);
13795
13934
  }
13796
- const subjectPortsCount = Math.max(subject.data.ports.left.length, subject.data.ports.right.length);
13797
- subjectPortsCount > 2 && (g.node(subjectElement.id).height = Sizes.hodeHeight + (subjectPortsCount - 2) * 1);
13798
- const nodebounds = applyDagreLayout(ctx.g), xynodes = [
13799
- subject,
13800
- ...ctx.columns.incomers.values(),
13801
- ...ctx.columns.outgoers.values()
13802
- ].map((node2) => ({
13803
- ...node2,
13804
- ...nodebounds(node2.id, node2.parentId)
13805
- })), sortedPorts = (ports) => ports.length < 2 ? ports : x$1(
13935
+ const nodebounds = applyDagreLayout$1(ctx.g), sortedPorts = (ports) => ports.length < 2 ? ports : x$1(
13806
13936
  ports,
13807
13937
  m((port) => ({
13808
13938
  port,
13809
- topY: nodebounds(port.id).position.y
13939
+ topY: nodebounds(port).position.y
13810
13940
  })),
13811
- a$3(p$2("topY")),
13812
- m(p$2("port"))
13813
- );
13814
- for (const node2 of xynodes) {
13815
- if (node2.type === "empty") {
13816
- const subjectPosition = nodebounds(subject.id);
13817
- node2.position.y = subjectPosition.position.y + subjectPosition.height / 2 - node2.height / 2, node2.data.column === "incomers" ? node2.position.x = subjectPosition.position.x - node2.width - Sizes.emptyNodeOffset : node2.position.x = subjectPosition.position.x + subjectPosition.width + Sizes.emptyNodeOffset;
13818
- continue;
13819
- }
13820
- node2.data.ports.left.length > 0 && (node2.data.ports.left = sortedPorts(node2.data.ports.left)), node2.data.ports.right.length > 0 && (node2.data.ports.right = sortedPorts(node2.data.ports.right));
13821
- }
13941
+ a$3(p$3("topY")),
13942
+ m(p$3("port"))
13943
+ ), xynodes = [...ctx.xynodes.values()].map((node2) => (node2.data.ports.in.length > 1 && (node2.data.ports.in = sortedPorts(node2.data.ports.in)), node2.data.ports.out.length > 1 && (node2.data.ports.out = sortedPorts(node2.data.ports.out)), {
13944
+ ...node2,
13945
+ ...nodebounds(node2.id, node2.parentId)
13946
+ }));
13822
13947
  return {
13823
13948
  view,
13824
- viewIncludesSubject: diagramNodes.has(subjectId),
13825
- subject: subjectElement,
13949
+ edge,
13826
13950
  edges: ctx.edges,
13827
- nodes: xynodes
13951
+ nodes: xynodes,
13952
+ bounds: {
13953
+ x: 0,
13954
+ y: 0,
13955
+ width: g.graph().width ?? 0,
13956
+ height: g.graph().height ?? 0
13957
+ }
13828
13958
  };
13829
13959
  }
13830
- function useLayoutedRelationships(scope) {
13831
- const {
13832
- subjectId,
13833
- view
13834
- } = useDiagramState((s2) => ({
13835
- subjectId: s2.activeOverlay?.relationshipsOf,
13836
- view: s2.view
13837
- }));
13838
- invariant(subjectId, "subject not found");
13839
- const likec4model = useLikeC4Model(!0);
13840
- return useMemo$1(() => layout(
13841
- subjectId,
13960
+ function useLayoutedEdgeDetails(edgeId) {
13961
+ const view = useDiagramState((s2) => s2.view), likec4model = useLikeC4Model(!0);
13962
+ return useMemo$1(() => layout$1(
13963
+ edgeId,
13842
13964
  view,
13843
- likec4model,
13844
- scope
13965
+ likec4model
13845
13966
  ), [
13846
- subjectId,
13967
+ edgeId,
13847
13968
  view,
13848
13969
  likec4model,
13849
- layout,
13850
- scope
13970
+ layout$1
13851
13971
  ]);
13852
13972
  }
13853
- var elementNode = "_1ittjvh0", elementNodeContent = "_1ittjvh1", elementNodeTitle = "_1ittjvh2", elementNodeDescription = "_1ittjvh3", compoundNodeBody = "_1ittjvh4", compoundNodeTitle = "_1ittjvh5", cssShapeSvg$1 = "_1ittjvh6", edgePath = "_1ittjvh7", edgeLabel$1 = "_1ittjvh8", edgeLabelText$1 = "_1ittjvh9", emptyNode = "_1ittjvha", navigateBtnBox = "_1ittjvhb", navigateBtn$2 = "_1ittjvhc";
13854
- const Text$3 = Text$4.withProps({
13973
+ var elementNode$1 = "xsefl30", elementNodeContent$1 = "xsefl31", elementNodeTitle$1 = "xsefl32", elementNodeDescription$1 = "xsefl33", compoundNodeBody$1 = "xsefl34", compoundNodeTitle$1 = "xsefl35", cssShapeSvg$2 = "xsefl36", edgePath$1 = "xsefl37", edgeLabel$2 = "xsefl38", edgeLabelText$2 = "xsefl39", edgeLabelTechnology$1 = "xsefl3a", navigateBtnBox$1 = "xsefl3b", navigateBtn$3 = "xsefl3c";
13974
+ const Text$5 = Text$6.withProps({
13855
13975
  component: "div"
13856
13976
  });
13857
- function CompoundNode({
13977
+ function CompoundNode$1({
13858
13978
  data: {
13859
13979
  element,
13860
13980
  ports,
@@ -13868,15 +13988,15 @@ function CompoundNode({
13868
13988
  m$3.div,
13869
13989
  {
13870
13990
  className: clsx([
13871
- compoundNodeBody,
13991
+ compoundNodeBody$1,
13872
13992
  "likec4-compound-node"
13873
13993
  ]),
13874
- "data-compound-depth": 2,
13994
+ "data-compound-depth": 3,
13875
13995
  "data-likec4-color": element.color,
13876
13996
  animate: {
13877
13997
  opacity: data.dimmed ? 0.15 : 1,
13878
13998
  transition: {
13879
- delay: data.dimmed ? 0.8 : 0
13999
+ delay: data.dimmed === !0 ? 0.4 : 0
13880
14000
  }
13881
14001
  },
13882
14002
  ...selectable && {
@@ -13890,15 +14010,15 @@ function CompoundNode({
13890
14010
  scale: 1
13891
14011
  }
13892
14012
  },
13893
- children: /* @__PURE__ */ jsx(Text$3, { className: compoundNodeTitle, maw: width2 - 20, children: element.title })
14013
+ children: /* @__PURE__ */ jsx(Text$5, { className: compoundNodeTitle$1, maw: width2 - 20, children: element.title })
13894
14014
  }
13895
14015
  ),
13896
- ports.left.map(({ id: id2, type }, i2) => /* @__PURE__ */ jsx(
14016
+ ports.out.map((id2, i2) => /* @__PURE__ */ jsx(
13897
14017
  Handle,
13898
14018
  {
13899
14019
  id: id2,
13900
- type: type === "in" ? "target" : "source",
13901
- position: Position.Left,
14020
+ type: "source",
14021
+ position: Position.Right,
13902
14022
  style: {
13903
14023
  visibility: "hidden",
13904
14024
  top: `${16 + 20 * i2}px`
@@ -13906,12 +14026,12 @@ function CompoundNode({
13906
14026
  },
13907
14027
  id2
13908
14028
  )),
13909
- ports.right.map(({ id: id2, type }, i2) => /* @__PURE__ */ jsx(
14029
+ ports.in.map((id2, i2) => /* @__PURE__ */ jsx(
13910
14030
  Handle,
13911
14031
  {
13912
14032
  id: id2,
13913
- type: type === "in" ? "target" : "source",
13914
- position: Position.Right,
14033
+ type: "target",
14034
+ position: Position.Left,
13915
14035
  style: {
13916
14036
  visibility: "hidden",
13917
14037
  top: `${16 + 20 * i2}px`
@@ -13921,7 +14041,7 @@ function CompoundNode({
13921
14041
  ))
13922
14042
  ] });
13923
14043
  }
13924
- var container$5 = "_14ylloj1", handleCenter = "_14ylloj2", containerAnimated = "_14ylloj3", dimmed$2 = "_14ylloj4", indicator$1 = "_14ylloj7", fillElementFill = "_14ylloj8", fillMixStroke = "_14ylloja", hasIcon = "_14yllojb", title$3 = "_14ylloje", description$1 = "_14yllojf", technology = "_14yllojg", elementDataContainer = "_14yllojh", elementTextData = "_14ylloji", elementIcon = "_14yllojj", cssShapeSvg = "_14yllojm", navigateBtn$1 = "_14yllojn";
14044
+ var container$6 = "_14ylloj1", handleCenter = "_14ylloj2", containerAnimated = "_14ylloj3", dimmed$2 = "_14ylloj4", indicator$1 = "_14ylloj7", fillElementFill = "_14ylloj8", fillMixStroke = "_14ylloja", hasIcon = "_14yllojb", title$3 = "_14ylloje", description$1 = "_14yllojf", technology = "_14yllojg", elementDataContainer = "_14yllojh", elementTextData = "_14ylloji", elementIcon = "_14yllojj", cssShapeSvg$1 = "_14yllojm", navigateBtn$2 = "_14yllojn";
13925
14045
  function cylinderSVGPath(diameter, height, tilt = 0.065) {
13926
14046
  const radius = Math.round(diameter / 2), rx = radius, ry = toDomPrecision(tilt * radius), tiltAdjustedHeight = height - 2 * ry;
13927
14047
  return {
@@ -14003,82 +14123,967 @@ function ElementShapeSvg({ shape, w, h }) {
14003
14123
  rx: 6,
14004
14124
  strokeWidth: 0
14005
14125
  }
14006
- ),
14007
- /* @__PURE__ */ jsx(
14008
- "svg",
14009
- {
14010
- x: w - PersonIcon.width - 6,
14011
- y: h - PersonIcon.height,
14012
- width: PersonIcon.width,
14013
- height: PersonIcon.height,
14014
- viewBox: `0 0 ${PersonIcon.width} ${PersonIcon.height}`,
14015
- className: fillMixStroke,
14016
- children: /* @__PURE__ */ jsx(
14017
- "path",
14018
- {
14019
- strokeWidth: 0,
14020
- d: PersonIcon.path
14021
- }
14022
- )
14126
+ ),
14127
+ /* @__PURE__ */ jsx(
14128
+ "svg",
14129
+ {
14130
+ x: w - PersonIcon.width - 6,
14131
+ y: h - PersonIcon.height,
14132
+ width: PersonIcon.width,
14133
+ height: PersonIcon.height,
14134
+ viewBox: `0 0 ${PersonIcon.width} ${PersonIcon.height}`,
14135
+ className: fillMixStroke,
14136
+ children: /* @__PURE__ */ jsx(
14137
+ "path",
14138
+ {
14139
+ strokeWidth: 0,
14140
+ d: PersonIcon.path
14141
+ }
14142
+ )
14143
+ }
14144
+ )
14145
+ ] });
14146
+ case "queue": {
14147
+ const { path, rx, ry } = queueSVGPath(w, h);
14148
+ return /* @__PURE__ */ jsxs(Fragment$1, { children: [
14149
+ /* @__PURE__ */ jsx("path", { d: path, strokeWidth: 2 }),
14150
+ /* @__PURE__ */ jsx("ellipse", { cx: rx, cy: ry, ry: ry - 0.75, rx, className: fillMixStroke, strokeWidth: 2 })
14151
+ ] });
14152
+ }
14153
+ case "storage":
14154
+ case "cylinder": {
14155
+ const { path, rx, ry } = cylinderSVGPath(w, h);
14156
+ return /* @__PURE__ */ jsxs(Fragment$1, { children: [
14157
+ /* @__PURE__ */ jsx("path", { d: path, strokeWidth: 2 }),
14158
+ /* @__PURE__ */ jsx("ellipse", { cx: rx, cy: ry, ry, rx: rx - 0.75, className: fillMixStroke, strokeWidth: 2 })
14159
+ ] });
14160
+ }
14161
+ case "rectangle":
14162
+ return /* @__PURE__ */ jsx(
14163
+ "rect",
14164
+ {
14165
+ width: w,
14166
+ height: h,
14167
+ rx: 6,
14168
+ strokeWidth: 0
14169
+ }
14170
+ );
14171
+ default:
14172
+ return nonexhaustive(shape);
14173
+ }
14174
+ }
14175
+ function SelectedIndicator({ shape, w, h }) {
14176
+ switch (shape) {
14177
+ case "queue":
14178
+ return /* @__PURE__ */ jsx("path", { d: queueSVGPath(w, h).path });
14179
+ case "storage":
14180
+ case "cylinder":
14181
+ return /* @__PURE__ */ jsx("path", { d: cylinderSVGPath(w, h).path });
14182
+ default:
14183
+ return /* @__PURE__ */ jsx(
14184
+ "rect",
14185
+ {
14186
+ x: -1,
14187
+ y: -1,
14188
+ width: w + 2,
14189
+ height: h + 2,
14190
+ rx: 6
14191
+ }
14192
+ );
14193
+ }
14194
+ }
14195
+ const Action$2 = ActionIcon$1.withProps({
14196
+ className: "nodrag nopan " + navigateBtn$3,
14197
+ radius: "md",
14198
+ role: "button",
14199
+ onDoubleClick: stopPropagation$1,
14200
+ onPointerDownCapture: stopPropagation$1
14201
+ }), Text$4 = Text$6.withProps({
14202
+ component: "div"
14203
+ });
14204
+ function selector$6(s2) {
14205
+ return {
14206
+ currentViewId: s2.view.id,
14207
+ onNavigateTo: s2.onNavigateTo,
14208
+ onOpenSource: s2.onOpenSourceElement
14209
+ };
14210
+ }
14211
+ function ElementNode$1({
14212
+ data: {
14213
+ element,
14214
+ ports,
14215
+ navigateTo,
14216
+ ...data
14217
+ },
14218
+ selectable = !0,
14219
+ width: w = 100,
14220
+ height: h = 100
14221
+ }) {
14222
+ const overlay = useOverlayDialog(), {
14223
+ currentViewId,
14224
+ onNavigateTo,
14225
+ onOpenSource
14226
+ } = useDiagramState(selector$6);
14227
+ return /* @__PURE__ */ jsxs(Fragment$1, { children: [
14228
+ /* @__PURE__ */ jsxs(
14229
+ m$3.div,
14230
+ {
14231
+ className: clsx([
14232
+ elementNode$1,
14233
+ "likec4-element-node"
14234
+ ]),
14235
+ "data-likec4-color": element.color,
14236
+ "data-likec4-shape": element.shape,
14237
+ animate: {
14238
+ opacity: data.dimmed ? 0.15 : 1,
14239
+ transition: {
14240
+ delay: data.dimmed === !0 ? 0.4 : 0
14241
+ }
14242
+ },
14243
+ ...selectable && {
14244
+ whileHover: {
14245
+ scale: 1.045,
14246
+ transition: {
14247
+ delay: 0.15
14248
+ }
14249
+ },
14250
+ whileTap: {
14251
+ scale: 0.97
14252
+ }
14253
+ },
14254
+ children: [
14255
+ /* @__PURE__ */ jsx(
14256
+ "svg",
14257
+ {
14258
+ className: clsx(
14259
+ cssShapeSvg$2
14260
+ ),
14261
+ viewBox: `0 0 ${w} ${h}`,
14262
+ width: w,
14263
+ height: h,
14264
+ children: /* @__PURE__ */ jsx(ElementShapeSvg, { shape: element.shape, w, h })
14265
+ }
14266
+ ),
14267
+ /* @__PURE__ */ jsxs(Box, { className: elementNodeContent$1, children: [
14268
+ /* @__PURE__ */ jsx(Text$4, { className: elementNodeTitle$1, lineClamp: 2, children: element.title }),
14269
+ element.description && /* @__PURE__ */ jsx(Text$4, { className: elementNodeDescription$1, lineClamp: 4, children: element.description })
14270
+ ] }),
14271
+ /* @__PURE__ */ jsxs(Group, { className: navigateBtnBox$1, children: [
14272
+ navigateTo && onNavigateTo && navigateTo !== currentViewId && /* @__PURE__ */ jsx(
14273
+ Action$2,
14274
+ {
14275
+ onClick: (event) => {
14276
+ event.stopPropagation(), setTimeout(() => onNavigateTo(navigateTo), 100), overlay.close();
14277
+ },
14278
+ children: /* @__PURE__ */ jsx(IconZoomScan, { stroke: 1.8, style: { width: "75%" } })
14279
+ }
14280
+ ),
14281
+ /* @__PURE__ */ jsx(
14282
+ Action$2,
14283
+ {
14284
+ onClick: (event) => {
14285
+ event.stopPropagation(), overlay.openOverlay({
14286
+ relationshipsOf: data.fqn
14287
+ });
14288
+ },
14289
+ children: /* @__PURE__ */ jsx(IconTransform, { stroke: 1.8, style: { width: "72%" } })
14290
+ }
14291
+ ),
14292
+ onOpenSource && /* @__PURE__ */ jsx(
14293
+ Action$2,
14294
+ {
14295
+ onClick: (event) => {
14296
+ event.stopPropagation(), onOpenSource(data.fqn);
14297
+ },
14298
+ children: /* @__PURE__ */ jsx(IconFileSymlink, { stroke: 1.8, style: { width: "72%" } })
14299
+ }
14300
+ )
14301
+ ] })
14302
+ ]
14303
+ }
14304
+ ),
14305
+ ports.out.map((id2, i2) => /* @__PURE__ */ jsx(
14306
+ Handle,
14307
+ {
14308
+ id: id2,
14309
+ type: "source",
14310
+ position: Position.Right,
14311
+ style: {
14312
+ visibility: "hidden",
14313
+ top: `${15 + (i2 + 1) * ((h - 30) / (ports.out.length + 1))}px`
14314
+ }
14315
+ },
14316
+ id2
14317
+ )),
14318
+ ports.in.map((id2, i2) => /* @__PURE__ */ jsx(
14319
+ Handle,
14320
+ {
14321
+ id: id2,
14322
+ type: "target",
14323
+ position: Position.Left,
14324
+ style: {
14325
+ visibility: "hidden",
14326
+ top: `${15 + (i2 + 1) * ((h - 30) / (ports.in.length + 1))}px`
14327
+ }
14328
+ },
14329
+ id2
14330
+ ))
14331
+ ] });
14332
+ }
14333
+ function RelationshipEdge$2({
14334
+ data,
14335
+ label: label2,
14336
+ ...props2
14337
+ }) {
14338
+ const onNavigateTo = useDiagramState((s2) => s2.onNavigateTo), [edgePath2, labelX, labelY] = getBezierPath(props2), navigateTo = data.relation.navigateTo;
14339
+ return /* @__PURE__ */ jsxs(Fragment$1, { children: [
14340
+ /* @__PURE__ */ jsx(
14341
+ "g",
14342
+ {
14343
+ className: edgePath$1,
14344
+ "data-edge-dimmed": data.dimmed,
14345
+ "data-edge-hovered": data.hovered,
14346
+ children: /* @__PURE__ */ jsx(
14347
+ BaseEdge,
14348
+ {
14349
+ path: edgePath2,
14350
+ ...props2
14351
+ }
14352
+ )
14353
+ }
14354
+ ),
14355
+ /* @__PURE__ */ jsx(EdgeLabelRenderer, { children: /* @__PURE__ */ jsxs(
14356
+ Stack$1,
14357
+ {
14358
+ gap: 2,
14359
+ style: {
14360
+ position: "absolute",
14361
+ transform: `translate(-50%, -50%) translate(${labelX}px,${labelY}px)`,
14362
+ maxWidth: Math.abs(props2.targetX - props2.sourceX - 40),
14363
+ zIndex: ZIndexes$1.max
14364
+ },
14365
+ className: clsx([
14366
+ edgeLabel$2,
14367
+ "nodrag nopan"
14368
+ ]),
14369
+ "data-edge-dimmed": data.dimmed,
14370
+ "data-edge-hovered": data.hovered,
14371
+ children: [
14372
+ label2 && /* @__PURE__ */ jsx(Text$6, { component: "div", className: edgeLabelText$2, lineClamp: 3, children: label2 }),
14373
+ data.relation.technology && /* @__PURE__ */ jsxs(Text$6, { component: "div", className: edgeLabelTechnology$1, children: [
14374
+ "[ ",
14375
+ data.relation.technology,
14376
+ " ]"
14377
+ ] }),
14378
+ navigateTo && onNavigateTo && /* @__PURE__ */ jsx(Box, { ta: "center", mt: 4, children: /* @__PURE__ */ jsx(
14379
+ ActionIcon$1,
14380
+ {
14381
+ variant: "default",
14382
+ size: "sm",
14383
+ radius: "sm",
14384
+ onPointerDownCapture: stopPropagation$1,
14385
+ onClick: (event) => {
14386
+ event.stopPropagation(), onNavigateTo(navigateTo, event);
14387
+ },
14388
+ role: "button",
14389
+ onDoubleClick: stopPropagation$1,
14390
+ children: /* @__PURE__ */ jsx(IconZoomScan, {})
14391
+ }
14392
+ ) })
14393
+ ]
14394
+ }
14395
+ ) })
14396
+ ] });
14397
+ }
14398
+ const nodeTypes$2 = {
14399
+ element: ElementNode$1,
14400
+ compound: CompoundNode$1
14401
+ }, edgeTypes$2 = {
14402
+ relation: RelationshipEdge$2
14403
+ }, resetDimmedAndHovered$1 = (xyflow) => {
14404
+ xyflow.setEdges(
14405
+ (edges) => edges.map((edge) => ({
14406
+ ...edge,
14407
+ data: {
14408
+ ...edge.data,
14409
+ dimmed: !1,
14410
+ hovered: !1
14411
+ },
14412
+ animated: !1
14413
+ }))
14414
+ ), xyflow.setNodes(
14415
+ (nodes) => nodes.map(
14416
+ (n2) => ({
14417
+ ...n2,
14418
+ data: {
14419
+ ...n2.data,
14420
+ dimmed: !1,
14421
+ hovered: !1
14422
+ }
14423
+ })
14424
+ )
14425
+ );
14426
+ }, EdgeDetailsXYFlow = memo$1(function({ edgeId }) {
14427
+ const diagramStore = useDiagramStoreApi(), {
14428
+ view,
14429
+ edge,
14430
+ edges,
14431
+ nodes,
14432
+ bounds
14433
+ } = useLayoutedEdgeDetails(edgeId), boundsRef = useSyncedRef(bounds), xyflow = useReactFlow(), xystore = useStoreApi(), fitview = useDebouncedCallback(
14434
+ () => {
14435
+ const {
14436
+ width: width2,
14437
+ height
14438
+ } = xystore.getState(), viewport = getViewportForBounds(
14439
+ {
14440
+ ...boundsRef.current,
14441
+ height: Math.max(boundsRef.current.height + 100, height - 200)
14442
+ // Add some padding to the bottom
14443
+ },
14444
+ width2,
14445
+ height,
14446
+ 0.2,
14447
+ 1,
14448
+ 0.2
14449
+ );
14450
+ xyflow.setViewport(viewport, { duration: 350 });
14451
+ },
14452
+ [xyflow],
14453
+ 150
14454
+ );
14455
+ useEffect$1(() => {
14456
+ xyflow.setNodes(nodes), xyflow.setEdges(edges);
14457
+ }, [nodes, edges]);
14458
+ const zoomable = !0;
14459
+ return useUpdateEffect$1(() => fitview(), [edge.id]), /* @__PURE__ */ jsxs(
14460
+ index,
14461
+ {
14462
+ defaultEdges: [],
14463
+ defaultNodes: [],
14464
+ nodeTypes: nodeTypes$2,
14465
+ edgeTypes: edgeTypes$2,
14466
+ defaultMarkerColor: "var(--xy-edge-stroke)",
14467
+ zoomOnPinch: zoomable,
14468
+ zoomOnScroll: !1,
14469
+ zoomOnDoubleClick: !1,
14470
+ maxZoom: 1.5,
14471
+ minZoom: 0.1,
14472
+ fitView: !0,
14473
+ fitViewOptions: {
14474
+ padding: 0.2,
14475
+ maxZoom: 1,
14476
+ minZoom: 0.1,
14477
+ includeHiddenNodes: !0
14478
+ },
14479
+ preventScrolling: !0,
14480
+ noDragClassName: "nodrag",
14481
+ noPanClassName: "nopan",
14482
+ panOnScroll: !0,
14483
+ panOnDrag: !0,
14484
+ elementsSelectable: !0,
14485
+ nodesFocusable: !1,
14486
+ edgesFocusable: !1,
14487
+ nodesDraggable: !1,
14488
+ onEdgeMouseEnter: (_, edge2) => {
14489
+ xyflow.setEdges(
14490
+ (edges2) => edges2.map((e2) => ({
14491
+ ...e2,
14492
+ data: {
14493
+ ...e2.data,
14494
+ dimmed: e2.id !== edge2.id,
14495
+ hovered: e2.id === edge2.id
14496
+ },
14497
+ zIndex: e2.id === edge2.id ? ZIndexes$1.max : ZIndexes$1.edge,
14498
+ animated: e2.id === edge2.id
14499
+ }))
14500
+ ), xyflow.setNodes(
14501
+ (nodes2) => nodes2.map((n2) => ({
14502
+ ...n2,
14503
+ data: {
14504
+ ...n2.data,
14505
+ dimmed: n2.id !== edge2.source && n2.id !== edge2.target
14506
+ }
14507
+ }))
14508
+ );
14509
+ },
14510
+ onEdgeMouseLeave: () => {
14511
+ resetDimmedAndHovered$1(xyflow);
14512
+ },
14513
+ onEdgeClick: (e2, edge2) => {
14514
+ e2.stopPropagation(), diagramStore.getState().onOpenSourceRelation?.(edge2.data.relation.id);
14515
+ },
14516
+ children: [
14517
+ /* @__PURE__ */ jsx(Panel$1, { position: "top-center", children: /* @__PURE__ */ jsx(Group, { gap: "xs", wrap: "nowrap", children: /* @__PURE__ */ jsx(
14518
+ SelectEdge,
14519
+ {
14520
+ view,
14521
+ edge
14522
+ }
14523
+ ) }) }),
14524
+ /* @__PURE__ */ jsx(EdgeData, { edge, top: bounds.height, width: bounds.width })
14525
+ ]
14526
+ }
14527
+ );
14528
+ }), EdgeData = ({ edge, top, width: width2 }) => /* @__PURE__ */ jsx(ViewportPortal, { children: /* @__PURE__ */ jsx(
14529
+ Box,
14530
+ {
14531
+ maw: width2,
14532
+ style: {
14533
+ transform: `translate(100px, ${top + 32}px)`
14534
+ },
14535
+ children: /* @__PURE__ */ jsxs(Box, { className: edgeDataGrid, children: [
14536
+ /* @__PURE__ */ jsx(Text$6, { size: "xs", fw: 500, c: "dimmed", children: "technology" }),
14537
+ /* @__PURE__ */ jsx(Text$6, { children: edge.technology || "unknown" }),
14538
+ /* @__PURE__ */ jsx(Text$6, { size: "xs", fw: 500, c: "dimmed", children: "description" }),
14539
+ /* @__PURE__ */ jsx(Text$6, { children: edge.description || "no description" })
14540
+ ] })
14541
+ }
14542
+ ) });
14543
+ var container$5 = "y6dq321", node = "_1nudxvt0", label = "_1nudxvt1";
14544
+ const classes = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
14545
+ __proto__: null,
14546
+ get label() {
14547
+ return label;
14548
+ },
14549
+ get node() {
14550
+ return node;
14551
+ }
14552
+ }, Symbol.toStringTag, { value: "Module" })), SelectElement = ({
14553
+ subject,
14554
+ viewId,
14555
+ scope,
14556
+ onSelect
14557
+ }) => {
14558
+ const viewport = useRef$1(null), data = useLikeC4ElementsTree(scope === "view" ? viewId : void 0), tree = useTree({
14559
+ multiple: !1
14560
+ });
14561
+ useEffect$1(() => {
14562
+ ancestorsFqn(subject.id).reverse().forEach((id2) => {
14563
+ tree.expand(id2);
14564
+ }), tree.select(subject.id);
14565
+ }, [subject.id]);
14566
+ const theme2 = useComputedColorScheme();
14567
+ return /* @__PURE__ */ jsxs(
14568
+ Popover,
14569
+ {
14570
+ position: "bottom",
14571
+ shadow: "md",
14572
+ keepMounted: !0,
14573
+ withinPortal: !1,
14574
+ closeOnClickOutside: !0,
14575
+ clickOutsideEvents: ["pointerdown", "mousedown", "click"],
14576
+ onOpen: () => {
14577
+ setTimeout(() => {
14578
+ const item = viewport.current?.querySelector(`[data-value="${subject.id}"]`);
14579
+ console.log("item", item), item?.scrollIntoView({ behavior: "instant", block: "nearest" });
14580
+ }, 100);
14581
+ },
14582
+ children: [
14583
+ /* @__PURE__ */ jsx(PopoverTarget, { children: /* @__PURE__ */ jsx(
14584
+ Button,
14585
+ {
14586
+ size: "xs",
14587
+ variant: "light",
14588
+ color: theme2 === "light" ? "dark" : "gray",
14589
+ fw: "500",
14590
+ maw: 250,
14591
+ style: { padding: "0.25rem 0.75rem" },
14592
+ rightSection: /* @__PURE__ */ jsx(IconSelector, { size: 16 }),
14593
+ children: subject.title
14594
+ }
14595
+ ) }),
14596
+ /* @__PURE__ */ jsx(PopoverDropdown, { p: 0, miw: 250, maw: 400, children: /* @__PURE__ */ jsx(ScrollAreaAutosize, { mah: "70vh", scrollbars: "y", type: "never", viewportRef: viewport, children: /* @__PURE__ */ jsx(
14597
+ Tree,
14598
+ {
14599
+ allowRangeSelection: !1,
14600
+ selectOnClick: !1,
14601
+ tree,
14602
+ data,
14603
+ classNames: classes,
14604
+ levelOffset: 8,
14605
+ styles: {
14606
+ label: {
14607
+ paddingTop: 5,
14608
+ paddingBottom: 6
14609
+ }
14610
+ },
14611
+ renderNode: ({ node: node2, selected, expanded, elementProps, hasChildren }) => /* @__PURE__ */ jsxs(Group, { gap: 2, wrap: "nowrap", ...elementProps, py: "3", children: [
14612
+ /* @__PURE__ */ jsx(
14613
+ ActionIcon$1,
14614
+ {
14615
+ variant: "subtle",
14616
+ size: 18,
14617
+ c: "dimmed",
14618
+ style: {
14619
+ visibility: hasChildren ? "visible" : "hidden"
14620
+ },
14621
+ children: /* @__PURE__ */ jsx(
14622
+ IconChevronRight,
14623
+ {
14624
+ stroke: 3.5,
14625
+ style: {
14626
+ transition: "transform 150ms ease",
14627
+ transform: `rotate(${expanded ? "90deg" : "0"})`,
14628
+ width: "80%"
14629
+ }
14630
+ }
14631
+ )
14632
+ }
14633
+ ),
14634
+ /* @__PURE__ */ jsx(
14635
+ Box,
14636
+ {
14637
+ flex: "1 1 100%",
14638
+ w: "100%",
14639
+ onClick: (e2) => {
14640
+ e2.stopPropagation(), onSelect(node2.value), tree.select(node2.value), tree.expand(node2.value);
14641
+ },
14642
+ children: /* @__PURE__ */ jsx(
14643
+ Text$6,
14644
+ {
14645
+ fz: "sm",
14646
+ fw: selected ? "600" : "400",
14647
+ truncate: "end",
14648
+ children: node2.label
14649
+ }
14650
+ )
14651
+ }
14652
+ )
14653
+ ] })
14654
+ }
14655
+ ) }) })
14656
+ ]
14657
+ }
14658
+ );
14659
+ }, graphColumn = (c) => ({
14660
+ name: c,
14661
+ id: `__${c}`,
14662
+ anchor: `__${c}::anchor`
14663
+ }), Sizes = {
14664
+ dagre: {
14665
+ ranksep: 40,
14666
+ nodesep: 20,
14667
+ edgesep: 20
14668
+ },
14669
+ edgeLabel: {
14670
+ width: 60
14671
+ },
14672
+ emptyNodeOffset: 150,
14673
+ nodeWidth: 270,
14674
+ hodeHeight: 160,
14675
+ // Spacer between elements in a compound node
14676
+ // 0 means no spacer
14677
+ spacerHeight: 0,
14678
+ compoundLabelHeight: 1
14679
+ }, ZIndexes = {
14680
+ empty: 2,
14681
+ compound: 2,
14682
+ edge: 3,
14683
+ element: 4,
14684
+ max: 5
14685
+ };
14686
+ function createGraph() {
14687
+ const g = new dagre$1.graphlib.Graph({
14688
+ directed: !0,
14689
+ compound: !0
14690
+ });
14691
+ return g.setGraph({
14692
+ ...Sizes.dagre,
14693
+ rankdir: "LR"
14694
+ }), g.setDefaultEdgeLabel(() => ({ ...Sizes.edgeLabel })), g.setDefaultNodeLabel(() => ({})), ["incomers", "subject", "outgoers"].reduce((prev, column) => {
14695
+ const c = graphColumn(column);
14696
+ return g.setNode(c.id, {}), g.setNode(c.anchor, { width: 40, height: 2 }), g.setParent(c.anchor, c.id), prev && g.setEdge(prev, c.anchor, {
14697
+ width: 0
14698
+ }), c.anchor;
14699
+ }, null), g;
14700
+ }
14701
+ const sized = (height = Sizes.hodeHeight) => ({
14702
+ width: Sizes.nodeWidth,
14703
+ height
14704
+ }), graphId = (node2) => ({
14705
+ id: node2.id,
14706
+ port: node2.type === "compound" ? `${node2.id}::port` : node2.id,
14707
+ // port: `${node.id}::port`,
14708
+ // For nested nodes
14709
+ body: `${node2.id}`,
14710
+ spacer: `${node2.id}:spacer`
14711
+ });
14712
+ function nodeData(element, ctx) {
14713
+ let diagramNode = ctx.diagramNodes.get(element.id);
14714
+ const ancestor = diagramNode ?? (ctx.scope === "view" ? x$1(
14715
+ element.ancestors(),
14716
+ m((ancestor2) => ctx.diagramNodes.get(ancestor2.id)),
14717
+ T(n$4),
14718
+ d()
14719
+ ) : void 0);
14720
+ return {
14721
+ fqn: element.id,
14722
+ existsInCurrentView: ctx.diagramNodes.has(element.id),
14723
+ element: {
14724
+ kind: element.kind,
14725
+ title: diagramNode?.title ?? element.title,
14726
+ description: diagramNode?.description ?? element.element.description,
14727
+ color: diagramNode?.color ?? ancestor?.color ?? element.color,
14728
+ shape: diagramNode?.shape ?? element.shape
14729
+ },
14730
+ navigateTo: diagramNode?.navigateTo ?? d(element.viewsOf())?.id ?? null,
14731
+ ports: {
14732
+ left: [],
14733
+ right: []
14734
+ }
14735
+ };
14736
+ }
14737
+ function createEmptyNode(column, ctx) {
14738
+ const id2 = `${column}::empty`, xynodes = ctx.columns[column];
14739
+ let node2 = xynodes.get(id2);
14740
+ if (node2)
14741
+ return invariant(node2.type === "empty", "Node is not empty"), node2;
14742
+ const xynode = {
14743
+ type: "empty",
14744
+ id: id2,
14745
+ position: { x: 0, y: 0 },
14746
+ data: {
14747
+ column
14748
+ },
14749
+ zIndex: ZIndexes.empty
14750
+ };
14751
+ xynodes.set(id2, xynode);
14752
+ const k = graphId(xynode);
14753
+ return ctx.g.setNode(k.id, {
14754
+ width: 230,
14755
+ height: 130
14756
+ }), ctx.g.setParent(k.id, graphColumn(column).id), xynode;
14757
+ }
14758
+ function createNode(column, nodeType, element, ctx) {
14759
+ const xynodes = ctx.columns[column];
14760
+ let node2 = xynodes.get(element.id);
14761
+ if (node2)
14762
+ return invariant(node2.type !== "empty", `Node ${element.id} is empty`), node2;
14763
+ const g = ctx.g, parent = x$1(
14764
+ element.ancestors(),
14765
+ u$7((ancestor) => !isAncestor(ancestor.id, ctx.subjectId)),
14766
+ f(
14767
+ (ancestor) => ctx.diagramNodes.has(ancestor.id) || ctx.connected[column].has(ancestor.id) || ctx.scope === "global" && ctx.subjectElement.ascendingSiblings().some((s2) => s2.id === ancestor.id)
14768
+ ),
14769
+ (found) => found ? createNode(column, "compound", found, ctx) : null
14770
+ ), xynode = {
14771
+ type: nodeType,
14772
+ id: `${column}::${element.id}`,
14773
+ position: { x: 0, y: 0 },
14774
+ data: {
14775
+ ...nodeData(element, ctx),
14776
+ column
14777
+ },
14778
+ zIndex: ZIndexes[nodeType],
14779
+ ...!!parent && { parentId: parent.id }
14780
+ };
14781
+ xynodes.set(element.id, xynode);
14782
+ const k = graphId(xynode);
14783
+ g.setNode(k.id, sized()), xynode.type === "compound" && (g.setNode(k.port, {
14784
+ width: Sizes.nodeWidth - Sizes.dagre.ranksep,
14785
+ height: Sizes.compoundLabelHeight
14786
+ }), g.setParent(k.port, k.id));
14787
+ const parentGraphId = parent ? graphId(parent).body : graphColumn(column).id;
14788
+ return g.setParent(k.id, parentGraphId), xynode;
14789
+ }
14790
+ function applyDagreLayout(g) {
14791
+ return dagre$1.layout(g), function nodeBounds(nodeId, relativeTo) {
14792
+ const { x: x2, y: y2, width: width2, height } = g.node(nodeId), pos = {
14793
+ position: {
14794
+ x: x2 - Math.round(width2 / 2),
14795
+ y: y2 - Math.round(height / 2)
14796
+ },
14797
+ width: width2,
14798
+ height
14799
+ };
14800
+ if (!relativeTo)
14801
+ return pos;
14802
+ const offset = nodeBounds(relativeTo).position;
14803
+ return {
14804
+ position: {
14805
+ x: pos.position.x - offset.x,
14806
+ y: pos.position.y - offset.y
14807
+ },
14808
+ width: pos.width,
14809
+ height: pos.height
14810
+ };
14811
+ };
14812
+ }
14813
+ function addEdge(ctx, props2) {
14814
+ const { source, target, relations } = props2, ids = relations.map((r2) => r2.id).join("_"), label2 = t$5(relations)?.title ?? "untitled", isMultiple = relations.length > 1, edge = {
14815
+ id: `rel${ctx.edges.length + 1}_${ids}`,
14816
+ type: "relation",
14817
+ source,
14818
+ target,
14819
+ sourceHandle: target,
14820
+ targetHandle: source,
14821
+ data: {
14822
+ relations
14823
+ },
14824
+ label: isMultiple ? `${relations.length} relationships` : label2,
14825
+ zIndex: ZIndexes.edge,
14826
+ markerEnd: {
14827
+ type: MarkerType.ArrowClosed,
14828
+ width: isMultiple ? 7 : 9
14829
+ },
14830
+ style: {
14831
+ strokeWidth: isMultiple ? 5 : 2.2,
14832
+ strokeDasharray: isMultiple ? void 0 : "5, 5"
14833
+ }
14834
+ };
14835
+ ctx.edges.push(edge);
14836
+ }
14837
+ function processRelations(props2) {
14838
+ x$1(
14839
+ props2.incoming,
14840
+ i$2((r2) => r2.source),
14841
+ t$2(),
14842
+ m$1((a2, b2) => compareFqnHierarchically(a2[0], b2[0])),
14843
+ t$7(),
14844
+ u$4(([sourceId, relations]) => {
14845
+ try {
14846
+ props2.forEachIncoming(sourceId, relations);
14847
+ } catch (e2) {
14848
+ console.error("Error in forEachIncoming", e2);
14849
+ }
14850
+ })
14851
+ ), x$1(
14852
+ props2.outgoing,
14853
+ i$2((r2) => r2.target),
14854
+ t$2(),
14855
+ m$1((a2, b2) => compareFqnHierarchically(a2[0], b2[0])),
14856
+ t$7(),
14857
+ u$4(([targetId, relations]) => {
14858
+ try {
14859
+ props2.forEachOutgoing(targetId, relations);
14860
+ } catch (e2) {
14861
+ console.error("Error in forEachOutgoing", e2);
14862
+ }
14863
+ })
14864
+ );
14865
+ }
14866
+ function layout(subjectId, view, likec4model, scope) {
14867
+ const diagramNodes = new Map(view.nodes.map((n2) => [n2.id, n2])), subjectElement = likec4model.element(subjectId);
14868
+ diagramNodes.has(subjectId) || (scope = "global");
14869
+ const g = createGraph(), ctx = {
14870
+ scope,
14871
+ g,
14872
+ diagramNodes,
14873
+ subjectId,
14874
+ subjectElement,
14875
+ connected: i$3(
14876
+ ["incomers", "outgoers"],
14877
+ (column) => new Set(subjectElement[column]().map((m2) => m2.id))
14878
+ ),
14879
+ columns: {
14880
+ incomers: /* @__PURE__ */ new Map(),
14881
+ outgoers: /* @__PURE__ */ new Map()
14882
+ },
14883
+ edges: []
14884
+ }, subject = {
14885
+ id: subjectElement.id,
14886
+ type: "element",
14887
+ position: { x: 0, y: 0 },
14888
+ data: {
14889
+ ...nodeData(subjectElement, ctx),
14890
+ column: "subject"
14891
+ },
14892
+ zIndex: 3,
14893
+ selectable: !1,
14894
+ focusable: !1,
14895
+ ...sized()
14896
+ };
14897
+ if (g.setNode(subject.id, sized()), g.setParent(subject.id, graphColumn("subject").id), processRelations({
14898
+ // Based on the scope we pick relationships
14899
+ ...scope === "global" ? {
14900
+ incoming: subjectElement.incoming().map((r2) => r2.relationship),
14901
+ outgoing: subjectElement.outgoing().map((r2) => r2.relationship)
14902
+ } : {
14903
+ incoming: likec4model.view(view.id).element(subjectId).incoming().flatMap((c) => c.relationships().map((r2) => r2.relationship)),
14904
+ outgoing: likec4model.view(view.id).element(subjectId).outgoing().flatMap((c) => c.relationships().map((r2) => r2.relationship))
14905
+ },
14906
+ forEachIncoming(sourceId, relations) {
14907
+ const source = createNode("incomers", "element", likec4model.element(sourceId), ctx);
14908
+ g.setEdge(graphId(source).port, subject.id), subject.data.ports.left.push({
14909
+ id: source.id,
14910
+ type: "in"
14911
+ }), source.data.ports.right.push({
14912
+ id: subject.id,
14913
+ type: "out"
14914
+ }), addEdge(ctx, {
14915
+ source: source.id,
14916
+ target: subject.id,
14917
+ relations
14918
+ });
14919
+ },
14920
+ forEachOutgoing(targetId, relations) {
14921
+ const target = createNode("outgoers", "element", likec4model.element(targetId), ctx);
14922
+ g.setEdge(subjectElement.id, graphId(target).port), subject.data.ports.right.push({
14923
+ id: target.id,
14924
+ type: "out"
14925
+ }), target.data.ports.left.push({
14926
+ id: subject.id,
14927
+ type: "in"
14928
+ }), addEdge(ctx, {
14929
+ source: subjectElement.id,
14930
+ target: target.id,
14931
+ relations
14932
+ });
14933
+ }
14934
+ }), ctx.columns.incomers.size == 0) {
14935
+ const source = createEmptyNode("incomers", ctx);
14936
+ g.setEdge(graphId(source).port, subject.id);
14937
+ }
14938
+ if (ctx.columns.outgoers.size == 0) {
14939
+ const target = createEmptyNode("outgoers", ctx);
14940
+ g.setEdge(subject.id, graphId(target).port);
14941
+ }
14942
+ const subjectPortsCount = Math.max(subject.data.ports.left.length, subject.data.ports.right.length);
14943
+ subjectPortsCount > 2 && (g.node(subjectElement.id).height = Sizes.hodeHeight + (subjectPortsCount - 2) * 1);
14944
+ const nodebounds = applyDagreLayout(ctx.g), xynodes = [
14945
+ subject,
14946
+ ...ctx.columns.incomers.values(),
14947
+ ...ctx.columns.outgoers.values()
14948
+ ].map((node2) => ({
14949
+ ...node2,
14950
+ ...nodebounds(node2.id, node2.parentId)
14951
+ })), sortedPorts = (ports) => ports.length < 2 ? ports : x$1(
14952
+ ports,
14953
+ m((port) => ({
14954
+ port,
14955
+ topY: nodebounds(port.id).position.y
14956
+ })),
14957
+ a$3(p$3("topY")),
14958
+ m(p$3("port"))
14959
+ );
14960
+ for (const node2 of xynodes) {
14961
+ if (node2.type === "empty") {
14962
+ const subjectPosition = nodebounds(subject.id);
14963
+ if (node2.position.y = subjectPosition.position.y + subjectPosition.height / 2 - node2.height / 2, node2.data.column === "incomers")
14964
+ node2.width = subjectPosition.position.x - Sizes.emptyNodeOffset - node2.position.x;
14965
+ else {
14966
+ const rightX = node2.position.x + node2.width;
14967
+ node2.position.x = subjectPosition.position.x + subjectPosition.width + Sizes.emptyNodeOffset, node2.width = rightX - node2.position.x;
14968
+ }
14969
+ continue;
14970
+ }
14971
+ node2.data.ports.left.length > 1 && (node2.data.ports.left = sortedPorts(node2.data.ports.left)), node2.data.ports.right.length > 1 && (node2.data.ports.right = sortedPorts(node2.data.ports.right));
14972
+ }
14973
+ return {
14974
+ view,
14975
+ viewIncludesSubject: diagramNodes.has(subjectId),
14976
+ subject: subjectElement,
14977
+ edges: ctx.edges,
14978
+ nodes: xynodes,
14979
+ bounds: {
14980
+ x: 0,
14981
+ y: 0,
14982
+ width: g.graph().width ?? 0,
14983
+ height: g.graph().height ?? 0
14984
+ }
14985
+ };
14986
+ }
14987
+ function useLayoutedRelationships(subjectId, scope) {
14988
+ const view = useDiagramState((s2) => s2.view), likec4model = useLikeC4Model(!0);
14989
+ return useMemo$1(() => layout(
14990
+ subjectId,
14991
+ view,
14992
+ likec4model,
14993
+ scope
14994
+ ), [
14995
+ subjectId,
14996
+ view,
14997
+ likec4model,
14998
+ layout,
14999
+ scope
15000
+ ]);
15001
+ }
15002
+ var elementNode = "_1ittjvh0", elementNodeContent = "_1ittjvh1", elementNodeTitle = "_1ittjvh2", elementNodeDescription = "_1ittjvh3", compoundNodeBody = "_1ittjvh4", compoundNodeTitle = "_1ittjvh5", cssShapeSvg = "_1ittjvh6", edgePath = "_1ittjvh7", edgeLabel$1 = "_1ittjvh8", edgeLabelText$1 = "_1ittjvh9", edgeLabelTechnology = "_1ittjvha", emptyNode = "_1ittjvhb", navigateBtnBox = "_1ittjvhc", navigateBtn$1 = "_1ittjvhd";
15003
+ const Text$3 = Text$6.withProps({
15004
+ component: "div"
15005
+ });
15006
+ function CompoundNode({
15007
+ data: {
15008
+ element,
15009
+ ports,
15010
+ ...data
15011
+ },
15012
+ width: width2 = 200,
15013
+ selectable = !0
15014
+ }) {
15015
+ return /* @__PURE__ */ jsxs(Fragment$1, { children: [
15016
+ /* @__PURE__ */ jsx(
15017
+ m$3.div,
15018
+ {
15019
+ className: clsx([
15020
+ compoundNodeBody,
15021
+ "likec4-compound-node"
15022
+ ]),
15023
+ "data-compound-depth": 3,
15024
+ "data-likec4-color": element.color,
15025
+ animate: {
15026
+ opacity: data.dimmed ? 0.15 : 1,
15027
+ transition: {
15028
+ delay: data.dimmed === !0 ? 0.4 : 0
15029
+ }
15030
+ },
15031
+ ...selectable && {
15032
+ whileHover: {
15033
+ scale: 1.04,
15034
+ transition: {
15035
+ delay: 0.15
15036
+ }
15037
+ },
15038
+ whileTap: {
15039
+ scale: 1
14023
15040
  }
14024
- )
14025
- ] });
14026
- case "queue": {
14027
- const { path, rx, ry } = queueSVGPath(w, h);
14028
- return /* @__PURE__ */ jsxs(Fragment$1, { children: [
14029
- /* @__PURE__ */ jsx("path", { d: path, strokeWidth: 2 }),
14030
- /* @__PURE__ */ jsx("ellipse", { cx: rx, cy: ry, ry: ry - 0.75, rx, className: fillMixStroke, strokeWidth: 2 })
14031
- ] });
14032
- }
14033
- case "storage":
14034
- case "cylinder": {
14035
- const { path, rx, ry } = cylinderSVGPath(w, h);
14036
- return /* @__PURE__ */ jsxs(Fragment$1, { children: [
14037
- /* @__PURE__ */ jsx("path", { d: path, strokeWidth: 2 }),
14038
- /* @__PURE__ */ jsx("ellipse", { cx: rx, cy: ry, ry, rx: rx - 0.75, className: fillMixStroke, strokeWidth: 2 })
14039
- ] });
14040
- }
14041
- case "rectangle":
14042
- return /* @__PURE__ */ jsx(
14043
- "rect",
14044
- {
14045
- width: w,
14046
- height: h,
14047
- rx: 6,
14048
- strokeWidth: 0
15041
+ },
15042
+ children: /* @__PURE__ */ jsx(Text$3, { className: compoundNodeTitle, maw: width2 - 20, children: element.title })
15043
+ }
15044
+ ),
15045
+ ports.left.map(({ id: id2, type }, i2) => /* @__PURE__ */ jsx(
15046
+ Handle,
15047
+ {
15048
+ id: id2,
15049
+ type: type === "in" ? "target" : "source",
15050
+ position: Position.Left,
15051
+ style: {
15052
+ visibility: "hidden",
15053
+ top: `${16 + 20 * i2}px`
14049
15054
  }
14050
- );
14051
- default:
14052
- return nonexhaustive(shape);
14053
- }
14054
- }
14055
- function SelectedIndicator({ shape, w, h }) {
14056
- switch (shape) {
14057
- case "queue":
14058
- return /* @__PURE__ */ jsx("path", { d: queueSVGPath(w, h).path });
14059
- case "storage":
14060
- case "cylinder":
14061
- return /* @__PURE__ */ jsx("path", { d: cylinderSVGPath(w, h).path });
14062
- default:
14063
- return /* @__PURE__ */ jsx(
14064
- "rect",
14065
- {
14066
- x: -1,
14067
- y: -1,
14068
- width: w + 2,
14069
- height: h + 2,
14070
- rx: 6
15055
+ },
15056
+ id2
15057
+ )),
15058
+ ports.right.map(({ id: id2, type }, i2) => /* @__PURE__ */ jsx(
15059
+ Handle,
15060
+ {
15061
+ id: id2,
15062
+ type: type === "in" ? "target" : "source",
15063
+ position: Position.Right,
15064
+ style: {
15065
+ visibility: "hidden",
15066
+ top: `${16 + 20 * i2}px`
14071
15067
  }
14072
- );
14073
- }
15068
+ },
15069
+ id2
15070
+ ))
15071
+ ] });
14074
15072
  }
14075
- const Text$2 = Text$4.withProps({
15073
+ const Action$1 = ActionIcon$1.withProps({
15074
+ className: "nodrag nopan " + navigateBtn$1,
15075
+ radius: "md",
15076
+ role: "button",
15077
+ onDoubleClick: stopPropagation$1,
15078
+ onPointerDownCapture: stopPropagation$1
15079
+ }), Text$2 = Text$6.withProps({
14076
15080
  component: "div"
14077
15081
  });
14078
15082
  function selector$5(s2) {
14079
15083
  return {
14080
- viewId: s2.view.id,
14081
- onNavigateTo: s2.onNavigateTo
15084
+ currentViewId: s2.view.id,
15085
+ onNavigateTo: s2.onNavigateTo,
15086
+ onOpenSource: s2.onOpenSourceElement
14082
15087
  };
14083
15088
  }
14084
15089
  function ElementNode({
@@ -14092,9 +15097,10 @@ function ElementNode({
14092
15097
  width: w = 100,
14093
15098
  height: h = 100
14094
15099
  }) {
14095
- const overlay2 = useOverlayDialog(), {
14096
- viewId,
14097
- onNavigateTo
15100
+ const overlay = useOverlayDialog(), {
15101
+ currentViewId,
15102
+ onNavigateTo,
15103
+ onOpenSource
14098
15104
  } = useDiagramState(selector$5);
14099
15105
  return /* @__PURE__ */ jsxs(Fragment$1, { children: [
14100
15106
  /* @__PURE__ */ jsxs(
@@ -14108,7 +15114,7 @@ function ElementNode({
14108
15114
  animate: {
14109
15115
  opacity: data.dimmed ? 0.15 : 1,
14110
15116
  transition: {
14111
- delay: data.dimmed ? 0.8 : 0
15117
+ delay: data.dimmed === !0 ? 0.4 : 0
14112
15118
  }
14113
15119
  },
14114
15120
  ...selectable && {
@@ -14127,39 +15133,49 @@ function ElementNode({
14127
15133
  "svg",
14128
15134
  {
14129
15135
  className: clsx(
14130
- cssShapeSvg$1
15136
+ cssShapeSvg
14131
15137
  ),
14132
15138
  viewBox: `0 0 ${w} ${h}`,
14133
15139
  width: w,
14134
15140
  height: h,
14135
- children: /* @__PURE__ */ jsx(
14136
- ElementShapeSvg,
14137
- {
14138
- shape: element.shape,
14139
- w,
14140
- h
14141
- }
14142
- )
15141
+ children: /* @__PURE__ */ jsx(ElementShapeSvg, { shape: element.shape, w, h })
14143
15142
  }
14144
15143
  ),
14145
15144
  /* @__PURE__ */ jsxs(Box, { className: elementNodeContent, children: [
14146
15145
  /* @__PURE__ */ jsx(Text$2, { className: elementNodeTitle, lineClamp: 2, children: element.title }),
14147
15146
  element.description && /* @__PURE__ */ jsx(Text$2, { className: elementNodeDescription, lineClamp: 4, children: element.description })
14148
15147
  ] }),
14149
- navigateTo && onNavigateTo && navigateTo !== viewId && /* @__PURE__ */ jsx(Box, { className: navigateBtnBox, children: /* @__PURE__ */ jsx(
14150
- ActionIcon$1,
14151
- {
14152
- className: clsx("nodrag nopan", navigateBtn$2),
14153
- radius: "md",
14154
- onClick: (event) => {
14155
- event.stopPropagation(), setTimeout(() => onNavigateTo(navigateTo), 200), overlay2.close();
14156
- },
14157
- role: "button",
14158
- onDoubleClick: stopPropagation$1,
14159
- onPointerDownCapture: stopPropagation$1,
14160
- children: /* @__PURE__ */ jsx(IconZoomScan, { stroke: 1.8, style: { width: "75%" } })
14161
- }
14162
- ) })
15148
+ /* @__PURE__ */ jsxs(Group, { className: navigateBtnBox, children: [
15149
+ navigateTo && onNavigateTo && navigateTo !== currentViewId && /* @__PURE__ */ jsx(
15150
+ Action$1,
15151
+ {
15152
+ onClick: (event) => {
15153
+ event.stopPropagation(), setTimeout(() => onNavigateTo(navigateTo), 100), overlay.close();
15154
+ },
15155
+ children: /* @__PURE__ */ jsx(IconZoomScan, { stroke: 1.8, style: { width: "75%" } })
15156
+ }
15157
+ ),
15158
+ data.column !== "subject" && /* @__PURE__ */ jsx(
15159
+ Action$1,
15160
+ {
15161
+ onClick: (event) => {
15162
+ event.stopPropagation(), overlay.openOverlay({
15163
+ relationshipsOf: data.fqn
15164
+ });
15165
+ },
15166
+ children: /* @__PURE__ */ jsx(IconTransform, { stroke: 1.8, style: { width: "72%" } })
15167
+ }
15168
+ ),
15169
+ onOpenSource && /* @__PURE__ */ jsx(
15170
+ Action$1,
15171
+ {
15172
+ onClick: (event) => {
15173
+ event.stopPropagation(), onOpenSource(data.fqn);
15174
+ },
15175
+ children: /* @__PURE__ */ jsx(IconFileSymlink, { stroke: 1.8, style: { width: "72%" } })
15176
+ }
15177
+ )
15178
+ ] })
14163
15179
  ]
14164
15180
  }
14165
15181
  ),
@@ -14191,7 +15207,7 @@ function ElementNode({
14191
15207
  ))
14192
15208
  ] });
14193
15209
  }
14194
- const Text$1 = Text$4.withProps({
15210
+ const Text$1 = Text$6.withProps({
14195
15211
  component: "div"
14196
15212
  });
14197
15213
  function EmptyNode({
@@ -14209,7 +15225,7 @@ function RelationshipEdge$1({
14209
15225
  label: label2,
14210
15226
  ...props2
14211
15227
  }) {
14212
- const [edgePath$1, labelX, labelY] = getBezierPath(props2), isMultiRelation = data.relations.length > 1;
15228
+ const onNavigateTo = useDiagramState((s2) => s2.onNavigateTo), [edgePath$12, labelX, labelY] = getBezierPath(props2), navigateTo = onNavigateTo ? t$5(data.relations)?.navigateTo : void 0, isMultiRelation = data.relations.length > 1, technology2 = t$5(data.relations)?.technology;
14213
15229
  return /* @__PURE__ */ jsxs(Fragment$1, { children: [
14214
15230
  /* @__PURE__ */ jsx(
14215
15231
  "g",
@@ -14220,15 +15236,16 @@ function RelationshipEdge$1({
14220
15236
  children: /* @__PURE__ */ jsx(
14221
15237
  BaseEdge,
14222
15238
  {
14223
- path: edgePath$1,
15239
+ path: edgePath$12,
14224
15240
  ...props2
14225
15241
  }
14226
15242
  )
14227
15243
  }
14228
15244
  ),
14229
- label2 && /* @__PURE__ */ jsx(EdgeLabelRenderer, { children: /* @__PURE__ */ jsx(
14230
- "div",
15245
+ /* @__PURE__ */ jsx(EdgeLabelRenderer, { children: /* @__PURE__ */ jsxs(
15246
+ Stack$1,
14231
15247
  {
15248
+ gap: 2,
14232
15249
  style: {
14233
15250
  position: "absolute",
14234
15251
  transform: `translate(-50%, -50%) translate(${labelX}px,${labelY}px)`,
@@ -14241,10 +15258,41 @@ function RelationshipEdge$1({
14241
15258
  ]),
14242
15259
  "data-edge-dimmed": data.dimmed,
14243
15260
  "data-edge-hovered": data.hovered,
14244
- children: /* @__PURE__ */ jsxs(Group, { gap: 6, wrap: "nowrap", children: [
14245
- isMultiRelation && /* @__PURE__ */ jsx(ThemeIcon, { size: "sm", variant: "transparent", color: "orange", children: /* @__PURE__ */ jsx(IconBoxMultipleFilled, { style: { width: "80%" } }) }),
14246
- /* @__PURE__ */ jsx(Text$4, { fw: isMultiRelation ? "500" : "400", component: "div", className: edgeLabelText$1, lineClamp: 3, children: label2 })
14247
- ] })
15261
+ children: [
15262
+ label2 && /* @__PURE__ */ jsxs(Group, { gap: 6, wrap: "nowrap", children: [
15263
+ isMultiRelation && /* @__PURE__ */ jsx(ThemeIcon, { size: "sm", variant: "transparent", color: "orange", children: /* @__PURE__ */ jsx(IconBoxMultipleFilled, { style: { width: "80%" } }) }),
15264
+ /* @__PURE__ */ jsx(
15265
+ Text$6,
15266
+ {
15267
+ fw: isMultiRelation ? "500" : "400",
15268
+ component: "div",
15269
+ className: edgeLabelText$1,
15270
+ lineClamp: 3,
15271
+ children: label2
15272
+ }
15273
+ )
15274
+ ] }),
15275
+ technology2 && /* @__PURE__ */ jsxs(Text$6, { component: "div", className: edgeLabelTechnology, children: [
15276
+ "[ ",
15277
+ technology2,
15278
+ " ]"
15279
+ ] }),
15280
+ navigateTo && /* @__PURE__ */ jsx(Box, { ta: "center", mt: 4, children: /* @__PURE__ */ jsx(
15281
+ ActionIcon$1,
15282
+ {
15283
+ variant: "default",
15284
+ size: "sm",
15285
+ radius: "sm",
15286
+ onPointerDownCapture: stopPropagation$1,
15287
+ onClick: (event) => {
15288
+ event.stopPropagation(), onNavigateTo?.(navigateTo, event);
15289
+ },
15290
+ role: "button",
15291
+ onDoubleClick: stopPropagation$1,
15292
+ children: /* @__PURE__ */ jsx(IconZoomScan, {})
15293
+ }
15294
+ ) })
15295
+ ]
14248
15296
  }
14249
15297
  ) })
14250
15298
  ] });
@@ -14255,7 +15303,7 @@ const nodeTypes$1 = {
14255
15303
  empty: EmptyNode
14256
15304
  }, edgeTypes$1 = {
14257
15305
  relation: RelationshipEdge$1
14258
- }, resetDimmedAndHovered = (xyflow) => {
15306
+ }, findSubjectNode = (nodes) => nodes.find((n2) => n2.type === "element" && n2.data.column === "subject"), resetDimmedAndHovered = (xyflow) => {
14259
15307
  xyflow.setEdges(
14260
15308
  (edges) => edges.map((edge) => ({
14261
15309
  ...edge,
@@ -14284,7 +15332,7 @@ const nodeTypes$1 = {
14284
15332
  ...edge,
14285
15333
  animated: animated && isConnected
14286
15334
  };
14287
- }), onlyOneUnique = (data, property) => t$5(i$7(m(data.relations, p$2(property)))), RelationshipsXYFlow = memo$1(function() {
15335
+ }), onlyOneUnique = (data, property) => t$5(i$8(m(data.relations, p$3(property)))), RelationshipsXYFlow = memo$1(function({ subjectId }) {
14288
15336
  const diagramStore = useDiagramStoreApi(), lastClickedNodeRef = useRef$1(null), [_scope, setScope] = useLocalStorage({
14289
15337
  key: "likec4:scope-relationships-of",
14290
15338
  getInitialValueInEffect: !1,
@@ -14294,58 +15342,86 @@ const nodeTypes$1 = {
14294
15342
  viewIncludesSubject,
14295
15343
  edges,
14296
15344
  nodes,
14297
- subject
14298
- } = useLayoutedRelationships(_scope), scope = viewIncludesSubject ? _scope : "global", showSubjectWarning = !viewIncludesSubject && _scope === "view", [historySubjectId, historyOps, { history, current }] = useStateHistory(subject.id), xyflow = useReactFlow(), xystore = useStoreApi(), overlay2 = useOverlayDialog();
15345
+ subject,
15346
+ bounds
15347
+ } = useLayoutedRelationships(subjectId, _scope), scope = viewIncludesSubject ? _scope : "global", showSubjectWarning = !viewIncludesSubject && _scope === "view", [historySubjectId, historyOps, { history, current }] = useStateHistory(subject.id), xyflow = useReactFlow(), xystore = useStoreApi(), overlay = useOverlayDialog();
14299
15348
  useEffect$1(() => {
14300
15349
  historySubjectId !== subject.id && historyOps.set(subject.id);
14301
15350
  }, [subject.id]), useEffect$1(() => {
14302
- historySubjectId !== subject.id && overlay2.openOverlay({
15351
+ historySubjectId !== subject.id && overlay.openOverlay({
14303
15352
  relationshipsOf: historySubjectId
14304
15353
  });
14305
- }, [historySubjectId]), useEffect$1(() => {
14306
- const nextSubjectNode = nodes.find(
14307
- (n2) => n2.type !== "empty" && n2.data.column === "subject"
14308
- );
14309
- nextSubjectNode ? nextSubjectNode.data.fqn !== subject.id && console.error(`Subject node mismatch, expected: ${subject.id} got: ${nextSubjectNode.data.fqn}`) : console.error("Subject node not found");
14310
- const existingNode = lastClickedNodeRef.current ?? xyflow.getNodes().find((n2) => n2.type !== "empty" && n2.data.column !== "subject" && n2.data.fqn === subject.id);
14311
- if (lastClickedNodeRef.current = null, nextSubjectNode && existingNode && existingNode.data.column !== "subject") {
14312
- const xynodeFrom = xyflow.getInternalNode(existingNode.id), fromPos = xyflow.flowToScreenPosition({
14313
- x: xynodeFrom.internals.positionAbsolute.x,
14314
- y: xynodeFrom.internals.positionAbsolute.y
14315
- }), toPos = xyflow.flowToScreenPosition({
14316
- x: nextSubjectNode.position.x,
14317
- y: nextSubjectNode.position.y
14318
- }), diff = {
14319
- x: fromPos.x - toPos.x,
14320
- y: fromPos.y - toPos.y
14321
- };
14322
- xystore.getState().panBy(diff), xystore.getState().setNodes(nodes), xystore.getState().setEdges(edges);
14323
- return;
14324
- }
14325
- xyflow.setNodes(nodes), xyflow.setEdges(edges);
14326
- }, [nodes, edges]);
14327
- const zoomable = !0;
14328
- return useDebouncedEffect(
15354
+ }, [historySubjectId]);
15355
+ const fitview = useDebouncedCallback(
14329
15356
  () => {
14330
15357
  xyflow.fitView({
14331
15358
  padding: 0.2,
14332
15359
  includeHiddenNodes: !0,
14333
15360
  maxZoom: 1,
14334
- duration: 450
15361
+ duration: 500
14335
15362
  });
14336
15363
  },
14337
- [subject.id, scope],
14338
- 200
14339
- ), /* @__PURE__ */ jsx(
15364
+ [xyflow],
15365
+ 150
15366
+ );
15367
+ return useEffect$1(() => {
15368
+ const {
15369
+ nodes: _nodes,
15370
+ edges: _edges,
15371
+ setNodes,
15372
+ setEdges,
15373
+ width: width2,
15374
+ height
15375
+ } = xystore.getState(), nextSubjectNode = findSubjectNode(nodes), currentSubjectNode = findSubjectNode(_nodes);
15376
+ if (nextSubjectNode?.data.fqn === currentSubjectNode?.data.fqn) {
15377
+ setNodes(nodes), setEdges(edges);
15378
+ return;
15379
+ }
15380
+ nextSubjectNode ? nextSubjectNode.data.fqn !== subject.id && console.error(`Subject node mismatch, expected: ${subject.id} got: ${nextSubjectNode.data.fqn}`) : console.error("Subject node not found");
15381
+ const nextzoom = getViewportForBounds(bounds, width2, height, 0.2, 1, 0.2).zoom, nextSubjectCenter = nextSubjectNode && {
15382
+ x: nextSubjectNode.position.x + (nextSubjectNode.width ?? 0) / 2,
15383
+ y: nextSubjectNode.position.y + (nextSubjectNode.height ?? 0) / 2
15384
+ }, existingNode = lastClickedNodeRef.current ?? xyflow.getNodes().find((n2) => n2.type !== "empty" && n2.data.column !== "subject" && n2.data.fqn === subject.id);
15385
+ if (lastClickedNodeRef.current = null, nextSubjectCenter && existingNode) {
15386
+ setNodes(_nodes.map((n2) => ({
15387
+ ...n2,
15388
+ data: {
15389
+ ...n2.data,
15390
+ dimmed: n2.id !== existingNode.id ? "immediate" : !1
15391
+ }
15392
+ }))), setEdges(_edges.map((e2) => ({
15393
+ ...e2,
15394
+ data: {
15395
+ ...e2.data,
15396
+ dimmed: !0
15397
+ }
15398
+ })));
15399
+ const existingInternalNode = xyflow.getInternalNode(existingNode.id), existingDimensions = getNodeDimensions(existingInternalNode), existingCenter = {
15400
+ x: existingInternalNode.internals.positionAbsolute.x + existingDimensions.width / 2,
15401
+ y: existingInternalNode.internals.positionAbsolute.y + existingDimensions.height / 2
15402
+ }, zoom = Math.min(
15403
+ xyflow.getViewport().zoom,
15404
+ nextzoom,
15405
+ nextSubjectNode.width / existingDimensions.width,
15406
+ nextSubjectNode.height / existingDimensions.height
15407
+ );
15408
+ let isCancelled = !1;
15409
+ return xyflow.setCenter(existingCenter.x, existingCenter.y, { zoom, duration: 350 }).then(() => {
15410
+ isCancelled || (setNodes(nodes), setEdges(edges), xyflow.setCenter(nextSubjectCenter.x, nextSubjectCenter.y, { zoom: nextzoom }), fitview());
15411
+ }), () => {
15412
+ isCancelled = !0;
15413
+ };
15414
+ }
15415
+ setNodes(nodes), setEdges(edges), fitview();
15416
+ }, [nodes, edges]), /* @__PURE__ */ jsx(
14340
15417
  index,
14341
15418
  {
14342
- className: root,
14343
15419
  defaultEdges: [],
14344
15420
  defaultNodes: [],
14345
15421
  nodeTypes: nodeTypes$1,
14346
15422
  edgeTypes: edgeTypes$1,
14347
15423
  defaultMarkerColor: "var(--xy-edge-stroke)",
14348
- zoomOnPinch: zoomable,
15424
+ zoomOnPinch: !0,
14349
15425
  zoomOnScroll: !1,
14350
15426
  zoomOnDoubleClick: !1,
14351
15427
  maxZoom: 1.5,
@@ -14398,25 +15474,25 @@ const nodeTypes$1 = {
14398
15474
  resetDimmedAndHovered(xyflow);
14399
15475
  },
14400
15476
  onNodeClick: (e2, node2) => {
14401
- e2.stopPropagation(), node2.type !== "empty" && (subject.id !== node2.data.fqn && (lastClickedNodeRef.current = node2), overlay2.openOverlay({
15477
+ e2.stopPropagation(), node2.type !== "empty" && (lastClickedNodeRef.current = node2, overlay.openOverlay({
14402
15478
  relationshipsOf: node2.data.fqn
14403
15479
  }));
14404
15480
  },
15481
+ onNodeDoubleClick: (e2) => {
15482
+ e2.stopPropagation();
15483
+ },
14405
15484
  onDoubleClick: (e2) => {
14406
- e2.stopPropagation(), xyflow.fitView({
14407
- includeHiddenNodes: !0,
14408
- maxZoom: 1,
14409
- duration: 450
14410
- });
15485
+ e2.stopPropagation(), fitview();
14411
15486
  },
14412
15487
  onEdgeClick: (e2, edge) => {
14413
- if (e2.stopPropagation(), edge.data.relations.length <= 1) {
14414
- const relationId = t$5(edge.data.relations)?.id;
14415
- relationId && diagramStore.getState().onOpenSourceRelation?.(relationId);
15488
+ e2.stopPropagation();
15489
+ const relationId = t$5(edge.data.relations)?.id;
15490
+ if (relationId) {
15491
+ diagramStore.getState().onOpenSourceRelation?.(relationId);
14416
15492
  return;
14417
15493
  }
14418
15494
  const nodeId = onlyOneUnique(edge.data, "source") ? edge.source : edge.target, next = xyflow.getNode(nodeId);
14419
- next && next.type !== "empty" && (lastClickedNodeRef.current = next, overlay2.openOverlay({
15495
+ next && next.type !== "empty" && (lastClickedNodeRef.current = next, overlay.openOverlay({
14420
15496
  relationshipsOf: next.data.fqn
14421
15497
  }));
14422
15498
  },
@@ -14448,13 +15524,13 @@ const nodeTypes$1 = {
14448
15524
  ),
14449
15525
  /* @__PURE__ */ jsx(Space, { w: 2 }),
14450
15526
  /* @__PURE__ */ jsxs(Group, { gap: "xs", pos: "relative", wrap: "nowrap", flex: "1 0 auto", children: [
14451
- /* @__PURE__ */ jsx(Box, { fz: "sm", fw: "400", style: { whiteSpace: "nowrap" }, children: "Relationships of" }),
15527
+ /* @__PURE__ */ jsx(Box, { fz: "sm", fw: "400", style: { whiteSpace: "nowrap", userSelect: "none" }, children: "Relationships of" }),
14452
15528
  /* @__PURE__ */ jsx(Box, { flex: "1 0 auto", children: /* @__PURE__ */ jsx(
14453
15529
  SelectElement,
14454
15530
  {
14455
15531
  scope,
14456
15532
  subject: subject.element,
14457
- onSelect: (fqn) => overlay2.openOverlay({
15533
+ onSelect: (fqn) => overlay.openOverlay({
14458
15534
  relationshipsOf: fqn
14459
15535
  }),
14460
15536
  viewId: view.id
@@ -14489,7 +15565,7 @@ const nodeTypes$1 = {
14489
15565
  onClick: (e2) => {
14490
15566
  e2.stopPropagation(), setScope("global");
14491
15567
  },
14492
- children: /* @__PURE__ */ jsx(Text$4, { fw: 500, size: "xs", c: "orange", component: "div", children: "Current view doesn't include selected element, switched to Global" })
15568
+ children: /* @__PURE__ */ jsx(Text$6, { fw: 500, size: "xs", c: "orange", component: "div", children: "Current view doesn't include this element, switched to Global" })
14493
15569
  }
14494
15570
  )
14495
15571
  ] }),
@@ -14521,38 +15597,78 @@ const nodeTypes$1 = {
14521
15597
  ] }) })
14522
15598
  }
14523
15599
  );
14524
- }), RelationshipsOfOverlay = memo$1(() => {
14525
- const diagramApi = useDiagramStoreApi();
14526
- return /* @__PURE__ */ jsx(
14527
- OverlayDialog,
15600
+ }), Overlays = memo$1(() => {
15601
+ const diagramStore = useDiagramStoreApi(), activeOverlay = useDiagramState((s2) => s2.activeOverlay), ctxValue = useMemo$1(() => ({
15602
+ openOverlay: (overlay) => {
15603
+ diagramStore.getState().openOverlay(overlay);
15604
+ },
15605
+ close: () => {
15606
+ diagramStore.getState().closeOverlay();
15607
+ }
15608
+ }), [diagramStore]);
15609
+ return useHotkeys(
15610
+ !!activeOverlay ? [
15611
+ ["Escape", (e2) => {
15612
+ e2.stopImmediatePropagation(), diagramStore.getState().closeOverlay();
15613
+ }, { preventDefault: !0 }]
15614
+ ] : []
15615
+ ), /* @__PURE__ */ jsx(OverlayContext.Provider, { value: ctxValue, children: /* @__PURE__ */ jsx(AnimatePresence, { children: activeOverlay && /* @__PURE__ */ jsx(
15616
+ Box,
14528
15617
  {
14529
- className: overlay,
14530
- onClose: () => {
14531
- diagramApi.getState().closeOverlay();
14532
- },
15618
+ component: m$3.div,
15619
+ className: container$5,
14533
15620
  "data-likec4-color": "gray",
14534
- children: ({ opened }) => /* @__PURE__ */ jsxs(Fragment$1, { children: [
14535
- opened && /* @__PURE__ */ jsx(
15621
+ initial: {
15622
+ "--backdrop-blur": "0px",
15623
+ "--backdrop-opacity": "60%",
15624
+ opacity: 0,
15625
+ translateY: -15
15626
+ },
15627
+ animate: {
15628
+ "--backdrop-blur": "10px",
15629
+ "--backdrop-opacity": "25%",
15630
+ opacity: 1,
15631
+ translateY: 0
15632
+ },
15633
+ exit: {
15634
+ "--backdrop-blur": "1px",
15635
+ "--backdrop-opacity": "90%",
15636
+ translateY: -5,
15637
+ opacity: 0
15638
+ },
15639
+ children: /* @__PURE__ */ jsxs(FocusTrap, { children: [
15640
+ activeOverlay.relationshipsOf && /* @__PURE__ */ jsx(
14536
15641
  ReactFlowProvider,
14537
15642
  {
14538
15643
  defaultNodes: [],
14539
15644
  defaultEdges: [],
14540
- children: /* @__PURE__ */ jsx(RelationshipsXYFlow, {})
15645
+ children: /* @__PURE__ */ jsx(RelationshipsXYFlow, { subjectId: activeOverlay.relationshipsOf })
14541
15646
  }
14542
15647
  ),
14543
- /* @__PURE__ */ jsx(OverlayDialogCloseButton, {})
15648
+ activeOverlay.edgeDetails && /* @__PURE__ */ jsx(
15649
+ ReactFlowProvider,
15650
+ {
15651
+ defaultNodes: [],
15652
+ defaultEdges: [],
15653
+ children: /* @__PURE__ */ jsx(EdgeDetailsXYFlow, { edgeId: activeOverlay.edgeDetails })
15654
+ }
15655
+ ),
15656
+ /* @__PURE__ */ jsx(Box, { pos: "absolute", top: "1rem", right: "1rem", children: /* @__PURE__ */ jsx(
15657
+ ActionIcon$1,
15658
+ {
15659
+ variant: "default",
15660
+ size: "lg",
15661
+ "data-autofocus": !0,
15662
+ autoFocus: !0,
15663
+ onClick: (e2) => {
15664
+ e2.stopPropagation(), ctxValue.close();
15665
+ },
15666
+ children: /* @__PURE__ */ jsx(IconX, {})
15667
+ }
15668
+ ) })
14544
15669
  ] })
14545
15670
  }
14546
- );
14547
- }), Overlays = memo$1(() => {
14548
- const {
14549
- hasLikeC4Model,
14550
- activeOverlay
14551
- } = useDiagramState((s2) => ({
14552
- hasLikeC4Model: s2.hasLikeC4Model,
14553
- activeOverlay: s2.activeOverlay
14554
- }));
14555
- return activeOverlay ? hasLikeC4Model ? activeOverlay.relationshipsOf ? /* @__PURE__ */ jsx(RelationshipsOfOverlay, {}) : activeOverlay.edgeDetails ? /* @__PURE__ */ jsx(EdgeDetailsOverlay, { edgeId: activeOverlay.edgeDetails }) : null : (console.warn("LikeC4Model is not available, but overlays are active"), null) : null;
15671
+ ) }) });
14556
15672
  });
14557
15673
  function selectXYFlowSize(state) {
14558
15674
  return `${Math.round(state.width)}:${Math.round(state.height)}`;
@@ -15235,8 +16351,8 @@ function RelationshipsDropdownMenu({
15235
16351
  likec4model,
15236
16352
  children
15237
16353
  }) {
15238
- const portalProps = useMantinePortalProps(), [sourceXYNode, targetXYNode] = useXYNodesData([edge.source, edge.target]);
15239
- if (!sourceXYNode || !targetXYNode) return children;
16354
+ const openOverlay = useDiagramState((s2) => s2.openOverlay), portalProps = useMantinePortalProps(), [sourceXYNode, targetXYNode] = useXYNodesData([edge.source, edge.target]);
16355
+ invariant(sourceXYNode, `Source XYNode ${edge.source} not found for edge ${edge.id}`), invariant(targetXYNode, `Target XYNode ${edge.target} not found for edge ${edge.id}`);
15240
16356
  const [direct, nested] = x$1(
15241
16357
  edge.relations,
15242
16358
  m((id2) => {
@@ -15251,14 +16367,12 @@ function RelationshipsDropdownMenu({
15251
16367
  }),
15252
16368
  T(n$4),
15253
16369
  d$1((r2) => r2.relationship.source === edge.source && r2.relationship.target === edge.target)
15254
- );
15255
- if (direct.length + nested.length === 0)
15256
- return /* @__PURE__ */ jsx(Fragment$1, { children });
15257
- const renderRelationship = (relationship, index2) => /* @__PURE__ */ jsxs(Fragment, { children: [
16370
+ ), renderRelationship = (relationship, index2) => /* @__PURE__ */ jsxs(Fragment, { children: [
15258
16371
  index2 > 0 && /* @__PURE__ */ jsx(MenuDivider, { opacity: 0.65 }),
15259
16372
  /* @__PURE__ */ jsx(
15260
16373
  MenuItem,
15261
16374
  {
16375
+ onClick: onClickOpenOverlay,
15262
16376
  component: Relationship,
15263
16377
  relationship,
15264
16378
  sourceNode: sourceXYNode.data.element,
@@ -15266,8 +16380,12 @@ function RelationshipsDropdownMenu({
15266
16380
  edge
15267
16381
  }
15268
16382
  )
15269
- ] }, relationship.id);
15270
- return /* @__PURE__ */ jsxs(
16383
+ ] }, relationship.id), onClickOpenOverlay = useCallback$1((e2) => {
16384
+ e2.stopPropagation(), openOverlay({
16385
+ edgeDetails: edge.id
16386
+ });
16387
+ }, [edge.id, openOverlay]);
16388
+ return direct.length + nested.length === 0 ? /* @__PURE__ */ jsx(Fragment$1, { children }) : /* @__PURE__ */ jsxs(
15271
16389
  Menu,
15272
16390
  {
15273
16391
  trigger: "click-hover",
@@ -15289,7 +16407,6 @@ function RelationshipsDropdownMenu({
15289
16407
  onPointerDownCapture: stopPropagation,
15290
16408
  onPointerDown: stopPropagation,
15291
16409
  onClick: stopPropagation,
15292
- onDoubleClick: stopPropagation,
15293
16410
  children: [
15294
16411
  direct.length > 0 && /* @__PURE__ */ jsxs(Fragment$1, { children: [
15295
16412
  /* @__PURE__ */ jsx(MenuLabel, { children: "direct relationships" }),
@@ -15299,7 +16416,16 @@ function RelationshipsDropdownMenu({
15299
16416
  direct.length > 0 && /* @__PURE__ */ jsx(MenuDivider, {}),
15300
16417
  /* @__PURE__ */ jsx(MenuLabel, { children: "resolved from nested" }),
15301
16418
  nested.map(renderRelationship)
15302
- ] })
16419
+ ] }),
16420
+ /* @__PURE__ */ jsx(Box, { pos: "absolute", top: 5, right: 6, children: /* @__PURE__ */ jsx(
16421
+ ActionIcon$1,
16422
+ {
16423
+ size: 24,
16424
+ variant: "subtle",
16425
+ onClick: onClickOpenOverlay,
16426
+ children: /* @__PURE__ */ jsx(IconInfoCircle, { style: { width: "70%" } })
16427
+ }
16428
+ ) })
15303
16429
  ]
15304
16430
  }
15305
16431
  )
@@ -15326,9 +16452,9 @@ const Relationship = forwardRef$1(({
15326
16452
  })), sourceId = nameFromFqn(edge.source) + r2.source.id.slice(edge.source.length), targetId = nameFromFqn(edge.target) + r2.target.id.slice(edge.target.length), navigateTo = hasOnNavigateTo && r2.relationship.navigateTo !== viewId ? r2.relationship.navigateTo : void 0;
15327
16453
  return /* @__PURE__ */ jsxs(Stack$1, { ref, className: clsx(menuItemRelationship, className), ...props2, children: [
15328
16454
  /* @__PURE__ */ jsxs(Group, { gap: 4, children: [
15329
- /* @__PURE__ */ jsx(Text$4, { component: "div", className: endpoint, "data-likec4-color": sourceNode.color, children: sourceId }),
16455
+ /* @__PURE__ */ jsx(Text$6, { component: "div", className: endpoint, "data-likec4-color": sourceNode.color, children: sourceId }),
15330
16456
  /* @__PURE__ */ jsx(IconArrowRight, { stroke: 2.5, size: 11 }),
15331
- /* @__PURE__ */ jsx(Text$4, { component: "div", className: endpoint, "data-likec4-color": targetNode.color, children: targetId }),
16457
+ /* @__PURE__ */ jsx(Text$6, { component: "div", className: endpoint, "data-likec4-color": targetNode.color, children: targetId }),
15332
16458
  (navigateTo || hasOnOpenSourceRelation) && /* @__PURE__ */ jsxs(TooltipGroup, { openDelay: 100, children: [
15333
16459
  /* @__PURE__ */ jsx(Space, { w: "xs" }),
15334
16460
  navigateTo && /* @__PURE__ */ jsx(Tooltip$2, { label: "Open dynamic view", children: /* @__PURE__ */ jsx(
@@ -15340,7 +16466,7 @@ const Relationship = forwardRef$1(({
15340
16466
  variant: "default",
15341
16467
  onPointerDownCapture: stopPropagation,
15342
16468
  onClick: (event) => {
15343
- diagramApi.getState().onNavigateTo?.(navigateTo, event);
16469
+ event.stopPropagation(), diagramApi.getState().onNavigateTo?.(navigateTo, event);
15344
16470
  },
15345
16471
  role: "button",
15346
16472
  children: /* @__PURE__ */ jsx(IconZoomScan, { size: "80%", stroke: 2 })
@@ -15432,7 +16558,7 @@ const Relationship = forwardRef$1(({
15432
16558
  onClick: stopPropagation$1,
15433
16559
  onDoubleClick: stopPropagation$1,
15434
16560
  children: [
15435
- /* @__PURE__ */ jsx(ScrollAreaAutosize, { maw: 450, mah: 350, type: "scroll", mx: "auto", mt: 2, children: /* @__PURE__ */ jsx(Text$4, { component: "div", className: edgeNoteText, p: 4, children: notes }) }),
16561
+ /* @__PURE__ */ jsx(ScrollAreaAutosize, { maw: 450, mah: 350, type: "scroll", mx: "auto", mt: 2, children: /* @__PURE__ */ jsx(Text$6, { component: "div", className: edgeNoteText, p: 4, children: notes }) }),
15436
16562
  /* @__PURE__ */ jsx(
15437
16563
  CloseButton,
15438
16564
  {
@@ -15523,7 +16649,6 @@ function bezierPath(bezierSpline) {
15523
16649
  const isSame = (a2, b2) => Math.abs(a2 - b2) < 2.5, isSamePoint = (a2, b2) => isSame(n$2(a2) ? a2[0] : a2.x, n$2(b2) ? b2[0] : b2.x) && isSame(n$2(a2) ? a2[1] : a2.y, n$2(b2) ? b2[1] : b2.y), sameControlPoints = (a2, b2) => a2 === b2 ? !0 : !a2 || !b2 || a2.length !== b2.length ? !1 : a2.every((ap, i2) => isSamePoint(ap, b2[i2])), isEqualProps$2 = (prev, next) => prev.id === next.id && deepEqual(prev.source, next.source) && deepEqual(prev.target, next.target) && deepEqual(prev.selected ?? !1, next.selected ?? !1) && isSame(prev.sourceX, next.sourceX) && isSame(prev.sourceY, next.sourceY) && isSame(prev.targetX, next.targetX) && isSame(prev.targetY, next.targetY) && deepEqual(prev.data.label, next.data.label) && sameControlPoints(prev.data.controlPoints, next.data.controlPoints) && deepEqual(prev.data.edge, next.data.edge), curve = d3line().curve(curveCatmullRomOpen).x((d2) => d2.x).y((d2) => d2.y), RelationshipEdge = memo$1(function({
15524
16650
  id: id2,
15525
16651
  data,
15526
- selected,
15527
16652
  sourceX,
15528
16653
  sourceY,
15529
16654
  targetX,
@@ -15697,9 +16822,9 @@ const isSame = (a2, b2) => Math.abs(a2 - b2) < 2.5, isSamePoint = (a2, b2) => is
15697
16822
  };
15698
16823
  let markerStartName = toMarker(diagramEdge.tail), markerEndName = toMarker(diagramEdge.head ?? "normal");
15699
16824
  diagramEdge.dir === "back" && ([markerStartName, markerEndName] = [markerEndName, markerStartName]);
15700
- const MarkerStart = markerStartName ? EdgeMarkers[markerStartName] : null, MarkerEnd = markerEndName ? EdgeMarkers[markerEndName] : null;
15701
- let labelZIndex = 1 + (isHovered ? ZIndexes$1.Element : edgeLookup.get(id2).zIndex ?? ZIndexes$1.Edge);
15702
- return isEdgePathEditable && selected && (labelZIndex = (edgeLookup.get(id2).zIndex ?? ZIndexes$1.Edge) - 1), /* @__PURE__ */ jsxs(
16825
+ const MarkerStart = markerStartName ? EdgeMarkers[markerStartName] : null, MarkerEnd = markerEndName ? EdgeMarkers[markerEndName] : null, edgeZIndex = edgeLookup.get(id2).zIndex ?? ZIndexes$2.Edge;
16826
+ let labelZIndex;
16827
+ return isEdgePathEditable ? labelZIndex = edgeZIndex - 1 : isHovered ? labelZIndex = ZIndexes$2.Element + 1 : labelZIndex = edgeZIndex + 1, /* @__PURE__ */ jsxs(
15703
16828
  "g",
15704
16829
  {
15705
16830
  className: clsx(
@@ -15881,7 +17006,7 @@ function Toolbar({ element, children, ...props2 }) {
15881
17006
  onDoubleClick: stopPropagation$1,
15882
17007
  withBorder: !0,
15883
17008
  children: /* @__PURE__ */ jsxs(Stack$1, { gap: 4, children: [
15884
- /* @__PURE__ */ jsx(Box, { pl: 2, children: /* @__PURE__ */ jsx(Text$4, { c: "dimmed", fz: 10, fw: 500, children: element.id }) }),
17009
+ /* @__PURE__ */ jsx(Box, { pl: 2, children: /* @__PURE__ */ jsx(Text$6, { c: "dimmed", fz: 10, fw: 500, children: element.id }) }),
15885
17010
  /* @__PURE__ */ jsx(Group, { gap: 3, children })
15886
17011
  ] })
15887
17012
  }
@@ -15983,7 +17108,7 @@ function GoToSourceButton({ elementId }) {
15983
17108
  onClick: (e2) => {
15984
17109
  e2.stopPropagation(), diagramApi.getState().onOpenSourceElement?.(elementId);
15985
17110
  },
15986
- children: /* @__PURE__ */ jsx(IconFileSymlink, { size: "70%", stroke: 1.8 })
17111
+ children: /* @__PURE__ */ jsx(IconFileSymlink, { stroke: 1.8, style: { width: "70%" } })
15987
17112
  }
15988
17113
  ) });
15989
17114
  }
@@ -16314,15 +17439,11 @@ const isEqualProps$1 = (prev, next) => prev.id === next.id && deepEqual(prev.sel
16314
17439
  selected = !1,
16315
17440
  dragging = !1,
16316
17441
  data: {
16317
- element: {
16318
- color: color2,
16319
- style,
16320
- depth = 1,
16321
- ...element
16322
- }
17442
+ isViewGroup,
17443
+ element
16323
17444
  }
16324
17445
  }) {
16325
- const opacity = u((style.opacity ?? 100) / 100, {
17446
+ const { depth, style, color: color2 } = element, isNotViewGroup = !isViewGroup, opacity = u((style.opacity ?? 100) / 100, {
16326
17447
  min: 0,
16327
17448
  max: 1
16328
17449
  }), borderTransparency = u(50 - opacity * 50, {
@@ -16346,7 +17467,7 @@ const isEqualProps$1 = (prev, next) => prev.id === next.id && deepEqual(prev.sel
16346
17467
  isInteractive: s2.nodesDraggable || s2.nodesSelectable || s2.enableRelationshipsBrowser || !!s2.onNavigateTo && !!element.navigateTo,
16347
17468
  hasOnNavigateTo: !!s2.onNavigateTo,
16348
17469
  enableRelationshipsMode: s2.enableRelationshipsBrowser
16349
- })), isNavigable = !!element.navigateTo && hasOnNavigateTo, _isToolbarVisible = isEditable && (isHovered || !1), [isToolbarVisible] = useDebouncedValue(_isToolbarVisible, _isToolbarVisible ? 500 : 300), [animateVariants, animateHandlers] = useFramerAnimateVariants();
17470
+ })), isNavigable = isNotViewGroup && !!element.navigateTo && hasOnNavigateTo, hasRelationshipsBrowser = isNotViewGroup && enableRelationshipsMode, _isToolbarVisible = isNotViewGroup && isEditable && (isHovered || !1), [isToolbarVisible] = useDebouncedValue(_isToolbarVisible, _isToolbarVisible ? 500 : 300), [animateVariants, animateHandlers] = useFramerAnimateVariants();
16350
17471
  let animate;
16351
17472
  switch (!0) {
16352
17473
  case (dragging && selected):
@@ -16433,12 +17554,12 @@ const isEqualProps$1 = (prev, next) => prev.id === next.id && deepEqual(prev.sel
16433
17554
  }
16434
17555
  },
16435
17556
  children: /* @__PURE__ */ jsx(
16436
- Text$4,
17557
+ Text$6,
16437
17558
  {
16438
17559
  component: "div",
16439
17560
  className: clsx(
16440
17561
  title$1,
16441
- (isNavigable || enableRelationshipsMode) && titleWithNavigation,
17562
+ (isNavigable || hasRelationshipsBrowser) && titleWithNavigation,
16442
17563
  "likec4-compound-title"
16443
17564
  ),
16444
17565
  children: element.title
@@ -16463,7 +17584,7 @@ const isEqualProps$1 = (prev, next) => prev.id === next.id && deepEqual(prev.sel
16463
17584
  },
16464
17585
  "navigate"
16465
17586
  ),
16466
- enableRelationshipsMode && /* @__PURE__ */ jsx(
17587
+ hasRelationshipsBrowser && /* @__PURE__ */ jsx(
16467
17588
  Tooltip$3,
16468
17589
  {
16469
17590
  fz: "xs",
@@ -16569,7 +17690,7 @@ function ElementLink({
16569
17690
  }
16570
17691
  );
16571
17692
  }
16572
- const Text = Text$4.withProps({
17693
+ const Text = Text$6.withProps({
16573
17694
  component: "div"
16574
17695
  }), selectedScale = 1.015, VariantsRoot = {
16575
17696
  idle: (_, { scale: scale2 }) => ({
@@ -16728,7 +17849,7 @@ const VariantsRelationsBtnSingle = {
16728
17849
  {
16729
17850
  id: id2,
16730
17851
  className: clsx([
16731
- container$5,
17852
+ container$6,
16732
17853
  isDimmed && dimmed$2,
16733
17854
  animate !== "idle" && containerAnimated,
16734
17855
  "likec4-element-node"
@@ -16747,7 +17868,7 @@ const VariantsRelationsBtnSingle = {
16747
17868
  onTapCancel: animateHandlers.onTapCancel
16748
17869
  },
16749
17870
  children: [
16750
- /* @__PURE__ */ jsxs("svg", { className: clsx(cssShapeSvg), viewBox: `0 0 ${w} ${h}`, width: w, height: h, children: [
17871
+ /* @__PURE__ */ jsxs("svg", { className: clsx(cssShapeSvg$1), viewBox: `0 0 ${w} ${h}`, width: w, height: h, children: [
16751
17872
  /* @__PURE__ */ jsx("g", { className: indicator$1, children: /* @__PURE__ */ jsx(SelectedIndicator, { shape: element.shape, w, h }) }),
16752
17873
  /* @__PURE__ */ jsx(ElementShapeSvg, { shape: element.shape, w, h })
16753
17874
  ] }),
@@ -16776,7 +17897,7 @@ const VariantsRelationsBtnSingle = {
16776
17897
  component: m$3.div,
16777
17898
  variants: VariantsNavigate,
16778
17899
  "data-animate-target": "navigate",
16779
- className: clsx("nodrag nopan", navigateBtn$1),
17900
+ className: clsx("nodrag nopan", navigateBtn$2),
16780
17901
  radius: "md",
16781
17902
  style: { zIndex: 100 },
16782
17903
  role: "button",
@@ -16792,7 +17913,7 @@ const VariantsRelationsBtnSingle = {
16792
17913
  component: m$3.div,
16793
17914
  variants: isNavigable ? VariantsRelationsBtn : VariantsRelationsBtnSingle,
16794
17915
  "data-animate-target": isNavigable ? "relations" : "navigate",
16795
- className: clsx("nodrag nopan", navigateBtn$1),
17916
+ className: clsx("nodrag nopan", navigateBtn$2),
16796
17917
  radius: "md",
16797
17918
  style: {
16798
17919
  left: isNavigable ? "calc(50% + 28px)" : "50%",
@@ -16945,7 +18066,16 @@ function useXYFlowEvents() {
16945
18066
  return;
16946
18067
  }
16947
18068
  }
16948
- n$4(focusedNodeId) ? (focusOnNode(connectedToFocusedNode && focusedNodeId === xyedge.source ? xyedge.target : xyedge.source), onEdgeClick || event.stopPropagation()) : nodesSelectable && (xystore.getState().addSelectedEdges([xyedge.id]), onEdgeClick || event.stopPropagation()), onEdgeClick?.(
18069
+ if (n$4(focusedNodeId)) {
18070
+ if (focusOnNode(connectedToFocusedNode && focusedNodeId === xyedge.source ? xyedge.target : xyedge.source), !onEdgeClick) {
18071
+ event.stopPropagation();
18072
+ return;
18073
+ }
18074
+ } else if (nodesSelectable && (xystore.getState().addSelectedEdges([xyedge.id]), !onEdgeClick)) {
18075
+ event.stopPropagation();
18076
+ return;
18077
+ }
18078
+ onEdgeClick?.(
16949
18079
  xyedge.data.edge,
16950
18080
  event
16951
18081
  );
@@ -16958,13 +18088,21 @@ function useXYFlowEvents() {
16958
18088
  enableDynamicViewWalkthrough,
16959
18089
  focusOnNode,
16960
18090
  activeWalkthrough,
16961
- activateWalkthrough
18091
+ activateWalkthrough,
18092
+ openOverlay,
18093
+ showRelationshipDetails
16962
18094
  } = diagramApi.getState();
16963
18095
  if (isDynamicView && enableDynamicViewWalkthrough) {
16964
18096
  const nextStep = xyedge.data.edge.id;
16965
18097
  activeWalkthrough?.stepId !== nextStep && (activateWalkthrough(nextStep), event.stopPropagation());
16966
18098
  return;
16967
18099
  }
18100
+ if (showRelationshipDetails) {
18101
+ openOverlay({
18102
+ edgeDetails: xyedge.data.edge.id
18103
+ }), event.stopPropagation();
18104
+ return;
18105
+ }
16968
18106
  if (enableFocusMode) {
16969
18107
  focusOnNode(xyedge.source), event.stopPropagation();
16970
18108
  return;
@@ -17070,7 +18208,7 @@ function XYFlow({
17070
18208
  zoomOnDoubleClick: !1,
17071
18209
  maxZoom: zoomable ? MaxZoom : 1,
17072
18210
  minZoom: zoomable ? MinZoom : 1,
17073
- fitView,
18211
+ fitView: !1,
17074
18212
  fitViewOptions: useMemo$1(() => ({
17075
18213
  minZoom: MinZoom,
17076
18214
  maxZoom: 1,
@@ -17201,7 +18339,7 @@ function DiagramTitlePanel() {
17201
18339
  ) }),
17202
18340
  /* @__PURE__ */ jsxs(Group, { justify: "stretch", wrap: "nowrap", mb: "sm", children: [
17203
18341
  /* @__PURE__ */ jsx(
17204
- Text$4,
18342
+ Text$6,
17205
18343
  {
17206
18344
  component: "div",
17207
18345
  flex: "1",
@@ -17213,7 +18351,7 @@ function DiagramTitlePanel() {
17213
18351
  }
17214
18352
  ),
17215
18353
  /* @__PURE__ */ jsxs(
17216
- Text$4,
18354
+ Text$6,
17217
18355
  {
17218
18356
  hidden: isCollapsed,
17219
18357
  component: "div",
@@ -17243,7 +18381,7 @@ function DiagramTitlePanel() {
17243
18381
  showLabel: /* @__PURE__ */ jsx(Button, { color: "gray", variant: "light", fz: "10", size: "compact-xs", tabIndex: -1, children: "show more" }),
17244
18382
  hideLabel: /* @__PURE__ */ jsx(Button, { color: "gray", variant: "light", fz: "10", size: "compact-xs", tabIndex: -1, children: "hide" }),
17245
18383
  children: /* @__PURE__ */ jsx(
17246
- Text$4,
18384
+ Text$6,
17247
18385
  {
17248
18386
  component: "div",
17249
18387
  size: "sm",
@@ -17254,7 +18392,7 @@ function DiagramTitlePanel() {
17254
18392
  }
17255
18393
  ),
17256
18394
  !description$12 && /* @__PURE__ */ jsx(
17257
- Text$4,
18395
+ Text$6,
17258
18396
  {
17259
18397
  component: "div",
17260
18398
  size: "xs",
@@ -17510,7 +18648,7 @@ const ElementNotation = ({ value }) => {
17510
18648
  kind
17511
18649
  )) }),
17512
18650
  /* @__PURE__ */ jsx(
17513
- Text$4,
18651
+ Text$6,
17514
18652
  {
17515
18653
  component: "div",
17516
18654
  fz: "sm",
@@ -17728,14 +18866,14 @@ const selector = (state) => ({
17728
18866
  className: autolayoutIndicator
17729
18867
  }
17730
18868
  ),
17731
- /* @__PURE__ */ jsx(Box, { mb: 10, children: /* @__PURE__ */ jsx(Text$4, { inline: !0, fz: "xs", c: "dimmed", fw: 500, children: "Auto layout:" }) }),
18869
+ /* @__PURE__ */ jsx(Box, { mb: 10, children: /* @__PURE__ */ jsx(Text$6, { inline: !0, fz: "xs", c: "dimmed", fw: 500, children: "Auto layout:" }) }),
17732
18870
  /* @__PURE__ */ jsxs(Flex, { gap: 2, wrap: "wrap", justify: "stretch", maw: 160, children: [
17733
18871
  /* @__PURE__ */ jsx(UnstyledButton, { className: autolayoutButton, ref: setControlRef("TB"), onClick: setAutoLayout("TB"), children: "Top-Bottom" }),
17734
18872
  /* @__PURE__ */ jsx(UnstyledButton, { className: autolayoutButton, ref: setControlRef("BT"), onClick: setAutoLayout("BT"), children: "Bottom-Top" }),
17735
18873
  /* @__PURE__ */ jsx(UnstyledButton, { className: autolayoutButton, ref: setControlRef("LR"), onClick: setAutoLayout("LR"), children: "Left-Right" }),
17736
18874
  /* @__PURE__ */ jsx(UnstyledButton, { className: autolayoutButton, ref: setControlRef("RL"), onClick: setAutoLayout("RL"), children: "Right-Left" })
17737
18875
  ] }),
17738
- /* @__PURE__ */ jsx(Box, { my: 10, children: /* @__PURE__ */ jsx(Text$4, { inline: !0, fz: "xs", c: "dimmed", fw: 500, children: "Spacing:" }) }),
18876
+ /* @__PURE__ */ jsx(Box, { my: 10, children: /* @__PURE__ */ jsx(Text$6, { inline: !0, fz: "xs", c: "dimmed", fw: 500, children: "Spacing:" }) }),
17739
18877
  /* @__PURE__ */ jsx(
17740
18878
  SpacingSliders,
17741
18879
  {
@@ -17786,7 +18924,7 @@ const selector = (state) => ({
17786
18924
  }
17787
18925
  }
17788
18926
  ),
17789
- /* @__PURE__ */ jsx(Box, { pos: "absolute", left: 2, bottom: 2, children: /* @__PURE__ */ jsxs(Text$4, { component: "div", fz: 8, c: "dimmed", fw: 500, children: [
18927
+ /* @__PURE__ */ jsx(Box, { pos: "absolute", left: 2, bottom: 2, children: /* @__PURE__ */ jsxs(Text$6, { component: "div", fz: 8, c: "dimmed", fw: 500, children: [
17790
18928
  rankSepValue,
17791
18929
  ", ",
17792
18930
  nodeSepValue
@@ -17985,12 +19123,12 @@ const selector = (state) => ({
17985
19123
  withCloseButton: !1,
17986
19124
  title: "Manual layout issues",
17987
19125
  children: [
17988
- /* @__PURE__ */ jsxs(Text$4, { mt: 2, size: "sm", lh: "xs", children: [
19126
+ /* @__PURE__ */ jsxs(Text$6, { mt: 2, size: "sm", lh: "xs", children: [
17989
19127
  "View contains new elements or their sizes have changed,",
17990
19128
  /* @__PURE__ */ jsx("br", {}),
17991
19129
  "last manual layout can not be applied."
17992
19130
  ] }),
17993
- /* @__PURE__ */ jsxs(Text$4, { mt: "xs", size: "sm", lh: "xs", children: [
19131
+ /* @__PURE__ */ jsxs(Text$6, { mt: "xs", size: "sm", lh: "xs", children: [
17994
19132
  "Update view predicates or remove ",
17995
19133
  /* @__PURE__ */ jsx(Code, { children: "@likec4-generated" })
17996
19134
  ] })
@@ -18151,9 +19289,10 @@ function LikeC4Diagram({
18151
19289
  initialWidth: initialWidth ?? view.bounds.width,
18152
19290
  initialHeight: initialHeight ?? view.bounds.height
18153
19291
  });
18154
- return readonly !== !0 && where && console.warn("where filter is only supported in readonly mode"), useEffect$1(() => {
18155
- hasLikec4model || (showRelationshipDetails && console.warn("Invalid showRelationshipDetails=true, requires LikeC4ModelProvider"), enableRelationshipsBrowser && console.warn("Invalid enableRelationshipsBrowser=true, requires LikeC4ModelProvider"));
18156
- }, []), /* @__PURE__ */ jsx(EnsureMantine, { children: /* @__PURE__ */ jsx(LazyMotion, { features: domMax, strict: !0, children: /* @__PURE__ */ jsxs(
19292
+ return useEffect$1(() => {
19293
+ readonly !== !0 && where != null && console.warn(`Ignore filter, supported in readonly mode only
19294
+ `, { where }), !hasLikec4model && (showRelationshipDetails && console.warn("Invalid showRelationshipDetails=true, requires LikeC4ModelProvider"), enableRelationshipsBrowser && console.warn("Invalid enableRelationshipsBrowser=true, requires LikeC4ModelProvider"));
19295
+ }), /* @__PURE__ */ jsx(EnsureMantine, { children: /* @__PURE__ */ jsx(LazyMotion, { features: domMax, strict: !0, children: /* @__PURE__ */ jsxs(
18157
19296
  ReactFlowProvider,
18158
19297
  {
18159
19298
  fitView,
@@ -18183,7 +19322,7 @@ function LikeC4Diagram({
18183
19322
  enableDynamicViewWalkthrough,
18184
19323
  enableFocusMode,
18185
19324
  enableRelationshipsBrowser: enableRelationshipsBrowser && hasLikec4model,
18186
- whereFilter: readonly !== !0 ? where ?? null : null,
19325
+ whereFilter: readonly ? where ?? null : null,
18187
19326
  renderIcon: renderIcon ?? null,
18188
19327
  onCanvasClick: onCanvasClick ?? null,
18189
19328
  onCanvasContextMenu: onCanvasContextMenu ?? null,
@@ -18227,7 +19366,7 @@ const LikeC4DiagramInnerMemo = /* @__PURE__ */ memo$1(function({
18227
19366
  pannable: s2.pannable,
18228
19367
  fitView: s2.fitViewEnabled,
18229
19368
  enableFocusMode: s2.enableFocusMode,
18230
- enableOverlays: s2.enableRelationshipsBrowser
19369
+ enableOverlays: s2.hasLikeC4Model && (s2.enableRelationshipsBrowser || s2.showRelationshipDetails)
18231
19370
  }));
18232
19371
  return /* @__PURE__ */ jsxs(Fragment$1, { children: [
18233
19372
  /* @__PURE__ */ jsx(
@@ -18238,7 +19377,8 @@ const LikeC4DiagramInnerMemo = /* @__PURE__ */ memo$1(function({
18238
19377
  cssReactFlow,
18239
19378
  cssNoControls,
18240
19379
  pannable !== !0 && cssDisablePan,
18241
- background === "transparent" && cssTransparentBg
19380
+ background === "transparent" && cssTransparentBg,
19381
+ isInitialized ? "initialized" : notInitialized
18242
19382
  ),
18243
19383
  children: /* @__PURE__ */ jsx(
18244
19384
  XYFlowInner,
@@ -18382,8 +19522,8 @@ const ViewCard = memo$1(({ viewId }) => {
18382
19522
  withBorder: !0,
18383
19523
  children: [
18384
19524
  /* @__PURE__ */ jsx(Card.Section, { children: /* @__PURE__ */ jsx(DiagramPreview$1, { diagram }) }),
18385
- /* @__PURE__ */ jsx(Group, { justify: "space-between", mt: "md", mb: "xs", children: /* @__PURE__ */ jsx(Text$4, { fw: 500, children: title2 }) }),
18386
- /* @__PURE__ */ jsx(Text$4, { size: "sm", c: "dimmed", children: description2 }),
19525
+ /* @__PURE__ */ jsx(Group, { justify: "space-between", mt: "md", mb: "xs", children: /* @__PURE__ */ jsx(Text$6, { fw: 500, children: title2 }) }),
19526
+ /* @__PURE__ */ jsx(Text$6, { size: "sm", c: "dimmed", children: description2 }),
18387
19527
  /* @__PURE__ */ jsx(Link, { to: "/view/$viewId", params: { viewId: id2 }, search: !0, className: cardLink })
18388
19528
  ]
18389
19529
  }
@@ -18405,7 +19545,7 @@ function DiagramPreview$1({ diagram }) {
18405
19545
  }
18406
19546
  ) });
18407
19547
  }
18408
- const OverviewGraph = /* @__PURE__ */ lazy(() => import("./-index-overview-DrWsHFH4.js"));
19548
+ const OverviewGraph = /* @__PURE__ */ lazy(() => import("./-index-overview-BwT9t8VB.js"));
18409
19549
  function WithOverviewGraph() {
18410
19550
  return /* @__PURE__ */ jsx(Suspense, { children: /* @__PURE__ */ jsx(OverviewGraph, {}) });
18411
19551
  }
@@ -18529,7 +19669,7 @@ class ErrorBoundary extends Component {
18529
19669
  childToRender = fallbackRender(props2);
18530
19670
  else if (FallbackComponent)
18531
19671
  childToRender = createElement$1(FallbackComponent, props2);
18532
- else if (fallback === null || isValidElement(fallback))
19672
+ else if (fallback !== void 0)
18533
19673
  childToRender = fallback;
18534
19674
  else
18535
19675
  throw error;
@@ -18908,7 +20048,7 @@ const AlertLocalhost = () => /* @__PURE__ */ jsx(
18908
20048
  icon: /* @__PURE__ */ jsx(IconAlertTriangle, {}),
18909
20049
  title: "Localhost URL",
18910
20050
  styles: { body: { gap: rem(4) } },
18911
- children: /* @__PURE__ */ jsx(Text$4, { c: "yellow", size: "sm", children: "You need to deploy your project to make it available on the internet" })
20051
+ children: /* @__PURE__ */ jsx(Text$6, { c: "yellow", size: "sm", children: "You need to deploy your project to make it available on the internet" })
18912
20052
  }
18913
20053
  ), CopyButtonChild = ({ copied, copy }) => /* @__PURE__ */ jsx(
18914
20054
  Button,
@@ -18938,10 +20078,10 @@ const AlertLocalhost = () => /* @__PURE__ */ jsx(
18938
20078
  `.trim();
18939
20079
  return /* @__PURE__ */ jsxs(Stack$1, { children: [
18940
20080
  code.includes("http://localhost") && /* @__PURE__ */ jsx(AlertLocalhost, {}),
18941
- /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$4, { size: "sm", children: "Embedded view is an iframe with a static diagram" }) }),
20081
+ /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$6, { size: "sm", children: "Embedded view is an iframe with a static diagram" }) }),
18942
20082
  /* @__PURE__ */ jsxs(Stack$1, { gap: "xs", children: [
18943
20083
  /* @__PURE__ */ jsxs(Group, { justify: "space-between", children: [
18944
- /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$4, { fw: "500", size: "sm", children: "HTML" }) }),
20084
+ /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$6, { fw: "500", size: "sm", children: "HTML" }) }),
18945
20085
  /* @__PURE__ */ jsxs(Group, { gap: "xs", children: [
18946
20086
  /* @__PURE__ */ jsx(ActionIcon$1, { component: "a", href, target: "_blank", variant: "light", color: "gray", children: /* @__PURE__ */ jsx(IconExternalLink, {}) }),
18947
20087
  /* @__PURE__ */ jsx(CopyButton$1, { value: code, timeout: 1500, children: CopyButtonChild })
@@ -18992,10 +20132,10 @@ function WebcomponentsPanel({ diagram }) {
18992
20132
  );
18993
20133
  return /* @__PURE__ */ jsxs(Stack$1, { children: [
18994
20134
  jscode.includes("http://localhost") && /* @__PURE__ */ jsx(AlertLocalhost, {}),
18995
- /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$4, { size: "sm", children: "Add this script to your page:" }) }),
20135
+ /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$6, { size: "sm", children: "Add this script to your page:" }) }),
18996
20136
  /* @__PURE__ */ jsxs(Stack$1, { gap: "xs", children: [
18997
20137
  /* @__PURE__ */ jsxs(Group, { justify: "space-between", children: [
18998
- /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$4, { fw: "500", size: "sm", children: "JavaScript" }) }),
20138
+ /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$6, { fw: "500", size: "sm", children: "JavaScript" }) }),
18999
20139
  /* @__PURE__ */ jsxs(Group, { gap: "xs", children: [
19000
20140
  /* @__PURE__ */ jsx(ActionIcon$1, { component: "a", href: webcomponentPreview.href, target: "_blank", variant: "light", color: "gray", children: /* @__PURE__ */ jsx(IconExternalLink, {}) }),
19001
20141
  /* @__PURE__ */ jsx(
@@ -19009,7 +20149,7 @@ function WebcomponentsPanel({ diagram }) {
19009
20149
  ] })
19010
20150
  ] }),
19011
20151
  /* @__PURE__ */ jsx(Code, { block: !0, children: jscode }),
19012
- /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsxs(Text$4, { size: "sm", c: "dimmed", children: [
20152
+ /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsxs(Text$6, { size: "sm", c: "dimmed", children: [
19013
20153
  "This script defines a custom element (webcomponent) that renders your diagrams.",
19014
20154
  /* @__PURE__ */ jsx("br", {}),
19015
20155
  "Script must be inserted once in the ",
@@ -19022,7 +20162,7 @@ function WebcomponentsPanel({ diagram }) {
19022
20162
  ] }),
19023
20163
  /* @__PURE__ */ jsxs(Stack$1, { gap: "xs", children: [
19024
20164
  /* @__PURE__ */ jsxs(Group, { justify: "space-between", children: [
19025
- /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$4, { fw: "500", size: "sm", children: "HTML" }) }),
20165
+ /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(Text$6, { fw: "500", size: "sm", children: "HTML" }) }),
19026
20166
  /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(
19027
20167
  CopyButton$1,
19028
20168
  {
@@ -19033,7 +20173,7 @@ function WebcomponentsPanel({ diagram }) {
19033
20173
  ) })
19034
20174
  ] }),
19035
20175
  /* @__PURE__ */ jsx(Code, { block: !0, children: htmlCode }),
19036
- /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsxs(Text$4, { size: "sm", c: "dimmed", children: [
20176
+ /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsxs(Text$6, { size: "sm", c: "dimmed", children: [
19037
20177
  "Insert this code to your page. Page may have multiple ",
19038
20178
  /* @__PURE__ */ jsx("code", { children: "<likec4-view>" }),
19039
20179
  "."
@@ -19175,7 +20315,7 @@ function Fallback({ error, resetErrorBoundary }) {
19175
20315
  return useUpdateEffect(() => {
19176
20316
  resetErrorBoundary();
19177
20317
  }, [viewId]), isNotFound(error) ? /* @__PURE__ */ jsx(Container, { my: "md", children: /* @__PURE__ */ jsxs(Alert, { variant: "light", color: "orange", children: [
19178
- /* @__PURE__ */ jsxs(Text$4, { c: "orange", fz: "md", children: [
20318
+ /* @__PURE__ */ jsxs(Text$6, { c: "orange", fz: "md", children: [
19179
20319
  "The diagram",
19180
20320
  " ",
19181
20321
  /* @__PURE__ */ jsx(Code, { color: "orange", children: viewId }),
@@ -21234,5 +22374,5 @@ export {
21234
22374
  createReactComponent as c,
21235
22375
  e$3 as e,
21236
22376
  nonexhaustive as n,
21237
- u$7 as u
22377
+ u$8 as u
21238
22378
  };