Skip to content
WingoUI
ComponentsTemplatesDocsPricingAI agentsBlogChangelogContact
Components
Buttons & Actions
ButtonButton GroupCopy ButtonDelete ButtonTheme ToggleToggleToggle Group
Inputs
Avatar UploadCalendarCheckboxColor PickerComboboxCountry SelectCron PickerCurrency InputDate PickerDate Range PickerDate Time PickerDuration PickerEmail InputEmoji PickerFile UploadFilter BuilderInputInput GroupListboxMasked InputMention InputMonth PickerMulti SelectNumber InputOTP InputPassword InputPhone InputRadio GroupRatingSearch InputSegmented ControlSelectSignature PadSliderSwitchTag InputTextareaTime PickerTimezone SelectTree Select
Forms
Address InputBooking WidgetCSV ImportFieldForm WizardInline EditInvoice line itemsRich Text EditorSchema Builder
Navigation
Back To TopBounce SidebarBreadcrumbCommand MenuGlobal SearchGooey NavHook SidebarNav MenuNav TabsPaginationProximity SidebarScroll ProgressSidebarStepsTable Of ContentsTabsTopbarUser MenuWorkspace Switcher
Overlays
Alert DialogContext MenuDialogDrawerDropdown MenuFamily DrawerHover CardPopoverShare DialogSheetShortcuts DialogTooltipTour
Feedback
AlertBannerCookie ConsentEmoji ReactionEmpty StateNotification BellNotification CenterProgressRoute ProgressSetup ChecklistSkeletonSpinnerToast
Data Display
Approval FlowAvatarBadgeCalendar ViewCode BlockComment ThreadContact cardCountdownDescription ListDiff ViewerFile ListFile managerFolderGanttJSON ViewerKbdLog ViewerMarkdownPresenceSchedulerTagTimelineTree View
Tables & Lists
Audit LogData TableDeal PipelineEditable GridKanbanListMembers tablePermissions MatrixTableTask ListVirtual List
Charts & Stats
Animated CounterArea chartBar chartDonut chartFunnel chartGaugeGitHub ActivityHeatmap calendarLeaderboardLine chartRadar chartRadial barSparklineStat CardTrackerTrend badge
Layout
AccordionApp ShellCardCollapsibleDetail LayoutEntity HeaderPage HeaderScroll AreaSeparatorSettings LayoutSplit ViewToolbar
Media
Audio PlayerCarouselCSV ViewerDOCX EditorDOCX ViewerExcel ViewerFile SystemImage compareImage CropperImage GalleryImage LightboxLocation MapPDF ViewerPowerPoint ViewerQR CodeStep PlayerVideo Player
AI Kit
Agent Status CardChat MessageChat ThreadChat WidgetConversation ListFluid OrbGrid RevealMatrix OrbModel PickerPrompt InputReasoning IndicatorRule BuilderSuggestion ChipsTool Call TimelineUsage MeterVoice InputWorkflow Canvas
Text & Effects
Background PatternGravity LettersMarqueeTerminalText AnimateText Rotate
Mobile
Action SheetBottom Tab BarFABHaptic ButtonHero HeaderInstall PromptLarge Title HeaderNotification BannerOnboarding CarouselPicker WheelPull To RefreshSlide To ConfirmSticky CTA BarSwipe DeckSwipeable Tabs
Commerce
Cart drawerCategory pickerCheckout stepsCoupon inputFavorite buttonFilter panelListing cardListing gridOrder trackerPricePrice rangePricing tableProduct galleryQuantity stepperReviewsSeller card
Marketing Sections
App Download SectionBlog Cards SectionCTA SectionFAQ SectionFeature GridFeature ShowcaseHero SectionIntegrations SectionLogo CloudMarketing FooterMarketing HeaderMarketing SectionNewsletter SectionPricing SectionStats SectionSteps SectionTeam SectionTestimonials SectionTimeline SectionVideo Section
Blocks
Admin Dashboard PageAdmin ShellAI Chat PageAPI Keys PageAutomation Builder PageCheckout PageCRM Contact PageCRM Pipeline PageError PagesInbox PageInvoice PageKPI DashboardListing Detail PageLogin PageMarketplace Home PageMarketplace Search PageMarketplace ShellMobile App HomeOnboarding FlowOrder History PagePost Listing WizardPricing PageProfile PageRegister PageSettings PageUsers Admin Page
Templates
About PageAcademy PageAccessibility PageAffiliate PageAgency PageAI Product PageAppointment Booking PageBlog PageBlog Post PageBug Bounty PageCareers PageChangelog PageCommunity PageCompare PageContact PageCustomer Story PageCustomers PageDemo Booking PageDevelopers PageDocs Home PageDownload PageEnterprise PageEvents PageExperts PageFAQ PageFeature PageGlossary PageHelp Article PageHelp Center PageHome Services PageImpact PageIntegration Detail PageIntegrations PageJob Detail PageLanding PageLaunch PageLegal PageManifesto PagePortfolio PagePress PageProduct Tour PagePromo PageReal Estate PageReferral PageResearch Report PageRestaurant PageRoadmap PageROI Calculator PageSecurity PageSolutions PageStartups PageStatus PageStorefront PageSwitch PageTemplate Gallery PageTravel PageWaitlist PageYear in Review Page
Hooks & Utilities
AI ChatChart kitCommerceDate utilsFile exportFile typesFiltersForm validationHapticsInvoicingMotion presetsNavigationNumber formatRelative timeRomanian locationsSpreadsheetText matchTonesUIProvideruseClipboarduseConsentuseControllableStateuseCooldownuseDebounceuseKeyboardInsetuseLocaleuseLongPressuseMediaControlsuseMediaQueryuseOverflowItemsusePersistedStateuseScrollEdgesuseScrollStateuseSelectionuseShortcutuseStickToBottom
GalleryTheme

Blocks

Users Admin Page

Blocks

Users Admin Page React block for Tailwind CSS v4

Settings PageAbout Page
Live props
Content
companyName
State
auditPeriodDays7
defaultTab
defaultInviteOpen
loading
Behavior
seatStep5
require2fa
canManage
saveShortcut
securityHref
locale
animateIn
Appearance
tone
radius
Code
import { UsersAdminPage } from "@/components/blocks/users-admin-page"

<UsersAdminPage />
  1. Home
  2. Components
  3. Blocks
  4. Users Admin Page
Pro

Users Admin Page React block for Tailwind CSS v4

v1.0.1·Updated in 1.9.0

A React users admin page: team members and invitations with seats, roles with a permissions matrix and a save bar, and the audit log.

The header shows the seats in use ("8 of 10 seats", turning amber from 80%), Invite people and a menu with Export members CSV (downloads a ; separated file that opens cleanly in Excel) and Security settings. Switch between Members, Roles and permissions and Audit log with a click or the arrow keys; the panel slides the way you went. In Members, a warning lists who has no two-step verification with Send reminder; search by name or email, sort by name, role or last activity, change a role in its picker (it saves with a spinner, a failure rolls back with a toast, and the last administrator cannot be demoted), remove someone from the row menu after a confirmation (you and the owner cannot be removed), and in Invitations resend or revoke an invitation. Invite people opens the invite dialog (a bottom sheet on phones): paste or type addresses, pick a role, add a message and send; addresses already in the team are refused. With every seat taken it first offers Add 5 seats. In Roles and permissions, pick a role card (or a column heading) to highlight it, create a role with New role (name, description, copy permissions from a role), and tick permissions in the matrix: requirements follow along, changed cells get a dot, and a save bar slides up with the count, Discard and Save (mod+s while it shows). Leaving the tab with unsaved changes asks first. On phones the matrix picks one role at a time with chips and the save bar floats above the edge. In Audit log, search, filter by user, action, record type, severity or IP, change the period, expand a row for its changes, and export the rows as CSV; your own changes on this page appear at the top. Toasts confirm each action. Sections rise in once on mount; reduced motion keeps them still.

Users Admin Page is a Pro React block in the React blocks category, written in TypeScript for React 19 and Tailwind CSS v4. It installs as source with npx wingo-ui@latest add users-admin-page, together with Alert, Alert Dialog, Audit Log, Avatar, Badge and 25 more and the npm packages motion and lucide-react.

Add to a project

Requirements: React 19 and Tailwind CSS v4, in Next.js (App Router or Pages), Vite or React Router. Installation guide · Next.js setup · Vite setup

npx wingo-ui@latest add users-admin-page

Users Admin Page is part of Pro, with 298 more Pro items: $8 a month or $150 once. 14-day refund before you download any Pro item. See plans

Usage

Import UsersAdminPage from @/components/blocks/users-admin-page.

// app/(admin)/team/page.tsx (the shell lives in app/(admin)/layout.tsx: <AdminShell>{children}</AdminShell>)
"use client"

import { UsersAdminPage } from "@/components/blocks/users-admin-page"

export default function TeamPage() {
  return (
    <UsersAdminPage
      companyName="Northwind Labs"
      onInvite={async ({ emails, role }) => {
        await fetch("/api/team/invitations", { method: "POST", body: JSON.stringify({ emails, role }) })
      }}
      onRoleChange={async (member, role) => {
        await fetch(`/api/team/${member.id}`, { method: "PATCH", body: JSON.stringify({ role }) })
      }}
      onPermissionsSave={async (permissions) => {
        await fetch("/api/roles", { method: "PUT", body: JSON.stringify(permissions) })
      }}
    />
  )
}

Props

  • companyNamedefault "Northwind Labs"
    string

    The workspace named in the description ("Manage who has access to Northwind Labs").

  • members
    MemberData[]

    The team; defaults to the eight people of Northwind Labs (USERS_ADMIN_SAMPLE.members). The member with isYou cannot change their own role or leave.

  • invites
    PendingInvite[]

    Pending invitations; defaults to USERS_ADMIN_SAMPLE.invites (one pending, one expired). Invitations that have not expired hold a seat.

  • roles
    MemberRole[]

    The roles a member can have: Administrator, Manager, Sales, Accounting, Read only (USERS_ADMIN_SAMPLE.roles).

  • permissionRoles
    PermissionRole[]

    The matrix's columns, same ids as roles; the locked Administrator holds every permission (USERS_ADMIN_SAMPLE.permissionRoles).

  • permissionGroups
    PermissionGroup[]

    Six groups (Clients, Deals, Invoices, Reports, Automations, Settings and team) with 4 to 6 permissions and their requirements (USERS_ADMIN_SAMPLE.permissionGroups).

  • permissions
    PermissionsValue

    The saved permissions, controlled (role id to granted permission ids); pair it with onPermissionsSave.

  • defaultPermissions
    PermissionsValue

    The saved permissions while uncontrolled; defaults to USERS_ADMIN_SAMPLE.permissions.

  • onPermissionsSave
    (value: PermissionsValue) => (void | Promise<unknown>)

    The save bar's Save (and mod+s). A promise keeps it saving; a rejection keeps the bar with its message. Default: a simulated request.

  • defaultPermissionsDraft
    PermissionsValue

    Edits already pending when the page opens (the save bar showing); USERS_ADMIN_SAMPLE.permissionsDraft has three.

  • onDirtyChange
    (dirty: boolean) => void

    The matrix differs from the saved value, or no longer does; hide a phone tab bar while true so one bar holds the bottom edge.

  • auditEvents
    AuditEvent[]

    The audit log, newest first; defaults to 120 events over the last 30 days (USERS_ADMIN_SAMPLE.auditEvents). Changes made on this page are added on top.

  • auditActions
    Record<string, AuditActionDef>

    Verb, tone, group and icon per action key; defaults to USERS_ADMIN_SAMPLE.auditActions with icons per key.

  • auditTargetTypes
    Record<string, string>

    Record type names for the filter and the export (member, role, client, invoice, deal, settings, login).

  • defaultAuditFilter
    FilterGroup

    The audit log's first filter; usersAdminAuditTypeFilter(["invoice"]) shows only invoices.

  • auditPeriodDaysdefault 7
    number

    The audit log's period on open: the last n days up to now; 0 shows all time.

  • seatsdefault "{ used: 8, total: 10 }"
    { used: number; total: number }

    Seats in the plan. Pending invitations reserve seats; with none free, inviting offers to add seats first.

  • seatStepdefault 5
    number

    How many seats "Add seats" adds to the plan.

  • tab
    "members" | "roles" | "audit"

    The open tab, controlled; pair it with onTabChange.

  • defaultTabdefault "members"
    "members" | "roles" | "audit"

    The tab open on mount while uncontrolled.

  • onTabChange
    (tab: UsersAdminTab) => void

    Called on a tab switch (after the unsaved changes question, when there is one).

  • require2fadefault true
    boolean

    The workspace requires two-step verification: members without it get a warning with Send reminder.

  • canManagedefault true
    boolean

    False is the read-only view: no invite, role changes, removals, new roles or matrix edits, and an info alert says why.

  • saveShortcutdefault "mod+s"
    string

    Saves the matrix while it has unsaved changes; "" turns the key off.

  • inviteOpen
    boolean

    The invite dialog, controlled (the shell's "Invite a teammate" command can open it).

  • defaultInviteOpendefault false
    boolean

    Opens the invite dialog on mount (the seats dialog when every seat is taken).

  • onInviteOpenChange
    (open: boolean) => void

    Called when the invite dialog opens or closes.

  • securityHrefdefault "/settings/security"
    string

    Where "Security settings" in the header menu goes.

  • onInvite
    (input: { emails: string[]; role: string; message?: string }) => (void | Promise<unknown>)

    Sends invitations; the page adds them to Invitations. Default: a simulated request.

  • onRoleChange
    (member: MemberData, role: string) => (void | Promise<unknown>)

    A member's new role; a rejection rolls the picker back and shows its message. The last administrator cannot be demoted.

  • onRemove
    (member: MemberData) => (void | Promise<unknown>)

    Removes a member after the confirmation; the seat frees up.

  • onResendInvite
    (invite: PendingInvite) => (void | Promise<unknown>)

    Sends an invitation again and restarts its seven days.

  • onRevokeInvite
    (invite: PendingInvite) => (void | Promise<unknown>)

    Revokes an invitation; a rejection brings the row back.

  • onRoleCreate
    (role: { name: string; description?: string; copyFrom?: string }) => (void | Promise<unknown>)

    Creates a role from the New role dialog; the page adds its column with the copied permissions. A rejection shows under the name.

  • onExport
    (members: MemberData[]) => (void | Promise<unknown>)

    Export members CSV. Default: downloads members-<date>.csv with ; separators and a byte order mark.

  • onRemindTwoFactor
    (members: MemberData[]) => (void | Promise<unknown>)

    Send reminder, with the members who have no two-step verification.

  • onAddSeats
    (count: number) => (void | Promise<unknown>)

    Adds seatStep seats from the seats dialog; then the invite form opens.

  • labelsdefault "DEFAULT_USERS_ADMIN_PAGE_LABELS"
    Partial<UsersAdminPageLabels>

    Every visible string, English by default (USERS_ADMIN_PAGE_LABELS_EN); USERS_ADMIN_PAGE_LABELS_RO is the Romanian set. Nested keys carry the composed items' strings (membersTable, permissionsMatrix, auditLog, auditFilters, auditPeriod, usageMeter).

  • localedefault "en-US"
    string

    Intl locale for numbers, dates and relative times.

  • now
    Date | number

    The reference time for last activity, invitations and the audit period; default the live clock.

  • tonedefault "neutral"
    "neutral" | "brand" | "success" | "warning" | "danger" | "info"

    Accent of the invite button, the tabs, the selected role, the checkboxes and the save bar.

  • radiusdefault "md"
    "sm" | "md" | "lg"

    Corner size of the role cards and the skeleton panels (12 / 16 / 24px).

  • loadingdefault false
    boolean

    Skeletons in the real layout: the header, the seats, the member rows, the role cards and the matrix.

  • animateIndefault true
    boolean

    The header and the panel rise in once when the page mounts on the client; off in thumbnails and under reduced motion.

  • linkComponentdefault "<a>"
    (props: LinkComponentProps) => ReactNode

    The router link for the header's links; default the surrounding LinkProvider's (the admin shell's).

  • className
    string

    Classes for the root.

  • classNames
    Partial<Record<UsersAdminPageSlot, string>>

    Classes for header, seats, panels, members, twoFactor, readOnly, roles, roleList, roleCard, permissions, saveBar, audit, seatsDialog and roleDialog.

Parts

  • DEFAULT_USERS_ADMIN_PAGE_LABELS

    constant

    Every English string of the members, roles and audit log tabs, the seats bar and the save bar. Spread it and override what you translate.

  • USERS_ADMIN_PAGE_LABELS_EN

    constant

    The English set that DEFAULT_USERS_ADMIN_PAGE_LABELS points to, kept so older imports keep working.

  • USERS_ADMIN_PAGE_LABELS_RO

    constant

    A ready Romanian set of every string. Pass it as labels for a Romanian back office.

  • generateUsersAdminSample

    function

    Builds the demo team in English or Romanian: members, invitations, seats, roles with their permissions and the audit log.

  • USERS_ADMIN_SAMPLE

    constant

    The English demo team built by generateUsersAdminSample. Replace it with data from your API.

  • usersAdminActor

    function

    Turns a member into the actor of an audit log entry (id, name, avatar).

  • usersAdminAuditTypeFilter

    function

    Builds a filter group of the audit log by record type (for example only invoices), with stable ids for server rendering.

  • USERS_ADMIN_NOW

    constant

    The fixed "now" of the sample (September 24, 2026, 4:40 PM) that last seen and log times are measured from.

Examples

Open

Roles with 3 unsaved changes

defaultPermissionsDraft: changed cells carry a dot and the save bar offers Discard and Save (mod+s).

Open

Audit log filtered to invoices

defaultTab="audit", a record type filter on Invoice and the last 30 days.

Open

Invite with every seat taken

8 members and 2 pending invitations fill 10 seats: inviting offers Add 5 seats first.

Open

Read only (Ryan Mitchell)

canManage={false}: no invite, fixed roles, a read-only matrix and an info alert.

Open

Loading

loading: the header, the seats, the rows and the matrix as skeletons.

Open

Brand tone, large radius

tone="brand", radius="lg" on the roles tab.

Open

Localized: Romanian

USERS_ADMIN_PAGE_LABELS_RO, locale="ro-RO" and generateUsersAdminSample("ro"): the same page for a Romanian workspace.

Dependencies

motionlucide-reactalertalert-dialogaudit-logavatarbadgebuttoncarddate-range-pickerdialogfilter-builderinputmembers-tablepage-headerpermissions-matrixselectsettings-layouttabstextareatoastusage-meteruse-controllable-statedate-utilsfile-exportfiltersmotionnavigationnumber-formatrelative-timetonesui-config

Files

  • components/blocks/users-admin-page.tsx
  • components/blocks/users-admin-page-data.ts

FAQ

Is the React Users Admin Page block free?

The preview, props and docs are free; copying the source needs a Pro plan. See plans.

How do I install Users Admin Page?

Run npx wingo-ui@latest add users-admin-page. It also adds the Wingo UI items it builds on (Alert, Alert Dialog, Audit Log, Avatar, Badge and 25 more) and the npm packages motion and lucide-react. With shadcn, add the @wingo-ui registry with your API key, then run npx shadcn@latest add @wingo-ui/users-admin-page.

How does Users Admin Page behave on phones?

Invite people opens the invite dialog (a bottom sheet on phones): paste or type addresses, pick a role, add a message and send; addresses already in the team are refused. On phones the matrix picks one role at a time with chips and the save bar floats above the edge.

See also

Members tablePermissions MatrixAudit LogAdmin ShellSettings Layout

More React blocks

Onboarding FlowLogin PageMarketplace Home PageMobile App HomeAdmin Dashboard PageAI Chat Page
All 26 React blocks

Articles using this component

  • Role Management UI in React: Members, Roles, Audit Log

    Build it: screens and apps · Nov 5, 2026 · 9 min read

  • Nextjs Admin Dashboard Tutorial: 5 Screens, Phone-Ready

    Build it: screens and apps · Oct 9, 2026 · 23 min read

PreviousSettings PageNext About Page