Skip to content

Commit 52f1810

Browse files
committed
Merge branch 'EVL-78'
2 parents 28ae634 + 29a51e4 commit 52f1810

11 files changed

Lines changed: 230 additions & 419 deletions

File tree

apps/playground/app/app.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
export default defineAppConfig({
22
ui: {
33
colors: {
4-
primary: 'sky',
4+
primary: 'blue',
55
neutral: 'zinc',
66
},
77
},
Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,11 @@
11
@import "tailwindcss";
2-
@import "@nuxt/ui";
2+
@import "@nuxt/ui";
3+
4+
:root {
5+
--ui-radius: 0;
6+
--ui-primary: #2853FF;
7+
}
8+
9+
.dark {
10+
--ui-bg: #09090b;
11+
}

apps/playground/app/components/playground/NavigationTabs.vue

Lines changed: 0 additions & 35 deletions
This file was deleted.

apps/playground/app/components/playground/StatusIndicator.vue

Lines changed: 0 additions & 39 deletions
This file was deleted.

apps/playground/app/components/playground/TestButton.vue

Lines changed: 0 additions & 59 deletions
This file was deleted.

apps/playground/app/components/playground/TestCard.vue

Lines changed: 36 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,17 @@ const { execute, isLoading, result, error, status } = useTestRunner(props.id, {
2626
},
2727
})
2828
29+
const accentColor = computed(() => {
30+
const map: Record<string, string> = {
31+
error: 'var(--color-red-500)',
32+
warning: 'var(--color-amber-500)',
33+
success: 'var(--color-emerald-500)',
34+
primary: 'var(--ui-primary)',
35+
neutral: 'var(--color-zinc-600)',
36+
}
37+
return map[props.color || ''] || 'var(--ui-primary)'
38+
})
39+
2940
async function handleClick() {
3041
try {
3142
if (props.onClick) {
@@ -40,43 +51,40 @@ async function handleClick() {
4051
</script>
4152

4253
<template>
43-
<div class="h-full p-5 rounded-lg bg-elevated border border-primary/5 hover:border-primary/10 transition-colors flex flex-col">
44-
<div class="flex items-start justify-between gap-3 mb-3">
45-
<h3 class="text-sm font-semibold text-highlighted leading-tight">
46-
{{ label }}
47-
</h3>
54+
<div
55+
class="h-full bg-elevated border border-[var(--ui-border)] border-l-2 flex flex-col"
56+
:style="{ borderLeftColor: accentColor }"
57+
>
58+
<div
59+
class="p-4 flex-1 flex flex-col cursor-pointer transition-colors hover:bg-white/[0.02] active:bg-white/[0.04] relative"
60+
@click="handleClick"
61+
>
62+
<UIcon
63+
v-if="isLoading"
64+
name="i-lucide-loader-circle"
65+
class="size-3.5 animate-spin text-primary absolute top-4 right-4"
66+
/>
67+
4868
<UBadge
4969
v-if="badge"
50-
:color="badge.color as any"
70+
color="neutral"
5171
variant="subtle"
52-
class="shrink-0"
72+
class="mb-2.5 w-fit"
5373
>
5474
{{ badge.label }}
5575
</UBadge>
56-
</div>
57-
58-
<p v-if="description" class="text-sm text-muted leading-relaxed mb-4 grow">
59-
{{ description }}
60-
</p>
6176

62-
<div class="mt-auto">
63-
<UButton
64-
block
65-
:color="color as any"
66-
:loading="isLoading"
67-
@click="handleClick"
68-
>
77+
<h3 class="text-sm font-medium text-highlighted leading-snug">
6978
{{ label }}
70-
</UButton>
79+
</h3>
80+
81+
<p v-if="description" class="text-xs text-muted leading-relaxed mt-1.5 line-clamp-2" :title="description">
82+
{{ description }}
83+
</p>
7184
</div>
7285

73-
<PlaygroundTestResult
74-
v-if="showResult"
75-
:status
76-
:response="result"
77-
:error
78-
compact
79-
class="mt-4"
80-
/>
86+
<div v-if="showResult" class="px-4 pb-4" @click.stop>
87+
<PlaygroundTestResult :status :response="result" :error compact />
88+
</div>
8189
</div>
8290
</template>

apps/playground/app/components/playground/TestSection.vue

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,15 @@ defineProps<{
77
</script>
88

99
<template>
10-
<section :id class="space-y-6">
11-
<div class="space-y-2">
12-
<h2 class="text-2xl font-bold text-highlighted">
13-
{{ title }}
14-
</h2>
15-
<p class="text-muted leading-relaxed">
10+
<section :id class="space-y-5">
11+
<div>
12+
<div class="flex items-center gap-2 mb-1.5">
13+
<div class="w-1 h-4 bg-primary" />
14+
<h2 class="text-lg font-semibold text-highlighted">
15+
{{ title }}
16+
</h2>
17+
</div>
18+
<p class="text-sm text-muted leading-relaxed">
1619
{{ description }}
1720
</p>
1821
</div>

apps/playground/app/composables/useTestConfig.ts

Lines changed: 0 additions & 21 deletions
This file was deleted.

0 commit comments

Comments
 (0)