chore: ai, public course and other ui improvements
This commit is contained in:
@@ -14,6 +14,8 @@
|
||||
import ContentCreateModal from '$features/course/components/content/content-create-modal.svelte';
|
||||
import CourseCompletionModal from '$features/course/components/ceritficate/course-completion-modal.svelte';
|
||||
import { AiCourseChat } from '$features/ai-assistant';
|
||||
import { initialChatPrompt, openAiAssistant } from '$features/ai-assistant/utils/store';
|
||||
import { get } from 'svelte/store';
|
||||
import { profile } from '$lib/utils/store/user';
|
||||
import { isOrgAdmin } from '$lib/utils/store/org';
|
||||
import { t } from '$lib/utils/functions/translations';
|
||||
@@ -98,6 +100,10 @@
|
||||
}
|
||||
|
||||
hasLoadedSidebarWidth = true;
|
||||
|
||||
if (get(initialChatPrompt)) {
|
||||
openAiAssistant();
|
||||
}
|
||||
});
|
||||
|
||||
$effect(() => {
|
||||
@@ -180,5 +186,5 @@
|
||||
{/if}
|
||||
</Sidebar.Inset>
|
||||
|
||||
<AiCourseChat />
|
||||
<AiCourseChat courseId={data.courseId} />
|
||||
</Sidebar.Provider>
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
});
|
||||
</script>
|
||||
|
||||
<Page.Root class="mx-auto flex w-[90%] px-4 md:max-w-2xl lg:max-w-3xl">
|
||||
<Page.Root class="mx-auto flex w-full px-3 sm:w-[90%] sm:px-4 lg:max-w-5xl">
|
||||
{#if isLockedForStudent}
|
||||
<Empty
|
||||
title={$t('course.navItem.lessons.content_locked_title')}
|
||||
|
||||
Reference in New Issue
Block a user