alpha
Login
or
Join now
flo-bit.dev
/
flo-bit.github.io
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
[READ-ONLY] Mirror of https://github.com/flo-bit/flo-bit.github.io. my personal website, w/ astro, svelte, tailwind, typescript, threlte
flo-bit.dev/
portfolio
portfolio-website
svelte
sveltekit
tailwind
threejs
threlte
typescript
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
Overview
Issues
Pulls
Pipelines
add articles section
author
Florian
date
2 years ago
(Jan 12, 2024, 1:04 AM +0100)
commit
fd8ff840
fd8ff84037b823846e8e9fd2cf49fc4318da267c
parent
32d6bab8
32d6bab890b232d0d2e11276d88e8248f1debada
+106
-6
6 changed files
Expand all
Collapse all
Unified
Split
src
app.css
lib
components
Posts.svelte
Projects.svelte
nav
DektopNavigation.svelte
MobileNavigation.svelte
routes
+page.svelte
+4
src/app.css
View file
Reviewed
···
19
19
scrollbar-width: none; /* Firefox */
20
20
}
21
21
}
22
22
+
23
23
+
/* * {
24
24
+
outline: red solid 1px;
25
25
+
} */
+83
src/lib/components/Posts.svelte
View file
Reviewed
···
1
1
+
<script lang="ts">
2
2
+
interface Article {
3
3
+
title: string;
4
4
+
description: string;
5
5
+
date: string;
6
6
+
href: string;
7
7
+
}
8
8
+
9
9
+
const articles: Article[] = [
10
10
+
{
11
11
+
title: 'How I use AI for Software Development',
12
12
+
description:
13
13
+
'I admit it, I have asked ChatGPT at least 17 times how to center a div!',
14
14
+
date: '2024-01-08',
15
15
+
href: 'https://flobit.substack.com/p/how-i-use-ai-for-software-development-474551a7aa7f'
16
16
+
}
17
17
+
];
18
18
+
19
19
+
function formatDate(date: string) {
20
20
+
return new Date(date).toLocaleDateString('en-US', {
21
21
+
year: 'numeric',
22
22
+
month: 'long',
23
23
+
day: 'numeric'
24
24
+
});
25
25
+
}
26
26
+
</script>
27
27
+
28
28
+
<div class="relative isolate overflow-hidden bg-black">
29
29
+
<div class="mx-auto max-w-5xl px-6 lg:px-8">
30
30
+
<div id="articles" class="py-16 md:py-32 section">
31
31
+
<div class="max-w-2xl">
32
32
+
<h1 class="text-4xl font-bold tracking-tight text-zinc-800 dark:text-zinc-100 sm:text-5xl">
33
33
+
My ramblings
34
34
+
</h1>
35
35
+
<p class="mt-6 text-base text-zinc-600 dark:text-zinc-400">
36
36
+
Here are some of my thoughts on things I'm learning or working on.
37
37
+
</p>
38
38
+
</div>
39
39
+
<div class="mt-16">
40
40
+
<div class="grid grid-cols-1 md:grid-cols-2 gap-16">
41
41
+
{#each articles as article}
42
42
+
<article class="">
43
43
+
<div class="group relative flex flex-col items-start">
44
44
+
<div
45
45
+
class="text-base z-10 font-semibold tracking-tight text-zinc-800 dark:text-zinc-100"
46
46
+
>
47
47
+
{article.title}
48
48
+
</div>
49
49
+
<div
50
50
+
class="relative z-10 order-first mb-3 flex items-center text-sm text-zinc-400 dark:text-zinc-500 pl-3.5 mt-1"
51
51
+
>
52
52
+
<span class="absolute inset-y-0 left-0 flex items-center" aria-hidden="true">
53
53
+
<span class="h-4 w-0.5 rounded-full bg-zinc-200 dark:bg-zinc-500" />
54
54
+
</span>
55
55
+
{formatDate(article.date)}
56
56
+
</div>
57
57
+
58
58
+
<p class="relative z-10 mt-2 text-sm text-zinc-600 dark:text-zinc-400">
59
59
+
{article.description}
60
60
+
</p>
61
61
+
62
62
+
<a href={article.href} target="_blank">
63
63
+
<div
64
64
+
class="absolute -inset-x-4 -inset-y-6 z-0 scale-95 bg-zinc-50 opacity-0 transition group-hover:scale-100 group-hover:opacity-100 dark:bg-zinc-800/50 sm:-inset-x-6 sm:rounded-2xl"
65
65
+
/>
66
66
+
<span class="absolute -inset-x-4 -inset-y-6 z-20 sm:-inset-x-6 sm:rounded-2xl" />
67
67
+
<span class="relative z-10 mt-4 flex items-center text-sm font-medium text-zinc-400 transition-colors duration-200 group-hover:text-cyan-400">
68
68
+
Read Article
69
69
+
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" class="w-3 h-3 ml-1 mt-0.5">
70
70
+
<path stroke-linecap="round" stroke-linejoin="round" d="m8.25 4.5 7.5 7.5-7.5 7.5" />
71
71
+
</svg>
72
72
+
73
73
+
</span>
74
74
+
75
75
+
</a>
76
76
+
</div>
77
77
+
</article>
78
78
+
{/each}
79
79
+
</div>
80
80
+
</div>
81
81
+
</div>
82
82
+
</div>
83
83
+
</div>
+1
-1
src/lib/components/Projects.svelte
View file
Reviewed
···
136
136
</div>
137
137
{#if project.link}
138
138
<p
139
139
-
class="relative z-10 mt-6 flex text-sm font-medium text-zinc-400 transition group-hover:text-cyan-500 dark:text-zinc-200"
139
139
+
class="relative z-10 mt-6 flex text-sm font-medium text-zinc-400 transition group-hover:text-cyan-400 dark:text-zinc-200"
140
140
>
141
141
<svg viewBox="0 0 24 24" aria-hidden="true" class="h-6 w-6 flex-none">
142
142
<path
+3
-2
src/lib/components/nav/DektopNavigation.svelte
View file
Reviewed
···
5
5
6
6
export { classes as class };
7
7
8
8
-
export let active: 'home' | 'about' | 'projects' | 'learning' | 'contact' = 'home';
8
8
+
export let active: 'home' | 'about' | 'projects' | 'learning' | 'contact' | 'articles' = 'home';
9
9
</script>
10
10
11
11
<nav class={classes}>
12
12
<ul
13
13
class="flex rounded-full bg-white/90 px-3 text-sm font-medium text-zinc-800 shadow-lg shadow-zinc-800/5 ring-1 ring-zinc-900/5 backdrop-blur dark:bg-white/5 dark:text-zinc-200 dark:ring-white/10"
14
14
>
15
15
-
<NavigationItem href="#home" isActive={active == 'home'}>Home</NavigationItem>
15
15
+
<!-- <NavigationItem href="#home" isActive={active == 'home'}>Home</NavigationItem> -->
16
16
<NavigationItem href="#about" isActive={active == 'about'}>About</NavigationItem>
17
17
<NavigationItem href="#projects" isActive={active == 'projects'}>Projects</NavigationItem>
18
18
+
<NavigationItem href="#articles" isActive={active == 'articles'}>Articles</NavigationItem>
18
19
<NavigationItem href="#learning" isActive={active == 'learning'}>Learning</NavigationItem>
19
20
<NavigationItem href="#contact" isActive={active == 'contact'}>Contact</NavigationItem>
20
21
</ul>
+12
-3
src/lib/components/nav/MobileNavigation.svelte
View file
Reviewed
···
17
17
open.set(false);
18
18
}
19
19
20
20
-
export let active: 'home' | 'about' | 'projects' | 'learning' | 'contact' = 'home';
20
20
+
export let active: 'home' | 'about' | 'projects' | 'learning' | 'contact' | 'articles' = 'home';
21
21
</script>
22
22
23
23
<button
···
64
64
<ul
65
65
class="-my-2 divide-y divide-white/10 text-base text-zinc-800 dark:divide-zinc-100/5 dark:text-zinc-100"
66
66
>
67
67
-
<li>
67
67
+
<!-- <li>
68
68
<a
69
69
href="#home"
70
70
class="block py-2 {active == 'home' ? 'dark:text-cyan-400' : ''}"
···
72
72
>
73
73
Home
74
74
</a>
75
75
-
</li>
75
75
+
</li> -->
76
76
<li>
77
77
<a
78
78
href="#about"
···
89
89
on:click={hide}
90
90
>
91
91
Projects
92
92
+
</a>
93
93
+
</li>
94
94
+
<li>
95
95
+
<a
96
96
+
href="#articles"
97
97
+
class="block py-2 {active == 'articles' ? 'dark:text-cyan-400' : ''}"
98
98
+
on:click={hide}
99
99
+
>
100
100
+
Articles
92
101
</a>
93
102
</li>
94
103
<li>
+3
src/routes/+page.svelte
View file
Reviewed
···
13
13
import Footer from '$lib/components/Footer.svelte';
14
14
import About from '$lib/components/About.svelte';
15
15
import Learning from '$lib/components/Learning.svelte';
16
16
+
import Posts from '$lib/components/Posts.svelte';
16
17
17
18
let active: 'home' | 'about' | 'projects' | 'learning' | 'contact' = 'home';
18
19
···
60
61
<About />
61
62
62
63
<Projects />
64
64
+
65
65
+
<Posts />
63
66
64
67
<Learning />
65
68