Navbar
v0.0.10
mix mishka.ui.gen.component navbar
Default Variant
The default style of the Mishka Chelekom navbar applies a solid background and border that change based on user interaction, making it perfect for delivering important notifications. With just a single setting, you can select from a range of color options, ensuring easy customization to match various design styles. Default variant have also white and dark colors which are the same colors in the dark and light mode.
Default Variant
<.navbar id="navbar-2" variant="default" color="natural"></.navbar>
<.navbar id="navbar-3" variant="default" color="white"></.navbar>
<.navbar id="navbar-4" variant="default" color="primary"></.navbar>
<.navbar id="navbar-5" variant="default" color="secondary"></.navbar>
<.navbar id="navbar-6" variant="default" color="dark"></.navbar>
<.navbar id="navbar-7" variant="default" color="success"></.navbar>
<.navbar id="navbar-8" variant="default" color="warning"></.navbar>
<.navbar id="navbar-9" variant="default" color="danger"></.navbar>
<.navbar id="navbar-10" variant="default" color="info"></.navbar>
<.navbar id="navbar-11" variant="default" color="silver"></.navbar>
<.navbar id="navbar-12" variant="default" color="misc"></.navbar>
<.navbar id="navbar-13" variant="default" color="dawn"></.navbar>Shadow Variant
The shadow variant of the Mishka Chelekom navbar is similar to the default variant, but it also includes a subtle shadow along with a border and white background in light mode.
Shadow Variant
<.navbar id="navbar-14" color="natural" variant="shadow"></.navbar>
<.navbar id="navbar-15" color="primary" variant="shadow"></.navbar>
<.navbar id="navbar-16" color="secondary" variant="shadow"></.navbar>
<.navbar id="navbar-17" color="success" variant="shadow"></.navbar>
<.navbar id="navbar-18" color="warning" variant="shadow"></.navbar>
<.navbar id="navbar-19" color="danger" variant="shadow"></.navbar>
<.navbar id="navbar-20" color="info" variant="shadow"></.navbar>
<.navbar id="navbar-21" color="silver" variant="shadow"></.navbar>
<.navbar id="navbar-22" color="misc" variant="shadow"></.navbar>
<.navbar id="navbar-23" color="dawn" variant="shadow"></.navbar>bordered Variant
The Bordered variant of the Mishka Chelekom navbar has lighter background and a border. Bordered variant have also white and dark colors which are the same colors in the dark and light mode.
bordered Variant
<.navbar id="navbar-24" color="natural" variant="bordered"></.navbar>
<.navbar id="navbar-25" color="white" variant="bordered"></.navbar>
<.navbar id="navbar-26" color="primary" variant="bordered"></.navbar>
<.navbar id="navbar-27" color="secondary" variant="bordered"></.navbar>
<.navbar id="navbar-28" color="dark" variant="bordered"></.navbar>
<.navbar id="navbar-29" color="success" variant="bordered"></.navbar>
<.navbar id="navbar-30" color="warning" variant="bordered"></.navbar>
<.navbar id="navbar-31" color="danger" variant="bordered"></.navbar>
<.navbar id="navbar-32" color="info" variant="bordered"></.navbar>
<.navbar id="navbar-33" color="silver" variant="bordered"></.navbar>
<.navbar id="navbar-34" color="misc" variant="bordered"></.navbar>
<.navbar id="navbar-35" color="dawn" variant="bordered"></.navbar>gradient Variant
The gradient variant of the Mishka Chelekom navbar has gradients in various colors.
gradient Variant
<.navbar id="navbar-36" color="natural" variant="bordered"></.navbar>
<.navbar id="navbar-37" color="white" variant="bordered"></.navbar>
<.navbar id="navbar-38" color="primary" variant="bordered"></.navbar>
<.navbar id="navbar-39" color="secondary" variant="bordered"></.navbar>
<.navbar id="navbar-40" color="dark" variant="bordered"></.navbar>
<.navbar id="navbar-41" color="success" variant="bordered"></.navbar>
<.navbar id="navbar-42" color="warning" variant="bordered"></.navbar>
<.navbar id="navbar-43" color="danger" variant="bordered"></.navbar>
<.navbar id="navbar-44" color="info" variant="bordered"></.navbar>
<.navbar id="navbar-45" color="silver" variant="bordered"></.navbar>
<.navbar id="navbar-46" color="misc" variant="bordered"></.navbar>
<.navbar id="navbar-47" color="dawn" variant="bordered"></.navbar>Border prop
The border prop offers values like extra_small, small, medium, large, and extra_large. These values control the border size of the navbars, allowing you to adjust the thickness to suit your design.
Border prop
<.navbar id="navbar-53" border="extra_small"></.navbar>
<.navbar id="navbar-54" border="small"></.navbar>
<.navbar id="navbar-55" border="medium"></.navbar>
<.navbar id="navbar-56" border="large"></.navbar>
<.navbar id="navbar-57" border="extra_large"></.navbar>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 navbars.
Padding prop
<.navbar id="navbar-58" padding="extra_small"></.navbar>
<.navbar id="navbar-59" padding="small"></.navbar>
<.navbar id="navbar-60" padding="medium"></.navbar>
<.navbar id="navbar-61" padding="large"></.navbar>
<.navbar id="navbar-62" padding="extra_large"></.navbar>Max width prop
The max_width attribute controls the maximum width of the navbar component, ensuring that the content stays within a defined boundary, which is especially useful for creating consistent layouts. By setting the max_width value, you can easily limit how wide the navbar can extend, maintaining a structured appearance across different screen sizes. This attribute allows the navbar to remain centered and visually balanced, enhancing the overall presentation of the component in any layout.
Max width prop
<.navbar id="navbar-63" max_width="extra_small"></.navbar>
<.navbar id="navbar-64" max_width="small"></.navbar>
<.navbar id="navbar-65" max_width="medium"></.navbar>
<.navbar id="navbar-66" max_width="large"></.navbar>
<.navbar id="navbar-67" max_width="extra_large"></.navbar>Text position prop
The text_position attribute controls the alignment of text within a component, ensuring that content is properly positioned based on the design needs. With options like left, right, and center, you can align text to the left, right, or center of the component, respectively. This flexibility allows developers to manage how textual content is presented, enhancing readability and improving the visual structure of the component. If no specific value is provided, a default alignment is applied, typically aligning the text to the left.
Text position prop
<.navbar id="navbar-68" text_position="left"></.navbar>
<.navbar id="navbar-69" text_position="center"></.navbar>
<.navbar id="navbar-70" text_position="right"></.navbar>Content position prop
The content_position prop controls the horizontal alignment of content within the navbar by applying different justify-content classes to the wrapper. It accepts values like start, end, center, between, and around to distribute the content accordingly. The default value is between, which creates equal spacing between elements.
Content position prop
<.navbar id="navbar-82" content_position="center">
Mishka Chelekom Library
</.navbar>Attributes
| Name | Type | Default | Values | Required | Description |
|---|---|---|---|---|---|
id
|
string
| — | — | Yes | A unique identifier is used to manage state and interaction |
variant
|
string
|
base
|
defaultshadowborderedgradientbase
| No | Determines the style |
color
|
string
|
natural
|
basenaturalwhiteprimarysecondarydarksuccesswarningdangerinfosilvermiscdawn
| No | Determines color theme |
border
|
string
|
extra_small
| — | No | Determines border style |
text_position
|
string
| — | — | No | Determines the element's text position |
rounded
|
string
| — |
extra_smallsmallmediumlargeextra_largenone
| No | Determines the border radius |
max_width
|
string
| — | — | No | Determines the style of element max width |
content_position
|
string
|
between
| — | No | Determines the alignment of the element's content |
image
|
string
| — | — | No | Image displayed alongside of an item |
image_class
|
string
| — | — | No | Determines custom class for the image |
name
|
string
| — | — | No | Specifies the name of the element |
relative
|
boolean
|
false
| — | No | — |
link
|
string
| — | — | No | — |
space
|
string
| — |
extra_smallsmallmediumlargeextra_large
| No | Space between items |
font_weight
|
string
|
font-normal
| — | No | Determines custom class for the font weight |
padding
|
string
|
small
|
extra_smallsmallmediumlargeextra_largenone
| No | Determines padding for items |
class
|
any
| — | — | No | Custom CSS class for additional styling |
nav_wrapper_class
|
string
| — | — | No | Custom CSS class for nav wrapper |
link_class
|
string
| — | — | No | Custom CSS class for link |
list_wrapper_class
|
string
| — | — | No | Custom CSS class for list main wrapper |
list_class
|
string
| — | — | No | Custom CSS class for list ul |
rest
|
global
| — | — | No | Global attributes can define defaults which are merged with attributes provided by the caller |
Slots
| Name | Required | Description |
|---|---|---|
start_content
| No | — |
inner_block
| No | Inner block that renders HEEx content |
end_content
| No | — |
list
| No | — |
Attributes of the start_content slot
| Name | Type | Default | Values | Required | Description |
|---|---|---|---|---|---|
class
|
any
| — | — | No | Custom CSS class for additional styling |
Attributes of the end_content slot
| Name | Type | Default | Values | Required | Description |
|---|---|---|---|---|---|
class
|
any
| — | — | No | Custom CSS class for additional styling |
Attributes of the list slot
| Name | Type | Default | Values | Required | Description |
|---|---|---|---|---|---|
class
|
any
| — | — | No | Custom CSS class for additional styling |
padding
|
string
| — | — | No | Determines padding for items |
icon
|
string
| — | — | No | Icon displayed alongside of an item |
icon_class
|
string
| — | — | No | Determines custom class for the icon |
icon_position
|
string
| — | — | No | Determines icon position |
Options
Each option takes one or more of its values, separated by commas.
| Option | Values |
|---|---|
--variant
|
defaultshadowborderedgradientbase
|
--color
|
basenaturalwhiteprimarysecondarydarksuccesswarningdangerinfosilvermiscdawn
|
--padding
|
extra_smallsmallmediumlargeextra_largenone
|
--rounded
|
extra_smallsmallmediumlargeextra_largenone
|
--space
|
extra_smallsmallmediumlargeextra_large
|
--module
| A module name of your own |
What it generates
mix mishka.ui.gen.component navbar