Skip to content

Commit

Permalink
Merge pull request #850 from tutors-sdk/development
Browse files Browse the repository at this point in the history
reintroduce tutors time indicator
  • Loading branch information
edeleastar authored Nov 19, 2024
2 parents 86def94 + 33b3314 commit 6fd44b1
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/lib/ui/navigators/MainNavigator.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,17 @@
import { tutorsConnectService } from "$lib/services/connect.svelte";
import AnonProfile from "./tutors-connect/AnonProfile.svelte";
import ConnectedProfile from "./tutors-connect/ConnectedProfile.svelte";
import TutorsTimeIndicator from "./buttons/TutorsTimeIndicator.svelte";
</script>

<AppBar
background="bg-surface-100-800-token"
shadow="none"
class="h-20 justify-center border-b-[1px] border-surface-200 dark:border-surface-700"
>
<AppBar background="bg-surface-100-800-token" shadow="none" class="h-20 justify-center border-b-[1px] border-surface-200 dark:border-surface-700">
{#snippet lead()}
<InfoButton />
<CourseTitle />
{/snippet}
<CalendarButton />
{#snippet trail()}
<TutorsTimeIndicator />
{#if !currentCourse?.value?.isPortfolio}
<SearchButton />
{/if}
Expand Down
9 changes: 9 additions & 0 deletions src/lib/ui/navigators/buttons/TutorsTimeIndicator.svelte
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<script lang="ts">
import { currentCourse } from "$lib/runes";
import { tutorsConnectService } from "$lib/services/connect.svelte";
import Icon from "$lib/ui/themes/icons/Icon.svelte";
</script>

{#if currentCourse?.value?.authLevel! > 0 && tutorsConnectService?.tutorsId?.value?.share === "true"}
<Icon link="https://time.tutors.dev/{currentCourse?.value?.courseId}" type="tutorsTime" tip={"This course is Tutors Time enabled"} />
{/if}

0 comments on commit 6fd44b1

Please sign in to comment.