|
|
@ -12,7 +12,7 @@ const onChange = (e: boolean) => { |
|
|
|
|
|
|
|
|
|
|
|
<template> |
|
|
|
<template> |
|
|
|
<a-switch v-model:checked="checked" :disabled="props.disabled" class="nc-switch" size="small" @change="onChange"> </a-switch> |
|
|
|
<a-switch v-model:checked="checked" :disabled="props.disabled" class="nc-switch" size="small" @change="onChange"> </a-switch> |
|
|
|
<span class="cursor-pointer pl-2" @click="checked = !checked"> |
|
|
|
<span v-if="$slots.default" class="cursor-pointer pl-2" @click="checked = !checked"> |
|
|
|
<slot /> |
|
|
|
<slot /> |
|
|
|
</span> |
|
|
|
</span> |
|
|
|
</template> |
|
|
|
</template> |
|
|
|