refactor: remove unused function
This commit is contained in:
parent
3c43a1cdd1
commit
f4f6208420
|
@ -43,17 +43,8 @@ const rebloggedBy = $computed(() => props.status.reblog ? props.status.account :
|
|||
|
||||
const statusRoute = $computed(() => getStatusRoute(status))
|
||||
|
||||
const el = ref<HTMLElement>()
|
||||
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)
|
||||
|
|
Loading…
Reference in a new issue