{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "invite-members-modal",
  "title": "Invite Members Modal",
  "description": "An invite dialog that handles the real cases: paste a list and it becomes chips, bad addresses turn red, existing members and pending invites are caught, each person gets a role, a seat meter warns before you go over the plan, an optional message, a shareable invite link with expiry and reset, and a success list.",
  "dependencies": [
    "motion",
    "clsx",
    "tailwind-merge"
  ],
  "files": [
    {
      "path": "registry/new-york/invite-members-modal/invite-members-modal.tsx",
      "content": "\"use client\";\n\nimport * as React from \"react\";\nimport { AnimatePresence, motion, useReducedMotion } from \"motion/react\";\nimport { clsx, type ClassValue } from \"clsx\";\nimport { twMerge } from \"tailwind-merge\";\n\nfunction cn(...inputs: ClassValue[]) {\n  return twMerge(clsx(inputs));\n}\n\ntype Role = \"Admin\" | \"Member\" | \"Viewer\";\ninterface Invite {\n  email: string;\n  role: Role;\n}\n\nexport interface InviteMembersModalProps {\n  workspace?: string;\n  members?: string[];\n  seats?: { used: number; total: number };\n  defaultOpen?: boolean;\n  onInvite?: (invites: Invite[], message: string) => Promise<void> | void;\n  theme?: \"dark\" | \"light\";\n  className?: string;\n}\n\nconst PALETTES = {\n  dark: { bg: \"#0A0A0A\", text: \"#F5F4F1\", muted: \"rgba(245,244,241,0.62)\", faint: \"rgba(245,244,241,0.36)\", panel: \"#141414\", border: \"rgba(255,255,255,0.09)\", input: \"#0E0E0E\", chip: \"rgba(255,255,255,0.07)\", track: \"rgba(255,255,255,0.08)\", on: \"#F5F4F1\", onText: \"#0A0A0A\", accent: \"#60A5FA\", green: \"#4ADE80\", amber: \"#FBBF24\", red: \"#F87171\", ring: \"rgba(245,244,241,0.6)\", scrim: \"rgba(0,0,0,0.6)\", ghost: \"rgba(255,255,255,0.035)\" },\n  light: { bg: \"#F4F4F1\", text: \"#0A0A0A\", muted: \"rgba(10,10,10,0.62)\", faint: \"rgba(10,10,10,0.42)\", panel: \"#FFFFFF\", border: \"rgba(10,10,10,0.1)\", input: \"#FAFAF8\", chip: \"rgba(10,10,10,0.06)\", track: \"rgba(10,10,10,0.07)\", on: \"#0A0A0A\", onText: \"#FAFAF8\", accent: \"#2563EB\", green: \"#15803D\", amber: \"#B45309\", red: \"#DC2626\", ring: \"rgba(10,10,10,0.5)\", scrim: \"rgba(10,10,10,0.3)\", ghost: \"rgba(10,10,10,0.04)\" },\n};\nconst ROLES: { id: Role; hint: string }[] = [\n  { id: \"Admin\", hint: \"Manage members, billing and settings\" },\n  { id: \"Member\", hint: \"Create and edit projects\" },\n  { id: \"Viewer\", hint: \"View and comment, no editing\" },\n];\nconst EMAIL = /^[^\\s@]+@[^\\s@]+\\.[^\\s@]{2,}$/;\nconst MEMBERS = [\"lena@nexora.io\", \"daniel@nexora.io\", \"mia@nexora.io\", \"tomas@nexora.io\", \"aiko@nexora.io\", \"jonas@nexora.io\"];\n\nexport function InviteMembersModal({ workspace = \"Nexora\", members = MEMBERS, seats = { used: 6, total: 10 }, defaultOpen = true, onInvite, theme = \"dark\", className }: InviteMembersModalProps) {\n  const p = PALETTES[theme];\n  const reduce = !!useReducedMotion();\n  const uid = React.useId();\n  const [open, setOpen] = React.useState(defaultOpen);\n  const [invites, setInvites] = React.useState<Invite[]>([{ email: \"priya@atlasfreight.com\", role: \"Member\" }]);\n  const [text, setText] = React.useState(\"\");\n  const [role, setRole] = React.useState<Role>(\"Member\");\n  const [message, setMessage] = React.useState(\"\");\n  const [showMsg, setShowMsg] = React.useState(false);\n  const [notice, setNotice] = React.useState<string | null>(null);\n  const [status, setStatus] = React.useState<\"idle\" | \"sending\" | \"sent\">(\"idle\");\n  const [sent, setSent] = React.useState<Invite[]>([]);\n  const [linkOn, setLinkOn] = React.useState(false);\n  const [linkId, setLinkId] = React.useState(\"k7f2q9\");\n  const [expiry, setExpiry] = React.useState(\"7 days\");\n  const [copied, setCopied] = React.useState(false);\n  const [pending, setPending] = React.useState<Invite[]>([{ email: \"grace@northpine.co\", role: \"Viewer\" }]);\n  const inputRef = React.useRef<HTMLInputElement>(null);\n  const timer = React.useRef<ReturnType<typeof setTimeout> | null>(null);\n  const counter = React.useRef(0);\n\n  React.useEffect(() => {\n    if (!notice && !copied) return;\n    const t = setTimeout(() => {\n      setNotice(null);\n      setCopied(false);\n    }, 2400);\n    return () => clearTimeout(t);\n  }, [notice, copied]);\n  React.useEffect(() => {\n    if (!open) return;\n    const onKey = (e: KeyboardEvent) => e.key === \"Escape\" && setOpen(false);\n    document.addEventListener(\"keydown\", onKey);\n    return () => document.removeEventListener(\"keydown\", onKey);\n  }, [open]);\n  React.useEffect(\n    () => () => {\n      if (timer.current) clearTimeout(timer.current);\n    },\n    [],\n  );\n\n  const addFrom = (raw: string) => {\n    const parts = raw.split(/[\\s,;]+/).map((s) => s.trim().toLowerCase()).filter(Boolean);\n    if (!parts.length) return;\n    const skipped: string[] = [];\n    const next = [...invites];\n    for (const e of parts) {\n      if (members.includes(e)) skipped.push(`${e} is already a member`);\n      else if (next.some((x) => x.email === e) || pending.some((x) => x.email === e)) skipped.push(`${e} is already invited`);\n      else next.push({ email: e, role });\n    }\n    setInvites(next);\n    if (skipped.length) setNotice(skipped[0] + (skipped.length > 1 ? ` (+${skipped.length - 1} more)` : \"\"));\n    setText(\"\");\n  };\n  const valid = invites.filter((i) => EMAIL.test(i.email));\n  const invalid = invites.length - valid.length;\n  const after = seats.used + pending.length + valid.length;\n  const over = after > seats.total;\n  const send = () => {\n    if (!valid.length || invalid || over || status !== \"idle\") return;\n    setStatus(\"sending\");\n    const batch = valid;\n    const done = () => {\n      setSent(batch);\n      setPending((p0) => [...batch, ...p0]);\n      setInvites([]);\n      setStatus(\"sent\");\n    };\n    const r = onInvite?.(batch, message);\n    if (r instanceof Promise) r.then(done, () => setStatus(\"idle\"));\n    else timer.current = setTimeout(done, reduce ? 0 : 900);\n  };\n\n  const ring = { [\"--tw-ring-color\" as string]: p.ring, [\"--tw-ring-offset-color\" as string]: p.panel } as React.CSSProperties;\n  const focus = \"outline-none focus-visible:ring-2 focus-visible:ring-offset-2\";\n  const btn = cn(\"flex h-9 shrink-0 cursor-pointer items-center justify-center gap-1.5 rounded-lg px-3.5 text-[13px] font-medium disabled:cursor-not-allowed disabled:opacity-40\", focus);\n\n  return (\n    <section className={cn(\"@container relative min-h-[700px] w-full overflow-hidden\", className)} style={{ background: p.bg, color: p.text }}>\n      {/* Members page behind */}\n      <div className=\"mx-auto max-w-3xl px-4 py-10 @[640px]:px-6\" aria-hidden={open}>\n        <div className=\"flex items-center justify-between\">\n          <div>\n            <h2 className=\"m-0 text-[20px] font-semibold\">Members</h2>\n            <p className=\"m-0 mt-1 text-[13px]\" style={{ color: p.muted }}>\n              {seats.used} of {seats.total} seats used · {pending.length} pending\n            </p>\n          </div>\n          <button type=\"button\" onClick={() => setOpen(true)} className={cn(btn, \"border-0\")} style={{ background: p.on, color: p.onText, ...ring }}>\n            + Invite\n          </button>\n        </div>\n        <ul className=\"m-0 mt-6 flex list-none flex-col gap-2 p-0\">\n          {[...members.slice(0, 4), ...pending.map((x) => x.email)].map((m, i) => (\n            <li key={m} className=\"flex items-center gap-3 rounded-xl px-3 py-2.5\" style={{ background: p.ghost }}>\n              <span className=\"grid h-8 w-8 place-items-center rounded-full text-[11px] font-semibold uppercase\" style={{ background: p.chip }}>\n                {m.slice(0, 2)}\n              </span>\n              <span className=\"min-w-0 flex-1 truncate text-[13px]\">{m}</span>\n              <span className=\"text-[12px]\" style={{ color: i >= 4 ? p.amber : p.faint }}>\n                {i >= 4 ? \"Pending\" : i === 0 ? \"Owner\" : \"Member\"}\n              </span>\n            </li>\n          ))}\n        </ul>\n      </div>\n\n      <AnimatePresence>\n        {open && (\n          <motion.div key=\"scrim\" initial={reduce ? false : { opacity: 0 }} animate={{ opacity: 1 }} exit={reduce ? undefined : { opacity: 0 }} className=\"absolute inset-0 z-20 flex items-start justify-center overflow-y-auto px-3 py-8 @[640px]:py-14\" style={{ background: p.scrim }} onMouseDown={(e) => e.target === e.currentTarget && setOpen(false)}>\n            <motion.div role=\"dialog\" aria-modal=\"true\" aria-labelledby={`${uid}-t`} initial={reduce ? false : { opacity: 0, y: 12, scale: 0.97 }} animate={{ opacity: 1, y: 0, scale: 1 }} exit={reduce ? undefined : { opacity: 0, y: 8, scale: 0.98 }} transition={{ type: \"spring\", stiffness: 460, damping: 36 }} className=\"w-full max-w-[520px] rounded-2xl border shadow-[0_24px_70px_-20px_rgba(0,0,0,0.7)]\" style={{ background: p.panel, borderColor: p.border }}>\n              <div className=\"flex items-start justify-between gap-3 px-5 pt-5\">\n                <div>\n                  <h3 id={`${uid}-t`} className=\"m-0 text-[17px] font-semibold\">\n                    {status === \"sent\" ? \"Invites sent\" : `Invite people to ${workspace}`}\n                  </h3>\n                  <p className=\"m-0 mt-1 text-[13px]\" style={{ color: p.muted }}>\n                    {status === \"sent\" ? `${sent.length} ${sent.length === 1 ? \"person\" : \"people\"} will get an email to join.` : \"They'll get an email with a link to join.\"}\n                  </p>\n                </div>\n                <button type=\"button\" onClick={() => setOpen(false)} aria-label=\"Close\" className={cn(\"grid h-8 w-8 shrink-0 cursor-pointer place-items-center rounded-lg border-0 bg-transparent\", focus)} style={{ color: p.muted, ...ring }}>\n                  <svg width=\"16\" height=\"16\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" strokeWidth=\"2\" strokeLinecap=\"round\" aria-hidden=\"true\">\n                    <path d=\"M6 6l12 12M18 6 6 18\" />\n                  </svg>\n                </button>\n              </div>\n\n              {status === \"sent\" ? (\n                <motion.div initial={reduce ? false : { opacity: 0, y: 6 }} animate={{ opacity: 1, y: 0 }} className=\"px-5 pt-4 pb-5\" role=\"status\">\n                  <ul className=\"m-0 flex list-none flex-col gap-1.5 p-0\">\n                    {sent.map((s, i) => (\n                      <motion.li key={s.email} initial={reduce ? false : { opacity: 0, x: -6 }} animate={{ opacity: 1, x: 0 }} transition={{ delay: reduce ? 0 : i * 0.06 }} className=\"flex items-center gap-2.5 rounded-lg px-3 py-2 text-[13px]\" style={{ background: p.ghost }}>\n                        <span style={{ color: p.green }}>✓</span>\n                        <span className=\"min-w-0 flex-1 truncate\">{s.email}</span>\n                        <span className=\"text-[12px]\" style={{ color: p.faint }}>\n                          {s.role}\n                        </span>\n                      </motion.li>\n                    ))}\n                  </ul>\n                  <div className=\"mt-5 flex justify-end gap-2\">\n                    <button type=\"button\" onClick={() => setStatus(\"idle\")} className={cn(btn, \"border bg-transparent\")} style={{ borderColor: p.border, color: p.text, ...ring }}>\n                      Invite more\n                    </button>\n                    <button type=\"button\" onClick={() => setOpen(false)} className={cn(btn, \"border-0\")} style={{ background: p.on, color: p.onText, ...ring }}>\n                      Done\n                    </button>\n                  </div>\n                </motion.div>\n              ) : (\n                <form\n                  className=\"px-5 pt-4 pb-5\"\n                  onSubmit={(e) => {\n                    e.preventDefault();\n                    send();\n                  }}\n                >\n                  <div className=\"flex items-baseline justify-between\">\n                    <label htmlFor={`${uid}-in`} className=\"text-[13px] font-medium\">\n                      Email addresses\n                    </label>\n                    <label className=\"flex items-center gap-1.5 text-[12px]\" style={{ color: p.faint }}>\n                      Default role\n                      <select value={role} onChange={(e) => setRole(e.target.value as Role)} className={cn(\"h-7 cursor-pointer rounded-md border px-1.5 text-[12px]\", focus)} style={{ borderColor: p.border, background: p.input, color: p.text, ...ring }}>\n                        {ROLES.map((r) => (\n                          <option key={r.id}>{r.id}</option>\n                        ))}\n                      </select>\n                    </label>\n                  </div>\n                  <div onClick={() => inputRef.current?.focus()} className=\"mt-1.5 flex min-h-[44px] cursor-text flex-wrap items-center gap-1.5 rounded-xl border p-1.5 focus-within:border-[var(--f)]\" style={{ borderColor: p.border, background: p.input, [\"--f\" as string]: p.accent }}>\n                    <AnimatePresence initial={false}>\n                      {invites.map((inv) => {\n                        const ok = EMAIL.test(inv.email);\n                        return (\n                          <motion.span key={inv.email} layout={!reduce} initial={reduce ? false : { opacity: 0, scale: 0.85 }} animate={{ opacity: 1, scale: 1 }} exit={reduce ? undefined : { opacity: 0, scale: 0.85 }} className=\"flex max-w-full items-center gap-1 rounded-lg py-0.5 pr-0.5 pl-2 text-[12.5px]\" style={{ background: ok ? p.chip : `${p.red}22`, color: ok ? p.text : p.red }} title={ok ? undefined : \"Not a valid email address\"}>\n                            <span className=\"truncate\">{inv.email}</span>\n                            <select value={inv.role} onChange={(e) => setInvites((l) => l.map((x) => (x.email === inv.email ? { ...x, role: e.target.value as Role } : x)))} aria-label={`Role for ${inv.email}`} className={cn(\"h-6 cursor-pointer rounded-md border-0 bg-transparent px-1 text-[11.5px]\", focus)} style={{ color: p.muted, ...ring }}>\n                              {ROLES.map((r) => (\n                                <option key={r.id}>{r.id}</option>\n                              ))}\n                            </select>\n                            <button type=\"button\" onClick={() => setInvites((l) => l.filter((x) => x.email !== inv.email))} aria-label={`Remove ${inv.email}`} className={cn(\"grid h-5 w-5 cursor-pointer place-items-center rounded border-0 bg-transparent text-[13px]\", focus)} style={{ color: p.faint, ...ring }}>\n                              ×\n                            </button>\n                          </motion.span>\n                        );\n                      })}\n                    </AnimatePresence>\n                    <input\n                      ref={inputRef}\n                      id={`${uid}-in`}\n                      value={text}\n                      onChange={(e) => {\n                        const v = e.target.value;\n                        if (/[,;\\s]$/.test(v)) addFrom(v);\n                        else setText(v);\n                      }}\n                      onKeyDown={(e) => {\n                        if (e.key === \"Enter\" && text.trim()) {\n                          e.preventDefault();\n                          addFrom(text);\n                        } else if (e.key === \"Backspace\" && !text && invites.length) setInvites((l) => l.slice(0, -1));\n                      }}\n                      onPaste={(e) => {\n                        const t = e.clipboardData.getData(\"text\");\n                        if (/[,;\\s]/.test(t.trim())) {\n                          e.preventDefault();\n                          addFrom(t);\n                        }\n                      }}\n                      onBlur={() => text.trim() && addFrom(text)}\n                      placeholder={invites.length ? \"\" : \"name@company.com, another@company.com\"}\n                      autoComplete=\"off\"\n                      className=\"h-8 min-w-[160px] flex-1 border-0 bg-transparent px-1.5 text-[13px] outline-none\"\n                      style={{ color: p.text }}\n                      aria-describedby={`${uid}-hint`}\n                    />\n                  </div>\n                  <p id={`${uid}-hint`} className=\"m-0 mt-1.5 min-h-[18px] text-[12px]\" style={{ color: notice ? p.amber : invalid ? p.red : p.faint }} aria-live=\"polite\">\n                    {notice ?? (invalid ? `Fix or remove ${invalid} invalid ${invalid === 1 ? \"address\" : \"addresses\"}.` : \"Separate with commas or Enter. Paste a whole list at once.\")}\n                  </p>\n\n                  {/* Seats */}\n                  <div className=\"mt-3 rounded-xl p-3\" style={{ background: p.ghost }}>\n                    <div className=\"flex items-baseline justify-between text-[12.5px]\">\n                      <span style={{ color: p.muted }}>Seats</span>\n                      <span className=\"tabular-nums\" style={{ color: over ? p.red : p.text }}>\n                        {Math.min(after, 99)} of {seats.total}\n                        {valid.length > 0 && <span style={{ color: p.faint }}> · +{valid.length} with these invites</span>}\n                      </span>\n                    </div>\n                    <div className=\"mt-2 flex h-1.5 overflow-hidden rounded-full\" style={{ background: p.track }}>\n                      <span className=\"h-full\" style={{ width: `${(seats.used / seats.total) * 100}%`, background: p.on }} />\n                      <span className=\"h-full\" style={{ width: `${(pending.length / seats.total) * 100}%`, background: p.amber }} />\n                      <motion.span className=\"h-full\" initial={false} animate={{ width: `${(Math.min(valid.length, Math.max(0, seats.total - seats.used - pending.length)) / seats.total) * 100}%` }} style={{ background: over ? p.red : p.accent }} />\n                    </div>\n                    {over && (\n                      <p className=\"m-0 mt-2 text-[12px]\" style={{ color: p.red }}>\n                        That&apos;s {after - seats.total} more than your plan allows.{\" \"}\n                        <a href=\"#\" className=\"underline underline-offset-2\" style={{ color: p.text }}>\n                          Add seats\n                        </a>\n                      </p>\n                    )}\n                  </div>\n\n                  {/* Message */}\n                  <AnimatePresence initial={false}>\n                    {showMsg ? (\n                      <motion.div key=\"msg\" initial={reduce ? false : { opacity: 0, height: 0 }} animate={{ opacity: 1, height: \"auto\" }} exit={reduce ? undefined : { opacity: 0, height: 0 }} className=\"overflow-hidden\">\n                        <label htmlFor={`${uid}-msg`} className=\"mt-4 block text-[13px] font-medium\">\n                          Personal message <span style={{ color: p.faint, fontWeight: 400 }}>(optional)</span>\n                        </label>\n                        <textarea id={`${uid}-msg`} value={message} onChange={(e) => setMessage(e.target.value)} rows={2} maxLength={280} placeholder=\"Hey! Join us so we can plan Q1 together.\" className={cn(\"mt-1.5 block w-full resize-none rounded-xl border px-3 py-2 text-[13px]\", focus)} style={{ borderColor: p.border, background: p.input, color: p.text, ...ring }} />\n                      </motion.div>\n                    ) : (\n                      <motion.button key=\"add\" type=\"button\" onClick={() => setShowMsg(true)} className={cn(\"mt-3 cursor-pointer rounded border-0 bg-transparent p-0 text-[12.5px] underline underline-offset-2\", focus)} style={{ color: p.muted, ...ring }}>\n                        + Add a personal message\n                      </motion.button>\n                    )}\n                  </AnimatePresence>\n\n                  {/* Link */}\n                  <div className=\"mt-4 border-t pt-4\" style={{ borderColor: p.border }}>\n                    <div className=\"flex items-center justify-between gap-3\">\n                      <div>\n                        <p className=\"m-0 text-[13px] font-medium\">Invite link</p>\n                        <p className=\"m-0 text-[12px]\" style={{ color: p.faint }}>\n                          Anyone with the link joins as a Viewer.\n                        </p>\n                      </div>\n                      <button type=\"button\" role=\"switch\" aria-checked={linkOn} aria-label=\"Invite link\" onClick={() => setLinkOn((v) => !v)} className={cn(\"relative h-5 w-9 shrink-0 cursor-pointer rounded-full border-0 transition-colors\", focus)} style={{ background: linkOn ? p.green : p.track, ...ring }}>\n                        <motion.span className=\"absolute top-0.5 h-4 w-4 rounded-full bg-white shadow\" initial={false} animate={{ left: linkOn ? 18 : 2 }} transition={reduce ? { duration: 0 } : { type: \"spring\", stiffness: 600, damping: 34 }} />\n                      </button>\n                    </div>\n                    <AnimatePresence initial={false}>\n                      {linkOn && (\n                        <motion.div key=\"link\" initial={reduce ? false : { opacity: 0, height: 0 }} animate={{ opacity: 1, height: \"auto\" }} exit={reduce ? undefined : { opacity: 0, height: 0 }} className=\"overflow-hidden\">\n                          <div className=\"mt-3 flex flex-wrap items-center gap-2\">\n                            <code className=\"min-w-0 flex-1 truncate rounded-lg border px-2.5 py-2 font-mono text-[12px]\" style={{ borderColor: p.border, background: p.input, color: p.muted }}>\n                              nexora.app/join/{linkId}\n                            </code>\n                            <button\n                              type=\"button\"\n                              onClick={() => {\n                                navigator.clipboard?.writeText(`https://nexora.app/join/${linkId}`).catch(() => {});\n                                setCopied(true);\n                              }}\n                              className={cn(btn, \"h-8 border bg-transparent px-2.5 text-[12px]\")}\n                              style={{ borderColor: p.border, color: copied ? p.green : p.text, ...ring }}\n                            >\n                              {copied ? \"✓ Copied\" : \"Copy\"}\n                            </button>\n                          </div>\n                          <div className=\"mt-2 flex items-center justify-between text-[12px]\" style={{ color: p.faint }}>\n                            <label className=\"flex items-center gap-1.5\">\n                              Expires in\n                              <select value={expiry} onChange={(e) => setExpiry(e.target.value)} className={cn(\"h-7 cursor-pointer rounded-md border px-1.5 text-[12px]\", focus)} style={{ borderColor: p.border, background: p.input, color: p.text, ...ring }}>\n                                {[\"24 hours\", \"7 days\", \"30 days\", \"Never\"].map((x) => (\n                                  <option key={x}>{x}</option>\n                                ))}\n                              </select>\n                            </label>\n                            <button\n                              type=\"button\"\n                              onClick={() => {\n                                counter.current += 1;\n                                setLinkId(`${[\"m3x8\", \"q2v7\", \"z9k4\", \"h6p1\"][counter.current % 4]}${counter.current}`);\n                                setNotice(\"Old link turned off. Share the new one.\");\n                              }}\n                              className={cn(\"cursor-pointer rounded border-0 bg-transparent p-0 text-[12px] underline underline-offset-2\", focus)}\n                              style={{ color: p.muted, ...ring }}\n                            >\n                              Reset link\n                            </button>\n                          </div>\n                        </motion.div>\n                      )}\n                    </AnimatePresence>\n                  </div>\n\n                  <div className=\"mt-5 flex items-center justify-between gap-2\">\n                    <span className=\"text-[12px]\" style={{ color: p.faint }}>\n                      {pending.length} pending\n                    </span>\n                    <div className=\"flex gap-2\">\n                      <button type=\"button\" onClick={() => setOpen(false)} className={cn(btn, \"border bg-transparent\")} style={{ borderColor: p.border, color: p.text, ...ring }}>\n                        Cancel\n                      </button>\n                      <button type=\"submit\" disabled={!valid.length || invalid > 0 || over || status === \"sending\"} className={cn(btn, \"min-w-[120px] border-0\")} style={{ background: p.on, color: p.onText, ...ring }}>\n                        {status === \"sending\" ? (\n                          <>\n                            <motion.span className=\"h-3.5 w-3.5 rounded-full border-2 border-current border-t-transparent\" animate={reduce ? undefined : { rotate: 360 }} transition={{ repeat: Infinity, duration: 0.7, ease: \"linear\" }} aria-hidden=\"true\" />\n                            Sending…\n                          </>\n                        ) : (\n                          `Send ${valid.length || \"\"} ${valid.length === 1 ? \"invite\" : \"invites\"}`.replace(\"  \", \" \")\n                        )}\n                      </button>\n                    </div>\n                  </div>\n                </form>\n              )}\n            </motion.div>\n          </motion.div>\n        )}\n      </AnimatePresence>\n    </section>\n  );\n}\n\nexport default InviteMembersModal;\n",
      "type": "registry:component"
    }
  ],
  "type": "registry:component"
}