s3si.ts/gui/src/pages/Home.tsx

18 lines
458 B
TypeScript
Raw Normal View History

2023-03-04 06:19:24 -05:00
import { WebviewWindow } from '@tauri-apps/api/window'
2023-03-03 09:29:46 -05:00
import { Loading } from 'components/Loading'
2023-03-03 09:06:14 -05:00
import React from 'react'
export const Home: React.FC = ({ }) => {
2023-03-04 06:19:24 -05:00
const onClick = () => {
const webview = new WebviewWindow('theUniqueLabel', {
url: 'https://accounts.nintendo.com/',
resizable: false,
focus: true,
})
};
2023-03-03 09:06:14 -05:00
return <>
2023-03-03 09:29:46 -05:00
Hello world! <Loading />
2023-03-04 06:19:24 -05:00
<button onClick={onClick}>Open the window!</button>
2023-03-03 09:06:14 -05:00
</>
2023-03-04 06:19:24 -05:00
}