Skip to content

Commit

Permalink
support more than two variants
Browse files Browse the repository at this point in the history
  • Loading branch information
benvp committed Dec 6, 2022
1 parent 472ab44 commit fd57acc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/cva/component.ex
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ defmodule CVA.Component do
defmacro variant(name, variants, opts \\ [])
when is_atom(name) and is_list(variants) and is_list(opts) do
quote do
if Module.get_attribute(__MODULE__, :__cva_variant_called__) do
unless Module.get_attribute(__MODULE__, :__cva_variant_called__) do
attr(:cva_class, :string, default: nil)
end

Expand Down

0 comments on commit fd57acc

Please sign in to comment.