Skip to content

Commit

Permalink
Moved navigation feedback to the header.
Browse files Browse the repository at this point in the history
  • Loading branch information
amyjko committed Jul 4, 2024
1 parent b369ee4 commit cbcb9e3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.
1 change: 1 addition & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ Dates should be in`YYYY-MM-DD` format and versions are in [semantic versioning](
- Don't show role drop down if empty.
- Cleaned up landing page.
- Don't blur dialog background so that errors are visible.
- Moved navigation feedback to the header.

## v0.5.2

Expand Down
8 changes: 1 addition & 7 deletions src/lib/OrganizationLink.svelte
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
<script lang="ts">
import Link from './Link.svelte';
import { type OrganizationID } from '$types/Organization';
import { navigating } from '$app/stores';
import Loading from './Loading.svelte';
export let id: OrganizationID;
export let name: string;
</script>

{#if $navigating}
<Loading />
{:else}
<Link to="/org/{id}" kind="org">{name}</Link>
{/if}
<Link to="/org/{id}" kind="org">{name}</Link>
4 changes: 3 additions & 1 deletion src/lib/Page.svelte
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
<script>
import { navigating } from '$app/stores';
import Link from './Link.svelte';
import Loading from './Loading.svelte';
import Logo from './Logo';
import { getUser } from './contexts';
const user = getUser();
</script>

<div class="header">
<Link to="/">{Logo}</Link><span class="account"
<Link to="/">{Logo}</Link>{#if $navigating}<Loading />{/if}<span class="account"
>{#if $user}<Link to="/login">{$user.email}</Link>{:else}<Link to="/login">Login</Link
>{/if}</span
>
Expand Down

0 comments on commit cbcb9e3

Please sign in to comment.