shadcn.io is not affiliated with official shadcn/ui
Expired Invitation Error Block for React
A full-screen page for an expired team invitation: the invitation drawn as a pass in a card in a card with an Expired stamp, its code with a Copy button, and an Ask for a new invite button that honestly sends nothing.
Installation
Overview
Say clearly who can fix an expired invitation, with this invitation expired page for React with Base UI. It's the screen Wrenhouse, a team workspace, shows to someone who opens an old invitation: the page's two side rails run its full height and one band crosses the screen between two rules with a plus mark where each meets a rail, split in two. At the start, the heading, one sentence saying how long ago the invitation ended and that only the person who sent it can send another, and the Shine Button Ask Imogen for a new invite, the only coloured control. At the end, in a card in a card made with Frame, the invitation drawn as a pass: the team, who invited you, the day it was sent, the day it ended with "3 days ago", and its code with a Copy Button. A Stamp Text "Expired" lands on the pass once, character by character, in a zone of its own so it never covers a word. The rules come from Guides, and the entrance is CSS only. For team, workspace and shared-document invitations.
FAQ
What does Ask for a new invite do, and what stays in the page?
Nothing leaves the page. Pressing it shows a spinner on the button for under a second, then a polite status line says that a request would go to the inviter and that nothing was sent in this demo; asking again says how many times and that a real page sends one request and then waits. To wire it for real, send the inviter a request (an email or an in-app notification) from ask, and keep the button's busy state until your server answers.
Is the Copy button real?
Yes. It writes the code to the clipboard and a polite line says "Copied code INV-2026-ABC123". If the browser refuses (no permission, or a page that isn't served over HTTPS) the button shows a cross and announces that it couldn't copy. The code is a typed constant, a sample, not a real invitation.
Where do the dates and the day count come from?
From typed ISO dates in the file: when the invitation was sent and when it ended, with one AS_OF day standing in for today. "3 days ago" and "valid 7 days" are worked out from them with UTC day numbers, so the page reads the same on the server and in every time zone, and nothing reads the clock. In your app, use the invitation's real dates and the server's date.
What happens to the stamp with reduced motion?
The stamp animation is CSS and runs once; with reduced motion the word is simply there, still tilted. The stamp is decoration (hidden from assistive technology): the list on the pass says "Expired" with its date in text, and the heading says it in words.
Why do invitations expire at all?
An invitation is a credential: anyone who has the link can join the team, so it shouldn't work forever. Seven days is a common balance. The page doesn't say who else is invited or how many seats are free, because that would tell a stranger things about the team; it names only the team and the inviter, who already sent it to this person.
Related
- Pro
Expired Link Error
Sign-in and identityA full-screen page for an expired password-reset link: the link's life drawn on a time axis, the facts in words, and an Email me a new link button that hands its place to a 30-second cooldown.
- Pro
Seats Full Error
Plans and checkoutA panel for an invite that can't go out because every seat is taken: six seat cells, two inactive members to remove, and one button that reads Add seats until a seat is free and then Send the invite.
- Pro
Email Not Verified Error
Sign-in and identityA full-screen page for an unconfirmed email: a drawn mail list with Inbox, Spam and Promotions tabs showing where the message hides, an I've confirmed it button, a Resend the email button with a 30-second wait and a Change email field.
- Pro
Account Suspended Error
Locked and removedA full-screen page for a suspended seller account: the reason, the day and a copyable reference, a Submit an appeal button that opens a Dialog with a note field, and a read-only Steps list that moves to Appeal sent.
- Pro
Invite Accepted Roster Success
People and approvalsA confirmation page for a teammate joining: who invited them and when, how many seats are used, and a roster where the new member's row is marked Joined and holds a role select that changes the role sentence below.
- 43Pro
403 Forbidden Error
Locked and removedA full-screen 403 page for a team wiki: a door drawn as the zero of 403, the heading 'Ask someone who can say yes', the three workspace admins in a framed list with a Copy email button each, and a way back to the wiki.