mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 10:02:05 +00:00
feat: Fix checkbox line height and make checkbox label clickable (#4818)
* fix: Update checkbox design and make checkbox label clickable * fix: Remove checkbox ids * chore: remove unused imports
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
<template>
|
||||
<el-checkbox
|
||||
v-bind="$props"
|
||||
ref="checkbox"
|
||||
:class="['n8n-checkbox', $style.n8nCheckbox]"
|
||||
:disabled="disabled"
|
||||
:indeterminate="indeterminate"
|
||||
@@ -12,7 +13,8 @@
|
||||
:tooltipText="tooltipText"
|
||||
:bold="false"
|
||||
:size="labelSize"
|
||||
></n8n-input-label>
|
||||
@click.prevent="onLabelClick"
|
||||
/>
|
||||
</el-checkbox>
|
||||
</template>
|
||||
|
||||
@@ -58,6 +60,14 @@ export default Vue.extend({
|
||||
onChange(event: Event) {
|
||||
this.$emit('input', event);
|
||||
},
|
||||
onLabelClick() {
|
||||
const checkboxComponent = this.$refs.checkbox as ElCheckbox;
|
||||
if (!checkboxComponent) {
|
||||
return;
|
||||
}
|
||||
|
||||
(checkboxComponent.$el as HTMLElement).click();
|
||||
},
|
||||
},
|
||||
});
|
||||
</script>
|
||||
@@ -70,5 +80,9 @@ export default Vue.extend({
|
||||
span {
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
label {
|
||||
cursor: pointer;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user