Items filtering in Sidebar #3585
-
Hello there! We at the One Admin team have been busy lately building the new shell for the One Admin project that will spread across the new React pages and the legacy Monkey pages, now wrapped by the One Admin layout. Such new layout implements the new Paste Sidebar plus a masthead wrapping a Topbar component including a UserDialog element. Everything works like a charm. However, and given the HUGE density of links across all different centers in One Admin, several customers have requested some kind of filtering options so they can easily access the links they're after, without having to dig into each section or subsection in the hierarchical sidebar. Therefore, we came up with the idea of introducing a filtering search box so customers could more easily find the links they're after by keyword filtering: small.movSome notes about the implementation:
This is currently a PoC that still needs to be censored by our product designers but we wanted to get some early feedback from the Paste team as well, and also address some questions:
Thanks and keep up the good work! 🚀 |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Hey @deeleman !
After some digging, it looks like the search event is non-standard according to MDN: https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/search_event , so your implementation may just be the way to go for now.
For any inputs that aren't search, we recommend using a Label instead of relying only on placeholder since the placeholder disappears when text is entered. The reason is that a search bar with the search icon is a widely used UI element across the internet that it can be understood without a label. Otherwise, the copy itself seems pretty clear.
The location of the search box seems logical since it's always visible, but if you can do any user testing on the entire interaction, that'd be even better.
Yep!
Without seeing the exact code, it's hard to say why you're experiencing the odd CSS behavior. Can you share a Codesandbox reproduction?
You can use the inverse variant of the Input:
We don't document it on our website because we haven't yet developed guidelines for our inverse components, but you can see an example in Storybook: https://paste-storybook.twilio.design/?path=/story/components-input--input-inverse Hope that helps! Let us know if you run into any other issues. |
Beta Was this translation helpful? Give feedback.
Hey @deeleman !
After some digging, it looks like the search event is non-standard according to MDN: https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/search_event , so your implementation may just be the way to go for now.
For any inputs that aren't search, we recommend using a Label instead of relying only on placeholder since the placeholder disappears when text is entered. The reason is that a search bar with the search icon is a widely used UI element…