Skip to content

feat: add gated content access check UI on key detail page - #1217

Merged
Chucks1093 merged 1 commit into
accesslayerorg:devfrom
Ecruise-hub:feat/issue-1207-implement-content-gating-access-check-ui-on-key
Oct 21, 2026
Merged

Chucks1093 merged 1 commit into
accesslayerorg:devfrom
Ecruise-hub:feat/issue-1207-implement-content-gating-access-check-ui-on-key

Conversation

@Ecruise-hub

Copy link
Copy Markdown
Contributor

Overview

This PR adds a Gated Content section to the key detail page that checks wallet access eligibility against the configured gate type and renders either a locked state (with the requirement and a CTA to unlock) or the unlocked content cards for eligible wallets.

Related Issue

Changes

🔒 Gated Content Access UI

  • [ADD] src/components/common/SubscriptionAccessGate.tsx

    • Renders the gated content section with gate type display (Holder Required / Subscriber Required / Threshold (X tokens)).
    • Locked state for ineligible wallets showing the requirement and a CTA (Buy Key / Subscribe) per gate type.
    • Unlocked state showing content cards for eligible wallets.
    • Runs the check_access contract call on wallet connect and disconnect.
  • [ADD] src/components/common/KeyDetailPageErrorBoundary.tsx

    • Error boundary wrapping the key detail page so a failed access check or gate render does not break the page.
  • [MODIFY] src/components/common/AnnouncementFeed.tsx

    • Adjusted so the gated content section renders below announcements on KeyDetail, and no gated section is shown for keys with no gate configured.

Verification Results

Manual verification on KeyDetail:
✅ Locked state shows accurate requirement per gate type
✅ CTA navigates to buy or subscribe flow per gate type
✅ Unlocked state shows content cards for eligible wallets
✅ Access check re-runs on wallet connect and disconnect
✅ No gated content section rendered for keys with no gate configured
Acceptance Criteria Status
Locked state shown correctly with accurate requirement for each gate type ✅ Gate type and threshold rendered from gate config
CTA navigates correctly to buy or subscribe flow per gate type ✅ CTA target selected by gate type
Unlocked state shows content correctly for eligible wallets ✅ Content cards rendered when check_access returns eligible
Access check runs correctly on wallet connect and disconnect ✅ check_access re-invoked on wallet state change
No gated content section shown for keys with no gate configured ✅ Section omitted when no gate is set

Closes #1207

@drips-wave

drips-wave Bot commented Oct 20, 2026

Copy link
Copy Markdown

@Ecruise-hub 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! 🚀

Learn more about application limits

@Chucks1093
Chucks1093 merged commit ffc8258 into accesslayerorg:dev Oct 21, 2026
1 check passed
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.

Implement content gating access check UI on key detail page

2 participants