-
Notifications
You must be signed in to change notification settings - Fork 29
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
Collapse duplicate rows when table is flattened #4735
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated our sorting fixture to have multiple branches:
main
with 5 commits and seven experiments under oneother-branch
with one commit and no experimentsanother-branch
with one commit and no experiments
@@ -183,46 +183,69 @@ describe('App', () => { | |||
await expectHeaders(['A', 'C', 'D', 'B']) | |||
}) | |||
|
|||
it('should add a "branch/tags" column if the table is sorted', () => { | |||
renderTable(sortedTableStateFixture) | |||
describe('Sorted (Flattened) Table', () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Grouped the "parents" column tests inside of a describe block.
> | ||
<div className={styles.cellContents}> | ||
<Icon icon={GitMerge} width={13} height={13} /> | ||
<ul |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could also use span
but chose ul
/li
for accessibility.
@julieg18 please rebase when you get a chance. I'll review afterwards. |
Done :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I took a quick look and I think the data structure could be improved a little bit. I'll do a real review at the start of the working week 🙏🏻.
} | ||
} = cell as unknown as CellContext<Experiment, CellValue> | ||
|
||
if (!branch) { | ||
if (flatBranches.length === 0) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Similar blocks of code found in 2 locations. Consider refactoring.
Deeply nested sorting story needs to be updated :) |
Code Climate has analyzed commit f819ec9 and detected 3 issues on this pull request. Here's the issue category breakdown:
The test coverage on the diff in this pull request is 100.0% (85% is the threshold). This pull request will bring the total coverage in the repository to 95.1%. View more on Code Climate. |
Demo
Screen.Recording.2023-09-28.at.12.24.37.PM.mov
Part of #4746