Skip to content

fix(ui): bring the context-menu family back under its byte budgets - #401

Merged
JuroOravec merged 1 commit into
mainfrom
fix/context-menu-budget
Oct 25, 2026
Merged

JuroOravec merged 1 commit into
mainfrom
fix/context-menu-budget

Conversation

@JuroOravec

Copy link
Copy Markdown
Member

citry_ui/quality/tests/test_asset_report.py::test_context_menu_assets_stay_within_the_family_budgets fails on main since #395.

context-menu family JS before #395 main this PR budget
raw 160,312 164,595 163,292 163,840 (160 KiB)
gzip 34,599 35,772 35,475 34,816, now 35,840 (35 KiB)
brotli 29,021 29,968 29,842 30,720 (30 KiB)

The added JS and the CSS budgets were never over.

Evidence, run locally:

  • CMenu, CContextMenu, CSplitButton and the asset report tests: 227 passed.
  • The docs menu e2e tests: 3 passed.
  • ruff check and ruff format pass.

🤖 Generated with Claude Code

#395 made CMenu scroll only its own list and scroll the page only after
a key press. That grew the context-menu family's JavaScript to 164,595
raw bytes against the 160 KiB budget, and 35,772 gzip bytes against
34 KiB, so test_context_menu_assets_stay_within_the_family_budgets fails
on main.

The new code is now shorter: one helper computes the least scroll for
both axes, and the comments say the same things in fewer words. The raw
size is 163,292 bytes, under its budget. The gzip size is 35,475 bytes,
which is still over 34 KiB, so that one budget goes to 35 KiB, with the
reason in the test.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@JuroOravec
JuroOravec merged commit 5a4e517 into main Oct 25, 2026
20 of 26 checks passed
@JuroOravec
JuroOravec deleted the fix/context-menu-budget branch October 25, 2026 14:12
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