Open kshitjj opened 1 month ago
@ovflowd can we use an arrow icon as content for the buttons?
I'd say so? But we could use arrow-left-end-on-rectangle
and arrow-right-end-on-rectangle
from https://heroicons.com/
@ovflowd This feature to minimize the sidebar requires client-side interactivity due to that reason we have to introduce a state to control whether the sidebar is minimized. Can I use "use client" in LearnLayout? I will then add a new class in ArticleLayout based on this state to control the grid widths.
Hmmm, wouldn't add an use client on the Metabar and the Sidebar components be enough? 👀
I'm also curious how this effort may relate to https://github.com/nodejs/nodejs.org/pull/6821
I'm actually curious to see where the state control buttons will be placed (in both open and closed states) without appearing clunky or crowding the header as we are not moving the sidebars up in z axis here and the sidebar state affects the width occupied by the article.
I believe, as @abizek, the best approach would be for #6821 to be the default behavior. And then the feature described on this issue only works on non-mobile screens.
And if you hide the meta bar/sidebar, well, on mobile screens, they become respectively on the bottom of the article and the select button.
Enter your suggestions in details:
What is the problem this feature will solve?
the sidebars are not minimizable, which causes the body to have less width, which cramps the body.
What is the feature you are proposing to solve the problem?
adding two buttons, which would allow a dev to minimize the sidebars.