Changing the width of the search bar - Empire Theme

Changing the width of the search bar - Empire Theme

Charlotte93
Tourist
5 0 1

Hi,I would like to change the search bar to be smaller in width, I have tried to find the code for it but it doesn't seem to be there. We have the empire theme

 

Website:https://vauxcentre.co.uk/

Replies 4 (4)

ThePrimeWeb
Shopify Partner
2138 616 503

Hey @Charlotte93,

 

Go to your theme's "Edit Code" Option, then in the search bar type "theme.liquid"
Below the tag "<head>" tag paste the following. Screenshot attached for reference.

 

Change the 50% to any size you like

<style>
@media only screen and (min-width: 990px) {
    form.live-search-form.form-fields-inline {
        width: 50% !important;
        margin: auto !important;
    }
}
</style>

 

Screenshot is for reference only, the correct code to paste is the one shown above.

ThePrimeWeb_0-1710872823370.jpeg

 

Was I helpful?

Buy me a coffee

🙂

Need help with your store? contact@theprimeweb.com or check out the website
Check out our interview with Shopify!

PageFly-Richard
Shopify Partner
4668 1069 1726

 

Hi @Charlotte93 

 

This is Richard from PageFly - Shopify Page Builder App

 

Please add this code to your theme.liquid above the </head> to get this solved

Step 1: Online Stores > Themes > More Actions > Edit code

Step 2: click on theme.liquid and paste the code above the </head>

<style>
.live-search {
    max-width: 50%;
    margin: 0 auto;
}
</style>

PageFlyRichard_0-1710898284166.png

 

Hope this can help you solve the issue 

 

Best regards,

Richard | PageFly

Please let me know if it works by giving it a Like or marking it as a solution!


➜ Optimize your Shopify store with PageFly Page Builder (Free plan available) 


All features are available from Free plan. Live Chat Support is available 24/7.

Charlotte93
Tourist
5 0 1

Hi Richard,

 

Thank you for this! It changed it on the web, however it changed on the mobile as well when I am happy with how it looks on the mobile. Is there anyway of just changing it on the web and not the mobile too?

 

Thank you!

Raj-webdesigner
Shopify Partner
345 85 82
.ui-menu.glFilter-search-popup .gl-fullscreen-layer .gl-d-close-btn{
    width: 30px;
    height: 30px;
    flex: unset;
    padding: unset;
}
.ui-menu.glFilter-search-popup .gl-fullscreen-layer .gl-d-searchbox-input{
    font-size: 18px;
}
.ui-menu.glFilter-search-popup .gl-fullscreen-layer .gl-d-searchbox-icon{
    width: 50px;
    height: 50px;
}
.ui-menu.glFilter-search-popup .gl-fullscreen-layer .gl-fullscreen-header {
    width: 50%;
    margin: 0 auto;
}

Add This Css In Your base.css file and see Magic 

 

Are you looking for Shopify Developer then your search is over I will help you


If you require further help to optimize your store, please don’t hesitate to reach out.


This contribution will always benefit you and you will get my full help easily and you can contact me easily.


Your Willpower Contribution Link

:-

❤️Tip❤️

Contect On My Mail :-Mail@gmail.com