-
Notifications
You must be signed in to change notification settings - Fork 874
feat: add breadcrumbs to admin settings pages #15865
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
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.
@BrunoQuaresma the reason the breadcrumbs are not aligned is because it is dependent on the changes to the topbar navigation, #15617 Also I wanted to get approval because I am treating it as a standalone PR to make review easier and its dependent on #15388 |
1c6fe52
to
ac71d6c
Compare
e01b74b
to
5ede03c
Compare
<BreadcrumbItem> | ||
<BreadcrumbPage>Admin Settings</BreadcrumbPage> | ||
</BreadcrumbItem> | ||
<BreadcrumbSeparator /> |
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 feel like inserting the separator shouldn't be the responsibility of the consumer. The BreadcrumbList
could use Children.toArray
and intersperse them automatically, you could use some CSS tricks with :not(:first-of-kind)
or whatever, etc. There are other options that reduce the risk of misusage.
Also why are <Breadcrumb>
and <BreadcrumbList>
even separate components?
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 was originally thinking that the Breadcrumb should be more universal so that it could be used in places without the separator line underneath and this is how shadcn/ui does it as well. Of course, if the argument is that breadcrumbs for Coder will always have a separator line underneath, it could make sense.
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.
Having both and is a common pattern in the shadcn/ui components to add some semantic meaning. In general, I am not focused on altering or adding opinions to the way the components are constructed but always open to suggestions.
2e82bfb
to
5b428e4
Compare
resolves coder/internal#174
Uses shadcn/ui for admin settings breadcrumbs
Figma: https://www.figma.com/design/OR75XeUI0Z3ksqt1mHsNQw/Dashboard-v1?node-id=139-1380&m=dev