fix: style
This commit is contained in:
@@ -6,7 +6,7 @@
|
|||||||
|
|
||||||
## 👂 Languages/Framework/Packages:
|
## 👂 Languages/Framework/Packages:
|
||||||
|
|
||||||
- Angular v19
|
- Angular v21
|
||||||
- TypeScript
|
- TypeScript
|
||||||
- SCSS
|
- SCSS
|
||||||
|
|
||||||
|
|||||||
@@ -390,12 +390,17 @@ export class HomeComponent implements OnInit, AfterViewInit, OnDestroy {
|
|||||||
portfolioEyebrow === null
|
portfolioEyebrow === null
|
||||||
? Number.POSITIVE_INFINITY
|
? Number.POSITIVE_INFINITY
|
||||||
: portfolioEyebrow.getBoundingClientRect().top + window.scrollY;
|
: portfolioEyebrow.getBoundingClientRect().top + window.scrollY;
|
||||||
|
const isMobileViewport: boolean = window.innerWidth <= 700;
|
||||||
const triggerDistance: number = Math.max(portfolioTriggerY, 1);
|
const mobileRevealDistance: number = Math.max(window.innerHeight * 0.38, 180);
|
||||||
|
const triggerDistance: number = isMobileViewport
|
||||||
|
? mobileRevealDistance
|
||||||
|
: Math.max(portfolioTriggerY, 1);
|
||||||
const rawProgress: number = Math.min(window.scrollY / triggerDistance, 1);
|
const rawProgress: number = Math.min(window.scrollY / triggerDistance, 1);
|
||||||
const acceleratedProgress: number = Math.pow(rawProgress, 0.66);
|
const acceleratedProgress: number = Math.pow(rawProgress, isMobileViewport ? 0.62 : 0.66);
|
||||||
const progress: number =
|
const progress: number =
|
||||||
window.scrollY > 0 ? Math.max(acceleratedProgress, 0.05) : acceleratedProgress;
|
window.scrollY > 0
|
||||||
|
? Math.max(acceleratedProgress, isMobileViewport ? 0.06 : 0.05)
|
||||||
|
: acceleratedProgress;
|
||||||
|
|
||||||
root.style.setProperty('--name-pride-progress', progress.toFixed(4));
|
root.style.setProperty('--name-pride-progress', progress.toFixed(4));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -10,5 +10,15 @@
|
|||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<app-root></app-root>
|
<app-root></app-root>
|
||||||
|
|
||||||
|
<script src="https://storage.ko-fi.com/cdn/scripts/overlay-widget.js"></script>
|
||||||
|
<script>
|
||||||
|
kofiWidgetOverlay.draw('fraujulian', {
|
||||||
|
type: 'floating-chat',
|
||||||
|
'floating-chat.donateButton.text': 'Tip me',
|
||||||
|
'floating-chat.donateButton.background-color': '#ff5f5f',
|
||||||
|
'floating-chat.donateButton.text-color': '#fff',
|
||||||
|
});
|
||||||
|
</script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
+9
-2
@@ -164,7 +164,8 @@ hr {
|
|||||||
#004dff 83.33%,
|
#004dff 83.33%,
|
||||||
#750787 83.33%,
|
#750787 83.33%,
|
||||||
#750787 100%
|
#750787 100%
|
||||||
) no-repeat 0 50%;
|
)
|
||||||
|
no-repeat 0 50%;
|
||||||
-webkit-background-clip: text;
|
-webkit-background-clip: text;
|
||||||
background-clip: text;
|
background-clip: text;
|
||||||
-webkit-text-fill-color: transparent;
|
-webkit-text-fill-color: transparent;
|
||||||
@@ -309,7 +310,8 @@ hr {
|
|||||||
#004dff 83.33%,
|
#004dff 83.33%,
|
||||||
#750787 83.33%,
|
#750787 83.33%,
|
||||||
#750787 100%
|
#750787 100%
|
||||||
) 0 50%;
|
)
|
||||||
|
0 50%;
|
||||||
transform: translate(2px, 2px);
|
transform: translate(2px, 2px);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -972,6 +974,11 @@ hr {
|
|||||||
max-width: none;
|
max-width: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.hero-copy h1 {
|
||||||
|
font-size: clamp(3.35rem, 13vw, 4.75rem);
|
||||||
|
line-height: 0.96;
|
||||||
|
}
|
||||||
|
|
||||||
.hero-copy {
|
.hero-copy {
|
||||||
display: contents;
|
display: contents;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user