Feat: portfolio polish + font Danzza Light
- App.svelte : classe active sur la slide courante - Portfolio : flèches PNG custom, <output> pour le compteur, transition gallery mobile avec délai à l'entrée seulement - fonts.css : @font-face Danzza Light + classe .font-face-danzza-light corrigée Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
77080c4928
commit
e45380258b
4 changed files with 43 additions and 15 deletions
BIN
assets/fonts/Danzza Light.otf
Normal file
BIN
assets/fonts/Danzza Light.otf
Normal file
Binary file not shown.
|
|
@ -83,8 +83,8 @@
|
||||||
class:is-animated={isReady && !isResizing}
|
class:is-animated={isReady && !isResizing}
|
||||||
style="width: {wrapperWidth}; transform: {wrapperTransform}"
|
style="width: {wrapperWidth}; transform: {wrapperTransform}"
|
||||||
>
|
>
|
||||||
{#each slides.all as slide}
|
{#each slides.all as slide, i}
|
||||||
<section class="slide" data-slide={slide.id}>
|
<section class="slide" class:active={i === slides.activeIndex} data-slide={slide.id}>
|
||||||
{#if slide.loaded}
|
{#if slide.loaded}
|
||||||
<svelte:component
|
<svelte:component
|
||||||
this={templates[slide.template] ?? Default}
|
this={templates[slide.template] ?? Default}
|
||||||
|
|
|
||||||
|
|
@ -20,6 +20,13 @@
|
||||||
font-display: swap;
|
font-display: swap;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@font-face {
|
||||||
|
font-family: "Danzza Light";
|
||||||
|
src: local("Danzza Light"),
|
||||||
|
url("/assets/fonts/Danzza%20Light.otf") format("opentype");
|
||||||
|
font-display: swap;
|
||||||
|
}
|
||||||
|
|
||||||
@font-face {
|
@font-face {
|
||||||
font-family: "Danzza Bold";
|
font-family: "Danzza Bold";
|
||||||
src: local("Danzza Bold"),
|
src: local("Danzza Bold"),
|
||||||
|
|
@ -36,9 +43,8 @@
|
||||||
font-family: "Danzza";
|
font-family: "Danzza";
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Danzza Light n'existe pas — pointe vers Regular */
|
|
||||||
.font-face-danzza-light {
|
.font-face-danzza-light {
|
||||||
font-family: "Danzza";
|
font-family: "Danzza Light";
|
||||||
}
|
}
|
||||||
|
|
||||||
.font-face-danzza-medium {
|
.font-face-danzza-medium {
|
||||||
|
|
|
||||||
|
|
@ -174,7 +174,7 @@
|
||||||
disabled={currentIndex >= projects.length - 1}
|
disabled={currentIndex >= projects.length - 1}
|
||||||
onclick={() => { if (currentIndex < projects.length - 1) { currentIndex++; setAnchor(currentIndex) } }}
|
onclick={() => { if (currentIndex < projects.length - 1) { currentIndex++; setAnchor(currentIndex) } }}
|
||||||
></button>
|
></button>
|
||||||
<span class="portfolio-counter">{String(currentIndex + 1).padStart(2, '0')}/{String(projects.length).padStart(2, '0')}</span>
|
<output class="portfolio-counter">{String(currentIndex + 1).padStart(2, '0')}/{String(projects.length).padStart(2, '0')}</output>
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
|
|
@ -270,7 +270,7 @@
|
||||||
|
|
||||||
.portfolio-nav {
|
.portfolio-nav {
|
||||||
grid-area: 4/17 / span 14 / span 4;
|
grid-area: 4/17 / span 14 / span 4;
|
||||||
padding-right: 8rem;
|
margin-right: 7vw;
|
||||||
z-index: var(--z-content);
|
z-index: var(--z-content);
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
|
@ -350,12 +350,13 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-arrow--up {
|
.portfolio-arrow--up {
|
||||||
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' fill='none' stroke='white' stroke-width='2'%3E%3Cpath d='M2 8L6 4L10 8'/%3E%3C/svg%3E");
|
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAARCAYAAAAL4VbbAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAACxSURBVChT7dExDgFBFMbxF4RKolC5ABGRuIIjqJQu4ATiDE6hcQKNhsJGi4YLqBQ6jfF/k53Js8YNfMkvb9/Mm8lmV5xzRTVsMDZrXkm+U8EQA9/ZFE7PYHND3Lc3T9DC1nciVxyg611dCKfq0EyhvWaE8LyAv3mFB/pYogFNO689dPDS4Qt2OOKOKjShnrHGPryG1YRmjo+91Kf7mf+wTWq4nNfwJ2NSw09kOPkuRuQNVDyfOxATXhEAAAAASUVORK5CYII=");
|
||||||
|
transform: rotate(180deg);
|
||||||
margin-right: 2px;
|
margin-right: 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-arrow--down {
|
.portfolio-arrow--down {
|
||||||
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' fill='none' stroke='white' stroke-width='2'%3E%3Cpath d='M2 4L6 8L10 4'/%3E%3C/svg%3E");
|
background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAsAAAARCAYAAAAL4VbbAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAACxSURBVChT7dExDgFBFMbxF4RKolC5ABGRuIIjqJQu4ATiDE6hcQKNhsJGi4YLqBQ6jfF/k53Js8YNfMkvb9/Mm8lmV5xzRTVsMDZrXkm+U8EQA9/ZFE7PYHND3Lc3T9DC1nciVxyg611dCKfq0EyhvWaE8LyAv3mFB/pYogFNO689dPDS4Qt2OOKOKjShnrHGPryG1YRmjo+91Kf7mf+wTWq4nNfwJ2NSw09kOPkuRuQNVDyfOxATXhEAAAAASUVORK5CYII=");
|
||||||
margin-right: 5px;
|
margin-right: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -371,17 +372,24 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Gallery over background, under content */
|
/* Gallery over background, under content */
|
||||||
.portfolio-gallery {
|
.portfolio-gallery.mobile-only {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
transform: translateX(-10vw);
|
|
||||||
width: 120vw;
|
|
||||||
opacity: 0.8;
|
opacity: 0.8;
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
|
transform: translateX(0vw);
|
||||||
|
width: 100vw;
|
||||||
|
transition: all .3s ease-in-out;
|
||||||
|
}
|
||||||
|
|
||||||
|
:global(.slide.active .portfolio-gallery.mobile-only) {
|
||||||
|
transform: translateX(-10vw);
|
||||||
|
width: 120vw;
|
||||||
|
transition: all .3s ease-in-out .8s;
|
||||||
}
|
}
|
||||||
|
|
||||||
.content-background {
|
.content-background {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: -7rem;
|
bottom: 0;
|
||||||
width: 100vw;
|
width: 100vw;
|
||||||
height: auto;
|
height: auto;
|
||||||
z-index: 5;
|
z-index: 5;
|
||||||
|
|
@ -399,8 +407,9 @@
|
||||||
|
|
||||||
/* Text — over mockup, centered */
|
/* Text — over mockup, centered */
|
||||||
.portfolio-text {
|
.portfolio-text {
|
||||||
grid-area: 9/3 / span 7 / span 16;
|
grid-area: 8/4/span 8/span 14;
|
||||||
z-index: var(--z-content);
|
z-index: var(--z-content);
|
||||||
|
gap: .5rem;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -414,7 +423,10 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-description {
|
.portfolio-description {
|
||||||
|
font-family: "Danzza Light", sans-serif;
|
||||||
font-size: var(--font-size-paragraph-mobile);
|
font-size: var(--font-size-paragraph-mobile);
|
||||||
|
font-weight: 600;
|
||||||
|
line-height: 1.34;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Hide keywords on mobile */
|
/* Hide keywords on mobile */
|
||||||
|
|
@ -422,6 +434,11 @@
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.portfolio-links {
|
||||||
|
margin-top: .5rem;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
/* Nav thumbnails — horizontal, compact */
|
/* Nav thumbnails — horizontal, compact */
|
||||||
.portfolio-nav {
|
.portfolio-nav {
|
||||||
grid-area: 17/4 / span 1 / span 14;
|
grid-area: 17/4 / span 1 / span 14;
|
||||||
|
|
@ -431,6 +448,7 @@
|
||||||
height: 75px;
|
height: 75px;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
margin-right: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-nav-item:not(:last-child) {
|
.portfolio-nav-item:not(:last-child) {
|
||||||
|
|
@ -451,8 +469,8 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-nav-item img {
|
.portfolio-nav-item img {
|
||||||
width: 45px;
|
width: 3.75rem;
|
||||||
height: 50px;
|
height: 3.75rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.portfolio-nav-number {
|
.portfolio-nav-number {
|
||||||
|
|
@ -464,6 +482,10 @@
|
||||||
grid-area: 18/15 / span 1 / span 3;
|
grid-area: 18/15 / span 1 / span 3;
|
||||||
font-size: var(--font-size-caption-mobile, 11px);
|
font-size: var(--font-size-caption-mobile, 11px);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.portfolio-counter {
|
||||||
|
font-size: 0.8125rem;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Tablet (701px–912px) */
|
/* Tablet (701px–912px) */
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue