From 6cc9f70a4a03d3a0c23ce2f2d430a28e5a19760e Mon Sep 17 00:00:00 2001 From: Till-JS <101404291+Till-JS@users.noreply.github.com> Date: Tue, 2 Dec 2025 14:42:01 +0100 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20feat(contacts):=20add=20archive,=20?= =?UTF-8?q?favorites,=20groups,=20and=20feedback=20pages?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Add feedback service and route - Add archive page for deleted contacts - Add favorites page for starred contacts - Add groups page for contact organization - Add mana integration page 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- .../apps/web/src/lib/services/feedback.ts | 14 + .../web/src/routes/(app)/archive/+page.svelte | 582 ++++++++++ .../src/routes/(app)/favorites/+page.svelte | 516 +++++++++ .../src/routes/(app)/feedback/+page.svelte | 7 + .../web/src/routes/(app)/groups/+page.svelte | 469 ++++++++ .../src/routes/(app)/groups/[id]/+page.svelte | 1023 +++++++++++++++++ .../src/routes/(app)/groups/new/+page.svelte | 540 +++++++++ .../web/src/routes/(app)/mana/+page.svelte | 39 + 8 files changed, 3190 insertions(+) create mode 100644 apps/contacts/apps/web/src/lib/services/feedback.ts create mode 100644 apps/contacts/apps/web/src/routes/(app)/archive/+page.svelte create mode 100644 apps/contacts/apps/web/src/routes/(app)/favorites/+page.svelte create mode 100644 apps/contacts/apps/web/src/routes/(app)/feedback/+page.svelte create mode 100644 apps/contacts/apps/web/src/routes/(app)/groups/+page.svelte create mode 100644 apps/contacts/apps/web/src/routes/(app)/groups/[id]/+page.svelte create mode 100644 apps/contacts/apps/web/src/routes/(app)/groups/new/+page.svelte create mode 100644 apps/contacts/apps/web/src/routes/(app)/mana/+page.svelte diff --git a/apps/contacts/apps/web/src/lib/services/feedback.ts b/apps/contacts/apps/web/src/lib/services/feedback.ts new file mode 100644 index 000000000..95dc1656d --- /dev/null +++ b/apps/contacts/apps/web/src/lib/services/feedback.ts @@ -0,0 +1,14 @@ +/** + * Feedback Service Instance for Contacts Web App + */ + +import { createFeedbackService } from '@manacore/shared-feedback-service'; +import { authStore } from '$lib/stores/auth.svelte'; + +const MANA_AUTH_URL = 'http://localhost:3001'; + +export const feedbackService = createFeedbackService({ + apiUrl: MANA_AUTH_URL, + appId: 'contacts', + getAuthToken: async () => authStore.getAccessToken(), +}); diff --git a/apps/contacts/apps/web/src/routes/(app)/archive/+page.svelte b/apps/contacts/apps/web/src/routes/(app)/archive/+page.svelte new file mode 100644 index 000000000..03e4744ae --- /dev/null +++ b/apps/contacts/apps/web/src/routes/(app)/archive/+page.svelte @@ -0,0 +1,582 @@ + + + + Archiv - Contacts + + +
+ +
+ + + + + +

Archiv

+
+ + + +
+
+ + + {#if contacts.length > 0} +
+ + + + +
+ {/if} + + {#if error} + + {/if} + + {#if loading} +
+
+
+ {:else if contacts.length === 0} +
+
+ + + +
+

Archiv ist leer

+

Archivierte Kontakte erscheinen hier. Du kannst sie später wiederherstellen oder endgültig löschen.

+ + + + + Zu Kontakten + +
+ {:else if filteredContacts().length === 0} +
+
+ + + +
+

Keine Ergebnisse

+

Keine archivierten Kontakte gefunden fĂĽr "{searchQuery}"

+
+ {:else} +
+ + + + Archivierte Kontakte können wiederhergestellt oder endgültig gelöscht werden. +
+ +
+ {#each filteredContacts() as contact (contact.id)} +
handleContactClick(contact.id)} + onkeydown={(e) => e.key === 'Enter' && handleContactClick(contact.id)} + class="contact-card" + > + +
+ {#if contact.photoUrl} + {getDisplayName(contact)} + {:else} + {getInitials(contact)} + {/if} +
+ + +
+

{getDisplayName(contact)}

+ {#if contact.company || contact.jobTitle} +

+ {[contact.jobTitle, contact.company].filter(Boolean).join(' @ ')} +

+ {/if} + {#if contact.email} +

{contact.email}

+ {/if} +
+ + +
+ + +
+
+ {/each} +
+ +

{contacts.length} archiviert{contacts.length !== 1 ? 'e Kontakte' : 'er Kontakt'}

+ {/if} +
+ + diff --git a/apps/contacts/apps/web/src/routes/(app)/favorites/+page.svelte b/apps/contacts/apps/web/src/routes/(app)/favorites/+page.svelte new file mode 100644 index 000000000..34e345244 --- /dev/null +++ b/apps/contacts/apps/web/src/routes/(app)/favorites/+page.svelte @@ -0,0 +1,516 @@ + + + + Favoriten - Contacts + + +
+ +
+ + + + + +

Favoriten

+
+ + + +
+
+ + +
+ + + + +
+ + {#if error} + + {/if} + + {#if loading} +
+
+
+ {:else if contacts.length === 0} +
+
+ + + +
+

Keine Favoriten

+

Markiere Kontakte als Favoriten, um sie hier schnell zu finden.

+ + + + + Zu Kontakten + +
+ {:else if filteredContacts().length === 0} +
+
+ + + +
+

Keine Ergebnisse

+

Keine Favoriten gefunden fĂĽr "{searchQuery}"

+
+ {:else} +
+ {#each filteredContacts() as contact (contact.id)} +
handleContactClick(contact.id)} + onkeydown={(e) => e.key === 'Enter' && handleContactClick(contact.id)} + class="contact-card" + > + +
+ {#if contact.photoUrl} + {getDisplayName(contact)} + {:else} + {getInitials(contact)} + {/if} +
+ + +
+

{getDisplayName(contact)}

+ {#if contact.company || contact.jobTitle} +

+ {[contact.jobTitle, contact.company].filter(Boolean).join(' @ ')} +

+ {/if} + {#if contact.email} +

{contact.email}

+ {/if} +
+ + + +
+ {/each} +
+ +

{contacts.length} Favorit{contacts.length !== 1 ? 'en' : ''}

+ {/if} +
+ + diff --git a/apps/contacts/apps/web/src/routes/(app)/feedback/+page.svelte b/apps/contacts/apps/web/src/routes/(app)/feedback/+page.svelte new file mode 100644 index 000000000..fc6901f85 --- /dev/null +++ b/apps/contacts/apps/web/src/routes/(app)/feedback/+page.svelte @@ -0,0 +1,7 @@ + + + diff --git a/apps/contacts/apps/web/src/routes/(app)/groups/+page.svelte b/apps/contacts/apps/web/src/routes/(app)/groups/+page.svelte new file mode 100644 index 000000000..512e69ca5 --- /dev/null +++ b/apps/contacts/apps/web/src/routes/(app)/groups/+page.svelte @@ -0,0 +1,469 @@ + + + + Gruppen - Contacts + + +
+ +
+ + + + + +

Gruppen

+ + + + + +
+ + +
+ + + + +
+ + {#if error} + + {/if} + + {#if loading} +
+
+
+ {:else if groups.length === 0} +
+
+ + + +
+

Keine Gruppen

+

Erstelle deine erste Gruppe um Kontakte zu organisieren.

+ + + + + Neue Gruppe + +
+ {:else if filteredGroups().length === 0} +
+
+ + + +
+

Keine Ergebnisse

+

Keine Gruppen gefunden fĂĽr "{searchQuery}"

+
+ {:else} +
+ {#each filteredGroups() as group (group.id)} +
handleGroupClick(group.id)} + onkeydown={(e) => e.key === 'Enter' && handleGroupClick(group.id)} + class="group-card" + > +
+
+

{group.name}

+ {#if group.description} +

{group.description}

+ {/if} +
+
+ + + + +
+
+ {/each} +
+ +

{groups.length} Gruppe{groups.length !== 1 ? 'n' : ''}

+ {/if} +
+ + diff --git a/apps/contacts/apps/web/src/routes/(app)/groups/[id]/+page.svelte b/apps/contacts/apps/web/src/routes/(app)/groups/[id]/+page.svelte new file mode 100644 index 000000000..d79133980 --- /dev/null +++ b/apps/contacts/apps/web/src/routes/(app)/groups/[id]/+page.svelte @@ -0,0 +1,1023 @@ + + + + {group?.name || 'Gruppe'} - Contacts + + +
+ +
+ + + + + +

{isEditing ? 'Gruppe bearbeiten' : (group?.name || 'Gruppe')}

+ {#if !loading && group && !isEditing} + + {:else} +
+ {/if} +
+ + {#if loading} +
+
+
+ {:else if error && !group} +
+
+ + + +
+

Fehler

+

{error}

+ ZurĂĽck zu Gruppen +
+ {:else if group} + {#if error} + + {/if} + + {#if isEditing} + +
+
+ + + +
+

{name || 'Gruppenname'}

+
+ +
{ e.preventDefault(); handleSave(); }} class="form"> +
+
+
+ + + +
+

Details

+
+
+ + +
+
+ + +
+
+ +
+
+
+ + + +
+

Farbe

+
+
+ {#each presetColors as presetColor} + + {/each} +
+
+ +
+ + +
+
+ + + + {:else} + +
+
+ + + +
+

{group.name}

+ {#if group.description} +

{group.description}

+ {/if} +
+ + +
+
+
+ + + +
+

Kontakte ({groupContacts().length})

+ +
+ + {#if groupContacts().length === 0} +

Keine Kontakte in dieser Gruppe

+ {:else} +
+ {#each groupContacts() as contact (contact.id)} +
+
+ {#if contact.photoUrl} + {getDisplayName(contact)} + {:else} + {getInitials(contact)} + {/if} +
+
+ {getDisplayName(contact)} + {#if contact.email} + {contact.email} + {/if} +
+ +
+ {/each} +
+ {/if} +
+ {/if} + {/if} +
+ + +{#if showAddContacts} + +{/if} + + diff --git a/apps/contacts/apps/web/src/routes/(app)/groups/new/+page.svelte b/apps/contacts/apps/web/src/routes/(app)/groups/new/+page.svelte new file mode 100644 index 000000000..7f6ea913e --- /dev/null +++ b/apps/contacts/apps/web/src/routes/(app)/groups/new/+page.svelte @@ -0,0 +1,540 @@ + + + + Neue Gruppe - Contacts + + +
+ +
+ + + + + +

Neue Gruppe

+
+
+ + +
+
+ + + +
+

{name || 'Neue Gruppe'}

+ {#if description} +

{description}

+ {/if} +
+ + {#if error} + + {/if} + +
{ e.preventDefault(); handleSubmit(); }} class="form"> + +
+
+
+ + + +
+

Gruppenname

+
+
+ + +
+
+ + +
+
+ + +
+
+
+ + + +
+

Farbe

+
+
+ {#each presetColors as presetColor} + + {/each} +
+
+ +
+ + +
+
+
+ + +
+ + Abbrechen + + +
+
+
+ + diff --git a/apps/contacts/apps/web/src/routes/(app)/mana/+page.svelte b/apps/contacts/apps/web/src/routes/(app)/mana/+page.svelte new file mode 100644 index 000000000..63b883afb --- /dev/null +++ b/apps/contacts/apps/web/src/routes/(app)/mana/+page.svelte @@ -0,0 +1,39 @@ + + + + Mana - Contacts + + +
+ +
+ +