findNearest(node, hint) {
    // Use the hint if we are given one. When doing "live" inspecting, the mouse likely
    // hasn't moved far from its last location. Therefore, the matching render node is
    // likely to be the same render node, one of its children, or its parent. Knowing this,
    // we can heuristically start the search from the parent render node (which would also
    // match against this node and its children), then only fallback to matching the entire
    // tree when there is no match in this subtree.

    if (node.__emberInspectorParentElement) {
      node = node.__emberInspectorParentElement;
    }

    let hintNode = this._findUp(this.nodes[hint]);
    let hints = [hintNode];
    if (node.__emberInspectorParentNode) {
      const remoteNode = this.inElementSupport?.nodeMap.get(node);
      const n = remoteNode && this.nodes[remoteNode];
      hints.push(n);
    }

    hints = hints.filter((h) => !!h);
    let renderNode;

    const remoteRoots = this.inElementSupport?.remoteRoots || [];

    renderNode = this._matchRenderNodes(
      [...hints, ...remoteRoots, ...this.tree],
      node,
    );

    if (renderNode) {
      return this._serializeRenderNode(renderNode);
    } else {
      return null;
    }
  }
Find the deepest enclosing render node for a given DOM node.

@method findNearest
@param {Node} node A DOM node.
@param {string} hint The id of the last-matched render node (see comment below).
@return {Option<SerializedRenderNode>} The deepest enclosing render node, if any.