From 01e46e8ebf46ced6565b16abb4e042b5040de9fb Mon Sep 17 00:00:00 2001 From: Santiago Nahuel de la Fuente Date: Mon, 18 Aug 2025 10:40:11 -0300 Subject: [PATCH] feat: add smooth scrolling to rewards tab on donate button click --- src/components/project/Card.svelte | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/components/project/Card.svelte b/src/components/project/Card.svelte index 9014a9be..0af3ab82 100644 --- a/src/components/project/Card.svelte +++ b/src/components/project/Card.svelte @@ -23,6 +23,16 @@ accountingBalance.balance?.amount !== undefined && project.budget?.minimum?.money?.amount !== undefined && Number(accountingBalance.balance.amount) - Number(project.budget.minimum.money.amount) > 0; + + function scrollToRewards() { + const rewardsElement = document.getElementById("tab-rewards"); + if (rewardsElement) { + rewardsElement.scrollIntoView({ + behavior: "smooth", + block: "start", + }); + } + }