feat: add Separator Kbd and Chip components

This commit is contained in:
maoyingjie
2026-10-21 18:35:24 +08:00
parent 3d05fea7bd
commit 3515a47f5e
51 changed files with 2813 additions and 21 deletions
+98
View File
@@ -295,3 +295,101 @@ export const skeletonVariants = tv({
});
export type SkeletonVariants = VariantProps<typeof skeletonVariants>;
export const separatorVariants = tv({
base: "hv-separator",
defaultVariants: {
orientation: "horizontal",
variant: "default",
},
variants: {
orientation: {
horizontal: "hv-separator--horizontal",
vertical: "hv-separator--vertical",
},
variant: {
default: "hv-separator--default",
secondary: "hv-separator--secondary",
tertiary: "hv-separator--tertiary",
},
},
});
export type SeparatorVariants = VariantProps<typeof separatorVariants>;
export const kbdVariants = tv({
defaultVariants: {
variant: "default",
},
slots: {
abbr: "hv-kbd__abbr",
base: "hv-kbd",
content: "hv-kbd__content",
},
variants: {
variant: {
default: "hv-kbd--default",
light: "hv-kbd--light",
},
},
});
export type KbdVariants = VariantProps<typeof kbdVariants>;
export const chipVariants = tv({
defaultVariants: {
color: "default",
size: "md",
variant: "secondary",
},
slots: {
base: "hv-chip",
label: "hv-chip__label",
},
variants: {
color: {
accent: {
base: "hv-chip--accent",
},
danger: {
base: "hv-chip--danger",
},
default: {
base: "hv-chip--default",
},
success: {
base: "hv-chip--success",
},
warning: {
base: "hv-chip--warning",
},
},
size: {
lg: {
base: "hv-chip--lg",
},
md: {
base: "hv-chip--md",
},
sm: {
base: "hv-chip--sm",
},
},
variant: {
primary: {
base: "hv-chip--primary",
},
secondary: {
base: "hv-chip--secondary",
},
soft: {
base: "hv-chip--soft",
},
tertiary: {
base: "hv-chip--tertiary",
},
},
},
});
export type ChipVariants = VariantProps<typeof chipVariants>;