@@ -48,7 +50,11 @@ const emits = defineEmits<{
const source = computed(() => sources.value[props.item.source]);
const sourceItem = computed(() => source.value.items[props.item.sourceItem]);
-const contact = computed(() => props.item.threads[0].contact == null ? null : sources.value[props.item.source].contacts[props.item.threads[0].contact])
+
+function getContact(thread: number) {
+ const contact = props.item.threads[thread].contact;
+ return contact == null ? undefined : sources.value[props.item.source].contacts[contact];
+}
function isSelected(thread: number | string) {
if (typeof thread === "string") {
diff --git a/src/components/Nav.vue b/src/components/Nav.vue
index 5ecd4af..e313d13 100644
--- a/src/components/Nav.vue
+++ b/src/components/Nav.vue
@@ -8,13 +8,13 @@
-
-
+
{{ Math.min(contact.count, 9) }}
-
-
+
{{ Math.min(contact.count, 9) }}
@@ -24,7 +24,7 @@
-
-
+
To Do
@@ -32,19 +32,19 @@
-
-
+
Low Priority
-
-
+
Garden
-
-
+
My messages
@@ -55,7 +55,7 @@
Sources
-
-
+
{{ source.name }}
@@ -67,19 +67,19 @@
-
-
+
Snoozed
-
-
+
Unsorted
-
-
+
Settings
@@ -94,11 +94,13 @@ import { faBars, faClock, faFaceSmile, faGear, faLeaf, faList, faListCheck, faSh
import { FontAwesomeIcon } from '@fortawesome/vue-fontawesome'
import { initFlowbite } from 'flowbite'
import { computed, onMounted } from 'vue'
-import { RouterLink } from 'vue-router'
+import { RouterLink, useRoute } from 'vue-router'
import type { ContactStatus } from "../state"
import { categories, favorites, sources, todoItems, urgentItems } from '../state'
import Avatar from "./Avatar.vue"
+const route = useRoute();
+
onMounted(() => {
initFlowbite();
});
diff --git a/src/components/PanelTitle.vue b/src/components/PanelTitle.vue
new file mode 100644
index 0000000..92d2820
--- /dev/null
+++ b/src/components/PanelTitle.vue
@@ -0,0 +1,18 @@
+
+
{{ title }}
+
+
+
+
+
diff --git a/src/components/Thread.vue b/src/components/Thread.vue
index 90a0b30..1d17843 100644
--- a/src/components/Thread.vue
+++ b/src/components/Thread.vue
@@ -1,31 +1,31 @@
-
-
-
-
-
-
-
- {{ event.message }}
- {{ sourceObj.contacts[event.contact].name }}
-
+
+
+
+
+
+
+ {{ event.message }}
+ {{ sourceObj.contacts[event.contact].name }}
-
- {{ event.message }}
-
-
-
- {{ sourceObj.contacts[event.contact].name }} created a new thread called "{{ item.threads[event.thread].title }}"
+
+
+ {{ event.message }}
-
-
+
+ {{ sourceObj.contacts[event.contact].name }} created a new thread called "{{ item.threads[event.thread].title }}"
+
+
+