From f4f6208420a405fdd5cbab789612eb8a7c4adead Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=B8=89=E5=92=B2=E6=99=BA=E5=AD=90=20Kevin=20Deng?= Date: Fri, 31 Mar 2023 03:07:49 +0800 Subject: [PATCH] refactor: remove unused function --- components/status/StatusCard.vue | 9 --------- 1 file changed, 9 deletions(-) diff --git a/components/status/StatusCard.vue b/components/status/StatusCard.vue index 424ef6be..17cee428 100644 --- a/components/status/StatusCard.vue +++ b/components/status/StatusCard.vue @@ -43,17 +43,8 @@ const rebloggedBy = $computed(() => props.status.reblog ? props.status.account : const statusRoute = $computed(() => getStatusRoute(status)) -const el = ref() const router = useRouter() -function onclick(evt: MouseEvent | KeyboardEvent) { - const path = evt.composedPath() as HTMLElement[] - const el = path.find(el => ['A', 'BUTTON', 'IMG', 'VIDEO'].includes(el.tagName?.toUpperCase())) - const text = window.getSelection()?.toString() - if (!el && !text) - go(evt) -} - function go(evt: MouseEvent | KeyboardEvent) { if (evt.metaKey || evt.ctrlKey) { window.open(statusRoute.href)