@Override
  public @Nullable AutoImportQuickFix getFileModifierForPreview(@NotNull PsiFile target) {
    PsiElement unresolvedRef = getStartElement();
    if (unresolvedRef == null) return null;
    PsiElement unresolvedRefCopy = PsiTreeUtil.findSameElementInCopy(unresolvedRef, target);
    List<ImportCandidateHolder> candidates = new ArrayList<>();
    for (ImportCandidateHolder candidate : myImports) {
      ImportCandidateHolder importCandidateForPreview = updateExistingImportElementForPreview(candidate, target);
      if (importCandidateForPreview == null) return null;
      candidates.add(importCandidateForPreview);
    }
    return new AutoImportQuickFix(unresolvedRefCopy, myReferenceType, myInitialName, myUseQualifiedImport, candidates);
  }
@Override
  public @Nullable AutoImportQuickFix getFileModifierForPreview(@NotNull PsiFile target)