Skip to content

Commit

Permalink
Corretly format files
Browse files Browse the repository at this point in the history
  • Loading branch information
miguelmagueijo committed Aug 18, 2024
1 parent 9e17b2b commit a385380
Show file tree
Hide file tree
Showing 4 changed files with 40 additions and 17 deletions.
16 changes: 13 additions & 3 deletions frontend/src/assets/CloseCross.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,16 @@
export let height = "";
export let classes = "";
</script>
<svg xmlns="http://www.w3.org/2000/svg" class={classes} width={width} height={height} viewBox="0 0 24 24">
<path fill="currentColor" d="M19 6.41L17.59 5L12 10.59L6.41 5L5 6.41L10.59 12L5 17.59L6.41 19L12 13.41L17.59 19L19 17.59L13.41 12z" />
</svg>

<svg
xmlns="http://www.w3.org/2000/svg"
class="{classes}"
width="{width}"
height="{height}"
viewBox="0 0 24 24"
>
<path
fill="currentColor"
d="M19 6.41L17.59 5L12 10.59L6.41 5L5 6.41L10.59 12L5 17.59L6.41 19L12 13.41L17.59 19L19 17.59L13.41 12z"
></path>
</svg>
8 changes: 6 additions & 2 deletions frontend/src/components/Changelog/ChangelogButton.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
import { modalStore } from "./store";
</script>

<button type="button" class="text-kuRed/75 underline md:no-underline md:text-sm relative" on:click={modalStore.open}>
<button
type="button"
class="text-kuRed/75 underline md:no-underline md:text-sm relative"
on:click="{modalStore.open}"
>
View Changelog
</button>
</button>
31 changes: 20 additions & 11 deletions frontend/src/components/Changelog/ChangelogModal.svelte
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<script lang="ts">
import { onMount } from "svelte";
import CloseCross from "../../assets/CloseCross.svelte";
import {modalStore} from "./store";
import { modalStore } from "./store";
const changelogItems = [
{
Expand Down Expand Up @@ -34,14 +34,19 @@

{#if $modalStore}
<!-- svelte-ignore a11y-click-events-have-key-events -->
<div class="absolute w-screen h-screen z-10 bg-black/40 flex justify-center items-center" on:click|self={modalStore.close}>
<div class="bg-white text-m font-normal h-fit mx-4 max-h-[75vh] md:max-h-[500px] overflow-y-scroll rounded">
<div class="flex justify-between mb-6 sticky top-0 bg-white pt-6 pb-4 border-b-2 px-6">
<h3 class="font-bold text-2xl">
Changelog
</h3>
<button type="button" on:click={modalStore.close}>
<CloseCross classes="size-6"/>
<div
class="absolute w-screen h-screen z-10 bg-black/40 flex justify-center items-center"
on:click|self="{modalStore.close}"
>
<div
class="bg-white text-m font-normal h-fit mx-4 max-h-[75vh] md:max-h-[500px] overflow-y-scroll rounded"
>
<div
class="flex justify-between mb-6 sticky top-0 bg-white pt-6 pb-4 border-b-2 px-6"
>
<h3 class="font-bold text-2xl">Changelog</h3>
<button type="button" on:click="{modalStore.close}">
<CloseCross classes="size-6" />
</button>
</div>
<ul class="space-y-4 -mt-4 px-6">
Expand All @@ -56,9 +61,13 @@
</li>
{/each}
</ul>
<button class="my-6 py-2 px-6 mx-auto block bg-kuRed text-white" type="button" on:click={modalStore.close}>
<button
class="my-6 py-2 px-6 mx-auto block bg-kuRed text-white"
type="button"
on:click="{modalStore.close}"
>
Close
</button>
</div>
</div>
{/if}
{/if}
2 changes: 1 addition & 1 deletion frontend/src/routes/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
import OverviewCard from "../components/OverviewCard/OverviewCard.svelte";
import type { Overview } from "../course";
import { browser } from "$app/environment";
let loading = true;
let error: string | null = null;
let API_URL = apiUrl();
Expand Down

0 comments on commit a385380

Please sign in to comment.