Skip to content

Commit 04acd6d

Browse files
authored
Merge branch 'main' into feat/atproto-blog-fe
2 parents 78beae7 + 39ebe2c commit 04acd6d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+1860
-546
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ jobs:
8484
run: pnpm install
8585

8686
- name: 🧪 Unit tests
87-
run: pnpm test:unit run --coverage --reporter=junit --outputFile=test-report.junit.xml
87+
run: pnpm test:unit run --coverage --reporter=default --reporter=junit --outputFile=test-report.junit.xml
8888

8989
- name: ⬆︎ Upload test results to Codecov
9090
if: ${{ !cancelled() }}
@@ -115,7 +115,7 @@ jobs:
115115
run: pnpm playwright install chromium-headless-shell
116116

117117
- name: 🧪 Component tests
118-
run: pnpm test:nuxt run --coverage --reporter=junit --outputFile=test-report.junit.xml
118+
run: pnpm test:nuxt run --coverage --reporter=default --reporter=junit --outputFile=test-report.junit.xml
119119

120120
- name: ⬆︎ Upload coverage reports to Codecov
121121
uses: codecov/codecov-action@671740ac38dd9b0130fbe1cec585b89eea48d3de # v5

app/assets/main.css

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -193,11 +193,11 @@
193193
*/
194194

195195
html {
196+
@apply scroll-pt-20;
196197
-webkit-font-smoothing: antialiased;
197198
-moz-osx-font-smoothing: grayscale;
198199
text-rendering: optimizeLegibility;
199200
/* Offset for fixed header - otherwise anchor headers are cutted */
200-
scroll-padding-top: 5rem;
201201
scrollbar-gutter: stable;
202202
}
203203

@@ -237,11 +237,6 @@ dd {
237237
margin: 0;
238238
}
239239

240-
/* Reset button styles */
241-
button {
242-
cursor: pointer;
243-
}
244-
245240
/* Selection */
246241
::selection {
247242
background-color: var(--fg-muted);

app/components/CollapsibleSection.vue

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
<script setup lang="ts">
22
import { shallowRef, computed } from 'vue'
3+
import { LinkBase } from '#components'
34
45
interface Props {
56
title: string
@@ -18,7 +19,6 @@ const appSettings = useSettings()
1819
1920
const buttonId = `${props.id}-collapsible-button`
2021
const contentId = `${props.id}-collapsible-content`
21-
const headingId = `${props.id}-heading`
2222
2323
const isOpen = shallowRef(true)
2424
@@ -75,11 +75,10 @@ useHead({
7575
</script>
7676

7777
<template>
78-
<section class="scroll-mt-20" :data-anchor-id="id">
78+
<section :id="id" :data-anchor-id="id" class="scroll-mt-20 xl:scroll-mt-0">
7979
<div class="flex items-center justify-between mb-3 px-1">
8080
<component
8181
:is="headingLevel"
82-
:id="headingId"
8382
class="group text-xs text-fg-subtle uppercase tracking-wider flex items-center gap-2"
8483
>
8584
<button
@@ -104,17 +103,9 @@ useHead({
104103
/>
105104
</button>
106105

107-
<a
108-
:href="`#${id}`"
109-
class="inline-flex items-center gap-1.5 text-fg-subtle hover:text-fg-muted transition-colors duration-200 no-underline"
110-
>
111-
<span v-if="icon" :class="icon" aria-hidden="true" />
106+
<LinkBase :to="`#${id}`" class="">
112107
{{ title }}
113-
<span
114-
class="i-carbon:link w-3 h-3 opacity-0 group-hover:opacity-100 transition-opacity duration-200"
115-
aria-hidden="true"
116-
/>
117-
</a>
108+
</LinkBase>
118109
</component>
119110

120111
<!-- Actions slot for buttons or other elements -->

app/components/ColumnPicker.vue

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -102,11 +102,7 @@ function handleReset() {
102102
v-for="column in toggleableColumns"
103103
:key="column.id"
104104
class="flex gap-2 items-center px-3 py-2 transition-colors duration-200"
105-
:class="
106-
column.disabled
107-
? 'opacity-50 cursor-not-allowed'
108-
: 'hover:bg-bg-muted cursor-pointer'
109-
"
105+
:class="column.disabled ? 'opacity-50 cursor-not-allowed' : 'hover:bg-bg-muted'"
110106
>
111107
<input
112108
type="checkbox"

app/components/DependencyPathPopup.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ function parsePackageString(pkg: string): { name: string; version: string } {
6868
<!-- Path badge button -->
6969
<button
7070
type="button"
71-
class="path-badge font-mono text-3xs px-1.5 py-0.5 rounded bg-amber-500/10 border border-amber-500/30 text-amber-700 dark:text-amber-400 cursor-pointer transition-all duration-200 ease-out whitespace-nowrap flex items-center gap-1 hover:bg-amber-500/20 hover:border-amber-500/50"
71+
class="path-badge font-mono text-3xs px-1.5 py-0.5 rounded bg-amber-500/10 border border-amber-500/30 text-amber-700 dark:text-amber-400 transition-all duration-200 ease-out whitespace-nowrap flex items-center gap-1 hover:bg-amber-500/20 hover:border-amber-500/50"
7272
:aria-expanded="isOpen"
7373
@click.stop="togglePopup"
7474
>

app/components/Header/AuthModal.client.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ watch(handleInput, newHandleInput => {
105105

106106
<details class="text-sm">
107107
<summary
108-
class="text-fg-subtle cursor-pointer hover:text-fg-muted transition-colors duration-200 focus-visible:(outline-2 outline-accent/70)"
108+
class="text-fg-subtle hover:text-fg-muted transition-colors duration-200 focus-visible:(outline-2 outline-accent/70)"
109109
>
110110
{{ $t('auth.modal.what_is_atmosphere') }}
111111
</summary>

app/components/Header/ConnectorModal.vue

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -173,9 +173,7 @@ function handleDisconnect() {
173173
</div>
174174

175175
<details class="text-sm">
176-
<summary
177-
class="text-fg-subtle cursor-pointer hover:text-fg-muted transition-colors duration-200"
178-
>
176+
<summary class="text-fg-subtle hover:text-fg-muted transition-colors duration-200">
179177
{{ $t('connector.modal.advanced') }}
180178
</summary>
181179
<div class="mt-3">

app/components/Link/Base.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ const isButtonMedium = computed(() => props.size === 'medium' && props.variant !
7373
/></span>
7474
<NuxtLink
7575
v-else
76-
class="group inline-flex gap-x-1 items-center justify-center"
76+
class="group/link inline-flex gap-x-1 items-center justify-center"
7777
:class="{
7878
'underline-offset-[0.2rem] underline decoration-1 decoration-fg/30': !isLinkAnchor && isLink,
7979
'font-mono text-fg hover:(decoration-accent text-accent) focus-visible:(decoration-accent text-accent) transition-colors duration-200':
@@ -103,7 +103,7 @@ const isButtonMedium = computed(() => props.size === 'medium' && props.variant !
103103
/>
104104
<span
105105
v-else-if="isLinkAnchor && isLink"
106-
class="i-carbon:link w-3 h-3 opacity-0 group-hover:opacity-100 transition-opacity duration-200"
106+
class="i-carbon:link w-3 h-3 opacity-0 group-hover/link:opacity-100 transition-opacity duration-200"
107107
aria-hidden="true"
108108
/>
109109
<kbd
Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,16 @@
1-
declare const _default: any
1+
// This type declaration file is required to break a circular type resolution in vue-tsc.
2+
//
3+
// nuxt-og-image generates a type declaration (.nuxt/module/nuxt-og-image.d.ts) that imports
4+
// this component's type. This creates a cycle: nuxt.d.ts → nuxt-og-image.d.ts → Package.vue →
5+
// needs auto-import globals from nuxt.d.ts. Without this file, vue-tsc resolves the component
6+
// before the globals are available, so all auto-imports (computed, toRefs, useFetch, etc.) fail.
7+
8+
import type { DefineComponent } from 'vue'
9+
10+
declare const _default: DefineComponent<{
11+
name: string
12+
version: string
13+
primaryColor?: string
14+
}>
215

316
export default _default

app/components/OgImage/Package.vue

Lines changed: 19 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,12 @@ const { data: likes, refresh: refreshLikes } = useFetch(() => `/api/social/likes
5353
const { stars, refresh: refreshRepoMeta } = useRepoMeta(repositoryUrl)
5454
5555
const formattedStars = computed(() =>
56-
Intl.NumberFormat('en', {
57-
notation: 'compact',
58-
maximumFractionDigits: 1,
59-
}).format(stars.value),
56+
stars.value > 0
57+
? Intl.NumberFormat('en', {
58+
notation: 'compact',
59+
maximumFractionDigits: 1,
60+
}).format(stars.value)
61+
: '',
6062
)
6163
6264
try {
@@ -75,6 +77,7 @@ try {
7577
class="h-full w-full flex flex-col justify-center px-20 bg-[#050505] text-[#fafafa] relative overflow-hidden"
7678
>
7779
<div class="relative z-10 flex flex-col gap-6">
80+
<!-- Package name -->
7881
<div class="flex items-start gap-4">
7982
<div
8083
class="flex items-center justify-center w-16 h-16 p-4 rounded-xl shadow-lg bg-gradient-to-tr from-[#3b82f6]"
@@ -107,6 +110,7 @@ try {
107110
</h1>
108111
</div>
109112

113+
<!-- Version -->
110114
<div
111115
class="flex items-center gap-5 text-4xl font-light text-[#a3a3a3]"
112116
style="font-family: 'Geist Sans', sans-serif"
@@ -122,6 +126,8 @@ try {
122126
>
123127
{{ resolvedVersion }}
124128
</span>
129+
130+
<!-- Downloads (if any) -->
125131
<span v-if="downloads" class="flex items-center gap-2">
126132
<svg
127133
width="30"
@@ -139,7 +145,9 @@ try {
139145
</svg>
140146
<span>{{ $n(downloads.downloads) }}/wk</span>
141147
</span>
142-
<span v-if="pkg?.license" class="flex items-center gap-2">
148+
149+
<!-- License (if any) -->
150+
<span v-if="pkg?.license" class="flex items-center gap-2" data-testid="license">
143151
<svg
144152
viewBox="0 0 32 32"
145153
:fill="primaryColor"
@@ -162,7 +170,9 @@ try {
162170
{{ pkg.license }}
163171
</span>
164172
</span>
165-
<span class="flex items-center gap-2">
173+
174+
<!-- Stars (if any) -->
175+
<span v-if="formattedStars" class="flex items-center gap-2" data-testid="stars">
166176
<svg
167177
xmlns="http://www.w3.org/2000/svg"
168178
viewBox="0 0 32 32"
@@ -179,7 +189,9 @@ try {
179189
{{ formattedStars }}
180190
</span>
181191
</span>
182-
<span class="flex items-center gap-2">
192+
193+
<!-- Likes (if any) -->
194+
<span v-if="likes.totalLikes > 0" class="flex items-center gap-2" data-testid="likes">
183195
<svg
184196
width="32"
185197
height="32"

0 commit comments

Comments
 (0)