refactor(client): refactor
This commit is contained in:
parent
cc441258db
commit
3a990dce75
3 changed files with 28 additions and 65 deletions
|
|
@ -18,6 +18,9 @@ export function useTooltip(
|
|||
const open = () => {
|
||||
close();
|
||||
if (!isHovering) return;
|
||||
if (elRef.value == null) return;
|
||||
const el = elRef.value instanceof Element ? elRef.value : elRef.value.$el;
|
||||
if (!document.body.contains(el)) return; // openしようとしたときに既に元要素がDOMから消えている場合があるため
|
||||
|
||||
const showing = ref(true);
|
||||
onShow(showing);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue