Improve combat and training HUD responsive fit#1939
Merged
Conversation
Agent-Logs-Url: https://github.com/Hack23/blacktrigram/sessions/307e6ccb-0b1c-4c8c-942d-411941327b46 Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
Agent-Logs-Url: https://github.com/Hack23/blacktrigram/sessions/307e6ccb-0b1c-4c8c-942d-411941327b46 Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
Agent-Logs-Url: https://github.com/Hack23/blacktrigram/sessions/307e6ccb-0b1c-4c8c-942d-411941327b46 Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
Copilot created this pull request from a session on behalf of
pethers
May 15, 2026 11:30
View session
Contributor
Dependency Reviewโ No vulnerabilities or license issues or OpenSSF Scorecard issues found.Scanned FilesNone |
Contributor
๐ฏ Accessibility Test ResultsWCAG 2.1 Level AA Compliance Tests
Components Tested
Test Framework
|
Contributor
There was a problem hiding this comment.
Pull request overview
This PR improves combat and training HUD fit across responsive screenshot-analysis viewports by centralizing HUD scale/height calculations, aligning arena reservations with rendered HUD bars, and making screenshot navigation more reliable.
Changes:
- Added shared combat/training HUD height constants and a shared large-display HUD position scale helper.
- Updated combat/training layout hooks and HUD components to reserve actual top/bottom HUD space.
- Hardened screenshot capture navigation and removed the forced Brotli preview header.
Reviewed changes
Copilot reviewed 19 out of 19 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
vite.config.ts |
Removes forced Brotli preview response header. |
src/utils/responsiveLayoutHelpers.ts |
Adjusts desktop arena width budget and adds shared HUD scale helper. |
src/utils/__tests__/responsiveLayoutHelpers.test.ts |
Adds coverage for arena width budget and HUD scale helper. |
src/types/constants/layout.ts |
Adds shared combat/training HUD height ratio constants. |
src/hooks/useHUDLayout.ts |
Uses shared HUD height constants for side/top/bottom HUD offsets. |
src/hooks/useHUDLayout.test.tsx |
Adds direct alignment tests for combat and training HUD offsets. |
src/hooks/__tests__/useHUDLayout.test.ts |
Updates existing expectations for new combat HUD reservations. |
src/components/screens/training/TrainingScreen3D.tsx |
Reuses shared HUD position scale calculation. |
src/components/screens/training/hooks/useTrainingLayout.ts |
Reserves actual training HUD heights in training area bounds. |
src/components/screens/training/hooks/useTrainingLayout.responsive.test.ts |
Adds responsive training viewport fit tests. |
src/components/screens/training/components/hud/TrainingBottomHUD.tsx |
Uses shared training bottom HUD height constant. |
src/components/screens/combat/hooks/useCombatLayout.ts |
Reserves actual combat HUD heights in arena bounds. |
src/components/screens/combat/hooks/useCombatLayout.test.ts |
Updates combat arena positioning expectation. |
src/components/screens/combat/components/hud/CombatTopHUD.tsx |
Uses shared combat top HUD height constant. |
src/components/screens/combat/components/hud/CombatRightHUD.test.tsx |
Updates side HUD sizing expectations. |
src/components/screens/combat/components/hud/CombatLeftHUD.test.tsx |
Updates side HUD sizing expectations. |
src/components/screens/combat/components/hud/CombatBottomHUD.tsx |
Uses shared combat bottom HUD height constant. |
src/components/screens/combat/CombatScreen3D.tsx |
Reuses shared HUD scale and top HUD height for overlay offsets. |
scripts/capture-screenshots.ts |
Adds DOM-ready navigation helper with timeout for screenshot flows. |
Contributor
๐ธ Automated UI Screenshots๐ Screenshots Captured (8)
๐ฆ Download Screenshots๐ฅ Download all screenshots from workflow artifacts
๐ค Generated by Playwright automation |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Combat and training HUDs needed better fit, sizing, and placement across screenshot-analysis resolutions. This updates HUD layout synchronization and screenshot capture reliability for reviewing UI/UX regressions.
HUD layout
Arena/content fit
Screenshot analysis