40 lines
889 B
Vue
40 lines
889 B
Vue
<template>
|
|
<table class="emphased">
|
|
<tbody>
|
|
<tr>
|
|
<td v-for="(val, index) in values" :id="`${questionId}-${val}`" :key="index">
|
|
<input type="radio" :value="val" :name="String(questionId)">
|
|
<label :for="`${questionId}-${val}`">{{ val }}</label>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</template>
|
|
|
|
|
|
<script setup lang="ts">
|
|
interface Props {
|
|
values?: string[]
|
|
questionId: string
|
|
}
|
|
|
|
const { values = ["Très bien", "Bien", "Passable", "Insuffisant", "À rejeter"], questionId } = defineProps<Props>()
|
|
|
|
</script>
|
|
|
|
|
|
<style scoped="true" lang="css">
|
|
.emphased {
|
|
border: 1px solid #444;
|
|
padding: 1em;
|
|
margin-top: 2em;
|
|
margin-bottom: 2em;
|
|
table-layout: fixed;
|
|
width: 100%;
|
|
border-collapse: collapse;
|
|
}
|
|
|
|
.emphased td {
|
|
border: 1px solid;
|
|
}
|
|
</style> |