static @Nullable PsiElement getParentWithName(PsiElement element, String[] tagNames) {
    while (element != null) {
      if (element instanceof XmlTag) {
        if (tagNames != null) {
          final String name = StringUtil.toLowerCase(((XmlTag)element).getName());
          if (ArrayUtil.contains(name, tagNames)) {
              return element;
          }
        }
        else {
          return element;
        }
      }
      element = element.getParent();
    }
    return null;
  }
static @Nullable PsiElement getParentWithName(PsiElement element, String[] tagNames)