godown 2.6.2 → 2.7.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 (461) hide show
  1. package/{deps.d.ts → .deps.d.ts} +1 -1
  2. package/.deps.d.ts.map +1 -0
  3. package/{deps.js → .deps.js} +1 -1
  4. package/.deps.js.map +1 -0
  5. package/README.md +166 -43
  6. package/a.d.ts +2 -0
  7. package/a.d.ts.map +1 -0
  8. package/a.js +2 -0
  9. package/a.js.map +1 -0
  10. package/alert.d.ts +2 -0
  11. package/alert.d.ts.map +1 -0
  12. package/alert.js +2 -0
  13. package/alert.js.map +1 -0
  14. package/avatar-group.js.map +1 -1
  15. package/avatar.d.ts +2 -0
  16. package/avatar.d.ts.map +1 -0
  17. package/avatar.js +2 -0
  18. package/avatar.js.map +1 -0
  19. package/button.d.ts +2 -0
  20. package/button.d.ts.map +1 -0
  21. package/button.js +2 -0
  22. package/button.js.map +1 -0
  23. package/card.d.ts +2 -0
  24. package/card.d.ts.map +1 -0
  25. package/card.js +2 -0
  26. package/card.js.map +1 -0
  27. package/carousel.d.ts +2 -0
  28. package/carousel.d.ts.map +1 -0
  29. package/carousel.js +2 -0
  30. package/carousel.js.map +1 -0
  31. package/clip.d.ts +2 -0
  32. package/clip.d.ts.map +1 -0
  33. package/clip.js +2 -0
  34. package/clip.js.map +1 -0
  35. package/conf.d.ts +23 -3
  36. package/conf.d.ts.map +1 -1
  37. package/conf.js +19 -16
  38. package/conf.js.map +1 -1
  39. package/decorators/define.d.ts +7 -0
  40. package/decorators/define.d.ts.map +1 -0
  41. package/decorators/define.js +11 -0
  42. package/decorators/define.js.map +1 -0
  43. package/details-group.js.map +1 -1
  44. package/details.d.ts +2 -0
  45. package/details.d.ts.map +1 -0
  46. package/details.js +2 -0
  47. package/details.js.map +1 -0
  48. package/dialog.d.ts +2 -0
  49. package/dialog.d.ts.map +1 -0
  50. package/dialog.js +2 -0
  51. package/dialog.js.map +1 -0
  52. package/divider.d.ts +2 -0
  53. package/divider.d.ts.map +1 -0
  54. package/divider.js +2 -0
  55. package/divider.js.map +1 -0
  56. package/dragbox.d.ts +2 -0
  57. package/dragbox.d.ts.map +1 -0
  58. package/dragbox.js +2 -0
  59. package/dragbox.js.map +1 -0
  60. package/flex-flow.js.map +1 -1
  61. package/form.d.ts +2 -0
  62. package/form.d.ts.map +1 -0
  63. package/form.js +2 -0
  64. package/form.js.map +1 -0
  65. package/godown-element.d.ts +1 -1
  66. package/godown-element.d.ts.map +1 -1
  67. package/godown-element.js +12 -4
  68. package/godown-element.js.map +1 -1
  69. package/input.d.ts +2 -0
  70. package/input.d.ts.map +1 -0
  71. package/input.js +2 -0
  72. package/input.js.map +1 -0
  73. package/label-input.js.map +1 -1
  74. package/lib/event-collection.d.ts +1 -1
  75. package/lib/event-collection.d.ts.map +1 -1
  76. package/lib/templates.d.ts +2 -0
  77. package/lib/templates.d.ts.map +1 -1
  78. package/lib/templates.js +4 -0
  79. package/lib/templates.js.map +1 -1
  80. package/lib/utils.d.ts +0 -1
  81. package/lib/utils.d.ts.map +1 -1
  82. package/lib/utils.js +0 -7
  83. package/lib/utils.js.map +1 -1
  84. package/naming.d.ts +91 -0
  85. package/naming.d.ts.map +1 -0
  86. package/naming.js +67 -0
  87. package/naming.js.map +1 -0
  88. package/nav-layout.js.map +1 -1
  89. package/open-offset.d.ts +1 -1
  90. package/open-offset.d.ts.map +1 -1
  91. package/open-offset.js +1 -1
  92. package/open-offset.js.map +1 -1
  93. package/overbreath.d.ts +2 -0
  94. package/overbreath.d.ts.map +1 -0
  95. package/overbreath.js +2 -0
  96. package/overbreath.js.map +1 -0
  97. package/package.json +29 -33
  98. package/progress.d.ts +2 -0
  99. package/progress.d.ts.map +1 -0
  100. package/progress.js +2 -0
  101. package/progress.js.map +1 -0
  102. package/react/index.d.ts +24 -25
  103. package/react/index.d.ts.map +1 -1
  104. package/react/index.js +52 -56
  105. package/react/index.js.map +1 -1
  106. package/router-a.d.ts +2 -0
  107. package/router-a.d.ts.map +1 -0
  108. package/router-a.js +2 -0
  109. package/router-a.js.map +1 -0
  110. package/router.d.ts +2 -0
  111. package/router.d.ts.map +1 -0
  112. package/router.js +2 -0
  113. package/router.js.map +1 -0
  114. package/search-input.js.map +1 -1
  115. package/select-input.js.map +1 -1
  116. package/skeleton.d.ts +2 -0
  117. package/skeleton.d.ts.map +1 -0
  118. package/skeleton.js +2 -0
  119. package/skeleton.js.map +1 -0
  120. package/split-input.js.map +1 -1
  121. package/supers/anchor.d.ts +26 -0
  122. package/supers/anchor.d.ts.map +1 -0
  123. package/{web-components/a/super-a.js → supers/anchor.js} +27 -22
  124. package/supers/anchor.js.map +1 -0
  125. package/supers/input.d.ts +28 -0
  126. package/supers/input.d.ts.map +1 -0
  127. package/supers/input.js +117 -0
  128. package/supers/input.js.map +1 -0
  129. package/{web-components/open/open.d.ts → supers/openable.d.ts} +6 -6
  130. package/supers/openable.d.ts.map +1 -0
  131. package/{web-components/open/open.js → supers/openable.js} +11 -11
  132. package/supers/openable.js.map +1 -0
  133. package/supers/root.d.ts +18 -0
  134. package/supers/root.d.ts.map +1 -0
  135. package/{root.js → supers/root.js} +3 -11
  136. package/supers/root.js.map +1 -0
  137. package/switch-input.js.map +1 -1
  138. package/tabs.d.ts +2 -0
  139. package/tabs.d.ts.map +1 -0
  140. package/tabs.js +2 -0
  141. package/tabs.js.map +1 -0
  142. package/time.d.ts +2 -0
  143. package/time.d.ts.map +1 -0
  144. package/time.js +2 -0
  145. package/time.js.map +1 -0
  146. package/tooltip.d.ts +2 -0
  147. package/tooltip.d.ts.map +1 -0
  148. package/tooltip.js +2 -0
  149. package/tooltip.js.map +1 -0
  150. package/typewriter.d.ts +2 -0
  151. package/typewriter.d.ts.map +1 -0
  152. package/typewriter.js +2 -0
  153. package/typewriter.js.map +1 -0
  154. package/web-components/a/a.d.ts +16 -0
  155. package/web-components/a/a.d.ts.map +1 -0
  156. package/web-components/a/a.js +17 -0
  157. package/web-components/a/a.js.map +1 -0
  158. package/web-components/{items/alert-item.d.ts → alert/alert.d.ts} +8 -7
  159. package/web-components/alert/alert.d.ts.map +1 -0
  160. package/web-components/{items/alert-item.js → alert/alert.js} +18 -17
  161. package/web-components/alert/alert.js.map +1 -0
  162. package/web-components/{a/avatar-a.d.ts → avatar/avatar.d.ts} +9 -8
  163. package/web-components/avatar/avatar.d.ts.map +1 -0
  164. package/web-components/{a/avatar-a.js → avatar/avatar.js} +20 -19
  165. package/web-components/avatar/avatar.js.map +1 -0
  166. package/web-components/button/{base-button.d.ts → button.d.ts} +7 -10
  167. package/web-components/button/button.d.ts.map +1 -0
  168. package/web-components/button/{base-button.js → button.js} +22 -46
  169. package/web-components/button/button.js.map +1 -0
  170. package/web-components/{items/card-item.d.ts → card/card.d.ts} +8 -7
  171. package/web-components/card/card.d.ts.map +1 -0
  172. package/web-components/{items/card-item.js → card/card.js} +15 -14
  173. package/web-components/card/card.js.map +1 -0
  174. package/web-components/carousel/{carousel-slider.d.ts → carousel.d.ts} +8 -6
  175. package/web-components/carousel/carousel.d.ts.map +1 -0
  176. package/web-components/carousel/{carousel-slider.js → carousel.js} +16 -16
  177. package/web-components/carousel/carousel.js.map +1 -0
  178. package/web-components/{open/open-details.d.ts → details/details.d.ts} +8 -7
  179. package/web-components/details/details.d.ts.map +1 -0
  180. package/web-components/{open/open-details.js → details/details.js} +17 -16
  181. package/web-components/details/details.js.map +1 -0
  182. package/web-components/{open/open-dialog.d.ts → dialog/dialog.d.ts} +9 -7
  183. package/web-components/dialog/dialog.d.ts.map +1 -0
  184. package/web-components/{open/open-dialog.js → dialog/dialog.js} +19 -18
  185. package/web-components/dialog/dialog.js.map +1 -0
  186. package/web-components/form/{base-form.d.ts → form.d.ts} +8 -7
  187. package/web-components/form/form.d.ts.map +1 -0
  188. package/web-components/form/{base-form.js → form.js} +16 -15
  189. package/web-components/form/form.js.map +1 -0
  190. package/web-components/group/avatar-group.d.ts +6 -5
  191. package/web-components/group/avatar-group.d.ts.map +1 -1
  192. package/web-components/group/avatar-group.js +8 -7
  193. package/web-components/group/avatar-group.js.map +1 -1
  194. package/web-components/group/details-group.d.ts +3 -2
  195. package/web-components/group/details-group.d.ts.map +1 -1
  196. package/web-components/group/details-group.js +4 -3
  197. package/web-components/group/details-group.js.map +1 -1
  198. package/web-components/index.d.ts +24 -25
  199. package/web-components/index.d.ts.map +1 -1
  200. package/web-components/index.js +24 -26
  201. package/web-components/index.js.map +1 -1
  202. package/web-components/input/input.d.ts +44 -22
  203. package/web-components/input/input.d.ts.map +1 -1
  204. package/web-components/input/input.js +210 -80
  205. package/web-components/input/input.js.map +1 -1
  206. package/web-components/input/label-input.d.ts +5 -4
  207. package/web-components/input/label-input.d.ts.map +1 -1
  208. package/web-components/input/label-input.js +7 -6
  209. package/web-components/input/label-input.js.map +1 -1
  210. package/web-components/input/search-input.d.ts +5 -4
  211. package/web-components/input/search-input.d.ts.map +1 -1
  212. package/web-components/input/search-input.js +7 -6
  213. package/web-components/input/search-input.js.map +1 -1
  214. package/web-components/input/select-input.d.ts +5 -4
  215. package/web-components/input/select-input.d.ts.map +1 -1
  216. package/web-components/input/select-input.js +7 -6
  217. package/web-components/input/select-input.js.map +1 -1
  218. package/web-components/input/split-input.d.ts +5 -4
  219. package/web-components/input/split-input.d.ts.map +1 -1
  220. package/web-components/input/split-input.js +7 -6
  221. package/web-components/input/split-input.js.map +1 -1
  222. package/web-components/input/switch-input.d.ts +5 -4
  223. package/web-components/input/switch-input.d.ts.map +1 -1
  224. package/web-components/input/switch-input.js +7 -6
  225. package/web-components/input/switch-input.js.map +1 -1
  226. package/web-components/layout/divider.d.ts +22 -0
  227. package/web-components/layout/divider.d.ts.map +1 -0
  228. package/web-components/layout/{divider-line.js → divider.js} +13 -12
  229. package/web-components/layout/divider.js.map +1 -0
  230. package/web-components/layout/flex-flow.d.ts +3 -2
  231. package/web-components/layout/flex-flow.d.ts.map +1 -1
  232. package/web-components/layout/flex-flow.js +4 -3
  233. package/web-components/layout/flex-flow.js.map +1 -1
  234. package/web-components/layout/nav-layout.d.ts +4 -3
  235. package/web-components/layout/nav-layout.d.ts.map +1 -1
  236. package/web-components/layout/nav-layout.js +4 -3
  237. package/web-components/layout/nav-layout.js.map +1 -1
  238. package/web-components/{open → offset}/open-offset.d.ts +5 -4
  239. package/web-components/offset/open-offset.d.ts.map +1 -0
  240. package/web-components/{open → offset}/open-offset.js +5 -5
  241. package/web-components/offset/open-offset.js.map +1 -0
  242. package/web-components/{loading/loading-progress.d.ts → progress/progress.d.ts} +9 -7
  243. package/web-components/progress/progress.d.ts.map +1 -0
  244. package/web-components/{loading/loading-progress.js → progress/progress.js} +15 -14
  245. package/web-components/progress/progress.js.map +1 -0
  246. package/web-components/router/router-a.d.ts +25 -0
  247. package/web-components/router/router-a.d.ts.map +1 -0
  248. package/web-components/router/router-a.js +70 -0
  249. package/web-components/router/router-a.js.map +1 -0
  250. package/web-components/{view/route-view.d.ts → router/router.d.ts} +10 -9
  251. package/web-components/router/router.d.ts.map +1 -0
  252. package/web-components/{view/route-view.js → router/router.js} +21 -21
  253. package/web-components/router/router.js.map +1 -0
  254. package/web-components/{loading/skeleton-screen.d.ts → skeleton/skeleton.d.ts} +8 -7
  255. package/web-components/skeleton/skeleton.d.ts.map +1 -0
  256. package/web-components/{loading/skeleton-screen.js → skeleton/skeleton.js} +15 -14
  257. package/web-components/skeleton/skeleton.js.map +1 -0
  258. package/web-components/{group/tab-group.d.ts → tabs/tabs.d.ts} +9 -8
  259. package/web-components/tabs/tabs.d.ts.map +1 -0
  260. package/web-components/{group/tab-group.js → tabs/tabs.js} +17 -16
  261. package/web-components/tabs/tabs.js.map +1 -0
  262. package/web-components/text/clip.d.ts +22 -0
  263. package/web-components/text/clip.d.ts.map +1 -0
  264. package/web-components/text/{clip-text.js → clip.js} +13 -12
  265. package/web-components/text/clip.js.map +1 -0
  266. package/web-components/text/{overbreath-text.d.ts → overbreath.d.ts} +8 -7
  267. package/web-components/text/overbreath.d.ts.map +1 -0
  268. package/web-components/text/{overbreath-text.js → overbreath.js} +15 -14
  269. package/web-components/text/overbreath.js.map +1 -0
  270. package/web-components/text/time.d.ts +60 -0
  271. package/web-components/text/time.d.ts.map +1 -0
  272. package/web-components/{items/time-bar.js → text/time.js} +53 -36
  273. package/web-components/text/time.js.map +1 -0
  274. package/web-components/text/{typewriter-text.d.ts → typewriter.d.ts} +10 -9
  275. package/web-components/text/typewriter.d.ts.map +1 -0
  276. package/web-components/text/{typewriter-text.js → typewriter.js} +23 -22
  277. package/web-components/text/typewriter.js.map +1 -0
  278. package/web-components/tooltip/tooltip.d.ts +26 -0
  279. package/web-components/tooltip/tooltip.d.ts.map +1 -0
  280. package/web-components/{open/open-tooltip.js → tooltip/tooltip.js} +15 -14
  281. package/web-components/tooltip/tooltip.js.map +1 -0
  282. package/web-components/{items/drag-box.d.ts → wrapper/dragbox.d.ts} +7 -6
  283. package/web-components/wrapper/dragbox.d.ts.map +1 -0
  284. package/web-components/{items/drag-box.js → wrapper/dragbox.js} +14 -13
  285. package/web-components/wrapper/dragbox.js.map +1 -0
  286. package/web-components/{view/wrap-view.d.ts → wrapper/wrapper.d.ts} +7 -5
  287. package/web-components/wrapper/wrapper.d.ts.map +1 -0
  288. package/web-components/{view/wrap-view.js → wrapper/wrapper.js} +13 -12
  289. package/web-components/wrapper/wrapper.js.map +1 -0
  290. package/wrapper.d.ts +2 -0
  291. package/wrapper.d.ts.map +1 -0
  292. package/wrapper.js +2 -0
  293. package/wrapper.js.map +1 -0
  294. package/alert-item.d.ts +0 -2
  295. package/alert-item.d.ts.map +0 -1
  296. package/alert-item.js +0 -2
  297. package/alert-item.js.map +0 -1
  298. package/avatar-a.d.ts +0 -2
  299. package/avatar-a.d.ts.map +0 -1
  300. package/avatar-a.js +0 -2
  301. package/avatar-a.js.map +0 -1
  302. package/base-button.d.ts +0 -2
  303. package/base-button.d.ts.map +0 -1
  304. package/base-button.js +0 -2
  305. package/base-button.js.map +0 -1
  306. package/base-form.d.ts +0 -2
  307. package/base-form.d.ts.map +0 -1
  308. package/base-form.js +0 -2
  309. package/base-form.js.map +0 -1
  310. package/base-input.d.ts +0 -2
  311. package/base-input.d.ts.map +0 -1
  312. package/base-input.js +0 -2
  313. package/base-input.js.map +0 -1
  314. package/card-item.d.ts +0 -2
  315. package/card-item.d.ts.map +0 -1
  316. package/card-item.js +0 -2
  317. package/card-item.js.map +0 -1
  318. package/carousel-slider.d.ts +0 -2
  319. package/carousel-slider.d.ts.map +0 -1
  320. package/carousel-slider.js +0 -2
  321. package/carousel-slider.js.map +0 -1
  322. package/clip-text.d.ts +0 -2
  323. package/clip-text.d.ts.map +0 -1
  324. package/clip-text.js +0 -2
  325. package/clip-text.js.map +0 -1
  326. package/deps.d.ts.map +0 -1
  327. package/deps.js.map +0 -1
  328. package/divider-line.d.ts +0 -2
  329. package/divider-line.d.ts.map +0 -1
  330. package/divider-line.js +0 -2
  331. package/divider-line.js.map +0 -1
  332. package/drag-box.d.ts +0 -2
  333. package/drag-box.d.ts.map +0 -1
  334. package/drag-box.js +0 -2
  335. package/drag-box.js.map +0 -1
  336. package/link-a.d.ts +0 -2
  337. package/link-a.d.ts.map +0 -1
  338. package/link-a.js +0 -2
  339. package/link-a.js.map +0 -1
  340. package/loading-progress.d.ts +0 -2
  341. package/loading-progress.d.ts.map +0 -1
  342. package/loading-progress.js +0 -2
  343. package/loading-progress.js.map +0 -1
  344. package/open-details.d.ts +0 -2
  345. package/open-details.d.ts.map +0 -1
  346. package/open-details.js +0 -2
  347. package/open-details.js.map +0 -1
  348. package/open-dialog.d.ts +0 -2
  349. package/open-dialog.d.ts.map +0 -1
  350. package/open-dialog.js +0 -2
  351. package/open-dialog.js.map +0 -1
  352. package/open-tooltip.d.ts +0 -2
  353. package/open-tooltip.d.ts.map +0 -1
  354. package/open-tooltip.js +0 -2
  355. package/open-tooltip.js.map +0 -1
  356. package/overbreath-text.d.ts +0 -2
  357. package/overbreath-text.d.ts.map +0 -1
  358. package/overbreath-text.js +0 -2
  359. package/overbreath-text.js.map +0 -1
  360. package/root.d.ts +0 -23
  361. package/root.d.ts.map +0 -1
  362. package/root.js.map +0 -1
  363. package/route-view.d.ts +0 -2
  364. package/route-view.d.ts.map +0 -1
  365. package/route-view.js +0 -2
  366. package/route-view.js.map +0 -1
  367. package/sign-form.d.ts +0 -2
  368. package/sign-form.d.ts.map +0 -1
  369. package/sign-form.js +0 -2
  370. package/sign-form.js.map +0 -1
  371. package/skeleton-screen.d.ts +0 -2
  372. package/skeleton-screen.d.ts.map +0 -1
  373. package/skeleton-screen.js +0 -2
  374. package/skeleton-screen.js.map +0 -1
  375. package/super-a.d.ts +0 -2
  376. package/super-a.d.ts.map +0 -1
  377. package/super-a.js +0 -2
  378. package/super-a.js.map +0 -1
  379. package/tab-group.d.ts +0 -2
  380. package/tab-group.d.ts.map +0 -1
  381. package/tab-group.js +0 -2
  382. package/tab-group.js.map +0 -1
  383. package/time-bar.d.ts +0 -2
  384. package/time-bar.d.ts.map +0 -1
  385. package/time-bar.js +0 -2
  386. package/time-bar.js.map +0 -1
  387. package/typewriter-text.d.ts +0 -2
  388. package/typewriter-text.d.ts.map +0 -1
  389. package/typewriter-text.js +0 -2
  390. package/typewriter-text.js.map +0 -1
  391. package/web-components/a/avatar-a.d.ts.map +0 -1
  392. package/web-components/a/avatar-a.js.map +0 -1
  393. package/web-components/a/link-a.d.ts +0 -33
  394. package/web-components/a/link-a.d.ts.map +0 -1
  395. package/web-components/a/link-a.js +0 -81
  396. package/web-components/a/link-a.js.map +0 -1
  397. package/web-components/a/super-a.d.ts +0 -31
  398. package/web-components/a/super-a.d.ts.map +0 -1
  399. package/web-components/a/super-a.js.map +0 -1
  400. package/web-components/button/base-button.d.ts.map +0 -1
  401. package/web-components/button/base-button.js.map +0 -1
  402. package/web-components/carousel/carousel-slider.d.ts.map +0 -1
  403. package/web-components/carousel/carousel-slider.js.map +0 -1
  404. package/web-components/form/base-form.d.ts.map +0 -1
  405. package/web-components/form/base-form.js.map +0 -1
  406. package/web-components/form/sign-form.d.ts +0 -19
  407. package/web-components/form/sign-form.d.ts.map +0 -1
  408. package/web-components/form/sign-form.js +0 -16
  409. package/web-components/form/sign-form.js.map +0 -1
  410. package/web-components/group/tab-group.d.ts.map +0 -1
  411. package/web-components/group/tab-group.js.map +0 -1
  412. package/web-components/input/base-input.d.ts +0 -49
  413. package/web-components/input/base-input.d.ts.map +0 -1
  414. package/web-components/input/base-input.js +0 -246
  415. package/web-components/input/base-input.js.map +0 -1
  416. package/web-components/items/alert-item.d.ts.map +0 -1
  417. package/web-components/items/alert-item.js.map +0 -1
  418. package/web-components/items/card-item.d.ts.map +0 -1
  419. package/web-components/items/card-item.js.map +0 -1
  420. package/web-components/items/drag-box.d.ts.map +0 -1
  421. package/web-components/items/drag-box.js.map +0 -1
  422. package/web-components/items/index.d.ts +0 -5
  423. package/web-components/items/index.d.ts.map +0 -1
  424. package/web-components/items/index.js +0 -6
  425. package/web-components/items/index.js.map +0 -1
  426. package/web-components/items/time-bar.d.ts +0 -54
  427. package/web-components/items/time-bar.d.ts.map +0 -1
  428. package/web-components/items/time-bar.js.map +0 -1
  429. package/web-components/layout/divider-line.d.ts +0 -20
  430. package/web-components/layout/divider-line.d.ts.map +0 -1
  431. package/web-components/layout/divider-line.js.map +0 -1
  432. package/web-components/loading/loading-progress.d.ts.map +0 -1
  433. package/web-components/loading/loading-progress.js.map +0 -1
  434. package/web-components/loading/skeleton-screen.d.ts.map +0 -1
  435. package/web-components/loading/skeleton-screen.js.map +0 -1
  436. package/web-components/open/open-details.d.ts.map +0 -1
  437. package/web-components/open/open-details.js.map +0 -1
  438. package/web-components/open/open-dialog.d.ts.map +0 -1
  439. package/web-components/open/open-dialog.js.map +0 -1
  440. package/web-components/open/open-offset.d.ts.map +0 -1
  441. package/web-components/open/open-offset.js.map +0 -1
  442. package/web-components/open/open-tooltip.d.ts +0 -24
  443. package/web-components/open/open-tooltip.d.ts.map +0 -1
  444. package/web-components/open/open-tooltip.js.map +0 -1
  445. package/web-components/open/open.d.ts.map +0 -1
  446. package/web-components/open/open.js.map +0 -1
  447. package/web-components/text/clip-text.d.ts +0 -21
  448. package/web-components/text/clip-text.d.ts.map +0 -1
  449. package/web-components/text/clip-text.js.map +0 -1
  450. package/web-components/text/overbreath-text.d.ts.map +0 -1
  451. package/web-components/text/overbreath-text.js.map +0 -1
  452. package/web-components/text/typewriter-text.d.ts.map +0 -1
  453. package/web-components/text/typewriter-text.js.map +0 -1
  454. package/web-components/view/route-view.d.ts.map +0 -1
  455. package/web-components/view/route-view.js.map +0 -1
  456. package/web-components/view/wrap-view.d.ts.map +0 -1
  457. package/web-components/view/wrap-view.js.map +0 -1
  458. package/wrap-view.d.ts +0 -2
  459. package/wrap-view.d.ts.map +0 -1
  460. package/wrap-view.js +0 -2
  461. package/wrap-view.js.map +0 -1
@@ -1,28 +1,50 @@
1
- import { type CSSResultGroup } from "../../deps.js";
2
- import { GodownElement } from "../../root.js";
3
- export type InputType = "hidden" | "text" | "search" | "tel" | "url" | "email" | "password" | "datetime" | "date" | "month" | "week" | "time" | "datetime-local" | "number" | "range" | "color" | "checkbox" | "radio" | "file" | "image";
4
- export declare class InputElement extends GodownElement {
5
- type: InputType;
6
- name: string;
7
- value: string | any;
8
- label: string;
9
- def: string;
10
- pla?: string;
11
- autofocus: boolean;
1
+ import { type CSSResultGroup } from "../../.deps.js";
2
+ import { type HTMLTemplate } from "../../lib/templates.js";
3
+ import { GodownInput } from "../../supers/input.js";
4
+ /**
5
+ * {@linkcode Input }.
6
+ */
7
+ export declare class Input extends GodownInput {
8
+ /**
9
+ * Input sccept.
10
+ */
11
+ accept: any;
12
+ /**
13
+ * Value.
14
+ */
15
+ value: string | File | FileList;
16
+ /**
17
+ * Only single files are allowed to be selected.
18
+ */
19
+ only: boolean;
20
+ /**
21
+ * Input min.
22
+ */
23
+ min: number;
24
+ /**
25
+ * Input max.
26
+ */
27
+ max: number;
28
+ /**
29
+ * Input step.
30
+ */
31
+ step: number;
12
32
  _input: HTMLInputElement;
13
- compositing: boolean;
33
+ _ranged: HTMLElement;
14
34
  static styles: CSSResultGroup;
15
- namevalue(): [string, any];
16
- nameValue: () => [string, any];
17
- reset(): void;
18
- protected _handleInput(e: any): void;
19
- protected _handleChange(): void;
35
+ protected render(): HTMLTemplate;
20
36
  connectedCallback(): void;
21
- protected _initName(): void;
22
- protected _compositionCheck(): void;
23
- protected _changeInputType(t: InputType): void;
24
- focus(options?: FocusOptions): void;
25
37
  protected firstUpdated(): void;
26
- protected targetValue(e: Event): string | any;
38
+ protected _handleRange(e: any | Event): void;
39
+ protected _handleFile(e: any | Event): void;
40
+ reset(): void;
41
+ protected _typeSwitcher(): HTMLTemplate;
42
+ }
43
+ export default Input;
44
+ declare global {
45
+ interface HTMLElementTagNameMap {
46
+ "base-input": Input;
47
+ "g-input": Input;
48
+ }
27
49
  }
28
50
  //# sourceMappingURL=input.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"input.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["web-components/input/input.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,cAAc,EAAY,MAAM,eAAe,CAAC;AACnE,OAAO,EAAgB,aAAa,EAAE,MAAM,eAAe,CAAC;AAE5D,MAAM,MAAM,SAAS,GAAG,QAAQ,GAAG,MAAM,GAAG,QAAQ,GAAG,KAAK,GAAG,KAAK,GAAG,OAAO,GAAG,UAAU,GAAG,UAAU,GAAG,MAAM,GAAG,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,gBAAgB,GAAG,QAAQ,GAAG,OAAO,GAAG,OAAO,GAAG,UAAU,GAAG,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC;AAE1O,qBAAa,YAAa,SAAQ,aAAa;IAChB,IAAI,EAAE,SAAS,CAAU;IAC1C,IAAI,EAAE,MAAM,CAAa;IACzB,KAAK,EAAE,MAAM,GAAG,GAAG,CAAa;IACf,KAAK,SAAM;IAC5B,GAAG,SAAM;IACQ,GAAG,CAAC,EAAE,MAAM,CAAa;IACV,SAAS,UAAS;IAE9D,MAAM,EAAE,gBAAgB,CAAC;IACzB,WAAW,EAAE,OAAO,CAAC;IAErB,MAAM,CAAC,MAAM,iBAcO;IAEpB,SAAS,IAAI,CAAC,MAAM,EAAE,GAAG,CAAC;IAI1B,SAAS,sBAA0B;IAEnC,KAAK;IAKL,SAAS,CAAC,YAAY,CAAC,CAAC,EAAE,GAAG;IAU7B,SAAS,CAAC,aAAa;IAIvB,iBAAiB;IAWjB,SAAS,CAAC,SAAS;IAQnB,SAAS,CAAC,iBAAiB;IAY3B,SAAS,CAAC,gBAAgB,CAAC,CAAC,EAAE,SAAS;IAIvC,KAAK,CAAC,OAAO,CAAC,EAAE,YAAY;IAI5B,SAAS,CAAC,YAAY;IAKtB,SAAS,CAAC,WAAW,CAAC,CAAC,EAAE,KAAK,GAAG,MAAM,GAAG,GAAG;CAO9C"}
1
+ {"version":3,"file":"input.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["web-components/input/input.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,cAAc,EAAyB,MAAM,gBAAgB,CAAC;AAEjF,OAAO,EAAY,KAAK,YAAY,EAAE,MAAM,wBAAwB,CAAC;AACrE,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAKpD;;GAEG;AACH,qBACa,KAAM,SAAQ,WAAW;IACpC;;OAEG;IACS,MAAM,MAAa;IAC/B;;OAEG;IACS,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,QAAQ,CAAa;IACxD;;OAEG;IAC0B,IAAI,UAAS;IAC1C;;OAEG;IACyB,GAAG,SAAK;IACpC;;OAEG;IACyB,GAAG,SAAO;IACtC;;OAEG;IACyB,IAAI,SAAK;IAEpB,MAAM,EAAE,gBAAgB,CAAC;IACvB,OAAO,EAAE,WAAW,CAAC;IAExC,MAAM,CAAC,MAAM,iBA8GO;IAEpB,SAAS,CAAC,MAAM,IAAI,YAAY;IAahC,iBAAiB;IAejB,SAAS,CAAC,YAAY;IAOtB,SAAS,CAAC,YAAY,CAAC,CAAC,EAAE,GAAG,GAAG,KAAK;IAMrC,SAAS,CAAC,WAAW,CAAC,CAAC,EAAE,GAAG,GAAG,KAAK;IAKpC,KAAK;IAeL,SAAS,CAAC,aAAa,IAAI,YAAY;CAYxC;AAED,eAAe,KAAK,CAAC;AAErB,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,YAAY,EAAE,KAAK,CAAC;QACpB,SAAS,EAAE,KAAK,CAAC;KAClB;CACF"}
@@ -1,117 +1,247 @@
1
1
  import { __decorate } from "tslib";
2
- import { css, property } from "../../deps.js";
3
- import { cssvarValues, GodownElement } from "../../root.js";
4
- export class InputElement extends GodownElement {
2
+ import { css, html, property, query } from "../../.deps.js";
3
+ import { define } from "../../decorators/define.js";
4
+ import { htmlSlot } from "../../lib/templates.js";
5
+ import { GodownInput } from "../../supers/input.js";
6
+ import { cssvar, cssvarValues } from "../../supers/root.js";
7
+ const defineName = "input";
8
+ /**
9
+ * {@linkcode Input }.
10
+ */
11
+ let Input = class Input extends GodownInput {
5
12
  constructor() {
6
13
  super(...arguments);
7
- this.type = "text";
8
- this.name = undefined;
14
+ /**
15
+ * Input sccept.
16
+ */
17
+ this.accept = undefined;
18
+ /**
19
+ * Value.
20
+ */
9
21
  this.value = undefined;
10
- this.label = "";
11
- this.def = "";
12
- this.pla = undefined;
13
- this.autofocus = false;
14
- this.nameValue = () => this.namevalue();
22
+ /**
23
+ * Only single files are allowed to be selected.
24
+ */
25
+ this.only = false;
26
+ /**
27
+ * Input min.
28
+ */
29
+ this.min = 0;
30
+ /**
31
+ * Input max.
32
+ */
33
+ this.max = 100;
34
+ /**
35
+ * Input step.
36
+ */
37
+ this.step = 1;
15
38
  }
16
- namevalue() {
17
- return [this.name, this.value];
18
- }
19
- reset() {
20
- this.value = this.def;
21
- this._input.value = this.def;
22
- }
23
- _handleInput(e) {
24
- e.stopPropagation();
25
- this.value = e.target.value?.trim();
26
- if (this.compositing) {
27
- return;
39
+ render() {
40
+ if (this.type === "range") {
41
+ return html `<div class="range">
42
+ <input id="input" type="range" min="${this.min}" max="${this.max}" step="${this.step}" @input="${this._handleRange}" @change="${this._handleRange}" />
43
+ <b></b>
44
+ <b>
45
+ <i></i>
46
+ </b>
47
+ </div>`;
28
48
  }
29
- this.dispatchEvent(new CustomEvent("input", { detail: this.value, bubbles: true, composed: true }));
30
- this.dispatchEvent(new CustomEvent("change", { detail: this.value, composed: true }));
31
- }
32
- _handleChange() {
33
- this.dispatchEvent(new CustomEvent("change", { detail: this.value, composed: true }));
49
+ return html `<label for="input"> ${htmlSlot("pre")} ${this._typeSwitcher()} ${htmlSlot("suf")} </label>`;
34
50
  }
35
51
  connectedCallback() {
36
52
  super.connectedCallback();
37
- if (!this.def) {
38
- this.def = this.value || "";
53
+ if (this.type === "file") {
54
+ this.value = null;
39
55
  }
40
- if (!this.value) {
41
- this.value = this.def;
42
- }
43
- this._initName();
44
- }
45
- _initName() {
46
- if (!this.name) {
47
- if (this.label || this.type) {
48
- this.name = this.label || this.type;
56
+ else {
57
+ if (!this.def) {
58
+ this.def = this.value || "";
59
+ }
60
+ if (!this.value) {
61
+ this.value = this.def;
49
62
  }
50
63
  }
64
+ this._initName();
51
65
  }
52
- _compositionCheck() {
53
- if (this._input) {
54
- this.addEvent(this._input, "compositionstart", () => {
55
- this.compositing = true;
56
- });
57
- this.addEvent(this._input, "compositionend", (e) => {
58
- this.compositing = false;
59
- this._handleInput(e);
60
- });
66
+ firstUpdated() {
67
+ super.firstUpdated();
68
+ if (this.type === "range") {
69
+ this._ranged.style.width = 100 * (parseInt(this.value) / (this.max - this.min)) + "%";
61
70
  }
62
71
  }
63
- _changeInputType(t) {
64
- this._input.type = t;
72
+ _handleRange(e) {
73
+ this.value = e.target.value;
74
+ this._ranged.style.width = (100 * parseInt(e.target.value)) / (this.max - this.min) + "%";
75
+ this.dispatchEvent(new CustomEvent("input", { detail: this.value }));
65
76
  }
66
- focus(options) {
67
- this._input?.focus(options);
77
+ _handleFile(e) {
78
+ this.value = !this.only ? e.target.files : e.target.files[0];
79
+ this.dispatchEvent(new CustomEvent("change", { detail: this.value }));
68
80
  }
69
- firstUpdated() {
70
- this._compositionCheck();
71
- this.reset();
81
+ reset() {
82
+ if (this.type === "file") {
83
+ this.value = null;
84
+ return;
85
+ }
86
+ if (this.type === "range") {
87
+ this._input.value = this.def || ((this.max - this.min) / 2).toString();
88
+ this.value = this._input.value;
89
+ this._ranged.style.width = 100 * (parseInt(this.value) / (this.max - this.min)) + "%";
90
+ }
91
+ else {
92
+ this._input.value = this.def.toString();
93
+ this.value = this.def;
94
+ }
72
95
  }
73
- targetValue(e) {
74
- const target = e.target;
75
- if (target.value.trim) {
76
- return target.value.trim();
96
+ _typeSwitcher() {
97
+ switch (this.type) {
98
+ case "file":
99
+ return html `<input id="input" class="input" type="file" accept="${this.accept}" ?multiple="${!this.only}" @change="${this._handleFile}" />${htmlSlot()}`;
100
+ case "number":
101
+ return html `<input .value="${this.value}" ?autofocus="${this.autofocus}" id="input" class="input" type="number" placeholder="${this.pla}" min="${this.min}" max="${this.max}" @input="${this._handleInput}" @change="${this._handleChange}" />`;
102
+ default:
103
+ return html `<input .value="${this.value}" ?autofocus="${this.autofocus}" id="input" class="input" type="${this.type}" placeholder="${this.pla}" @input="${this._handleInput}" @change="${this._handleChange}" />`;
77
104
  }
78
- return target.value;
79
105
  }
80
- }
81
- InputElement.styles = [
82
- GodownElement.styles,
106
+ };
107
+ Input.styles = [
108
+ GodownInput.styles,
83
109
  css `
84
110
  :host {
85
- display: flex;
111
+ width: var(${cssvarValues.input}--width);
112
+ height: var(${cssvarValues.input}--height);
113
+ background: var(${cssvarValues.input}--background);
114
+ margin: var(${cssvarValues.input}--outline-width);
115
+ outline: var(${cssvarValues.input}--outline);
116
+ border-radius: var(${cssvarValues.input}--radius);
86
117
  }
87
- ::-ms-reveal {
118
+
119
+ input[type="file"] {
88
120
  display: none;
89
121
  }
90
- ::-webkit-calendar-picker-indicator {
91
- background-color: var(${cssvarValues.input}-true);
92
- border-radius: 0.1rem;
122
+
123
+ label,
124
+ div {
125
+ width: 100%;
126
+ display: flex;
127
+ align-items: center;
128
+ }
129
+
130
+ * {
131
+ border-radius: inherit;
132
+ cursor: inherit;
133
+ }
134
+
135
+ input {
136
+ box-sizing: border-box;
137
+ height: 100%;
138
+ width: 100%;
139
+ margin: 0;
140
+ color: inherit;
141
+ background: transparent;
142
+ padding: 0 0.25em;
143
+ border-radius: 0.25em;
144
+ }
145
+ `,
146
+ css `
147
+ :host([type="range"]) {
148
+ height: auto !important;
149
+ margin: 0.3em 0;
150
+ background: var(${cssvarValues.input}--false);
151
+ border-radius: 2em;
152
+ }
153
+
154
+ .range b:nth-of-type(1) {
155
+ width: 1em;
156
+ left: 0;
157
+ background: var(${cssvarValues.input}--true);
158
+ border-top-right-radius: 0;
159
+ border-bottom-right-radius: 0;
160
+ }
161
+
162
+ .range b {
163
+ pointer-events: none;
164
+ width: calc(100% - 1em);
165
+ height: 100%;
166
+ left: 1em;
167
+ position: absolute;
168
+ }
169
+
170
+ .range {
171
+ height: fit-content;
172
+ position: relative;
173
+ display: inline-flex;
174
+ justify-content: center;
175
+ align-items: center;
176
+ }
177
+
178
+ .range input {
179
+ padding: 0;
180
+ height: 0.6em;
181
+ margin: 0px -0.5em;
182
+ appearance: none;
183
+ -webkit-appearance: none;
184
+ outline: none;
185
+ background: transparent;
186
+ }
187
+
188
+ .range i {
189
+ position: absolute;
190
+ left: 0;
191
+ width: 50%;
192
+ height: 100%;
193
+ pointer-events: none;
194
+ background: var(${cssvarValues.input}--true);
195
+ border-top-left-radius: 0;
196
+ border-bottom-left-radius: 0;
197
+ }
198
+
199
+ .range input::-webkit-slider-runnable-track {
200
+ height: 0.6em;
201
+ }
202
+
203
+ .range input::-webkit-slider-thumb {
204
+ z-index: 1;
205
+ appearance: none;
206
+ -webkit-appearance: none;
207
+ position: relative;
208
+ height: 1.2em;
209
+ width: 1.2em;
210
+ margin-top: -0.3em;
211
+ background: var(${cssvarValues.input}--control);
212
+ border-radius: 50%;
213
+ border: solid 0.125em var(${cssvarValues.input}--control-edge);
214
+ box-shadow: 0 0.1em 0.1em var(${cssvar}--shadow);
93
215
  }
94
216
  `,
95
217
  ];
96
- __decorate([
97
- property({ reflect: true })
98
- ], InputElement.prototype, "type", void 0);
99
218
  __decorate([
100
219
  property()
101
- ], InputElement.prototype, "name", void 0);
220
+ ], Input.prototype, "accept", void 0);
102
221
  __decorate([
103
222
  property()
104
- ], InputElement.prototype, "value", void 0);
223
+ ], Input.prototype, "value", void 0);
105
224
  __decorate([
106
- property({ reflect: true })
107
- ], InputElement.prototype, "label", void 0);
225
+ property({ type: Boolean })
226
+ ], Input.prototype, "only", void 0);
108
227
  __decorate([
109
- property()
110
- ], InputElement.prototype, "def", void 0);
228
+ property({ type: Number })
229
+ ], Input.prototype, "min", void 0);
230
+ __decorate([
231
+ property({ type: Number })
232
+ ], Input.prototype, "max", void 0);
233
+ __decorate([
234
+ property({ type: Number })
235
+ ], Input.prototype, "step", void 0);
111
236
  __decorate([
112
- property({ reflect: true })
113
- ], InputElement.prototype, "pla", void 0);
237
+ query("#input")
238
+ ], Input.prototype, "_input", void 0);
114
239
  __decorate([
115
- property({ type: Boolean, reflect: true })
116
- ], InputElement.prototype, "autofocus", void 0);
240
+ query(".range i")
241
+ ], Input.prototype, "_ranged", void 0);
242
+ Input = __decorate([
243
+ define(defineName)
244
+ ], Input);
245
+ export { Input };
246
+ export default Input;
117
247
  //# sourceMappingURL=input.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"input.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["web-components/input/input.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAuB,QAAQ,EAAE,MAAM,eAAe,CAAC;AACnE,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAI5D,MAAM,OAAO,YA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CAAC;IAES,YAAY;QACpB,IAAI,CAAC,iBAAiB,EAAE,CAAC;QACzB,IAAI,CAAC,KAAK,EAAE,CAAC;IACf,CAAC;IAES,WAAW,CAAC,CAAQ;QAC5B,MAAM,MAAM,GAAG,CAAC,CAAC,MAA0B,CAAC;QAC5C,IAAI,MAAM,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC;YACtB,OAAO,MAAM,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC;QAC7B,CAAC;QACD,OAAO,MAAM,CAAC,KAAK,CAAC;IACtB,CAAC;;AA3FM,mBAAM,GAAG;IACd,aAAa,CAAC,MAAM;IACpB,GAAG,CAAA;;;;;;;;gCAQyB,YAAY,CAAC,KAAK;;;KAG7C;CACgB,AAdN,CAcO;AAzBS;IAA5B,QAAQ,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;0CAA0B;AAC1C;IAAX,QAAQ,EAAE;0CAA0B;AACzB;IAAX,QAAQ,EAAE;2CAAiC;AACf;IAA5B,QAAQ,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;2CAAY;AAC5B;IAAX,QAAQ,EAAE;yCAAU;AACQ;IAA5B,QAAQ,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;yCAA0B;AACV;IAA3C,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;+CAAmB","sourcesContent":["import { css, type CSSResultGroup, property } from \"../../deps.js\";\nimport { cssvarValues, GodownElement } from \"../../root.js\";\n\nexport type InputType = \"hidden\" | \"text\" | \"search\" | \"tel\" | \"url\" | \"email\" | \"password\" | \"datetime\" | \"date\" | \"month\" | \"week\" | \"time\" | \"datetime-local\" | \"number\" | \"range\" | \"color\" | \"checkbox\" | \"radio\" | \"file\" | \"image\";\n\nexport class InputElement extends GodownElement {\n @property({ reflect: true }) type: InputType = \"text\";\n @property() name: string = undefined;\n @property() value: string | any = undefined;\n @property({ reflect: true }) label = \"\";\n @property() def = \"\";\n @property({ reflect: true }) pla?: string = undefined;\n @property({ type: Boolean, reflect: true }) autofocus = false;\n\n _input: HTMLInputElement;\n compositing: boolean;\n\n static styles = [\n GodownElement.styles,\n css`\n :host {\n display: flex;\n }\n ::-ms-reveal {\n display: none;\n }\n ::-webkit-calendar-picker-indicator {\n background-color: var(${cssvarValues.input}-true);\n border-radius: 0.1rem;\n }\n `,\n ] as CSSResultGroup;\n\n namevalue(): [string, any] {\n return [this.name, this.value];\n }\n\n nameValue = () => this.namevalue();\n\n reset() {\n this.value = this.def;\n this._input.value = this.def;\n }\n\n protected _handleInput(e: any) {\n e.stopPropagation();\n this.value = e.target.value?.trim();\n if (this.compositing) {\n return;\n }\n this.dispatchEvent(new CustomEvent(\"input\", { detail: this.value, bubbles: true, composed: true }));\n this.dispatchEvent(new CustomEvent(\"change\", { detail: this.value, composed: true }));\n }\n\n protected _handleChange() {\n this.dispatchEvent(new CustomEvent(\"change\", { detail: this.value, composed: true }));\n }\n\n connectedCallback() {\n super.connectedCallback();\n if (!this.def) {\n this.def = this.value || \"\";\n }\n if (!this.value) {\n this.value = this.def;\n }\n this._initName();\n }\n\n protected _initName() {\n if (!this.name) {\n if (this.label || this.type) {\n this.name = this.label || this.type;\n }\n }\n }\n\n protected _compositionCheck() {\n if (this._input) {\n this.addEvent(this._input, \"compositionstart\", () => {\n this.compositing = true;\n });\n this.addEvent(this._input, \"compositionend\", (e: MouseEvent) => {\n this.compositing = false;\n this._handleInput(e);\n });\n }\n }\n\n protected _changeInputType(t: InputType) {\n this._input.type = t;\n }\n\n focus(options?: FocusOptions) {\n this._input?.focus(options);\n }\n\n protected firstUpdated() {\n this._compositionCheck();\n this.reset();\n }\n\n protected targetValue(e: Event): string | any {\n const target = e.target as HTMLInputElement;\n if (target.value.trim) {\n return target.value.trim();\n }\n return target.value;\n }\n}\n"]}
1
+ {"version":3,"file":"input.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["web-components/input/input.ts"],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E,IAAI,EAAE,MAAM,EAAE,CAAC;mCAAU;AAEpB;IAAhB,KAAK,CAAC,QAAQ,CAAC;qCAA0B;AACvB;IAAlB,KAAK,CAAC,UAAU,CAAC;sCAAsB;AA3B7B,KAAK;IADjB,MAAM,CAAC,UAAU,CAAC;GACN,KAAK,CAsNjB;;AAED,eAAe,KAAK,CAAC","sourcesContent":["import { css, type CSSResultGroup, html, property, query } from \"../../.deps.js\";\nimport { define } from \"../../decorators/define.js\";\nimport { htmlSlot, type HTMLTemplate } from \"../../lib/templates.js\";\nimport { GodownInput } from \"../../supers/input.js\";\nimport { cssvar, cssvarValues } from \"../../supers/root.js\";\n\nconst defineName = \"input\";\n\n/**\n * {@linkcode Input }.\n */\n@define(defineName)\nexport class Input extends GodownInput {\n /**\n * Input sccept.\n */\n @property() accept = undefined;\n /**\n * Value.\n */\n @property() value: string | File | FileList = undefined;\n /**\n * Only single files are allowed to be selected.\n */\n @property({ type: Boolean }) only = false;\n /**\n * Input min.\n */\n @property({ type: Number }) min = 0;\n /**\n * Input max.\n */\n @property({ type: Number }) max = 100;\n /**\n * Input step.\n */\n @property({ type: Number }) step = 1;\n\n @query(\"#input\") _input: HTMLInputElement;\n @query(\".range i\") _ranged: HTMLElement;\n\n static styles = [\n GodownInput.styles,\n css`\n :host {\n width: var(${cssvarValues.input}--width);\n height: var(${cssvarValues.input}--height);\n background: var(${cssvarValues.input}--background);\n margin: var(${cssvarValues.input}--outline-width);\n outline: var(${cssvarValues.input}--outline);\n border-radius: var(${cssvarValues.input}--radius);\n }\n\n input[type=\"file\"] {\n display: none;\n }\n\n label,\n div {\n width: 100%;\n display: flex;\n align-items: center;\n }\n\n * {\n border-radius: inherit;\n cursor: inherit;\n }\n\n input {\n box-sizing: border-box;\n height: 100%;\n width: 100%;\n margin: 0;\n color: inherit;\n background: transparent;\n padding: 0 0.25em;\n border-radius: 0.25em;\n }\n `,\n css`\n :host([type=\"range\"]) {\n height: auto !important;\n margin: 0.3em 0;\n background: var(${cssvarValues.input}--false);\n border-radius: 2em;\n }\n\n .range b:nth-of-type(1) {\n width: 1em;\n left: 0;\n background: var(${cssvarValues.input}--true);\n border-top-right-radius: 0;\n border-bottom-right-radius: 0;\n }\n\n .range b {\n pointer-events: none;\n width: calc(100% - 1em);\n height: 100%;\n left: 1em;\n position: absolute;\n }\n\n .range {\n height: fit-content;\n position: relative;\n display: inline-flex;\n justify-content: center;\n align-items: center;\n }\n\n .range input {\n padding: 0;\n height: 0.6em;\n margin: 0px -0.5em;\n appearance: none;\n -webkit-appearance: none;\n outline: none;\n background: transparent;\n }\n\n .range i {\n position: absolute;\n left: 0;\n width: 50%;\n height: 100%;\n pointer-events: none;\n background: var(${cssvarValues.input}--true);\n border-top-left-radius: 0;\n border-bottom-left-radius: 0;\n }\n\n .range input::-webkit-slider-runnable-track {\n height: 0.6em;\n }\n\n .range input::-webkit-slider-thumb {\n z-index: 1;\n appearance: none;\n -webkit-appearance: none;\n position: relative;\n height: 1.2em;\n width: 1.2em;\n margin-top: -0.3em;\n background: var(${cssvarValues.input}--control);\n border-radius: 50%;\n border: solid 0.125em var(${cssvarValues.input}--control-edge);\n box-shadow: 0 0.1em 0.1em var(${cssvar}--shadow);\n }\n `,\n ] as CSSResultGroup;\n\n protected render(): HTMLTemplate {\n if (this.type === \"range\") {\n return html`<div class=\"range\">\n <input id=\"input\" type=\"range\" min=\"${this.min}\" max=\"${this.max}\" step=\"${this.step}\" @input=\"${this._handleRange}\" @change=\"${this._handleRange}\" />\n <b></b>\n <b>\n <i></i>\n </b>\n </div>`;\n }\n return html`<label for=\"input\"> ${htmlSlot(\"pre\")} ${this._typeSwitcher()} ${htmlSlot(\"suf\")} </label>`;\n }\n\n connectedCallback() {\n super.connectedCallback();\n if (this.type === \"file\") {\n this.value = null;\n } else {\n if (!this.def) {\n this.def = (this.value as string) || \"\";\n }\n if (!this.value) {\n this.value = this.def;\n }\n }\n this._initName();\n }\n\n protected firstUpdated() {\n super.firstUpdated();\n if (this.type === \"range\") {\n this._ranged.style.width = 100 * (parseInt(this.value as string) / (this.max - this.min)) + \"%\";\n }\n }\n\n protected _handleRange(e: any | Event) {\n this.value = e.target.value;\n this._ranged.style.width = (100 * parseInt(e.target.value)) / (this.max - this.min) + \"%\";\n this.dispatchEvent(new CustomEvent(\"input\", { detail: this.value }));\n }\n\n protected _handleFile(e: any | Event) {\n this.value = !this.only ? e.target.files : e.target.files[0];\n this.dispatchEvent(new CustomEvent(\"change\", { detail: this.value }));\n }\n\n reset() {\n if (this.type === \"file\") {\n this.value = null;\n return;\n }\n if (this.type === \"range\") {\n this._input.value = this.def || ((this.max - this.min) / 2).toString();\n this.value = this._input.value;\n this._ranged.style.width = 100 * (parseInt(this.value) / (this.max - this.min)) + \"%\";\n } else {\n this._input.value = this.def.toString();\n this.value = this.def;\n }\n }\n\n protected _typeSwitcher(): HTMLTemplate {\n switch (this.type) {\n case \"file\":\n return html`<input id=\"input\" class=\"input\" type=\"file\" accept=\"${this.accept}\" ?multiple=\"${!this.only}\" @change=\"${this._handleFile}\" />${htmlSlot()}`;\n\n case \"number\":\n return html`<input .value=\"${this.value}\" ?autofocus=\"${this.autofocus}\" id=\"input\" class=\"input\" type=\"number\" placeholder=\"${this.pla}\" min=\"${this.min}\" max=\"${this.max}\" @input=\"${this._handleInput}\" @change=\"${this._handleChange}\" />`;\n\n default:\n return html`<input .value=\"${this.value}\" ?autofocus=\"${this.autofocus}\" id=\"input\" class=\"input\" type=\"${this.type}\" placeholder=\"${this.pla}\" @input=\"${this._handleInput}\" @change=\"${this._handleChange}\" />`;\n }\n }\n}\n\nexport default Input;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"base-input\": Input;\n \"g-input\": Input;\n }\n}\n"]}
@@ -1,14 +1,14 @@
1
- import { type CSSResultGroup } from "../../deps.js";
1
+ import { type CSSResultGroup } from "../../.deps.js";
2
2
  import { type HTMLTemplate } from "../../lib/templates.js";
3
- import { InputElement } from "./input.js";
3
+ import { GodownInput } from "../../supers/input.js";
4
4
  /**
5
- * LabelInput renders label and input.
5
+ * {@linkcode LabelInput } renders label and input.
6
6
  *
7
7
  * When there is a label, the layout will be adjusted according to the width of the screen.
8
8
  *
9
9
  * Otherwise it behaves similarly to the `BaseInput`.
10
10
  */
11
- export declare class LabelInput extends InputElement {
11
+ export declare class LabelInput extends GodownInput {
12
12
  /**
13
13
  * Conditions for adjust layout.
14
14
  */
@@ -23,6 +23,7 @@ export default LabelInput;
23
23
  declare global {
24
24
  interface HTMLElementTagNameMap {
25
25
  "label-input": LabelInput;
26
+ "g-label-input": LabelInput;
26
27
  }
27
28
  }
28
29
  //# sourceMappingURL=label-input.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"label-input.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["web-components/input/label-input.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,cAAc,EAAyB,MAAM,eAAe,CAAC;AAChF,OAAO,EAAuB,KAAK,YAAY,EAAU,MAAM,wBAAwB,CAAC;AAExF,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AA+B1C;;;;;;GAMG;AACH,qBACa,UAAW,SAAQ,YAAY;IAC1C;;OAEG;IACS,MAAM,SAAW;IAEb,MAAM,EAAE,gBAAgB,CAAC;IAEzC,MAAM,CAAC,MAAM,iBA4DO;IAEpB,SAAS,CAAC,MAAM,IAAI,YAAY,EAAE;IAmBlC,OAAO,CAAC,SAAS;IAkBjB,SAAS,CAAC,iBAAiB;CAO5B;AAED,eAAe,UAAU,CAAC;AAE1B,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,aAAa,EAAE,UAAU,CAAC;KAC3B;CACF"}
1
+ {"version":3,"file":"label-input.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["web-components/input/label-input.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,cAAc,EAAyB,MAAM,gBAAgB,CAAC;AAEjF,OAAO,EAAuB,KAAK,YAAY,EAAU,MAAM,wBAAwB,CAAC;AACxF,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAgCpD;;;;;;GAMG;AACH,qBACa,UAAW,SAAQ,WAAW;IACzC;;OAEG;IACS,MAAM,SAAW;IAEb,MAAM,EAAE,gBAAgB,CAAC;IAEzC,MAAM,CAAC,MAAM,iBA4DO;IAEpB,SAAS,CAAC,MAAM,IAAI,YAAY,EAAE;IAmBlC,OAAO,CAAC,SAAS;IAkBjB,SAAS,CAAC,iBAAiB;CAO5B;AAED,eAAe,UAAU,CAAC;AAE1B,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,aAAa,EAAE,UAAU,CAAC;QAC1B,eAAe,EAAE,UAAU,CAAC;KAC7B;CACF"}
@@ -1,8 +1,9 @@
1
1
  import { __decorate } from "tslib";
2
- import { css, html, property, query } from "../../deps.js";
2
+ import { css, html, property, query } from "../../.deps.js";
3
+ import { define } from "../../decorators/define.js";
3
4
  import { htmlSlot, htmlStyle, svgEye } from "../../lib/templates.js";
4
- import { cssvarValues, define } from "../../root.js";
5
- import { InputElement } from "./input.js";
5
+ import { GodownInput } from "../../supers/input.js";
6
+ import { cssvarValues } from "../../supers/root.js";
6
7
  const PASSWORD = "password";
7
8
  const styleInMedia = css `
8
9
  label[for] {
@@ -28,13 +29,13 @@ const styleWithLabel = css `
28
29
  `;
29
30
  const defineName = "label-input";
30
31
  /**
31
- * LabelInput renders label and input.
32
+ * {@linkcode LabelInput } renders label and input.
32
33
  *
33
34
  * When there is a label, the layout will be adjusted according to the width of the screen.
34
35
  *
35
36
  * Otherwise it behaves similarly to the `BaseInput`.
36
37
  */
37
- let LabelInput = class LabelInput extends InputElement {
38
+ let LabelInput = class LabelInput extends GodownInput {
38
39
  constructor() {
39
40
  super(...arguments);
40
41
  /**
@@ -88,7 +89,7 @@ let LabelInput = class LabelInput extends InputElement {
88
89
  }
89
90
  };
90
91
  LabelInput.styles = [
91
- InputElement.styles,
92
+ GodownInput.styles,
92
93
  css `
93
94
  :host {
94
95
  margin: var(${cssvarValues.input}--outline-width);
@@ -1 +1 @@
1
- {"version":3,"file":"label-input.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["web-components/input/label-input.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAuB,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAChF,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAqB,MAAM,EAAE,MAAM,wBAAwB,CAAC;AACxF,OAAO,EAAE,YAAY,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AACrD,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAE1C,MAAM,QAAQ,GAAG,UAAU,CAAC;AAE5B,MAAM,YAAY,GAAG,GAAG,CAAA;;;;;;;;iBAQP,YAAY,CAAC,KAAK;;;CAGlC,CAAC;AAEF,MAAM,YAAY,GAAG,GAAG,CAAA;;iBAEP,YAAY,CAAC,KAAK;;CAElC,CAAC;AAEF,MAAM,cAAc,GAAG,GAAG,CAAA;;sBAEJ,YAAY,CAAC,KAAK;;CAEvC,CAAC;AAEF,MAAM,UAAU,GAAG,aAAa,CAAC;AAEjC;;;;;;GAMG;AAEI,IAAM,UAAU,GAAhB,MAAM,UAAW,SAAQ,YAAY;IAArC;;QACL;;WAEG;QACS,WAAM,GAAG,OAAO,CAAC;IA8G/B,CAAC;IA5CW,MAAM;QACd,MAAM,MAAM,GAAG,IAAI,CAAA;WACZ,QAAQ,CAAC,KAAK,CAAC;uBACH,IAAI,CAAC,KAAK,iBAAiB,IAAI,CAAC,SAAS,SAAS,IAAI,CAAC,IAAI,WAAW,IAAI,CAAC,IAAI,kBAAkB,IAAI,CAAC,GAAG,YAAY,IAAI,CAAC,IAAI,aAAa,IAAI,CAAC,YAAY,cAAc,IAAI,CAAC,aAAa;QAC3M,IAAI,CAAC,SAAS,EAAE;gBACR,CAAC;QACb,IAAI,IAAI,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;;;;;;;;;;;;;uBA4BxB,YAAY,CAAC,KAAK;;;;;;;;;;;;;;;;;;gCAkBT,YAAY,CAAC,KAAK;;;;sBAI5B,YAAY,CAAC,KAAK;qBACnB,YAAY,CAAC,KAAK;yBACd,YAAY,CAAC,KAAK;;KAEtC;CACgB,AA5DN,CA4DO;AAhER;IAAX,QAAQ,EAAE;0CAAkB;AAEb;IAAf,KAAK,CAAC,OAAO,CAAC;0CAA0B;AAN9B,UAAU;IADtB,MAAM,CAAC,UAAU,CAAC;GACN,UAAU,CAkHtB;;AAED,eAAe,UAAU,CAAC","sourcesContent":["import { css, type CSSResultGroup, html, property, query } from \"../../deps.js\";\nimport { htmlSlot, htmlStyle, type HTMLTemplate, svgEye } from \"../../lib/templates.js\";\nimport { cssvarValues, define } from \"../../root.js\";\nimport { InputElement } from \"./input.js\";\n\nconst PASSWORD = \"password\";\n\nconst styleInMedia = css`\n label[for] {\n justify-content: flex-start;\n flex-direction: column;\n align-items: inherit;\n width: fit-content;\n }\n :host {\n width: var(${cssvarValues.input}--width);\n margin: auto;\n }\n`;\n\nconst styleNoLabel = css`\n :host {\n width: var(${cssvarValues.input}--width);\n }\n`;\n\nconst styleWithLabel = css`\n :host {\n width: calc(var(${cssvarValues.input}--width) * 2);\n }\n`;\n\nconst defineName = \"label-input\";\n\n/**\n * LabelInput renders label and input.\n *\n * When there is a label, the layout will be adjusted according to the width of the screen.\n *\n * Otherwise it behaves similarly to the `BaseInput`.\n */\n@define(defineName)\nexport class LabelInput extends InputElement {\n /**\n * Conditions for adjust layout.\n */\n @property() mobile = \"540px\";\n\n @query(\"input\") _input: HTMLInputElement;\n\n static styles = [\n InputElement.styles,\n css`\n :host {\n margin: var(${cssvarValues.input}--outline-width);\n border-radius: var(${cssvarValues.input}--radius);\n }\n\n label {\n width: 100%;\n margin: auto;\n box-sizing: border-box;\n height: fit-content;\n display: flex;\n justify-content: space-between;\n align-items: center;\n border-radius: inherit;\n }\n\n span {\n white-space: nowrap;\n }\n\n input {\n padding: 0 0.25em;\n background-color: transparent;\n border-radius: inherit;\n flex: 1;\n width: 100%;\n height: inherit;\n }\n\n fieldset:focus-within {\n outline: var(${cssvarValues.input}--outline);\n }\n\n i {\n margin: auto;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n\n i > svg {\n height: 1em;\n width: 1em;\n margin: 0.25em;\n }\n\n fieldset {\n position: relative;\n background-color: var(${cssvarValues.input}--background);\n display: flex;\n align-items: center;\n border-radius: inherit;\n height: var(${cssvarValues.input}--height);\n width: var(${cssvarValues.input}--width);\n min-width: var(${cssvarValues.input}--width);\n }\n `,\n ] as CSSResultGroup;\n\n protected render(): HTMLTemplate[] {\n const result = html`<fieldset>\n <i>${htmlSlot(\"pre\")}</i>\n <input .value=\"${this.value}\" ?autofocus=\"${this.autofocus}\" id=\"${this.name}\" type=\"${this.type}\" placeholder=\"${this.pla}\" class=\"${this.type}\" @input=\"${this._handleInput}\" @change=\"${this._handleChange}\" />\n ${this.renderSuf()}\n </fieldset>`;\n if (this.label) {\n const style = this.mobile && `${styleWithLabel}@media (max-width: ${this.mobile}){${styleInMedia}}`;\n return [\n html`<label for=\"${this.name}\">\n <span>${this.label}${htmlSlot()}</span>\n ${result}\n </label>`,\n htmlStyle(style),\n ];\n }\n return [result, htmlStyle(styleNoLabel.toString())];\n }\n\n private renderSuf(): HTMLTemplate {\n if (this.type === PASSWORD) {\n return html`<i\n @mousedown=\"${this._passwordSwitcher}\"\n @mouseup=\"${() => {\n this._changeInputType(PASSWORD);\n }}\"\n @mouseleave=\"${() => {\n this._changeInputType(PASSWORD);\n }}\"\n >\n ${htmlSlot(\"suf\", svgEye(), this)}\n </i>`;\n } else {\n return html`<i>${htmlSlot(\"suf\")}</i>`;\n }\n }\n\n protected _passwordSwitcher() {\n if (this._input.type === PASSWORD) {\n this._changeInputType(\"text\");\n } else {\n this._changeInputType(PASSWORD);\n }\n }\n}\n\nexport default LabelInput;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"label-input\": LabelInput;\n }\n}\n"]}
1
+ {"version":3,"file":"label-input.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["web-components/input/label-input.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAuB,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AACjF,OAAO,EAAE,MAAM,EAAE,MAAM,4BAA4B,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAqB,MAAM,EAAE,MAAM,wBAAwB,CAAC;AACxF,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAEpD,MAAM,QAAQ,GAAG,UAAU,CAAC;AAE5B,MAAM,YAAY,GAAG,GAAG,CAAA;;;;;;;;iBAQP,YAAY,CAAC,KAAK;;;CAGlC,CAAC;AAEF,MAAM,YAAY,GAAG,GAAG,CAAA;;iBAEP,YAAY,CAAC,KAAK;;CAElC,CAAC;AAEF,MAAM,cAAc,GAAG,GAAG,CAAA;;sBAEJ,YAAY,CAAC,KAAK;;CAEvC,CAAC;AAEF,MAAM,UAAU,GAAG,aAAa,CAAC;AAEjC;;;;;;GAMG;AAEI,IAAM,UAAU,GAAhB,MAAM,UAAW,SAAQ,WAAW;IAApC;;QACL;;WAEG;QACS,WAAM,GAAG,OAAO,CAAC;IA8G/B,CAAC;IA5CW,MAAM;QACd,MAAM,MAAM,GAAG,IAAI,CAAA;WACZ,QAAQ,CAAC,KAAK,CAAC;uBACH,IAAI,CAAC,KAAK,iBAAiB,IAAI,CAAC,SAAS,SAAS,IAAI,CAAC,IAAI,WAAW,IAAI,CAAC,IAAI,kBAAkB,IAAI,CAAC,GAAG,YAAY,IAAI,CAAC,IAAI,aAAa,IAAI,CAAC,YAAY,cAAc,IAAI,CAAC,aAAa;QAC3M,IAAI,CAAC,SAAS,EAAE;gBACR,CAAC;QACb,IAAI,IAAI,CAAC,KAAK,EA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;uBA4BxB,YAAY,CAAC,KAAK;;;;;;;;;;;;;;;;;;gCAkBT,YAAY,CAAC,KAAK;;;;sBAI5B,YAAY,CAAC,KAAK;qBACnB,YAAY,CAAC,KAAK;yBACd,YAAY,CAAC,KAAK;;KAEtC;CACgB,AA5DN,CA4DO;AAhER;IAAX,QAAQ,EAAE;0CAAkB;AAEb;IAAf,KAAK,CAAC,OAAO,CAAC;0CAA0B;AAN9B,UAAU;IADtB,MAAM,CAAC,UAAU,CAAC;GACN,UAAU,CAkHtB;;AAED,eAAe,UAAU,CAAC","sourcesContent":["import { css, type CSSResultGroup, html, property, query } from \"../../.deps.js\";\nimport { define } from \"../../decorators/define.js\";\nimport { htmlSlot, htmlStyle, type HTMLTemplate, svgEye } from \"../../lib/templates.js\";\nimport { GodownInput } from \"../../supers/input.js\";\nimport { cssvarValues } from \"../../supers/root.js\";\n\nconst PASSWORD = \"password\";\n\nconst styleInMedia = css`\n label[for] {\n justify-content: flex-start;\n flex-direction: column;\n align-items: inherit;\n width: fit-content;\n }\n :host {\n width: var(${cssvarValues.input}--width);\n margin: auto;\n }\n`;\n\nconst styleNoLabel = css`\n :host {\n width: var(${cssvarValues.input}--width);\n }\n`;\n\nconst styleWithLabel = css`\n :host {\n width: calc(var(${cssvarValues.input}--width) * 2);\n }\n`;\n\nconst defineName = \"label-input\";\n\n/**\n * {@linkcode LabelInput } renders label and input.\n *\n * When there is a label, the layout will be adjusted according to the width of the screen.\n *\n * Otherwise it behaves similarly to the `BaseInput`.\n */\n@define(defineName)\nexport class LabelInput extends GodownInput {\n /**\n * Conditions for adjust layout.\n */\n @property() mobile = \"540px\";\n\n @query(\"input\") _input: HTMLInputElement;\n\n static styles = [\n GodownInput.styles,\n css`\n :host {\n margin: var(${cssvarValues.input}--outline-width);\n border-radius: var(${cssvarValues.input}--radius);\n }\n\n label {\n width: 100%;\n margin: auto;\n box-sizing: border-box;\n height: fit-content;\n display: flex;\n justify-content: space-between;\n align-items: center;\n border-radius: inherit;\n }\n\n span {\n white-space: nowrap;\n }\n\n input {\n padding: 0 0.25em;\n background-color: transparent;\n border-radius: inherit;\n flex: 1;\n width: 100%;\n height: inherit;\n }\n\n fieldset:focus-within {\n outline: var(${cssvarValues.input}--outline);\n }\n\n i {\n margin: auto;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n\n i > svg {\n height: 1em;\n width: 1em;\n margin: 0.25em;\n }\n\n fieldset {\n position: relative;\n background-color: var(${cssvarValues.input}--background);\n display: flex;\n align-items: center;\n border-radius: inherit;\n height: var(${cssvarValues.input}--height);\n width: var(${cssvarValues.input}--width);\n min-width: var(${cssvarValues.input}--width);\n }\n `,\n ] as CSSResultGroup;\n\n protected render(): HTMLTemplate[] {\n const result = html`<fieldset>\n <i>${htmlSlot(\"pre\")}</i>\n <input .value=\"${this.value}\" ?autofocus=\"${this.autofocus}\" id=\"${this.name}\" type=\"${this.type}\" placeholder=\"${this.pla}\" class=\"${this.type}\" @input=\"${this._handleInput}\" @change=\"${this._handleChange}\" />\n ${this.renderSuf()}\n </fieldset>`;\n if (this.label) {\n const style = this.mobile && `${styleWithLabel}@media (max-width: ${this.mobile}){${styleInMedia}}`;\n return [\n html`<label for=\"${this.name}\">\n <span>${this.label}${htmlSlot()}</span>\n ${result}\n </label>`,\n htmlStyle(style),\n ];\n }\n return [result, htmlStyle(styleNoLabel.toString())];\n }\n\n private renderSuf(): HTMLTemplate {\n if (this.type === PASSWORD) {\n return html`<i\n @mousedown=\"${this._passwordSwitcher}\"\n @mouseup=\"${() => {\n this._changeInputType(PASSWORD);\n }}\"\n @mouseleave=\"${() => {\n this._changeInputType(PASSWORD);\n }}\"\n >\n ${htmlSlot(\"suf\", svgEye(), this)}\n </i>`;\n } else {\n return html`<i>${htmlSlot(\"suf\")}</i>`;\n }\n }\n\n protected _passwordSwitcher() {\n if (this._input.type === PASSWORD) {\n this._changeInputType(\"text\");\n } else {\n this._changeInputType(PASSWORD);\n }\n }\n}\n\nexport default LabelInput;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"label-input\": LabelInput;\n \"g-label-input\": LabelInput;\n }\n}\n"]}
@@ -1,10 +1,10 @@
1
- import { type CSSResultGroup } from "../../deps.js";
1
+ import { type CSSResultGroup } from "../../.deps.js";
2
2
  import { type HTMLTemplate } from "../../lib/templates.js";
3
- import { InputElement } from "./input.js";
3
+ import { GodownInput } from "../../supers/input.js";
4
4
  /**
5
- * SearchInput used for search behavior.
5
+ * {@linkcode SearchInput} used for search behavior.
6
6
  */
7
- export declare class SearchInput extends InputElement {
7
+ export declare class SearchInput extends GodownInput {
8
8
  /**
9
9
  * Query selectors.
10
10
  */
@@ -44,6 +44,7 @@ export default SearchInput;
44
44
  declare global {
45
45
  interface HTMLElementTagNameMap {
46
46
  "search-input": SearchInput;
47
+ "g-search-input": SearchInput;
47
48
  }
48
49
  }
49
50
  //# sourceMappingURL=search-input.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"search-input.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["web-components/input/search-input.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,cAAc,EAAyB,MAAM,eAAe,CAAC;AAChF,OAAO,EAAY,KAAK,YAAY,EAAa,MAAM,wBAAwB,CAAC;AAEhF,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAM1C;;GAEG;AACH,qBACa,WAAY,SAAQ,YAAY;IAC3C;;OAEG;IACS,KAAK,SAAM;IACvB;;OAEG;IACS,MAAM,SAAM;IACxB;;OAEG;IAC0B,KAAK,UAAS;IAC3C;;OAEG;IACyC,KAAK,UAAS;IAC1D;;OAEG;IACS,MAAM,SAAM;IACxB;;OAEG;IACS,MAAM,EAAE,KAAK,GAAG,MAAM,CAAS;IAC3C;;OAEG;IACS,IAAI,SAAO;IAEP,MAAM,EAAG,gBAAgB,CAAC;IAE1C,MAAM,CAAC,MAAM,iBAsFO;IAEpB,SAAS,CAAC,MAAM,IAAI,YAAY;IAYhC,SAAS,CAAC,aAAa,CAAC,CAAC,EAAE,KAAK;IAOhC,SAAS,CAAC,YAAY,CAAC,CAAC,EAAE,KAAK;IAiB/B,cAAc,CAAC,CAAC,EAAE,MAAM;CAezB;AAED,eAAe,WAAW,CAAC;AAE3B,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,cAAc,EAAE,WAAW,CAAC;KAC7B;CACF"}
1
+ {"version":3,"file":"search-input.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["web-components/input/search-input.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,cAAc,EAAyB,MAAM,gBAAgB,CAAC;AAEjF,OAAO,EAAY,KAAK,YAAY,EAAa,MAAM,wBAAwB,CAAC;AAChF,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAOpD;;GAEG;AACH,qBACa,WAAY,SAAQ,WAAW;IAC1C;;OAEG;IACS,KAAK,SAAM;IACvB;;OAEG;IACS,MAAM,SAAM;IACxB;;OAEG;IAC0B,KAAK,UAAS;IAC3C;;OAEG;IACyC,KAAK,UAAS;IAC1D;;OAEG;IACS,MAAM,SAAM;IACxB;;OAEG;IACS,MAAM,EAAE,KAAK,GAAG,MAAM,CAAS;IAC3C;;OAEG;IACS,IAAI,SAAO;IAEP,MAAM,EAAG,gBAAgB,CAAC;IAE1C,MAAM,CAAC,MAAM,iBAsFO;IAEpB,SAAS,CAAC,MAAM,IAAI,YAAY;IAYhC,SAAS,CAAC,aAAa,CAAC,CAAC,EAAE,KAAK;IAOhC,SAAS,CAAC,YAAY,CAAC,CAAC,EAAE,KAAK;IAiB/B,cAAc,CAAC,CAAC,EAAE,MAAM;CAezB;AAED,eAAe,WAAW,CAAC;AAE3B,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,cAAc,EAAE,WAAW,CAAC;QAC5B,gBAAgB,EAAE,WAAW,CAAC;KAC/B;CACF"}
@@ -1,14 +1,15 @@
1
1
  import { __decorate } from "tslib";
2
- import { css, html, property, query } from "../../deps.js";
2
+ import { css, html, property, query } from "../../.deps.js";
3
+ import { define } from "../../decorators/define.js";
3
4
  import { htmlSlot, svgSearch } from "../../lib/templates.js";
4
- import { createScope, cssvarValues, define } from "../../root.js";
5
- import { InputElement } from "./input.js";
5
+ import { GodownInput } from "../../supers/input.js";
6
+ import { createScope, cssvarValues } from "../../supers/root.js";
6
7
  const defineName = "search-input";
7
8
  const cssScope = createScope(defineName);
8
9
  /**
9
- * SearchInput used for search behavior.
10
+ * {@linkcode SearchInput} used for search behavior.
10
11
  */
11
- let SearchInput = class SearchInput extends InputElement {
12
+ let SearchInput = class SearchInput extends GodownInput {
12
13
  constructor() {
13
14
  super(...arguments);
14
15
  /**
@@ -90,7 +91,7 @@ let SearchInput = class SearchInput extends InputElement {
90
91
  }
91
92
  };
92
93
  SearchInput.styles = [
93
- InputElement.styles,
94
+ GodownInput.styles,
94
95
  css `
95
96
  :host {
96
97
  ${cssScope}--width:var(${cssvarValues.input}--width);