glendix/js/dom
Provides typed DOM operations delegated to Plinth.
Glendix’s established element and rectangle handles stay public through identity adapters. Native click and default scrolling remain minimal FFI gaps because Plinth 0.11.0 does not provide equivalent operations.
Types
Represents a DOM element handle.
pub type DomElement
Values
pub fn click(element element: DomElement) -> Nil
Dispatches the element’s native click behavior.
pub fn get_bounding_client_rect(
element element: DomElement,
) -> DomRect
Reads the element’s bounding client rectangle.
pub fn query_selector(
in element: DomElement,
matching selector: String,
) -> option.Option(DomElement)
Finds the first descendant matching a CSS selector.
pub fn scroll_into_view(element element: DomElement) -> Nil
Scrolls an element into the viewport.