@vandenberghinc/volt 1.1.26 → 1.1.28

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 (502) hide show
  1. package/backend/dist/cjs/{blacklist.d.ts → backend/src/blacklist.d.ts} +5 -3
  2. package/backend/dist/cjs/{blacklist.js → backend/src/blacklist.js} +8 -5
  3. package/backend/dist/cjs/{cli.js → backend/src/cli.js} +29 -47
  4. package/backend/dist/cjs/backend/src/database/collection.d.ts +1543 -0
  5. package/backend/dist/cjs/backend/src/database/collection.js +3042 -0
  6. package/backend/dist/cjs/backend/src/database/database.d.ts +66 -0
  7. package/backend/dist/cjs/{database → backend/src/database}/database.js +48 -43
  8. package/backend/dist/cjs/backend/src/database/filters/filters.d.ts +6 -0
  9. package/backend/dist/cjs/backend/src/database/filters/filters.js +15 -0
  10. package/backend/dist/cjs/backend/src/database/filters/strict_filter.d.ts +223 -0
  11. package/backend/dist/cjs/backend/src/database/filters/strict_filter.js +15 -0
  12. package/backend/dist/cjs/backend/src/database/filters/strict_filter_test.js +443 -0
  13. package/backend/dist/cjs/backend/src/database/filters/strict_filter_test_v0.js +15 -0
  14. package/backend/dist/cjs/backend/src/database/filters/strict_filter_v0.d.ts +50 -0
  15. package/backend/dist/cjs/backend/src/database/filters/strict_filter_v0.js +15 -0
  16. package/backend/dist/cjs/backend/src/database/filters/strict_filter_v1.d.ts +76 -0
  17. package/backend/dist/cjs/backend/src/database/filters/strict_filter_v1.js +15 -0
  18. package/backend/dist/cjs/backend/src/database/filters/strict_filter_v2.d.ts +75 -0
  19. package/backend/dist/cjs/backend/src/database/filters/strict_filter_v2.js +15 -0
  20. package/backend/dist/cjs/backend/src/database/filters/strict_filter_v3.d.ts +219 -0
  21. package/backend/dist/cjs/backend/src/database/filters/strict_filter_v3.js +15 -0
  22. package/backend/dist/cjs/backend/src/database/filters/strict_update_filter.d.ts +165 -0
  23. package/backend/dist/cjs/backend/src/database/filters/strict_update_filter.js +15 -0
  24. package/backend/dist/cjs/backend/src/database/filters/strict_update_filter_test.d.ts +5 -0
  25. package/backend/dist/cjs/backend/src/database/filters/strict_update_filter_test.js +355 -0
  26. package/backend/dist/cjs/backend/src/database/flatten.d.ts +75 -0
  27. package/backend/dist/cjs/{logger.js → backend/src/database/flatten.js} +18 -7
  28. package/backend/dist/cjs/backend/src/database/flatten_test.js +175 -0
  29. package/backend/dist/cjs/backend/src/database/quota/quota.d.ts +461 -0
  30. package/backend/dist/cjs/backend/src/database/quota/quota.js +1014 -0
  31. package/backend/dist/cjs/backend/src/database/quota/quota_v1.d.ts +534 -0
  32. package/backend/dist/cjs/backend/src/database/quota/quota_v1.js +1087 -0
  33. package/backend/dist/cjs/backend/src/database/quota/safe_int.d.ts +293 -0
  34. package/backend/dist/cjs/backend/src/database/quota/safe_int.js +573 -0
  35. package/backend/dist/{esm → cjs/backend/src}/endpoint.d.ts +69 -46
  36. package/backend/dist/cjs/{endpoint.js → backend/src/endpoint.js} +87 -101
  37. package/backend/dist/cjs/backend/src/errors/index.d.ts +7 -0
  38. package/backend/dist/cjs/backend/src/errors/index.js +25 -0
  39. package/backend/dist/{esm/utils.d.ts → cjs/backend/src/errors/internal_external.d.ts} +14 -22
  40. package/backend/dist/cjs/backend/src/errors/internal_external.js +85 -0
  41. package/backend/dist/cjs/backend/src/errors/invalid_usage_error.d.ts +38 -0
  42. package/backend/dist/cjs/{mutex.js → backend/src/errors/invalid_usage_error.js} +20 -37
  43. package/backend/dist/cjs/backend/src/errors/system_error.d.ts +230 -0
  44. package/backend/dist/cjs/backend/src/errors/system_error.js +393 -0
  45. package/backend/dist/cjs/backend/src/events.d.ts +54 -0
  46. package/backend/dist/cjs/backend/src/events.js +15 -0
  47. package/backend/dist/cjs/{frontend.js → backend/src/frontend.js} +1 -1
  48. package/backend/dist/cjs/{image_endpoint.d.ts → backend/src/image_endpoint.d.ts} +16 -1
  49. package/backend/dist/cjs/{image_endpoint.js → backend/src/image_endpoint.js} +3 -5
  50. package/backend/dist/cjs/backend/src/logger.d.ts +5 -0
  51. package/backend/dist/cjs/backend/src/logger.js +15 -0
  52. package/backend/dist/cjs/backend/src/meta.d.ts +64 -0
  53. package/backend/dist/cjs/{meta.js → backend/src/meta.js} +9 -12
  54. package/backend/dist/cjs/backend/src/payments/paddle.d.ts +326 -0
  55. package/backend/dist/cjs/{payments → backend/src/payments}/paddle.js +377 -327
  56. package/backend/dist/cjs/backend/src/plugins/browser.d.ts +1 -0
  57. package/backend/dist/cjs/backend/src/plugins/browser.js +15 -0
  58. package/backend/dist/cjs/backend/src/plugins/mail/mail.d.ts +248 -0
  59. package/backend/dist/cjs/backend/src/plugins/mail/mail.js +379 -0
  60. package/backend/dist/{esm → cjs/backend/src}/plugins/mail/ui.d.ts +23 -0
  61. package/backend/dist/cjs/backend/src/plugins/pdf.d.ts +1 -0
  62. package/backend/dist/cjs/backend/src/rate_limit.d.ts +145 -0
  63. package/backend/dist/cjs/backend/src/rate_limit.js +549 -0
  64. package/backend/dist/cjs/{route.d.ts → backend/src/route.d.ts} +3 -10
  65. package/backend/dist/cjs/{route.js → backend/src/route.js} +23 -21
  66. package/backend/dist/cjs/backend/src/server.d.ts +485 -0
  67. package/backend/dist/cjs/{server.js → backend/src/server.js} +688 -873
  68. package/backend/dist/cjs/backend/src/splash_screen.d.ts +80 -0
  69. package/backend/dist/cjs/{splash_screen.js → backend/src/splash_screen.js} +24 -3
  70. package/backend/dist/cjs/backend/src/status.d.ts +74 -0
  71. package/backend/dist/cjs/{status.js → backend/src/status.js} +64 -64
  72. package/backend/dist/cjs/backend/src/stream.d.ts +376 -0
  73. package/backend/dist/cjs/{stream.js → backend/src/stream.js} +299 -276
  74. package/backend/dist/cjs/backend/src/users.d.ts +807 -0
  75. package/backend/dist/cjs/backend/src/users.js +1971 -0
  76. package/backend/dist/cjs/backend/src/utils.d.ts +16 -0
  77. package/backend/dist/cjs/{utils.js → backend/src/utils.js} +14 -77
  78. package/backend/dist/{esm → cjs/backend/src}/view.d.ts +33 -11
  79. package/backend/dist/cjs/backend/src/view.js +508 -0
  80. package/backend/dist/{esm → cjs/backend/src}/volt.d.ts +10 -1
  81. package/backend/dist/cjs/{volt.js → backend/src/volt.js} +8 -5
  82. package/backend/dist/cjs/frontend/src/modules/request.d.ts +70 -0
  83. package/backend/dist/cjs/frontend/src/modules/request.js +99 -0
  84. package/backend/dist/esm/{blacklist.d.ts → backend/src/blacklist.d.ts} +5 -3
  85. package/backend/dist/esm/{blacklist.js → backend/src/blacklist.js} +9 -6
  86. package/backend/dist/esm/{cli.js → backend/src/cli.js} +43 -60
  87. package/backend/dist/esm/backend/src/database/collection.d.ts +1543 -0
  88. package/backend/dist/esm/backend/src/database/collection.js +3510 -0
  89. package/backend/dist/esm/backend/src/database/database.d.ts +66 -0
  90. package/backend/dist/esm/{database → backend/src/database}/database.js +62 -103
  91. package/backend/dist/esm/backend/src/database/document.d.ts +1 -0
  92. package/backend/dist/esm/backend/src/database/document.js +558 -0
  93. package/backend/dist/esm/backend/src/database/filters/filters.d.ts +6 -0
  94. package/backend/dist/esm/backend/src/database/filters/filters.js +1 -0
  95. package/backend/dist/esm/backend/src/database/filters/strict_filter.d.ts +223 -0
  96. package/backend/dist/esm/backend/src/database/filters/strict_filter.js +3 -0
  97. package/backend/dist/esm/backend/src/database/filters/strict_filter_test.d.ts +1 -0
  98. package/backend/dist/esm/backend/src/database/filters/strict_filter_test.js +505 -0
  99. package/backend/dist/esm/backend/src/database/filters/strict_filter_test_v0.d.ts +1 -0
  100. package/backend/dist/esm/backend/src/database/filters/strict_filter_test_v0.js +712 -0
  101. package/backend/dist/esm/backend/src/database/filters/strict_filter_v0.d.ts +50 -0
  102. package/backend/dist/esm/backend/src/database/filters/strict_filter_v0.js +5 -0
  103. package/backend/dist/esm/backend/src/database/filters/strict_filter_v1.d.ts +76 -0
  104. package/backend/dist/esm/backend/src/database/filters/strict_filter_v1.js +44 -0
  105. package/backend/dist/esm/backend/src/database/filters/strict_filter_v2.d.ts +75 -0
  106. package/backend/dist/esm/backend/src/database/filters/strict_filter_v2.js +5 -0
  107. package/backend/dist/esm/backend/src/database/filters/strict_filter_v3.d.ts +219 -0
  108. package/backend/dist/esm/backend/src/database/filters/strict_filter_v3.js +1 -0
  109. package/backend/dist/esm/backend/src/database/filters/strict_update_filter.d.ts +165 -0
  110. package/backend/dist/esm/backend/src/database/filters/strict_update_filter.js +5 -0
  111. package/backend/dist/esm/backend/src/database/filters/strict_update_filter_test.d.ts +5 -0
  112. package/backend/dist/esm/backend/src/database/filters/strict_update_filter_test.js +405 -0
  113. package/backend/dist/esm/backend/src/database/flatten.d.ts +75 -0
  114. package/backend/dist/esm/backend/src/database/flatten.js +22 -0
  115. package/backend/dist/esm/backend/src/database/flatten_test.d.ts +1 -0
  116. package/backend/dist/esm/backend/src/database/flatten_test.js +174 -0
  117. package/backend/dist/esm/backend/src/database/quota/quota.d.ts +461 -0
  118. package/backend/dist/esm/backend/src/database/quota/quota.js +1118 -0
  119. package/backend/dist/esm/backend/src/database/quota/quota_v1.d.ts +534 -0
  120. package/backend/dist/esm/backend/src/database/quota/quota_v1.js +1242 -0
  121. package/backend/dist/esm/backend/src/database/quota/safe_int.d.ts +293 -0
  122. package/backend/dist/esm/backend/src/database/quota/safe_int.js +602 -0
  123. package/backend/dist/{cjs → esm/backend/src}/endpoint.d.ts +69 -46
  124. package/backend/dist/esm/{endpoint.js → backend/src/endpoint.js} +136 -127
  125. package/backend/dist/esm/backend/src/errors/index.d.ts +7 -0
  126. package/backend/dist/esm/backend/src/errors/index.js +7 -0
  127. package/backend/dist/{cjs/utils.d.ts → esm/backend/src/errors/internal_external.d.ts} +14 -22
  128. package/backend/dist/esm/backend/src/errors/internal_external.js +70 -0
  129. package/backend/dist/esm/backend/src/errors/invalid_usage_error.d.ts +38 -0
  130. package/backend/dist/esm/backend/src/errors/invalid_usage_error.js +30 -0
  131. package/backend/dist/esm/backend/src/errors/system_error.d.ts +230 -0
  132. package/backend/dist/esm/backend/src/errors/system_error.js +402 -0
  133. package/backend/dist/esm/backend/src/events.d.ts +54 -0
  134. package/backend/dist/esm/backend/src/events.js +5 -0
  135. package/backend/dist/esm/{frontend.js → backend/src/frontend.js} +1 -1
  136. package/backend/dist/esm/{image_endpoint.d.ts → backend/src/image_endpoint.d.ts} +16 -1
  137. package/backend/dist/esm/{image_endpoint.js → backend/src/image_endpoint.js} +16 -20
  138. package/backend/dist/esm/backend/src/logger.d.ts +5 -0
  139. package/backend/dist/esm/backend/src/logger.js +8 -0
  140. package/backend/dist/esm/backend/src/meta.d.ts +64 -0
  141. package/backend/dist/esm/{meta.js → backend/src/meta.js} +15 -54
  142. package/backend/dist/esm/backend/src/payments/paddle.d.ts +326 -0
  143. package/backend/dist/esm/{payments → backend/src/payments}/paddle.js +417 -452
  144. package/backend/dist/esm/backend/src/plugins/browser.d.ts +1 -0
  145. package/backend/dist/esm/backend/src/plugins/browser.js +170 -0
  146. package/backend/dist/esm/backend/src/plugins/mail/mail.d.ts +248 -0
  147. package/backend/dist/esm/backend/src/plugins/mail/mail.js +389 -0
  148. package/backend/dist/{cjs → esm/backend/src}/plugins/mail/ui.d.ts +23 -0
  149. package/backend/dist/esm/{plugins → backend/src/plugins}/mail/ui.js +3 -6
  150. package/backend/dist/esm/backend/src/plugins/pdf.d.ts +1 -0
  151. package/backend/dist/esm/{plugins → backend/src/plugins}/pdf.js +3 -3
  152. package/backend/dist/esm/backend/src/rate_limit.d.ts +145 -0
  153. package/backend/dist/esm/backend/src/rate_limit.js +667 -0
  154. package/backend/dist/esm/{route.d.ts → backend/src/route.d.ts} +3 -10
  155. package/backend/dist/esm/{route.js → backend/src/route.js} +26 -21
  156. package/backend/dist/esm/backend/src/server.d.ts +485 -0
  157. package/backend/dist/esm/{server.js → backend/src/server.js} +891 -1441
  158. package/backend/dist/esm/backend/src/splash_screen.d.ts +80 -0
  159. package/backend/dist/esm/{splash_screen.js → backend/src/splash_screen.js} +42 -55
  160. package/backend/dist/esm/backend/src/status.d.ts +74 -0
  161. package/backend/dist/esm/backend/src/status.js +199 -0
  162. package/backend/dist/esm/backend/src/stream.d.ts +376 -0
  163. package/backend/dist/esm/{stream.js → backend/src/stream.js} +327 -292
  164. package/backend/dist/esm/backend/src/users.d.ts +809 -0
  165. package/backend/dist/esm/backend/src/users.js +2140 -0
  166. package/backend/dist/esm/backend/src/utils.d.ts +16 -0
  167. package/backend/dist/esm/{utils.js → backend/src/utils.js} +20 -81
  168. package/backend/dist/{cjs → esm/backend/src}/view.d.ts +33 -11
  169. package/backend/dist/esm/{view.js → backend/src/view.js} +266 -86
  170. package/backend/dist/{cjs → esm/backend/src}/volt.d.ts +10 -1
  171. package/backend/dist/esm/{volt.js → backend/src/volt.js} +7 -4
  172. package/backend/dist/esm/frontend/src/modules/request.d.ts +70 -0
  173. package/backend/dist/esm/frontend/src/modules/request.js +117 -0
  174. package/frontend/dist/backend/src/database/collection.d.ts +1543 -0
  175. package/frontend/dist/backend/src/database/collection.js +3510 -0
  176. package/frontend/dist/backend/src/database/database.d.ts +66 -0
  177. package/frontend/dist/backend/src/database/database.js +196 -0
  178. package/frontend/dist/backend/src/database/filters/filters.d.ts +6 -0
  179. package/frontend/dist/backend/src/database/filters/filters.js +1 -0
  180. package/frontend/dist/backend/src/database/filters/strict_filter.d.ts +223 -0
  181. package/frontend/dist/backend/src/database/filters/strict_filter.js +3 -0
  182. package/frontend/dist/backend/src/database/filters/strict_update_filter.d.ts +165 -0
  183. package/frontend/dist/backend/src/database/filters/strict_update_filter.js +5 -0
  184. package/frontend/dist/backend/src/database/flatten.d.ts +75 -0
  185. package/frontend/dist/backend/src/database/flatten.js +22 -0
  186. package/frontend/dist/backend/src/endpoint.d.ts +204 -0
  187. package/frontend/dist/backend/src/endpoint.js +570 -0
  188. package/frontend/dist/backend/src/errors/index.d.ts +7 -0
  189. package/frontend/dist/backend/src/errors/index.js +7 -0
  190. package/frontend/dist/backend/src/errors/internal_external.d.ts +38 -0
  191. package/frontend/dist/backend/src/errors/internal_external.js +70 -0
  192. package/frontend/dist/backend/src/errors/invalid_usage_error.d.ts +38 -0
  193. package/frontend/dist/backend/src/errors/invalid_usage_error.js +30 -0
  194. package/frontend/dist/backend/src/errors/system_error.d.ts +230 -0
  195. package/frontend/dist/backend/src/errors/system_error.js +402 -0
  196. package/frontend/dist/backend/src/events.d.ts +54 -0
  197. package/frontend/dist/backend/src/events.js +5 -0
  198. package/frontend/dist/backend/src/frontend.d.ts +11 -0
  199. package/frontend/dist/backend/src/frontend.js +12 -0
  200. package/frontend/dist/backend/src/image_endpoint.d.ts +39 -0
  201. package/frontend/dist/backend/src/image_endpoint.js +202 -0
  202. package/frontend/dist/backend/src/meta.d.ts +64 -0
  203. package/frontend/dist/backend/src/meta.js +110 -0
  204. package/frontend/dist/backend/src/payments/paddle.d.ts +326 -0
  205. package/frontend/dist/backend/src/payments/paddle.js +2256 -0
  206. package/frontend/dist/backend/src/plugins/mail/mail.d.ts +248 -0
  207. package/frontend/dist/backend/src/plugins/mail/mail.js +389 -0
  208. package/{backend/dist/esm/plugins/mail.d.ts → frontend/dist/backend/src/plugins/mail/ui.d.ts} +23 -0
  209. package/{backend/dist/esm/plugins/mail.js → frontend/dist/backend/src/plugins/mail/ui.js} +3 -6
  210. package/frontend/dist/backend/src/rate_limit.d.ts +145 -0
  211. package/frontend/dist/backend/src/rate_limit.js +673 -0
  212. package/frontend/dist/backend/src/route.d.ts +35 -0
  213. package/frontend/dist/backend/src/route.js +212 -0
  214. package/frontend/dist/backend/src/server.d.ts +485 -0
  215. package/frontend/dist/backend/src/server.js +2670 -0
  216. package/frontend/dist/backend/src/splash_screen.d.ts +80 -0
  217. package/frontend/dist/backend/src/splash_screen.js +135 -0
  218. package/frontend/dist/backend/src/status.d.ts +74 -0
  219. package/frontend/dist/backend/src/status.js +199 -0
  220. package/frontend/dist/backend/src/stream.d.ts +376 -0
  221. package/frontend/dist/backend/src/stream.js +1007 -0
  222. package/frontend/dist/backend/src/users.d.ts +807 -0
  223. package/frontend/dist/backend/src/users.js +2118 -0
  224. package/frontend/dist/backend/src/utils.d.ts +16 -0
  225. package/frontend/dist/backend/src/utils.js +241 -0
  226. package/frontend/dist/backend/src/view.d.ts +162 -0
  227. package/frontend/dist/backend/src/view.js +720 -0
  228. package/frontend/dist/frontend/src/elements/base.d.ts +4414 -0
  229. package/frontend/dist/{elements → frontend/src/elements}/base.js +3624 -260
  230. package/frontend/dist/frontend/src/elements/module.d.ts +95 -0
  231. package/frontend/dist/{elements → frontend/src/elements}/module.js +53 -52
  232. package/frontend/dist/frontend/src/elements/types.d.ts +52 -0
  233. package/frontend/dist/frontend/src/elements/types.js +5 -0
  234. package/frontend/dist/frontend/src/modules/attachment.d.ts +126 -0
  235. package/frontend/dist/frontend/src/modules/attachment.js +306 -0
  236. package/frontend/dist/frontend/src/modules/auth.d.ts +44 -0
  237. package/frontend/dist/frontend/src/modules/auth.js +80 -0
  238. package/frontend/dist/{modules → frontend/src/modules}/color.js +2 -2
  239. package/frontend/dist/frontend/src/modules/compression.d.ts +39 -0
  240. package/frontend/dist/frontend/src/modules/compression.js +102 -0
  241. package/frontend/dist/frontend/src/modules/cookies.d.ts +44 -0
  242. package/frontend/dist/frontend/src/modules/cookies.js +143 -0
  243. package/frontend/dist/frontend/src/modules/events.d.ts +31 -0
  244. package/frontend/dist/frontend/src/modules/events.js +74 -0
  245. package/frontend/dist/frontend/src/modules/google.d.ts +23 -0
  246. package/frontend/dist/frontend/src/modules/google.js +52 -0
  247. package/frontend/dist/frontend/src/modules/meta.d.ts +14 -0
  248. package/frontend/dist/{modules → frontend/src/modules}/meta.js +9 -7
  249. package/frontend/dist/{modules → frontend/src/modules}/paddle.d.ts +37 -134
  250. package/frontend/dist/{modules → frontend/src/modules}/paddle.js +620 -568
  251. package/frontend/dist/frontend/src/modules/request.d.ts +70 -0
  252. package/frontend/dist/frontend/src/modules/request.js +117 -0
  253. package/frontend/dist/frontend/src/modules/settings.d.ts +3 -0
  254. package/frontend/dist/frontend/src/modules/settings.js +5 -0
  255. package/frontend/dist/frontend/src/modules/statics.d.ts +21 -0
  256. package/frontend/dist/{modules → frontend/src/modules}/statics.js +15 -18
  257. package/frontend/dist/frontend/src/modules/support.d.ts +30 -0
  258. package/frontend/dist/frontend/src/modules/support.js +53 -0
  259. package/frontend/dist/{modules → frontend/src/modules}/theme.d.ts +67 -0
  260. package/frontend/dist/{modules → frontend/src/modules}/theme.js +68 -38
  261. package/frontend/dist/frontend/src/modules/themes.d.ts +12 -0
  262. package/frontend/dist/frontend/src/modules/themes.js +22 -0
  263. package/frontend/dist/frontend/src/modules/user.d.ts +164 -0
  264. package/frontend/dist/frontend/src/modules/user.js +268 -0
  265. package/frontend/dist/frontend/src/modules/utils.d.ts +176 -0
  266. package/frontend/dist/frontend/src/modules/utils.js +569 -0
  267. package/frontend/dist/frontend/src/types/gradient.d.ts +29 -0
  268. package/frontend/dist/{types → frontend/src/types}/gradient.js +14 -18
  269. package/frontend/dist/frontend/src/ui/border_button.d.ts +94 -0
  270. package/frontend/dist/{ui → frontend/src/ui}/border_button.js +7 -13
  271. package/frontend/dist/frontend/src/ui/button.d.ts +28 -0
  272. package/frontend/dist/{ui → frontend/src/ui}/button.js +21 -12
  273. package/frontend/dist/frontend/src/ui/canvas.d.ts +138 -0
  274. package/frontend/dist/{ui → frontend/src/ui}/canvas.js +88 -55
  275. package/frontend/dist/frontend/src/ui/checkbox.d.ts +74 -0
  276. package/frontend/dist/{ui → frontend/src/ui}/checkbox.js +80 -41
  277. package/frontend/dist/{ui → frontend/src/ui}/code.d.ts +73 -6
  278. package/frontend/dist/{ui → frontend/src/ui}/code.js +55 -52
  279. package/frontend/dist/{ui → frontend/src/ui}/context_menu.d.ts +4 -0
  280. package/frontend/dist/{ui → frontend/src/ui}/context_menu.js +12 -17
  281. package/frontend/dist/{ui → frontend/src/ui}/css.d.ts +4 -0
  282. package/frontend/dist/{ui → frontend/src/ui}/css.js +3 -3
  283. package/frontend/dist/{ui → frontend/src/ui}/divider.d.ts +4 -0
  284. package/frontend/dist/{ui → frontend/src/ui}/divider.js +3 -3
  285. package/frontend/dist/{ui → frontend/src/ui}/dropdown.d.ts +57 -2
  286. package/frontend/dist/{ui → frontend/src/ui}/dropdown.js +87 -94
  287. package/frontend/dist/{ui → frontend/src/ui}/for_each.d.ts +4 -0
  288. package/frontend/dist/{ui → frontend/src/ui}/for_each.js +3 -3
  289. package/frontend/dist/{ui → frontend/src/ui}/form.d.ts +6 -2
  290. package/frontend/dist/{ui → frontend/src/ui}/form.js +10 -7
  291. package/frontend/dist/frontend/src/ui/frame_modes.d.ts +37 -0
  292. package/frontend/dist/{ui → frontend/src/ui}/frame_modes.js +16 -22
  293. package/frontend/dist/{ui → frontend/src/ui}/google_map.d.ts +4 -0
  294. package/frontend/dist/{ui → frontend/src/ui}/google_map.js +4 -4
  295. package/frontend/dist/{ui → frontend/src/ui}/gradient.d.ts +4 -0
  296. package/frontend/dist/{ui → frontend/src/ui}/gradient.js +3 -3
  297. package/frontend/dist/{ui → frontend/src/ui}/image.d.ts +4 -0
  298. package/frontend/dist/{ui → frontend/src/ui}/image.js +5 -5
  299. package/frontend/dist/frontend/src/ui/input.d.ts +392 -0
  300. package/frontend/dist/{ui → frontend/src/ui}/input.js +346 -360
  301. package/frontend/dist/{ui → frontend/src/ui}/link.d.ts +4 -0
  302. package/frontend/dist/{ui → frontend/src/ui}/link.js +3 -3
  303. package/frontend/dist/{ui → frontend/src/ui}/list.d.ts +4 -0
  304. package/frontend/dist/{ui → frontend/src/ui}/list.js +12 -6
  305. package/frontend/dist/frontend/src/ui/loader_button.d.ts +80 -0
  306. package/frontend/dist/{ui → frontend/src/ui}/loader_button.js +35 -47
  307. package/frontend/dist/frontend/src/ui/loaders.d.ts +57 -0
  308. package/frontend/dist/{ui → frontend/src/ui}/loaders.js +11 -11
  309. package/frontend/dist/{ui → frontend/src/ui}/popup.d.ts +11 -6
  310. package/frontend/dist/{ui → frontend/src/ui}/popup.js +32 -18
  311. package/frontend/dist/frontend/src/ui/pseudo.d.ts +44 -0
  312. package/frontend/dist/{ui → frontend/src/ui}/pseudo.js +84 -8
  313. package/frontend/dist/{ui → frontend/src/ui}/scroller.d.ts +14 -2
  314. package/frontend/dist/{ui → frontend/src/ui}/scroller.js +37 -43
  315. package/frontend/dist/{ui → frontend/src/ui}/slider.d.ts +5 -1
  316. package/frontend/dist/{ui → frontend/src/ui}/slider.js +4 -4
  317. package/frontend/dist/{ui → frontend/src/ui}/spacer.d.ts +4 -0
  318. package/frontend/dist/{ui → frontend/src/ui}/spacer.js +3 -3
  319. package/frontend/dist/{ui → frontend/src/ui}/span.d.ts +4 -0
  320. package/frontend/dist/{ui → frontend/src/ui}/span.js +3 -3
  321. package/frontend/dist/{ui → frontend/src/ui}/stack.d.ts +4 -0
  322. package/frontend/dist/{ui → frontend/src/ui}/stack.js +3 -9
  323. package/frontend/dist/frontend/src/ui/steps.d.ts +131 -0
  324. package/frontend/dist/{ui → frontend/src/ui}/steps.js +30 -45
  325. package/frontend/dist/{ui → frontend/src/ui}/style.d.ts +4 -0
  326. package/frontend/dist/{ui → frontend/src/ui}/style.js +3 -3
  327. package/frontend/dist/{ui → frontend/src/ui}/switch.d.ts +5 -1
  328. package/frontend/dist/{ui → frontend/src/ui}/switch.js +4 -4
  329. package/frontend/dist/{ui → frontend/src/ui}/table.d.ts +4 -0
  330. package/frontend/dist/{ui → frontend/src/ui}/table.js +6 -6
  331. package/frontend/dist/{ui → frontend/src/ui}/tabs.d.ts +45 -3
  332. package/frontend/dist/{ui → frontend/src/ui}/tabs.js +65 -40
  333. package/frontend/dist/{ui → frontend/src/ui}/text.d.ts +4 -0
  334. package/frontend/dist/{ui → frontend/src/ui}/text.js +3 -3
  335. package/frontend/dist/frontend/src/ui/title.d.ts +91 -0
  336. package/frontend/dist/frontend/src/ui/title.js +272 -0
  337. package/frontend/dist/{ui → frontend/src/ui}/view.d.ts +4 -0
  338. package/frontend/dist/{ui → frontend/src/ui}/view.js +3 -3
  339. package/frontend/dist/{volt.d.ts → frontend/src/volt.d.ts} +3 -0
  340. package/frontend/dist/{volt.js → frontend/src/volt.js} +4 -0
  341. package/frontend/tools/bundle_d_ts.js +71 -0
  342. package/frontend/tools/convert_to_jsdoc_input.txt +9452 -0
  343. package/frontend/tools/convert_to_jsdoc_output.txt +7626 -0
  344. package/frontend/tools/convert_to_jsdoc_tmp.js +345 -0
  345. package/package.json +11 -12
  346. package/backend/dist/cjs/database/collection.d.ts +0 -160
  347. package/backend/dist/cjs/database/collection.js +0 -842
  348. package/backend/dist/cjs/database/database.d.ts +0 -121
  349. package/backend/dist/cjs/database/document.d.ts +0 -131
  350. package/backend/dist/cjs/database/document.js +0 -224
  351. package/backend/dist/cjs/database.d.ts +0 -502
  352. package/backend/dist/cjs/database.js +0 -2248
  353. package/backend/dist/cjs/logger.d.ts +0 -3
  354. package/backend/dist/cjs/meta.d.ts +0 -50
  355. package/backend/dist/cjs/mutex.d.ts +0 -24
  356. package/backend/dist/cjs/payments/paddle.d.ts +0 -160
  357. package/backend/dist/cjs/plugins/browser.d.ts +0 -36
  358. package/backend/dist/cjs/plugins/browser.js +0 -198
  359. package/backend/dist/cjs/plugins/css.d.ts +0 -11
  360. package/backend/dist/cjs/plugins/css.js +0 -80
  361. package/backend/dist/cjs/plugins/mail.d.ts +0 -277
  362. package/backend/dist/cjs/plugins/mail.js +0 -1370
  363. package/backend/dist/cjs/plugins/ts/compiler.d.ts +0 -139
  364. package/backend/dist/cjs/plugins/ts/compiler.js +0 -750
  365. package/backend/dist/cjs/plugins/ts/preprocessing.d.ts +0 -14
  366. package/backend/dist/cjs/plugins/ts/preprocessing.js +0 -440
  367. package/backend/dist/cjs/rate_limit.d.ts +0 -63
  368. package/backend/dist/cjs/rate_limit.js +0 -348
  369. package/backend/dist/cjs/request.deprc.d.ts +0 -48
  370. package/backend/dist/cjs/request.deprc.js +0 -572
  371. package/backend/dist/cjs/response.deprc.d.ts +0 -55
  372. package/backend/dist/cjs/response.deprc.js +0 -275
  373. package/backend/dist/cjs/server.d.ts +0 -342
  374. package/backend/dist/cjs/splash_screen.d.ts +0 -35
  375. package/backend/dist/cjs/status.d.ts +0 -61
  376. package/backend/dist/cjs/stream.d.ts +0 -79
  377. package/backend/dist/cjs/users.d.ts +0 -111
  378. package/backend/dist/cjs/users.js +0 -1817
  379. package/backend/dist/cjs/view.js +0 -352
  380. package/backend/dist/cjs/vinc.dev.d.ts +0 -3
  381. package/backend/dist/cjs/vinc.dev.js +0 -7
  382. package/backend/dist/css/adyen.css +0 -92
  383. package/backend/dist/css/volt.css +0 -70
  384. package/backend/dist/esm/database/collection.d.ts +0 -160
  385. package/backend/dist/esm/database/collection.js +0 -1328
  386. package/backend/dist/esm/database/database.d.ts +0 -121
  387. package/backend/dist/esm/database/document.d.ts +0 -131
  388. package/backend/dist/esm/database/document.js +0 -247
  389. package/backend/dist/esm/database.d.ts +0 -502
  390. package/backend/dist/esm/database.js +0 -2423
  391. package/backend/dist/esm/file_watcher.js +0 -329
  392. package/backend/dist/esm/logger.d.ts +0 -3
  393. package/backend/dist/esm/logger.js +0 -11
  394. package/backend/dist/esm/meta.d.ts +0 -50
  395. package/backend/dist/esm/mutex.d.ts +0 -24
  396. package/backend/dist/esm/mutex.js +0 -48
  397. package/backend/dist/esm/payments/paddle.d.ts +0 -160
  398. package/backend/dist/esm/plugins/browser.d.ts +0 -36
  399. package/backend/dist/esm/plugins/browser.js +0 -176
  400. package/backend/dist/esm/plugins/css.d.ts +0 -11
  401. package/backend/dist/esm/plugins/css.js +0 -90
  402. package/backend/dist/esm/plugins/ts/compiler.d.ts +0 -139
  403. package/backend/dist/esm/plugins/ts/compiler.js +0 -1194
  404. package/backend/dist/esm/plugins/ts/preprocessing.d.ts +0 -14
  405. package/backend/dist/esm/plugins/ts/preprocessing.js +0 -726
  406. package/backend/dist/esm/rate_limit.d.ts +0 -63
  407. package/backend/dist/esm/rate_limit.js +0 -417
  408. package/backend/dist/esm/request.deprc.d.ts +0 -48
  409. package/backend/dist/esm/request.deprc.js +0 -572
  410. package/backend/dist/esm/response.deprc.d.ts +0 -55
  411. package/backend/dist/esm/response.deprc.js +0 -275
  412. package/backend/dist/esm/server.d.ts +0 -342
  413. package/backend/dist/esm/splash_screen.d.ts +0 -35
  414. package/backend/dist/esm/status.d.ts +0 -61
  415. package/backend/dist/esm/status.js +0 -197
  416. package/backend/dist/esm/stream.d.ts +0 -79
  417. package/backend/dist/esm/users.d.ts +0 -111
  418. package/backend/dist/esm/users.js +0 -1935
  419. package/backend/dist/esm/vinc.dev.d.ts +0 -3
  420. package/backend/dist/esm/vinc.dev.js +0 -7
  421. package/frontend/dist/elements/base.d.ts +0 -9889
  422. package/frontend/dist/elements/module.d.ts +0 -30
  423. package/frontend/dist/modules/array.d.ts +0 -94
  424. package/frontend/dist/modules/array.js +0 -634
  425. package/frontend/dist/modules/auth.d.ts +0 -46
  426. package/frontend/dist/modules/auth.js +0 -139
  427. package/frontend/dist/modules/colors.d.ts +0 -1
  428. package/frontend/dist/modules/colors.js +0 -417
  429. package/frontend/dist/modules/compression.d.ts +0 -6
  430. package/frontend/dist/modules/compression.js +0 -999
  431. package/frontend/dist/modules/cookies.d.ts +0 -18
  432. package/frontend/dist/modules/cookies.js +0 -167
  433. package/frontend/dist/modules/date.d.ts +0 -142
  434. package/frontend/dist/modules/date.js +0 -493
  435. package/frontend/dist/modules/events.d.ts +0 -8
  436. package/frontend/dist/modules/events.js +0 -91
  437. package/frontend/dist/modules/google.d.ts +0 -11
  438. package/frontend/dist/modules/google.js +0 -54
  439. package/frontend/dist/modules/meta.d.ts +0 -10
  440. package/frontend/dist/modules/mutex.d.ts +0 -7
  441. package/frontend/dist/modules/mutex.js +0 -51
  442. package/frontend/dist/modules/number.d.ts +0 -16
  443. package/frontend/dist/modules/number.js +0 -23
  444. package/frontend/dist/modules/object.d.ts +0 -52
  445. package/frontend/dist/modules/object.js +0 -383
  446. package/frontend/dist/modules/scheme.d.ts +0 -227
  447. package/frontend/dist/modules/scheme.js +0 -531
  448. package/frontend/dist/modules/settings.d.ts +0 -3
  449. package/frontend/dist/modules/settings.js +0 -4
  450. package/frontend/dist/modules/statics.d.ts +0 -5
  451. package/frontend/dist/modules/string.d.ts +0 -124
  452. package/frontend/dist/modules/string.js +0 -745
  453. package/frontend/dist/modules/support.d.ts +0 -19
  454. package/frontend/dist/modules/support.js +0 -103
  455. package/frontend/dist/modules/themes.d.ts +0 -8
  456. package/frontend/dist/modules/themes.js +0 -18
  457. package/frontend/dist/modules/user.d.ts +0 -59
  458. package/frontend/dist/modules/user.js +0 -280
  459. package/frontend/dist/modules/utils.d.ts +0 -87
  460. package/frontend/dist/modules/utils.js +0 -923
  461. package/frontend/dist/types/gradient.d.ts +0 -12
  462. package/frontend/dist/ui/border_button.d.ts +0 -152
  463. package/frontend/dist/ui/button.d.ts +0 -21
  464. package/frontend/dist/ui/canvas.d.ts +0 -56
  465. package/frontend/dist/ui/checkbox.d.ts +0 -52
  466. package/frontend/dist/ui/frame_modes.d.ts +0 -25
  467. package/frontend/dist/ui/input.d.ts +0 -241
  468. package/frontend/dist/ui/loader_button.d.ts +0 -93
  469. package/frontend/dist/ui/loaders.d.ts +0 -57
  470. package/frontend/dist/ui/pseudo.d.ts +0 -16
  471. package/frontend/dist/ui/steps.d.ts +0 -59
  472. package/frontend/dist/ui/title.d.ts +0 -21
  473. package/frontend/dist/ui/title.js +0 -121
  474. package/frontend/examples/dashboard/dashboard.ts +0 -776
  475. /package/backend/dist/cjs/{cli.d.ts → backend/src/cli.d.ts} +0 -0
  476. /package/backend/dist/cjs/{file_watcher.d.ts → backend/src/database/document.d.ts} +0 -0
  477. /package/backend/dist/cjs/{file_watcher.js → backend/src/database/document.js} +0 -0
  478. /package/backend/dist/cjs/{plugins/pdf.d.ts → backend/src/database/filters/strict_filter_test.d.ts} +0 -0
  479. /package/backend/dist/{esm/file_watcher.d.ts → cjs/backend/src/database/filters/strict_filter_test_v0.d.ts} +0 -0
  480. /package/backend/dist/{esm/plugins/pdf.d.ts → cjs/backend/src/database/flatten_test.d.ts} +0 -0
  481. /package/backend/dist/cjs/{frontend.d.ts → backend/src/frontend.d.ts} +0 -0
  482. /package/backend/dist/cjs/{plugins → backend/src/plugins}/communication.d.ts +0 -0
  483. /package/backend/dist/cjs/{plugins → backend/src/plugins}/communication.js +0 -0
  484. /package/backend/dist/cjs/{plugins → backend/src/plugins}/mail/ui.js +0 -0
  485. /package/backend/dist/cjs/{plugins → backend/src/plugins}/pdf.js +0 -0
  486. /package/backend/dist/cjs/{plugins → backend/src/plugins}/thread_monitor.d.ts +0 -0
  487. /package/backend/dist/cjs/{plugins → backend/src/plugins}/thread_monitor.js +0 -0
  488. /package/backend/dist/cjs/{vinc.d.ts → backend/src/vinc.d.ts} +0 -0
  489. /package/backend/dist/cjs/{vinc.js → backend/src/vinc.js} +0 -0
  490. /package/backend/dist/esm/{cli.d.ts → backend/src/cli.d.ts} +0 -0
  491. /package/backend/dist/esm/{frontend.d.ts → backend/src/frontend.d.ts} +0 -0
  492. /package/backend/dist/esm/{plugins → backend/src/plugins}/communication.d.ts +0 -0
  493. /package/backend/dist/esm/{plugins → backend/src/plugins}/communication.js +0 -0
  494. /package/backend/dist/esm/{plugins → backend/src/plugins}/thread_monitor.d.ts +0 -0
  495. /package/backend/dist/esm/{plugins → backend/src/plugins}/thread_monitor.js +0 -0
  496. /package/backend/dist/esm/{vinc.d.ts → backend/src/vinc.d.ts} +0 -0
  497. /package/backend/dist/esm/{vinc.js → backend/src/vinc.js} +0 -0
  498. /package/frontend/dist/{elements → frontend/src/elements}/register_element.d.ts +0 -0
  499. /package/frontend/dist/{elements → frontend/src/elements}/register_element.js +0 -0
  500. /package/frontend/dist/{modules → frontend/src/modules}/color.d.ts +0 -0
  501. /package/frontend/dist/{ui → frontend/src/ui}/ui.d.ts +0 -0
  502. /package/frontend/dist/{ui → frontend/src/ui}/ui.js +0 -0
@@ -0,0 +1,143 @@
1
+ /**
2
+ * @author Daan van den Bergh
3
+ * @copyright © 2022 - 2025 Daan van den Bergh. All rights reserved
4
+ */
5
+ // Imports.
6
+ import { Google } from "./google.js";
7
+ // Cookies object.
8
+ export var Cookies;
9
+ (function (Cookies) {
10
+ let _cookies = {};
11
+ let _last_cookies = '';
12
+ Cookies.enabled = false;
13
+ /**
14
+ * Checks if cookies need to be parsed again.
15
+ * @docs
16
+ */
17
+ function is_parse_required() {
18
+ return document.cookie !== _last_cookies;
19
+ }
20
+ Cookies.is_parse_required = is_parse_required;
21
+ /**
22
+ * Get cookies or a specific cookie by name.
23
+ * @experimental true
24
+ * @param name The name of the cookie.
25
+ * @docs
26
+ */
27
+ function get(name = null) {
28
+ if (document.cookie === _last_cookies) {
29
+ if (name != null) {
30
+ return _cookies[name];
31
+ }
32
+ return _cookies;
33
+ }
34
+ // Attributes.
35
+ _cookies = {};
36
+ _last_cookies = document.cookie;
37
+ // Vars.
38
+ let is_key = true, is_str = null;
39
+ let key = "", value = "";
40
+ // Wrapper.
41
+ const append = () => {
42
+ if (key.length > 0) {
43
+ _cookies[key] = decodeURIComponent(value);
44
+ }
45
+ value = "";
46
+ key = "";
47
+ is_key = true;
48
+ is_str = null;
49
+ };
50
+ // Parse.
51
+ for (let i = 0; i < document.cookie.length; i++) {
52
+ const c = document.cookie.charAt(i);
53
+ // Is key.
54
+ if (is_key) {
55
+ if (c === " " || c === "\t") {
56
+ continue;
57
+ }
58
+ else if (c === "=") {
59
+ is_key = false;
60
+ }
61
+ else {
62
+ key += c;
63
+ }
64
+ }
65
+ // Is value.
66
+ else {
67
+ // End of string.
68
+ if (is_str != null && is_str === c) {
69
+ value = value.substr(1, value.length - 1);
70
+ append();
71
+ }
72
+ // End of cookie.
73
+ else if (c === ";") {
74
+ append();
75
+ }
76
+ // Append to value.
77
+ else {
78
+ // Start of string.
79
+ if (value.length === 0 && (c === "\"" || c === "'")) {
80
+ is_str = c;
81
+ }
82
+ value += c;
83
+ }
84
+ }
85
+ }
86
+ append();
87
+ if (name != null) {
88
+ return _cookies[name];
89
+ }
90
+ return _cookies;
91
+ }
92
+ Cookies.get = get;
93
+ /**
94
+ * Checks if the user has set a cookie preference (enabled or disabled).
95
+ * @docs
96
+ */
97
+ function has_preference() {
98
+ const pref = localStorage.getItem("volt_cookies_enabled");
99
+ return pref === "true" || pref === "false";
100
+ }
101
+ Cookies.has_preference = has_preference;
102
+ // Check if all the cookies are accepted.
103
+ /**
104
+ * Checks if cookies are accepted by the user.
105
+ * @docs
106
+ */
107
+ function is_accepted() {
108
+ return localStorage.getItem("volt_cookies_enabled") === "true";
109
+ }
110
+ Cookies.is_accepted = is_accepted;
111
+ /**
112
+ * Enables cookies (opt-in) and updates the user's preference.
113
+ * @param _set_storage Whether to update the localStorage preference (default: true).
114
+ * @docs
115
+ */
116
+ function enable(_set_storage = true) {
117
+ Cookies.enabled = true;
118
+ if (_set_storage) {
119
+ localStorage.setItem("volt_cookies_enabled", "true");
120
+ }
121
+ Google.disable_tracking();
122
+ }
123
+ Cookies.enable = enable;
124
+ /**
125
+ * Disables cookies (opt-out) and updates the user's preference.
126
+ * @param _set_storage Whether to update the localStorage preference (default: true).
127
+ * @docs
128
+ */
129
+ function disable(_set_storage = true) {
130
+ Cookies.enabled = false;
131
+ if (_set_storage) {
132
+ localStorage.setItem("volt_cookies_enabled", "false");
133
+ }
134
+ Google.enable_tracking();
135
+ }
136
+ Cookies.disable = disable;
137
+ // Initialize cookies.
138
+ if (is_accepted())
139
+ enable(false);
140
+ else
141
+ disable(false);
142
+ })(Cookies || (Cookies = {}));
143
+ export { Cookies as cookies }; // also export as lowercase for compatibility.
@@ -0,0 +1,31 @@
1
+ /**
2
+ * @author Daan van den Bergh
3
+ * @copyright © 2022 - 2025 Daan van den Bergh. All rights reserved
4
+ */
5
+ export declare namespace Events {
6
+ const events: Map<string, [any, (element: any, args: any) => void][]>;
7
+ /**
8
+ * Emit a registered event.
9
+ * @param id The id of the registered event to emit.
10
+ * @param args The arguments that will be passed to the registered callbacks.
11
+ * @docs
12
+ */
13
+ function emit(id: string, args?: Record<string, any>): void;
14
+ /**
15
+ * Set a callback for an event.
16
+ * @param id The id of the registered event to emit.
17
+ * @param element The element.
18
+ * @param callback The callback function, accepts parameters `(element, args)`.
19
+ * @docs
20
+ */
21
+ function on<T extends object>(id: string, element: T, callback: (element: T, args: Record<string, any>) => void): void;
22
+ /**
23
+ * Remove a callback for an event.
24
+ * @param id The id of the registered event to emit.
25
+ * @param element The element.
26
+ * @param callback The callback function to remove. When left undefined, all callbacks matching to that element will be removed.
27
+ * @docs
28
+ */
29
+ function remove<T extends object>(id: string, element: T, callback?: (element: T, args: Record<string, any>) => void): void;
30
+ }
31
+ export { Events as events };
@@ -0,0 +1,74 @@
1
+ /**
2
+ * @author Daan van den Bergh
3
+ * @copyright © 2022 - 2025 Daan van den Bergh. All rights reserved
4
+ */
5
+ // Events module.
6
+ export var Events;
7
+ (function (Events) {
8
+ Events.events = new Map();
9
+ // Emit an event.
10
+ /**
11
+ * Emit a registered event.
12
+ * @param id The id of the registered event to emit.
13
+ * @param args The arguments that will be passed to the registered callbacks.
14
+ * @docs
15
+ */
16
+ function emit(id, args = {}) {
17
+ const callbacks = Events.events.get(id);
18
+ if (callbacks == null) {
19
+ return;
20
+ }
21
+ callbacks.forEach((i) => {
22
+ i[1](i[0], args);
23
+ });
24
+ }
25
+ Events.emit = emit;
26
+ // On event.
27
+ /**
28
+ * Set a callback for an event.
29
+ * @param id The id of the registered event to emit.
30
+ * @param element The element.
31
+ * @param callback The callback function, accepts parameters `(element, args)`.
32
+ * @docs
33
+ */
34
+ function on(id, element, callback) {
35
+ let callbacks = Events.events.get(id);
36
+ if (callbacks == null) {
37
+ callbacks = [];
38
+ Events.events.set(id, callbacks);
39
+ }
40
+ callbacks.push([element, callback]);
41
+ }
42
+ Events.on = on;
43
+ // Remove a callback for an event.
44
+ /**
45
+ * Remove a callback for an event.
46
+ * @param id The id of the registered event to emit.
47
+ * @param element The element.
48
+ * @param callback The callback function to remove. When left undefined, all callbacks matching to that element will be removed.
49
+ * @docs
50
+ */
51
+ function remove(id, element, callback) {
52
+ const callbacks = Events.events.get(id);
53
+ if (callbacks == null) {
54
+ return;
55
+ }
56
+ const filtered = [];
57
+ callbacks.forEach((i) => {
58
+ if (i[0] === element && (callback == null || i[1] === callback)) {
59
+ return;
60
+ }
61
+ filtered.push(i);
62
+ });
63
+ Events.events.set(id, filtered);
64
+ }
65
+ Events.remove = remove;
66
+ })(Events || (Events = {}));
67
+ export { Events as events }; // also export as lowercase for compatibility.
68
+ // Fire the onload event.
69
+ /**
70
+ * Fires the `volt.on_load` event when the window finishes loading.
71
+ */
72
+ window.onload = () => {
73
+ Events.emit("volt.on_load");
74
+ };
@@ -0,0 +1,23 @@
1
+ /**
2
+ * @author Daan van den Bergh
3
+ * @copyright © 2022 - 2025 Daan van den Bergh. All rights reserved
4
+ */
5
+ export declare namespace Google {
6
+ const id: string;
7
+ /**
8
+ * Enable google analytics tracking
9
+ * @nav Fronted/Google
10
+ * @docs
11
+ */
12
+ function enable_tracking(): void;
13
+ /**
14
+ * Disable google analytics tracking
15
+ * @nav Fronted/Google
16
+ * @docs
17
+ */
18
+ function disable_tracking(): void;
19
+ const cloud: {
20
+ api_key: string;
21
+ };
22
+ }
23
+ export { Google as google };
@@ -0,0 +1,52 @@
1
+ /**
2
+ * @author Daan van den Bergh
3
+ * @copyright © 2022 - 2025 Daan van den Bergh. All rights reserved
4
+ */
5
+ // Google wrapper module.
6
+ export var Google;
7
+ (function (Google) {
8
+ Google.id = "{{GOOGLE_TAG}}";
9
+ // Source: https://developers.google.com/analytics/devguides/collection/gajs/#disable
10
+ /**
11
+ * Enable google analytics tracking
12
+ * @nav Fronted/Google
13
+ * @docs
14
+ */
15
+ function enable_tracking() {
16
+ // document.cookie = "ga-opt-out=false; Path=/; SameSite=None;";
17
+ delete window[`ga-disable-${Google.id}`];
18
+ }
19
+ Google.enable_tracking = enable_tracking;
20
+ // Source: https://developers.google.com/analytics/devguides/collection/gajs/#disable
21
+ /**
22
+ * Disable google analytics tracking
23
+ * @nav Fronted/Google
24
+ * @docs
25
+ */
26
+ function disable_tracking() {
27
+ // document.cookie = "ga-opt-out=true; Path=/; SameSite=None;";
28
+ window[`ga-disable-${Google.id}`] = true;
29
+ }
30
+ Google.disable_tracking = disable_tracking;
31
+ // Auto initialize (internal use).
32
+ function _initialize() {
33
+ if (Google.id && typeof window !== "undefined") {
34
+ // @ts-ignore
35
+ window.dataLayer = window.dataLayer || [];
36
+ function gtag(...args) {
37
+ // @ts-ignore
38
+ window.dataLayer.push(args);
39
+ }
40
+ gtag('js', new Date());
41
+ gtag('config', Google.id);
42
+ }
43
+ }
44
+ // Google cloud.
45
+ Google.cloud = {
46
+ api_key: "{{GOOGLE_COULD_API_KEY}}",
47
+ };
48
+ // Initialize.
49
+ _initialize();
50
+ })(Google || (Google = {}));
51
+ ;
52
+ export { Google as google }; // also export as lowercase for compatibility.
@@ -0,0 +1,14 @@
1
+ /**
2
+ * @author Daan van den Bergh
3
+ * @copyright © 2022 - 2025 Daan van den Bergh. All rights reserved
4
+ */
5
+ export declare namespace Meta {
6
+ function set({ author, title, description, image, favicon, }: {
7
+ author?: string;
8
+ title?: string;
9
+ description?: string;
10
+ image?: string;
11
+ favicon?: string;
12
+ }): void;
13
+ }
14
+ export { Meta as meta };
@@ -1,11 +1,12 @@
1
- /*
2
- * Author: Daan van den Bergh
3
- * Copyright: © 2022 - 2024 Daan van den Bergh.
1
+ /**
2
+ * @author Daan van den Bergh
3
+ * @copyright © 2022 - 2025 Daan van den Bergh. All rights reserved
4
4
  */
5
5
  // Meta module.
6
- export const Meta = {
6
+ export var Meta;
7
+ (function (Meta) {
7
8
  // Set title.
8
- set({ author, title, description, image, favicon, }) {
9
+ function set({ author, title, description, image, favicon, }) {
9
10
  const set_content_query = (query, content) => {
10
11
  const e = document.querySelector(query);
11
12
  if (e) {
@@ -41,6 +42,7 @@ export const Meta = {
41
42
  set_content_og("og:image", image);
42
43
  set_content_og("twitter:image", description);
43
44
  }
44
- },
45
- };
45
+ }
46
+ Meta.set = set;
47
+ })(Meta || (Meta = {}));
46
48
  export { Meta as meta }; // also export as lowercase for compatibility.
@@ -1,8 +1,12 @@
1
- declare const Payments: {
2
- client_key: string;
3
- sandbox: boolean;
4
- tax_inclusive: boolean;
5
- countries: {
1
+ import type { Paddle as PaddleBackend, Product } from "../../../backend/src/payments/paddle.js";
2
+ import { Request } from "./request.js";
3
+ /**
4
+ * @deprecated using stripe from now on.
5
+ */
6
+ export declare namespace Payments {
7
+ const sandbox: boolean;
8
+ const tax_inclusive: boolean;
9
+ const countries: {
6
10
  AD: {
7
11
  name: string;
8
12
  calling_code: string;
@@ -1000,84 +1004,9 @@ declare const Payments: {
1000
1004
  calling_code: string;
1001
1005
  };
1002
1006
  };
1003
- _paddle_initialized: boolean;
1004
- _payment_element: any;
1005
- _sign_in_redirect: string | undefined | null;
1006
- _step: number;
1007
- _steps_element: any;
1008
- _steps_container: any;
1009
- _overview_container: any;
1010
- _order_container: any;
1011
- _billing_container: any;
1012
- _payment_container: any;
1013
- _processing_container: any;
1014
- _checkout_button: any;
1015
- _prev_step_button: any;
1016
- _style: any;
1017
- _currency_symbol: string | undefined;
1018
- _render_payment_element_reject: undefined | Function;
1019
- _render_payment_element_resolve: undefined | Function;
1020
- _refunds_element: any;
1021
- _refunds_container: any;
1022
- _processing_element: any;
1023
- _theme: any;
1024
- _products: any;
1025
- _days_refundable: number;
1026
- on_error: (data: string | Error) => void;
1027
- _refund_policy: string | undefined;
1028
- _cancellation_policy: string | undefined;
1029
- _billing_element: any;
1030
- _billing_details: any;
1031
- _overview_subtotal: any;
1032
- _overview_total: any;
1033
- _overview_subtotal_tax: any;
1034
- _overview_tax_container: any;
1035
- _overview_incl_excl_tax: any;
1036
- _overview_element: any;
1037
- _order_element: any;
1038
- /**
1039
- * Initialize Paddle with the provided client key and set up event callbacks.
1040
- */
1041
- _initialize_paddle: () => void;
1042
- /**
1043
- * Reset the payment element by removing it if it exists.
1044
- */
1045
- _reset: () => void;
1046
- /**
1047
- * Initialize the order by verifying authentication and making a POST request.
1048
- */
1049
- _init_order: () => Promise<void>;
1050
- /**
1051
- * Set the current step in the payment process.
1052
- */
1053
- _set_step: () => Promise<void | null>;
1054
- /**
1055
- * Navigate to the next step in the payment process.
1056
- */
1057
- _next: () => Promise<void | null>;
1058
- /**
1059
- * Navigate to the previous step in the payment process.
1060
- */
1061
- _prev: () => Promise<void | null>;
1062
- /**
1063
- * Render the steps element in the UI.
1064
- */
1065
- _render_steps_element: () => void;
1066
- /**
1067
- * Render the overview element in the UI.
1068
- */
1069
- _render_overview_element: () => void;
1070
- /**
1071
- * Render the order element in the UI.
1072
- */
1073
- _render_order_element: () => void;
1074
- _render_refunds_element: () => void;
1075
- _render_billing_element: () => void;
1076
- _render_payment_element: () => Promise<void>;
1077
- _render_processing_element: () => void;
1078
- _show_processing: (status?: string | null) => Promise<void>;
1079
- _update_processing: (status: string) => Promise<void>;
1080
- style: ({ theme, font_size, border_radius, bg, bg_1, divider_bg, fg, fg_1, fg_2, theme_fg, missing_fg, selected, button, }?: {
1007
+ let on_error: (data: string | Error) => any;
1008
+ function style({ theme, // light or dark
1009
+ font_size, border_radius, bg, bg_1, divider_bg, fg, fg_1, fg_2, theme_fg, missing_fg, selected, button, }?: {
1081
1010
  theme?: string | undefined;
1082
1011
  font_size?: number | undefined;
1083
1012
  border_radius?: number | undefined;
@@ -1102,22 +1031,7 @@ declare const Payments: {
1102
1031
  border_inset: boolean;
1103
1032
  hover_brightness: number[];
1104
1033
  } | undefined;
1105
- }) => void;
1106
- create_checkout_dropin: ({ steps_container, order_container, billing_container, payment_container, processing_container, overview_container, sign_in_redirect, on_error, }: {
1107
- steps_container: any;
1108
- order_container: any;
1109
- billing_container: any;
1110
- payment_container: any;
1111
- processing_container: any;
1112
- overview_container: any;
1113
- sign_in_redirect?: string | null;
1114
- on_error?: (error: string | Error) => void;
1115
- }) => void;
1116
- create_refunds_dropin: ({ refunds_container, days_refundable, on_error, }: {
1117
- refunds_container: any;
1118
- days_refundable?: number;
1119
- on_error?: (error: any) => void;
1120
- }) => void;
1034
+ }): void;
1121
1035
  /**
1122
1036
  * @docs:
1123
1037
  * @nav: Frontend
@@ -1130,7 +1044,7 @@ declare const Payments: {
1130
1044
  * @name: currency
1131
1045
  * @description: The currency from the product object.
1132
1046
  */
1133
- get_currency_symbol: (currency: string) => string | null;
1047
+ function get_currency_symbol(currency: string): string | null;
1134
1048
  /**
1135
1049
  * @docs:
1136
1050
  * @nav: Frontend
@@ -1140,7 +1054,7 @@ declare const Payments: {
1140
1054
  * @type: array[object]
1141
1055
  * @return: Returns the backend defined payment products.
1142
1056
  */
1143
- get_products: () => Promise<any[]>;
1057
+ function get_products(): Request.ResultPromiseFromInfo<PaddleBackend.Endpoints.GetProducts>;
1144
1058
  /**
1145
1059
  * @docs:
1146
1060
  * @nav: Frontend
@@ -1155,7 +1069,7 @@ declare const Payments: {
1155
1069
  * @type: string
1156
1070
  * @desc: The id of the payment product.
1157
1071
  */
1158
- get_product: (id: string) => Promise<any>;
1072
+ function get_product(id: string): Request.ResultPromise<Product>;
1159
1073
  /**
1160
1074
  * @docs:
1161
1075
  * @nav: Frontend
@@ -1168,7 +1082,7 @@ declare const Payments: {
1168
1082
  * @type: string
1169
1083
  * @desc: The id of the payment.
1170
1084
  */
1171
- get_payment: (id: string) => Promise<any>;
1085
+ function get_payment(payload: PaddleBackend.Endpoints.GetPayment["payload"]): Request.ResultPromiseFromInfo<PaddleBackend.Endpoints.GetPayment>;
1172
1086
  /**
1173
1087
  * @docs:
1174
1088
  * @nav: Frontend
@@ -1197,11 +1111,7 @@ declare const Payments: {
1197
1111
  * @value: "paid"
1198
1112
  * @desc: Payments that are paid.
1199
1113
  */
1200
- get_payments: ({ days, limit, status, }?: {
1201
- days?: number | undefined;
1202
- limit?: null | undefined;
1203
- status?: null | undefined;
1204
- }) => Promise<any>;
1114
+ function get_payments(payload: PaddleBackend.Endpoints.GetPayments["payload"]): Request.ResultPromiseFromInfo<PaddleBackend.Endpoints.GetPayments>;
1205
1115
  /**
1206
1116
  * @docs:
1207
1117
  * @nav: Frontend
@@ -1217,10 +1127,7 @@ declare const Payments: {
1217
1127
  * @type: number
1218
1128
  * @desc: Limit the amount of response payment objects.
1219
1129
  */
1220
- get_refundable_payments: ({ days, limit, }?: {
1221
- days?: number | undefined;
1222
- limit?: null | undefined;
1223
- }) => Promise<any>;
1130
+ function get_refundable_payments(payload?: PaddleBackend.Endpoints.GetRefundablePayments["payload"]): Request.ResultPromiseFromInfo<PaddleBackend.Endpoints.GetRefundablePayments>;
1224
1131
  /**
1225
1132
  * @docs:
1226
1133
  * @nav: Frontend
@@ -1236,10 +1143,7 @@ declare const Payments: {
1236
1143
  * @type: number
1237
1144
  * @desc: Limit the amount of response payment objects.
1238
1145
  */
1239
- get_refunded_payments: ({ days, limit, }?: {
1240
- days?: number | undefined;
1241
- limit?: null | undefined;
1242
- }) => Promise<any>;
1146
+ function get_refunded_payments(payload?: PaddleBackend.Endpoints.GetRefundedPayments["payload"]): Request.ResultPromiseFromInfo<PaddleBackend.Endpoints.GetRefundedPayments>;
1243
1147
  /**
1244
1148
  * @docs:
1245
1149
  * @nav: Frontend
@@ -1255,10 +1159,7 @@ declare const Payments: {
1255
1159
  * @type: number
1256
1160
  * @desc: Limit the amount of response payment objects.
1257
1161
  */
1258
- get_refunding_payments: ({ days, limit, }?: {
1259
- days?: null | undefined;
1260
- limit?: null | undefined;
1261
- }) => Promise<any>;
1162
+ function get_refunding_payments(payload?: PaddleBackend.Endpoints.GetRefundingPayments["payload"]): Request.ResultPromiseFromInfo<PaddleBackend.Endpoints.GetRefundingPayments>;
1262
1163
  /**
1263
1164
  * @docs:
1264
1165
  * @nav: Frontend
@@ -1281,7 +1182,7 @@ declare const Payments: {
1281
1182
  * @type: string
1282
1183
  * @desc: The refund reason.
1283
1184
  */
1284
- create_refund: (payment: number | string, line_items?: any[] | null, reason?: string) => Promise<any>;
1185
+ function create_refund(payload: PaddleBackend.Endpoints.RefundPayment["payload"]): Request.ResultPromiseFromInfo<PaddleBackend.Endpoints.RefundPayment>;
1285
1186
  /**
1286
1187
  * @docs:
1287
1188
  * @nav: Frontend
@@ -1295,7 +1196,7 @@ declare const Payments: {
1295
1196
  * @type: string
1296
1197
  * @desc: The product id.
1297
1198
  */
1298
- cancel_subscription: (product: string) => Promise<any>;
1199
+ function cancel_subscription(payload: PaddleBackend.Endpoints.CancelSubscription["payload"]): Request.ResultPromiseFromInfo<PaddleBackend.Endpoints.CancelSubscription>;
1299
1200
  /**
1300
1201
  * @docs:
1301
1202
  * @nav: Frontend
@@ -1308,7 +1209,7 @@ declare const Payments: {
1308
1209
  * @type: string
1309
1210
  * @desc: The product id.
1310
1211
  */
1311
- is_subscribed: (product: string) => Promise<any>;
1212
+ function is_subscribed(payload: PaddleBackend.Endpoints.IsSubscribed["payload"]): Request.ResultPromiseFromInfo<PaddleBackend.Endpoints.IsSubscribed>;
1312
1213
  /**
1313
1214
  * @docs:
1314
1215
  * @nav: Frontend
@@ -1316,9 +1217,12 @@ declare const Payments: {
1316
1217
  * @title: Get active subscriptions
1317
1218
  * @desc: Get the active subscriptions of the authenticated user.
1318
1219
  */
1319
- get_active_subscriptions: () => Promise<any>;
1320
- cart: {
1321
- items: any[];
1220
+ function get_active_subscriptions(): Request.ResultPromiseFromInfo<PaddleBackend.Endpoints.GetActiveSubscriptions>;
1221
+ namespace Cart {
1222
+ let items: {
1223
+ product: Product;
1224
+ quantity: number;
1225
+ }[];
1322
1226
  /**
1323
1227
  * @docs:
1324
1228
  * @nav: Frontend
@@ -1329,7 +1233,7 @@ declare const Payments: {
1329
1233
  *
1330
1234
  * The current cart items are accessible as `Payments.cart.items`.
1331
1235
  */
1332
- refresh: () => void;
1236
+ function refresh(): void;
1333
1237
  /**
1334
1238
  * @docs:
1335
1239
  * @nav: Frontend
@@ -1340,7 +1244,7 @@ declare const Payments: {
1340
1244
  *
1341
1245
  * The current cart items are accessible as `Payments.cart.items`.
1342
1246
  */
1343
- save: () => void;
1247
+ function save(): void;
1344
1248
  /**
1345
1249
  * @docs:
1346
1250
  * @nav: Frontend
@@ -1363,7 +1267,7 @@ declare const Payments: {
1363
1267
  * @description: The quantity to add.
1364
1268
  * @type: number
1365
1269
  */
1366
- add: (id: string, quantity?: number) => Promise<void>;
1270
+ function add(id: string, quantity?: number): Promise<void>;
1367
1271
  /**
1368
1272
  * @docs:
1369
1273
  * @nav: Frontend
@@ -1384,7 +1288,7 @@ declare const Payments: {
1384
1288
  * @description: The quantity to remove. When the quantity value is "all", the entire product will be removed from the shopping cart.
1385
1289
  * @type: number | "all"
1386
1290
  */
1387
- remove: (id: string, quantity?: number | "all") => Promise<void>;
1291
+ function remove(id: string, quantity?: number | "all"): Promise<void>;
1388
1292
  /**
1389
1293
  * @docs:
1390
1294
  * @nav: Frontend
@@ -1397,8 +1301,7 @@ declare const Payments: {
1397
1301
  *
1398
1302
  * The current cart items are accessible as `Payments.cart.items`.
1399
1303
  */
1400
- clear: () => Promise<void>;
1401
- };
1402
- };
1403
- export { Payments };
1304
+ function clear(): Promise<void>;
1305
+ }
1306
+ }
1404
1307
  export { Payments as payments };