<template>
  <el-checkbox-group :model-value="modelValue" :disabled="disabled" @update:model-value="handleChange">
    <el-checkbox v-for="opt in options" :key="opt.value" :label="opt.value">
      {{ opt.label }}
    </el-checkbox>
  </el-checkbox-group>
</template>

<script setup>
const props = defineProps({
  modelValue: String,
  disabled: Boolean,
  options: { type: Array, default: () => [] }
})
const emit = defineEmits(['update:modelValue'])

function handleChange(value) {
  emit('update:modelValue', value)
}
</script>