mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Add descriptive variable
Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
parent
58f9752a29
commit
ca831b424d
@ -107,8 +107,9 @@ class NonInjectedDrawer extends React.Component<DrawerProps & Dependencies & typ
|
||||
// detail: A count of consecutive clicks that happened in a short amount of time
|
||||
if (ev.detail === 3) {
|
||||
const selection = window.getSelection();
|
||||
const isSelectingChildrenOfInputLabel = selection?.anchorNode instanceof HTMLLabelElement;
|
||||
|
||||
if (selection?.anchorNode?.parentNode && !(selection.anchorNode instanceof HTMLLabelElement)) {
|
||||
if (selection?.anchorNode?.parentNode && !isSelectingChildrenOfInputLabel) {
|
||||
selection.selectAllChildren(selection.anchorNode.parentNode);
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user