CodeMeltedDEV
    Preparing search index...

    Class CAppToolbar

    <cm-app-toolbar> Web Component

    A unified, dual-mode application toolbar supporting:

    position="top" -> Fixed header pinned to top: 0 with <header role="banner"> and bottom border position="bottom" -> Fixed footer pinned to bottom: 0 with <footer role="contentinfo"> and top border

    Coordinates (top/bottom/left/right) are strictly managed by the component.

    Exposed CSS Variables:

    • --toolbar-height (default: 60px)
    • --toolbar-bg (default: rgba(15, 23, 42, 0.9))
    • --toolbar-color (default: #f8fafc)
    • --toolbar-border (default: 1px solid rgba(51, 65, 85, 0.7))
    • --toolbar-z-index (default: 1000)
    • --toolbar-padding (default: 0 1.25rem)
    • --toolbar-gap (default: 0.75rem)

    HTML Example:

    <cm-app-toolbar position="top">
    <!-- Toolbar Items Go Here -->
    </cm-app-toolbar>

    Hierarchy (View Summary)

    Index
    • get position(): string

      Retrieves the current toolbar position as "top" or "bottom".

      Returns string

    • set position(val: "top" | "bottom"): void

      Sets the toolbar position.

      Parameters

      • val: "top" | "bottom"

        The position to set.

      Returns void

    • get observedAttributes(): string[]

      Returns string[]

    • Called when attributes are changed, added, removed, or replaced.

      Parameters

      • name: string

        The name of a observedAttributes allowing access into the internals of the custom component.

      • old_value: string

        The original value held by the attribute.

      • new_value: string

        The new value to apply.

      Returns void

    • Called each time the element is added to the document. The specification recommends that, as far as possible, developers should implement custom element setup in this callback rather than the constructor.

      Returns void

    • When defined, this is called instead of connectedCallback() and disconnectedCallback() each time the element is moved to a different place in the DOM via Element.moveBefore(). Use this to avoid running initialization/cleanup code in the connectedCallback() and disconnectedCallback() callbacks when the element is not actually being added to or removed from the DOM. See Lifecycle callbacks and state-preserving moves for more details.

      Returns void

    • The get_attribute() method of the Element interface returns the string value of the specified attribute of the specified element. It returns null if the element doesn't have an attribute with the given name.

      Parameters

      • name: string

        A string specifying the name of the attribute. When called on an HTML element in a DOM flagged as an HTML document, the name is normalized to lowercase.

      Returns string | null

      A string containing the attribute's value, or null if the element doesn't have an attribute with the given name.

    • Renders the toolbar at its designated position.

      Returns void

    • The set_attribute() method of the Element interface sets the value of an attribute on the specified element. If the attribute already exists, the value is updated; otherwise a new attribute is added with the specified name and value.

      Parameters

      • name: string

        A string containing the qualified name of the attribute whose value is to be set. The attribute name is automatically converted to all lower-case when set_attribute() is called on an HTML element in an HTML document.

      • value: string

        A trusted type or string containing the value to assign to the attribute.

      Returns void

    • Utility function to register a custom component if it has not already been defined.

      Parameters

      • name: string

        The name of the component.

      • element_def: any

        The constructor definition.

      Returns void