- Introduced a new BaseTable component to enhance table functionality with sorting and loading states. - Updated upload queue logic to support chunk uploads and improved error handling. - Refactored various admin routes to utilize the new BaseTable component. - Adjusted import paths for UI components to maintain consistency. - Enhanced upload handling with better progress tracking and cancellation support. - Updated theme colors in uno.config.ts for a more cohesive design.
22 lines
557 B
Vue
22 lines
557 B
Vue
<script setup lang="ts">
|
|
import { cn } from '@/lib/utils';
|
|
import { computed } from 'vue';
|
|
|
|
const props = defineProps<{
|
|
value: number;
|
|
class?: string;
|
|
}>();
|
|
|
|
const pct = computed(() => {
|
|
const v = Number(props.value);
|
|
if (Number.isNaN(v)) return 0;
|
|
return Math.min(Math.max(v, 0), 100);
|
|
});
|
|
</script>
|
|
|
|
<template>
|
|
<div :class="cn('w-full bg-muted/50 rounded-full overflow-hidden', props.class)" style="height: 6px">
|
|
<div class="bg-primary h-full rounded-full transition-all duration-300" :style="{ width: `${pct}%` }" />
|
|
</div>
|
|
</template>
|