{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "settings",
  "title": "Settings",
  "description": "An account settings page with tabs for a profile form, a password change and delete-account dialog, and notification switches.",
  "registryDependencies": [
    "@corsair-ui/utils",
    "@corsair-ui/use-media-query",
    "@corsair-ui/alert-dialog",
    "@corsair-ui/avatar",
    "@corsair-ui/button",
    "@corsair-ui/card",
    "@corsair-ui/field",
    "@corsair-ui/input",
    "@corsair-ui/password-input",
    "@corsair-ui/switch",
    "@corsair-ui/tabs",
    "@corsair-ui/textarea"
  ],
  "files": [
    {
      "path": "registry/default/components/blocks/settings.tsx",
      "content": "\"use client\";\n\nimport {\n  useId,\n  useState,\n  type ComponentProps,\n  type MouseEvent,\n  type ReactNode,\n  type SubmitEvent,\n} from \"react\";\n\nimport { useMediaQuery } from \"@/registry/default/hooks/use-media-query\";\nimport { cn } from \"@/registry/default/lib/utils\";\nimport {\n  AlertDialog,\n  AlertDialogAction,\n  AlertDialogCancel,\n  AlertDialogContent,\n  AlertDialogDescription,\n  AlertDialogFooter,\n  AlertDialogHeader,\n  AlertDialogTitle,\n  AlertDialogTrigger,\n} from \"@/registry/default/ui/alert-dialog\";\nimport { Avatar, AvatarFallback, AvatarImage } from \"@/registry/default/ui/avatar\";\nimport { Button, buttonVariants } from \"@/registry/default/ui/button\";\nimport {\n  Card,\n  CardContent,\n  CardDescription,\n  CardFooter,\n  CardHeader,\n} from \"@/registry/default/ui/card\";\nimport {\n  Field,\n  FieldContent,\n  FieldDescription,\n  FieldGroup,\n  FieldLabel,\n} from \"@/registry/default/ui/field\";\nimport { Input } from \"@/registry/default/ui/input\";\nimport { PasswordInput } from \"@/registry/default/ui/password-input\";\nimport { Switch } from \"@/registry/default/ui/switch\";\nimport { Tabs, TabsContent, TabsList, TabsTrigger } from \"@/registry/default/ui/tabs\";\nimport { Textarea } from \"@/registry/default/ui/textarea\";\n\n/** Status of a form or of the delete action, exposed as `data-status`. */\ntype SettingsStatus = \"idle\" | \"pending\" | \"success\" | \"error\";\n\n/** What the profile form hands to `onSaveProfile`, read from its fields with FormData. */\ninterface SettingsProfileValues {\n  name: string;\n  email: string;\n  bio: string;\n}\n\n/** What the password form hands to `onChangePassword`. */\ninterface SettingsPasswordValues {\n  currentPassword: string;\n  newPassword: string;\n}\n\n/** The profile the form starts with. */\ninterface SettingsProfile {\n  name?: string;\n  email?: string;\n  bio?: string;\n  /** Image URL for the avatar; initials of `name` show while it loads or when it fails. */\n  avatar?: string;\n}\n\n/** One switch on the notifications panel. */\ninterface SettingsNotification {\n  /** Key of the switch in the state passed to `onNotificationsChange`. */\n  id: string;\n  label: ReactNode;\n  description?: ReactNode;\n  defaultChecked?: boolean;\n}\n\n/**\n * A tab. The values `\"profile\"`, `\"account\"` and `\"notifications\"` render\n * the built-in panels; any other value needs `content`, which also replaces\n * a built-in panel.\n */\ninterface SettingsSection {\n  value: string;\n  label: ReactNode;\n  /** Shown before the label. */\n  icon?: ReactNode;\n  content?: ReactNode;\n}\n\n/** Every string the page shows, including buttons and status messages. */\ninterface SettingsLabels {\n  title: ReactNode;\n  description: ReactNode;\n  /** Accessible name of the tab list. */\n  sections: string;\n  profileTab: ReactNode;\n  accountTab: ReactNode;\n  notificationsTab: ReactNode;\n\n  profileTitle: ReactNode;\n  profileDescription: ReactNode;\n  name: ReactNode;\n  email: ReactNode;\n  bio: ReactNode;\n  bioHint: ReactNode;\n  saveProfile: ReactNode;\n  savingProfile: ReactNode;\n  profileSuccess: ReactNode;\n  profileError: ReactNode;\n\n  passwordTitle: ReactNode;\n  passwordDescription: ReactNode;\n  currentPassword: ReactNode;\n  newPassword: ReactNode;\n  passwordHint: ReactNode;\n  /** Accessible name of the button that shows a password. */\n  showPassword: string;\n  changePassword: ReactNode;\n  changingPassword: ReactNode;\n  passwordSuccess: ReactNode;\n  passwordError: ReactNode;\n\n  dangerTitle: ReactNode;\n  dangerDescription: ReactNode;\n  deleteAccount: ReactNode;\n  deleteTitle: ReactNode;\n  deleteDescription: ReactNode;\n  deleteCancel: ReactNode;\n  deleteConfirm: ReactNode;\n  deleting: ReactNode;\n  deleteSuccess: ReactNode;\n  deleteError: ReactNode;\n\n  notificationsTitle: ReactNode;\n  notificationsDescription: ReactNode;\n}\n\nconst defaultLabels: SettingsLabels = {\n  title: \"Settings\",\n  description: \"Manage your profile, account and notification preferences.\",\n  sections: \"Settings sections\",\n  profileTab: \"Profile\",\n  accountTab: \"Account\",\n  notificationsTab: \"Notifications\",\n\n  profileTitle: \"Profile\",\n  profileDescription: \"This is how other people see you.\",\n  name: \"Name\",\n  email: \"Email\",\n  bio: \"Bio\",\n  bioHint: \"A few words about yourself.\",\n  saveProfile: \"Save profile\",\n  savingProfile: \"Saving…\",\n  profileSuccess: \"Your profile has been saved.\",\n  profileError: \"Something went wrong. Please try again.\",\n\n  passwordTitle: \"Password\",\n  passwordDescription: \"Change the password you use to sign in.\",\n  currentPassword: \"Current password\",\n  newPassword: \"New password\",\n  passwordHint: \"At least 8 characters.\",\n  showPassword: \"Show password\",\n  changePassword: \"Update password\",\n  changingPassword: \"Updating…\",\n  passwordSuccess: \"Your password has been updated.\",\n  passwordError: \"Something went wrong. Please try again.\",\n\n  dangerTitle: \"Danger zone\",\n  dangerDescription: \"Permanently delete your account and everything in it.\",\n  deleteAccount: \"Delete account\",\n  deleteTitle: \"Delete your account?\",\n  deleteDescription:\n    \"This permanently deletes your account and all of its data. This cannot be undone.\",\n  deleteCancel: \"Cancel\",\n  deleteConfirm: \"Delete account\",\n  deleting: \"Deleting…\",\n  deleteSuccess: \"Your account has been deleted.\",\n  deleteError: \"Something went wrong. Please try again.\",\n\n  notificationsTitle: \"Notifications\",\n  notificationsDescription: \"Choose what we email you about.\",\n};\n\nconst defaultProfile: SettingsProfile = {\n  name: \"Alex Morgan\",\n  email: \"alex@example.com\",\n  bio: \"Product designer at Acme.\",\n};\n\nconst defaultNotifications: SettingsNotification[] = [\n  {\n    id: \"product\",\n    label: \"Product updates\",\n    description: \"News about features and improvements.\",\n    defaultChecked: true,\n  },\n  {\n    id: \"security\",\n    label: \"Security alerts\",\n    description: \"Sign-ins from new devices and password changes.\",\n    defaultChecked: true,\n  },\n  {\n    id: \"comments\",\n    label: \"Comments\",\n    description: \"When someone replies to you or mentions you.\",\n  },\n  {\n    id: \"marketing\",\n    label: \"Tips and offers\",\n    description: \"Occasional emails about getting more out of Acme.\",\n  },\n];\n\ninterface SettingsProps extends Omit<ComponentProps<\"section\">, \"title\" | \"onSubmit\"> {\n  /** Overrides for any of the page's strings; the rest keep their English defaults. */\n  labels?: Partial<SettingsLabels>;\n  /** The tabs, in order. Defaults to Profile, Account and Notifications. */\n  sections?: SettingsSection[];\n  /** Props for `Tabs`: `defaultValue`, or `value` / `onValueChange` to control the tab. */\n  tabsProps?: Omit<ComponentProps<typeof Tabs>, \"children\" | \"orientation\">;\n  /** The values the profile form starts with. */\n  profile?: SettingsProfile;\n  /**\n   * Called with the profile values instead of a native submit. While it runs\n   * the button is disabled; resolving shows `labels.profileSuccess`,\n   * throwing shows `labels.profileError`.\n   */\n  onSaveProfile?: (values: SettingsProfileValues) => void | Promise<void>;\n  /** Shortest new password the form accepts. */\n  minPasswordLength?: number;\n  /**\n   * Called with the current and new password. Resolving clears the form and\n   * shows `labels.passwordSuccess`; throwing shows `labels.passwordError`.\n   */\n  onChangePassword?: (values: SettingsPasswordValues) => void | Promise<void>;\n  /**\n   * Called when the user confirms the delete dialog. The dialog stays open\n   * while it runs, closes when it resolves and shows `labels.deleteError`\n   * when it throws. Without it, confirming only closes the dialog.\n   */\n  onDelete?: () => void | Promise<void>;\n  /** The switches on the notifications panel. */\n  notifications?: SettingsNotification[];\n  /** Called with every switch's state, by id, whenever one changes. */\n  onNotificationsChange?: (state: Record<string, boolean>) => void;\n  /** Props for the profile `<form>`, such as `action` and `method` for a native submit. */\n  profileFormProps?: ComponentProps<\"form\">;\n  /** Props for the password `<form>`, such as `action` and `method` for a native submit. */\n  passwordFormProps?: ComponentProps<\"form\">;\n}\n\n/** Up to two initials from a name, for the avatar fallback. */\nfunction initials(name: string) {\n  return name\n    .split(/\\s+/)\n    .filter(Boolean)\n    .slice(0, 2)\n    .map((part) => part[0])\n    .join(\"\");\n}\n\n/** Runs an async handler and tracks its status. */\nfunction useStatus() {\n  const [status, setStatus] = useState<SettingsStatus>(\"idle\");\n  async function run(task: () => void | Promise<void>) {\n    setStatus(\"pending\");\n    try {\n      await task();\n      setStatus(\"success\");\n      return true;\n    } catch {\n      setStatus(\"error\");\n      return false;\n    }\n  }\n  return [status, run] as const;\n}\n\n/** The success and error regions under a form: always mounted so screen readers announce them. */\nfunction StatusRegions({\n  slot,\n  status,\n  success,\n  error,\n}: {\n  slot: string;\n  status: SettingsStatus;\n  success: ReactNode;\n  error: ReactNode;\n}) {\n  return (\n    <>\n      <p role=\"status\" data-slot={`${slot}-success`} className=\"text-sm empty:hidden\">\n        {status === \"success\" ? success : null}\n      </p>\n      <p role=\"alert\" data-slot={`${slot}-error`} className=\"text-destructive text-sm empty:hidden\">\n        {status === \"error\" ? error : null}\n      </p>\n    </>\n  );\n}\n\nfunction PanelHeader({ title, description }: { title: ReactNode; description: ReactNode }) {\n  return (\n    <CardHeader>\n      <h2 className=\"leading-none font-semibold\">{title}</h2>\n      {description != null ? <CardDescription>{description}</CardDescription> : null}\n    </CardHeader>\n  );\n}\n\n/**\n * An account settings page: a header with an `<h1>` and a description, and\n * tabs for Profile (name, email, bio and avatar), Account (password change\n * and a Danger zone with a confirmation dialog) and Notifications (a list\n * of switches). The tabs stand in a column beside the panels from 768px\n * up and in a row above them on smaller screens. `<Settings />` renders a\n * complete example; every string comes from `labels`.\n *\n * Forms: with `onSaveProfile` / `onChangePassword` the forms do not\n * navigate. Each form gets `data-status=\"pending\"`, then `\"success\"` or\n * `\"error\"`, and has its own `role=\"status\"` and `role=\"alert\"` regions,\n * always mounted, so screen readers announce the result. Fields use native\n * validation (`required`, `type=\"email\"`, `minLength`) and `autoComplete`,\n * so password managers fill and save them. Without a handler the form\n * submits natively.\n *\n * Keyboard and screen readers: the tab list is one Tab stop; the arrow keys\n * move between tabs (Up and Down while vertical, Left and Right while\n * horizontal), Home and End jump to the ends. The delete dialog is an alert\n * dialog that traps focus, starts on Cancel and closes with Escape. Each\n * switch is named by its label and described by its description, and\n * applies at once. Only colour transitions and the dialog's fade move;\n * reduced motion turns them off.\n *\n * @example\n * <Settings\n *   profile={{ name: \"Sam Lee\", email: \"sam@example.com\" }}\n *   onSaveProfile={async (values) => {\n *     await fetch(\"/api/profile\", { method: \"PUT\", body: JSON.stringify(values) });\n *   }}\n *   onDelete={() => deleteAccount()}\n *   onNotificationsChange={(state) => savePreferences(state)}\n * />\n */\nfunction Settings({\n  labels: labelsProp,\n  sections: sectionsProp,\n  tabsProps,\n  profile = defaultProfile,\n  onSaveProfile,\n  minPasswordLength = 8,\n  onChangePassword,\n  onDelete,\n  notifications = defaultNotifications,\n  onNotificationsChange,\n  profileFormProps,\n  passwordFormProps,\n  className,\n  ...props\n}: SettingsProps) {\n  const id = useId();\n  const labels = { ...defaultLabels, ...labelsProp };\n  const isDesktop = useMediaQuery(\"(min-width: 768px)\", { defaultValue: true });\n  const orientation = isDesktop ? \"vertical\" : \"horizontal\";\n\n  const sections = sectionsProp ?? [\n    { value: \"profile\", label: labels.profileTab },\n    { value: \"account\", label: labels.accountTab },\n    { value: \"notifications\", label: labels.notificationsTab },\n  ];\n\n  const [profileStatus, runProfile] = useStatus();\n  const [passwordStatus, runPassword] = useStatus();\n  const [deleteStatus, runDelete] = useStatus();\n  const [deleteOpen, setDeleteOpen] = useState(false);\n  const [notificationState, setNotificationState] = useState<Record<string, boolean>>(() =>\n    Object.fromEntries(notifications.map((item) => [item.id, item.defaultChecked ?? false]))\n  );\n\n  async function handleProfile(event: SubmitEvent<HTMLFormElement>) {\n    profileFormProps?.onSubmit?.(event);\n    // No handler, or the consumer cancelled it: leave the native submit alone.\n    if (!onSaveProfile || event.defaultPrevented) return;\n    event.preventDefault();\n    if (profileStatus === \"pending\") return;\n    const data = new FormData(event.currentTarget);\n    const values: SettingsProfileValues = {\n      name: String(data.get(\"name\") ?? \"\"),\n      email: String(data.get(\"email\") ?? \"\"),\n      bio: String(data.get(\"bio\") ?? \"\"),\n    };\n    await runProfile(() => onSaveProfile(values));\n  }\n\n  async function handlePassword(event: SubmitEvent<HTMLFormElement>) {\n    passwordFormProps?.onSubmit?.(event);\n    if (!onChangePassword || event.defaultPrevented) return;\n    event.preventDefault();\n    if (passwordStatus === \"pending\") return;\n    // React clears currentTarget once the event is handled, so keep the form.\n    const form = event.currentTarget;\n    const data = new FormData(form);\n    const values: SettingsPasswordValues = {\n      currentPassword: String(data.get(\"current-password\") ?? \"\"),\n      newPassword: String(data.get(\"new-password\") ?? \"\"),\n    };\n    if (await runPassword(() => onChangePassword(values))) form.reset();\n  }\n\n  async function handleDelete(event: MouseEvent<HTMLButtonElement>) {\n    // Keep the dialog open until the handler settles.\n    event.preventDefault();\n    if (deleteStatus === \"pending\") return;\n    if (!onDelete) {\n      setDeleteOpen(false);\n      return;\n    }\n    if (await runDelete(onDelete)) setDeleteOpen(false);\n  }\n\n  function toggleNotification(key: string, checked: boolean) {\n    const next = { ...notificationState, [key]: checked };\n    setNotificationState(next);\n    onNotificationsChange?.(next);\n  }\n\n  const profilePending = profileStatus === \"pending\";\n  const passwordPending = passwordStatus === \"pending\";\n  const deletePending = deleteStatus === \"pending\";\n\n  const profilePanel = (\n    <Card data-slot=\"settings-profile\">\n      <PanelHeader title={labels.profileTitle} description={labels.profileDescription} />\n      <form\n        data-slot=\"settings-profile-form\"\n        data-status={profileStatus}\n        {...profileFormProps}\n        className={cn(\"flex flex-col gap-6\", profileFormProps?.className)}\n        onSubmit={handleProfile}\n      >\n        <CardContent>\n          <FieldGroup>\n            <div data-slot=\"settings-avatar\" className=\"flex items-center gap-4\">\n              <Avatar size=\"lg\" aria-hidden=\"true\">\n                {profile.avatar ? <AvatarImage src={profile.avatar} alt=\"\" /> : null}\n                <AvatarFallback>{initials(profile.name ?? \"\")}</AvatarFallback>\n              </Avatar>\n              <div className=\"grid min-w-0 text-sm\">\n                <span className=\"truncate font-medium\">{profile.name}</span>\n                <span className=\"text-muted-foreground truncate\">{profile.email}</span>\n              </div>\n            </div>\n            <div className=\"grid gap-6 sm:grid-cols-2\">\n              <Field>\n                <FieldLabel htmlFor={`${id}-name`}>{labels.name}</FieldLabel>\n                <Input\n                  id={`${id}-name`}\n                  name=\"name\"\n                  autoComplete=\"name\"\n                  defaultValue={profile.name}\n                  required\n                />\n              </Field>\n              <Field>\n                <FieldLabel htmlFor={`${id}-email`}>{labels.email}</FieldLabel>\n                <Input\n                  id={`${id}-email`}\n                  name=\"email\"\n                  type=\"email\"\n                  autoComplete=\"email\"\n                  defaultValue={profile.email}\n                  required\n                />\n              </Field>\n            </div>\n            <Field>\n              <FieldLabel htmlFor={`${id}-bio`}>{labels.bio}</FieldLabel>\n              <Textarea\n                id={`${id}-bio`}\n                name=\"bio\"\n                rows={4}\n                defaultValue={profile.bio}\n                aria-describedby={`${id}-bio-hint`}\n              />\n              <FieldDescription id={`${id}-bio-hint`}>{labels.bioHint}</FieldDescription>\n            </Field>\n          </FieldGroup>\n        </CardContent>\n        <CardFooter className=\"flex-col items-start gap-4\">\n          <Button type=\"submit\" data-slot=\"settings-profile-submit\" loading={profilePending}>\n            {profilePending ? labels.savingProfile : labels.saveProfile}\n          </Button>\n          <StatusRegions\n            slot=\"settings-profile\"\n            status={profileStatus}\n            success={labels.profileSuccess}\n            error={labels.profileError}\n          />\n        </CardFooter>\n      </form>\n    </Card>\n  );\n\n  const accountPanel = (\n    <div className=\"flex flex-col gap-6\">\n      <Card data-slot=\"settings-password\">\n        <PanelHeader title={labels.passwordTitle} description={labels.passwordDescription} />\n        <form\n          data-slot=\"settings-password-form\"\n          data-status={passwordStatus}\n          {...passwordFormProps}\n          className={cn(\"flex flex-col gap-6\", passwordFormProps?.className)}\n          onSubmit={handlePassword}\n        >\n          <CardContent>\n            <FieldGroup>\n              <Field>\n                <FieldLabel htmlFor={`${id}-current-password`}>{labels.currentPassword}</FieldLabel>\n                <PasswordInput\n                  id={`${id}-current-password`}\n                  name=\"current-password\"\n                  autoComplete=\"current-password\"\n                  toggleLabel={labels.showPassword}\n                  required\n                />\n              </Field>\n              <Field>\n                <FieldLabel htmlFor={`${id}-new-password`}>{labels.newPassword}</FieldLabel>\n                <PasswordInput\n                  id={`${id}-new-password`}\n                  name=\"new-password\"\n                  autoComplete=\"new-password\"\n                  minLength={minPasswordLength}\n                  aria-describedby={`${id}-new-password-hint`}\n                  toggleLabel={labels.showPassword}\n                  required\n                />\n                <FieldDescription id={`${id}-new-password-hint`}>\n                  {labels.passwordHint}\n                </FieldDescription>\n              </Field>\n            </FieldGroup>\n          </CardContent>\n          <CardFooter className=\"flex-col items-start gap-4\">\n            <Button type=\"submit\" data-slot=\"settings-password-submit\" loading={passwordPending}>\n              {passwordPending ? labels.changingPassword : labels.changePassword}\n            </Button>\n            <StatusRegions\n              slot=\"settings-password\"\n              status={passwordStatus}\n              success={labels.passwordSuccess}\n              error={labels.passwordError}\n            />\n          </CardFooter>\n        </form>\n      </Card>\n      <Card\n        data-slot=\"settings-danger\"\n        data-status={deleteStatus}\n        className=\"border-destructive/50\"\n      >\n        <PanelHeader title={labels.dangerTitle} description={labels.dangerDescription} />\n        <CardFooter className=\"flex-col items-start gap-4\">\n          <AlertDialog open={deleteOpen} onOpenChange={setDeleteOpen}>\n            <AlertDialogTrigger asChild>\n              <Button variant=\"destructive\" data-slot=\"settings-delete\">\n                {labels.deleteAccount}\n              </Button>\n            </AlertDialogTrigger>\n            <AlertDialogContent>\n              <AlertDialogHeader>\n                <AlertDialogTitle>{labels.deleteTitle}</AlertDialogTitle>\n                <AlertDialogDescription>{labels.deleteDescription}</AlertDialogDescription>\n              </AlertDialogHeader>\n              {/* The page behind a modal is hidden from screen readers: report errors in here too. */}\n              <p\n                role=\"alert\"\n                data-slot=\"settings-delete-dialog-error\"\n                className=\"text-destructive text-sm empty:hidden\"\n              >\n                {deleteStatus === \"error\" ? labels.deleteError : null}\n              </p>\n              <AlertDialogFooter>\n                <AlertDialogCancel>{labels.deleteCancel}</AlertDialogCancel>\n                <AlertDialogAction\n                  data-slot=\"settings-delete-confirm\"\n                  className={buttonVariants({ variant: \"destructive\" })}\n                  disabled={deletePending}\n                  onClick={handleDelete}\n                >\n                  {deletePending ? labels.deleting : labels.deleteConfirm}\n                </AlertDialogAction>\n              </AlertDialogFooter>\n            </AlertDialogContent>\n          </AlertDialog>\n          <StatusRegions\n            slot=\"settings-delete\"\n            status={deleteStatus}\n            success={labels.deleteSuccess}\n            error={labels.deleteError}\n          />\n        </CardFooter>\n      </Card>\n    </div>\n  );\n\n  const notificationsPanel = (\n    <Card data-slot=\"settings-notifications\">\n      <PanelHeader\n        title={labels.notificationsTitle}\n        description={labels.notificationsDescription}\n      />\n      <CardContent>\n        <ul data-slot=\"settings-notification-list\" className=\"flex flex-col divide-y\">\n          {notifications.map((item) => {\n            const switchId = `${id}-notification-${item.id}`;\n            return (\n              <li\n                key={item.id}\n                data-slot=\"settings-notification\"\n                className=\"py-4 first:pt-0 last:pb-0\"\n              >\n                <Field orientation=\"horizontal\">\n                  <FieldContent>\n                    <FieldLabel htmlFor={switchId}>{item.label}</FieldLabel>\n                    {item.description != null ? (\n                      <FieldDescription id={`${switchId}-description`}>\n                        {item.description}\n                      </FieldDescription>\n                    ) : null}\n                  </FieldContent>\n                  <Switch\n                    id={switchId}\n                    name={item.id}\n                    checked={notificationState[item.id] ?? false}\n                    onCheckedChange={(checked) => toggleNotification(item.id, checked)}\n                    aria-describedby={\n                      item.description != null ? `${switchId}-description` : undefined\n                    }\n                  />\n                </Field>\n              </li>\n            );\n          })}\n        </ul>\n      </CardContent>\n    </Card>\n  );\n\n  const builtIn: Record<string, ReactNode> = {\n    profile: profilePanel,\n    account: accountPanel,\n    notifications: notificationsPanel,\n  };\n\n  return (\n    <section data-slot=\"settings\" className={cn(\"py-10 sm:py-16\", className)} {...props}>\n      <div data-slot=\"settings-container\" className=\"mx-auto w-full max-w-5xl px-4 sm:px-6\">\n        <div data-slot=\"settings-header\" className=\"max-w-2xl\">\n          <h1\n            data-slot=\"settings-title\"\n            className=\"text-2xl font-semibold tracking-tight sm:text-3xl\"\n          >\n            {labels.title}\n          </h1>\n          {labels.description != null ? (\n            <p data-slot=\"settings-description\" className=\"text-muted-foreground mt-2\">\n              {labels.description}\n            </p>\n          ) : null}\n        </div>\n        <Tabs\n          defaultValue={sections[0]?.value}\n          {...tabsProps}\n          orientation={orientation}\n          className={cn(\"mt-8 gap-6 md:gap-10\", tabsProps?.className)}\n        >\n          <TabsList\n            variant=\"line\"\n            aria-label={labels.sections}\n            className=\"w-full shrink-0 justify-start overflow-x-auto md:w-48\"\n          >\n            {sections.map((section) => (\n              <TabsTrigger key={section.value} value={section.value}>\n                {section.icon}\n                {section.label}\n              </TabsTrigger>\n            ))}\n          </TabsList>\n          {sections.map((section) => (\n            <TabsContent key={section.value} value={section.value} className=\"min-w-0\">\n              {section.content ?? builtIn[section.value]}\n            </TabsContent>\n          ))}\n        </Tabs>\n      </div>\n    </section>\n  );\n}\n\nexport {\n  Settings,\n  type SettingsLabels,\n  type SettingsNotification,\n  type SettingsPasswordValues,\n  type SettingsProfile,\n  type SettingsProfileValues,\n  type SettingsProps,\n  type SettingsSection,\n  type SettingsStatus,\n};\n",
      "type": "registry:component"
    }
  ],
  "type": "registry:block"
}