2022-11-25 15:45:26 +00:00
|
|
|
import type { Component } from 'solid-js';
|
|
|
|
import { Routes, Route, Navigate } from '@solidjs/router';
|
|
|
|
import Map from './components/map';
|
2022-12-14 14:26:32 +00:00
|
|
|
import { AndroidFullScreen } from '@awesome-cordova-plugins/android-full-screen';
|
|
|
|
|
|
|
|
// See https://stackoverflow.com/questions/71288670/how-to-make-fullscreen-ionic-capacitor-app
|
|
|
|
AndroidFullScreen.isImmersiveModeSupported()
|
|
|
|
.then(() => AndroidFullScreen.immersiveMode())
|
|
|
|
.catch(console.warn);
|
2022-11-25 15:45:26 +00:00
|
|
|
|
|
|
|
const App: Component = () => {
|
|
|
|
return (
|
|
|
|
<Routes>
|
2022-11-28 14:27:36 +00:00
|
|
|
<Route path='/map/:provider/:lon/:lat/:zoom/:rotation' component={Map} />
|
|
|
|
<Route path='/*' element={<Navigate href='/map/osm/0/0/2/0' />} />
|
2022-11-25 15:45:26 +00:00
|
|
|
</Routes>
|
|
|
|
);
|
|
|
|
};
|
|
|
|
|
|
|
|
export default App;
|