Skip to content

Prevent broken page layout from table overflow#3256

Open
ritorhymes wants to merge 2 commits intozaproxy:mainfrom
ritovision:fix/table-responsive-scroll
Open

Prevent broken page layout from table overflow#3256
ritorhymes wants to merge 2 commits intozaproxy:mainfrom
ritovision:fix/table-responsive-scroll

Conversation

@ritorhymes
Copy link
Contributor

@ritorhymes ritorhymes commented Sep 18, 2025

Description

The tables throughout the site are not mobile responsive and cause horizontal page overflow when they're too wide to fit on the page. This breaks the layout on mobile and introduces difficulties scrolling around the page.

This fix:

  • Modifies global table behavior to be horizontally scrollable internally instead of the page itself.
  • Creates _tables.scss for table helper styles.
  • Creates a .sticky-table class to allow tables' top row of cells to remain fixed for context while scrolling.
  • Extends .market-table with .sticky-table so the top filter row is always accessible.
  • Moves .market-table from addons.scss into _tables.scss since it is reused on multiple pages.

Pages with tables that had page overflow:
/docs/internal-statistics/
/docs/internal-events/
/docs/constants/
/docs/alerts/

You can test the fix out on this page of the demo site zaproxy.ritovision.com/docs/constants/

Before and After

Recorded on an Android Chrome browser, screen size about 450px.

Before

zaproxy-tables-before_1.webm

After

zaproxy-tables-after.webm

@psiinon
Copy link
Member

psiinon commented Sep 18, 2025

Logo
Checkmarx One – Scan Summary & Detailsd5ab3598-3d7f-4312-a985-5276e042c880

Great job! No new security vulnerabilities introduced in this pull request


Use @Checkmarx to interact with Checkmarx PR Assistant.
Examples:
@Checkmarx how are you able to help me?
@Checkmarx rescan this PR

@kingthorin
Copy link
Member

@ritorhymes ritorhymes force-pushed the fix/table-responsive-scroll branch from 274bac2 to 46cb499 Compare September 18, 2025 11:05
@ritorhymes
Copy link
Contributor Author

@kingthorin got it, thanks! I just took care of them.

@thc202 thc202 changed the title fix(table): prevent broken page layout from table overflow Prevent broken page layout from table overflow Sep 29, 2025
@ritorhymes ritorhymes force-pushed the fix/table-responsive-scroll branch from 05da725 to edab822 Compare December 27, 2025 10:49
@thc202
Copy link
Member

thc202 commented Mar 13, 2026

This needs a push (probably worth rebasing), the checks didn't trigger for some reason.

Allow tables to scroll horizontally internally when they
exceed the page width.

This prevents tables from expanding the page width,
breaking the layout, and causing page-wide horizontal
scrolling.

Signed-off-by: Rito Rhymes <rito@ritovision.com>
Create a shared .sticky-table utility for tables with sticky
top header cells inside a scrollable container.

Set a max height and internal vertical scrolling so sticky
positioning takes effect and header cells stay above content.

Apply it to .market-table and move those styles from
addons.scss into _tables.scss, where shared table styles
belong.

Signed-off-by: Rito Rhymes <rito@ritovision.com>
@ritorhymes ritorhymes force-pushed the fix/table-responsive-scroll branch from edab822 to 2bdab64 Compare March 13, 2026 10:00
@ritorhymes
Copy link
Contributor Author

Done. Updated the commit msg clarity too.

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

Labels

None yet

Development

Successfully merging this pull request may close these issues.

4 participants