Skip to content

fix(platform): add success variant to toast notifications#1317

Merged
yannickmonney merged 3 commits into
mainfrom
fix/toast-success-icons
Apr 10, 2026
Merged

fix(platform): add success variant to toast notifications#1317
yannickmonney merged 3 commits into
mainfrom
fix/toast-success-icons

Conversation

@yannickmonney
Copy link
Copy Markdown
Contributor

@yannickmonney yannickmonney commented Apr 10, 2026

Summary

  • Add variant: 'success' to vendor import, customer import, product import, and RAG indexing retry toast notifications so they display the green CheckCircle2 icon
  • Fix product import partial success toast from variant: 'destructive' to variant: 'success'
  • Add missing product delete success toast with new actions.deleteSuccess translation key in en.json and de.json

Closes #1303, closes #1304, closes #1284, closes #1283

Summary by CodeRabbit

  • New Features

    • Bulk product import functionality for faster batch uploads
    • Product deletion success notifications
  • Improvements

    • Enhanced toast notifications with clearer success/error styling
    • More detailed error messages and reporting during import operations
    • Improved import status messaging for better clarity
  • Localization

    • Updated translation strings for product and customer imports in German and English

Add variant: 'success' to toast calls for vendor import, customer
import, product import (both clean and partial success), product
deletion, and RAG indexing retry. Also add missing product delete
success toast with translation keys in en.json and de.json.
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 10, 2026

Caution

Review failed

Pull request was closed or merged during review

📝 Walkthrough

Walkthrough

This pull request adds success toast variant styling to import and deletion operations across customers, products, and vendors modules, and refactors the product import workflow from sequential per-item creation to a single bulk creation operation. The bulk create mutation processes products sequentially, aggregates success/failure counts, and captures structured error information including error codes. Localization messages are updated to use new variable names ({success} instead of {count}) and improved pluralization logic for failed items, with a new errorCodes.unknown entry for handling unspecified bulk operation failures.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Out of Scope Changes check ⚠️ Warning Changes include a substantial refactoring of product imports to use bulkCreateProducts mutation, which extends beyond the minimal scope of just adding success toast variants to existing implementations. Consider separating the bulk product import refactoring into a separate PR to keep this PR focused on the core objective of fixing success icon visibility.
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and specifically identifies the main change: adding success variant styling to toast notifications.
Linked Issues check ✅ Passed All four linked issues are addressed: customer import [#1303], vendor import [#1304], and product import [#1284] success toasts now display success icons via variant, and product delete success toast [#1283] was added with translations.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/toast-success-icons

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@greptile-apps greptile-apps Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your free trial has ended. If you'd like to continue receiving code reviews, you can add a payment method here.

Replace Promise.allSettled with individual createProduct calls with a
single bulkCreateProducts mutation, matching the vendor/customer pattern
for consistent error handling and better performance.
Align vendor, customer, and product import dialogs to use the same
code flow: bulkCreate call, error code lookup in none-imported block,
consistent ICU successDescription params, and unified catch handling.
@yannickmonney yannickmonney merged commit d28a2f6 into main Apr 10, 2026
23 of 24 checks passed
@yannickmonney yannickmonney deleted the fix/toast-success-icons branch April 10, 2026 11:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant