Module label

Module label 

Source
Expand description

label simply let’s you display some text.

§Example

fn app() -> Element {
    rsx!(
        label {
            "Hello World"
        }
    )
}

Constants§

a11y_access_key
a11y_author_id
a11y_auto_complete
a11y_auto_focus
a11y_busy
a11y_color_value
a11y_column_count
a11y_column_index
a11y_column_index_text
a11y_column_span
a11y_current
a11y_default_action_verb
a11y_description
a11y_disabled
a11y_expanded
a11y_focusable
a11y_has_popup
a11y_hidden
a11y_hovered
a11y_id
a11y_invalid
a11y_is_grammar_error
a11y_is_search_match
a11y_is_spelling_error
a11y_is_suggestion
a11y_keyboard_shortcut
a11y_language
a11y_level
a11y_linked
a11y_list_style
a11y_live
a11y_live_atomic
a11y_max_numeric_value
a11y_min_numeric_value
a11y_modal
a11y_multiselectable
a11y_name
a11y_numeric_value
a11y_numeric_value_jump
a11y_numeric_value_step
a11y_orientation
a11y_placeholder
a11y_position_in_set
a11y_read_only
a11y_required
a11y_role
a11y_role_description
a11y_row_count
a11y_row_index
a11y_row_index_text
a11y_row_span
a11y_scroll_x
a11y_scroll_x_max
a11y_scroll_x_min
a11y_scroll_y
a11y_scroll_y_max
a11y_scroll_y_min
a11y_selected
a11y_size_of_set
a11y_sort_direction
a11y_state_description
a11y_toggled
a11y_tooltip
a11y_touch_transparent
a11y_url
a11y_value
a11y_vertical_offset
a11y_visited
color
The color attribute lets you specify the color of the text.
decoration
Specify the decoration in a text.
decoration_color
Specify the decoration’s color in a text.
decoration_style
Specify the decoration’s style in a text.
font_family
With the font_family you can specify what font you want to use for the inner text.
font_size
You can specify the size of the text using font_size.
font_style
You can choose a style for a text using the font_style attribute.
font_weight
You can choose a weight for text using the font_weight attribute.
font_width
You can choose a width for a text using the font_width attribute.
height
Specify the height for the given element.
layer
Controls the stacking order of elements on the z-axis.
letter_spacing
Specify the spacing between characters of the text.
line_height
line_height
main_align
main_align
margin
Specify the margin of an element. You can do so by four different ways, just like in CSS.
max_height
Specify a maximum height for the given element.
max_lines
Determines the amount of lines that the text can have. It has unlimited lines by default.
max_width
Specify a maximum width for the given element.
min_height
Specify a minimum height for the given element. This can be useful if you use it alongside a percentage for the target size.
min_width
Specify a minimum width for the given element. This can be useful if you use it alongside a percentage for the target size.
opacity
Specify the opacity for this element.
position
Specify how you want the element to be positioned inside it’s parent area.
position_bottom
Specify the bottom position of an element when using position: "absolute" or position: "global". This supports pixels only.
position_left
Specify the left position of an element when using position: "absolute" or position: "global". This supports pixels only.
position_right
Specify the right position of an element when using position: "absolute" or position: "global". This supports pixels only.
position_top
Specify the top position of an element when using position: "absolute" or position: "global". This supports pixels only.
reference
Attach a reference to an element to track its layout and metadata.
rotate
Specify the rotation for this element.
text_align
You can change the alignment of the text using the text_align attribute.
text_height
Specify the text height behavior.
text_overflow
Determines how text is treated when it exceeds its max_lines count. By default uses the clip mode, which will cut off any overflowing text, with ellipsis mode it will show ... at the end.
text_shadow
Specify the shadow of a text.
width
Specify the width for the given element.
word_spacing
Specify the spacing between words of the text.