Skip to content

fix: add amount input and validation to MilestoneFundButton (#83) - #169

Open
rafaio1 wants to merge 1 commit into
MergeFi:mainfrom
rafaio1:fix/83-milestone-partial-funding
Open

fix: add amount input and validation to MilestoneFundButton (#83)#169
rafaio1 wants to merge 1 commit into
MergeFi:mainfrom
rafaio1:fix/83-milestone-partial-funding

Conversation

@rafaio1

@rafaio1 rafaio1 commented Aug 20, 2026

Copy link
Copy Markdown

Fixes #83.

  • Add an amount input field to MilestoneFundButton, mirroring the existing pattern in PoolDepositButton within the same file.
  • Validate the entered amount before submission: rejects empty, non-finite, zero, negative, and over-precision (>7 decimals) values client-side.
  • Include the validated amount in the POST /milestones/:id/fund request body alongside funderAddress. Previously, no amount was sent at all, making partial funding impossible from the UI despite the progress bar modeling incremental contributions.
  • Backend contract note: The fix assumes the backend endpoint accepts or requires an amount field (consistent with the maintenance pool deposit endpoint). If the current backend silently interprets a missing amount as 'fund entire remaining budget,' this change makes that behavior explicit and user-controlled rather than implicit.
  • TypeScript compiles cleanly with npx tsc --noEmit.

@vercel

vercel Bot commented Aug 20, 2026

Copy link
Copy Markdown

Someone is attempting to deploy a commit to the chonilius' projects Team on Vercel.

A member of the Team first needs to authorize it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

MilestoneFundButton has no amount input, making partial milestone funding impossible from the UI

1 participant