Uh oh!
There was an error while loading. Please reload this page.
#65 💇 Feat: Header Buttons & CSS Refinements - #247
Conversation
| fontColor: 'inherit', | ||
| // Table CountDisplay is hidden in order to position CountDisplay with Pagination | ||
| fontSize: '0px', | ||
| }, |
There was a problem hiding this comment.
There may be a better way to solve this; this is basically moving CountDisplay out of the table and into Pagination using CSS
I do not believe Pagination has a customElements or children Prop
And CountDisplay theming only allows font related properties, so setting fontSize to 0 hides it in the Table, and CountDisplay is added to the RepoTable render beside Pagination, using position: absolute to render it next to the pagination elements
There was a problem hiding this comment.
sounds like a candidate use case to provide a custom element or child prop to Pagination?
There was a problem hiding this comment.
the ToolBar component is one provided as is for convenience, but a custom toolbar can be built with the individual components seen here. no need to "hack" elements out of screen.
a good example of that custom toolbar implementation can be found in your work upgrading HCMI, iirc
There was a problem hiding this comment.
Ironically the custom Toolbar implementation was blocked b/c we could not use arranger@latest:
see components/search/Search L394
https://github.com/nci-hcmi-catalog/portal/pull/1108/files#diff-9169b023a738875edfa40a7bbfd0504daf901e19afa442610f37b96052cbfd20R394
There was a problem hiding this comment.
Toolbar is updated to use individual components in the same container as the navigation Button
| color: ${theme.colors.black}; | ||
| left: 170px; | ||
| position: absolute; | ||
| top: 3px; |
There was a problem hiding this comment.
There is also some fine-tuned CSS positioning that's worth reviewing
There was a problem hiding this comment.
Is this to anchor a child element with flex: 1 to a parent element?
There was a problem hiding this comment.
There was a problem hiding this comment.
can't they be all "grouped together by wrapping them in a flex-ed div though?
There was a problem hiding this comment.
I fixed the header up so elements are grouped and we no longer rely on position:absolute, it ends up being a nice refactor & separates logic a bit more
I will do the same for the Footer tomorrow
There was a problem hiding this comment.
Footer is updated to use separate MaxRows / CountDisplay / PageSelector components
joneubank
left a comment
There was a problem hiding this comment.
All of this seems fine to me, would prefer you get someone else to go through the styling and layout concerns before merging.
| switchTable={switchTable} | ||
| theme={theme} | ||
| /> | ||
| {isFileTableActive ? null : <FullScreenButton isFullScreen={false} setFullScreen={() => {}} theme={theme} />} |
There was a problem hiding this comment.
What is the purpose of a FullScreenButton with no setFullScreen handler?
There was a problem hiding this comment.
Eh there is no purpose? It provides a sense of aesthetic to the page??
This was set up but left unfinished, was focused on style & page elements
I added a working setFullScreen handler today
ciaranschutte
left a comment
There was a problem hiding this comment.
icons/barGraph and icons/fullScreen both exports are named FullScreen
doesn't error because it's a default export/import so can be named FunkyCocoLand with no breakage.
ciaranschutte
left a comment
There was a problem hiding this comment.
I think it's best to use a hook for theming.
the useTheme hook can be used in components as they're all under the theme provider component, this means you can remove them as args to a lot of functions and components.
Makes sense as well so we don't pass in something like white to a function which doesn't make sense to me when I read the function.
${getToggleButtonStyles({ active: isDemoData, accent, white })}
In the case of a function, this may mean you use a hook within a hook, which also works because they're built to be composable
| } from '@overture-stack/iobio-components/packages/iobio-react-components/'; | ||
| import { getToggleButtonStyles } from './tableUtils'; | ||
| const getActiveButtonStyles = (active: boolean, theme: Theme) => { |
There was a problem hiding this comment.
this can be object params, as most of our functions use object params and it's a good default because we don't blindly pass in things that don't work
| constgetActiveButtonStyles=(active: boolean,theme: Theme)=>{ | |
| constgetActiveButtonStyles=({active: boolean,theme: Theme})=>{ |
There was a problem hiding this comment.
Agreed, did a nice cleanup refactor of getButtonStyles/useTheme etc based on these comments
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
demariadaniel
commented
Jun 6, 2025
Naming is so hard, |


#65 Visualizer & File Table Buttons & CSS updates
Summary
Adds Visualizer & File Table Header navigation buttons with related CSS adjustments to match latest mockups
Issues
Description of Changes
Readiness Checklist
.env.schemafile and documented in the README