Skip to content

fix: change text on cart delete verification#875

Merged
smarcet merged 1 commit intomasterfrom
fix/change-text-cart-delete-verification
Apr 17, 2026
Merged

fix: change text on cart delete verification#875
smarcet merged 1 commit intomasterfrom
fix/change-text-cart-delete-verification

Conversation

@priscila-moneo
Copy link
Copy Markdown

@priscila-moneo priscila-moneo commented Apr 15, 2026

ref: https://app.clickup.com/t/86b9b9jbe

Summary by CodeRabbit

  • New Features
    • Added a localized delete-confirmation message with a placeholder for the item name.
    • Sponsor cart delete dialogs now display the item name in the confirmation text and use an error-styled confirm button for clearer intent.

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 15, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 277a32c7-57d3-4102-bc26-b645bf6fc473

📥 Commits

Reviewing files that changed from the base of the PR and between 7390f69 and e2b5d83.

📒 Files selected for processing (2)
  • src/i18n/en.json
  • src/pages/sponsors/sponsor-page/tabs/sponsor-cart-tab/components/cart-view.js
✅ Files skipped from review due to trivial changes (2)
  • src/pages/sponsors/sponsor-page/tabs/sponsor-cart-tab/components/cart-view.js
  • src/i18n/en.json

📝 Walkthrough

Walkthrough

Added a new i18n key for delete confirmation in the sponsor cart and updated CartView to provide a localized deleteDialogBody (with {form} interpolation) and set the confirmation button color to error on the MuiTable.

Changes

Cohort / File(s) Summary
i18n addition
src/i18n/en.json
Added sponsor_settings.cart_tab.delete_form_confirm translation with {form} interpolation.
Sponsor cart UI
src/pages/sponsors/sponsor-page/tabs/sponsor-cart-tab/components/cart-view.js
CartView now passes deleteDialogBody (returns translated confirmation with formName fallback) and confirmButtonColor="error" to MuiTable.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Suggested reviewers

  • smarcet
  • martinquiroga-exo

Poem

🐰 I nibble strings and hop with cheer,
A {form} appears — now crystal clear.
Red button ready, message neat,
Confirm or cancel — a tidy feat.
Hooray for clean dialogs, one small hop, repeat.

🚥 Pre-merge checks | ✅ 3
✅ 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 accurately describes the main change: updating text displayed during cart delete verification, which aligns with the i18n addition and the CartView component modifications.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ 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/change-text-cart-delete-verification

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

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In
`@src/pages/sponsors/sponsor-page/tabs/sponsor-cart-tab/components/cart-view.js`:
- Around line 196-199: The deleteDialogBody callback is expecting a row object
but MuiTable calls it with a form name string (via getName(item)), so change the
handler in cart-view.js (the deleteDialogBody prop) to treat its parameter as
the form name string (e.g., rename param to name or formName) and pass that
directly into T.translate (use name ?? ""), rather than accessing row?.name;
this will ensure the confirmation text includes the actual form name when
MuiTable invokes deleteDialogBody(getName(item)).
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: afb31fb1-8c88-4a6e-864f-b1cf92b0f59a

📥 Commits

Reviewing files that changed from the base of the PR and between 68ac5d1 and 7390f69.

📒 Files selected for processing (2)
  • src/i18n/en.json
  • src/pages/sponsors/sponsor-page/tabs/sponsor-cart-tab/components/cart-view.js

Comment thread src/pages/sponsors/sponsor-page/tabs/sponsor-cart-tab/components/cart-view.js Outdated
@priscila-moneo priscila-moneo force-pushed the fix/change-text-cart-delete-verification branch from 7390f69 to e2b5d83 Compare April 16, 2026 14:09
Copy link
Copy Markdown

@santipalenque santipalenque left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Copy Markdown

@smarcet smarcet left a comment

Choose a reason for hiding this comment

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

LGTM

@smarcet smarcet merged commit d4d9dc2 into master Apr 17, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants