From 67727f96aba96b6f4da0a6ad4e323e2f1ad26264 Mon Sep 17 00:00:00 2001 From: Anbraten Date: Fri, 7 Aug 2026 12:57:45 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20fix=20typecheck=20and=20cleanup?= =?UTF-8?q?=20imports?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/components/AddExpenseForm.vue | 2 +- app/components/BalanceSummary.vue | 2 +- app/components/ExpenseList.vue | 2 +- app/pages/p/[slug]/settings.vue | 32 +- package.json | 18 +- pnpm-lock.yaml | 2997 +++++++++-------- server/api/pots.post.ts | 6 +- server/api/pots/[slug].get.ts | 2 +- server/api/pots/[slug]/expenses.post.ts | 6 +- .../api/pots/[slug]/expenses/[id].delete.ts | 4 +- server/api/pots/[slug]/expenses/[id].patch.ts | 4 +- server/api/pots/[slug]/participants.post.ts | 4 +- .../pots/[slug]/participants/[id].delete.ts | 25 + .../pots/[slug]/participants/[id].patch.ts | 6 +- server/api/pots/[slug]/payments.post.ts | 6 +- shared/utils/balances.ts | 4 +- test/api/pots.test.ts | 22 + 17 files changed, 1790 insertions(+), 1352 deletions(-) create mode 100644 server/api/pots/[slug]/participants/[id].delete.ts diff --git a/app/components/AddExpenseForm.vue b/app/components/AddExpenseForm.vue index 0c499f8..b0e0d3f 100644 --- a/app/components/AddExpenseForm.vue +++ b/app/components/AddExpenseForm.vue @@ -15,7 +15,7 @@ const emit = defineEmits<{ const description = ref(props.editing?.description ?? '') const amount = ref(props.editing ? fromCents(props.editing.amountCents).toString() : '') -const payerId = ref(props.editing?.payerId ?? props.defaultPayerId ?? props.participants[0]?.id) +const payerId = ref(props.editing?.payerId ?? props.defaultPayerId ?? props.participants[0]!.id) const selectedIds = ref(props.editing?.participantIds ?? props.participants.map(p => p.id)) const error = ref('') diff --git a/app/components/BalanceSummary.vue b/app/components/BalanceSummary.vue index c6c8074..7ce2e09 100644 --- a/app/components/BalanceSummary.vue +++ b/app/components/BalanceSummary.vue @@ -1,6 +1,6 @@