Header dropdown menu position is not relevant to the Header button #84
-
I already discussed this with @veekeys , and it seems that it needs js to position the menu to be responsive. But I was wondering for header we can have special case without needing a js to position the menu as header is stationary at the top of the UI. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Not sure I understand the problem here. If you're talking about the React implementation, Header button relies on our DropdownMenu component, which is implemented using JS. Sure it's a simple case that could be done with pure CSS, but we want to reuse our existing components wherever possible. You are not forced to use JS in your implementation (we don't have any JS in the base CSS package). So you could write your own rules/markup for handling the menu. Using |
Beta Was this translation helpful? Give feedback.
Not sure I understand the problem here.
If you're talking about the React implementation, Header button relies on our DropdownMenu component, which is implemented using JS. Sure it's a simple case that could be done with pure CSS, but we want to reuse our existing components wherever possible.
You are not forced to use JS in your implementation (we don't have any JS in the base CSS package). So you could write your own rules/markup for handling the menu. Using
:focus-within
is one approach of doing it.