Skip to content

Instantly share code, notes, and snippets.

@carolineschnapp
Created February 16, 2016 19:22
Show Gist options
  • Save carolineschnapp/5b7a23570eb4228c51da to your computer and use it in GitHub Desktop.
Save carolineschnapp/5b7a23570eb4228c51da to your computer and use it in GitHub Desktop.
Have search box open by default in #Venture

What you have

Alt text

What you want

Alt text

How to get it

Open your theme.liquid file in the online code editor, go to line no 61 and add the class site-header__search-input--visible to the search box input, like so:

<input type="search" name="q" id="SiteNavSearch" placeholder="{{ 'general.search.placeholder' | t }}" aria-label="{{ 'general.search.placeholder' | t }}" class="site-header__search-input site-header__search-input--visible">

You'll need to scroll to the right, it's a long line of code:

Alt text

@hstassens
Copy link

hstassens commented Aug 25, 2016

This does work but if you click outside of the search box it will disappear again because the "hide" script hasn't been disabled. To disable this, you need to also access the theme.js.liquid file and comment out (or delete) the .removeClass script as shown:

venture-search-function

Hopefully this might help.

@vivekmaishe0808
Copy link

still my seacrh bar is not visible

@vivekmaishe0808
Copy link

its getting hided after going in next page

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment