blue-chestnut-solar-expert 0.0.54 → 0.0.56

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 (380) hide show
  1. package/dist/cjs/app-globals-I24yU8do.js +10 -0
  2. package/dist/cjs/app-globals-I24yU8do.js.map +1 -0
  3. package/dist/cjs/basedecoder-CQuzfSgz.js +116 -0
  4. package/dist/cjs/basedecoder-CQuzfSgz.js.map +1 -0
  5. package/dist/cjs/deflate-AzGzQSW2.js +17 -0
  6. package/dist/cjs/deflate-AzGzQSW2.js.map +1 -0
  7. package/dist/cjs/eraser-icon_18.cjs.entry.js +30 -0
  8. package/dist/cjs/eraser-icon_18.cjs.entry.js.map +1 -0
  9. package/dist/cjs/index-HgRXF6kp.js +1470 -0
  10. package/dist/cjs/index-HgRXF6kp.js.map +1 -0
  11. package/dist/cjs/index.cjs.js +7 -0
  12. package/dist/cjs/index.cjs.js.map +1 -0
  13. package/dist/cjs/jpeg-Bx3bTm32.js +904 -0
  14. package/dist/cjs/jpeg-Bx3bTm32.js.map +1 -0
  15. package/dist/cjs/lerc-BC1SKbTC.js +4427 -0
  16. package/dist/cjs/lerc-BC1SKbTC.js.map +1 -0
  17. package/dist/cjs/loader.cjs.js +18 -0
  18. package/dist/cjs/loader.cjs.js.map +1 -0
  19. package/dist/cjs/loading-widget.cjs.entry.js +22 -0
  20. package/dist/cjs/loading-widget.cjs.entry.js.map +1 -0
  21. package/dist/cjs/loading-widget.entry.cjs.js.map +1 -0
  22. package/dist/cjs/lzw-BmFug486.js +140 -0
  23. package/dist/cjs/lzw-BmFug486.js.map +1 -0
  24. package/dist/cjs/packbits-CYx9fB0v.js +35 -0
  25. package/dist/cjs/packbits-CYx9fB0v.js.map +1 -0
  26. package/dist/cjs/pako.esm-0mKI6Jik.js +3243 -0
  27. package/dist/cjs/pako.esm-0mKI6Jik.js.map +1 -0
  28. package/dist/cjs/raw-DC82yoyr.js +16 -0
  29. package/dist/cjs/raw-DC82yoyr.js.map +1 -0
  30. package/dist/cjs/stencil-library.cjs.js +30 -0
  31. package/dist/cjs/stencil-library.cjs.js.map +1 -0
  32. package/dist/cjs/webimage-Dc0t2xAB.js +49 -0
  33. package/dist/cjs/webimage-Dc0t2xAB.js.map +1 -0
  34. package/dist/collection/build/assets/tutorial1.mp4 +0 -0
  35. package/dist/collection/build/assets/tutorial2.mp4 +0 -0
  36. package/dist/collection/build/assets/tutorial3.mp4 +0 -0
  37. package/dist/collection/collection-manifest.json +30 -0
  38. package/dist/collection/components/icons/eraser.js +64 -0
  39. package/dist/collection/components/icons/eraser.js.map +1 -0
  40. package/dist/collection/components/icons/house.js +64 -0
  41. package/dist/collection/components/icons/house.js.map +1 -0
  42. package/dist/collection/components/icons/icon.js +108 -0
  43. package/dist/collection/components/icons/icon.js.map +1 -0
  44. package/dist/collection/components/icons/marker.js +64 -0
  45. package/dist/collection/components/icons/marker.js.map +1 -0
  46. package/dist/collection/components/icons/move.js +64 -0
  47. package/dist/collection/components/icons/move.js.map +1 -0
  48. package/dist/collection/components/icons/octagonMinus.js +64 -0
  49. package/dist/collection/components/icons/octagonMinus.js.map +1 -0
  50. package/dist/collection/components/icons/search.js +64 -0
  51. package/dist/collection/components/icons/search.js.map +1 -0
  52. package/dist/collection/components/icons/settings.js +64 -0
  53. package/dist/collection/components/icons/settings.js.map +1 -0
  54. package/dist/collection/components/icons/undo.js +64 -0
  55. package/dist/collection/components/icons/undo.js.map +1 -0
  56. package/dist/collection/components/map-draw/map-draw.js +797 -0
  57. package/dist/collection/components/map-draw/map-draw.js.map +1 -0
  58. package/dist/collection/components/map-draw/map-selector.js +246 -0
  59. package/dist/collection/components/map-draw/map-selector.js.map +1 -0
  60. package/dist/collection/components/map-draw/polygon-buttons.js +86 -0
  61. package/dist/collection/components/map-draw/polygon-buttons.js.map +1 -0
  62. package/dist/collection/components/map-draw/polygon-information.js +204 -0
  63. package/dist/collection/components/map-draw/polygon-information.js.map +1 -0
  64. package/dist/collection/components/map-draw/tool-box.js +108 -0
  65. package/dist/collection/components/map-draw/tool-box.js.map +1 -0
  66. package/dist/collection/components/map-draw/tutorial-component.js +118 -0
  67. package/dist/collection/components/map-draw/tutorial-component.js.map +1 -0
  68. package/dist/collection/components/settings/settings.js +127 -0
  69. package/dist/collection/components/settings/settings.js.map +1 -0
  70. package/dist/collection/components/solar-expert/solar-expert.js +239 -0
  71. package/dist/collection/components/solar-expert/solar-expert.js.map +1 -0
  72. package/dist/collection/components/solar-system-form/solar-system-form.js +573 -0
  73. package/dist/collection/components/solar-system-form/solar-system-form.js.map +1 -0
  74. package/dist/collection/components/widgets/loading-widget.js +18 -0
  75. package/dist/collection/components/widgets/loading-widget.js.map +1 -0
  76. package/dist/{stencil-library/config-CWfV1nKn.js → collection/config.js} +4 -10
  77. package/dist/collection/config.js.map +1 -0
  78. package/dist/collection/constants.js +90 -0
  79. package/dist/collection/constants.js.map +1 -0
  80. package/dist/collection/index.js +2 -0
  81. package/dist/collection/index.js.map +1 -0
  82. package/dist/collection/output.css +1175 -0
  83. package/dist/collection/store.js +43 -0
  84. package/dist/collection/store.js.map +1 -0
  85. package/dist/collection/types/lang.js +2 -0
  86. package/dist/collection/types/lang.js.map +1 -0
  87. package/dist/collection/types/shapes.js +2 -0
  88. package/dist/collection/types/shapes.js.map +1 -0
  89. package/dist/{stencil-library/api-Did5lAE0.js → collection/utils/api.js} +27 -32
  90. package/dist/collection/utils/api.js.map +1 -0
  91. package/dist/collection/utils/images.js +2 -0
  92. package/dist/collection/utils/images.js.map +1 -0
  93. package/dist/collection/utils/lang/english.js +150 -0
  94. package/dist/collection/utils/lang/english.js.map +1 -0
  95. package/dist/collection/utils/lang/general.js +30 -0
  96. package/dist/collection/utils/lang/general.js.map +1 -0
  97. package/dist/collection/utils/lang/german.js +150 -0
  98. package/dist/collection/utils/lang/german.js.map +1 -0
  99. package/dist/collection/utils/lang/spanish.js +150 -0
  100. package/dist/collection/utils/lang/spanish.js.map +1 -0
  101. package/dist/{stencil-library/tools-BCET7NeO.js → collection/utils/render/tools.js} +10 -15
  102. package/dist/collection/utils/render/tools.js.map +1 -0
  103. package/dist/collection/utils/solar.js +135 -0
  104. package/dist/collection/utils/solar.js.map +1 -0
  105. package/dist/collection/utils/theme.js +97 -0
  106. package/dist/collection/utils/theme.js.map +1 -0
  107. package/dist/{stencil-library/utils-BCUZxI9u.js → collection/utils/utils.js} +3 -9
  108. package/dist/collection/utils/utils.js.map +1 -0
  109. package/dist/components/eraser-icon.js +11 -0
  110. package/dist/components/eraser-icon.js.map +1 -0
  111. package/dist/components/house-icon.js +11 -0
  112. package/dist/components/house-icon.js.map +1 -0
  113. package/dist/components/icon-selector.js +11 -0
  114. package/dist/components/icon-selector.js.map +1 -0
  115. package/dist/components/index.js +1269 -0
  116. package/dist/components/index.js.map +1 -0
  117. package/dist/components/loading-widget.js +38 -0
  118. package/dist/components/loading-widget.js.map +1 -0
  119. package/dist/components/map-draw.js +11 -0
  120. package/dist/components/map-draw.js.map +1 -0
  121. package/dist/components/map-selector.js +11 -0
  122. package/dist/components/map-selector.js.map +1 -0
  123. package/dist/components/{solar-calculator.d.ts → marker-icon.d.ts} +4 -4
  124. package/dist/components/marker-icon.js +11 -0
  125. package/dist/components/marker-icon.js.map +1 -0
  126. package/dist/components/move-icon.js +11 -0
  127. package/dist/components/move-icon.js.map +1 -0
  128. package/dist/components/octagon-minus-icon.js +11 -0
  129. package/dist/components/octagon-minus-icon.js.map +1 -0
  130. package/dist/components/p-B54Ul0nf.js +15 -0
  131. package/dist/components/p-B54Ul0nf.js.map +1 -0
  132. package/dist/components/p-B5WTRCh8.js +3241 -0
  133. package/dist/components/p-B5WTRCh8.js.map +1 -0
  134. package/dist/components/p-B7UJpRdF.js +40 -0
  135. package/dist/components/p-B7UJpRdF.js.map +1 -0
  136. package/dist/components/p-BELtn8mh.js +40 -0
  137. package/dist/components/p-BELtn8mh.js.map +1 -0
  138. package/dist/components/p-BFxdD9Vs.js +40 -0
  139. package/dist/components/p-BFxdD9Vs.js.map +1 -0
  140. package/dist/{stencil-library/jpeg-CjOJHUd1.js → components/p-BGoSj_DR.js} +3 -11
  141. package/dist/components/p-BGoSj_DR.js.map +1 -0
  142. package/dist/components/p-BXbeMtbx.js +76 -0
  143. package/dist/components/p-BXbeMtbx.js.map +1 -0
  144. package/dist/components/p-BYE5N70N.js +163 -0
  145. package/dist/components/p-BYE5N70N.js.map +1 -0
  146. package/dist/components/p-BnTinS5t.js +40 -0
  147. package/dist/components/p-BnTinS5t.js.map +1 -0
  148. package/dist/components/p-BsLLB46f.js +114 -0
  149. package/dist/components/p-BsLLB46f.js.map +1 -0
  150. package/dist/{stencil-library/packbits-BMYGgS0z.js → components/p-ByX6QP-E.js} +3 -9
  151. package/dist/components/p-ByX6QP-E.js.map +1 -0
  152. package/dist/{stencil-library/lerc-BQF80JgE.js → components/p-CH_OwRlu.js} +1981 -27
  153. package/dist/components/p-CH_OwRlu.js.map +1 -0
  154. package/dist/components/p-CO7fYxHj.js +40 -0
  155. package/dist/components/p-CO7fYxHj.js.map +1 -0
  156. package/dist/{stencil-library/store-4trH9erz.js → components/p-CRQ8cKpY.js} +72 -9
  157. package/dist/components/p-CRQ8cKpY.js.map +1 -0
  158. package/dist/components/p-CZydnQHs.js +114 -0
  159. package/dist/components/p-CZydnQHs.js.map +1 -0
  160. package/dist/components/p-CcItlhA2.js +60 -0
  161. package/dist/components/p-CcItlhA2.js.map +1 -0
  162. package/dist/{stencil-library/webimage-V5ihYILu.js → components/p-Cgchl6bA.js} +3 -9
  163. package/dist/components/p-Cgchl6bA.js.map +1 -0
  164. package/dist/components/p-DJcc5dax.js +1959 -0
  165. package/dist/components/p-DJcc5dax.js.map +1 -0
  166. package/dist/components/p-Dcu7-bdb.js +623 -0
  167. package/dist/components/p-Dcu7-bdb.js.map +1 -0
  168. package/dist/components/p-DotCjbjt.js +40 -0
  169. package/dist/components/p-DotCjbjt.js.map +1 -0
  170. package/dist/components/p-Dqekrz_n.js +40 -0
  171. package/dist/components/p-Dqekrz_n.js.map +1 -0
  172. package/dist/components/p-DvYICeab.js +40 -0
  173. package/dist/components/p-DvYICeab.js.map +1 -0
  174. package/dist/components/p-Dvlk0vkV.js +47 -0
  175. package/dist/components/p-Dvlk0vkV.js.map +1 -0
  176. package/dist/components/p-N0461-xw.js +15944 -0
  177. package/dist/components/p-N0461-xw.js.map +1 -0
  178. package/dist/components/p-WmcSqXD8.js +14 -0
  179. package/dist/components/p-WmcSqXD8.js.map +1 -0
  180. package/dist/components/p-j-vOrhhh.js +114 -0
  181. package/dist/components/p-j-vOrhhh.js.map +1 -0
  182. package/dist/{stencil-library/lzw-PA2aOuVK.js → components/p-q8auDIJ2.js} +4 -10
  183. package/dist/components/p-q8auDIJ2.js.map +1 -0
  184. package/dist/components/polygon-buttons.js +11 -0
  185. package/dist/components/polygon-buttons.js.map +1 -0
  186. package/dist/components/polygon-information.js +11 -0
  187. package/dist/components/polygon-information.js.map +1 -0
  188. package/dist/components/search-icon.js +11 -0
  189. package/dist/components/search-icon.js.map +1 -0
  190. package/dist/components/settings-icon.js +11 -0
  191. package/dist/components/settings-icon.js.map +1 -0
  192. package/dist/components/settings-modal.js +11 -0
  193. package/dist/components/settings-modal.js.map +1 -0
  194. package/dist/components/solar-expert.js +373 -0
  195. package/dist/components/solar-expert.js.map +1 -0
  196. package/dist/components/solar-system-form.js +11 -0
  197. package/dist/components/solar-system-form.js.map +1 -0
  198. package/dist/components/tool-box.js +11 -0
  199. package/dist/components/tool-box.js.map +1 -0
  200. package/dist/components/tutorial-component.d.ts +11 -0
  201. package/dist/components/tutorial-component.js +11 -0
  202. package/dist/components/tutorial-component.js.map +1 -0
  203. package/dist/components/undo-icon.js +11 -0
  204. package/dist/components/undo-icon.js.map +1 -0
  205. package/dist/esm/basedecoder-j-vOrhhh.js +114 -0
  206. package/dist/esm/basedecoder-j-vOrhhh.js.map +1 -0
  207. package/dist/esm/deflate-DHgPf9CO.js +15 -0
  208. package/dist/{stencil-library/deflate-BrCNE9ec.js.map → esm/deflate-DHgPf9CO.js.map} +1 -1
  209. package/dist/esm/eraser-icon_18.entry.js +7 -0
  210. package/dist/esm/eraser-icon_18.entry.js.map +1 -0
  211. package/dist/esm/index-C2JRBB5c.js +1458 -0
  212. package/dist/esm/index-C2JRBB5c.js.map +1 -0
  213. package/dist/esm/index.js +5 -0
  214. package/dist/esm/index.js.map +1 -0
  215. package/dist/esm/jpeg-CJLm1GkA.js +902 -0
  216. package/dist/esm/jpeg-CJLm1GkA.js.map +1 -0
  217. package/dist/esm/lerc-C1dTV3Ec.js +4424 -0
  218. package/dist/esm/lerc-C1dTV3Ec.js.map +1 -0
  219. package/dist/esm/loader.js +16 -0
  220. package/dist/esm/loader.js.map +1 -0
  221. package/dist/esm/loading-widget.entry.js +20 -0
  222. package/dist/esm/loading-widget.entry.js.map +1 -0
  223. package/dist/esm/lzw-DaOzWJUD.js +138 -0
  224. package/dist/esm/lzw-DaOzWJUD.js.map +1 -0
  225. package/dist/esm/packbits-CZPyx9kx.js +33 -0
  226. package/dist/esm/packbits-CZPyx9kx.js.map +1 -0
  227. package/dist/esm/pako.esm-B5WTRCh8.js +3241 -0
  228. package/dist/{stencil-library/pako.esm-CPorU236.js.map → esm/pako.esm-B5WTRCh8.js.map} +1 -1
  229. package/dist/esm/raw-pqeeWc2_.js +14 -0
  230. package/dist/esm/raw-pqeeWc2_.js.map +1 -0
  231. package/dist/esm/stencil-library.js +26 -0
  232. package/dist/esm/stencil-library.js.map +1 -0
  233. package/dist/esm/webimage-BiHardhv.js +47 -0
  234. package/dist/{stencil-library/webimage-V5ihYILu.js.map → esm/webimage-BiHardhv.js.map} +1 -1
  235. package/dist/index.cjs.js +1 -0
  236. package/dist/index.js +1 -0
  237. package/dist/stencil-library/build/assets/tutorial1.mp4 +0 -0
  238. package/dist/stencil-library/build/assets/tutorial2.mp4 +0 -0
  239. package/dist/stencil-library/build/assets/tutorial3.mp4 +0 -0
  240. package/dist/stencil-library/index.esm.js +1 -13
  241. package/dist/stencil-library/index.esm.js.map +1 -1
  242. package/dist/stencil-library/loading-widget.entry.esm.js.map +1 -1
  243. package/dist/stencil-library/p-0cc467c4.entry.js +2 -0
  244. package/dist/stencil-library/p-0cc467c4.entry.js.map +1 -0
  245. package/dist/stencil-library/p-B54Ul0nf.js +2 -0
  246. package/dist/stencil-library/p-B54Ul0nf.js.map +1 -0
  247. package/dist/stencil-library/p-B5WTRCh8.js +2 -0
  248. package/dist/stencil-library/p-B5WTRCh8.js.map +1 -0
  249. package/dist/stencil-library/p-BGoSj_DR.js +2 -0
  250. package/dist/stencil-library/p-BGoSj_DR.js.map +1 -0
  251. package/dist/stencil-library/p-ByX6QP-E.js +2 -0
  252. package/dist/stencil-library/p-ByX6QP-E.js.map +1 -0
  253. package/dist/stencil-library/p-C2JRBB5c.js +3 -0
  254. package/dist/stencil-library/p-C2JRBB5c.js.map +1 -0
  255. package/dist/stencil-library/p-CX8V3eiN.js +2 -0
  256. package/dist/stencil-library/p-CX8V3eiN.js.map +1 -0
  257. package/dist/stencil-library/p-Cgchl6bA.js +2 -0
  258. package/dist/stencil-library/p-Cgchl6bA.js.map +1 -0
  259. package/dist/stencil-library/p-DN5z5Lnk.js +2 -0
  260. package/dist/stencil-library/p-DN5z5Lnk.js.map +1 -0
  261. package/dist/stencil-library/p-DYtW7_ih.js +10 -0
  262. package/dist/stencil-library/p-DYtW7_ih.js.map +1 -0
  263. package/dist/stencil-library/p-WmcSqXD8.js +2 -0
  264. package/dist/stencil-library/p-WmcSqXD8.js.map +1 -0
  265. package/dist/stencil-library/p-d3e17162.entry.js +2 -0
  266. package/dist/stencil-library/p-d3e17162.entry.js.map +1 -0
  267. package/dist/stencil-library/p-j-vOrhhh.js +2 -0
  268. package/dist/stencil-library/p-j-vOrhhh.js.map +1 -0
  269. package/dist/stencil-library/p-q8auDIJ2.js +2 -0
  270. package/dist/stencil-library/p-q8auDIJ2.js.map +1 -0
  271. package/dist/stencil-library/stencil-library.esm.js +1 -52
  272. package/dist/stencil-library/stencil-library.esm.js.map +1 -1
  273. package/dist/types/components/icons/marker.d.ts +5 -0
  274. package/dist/types/components/map-draw/map-draw.d.ts +8 -1
  275. package/dist/types/components/map-draw/map-selector.d.ts +1 -0
  276. package/dist/types/components/map-draw/polygon-buttons.d.ts +0 -1
  277. package/dist/types/components/map-draw/polygon-information.d.ts +2 -0
  278. package/dist/types/components/map-draw/tutorial-component.d.ts +8 -0
  279. package/dist/types/components.d.ts +42 -17
  280. package/dist/types/types/lang.d.ts +21 -0
  281. package/dist/types/utils/api.d.ts +1 -1
  282. package/dist/types/utils/images.d.ts +1 -0
  283. package/package.json +2 -1
  284. package/dist/stencil-library/api-90JQS7b6.js +0 -104
  285. package/dist/stencil-library/api-90JQS7b6.js.map +0 -1
  286. package/dist/stencil-library/api-B5514wut.js +0 -102
  287. package/dist/stencil-library/api-B5514wut.js.map +0 -1
  288. package/dist/stencil-library/api-CLbMaqt3.js +0 -103
  289. package/dist/stencil-library/api-CLbMaqt3.js.map +0 -1
  290. package/dist/stencil-library/api-Cfi-C6kT.js +0 -104
  291. package/dist/stencil-library/api-Cfi-C6kT.js.map +0 -1
  292. package/dist/stencil-library/api-CiNFC5mG.js +0 -104
  293. package/dist/stencil-library/api-CiNFC5mG.js.map +0 -1
  294. package/dist/stencil-library/api-D_61gY2X.js +0 -102
  295. package/dist/stencil-library/api-D_61gY2X.js.map +0 -1
  296. package/dist/stencil-library/api-Did5lAE0.js.map +0 -1
  297. package/dist/stencil-library/api-S3oJcLL5.js +0 -103
  298. package/dist/stencil-library/api-S3oJcLL5.js.map +0 -1
  299. package/dist/stencil-library/api-iAs1ZQr1.js +0 -104
  300. package/dist/stencil-library/api-iAs1ZQr1.js.map +0 -1
  301. package/dist/stencil-library/api-vropRvpT.js +0 -102
  302. package/dist/stencil-library/api-vropRvpT.js.map +0 -1
  303. package/dist/stencil-library/config-CWfV1nKn.js.map +0 -1
  304. package/dist/stencil-library/constants-pXQQsEkH.js +0 -1519
  305. package/dist/stencil-library/constants-pXQQsEkH.js.map +0 -1
  306. package/dist/stencil-library/decoder-BDfrXE7e.js +0 -39
  307. package/dist/stencil-library/decoder-BDfrXE7e.js.map +0 -1
  308. package/dist/stencil-library/deflate-BrCNE9ec.js +0 -21
  309. package/dist/stencil-library/eraser-icon.entry.esm.js.map +0 -1
  310. package/dist/stencil-library/eraser-icon.entry.js +0 -22
  311. package/dist/stencil-library/eraser-icon.entry.js.map +0 -1
  312. package/dist/stencil-library/house-icon.entry.esm.js.map +0 -1
  313. package/dist/stencil-library/house-icon.entry.js +0 -22
  314. package/dist/stencil-library/house-icon.entry.js.map +0 -1
  315. package/dist/stencil-library/icon-selector.entry.esm.js.map +0 -1
  316. package/dist/stencil-library/icon-selector.entry.js +0 -44
  317. package/dist/stencil-library/icon-selector.entry.js.map +0 -1
  318. package/dist/stencil-library/index-CChkgM3J.js +0 -414
  319. package/dist/stencil-library/index-CChkgM3J.js.map +0 -1
  320. package/dist/stencil-library/index-Cx8GOJRA.js +0 -4172
  321. package/dist/stencil-library/index-Cx8GOJRA.js.map +0 -1
  322. package/dist/stencil-library/jpeg-CjOJHUd1.js.map +0 -1
  323. package/dist/stencil-library/lerc-BQF80JgE.js.map +0 -1
  324. package/dist/stencil-library/loading-widget.entry.js +0 -20
  325. package/dist/stencil-library/loading-widget.entry.js.map +0 -1
  326. package/dist/stencil-library/lzw-PA2aOuVK.js.map +0 -1
  327. package/dist/stencil-library/map-draw-CaQc1QTP.js +0 -25429
  328. package/dist/stencil-library/map-draw-CaQc1QTP.js.map +0 -1
  329. package/dist/stencil-library/map-draw.entry.esm.js.map +0 -1
  330. package/dist/stencil-library/map-draw.entry.js +0 -12
  331. package/dist/stencil-library/map-draw.entry.js.map +0 -1
  332. package/dist/stencil-library/map-selector.entry.esm.js.map +0 -1
  333. package/dist/stencil-library/map-selector.entry.js +0 -171
  334. package/dist/stencil-library/map-selector.entry.js.map +0 -1
  335. package/dist/stencil-library/move-icon.entry.esm.js.map +0 -1
  336. package/dist/stencil-library/move-icon.entry.js +0 -22
  337. package/dist/stencil-library/move-icon.entry.js.map +0 -1
  338. package/dist/stencil-library/octagon-minus-icon.entry.esm.js.map +0 -1
  339. package/dist/stencil-library/octagon-minus-icon.entry.js +0 -22
  340. package/dist/stencil-library/octagon-minus-icon.entry.js.map +0 -1
  341. package/dist/stencil-library/packbits-BMYGgS0z.js.map +0 -1
  342. package/dist/stencil-library/pako.esm-CPorU236.js +0 -6881
  343. package/dist/stencil-library/polygon-buttons.entry.esm.js.map +0 -1
  344. package/dist/stencil-library/polygon-buttons.entry.js +0 -30
  345. package/dist/stencil-library/polygon-buttons.entry.js.map +0 -1
  346. package/dist/stencil-library/polygon-information.entry.esm.js.map +0 -1
  347. package/dist/stencil-library/polygon-information.entry.js +0 -53
  348. package/dist/stencil-library/polygon-information.entry.js.map +0 -1
  349. package/dist/stencil-library/raw-D-Vfg78n.js +0 -20
  350. package/dist/stencil-library/raw-D-Vfg78n.js.map +0 -1
  351. package/dist/stencil-library/search-icon.entry.esm.js.map +0 -1
  352. package/dist/stencil-library/search-icon.entry.js +0 -22
  353. package/dist/stencil-library/search-icon.entry.js.map +0 -1
  354. package/dist/stencil-library/settings-icon.entry.esm.js.map +0 -1
  355. package/dist/stencil-library/settings-icon.entry.js +0 -22
  356. package/dist/stencil-library/settings-icon.entry.js.map +0 -1
  357. package/dist/stencil-library/settings-modal.entry.esm.js.map +0 -1
  358. package/dist/stencil-library/settings-modal.entry.js +0 -58
  359. package/dist/stencil-library/settings-modal.entry.js.map +0 -1
  360. package/dist/stencil-library/solar-calculator.entry.esm.js.map +0 -1
  361. package/dist/stencil-library/solar-calculator.entry.js +0 -26666
  362. package/dist/stencil-library/solar-calculator.entry.js.map +0 -1
  363. package/dist/stencil-library/solar-expert.entry.esm.js.map +0 -1
  364. package/dist/stencil-library/solar-expert.entry.js +0 -241
  365. package/dist/stencil-library/solar-expert.entry.js.map +0 -1
  366. package/dist/stencil-library/solar-system-form.entry.esm.js.map +0 -1
  367. package/dist/stencil-library/solar-system-form.entry.js +0 -444
  368. package/dist/stencil-library/solar-system-form.entry.js.map +0 -1
  369. package/dist/stencil-library/store-4trH9erz.js.map +0 -1
  370. package/dist/stencil-library/tool-box.entry.esm.js.map +0 -1
  371. package/dist/stencil-library/tool-box.entry.js +0 -36
  372. package/dist/stencil-library/tool-box.entry.js.map +0 -1
  373. package/dist/stencil-library/tools-BCET7NeO.js.map +0 -1
  374. package/dist/stencil-library/undo-icon.entry.esm.js.map +0 -1
  375. package/dist/stencil-library/undo-icon.entry.js +0 -22
  376. package/dist/stencil-library/undo-icon.entry.js.map +0 -1
  377. package/dist/stencil-library/utils-BCUZxI9u.js.map +0 -1
  378. package/dist/types/components/solar-calculator/solar-calculator.d.ts +0 -15
  379. /package/dist/{stencil-library → esm}/app-globals-CX8V3eiN.js +0 -0
  380. /package/dist/{stencil-library → esm}/app-globals-CX8V3eiN.js.map +0 -0
@@ -0,0 +1,1959 @@
1
+
2
+ if (typeof global === "undefined") { var global = globalThis || window || self; }
3
+ import { p as proxyCustomElement, H, h } from './index.js';
4
+ import { g as getLanguageStrings, s as state } from './p-CRQ8cKpY.js';
5
+
6
+ var dist$1 = {};
7
+
8
+ var geometry = {};
9
+
10
+ var gridMatch = {};
11
+
12
+ var dist = {};
13
+
14
+ var shapes = {};
15
+
16
+ var polygon = {};
17
+
18
+ var hasRequiredPolygon;
19
+
20
+ function requirePolygon () {
21
+ if (hasRequiredPolygon) return polygon;
22
+ hasRequiredPolygon = 1;
23
+ Object.defineProperty(polygon, "__esModule", { value: true });
24
+ polygon.PolygonType = polygon.Point = void 0;
25
+ class Point {
26
+ constructor(x, y) {
27
+ this.x = x;
28
+ this.y = y;
29
+ }
30
+ equals(other) {
31
+ return this.x === other.x && this.y === other.y;
32
+ }
33
+ }
34
+ polygon.Point = Point;
35
+ var PolygonType;
36
+ (function (PolygonType) {
37
+ PolygonType["ROOF"] = "roof";
38
+ PolygonType["OBSTRUCTION"] = "obstruction";
39
+ })(PolygonType || (polygon.PolygonType = PolygonType = {}));
40
+
41
+ return polygon;
42
+ }
43
+
44
+ var utils$1 = {};
45
+
46
+ var hasRequiredUtils$1;
47
+
48
+ function requireUtils$1 () {
49
+ if (hasRequiredUtils$1) return utils$1;
50
+ hasRequiredUtils$1 = 1;
51
+ Object.defineProperty(utils$1, "__esModule", { value: true });
52
+ utils$1.isPointInPolygon = isPointInPolygon;
53
+ utils$1.isPointOnBorder = isPointOnBorder;
54
+ function isPointInPolygon(point, polygon) {
55
+ if (!polygon.closed || polygon.points.length < 3)
56
+ return false;
57
+ const num_vertices = polygon.points.length;
58
+ const x = point.x;
59
+ const y = point.y;
60
+ let inside = false;
61
+ let p1 = polygon.points[0];
62
+ let p2;
63
+ for (let i = 1; i <= num_vertices; i++) {
64
+ p2 = polygon.points[i % num_vertices];
65
+ if (y > Math.min(p1.y, p2.y)) {
66
+ if (y <= Math.max(p1.y, p2.y)) {
67
+ if (x <= Math.max(p1.x, p2.x)) {
68
+ const x_intersection = ((y - p1.y) * (p2.x - p1.x)) / (p2.y - p1.y) + p1.x;
69
+ if (p1.x === p2.x || x <= x_intersection) {
70
+ inside = !inside;
71
+ }
72
+ }
73
+ }
74
+ }
75
+ p1 = p2;
76
+ }
77
+ return inside;
78
+ }
79
+ function isPointOnBorder(point, polygon) {
80
+ if (!polygon.closed || polygon.points.length < 3)
81
+ return false;
82
+ const x = point.x;
83
+ const y = point.y;
84
+ for (let i = 0; i < polygon.points.length; i++) {
85
+ const p1 = polygon.points[i];
86
+ const p2 = polygon.points[(i + 1) % polygon.points.length];
87
+ const distance = Math.sqrt(Math.pow(p1.x - p2.x, 2) + Math.pow(p1.y - p2.y, 2));
88
+ const distanceToPoint = Math.sqrt(Math.pow(p1.x - x, 2) + Math.pow(p1.y - y, 2));
89
+ const distanceFromPoint = Math.sqrt(Math.pow(p2.x - x, 2) + Math.pow(p2.y - y, 2));
90
+ if (distance === distanceToPoint + distanceFromPoint) {
91
+ return true;
92
+ }
93
+ }
94
+ return false;
95
+ }
96
+
97
+ return utils$1;
98
+ }
99
+
100
+ var hasRequiredShapes;
101
+
102
+ function requireShapes () {
103
+ if (hasRequiredShapes) return shapes;
104
+ hasRequiredShapes = 1;
105
+ (function (exports) {
106
+ var __createBinding = (shapes && shapes.__createBinding) || (Object.create ? (function(o, m, k, k2) {
107
+ if (k2 === undefined) k2 = k;
108
+ var desc = Object.getOwnPropertyDescriptor(m, k);
109
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
110
+ desc = { enumerable: true, get: function() { return m[k]; } };
111
+ }
112
+ Object.defineProperty(o, k2, desc);
113
+ }) : (function(o, m, k, k2) {
114
+ if (k2 === undefined) k2 = k;
115
+ o[k2] = m[k];
116
+ }));
117
+ var __exportStar = (shapes && shapes.__exportStar) || function(m, exports) {
118
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
119
+ };
120
+ Object.defineProperty(exports, "__esModule", { value: true });
121
+ __exportStar(requirePolygon(), exports);
122
+ __exportStar(requireUtils$1(), exports);
123
+
124
+ } (shapes));
125
+ return shapes;
126
+ }
127
+
128
+ var solar = {};
129
+
130
+ var location = {};
131
+
132
+ var hasRequiredLocation;
133
+
134
+ function requireLocation () {
135
+ if (hasRequiredLocation) return location;
136
+ hasRequiredLocation = 1;
137
+ Object.defineProperty(location, "__esModule", { value: true });
138
+
139
+ return location;
140
+ }
141
+
142
+ var solarPanel = {};
143
+
144
+ var hasRequiredSolarPanel;
145
+
146
+ function requireSolarPanel () {
147
+ if (hasRequiredSolarPanel) return solarPanel;
148
+ hasRequiredSolarPanel = 1;
149
+ Object.defineProperty(solarPanel, "__esModule", { value: true });
150
+
151
+ return solarPanel;
152
+ }
153
+
154
+ var googleSolar = {};
155
+
156
+ var hasRequiredGoogleSolar;
157
+
158
+ function requireGoogleSolar () {
159
+ if (hasRequiredGoogleSolar) return googleSolar;
160
+ hasRequiredGoogleSolar = 1;
161
+ var __awaiter = (googleSolar && googleSolar.__awaiter) || function (thisArg, _arguments, P, generator) {
162
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
163
+ return new (P || (P = Promise))(function (resolve, reject) {
164
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
165
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
166
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
167
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
168
+ });
169
+ };
170
+ Object.defineProperty(googleSolar, "__esModule", { value: true });
171
+ googleSolar.findClosestBuilding = findClosestBuilding;
172
+ googleSolar.getDataLayerUrls = getDataLayerUrls;
173
+ function findClosestBuilding(location, apiKey) {
174
+ return __awaiter(this, void 0, void 0, function* () {
175
+ const args = {
176
+ "location.latitude": location.lat().toFixed(5),
177
+ "location.longitude": location.lng().toFixed(5),
178
+ };
179
+ const params = new URLSearchParams(Object.assign(Object.assign({}, args), { key: apiKey }));
180
+ return fetch(`https://solar.googleapis.com/v1/buildingInsights:findClosest?${params}`).then((response) => __awaiter(this, void 0, void 0, function* () {
181
+ const content = yield response.json();
182
+ if (response.status != 200) {
183
+ console.error("findClosestBuilding\n", content);
184
+ throw content;
185
+ }
186
+ return content;
187
+ }));
188
+ });
189
+ }
190
+ function getDataLayerUrls(location, radiusMeters, apiKey) {
191
+ return __awaiter(this, void 0, void 0, function* () {
192
+ const args = {
193
+ "location.latitude": location.latitude.toFixed(5),
194
+ "location.longitude": location.longitude.toFixed(5),
195
+ radius_meters: radiusMeters.toString(),
196
+ required_quality: "LOW",
197
+ };
198
+ const params = new URLSearchParams(Object.assign(Object.assign({}, args), { key: apiKey }));
199
+ return fetch(`https://solar.googleapis.com/v1/dataLayers:get?${params}`)
200
+ .then((response) => __awaiter(this, void 0, void 0, function* () {
201
+ const content = yield response.json();
202
+ if (response.status != 200) {
203
+ console.error("getDataLayerUrls\n", content);
204
+ throw content;
205
+ }
206
+ return content;
207
+ }));
208
+ });
209
+ }
210
+
211
+ return googleSolar;
212
+ }
213
+
214
+ var hasRequiredSolar;
215
+
216
+ function requireSolar () {
217
+ if (hasRequiredSolar) return solar;
218
+ hasRequiredSolar = 1;
219
+ (function (exports) {
220
+ var __createBinding = (solar && solar.__createBinding) || (Object.create ? (function(o, m, k, k2) {
221
+ if (k2 === undefined) k2 = k;
222
+ var desc = Object.getOwnPropertyDescriptor(m, k);
223
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
224
+ desc = { enumerable: true, get: function() { return m[k]; } };
225
+ }
226
+ Object.defineProperty(o, k2, desc);
227
+ }) : (function(o, m, k, k2) {
228
+ if (k2 === undefined) k2 = k;
229
+ o[k2] = m[k];
230
+ }));
231
+ var __exportStar = (solar && solar.__exportStar) || function(m, exports) {
232
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
233
+ };
234
+ Object.defineProperty(exports, "__esModule", { value: true });
235
+ __exportStar(requireLocation(), exports);
236
+ __exportStar(requireSolarPanel(), exports);
237
+ __exportStar(requireGoogleSolar(), exports);
238
+
239
+ } (solar));
240
+ return solar;
241
+ }
242
+
243
+ var heating = {};
244
+
245
+ var hasRequiredHeating;
246
+
247
+ function requireHeating () {
248
+ if (hasRequiredHeating) return heating;
249
+ hasRequiredHeating = 1;
250
+ Object.defineProperty(heating, "__esModule", { value: true });
251
+
252
+ return heating;
253
+ }
254
+
255
+ var hasRequiredDist$1;
256
+
257
+ function requireDist$1 () {
258
+ if (hasRequiredDist$1) return dist;
259
+ hasRequiredDist$1 = 1;
260
+ (function (exports) {
261
+ var __createBinding = (dist && dist.__createBinding) || (Object.create ? (function(o, m, k, k2) {
262
+ if (k2 === undefined) k2 = k;
263
+ var desc = Object.getOwnPropertyDescriptor(m, k);
264
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
265
+ desc = { enumerable: true, get: function() { return m[k]; } };
266
+ }
267
+ Object.defineProperty(o, k2, desc);
268
+ }) : (function(o, m, k, k2) {
269
+ if (k2 === undefined) k2 = k;
270
+ o[k2] = m[k];
271
+ }));
272
+ var __exportStar = (dist && dist.__exportStar) || function(m, exports) {
273
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
274
+ };
275
+ Object.defineProperty(exports, "__esModule", { value: true });
276
+ __exportStar(requireShapes(), exports);
277
+ __exportStar(requireSolar(), exports);
278
+ __exportStar(requireHeating(), exports);
279
+
280
+ } (dist));
281
+ return dist;
282
+ }
283
+
284
+ var fitting = {};
285
+
286
+ var utils = {};
287
+
288
+ var solarApi = {};
289
+
290
+ var hasRequiredSolarApi;
291
+
292
+ function requireSolarApi () {
293
+ if (hasRequiredSolarApi) return solarApi;
294
+ hasRequiredSolarApi = 1;
295
+ var __awaiter = (solarApi && solarApi.__awaiter) || function (thisArg, _arguments, P, generator) {
296
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
297
+ return new (P || (P = Promise))(function (resolve, reject) {
298
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
299
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
300
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
301
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
302
+ });
303
+ };
304
+ Object.defineProperty(solarApi, "__esModule", { value: true });
305
+ solarApi.fetchSolarData = fetchSolarData;
306
+ solarApi.getPixelInMeters = getPixelInMeters;
307
+ function fetchSolarData(latitude, longitude, apiKey) {
308
+ return __awaiter(this, void 0, void 0, function* () {
309
+ if (latitude === 0 || longitude === 0) {
310
+ return null;
311
+ }
312
+ try {
313
+ const args = {
314
+ "location.latitude": latitude.toFixed(5),
315
+ "location.longitude": longitude.toFixed(5),
316
+ };
317
+ const params = new URLSearchParams(Object.assign(Object.assign({}, args), { key: apiKey }));
318
+ const response = yield fetch(`https://solar.googleapis.com/v1/buildingInsights:findClosest?${params}`);
319
+ if (!response.ok) {
320
+ const errorText = yield response.text();
321
+ throw new Error(`HTTP error! status: ${response.status}, body: ${errorText}`);
322
+ }
323
+ const contentType = response.headers.get("content-type");
324
+ if (!contentType || !contentType.includes("application/json")) {
325
+ const text = yield response.text();
326
+ console.error("Unexpected content type:", contentType, "Response:", text);
327
+ return null;
328
+ }
329
+ const rawData = yield response.json();
330
+ return rawData;
331
+ }
332
+ catch (error) {
333
+ console.error("Error fetching solar data:", error);
334
+ if (error instanceof TypeError &&
335
+ error.message === "Failed to fetch") {
336
+ throw new Error("Unable to connect to the solar data API.");
337
+ }
338
+ throw error;
339
+ }
340
+ });
341
+ }
342
+ function getPixelInMeters(rgbTiff) {
343
+ const latDiff = rgbTiff.bounds.north - rgbTiff.bounds.south;
344
+ const pixelHeight = rgbTiff.height;
345
+ const pixelInMeters = latDiff * 111320 / pixelHeight;
346
+ return pixelInMeters;
347
+ }
348
+
349
+ return solarApi;
350
+ }
351
+
352
+ var hasRequiredUtils;
353
+
354
+ function requireUtils () {
355
+ if (hasRequiredUtils) return utils;
356
+ hasRequiredUtils = 1;
357
+ (function (exports) {
358
+ var __createBinding = (utils && utils.__createBinding) || (Object.create ? (function(o, m, k, k2) {
359
+ if (k2 === undefined) k2 = k;
360
+ var desc = Object.getOwnPropertyDescriptor(m, k);
361
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
362
+ desc = { enumerable: true, get: function() { return m[k]; } };
363
+ }
364
+ Object.defineProperty(o, k2, desc);
365
+ }) : (function(o, m, k, k2) {
366
+ if (k2 === undefined) k2 = k;
367
+ o[k2] = m[k];
368
+ }));
369
+ var __exportStar = (utils && utils.__exportStar) || function(m, exports) {
370
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
371
+ };
372
+ Object.defineProperty(exports, "__esModule", { value: true });
373
+ exports.latLngToPixel = latLngToPixel;
374
+ const harmonia_types_1 = requireDist$1();
375
+ __exportStar(/*@__PURE__*/ requireSolarApi(), exports);
376
+ function latLngToPixel(bounds, canvas, latLng) {
377
+ const ctx = canvas.getContext("2d");
378
+ if (!ctx) {
379
+ throw new Error("Canvas context not found");
380
+ }
381
+ const latToPixel = (lat) => {
382
+ return canvas.height *
383
+ (1 - (lat - bounds.south) / (bounds.north - bounds.south));
384
+ };
385
+ const lngToPixel = (lng) => {
386
+ return canvas.width * (lng - bounds.west) / (bounds.east - bounds.west);
387
+ };
388
+ return new harmonia_types_1.Point(lngToPixel(latLng.longitude), latToPixel(latLng.latitude));
389
+ }
390
+
391
+ } (utils));
392
+ return utils;
393
+ }
394
+
395
+ var hasRequiredFitting;
396
+
397
+ function requireFitting () {
398
+ if (hasRequiredFitting) return fitting;
399
+ hasRequiredFitting = 1;
400
+ Object.defineProperty(fitting, "__esModule", { value: true });
401
+ fitting.projectPoint = projectPoint;
402
+ fitting.projectPolygon = projectPolygon;
403
+ fitting.intersects = intersects;
404
+ fitting.offsetPolygon = offsetPolygon;
405
+ fitting.getBestFittingRoofSegment = getBestFittingRoofSegment;
406
+ const harmonia_types_1 = requireDist$1();
407
+ const utils_1 = /*@__PURE__*/ requireUtils();
408
+ function projectPoint(point, azimuth) {
409
+ const angle = azimuth * (Math.PI / 180);
410
+ const x = point.x * Math.cos(angle) - point.y * Math.sin(angle);
411
+ const y = point.x * Math.sin(angle) + point.y * Math.cos(angle);
412
+ return new harmonia_types_1.Point(x, y);
413
+ }
414
+ function projectPolygon(polygon, azimuth) {
415
+ return {
416
+ points: polygon.points.map((point) => projectPoint(point, azimuth)),
417
+ type: polygon.type,
418
+ closed: polygon.closed,
419
+ id: polygon.id,
420
+ };
421
+ }
422
+ function intersects(line1, line2) {
423
+ const p1 = line1.start;
424
+ const p2 = line1.end;
425
+ const p3 = line2.start;
426
+ const p4 = line2.end;
427
+ if (p1.equals(p3) ||
428
+ p1.equals(p4) ||
429
+ p2.equals(p3) ||
430
+ p2.equals(p4)) {
431
+ return false;
432
+ }
433
+ const d1 = (p4.x - p3.x) * (p1.y - p3.y) - (p4.y - p3.y) * (p1.x - p3.x);
434
+ const d2 = (p4.x - p3.x) * (p2.y - p3.y) - (p4.y - p3.y) * (p2.x - p3.x);
435
+ const d3 = (p2.x - p1.x) * (p3.y - p1.y) - (p2.y - p1.y) * (p3.x - p1.x);
436
+ const d4 = (p2.x - p1.x) * (p4.y - p1.y) - (p2.y - p1.y) * (p4.x - p1.x);
437
+ return (d1 * d2 < 0) && (d3 * d4 < 0);
438
+ }
439
+ function offsetPolygon(polygon, offset) {
440
+ if (polygon.points.length === 0) {
441
+ return { polygon: polygon, offset: { x: 0, y: 0 } };
442
+ }
443
+ let offsetX = 0;
444
+ let offsetY = 0;
445
+ if (!offset) {
446
+ const minX = Math.min(...polygon.points.map((point) => point.x));
447
+ const minY = Math.min(...polygon.points.map((point) => point.y));
448
+ const maxX = Math.max(...polygon.points.map((point) => point.x));
449
+ const maxY = Math.max(...polygon.points.map((point) => point.y));
450
+ offsetX = minX + (maxX - minX) / 2;
451
+ offsetY = minY + (maxY - minY) / 2;
452
+ }
453
+ else {
454
+ offsetX = offset.x;
455
+ offsetY = offset.y;
456
+ }
457
+ const newPoints = polygon.points.map((point) => new harmonia_types_1.Point(point.x - offsetX, point.y - offsetY));
458
+ return {
459
+ polygon: Object.assign(Object.assign({}, polygon), { points: newPoints }),
460
+ offset: { x: offsetX, y: offsetY },
461
+ };
462
+ }
463
+ function getBestFittingRoofSegment(roof, roofSegmentStats, bounds, canvas) {
464
+ const polygonBounds = {
465
+ minX: Math.min(...roof.points.map((p) => p.x)),
466
+ maxX: Math.max(...roof.points.map((p) => p.x)),
467
+ minY: Math.min(...roof.points.map((p) => p.y)),
468
+ maxY: Math.max(...roof.points.map((p) => p.y)),
469
+ };
470
+ let bestSegment = null;
471
+ let bestIoU = 0;
472
+ for (const segment of roofSegmentStats) {
473
+ const sw = (0, utils_1.latLngToPixel)(bounds, canvas, {
474
+ latitude: segment.boundingBox.sw.latitude,
475
+ longitude: segment.boundingBox.sw.longitude,
476
+ });
477
+ const ne = (0, utils_1.latLngToPixel)(bounds, canvas, {
478
+ latitude: segment.boundingBox.ne.latitude,
479
+ longitude: segment.boundingBox.ne.longitude,
480
+ });
481
+ const segmentBounds = {
482
+ minX: sw.x,
483
+ maxX: ne.x,
484
+ minY: ne.y,
485
+ maxY: sw.y,
486
+ };
487
+ const interLeft = Math.max(polygonBounds.minX, segmentBounds.minX);
488
+ const interRight = Math.min(polygonBounds.maxX, segmentBounds.maxX);
489
+ const interTop = Math.max(polygonBounds.minY, segmentBounds.minY);
490
+ const interBottom = Math.min(polygonBounds.maxY, segmentBounds.maxY);
491
+ const interWidth = interRight - interLeft;
492
+ const interHeight = interBottom - interTop;
493
+ let intersectionArea = 0;
494
+ if (interWidth > 0 && interHeight > 0) {
495
+ intersectionArea = interWidth * interHeight;
496
+ }
497
+ const polygonArea = (polygonBounds.maxX - polygonBounds.minX) *
498
+ (polygonBounds.maxY - polygonBounds.minY);
499
+ const segmentArea = (segmentBounds.maxX - segmentBounds.minX) *
500
+ (segmentBounds.maxY - segmentBounds.minY);
501
+ const unionArea = polygonArea + segmentArea - intersectionArea;
502
+ const iou = unionArea > 0 ? intersectionArea / unionArea : 0;
503
+ if (iou > bestIoU) {
504
+ bestIoU = iou;
505
+ bestSegment = segment;
506
+ }
507
+ }
508
+ return bestSegment;
509
+ }
510
+
511
+ return fitting;
512
+ }
513
+
514
+ var hasRequiredGridMatch;
515
+
516
+ function requireGridMatch () {
517
+ if (hasRequiredGridMatch) return gridMatch;
518
+ hasRequiredGridMatch = 1;
519
+ Object.defineProperty(gridMatch, "__esModule", { value: true });
520
+ gridMatch.generateGrid = generateGrid;
521
+ gridMatch.solarPanelInObstacle = solarPanelInObstacle;
522
+ gridMatch.solarPanelInPolygon = solarPanelInPolygon;
523
+ gridMatch.isPanelObstructed = isPanelObstructed;
524
+ gridMatch.getSolarPanelsInPolygon = getSolarPanelsInPolygon;
525
+ gridMatch.getOptimalSolarPosition = getOptimalSolarPosition;
526
+ gridMatch.insetPolygon = insetPolygon;
527
+ gridMatch.getOptimalSolarPositionFully = getOptimalSolarPositionFully;
528
+ const harmonia_types_1 = requireDist$1();
529
+ const fitting_1 = /*@__PURE__*/ requireFitting();
530
+ function generateGrid(minMax, solarPanel, horizontal, anker, rowSpacing, columnSpacing) {
531
+ const grid = [];
532
+ const width = horizontal ? solarPanel.heightMeters : solarPanel.widthMeters;
533
+ const widthCount = Math.ceil((minMax.maxX - minMax.minX) / width);
534
+ const height = horizontal
535
+ ? solarPanel.widthMeters
536
+ : solarPanel.heightMeters;
537
+ const heightCount = Math.ceil((minMax.maxY - minMax.minY) / height);
538
+ const widthOffset = width / 2;
539
+ const heightOffset = height / 2;
540
+ const startX = anker.x -
541
+ (Math.ceil((anker.x - minMax.minX) / width) * width);
542
+ const startY = anker.y -
543
+ (Math.ceil((anker.y - minMax.minY) / height) * height);
544
+ for (let i = 0; i < heightCount; i++) {
545
+ const row = [];
546
+ for (let j = 0; j < widthCount; j++) {
547
+ const x = startX + j * width + j * columnSpacing + widthOffset;
548
+ const y = startY + i * height + i * rowSpacing + heightOffset;
549
+ const positionedSolarPanel = {
550
+ panel: solarPanel,
551
+ pixelPosition: new harmonia_types_1.Point(x, y),
552
+ horizontal: horizontal,
553
+ };
554
+ row.push(positionedSolarPanel);
555
+ }
556
+ grid.push(row);
557
+ }
558
+ return grid;
559
+ }
560
+ function getSolarPanelLines(positionedSolarPanel, horizontal) {
561
+ const width = horizontal
562
+ ? positionedSolarPanel.panel.heightMeters
563
+ : positionedSolarPanel.panel.widthMeters;
564
+ const height = horizontal
565
+ ? positionedSolarPanel.panel.widthMeters
566
+ : positionedSolarPanel.panel.heightMeters;
567
+ const p1 = new harmonia_types_1.Point(positionedSolarPanel.pixelPosition.x - width / 2, positionedSolarPanel.pixelPosition.y - height / 2);
568
+ const p2 = new harmonia_types_1.Point(positionedSolarPanel.pixelPosition.x - width / 2, positionedSolarPanel.pixelPosition.y + height / 2);
569
+ const p3 = new harmonia_types_1.Point(positionedSolarPanel.pixelPosition.x + width / 2, positionedSolarPanel.pixelPosition.y + height / 2);
570
+ const p4 = new harmonia_types_1.Point(positionedSolarPanel.pixelPosition.x + width / 2, positionedSolarPanel.pixelPosition.y - height / 2);
571
+ const lines = [
572
+ {
573
+ start: p1,
574
+ end: p2,
575
+ },
576
+ {
577
+ start: p2,
578
+ end: p3,
579
+ },
580
+ {
581
+ start: p3,
582
+ end: p4,
583
+ },
584
+ {
585
+ start: p4,
586
+ end: p1,
587
+ },
588
+ ];
589
+ return lines;
590
+ }
591
+ function solarPanelInObstacle(positionedSolarPanel, obstacle, horizontal) {
592
+ const lines = getSolarPanelLines(positionedSolarPanel, horizontal);
593
+ if ((0, harmonia_types_1.isPointInPolygon)(positionedSolarPanel.pixelPosition, obstacle)) {
594
+ return true;
595
+ }
596
+ for (let i = 0; i < obstacle.points.length; i++) {
597
+ const point = obstacle.points[i];
598
+ const nextPoint = obstacle.points[(i + 1) % obstacle.points.length];
599
+ const border = {
600
+ start: point,
601
+ end: nextPoint,
602
+ };
603
+ for (const line of lines) {
604
+ if ((0, fitting_1.intersects)(line, border)) {
605
+ return true;
606
+ }
607
+ }
608
+ }
609
+ return false;
610
+ }
611
+ function solarPanelInPolygon(positionedSolarPanel, polygon, horizontal) {
612
+ const lines = getSolarPanelLines(positionedSolarPanel, horizontal);
613
+ for (let i = 0; i < polygon.points.length; i++) {
614
+ const point = polygon.points[i];
615
+ const nextPoint = polygon.points[(i + 1) % polygon.points.length];
616
+ const border = {
617
+ start: point,
618
+ end: nextPoint,
619
+ };
620
+ for (const line of lines) {
621
+ if ((0, fitting_1.intersects)(line, border)) {
622
+ return false;
623
+ }
624
+ }
625
+ }
626
+ return (0, harmonia_types_1.isPointInPolygon)(positionedSolarPanel.pixelPosition, polygon);
627
+ }
628
+ function isPanelObstructed(positionedSolarPanel, obstacles, horizontal) {
629
+ for (const obstacle of obstacles) {
630
+ if (solarPanelInObstacle(positionedSolarPanel, obstacle.polygon, horizontal)) {
631
+ return true;
632
+ }
633
+ }
634
+ return false;
635
+ }
636
+ function getSolarPanelsInPolygon(grid, polygon, horizontal, obstacles) {
637
+ const solarPanels = [];
638
+ for (const row of grid) {
639
+ let newRow = [];
640
+ for (const positionedSolarPanel of row) {
641
+ const isObstructed = isPanelObstructed(positionedSolarPanel, obstacles, horizontal);
642
+ if (solarPanelInPolygon(positionedSolarPanel, polygon, horizontal) && !isObstructed) {
643
+ newRow.push(positionedSolarPanel);
644
+ }
645
+ }
646
+ solarPanels.push(newRow);
647
+ }
648
+ return solarPanels;
649
+ }
650
+ function getOptimalSolarPosition(roof, obstacles, solarPanel, angle, columnSpacing, rowSpacing) {
651
+ const minX = Math.min(...roof.points.map((p) => p.x));
652
+ const maxX = Math.max(...roof.points.map((p) => p.x));
653
+ const minY = Math.min(...roof.points.map((p) => p.y));
654
+ const maxY = Math.max(...roof.points.map((p) => p.y));
655
+ const minMax = {
656
+ minX: minX,
657
+ maxX: maxX,
658
+ minY: minY,
659
+ maxY: maxY,
660
+ };
661
+ Object.assign(Object.assign({}, solarPanel), { widthMeters: solarPanel.widthMeters * Math.cos(angle * Math.PI / 180), heightMeters: solarPanel.heightMeters });
662
+ const verticalSolarPanel = Object.assign(Object.assign({}, solarPanel), { widthMeters: solarPanel.widthMeters, heightMeters: solarPanel.heightMeters * Math.cos(angle * Math.PI / 180) });
663
+ let solarPanels = [];
664
+ let numberOfPanels = 0;
665
+ for (const point of roof.points) {
666
+ for (const horizontal of [true]) {
667
+ const grid = generateGrid(minMax, verticalSolarPanel, horizontal, point, rowSpacing, columnSpacing);
668
+ const solarPanelsInPolygon = getSolarPanelsInPolygon(grid, roof, horizontal, obstacles);
669
+ const numberOfPanelsInPolygon = solarPanelsInPolygon.reduce((acc, row) => acc + row.length, 0);
670
+ if (numberOfPanelsInPolygon > numberOfPanels) {
671
+ numberOfPanels = numberOfPanelsInPolygon;
672
+ solarPanels = solarPanelsInPolygon;
673
+ }
674
+ }
675
+ break;
676
+ }
677
+ return solarPanels;
678
+ }
679
+ function projectObstacles(obstacles, azimuth, offset, inset) {
680
+ const result = [];
681
+ for (const obstacle of obstacles) {
682
+ const offsetObstacle = (0, fitting_1.offsetPolygon)(obstacle, offset);
683
+ const projectedObstacle = (0, fitting_1.projectPolygon)(offsetObstacle.polygon, -azimuth);
684
+ const insetObstacle = insetPolygon(projectedObstacle, -inset);
685
+ const minX = Math.min(...insetObstacle.points.map((p) => p.x));
686
+ const maxX = Math.max(...insetObstacle.points.map((p) => p.x));
687
+ const minY = Math.min(...insetObstacle.points.map((p) => p.y));
688
+ const maxY = Math.max(...insetObstacle.points.map((p) => p.y));
689
+ const boundingBox = {
690
+ minX: minX,
691
+ maxX: maxX,
692
+ minY: minY,
693
+ maxY: maxY,
694
+ };
695
+ result.push({
696
+ polygon: projectedObstacle,
697
+ boundingBox: boundingBox,
698
+ });
699
+ }
700
+ return result;
701
+ }
702
+ function isClockwise(points) {
703
+ let sum = 0;
704
+ for (let i = 0; i < points.length; i++) {
705
+ const curr = points[i];
706
+ const next = points[(i + 1) % points.length];
707
+ sum += (next.x - curr.x) * (next.y + curr.y);
708
+ }
709
+ return sum > 0;
710
+ }
711
+ function insetPolygon(polygon, inset) {
712
+ const points = polygon.points;
713
+ const isClockwisePolygon = isClockwise(points);
714
+ inset = inset * Math.sqrt(2) * (isClockwisePolygon ? -1 : 1);
715
+ const insetPoints = [];
716
+ for (let i = 0; i < points.length; i++) {
717
+ const prev = points[(i - 1 + points.length) % points.length];
718
+ const curr = points[i];
719
+ const next = points[(i + 1) % points.length];
720
+ const v1 = {
721
+ x: curr.x - prev.x,
722
+ y: curr.y - prev.y,
723
+ };
724
+ const v2 = {
725
+ x: next.x - curr.x,
726
+ y: next.y - curr.y,
727
+ };
728
+ const perp1 = {
729
+ x: -v1.y,
730
+ y: v1.x,
731
+ };
732
+ const perp2 = {
733
+ x: -v2.y,
734
+ y: v2.x,
735
+ };
736
+ const length1 = Math.sqrt(perp1.x * perp1.x + perp1.y * perp1.y);
737
+ const length2 = Math.sqrt(perp2.x * perp2.x + perp2.y * perp2.y);
738
+ perp1.x /= length1;
739
+ perp1.y /= length1;
740
+ perp2.x /= length2;
741
+ perp2.y /= length2;
742
+ const bisector = {
743
+ x: perp1.x + perp2.x,
744
+ y: perp1.y + perp2.y,
745
+ };
746
+ const bisectorLength = Math.sqrt(bisector.x * bisector.x + bisector.y * bisector.y);
747
+ bisector.x /= bisectorLength;
748
+ bisector.y /= bisectorLength;
749
+ const insetPoint = new harmonia_types_1.Point(curr.x + bisector.x * inset, curr.y + bisector.y * inset);
750
+ insetPoints.push(insetPoint);
751
+ }
752
+ return {
753
+ points: insetPoints,
754
+ type: polygon.type,
755
+ closed: polygon.closed,
756
+ id: polygon.id,
757
+ area: polygon.area,
758
+ };
759
+ }
760
+ function getOptimalSolarPositionFully(roof, obstacles, solarPanel, azimuth, inset, angle, columnSpacing, rowSpacing) {
761
+ const insetRoof = insetPolygon(roof, inset);
762
+ const offset = (0, fitting_1.offsetPolygon)(insetRoof);
763
+ const projectedOffset = (0, fitting_1.projectPolygon)(offset.polygon, -azimuth);
764
+ const projectedObstacles = projectObstacles(obstacles, azimuth, offset.offset, inset);
765
+ const horizontalSolarPanels = getOptimalSolarPosition(projectedOffset, projectedObstacles, solarPanel, angle, columnSpacing, rowSpacing);
766
+ const unprojectedPanels = [];
767
+ for (const panel of horizontalSolarPanels.flat()) {
768
+ const unprojectedPanel = (0, fitting_1.projectPoint)(panel.pixelPosition, azimuth);
769
+ const offsetPosition = new harmonia_types_1.Point(unprojectedPanel.x + offset.offset.x, unprojectedPanel.y + offset.offset.y);
770
+ unprojectedPanels.push({
771
+ panel: panel.panel,
772
+ pixelPosition: offsetPosition,
773
+ horizontal: panel.horizontal,
774
+ });
775
+ }
776
+ return unprojectedPanels;
777
+ }
778
+
779
+ return gridMatch;
780
+ }
781
+
782
+ var hasRequiredGeometry;
783
+
784
+ function requireGeometry () {
785
+ if (hasRequiredGeometry) return geometry;
786
+ hasRequiredGeometry = 1;
787
+ (function (exports) {
788
+ var __createBinding = (geometry && geometry.__createBinding) || (Object.create ? (function(o, m, k, k2) {
789
+ if (k2 === undefined) k2 = k;
790
+ var desc = Object.getOwnPropertyDescriptor(m, k);
791
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
792
+ desc = { enumerable: true, get: function() { return m[k]; } };
793
+ }
794
+ Object.defineProperty(o, k2, desc);
795
+ }) : (function(o, m, k, k2) {
796
+ if (k2 === undefined) k2 = k;
797
+ o[k2] = m[k];
798
+ }));
799
+ var __exportStar = (geometry && geometry.__exportStar) || function(m, exports) {
800
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
801
+ };
802
+ Object.defineProperty(exports, "__esModule", { value: true });
803
+ __exportStar(/*@__PURE__*/ requireGridMatch(), exports);
804
+ __exportStar(/*@__PURE__*/ requireFitting(), exports);
805
+
806
+ } (geometry));
807
+ return geometry;
808
+ }
809
+
810
+ var simulation$1 = {};
811
+
812
+ var simulation = {};
813
+
814
+ var solarCurves = {};
815
+
816
+ var hasRequiredSolarCurves;
817
+
818
+ function requireSolarCurves () {
819
+ if (hasRequiredSolarCurves) return solarCurves;
820
+ hasRequiredSolarCurves = 1;
821
+ Object.defineProperty(solarCurves, "__esModule", { value: true });
822
+ solarCurves.SOLAR_RADIATION = solarCurves.CONSUMPTION_PROFILES = void 0;
823
+ solarCurves.getSolarRadiation = getSolarRadiation;
824
+ const SOLAR_RADIATION = [
825
+ 0,
826
+ 0,
827
+ 0,
828
+ 0,
829
+ 0,
830
+ 0,
831
+ 0,
832
+ 0.1,
833
+ 0.2,
834
+ 0.4,
835
+ 0.8,
836
+ 0.9,
837
+ 1,
838
+ 0.95,
839
+ 0.9,
840
+ 0.7,
841
+ 0.5,
842
+ 0.3,
843
+ 0.16,
844
+ 0.02,
845
+ 0,
846
+ 0,
847
+ 0,
848
+ 0,
849
+ ];
850
+ solarCurves.SOLAR_RADIATION = SOLAR_RADIATION;
851
+ function getSolarRadiation(discountFactor) {
852
+ return SOLAR_RADIATION.map((value) => value * discountFactor);
853
+ }
854
+ const CONSUMPTION_PROFILES = {
855
+ mostly_at_home: [
856
+ 0.1,
857
+ 0.1,
858
+ 0.1,
859
+ 0.1,
860
+ 0.1,
861
+ 0.15,
862
+ 0.23,
863
+ 0.26,
864
+ 0.16,
865
+ 0.16,
866
+ 0.15,
867
+ 0.19,
868
+ 0.23,
869
+ 0.24,
870
+ 0.35,
871
+ 0.28,
872
+ 0.275,
873
+ 0.8,
874
+ 0.78,
875
+ 0.74,
876
+ 0.75,
877
+ 0.73,
878
+ 0.26,
879
+ 0.1,
880
+ ],
881
+ mostly_away: [
882
+ 0.1,
883
+ 0.1,
884
+ 0.1,
885
+ 0.1,
886
+ 0.1,
887
+ 0.15,
888
+ 0.29,
889
+ 0.32,
890
+ 0.25,
891
+ 0.15,
892
+ 0.12,
893
+ 0.14,
894
+ 0.15,
895
+ 0.12,
896
+ 0.16,
897
+ 0.21,
898
+ 0.285,
899
+ 1,
900
+ 0.81,
901
+ 0.77,
902
+ 0.79,
903
+ 0.73,
904
+ 0.26,
905
+ 0.1,
906
+ ],
907
+ };
908
+ solarCurves.CONSUMPTION_PROFILES = CONSUMPTION_PROFILES;
909
+
910
+ return solarCurves;
911
+ }
912
+
913
+ var types = {};
914
+
915
+ var hasRequiredTypes;
916
+
917
+ function requireTypes () {
918
+ if (hasRequiredTypes) return types;
919
+ hasRequiredTypes = 1;
920
+ Object.defineProperty(types, "__esModule", { value: true });
921
+ types.DEFAULT_GENERAL_SIMULATION_CONFIG = void 0;
922
+ types.DEFAULT_GENERAL_SIMULATION_CONFIG = {
923
+ simulationYears: 25,
924
+ };
925
+
926
+ return types;
927
+ }
928
+
929
+ var hasRequiredSimulation$1;
930
+
931
+ function requireSimulation$1 () {
932
+ if (hasRequiredSimulation$1) return simulation;
933
+ hasRequiredSimulation$1 = 1;
934
+ Object.defineProperty(simulation, "__esModule", { value: true });
935
+ simulation.generateElectricCarChargingHours = generateElectricCarChargingHours;
936
+ simulation.simulateDay = simulateDay;
937
+ simulation.simulate = simulate;
938
+ const solarCurves_1 = /*@__PURE__*/ requireSolarCurves();
939
+ const types_1 = /*@__PURE__*/ requireTypes();
940
+ function generateElectricCarChargingHours(start, end) {
941
+ let hours = new Array(24).fill(false);
942
+ if (start < end) {
943
+ for (let i = start; i <= end; i++) {
944
+ hours[i] = true;
945
+ }
946
+ }
947
+ else {
948
+ for (let i = start; i <= 24; i++) {
949
+ hours[i] = true;
950
+ }
951
+ for (let i = 0; i <= end; i++) {
952
+ hours[i] = true;
953
+ }
954
+ }
955
+ return hours;
956
+ }
957
+ function simulateDay(production, consumption, dailyConsumption, battery) {
958
+ let batteryCharge = 0;
959
+ let soldEnergy = 0;
960
+ let energyUsageOfProduction = 0;
961
+ for (let hour = 0; hour < production.length; hour++) {
962
+ const energyDifference = production[hour] - consumption[hour];
963
+ if (energyDifference > 0) {
964
+ energyUsageOfProduction += consumption[hour];
965
+ if (batteryCharge < battery &&
966
+ batteryCharge + energyDifference <= battery) {
967
+ batteryCharge = batteryCharge + energyDifference;
968
+ }
969
+ else if (batteryCharge < battery) {
970
+ const batteryDifference = battery - batteryCharge;
971
+ batteryCharge = battery;
972
+ soldEnergy += energyDifference - batteryDifference;
973
+ }
974
+ else {
975
+ soldEnergy += energyDifference;
976
+ }
977
+ }
978
+ else {
979
+ if (batteryCharge > 0) {
980
+ if (batteryCharge >= -energyDifference) {
981
+ batteryCharge += energyDifference;
982
+ energyUsageOfProduction += consumption[hour];
983
+ }
984
+ else {
985
+ energyUsageOfProduction += production[hour] + batteryCharge;
986
+ batteryCharge = 0;
987
+ }
988
+ }
989
+ else {
990
+ energyUsageOfProduction += production[hour];
991
+ }
992
+ }
993
+ }
994
+ if (batteryCharge > 0) {
995
+ soldEnergy += batteryCharge;
996
+ }
997
+ const autonomy = energyUsageOfProduction / dailyConsumption;
998
+ return {
999
+ autonomy: autonomy > 1 ? 1 : autonomy,
1000
+ soldEnergy,
1001
+ energyUsageOfProduction,
1002
+ };
1003
+ }
1004
+ function simulate(config) {
1005
+ const generalConfig = Object.assign(Object.assign({}, types_1.DEFAULT_GENERAL_SIMULATION_CONFIG), config.general);
1006
+ const consumption = solarCurves_1.CONSUMPTION_PROFILES[config.householdConsumption.consumptionProfile];
1007
+ const norm = consumption.reduce((acc, curr) => acc + curr, 0);
1008
+ let additionalConsumption = 0;
1009
+ if (config.heatPump) {
1010
+ additionalConsumption =
1011
+ (config.heatPump.m2 || 0) * config.heatPump.consumptionPerM2 || 0;
1012
+ }
1013
+ let electricCarConsumption = 0;
1014
+ let electricCarNorm = 1;
1015
+ let electricCarChargingHours = consumption.map((_) => false);
1016
+ if (config.electricCar) {
1017
+ electricCarChargingHours = config.electricCar.chargingHours;
1018
+ const dailyCarUsage = config.electricCar.averageKilometersPerDay / 100 *
1019
+ config.electricCar.consumptionkWhPer100km;
1020
+ electricCarConsumption = Math.min(dailyCarUsage, config.electricCar.batteryKWh);
1021
+ electricCarNorm = config.electricCar.chargingHours.reduce((acc, curr) => acc + (curr ? 1 : 0), 0);
1022
+ if (electricCarNorm === 0) {
1023
+ electricCarNorm = 1;
1024
+ }
1025
+ }
1026
+ let systemSize = 0;
1027
+ if (config.solarSystems) {
1028
+ systemSize = Object.values(config.solarSystems).reduce((acc, curr) => {
1029
+ return acc + curr.numberOfPanels * curr.panelType.kWattPeak;
1030
+ }, 0);
1031
+ }
1032
+ else if (config.solarSystem) {
1033
+ console.warn("solarSystem is deprecated, use solarSystems instead");
1034
+ systemSize = config.solarSystem.numberOfPanels *
1035
+ config.solarSystem.panelType.kWattPeak;
1036
+ }
1037
+ else {
1038
+ throw new Error("No solar system found");
1039
+ }
1040
+ const summerProduction = (0, solarCurves_1.getSolarRadiation)(config.solarRadiation.summerFactor * systemSize);
1041
+ const winterProduction = (0, solarCurves_1.getSolarRadiation)(config.solarRadiation.winterFactor * systemSize);
1042
+ const summerConsumptionWholeDay = config.householdConsumption.averageConsumption *
1043
+ config.householdConsumption.summerConsumptionFactor +
1044
+ additionalConsumption *
1045
+ config.householdConsumption.summerConsumptionFactor;
1046
+ const summerConsumptionDaily = consumption.map((c, i) => c / norm * summerConsumptionWholeDay +
1047
+ electricCarConsumption / electricCarNorm *
1048
+ (electricCarChargingHours[i] ? 1 : 0));
1049
+ const winterConsumptionWholeDay = config.householdConsumption.averageConsumption *
1050
+ config.householdConsumption.winterConsumptionFactor +
1051
+ additionalConsumption *
1052
+ config.householdConsumption.winterConsumptionFactor;
1053
+ const winterConsumptionDaily = consumption.map((c, i) => c / norm * winterConsumptionWholeDay +
1054
+ electricCarConsumption / electricCarNorm *
1055
+ (electricCarChargingHours[i] ? 1 : 0));
1056
+ const summerDay = simulateDay(summerProduction, summerConsumptionDaily, summerConsumptionWholeDay + electricCarConsumption, config.batteryKWh);
1057
+ const winterDay = simulateDay(winterProduction, winterConsumptionDaily, winterConsumptionWholeDay + electricCarConsumption, config.batteryKWh);
1058
+ let savedCostsByYear = [];
1059
+ const soldEnergy = (summerDay.soldEnergy + winterDay.soldEnergy) / 2;
1060
+ const ownConsumption = (summerDay.energyUsageOfProduction +
1061
+ winterDay.energyUsageOfProduction) / 2;
1062
+ let energyPrice = config.electricityPrice.purchase;
1063
+ for (let i = 0; i < generalConfig.simulationYears; i++) {
1064
+ const savedCostsThisYear = ownConsumption * energyPrice * 365;
1065
+ savedCostsByYear.push(savedCostsThisYear);
1066
+ energyPrice = (1 + config.electricityPrice.increase) * energyPrice;
1067
+ }
1068
+ return {
1069
+ autonomy: (summerDay.autonomy + winterDay.autonomy) / 2,
1070
+ compensationPerDay: soldEnergy * config.electricityPrice.sell,
1071
+ byYearSavedCosts: savedCostsByYear,
1072
+ totalEnergyConsumptionDay: (summerConsumptionWholeDay + winterConsumptionWholeDay) / 2 +
1073
+ electricCarConsumption,
1074
+ };
1075
+ }
1076
+
1077
+ return simulation;
1078
+ }
1079
+
1080
+ var heatingSimulation = {};
1081
+
1082
+ var heatingConstants = {};
1083
+
1084
+ var hasRequiredHeatingConstants;
1085
+
1086
+ function requireHeatingConstants () {
1087
+ if (hasRequiredHeatingConstants) return heatingConstants;
1088
+ hasRequiredHeatingConstants = 1;
1089
+ Object.defineProperty(heatingConstants, "__esModule", { value: true });
1090
+ heatingConstants.SYSTEM_EFFICIENCY = heatingConstants.INSULATION_FACTORS = heatingConstants.EQUIPMENT_COSTS = heatingConstants.DISTRIBUTION_EFFICIENCY = heatingConstants.DISTRIBUTION_COSTS = heatingConstants.CO2_EMISSIONS = heatingConstants.CLIMATE_DATA = void 0;
1091
+ const CLIMATE_DATA = {
1092
+ "Zone 1": { heatingDegreeHours: 1200, coolingDegreeHours: 2800 },
1093
+ "Zone 2": { heatingDegreeHours: 1800, coolingDegreeHours: 2200 },
1094
+ "Zone 3": { heatingDegreeHours: 2400, coolingDegreeHours: 1800 },
1095
+ "Zone 4": { heatingDegreeHours: 3200, coolingDegreeHours: 1400 },
1096
+ "Zone 5": { heatingDegreeHours: 4200, coolingDegreeHours: 1000 },
1097
+ "Zone 6": { heatingDegreeHours: 5400, coolingDegreeHours: 600 },
1098
+ "Zone 7": { heatingDegreeHours: 6800, coolingDegreeHours: 300 },
1099
+ "Zone 8": { heatingDegreeHours: 8400, coolingDegreeHours: 100 },
1100
+ };
1101
+ heatingConstants.CLIMATE_DATA = CLIMATE_DATA;
1102
+ const INSULATION_FACTORS = {
1103
+ poor: 1.4,
1104
+ fair: 1.2,
1105
+ good: 1.0,
1106
+ excellent: 0.8,
1107
+ };
1108
+ heatingConstants.INSULATION_FACTORS = INSULATION_FACTORS;
1109
+ const CO2_EMISSIONS = {
1110
+ electricity: 0.855,
1111
+ gas: 11.7,
1112
+ oil: 22.4,
1113
+ };
1114
+ heatingConstants.CO2_EMISSIONS = CO2_EMISSIONS;
1115
+ const SYSTEM_EFFICIENCY = {
1116
+ "heat-pump": { heating: 3.2, cooling: 16 },
1117
+ "electric": { heating: 1.0, cooling: 0 },
1118
+ "gas": { heating: 0.85, cooling: 0 },
1119
+ "oil": { heating: 0.8, cooling: 0 },
1120
+ "split-ac": { heating: 2.8, cooling: 14 },
1121
+ "central-ac": { heating: 0, cooling: 13 },
1122
+ };
1123
+ heatingConstants.SYSTEM_EFFICIENCY = SYSTEM_EFFICIENCY;
1124
+ const DISTRIBUTION_EFFICIENCY = {
1125
+ "central-air": 0.85,
1126
+ "radiators": 0.9,
1127
+ "radiant-floor": 0.95,
1128
+ "radiant-ceiling": 0.92,
1129
+ };
1130
+ heatingConstants.DISTRIBUTION_EFFICIENCY = DISTRIBUTION_EFFICIENCY;
1131
+ const EQUIPMENT_COSTS = {
1132
+ "heat-pump": { base: 8000, perSqFt: 3 },
1133
+ "electric": { base: 2000, perSqFt: 1 },
1134
+ "gas": { base: 4000, perSqFt: 2 },
1135
+ "oil": { base: 5000, perSqFt: 2.5 },
1136
+ "split-ac": { base: 6000, perSqFt: 2.5 },
1137
+ "central-ac": { base: 7000, perSqFt: 3 },
1138
+ };
1139
+ heatingConstants.EQUIPMENT_COSTS = EQUIPMENT_COSTS;
1140
+ const DISTRIBUTION_COSTS = {
1141
+ "central-air": { base: 3000, perSqFt: 2 },
1142
+ "radiators": { base: 4000, perSqFt: 3 },
1143
+ "radiant-floor": { base: 8000, perSqFt: 6 },
1144
+ "radiant-ceiling": { base: 6000, perSqFt: 4 },
1145
+ };
1146
+ heatingConstants.DISTRIBUTION_COSTS = DISTRIBUTION_COSTS;
1147
+
1148
+ return heatingConstants;
1149
+ }
1150
+
1151
+ var hasRequiredHeatingSimulation;
1152
+
1153
+ function requireHeatingSimulation () {
1154
+ if (hasRequiredHeatingSimulation) return heatingSimulation;
1155
+ hasRequiredHeatingSimulation = 1;
1156
+ Object.defineProperty(heatingSimulation, "__esModule", { value: true });
1157
+ heatingSimulation.houseSchema = heatingSimulation.locationSchema = void 0;
1158
+ heatingSimulation.calculateHeatingSystemComparison = calculateHeatingSystemComparison;
1159
+ heatingSimulation.getDefaultUtilityRates = getDefaultUtilityRates;
1160
+ const heatingConstants_1 = /*@__PURE__*/ requireHeatingConstants();
1161
+ function calculateHeatLoss(house, location) {
1162
+ const climateData = heatingConstants_1.CLIMATE_DATA["Zone 1"];
1163
+ const baseHeatLoss = house.size * 30;
1164
+ const insulationFactor = heatingConstants_1.INSULATION_FACTORS[house.insulationLevel];
1165
+ const sharedWallFactor = 1 - (house.sharedWalls * 0.1);
1166
+ return baseHeatLoss * insulationFactor * sharedWallFactor *
1167
+ ((climateData === null || climateData === void 0 ? void 0 : climateData.heatingDegreeHours) || 3000) / 3000;
1168
+ }
1169
+ function calculateCoolingLoad(house, location) {
1170
+ const climateData = heatingConstants_1.CLIMATE_DATA["Zone 1"];
1171
+ const baseCoolingLoad = house.size * 25;
1172
+ const insulationFactor = heatingConstants_1.INSULATION_FACTORS[house.insulationLevel];
1173
+ return baseCoolingLoad * insulationFactor *
1174
+ ((climateData === null || climateData === void 0 ? void 0 : climateData.coolingDegreeHours) || 1500) / 1500;
1175
+ }
1176
+ function calculateEnergyConsumption(heatLoss, coolingLoad, system, hours) {
1177
+ const systemEff = heatingConstants_1.SYSTEM_EFFICIENCY[system.type];
1178
+ const distEff = heatingConstants_1.DISTRIBUTION_EFFICIENCY[system.distribution];
1179
+ const heatingEnergy = (heatLoss * hours) /
1180
+ (systemEff.heating * distEff * 3412);
1181
+ const coolingEnergy = (coolingLoad * hours) /
1182
+ (systemEff.cooling * distEff * 3412);
1183
+ return { heating: heatingEnergy, cooling: coolingEnergy };
1184
+ }
1185
+ function calculateCosts(energy, system, rates) {
1186
+ let cost = 0;
1187
+ if (system.type === "heat-pump" || system.type === "electric" ||
1188
+ system.type === "split-ac" || system.type === "central-ac") {
1189
+ cost = (energy.heating + energy.cooling) * rates.electricity;
1190
+ }
1191
+ else if (system.type === "gas") {
1192
+ cost = (energy.heating * 3412 / 100000) * rates.gas +
1193
+ energy.cooling * rates.electricity;
1194
+ }
1195
+ else if (system.type === "oil") {
1196
+ cost = (energy.heating * 3412 / 138690) * rates.oil +
1197
+ energy.cooling * rates.electricity;
1198
+ }
1199
+ return cost;
1200
+ }
1201
+ function calculateCO2Emissions(energy, system) {
1202
+ let emissions = 0;
1203
+ if (system.type === "heat-pump" || system.type === "electric" ||
1204
+ system.type === "split-ac" || system.type === "central-ac") {
1205
+ emissions = (energy.heating + energy.cooling) *
1206
+ heatingConstants_1.CO2_EMISSIONS.electricity;
1207
+ }
1208
+ else if (system.type === "gas") {
1209
+ emissions = (energy.heating * 3412 / 100000) * heatingConstants_1.CO2_EMISSIONS.gas +
1210
+ energy.cooling * heatingConstants_1.CO2_EMISSIONS.electricity;
1211
+ }
1212
+ else if (system.type === "oil") {
1213
+ emissions = (energy.heating * 3412 / 138690) * heatingConstants_1.CO2_EMISSIONS.oil +
1214
+ energy.cooling * heatingConstants_1.CO2_EMISSIONS.electricity;
1215
+ }
1216
+ return emissions;
1217
+ }
1218
+ function calculateSystemCosts(system, house) {
1219
+ const equipmentCost = heatingConstants_1.EQUIPMENT_COSTS[system.type];
1220
+ const distributionCost = heatingConstants_1.DISTRIBUTION_COSTS[system.distribution];
1221
+ const equipment = equipmentCost.base + (equipmentCost.perSqFt * house.size);
1222
+ const distribution = distributionCost.base +
1223
+ (distributionCost.perSqFt * house.size);
1224
+ const installation = (equipment + distribution) * 0.3;
1225
+ return {
1226
+ equipment: equipment + distribution,
1227
+ installation,
1228
+ total: equipment + distribution + installation,
1229
+ };
1230
+ }
1231
+ function calculateHeatingSystemComparison(input) {
1232
+ const heatLoss = calculateHeatLoss(input.house);
1233
+ const coolingLoad = calculateCoolingLoad(input.house);
1234
+ const operatingHours = 2000;
1235
+ const currentEnergy = calculateEnergyConsumption(heatLoss, coolingLoad, input.currentSystem, operatingHours);
1236
+ const currentCost = calculateCosts(currentEnergy, input.currentSystem, input.utilityRates);
1237
+ const currentCO2 = calculateCO2Emissions(currentEnergy, input.currentSystem);
1238
+ const proposedEnergy = calculateEnergyConsumption(heatLoss, coolingLoad, input.proposedSystem, operatingHours);
1239
+ const proposedCost = calculateCosts(proposedEnergy, input.proposedSystem, input.utilityRates);
1240
+ const proposedCO2 = calculateCO2Emissions(proposedEnergy, input.proposedSystem);
1241
+ const systemCosts = calculateSystemCosts(input.proposedSystem, input.house);
1242
+ const totalCurrentEnergy = currentEnergy.heating + currentEnergy.cooling;
1243
+ const totalProposedEnergy = proposedEnergy.heating + proposedEnergy.cooling;
1244
+ const energySavings = totalCurrentEnergy - totalProposedEnergy;
1245
+ const costSavings = currentCost - proposedCost;
1246
+ const co2Savings = currentCO2 - proposedCO2;
1247
+ const paybackPeriod = costSavings > 0
1248
+ ? systemCosts.total / costSavings
1249
+ : Infinity;
1250
+ return {
1251
+ energySavings: {
1252
+ annual: energySavings,
1253
+ percentage: (energySavings / totalCurrentEnergy) * 100,
1254
+ },
1255
+ co2Savings: {
1256
+ annual: co2Savings,
1257
+ percentage: (co2Savings / currentCO2) * 100,
1258
+ },
1259
+ costSavings: {
1260
+ annual: costSavings,
1261
+ monthlyAverage: costSavings / 12,
1262
+ percentage: (costSavings / currentCost) * 100,
1263
+ },
1264
+ newSystemCosts: {
1265
+ equipment: systemCosts.equipment,
1266
+ installation: systemCosts.installation,
1267
+ total: systemCosts.total,
1268
+ paybackPeriod,
1269
+ },
1270
+ efficiency: {
1271
+ current: heatingConstants_1.SYSTEM_EFFICIENCY[input.currentSystem.type].heating,
1272
+ proposed: heatingConstants_1.SYSTEM_EFFICIENCY[input.proposedSystem.type].heating,
1273
+ improvement: ((heatingConstants_1.SYSTEM_EFFICIENCY[input.proposedSystem.type].heating -
1274
+ heatingConstants_1.SYSTEM_EFFICIENCY[input.currentSystem.type].heating) /
1275
+ heatingConstants_1.SYSTEM_EFFICIENCY[input.currentSystem.type].heating) * 100,
1276
+ },
1277
+ };
1278
+ }
1279
+ function getDefaultUtilityRates(location) {
1280
+ const stateRates = {
1281
+ "CA": { electricity: 0.28, gas: 1.15, oil: 3.20 },
1282
+ "NY": { electricity: 0.20, gas: 1.05, oil: 3.10 },
1283
+ "TX": { electricity: 0.12, gas: 0.95, oil: 2.90 },
1284
+ "FL": { electricity: 0.14, gas: 1.20, oil: 3.00 },
1285
+ };
1286
+ return stateRates[location.address] ||
1287
+ { electricity: 0.16, gas: 1.00, oil: 3.00 };
1288
+ }
1289
+ heatingSimulation.locationSchema = {
1290
+ city: (value) => value.length > 0 ? null : "City is required",
1291
+ state: (value) => value.length > 0 ? null : "State is required",
1292
+ climateZone: (value) => Object.keys(heatingConstants_1.CLIMATE_DATA).includes(value)
1293
+ ? null
1294
+ : "Invalid climate zone",
1295
+ };
1296
+ heatingSimulation.houseSchema = {
1297
+ size: (value) => value > 0 && value < 50000
1298
+ ? null
1299
+ : "House size must be between 1 and 50,000 sq ft",
1300
+ sharedWalls: (value) => value >= 0 && value <= 4
1301
+ ? null
1302
+ : "Shared walls must be between 0 and 4",
1303
+ };
1304
+
1305
+ return heatingSimulation;
1306
+ }
1307
+
1308
+ var hasRequiredSimulation;
1309
+
1310
+ function requireSimulation () {
1311
+ if (hasRequiredSimulation) return simulation$1;
1312
+ hasRequiredSimulation = 1;
1313
+ (function (exports) {
1314
+ var __createBinding = (simulation$1 && simulation$1.__createBinding) || (Object.create ? (function(o, m, k, k2) {
1315
+ if (k2 === undefined) k2 = k;
1316
+ var desc = Object.getOwnPropertyDescriptor(m, k);
1317
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
1318
+ desc = { enumerable: true, get: function() { return m[k]; } };
1319
+ }
1320
+ Object.defineProperty(o, k2, desc);
1321
+ }) : (function(o, m, k, k2) {
1322
+ if (k2 === undefined) k2 = k;
1323
+ o[k2] = m[k];
1324
+ }));
1325
+ var __exportStar = (simulation$1 && simulation$1.__exportStar) || function(m, exports) {
1326
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
1327
+ };
1328
+ Object.defineProperty(exports, "__esModule", { value: true });
1329
+ __exportStar(/*@__PURE__*/ requireSimulation$1(), exports);
1330
+ __exportStar(/*@__PURE__*/ requireTypes(), exports);
1331
+ __exportStar(/*@__PURE__*/ requireHeatingSimulation(), exports);
1332
+
1333
+ } (simulation$1));
1334
+ return simulation$1;
1335
+ }
1336
+
1337
+ var hasRequiredDist;
1338
+
1339
+ function requireDist () {
1340
+ if (hasRequiredDist) return dist$1;
1341
+ hasRequiredDist = 1;
1342
+ (function (exports) {
1343
+ var __createBinding = (dist$1 && dist$1.__createBinding) || (Object.create ? (function(o, m, k, k2) {
1344
+ if (k2 === undefined) k2 = k;
1345
+ var desc = Object.getOwnPropertyDescriptor(m, k);
1346
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
1347
+ desc = { enumerable: true, get: function() { return m[k]; } };
1348
+ }
1349
+ Object.defineProperty(o, k2, desc);
1350
+ }) : (function(o, m, k, k2) {
1351
+ if (k2 === undefined) k2 = k;
1352
+ o[k2] = m[k];
1353
+ }));
1354
+ var __exportStar = (dist$1 && dist$1.__exportStar) || function(m, exports) {
1355
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
1356
+ };
1357
+ Object.defineProperty(exports, "__esModule", { value: true });
1358
+ __exportStar(/*@__PURE__*/ requireGeometry(), exports);
1359
+ __exportStar(/*@__PURE__*/ requireUtils(), exports);
1360
+ __exportStar(/*@__PURE__*/ requireSimulation(), exports);
1361
+
1362
+ } (dist$1));
1363
+ return dist$1;
1364
+ }
1365
+
1366
+ var distExports = /*@__PURE__*/ requireDist();
1367
+
1368
+ const DEFAULT_SOLAR_EXPERT_CONFIG = {
1369
+ openRoofColor: "#d6eeff",
1370
+ closedRoofColor: "#ffffff",
1371
+ openObstructionColor: "#f57242",
1372
+ closedObstructionColor: "rgba(255, 132, 107, 0.8)",
1373
+ roofPolygonFillColor: "rgba(92, 187, 255, 0.5)",
1374
+ obstructionPolygonFillColor: "rgba(255, 132, 107, 0.5)",
1375
+ roofPolygonHoverFillColor: "rgba(92, 187, 255, 0.8)",
1376
+ obstructionPolygonHoverFillColor: "rgba(255, 132, 107, 0.8)",
1377
+ roofPolygonSelectedFillColor: "rgba(92, 187, 255, 0.7)",
1378
+ obstructionPolygonSelectedFillColor: "rgba(255, 132, 107, 0.7)",
1379
+ highlightColor: "rgba(0, 89, 255, 1)",
1380
+ };
1381
+ const DEFAULT_SOLAR_PANEL_TYPE = {
1382
+ widthMeters: 1.134,
1383
+ heightMeters: 1.762,
1384
+ kWattPeak: 0.455,
1385
+ efficiency: 0.224,
1386
+ price: 77.68,
1387
+ };
1388
+ const DEFAULT_COLOR_SCHEME = {
1389
+ primary: "hsl(41 51% 90%)",
1390
+ primaryForeground: "hsl(0 0% 0%)",
1391
+ secondary: "hsl(28 100% 8%)",
1392
+ secondaryForeground: "hsl(0 0% 100%)",
1393
+ tertiary: "hsl(28 100% 29%)",
1394
+ tertiaryForeground: "hsl(0 0% 100%)",
1395
+ muted: "hsl(0 0% 100%)",
1396
+ mutedForeground: "hsl(0 0% 0%)",
1397
+ error: "hsl(0 100% 50%)",
1398
+ errorForeground: "hsl(0 0% 100%)",
1399
+ // Surface colors
1400
+ surface: "hsl(0 0% 88%)", // gray-200
1401
+ surfaceHover: "hsl(0 0% 82%)", // gray-300
1402
+ surfaceActive: "hsl(0 0% 64%)", // gray-400
1403
+ // Text colors
1404
+ textMuted: "hsl(0 0% 45%)", // gray-600
1405
+ textSecondary: "hsl(0 0% 55%)", // gray-500
1406
+ textPlaceholder: "hsl(0 0% 73%)", // gray-400
1407
+ // Border colors
1408
+ border: "hsl(0 0% 82%)", // gray-300
1409
+ borderLight: "hsl(0 0% 93%)", // gray-200
1410
+ // Status colors
1411
+ success: "hsl(142 76% 36%)", // green-600
1412
+ info: "hsl(221 83% 53%)", // blue-500
1413
+ // Interactive colors
1414
+ hover: "hsl(0 0% 88%)", // gray-200
1415
+ hoverDark: "hsl(28 100% 8%)", // darker secondary for hover
1416
+ overlay: "rgba(0, 0, 0, 0.24)", // #0000003c
1417
+ tooltip: "hsl(0 0% 13%)", // gray-800
1418
+ };
1419
+
1420
+ const BORDER_INSET = 0;
1421
+ const HEAT_PUMP_CONSUMPTION = 46; // kWh per m² per year
1422
+
1423
+ async function sendLeadToNexvoro(leadData) {
1424
+ try {
1425
+ const extradata = {
1426
+ leadtype: "A-lead",
1427
+ phase: "10 Anbahnung",
1428
+ title: `${leadData.client.name}/solarExpert`,
1429
+ extradata: leadData,
1430
+ };
1431
+ const formData = new FormData();
1432
+ formData.append("md", "81.87.84.89.90.");
1433
+ formData.append("token", "rdwetayarqzwtdsqystyraa");
1434
+ formData.append("type", "new");
1435
+ formData.append("data", "lead");
1436
+ formData.append("values", JSON.stringify(extradata));
1437
+ // Build the URL
1438
+ const baseUrl = "https://workspace.nexvoro.cloud/exchange/extevent";
1439
+ const url = baseUrl;
1440
+ // Send the request with FormData to avoid CORS preflight
1441
+ const response = await fetch(url, {
1442
+ method: "POST",
1443
+ body: formData,
1444
+ // No custom headers to avoid preflight request
1445
+ });
1446
+ if (!response.ok) {
1447
+ const errorText = await response.text();
1448
+ console.error("Error sending lead to Nexvoro:", response.status, errorText);
1449
+ throw new Error(`HTTP error! status: ${response.status}, body: ${errorText}`);
1450
+ }
1451
+ const result = await response.text();
1452
+ console.log("result", result);
1453
+ // Check if the response contains a lead ID (successful creation)
1454
+ if (result.includes("ERROR")) {
1455
+ return {
1456
+ success: false,
1457
+ message: "Lead not created",
1458
+ leadId: result,
1459
+ };
1460
+ }
1461
+ else {
1462
+ return {
1463
+ success: true,
1464
+ message: "Lead submitted successfully",
1465
+ leadId: undefined,
1466
+ };
1467
+ }
1468
+ }
1469
+ catch (error) {
1470
+ console.error("Error sending lead to Nexvoro:", error);
1471
+ return {
1472
+ success: false,
1473
+ message: error instanceof Error
1474
+ ? error.message
1475
+ : "Unknown error occurred",
1476
+ };
1477
+ }
1478
+ }
1479
+
1480
+ const outputCss = "/*! tailwindcss v4.1.11 | MIT License | https://tailwindcss.com */\n@layer properties;\n@layer theme, base, components, utilities;\n@layer theme {\n :root, :host {\n --font-sans: ui-sans-serif, system-ui, sans-serif, \"Apple Color Emoji\",\n \"Segoe UI Emoji\", \"Segoe UI Symbol\", \"Noto Color Emoji\";\n --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, \"Liberation Mono\",\n \"Courier New\", monospace;\n --color-red-100: oklch(93.6% 0.032 17.717);\n --color-red-300: oklch(80.8% 0.114 19.571);\n --color-red-700: oklch(50.5% 0.213 27.518);\n --color-gray-400: oklch(70.7% 0.022 261.325);\n --color-gray-800: oklch(27.8% 0.033 256.848);\n --color-black: #000;\n --color-white: #fff;\n --spacing: 0.25rem;\n --container-md: 28rem;\n --container-2xl: 42rem;\n --text-xs: 0.75rem;\n --text-xs--line-height: calc(1 / 0.75);\n --text-sm: 0.875rem;\n --text-sm--line-height: calc(1.25 / 0.875);\n --text-lg: 1.125rem;\n --text-lg--line-height: calc(1.75 / 1.125);\n --text-xl: 1.25rem;\n --text-xl--line-height: calc(1.75 / 1.25);\n --text-2xl: 1.5rem;\n --text-2xl--line-height: calc(2 / 1.5);\n --font-weight-medium: 500;\n --font-weight-semibold: 600;\n --font-weight-bold: 700;\n --radius-lg: 0.5rem;\n --radius-4xl: 2rem;\n --animate-spin: spin 1s linear infinite;\n --default-transition-duration: 150ms;\n --default-transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);\n --default-font-family: var(--font-sans);\n --default-mono-font-family: var(--font-mono);\n --color-primary: hsl(41 51% 90%);\n --color-primary-foreground: hsl(0 0% 0%);\n --color-secondary: hsl(28 100% 8%);\n --color-secondary-foreground: hsl(0 0% 100%);\n --color-tertiary: hsl(28 100% 29%);\n --color-tertiary-foreground: hsl(0 0% 100%);\n --color-muted: hsl(0 0% 100%);\n --color-muted-foreground: hsl(0 0% 0%);\n --color-error: hsl(0 100% 50%);\n --color-error-foreground: hsl(0 0% 100%);\n --color-surface: hsl(0 0% 88%);\n --color-surface-hover: hsl(0 0% 82%);\n --color-surface-active: hsl(0 0% 64%);\n --color-text-muted: hsl(0 0% 45%);\n --color-text-secondary: hsl(0 0% 55%);\n --color-text-placeholder: hsl(0 0% 73%);\n --color-border: hsl(0 0% 82%);\n --color-border-light: hsl(0 0% 93%);\n --color-success: hsl(142 76% 36%);\n --color-info: hsl(221 83% 53%);\n --color-hover: hsl(0 0% 88%);\n --color-hover-dark: hsl(28 100% 8%);\n --color-overlay: rgba(0, 0, 0, 0.24);\n --color-tooltip: hsl(0 0% 13%);\n }\n}\n@layer base {\n *, ::after, ::before, ::backdrop, ::file-selector-button {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n border: 0 solid;\n }\n html, :host {\n line-height: 1.5;\n -webkit-text-size-adjust: 100%;\n tab-size: 4;\n font-family: var(--default-font-family, ui-sans-serif, system-ui, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\", \"Noto Color Emoji\");\n font-feature-settings: var(--default-font-feature-settings, normal);\n font-variation-settings: var(--default-font-variation-settings, normal);\n -webkit-tap-highlight-color: transparent;\n }\n hr {\n height: 0;\n color: inherit;\n border-top-width: 1px;\n }\n abbr:where([title]) {\n -webkit-text-decoration: underline dotted;\n text-decoration: underline dotted;\n }\n h1, h2, h3, h4, h5, h6 {\n font-size: inherit;\n font-weight: inherit;\n }\n a {\n color: inherit;\n -webkit-text-decoration: inherit;\n text-decoration: inherit;\n }\n b, strong {\n font-weight: bolder;\n }\n code, kbd, samp, pre {\n font-family: var(--default-mono-font-family, ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, \"Liberation Mono\", \"Courier New\", monospace);\n font-feature-settings: var(--default-mono-font-feature-settings, normal);\n font-variation-settings: var(--default-mono-font-variation-settings, normal);\n font-size: 1em;\n }\n small {\n font-size: 80%;\n }\n sub, sup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n }\n sub {\n bottom: -0.25em;\n }\n sup {\n top: -0.5em;\n }\n table {\n text-indent: 0;\n border-color: inherit;\n border-collapse: collapse;\n }\n :-moz-focusring {\n outline: auto;\n }\n progress {\n vertical-align: baseline;\n }\n summary {\n display: list-item;\n }\n ol, ul, menu {\n list-style: none;\n }\n img, svg, video, canvas, audio, iframe, embed, object {\n display: block;\n vertical-align: middle;\n }\n img, video {\n max-width: 100%;\n height: auto;\n }\n button, input, select, optgroup, textarea, ::file-selector-button {\n font: inherit;\n font-feature-settings: inherit;\n font-variation-settings: inherit;\n letter-spacing: inherit;\n color: inherit;\n border-radius: 0;\n background-color: transparent;\n opacity: 1;\n }\n :where(select:is([multiple], [size])) optgroup {\n font-weight: bolder;\n }\n :where(select:is([multiple], [size])) optgroup option {\n padding-inline-start: 20px;\n }\n ::file-selector-button {\n margin-inline-end: 4px;\n }\n ::placeholder {\n opacity: 1;\n }\n @supports (not (-webkit-appearance: -apple-pay-button)) or (contain-intrinsic-size: 1px) {\n ::placeholder {\n color: currentcolor;\n @supports (color: color-mix(in lab, red, red)) {\n color: color-mix(in oklab, currentcolor 50%, transparent);\n }\n }\n }\n textarea {\n resize: vertical;\n }\n ::-webkit-search-decoration {\n -webkit-appearance: none;\n }\n ::-webkit-date-and-time-value {\n min-height: 1lh;\n text-align: inherit;\n }\n ::-webkit-datetime-edit {\n display: inline-flex;\n }\n ::-webkit-datetime-edit-fields-wrapper {\n padding: 0;\n }\n ::-webkit-datetime-edit, ::-webkit-datetime-edit-year-field, ::-webkit-datetime-edit-month-field, ::-webkit-datetime-edit-day-field, ::-webkit-datetime-edit-hour-field, ::-webkit-datetime-edit-minute-field, ::-webkit-datetime-edit-second-field, ::-webkit-datetime-edit-millisecond-field, ::-webkit-datetime-edit-meridiem-field {\n padding-block: 0;\n }\n :-moz-ui-invalid {\n box-shadow: none;\n }\n button, input:where([type=\"button\"], [type=\"reset\"], [type=\"submit\"]), ::file-selector-button {\n appearance: button;\n }\n ::-webkit-inner-spin-button, ::-webkit-outer-spin-button {\n height: auto;\n }\n [hidden]:where(:not([hidden=\"until-found\"])) {\n display: none !important;\n }\n}\n@layer utilities {\n .pointer-events-none {\n pointer-events: none;\n }\n .absolute {\n position: absolute;\n }\n .fixed {\n position: fixed;\n }\n .relative {\n position: relative;\n }\n .inset-0 {\n inset: calc(var(--spacing) * 0);\n }\n .top-0 {\n top: calc(var(--spacing) * 0);\n }\n .top-1 {\n top: calc(var(--spacing) * 1);\n }\n .top-1\\/2 {\n top: calc(1/2 * 100%);\n }\n .top-full {\n top: 100%;\n }\n .bottom-full {\n bottom: 100%;\n }\n .left-0 {\n left: calc(var(--spacing) * 0);\n }\n .left-1 {\n left: calc(var(--spacing) * 1);\n }\n .left-1\\/2 {\n left: calc(1/2 * 100%);\n }\n .left-3 {\n left: calc(var(--spacing) * 3);\n }\n .z-10 {\n z-index: 10;\n }\n .z-20 {\n z-index: 20;\n }\n .z-50 {\n z-index: 50;\n }\n .container {\n width: 100%;\n @media (width >= 40rem) {\n max-width: 40rem;\n }\n @media (width >= 48rem) {\n max-width: 48rem;\n }\n @media (width >= 64rem) {\n max-width: 64rem;\n }\n @media (width >= 80rem) {\n max-width: 80rem;\n }\n @media (width >= 96rem) {\n max-width: 96rem;\n }\n }\n .m-auto {\n margin: auto;\n }\n .mt-1 {\n margin-top: calc(var(--spacing) * 1);\n }\n .mt-4 {\n margin-top: calc(var(--spacing) * 4);\n }\n .mt-6 {\n margin-top: calc(var(--spacing) * 6);\n }\n .mb-1 {\n margin-bottom: calc(var(--spacing) * 1);\n }\n .mb-2 {\n margin-bottom: calc(var(--spacing) * 2);\n }\n .mb-4 {\n margin-bottom: calc(var(--spacing) * 4);\n }\n .mb-6 {\n margin-bottom: calc(var(--spacing) * 6);\n }\n .block {\n display: block;\n }\n .flex {\n display: flex;\n }\n .grid {\n display: grid;\n }\n .inline {\n display: inline;\n }\n .inline-block {\n display: inline-block;\n }\n .table {\n display: table;\n }\n .h-0 {\n height: calc(var(--spacing) * 0);\n }\n .h-4 {\n height: calc(var(--spacing) * 4);\n }\n .h-16 {\n height: calc(var(--spacing) * 16);\n }\n .h-48 {\n height: calc(var(--spacing) * 48);\n }\n .h-64 {\n height: calc(var(--spacing) * 64);\n }\n .h-96 {\n height: calc(var(--spacing) * 96);\n }\n .h-\\[400px\\] {\n height: 400px;\n }\n .h-full {\n height: 100%;\n }\n .max-h-96 {\n max-height: calc(var(--spacing) * 96);\n }\n .max-h-full {\n max-height: 100%;\n }\n .w-0 {\n width: calc(var(--spacing) * 0);\n }\n .w-4 {\n width: calc(var(--spacing) * 4);\n }\n .w-16 {\n width: calc(var(--spacing) * 16);\n }\n .w-20 {\n width: calc(var(--spacing) * 20);\n }\n .w-48 {\n width: calc(var(--spacing) * 48);\n }\n .w-64 {\n width: calc(var(--spacing) * 64);\n }\n .w-96 {\n width: calc(var(--spacing) * 96);\n }\n .w-auto {\n width: auto;\n }\n .w-full {\n width: 100%;\n }\n .max-w-2xl {\n max-width: var(--container-2xl);\n }\n .max-w-md {\n max-width: var(--container-md);\n }\n .flex-1 {\n flex: 1;\n }\n .flex-3 {\n flex: 3;\n }\n .border-collapse {\n border-collapse: collapse;\n }\n .-translate-y-1 {\n --tw-translate-y: calc(var(--spacing) * -1);\n translate: var(--tw-translate-x) var(--tw-translate-y);\n }\n .-translate-y-1\\/2 {\n --tw-translate-y: calc(calc(1/2 * 100%) * -1);\n translate: var(--tw-translate-x) var(--tw-translate-y);\n }\n .transform {\n transform: var(--tw-rotate-x,) var(--tw-rotate-y,) var(--tw-rotate-z,) var(--tw-skew-x,) var(--tw-skew-y,);\n }\n .animate-spin {\n animation: var(--animate-spin);\n }\n .cursor-not-allowed {\n cursor: not-allowed;\n }\n .resize {\n resize: both;\n }\n .appearance-none {\n appearance: none;\n }\n .grid-cols-2 {\n grid-template-columns: repeat(2, minmax(0, 1fr));\n }\n .grid-rows-2 {\n grid-template-rows: repeat(2, minmax(0, 1fr));\n }\n .flex-col {\n flex-direction: column;\n }\n .flex-row {\n flex-direction: row;\n }\n .flex-wrap {\n flex-wrap: wrap;\n }\n .items-center {\n align-items: center;\n }\n .items-start {\n align-items: flex-start;\n }\n .items-stretch {\n align-items: stretch;\n }\n .justify-between {\n justify-content: space-between;\n }\n .justify-center {\n justify-content: center;\n }\n .justify-end {\n justify-content: flex-end;\n }\n .justify-start {\n justify-content: flex-start;\n }\n .gap-0 {\n gap: calc(var(--spacing) * 0);\n }\n .gap-1 {\n gap: calc(var(--spacing) * 1);\n }\n .gap-2 {\n gap: calc(var(--spacing) * 2);\n }\n .gap-4 {\n gap: calc(var(--spacing) * 4);\n }\n .space-y-3 {\n :where(& > :not(:last-child)) {\n --tw-space-y-reverse: 0;\n margin-block-start: calc(calc(var(--spacing) * 3) * var(--tw-space-y-reverse));\n margin-block-end: calc(calc(var(--spacing) * 3) * calc(1 - var(--tw-space-y-reverse)));\n }\n }\n .space-y-4 {\n :where(& > :not(:last-child)) {\n --tw-space-y-reverse: 0;\n margin-block-start: calc(calc(var(--spacing) * 4) * var(--tw-space-y-reverse));\n margin-block-end: calc(calc(var(--spacing) * 4) * calc(1 - var(--tw-space-y-reverse)));\n }\n }\n .space-y-6 {\n :where(& > :not(:last-child)) {\n --tw-space-y-reverse: 0;\n margin-block-start: calc(calc(var(--spacing) * 6) * var(--tw-space-y-reverse));\n margin-block-end: calc(calc(var(--spacing) * 6) * calc(1 - var(--tw-space-y-reverse)));\n }\n }\n .overflow-hidden {\n overflow: hidden;\n }\n .overflow-y-auto {\n overflow-y: auto;\n }\n .rounded {\n border-radius: 0.25rem;\n }\n .rounded-4xl {\n border-radius: var(--radius-4xl);\n }\n .rounded-full {\n border-radius: calc(infinity * 1px);\n }\n .rounded-lg {\n border-radius: var(--radius-lg);\n }\n .border {\n border-style: var(--tw-border-style);\n border-width: 1px;\n }\n .border-2 {\n border-style: var(--tw-border-style);\n border-width: 2px;\n }\n .border-t-2 {\n border-top-style: var(--tw-border-style);\n border-top-width: 2px;\n }\n .border-t-4 {\n border-top-style: var(--tw-border-style);\n border-top-width: 4px;\n }\n .border-r-4 {\n border-right-style: var(--tw-border-style);\n border-right-width: 4px;\n }\n .border-b-2 {\n border-bottom-style: var(--tw-border-style);\n border-bottom-width: 2px;\n }\n .border-b-4 {\n border-bottom-style: var(--tw-border-style);\n border-bottom-width: 4px;\n }\n .border-l-4 {\n border-left-style: var(--tw-border-style);\n border-left-width: 4px;\n }\n .border-border {\n border-color: var(--color-border);\n }\n .border-current {\n border-color: currentcolor;\n }\n .border-error {\n border-color: var(--color-error);\n }\n .border-error\\/20 {\n border-color: color-mix(in srgb, hsl(0 100% 50%) 20%, transparent);\n @supports (color: color-mix(in lab, red, red)) {\n border-color: color-mix(in oklab, var(--color-error) 20%, transparent);\n }\n }\n .border-red-300 {\n border-color: var(--color-red-300);\n }\n .border-secondary {\n border-color: var(--color-secondary);\n }\n .border-secondary\\/20 {\n border-color: color-mix(in srgb, hsl(28 100% 8%) 20%, transparent);\n @supports (color: color-mix(in lab, red, red)) {\n border-color: color-mix(in oklab, var(--color-secondary) 20%, transparent);\n }\n }\n .border-success {\n border-color: var(--color-success);\n }\n .border-success\\/20 {\n border-color: color-mix(in srgb, hsl(142 76% 36%) 20%, transparent);\n @supports (color: color-mix(in lab, red, red)) {\n border-color: color-mix(in oklab, var(--color-success) 20%, transparent);\n }\n }\n .border-transparent {\n border-color: transparent;\n }\n .border-t-gray-800 {\n border-top-color: var(--color-gray-800);\n }\n .border-t-transparent {\n border-top-color: transparent;\n }\n .border-b-gray-800 {\n border-bottom-color: var(--color-gray-800);\n }\n .bg-black {\n background-color: var(--color-black);\n }\n .bg-error {\n background-color: var(--color-error);\n }\n .bg-error\\/10 {\n background-color: color-mix(in srgb, hsl(0 100% 50%) 10%, transparent);\n @supports (color: color-mix(in lab, red, red)) {\n background-color: color-mix(in oklab, var(--color-error) 10%, transparent);\n }\n }\n .bg-gray-400 {\n background-color: var(--color-gray-400);\n }\n .bg-gray-800 {\n background-color: var(--color-gray-800);\n }\n .bg-muted {\n background-color: var(--color-muted);\n }\n .bg-overlay {\n background-color: var(--color-overlay);\n }\n .bg-primary {\n background-color: var(--color-primary);\n }\n .bg-red-100 {\n background-color: var(--color-red-100);\n }\n .bg-secondary {\n background-color: var(--color-secondary);\n }\n .bg-success {\n background-color: var(--color-success);\n }\n .bg-success\\/10 {\n background-color: color-mix(in srgb, hsl(142 76% 36%) 10%, transparent);\n @supports (color: color-mix(in lab, red, red)) {\n background-color: color-mix(in oklab, var(--color-success) 10%, transparent);\n }\n }\n .bg-surface {\n background-color: var(--color-surface);\n }\n .bg-tertiary {\n background-color: var(--color-tertiary);\n }\n .bg-text-secondary {\n background-color: var(--color-text-secondary);\n }\n .bg-transparent {\n background-color: transparent;\n }\n .object-contain {\n object-fit: contain;\n }\n .p-2 {\n padding: calc(var(--spacing) * 2);\n }\n .p-3 {\n padding: calc(var(--spacing) * 3);\n }\n .p-4 {\n padding: calc(var(--spacing) * 4);\n }\n .p-6 {\n padding: calc(var(--spacing) * 6);\n }\n .px-2 {\n padding-inline: calc(var(--spacing) * 2);\n }\n .px-3 {\n padding-inline: calc(var(--spacing) * 3);\n }\n .px-4 {\n padding-inline: calc(var(--spacing) * 4);\n }\n .px-6 {\n padding-inline: calc(var(--spacing) * 6);\n }\n .py-1 {\n padding-block: calc(var(--spacing) * 1);\n }\n .py-2 {\n padding-block: calc(var(--spacing) * 2);\n }\n .py-3 {\n padding-block: calc(var(--spacing) * 3);\n }\n .py-4 {\n padding-block: calc(var(--spacing) * 4);\n }\n .pt-3 {\n padding-top: calc(var(--spacing) * 3);\n }\n .pt-4 {\n padding-top: calc(var(--spacing) * 4);\n }\n .pt-7 {\n padding-top: calc(var(--spacing) * 7);\n }\n .pr-3 {\n padding-right: calc(var(--spacing) * 3);\n }\n .pr-4 {\n padding-right: calc(var(--spacing) * 4);\n }\n .pb-2 {\n padding-bottom: calc(var(--spacing) * 2);\n }\n .pb-3 {\n padding-bottom: calc(var(--spacing) * 3);\n }\n .pb-4 {\n padding-bottom: calc(var(--spacing) * 4);\n }\n .pl-2 {\n padding-left: calc(var(--spacing) * 2);\n }\n .pl-3 {\n padding-left: calc(var(--spacing) * 3);\n }\n .pl-4 {\n padding-left: calc(var(--spacing) * 4);\n }\n .pl-10 {\n padding-left: calc(var(--spacing) * 10);\n }\n .text-center {\n text-align: center;\n }\n .text-right {\n text-align: right;\n }\n .text-2xl {\n font-size: var(--text-2xl);\n line-height: var(--tw-leading, var(--text-2xl--line-height));\n }\n .text-lg {\n font-size: var(--text-lg);\n line-height: var(--tw-leading, var(--text-lg--line-height));\n }\n .text-sm {\n font-size: var(--text-sm);\n line-height: var(--tw-leading, var(--text-sm--line-height));\n }\n .text-xl {\n font-size: var(--text-xl);\n line-height: var(--tw-leading, var(--text-xl--line-height));\n }\n .text-xs {\n font-size: var(--text-xs);\n line-height: var(--tw-leading, var(--text-xs--line-height));\n }\n .font-bold {\n --tw-font-weight: var(--font-weight-bold);\n font-weight: var(--font-weight-bold);\n }\n .font-medium {\n --tw-font-weight: var(--font-weight-medium);\n font-weight: var(--font-weight-medium);\n }\n .font-semibold {\n --tw-font-weight: var(--font-weight-semibold);\n font-weight: var(--font-weight-semibold);\n }\n .whitespace-nowrap {\n white-space: nowrap;\n }\n .text-error {\n color: var(--color-error);\n }\n .text-muted {\n color: var(--color-muted);\n }\n .text-muted-foreground {\n color: var(--color-muted-foreground);\n }\n .text-primary-foreground {\n color: var(--color-primary-foreground);\n }\n .text-red-700 {\n color: var(--color-red-700);\n }\n .text-secondary {\n color: var(--color-secondary);\n }\n .text-success {\n color: var(--color-success);\n }\n .text-text-muted {\n color: var(--color-text-muted);\n }\n .text-text-placeholder {\n color: var(--color-text-placeholder);\n }\n .text-text-secondary {\n color: var(--color-text-secondary);\n }\n .text-white {\n color: var(--color-white);\n }\n .underline {\n text-decoration-line: underline;\n }\n .accent-tertiary {\n accent-color: var(--color-tertiary);\n }\n .shadow {\n --tw-shadow: 0 1px 3px 0 var(--tw-shadow-color, rgb(0 0 0 / 0.1)), 0 1px 2px -1px var(--tw-shadow-color, rgb(0 0 0 / 0.1));\n box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);\n }\n .shadow-lg {\n --tw-shadow: 0 10px 15px -3px var(--tw-shadow-color, rgb(0 0 0 / 0.1)), 0 4px 6px -4px var(--tw-shadow-color, rgb(0 0 0 / 0.1));\n box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);\n }\n .outline {\n outline-style: var(--tw-outline-style);\n outline-width: 1px;\n }\n .transition {\n transition-property: color, background-color, border-color, outline-color, text-decoration-color, fill, stroke, --tw-gradient-from, --tw-gradient-via, --tw-gradient-to, opacity, box-shadow, transform, translate, scale, rotate, filter, -webkit-backdrop-filter, backdrop-filter, display, visibility, content-visibility, overlay, pointer-events;\n transition-timing-function: var(--tw-ease, var(--default-transition-timing-function));\n transition-duration: var(--tw-duration, var(--default-transition-duration));\n }\n .transition-colors {\n transition-property: color, background-color, border-color, outline-color, text-decoration-color, fill, stroke, --tw-gradient-from, --tw-gradient-via, --tw-gradient-to;\n transition-timing-function: var(--tw-ease, var(--default-transition-timing-function));\n transition-duration: var(--tw-duration, var(--default-transition-duration));\n }\n .duration-200 {\n --tw-duration: 200ms;\n transition-duration: 200ms;\n }\n .hover\\:border-secondary\\/40 {\n &:hover {\n @media (hover: hover) {\n border-color: color-mix(in srgb, hsl(28 100% 8%) 40%, transparent);\n @supports (color: color-mix(in lab, red, red)) {\n border-color: color-mix(in oklab, var(--color-secondary) 40%, transparent);\n }\n }\n }\n }\n .hover\\:bg-hover {\n &:hover {\n @media (hover: hover) {\n background-color: var(--color-hover);\n }\n }\n }\n .hover\\:bg-muted {\n &:hover {\n @media (hover: hover) {\n background-color: var(--color-muted);\n }\n }\n }\n .hover\\:bg-overlay {\n &:hover {\n @media (hover: hover) {\n background-color: var(--color-overlay);\n }\n }\n }\n .hover\\:bg-secondary\\/80 {\n &:hover {\n @media (hover: hover) {\n background-color: color-mix(in srgb, hsl(28 100% 8%) 80%, transparent);\n @supports (color: color-mix(in lab, red, red)) {\n background-color: color-mix(in oklab, var(--color-secondary) 80%, transparent);\n }\n }\n }\n }\n .hover\\:bg-surface-hover {\n &:hover {\n @media (hover: hover) {\n background-color: var(--color-surface-hover);\n }\n }\n }\n .hover\\:bg-tertiary {\n &:hover {\n @media (hover: hover) {\n background-color: var(--color-tertiary);\n }\n }\n }\n .hover\\:bg-tertiary\\/80 {\n &:hover {\n @media (hover: hover) {\n background-color: color-mix(in srgb, hsl(28 100% 29%) 80%, transparent);\n @supports (color: color-mix(in lab, red, red)) {\n background-color: color-mix(in oklab, var(--color-tertiary) 80%, transparent);\n }\n }\n }\n }\n .hover\\:bg-text-secondary {\n &:hover {\n @media (hover: hover) {\n background-color: var(--color-text-secondary);\n }\n }\n }\n .focus\\:border-2 {\n &:focus {\n border-style: var(--tw-border-style);\n border-width: 2px;\n }\n }\n .focus\\:border-secondary {\n &:focus {\n border-color: var(--color-secondary);\n }\n }\n .focus\\:border-transparent {\n &:focus {\n border-color: transparent;\n }\n }\n .focus\\:ring-2 {\n &:focus {\n --tw-ring-shadow: var(--tw-ring-inset,) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color, currentcolor);\n box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);\n }\n }\n .focus\\:ring-info {\n &:focus {\n --tw-ring-color: var(--color-info);\n }\n }\n .focus\\:ring-secondary {\n &:focus {\n --tw-ring-color: var(--color-secondary);\n }\n }\n .focus\\:ring-tertiary {\n &:focus {\n --tw-ring-color: var(--color-tertiary);\n }\n }\n .focus\\:ring-offset-0 {\n &:focus {\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-shadow: var(--tw-ring-inset,) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);\n }\n }\n .focus\\:outline-none {\n &:focus {\n --tw-outline-style: none;\n outline-style: none;\n }\n }\n .sm\\:mt-0 {\n @media (width >= 40rem) {\n margin-top: calc(var(--spacing) * 0);\n }\n }\n .sm\\:flex-3 {\n @media (width >= 40rem) {\n flex: 3;\n }\n }\n .sm\\:flex-row {\n @media (width >= 40rem) {\n flex-direction: row;\n }\n }\n .sm\\:items-center {\n @media (width >= 40rem) {\n align-items: center;\n }\n }\n .sm\\:gap-4 {\n @media (width >= 40rem) {\n gap: calc(var(--spacing) * 4);\n }\n }\n .md\\:justify-between {\n @media (width >= 48rem) {\n justify-content: space-between;\n }\n }\n .lg\\:gap-4 {\n @media (width >= 64rem) {\n gap: calc(var(--spacing) * 4);\n }\n }\n .\\[\\&\\:\\:-webkit-slider-runnable-track\\]\\:rounded-full {\n &::-webkit-slider-runnable-track {\n border-radius: calc(infinity * 1px);\n }\n }\n .\\[\\&\\:\\:-webkit-slider-runnable-track\\]\\:bg-black\\/25 {\n &::-webkit-slider-runnable-track {\n background-color: color-mix(in srgb, #000 25%, transparent);\n @supports (color: color-mix(in lab, red, red)) {\n background-color: color-mix(in oklab, var(--color-black) 25%, transparent);\n }\n }\n }\n .\\[\\&\\:\\:-webkit-slider-thumb\\]\\:h-\\[10px\\] {\n &::-webkit-slider-thumb {\n height: 10px;\n }\n }\n .\\[\\&\\:\\:-webkit-slider-thumb\\]\\:w-\\[10px\\] {\n &::-webkit-slider-thumb {\n width: 10px;\n }\n }\n .\\[\\&\\:\\:-webkit-slider-thumb\\]\\:appearance-none {\n &::-webkit-slider-thumb {\n appearance: none;\n }\n }\n .\\[\\&\\:\\:-webkit-slider-thumb\\]\\:rounded-full {\n &::-webkit-slider-thumb {\n border-radius: calc(infinity * 1px);\n }\n }\n .\\[\\&\\:\\:-webkit-slider-thumb\\]\\:bg-muted {\n &::-webkit-slider-thumb {\n background-color: var(--color-muted);\n }\n }\n}\n@property --tw-translate-x {\n syntax: \"*\";\n inherits: false;\n initial-value: 0;\n}\n@property --tw-translate-y {\n syntax: \"*\";\n inherits: false;\n initial-value: 0;\n}\n@property --tw-translate-z {\n syntax: \"*\";\n inherits: false;\n initial-value: 0;\n}\n@property --tw-rotate-x {\n syntax: \"*\";\n inherits: false;\n}\n@property --tw-rotate-y {\n syntax: \"*\";\n inherits: false;\n}\n@property --tw-rotate-z {\n syntax: \"*\";\n inherits: false;\n}\n@property --tw-skew-x {\n syntax: \"*\";\n inherits: false;\n}\n@property --tw-skew-y {\n syntax: \"*\";\n inherits: false;\n}\n@property --tw-space-y-reverse {\n syntax: \"*\";\n inherits: false;\n initial-value: 0;\n}\n@property --tw-border-style {\n syntax: \"*\";\n inherits: false;\n initial-value: solid;\n}\n@property --tw-font-weight {\n syntax: \"*\";\n inherits: false;\n}\n@property --tw-shadow {\n syntax: \"*\";\n inherits: false;\n initial-value: 0 0 #0000;\n}\n@property --tw-shadow-color {\n syntax: \"*\";\n inherits: false;\n}\n@property --tw-shadow-alpha {\n syntax: \"<percentage>\";\n inherits: false;\n initial-value: 100%;\n}\n@property --tw-inset-shadow {\n syntax: \"*\";\n inherits: false;\n initial-value: 0 0 #0000;\n}\n@property --tw-inset-shadow-color {\n syntax: \"*\";\n inherits: false;\n}\n@property --tw-inset-shadow-alpha {\n syntax: \"<percentage>\";\n inherits: false;\n initial-value: 100%;\n}\n@property --tw-ring-color {\n syntax: \"*\";\n inherits: false;\n}\n@property --tw-ring-shadow {\n syntax: \"*\";\n inherits: false;\n initial-value: 0 0 #0000;\n}\n@property --tw-inset-ring-color {\n syntax: \"*\";\n inherits: false;\n}\n@property --tw-inset-ring-shadow {\n syntax: \"*\";\n inherits: false;\n initial-value: 0 0 #0000;\n}\n@property --tw-ring-inset {\n syntax: \"*\";\n inherits: false;\n}\n@property --tw-ring-offset-width {\n syntax: \"<length>\";\n inherits: false;\n initial-value: 0px;\n}\n@property --tw-ring-offset-color {\n syntax: \"*\";\n inherits: false;\n initial-value: #fff;\n}\n@property --tw-ring-offset-shadow {\n syntax: \"*\";\n inherits: false;\n initial-value: 0 0 #0000;\n}\n@property --tw-outline-style {\n syntax: \"*\";\n inherits: false;\n initial-value: solid;\n}\n@property --tw-duration {\n syntax: \"*\";\n inherits: false;\n}\n@keyframes spin {\n to {\n transform: rotate(360deg);\n }\n}\n@layer properties {\n @supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))) {\n *, ::before, ::after, ::backdrop {\n --tw-translate-x: 0;\n --tw-translate-y: 0;\n --tw-translate-z: 0;\n --tw-rotate-x: initial;\n --tw-rotate-y: initial;\n --tw-rotate-z: initial;\n --tw-skew-x: initial;\n --tw-skew-y: initial;\n --tw-space-y-reverse: 0;\n --tw-border-style: solid;\n --tw-font-weight: initial;\n --tw-shadow: 0 0 #0000;\n --tw-shadow-color: initial;\n --tw-shadow-alpha: 100%;\n --tw-inset-shadow: 0 0 #0000;\n --tw-inset-shadow-color: initial;\n --tw-inset-shadow-alpha: 100%;\n --tw-ring-color: initial;\n --tw-ring-shadow: 0 0 #0000;\n --tw-inset-ring-color: initial;\n --tw-inset-ring-shadow: 0 0 #0000;\n --tw-ring-inset: initial;\n --tw-ring-offset-width: 0px;\n --tw-ring-offset-color: #fff;\n --tw-ring-offset-shadow: 0 0 #0000;\n --tw-outline-style: solid;\n --tw-duration: initial;\n }\n }\n}\n";
1481
+
1482
+ const SolarSystemForm = /*@__PURE__*/ proxyCustomElement(class SolarSystemForm extends H {
1483
+ constructor() {
1484
+ super();
1485
+ this.__registerHost();
1486
+ }
1487
+ systemConfigs = {};
1488
+ polygons = [];
1489
+ roofCanvas;
1490
+ polygonCanvas;
1491
+ householdConsumption = 4500;
1492
+ consumptionProfile = "mostly_at_home";
1493
+ electricityPrice = 0.3;
1494
+ compensationRate = 0.07;
1495
+ annualPriceIncrease = 2;
1496
+ autonomy = 0;
1497
+ costSavings = 0;
1498
+ numberOfPanels = 5;
1499
+ panelPeakPower = 0.4; // kW per panel
1500
+ name = "";
1501
+ email = "";
1502
+ phone = "";
1503
+ nameError = "";
1504
+ emailError = "";
1505
+ phoneError = "";
1506
+ electricCar = false;
1507
+ electricCarChargingTime = "day";
1508
+ heatPump = 0;
1509
+ battery = 0;
1510
+ compensation20Years = 0;
1511
+ savedCosts20Years = 0;
1512
+ maxPanels = 5;
1513
+ kmDrivenPerYear = 10000;
1514
+ totalEnergyConsumption = 4500;
1515
+ totalEnergyProduction = 0;
1516
+ isSubmitting = false;
1517
+ submitMessage = "";
1518
+ submitSuccess = false;
1519
+ updateSystemConfigs() {
1520
+ if (Object.keys(this.systemConfigs).length === 0) {
1521
+ this.numberOfPanels = 0;
1522
+ this.maxPanels = 0;
1523
+ return;
1524
+ }
1525
+ this.numberOfPanels = Object.keys(this.systemConfigs).reduce((acc, curr) => acc + this.systemConfigs[curr].numberOfPanels, 0);
1526
+ this.maxPanels = Object.keys(this.systemConfigs).reduce((acc, curr) => acc + this.systemConfigs[curr].numberOfPanels, 0);
1527
+ this.panelPeakPower = Object.entries(this.systemConfigs)[0][1][0]
1528
+ ?.panel.kWattPeak ?? 0.44;
1529
+ this.recalculate();
1530
+ }
1531
+ formatEuropeanNumber(num, decimals = 2) {
1532
+ const fixed = num.toFixed(decimals);
1533
+ const [integerPart, decimalPart] = fixed.split(".");
1534
+ // Add dots as thousands separators
1535
+ const formattedInteger = integerPart.replace(/\B(?=(\d{3})+(?!\d))/g, ".");
1536
+ // Join with comma as decimal separator
1537
+ return decimalPart
1538
+ ? `${formattedInteger},${decimalPart}`
1539
+ : formattedInteger;
1540
+ }
1541
+ recalculate() {
1542
+ const currentSystemConfigs = {};
1543
+ let totalNumberOfPanels = 0;
1544
+ for (const [key, value] of Object.entries(this.systemConfigs)) {
1545
+ if (totalNumberOfPanels >= this.numberOfPanels) {
1546
+ break;
1547
+ }
1548
+ if (value.numberOfPanels + totalNumberOfPanels > this.numberOfPanels) {
1549
+ currentSystemConfigs[key] = {
1550
+ ...value,
1551
+ numberOfPanels: this.numberOfPanels - totalNumberOfPanels,
1552
+ };
1553
+ totalNumberOfPanels = this.numberOfPanels;
1554
+ }
1555
+ else {
1556
+ currentSystemConfigs[key] = value;
1557
+ totalNumberOfPanels += value.numberOfPanels;
1558
+ }
1559
+ }
1560
+ const simulationConfig = {
1561
+ general: {
1562
+ simulationYears: 20,
1563
+ },
1564
+ householdConsumption: {
1565
+ consumptionProfile: this.consumptionProfile,
1566
+ winterConsumptionFactor: 1.4,
1567
+ summerConsumptionFactor: 0.6,
1568
+ averageConsumption: this.householdConsumption / 365,
1569
+ },
1570
+ electricityPrice: {
1571
+ purchase: this.electricityPrice,
1572
+ sell: this.compensationRate,
1573
+ increase: this.annualPriceIncrease / 100,
1574
+ },
1575
+ solarSystems: currentSystemConfigs,
1576
+ batteryKWh: this.battery,
1577
+ solarRadiation: {
1578
+ winterFactor: 0.2,
1579
+ summerFactor: 0.6,
1580
+ },
1581
+ heatPump: {
1582
+ m2: this.heatPump,
1583
+ consumptionPerM2: HEAT_PUMP_CONSUMPTION / 365,
1584
+ },
1585
+ electricCar: this.electricCar
1586
+ ? {
1587
+ averageKilometersPerDay: this.kmDrivenPerYear / 365,
1588
+ consumptionkWhPer100km: 20,
1589
+ batteryKWh: 80,
1590
+ chargingHours: this.electricCarChargingTime === "day"
1591
+ ? distExports.generateElectricCarChargingHours(6, 18)
1592
+ : distExports.generateElectricCarChargingHours(18, 6),
1593
+ }
1594
+ : undefined,
1595
+ };
1596
+ const result = distExports.simulate(simulationConfig);
1597
+ this.compensation20Years = result.compensationPerDay * 365 * 20;
1598
+ this.savedCosts20Years = result.byYearSavedCosts.reduce((acc, curr) => acc + curr, 0) + this.compensation20Years;
1599
+ this.costSavings = result.byYearSavedCosts[0];
1600
+ this.autonomy = result.autonomy * 100;
1601
+ this.totalEnergyConsumption = result.totalEnergyConsumptionDay * 365;
1602
+ // Calculate total energy production based on compensation and rate
1603
+ this.totalEnergyProduction =
1604
+ (result.compensationPerDay / this.compensationRate) * 365;
1605
+ }
1606
+ componentWillLoad() {
1607
+ this.updateSystemConfigs();
1608
+ }
1609
+ validateForm() {
1610
+ let isValid = true;
1611
+ const t = getLanguageStrings(state.settings.language);
1612
+ // Validate name
1613
+ if (!this.name.trim()) {
1614
+ this.nameError = t.solarSystemForm.nameError;
1615
+ isValid = false;
1616
+ }
1617
+ else {
1618
+ this.nameError = "";
1619
+ }
1620
+ // Validate email
1621
+ const emailRegex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
1622
+ if (!this.email.trim()) {
1623
+ this.emailError = t.solarSystemForm.emailError;
1624
+ isValid = false;
1625
+ }
1626
+ else if (!emailRegex.test(this.email)) {
1627
+ this.emailError = t.solarSystemForm.validEmailError;
1628
+ isValid = false;
1629
+ }
1630
+ else {
1631
+ this.emailError = "";
1632
+ }
1633
+ // Validate phone (optional)
1634
+ const phoneRegex = /^[\+]?[1-9][\d]{0,15}$/;
1635
+ if (this.phone.trim() &&
1636
+ !phoneRegex.test(this.phone.replace(/[\s\-\(\)]/g, ""))) {
1637
+ this.phoneError = t.solarSystemForm.phoneError;
1638
+ isValid = false;
1639
+ }
1640
+ else {
1641
+ this.phoneError = "";
1642
+ }
1643
+ return isValid;
1644
+ }
1645
+ async handleRequestOffer() {
1646
+ if (!this.validateForm()) {
1647
+ return;
1648
+ }
1649
+ this.isSubmitting = true;
1650
+ this.submitMessage = "";
1651
+ this.submitSuccess = false;
1652
+ const t = getLanguageStrings(state.settings.language);
1653
+ try {
1654
+ const leadData = {
1655
+ location: {
1656
+ name: state.location,
1657
+ latitude: state.latitude,
1658
+ longitude: state.longitude,
1659
+ },
1660
+ systemConfig: {
1661
+ maxNumberOfPanels: this.maxPanels,
1662
+ panelPeakPower: this.panelPeakPower,
1663
+ polygons: this.polygons,
1664
+ solarSystems: this.systemConfigs,
1665
+ electricityPrice: this.electricityPrice,
1666
+ compensationRate: this.compensationRate,
1667
+ annualPriceIncrease: this.annualPriceIncrease,
1668
+ },
1669
+ client: {
1670
+ name: this.name,
1671
+ email: this.email,
1672
+ phone: this.phone,
1673
+ consumption: this.householdConsumption,
1674
+ consumptionProfile: this.consumptionProfile,
1675
+ hasBattery: this.battery > 0,
1676
+ battery: this.battery,
1677
+ hasHeatPump: this.heatPump > 0,
1678
+ heatPumpM2: this.heatPump,
1679
+ hasElectricCar: this.electricCar,
1680
+ electricCarChargingTime: this.electricCarChargingTime,
1681
+ electricCarKmPerYear: this.kmDrivenPerYear,
1682
+ },
1683
+ images: {
1684
+ roof: this.roofCanvas.toDataURL(),
1685
+ polygon: this.polygonCanvas.toDataURL(),
1686
+ },
1687
+ results: {
1688
+ autonomy: this.autonomy,
1689
+ costSavings: this.costSavings,
1690
+ compensation20Years: this.compensation20Years,
1691
+ savedCosts20Years: this.savedCosts20Years,
1692
+ totalEnergyConsumption: this.totalEnergyConsumption,
1693
+ },
1694
+ };
1695
+ console.log("leadData", leadData);
1696
+ const result = await sendLeadToNexvoro(leadData);
1697
+ this.submitSuccess = result.success;
1698
+ if (result.success) {
1699
+ console.log("Lead successfully sent to Nexvoro", result);
1700
+ this.submitMessage = t.solarSystemForm.leadSubmitted;
1701
+ // Optionally reset form or show success message
1702
+ }
1703
+ else {
1704
+ console.error("Failed to send lead to Nexvoro:", result.message);
1705
+ this.submitMessage = t.solarSystemForm.leadError;
1706
+ }
1707
+ }
1708
+ catch (error) {
1709
+ console.error("Error in handleRequestOffer:", error);
1710
+ this.submitSuccess = false;
1711
+ this.submitMessage = error instanceof Error
1712
+ ? error.message
1713
+ : "An unexpected error occurred";
1714
+ }
1715
+ finally {
1716
+ this.isSubmitting = false;
1717
+ }
1718
+ }
1719
+ isIOS() {
1720
+ return state.isIOS;
1721
+ }
1722
+ render() {
1723
+ const t = getLanguageStrings(state.settings.language);
1724
+ // Reusable style objects
1725
+ const borderStyle = { border: "1px solid var(--color-border)" };
1726
+ const errorBorderStyle = { border: "1px solid var(--color-error)" };
1727
+ return (h("div", { key: '7139c9f7a83ebbbda58963c1136bbdfd7728e0bd', class: "flex flex-col justify-center items-center w-full h-full pt-4" // style={{
1728
+ ,
1729
+ // display: (Object.keys(this.systemConfigs).length === 0)
1730
+ // ? "none"
1731
+ // : "flex",
1732
+ // }}
1733
+ id: "solar-system-form" }, h("h1", { key: '4e1cdee9c1ec934d4b874e88a96db2801c79a60d', class: "text-2xl font-bold text-secondary mb-4 w-full" }, t.solarSystemForm.title), h("div", { key: '63bb70b6c15761b9268dcc3059f44eb8ad4ef2fa', class: "w-full bg-primary rounded-4xl space-y-6" }, h("div", { key: '9f0f34af0c1dbfc1b8bb07883cb592010985692b', class: "space-y-4 p-4 rounded-4xl", style: borderStyle }, h("h2", { key: '5e8a8d3554ec8d810433dd75f96c32c2545508fc', class: "text-lg font-semibold text-secondary" }, t.solarSystemForm.systemInformation), h("div", { key: 'cf72325db86b65965cdb44013533477e64c23422', class: "flex flex-col sm:flex-row gap-4" }, h("div", { key: '5241cb1db7b4d7afc9179fa138a610152a7a35e1', class: "flex-1 bg-muted rounded-4xl p-4 space-y-3" }, h("div", { key: 'bc6151b8cd4b9f2e8b1b7cd311719d9fd21fc212', class: "flex items-center justify-between" }, h("label", { key: '0c1cca4024a7274281df489cd5f7bd8b62a2c96b', class: "text-sm font-medium text-text-muted" }, t.solarSystemForm.numberOfPanels), !this.isIOS()
1734
+ ? (h("input", { type: "number", class: "w-20 px-3 py-1 rounded-full bg-muted text-muted-foreground text-right", value: this.numberOfPanels, readOnly: true }))
1735
+ : (h("input", { type: "number", min: "1", max: this.maxPanels, class: "w-20 px-3 py-1 rounded-full focus:ring-2 focus:ring-tertiary focus:border-transparent bg-muted text-muted-foreground text-center", style: borderStyle, value: this.numberOfPanels, onInput: (e) => {
1736
+ const value = parseInt(e.target
1737
+ .value);
1738
+ if (value >= 1 &&
1739
+ value <=
1740
+ this.maxPanels) {
1741
+ this.numberOfPanels =
1742
+ value;
1743
+ this.recalculate();
1744
+ }
1745
+ } }))), !this.isIOS() && (h("input", { key: 'b7cc82a0d13854509a123976ffec2150497c54bf', type: "range", min: "1", max: this.maxPanels, step: "1", class: "input-slider w-full custom-range appearance-none rounded-full bg-transparent [&::-webkit-slider-runnable-track]:rounded-full [&::-webkit-slider-runnable-track]:bg-black/25 [&::-webkit-slider-thumb]:appearance-none [&::-webkit-slider-thumb]:h-[10px] [&::-webkit-slider-thumb]:w-[10px] [&::-webkit-slider-thumb]:rounded-full [&::-webkit-slider-thumb]:bg-muted", value: this.numberOfPanels, onInput: (e) => {
1746
+ this.numberOfPanels = parseInt(e.target
1747
+ .value);
1748
+ this.recalculate();
1749
+ } }))), h("div", { key: '2dd7469d204e77e97c29256a07dc164bbce62b3f', class: "flex-1 bg-muted rounded-4xl p-4" }, h("div", { key: 'd6fbb640a3093ffa56ddbdecf41fee985b7c13de', class: "flex items-center justify-between" }, h("label", { key: '5967e7593b965896fca79dc911f79dfb04bd31ba', class: "text-sm font-medium text-text-muted" }, t.solarSystemForm.panelPeakPower), h("span", { key: 'ecc8aebf57ebacdce115188308a3947d4329a4cd', class: "text-text-muted" }, this.panelPeakPower.toFixed(2), " kW")), h("div", { key: '07acff632a6492d811334c1b4fdfe7631fbf8930', class: "flex items-center justify-between mt-4" }, h("span", { key: 'f8692f2cf74cd8603775e94099752c9e4d03be9b', class: "text-sm font-medium text-text-muted" }, t.solarSystemForm.totalSystemPeakPower), h("span", { key: '7a89ad672637c04b5365e7ea034448ece3d32cf2', class: "font-bold text-text-muted" }, (DEFAULT_SOLAR_PANEL_TYPE.kWattPeak *
1750
+ this.numberOfPanels).toFixed(1), " kWp"))))), h("div", { key: 'c913d3a0895044e60c992aa368c27379208a197b', class: "space-y-4 p-4 rounded-4xl", style: borderStyle }, h("h2", { key: 'fc1b7bfc69f79e199a8526fda30851395e615b0f', class: "text-lg font-semibold text-secondary" }, t.solarSystemForm.householdConsumptionTitle), h("div", { key: 'dc4e9eecae7e31cded9b85c544ce13c59226efa6', class: "grid grid-rows-2 gap-0" }, h("div", { key: '5e00f5e87fdccd6dd6455c9a26e3a7ce1ae05394', class: "grid grid-cols-2 gap-4" }, h("label", { key: '155a89fbbf6ccc69bdcc0bed88d05bc7d09a866d', class: "block text-sm font-medium text-text-muted" }, t.solarSystemForm.annualConsumption), h("label", { key: '3bd653254b0f2ddb0c61f452952a0ab58c4f7d40', class: "block text-sm font-medium text-text-muted" }, t.solarSystemForm.consumptionProfileTitle)), h("div", { key: '33113a21857b3f4f68339fc39cd3bbc4054e1586', class: "grid grid-cols-2 gap-4" }, h("input", { key: '063500ea400d697056ec5e214b6fb530af06ccfe', type: "number", class: "w-full px-4 py-2 rounded-4xl focus:ring-2 focus:ring-tertiary focus:border-transparent bg-muted text-muted-foreground", style: borderStyle, value: this.householdConsumption, onInput: (e) => {
1751
+ this.householdConsumption = parseInt(e.target
1752
+ .value);
1753
+ this.recalculate();
1754
+ } }), h("select", { key: '48628afb1e204838358a8a56d7e3d09fc1576c10', class: "w-full px-4 py-2 rounded-4xl focus:ring-2 focus:ring-tertiary focus:border-transparent bg-muted text-muted-foreground", style: borderStyle, onChange: (e) => {
1755
+ this.consumptionProfile =
1756
+ e.target
1757
+ .value;
1758
+ this.recalculate();
1759
+ } }, h("option", { key: 'dcdcf43433687a823b4cc617d956b10a56b82133', value: "mostly_at_home", selected: this.consumptionProfile ===
1760
+ "mostly_at_home" }, t.solarSystemForm.consumptionProfiles
1761
+ .mostlyAtHome), h("option", { key: 'ad37f3694f26f08cfc65e67f6d78e14c815478c9', value: "mostly_away", selected: this.consumptionProfile ===
1762
+ "mostly_away" }, t.solarSystemForm.consumptionProfiles
1763
+ .mostlyAway))))), h("div", { key: '2461025c58f8e091cf757c4968b0a21108f35e75', class: "space-y-4 p-4 rounded-4xl", style: borderStyle }, h("h2", { key: '89575de1e21452e71028505f02474cc6d0de197a', class: "text-lg font-semibold text-secondary" }, t.solarSystemForm.additionalComponents.title), h("div", { key: 'b2f666cfe480ce0cc8c84c24a852034b04eca215', class: "flex flex-col gap-4" }, h("div", { key: '7a224cfb1d954bed01b45e3a9f397ba69f0055b8', class: "flex flex-col bg-muted rounded-4xl p-4 gap-4" }, h("div", { key: '4c0d72a28f4440e647159fbb8cfe5d3a6eda53e2', class: "flex items-center justify-between" }, h("div", { key: '928b6bf84a5349fa89e3b961894b538185d33961', class: "flex items-center gap-2" }, h("input", { key: '6f5d77b885551b0280366cd837baec595529490f', type: "checkbox", id: "heatPump", class: "w-4 h-4 accent-tertiary border-border rounded-full focus:ring-tertiary focus:ring-offset-0 focus:ring-2", checked: this.heatPump > 0, onChange: (e) => {
1764
+ this.heatPump =
1765
+ e.target
1766
+ .checked
1767
+ ? 100
1768
+ : 0;
1769
+ this.recalculate();
1770
+ } }), h("label", { key: '4df84acd8d1011ace4903c10674a6ea6c8320276', htmlFor: "heatPump", class: "text-text-muted" }, t.solarSystemForm
1771
+ .additionalComponents
1772
+ .heatPump)), (this.heatPump > 0 && !this.isIOS()) && (h("span", { key: 'e1cc7cac2dd0d3efbefd9e05ef7fe61c7a1cfe3a', class: "text-text-muted" }, this.heatPump, " m\u00B2"))), this.heatPump > 0 && (h("div", { key: '5bef4d0ac8adbd58bd8f4d56e6ba1c83f22d6f98', class: "flex flex-col gap-2" }, this.isIOS()
1773
+ ? (h("div", { class: "flex items-center gap-2" }, h("input", { type: "number", min: "10", max: "300", step: "10", class: "flex-1 px-4 py-2 rounded-4xl focus:ring-2 focus:ring-tertiary focus:border-transparent bg-muted", style: borderStyle, value: this.heatPump, onInput: (e) => {
1774
+ const value = parseInt(e.target
1775
+ .value);
1776
+ if (value >= 10 &&
1777
+ value <= 300) {
1778
+ this.heatPump =
1779
+ value;
1780
+ this.recalculate();
1781
+ }
1782
+ } }), h("span", { class: "text-sm text-text-muted" }, "m\u00B2")))
1783
+ : (h("input", { type: "range", min: "10", max: "300", step: "10", class: "input-slider custom-range appearance-none rounded-full bg-transparent [&::-webkit-slider-runnable-track]:rounded-full [&::-webkit-slider-runnable-track]:bg-black/25 [&::-webkit-slider-thumb]:appearance-none [&::-webkit-slider-thumb]:h-[10px] [&::-webkit-slider-thumb]:w-[10px] [&::-webkit-slider-thumb]:rounded-full [&::-webkit-slider-thumb]:bg-muted", value: this.heatPump, onInput: (e) => {
1784
+ this.heatPump =
1785
+ parseInt(e.target
1786
+ .value);
1787
+ this.recalculate();
1788
+ } }))))), h("div", { key: '76a40ab1f89c47050faf446a2017b2b74703638a', class: "flex flex-col bg-muted rounded-4xl p-4 gap-4" }, h("div", { key: '56666133211231da0c95f3ecd058ea62615ea88c', class: "flex items-center justify-between" }, h("div", { key: '08b1d06eb90a88e5583989f5d2743f9e294a1f7e', class: "flex items-center gap-2" }, h("input", { key: 'cbd441786b9e23720e2a0aa2c39ef5bbaaed01b4', type: "checkbox", id: "electricCar", class: "w-4 h-4 accent-tertiary border-border rounded focus:ring-tertiary focus:ring-offset-0 focus:ring-2", checked: this.electricCar, onChange: (e) => {
1789
+ this.electricCar =
1790
+ e.target
1791
+ .checked;
1792
+ this.recalculate();
1793
+ } }), h("label", { key: 'f746d81d324d236e53d553706a0a64f78d6ae2d8', htmlFor: "electricCar", class: "text-text-muted" }, t.solarSystemForm
1794
+ .additionalComponents
1795
+ .electricCar))), this.electricCar && (h("div", { key: 'f2a0ff39ca1e52ba544f333ebd73da57b0803f36', class: "flex flex-col gap-2" }, h("div", { key: '052c60cf1661a8d3fe826a63e657b7ebb228bccc', class: "grid grid-cols-2 gap-4" }, h("label", { key: 'f486f4876988df361f4bbb967e566112c491036c', class: "text-sm text-text-muted" }, t.solarSystemForm
1796
+ .additionalComponents
1797
+ .chargingTime), h("label", { key: '870bc7ff65a52cfa1bbfa0296bf8428c104d5edf', class: "text-sm text-text-muted" }, t.solarSystemForm
1798
+ .additionalComponents
1799
+ .kilometersPerYear)), h("div", { key: 'e1698c0928da471f3758228502159baafecbe44b', class: "grid grid-cols-2 gap-4" }, h("select", { key: '82362f74b362a31c8a30e246d073836e93bec1c3', class: "w-full px-4 py-2 rounded-4xl focus:ring-2 focus:ring-tertiary focus:border-transparent bg-muted", onChange: (e) => {
1800
+ this.electricCarChargingTime =
1801
+ e.target
1802
+ .value;
1803
+ this.recalculate();
1804
+ }, style: borderStyle }, h("option", { key: 'c76bd6ed6abbcb624f3c79585cb6f719bc60b30e', value: "day", selected: this
1805
+ .electricCarChargingTime ===
1806
+ "day" }, t.solarSystemForm
1807
+ .additionalComponents
1808
+ .chargingTimeDay), h("option", { key: 'abc0fd939d0d6d228b124f53e9b297bd8079fef6', value: "night", selected: this
1809
+ .electricCarChargingTime ===
1810
+ "night" }, t.solarSystemForm
1811
+ .additionalComponents
1812
+ .chargingTimeNight)), h("input", { key: '0f8792d286b91548ca25843c1ad31dd081842f88', type: "number", min: "1000", max: "50000", step: "1000", class: "w-full px-4 py-2 rounded-4xl focus:ring-2 focus:ring-tertiary focus:border-transparent bg-muted", value: this.kmDrivenPerYear, onInput: (e) => {
1813
+ this.kmDrivenPerYear =
1814
+ parseInt(e.target
1815
+ .value);
1816
+ this.recalculate();
1817
+ }, style: borderStyle }))))), h("div", { key: '3f9c6afd978a3e77435e035e64d9aaf3aa0aa97a', class: "flex flex-col bg-muted rounded-4xl p-4 gap-4" }, h("div", { key: '99b1f2cfbf1d8cba8d1fb19201ee59faa8943858', class: "flex items-center justify-between" }, h("div", { key: 'ae3155b4b63cea133953a9dee18629c61dbd1cc4', class: "flex items-center gap-2" }, h("input", { key: 'bbfe892ac4fe0564701d1e8a5595b6b85f0ba76a', type: "checkbox", id: "battery", class: "w-4 h-4 accent-tertiary border-border rounded-full focus:ring-tertiary focus:ring-offset-0 focus:ring-2", checked: this.battery > 0, onChange: (e) => {
1818
+ this.battery =
1819
+ e.target
1820
+ .checked
1821
+ ? 5
1822
+ : 0;
1823
+ this.recalculate();
1824
+ } }), h("label", { key: 'c0da0d83bfe05a6591683e308f14f2d7aa60b3b3', htmlFor: "battery", class: "text-text-muted" }, t.solarSystemForm
1825
+ .additionalComponents
1826
+ .battery)), (this.battery > 0 && !this.isIOS()) && (h("span", { key: '7e7e5848a5c12d3029887800c9cfa6a97c3c5f8d', class: "text-text-muted" }, this.battery, " kWh"))), this.battery > 0 && (h("div", { key: '41ebca4575af0383bae612780942f52197835390', class: "flex flex-col gap-2" }, this.isIOS()
1827
+ ? (h("div", { class: "flex items-center gap-2" }, h("input", { type: "number", min: "1", max: "20", step: "1", class: "flex-1 px-4 py-2 rounded-4xl focus:ring-2 focus:ring-tertiary focus:border-transparent bg-muted", value: this.battery, onInput: (e) => {
1828
+ const value = parseInt(e.target
1829
+ .value);
1830
+ if (value >= 1 &&
1831
+ value <= 20) {
1832
+ this.battery =
1833
+ value;
1834
+ this.recalculate();
1835
+ }
1836
+ }, style: borderStyle }), h("span", { class: "text-sm text-text-muted" }, "kWh")))
1837
+ : (h("input", { type: "range", min: "1", max: "20", step: "1", class: "input-slider w-full custom-range appearance-none rounded-full bg-transparent [&::-webkit-slider-runnable-track]:rounded-full [&::-webkit-slider-runnable-track]:bg-black/25 [&::-webkit-slider-thumb]:appearance-none [&::-webkit-slider-thumb]:h-[10px] [&::-webkit-slider-thumb]:w-[10px] [&::-webkit-slider-thumb]:rounded-full [&::-webkit-slider-thumb]:bg-muted", value: this.battery, onInput: (e) => {
1838
+ this.battery = parseInt(e.target
1839
+ .value);
1840
+ this.recalculate();
1841
+ } }))))))), h("div", { key: '1f3db56a01db3aa71a3e732eb42feee34619c016', class: "space-y-4 p-4 rounded-4xl", style: borderStyle }, h("h2", { key: '4406c2eb5ce9f2fb6c2b9ced506e2722dd33c90d', class: "text-lg font-semibold text-secondary" }, t.solarSystemForm.electricityCostsTitle), h("div", { key: '9474e98cb4f906dc7bbe9c1ae9677be099af8554', style: {
1842
+ display: "grid",
1843
+ gridTemplateColumns: "repeat(auto-fit, minmax(250px, 1fr))",
1844
+ gap: "1rem",
1845
+ } }, h("div", { key: '45be0a23fce514b258b89308355512be1ab76543' }, h("label", { key: 'd4b5ae8bec34ea36437fbc80808954e3faa4b53a', class: "block text-sm font-medium text-text-muted mb-1" }, t.solarSystemForm.electricityPrice), h("input", { key: '3f0f2f9f6424647f3b39fd6c1c71673c151f5168', type: "number", step: "0.01", class: "w-full px-4 py-2 rounded-4xl focus:ring-2 focus:ring-tertiary focus:border-transparent bg-muted", style: borderStyle, value: this.electricityPrice.toFixed(2), onInput: (e) => {
1846
+ this.electricityPrice = parseFloat(e.target
1847
+ .value);
1848
+ this.recalculate();
1849
+ } })), h("div", { key: 'ff004d5e3a408d0b471bccff956297eb80359581' }, h("label", { key: 'afd1ecf5fcbad4ccd0a9ab091e16cffd9c21b64c', class: "block text-sm font-medium text-text-muted mb-1" }, t.solarSystemForm.compensationRate), h("input", { key: 'f22a6fa86cb9ade28345570bacd51a0ca69e3ccd', type: "number", step: "0.01", class: "w-full px-4 py-2 rounded-4xl focus:ring-2 focus:ring-tertiary focus:border-transparent bg-muted", style: borderStyle, value: this.compensationRate.toFixed(2), onInput: (e) => {
1850
+ this.compensationRate = parseFloat(e.target
1851
+ .value);
1852
+ this.recalculate();
1853
+ } })), h("div", { key: '2b2f63afb3a565fbd96c3e81e06c7281fb62fa3b' }, h("label", { key: '46f212c2b33c682f3b2c203dc71f7b6441cc25a5', class: "block text-sm font-medium text-text-muted mb-1" }, t.solarSystemForm.annualPriceIncrease), h("input", { key: '164994dc4f1bdaa38b0fd4a069ac1fbc0f02026f', type: "number", step: "0.1", class: "w-full px-4 py-2 rounded-4xl focus:ring-2 focus:ring-tertiary focus:border-transparent bg-muted", style: borderStyle, value: this.annualPriceIncrease.toFixed(1), onInput: (e) => {
1854
+ this.annualPriceIncrease = parseFloat(e.target
1855
+ .value);
1856
+ this.recalculate();
1857
+ } })))), h("div", { key: '6543bebe9a5c3ddd914cd79a1d0bccdeb064091f', class: "space-y-4 p-4 rounded-4xl", style: borderStyle }, h("h2", { key: '05fafd14c233ce175189d8bd93df07121ee7c33c', class: "text-lg font-semibold text-secondary" }, t.solarSystemForm.resultsTitle), h("div", { key: '8dc5907b2cc779ff942ee0e6f2b501924f9d1a97', class: "bg-muted rounded-4xl p-4" }, h("div", { key: '8fd3a7c0ef678a57834242dbc5e655cba001888a', class: "flex flex-col sm:flex-row sm:items-center justify-between" }, h("span", { key: 'c2c32f7f9f5f50242332c6a4b5af2cedb7fb6669', class: "text-text-muted" }, t.solarSystemForm.autonomy), h("span", { key: 'd6e5824d2b44cac00cd5d712007e65b2ccd0ecfd', class: "text-xl font-bold text-secondary mt-1 sm:mt-0" }, this.autonomy > 100
1858
+ ? "100"
1859
+ : this.formatEuropeanNumber(this.autonomy, 1), "%")), h("div", { key: '15e3620ae50666bbd4dd08379d2d276b41508379', class: "flex flex-col sm:flex-row sm:items-center justify-between mt-4" }, h("span", { key: 'ff9746b6eb4046ddf4d87839555297e64205e841', class: "text-text-muted" }, t.solarSystemForm.totalEnergyConsumption), h("span", { key: '692198f0d789364993b679f4d73c098c7a2c2b93', class: "text-xl font-bold text-secondary mt-1 sm:mt-0" }, this.formatEuropeanNumber(this.totalEnergyConsumption, 0), " kWh/", t.solarSystemForm.year)), h("div", { key: '8a292497f9b701b0805e5c3a2d007c8242033891', class: "flex flex-col sm:flex-row sm:items-center justify-between mt-4" }, h("span", { key: 'd156ccda8acafbc6946810493c150881bc891757', class: "text-text-muted" }, t.solarSystemForm.totalEnergyProduction), h("span", { key: 'f3b8171f54c842950cf442b51a8e712b21a28a7c', class: "text-xl font-bold text-secondary mt-1 sm:mt-0" }, this.formatEuropeanNumber(this.totalEnergyProduction, 0), " kWh/", t.solarSystemForm.year)), h("div", { key: '0ce95a5cfff5c3ae27056b680f4e290b5c383cea', class: "flex flex-col sm:flex-row sm:items-center justify-between mt-4" }, h("div", { key: 'e3551545706f356cbdb82b9d9b2b90c561f7895e', class: "flex items-center gap-2" }, h("span", { key: '97df861ed813711fc7d2f225b45071c9a6035e3d', class: "text-text-muted" }, t.solarSystemForm.costSavings)), h("span", { key: '0929f0961f4db248a3ad63cc685d5d48f4e0693c', class: "text-xl font-bold text-success mt-1 sm:mt-0" }, this.formatEuropeanNumber(this.costSavings), "\u20AC/", t
1860
+ .solarSystemForm.year)), h("div", { key: '8658c9d6537b980d3c32f1382c9a1507de5482bf', class: "flex flex-col sm:flex-row sm:items-center justify-between mt-4" }, h("div", { key: 'e3b71e616e9f0be006cd48eb57161e24f5a8f204', class: "flex items-center gap-2" }, h("span", { key: 'a083ad4fec0a9d546cd2d38fdbaeb4d76e5ce091', class: "text-text-muted" }, t.solarSystemForm.compensation20Years)), h("span", { key: '028c3f9c1135bb74f4bf39baf657ac73dbd935d3', class: "text-xl font-bold text-success mt-1 sm:mt-0" }, this.formatEuropeanNumber(this.compensation20Years), "\u20AC")), h("div", { key: '875446618133c6cbe70c4939fa46a5b85157e6ca', class: "flex flex-col sm:flex-row sm:items-center justify-between mt-4" }, h("div", { key: '98b9829e57eb40d1be9f42d0497b5678363ef20b', class: "flex items-center gap-2" }, h("span", { key: '6a87d1ebb879bacade7d1de58942bdb080190e6c', class: "text-text-muted" }, t.solarSystemForm
1861
+ .monetaryBenefit20Years)), h("span", { key: 'fcae5f3a40137fad4a51df1afa5cbb70cca43b0e', class: "text-xl font-bold text-success mt-1 sm:mt-0" }, this.formatEuropeanNumber(this.savedCosts20Years), "\u20AC")))), h("div", { key: 'f6298fa9bbba037cecb0b8e55bdd620b0cac1602', class: "space-y-4 p-4 rounded-4xl", style: borderStyle }, h("h2", { key: 'ba176c714d0c73cec7354b060734fbafdbbfd7b7', class: "text-lg font-semibold text-secondary" }, t.solarSystemForm.requestOffer), h("div", { key: 'e35c8b896aecc01ccc8036a64cfcd52636d7d816', style: {
1862
+ display: "grid",
1863
+ gridTemplateColumns: "repeat(auto-fit, minmax(250px, 1fr))",
1864
+ gap: "1rem",
1865
+ } }, h("div", { key: 'd88465e3c4edc99871fc92a0f36900d204579d9a' }, h("label", { key: 'f0a49b5ed350c5f638a64de1fa87739e46297c9f', class: "block text-sm font-medium text-text-muted mb-1" }, t.solarSystemForm.name), h("input", { key: '70eb7d64859083937ed05c85e2a433b862e7ef0c', type: "text", class: `w-full px-4 py-2 rounded-4xl focus:ring-2 focus:ring-tertiary focus:border-transparent bg-muted text-muted-foreground`, style: this.nameError
1866
+ ? errorBorderStyle
1867
+ : borderStyle, value: this.name, onInput: (e) => {
1868
+ this.name =
1869
+ e.target
1870
+ .value;
1871
+ this.validateForm();
1872
+ }, placeholder: "Your name" }), this.nameError && (h("p", { key: '953421511217ed5759266488e606ee706cbaaa66', class: "text-error text-sm mt-1" }, this.nameError))), h("div", { key: '7d2c2f6ce9f6161ea1123f45b017479f0a872153' }, h("label", { key: '190c752cc5f9a0db9355b871b42adfdedd7160b3', class: "block text-sm font-medium text-text-muted mb-1" }, t.solarSystemForm.email), h("input", { key: 'f1bad4e18f283acd556017bb8ccb880cbbc804c4', type: "email", class: `w-full px-4 py-2 rounded-4xl focus:ring-2 focus:ring-tertiary focus:border-transparent bg-muted text-muted-foreground`, style: this.emailError
1873
+ ? errorBorderStyle
1874
+ : borderStyle, value: this.email, onInput: (e) => {
1875
+ this.email =
1876
+ e.target
1877
+ .value;
1878
+ this.validateForm();
1879
+ }, placeholder: "your.email@example.com" }), this.emailError && (h("p", { key: '07e41cd62db7a0585ce03cf66978bc1b485fcd58', class: "text-error text-sm mt-1" }, this.emailError))), h("div", { key: '4ac9628f2ce4cba2fda116e2ffbb6496372dcecf' }, h("label", { key: '94e2332210a1efed939555f52645cd0ebfef2679', class: "block text-sm font-medium text-text-muted mb-1" }, t.solarSystemForm.phone), h("input", { key: 'de94479e3cf9c16f35e536815f1f511e168ef8e0', type: "tel", class: `w-full px-4 py-2 rounded-4xl focus:ring-2 focus:ring-tertiary focus:border-transparent bg-muted text-muted-foreground`, style: this.phoneError
1880
+ ? errorBorderStyle
1881
+ : borderStyle, value: this.phone, onInput: (e) => {
1882
+ this.phone =
1883
+ e.target
1884
+ .value;
1885
+ this.validateForm();
1886
+ }, placeholder: "+34 123 456 789" }), this.phoneError && (h("p", { key: '644a0267abc1fec8a6a2784b21e1327d71f091af', class: "text-error text-sm mt-1" }, this.phoneError)))), h("div", { key: '4c88bcdee1119057ecc14ead825fd144414577ba', class: "flex flex-col items-center gap-4" }, h("button", { key: 'c8c97d037ad92042100af3c3be6bfdc1ff2517a5', onClick: () => this.handleRequestOffer(), disabled: !this.name.trim() ||
1887
+ !this.email.trim() || !!this.nameError ||
1888
+ !!this.emailError || !!this.phoneError ||
1889
+ this.isSubmitting, class: `px-6 py-3 rounded-4xl transition-colors duration-200 flex items-center gap-2 ${this.isSubmitting
1890
+ ? "bg-muted text-text-muted cursor-not-allowed"
1891
+ : "bg-secondary hover:bg-tertiary"}`, style: {
1892
+ color: this.isSubmitting
1893
+ ? "var(--color-text-muted)"
1894
+ : "#ffffff",
1895
+ } }, this.isSubmitting && (h("div", { key: '78ccc59f3f59496867c0699c1370cf79b4c7fe7d', class: "w-4 h-4 border-2 border-current border-t-transparent rounded-full animate-spin" })), this.isSubmitting
1896
+ ? t.solarSystemForm.sending
1897
+ : t.solarSystemForm.requestOfferButton), this.submitMessage && (h("div", { key: '5a1efe7e4264d5510618570e494b7ccbfef76bfa', class: `text-sm px-4 py-2 rounded-4xl ${this.submitSuccess
1898
+ ? "bg-success/10 text-success border border-success/20"
1899
+ : "bg-error/10 text-error border border-error/20"}` }, this.submitMessage)))))));
1900
+ }
1901
+ static get watchers() { return {
1902
+ "systemConfigs": ["updateSystemConfigs"]
1903
+ }; }
1904
+ static get style() { return outputCss; }
1905
+ }, [0, "solar-system-form", {
1906
+ "systemConfigs": [16, "system-configs"],
1907
+ "polygons": [16],
1908
+ "roofCanvas": [16, "roof-canvas"],
1909
+ "polygonCanvas": [16, "polygon-canvas"],
1910
+ "householdConsumption": [32],
1911
+ "consumptionProfile": [32],
1912
+ "electricityPrice": [32],
1913
+ "compensationRate": [32],
1914
+ "annualPriceIncrease": [32],
1915
+ "autonomy": [32],
1916
+ "costSavings": [32],
1917
+ "numberOfPanels": [32],
1918
+ "panelPeakPower": [32],
1919
+ "name": [32],
1920
+ "email": [32],
1921
+ "phone": [32],
1922
+ "nameError": [32],
1923
+ "emailError": [32],
1924
+ "phoneError": [32],
1925
+ "electricCar": [32],
1926
+ "electricCarChargingTime": [32],
1927
+ "heatPump": [32],
1928
+ "battery": [32],
1929
+ "compensation20Years": [32],
1930
+ "savedCosts20Years": [32],
1931
+ "maxPanels": [32],
1932
+ "kmDrivenPerYear": [32],
1933
+ "totalEnergyConsumption": [32],
1934
+ "totalEnergyProduction": [32],
1935
+ "isSubmitting": [32],
1936
+ "submitMessage": [32],
1937
+ "submitSuccess": [32]
1938
+ }, undefined, {
1939
+ "systemConfigs": ["updateSystemConfigs"]
1940
+ }]);
1941
+ function defineCustomElement() {
1942
+ if (typeof customElements === "undefined") {
1943
+ return;
1944
+ }
1945
+ const components = ["solar-system-form"];
1946
+ components.forEach(tagName => { switch (tagName) {
1947
+ case "solar-system-form":
1948
+ if (!customElements.get(tagName)) {
1949
+ customElements.define(tagName, SolarSystemForm);
1950
+ }
1951
+ break;
1952
+ } });
1953
+ }
1954
+ defineCustomElement();
1955
+
1956
+ export { BORDER_INSET as B, DEFAULT_COLOR_SCHEME as D, SolarSystemForm as S, DEFAULT_SOLAR_EXPERT_CONFIG as a, DEFAULT_SOLAR_PANEL_TYPE as b, distExports as c, defineCustomElement as d, requireDist$1 as r };
1957
+ //# sourceMappingURL=p-DJcc5dax.js.map
1958
+
1959
+ //# sourceMappingURL=p-DJcc5dax.js.map