CLASSROOMIO-T-32: Landing page with editor v1

This commit is contained in:
Rotimi Best
2022-01-03 20:28:35 +02:00
parent 88cfadba3e
commit 7d7d68594b
10 changed files with 476 additions and 54 deletions
+1 -1
View File
@@ -102,7 +102,7 @@
}
function isCoursePage(path) {
return /courses\/[a-z 0-9 -]/.test(path);
return /course[s]*\/[a-z 0-9 -]/.test(path);
}
function handleResize() {
+34
View File
@@ -0,0 +1,34 @@
<script context="module">
export async function preload({ params }) {
return { slug: params.slug };
}
</script>
<script>
import CourseLandingPage from '../../components/CourseLandingPage/index.svelte';
import Editor from '../../components/CourseLandingPage/components/Editor/index.svelte';
import { isMobile } from '../../utils/store/useMobile';
</script>
<div class="root">
<Editor />
<div class="rightBar" class:isMobile={$isMobile}>
<CourseLandingPage />
</div>
</div>
<style>
.root {
display: flex;
width: 100%;
}
.rightBar {
flex-grow: 1;
width: calc(100% - 360px);
}
.rightBar.isMobile {
margin-left: 10px;
}
</style>