Replies: 1 comment
-
No there isn't anything like this @charmbyte IMO heading should be a variant in textStyles |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Is it possible to merge two
cva
objects to keep things DRY?For example, say I have two typography components - Heading and Text - and I want to define Heading variants using
cva
that inherits all of the variants from the Text component.Coming from using StitchesJS, the way to have done this would be to supply the
headingStyles
call with the first argument beingtextStyles
and the second argument would be the variants and styles specific to the heading component. So, for example, I have a functiontextStyles = cva(...)
and I want a second function that looks something likeheadingStyles = cva(textStyles, ...)
.Is there an equivalent to this in Panda?
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions