-
Notifications
You must be signed in to change notification settings - Fork 237
feat(databases-collections-list): replace the database and collection cards with tables COMPASS-9585 COMPASS-9586 #7399
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
base: main
Are you sure you want to change the base?
Conversation
a170d7f
to
ba9091a
Compare
: '-'; | ||
}, | ||
}, | ||
/* |
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 initially wanted to display this because it would make all sizes explicit, but the table quickly gets crowded.
: '-'; | ||
}, | ||
}, | ||
/* |
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 initially wanted to display this because it would make all sizes explicit, but the table quickly gets crowded.
477d800
to
3f36c86
Compare
…tual rendering isn't working. rely on e2e tests.
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.
Pull Request Overview
This PR replaces database and collection cards with tables as part of COMPASS-9585 and COMPASS-9586. The change transitions from a grid-based card layout to a table-based interface for displaying databases and collections.
- Removes grid view components and implements table-based displays
- Updates e2e tests to work with new table selectors and structure
- Consolidates functionality into ItemsTable component with column-based data display
Reviewed Changes
Copilot reviewed 17 out of 17 changed files in this pull request and generated 3 comments.
Show a summary per file
File | Description |
---|---|
packages/databases-collections-list/src/use-view-type.tsx | Removes view type toggle functionality (grid/list views) |
packages/databases-collections-list/src/namespace-param.tsx | Removes parameter display component used in cards |
packages/databases-collections-list/src/namespace-card.tsx | Removes card-based display component |
packages/databases-collections-list/src/items-table.tsx | Adds new table-based component for displaying items |
packages/databases-collections-list/src/items-grid.tsx | Removes grid-based display component |
packages/databases-collections-list/src/index.spec.tsx | Removes old test suite for card-based components |
packages/databases-collections-list/src/databases.tsx | Converts databases display to use table columns instead of cards |
packages/databases-collections-list/src/collections.tsx | Converts collections display to use table columns instead of cards |
packages/compass-e2e-tests/tests/instance-databases-tab.test.ts | Updates test selectors from card to row references |
packages/compass-e2e-tests/tests/in-use-encryption.test.ts | Updates collection selectors for table-based display |
packages/compass-e2e-tests/tests/database-collections-tab.test.ts | Updates collection test selectors and interactions |
packages/compass-e2e-tests/package.json | Updates test command flags from --bail to --mocha-bail |
packages/compass-e2e-tests/index.ts | Adds bail handling for test cleanup |
packages/compass-e2e-tests/helpers/selectors.ts | Updates selectors from card-based to row-based for tables |
packages/compass-e2e-tests/helpers/commands/scroll-to-virtual-item.ts | Updates virtual scrolling for table structure |
packages/compass-e2e-tests/helpers/commands/database-workspaces.ts | Updates navigation to use row selector |
packages/compass-components/src/components/leafygreen.tsx | Exports additional table-related components |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
packages/compass-e2e-tests/helpers/commands/scroll-to-virtual-item.ts
Outdated
Show resolved
Hide resolved
f75b478
to
589d5be
Compare
}); | ||
|
||
describe('with loaded collections', function () { | ||
// TODO |
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.
The table isn't rendering any rows in unit tests, so I haven't bothered trying to port these as the tests won't work until I find a workaround anyway.
}); | ||
|
||
describe('with loaded databases', function () { | ||
// TODO |
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.
ditto.
e9d16ee
to
5eda9b0
Compare
a892ba1
to
1885ff9
Compare
// real harm in trying to scroll beyond the end - it will either have found | ||
// the item already and exited the loop or worst case it will attempt to | ||
// scroll one more time and then still not find the item. | ||
totalHeight += scrollHeight; |
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.
If this works then I can change the table height calculator to just add the height of the sticky header. Or whatever it is that's about two/three row heights causing this thing to stop before the end.
evergreen retry |
This replaced the databases and collection cards with tables.
Plan:
Derived from {collection_name}
(including dark mode)