@aivex/ui 1.2.0-dev.42 → 1.2.0-dev.44

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/dist/{Button-BrPqDGyO.js → Button-CH_7RCR4.js} +244 -194
  2. package/dist/Button-CH_7RCR4.js.map +1 -0
  3. package/dist/Button-D6MqxX_7.cjs +2 -0
  4. package/dist/Button-D6MqxX_7.cjs.map +1 -0
  5. package/dist/{IconButton-CK4en7H6.js → IconButton-7v0vHj6O.js} +2 -2
  6. package/dist/{IconButton-CK4en7H6.js.map → IconButton-7v0vHj6O.js.map} +1 -1
  7. package/dist/{IconButton-DBlsEy3m.cjs → IconButton-DwhPDE1m.cjs} +2 -2
  8. package/dist/{IconButton-DBlsEy3m.cjs.map → IconButton-DwhPDE1m.cjs.map} +1 -1
  9. package/dist/comment.cjs +1 -1
  10. package/dist/comment.js +2 -2
  11. package/dist/components/DataGrid/DataGrid.d.ts +8 -3
  12. package/dist/components/DataGrid/DataGridPrimitives.d.ts +10 -2
  13. package/dist/components/DataGrid/index.d.ts +1 -1
  14. package/dist/components/Icon/index.d.ts +2 -0
  15. package/dist/components/Table/Table.d.ts +10 -0
  16. package/dist/index.cjs +1 -1
  17. package/dist/index.cjs.map +1 -1
  18. package/dist/index.js +628 -625
  19. package/dist/index.js.map +1 -1
  20. package/dist/{keyboard-BMCakKCv.js → keyboard-CnteNNEc.js} +2 -2
  21. package/dist/{keyboard-BMCakKCv.js.map → keyboard-CnteNNEc.js.map} +1 -1
  22. package/dist/{keyboard-DCewgvMV.cjs → keyboard-GVlhOfI6.cjs} +2 -2
  23. package/dist/{keyboard-DCewgvMV.cjs.map → keyboard-GVlhOfI6.cjs.map} +1 -1
  24. package/dist/shape-editor.cjs +1 -1
  25. package/dist/shape-editor.js +88 -88
  26. package/dist/styles.css +1 -1
  27. package/dist/utils.cjs +1 -1
  28. package/package.json +1 -1
  29. package/dist/Button-BrPqDGyO.js.map +0 -1
  30. package/dist/Button-EEErevS-.cjs +0 -2
  31. package/dist/Button-EEErevS-.cjs.map +0 -1
@@ -1,5 +1,5 @@
1
1
  import { cn as e } from "./utils.js";
2
- import { ma as t } from "./Button-BrPqDGyO.js";
2
+ import { ga as t } from "./Button-CH_7RCR4.js";
3
3
  import * as n from "@radix-ui/react-avatar";
4
4
  import { cva as r } from "class-variance-authority";
5
5
  import * as i from "@radix-ui/react-tooltip";
@@ -206,4 +206,4 @@ function x({ className: n, size: r = "sm", shape: i = "rectangle", color: a = "p
206
206
  //#endregion
207
207
  export { d as a, f as i, _ as n, l as o, g as r, x as t };
208
208
 
209
- //# sourceMappingURL=IconButton-CK4en7H6.js.map
209
+ //# sourceMappingURL=IconButton-7v0vHj6O.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"IconButton-CK4en7H6.js","names":[],"sources":["../src/components/Tooltip/Tooltip.tsx","../src/components/Avatar/Avatar.tsx","../src/components/IconButton/IconButton.tsx"],"sourcesContent":["\"use client\";\n\nimport * as RadixTooltip from \"@radix-ui/react-tooltip\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type { ReactNode, Ref } from \"react\";\nimport { cn } from \"@/utils/cn\";\n\nconst tooltipContentVariants = cva(\n \"aivex:z-50 aivex:max-w-[720px] aivex:rounded-sm aivex:bg-static-gray aivex:px-md aivex:py-xs aivex:text-body-md-regular aivex:text-text-on-color aivex:whitespace-pre-wrap aivex:break-words aivex:pointer-events-none aivex:shadow-md aivex:select-none\",\n {\n variants: {\n placement: {\n top: \"\",\n bottom: \"\",\n left: \"\",\n right: \"\",\n },\n },\n defaultVariants: {\n placement: \"top\",\n },\n },\n);\n\nconst arrowVariants = cva(\"aivex:fill-static-gray\", {\n variants: {\n placement: {\n top: \"\",\n bottom: \"\",\n left: \"\",\n right: \"\",\n },\n },\n defaultVariants: {\n placement: \"top\",\n },\n});\n\ntype TooltipPlacement = NonNullable<VariantProps<typeof tooltipContentVariants>[\"placement\"]>;\n\nexport interface TooltipProps extends VariantProps<typeof tooltipContentVariants> {\n content: ReactNode;\n children: ReactNode;\n disabled?: boolean;\n ref?: Ref<HTMLDivElement>;\n}\n\nfunction Tooltip({ content, children, placement = \"top\", disabled = false, ref }: TooltipProps) {\n const resolvedPlacement: TooltipPlacement = placement ?? \"top\";\n\n if (disabled) {\n return <>{children}</>;\n }\n\n return (\n <RadixTooltip.Provider delayDuration={0}>\n <RadixTooltip.Root>\n <RadixTooltip.Trigger asChild>\n <span ref={ref} className=\"aivex:inline-flex\">\n {children}\n </span>\n </RadixTooltip.Trigger>\n <RadixTooltip.Portal>\n <RadixTooltip.Content\n side={resolvedPlacement}\n sideOffset={8}\n className={cn(tooltipContentVariants({ placement: resolvedPlacement }))}\n >\n {content}\n <RadixTooltip.Arrow\n width={8}\n height={4}\n className={cn(arrowVariants({ placement: resolvedPlacement }))}\n />\n </RadixTooltip.Content>\n </RadixTooltip.Portal>\n </RadixTooltip.Root>\n </RadixTooltip.Provider>\n );\n}\n\nexport { Tooltip, tooltipContentVariants };\n","import * as AvatarPrimitive from \"@radix-ui/react-avatar\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type { HTMLAttributes, ReactNode, Ref } from \"react\";\nimport { Tooltip } from \"@/components/Tooltip\";\nimport { cn } from \"@/utils/cn\";\n\nconst avatarVariants = cva(\n \"aivex:inline-flex aivex:items-center aivex:justify-center aivex:shrink-0 aivex:overflow-hidden aivex:select-none aivex:leading-none aivex:text-text-primary\",\n {\n variants: {\n size: {\n xxs: \"aivex:w-4 aivex:h-4 aivex:text-label-sm\",\n xs: \"aivex:w-5 aivex:h-5 aivex:text-label-md\",\n sm: \"aivex:w-6 aivex:h-6 aivex:text-label-md\",\n md: \"aivex:w-8 aivex:h-8 aivex:text-label-lg\",\n lg: \"aivex:w-9 aivex:h-9 aivex:text-label-xl\",\n xl: \"aivex:w-12 aivex:h-12 aivex:text-label-xl\",\n \"2xl\": \"aivex:w-14 aivex:h-14 aivex:text-label-xl\",\n },\n type: {\n round: \"aivex:rounded-full aivex:bg-category-indigo-bg\",\n square: \"aivex:bg-category-indigo-bg\",\n image: \"aivex:rounded-full aivex:border aivex:border-border-subtle aivex:bg-bg-secondary\",\n },\n },\n // Square shape: size-scaled radius per Figma\n compoundVariants: [\n { type: \"square\", size: [\"xxs\", \"xs\", \"sm\"], className: \"aivex:rounded-xs\" },\n { type: \"square\", size: [\"md\", \"lg\"], className: \"aivex:rounded-sm\" },\n { type: \"square\", size: [\"xl\", \"2xl\"], className: \"aivex:rounded-md\" },\n ],\n defaultVariants: { size: \"md\", type: \"round\" },\n },\n);\n\nexport interface AvatarProps\n extends Omit<HTMLAttributes<HTMLSpanElement>, \"children\">,\n VariantProps<typeof avatarVariants> {\n src?: string;\n alt?: string;\n initials?: string;\n icon?: ReactNode;\n name?: string;\n bgColor?: string;\n showTooltip?: boolean;\n /** Fallback render delay in ms (only applies when `src` is provided). Default: 600ms. */\n delayMs?: number;\n ref?: Ref<HTMLSpanElement>;\n}\n\n/** name(또는 initials) 기반으로 결정적 색을 고르기 위한 카테고리 팔레트 */\nconst avatarColorClasses = [\n \"aivex:bg-category-blue-bg aivex:text-category-blue-text\",\n \"aivex:bg-category-green-bg aivex:text-category-green-text\",\n \"aivex:bg-category-orange-bg aivex:text-category-orange-text\",\n \"aivex:bg-category-violet-bg aivex:text-category-violet-text\",\n \"aivex:bg-category-teal-bg aivex:text-category-teal-text\",\n \"aivex:bg-category-pink-bg aivex:text-category-pink-text\",\n \"aivex:bg-category-cyan-bg aivex:text-category-cyan-text\",\n \"aivex:bg-category-red-bg aivex:text-category-red-text\",\n \"aivex:bg-category-lime-bg aivex:text-category-lime-text\",\n \"aivex:bg-category-yellow-bg aivex:text-category-yellow-text\",\n \"aivex:bg-category-indigo-bg aivex:text-category-indigo-text\",\n] as const;\n\nfunction pickColorClass(key: string): string {\n let hash = 0;\n for (let i = 0; i < key.length; i++) {\n hash = (hash * 31 + key.charCodeAt(i)) >>> 0;\n }\n return avatarColorClasses[hash % avatarColorClasses.length];\n}\n\nfunction resolveFallback({\n initials,\n name,\n icon,\n}: Pick<AvatarProps, \"initials\" | \"name\" | \"icon\">): ReactNode {\n const text = initials ?? name?.trim().slice(0, 1).toUpperCase();\n if (text) return text;\n return icon ?? null;\n}\n\nfunction Avatar({\n className,\n size,\n type,\n src,\n alt,\n initials,\n icon,\n name,\n bgColor,\n showTooltip,\n delayMs = 600,\n style,\n ref,\n ...props\n}: AvatarProps) {\n const fallback = resolveFallback({ initials, name, icon });\n // src/bgColor가 없으면 name(없으면 initials) 기준으로 카테고리 색을 자동 배정한다.\n const colorSeed = name ?? initials;\n const autoColorClass = !src && !bgColor && colorSeed ? pickColorClass(colorSeed) : undefined;\n\n const avatar = (\n <AvatarPrimitive.Root\n ref={ref}\n className={cn(avatarVariants({ size, type }), autoColorClass, className)}\n style={bgColor ? { backgroundColor: bgColor, ...style } : style}\n {...props}\n >\n {src && (\n <AvatarPrimitive.Image\n src={src}\n alt={alt ?? \"avatar\"}\n className=\"aivex:w-full aivex:h-full aivex:object-cover\"\n />\n )}\n <AvatarPrimitive.Fallback\n delayMs={src ? delayMs : 0}\n className=\"aivex:inline-flex aivex:h-full aivex:w-full aivex:items-center aivex:justify-center aivex:leading-none\"\n >\n {fallback}\n </AvatarPrimitive.Fallback>\n </AvatarPrimitive.Root>\n );\n\n return showTooltip && name ? <Tooltip content={name}>{avatar}</Tooltip> : avatar;\n}\n\nexport { Avatar, avatarVariants };\n","import { Slot } from \"@radix-ui/react-slot\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type { ButtonHTMLAttributes, ReactNode, Ref } from \"react\";\nimport { InteractionLayer } from \"@/components/InteractionLayer\";\nimport { cn } from \"@/utils/cn\";\n\nconst iconButtonVariants = cva(\n \"aivex:relative aivex:group aivex:inline-flex aivex:cursor-pointer aivex:items-center aivex:justify-center aivex:transition-colors aivex:disabled:pointer-events-none aivex:disabled:opacity-disable aivex:focus-visible:outline-none aivex:focus-visible:ring-2 aivex:focus-visible:ring-border-brand\",\n {\n variants: {\n size: {\n xs: \"aivex:size-xl aivex:rounded-xs\",\n sm: \"aivex:size-2xl aivex:rounded-xs\",\n md: \"aivex:size-3xl aivex:rounded-sm\",\n },\n shape: {\n rectangle: \"\",\n rounded: \"aivex:rounded-full\",\n },\n },\n defaultVariants: {\n size: \"sm\",\n shape: \"rectangle\",\n },\n },\n);\n\ntype IconButtonSize = \"xs\" | \"sm\" | \"md\";\ntype IconButtonShape = \"rectangle\" | \"rounded\";\n\nconst iconSizeClass: Record<IconButtonSize, string> = {\n xs: \"aivex:size-xl\",\n sm: \"aivex:size-2xl\",\n md: \"aivex:size-3xl\",\n};\n\nconst interactionInsetClass: Record<IconButtonSize, string> = {\n xs: \"aivex:-inset-2xs\",\n sm: \"aivex:-inset-xs\",\n md: \"aivex:-inset-xs\",\n};\n\nconst interactionRadiusClass: Record<IconButtonSize, Record<IconButtonShape, string>> = {\n xs: {\n rectangle: \"aivex:rounded-xs\",\n rounded: \"aivex:rounded-full\",\n },\n sm: {\n rectangle: \"aivex:rounded-sm\",\n rounded: \"aivex:rounded-full\",\n },\n md: {\n rectangle: \"aivex:rounded-md\",\n rounded: \"aivex:rounded-full\",\n },\n};\n\nexport interface IconButtonProps\n extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, \"type\">,\n VariantProps<typeof iconButtonVariants> {\n /** 아이콘 색상 — primary: 기본(어두운) 배경, white: 어두운 배경 위 */\n color?: \"primary\" | \"white\";\n /** true 이면 danger 색상 적용 (color 보다 우선) */\n error?: boolean;\n asChild?: boolean;\n children?: ReactNode;\n ref?: Ref<HTMLButtonElement>;\n}\n\nfunction IconButton({\n className,\n size = \"sm\",\n shape = \"rectangle\",\n color = \"primary\",\n error = false,\n asChild = false,\n children,\n ref,\n ...props\n}: IconButtonProps) {\n const Comp = asChild ? Slot : \"button\";\n\n const iconColor = error\n ? \"aivex:text-icon-danger\"\n : color === \"white\"\n ? \"aivex:text-static-white\"\n : \"aivex:text-icon-primary\";\n\n const interactionVariant = error ? \"danger\" : color === \"white\" ? \"white\" : \"default\";\n const iconButtonSize = size ?? \"sm\";\n const iconButtonShape = shape ?? \"rectangle\";\n\n return (\n <Comp\n ref={ref}\n type={asChild ? undefined : \"button\"}\n className={cn(iconButtonVariants({ size, shape }), iconColor, className)}\n {...props}\n >\n <InteractionLayer\n variant={interactionVariant}\n fill={false}\n interactive\n className={cn(\n interactionInsetClass[iconButtonSize],\n interactionRadiusClass[iconButtonSize][iconButtonShape],\n )}\n />\n <span\n className={cn(\n \"aivex:flex aivex:items-center aivex:justify-center aivex:shrink-0\",\n iconSizeClass[iconButtonSize],\n )}\n >\n {children}\n </span>\n </Comp>\n );\n}\n\nexport { IconButton, iconButtonVariants };\n"],"mappings":";;;;;;;;AAOA,IAAM,IAAyB,EAC7B,4PACA;CACE,UAAU,EACR,WAAW;EACT,KAAK;EACL,QAAQ;EACR,MAAM;EACN,OAAO;EACR,EACF;CACD,iBAAiB,EACf,WAAW,OACZ;CACF,CACF,EAEK,IAAgB,EAAI,0BAA0B;CAClD,UAAU,EACR,WAAW;EACT,KAAK;EACL,QAAQ;EACR,MAAM;EACN,OAAO;EACR,EACF;CACD,iBAAiB,EACf,WAAW,OACZ;CACF,CAAC;AAWF,SAAS,EAAQ,EAAE,YAAS,aAAU,eAAY,OAAO,cAAW,IAAO,UAAqB;CAC9F,IAAM,IAAsC,KAAa;AAMzD,QAJI,IACK,kBAAA,GAAA,EAAG,aAAY,CAAA,GAItB,kBAAC,EAAa,UAAd;EAAuB,eAAe;YACpC,kBAAC,EAAa,MAAd,EAAA,UAAA,CACE,kBAAC,EAAa,SAAd;GAAsB,SAAA;aACpB,kBAAC,QAAD;IAAW;IAAK,WAAU;IACvB;IACI,CAAA;GACc,CAAA,EACvB,kBAAC,EAAa,QAAd,EAAA,UACE,kBAAC,EAAa,SAAd;GACE,MAAM;GACN,YAAY;GACZ,WAAW,EAAG,EAAuB,EAAE,WAAW,GAAmB,CAAC,CAAC;a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AW,EAAG,EAAmB;GAAE;GAAM;GAAO,CAAC,EAAE,GAAW,EAAU;EACxE,GAAI;YAJN,CAME,kBAAC,GAAD;GACE,SAAS;GACT,MAAM;GACN,aAAA;GACA,WAAW,EACT,EAAsB,IACtB,EAAuB,GAAgB,GACxC;GACD,CAAA,EACF,kBAAC,QAAD;GACE,WAAW,EACT,qEACA,EAAc,GACf;GAEA;GACI,CAAA,CACF"}
1
+ {"version":3,"file":"IconButton-7v0vHj6O.js","names":[],"sources":["../src/components/Tooltip/Tooltip.tsx","../src/components/Avatar/Avatar.tsx","../src/components/IconButton/IconButton.tsx"],"sourcesContent":["\"use client\";\n\nimport * as RadixTooltip from \"@radix-ui/react-tooltip\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type { ReactNode, Ref } from \"react\";\nimport { cn } from \"@/utils/cn\";\n\nconst tooltipContentVariants = cva(\n \"aivex:z-50 aivex:max-w-[720px] aivex:rounded-sm aivex:bg-static-gray aivex:px-md aivex:py-xs aivex:text-body-md-regular aivex:text-text-on-color aivex:whitespace-pre-wrap aivex:break-words aivex:pointer-events-none aivex:shadow-md aivex:select-none\",\n {\n variants: {\n placement: {\n top: \"\",\n bottom: \"\",\n left: \"\",\n right: \"\",\n },\n },\n defaultVariants: {\n placement: \"top\",\n },\n },\n);\n\nconst arrowVariants = cva(\"aivex:fill-static-gray\", {\n variants: {\n placement: {\n top: \"\",\n bottom: \"\",\n left: \"\",\n right: \"\",\n },\n },\n defaultVariants: {\n placement: \"top\",\n },\n});\n\ntype TooltipPlacement = NonNullable<VariantProps<typeof tooltipContentVariants>[\"placement\"]>;\n\nexport interface TooltipProps extends VariantProps<typeof tooltipContentVariants> {\n content: ReactNode;\n children: ReactNode;\n disabled?: boolean;\n ref?: Ref<HTMLDivElement>;\n}\n\nfunction Tooltip({ content, children, placement = \"top\", disabled = false, ref }: TooltipProps) {\n const resolvedPlacement: TooltipPlacement = placement ?? \"top\";\n\n if (disabled) {\n return <>{children}</>;\n }\n\n return (\n <RadixTooltip.Provider delayDuration={0}>\n <RadixTooltip.Root>\n <RadixTooltip.Trigger asChild>\n <span ref={ref} className=\"aivex:inline-flex\">\n {children}\n </span>\n </RadixTooltip.Trigger>\n <RadixTooltip.Portal>\n <RadixTooltip.Content\n side={resolvedPlacement}\n sideOffset={8}\n className={cn(tooltipContentVariants({ placement: resolvedPlacement }))}\n >\n {content}\n <RadixTooltip.Arrow\n width={8}\n height={4}\n className={cn(arrowVariants({ placement: resolvedPlacement }))}\n />\n </RadixTooltip.Content>\n </RadixTooltip.Portal>\n </RadixTooltip.Root>\n </RadixTooltip.Provider>\n );\n}\n\nexport { Tooltip, tooltipContentVariants };\n","import * as AvatarPrimitive from \"@radix-ui/react-avatar\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type { HTMLAttributes, ReactNode, Ref } from \"react\";\nimport { Tooltip } from \"@/components/Tooltip\";\nimport { cn } from \"@/utils/cn\";\n\nconst avatarVariants = cva(\n \"aivex:inline-flex aivex:items-center aivex:justify-center aivex:shrink-0 aivex:overflow-hidden aivex:select-none aivex:leading-none aivex:text-text-primary\",\n {\n variants: {\n size: {\n xxs: \"aivex:w-4 aivex:h-4 aivex:text-label-sm\",\n xs: \"aivex:w-5 aivex:h-5 aivex:text-label-md\",\n sm: \"aivex:w-6 aivex:h-6 aivex:text-label-md\",\n md: \"aivex:w-8 aivex:h-8 aivex:text-label-lg\",\n lg: \"aivex:w-9 aivex:h-9 aivex:text-label-xl\",\n xl: \"aivex:w-12 aivex:h-12 aivex:text-label-xl\",\n \"2xl\": \"aivex:w-14 aivex:h-14 aivex:text-label-xl\",\n },\n type: {\n round: \"aivex:rounded-full aivex:bg-category-indigo-bg\",\n square: \"aivex:bg-category-indigo-bg\",\n image: \"aivex:rounded-full aivex:border aivex:border-border-subtle aivex:bg-bg-secondary\",\n },\n },\n // Square shape: size-scaled radius per Figma\n compoundVariants: [\n { type: \"square\", size: [\"xxs\", \"xs\", \"sm\"], className: \"aivex:rounded-xs\" },\n { type: \"square\", size: [\"md\", \"lg\"], className: \"aivex:rounded-sm\" },\n { type: \"square\", size: [\"xl\", \"2xl\"], className: \"aivex:rounded-md\" },\n ],\n defaultVariants: { size: \"md\", type: \"round\" },\n },\n);\n\nexport interface AvatarProps\n extends Omit<HTMLAttributes<HTMLSpanElement>, \"children\">,\n VariantProps<typeof avatarVariants> {\n src?: string;\n alt?: string;\n initials?: string;\n icon?: ReactNode;\n name?: string;\n bgColor?: string;\n showTooltip?: boolean;\n /** Fallback render delay in ms (only applies when `src` is provided). Default: 600ms. */\n delayMs?: number;\n ref?: Ref<HTMLSpanElement>;\n}\n\n/** name(또는 initials) 기반으로 결정적 색을 고르기 위한 카테고리 팔레트 */\nconst avatarColorClasses = [\n \"aivex:bg-category-blue-bg aivex:text-category-blue-text\",\n \"aivex:bg-category-green-bg aivex:text-category-green-text\",\n \"aivex:bg-category-orange-bg aivex:text-category-orange-text\",\n \"aivex:bg-category-violet-bg aivex:text-category-violet-text\",\n \"aivex:bg-category-teal-bg aivex:text-category-teal-text\",\n \"aivex:bg-category-pink-bg aivex:text-category-pink-text\",\n \"aivex:bg-category-cyan-bg aivex:text-category-cyan-text\",\n \"aivex:bg-category-red-bg aivex:text-category-red-text\",\n \"aivex:bg-category-lime-bg aivex:text-category-lime-text\",\n \"aivex:bg-category-yellow-bg aivex:text-category-yellow-text\",\n \"aivex:bg-category-indigo-bg aivex:text-category-indigo-text\",\n] as const;\n\nfunction pickColorClass(key: string): string {\n let hash = 0;\n for (let i = 0; i < key.length; i++) {\n hash = (hash * 31 + key.charCodeAt(i)) >>> 0;\n }\n return avatarColorClasses[hash % avatarColorClasses.length];\n}\n\nfunction resolveFallback({\n initials,\n name,\n icon,\n}: Pick<AvatarProps, \"initials\" | \"name\" | \"icon\">): ReactNode {\n const text = initials ?? name?.trim().slice(0, 1).toUpperCase();\n if (text) return text;\n return icon ?? null;\n}\n\nfunction Avatar({\n className,\n size,\n type,\n src,\n alt,\n initials,\n icon,\n name,\n bgColor,\n showTooltip,\n delayMs = 600,\n style,\n ref,\n ...props\n}: AvatarProps) {\n const fallback = resolveFallback({ initials, name, icon });\n // src/bgColor가 없으면 name(없으면 initials) 기준으로 카테고리 색을 자동 배정한다.\n const colorSeed = name ?? initials;\n const autoColorClass = !src && !bgColor && colorSeed ? pickColorClass(colorSeed) : undefined;\n\n const avatar = (\n <AvatarPrimitive.Root\n ref={ref}\n className={cn(avatarVariants({ size, type }), autoColorClass, className)}\n style={bgColor ? { backgroundColor: bgColor, ...style } : style}\n {...props}\n >\n {src && (\n <AvatarPrimitive.Image\n src={src}\n alt={alt ?? \"avatar\"}\n className=\"aivex:w-full aivex:h-full aivex:object-cover\"\n />\n )}\n <AvatarPrimitive.Fallback\n delayMs={src ? delayMs : 0}\n className=\"aivex:inline-flex aivex:h-full aivex:w-full aivex:items-center aivex:justify-center aivex:leading-none\"\n >\n {fallback}\n </AvatarPrimitive.Fallback>\n </AvatarPrimitive.Root>\n );\n\n return showTooltip && name ? <Tooltip content={name}>{avatar}</Tooltip> : avatar;\n}\n\nexport { Avatar, avatarVariants };\n","import { Slot } from \"@radix-ui/react-slot\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type { ButtonHTMLAttributes, ReactNode, Ref } from \"react\";\nimport { InteractionLayer } from \"@/components/InteractionLayer\";\nimport { cn } from \"@/utils/cn\";\n\nconst iconButtonVariants = cva(\n \"aivex:relative aivex:group aivex:inline-flex aivex:cursor-pointer aivex:items-center aivex:justify-center aivex:transition-colors aivex:disabled:pointer-events-none aivex:disabled:opacity-disable aivex:focus-visible:outline-none aivex:focus-visible:ring-2 aivex:focus-visible:ring-border-brand\",\n {\n variants: {\n size: {\n xs: \"aivex:size-xl aivex:rounded-xs\",\n sm: \"aivex:size-2xl aivex:rounded-xs\",\n md: \"aivex:size-3xl aivex:rounded-sm\",\n },\n shape: {\n rectangle: \"\",\n rounded: \"aivex:rounded-full\",\n },\n },\n defaultVariants: {\n size: \"sm\",\n shape: \"rectangle\",\n },\n },\n);\n\ntype IconButtonSize = \"xs\" | \"sm\" | \"md\";\ntype IconButtonShape = \"rectangle\" | \"rounded\";\n\nconst iconSizeClass: Record<IconButtonSize, string> = {\n xs: \"aivex:size-xl\",\n sm: \"aivex:size-2xl\",\n md: \"aivex:size-3xl\",\n};\n\nconst interactionInsetClass: Record<IconButtonSize, string> = {\n xs: \"aivex:-inset-2xs\",\n sm: \"aivex:-inset-xs\",\n md: \"aivex:-inset-xs\",\n};\n\nconst interactionRadiusClass: Record<IconButtonSize, Record<IconButtonShape, string>> = {\n xs: {\n rectangle: \"aivex:rounded-xs\",\n rounded: \"aivex:rounded-full\",\n },\n sm: {\n rectangle: \"aivex:rounded-sm\",\n rounded: \"aivex:rounded-full\",\n },\n md: {\n rectangle: \"aivex:rounded-md\",\n rounded: \"aivex:rounded-full\",\n },\n};\n\nexport interface IconButtonProps\n extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, \"type\">,\n VariantProps<typeof iconButtonVariants> {\n /** 아이콘 색상 — primary: 기본(어두운) 배경, white: 어두운 배경 위 */\n color?: \"primary\" | \"white\";\n /** true 이면 danger 색상 적용 (color 보다 우선) */\n error?: boolean;\n asChild?: boolean;\n children?: ReactNode;\n ref?: Ref<HTMLButtonElement>;\n}\n\nfunction IconButton({\n className,\n size = \"sm\",\n shape = \"rectangle\",\n color = \"primary\",\n error = false,\n asChild = false,\n children,\n ref,\n ...props\n}: IconButtonProps) {\n const Comp = asChild ? Slot : \"button\";\n\n const iconColor = error\n ? \"aivex:text-icon-danger\"\n : color === \"white\"\n ? \"aivex:text-static-white\"\n : \"aivex:text-icon-primary\";\n\n const interactionVariant = error ? \"danger\" : color === \"white\" ? \"white\" : \"default\";\n const iconButtonSize = size ?? \"sm\";\n const iconButtonShape = shape ?? \"rectangle\";\n\n return (\n <Comp\n ref={ref}\n type={asChild ? undefined : \"button\"}\n className={cn(iconButtonVariants({ size, shape }), iconColor, className)}\n {...props}\n >\n <InteractionLayer\n variant={interactionVariant}\n fill={false}\n interactive\n className={cn(\n interactionInsetClass[iconButtonSize],\n interactionRadiusClass[iconButtonSize][iconButtonShape],\n )}\n />\n <span\n className={cn(\n \"aivex:flex aivex:items-center aivex:justify-center aivex:shrink-0\",\n iconSizeClass[iconButtonSize],\n )}\n >\n {children}\n </span>\n </Comp>\n );\n}\n\nexport { IconButton, iconButtonVariants };\n"],"mappings":";;;;;;;;AAOA,IAAM,IAAyB,EAC7B,4PACA;CACE,UAAU,EACR,WAAW;EACT,KAAK;EACL,QAAQ;EACR,MAAM;EACN,OAAO;EACR,EACF;CACD,iBAAiB,EACf,WAAW,OACZ;CACF,CACF,EAEK,IAAgB,EAAI,0BAA0B;CAClD,UAAU,EACR,WAAW;EACT,KAAK;EACL,QAAQ;EACR,MAAM;EACN,OAAO;EACR,EACF;CACD,iBAAiB,EACf,WAAW,OACZ;CACF,CAAC;AAWF,SAAS,EAAQ,EAAE,YAAS,aAAU,eAAY,OAAO,cAAW,IAAO,UAAqB;CAC9F,IAAM,IAAsC,KAAa;AAMzD,QAJI,IACK,kBAAA,GAAA,EAAG,aAAY,CAAA,GAItB,kBAAC,EAAa,UAAd;EAAuB,eAAe;YACpC,kBAAC,EAAa,MAAd,EAAA,UAAA,CACE,kBAAC,EAAa,SAAd;GAAsB,SAAA;aACpB,kBAAC,QAAD;IAAW;IAAK,WAAU;IACvB;IACI,CAAA;GACc,CAAA,EACvB,kBAAC,EAAa,QAAd,EAAA,UACE,kBAAC,EAAa,SAAd;GACE,MAAM;GACN,YAAY;GACZ,WAAW,EAAG,EAAuB,EAAE,WAAW,GAAmB,CAAC,CAAC;aAHzE,CAKG,GACD,kBAAC,EAAa,OAAd;IACE,OAAO;IACP,QAAQ;IACR,WAAW,EAAG,EAAc,EAAE,WAAW,GAAmB,CAAC,CAAC;IAC9D,CAAA,CACmB;MACH,CAAA,CACJ,EAAA,CAAA;EACE,CAAA;;;;ACvE5B,IAAM,IAAiB,EACrB,+JACA;CACE,UAAU;EACR,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A,EAAc,GACf;GAEA;GACI,CAAA,CACF"}
@@ -1,2 +1,2 @@
1
- const e=require(`./Button-EEErevS-.cjs`),t=require(`./utils.cjs`);let n=require(`@radix-ui/react-avatar`);n=e.ha(n,1);let r=require(`class-variance-authority`),i=require(`@radix-ui/react-tooltip`);i=e.ha(i,1);let a=require(`react/jsx-runtime`),o=require(`@radix-ui/react-slot`);var s=(0,r.cva)(`aivex:z-50 aivex:max-w-[720px] aivex:rounded-sm aivex:bg-static-gray aivex:px-md aivex:py-xs aivex:text-body-md-regular aivex:text-text-on-color aivex:whitespace-pre-wrap aivex:break-words aivex:pointer-events-none aivex:shadow-md aivex:select-none`,{variants:{placement:{top:``,bottom:``,left:``,right:``}},defaultVariants:{placement:`top`}}),c=(0,r.cva)(`aivex:fill-static-gray`,{variants:{placement:{top:``,bottom:``,left:``,right:``}},defaultVariants:{placement:`top`}});function l({content:e,children:n,placement:r=`top`,disabled:o=!1,ref:l}){let u=r??`top`;return o?(0,a.jsx)(a.Fragment,{children:n}):(0,a.jsx)(i.Provider,{delayDuration:0,children:(0,a.jsxs)(i.Root,{children:[(0,a.jsx)(i.Trigger,{asChild:!0,children:(0,a.jsx)(`span`,{ref:l,className:`aivex:inline-flex`,children:n})}),(0,a.jsx)(i.Portal,{children:(0,a.jsxs)(i.Content,{side:u,sideOffset:8,className:t.cn(s({placement:u})),children:[e,(0,a.jsx)(i.Arrow,{width:8,height:4,className:t.cn(c({placement:u}))})]})})]})})}var u=(0,r.cva)(`aivex:inline-flex aivex:items-center aivex:justify-center aivex:shrink-0 aivex:overflow-hidden aivex:select-none aivex:leading-none aivex:text-text-primary`,{variants:{size:{xxs:`aivex:w-4 aivex:h-4 aivex:text-label-sm`,xs:`aivex:w-5 aivex:h-5 aivex:text-label-md`,sm:`aivex:w-6 aivex:h-6 aivex:text-label-md`,md:`aivex:w-8 aivex:h-8 aivex:text-label-lg`,lg:`aivex:w-9 aivex:h-9 aivex:text-label-xl`,xl:`aivex:w-12 aivex:h-12 aivex:text-label-xl`,"2xl":`aivex:w-14 aivex:h-14 aivex:text-label-xl`},type:{round:`aivex:rounded-full aivex:bg-category-indigo-bg`,square:`aivex:bg-category-indigo-bg`,image:`aivex:rounded-full aivex:border aivex:border-border-subtle aivex:bg-bg-secondary`}},compoundVariants:[{type:`square`,size:[`xxs`,`xs`,`sm`],className:`aivex:rounded-xs`},{type:`square`,size:[`md`,`lg`],className:`aivex:rounded-sm`},{type:`square`,size:[`xl`,`2xl`],className:`aivex:rounded-md`}],defaultVariants:{size:`md`,type:`round`}}),d=[`aivex:bg-category-blue-bg aivex:text-category-blue-text`,`aivex:bg-category-green-bg aivex:text-category-green-text`,`aivex:bg-category-orange-bg aivex:text-category-orange-text`,`aivex:bg-category-violet-bg aivex:text-category-violet-text`,`aivex:bg-category-teal-bg aivex:text-category-teal-text`,`aivex:bg-category-pink-bg aivex:text-category-pink-text`,`aivex:bg-category-cyan-bg aivex:text-category-cyan-text`,`aivex:bg-category-red-bg aivex:text-category-red-text`,`aivex:bg-category-lime-bg aivex:text-category-lime-text`,`aivex:bg-category-yellow-bg aivex:text-category-yellow-text`,`aivex:bg-category-indigo-bg aivex:text-category-indigo-text`];function f(e){let t=0;for(let n=0;n<e.length;n++)t=t*31+e.charCodeAt(n)>>>0;return d[t%d.length]}function p({initials:e,name:t,icon:n}){return(e??t?.trim().slice(0,1).toUpperCase())||(n??null)}function m({className:e,size:r,type:i,src:o,alt:s,initials:c,icon:d,name:m,bgColor:h,showTooltip:g,delayMs:_=600,style:v,ref:y,...b}){let x=p({initials:c,name:m,icon:d}),S=m??c,C=!o&&!h&&S?f(S):void 0,w=(0,a.jsxs)(n.Root,{ref:y,className:t.cn(u({size:r,type:i}),C,e),style:h?{backgroundColor:h,...v}:v,...b,children:[o&&(0,a.jsx)(n.Image,{src:o,alt:s??`avatar`,className:`aivex:w-full aivex:h-full aivex:object-cover`}),(0,a.jsx)(n.Fallback,{delayMs:o?_:0,className:`aivex:inline-flex aivex:h-full aivex:w-full aivex:items-center aivex:justify-center aivex:leading-none`,children:x})]});return g&&m?(0,a.jsx)(l,{content:m,children:w}):w}var h=(0,r.cva)(`aivex:relative aivex:group aivex:inline-flex aivex:cursor-pointer aivex:items-center aivex:justify-center aivex:transition-colors aivex:disabled:pointer-events-none aivex:disabled:opacity-disable aivex:focus-visible:outline-none aivex:focus-visible:ring-2 aivex:focus-visible:ring-border-brand`,{variants:{size:{xs:`aivex:size-xl aivex:rounded-xs`,sm:`aivex:size-2xl aivex:rounded-xs`,md:`aivex:size-3xl aivex:rounded-sm`},shape:{rectangle:``,rounded:`aivex:rounded-full`}},defaultVariants:{size:`sm`,shape:`rectangle`}}),g={xs:`aivex:size-xl`,sm:`aivex:size-2xl`,md:`aivex:size-3xl`},_={xs:`aivex:-inset-2xs`,sm:`aivex:-inset-xs`,md:`aivex:-inset-xs`},v={xs:{rectangle:`aivex:rounded-xs`,rounded:`aivex:rounded-full`},sm:{rectangle:`aivex:rounded-sm`,rounded:`aivex:rounded-full`},md:{rectangle:`aivex:rounded-md`,rounded:`aivex:rounded-full`}};function y({className:n,size:r=`sm`,shape:i=`rectangle`,color:s=`primary`,error:c=!1,asChild:l=!1,children:u,ref:d,...f}){let p=l?o.Slot:`button`,m=c?`aivex:text-icon-danger`:s===`white`?`aivex:text-static-white`:`aivex:text-icon-primary`,y=c?`danger`:s===`white`?`white`:`default`,b=r??`sm`,x=i??`rectangle`;return(0,a.jsxs)(p,{ref:d,type:l?void 0:`button`,className:t.cn(h({size:r,shape:i}),m,n),...f,children:[(0,a.jsx)(e.ma,{variant:y,fill:!1,interactive:!0,className:t.cn(_[b],v[b][x])}),(0,a.jsx)(`span`,{className:t.cn(`aivex:flex aivex:items-center aivex:justify-center aivex:shrink-0`,g[b]),children:u})]})}Object.defineProperty(exports,`a`,{enumerable:!0,get:function(){return l}}),Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return u}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,`o`,{enumerable:!0,get:function(){return s}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return y}});
2
- //# sourceMappingURL=IconButton-DBlsEy3m.cjs.map
1
+ const e=require(`./Button-D6MqxX_7.cjs`),t=require(`./utils.cjs`);let n=require(`@radix-ui/react-avatar`);n=e._a(n,1);let r=require(`class-variance-authority`),i=require(`@radix-ui/react-tooltip`);i=e._a(i,1);let a=require(`react/jsx-runtime`),o=require(`@radix-ui/react-slot`);var s=(0,r.cva)(`aivex:z-50 aivex:max-w-[720px] aivex:rounded-sm aivex:bg-static-gray aivex:px-md aivex:py-xs aivex:text-body-md-regular aivex:text-text-on-color aivex:whitespace-pre-wrap aivex:break-words aivex:pointer-events-none aivex:shadow-md aivex:select-none`,{variants:{placement:{top:``,bottom:``,left:``,right:``}},defaultVariants:{placement:`top`}}),c=(0,r.cva)(`aivex:fill-static-gray`,{variants:{placement:{top:``,bottom:``,left:``,right:``}},defaultVariants:{placement:`top`}});function l({content:e,children:n,placement:r=`top`,disabled:o=!1,ref:l}){let u=r??`top`;return o?(0,a.jsx)(a.Fragment,{children:n}):(0,a.jsx)(i.Provider,{delayDuration:0,children:(0,a.jsxs)(i.Root,{children:[(0,a.jsx)(i.Trigger,{asChild:!0,children:(0,a.jsx)(`span`,{ref:l,className:`aivex:inline-flex`,children:n})}),(0,a.jsx)(i.Portal,{children:(0,a.jsxs)(i.Content,{side:u,sideOffset:8,className:t.cn(s({placement:u})),children:[e,(0,a.jsx)(i.Arrow,{width:8,height:4,className:t.cn(c({placement:u}))})]})})]})})}var u=(0,r.cva)(`aivex:inline-flex aivex:items-center aivex:justify-center aivex:shrink-0 aivex:overflow-hidden aivex:select-none aivex:leading-none aivex:text-text-primary`,{variants:{size:{xxs:`aivex:w-4 aivex:h-4 aivex:text-label-sm`,xs:`aivex:w-5 aivex:h-5 aivex:text-label-md`,sm:`aivex:w-6 aivex:h-6 aivex:text-label-md`,md:`aivex:w-8 aivex:h-8 aivex:text-label-lg`,lg:`aivex:w-9 aivex:h-9 aivex:text-label-xl`,xl:`aivex:w-12 aivex:h-12 aivex:text-label-xl`,"2xl":`aivex:w-14 aivex:h-14 aivex:text-label-xl`},type:{round:`aivex:rounded-full aivex:bg-category-indigo-bg`,square:`aivex:bg-category-indigo-bg`,image:`aivex:rounded-full aivex:border aivex:border-border-subtle aivex:bg-bg-secondary`}},compoundVariants:[{type:`square`,size:[`xxs`,`xs`,`sm`],className:`aivex:rounded-xs`},{type:`square`,size:[`md`,`lg`],className:`aivex:rounded-sm`},{type:`square`,size:[`xl`,`2xl`],className:`aivex:rounded-md`}],defaultVariants:{size:`md`,type:`round`}}),d=[`aivex:bg-category-blue-bg aivex:text-category-blue-text`,`aivex:bg-category-green-bg aivex:text-category-green-text`,`aivex:bg-category-orange-bg aivex:text-category-orange-text`,`aivex:bg-category-violet-bg aivex:text-category-violet-text`,`aivex:bg-category-teal-bg aivex:text-category-teal-text`,`aivex:bg-category-pink-bg aivex:text-category-pink-text`,`aivex:bg-category-cyan-bg aivex:text-category-cyan-text`,`aivex:bg-category-red-bg aivex:text-category-red-text`,`aivex:bg-category-lime-bg aivex:text-category-lime-text`,`aivex:bg-category-yellow-bg aivex:text-category-yellow-text`,`aivex:bg-category-indigo-bg aivex:text-category-indigo-text`];function f(e){let t=0;for(let n=0;n<e.length;n++)t=t*31+e.charCodeAt(n)>>>0;return d[t%d.length]}function p({initials:e,name:t,icon:n}){return(e??t?.trim().slice(0,1).toUpperCase())||(n??null)}function m({className:e,size:r,type:i,src:o,alt:s,initials:c,icon:d,name:m,bgColor:h,showTooltip:g,delayMs:_=600,style:v,ref:y,...b}){let x=p({initials:c,name:m,icon:d}),S=m??c,C=!o&&!h&&S?f(S):void 0,w=(0,a.jsxs)(n.Root,{ref:y,className:t.cn(u({size:r,type:i}),C,e),style:h?{backgroundColor:h,...v}:v,...b,children:[o&&(0,a.jsx)(n.Image,{src:o,alt:s??`avatar`,className:`aivex:w-full aivex:h-full aivex:object-cover`}),(0,a.jsx)(n.Fallback,{delayMs:o?_:0,className:`aivex:inline-flex aivex:h-full aivex:w-full aivex:items-center aivex:justify-center aivex:leading-none`,children:x})]});return g&&m?(0,a.jsx)(l,{content:m,children:w}):w}var h=(0,r.cva)(`aivex:relative aivex:group aivex:inline-flex aivex:cursor-pointer aivex:items-center aivex:justify-center aivex:transition-colors aivex:disabled:pointer-events-none aivex:disabled:opacity-disable aivex:focus-visible:outline-none aivex:focus-visible:ring-2 aivex:focus-visible:ring-border-brand`,{variants:{size:{xs:`aivex:size-xl aivex:rounded-xs`,sm:`aivex:size-2xl aivex:rounded-xs`,md:`aivex:size-3xl aivex:rounded-sm`},shape:{rectangle:``,rounded:`aivex:rounded-full`}},defaultVariants:{size:`sm`,shape:`rectangle`}}),g={xs:`aivex:size-xl`,sm:`aivex:size-2xl`,md:`aivex:size-3xl`},_={xs:`aivex:-inset-2xs`,sm:`aivex:-inset-xs`,md:`aivex:-inset-xs`},v={xs:{rectangle:`aivex:rounded-xs`,rounded:`aivex:rounded-full`},sm:{rectangle:`aivex:rounded-sm`,rounded:`aivex:rounded-full`},md:{rectangle:`aivex:rounded-md`,rounded:`aivex:rounded-full`}};function y({className:n,size:r=`sm`,shape:i=`rectangle`,color:s=`primary`,error:c=!1,asChild:l=!1,children:u,ref:d,...f}){let p=l?o.Slot:`button`,m=c?`aivex:text-icon-danger`:s===`white`?`aivex:text-static-white`:`aivex:text-icon-primary`,y=c?`danger`:s===`white`?`white`:`default`,b=r??`sm`,x=i??`rectangle`;return(0,a.jsxs)(p,{ref:d,type:l?void 0:`button`,className:t.cn(h({size:r,shape:i}),m,n),...f,children:[(0,a.jsx)(e.ga,{variant:y,fill:!1,interactive:!0,className:t.cn(_[b],v[b][x])}),(0,a.jsx)(`span`,{className:t.cn(`aivex:flex aivex:items-center aivex:justify-center aivex:shrink-0`,g[b]),children:u})]})}Object.defineProperty(exports,`a`,{enumerable:!0,get:function(){return l}}),Object.defineProperty(exports,`i`,{enumerable:!0,get:function(){return u}}),Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,`o`,{enumerable:!0,get:function(){return s}}),Object.defineProperty(exports,`r`,{enumerable:!0,get:function(){return m}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return y}});
2
+ //# sourceMappingURL=IconButton-DwhPDE1m.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"IconButton-DBlsEy3m.cjs","names":[],"sources":["../src/components/Tooltip/Tooltip.tsx","../src/components/Avatar/Avatar.tsx","../src/components/IconButton/IconButton.tsx"],"sourcesContent":["\"use client\";\n\nimport * as RadixTooltip from \"@radix-ui/react-tooltip\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type { ReactNode, Ref } from \"react\";\nimport { cn } from \"@/utils/cn\";\n\nconst tooltipContentVariants = cva(\n \"aivex:z-50 aivex:max-w-[720px] aivex:rounded-sm aivex:bg-static-gray aivex:px-md aivex:py-xs aivex:text-body-md-regular aivex:text-text-on-color aivex:whitespace-pre-wrap aivex:break-words aivex:pointer-events-none aivex:shadow-md aivex:select-none\",\n {\n variants: {\n placement: {\n top: \"\",\n bottom: \"\",\n left: \"\",\n right: \"\",\n },\n },\n defaultVariants: {\n placement: \"top\",\n },\n },\n);\n\nconst arrowVariants = cva(\"aivex:fill-static-gray\", {\n variants: {\n placement: {\n top: \"\",\n bottom: \"\",\n left: \"\",\n right: \"\",\n },\n },\n defaultVariants: {\n placement: \"top\",\n },\n});\n\ntype TooltipPlacement = NonNullable<VariantProps<typeof tooltipContentVariants>[\"placement\"]>;\n\nexport interface TooltipProps extends VariantProps<typeof tooltipContentVariants> {\n content: ReactNode;\n children: ReactNode;\n disabled?: boolean;\n ref?: Ref<HTMLDivElement>;\n}\n\nfunction Tooltip({ content, children, placement = \"top\", disabled = false, ref }: TooltipProps) {\n const resolvedPlacement: TooltipPlacement = placement ?? \"top\";\n\n if (disabled) {\n return <>{children}</>;\n }\n\n return (\n <RadixTooltip.Provider delayDuration={0}>\n <RadixTooltip.Root>\n <RadixTooltip.Trigger asChild>\n <span ref={ref} className=\"aivex:inline-flex\">\n {children}\n </span>\n </RadixTooltip.Trigger>\n <RadixTooltip.Portal>\n <RadixTooltip.Content\n side={resolvedPlacement}\n sideOffset={8}\n className={cn(tooltipContentVariants({ placement: resolvedPlacement }))}\n >\n {content}\n <RadixTooltip.Arrow\n width={8}\n height={4}\n className={cn(arrowVariants({ placement: resolvedPlacement }))}\n />\n </RadixTooltip.Content>\n </RadixTooltip.Portal>\n </RadixTooltip.Root>\n </RadixTooltip.Provider>\n );\n}\n\nexport { Tooltip, tooltipContentVariants };\n","import * as AvatarPrimitive from \"@radix-ui/react-avatar\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type { HTMLAttributes, ReactNode, Ref } from \"react\";\nimport { Tooltip } from \"@/components/Tooltip\";\nimport { cn } from \"@/utils/cn\";\n\nconst avatarVariants = cva(\n \"aivex:inline-flex aivex:items-center aivex:justify-center aivex:shrink-0 aivex:overflow-hidden aivex:select-none aivex:leading-none aivex:text-text-primary\",\n {\n variants: {\n size: {\n xxs: \"aivex:w-4 aivex:h-4 aivex:text-label-sm\",\n xs: \"aivex:w-5 aivex:h-5 aivex:text-label-md\",\n sm: \"aivex:w-6 aivex:h-6 aivex:text-label-md\",\n md: \"aivex:w-8 aivex:h-8 aivex:text-label-lg\",\n lg: \"aivex:w-9 aivex:h-9 aivex:text-label-xl\",\n xl: \"aivex:w-12 aivex:h-12 aivex:text-label-xl\",\n \"2xl\": \"aivex:w-14 aivex:h-14 aivex:text-label-xl\",\n },\n type: {\n round: \"aivex:rounded-full aivex:bg-category-indigo-bg\",\n square: \"aivex:bg-category-indigo-bg\",\n image: \"aivex:rounded-full aivex:border aivex:border-border-subtle aivex:bg-bg-secondary\",\n },\n },\n // Square shape: size-scaled radius per Figma\n compoundVariants: [\n { type: \"square\", size: [\"xxs\", \"xs\", \"sm\"], className: \"aivex:rounded-xs\" },\n { type: \"square\", size: [\"md\", \"lg\"], className: \"aivex:rounded-sm\" },\n { type: \"square\", size: [\"xl\", \"2xl\"], className: \"aivex:rounded-md\" },\n ],\n defaultVariants: { size: \"md\", type: \"round\" },\n },\n);\n\nexport interface AvatarProps\n extends Omit<HTMLAttributes<HTMLSpanElement>, \"children\">,\n VariantProps<typeof avatarVariants> {\n src?: string;\n alt?: string;\n initials?: string;\n icon?: ReactNode;\n name?: string;\n bgColor?: string;\n showTooltip?: boolean;\n /** Fallback render delay in ms (only applies when `src` is provided). Default: 600ms. */\n delayMs?: number;\n ref?: Ref<HTMLSpanElement>;\n}\n\n/** name(또는 initials) 기반으로 결정적 색을 고르기 위한 카테고리 팔레트 */\nconst avatarColorClasses = [\n \"aivex:bg-category-blue-bg aivex:text-category-blue-text\",\n \"aivex:bg-category-green-bg aivex:text-category-green-text\",\n \"aivex:bg-category-orange-bg aivex:text-category-orange-text\",\n \"aivex:bg-category-violet-bg aivex:text-category-violet-text\",\n \"aivex:bg-category-teal-bg aivex:text-category-teal-text\",\n \"aivex:bg-category-pink-bg aivex:text-category-pink-text\",\n \"aivex:bg-category-cyan-bg aivex:text-category-cyan-text\",\n \"aivex:bg-category-red-bg aivex:text-category-red-text\",\n \"aivex:bg-category-lime-bg aivex:text-category-lime-text\",\n \"aivex:bg-category-yellow-bg aivex:text-category-yellow-text\",\n \"aivex:bg-category-indigo-bg aivex:text-category-indigo-text\",\n] as const;\n\nfunction pickColorClass(key: string): string {\n let hash = 0;\n for (let i = 0; i < key.length; i++) {\n hash = (hash * 31 + key.charCodeAt(i)) >>> 0;\n }\n return avatarColorClasses[hash % avatarColorClasses.length];\n}\n\nfunction resolveFallback({\n initials,\n name,\n icon,\n}: Pick<AvatarProps, \"initials\" | \"name\" | \"icon\">): ReactNode {\n const text = initials ?? name?.trim().slice(0, 1).toUpperCase();\n if (text) return text;\n return icon ?? null;\n}\n\nfunction Avatar({\n className,\n size,\n type,\n src,\n alt,\n initials,\n icon,\n name,\n bgColor,\n showTooltip,\n delayMs = 600,\n style,\n ref,\n ...props\n}: AvatarProps) {\n const fallback = resolveFallback({ initials, name, icon });\n // src/bgColor가 없으면 name(없으면 initials) 기준으로 카테고리 색을 자동 배정한다.\n const colorSeed = name ?? initials;\n const autoColorClass = !src && !bgColor && colorSeed ? pickColorClass(colorSeed) : undefined;\n\n const avatar = (\n <AvatarPrimitive.Root\n ref={ref}\n className={cn(avatarVariants({ size, type }), autoColorClass, className)}\n style={bgColor ? { backgroundColor: bgColor, ...style } : style}\n {...props}\n >\n {src && (\n <AvatarPrimitive.Image\n src={src}\n alt={alt ?? \"avatar\"}\n className=\"aivex:w-full aivex:h-full aivex:object-cover\"\n />\n )}\n <AvatarPrimitive.Fallback\n delayMs={src ? delayMs : 0}\n className=\"aivex:inline-flex aivex:h-full aivex:w-full aivex:items-center aivex:justify-center aivex:leading-none\"\n >\n {fallback}\n </AvatarPrimitive.Fallback>\n </AvatarPrimitive.Root>\n );\n\n return showTooltip && name ? <Tooltip content={name}>{avatar}</Tooltip> : avatar;\n}\n\nexport { Avatar, avatarVariants };\n","import { Slot } from \"@radix-ui/react-slot\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type { ButtonHTMLAttributes, ReactNode, Ref } from \"react\";\nimport { InteractionLayer } from \"@/components/InteractionLayer\";\nimport { cn } from \"@/utils/cn\";\n\nconst iconButtonVariants = cva(\n \"aivex:relative aivex:group aivex:inline-flex aivex:cursor-pointer aivex:items-center aivex:justify-center aivex:transition-colors aivex:disabled:pointer-events-none aivex:disabled:opacity-disable aivex:focus-visible:outline-none aivex:focus-visible:ring-2 aivex:focus-visible:ring-border-brand\",\n {\n variants: {\n size: {\n xs: \"aivex:size-xl aivex:rounded-xs\",\n sm: \"aivex:size-2xl aivex:rounded-xs\",\n md: \"aivex:size-3xl aivex:rounded-sm\",\n },\n shape: {\n rectangle: \"\",\n rounded: \"aivex:rounded-full\",\n },\n },\n defaultVariants: {\n size: \"sm\",\n shape: \"rectangle\",\n },\n },\n);\n\ntype IconButtonSize = \"xs\" | \"sm\" | \"md\";\ntype IconButtonShape = \"rectangle\" | \"rounded\";\n\nconst iconSizeClass: Record<IconButtonSize, string> = {\n xs: \"aivex:size-xl\",\n sm: \"aivex:size-2xl\",\n md: \"aivex:size-3xl\",\n};\n\nconst interactionInsetClass: Record<IconButtonSize, string> = {\n xs: \"aivex:-inset-2xs\",\n sm: \"aivex:-inset-xs\",\n md: \"aivex:-inset-xs\",\n};\n\nconst interactionRadiusClass: Record<IconButtonSize, Record<IconButtonShape, string>> = {\n xs: {\n rectangle: \"aivex:rounded-xs\",\n rounded: \"aivex:rounded-full\",\n },\n sm: {\n rectangle: \"aivex:rounded-sm\",\n rounded: \"aivex:rounded-full\",\n },\n md: {\n rectangle: \"aivex:rounded-md\",\n rounded: \"aivex:rounded-full\",\n },\n};\n\nexport interface IconButtonProps\n extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, \"type\">,\n VariantProps<typeof iconButtonVariants> {\n /** 아이콘 색상 — primary: 기본(어두운) 배경, white: 어두운 배경 위 */\n color?: \"primary\" | \"white\";\n /** true 이면 danger 색상 적용 (color 보다 우선) */\n error?: boolean;\n asChild?: boolean;\n children?: ReactNode;\n ref?: Ref<HTMLButtonElement>;\n}\n\nfunction IconButton({\n className,\n size = \"sm\",\n shape = \"rectangle\",\n color = \"primary\",\n error = false,\n asChild = false,\n children,\n ref,\n ...props\n}: IconButtonProps) {\n const Comp = asChild ? Slot : \"button\";\n\n const iconColor = error\n ? \"aivex:text-icon-danger\"\n : color === \"white\"\n ? \"aivex:text-static-white\"\n : \"aivex:text-icon-primary\";\n\n const interactionVariant = error ? \"danger\" : color === \"white\" ? \"white\" : \"default\";\n const iconButtonSize = size ?? \"sm\";\n const iconButtonShape = shape ?? \"rectangle\";\n\n return (\n <Comp\n ref={ref}\n type={asChild ? undefined : \"button\"}\n className={cn(iconButtonVariants({ size, shape }), iconColor, className)}\n {...props}\n >\n <InteractionLayer\n variant={interactionVariant}\n fill={false}\n interactive\n className={cn(\n interactionInsetClass[iconButtonSize],\n interactionRadiusClass[iconButtonSize][iconButtonShape],\n )}\n />\n <span\n className={cn(\n \"aivex:flex aivex:items-center aivex:justify-center aivex:shrink-0\",\n iconSizeClass[iconButtonSize],\n )}\n >\n {children}\n </span>\n </Comp>\n );\n}\n\nexport { IconButton, iconButtonVariants };\n"],"mappings":"sRAOA,IAAM,GAAA,EAAA,EAAA,KACJ,2PACA,CACE,SAAU,CACR,UAAW,CACT,IAAK,GACL,OAAQ,GACR,KAAM,GACN,MAAO,GACR,CACF,CACD,gBAAiB,CACf,UAAW,MACZ,CACF,CACF,CAEK,GAAA,EAAA,EAAA,KAAoB,yBAA0B,CAClD,SAAU,CACR,UAAW,CACT,IAAK,GACL,OAAQ,GACR,KAAM,GACN,MAAO,GACR,CACF,CACD,gBAAiB,CACf,UAAW,MACZ,CACF,CAAC,CAWF,SAAS,EAAQ,CAAE,UAAS,WAAU,YAAY,MAAO,WAAW,GAAO,OAAqB,CAC9F,IAAM,EAAsC,GAAa,MAMzD,OAJI,GACK,EAAA,EAAA,KAAA,EAAA,SAAA,CAAG,WAAY,CAAA,EAItB,EAAA,EAAA,KAAC,EAAa,SAAd,CAAuB,cAAe,YACpC,EAAA,EAAA,MAAC,EAAa,KAAd,CAAA,SAAA,EACE,EAAA,EAAA,KAAC,EAAa,QAAd,CAAsB,QAAA,aACpB,EAAA,EAAA,KAAC,OAAD,CAAW,MAAK,UAAU,oBACvB,WACI,CAAA,CACc,CAAA,EACvB,EAAA,EAAA,KAAC,EAAa,OAAd,CAAA,UACE,EAAA,EAAA,MAAC,EAAa,QAAd,CACE,KAAM,EACN,WAAY,EACZ,UAAW,EAAA,GAAG,EAAuB,CAAE,UAAW,EAAmB,CAAC,CAAC,UAHzE,CAKG,GACD,EAAA,EAAA,KAAC,EAAa,MAAd,CACE,MAAO,EACP,OAAQ,EACR,UAAW,EAAA,GAAG,EAAc,CAAE,UAAW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KAAM,EAAU,IAAA,GAAY,SAC5B,UAAW,EAAA,GAAG,EAAmB,CAAE,OAAM,QAAO,CAAC,CAAE,EAAW,EAAU,CACxE,GAAI,WAJN,EAME,EAAA,EAAA,KAAC,EAAA,GAAD,CACE,QAAS,EACT,KAAM,GACN,YAAA,GACA,UAAW,EAAA,GACT,EAAsB,GACtB,EAAuB,GAAgB,GACxC,CACD,CAAA,EACF,EAAA,EAAA,KAAC,OAAD,CACE,UAAW,EAAA,GACT,oEACA,EAAc,GACf,CAEA,WACI,CAAA,CACF"}
1
+ {"version":3,"file":"IconButton-DwhPDE1m.cjs","names":[],"sources":["../src/components/Tooltip/Tooltip.tsx","../src/components/Avatar/Avatar.tsx","../src/components/IconButton/IconButton.tsx"],"sourcesContent":["\"use client\";\n\nimport * as RadixTooltip from \"@radix-ui/react-tooltip\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type { ReactNode, Ref } from \"react\";\nimport { cn } from \"@/utils/cn\";\n\nconst tooltipContentVariants = cva(\n \"aivex:z-50 aivex:max-w-[720px] aivex:rounded-sm aivex:bg-static-gray aivex:px-md aivex:py-xs aivex:text-body-md-regular aivex:text-text-on-color aivex:whitespace-pre-wrap aivex:break-words aivex:pointer-events-none aivex:shadow-md aivex:select-none\",\n {\n variants: {\n placement: {\n top: \"\",\n bottom: \"\",\n left: \"\",\n right: \"\",\n },\n },\n defaultVariants: {\n placement: \"top\",\n },\n },\n);\n\nconst arrowVariants = cva(\"aivex:fill-static-gray\", {\n variants: {\n placement: {\n top: \"\",\n bottom: \"\",\n left: \"\",\n right: \"\",\n },\n },\n defaultVariants: {\n placement: \"top\",\n },\n});\n\ntype TooltipPlacement = NonNullable<VariantProps<typeof tooltipContentVariants>[\"placement\"]>;\n\nexport interface TooltipProps extends VariantProps<typeof tooltipContentVariants> {\n content: ReactNode;\n children: ReactNode;\n disabled?: boolean;\n ref?: Ref<HTMLDivElement>;\n}\n\nfunction Tooltip({ content, children, placement = \"top\", disabled = false, ref }: TooltipProps) {\n const resolvedPlacement: TooltipPlacement = placement ?? \"top\";\n\n if (disabled) {\n return <>{children}</>;\n }\n\n return (\n <RadixTooltip.Provider delayDuration={0}>\n <RadixTooltip.Root>\n <RadixTooltip.Trigger asChild>\n <span ref={ref} className=\"aivex:inline-flex\">\n {children}\n </span>\n </RadixTooltip.Trigger>\n <RadixTooltip.Portal>\n <RadixTooltip.Content\n side={resolvedPlacement}\n sideOffset={8}\n className={cn(tooltipContentVariants({ placement: resolvedPlacement }))}\n >\n {content}\n <RadixTooltip.Arrow\n width={8}\n height={4}\n className={cn(arrowVariants({ placement: resolvedPlacement }))}\n />\n </RadixTooltip.Content>\n </RadixTooltip.Portal>\n </RadixTooltip.Root>\n </RadixTooltip.Provider>\n );\n}\n\nexport { Tooltip, tooltipContentVariants };\n","import * as AvatarPrimitive from \"@radix-ui/react-avatar\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type { HTMLAttributes, ReactNode, Ref } from \"react\";\nimport { Tooltip } from \"@/components/Tooltip\";\nimport { cn } from \"@/utils/cn\";\n\nconst avatarVariants = cva(\n \"aivex:inline-flex aivex:items-center aivex:justify-center aivex:shrink-0 aivex:overflow-hidden aivex:select-none aivex:leading-none aivex:text-text-primary\",\n {\n variants: {\n size: {\n xxs: \"aivex:w-4 aivex:h-4 aivex:text-label-sm\",\n xs: \"aivex:w-5 aivex:h-5 aivex:text-label-md\",\n sm: \"aivex:w-6 aivex:h-6 aivex:text-label-md\",\n md: \"aivex:w-8 aivex:h-8 aivex:text-label-lg\",\n lg: \"aivex:w-9 aivex:h-9 aivex:text-label-xl\",\n xl: \"aivex:w-12 aivex:h-12 aivex:text-label-xl\",\n \"2xl\": \"aivex:w-14 aivex:h-14 aivex:text-label-xl\",\n },\n type: {\n round: \"aivex:rounded-full aivex:bg-category-indigo-bg\",\n square: \"aivex:bg-category-indigo-bg\",\n image: \"aivex:rounded-full aivex:border aivex:border-border-subtle aivex:bg-bg-secondary\",\n },\n },\n // Square shape: size-scaled radius per Figma\n compoundVariants: [\n { type: \"square\", size: [\"xxs\", \"xs\", \"sm\"], className: \"aivex:rounded-xs\" },\n { type: \"square\", size: [\"md\", \"lg\"], className: \"aivex:rounded-sm\" },\n { type: \"square\", size: [\"xl\", \"2xl\"], className: \"aivex:rounded-md\" },\n ],\n defaultVariants: { size: \"md\", type: \"round\" },\n },\n);\n\nexport interface AvatarProps\n extends Omit<HTMLAttributes<HTMLSpanElement>, \"children\">,\n VariantProps<typeof avatarVariants> {\n src?: string;\n alt?: string;\n initials?: string;\n icon?: ReactNode;\n name?: string;\n bgColor?: string;\n showTooltip?: boolean;\n /** Fallback render delay in ms (only applies when `src` is provided). Default: 600ms. */\n delayMs?: number;\n ref?: Ref<HTMLSpanElement>;\n}\n\n/** name(또는 initials) 기반으로 결정적 색을 고르기 위한 카테고리 팔레트 */\nconst avatarColorClasses = [\n \"aivex:bg-category-blue-bg aivex:text-category-blue-text\",\n \"aivex:bg-category-green-bg aivex:text-category-green-text\",\n \"aivex:bg-category-orange-bg aivex:text-category-orange-text\",\n \"aivex:bg-category-violet-bg aivex:text-category-violet-text\",\n \"aivex:bg-category-teal-bg aivex:text-category-teal-text\",\n \"aivex:bg-category-pink-bg aivex:text-category-pink-text\",\n \"aivex:bg-category-cyan-bg aivex:text-category-cyan-text\",\n \"aivex:bg-category-red-bg aivex:text-category-red-text\",\n \"aivex:bg-category-lime-bg aivex:text-category-lime-text\",\n \"aivex:bg-category-yellow-bg aivex:text-category-yellow-text\",\n \"aivex:bg-category-indigo-bg aivex:text-category-indigo-text\",\n] as const;\n\nfunction pickColorClass(key: string): string {\n let hash = 0;\n for (let i = 0; i < key.length; i++) {\n hash = (hash * 31 + key.charCodeAt(i)) >>> 0;\n }\n return avatarColorClasses[hash % avatarColorClasses.length];\n}\n\nfunction resolveFallback({\n initials,\n name,\n icon,\n}: Pick<AvatarProps, \"initials\" | \"name\" | \"icon\">): ReactNode {\n const text = initials ?? name?.trim().slice(0, 1).toUpperCase();\n if (text) return text;\n return icon ?? null;\n}\n\nfunction Avatar({\n className,\n size,\n type,\n src,\n alt,\n initials,\n icon,\n name,\n bgColor,\n showTooltip,\n delayMs = 600,\n style,\n ref,\n ...props\n}: AvatarProps) {\n const fallback = resolveFallback({ initials, name, icon });\n // src/bgColor가 없으면 name(없으면 initials) 기준으로 카테고리 색을 자동 배정한다.\n const colorSeed = name ?? initials;\n const autoColorClass = !src && !bgColor && colorSeed ? pickColorClass(colorSeed) : undefined;\n\n const avatar = (\n <AvatarPrimitive.Root\n ref={ref}\n className={cn(avatarVariants({ size, type }), autoColorClass, className)}\n style={bgColor ? { backgroundColor: bgColor, ...style } : style}\n {...props}\n >\n {src && (\n <AvatarPrimitive.Image\n src={src}\n alt={alt ?? \"avatar\"}\n className=\"aivex:w-full aivex:h-full aivex:object-cover\"\n />\n )}\n <AvatarPrimitive.Fallback\n delayMs={src ? delayMs : 0}\n className=\"aivex:inline-flex aivex:h-full aivex:w-full aivex:items-center aivex:justify-center aivex:leading-none\"\n >\n {fallback}\n </AvatarPrimitive.Fallback>\n </AvatarPrimitive.Root>\n );\n\n return showTooltip && name ? <Tooltip content={name}>{avatar}</Tooltip> : avatar;\n}\n\nexport { Avatar, avatarVariants };\n","import { Slot } from \"@radix-ui/react-slot\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport type { ButtonHTMLAttributes, ReactNode, Ref } from \"react\";\nimport { InteractionLayer } from \"@/components/InteractionLayer\";\nimport { cn } from \"@/utils/cn\";\n\nconst iconButtonVariants = cva(\n \"aivex:relative aivex:group aivex:inline-flex aivex:cursor-pointer aivex:items-center aivex:justify-center aivex:transition-colors aivex:disabled:pointer-events-none aivex:disabled:opacity-disable aivex:focus-visible:outline-none aivex:focus-visible:ring-2 aivex:focus-visible:ring-border-brand\",\n {\n variants: {\n size: {\n xs: \"aivex:size-xl aivex:rounded-xs\",\n sm: \"aivex:size-2xl aivex:rounded-xs\",\n md: \"aivex:size-3xl aivex:rounded-sm\",\n },\n shape: {\n rectangle: \"\",\n rounded: \"aivex:rounded-full\",\n },\n },\n defaultVariants: {\n size: \"sm\",\n shape: \"rectangle\",\n },\n },\n);\n\ntype IconButtonSize = \"xs\" | \"sm\" | \"md\";\ntype IconButtonShape = \"rectangle\" | \"rounded\";\n\nconst iconSizeClass: Record<IconButtonSize, string> = {\n xs: \"aivex:size-xl\",\n sm: \"aivex:size-2xl\",\n md: \"aivex:size-3xl\",\n};\n\nconst interactionInsetClass: Record<IconButtonSize, string> = {\n xs: \"aivex:-inset-2xs\",\n sm: \"aivex:-inset-xs\",\n md: \"aivex:-inset-xs\",\n};\n\nconst interactionRadiusClass: Record<IconButtonSize, Record<IconButtonShape, string>> = {\n xs: {\n rectangle: \"aivex:rounded-xs\",\n rounded: \"aivex:rounded-full\",\n },\n sm: {\n rectangle: \"aivex:rounded-sm\",\n rounded: \"aivex:rounded-full\",\n },\n md: {\n rectangle: \"aivex:rounded-md\",\n rounded: \"aivex:rounded-full\",\n },\n};\n\nexport interface IconButtonProps\n extends Omit<ButtonHTMLAttributes<HTMLButtonElement>, \"type\">,\n VariantProps<typeof iconButtonVariants> {\n /** 아이콘 색상 — primary: 기본(어두운) 배경, white: 어두운 배경 위 */\n color?: \"primary\" | \"white\";\n /** true 이면 danger 색상 적용 (color 보다 우선) */\n error?: boolean;\n asChild?: boolean;\n children?: ReactNode;\n ref?: Ref<HTMLButtonElement>;\n}\n\nfunction IconButton({\n className,\n size = \"sm\",\n shape = \"rectangle\",\n color = \"primary\",\n error = false,\n asChild = false,\n children,\n ref,\n ...props\n}: IconButtonProps) {\n const Comp = asChild ? Slot : \"button\";\n\n const iconColor = error\n ? \"aivex:text-icon-danger\"\n : color === \"white\"\n ? \"aivex:text-static-white\"\n : \"aivex:text-icon-primary\";\n\n const interactionVariant = error ? \"danger\" : color === \"white\" ? \"white\" : \"default\";\n const iconButtonSize = size ?? \"sm\";\n const iconButtonShape = shape ?? \"rectangle\";\n\n return (\n <Comp\n ref={ref}\n type={asChild ? undefined : \"button\"}\n className={cn(iconButtonVariants({ size, shape }), iconColor, className)}\n {...props}\n >\n <InteractionLayer\n variant={interactionVariant}\n fill={false}\n interactive\n className={cn(\n interactionInsetClass[iconButtonSize],\n interactionRadiusClass[iconButtonSize][iconButtonShape],\n )}\n />\n <span\n className={cn(\n \"aivex:flex aivex:items-center aivex:justify-center aivex:shrink-0\",\n iconSizeClass[iconButtonSize],\n )}\n >\n {children}\n </span>\n </Comp>\n );\n}\n\nexport { IconButton, iconButtonVariants };\n"],"mappings":"sRAOA,IAAM,GAAA,EAAA,EAAA,KACJ,2PACA,CACE,SAAU,CACR,UAAW,CACT,IAAK,GACL,OAAQ,GACR,KAAM,GACN,MAAO,GACR,CACF,CACD,gBAAiB,CACf,UAAW,MACZ,CACF,CACF,CAEK,GAAA,EAAA,EAAA,KAAoB,yBAA0B,CAClD,SAAU,CACR,UAAW,CACT,IAAK,GACL,OAAQ,GACR,KAAM,GACN,MAAO,GACR,CACF,CACD,gBAAiB,CACf,UAAW,MACZ,CACF,CAAC,CAWF,SAAS,EAAQ,CAAE,UAAS,WAAU,YAAY,MAAO,WAAW,GAAO,OAAqB,CAC9F,IAAM,EAAsC,GAAa,MAMzD,OAJI,GACK,EAAA,EAAA,KAAA,EAAA,SAAA,CAAG,WAAY,CAAA,EAItB,EAAA,EAAA,KAAC,EAAa,SAAd,CAAuB,cAAe,YACpC,EAAA,EAAA,MAAC,EAAa,KAAd,CAAA,SAAA,EACE,EAAA,EAAA,KAAC,EAAa,QAAd,CAAsB,QAAA,aACpB,EAAA,EAAA,KAAC,OAAD,CAAW,MAAK,UAAU,oBACvB,WACI,CAAA,CACc,CAAA,EACvB,EAAA,EAAA,KAAC,EAAa,OAAd,CAAA,UACE,EAAA,EAAA,MAAC,EAAa,QAAd,CACE,KAAM,EACN,WAAY,EACZ,UAAW,EAAA,GAAG,EAAuB,CAAE,UAAW,EAAmB,CAAC,CAAC,UAHzE,CAKG,GACD,EAAA,EAAA,KAAC,EAAa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AQ,KACzB,EAAkB,GAAS,YAEjC,OACE,EAAA,EAAA,MAAC,EAAD,CACO,MACL,KAAM,EAAU,IAAA,GAAY,SAC5B,UAAW,EAAA,GAAG,EAAmB,CAAE,OAAM,QAAO,CAAC,CAAE,EAAW,EAAU,CACxE,GAAI,WAJN,EAME,EAAA,EAAA,KAAC,EAAA,GAAD,CACE,QAAS,EACT,KAAM,GACN,YAAA,GACA,UAAW,EAAA,GACT,EAAsB,GACtB,EAAuB,GAAgB,GACxC,CACD,CAAA,EACF,EAAA,EAAA,KAAC,OAAD,CACE,UAAW,EAAA,GACT,oEACA,EAAc,GACf,CAEA,WACI,CAAA,CACF"}
package/dist/comment.cjs CHANGED
@@ -1,4 +1,4 @@
1
- "use client";require(`./styles.css`),Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`./Button-EEErevS-.cjs`),t=require(`./IconButton-DBlsEy3m.cjs`);let n=require(`react/jsx-runtime`),r=require(`react`),i=require(`@tiptap/extension-mention`);i=e.ha(i,1);let a=require(`@tiptap/extension-placeholder`);a=e.ha(a,1);let o=require(`@tiptap/react`),s=require(`@tiptap/starter-kit`);s=e.ha(s,1);let c=require(`tippy.js`);c=e.ha(c,1);var l=/@\[([^\]]*)\]\(([^)]*)\)/g;function u(e){return{type:`doc`,content:e.split(`
1
+ "use client";require(`./styles.css`),Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});const e=require(`./Button-D6MqxX_7.cjs`),t=require(`./IconButton-DwhPDE1m.cjs`);let n=require(`react/jsx-runtime`),r=require(`react`),i=require(`@tiptap/extension-mention`);i=e._a(i,1);let a=require(`@tiptap/extension-placeholder`);a=e._a(a,1);let o=require(`@tiptap/react`),s=require(`@tiptap/starter-kit`);s=e._a(s,1);let c=require(`tippy.js`);c=e._a(c,1);var l=/@\[([^\]]*)\]\(([^)]*)\)/g;function u(e){return{type:`doc`,content:e.split(`
2
2
  `).map(e=>{let t=[],n=0;for(let r of e.matchAll(l)){let[i,a,o]=r,s=r.index??0;s>n&&t.push({type:`text`,text:e.slice(n,s)}),t.push({type:`mention`,attrs:{id:o,label:a}}),n=s+i.length}return n<e.length&&t.push({type:`text`,text:e.slice(n)}),t.length>0?{type:`paragraph`,content:t}:{type:`paragraph`}})}}function d(e){if(!e?.content)return``;let t=e=>e.type===`mention`&&e.attrs?`@[${e.attrs.label}](${e.attrs.id})`:e.type===`text`?e.text||``:e.type===`hardBreak`?`
3
3
  `:e.content?e.content.map(t).join(``):``;return e.content.map(t).join(`
4
4
  `)}var f=(0,r.memo)(function({items:e,command:i,emptyText:a=`No results found.`,ref:o}){let[s,c]=(0,r.useState)(0),l=(0,r.useRef)([]),u=(0,r.useCallback)(t=>{let n=e[t];n&&i(n)},[e,i]),d=(0,r.useCallback)(t=>{c(n=>{let r=e.length;return t===`up`?(n+r-1)%r:(n+1)%r})},[e.length]),f=(0,r.useCallback)(e=>{switch(e.key){case`ArrowUp`:return d(`up`),!0;case`ArrowDown`:return d(`down`),!0;case`Enter`:return u(s),!0;default:return!1}},[d,u,s]);return(0,r.useEffect)(()=>{c(0),l.current=e.map(()=>null)},[e]),(0,r.useEffect)(()=>{l.current[s]?.scrollIntoView({behavior:`smooth`,block:`nearest`})},[s]),(0,r.useImperativeHandle)(o,()=>({onKeyDown:f}),[f]),e.length?(0,n.jsx)(`div`,{className:`aivex:h-full aivex:max-h-[248px] aivex:min-w-[298px] aivex:max-w-[328px] aivex:overflow-y-auto aivex:rounded-lg aivex:border aivex:border-border-subtle aivex:bg-bg-primary aivex:py-2 aivex:shadow-xl`,children:e.map((e,r)=>(0,n.jsxs)(`div`,{ref:e=>{l.current[r]=e},className:`aivex:flex aivex:h-[52px] aivex:cursor-pointer aivex:items-center aivex:gap-2 aivex:px-4 aivex:py-2 ${s===r?`aivex:bg-bg-brand-subtle`:``}`,onClick:()=>u(r),children:[(0,n.jsx)(t.r,{size:`sm`,src:e.avatarUrl,bgColor:e.color,name:e.name}),(0,n.jsxs)(`div`,{className:`aivex:flex aivex:max-w-[260px] aivex:flex-col`,children:[(0,n.jsx)(`div`,{className:`aivex:truncate aivex:text-label-md aivex:text-text-primary`,children:e.name}),e.email?(0,n.jsx)(`div`,{className:`aivex:truncate aivex:text-body-sm-regular aivex:text-text-secondary`,children:e.email}):null]})]},e.id))}):(0,n.jsx)(`div`,{className:`aivex:min-w-[298px] aivex:max-w-[328px] aivex:rounded-lg aivex:border aivex:border-border-subtle aivex:bg-bg-primary aivex:py-2 aivex:shadow-xl`,children:(0,n.jsx)(`div`,{className:`aivex:p-2 aivex:text-body-md-regular aivex:text-text-secondary`,children:a})})}),p=(e,t,n)=>(0,r.useMemo)(()=>{let r=t=>{if(!t)return e;let n=t.toLowerCase();return e.filter(e=>e.name.toLowerCase().includes(n)||(e.email??``).toLowerCase().includes(n))},i=e=>t=>{e({id:t.id,label:t.name})};return{items:({query:e})=>r(e),render:()=>{let e=null,r=null;return{onStart:a=>{e=new o.ReactRenderer(f,{props:{...a,emptyText:n,command:i(a.command)},editor:a.editor}),a.clientRect&&(r=(0,c.default)(`body`,{getReferenceClientRect:a.clientRect,appendTo:()=>document.body,content:e.element,showOnCreate:!0,interactive:!0,trigger:`manual`,placement:`bottom-start`}),t?.(!0))},onUpdate(t){e?.updateProps({...t,emptyText:n,command:i(t.command)}),t.clientRect&&r?.[0]?.setProps({getReferenceClientRect:t.clientRect})},onKeyDown(n){return n.event.key===`Escape`?(r?.[0]&&!r[0].state.isDestroyed&&r[0].hide(),t?.(!1),!0):e?.ref?.onKeyDown(n.event)||!1},onExit(){r?.[0]&&!r[0].state.isDestroyed&&r[0].destroy(),e?.destroy(),r=null,e=null,t?.(!1)}}}}},[e,t,n]);function m({value:e,onChange:t,placeholder:c,onSubmit:l,onEscape:f,userList:m=[],initialContent:h,mentionEmptyText:g,autoFocus:_=!0,handleRef:v}){let y=(0,r.useRef)(null),[b,x]=(0,r.useState)(!1),S=p(m,x,g),C=(0,o.useEditor)({extensions:[s.default,a.default.configure({placeholder:c,emptyEditorClass:`aivex:before:content-[attr(data-placeholder)] aivex:before:text-text-tertiary aivex:before:absolute aivex:before:left-3`}),i.default.configure({HTMLAttributes:{class:`aivex:text-text-brand aivex:px-1`},renderHTML({options:e,node:t}){return[`span`,(0,o.mergeAttributes)(e.HTMLAttributes),`${t.attrs.label}`]},renderText({node:e}){return`@[${e.attrs.label}](${e.attrs.id})`},deleteTriggerWithBackspace:!0,suggestion:S})],content:h||u(e),immediatelyRender:!1,editorProps:{attributes:{class:`aivex:px-3 aivex:py-1 aivex:rounded-lg aivex:border aivex:border-border-subtle aivex:bg-bg-secondary aivex:focus:border-border-brand aivex:outline-none aivex:text-body-md-regular aivex:text-text-primary aivex:cursor-text aivex:[&_p]:leading-[22px]`},handleKeyDown:(t,n)=>n.key===`Enter`?b||n.shiftKey||n.metaKey||n.ctrlKey||n.altKey?!1:(n.preventDefault(),e.trim()&&l&&l(),!0):n.key===`Escape`?b||!f?!1:(n.preventDefault(),f(),!0):!1},onUpdate:({editor:e})=>{t(d(e.getJSON()))}});return(0,r.useEffect)(()=>{if(!C||!b&&!f)return;let e=C.view,t=e.dom.ownerDocument.defaultView,n=t=>{t.key!==`Escape`||t.defaultPrevented||!(t.target instanceof Node)||!e.dom.contains(t.target)||e.someProp(`handleKeyDown`,n=>n(e,t))&&(t.preventDefault(),t.stopPropagation())};return t?.addEventListener(`keydown`,n,!0),()=>t?.removeEventListener(`keydown`,n,!0)},[C,b,f]),(0,r.useEffect)(()=>{C&&!h&&e!==d(C.getJSON())&&C.commands.setContent(u(e))},[e,C,h]),(0,r.useEffect)(()=>{C&&_&&requestAnimationFrame(()=>{C.commands.focus()})},[C,_]),(0,r.useImperativeHandle)(v,()=>({focus:()=>{C?.commands.focus()}}),[C]),(0,n.jsx)(o.EditorContent,{ref:y,editor:C,className:`aivex:relative aivex:h-full aivex:w-full`,onKeyDown:e=>e.stopPropagation()})}function h({user:r,value:i,onChange:a,onSubmit:o,onClose:s,title:c=`Comment`,placeholder:l,submitLabel:u=`Send`,showSubmit:d=!0,pending:f=!1,userList:p,mentionEmptyText:h,initialContent:g,className:_}){let v=()=>{!i.trim()||f||o()};return(0,n.jsx)(`div`,{className:`aivex:rounded-2xl aivex:bg-bg-primary aivex:shadow-xl ${_??``}`,children:(0,n.jsxs)(`div`,{className:`aivex:flex aivex:w-[360px] aivex:flex-col`,children:[(0,n.jsxs)(`div`,{className:`aivex:flex aivex:h-12 aivex:items-center aivex:justify-between aivex:border-border-subtle aivex:border-b aivex:px-5 aivex:py-2`,children:[(0,n.jsx)(`span`,{className:`aivex:text-body-lg-medium aivex:text-text-primary`,children:c}),(0,n.jsx)(t.t,{size:`sm`,className:`aivex:text-text-secondary`,onClick:s,children:(0,n.jsx)(e.xt,{size:20})})]}),(0,n.jsxs)(`div`,{className:`aivex:flex aivex:flex-col aivex:px-4 aivex:py-3`,children:[(0,n.jsxs)(`div`,{className:`aivex:flex aivex:gap-1.5`,children:[(0,n.jsx)(`div`,{className:`aivex:h-6 aivex:w-6 aivex:py-1`,children:r?(0,n.jsx)(t.r,{size:`sm`,src:r.avatarUrl,bgColor:r.color,name:r.name}):null}),(0,n.jsx)(`div`,{className:`aivex:min-w-0 aivex:flex-1`,children:(0,n.jsx)(m,{value:i,onChange:a,placeholder:l,onSubmit:v,onEscape:s,userList:p,mentionEmptyText:h,initialContent:g})})]}),d?(0,n.jsx)(`div`,{className:`aivex:grid aivex:transition-[grid-template-rows,opacity] aivex:duration-200 aivex:ease-out ${i.trim()?`aivex:grid-rows-[1fr] aivex:opacity-100`:`aivex:pointer-events-none aivex:grid-rows-[0fr] aivex:opacity-0`}`,children:(0,n.jsx)(`div`,{className:`aivex:flex aivex:justify-end aivex:overflow-hidden aivex:pt-1.5`,children:(0,n.jsx)(e.t,{size:`md`,disabled:!i.trim()||f,onClick:v,tabIndex:i.trim()?void 0:-1,children:u})})}):null]})]})})}function g({users:e,selected:r=!1,resolved:i=!1,onClick:a,maxAvatars:o=3,className:s}){let c=e.slice(0,o);return(0,n.jsxs)(`button`,{type:`button`,onClick:a,className:`aivex:flex aivex:h-fit aivex:cursor-pointer aivex:items-center aivex:rounded-t-full aivex:rounded-br-full aivex:border aivex:p-1 aivex:transition-colors ${r?`aivex:border-border-brand aivex:bg-bg-brand`:`aivex:border-border-subtle aivex:bg-bg-primary aivex:hover:border-border-brand`} ${i?`aivex:opacity-40`:``} ${s??``}`,children:[c.map((e,r)=>(0,n.jsx)(`span`,{className:`aivex:flex`,style:r>0?{marginLeft:`-4px`}:void 0,children:(0,n.jsx)(t.r,{size:`xs`,src:e.avatarUrl,bgColor:e.color,name:e.name})},e.id)),e.length>o?(0,n.jsxs)(`span`,{className:`aivex:px-1 aivex:text-label-sm aivex:text-text-secondary`,children:[`+`,e.length-o]}):null]})}exports.CommentInput=h,exports.CommentPin=g,exports.MentionInput=m;
package/dist/comment.js CHANGED
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import "./styles.css";
3
- import { r as e, t } from "./IconButton-CK4en7H6.js";
4
- import { t as n, xt as r } from "./Button-BrPqDGyO.js";
3
+ import { r as e, t } from "./IconButton-7v0vHj6O.js";
4
+ import { t as n, xt as r } from "./Button-CH_7RCR4.js";
5
5
  import { jsx as i, jsxs as a } from "react/jsx-runtime";
6
6
  import { memo as o, useCallback as s, useEffect as c, useImperativeHandle as l, useMemo as u, useRef as d, useState as f } from "react";
7
7
  import p from "@tiptap/extension-mention";
@@ -1,11 +1,16 @@
1
1
  import { type Row, type TableOptions } from "@tanstack/react-table";
2
2
  import type { MouseEvent, ReactNode, Ref } from "react";
3
3
  import { type DataGridColumnSettingsOptions } from "./DataGridColumnSettings";
4
- import { type DataGridValue } from "./DataGridPrimitives";
4
+ import { type DataGridValue, type DataGridVariant } from "./DataGridPrimitives";
5
5
  export interface DataGridProps<TData> extends Omit<TableOptions<TData>, "getCoreRowModel"> {
6
6
  getCoreRowModel?: TableOptions<TData>["getCoreRowModel"];
7
7
  className?: string;
8
8
  ref?: Ref<HTMLDivElement>;
9
+ /**
10
+ * 밀도 (Figma Table Variants : Type). 기본 basic.
11
+ * compact는 헤더 32px·행 36px에 헤더 박스·행 구분선이 없다.
12
+ */
13
+ variant?: DataGridVariant;
9
14
  loading?: boolean;
10
15
  loadingRowCount?: number;
11
16
  empty?: ReactNode;
@@ -50,10 +55,10 @@ export interface DataGridProps<TData> extends Omit<TableOptions<TData>, "getCore
50
55
  * SSR에서는 초기 행이 비어 있고 마운트 후 렌더된다.
51
56
  */
52
57
  virtualized?: boolean;
53
- /** 가상화 시 행 높이 추정값(px). 실제 높이는 렌더 후 실측로 보정된다. 기본 48 */
58
+ /** 가상화 시 행 높이 추정값(px). 실제 높이는 렌더 후 실측로 보정된다. 기본 basic 48 / compact 36 */
54
59
  estimateRowHeight?: number;
55
60
  /** 가상화 시 화면 밖에 미리 렌더할 행 수. 기본 6 */
56
61
  overscan?: number;
57
62
  }
58
- declare function DataGrid<TData>({ className, loading, loadingRowCount, empty, headerSticky, viewportClassName, contentClassName, headerClassName, bodyClassName, rowClassName, rowInteractive, isRowSelected, isRowDisabled, onRowClick, renderExpandedRow, loadingMore, loadingMoreContent, loadingMoreRowCount, skeletonRowClassName, endContent, infiniteTriggerRef, infiniteTriggerClassName, columnSettings, virtualized, estimateRowHeight, overscan, ref, getCoreRowModel, ...tableOptions }: DataGridProps<TData>): import("react/jsx-runtime").JSX.Element;
63
+ declare function DataGrid<TData>({ className, variant, loading, loadingRowCount, empty, headerSticky, viewportClassName, contentClassName, headerClassName, bodyClassName, rowClassName, rowInteractive, isRowSelected, isRowDisabled, onRowClick, renderExpandedRow, loadingMore, loadingMoreContent, loadingMoreRowCount, skeletonRowClassName, endContent, infiniteTriggerRef, infiniteTriggerClassName, columnSettings, virtualized, estimateRowHeight, overscan, ref, getCoreRowModel, ...tableOptions }: DataGridProps<TData>): import("react/jsx-runtime").JSX.Element;
59
64
  export { DataGrid };
@@ -1,7 +1,13 @@
1
1
  import type { RowData } from "@tanstack/react-table";
2
- import type { HTMLAttributes, ReactNode, Ref } from "react";
2
+ import { type HTMLAttributes, type ReactNode, type Ref } from "react";
3
3
  import { type ScrollAreaProps } from "@/components/ScrollArea";
4
4
  export type DataGridAlign = "start" | "center" | "end";
5
+ /**
6
+ * 그리드 밀도 (Figma Table Variants : Type).
7
+ * - basic: 헤더 48px(배경·테두리 박스) + 행 48px + 행 구분선
8
+ * - compact: 헤더 32px(박스 없음) + 행 36px, 구분선·바깥 인셋 없음 — 대시보드 카드 등 좁은 영역용
9
+ */
10
+ export type DataGridVariant = "basic" | "compact";
5
11
  export type DataGridValue<TData, TValue> = TValue | ((row: TData, index: number) => TValue);
6
12
  declare module "@tanstack/react-table" {
7
13
  interface ColumnMeta<TData extends RowData, TValue> {
@@ -23,9 +29,11 @@ declare module "@tanstack/react-table" {
23
29
  }
24
30
  export declare function resolveDataGridValue<TData, TValue>(value: DataGridValue<TData, TValue> | undefined, row: TData, index: number): TValue | undefined;
25
31
  export interface DataGridRootProps extends HTMLAttributes<HTMLDivElement> {
32
+ /** 하위 헤더·행·셀에 전달되는 밀도. 기본 basic */
33
+ variant?: DataGridVariant;
26
34
  ref?: Ref<HTMLDivElement>;
27
35
  }
28
- declare function DataGridRoot({ className, children, ref, ...props }: DataGridRootProps): import("react/jsx-runtime").JSX.Element;
36
+ declare function DataGridRoot({ className, children, variant, ref, ...props }: DataGridRootProps): import("react/jsx-runtime").JSX.Element;
29
37
  export interface DataGridViewportProps extends ScrollAreaProps {
30
38
  /** 세로 스크롤바에 덧붙일 클래스 — 고정 헤더 아래에서 시작시킬 때 */
31
39
  verticalScrollbarClassName?: string;
@@ -4,5 +4,5 @@ export type { DataGridProps } from "./DataGrid";
4
4
  export { DataGrid } from "./DataGrid";
5
5
  export type { DataGridColumnSettingsOptions } from "./DataGridColumnSettings";
6
6
  export { DataGridColumnSettings } from "./DataGridColumnSettings";
7
- export type { DataGridAlign, DataGridBodyProps, DataGridCellProps, DataGridEmptyProps, DataGridHeaderCellProps, DataGridHeaderProps, DataGridInfiniteTriggerProps, DataGridLoadingProps, DataGridRootProps, DataGridRowProps, DataGridViewportProps, } from "./DataGridPrimitives";
7
+ export type { DataGridAlign, DataGridBodyProps, DataGridCellProps, DataGridEmptyProps, DataGridHeaderCellProps, DataGridHeaderProps, DataGridInfiniteTriggerProps, DataGridLoadingProps, DataGridRootProps, DataGridRowProps, DataGridVariant, DataGridViewportProps, } from "./DataGridPrimitives";
8
8
  export { DataGridBody, DataGridCell, DataGridEmpty, DataGridHeader, DataGridHeaderCell, DataGridInfiniteTrigger, DataGridLoading, DataGridRoot, DataGridRow, DataGridViewport, } from "./DataGridPrimitives";
@@ -101,6 +101,8 @@ export declare const FloppyDiskIcon: ({ size, color, className, ...props }: Icon
101
101
  export declare const GalleryViewLargeIcon: ({ size, color, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
102
102
  export declare const GalleryViewMediumIcon: ({ size, color, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
103
103
  export declare const GalleryViewSmallIcon: ({ size, color, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
104
+ export declare const GitBranchIcon: ({ size, color, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
105
+ export declare const GitCommitIcon: ({ size, color, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
104
106
  export declare const GlobalIcon: ({ size, color, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
105
107
  export declare const GpuIcon: ({ size, color, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
106
108
  export declare const GraphIcon: ({ size, color, className, ...props }: IconProps) => import("react/jsx-runtime").JSX.Element;
@@ -5,22 +5,27 @@ export interface TableProps extends HTMLAttributes<HTMLDivElement> {
5
5
  tableClassName?: string;
6
6
  ref?: Ref<HTMLDivElement>;
7
7
  }
8
+ /** @deprecated Table은 제거 예정입니다. `DataGrid`(또는 DataGrid 프리미티브)를 사용하세요. */
8
9
  declare function Table({ className, tableClassName, size, children, ref, ...props }: TableProps): import("react/jsx-runtime").JSX.Element;
9
10
  export interface TableHeaderProps extends HTMLAttributes<HTMLTableSectionElement> {
10
11
  ref?: Ref<HTMLTableSectionElement>;
11
12
  }
13
+ /** @deprecated Table은 제거 예정입니다. `DataGrid`(또는 DataGrid 프리미티브)를 사용하세요. */
12
14
  declare function TableHeader({ className, children, ref, ...props }: TableHeaderProps): import("react/jsx-runtime").JSX.Element;
13
15
  export interface TableFooterProps extends HTMLAttributes<HTMLTableSectionElement> {
14
16
  ref?: Ref<HTMLTableSectionElement>;
15
17
  }
18
+ /** @deprecated Table은 제거 예정입니다. `DataGrid`(또는 DataGrid 프리미티브)를 사용하세요. */
16
19
  declare function TableFooter({ className, children, ref, ...props }: TableFooterProps): import("react/jsx-runtime").JSX.Element;
17
20
  export interface TableCaptionProps extends HTMLAttributes<HTMLTableCaptionElement> {
18
21
  ref?: Ref<HTMLTableCaptionElement>;
19
22
  }
23
+ /** @deprecated Table은 제거 예정입니다. `DataGrid`(또는 DataGrid 프리미티브)를 사용하세요. */
20
24
  declare function TableCaption({ className, children, ref, ...props }: TableCaptionProps): import("react/jsx-runtime").JSX.Element;
21
25
  export interface TableBodyProps extends HTMLAttributes<HTMLTableSectionElement> {
22
26
  ref?: Ref<HTMLTableSectionElement>;
23
27
  }
28
+ /** @deprecated Table은 제거 예정입니다. `DataGrid`(또는 DataGrid 프리미티브)를 사용하세요. */
24
29
  declare function TableBody({ className, children, ref, ...props }: TableBodyProps): import("react/jsx-runtime").JSX.Element;
25
30
  export interface TableRowProps extends HTMLAttributes<HTMLTableRowElement> {
26
31
  size?: TableSize;
@@ -30,6 +35,7 @@ export interface TableRowProps extends HTMLAttributes<HTMLTableRowElement> {
30
35
  asChild?: boolean;
31
36
  ref?: Ref<HTMLTableRowElement>;
32
37
  }
38
+ /** @deprecated Table은 제거 예정입니다. `DataGrid`(또는 DataGrid 프리미티브)를 사용하세요. */
33
39
  declare function TableRow({ className, children, size, selected, disabled, interactive, asChild, ref, onClick, onDoubleClick, onKeyDown, tabIndex, "aria-disabled": ariaDisabled, ...props }: TableRowProps): import("react/jsx-runtime").JSX.Element;
34
40
  export interface TableHeadProps extends ThHTMLAttributes<HTMLTableCellElement> {
35
41
  size?: TableSize;
@@ -39,23 +45,27 @@ export interface TableHeadProps extends ThHTMLAttributes<HTMLTableCellElement> {
39
45
  asChild?: boolean;
40
46
  ref?: Ref<HTMLTableCellElement>;
41
47
  }
48
+ /** @deprecated Table은 제거 예정입니다. `DataGrid`(또는 DataGrid 프리미티브)를 사용하세요. */
42
49
  declare function TableHead({ className, children, size, sortable, sortDirection, onSort, asChild, ref, ...props }: TableHeadProps): import("react/jsx-runtime").JSX.Element;
43
50
  export interface TableCellProps extends TdHTMLAttributes<HTMLTableCellElement> {
44
51
  size?: TableSize;
45
52
  asChild?: boolean;
46
53
  ref?: Ref<HTMLTableCellElement>;
47
54
  }
55
+ /** @deprecated Table은 제거 예정입니다. `DataGrid`(또는 DataGrid 프리미티브)를 사용하세요. */
48
56
  declare function TableCell({ className, children, size, asChild, ref, ...props }: TableCellProps): import("react/jsx-runtime").JSX.Element;
49
57
  export interface TableEmptyProps extends TdHTMLAttributes<HTMLTableCellElement> {
50
58
  colSpan: number;
51
59
  children?: ReactNode;
52
60
  ref?: Ref<HTMLTableCellElement>;
53
61
  }
62
+ /** @deprecated Table은 제거 예정입니다. `DataGrid`(또는 DataGrid 프리미티브)를 사용하세요. */
54
63
  declare function TableEmpty({ className, children, colSpan, ref, ...props }: TableEmptyProps): import("react/jsx-runtime").JSX.Element;
55
64
  export interface TableLoadingProps extends TableHTMLAttributes<HTMLTableSectionElement> {
56
65
  colSpan: number;
57
66
  rowCount?: number;
58
67
  ref?: Ref<HTMLTableSectionElement>;
59
68
  }
69
+ /** @deprecated Table은 제거 예정입니다. `DataGrid`(또는 DataGrid 프리미티브)를 사용하세요. */
60
70
  declare function TableLoading({ className, colSpan, rowCount, ref, ...props }: TableLoadingProps): import("react/jsx-runtime").JSX.Element;
61
71
  export { Table, TableBody, TableCaption, TableCell, TableEmpty, TableFooter, TableHead, TableHeader, TableLoading, TableRow, };