Repository navigation
Add invite list UI showing registration link status and usage - #53
Merged
Merged
Conversation
Lists the links the registration bot generated for the current user, with each one's status (not used yet / in progress / used by whom / expired / revoked), using the bot's GET /api/invites from HelloAOLab/matrix-bots#48. The list reloads after a new link is minted. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018uEeWQpUstXyDM2hVAD2X8
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Adds support for listing and displaying registration invite links generated by the bot, showing their status (unused, pending, used, expired, revoked) and usage details.
Changes:
Backend API integration (
registration-bot.ts):/api/invitesendpoint (PR Support jumping to events in notifications and inbox links #48)RegistrationInvitetype with token hash, status, client ID, timestamps, and registration detailsrequestRegistrationInvites()function to fetch invites for the current user (or another user for admins)UI components (
InviteFlow.tsx):InviteListcomponent displaying invites newest-first with status badgesStyling (
InviteFlow.css.ts):Helper utilities (
inviteList.ts):describeInvite()— formats invite status with human-readable labels and detailssummarizeInvites()— generates summary text like "2 invites · 1 used"React hook (
useRegistrationInvites.ts):useRegistrationInvites()hook that loads invites on mount and provides arefresh()callbackTests:
inviteList.test.tscoveringdescribeInvite()andsummarizeInvites()with all status typesregistration-bot.test.tstests for URL building, response parsing, and HTTP request handlingFixes the registration flow to show users the history and status of invitation links they've created.
Checklist:
https://claude.ai/code/session_018uEeWQpUstXyDM2hVAD2X8