algolia / docsearch

:blue_book: The easiest way to add search to your documentation.
https://docsearch.algolia.com
MIT License
3.87k stars 374 forks source link

Allow custom placeholder #2232

Closed arno-fukuda closed 2 months ago

arno-fukuda commented 2 months ago

Currently placeholder prop allows to customize the search placeholder of the modal only.

We want to customize the placeholder of the search input component on our navbar.

It's currently hardcoded to "Search".

https://github.com/algolia/docsearch/blob/6462d11826eea334e2fad1738d396571ea158035/packages/docsearch-react/src/DocSearchButton.tsx#L26

For my Japanese site, I would like to conditionally use "検索" as an example.