Add form field title for a11y (#542)

* Add input title to improve a11y

Resolves pa11y error:

```
 • Error: This form field should be labelled in some way. Use the label element (either with a "for" attribute or wrapped around the form field), or "title", "aria-label" or "aria-labelledby" attributes as appropriate.
   ├── WCAG2AA.Principle1.Guideline1_3.1_3_1.F68
   ├── #search_input_react
   └── <input type="text" id="search_input_react" placeholder="Search" aria-label="Search" class="aa-input" autocomplete="off" spellcheck="false" role="combobox" aria-autocomplete="list" aria-expanded="false" aria-labelledby="search_input_react" aria-owns="...
```

* Fix Prettier failure on Circle CI
This commit is contained in:
Amy Lam 2018-04-10 08:46:08 -07:00 committed by Joel Marcey
parent 71317e49ba
commit 80ece69a10

View file

@ -107,7 +107,12 @@ class HeaderNav extends React.Component {
// return algolia search bar
return (
<li className="navSearchWrapper reactNavSearchWrapper" key="search">
<input id="search_input_react" type="text" placeholder="Search" />
<input
id="search_input_react"
type="text"
placeholder="Search"
title="Search"
/>
</li>
);
} else if (link.languages) {