fix: update dispute table in payment details page#4953
Conversation
Changed Files
|
XyneSpaces
left a comment
There was a problem hiding this comment.
Automated Review Summary
PR: fix: update dispute table in payment details page
Reviewer: XyneSpaces Automation
Findings
✅ No blocking issues found. This is a well-scoped UI consistency fix that aligns the Disputes table with existing Payment Attempts and Refunds patterns.
Verified Changes
1. Layout Consistency (ShowOrder.res)
- Correctly replaces
RenderAccordionwrapper with the same pattern used for Attempts/Refunds sections - Adds explicit "Disputes" heading with proper Typography styling
- Structure now matches:
<div className="flex flex-col gap-4">+<p>heading +<CustomExpandableTable>
2. Column Definitions (DisputesEntity.res)
- ✅ Correctly adds
AmountandChallengeRequiredBytocolumnsInPaymentPage - ✅ Fixes column key from
connector_required_by→challenge_required_by(matches data field) - ✅ Updates title from "Connector Required By" → "Challenge Required By" (clearer semantics)
3. Date Rendering Fix (OrderUtils.res)
- ✅ Removes
customDateStyle="!font-fira-code"which was being incorrectly interpreted as a date format string - This fixes the garbled date display issue described in the PR
Code Quality Notes
Positive:
- Uses Typography module correctly (
body.lg.boldwithopen Typographyat file top) - Minimal, focused changes - only what's needed for the fix
- No unnecessary complexity introduced
Pre-existing Pattern Note:
The !font-fira-code style removal is correct. The prop customDateStyle in DisplayKeyValueParams is passed to Table.TableCell which expects a date format string, not CSS classes. The previous value was causing dates to render incorrectly (e.g., "!font-firpm-co2e IST").
Suggestion (Non-blocking)
Consider verifying that the text-nd_gray-900 color class in the new heading matches the color used in sibling Attempts/Refunds headings for perfect visual consistency:
// Current
<p className={`${body.lg.bold} text-nd_gray-900`}>
// Verify this matches Payment Attempts/Refunds heading colorsVerdict: Approved for merge pending standard CI checks.
Type of Change
Description
Aligns the Disputes table on the payment details page with the existing Payment Attempts and Refunds tables, and fixes a date-rendering bug in expandable detail panels.
Made layout similar to Attempts and Refunds and added new columns
Before
After
Fix date component
Before
After
Motivation and Context
On the payment details page, the Disputes table looked and behaved inconsistently with the Payment Attempts and Refunds tables — it was tucked inside an accordion, had no section heading, and showed only a few columns, which left an awkwardly large gap between "Dispute ID" and the next column. While bringing it in line, expanding a dispute row also exposed a latent bug where the Created (and any date) field rendered as a corrupted string, because a CSS class was mistakenly passed into a date-format prop on the shared details component. This change makes the three tables visually consistent and ensures dispute dates display correctly.
How did you test it?
Where to test it?
Backend Dependency
Backend PR URL:
Feature Flag
Feature flag name(s):
Checklist
npm run re:build