"use client" import { RocketOne, Minus, Close, Square } from "@icon-park/react"; import { relaunch, exit } from "@tauri-apps/plugin-process"; import { getCurrentWindow } from "@tauri-apps/api/window"; // import { invoke } from "@tauri-apps/api/core"; const Nav = () => { const close = async () => { // (await window.hideOnClose) ? getCurrent().hide() : exit(); await exit(); }; const minimize = () => { getCurrentWindow() .minimize() .then(() => { console.log("minimized"); }) .catch((err: unknown) => { console.error(err); }); }; const toggleMaximize = async () => { const current = getCurrentWindow() const maximized = await current.isMaximized() maximized ? current.unmaximize() : current.maximize() } const reset = async () => { await relaunch(); }; return ( ); }; export default Nav;