Skip to content

Commit f6325fa

Browse files
bugfix: upgrade issues with animations
1 parent 03b9b54 commit f6325fa

File tree

12 files changed

+436
-426
lines changed

12 files changed

+436
-426
lines changed

package.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,17 @@
1313
"prepare": "husky"
1414
},
1515
"dependencies": {
16-
"@sentry/sveltekit": "^10.22.0",
16+
"@sentry/sveltekit": "^10.24.0",
1717
"gray-matter": "^4.0.3",
1818
"mdsvex": "^0.12.6"
1919
},
2020
"devDependencies": {
21-
"@eslint/js": "^9.39.0",
21+
"@eslint/js": "^9.39.1",
2222
"@sveltejs/adapter-node": "^5.4.0",
2323
"@sveltejs/kit": "^2.48.4",
2424
"@sveltejs/vite-plugin-svelte": "^6.2.1",
2525
"@types/node": "^24.10.0",
26-
"eslint": "^9.39.0",
26+
"eslint": "^9.39.1",
2727
"eslint-config-prettier": "^10.1.8",
2828
"eslint-plugin-svelte": "^3.13.0",
2929
"globals": "^16.5.0",
@@ -32,11 +32,11 @@
3232
"prettier": "^3.6.2",
3333
"prettier-plugin-svelte": "^3.4.0",
3434
"sass": "^1.93.3",
35-
"svelte": "^5.43.2",
35+
"svelte": "^5.43.5",
3636
"svelte-check": "^4.3.3",
3737
"typescript": "^5.9.3",
38-
"typescript-eslint": "^8.46.2",
39-
"vite": "^7.1.12"
38+
"typescript-eslint": "^8.46.3",
39+
"vite": "^7.2.2"
4040
},
4141
"lint-staged": {
4242
"*": [

pnpm-lock.yaml

Lines changed: 385 additions & 385 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/lib/components/analytics.svelte

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
<script lang="ts">
22
import { browser } from '$app/environment';
3+
import { resolve } from '$app/paths';
34
import { PUBLIC_GA4_ID } from '$env/static/public';
45
56
// locally store if a user has allowed the usage of cookies
@@ -45,8 +46,8 @@
4546
<div class="container">
4647
<span>Cookie notice</span>
4748
<p>
48-
This website uses cookies to improve your user experience. By using our website, you consent to all cookies in accordance with our <a href="/privacy-policy"
49-
>privacy policy</a
49+
This website uses cookies to improve your user experience. By using our website, you consent to all cookies in accordance with our <a
50+
href={resolve('/privacy-policy')}>privacy policy</a
5051
>.
5152
</p>
5253
<div class="buttons">
@@ -101,7 +102,7 @@
101102
cursor: pointer;
102103
transition:
103104
background-color $animation-duration-default ease-in-out,
104-
color $animation-duration-default ease-in-out;
105+
color $animation-duration-default ease-in-out !important;
105106
106107
&:hover {
107108
color: $color-brand-primary;

src/lib/layout/footer.svelte

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,19 @@
1+
<script lang="ts">
2+
import { resolve } from '$app/paths';
3+
</script>
4+
15
<footer>
26
<div class="container">
37
<div class="info">
48
<span class="name"><b>tukkr</b></span>
59
<span><a href="mailto:info@tukkr.dev">info@tukkr.dev</a></span>
6-
<span><a href="/contact">Contact</a></span>
10+
<span><a href={resolve('/contact')}>Contact</a></span>
711
</div>
812
<nav aria-label="Footer menu">
9-
<a href="/">Home</a>
10-
<a href="/about">About</a>
11-
<a href="/snippets">Snippets</a>
12-
<a href="/contact">Contact</a>
13+
<a href={resolve('/')}>Home</a>
14+
<a href={resolve('/about')}>About</a>
15+
<a href={resolve('/snippets')}>Snippets</a>
16+
<a href={resolve('/contact')}>Contact</a>
1317
</nav>
1418
<div class="socials">
1519
<a href="https://www.linkedin.com/in/jeffrey-boesenkool/" target="_blank" rel="noopener">LinkedIn</a>

src/lib/layout/header.svelte

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,13 @@
11
<script lang="ts">
2+
import { resolve } from '$app/paths';
23
import { page } from '$app/state';
34
45
// verify the current url pathname equals the menu href
56
let isCurrentPage = (path: string): boolean => page.url.pathname.split('/')[1] === path;
67
78
// check the scroll state to decrease the header padding
89
let scrollY: number = $state(0);
9-
let scrollOffsetClass = (): string | null => (scrollY > 1 ? 'scrolled' : null);
10+
let isScrolled = $derived(scrollY > 1);
1011
1112
// toggle mobile menu state
1213
let mobileMenuActive: boolean = $state(false);
@@ -28,9 +29,9 @@
2829

2930
<svelte:window bind:scrollY bind:innerWidth />
3031

31-
<header class={scrollOffsetClass()}>
32+
<header class:scrolled={isScrolled}>
3233
<div class="logo">
33-
<a href="/">
34+
<a href={resolve('/')}>
3435
<img alt="tukkr logo" height="42" width="42" src="/logo.svg" />
3536
</a>
3637
</div>
@@ -42,10 +43,10 @@
4243
</svg>
4344
</button>
4445
<nav aria-label="Main menu" class:active={mobileMenuActive} id="main-menu">
45-
<a class:active={isCurrentPage('')} href="/">Home</a>
46-
<a class:active={isCurrentPage('about')} href="/about">About</a>
47-
<a class:active={isCurrentPage('snippets')} href="/snippets">Snippets</a>
48-
<a class:active={isCurrentPage('contact')} href="/contact">Contact</a>
46+
<a class:active={isCurrentPage('')} href={resolve('/')}>Home</a>
47+
<a class:active={isCurrentPage('about')} href={resolve('/about')}>About</a>
48+
<a class:active={isCurrentPage('snippets')} href={resolve('/snippets')}>Snippets</a>
49+
<a class:active={isCurrentPage('contact')} href={resolve('/contact')}>Contact</a>
4950
</nav>
5051
</header>
5152

@@ -61,7 +62,7 @@
6162
will-change: padding;
6263
padding: 1.8rem 2rem;
6364
background-color: rgba(255, 255, 255, 0.94);
64-
transition: padding 0.2s ease-in-out;
65+
transition: padding 0.2s ease-in-out !important;
6566
z-index: 999;
6667
6768
// change padding if window is scrolled
@@ -86,7 +87,7 @@
8687
will-change: transform, stroke-dashoffset;
8788
transition:
8889
transform $animation-duration-slow ease-in-out,
89-
stroke-dashoffset $animation-duration-slow ease-in-out;
90+
stroke-dashoffset $animation-duration-slow ease-in-out !important;
9091
9192
path {
9293
fill: none;
@@ -128,7 +129,7 @@
128129
margin-top: 0;
129130
transition:
130131
height $animation-duration-slow ease-in-out,
131-
margin-top $animation-duration-slow ease-in-out;
132+
margin-top $animation-duration-slow ease-in-out !important;
132133
133134
&.active {
134135
// note: height must be a fixed value for transition to work properly
@@ -144,7 +145,7 @@
144145
margin-top: 0 !important;
145146
146147
// disable transition to prevent weird rescaling animations
147-
transition: none;
148+
transition: none !important;
148149
}
149150
150151
a {

src/routes/+page.svelte

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<script lang="ts">
2+
import { resolve } from '$app/paths';
23
import SEO from '$lib/components/seo.svelte';
34
</script>
45

@@ -8,15 +9,15 @@
89
<h1>tukkr</h1>
910
<p>Hey! I am Jeffrey, a Fullstack Web Developer from The Netherlands.</p>
1011
<div class="page-actions">
11-
<a href="/about" class="about">
12+
<a href={resolve('/about')} class="about">
1213
<h2>About me</h2>
1314
<p>Read more about me and my past experiences.</p>
1415
</a>
15-
<a href="/snippets" class="snippets">
16+
<a href={resolve('/snippets')} class="snippets">
1617
<h2>Snippets</h2>
1718
<p>The place where I store some cool snippets / knowledge.</p>
1819
</a>
19-
<a href="/contact" class="contact">
20+
<a href={resolve('/contact')} class="contact">
2021
<h2>Get in touch</h2>
2122
<p>In for a friendly chat? Contact me directly!</p>
2223
</a>
@@ -41,7 +42,7 @@
4142
padding: 1rem;
4243
border: 1px solid $color-border-primary;
4344
border-radius: 16px;
44-
transition: border-color $animation-duration-default ease-in-out;
45+
transition: border-color $animation-duration-default ease-in-out !important;
4546
4647
@include mediaQuery(s) {
4748
width: calc((100% - 2rem) / 2);

src/routes/about/+page.svelte

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<script lang="ts">
2+
import { resolve } from '$app/paths';
23
import SEO from '$lib/components/seo.svelte';
34
45
// calculate my age in years
@@ -40,8 +41,9 @@
4041
<li><b>Hosting:</b> Debian and RHEL based distributions, Plesk, DirectAdmin, WHM.</li>
4142
</ul>
4243
<p>
43-
Please note that these are only the technologies I am most confident in, I have worked with other stacks and technologies so feel free to <a href="/contact">reach out</a> to
44-
me for a friendly chat!
44+
Please note that these are only the technologies I am most confident in, I have worked with other stacks and technologies so feel free to <a href={resolve('/contact')}
45+
>reach out</a
46+
> to me for a friendly chat!
4547
</p>
4648
</div>
4749

src/routes/snippets/+page.svelte

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<script lang="ts">
2+
import { resolve } from '$app/paths';
23
import SEO from '$lib/components/seo.svelte';
34
import type { PageData } from './$types';
45
@@ -12,7 +13,8 @@
1213
<p>While I'm not big on blog writing, I do occasionally come across some neat pieces of code or specific knowledge which I find worth sharing - <i>or storing</i>.</p>
1314
<div class="posts">
1415
{#each data.posts as post (post.date)}
15-
<a href={'/snippets/' + post.slug} class="post>">
16+
<!-- eslint-disable-next-line @typescript-eslint/no-explicit-any -->
17+
<a href={resolve(('/snippets/' + post.slug) as any)} class="post">
1618
<div class="title">
1719
<h2>{post.title}</h2>
1820
<span>{post.date.toLocaleDateString('en-GB')}</span>
@@ -34,7 +36,7 @@
3436
padding: 1rem;
3537
border: 1px solid $color-border-primary;
3638
border-radius: 16px;
37-
transition: border-color $animation-duration-default ease-in-out;
39+
transition: border-color $animation-duration-default ease-in-out !important;
3840
3941
&:hover {
4042
border-color: $color-border-dark;

src/routes/snippets/[...path]/+page.server.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export const load: ServerLoad = async ({ url }): Promise<{ post: SnippetI }> =>
1515
};
1616
};
1717

18-
const highlighter = (code: string, lang?: string): string => {
18+
const highlighter = (code: string, lang?: string | null): string => {
1919
const className: string = 'language-' + lang;
2020

2121
return `<pre><code class=${className}>${code}</code></pre>`;

src/scss/_mixins.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
border-radius: 1px;
3636
background-color: $color-brand-primary;
3737
transform: scaleX(0);
38-
transition: transform $animation-duration-default ease-in-out;
38+
transition: transform $animation-duration-default ease-in-out !important;
3939
}
4040

4141
&:hover::before {

0 commit comments

Comments
 (0)