mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-19 16:10:12 +01:00
This commit is contained in:
parent
1139ffddc0
commit
bd24cc4b3b
1 changed files with 1 additions and 6 deletions
|
|
@ -20,12 +20,7 @@ export const showTooltip = (message: string, target: Element, tooltipClass?: str
|
||||||
if (tooltipClass) {
|
if (tooltipClass) {
|
||||||
messageElement.classList.add("tooltip--" + tooltipClass);
|
messageElement.classList.add("tooltip--" + tooltipClass);
|
||||||
} else {
|
} else {
|
||||||
const classesToRemove = Array.from(messageElement.classList).filter(className =>
|
messageElement.className = "tooltip";
|
||||||
className.startsWith("tooltip--")
|
|
||||||
);
|
|
||||||
classesToRemove.forEach(className => {
|
|
||||||
messageElement.classList.remove(className);
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
let left = targetRect.left;
|
let left = targetRect.left;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue