[Web] Add List View to Unified Resources#34203
Conversation
|
The PR changelog entry failed validation: Changelog entry not found in the PR body. Please add a "no-changelog" label to the PR, or changelog lines starting with |
|
The PR changelog entry failed validation: Changelog entry not found in the PR body. Please add a "no-changelog" label to the PR, or changelog lines starting with |
a4d084a to
cc41cb6
Compare
|
The PR changelog entry failed validation: Changelog entry not found in the PR body. Please add a "no-changelog" label to the PR, or changelog lines starting with |
cc41cb6 to
900f096
Compare
|
Something is causing the the horizontal scrollbar blinking (Firefox): horizontal.scroll.mov |
|
What do you think about putting a tooltip over the labels icon that says "Show Labels" (similar to how we show the "Click to Copy" tooltip on the copy button)? |
900f096 to
c8129a3
Compare
@gzdunek Good catch, looks like this was being caused because the |
|
This looks/works great. My only concern is leaving out the user preferences part because until that goes in, a user who would want this view would have to click the list view button every time they load the page (could lead to more frustration than not having it at all). Lets pair up and bust it out real quick to squeeze it into this PR? |
e54aa45 to
baef29c
Compare
a762d03 to
d0bc2d6
Compare
| const selectViewMode = (viewMode: UnifiedViewModePreference) => { | ||
| updateUnifiedResourcesPreferences({ | ||
| ...unifiedResourcePreferences, | ||
| viewMode, | ||
| }); |
There was a problem hiding this comment.
This is great 👏
However, now we have some inconsistency: viewMode state is kept outside, but information if pinned tab is active is kept in params and sent externally via updateUnifiedResourcesPreferences.
It seems to me that it would be good to have a single way of updating both properties. I made an attempt to refactor this, you can check out the draft #34394.
It's not perfect, but we should refactor useUrlFiltering first.
I also improved naming and fixed imports (shared and teleterm shouldn't import from teleport).
There was a problem hiding this comment.
Agreed, though I think we should do the refactoring after this is merged since this PR is already large enough and this doesn't affect UX.
gzdunek
left a comment
There was a problem hiding this comment.
I left two small comments.
🚢 it!
4388f04 to
af5e440
Compare
9ac71a7 to
d0b42dc
Compare
d0b42dc to
21d6550
Compare
Purpose
Adds a list view option to the Unified Resources page as an alternative to the card view.
Also changes the hover state for the card view to use a shadow.
ecounterpart: https://github.com/gravitational/teleport.e/pull/2619Figma design
Demo
TODO:
changelog: Add list view to resources page