Added functionality for header and footer calculation with unit tests#269
Closed
James-Cocker wants to merge 2 commits intomainfrom
Closed
Added functionality for header and footer calculation with unit tests#269James-Cocker wants to merge 2 commits intomainfrom
James-Cocker wants to merge 2 commits intomainfrom
Conversation
Signed-off-by: James Cocker <james.s.earth@gmail.com>
James-Cocker
commented
Mar 6, 2026
| */ | ||
|
|
||
| .crumbContainer { | ||
| height: 84px; |
Contributor
Author
There was a problem hiding this comment.
Manually set this height otherwise it seems to default to 64px for an odd reason.
Signed-off-by: James Cocker <james.s.earth@gmail.com>
eamansour
previously approved these changes
Mar 9, 2026
Member
eamansour
left a comment
There was a problem hiding this comment.
A couple of minor comments but overall looks good, happy to approve!
Comment on lines
+63
to
+79
| // Calculate and set the dynamic max-height based on header and footer heights | ||
| useEffect(() => { | ||
| const updateMaxHeight = () => { | ||
| const headerFooterHeight = getHeightOfHeaderAndFooter(); | ||
| setMaxHeight(`calc(100vh - ${headerFooterHeight}px)`); | ||
| }; | ||
|
|
||
| // Initial calculation | ||
| updateMaxHeight(); | ||
|
|
||
| // Recalculate on window resize | ||
| window.addEventListener('resize', updateMaxHeight); | ||
|
|
||
| return () => { | ||
| window.removeEventListener('resize', updateMaxHeight); | ||
| }; | ||
| }, []); |
Member
There was a problem hiding this comment.
There's some code duplication now with the content of this useEffect and the useEffect in the CollapsibleSideBar component.
Is there a way to reduce this duplication?
Just tried the changes out locally and have sent James a few more questions - seems like the header and footer can make the test runs table harder to see on smaller screens.
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.
Why?
Closes galasa-dev/projectmanagement#2501.
Sets the max-height for the content on the /test-runs page (including the side bar) to be
100vh-height_of_headers_and_footerso that they scroll independently of one another, without the observer causing strange flickering and scrolling.Screenshot(s) of changes
Notice how the header and footer will always be on the screen.


Changes