Skip to content

[Due for payment 2026-04-14] Reports - Category column does not align with the table header #86791

Closed

Description

@lanitochka17

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Version Number: 9.3.51-0
Reproducible in staging?: Yes
Reproducible in production?: N/A - new feature, doesn't exist in prod
If this was caught during regression testing, add the test name, ID and link from BrowserStack: #85818
Email or phone of affected tester (no customers): soidnjsojdiosjiosdjo@gmail.com
Issue reported by: Applause Internal Team
Bug source: Exploratory - Significant User Experience Deterioration
Device used: Mac 26.2 / Chrome
App Component: Search

Action Performed:

  1. Go to staging.new.expensify.com
  2. Go to workspace chat.
  3. Create two expenses.
  4. Delete one of the expenses.
  5. Go to Reports > Expenses.
  6. Click Status, select Deleted and click Apply.

Expected Result:

Category column will align with the table header.

Actual Result:

Category column does not align with the table header.

Workaround:

Unknown

Platforms:

  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome / Safari

Screenshots/Videos

Bug7118356_1774987421106.4.mp4

View all open jobs on GitHub

Issue OwnerCurrent Issue Owner: @jakubstec

Activity

  1. added
    DeployBlockerCashThis issue or pull request should block deployment
    BugSomething is broken. Auto assigns a BugZero manager.
    on Mar 31, 2026
  2. melvin-bot commented on Mar 31, 2026

    @melvin-bot

    You have been assigned to this deploy blocker because you recently merged this PR: #85818

  3. melvin-bot commented on Mar 31, 2026

    @melvin-bot

    💬 A slack conversation has been started in #expensify-open-source

  4. github-actions commented on Mar 31, 2026

    @github-actions
    Contributor

    👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:

    1. Identify the pull request that introduced this issue and revert it.
    2. Find someone who can quickly fix the issue.
    3. Fix the issue yourself.
  5. OSBotify commented on Mar 31, 2026

    @OSBotify
    Contributor

    🔍 Investigation Summary

    Classification: Frontend bug
    Causing PR: #85818 - "Deleted transactions on search" by @jnowakow (High confidence)
    Related Issues: None

    Recommendation: ROLL FORWARD

    The PR #85818 added support for deleted transactions in search, but introduced a table column alignment issue. The problem is that deleted transactions do not have an action value, which causes the ACTION column to be empty while other rows have content in this column. This creates misalignment between the table header and row data.

    A fix PR should ensure that deleted transactions either:

    1. Have a consistent action value (like "undelete") so the ACTION column is populated, OR
    2. Handle the empty ACTION column case to maintain proper spacing/alignment

    Rolling forward with a fix is preferable to reverting because:

    • The feature (deleted transactions in search) is valuable and mostly working
    • The fix is straightforward (ensure ACTION column has consistent content)
    • Reverting would remove the entire deleted transactions feature

    Labels: Keeping DeployBlockerCash (App PR caused the issue)

    📋 Detailed Analysis

    Evidence

    PR #85818 added the ability to view deleted transactions in the search results by:

    • Adding a new "Deleted" status filter
    • Creating a special TRASH_REPORT_ID constant for deleted transactions
    • Modifying the StatusCell component to show "Deleted" status
    • Adding various UI changes to handle deleted transactions differently (disabled clicks, cursor changes, etc.)

    The bug manifests when filtering by "Deleted" status - the Category column (and potentially other columns) do not align with the table header.

    Verification

    Files affected by PR #85818 that relate to the table rendering:

    • src/components/TransactionItemRow/index.tsx - Renders transaction rows including the ACTION column
    • src/components/Search/SearchList/ListItem/StatusCell.tsx - Shows status in table
    • src/components/Search/SearchList/ListItem/TransactionListItem.tsx - Main transaction list item component
    • src/hooks/useSearchBulkActions.ts - Adds undelete bulk action

    The TransactionItemRow component renders columns dynamically, including an ACTION column. For normal transactions, this column contains an ActionCell with action buttons. For deleted transactions, the transactionItem.action is likely null/undefined, causing the ACTION column to render empty.

    Root Cause

    In src/components/TransactionItemRow/index.tsx, the ACTION column is rendered conditionally:

    case CONST.SEARCH.TABLE_COLUMNS.ACTION:
        return (
            <View style={[StyleUtils.getReportTableColumnStyles(CONST.SEARCH.TABLE_COLUMNS.ACTION)]}>
                {!!transactionItem.action && (
                    <ActionCell ... />
                )}
            </View>
        );

    When transactionItem.action is falsy for deleted transactions, the ACTION column renders as an empty View with just the column styles. This creates inconsistent widths between the header row (which always shows the ACTION column header) and data rows (where deleted transactions have an empty ACTION column).

    The table layout relies on consistent column widths across all rows. When one row has empty content in a column while others have content, flexbox/layout calculations cause misalignment with the header.

  6. MelvinBot commented on Mar 31, 2026

    @MelvinBot
    Contributor

    Proposal

    What is the root cause of that problem?

    PR #85818 conditionally removes the arrow-right navigation button for deleted transactions (TransactionListItem.tsx:236):

    onArrowRightPress={isDeletedTransaction ? undefined : () => onSelectRow(item, transactionPreviewData)}
    

    In TransactionItemRow/index.tsx:805, the arrow button only renders when onArrowRightPress is truthy:

    {!!isLargeScreenWidth && !!onArrowRightPress && (
        <PressableWithFeedback ... >
            <Icon src={expensicons.ArrowRight} ... />
        </PressableWithFeedback>
    )}
    

    However, the table header always applies styles.pr8 (paddingRight: 32px) to reserve space for this arrow button (Search/index.tsx:1558):

    <View style={[!isTask && styles.pr8, styles.flex1]}>
        <SearchTableHeader ... />
    </View>
    

    When viewing deleted transactions, no rows have the arrow button, so each row's flex columns get ~32px more space than the header's flex columns. This progressive width mismatch causes rightmost columns like Category to visually drift out of alignment with their header.

    What changes do you think we should make in order to solve the problem?

    In TransactionItemRow/index.tsx, always render a placeholder/spacer View in the arrow button area when onArrowRightPress is undefined (on large screens). This ensures rows always occupy the same horizontal space as the header regardless of whether the arrow button is interactive. The spacer should match the width of the existing arrow button pressable (p3Half + icon size).

    What alternative solutions did you explore? (Optional)

    1. Conditionally remove pr8 from the header when all visible rows are deleted -- this is more complex since it requires passing deleted-state information up to the header wrapper, and would cause layout shifts when mixing deleted and non-deleted rows.
    2. Add right padding to the row container for deleted transactions -- this couples the fix to the deletion logic rather than keeping the layout consistent at the component level.

    Next Steps for Contributor+ team: Reply with @MelvinBot implement this to create a draft PR, @MelvinBot <your feedback> to refine this analysis, or explain why you are rejecting Melvin's proposal.

  7. jakubstec commented on Apr 1, 2026

    @jakubstec
    Member

    Hey! I'm Jakub Steć from Software Mansion, an expert agency.

    In linked PR 85818 during discussion with designers it was concluded to leave a gap with a right arrow styling which is absent in deleted expenses row. (link to message in mentioned PR: link

    Here is PR fix: link

  8. 4 remaining items

  9. added
    Awaiting PaymentAuto-added when associated PR is deployed to production
    and removed on Apr 7, 2026
  10. changed the title [-]Reports - Category column does not align with the table header[/-] [+][Due for payment 2026-04-14] Reports - Category column does not align with the table header[/+] on Apr 7, 2026
  11. melvin-bot commented on Apr 7, 2026

    @melvin-bot

    Reviewing label has been removed, please complete the "BugZero Checklist".

  12. melvin-bot commented on Apr 7, 2026

    @melvin-bot

    The solution for this issue has been 🚀 deployed to production 🚀 in version 9.3.52-9 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:

    If no regressions arise, payment will be issued on 2026-04-14. 🎊

    For reference, here are some details about the assignees on this issue:

    • @jakubstec does not require payment (Contractor)
  13. melvin-bot commented on Apr 7, 2026

    @melvin-bot

    @luacmartins @jakubstec The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]

  14. melvin-bot commented on Apr 7, 2026

    @melvin-bot

    Triggered auto assignment to @mallenexpensify (Awaiting Payment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.EngineeringReviewingHas a PR in reviewWeeklyKSv2

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions