Skip to content

Commit

Permalink
✨ Add support for custom navbar items
Browse files Browse the repository at this point in the history
  • Loading branch information
AnandChowdhary committed Oct 29, 2020
1 parent 861c7f0 commit e794ae0
Showing 1 changed file with 12 additions and 6 deletions.
18 changes: 12 additions & 6 deletions src/components/Nav.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,18 @@
</div>
{/if}
<ul>
<li>
<a aria-current={segment === undefined ? 'page' : undefined} href="/">
{config.i18n.navStatus}
</a>
</li>
{#if config['status-website'] && config['status-website'].navbarGitHub}
{#if config['status-website'] && config['status-website'].navbar}
{#each config['status-website'].navbar as item}
<li>
<a
aria-current={segment === (item.href === '/' ? undefined : item.href) ? 'page' : undefined}
href={item.href}>
{item.title}
</a>
</li>
{/each}
{/if}
{#if config['status-website'] && config['status-website'].navbarGitHub && !config['status-website'].navbar}
<li>
<a href={`https://github.com/${config.owner}/${config.repo}`}>
{config.i18n.navGitHub}
Expand Down

0 comments on commit e794ae0

Please sign in to comment.