function getParentES5Component(context, node) {
  let scope = getScope(context, node);
  while (scope) {
    // @ts-ignore
    node = scope.block && scope.block.parent && scope.block.parent.parent;
    if (node && isES5Component(node, context)) {
      return node;
    }
    scope = scope.upper;
  }
  return null;
}
Get the parent ES5 component node from the current scope
@param {Context} context
@param {ASTNode} node
@returns {ASTNode|null}