diff options
| author | Adam Soltys <[email protected]> | 2024-11-29 21:31:25 -0800 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2024-11-29 21:31:25 -0800 |
| commit | 644d7963b8d108304ba75bb87cacadab66199feb (patch) | |
| tree | 5dcffee7b489f193dd7ff4ae234f5f1d9c356fab /src/routes | |
| parent | c43d415f3b473367b5de44fd0719241961cb740d (diff) | |
| download | coinos-ui-644d7963b8d108304ba75bb87cacadab66199feb.tar.gz coinos-ui-644d7963b8d108304ba75bb87cacadab66199feb.zip | |
try service worker again
Diffstat (limited to 'src/routes')
| -rw-r--r-- | src/routes/(app)/+layout.svelte | 2 | ||||
| -rw-r--r-- | src/routes/(app)/invoice/[id]/memo/+page.svelte | 1 | ||||
| -rw-r--r-- | src/routes/(app)/invoice/[id]/tip/+page.svelte | 2 | ||||
| -rw-r--r-- | src/routes/(app)/payments/[...page]/+page.server.ts | 4 | ||||
| -rw-r--r-- | src/routes/(app)/payments/[...page]/+page.svelte | 21 |
5 files changed, 15 insertions, 15 deletions
diff --git a/src/routes/(app)/+layout.svelte b/src/routes/(app)/+layout.svelte index ba838488..d2644443 100644 --- a/src/routes/(app)/+layout.svelte +++ b/src/routes/(app)/+layout.svelte @@ -17,7 +17,7 @@ import LoadingSplash from "$comp/LoadingSplash.svelte"; import AppHeader from "$comp/AppHeader.svelte"; import Password from "$comp/Password.svelte"; - import { getCookie, warning, protectedRoutes } from "$lib/utils"; + import { getCookie, warning } from "$lib/utils"; import { t, locale, loading } from "$lib/translations"; import { goto, afterNavigate, preloadData } from "$app/navigation"; diff --git a/src/routes/(app)/invoice/[id]/memo/+page.svelte b/src/routes/(app)/invoice/[id]/memo/+page.svelte index 02f4a5d9..e5bc8a18 100644 --- a/src/routes/(app)/invoice/[id]/memo/+page.svelte +++ b/src/routes/(app)/invoice/[id]/memo/+page.svelte @@ -10,7 +10,6 @@ f, sat, get, - reverseFormat, s, sats, } from "$lib/utils"; diff --git a/src/routes/(app)/invoice/[id]/tip/+page.svelte b/src/routes/(app)/invoice/[id]/tip/+page.svelte index 4431b17d..1c651163 100644 --- a/src/routes/(app)/invoice/[id]/tip/+page.svelte +++ b/src/routes/(app)/invoice/[id]/tip/+page.svelte @@ -3,7 +3,7 @@ import { browser } from "$app/environment"; import { invoice as inv, request } from "$lib/store"; - import { copy, focus, f, sat, get, reverseFormat, s, sats } from "$lib/utils"; + import { copy, focus, f, sat, get, s, sats } from "$lib/utils"; import Icon from "$comp/Icon.svelte"; import Slider from "$comp/Slider.svelte"; import { goto } from "$app/navigation"; diff --git a/src/routes/(app)/payments/[...page]/+page.server.ts b/src/routes/(app)/payments/[...page]/+page.server.ts index 6b9f47e2..153615b1 100644 --- a/src/routes/(app)/payments/[...page]/+page.server.ts +++ b/src/routes/(app)/payments/[...page]/+page.server.ts @@ -1,6 +1,6 @@ import { auth, get, str } from "$lib/utils"; -const limit = 5; +const limit = 10; export async function load({ cookies, depends, params }) { depends("app:payments"); @@ -30,9 +30,7 @@ export async function load({ cookies, depends, params }) { auth(cookies), ); - console.log("payments", payments.length); const pages = new Array(Math.ceil(count / limit)); - console.log("pages", pages); return { payments, page, pages, start, end, incoming, outgoing }; } diff --git a/src/routes/(app)/payments/[...page]/+page.svelte b/src/routes/(app)/payments/[...page]/+page.svelte index 5625c8de..0a33840e 100644 --- a/src/routes/(app)/payments/[...page]/+page.svelte +++ b/src/routes/(app)/payments/[...page]/+page.svelte @@ -57,12 +57,9 @@ ]); let selection = $derived( - start - ? presets.findIndex( - (p) => - Math.abs(differenceInDays(new Date(start * 1000), p.start)) < 1, - ) - : 0, + presets.findIndex( + (p) => Math.abs(differenceInDays(new Date(start * 1000), p.start)) < 1, + ), ); $effect(() => { @@ -312,7 +309,9 @@ <span class="text-base text-secondary"> {#if tipsIn || tipsOut}{$t("payments.tips")}{/if} </span> - <span class="text-base text-secondary text-right">{$t("payments.total")}</span> + <span class="text-base text-secondary text-right" + >{$t("payments.total")}</span + > {@const totalIn = incoming[c]?.fiat || 0} {@const tipsIn = incoming[c]?.fiatTips || 0} @@ -327,14 +326,18 @@ > <!-- <span><b>{subtotalIn ? f(subtotalIn, c) : "-"}</b></span> --> <span><b>{tipsIn > 0 ? f(tipsIn, c, userLocale) : "-"}</b></span> - <span class="text-right"><b>{totalIn > 0 ? f(totalIn, c, userLocale) : "-"}</b></span> + <span class="text-right" + ><b>{totalIn > 0 ? f(totalIn, c, userLocale) : "-"}</b></span + > <span class="text-left text-base text-secondary" >{$t("payments.expenditure")}</span > <!-- <span><b>{subtotalOut ? f(subtotalOut, c) : "-"}</b></span> --> <span><b>{tipsOut > 0 ? f(tipsOut, c, userLocale) : "-"}</b></span> - <span class="text-right"><b>{totalOut > 0 ? f(totalOut, c, userLocale) : "-"}</b></span> + <span class="text-right" + ><b>{totalOut > 0 ? f(totalOut, c, userLocale) : "-"}</b></span + > {/each} </div> </div> |
