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

[Feature Request] "rail icon" variant for SideNav #15109

Open
2 tasks done
Tracked by #16296
Tomahaawk opened this issue Nov 6, 2023 · 9 comments
Open
2 tasks done
Tracked by #16296

[Feature Request] "rail icon" variant for SideNav #15109

Tomahaawk opened this issue Nov 6, 2023 · 9 comments
Labels
component: ui-shell proposal: open This request has gone through triaging. We're determining whether we take this on or not. role: design ✏️ role: dev 🤖 type: enhancement 💡

Comments

@Tomahaawk
Copy link
Contributor

Package

@carbon/react

Browser

Chrome, Firefox

Package version

1.40.0

React version

16.13

Description

When zooming over 175% on my browser or settign the view width to < 1056px the SideNav becomes unclickable when collapsed. I'm using the SideNav as a controlled component but if I use it with the isRail prop it works as expected.

Reproduction/example

https://stackblitz.com/edit/github-ked8wj?file=src%2FApp.jsx

Steps to reproduce

1 - Set the browser width to < 1056px or zoom in the page.
2 - Close the SideNav with the toggle button.

Expected result: User should be able to open the SideNav again.
Actual result: User cannot click on the SideNav.

Suggested Severity

Severity 3 = User can complete task, and/or has a workaround within the user experience of a given component.

Application/PAL

IBM RPA

Code of Conduct

@alisonjoseph
Copy link
Member

Hi @Tomahaawk this appears to be working as intended as the inert property is being added here

I would recommend placing the toggle button outside of the SideNav component, if this doesn't work could you provide more details around your use-case? Thanks!

@Tomahaawk
Copy link
Contributor Author

@alisonjoseph the issue is not related to the toggle button. I updated the demo.

https://stackblitz.com/edit/github-ked8wj

If you open the sandbox and make the screen smaller, you will notice that you cannot interact with the side nav after the size I mentioned on the description.

I recorded a video of the issue happening.
https://github.com/carbon-design-system/carbon/assets/12561157/845a690f-1aa4-4556-94e6-edf597ab52f0

@alisonjoseph
Copy link
Member

Thanks for the additional context, I see what you're saying now.

@riddhybansal lets pair up next week on this, we may be able to just remove the isLg check on the inert prop, but will need to test the ramifications.

@alisonjoseph
Copy link
Member

@Tomahaawk I was looking closer at this issue with @riddhybansal this morning and we think this is working as intended.

Just to clarify, you want to be able to click on an item in the side nav when it is in the collapsed state? This isn't currently supported within the component. Can you provide more details around your use-case here so we can discuss with design on whether this is an enhancement we would want to add?

@Tomahaawk
Copy link
Contributor Author

@alisonjoseph Our implementation is based on IDENavigation from Cloud PAL (which seems to be broken right now). We used their component at the begining and later on we replaced it with the Carbon implementation.

This is how our menu looks like:
image
image

We have a button at the bottom that collapses and expand the menu. Pretty much like the sandbox.
We would like to keep the menu on the side when on smaller screens, so the user can at least click on the icons to navigate around.

@alisonjoseph
Copy link
Member

Thanks @Tomahaawk, it looks like you're asking for an isRail option for sidenav that does NOT open/close on hover by default, and instead allows the user to interact with the sidenav rail while it is collapsed.

@carbon-design-system/design fyi

@Tomahaawk
Copy link
Contributor Author

Yes @alisonjoseph, that sums it up

@alisonjoseph alisonjoseph changed the title [Bug]: Cannot interact with SideNav when viewport is < 1056px isRail variant for SideNav May 29, 2024
@alisonjoseph alisonjoseph changed the title isRail variant for SideNav [Feature Request] isRail variant for SideNav May 29, 2024
@alisonjoseph alisonjoseph changed the title [Feature Request] isRail variant for SideNav [Feature Request] "rail" variant for SideNav May 29, 2024
@alisonjoseph alisonjoseph changed the title [Feature Request] "rail" variant for SideNav [Feature Request] "rail icon" variant for SideNav May 29, 2024
@CalvinThai
Copy link

any update on this?
image
same issue here, when the width of the window is small the isRail attribute gets added and the buttons aren't able to be clicked

@sstrubberg sstrubberg added the proposal: open This request has gone through triaging. We're determining whether we take this on or not. label Jul 8, 2024
@alisonjoseph
Copy link
Member

Hi, the Carbon team discussed this today, and while we may consider this enhancement in the future, it will require additional design and accessibility research. Unfortunately, it’s not something that we are able to prioritize in our immediate backlog.

For now, we recommend building a custom SideNav component to achieve this functionality.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: ui-shell proposal: open This request has gone through triaging. We're determining whether we take this on or not. role: design ✏️ role: dev 🤖 type: enhancement 💡
Projects
Status: Later 🧊
Development

No branches or pull requests

5 participants