Initial commit — Diabetix V2
Application Laravel 12 + Inertia + Vue 3 + Tailwind. Fonctionnalités : dashboard glycémique, saisie de mesures, courbe SVG, statistiques (jour/semaine/mois/trimestre), défis & badges, chat coach IA (Gemini), paramètres profil avec palette de couleurs, pages auth redessinées, emails transactionnels via Resend avec thème Diabetix. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
20
app/resources/js/Components/Diabetix/ProgressBar.vue
Normal file
20
app/resources/js/Components/Diabetix/ProgressBar.vue
Normal file
@@ -0,0 +1,20 @@
|
||||
<script setup>
|
||||
import { computed } from 'vue';
|
||||
|
||||
const props = defineProps({
|
||||
value: { type: Number, default: 0 },
|
||||
max: { type: Number, default: 100 },
|
||||
color: { type: String, default: null },
|
||||
height: { type: Number, default: 6 },
|
||||
bg: { type: String, default: null },
|
||||
tok: { type: Object, required: true },
|
||||
});
|
||||
|
||||
const pct = computed(() => Math.min(100, Math.max(0, (props.value / props.max) * 100)));
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div :style="{ height: height + 'px', borderRadius: '999px', overflow: 'hidden', background: bg || tok.bgAlt }">
|
||||
<div :style="{ height: '100%', width: pct + '%', background: color || tok.primary, borderRadius: '999px', transition: 'width .3s ease' }" />
|
||||
</div>
|
||||
</template>
|
||||
Reference in New Issue
Block a user