Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Grid with hideHeaders:true omits extraneous header border #3435

Merged
merged 5 commits into from
Aug 3, 2023

Conversation

Ryanseanlee
Copy link
Contributor

@Ryanseanlee Ryanseanlee commented Aug 1, 2023

Hoist P/R Checklist

Pull request authors: Review and check off the below. Items that do not apply can also be
checked off to indicate they have been considered. If unclear if a step is relevant, please leave
unchecked and note in comments.

  • Caught up with develop branch as of last change.
  • Added CHANGELOG entry, or determined not required.
  • Reviewed for breaking changes, added breaking-change label + CHANGELOG if so.
  • Updated doc comments / prop-types, or determined not required.
  • Reviewed and tested on Mobile, or determined not required.
  • Created Toolbox branch / PR, or determined not required.

If your change is still a WIP, please use the "Create draft pull request" option in the split
button below to indicate it is not ready yet for a final review.

Pull request reviewers: when merging this P/R, please consider using a squash commit to
collapse multiple intermediate commits into a single commit representing the overall feature
change. This helps keep the commit log clean and easy to scan across releases. PRs containing a
single commit should be rebased when possible.

@Ryanseanlee Ryanseanlee requested a review from jskupsik August 1, 2023 23:57
@Ryanseanlee Ryanseanlee linked an issue Aug 2, 2023 that may be closed by this pull request
Copy link
Member

@amcclain amcclain left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for looking at this - one comment + one question below - let's get it merged in today.

@@ -78,7 +86,8 @@ export const [AgGrid, agGrid] = hoistCmp.withFactory<AgGridProps>({
stripeRows ? 'xh-ag-grid--stripe-rows' : 'xh-ag-grid--no-stripe-rows',
cellBorders ? 'xh-ag-grid--cell-borders' : 'xh-ag-grid--no-cell-borders',
showCellFocus ? 'xh-ag-grid--show-cell-focus' : 'xh-ag-grid--no-cell-focus',
isDesktop && showHover ? 'xh-ag-grid--show-hover' : 'xh-ag-grid--no-hover'
isDesktop && showHover ? 'xh-ag-grid--show-hover' : 'xh-ag-grid--no-hover',
hideHeaders ? 'xh-grid-header--hidden' : null
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like xh-ag-grid--hide-headers would be a more consistent with the other classnames here. Agreed we don't need a class for the default "not hidden" case.

cmp/grid/Grid.scss Outdated Show resolved Hide resolved
@amcclain
Copy link
Member

amcclain commented Aug 3, 2023

Thanks - let's look together today - right now this is placing an xh-grid-header-- class on the grid itself, which is a bit weird. If we're placing the class on the grid element I would expect it to be an xh-ag-grid-- class like the others. We could then key off of that in an .xh-ag-grid--hide-headers .xh-grid-header override. Or we could look to put the class on the header element itself, in which case we could have it be something like xh-grid-header--hidden - we would just need to see if we can easily check the flag when we are rendering the header.

@amcclain amcclain changed the title Add css class to suppress border from showing when hideHeader is true Grid with hideHeaders:true omits extraneous header border Aug 3, 2023
@amcclain amcclain merged commit f658282 into develop Aug 3, 2023
@amcclain amcclain deleted the headerBorderVisibleWithhideHeadersTrueFix branch August 3, 2023 17:57
leogretz2 pushed a commit that referenced this pull request Aug 4, 2023
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.

Grid with hideHeaders: true still renders header border
2 participants