diff --git a/Makefile b/Makefile index a4c5eff..cb361ee 100755 --- a/Makefile +++ b/Makefile @@ -10,9 +10,11 @@ clean: rm -rfd ./$(BUILD_DIR) build: + node scripts/generate-llms.mjs zola build serve: + node scripts/generate-llms.mjs zola serve update-zola: diff --git a/build.sh b/build.sh index 17aa776..6a378d6 100755 --- a/build.sh +++ b/build.sh @@ -10,7 +10,8 @@ echo "Extracting Zola..." tar -xf zola-v${ZOLA_VERSION}-x86_64-unknown-linux-gnu.tar.gz echo "Building site with Zola..." +node scripts/generate-llms.mjs ./zola build echo "Build complete! Generated files:" -ls -la public/ \ No newline at end of file +ls -la public/ diff --git a/package.json b/package.json index beeda24..3ed9008 100644 --- a/package.json +++ b/package.json @@ -5,6 +5,8 @@ "wrangler": "^4" }, "scripts": { - "deploy": "zola build && wrangler deploy" + "generate:llms": "node scripts/generate-llms.mjs", + "build": "npm run generate:llms && zola build", + "deploy": "npm run build && wrangler deploy" } } diff --git a/scripts/generate-llms.mjs b/scripts/generate-llms.mjs new file mode 100644 index 0000000..5bcf96f --- /dev/null +++ b/scripts/generate-llms.mjs @@ -0,0 +1,85 @@ +import fs from 'node:fs'; +import path from 'node:path'; + +const root = process.cwd(); +const config = fs.readFileSync(path.join(root, 'zola.toml'), 'utf8'); +const postsDir = path.join(root, 'content', 'posts'); +const output = path.join(root, 'static', 'llms.txt'); + +function tomlString(source, key) { + const match = source.match(new RegExp(`^${key}\\s*=\\s*("(?:[^"\\\\]|\\\\.)*")`, 'm')); + return match ? JSON.parse(match[1]) : undefined; +} + +function frontMatter(source) { + return source.match(/^\+\+\+\s*\n([\s\S]*?)\n\+\+\+/)?.[1]; +} + +function markdownFiles(directory) { + return fs.readdirSync(directory, { withFileTypes: true }).flatMap((entry) => { + const location = path.join(directory, entry.name); + if (entry.isDirectory()) return markdownFiles(location); + return entry.isFile() && entry.name.endsWith('.md') ? [location] : []; + }); +} + +function postUrl(file, metadata, baseUrl) { + const relative = path.relative(postsDir, file).replaceAll(path.sep, '/'); + const defaultSlug = relative.endsWith('/index.md') + ? relative.slice(0, -'/index.md'.length) + : relative.slice(0, -'.md'.length); + const slug = tomlString(metadata, 'slug') ?? defaultSlug; + return `${baseUrl}/posts/${slug}/`; +} + +const baseUrl = tomlString(config, 'base_url')?.replace(/\/$/, ''); +const siteTitle = new URL(baseUrl).hostname; +const summary = tomlString(config, 'llms_description') ?? tomlString(config, 'description'); + +const posts = markdownFiles(postsDir) + .filter((file) => path.basename(file) !== '_index.md') + .map((file) => { + const metadata = frontMatter(fs.readFileSync(file, 'utf8')); + if (!metadata || /^draft\s*=\s*true$/m.test(metadata)) return null; + + const title = tomlString(metadata, 'title'); + const description = tomlString(metadata, 'description'); + const date = metadata.match(/^date\s*=\s*(\d{4}-\d{2}-\d{2})/m)?.[1]; + if (!title || !date) return null; + + return { title, description, date, url: postUrl(file, metadata, baseUrl) }; + }) + .filter(Boolean) + .sort((a, b) => b.date.localeCompare(a.date)); + +const lines = [ + `# ${siteTitle}`, + '', + `> ${summary}`, + '', + 'This site contains articles in English, often with commands, code samples, worked explanations, and material aimed at readers learning by doing.', + '', + '## Main pages', + '', + `- [Home](${baseUrl}/): Introduction and latest articles.`, + `- [About](${baseUrl}/about/): About the author and contact information.`, + `- [Posts](${baseUrl}/posts/): All published articles.`, + `- [Tags](${baseUrl}/tags/): Articles grouped by topic.`, + `- [Archive](${baseUrl}/archive/): Chronological article archive.`, + '', + '## Published articles', + '', + ...posts.map(({ title, description, url }) => + `- [${title}](${url})${description ? `: ${description.replace(/\s+/g, ' ').trim()}` : ''}`, + ), + '', + '## Feeds and discovery', + '', + `- [RSS feed](${baseUrl}/rss.xml): Full site feed in RSS format.`, + `- [JSON feed](${baseUrl}/feed.json): Full site feed in JSON format.`, + `- [Sitemap](${baseUrl}/sitemap.xml): Machine-readable index of public pages.`, + '', +]; + +fs.writeFileSync(output, lines.join('\n')); +console.log(`Generated ${path.relative(root, output)} with ${posts.length} published articles.`); diff --git a/static/css/cookieconsent.css b/static/css/cookieconsent.css deleted file mode 100644 index 13a9625..0000000 --- a/static/css/cookieconsent.css +++ /dev/null @@ -1,1452 +0,0 @@ -#cc-main { - background: transparent; - color: var(--cc-primary-color); - font-family: var(--cc-font-family); - font-size: 16px; - font-weight: 400; - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; - line-height: 1.15; - position: relative; - text-rendering: optimizeLegibility; - -webkit-text-size-adjust: 100%; - position: fixed; - z-index: var(--cc-z-index); -} -#cc-main :after, -#cc-main :before, -#cc-main a, -#cc-main button, -#cc-main div, -#cc-main h2, -#cc-main input, -#cc-main p, -#cc-main span { - all: unset; - box-sizing: border-box; -} -#cc-main .pm__badge, -#cc-main button { - all: initial; - box-sizing: border-box; - color: unset; - visibility: unset; -} -#cc-main .pm__badge, -#cc-main a, -#cc-main button, -#cc-main input { - -webkit-appearance: none; - appearance: none; - cursor: pointer; - font-family: inherit; - font-size: 100%; - line-height: normal; - margin: 0; - outline: revert; - outline-offset: 2px; - overflow: hidden; -} -#cc-main table, -#cc-main tbody, -#cc-main td, -#cc-main th, -#cc-main thead, -#cc-main tr { - all: revert; - color: inherit; - font-family: inherit; - font-size: inherit; - font-weight: inherit; -} -:root { - --cc-font-family: - -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif, - 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'; - --cc-modal-border-radius: 0.5rem; - --cc-btn-border-radius: 0.4rem; - --cc-modal-transition-duration: 0.25s; - --cc-link-color: var(--cc-btn-primary-bg); - --cc-modal-margin: 1rem; - --cc-z-index: 2147483647; - --cc-bg: #fff; - --cc-primary-color: #2c2f31; - --cc-secondary-color: #5e6266; - --cc-btn-primary-bg: #30363c; - --cc-btn-primary-color: #fff; - --cc-btn-primary-border-color: var(--cc-btn-primary-bg); - --cc-btn-primary-hover-bg: #000; - --cc-btn-primary-hover-color: #fff; - --cc-btn-primary-hover-border-color: var(--cc-btn-primary-hover-bg); - --cc-btn-secondary-bg: #eaeff2; - --cc-btn-secondary-color: var(--cc-primary-color); - --cc-btn-secondary-border-color: var(--cc-btn-secondary-bg); - --cc-btn-secondary-hover-bg: #d4dae0; - --cc-btn-secondary-hover-color: #000; - --cc-btn-secondary-hover-border-color: #d4dae0; - --cc-separator-border-color: #f0f4f7; - --cc-toggle-on-bg: var(--cc-btn-primary-bg); - --cc-toggle-off-bg: #667481; - --cc-toggle-on-knob-bg: #fff; - --cc-toggle-off-knob-bg: var(--cc-toggle-on-knob-bg); - --cc-toggle-enabled-icon-color: var(--cc-bg); - --cc-toggle-disabled-icon-color: var(--cc-bg); - --cc-toggle-readonly-bg: #d5dee2; - --cc-toggle-readonly-knob-bg: #fff; - --cc-toggle-readonly-knob-icon-color: var(--cc-toggle-readonly-bg); - --cc-section-category-border: var(--cc-cookie-category-block-bg); - --cc-cookie-category-block-bg: #f0f4f7; - --cc-cookie-category-block-border: #f0f4f7; - --cc-cookie-category-block-hover-bg: #e9eff4; - --cc-cookie-category-block-hover-border: #e9eff4; - --cc-cookie-category-expanded-block-bg: transparent; - --cc-cookie-category-expanded-block-hover-bg: #dee4e9; - --cc-overlay-bg: rgba(0, 0, 0, 0.65); - --cc-webkit-scrollbar-bg: var(--cc-section-category-border); - --cc-webkit-scrollbar-hover-bg: var(--cc-btn-primary-hover-bg); - --cc-footer-bg: var(--cc-btn-secondary-bg); - --cc-footer-color: var(--cc-secondary-color); - --cc-footer-border-color: #e4eaed; - --cc-pm-toggle-border-radius: 4em; -} -#cc-main.cc--rtl { - direction: rtl; -} -#cc-main .cm__title, -#cc-main a, -#cc-main b, -#cc-main em, -#cc-main strong { - font-weight: 600; -} -#cc-main button > span { - pointer-events: none; -} -#cc-main .cc__link, -#cc-main a { - background-image: linear-gradient(currentColor, currentColor); - background-position: 0 100%; - background-repeat: no-repeat; - background-size: 0 1px; - font-weight: 600; - position: relative; - transition: - background-size 0.25s, - color 0.25s ease; -} -#cc-main .cc__link:hover, -#cc-main a:hover { - background-size: 100% 1px; - color: var(--cc-primary-color); -} -#cc-main .cc__link { - color: var(--cc-link-color); -} -#cc-main .cm__desc, -#cc-main .pm__body { - overscroll-behavior: auto contain; - scrollbar-width: thin; -} -@media screen and (min-width: 640px) { - #cc-main ::-webkit-scrollbar, - #cc-main ::-webkit-scrollbar-thumb, - #cc-main ::-webkit-scrollbar-track { - all: revert; - } - #cc-main ::-webkit-scrollbar-thumb { - -webkit-background-clip: padding-box; - background-clip: padding-box; - background: var(--cc-toggle-readonly-bg); - border: 0.25rem solid var(--cc-bg); - border-radius: 1rem; - } - #cc-main ::-webkit-scrollbar-thumb:hover { - background: var(--cc-toggle-off-bg); - } - #cc-main ::-webkit-scrollbar { - background: transparent; - width: 12px; - } -} -html.disable--interaction.show--consent, -html.disable--interaction.show--consent body { - height: auto !important; - overflow: hidden !important; -} -@media (prefers-reduced-motion) { - #cc-main { - --cc-modal-transition-duration: 0s; - } -} -.cc--darkmode { - --cc-bg: #161a1c; - --cc-primary-color: #ebf3f6; - --cc-secondary-color: #aebbc5; - --cc-btn-primary-bg: #c2d0e0; - --cc-btn-primary-color: var(--cc-bg); - --cc-btn-primary-border-color: var(--cc-btn-primary-bg); - --cc-btn-primary-hover-bg: #98a7b6; - --cc-btn-primary-hover-color: #000; - --cc-btn-primary-hover-border-color: var(--cc-btn-primary-hover-bg); - --cc-btn-secondary-bg: #242c31; - --cc-btn-secondary-color: var(--cc-primary-color); - --cc-btn-secondary-border-color: var(--cc-btn-secondary-bg); - --cc-btn-secondary-hover-bg: #353d43; - --cc-btn-secondary-hover-color: #fff; - --cc-btn-secondary-hover-border-color: var(--cc-btn-secondary-hover-bg); - --cc-separator-border-color: #222a30; - --cc-toggle-on-bg: var(--cc-btn-primary-bg); - --cc-toggle-off-bg: #525f6b; - --cc-toggle-on-knob-bg: var(--cc-btn-primary-color); - --cc-toggle-off-knob-bg: var(--cc-btn-primary-color); - --cc-toggle-enabled-icon-color: var(--cc-btn-primary-color); - --cc-toggle-disabled-icon-color: var(--cc-btn-primary-color); - --cc-toggle-readonly-bg: #343e45; - --cc-toggle-readonly-knob-bg: #5f6b72; - --cc-toggle-readonly-knob-icon-color: var(--cc-toggle-readonly-bg); - --cc-section-category-border: #1e2428; - --cc-cookie-category-block-bg: #1e2428; - --cc-cookie-category-block-border: var(--cc-section-category-border); - --cc-cookie-category-block-hover-bg: #242c31; - --cc-cookie-category-block-hover-border: #232a2f; - --cc-cookie-category-expanded-block-bg: transparent; - --cc-cookie-category-expanded-block-hover-bg: var(--cc-toggle-readonly-bg); - --cc-overlay-bg: rgba(0, 0, 0, 0.65); - --cc-webkit-scrollbar-bg: var(--cc-section-category-border); - --cc-webkit-scrollbar-hover-bg: var(--cc-btn-primary-hover-bg); - --cc-footer-bg: #0c0e0f; - --cc-footer-color: var(--cc-secondary-color); - --cc-footer-border-color: #060809; -} -.cc--darkmode #cc-main { - color-scheme: dark; -} -#cc-main .cm { - background: var(--cc-bg); - border-radius: var(--cc-modal-border-radius); - box-shadow: 0 0.625em 1.875em rgba(0, 0, 2, 0.3); - display: flex; - flex-direction: column; - max-width: 24rem; - opacity: 0; - overflow: hidden; - position: fixed; - transform: translateY(1.6em); - visibility: hidden; - z-index: 1; -} -#cc-main .cm--top { - top: var(--cc-modal-margin); -} -#cc-main .cm--middle { - top: 50%; - transform: translateY(calc(-50% + 1.6em)); -} -#cc-main .cm--bottom { - bottom: var(--cc-modal-margin); -} -#cc-main .cm--center { - left: var(--cc-modal-margin); - margin: 0 auto; - right: var(--cc-modal-margin); - width: unset; -} -#cc-main .cm--left { - left: var(--cc-modal-margin); - margin-right: var(--cc-modal-margin); -} -#cc-main .cm--right { - margin-left: var(--cc-modal-margin); - right: var(--cc-modal-margin); -} -#cc-main .cm__body { - display: flex; - flex-direction: column; - justify-content: space-between; - position: relative; -} -#cc-main .cm__btns, -#cc-main .cm__links { - padding: 1rem 1.3rem; - width: unset; -} -#cc-main .cm__texts { - display: flex; - flex: 1; - flex-direction: column; - justify-content: center; - padding: 1rem 0 0; -} -#cc-main .cm__desc, -#cc-main .cm__title { - padding: 0 1.3rem; -} -#cc-main .cm__title { - font-size: 1.05em; -} -#cc-main .cm__title + .cm__desc { - margin-top: 1.1em; -} -#cc-main .cm__desc { - color: var(--cc-secondary-color); - font-size: 0.9em; - line-height: 1.5; - max-height: 40vh; - overflow-x: visible; - overflow-y: auto; - padding-bottom: 1em; -} -#cc-main .cm__btns { - border-top: 1px solid var(--cc-separator-border-color); - display: flex; - flex-direction: column; - justify-content: center; -} -#cc-main .cm__btn-group { - display: grid; - grid-auto-columns: minmax(0, 1fr); -} -#cc-main .cm__btn + .cm__btn, -#cc-main .cm__btn-group + .cm__btn-group { - margin-top: 0.375rem; -} -#cc-main .cm--flip .cm__btn + .cm__btn, -#cc-main .cm--flip .cm__btn-group + .cm__btn-group { - margin-bottom: 0.375rem; - margin-top: 0; -} -#cc-main .cm--inline .cm__btn + .cm__btn { - margin-left: 0.375rem; - margin-top: 0; -} -#cc-main .cm--inline.cm--flip .cm__btn + .cm__btn { - margin-bottom: 0; - margin-left: 0; - margin-right: 0.375rem; -} -#cc-main .cm--inline.cm--flip .cm__btn-group + .cm__btn-group { - margin-bottom: 0.375rem; - margin-right: 0; -} -#cc-main .cm--wide .cm__btn + .cm__btn, -#cc-main .cm--wide .cm__btn-group + .cm__btn-group { - margin-left: 0.375rem; - margin-top: 0; -} -#cc-main .cm--wide.cm--flip .cm__btn + .cm__btn, -#cc-main .cm--wide.cm--flip .cm__btn-group + .cm__btn-group { - margin-bottom: 0; - margin-right: 0.375rem; -} -#cc-main .cm--bar:not(.cm--inline) .cm__btn-group--uneven, -#cc-main .cm--wide .cm__btn-group--uneven { - display: flex; - flex: 1; - justify-content: space-between; -} -#cc-main .cm--bar:not(.cm--inline).cm--flip .cm__btn-group--uneven, -#cc-main .cm--wide.cm--flip .cm__btn-group--uneven { - flex-direction: row-reverse; -} -#cc-main .cm__btn { - background: var(--cc-btn-primary-bg); - border: 1px solid var(--cc-btn-primary-border-color); - border-radius: var(--cc-btn-border-radius); - color: var(--cc-btn-primary-color); - font-size: 0.82em; - font-weight: 600; - min-height: 42px; - padding: 0.5em 1em; - text-align: center; -} -#cc-main .cm__btn:hover { - background: var(--cc-btn-primary-hover-bg); - border-color: var(--cc-btn-primary-hover-border-color); - color: var(--cc-btn-primary-hover-color); -} -#cc-main .cm__btn--secondary { - background: var(--cc-btn-secondary-bg); - border-color: var(--cc-btn-secondary-border-color); - color: var(--cc-btn-secondary-color); -} -#cc-main .cm__btn--secondary:hover { - background: var(--cc-btn-secondary-hover-bg); - border-color: var(--cc-btn-secondary-hover-border-color); - color: var(--cc-btn-secondary-hover-color); -} -#cc-main .cm__btn--close { - border-radius: 0; - border-bottom-left-radius: var(--cc-btn-border-radius); - border-right: none; - border-top: none; - display: none; - font-size: 1em; - height: 42px; - min-width: auto !important; - overflow: hidden; - padding: 0 !important; - position: absolute; - right: 0; - top: 0; - width: 42px; -} -#cc-main .cm__btn--close svg { - stroke: var(--cc-btn-primary-color); - transform: scale(0.5); - transition: stroke 0.15s ease; -} -#cc-main .cm__btn--close:hover svg { - stroke: var(--cc-btn-primary-hover-color); -} -#cc-main .cm__btn--close.cm__btn--secondary svg { - stroke: var(--cc-btn-secondary-color); -} -#cc-main .cm__btn--close.cm__btn--secondary:hover svg { - stroke: var(--cc-btn-secondary-hover-color); -} -#cc-main .cm__btn--close + .cm__texts .cm__title { - padding-right: 3rem; -} -#cc-main .cm--inline .cm__btn-group { - grid-auto-flow: column; -} -#cc-main .cm__footer { - background: var(--cc-footer-bg); - border-top: 1px solid var(--cc-footer-border-color); - color: var(--cc-footer-color); - padding: 0.4em 0 0.5em; -} -#cc-main .cm__links { - display: flex; - flex-direction: row; - padding-bottom: 0; - padding-top: 0; -} -#cc-main .cm__link-group { - display: flex; - flex-direction: row; - font-size: 0.8em; - width: 100%; -} -#cc-main .cm__link-group > * + * { - margin-left: 1.3rem; -} -#cc-main .cm--flip .cm__btn:last-child { - grid-row: 1; -} -#cc-main .cm--inline.cm--flip .cm__btn:last-child { - grid-column: 1; -} -#cc-main .cm--box .cm__btn--close { - display: block; -} -#cc-main .cm--box.cm--flip .cm__btns { - flex-direction: column-reverse; -} -#cc-main .cm--box.cm--wide { - max-width: 36em; -} -#cc-main .cm--box.cm--wide .cm__btns { - flex-direction: row; - justify-content: space-between; -} -#cc-main .cm--box.cm--wide .cm__btn-group { - grid-auto-flow: column; -} -#cc-main .cm--box.cm--wide .cm__btn { - min-width: 120px; - padding-left: 1.8em; - padding-right: 1.8em; -} -#cc-main .cm--box.cm--wide.cm--flip .cm__btns { - flex-direction: row-reverse; -} -#cc-main .cm--box.cm--wide.cm--flip .cm__btn:last-child { - grid-column: 1; -} -#cc-main .cm--cloud { - max-width: 54em; - width: unset; -} -#cc-main .cm--cloud .cm__body { - flex-direction: row; -} -#cc-main .cm--cloud .cm__texts { - flex: 1; -} -#cc-main .cm--cloud .cm__desc { - max-height: 9.4em; -} -#cc-main .cm--cloud .cm__btns { - border-left: 1px solid var(--cc-separator-border-color); - border-top: none; - max-width: 23em; -} -#cc-main .cm--cloud .cm__btn-group { - flex-direction: column; -} -#cc-main .cm--cloud .cm__btn { - min-width: 19em; -} -#cc-main .cm--cloud.cm--flip .cm__btn-group, -#cc-main .cm--cloud.cm--flip .cm__btns { - flex-direction: column-reverse; -} -#cc-main .cm--cloud.cm--inline .cm__btn-group { - flex-direction: row; -} -#cc-main .cm--cloud.cm--inline .cm__btn { - min-width: 10em; -} -#cc-main .cm--cloud.cm--inline.cm--flip .cm__btn-group { - flex-direction: row-reverse; -} -#cc-main .cm--bar { - border-radius: 0; - left: 0; - margin: 0; - max-width: unset; - opacity: 1; - right: 0; - transform: translateY(0); - width: 100vw; - --cc-modal-transition-duration: 0.35s; -} -#cc-main .cm--bar.cm--top { - top: 0; - transform: translateY(-100%); -} -#cc-main .cm--bar.cm--bottom { - bottom: 0; - transform: translateY(100%); -} -#cc-main .cm--bar .cm__body, -#cc-main .cm--bar .cm__links { - margin: 0 auto; - max-width: 55em; - width: 100%; -} -#cc-main .cm--bar .cm__body { - padding: 0.5em 0 0.9em; -} -#cc-main .cm--bar .cm__btns { - border-top: none; - flex-direction: row; - justify-content: space-between; -} -#cc-main .cm--bar .cm__btn-group { - grid-auto-flow: column; -} -#cc-main .cm--bar:not(.cm--inline) .cm__btn + .cm__btn, -#cc-main .cm--bar:not(.cm--inline) .cm__btn-group + .cm__btn-group { - margin-left: 0.375rem; - margin-top: 0; -} -#cc-main .cm--bar .cm__btn { - min-width: 120px; - padding-left: 2em; - padding-right: 2em; -} -#cc-main .cm--bar.cm--flip:not(.cm--inline) .cm__btn + .cm__btn, -#cc-main .cm--bar.cm--flip:not(.cm--inline) .cm__btn-group + .cm__btn-group { - margin-bottom: 0; - margin-left: 0; - margin-right: 0.375rem; -} -#cc-main .cm--bar.cm--flip .cm__btns { - flex-direction: row-reverse; -} -#cc-main .cm--bar.cm--flip .cm__btn:last-child { - grid-column: 1; -} -#cc-main .cm--bar.cm--inline .cm__body, -#cc-main .cm--bar.cm--inline .cm__links { - max-width: 74em; -} -#cc-main .cm--bar.cm--inline .cm__body { - flex-direction: row; - padding: 0; -} -#cc-main .cm--bar.cm--inline .cm__btns { - flex-direction: column; - justify-content: center; - max-width: 23em; -} -#cc-main .cm--bar.cm--inline.cm--flip .cm__btns { - flex-direction: column-reverse; -} -#cc-main .cc--anim .cm, -#cc-main .cc--anim.cm-wrapper:before { - transition: - opacity var(--cc-modal-transition-duration) ease, - visibility var(--cc-modal-transition-duration) ease, - transform var(--cc-modal-transition-duration) ease; -} -#cc-main .cc--anim .cm__btn, -#cc-main .cc--anim .cm__close { - transition: - background-color 0.15s ease, - border-color 0.15s ease, - color 0.15s ease; -} -.disable--interaction #cc-main .cm-wrapper:before { - background: var(--cc-overlay-bg); - bottom: 0; - content: ''; - left: 0; - opacity: 0; - position: fixed; - right: 0; - top: 0; - visibility: hidden; - z-index: 0; -} -.show--consent #cc-main .cc--anim .cm { - opacity: 1; - transform: translateY(0); - visibility: visible !important; -} -.show--consent #cc-main .cc--anim .cm--middle { - transform: translateY(-50%); -} -.show--consent #cc-main .cc--anim .cm--bar { - transform: translateY(0); -} -.show--consent #cc-main .cc--anim.cm-wrapper:before { - opacity: 1; - visibility: visible; -} -#cc-main.cc--rtl .cm__btn--close { - border-bottom-left-radius: unset; - border-bottom-right-radius: var(--cc-btn-border-radius); - left: 0; - right: unset; -} -#cc-main.cc--rtl .cm__btn--close + .cm__texts .cm__title { - padding-left: 3rem !important; - padding-right: 1.3rem; -} -#cc-main.cc--rtl .cm--inline .cm__btn + .cm__btn { - margin-left: 0; - margin-right: 0.375rem; -} -#cc-main.cc--rtl .cm--inline.cm--flip .cm__btn + .cm__btn { - margin-left: 0.375rem; - margin-right: 0; -} -#cc-main.cc--rtl .cm:not(.cm--inline).cm--bar .cm__btn + .cm__btn, -#cc-main.cc--rtl .cm:not(.cm--inline).cm--bar .cm__btn-group + .cm__btn-group, -#cc-main.cc--rtl .cm:not(.cm--inline).cm--wide .cm__btn + .cm__btn, -#cc-main.cc--rtl .cm:not(.cm--inline).cm--wide .cm__btn-group + .cm__btn-group { - margin-left: 0; - margin-right: 0.375rem; -} -#cc-main.cc--rtl .cm:not(.cm--inline).cm--bar.cm--flip .cm__btn + .cm__btn, -#cc-main.cc--rtl .cm:not(.cm--inline).cm--wide.cm--flip .cm__btn + .cm__btn { - margin-left: 0.375rem; - margin-right: 0; -} -#cc-main.cc--rtl .cm__link-group > * + * { - margin-left: 0; - margin-right: 1.3rem; -} -@media screen and (max-width: 640px) { - #cc-main { - --cc-modal-margin: 0.5em; - } - #cc-main .cm { - max-width: none !important; - width: auto !important; - } - #cc-main .cm__body { - flex-direction: column !important; - padding: 0 !important; - } - #cc-main .cm__btns, - #cc-main .cm__desc, - #cc-main .cm__links, - #cc-main .cm__title { - padding-left: 1.1rem !important; - padding-right: 1.1rem !important; - } - #cc-main .cm__btns { - border-left: none !important; - border-top: 1px solid var(--cc-separator-border-color) !important; - flex-direction: column !important; - max-width: none !important; - min-width: auto !important; - } - #cc-main .cm__btn + .cm__btn, - #cc-main .cm__btn-group + .cm__btn-group { - margin: 0.375rem 0 0 !important; - } - #cc-main .cm--flip .cm__btn + .cm__btn, - #cc-main .cm--flip .cm__btn-group + .cm__btn-group { - margin-bottom: 0.375rem !important; - margin-top: 0 !important; - } - #cc-main .cm__btn-group { - display: flex !important; - flex-direction: column !important; - min-width: auto !important; - } - #cc-main .cm__btn { - flex: auto !important; - } - #cc-main .cm__link-group { - justify-content: center !important; - } - #cc-main .cm--flip .cm__btn-group, - #cc-main .cm--flip .cm__btns { - flex-direction: column-reverse !important; - } -} -#cc-main .pm-wrapper { - position: relative; - z-index: 2; -} -#cc-main .pm { - background: var(--cc-bg); - border-radius: var(--cc-modal-border-radius); - box-shadow: 0 0.625em 1.875em rgba(0, 0, 2, 0.3); - display: flex; - flex-direction: column; - opacity: 0; - overflow: hidden; - position: fixed; - visibility: hidden; - width: 100%; - width: unset; - z-index: 1; -} -#cc-main svg { - fill: none; - width: 100%; -} -#cc-main .pm__body, -#cc-main .pm__footer, -#cc-main .pm__header { - padding: 1em 1.4em; -} -#cc-main .pm__header { - align-items: center; - border-bottom: 1px solid var(--cc-separator-border-color); - display: flex; - justify-content: space-between; -} -#cc-main .pm__title { - align-items: center; - display: flex; - flex: 1; - font-weight: 600; - margin-right: 2em; -} -#cc-main .pm__close-btn { - background: var(--cc-btn-secondary-bg); - border: 1px solid var(--cc-btn-secondary-border-color); - border-radius: var(--cc-btn-border-radius); - height: 40px; - position: relative; - transition: all 0.15s ease; - width: 40px; -} -#cc-main .pm__close-btn span { - display: flex; - height: 100%; - width: 100%; -} -#cc-main .pm__close-btn svg { - stroke: var(--cc-btn-secondary-color); - transform: scale(0.5); - transition: stroke 0.15s ease; -} -#cc-main .pm__close-btn:hover { - background: var(--cc-btn-secondary-hover-bg); - border-color: var(--cc-btn-secondary-hover-border-color); -} -#cc-main .pm__close-btn:hover svg { - stroke: var(--cc-btn-secondary-hover-color); -} -#cc-main .pm__body { - flex: 1; - overflow-y: auto; - overflow-y: overlay; -} -#cc-main .pm__section, -#cc-main .pm__section--toggle { - border-radius: var(--cc-btn-border-radius); - display: flex; - flex-direction: column; - margin-bottom: 0.5em; -} -#cc-main .pm__section--toggle .pm__section-desc-wrapper { - border: 1px solid var(--cc-cookie-category-block-border); - border-radius: var(--cc-btn-border-radius); - border-top: none; - border-top-left-radius: 0; - border-top-right-radius: 0; - display: none; - margin-top: 0 !important; - overflow: hidden; -} -#cc-main .pm__section { - border: 1px solid var(--cc-separator-border-color); - padding: 1em; - transition: - background-color 0.25s ease, - border-color 0.25s ease; -} -#cc-main .pm__section:first-child { - border: none; - margin-bottom: 2em; - margin-top: 0; - padding: 0; - transition: none; -} -#cc-main .pm__section:not(:first-child):hover { - background: var(--cc-cookie-category-block-bg); - border-color: var(--cc-cookie-category-block-border); -} -#cc-main .pm__section-toggles + .pm__section { - margin-top: 2em; -} -#cc-main .pm__section--toggle { - background: var(--cc-cookie-category-block-bg); - border-top: none; - margin-bottom: 0.375rem; -} -#cc-main .pm__section--toggle .pm__section-title { - align-items: center; - background: var(--cc-cookie-category-block-bg); - border: 1px solid var(--cc-cookie-category-block-border); - display: flex; - justify-content: space-between; - min-height: 58px; - padding: 1.1em 5.4em 1.1em 1.2em; - position: relative; - transition: - background-color 0.25s ease, - border-color 0.25s ease; - width: 100%; -} -#cc-main .pm__section--toggle .pm__section-title:hover { - background: var(--cc-cookie-category-block-hover-bg); - border-color: var(--cc-cookie-category-block-hover-border); -} -#cc-main .pm__section--toggle .pm__section-desc { - margin-top: 0; - padding: 1em; -} -#cc-main .pm__section--toggle.is-expanded { - --cc-cookie-category-block-bg: var(--cc-cookie-category-expanded-block-bg); - --cc-cookie-category-block-border: var(--cc-cookie-category-expanded-block-hover-bg); -} -#cc-main .pm__section--toggle.is-expanded .pm__section-title { - border-bottom-left-radius: 0; - border-bottom-right-radius: 0; -} -#cc-main .pm__section--toggle.is-expanded .pm__section-arrow svg { - transform: scale(0.5) rotate(180deg); -} -#cc-main .pm__section--toggle.is-expanded .pm__section-desc-wrapper { - display: flex; -} -#cc-main .pm__section--expandable .pm__section-title { - cursor: pointer; - padding-left: 3.4em; -} -#cc-main .pm__section--expandable .pm__section-arrow { - background: var(--cc-toggle-readonly-bg); - border-radius: 100%; - display: flex; - height: 20px; - justify-content: center; - left: 18px; - pointer-events: none; - position: absolute; - width: 20px; -} -#cc-main .pm__section--expandable .pm__section-arrow svg { - stroke: var(--cc-btn-secondary-color); - transform: scale(0.5); -} -#cc-main .pm__section-title-wrapper { - align-items: center; - display: flex; - position: relative; -} -#cc-main .pm__section-title-wrapper + .pm__section-desc-wrapper { - margin-top: 0.85em; -} -#cc-main .pm__section-title { - border-radius: var(--cc-btn-border-radius); - font-size: 0.95em; - font-weight: 600; -} -#cc-main .pm__badge { - align-items: center; - background: var(--cc-btn-secondary-bg); - border-radius: 5em; - color: var(--cc-secondary-color); - display: flex; - flex: none; - font-size: 0.8em; - font-weight: 600; - height: 23px; - justify-content: center; - margin-left: 1em; - min-width: 23px; - overflow: hidden; - padding: 0 0.6em 1px; - position: relative; - text-align: center; - white-space: nowrap; - width: auto; -} -#cc-main .pm__service-counter { - background: var(--cc-btn-primary-bg); - color: var(--cc-btn-primary-color); - padding: 0; - width: 23px; -} -#cc-main .pm__service-counter[data-counterlabel] { - padding: 0 0.6em 1px; - width: auto; -} -#cc-main .section__toggle, -#cc-main .section__toggle-wrapper, -#cc-main .toggle__icon, -#cc-main .toggle__label { - border-radius: var(--cc-pm-toggle-border-radius); - height: 23px; - transform: translateZ(0); - width: 50px; -} -#cc-main .section__toggle-wrapper { - cursor: pointer; - position: absolute; - right: 18px; - z-index: 1; -} -#cc-main .toggle-service { - height: 19px; - position: relative; - right: 0; - width: 42px; -} -#cc-main .toggle-service .section__toggle, -#cc-main .toggle-service .toggle__icon, -#cc-main .toggle-service .toggle__label { - height: 19px; - width: 42px; -} -#cc-main .toggle-service .toggle__icon { - position: relative; -} -#cc-main .toggle-service .toggle__icon-circle { - height: 19px; - width: 19px; -} -#cc-main .toggle-service .section__toggle:checked ~ .toggle__icon .toggle__icon-circle { - transform: translateX(23px); -} -#cc-main .pm__section--toggle:nth-child(2) .section__toggle-wrapper:after { - display: none !important; -} -#cc-main .section__toggle { - border: 0; - cursor: pointer; - display: block; - left: 0; - margin: 0; - position: absolute; - top: 0; -} -#cc-main .section__toggle:disabled { - cursor: not-allowed; -} -#cc-main .toggle__icon { - background: var(--cc-toggle-off-bg); - box-shadow: 0 0 0 1px var(--cc-toggle-off-bg); - display: flex; - flex-direction: row; - pointer-events: none; - position: absolute; - transition: all 0.25s ease; -} -#cc-main .toggle__icon-circle { - background: var(--cc-toggle-off-knob-bg); - border: none; - border-radius: var(--cc-pm-toggle-border-radius); - box-shadow: 0 1px 2px rgba(24, 32, 3, 0.36); - display: block; - height: 23px; - left: 0; - position: absolute; - top: 0; - transition: - transform 0.25s ease, - background-color 0.25s ease; - width: 23px; -} -#cc-main .toggle__icon-off, -#cc-main .toggle__icon-on { - height: 100%; - position: absolute; - transition: opacity 0.15s ease; - width: 100%; -} -#cc-main .toggle__icon-on { - opacity: 0; - transform: rotate(45deg); -} -#cc-main .toggle__icon-on svg { - stroke: var(--cc-toggle-on-bg); - transform: scale(0.55) rotate(-45deg); -} -#cc-main .toggle__icon-off { - opacity: 1; -} -#cc-main .toggle__icon-off svg { - stroke: var(--cc-toggle-off-bg); - transform: scale(0.55); -} -#cc-main .section__toggle:checked ~ .toggle__icon { - background: var(--cc-toggle-on-bg); - box-shadow: 0 0 0 1px var(--cc-toggle-on-bg); -} -#cc-main .section__toggle:checked ~ .toggle__icon .toggle__icon-circle { - background-color: var(--cc-toggle-on-knob-bg); - transform: translateX(27px); -} -#cc-main .section__toggle:checked ~ .toggle__icon .toggle__icon-on { - opacity: 1; -} -#cc-main .section__toggle:checked ~ .toggle__icon .toggle__icon-off { - opacity: 0; -} -#cc-main .section__toggle:checked:disabled ~ .toggle__icon { - background: var(--cc-toggle-readonly-bg); - box-shadow: 0 0 0 1px var(--cc-toggle-readonly-bg); -} -#cc-main .section__toggle:checked:disabled ~ .toggle__icon .toggle__icon-circle { - background: var(--cc-toggle-readonly-knob-bg); - box-shadow: none; -} -#cc-main .section__toggle:checked:disabled ~ .toggle__icon svg { - stroke: var(--cc-toggle-readonly-knob-icon-color); -} -#cc-main .toggle__label { - opacity: 0; - overflow: hidden; - pointer-events: none; - position: absolute; - top: 0; - z-index: -1; -} -#cc-main .pm__section-desc-wrapper { - color: var(--cc-secondary-color); - display: flex; - flex-direction: column; - font-size: 0.9em; -} -#cc-main .pm__section-desc-wrapper > :not(:last-child) { - border-bottom: 1px solid var(--cc-cookie-category-block-border); -} -#cc-main .pm__section-services { - display: flex; - flex-direction: column; -} -#cc-main .pm__service { - align-items: center; - display: flex; - justify-content: space-between; - padding: 0.4em 1.2em; - position: relative; - transition: background-color 0.15s ease; -} -#cc-main .pm__service:hover { - background-color: var(--cc-cookie-category-block-hover-bg); -} -#cc-main .pm__service-header { - align-items: center; - display: flex; - margin-right: 1em; - width: 100%; -} -#cc-main .pm__service-icon { - border: 2px solid; - border-radius: 100%; - height: 8px; - margin-left: 6px; - margin-right: 20px; - margin-top: 1px; - min-width: 8px; -} -#cc-main .pm__service-title { - font-size: 0.95em; - width: 100%; - word-break: break-word; -} -#cc-main .pm__section-desc { - line-height: 1.5em; -} -#cc-main .pm__section-table { - border-collapse: collapse; - font-size: 0.9em; - margin: 0; - overflow: hidden; - padding: 0; - text-align: left; - width: 100%; -} -#cc-main .pm__table-caption { - text-align: left; -} -#cc-main .pm__table-caption, -#cc-main .pm__table-head > tr { - border-bottom: 1px dashed var(--cc-separator-border-color); - color: var(--cc-primary-color); - font-weight: 600; -} -#cc-main .pm__table-tr { - transition: background-color 0.15s ease; -} -#cc-main .pm__table-tr:hover { - background: var(--cc-cookie-category-block-hover-bg); -} -#cc-main .pm__table-caption, -#cc-main .pm__table-td, -#cc-main .pm__table-th { - padding: 0.625em 0.625em 0.625em 1.2em; - vertical-align: top; -} -#cc-main .pm__footer { - border-top: 1px solid var(--cc-separator-border-color); - display: flex; - justify-content: space-between; -} -#cc-main .pm__btn-group { - display: flex; -} -#cc-main .pm__btn + .pm__btn, -#cc-main .pm__btn-group + .pm__btn-group { - margin-left: 0.375rem; -} -#cc-main .pm--flip .pm__btn + .pm__btn, -#cc-main .pm--flip .pm__btn-group + .pm__btn-group { - margin-left: 0; - margin-right: 0.375rem; -} -#cc-main .pm__btn { - background: var(--cc-btn-primary-bg); - border: 1px solid var(--cc-btn-primary-border-color); - border-radius: var(--cc-btn-border-radius); - color: var(--cc-btn-primary-color); - flex: auto; - font-size: 0.82em; - font-weight: 600; - min-height: 42px; - min-width: 110px; - padding: 0.5em 1.5em; - text-align: center; - transition: - background-color 0.15s ease, - border-color 0.15s ease, - color 0.15s ease; -} -#cc-main .pm__btn:hover { - background: var(--cc-btn-primary-hover-bg); - border-color: var(--cc-btn-primary-hover-border-color); - color: var(--cc-btn-primary-hover-color); -} -#cc-main .pm__btn--secondary { - background: var(--cc-btn-secondary-bg); - border-color: var(--cc-btn-secondary-border-color); - color: var(--cc-btn-secondary-color); -} -#cc-main .pm__btn--secondary:hover { - background: var(--cc-btn-secondary-hover-bg); - border-color: var(--cc-btn-secondary-hover-border-color); - color: var(--cc-btn-secondary-hover-color); -} -#cc-main .pm--box { - height: calc(100% - 2em); - left: var(--cc-modal-margin); - margin: 0 auto; - max-height: 37.5em; - max-width: 43em; - right: var(--cc-modal-margin); - top: 50%; - transform: translateY(calc(-50% + 1.6em)); -} -#cc-main .pm--box.pm--flip .pm__btn-group, -#cc-main .pm--box.pm--flip .pm__footer { - flex-direction: row-reverse; -} -#cc-main .pm--bar { - border-radius: 0; - bottom: 0; - height: 100%; - margin: 0; - max-height: none; - max-width: 29em; - opacity: 1; - top: 0; - width: 100%; - --cc-modal-transition-duration: 0.35s; -} -#cc-main .pm--bar .pm__section-table, -#cc-main .pm--bar .pm__table-body, -#cc-main .pm--bar .pm__table-td, -#cc-main .pm--bar .pm__table-th, -#cc-main .pm--bar .pm__table-tr { - display: block; -} -#cc-main .pm--bar .pm__table-head { - display: none; -} -#cc-main .pm--bar .pm__table-caption { - display: block; -} -#cc-main .pm--bar .pm__table-tr:not(:last-child) { - border-bottom: 1px solid var(--cc-separator-border-color); -} -#cc-main .pm--bar .pm__table-td { - display: flex; - justify-content: space-between; -} -#cc-main .pm--bar .pm__table-td:before { - color: var(--cc-primary-color); - content: attr(data-column); - flex: 1; - font-weight: 600; - min-width: 100px; - overflow: hidden; - padding-right: 2em; - text-overflow: ellipsis; -} -#cc-main .pm--bar .pm__table-td > div { - flex: 3; -} -#cc-main .pm--bar:not(.pm--wide) .pm__body, -#cc-main .pm--bar:not(.pm--wide) .pm__footer, -#cc-main .pm--bar:not(.pm--wide) .pm__header { - padding: 1em 1.3em; -} -#cc-main .pm--bar:not(.pm--wide) .pm__btn-group, -#cc-main .pm--bar:not(.pm--wide) .pm__footer { - flex-direction: column; -} -#cc-main .pm--bar:not(.pm--wide) .pm__btn + .pm__btn, -#cc-main .pm--bar:not(.pm--wide) .pm__btn-group + .pm__btn-group { - margin: 0.375rem 0 0; -} -#cc-main .pm--bar:not(.pm--wide).pm--flip .pm__btn-group, -#cc-main .pm--bar:not(.pm--wide).pm--flip .pm__footer { - flex-direction: column-reverse; -} -#cc-main .pm--bar:not(.pm--wide).pm--flip .pm__btn + .pm__btn, -#cc-main .pm--bar:not(.pm--wide).pm--flip .pm__btn-group + .pm__btn-group { - margin-bottom: 0.375rem; - margin-top: 0; -} -#cc-main .pm--bar:not(.pm--wide) .pm__badge { - display: none; -} -#cc-main .pm--bar.pm--left { - left: 0; - transform: translateX(-100%); -} -#cc-main .pm--bar.pm--right { - right: 0; - transform: translateX(100%); -} -#cc-main .pm--bar.pm--wide { - max-width: 35em; -} -#cc-main .pm--bar.pm--wide .pm__body, -#cc-main .pm--bar.pm--wide .pm__footer, -#cc-main .pm--bar.pm--wide .pm__header { - padding: 1em 1.4em; -} -#cc-main .pm--bar.pm--wide.pm--flip .pm__btn-group, -#cc-main .pm--bar.pm--wide.pm--flip .pm__footer { - flex-direction: row-reverse; -} -#cc-main .pm-overlay { - background: var(--cc-overlay-bg); - bottom: 0; - content: ''; - left: 0; - opacity: 0; - position: fixed; - right: 0; - top: 0; - visibility: hidden; - z-index: 1; -} -#cc-main .cc--anim .pm, -#cc-main .cc--anim .pm-overlay { - transition: - opacity var(--cc-modal-transition-duration) ease, - visibility var(--cc-modal-transition-duration) ease, - transform var(--cc-modal-transition-duration) ease; -} -.show--preferences #cc-main .cc--anim .pm { - opacity: 1; - visibility: visible !important; -} -.show--preferences #cc-main .cc--anim .pm--box { - transform: translateY(-50%); -} -.show--preferences #cc-main .cc--anim .pm--bar { - transform: translateX(0); -} -.show--preferences #cc-main .cc--anim .pm-overlay { - opacity: 1; - visibility: visible; -} -#cc-main.cc--rtl .pm__service-header { - margin-left: 1em; - margin-right: 0; -} -#cc-main.cc--rtl .pm__section-arrow { - left: unset; - right: 18px; -} -#cc-main.cc--rtl .section__toggle-wrapper { - left: 18px; - right: unset; - transform-origin: left; -} -#cc-main.cc--rtl .toggle-service { - left: 0; -} -#cc-main.cc--rtl .pm__service-icon { - margin-left: 20px; - margin-right: 5px; -} -#cc-main.cc--rtl .pm__section--toggle .pm__section-title { - padding-left: 5.4em; - padding-right: 1.2em; -} -#cc-main.cc--rtl .pm__section--expandable .pm__section-title { - padding-right: 3.4em; -} -#cc-main.cc--rtl .pm__badge { - margin-left: unset; - margin-right: 1em; -} -#cc-main.cc--rtl .toggle__icon-circle { - transform: translateX(27px); -} -#cc-main.cc--rtl .toggle-service .toggle__icon-circle { - transform: translateX(23px); -} -#cc-main.cc--rtl .section__toggle:checked ~ .toggle__icon .toggle__icon-circle { - transform: translateX(0); -} -#cc-main.cc--rtl .pm__table-td, -#cc-main.cc--rtl .pm__table-th { - padding-left: unset; - padding-right: 1.2em; - text-align: right; -} -#cc-main.cc--rtl .pm__table-td { - padding-left: unset; - padding-right: 1.2em; -} -#cc-main.cc--rtl .pm__table-td:before { - padding-left: 2em; - padding-right: unset; -} -#cc-main.cc--rtl .pm__btn + .pm__btn, -#cc-main.cc--rtl .pm__btn-group + .pm__btn-group { - margin-left: 0; - margin-right: 0.375rem; -} -#cc-main.cc--rtl .pm--flip .pm__btn + .pm__btn, -#cc-main.cc--rtl .pm--flip .pm__btn-group + .pm__btn-group { - margin-left: 0.375rem; - margin-right: 0; -} -#cc-main.cc--rtl .pm--flip.pm--bar:not(.pm--wide) .pm__btn + .pm__btn, -#cc-main.cc--rtl .pm--flip.pm--bar:not(.pm--wide) .pm__btn-group + .pm__btn-group { - margin-left: 0; -} -@media screen and (max-width: 640px) { - #cc-main .pm { - border-radius: 0; - bottom: 0; - height: auto; - left: 0; - max-height: 100%; - max-width: none !important; - right: 0; - top: 0; - transform: translateY(1.6em); - } - #cc-main .pm__body, - #cc-main .pm__footer, - #cc-main .pm__header { - padding: 0.9em !important; - } - #cc-main .pm__badge { - display: none; - } - #cc-main .pm__section-table, - #cc-main .pm__table-body, - #cc-main .pm__table-caption, - #cc-main .pm__table-td, - #cc-main .pm__table-th, - #cc-main .pm__table-tr { - display: block; - } - #cc-main .pm__table-head { - display: none; - } - #cc-main .pm__table-tr:not(:last-child) { - border-bottom: 1px solid var(--cc-separator-border-color); - } - #cc-main .pm__table-td { - display: flex; - justify-content: space-between; - } - #cc-main .pm__table-td:before { - color: var(--cc-primary-color); - content: attr(data-column); - flex: 1; - font-weight: 600; - min-width: 100px; - overflow: hidden; - padding-right: 2em; - text-overflow: ellipsis; - } - #cc-main .pm__table-td > div { - flex: 3; - } - #cc-main .pm__btn-group, - #cc-main .pm__footer { - flex-direction: column !important; - } - #cc-main .pm__btn-group { - display: flex !important; - } - #cc-main .pm__btn + .pm__btn, - #cc-main .pm__btn-group + .pm__btn-group { - margin: 0.375rem 0 0 !important; - } - #cc-main .pm--flip .pm__btn + .pm__btn, - #cc-main .pm--flip .pm__btn-group + .pm__btn-group { - margin-bottom: 0.375rem !important; - margin-top: 0 !important; - } - #cc-main .pm--flip .pm__btn-group, - #cc-main .pm--flip .pm__footer { - flex-direction: column-reverse !important; - } - .show--preferences #cc-main .cc--anim .pm { - transform: translateY(0) !important; - } -} diff --git a/static/js/cookieconsent.umd.js b/static/js/cookieconsent.umd.js deleted file mode 100644 index c7394b4..0000000 --- a/static/js/cookieconsent.umd.js +++ /dev/null @@ -1,7 +0,0 @@ -/*! -* CookieConsent 3.1.0 -* https://github.com/orestbida/cookieconsent -* Author Orest Bida -* Released under the MIT License -*/ -var e,t;e=this,t=function(e){"use strict";const t="opt-in",o="opt-out",n="show--consent",r="show--preferences",s="disable--interaction",c="data-category",a="div",i="button",l="aria-hidden",d="btn-group",f="click",u="data-role",p="consentModal",h="preferencesModal";class m{constructor(){this.t={mode:t,revision:0,autoShow:!0,lazyHtmlGeneration:!0,autoClearCookies:!0,manageScriptTags:!0,hideFromBots:!0,cookie:{name:"cc_cookie",expiresAfterDays:182,domain:"",path:"/",secure:!0,sameSite:"Lax"}},this.o={i:{},l:"",_:{},u:{},p:{},m:[],v:!1,h:null,C:null,S:null,M:"",T:!0,D:!1,k:!1,A:!1,N:!1,H:[],V:!1,j:!0,I:[],L:!1,F:"",P:!1,O:[],R:[],B:[],$:[],G:!1,J:!1,U:!1,q:[],K:[],W:[],X:{},Y:{},Z:{},ee:{},te:{},oe:[]},this.ne={se:{},ae:{}},this.ce={},this.re={ie:"cc:onFirstConsent",le:"cc:onConsent",de:"cc:onChange",fe:"cc:onModalShow",_e:"cc:onModalHide",ue:"cc:onModalReady"}}}const g=new m,y=(e,t)=>e.indexOf(t),b=(e,t)=>-1!==y(e,t),v=e=>Array.isArray(e),w=e=>"string"==typeof e,C=e=>!!e&&"object"==typeof e&&!v(e),k=e=>"function"==typeof e,T=e=>Object.keys(e),S=e=>Array.from(new Set(e)),L=()=>document.activeElement,M=e=>e.preventDefault(),_=(e,t)=>e.querySelectorAll(t),x=e=>e.dispatchEvent(new Event("change")),H=e=>{const t=document.createElement(e);return e===i&&(t.type=e),t},A=(e,t,o)=>e.setAttribute(t,o),O=(e,t,o)=>{e.removeAttribute(o?"data-"+t:t)},I=(e,t,o)=>e.getAttribute(o?"data-"+t:t),R=(e,t)=>e.appendChild(t),P=(e,t)=>e.classList.add(t),j=(e,t)=>P(e,"cm__"+t),N=(e,t)=>P(e,"pm__"+t),B=(e,t)=>e.classList.remove(t),D=e=>{if("object"!=typeof e)return e;if(e instanceof Date)return new Date(e.getTime());let t=Array.isArray(e)?[]:{};for(let o in e){let n=e[o];t[o]=D(n)}return t},E=()=>{const e={},{O:t,X:o,Y:n}=g.o;for(const r of t)e[r]=X(n[r],T(o[r]));return e},Y=(e,t)=>dispatchEvent(new CustomEvent(e,{detail:t})),F=(e,t,o,n)=>{e.addEventListener(t,o),n&&g.o.m.push({pe:e,ge:t,me:o})},Z=()=>{const e=g.t.cookie.expiresAfterDays;return k(e)?e(g.o.F):e},X=(e,t)=>{const o=e||[],n=t||[];return o.filter(e=>!b(n,e)).concat(n.filter(e=>!b(o,e)))},q=e=>{g.o.R=S(e),g.o.F=(()=>{let e="custom";const{R:t,O:o,B:n}=g.o,r=t.length;return r===o.length?e="all":r===n.length&&(e="necessary"),e})()},G=(e,t,o,n)=>{const r="accept-",{show:s,showPreferences:c,hide:a,hidePreferences:i,acceptCategory:l}=t,d=e||document,u=e=>_(d,`[data-cc="${e}"]`),p=(e,t)=>{M(e),l(t),i(),a()},h=u("show-preferencesModal"),m=u("show-consentModal"),y=u(r+"all"),b=u(r+"necessary"),v=u(r+"custom"),w=g.t.lazyHtmlGeneration;for(const e of h)A(e,"aria-haspopup","dialog"),F(e,f,e=>{M(e),c()}),w&&(F(e,"mouseenter",e=>{M(e),g.o.N||o(t,n)},!0),F(e,"focus",()=>{g.o.N||o(t,n)}));for(let e of m)A(e,"aria-haspopup","dialog"),F(e,f,e=>{M(e),s(!0)},!0);for(let e of y)F(e,f,e=>{p(e,"all")},!0);for(let e of v)F(e,f,e=>{p(e)},!0);for(let e of b)F(e,f,e=>{p(e,[])},!0)},J=(e,t)=>{e&&(t&&(e.tabIndex=-1),e.focus(),t&&e.removeAttribute("tabindex"))},$=(e,t)=>{const o=n=>{n.target.removeEventListener("transitionend",o),"opacity"===n.propertyName&&"1"===getComputedStyle(e).opacity&&J((e=>1===e?g.ne.be:g.ne.ve)(t))};F(e,"transitionend",o)};let U;const z=e=>{clearTimeout(U),e?P(g.ne.ye,s):U=setTimeout(()=>{B(g.ne.ye,s)},500)},V=["M 19.5 4.5 L 4.5 19.5 M 4.5 4.501 L 19.5 19.5","M 3.572 13.406 L 8.281 18.115 L 20.428 5.885","M 21.999 6.94 L 11.639 17.18 L 2.001 6.82 "],W=(e=0,t=1.5)=>``,K=e=>{const t=g.ne,o=g.o;(e=>{const n=e===t.he,r=o.i.disablePageInteraction?t.ye:n?t.Ce:t.ye;F(r,"keydown",t=>{if("Tab"!==t.key||!(n?o.k&&!o.A:o.A))return;const r=L(),s=n?o.q:o.K;0!==s.length&&(t.shiftKey?r!==s[0]&&e.contains(r)||(M(t),J(s[1])):r!==s[1]&&e.contains(r)||(M(t),J(s[0])))},!0)})(e)},Q=["[href]",i,"input","details","[tabindex]"].map(e=>e+':not([tabindex="-1"])').join(","),ee=e=>{const{o:t,ne:o}=g,n=(e,t)=>{const o=_(e,Q);t[0]=o[0],t[1]=o[o.length-1]};1===e&&t.D&&n(o.he,t.q),2===e&&t.N&&n(o.we,t.K)},te=(e,t,o)=>{const{de:n,le:r,ie:s,_e:c,ue:a,fe:i}=g.ce,l=g.re;if(t){const n={modalName:t};return e===l.fe?k(i)&&i(n):e===l._e?k(c)&&c(n):(n.modal=o,k(a)&&a(n)),Y(e,n)}const d={cookie:g.o.p};e===l.ie?k(s)&&s(D(d)):e===l.le?k(r)&&r(D(d)):(d.changedCategories=g.o.I,d.changedServices=g.o.ee,k(n)&&n(D(d))),Y(e,D(d))},oe=(e,t)=>{try{return e()}catch(e){return!t&&console.warn("CookieConsent:",e),!1}},ne=e=>{const{Y:t,ee:o,O:n,X:r,oe:s,p:a,I:i}=g.o;for(const e of n){const n=o[e]||t[e]||[];for(const o of n){const n=r[e][o];if(!n)continue;const{onAccept:s,onReject:c}=n;!n.Se&&b(t[e],o)?(n.Se=!0,k(s)&&s()):n.Se&&!b(t[e],o)&&(n.Se=!1,k(c)&&c())}}if(!g.t.manageScriptTags)return;const l=s,d=e||a.categories||[],f=(e,n)=>{if(n>=e.length)return;const r=s[n];if(r.xe)return f(e,n+1);const a=r.Me,l=r.Te,u=r.De,p=b(d,l),h=!!u&&b(t[l],u);if(!u&&!r.ke&&p||!u&&r.ke&&!p&&b(i,l)||u&&!r.ke&&h||u&&r.ke&&!h&&b(o[l]||[],u)){r.xe=!0;const t=I(a,"type",!0);O(a,"type",!!t),O(a,c);let o=I(a,"src",!0);o&&O(a,"src",!0);const s=H("script");s.textContent=a.innerHTML;for(const{nodeName:e}of a.attributes)A(s,e,a[e]||I(a,e));t&&(s.type=t),o?s.src=o:o=a.src;const i=!!o&&(!t||["text/javascript","module"].includes(t));if(i&&(s.onload=s.onerror=()=>{f(e,++n)}),a.replaceWith(s),i)return}f(e,++n)};f(l,0)},re="bottom",se="left",ce="center",ae="right",ie="inline",le="wide",de="pm--",fe=["middle","top",re],ue=[se,ce,ae],pe={box:{Ee:[le,ie],Ae:fe,Ne:ue,He:re,Ve:ae},cloud:{Ee:[ie],Ae:fe,Ne:ue,He:re,Ve:ce},bar:{Ee:[ie],Ae:fe.slice(1),Ne:[],He:re,Ve:""}},he={box:{Ee:[],Ae:[],Ne:[],He:"",Ve:""},bar:{Ee:[le],Ae:[],Ne:[se,ae],He:"",Ve:se}},me=e=>{const t=g.o.i.guiOptions,o=t&&t.consentModal,n=t&&t.preferencesModal;0===e&&ge(g.ne.he,pe,o,"cm--","box","cm"),1===e&&ge(g.ne.we,he,n,de,"box","pm")},ge=(e,t,o,n,r,s)=>{e.className=s;const c=o&&o.layout,a=o&&o.position,i=o&&o.flipButtons,l=!o||!1!==o.equalWeightButtons,d=c&&c.split(" ")||[],f=d[0],u=d[1],p=f in t?f:r,h=t[p],m=b(h.Ee,u)&&u,y=a&&a.split(" ")||[],v=y[0],w=n===de?y[0]:y[1],C=b(h.Ae,v)?v:h.He,k=b(h.Ne,w)?w:h.Ve,T=t=>{t&&P(e,n+t)};T(p),T(m),T(C),T(k),i&&T("flip");const S=s+"__btn--secondary";if("cm"===s){const{je:e,Ie:t}=g.ne;e&&(l?B(e,S):P(e,S)),t&&(l?B(t,S):P(t,S))}else{const{Le:e}=g.ne;e&&(l?B(e,S):P(e,S))}},ye=(e,t)=>{const o=g.o,n=g.ne,{hide:r,hidePreferences:s,acceptCategory:c}=e,p=e=>{c(e),s(),r()},m=o.u&&o.u.preferencesModal;if(!m)return;const y=m.title,b=m.closeIconLabel,v=m.acceptAllBtn,k=m.acceptNecessaryBtn,S=m.savePreferencesBtn,L=m.sections||[],M=v||k||S;if(n.Fe)n.Pe=H(a),N(n.Pe,"body");else{n.Fe=H(a),P(n.Fe,"pm-wrapper");const e=H("div");P(e,"pm-overlay"),R(n.Fe,e),F(e,f,s),n.we=H(a),P(n.we,"pm"),A(n.we,"role","dialog"),A(n.we,l,!0),A(n.we,"aria-modal",!0),A(n.we,"aria-labelledby","pm__title"),F(n.ye,"keydown",e=>{27===e.keyCode&&s()},!0),n.Oe=H(a),N(n.Oe,"header"),n.Re=H("h2"),N(n.Re,"title"),n.Re.id="pm__title",n.Be=H(i),N(n.Be,"close-btn"),A(n.Be,"aria-label",m.closeIconLabel||""),F(n.Be,f,s),n.$e=H("span"),n.$e.innerHTML=W(),R(n.Be,n.$e),n.Ge=H(a),N(n.Ge,"body"),n.Je=H(a),N(n.Je,"footer");var _=H(a);P(_,"btns");var x=H(a),O=H(a);N(x,d),N(O,d),R(n.Je,x),R(n.Je,O),R(n.Oe,n.Re),R(n.Oe,n.Be),n.ve=H(a),A(n.ve,"tabIndex",-1),R(n.we,n.ve),R(n.we,n.Oe),R(n.we,n.Ge),M&&R(n.we,n.Je),R(n.Fe,n.we)}let I;y&&(n.Re.innerHTML=y,b&&A(n.Be,"aria-label",b)),L.forEach((e,t)=>{const r=e.title,s=e.description,c=e.linkedCategory,d=c&&o.P[c],u=e.cookieTable,p=u&&u.body,h=u&&u.caption,g=p&&p.length>0,y=!!d,b=y&&o.X[c],v=C(b)&&T(b)||[],k=y&&(!!s||!!g||T(b).length>0);var S=H(a);if(N(S,"section"),k||s){var L=H(a);N(L,"section-desc-wrapper")}let M=v.length;if(k&&M>0){const e=H(a);N(e,"section-services");for(const t of v){const o=b[t],n=o&&o.label||t,r=H(a),s=H(a),i=H(a),l=H(a);N(r,"service"),N(l,"service-title"),N(s,"service-header"),N(i,"service-icon");const f=be(n,t,d,!0,c);l.innerHTML=n,R(s,i),R(s,l),R(r,s),R(r,f),R(e,r)}R(L,e)}if(r){var _=H(a),x=H(y?i:a);if(N(_,"section-title-wrapper"),N(x,"section-title"),x.innerHTML=r,R(_,x),y){const e=H("span");e.innerHTML=W(2,3.5),N(e,"section-arrow"),R(_,e),S.className+="--toggle";const t=be(r,c,d);let o=m.serviceCounterLabel;if(M>0&&w(o)){let e=H("span");N(e,"badge"),N(e,"service-counter"),A(e,l,!0),A(e,"data-servicecounter",M),o&&(o=o.split("|"),o=o.length>1&&M>1?o[1]:o[0],A(e,"data-counterlabel",o)),e.innerHTML=M+(o?" "+o:""),R(x,e)}if(k){N(S,"section--expandable");var O=c+"-desc";A(x,"aria-expanded",!1),A(x,"aria-controls",O)}R(_,t)}else A(x,"role","heading"),A(x,"aria-level","3");R(S,_)}if(s){var j=H("p");N(j,"section-desc"),j.innerHTML=s,R(L,j)}if(k&&(A(L,l,"true"),L.id=O,((e,t,o)=>{F(x,f,()=>{t.classList.contains("is-expanded")?(B(t,"is-expanded"),A(o,"aria-expanded","false"),A(e,l,"true")):(P(t,"is-expanded"),A(o,"aria-expanded","true"),A(e,l,"false"))})})(L,S,x),g)){const e=H("table"),o=H("thead"),r=H("tbody");if(h){const t=H("caption");N(t,"table-caption"),t.innerHTML=h,e.appendChild(t)}N(e,"section-table"),N(o,"table-head"),N(r,"table-body");const s=u.headers,c=T(s),i=n.Ue.createDocumentFragment(),l=H("tr");for(const e of c){const o=s[e],n=H("th");n.id="cc__row-"+o+t,A(n,"scope","col"),N(n,"table-th"),n.innerHTML=o,R(i,n)}R(l,i),R(o,l);const d=n.Ue.createDocumentFragment();for(const e of p){const o=H("tr");N(o,"table-tr");for(const n of c){const r=s[n],c=e[n],i=H("td"),l=H(a);N(i,"table-td"),A(i,"data-column",r),A(i,"headers","cc__row-"+r+t),l.insertAdjacentHTML("beforeend",c),R(i,l),R(o,i)}R(d,o)}R(r,d),R(e,o),R(e,r),R(L,e)}(k||s)&&R(S,L);const D=n.Pe||n.Ge;y?(I||(I=H(a),N(I,"section-toggles")),I.appendChild(S)):I=null,R(D,I||S)}),v&&(n.ze||(n.ze=H(i),N(n.ze,"btn"),A(n.ze,u,"all"),R(x,n.ze),F(n.ze,f,()=>p("all"))),n.ze.innerHTML=v),k&&(n.Le||(n.Le=H(i),N(n.Le,"btn"),A(n.Le,u,"necessary"),R(x,n.Le),F(n.Le,f,()=>p([]))),n.Le.innerHTML=k),S&&(n.qe||(n.qe=H(i),N(n.qe,"btn"),N(n.qe,"btn--secondary"),A(n.qe,u,"save"),R(O,n.qe),F(n.qe,f,()=>p())),n.qe.innerHTML=S),n.Pe&&(n.we.replaceChild(n.Pe,n.Ge),n.Ge=n.Pe),me(1),o.N||(o.N=!0,te(g.re.ue,h,n.we),t(e),R(n.Ce,n.Fe),K(n.we),setTimeout(()=>P(n.Fe,"cc--anim"),100)),ee(2)};function be(e,t,o,n,r){const s=g.o,a=g.ne,i=H("label"),d=H("input"),u=H("span"),p=H("span"),h=H("span"),m=H("span"),y=H("span");if(m.innerHTML=W(1,3),y.innerHTML=W(0,3),d.type="checkbox",P(i,"section__toggle-wrapper"),P(d,"section__toggle"),P(m,"toggle__icon-on"),P(y,"toggle__icon-off"),P(u,"toggle__icon"),P(p,"toggle__icon-circle"),P(h,"toggle__label"),A(u,l,"true"),n?(P(i,"toggle-service"),A(d,c,r),a.ae[r][t]=d):a.se[t]=d,n?(e=>{F(d,"change",()=>{const t=a.ae[e],o=a.se[e];s.Z[e]=[];for(let o in t){const n=t[o];n.checked&&s.Z[e].push(n.value)}o.checked=s.Z[e].length>0})})(r):(e=>{F(d,f,()=>{const t=a.ae[e],o=d.checked;s.Z[e]=[];for(let n in t)t[n].checked=o,o&&s.Z[e].push(n)})})(t),d.value=t,h.textContent=e.replace(/<.*>.*<\/.*>/gm,""),R(p,y),R(p,m),R(u,p),s.T)(o.readOnly||o.enabled)&&(d.checked=!0);else if(n){const e=s.Y[r];d.checked=o.readOnly||b(e,t)}else b(s.R,t)&&(d.checked=!0);return o.readOnly&&(d.disabled=!0),R(i,d),R(i,u),R(i,h),i}const ve=()=>{const e=H("span");return g.ne.Ke||(g.ne.Ke=e),e},we=(e,t)=>{const o=g.o,n=g.ne,{hide:r,showPreferences:s,acceptCategory:c}=e,h=o.u&&o.u.consentModal;if(!h)return;const m=h.acceptAllBtn,y=h.acceptNecessaryBtn,b=h.showPreferencesBtn,v=h.closeIconLabel,w=h.footer,C=h.label,k=h.title,T=e=>{r(),c(e)};if(!n.Qe){n.Qe=H(a),n.he=H(a),n.We=H(a),n.Xe=H(a),n.Ye=H(a),P(n.Qe,"cm-wrapper"),P(n.he,"cm"),j(n.We,"body"),j(n.Xe,"texts"),j(n.Ye,"btns"),A(n.he,"role","dialog"),A(n.he,"aria-modal","true"),A(n.he,l,"false"),A(n.he,"aria-describedby","cm__desc"),C?A(n.he,"aria-label",C):k&&A(n.he,"aria-labelledby","cm__title");const e="box",t=o.i.guiOptions,r=t&&t.consentModal,s=(r&&r.layout||e).split(" ")[0]===e;k&&v&&s&&(n.Ie||(n.Ie=H(i),n.Ie.innerHTML=W(),j(n.Ie,"btn"),j(n.Ie,"btn--close"),F(n.Ie,f,()=>{T([])}),R(n.We,n.Ie)),A(n.Ie,"aria-label",v)),R(n.We,n.Xe),(m||y||b)&&R(n.We,n.Ye),n.be=H(a),A(n.be,"tabIndex",-1),R(n.he,n.be),R(n.he,n.We),R(n.Qe,n.he)}k&&(n.Ze||(n.Ze=H("h2"),n.Ze.className=n.Ze.id="cm__title",R(n.Xe,n.Ze)),n.Ze.innerHTML=k);let S=h.description;if(S&&(o.V&&(S=S.replace("{{revisionMessage}}",o.j?"":h.revisionMessage||"")),n.et||(n.et=H("p"),n.et.className=n.et.id="cm__desc",R(n.Xe,n.et)),n.et.innerHTML=S),m&&(n.tt||(n.tt=H(i),R(n.tt,ve()),j(n.tt,"btn"),A(n.tt,u,"all"),F(n.tt,f,()=>{T("all")})),n.tt.firstElementChild.innerHTML=m),y&&(n.je||(n.je=H(i),R(n.je,ve()),j(n.je,"btn"),A(n.je,u,"necessary"),F(n.je,f,()=>{T([])})),n.je.firstElementChild.innerHTML=y),b&&(n.ot||(n.ot=H(i),R(n.ot,ve()),j(n.ot,"btn"),j(n.ot,"btn--secondary"),A(n.ot,u,"show"),F(n.ot,"mouseenter",()=>{o.N||ye(e,t)}),F(n.ot,f,s)),n.ot.firstElementChild.innerHTML=b),n.nt||(n.nt=H(a),j(n.nt,d),m&&R(n.nt,n.tt),y&&R(n.nt,n.je),(m||y)&&R(n.We,n.nt),R(n.Ye,n.nt)),n.ot&&!n.st&&(n.st=H(a),n.je&&n.tt?(j(n.st,d),R(n.st,n.ot),R(n.Ye,n.st)):(R(n.nt,n.ot),j(n.nt,d+"--uneven"))),w){if(!n.ct){let e=H(a),t=H(a);n.ct=H(a),j(e,"footer"),j(t,"links"),j(n.ct,"link-group"),R(t,n.ct),R(e,t),R(n.he,e)}n.ct.innerHTML=w}me(0),o.D||(o.D=!0,te(g.re.ue,p,n.he),t(e),R(n.Ce,n.Qe),K(n.he),setTimeout(()=>P(n.Qe,"cc--anim"),100)),ee(1),G(n.We,e,ye,t)},Ce=e=>{if(!w(e))return null;if(e in g.o._)return e;let t=e.slice(0,2);return t in g.o._?t:null},ke=()=>g.o.l||g.o.i.language.default,Te=e=>{e&&(g.o.l=e)},Se=async e=>{const t=g.o;let o=Ce(e)?e:ke(),n=t._[o];if(w(n)?n=await(async e=>{try{const t=await fetch(e);return await t.json()}catch(e){return console.error(e),!1}})(n):k(n)&&(n=await n()),!n)throw`Could not load translation for the '${o}' language`;return t.u=n,Te(o),!0},Le=()=>{let e=g.o.i.language.rtl,t=g.ne.Ce;e&&t&&(v(e)||(e=[e]),b(e,g.o.l)?P(t,"cc--rtl"):B(t,"cc--rtl"))},Me=()=>{const e=g.ne;if(e.Ce)return;e.Ce=H(a),e.Ce.id="cc-main",e.Ce.setAttribute("data-nosnippet",""),Le();let t=g.o.i.root;t&&w(t)&&(t=document.querySelector(t)),(t||e.Ue.body).appendChild(e.Ce)},_e=e=>oe(()=>localStorage.removeItem(e)),xe=(e,t)=>{if(t instanceof RegExp)return e.filter(e=>t.test(e));{const o=y(e,t);return o>-1?[e[o]]:[]}},He=e=>{const{hostname:t,protocol:o}=location,{name:n,path:r,domain:s,sameSite:c,useLocalStorage:a,secure:i}=g.t.cookie,l=e?(()=>{const e=g.o.S,t=e?new Date-e:0;return 864e5*Z()-t})():864e5*Z(),d=new Date;d.setTime(d.getTime()+l),g.o.p.expirationTime=d.getTime();const f=JSON.stringify(g.o.p);let u=n+"="+encodeURIComponent(f)+(0!==l?"; expires="+d.toUTCString():"")+"; Path="+r+"; SameSite="+c;b(t,".")&&(u+="; Domain="+s),i&&"https:"===o&&(u+="; Secure"),a?((e,t)=>{oe(()=>localStorage.setItem(e,t))})(n,f):document.cookie=u,g.o.p},Ae=(e,t,o)=>{if(0===e.length)return;const n=o||g.t.cookie.domain,r=t||g.t.cookie.path,s="www."===n.slice(0,4),c=s&&n.substring(4),a=(e,t)=>{t&&"."!==t.slice(0,1)&&(t="."+t),document.cookie=e+"=; path="+r+(t?"; domain="+t:"")+"; expires=Thu, 01 Jan 1970 00:00:01 GMT;"};for(const t of e)a(t,o),o||a(t,n),s&&a(t,c)},Oe=e=>{const t=e||g.t.cookie.name,o=g.t.cookie.useLocalStorage;return((e,t)=>{let o;return o=oe(()=>JSON.parse(t?e:decodeURIComponent(e)),!0)||{},o})(o?(n=t,oe(()=>localStorage.getItem(n))||""):Ie(t,!0),o);var n},Ie=(e,t)=>{const o=document.cookie.match("(^|;)\\s*"+e+"\\s*=\\s*([^;]+)");return o?t?o.pop():e:""},Re=e=>{const t=document.cookie.split(/;\s*/),o=[];for(const n of t){let t=n.split("=")[0];e?oe(()=>{e.test(t)&&o.push(t)}):o.push(t)}return o},Pe=(e,n=[])=>{((e,t)=>{const{O:o,R:n,B:r,N:s,Z:c,$:a,X:i}=g.o;let l=[];if(e){v(e)?l.push(...e):w(e)&&(l="all"===e?o:[e]);for(const e of o)c[e]=b(l,e)?T(i[e]):[]}else l=[...n,...a],s&&(l=(()=>{const e=g.ne.se;if(!e)return[];let t=[];for(let o in e)e[o].checked&&t.push(o);return t})());l=l.filter(e=>!b(o,e)||!b(t,e)),l.push(...r),q(l)})(e,n),(()=>{const e=g.o,{Z:t,B:o,Y:n,X:r,O:s}=e,c=s;e.te=D(n);for(const s of c){const c=r[s],a=T(c),i=t[s]&&t[s].length>0,l=b(o,s);if(0!==a.length){if(n[s]=[],l)n[s].push(...a);else if(i){const e=t[s];n[s].push(...e)}else n[s]=e.Z[s];n[s]=S(n[s])}}})(),(()=>{const e=g.o;e.I=g.t.mode===o&&e.T?X(e.$,e.R):X(e.R,e.p.categories);let n=e.I.length>0,r=!1;for(const t of e.O)e.ee[t]=X(e.Y[t],e.te[t]),e.ee[t].length>0&&(r=!0);const s=g.ne.se;for(const t in s)s[t].checked=b(e.R,t);for(const t of e.O){const o=g.ne.ae[t],n=e.Y[t];for(const e in o)o[e].checked=b(n,e)}e.C||(e.C=new Date),e.M||(e.M=([1e7]+-1e3+-4e3+-8e3+-1e11).replace(/[018]/g,e=>(e^crypto.getRandomValues(new Uint8Array(1))[0]&15>>e/4).toString(16))),e.p={categories:D(e.R),revision:g.t.revision,data:e.h,consentTimestamp:e.C.toISOString(),consentId:e.M,services:D(e.Y),languageCode:g.o.l},e.S&&(e.p.lastConsentTimestamp=e.S.toISOString());let c=!1;const a=n||r;(e.T||a)&&(e.T&&(e.T=!1,c=!0),e.S=e.S?new Date:e.C,e.p.lastConsentTimestamp=e.S.toISOString(),He(),g.t.autoClearCookies&&(c||a)&&(e=>{const t=g.o,o=Re(),n=(e=>{const t=g.o;return(e?t.O:t.I).filter(e=>{const o=t.P[e];return!!o&&!o.readOnly&&!!o.autoClear})})(e);for(const e in t.ee)for(const n of t.ee[e]){const r=t.X[e][n].cookies;if(!b(t.Y[e],n)&&r)for(const e of r){const t=xe(o,e.name);Ae(t,e.path,e.domain)}}for(const r of n){const n=t.P[r].autoClear,s=n&&n.cookies||[],c=b(t.I,r),a=!b(t.R,r),i=c&&a;if(e?a:i){n.reloadPage&&i&&(t.L=!0);for(const e of s){const t=xe(o,e.name);Ae(t,e.path,e.domain)}}}})(c),ne()),c&&(te(g.re.ie),te(g.re.le),g.t.mode===t)||(a&&te(g.re.de),e.L&&(e.L=!1,location.reload()))})()},je=e=>{const t=g.o.T?[]:g.o.R;return b(t,e)},Ne=(e,t)=>{const o=g.o.T?[]:g.o.Y[t]||[];return b(o,e)},Be=(e,t,o)=>{let n=[];const r=e=>{if(w(e)){let t=Ie(e);""!==t&&n.push(t)}else n.push(...Re(e))};if(v(e))for(let t of e)r(t);else r(e);Ae(n,t,o)},De=e=>{const{ne:t,o:o}=g;if(!o.k){if(!o.D){if(!e)return;we(Ze,Me)}o.k=!0,o.J=L(),o.v&&z(!0),$(t.he,1),P(t.ye,n),A(t.he,l,"false"),setTimeout(()=>{J(g.ne.be)},100),te(g.re.fe,p)}},Ee=()=>{const{ne:e,o:t,re:o}=g;t.k&&(t.k=!1,t.v&&z(),J(e.Ke,!0),B(e.ye,n),A(e.he,l,"true"),J(t.J),t.J=null,te(o._e,p))},Ye=()=>{const e=g.o;e.A||(e.N||ye(Ze,Me),e.A=!0,e.k?e.U=L():e.J=L(),$(g.ne.we,2),P(g.ne.ye,r),A(g.ne.we,l,"false"),setTimeout(()=>{J(g.ne.ve)},100),te(g.re.fe,h))},Fe=()=>{const e=g.o;e.A&&(e.A=!1,(()=>{const e=qe(),t=g.o.P,o=g.ne.se,n=g.ne.ae,r=e=>b(g.o.$,e);for(const s in o){const c=!!t[s].readOnly;o[s].checked=c||(e?je(s):r(s));for(const t in n[s])n[s][t].checked=c||(e?Ne(t,s):r(s))}})(),J(g.ne.$e,!0),B(g.ne.ye,r),A(g.ne.we,l,"true"),e.k?(J(e.U),e.U=null):(J(e.J),e.J=null),te(g.re._e,h))};var Ze={show:De,hide:Ee,showPreferences:Ye,hidePreferences:Fe,acceptCategory:Pe};const Xe=(e,t)=>{const o=Oe(t);return e?o[e]:o},qe=()=>!g.o.T;e.acceptCategory=Pe,e.acceptService=(e,t)=>{const{O:o,X:n}=g.o;if(!(e&&t&&w(t)&&b(o,t)&&0!==T(n[t]).length))return!1;((e,t)=>{const o=g.o,{X:n,Z:r,N:s}=o,c=g.ne.ae[t]||{},a=g.ne.se[t]||{},i=T(n[t]);if(r[t]=[],w(e)){if("all"===e){if(r[t].push(...i),s)for(let e in c)c[e].checked=!0,x(c[e])}else if(b(i,e)&&r[t].push(e),s)for(let t in c)c[t].checked=e===t,x(c[t])}else if(v(e))for(let o of i){const n=b(e,o);n&&r[t].push(o),s&&(c[o].checked=n,x(c[o]))}const l=0===r[t].length;o.R=l?o.R.filter(e=>e!==t):S([...o.R,t]),s&&(a.checked=!l,x(a))})(e,t),Pe()},e.acceptedCategory=je,e.acceptedService=Ne,e.eraseCookies=Be,e.getConfig=e=>{const t=g.t,o=g.o.i;return e?t[e]||o[e]:{...t,...o,cookie:{...t.cookie}}},e.getCookie=Xe,e.getUserPreferences=()=>{const{F:e,Y:t}=g.o,{accepted:o,rejected:n}=(()=>{const{T:e,R:t,O:o}=g.o;return{accepted:t,rejected:e?[]:o.filter(e=>!b(t,e))}})();return D({acceptType:e,acceptedCategories:o,rejectedCategories:n,acceptedServices:t,rejectedServices:E()})},e.hide=Ee,e.hidePreferences=Fe,e.loadScript=(e,t)=>{let o=document.querySelector('script[src="'+e+'"]');return new Promise(n=>{if(o)return n(!0);if(o=H("script"),C(t))for(const e in t)A(o,e,t[e]);o.onload=()=>n(!0),o.onerror=()=>{o.remove(),n(!1)},o.src=e,R(document.head,o)})},e.reset=e=>{const{Ce:t,ye:o}=g.ne,{name:c,path:a,domain:i,useLocalStorage:l}=g.t.cookie;e&&(l?_e(c):Be(c,a,i));for(const{pe:e,ge:t,me:o}of g.o.m)e.removeEventListener(t,o);t&&t.remove(),o&&o.classList.remove(s,r,n);const d=new m;for(const e in g)g[e]=d[e];window._ccRun=!1},e.run=async e=>{const{o:t,t:n,re:r}=g,s=window;if(!s._ccRun){if(s._ccRun=!0,(e=>{const{ne:t,t:n,o:r}=g,s=n,a=r,{cookie:i}=s,l=g.ce,d=e.cookie,f=e.categories,u=T(f)||[],p=navigator,h=document;t.Ue=h,t.ye=h.documentElement,i.domain=location.hostname,a.i=e,a.P=f,a.O=u,a._=e.language.translations,a.v=!!e.disablePageInteraction,l.ie=e.onFirstConsent,l.le=e.onConsent,l.de=e.onChange,l._e=e.onModalHide,l.fe=e.onModalShow,l.ue=e.onModalReady;const{mode:m,autoShow:y,lazyHtmlGeneration:v,autoClearCookies:w,revision:k,manageScriptTags:S,hideFromBots:L}=e;m===o&&(s.mode=m),"boolean"==typeof w&&(s.autoClearCookies=w),"boolean"==typeof S&&(s.manageScriptTags=S),"number"==typeof k&&k>=0&&(s.revision=k,a.V=!0),"boolean"==typeof y&&(s.autoShow=y),"boolean"==typeof v&&(s.lazyHtmlGeneration=v),!1===L&&(s.hideFromBots=!1),!0===s.hideFromBots&&p&&(a.G=p.userAgent&&/bot|crawl|spider|slurp|teoma/i.test(p.userAgent)||p.webdriver),C(d)&&(s.cookie={...i,...d}),s.autoClearCookies,a.V,s.manageScriptTags,(e=>{const{P:t,X:o,Y:n,Z:r,B:s}=g.o;for(let c of e){const e=t[c],a=e.services||{},i=C(a)&&T(a)||[];o[c]={},n[c]=[],r[c]=[],e.readOnly&&(s.push(c),n[c]=i),g.ne.ae[c]={};for(let e of i){const t=a[e];t.Se=!1,o[c][e]=t}}})(u),(()=>{if(!g.t.manageScriptTags)return;const e=g.o,t=_(document,"script["+c+"]");for(const o of t){let t=I(o,c),n=o.dataset.service||"",r=!1;if(t&&"!"===t.charAt(0)&&(t=t.slice(1),r=!0),"!"===n.charAt(0)&&(n=n.slice(1),r=!0),b(e.O,t)&&(e.oe.push({Me:o,xe:!1,ke:r,Te:t,De:n}),n)){const o=e.X[t];o[n]||(o[n]={Se:!1})}}})(),Te((()=>{const e=g.o.i.language.autoDetect;if(e){const t={browser:navigator.language,document:document.documentElement.lang},o=Ce(t[e]);if(o)return o}return ke()})())})(e),t.G)return;(()=>{const e=g.o,t=g.t,n=Oe(),{categories:r,services:s,consentId:c,consentTimestamp:a,lastConsentTimestamp:i,data:l,revision:d}=n,f=v(r);e.p=n,e.M=c;const u=!!c&&w(c);e.C=a,e.C&&(e.C=new Date(a)),e.S=i,e.S&&(e.S=new Date(i)),e.h=void 0!==l?l:null,e.V&&u&&d!==t.revision&&(e.j=!1),e.T=!(u&&e.j&&e.C&&e.S&&f),t.cookie.useLocalStorage&&!e.T&&(e.T=(new Date).getTime()>(n.expirationTime||0),e.T&&_e(t.cookie.name)),e.T,(()=>{const e=g.o;for(const t of e.O){const n=e.P[t];if(n.readOnly||n.enabled){e.$.push(t);const n=e.X[t]||{};for(let r in n)e.Z[t].push(r),e.i.mode===o&&e.Y[t].push(r)}}})(),e.T?t.mode===o&&(e.R=[...e.$]):(e.Y={...e.Y,...s},e.Z={...e.Y},q([...e.B,...r]))})();const i=qe();if(!await Se())return!1;if(G(null,a=Ze,ye,Me),g.o.T&&we(a,Me),g.t.lazyHtmlGeneration||ye(a,Me),n.autoShow&&!i&&De(!0),i)return ne(),te(r.le);n.mode===o&&ne(t.$)}var a},e.setCookieData=e=>{let t,o=e.value,n=e.mode,r=!1;const s=g.o;if("update"===n){s.h=t=Xe("data");const e=typeof t==typeof o;if(e&&"object"==typeof t){!t&&(t={});for(let e in o)t[e]!==o[e]&&(t[e]=o[e],r=!0)}else!e&&t||t===o||(t=o,r=!0)}else t=o,r=!0;return r&&(s.h=t,s.p.data=t,He(!0)),r},e.setLanguage=async(e,t)=>{if(!Ce(e))return!1;const o=g.o;return!(e===ke()&&!0!==t||!await Se(e)||(Te(e),o.D&&we(Ze,Me),o.N&&ye(Ze,Me),Le(),0))},e.show=De,e.showPreferences=Ye,e.validConsent=qe,e.validCookie=e=>""!==Ie(e,!0)},"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).CookieConsent={}); \ No newline at end of file diff --git a/static/js/theme.js b/static/js/theme.js index 8cb34a6..71924ba 100644 --- a/static/js/theme.js +++ b/static/js/theme.js @@ -48,19 +48,6 @@ document.addEventListener('DOMContentLoaded', () => { }); } - // Sync cookieconsent dark mode reactively with the site theme - const syncCCTheme = () => { - const ccMain = document.getElementById('cc-main'); - if (!ccMain) return; - ccMain.classList.toggle('cc--darkmode', htmlElement.classList.contains('dark')); - }; - new MutationObserver(syncCCTheme).observe(htmlElement, { - attributes: true, - attributeFilter: ['class'], - }); - // Initial sync in case banner is already mounted - setTimeout(syncCCTheme, 100); - // Sync Utterances (comments iframe) theme with the site theme. // The iframe only reads its initial `theme` attribute once, so later // changes must go through postMessage per the utterances protocol. diff --git a/static/llms.txt b/static/llms.txt new file mode 100644 index 0000000..1782699 --- /dev/null +++ b/static/llms.txt @@ -0,0 +1,40 @@ +# andwati.com + +> Ian Andwati's personal blog about mathematics, computer science, binary exploitation, reverse engineering, capture-the-flag competitions, offensive security, Linux, and software development. + +This site contains articles in English, often with commands, code samples, worked explanations, and material aimed at readers learning by doing. + +## Main pages + +- [Home](https://andwati.com/): Introduction and latest articles. +- [About](https://andwati.com/about/): About the author and contact information. +- [Posts](https://andwati.com/posts/): All published articles. +- [Tags](https://andwati.com/tags/): Articles grouped by topic. +- [Archive](https://andwati.com/archive/): Chronological article archive. + +## Published articles + +- [The One Thing Nobody Tells You About WiFi Hotspots on Arch Linux](https://andwati.com/posts/wifi-hotspot-arch/): A minimal Arch install is great until NetworkManager silently fails to find a binary you didn't know you needed +- [From C to Machine Code: What Actually Runs](https://andwati.com/posts/from-c-to-machine-code/): Before diving into how to break a program, we need to understand what the computer is actually executing +- [The Single Byte That Kills Your Exploit: Understanding Endianness](https://andwati.com/posts/the-single-byte-that-kills-your-exploit-understanding-endianness/): Problem: Computers speak different languages, like people +- [What is pwn?](https://andwati.com/posts/what-is-pwn/): No not that one +- [ScriptCTF 2025 Writeup](https://andwati.com/posts/scriptctf2025/): ScriptCTF 2025 Writeup +- [mmuctf 2025 writeup](https://andwati.com/posts/mmuctf2025/): mmuctf 2025 challenges writeup +- [cognitive inertia](https://andwati.com/posts/inertia/): inertia +- [Export default and module.exports in Javascript](https://andwati.com/posts/javascript-exporting-modules/): Modules are the building blocks of modern JavaScript applications, allowing for the encapsulation of code into reusable components. Two primary systems govern the exportation of these modules: export default in ES6 and module.exports in CommonJS. +- [Setting up Obsidian sync in Windows](https://andwati.com/posts/obsidian-sync/): Syncing Obsidian in Windows with Windows Task Scheduler with git +- [A Fresh Coat Of Paint](https://andwati.com/posts/a-fresh-coat-of-paint/): Migrating to Zola +- [What say you?](https://andwati.com/posts/utterances-comments/): Adding a comment system by utterances +- [Subresource Integrity](https://andwati.com/posts/subresource-integrity/): Understanding Subresource Integrity +- [Install PostgreSQL on Arch | Manjaro | Garuda Linux](https://andwati.com/posts/install-postgresql-15-on-arch-manjaro-garuda-linux/): Getting PostgreSQL up and running on Arch Linux-based distros +- [Semantic Versioning(SemVer) and Conventional Commits](https://andwati.com/posts/semantic-version-and-conventional-commits/): Adopting best practices in your git and build workflows. +- [Integrating Netlify CMS](https://andwati.com/posts/integrating-netlify/): Integrating netlify cms +- [Django Secret Key Tutorial](https://andwati.com/posts/generate-django-secret-key/): Managing secrets +- [Hello World](https://andwati.com/posts/hello-world/): Hello world +- [Configure Vue.js app With Tailwind CSS](https://andwati.com/posts/vuejs-tailwind/): Tailwindcss in vuejs + +## Feeds and discovery + +- [RSS feed](https://andwati.com/rss.xml): Full site feed in RSS format. +- [JSON feed](https://andwati.com/feed.json): Full site feed in JSON format. +- [Sitemap](https://andwati.com/sitemap.xml): Machine-readable index of public pages. diff --git a/templates/base.html b/templates/base.html index ab399f9..903f451 100644 --- a/templates/base.html +++ b/templates/base.html @@ -90,153 +90,16 @@ {% if config.extra.google_analytics %} - + + {% endif %} - - - - - - - - - {% block head %}{% endblock head %} diff --git a/zola.toml b/zola.toml index 637ed90..0d6446a 100644 --- a/zola.toml +++ b/zola.toml @@ -18,6 +18,8 @@ lazy_async_image = true theme = "gruvbox-dark-medium" [extra] +llms_description = "Ian Andwati's personal blog about mathematics, computer science, binary exploitation, reverse engineering, capture-the-flag competitions, offensive security, Linux, and software development." + # Analytics google_analytics = "G-4HGRQ9QNPD" google_site_verification = ""