On a MULTI_WINNER_MILESTONE bounty, the sidebar CTA shows an "Apply for Slot [Coming soon]" button that runs a stub click handler. Contributors can't actually apply for a slot, and the slot counter on the bounty card never moves.
We need a real apply action that increments the slot occupancy and adds the contributor to the milestone funnel.
What to do
Add a useApplyForSlot mutation in hooks/use-bounty-application.ts accepting bountyId and applicantAddress. Optimistically:
- Increment
totalSlotsOccupied on the bounty detail in the cache
- Append the applicant to
contributorProgress at the first milestone
- Roll back on error
In components/bounty-detail/bounty-detail-sidebar-cta.tsx (both SidebarCTA and MobileCTA), replace the stub click handler with a call to the new mutation. Drop the [Coming soon] suffix from the button label and disable the button only when the slot count is full, the user is already in contributorProgress, or the session doesn't have a wallet address.
Acceptance criteria
- Eligible contributor can click Apply for Slot and join the bounty
totalSlotsOccupied / maxSlots count on the sidebar and the bounty card reflects the new count after applying
- Contributor's avatar appears in the milestone funnel
- Button reads "Slots Full" and disables when the bounty is at capacity
- Button reads "Already Joined" and disables for an applicant already in the bounty
Files
components/bounty-detail/bounty-detail-sidebar-cta.tsx
hooks/use-bounty-application.ts
On a
MULTI_WINNER_MILESTONEbounty, the sidebar CTA shows an "Apply for Slot [Coming soon]" button that runs a stub click handler. Contributors can't actually apply for a slot, and the slot counter on the bounty card never moves.We need a real apply action that increments the slot occupancy and adds the contributor to the milestone funnel.
What to do
Add a
useApplyForSlotmutation inhooks/use-bounty-application.tsacceptingbountyIdandapplicantAddress. Optimistically:totalSlotsOccupiedon the bounty detail in the cachecontributorProgressat the first milestoneIn
components/bounty-detail/bounty-detail-sidebar-cta.tsx(bothSidebarCTAandMobileCTA), replace the stub click handler with a call to the new mutation. Drop the[Coming soon]suffix from the button label and disable the button only when the slot count is full, the user is already incontributorProgress, or the session doesn't have a wallet address.Acceptance criteria
totalSlotsOccupied / maxSlotscount on the sidebar and the bounty card reflects the new count after applyingFiles
components/bounty-detail/bounty-detail-sidebar-cta.tsxhooks/use-bounty-application.ts