mirror of
https://github.com/zadam/trilium.git
synced 2025-12-13 02:44:24 +01:00
feat(widgets): prevent clicks in toggle from dismissing menu
This commit is contained in:
parent
8fa9c25f2a
commit
b39a6bcc97
@ -139,8 +139,12 @@ export function FormListToggleableItem({ title, currentValue, onChange, ...props
|
|||||||
onChange(newValue: boolean): void;
|
onChange(newValue: boolean): void;
|
||||||
}) {
|
}) {
|
||||||
return (
|
return (
|
||||||
<FormListItem {...props}>
|
<FormListItem {...props} onClick={(e) => e.stopPropagation()}>
|
||||||
<FormToggle switchOnName={title} switchOffName={title} currentValue={currentValue} onChange={onChange} />
|
<FormToggle
|
||||||
|
switchOnName={title} switchOffName={title}
|
||||||
|
currentValue={currentValue}
|
||||||
|
onChange={onChange}
|
||||||
|
/>
|
||||||
</FormListItem>
|
</FormListItem>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user