godown 2.7.7 → 3.0.0-canary.1

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 (736) hide show
  1. package/README.md +44 -80
  2. package/alert.d.ts +2 -3
  3. package/alert.d.ts.map +1 -1
  4. package/alert.js +5 -4
  5. package/alert.js.map +1 -1
  6. package/avatar.d.ts +2 -3
  7. package/avatar.d.ts.map +1 -1
  8. package/avatar.js +5 -4
  9. package/avatar.js.map +1 -1
  10. package/breath.d.ts +9 -0
  11. package/breath.d.ts.map +1 -0
  12. package/breath.js +6 -0
  13. package/breath.js.map +1 -0
  14. package/button.d.ts +2 -3
  15. package/button.d.ts.map +1 -1
  16. package/button.js +5 -4
  17. package/button.js.map +1 -1
  18. package/card.d.ts +2 -3
  19. package/card.d.ts.map +1 -1
  20. package/card.js +5 -4
  21. package/card.js.map +1 -1
  22. package/carousel.d.ts +2 -3
  23. package/carousel.d.ts.map +1 -1
  24. package/carousel.js +5 -4
  25. package/carousel.js.map +1 -1
  26. package/components/alert.d.ts +50 -0
  27. package/components/alert.d.ts.map +1 -0
  28. package/components/alert.js +167 -0
  29. package/components/alert.js.map +1 -0
  30. package/components/avatar.d.ts +26 -0
  31. package/components/avatar.d.ts.map +1 -0
  32. package/components/avatar.js +62 -0
  33. package/components/avatar.js.map +1 -0
  34. package/components/breath.d.ts +34 -0
  35. package/components/breath.d.ts.map +1 -0
  36. package/components/breath.js +80 -0
  37. package/components/breath.js.map +1 -0
  38. package/{web-components/button → components}/button.d.ts +6 -5
  39. package/components/button.d.ts.map +1 -0
  40. package/components/button.js +167 -0
  41. package/components/button.js.map +1 -0
  42. package/components/card.d.ts +20 -0
  43. package/components/card.d.ts.map +1 -0
  44. package/components/card.js +55 -0
  45. package/components/card.js.map +1 -0
  46. package/components/carousel.d.ts +40 -0
  47. package/components/carousel.d.ts.map +1 -0
  48. package/components/carousel.js +113 -0
  49. package/components/carousel.js.map +1 -0
  50. package/{web-components/details → components}/details.d.ts +5 -3
  51. package/components/details.d.ts.map +1 -0
  52. package/components/details.js +50 -0
  53. package/components/details.js.map +1 -0
  54. package/components/dialog.d.ts +33 -0
  55. package/components/dialog.d.ts.map +1 -0
  56. package/components/dialog.js +92 -0
  57. package/components/dialog.js.map +1 -0
  58. package/components/divider.d.ts +17 -0
  59. package/components/divider.d.ts.map +1 -0
  60. package/components/divider.js +37 -0
  61. package/components/divider.js.map +1 -0
  62. package/{web-components/wrapper → components}/dragbox.d.ts +15 -5
  63. package/components/dragbox.d.ts.map +1 -0
  64. package/components/dragbox.js +110 -0
  65. package/components/dragbox.js.map +1 -0
  66. package/components/flex.d.ts +31 -0
  67. package/components/flex.d.ts.map +1 -0
  68. package/components/flex.js +55 -0
  69. package/components/flex.js.map +1 -0
  70. package/{web-components/form → components}/form.d.ts +4 -2
  71. package/components/form.d.ts.map +1 -0
  72. package/components/form.js +78 -0
  73. package/components/form.js.map +1 -0
  74. package/components/grid.d.ts +31 -0
  75. package/components/grid.d.ts.map +1 -0
  76. package/components/grid.js +56 -0
  77. package/components/grid.js.map +1 -0
  78. package/components/input.d.ts +20 -0
  79. package/components/input.d.ts.map +1 -0
  80. package/components/input.js +54 -0
  81. package/components/input.js.map +1 -0
  82. package/components/layout.d.ts +29 -0
  83. package/components/layout.d.ts.map +1 -0
  84. package/components/layout.js +48 -0
  85. package/components/layout.js.map +1 -0
  86. package/components/link.d.ts +20 -0
  87. package/components/link.d.ts.map +1 -0
  88. package/components/link.js +43 -0
  89. package/components/link.js.map +1 -0
  90. package/{web-components/progress → components}/progress.d.ts +5 -3
  91. package/components/progress.d.ts.map +1 -0
  92. package/components/progress.js +68 -0
  93. package/components/progress.js.map +1 -0
  94. package/components/range.d.ts +60 -0
  95. package/components/range.d.ts.map +1 -0
  96. package/components/range.js +193 -0
  97. package/components/range.js.map +1 -0
  98. package/{web-components/wrapper → components}/rotate.d.ts +4 -8
  99. package/components/rotate.d.ts.map +1 -0
  100. package/components/rotate.js +57 -0
  101. package/components/rotate.js.map +1 -0
  102. package/components/router.d.ts +121 -0
  103. package/components/router.d.ts.map +1 -0
  104. package/components/router.js +251 -0
  105. package/components/router.js.map +1 -0
  106. package/components/select.d.ts +50 -0
  107. package/components/select.d.ts.map +1 -0
  108. package/components/select.js +211 -0
  109. package/components/select.js.map +1 -0
  110. package/{web-components/skeleton → components}/skeleton.d.ts +6 -6
  111. package/components/skeleton.d.ts.map +1 -0
  112. package/components/skeleton.js +56 -0
  113. package/components/skeleton.js.map +1 -0
  114. package/components/split.d.ts +32 -0
  115. package/components/split.d.ts.map +1 -0
  116. package/components/split.js +121 -0
  117. package/components/split.js.map +1 -0
  118. package/{web-components/input/switch-input.d.ts → components/switch.d.ts} +9 -10
  119. package/components/switch.d.ts.map +1 -0
  120. package/components/switch.js +93 -0
  121. package/components/switch.js.map +1 -0
  122. package/{web-components/text → components}/text.d.ts +5 -3
  123. package/components/text.d.ts.map +1 -0
  124. package/components/text.js +44 -0
  125. package/components/text.js.map +1 -0
  126. package/{web-components/text → components}/time.d.ts +5 -3
  127. package/components/time.d.ts.map +1 -0
  128. package/components/time.js +139 -0
  129. package/components/time.js.map +1 -0
  130. package/components/tooltip.d.ts +38 -0
  131. package/components/tooltip.d.ts.map +1 -0
  132. package/components/tooltip.js +67 -0
  133. package/components/tooltip.js.map +1 -0
  134. package/{web-components/text → components}/typewriter.d.ts +5 -3
  135. package/components/typewriter.d.ts.map +1 -0
  136. package/components/typewriter.js +130 -0
  137. package/components/typewriter.js.map +1 -0
  138. package/core/global-style.d.ts +21 -0
  139. package/core/global-style.d.ts.map +1 -0
  140. package/core/global-style.js +46 -0
  141. package/core/global-style.js.map +1 -0
  142. package/core/super-anchor.d.ts +15 -0
  143. package/core/super-anchor.d.ts.map +1 -0
  144. package/core/super-anchor.js +39 -0
  145. package/core/super-anchor.js.map +1 -0
  146. package/core/super-input.d.ts +39 -0
  147. package/core/super-input.d.ts.map +1 -0
  148. package/core/super-input.js +115 -0
  149. package/core/super-input.js.map +1 -0
  150. package/{proto → core}/super-openable.d.ts +4 -8
  151. package/core/super-openable.d.ts.map +1 -0
  152. package/core/super-openable.js +38 -0
  153. package/core/super-openable.js.map +1 -0
  154. package/custom-elements.json +1 -0
  155. package/details.d.ts +2 -3
  156. package/details.d.ts.map +1 -1
  157. package/details.js +5 -4
  158. package/details.js.map +1 -1
  159. package/dev/alert.d.ts +8 -0
  160. package/dev/alert.d.ts.map +1 -0
  161. package/dev/alert.js +4 -0
  162. package/dev/alert.js.map +1 -0
  163. package/dev/avatar.d.ts +8 -0
  164. package/dev/avatar.d.ts.map +1 -0
  165. package/dev/avatar.js +4 -0
  166. package/dev/avatar.js.map +1 -0
  167. package/dev/breath.d.ts +9 -0
  168. package/dev/breath.d.ts.map +1 -0
  169. package/dev/breath.js +5 -0
  170. package/dev/breath.js.map +1 -0
  171. package/dev/button.d.ts +8 -0
  172. package/dev/button.d.ts.map +1 -0
  173. package/dev/button.js +4 -0
  174. package/dev/button.js.map +1 -0
  175. package/dev/card.d.ts +8 -0
  176. package/dev/card.d.ts.map +1 -0
  177. package/dev/card.js +4 -0
  178. package/dev/card.js.map +1 -0
  179. package/dev/carousel.d.ts +8 -0
  180. package/dev/carousel.d.ts.map +1 -0
  181. package/dev/carousel.js +4 -0
  182. package/dev/carousel.js.map +1 -0
  183. package/dev/components/alert.d.ts +50 -0
  184. package/dev/components/alert.d.ts.map +1 -0
  185. package/dev/components/alert.js +234 -0
  186. package/dev/components/alert.js.map +1 -0
  187. package/dev/components/avatar.d.ts +26 -0
  188. package/dev/components/avatar.d.ts.map +1 -0
  189. package/dev/components/avatar.js +91 -0
  190. package/dev/components/avatar.js.map +1 -0
  191. package/dev/components/breath.d.ts +34 -0
  192. package/dev/components/breath.d.ts.map +1 -0
  193. package/dev/components/breath.js +133 -0
  194. package/dev/components/breath.js.map +1 -0
  195. package/dev/components/button.d.ts +45 -0
  196. package/dev/components/button.d.ts.map +1 -0
  197. package/{web-components/button → dev/components}/button.js +76 -76
  198. package/dev/components/button.js.map +1 -0
  199. package/dev/components/card.d.ts +20 -0
  200. package/dev/components/card.d.ts.map +1 -0
  201. package/dev/components/card.js +89 -0
  202. package/dev/components/card.js.map +1 -0
  203. package/dev/components/carousel.d.ts +40 -0
  204. package/dev/components/carousel.d.ts.map +1 -0
  205. package/dev/components/carousel.js +155 -0
  206. package/dev/components/carousel.js.map +1 -0
  207. package/dev/components/details.d.ts +20 -0
  208. package/dev/components/details.d.ts.map +1 -0
  209. package/dev/components/details.js +115 -0
  210. package/dev/components/details.js.map +1 -0
  211. package/dev/components/dialog.d.ts +33 -0
  212. package/dev/components/dialog.d.ts.map +1 -0
  213. package/dev/components/dialog.js +154 -0
  214. package/dev/components/dialog.js.map +1 -0
  215. package/dev/components/divider.d.ts +17 -0
  216. package/dev/components/divider.d.ts.map +1 -0
  217. package/dev/components/divider.js +46 -0
  218. package/dev/components/divider.js.map +1 -0
  219. package/dev/components/dragbox.d.ts +40 -0
  220. package/dev/components/dragbox.d.ts.map +1 -0
  221. package/{web-components/wrapper → dev/components}/dragbox.js +27 -15
  222. package/dev/components/dragbox.js.map +1 -0
  223. package/dev/components/flex.d.ts +31 -0
  224. package/dev/components/flex.d.ts.map +1 -0
  225. package/dev/components/flex.js +52 -0
  226. package/dev/components/flex.js.map +1 -0
  227. package/dev/components/form.d.ts +24 -0
  228. package/dev/components/form.d.ts.map +1 -0
  229. package/{web-components/form → dev/components}/form.js +11 -11
  230. package/dev/components/form.js.map +1 -0
  231. package/dev/components/grid.d.ts +31 -0
  232. package/dev/components/grid.d.ts.map +1 -0
  233. package/dev/components/grid.js +53 -0
  234. package/dev/components/grid.js.map +1 -0
  235. package/dev/components/input.d.ts +20 -0
  236. package/dev/components/input.d.ts.map +1 -0
  237. package/dev/components/input.js +89 -0
  238. package/dev/components/input.js.map +1 -0
  239. package/dev/components/layout.d.ts +29 -0
  240. package/dev/components/layout.d.ts.map +1 -0
  241. package/dev/components/layout.js +69 -0
  242. package/dev/components/layout.js.map +1 -0
  243. package/dev/components/link.d.ts +20 -0
  244. package/dev/components/link.d.ts.map +1 -0
  245. package/dev/components/link.js +40 -0
  246. package/dev/components/link.js.map +1 -0
  247. package/dev/components/progress.d.ts +30 -0
  248. package/dev/components/progress.d.ts.map +1 -0
  249. package/{web-components/progress → dev/components}/progress.js +12 -11
  250. package/dev/components/progress.js.map +1 -0
  251. package/dev/components/range.d.ts +60 -0
  252. package/dev/components/range.d.ts.map +1 -0
  253. package/{web-components/input/range-input.js → dev/components/range.js} +82 -92
  254. package/dev/components/range.js.map +1 -0
  255. package/dev/components/rotate.d.ts +26 -0
  256. package/dev/components/rotate.d.ts.map +1 -0
  257. package/{web-components/wrapper → dev/components}/rotate.js +14 -20
  258. package/dev/components/rotate.js.map +1 -0
  259. package/dev/components/router.d.ts +121 -0
  260. package/dev/components/router.d.ts.map +1 -0
  261. package/dev/components/router.js +248 -0
  262. package/dev/components/router.js.map +1 -0
  263. package/dev/components/select.d.ts +50 -0
  264. package/dev/components/select.d.ts.map +1 -0
  265. package/dev/components/select.js +243 -0
  266. package/dev/components/select.js.map +1 -0
  267. package/dev/components/skeleton.d.ts +26 -0
  268. package/dev/components/skeleton.d.ts.map +1 -0
  269. package/dev/components/skeleton.js +119 -0
  270. package/dev/components/skeleton.js.map +1 -0
  271. package/dev/components/split.d.ts +32 -0
  272. package/dev/components/split.d.ts.map +1 -0
  273. package/dev/components/split.js +173 -0
  274. package/dev/components/split.js.map +1 -0
  275. package/dev/components/switch.d.ts +39 -0
  276. package/dev/components/switch.d.ts.map +1 -0
  277. package/{web-components/input/switch-input.js → dev/components/switch.js} +53 -59
  278. package/dev/components/switch.js.map +1 -0
  279. package/dev/components/text.d.ts +19 -0
  280. package/dev/components/text.d.ts.map +1 -0
  281. package/{web-components/text → dev/components}/text.js +22 -23
  282. package/dev/components/text.js.map +1 -0
  283. package/dev/components/time.d.ts +53 -0
  284. package/dev/components/time.d.ts.map +1 -0
  285. package/{web-components/text → dev/components}/time.js +12 -18
  286. package/dev/components/time.js.map +1 -0
  287. package/dev/components/tooltip.d.ts +38 -0
  288. package/dev/components/tooltip.d.ts.map +1 -0
  289. package/dev/components/tooltip.js +114 -0
  290. package/dev/components/tooltip.js.map +1 -0
  291. package/dev/components/typewriter.d.ts +55 -0
  292. package/dev/components/typewriter.d.ts.map +1 -0
  293. package/{web-components/text → dev/components}/typewriter.js +21 -19
  294. package/dev/components/typewriter.js.map +1 -0
  295. package/dev/core/global-style.d.ts +21 -0
  296. package/dev/core/global-style.d.ts.map +1 -0
  297. package/dev/core/global-style.js +77 -0
  298. package/dev/core/global-style.js.map +1 -0
  299. package/dev/core/super-anchor.d.ts +15 -0
  300. package/dev/core/super-anchor.d.ts.map +1 -0
  301. package/dev/core/super-anchor.js +58 -0
  302. package/dev/core/super-anchor.js.map +1 -0
  303. package/dev/core/super-input.d.ts +39 -0
  304. package/dev/core/super-input.d.ts.map +1 -0
  305. package/dev/core/super-input.js +181 -0
  306. package/dev/core/super-input.js.map +1 -0
  307. package/dev/core/super-openable.d.ts +19 -0
  308. package/dev/core/super-openable.d.ts.map +1 -0
  309. package/{proto → dev/core}/super-openable.js +6 -13
  310. package/dev/core/super-openable.js.map +1 -0
  311. package/dev/details.d.ts +8 -0
  312. package/dev/details.d.ts.map +1 -0
  313. package/dev/details.js +4 -0
  314. package/dev/details.js.map +1 -0
  315. package/dev/dialog.d.ts +8 -0
  316. package/dev/dialog.d.ts.map +1 -0
  317. package/dev/dialog.js +4 -0
  318. package/dev/dialog.js.map +1 -0
  319. package/dev/divider.d.ts +8 -0
  320. package/dev/divider.d.ts.map +1 -0
  321. package/dev/divider.js +4 -0
  322. package/dev/divider.js.map +1 -0
  323. package/dev/dragbox.d.ts +8 -0
  324. package/dev/dragbox.d.ts.map +1 -0
  325. package/dev/dragbox.js +4 -0
  326. package/dev/dragbox.js.map +1 -0
  327. package/dev/flex.d.ts +8 -0
  328. package/dev/flex.d.ts.map +1 -0
  329. package/dev/flex.js +4 -0
  330. package/dev/flex.js.map +1 -0
  331. package/dev/form.d.ts +8 -0
  332. package/dev/form.d.ts.map +1 -0
  333. package/dev/form.js +4 -0
  334. package/dev/form.js.map +1 -0
  335. package/dev/grid.d.ts +8 -0
  336. package/dev/grid.d.ts.map +1 -0
  337. package/dev/grid.js +4 -0
  338. package/dev/grid.js.map +1 -0
  339. package/dev/index.d.ts +29 -0
  340. package/dev/index.d.ts.map +1 -0
  341. package/dev/index.js +29 -0
  342. package/dev/index.js.map +1 -0
  343. package/dev/input.d.ts +9 -0
  344. package/dev/input.d.ts.map +1 -0
  345. package/dev/input.js +5 -0
  346. package/dev/input.js.map +1 -0
  347. package/dev/layout.d.ts +9 -0
  348. package/dev/layout.d.ts.map +1 -0
  349. package/dev/layout.js +5 -0
  350. package/dev/layout.js.map +1 -0
  351. package/dev/link.d.ts +9 -0
  352. package/dev/link.d.ts.map +1 -0
  353. package/dev/link.js +5 -0
  354. package/dev/link.js.map +1 -0
  355. package/dev/progress.d.ts +9 -0
  356. package/dev/progress.d.ts.map +1 -0
  357. package/dev/progress.js +5 -0
  358. package/dev/progress.js.map +1 -0
  359. package/dev/range.d.ts +9 -0
  360. package/dev/range.d.ts.map +1 -0
  361. package/dev/range.js +5 -0
  362. package/dev/range.js.map +1 -0
  363. package/dev/rotate.d.ts +9 -0
  364. package/dev/rotate.d.ts.map +1 -0
  365. package/dev/rotate.js +5 -0
  366. package/dev/rotate.js.map +1 -0
  367. package/dev/router.d.ts +9 -0
  368. package/dev/router.d.ts.map +1 -0
  369. package/dev/router.js +5 -0
  370. package/dev/router.js.map +1 -0
  371. package/dev/select.d.ts +9 -0
  372. package/dev/select.d.ts.map +1 -0
  373. package/dev/select.js +5 -0
  374. package/dev/select.js.map +1 -0
  375. package/dev/skeleton.d.ts +9 -0
  376. package/dev/skeleton.d.ts.map +1 -0
  377. package/dev/skeleton.js +5 -0
  378. package/dev/skeleton.js.map +1 -0
  379. package/dev/split.d.ts +9 -0
  380. package/dev/split.d.ts.map +1 -0
  381. package/dev/split.js +5 -0
  382. package/dev/split.js.map +1 -0
  383. package/dev/switch.d.ts +9 -0
  384. package/dev/switch.d.ts.map +1 -0
  385. package/dev/switch.js +5 -0
  386. package/dev/switch.js.map +1 -0
  387. package/dev/text.d.ts +9 -0
  388. package/dev/text.d.ts.map +1 -0
  389. package/dev/text.js +5 -0
  390. package/dev/text.js.map +1 -0
  391. package/dev/time.d.ts +9 -0
  392. package/dev/time.d.ts.map +1 -0
  393. package/dev/time.js +5 -0
  394. package/dev/time.js.map +1 -0
  395. package/dev/tooltip.d.ts +9 -0
  396. package/dev/tooltip.d.ts.map +1 -0
  397. package/dev/tooltip.js +5 -0
  398. package/dev/tooltip.js.map +1 -0
  399. package/dev/typewriter.d.ts +8 -0
  400. package/dev/typewriter.d.ts.map +1 -0
  401. package/dev/typewriter.js +4 -0
  402. package/dev/typewriter.js.map +1 -0
  403. package/dialog.d.ts +2 -3
  404. package/dialog.d.ts.map +1 -1
  405. package/dialog.js +5 -4
  406. package/dialog.js.map +1 -1
  407. package/divider.d.ts +2 -3
  408. package/divider.d.ts.map +1 -1
  409. package/divider.js +5 -4
  410. package/divider.js.map +1 -1
  411. package/dragbox.d.ts +2 -3
  412. package/dragbox.d.ts.map +1 -1
  413. package/dragbox.js +5 -4
  414. package/dragbox.js.map +1 -1
  415. package/flex.d.ts +8 -0
  416. package/flex.d.ts.map +1 -0
  417. package/flex.js +6 -0
  418. package/flex.js.map +1 -0
  419. package/form.d.ts +2 -3
  420. package/form.d.ts.map +1 -1
  421. package/form.js +5 -4
  422. package/form.js.map +1 -1
  423. package/grid.d.ts +8 -0
  424. package/grid.d.ts.map +1 -0
  425. package/grid.js +6 -0
  426. package/grid.js.map +1 -0
  427. package/index.d.ts +28 -32
  428. package/index.d.ts.map +1 -1
  429. package/index.js +57 -33
  430. package/index.js.map +1 -1
  431. package/input.d.ts +3 -3
  432. package/input.d.ts.map +1 -1
  433. package/input.js +5 -4
  434. package/input.js.map +1 -1
  435. package/layout.d.ts +3 -3
  436. package/layout.d.ts.map +1 -1
  437. package/layout.js +5 -4
  438. package/layout.js.map +1 -1
  439. package/link.d.ts +3 -3
  440. package/link.d.ts.map +1 -1
  441. package/link.js +5 -4
  442. package/link.js.map +1 -1
  443. package/package.json +42 -81
  444. package/progress.d.ts +3 -3
  445. package/progress.d.ts.map +1 -1
  446. package/progress.js +5 -4
  447. package/progress.js.map +1 -1
  448. package/range.d.ts +9 -0
  449. package/range.d.ts.map +1 -0
  450. package/range.js +6 -0
  451. package/range.js.map +1 -0
  452. package/rotate.d.ts +3 -3
  453. package/rotate.d.ts.map +1 -1
  454. package/rotate.js +5 -4
  455. package/rotate.js.map +1 -1
  456. package/router.d.ts +3 -3
  457. package/router.d.ts.map +1 -1
  458. package/router.js +5 -4
  459. package/router.js.map +1 -1
  460. package/select.d.ts +9 -0
  461. package/select.d.ts.map +1 -0
  462. package/select.js +6 -0
  463. package/select.js.map +1 -0
  464. package/skeleton.d.ts +3 -3
  465. package/skeleton.d.ts.map +1 -1
  466. package/skeleton.js +5 -4
  467. package/skeleton.js.map +1 -1
  468. package/split.d.ts +9 -0
  469. package/split.d.ts.map +1 -0
  470. package/split.js +6 -0
  471. package/split.js.map +1 -0
  472. package/switch.d.ts +9 -0
  473. package/switch.d.ts.map +1 -0
  474. package/switch.js +6 -0
  475. package/switch.js.map +1 -0
  476. package/text.d.ts +3 -3
  477. package/text.d.ts.map +1 -1
  478. package/text.js +5 -4
  479. package/text.js.map +1 -1
  480. package/time.d.ts +3 -3
  481. package/time.d.ts.map +1 -1
  482. package/time.js +5 -4
  483. package/time.js.map +1 -1
  484. package/tooltip.d.ts +3 -3
  485. package/tooltip.d.ts.map +1 -1
  486. package/tooltip.js +5 -4
  487. package/tooltip.js.map +1 -1
  488. package/typewriter.d.ts +2 -3
  489. package/typewriter.d.ts.map +1 -1
  490. package/typewriter.js +5 -4
  491. package/typewriter.js.map +1 -1
  492. package/vscode.css-custom-data.json +1 -0
  493. package/vscode.html-custom-data.json +1 -0
  494. package/web-types.json +1 -0
  495. package/_deps.d.ts +0 -4
  496. package/_deps.d.ts.map +0 -1
  497. package/_deps.js +0 -4
  498. package/_deps.js.map +0 -1
  499. package/avatar-group.d.ts +0 -9
  500. package/avatar-group.d.ts.map +0 -1
  501. package/avatar-group.js +0 -5
  502. package/avatar-group.js.map +0 -1
  503. package/components.json +0 -194
  504. package/conf.d.ts +0 -12
  505. package/conf.d.ts.map +0 -1
  506. package/conf.js +0 -24
  507. package/conf.js.map +0 -1
  508. package/decorators/godown.d.ts +0 -4
  509. package/decorators/godown.d.ts.map +0 -1
  510. package/decorators/godown.js +0 -9
  511. package/decorators/godown.js.map +0 -1
  512. package/decorators/part.d.ts +0 -7
  513. package/decorators/part.d.ts.map +0 -1
  514. package/decorators/part.js +0 -8
  515. package/decorators/part.js.map +0 -1
  516. package/decorators/styles.d.ts +0 -3
  517. package/decorators/styles.d.ts.map +0 -1
  518. package/decorators/styles.js +0 -8
  519. package/decorators/styles.js.map +0 -1
  520. package/flex-flow.d.ts +0 -9
  521. package/flex-flow.d.ts.map +0 -1
  522. package/flex-flow.js +0 -5
  523. package/flex-flow.js.map +0 -1
  524. package/grid-flow.d.ts +0 -9
  525. package/grid-flow.d.ts.map +0 -1
  526. package/grid-flow.js +0 -5
  527. package/grid-flow.js.map +0 -1
  528. package/label-input.d.ts +0 -9
  529. package/label-input.d.ts.map +0 -1
  530. package/label-input.js +0 -5
  531. package/label-input.js.map +0 -1
  532. package/lib/css.d.ts +0 -13
  533. package/lib/css.d.ts.map +0 -1
  534. package/lib/css.js +0 -29
  535. package/lib/css.js.map +0 -1
  536. package/lib/directives.d.ts +0 -25
  537. package/lib/directives.d.ts.map +0 -1
  538. package/lib/directives.js +0 -40
  539. package/lib/directives.js.map +0 -1
  540. package/lib/event-coll.d.ts +0 -13
  541. package/lib/event-coll.d.ts.map +0 -1
  542. package/lib/event-coll.js +0 -45
  543. package/lib/event-coll.js.map +0 -1
  544. package/lib/icons.d.ts +0 -25
  545. package/lib/icons.d.ts.map +0 -1
  546. package/lib/icons.js +0 -73
  547. package/lib/icons.js.map +0 -1
  548. package/lib/jsx.d.ts +0 -4
  549. package/lib/jsx.d.ts.map +0 -1
  550. package/lib/jsx.js +0 -52
  551. package/lib/jsx.js.map +0 -1
  552. package/lib/route-tree.d.ts +0 -28
  553. package/lib/route-tree.d.ts.map +0 -1
  554. package/lib/route-tree.js +0 -141
  555. package/lib/route-tree.js.map +0 -1
  556. package/lib/utils.d.ts +0 -10
  557. package/lib/utils.d.ts.map +0 -1
  558. package/lib/utils.js +0 -71
  559. package/lib/utils.js.map +0 -1
  560. package/overbreath.d.ts +0 -9
  561. package/overbreath.d.ts.map +0 -1
  562. package/overbreath.js +0 -5
  563. package/overbreath.js.map +0 -1
  564. package/proto/godown-config.d.ts +0 -41
  565. package/proto/godown-config.d.ts.map +0 -1
  566. package/proto/godown-config.js +0 -27
  567. package/proto/godown-config.js.map +0 -1
  568. package/proto/godown-element.d.ts +0 -125
  569. package/proto/godown-element.d.ts.map +0 -1
  570. package/proto/godown-element.js +0 -204
  571. package/proto/godown-element.js.map +0 -1
  572. package/proto/super-a.d.ts +0 -30
  573. package/proto/super-a.d.ts.map +0 -1
  574. package/proto/super-a.js +0 -141
  575. package/proto/super-a.js.map +0 -1
  576. package/proto/super-input.d.ts +0 -44
  577. package/proto/super-input.d.ts.map +0 -1
  578. package/proto/super-input.js +0 -119
  579. package/proto/super-input.js.map +0 -1
  580. package/proto/super-openable.d.ts.map +0 -1
  581. package/proto/super-openable.js.map +0 -1
  582. package/range-input.d.ts +0 -9
  583. package/range-input.d.ts.map +0 -1
  584. package/range-input.js +0 -5
  585. package/range-input.js.map +0 -1
  586. package/react/create.d.ts +0 -5
  587. package/react/create.d.ts.map +0 -1
  588. package/react/create.js +0 -16
  589. package/react/create.js.map +0 -1
  590. package/react/index.d.ts +0 -65
  591. package/react/index.d.ts.map +0 -1
  592. package/react/index.js +0 -132
  593. package/react/index.js.map +0 -1
  594. package/router-link.d.ts +0 -9
  595. package/router-link.d.ts.map +0 -1
  596. package/router-link.js +0 -5
  597. package/router-link.js.map +0 -1
  598. package/search-input.d.ts +0 -9
  599. package/search-input.d.ts.map +0 -1
  600. package/search-input.js +0 -5
  601. package/search-input.js.map +0 -1
  602. package/select-input.d.ts +0 -9
  603. package/select-input.d.ts.map +0 -1
  604. package/select-input.js +0 -5
  605. package/select-input.js.map +0 -1
  606. package/split-input.d.ts +0 -9
  607. package/split-input.d.ts.map +0 -1
  608. package/split-input.js +0 -5
  609. package/split-input.js.map +0 -1
  610. package/styles/colors/presets.d.ts +0 -13
  611. package/styles/colors/presets.d.ts.map +0 -1
  612. package/styles/colors/presets.js +0 -6
  613. package/styles/colors/presets.js.map +0 -1
  614. package/styles/colors/presetsRGB.d.ts +0 -16
  615. package/styles/colors/presetsRGB.d.ts.map +0 -1
  616. package/styles/colors/presetsRGB.js +0 -134
  617. package/styles/colors/presetsRGB.js.map +0 -1
  618. package/styles/global.d.ts +0 -18
  619. package/styles/global.d.ts.map +0 -1
  620. package/styles/global.js +0 -78
  621. package/styles/global.js.map +0 -1
  622. package/styles/inputStyle.d.ts +0 -3
  623. package/styles/inputStyle.d.ts.map +0 -1
  624. package/styles/inputStyle.js +0 -59
  625. package/styles/inputStyle.js.map +0 -1
  626. package/switch-input.d.ts +0 -9
  627. package/switch-input.d.ts.map +0 -1
  628. package/switch-input.js +0 -5
  629. package/switch-input.js.map +0 -1
  630. package/web-components/alert/alert.d.ts +0 -36
  631. package/web-components/alert/alert.d.ts.map +0 -1
  632. package/web-components/alert/alert.js +0 -161
  633. package/web-components/alert/alert.js.map +0 -1
  634. package/web-components/avatar/avatar-group.d.ts +0 -21
  635. package/web-components/avatar/avatar-group.d.ts.map +0 -1
  636. package/web-components/avatar/avatar-group.js +0 -86
  637. package/web-components/avatar/avatar-group.js.map +0 -1
  638. package/web-components/avatar/avatar.d.ts +0 -28
  639. package/web-components/avatar/avatar.d.ts.map +0 -1
  640. package/web-components/avatar/avatar.js +0 -120
  641. package/web-components/avatar/avatar.js.map +0 -1
  642. package/web-components/button/button.d.ts.map +0 -1
  643. package/web-components/button/button.js.map +0 -1
  644. package/web-components/card/card.d.ts +0 -9
  645. package/web-components/card/card.d.ts.map +0 -1
  646. package/web-components/card/card.js +0 -75
  647. package/web-components/card/card.js.map +0 -1
  648. package/web-components/carousel/carousel.d.ts +0 -29
  649. package/web-components/carousel/carousel.d.ts.map +0 -1
  650. package/web-components/carousel/carousel.js +0 -185
  651. package/web-components/carousel/carousel.js.map +0 -1
  652. package/web-components/details/details.d.ts.map +0 -1
  653. package/web-components/details/details.js +0 -124
  654. package/web-components/details/details.js.map +0 -1
  655. package/web-components/dialog/dialog.d.ts +0 -31
  656. package/web-components/dialog/dialog.d.ts.map +0 -1
  657. package/web-components/dialog/dialog.js +0 -143
  658. package/web-components/dialog/dialog.js.map +0 -1
  659. package/web-components/divider/divider.d.ts +0 -13
  660. package/web-components/divider/divider.d.ts.map +0 -1
  661. package/web-components/divider/divider.js +0 -95
  662. package/web-components/divider/divider.js.map +0 -1
  663. package/web-components/form/form.d.ts.map +0 -1
  664. package/web-components/form/form.js.map +0 -1
  665. package/web-components/input/input.d.ts +0 -37
  666. package/web-components/input/input.d.ts.map +0 -1
  667. package/web-components/input/input.js +0 -152
  668. package/web-components/input/input.js.map +0 -1
  669. package/web-components/input/label-input.d.ts +0 -15
  670. package/web-components/input/label-input.d.ts.map +0 -1
  671. package/web-components/input/label-input.js +0 -96
  672. package/web-components/input/label-input.js.map +0 -1
  673. package/web-components/input/range-input.d.ts +0 -53
  674. package/web-components/input/range-input.d.ts.map +0 -1
  675. package/web-components/input/range-input.js.map +0 -1
  676. package/web-components/input/search-input.d.ts +0 -42
  677. package/web-components/input/search-input.d.ts.map +0 -1
  678. package/web-components/input/search-input.js +0 -214
  679. package/web-components/input/search-input.js.map +0 -1
  680. package/web-components/input/select-input.d.ts +0 -36
  681. package/web-components/input/select-input.d.ts.map +0 -1
  682. package/web-components/input/select-input.js +0 -210
  683. package/web-components/input/select-input.js.map +0 -1
  684. package/web-components/input/split-input.d.ts +0 -29
  685. package/web-components/input/split-input.d.ts.map +0 -1
  686. package/web-components/input/split-input.js +0 -184
  687. package/web-components/input/split-input.js.map +0 -1
  688. package/web-components/input/switch-input.d.ts.map +0 -1
  689. package/web-components/input/switch-input.js.map +0 -1
  690. package/web-components/layout/flex-flow.d.ts +0 -17
  691. package/web-components/layout/flex-flow.d.ts.map +0 -1
  692. package/web-components/layout/flex-flow.js +0 -73
  693. package/web-components/layout/flex-flow.js.map +0 -1
  694. package/web-components/layout/grid-flow.d.ts +0 -14
  695. package/web-components/layout/grid-flow.d.ts.map +0 -1
  696. package/web-components/layout/grid-flow.js +0 -56
  697. package/web-components/layout/grid-flow.js.map +0 -1
  698. package/web-components/layout/layout.d.ts +0 -18
  699. package/web-components/layout/layout.d.ts.map +0 -1
  700. package/web-components/layout/layout.js +0 -76
  701. package/web-components/layout/layout.js.map +0 -1
  702. package/web-components/link/link.d.ts +0 -10
  703. package/web-components/link/link.d.ts.map +0 -1
  704. package/web-components/link/link.js +0 -17
  705. package/web-components/link/link.js.map +0 -1
  706. package/web-components/link/router-link.d.ts +0 -19
  707. package/web-components/link/router-link.d.ts.map +0 -1
  708. package/web-components/link/router-link.js +0 -60
  709. package/web-components/link/router-link.js.map +0 -1
  710. package/web-components/progress/progress.d.ts.map +0 -1
  711. package/web-components/progress/progress.js.map +0 -1
  712. package/web-components/router/router.d.ts +0 -86
  713. package/web-components/router/router.d.ts.map +0 -1
  714. package/web-components/router/router.js +0 -246
  715. package/web-components/router/router.js.map +0 -1
  716. package/web-components/skeleton/skeleton.d.ts.map +0 -1
  717. package/web-components/skeleton/skeleton.js +0 -130
  718. package/web-components/skeleton/skeleton.js.map +0 -1
  719. package/web-components/text/overbreath.d.ts +0 -22
  720. package/web-components/text/overbreath.d.ts.map +0 -1
  721. package/web-components/text/overbreath.js +0 -132
  722. package/web-components/text/overbreath.js.map +0 -1
  723. package/web-components/text/text.d.ts.map +0 -1
  724. package/web-components/text/text.js.map +0 -1
  725. package/web-components/text/time.d.ts.map +0 -1
  726. package/web-components/text/time.js.map +0 -1
  727. package/web-components/text/typewriter.d.ts.map +0 -1
  728. package/web-components/text/typewriter.js.map +0 -1
  729. package/web-components/tooltip/tooltip.d.ts +0 -30
  730. package/web-components/tooltip/tooltip.d.ts.map +0 -1
  731. package/web-components/tooltip/tooltip.js +0 -123
  732. package/web-components/tooltip/tooltip.js.map +0 -1
  733. package/web-components/wrapper/dragbox.d.ts.map +0 -1
  734. package/web-components/wrapper/dragbox.js.map +0 -1
  735. package/web-components/wrapper/rotate.d.ts.map +0 -1
  736. package/web-components/wrapper/rotate.js.map +0 -1
@@ -1 +0,0 @@
1
- {"version":3,"file":"icons.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["lib/icons.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,QAAQ,uCAMpB,CAAC;AAEF,eAAO,MAAM,cAAc,uCAS1B,CAAC;AAEF,eAAO,MAAM,QAAQ,UAAW,OAAO,oCAKtC,CAAC;AAEF,eAAO,MAAM,SAAS,uCAMrB,CAAC;AAEF,eAAO,MAAM,MAAM,uCAUlB,CAAC;AAEF,eAAO,MAAM,IAAI,uCAIhB,CAAC;AAEF,eAAO,MAAM,QAAQ,uCASpB,CAAC;AAEF,eAAO,MAAM,MAAM,uCAUlB,CAAC;AAEF,eAAO,MAAM,OAAO,UAAW,OAAO,oCAgBrC,CAAC;AAEF,eAAO,MAAM,OAAO,uCAMnB,CAAC;AAEF,eAAO,MAAM,KAAK;;;mBAlFc,OAAO;;;;;;kBAwDR,OAAO;;;;CAuCrC,CAAC"}
package/lib/icons.js DELETED
@@ -1,73 +0,0 @@
1
- import { html } from "lit";
2
- import { path } from "./directives.js";
3
- // SVG ICONS.
4
- export const svgDelta = () => {
5
- return html `<svg part="icon-delta" viewBox="0 0 1024 1024" fill="none">
6
- ${path()("M472.205 772.103l-441.229-440.485c-35.531-35.47-10.41-96.189 39.795-96.189h882.46c50.204 0 75.325 60.718 39.794 96.189l-441.231 440.485c-21.988 21.953-57.6 21.953-79.589 0z")}
7
- </svg>`;
8
- };
9
- export const svgDeltaSmooth = () => {
10
- return html `<svg part="icon-delta" viewBox="0 0 16 16" fill="currentColor">
11
- ${path(undefined, 0)("m3.86 8.753 5.482 4.796c.646.566 1.658.106 1.658-.753V3.204a1 1 0 0 0-1.659-.753l-5.48 4.796a1 1 0 0 0 0 1.506z")}
12
- </svg>`;
13
- };
14
- export const svgArrow = (body) => {
15
- const d = body ? "M24 12L36 24L24 36" : "M19 12L31 24L19 36";
16
- return html `<svg part="icon=arrow" viewBox="0 0 48 48" fill="none">
17
- ${body && path()("M36 24.0083H12")} ${path("none")(d)}
18
- </svg>`;
19
- };
20
- export const svgSearch = () => {
21
- return html `<svg part="icon-search" viewBox="0 0 1024 1024">
22
- ${path()("M950.6 899.8L726.2 675.4c-1.6-1.6-1.8-4.2-0.4-6 21.7-26.9 39.4-56.5 53-88.5 19.4-46 29.2-94.7 29.2-144.9s-9.8-98.9-29.2-144.8C760 246.9 733.2 207.1 699 173c-34.2-34.2-73.9-61-118.2-79.7C534.9 73.8 486.2 64 436 64s-98.9 9.8-144.8 29.2C246.9 112 207.1 138.8 173 173c-34.2 34.2-61 73.9-79.7 118.2C73.8 337.1 64 385.8 64 436s9.8 98.9 29.2 144.8C112 625.1 138.8 664.9 173 699c34.2 34.2 73.9 61 118.2 79.7C337.1 798.2 385.8 808 436 808s98.9-9.8 144.8-29.2c32-13.5 61.6-31.3 88.5-53 1.8-1.5 4.4-1.3 6 0.4l224.4 224.4c12.5 12.5 32.7 12.5 45.2 0l5.6-5.6c12.6-12.5 12.6-32.7 0.1-45.2zM436 736c-165.4 0-300-134.6-300-300S270.6 136 436 136 736 270.6 736 436 601.4 736 436 736z")}
23
- </svg>`;
24
- };
25
- export const svgEye = () => {
26
- return html `<svg part="icon-eye" viewBox="0 0 48 48">
27
- ${path(0)("M9.85786 18C6.23858 21 4 24 4 24C4 24 12.9543 36 24 36C25.3699 36 26.7076 35.8154 28 35.4921M20.0318 12.5C21.3144 12.1816 22.6414 12 24 12C35.0457 12 44 24 44 24C44 24 41.7614 27 38.1421 30")}
28
- ${path(0)("M20.3142 20.6211C19.4981 21.5109 19 22.6972 19 23.9998C19 26.7612 21.2386 28.9998 24 28.9998C25.3627 28.9998 26.5981 28.4546 27.5 27.5705")}
29
- ${path()("M42 42L6 6")}
30
- </svg>`;
31
- };
32
- export const svgX = () => {
33
- return html `<svg part="icon-x" viewBox="0 0 48 48" fill="none">
34
- ${path()("M12 12L36 36")} ${path()("M12 36L36 12")}
35
- </svg>`;
36
- };
37
- export const svgImage = () => {
38
- return html `<svg part="icon-image" viewBox="0 0 1098 1024">
39
- ${path(undefined, 0)("M365.714286 329.142857q0 45.714286-32.036571 77.677714t-77.677714 32.036571-77.677714-32.036571-32.036571-77.677714 32.036571-77.677714 77.677714-32.036571 77.677714 32.036571 32.036571 77.677714zM950.857143 548.571429l0 256-804.571429 0 0-109.714286 182.857143-182.857143 91.428571 91.428571 292.571429-292.571429zM1005.714286 146.285714l-914.285714 0q-7.460571 0-12.873143 5.412571t-5.412571 12.873143l0 694.857143q0 7.460571 5.412571 12.873143t12.873143 5.412571l914.285714 0q7.460571 0 12.873143-5.412571t5.412571-12.873143l0-694.857143q0-7.460571-5.412571-12.873143t-12.873143-5.412571zM1097.142857 164.571429l0 694.857143q0 37.741714-26.843429 64.585143t-64.585143 26.843429l-914.285714 0q-37.741714 0-64.585143-26.843429t-26.843429-64.585143l0-694.857143q0-37.741714 26.843429-64.585143t64.585143-26.843429l914.285714 0q37.741714 0 64.585143 26.843429t26.843429 64.585143z")}
40
- </svg>`;
41
- };
42
- export const svgSun = () => {
43
- return html `<svg part="icon-sun" viewBox="0 0 16 16">
44
- ${path(undefined, 0, 1)("M8 11a3 3 0 1 1 0-6 3 3 0 0 1 0 6zm0 1a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM8 0a.5.5 0 0 1 .5.5v2a.5.5 0 0 1-1 0v-2A.5.5 0 0 1 8 0zm0 13a.5.5 0 0 1 .5.5v2a.5.5 0 0 1-1 0v-2A.5.5 0 0 1 8 13zm8-5a.5.5 0 0 1-.5.5h-2a.5.5 0 0 1 0-1h2a.5.5 0 0 1 .5.5zM3 8a.5.5 0 0 1-.5.5h-2a.5.5 0 0 1 0-1h2A.5.5 0 0 1 3 8zm10.657-5.657a.5.5 0 0 1 0 .707l-1.414 1.415a.5.5 0 1 1-.707-.708l1.414-1.414a.5.5 0 0 1 .707 0zm-9.193 9.193a.5.5 0 0 1 0 .707L3.05 13.657a.5.5 0 0 1-.707-.707l1.414-1.414a.5.5 0 0 1 .707 0zm9.193 2.121a.5.5 0 0 1-.707 0l-1.414-1.414a.5.5 0 0 1 .707-.707l1.414 1.414a.5.5 0 0 1 0 .707zM4.464 4.465a.5.5 0 0 1-.707 0L2.343 3.05a.5.5 0 1 1 .707-.707l1.414 1.414a.5.5 0 0 1 0 .708z")}
45
- </svg>`;
46
- };
47
- export const svgMoon = (star) => {
48
- return html `<svg part="icon-moon" viewBox="0 0 16 16">
49
- ${path(undefined, 0)("M6 .278a.768.768 0 0 1 .08.858 7.208 7.208 0 0 0-.878 3.46c0 4.021 3.278 7.277 7.318 7.277.527 0 1.04-.055 1.533-.16a.787.787 0 0 1 .81.316.733.733 0 0 1-.031.893A8.349 8.349 0 0 1 8.344 16C3.734 16 0 12.286 0 7.71 0 4.266 2.114 1.312 5.124.06A.752.752 0 0 1 6 .278zM4.858 1.311A7.269 7.269 0 0 0 1.025 7.71c0 4.02 3.279 7.276 7.319 7.276a7.316 7.316 0 0 0 5.205-2.162c-.337.042-.68.063-1.029.063-4.61 0-8.343-3.714-8.343-8.29 0-1.167.242-2.278.681-3.286z")}
50
- ${star &&
51
- path(undefined, 0)("M10.794 3.148a.217.217 0 0 1 .412 0l.387 1.162c.173.518.579.924 1.097 1.097l1.162.387a.217.217 0 0 1 0 .412l-1.162.387a1.734 1.734 0 0 0-1.097 1.097l-.387 1.162a.217.217 0 0 1-.412 0l-.387-1.162A1.734 1.734 0 0 0 9.31 6.593l-1.162-.387a.217.217 0 0 1 0-.412l1.162-.387a1.734 1.734 0 0 0 1.097-1.097l.387-1.162zM13.863.099a.145.145 0 0 1 .274 0l.258.774c.115.346.386.617.732.732l.774.258a.145.145 0 0 1 0 .274l-.774.258a1.156 1.156 0 0 0-.732.732l-.258.774a.145.145 0 0 1-.274 0l-.258-.774a1.156 1.156 0 0 0-.732-.732l-.774-.258a.145.145 0 0 1 0-.274l.774-.258c.346-.115.617-.386.732-.732L13.863.1z")}
52
- </svg>`;
53
- };
54
- export const svgLink = () => {
55
- return html `<svg part="icon-link" viewBox="0 0 48 48" fill="none">
56
- ${path(0)("M28 6H42V20")}${path(0)("M42 29.4737V39C42 40.6569 40.6569 42 39 42H9C7.34315 42 6 40.6569 6 39V9C6 7.34315 7.34315 6 9 6L18 6")}${path()("M25.7998 22.1999L41.0998 6.8999")}
57
- </svg>`;
58
- };
59
- export const icons = {
60
- delta: svgDelta,
61
- "delta-smooth": svgDeltaSmooth,
62
- arrow: svgArrow,
63
- "arrow-body": () => svgArrow(true),
64
- search: svgSearch,
65
- eye: svgEye,
66
- x: svgX,
67
- image: svgImage,
68
- moon: svgMoon,
69
- "moon-star": () => svgMoon(true),
70
- sun: svgSun,
71
- link: svgLink,
72
- };
73
- //# sourceMappingURL=icons.js.map
package/lib/icons.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"icons.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["lib/icons.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAE3B,OAAO,EAAE,IAAI,EAAE,MAAM,iBAAiB,CAAC;AAEvC,aAAa;AAEb,MAAM,CAAC,MAAM,QAAQ,GAAG,GAAG,EAAE;IAC3B,OAAO,IAAI,CAAA;MACP,IAAI,EAAE,CACN,8K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AAM,MAAM,GAAG,GAAG,EAAE;IACzB,OAAO,IAAI,CAAA;MACP,IAAI,CACJ,SAAS,EACT,CAAC,EACD,CAAC,CACF,CACC,mqBAAmqB,CACpqB;SACI,CAAC;AACV,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,OAAO,GAAG,CAAC,IAAc,EAAE,EAAE;IACxC,OAAO,IAAI,CAAA;MACP,IAAI,CACJ,SAAS,EACT,CAAC,CACF,CACC,ycAAyc,CAC1c;MACC,IAAI;QACN,IAAI,CACF,SAAS,EACT,CAAC,CACF,CACC,ulBAAulB,CACxlB;SACI,CAAC;AACV,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,OAAO,GAAG,GAAG,EAAE;IAC1B,OAAO,IAAI,CAAA;MACP,IAAI,CAAC,CAAC,CAAC,CAAC,aAAa,CAAC,GAAG,IAAI,CAAC,CAAC,CAAC,CAChC,uGAAuG,CACxG,GAAG,IAAI,EAAE,CAAC,iCAAiC,CAAC;SACxC,CAAC;AACV,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,KAAK,GAAG;IACnB,KAAK,EAAE,QAAQ;IACf,cAAc,EAAE,cAAc;IAC9B,KAAK,EAAE,QAAQ;IACf,YAAY,EAAE,GAAG,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC;IAClC,MAAM,EAAE,SAAS;IACjB,GAAG,EAAE,MAAM;IACX,CAAC,EAAE,IAAI;IACP,KAAK,EAAE,QAAQ;IACf,IAAI,EAAE,OAAO;IACb,WAAW,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC;IAChC,GAAG,EAAE,MAAM;IACX,IAAI,EAAE,OAAO;CACd,CAAC","sourcesContent":["import { html } from \"lit\";\n\nimport { path } from \"./directives.js\";\n\n// SVG ICONS.\n\nexport const svgDelta = () => {\n return html`<svg part=\"icon-delta\" viewBox=\"0 0 1024 1024\" fill=\"none\">\n ${path()(\n \"M472.205 772.103l-441.229-440.485c-35.531-35.47-10.41-96.189 39.795-96.189h882.46c50.204 0 75.325 60.718 39.794 96.189l-441.231 440.485c-21.988 21.953-57.6 21.953-79.589 0z\",\n )}\n </svg>`;\n};\n\nexport const svgDeltaSmooth = () => {\n return html`<svg part=\"icon-delta\" viewBox=\"0 0 16 16\" fill=\"currentColor\">\n ${path(\n undefined,\n 0,\n )(\n \"m3.86 8.753 5.482 4.796c.646.566 1.658.106 1.658-.753V3.204a1 1 0 0 0-1.659-.753l-5.48 4.796a1 1 0 0 0 0 1.506z\",\n )}\n </svg>`;\n};\n\nexport const svgArrow = (body?: boolean) => {\n const d = body ? \"M24 12L36 24L24 36\" : \"M19 12L31 24L19 36\";\n return html`<svg part=\"icon=arrow\" viewBox=\"0 0 48 48\" fill=\"none\">\n ${body && path()(\"M36 24.0083H12\")} ${path(\"none\")(d)}\n </svg>`;\n};\n\nexport const svgSearch = () => {\n return html`<svg part=\"icon-search\" viewBox=\"0 0 1024 1024\">\n ${path()(\n \"M950.6 899.8L726.2 675.4c-1.6-1.6-1.8-4.2-0.4-6 21.7-26.9 39.4-56.5 53-88.5 19.4-46 29.2-94.7 29.2-144.9s-9.8-98.9-29.2-144.8C760 246.9 733.2 207.1 699 173c-34.2-34.2-73.9-61-118.2-79.7C534.9 73.8 486.2 64 436 64s-98.9 9.8-144.8 29.2C246.9 112 207.1 138.8 173 173c-34.2 34.2-61 73.9-79.7 118.2C73.8 337.1 64 385.8 64 436s9.8 98.9 29.2 144.8C112 625.1 138.8 664.9 173 699c34.2 34.2 73.9 61 118.2 79.7C337.1 798.2 385.8 808 436 808s98.9-9.8 144.8-29.2c32-13.5 61.6-31.3 88.5-53 1.8-1.5 4.4-1.3 6 0.4l224.4 224.4c12.5 12.5 32.7 12.5 45.2 0l5.6-5.6c12.6-12.5 12.6-32.7 0.1-45.2zM436 736c-165.4 0-300-134.6-300-300S270.6 136 436 136 736 270.6 736 436 601.4 736 436 736z\",\n )}\n </svg>`;\n};\n\nexport const svgEye = () => {\n return html`<svg part=\"icon-eye\" viewBox=\"0 0 48 48\">\n ${path(0)(\n \"M9.85786 18C6.23858 21 4 24 4 24C4 24 12.9543 36 24 36C25.3699 36 26.7076 35.8154 28 35.4921M20.0318 12.5C21.3144 12.1816 22.6414 12 24 12C35.0457 12 44 24 44 24C44 24 41.7614 27 38.1421 30\",\n )}\n ${path(0)(\n \"M20.3142 20.6211C19.4981 21.5109 19 22.6972 19 23.9998C19 26.7612 21.2386 28.9998 24 28.9998C25.3627 28.9998 26.5981 28.4546 27.5 27.5705\",\n )}\n ${path()(\"M42 42L6 6\")}\n </svg>`;\n};\n\nexport const svgX = () => {\n return html`<svg part=\"icon-x\" viewBox=\"0 0 48 48\" fill=\"none\">\n ${path()(\"M12 12L36 36\")} ${path()(\"M12 36L36 12\")}\n </svg>`;\n};\n\nexport const svgImage = () => {\n return html`<svg part=\"icon-image\" viewBox=\"0 0 1098 1024\">\n ${path(\n undefined,\n 0,\n )(\n \"M365.714286 329.142857q0 45.714286-32.036571 77.677714t-77.677714 32.036571-77.677714-32.036571-32.036571-77.677714 32.036571-77.677714 77.677714-32.036571 77.677714 32.036571 32.036571 77.677714zM950.857143 548.571429l0 256-804.571429 0 0-109.714286 182.857143-182.857143 91.428571 91.428571 292.571429-292.571429zM1005.714286 146.285714l-914.285714 0q-7.460571 0-12.873143 5.412571t-5.412571 12.873143l0 694.857143q0 7.460571 5.412571 12.873143t12.873143 5.412571l914.285714 0q7.460571 0 12.873143-5.412571t5.412571-12.873143l0-694.857143q0-7.460571-5.412571-12.873143t-12.873143-5.412571zM1097.142857 164.571429l0 694.857143q0 37.741714-26.843429 64.585143t-64.585143 26.843429l-914.285714 0q-37.741714 0-64.585143-26.843429t-26.843429-64.585143l0-694.857143q0-37.741714 26.843429-64.585143t64.585143-26.843429l914.285714 0q37.741714 0 64.585143 26.843429t26.843429 64.585143z\",\n )}\n </svg>`;\n};\n\nexport const svgSun = () => {\n return html`<svg part=\"icon-sun\" viewBox=\"0 0 16 16\">\n ${path(\n undefined,\n 0,\n 1,\n )(\n \"M8 11a3 3 0 1 1 0-6 3 3 0 0 1 0 6zm0 1a4 4 0 1 0 0-8 4 4 0 0 0 0 8zM8 0a.5.5 0 0 1 .5.5v2a.5.5 0 0 1-1 0v-2A.5.5 0 0 1 8 0zm0 13a.5.5 0 0 1 .5.5v2a.5.5 0 0 1-1 0v-2A.5.5 0 0 1 8 13zm8-5a.5.5 0 0 1-.5.5h-2a.5.5 0 0 1 0-1h2a.5.5 0 0 1 .5.5zM3 8a.5.5 0 0 1-.5.5h-2a.5.5 0 0 1 0-1h2A.5.5 0 0 1 3 8zm10.657-5.657a.5.5 0 0 1 0 .707l-1.414 1.415a.5.5 0 1 1-.707-.708l1.414-1.414a.5.5 0 0 1 .707 0zm-9.193 9.193a.5.5 0 0 1 0 .707L3.05 13.657a.5.5 0 0 1-.707-.707l1.414-1.414a.5.5 0 0 1 .707 0zm9.193 2.121a.5.5 0 0 1-.707 0l-1.414-1.414a.5.5 0 0 1 .707-.707l1.414 1.414a.5.5 0 0 1 0 .707zM4.464 4.465a.5.5 0 0 1-.707 0L2.343 3.05a.5.5 0 1 1 .707-.707l1.414 1.414a.5.5 0 0 1 0 .708z\",\n )}\n </svg>`;\n};\n\nexport const svgMoon = (star?: boolean) => {\n return html`<svg part=\"icon-moon\" viewBox=\"0 0 16 16\">\n ${path(\n undefined,\n 0,\n )(\n \"M6 .278a.768.768 0 0 1 .08.858 7.208 7.208 0 0 0-.878 3.46c0 4.021 3.278 7.277 7.318 7.277.527 0 1.04-.055 1.533-.16a.787.787 0 0 1 .81.316.733.733 0 0 1-.031.893A8.349 8.349 0 0 1 8.344 16C3.734 16 0 12.286 0 7.71 0 4.266 2.114 1.312 5.124.06A.752.752 0 0 1 6 .278zM4.858 1.311A7.269 7.269 0 0 0 1.025 7.71c0 4.02 3.279 7.276 7.319 7.276a7.316 7.316 0 0 0 5.205-2.162c-.337.042-.68.063-1.029.063-4.61 0-8.343-3.714-8.343-8.29 0-1.167.242-2.278.681-3.286z\",\n )}\n ${star &&\n path(\n undefined,\n 0,\n )(\n \"M10.794 3.148a.217.217 0 0 1 .412 0l.387 1.162c.173.518.579.924 1.097 1.097l1.162.387a.217.217 0 0 1 0 .412l-1.162.387a1.734 1.734 0 0 0-1.097 1.097l-.387 1.162a.217.217 0 0 1-.412 0l-.387-1.162A1.734 1.734 0 0 0 9.31 6.593l-1.162-.387a.217.217 0 0 1 0-.412l1.162-.387a1.734 1.734 0 0 0 1.097-1.097l.387-1.162zM13.863.099a.145.145 0 0 1 .274 0l.258.774c.115.346.386.617.732.732l.774.258a.145.145 0 0 1 0 .274l-.774.258a1.156 1.156 0 0 0-.732.732l-.258.774a.145.145 0 0 1-.274 0l-.258-.774a1.156 1.156 0 0 0-.732-.732l-.774-.258a.145.145 0 0 1 0-.274l.774-.258c.346-.115.617-.386.732-.732L13.863.1z\",\n )}\n </svg>`;\n};\n\nexport const svgLink = () => {\n return html`<svg part=\"icon-link\" viewBox=\"0 0 48 48\" fill=\"none\">\n ${path(0)(\"M28 6H42V20\")}${path(0)(\n \"M42 29.4737V39C42 40.6569 40.6569 42 39 42H9C7.34315 42 6 40.6569 6 39V9C6 7.34315 7.34315 6 9 6L18 6\",\n )}${path()(\"M25.7998 22.1999L41.0998 6.8999\")}\n </svg>`;\n};\n\nexport const icons = {\n delta: svgDelta,\n \"delta-smooth\": svgDeltaSmooth,\n arrow: svgArrow,\n \"arrow-body\": () => svgArrow(true),\n search: svgSearch,\n eye: svgEye,\n x: svgX,\n image: svgImage,\n moon: svgMoon,\n \"moon-star\": () => svgMoon(true),\n sun: svgSun,\n link: svgLink,\n};\n"]}
package/lib/jsx.d.ts DELETED
@@ -1,4 +0,0 @@
1
- export declare function factory(tag: string | typeof fragment, props?: null | Record<string, any>, ...children: any[]): HTMLElement;
2
- export declare function factory<T extends typeof HTMLElement>(tag: string | T, props?: null | (Partial<Record<keyof T, T[keyof T]>> & Record<string, any>), ...children: any[]): InstanceType<T>;
3
- export declare function fragment(_: any, ...children: any[]): any[];
4
- //# sourceMappingURL=jsx.d.ts.map
package/lib/jsx.d.ts.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"jsx.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["lib/jsx.ts"],"names":[],"mappings":"AAAA,wBAAgB,OAAO,CACrB,GAAG,EAAE,MAAM,GAAG,OAAO,QAAQ,EAC7B,KAAK,CAAC,EAAE,IAAI,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAClC,GAAG,QAAQ,EAAE,GAAG,EAAE,GACjB,WAAW,CAAC;AAEf,wBAAgB,OAAO,CAAC,CAAC,SAAS,OAAO,WAAW,EAClD,GAAG,EAAE,MAAM,GAAG,CAAC,EACf,KAAK,CAAC,EAAE,IAAI,GAAG,CAAC,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC,EAC3E,GAAG,QAAQ,EAAE,GAAG,EAAE,GACjB,YAAY,CAAC,CAAC,CAAC,CAAC;AA0CnB,wBAAgB,QAAQ,CAAC,CAAC,EAAE,GAAG,EAAE,GAAG,QAAQ,EAAE,GAAG,EAAE,SAElD"}
package/lib/jsx.js DELETED
@@ -1,52 +0,0 @@
1
- export function factory(tag, props, ...children) {
2
- let element;
3
- if (typeof tag === "string") {
4
- element = document.createElement(tag);
5
- }
6
- else if (tag.prototype instanceof HTMLElement) {
7
- element = new tag();
8
- }
9
- else if (typeof tag === "function") {
10
- return tag(props, children);
11
- }
12
- if (props) {
13
- Object.entries(props).forEach(([key, value]) => {
14
- if (key === "style") {
15
- Object.assign(element.style, value);
16
- }
17
- else if (key === "class") {
18
- element.className = value;
19
- }
20
- else if (key.startsWith("on") && key.length > 2) {
21
- const type = key.slice(2);
22
- if (type) {
23
- element.addEventListener(type.toLowerCase(), value);
24
- }
25
- }
26
- else {
27
- if (key.startsWith("data-") || Object.prototype.hasOwnProperty.call(element, key)) {
28
- element.setAttribute(key, value);
29
- }
30
- else {
31
- element[key] = value;
32
- }
33
- }
34
- });
35
- }
36
- children.forEach((child) => {
37
- append(element, child);
38
- });
39
- return element;
40
- }
41
- export function fragment(_, ...children) {
42
- return children;
43
- }
44
- function append(parent, child) {
45
- if (Array.isArray(child)) {
46
- child.forEach((nestedChild) => append(parent, nestedChild));
47
- }
48
- else {
49
- parent.appendChild(typeof child === "string" ? document.createTextNode(child) : child);
50
- }
51
- }
52
- //# sourceMappingURL=jsx.js.map
package/lib/jsx.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"jsx.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["lib/jsx.ts"],"names":[],"mappings":"AAYA,MAAM,UAAU,OAAO,CACrB,GAAiC,EACjC,KAAiG,EACjG,GAAG,QAAe;IAElB,IAAI,OAAoB,CAAC;IACzB,IAAI,OAAO,GAAG,KAAK,QAAQ,EAAE,CAAC;QAC5B,OAAO,GAAG,QAAQ,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC;IACxC,CAAC;SAAM,IAAI,GAAG,CAAC,SAAS,YAAY,WAAW,EAAE,CAAC;QAChD,OAAO,GAAG,IAAK,GAAS,EAAE,CAAC;IAC7B,CAAC;SAAM,IAAI,OAAO,GAAG,KAAK,UAAU,EAAE,CAAC;QACrC,OAAQ,GAAuB,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC;IACnD,CAAC;IACD,IAAI,KAAK,EAAE,CAAC;QACV,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,GAAG,EAAE,KAAK,CAAC,EAAE,EAAE;YAC7C,IAAI,GAAG,KAAK,OAAO,EAAE,CAAC;gBACpB,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;YACtC,CAAC;iBAAM,IAAI,GAAG,KAAK,OAAO,EAAE,CAAC;gBAC3B,OAA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AAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC;IACzF,CAAC;AACH,CAAC","sourcesContent":["export function factory(\n tag: string | typeof fragment,\n props?: null | Record<string, any>,\n ...children: any[]\n): HTMLElement;\n\nexport function factory<T extends typeof HTMLElement>(\n tag: string | T,\n props?: null | (Partial<Record<keyof T, T[keyof T]>> & Record<string, any>),\n ...children: any[]\n): InstanceType<T>;\n\nexport function factory<T extends typeof HTMLElement>(\n tag: string | typeof fragment | T,\n props?: null | Record<string, any> | (Partial<Record<keyof T, T[keyof T]>> & Record<string, any>),\n ...children: any[]\n) {\n let element: HTMLElement;\n if (typeof tag === \"string\") {\n element = document.createElement(tag);\n } else if (tag.prototype instanceof HTMLElement) {\n element = new (tag as T)();\n } else if (typeof tag === \"function\") {\n return (tag as typeof fragment)(props, children);\n }\n if (props) {\n Object.entries(props).forEach(([key, value]) => {\n if (key === \"style\") {\n Object.assign(element.style, value);\n } else if (key === \"class\") {\n element.className = value;\n } else if (key.startsWith(\"on\") && key.length > 2) {\n const type = key.slice(2);\n if (type) {\n element.addEventListener(type.toLowerCase(), value);\n }\n } else {\n if (key.startsWith(\"data-\") || Object.prototype.hasOwnProperty.call(element, key)) {\n element.setAttribute(key, value);\n } else {\n element[key] = value;\n }\n }\n });\n }\n children.forEach((child) => {\n append(element, child);\n });\n\n return element;\n}\n\nexport function fragment(_: any, ...children: any[]) {\n return children;\n}\n\nfunction append(parent: HTMLElement, child: Node | string) {\n if (Array.isArray(child)) {\n child.forEach((nestedChild) => append(parent, nestedChild));\n } else {\n parent.appendChild(typeof child === \"string\" ? document.createTextNode(child) : child);\n }\n}\n"]}
@@ -1,28 +0,0 @@
1
- export declare class RouteTree {
2
- pattern: string;
3
- part: string;
4
- children: RouteTree[];
5
- isWild: boolean;
6
- insert(pattern: string, parts?: string[] | undefined, height?: number): void;
7
- search(parts: string[], height?: number): RouteTree | null;
8
- matchChild(part: string): RouteTree | null;
9
- matchChildren(part: string): RouteTree[];
10
- static split(s: string): string[];
11
- /**
12
- *
13
- * @param s Pattern, may contains dynamic matching parameters.
14
- * @returns {object} key, carry, multi.
15
- * @property {string} key - Dynamic key.
16
- * @property {number} carry - The length of the modifier symbol for the dynamic prefix.
17
- * @property {boolean} multi - Ignore after.
18
- */
19
- static dynamic(s: string): {
20
- key: string;
21
- carry: number;
22
- multi: boolean;
23
- };
24
- useWhich(s: string): string | null;
25
- parseParams(s: string, pattern: string): Record<string, string>;
26
- }
27
- export default RouteTree;
28
- //# sourceMappingURL=route-tree.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"route-tree.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["lib/route-tree.ts"],"names":[],"mappings":"AAAA,qBAAa,SAAS;IACpB,OAAO,SAAM;IACb,IAAI,SAAM;IACV,QAAQ,EAAE,SAAS,EAAE,CAAM;IAC3B,MAAM,UAAS;IAEf,MAAM,CAAC,OAAO,EAAE,MAAM,EAAE,KAAK,GAAE,MAAM,EAAE,GAAG,SAAqB,EAAE,MAAM,SAAI,GAAG,IAAI;IAoBlF,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,EAAE,MAAM,SAAI,GAAG,SAAS,GAAG,IAAI;IAkBrD,UAAU,CAAC,IAAI,EAAE,MAAM,GAAG,SAAS,GAAG,IAAI;IAS1C,aAAa,CAAC,IAAI,EAAE,MAAM,GAAG,SAAS,EAAE;IAUxC,MAAM,CAAC,KAAK,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE;IAIjC;;;;;;;OAOG;IACH,MAAM,CAAC,OAAO,CAAC,CAAC,EAAE,MAAM,GAAG;QACzB,GAAG,EAAE,MAAM,CAAC;QACZ,KAAK,EAAE,MAAM,CAAC;QACd,KAAK,EAAE,OAAO,CAAC;KAChB;IA4CD,QAAQ,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI;IASlC,WAAW,CAAC,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;CAgBhE;AACD,eAAe,SAAS,CAAC"}
package/lib/route-tree.js DELETED
@@ -1,141 +0,0 @@
1
- export class RouteTree {
2
- constructor() {
3
- this.pattern = "";
4
- this.part = "";
5
- this.children = [];
6
- this.isWild = false;
7
- }
8
- insert(pattern, parts = undefined, height = 0) {
9
- if (!parts) {
10
- parts = RouteTree.split(pattern);
11
- }
12
- if (parts.length === height) {
13
- this.pattern = pattern;
14
- return;
15
- }
16
- const part = parts[height];
17
- let child = this.matchChild(part);
18
- if (child === null) {
19
- child = new RouteTree();
20
- child.part = part;
21
- const { carry } = RouteTree.dynamic(part);
22
- child.isWild = Boolean(carry);
23
- this.children.push(child);
24
- }
25
- child.insert(pattern, parts, height + 1);
26
- }
27
- search(parts, height = 0) {
28
- if (parts.length === height || this.part.startsWith("*")) {
29
- if (this.pattern === "") {
30
- return null;
31
- }
32
- return this;
33
- }
34
- const part = parts[height];
35
- const children = this.matchChildren(part);
36
- for (const child of children) {
37
- const result = child.search(parts, height + 1);
38
- if (result !== null) {
39
- return result;
40
- }
41
- }
42
- return null;
43
- }
44
- matchChild(part) {
45
- for (const child of this.children) {
46
- if (child.part === part || child.isWild) {
47
- return child;
48
- }
49
- }
50
- return null;
51
- }
52
- matchChildren(part) {
53
- const nodes = [];
54
- for (const child of this.children) {
55
- if (child.part === part || child.isWild) {
56
- nodes.push(child);
57
- }
58
- }
59
- return nodes;
60
- }
61
- static split(s) {
62
- return s.split("/").filter((a) => a);
63
- }
64
- /**
65
- *
66
- * @param s Pattern, may contains dynamic matching parameters.
67
- * @returns {object} key, carry, multi.
68
- * @property {string} key - Dynamic key.
69
- * @property {number} carry - The length of the modifier symbol for the dynamic prefix.
70
- * @property {boolean} multi - Ignore after.
71
- */
72
- static dynamic(s) {
73
- if (s[0] === "{" && s[s.length - 1] === "}") {
74
- s = s.substring(1, s.length - 1);
75
- if (s[0] !== ":" && s[0] !== "*" && s[0] !== ".") {
76
- return {
77
- key: s,
78
- carry: 0,
79
- multi: false,
80
- };
81
- }
82
- }
83
- if (s[0] === "[" && s[s.length - 1] === "]") {
84
- s = s.substring(1, s.length - 1);
85
- }
86
- const s1 = s.substring(0, 1);
87
- if (s1 === ":") {
88
- return {
89
- key: s,
90
- carry: 1,
91
- multi: false,
92
- };
93
- }
94
- if (s1 === "*") {
95
- return {
96
- key: s,
97
- carry: 1,
98
- multi: true,
99
- };
100
- }
101
- const s3 = s.substring(0, 3);
102
- if (s3 === "...") {
103
- return {
104
- key: s,
105
- carry: 3,
106
- multi: true,
107
- };
108
- }
109
- return {
110
- key: "",
111
- carry: 0,
112
- multi: false,
113
- };
114
- }
115
- useWhich(s) {
116
- const sp = RouteTree.split(s);
117
- const t = this.search(sp);
118
- if (t) {
119
- return t.pattern;
120
- }
121
- return null;
122
- }
123
- parseParams(s, pattern) {
124
- const sSplit = RouteTree.split(s);
125
- const patternSplit = RouteTree.split(pattern);
126
- const params = {};
127
- for (const index in patternSplit) {
128
- const { key, carry, multi } = RouteTree.dynamic(patternSplit[index]);
129
- if (!key) {
130
- continue;
131
- }
132
- params[key.substring(carry)] = sSplit[index];
133
- if (multi) {
134
- break;
135
- }
136
- }
137
- return params;
138
- }
139
- }
140
- export default RouteTree;
141
- //# sourceMappingURL=route-tree.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"route-tree.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["lib/route-tree.ts"],"names":[],"mappings":"AAAA,MAAM,OAAO,SAAS;IAAtB;QACE,YAAO,GAAG,EAAE,CAAC;QACb,SAAI,GAAG,EAAE,CAAC;QACV,aAAQ,GAAgB,EAAE,CAAC;QAC3B,WAAM,GAAG,KAAK,CAAC;IAgJjB,CAAC;IA9IC,MAAM,CAAC,OAAe,EAAE,QAA8B,SAAS,EAAE,MAAM,GAAG,CAAC;QACzE,IAAI,CAAC,KAAK,EAAE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AAC,CAAC;QAC9B,MAAM,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC;QAC1B,IAAI,CAAC,EAAE,CAAC;YACN,OAAO,CAAC,CAAC,OAAO,CAAC;QACnB,CAAC;QACD,OAAO,IAAI,CAAC;IACd,CAAC;IAED,WAAW,CAAC,CAAS,EAAE,OAAe;QACpC,MAAM,MAAM,GAAG,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;QAClC,MAAM,YAAY,GAAG,SAAS,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QAC9C,MAAM,MAAM,GAA2B,EAAE,CAAC;QAC1C,KAAK,MAAM,KAAK,IAAI,YAAY,EAAE,CAAC;YACjC,MAAM,EAAE,GAAG,EAAE,KAAK,EAAE,KAAK,EAAE,GAAG,SAAS,CAAC,OAAO,CAAC,YAAY,CAAC,KAAK,CAAC,CAAC,CAAC;YACrE,IAAI,CAAC,GAAG,EAAE,CAAC;gBACT,SAAS;YACX,CAAC;YACD,MAAM,CAAC,GAAG,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,GAAG,MAAM,CAAC,KAAK,CAAC,CAAC;YAC7C,IAAI,KAAK,EAAE,CAAC;gBACV,MAAM;YACR,CAAC;QACH,CAAC;QACD,OAAO,MAAM,CAAC;IAChB,CAAC;CACF;AACD,eAAe,SAAS,CAAC","sourcesContent":["export class RouteTree {\n pattern = \"\";\n part = \"\";\n children: RouteTree[] = [];\n isWild = false;\n\n insert(pattern: string, parts: string[] | undefined = undefined, height = 0): void {\n if (!parts) {\n parts = RouteTree.split(pattern);\n }\n if (parts.length === height) {\n this.pattern = pattern;\n return;\n }\n const part = parts[height];\n let child = this.matchChild(part);\n if (child === null) {\n child = new RouteTree();\n child.part = part;\n const { carry } = RouteTree.dynamic(part);\n child.isWild = Boolean(carry);\n this.children.push(child);\n }\n child.insert(pattern, parts, height + 1);\n }\n\n search(parts: string[], height = 0): RouteTree | null {\n if (parts.length === height || this.part.startsWith(\"*\")) {\n if (this.pattern === \"\") {\n return null;\n }\n return this;\n }\n const part = parts[height];\n const children = this.matchChildren(part);\n for (const child of children) {\n const result = child.search(parts, height + 1);\n if (result !== null) {\n return result;\n }\n }\n return null;\n }\n\n matchChild(part: string): RouteTree | null {\n for (const child of this.children) {\n if (child.part === part || child.isWild) {\n return child;\n }\n }\n return null;\n }\n\n matchChildren(part: string): RouteTree[] {\n const nodes: RouteTree[] = [];\n for (const child of this.children) {\n if (child.part === part || child.isWild) {\n nodes.push(child);\n }\n }\n return nodes;\n }\n\n static split(s: string): string[] {\n return s.split(\"/\").filter((a) => a);\n }\n\n /**\n *\n * @param s Pattern, may contains dynamic matching parameters.\n * @returns {object} key, carry, multi.\n * @property {string} key - Dynamic key.\n * @property {number} carry - The length of the modifier symbol for the dynamic prefix.\n * @property {boolean} multi - Ignore after.\n */\n static dynamic(s: string): {\n key: string;\n carry: number;\n multi: boolean;\n } {\n if (s[0] === \"{\" && s[s.length - 1] === \"}\") {\n s = s.substring(1, s.length - 1);\n if (s[0] !== \":\" && s[0] !== \"*\" && s[0] !== \".\") {\n return {\n key: s,\n carry: 0,\n multi: false,\n };\n }\n }\n if (s[0] === \"[\" && s[s.length - 1] === \"]\") {\n s = s.substring(1, s.length - 1);\n }\n const s1 = s.substring(0, 1);\n if (s1 === \":\") {\n return {\n key: s,\n carry: 1,\n multi: false,\n };\n }\n if (s1 === \"*\") {\n return {\n key: s,\n carry: 1,\n multi: true,\n };\n }\n const s3 = s.substring(0, 3);\n if (s3 === \"...\") {\n return {\n key: s,\n carry: 3,\n multi: true,\n };\n }\n return {\n key: \"\",\n carry: 0,\n multi: false,\n };\n }\n\n useWhich(s: string): string | null {\n const sp = RouteTree.split(s);\n const t = this.search(sp);\n if (t) {\n return t.pattern;\n }\n return null;\n }\n\n parseParams(s: string, pattern: string): Record<string, string> {\n const sSplit = RouteTree.split(s);\n const patternSplit = RouteTree.split(pattern);\n const params: Record<string, string> = {};\n for (const index in patternSplit) {\n const { key, carry, multi } = RouteTree.dynamic(patternSplit[index]);\n if (!key) {\n continue;\n }\n params[key.substring(carry)] = sSplit[index];\n if (multi) {\n break;\n }\n }\n return params;\n }\n}\nexport default RouteTree;\n"]}
package/lib/utils.d.ts DELETED
@@ -1,10 +0,0 @@
1
- export declare function isNil(n: any): boolean;
2
- export declare function notNil(n: any): boolean;
3
- export declare function numerical(n?: string | number): boolean;
4
- export declare function random(m?: number, n?: number): number;
5
- export declare function joinRules(rules: Record<string, Record<string, string | number>>): string;
6
- export declare function joinProperties(prop: Record<string, string | number>): string;
7
- export declare function debounce(func: (_: any) => any, timeout: number): () => void;
8
- export declare function deepQuerySelectorAll<E extends Element = HTMLElement>(selectors: string, root?: E | ParentNode): E[];
9
- export declare function deepQuerySelector<E extends Element = HTMLElement>(selectors: string, root?: E | ParentNode): E;
10
- //# sourceMappingURL=utils.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"utils.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["lib/utils.ts"],"names":[],"mappings":"AAAA,wBAAgB,KAAK,CAAC,CAAC,EAAE,GAAG,WAG3B;AAED,wBAAgB,MAAM,CAAC,CAAC,EAAE,GAAG,WAE5B;AAED,wBAAgB,SAAS,CAAC,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM,WAE5C;AAED,wBAAgB,MAAM,CAAC,CAAC,SAAI,EAAE,CAAC,SAAI,UAElC;AAED,wBAAgB,SAAS,CAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,CAAC,UAK/E;AAED,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,UAKnE;AAED,wBAAgB,QAAQ,CAAC,IAAI,EAAE,CAAC,CAAC,EAAE,GAAG,KAAK,GAAG,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM,IAAI,CAU3E;AAED,wBAAgB,oBAAoB,CAAC,CAAC,SAAS,OAAO,GAAG,WAAW,EAClE,SAAS,EAAE,MAAM,EACjB,IAAI,GAAE,CAAC,GAAG,UAA0B,GACnC,CAAC,EAAE,CAmBL;AAED,wBAAgB,iBAAiB,CAAC,CAAC,SAAS,OAAO,GAAG,WAAW,EAC/D,SAAS,EAAE,MAAM,EACjB,IAAI,GAAE,CAAC,GAAG,UAA0B,GACnC,CAAC,CAkBH"}
package/lib/utils.js DELETED
@@ -1,71 +0,0 @@
1
- export function isNil(n) {
2
- // eslint-disable-next-line eqeqeq
3
- return n == null;
4
- }
5
- export function notNil(n) {
6
- return !isNil(n);
7
- }
8
- export function numerical(n) {
9
- return !isNaN(+n);
10
- }
11
- export function random(m = 0, n = 1) {
12
- return Math.random() * (n - m) + m;
13
- }
14
- export function joinRules(rules) {
15
- return Object.keys(rules).reduce((css, key) => {
16
- const properties = joinProperties(rules[key]);
17
- return properties ? css + `${key}{${properties}}` : css;
18
- }, "");
19
- }
20
- export function joinProperties(prop) {
21
- return Object.keys(prop).reduce((css, key) => {
22
- const value = prop[key];
23
- return isNil(value) ? css : css + `${key}:${value};`;
24
- }, "");
25
- }
26
- export function debounce(func, timeout) {
27
- let timer = null;
28
- return function (...args) {
29
- if (timer) {
30
- clearTimeout(timer);
31
- }
32
- timer = setTimeout(() => {
33
- func.apply(this, args);
34
- }, timeout);
35
- };
36
- }
37
- export function deepQuerySelectorAll(selectors, root = document.body) {
38
- const result = [];
39
- if (!root || !selectors) {
40
- return result;
41
- }
42
- if (root.shadowRoot) {
43
- result.push(...deepQuerySelectorAll(selectors, root.shadowRoot));
44
- }
45
- const a = root.querySelectorAll(selectors);
46
- result.push(...Array.from(a));
47
- for (const child of root.children) {
48
- result.push(...deepQuerySelectorAll(selectors, child));
49
- }
50
- return [...new Set(result)];
51
- }
52
- export function deepQuerySelector(selectors, root = document.body) {
53
- if (!root || !selectors) {
54
- return null;
55
- }
56
- if (root.shadowRoot) {
57
- return deepQuerySelector(selectors, root.shadowRoot);
58
- }
59
- const a = root.querySelector(selectors);
60
- if (a) {
61
- return a;
62
- }
63
- for (const child of root.children) {
64
- const b = deepQuerySelector(selectors, child);
65
- if (b) {
66
- return b;
67
- }
68
- }
69
- return null;
70
- }
71
- //# sourceMappingURL=utils.js.map
package/lib/utils.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"utils.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["lib/utils.ts"],"names":[],"mappings":"AAAA,MAAM,UAAU,KAAK,CAAC,CAAM;IAC1B,kCAAkC;IAClC,OAAO,CAAC,IAAI,IAAI,CAAC;AACnB,CAAC;AAED,MAAM,UAAU,MAAM,CAAC,CAAM;IAC3B,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;AACnB,CAAC;AAED,MAAM,UAAU,SAAS,CAAC,CAAmB;IAC3C,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;AACpB,CAAC;AAED,MAAM,UAAU,MAAM,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC;IACjC,OAAO,IAAI,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC;AACrC,CAAC;AAED,MAAM,UAAU,SAAS,CAAC,KAAsD;IAC9E,OAAO,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,MAAM,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE;QAC5C,MAAM,UAAU,GAAG,cAAc,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;QAC9C,OAAO,UAAU,CAAC,CAAC,CAAC,GAAG,GAAG,GAAG,GAAG,IAAI,UAAU,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC;IAC1D,CAAC,EAAE,EAAE,CAAC,CAAC;AACT,CAAC;AAED,MAAM,UAAU,cAAc,CAAC,IAAqC;IAClE,OAAO,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC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AAC,IAAI,CAAC,GAAG,oBAAoB,CAAI,SAAS,EAAE,KAAK,CAAC,CAAC,CAAC;IAC5D,CAAC;IAED,OAAO,CAAC,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC;AAC9B,CAAC;AAED,MAAM,UAAU,iBAAiB,CAC/B,SAAiB,EACjB,OAAuB,QAAQ,CAAC,IAAI;IAEpC,IAAI,CAAC,IAAI,IAAI,CAAC,SAAS,EAAE,CAAC;QACxB,OAAO,IAAI,CAAC;IACd,CAAC;IACD,IAAK,IAAU,CAAC,UAAU,EAAE,CAAC;QAC3B,OAAO,iBAAiB,CAAI,SAAS,EAAG,IAAU,CAAC,UAAU,CAAC,CAAC;IACjE,CAAC;IACD,MAAM,CAAC,GAAG,IAAI,CAAC,aAAa,CAAI,SAAS,CAAC,CAAC;IAC3C,IAAI,CAAC,EAAE,CAAC;QACN,OAAO,CAAC,CAAC;IACX,CAAC;IACD,KAAK,MAAM,KAAK,IAAI,IAAI,CAAC,QAAQ,EAAE,CAAC;QAClC,MAAM,CAAC,GAAG,iBAAiB,CAAI,SAAS,EAAE,KAAK,CAAC,CAAC;QACjD,IAAI,CAAC,EAAE,CAAC;YACN,OAAO,CAAC,CAAC;QACX,CAAC;IACH,CAAC;IACD,OAAO,IAAI,CAAC;AACd,CAAC","sourcesContent":["export function isNil(n: any) {\n // eslint-disable-next-line eqeqeq\n return n == null;\n}\n\nexport function notNil(n: any) {\n return !isNil(n);\n}\n\nexport function numerical(n?: string | number) {\n return !isNaN(+n);\n}\n\nexport function random(m = 0, n = 1) {\n return Math.random() * (n - m) + m;\n}\n\nexport function joinRules(rules: Record<string, Record<string, string | number>>) {\n return Object.keys(rules).reduce((css, key) => {\n const properties = joinProperties(rules[key]);\n return properties ? css + `${key}{${properties}}` : css;\n }, \"\");\n}\n\nexport function joinProperties(prop: Record<string, string | number>) {\n return Object.keys(prop).reduce((css, key) => {\n const value = prop[key];\n return isNil(value) ? css : css + `${key}:${value};`;\n }, \"\");\n}\n\nexport function debounce(func: (_: any) => any, timeout: number): () => void {\n let timer: number | null = null;\n return function (this: any, ...args: any[]) {\n if (timer) {\n clearTimeout(timer);\n }\n timer = setTimeout(() => {\n func.apply(this, args);\n }, timeout) as unknown as number;\n };\n}\n\nexport function deepQuerySelectorAll<E extends Element = HTMLElement>(\n selectors: string,\n root: E | ParentNode = document.body,\n): E[] {\n const result: E[] = [];\n\n if (!root || !selectors) {\n return result;\n }\n\n if ((root as E).shadowRoot) {\n result.push(...deepQuerySelectorAll<E>(selectors, (root as E).shadowRoot));\n }\n\n const a = root.querySelectorAll<E>(selectors);\n result.push(...Array.from(a));\n\n for (const child of root.children) {\n result.push(...deepQuerySelectorAll<E>(selectors, child));\n }\n\n return [...new Set(result)];\n}\n\nexport function deepQuerySelector<E extends Element = HTMLElement>(\n selectors: string,\n root: E | ParentNode = document.body,\n): E {\n if (!root || !selectors) {\n return null;\n }\n if ((root as E).shadowRoot) {\n return deepQuerySelector<E>(selectors, (root as E).shadowRoot);\n }\n const a = root.querySelector<E>(selectors);\n if (a) {\n return a;\n }\n for (const child of root.children) {\n const b = deepQuerySelector<E>(selectors, child);\n if (b) {\n return b;\n }\n }\n return null;\n}\n"]}
package/overbreath.d.ts DELETED
@@ -1,9 +0,0 @@
1
- import Overbreath from "./web-components/text/overbreath.js";
2
- export default Overbreath;
3
- export * from "./web-components/text/overbreath.js";
4
- declare global {
5
- interface HTMLElementTagNameMap {
6
- "g-overbreath": Overbreath;
7
- }
8
- }
9
- //# sourceMappingURL=overbreath.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"overbreath.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["overbreath.ts"],"names":[],"mappings":"AAAA,OAAO,UAAU,MAAM,qCAAqC,CAAC;AAE7D,eAAe,UAAU,CAAC;AAC1B,cAAc,qCAAqC,CAAC;AAEpD,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,cAAc,EAAE,UAAU,CAAC;KAC5B;CACF"}
package/overbreath.js DELETED
@@ -1,5 +0,0 @@
1
- import Overbreath from "./web-components/text/overbreath.js";
2
- Overbreath.define();
3
- export default Overbreath;
4
- export * from "./web-components/text/overbreath.js";
5
- //# sourceMappingURL=overbreath.js.map
package/overbreath.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"overbreath.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["overbreath.ts"],"names":[],"mappings":"AAAA,OAAO,UAAU,MAAM,qCAAqC,CAAC;AAC7D,UAAU,CAAC,MAAM,EAAE,CAAC;AACpB,eAAe,UAAU,CAAC;AAC1B,cAAc,qCAAqC,CAAC","sourcesContent":["import Overbreath from \"./web-components/text/overbreath.js\";\nOverbreath.define();\nexport default Overbreath;\nexport * from \"./web-components/text/overbreath.js\";\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"g-overbreath\": Overbreath;\n }\n}\n"]}
@@ -1,41 +0,0 @@
1
- export declare class GodownConfig {
2
- assign: Record<string, any>;
3
- reflect: boolean;
4
- prefix: string;
5
- suffix: string;
6
- cssvar: string;
7
- components: Accessor<string, CustomElementConstructor>;
8
- readonly override: {
9
- pushState?: typeof history.pushState;
10
- };
11
- tag(origin: string): string;
12
- define(name: string, constructor: CustomElementConstructor, options?: ElementDefinitionOptions): void;
13
- /**
14
- * Use `this.components` instead.
15
- * @deprecated
16
- */
17
- nameMap: Accessor;
18
- /**
19
- * Use `this.components` instead.
20
- * @deprecated
21
- */
22
- classMap: Accessor<string, CustomElementConstructor>;
23
- }
24
- export default GodownConfig;
25
- export interface GodownEventMap {
26
- "godown-define": DefineEvent;
27
- }
28
- export interface DefineEvent {
29
- name: string;
30
- constructor: CustomElementConstructor;
31
- options?: ElementDefinitionOptions;
32
- }
33
- export type MixedRecord<K, V, M> = M | (K extends PropertyKey ? M & Record<K, V> : never);
34
- export type SetAccessor<K = string, V = string | undefined> = MixedRecord<K, V, {
35
- set(key: K, value: V): void;
36
- }>;
37
- export type GetAccessor<K = string, V = string | undefined> = MixedRecord<K, V, {
38
- get: (key: K) => V;
39
- }>;
40
- export type Accessor<K = string, V = string | undefined> = GetAccessor<K, V> & SetAccessor<K, V>;
41
- //# sourceMappingURL=godown-config.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"godown-config.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["proto/godown-config.ts"],"names":[],"mappings":"AAAA,qBAAa,YAAY;IACvB,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAQ;IACnC,OAAO,UAAS;IAChB,MAAM,SAAQ;IACd,MAAM,SAAM;IACZ,MAAM,SAAY;IAClB,UAAU,EAAE,QAAQ,CAAC,MAAM,EAAE,wBAAwB,CAAC,CAAa;IACnE,QAAQ,CAAC,QAAQ,EAAE;QACjB,SAAS,CAAC,EAAE,OAAO,OAAO,CAAC,SAAS,CAAC;KACtC,CAAM;IAEP,GAAG,CAAC,MAAM,EAAE,MAAM;IAIlB,MAAM,CAAC,IAAI,EAAE,MAAM,EAAE,WAAW,EAAE,wBAAwB,EAAE,OAAO,CAAC,EAAE,wBAAwB;IAc9F;;;OAGG;IACH,OAAO,EAAE,QAAQ,CAAC;IAClB;;;OAGG;IACH,QAAQ,EAAE,QAAQ,CAAC,MAAM,EAAE,wBAAwB,CAAC,CAAC;CACtD;AAED,eAAe,YAAY,CAAC;AAE5B,MAAM,WAAW,cAAc;IAC7B,eAAe,EAAE,WAAW,CAAC;CAC9B;AAED,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,wBAAwB,CAAC;IACtC,OAAO,CAAC,EAAE,wBAAwB,CAAC;CACpC;AAED,MAAM,MAAM,WAAW,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,SAAS,WAAW,GAAG,CAAC,GAAG,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,KAAK,CAAC,CAAC;AAC1F,MAAM,MAAM,WAAW,CAAC,CAAC,GAAG,MAAM,EAAE,CAAC,GAAG,MAAM,GAAG,SAAS,IAAI,WAAW,CAAC,CAAC,EAAE,CAAC,EAAE;IAAE,GAAG,CAAC,GAAG,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,GAAG,IAAI,CAAA;CAAE,CAAC,CAAC;AACjH,MAAM,MAAM,WAAW,CAAC,CAAC,GAAG,MAAM,EAAE,CAAC,GAAG,MAAM,GAAG,SAAS,IAAI,WAAW,CAAC,CAAC,EAAE,CAAC,EAAE;IAAE,GAAG,EAAE,CAAC,GAAG,EAAE,CAAC,KAAK,CAAC,CAAA;CAAE,CAAC,CAAC;AACxG,MAAM,MAAM,QAAQ,CAAC,CAAC,GAAG,MAAM,EAAE,CAAC,GAAG,MAAM,GAAG,SAAS,IAAI,WAAW,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,WAAW,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC"}
@@ -1,27 +0,0 @@
1
- export class GodownConfig {
2
- constructor() {
3
- this.assign = null;
4
- this.reflect = false;
5
- this.prefix = "g-";
6
- this.suffix = "";
7
- this.cssvar = "godown";
8
- this.components = new Map();
9
- this.override = {};
10
- }
11
- tag(origin) {
12
- return this.prefix + origin + this.suffix;
13
- }
14
- define(name, constructor, options) {
15
- customElements.define(name, constructor, options);
16
- this.components.set(name, constructor);
17
- globalThis.document?.dispatchEvent(new CustomEvent("godown-define", {
18
- detail: {
19
- name,
20
- constructor,
21
- options,
22
- },
23
- }));
24
- }
25
- }
26
- export default GodownConfig;
27
- //# sourceMappingURL=godown-config.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"godown-config.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["proto/godown-config.ts"],"names":[],"mappings":"AAAA,MAAM,OAAO,YAAY;IAAzB;QACE,WAAM,GAAwB,IAAI,CAAC;QACnC,YAAO,GAAG,KAAK,CAAC;QAChB,WAAM,GAAG,IAAI,CAAC;QACd,WAAM,GAAG,EAAE,CAAC;QACZ,WAAM,GAAG,QAAQ,CAAC;QAClB,eAAU,GAA+C,IAAI,GAAG,EAAE,CAAC;QAC1D,aAAQ,GAEb,EAAE,CAAC;IA8BT,CAAC;IA5BC,GAAG,CAAC,MAAc;QAChB,OAAO,IAAI,CAAC,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC,MAAM,CAAC;IAC5C,CAAC;IAED,MAAM,CAAC,IAAY,EAAE,WAAqC,EAAE,OAAkC;QAC5F,cAAc,CAAC,MAAM,CAAC,IAAI,EAAE,WAAW,EAAE,OAAO,CAAC,CAAC;QAClD,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,EAAE,WAAW,CAAC,CAAC;QACvC,UAAU,CAAC,QAAQ,EAAE,aAAa,CAChC,IAAI,WAAW,CAAc,eAAe,EAAE;YAC5C,MAAM,EAAE;gBACN,IAAI;gBACJ,WAAW;gBACX,OAAO;aACR;SACF,CAAC,CACH,CAAC;IACJ,CAAC;CAYF;AAED,eAAe,YAAY,CAAC","sourcesContent":["export class GodownConfig {\n assign: Record<string, any> = null;\n reflect = false;\n prefix = \"g-\";\n suffix = \"\";\n cssvar = \"godown\";\n components: Accessor<string, CustomElementConstructor> = new Map();\n readonly override: {\n pushState?: typeof history.pushState;\n } = {};\n\n tag(origin: string) {\n return this.prefix + origin + this.suffix;\n }\n\n define(name: string, constructor: CustomElementConstructor, options?: ElementDefinitionOptions) {\n customElements.define(name, constructor, options);\n this.components.set(name, constructor);\n globalThis.document?.dispatchEvent(\n new CustomEvent<DefineEvent>(\"godown-define\", {\n detail: {\n name,\n constructor,\n options,\n },\n }),\n );\n }\n\n /**\n * Use `this.components` instead.\n * @deprecated\n */\n nameMap: Accessor;\n /**\n * Use `this.components` instead.\n * @deprecated\n */\n classMap: Accessor<string, CustomElementConstructor>;\n}\n\nexport default GodownConfig;\n\nexport interface GodownEventMap {\n \"godown-define\": DefineEvent;\n}\n\nexport interface DefineEvent {\n name: string;\n constructor: CustomElementConstructor;\n options?: ElementDefinitionOptions;\n}\n\nexport type MixedRecord<K, V, M> = M | (K extends PropertyKey ? M & Record<K, V> : never);\nexport type SetAccessor<K = string, V = string | undefined> = MixedRecord<K, V, { set(key: K, value: V): void }>;\nexport type GetAccessor<K = string, V = string | undefined> = MixedRecord<K, V, { get: (key: K) => V }>;\nexport type Accessor<K = string, V = string | undefined> = GetAccessor<K, V> & SetAccessor<K, V>;\n"]}