From aea400db5db347894992cf7a00cb3c010f72755c Mon Sep 17 00:00:00 2001 From: Yohan Boujon Date: Thu, 25 Jan 2024 00:01:23 +0100 Subject: [PATCH] Frontend: Adjusted CSS to work with mobile environnement. --- frontend/src/app.html | 2 +- frontend/src/lib/components/education.svelte | 1 + frontend/src/lib/components/experience.svelte | 1 + frontend/src/lib/components/projects.svelte | 3 +- frontend/src/lib/components/slideshow.svelte | 11 +- frontend/src/lib/css/cv.css | 53 ++++-- frontend/src/lib/css/pill.css | 6 +- frontend/src/lib/css/section.css | 59 ++++-- frontend/src/lib/css/slide.css | 178 ++++++++++++------ frontend/src/lib/css/slideshow.css | 56 ++++-- frontend/vite.config.js | 2 +- 11 files changed, 264 insertions(+), 108 deletions(-) diff --git a/frontend/src/app.html b/frontend/src/app.html index 495490a..f3c9371 100644 --- a/frontend/src/app.html +++ b/frontend/src/app.html @@ -3,7 +3,7 @@ - + %sveltekit.head% diff --git a/frontend/src/lib/components/education.svelte b/frontend/src/lib/components/education.svelte index 5daaf71..e66d7ad 100644 --- a/frontend/src/lib/components/education.svelte +++ b/frontend/src/lib/components/education.svelte @@ -23,6 +23,7 @@

{title}

+ Education {#if location}
diff --git a/frontend/src/lib/components/experience.svelte b/frontend/src/lib/components/experience.svelte index 6342f50..65b3da9 100644 --- a/frontend/src/lib/components/experience.svelte +++ b/frontend/src/lib/components/experience.svelte @@ -28,6 +28,7 @@

{position}

+ Experience

diff --git a/frontend/src/lib/components/projects.svelte b/frontend/src/lib/components/projects.svelte index b9372ac..ec334b9 100644 --- a/frontend/src/lib/components/projects.svelte +++ b/frontend/src/lib/components/projects.svelte @@ -21,10 +21,11 @@

- projects + Projects

{title}

+ Projects

diff --git a/frontend/src/lib/components/slideshow.svelte b/frontend/src/lib/components/slideshow.svelte index b207b09..e59f8db 100644 --- a/frontend/src/lib/components/slideshow.svelte +++ b/frontend/src/lib/components/slideshow.svelte @@ -20,13 +20,15 @@ data = data.reverse(); } + // Svelte bindings + let windowWidth = 0; + // Resizing variables let resizing = false; // Slideshow global variables let slideshow_index = 0; let slideshow_hidden = []; - let slideshowTimeline; let slideshowElements; let slideshowBubbles; @@ -34,6 +36,7 @@ // Timeline global variables let slideshow; let bubbles = []; + onMount(() => { /* Slideshow */ //global writer count @@ -80,7 +83,7 @@ // Incrementing the transformValue for each element let transformValue = 0; for (const id of slideshow_hidden) { - transformValue += slideshowElements[id].clientWidth; + transformValue += slideshowElements[id].clientWidth; } // Translating elements @@ -166,13 +169,13 @@ } - +