@setoelkahfi / svara / commits / 46bf3f1

chore: test notification

mellbacon committed May 21, 2024 at 18:26 UTC 46bf3f18e13e47b477b93a548a1d78bdf0c52284
1 file changed +3
src/App.svelte
+3
@@ -17,6 +17,7 @@
17 import { fitTerminal } from "./lib/Terminal.svelte";
18 import { loadDir } from "./lib/File";
19 import NotificationToasts from "./lib/Notifications/NotificationToasts.svelte";
20 + import { NotifType, addNotification } from "./lib/Notifications/notifications";
21 let resolution = writable(0);
22
23 let minPanelSize = 10;
@@ -35,6 +36,8 @@
36 resolution.set(size.width);
37 updateMinPanelSize();
38
39 + addNotification(NotifType.Message, "Startup", [{label: "Test action", action: () => {}}], "test message");
40 +
41 appWindow.onResized((e) => {
42 resolution.set(e.payload.width);
43 updateMinPanelSize();