diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS new file mode 100644 index 0000000..c48ef23 --- /dev/null +++ b/.github/CODEOWNERS @@ -0,0 +1 @@ +* @mauro-balades \ No newline at end of file diff --git a/src/assets/tuta-logo.png b/src/assets/sponsors/tuta-logo.png similarity index 100% rename from src/assets/tuta-logo.png rename to src/assets/sponsors/tuta-logo.png diff --git a/src/assets/sponsors/tutaLogo_monochrome.svg b/src/assets/sponsors/tutaLogo_monochrome.svg new file mode 100644 index 0000000..d82f2dc --- /dev/null +++ b/src/assets/sponsors/tutaLogo_monochrome.svg @@ -0,0 +1,13 @@ + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/components/Features.astro b/src/components/Features.astro index 4020cb3..73527b5 100644 --- a/src/components/Features.astro +++ b/src/components/Features.astro @@ -28,7 +28,7 @@ const descriptions = Object.values(features.featureTabs).map((tab) => tab.descri id="Features" class="relative flex w-full flex-col py-12 text-start lg:py-36" > - + {title1} diff --git a/src/components/Sponsors.astro b/src/components/Sponsors.astro index 9bcf4e8..95b9f19 100644 --- a/src/components/Sponsors.astro +++ b/src/components/Sponsors.astro @@ -6,7 +6,7 @@ import { getLocale, getUI } from '~/utils/i18n' const locale = getLocale(Astro) -import tutaLogo from '~/assets/tuta-logo.png' +import tutaLogo from '~/assets/sponsors/tutaLogo_monochrome.svg' import Image from 'astro/components/Image.astro' const { showSponsors = true } = Astro.props diff --git a/src/components/download/DownloadScript.astro b/src/components/download/DownloadScript.astro index b8d6033..c58b01b 100644 --- a/src/components/download/DownloadScript.astro +++ b/src/components/download/DownloadScript.astro @@ -26,32 +26,32 @@ // Function to select a platform async function selectPlatform(platform: string) { // Update button styling - platformButtons.forEach((button) => { + for (const button of platformButtons) { const buttonPlatform = button.getAttribute('data-platform') if (buttonPlatform === platform) { button.setAttribute('data-active', 'true') } else { button.setAttribute('data-active', 'false') } - }) + } // Show/hide platform sections - platformSections.forEach((section) => { + for (const section of platformSections) { if (section.id === `${platform}-downloads`) { section.setAttribute('data-active', 'true') } else { section.setAttribute('data-active', 'false') } - }) + } } // Handle platform button clicks - platformButtons.forEach((button) => { + for (const button of platformButtons) { button.addEventListener('click', () => { const platform = button.getAttribute('data-platform') ?? '' selectPlatform(platform) }) - }) + } // Check for twilight mode async function checkTwilightMode() { @@ -70,21 +70,21 @@ } const tags = document.querySelectorAll('.release-type-tag') - tags.forEach((tag) => { + for (const tag of tags) { tag.innerHTML = tag.innerHTML.replace('Beta', 'Twilight') - }) + } // Apply twilight mode to all relevant elements const coralElements = document.querySelectorAll( - '.download-browser-logo, .release-type-tag, .decorative-gradient, .download-link, .download-arrow-icon, .download-card__icon, .checksum-icon-btn, .copy-btn', + '.download-browser-logo, .release-type-tag, .decorative-gradient, .download-link, .download-arrow-icon, .download-card__icon, .checksum-icon-btn, .copy-btn, .flathub-download', ) - coralElements.forEach((element) => { + for (const element of coralElements) { element.setAttribute('data-twilight', 'true') - }) + } // Replace all download links with twilight versions const downloadLinks = document.querySelectorAll('a.download-link') - downloadLinks.forEach((link) => { + for (const link of downloadLinks) { if (!link.id.includes('beta')) { const href = link.getAttribute('href') if (href && href.includes('/latest/download/')) { @@ -95,7 +95,7 @@ link.setAttribute('href', twilightHref) } } - }) + } } } diff --git a/src/components/download/PlatformDownload.astro b/src/components/download/PlatformDownload.astro index 983aef9..f4c0eb9 100644 --- a/src/components/download/PlatformDownload.astro +++ b/src/components/download/PlatformDownload.astro @@ -59,7 +59,7 @@ function isFlatReleaseInfo(obj: unknown): obj is ReleaseInfo { platform === "linux" ? ( <> {releases.flathub && releases.flathub.all.label && ( -
+

Package Managers

-
+ )} {releases.x86_64 && typeof releases.x86_64 === "object" && "tarball" in releases.x86_64 && (releases.x86_64.tarball) && ( -
+

x86_64

{releases.x86_64.tarball && ( @@ -94,13 +94,13 @@ function isFlatReleaseInfo(obj: unknown): obj is ReleaseInfo { /> )}
-
+ )} {releases.aarch64 && typeof releases.aarch64 === "object" && "tarball" in releases.aarch64 && (releases.aarch64.tarball) && ( -
+

ARM64

{releases.aarch64.tarball && ( @@ -120,7 +120,7 @@ function isFlatReleaseInfo(obj: unknown): obj is ReleaseInfo { /> )}
-
+ )} ) : ( diff --git a/src/pages/[...locale]/release-notes/index.astro b/src/pages/[...locale]/release-notes/index.astro index 5ad55a2..ea1dd5d 100644 --- a/src/pages/[...locale]/release-notes/index.astro +++ b/src/pages/[...locale]/release-notes/index.astro @@ -130,6 +130,14 @@ const { window.addEventListener('scroll', toggleScrollButton) versionButton?.addEventListener('click', openVersionModal) versionList?.addEventListener('click', navigateToVersion) + + document.addEventListener('keydown', (e) => { + if (e.key === 'Escape' && modal?.hasAttribute('open')) { + closeModal(modal) + // Remove scroll lock if present + document.body.style.overflow = '' + } + })