HealthCatalyst / Fabric.Cashmere

Health Catalyst’s comprehensive design system.
http://cashmere.healthcatalyst.net
Apache License 2.0
66 stars 76 forks source link

Search function for site #1123

Closed cedar-ave closed 4 years ago

cedar-ave commented 4 years ago

I usually click around a fair amount to find what I'm looking for. Often it is not clear to me what is a "style" or a "component." For example I would think of a "logo" or "breadcrumbs" as components that make up the structure of the site, but they are considered styles. I'm know the Cashmere team surely has some clear delineations defined, but a search may be more helpful than expecting every user to learn and understand them. I do understand that search is possible in the GitHub interface. I am not a UI/UX or graphic designer, and I do understand that people in those roles are who the site is primarily for, so most users in those areas of expertise may inherently understand the delineations. I use the site a fair amount to make sure things I work on align with Cashmere standards or to pull resources off. Thanks for considering.

andrew-frueh commented 4 years ago

This is a great suggestion, @cedar-ave. The Cashmere site has grown a lot over the past year, and there's so much content now that search is probably something pretty important for us to be thinking about. I'm going to roll this into a larger conversation that @isaaclyman is leading about overhauling our documentation. We wanted to have a chat with you anyway about our approach - so that would be a perfect time to talk this through further.

andrew-frueh commented 4 years ago

Thanks again for bringing this up @cedar-ave. In conjunction with our documentation improvements, I'm bumping this up on the priority list.

joeskeen commented 4 years ago

I think we could index the documentation articles during the build and provide a search functionality based on that.

joeskeen commented 4 years ago

I found this library minisearch on NPM that looks promising. It even would allow us to build the index at build-time, export it, and load it when the user wants to search: https://lucaong.github.io/minisearch/MiniSearch.html#toJSON Of course, we would have to pass the files to a Markdown->Plaintext function like this before indexing them: https://github.com/stiang/remove-markdown I'd estimate the build-side of this would take 3-4 hours at most, UI end maybe a little longer to get the UX right.

andrew-frueh commented 4 years ago

Below is some additional design direction for this ticket. @corykon @cedar-ave @isaaclyman would love to hear any suggestions you'd have on the search experience. @joeskeen this workflow is almost identical to what you all implemented in Atlas last year. Maybe the Neumont team can use that as a reference?

Home Page In the banner of our homepage, I'd like to replace the "Get Started" button with a search field that will trigger a search on return. Bonus points if we can do typeahead in that field. I'd also like to adjust the top-right icons in the navbar so we have search available from the nav next to the GitHub link

Home

Navbar Search When search is trigger from the navbar, it immediately displays the top ~5 results, so the user can jump immediately to a page, or click the "show all results" button to go the full results page.

Home – Search

All Results The Show All Results button from the navbar search, or a return in the hompage search filed arrives here. In addition to a paginated list of all results, the user can filter the results using the left sidebar.

Home – Search Results

benjanderson commented 4 years ago

:tada: This issue has been resolved in version 8.0.0 :tada:

The release is available on:

Your semantic-release bot :package::rocket: