feat: students can view org landing page from LMS

This commit is contained in:
Rotimi Best
2024-04-25 06:51:39 +01:00
parent 648e15d88d
commit bd94594b56
18 changed files with 67 additions and 34 deletions
+1 -1
View File
@@ -323,7 +323,7 @@
{/if}
{/if}
<div class="flex justify-between">
<div class={path.includes('home') ? '' : 'flex justify-between'}>
<slot />
{#if showAppsSideBar(path)}
+2 -2
View File
@@ -11,10 +11,10 @@
function handleClick() {
if (!isOrg) {
return goto('/')
return goto('/');
}
return goto('/home')
return goto('https://classroomio.com');
}
</script>
@@ -1,5 +0,0 @@
import { redirect } from '@sveltejs/kit';
export const load = () => {
throw redirect(307, 'https://classroomio.com');
};
@@ -0,0 +1,7 @@
<script>
import OrgLandingPage from '$lib/components/Org/LandingPage/index.svelte';
import { globalStore } from '$lib/utils/store/app';
import { currentOrg } from '$lib/utils/store/org';
</script>
<OrgLandingPage orgSiteName={$globalStore.orgSiteName} org={$currentOrg} />
+10 -4
View File
@@ -10,6 +10,7 @@
import type { Course } from '$lib/utils/types';
import { getGreeting } from '$lib/utils/functions/date';
import { t } from '$lib/utils/functions/translations';
import VisitOrgSiteButton from '$lib/components/Buttons/VisitOrgSite.svelte';
let hasFetched = false;
let progressPercentage = 0;
@@ -52,10 +53,15 @@
<section class="max-w-6xl gap-5 mx-auto">
<div class="m-5">
<h1 class="dark:text-white text-2xl md:text-3xl font-bold mb-3">
{$t(getGreeting())}
{$profile.fullname}!
</h1>
<div class="flex items-center justify-between mb-10">
<h1 class="dark:text-white text-2xl md:text-3xl font-bold">
{$t(getGreeting())}
{$profile.fullname}!
</h1>
<VisitOrgSiteButton isLMS={true} />
</div>
<div
class="w-full h-fit lg:h-[265px] flex md:items-center justify-between flex-col-reverse md:flex-row p-5 lg:p-10 rounded-md bg-primary-900 my-2"
>