godown 2.7.5 → 2.7.6
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.
- package/README.md +18 -45
- package/{.deps.d.ts → _deps.d.ts} +1 -2
- package/{.deps.d.ts.map → _deps.d.ts.map} +1 -1
- package/{.deps.js → _deps.js} +1 -2
- package/_deps.js.map +1 -0
- package/alert.d.ts +8 -1
- package/alert.d.ts.map +1 -1
- package/alert.js +4 -1
- package/alert.js.map +1 -1
- package/avatar-group.d.ts +8 -1
- package/avatar-group.d.ts.map +1 -1
- package/avatar-group.js +4 -1
- package/avatar-group.js.map +1 -1
- package/avatar.d.ts +8 -1
- package/avatar.d.ts.map +1 -1
- package/avatar.js +4 -1
- package/avatar.js.map +1 -1
- package/button.d.ts +8 -1
- package/button.d.ts.map +1 -1
- package/button.js +4 -1
- package/button.js.map +1 -1
- package/card.d.ts +8 -1
- package/card.d.ts.map +1 -1
- package/card.js +4 -1
- package/card.js.map +1 -1
- package/carousel.d.ts +8 -1
- package/carousel.d.ts.map +1 -1
- package/carousel.js +4 -1
- package/carousel.js.map +1 -1
- package/components.json +194 -0
- package/conf.d.ts +6 -75
- package/conf.d.ts.map +1 -1
- package/conf.js +8 -34
- package/conf.js.map +1 -1
- package/decorators/godown.d.ts +4 -0
- package/decorators/godown.d.ts.map +1 -0
- package/decorators/godown.js +9 -0
- package/decorators/godown.js.map +1 -0
- package/decorators/part.d.ts +7 -0
- package/decorators/part.d.ts.map +1 -0
- package/decorators/part.js +8 -0
- package/decorators/part.js.map +1 -0
- package/decorators/styles.d.ts +3 -0
- package/decorators/styles.d.ts.map +1 -0
- package/decorators/styles.js +8 -0
- package/decorators/styles.js.map +1 -0
- package/details.d.ts +8 -1
- package/details.d.ts.map +1 -1
- package/details.js +4 -1
- package/details.js.map +1 -1
- package/dialog.d.ts +8 -1
- package/dialog.d.ts.map +1 -1
- package/dialog.js +4 -1
- package/dialog.js.map +1 -1
- package/divider.d.ts +8 -1
- package/divider.d.ts.map +1 -1
- package/divider.js +4 -1
- package/divider.js.map +1 -1
- package/dragbox.d.ts +8 -1
- package/dragbox.d.ts.map +1 -1
- package/dragbox.js +4 -1
- package/dragbox.js.map +1 -1
- package/flex-flow.d.ts +8 -1
- package/flex-flow.d.ts.map +1 -1
- package/flex-flow.js +4 -1
- package/flex-flow.js.map +1 -1
- package/form.d.ts +8 -1
- package/form.d.ts.map +1 -1
- package/form.js +4 -1
- package/form.js.map +1 -1
- package/grid-flow.d.ts +9 -0
- package/grid-flow.d.ts.map +1 -0
- package/grid-flow.js +5 -0
- package/grid-flow.js.map +1 -0
- package/index.d.ts +32 -3
- package/index.d.ts.map +1 -1
- package/index.js +32 -3
- package/index.js.map +1 -1
- package/input.d.ts +8 -1
- package/input.d.ts.map +1 -1
- package/input.js +4 -1
- package/input.js.map +1 -1
- package/label-input.d.ts +8 -1
- package/label-input.d.ts.map +1 -1
- package/label-input.js +4 -1
- package/label-input.js.map +1 -1
- package/layout.d.ts +9 -0
- package/layout.d.ts.map +1 -0
- package/layout.js +5 -0
- package/layout.js.map +1 -0
- package/lib/css.d.ts +13 -0
- package/lib/css.d.ts.map +1 -0
- package/lib/css.js +29 -0
- package/lib/css.js.map +1 -0
- package/lib/directives.d.ts +16 -20
- package/lib/directives.d.ts.map +1 -1
- package/lib/directives.js +33 -31
- package/lib/directives.js.map +1 -1
- package/lib/event-coll.d.ts +13 -0
- package/lib/event-coll.d.ts.map +1 -0
- package/lib/event-coll.js +45 -0
- package/lib/event-coll.js.map +1 -0
- package/lib/{templates.d.ts → icons.d.ts} +1 -17
- package/lib/icons.d.ts.map +1 -0
- package/lib/icons.js +73 -0
- package/lib/icons.js.map +1 -0
- package/lib/jsx.d.ts +4 -0
- package/lib/jsx.d.ts.map +1 -0
- package/lib/jsx.js +52 -0
- package/lib/jsx.js.map +1 -0
- package/lib/route-tree.d.ts +5 -5
- package/lib/route-tree.js +5 -5
- package/lib/route-tree.js.map +1 -1
- package/lib/utils.d.ts +6 -46
- package/lib/utils.d.ts.map +1 -1
- package/lib/utils.js +25 -110
- package/lib/utils.js.map +1 -1
- package/link.d.ts +9 -0
- package/link.d.ts.map +1 -0
- package/link.js +5 -0
- package/link.js.map +1 -0
- package/overbreath.d.ts +8 -1
- package/overbreath.d.ts.map +1 -1
- package/overbreath.js +4 -1
- package/overbreath.js.map +1 -1
- package/package.json +18 -23
- package/progress.d.ts +8 -1
- package/progress.d.ts.map +1 -1
- package/progress.js +4 -1
- package/progress.js.map +1 -1
- package/proto/godown-config.d.ts +41 -0
- package/proto/godown-config.d.ts.map +1 -0
- package/proto/godown-config.js +27 -0
- package/proto/godown-config.js.map +1 -0
- package/{godown-element.d.ts → proto/godown-element.d.ts} +48 -16
- package/proto/godown-element.d.ts.map +1 -0
- package/{godown-element.js → proto/godown-element.js} +82 -26
- package/proto/godown-element.js.map +1 -0
- package/proto/super-a.d.ts +30 -0
- package/proto/super-a.d.ts.map +1 -0
- package/proto/super-a.js +141 -0
- package/proto/super-a.js.map +1 -0
- package/proto/super-input.d.ts +44 -0
- package/proto/super-input.d.ts.map +1 -0
- package/proto/super-input.js +119 -0
- package/proto/super-input.js.map +1 -0
- package/proto/super-openable.d.ts +23 -0
- package/proto/super-openable.d.ts.map +1 -0
- package/proto/super-openable.js +43 -0
- package/proto/super-openable.js.map +1 -0
- package/range-input.d.ts +9 -0
- package/range-input.d.ts.map +1 -0
- package/range-input.js +5 -0
- package/range-input.js.map +1 -0
- package/react/create.d.ts.map +1 -1
- package/react/create.js +4 -1
- package/react/create.js.map +1 -1
- package/react/index.d.ts +64 -34
- package/react/index.d.ts.map +1 -1
- package/react/index.js +78 -51
- package/react/index.js.map +1 -1
- package/rotate.d.ts +9 -0
- package/rotate.d.ts.map +1 -0
- package/rotate.js +5 -0
- package/rotate.js.map +1 -0
- package/router-link.d.ts +9 -0
- package/router-link.d.ts.map +1 -0
- package/router-link.js +5 -0
- package/router-link.js.map +1 -0
- package/router.d.ts +8 -1
- package/router.d.ts.map +1 -1
- package/router.js +4 -1
- package/router.js.map +1 -1
- package/search-input.d.ts +8 -1
- package/search-input.d.ts.map +1 -1
- package/search-input.js +4 -1
- package/search-input.js.map +1 -1
- package/select-input.d.ts +8 -1
- package/select-input.d.ts.map +1 -1
- package/select-input.js +4 -1
- package/select-input.js.map +1 -1
- package/skeleton.d.ts +8 -1
- package/skeleton.d.ts.map +1 -1
- package/skeleton.js +4 -1
- package/skeleton.js.map +1 -1
- package/split-input.d.ts +8 -1
- package/split-input.d.ts.map +1 -1
- package/split-input.js +4 -1
- package/split-input.js.map +1 -1
- package/styles/colors/presets.d.ts +13 -0
- package/styles/colors/presets.d.ts.map +1 -0
- package/styles/colors/presets.js +6 -0
- package/styles/colors/presets.js.map +1 -0
- package/styles/colors/presetsRGB.d.ts +16 -0
- package/styles/colors/presetsRGB.d.ts.map +1 -0
- package/styles/colors/presetsRGB.js +134 -0
- package/styles/colors/presetsRGB.js.map +1 -0
- package/styles/global.d.ts +18 -0
- package/styles/global.d.ts.map +1 -0
- package/styles/global.js +78 -0
- package/styles/global.js.map +1 -0
- package/styles/inputStyle.d.ts +3 -0
- package/styles/inputStyle.d.ts.map +1 -0
- package/styles/inputStyle.js +59 -0
- package/styles/inputStyle.js.map +1 -0
- package/switch-input.d.ts +8 -1
- package/switch-input.d.ts.map +1 -1
- package/switch-input.js +4 -1
- package/switch-input.js.map +1 -1
- package/text.d.ts +8 -1
- package/text.d.ts.map +1 -1
- package/text.js +4 -1
- package/text.js.map +1 -1
- package/time.d.ts +8 -1
- package/time.d.ts.map +1 -1
- package/time.js +4 -1
- package/time.js.map +1 -1
- package/tooltip.d.ts +8 -1
- package/tooltip.d.ts.map +1 -1
- package/tooltip.js +4 -1
- package/tooltip.js.map +1 -1
- package/typewriter.d.ts +8 -1
- package/typewriter.d.ts.map +1 -1
- package/typewriter.js +4 -1
- package/typewriter.js.map +1 -1
- package/web-components/alert/alert.d.ts +2 -10
- package/web-components/alert/alert.d.ts.map +1 -1
- package/web-components/alert/alert.js +93 -91
- package/web-components/alert/alert.js.map +1 -1
- package/web-components/avatar/avatar-group.d.ts +21 -0
- package/web-components/avatar/avatar-group.d.ts.map +1 -0
- package/web-components/avatar/avatar-group.js +86 -0
- package/web-components/avatar/avatar-group.js.map +1 -0
- package/web-components/avatar/avatar.d.ts +5 -18
- package/web-components/avatar/avatar.d.ts.map +1 -1
- package/web-components/avatar/avatar.js +70 -85
- package/web-components/avatar/avatar.js.map +1 -1
- package/web-components/button/button.d.ts +10 -43
- package/web-components/button/button.d.ts.map +1 -1
- package/web-components/button/button.js +183 -226
- package/web-components/button/button.js.map +1 -1
- package/web-components/card/card.d.ts +2 -27
- package/web-components/card/card.d.ts.map +1 -1
- package/web-components/card/card.js +57 -132
- package/web-components/card/card.js.map +1 -1
- package/web-components/carousel/carousel.d.ts +5 -16
- package/web-components/carousel/carousel.d.ts.map +1 -1
- package/web-components/carousel/carousel.js +102 -106
- package/web-components/carousel/carousel.js.map +1 -1
- package/web-components/details/details.d.ts +4 -15
- package/web-components/details/details.d.ts.map +1 -1
- package/web-components/details/details.js +91 -97
- package/web-components/details/details.js.map +1 -1
- package/web-components/dialog/dialog.d.ts +6 -17
- package/web-components/dialog/dialog.d.ts.map +1 -1
- package/web-components/dialog/dialog.js +87 -137
- package/web-components/dialog/dialog.js.map +1 -1
- package/web-components/divider/divider.d.ts +13 -0
- package/web-components/divider/divider.d.ts.map +1 -0
- package/web-components/divider/divider.js +95 -0
- package/web-components/divider/divider.js.map +1 -0
- package/web-components/form/form.d.ts +15 -22
- package/web-components/form/form.d.ts.map +1 -1
- package/web-components/form/form.js +47 -117
- package/web-components/form/form.js.map +1 -1
- package/web-components/input/input.d.ts +5 -18
- package/web-components/input/input.d.ts.map +1 -1
- package/web-components/input/input.js +74 -169
- package/web-components/input/input.js.map +1 -1
- package/web-components/input/label-input.d.ts +5 -19
- package/web-components/input/label-input.d.ts.map +1 -1
- package/web-components/input/label-input.js +74 -141
- package/web-components/input/label-input.js.map +1 -1
- package/web-components/input/range-input.d.ts +53 -0
- package/web-components/input/range-input.d.ts.map +1 -0
- package/web-components/input/range-input.js +316 -0
- package/web-components/input/range-input.js.map +1 -0
- package/web-components/input/search-input.d.ts +4 -12
- package/web-components/input/search-input.d.ts.map +1 -1
- package/web-components/input/search-input.js +118 -113
- package/web-components/input/search-input.js.map +1 -1
- package/web-components/input/select-input.d.ts +17 -32
- package/web-components/input/select-input.d.ts.map +1 -1
- package/web-components/input/select-input.js +154 -286
- package/web-components/input/select-input.js.map +1 -1
- package/web-components/input/split-input.d.ts +8 -15
- package/web-components/input/split-input.d.ts.map +1 -1
- package/web-components/input/split-input.js +82 -72
- package/web-components/input/split-input.js.map +1 -1
- package/web-components/input/switch-input.d.ts +8 -17
- package/web-components/input/switch-input.d.ts.map +1 -1
- package/web-components/input/switch-input.js +122 -158
- package/web-components/input/switch-input.js.map +1 -1
- package/web-components/layout/flex-flow.d.ts +11 -19
- package/web-components/layout/flex-flow.d.ts.map +1 -1
- package/web-components/layout/flex-flow.js +57 -35
- package/web-components/layout/flex-flow.js.map +1 -1
- package/web-components/layout/grid-flow.d.ts +14 -0
- package/web-components/layout/grid-flow.d.ts.map +1 -0
- package/web-components/layout/grid-flow.js +56 -0
- package/web-components/layout/grid-flow.js.map +1 -0
- package/web-components/layout/layout.d.ts +18 -0
- package/web-components/layout/layout.d.ts.map +1 -0
- package/web-components/layout/layout.js +76 -0
- package/web-components/layout/layout.js.map +1 -0
- package/web-components/link/link.d.ts +10 -0
- package/web-components/link/link.d.ts.map +1 -0
- package/web-components/link/link.js +17 -0
- package/web-components/link/link.js.map +1 -0
- package/web-components/link/router-link.d.ts +19 -0
- package/web-components/link/router-link.d.ts.map +1 -0
- package/web-components/link/router-link.js +60 -0
- package/web-components/link/router-link.js.map +1 -0
- package/web-components/progress/progress.d.ts +2 -12
- package/web-components/progress/progress.d.ts.map +1 -1
- package/web-components/progress/progress.js +52 -48
- package/web-components/progress/progress.js.map +1 -1
- package/web-components/router/router.d.ts +15 -21
- package/web-components/router/router.d.ts.map +1 -1
- package/web-components/router/router.js +35 -37
- package/web-components/router/router.js.map +1 -1
- package/web-components/skeleton/skeleton.d.ts +5 -12
- package/web-components/skeleton/skeleton.d.ts.map +1 -1
- package/web-components/skeleton/skeleton.js +90 -98
- package/web-components/skeleton/skeleton.js.map +1 -1
- package/web-components/text/overbreath.d.ts +15 -20
- package/web-components/text/overbreath.d.ts.map +1 -1
- package/web-components/text/overbreath.js +108 -202
- package/web-components/text/overbreath.js.map +1 -1
- package/web-components/text/text.d.ts +5 -18
- package/web-components/text/text.d.ts.map +1 -1
- package/web-components/text/text.js +70 -80
- package/web-components/text/text.js.map +1 -1
- package/web-components/text/time.d.ts +5 -14
- package/web-components/text/time.d.ts.map +1 -1
- package/web-components/text/time.js +32 -31
- package/web-components/text/time.js.map +1 -1
- package/web-components/text/typewriter.d.ts +3 -11
- package/web-components/text/typewriter.d.ts.map +1 -1
- package/web-components/text/typewriter.js +42 -40
- package/web-components/text/typewriter.js.map +1 -1
- package/web-components/tooltip/tooltip.d.ts +21 -17
- package/web-components/tooltip/tooltip.d.ts.map +1 -1
- package/web-components/tooltip/tooltip.js +98 -60
- package/web-components/tooltip/tooltip.js.map +1 -1
- package/web-components/wrapper/dragbox.d.ts +5 -10
- package/web-components/wrapper/dragbox.d.ts.map +1 -1
- package/web-components/wrapper/dragbox.js +40 -31
- package/web-components/wrapper/dragbox.js.map +1 -1
- package/web-components/wrapper/rotate.d.ts +30 -0
- package/web-components/wrapper/rotate.d.ts.map +1 -0
- package/web-components/wrapper/rotate.js +92 -0
- package/web-components/wrapper/rotate.js.map +1 -0
- package/.deps.js.map +0 -1
- package/a.d.ts +0 -2
- package/a.d.ts.map +0 -1
- package/a.js +0 -2
- package/a.js.map +0 -1
- package/clip.d.ts +0 -2
- package/clip.d.ts.map +0 -1
- package/clip.js +0 -2
- package/clip.js.map +0 -1
- package/decorators/define.d.ts +0 -7
- package/decorators/define.d.ts.map +0 -1
- package/decorators/define.js +0 -11
- package/decorators/define.js.map +0 -1
- package/details-group.d.ts +0 -2
- package/details-group.d.ts.map +0 -1
- package/details-group.js +0 -2
- package/details-group.js.map +0 -1
- package/godown-element.d.ts.map +0 -1
- package/godown-element.js.map +0 -1
- package/lib/event-collection.d.ts +0 -14
- package/lib/event-collection.d.ts.map +0 -1
- package/lib/event-collection.js +0 -71
- package/lib/event-collection.js.map +0 -1
- package/lib/templates.d.ts.map +0 -1
- package/lib/templates.js +0 -76
- package/lib/templates.js.map +0 -1
- package/naming.d.ts +0 -91
- package/naming.d.ts.map +0 -1
- package/naming.js +0 -67
- package/naming.js.map +0 -1
- package/nav-layout.d.ts +0 -2
- package/nav-layout.d.ts.map +0 -1
- package/nav-layout.js +0 -2
- package/nav-layout.js.map +0 -1
- package/open-offset.d.ts +0 -2
- package/open-offset.d.ts.map +0 -1
- package/open-offset.js +0 -2
- package/open-offset.js.map +0 -1
- package/router-a.d.ts +0 -2
- package/router-a.d.ts.map +0 -1
- package/router-a.js +0 -2
- package/router-a.js.map +0 -1
- package/supers/anchor.d.ts +0 -26
- package/supers/anchor.d.ts.map +0 -1
- package/supers/anchor.js +0 -124
- package/supers/anchor.js.map +0 -1
- package/supers/input.d.ts +0 -28
- package/supers/input.d.ts.map +0 -1
- package/supers/input.js +0 -117
- package/supers/input.js.map +0 -1
- package/supers/openable.d.ts +0 -38
- package/supers/openable.d.ts.map +0 -1
- package/supers/openable.js +0 -77
- package/supers/openable.js.map +0 -1
- package/supers/root.d.ts +0 -18
- package/supers/root.d.ts.map +0 -1
- package/supers/root.js +0 -76
- package/supers/root.js.map +0 -1
- package/tabs.d.ts +0 -2
- package/tabs.d.ts.map +0 -1
- package/tabs.js +0 -2
- package/tabs.js.map +0 -1
- package/web-components/a/a.d.ts +0 -16
- package/web-components/a/a.d.ts.map +0 -1
- package/web-components/a/a.js +0 -17
- package/web-components/a/a.js.map +0 -1
- package/web-components/group/avatar-group.d.ts +0 -29
- package/web-components/group/avatar-group.d.ts.map +0 -1
- package/web-components/group/avatar-group.js +0 -88
- package/web-components/group/avatar-group.js.map +0 -1
- package/web-components/group/details-group.d.ts +0 -28
- package/web-components/group/details-group.d.ts.map +0 -1
- package/web-components/group/details-group.js +0 -59
- package/web-components/group/details-group.js.map +0 -1
- package/web-components/index.d.ts +0 -35
- package/web-components/index.d.ts.map +0 -1
- package/web-components/index.js +0 -35
- package/web-components/index.js.map +0 -1
- package/web-components/layout/divider.d.ts +0 -22
- package/web-components/layout/divider.d.ts.map +0 -1
- package/web-components/layout/divider.js +0 -85
- package/web-components/layout/divider.js.map +0 -1
- package/web-components/layout/nav-layout.d.ts +0 -38
- package/web-components/layout/nav-layout.d.ts.map +0 -1
- package/web-components/layout/nav-layout.js +0 -69
- package/web-components/layout/nav-layout.js.map +0 -1
- package/web-components/offset/open-offset.d.ts +0 -27
- package/web-components/offset/open-offset.d.ts.map +0 -1
- package/web-components/offset/open-offset.js +0 -130
- package/web-components/offset/open-offset.js.map +0 -1
- package/web-components/router/router-a.d.ts +0 -25
- package/web-components/router/router-a.d.ts.map +0 -1
- package/web-components/router/router-a.js +0 -70
- package/web-components/router/router-a.js.map +0 -1
- package/web-components/tabs/tabs.d.ts +0 -52
- package/web-components/tabs/tabs.d.ts.map +0 -1
- package/web-components/tabs/tabs.js +0 -165
- package/web-components/tabs/tabs.js.map +0 -1
- package/web-components/text/clip.d.ts +0 -22
- package/web-components/text/clip.d.ts.map +0 -1
- package/web-components/text/clip.js +0 -45
- package/web-components/text/clip.js.map +0 -1
- package/web-components/wrapper/wrapper.d.ts +0 -27
- package/web-components/wrapper/wrapper.d.ts.map +0 -1
- package/web-components/wrapper/wrapper.js +0 -95
- package/web-components/wrapper/wrapper.js.map +0 -1
- package/wrapper.d.ts +0 -2
- package/wrapper.d.ts.map +0 -1
- package/wrapper.js +0 -2
- package/wrapper.js.map +0 -1
package/supers/anchor.js
DELETED
@@ -1,124 +0,0 @@
|
|
1
|
-
import { __decorate } from "tslib";
|
2
|
-
import { css, html, ifDefined, property } from "../.deps.js";
|
3
|
-
import { htmlSlot, svgArrow, svgDelta, svgLink } from "../lib/templates.js";
|
4
|
-
import { GodownElement } from "./root.js";
|
5
|
-
export class GodownAnchor extends GodownElement {
|
6
|
-
constructor() {
|
7
|
-
super(...arguments);
|
8
|
-
/**
|
9
|
-
* True when the href is in the same pathname as the location.
|
10
|
-
*/
|
11
|
-
this.active = false;
|
12
|
-
/**
|
13
|
-
* Href for a element.
|
14
|
-
*/
|
15
|
-
this.href = undefined;
|
16
|
-
/**
|
17
|
-
* Target for an element.
|
18
|
-
*/
|
19
|
-
this.target = "_self";
|
20
|
-
/**
|
21
|
-
* Arrow type.
|
22
|
-
*/
|
23
|
-
this.arrow = "";
|
24
|
-
}
|
25
|
-
render() {
|
26
|
-
return html `<a href="${ifDefined(this.href)}" target="${this.target}">
|
27
|
-
${htmlSlot()}
|
28
|
-
<i>${this._arrowSwitcher()}</i>
|
29
|
-
</a>`;
|
30
|
-
}
|
31
|
-
_arrowSwitcher() {
|
32
|
-
switch (this.arrow) {
|
33
|
-
case "delta":
|
34
|
-
return svgDelta();
|
35
|
-
case "arrow":
|
36
|
-
return svgArrow(true);
|
37
|
-
case "angle":
|
38
|
-
return svgArrow();
|
39
|
-
case "link":
|
40
|
-
return svgLink();
|
41
|
-
default:
|
42
|
-
return htmlSlot("icon");
|
43
|
-
}
|
44
|
-
}
|
45
|
-
useActive() {
|
46
|
-
const url = new URL(this.href, location.href);
|
47
|
-
if (url.origin === location.origin) {
|
48
|
-
this.active = url.pathname === location.pathname;
|
49
|
-
}
|
50
|
-
}
|
51
|
-
}
|
52
|
-
GodownAnchor.styles = [
|
53
|
-
css `
|
54
|
-
:host([arrow="delta"]) svg {
|
55
|
-
transform: rotate(-90deg);
|
56
|
-
}
|
57
|
-
|
58
|
-
:host {
|
59
|
-
display: inline-block;
|
60
|
-
color: currentColor;
|
61
|
-
text-decoration: none;
|
62
|
-
cursor: default;
|
63
|
-
}
|
64
|
-
|
65
|
-
:host([href]) {
|
66
|
-
cursor: pointer;
|
67
|
-
}
|
68
|
-
|
69
|
-
a {
|
70
|
-
width: 100%;
|
71
|
-
display: flex;
|
72
|
-
color: inherit;
|
73
|
-
text-decoration: inherit;
|
74
|
-
justify-content: space-between;
|
75
|
-
align-items: center;
|
76
|
-
}
|
77
|
-
|
78
|
-
i {
|
79
|
-
display: inline-flex;
|
80
|
-
border-radius: 20%;
|
81
|
-
font-style: normal;
|
82
|
-
}
|
83
|
-
|
84
|
-
i > svg {
|
85
|
-
width: 1em;
|
86
|
-
height: 1em;
|
87
|
-
border-radius: inherit;
|
88
|
-
}
|
89
|
-
|
90
|
-
:host(:hover) i {
|
91
|
-
animation: arrow 0.3s linear;
|
92
|
-
}
|
93
|
-
|
94
|
-
i:hover {
|
95
|
-
background-color: rgb(0 0 0 / 0.075);
|
96
|
-
}
|
97
|
-
|
98
|
-
@keyframes arrow {
|
99
|
-
from {
|
100
|
-
transform: translateX(0);
|
101
|
-
}
|
102
|
-
50% {
|
103
|
-
transform: translateX(0.05em);
|
104
|
-
}
|
105
|
-
to {
|
106
|
-
transform: translateX(0);
|
107
|
-
}
|
108
|
-
}
|
109
|
-
`,
|
110
|
-
];
|
111
|
-
__decorate([
|
112
|
-
property({ type: Boolean, reflect: true })
|
113
|
-
], GodownAnchor.prototype, "active", void 0);
|
114
|
-
__decorate([
|
115
|
-
property()
|
116
|
-
], GodownAnchor.prototype, "href", void 0);
|
117
|
-
__decorate([
|
118
|
-
property()
|
119
|
-
], GodownAnchor.prototype, "target", void 0);
|
120
|
-
__decorate([
|
121
|
-
property()
|
122
|
-
], GodownAnchor.prototype, "arrow", void 0);
|
123
|
-
export default GodownAnchor;
|
124
|
-
//# sourceMappingURL=anchor.js.map
|
package/supers/anchor.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"anchor.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["supers/anchor.ts"],"names":[],"mappings":";AAAA,OA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;IACH,CAAC;;AAvFM,mBAAM,GAAG;IACd,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAwDF;CACF,AA1DY,CA0DX;AAxE0C;IAA3C,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;4CAAgB;AAI/C;IAAX,QAAQ,EAAE;0CAA0B;AAIzB;IAAX,QAAQ,EAAE;4CAAkB;AAIjB;IAAX,QAAQ,EAAE;2CAAuD;AA4FpE,eAAe,YAAY,CAAC","sourcesContent":["import { css, html, ifDefined, property } from \"../.deps.js\";\nimport { htmlSlot, type HTMLTemplate, svgArrow, svgDelta, svgLink } from \"../lib/templates.js\";\nimport { GodownElement } from \"./root.js\";\n\nexport class GodownAnchor extends GodownElement {\n /**\n * True when the href is in the same pathname as the location.\n */\n @property({ type: Boolean, reflect: true }) active = false;\n /**\n * Href for a element.\n */\n @property() href: string = undefined;\n /**\n * Target for an element.\n */\n @property() target = \"_self\";\n /**\n * Arrow type.\n */\n @property() arrow: \"\" | \"link\" | \"delta\" | \"arrow\" | \"angle\" = \"\";\n\n static styles = [\n css`\n :host([arrow=\"delta\"]) svg {\n transform: rotate(-90deg);\n }\n\n :host {\n display: inline-block;\n color: currentColor;\n text-decoration: none;\n cursor: default;\n }\n\n :host([href]) {\n cursor: pointer;\n }\n\n a {\n width: 100%;\n display: flex;\n color: inherit;\n text-decoration: inherit;\n justify-content: space-between;\n align-items: center;\n }\n\n i {\n display: inline-flex;\n border-radius: 20%;\n font-style: normal;\n }\n\n i > svg {\n width: 1em;\n height: 1em;\n border-radius: inherit;\n }\n\n :host(:hover) i {\n animation: arrow 0.3s linear;\n }\n\n i:hover {\n background-color: rgb(0 0 0 / 0.075);\n }\n\n @keyframes arrow {\n from {\n transform: translateX(0);\n }\n 50% {\n transform: translateX(0.05em);\n }\n to {\n transform: translateX(0);\n }\n }\n `,\n ];\n\n protected render(): HTMLTemplate {\n return html`<a href=\"${ifDefined(this.href)}\" target=\"${this.target}\">\n ${htmlSlot()}\n <i>${this._arrowSwitcher()}</i>\n </a>`;\n }\n\n private _arrowSwitcher(): HTMLTemplate {\n switch (this.arrow) {\n case \"delta\":\n return svgDelta();\n case \"arrow\":\n return svgArrow(true);\n case \"angle\":\n return svgArrow();\n case \"link\":\n return svgLink();\n default:\n return htmlSlot(\"icon\");\n }\n }\n\n useActive() {\n const url = new URL(this.href, location.href);\n if (url.origin === location.origin) {\n this.active = url.pathname === location.pathname;\n }\n }\n}\n\nexport default GodownAnchor;\n"]}
|
package/supers/input.d.ts
DELETED
@@ -1,28 +0,0 @@
|
|
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 GodownInput extends GodownElement {
|
5
|
-
type: InputType;
|
6
|
-
name: string;
|
7
|
-
value: string | any;
|
8
|
-
label: string;
|
9
|
-
def: string;
|
10
|
-
pla?: string;
|
11
|
-
autofocus: boolean;
|
12
|
-
_input: HTMLInputElement;
|
13
|
-
compositing: boolean;
|
14
|
-
static styles: CSSResultGroup;
|
15
|
-
namevalue(): [string, any];
|
16
|
-
nameValue: () => [string, any];
|
17
|
-
reset(): void;
|
18
|
-
protected _handleInput(e: any): void;
|
19
|
-
protected _handleChange(): void;
|
20
|
-
connectedCallback(): void;
|
21
|
-
protected _initName(): void;
|
22
|
-
protected _compositionCheck(): void;
|
23
|
-
protected _changeInputType(t: InputType): void;
|
24
|
-
focus(options?: FocusOptions): void;
|
25
|
-
protected firstUpdated(): void;
|
26
|
-
protected targetValue(e: Event): string | any;
|
27
|
-
}
|
28
|
-
//# sourceMappingURL=input.d.ts.map
|
package/supers/input.d.ts.map
DELETED
@@ -1 +0,0 @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/supers/input.js
DELETED
@@ -1,117 +0,0 @@
|
|
1
|
-
import { __decorate } from "tslib";
|
2
|
-
import { css, property } from "../.deps.js";
|
3
|
-
import { cssvarValues, GodownElement } from "./root.js";
|
4
|
-
export class GodownInput extends GodownElement {
|
5
|
-
constructor() {
|
6
|
-
super(...arguments);
|
7
|
-
this.type = "text";
|
8
|
-
this.name = undefined;
|
9
|
-
this.value = undefined;
|
10
|
-
this.label = "";
|
11
|
-
this.def = "";
|
12
|
-
this.pla = undefined;
|
13
|
-
this.autofocus = false;
|
14
|
-
this.nameValue = () => this.namevalue();
|
15
|
-
}
|
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;
|
28
|
-
}
|
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 }));
|
34
|
-
}
|
35
|
-
connectedCallback() {
|
36
|
-
super.connectedCallback();
|
37
|
-
if (!this.def) {
|
38
|
-
this.def = this.value || "";
|
39
|
-
}
|
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;
|
49
|
-
}
|
50
|
-
}
|
51
|
-
}
|
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
|
-
});
|
61
|
-
}
|
62
|
-
}
|
63
|
-
_changeInputType(t) {
|
64
|
-
this._input.type = t;
|
65
|
-
}
|
66
|
-
focus(options) {
|
67
|
-
this._input?.focus(options);
|
68
|
-
}
|
69
|
-
firstUpdated() {
|
70
|
-
this._compositionCheck();
|
71
|
-
this.reset();
|
72
|
-
}
|
73
|
-
targetValue(e) {
|
74
|
-
const target = e.target;
|
75
|
-
if (target.value.trim) {
|
76
|
-
return target.value.trim();
|
77
|
-
}
|
78
|
-
return target.value;
|
79
|
-
}
|
80
|
-
}
|
81
|
-
GodownInput.styles = [
|
82
|
-
GodownElement.styles,
|
83
|
-
css `
|
84
|
-
:host {
|
85
|
-
display: flex;
|
86
|
-
}
|
87
|
-
::-ms-reveal {
|
88
|
-
display: none;
|
89
|
-
}
|
90
|
-
::-webkit-calendar-picker-indicator {
|
91
|
-
background-color: var(${cssvarValues.input}-true);
|
92
|
-
border-radius: 0.1rem;
|
93
|
-
}
|
94
|
-
`,
|
95
|
-
];
|
96
|
-
__decorate([
|
97
|
-
property({ reflect: true })
|
98
|
-
], GodownInput.prototype, "type", void 0);
|
99
|
-
__decorate([
|
100
|
-
property()
|
101
|
-
], GodownInput.prototype, "name", void 0);
|
102
|
-
__decorate([
|
103
|
-
property()
|
104
|
-
], GodownInput.prototype, "value", void 0);
|
105
|
-
__decorate([
|
106
|
-
property({ reflect: true })
|
107
|
-
], GodownInput.prototype, "label", void 0);
|
108
|
-
__decorate([
|
109
|
-
property()
|
110
|
-
], GodownInput.prototype, "def", void 0);
|
111
|
-
__decorate([
|
112
|
-
property({ reflect: true })
|
113
|
-
], GodownInput.prototype, "pla", void 0);
|
114
|
-
__decorate([
|
115
|
-
property({ type: Boolean, reflect: true })
|
116
|
-
], GodownInput.prototype, "autofocus", void 0);
|
117
|
-
//# sourceMappingURL=input.js.map
|
package/supers/input.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"input.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["supers/input.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAuB,QAAQ,EAAE,MAAM,aAAa,CAAC;AACjE,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAIxD,MAAM,OAAO,WAAY,SAAQ,aAAa;IAA9C;;QAC+B,SAAI,GAAc,MAAM,CAAC;QAC1C,SAAI,GAAW,SAAS,CAAC;QACzB,UAAK,GAAiB,SAAS,CAAC;QACf,UAAK,GAAG,EAAE,CAAC;QAC5B,QAAG,GAAG,EAAE,CAAC;QACQ,QAAG,GAAY,SAAS,CAAC;QACV,cAAS,GAAG,KAAK,CAAC;QAyB9D,cAAS,GAAG,GAAG,EAAE,CAAC,IAAI,CAAC,SAAS,EAAE,CAAC;IAwErC,CAAC;IA5EC,SAAS;QACP,OAAO,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,CAAC,KAAK,CAAC,CAAC;IACjC,CAAC;IAID,KAAK;QACH,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC;QACtB,IAAI,CAAC,MAAM,CAAC,KAAK,GAAG,IAAI,CAAC,GAAG,CAAC;IAC/B,CAAC;IAES,YAAY,CAAC,CAAM;QAC3B,CAAC,CAAC,eAAe,EAAE,CAAC;QACpB,IAAI,CAAC,KAAK,GAAG,CAAC,CAAC,MAAM,CAAC,KAAK,EAAE,IAAI,EAAE,CAAC;QACpC,IAAI,IAAI,CAAC,WAAW,EAAE,CAAC;YACrB,OAAO;QACT,CAAC;QACD,IAAI,CAAC,aAAa,CAAC,IAAI,WAAW,CAAC,OAAO,EAAE,EAAE,MAAM,EAAE,IAAI,CAAC,KAAK,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC;QACpG,IAAI,CAAC,aAAa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port 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 GodownInput 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"]}
|
package/supers/openable.d.ts
DELETED
@@ -1,38 +0,0 @@
|
|
1
|
-
import { type CSSResultGroup, type PropertyValueMap } from "../.deps.js";
|
2
|
-
import { type EventsNames } from "../lib/event-collection.js";
|
3
|
-
import { GodownElement } from "./root.js";
|
4
|
-
export type Direction4 = "left" | "right" | "top" | "bottom";
|
5
|
-
export type Direction5 = Direction4 | "center";
|
6
|
-
export type Direction8 = Direction4 | "top-left" | "top-right" | "bottom-left" | "bottom-right";
|
7
|
-
export type Direction9 = Direction8 | "center";
|
8
|
-
export type OnEvents = EventsNames | "";
|
9
|
-
export declare class GodownOpenable extends GodownElement {
|
10
|
-
/**
|
11
|
-
* Summary text.
|
12
|
-
*/
|
13
|
-
summary: string;
|
14
|
-
/**
|
15
|
-
* Make the content float.
|
16
|
-
*/
|
17
|
-
float: boolean;
|
18
|
-
/**
|
19
|
-
* Open the content.
|
20
|
-
*/
|
21
|
-
open: boolean;
|
22
|
-
/**
|
23
|
-
* Enable event mode.
|
24
|
-
*/
|
25
|
-
on: OnEvents;
|
26
|
-
/**
|
27
|
-
* Direction of appearance.
|
28
|
-
*/
|
29
|
-
direction: Direction9 | "";
|
30
|
-
static styles: CSSResultGroup;
|
31
|
-
toggle(to?: boolean): void;
|
32
|
-
close(): void;
|
33
|
-
show(): void;
|
34
|
-
protected updated(changedProperties: PropertyValueMap<this>): void;
|
35
|
-
protected _handelClick(_: MouseEvent): void;
|
36
|
-
}
|
37
|
-
export default GodownOpenable;
|
38
|
-
//# sourceMappingURL=openable.d.ts.map
|
package/supers/openable.d.ts.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"openable.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["supers/openable.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,cAAc,EAAY,KAAK,gBAAgB,EAAE,MAAM,aAAa,CAAC;AACxF,OAAO,EAAE,KAAK,WAAW,EAAE,MAAM,4BAA4B,CAAC;AAC9D,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAE1C,MAAM,MAAM,UAAU,GAAG,MAAM,GAAG,OAAO,GAAG,KAAK,GAAG,QAAQ,CAAC;AAE7D,MAAM,MAAM,UAAU,GAAG,UAAU,GAAG,QAAQ,CAAC;AAE/C,MAAM,MAAM,UAAU,GAAG,UAAU,GAAG,UAAU,GAAG,WAAW,GAAG,aAAa,GAAG,cAAc,CAAC;AAEhG,MAAM,MAAM,UAAU,GAAG,UAAU,GAAG,QAAQ,CAAC;AAE/C,MAAM,MAAM,QAAQ,GAAG,WAAW,GAAG,EAAE,CAAC;AAExC,qBAAa,cAAe,SAAQ,aAAa;IAC/C;;OAEG;IACS,OAAO,SAAM;IACzB;;OAEG;IACyC,KAAK,UAAS;IAC1D;;OAEG;IACyC,IAAI,UAAS;IACzD;;OAEG;IACS,EAAE,EAAE,QAAQ,CAAM;IAC9B;;OAEG;IACS,SAAS,EAAE,UAAU,GAAG,EAAE,CAAM;IAE5C,MAAM,CAAC,MAAM,iBAYO;IAEpB,MAAM,CAAC,EAAE,UAAa;IAItB,KAAK;IAIL,IAAI;IAIJ,SAAS,CAAC,OAAO,CAAC,iBAAiB,EAAE,gBAAgB,CAAC,IAAI,CAAC;IAQ3D,SAAS,CAAC,YAAY,CAAC,CAAC,EAAE,UAAU;CAGrC;AAED,eAAe,cAAc,CAAC"}
|
package/supers/openable.js
DELETED
@@ -1,77 +0,0 @@
|
|
1
|
-
import { __decorate } from "tslib";
|
2
|
-
import { css, property } from "../.deps.js";
|
3
|
-
import { GodownElement } from "./root.js";
|
4
|
-
export class GodownOpenable extends GodownElement {
|
5
|
-
constructor() {
|
6
|
-
super(...arguments);
|
7
|
-
/**
|
8
|
-
* Summary text.
|
9
|
-
*/
|
10
|
-
this.summary = "";
|
11
|
-
/**
|
12
|
-
* Make the content float.
|
13
|
-
*/
|
14
|
-
this.float = false;
|
15
|
-
/**
|
16
|
-
* Open the content.
|
17
|
-
*/
|
18
|
-
this.open = false;
|
19
|
-
/**
|
20
|
-
* Enable event mode.
|
21
|
-
*/
|
22
|
-
this.on = "";
|
23
|
-
/**
|
24
|
-
* Direction of appearance.
|
25
|
-
*/
|
26
|
-
this.direction = "";
|
27
|
-
}
|
28
|
-
toggle(to = !this.open) {
|
29
|
-
this.open = to;
|
30
|
-
}
|
31
|
-
close() {
|
32
|
-
this.open = false;
|
33
|
-
}
|
34
|
-
show() {
|
35
|
-
this.open = true;
|
36
|
-
}
|
37
|
-
updated(changedProperties) {
|
38
|
-
const open = changedProperties.get("open");
|
39
|
-
if (typeof open === typeof !0) {
|
40
|
-
this.dispatchEvent(new CustomEvent("change", { detail: this.open }));
|
41
|
-
}
|
42
|
-
}
|
43
|
-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
44
|
-
_handelClick(_) {
|
45
|
-
this.toggle();
|
46
|
-
}
|
47
|
-
}
|
48
|
-
GodownOpenable.styles = [
|
49
|
-
GodownElement.styles,
|
50
|
-
css `
|
51
|
-
:host {
|
52
|
-
display: block;
|
53
|
-
transition:
|
54
|
-
all 0.3s ease-in-out,
|
55
|
-
color 0s,
|
56
|
-
background 0s;
|
57
|
-
height: fit-content;
|
58
|
-
}
|
59
|
-
`,
|
60
|
-
];
|
61
|
-
__decorate([
|
62
|
-
property()
|
63
|
-
], GodownOpenable.prototype, "summary", void 0);
|
64
|
-
__decorate([
|
65
|
-
property({ type: Boolean, reflect: true })
|
66
|
-
], GodownOpenable.prototype, "float", void 0);
|
67
|
-
__decorate([
|
68
|
-
property({ type: Boolean, reflect: true })
|
69
|
-
], GodownOpenable.prototype, "open", void 0);
|
70
|
-
__decorate([
|
71
|
-
property()
|
72
|
-
], GodownOpenable.prototype, "on", void 0);
|
73
|
-
__decorate([
|
74
|
-
property()
|
75
|
-
], GodownOpenable.prototype, "direction", void 0);
|
76
|
-
export default GodownOpenable;
|
77
|
-
//# sourceMappingURL=openable.js.map
|
package/supers/openable.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"openable.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["supers/openable.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAuB,QAAQ,EAAyB,MAAM,aAAa,CAAC;AAExF,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAY1C,MAAM,OAAO,cAAe,SAAQ,aAAa;IAAjD;;QACE;;WAEG;QACS,YAAO,GAAG,EAAE,CAAC;QACzB;;WAEG;QACyC,UAAK,GAAG,KAAK,CAAC;QAC1D;;WAEG;QACyC,SAAI,GAAG,KAAK,CAAC;QACzD;;WAEG;QACS,OAAE,GAAa,EAAE,CAAC;QAC9B;;WAEG;QACS,cAAS,GAAoB,EAAE,CAAC;IAuC9C,CAAC;IAvBC,MAAM,CAAC,EAAE,GAAG,CAAC,IAAI,CAAC,IAAI;QACpB,IAAI,CAAC,IAAI,GAAG,EAAE,CAAC;IACjB,CAAC;IAED,KAAK;QACH,IAAI,CAAC,IAAI,GAAG,KAAK,CAAC;IACpB,CAAC;IAED,IAAI;QACF,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;IACnB,CAAC;IAES,OAAO,CAAC,iBAAyC;QACzD,MAAM,IAAI,GAAG,iBAAiB,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;QAC3C,IAAI,OAAO,IAAI,KAAK,OAAO,CAAC,CAAC,EAAE,CAAC;YAC9B,IAAI,CAAC,aAAa,CAAC,IAAI,WAAW,CAAC,QAAQ,EAAE,EAAE,MAAM,EAAE,IAAI,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC;QACvE,CAAC;IACH,CAAC;IAED,6DAA6D;IACnD,YAAY,CAAC,CAAa;QAClC,IAAI,CAAC,MAAM,EAAE,CAAC;IAChB,CAAC;;AApCM,qBAAM,GAAG;IACd,aAAa,CAAC,MAAM;IACpB,GAAG,CAAA;;;;;;;;;KASF;CACgB,AAZN,CAYO;AA9BR;IAAX,QAAQ,EAAE;+CAAc;AAImB;IAA3C,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;6CAAe;AAId;IAA3C,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;4CAAc;AAI7C;IAAX,QAAQ,EAAE;0CAAmB;AAIlB;IAAX,QAAQ,EAAE;iDAAiC;AAyC9C,eAAe,cAAc,CAAC","sourcesContent":["import { css, type CSSResultGroup, property, type PropertyValueMap } from \"../.deps.js\";\nimport { type EventsNames } from \"../lib/event-collection.js\";\nimport { GodownElement } from \"./root.js\";\n\nexport type Direction4 = \"left\" | \"right\" | \"top\" | \"bottom\";\n\nexport type Direction5 = Direction4 | \"center\";\n\nexport type Direction8 = Direction4 | \"top-left\" | \"top-right\" | \"bottom-left\" | \"bottom-right\";\n\nexport type Direction9 = Direction8 | \"center\";\n\nexport type OnEvents = EventsNames | \"\";\n\nexport class GodownOpenable extends GodownElement {\n /**\n * Summary text.\n */\n @property() summary = \"\";\n /**\n * Make the content float.\n */\n @property({ type: Boolean, reflect: true }) float = false;\n /**\n * Open the content.\n */\n @property({ type: Boolean, reflect: true }) open = false;\n /**\n * Enable event mode.\n */\n @property() on: OnEvents = \"\";\n /**\n * Direction of appearance.\n */\n @property() direction: Direction9 | \"\" = \"\";\n\n static styles = [\n GodownElement.styles,\n css`\n :host {\n display: block;\n transition:\n all 0.3s ease-in-out,\n color 0s,\n background 0s;\n height: fit-content;\n }\n `,\n ] as CSSResultGroup;\n\n toggle(to = !this.open) {\n this.open = to;\n }\n\n close() {\n this.open = false;\n }\n\n show() {\n this.open = true;\n }\n\n protected updated(changedProperties: PropertyValueMap<this>) {\n const open = changedProperties.get(\"open\");\n if (typeof open === typeof !0) {\n this.dispatchEvent(new CustomEvent(\"change\", { detail: this.open }));\n }\n }\n\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n protected _handelClick(_: MouseEvent) {\n this.toggle();\n }\n}\n\nexport default GodownOpenable;\n"]}
|
package/supers/root.d.ts
DELETED
@@ -1,18 +0,0 @@
|
|
1
|
-
import { type CSSResult } from "lit";
|
2
|
-
import GodownElement from "../godown-element.js";
|
3
|
-
/**
|
4
|
-
* Custom CSS variable prefix, join with "--".
|
5
|
-
*/
|
6
|
-
export declare const cssvar: CSSResult;
|
7
|
-
export declare function createScope(scope: string): CSSResult;
|
8
|
-
export declare const cssvarValues: {
|
9
|
-
cssvar: CSSResult;
|
10
|
-
input: CSSResult;
|
11
|
-
main: CSSResult;
|
12
|
-
text: CSSResult;
|
13
|
-
mainRGB: CSSResult;
|
14
|
-
textRGB: CSSResult;
|
15
|
-
};
|
16
|
-
export { GodownElement };
|
17
|
-
export default GodownElement;
|
18
|
-
//# sourceMappingURL=root.d.ts.map
|
package/supers/root.d.ts.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"root.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["supers/root.ts"],"names":[],"mappings":"AAAA,OAAO,EAAO,KAAK,SAAS,EAAkC,MAAM,KAAK,CAAC;AAG1E,OAAO,aAAa,MAAM,sBAAsB,CAAC;AAIjD;;GAEG;AACH,eAAO,MAAM,MAAM,WAAuE,CAAC;AAE3F,wBAAgB,WAAW,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,CAEpD;AAMD,eAAO,MAAM,YAAY;;;;;;;CAOxB,CAAC;AAuDF,OAAO,EAAE,aAAa,EAAE,CAAC;AACzB,eAAe,aAAa,CAAC"}
|
package/supers/root.js
DELETED
@@ -1,76 +0,0 @@
|
|
1
|
-
import { css, unsafeCSS } from "lit";
|
2
|
-
import { conf } from "../conf.js";
|
3
|
-
import GodownElement from "../godown-element.js";
|
4
|
-
const scopeString = "--";
|
5
|
-
/**
|
6
|
-
* Custom CSS variable prefix, join with "--".
|
7
|
-
*/
|
8
|
-
export const cssvar = unsafeCSS(scopeString + conf.cssvar.replace(/[^a-zA-Z0-9\\-]/g, ""));
|
9
|
-
export function createScope(scope) {
|
10
|
-
return joinScope(conf.tag(scope));
|
11
|
-
}
|
12
|
-
function joinScope(s) {
|
13
|
-
return unsafeCSS(cssvar + scopeString + s);
|
14
|
-
}
|
15
|
-
export const cssvarValues = {
|
16
|
-
cssvar,
|
17
|
-
input: joinScope("input"),
|
18
|
-
main: joinScope("background"),
|
19
|
-
text: joinScope("foreground"),
|
20
|
-
mainRGB: joinScope("background-rgb"),
|
21
|
-
textRGB: joinScope("foreground-rgb"),
|
22
|
-
};
|
23
|
-
GodownElement.conf = conf;
|
24
|
-
GodownElement.styles = [
|
25
|
-
css `
|
26
|
-
:host {
|
27
|
-
${cssvar}--background-rgb: 12 12 12;
|
28
|
-
${cssvar}--background: rgb(var(${cssvarValues.mainRGB}));
|
29
|
-
${cssvar}--foreground-rgb: 240 240 240;
|
30
|
-
${cssvar}--foreground: rgb(var(${cssvarValues.textRGB}));
|
31
|
-
${cssvar}--clip-background:linear-gradient(180deg, var(${cssvarValues.text}), rgb(var(${cssvarValues.textRGB}) / 68%));
|
32
|
-
${cssvar}--size: 100%;
|
33
|
-
${cssvar}--accept: rgb(25 130 180);
|
34
|
-
font-size: var(${cssvar}--size);
|
35
|
-
}
|
36
|
-
`,
|
37
|
-
css `
|
38
|
-
:host {
|
39
|
-
${cssvarValues.input}--width: 10em;
|
40
|
-
${cssvarValues.input}--height: 1.6em;
|
41
|
-
${cssvarValues.input}--background: var(${cssvarValues.main});
|
42
|
-
${cssvarValues.input}--true: rgb(48 132 240);
|
43
|
-
${cssvarValues.input}--false: rgb(198 198 198);
|
44
|
-
${cssvarValues.input}--control:var(${cssvarValues.text});
|
45
|
-
${cssvarValues.input}--control-edge: var(${cssvarValues.input}--true);
|
46
|
-
${cssvarValues.input}--outline-color: var(${cssvar}--accept);
|
47
|
-
${cssvarValues.input}--outline-width: .15em;
|
48
|
-
${cssvarValues.input}--outline-style: solid;
|
49
|
-
${cssvarValues.input}--outline: var(${cssvarValues.input}--outline-width) var(${cssvarValues.input}--outline-style) var(${cssvarValues.input}--outline-color);
|
50
|
-
${cssvarValues.input}--radius: 0.2em;
|
51
|
-
}
|
52
|
-
`,
|
53
|
-
css `
|
54
|
-
* {
|
55
|
-
font-size: 100%;
|
56
|
-
font-style: normal;
|
57
|
-
color: inherit;
|
58
|
-
box-sizing: border-box;
|
59
|
-
margin: 0;
|
60
|
-
padding: 0;
|
61
|
-
border: 0;
|
62
|
-
outline: 0;
|
63
|
-
text-decoration: none;
|
64
|
-
}
|
65
|
-
|
66
|
-
::selection {
|
67
|
-
${cssvar}--text-selection--color: inherit;
|
68
|
-
${cssvar}--text-selection--background: none;
|
69
|
-
color: var(${cssvar}--text-selection--color);
|
70
|
-
background: var(${cssvar}--text-selection--background);
|
71
|
-
}
|
72
|
-
`,
|
73
|
-
];
|
74
|
-
export { GodownElement };
|
75
|
-
export default GodownElement;
|
76
|
-
//# sourceMappingURL=root.js.map
|
package/supers/root.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"root.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["supers/root.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAuC,SAAS,EAAE,MAAM,KAAK,CAAC;AAE1E,OAAO,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAClC,OAAO,aAAa,MAAM,sBAAsB,CAAC;AAEjD,MAAM,WAAW,GAAG,IAAI,CAAC;AAEzB;;GAEG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,SAAS,CAAC,WAAW,GAAG,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,kBAAkB,EAAE,EAAE,CAAC,CAAC,CAAC;AAE3F,M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AwB,YAAY,CAAC,KAAK;QAC3I,YAAY,CAAC,KAAK;;GAEvB;IACD,GAAG,CAAA;;;;;;;;;;;;;;QAcG,MAAM;QACN,MAAM;mBACK,MAAM;wBACD,MAAM;;GAE3B;CACgB,CAAC;AAEpB,OAAO,EAAE,aAAa,EAAE,CAAC;AACzB,eAAe,aAAa,CAAC","sourcesContent":["import { css, type CSSResult, type CSSResultGroup, unsafeCSS } from \"lit\";\n\nimport { conf } from \"../conf.js\";\nimport GodownElement from \"../godown-element.js\";\n\nconst scopeString = \"--\";\n\n/**\n * Custom CSS variable prefix, join with \"--\".\n */\nexport const cssvar = unsafeCSS(scopeString + conf.cssvar.replace(/[^a-zA-Z0-9\\\\-]/g, \"\"));\n\nexport function createScope(scope: string): CSSResult {\n return joinScope(conf.tag(scope));\n}\n\nfunction joinScope(s: string) {\n return unsafeCSS(cssvar + scopeString + s);\n}\n\nexport const cssvarValues = {\n cssvar,\n input: joinScope(\"input\"),\n main: joinScope(\"background\"),\n text: joinScope(\"foreground\"),\n mainRGB: joinScope(\"background-rgb\"),\n textRGB: joinScope(\"foreground-rgb\"),\n};\n\nGodownElement.conf = conf;\n\nGodownElement.styles = [\n css`\n :host {\n ${cssvar}--background-rgb: 12 12 12;\n ${cssvar}--background: rgb(var(${cssvarValues.mainRGB}));\n ${cssvar}--foreground-rgb: 240 240 240;\n ${cssvar}--foreground: rgb(var(${cssvarValues.textRGB}));\n ${cssvar}--clip-background:linear-gradient(180deg, var(${cssvarValues.text}), rgb(var(${cssvarValues.textRGB}) / 68%));\n ${cssvar}--size: 100%;\n ${cssvar}--accept: rgb(25 130 180);\n font-size: var(${cssvar}--size);\n }\n `,\n css`\n :host {\n ${cssvarValues.input}--width: 10em;\n ${cssvarValues.input}--height: 1.6em;\n ${cssvarValues.input}--background: var(${cssvarValues.main});\n ${cssvarValues.input}--true: rgb(48 132 240);\n ${cssvarValues.input}--false: rgb(198 198 198);\n ${cssvarValues.input}--control:var(${cssvarValues.text});\n ${cssvarValues.input}--control-edge: var(${cssvarValues.input}--true);\n ${cssvarValues.input}--outline-color: var(${cssvar}--accept);\n ${cssvarValues.input}--outline-width: .15em;\n ${cssvarValues.input}--outline-style: solid;\n ${cssvarValues.input}--outline: var(${cssvarValues.input}--outline-width) var(${cssvarValues.input}--outline-style) var(${cssvarValues.input}--outline-color);\n ${cssvarValues.input}--radius: 0.2em;\n }\n `,\n css`\n * {\n font-size: 100%;\n font-style: normal;\n color: inherit;\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n border: 0;\n outline: 0;\n text-decoration: none;\n }\n\n ::selection {\n ${cssvar}--text-selection--color: inherit;\n ${cssvar}--text-selection--background: none;\n color: var(${cssvar}--text-selection--color);\n background: var(${cssvar}--text-selection--background);\n }\n `,\n] as CSSResultGroup;\n\nexport { GodownElement };\nexport default GodownElement;\n"]}
|
package/tabs.d.ts
DELETED
package/tabs.d.ts.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"tabs.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["tabs.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,+BAA+B,CAAC"}
|
package/tabs.js
DELETED
package/tabs.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"tabs.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["tabs.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,+BAA+B,CAAC","sourcesContent":["export { default } from \"./web-components/tabs/tabs.js\";\n"]}
|
package/web-components/a/a.d.ts
DELETED
@@ -1,16 +0,0 @@
|
|
1
|
-
import GodownAnchor from "../../supers/anchor.js";
|
2
|
-
/**
|
3
|
-
* {@linkcode A} similar to a.
|
4
|
-
*
|
5
|
-
* Has an optional arrow.
|
6
|
-
*/
|
7
|
-
export declare class A extends GodownAnchor {
|
8
|
-
}
|
9
|
-
export default A;
|
10
|
-
declare global {
|
11
|
-
interface HTMLElementTagNameMap {
|
12
|
-
"super-a": A;
|
13
|
-
"g-a": A;
|
14
|
-
}
|
15
|
-
}
|
16
|
-
//# sourceMappingURL=a.d.ts.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"a.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["web-components/a/a.ts"],"names":[],"mappings":"AACA,OAAO,YAAY,MAAM,wBAAwB,CAAC;AAIlD;;;;GAIG;AACH,qBACa,CAAE,SAAQ,YAAY;CAAG;AAEtC,eAAe,CAAC,CAAC;AAEjB,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,SAAS,EAAE,CAAC,CAAC;QACb,KAAK,EAAE,CAAC,CAAC;KACV;CACF"}
|
package/web-components/a/a.js
DELETED
@@ -1,17 +0,0 @@
|
|
1
|
-
import { __decorate } from "tslib";
|
2
|
-
import { define } from "../../decorators/define.js";
|
3
|
-
import GodownAnchor from "../../supers/anchor.js";
|
4
|
-
const defineName = "a";
|
5
|
-
/**
|
6
|
-
* {@linkcode A} similar to a.
|
7
|
-
*
|
8
|
-
* Has an optional arrow.
|
9
|
-
*/
|
10
|
-
let A = class A extends GodownAnchor {
|
11
|
-
};
|
12
|
-
A = __decorate([
|
13
|
-
define(defineName)
|
14
|
-
], A);
|
15
|
-
export { A };
|
16
|
-
export default A;
|
17
|
-
//# sourceMappingURL=a.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"a.js","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["web-components/a/a.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,4BAA4B,CAAC;AACpD,OAAO,YAAY,MAAM,wBAAwB,CAAC;AAElD,MAAM,UAAU,GAAG,GAAG,CAAC;AAEvB;;;;GAIG;AAEI,IAAM,CAAC,GAAP,MAAM,CAAE,SAAQ,YAAY;CAAG,CAAA;AAAzB,CAAC;IADb,MAAM,CAAC,UAAU,CAAC;GACN,CAAC,CAAwB;;AAEtC,eAAe,CAAC,CAAC","sourcesContent":["import { define } from \"../../decorators/define.js\";\nimport GodownAnchor from \"../../supers/anchor.js\";\n\nconst defineName = \"a\";\n\n/**\n * {@linkcode A} similar to a.\n *\n * Has an optional arrow.\n */\n@define(defineName)\nexport class A extends GodownAnchor {}\n\nexport default A;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n \"super-a\": A;\n \"g-a\": A;\n }\n}\n"]}
|
@@ -1,29 +0,0 @@
|
|
1
|
-
import { type HTMLTemplate } from "../../lib/templates.js";
|
2
|
-
import { GodownElement } from "../../supers/root.js";
|
3
|
-
import Avatar from "../avatar/avatar.js";
|
4
|
-
/**
|
5
|
-
* {@linkcode AvatarGroup} ensure that the display content does not exceed the maximum value, and display the excess quantity.
|
6
|
-
*/
|
7
|
-
export declare class AvatarGroup extends GodownElement {
|
8
|
-
/**
|
9
|
-
* The maximum number of elements that can be accepted for this element.
|
10
|
-
*/
|
11
|
-
max: number;
|
12
|
-
/**
|
13
|
-
* When the content overflows, create an {@linkcode Avatar} with the same {@linkcode Avatar.more} attribute as more.
|
14
|
-
*/
|
15
|
-
more: number;
|
16
|
-
static styles: import("lit").CSSResult[];
|
17
|
-
protected render(): HTMLTemplate;
|
18
|
-
protected firstUpdated(): void;
|
19
|
-
append(args?: Avatar): void;
|
20
|
-
subtract(): void;
|
21
|
-
}
|
22
|
-
export default AvatarGroup;
|
23
|
-
declare global {
|
24
|
-
interface HTMLElementTagNameMap {
|
25
|
-
"avatar-group": AvatarGroup;
|
26
|
-
"g-avatar-group": AvatarGroup;
|
27
|
-
}
|
28
|
-
}
|
29
|
-
//# sourceMappingURL=avatar-group.d.ts.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"avatar-group.d.ts","sourceRoot":"https://github.com/startracex/godown/tree/main/src/","sources":["web-components/group/avatar-group.ts"],"names":[],"mappings":"AAGA,OAAO,EAAuB,KAAK,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAEhF,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,MAAM,MAAM,qBAAqB,CAAC;AAIzC;;GAEG;AACH,qBACa,WAAY,SAAQ,aAAa;IAC5C;;OAEG;IACyB,GAAG,SAAM;IACrC;;OAEG;IACyB,IAAI,SAAK;IAErC,MAAM,CAAC,MAAM,4BAYX;IAEF,SAAS,CAAC,MAAM,IAAI,YAAY;IAKhC,SAAS,CAAC,YAAY;IAMtB,MAAM,CAAC,IAAI,SAAe;IAe1B,QAAQ;CAYT;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"}
|