boolean (Object element, PsiElement context) { final PsiElement grandParent = ((PsiElement)element).getParent().getParent(); if (grandParent instanceof XmlTag tag) { if (!tag.getNamespacePrefix().isEmpty()) { return true; } } return false; }