tangled
alpha
login
or
join now
vt3e.cat
/
www
2
fork
atom
this repo has no descr,ription
vt3e.cat
2
fork
atom
overview
issues
pulls
pipelines
feat: uses page
vt3e.cat
2 months ago
fab1c6e8
0229495b
verified
This commit was signed with the committer's
known signature
.
vt3e.cat
SSH Key Fingerprint:
SHA256:bC12nO0d6wKnJ426YBbLO7LVxmZlwJ1l2X0eqOroDV0=
+224
-4
2 changed files
expand all
collapse all
unified
split
pkgs
web
src
router
index.ts
views
UsesView.vue
+5
-4
pkgs/web/src/router/index.ts
···
11
11
12
12
const HomeView = () => import('../views/HomeView.vue')
13
13
const ProjectsView = () => import('../views/ProjectsView.vue')
14
14
+
const UsesView = () => import('../views/UsesView.vue')
14
15
const AboutView = () => import('../views/AboutView.vue')
15
16
16
17
declare module 'vue-router' {
···
100
101
component: AboutView,
101
102
meta: {
102
103
title: 'about',
103
103
-
bg: AccentColour.Teal
104
104
+
bg: AccentColour.Rosewater
104
105
}
105
106
},
106
107
{
···
118
119
{
119
120
path: '/uses',
120
121
name: 'uses',
121
121
-
component: ProjectsView,
122
122
+
component: UsesView,
122
123
meta: {
123
124
isCard: true,
124
125
title: '/uses',
125
126
icon: IconLaptopWindowsOutlineRounded(),
126
127
gridArea: 'area-uses',
127
127
-
bg: AccentColour.Mauve
128
128
+
bg: AccentColour.Sky
128
129
}
129
130
},
130
131
{
···
136
137
title: 'gallery',
137
138
icon: IconAutoAwesomeMosaicOutline(),
138
139
gridArea: 'area-gallery',
139
139
-
bg: AccentColour.Sapphire
140
140
+
bg: AccentColour.Lavender
140
141
}
141
142
}
142
143
],
+219
pkgs/web/src/views/UsesView.vue
···
1
1
+
<script setup lang="ts">
2
2
+
import CardLayout from '@/components/Card/CardLayout.vue'
3
3
+
4
4
+
interface UseItem {
5
5
+
label: string
6
6
+
value: string
7
7
+
subtext?: string
8
8
+
link?: string
9
9
+
}
10
10
+
11
11
+
interface UseSection {
12
12
+
title: string
13
13
+
purpose?: string
14
14
+
description?: string
15
15
+
category?: 'hardware' | 'software'
16
16
+
items: UseItem[]
17
17
+
}
18
18
+
19
19
+
const useSections: UseSection[] = [
20
20
+
{
21
21
+
title: 'dahlia',
22
22
+
description: 'my main daily driver desktop computer',
23
23
+
category: 'hardware',
24
24
+
items: [
25
25
+
{ label: 'purpose', value: 'desktop' },
26
26
+
{ label: 'operating system', value: 'nixos 25.05' },
27
27
+
{ label: 'ram', value: '16gb' },
28
28
+
{ label: 'cpu', value: 'intel core i5-3470' },
29
29
+
{ label: 'gpu', value: 'rx 6400' },
30
30
+
],
31
31
+
},
32
32
+
{
33
33
+
title: 'ivy',
34
34
+
description: 'my home server',
35
35
+
category: 'hardware',
36
36
+
items: [
37
37
+
{ label: 'purpose', value: 'server' },
38
38
+
{ label: 'operating system', value: 'nixos 25.05' },
39
39
+
{ label: 'model', value: 'hp proliant dl360 g9' },
40
40
+
{ label: 'ram', value: '48gb' },
41
41
+
{ label: 'cpu', value: 'intel xeon e5-2620 v4 x2' },
42
42
+
],
43
43
+
},
44
44
+
{
45
45
+
title: 'azalea',
46
46
+
description:
47
47
+
"my [deprecated] home server that used to host my pds and website before ivy took over, it's now used for miscellaneous tasks",
48
48
+
category: 'hardware',
49
49
+
items: [
50
50
+
{ label: 'purpose', value: 'server' },
51
51
+
{ label: 'operating system', value: 'nixos 25.05' },
52
52
+
{ label: 'model', value: 'raspberry pi 4b' },
53
53
+
{ label: 'ram', value: '8gb' },
54
54
+
{ label: 'cpu', value: 'cortex-a72' },
55
55
+
],
56
56
+
},
57
57
+
{
58
58
+
title: 'phone',
59
59
+
description: 'my daily driver phone',
60
60
+
category: 'hardware',
61
61
+
items: [
62
62
+
{ label: 'model', value: 'pixel 9a', subtext: 'google' },
63
63
+
{ label: 'os', value: 'android 16' },
64
64
+
],
65
65
+
},
66
66
+
]
67
67
+
</script>
68
68
+
69
69
+
<template>
70
70
+
<CardLayout title="placeholder!">
71
71
+
<div class="uses-sections">
72
72
+
<section v-for="section in useSections" :key="section.title" class="uses-section">
73
73
+
<div class="section-header">
74
74
+
<div class="title-group">
75
75
+
<span class="badge">{{ section.category }}</span>
76
76
+
<h2 class="section-title">{{ section.title }}</h2>
77
77
+
</div>
78
78
+
<p class="section-description">
79
79
+
{{ section.description }}
80
80
+
</p>
81
81
+
</div>
82
82
+
83
83
+
<table class="uses-table">
84
84
+
<tbody>
85
85
+
<tr v-for="item in section.items" :key="item.label" class="item-row">
86
86
+
<td class="item-label">{{ item.label }}</td>
87
87
+
<td class="item-value">
88
88
+
<span v-if="item.link">
89
89
+
<a :href="item.link" target="_blank" rel="noopener noreferrer">
90
90
+
{{ item.value }}
91
91
+
</a>
92
92
+
</span>
93
93
+
<span v-else>{{ item.value }}</span>
94
94
+
<span v-if="item.subtext" class="item-subtext">
95
95
+
{{ item.subtext }}
96
96
+
</span>
97
97
+
</td>
98
98
+
</tr>
99
99
+
</tbody>
100
100
+
</table>
101
101
+
</section>
102
102
+
</div>
103
103
+
</CardLayout>
104
104
+
</template>
105
105
+
106
106
+
<style lang="scss" scoped>
107
107
+
.uses-sections {
108
108
+
display: flex;
109
109
+
flex-direction: column;
110
110
+
gap: 0.25rem;
111
111
+
}
112
112
+
113
113
+
.uses-section {
114
114
+
display: grid;
115
115
+
grid-template-columns: 40% 60%;
116
116
+
overflow: hidden;
117
117
+
background-color: hsla(var(--surface0) / 1);
118
118
+
padding: 0.5rem;
119
119
+
120
120
+
border-radius: 0.5rem;
121
121
+
&:first-child {
122
122
+
border-radius: 1rem 1rem 0.5rem 0.5rem;
123
123
+
}
124
124
+
&:last-child {
125
125
+
border-radius: 0.5rem 0.5rem 1rem 1rem;
126
126
+
}
127
127
+
128
128
+
.section-header {
129
129
+
.title-group {
130
130
+
display: flex;
131
131
+
flex-direction: column;
132
132
+
133
133
+
span.badge {
134
134
+
align-self: flex-start;
135
135
+
background-color: hsla(var(--accent) / 0.1);
136
136
+
color: hsl(var(--accent));
137
137
+
padding: 0.25rem 0.5rem;
138
138
+
font-size: 0.75rem;
139
139
+
font-weight: 700;
140
140
+
border-radius: 5rem;
141
141
+
user-select: none;
142
142
+
}
143
143
+
144
144
+
h2.section-title {
145
145
+
font-size: 2rem;
146
146
+
font-weight: 900;
147
147
+
}
148
148
+
}
149
149
+
.section-description {
150
150
+
font-size: 1rem;
151
151
+
color: hsl(var(--subtext1));
152
152
+
}
153
153
+
}
154
154
+
155
155
+
@media (max-width: 800px) {
156
156
+
border-radius: 0;
157
157
+
grid-template-columns: 1fr;
158
158
+
gap: 1rem;
159
159
+
}
160
160
+
161
161
+
.uses-table {
162
162
+
width: 100%;
163
163
+
border-collapse: separate;
164
164
+
border-spacing: 0;
165
165
+
overflow: hidden;
166
166
+
table-layout: fixed;
167
167
+
background-color: hsla(var(--surface0) / 0.1);
168
168
+
border-radius: 0.5rem;
169
169
+
border: 1px solid hsla(var(--overlay1) / 0.25);
170
170
+
171
171
+
* {
172
172
+
transition: none;
173
173
+
}
174
174
+
175
175
+
th:first-child,
176
176
+
td:first-child {
177
177
+
width: 40%;
178
178
+
}
179
179
+
180
180
+
th:last-child,
181
181
+
td:last-child {
182
182
+
width: 60%;
183
183
+
}
184
184
+
185
185
+
td {
186
186
+
padding: 0.75rem;
187
187
+
color: hsl(var(--text));
188
188
+
font-size: 1rem;
189
189
+
font-weight: 500;
190
190
+
191
191
+
.item-subtext {
192
192
+
display: block;
193
193
+
font-size: 0.8rem;
194
194
+
color: hsl(var(--subtext0));
195
195
+
font-weight: normal;
196
196
+
margin-top: 0.15rem;
197
197
+
}
198
198
+
}
199
199
+
200
200
+
tbody {
201
201
+
tr {
202
202
+
--opacity: 0.2;
203
203
+
background-color: hsla(var(--overlay0) / 0.15);
204
204
+
&:nth-child(even) {
205
205
+
--opacity: 0.15;
206
206
+
background-color: hsla(var(--overlay0) / 0.05);
207
207
+
}
208
208
+
&:hover {
209
209
+
background-color: hsla(var(--overlay1) / var(--opacity));
210
210
+
}
211
211
+
}
212
212
+
213
213
+
tr:last-child td {
214
214
+
border-bottom: none;
215
215
+
}
216
216
+
}
217
217
+
}
218
218
+
}
219
219
+
</style>