Skip to content

Commit 12e3086

Browse files
author
hywax
committed
chore: the entire card is a reference
1 parent 541cf32 commit 12e3086

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

components/service/base/Index.vue

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,17 @@
11
<template>
22
<ServicePlaceholder v-if="loadingOverlay" />
3-
<div v-else class="p-4 flex gap-4">
3+
<Component :is="isLink ? 'a' : 'div'" v-else :href="link" :target="target" class="p-4 flex gap-4 hover:bg-fg/5 dark:hover:bg-fg/9 rounded-2xl transition-all">
44
<div class="flex-shrink-0 flex">
5-
<Component :is="isLink ? 'a' : 'div'" :href="link" :target="target" class="self-center w-16 h-16 overflow-hidden rounded-2xl border border-fg/10 dark:border-fg/15">
5+
<div class="self-center w-16 h-16 overflow-hidden rounded-2xl border border-fg/10 dark:border-fg/15">
66
<slot name="icon" :service="data">
77
<ServiceBaseIcon v-if="icon" v-bind="icon" />
88
</slot>
9-
</Component>
9+
</div>
1010
</div>
1111
<div>
1212
<h3 class="text-lg mt-1 pr-1 font-semibold line-clamp-1 flex gap-2 items-center">
1313
<slot name="title" :service="data">
14-
<a v-if="isLink" :href="link" :target="target">{{ title }}</a>
15-
<span v-else>{{ title }}</span>
14+
{{ title }}
1615
</slot>
1716
<slot v-if="status" name="status" :data="data">
1817
<ServiceBaseStatus :ping="data?.ping" />
@@ -25,7 +24,7 @@
2524
</slot>
2625
</p>
2726
</div>
28-
</div>
27+
</Component>
2928
</template>
3029

3130
<script setup lang="ts">

0 commit comments

Comments
 (0)