1
0
mirror of https://github.com/misskey-dev/misskey.git synced 2026-05-23 15:44:26 +02:00

refactor(frontend): フロントエンドの型エラー解消 (#16694)

This commit is contained in:
かっこかり
2025-10-23 11:04:27 +09:00
committed by GitHub
parent 4988719a2e
commit d203e1a446
8 changed files with 26 additions and 19 deletions

View File

@@ -15,7 +15,7 @@ const start = isTouchUsing ? 'touchstart' : 'mouseenter';
const end = isTouchUsing ? 'touchend' : 'mouseleave';
type TooltipDirectiveState = {
text: string;
text: string | null | undefined;
_close: null | (() => void);
showTimer: number | null;
hideTimer: number | null;
@@ -53,6 +53,7 @@ export const tooltipDirective = {
if (binding.arg === 'dialog') {
el.addEventListener('click', (ev) => {
if (binding.value == null) return;
ev.preventDefault();
ev.stopPropagation();
alert({
@@ -128,4 +129,4 @@ export const tooltipDirective = {
if (self.checkTimer) window.clearTimeout(self.checkTimer);
self.close();
},
} as Directive<TooltipDirectiveElement, string, TooltipDirectiveModifiers, TooltipDirectiveArg>;
} as Directive<TooltipDirectiveElement, string | null | undefined, TooltipDirectiveModifiers, TooltipDirectiveArg>;