Add parsing of AD1 files. Memorize window size and location.

This commit is contained in:
Patrick Fic
2025-03-17 14:27:33 -07:00
parent 10368f8f9e
commit c1949eb5f9
33 changed files with 524 additions and 20 deletions

View File

@@ -11,6 +11,7 @@ import {} from "react-error-boundary";
import { ErrorBoundary } from "react-error-boundary";
import ErrorBoundaryFallback from "./components/ErrorBoundaryFallback/ErrorBoundaryFallback";
import Settings from "./components/Settings/Settings";
import Home from "./components/Home/Home";
const App: React.FC = () => {
const [user, setUser] = useState<User | null>(null);
@@ -36,7 +37,7 @@ const App: React.FC = () => {
<>
<NavigationHeader />
<Routes>
<Route path="/" element={<div>AuthHome</div>} />
<Route path="/" element={<Home />} />
<Route path="settings" element={<Settings />} />
</Routes>
</>

View File

@@ -0,0 +1,21 @@
import { Button } from "antd";
import ipcTypes from "../../../../util/ipcTypes.json";
const Home: React.FC = () => {
return (
<div>
<h1>Home</h1>
<Button
onClick={(): void => {
window.electron.ipcRenderer.send(
ipcTypes.toMain.debug.decodeEstimate
);
}}
>
Test Decode Estimate
</Button>
</div>
);
};
export default Home;

View File

@@ -16,7 +16,7 @@ const SettingsWatchedPaths: React.FC = () => {
});
}, []);
const handleAddPath = () => {
const handleAddPath = (): void => {
window.electron.ipcRenderer
.invoke(ipcTypes.toMain.settings.filepaths.add)
.then((paths: string[]) => {
@@ -24,7 +24,7 @@ const SettingsWatchedPaths: React.FC = () => {
});
};
const handleRemovePath = (path: string) => {
const handleRemovePath = (path: string): void => {
window.electron.ipcRenderer
.invoke(ipcTypes.toMain.settings.filepaths.remove, path)
.then((paths: string[]) => {