Skip to content
Recent and popular, light
Light
Recent and popular, dark
Dark

Every state

  • Recent and popular, default, light
    Recent and popular, default, dark

    default

  • Recent and popular, focus, light
    Recent and popular, focus, dark

    focus

  • Recent and popular, active, light
    Recent and popular, active, dark

    active

  • Recent and popular, removed, light
    Recent and popular, removed, dark

    removed

  • Recent and popular, typed, light
    Recent and popular, typed, dark

    typed

  • Recent and popular, no-recent, light
    Recent and popular, no-recent, dark

    no-recent

Props

PropTypeDefaultWhat it does
idstring"site-search"Id prefix; make it unique on the page.
labelstring"Search the shop"Accessible name of the field.
placeholderstring"Search the shop"Placeholder text.
actionstring"/search"Where the form goes on submit, with the text as `name`.
namestring"q"Form field name.
recentstring[]["cast-iron skillet", "oven gloves", "knife sharpener", "bread tin"]Your recent searches, newest first. Empty: the group is left out.
recentHeadingstring"Recent searches"Recent heading.
popularstring[]["dutch oven", "carbon-steel pan", "chef's knife", "linen tea towels", "stoneware mugs"]Searches many people make, most first. Empty: the group is left out.
popularHeadingstring"Popular right now"Popular heading.
onRemove(term: string) => void–Called with a recent search when it is removed.
onSearch(term: string) => void–Called with the text when a search is chosen or submitted. Left out: the form submits to `action`.
classNamestring–Extra classes on the outer element.

More search boxes

All 6
search-box-04 is in UI ProGet UI Pro, €199

Preview

Open the page
In UI Pro: get it, €199 once

With every block and theme. 400+ buyers since 2020. Plans