File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change 1
1
<template >
2
- <div class =" flex items-center h-5" >
2
+ <div class =" flex items-center h-5" :class = " {'opacity-50' : props.disabled} " >
3
3
<input :id =" id"
4
4
ref =" rememberInput"
5
5
type =" checkbox"
6
6
:checked =" props.modelValue"
7
+ :disabled =" props.disabled"
7
8
@change =" $emit('update:modelValue', $event.target.checked)"
8
9
class =" w-4 h-4 border border-gray-300 rounded bg-gray-50 focus:ring-3 focus:ring-lightPrimary cursor-pointer
9
10
focus:ring-opacity-50 dark:bg-gray-700 dark:border-gray-600 dark:focus:ring-blue-600 dark:ring-offset-gray-800 dark:focus:ring-offset-gray-800 checked:bg-lightPrimary checked:dark:bg-darkPrimary" />
17
18
18
19
const props = defineProps ({
19
20
modelValue: Boolean ,
21
+ disabled: Boolean ,
20
22
});
21
23
22
24
defineEmits ([' update:modelValue' ]);
You can’t perform that action at this time.
0 commit comments