@antistatique/leckerli 1.2.6 → 1.3.0
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/CHANGELOG.md +7 -1
- package/README.md +5 -0
- package/dist/assets/leckerli-gtm.min.js +1 -1
- package/dist/assets/leckerli.min.css +1 -1
- package/dist/assets/leckerli.min.js +1 -1
- package/doc/gtm-tag-template.js +1 -1
- package/index.html +6 -0
- package/package.json +1 -1
- package/src/components/App.tsx +13 -3
- package/src/components/Banner.tsx +1 -1
- package/src/defaultSettings.ts +1 -0
- package/tailwind.config.js +10 -1
package/CHANGELOG.md
CHANGED
|
@@ -6,6 +6,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
6
6
|
|
|
7
7
|
## [Unreleased]
|
|
8
8
|
|
|
9
|
+
## [1.3.0] - 2026-02-26
|
|
10
|
+
### Added
|
|
11
|
+
- Add `displayDelay` option to delay the banner appearance (in milliseconds)
|
|
12
|
+
- Add slide-up animation on the banner
|
|
13
|
+
|
|
9
14
|
## [1.2.6] - 2026-02-26
|
|
10
15
|
### Changed
|
|
11
16
|
- Display banner when permissions list change
|
|
@@ -94,7 +99,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
94
99
|
### Added
|
|
95
100
|
- First POC
|
|
96
101
|
|
|
97
|
-
[Unreleased]: https://github.com/antistatique/leckerli/compare/v1.
|
|
102
|
+
[Unreleased]: https://github.com/antistatique/leckerli/compare/v1.3.0...HEAD
|
|
103
|
+
[1.3.0]: https://github.com/antistatique/leckerli/compare/v1.2.6...v1.3.0
|
|
98
104
|
[1.2.6]: https://github.com/antistatique/leckerli/compare/v1.2.5...v1.2.6
|
|
99
105
|
[1.2.5]: https://github.com/antistatique/leckerli/compare/v1.2.4...v1.2.5
|
|
100
106
|
[1.2.4]: https://github.com/antistatique/leckerli/compare/v1.2.3...v1.2.4
|
package/README.md
CHANGED
|
@@ -153,6 +153,10 @@ window.leckerliSettings = {
|
|
|
153
153
|
|
|
154
154
|
`baseData` is an object of any kind that **will be passed to the final cookie** as well. For example for store consent-id of some sort.
|
|
155
155
|
|
|
156
|
+
### displayDelay
|
|
157
|
+
|
|
158
|
+
It's the time in **milliseconds** before the banner appears after page load. By default it is set to `0` (the banner appears immediately). The delay is only applied when the user has not yet made a choice.
|
|
159
|
+
|
|
156
160
|
### For example
|
|
157
161
|
|
|
158
162
|
You could have something like:
|
|
@@ -189,6 +193,7 @@ You could have something like:
|
|
|
189
193
|
'analytics_storage',
|
|
190
194
|
'personalization_storage',
|
|
191
195
|
],
|
|
196
|
+
displayDelay: 2000, // milliseconds
|
|
192
197
|
}
|
|
193
198
|
</script>
|
|
194
199
|
```
|
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(){"use strict";if(window.leckerliSettings.enableGtmAutoLoad){const e=document.createElement("link");e.rel="stylesheet",e.href="//www.unpkg.com/@antistatique/leckerli@1.
|
|
1
|
+
!function(){"use strict";if(window.leckerliSettings.enableGtmAutoLoad){const e=document.createElement("link");e.rel="stylesheet",e.href="//www.unpkg.com/@antistatique/leckerli@1.3.0/dist/assets/leckerli.min.css",document.head.appendChild(e)}if(window.leckerliSettings.enableGtmAutoLoad){const e=document.createElement("script");e.src="//www.unpkg.com/@antistatique/leckerli@1.3.0/dist/assets/leckerli.min.js",document.body.appendChild(e)}document.addEventListener("leckerli:permissions-updated",(e=>{window.leckerliGTMUpdate(e.detail.cookie)}))}();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
/*! tailwindcss v3.3.3 | MIT License | https://tailwindcss.com*/#lkrl-wrapper *,#lkrl-wrapper :after,#lkrl-wrapper :before{box-sizing:border-box;border:0 solid #e5e7eb}#lkrl-wrapper :after,#lkrl-wrapper :before{--tw-content:""}#lkrl-wrapper{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-feature-settings:normal;font-variation-settings:normal;margin:0;line-height:inherit}#lkrl-wrapper hr{height:0;color:inherit;border-top-width:1px}#lkrl-wrapper abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}#lkrl-wrapper h1,#lkrl-wrapper h2,#lkrl-wrapper h3,#lkrl-wrapper h4,#lkrl-wrapper h5,#lkrl-wrapper h6{font-size:inherit;font-weight:inherit}#lkrl-wrapper a{color:inherit;text-decoration:inherit}#lkrl-wrapper b,#lkrl-wrapper strong{font-weight:bolder}#lkrl-wrapper code,#lkrl-wrapper kbd,#lkrl-wrapper pre,#lkrl-wrapper samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}#lkrl-wrapper small{font-size:80%}#lkrl-wrapper sub,#lkrl-wrapper sup{font-size:75%;line-height:0;position:relative;vertical-align:initial}#lkrl-wrapper sub{bottom:-.25em}#lkrl-wrapper sup{top:-.5em}#lkrl-wrapper table{text-indent:0;border-color:inherit;border-collapse:collapse}#lkrl-wrapper button,#lkrl-wrapper input,#lkrl-wrapper optgroup,#lkrl-wrapper select,#lkrl-wrapper textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;color:inherit;margin:0;padding:0}#lkrl-wrapper button,#lkrl-wrapper select{text-transform:none}#lkrl-wrapper [type=button],#lkrl-wrapper [type=reset],#lkrl-wrapper [type=submit],#lkrl-wrapper button{-webkit-appearance:button;background-color:initial;background-image:none}#lkrl-wrapper :-moz-focusring{outline:auto}#lkrl-wrapper :-moz-ui-invalid{box-shadow:none}#lkrl-wrapper progress{vertical-align:initial}#lkrl-wrapper ::-webkit-inner-spin-button,#lkrl-wrapper ::-webkit-outer-spin-button{height:auto}#lkrl-wrapper [type=search]{-webkit-appearance:textfield;outline-offset:-2px}#lkrl-wrapper ::-webkit-search-decoration{-webkit-appearance:none}#lkrl-wrapper ::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}#lkrl-wrapper summary{display:list-item}#lkrl-wrapper blockquote,#lkrl-wrapper dd,#lkrl-wrapper dl,#lkrl-wrapper figure,#lkrl-wrapper h1,#lkrl-wrapper h2,#lkrl-wrapper h3,#lkrl-wrapper h4,#lkrl-wrapper h5,#lkrl-wrapper h6,#lkrl-wrapper hr,#lkrl-wrapper p,#lkrl-wrapper pre{margin:0}#lkrl-wrapper fieldset{margin:0;padding:0}#lkrl-wrapper legend{padding:0}#lkrl-wrapper menu,#lkrl-wrapper ol,#lkrl-wrapper ul{list-style:none;margin:0;padding:0}#lkrl-wrapper dialog{padding:0}#lkrl-wrapper textarea{resize:vertical}#lkrl-wrapper input::-moz-placeholder,#lkrl-wrapper textarea::-moz-placeholder{opacity:1;color:#9ca3af}#lkrl-wrapper input::placeholder,#lkrl-wrapper textarea::placeholder{opacity:1;color:#9ca3af}#lkrl-wrapper [role=button],#lkrl-wrapper button{cursor:pointer}#lkrl-wrapper :disabled{cursor:default}#lkrl-wrapper audio,#lkrl-wrapper canvas,#lkrl-wrapper embed,#lkrl-wrapper iframe,#lkrl-wrapper img,#lkrl-wrapper object,#lkrl-wrapper svg,#lkrl-wrapper video{display:block;vertical-align:middle}#lkrl-wrapper img,#lkrl-wrapper video{max-width:100%;height:auto}#lkrl-wrapper [hidden]{display:none}#lkrl-wrapper *,#lkrl-wrapper ::backdrop,#lkrl-wrapper :after,#lkrl-wrapper :before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:#3b82f680;--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }#lkrl-wrapper .sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border-width:0!important}#lkrl-wrapper .pointer-events-none{pointer-events:none!important}#lkrl-wrapper .fixed{position:fixed!important}#lkrl-wrapper .absolute{position:absolute!important}#lkrl-wrapper .relative{position:relative!important}#lkrl-wrapper .bottom-0{bottom:0!important}#lkrl-wrapper .left-0{left:0!important}#lkrl-wrapper .right-0{right:0!important}#lkrl-wrapper .top-0{top:0!important}#lkrl-wrapper .z-\[9998\]{z-index:9998!important}#lkrl-wrapper .z-\[9999\]{z-index:9999!important}#lkrl-wrapper .m-0{margin:0!important}#lkrl-wrapper .m-2{margin:.5rem!important}#lkrl-wrapper .mr-2{margin-right:.5rem!important}#lkrl-wrapper .mt-0{margin-top:0!important}#lkrl-wrapper .mt-0\.5{margin-top:.125rem!important}#lkrl-wrapper .mt-2{margin-top:.5rem!important}#lkrl-wrapper .inline-block{display:inline-block!important}#lkrl-wrapper .flex{display:flex!important}#lkrl-wrapper .inline-flex{display:inline-flex!important}#lkrl-wrapper .h-5{height:1.25rem!important}#lkrl-wrapper .h-6{height:1.5rem!important}#lkrl-wrapper .h-8{height:2rem!important}#lkrl-wrapper .max-h-full{max-height:100%!important}#lkrl-wrapper .w-10\/12{width:83.333333%!important}#lkrl-wrapper .w-11{width:2.75rem!important}#lkrl-wrapper .w-5{width:1.25rem!important}#lkrl-wrapper .w-8{width:2rem!important}#lkrl-wrapper .w-full{width:100%!important}#lkrl-wrapper .max-w-lg{max-width:32rem!important}#lkrl-wrapper .max-w-md{max-width:28rem!important}#lkrl-wrapper .flex-shrink-0{flex-shrink:0!important}#lkrl-wrapper .translate-x-0{--tw-translate-x:0px!important}#lkrl-wrapper .translate-x-0,#lkrl-wrapper .translate-x-5{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}#lkrl-wrapper .translate-x-5{--tw-translate-x:1.25rem!important}#lkrl-wrapper .transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}#lkrl-wrapper .cursor-pointer{cursor:pointer!important}#lkrl-wrapper .items-start{align-items:flex-start!important}#lkrl-wrapper .justify-between{justify-content:space-between!important}#lkrl-wrapper .space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0!important;margin-top:calc(.5rem*(1 - var(--tw-space-y-reverse)))!important;margin-bottom:calc(.5rem*var(--tw-space-y-reverse))!important}#lkrl-wrapper .space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0!important;margin-top:calc(1rem*(1 - var(--tw-space-y-reverse)))!important;margin-bottom:calc(1rem*var(--tw-space-y-reverse))!important}#lkrl-wrapper .space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0!important;margin-top:calc(1.5rem*(1 - var(--tw-space-y-reverse)))!important;margin-bottom:calc(1.5rem*var(--tw-space-y-reverse))!important}#lkrl-wrapper .overflow-y-auto{overflow-y:auto!important}#lkrl-wrapper .rounded{border-radius:.25rem!important}#lkrl-wrapper .rounded-full{border-radius:9999px!important}#lkrl-wrapper .rounded-md{border-radius:.375rem!important}#lkrl-wrapper .border-2{border-width:2px!important}#lkrl-wrapper .border-solid{border-style:solid!important}#lkrl-wrapper .border-primary{border-color:var(--leckerli-primary,#059669)!important}#lkrl-wrapper .border-transparent{border-color:#0000!important}#lkrl-wrapper .bg-background{background-color:var(--leckerli-background,#fff)!important}#lkrl-wrapper .bg-gray-200{--tw-bg-opacity:1!important;background-color:rgb(229 231 235/var(--tw-bg-opacity))!important}#lkrl-wrapper .bg-primary{background-color:var(--leckerli-primary,#059669)!important}#lkrl-wrapper .px-2{padding-left:.5rem!important;padding-right:.5rem!important}#lkrl-wrapper .px-5{padding-left:1.25rem!important;padding-right:1.25rem!important}#lkrl-wrapper .py-1{padding-top:.25rem!important;padding-bottom:.25rem!important}#lkrl-wrapper .py-1\.5{padding-top:.375rem!important;padding-bottom:.375rem!important}#lkrl-wrapper .py-4{padding-top:1rem!important;padding-bottom:1rem!important}#lkrl-wrapper .pt-2{padding-top:.5rem!important}#lkrl-wrapper .pt-4{padding-top:1rem!important}#lkrl-wrapper .font-primary{font-family:var(--leckerli-font,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji")!important}#lkrl-wrapper .text-lg{font-size:1.125rem!important;line-height:1.75rem!important}#lkrl-wrapper .text-sm{font-size:.875rem!important;line-height:1.25rem!important}#lkrl-wrapper .text-xl{font-size:1.25rem!important;line-height:1.75rem!important}#lkrl-wrapper .font-semibold{font-weight:600!important}#lkrl-wrapper .leading-snug{line-height:1.375!important}#lkrl-wrapper .text-background{color:var(--leckerli-background,#fff)!important}#lkrl-wrapper .text-black{--tw-text-opacity:1!important;color:rgb(0 0 0/var(--tw-text-opacity))!important}#lkrl-wrapper .text-foreground{color:var(--leckerli-foreground,#000)!important}#lkrl-wrapper .text-primary{color:var(--leckerli-primary,#059669)!important}#lkrl-wrapper .shadow{--tw-shadow:0 1px 3px 0 #0000001a,0 1px 2px -1px #0000001a!important;--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color)!important}#lkrl-wrapper .shadow,#lkrl-wrapper .shadow-md{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}#lkrl-wrapper .shadow-md{--tw-shadow:0 4px 6px -1px #0000001a,0 2px 4px -2px #0000001a!important;--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)!important}#lkrl-wrapper .shadow-black\/25{--tw-shadow-color:#00000040!important;--tw-shadow:var(--tw-shadow-colored)!important}#lkrl-wrapper .ring-0{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)!important;--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(var(--tw-ring-offset-width)) var(--tw-ring-color)!important;box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)!important}#lkrl-wrapper .filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)!important}#lkrl-wrapper .transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter!important;transition-timing-function:cubic-bezier(.4,0,.2,1)!important;transition-duration:.15s!important}#lkrl-wrapper .transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke!important;transition-timing-function:cubic-bezier(.4,0,.2,1)!important;transition-duration:.15s!important}#lkrl-wrapper .duration-200{transition-duration:.2s!important}#lkrl-wrapper .ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)!important}#lkrl-wrapper .hover\:border-primary-hover:hover{border-color:var(--leckerli-primary-hover,#047857)!important}#lkrl-wrapper .hover\:bg-primary-hover:hover{background-color:var(--leckerli-primary-hover,#047857)!important}#lkrl-wrapper .hover\:text-primary-hover:hover{color:var(--leckerli-primary-hover,#047857)!important}#lkrl-wrapper .focus\:outline-none:focus{outline:2px solid #0000!important;outline-offset:2px!important}#lkrl-wrapper .focus\:ring-2:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)!important;--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color)!important;box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)!important}#lkrl-wrapper .focus\:ring-primary:focus{--tw-ring-color:var(--leckerli-primary,#059669)!important}#lkrl-wrapper .focus\:ring-offset-2:focus{--tw-ring-offset-width:2px!important}#lkrl-wrapper .active\:border-primary-active:active{border-color:var(--leckerli-primary-active,#064e3b)!important}#lkrl-wrapper .active\:bg-primary-active:active{background-color:var(--leckerli-primary-active,#064e3b)!important}#lkrl-wrapper .active\:text-primary-active:active{color:var(--leckerli-primary-active,#064e3b)!important}@media (min-width:768px){#lkrl-wrapper .md\:px-3{padding-left:.75rem!important;padding-right:.75rem!important}#lkrl-wrapper .md\:px-3\.5{padding-left:.875rem!important;padding-right:.875rem!important}#lkrl-wrapper .md\:py-2{padding-top:.5rem!important;padding-bottom:.5rem!important}#lkrl-wrapper .md\:py-2\.5{padding-top:.625rem!important;padding-bottom:.625rem!important}#lkrl-wrapper .md\:text-2xl{font-size:1.5rem!important;line-height:2rem!important}#lkrl-wrapper .md\:text-base{font-size:1rem!important;line-height:1.5rem!important}#lkrl-wrapper .md\:text-xl{font-size:1.25rem!important;line-height:1.75rem!important}}
|
|
1
|
+
/*! tailwindcss v3.3.3 | MIT License | https://tailwindcss.com*/#lkrl-wrapper *,#lkrl-wrapper :after,#lkrl-wrapper :before{box-sizing:border-box;border:0 solid #e5e7eb}#lkrl-wrapper :after,#lkrl-wrapper :before{--tw-content:""}#lkrl-wrapper{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-feature-settings:normal;font-variation-settings:normal;margin:0;line-height:inherit}#lkrl-wrapper hr{height:0;color:inherit;border-top-width:1px}#lkrl-wrapper abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}#lkrl-wrapper h1,#lkrl-wrapper h2,#lkrl-wrapper h3,#lkrl-wrapper h4,#lkrl-wrapper h5,#lkrl-wrapper h6{font-size:inherit;font-weight:inherit}#lkrl-wrapper a{color:inherit;text-decoration:inherit}#lkrl-wrapper b,#lkrl-wrapper strong{font-weight:bolder}#lkrl-wrapper code,#lkrl-wrapper kbd,#lkrl-wrapper pre,#lkrl-wrapper samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}#lkrl-wrapper small{font-size:80%}#lkrl-wrapper sub,#lkrl-wrapper sup{font-size:75%;line-height:0;position:relative;vertical-align:initial}#lkrl-wrapper sub{bottom:-.25em}#lkrl-wrapper sup{top:-.5em}#lkrl-wrapper table{text-indent:0;border-color:inherit;border-collapse:collapse}#lkrl-wrapper button,#lkrl-wrapper input,#lkrl-wrapper optgroup,#lkrl-wrapper select,#lkrl-wrapper textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;color:inherit;margin:0;padding:0}#lkrl-wrapper button,#lkrl-wrapper select{text-transform:none}#lkrl-wrapper [type=button],#lkrl-wrapper [type=reset],#lkrl-wrapper [type=submit],#lkrl-wrapper button{-webkit-appearance:button;background-color:initial;background-image:none}#lkrl-wrapper :-moz-focusring{outline:auto}#lkrl-wrapper :-moz-ui-invalid{box-shadow:none}#lkrl-wrapper progress{vertical-align:initial}#lkrl-wrapper ::-webkit-inner-spin-button,#lkrl-wrapper ::-webkit-outer-spin-button{height:auto}#lkrl-wrapper [type=search]{-webkit-appearance:textfield;outline-offset:-2px}#lkrl-wrapper ::-webkit-search-decoration{-webkit-appearance:none}#lkrl-wrapper ::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}#lkrl-wrapper summary{display:list-item}#lkrl-wrapper blockquote,#lkrl-wrapper dd,#lkrl-wrapper dl,#lkrl-wrapper figure,#lkrl-wrapper h1,#lkrl-wrapper h2,#lkrl-wrapper h3,#lkrl-wrapper h4,#lkrl-wrapper h5,#lkrl-wrapper h6,#lkrl-wrapper hr,#lkrl-wrapper p,#lkrl-wrapper pre{margin:0}#lkrl-wrapper fieldset{margin:0;padding:0}#lkrl-wrapper legend{padding:0}#lkrl-wrapper menu,#lkrl-wrapper ol,#lkrl-wrapper ul{list-style:none;margin:0;padding:0}#lkrl-wrapper dialog{padding:0}#lkrl-wrapper textarea{resize:vertical}#lkrl-wrapper input::-moz-placeholder,#lkrl-wrapper textarea::-moz-placeholder{opacity:1;color:#9ca3af}#lkrl-wrapper input::placeholder,#lkrl-wrapper textarea::placeholder{opacity:1;color:#9ca3af}#lkrl-wrapper [role=button],#lkrl-wrapper button{cursor:pointer}#lkrl-wrapper :disabled{cursor:default}#lkrl-wrapper audio,#lkrl-wrapper canvas,#lkrl-wrapper embed,#lkrl-wrapper iframe,#lkrl-wrapper img,#lkrl-wrapper object,#lkrl-wrapper svg,#lkrl-wrapper video{display:block;vertical-align:middle}#lkrl-wrapper img,#lkrl-wrapper video{max-width:100%;height:auto}#lkrl-wrapper [hidden]{display:none}#lkrl-wrapper *,#lkrl-wrapper ::backdrop,#lkrl-wrapper :after,#lkrl-wrapper :before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:#3b82f680;--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }#lkrl-wrapper .sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border-width:0!important}#lkrl-wrapper .pointer-events-none{pointer-events:none!important}#lkrl-wrapper .fixed{position:fixed!important}#lkrl-wrapper .absolute{position:absolute!important}#lkrl-wrapper .relative{position:relative!important}#lkrl-wrapper .bottom-0{bottom:0!important}#lkrl-wrapper .left-0{left:0!important}#lkrl-wrapper .right-0{right:0!important}#lkrl-wrapper .top-0{top:0!important}#lkrl-wrapper .z-\[9998\]{z-index:9998!important}#lkrl-wrapper .z-\[9999\]{z-index:9999!important}#lkrl-wrapper .m-0{margin:0!important}#lkrl-wrapper .m-2{margin:.5rem!important}#lkrl-wrapper .mr-2{margin-right:.5rem!important}#lkrl-wrapper .mt-0{margin-top:0!important}#lkrl-wrapper .mt-0\.5{margin-top:.125rem!important}#lkrl-wrapper .mt-2{margin-top:.5rem!important}#lkrl-wrapper .inline-block{display:inline-block!important}#lkrl-wrapper .flex{display:flex!important}#lkrl-wrapper .inline-flex{display:inline-flex!important}#lkrl-wrapper .h-5{height:1.25rem!important}#lkrl-wrapper .h-6{height:1.5rem!important}#lkrl-wrapper .h-8{height:2rem!important}#lkrl-wrapper .max-h-full{max-height:100%!important}#lkrl-wrapper .w-10\/12{width:83.333333%!important}#lkrl-wrapper .w-11{width:2.75rem!important}#lkrl-wrapper .w-5{width:1.25rem!important}#lkrl-wrapper .w-8{width:2rem!important}#lkrl-wrapper .w-full{width:100%!important}#lkrl-wrapper .max-w-lg{max-width:32rem!important}#lkrl-wrapper .max-w-md{max-width:28rem!important}#lkrl-wrapper .flex-shrink-0{flex-shrink:0!important}#lkrl-wrapper .translate-x-0{--tw-translate-x:0px!important}#lkrl-wrapper .translate-x-0,#lkrl-wrapper .translate-x-5{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}#lkrl-wrapper .translate-x-5{--tw-translate-x:1.25rem!important}#lkrl-wrapper .transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))!important}@keyframes slide-in-up{0%{opacity:.4;transform:translateY(2rem)}to{opacity:1;transform:translateY(0)}}#lkrl-wrapper .animate-slide-in-up{animation:slide-in-up .4s ease-out!important}#lkrl-wrapper .cursor-pointer{cursor:pointer!important}#lkrl-wrapper .items-start{align-items:flex-start!important}#lkrl-wrapper .justify-between{justify-content:space-between!important}#lkrl-wrapper .space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0!important;margin-top:calc(.5rem*(1 - var(--tw-space-y-reverse)))!important;margin-bottom:calc(.5rem*var(--tw-space-y-reverse))!important}#lkrl-wrapper .space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0!important;margin-top:calc(1rem*(1 - var(--tw-space-y-reverse)))!important;margin-bottom:calc(1rem*var(--tw-space-y-reverse))!important}#lkrl-wrapper .space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0!important;margin-top:calc(1.5rem*(1 - var(--tw-space-y-reverse)))!important;margin-bottom:calc(1.5rem*var(--tw-space-y-reverse))!important}#lkrl-wrapper .overflow-y-auto{overflow-y:auto!important}#lkrl-wrapper .rounded{border-radius:.25rem!important}#lkrl-wrapper .rounded-full{border-radius:9999px!important}#lkrl-wrapper .rounded-md{border-radius:.375rem!important}#lkrl-wrapper .border-2{border-width:2px!important}#lkrl-wrapper .border-solid{border-style:solid!important}#lkrl-wrapper .border-primary{border-color:var(--leckerli-primary,#059669)!important}#lkrl-wrapper .border-transparent{border-color:#0000!important}#lkrl-wrapper .bg-background{background-color:var(--leckerli-background,#fff)!important}#lkrl-wrapper .bg-gray-200{--tw-bg-opacity:1!important;background-color:rgb(229 231 235/var(--tw-bg-opacity))!important}#lkrl-wrapper .bg-primary{background-color:var(--leckerli-primary,#059669)!important}#lkrl-wrapper .px-2{padding-left:.5rem!important;padding-right:.5rem!important}#lkrl-wrapper .px-5{padding-left:1.25rem!important;padding-right:1.25rem!important}#lkrl-wrapper .py-1{padding-top:.25rem!important;padding-bottom:.25rem!important}#lkrl-wrapper .py-1\.5{padding-top:.375rem!important;padding-bottom:.375rem!important}#lkrl-wrapper .py-4{padding-top:1rem!important;padding-bottom:1rem!important}#lkrl-wrapper .pt-2{padding-top:.5rem!important}#lkrl-wrapper .pt-4{padding-top:1rem!important}#lkrl-wrapper .font-primary{font-family:var(--leckerli-font,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji")!important}#lkrl-wrapper .text-lg{font-size:1.125rem!important;line-height:1.75rem!important}#lkrl-wrapper .text-sm{font-size:.875rem!important;line-height:1.25rem!important}#lkrl-wrapper .text-xl{font-size:1.25rem!important;line-height:1.75rem!important}#lkrl-wrapper .font-semibold{font-weight:600!important}#lkrl-wrapper .leading-snug{line-height:1.375!important}#lkrl-wrapper .text-background{color:var(--leckerli-background,#fff)!important}#lkrl-wrapper .text-black{--tw-text-opacity:1!important;color:rgb(0 0 0/var(--tw-text-opacity))!important}#lkrl-wrapper .text-foreground{color:var(--leckerli-foreground,#000)!important}#lkrl-wrapper .text-primary{color:var(--leckerli-primary,#059669)!important}#lkrl-wrapper .shadow{--tw-shadow:0 1px 3px 0 #0000001a,0 1px 2px -1px #0000001a!important;--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color),0 1px 2px -1px var(--tw-shadow-color)!important}#lkrl-wrapper .shadow,#lkrl-wrapper .shadow-md{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)!important}#lkrl-wrapper .shadow-md{--tw-shadow:0 4px 6px -1px #0000001a,0 2px 4px -2px #0000001a!important;--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)!important}#lkrl-wrapper .shadow-black\/25{--tw-shadow-color:#00000040!important;--tw-shadow:var(--tw-shadow-colored)!important}#lkrl-wrapper .ring-0{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)!important;--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(var(--tw-ring-offset-width)) var(--tw-ring-color)!important;box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)!important}#lkrl-wrapper .filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)!important}#lkrl-wrapper .transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter!important;transition-timing-function:cubic-bezier(.4,0,.2,1)!important;transition-duration:.15s!important}#lkrl-wrapper .transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke!important;transition-timing-function:cubic-bezier(.4,0,.2,1)!important;transition-duration:.15s!important}#lkrl-wrapper .duration-200{transition-duration:.2s!important}#lkrl-wrapper .ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)!important}#lkrl-wrapper .hover\:border-primary-hover:hover{border-color:var(--leckerli-primary-hover,#047857)!important}#lkrl-wrapper .hover\:bg-primary-hover:hover{background-color:var(--leckerli-primary-hover,#047857)!important}#lkrl-wrapper .hover\:text-primary-hover:hover{color:var(--leckerli-primary-hover,#047857)!important}#lkrl-wrapper .focus\:outline-none:focus{outline:2px solid #0000!important;outline-offset:2px!important}#lkrl-wrapper .focus\:ring-2:focus{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)!important;--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color)!important;box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)!important}#lkrl-wrapper .focus\:ring-primary:focus{--tw-ring-color:var(--leckerli-primary,#059669)!important}#lkrl-wrapper .focus\:ring-offset-2:focus{--tw-ring-offset-width:2px!important}#lkrl-wrapper .active\:border-primary-active:active{border-color:var(--leckerli-primary-active,#064e3b)!important}#lkrl-wrapper .active\:bg-primary-active:active{background-color:var(--leckerli-primary-active,#064e3b)!important}#lkrl-wrapper .active\:text-primary-active:active{color:var(--leckerli-primary-active,#064e3b)!important}@media (min-width:768px){#lkrl-wrapper .md\:px-3{padding-left:.75rem!important;padding-right:.75rem!important}#lkrl-wrapper .md\:px-3\.5{padding-left:.875rem!important;padding-right:.875rem!important}#lkrl-wrapper .md\:py-2{padding-top:.5rem!important;padding-bottom:.5rem!important}#lkrl-wrapper .md\:py-2\.5{padding-top:.625rem!important;padding-bottom:.625rem!important}#lkrl-wrapper .md\:text-2xl{font-size:1.5rem!important;line-height:2rem!important}#lkrl-wrapper .md\:text-base{font-size:1rem!important;line-height:1.5rem!important}#lkrl-wrapper .md\:text-xl{font-size:1.25rem!important;line-height:1.75rem!important}}
|
|
@@ -7,4 +7,4 @@
|
|
|
7
7
|
*
|
|
8
8
|
* This source code is licensed under the MIT license found in the
|
|
9
9
|
* LICENSE file in the root directory of this source tree.
|
|
10
|
-
*/var Xn="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},Kn=$n.useSyncExternalStore,Zn=Yn.useRef,Jn=Yn.useEffect,Qn=Yn.useMemo,er=Yn.useDebugValue;Mn.useSyncExternalStoreWithSelector=function(e,t,n,r,o){var i=Zn(null);if(null===i.current){var a={hasValue:!1,value:null};i.current=a}else a=i.current;i=Qn((function(){function e(e){if(!l){if(l=!0,i=e,e=r(e),void 0!==o&&a.hasValue){var t=a.value;if(o(t,e))return u=t}return u=e}if(t=u,Xn(i,e))return t;var n=r(e);return void 0!==o&&o(t,n)?t:(i=e,u=n)}var i,u,l=!1,c=void 0===n?null:n;return[function(){return e(t())},null===c?void 0:function(){return e(c())}]}),[t,n,r,o]);var u=Kn(e,i[0],i[1]);return Jn((function(){a.hasValue=!0,a.value=u}),[u]),er(u),u},In.exports=Mn;var tr=Rn(In.exports);const{useSyncExternalStoreWithSelector:nr}=tr;let rr=!1;const or=e=>{"function"!=typeof e&&console.warn("[DEPRECATED] Passing a vanilla store will be unsupported in a future version. Instead use `import { useStore } from 'zustand'`.");const t="function"==typeof e?(e=>e?wt(e):wt)(e):e,n=(e,n)=>function(e,t=e.getState,n){n&&!rr&&(console.warn("[DEPRECATED] Use `createWithEqualityFn` instead of `create` or use `useStoreWithEqualityFn` instead of `useStore`. They can be imported from 'zustand/traditional'. https://github.com/pmndrs/zustand/discussions/1937"),rr=!0);const r=nr(e.subscribe,e.getState,e.getServerState||e.getState,t,n);return ve(r),r}(t,e,n);return Object.assign(n,t),n},ir=At({name:"leckerli",expires:92,banner:{title:"This website uses cookies.",description:'We use cookies to improve your browsing experience, deliver personalised advertising or content and analyse our traffic. By clicking on "Accept all", you consent to our use of cookies.',accept:"Accept all",reject:"Deny",customise:"Customize",customiseDescription:"",save:"Save",settings:[{slug:"analytics_storage",title:"Statistics",description:"Statistic cookies help website owners to understand how visitors interact with websites by collecting and reporting information anonymously."},{slug:"ad_storage",title:"Marketing",description:"Marketing cookies are used to track visitors across websites. The intention is to display ads that are relevant and engaging for the individual user and thereby more valuable for publishers and third party advertisers."}]},permissions:["analytics_storage","ad_storage"],baseData:{},cookie:{},choiceMade:!1,settingsOpen:!1,domain:window.location.hostname,enableGtmAutoLoad:!1},window.leckerliSettings??{}),ar={sameSite:"strict",domain:ir.domain,expires:ir.expires},ur=Ne.get(ir.name);ir.cookie=St(ur)?JSON.parse(ur):ir.permissions.reduce(((e,t)=>({...e,[t]:!1})),ir.baseData),ir.choiceMade=St(ur)&>(kt(Object.keys(ir.cookie).filter((e=>!Object.keys(ir.baseData).includes(e))),ir.permissions));const lr=(cr=(e,t)=>({...ir,init:()=>{const e=t();ft(ur)&&e.choiceMade&&Ne.set(e.name,JSON.stringify(e.cookie),ar),document.dispatchEvent(new CustomEvent("leckerli:initialised",{detail:{cookie:e.choiceMade?e.cookie:null}})),document.addEventListener("leckerli:open-banner",(()=>t().setChoice(!1))),document.addEventListener("leckerli:close-banner",(()=>t().setChoice(!0))),document.addEventListener("leckerli:open-modal",(()=>t().setModal(!0))),document.addEventListener("leckerli:close-modal",(()=>t().setModal(!1)))},propagate(e){const n=t();Ne.set(n.name,JSON.stringify(e),ar),document.dispatchEvent(new CustomEvent("leckerli:permissions-updated",{detail:{cookie:e}}))},setChoice:t=>e((e=>({...e,choiceMade:t}))),setModal:t=>e((e=>(document.dispatchEvent(new CustomEvent("leckerli:modal-"+(t?"opened":"closed"))),{...e,settingsOpen:t}))),setPermissions:t=>e((e=>{const n=e.permissions.reduce(((e,n)=>({...e,[n]:t[n]??!1})),e.baseData);return e.propagate(n),{...e,choiceMade:!0,cookie:n}})),togglePermission:t=>e((e=>{const n=e.permissions.reduce(((n,r)=>(n[r]=t===r?!St(e.cookie[r])||!e.cookie[r]:e.cookie[r]??!1,n)),e.baseData);return e.propagate(n),{...e,choiceMade:!0,cookie:n}})),acceptAll:()=>{t().setPermissions(t().permissions.reduce(((e,t)=>({...e,[t]:!0})),{}))},rejectAll:()=>{t().setPermissions(t().permissions.reduce(((e,t)=>({...e,[t]:!1})),{}))}}))?or(cr):or;/*! @license DOMPurify 3.3.1 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.1/LICENSE */var cr;const{entries:sr,setPrototypeOf:fr,isFrozen:_r,getPrototypeOf:pr,getOwnPropertyDescriptor:dr}=Object;let{freeze:mr,seal:hr,create:yr}=Object,{apply:vr,construct:gr}="undefined"!=typeof Reflect&&Reflect;mr||(mr=function(e){return e}),hr||(hr=function(e){return e}),vr||(vr=function(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];return e.apply(t,r)}),gr||(gr=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return new e(...n)});const br=Mr(Array.prototype.forEach),Sr=Mr(Array.prototype.lastIndexOf),Er=Mr(Array.prototype.pop),Tr=Mr(Array.prototype.push),Ar=Mr(Array.prototype.splice),kr=Mr(String.prototype.toLowerCase),wr=Mr(String.prototype.toString),xr=Mr(String.prototype.match),Nr=Mr(String.prototype.replace),Cr=Mr(String.prototype.indexOf),Or=Mr(String.prototype.trim),Dr=Mr(Object.prototype.hasOwnProperty),Rr=Mr(RegExp.prototype.test),Lr=(Ir=TypeError,function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return gr(Ir,t)});var Ir;function Mr(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return vr(e,t,r)}}function Ur(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:kr;fr&&fr(e,null);let r=t.length;for(;r--;){let o=t[r];if("string"==typeof o){const e=n(o);e!==o&&(_r(t)||(t[r]=e),o=e)}e[o]=!0}return e}function Pr(e){for(let t=0;t<e.length;t++){Dr(e,t)||(e[t]=null)}return e}function jr(e){const t=yr(null);for(const[n,r]of sr(e)){Dr(e,n)&&(Array.isArray(r)?t[n]=Pr(r):r&&"object"==typeof r&&r.constructor===Object?t[n]=jr(r):t[n]=r)}return t}function Fr(e,t){for(;null!==e;){const n=dr(e,t);if(n){if(n.get)return Mr(n.get);if("function"==typeof n.value)return Mr(n.value)}e=pr(e)}return function(){return null}}const zr=mr(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Hr=mr(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Wr=mr(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),Br=mr(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),Gr=mr(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),qr=mr(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Vr=mr(["#text"]),Yr=mr(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),$r=mr(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Xr=mr(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Kr=mr(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Zr=hr(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Jr=hr(/<%[\w\W]*|[\w\W]*%>/gm),Qr=hr(/\$\{[\w\W]*/gm),eo=hr(/^data-[\-\w.\u00B7-\uFFFF]+$/),to=hr(/^aria-[\-\w]+$/),no=hr(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),ro=hr(/^(?:\w+script|data):/i),oo=hr(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),io=hr(/^html$/i),ao=hr(/^[a-z][.\w]*(-[.\w]+)+$/i);var uo=Object.freeze({__proto__:null,ARIA_ATTR:to,ATTR_WHITESPACE:oo,CUSTOM_ELEMENT:ao,DATA_ATTR:eo,DOCTYPE_NAME:io,ERB_EXPR:Jr,IS_ALLOWED_URI:no,IS_SCRIPT_OR_DATA:ro,MUSTACHE_EXPR:Zr,TMPLIT_EXPR:Qr});const lo=1,co=3,so=7,fo=8,_o=9,po=function(){return"undefined"==typeof window?null:window};var mo=function e(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:po();const n=t=>e(t);if(n.version="3.3.1",n.removed=[],!t||!t.document||t.document.nodeType!==_o||!t.Element)return n.isSupported=!1,n;let{document:r}=t;const o=r,i=o.currentScript,{DocumentFragment:a,HTMLTemplateElement:u,Node:l,Element:c,NodeFilter:s,NamedNodeMap:f=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:_,DOMParser:p,trustedTypes:d}=t,m=c.prototype,h=Fr(m,"cloneNode"),y=Fr(m,"remove"),v=Fr(m,"nextSibling"),g=Fr(m,"childNodes"),b=Fr(m,"parentNode");if("function"==typeof u){const e=r.createElement("template");e.content&&e.content.ownerDocument&&(r=e.content.ownerDocument)}let S,E="";const{implementation:T,createNodeIterator:A,createDocumentFragment:k,getElementsByTagName:w}=r,{importNode:x}=o;let N={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]};n.isSupported="function"==typeof sr&&"function"==typeof b&&T&&void 0!==T.createHTMLDocument;const{MUSTACHE_EXPR:C,ERB_EXPR:O,TMPLIT_EXPR:D,DATA_ATTR:R,ARIA_ATTR:L,IS_SCRIPT_OR_DATA:I,ATTR_WHITESPACE:M,CUSTOM_ELEMENT:U}=uo;let{IS_ALLOWED_URI:P}=uo,j=null;const F=Ur({},[...zr,...Hr,...Wr,...Gr,...Vr]);let z=null;const H=Ur({},[...Yr,...$r,...Xr,...Kr]);let W=Object.seal(yr(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),B=null,G=null;const q=Object.seal(yr(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let V=!0,Y=!0,$=!1,X=!0,K=!1,Z=!0,J=!1,Q=!1,ee=!1,te=!1,ne=!1,re=!1,oe=!0,ie=!1,ae=!0,ue=!1,le={},ce=null;const se=Ur({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let fe=null;const _e=Ur({},["audio","video","img","source","image","track"]);let pe=null;const de=Ur({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),me="http://www.w3.org/1998/Math/MathML",he="http://www.w3.org/2000/svg",ye="http://www.w3.org/1999/xhtml";let ve=ye,ge=!1,be=null;const Se=Ur({},[me,he,ye],wr);let Ee=Ur({},["mi","mo","mn","ms","mtext"]),Te=Ur({},["annotation-xml"]);const Ae=Ur({},["title","style","font","a","script"]);let ke=null;const we=["application/xhtml+xml","text/html"];let xe=null,Ne=null;const Ce=r.createElement("form"),Oe=function(e){return e instanceof RegExp||e instanceof Function},De=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!Ne||Ne!==e){if(e&&"object"==typeof e||(e={}),e=jr(e),ke=-1===we.indexOf(e.PARSER_MEDIA_TYPE)?"text/html":e.PARSER_MEDIA_TYPE,xe="application/xhtml+xml"===ke?wr:kr,j=Dr(e,"ALLOWED_TAGS")?Ur({},e.ALLOWED_TAGS,xe):F,z=Dr(e,"ALLOWED_ATTR")?Ur({},e.ALLOWED_ATTR,xe):H,be=Dr(e,"ALLOWED_NAMESPACES")?Ur({},e.ALLOWED_NAMESPACES,wr):Se,pe=Dr(e,"ADD_URI_SAFE_ATTR")?Ur(jr(de),e.ADD_URI_SAFE_ATTR,xe):de,fe=Dr(e,"ADD_DATA_URI_TAGS")?Ur(jr(_e),e.ADD_DATA_URI_TAGS,xe):_e,ce=Dr(e,"FORBID_CONTENTS")?Ur({},e.FORBID_CONTENTS,xe):se,B=Dr(e,"FORBID_TAGS")?Ur({},e.FORBID_TAGS,xe):jr({}),G=Dr(e,"FORBID_ATTR")?Ur({},e.FORBID_ATTR,xe):jr({}),le=!!Dr(e,"USE_PROFILES")&&e.USE_PROFILES,V=!1!==e.ALLOW_ARIA_ATTR,Y=!1!==e.ALLOW_DATA_ATTR,$=e.ALLOW_UNKNOWN_PROTOCOLS||!1,X=!1!==e.ALLOW_SELF_CLOSE_IN_ATTR,K=e.SAFE_FOR_TEMPLATES||!1,Z=!1!==e.SAFE_FOR_XML,J=e.WHOLE_DOCUMENT||!1,te=e.RETURN_DOM||!1,ne=e.RETURN_DOM_FRAGMENT||!1,re=e.RETURN_TRUSTED_TYPE||!1,ee=e.FORCE_BODY||!1,oe=!1!==e.SANITIZE_DOM,ie=e.SANITIZE_NAMED_PROPS||!1,ae=!1!==e.KEEP_CONTENT,ue=e.IN_PLACE||!1,P=e.ALLOWED_URI_REGEXP||no,ve=e.NAMESPACE||ye,Ee=e.MATHML_TEXT_INTEGRATION_POINTS||Ee,Te=e.HTML_INTEGRATION_POINTS||Te,W=e.CUSTOM_ELEMENT_HANDLING||{},e.CUSTOM_ELEMENT_HANDLING&&Oe(e.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(W.tagNameCheck=e.CUSTOM_ELEMENT_HANDLING.tagNameCheck),e.CUSTOM_ELEMENT_HANDLING&&Oe(e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(W.attributeNameCheck=e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),e.CUSTOM_ELEMENT_HANDLING&&"boolean"==typeof e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements&&(W.allowCustomizedBuiltInElements=e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),K&&(Y=!1),ne&&(te=!0),le&&(j=Ur({},Vr),z=[],!0===le.html&&(Ur(j,zr),Ur(z,Yr)),!0===le.svg&&(Ur(j,Hr),Ur(z,$r),Ur(z,Kr)),!0===le.svgFilters&&(Ur(j,Wr),Ur(z,$r),Ur(z,Kr)),!0===le.mathMl&&(Ur(j,Gr),Ur(z,Xr),Ur(z,Kr))),e.ADD_TAGS&&("function"==typeof e.ADD_TAGS?q.tagCheck=e.ADD_TAGS:(j===F&&(j=jr(j)),Ur(j,e.ADD_TAGS,xe))),e.ADD_ATTR&&("function"==typeof e.ADD_ATTR?q.attributeCheck=e.ADD_ATTR:(z===H&&(z=jr(z)),Ur(z,e.ADD_ATTR,xe))),e.ADD_URI_SAFE_ATTR&&Ur(pe,e.ADD_URI_SAFE_ATTR,xe),e.FORBID_CONTENTS&&(ce===se&&(ce=jr(ce)),Ur(ce,e.FORBID_CONTENTS,xe)),e.ADD_FORBID_CONTENTS&&(ce===se&&(ce=jr(ce)),Ur(ce,e.ADD_FORBID_CONTENTS,xe)),ae&&(j["#text"]=!0),J&&Ur(j,["html","head","body"]),j.table&&(Ur(j,["tbody"]),delete B.tbody),e.TRUSTED_TYPES_POLICY){if("function"!=typeof e.TRUSTED_TYPES_POLICY.createHTML)throw Lr('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!=typeof e.TRUSTED_TYPES_POLICY.createScriptURL)throw Lr('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');S=e.TRUSTED_TYPES_POLICY,E=S.createHTML("")}else void 0===S&&(S=function(e,t){if("object"!=typeof e||"function"!=typeof e.createPolicy)return null;let n=null;const r="data-tt-policy-suffix";t&&t.hasAttribute(r)&&(n=t.getAttribute(r));const o="dompurify"+(n?"#"+n:"");try{return e.createPolicy(o,{createHTML:e=>e,createScriptURL:e=>e})}catch(e){return console.warn("TrustedTypes policy "+o+" could not be created."),null}}(d,i)),null!==S&&"string"==typeof E&&(E=S.createHTML(""));mr&&mr(e),Ne=e}},Re=Ur({},[...Hr,...Wr,...Br]),Le=Ur({},[...Gr,...qr]),Ie=function(e){Tr(n.removed,{element:e});try{b(e).removeChild(e)}catch(t){y(e)}},Me=function(e,t){try{Tr(n.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){Tr(n.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e)if(te||ne)try{Ie(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}},Ue=function(e){let t=null,n=null;if(ee)e="<remove></remove>"+e;else{const t=xr(e,/^[\r\n\t ]+/);n=t&&t[0]}"application/xhtml+xml"===ke&&ve===ye&&(e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");const o=S?S.createHTML(e):e;if(ve===ye)try{t=(new p).parseFromString(o,ke)}catch(e){}if(!t||!t.documentElement){t=T.createDocument(ve,"template",null);try{t.documentElement.innerHTML=ge?E:o}catch(e){}}const i=t.body||t.documentElement;return e&&n&&i.insertBefore(r.createTextNode(n),i.childNodes[0]||null),ve===ye?w.call(t,J?"html":"body")[0]:J?t.documentElement:i},Pe=function(e){return A.call(e.ownerDocument||e,e,s.SHOW_ELEMENT|s.SHOW_COMMENT|s.SHOW_TEXT|s.SHOW_PROCESSING_INSTRUCTION|s.SHOW_CDATA_SECTION,null)},je=function(e){return e instanceof _&&("string"!=typeof e.nodeName||"string"!=typeof e.textContent||"function"!=typeof e.removeChild||!(e.attributes instanceof f)||"function"!=typeof e.removeAttribute||"function"!=typeof e.setAttribute||"string"!=typeof e.namespaceURI||"function"!=typeof e.insertBefore||"function"!=typeof e.hasChildNodes)},Fe=function(e){return"function"==typeof l&&e instanceof l};function ze(e,t,r){br(e,(e=>{e.call(n,t,r,Ne)}))}const He=function(e){let t=null;if(ze(N.beforeSanitizeElements,e,null),je(e))return Ie(e),!0;const r=xe(e.nodeName);if(ze(N.uponSanitizeElement,e,{tagName:r,allowedTags:j}),Z&&e.hasChildNodes()&&!Fe(e.firstElementChild)&&Rr(/<[/\w!]/g,e.innerHTML)&&Rr(/<[/\w!]/g,e.textContent))return Ie(e),!0;if(e.nodeType===so)return Ie(e),!0;if(Z&&e.nodeType===fo&&Rr(/<[/\w]/g,e.data))return Ie(e),!0;if(!(q.tagCheck instanceof Function&&q.tagCheck(r))&&(!j[r]||B[r])){if(!B[r]&&Be(r)){if(W.tagNameCheck instanceof RegExp&&Rr(W.tagNameCheck,r))return!1;if(W.tagNameCheck instanceof Function&&W.tagNameCheck(r))return!1}if(ae&&!ce[r]){const t=b(e)||e.parentNode,n=g(e)||e.childNodes;if(n&&t){for(let r=n.length-1;r>=0;--r){const o=h(n[r],!0);o.__removalCount=(e.__removalCount||0)+1,t.insertBefore(o,v(e))}}}return Ie(e),!0}return e instanceof c&&!function(e){let t=b(e);t&&t.tagName||(t={namespaceURI:ve,tagName:"template"});const n=kr(e.tagName),r=kr(t.tagName);return!!be[e.namespaceURI]&&(e.namespaceURI===he?t.namespaceURI===ye?"svg"===n:t.namespaceURI===me?"svg"===n&&("annotation-xml"===r||Ee[r]):Boolean(Re[n]):e.namespaceURI===me?t.namespaceURI===ye?"math"===n:t.namespaceURI===he?"math"===n&&Te[r]:Boolean(Le[n]):e.namespaceURI===ye?!(t.namespaceURI===he&&!Te[r])&&!(t.namespaceURI===me&&!Ee[r])&&!Le[n]&&(Ae[n]||!Re[n]):!("application/xhtml+xml"!==ke||!be[e.namespaceURI]))}(e)?(Ie(e),!0):"noscript"!==r&&"noembed"!==r&&"noframes"!==r||!Rr(/<\/no(script|embed|frames)/i,e.innerHTML)?(K&&e.nodeType===co&&(t=e.textContent,br([C,O,D],(e=>{t=Nr(t,e," ")})),e.textContent!==t&&(Tr(n.removed,{element:e.cloneNode()}),e.textContent=t)),ze(N.afterSanitizeElements,e,null),!1):(Ie(e),!0)},We=function(e,t,n){if(oe&&("id"===t||"name"===t)&&(n in r||n in Ce))return!1;if(Y&&!G[t]&&Rr(R,t));else if(V&&Rr(L,t));else if(q.attributeCheck instanceof Function&&q.attributeCheck(t,e));else if(!z[t]||G[t]){if(!(Be(e)&&(W.tagNameCheck instanceof RegExp&&Rr(W.tagNameCheck,e)||W.tagNameCheck instanceof Function&&W.tagNameCheck(e))&&(W.attributeNameCheck instanceof RegExp&&Rr(W.attributeNameCheck,t)||W.attributeNameCheck instanceof Function&&W.attributeNameCheck(t,e))||"is"===t&&W.allowCustomizedBuiltInElements&&(W.tagNameCheck instanceof RegExp&&Rr(W.tagNameCheck,n)||W.tagNameCheck instanceof Function&&W.tagNameCheck(n))))return!1}else if(pe[t]);else if(Rr(P,Nr(n,M,"")));else if("src"!==t&&"xlink:href"!==t&&"href"!==t||"script"===e||0!==Cr(n,"data:")||!fe[e]){if($&&!Rr(I,Nr(n,M,"")));else if(n)return!1}else;return!0},Be=function(e){return"annotation-xml"!==e&&xr(e,U)},Ge=function(e){ze(N.beforeSanitizeAttributes,e,null);const{attributes:t}=e;if(!t||je(e))return;const r={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:z,forceKeepAttr:void 0};let o=t.length;for(;o--;){const i=t[o],{name:a,namespaceURI:u,value:l}=i,c=xe(a),s=l;let f="value"===a?s:Or(s);if(r.attrName=c,r.attrValue=f,r.keepAttr=!0,r.forceKeepAttr=void 0,ze(N.uponSanitizeAttribute,e,r),f=r.attrValue,!ie||"id"!==c&&"name"!==c||(Me(a,e),f="user-content-"+f),Z&&Rr(/((--!?|])>)|<\/(style|title|textarea)/i,f)){Me(a,e);continue}if("attributename"===c&&xr(f,"href")){Me(a,e);continue}if(r.forceKeepAttr)continue;if(!r.keepAttr){Me(a,e);continue}if(!X&&Rr(/\/>/i,f)){Me(a,e);continue}K&&br([C,O,D],(e=>{f=Nr(f,e," ")}));const _=xe(e.nodeName);if(We(_,c,f)){if(S&&"object"==typeof d&&"function"==typeof d.getAttributeType)if(u);else switch(d.getAttributeType(_,c)){case"TrustedHTML":f=S.createHTML(f);break;case"TrustedScriptURL":f=S.createScriptURL(f)}if(f!==s)try{u?e.setAttributeNS(u,a,f):e.setAttribute(a,f),je(e)?Ie(e):Er(n.removed)}catch(t){Me(a,e)}}else Me(a,e)}ze(N.afterSanitizeAttributes,e,null)},qe=function e(t){let n=null;const r=Pe(t);for(ze(N.beforeSanitizeShadowDOM,t,null);n=r.nextNode();)ze(N.uponSanitizeShadowNode,n,null),He(n),Ge(n),n.content instanceof a&&e(n.content);ze(N.afterSanitizeShadowDOM,t,null)};return n.sanitize=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=null,i=null,u=null,c=null;if(ge=!e,ge&&(e="\x3c!--\x3e"),"string"!=typeof e&&!Fe(e)){if("function"!=typeof e.toString)throw Lr("toString is not a function");if("string"!=typeof(e=e.toString()))throw Lr("dirty is not a string, aborting")}if(!n.isSupported)return e;if(Q||De(t),n.removed=[],"string"==typeof e&&(ue=!1),ue){if(e.nodeName){const t=xe(e.nodeName);if(!j[t]||B[t])throw Lr("root node is forbidden and cannot be sanitized in-place")}}else if(e instanceof l)r=Ue("\x3c!----\x3e"),i=r.ownerDocument.importNode(e,!0),i.nodeType===lo&&"BODY"===i.nodeName||"HTML"===i.nodeName?r=i:r.appendChild(i);else{if(!te&&!K&&!J&&-1===e.indexOf("<"))return S&&re?S.createHTML(e):e;if(r=Ue(e),!r)return te?null:re?E:""}r&&ee&&Ie(r.firstChild);const s=Pe(ue?e:r);for(;u=s.nextNode();)He(u),Ge(u),u.content instanceof a&&qe(u.content);if(ue)return e;if(te){if(ne)for(c=k.call(r.ownerDocument);r.firstChild;)c.appendChild(r.firstChild);else c=r;return(z.shadowroot||z.shadowrootmode)&&(c=x.call(o,c,!0)),c}let f=J?r.outerHTML:r.innerHTML;return J&&j["!doctype"]&&r.ownerDocument&&r.ownerDocument.doctype&&r.ownerDocument.doctype.name&&Rr(io,r.ownerDocument.doctype.name)&&(f="<!DOCTYPE "+r.ownerDocument.doctype.name+">\n"+f),K&&br([C,O,D],(e=>{f=Nr(f,e," ")})),S&&re?S.createHTML(f):f},n.setConfig=function(){De(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}),Q=!0},n.clearConfig=function(){Ne=null,Q=!1},n.isValidAttribute=function(e,t,n){Ne||De({});const r=xe(e),o=xe(t);return We(r,o,n)},n.addHook=function(e,t){"function"==typeof t&&Tr(N[e],t)},n.removeHook=function(e,t){if(void 0!==t){const n=Sr(N[e],t);return-1===n?void 0:Ar(N[e],n,1)[0]}return Er(N[e])},n.removeHooks=function(e){N[e]=[]},n.removeAllHooks=function(){N={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},n}();const ho=()=>{const{banner:e,acceptAll:t,rejectAll:n,setModal:r}=lr();return $("div",{className:"fixed bottom-0 left-0 max-w-md px-5 py-4 m-2 shadow-md shadow-black/25 z-[9998] bg-background space-y-4 font-primary text-foreground rounded-md banner-wrapper",children:[e.title&&$("h3",{className:"m-0 text-lg font-semibold font-primary md:text-xl banner-title",children:e.title}),e.description&&$("p",{className:"m-0 text-sm leading-snug font-primary md:text-base banner-description",dangerouslySetInnerHTML:{__html:mo.sanitize(e.description,{USE_PROFILES:{html:!0},ALLOWED_TAGS:["b","i","em","strong","p","ul","li","ol","span","h2","h3","h4","h5","h6","a","div"],ALLOWED_ATTR:["href","target"]})}}),$("div",{className:"pt-2 space-y-2 banner-btns",children:[!gt(e.settings)&&$("button",{type:"button",className:"px-2 mr-2 text-sm font-semibold border-2 border-solid rounded bg-background font-primary text-primary md:px-3.5 py-1.5 md:py-2.5 border-primary hover:border-primary-hover hover:text-primary-hover active:border-primary-active active:text-primary-active transition-colors banner-btn-customise",onClick:()=>r(!0),children:e.customise}),$("button",{type:"button",className:"px-2 mr-2 text-sm font-semibold border-2 border-solid rounded bg-background font-primary text-primary md:px-3.5 py-1.5 md:py-2.5 border-primary hover:border-primary-hover hover:text-primary-hover active:border-primary-active active:text-primary-active transition-colors banner-btn-reject",onClick:n,children:e.reject}),$("button",{type:"button",className:"px-2 mr-2 text-sm font-semibold border-2 border-solid rounded bg-primary font-primary text-background md:px-3.5 py-1.5 md:py-2.5 border-primary hover:bg-primary-hover hover:border-primary-hover active:bg-primary-active active:border-primary-active transition-colors banner-btn-accept",onClick:t,children:e.accept})]})]})},yo=()=>{const{cookie:e,setPermissions:t,banner:n,setModal:r}=lr(),[o,i]=ce(e);return $("div",{className:"fixed bottom-0 left-0 w-full max-w-lg max-h-full px-5 py-4 m-2 overflow-y-auto text-black shadow-md shadow-black/25 z-[9999] bg-background text-foreground font-primary rounded-md banner-wrapper",children:[$("div",{className:"space-y-6",children:[$("div",{children:[$("h3",{className:"w-10/12 m-0 text-xl font-semibold font-primary md:text-2xl banner-title",children:n.customise}),n.customiseDescription&&$("p",{className:"m-0 mt-2 text-sm leading-snug font-primary md:text-base banner-settings-general-description",dangerouslySetInnerHTML:{__html:mo.sanitize(n.customiseDescription,{USE_PROFILES:{html:!0},ALLOWED_TAGS:["b","i","em","strong","p","ul","li","ol","span","h2","h3","h4","h5","h6","a","div"],ALLOWED_ATTR:["href","target"]})}})]}),n.settings.map((({slug:e,title:t,description:n})=>$("div",{children:[$("div",{className:"flex items-start justify-between",children:[$("h3",{className:"m-0 text-lg font-semibold font-primary banner-settings-title",children:t}),$("button",{type:"button",className:(o[e]?"bg-primary":"bg-gray-200")+" relative inline-flex h-6 w-11 flex-shrink-0 cursor-pointer rounded-full border-2 border-transparent transition-colors duration-200 ease-in-out focus:outline-none focus:ring-2 focus:ring-primary focus:ring-offset-2 mt-0.5 banner-settings-toggle",role:"switch","aria-checked":"false",onClick:()=>i({...o,[e]:!o[e]}),children:[$("span",{className:"sr-only",children:"Toggle"}),$("span",{"aria-hidden":"true",className:(o[e]?"translate-x-5":"translate-x-0")+" pointer-events-none inline-block h-5 w-5 transform rounded-full bg-background shadow ring-0 transition duration-200 ease-in-out"})]})]}),$("p",{className:"m-0 mt-2 text-sm leading-snug font-primary md:text-base banner-settings-description",children:n})]},`setting-${e}`))),$("div",{className:"pt-4",children:$("button",{type:"button",className:"px-2 mr-2 text-sm font-semibold border-2 border-solid rounded bg-primary font-primary text-background md:px-3.5 py-1.5 md:py-2.5 border-primary hover:bg-primary-hover hover:border-primary-hover active:bg-primary-active active:border-primary-active transition-colors banner-settings-save",onClick:()=>{t(o),r(!1)},children:n.save})})]}),$("button",{type:"button",className:"absolute top-0 right-0 w-8 h-8 mt-0 text-xl rounded-full banner-settings-close",onClick:()=>r(!1),children:"×"})]})},vo=document.createElement("div");vo.id="lkrl-wrapper",document.body.appendChild(vo),B($((()=>{const{choiceMade:e,init:t,settingsOpen:n}=lr();return fe((()=>{t()}),[]),$(S,{children:[!e&&!n&&$(ho,{}),n&&$(yo,{})]})}),{}),vo)}();
|
|
10
|
+
*/var Xn="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},Kn=$n.useSyncExternalStore,Zn=Yn.useRef,Jn=Yn.useEffect,Qn=Yn.useMemo,er=Yn.useDebugValue;Mn.useSyncExternalStoreWithSelector=function(e,t,n,r,o){var i=Zn(null);if(null===i.current){var a={hasValue:!1,value:null};i.current=a}else a=i.current;i=Qn((function(){function e(e){if(!l){if(l=!0,i=e,e=r(e),void 0!==o&&a.hasValue){var t=a.value;if(o(t,e))return u=t}return u=e}if(t=u,Xn(i,e))return t;var n=r(e);return void 0!==o&&o(t,n)?t:(i=e,u=n)}var i,u,l=!1,c=void 0===n?null:n;return[function(){return e(t())},null===c?void 0:function(){return e(c())}]}),[t,n,r,o]);var u=Kn(e,i[0],i[1]);return Jn((function(){a.hasValue=!0,a.value=u}),[u]),er(u),u},In.exports=Mn;var tr=Rn(In.exports);const{useSyncExternalStoreWithSelector:nr}=tr;let rr=!1;const or=e=>{"function"!=typeof e&&console.warn("[DEPRECATED] Passing a vanilla store will be unsupported in a future version. Instead use `import { useStore } from 'zustand'`.");const t="function"==typeof e?(e=>e?wt(e):wt)(e):e,n=(e,n)=>function(e,t=e.getState,n){n&&!rr&&(console.warn("[DEPRECATED] Use `createWithEqualityFn` instead of `create` or use `useStoreWithEqualityFn` instead of `useStore`. They can be imported from 'zustand/traditional'. https://github.com/pmndrs/zustand/discussions/1937"),rr=!0);const r=nr(e.subscribe,e.getState,e.getServerState||e.getState,t,n);return ve(r),r}(t,e,n);return Object.assign(n,t),n},ir=At({name:"leckerli",expires:92,banner:{title:"This website uses cookies.",description:'We use cookies to improve your browsing experience, deliver personalised advertising or content and analyse our traffic. By clicking on "Accept all", you consent to our use of cookies.',accept:"Accept all",reject:"Deny",customise:"Customize",customiseDescription:"",save:"Save",settings:[{slug:"analytics_storage",title:"Statistics",description:"Statistic cookies help website owners to understand how visitors interact with websites by collecting and reporting information anonymously."},{slug:"ad_storage",title:"Marketing",description:"Marketing cookies are used to track visitors across websites. The intention is to display ads that are relevant and engaging for the individual user and thereby more valuable for publishers and third party advertisers."}]},permissions:["analytics_storage","ad_storage"],baseData:{},cookie:{},choiceMade:!1,settingsOpen:!1,domain:window.location.hostname,enableGtmAutoLoad:!1,displayDelay:0},window.leckerliSettings??{}),ar={sameSite:"strict",domain:ir.domain,expires:ir.expires},ur=Ne.get(ir.name);ir.cookie=St(ur)?JSON.parse(ur):ir.permissions.reduce(((e,t)=>({...e,[t]:!1})),ir.baseData),ir.choiceMade=St(ur)&>(kt(Object.keys(ir.cookie).filter((e=>!Object.keys(ir.baseData).includes(e))),ir.permissions));const lr=(cr=(e,t)=>({...ir,init:()=>{const e=t();ft(ur)&&e.choiceMade&&Ne.set(e.name,JSON.stringify(e.cookie),ar),document.dispatchEvent(new CustomEvent("leckerli:initialised",{detail:{cookie:e.choiceMade?e.cookie:null}})),document.addEventListener("leckerli:open-banner",(()=>t().setChoice(!1))),document.addEventListener("leckerli:close-banner",(()=>t().setChoice(!0))),document.addEventListener("leckerli:open-modal",(()=>t().setModal(!0))),document.addEventListener("leckerli:close-modal",(()=>t().setModal(!1)))},propagate(e){const n=t();Ne.set(n.name,JSON.stringify(e),ar),document.dispatchEvent(new CustomEvent("leckerli:permissions-updated",{detail:{cookie:e}}))},setChoice:t=>e((e=>({...e,choiceMade:t}))),setModal:t=>e((e=>(document.dispatchEvent(new CustomEvent("leckerli:modal-"+(t?"opened":"closed"))),{...e,settingsOpen:t}))),setPermissions:t=>e((e=>{const n=e.permissions.reduce(((e,n)=>({...e,[n]:t[n]??!1})),e.baseData);return e.propagate(n),{...e,choiceMade:!0,cookie:n}})),togglePermission:t=>e((e=>{const n=e.permissions.reduce(((n,r)=>(n[r]=t===r?!St(e.cookie[r])||!e.cookie[r]:e.cookie[r]??!1,n)),e.baseData);return e.propagate(n),{...e,choiceMade:!0,cookie:n}})),acceptAll:()=>{t().setPermissions(t().permissions.reduce(((e,t)=>({...e,[t]:!0})),{}))},rejectAll:()=>{t().setPermissions(t().permissions.reduce(((e,t)=>({...e,[t]:!1})),{}))}}))?or(cr):or;/*! @license DOMPurify 3.3.1 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.1/LICENSE */var cr;const{entries:sr,setPrototypeOf:fr,isFrozen:_r,getPrototypeOf:pr,getOwnPropertyDescriptor:dr}=Object;let{freeze:mr,seal:hr,create:yr}=Object,{apply:vr,construct:gr}="undefined"!=typeof Reflect&&Reflect;mr||(mr=function(e){return e}),hr||(hr=function(e){return e}),vr||(vr=function(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];return e.apply(t,r)}),gr||(gr=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return new e(...n)});const br=Mr(Array.prototype.forEach),Sr=Mr(Array.prototype.lastIndexOf),Er=Mr(Array.prototype.pop),Tr=Mr(Array.prototype.push),Ar=Mr(Array.prototype.splice),kr=Mr(String.prototype.toLowerCase),wr=Mr(String.prototype.toString),xr=Mr(String.prototype.match),Nr=Mr(String.prototype.replace),Cr=Mr(String.prototype.indexOf),Or=Mr(String.prototype.trim),Dr=Mr(Object.prototype.hasOwnProperty),Rr=Mr(RegExp.prototype.test),Lr=(Ir=TypeError,function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return gr(Ir,t)});var Ir;function Mr(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return vr(e,t,r)}}function Ur(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:kr;fr&&fr(e,null);let r=t.length;for(;r--;){let o=t[r];if("string"==typeof o){const e=n(o);e!==o&&(_r(t)||(t[r]=e),o=e)}e[o]=!0}return e}function Pr(e){for(let t=0;t<e.length;t++){Dr(e,t)||(e[t]=null)}return e}function jr(e){const t=yr(null);for(const[n,r]of sr(e)){Dr(e,n)&&(Array.isArray(r)?t[n]=Pr(r):r&&"object"==typeof r&&r.constructor===Object?t[n]=jr(r):t[n]=r)}return t}function Fr(e,t){for(;null!==e;){const n=dr(e,t);if(n){if(n.get)return Mr(n.get);if("function"==typeof n.value)return Mr(n.value)}e=pr(e)}return function(){return null}}const zr=mr(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Hr=mr(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Wr=mr(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),Br=mr(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),Gr=mr(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),qr=mr(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Vr=mr(["#text"]),Yr=mr(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),$r=mr(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Xr=mr(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Kr=mr(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Zr=hr(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Jr=hr(/<%[\w\W]*|[\w\W]*%>/gm),Qr=hr(/\$\{[\w\W]*/gm),eo=hr(/^data-[\-\w.\u00B7-\uFFFF]+$/),to=hr(/^aria-[\-\w]+$/),no=hr(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),ro=hr(/^(?:\w+script|data):/i),oo=hr(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),io=hr(/^html$/i),ao=hr(/^[a-z][.\w]*(-[.\w]+)+$/i);var uo=Object.freeze({__proto__:null,ARIA_ATTR:to,ATTR_WHITESPACE:oo,CUSTOM_ELEMENT:ao,DATA_ATTR:eo,DOCTYPE_NAME:io,ERB_EXPR:Jr,IS_ALLOWED_URI:no,IS_SCRIPT_OR_DATA:ro,MUSTACHE_EXPR:Zr,TMPLIT_EXPR:Qr});const lo=1,co=3,so=7,fo=8,_o=9,po=function(){return"undefined"==typeof window?null:window};var mo=function e(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:po();const n=t=>e(t);if(n.version="3.3.1",n.removed=[],!t||!t.document||t.document.nodeType!==_o||!t.Element)return n.isSupported=!1,n;let{document:r}=t;const o=r,i=o.currentScript,{DocumentFragment:a,HTMLTemplateElement:u,Node:l,Element:c,NodeFilter:s,NamedNodeMap:f=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:_,DOMParser:p,trustedTypes:d}=t,m=c.prototype,h=Fr(m,"cloneNode"),y=Fr(m,"remove"),v=Fr(m,"nextSibling"),g=Fr(m,"childNodes"),b=Fr(m,"parentNode");if("function"==typeof u){const e=r.createElement("template");e.content&&e.content.ownerDocument&&(r=e.content.ownerDocument)}let S,E="";const{implementation:T,createNodeIterator:A,createDocumentFragment:k,getElementsByTagName:w}=r,{importNode:x}=o;let N={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]};n.isSupported="function"==typeof sr&&"function"==typeof b&&T&&void 0!==T.createHTMLDocument;const{MUSTACHE_EXPR:C,ERB_EXPR:O,TMPLIT_EXPR:D,DATA_ATTR:R,ARIA_ATTR:L,IS_SCRIPT_OR_DATA:I,ATTR_WHITESPACE:M,CUSTOM_ELEMENT:U}=uo;let{IS_ALLOWED_URI:P}=uo,j=null;const F=Ur({},[...zr,...Hr,...Wr,...Gr,...Vr]);let z=null;const H=Ur({},[...Yr,...$r,...Xr,...Kr]);let W=Object.seal(yr(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),B=null,G=null;const q=Object.seal(yr(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let V=!0,Y=!0,$=!1,X=!0,K=!1,Z=!0,J=!1,Q=!1,ee=!1,te=!1,ne=!1,re=!1,oe=!0,ie=!1,ae=!0,ue=!1,le={},ce=null;const se=Ur({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let fe=null;const _e=Ur({},["audio","video","img","source","image","track"]);let pe=null;const de=Ur({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),me="http://www.w3.org/1998/Math/MathML",he="http://www.w3.org/2000/svg",ye="http://www.w3.org/1999/xhtml";let ve=ye,ge=!1,be=null;const Se=Ur({},[me,he,ye],wr);let Ee=Ur({},["mi","mo","mn","ms","mtext"]),Te=Ur({},["annotation-xml"]);const Ae=Ur({},["title","style","font","a","script"]);let ke=null;const we=["application/xhtml+xml","text/html"];let xe=null,Ne=null;const Ce=r.createElement("form"),Oe=function(e){return e instanceof RegExp||e instanceof Function},De=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!Ne||Ne!==e){if(e&&"object"==typeof e||(e={}),e=jr(e),ke=-1===we.indexOf(e.PARSER_MEDIA_TYPE)?"text/html":e.PARSER_MEDIA_TYPE,xe="application/xhtml+xml"===ke?wr:kr,j=Dr(e,"ALLOWED_TAGS")?Ur({},e.ALLOWED_TAGS,xe):F,z=Dr(e,"ALLOWED_ATTR")?Ur({},e.ALLOWED_ATTR,xe):H,be=Dr(e,"ALLOWED_NAMESPACES")?Ur({},e.ALLOWED_NAMESPACES,wr):Se,pe=Dr(e,"ADD_URI_SAFE_ATTR")?Ur(jr(de),e.ADD_URI_SAFE_ATTR,xe):de,fe=Dr(e,"ADD_DATA_URI_TAGS")?Ur(jr(_e),e.ADD_DATA_URI_TAGS,xe):_e,ce=Dr(e,"FORBID_CONTENTS")?Ur({},e.FORBID_CONTENTS,xe):se,B=Dr(e,"FORBID_TAGS")?Ur({},e.FORBID_TAGS,xe):jr({}),G=Dr(e,"FORBID_ATTR")?Ur({},e.FORBID_ATTR,xe):jr({}),le=!!Dr(e,"USE_PROFILES")&&e.USE_PROFILES,V=!1!==e.ALLOW_ARIA_ATTR,Y=!1!==e.ALLOW_DATA_ATTR,$=e.ALLOW_UNKNOWN_PROTOCOLS||!1,X=!1!==e.ALLOW_SELF_CLOSE_IN_ATTR,K=e.SAFE_FOR_TEMPLATES||!1,Z=!1!==e.SAFE_FOR_XML,J=e.WHOLE_DOCUMENT||!1,te=e.RETURN_DOM||!1,ne=e.RETURN_DOM_FRAGMENT||!1,re=e.RETURN_TRUSTED_TYPE||!1,ee=e.FORCE_BODY||!1,oe=!1!==e.SANITIZE_DOM,ie=e.SANITIZE_NAMED_PROPS||!1,ae=!1!==e.KEEP_CONTENT,ue=e.IN_PLACE||!1,P=e.ALLOWED_URI_REGEXP||no,ve=e.NAMESPACE||ye,Ee=e.MATHML_TEXT_INTEGRATION_POINTS||Ee,Te=e.HTML_INTEGRATION_POINTS||Te,W=e.CUSTOM_ELEMENT_HANDLING||{},e.CUSTOM_ELEMENT_HANDLING&&Oe(e.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(W.tagNameCheck=e.CUSTOM_ELEMENT_HANDLING.tagNameCheck),e.CUSTOM_ELEMENT_HANDLING&&Oe(e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(W.attributeNameCheck=e.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),e.CUSTOM_ELEMENT_HANDLING&&"boolean"==typeof e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements&&(W.allowCustomizedBuiltInElements=e.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),K&&(Y=!1),ne&&(te=!0),le&&(j=Ur({},Vr),z=[],!0===le.html&&(Ur(j,zr),Ur(z,Yr)),!0===le.svg&&(Ur(j,Hr),Ur(z,$r),Ur(z,Kr)),!0===le.svgFilters&&(Ur(j,Wr),Ur(z,$r),Ur(z,Kr)),!0===le.mathMl&&(Ur(j,Gr),Ur(z,Xr),Ur(z,Kr))),e.ADD_TAGS&&("function"==typeof e.ADD_TAGS?q.tagCheck=e.ADD_TAGS:(j===F&&(j=jr(j)),Ur(j,e.ADD_TAGS,xe))),e.ADD_ATTR&&("function"==typeof e.ADD_ATTR?q.attributeCheck=e.ADD_ATTR:(z===H&&(z=jr(z)),Ur(z,e.ADD_ATTR,xe))),e.ADD_URI_SAFE_ATTR&&Ur(pe,e.ADD_URI_SAFE_ATTR,xe),e.FORBID_CONTENTS&&(ce===se&&(ce=jr(ce)),Ur(ce,e.FORBID_CONTENTS,xe)),e.ADD_FORBID_CONTENTS&&(ce===se&&(ce=jr(ce)),Ur(ce,e.ADD_FORBID_CONTENTS,xe)),ae&&(j["#text"]=!0),J&&Ur(j,["html","head","body"]),j.table&&(Ur(j,["tbody"]),delete B.tbody),e.TRUSTED_TYPES_POLICY){if("function"!=typeof e.TRUSTED_TYPES_POLICY.createHTML)throw Lr('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!=typeof e.TRUSTED_TYPES_POLICY.createScriptURL)throw Lr('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');S=e.TRUSTED_TYPES_POLICY,E=S.createHTML("")}else void 0===S&&(S=function(e,t){if("object"!=typeof e||"function"!=typeof e.createPolicy)return null;let n=null;const r="data-tt-policy-suffix";t&&t.hasAttribute(r)&&(n=t.getAttribute(r));const o="dompurify"+(n?"#"+n:"");try{return e.createPolicy(o,{createHTML:e=>e,createScriptURL:e=>e})}catch(e){return console.warn("TrustedTypes policy "+o+" could not be created."),null}}(d,i)),null!==S&&"string"==typeof E&&(E=S.createHTML(""));mr&&mr(e),Ne=e}},Re=Ur({},[...Hr,...Wr,...Br]),Le=Ur({},[...Gr,...qr]),Ie=function(e){Tr(n.removed,{element:e});try{b(e).removeChild(e)}catch(t){y(e)}},Me=function(e,t){try{Tr(n.removed,{attribute:t.getAttributeNode(e),from:t})}catch(e){Tr(n.removed,{attribute:null,from:t})}if(t.removeAttribute(e),"is"===e)if(te||ne)try{Ie(t)}catch(e){}else try{t.setAttribute(e,"")}catch(e){}},Ue=function(e){let t=null,n=null;if(ee)e="<remove></remove>"+e;else{const t=xr(e,/^[\r\n\t ]+/);n=t&&t[0]}"application/xhtml+xml"===ke&&ve===ye&&(e='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+e+"</body></html>");const o=S?S.createHTML(e):e;if(ve===ye)try{t=(new p).parseFromString(o,ke)}catch(e){}if(!t||!t.documentElement){t=T.createDocument(ve,"template",null);try{t.documentElement.innerHTML=ge?E:o}catch(e){}}const i=t.body||t.documentElement;return e&&n&&i.insertBefore(r.createTextNode(n),i.childNodes[0]||null),ve===ye?w.call(t,J?"html":"body")[0]:J?t.documentElement:i},Pe=function(e){return A.call(e.ownerDocument||e,e,s.SHOW_ELEMENT|s.SHOW_COMMENT|s.SHOW_TEXT|s.SHOW_PROCESSING_INSTRUCTION|s.SHOW_CDATA_SECTION,null)},je=function(e){return e instanceof _&&("string"!=typeof e.nodeName||"string"!=typeof e.textContent||"function"!=typeof e.removeChild||!(e.attributes instanceof f)||"function"!=typeof e.removeAttribute||"function"!=typeof e.setAttribute||"string"!=typeof e.namespaceURI||"function"!=typeof e.insertBefore||"function"!=typeof e.hasChildNodes)},Fe=function(e){return"function"==typeof l&&e instanceof l};function ze(e,t,r){br(e,(e=>{e.call(n,t,r,Ne)}))}const He=function(e){let t=null;if(ze(N.beforeSanitizeElements,e,null),je(e))return Ie(e),!0;const r=xe(e.nodeName);if(ze(N.uponSanitizeElement,e,{tagName:r,allowedTags:j}),Z&&e.hasChildNodes()&&!Fe(e.firstElementChild)&&Rr(/<[/\w!]/g,e.innerHTML)&&Rr(/<[/\w!]/g,e.textContent))return Ie(e),!0;if(e.nodeType===so)return Ie(e),!0;if(Z&&e.nodeType===fo&&Rr(/<[/\w]/g,e.data))return Ie(e),!0;if(!(q.tagCheck instanceof Function&&q.tagCheck(r))&&(!j[r]||B[r])){if(!B[r]&&Be(r)){if(W.tagNameCheck instanceof RegExp&&Rr(W.tagNameCheck,r))return!1;if(W.tagNameCheck instanceof Function&&W.tagNameCheck(r))return!1}if(ae&&!ce[r]){const t=b(e)||e.parentNode,n=g(e)||e.childNodes;if(n&&t){for(let r=n.length-1;r>=0;--r){const o=h(n[r],!0);o.__removalCount=(e.__removalCount||0)+1,t.insertBefore(o,v(e))}}}return Ie(e),!0}return e instanceof c&&!function(e){let t=b(e);t&&t.tagName||(t={namespaceURI:ve,tagName:"template"});const n=kr(e.tagName),r=kr(t.tagName);return!!be[e.namespaceURI]&&(e.namespaceURI===he?t.namespaceURI===ye?"svg"===n:t.namespaceURI===me?"svg"===n&&("annotation-xml"===r||Ee[r]):Boolean(Re[n]):e.namespaceURI===me?t.namespaceURI===ye?"math"===n:t.namespaceURI===he?"math"===n&&Te[r]:Boolean(Le[n]):e.namespaceURI===ye?!(t.namespaceURI===he&&!Te[r])&&!(t.namespaceURI===me&&!Ee[r])&&!Le[n]&&(Ae[n]||!Re[n]):!("application/xhtml+xml"!==ke||!be[e.namespaceURI]))}(e)?(Ie(e),!0):"noscript"!==r&&"noembed"!==r&&"noframes"!==r||!Rr(/<\/no(script|embed|frames)/i,e.innerHTML)?(K&&e.nodeType===co&&(t=e.textContent,br([C,O,D],(e=>{t=Nr(t,e," ")})),e.textContent!==t&&(Tr(n.removed,{element:e.cloneNode()}),e.textContent=t)),ze(N.afterSanitizeElements,e,null),!1):(Ie(e),!0)},We=function(e,t,n){if(oe&&("id"===t||"name"===t)&&(n in r||n in Ce))return!1;if(Y&&!G[t]&&Rr(R,t));else if(V&&Rr(L,t));else if(q.attributeCheck instanceof Function&&q.attributeCheck(t,e));else if(!z[t]||G[t]){if(!(Be(e)&&(W.tagNameCheck instanceof RegExp&&Rr(W.tagNameCheck,e)||W.tagNameCheck instanceof Function&&W.tagNameCheck(e))&&(W.attributeNameCheck instanceof RegExp&&Rr(W.attributeNameCheck,t)||W.attributeNameCheck instanceof Function&&W.attributeNameCheck(t,e))||"is"===t&&W.allowCustomizedBuiltInElements&&(W.tagNameCheck instanceof RegExp&&Rr(W.tagNameCheck,n)||W.tagNameCheck instanceof Function&&W.tagNameCheck(n))))return!1}else if(pe[t]);else if(Rr(P,Nr(n,M,"")));else if("src"!==t&&"xlink:href"!==t&&"href"!==t||"script"===e||0!==Cr(n,"data:")||!fe[e]){if($&&!Rr(I,Nr(n,M,"")));else if(n)return!1}else;return!0},Be=function(e){return"annotation-xml"!==e&&xr(e,U)},Ge=function(e){ze(N.beforeSanitizeAttributes,e,null);const{attributes:t}=e;if(!t||je(e))return;const r={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:z,forceKeepAttr:void 0};let o=t.length;for(;o--;){const i=t[o],{name:a,namespaceURI:u,value:l}=i,c=xe(a),s=l;let f="value"===a?s:Or(s);if(r.attrName=c,r.attrValue=f,r.keepAttr=!0,r.forceKeepAttr=void 0,ze(N.uponSanitizeAttribute,e,r),f=r.attrValue,!ie||"id"!==c&&"name"!==c||(Me(a,e),f="user-content-"+f),Z&&Rr(/((--!?|])>)|<\/(style|title|textarea)/i,f)){Me(a,e);continue}if("attributename"===c&&xr(f,"href")){Me(a,e);continue}if(r.forceKeepAttr)continue;if(!r.keepAttr){Me(a,e);continue}if(!X&&Rr(/\/>/i,f)){Me(a,e);continue}K&&br([C,O,D],(e=>{f=Nr(f,e," ")}));const _=xe(e.nodeName);if(We(_,c,f)){if(S&&"object"==typeof d&&"function"==typeof d.getAttributeType)if(u);else switch(d.getAttributeType(_,c)){case"TrustedHTML":f=S.createHTML(f);break;case"TrustedScriptURL":f=S.createScriptURL(f)}if(f!==s)try{u?e.setAttributeNS(u,a,f):e.setAttribute(a,f),je(e)?Ie(e):Er(n.removed)}catch(t){Me(a,e)}}else Me(a,e)}ze(N.afterSanitizeAttributes,e,null)},qe=function e(t){let n=null;const r=Pe(t);for(ze(N.beforeSanitizeShadowDOM,t,null);n=r.nextNode();)ze(N.uponSanitizeShadowNode,n,null),He(n),Ge(n),n.content instanceof a&&e(n.content);ze(N.afterSanitizeShadowDOM,t,null)};return n.sanitize=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=null,i=null,u=null,c=null;if(ge=!e,ge&&(e="\x3c!--\x3e"),"string"!=typeof e&&!Fe(e)){if("function"!=typeof e.toString)throw Lr("toString is not a function");if("string"!=typeof(e=e.toString()))throw Lr("dirty is not a string, aborting")}if(!n.isSupported)return e;if(Q||De(t),n.removed=[],"string"==typeof e&&(ue=!1),ue){if(e.nodeName){const t=xe(e.nodeName);if(!j[t]||B[t])throw Lr("root node is forbidden and cannot be sanitized in-place")}}else if(e instanceof l)r=Ue("\x3c!----\x3e"),i=r.ownerDocument.importNode(e,!0),i.nodeType===lo&&"BODY"===i.nodeName||"HTML"===i.nodeName?r=i:r.appendChild(i);else{if(!te&&!K&&!J&&-1===e.indexOf("<"))return S&&re?S.createHTML(e):e;if(r=Ue(e),!r)return te?null:re?E:""}r&&ee&&Ie(r.firstChild);const s=Pe(ue?e:r);for(;u=s.nextNode();)He(u),Ge(u),u.content instanceof a&&qe(u.content);if(ue)return e;if(te){if(ne)for(c=k.call(r.ownerDocument);r.firstChild;)c.appendChild(r.firstChild);else c=r;return(z.shadowroot||z.shadowrootmode)&&(c=x.call(o,c,!0)),c}let f=J?r.outerHTML:r.innerHTML;return J&&j["!doctype"]&&r.ownerDocument&&r.ownerDocument.doctype&&r.ownerDocument.doctype.name&&Rr(io,r.ownerDocument.doctype.name)&&(f="<!DOCTYPE "+r.ownerDocument.doctype.name+">\n"+f),K&&br([C,O,D],(e=>{f=Nr(f,e," ")})),S&&re?S.createHTML(f):f},n.setConfig=function(){De(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}),Q=!0},n.clearConfig=function(){Ne=null,Q=!1},n.isValidAttribute=function(e,t,n){Ne||De({});const r=xe(e),o=xe(t);return We(r,o,n)},n.addHook=function(e,t){"function"==typeof t&&Tr(N[e],t)},n.removeHook=function(e,t){if(void 0!==t){const n=Sr(N[e],t);return-1===n?void 0:Ar(N[e],n,1)[0]}return Er(N[e])},n.removeHooks=function(e){N[e]=[]},n.removeAllHooks=function(){N={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},n}();const ho=()=>{const{banner:e,acceptAll:t,rejectAll:n,setModal:r}=lr();return $("div",{className:"fixed bottom-0 left-0 max-w-md px-5 py-4 m-2 shadow-md shadow-black/25 z-[9998] bg-background space-y-4 font-primary text-foreground rounded-md animate-slide-in-up banner-wrapper",children:[e.title&&$("h3",{className:"m-0 text-lg font-semibold font-primary md:text-xl banner-title",children:e.title}),e.description&&$("p",{className:"m-0 text-sm leading-snug font-primary md:text-base banner-description",dangerouslySetInnerHTML:{__html:mo.sanitize(e.description,{USE_PROFILES:{html:!0},ALLOWED_TAGS:["b","i","em","strong","p","ul","li","ol","span","h2","h3","h4","h5","h6","a","div"],ALLOWED_ATTR:["href","target"]})}}),$("div",{className:"pt-2 space-y-2 banner-btns",children:[!gt(e.settings)&&$("button",{type:"button",className:"px-2 mr-2 text-sm font-semibold border-2 border-solid rounded bg-background font-primary text-primary md:px-3.5 py-1.5 md:py-2.5 border-primary hover:border-primary-hover hover:text-primary-hover active:border-primary-active active:text-primary-active transition-colors banner-btn-customise",onClick:()=>r(!0),children:e.customise}),$("button",{type:"button",className:"px-2 mr-2 text-sm font-semibold border-2 border-solid rounded bg-background font-primary text-primary md:px-3.5 py-1.5 md:py-2.5 border-primary hover:border-primary-hover hover:text-primary-hover active:border-primary-active active:text-primary-active transition-colors banner-btn-reject",onClick:n,children:e.reject}),$("button",{type:"button",className:"px-2 mr-2 text-sm font-semibold border-2 border-solid rounded bg-primary font-primary text-background md:px-3.5 py-1.5 md:py-2.5 border-primary hover:bg-primary-hover hover:border-primary-hover active:bg-primary-active active:border-primary-active transition-colors banner-btn-accept",onClick:t,children:e.accept})]})]})},yo=()=>{const{cookie:e,setPermissions:t,banner:n,setModal:r}=lr(),[o,i]=ce(e);return $("div",{className:"fixed bottom-0 left-0 w-full max-w-lg max-h-full px-5 py-4 m-2 overflow-y-auto text-black shadow-md shadow-black/25 z-[9999] bg-background text-foreground font-primary rounded-md banner-wrapper",children:[$("div",{className:"space-y-6",children:[$("div",{children:[$("h3",{className:"w-10/12 m-0 text-xl font-semibold font-primary md:text-2xl banner-title",children:n.customise}),n.customiseDescription&&$("p",{className:"m-0 mt-2 text-sm leading-snug font-primary md:text-base banner-settings-general-description",dangerouslySetInnerHTML:{__html:mo.sanitize(n.customiseDescription,{USE_PROFILES:{html:!0},ALLOWED_TAGS:["b","i","em","strong","p","ul","li","ol","span","h2","h3","h4","h5","h6","a","div"],ALLOWED_ATTR:["href","target"]})}})]}),n.settings.map((({slug:e,title:t,description:n})=>$("div",{children:[$("div",{className:"flex items-start justify-between",children:[$("h3",{className:"m-0 text-lg font-semibold font-primary banner-settings-title",children:t}),$("button",{type:"button",className:(o[e]?"bg-primary":"bg-gray-200")+" relative inline-flex h-6 w-11 flex-shrink-0 cursor-pointer rounded-full border-2 border-transparent transition-colors duration-200 ease-in-out focus:outline-none focus:ring-2 focus:ring-primary focus:ring-offset-2 mt-0.5 banner-settings-toggle",role:"switch","aria-checked":"false",onClick:()=>i({...o,[e]:!o[e]}),children:[$("span",{className:"sr-only",children:"Toggle"}),$("span",{"aria-hidden":"true",className:(o[e]?"translate-x-5":"translate-x-0")+" pointer-events-none inline-block h-5 w-5 transform rounded-full bg-background shadow ring-0 transition duration-200 ease-in-out"})]})]}),$("p",{className:"m-0 mt-2 text-sm leading-snug font-primary md:text-base banner-settings-description",children:n})]},`setting-${e}`))),$("div",{className:"pt-4",children:$("button",{type:"button",className:"px-2 mr-2 text-sm font-semibold border-2 border-solid rounded bg-primary font-primary text-background md:px-3.5 py-1.5 md:py-2.5 border-primary hover:bg-primary-hover hover:border-primary-hover active:bg-primary-active active:border-primary-active transition-colors banner-settings-save",onClick:()=>{t(o),r(!1)},children:n.save})})]}),$("button",{type:"button",className:"absolute top-0 right-0 w-8 h-8 mt-0 text-xl rounded-full banner-settings-close",onClick:()=>r(!1),children:"×"})]})},vo=document.createElement("div");vo.id="lkrl-wrapper",document.body.appendChild(vo),B($((()=>{const{choiceMade:e,displayDelay:t,init:n,settingsOpen:r}=lr(),[o,i]=ce(t<=0);return fe((()=>{n()}),[]),fe((()=>{if(o||e||t<=0)return;const n=setTimeout((()=>i(!0)),t);return()=>clearTimeout(n)}),[e,o,t]),$(S,{children:[!e&&!r&&o&&$(ho,{}),r&&$(yo,{})]})}),{}),vo)}();
|
package/doc/gtm-tag-template.js
CHANGED
|
@@ -23,7 +23,7 @@ const DEFAULT_CONSENT_STATE = {
|
|
|
23
23
|
const ALLOWED_CONSENT_STATE = Object.keys(DEFAULT_CONSENT_STATE);
|
|
24
24
|
const CONSENT_UPDATE_CUSTOM_EVENT = 'leckerliConsentUpdate';
|
|
25
25
|
const COOKIE_NAME = 'gtm-leckerli';
|
|
26
|
-
const LECKERLI_JS_URL = 'https://www.unpkg.com/@antistatique/leckerli@1.
|
|
26
|
+
const LECKERLI_JS_URL = 'https://www.unpkg.com/@antistatique/leckerli@1.3/dist/assets/leckerli-gtm.min.js';
|
|
27
27
|
|
|
28
28
|
/**
|
|
29
29
|
* Used to merge an object in another.
|
package/index.html
CHANGED
|
@@ -10,6 +10,12 @@
|
|
|
10
10
|
<body style="background: #cbd5e1; display: grid; place-content: center; font-family: sans-serif; min-height: 100vh;">
|
|
11
11
|
<h1>Your website here 🤗</h1>
|
|
12
12
|
|
|
13
|
+
<script>
|
|
14
|
+
window.leckerliSettings = {
|
|
15
|
+
displayDelay: 1200,
|
|
16
|
+
};
|
|
17
|
+
</script>
|
|
18
|
+
|
|
13
19
|
<script defer type="module" src="/src/index.tsx"></script>
|
|
14
20
|
|
|
15
21
|
<script>
|
package/package.json
CHANGED
package/src/components/App.tsx
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { useEffect } from 'preact/hooks';
|
|
1
|
+
import { useEffect, useState } from 'preact/hooks';
|
|
2
2
|
|
|
3
3
|
import useSettings from '../hooks/useSettings';
|
|
4
4
|
|
|
@@ -6,15 +6,25 @@ import Banner from './Banner';
|
|
|
6
6
|
import Settings from './Settings';
|
|
7
7
|
|
|
8
8
|
const App = () => {
|
|
9
|
-
const { choiceMade, init, settingsOpen } = useSettings();
|
|
9
|
+
const { choiceMade, displayDelay, init, settingsOpen } = useSettings();
|
|
10
|
+
const [delayElapsed, setDelayElapsed] = useState(displayDelay <= 0);
|
|
10
11
|
|
|
11
12
|
useEffect(() => {
|
|
12
13
|
init();
|
|
13
14
|
}, []);
|
|
14
15
|
|
|
16
|
+
useEffect(() => {
|
|
17
|
+
if (delayElapsed || choiceMade || displayDelay <= 0) {
|
|
18
|
+
return undefined;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
const timer = setTimeout(() => setDelayElapsed(true), displayDelay);
|
|
22
|
+
return () => clearTimeout(timer);
|
|
23
|
+
}, [choiceMade, delayElapsed, displayDelay]);
|
|
24
|
+
|
|
15
25
|
return (
|
|
16
26
|
<>
|
|
17
|
-
{!choiceMade && !settingsOpen && <Banner />}
|
|
27
|
+
{!choiceMade && !settingsOpen && delayElapsed && <Banner />}
|
|
18
28
|
{settingsOpen && <Settings />}
|
|
19
29
|
</>
|
|
20
30
|
);
|
|
@@ -28,7 +28,7 @@ const Banner = () => {
|
|
|
28
28
|
const allowedAttributes = ['href', 'target'];
|
|
29
29
|
|
|
30
30
|
return (
|
|
31
|
-
<div className="fixed bottom-0 left-0 max-w-md px-5 py-4 m-2 shadow-md shadow-black/25 z-[9998] bg-background space-y-4 font-primary text-foreground rounded-md banner-wrapper">
|
|
31
|
+
<div className="fixed bottom-0 left-0 max-w-md px-5 py-4 m-2 shadow-md shadow-black/25 z-[9998] bg-background space-y-4 font-primary text-foreground rounded-md animate-slide-in-up banner-wrapper">
|
|
32
32
|
{banner.title && (
|
|
33
33
|
<h3 className="m-0 text-lg font-semibold font-primary md:text-xl banner-title">
|
|
34
34
|
{banner.title}
|
package/src/defaultSettings.ts
CHANGED
package/tailwind.config.js
CHANGED
|
@@ -19,7 +19,16 @@ export default {
|
|
|
19
19
|
},
|
|
20
20
|
fontFamily: {
|
|
21
21
|
primary: `var(--leckerli-font, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji")`
|
|
22
|
-
}
|
|
22
|
+
},
|
|
23
|
+
keyframes: {
|
|
24
|
+
'slide-in-up': {
|
|
25
|
+
'0%': { opacity: '0.4', transform: 'translateY(2rem)' },
|
|
26
|
+
'100%': { opacity: '1', transform: 'translateY(0)' },
|
|
27
|
+
},
|
|
28
|
+
},
|
|
29
|
+
animation: {
|
|
30
|
+
'slide-in-up': 'slide-in-up 0.4s ease-out',
|
|
31
|
+
},
|
|
23
32
|
},
|
|
24
33
|
},
|
|
25
34
|
plugins: [],
|