From 740f43e2bac7b1eee919351694905fecf9291943 Mon Sep 17 00:00:00 2001
From: ivarlovlie <git@ivarlovlie.no>
Date: Sun, 21 Aug 2022 16:56:11 +0200
Subject: feat: Before tailwind

---
 apps/projects/src/app/pages/nav/nav-item.svelte | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)
 create mode 100644 apps/projects/src/app/pages/nav/nav-item.svelte

(limited to 'apps/projects/src/app/pages/nav/nav-item.svelte')

diff --git a/apps/projects/src/app/pages/nav/nav-item.svelte b/apps/projects/src/app/pages/nav/nav-item.svelte
new file mode 100644
index 0000000..335cbbb
--- /dev/null
+++ b/apps/projects/src/app/pages/nav/nav-item.svelte
@@ -0,0 +1,18 @@
+<script lang="ts">
+    import {link} from "svelte-spa-router";
+    import Icon from "$shared/components/icon.svelte";
+    
+    export let external = "";
+    export let to = "";
+    export let text;
+    export let icon;
+</script>
+
+<li class="sidenav-v4__item">
+    <a class="sidenav-v4__link" href={to ?? external} use:link={external === ""}>
+        {#if icon}
+            <Icon class="sidenav-v4__icon icon" name="{icon}" />
+        {/if}
+        <span>{text}</span>
+    </a>
+</li>
-- 
cgit v1.3

