1
0
Fork 0
mirror of synced 2024-08-23 22:11:39 +12:00
budibase/packages/builder/src/BackendRoot.svelte

58 lines
1.3 KiB
Svelte
Raw Normal View History

2019-08-20 18:24:02 +12:00
<script>
2020-02-03 22:50:30 +13:00
import BackendNav from "./nav/BackendNav.svelte"
2020-03-11 02:53:23 +13:00
import SchemaManagementDrawer from "./nav/SchemaManagementDrawer.svelte"
2020-02-03 22:50:30 +13:00
import Database from "./database/DatabaseRoot.svelte"
import UserInterface from "./userInterface/UserInterfaceRoot.svelte"
import ActionsAndTriggers from "./actionsAndTriggers/ActionsAndTriggersRoot.svelte"
import AccessLevels from "./accessLevels/AccessLevelsRoot.svelte"
import ComingSoon from "./common/ComingSoon.svelte"
2019-08-20 18:24:02 +12:00
2020-02-03 22:50:30 +13:00
import { store } from "./builderStore"
2020-03-11 02:53:23 +13:00
import { setContext } from 'svelte';
2019-08-20 18:24:02 +12:00
2020-03-11 02:53:23 +13:00
let activeNav = "database";
setContext("activeNav", activeNav);
2019-08-20 18:24:02 +12:00
</script>
<div class="root">
2019-08-30 19:25:00 +12:00
<div class="nav">
<BackendNav />
</div>
2020-02-25 10:31:35 +13:00
<div class="content">
2020-03-11 02:53:23 +13:00
{#if activeNav === 'database'}
2020-02-03 22:50:30 +13:00
<Database />
2020-03-11 02:53:23 +13:00
{:else if activeNav === 'actions'}
2020-02-03 22:50:30 +13:00
<ActionsAndTriggers />
2020-03-11 02:53:23 +13:00
{:else if activeNav === 'access levels'}
2020-02-03 22:50:30 +13:00
<AccessLevels />
2019-08-20 18:24:02 +12:00
{/if}
</div>
2020-03-11 02:53:23 +13:00
<div class="nav">
<SchemaManagementDrawer />
</div>
2019-08-20 18:24:02 +12:00
</div>
<style>
2020-02-03 22:50:30 +13:00
.root {
height: 100%;
display: flex;
2020-03-11 02:53:23 +13:00
background: #fafafa;
2020-02-03 22:50:30 +13:00
}
.content {
flex: 1 1 auto;
2020-03-11 02:53:23 +13:00
margin: 80px 60px;
background: #fff;
border-radius: 5px;
box-shadow: 0 0px 6px rgba(0, 0, 0, 0.05);
2020-02-03 22:50:30 +13:00
}
.nav {
2020-02-25 10:31:35 +13:00
overflow: auto;
2020-02-03 22:50:30 +13:00
flex: 0 1 auto;
width: 300px;
height: 100%;
}
</style>