Repository navigation
feat(campaigns): add backer-only exclusive content area on campaign pages - #1280
AugistineCreates wants to merge 2 commits into
Conversation
|
@AugistineCreates Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configuration
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Utilitycoder
left a comment
There was a problem hiding this comment.
Please fix up the merge conflict and update your PR. Kindly ensure you offramp with Fundable at https://stellar.fundable.finance/offramp
fixed, please review |
Summary
Adds a backer-only exclusive content area on campaign pages that allows campaign creators to publish rich-text updates and downloadable file attachments visible only to verified backers.
Closes #1267
Changes
apps/web/src/types/campaign-exclusive-content.ts):ExclusiveContentPost,ExclusiveContentAttachment,PledgeGateStatus, and helper functions (formatFileSize,deriveTeaserFromRichText).apps/web/src/services/campaign-exclusive-content.service.ts):checkPledgeStatusto verify whether a viewer is the campaign creator or has a positive verified contribution recorded for the campaign (with optional per-postminPledgeAmountthresholds).publishPost,deletePost, andgetFeedso verified backers and creators receive fullrichTextContentand attachmentdownloadUrls, while non-backers receive locked posts with redacted bodies/download URLs and teaser text preserved.apps/web/src/hooks/use-campaign-exclusive-content.ts,apps/web/src/app/api/campaigns/[id]/exclusive-content/route.ts):useCampaignExclusiveContenthook andGET/POST/DELETEhandlers at/api/campaigns/[id]/exclusive-content.apps/web/src/components/modules/campaign/exclusive-content/BackerExclusiveContent.tsx,apps/web/src/app/(overview)/campaigns/[id]/page.tsx,apps/web/src/app/campaigns/[id]/page.tsx):blur-sm) with a lock overlay and a Pledge to Unlock CTA linking to/campaigns/[id]/donate.apps/web/src/services/campaign-exclusive-content.service.test.ts), API route tests (apps/web/src/app/api/campaigns/[id]/exclusive-content/route.test.ts), and component tests (apps/web/src/components/modules/campaign/exclusive-content/BackerExclusiveContent.test.tsx).Acceptance Criteria Checklist