Skip to content

Text

Primitive typographic component
import { Text } from '@kalidao/reality'
name
type
default
align
ConditionalStyle<Values<("center" | "left" | "right")[], { defaultClass: string; conditions: { xs: string; sm: string; md: string; lg: string; xl: string; }; }>>
-
as
"label" | "div" | "code" | "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "p" | "span"
div
color
ConditionalStyle<Values<MapLeafNodes<{ background: string; backgroundSecondary: string; backgroundTertiary: string; foreground: string; foregroundSecondary: string; foregroundSecondaryHover: string; foregroundTertiary: string; ... 20 more ...; transparent: string; }, CSSVarFunction> & MapLeafNodes<...>, { ...; }>>
text
ellipsis
boolean
-
font
"mono" | "sans"
sans
letterSpacing
ConditionalStyle<Values<MapLeafNodes<{ '-0.02': string; '-0.015': string; '-0.01': string; normal: string; '0.03': string; }, CSSVarFunction>, { defaultClass: string; conditions: { xs: string; sm: string; md: string; lg: string; xl: string; }; }>>
-
lineHeight
ConditionalStyle<Values<MapLeafNodes<{ normal: string; none: string; '1.25': string; '1.375': string; '1.5': string; '1.625': string; '2': string; }, CSSVarFunction>, { defaultClass: string; conditions: { ...; }; }>>
-
ref
Ref<HTMLElement>
-
size
ConditionalStyle<Values<{ inherit: "inherit"; headingOne: CSSVarFunction; headingTwo: CSSVarFunction; headingThree: CSSVarFunction; extraLarge: CSSVarFunction; ... 5 more ...; root: CSSVarFunction; }, { ...; }>>
-
transform
"capitalize" | "lowercase" | "uppercase"
-
variant
"extraLarge" | "large" | "small" | "label" | "base"
-
weight
ConditionalStyle<Values<MapLeafNodes<{ light: string; normal: string; medium: string; semiBold: string; bold: string; }, CSSVarFunction>, { defaultClass: string; conditions: { ...; }; }>>
-
whiteSpace
"inherit" | "initial" | "normal" | "nowrap" | "pre" | "pre-line" | "pre-wrap"
-
wordBreak
"break-word"
-