private static @Nullable PsiElement targetElement(@NotNull PsiElement targetElement) {
    Navigatable descriptor = EditSourceUtil.getDescriptor(targetElement);
    return descriptor != null && descriptor.canNavigate() && targetElement.isPhysical()
           ? targetElement
           : null;
  }
private static @Nullable PsiElement targetElement(@NotNull PsiElement targetElement)