-
Notifications
You must be signed in to change notification settings - Fork 11
Conversation
…an fix in the metadata of each site)
* master: 0.10.0 fix prerelease order in sortVersion helper function (#124)
@colleenmcginnis this is ready for review! Note: search doesn't appear at all in IE11: I haven't pinpointed the exact point of failure, but I feel ok with punting on getting the search to work in IE11 since it gracefully degrades (to no search) and doesn't break the layout. |
## Master | ||
|
||
- Add `Search` component | ||
- 🚨 [Breaking change] Remove `txt-bold` and `txt-s` from `LevelIndicator` component to make it more flexible. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡When we update dr-ui in other repos using LevelIndicator
we'll want to wrap the component in a span or div with these classes where needed.
src/components/search/search-box.js
Outdated
</ul> | ||
) : ( | ||
<div className="py12 px12"> | ||
Sorry, we didn't find anything. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copy suggestions welcome!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤔 @HeyStenson any thoughts here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe something like: Hmmm, we didn't find anything. Reword your search, or contact Support.
(with a link to the support page).
❓❓❓
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I love that @HeyStenson! I'll add it 🙇♀
@@ -0,0 +1,90 @@ | |||
import React from 'react'; | |||
import PropTypes from 'prop-types'; | |||
import Downshift from 'downshift'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡Downshift makes our search input and and results navigable by keyboard!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ooooooo!
)} | ||
{subsite && subsite !== title && subsite !== site ? ( | ||
<span> | ||
{subsite.replace(/\sfor\s(iOS|Android|Vision)/, '')} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡This temporarily removes the "for Android" (or iOS or Vision) from the subsite name. We should eventually update the docs-page-shell to strip this out but this will fix it on the frontend to give us cleaner looking results.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@katydecorah this is a work of art.
I think there may be some design considerations we'll need to revisit when we roll this out to the wider collection of docs repos (for example, the width available in top bar when we have a few tabs), but I think this iteration is ready to test on the help page!!
This PR works to add a new Search component that will add an input hooked up to Swiftype. Results are displayed in a popover under the input.
To test:
The test has two examples - basic search and in context of where I think it could go on each site (on the right-end of the top bar sticker).
QA Checklist
Responsive
Cross-browser