zen-temple 0.7.2.dev1__tar.gz → 0.7.3.dev1__tar.gz

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 (133) hide show
  1. zen_temple-0.7.3.dev1/PKG-INFO +126 -0
  2. zen_temple-0.7.3.dev1/README.md +103 -0
  3. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/pyproject.toml +1 -1
  4. zen_temple-0.7.3.dev1/zen_temple/errors.py +2 -0
  5. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/assets/6.DpRBXrkG.css +1 -0
  6. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/assets/_page.DpRBXrkG.css +1 -0
  7. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/Hpa8B7Rc.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/-3L7ibXM.js +1 -1
  8. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/Bd0-aO2Q.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/5DMf3Tuo.js +1 -1
  9. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/B8ie1dNX.js +1 -0
  10. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/BIMe2fNB.js +1 -0
  11. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/BvtU7qVU.js +1 -0
  12. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/BxLhXNcl.js +1 -0
  13. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/C0T7Jkdw.js +22 -0
  14. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/BxxbHW41.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/C4sXYFFj.js +1 -1
  15. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/C92D-6Mo.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/CHFRUdvG.js +1 -1
  16. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/CZmx3lfa.js +1 -0
  17. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/CfPWzxx9.js +2 -0
  18. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/DS97ykb2.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/Cq-WyKR3.js +1 -1
  19. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/CvUL_eGA.js +2 -0
  20. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/CyI3pj5p.js +1 -0
  21. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/se_iUg_v.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/DnOfo-ZS.js +1 -1
  22. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/Dsl-dlBH.js +1 -0
  23. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/Drxlg-Xn.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/XfyNEFST.js +1 -1
  24. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/CTc1z_v2.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/fAgV3R1g.js +1 -1
  25. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/gMw3n3N4.js +1 -0
  26. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/DVIxwpxE.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/mQ-6pls1.js +1 -1
  27. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/CINfEwQf.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/chunks/xV1gGuCK.js +11 -11
  28. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/entry/app.kesLuhQF.js +2 -0
  29. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/entry/start.DVjKW3Ea.js +1 -0
  30. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/nodes/0.B6XItSbU.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/nodes/0.BOGH3qWK.js +2 -2
  31. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/nodes/1.rK0DannD.js +1 -0
  32. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/nodes/10.DUqmt2a_.js +1 -0
  33. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/nodes/11.BJBKTVl-.js +1 -0
  34. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/nodes/12.C5VaASOl.js +1 -0
  35. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/nodes/2.CsuYZjX1.js +1 -0
  36. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/nodes/3.Dw3puJTo.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/nodes/3.BoudEeAP.js +1 -1
  37. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/nodes/4.DxxR0ke_.js +1 -0
  38. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/nodes/5.CbfCxsxH.js +1 -0
  39. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/nodes/6.CIB5Uqo0.js +5 -0
  40. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/nodes/7.D7VhYfui.js +3 -0
  41. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/nodes/8.zCavfpyd.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/nodes/8.BaWCew_X.js +1 -1
  42. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/nodes/9.C0TrNojy.js → zen_temple-0.7.3.dev1/zen_temple/explorer/_app/immutable/nodes/9.CHYR81yc.js +1 -1
  43. zen_temple-0.7.3.dev1/zen_temple/explorer/_app/version.json +1 -0
  44. {zen_temple-0.7.2.dev1/zen_temple/explorer/energy_system → zen_temple-0.7.3.dev1/zen_temple/explorer/energy_balance/nodal}/index.html +13 -13
  45. {zen_temple-0.7.2.dev1/zen_temple/explorer/energy_balance/nodal → zen_temple-0.7.3.dev1/zen_temple/explorer/energy_balance/storage}/index.html +13 -13
  46. {zen_temple-0.7.2.dev1/zen_temple/explorer/energy_balance/storage → zen_temple-0.7.3.dev1/zen_temple/explorer/energy_system}/index.html +13 -13
  47. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/index.html +13 -13
  48. zen_temple-0.7.3.dev1/zen_temple/explorer/map/index.html +52 -0
  49. zen_temple-0.7.3.dev1/zen_temple/explorer/transition/capacity/index.html +52 -0
  50. zen_temple-0.7.3.dev1/zen_temple/explorer/transition/costs/index.html +52 -0
  51. zen_temple-0.7.3.dev1/zen_temple/explorer/transition/emissions/index.html +52 -0
  52. zen_temple-0.7.3.dev1/zen_temple/explorer/transition/index.html +52 -0
  53. zen_temple-0.7.3.dev1/zen_temple/explorer/transition/production/index.html +52 -0
  54. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/models/solution.py +26 -26
  55. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/repositories/solution_repository.py +28 -5
  56. zen_temple-0.7.3.dev1/zen_temple.egg-info/PKG-INFO +126 -0
  57. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple.egg-info/SOURCES.txt +39 -39
  58. zen_temple-0.7.2.dev1/PKG-INFO +0 -99
  59. zen_temple-0.7.2.dev1/README.md +0 -76
  60. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/assets/6.RyvcvckI.css +0 -1
  61. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/assets/_page.RyvcvckI.css +0 -1
  62. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/6KI89v4Y.js +0 -1
  63. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/BIpecMnu.js +0 -2
  64. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/BNZwnsPw.js +0 -1
  65. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/BbB4DTre.js +0 -1
  66. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/C6Y5c09E.js +0 -22
  67. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/CmpsC6LN.js +0 -1
  68. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/CpZHtke-.js +0 -1
  69. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/CxYln1hn.js +0 -2
  70. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/D6s5toP0.js +0 -1
  71. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/DL8SZLkd.js +0 -1
  72. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/DicWSYyP.js +0 -1
  73. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/chunks/iLwl9KAB.js +0 -1
  74. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/entry/app.Bp3FD6fc.js +0 -2
  75. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/entry/start.CnZ2Rhut.js +0 -1
  76. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/nodes/1.DmpENjmB.js +0 -1
  77. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/nodes/10.BWlUcSUW.js +0 -1
  78. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/nodes/11.CtdXfl4D.js +0 -1
  79. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/nodes/12.Mxj6Y4wo.js +0 -1
  80. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/nodes/2.0g-D28Cy.js +0 -1
  81. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/nodes/4.XXRRLHyJ.js +0 -1
  82. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/nodes/5.DAcJ1nQf.js +0 -1
  83. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/nodes/6.CdUDVMzG.js +0 -3
  84. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/immutable/nodes/7.CWlGsJIN.js +0 -3
  85. zen_temple-0.7.2.dev1/zen_temple/explorer/_app/version.json +0 -1
  86. zen_temple-0.7.2.dev1/zen_temple/explorer/map/index.html +0 -52
  87. zen_temple-0.7.2.dev1/zen_temple/explorer/transition/capacity/index.html +0 -52
  88. zen_temple-0.7.2.dev1/zen_temple/explorer/transition/costs/index.html +0 -52
  89. zen_temple-0.7.2.dev1/zen_temple/explorer/transition/emissions/index.html +0 -52
  90. zen_temple-0.7.2.dev1/zen_temple/explorer/transition/index.html +0 -52
  91. zen_temple-0.7.2.dev1/zen_temple/explorer/transition/production/index.html +0 -52
  92. zen_temple-0.7.2.dev1/zen_temple.egg-info/PKG-INFO +0 -99
  93. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/LICENSE +0 -0
  94. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/setup.cfg +0 -0
  95. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/__init__.py +0 -0
  96. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/config.py +0 -0
  97. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/env.js +0 -0
  98. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/assets/0.D1tPPeLD.css +0 -0
  99. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/assets/3.BLUK3SDz.css +0 -0
  100. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/assets/7.B0mkfc-a.css +0 -0
  101. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/assets/BarPlot.BovkadW7.css +0 -0
  102. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/assets/_layout.D1tPPeLD.css +0 -0
  103. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/assets/_page.B0mkfc-a.css +0 -0
  104. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/assets/_page.BLUK3SDz.css +0 -0
  105. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/assets/bootstrap-icons.BeopsB42.woff +0 -0
  106. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/assets/bootstrap-icons.mSm7cUeB.woff2 +0 -0
  107. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/assets/zen_garden_small.Bbfqs-kl.png +0 -0
  108. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/chunks/43hnhKVC.js +0 -0
  109. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/chunks/69_IOA4Y.js +0 -0
  110. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/chunks/B34HR-o6.js +0 -0
  111. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/chunks/BGj-pI5n.js +0 -0
  112. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/chunks/BXl3LOEh.js +0 -0
  113. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/chunks/CpFZsRVk.js +0 -0
  114. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/chunks/CqS7hfz2.js +0 -0
  115. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/chunks/DIeogL5L.js +0 -0
  116. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/_app/immutable/chunks/DsnmJJEf.js +0 -0
  117. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/apple-touch-icon.png +0 -0
  118. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/favicon-96x96.png +0 -0
  119. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/favicon.ico +0 -0
  120. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/favicon.svg +0 -0
  121. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/site.webmanifest +0 -0
  122. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/web-app-manifest-192x192.png +0 -0
  123. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/explorer/web-app-manifest-512x512.png +0 -0
  124. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/main.py +0 -0
  125. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/models/__init__.py +0 -0
  126. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/py.typed +0 -0
  127. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/repositories/__init__.py +0 -0
  128. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/routers/__init__.py +0 -0
  129. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/routers/solutions.py +0 -0
  130. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple/utils.py +0 -0
  131. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple.egg-info/dependency_links.txt +0 -0
  132. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple.egg-info/requires.txt +0 -0
  133. {zen_temple-0.7.2.dev1 → zen_temple-0.7.3.dev1}/zen_temple.egg-info/top_level.txt +0 -0
@@ -0,0 +1,126 @@
1
+ Metadata-Version: 2.4
2
+ Name: zen_temple
3
+ Version: 0.7.3.dev1
4
+ Summary: The visualization plattform for ZEN-garden
5
+ Author-email: ZEN-garden developers <zen-garden@ethz.ch>
6
+ Project-URL: Homepage, https://github.com/ZEN-universe/ZEN-temple
7
+ Project-URL: Issues, https://github.com/ZEN-universe/ZEN-temple/issues
8
+ Classifier: Programming Language :: Python :: 3
9
+ Classifier: License :: OSI Approved :: MIT License
10
+ Classifier: Operating System :: OS Independent
11
+ Requires-Python: >=3.10
12
+ Description-Content-Type: text/markdown
13
+ License-File: LICENSE
14
+ Requires-Dist: uvicorn
15
+ Requires-Dist: fastapi[standard]
16
+ Requires-Dist: fastapi-cache2
17
+ Requires-Dist: python-dotenv
18
+ Requires-Dist: zen-garden
19
+ Requires-Dist: mypy>=1.14.1
20
+ Provides-Extra: mypy
21
+ Requires-Dist: pandas-stubs; extra == "mypy"
22
+ Dynamic: license-file
23
+
24
+ # ZEN-temple
25
+
26
+ ZEN-temple is a FastAPI Application that provides a REST API to access results from [ZEN-garden](https://github.com/ZEN-universe/ZEN-garden). It is used as a backend for [ZEN-Explorer](https://github.com/ZEN-universe/ZEN-explorer).
27
+
28
+ [![PyPI - Version](https://img.shields.io/pypi/v/zen-temple?logo=pypi&logoColor=fff&color=0375b5)](https://pypi.org/project/zen-temple/)
29
+ ![Python Version from PEP 621 TOML](https://img.shields.io/python/required-version-toml?tomlFilePath=https%3A%2F%2Fgithub.com%2FZEN-universe%2FZEN-temple%2Fraw%2Frefs%2Fheads%2Fmain%2Fpyproject.toml)
30
+
31
+ [![GitHub Actions: Type checker](https://github.com/ZEN-universe/ZEN-temple/actions/workflows/run-mypy.yml/badge.svg)](https://github.com/ZEN-universe/ZEN-temple/actions/workflows/run-mypy.yml)
32
+
33
+ [![GitHub License](https://img.shields.io/github/license/ZEN-universe/ZEN-temple?label=License)](https://github.com/ZEN-universe/ZEN-temple/blob/main/LICENSE)
34
+
35
+ ## 🛠️ Requirements
36
+
37
+ - Conda (https://docs.conda.io/en/latest/miniconda.html)
38
+ - Python 3.10 or higher
39
+
40
+ ## 📦 Installation
41
+
42
+ Perform the following steps to install ZEN-temple:
43
+
44
+ 1. Clone the repository and navigate into the folder:
45
+
46
+ ```bash
47
+ git clone https://github.com/ZEN-universe/ZEN-temple.git
48
+ cd ZEN-temple
49
+ ```
50
+
51
+ 1. Create a new conda environment, activate it, and install all dependencies:
52
+
53
+ ```bash
54
+ conda create --name <your-env-name> python==3.12
55
+ conda activate <your-env-name>
56
+ pip install -e .[mypy]
57
+ ```
58
+
59
+ 2. Create a new copy of `.env`.
60
+
61
+ ```bash
62
+ cp .env.example .env
63
+ ```
64
+
65
+ Modify the `SOLUTION_FOLDER` variable to the location of your solutions, e.g. `./outputs`. This is the `outputs` folder generated by ZEN-garden.
66
+
67
+ ## ▶️ Usage
68
+
69
+ Open this folder in your terminal. Activate your conda environment for this project and run the application with the following commands:
70
+
71
+ ```bash
72
+ conda activate <your-env-name>
73
+ python -m zen_temple.main --reload
74
+ ```
75
+
76
+ For information about the available command line arguments run:
77
+
78
+ ```bash
79
+ python -m zen_temple.main --help
80
+ ```
81
+
82
+ ## 📤 Release workflow
83
+
84
+ To create a new release of ZEN-temple follow the following steps. The idea is that for each major release (from `v0.4.x` to `v0.5.0`) we sync the version number of ZEN-explorer and ZEN-temple
85
+
86
+ 1. Bump version in ZEN-explorer `bash scripts/bump_version.sh` and update its CHANGELOG.md.
87
+ 2. Commit and upload the updated files to GitHub.
88
+ 3. Create a new release for ZEN-explorer:
89
+ https://github.com/ZEN-universe/ZEN-explorer/releases/new
90
+ 4. Bump version in ZEN-temple `bash scripts/bump_version.sh` and update [CHANGELOG.md](CHANGELOG.md).
91
+ 5. Commit and upload the updated files to GitHub.
92
+ 6. Create a new release for ZEN-temple, e.g. `<version>`. For a pre-release also add a suffix `.dev1`, i.e. `<version>.dev1`, and mark the release as pre-release:
93
+ https://github.com/ZEN-universe/ZEN-temple/releases/new
94
+ 7. (optional) Look at PyPI whether the new release has successfully been created:
95
+ https://pypi.org/project/zen-temple/#history
96
+
97
+ ## 🗂️ Folder structure
98
+
99
+ The folder and file structure is the following:
100
+
101
+ ### Explorer
102
+
103
+ `explorer` contains the HTML files for the frontend.
104
+
105
+ > [!WARNING]
106
+ > Do not edit the files in this folder. This folder is automatically generated by the frontend repository pipeline.
107
+
108
+ ### Models
109
+
110
+ `models` contains the Pydantic-models that are used for the documentation. Some of these models also include generators that create an instance of the model given the path of a solution. See https://fastapi.tiangolo.com/tutorial/body/#create-your-data-model
111
+
112
+ ### Repositories
113
+
114
+ `repositories` contains the repositories for the data access. These provide an abstraction layer for the routers such that the data access is separated from the data source. Arguably, the generators defined in the models should be part of the repository in order to separate the instantiation of the models from the way that the solutions are stored. For more information visit https://www.umlboard.com/design-patterns/repository.html
115
+
116
+ ### Routers
117
+
118
+ `routers` contains the FastAPI routers which define the different paths of the API server. For more information visit https://fastapi.tiangolo.com/tutorial/bigger-applications/
119
+
120
+ ### Config
121
+
122
+ `config.py` contains the config of the application.
123
+
124
+ ### Main
125
+
126
+ `main.py` contains the setup of the FastAPI application. For more information visit https://fastapi.tiangolo.com/tutorial/bigger-applications/
@@ -0,0 +1,103 @@
1
+ # ZEN-temple
2
+
3
+ ZEN-temple is a FastAPI Application that provides a REST API to access results from [ZEN-garden](https://github.com/ZEN-universe/ZEN-garden). It is used as a backend for [ZEN-Explorer](https://github.com/ZEN-universe/ZEN-explorer).
4
+
5
+ [![PyPI - Version](https://img.shields.io/pypi/v/zen-temple?logo=pypi&logoColor=fff&color=0375b5)](https://pypi.org/project/zen-temple/)
6
+ ![Python Version from PEP 621 TOML](https://img.shields.io/python/required-version-toml?tomlFilePath=https%3A%2F%2Fgithub.com%2FZEN-universe%2FZEN-temple%2Fraw%2Frefs%2Fheads%2Fmain%2Fpyproject.toml)
7
+
8
+ [![GitHub Actions: Type checker](https://github.com/ZEN-universe/ZEN-temple/actions/workflows/run-mypy.yml/badge.svg)](https://github.com/ZEN-universe/ZEN-temple/actions/workflows/run-mypy.yml)
9
+
10
+ [![GitHub License](https://img.shields.io/github/license/ZEN-universe/ZEN-temple?label=License)](https://github.com/ZEN-universe/ZEN-temple/blob/main/LICENSE)
11
+
12
+ ## 🛠️ Requirements
13
+
14
+ - Conda (https://docs.conda.io/en/latest/miniconda.html)
15
+ - Python 3.10 or higher
16
+
17
+ ## 📦 Installation
18
+
19
+ Perform the following steps to install ZEN-temple:
20
+
21
+ 1. Clone the repository and navigate into the folder:
22
+
23
+ ```bash
24
+ git clone https://github.com/ZEN-universe/ZEN-temple.git
25
+ cd ZEN-temple
26
+ ```
27
+
28
+ 1. Create a new conda environment, activate it, and install all dependencies:
29
+
30
+ ```bash
31
+ conda create --name <your-env-name> python==3.12
32
+ conda activate <your-env-name>
33
+ pip install -e .[mypy]
34
+ ```
35
+
36
+ 2. Create a new copy of `.env`.
37
+
38
+ ```bash
39
+ cp .env.example .env
40
+ ```
41
+
42
+ Modify the `SOLUTION_FOLDER` variable to the location of your solutions, e.g. `./outputs`. This is the `outputs` folder generated by ZEN-garden.
43
+
44
+ ## ▶️ Usage
45
+
46
+ Open this folder in your terminal. Activate your conda environment for this project and run the application with the following commands:
47
+
48
+ ```bash
49
+ conda activate <your-env-name>
50
+ python -m zen_temple.main --reload
51
+ ```
52
+
53
+ For information about the available command line arguments run:
54
+
55
+ ```bash
56
+ python -m zen_temple.main --help
57
+ ```
58
+
59
+ ## 📤 Release workflow
60
+
61
+ To create a new release of ZEN-temple follow the following steps. The idea is that for each major release (from `v0.4.x` to `v0.5.0`) we sync the version number of ZEN-explorer and ZEN-temple
62
+
63
+ 1. Bump version in ZEN-explorer `bash scripts/bump_version.sh` and update its CHANGELOG.md.
64
+ 2. Commit and upload the updated files to GitHub.
65
+ 3. Create a new release for ZEN-explorer:
66
+ https://github.com/ZEN-universe/ZEN-explorer/releases/new
67
+ 4. Bump version in ZEN-temple `bash scripts/bump_version.sh` and update [CHANGELOG.md](CHANGELOG.md).
68
+ 5. Commit and upload the updated files to GitHub.
69
+ 6. Create a new release for ZEN-temple, e.g. `<version>`. For a pre-release also add a suffix `.dev1`, i.e. `<version>.dev1`, and mark the release as pre-release:
70
+ https://github.com/ZEN-universe/ZEN-temple/releases/new
71
+ 7. (optional) Look at PyPI whether the new release has successfully been created:
72
+ https://pypi.org/project/zen-temple/#history
73
+
74
+ ## 🗂️ Folder structure
75
+
76
+ The folder and file structure is the following:
77
+
78
+ ### Explorer
79
+
80
+ `explorer` contains the HTML files for the frontend.
81
+
82
+ > [!WARNING]
83
+ > Do not edit the files in this folder. This folder is automatically generated by the frontend repository pipeline.
84
+
85
+ ### Models
86
+
87
+ `models` contains the Pydantic-models that are used for the documentation. Some of these models also include generators that create an instance of the model given the path of a solution. See https://fastapi.tiangolo.com/tutorial/body/#create-your-data-model
88
+
89
+ ### Repositories
90
+
91
+ `repositories` contains the repositories for the data access. These provide an abstraction layer for the routers such that the data access is separated from the data source. Arguably, the generators defined in the models should be part of the repository in order to separate the instantiation of the models from the way that the solutions are stored. For more information visit https://www.umlboard.com/design-patterns/repository.html
92
+
93
+ ### Routers
94
+
95
+ `routers` contains the FastAPI routers which define the different paths of the API server. For more information visit https://fastapi.tiangolo.com/tutorial/bigger-applications/
96
+
97
+ ### Config
98
+
99
+ `config.py` contains the config of the application.
100
+
101
+ ### Main
102
+
103
+ `main.py` contains the setup of the FastAPI application. For more information visit https://fastapi.tiangolo.com/tutorial/bigger-applications/
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "zen_temple"
7
- version = "0.7.2.dev1"
7
+ version = "0.7.3.dev1"
8
8
  authors = [
9
9
  { name="ZEN-garden developers", email="zen-garden@ethz.ch" },
10
10
  ]
@@ -0,0 +1,2 @@
1
+ class InvalidSolutionFolderError(Exception):
2
+ pass
@@ -0,0 +1 @@
1
+ svg.svelte-1wzhsk8{font:9px sans-serif}.node.svelte-1wzhsk8{cursor:row-resize}.node.svelte-1wzhsk8 rect:where(.svelte-1wzhsk8){stroke:#000;stroke-width:2px}.link.svelte-1wzhsk8{fill:none;stroke:#000;stroke-opacity:.3}.link.svelte-1wzhsk8:hover{stroke-opacity:.5}.cycle-link.svelte-1wzhsk8{opacity:.3;stroke:none;stroke-linejoin:round}.cycle-link.svelte-1wzhsk8:hover{opacity:.5}.fs-7.svelte-1wzhsk8{font-size:.875rem}.fs-8.svelte-1wzhsk8{font-size:.75rem}.text-no-break.svelte-1wzhsk8{white-space:nowrap}
@@ -0,0 +1 @@
1
+ svg.svelte-1wzhsk8{font:9px sans-serif}.node.svelte-1wzhsk8{cursor:row-resize}.node.svelte-1wzhsk8 rect:where(.svelte-1wzhsk8){stroke:#000;stroke-width:2px}.link.svelte-1wzhsk8{fill:none;stroke:#000;stroke-opacity:.3}.link.svelte-1wzhsk8:hover{stroke-opacity:.5}.cycle-link.svelte-1wzhsk8{opacity:.3;stroke:none;stroke-linejoin:round}.cycle-link.svelte-1wzhsk8:hover{opacity:.5}.fs-7.svelte-1wzhsk8{font-size:.875rem}.fs-8.svelte-1wzhsk8{font-size:.75rem}.text-no-break.svelte-1wzhsk8{white-space:nowrap}
@@ -1 +1 @@
1
- import{D as c,q as f,E as _,F as d,G as l,B as u,H as h,I as m,n as v,J as y,K as o,L as g}from"./Drxlg-Xn.js";function b(r,n,...s){var t=r,e=v,a;c(()=>{e!==(e=n())&&(a&&(y(a),a=null),a=m(()=>e(t,...s)))},h),f&&(t=o)}function F(r){return(n,...s)=>{var t=r(...s),e;if(f)e=o,_();else{var a=t.render().trim(),p=d(a);e=g(p),n.before(e)}const i=t.setup?.(e);l(e,e),typeof i=="function"&&u(i)}}export{F as c,b as s};
1
+ import{D as c,q as f,E as _,F as d,G as l,B as u,H as h,I as m,n as v,J as y,K as o,L as g}from"./XfyNEFST.js";function b(r,n,...s){var t=r,e=v,a;c(()=>{e!==(e=n())&&(a&&(y(a),a=null),a=m(()=>e(t,...s)))},h),f&&(t=o)}function F(r){return(n,...s)=>{var t=r(...s),e;if(f)e=o,_();else{var a=t.render().trim(),p=d(a);e=g(p),n.before(e)}const i=t.setup?.(e);l(e,e),typeof i=="function"&&u(i)}}export{F as c,b as s};
@@ -1 +1 @@
1
- import{t as b}from"./BIpecMnu.js";import{q as g}from"./Drxlg-Xn.js";function A(i,h,t,N,f,r){var o=i.__className;if(g||o!==t||o===void 0){var a=b(t,N,r);(!g||a!==i.getAttribute("class"))&&(a==null?i.removeAttribute("class"):i.className=a),i.__className=t}else if(r&&f!==r)for(var l in r){var u=!!r[l];(f==null||u!==!!f[l])&&i.classList.toggle(l,u)}return r}export{A as s};
1
+ import{t as b}from"./CvUL_eGA.js";import{q as g}from"./XfyNEFST.js";function A(i,h,t,N,f,r){var o=i.__className;if(g||o!==t||o===void 0){var a=b(t,N,r);(!g||a!==i.getAttribute("class"))&&(a==null?i.removeAttribute("class"):i.className=a),i.__className=t}else if(r&&f!==r)for(var l in r){var u=!!r[l];(f==null||u!==!!f[l])&&i.classList.toggle(l,u)}return r}export{A as s};
@@ -0,0 +1 @@
1
+ import{M as L,N as p,O as v,P as M,Q as S,R as k,B,C as O,S as T}from"./XfyNEFST.js";const q=new Set,x=new Set;function N(r,a,i,n={}){function e(t){if(n.capture||P.call(a,t),!t.cancelBubble)return T(()=>i?.call(this,t))}return r.startsWith("pointer")||r.startsWith("touch")||r==="wheel"?O(()=>{a.addEventListener(r,e,n)}):a.addEventListener(r,e,n),e}function C(r,a,i,n,e){var t={capture:n,passive:e},l=N(r,a,i,t);(a===document.body||a===window||a===document||a instanceof HTMLMediaElement)&&B(()=>{a.removeEventListener(r,l,t)})}function D(r){for(var a=0;a<r.length;a++)q.add(r[a]);for(var i of x)i(r)}let g=null;function P(r){var a=this,i=a.ownerDocument,n=r.type,e=r.composedPath?.()||[],t=e[0]||r.target;g=r;var l=0,_=g===r&&r.__root;if(_){var u=e.indexOf(_);if(u!==-1&&(a===document||a===window)){r.__root=a;return}var d=e.indexOf(a);if(d===-1)return;u<=d&&(l=u)}if(t=e[l]||r.target,t!==a){L(r,"currentTarget",{configurable:!0,get(){return t||i}});var w=S,b=k;p(null),v(null);try{for(var c,h=[];t!==null;){var f=t.assignedSlot||t.parentNode||t.host||null;try{var o=t["__"+n];if(o!=null&&(!t.disabled||r.target===t))if(M(o)){var[y,...E]=o;y.apply(t,[r,...E])}else o.call(t,r)}catch(s){c?h.push(s):c=s}if(r.cancelBubble||f===a||f===null)break;t=f}if(c){for(let s of h)queueMicrotask(()=>{throw s});throw c}}finally{r.__root=a,delete r.currentTarget,p(w),v(b)}}}export{q as a,D as d,C as e,P as h,x as r};
@@ -0,0 +1 @@
1
+ const s=globalThis.__sveltekit_g111ct?.base??"",t=globalThis.__sveltekit_g111ct?.assets??s;export{t as a,s as b};
@@ -0,0 +1 @@
1
+ import{P as y,_ as le,ar as oe,a8 as j,D as ce,a6 as V,q as L,L as de,E as ve,g as x,aj as _e,a3 as he,a4 as me,a5 as W,a7 as Y,K as P,as as pe,at as Ee,I as K,ab as we,a9 as Ae,au as Z,av as Re,aw as $,ax as ee,ay as q,ac as re,ad as Te,az as B,aA as Ce,aB as z,J as ae,aC as Ie,aD as ge,aE as Ne,aF as Se,R as Le,C as xe,aG as ne,aH as Me,s as De,b as Pe,d as Ue}from"./XfyNEFST.js";import{r as be}from"./mQ-6pls1.js";import{p as k}from"./C4sXYFFj.js";const He=[];function Oe(e,a=!1){return O(e,new Map,"",He)}function O(e,a,r,f,l=null){if(typeof e=="object"&&e!==null){var o=a.get(e);if(o!==void 0)return o;if(e instanceof Map)return new Map(e);if(e instanceof Set)return new Set(e);if(y(e)){var t=Array(e.length);a.set(e,t),l!==null&&a.set(l,t);for(var c=0;c<e.length;c+=1){var w=e[c];c in e&&(t[c]=O(w,a,r,f))}return t}if(le(e)===oe){t={},a.set(e,t),l!==null&&a.set(l,t);for(var h in e)t[h]=O(e[h],a,r,f);return t}if(e instanceof Date)return structuredClone(e);if(typeof e.toJSON=="function")return O(e.toJSON(),a,r,f,e)}if(e instanceof EventTarget)return e;try{return structuredClone(e)}catch{return e}}function Ye(e,a){return a}function qe(e,a,r){for(var f=e.items,l=[],o=a.length,t=0;t<o;t++)ge(a[t].e,l,!0);var c=o>0&&l.length===0&&r!==null;if(c){var w=r.parentNode;Ne(w),w.append(r),f.clear(),C(e,a[0].prev,a[o-1].next)}Se(l,()=>{for(var h=0;h<o;h++){var v=a[h];c||(f.delete(v.k),C(e,v.prev,v.next)),ae(v.e,!c)}})}function ze(e,a,r,f,l,o=null){var t=e,c={flags:a,items:new Map,first:null},w=(a&ne)!==0;if(w){var h=e;t=L?V(de(h)):h.appendChild(j())}L&&ve();var v=null,g=!1,A=new Map,N=_e(()=>{var _=r();return y(_)?_:_==null?[]:ee(_)}),s,d;function u(){Be(d,s,c,A,t,l,a,f,r),o!==null&&(s.length===0?v?re(v):v=K(()=>o(t)):v!==null&&Te(v,()=>{v=null}))}ce(()=>{d??=Le,s=x(N);var _=s.length;if(g&&_===0)return;g=_===0;let E=!1;if(L){var R=he(t)===me;R!==(_===0)&&(t=W(),V(t),Y(!1),E=!0)}if(L){for(var I=null,m,n=0;n<_;n++){if(P.nodeType===pe&&P.data===Ee){t=P,E=!0,Y(!1);break}var i=s[n],p=f(i,n);m=X(P,c,I,null,i,p,n,l,a,r),c.items.set(p,m),I=m}_>0&&V(W())}if(L)_===0&&o&&(v=K(()=>o(t)));else if(we()){var M=new Set,b=Ae;for(n=0;n<_;n+=1){i=s[n],p=f(i,n);var S=c.items.get(p)??A.get(p);S?(a&(B|q))!==0&&te(S,i,n,a):(m=X(null,c,null,null,i,p,n,l,a,r,!0),A.set(p,m)),M.add(p)}for(const[T,H]of c.items)M.has(T)||b.skipped_effects.add(H.e);b.add_callback(u)}else u();E&&Y(!0),x(N)}),L&&(t=P)}function Be(e,a,r,f,l,o,t,c,w){var h=(t&Me)!==0,v=(t&(B|q))!==0,g=a.length,A=r.items,N=r.first,s=N,d,u=null,_,E=[],R=[],I,m,n,i;if(h)for(i=0;i<g;i+=1)I=a[i],m=c(I,i),n=A.get(m),n!==void 0&&(n.a?.measure(),(_??=new Set).add(n));for(i=0;i<g;i+=1){if(I=a[i],m=c(I,i),n=A.get(m),n===void 0){var p=f.get(m);if(p!==void 0){f.delete(m),A.set(m,p);var M=u?u.next:s;C(r,u,p),C(r,p,M),G(p,M,l),u=p}else{var b=s?s.e.nodes_start:l;u=X(b,r,u,u===null?r.first:u.next,I,m,i,o,t,w)}A.set(m,u),E=[],R=[],s=u.next;continue}if(v&&te(n,I,i,t),(n.e.f&z)!==0&&(re(n.e),h&&(n.a?.unfix(),(_??=new Set).delete(n))),n!==s){if(d!==void 0&&d.has(n)){if(E.length<R.length){var S=R[0],T;u=S.prev;var H=E[0],J=E[E.length-1];for(T=0;T<E.length;T+=1)G(E[T],S,l);for(T=0;T<R.length;T+=1)d.delete(R[T]);C(r,H.prev,J.next),C(r,u,H),C(r,J,S),s=S,u=J,i-=1,E=[],R=[]}else d.delete(n),G(n,s,l),C(r,n.prev,n.next),C(r,n,u===null?r.first:u.next),C(r,u,n),u=n;continue}for(E=[],R=[];s!==null&&s.k!==m;)(s.e.f&z)===0&&(d??=new Set).add(s),R.push(s),s=s.next;if(s===null)continue;n=s}E.push(n),u=n,s=n.next}if(s!==null||d!==void 0){for(var D=d===void 0?[]:ee(d);s!==null;)(s.e.f&z)===0&&D.push(s),s=s.next;var F=D.length;if(F>0){var ie=(t&ne)!==0&&g===0?l:null;if(h){for(i=0;i<F;i+=1)D[i].a?.measure();for(i=0;i<F;i+=1)D[i].a?.fix()}qe(r,D,ie)}}h&&xe(()=>{if(_!==void 0)for(n of _)n.a?.apply()}),e.first=r.first&&r.first.e,e.last=u&&u.e;for(var ue of f.values())ae(ue.e);f.clear()}function te(e,a,r,f){(f&B)!==0&&Z(e.v,a),(f&q)!==0?Z(e.i,r):e.i=r}function X(e,a,r,f,l,o,t,c,w,h,v){var g=(w&B)!==0,A=(w&Ce)===0,N=g?A?Re(l,!1,!1):$(l):l,s=(w&q)===0?t:$(t),d={i:s,v:N,k:o,a:null,e:null,prev:r,next:f};try{if(e===null){var u=document.createDocumentFragment();u.append(e=j())}return d.e=K(()=>c(e,N,s,h),L),d.e.prev=r&&r.e,d.e.next=f&&f.e,r===null?v||(a.first=d):(r.next=d,r.e.next=d.e),f!==null&&(f.prev=d,f.e.prev=d.e),d}finally{}}function G(e,a,r){for(var f=e.next?e.next.e.nodes_start:r,l=a?a.e.nodes_start:r,o=e.e.nodes_start;o!==null&&o!==f;){var t=Ie(o);l.before(o),o=t}}function C(e,a,r){a===null?e.first=r:(a.next=r,a.e.next=r&&r.e),r!==null&&(r.prev=a,r.e.prev=a&&a.e)}const Ge=globalThis.__sveltekit_g111ct.env;let U=De(Pe({}));function se(e){const a=k.state,r=k.url.searchParams;return a[e]??r.get(e)}function Q(e){const a=se(e);return a?decodeURIComponent(a):null}function Ke(e){const a=se(e);return a===null?null:a.split("~").map(r=>parseInt(r)).filter(r=>!isNaN(r))}function Xe(e,a){const r=Q(e);return r===null?a:r==="1"||r==="true"}function fe(e,a){a||(a=window.location.href);const r=new URL(a,window.location.origin);for(const f in e)e[f]!==null?r.searchParams.set(f,e[f]):r.searchParams.delete(f);return r}function Qe(e){return fe({solution:x(U).solution||Q("solution")||"",scenario:x(U).scenario||Q("scenario")||""},e).href}function We(e){Ue(U,{...x(U),...e},!0),be(fe(e),Oe(x(U)))}export{Xe as a,Ke as b,Ge as c,Qe as d,ze as e,Q as g,Ye as i,Oe as s,We as u};
@@ -0,0 +1 @@
1
+ import"./DsnmJJEf.js";import{h as Zn,m as Jn,i as jn,r as te,v as ne,a as It,a_ as xn}from"./XfyNEFST.js";import{s as ee}from"./-3L7ibXM.js";import{p as nn,i as re}from"./CyI3pj5p.js";import{s as Dt}from"./fAgV3R1g.js";import{l as ie}from"./C0T7Jkdw.js";var Pt="http://www.w3.org/1999/xhtml";const en={svg:"http://www.w3.org/2000/svg",xhtml:Pt,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function $t(t){var n=t+="",e=n.indexOf(":");return e>=0&&(n=t.slice(0,e))!=="xmlns"&&(t=t.slice(e+1)),en.hasOwnProperty(n)?{space:en[n],local:t}:t}function oe(t){return function(){var n=this.ownerDocument,e=this.namespaceURI;return e===Pt&&n.documentElement.namespaceURI===Pt?n.createElement(t):n.createElementNS(e,t)}}function se(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function bn(t){var n=$t(t);return(n.local?se:oe)(n)}function ae(){}function Kt(t){return t==null?ae:function(){return this.querySelector(t)}}function ue(t){typeof t!="function"&&(t=Kt(t));for(var n=this._groups,e=n.length,r=new Array(e),i=0;i<e;++i)for(var o=n[i],s=o.length,a=r[i]=new Array(s),u,c,f=0;f<s;++f)(u=o[f])&&(c=t.call(u,u.__data__,f,o))&&("__data__"in u&&(c.__data__=u.__data__),a[f]=c);return new z(r,this._parents)}function ce(t){return t==null?[]:Array.isArray(t)?t:Array.from(t)}function le(){return[]}function Nn(t){return t==null?le:function(){return this.querySelectorAll(t)}}function fe(t){return function(){return ce(t.apply(this,arguments))}}function he(t){typeof t=="function"?t=fe(t):t=Nn(t);for(var n=this._groups,e=n.length,r=[],i=[],o=0;o<e;++o)for(var s=n[o],a=s.length,u,c=0;c<a;++c)(u=s[c])&&(r.push(t.call(u,u.__data__,c,s)),i.push(u));return new z(r,i)}function kn(t){return function(){return this.matches(t)}}function An(t){return function(n){return n.matches(t)}}var pe=Array.prototype.find;function de(t){return function(){return pe.call(this.children,t)}}function ge(){return this.firstElementChild}function me(t){return this.select(t==null?ge:de(typeof t=="function"?t:An(t)))}var _e=Array.prototype.filter;function ye(){return Array.from(this.children)}function ve(t){return function(){return _e.call(this.children,t)}}function we(t){return this.selectAll(t==null?ye:ve(typeof t=="function"?t:An(t)))}function xe(t){typeof t!="function"&&(t=kn(t));for(var n=this._groups,e=n.length,r=new Array(e),i=0;i<e;++i)for(var o=n[i],s=o.length,a=r[i]=[],u,c=0;c<s;++c)(u=o[c])&&t.call(u,u.__data__,c,o)&&a.push(u);return new z(r,this._parents)}function En(t){return new Array(t.length)}function be(){return new z(this._enter||this._groups.map(En),this._parents)}function kt(t,n){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=n}kt.prototype={constructor:kt,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,n){return this._parent.insertBefore(t,n)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};function Ne(t){return function(){return t}}function ke(t,n,e,r,i,o){for(var s=0,a,u=n.length,c=o.length;s<c;++s)(a=n[s])?(a.__data__=o[s],r[s]=a):e[s]=new kt(t,o[s]);for(;s<u;++s)(a=n[s])&&(i[s]=a)}function Ae(t,n,e,r,i,o,s){var a,u,c=new Map,f=n.length,p=o.length,d=new Array(f),g;for(a=0;a<f;++a)(u=n[a])&&(d[a]=g=s.call(u,u.__data__,a,n)+"",c.has(g)?i[a]=u:c.set(g,u));for(a=0;a<p;++a)g=s.call(t,o[a],a,o)+"",(u=c.get(g))?(r[a]=u,u.__data__=o[a],c.delete(g)):e[a]=new kt(t,o[a]);for(a=0;a<f;++a)(u=n[a])&&c.get(d[a])===u&&(i[a]=u)}function Ee(t){return t.__data__}function Te(t,n){if(!arguments.length)return Array.from(this,Ee);var e=n?Ae:ke,r=this._parents,i=this._groups;typeof t!="function"&&(t=Ne(t));for(var o=i.length,s=new Array(o),a=new Array(o),u=new Array(o),c=0;c<o;++c){var f=r[c],p=i[c],d=p.length,g=Me(t.call(f,f&&f.__data__,c,r)),b=g.length,k=a[c]=new Array(b),T=s[c]=new Array(b),y=u[c]=new Array(d);e(f,p,k,T,y,g,n);for(var M=0,S=0,F,C;M<b;++M)if(F=k[M]){for(M>=S&&(S=M+1);!(C=T[S])&&++S<b;);F._next=C||null}}return s=new z(s,r),s._enter=a,s._exit=u,s}function Me(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function Se(){return new z(this._exit||this._groups.map(En),this._parents)}function $e(t,n,e){var r=this.enter(),i=this,o=this.exit();return typeof t=="function"?(r=t(r),r&&(r=r.selection())):r=r.append(t+""),n!=null&&(i=n(i),i&&(i=i.selection())),e==null?o.remove():e(o),r&&i?r.merge(i).order():i}function ze(t){for(var n=t.selection?t.selection():t,e=this._groups,r=n._groups,i=e.length,o=r.length,s=Math.min(i,o),a=new Array(i),u=0;u<s;++u)for(var c=e[u],f=r[u],p=c.length,d=a[u]=new Array(p),g,b=0;b<p;++b)(g=c[b]||f[b])&&(d[b]=g);for(;u<i;++u)a[u]=e[u];return new z(a,this._parents)}function Ce(){for(var t=this._groups,n=-1,e=t.length;++n<e;)for(var r=t[n],i=r.length-1,o=r[i],s;--i>=0;)(s=r[i])&&(o&&s.compareDocumentPosition(o)^4&&o.parentNode.insertBefore(s,o),o=s);return this}function Re(t){t||(t=Ie);function n(p,d){return p&&d?t(p.__data__,d.__data__):!p-!d}for(var e=this._groups,r=e.length,i=new Array(r),o=0;o<r;++o){for(var s=e[o],a=s.length,u=i[o]=new Array(a),c,f=0;f<a;++f)(c=s[f])&&(u[f]=c);u.sort(n)}return new z(i,this._parents).order()}function Ie(t,n){return t<n?-1:t>n?1:t>=n?0:NaN}function De(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}function Xe(){return Array.from(this)}function qe(){for(var t=this._groups,n=0,e=t.length;n<e;++n)for(var r=t[n],i=0,o=r.length;i<o;++i){var s=r[i];if(s)return s}return null}function Fe(){let t=0;for(const n of this)++t;return t}function Pe(){return!this.node()}function He(t){for(var n=this._groups,e=0,r=n.length;e<r;++e)for(var i=n[e],o=0,s=i.length,a;o<s;++o)(a=i[o])&&t.call(a,a.__data__,o,i);return this}function Oe(t){return function(){this.removeAttribute(t)}}function Ve(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Ye(t,n){return function(){this.setAttribute(t,n)}}function Le(t,n){return function(){this.setAttributeNS(t.space,t.local,n)}}function Be(t,n){return function(){var e=n.apply(this,arguments);e==null?this.removeAttribute(t):this.setAttribute(t,e)}}function Ue(t,n){return function(){var e=n.apply(this,arguments);e==null?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,e)}}function Ge(t,n){var e=$t(t);if(arguments.length<2){var r=this.node();return e.local?r.getAttributeNS(e.space,e.local):r.getAttribute(e)}return this.each((n==null?e.local?Ve:Oe:typeof n=="function"?e.local?Ue:Be:e.local?Le:Ye)(e,n))}function Tn(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function Ke(t){return function(){this.style.removeProperty(t)}}function We(t,n,e){return function(){this.style.setProperty(t,n,e)}}function Qe(t,n,e){return function(){var r=n.apply(this,arguments);r==null?this.style.removeProperty(t):this.style.setProperty(t,r,e)}}function Ze(t,n,e){return arguments.length>1?this.each((n==null?Ke:typeof n=="function"?Qe:We)(t,n,e??"")):nt(this.node(),t)}function nt(t,n){return t.style.getPropertyValue(n)||Tn(t).getComputedStyle(t,null).getPropertyValue(n)}function Je(t){return function(){delete this[t]}}function je(t,n){return function(){this[t]=n}}function tr(t,n){return function(){var e=n.apply(this,arguments);e==null?delete this[t]:this[t]=e}}function nr(t,n){return arguments.length>1?this.each((n==null?Je:typeof n=="function"?tr:je)(t,n)):this.node()[t]}function Mn(t){return t.trim().split(/^|\s+/)}function Wt(t){return t.classList||new Sn(t)}function Sn(t){this._node=t,this._names=Mn(t.getAttribute("class")||"")}Sn.prototype={add:function(t){var n=this._names.indexOf(t);n<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var n=this._names.indexOf(t);n>=0&&(this._names.splice(n,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};function $n(t,n){for(var e=Wt(t),r=-1,i=n.length;++r<i;)e.add(n[r])}function zn(t,n){for(var e=Wt(t),r=-1,i=n.length;++r<i;)e.remove(n[r])}function er(t){return function(){$n(this,t)}}function rr(t){return function(){zn(this,t)}}function ir(t,n){return function(){(n.apply(this,arguments)?$n:zn)(this,t)}}function or(t,n){var e=Mn(t+"");if(arguments.length<2){for(var r=Wt(this.node()),i=-1,o=e.length;++i<o;)if(!r.contains(e[i]))return!1;return!0}return this.each((typeof n=="function"?ir:n?er:rr)(e,n))}function sr(){this.textContent=""}function ar(t){return function(){this.textContent=t}}function ur(t){return function(){var n=t.apply(this,arguments);this.textContent=n??""}}function cr(t){return arguments.length?this.each(t==null?sr:(typeof t=="function"?ur:ar)(t)):this.node().textContent}function lr(){this.innerHTML=""}function fr(t){return function(){this.innerHTML=t}}function hr(t){return function(){var n=t.apply(this,arguments);this.innerHTML=n??""}}function pr(t){return arguments.length?this.each(t==null?lr:(typeof t=="function"?hr:fr)(t)):this.node().innerHTML}function dr(){this.nextSibling&&this.parentNode.appendChild(this)}function gr(){return this.each(dr)}function mr(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function _r(){return this.each(mr)}function yr(t){var n=typeof t=="function"?t:bn(t);return this.select(function(){return this.appendChild(n.apply(this,arguments))})}function vr(){return null}function wr(t,n){var e=typeof t=="function"?t:bn(t),r=n==null?vr:typeof n=="function"?n:Kt(n);return this.select(function(){return this.insertBefore(e.apply(this,arguments),r.apply(this,arguments)||null)})}function xr(){var t=this.parentNode;t&&t.removeChild(this)}function br(){return this.each(xr)}function Nr(){var t=this.cloneNode(!1),n=this.parentNode;return n?n.insertBefore(t,this.nextSibling):t}function kr(){var t=this.cloneNode(!0),n=this.parentNode;return n?n.insertBefore(t,this.nextSibling):t}function Ar(t){return this.select(t?kr:Nr)}function Er(t){return arguments.length?this.property("__data__",t):this.node().__data__}function Tr(t){return function(n){t.call(this,n,this.__data__)}}function Mr(t){return t.trim().split(/^|\s+/).map(function(n){var e="",r=n.indexOf(".");return r>=0&&(e=n.slice(r+1),n=n.slice(0,r)),{type:n,name:e}})}function Sr(t){return function(){var n=this.__on;if(n){for(var e=0,r=-1,i=n.length,o;e<i;++e)o=n[e],(!t.type||o.type===t.type)&&o.name===t.name?this.removeEventListener(o.type,o.listener,o.options):n[++r]=o;++r?n.length=r:delete this.__on}}}function $r(t,n,e){return function(){var r=this.__on,i,o=Tr(n);if(r){for(var s=0,a=r.length;s<a;++s)if((i=r[s]).type===t.type&&i.name===t.name){this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=o,i.options=e),i.value=n;return}}this.addEventListener(t.type,o,e),i={type:t.type,name:t.name,value:n,listener:o,options:e},r?r.push(i):this.__on=[i]}}function zr(t,n,e){var r=Mr(t+""),i,o=r.length,s;if(arguments.length<2){var a=this.node().__on;if(a){for(var u=0,c=a.length,f;u<c;++u)for(i=0,f=a[u];i<o;++i)if((s=r[i]).type===f.type&&s.name===f.name)return f.value}return}for(a=n?$r:Sr,i=0;i<o;++i)this.each(a(r[i],n,e));return this}function Cn(t,n,e){var r=Tn(t),i=r.CustomEvent;typeof i=="function"?i=new i(n,e):(i=r.document.createEvent("Event"),e?(i.initEvent(n,e.bubbles,e.cancelable),i.detail=e.detail):i.initEvent(n,!1,!1)),t.dispatchEvent(i)}function Cr(t,n){return function(){return Cn(this,t,n)}}function Rr(t,n){return function(){return Cn(this,t,n.apply(this,arguments))}}function Ir(t,n){return this.each((typeof n=="function"?Rr:Cr)(t,n))}function*Dr(){for(var t=this._groups,n=0,e=t.length;n<e;++n)for(var r=t[n],i=0,o=r.length,s;i<o;++i)(s=r[i])&&(yield s)}var Rn=[null];function z(t,n){this._groups=t,this._parents=n}function ft(){return new z([[document.documentElement]],Rn)}function Xr(){return this}z.prototype=ft.prototype={constructor:z,select:ue,selectAll:he,selectChild:me,selectChildren:we,filter:xe,data:Te,enter:be,exit:Se,join:$e,merge:ze,selection:Xr,order:Ce,sort:Re,call:De,nodes:Xe,node:qe,size:Fe,empty:Pe,each:He,attr:Ge,style:Ze,property:nr,classed:or,text:cr,html:pr,raise:gr,lower:_r,append:yr,insert:wr,remove:br,clone:Ar,datum:Er,on:zr,dispatch:Ir,[Symbol.iterator]:Dr};function Q(t){return typeof t=="string"?new z([[document.querySelector(t)]],[document.documentElement]):new z([[t]],Rn)}function qr(t){let n;for(;n=t.sourceEvent;)t=n;return t}function W(t,n){if(t=qr(t),n===void 0&&(n=t.currentTarget),n){var e=n.ownerSVGElement||n;if(e.createSVGPoint){var r=e.createSVGPoint();return r.x=t.clientX,r.y=t.clientY,r=r.matrixTransform(n.getScreenCTM().inverse()),[r.x,r.y]}if(n.getBoundingClientRect){var i=n.getBoundingClientRect();return[t.clientX-i.left-n.clientLeft,t.clientY-i.top-n.clientTop]}}return[t.pageX,t.pageY]}var Fr={value:()=>{}};function Qt(){for(var t=0,n=arguments.length,e={},r;t<n;++t){if(!(r=arguments[t]+"")||r in e||/[\s.]/.test(r))throw new Error("illegal type: "+r);e[r]=[]}return new wt(e)}function wt(t){this._=t}function Pr(t,n){return t.trim().split(/^|\s+/).map(function(e){var r="",i=e.indexOf(".");if(i>=0&&(r=e.slice(i+1),e=e.slice(0,i)),e&&!n.hasOwnProperty(e))throw new Error("unknown type: "+e);return{type:e,name:r}})}wt.prototype=Qt.prototype={constructor:wt,on:function(t,n){var e=this._,r=Pr(t+"",e),i,o=-1,s=r.length;if(arguments.length<2){for(;++o<s;)if((i=(t=r[o]).type)&&(i=Hr(e[i],t.name)))return i;return}if(n!=null&&typeof n!="function")throw new Error("invalid callback: "+n);for(;++o<s;)if(i=(t=r[o]).type)e[i]=rn(e[i],t.name,n);else if(n==null)for(i in e)e[i]=rn(e[i],t.name,null);return this},copy:function(){var t={},n=this._;for(var e in n)t[e]=n[e].slice();return new wt(t)},call:function(t,n){if((i=arguments.length-2)>0)for(var e=new Array(i),r=0,i,o;r<i;++r)e[r]=arguments[r+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(o=this._[t],r=0,i=o.length;r<i;++r)o[r].value.apply(n,e)},apply:function(t,n,e){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var r=this._[t],i=0,o=r.length;i<o;++i)r[i].value.apply(n,e)}};function Hr(t,n){for(var e=0,r=t.length,i;e<r;++e)if((i=t[e]).name===n)return i.value}function rn(t,n,e){for(var r=0,i=t.length;r<i;++r)if(t[r].name===n){t[r]=Fr,t=t.slice(0,r).concat(t.slice(r+1));break}return e!=null&&t.push({name:n,value:e}),t}const Lo={passive:!1},Ht={capture:!0,passive:!1};function Bo(t){t.stopImmediatePropagation()}function Ot(t){t.preventDefault(),t.stopImmediatePropagation()}function Or(t){var n=t.document.documentElement,e=Q(t).on("dragstart.drag",Ot,Ht);"onselectstart"in n?e.on("selectstart.drag",Ot,Ht):(n.__noselect=n.style.MozUserSelect,n.style.MozUserSelect="none")}function Vr(t,n){var e=t.document.documentElement,r=Q(t).on("dragstart.drag",null);n&&(r.on("click.drag",Ot,Ht),setTimeout(function(){r.on("click.drag",null)},0)),"onselectstart"in e?r.on("selectstart.drag",null):(e.style.MozUserSelect=e.__noselect,delete e.__noselect)}function Zt(t,n,e){t.prototype=n.prototype=e,e.constructor=t}function In(t,n){var e=Object.create(t.prototype);for(var r in n)e[r]=n[r];return e}function ht(){}var at=.7,At=1/at,tt="\\s*([+-]?\\d+)\\s*",ut="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",H="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Yr=/^#([0-9a-f]{3,8})$/,Lr=new RegExp(`^rgb\\(${tt},${tt},${tt}\\)$`),Br=new RegExp(`^rgb\\(${H},${H},${H}\\)$`),Ur=new RegExp(`^rgba\\(${tt},${tt},${tt},${ut}\\)$`),Gr=new RegExp(`^rgba\\(${H},${H},${H},${ut}\\)$`),Kr=new RegExp(`^hsl\\(${ut},${H},${H}\\)$`),Wr=new RegExp(`^hsla\\(${ut},${H},${H},${ut}\\)$`),on={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Zt(ht,ct,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:sn,formatHex:sn,formatHex8:Qr,formatHsl:Zr,formatRgb:an,toString:an});function sn(){return this.rgb().formatHex()}function Qr(){return this.rgb().formatHex8()}function Zr(){return Dn(this).formatHsl()}function an(){return this.rgb().formatRgb()}function ct(t){var n,e;return t=(t+"").trim().toLowerCase(),(n=Yr.exec(t))?(e=n[1].length,n=parseInt(n[1],16),e===6?un(n):e===3?new $(n>>8&15|n>>4&240,n>>4&15|n&240,(n&15)<<4|n&15,1):e===8?mt(n>>24&255,n>>16&255,n>>8&255,(n&255)/255):e===4?mt(n>>12&15|n>>8&240,n>>8&15|n>>4&240,n>>4&15|n&240,((n&15)<<4|n&15)/255):null):(n=Lr.exec(t))?new $(n[1],n[2],n[3],1):(n=Br.exec(t))?new $(n[1]*255/100,n[2]*255/100,n[3]*255/100,1):(n=Ur.exec(t))?mt(n[1],n[2],n[3],n[4]):(n=Gr.exec(t))?mt(n[1]*255/100,n[2]*255/100,n[3]*255/100,n[4]):(n=Kr.exec(t))?fn(n[1],n[2]/100,n[3]/100,1):(n=Wr.exec(t))?fn(n[1],n[2]/100,n[3]/100,n[4]):on.hasOwnProperty(t)?un(on[t]):t==="transparent"?new $(NaN,NaN,NaN,0):null}function un(t){return new $(t>>16&255,t>>8&255,t&255,1)}function mt(t,n,e,r){return r<=0&&(t=n=e=NaN),new $(t,n,e,r)}function Jr(t){return t instanceof ht||(t=ct(t)),t?(t=t.rgb(),new $(t.r,t.g,t.b,t.opacity)):new $}function Vt(t,n,e,r){return arguments.length===1?Jr(t):new $(t,n,e,r??1)}function $(t,n,e,r){this.r=+t,this.g=+n,this.b=+e,this.opacity=+r}Zt($,Vt,In(ht,{brighter(t){return t=t==null?At:Math.pow(At,t),new $(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=t==null?at:Math.pow(at,t),new $(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new $(J(this.r),J(this.g),J(this.b),Et(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:cn,formatHex:cn,formatHex8:jr,formatRgb:ln,toString:ln}));function cn(){return`#${Z(this.r)}${Z(this.g)}${Z(this.b)}`}function jr(){return`#${Z(this.r)}${Z(this.g)}${Z(this.b)}${Z((isNaN(this.opacity)?1:this.opacity)*255)}`}function ln(){const t=Et(this.opacity);return`${t===1?"rgb(":"rgba("}${J(this.r)}, ${J(this.g)}, ${J(this.b)}${t===1?")":`, ${t})`}`}function Et(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function J(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function Z(t){return t=J(t),(t<16?"0":"")+t.toString(16)}function fn(t,n,e,r){return r<=0?t=n=e=NaN:e<=0||e>=1?t=n=NaN:n<=0&&(t=NaN),new X(t,n,e,r)}function Dn(t){if(t instanceof X)return new X(t.h,t.s,t.l,t.opacity);if(t instanceof ht||(t=ct(t)),!t)return new X;if(t instanceof X)return t;t=t.rgb();var n=t.r/255,e=t.g/255,r=t.b/255,i=Math.min(n,e,r),o=Math.max(n,e,r),s=NaN,a=o-i,u=(o+i)/2;return a?(n===o?s=(e-r)/a+(e<r)*6:e===o?s=(r-n)/a+2:s=(n-e)/a+4,a/=u<.5?o+i:2-o-i,s*=60):a=u>0&&u<1?0:s,new X(s,a,u,t.opacity)}function ti(t,n,e,r){return arguments.length===1?Dn(t):new X(t,n,e,r??1)}function X(t,n,e,r){this.h=+t,this.s=+n,this.l=+e,this.opacity=+r}Zt(X,ti,In(ht,{brighter(t){return t=t==null?At:Math.pow(At,t),new X(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=t==null?at:Math.pow(at,t),new X(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+(this.h<0)*360,n=isNaN(t)||isNaN(this.s)?0:this.s,e=this.l,r=e+(e<.5?e:1-e)*n,i=2*e-r;return new $(Xt(t>=240?t-240:t+120,i,r),Xt(t,i,r),Xt(t<120?t+240:t-120,i,r),this.opacity)},clamp(){return new X(hn(this.h),_t(this.s),_t(this.l),Et(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const t=Et(this.opacity);return`${t===1?"hsl(":"hsla("}${hn(this.h)}, ${_t(this.s)*100}%, ${_t(this.l)*100}%${t===1?")":`, ${t})`}`}}));function hn(t){return t=(t||0)%360,t<0?t+360:t}function _t(t){return Math.max(0,Math.min(1,t||0))}function Xt(t,n,e){return(t<60?n+(e-n)*t/60:t<180?e:t<240?n+(e-n)*(240-t)/60:n)*255}const Xn=t=>()=>t;function ni(t,n){return function(e){return t+e*n}}function ei(t,n,e){return t=Math.pow(t,e),n=Math.pow(n,e)-t,e=1/e,function(r){return Math.pow(t+r*n,e)}}function ri(t){return(t=+t)==1?qn:function(n,e){return e-n?ei(n,e,t):Xn(isNaN(n)?e:n)}}function qn(t,n){var e=n-t;return e?ni(t,e):Xn(isNaN(t)?n:t)}const pn=(function t(n){var e=ri(n);function r(i,o){var s=e((i=Vt(i)).r,(o=Vt(o)).r),a=e(i.g,o.g),u=e(i.b,o.b),c=qn(i.opacity,o.opacity);return function(f){return i.r=s(f),i.g=a(f),i.b=u(f),i.opacity=c(f),i+""}}return r.gamma=t,r})(1);function K(t,n){return t=+t,n=+n,function(e){return t*(1-e)+n*e}}var Yt=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,qt=new RegExp(Yt.source,"g");function ii(t){return function(){return t}}function oi(t){return function(n){return t(n)+""}}function si(t,n){var e=Yt.lastIndex=qt.lastIndex=0,r,i,o,s=-1,a=[],u=[];for(t=t+"",n=n+"";(r=Yt.exec(t))&&(i=qt.exec(n));)(o=i.index)>e&&(o=n.slice(e,o),a[s]?a[s]+=o:a[++s]=o),(r=r[0])===(i=i[0])?a[s]?a[s]+=i:a[++s]=i:(a[++s]=null,u.push({i:s,x:K(r,i)})),e=qt.lastIndex;return e<n.length&&(o=n.slice(e),a[s]?a[s]+=o:a[++s]=o),a.length<2?u[0]?oi(u[0].x):ii(n):(n=u.length,function(c){for(var f=0,p;f<n;++f)a[(p=u[f]).i]=p.x(c);return a.join("")})}var dn=180/Math.PI,Lt={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Fn(t,n,e,r,i,o){var s,a,u;return(s=Math.sqrt(t*t+n*n))&&(t/=s,n/=s),(u=t*e+n*r)&&(e-=t*u,r-=n*u),(a=Math.sqrt(e*e+r*r))&&(e/=a,r/=a,u/=a),t*r<n*e&&(t=-t,n=-n,u=-u,s=-s),{translateX:i,translateY:o,rotate:Math.atan2(n,t)*dn,skewX:Math.atan(u)*dn,scaleX:s,scaleY:a}}var yt;function ai(t){const n=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(t+"");return n.isIdentity?Lt:Fn(n.a,n.b,n.c,n.d,n.e,n.f)}function ui(t){return t==null||(yt||(yt=document.createElementNS("http://www.w3.org/2000/svg","g")),yt.setAttribute("transform",t),!(t=yt.transform.baseVal.consolidate()))?Lt:(t=t.matrix,Fn(t.a,t.b,t.c,t.d,t.e,t.f))}function Pn(t,n,e,r){function i(c){return c.length?c.pop()+" ":""}function o(c,f,p,d,g,b){if(c!==p||f!==d){var k=g.push("translate(",null,n,null,e);b.push({i:k-4,x:K(c,p)},{i:k-2,x:K(f,d)})}else(p||d)&&g.push("translate("+p+n+d+e)}function s(c,f,p,d){c!==f?(c-f>180?f+=360:f-c>180&&(c+=360),d.push({i:p.push(i(p)+"rotate(",null,r)-2,x:K(c,f)})):f&&p.push(i(p)+"rotate("+f+r)}function a(c,f,p,d){c!==f?d.push({i:p.push(i(p)+"skewX(",null,r)-2,x:K(c,f)}):f&&p.push(i(p)+"skewX("+f+r)}function u(c,f,p,d,g,b){if(c!==p||f!==d){var k=g.push(i(g)+"scale(",null,",",null,")");b.push({i:k-4,x:K(c,p)},{i:k-2,x:K(f,d)})}else(p!==1||d!==1)&&g.push(i(g)+"scale("+p+","+d+")")}return function(c,f){var p=[],d=[];return c=t(c),f=t(f),o(c.translateX,c.translateY,f.translateX,f.translateY,p,d),s(c.rotate,f.rotate,p,d),a(c.skewX,f.skewX,p,d),u(c.scaleX,c.scaleY,f.scaleX,f.scaleY,p,d),c=f=null,function(g){for(var b=-1,k=d.length,T;++b<k;)p[(T=d[b]).i]=T.x(g);return p.join("")}}}var ci=Pn(ai,"px, ","px)","deg)"),li=Pn(ui,", ",")",")"),fi=1e-12;function gn(t){return((t=Math.exp(t))+1/t)/2}function hi(t){return((t=Math.exp(t))-1/t)/2}function pi(t){return((t=Math.exp(2*t))-1)/(t+1)}const di=(function t(n,e,r){function i(o,s){var a=o[0],u=o[1],c=o[2],f=s[0],p=s[1],d=s[2],g=f-a,b=p-u,k=g*g+b*b,T,y;if(k<fi)y=Math.log(d/c)/n,T=function(G){return[a+G*g,u+G*b,c*Math.exp(n*G*y)]};else{var M=Math.sqrt(k),S=(d*d-c*c+r*k)/(2*c*e*M),F=(d*d-c*c-r*k)/(2*d*e*M),C=Math.log(Math.sqrt(S*S+1)-S),R=Math.log(Math.sqrt(F*F+1)-F);y=(R-C)/n,T=function(G){var pt=G*y,dt=gn(C),gt=c/(e*M)*(dt*pi(n*pt+C)-hi(C));return[a+gt*g,u+gt*b,c*dt/gn(n*pt+C)]}}return T.duration=y*1e3*n/Math.SQRT2,T}return i.rho=function(o){var s=Math.max(.001,+o),a=s*s,u=a*a;return t(s,a,u)},i})(Math.SQRT2,2,4);var et=0,ot=0,rt=0,Hn=1e3,Tt,st,Mt=0,j=0,zt=0,lt=typeof performance=="object"&&performance.now?performance:Date,On=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function Jt(){return j||(On(gi),j=lt.now()+zt)}function gi(){j=0}function St(){this._call=this._time=this._next=null}St.prototype=Vn.prototype={constructor:St,restart:function(t,n,e){if(typeof t!="function")throw new TypeError("callback is not a function");e=(e==null?Jt():+e)+(n==null?0:+n),!this._next&&st!==this&&(st?st._next=this:Tt=this,st=this),this._call=t,this._time=e,Bt()},stop:function(){this._call&&(this._call=null,this._time=1/0,Bt())}};function Vn(t,n,e){var r=new St;return r.restart(t,n,e),r}function mi(){Jt(),++et;for(var t=Tt,n;t;)(n=j-t._time)>=0&&t._call.call(void 0,n),t=t._next;--et}function mn(){j=(Mt=lt.now())+zt,et=ot=0;try{mi()}finally{et=0,yi(),j=0}}function _i(){var t=lt.now(),n=t-Mt;n>Hn&&(zt-=n,Mt=t)}function yi(){for(var t,n=Tt,e,r=1/0;n;)n._call?(r>n._time&&(r=n._time),t=n,n=n._next):(e=n._next,n._next=null,n=t?t._next=e:Tt=e);st=t,Bt(r)}function Bt(t){if(!et){ot&&(ot=clearTimeout(ot));var n=t-j;n>24?(t<1/0&&(ot=setTimeout(mn,t-lt.now()-zt)),rt&&(rt=clearInterval(rt))):(rt||(Mt=lt.now(),rt=setInterval(_i,Hn)),et=1,On(mn))}}function _n(t,n,e){var r=new St;return n=n==null?0:+n,r.restart(i=>{r.stop(),t(i+n)},n,e),r}var vi=Qt("start","end","cancel","interrupt"),wi=[],Yn=0,yn=1,Ut=2,xt=3,vn=4,Gt=5,bt=6;function Ct(t,n,e,r,i,o){var s=t.__transition;if(!s)t.__transition={};else if(e in s)return;xi(t,e,{name:n,index:r,group:i,on:vi,tween:wi,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:Yn})}function jt(t,n){var e=q(t,n);if(e.state>Yn)throw new Error("too late; already scheduled");return e}function O(t,n){var e=q(t,n);if(e.state>xt)throw new Error("too late; already running");return e}function q(t,n){var e=t.__transition;if(!e||!(e=e[n]))throw new Error("transition not found");return e}function xi(t,n,e){var r=t.__transition,i;r[n]=e,e.timer=Vn(o,0,e.time);function o(c){e.state=yn,e.timer.restart(s,e.delay,e.time),e.delay<=c&&s(c-e.delay)}function s(c){var f,p,d,g;if(e.state!==yn)return u();for(f in r)if(g=r[f],g.name===e.name){if(g.state===xt)return _n(s);g.state===vn?(g.state=bt,g.timer.stop(),g.on.call("interrupt",t,t.__data__,g.index,g.group),delete r[f]):+f<n&&(g.state=bt,g.timer.stop(),g.on.call("cancel",t,t.__data__,g.index,g.group),delete r[f])}if(_n(function(){e.state===xt&&(e.state=vn,e.timer.restart(a,e.delay,e.time),a(c))}),e.state=Ut,e.on.call("start",t,t.__data__,e.index,e.group),e.state===Ut){for(e.state=xt,i=new Array(d=e.tween.length),f=0,p=-1;f<d;++f)(g=e.tween[f].value.call(t,t.__data__,e.index,e.group))&&(i[++p]=g);i.length=p+1}}function a(c){for(var f=c<e.duration?e.ease.call(null,c/e.duration):(e.timer.restart(u),e.state=Gt,1),p=-1,d=i.length;++p<d;)i[p].call(t,f);e.state===Gt&&(e.on.call("end",t,t.__data__,e.index,e.group),u())}function u(){e.state=bt,e.timer.stop(),delete r[n];for(var c in r)return;delete t.__transition}}function Nt(t,n){var e=t.__transition,r,i,o=!0,s;if(e){n=n==null?null:n+"";for(s in e){if((r=e[s]).name!==n){o=!1;continue}i=r.state>Ut&&r.state<Gt,r.state=bt,r.timer.stop(),r.on.call(i?"interrupt":"cancel",t,t.__data__,r.index,r.group),delete e[s]}o&&delete t.__transition}}function bi(t){return this.each(function(){Nt(this,t)})}function Ni(t,n){var e,r;return function(){var i=O(this,t),o=i.tween;if(o!==e){r=e=o;for(var s=0,a=r.length;s<a;++s)if(r[s].name===n){r=r.slice(),r.splice(s,1);break}}i.tween=r}}function ki(t,n,e){var r,i;if(typeof e!="function")throw new Error;return function(){var o=O(this,t),s=o.tween;if(s!==r){i=(r=s).slice();for(var a={name:n,value:e},u=0,c=i.length;u<c;++u)if(i[u].name===n){i[u]=a;break}u===c&&i.push(a)}o.tween=i}}function Ai(t,n){var e=this._id;if(t+="",arguments.length<2){for(var r=q(this.node(),e).tween,i=0,o=r.length,s;i<o;++i)if((s=r[i]).name===t)return s.value;return null}return this.each((n==null?Ni:ki)(e,t,n))}function tn(t,n,e){var r=t._id;return t.each(function(){var i=O(this,r);(i.value||(i.value={}))[n]=e.apply(this,arguments)}),function(i){return q(i,r).value[n]}}function Ln(t,n){var e;return(typeof n=="number"?K:n instanceof ct?pn:(e=ct(n))?(n=e,pn):si)(t,n)}function Ei(t){return function(){this.removeAttribute(t)}}function Ti(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Mi(t,n,e){var r,i=e+"",o;return function(){var s=this.getAttribute(t);return s===i?null:s===r?o:o=n(r=s,e)}}function Si(t,n,e){var r,i=e+"",o;return function(){var s=this.getAttributeNS(t.space,t.local);return s===i?null:s===r?o:o=n(r=s,e)}}function $i(t,n,e){var r,i,o;return function(){var s,a=e(this),u;return a==null?void this.removeAttribute(t):(s=this.getAttribute(t),u=a+"",s===u?null:s===r&&u===i?o:(i=u,o=n(r=s,a)))}}function zi(t,n,e){var r,i,o;return function(){var s,a=e(this),u;return a==null?void this.removeAttributeNS(t.space,t.local):(s=this.getAttributeNS(t.space,t.local),u=a+"",s===u?null:s===r&&u===i?o:(i=u,o=n(r=s,a)))}}function Ci(t,n){var e=$t(t),r=e==="transform"?li:Ln;return this.attrTween(t,typeof n=="function"?(e.local?zi:$i)(e,r,tn(this,"attr."+t,n)):n==null?(e.local?Ti:Ei)(e):(e.local?Si:Mi)(e,r,n))}function Ri(t,n){return function(e){this.setAttribute(t,n.call(this,e))}}function Ii(t,n){return function(e){this.setAttributeNS(t.space,t.local,n.call(this,e))}}function Di(t,n){var e,r;function i(){var o=n.apply(this,arguments);return o!==r&&(e=(r=o)&&Ii(t,o)),e}return i._value=n,i}function Xi(t,n){var e,r;function i(){var o=n.apply(this,arguments);return o!==r&&(e=(r=o)&&Ri(t,o)),e}return i._value=n,i}function qi(t,n){var e="attr."+t;if(arguments.length<2)return(e=this.tween(e))&&e._value;if(n==null)return this.tween(e,null);if(typeof n!="function")throw new Error;var r=$t(t);return this.tween(e,(r.local?Di:Xi)(r,n))}function Fi(t,n){return function(){jt(this,t).delay=+n.apply(this,arguments)}}function Pi(t,n){return n=+n,function(){jt(this,t).delay=n}}function Hi(t){var n=this._id;return arguments.length?this.each((typeof t=="function"?Fi:Pi)(n,t)):q(this.node(),n).delay}function Oi(t,n){return function(){O(this,t).duration=+n.apply(this,arguments)}}function Vi(t,n){return n=+n,function(){O(this,t).duration=n}}function Yi(t){var n=this._id;return arguments.length?this.each((typeof t=="function"?Oi:Vi)(n,t)):q(this.node(),n).duration}function Li(t,n){if(typeof n!="function")throw new Error;return function(){O(this,t).ease=n}}function Bi(t){var n=this._id;return arguments.length?this.each(Li(n,t)):q(this.node(),n).ease}function Ui(t,n){return function(){var e=n.apply(this,arguments);if(typeof e!="function")throw new Error;O(this,t).ease=e}}function Gi(t){if(typeof t!="function")throw new Error;return this.each(Ui(this._id,t))}function Ki(t){typeof t!="function"&&(t=kn(t));for(var n=this._groups,e=n.length,r=new Array(e),i=0;i<e;++i)for(var o=n[i],s=o.length,a=r[i]=[],u,c=0;c<s;++c)(u=o[c])&&t.call(u,u.__data__,c,o)&&a.push(u);return new U(r,this._parents,this._name,this._id)}function Wi(t){if(t._id!==this._id)throw new Error;for(var n=this._groups,e=t._groups,r=n.length,i=e.length,o=Math.min(r,i),s=new Array(r),a=0;a<o;++a)for(var u=n[a],c=e[a],f=u.length,p=s[a]=new Array(f),d,g=0;g<f;++g)(d=u[g]||c[g])&&(p[g]=d);for(;a<r;++a)s[a]=n[a];return new U(s,this._parents,this._name,this._id)}function Qi(t){return(t+"").trim().split(/^|\s+/).every(function(n){var e=n.indexOf(".");return e>=0&&(n=n.slice(0,e)),!n||n==="start"})}function Zi(t,n,e){var r,i,o=Qi(n)?jt:O;return function(){var s=o(this,t),a=s.on;a!==r&&(i=(r=a).copy()).on(n,e),s.on=i}}function Ji(t,n){var e=this._id;return arguments.length<2?q(this.node(),e).on.on(t):this.each(Zi(e,t,n))}function ji(t){return function(){var n=this.parentNode;for(var e in this.__transition)if(+e!==t)return;n&&n.removeChild(this)}}function to(){return this.on("end.remove",ji(this._id))}function no(t){var n=this._name,e=this._id;typeof t!="function"&&(t=Kt(t));for(var r=this._groups,i=r.length,o=new Array(i),s=0;s<i;++s)for(var a=r[s],u=a.length,c=o[s]=new Array(u),f,p,d=0;d<u;++d)(f=a[d])&&(p=t.call(f,f.__data__,d,a))&&("__data__"in f&&(p.__data__=f.__data__),c[d]=p,Ct(c[d],n,e,d,c,q(f,e)));return new U(o,this._parents,n,e)}function eo(t){var n=this._name,e=this._id;typeof t!="function"&&(t=Nn(t));for(var r=this._groups,i=r.length,o=[],s=[],a=0;a<i;++a)for(var u=r[a],c=u.length,f,p=0;p<c;++p)if(f=u[p]){for(var d=t.call(f,f.__data__,p,u),g,b=q(f,e),k=0,T=d.length;k<T;++k)(g=d[k])&&Ct(g,n,e,k,d,b);o.push(d),s.push(f)}return new U(o,s,n,e)}var ro=ft.prototype.constructor;function io(){return new ro(this._groups,this._parents)}function oo(t,n){var e,r,i;return function(){var o=nt(this,t),s=(this.style.removeProperty(t),nt(this,t));return o===s?null:o===e&&s===r?i:i=n(e=o,r=s)}}function Bn(t){return function(){this.style.removeProperty(t)}}function so(t,n,e){var r,i=e+"",o;return function(){var s=nt(this,t);return s===i?null:s===r?o:o=n(r=s,e)}}function ao(t,n,e){var r,i,o;return function(){var s=nt(this,t),a=e(this),u=a+"";return a==null&&(u=a=(this.style.removeProperty(t),nt(this,t))),s===u?null:s===r&&u===i?o:(i=u,o=n(r=s,a))}}function uo(t,n){var e,r,i,o="style."+n,s="end."+o,a;return function(){var u=O(this,t),c=u.on,f=u.value[o]==null?a||(a=Bn(n)):void 0;(c!==e||i!==f)&&(r=(e=c).copy()).on(s,i=f),u.on=r}}function co(t,n,e){var r=(t+="")=="transform"?ci:Ln;return n==null?this.styleTween(t,oo(t,r)).on("end.style."+t,Bn(t)):typeof n=="function"?this.styleTween(t,ao(t,r,tn(this,"style."+t,n))).each(uo(this._id,t)):this.styleTween(t,so(t,r,n),e).on("end.style."+t,null)}function lo(t,n,e){return function(r){this.style.setProperty(t,n.call(this,r),e)}}function fo(t,n,e){var r,i;function o(){var s=n.apply(this,arguments);return s!==i&&(r=(i=s)&&lo(t,s,e)),r}return o._value=n,o}function ho(t,n,e){var r="style."+(t+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(n==null)return this.tween(r,null);if(typeof n!="function")throw new Error;return this.tween(r,fo(t,n,e??""))}function po(t){return function(){this.textContent=t}}function go(t){return function(){var n=t(this);this.textContent=n??""}}function mo(t){return this.tween("text",typeof t=="function"?go(tn(this,"text",t)):po(t==null?"":t+""))}function _o(t){return function(n){this.textContent=t.call(this,n)}}function yo(t){var n,e;function r(){var i=t.apply(this,arguments);return i!==e&&(n=(e=i)&&_o(i)),n}return r._value=t,r}function vo(t){var n="text";if(arguments.length<1)return(n=this.tween(n))&&n._value;if(t==null)return this.tween(n,null);if(typeof t!="function")throw new Error;return this.tween(n,yo(t))}function wo(){for(var t=this._name,n=this._id,e=Un(),r=this._groups,i=r.length,o=0;o<i;++o)for(var s=r[o],a=s.length,u,c=0;c<a;++c)if(u=s[c]){var f=q(u,n);Ct(u,t,e,c,s,{time:f.time+f.delay+f.duration,delay:0,duration:f.duration,ease:f.ease})}return new U(r,this._parents,t,e)}function xo(){var t,n,e=this,r=e._id,i=e.size();return new Promise(function(o,s){var a={value:s},u={value:function(){--i===0&&o()}};e.each(function(){var c=O(this,r),f=c.on;f!==t&&(n=(t=f).copy(),n._.cancel.push(a),n._.interrupt.push(a),n._.end.push(u)),c.on=n}),i===0&&o()})}var bo=0;function U(t,n,e,r){this._groups=t,this._parents=n,this._name=e,this._id=r}function Un(){return++bo}var L=ft.prototype;U.prototype={constructor:U,select:no,selectAll:eo,selectChild:L.selectChild,selectChildren:L.selectChildren,filter:Ki,merge:Wi,selection:io,transition:wo,call:L.call,nodes:L.nodes,node:L.node,size:L.size,empty:L.empty,each:L.each,on:Ji,attr:Ci,attrTween:qi,style:co,styleTween:ho,text:mo,textTween:vo,remove:to,tween:Ai,delay:Hi,duration:Yi,ease:Bi,easeVarying:Gi,end:xo,[Symbol.iterator]:L[Symbol.iterator]};function No(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}var ko={time:null,delay:0,duration:250,ease:No};function Ao(t,n){for(var e;!(e=t.__transition)||!(e=e[n]);)if(!(t=t.parentNode))throw new Error(`transition ${n} not found`);return e}function Eo(t){var n,e;t instanceof U?(n=t._id,t=t._name):(n=Un(),(e=ko).time=Jt(),t=t==null?null:t+"");for(var r=this._groups,i=r.length,o=0;o<i;++o)for(var s=r[o],a=s.length,u,c=0;c<a;++c)(u=s[c])&&Ct(u,t,n,c,s,e||Ao(u,n));return new U(r,this._parents,t,n)}ft.prototype.interrupt=bi;ft.prototype.transition=Eo;const vt=t=>()=>t;function To(t,{sourceEvent:n,target:e,transform:r,dispatch:i}){Object.defineProperties(this,{type:{value:t,enumerable:!0,configurable:!0},sourceEvent:{value:n,enumerable:!0,configurable:!0},target:{value:e,enumerable:!0,configurable:!0},transform:{value:r,enumerable:!0,configurable:!0},_:{value:i}})}function B(t,n,e){this.k=t,this.x=n,this.y=e}B.prototype={constructor:B,scale:function(t){return t===1?this:new B(this.k*t,this.x,this.y)},translate:function(t,n){return t===0&n===0?this:new B(this.k,this.x+this.k*t,this.y+this.k*n)},apply:function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},applyX:function(t){return t*this.k+this.x},applyY:function(t){return t*this.k+this.y},invert:function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},invertX:function(t){return(t-this.x)/this.k},invertY:function(t){return(t-this.y)/this.k},rescaleX:function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},rescaleY:function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var Gn=new B(1,0,0);B.prototype;function Ft(t){t.stopImmediatePropagation()}function it(t){t.preventDefault(),t.stopImmediatePropagation()}function Mo(t){return(!t.ctrlKey||t.type==="wheel")&&!t.button}function So(){var t=this;return t instanceof SVGElement?(t=t.ownerSVGElement||t,t.hasAttribute("viewBox")?(t=t.viewBox.baseVal,[[t.x,t.y],[t.x+t.width,t.y+t.height]]):[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]):[[0,0],[t.clientWidth,t.clientHeight]]}function wn(){return this.__zoom||Gn}function $o(t){return-t.deltaY*(t.deltaMode===1?.05:t.deltaMode?1:.002)*(t.ctrlKey?10:1)}function zo(){return navigator.maxTouchPoints||"ontouchstart"in this}function Co(t,n,e){var r=t.invertX(n[0][0])-e[0][0],i=t.invertX(n[1][0])-e[1][0],o=t.invertY(n[0][1])-e[0][1],s=t.invertY(n[1][1])-e[1][1];return t.translate(i>r?(r+i)/2:Math.min(0,r)||Math.max(0,i),s>o?(o+s)/2:Math.min(0,o)||Math.max(0,s))}function Uo(){var t=Mo,n=So,e=Co,r=$o,i=zo,o=[0,1/0],s=[[-1/0,-1/0],[1/0,1/0]],a=250,u=di,c=Qt("start","zoom","end"),f,p,d,g=500,b=150,k=0,T=10;function y(l){l.property("__zoom",wn).on("wheel.zoom",pt,{passive:!1}).on("mousedown.zoom",dt).on("dblclick.zoom",gt).filter(i).on("touchstart.zoom",Kn).on("touchmove.zoom",Wn).on("touchend.zoom touchcancel.zoom",Qn).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}y.transform=function(l,m,h,_){var v=l.selection?l.selection():l;v.property("__zoom",wn),l!==v?C(l,m,h,_):v.interrupt().each(function(){R(this,arguments).event(_).start().zoom(null,typeof m=="function"?m.apply(this,arguments):m).end()})},y.scaleBy=function(l,m,h,_){y.scaleTo(l,function(){var v=this.__zoom.k,w=typeof m=="function"?m.apply(this,arguments):m;return v*w},h,_)},y.scaleTo=function(l,m,h,_){y.transform(l,function(){var v=n.apply(this,arguments),w=this.__zoom,x=h==null?F(v):typeof h=="function"?h.apply(this,arguments):h,N=w.invert(x),A=typeof m=="function"?m.apply(this,arguments):m;return e(S(M(w,A),x,N),v,s)},h,_)},y.translateBy=function(l,m,h,_){y.transform(l,function(){return e(this.__zoom.translate(typeof m=="function"?m.apply(this,arguments):m,typeof h=="function"?h.apply(this,arguments):h),n.apply(this,arguments),s)},null,_)},y.translateTo=function(l,m,h,_,v){y.transform(l,function(){var w=n.apply(this,arguments),x=this.__zoom,N=_==null?F(w):typeof _=="function"?_.apply(this,arguments):_;return e(Gn.translate(N[0],N[1]).scale(x.k).translate(typeof m=="function"?-m.apply(this,arguments):-m,typeof h=="function"?-h.apply(this,arguments):-h),w,s)},_,v)};function M(l,m){return m=Math.max(o[0],Math.min(o[1],m)),m===l.k?l:new B(m,l.x,l.y)}function S(l,m,h){var _=m[0]-h[0]*l.k,v=m[1]-h[1]*l.k;return _===l.x&&v===l.y?l:new B(l.k,_,v)}function F(l){return[(+l[0][0]+ +l[1][0])/2,(+l[0][1]+ +l[1][1])/2]}function C(l,m,h,_){l.on("start.zoom",function(){R(this,arguments).event(_).start()}).on("interrupt.zoom end.zoom",function(){R(this,arguments).event(_).end()}).tween("zoom",function(){var v=this,w=arguments,x=R(v,w).event(_),N=n.apply(v,w),A=h==null?F(N):typeof h=="function"?h.apply(v,w):h,P=Math.max(N[1][0]-N[0][0],N[1][1]-N[0][1]),E=v.__zoom,I=typeof m=="function"?m.apply(v,w):m,V=u(E.invert(A).concat(P/E.k),I.invert(A).concat(P/I.k));return function(D){if(D===1)D=I;else{var Y=V(D),Rt=P/Y[2];D=new B(Rt,A[0]-Y[0]*Rt,A[1]-Y[1]*Rt)}x.zoom(null,D)}})}function R(l,m,h){return!h&&l.__zooming||new G(l,m)}function G(l,m){this.that=l,this.args=m,this.active=0,this.sourceEvent=null,this.extent=n.apply(l,m),this.taps=0}G.prototype={event:function(l){return l&&(this.sourceEvent=l),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(l,m){return this.mouse&&l!=="mouse"&&(this.mouse[1]=m.invert(this.mouse[0])),this.touch0&&l!=="touch"&&(this.touch0[1]=m.invert(this.touch0[0])),this.touch1&&l!=="touch"&&(this.touch1[1]=m.invert(this.touch1[0])),this.that.__zoom=m,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(l){var m=Q(this.that).datum();c.call(l,this.that,new To(l,{sourceEvent:this.sourceEvent,target:y,transform:this.that.__zoom,dispatch:c}),m)}};function pt(l,...m){if(!t.apply(this,arguments))return;var h=R(this,m).event(l),_=this.__zoom,v=Math.max(o[0],Math.min(o[1],_.k*Math.pow(2,r.apply(this,arguments)))),w=W(l);if(h.wheel)(h.mouse[0][0]!==w[0]||h.mouse[0][1]!==w[1])&&(h.mouse[1]=_.invert(h.mouse[0]=w)),clearTimeout(h.wheel);else{if(_.k===v)return;h.mouse=[w,_.invert(w)],Nt(this),h.start()}it(l),h.wheel=setTimeout(x,b),h.zoom("mouse",e(S(M(_,v),h.mouse[0],h.mouse[1]),h.extent,s));function x(){h.wheel=null,h.end()}}function dt(l,...m){if(d||!t.apply(this,arguments))return;var h=l.currentTarget,_=R(this,m,!0).event(l),v=Q(l.view).on("mousemove.zoom",A,!0).on("mouseup.zoom",P,!0),w=W(l,h),x=l.clientX,N=l.clientY;Or(l.view),Ft(l),_.mouse=[w,this.__zoom.invert(w)],Nt(this),_.start();function A(E){if(it(E),!_.moved){var I=E.clientX-x,V=E.clientY-N;_.moved=I*I+V*V>k}_.event(E).zoom("mouse",e(S(_.that.__zoom,_.mouse[0]=W(E,h),_.mouse[1]),_.extent,s))}function P(E){v.on("mousemove.zoom mouseup.zoom",null),Vr(E.view,_.moved),it(E),_.event(E).end()}}function gt(l,...m){if(t.apply(this,arguments)){var h=this.__zoom,_=W(l.changedTouches?l.changedTouches[0]:l,this),v=h.invert(_),w=h.k*(l.shiftKey?.5:2),x=e(S(M(h,w),_,v),n.apply(this,m),s);it(l),a>0?Q(this).transition().duration(a).call(C,x,_,l):Q(this).call(y.transform,x,_,l)}}function Kn(l,...m){if(t.apply(this,arguments)){var h=l.touches,_=h.length,v=R(this,m,l.changedTouches.length===_).event(l),w,x,N,A;for(Ft(l),x=0;x<_;++x)N=h[x],A=W(N,this),A=[A,this.__zoom.invert(A),N.identifier],v.touch0?!v.touch1&&v.touch0[2]!==A[2]&&(v.touch1=A,v.taps=0):(v.touch0=A,w=!0,v.taps=1+!!f);f&&(f=clearTimeout(f)),w&&(v.taps<2&&(p=A[0],f=setTimeout(function(){f=null},g)),Nt(this),v.start())}}function Wn(l,...m){if(this.__zooming){var h=R(this,m).event(l),_=l.changedTouches,v=_.length,w,x,N,A;for(it(l),w=0;w<v;++w)x=_[w],N=W(x,this),h.touch0&&h.touch0[2]===x.identifier?h.touch0[0]=N:h.touch1&&h.touch1[2]===x.identifier&&(h.touch1[0]=N);if(x=h.that.__zoom,h.touch1){var P=h.touch0[0],E=h.touch0[1],I=h.touch1[0],V=h.touch1[1],D=(D=I[0]-P[0])*D+(D=I[1]-P[1])*D,Y=(Y=V[0]-E[0])*Y+(Y=V[1]-E[1])*Y;x=M(x,Math.sqrt(D/Y)),N=[(P[0]+I[0])/2,(P[1]+I[1])/2],A=[(E[0]+V[0])/2,(E[1]+V[1])/2]}else if(h.touch0)N=h.touch0[0],A=h.touch0[1];else return;h.zoom("touch",e(S(x,N,A),h.extent,s))}}function Qn(l,...m){if(this.__zooming){var h=R(this,m).event(l),_=l.changedTouches,v=_.length,w,x;for(Ft(l),d&&clearTimeout(d),d=setTimeout(function(){d=null},g),w=0;w<v;++w)x=_[w],h.touch0&&h.touch0[2]===x.identifier?delete h.touch0:h.touch1&&h.touch1[2]===x.identifier&&delete h.touch1;if(h.touch1&&!h.touch0&&(h.touch0=h.touch1,delete h.touch1),h.touch0)h.touch0[1]=this.__zoom.invert(h.touch0[0]);else if(h.end(),h.taps===2&&(x=W(x,this),Math.hypot(p[0]-x[0],p[1]-x[1])<T)){var N=Q(this).on("dblclick.zoom");N&&N.apply(this,arguments)}}}return y.wheelDelta=function(l){return arguments.length?(r=typeof l=="function"?l:vt(+l),y):r},y.filter=function(l){return arguments.length?(t=typeof l=="function"?l:vt(!!l),y):t},y.touchable=function(l){return arguments.length?(i=typeof l=="function"?l:vt(!!l),y):i},y.extent=function(l){return arguments.length?(n=typeof l=="function"?l:vt([[+l[0][0],+l[0][1]],[+l[1][0],+l[1][1]]]),y):n},y.scaleExtent=function(l){return arguments.length?(o[0]=+l[0],o[1]=+l[1],y):[o[0],o[1]]},y.translateExtent=function(l){return arguments.length?(s[0][0]=+l[0][0],s[1][0]=+l[1][0],s[0][1]=+l[0][1],s[1][1]=+l[1][1],y):[[s[0][0],s[0][1]],[s[1][0],s[1][1]]]},y.constrain=function(l){return arguments.length?(e=l,y):e},y.duration=function(l){return arguments.length?(a=+l,y):a},y.interpolate=function(l){return arguments.length?(u=l,y):u},y.on=function(){var l=c.on.apply(c,arguments);return l===c?y:l},y.clickDistance=function(l){return arguments.length?(k=(l=+l)*l,y):Math.sqrt(k)},y.tapDistance=function(l){return arguments.length?(T=+l,y):T},y}const Ro=t=>t;function Io(t,{delay:n=0,duration:e=400,easing:r=Ro}={}){const i=+getComputedStyle(t).opacity;return{delay:n,duration:e,easing:r,css:o=>`opacity: ${o*i}`}}var Do=xn('<svg class="position-absolute translate-middle-x opacity-75 start-50" width="10" height="5"><polygon points="0,0 10,0 5,5" fill="black"></polygon></svg>'),Xo=xn('<svg class="position-absolute translate-middle-x opacity-75 start-50" width="10" height="5"><polygon points="0,5 10,5 5,0" fill="black"></polygon></svg>'),qo=Zn('<div class="position-absolute bg-black bg-opacity-75 text-white py-2 rounded pe-none z-3"><!> <!></div>');function Go(t,n){let e=nn(n,"yOffset",3,0),r=nn(n,"isOnTop",3,!0);var i=qo();let o;var s=Jn(i);{var a=f=>{var p=Do();Dt(p,"",{},{bottom:"-5px"}),It(f,p)},u=f=>{var p=Xo();Dt(p,"",{},{top:"-5px"}),It(f,p)};re(s,f=>{r()?f(a):f(u,!1)})}var c=jn(s,2);ee(c,()=>n.content),te(i),ne(f=>o=Dt(i,"",o,f),[()=>({top:r()?`${n.y-5-e()}px`:`${n.y+5+e()}px`,left:`${n.x}px`,transform:r()?"translate(-50%, -100%)":"translate(-50%, 0%)","min-width":"200px"})]),ie(3,i,()=>Io,()=>({duration:300})),It(t,i)}export{Go as T,Ht as a,Or as b,Bo as c,Qt as d,Ot as e,Uo as f,Gn as i,Lo as n,W as p,Q as s,Vr as y};
@@ -0,0 +1,22 @@
1
+ import{y as it,ae as Xe,B as st,P as at,b0 as ot,A as lt,R as ut,H as ft,b1 as ct,b2 as dt,e as ht,b3 as _t,S as Ve,b4 as pt,C as gt,n as ce,b5 as vt,b6 as mt,w as $e,h as de,m as re,r as Y,i as Pe,v as me,a as fe,p as bt,b as Ce,s as xe,d as ne,g as w,l as Ne,f as yt,j as wt}from"./XfyNEFST.js";import{c as kt,s as Te,o as Et}from"./CfPWzxx9.js";import"./DsnmJJEf.js";import{p as be,i as Ge}from"./CyI3pj5p.js";import{c as Oe,g as Ue,u as Ot,e as Me,i as ze}from"./BvtU7qVU.js";import{s as ye}from"./CvUL_eGA.js";import{d as Rt}from"./B8ie1dNX.js";import{s as Ke}from"./-3L7ibXM.js";function et(r,n,a=!1){if(r.multiple){if(n==null)return;if(!at(n))return ot();for(var s of r.options)s.selected=n.includes(Ie(s));return}for(s of r.options){var o=Ie(s);if(lt(o,n)){s.selected=!0;return}}(!a||n!==void 0)&&(r.selectedIndex=-1)}function St(r){var n=new MutationObserver(()=>{et(r,r.__value)});n.observe(r,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["value"]}),st(()=>{n.disconnect()})}function qe(r,n,a=n){var s=!0;it(r,"change",o=>{var c=o?"[selected]":":checked",d;if(r.multiple)d=[].map.call(r.querySelectorAll(c),Ie);else{var g=r.querySelector(c)??r.querySelector("option:not([disabled])");d=g&&Ie(g)}a(d)}),Xe(()=>{var o=n();if(et(r,o,s),s&&o===void 0){var c=r.querySelector(":checked");c!==null&&(o=Ie(c),a(o))}r.__value=o,s=!1}),St(r)}function Ie(r){return"__value"in r?r.__value:r.value}const Ct=()=>performance.now(),pe={tick:r=>requestAnimationFrame(r),now:()=>Ct(),tasks:new Set};function tt(){const r=pe.now();pe.tasks.forEach(n=>{n.c(r)||(pe.tasks.delete(n),n.f())}),pe.tasks.size!==0&&pe.tick(tt)}function xt(r){let n;return pe.tasks.size===0&&pe.tick(tt),{promise:new Promise(a=>{pe.tasks.add(n={c:r,f:a})}),abort(){pe.tasks.delete(n)}}}function Ae(r,n){Ve(()=>{r.dispatchEvent(new CustomEvent(n))})}function Lt(r){if(r==="float")return"cssFloat";if(r==="offset")return"cssOffset";if(r.startsWith("--"))return r;const n=r.split("-");return n.length===1?n[0]:n[0]+n.slice(1).map(a=>a[0].toUpperCase()+a.slice(1)).join("")}function Ze(r){const n={},a=r.split(";");for(const s of a){const[o,c]=s.split(":");if(!o||c===void 0)break;const d=Lt(o.trim());n[d]=c.trim()}return n}const jt=r=>r;function lr(r,n,a,s){var o=(r&vt)!==0,c=(r&mt)!==0,d=o&&c,g=(r&_t)!==0,x=d?"both":o?"in":"out",l,p=n.inert,y=n.style.overflow,O,I;function A(){return Ve(()=>l??=a()(n,s?.()??{},{direction:x}))}var M={is_global:g,in(){if(n.inert=p,!o){I?.abort(),I?.reset?.();return}c||O?.abort(),Ae(n,"introstart"),O=We(n,A(),I,1,()=>{Ae(n,"introend"),O?.abort(),O=l=void 0,n.style.overflow=y})},out(se){if(!c){se?.(),l=void 0;return}n.inert=!0,Ae(n,"outrostart"),I=We(n,A(),O,0,()=>{Ae(n,"outroend"),se?.()})},stop:()=>{O?.abort(),I?.abort()}},K=ut;if((K.transitions??=[]).push(M),o&&kt){var $=g;if(!$){for(var J=K.parent;J&&(J.f&ft)!==0;)for(;(J=J.parent)&&(J.f&ct)===0;);$=!J||(J.f&dt)!==0}$&&Xe(()=>{ht(()=>M.in())})}}function We(r,n,a,s,o){var c=s===1;if(pt(n)){var d,g=!1;return gt(()=>{if(!g){var K=n({direction:c?"in":"out"});d=We(r,K,a,s,o)}}),{abort:()=>{g=!0,d?.abort()},deactivate:()=>d.deactivate(),reset:()=>d.reset(),t:()=>d.t()}}if(a?.deactivate(),!n?.duration)return o(),{abort:ce,deactivate:ce,reset:ce,t:()=>s};const{delay:x=0,css:l,tick:p,easing:y=jt}=n;var O=[];if(c&&a===void 0&&(p&&p(0,1),l)){var I=Ze(l(0,1));O.push(I,I)}var A=()=>1-s,M=r.animate(O,{duration:x,fill:"forwards"});return M.onfinish=()=>{M.cancel();var K=a?.t()??1-s;a?.abort();var $=s-K,J=n.duration*Math.abs($),se=[];if(J>0){var ge=!1;if(l)for(var he=Math.ceil(J/16.666666666666668),ee=0;ee<=he;ee+=1){var L=K+$*y(ee/he),t=Ze(l(L,1-L));se.push(t),ge||=t.overflow==="hidden"}ge&&(r.style.overflow="hidden"),A=()=>{var e=M.currentTime;return K+$*y(e/J)},p&&xt(()=>{if(M.playState!=="running")return!1;var e=A();return p(e,1-e),!0})}M=r.animate(se,{duration:J,fill:"forwards"}),M.onfinish=()=>{A=()=>s,p?.(s,1-s),o()}},{abort:()=>{M&&(M.cancel(),M.effect=null,M.onfinish=ce)},deactivate:()=>{o=ce},reset:()=>{s===0&&p?.(1,0)},t:()=>A()}}function Tt(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}var Fe={exports:{}};/* @license
2
+ Papa Parse
3
+ v5.5.3
4
+ https://github.com/mholt/PapaParse
5
+ License: MIT
6
+ */var It=Fe.exports,Ye;function At(){return Ye||(Ye=1,(function(r,n){((a,s)=>{r.exports=s()})(It,function a(){var s=typeof self<"u"?self:typeof window<"u"?window:s!==void 0?s:{},o,c=!s.document&&!!s.postMessage,d=s.IS_PAPA_WORKER||!1,g={},x=0,l={};function p(t){this._handle=null,this._finished=!1,this._completed=!1,this._halted=!1,this._input=null,this._baseIndex=0,this._partialLine="",this._rowCount=0,this._start=0,this._nextChunk=null,this.isFirstChunk=!0,this._completeResults={data:[],errors:[],meta:{}},(function(e){var i=he(e);i.chunkSize=parseInt(i.chunkSize),e.step||e.chunk||(i.chunkSize=null),this._handle=new M(i),(this._handle.streamer=this)._config=i}).call(this,t),this.parseChunk=function(e,i){var f=parseInt(this._config.skipFirstNLines)||0;if(this.isFirstChunk&&0<f){let h=this._config.newline;h||(u=this._config.quoteChar||'"',h=this._handle.guessLineEndings(e,u)),e=[...e.split(h).slice(f)].join(h)}this.isFirstChunk&&L(this._config.beforeFirstChunk)&&(u=this._config.beforeFirstChunk(e))!==void 0&&(e=u),this.isFirstChunk=!1,this._halted=!1;var f=this._partialLine+e,u=(this._partialLine="",this._handle.parse(f,this._baseIndex,!this._finished));if(!this._handle.paused()&&!this._handle.aborted()){if(e=u.meta.cursor,f=(this._finished||(this._partialLine=f.substring(e-this._baseIndex),this._baseIndex=e),u&&u.data&&(this._rowCount+=u.data.length),this._finished||this._config.preview&&this._rowCount>=this._config.preview),d)s.postMessage({results:u,workerId:l.WORKER_ID,finished:f});else if(L(this._config.chunk)&&!i){if(this._config.chunk(u,this._handle),this._handle.paused()||this._handle.aborted())return void(this._halted=!0);this._completeResults=u=void 0}return this._config.step||this._config.chunk||(this._completeResults.data=this._completeResults.data.concat(u.data),this._completeResults.errors=this._completeResults.errors.concat(u.errors),this._completeResults.meta=u.meta),this._completed||!f||!L(this._config.complete)||u&&u.meta.aborted||(this._config.complete(this._completeResults,this._input),this._completed=!0),f||u&&u.meta.paused||this._nextChunk(),u}this._halted=!0},this._sendError=function(e){L(this._config.error)?this._config.error(e):d&&this._config.error&&s.postMessage({workerId:l.WORKER_ID,error:e,finished:!1})}}function y(t){var e;(t=t||{}).chunkSize||(t.chunkSize=l.RemoteChunkSize),p.call(this,t),this._nextChunk=c?function(){this._readChunk(),this._chunkLoaded()}:function(){this._readChunk()},this.stream=function(i){this._input=i,this._nextChunk()},this._readChunk=function(){if(this._finished)this._chunkLoaded();else{if(e=new XMLHttpRequest,this._config.withCredentials&&(e.withCredentials=this._config.withCredentials),c||(e.onload=ee(this._chunkLoaded,this),e.onerror=ee(this._chunkError,this)),e.open(this._config.downloadRequestBody?"POST":"GET",this._input,!c),this._config.downloadRequestHeaders){var i,f=this._config.downloadRequestHeaders;for(i in f)e.setRequestHeader(i,f[i])}var u;this._config.chunkSize&&(u=this._start+this._config.chunkSize-1,e.setRequestHeader("Range","bytes="+this._start+"-"+u));try{e.send(this._config.downloadRequestBody)}catch(h){this._chunkError(h.message)}c&&e.status===0&&this._chunkError()}},this._chunkLoaded=function(){e.readyState===4&&(e.status<200||400<=e.status?this._chunkError():(this._start+=this._config.chunkSize||e.responseText.length,this._finished=!this._config.chunkSize||this._start>=(i=>(i=i.getResponseHeader("Content-Range"))!==null?parseInt(i.substring(i.lastIndexOf("/")+1)):-1)(e),this.parseChunk(e.responseText)))},this._chunkError=function(i){i=e.statusText||i,this._sendError(new Error(i))}}function O(t){(t=t||{}).chunkSize||(t.chunkSize=l.LocalChunkSize),p.call(this,t);var e,i,f=typeof FileReader<"u";this.stream=function(u){this._input=u,i=u.slice||u.webkitSlice||u.mozSlice,f?((e=new FileReader).onload=ee(this._chunkLoaded,this),e.onerror=ee(this._chunkError,this)):e=new FileReaderSync,this._nextChunk()},this._nextChunk=function(){this._finished||this._config.preview&&!(this._rowCount<this._config.preview)||this._readChunk()},this._readChunk=function(){var u=this._input,h=(this._config.chunkSize&&(h=Math.min(this._start+this._config.chunkSize,this._input.size),u=i.call(u,this._start,h)),e.readAsText(u,this._config.encoding));f||this._chunkLoaded({target:{result:h}})},this._chunkLoaded=function(u){this._start+=this._config.chunkSize,this._finished=!this._config.chunkSize||this._start>=this._input.size,this.parseChunk(u.target.result)},this._chunkError=function(){this._sendError(e.error)}}function I(t){var e;p.call(this,t=t||{}),this.stream=function(i){return e=i,this._nextChunk()},this._nextChunk=function(){var i,f;if(!this._finished)return i=this._config.chunkSize,e=i?(f=e.substring(0,i),e.substring(i)):(f=e,""),this._finished=!e,this.parseChunk(f)}}function A(t){p.call(this,t=t||{});var e=[],i=!0,f=!1;this.pause=function(){p.prototype.pause.apply(this,arguments),this._input.pause()},this.resume=function(){p.prototype.resume.apply(this,arguments),this._input.resume()},this.stream=function(u){this._input=u,this._input.on("data",this._streamData),this._input.on("end",this._streamEnd),this._input.on("error",this._streamError)},this._checkIsFinished=function(){f&&e.length===1&&(this._finished=!0)},this._nextChunk=function(){this._checkIsFinished(),e.length?this.parseChunk(e.shift()):i=!0},this._streamData=ee(function(u){try{e.push(typeof u=="string"?u:u.toString(this._config.encoding)),i&&(i=!1,this._checkIsFinished(),this.parseChunk(e.shift()))}catch(h){this._streamError(h)}},this),this._streamError=ee(function(u){this._streamCleanUp(),this._sendError(u)},this),this._streamEnd=ee(function(){this._streamCleanUp(),f=!0,this._streamData("")},this),this._streamCleanUp=ee(function(){this._input.removeListener("data",this._streamData),this._input.removeListener("end",this._streamEnd),this._input.removeListener("error",this._streamError)},this)}function M(t){var e,i,f,u,h=Math.pow(2,53),j=-h,D=/^\s*-?(\d+\.?|\.\d+|\d+\.\d+)([eE][-+]?\d+)?\s*$/,N=/^((\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z)))$/,b=this,F=0,v=0,X=!1,k=!1,R=[],_={data:[],errors:[],meta:{}};function H(S){return t.skipEmptyLines==="greedy"?S.join("").trim()==="":S.length===1&&S[0].length===0}function W(){if(_&&f&&(ie("Delimiter","UndetectableDelimiter","Unable to auto-detect delimiting character; defaulted to '"+l.DefaultDelimiter+"'"),f=!1),t.skipEmptyLines&&(_.data=_.data.filter(function(m){return!H(m)})),Z()){let m=function(B,Q){L(t.transformHeader)&&(B=t.transformHeader(B,Q)),R.push(B)};if(_)if(Array.isArray(_.data[0])){for(var S=0;Z()&&S<_.data.length;S++)_.data[S].forEach(m);_.data.splice(0,1)}else _.data.forEach(m)}function T(m,B){for(var Q=t.header?{}:[],P=0;P<m.length;P++){var U=P,C=m[P],C=((ae,E)=>(z=>(t.dynamicTypingFunction&&t.dynamicTyping[z]===void 0&&(t.dynamicTyping[z]=t.dynamicTypingFunction(z)),(t.dynamicTyping[z]||t.dynamicTyping)===!0))(ae)?E==="true"||E==="TRUE"||E!=="false"&&E!=="FALSE"&&((z=>{if(D.test(z)&&(z=parseFloat(z),j<z&&z<h))return 1})(E)?parseFloat(E):N.test(E)?new Date(E):E===""?null:E):E)(U=t.header?P>=R.length?"__parsed_extra":R[P]:U,C=t.transform?t.transform(C,U):C);U==="__parsed_extra"?(Q[U]=Q[U]||[],Q[U].push(C)):Q[U]=C}return t.header&&(P>R.length?ie("FieldMismatch","TooManyFields","Too many fields: expected "+R.length+" fields but parsed "+P,v+B):P<R.length&&ie("FieldMismatch","TooFewFields","Too few fields: expected "+R.length+" fields but parsed "+P,v+B)),Q}var q;_&&(t.header||t.dynamicTyping||t.transform)&&(q=1,!_.data.length||Array.isArray(_.data[0])?(_.data=_.data.map(T),q=_.data.length):_.data=T(_.data,0),t.header&&_.meta&&(_.meta.fields=R),v+=q)}function Z(){return t.header&&R.length===0}function ie(S,T,q,m){S={type:S,code:T,message:q},m!==void 0&&(S.row=m),_.errors.push(S)}L(t.step)&&(u=t.step,t.step=function(S){_=S,Z()?W():(W(),_.data.length!==0&&(F+=S.data.length,t.preview&&F>t.preview?i.abort():(_.data=_.data[0],u(_,b))))}),this.parse=function(S,T,q){var m=t.quoteChar||'"',m=(t.newline||(t.newline=this.guessLineEndings(S,m)),f=!1,t.delimiter?L(t.delimiter)&&(t.delimiter=t.delimiter(S),_.meta.delimiter=t.delimiter):((m=((B,Q,P,U,C)=>{var ae,E,z,ve;C=C||[","," ","|",";",l.RECORD_SEP,l.UNIT_SEP];for(var we=0;we<C.length;we++){for(var oe,Re=C[we],V=0,le=0,G=0,te=(z=void 0,new $({comments:U,delimiter:Re,newline:Q,preview:10}).parse(B)),_e=0;_e<te.data.length;_e++)P&&H(te.data[_e])?G++:(oe=te.data[_e].length,le+=oe,z===void 0?z=oe:0<oe&&(V+=Math.abs(oe-z),z=oe));0<te.data.length&&(le/=te.data.length-G),(E===void 0||V<=E)&&(ve===void 0||ve<le)&&1.99<le&&(E=V,ae=Re,ve=le)}return{successful:!!(t.delimiter=ae),bestDelimiter:ae}})(S,t.newline,t.skipEmptyLines,t.comments,t.delimitersToGuess)).successful?t.delimiter=m.bestDelimiter:(f=!0,t.delimiter=l.DefaultDelimiter),_.meta.delimiter=t.delimiter),he(t));return t.preview&&t.header&&m.preview++,e=S,i=new $(m),_=i.parse(e,T,q),W(),X?{meta:{paused:!0}}:_||{meta:{paused:!1}}},this.paused=function(){return X},this.pause=function(){X=!0,i.abort(),e=L(t.chunk)?"":e.substring(i.getCharIndex())},this.resume=function(){b.streamer._halted?(X=!1,b.streamer.parseChunk(e,!0)):setTimeout(b.resume,3)},this.aborted=function(){return k},this.abort=function(){k=!0,i.abort(),_.meta.aborted=!0,L(t.complete)&&t.complete(_),e=""},this.guessLineEndings=function(B,m){B=B.substring(0,1048576);var m=new RegExp(K(m)+"([^]*?)"+K(m),"gm"),q=(B=B.replace(m,"")).split("\r"),m=B.split(`
7
+ `),B=1<m.length&&m[0].length<q[0].length;if(q.length===1||B)return`
8
+ `;for(var Q=0,P=0;P<q.length;P++)q[P][0]===`
9
+ `&&Q++;return Q>=q.length/2?`\r
10
+ `:"\r"}}function K(t){return t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function $(t){var e=(t=t||{}).delimiter,i=t.newline,f=t.comments,u=t.step,h=t.preview,j=t.fastMode,D=null,N=!1,b=t.quoteChar==null?'"':t.quoteChar,F=b;if(t.escapeChar!==void 0&&(F=t.escapeChar),(typeof e!="string"||-1<l.BAD_DELIMITERS.indexOf(e))&&(e=","),f===e)throw new Error("Comment character same as delimiter");f===!0?f="#":(typeof f!="string"||-1<l.BAD_DELIMITERS.indexOf(f))&&(f=!1),i!==`
11
+ `&&i!=="\r"&&i!==`\r
12
+ `&&(i=`
13
+ `);var v=0,X=!1;this.parse=function(k,R,_){if(typeof k!="string")throw new Error("Input must be a string");var H=k.length,W=e.length,Z=i.length,ie=f.length,S=L(u),T=[],q=[],m=[],B=v=0;if(!k)return V();if(j||j!==!1&&k.indexOf(b)===-1){for(var Q=k.split(i),P=0;P<Q.length;P++){if(m=Q[P],v+=m.length,P!==Q.length-1)v+=i.length;else if(_)return V();if(!f||m.substring(0,ie)!==f){if(S){if(T=[],ve(m.split(e)),le(),X)return V()}else ve(m.split(e));if(h&&h<=P)return T=T.slice(0,h),V(!0)}}return V()}for(var U=k.indexOf(e,v),C=k.indexOf(i,v),ae=new RegExp(K(F)+K(b),"g"),E=k.indexOf(b,v);;)if(k[v]===b)for(E=v,v++;;){if((E=k.indexOf(b,E+1))===-1)return _||q.push({type:"Quotes",code:"MissingQuotes",message:"Quoted field unterminated",row:T.length,index:v}),oe();if(E===H-1)return oe(k.substring(v,E).replace(ae,b));if(b===F&&k[E+1]===F)E++;else if(b===F||E===0||k[E-1]!==F){U!==-1&&U<E+1&&(U=k.indexOf(e,E+1));var z=we((C=C!==-1&&C<E+1?k.indexOf(i,E+1):C)===-1?U:Math.min(U,C));if(k.substr(E+1+z,W)===e){m.push(k.substring(v,E).replace(ae,b)),k[v=E+1+z+W]!==b&&(E=k.indexOf(b,v)),U=k.indexOf(e,v),C=k.indexOf(i,v);break}if(z=we(C),k.substring(E+1+z,E+1+z+Z)===i){if(m.push(k.substring(v,E).replace(ae,b)),Re(E+1+z+Z),U=k.indexOf(e,v),E=k.indexOf(b,v),S&&(le(),X))return V();if(h&&T.length>=h)return V(!0);break}q.push({type:"Quotes",code:"InvalidQuotes",message:"Trailing quote on quoted field is malformed",row:T.length,index:v}),E++}}else if(f&&m.length===0&&k.substring(v,v+ie)===f){if(C===-1)return V();v=C+Z,C=k.indexOf(i,v),U=k.indexOf(e,v)}else if(U!==-1&&(U<C||C===-1))m.push(k.substring(v,U)),v=U+W,U=k.indexOf(e,v);else{if(C===-1)break;if(m.push(k.substring(v,C)),Re(C+Z),S&&(le(),X))return V();if(h&&T.length>=h)return V(!0)}return oe();function ve(G){T.push(G),B=v}function we(G){var te=0;return te=G!==-1&&(G=k.substring(E+1,G))&&G.trim()===""?G.length:te}function oe(G){return _||(G===void 0&&(G=k.substring(v)),m.push(G),v=H,ve(m),S&&le()),V()}function Re(G){v=G,ve(m),m=[],C=k.indexOf(i,v)}function V(G){if(t.header&&!R&&T.length&&!N){var te=T[0],_e=Object.create(null),De=new Set(te);let Qe=!1;for(let ke=0;ke<te.length;ke++){let ue=te[ke];if(_e[ue=L(t.transformHeader)?t.transformHeader(ue,ke):ue]){let Se,Je=_e[ue];for(;Se=ue+"_"+Je,Je++,De.has(Se););De.add(Se),te[ke]=Se,_e[ue]++,Qe=!0,(D=D===null?{}:D)[Se]=ue}else _e[ue]=1,te[ke]=ue;De.add(ue)}Qe&&console.warn("Duplicate headers found and renamed."),N=!0}return{data:T,errors:q,meta:{delimiter:e,linebreak:i,aborted:X,truncated:!!G,cursor:B+(R||0),renamedHeaders:D}}}function le(){u(V()),T=[],q=[]}},this.abort=function(){X=!0},this.getCharIndex=function(){return v}}function J(t){var e=t.data,i=g[e.workerId],f=!1;if(e.error)i.userError(e.error,e.file);else if(e.results&&e.results.data){var u={abort:function(){f=!0,se(e.workerId,{data:[],errors:[],meta:{aborted:!0}})},pause:ge,resume:ge};if(L(i.userStep)){for(var h=0;h<e.results.data.length&&(i.userStep({data:e.results.data[h],errors:e.results.errors,meta:e.results.meta},u),!f);h++);delete e.results}else L(i.userChunk)&&(i.userChunk(e.results,u,e.file),delete e.results)}e.finished&&!f&&se(e.workerId,e.results)}function se(t,e){var i=g[t];L(i.userComplete)&&i.userComplete(e),i.terminate(),delete g[t]}function ge(){throw new Error("Not implemented.")}function he(t){if(typeof t!="object"||t===null)return t;var e,i=Array.isArray(t)?[]:{};for(e in t)i[e]=he(t[e]);return i}function ee(t,e){return function(){t.apply(e,arguments)}}function L(t){return typeof t=="function"}return l.parse=function(t,e){var i=(e=e||{}).dynamicTyping||!1;if(L(i)&&(e.dynamicTypingFunction=i,i={}),e.dynamicTyping=i,e.transform=!!L(e.transform)&&e.transform,!e.worker||!l.WORKERS_SUPPORTED)return i=null,l.NODE_STREAM_INPUT,typeof t=="string"?(t=(f=>f.charCodeAt(0)!==65279?f:f.slice(1))(t),i=new(e.download?y:I)(e)):t.readable===!0&&L(t.read)&&L(t.on)?i=new A(e):(s.File&&t instanceof File||t instanceof Object)&&(i=new O(e)),i.stream(t);(i=(()=>{var f;return!!l.WORKERS_SUPPORTED&&(f=(()=>{var u=s.URL||s.webkitURL||null,h=a.toString();return l.BLOB_URL||(l.BLOB_URL=u.createObjectURL(new Blob(["var global = (function() { if (typeof self !== 'undefined') { return self; } if (typeof window !== 'undefined') { return window; } if (typeof global !== 'undefined') { return global; } return {}; })(); global.IS_PAPA_WORKER=true; ","(",h,")();"],{type:"text/javascript"})))})(),(f=new s.Worker(f)).onmessage=J,f.id=x++,g[f.id]=f)})()).userStep=e.step,i.userChunk=e.chunk,i.userComplete=e.complete,i.userError=e.error,e.step=L(e.step),e.chunk=L(e.chunk),e.complete=L(e.complete),e.error=L(e.error),delete e.worker,i.postMessage({input:t,config:e,workerId:i.id})},l.unparse=function(t,e){var i=!1,f=!0,u=",",h=`\r
14
+ `,j='"',D=j+j,N=!1,b=null,F=!1,v=((()=>{if(typeof e=="object"){if(typeof e.delimiter!="string"||l.BAD_DELIMITERS.filter(function(R){return e.delimiter.indexOf(R)!==-1}).length||(u=e.delimiter),typeof e.quotes!="boolean"&&typeof e.quotes!="function"&&!Array.isArray(e.quotes)||(i=e.quotes),typeof e.skipEmptyLines!="boolean"&&typeof e.skipEmptyLines!="string"||(N=e.skipEmptyLines),typeof e.newline=="string"&&(h=e.newline),typeof e.quoteChar=="string"&&(j=e.quoteChar),typeof e.header=="boolean"&&(f=e.header),Array.isArray(e.columns)){if(e.columns.length===0)throw new Error("Option columns is empty");b=e.columns}e.escapeChar!==void 0&&(D=e.escapeChar+j),e.escapeFormulae instanceof RegExp?F=e.escapeFormulae:typeof e.escapeFormulae=="boolean"&&e.escapeFormulae&&(F=/^[=+\-@\t\r].*$/)}})(),new RegExp(K(j),"g"));if(typeof t=="string"&&(t=JSON.parse(t)),Array.isArray(t)){if(!t.length||Array.isArray(t[0]))return X(null,t,N);if(typeof t[0]=="object")return X(b||Object.keys(t[0]),t,N)}else if(typeof t=="object")return typeof t.data=="string"&&(t.data=JSON.parse(t.data)),Array.isArray(t.data)&&(t.fields||(t.fields=t.meta&&t.meta.fields||b),t.fields||(t.fields=Array.isArray(t.data[0])?t.fields:typeof t.data[0]=="object"?Object.keys(t.data[0]):[]),Array.isArray(t.data[0])||typeof t.data[0]=="object"||(t.data=[t.data])),X(t.fields||[],t.data||[],N);throw new Error("Unable to serialize unrecognized input");function X(R,_,H){var W="",Z=(typeof R=="string"&&(R=JSON.parse(R)),typeof _=="string"&&(_=JSON.parse(_)),Array.isArray(R)&&0<R.length),ie=!Array.isArray(_[0]);if(Z&&f){for(var S=0;S<R.length;S++)0<S&&(W+=u),W+=k(R[S],S);0<_.length&&(W+=h)}for(var T=0;T<_.length;T++){var q=(Z?R:_[T]).length,m=!1,B=Z?Object.keys(_[T]).length===0:_[T].length===0;if(H&&!Z&&(m=H==="greedy"?_[T].join("").trim()==="":_[T].length===1&&_[T][0].length===0),H==="greedy"&&Z){for(var Q=[],P=0;P<q;P++){var U=ie?R[P]:P;Q.push(_[T][U])}m=Q.join("").trim()===""}if(!m){for(var C=0;C<q;C++){0<C&&!B&&(W+=u);var ae=Z&&ie?R[C]:C;W+=k(_[T][ae],C)}T<_.length-1&&(!H||0<q&&!B)&&(W+=h)}}return W}function k(R,_){var H,W;return R==null?"":R.constructor===Date?JSON.stringify(R).slice(1,25):(W=!1,F&&typeof R=="string"&&F.test(R)&&(R="'"+R,W=!0),H=R.toString().replace(v,D),(W=W||i===!0||typeof i=="function"&&i(R,_)||Array.isArray(i)&&i[_]||((Z,ie)=>{for(var S=0;S<ie.length;S++)if(-1<Z.indexOf(ie[S]))return!0;return!1})(H,l.BAD_DELIMITERS)||-1<H.indexOf(u)||H.charAt(0)===" "||H.charAt(H.length-1)===" ")?j+H+j:H)}},l.RECORD_SEP="",l.UNIT_SEP="",l.BYTE_ORDER_MARK="\uFEFF",l.BAD_DELIMITERS=["\r",`
15
+ `,'"',l.BYTE_ORDER_MARK],l.WORKERS_SUPPORTED=!c&&!!s.Worker,l.NODE_STREAM_INPUT=1,l.LocalChunkSize=10485760,l.RemoteChunkSize=5242880,l.DefaultDelimiter=",",l.Parser=$,l.ParserHandle=M,l.NetworkStreamer=y,l.FileStreamer=O,l.StringStreamer=I,l.ReadableStreamStreamer=A,s.jQuery&&((o=s.jQuery).fn.parse=function(t){var e=t.config||{},i=[];return this.each(function(h){if(!(o(this).prop("tagName").toUpperCase()==="INPUT"&&o(this).attr("type").toLowerCase()==="file"&&s.FileReader)||!this.files||this.files.length===0)return!0;for(var j=0;j<this.files.length;j++)i.push({file:this.files[j],inputElem:this,instanceConfig:o.extend({},e)})}),f(),this;function f(){if(i.length===0)L(t.complete)&&t.complete();else{var h,j,D,N,b=i[0];if(L(t.before)){var F=t.before(b.file,b.inputElem);if(typeof F=="object"){if(F.action==="abort")return h="AbortError",j=b.file,D=b.inputElem,N=F.reason,void(L(t.error)&&t.error({name:h},j,D,N));if(F.action==="skip")return void u();typeof F.config=="object"&&(b.instanceConfig=o.extend(b.instanceConfig,F.config))}else if(F==="skip")return void u()}var v=b.instanceConfig.complete;b.instanceConfig.complete=function(X){L(v)&&v(X,b.file,b.inputElem),u()},l.parse(b.file,b.instanceConfig)}}function u(){i.splice(0,1),f()}}),d&&(s.onmessage=function(t){t=t.data,l.WORKER_ID===void 0&&t&&(l.WORKER_ID=t.workerId),typeof t.input=="string"?s.postMessage({workerId:l.WORKER_ID,results:l.parse(t.input,t.config),finished:!0}):(s.File&&t.input instanceof File||t.input instanceof Object)&&(t=l.parse(t.input,t.config))&&s.postMessage({workerId:l.WORKER_ID,results:t,finished:!0})}),(y.prototype=Object.create(p.prototype)).constructor=y,(O.prototype=Object.create(p.prototype)).constructor=O,(I.prototype=Object.create(I.prototype)).constructor=I,(A.prototype=Object.create(p.prototype)).constructor=A,l})})(Fe)),Fe.exports}var Ft=At();const rt=Tt(Ft);async function Pt(){let r=Oe.PUBLIC_TEMPLE_URL+"solutions/list",n=await fetch(r,{cache:"no-store"});if(!n.ok)return alert("could not fetch "+r),[];let a=await n.json();return a.sort((s,o)=>s.name<o.name?-1:s.name>o.name?1:0),a}async function Dt(r){const n=Oe.PUBLIC_TEMPLE_URL+`solutions/get_detail/${r}`;let a=await fetch(n,{cache:"no-store"});if(!a.ok)throw alert("Could not fetch "+n),new Error("Could not fetch "+n);return await a.json()}async function ur(r,n,a,s="",o=0,c=1){const d=new URL(Oe.PUBLIC_TEMPLE_URL+"solutions/get_full_ts");d.searchParams.set("solution_name",r),d.searchParams.set("components",n.join(",")),d.searchParams.set("unit_component",s),d.searchParams.set("scenario",a),d.searchParams.set("year",o.toString()),d.searchParams.set("rolling_average_size",c.toString());const g=d.toString();let x=await fetch(g,{cache:"no-store"});if(!x.ok)throw alert("Error when fetching "+g),new Error("Error when fetching "+g);let l=await x.json();const p=Object.fromEntries(Object.entries(l).map(([y,O])=>y=="unit"||O===void 0?null:[y,nt(O)]).filter(y=>y!==null));return{unit:He(l.unit||""),components:p}}async function fr(r,n,a,s=""){let o=new URL(Oe.PUBLIC_TEMPLE_URL+"solutions/get_total");o.searchParams.set("solution_name",r),o.searchParams.set("components",n.join(",")),o.searchParams.set("scenario",a),o.searchParams.set("unit_component",s);const c=o.toString();let d=await fetch(c,{cache:"no-store"});if(!d.ok)throw alert("Error when fetching "+c),new Error("Error when fetching "+c);let g=await d.json();for(const x in g)x=="unit"||g[x]===void 0||(g[x]=Ut(Nt(g[x])));return g.unit=He(g.unit||""),g}async function cr(r,n,a){let s=await(await fetch(Oe.PUBLIC_TEMPLE_URL+`solutions/get_unit/${r}/${n}?scenario=${a}`,{cache:"no-store"})).json();return He(s)}async function dr(r,n,a,s,o,c){const d=Oe.PUBLIC_TEMPLE_URL+`solutions/get_energy_balance/${r}/${n}/${a}?scenario=${s}&year=${o}&rolling_average_size=${c}`;let g=await fetch(d,{cache:"no-store"});if(!g.ok)throw alert("Could not fetch "+d),new Error("Could not fetch "+d);let x=await g.json(),l=["shed_demand","demand","flow_conversion_input","flow_export","flow_import","flow_storage_charge","flow_storage_discharge","flow_transport_in","flow_transport_out","cost_shed_demand","flow_conversion_output","constraint_nodal_energy_balance"],p={};for(const y of l)x[y]!==void 0&&(p[y]=nt(x[y]));return p}function Nt(r){if(r.slice(0,r.indexOf(`
16
+ `)).split(",").length==2){let o=r.split(`
17
+ `),c="",d="";for(const g of o.slice(1,o.length)){if(g=="")continue;let x=g.split(",");c+=x[0]+",",d+=x[1]+","}r=c.substring(0,c.length-1)+`
18
+ `+d.substring(0,d.length-1)}return r.slice(-1)==`
19
+ `&&(r=r.slice(0,-1)),rt.parse(r,{delimiter:",",header:!0,newline:`
20
+ `})}function nt(r){return r.map(n=>{let{d:a,t:s,...o}=n;const[c,d]=s;let g=0;return a=a.map(x=>g+=x),a=a.map(x=>x*d+c),{index:o,data:a}})}function He(r){return r.slice(-1)==`
21
+ `&&(r=r.slice(0,r.length-1)),rt.parse(r,{delimiter:",",header:!0,newline:`
22
+ `})}function Ut(r){return r.data=r.data.filter(n=>Object.keys(n).some(a=>!Number.isNaN(Number(a))&&!Number.isNaN(n[a])&&Math.abs(n[a])>0)),r}const Ee=[["rgb(122, 157, 207)","rgb(8, 64, 126)","rgb(166, 190, 223)","rgb(33, 92, 175)","rgb(211, 222, 239)","rgb(77, 125, 191)"],["rgb(212, 134, 129)","rgb(150, 39, 45)","rgb(226, 174, 171)","rgb(183, 53, 45)","rgb(241, 215, 213)","rgb(197, 93, 87)"],["rgb(102, 175, 192)","rgb(0, 89, 109)","rgb(153, 202, 213)","rgb(0, 120, 148)","rgb(204, 228, 234)","rgb(51, 149, 171)"],["rgb(202, 108, 174)","rgb(140, 10, 89)","rgb(220, 158, 201)","rgb(167, 17, 122)","rgb(239, 208, 227)","rgb(183, 59, 146)"],["rgb(161, 171, 113)","rgb(54, 82, 19)","rgb(192, 199, 161)","rgb(98, 115, 19)","rgb(224, 227, 208)","rgb(129, 143, 66)"],["rgb(187, 164, 113)","rgb(112, 79, 18)","rgb(210, 194, 161)","rgb(142, 103, 19)","rgb(232, 225, 208)","rgb(165, 133, 66)"]];let Le=0,je=0;function hr(){Le=0,je=0}function Mt(){Le>=Ee.length&&(Le=0,je++,je>=Ee[0].length&&(je=0));const r=Ee[Le][je];return Le++,r}function zt(r,n=.8){return r.replace("rgb","rgba").replace(")",`, ${n})`)}function _r(){let r=[];for(let n=0;n<Ee.length;n++)for(let a=0;a<Ee[0].length;a++)r.push(Ee[a][n]);return r}function pr(r,n,a,s=[],o=!1,c="bar",d=""){if(r.length==0)return[];let g=Object.keys(r[0]).filter(p=>!isNaN(Number(p))&&!s.includes(Number(p))),x=Object.keys(n),l={};for(const p of r){let y=!1;for(let A in n)if(!n[A].includes(p[A])){y=!0;break}if(y)continue;for(let A of Object.keys(a))if(!a[A].includes(p[A])){y=!0;break}if(y)continue;let O=[];for(let A of x)O.push(p[A]);let I=O.join("_")+d;I in l||(l[I]=Object.fromEntries(g.map(A=>[A,0])));for(let A of g){let M=Number(p[A]);p[A]=="inf"&&(M=1/0),l[I][A]+=M}}if(o){let p=Object.fromEntries(g.map(y=>[y,0]));for(let y of g)for(let O in l)p[y]+=l[O][y];for(let y of g)for(let O in l)p[y]==0?l[O][y]=0:l[O][y]*=1/p[y]}return Object.entries(l).filter(([,p])=>!Object.values(p).includes(NaN)).map(([p,y])=>{let O=Mt();return{label:p,data:Object.values(y),type:c,borderColor:O,backgroundColor:zt(O)}})}function qt(r){return Array.from(new Set(r))}function gr(r){return r.map(n=>({value:n,label:n}))}function vr(r){let n={};r.forEach(s=>{Object.entries(s.data).forEach(([o,c])=>{!c||c<=0||(n[o]=(n[o]||0)+c)})});let a={};return r.forEach(s=>{Object.entries(s.data).forEach(([o,c])=>{!c||c>=0||(a[o]=(a[o]||0)-c)})}),r.map(s=>({...s,data:Object.values(Object.entries(s.data).reduce((o,[c,d])=>(d&&n[c]>0?o[c]=d/n[c]:d&&a[c]>0?o[c]=d/a[c]:o[c]=0,o),{}))}))}var Bt=de('<div class="row mb-2"><div class="col-sm-3"><label class="fw-medium fs-4"> </label></div> <div class="col-sm-9"><!></div></div>');function Be(r,n){const a=$e();var s=Bt(),o=re(s),c=re(o),d=re(c,!0);Y(c),Y(o);var g=Pe(o,2),x=re(g);Ke(x,()=>n.content,()=>a),Y(g),Y(s),me(()=>{ye(c,"for",a),Te(d,n.label)}),fe(r,s)}function Wt(r,n,a,s,o){ne(n,""),ne(a,""),ne(s,null),o()}function Kt(r,n,a){ne(n,""),a()}var Ht=de("<option> </option>"),Qt=de('<select class="form-select"></select>'),Jt=de("<option> </option>"),Gt=de('<select class="form-select"></select>'),Zt=de("<option> </option>"),Yt=de('<select class="form-select"></select>'),Xt=de("<!> <!> <!>",1);function mr(r,n){bt(n,!0);let a=be(n,"carriers",31,()=>Ce([])),s=be(n,"nodes",31,()=>Ce([])),o=be(n,"edges",31,()=>Ce([])),c=be(n,"years",31,()=>Ce([])),d=be(n,"selected_solution",15),g=be(n,"loading",15,!1),x=be(n,"disabled",3,!0),l=xe(Ce([])),p=xe(null),y=xe(""),O=xe(""),I=xe(""),A=Ne(()=>qt(w(l).map(e=>e.name.split(".")[0]))),M=Ne(()=>w(l).filter(e=>e.name.startsWith(w(y))).map(e=>e.name.split(".")[1]||null).filter(e=>e!=null)),K=Ne(()=>w(M).length==0?w(y)||null:w(O)?w(y)+"."+w(O):null);Et(async function(){ne(l,await Pt(),!0),ne(y,Ue("solution")?.split(".")[0]||"",!0),ne(O,Ue("solution")?.split(".")[1]||"",!0),ne(I,Ue("scenario")||"",!0),$()});async function $(){if(w(K)==null){d(null);return}g(!0),ne(p,await Dt(w(K)),!0),Object.keys(w(p).scenarios).length==1?(ne(I,Object.keys(w(p).scenarios)[0],!0),J()):w(I)!=""&&w(I)in w(p).scenarios?J():d(null),g(!1)}function J(){w(p)==null||w(K)==null||(d({solution_name:w(K),scenario_name:w(I),detail:w(p).scenarios[w(I)],version:w(p).version}),Ot({solution:d().solution_name,scenario:Object.keys(w(p).scenarios).length>1?d().scenario_name:null}),a(d().detail.system.set_carriers.slice()),s(d().detail.system.set_nodes),o(Object.keys(d().detail.edges)),c([...Array(d().detail.system.optimized_years).keys()].map(e=>e*d().detail.system.interval_between_years+d().detail.system.reference_year)),n.solution_selected?.(d()))}var se=Xt(),ge=yt(se);Be(ge,{label:"Solution",content:(i,f=ce)=>{var u=Qt();u.__change=[Wt,O,I,p,$],Me(u,21,()=>w(A),ze,(h,j)=>{var D=Ht(),N=re(D,!0);Y(D);var b={};me(()=>{Te(N,w(j)),b!==(b=w(j))&&(D.value=(D.__value=w(j))??"")}),fe(h,D)}),Y(u),me(()=>{ye(u,"id",f()),u.disabled=x()}),qe(u,()=>w(y),h=>ne(y,h)),fe(i,u)}});var he=Pe(ge,2);{var ee=e=>{Be(e,{label:"Subsolution",content:(f,u=ce)=>{var h=Gt();h.__change=[Kt,I,$],Me(h,21,()=>w(M),ze,(j,D)=>{var N=Jt(),b=re(N,!0);Y(N);var F={};me(()=>{Te(b,w(D)),F!==(F=w(D))&&(N.value=(N.__value=w(D))??"")}),fe(j,N)}),Y(h),me(()=>{ye(h,"id",u()),h.disabled=x()}),qe(h,()=>w(O),j=>ne(O,j)),fe(f,h)}})};Ge(he,e=>{w(M).length>0&&e(ee)})}var L=Pe(he,2);{var t=e=>{Be(e,{label:"Scenario",content:(f,u=ce)=>{var h=Yt();h.__change=J,Me(h,21,()=>Object.keys(w(p)?.scenarios||[]),ze,(j,D)=>{var N=Zt(),b=re(N,!0);Y(N);var F={};me(()=>{Te(b,w(D)),F!==(F=w(D))&&(N.value=(N.__value=w(D))??"")}),fe(j,N)}),Y(h),me(()=>{ye(h,"id",u()),h.disabled=x()}),qe(h,()=>w(I),j=>ne(I,j)),fe(f,h)}})};Ge(L,e=>{w(p)&&Object.keys(w(p).scenarios).length>1&&e(t)})}fe(r,se),wt()}Rt(["change"]);var Vt=de('<div class="z-1 position-relative"><div class="accordion" id="accordionFilters"><!></div></div>');function br(r,n){var a=Vt(),s=re(a),o=re(s);Ke(o,()=>n.children??ce),Y(s),Y(a),fe(r,a)}var $t=de('<div class="accordion-item"><h2 class="accordion-header"><button class="accordion-button" type="button" data-bs-toggle="collapse" aria-expanded="true"> </button></h2> <div class="accordion-collapse collapse show"><div class="accordion-body"><!></div></div></div>');function yr(r,n){const a=$e();var s=$t(),o=re(s),c=re(o),d=re(c,!0);Y(c),Y(o);var g=Pe(o,2),x=re(g),l=re(x);Ke(l,()=>n.children??ce),Y(x),Y(g),Y(s),me(()=>{ye(c,"data-bs-target","#collapse"+a),ye(c,"aria-controls","collapse"+a),Te(d,n.title),ye(g,"id","collapse"+a)}),fe(r,s)}export{br as F,mr as S,cr as a,yr as b,Be as c,ur as d,qt as e,fr as f,dr as g,pr as h,vr as i,qe as j,Tt as k,lr as l,_r as m,Mt as n,hr as r,gr as t};
@@ -1 +1 @@
1
- import{s as e,p as t}from"./DVIxwpxE.js";const r={get error(){return t.error},get state(){return t.state},get status(){return t.status},get url(){return t.url}};e.updated.check;const a=r;export{a as p};
1
+ import{s as e,p as t}from"./mQ-6pls1.js";const r={get error(){return t.error},get state(){return t.state},get status(){return t.status},get url(){return t.url}};e.updated.check;const a=r;export{a as p};
@@ -1 +1 @@
1
- import"./DsnmJJEf.js";import{p as k,b as y,e as _,r as u,a as c,i as R,m as f,h as U,v as S,g as t}from"./Drxlg-Xn.js";import{s as j}from"./CxYln1hn.js";import{e as q,i as w}from"./iLwl9KAB.js";import{r as z,s as p}from"./CpZHtke-.js";import{d as A}from"./CmpsC6LN.js";import{b as B}from"./DS97ykb2.js";import{p as v}from"./BbB4DTre.js";function C(m,a,i){a()(i())}var D=_('<div class="form-check form-check-inline"><input class="form-check-input" type="radio"/> <label class="form-check-label"> </label></div>'),E=_('<div role="radiogroup"></div>');function N(m,a){k(a,!0);const i=[];let l=v(a,"value",31,()=>y(a.options[0])),b=v(a,"disabled",3,!1),h=v(a,"onUpdate",3,()=>{});var s=E();q(s,21,()=>a.options,w,(g,r)=>{var o=D(),e=f(o);z(e),e.__change=[C,h,l];var n,d=U(e,2),x=f(d,!0);u(d),u(o),S(()=>{p(e,"id","radio-"+t(r).value),e.disabled=b(),n!==(n=t(r).value)&&(e.value=(e.__value=t(r).value)??""),p(d,"for","radio-"+t(r).value),j(x,t(r).label)}),B(i,[],e,()=>(t(r).value,l()),l),c(g,o)}),u(s),c(m,s),R()}A(["change"]);export{N as R};
1
+ import"./DsnmJJEf.js";import{p as k,b as y,h as _,r as u,a as c,j as R,m as f,i as U,v as j,g as t}from"./XfyNEFST.js";import{s as S}from"./CfPWzxx9.js";import{e as q,i as w}from"./BvtU7qVU.js";import{r as z,s as p}from"./CvUL_eGA.js";import{d as A}from"./B8ie1dNX.js";import{b as B}from"./Cq-WyKR3.js";import{p as v}from"./CyI3pj5p.js";function C(m,a,i){a()(i())}var D=_('<div class="form-check form-check-inline"><input class="form-check-input" type="radio"/> <label class="form-check-label"> </label></div>'),E=_('<div role="radiogroup"></div>');function N(m,a){k(a,!0);const i=[];let l=v(a,"value",31,()=>y(a.options[0])),b=v(a,"disabled",3,!1),h=v(a,"onUpdate",3,()=>{});var s=E();q(s,21,()=>a.options,w,(g,r)=>{var o=D(),e=f(o);z(e),e.__change=[C,h,l];var n,d=U(e,2),x=f(d,!0);u(d),u(o),j(()=>{p(e,"id","radio-"+t(r).value),e.disabled=b(),n!==(n=t(r).value)&&(e.value=(e.__value=t(r).value)??""),p(d,"for","radio-"+t(r).value),S(x,t(r).label)}),B(i,[],e,()=>(t(r).value,l()),l),c(g,o)}),u(s),c(m,s),R()}A(["change"]);export{N as R};
@@ -0,0 +1 @@
1
+ import"./DsnmJJEf.js";import{p as c,h as v,r as m,v as d,a as f,j as h,m as b,g as r}from"./XfyNEFST.js";import{s as g}from"./CfPWzxx9.js";import{e as x,i as j}from"./BvtU7qVU.js";import{s as D}from"./CvUL_eGA.js";import{d as w}from"./B8ie1dNX.js";import{j as I}from"./C0T7Jkdw.js";import{p as n}from"./CyI3pj5p.js";function U(l,e,o){e.onUpdate?.(o())}var k=v("<option> </option>"),q=v('<select class="form-select"></select>');function H(l,e){c(e,!0);let o=n(e,"value",15),p=n(e,"disabled",3,!1);var a=q();a.__change=[U,e,o],x(a,21,()=>e.options,j,(u,s)=>{var t=k(),_=b(t,!0);m(t);var i={};d(()=>{g(_,r(s).label),i!==(i=r(s).value)&&(t.value=(t.__value=r(s).value)??"")}),f(u,t)}),m(a),d(()=>{D(a,"id",e.formId),a.disabled=p()}),I(a,o),f(l,a),h()}w(["change"]);export{H as D};
@@ -0,0 +1,2 @@
1
+ import{a8 as I,D as U,aI as W,q as v,as as T,aJ as L,aC as C,a7 as p,a6 as m,K as _,L as P,aK as S,aL as w,E as Y,at as K,aM as Q,aN as q,aE as z,ax as G,aO as J,I as X,p as B,T as o,G as Z,R as ee,j as te,aP as y,u as ae,Q as O,aQ as ne,P as se,aR as V,e as x,aS as re,aT as oe,aU as ie,aV as le,aW as ue,aX as fe,t as ce}from"./XfyNEFST.js";import{l as de}from"./DIeogL5L.js";import{a as _e,r as M,h as g}from"./B8ie1dNX.js";import{c as he}from"./-3L7ibXM.js";const pe=["touchstart","touchmove"];function ve(e){return pe.includes(e)}let r;function ye(){r=void 0}function Ne(e){let t=null,a=v;var i;if(v){for(t=_,r===void 0&&(r=P(document.head));r!==null&&(r.nodeType!==T||r.data!==L);)r=C(r);r===null?p(!1):r=m(C(r))}v||(i=document.head.appendChild(I()));try{U(()=>e(i),W)}finally{a&&(p(!0),r=_,m(t))}}let k=!0;function Oe(e,t){var a=t==null?"":typeof t=="object"?t+"":t;a!==(e.__t??=e.nodeValue)&&(e.__t=a,e.nodeValue=a+"")}function j(e,t){return H(e,t)}function ge(e,t){S(),t.intro=t.intro??!1;const a=t.target,i=v,f=_;try{for(var n=P(a);n&&(n.nodeType!==T||n.data!==L);)n=C(n);if(!n)throw w;p(!0),m(n),Y();const s=H(e,{...t,anchor:n});if(_===null||_.nodeType!==T||_.data!==K)throw Q(),w;return p(!1),s}catch(s){if(s instanceof Error&&s.message.split(`
2
+ `).some(d=>d.startsWith("https://svelte.dev/e/")))throw s;return s!==w&&console.warn("Failed to hydrate: ",s),t.recover===!1&&q(),S(),z(a),p(!1),j(e,t)}finally{p(i),m(f),ye()}}const h=new Map;function H(e,{target:t,anchor:a,props:i={},events:f,context:n,intro:s=!0}){S();var d=new Set,E=c=>{for(var l=0;l<c.length;l++){var u=c[l];if(!d.has(u)){d.add(u);var D=ve(u);t.addEventListener(u,g,{passive:D});var N=h.get(u);N===void 0?(document.addEventListener(u,g,{passive:D}),h.set(u,1)):h.set(u,N+1)}}};E(G(_e)),M.add(E);var b=void 0,F=J(()=>{var c=a??t.appendChild(I());return X(()=>{if(n){B({});var l=o;l.c=n}f&&(i.$$events=f),v&&Z(c,null),k=s,b=e(c,i)||{},k=!0,v&&(ee.nodes_end=_),n&&te()}),()=>{for(var l of d){t.removeEventListener(l,g);var u=h.get(l);--u===0?(document.removeEventListener(l,g),h.delete(l)):h.set(l,u)}M.delete(E),c!==a&&c.parentNode?.removeChild(c)}});return R.set(b,F),b}let R=new WeakMap;function me(e,t){const a=R.get(e);return a?(R.delete(e),a(t)):Promise.resolve()}function Ee(){return O===null&&ne(),(O.ac??=new AbortController).signal}function $(e){o===null&&y(),de&&o.l!==null?A(o).m.push(e):ae(()=>{const t=x(e);if(typeof t=="function")return t})}function be(e){o===null&&y(),$(()=>()=>x(e))}function we(e,t,{bubbles:a=!1,cancelable:i=!1}={}){return new CustomEvent(e,{detail:t,bubbles:a,cancelable:i})}function Te(){const e=o;return e===null&&y(),(t,a,i)=>{const f=e.s.$$events?.[t];if(f){const n=se(f)?f.slice():[f],s=we(t,a,i);for(const d of n)d.call(e.x,s);return!s.defaultPrevented}return!0}}function Ce(e){o===null&&y(),o.l===null&&V(),A(o).b.push(e)}function Se(e){o===null&&y(),o.l===null&&V(),A(o).a.push(e)}function A(e){var t=e.l;return t.u??={a:[],b:[],m:[]}}const Me=Object.freeze(Object.defineProperty({__proto__:null,afterUpdate:Se,beforeUpdate:Ce,createEventDispatcher:Te,createRawSnippet:he,flushSync:re,getAbortSignal:Ee,getAllContexts:oe,getContext:ie,hasContext:le,hydrate:ge,mount:j,onDestroy:be,onMount:$,setContext:ue,settled:fe,tick:ce,unmount:me,untrack:x},Symbol.toStringTag,{value:"Module"}));export{Ne as a,be as b,k as c,Me as d,ge as h,j as m,$ as o,Oe as s,me as u};
@@ -1 +1 @@
1
- import{y as k,q as i,d as m,z as t,A as g,B as y,C as s}from"./Drxlg-Xn.js";const o=new Set;function C(c,f,e,r,l=r){var h=e.getAttribute("type")==="checkbox",d=c;let n=!1;if(f!==null)for(var u of f)d=d[u]??=[];d.push(e),k(e,"change",()=>{var a=e.__value;h&&(a=v(d,a,e.checked)),l(a)},()=>l(h?[]:null)),t(()=>{var a=r();if(i&&e.defaultChecked!==e.checked){n=!0;return}h?(a=a||[],e.checked=a.includes(e.__value)):e.checked=g(e.__value,a)}),y(()=>{var a=d.indexOf(e);a!==-1&&d.splice(a,1)}),o.has(d)||(o.add(d),s(()=>{d.sort((a,_)=>a.compareDocumentPosition(_)===4?-1:1),o.delete(d)})),s(()=>{if(n){var a;if(h)a=v(d,a,e.checked);else{var _=d.find(b=>b.checked);a=_?.__value}l(a)}})}function w(c,f,e=f){k(c,"change",r=>{var l=r?c.defaultChecked:c.checked;e(l)}),(i&&c.defaultChecked!==c.checked||m(f)==null)&&e(c.checked),t(()=>{var r=f();c.checked=!!r})}function v(c,f,e){for(var r=new Set,l=0;l<c.length;l+=1)c[l].checked&&r.add(c[l].__value);return e||r.delete(f),Array.from(r)}export{w as a,C as b};
1
+ import{y as k,q as i,e as m,z as t,A as g,B as y,C as s}from"./XfyNEFST.js";const o=new Set;function C(c,f,e,r,l=r){var h=e.getAttribute("type")==="checkbox",d=c;let n=!1;if(f!==null)for(var u of f)d=d[u]??=[];d.push(e),k(e,"change",()=>{var a=e.__value;h&&(a=v(d,a,e.checked)),l(a)},()=>l(h?[]:null)),t(()=>{var a=r();if(i&&e.defaultChecked!==e.checked){n=!0;return}h?(a=a||[],e.checked=a.includes(e.__value)):e.checked=g(e.__value,a)}),y(()=>{var a=d.indexOf(e);a!==-1&&d.splice(a,1)}),o.has(d)||(o.add(d),s(()=>{d.sort((a,_)=>a.compareDocumentPosition(_)===4?-1:1),o.delete(d)})),s(()=>{if(n){var a;if(h)a=v(d,a,e.checked);else{var _=d.find(b=>b.checked);a=_?.__value}l(a)}})}function w(c,f,e=f){k(c,"change",r=>{var l=r?c.defaultChecked:c.checked;e(l)}),(i&&c.defaultChecked!==c.checked||m(f)==null)&&e(c.checked),t(()=>{var r=f();c.checked=!!r})}function v(c,f,e){for(var r=new Set,l=0;l<c.length;l+=1)c[l].checked&&r.add(c[l].__value);return e||r.delete(f),Array.from(r)}export{w as a,C as b};
@@ -0,0 +1,2 @@
1
+ import{Z as g,_ as l,q as _,$ as h,a0 as p,a1 as A,a2 as m}from"./XfyNEFST.js";function v(r){var s,n,f="";if(typeof r=="string"||typeof r=="number")f+=r;else if(typeof r=="object")if(Array.isArray(r)){var e=r.length;for(s=0;s<e;s++)r[s]&&(n=v(r[s]))&&(f&&(f+=" "),f+=n)}else for(n in r)r[n]&&(f&&(f+=" "),f+=n);return f}function N(){for(var r,s,n=0,f="",e=arguments.length;n<e;n++)(r=arguments[n])&&(s=v(r))&&(f&&(f+=" "),f+=s);return f}function I(r){return typeof r=="object"?N(r):r??""}const a=[...`
2
+ \r\f \v\uFEFF`];function x(r,s,n){var f=r==null?"":""+r;if(s&&(f=f?f+" "+s:s),n){for(var e in n)if(n[e])f=f?f+" "+e:e;else if(f.length)for(var i=e.length,o=0;(o=f.indexOf(e,o))>=0;){var t=o+i;(o===0||a.includes(f[o-1]))&&(t===f.length||a.includes(f[t]))?f=(o===0?"":f.substring(0,o))+f.substring(t+1):o=t}}return f===""?null:f}function c(r,s=!1){var n=s?" !important;":";",f="";for(var e in r){var i=r[e];i!=null&&i!==""&&(f+=" "+e+": "+i+n)}return f}function O(r,s){if(s){var n="",f,e;return Array.isArray(s)?(f=s[0],e=s[1]):f=s,f&&(n+=c(f)),e&&(n+=c(e,!0)),n=n.trim(),n===""?null:n}return String(r)}const S=Symbol("is custom element"),M=Symbol("is html");function b(r){if(_){var s=!1,n=()=>{if(!s){if(s=!0,r.hasAttribute("value")){var f=r.value;u(r,"value",null),r.value=f}if(r.hasAttribute("checked")){var e=r.checked;u(r,"checked",null),r.checked=e}}};r.__on_r=n,p(n),A()}}function u(r,s,n,f){var e=E(r);_&&(e[s]=r.getAttribute(s),s==="src"||s==="srcset"||s==="href"&&r.nodeName==="LINK")||e[s]!==(e[s]=n)&&(s==="loading"&&(r[m]=n),n==null?r.removeAttribute(s):typeof n!="string"&&L(r).includes(s)?r[s]=n:r.setAttribute(s,n))}function E(r){return r.__attributes??={[S]:r.nodeName.includes("-"),[M]:r.namespaceURI===g}}var d=new Map;function L(r){var s=d.get(r.nodeName);if(s)return s;d.set(r.nodeName,s=[]);for(var n,f=r,e=Element.prototype;e!==f;){n=h(f);for(var i in n)n[i].set&&s.push(i);f=l(f)}return s}export{O as a,I as c,b as r,u as s,x as t};
@@ -0,0 +1 @@
1
+ import{D as N,q as T,E as Y,H as q,a3 as x,a4 as B,a5 as C,a6 as U,a7 as m,a8 as F,I as D,a9 as M,aa as k,ab as p,ac as z,ad as H,K as Z,ae as $,z as j,e as y,C as w,af as L,ag as G,ah as K,ai as J,g as A,Y as Q,aj as V,b as W,d as X,ak as aa,R as ea,al as ra,am as ia,an as ta,ao as na,ap as sa,aq as fa}from"./XfyNEFST.js";import{l as ua}from"./DIeogL5L.js";function ca(a,r,u=!1){T&&Y();var s=a,t=null,e=null,d=k,c=u?q:0,o=!1;const b=(_,n=!0)=>{o=!0,v(n,_)};var f=null;function I(){f!==null&&(f.lastChild.remove(),s.before(f),f=null);var _=d?t:e,n=d?e:t;_&&z(_),n&&H(n,()=>{d?e=null:t=null})}const v=(_,n)=>{if(d===(d=_))return;let E=!1;if(T){const P=x(s)===B;!!d===P&&(s=C(),U(s),m(!1),E=!0)}var g=p(),l=s;if(g&&(f=document.createDocumentFragment(),f.append(l=F())),d?t??=n&&D(()=>n(l)):e??=n&&D(()=>n(l)),g){var S=M,i=d?t:e,h=d?e:t;i&&S.skipped_effects.delete(i),h&&S.skipped_effects.add(h),S.add_callback(I)}else I();E&&m(!0)};N(()=>{o=!1,r(b),o||v(null,null)},c),T&&(s=Z)}function O(a,r){return a===r||a?.[L]===r}function va(a={},r,u,s){return $(()=>{var t,e;return j(()=>{t=e,e=[],y(()=>{a!==u(...e)&&(r(a,...e),t&&O(u(...t),a)&&r(null,...t))})}),()=>{w(()=>{e&&O(u(...e),a)&&r(null,...e)})}}),a}let R=!1;function da(a){var r=R;try{return R=!1,[a(),R]}finally{R=r}}function oa(a,r,u,s){var t=!ua||(u&ta)!==0,e=(u&ia)!==0,d=(u&sa)!==0,c=s,o=!0,b=()=>(o&&(o=!1,c=d?y(s):s),c),f;if(e){var I=L in a||fa in a;f=G(a,r)?.set??(I&&r in a?i=>a[r]=i:void 0)}var v,_=!1;e?[v,_]=da(()=>a[r]):v=a[r],v===void 0&&s!==void 0&&(v=b(),f&&(t&&K(),f(v)));var n;if(t?n=()=>{var i=a[r];return i===void 0?b():(o=!0,i)}:n=()=>{var i=a[r];return i!==void 0&&(c=void 0),i===void 0?c:i},t&&(u&J)===0)return n;if(f){var E=a.$$legacy;return(function(i,h){return arguments.length>0?((!t||!h||E||_)&&f(h?n():i),i):n()})}var g=!1,l=((u&na)!==0?Q:V)(()=>(g=!1,n()));e&&A(l);var S=ea;return(function(i,h){if(arguments.length>0){const P=h?A(l):t&&e?W(i):i;return X(l,P),g=!0,c!==void 0&&(c=P),i}return aa&&g||(S.f&ra)!==0?l.v:A(l)})}export{va as b,ca as i,oa as p};
@@ -1 +1 @@
1
- import"./DsnmJJEf.js";import{w as O,p as P,b as Q,e as w,m as i,r,h as x,l as R,g as o,v as D,a as d,i as T,x as E,c as V,f as W}from"./Drxlg-Xn.js";import{s as N}from"./CxYln1hn.js";import{p as g,i as q}from"./BbB4DTre.js";import{e as X,i as Y}from"./iLwl9KAB.js";import{s as k,r as Z}from"./CpZHtke-.js";import{d as $}from"./CmpsC6LN.js";import{b as ee}from"./DS97ykb2.js";function ae(m,e,t,_,v){o(e)?t([]):t(_.elements),v()(t())}function te(m,e,t){e()(t())}var le=w('<div class="text-muted">No elements available to select.</div>'),se=w('<div class="form-check form-check-inline"><input class="form-check-input" type="checkbox"/> <label class="form-check-label"> </label></div>'),ie=w('<div class="row mb-2"><div class="col-sm-3 d-flex justify-content-between"><label class="form-label fw-medium fs-4"> </label> <div><button class="btn btn-outline-primary btn-sm align-self-baseline px-3"><!></button></div></div> <div class="col-sm-9 form-group"><!></div></div>');function _e(m,e){const t=O();P(e,!0);const _=[];let v=g(e,"value",31,()=>Q(e.elements)),y=g(e,"disabled",3,!1),A=g(e,"onUpdate",3,()=>{}),C=R(()=>v().length==e.elements.length);var b=ie(),u=i(b),n=i(u),z=i(n,!0);r(n);var S=x(n,2),f=i(S);f.__click=[ae,C,v,e,A];var B=i(f);{var F=a=>{var l=E("Deselect all");d(a,l)},G=a=>{var l=E("Select all");d(a,l)};q(B,a=>{o(C)?a(F):a(G,!1)})}r(f),r(S),r(u);var U=x(u,2),H=i(U);{var I=a=>{var l=le();d(a,l)},J=a=>{var l=V(),K=W(l);X(K,17,()=>e.elements,Y,(L,c)=>{var h=se(),s=i(h);Z(s),s.__change=[te,A,v];var j,p=x(s,2),M=i(p,!0);r(p),r(h),D(()=>{k(s,"id",`${o(c)}Checkbox${t}`),s.disabled=y(),j!==(j=o(c))&&(s.value=(s.__value=o(c))??""),k(p,"for",`${o(c)}Checkbox${t}`),N(M,o(c))}),ee(_,[],s,()=>(o(c),v()),v),d(L,h)}),d(a,l)};q(H,a=>{e.elements.length==0?a(I):a(J,!1)})}r(U),r(b),D(()=>{k(n,"for","checkbox"+t),N(z,e.label),f.disabled=y()}),d(m,b),T()}$(["click","change"]);export{_e as A};
1
+ import"./DsnmJJEf.js";import{w as O,p as P,b as Q,h as w,m as i,r,i as x,l as R,g as o,v as D,a as d,j as T,x as E,c as V,f as W}from"./XfyNEFST.js";import{s as N}from"./CfPWzxx9.js";import{p as g,i as q}from"./CyI3pj5p.js";import{e as X,i as Y}from"./BvtU7qVU.js";import{s as k,r as Z}from"./CvUL_eGA.js";import{d as $}from"./B8ie1dNX.js";import{b as ee}from"./Cq-WyKR3.js";function ae(m,e,t,_,v){o(e)?t([]):t(_.elements),v()(t())}function te(m,e,t){e()(t())}var le=w('<div class="text-muted">No elements available to select.</div>'),se=w('<div class="form-check form-check-inline"><input class="form-check-input" type="checkbox"/> <label class="form-check-label"> </label></div>'),ie=w('<div class="row mb-2"><div class="col-sm-3 d-flex justify-content-between"><label class="form-label fw-medium fs-4"> </label> <div><button class="btn btn-outline-primary btn-sm align-self-baseline px-3"><!></button></div></div> <div class="col-sm-9 form-group"><!></div></div>');function _e(m,e){const t=O();P(e,!0);const _=[];let v=g(e,"value",31,()=>Q(e.elements)),y=g(e,"disabled",3,!1),A=g(e,"onUpdate",3,()=>{}),C=R(()=>v().length==e.elements.length);var b=ie(),u=i(b),n=i(u),z=i(n,!0);r(n);var j=x(n,2),f=i(j);f.__click=[ae,C,v,e,A];var B=i(f);{var F=a=>{var l=E("Deselect all");d(a,l)},G=a=>{var l=E("Select all");d(a,l)};q(B,a=>{o(C)?a(F):a(G,!1)})}r(f),r(j),r(u);var S=x(u,2),H=i(S);{var I=a=>{var l=le();d(a,l)},J=a=>{var l=V(),K=W(l);X(K,17,()=>e.elements,Y,(L,c)=>{var h=se(),s=i(h);Z(s),s.__change=[te,A,v];var U,p=x(s,2),M=i(p,!0);r(p),r(h),D(()=>{k(s,"id",`${o(c)}Checkbox${t}`),s.disabled=y(),U!==(U=o(c))&&(s.value=(s.__value=o(c))??""),k(p,"for",`${o(c)}Checkbox${t}`),N(M,o(c))}),ee(_,[],s,()=>(o(c),v()),v),d(L,h)}),d(a,l)};q(H,a=>{e.elements.length==0?a(I):a(J,!1)})}r(S),r(b),D(()=>{k(n,"for","checkbox"+t),N(z,e.label),f.disabled=y()}),d(m,b),T()}$(["click","change"]);export{_e as A};
@@ -0,0 +1 @@
1
+ import"./DsnmJJEf.js";import{w as p,p as d,h,m,i as u,r as c,v,a as _,j as b}from"./XfyNEFST.js";import{s as g}from"./CfPWzxx9.js";import{r as x,s as l}from"./CvUL_eGA.js";import{d as k}from"./B8ie1dNX.js";import{a as w}from"./Cq-WyKR3.js";import{p as f}from"./CyI3pj5p.js";function I(o,t){t.onUpdate?.()}var T=h('<div class="form-check form-switch"><input class="form-check-input" type="checkbox" role="switch"/> <label class="form-check-label"> </label></div>');function A(o,t){p(),d(t,!0);let s=f(t,"value",15),i=f(t,"texts",19,()=>["on","off"]);var a=T(),e=m(a);x(e),e.__change=[I,t];var r=u(e,2),n=m(r,!0);c(r),c(a),v(()=>{l(e,"id",t.formId),l(r,"for",t.formId),g(n,s()?i()[0]:i()[1])}),w(e,s),_(o,a),b()}k(["change"]);export{A as T};