@owlmeans/web-panel 0.1.18-rc.9 → 0.1.18
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 +510 -143
- package/THIRD-PARTY-NOTICES.txt +24 -0
- package/agent-meta/manifest.json +163 -4
- package/agent-meta/skills/web-panel/SKILL.md +136 -83
- package/agent-meta/skills/web-panel/parts/consent.md +114 -0
- package/agent-meta/skills/web-panel/parts/editor.md +47 -0
- package/agent-meta/skills/web-panel/parts/forms.md +85 -0
- package/agent-meta/skills/web-panel/parts/navigation.md +203 -0
- package/agent-meta/skills/web-panel/parts/picker.md +164 -0
- package/agent-meta/skills/web-panel/parts/reload.md +46 -0
- package/agent-meta/skills/web-panel/parts/sign-in.md +65 -0
- package/agent-meta/skills/web-panel/parts/theme.md +74 -0
- package/build/@/components/ui/alert-dialog.d.ts +15 -0
- package/build/@/components/ui/alert-dialog.d.ts.map +1 -0
- package/build/@/components/ui/alert-dialog.js +39 -0
- package/build/@/components/ui/alert-dialog.js.map +1 -0
- package/build/@/components/ui/alert.js +1 -1
- package/build/@/components/ui/alert.js.map +1 -1
- package/build/@/components/ui/button.js +1 -1
- package/build/@/components/ui/button.js.map +1 -1
- package/build/@/components/ui/card.js +1 -1
- package/build/@/components/ui/card.js.map +1 -1
- package/build/@/components/ui/input.js +1 -1
- package/build/@/components/ui/input.js.map +1 -1
- package/build/@/components/ui/label.js +1 -1
- package/build/@/components/ui/label.js.map +1 -1
- package/build/@/components/ui/navigation-menu.js +1 -1
- package/build/@/components/ui/navigation-menu.js.map +1 -1
- package/build/@/components/ui/popover.d.ts +8 -0
- package/build/@/components/ui/popover.d.ts.map +1 -0
- package/build/@/components/ui/popover.js +17 -0
- package/build/@/components/ui/popover.js.map +1 -0
- package/build/@/components/ui/progress.js +1 -1
- package/build/@/components/ui/progress.js.map +1 -1
- package/build/@/components/ui/separator.js +1 -1
- package/build/@/components/ui/separator.js.map +1 -1
- package/build/@/components/ui/sheet.d.ts +15 -0
- package/build/@/components/ui/sheet.d.ts.map +1 -0
- package/build/@/components/ui/sheet.js +40 -0
- package/build/@/components/ui/sheet.js.map +1 -0
- package/build/auth/context.d.ts.map +1 -1
- package/build/auth/context.js +0 -1
- package/build/auth/context.js.map +1 -1
- package/build/auth/entrypoints.d.ts +10 -0
- package/build/auth/entrypoints.d.ts.map +1 -0
- package/build/auth/entrypoints.js +4 -0
- package/build/auth/entrypoints.js.map +1 -0
- package/build/auth/exports.d.ts +4 -4
- package/build/auth/exports.d.ts.map +1 -1
- package/build/auth/exports.js +3 -3
- package/build/auth/exports.js.map +1 -1
- package/build/auth/modules.d.ts +1 -1
- package/build/auth/modules.d.ts.map +1 -1
- package/build/auth/plugins/basic-ed25519.js +4 -4
- package/build/auth/plugins/basic-ed25519.js.map +1 -1
- package/build/auth/plugins/re-captcha.js +3 -3
- package/build/auth/plugins/re-captcha.js.map +1 -1
- package/build/auth/plugins/tunnel-consumer.js +1 -1
- package/build/auth/plugins/tunnel-consumer.js.map +1 -1
- package/build/components/block.js +2 -2
- package/build/components/block.js.map +1 -1
- package/build/components/consts.local.d.ts +14 -0
- package/build/components/consts.local.d.ts.map +1 -0
- package/build/components/consts.local.js +26 -0
- package/build/components/consts.local.js.map +1 -0
- package/build/components/footer/component.d.ts +19 -1
- package/build/components/footer/component.d.ts.map +1 -1
- package/build/components/footer/component.js +38 -11
- package/build/components/footer/component.js.map +1 -1
- package/build/components/footer/credit.d.ts +27 -0
- package/build/components/footer/credit.d.ts.map +1 -0
- package/build/components/footer/credit.js +42 -0
- package/build/components/footer/credit.js.map +1 -0
- package/build/components/footer/index.d.ts +1 -0
- package/build/components/footer/index.d.ts.map +1 -1
- package/build/components/footer/index.js +1 -0
- package/build/components/footer/index.js.map +1 -1
- package/build/components/footer/types.d.ts +22 -1
- package/build/components/footer/types.d.ts.map +1 -1
- package/build/components/form/button/component.d.ts.map +1 -1
- package/build/components/form/button/component.js +5 -3
- package/build/components/form/button/component.js.map +1 -1
- package/build/components/form/component.js +2 -2
- package/build/components/form/component.js.map +1 -1
- package/build/components/form/text/component.js +2 -2
- package/build/components/form/text/component.js.map +1 -1
- package/build/components/helper.d.ts.map +1 -1
- package/build/components/helper.js +1 -12
- package/build/components/helper.js.map +1 -1
- package/build/components/index.d.ts +4 -0
- package/build/components/index.d.ts.map +1 -1
- package/build/components/index.js +4 -0
- package/build/components/index.js.map +1 -1
- package/build/components/link.js +3 -3
- package/build/components/link.js.map +1 -1
- package/build/components/login/append.d.ts +15 -0
- package/build/components/login/append.d.ts.map +1 -0
- package/build/components/login/append.js +26 -0
- package/build/components/login/append.js.map +1 -0
- package/build/components/login/consts.d.ts +3 -0
- package/build/components/login/consts.d.ts.map +1 -0
- package/build/components/login/consts.js +3 -0
- package/build/components/login/consts.js.map +1 -0
- package/build/components/login/consts.local.d.ts +4 -0
- package/build/components/login/consts.local.d.ts.map +1 -0
- package/build/components/login/consts.local.js +8 -0
- package/build/components/login/consts.local.js.map +1 -0
- package/build/components/login/credit.d.ts +12 -0
- package/build/components/login/credit.d.ts.map +1 -0
- package/build/components/login/credit.js +18 -0
- package/build/components/login/credit.js.map +1 -0
- package/build/components/login/i18n/be.json +10 -0
- package/build/components/login/i18n/de.json +10 -0
- package/build/components/login/i18n/en.json +10 -0
- package/build/components/login/i18n/es.json +10 -0
- package/build/components/login/i18n/fr.json +10 -0
- package/build/components/login/i18n/pl.json +10 -0
- package/build/components/login/i18n/ru.json +10 -0
- package/build/components/login/i18n/uk.json +10 -0
- package/build/components/login/i18n.d.ts +2 -0
- package/build/components/login/i18n.d.ts.map +1 -0
- package/build/components/login/i18n.js +28 -0
- package/build/components/login/i18n.js.map +1 -0
- package/build/components/login/icons.d.ts +14 -0
- package/build/components/login/icons.d.ts.map +1 -0
- package/build/components/login/icons.js +29 -0
- package/build/components/login/icons.js.map +1 -0
- package/build/components/login/index.d.ts +11 -0
- package/build/components/login/index.d.ts.map +1 -0
- package/build/components/login/index.js +10 -0
- package/build/components/login/index.js.map +1 -0
- package/build/components/login/notify.d.ts +18 -0
- package/build/components/login/notify.d.ts.map +1 -0
- package/build/components/login/notify.js +41 -0
- package/build/components/login/notify.js.map +1 -0
- package/build/components/login/provider.d.ts +20 -0
- package/build/components/login/provider.d.ts.map +1 -0
- package/build/components/login/provider.js +31 -0
- package/build/components/login/provider.js.map +1 -0
- package/build/components/login/screen.d.ts +24 -0
- package/build/components/login/screen.d.ts.map +1 -0
- package/build/components/login/screen.js +92 -0
- package/build/components/login/screen.js.map +1 -0
- package/build/components/login/terms.d.ts +19 -0
- package/build/components/login/terms.d.ts.map +1 -0
- package/build/components/login/terms.js +32 -0
- package/build/components/login/terms.js.map +1 -0
- package/build/components/login/types.d.ts +28 -0
- package/build/components/login/types.d.ts.map +1 -0
- package/build/components/login/types.js +2 -0
- package/build/components/login/types.js.map +1 -0
- package/build/components/nav/consts.local.d.ts +41 -0
- package/build/components/nav/consts.local.d.ts.map +1 -0
- package/build/components/nav/consts.local.js +60 -0
- package/build/components/nav/consts.local.js.map +1 -0
- package/build/components/nav/index.d.ts +1 -0
- package/build/components/nav/index.d.ts.map +1 -1
- package/build/components/nav/index.js +1 -0
- package/build/components/nav/index.js.map +1 -1
- package/build/components/nav/layout.d.ts +9 -2
- package/build/components/nav/layout.d.ts.map +1 -1
- package/build/components/nav/layout.js +48 -7
- package/build/components/nav/layout.js.map +1 -1
- package/build/components/nav/mobile.d.ts +21 -0
- package/build/components/nav/mobile.d.ts.map +1 -0
- package/build/components/nav/mobile.js +55 -0
- package/build/components/nav/mobile.js.map +1 -0
- package/build/components/nav/side.d.ts.map +1 -1
- package/build/components/nav/side.js +10 -10
- package/build/components/nav/side.js.map +1 -1
- package/build/components/nav/top.d.ts.map +1 -1
- package/build/components/nav/top.js +12 -8
- package/build/components/nav/top.js.map +1 -1
- package/build/components/nav/types.d.ts +64 -1
- package/build/components/nav/types.d.ts.map +1 -1
- package/build/components/nav/viewport.d.ts +3 -0
- package/build/components/nav/viewport.d.ts.map +1 -0
- package/build/components/nav/viewport.js +14 -0
- package/build/components/nav/viewport.js.map +1 -0
- package/build/components/panel-app/component.d.ts.map +1 -1
- package/build/components/panel-app/component.js +4 -3
- package/build/components/panel-app/component.js.map +1 -1
- package/build/components/picker/color-picker.d.ts +9 -0
- package/build/components/picker/color-picker.d.ts.map +1 -0
- package/build/components/picker/color-picker.js +9 -0
- package/build/components/picker/color-picker.js.map +1 -0
- package/build/components/picker/consts.local.d.ts +76 -0
- package/build/components/picker/consts.local.d.ts.map +1 -0
- package/build/components/picker/consts.local.js +214 -0
- package/build/components/picker/consts.local.js.map +1 -0
- package/build/components/picker/dot.d.ts +8 -0
- package/build/components/picker/dot.d.ts.map +1 -0
- package/build/components/picker/dot.js +10 -0
- package/build/components/picker/dot.js.map +1 -0
- package/build/components/picker/grid.d.ts +17 -0
- package/build/components/picker/grid.d.ts.map +1 -0
- package/build/components/picker/grid.js +73 -0
- package/build/components/picker/grid.js.map +1 -0
- package/build/components/picker/i18n/be.json +60 -0
- package/build/components/picker/i18n/de.json +60 -0
- package/build/components/picker/i18n/en.json +60 -0
- package/build/components/picker/i18n/es.json +60 -0
- package/build/components/picker/i18n/fr.json +60 -0
- package/build/components/picker/i18n/pl.json +60 -0
- package/build/components/picker/i18n/ru.json +60 -0
- package/build/components/picker/i18n/uk.json +60 -0
- package/build/components/picker/i18n.d.ts +2 -0
- package/build/components/picker/i18n.d.ts.map +1 -0
- package/build/components/picker/i18n.js +18 -0
- package/build/components/picker/i18n.js.map +1 -0
- package/build/components/picker/icon-color-picker.d.ts +14 -0
- package/build/components/picker/icon-color-picker.d.ts.map +1 -0
- package/build/components/picker/icon-color-picker.js +15 -0
- package/build/components/picker/icon-color-picker.js.map +1 -0
- package/build/components/picker/icon-picker.d.ts +8 -0
- package/build/components/picker/icon-picker.d.ts.map +1 -0
- package/build/components/picker/icon-picker.js +8 -0
- package/build/components/picker/icon-picker.js.map +1 -0
- package/build/components/picker/index.d.ts +11 -0
- package/build/components/picker/index.d.ts.map +1 -0
- package/build/components/picker/index.js +10 -0
- package/build/components/picker/index.js.map +1 -0
- package/build/components/picker/panel.d.ts +9 -0
- package/build/components/picker/panel.d.ts.map +1 -0
- package/build/components/picker/panel.js +23 -0
- package/build/components/picker/panel.js.map +1 -0
- package/build/components/picker/root.d.ts +13 -0
- package/build/components/picker/root.d.ts.map +1 -0
- package/build/components/picker/root.js +55 -0
- package/build/components/picker/root.js.map +1 -0
- package/build/components/picker/roving.d.ts +8 -0
- package/build/components/picker/roving.d.ts.map +1 -0
- package/build/components/picker/roving.js +62 -0
- package/build/components/picker/roving.js.map +1 -0
- package/build/components/picker/surface.d.ts +18 -0
- package/build/components/picker/surface.d.ts.map +1 -0
- package/build/components/picker/surface.js +36 -0
- package/build/components/picker/surface.js.map +1 -0
- package/build/components/picker/swatches/custom.d.ts +10 -0
- package/build/components/picker/swatches/custom.d.ts.map +1 -0
- package/build/components/picker/swatches/custom.js +65 -0
- package/build/components/picker/swatches/custom.js.map +1 -0
- package/build/components/picker/swatches.d.ts +16 -0
- package/build/components/picker/swatches.d.ts.map +1 -0
- package/build/components/picker/swatches.js +35 -0
- package/build/components/picker/swatches.js.map +1 -0
- package/build/components/picker/text.d.ts +5 -0
- package/build/components/picker/text.d.ts.map +1 -0
- package/build/components/picker/text.js +29 -0
- package/build/components/picker/text.js.map +1 -0
- package/build/components/picker/tile.d.ts +11 -0
- package/build/components/picker/tile.d.ts.map +1 -0
- package/build/components/picker/tile.js +19 -0
- package/build/components/picker/tile.js.map +1 -0
- package/build/components/picker/translate.d.ts +9 -0
- package/build/components/picker/translate.d.ts.map +1 -0
- package/build/components/picker/translate.js +13 -0
- package/build/components/picker/translate.js.map +1 -0
- package/build/components/picker/trigger.d.ts +12 -0
- package/build/components/picker/trigger.d.ts.map +1 -0
- package/build/components/picker/trigger.js +29 -0
- package/build/components/picker/trigger.js.map +1 -0
- package/build/components/picker/types.d.ts +114 -0
- package/build/components/picker/types.d.ts.map +1 -0
- package/build/components/picker/types.js +2 -0
- package/build/components/picker/types.js.map +1 -0
- package/build/components/picker/types.local.d.ts +143 -0
- package/build/components/picker/types.local.d.ts.map +1 -0
- package/build/components/picker/types.local.js +2 -0
- package/build/components/picker/types.local.js.map +1 -0
- package/build/components/scheme/consts.local.d.ts +8 -0
- package/build/components/scheme/consts.local.d.ts.map +1 -0
- package/build/components/scheme/consts.local.js +13 -0
- package/build/components/scheme/consts.local.js.map +1 -0
- package/build/components/scheme/hook.d.ts +16 -0
- package/build/components/scheme/hook.d.ts.map +1 -0
- package/build/components/scheme/hook.js +52 -0
- package/build/components/scheme/hook.js.map +1 -0
- package/build/components/scheme/index.d.ts +4 -0
- package/build/components/scheme/index.d.ts.map +1 -0
- package/build/components/scheme/index.js +3 -0
- package/build/components/scheme/index.js.map +1 -0
- package/build/components/scheme/toggle.d.ts +14 -0
- package/build/components/scheme/toggle.d.ts.map +1 -0
- package/build/components/scheme/toggle.js +24 -0
- package/build/components/scheme/toggle.js.map +1 -0
- package/build/components/scheme/types.d.ts +21 -0
- package/build/components/scheme/types.d.ts.map +1 -0
- package/build/components/scheme/types.js +2 -0
- package/build/components/scheme/types.js.map +1 -0
- package/build/components/socket/i18n/be.json +9 -0
- package/build/components/socket/i18n/de.json +9 -0
- package/build/components/socket/i18n/en.json +9 -0
- package/build/components/socket/i18n/es.json +9 -0
- package/build/components/socket/i18n/fr.json +9 -0
- package/build/components/socket/i18n/pl.json +9 -0
- package/build/components/socket/i18n/ru.json +9 -0
- package/build/components/socket/i18n/uk.json +9 -0
- package/build/components/socket/i18n.d.ts +2 -0
- package/build/components/socket/i18n.d.ts.map +1 -0
- package/build/components/socket/i18n.js +18 -0
- package/build/components/socket/i18n.js.map +1 -0
- package/build/components/socket/index.d.ts +3 -0
- package/build/components/socket/index.d.ts.map +1 -0
- package/build/components/socket/index.js +3 -0
- package/build/components/socket/index.js.map +1 -0
- package/build/components/socket/reload-dialog.d.ts +22 -0
- package/build/components/socket/reload-dialog.d.ts.map +1 -0
- package/build/components/socket/reload-dialog.js +34 -0
- package/build/components/socket/reload-dialog.js.map +1 -0
- package/build/components/status.js +1 -1
- package/build/components/status.js.map +1 -1
- package/build/components/text.d.ts.map +1 -1
- package/build/components/text.js +2 -13
- package/build/components/text.js.map +1 -1
- package/build/components/toaster.d.ts +16 -0
- package/build/components/toaster.d.ts.map +1 -0
- package/build/components/toaster.js +52 -0
- package/build/components/toaster.js.map +1 -0
- package/build/components/uploader/consts.local.d.ts +4 -0
- package/build/components/uploader/consts.local.d.ts.map +1 -0
- package/build/components/uploader/consts.local.js +6 -0
- package/build/components/uploader/consts.local.js.map +1 -0
- package/build/components/uploader/image.d.ts.map +1 -1
- package/build/components/uploader/image.js +2 -6
- package/build/components/uploader/image.js.map +1 -1
- package/build/consent/component.d.ts +27 -0
- package/build/consent/component.d.ts.map +1 -0
- package/build/consent/component.js +60 -0
- package/build/consent/component.js.map +1 -0
- package/build/consent/consts.d.ts +2 -0
- package/build/consent/consts.d.ts.map +1 -0
- package/build/consent/consts.js +2 -0
- package/build/consent/consts.js.map +1 -0
- package/build/consent/consts.local.d.ts +9 -0
- package/build/consent/consts.local.d.ts.map +1 -0
- package/build/consent/consts.local.js +9 -0
- package/build/consent/consts.local.js.map +1 -0
- package/build/consent/geo.d.ts +17 -0
- package/build/consent/geo.d.ts.map +1 -0
- package/build/consent/geo.js +19 -0
- package/build/consent/geo.js.map +1 -0
- package/build/consent/index.d.ts +11 -0
- package/build/consent/index.d.ts.map +1 -0
- package/build/consent/index.js +9 -0
- package/build/consent/index.js.map +1 -0
- package/build/consent/language.d.ts +12 -0
- package/build/consent/language.d.ts.map +1 -0
- package/build/consent/language.js +11 -0
- package/build/consent/language.js.map +1 -0
- package/build/consent/menu-widget.d.ts +13 -0
- package/build/consent/menu-widget.d.ts.map +1 -0
- package/build/consent/menu-widget.js +20 -0
- package/build/consent/menu-widget.js.map +1 -0
- package/build/consent/presence.d.ts +30 -0
- package/build/consent/presence.d.ts.map +1 -0
- package/build/consent/presence.js +40 -0
- package/build/consent/presence.js.map +1 -0
- package/build/consent/service.d.ts +18 -0
- package/build/consent/service.d.ts.map +1 -0
- package/build/consent/service.js +53 -0
- package/build/consent/service.js.map +1 -0
- package/build/consent/translate.d.ts +14 -0
- package/build/consent/translate.d.ts.map +1 -0
- package/build/consent/translate.js +28 -0
- package/build/consent/translate.js.map +1 -0
- package/build/consent/types.d.ts +39 -0
- package/build/consent/types.d.ts.map +1 -0
- package/build/consent/types.js +2 -0
- package/build/consent/types.js.map +1 -0
- package/build/consent/types.local.d.ts +6 -0
- package/build/consent/types.local.d.ts.map +1 -0
- package/build/consent/types.local.js +2 -0
- package/build/consent/types.local.js.map +1 -0
- package/build/context.d.ts.map +1 -1
- package/build/context.js +10 -0
- package/build/context.js.map +1 -1
- package/build/editor/component.d.ts +4 -0
- package/build/editor/component.d.ts.map +1 -0
- package/build/editor/component.js +103 -0
- package/build/editor/component.js.map +1 -0
- package/build/editor/consts.local.d.ts +6 -0
- package/build/editor/consts.local.d.ts.map +1 -0
- package/build/editor/consts.local.js +58 -0
- package/build/editor/consts.local.js.map +1 -0
- package/build/editor/index.d.ts +3 -0
- package/build/editor/index.d.ts.map +1 -0
- package/build/editor/index.js +2 -0
- package/build/editor/index.js.map +1 -0
- package/build/editor/types.d.ts +24 -0
- package/build/editor/types.d.ts.map +1 -0
- package/build/editor/types.js +2 -0
- package/build/editor/types.js.map +1 -0
- package/build/entrypoints.d.ts +8 -0
- package/build/entrypoints.d.ts.map +1 -0
- package/build/entrypoints.js +4 -0
- package/build/entrypoints.js.map +1 -0
- package/build/exports.d.ts +6 -5
- package/build/exports.d.ts.map +1 -1
- package/build/exports.js +5 -5
- package/build/exports.js.map +1 -1
- package/build/index.d.ts +1 -1
- package/build/index.d.ts.map +1 -1
- package/build/index.js +1 -1
- package/build/index.js.map +1 -1
- package/build/main.d.ts +1 -4
- package/build/main.d.ts.map +1 -1
- package/build/main.js.map +1 -1
- package/build/modules.d.ts +1 -1
- package/build/modules.d.ts.map +1 -1
- package/build/permission/i18n/be.json +13 -0
- package/build/permission/i18n/de.json +13 -0
- package/build/permission/i18n/en.json +13 -0
- package/build/permission/i18n/es.json +13 -0
- package/build/permission/i18n/fr.json +13 -0
- package/build/permission/i18n/pl.json +13 -0
- package/build/permission/i18n/ru.json +13 -0
- package/build/permission/i18n/uk.json +13 -0
- package/build/permission/i18n.d.ts +2 -0
- package/build/permission/i18n.d.ts.map +1 -0
- package/build/permission/i18n.js +13 -0
- package/build/permission/i18n.js.map +1 -0
- package/build/permission/index.d.ts +6 -0
- package/build/permission/index.d.ts.map +1 -0
- package/build/permission/index.js +27 -0
- package/build/permission/index.js.map +1 -0
- package/build/permission/toast.d.ts +5 -0
- package/build/permission/toast.d.ts.map +1 -0
- package/build/permission/toast.js +8 -0
- package/build/permission/toast.js.map +1 -0
- package/build/permission/types.d.ts +6 -0
- package/build/permission/types.d.ts.map +1 -0
- package/build/permission/types.js +2 -0
- package/build/permission/types.js.map +1 -0
- package/build/picker/icons/consts.d.ts +9 -0
- package/build/picker/icons/consts.d.ts.map +1 -0
- package/build/picker/icons/consts.js +264 -0
- package/build/picker/icons/consts.js.map +1 -0
- package/build/picker/icons/types.d.ts +18 -0
- package/build/picker/icons/types.d.ts.map +1 -0
- package/build/picker/icons/types.js +2 -0
- package/build/picker/icons/types.js.map +1 -0
- package/build/picker/icons.d.ts +4 -0
- package/build/picker/icons.d.ts.map +1 -0
- package/build/picker/icons.js +54 -0
- package/build/picker/icons.js.map +1 -0
- package/build/picker/index.d.ts +11 -0
- package/build/picker/index.d.ts.map +1 -0
- package/build/picker/index.js +10 -0
- package/build/picker/index.js.map +1 -0
- package/build/picker/utils/color/types.d.ts +35 -0
- package/build/picker/utils/color/types.d.ts.map +1 -0
- package/build/picker/utils/color/types.js +2 -0
- package/build/picker/utils/color/types.js.map +1 -0
- package/build/picker/utils/color.d.ts +4 -0
- package/build/picker/utils/color.d.ts.map +1 -0
- package/build/picker/utils/color.js +96 -0
- package/build/picker/utils/color.js.map +1 -0
- package/build/picker/vocabulary/consts.d.ts +26 -0
- package/build/picker/vocabulary/consts.d.ts.map +1 -0
- package/build/picker/vocabulary/consts.js +336 -0
- package/build/picker/vocabulary/consts.js.map +1 -0
- package/build/picker/vocabulary/types.d.ts +67 -0
- package/build/picker/vocabulary/types.d.ts.map +1 -0
- package/build/picker/vocabulary/types.js +2 -0
- package/build/picker/vocabulary/types.js.map +1 -0
- package/build/picker/vocabulary.d.ts +11 -0
- package/build/picker/vocabulary.d.ts.map +1 -0
- package/build/picker/vocabulary.js +83 -0
- package/build/picker/vocabulary.js.map +1 -0
- package/build/scheme/consts.d.ts +8 -0
- package/build/scheme/consts.d.ts.map +1 -0
- package/build/scheme/consts.js +8 -0
- package/build/scheme/consts.js.map +1 -0
- package/build/scheme/index.d.ts +4 -0
- package/build/scheme/index.d.ts.map +1 -0
- package/build/scheme/index.js +3 -0
- package/build/scheme/index.js.map +1 -0
- package/build/scheme/scheme.d.ts +16 -0
- package/build/scheme/scheme.d.ts.map +1 -0
- package/build/scheme/scheme.js +58 -0
- package/build/scheme/scheme.js.map +1 -0
- package/build/scheme/types.d.ts +30 -0
- package/build/scheme/types.d.ts.map +1 -0
- package/build/scheme/types.js +2 -0
- package/build/scheme/types.js.map +1 -0
- package/build/types.d.ts +18 -2
- package/build/types.d.ts.map +1 -1
- package/package.json +107 -52
- package/src/@/components/ui/alert-dialog.tsx +156 -0
- package/src/@/components/ui/alert.tsx +1 -1
- package/src/@/components/ui/button.tsx +1 -1
- package/src/@/components/ui/card.tsx +1 -1
- package/src/@/components/ui/input.tsx +1 -1
- package/src/@/components/ui/label.tsx +1 -1
- package/src/@/components/ui/navigation-menu.tsx +1 -1
- package/src/@/components/ui/popover.tsx +47 -0
- package/src/@/components/ui/progress.tsx +1 -1
- package/src/@/components/ui/separator.tsx +1 -1
- package/src/@/components/ui/sheet.tsx +142 -0
- package/src/auth/context.ts +0 -2
- package/src/auth/entrypoints.ts +5 -0
- package/src/auth/exports.ts +4 -4
- package/src/auth/plugins/basic-ed25519.tsx +4 -4
- package/src/auth/plugins/re-captcha.tsx +3 -3
- package/src/auth/plugins/tunnel-consumer.tsx +1 -1
- package/src/components/block.tsx +2 -2
- package/src/components/consts.local.ts +29 -0
- package/src/components/footer/component.tsx +58 -16
- package/src/components/footer/credit.tsx +61 -0
- package/src/components/footer/index.ts +1 -0
- package/src/components/footer/types.ts +22 -1
- package/src/components/form/button/component.tsx +7 -4
- package/src/components/form/component.tsx +2 -2
- package/src/components/form/text/component.tsx +2 -2
- package/src/components/helper.ts +1 -13
- package/src/components/index.ts +4 -0
- package/src/components/link.tsx +3 -3
- package/src/components/login/append.ts +34 -0
- package/src/components/login/consts.local.ts +10 -0
- package/src/components/login/consts.ts +2 -0
- package/src/components/login/credit.tsx +33 -0
- package/src/components/login/i18n/be.json +10 -0
- package/src/components/login/i18n/de.json +10 -0
- package/src/components/login/i18n/en.json +10 -0
- package/src/components/login/i18n/es.json +10 -0
- package/src/components/login/i18n/fr.json +10 -0
- package/src/components/login/i18n/pl.json +10 -0
- package/src/components/login/i18n/ru.json +10 -0
- package/src/components/login/i18n/uk.json +10 -0
- package/src/components/login/i18n.ts +29 -0
- package/src/components/login/icons.tsx +39 -0
- package/src/components/login/index.ts +11 -0
- package/src/components/login/notify.ts +48 -0
- package/src/components/login/provider.tsx +57 -0
- package/src/components/login/screen.tsx +178 -0
- package/src/components/login/terms.tsx +75 -0
- package/src/components/login/types.ts +30 -0
- package/src/components/nav/consts.local.ts +64 -0
- package/src/components/nav/index.ts +1 -0
- package/src/components/nav/layout.tsx +184 -26
- package/src/components/nav/mobile.tsx +165 -0
- package/src/components/nav/side.tsx +43 -27
- package/src/components/nav/top.tsx +44 -22
- package/src/components/nav/types.ts +65 -2
- package/src/components/nav/viewport.ts +16 -0
- package/src/components/panel-app/component.tsx +9 -1
- package/src/components/picker/color-picker.tsx +15 -0
- package/src/components/picker/consts.local.ts +267 -0
- package/src/components/picker/dot.tsx +21 -0
- package/src/components/picker/grid.tsx +138 -0
- package/src/components/picker/i18n/be.json +60 -0
- package/src/components/picker/i18n/de.json +60 -0
- package/src/components/picker/i18n/en.json +60 -0
- package/src/components/picker/i18n/es.json +60 -0
- package/src/components/picker/i18n/fr.json +60 -0
- package/src/components/picker/i18n/pl.json +60 -0
- package/src/components/picker/i18n/ru.json +60 -0
- package/src/components/picker/i18n/uk.json +60 -0
- package/src/components/picker/i18n.ts +19 -0
- package/src/components/picker/icon-color-picker.tsx +25 -0
- package/src/components/picker/icon-picker.tsx +13 -0
- package/src/components/picker/index.ts +11 -0
- package/src/components/picker/panel.tsx +61 -0
- package/src/components/picker/root.tsx +81 -0
- package/src/components/picker/roving.ts +70 -0
- package/src/components/picker/surface.tsx +62 -0
- package/src/components/picker/swatches/custom.tsx +110 -0
- package/src/components/picker/swatches.tsx +67 -0
- package/src/components/picker/text.ts +46 -0
- package/src/components/picker/tile.tsx +35 -0
- package/src/components/picker/translate.ts +15 -0
- package/src/components/picker/trigger.tsx +54 -0
- package/src/components/picker/types.local.ts +154 -0
- package/src/components/picker/types.ts +125 -0
- package/src/components/scheme/consts.local.ts +13 -0
- package/src/components/scheme/hook.ts +62 -0
- package/src/components/scheme/index.ts +4 -0
- package/src/components/scheme/toggle.tsx +32 -0
- package/src/components/scheme/types.ts +23 -0
- package/src/components/socket/i18n/be.json +9 -0
- package/src/components/socket/i18n/de.json +9 -0
- package/src/components/socket/i18n/en.json +9 -0
- package/src/components/socket/i18n/es.json +9 -0
- package/src/components/socket/i18n/fr.json +9 -0
- package/src/components/socket/i18n/pl.json +9 -0
- package/src/components/socket/i18n/ru.json +9 -0
- package/src/components/socket/i18n/uk.json +9 -0
- package/src/components/socket/i18n.ts +19 -0
- package/src/components/socket/index.ts +2 -0
- package/src/components/socket/reload-dialog.tsx +61 -0
- package/src/components/status.tsx +1 -1
- package/src/components/text.tsx +2 -14
- package/src/components/toaster.tsx +65 -0
- package/src/components/uploader/consts.local.ts +7 -0
- package/src/components/uploader/image.tsx +2 -6
- package/src/consent/component.tsx +84 -0
- package/src/consent/consts.local.ts +10 -0
- package/src/consent/consts.ts +1 -0
- package/src/consent/geo.ts +26 -0
- package/src/consent/index.ts +24 -0
- package/src/consent/language.ts +12 -0
- package/src/consent/menu-widget.tsx +22 -0
- package/src/consent/presence.ts +45 -0
- package/src/consent/service.ts +75 -0
- package/src/consent/translate.ts +31 -0
- package/src/consent/types.local.ts +6 -0
- package/src/consent/types.ts +43 -0
- package/src/context.ts +12 -0
- package/src/editor/component.tsx +172 -0
- package/src/editor/consts.local.ts +62 -0
- package/src/editor/index.ts +2 -0
- package/src/editor/types.ts +24 -0
- package/src/entrypoints.ts +5 -0
- package/src/exports.ts +6 -5
- package/src/index.ts +1 -1
- package/src/main.tsx +2 -6
- package/src/permission/i18n/be.json +13 -0
- package/src/permission/i18n/de.json +13 -0
- package/src/permission/i18n/en.json +13 -0
- package/src/permission/i18n/es.json +13 -0
- package/src/permission/i18n/fr.json +13 -0
- package/src/permission/i18n/pl.json +13 -0
- package/src/permission/i18n/ru.json +13 -0
- package/src/permission/i18n/uk.json +13 -0
- package/src/permission/i18n.ts +13 -0
- package/src/permission/index.ts +27 -0
- package/src/permission/toast.tsx +20 -0
- package/src/permission/types.ts +5 -0
- package/src/picker/icons/consts.ts +309 -0
- package/src/picker/icons/types.ts +18 -0
- package/src/picker/icons.ts +70 -0
- package/src/picker/index.ts +11 -0
- package/src/picker/utils/color/types.ts +37 -0
- package/src/picker/utils/color.ts +119 -0
- package/src/picker/vocabulary/consts.ts +347 -0
- package/src/picker/vocabulary/types.ts +72 -0
- package/src/picker/vocabulary.ts +111 -0
- package/src/scheme/consts.ts +8 -0
- package/src/scheme/index.ts +3 -0
- package/src/scheme/scheme.ts +66 -0
- package/src/scheme/types.ts +30 -0
- package/src/types.ts +19 -2
- package/tests/consent-language.spec.ts +31 -0
- package/tests/consent.spec.ts +112 -0
- package/tests/context.ts +4 -0
- package/tests/editor.spec.ts +58 -0
- package/tests/harness/editor.tsx +32 -0
- package/tests/harness/index.html +1 -0
- package/tests/harness/lazy-screen.tsx +9 -0
- package/tests/harness/mount.tsx +370 -29
- package/tests/harness/picker.tsx +110 -0
- package/tests/lazy.spec.ts +104 -0
- package/tests/login-provider.spec.ts +114 -0
- package/tests/login.spec.ts +447 -0
- package/tests/nav.spec.ts +449 -3
- package/tests/package-boundary.spec.ts +19 -0
- package/tests/picker-shots.spec.ts +174 -0
- package/tests/picker-vocabulary.spec.ts +217 -0
- package/tests/picker.spec.ts +333 -0
- package/tests/scheme.spec.ts +149 -0
- package/tests/smoke.spec.ts +2 -2
- package/tests/socket-dialog.spec.ts +154 -0
- package/tests/toaster.spec.ts +59 -0
- package/zz-tw.d.mts +2 -0
- package/zz-tw.d.mts.map +1 -0
- package/build/.gitkeep +0 -0
- package/src/auth/modules.ts +0 -5
- package/src/modules.ts +0 -5
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { ColorSchemeChoice } from '../../scheme/types.js';
|
|
2
|
+
import type { StyledProps } from '../types.js';
|
|
3
|
+
export interface ColorSchemeModel {
|
|
4
|
+
/** What the page is showing: the stored choice, or the operating system's preference. */
|
|
5
|
+
scheme: 'light' | 'dark';
|
|
6
|
+
/** The visitor's explicit choice, or `null` while the page follows the operating system. */
|
|
7
|
+
choice: ColorSchemeChoice | null;
|
|
8
|
+
/** Choose — `null` clears the choice and hands the page back to the operating system. */
|
|
9
|
+
setChoice: (choice: ColorSchemeChoice | null) => void;
|
|
10
|
+
}
|
|
11
|
+
/** The toggle's accessible names — what pressing it DOES. English defaults when absent. */
|
|
12
|
+
export interface ThemeToggleLabels {
|
|
13
|
+
/** Shown while the page is dark. Default "Switch to light mode". */
|
|
14
|
+
toLight?: string;
|
|
15
|
+
/** Shown while the page is light. Default "Switch to dark mode". */
|
|
16
|
+
toDark?: string;
|
|
17
|
+
}
|
|
18
|
+
export interface ThemeToggleProps extends StyledProps {
|
|
19
|
+
labels?: ThemeToggleLabels;
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/scheme/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAA;AAC9D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,aAAa,CAAA;AAE9C,MAAM,WAAW,gBAAgB;IAC/B,yFAAyF;IACzF,MAAM,EAAE,OAAO,GAAG,MAAM,CAAA;IACxB,4FAA4F;IAC5F,MAAM,EAAE,iBAAiB,GAAG,IAAI,CAAA;IAChC,yFAAyF;IACzF,SAAS,EAAE,CAAC,MAAM,EAAE,iBAAiB,GAAG,IAAI,KAAK,IAAI,CAAA;CACtD;AAED,2FAA2F;AAC3F,MAAM,WAAW,iBAAiB;IAChC,oEAAoE;IACpE,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,oEAAoE;IACpE,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB;AAED,MAAM,WAAW,gBAAiB,SAAQ,WAAW;IACnD,MAAM,CAAC,EAAE,iBAAiB,CAAA;CAC3B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/components/scheme/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
{
|
|
2
|
+
"reload": {
|
|
3
|
+
"title": "Злучэнне страчана",
|
|
4
|
+
"description": "Не ўдалося аднавіць злучэнне пасля некалькіх спробаў. Паспрабуйце яшчэ раз або перазагрузіце старонку, каб працягнуць.",
|
|
5
|
+
"action": "Перазагрузіць старонку",
|
|
6
|
+
"retry": "Паспрабаваць яшчэ раз",
|
|
7
|
+
"retrying": "Паўторнае падключэнне…"
|
|
8
|
+
}
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
{
|
|
2
|
+
"reload": {
|
|
3
|
+
"title": "Verbindung verloren",
|
|
4
|
+
"description": "Die Verbindung konnte nach mehreren Versuchen nicht wiederhergestellt werden. Versuche es erneut oder lade die Seite neu, um fortzufahren.",
|
|
5
|
+
"action": "Seite neu laden",
|
|
6
|
+
"retry": "Erneut versuchen",
|
|
7
|
+
"retrying": "Verbindung wird wiederhergestellt…"
|
|
8
|
+
}
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
{
|
|
2
|
+
"reload": {
|
|
3
|
+
"title": "Conexión perdida",
|
|
4
|
+
"description": "No se pudo restablecer la conexión tras varios intentos. Vuelve a intentarlo o recarga la página para continuar.",
|
|
5
|
+
"action": "Recargar página",
|
|
6
|
+
"retry": "Reintentar",
|
|
7
|
+
"retrying": "Reconectando…"
|
|
8
|
+
}
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
{
|
|
2
|
+
"reload": {
|
|
3
|
+
"title": "Connexion perdue",
|
|
4
|
+
"description": "Nous n’avons pas pu rétablir la connexion après plusieurs tentatives. Réessayez ou actualisez la page pour continuer.",
|
|
5
|
+
"action": "Actualiser la page",
|
|
6
|
+
"retry": "Réessayer",
|
|
7
|
+
"retrying": "Reconnexion…"
|
|
8
|
+
}
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
{
|
|
2
|
+
"reload": {
|
|
3
|
+
"title": "Utracono połączenie",
|
|
4
|
+
"description": "Nie udało się przywrócić połączenia mimo kilku prób. Spróbuj ponownie lub odśwież stronę, aby kontynuować.",
|
|
5
|
+
"action": "Odśwież stronę",
|
|
6
|
+
"retry": "Spróbuj ponownie",
|
|
7
|
+
"retrying": "Ponowne łączenie…"
|
|
8
|
+
}
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
{
|
|
2
|
+
"reload": {
|
|
3
|
+
"title": "Соединение потеряно",
|
|
4
|
+
"description": "Не удалось восстановить соединение после нескольких попыток. Попробуйте снова или перезагрузите страницу, чтобы продолжить.",
|
|
5
|
+
"action": "Перезагрузить страницу",
|
|
6
|
+
"retry": "Попробовать снова",
|
|
7
|
+
"retrying": "Переподключение…"
|
|
8
|
+
}
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
{
|
|
2
|
+
"reload": {
|
|
3
|
+
"title": "З'єднання втрачено",
|
|
4
|
+
"description": "Не вдалося відновити з'єднання після кількох спроб. Спробуйте ще раз або перезавантажте сторінку, щоб продовжити.",
|
|
5
|
+
"action": "Перезавантажити сторінку",
|
|
6
|
+
"retry": "Спробувати ще раз",
|
|
7
|
+
"retrying": "Перепідключення…"
|
|
8
|
+
}
|
|
9
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"i18n.d.ts","sourceRoot":"","sources":["../../../src/components/socket/i18n.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { i18nHelper } from '@owlmeans/i18n';
|
|
2
|
+
import en from './i18n/en.json' with { type: 'json' };
|
|
3
|
+
import pl from './i18n/pl.json' with { type: 'json' };
|
|
4
|
+
import ru from './i18n/ru.json' with { type: 'json' };
|
|
5
|
+
import be from './i18n/be.json' with { type: 'json' };
|
|
6
|
+
import uk from './i18n/uk.json' with { type: 'json' };
|
|
7
|
+
import es from './i18n/es.json' with { type: 'json' };
|
|
8
|
+
import de from './i18n/de.json' with { type: 'json' };
|
|
9
|
+
import fr from './i18n/fr.json' with { type: 'json' };
|
|
10
|
+
i18nHelper.addI18nLib('en', 'socket', en);
|
|
11
|
+
i18nHelper.addI18nLib('pl', 'socket', pl);
|
|
12
|
+
i18nHelper.addI18nLib('ru', 'socket', ru);
|
|
13
|
+
i18nHelper.addI18nLib('be', 'socket', be);
|
|
14
|
+
i18nHelper.addI18nLib('uk', 'socket', uk);
|
|
15
|
+
i18nHelper.addI18nLib('es', 'socket', es);
|
|
16
|
+
i18nHelper.addI18nLib('de', 'socket', de);
|
|
17
|
+
i18nHel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AAE,EAAE,CAAC,CAAA;AACzC,UAAU,CAAC,UAAU,CAAC,IAAI,EAAE,QAAQ,EAAE,EAAE,CAAC,CAAA;AACzC,UAAU,CAAC,UAAU,CAAC,IAAI,EAAE,QAAQ,EAAE,EAAE,CAAC,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/socket/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAA;AAClC,cAAc,WAAW,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/socket/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAA;AAClC,cAAc,WAAW,CAAA"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { FC } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* A global, blocking "connection lost" prompt — opt in per app with `cfg.socket.reloadDialog`.
|
|
4
|
+
*
|
|
5
|
+
* Mount it once, above the router (`PanelApp` does), exactly like `PanelCookieConsent`: a dialog
|
|
6
|
+
* mounted inside a route is torn down on every navigation, and this one is meant to survive them
|
|
7
|
+
* all. It opens the moment `useSocketStatus()` reports `'lost'` — every `ws()`/`useWs()`
|
|
8
|
+
* connection in the app has exhausted its own retry budget (10 minutes by default).
|
|
9
|
+
*
|
|
10
|
+
* Two exits: "Try again" revives every lost connection (`useSocketRetry()`), and the dialog stays
|
|
11
|
+
* up showing progress until they are back online — or offers both buttons again if they are lost
|
|
12
|
+
* again. "Reload page" is the fallback that always works. The status service also retries by
|
|
13
|
+
* itself when the tab or window becomes active, so a socket that died in a background tab is
|
|
14
|
+
* usually back before anyone has to press anything.
|
|
15
|
+
*
|
|
16
|
+
* Non-dismissible on two levels: Radix's `AlertDialogContent` (unlike its plain `Dialog` sibling)
|
|
17
|
+
* never treats an outside click as a request to close, so there is no `onPointerDownOutside` to
|
|
18
|
+
* override in the first place — and `open` is passed with no `onOpenChange` at all, so even the
|
|
19
|
+
* Escape key it does listen for (blocked below anyway) has no handler to call.
|
|
20
|
+
*/
|
|
21
|
+
export declare const SocketReloadDialog: FC;
|
|
22
|
+
//# sourceMappingURL=reload-dialog.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"reload-dialog.d.ts","sourceRoot":"","sources":["../../../src/components/socket/reload-dialog.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAA;AAS/B;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,kBAAkB,EAAE,EAgChC,CAAA"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { useSocketRetry, useSocketStatus } from '@owlmeans/client-socket';
|
|
3
|
+
import { useI18nLib } from '@owlmeans/client-i18n';
|
|
4
|
+
import { AlertDialog, AlertDialogAction, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogTitle } from '../../@/components/ui/alert-dialog.js';
|
|
5
|
+
import { Button } from '../../@/components/ui/button.js';
|
|
6
|
+
/**
|
|
7
|
+
* A global, blocking "connection lost" prompt — opt in per app with `cfg.socket.reloadDialog`.
|
|
8
|
+
*
|
|
9
|
+
* Mount it once, above the router (`PanelApp` does), exactly like `PanelCookieConsent`: a dialog
|
|
10
|
+
* mounted inside a route is torn down on every navigation, and this one is meant to survive them
|
|
11
|
+
* all. It opens the moment `useSocketStatus()` reports `'lost'` — every `ws()`/`useWs()`
|
|
12
|
+
* connection in the app has exhausted its own retry budget (10 minutes by default).
|
|
13
|
+
*
|
|
14
|
+
* Two exits: "Try again" revives every lost connection (`useSocketRetry()`), and the dialog stays
|
|
15
|
+
* up showing progress until they are back online — or offers both buttons again if they are lost
|
|
16
|
+
* again. "Reload page" is the fallback that always works. The status service also retries by
|
|
17
|
+
* itself when the tab or window becomes active, so a socket that died in a background tab is
|
|
18
|
+
* usually back before anyone has to press anything.
|
|
19
|
+
*
|
|
20
|
+
* Non-dismissible on two levels: Radix's `AlertDialogContent` (unlike its plain `Dialog` sibling)
|
|
21
|
+
* never treats an outside click as a request to close, so there is no `onPointerDownOutside` to
|
|
22
|
+
* override in the first place — and `open` is passed with no `onOpenChange` at all, so even the
|
|
23
|
+
* Escape key it does listen for (blocked below anyway) has no handler to call.
|
|
24
|
+
*/
|
|
25
|
+
export const SocketReloadDialog = () => {
|
|
26
|
+
const status = useSocketStatus();
|
|
27
|
+
const { retry, retrying } = useSocketRetry();
|
|
28
|
+
const t = useI18nLib('socket', 'reload');
|
|
29
|
+
const open = status === 'lost' || (retrying && status === 'reconnecting');
|
|
30
|
+
// Closing still animates the content out — keep the retry in its busy state until it is gone.
|
|
31
|
+
const busy = retrying || !open;
|
|
32
|
+
return _jsx(AlertDialog, { open: open, children: _jsxs(AlertDialogContent, { "data-socket-reload-dialog": true, onEscapeKeyDown: event => event.preventDefault(), children: [_jsxs(AlertDialogHeader, { children: [_jsx(AlertDialogTitle, { children: t('title') }), _jsx(AlertDialogDescription, { children: t('description') })] }), _jsxs(AlertDialogFooter, { children: [_jsx(Button, { variant: "outline", "data-socket-reload-action": true, onClick: () => window.location.reload(), children: t('action') }), _jsx(AlertDialogAction, { "data-socket-retry-action": true, disabled: busy, "aria-busy": busy, onClick: retry, children: busy ? t('retrying') : t('retry') })] })] }) });
|
|
33
|
+
};
|
|
34
|
+
//# sourceMappingURL=reload-dialog.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"reload-dialog.js","sourceRoot":"","sources":["../../../src/components/socket/reload-dialog.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,cAAc,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAA;AACzE,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAA;AAClD,OAAO,EACL,WAAW,EAAE,iBAAiB,EAAE,kBAAkB,E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,CAAC,CAAA"}
|
|
@@ -2,7 +2,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import { useMemo } from 'react';
|
|
3
3
|
import { usePanelI18n } from '@owlmeans/client-panel';
|
|
4
4
|
import { ResilientError } from '@owlmeans/error';
|
|
5
|
-
import { Alert, AlertDescription } from '
|
|
5
|
+
import { Alert, AlertDescription } from '../@/components/ui/alert.js';
|
|
6
6
|
const prepareMessage = (msg) => msg.replace(/:/g, '.');
|
|
7
7
|
const variantToAlert = (variant) => {
|
|
8
8
|
if (variant === 'error' || variant === 'destructive')
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"status.js","sourceRoot":"","sources":["../../src/components/status.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,OAAO,EAAE,MAAM,OAAO,CAAA;AAE/B,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAA;AACrD,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAA;AAChD,OAAO,EAAE,KAAK,EAAE,gBAAgB,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"status.js","sourceRoot":"","sources":["../../src/components/status.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,OAAO,EAAE,MAAM,OAAO,CAAA;AAE/B,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAA;AACrD,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAA;AAChD,OAAO,EAAE,KAAK,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAA;AAErE,MAAM,cAAc,GAAG,CAAC,GAAW,EAAE,EAAE,CAAC,GAAG,CAAC,OAAO,CAAC,IAAI,EAAE,GAAG,CAAC,CAAA;AAE9D,MAAM,cAAc,GAAG,CAAC,OAAe,EAAyC,EAAE;IAChF,IAAI,OAAO,KAAK,OAAO,IAAI,OAAO,KAAK,aAAa;QAAE,OAAO,aAAa,CAAA;IAC1E,IAAI,OAAO,KAAK,SAAS;QAAE,OAAO,S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
{"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../src/components/text.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,EAAO,MAAM,OAAO,CAAA;AACpC,OAAO,KAAK,EAAE,SAAS,EAAe,MAAM,YAAY,CAAA;
|
|
1
|
+
{"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../src/components/text.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAAE,EAAO,MAAM,OAAO,CAAA;AACpC,OAAO,KAAK,EAAE,SAAS,EAAe,MAAM,YAAY,CAAA;AAWxD,eAAO,MAAM,IAAI,EAAE,EAAE,CAAC,SAAS,CAO9B,CAAA"}
|
package/build/components/text.js
CHANGED
|
@@ -1,18 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { usePanelI18n } from '@owlmeans/client-panel';
|
|
3
|
-
import { cn } from '
|
|
4
|
-
|
|
5
|
-
h1: 'scroll-m-20 text-4xl font-extrabold tracking-tight',
|
|
6
|
-
h2: 'scroll-m-20 text-3xl font-semibold tracking-tight',
|
|
7
|
-
h3: 'scroll-m-20 text-2xl font-semibold tracking-tight',
|
|
8
|
-
h4: 'scroll-m-20 text-xl font-semibold tracking-tight',
|
|
9
|
-
p: 'leading-7',
|
|
10
|
-
lead: 'text-xl text-muted-foreground',
|
|
11
|
-
large: 'text-lg font-semibold',
|
|
12
|
-
small: 'text-sm font-medium leading-none',
|
|
13
|
-
muted: 'text-sm text-muted-foreground',
|
|
14
|
-
blockquote: 'mt-6 border-l-2 pl-6 italic',
|
|
15
|
-
};
|
|
3
|
+
import { cn } from '../@/lib/utils.js';
|
|
4
|
+
import { variantClasses } from './consts.local.js';
|
|
16
5
|
const variantTag = (variant, nested) => {
|
|
17
6
|
if (nested)
|
|
18
7
|
return 'span';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text.js","sourceRoot":"","sources":["../../src/components/text.tsx"],"names":[],"mappings":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AE,KAAK,EAAE,KAAK,YAAG,KAAK,IAAI,QAAQ,GAAO,CAAA;AACrE,CAAC,CAAA"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type FC } from 'react';
|
|
2
|
+
import { type ToasterProps } from 'sonner';
|
|
3
|
+
/**
|
|
4
|
+
* The application's toast surface — mount it ONCE, in the layout.
|
|
5
|
+
*
|
|
6
|
+
* `toast()` from `sonner` is a module-global store, so a second mounted `Toaster` renders every
|
|
7
|
+
* message twice and no mounted `Toaster` renders none of them at all with nothing reported. The
|
|
8
|
+
* layout is therefore the only place this belongs.
|
|
9
|
+
*
|
|
10
|
+
* Colours come from the app's own theme tokens rather than sonner's palette: the CSS variables
|
|
11
|
+
* below are what its stylesheet paints with, so a toast follows `--popover` the way every other
|
|
12
|
+
* floating surface in the app does. A caller's `style` is merged OVER them, so an app that has to
|
|
13
|
+
* shift or recolour the stack keeps the rest.
|
|
14
|
+
*/
|
|
15
|
+
export declare const Toaster: FC<ToasterProps>;
|
|
16
|
+
//# sourceMappingURL=toaster.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toaster.d.ts","sourceRoot":"","sources":["../../src/components/toaster.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAsB,KAAK,EAAE,EAAuB,MAAM,OAAO,CAAA;AACxE,OAAO,EAAqB,KAAK,YAAY,EAAE,MAAM,QAAQ,CAAA;AAiC7D;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,OAAO,EAAE,EAAE,CAAC,YAAY,CAkBpC,CAAA"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useEffect, useState } from 'react';
|
|
3
|
+
import { Toaster as Sonner } from 'sonner';
|
|
4
|
+
import { cn } from '../@/lib/utils.js';
|
|
5
|
+
import { DARK_CLASS } from './consts.local.js';
|
|
6
|
+
/**
|
|
7
|
+
* Follow whatever puts `.dark` on the document element.
|
|
8
|
+
*
|
|
9
|
+
* The panel's Tailwind theme switches on that class (`@custom-variant dark (&:is(.dark *))`),
|
|
10
|
+
* and every OwlMeans app drives it from something different — `next-themes` with
|
|
11
|
+
* `attribute="class"`, the owl theme provider, or nothing at all. Reading the class rather than a
|
|
12
|
+
* provider's hook means this component follows all three and depends on none of them: a package
|
|
13
|
+
* that imported `next-themes` would force it on every consumer of `@owlmeans/web-panel`, and a
|
|
14
|
+
* second copy of a theme provider is its own class of bug.
|
|
15
|
+
*
|
|
16
|
+
* `'system'` is the answer before the first paint and whenever nothing sets the class — sonner
|
|
17
|
+
* resolves it from `prefers-color-scheme`, which is what an app with no toggle means by it.
|
|
18
|
+
*/
|
|
19
|
+
const useDocumentTheme = () => {
|
|
20
|
+
const [theme, setTheme] = useState('system');
|
|
21
|
+
useEffect(() => {
|
|
22
|
+
const root = document.documentElement;
|
|
23
|
+
const read = () => setTheme(root.classList.contains(DARK_CLASS) ? 'dark' : 'system');
|
|
24
|
+
read();
|
|
25
|
+
const observer = new MutationObserver(read);
|
|
26
|
+
observer.observe(root, { attributes: true, attributeFilter: ['class'] });
|
|
27
|
+
return () => observer.disconnect();
|
|
28
|
+
}, []);
|
|
29
|
+
return theme;
|
|
30
|
+
};
|
|
31
|
+
/**
|
|
32
|
+
* The application's toast surface — mount it ONCE, in the layout.
|
|
33
|
+
*
|
|
34
|
+
* `toast()` from `sonner` is a module-global store, so a second mounted `Toaster` renders every
|
|
35
|
+
* message twice and no mounted `Toaster` renders none of them at all with nothing reported. The
|
|
36
|
+
* layout is therefore the only place this belongs.
|
|
37
|
+
*
|
|
38
|
+
* Colours come from the app's own theme tokens rather than sonner's palette: the CSS variables
|
|
39
|
+
* below are what its stylesheet paints with, so a toast follows `--popover` the way every other
|
|
40
|
+
* floating surface in the app does. A caller's `style` is merged OVER them, so an app that has to
|
|
41
|
+
* shift or recolour the stack keeps the rest.
|
|
42
|
+
*/
|
|
43
|
+
export const Toaster = ({ style, theme, className, ...props }) => {
|
|
44
|
+
const detected = useDocumentTheme();
|
|
45
|
+
return _jsx(Sonner, { theme: theme ?? detected, className: cn('toaster group', className), richColors: true, closeButton: true, duration: 5000, position: "top-right", style: {
|
|
46
|
+
'--normal-bg': 'var(--popover)',
|
|
47
|
+
'--normal-text': 'var(--popover-foreground)',
|
|
48
|
+
'--normal-border': 'var(--border)',
|
|
49
|
+
...(style ?? {})
|
|
50
|
+
}, ...props });
|
|
51
|
+
};
|
|
52
|
+
//# sourceMappingURL=toaster.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toaster.js","sourceRoot":"","sources":["../../src/components/toaster.tsx"],"names":[],"mappings":";AAAA,OAAO,EAA+B,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AACxE,OAAO,EAAE,OAAO,IAAI,MAAM,EAAqB,MAAM,QAAQ,CAAA;AAC7D,OAAO,EAAE,EAAE,EAAE,MAAM,mBAAmB,CAAA;AACtC,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA;AAE9C;;;;;;;;;;;;GAYG;AACH,MAAM,gBAAgB,GAAG,GAA0B,EAAE;IACnD,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,GAAG,QAAQ,CAAwB,QAAQ,CAAC,CAAA;IAEnE,SAAS,CAAC,GAAG,EAAE;QACb,MAAM,IAAI,GAAG,QAAQ,CAAC,eAAe,CAAA;QACrC,MAAM,IAAI,GAAG,GAAG,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAA;QACpF,IAAI,EAAE,CAAA;QACN,MAAM,QAAQ,GAAG,IAAI,gBAAgB,CAAC,IAAI,CAAC,CAAA;QAC3C,QAAQ,CAAC,OAAO,CAAC,IAAI,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE,eAAe,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC,CAAA;QAExE,OAAO,GAAG,EAAE,CAAC,QAAQ,CAAC,UAAU,EAAE,CAAA;IACpC,CAAC,EAAE,EAAE,CAAC,CAAA;IAEN,OAAO,KAAK,CAAA;AACd,CAAC,CAAA;AAED;;;;;;;;;;;GAWG;AACH,MAAM,CAAC,MAAM,OAAO,GAAqB,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,EAAE;IACjF,MAAM,QAAQ,GAAG,gBAAgB,EAAE,CAAA;IAEnC,OAAO,KAAC,MAAM,IACZ,KAAK,EAAE,KAAK,IAAI,QAAQ,EACxB,SAAS,EAAE,EAAE,CAAC,eAAe,EAAE,SAAS,CAAC,EACzC,UAAU,QACV,WAAW,QACX,QAAQ,EAAE,IAAI,EACd,QAAQ,EAAC,WAAW,EACpB,KAAK,EAAE;YACL,aAAa,EAAE,gBAAgB;YAC/B,eAAe,EAAE,2BAA2B;YAC5C,iBAAiB,EAAE,eAAe;YAClC,GAAG,CAAC,KAAK,IAAI,EAAE,CAAC;SACA,KACd,KAAK,GACT,CAAA;AACJ,CAAC,CAAA"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export declare const wrapperClasses = "w-[65px] h-[65px] md:w-[125px] md:h-[125px] lg:w-[205px] lg:h-[205px]";
|
|
2
|
+
export declare const previewClasses = "max-w-[60px] max-h-[60px] md:max-w-[120px] md:max-h-[120px] lg:max-w-[200px] lg:max-h-[200px]";
|
|
3
|
+
export declare const iconClasses = "size-[60px] md:size-[120px] lg:size-[200px] text-primary";
|
|
4
|
+
//# sourceMappingURL=consts.local.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"consts.local.d.ts","sourceRoot":"","sources":["../../../src/components/uploader/consts.local.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,cAAc,0EAA0E,CAAA;AAErG,eAAO,MAAM,cAAc,kGAAkG,CAAA;AAE7H,eAAO,MAAM,WAAW,6DAAgE,CAAA"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
// Tailwind responsive sizes — mirrors the previous MUI breakpoint object.
|
|
2
|
+
// xs: 60/65px md: 120/125px lg: 200/205px
|
|
3
|
+
export const wrapperClasses = 'w-[65px] h-[65px] md:w-[125px] md:h-[125px] lg:w-[205px] lg:h-[205px]';
|
|
4
|
+
export const previewClasses = 'max-w-[60px] max-h-[60px] md:max-w-[120px] md:max-h-[120px] lg:max-w-[200px] lg:max-h-[200px]';
|
|
5
|
+
export const iconClasses = 'size-[60px] md:size-[120px] lg:size-[200px] text-primary';
|
|
6
|
+
//# sourceMappingURL=consts.local.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"consts.local.js","sourceRoot":"","sources":["../../../src/components/uploader/consts.local.ts"],"names":[],"mappings":"AAAA,0EAA0E;AAC1E,iDAAiD;AACjD,MAAM,CAAC,MAAM,cAAc,GAAG,uEAAuE,CAAA;AAErG,MAAM,CAAC,MAAM,cAAc,GAAG,+FAA+F,CAAA;AAE7H,MAAM,CAAC,MAAM,WAAW,GAAM,0DAA0D,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"image.d.ts","sourceRoot":"","sources":["../../../src/components/uploader/image.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAA;AAG/B,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAA;
|
|
1
|
+
{"version":3,"file":"image.d.ts","sourceRoot":"","sources":["../../../src/components/uploader/image.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAA;AAG/B,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,YAAY,CAAA;AAKpD,eAAO,MAAM,aAAa,EAAE,EAAE,CAAC,kBAAkB,CAkBhD,CAAA"}
|
|
@@ -1,12 +1,8 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { ImageUploader as Uploader } from '@owlmeans/web-client';
|
|
3
3
|
import { ImagePlus } from 'lucide-react';
|
|
4
|
-
import { cn } from '
|
|
5
|
-
|
|
6
|
-
// xs: 60/65px md: 120/125px lg: 200/205px
|
|
7
|
-
const wrapperClasses = 'w-[65px] h-[65px] md:w-[125px] md:h-[125px] lg:w-[205px] lg:h-[205px]';
|
|
8
|
-
const previewClasses = 'max-w-[60px] max-h-[60px] md:max-w-[120px] md:max-h-[120px] lg:max-w-[200px] lg:max-h-[200px]';
|
|
9
|
-
const iconClasses = 'size-[60px] md:size-[120px] lg:size-[200px] text-primary';
|
|
4
|
+
import { cn } from '../../@/lib/utils.js';
|
|
5
|
+
import { iconClasses, previewClasses, wrapperClasses } from './consts.local.js';
|
|
10
6
|
export const ImageUploader = ({ Root, rootProps, previewUrl, ...others }) => {
|
|
11
7
|
const DefaultRoot = ({ children, className, ...rest }) => (_jsx("div", { ...rest, className: cn('flex items-center justify-center rounded-md border bg-card shadow-sm cursor-pointer', wrapperClasses, className), children: children }));
|
|
12
8
|
return _jsx(Uploader, { Root: Root ?? DefaultRoot, rootProps: rootProps, ...others, children: previewUrl != null
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"image.js","sourceRoot":"","sources":["../../../src/components/uploader/image.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,aAAa,IAAI,QAAQ,EAAE,MAAM,sBAAsB,CAAA;AAChE,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AAExC,OAAO,EAAE,EAAE,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"image.js","sourceRoot":"","sources":["../../../src/components/uploader/image.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,aAAa,IAAI,QAAQ,EAAE,MAAM,sBAAsB,CAAA;AAChE,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAA;AAExC,OAAO,EAAE,EAAE,EAAE,MAAM,sBAAsB,CAAA;AACzC,OAAO,EAAE,WAAW,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAA;AAG/E,MAAM,CAAC,MAAM,aAAa,GAA2B,CAAC,EAAE,IAAI,EAAE,SAAS,EAAE,UAAU,EAAE,GAAG,MAAM,EAAE,EAAE,EAAE;IAClG,MAAM,WAAW,GAAY,CAAC,EAAE,QAAQ,EAAE,SAAS,EAAE,GAAG,IAAI,EAAE,EAAE,EAAE,CAAC,CACjE,iBACM,IAAI,EACR,SAAS,EAAE,EAAE,CACX,qFAAqF,EACrF,cAAc,EACd,SAAS,CACV,YACD,QAAQ,GAAO,CAClB,CAAA;IAED,OAAO,KAAC,QAAQ,IAAC,IAAI,EAAE,IAAI,IAAI,WAAW,EAAE,SAAS,EAAE,SAAS,KAAM,MAAM,YACzE,UAAU,IAAI,IAAI;YACjB,CAAC,CAAC,cAAK,GAAG,EAAE,UAAU,EAAE,SAAS,EAAE,cAAc,GAAI;YACrD,CAAC,CAAC,KAAC,SAAS,IAAC,SAAS,EAAE,WAAW,wBAAgB,GAE5C,CAAA;AACb,CAAC,CAAA"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { FC } from 'react';
|
|
2
|
+
import { type CookieConsentProps, type CookiePolicyProps } from '@owlmeans/web-consent';
|
|
3
|
+
/**
|
|
4
|
+
* The consent dialog, bound to this application's language and translations.
|
|
5
|
+
*
|
|
6
|
+
* `@owlmeans/web-consent` deliberately knows nothing about OwlMeans i18n — one of its consumers is
|
|
7
|
+
* an Astro site with none — so this is where the two meet.
|
|
8
|
+
*
|
|
9
|
+
* Also hides the floating re-open button whenever a host menu declares, through
|
|
10
|
+
* `useConsentMenuPresence()`, that it offers a `PanelConsentMenuWidget` row (a collapsed dropdown,
|
|
11
|
+
* a footer "Cookie settings" control) — an explicit `noReopenButton` from the caller always wins;
|
|
12
|
+
* only the default `undefined` falls through to this computed presence.
|
|
13
|
+
*
|
|
14
|
+
* The presence read needs `appendConsentWidgetService(context)`, and an application mounting the
|
|
15
|
+
* dialog on its own has no reason to call it. Without the service the dialog is exactly the plain
|
|
16
|
+
* bound dialog, floating button included — never a presence read against a state resource that
|
|
17
|
+
* was never registered, which throws inside render and blanks the whole application. The choice is
|
|
18
|
+
* made by component TYPE, because it is fixed for the context's lifetime: a service is appended
|
|
19
|
+
* while the context is built, before anything renders.
|
|
20
|
+
*/
|
|
21
|
+
export declare const PanelCookieConsent: FC<CookieConsentProps>;
|
|
22
|
+
/**
|
|
23
|
+
* The cookie-policy page, bound like the dialog — and told about the geo gate the same way, so it
|
|
24
|
+
* states the regional rule exactly when the dialog applies it.
|
|
25
|
+
*/
|
|
26
|
+
export declare const PanelCookiePolicy: FC<CookiePolicyProps>;
|
|
27
|
+
//# sourceMappingURL=component.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"component.d.ts","sourceRoot":"","sources":["../../src/consent/component.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,OAAO,CAAA;AAC/B,OAAO,EACgD,KAAK,kBAAkB,EAAE,KAAK,iBAAiB,EACrG,MAAM,uBAAuB,CAAA;AAqC9B;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,kBAAkB,EAAE,EAAE,CAAC,kBAAkB,CAWrD,CAAA;AAED;;;GAGG;AACH,eAAO,MAAM,iBAAiB,EAAE,EAAE,CAAC,iBAAiB,CAQnD,CAAA"}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { CookieConsent, CookiePolicy, } from '@owlmeans/web-consent';
|
|
3
|
+
import { useLanguage } from '@owlmeans/client-i18n';
|
|
4
|
+
import { useContext } from '../context.js';
|
|
5
|
+
import { useConsentTranslate } from './translate.js';
|
|
6
|
+
import { useConsentWidgetPresent } from './presence.js';
|
|
7
|
+
import { _localeParity } from './consts.local.js';
|
|
8
|
+
const BoundCookieConsent = ({ menuPresent, ...props }) => {
|
|
9
|
+
const [lng] = useLanguage();
|
|
10
|
+
const locale = props.locale ?? lng;
|
|
11
|
+
const translate = useConsentTranslate(locale, props.translate);
|
|
12
|
+
return _jsx(CookieConsent, { ...props, locale: locale, translate: translate, noReopenButton: props.noReopenButton ?? menuPresent });
|
|
13
|
+
};
|
|
14
|
+
const MenuAwareCookieConsent = props => _jsx(BoundCookieConsent, { ...props, menuPresent: useConsentWidgetPresent() });
|
|
15
|
+
/**
|
|
16
|
+
* The geo gate in force: the prop, else `cfg.cookieConsent.geo`, else — when the application
|
|
17
|
+
* appended a locator of its own — the gate with nothing but that locator.
|
|
18
|
+
*/
|
|
19
|
+
const geoOf = (prop, context) => prop ?? context.cfg.cookieConsent?.geo ?? (typeof context.consentGeo === 'function' ? {} : undefined);
|
|
20
|
+
void _localeParity;
|
|
21
|
+
/**
|
|
22
|
+
* The consent dialog, bound to this application's language and translations.
|
|
23
|
+
*
|
|
24
|
+
* `@owlmeans/web-consent` deliberately knows nothing about OwlMeans i18n — one of its consumers is
|
|
25
|
+
* an Astro site with none — so this is where the two meet.
|
|
26
|
+
*
|
|
27
|
+
* Also hides the floating re-open button whenever a host menu declares, through
|
|
28
|
+
* `useConsentMenuPresence()`, that it offers a `PanelConsentMenuWidget` row (a collapsed dropdown,
|
|
29
|
+
* a footer "Cookie settings" control) — an explicit `noReopenButton` from the caller always wins;
|
|
30
|
+
* only the default `undefined` falls through to this computed presence.
|
|
31
|
+
*
|
|
32
|
+
* The presence read needs `appendConsentWidgetService(context)`, and an application mounting the
|
|
33
|
+
* dialog on its own has no reason to call it. Without the service the dialog is exactly the plain
|
|
34
|
+
* bound dialog, floating button included — never a presence read against a state resource that
|
|
35
|
+
* was never registered, which throws inside render and blanks the whole application. The choice is
|
|
36
|
+
* made by component TYPE, because it is fixed for the context's lifetime: a service is appended
|
|
37
|
+
* while the context is built, before anything renders.
|
|
38
|
+
*/
|
|
39
|
+
export const PanelCookieConsent = props => {
|
|
40
|
+
const context = useContext();
|
|
41
|
+
const mode = props.mode ?? context.cfg.cookieConsent?.mode;
|
|
42
|
+
const geo = geoOf(props.geo, context);
|
|
43
|
+
const bound = { ...props, ...(mode != null ? { mode } : {}), ...(geo != null ? { geo } : {}) };
|
|
44
|
+
return typeof context.consentWidget === 'function'
|
|
45
|
+
? _jsx(MenuAwareCookieConsent, { ...bound })
|
|
46
|
+
: _jsx(BoundCookieConsent, { ...bound });
|
|
47
|
+
};
|
|
48
|
+
/**
|
|
49
|
+
* The cookie-policy page, bound like the dialog — and told about the geo gate the same way, so it
|
|
50
|
+
* states the regional rule exactly when the dialog applies it.
|
|
51
|
+
*/
|
|
52
|
+
export const PanelCookiePolicy = props => {
|
|
53
|
+
const context = useContext();
|
|
54
|
+
const [lng] = useLanguage();
|
|
55
|
+
const locale = props.locale ?? lng;
|
|
56
|
+
const translate = useConsentTranslate(locale, props.translate);
|
|
57
|
+
const geo = geoOf(props.geo, context);
|
|
58
|
+
return _jsx(CookiePolicy, { ...props, ...(geo != null ? { geo } : {}), locale: locale, translate: translate });
|
|
59
|
+
};
|
|
60
|
+
//# sourceMappingURL=component.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"component.js","sourceRoot":"","sources":["../../src/consent/component.tsx"],"names":[],"mappings":";AACA,OAAO,EACL,aAAa,EAAE,YAAY,GAC5B,MAAM,uBAAuB,CAAA;AAC9B,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAA;AACnD,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAA;AAE1C,OAAO,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAA;AACpD,OAAO,EAAE,uBAAuB,EAAE,MAAM,eAAe,CAAA;AAEvD,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AAGjD,MAAM,kBAAkB,GAAgC,CAAC,EAAE,WAAW,EAAE,GAAG,KAAK,EAAE,EAAE,EAAE;IACpF,MAAM,CAAC,GAAG,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AAE,GAAG,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAA;IAE9F,OAAO,OAAO,OAAO,CAAC,aAAa,KAAK,UAAU;QAChD,CAAC,CAAC,KAAC,sBAAsB,OAAK,KAAK,GAAI;QACvC,CAAC,CAAC,KAAC,kBAAkB,OAAK,KAAK,GAAI,CAAA;AACvC,CAAC,CAAA;AAED;;;GAGG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAA0B,KAAK,CAAC,EAAE;IAC9D,MAAM,OAAO,GAAG,UAAU,EAAsE,CAAA;IAChG,MAAM,CAAC,GAAG,CAAC,GAAG,WAAW,EAAE,CAAA;IAC3B,MAAM,MAAM,GAAG,KAAK,CAAC,MAAM,IAAI,GAAG,CAAA;IAClC,MAAM,SAAS,GAAG,mBAAmB,CAAC,MAAM,EAAE,KAAK,CAAC,SAAS,CAAC,CAAA;IAC9D,MAAM,GAAG,GAAG,KAAK,CAAC,KAAK,CAAC,GAAG,EAAE,OAAO,CAAC,CAAA;IAErC,OAAO,KAAC,YAAY,OAAK,KAAK,KAAM,CAAC,GAAG,IAAI,IAAI,CAAC,CAAC,CAAC,EAAE,GAAG,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,MAAM,EAAE,MAAM,EAAE,SAAS,EAAE,SAAS,GAAI,CAAA;AAC5G,CAAC,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"consts.d.ts","sourceRoot":"","sources":["../../src/consent/consts.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,sBAAsB,mBAAmB,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"consts.js","sourceRoot":"","sources":["../../src/consent/consts.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,sBAAsB,GAAG,gBAAgB,CAAA"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ConsentLocale } from '@owlmeans/web-consent';
|
|
2
|
+
/**
|
|
3
|
+
* The consent package carries its own locale list because it must build with no dependency on the
|
|
4
|
+
* i18n package at all. This assertion is what keeps the two from drifting: a language added to the
|
|
5
|
+
* framework and not to the bundle fails here, at build time, rather than as a dialog rendering
|
|
6
|
+
* English to the one reader who cannot report it.
|
|
7
|
+
*/
|
|
8
|
+
export declare const _localeParity: readonly ConsentLocale[];
|
|
9
|
+
//# sourceMappingURL=consts.local.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"consts.local.d.ts","sourceRoot":"","sources":["../../src/consent/consts.local.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAA;AAG1D;;;;;GAKG;AACH,eAAO,MAAM,aAAa,EAAE,SAAS,aAAa,EAA+C,CAAA"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { SUPPORTED_LNGS } from '@owlmeans/i18n';
|
|
2
|
+
/**
|
|
3
|
+
* The consent package carries its own locale list because it must build with no dependency on the
|
|
4
|
+
* i18n package at all. This assertion is what keeps the two from drifting: a language added to the
|
|
5
|
+
* framework and not to the bundle fails here, at build time, rather than as a dialog rendering
|
|
6
|
+
* English to the one reader who cannot report it.
|
|
7
|
+
*/
|
|
8
|
+
export const _localeParity = SUPPORTED_LNGS;
|
|
9
|
+
//# sourceMappingURL=consts.local.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"consts.local.js","sourceRoot":"","sources":["../../src/consent/consts.local.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAA;AAE/C;;;;;GAKG;AACH,MAAM,CAAC,MAAM,aAAa,GAA6B,cAA0C,CAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { type ConsentGeoPlugin } from '@owlmeans/web-consent';
|
|
2
|
+
import type { ClientConfig } from '@owlmeans/client-context';
|
|
3
|
+
import type { ClientContext } from '@owlmeans/client';
|
|
4
|
+
import type { ConsentGeoPluginAppend } from './types.js';
|
|
5
|
+
/**
|
|
6
|
+
* Add the application's own country locator while its context is configured — beside
|
|
7
|
+
* `appendConsentWidgetService`, before anything renders.
|
|
8
|
+
*
|
|
9
|
+
* A locator is one async method that resolves the visitor's country or throws
|
|
10
|
+
* (`ConsentGeoPlugin`). It is registered into `@owlmeans/consent`'s plugin registry, ahead of the
|
|
11
|
+
* built-in Cloudflare one, and `PanelCookieConsent` turns the geo gate on for it even where
|
|
12
|
+
* `cfg.cookieConsent.geo` says nothing — appending a locator IS asking for the gate. Its result
|
|
13
|
+
* decides as Cloudflare's would: a visitor in a consent country is asked, anyone else is decided for
|
|
14
|
+
* automatically, and a throw hands over to the next locator — with none left, the visitor is asked.
|
|
15
|
+
*/
|
|
16
|
+
export declare const appendConsentGeoPlugin: <C extends ClientConfig, T extends ClientContext<C>>(ctx: T, plugin: ConsentGeoPlugin) => T & ConsentGeoPluginAppend;
|
|
17
|
+
//# sourceMappingURL=geo.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"geo.d.ts","sourceRoot":"","sources":["../../src/consent/geo.ts"],"names":[],"mappings":"AAAA,OAAO,EAAuB,KAAK,gBAAgB,EAAE,MAAM,uBAAuB,CAAA;AAClF,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAC5D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAA;AACrD,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,YAAY,CAAA;AAExD;;;;;;;;;;GAUG;AACH,eAAO,MAAM,sBAAsB,GAAI,CAAC,SAAS,YAAY,EAAE,CAAC,SAAS,aAAa,CAAC,CAAC,CAAC,OAClF,CAAC,UAAU,gBAAgB,KAC/B,CAAC,GAAG,sBAON,CAAA"}
|