summaryrefslogtreecommitdiff
path: root/packages/frontend/src/directives/user-preview.ts
diff options
context:
space:
mode:
authorsyuilo <4439005+syuilo@users.noreply.github.com>2025-03-20 19:00:09 +0900
committersyuilo <4439005+syuilo@users.noreply.github.com>2025-03-20 19:00:09 +0900
commit6015254e59ba0526efbfa139c89546458663ccbd (patch)
tree97adc609448eb3ce96730051193042c9eec470db /packages/frontend/src/directives/user-preview.ts
parentUpdate eslint.config.js (diff)
downloadsharkey-6015254e59ba0526efbfa139c89546458663ccbd.tar.gz
sharkey-6015254e59ba0526efbfa139c89546458663ccbd.tar.bz2
sharkey-6015254e59ba0526efbfa139c89546458663ccbd.zip
lint fixes
Diffstat (limited to 'packages/frontend/src/directives/user-preview.ts')
-rw-r--r--packages/frontend/src/directives/user-preview.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/frontend/src/directives/user-preview.ts b/packages/frontend/src/directives/user-preview.ts
index 43a93a0865..94deea82c7 100644
--- a/packages/frontend/src/directives/user-preview.ts
+++ b/packages/frontend/src/directives/user-preview.ts
@@ -31,7 +31,7 @@ export class UserPreview {
}
private show() {
- if (!document.body.contains(this.el)) return;
+ if (!window.document.body.contains(this.el)) return;
if (this.promise) return;
const showing = ref(true);
@@ -58,7 +58,7 @@ export class UserPreview {
};
this.checkTimer = window.setInterval(() => {
- if (!document.body.contains(this.el)) {
+ if (!window.document.body.contains(this.el)) {
window.clearTimeout(this.showTimer);
window.clearTimeout(this.hideTimer);
this.close();