refactor: refs #7411 update VnCheckbox component to use v-bind for attributes

This commit is contained in:
Jose Antonio Tubau 2025-01-31 08:50:35 +01:00
parent c083eba66c
commit cc07cc7824
1 changed files with 8 additions and 6 deletions

View File

@ -4,10 +4,6 @@ import { defineModel } from 'vue';
const modelValue = defineModel({ type: Boolean, default: false }); const modelValue = defineModel({ type: Boolean, default: false });
const $props = defineProps({ const $props = defineProps({
label: {
type: String,
default: null,
},
info: { info: {
type: String, type: String,
default: null, default: null,
@ -18,10 +14,16 @@ const $props = defineProps({
<template> <template>
<div> <div>
<QCheckbox <QCheckbox
:label="label" v-bind="$attrs"
v-model="modelValue" v-model="modelValue"
/> />
<QIcon v-if="info" class="cursor-info q-ml-sm" name="info" size="sm" v-bind="$attrs"> <QIcon
v-if="info"
v-bind="$attrs"
class="cursor-info q-ml-sm"
name="info"
size="sm"
>
<QTooltip> <QTooltip>
{{ info }} {{ info }}
</QTooltip> </QTooltip>