feat: table style

This commit is contained in:
Alisa | Side.one 2023-05-27 23:53:19 +08:00
parent 9567e08c9a
commit 26e2563c99
2 changed files with 6 additions and 4 deletions

View File

@ -46,7 +46,7 @@ const isPositive = controlledComputed(
<div class="">
<h6 class="text-lg font-semibold mt-2 mb-1">
{{ props.stats }}
{{ props.stats || '-'}}
</h6>
<p class="text-sm">
{{ props.title }}

View File

@ -18,13 +18,15 @@ const header = computed(() => {
});
</script>
<template>
<div class="overflow-x-auto">
<VTable
<div class="overflow-x-auto p-4">
<div
v-if="header.length > 0"
class="table table-compact w-full"
density="compact"
:height="value.length > 5? '300px': ''"
fixed-header
hover
>
<thead v-if="thead">
<tr>
@ -44,7 +46,7 @@ const header = computed(() => {
</td>
</tr>
</tbody>
</VTable>
</div>
<div v-else class="h-[300px]"></div>
</div>