I'd like it if the set of classes common across the variants of a component were pulled into something like a common_classes method. Take PhlexUI::Link, where each of the variants list of classes includes whitespace-nowrap, inline-flex, items-center, justify-center, rounded-md, font-medium, transition-colors, focus-visible:outline-none, focus-visible:ring-1, focus-visible:ring-ring, disabled:pointer-events-none, disabled:opacity-50. If these were broke up I could better see what the actual differences are.
I wonder how this could actually be maintained other than just like... as a policy as you write components. Some kinda custom cop? That seems like. lot. Maybe this isn't an issue but a like, discussion topic?
I'd like it if the set of classes common across the variants of a component were pulled into something like a
common_classes
method. TakePhlexUI::Link
, where each of the variants list of classes includeswhitespace-nowrap, inline-flex, items-center, justify-center, rounded-md, font-medium, transition-colors, focus-visible:outline-none, focus-visible:ring-1, focus-visible:ring-ring, disabled:pointer-events-none, disabled:opacity-50
. If these were broke up I could better see what the actual differences are.