{"$schema":"https:\/\/ui.particle.academy\/schema\/registry-item.json","name":"profile","type":"registry:ui","title":"Profile","description":"Profile from react-fancy","package":"react-fancy","dependencies":[],"registryDependencies":["avatar"],"files":[{"path":"components\/fancy\/profile\/Profile.tsx","content":"import { forwardRef } from \"react\";\r\nimport { cn } from \"..\/..\/utils\/cn\";\r\nimport { Avatar } from \"..\/Avatar\";\r\nimport type { ProfileProps } from \".\/Profile.types\";\r\n\r\nconst gapClasses: Record<NonNullable<ProfileProps[\"size\"]>, string> = {\r\n  sm: \"gap-2\",\r\n  md: \"gap-3\",\r\n  lg: \"gap-4\",\r\n};\r\n\r\nconst nameClasses: Record<NonNullable<ProfileProps[\"size\"]>, string> = {\r\n  sm: \"text-sm\",\r\n  md: \"text-base\",\r\n  lg: \"text-lg\",\r\n};\r\n\r\nconst subtitleClasses: Record<NonNullable<ProfileProps[\"size\"]>, string> = {\r\n  sm: \"text-xs\",\r\n  md: \"text-sm\",\r\n  lg: \"text-base\",\r\n};\r\n\r\nexport const Profile = forwardRef<HTMLDivElement, ProfileProps>(\r\n  (\r\n    {\r\n      src,\r\n      alt,\r\n      fallback,\r\n      name,\r\n      subtitle,\r\n      size = \"md\",\r\n      status,\r\n      className,\r\n    },\r\n    ref,\r\n  ) => {\r\n    return (\r\n      <div\r\n        ref={ref}\r\n        data-react-fancy-profile=\"\"\r\n        className={cn(\"flex items-center\", gapClasses[size], className)}\r\n      >\r\n        <Avatar\r\n          src={src}\r\n          alt={alt || name}\r\n          fallback={fallback}\r\n          size={size}\r\n          status={status}\r\n        \/>\r\n        <div className=\"flex min-w-0 flex-col\">\r\n          <span\r\n            className={cn(\r\n              \"truncate font-medium text-zinc-900 dark:text-zinc-100\",\r\n              nameClasses[size],\r\n            )}\r\n          >\r\n            {name}\r\n          <\/span>\r\n          {subtitle && (\r\n            <span\r\n              className={cn(\r\n                \"truncate text-zinc-500 dark:text-zinc-400\",\r\n                subtitleClasses[size],\r\n              )}\r\n            >\r\n              {subtitle}\r\n            <\/span>\r\n          )}\r\n        <\/div>\r\n      <\/div>\r\n    );\r\n  },\r\n);\r\n\r\nProfile.displayName = \"Profile\";\r\n","type":"registry:ui","target":"components\/fancy\/profile\/Profile.tsx"},{"path":"components\/fancy\/profile\/Profile.types.ts","content":"export interface ProfileProps {\r\n  src?: string;\r\n  alt?: string;\r\n  fallback?: string;\r\n  name: string;\r\n  subtitle?: string;\r\n  size?: \"sm\" | \"md\" | \"lg\";\r\n  status?: \"online\" | \"offline\" | \"busy\" | \"away\";\r\n  className?: string;\r\n}\r\n","type":"registry:ui","target":"components\/fancy\/profile\/Profile.types.ts"},{"path":"components\/fancy\/profile\/index.ts","content":"export { Profile } from \".\/Profile\";\r\nexport type { ProfileProps } from \".\/Profile.types\";\r\n","type":"registry:ui","target":"components\/fancy\/profile\/index.ts"}]}