1
0
mirror of https://github.com/ZeroCatDev/Classworks.git synced 2026-03-22 10:23:30 +00:00
Classworks/src/components/SettingsCard.vue
2025-11-16 15:14:17 +08:00

55 lines
939 B
Vue

<template>
<v-card class="settings-card rounded-lg" elevation="2">
<v-card-item>
<template #prepend>
<v-icon
:icon="icon"
class="mr-2"
size="large"
/>
</template>
<v-card-title class="text-h6">{{ title }}</v-card-title>
</v-card-item>
<v-card-text>
<v-progress-linear
v-if="loading"
class="mb-4"
color="primary"
indeterminate
/>
<slot/>
</v-card-text>
<v-card-actions v-if="$slots.actions" class="pa-4">
<slot name="actions"/>
</v-card-actions>
</v-card>
</template>
<script>
export default {
name: 'SettingsCard',
props: {
title: {
type: String,
required: true
},
icon: {
type: String,
required: true
},
loading: {
type: Boolean,
default: false
}
}
}
</script>
<style scoped>
.settings-card {
height: 100%;
}
</style>