Skip to content

Fix events#show layout: CFP Stats chart overflow and broken column ordering#1126

Merged
amatsuda merged 2 commits into
rubycentral:mainfrom
amatsuda:cfp_stats_fix
Jun 30, 2026
Merged

Fix events#show layout: CFP Stats chart overflow and broken column ordering#1126
amatsuda merged 2 commits into
rubycentral:mainfrom
amatsuda:cfp_stats_fix

Conversation

@amatsuda

Copy link
Copy Markdown
Collaborator

Two layout bugs on the public event page (events#show), both stemming from outdated CSS that didn't survive the Bootstrap 5 upgrade.

1. CFP Stats chart overflows into the guidelines text on resize

The "CFP Stats" line chart (Chartkick + Chart.js) is a responsive canvas that sizes itself to its parent's width. Its container .stats used display: table, and the CSS table-layout algorithm expands to fit content's intrinsic width instead of honoring width: 100%. On window resize this created a feedback loop — Chart.js drew a wider canvas, the table grew to fit it, Chart.js measured wider again — so the chart spilled out of its col-md-4 column and overlapped the proposal-guidelines text.

Fix: display: table → display: block on .stats, so the chart stays clamped to its column width. .stats is only ever used as this chart wrapper (the .stats .stat table-cell rules are dead — the styleguide uses #big_stats .stat), so nothing else is affected.

2. Dead Bootstrap 3 push/pull column classes

The two columns used col-md-push-8 / col-md-pull-4, which were removed in Bootstrap 4+. Under Bootstrap 5.3 they're no-ops, leaving the columns in raw source order (CFP status/stats on the left, guidelines on the right) instead of the intended layout.

Fix: Use order-md-* utilities to restore the intended layout — guidelines on the left, CFP status/stats sidebar on the
right — while keeping the status box first in t when columns stack on mobile.

amatsuda and others added 2 commits June 30, 2026 04:31
The chart container .stats used display: table, which expands to fit
its content's intrinsic width instead of honoring width: 100%. The
responsive Chart.js canvas and the table then fed each other's width on
window resize, letting the chart grow out of its column and overlap the
proposal guidelines text. Use display: block so the chart stays clamped
to the column width.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
col-md-push-8 / col-md-pull-4 were removed in Bootstrap 4+, so under
Bootstrap 5.3 they were no-ops, leaving the columns in source order
(CFP status/stats left, guidelines right). Use order-md-* utilities to
restore the intended layout: guidelines on the left, CFP status/stats
sidebar on the right, while keeping the status box first in source
order so it shows first when columns stack on mobile.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@amatsuda amatsuda merged commit 62fa9bb into rubycentral:main Jun 30, 2026
1 check passed
@amatsuda amatsuda deleted the cfp_stats_fix branch June 30, 2026 01:59
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.

1 participant