struct
Components::Variants::ComponentVariant
- Components::Variants::ComponentVariant
- Struct
- Value
- Object
Overview
Small value object that keeps component class construction predictable. It is intentionally string-backed so alpha examples can accept params from attrs without exposing raw class soup as the public API.
Defined in:
components/variants/component_variant.crConstructors
Instance Method Summary
- #classes : String
- #clone
- #copy_with(family _family = @family, tone _tone = @tone, emphasis _emphasis = @emphasis, size _size = @size, state _state = @state)
- #emphasis : String
- #family : String
- #size : String
- #state : String
- #tone : String
Constructor Detail
def self.new(family : String, tone : String = "brand", emphasis : String = "solid", size : String = "md", state : String = "default")
#
Instance Method Detail
def copy_with(family _family = @family, tone _tone = @tone, emphasis _emphasis = @emphasis, size _size = @size, state _state = @state)
#