🤖 Adds 3D model view
This commit is contained in:
+11
-1
@@ -12,13 +12,23 @@
|
||||
export let url = window.location.pathname;
|
||||
onMount(() => {
|
||||
connect(`ws://${location}`);
|
||||
registerFetchIntercept()
|
||||
});
|
||||
|
||||
const registerFetchIntercept = () => {
|
||||
const { fetch: originalFetch } = window;
|
||||
window.fetch = async (...args) => {
|
||||
const cache = await caches.open("files")
|
||||
const [resource, config] = args;
|
||||
return await cache.match(resource) ?? originalFetch(resource, config)
|
||||
};
|
||||
}
|
||||
</script>
|
||||
|
||||
<Router {url}>
|
||||
<TopBar />
|
||||
<Sidebar />
|
||||
<div class="absolute w-full h-full">
|
||||
<div class="absolute w-full h-full bg-background text-on-background">
|
||||
<Route path="/" component={Controller} />
|
||||
<Route path="/config" component={Config} />
|
||||
<Route path="/health" component={Health} />
|
||||
|
||||
Reference in New Issue
Block a user