Skip to content

Adjust desktop table row styles: tighter gaps and padding#84676

Draft
MelvinBot wants to merge 75 commits intomainfrom
claude-adjustTableRowStyles
Draft

Adjust desktop table row styles: tighter gaps and padding#84676
MelvinBot wants to merge 75 commits intomainfrom
claude-adjustTableRowStyles

Conversation

@MelvinBot
Copy link
Contributor

Explanation of Change

Adjusts table row styles on desktop to create a tighter, more compact table layout across the app. Specifically:

  1. Reduces vertical gaps between table rows from 8px to 4px on desktop (mb2mb1), affecting:

    • Transaction rows in search/reports (TransactionListItem)
    • Group headers in search/reports (TransactionGroupListItem)
    • Workspace table items for Categories, Tags, Expense Rules (TableListItem)
  2. Normalizes row padding to 12px horizontal / 8px vertical on desktop:

    • Expanded group transaction rows (TransactionGroupListExpanded): changed from 6px to 8px vertical
    • Workspace table items (TableListItem): changed from 16px to 12px horizontal, 16px to 8px vertical
  3. Reduces gap between table header and first row from 12px to 8px (searchListHeaderContainerStyle.paddingBottom)

All changes are desktop-only — mobile styles remain unchanged. Table header paddings are not modified.

Fixed Issues

$

Tests

  1. Open the app on desktop (web)
  2. Navigate to the Reports/Search page
  3. Verify table rows have tighter vertical spacing (4px gaps instead of 8px)
  4. Verify row padding is 12px horizontal, 8px vertical
  5. Verify the gap between the table column headers and the first row is reduced
  6. Open a workspace and navigate to Categories or Tags
  7. Verify the same tighter spacing applies to workspace table rows
  8. Navigate to Account > Expense Rules
  9. Verify the same tighter spacing applies
  10. Expand an expense report group and verify the child transaction rows also have the updated padding
  11. Resize the browser to mobile width and verify mobile styles are unchanged (rows should still have 8px gaps)
  12. Verify table header (column names row) padding has not changed
  • Verify that no errors appear in the JS console

Offline tests

N/A — these are purely visual style changes with no network dependency.

QA Steps

  1. On desktop web, navigate to the Reports/Search page
  2. Verify table rows appear more compact with tighter vertical gaps
  3. Navigate to a workspace Categories or Tags page and verify the same compact spacing
  4. Navigate to Account > Expense Rules and verify compact spacing
  5. Expand an expense report group and verify child rows have consistent padding
  6. On mobile web, verify the row spacing has NOT changed
  • Verify that no errors appear in the JS console

PR Author Checklist

  • I linked the correct issue in the ### Fixed Issues section above
  • I wrote clear testing steps that cover the changes made in this PR
    • I added steps for local testing in the Tests section
    • I added steps for the expected offline behavior in the Offline steps section
    • I added steps for Staging and/or Production testing in the QA steps section
    • I added steps to cover failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
    • I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)
    • I tested this PR with a High Traffic account against the staging or production API to ensure there are no regressions (e.g. long loading states that impact usability).
  • I included screenshots or videos for tests on all platforms
  • I ran the tests on all platforms & verified they passed on:
    • Android: Native
    • Android: mWeb Chrome
    • iOS: Native
    • iOS: mWeb Safari
    • MacOS: Chrome / Safari
  • I verified there are no console errors (if there's a console error not related to the PR, report it or open an issue for it to be fixed)
  • I followed proper code patterns (see Reviewing the code)
    • I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. toggleReport and not onIconClick)
    • I verified that comments were added to code that is not self explanatory
    • I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
    • I verified any copy / text shown in the product is localized by adding it to src/languages/* files and using the translation method
      • If any non-english text was added/modified, I used JaimeGPT to get English > Spanish translation. I then posted it in #expensify-open-source and it was approved by an internal Expensify engineer. Link to Slack message:
    • I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
    • I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is either coming verbatim from figma or has been approved by marketing (in order to get marketing approval, ask the Bug Zero team member to add the Waiting for copy label to the issue)
    • I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
    • I verified the JSDocs style guidelines (in STYLE.md) were followed
  • If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
  • I followed the guidelines as stated in the Review Guidelines
  • I tested other components that can be impacted by my changes (i.e. if the PR modifies a shared library or component like Avatar, I verified the components using Avatar are working as expected)
  • I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
  • I verified any variables that can be defined as constants (ie. in CONST.ts or at the top of the file that uses the constant) are defined as such
  • I verified that if a function's arguments changed that all usages have also been updated correctly
  • If any new file was added I verified that:
    • The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory
  • If a new CSS style is added I verified that:
    • A similar style doesn't already exist
    • The style can't be created with an existing StyleUtils function (i.e. StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))
  • If new assets were added or existing ones were modified, I verified that:
    • The assets are optimized and compressed (for SVG files, run npm run compress-svg)
    • The assets load correctly across all supported platforms.
  • If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
  • If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like Avatar is modified, I verified that Avatar is working as expected in all cases)
  • If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
  • If the PR modifies a component or page that can be accessed by a direct deeplink, I verified that the code functions as expected when the deeplink is used - from a logged in and logged out account.
  • If the PR modifies the UI (e.g. new buttons, new UI components, changing the padding/spacing/sizing, moving components, etc) or modifies the form input styles:
    • I verified that all the inputs inside a form are aligned with each other.
    • I added Design label and/or tagged @Expensify/design so the design team can review the changes.
  • If a new page is added, I verified it's using the ScrollView component to make it scrollable when more elements are added to the page.
  • I added unit tests for any new feature or bug fix in this PR to help automatically prevent regressions in this user flow.
  • If the main branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the Test steps.

Screenshots/Videos

Android: Native

N/A — desktop-only style changes

Android: mWeb Chrome

N/A — desktop-only style changes

iOS: Native

N/A — desktop-only style changes

iOS: mWeb Safari

N/A — desktop-only style changes

MacOS: Chrome / Safari

Screenshots to be added after visual review

- Reduce gap between table rows from 8px to 4px on desktop
- Set row padding to 12px horizontal / 8px vertical on desktop
- Reduce gap between table header and first row from 12px to 8px
- Changes apply to search results, workspace editor, and expense rules
- Mobile styles remain unchanged

Co-authored-by: Shawn Borton <shawnborton@users.noreply.github.com>
@MelvinBot MelvinBot requested a review from a team March 10, 2026 04:00
@codecov
Copy link

codecov bot commented Mar 10, 2026

@MelvinBot
Copy link
Contributor Author

The failing check is unrelated to this PR.

Analysis: The ESLint check is failing due to 336 pre-existing warnings in files not touched by this PR. The warnings are react-hooks/set-state-in-effect and react-hooks/preserve-manual-memoization violations in:

  • src/pages/workspace/travel/WorkspaceTravelInvoicingExportPage.tsx
  • src/pages/workspace/upgrade/WorkspaceUpgradePage.tsx
  • src/pages/workspace/workflows/approvals/WorkspaceWorkflowsApprovalsEditPage.tsx
  • src/pages/workspace/workflows/approvals/WorkspaceWorkflowsApprovalsExpensesFromPage.tsx

None of these files are part of this PR's changeset.

Evidence: The Changed files ESLint check (which lints only PR-modified files) passes. The full ESLint check is also failing on the main branch — the two most recent lint runs on main both show failure. This confirms the issue is pre-existing and not introduced by this PR.

@github-actions
Copy link
Contributor

🚧 @shawnborton has triggered a test Expensify/App build. You can view the workflow run here.

@github-actions

This comment has been minimized.

@shawnborton
Copy link
Contributor

@MelvinBot I meant the gaps in between each table row. It looks like those gaps are still 8px instead of 4px. Can you tighten all gaps between table rows please?

It looks like the gaps are tighter on Reports > Expenses, but not the Reports > Reports page. Please make this update everywhere. And it looks like the padding didn't change on Reports > Reports either. Please make those updates to this PR.

@shawnborton
Copy link
Contributor

@MelvinBot can you also change the minimum height on these table rows to be 52px instead of 64px? For example, in the workspace editor in the categories list, I see a min height of 64px but it should be 52px instead:
CleanShot 2026-03-10 at 07 49 08@2x

…orts > Reports page)

Reduce vertical gap between rows from 8px to 4px (mb2 → mb1) and
row padding from 12px to 8px vertical (pv3 → pv2) on desktop,
matching the same changes already applied to TransactionListItem
and TransactionGroupListItem.

Co-authored-by: Shawn Borton <shawnborton@users.noreply.github.com>
@MelvinBot
Copy link
Contributor Author

Updated `ExpenseReportListItem` (Reports > Reports page) to match the tighter desktop styling already applied to the Expenses tab:

  1. Row gaps: `mb2` → `mb1` on desktop (8px → 4px)
  2. Vertical padding: `pv3` → `pv2` on desktop (12px → 8px)

Both changes are desktop-only — mobile styles remain unchanged.

Override minHeight with variables.optionRowHeightCompact (52px) on
desktop for TableListItem, ExpenseReportListItem, TransactionListItem,
and TransactionGroupListItem.

Co-authored-by: Shawn Borton <shawnborton@users.noreply.github.com>
@MelvinBot
Copy link
Contributor Author

Reduced the table row minimum height from 64px to 52px on desktop across all list item components:

  • TableListItem (workspace settings lists like categories)
  • ExpenseReportListItem (Reports > Reports)
  • TransactionListItem (Reports > Expenses)
  • TransactionGroupListItem (Reports > Expenses grouped)

Uses the existing variables.optionRowHeightCompact (52px) to override the default optionRowHeight (64px) on desktop only — mobile min height remains unchanged.

@github-actions
Copy link
Contributor

🚧 @shawnborton has triggered a test Expensify/App build. You can view the workflow run here.

@shawnborton
Copy link
Contributor

@MelvinBot some changes you need to make:

  • please make the minimum height change to 52px for all table rows, including table rows in the workspace editor (categories, tags, etc)
  • the gaps between table rows in the Reports > Reports section are still too big
  • the minimum height of table rows in Reports > Reports is still too big, it should be 52px
  • the vertical padding of table rows in Reports > Reports needs to be changed to 8px

Match the same desktop-only changes applied to other list item components:
- Reduce vertical padding from 12px to 8px (pv3 → pv2)
- Set minHeight to 52px (optionRowHeightCompact)
- Reduce row gap from 8px to 4px (mb2 → mb1)

Co-authored-by: Shawn Borton <shawnborton@users.noreply.github.com>
@MelvinBot
Copy link
Contributor Author

Here's a summary of all desktop table row styling changes now in this PR:

Components updated with 52px minHeight, 8px vertical padding, and 4px row gaps on desktop:

Component Used For minHeight 52px pv2 (8px) mb1 (4px gap)
TableListItem Workspace editor (categories, tags, members, taxes, etc.)
ExpenseReportListItem Reports > Reports
TransactionListItem Reports > Expenses (single) — (uses own style)
TransactionGroupListItem Reports > Expenses (grouped) — (uses own style)
TransactionGroupListExpanded Expanded transaction group rows — (child rows)
TaskListItem Tasks

All changes are desktop-only — mobile styles remain unchanged. Please trigger a new adhoc build to test.

@github-actions
Copy link
Contributor

🚧 @shawnborton has triggered a test Expensify/App build. You can view the workflow run here.

@shawnborton
Copy link
Contributor

@MelvinBot for the Reports > Reports page, it looks like we aren't using gap but instead we use a bottom margin of 8px. Can we update that bottom margin to be 4px?
CleanShot 2026-03-10 at 09 40 07@2x

We also need those rows to have a minimum height of 52px, and vertical padding of 8px. You still haven't made those changes, can you please implement?

@MelvinBot
Copy link
Contributor Author

All three changes for the Reports > Reports page (ExpenseReportListItem) are already in the latest commit on this branch:

  1. Bottom margin 8px → 4px: containerStyle={isLargeScreenWidth ? [styles.mb1] : [styles.mb2]}mb1 = 4px, mb2 = 8px
  2. Vertical padding 8px: isLargeScreenWidth ? styles.pv2 : styles.pv3pv2 = 8px
  3. Min height 52px: isLargeScreenWidth && {minHeight: variables.optionRowHeightCompact}optionRowHeightCompact = 52px

The screenshot may be from the previous test build (triggered before these changes were pushed). Please trigger a new test build to verify.

@shawnborton
Copy link
Contributor

@MelvinBot thanks. Can you also make these same exact changes when you are viewing the table on an expense report? So if you are on Reports > Reports and you are viewing an expense report with multiple expenses, we want to make the same changes to that table as well:
CleanShot 2026-03-10 at 11 15 28@2x

Reduce row gaps from 8px to 4px (gap2 → gap1) and vertical row
padding from 12px to 8px (p3 + pv2) on desktop for the transaction
table inside expanded expense reports (MoneyRequestReportTransactionList
and MoneyRequestReportTransactionItem).

Co-authored-by: Shawn Borton <shawnborton@users.noreply.github.com>
@MelvinBot
Copy link
Contributor Author

Applied the same tighter desktop styling to the expense report detail view (the table you see when viewing an expense report with multiple expenses):

MoneyRequestReportTransactionList:

  • Container gap between rows: gap2gap1 on desktop (8px → 4px)
  • Group container gap: gap2gap1 on desktop (8px → 4px)

MoneyRequestReportTransactionItem:

  • Row vertical padding: added pv2 override on desktop (12px → 8px)

Mobile styles remain unchanged.

@github-actions
Copy link
Contributor

🚧 @shawnborton has triggered a test Expensify/App build. You can view the workflow run here.

@github-actions
Copy link
Contributor

🚧 @shawnborton has triggered a test Expensify/App build. You can view the workflow run here.

@shawnborton
Copy link
Contributor

@MelvinBot more changes. You need to change the minimum height on these table rows inside of an expense report to be 52px instead of 64px.
CleanShot 2026-03-10 at 13 32 51@2x

And can you also remove the top margin from the subgroup header? For instance, when we group the table by category, the group header that has a checkbox and the category name. It has a top margin of 16px currently, and we simply want to get rid of it.
CleanShot 2026-03-10 at 13 34 01@2x

@github-actions
Copy link
Contributor

🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
Built from App PR #84676.

Android 🤖 iOS 🍎
⏩ SKIPPED ⏩ ⏩ SKIPPED ⏩
The build for Android was skipped The build for iOS was skipped
Web 🕸️
https://84676.pr-testing.expensify.com
Web

👀 View the workflow run that generated this build 👀

@github-actions
Copy link
Contributor

🚧 @shawnborton has triggered a test Expensify/App build. You can view the workflow run here.

@github-actions
Copy link
Contributor

🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
Built from App PR #84676.

Android 🤖 iOS 🍎
❌ FAILED ❌ https://ad-hoc-expensify-cash.s3.us-east-1.amazonaws.com/rock-artifacts/ad-hoc/rock-ios-device-AdHoc-027b698-7c10bda-30621ab1bc29334d77477a48235426361d86a3b9/index.html
The QR code can't be generated, because the Android build failed iOS
Web 🕸️
https://84676.pr-testing.expensify.com
Web

👀 View the workflow run that generated this build 👀

@shawnborton
Copy link
Contributor

@MelvinBot please pull main

…Styles

Co-authored-by: Shawn Borton <shawnborton@users.noreply.github.com>
@MelvinBot
Copy link
Contributor Author

Merged main into the branch. The merge completed cleanly with no conflicts.

@github-actions
Copy link
Contributor

🚧 @shawnborton has triggered a test Expensify/App build. You can view the workflow run here.

@shawnborton
Copy link
Contributor

@MelvinBot the table header that is shown when you are viewing an actual expense report needs to have an inner padding of 44px. Please do not touch the table headers shown on Reports > Reports or any of those pages, we just need this when viewing an expense report.

@MelvinBot
Copy link
Contributor Author

The failing check is unrelated to this PR.

Analysis: The only failure is in test (job 8) — specifically 2 test cases in tests/unit/canEditFieldOfMoneyRequestTest.ts:

  • should return true for submitter of a distance request for amount and currency fields (line 215)
  • should return true for submitter when there are multiple outstanding reports (line 231)

These tests are about money request field editing permissions ("move expense" logic), which has no connection to this PR's desktop table row style changes.

Evidence: This PR modifies styling files (paddings, margins, gaps) across SelectionList, TransactionItemRow, SearchTableHeader, and styles/ — none of which are related to canEditFieldOfMoneyRequest logic. The failing test file is not in the PR diff.

This appears to be a pre-existing test failure on main.

Replace pl9 (36px) + pr11 (44px) with ph11 (44px symmetrical)
on the table header shown when viewing an actual expense report.
Search page headers are unchanged.

Co-authored-by: Shawn Borton <shawnborton@users.noreply.github.com>
@MelvinBot
Copy link
Contributor Author

Updated the table header padding for the expense report view:

  • Replaced pl9 (36px left) + pr11 (44px right) with ph11 (44px symmetrical) on the header in TransactionGroupListExpanded
  • Search page headers (Reports > Reports, Reports > Expenses) are not affected

@shawnborton
Copy link
Contributor

@MelvinBot that's not correct, please undo that. We only want this change on the table header above the table of expenses found when you click into an actual expense report from say Reports > Reports.

The subgroup header (category/tag group headers) should keep their
16px top margin. The tighter styling is only intended for the table
column header inside the expense report detail view, which already
has the correct styling in MoneyRequestReportTransactionList.

Co-authored-by: Shawn Borton <shawnborton@users.noreply.github.com>
@MelvinBot
Copy link
Contributor Author

Restored marginTop: 16 on reportLayoutGroupHeader — the subgroup headers (category/tag group headers) will keep their original 16px top margin.

The tighter styling changes are already applied only to the table column header inside the expense report detail view (tableHeaderContent in MoneyRequestReportTransactionList).

@shawnborton
Copy link
Contributor

@MelvinBot please undo your past two commits, they are both incorrect.

@MelvinBot
Copy link
Contributor Author

Reverted the last two commits:

  • b672fae — Restore marginTop: 16 on reportLayoutGroupHeader
  • b03b8ed — Fix: Set 44px inner padding on expense report table header

Both changes have been undone via revert commits.

@shawnborton
Copy link
Contributor

@MelvinBot this screenshot is from an expense report view, it's what happens when you are actually drilled down into an expense report:
CleanShot 2026-03-19 at 07 30 29@2x

For the table header here, the row above the subgroup header and above the expense rows, can you make the inner right padding 44px please?

Co-authored-by: Shawn Borton <shawnborton@users.noreply.github.com>
@MelvinBot
Copy link
Contributor Author

Updated the table header in the expense report view (MoneyRequestReportTransactionList.tsx) — changed inner right padding from 12px (ph3) to 44px (pl3 + pr11). Left padding remains 12px.

@github-actions
Copy link
Contributor

🚧 @shawnborton has triggered a test Expensify/App build. You can view the workflow run here.

@shawnborton
Copy link
Contributor

@MelvinBot pull in main please

…Styles

Co-authored-by: Shawn Borton <shawnborton@users.noreply.github.com>
@MelvinBot
Copy link
Contributor Author

Merged main into this branch as requested.

@github-actions
Copy link
Contributor

🚧 @shawnborton has triggered a test Expensify/App build. You can view the workflow run here.

@MelvinBot
Copy link
Contributor Author

The failing check build (New Expensify Dev, DebugDevelopment, false) is unrelated to this PR.

Analysis: This PR only modifies TypeScript/React component files (styling and padding changes). The failing check is an iOS native build (xcodebuild) that shows RockError: Failed to build the project with no specific compiler errors in the log. The build log contains only warnings (Airship Sendable warnings, mapbox deprecation warnings) but zero actual compiler errors.

Evidence: The PR changes 51 .tsx/.ts files — all React component styles, padding values, and layout adjustments. No native iOS code, Xcode project files, Podfile, or any other native build artifacts were modified. The iOS build failure appears to be an infrastructure issue (the remote cache also failed with NoSuchKey at the start of the build).

Recommend re-running the failed check.

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.

2 participants