@Contract(pure = true)
  public static @Nullable <T extends PsiElement> T findElementOfClassAtOffset(@NotNull PsiFile file,
                                                                              int offset,
                                                                              @NotNull Class<T> clazz,
                                                                              boolean strictStart) {
    T result = null;
    for (PsiElement root : file.getViewProvider().getAllFiles()) {
      PsiElement elementAt = root.findElementAt(offset);
      if (elementAt != null) {
        T parent = getParentOfType(elementAt, clazz, strictStart);
        if (parent != null) {
          TextRange range = parent.getTextRange();
          if (!strictStart || range.getStartOffset() == offset) {
            if (result == null || result.getTextRange().getEndOffset() > range.getEndOffset()) {
              result = parent;
            }
          }
        }
      }
    }
    return result;
  }
@Contract(pure = true)
  public static @Nullable <T extends PsiElement> T findElementOfClassAtOffset(@NotNull PsiFile file,
                                                                              int offset,
                                                                              @NotNull Class<T> clazz,
                                                                              boolean strictStart)