appmanager: simple web ui
diff --git a/core/appmanager/sveltekit/appmanager/src/app.html b/core/appmanager/sveltekit/appmanager/src/app.html
index 76f6fa3..e13964e 100644
--- a/core/appmanager/sveltekit/appmanager/src/app.html
+++ b/core/appmanager/sveltekit/appmanager/src/app.html
@@ -7,6 +7,6 @@
%sveltekit.head%
</head>
<body data-sveltekit-preload-data="hover">
- <div style="display: contents">%sveltekit.body%</div>
+ <div style="display: contents" class="h-full overflow-hidden">%sveltekit.body%</div>
</body>
</html>
diff --git a/core/appmanager/sveltekit/appmanager/src/app.postcss b/core/appmanager/sveltekit/appmanager/src/app.postcss
index 2e1e086..4bdf31e 100644
--- a/core/appmanager/sveltekit/appmanager/src/app.postcss
+++ b/core/appmanager/sveltekit/appmanager/src/app.postcss
@@ -1 +1,4 @@
/* Write your global styles here, in PostCSS syntax */
+html, body {
+ @apply h-full overflow-hidden;
+}
diff --git a/core/appmanager/sveltekit/appmanager/src/routes/+layout.svelte b/core/appmanager/sveltekit/appmanager/src/routes/+layout.svelte
index bffb1ea..f7560fd 100644
--- a/core/appmanager/sveltekit/appmanager/src/routes/+layout.svelte
+++ b/core/appmanager/sveltekit/appmanager/src/routes/+layout.svelte
@@ -1,12 +1,18 @@
-<script>
- // Your selected Skeleton theme:
- import '@skeletonlabs/skeleton/themes/theme-skeleton.css';
+<script lang="ts">
+ import "@skeletonlabs/skeleton/themes/theme-skeleton.css";
+ import "@skeletonlabs/skeleton/styles/skeleton.css";
+ import "../app.postcss";
+import { onMount } from "svelte";
- // This contains the bulk of Skeletons required styles:
- // NOTE: this will be renamed skeleton.css in the v2.x release.
- import '@skeletonlabs/skeleton/styles/skeleton.css';
-
- import '../app.postcss';
+ onMount(() => {
+ window.addEventListener('message', (e) => {
+ console.log(e);
+ if ("go_back" in e.data) {
+ window.history.go(-1);
+ }
+ });
+ });
</script>
<slot />
+
diff --git a/core/appmanager/sveltekit/appmanager/src/routes/+page.svelte b/core/appmanager/sveltekit/appmanager/src/routes/+page.svelte
index 5b8b500..c6ee5fe 100644
--- a/core/appmanager/sveltekit/appmanager/src/routes/+page.svelte
+++ b/core/appmanager/sveltekit/appmanager/src/routes/+page.svelte
@@ -9,7 +9,7 @@
let apps: app[] = [];
onMount(async () => {
- const resp = await fetch("http://localhost:8080/api/app-repo");
+ const resp = await fetch("/api/app-repo");
apps = await resp.json();
});
</script>