Overview of checkbox card component
  
             Mishka Chelekom checkbox card
            component is an interactive form component in
            
Choose Options
Choose Platform
Familiarity with Phoenix LiveView
Base variant
<.checkbox_card name="id="uniqu_naem"" id="uniqu_id"> <:checkbox value="" title="8-core CPU" description="32 GB RAM"></:checkbox> <:checkbox value="" title="6-core CPU" description="24 GB RAM"></:checkbox> <:checkbox value="" title="4-core CPU" description="16 GB RAM"></:checkbox> </.checkbox_card>
Default variant
<.checkbox_card name="" variant="default" color="natural"></.checkbox_card> <.checkbox_card name="" variant="default" color="primary"></.checkbox_card> <.checkbox_card name="" variant="default" color="secondary"></.checkbox_card> <.checkbox_card name="" variant="default" color="success"></.checkbox_card> <.checkbox_card name="" variant="default" color="danger"></.checkbox_card> <.checkbox_card name="" variant="default" color="warning"></.checkbox_card> <.checkbox_card name="" variant="default" color="misc"></.checkbox_card> <.checkbox_card name="" variant="default" color="dawn"></.checkbox_card> <.checkbox_card name="" variant="default" color="silver"></.checkbox_card> <.checkbox_card name="" variant="default" color="info"></.checkbox_card> <.checkbox_card name="" variant="default" color="dark"></.checkbox_card> <.checkbox_card name="" variant="default" color="white"></.checkbox_card>
Outline variant
<.checkbox_card name="" variant="outline" color="natural"></.checkbox_card> <.checkbox_card name="" variant="outline" color="primary"></.checkbox_card> <.checkbox_card name="" variant="outline" color="secondary"></.checkbox_card> <.checkbox_card name="" variant="outline" color="success"></.checkbox_card> <.checkbox_card name="" variant="outline" color="danger"></.checkbox_card> <.checkbox_card name="" variant="outline" color="warning"></.checkbox_card> <.checkbox_card name="" variant="outline" color="misc"></.checkbox_card> <.checkbox_card name="" variant="outline" color="dawn"></.checkbox_card> <.checkbox_card name="" variant="outline" color="silver"></.checkbox_card> <.checkbox_card name="" variant="outline" color="info"></.checkbox_card>
Shadow variant
<.checkbox_card name="" variant="shadow" color="natural"></.checkbox_card> <.checkbox_card name="" variant="shadow" color="primary"></.checkbox_card> <.checkbox_card name="" variant="shadow" color="secondary"></.checkbox_card> <.checkbox_card name="" variant="shadow" color="success"></.checkbox_card> <.checkbox_card name="" variant="shadow" color="danger"></.checkbox_card> <.checkbox_card name="" variant="shadow" color="warning"></.checkbox_card> <.checkbox_card name="" variant="shadow" color="misc"></.checkbox_card> <.checkbox_card name="" variant="shadow" color="dawn"></.checkbox_card> <.checkbox_card name="" variant="shadow" color="silver"></.checkbox_card> <.checkbox_card name="" variant="shadow" color="info"></.checkbox_card>
Bordered variant
<.checkbox_card name="" variant="bordered" color="natural"></.checkbox_card> <.checkbox_card name="" variant="bordered" color="primary"></.checkbox_card> <.checkbox_card name="" variant="bordered" color="secondary"></.checkbox_card> <.checkbox_card name="" variant="bordered" color="success"></.checkbox_card> <.checkbox_card name="" variant="bordered" color="danger"></.checkbox_card> <.checkbox_card name="" variant="bordered" color="warning"></.checkbox_card> <.checkbox_card name="" variant="bordered" color="misc"></.checkbox_card> <.checkbox_card name="" variant="bordered" color="dawn"></.checkbox_card> <.checkbox_card name="" variant="bordered" color="silver"></.checkbox_card> <.checkbox_card name="" variant="bordered" color="info"></.checkbox_card> <.checkbox_card name="" variant="bordered" color="white"></.checkbox_card> <.checkbox_card name="" variant="bordered" color="dark"></.checkbox_card>
Label prop
You can use the label prop to add custom title text above the checkbox card group.
<.checkbox_card label="This is label of this group"></.checkbox_card>
Description prop
The description prop allows you to add explanatory text below the label for additional context about the checkbox card group.
<.checkbox_card description="This is a description"></.checkbox_card>
Rounded prop
  
            The rounded prop offers values like 
  "extra_small"
, 
  "small"
, 
  "medium"
, 
  "large"
, and 
  "extra_large"
.
          
<.checkbox_card name="" rounded="extra_small" ></.checkbox_card> <.checkbox_card name="" rounded="small" ></.checkbox_card> <.checkbox_card name="" rounded="medium" ></.checkbox_card> <.checkbox_card name="" rounded="large" ></.checkbox_card> <.checkbox_card name="" rounded="extra_large" ></.checkbox_card>
Border prop
  
            The border prop offers values like 
  "extra_small"
, 
  "small"
, 
  "medium"
, 
  "large"
, and 
  "extra_large"
.
          
<.checkbox_card name="" border="extra_small" ></.checkbox_card> <.checkbox_card name="" border="small" ></.checkbox_card> <.checkbox_card name="" border="medium" ></.checkbox_card> <.checkbox_card name="" border="large" ></.checkbox_card> <.checkbox_card name="" border="extra_large" ></.checkbox_card>
Space prop
  
            The space prop offers values such as 
  "extra_small"
, 
  "small"
, 
  "medium"
, 
  "large"
, and 
  "extra_large"
. These values control the vertical spacing between elements within the checkbox cards.
          
<.checkbox_card name="" space="extra_small" ></.checkbox_card> <.checkbox_card name="" space="small" ></.checkbox_card> <.checkbox_card name="" space="medium" ></.checkbox_card> <.checkbox_card name="" space="large" ></.checkbox_card> <.checkbox_card name="" space="extra_large" ></.checkbox_card>
Padding prop
  
            The padding prop offers values such as 
  "extra_small"
, 
  "small"
, 
  "medium"
, 
  "large"
, and 
  "extra_large"
. These values control the padding around the content inside the checkbox cards.
          
<.checkbox_card name="" padding="extra_small" ></.checkbox_card> <.checkbox_card name="" padding="small" ></.checkbox_card> <.checkbox_card name="" padding="medium" ></.checkbox_card> <.checkbox_card name="" padding="large" ></.checkbox_card> <.checkbox_card name="" padding="extra_large" ></.checkbox_card>
Size prop
  
            The size prop offers values such as 
  "extra_small"
, 
  "small"
, 
  "medium"
, 
  "large"
, and 
  "extra_large"
. These values control the padding around the content inside the checkbox cards.
          
<.checkbox_card name="" size="extra_small" ></.checkbox_card> <.checkbox_card name="" size="small" ></.checkbox_card> <.checkbox_card name="" size="medium" ></.checkbox_card> <.checkbox_card name="" size="large" ></.checkbox_card> <.checkbox_card name="" size="extra_large" ></.checkbox_card>
Cols prop
  
            The cols prop in the
            
              Phoenix checkbox card component
            
            allows you to define the number of columns used to display media items. The values range from one to twelve, giving you flexibility to control how many columns appear in the grid. For example, setting it to
            
  one
            will display all items in a single column, while
            
  two
            will divide the items into two columns. As the number increases, more columns are introduced, such as 
  three
, 
  four
, or even up to 
  twelve
. When necessary, the columns can also adapt for different screen breakpoints, with values like
            
  md
            allowing for a responsive design that adjusts according to screen width.
          
<.checkbox_card cols="one"></.checkbox_card> <.checkbox_card cols="two"></.checkbox_card> <.checkbox_card cols="three"></.checkbox_card> <.checkbox_card cols="four"></.checkbox_card> <.checkbox_card cols="five"></.checkbox_card> <.checkbox_card cols="six"></.checkbox_card> <.checkbox_card cols="seven"></.checkbox_card> <.checkbox_card cols="eight"></.checkbox_card> <.checkbox_card cols="nine"></.checkbox_card> <.checkbox_card cols="ten"></.checkbox_card> <.checkbox_card cols="eleven"></.checkbox_card> <.checkbox_card cols="twelve"></.checkbox_card>
Cols gap prop
  
            The cols gap prop in the checkbox card component controls the spacing between media items within the grid layout. It offers various values  like 
  extra_small
, 
  small
, 
  medium
, 
  large
, and 
  extra_large
.
          
<.checkbox_card cols_gap="extra_small"></.checkbox_card> <.checkbox_card cols_gap="small"></.checkbox_card> <.checkbox_card cols_gap="medium"></.checkbox_card> <.checkbox_card cols_gap="large"></.checkbox_card> <.checkbox_card cols_gap="extra_large"></.checkbox_card>
Show checkbox prop
  
            The show checkbox prop is a boolean value that controls the visibility of checkbox buttons within checkbox cards. When set to 
  true
, checkbox buttons are displayed; when 
  false
, they remain hidden.
          
<.checkbox_card show_checkbox></.checkbox_card>
Reverse prop
  
            The
            
  reverse
            prop in checkbox cards allows you to change the direction and order of content within the card, letting you swap the position of elements like title, description, and checkbox buttons.
          
<.checkbox_card show_checkbox reverse></.checkbox_card>
checkbox slot
  
            The checkbox slot in the checkbox card component allows you to define individual checkbox options with their associated content. Each checkbox slot requires a value and can include optional attributes like an icon, title, and description. The slot supports customization through 
  icon_class
, 
  icon
, 
  value
, 
  checked
, 
  title
,
            
  description
            and
            
  content_class
            properties for fine-tuned styling of each checkbox option.
          
<!--All the props of checkbox slot--> <.checkbox_card name="" id="" class="text-center"> <:checkbox value="" checked></:checkbox> <!--Use hero icons--> <:checkbox icon=""></:checkbox> <:checkbox icon_class=""></:checkbox> <:checkbox title="This is a title"></:checkbox> <:checkbox content_class="text-lg"></:checkbox> <:checkbox description="This is a description"></:checkbox> <:checkbox> <div class="flex flex-col justify-center items-center gap-2 text-md"> <.icon name="hero-home" class="size-5" /> <div>Custom content</div> </div> </:checkbox> </.checkbox_card>