Remove unnecessary imports

This commit is contained in:
Dylan 2022-08-28 19:46:26 +09:30
parent c2f6a80244
commit 459987b2b3

View file

@ -1,15 +1,8 @@
import React, { useState } from 'react';
import { invoke } from '@tauri-apps/api/tauri';
import { openReusableDialog } from '../client/action/navigation';
import Text from '../app/atoms/text/Text';
import RoomTile from '../app/molecules/room-tile/RoomTile';
import initMatrix from '../client/initMatrix';
import PopupWindow from '../app/molecules/popup-window/PopupWindow';
import Spinner from '../app/atoms/spinner/Spinner';
import { openJoinAlias } from '../client/action/navigation';
const handlers = {
'matrix.to': (url) => {
'matrix.to': (url) => {
openJoinAlias(url.hash.slice(2));
},
};
@ -30,9 +23,8 @@ export default function handleLink(e) {
invoke('open_link', { url: e.target.href })
.then(() => e.preventDefault())
.catch((error) => console.error(error));
}
else {
//open in new tab
} else {
// open in new tab
window.open(e.target.href);
e.preventDefault();
}