HomeWeb Components API Reference - v0.10.1
    Preparing search index...

    Class ModelElement

    The ModelElement interface provides properties and methods for manipulating <pc-model> elements. The ModelElement interface also inherits the properties and methods of the HTMLElement interface.

    Hierarchy (View Summary)

    Index
    • get asset(): string

      Gets the id of the pc-asset to use for the model.

      Returns string

      The asset ID.

    • set asset(value: string): void

      Sets the id of the pc-asset to use for the model.

      Parameters

      • value: string

        The asset ID.

      Returns void

    • get closestApp(): AppElement | null

      The nearest ancestor <pc-app> element, or null if this element has no <pc-app> ancestor. The search starts at the parent, so an element never resolves to itself.

      Returns AppElement | null

      The closest app element, or null.

    • get closestEntity(): EntityElement | null

      The nearest ancestor <pc-entity> element, or null if this element has no <pc-entity> ancestor. The search starts at the parent, so an element never resolves to itself.

      Returns EntityElement | null

      The closest entity element, or null.

    • Called when the element is fully initialized and ready. Subclasses should call this when they're ready. Resolves the ready promise and dispatches a bubbling, composed ready event.

      Returns void