diff --git a/bun.lockb b/bun.lockb index 2a04662..d4d15e6 100755 Binary files a/bun.lockb and b/bun.lockb differ diff --git a/package.json b/package.json index a0801cc..84d2924 100644 --- a/package.json +++ b/package.json @@ -12,8 +12,7 @@ "@astrojs/tailwind": "^5.0.4", "@fontsource/averia-serif-libre": "^5.0.18", "@fontsource/merriweather": "^5.0.8", - "astro": "^4.0.8", - "astro-compress": "^2.2.15", + "astro": "^4.9.2", "astro-page-insight": "^0.4.1", "astro-robots-txt": "^1.0.0", "astro-seo": "^0.8.3", diff --git a/public/video/view-transitions-demo.webm b/public/video/view-transitions-demo.webm new file mode 100644 index 0000000..094d52a Binary files /dev/null and b/public/video/view-transitions-demo.webm differ diff --git a/src/components/featured-and-projects/projects.tsx b/src/components/featured-and-projects/projects.tsx index 53e1eb7..966544e 100644 --- a/src/components/featured-and-projects/projects.tsx +++ b/src/components/featured-and-projects/projects.tsx @@ -135,6 +135,113 @@ function goLeft() { cooldown.value = COOLDOWN_TIME } +function GitHubIcon() { + return ( + + + + + + ) +} + +function DemoIcon() { + return ( + + + + + + + + + + + + + + + + + + + ) +} + +function OfficialWebsiteIcon() { + return ( + + + + ) +} + +function ExternalLinkBadge({ + type = 'demo', + href, + lang = 'en' +}: { + type: 'demo' | 'official' | 'repository' + href: string + lang?: 'en' | 'es' +}) { + let displayedText + if (type === 'demo') { + displayedText = 'Preview' + } else if (type === 'official') { + if (lang === 'en') displayedText = 'Website' + else displayedText = 'Sitio Web' + } else if (lang === 'en') displayedText = 'Repository' + else displayedText = 'Repositorio' + const Icon = + type === 'demo' + ? DemoIcon + : type === 'official' + ? OfficialWebsiteIcon + : GitHubIcon + return ( + + + {displayedText} + + ) +} + function ProjectCard({ project, lang, @@ -182,34 +289,13 @@ function ProjectCard({ )}
{project?.repository && ( - - {lang === 'es' ? 'Repositorio' : 'Repository'} - + )} {project?.demo && ( - - {lang === 'es' ? 'Demo' : 'Preview'} - + )} {project?.website && ( - - {lang === 'es' ? 'Sitio web' : 'Website'} - + )}
diff --git a/src/components/featured-and-projects/resources.tsx b/src/components/featured-and-projects/resources.tsx index 5036466..9a829b5 100644 --- a/src/components/featured-and-projects/resources.tsx +++ b/src/components/featured-and-projects/resources.tsx @@ -85,7 +85,9 @@ export default function Resources({ n = 3 }: ResourceProps) { const resource = shuffleData.at((i + index.value) % data.length) return (
+ + + + + + { // eslint-disable-next-line diff --git a/src/components/head/scripts.astro b/src/components/head/scripts.astro index c65f42a..557f7bc 100644 --- a/src/components/head/scripts.astro +++ b/src/components/head/scripts.astro @@ -12,8 +12,19 @@ const blob = rawBlobs.at(index)! // @ts-ignore import { pwaInfo } from 'virtual:pwa-info' + +const url = Astro.url +const isInDeno = url.toString().includes('.deno.dev') --- + + + + + + + + + + { // eslint-disable-next-line diff --git a/src/components/main/buttons.astro b/src/components/main/buttons.astro index 579cd19..5baea9a 100644 --- a/src/components/main/buttons.astro +++ b/src/components/main/buttons.astro @@ -87,7 +87,7 @@ const SVGS_STYLES = [ en/es - diff --git a/src/components/main/working-on.tsx b/src/components/main/working-on.tsx index 9e3964e..d7878eb 100644 --- a/src/components/main/working-on.tsx +++ b/src/components/main/working-on.tsx @@ -57,7 +57,7 @@ function ProjectCard({ lang = 'en', project }: ProjectCardProps) { alt={`snap for ${project?.title.en}`} width='960' height='720' - loading='lazy' + loading='eager' class='aspect-[4/3] w-32' />