Function findParentElement

  • Provides a data defined mechanism to walk up the DOM parent element chain and return the first ancestor that satisfies multiple filtering rules (stacking context, class, ID, selector, predicate) while optionally limiting traversal depth.

    Parameters

    Returns Element

    The first acceptable parent element or null.