How to leave side filter blocks closed

Romas_elc
Tourist
4 0 1

Hello, community I have a question. How to leave side filter blocks closed by page open or refresh. (See video). Now it is always opened. There is a custom-used code for side filter.  And there is my website www.el-c.eu

 {% assign price= 5 %}
             <div class="range-slider">
                <input class="range-slider__range" name="price" type="range" value="{{ price }}" min="5" max="100" step="1">
                <span class="range-slider__value">€{{ price }}</span>
              </div> {% comment %}
                 <div class="price_con">
                 <input type="text" placeholder="Min">
                <i class="fa fa-minus" aria-hidden="true"></i>
                 <input type="text" placeholder="Max">
              </div>
              <div id="slider-range"></div>
            {% endcomment %}
            </div>
          </div>
         {% if collection.handle == "vendors" %}
         {% else %}
         <div class="set">
            <a href="#" class="active">
             {{ 'collections.general.color' | t }}
              <i class="fa fa-angle-up"></i>
            </a>
            <div class="content">
              <div class="inner_div">
               
                {% for block in section.blocks %}
                {% if block.type == "color" %}
                {% assign swatch_name = block.settings.title | append: '.jpg' %}
                {% assign swatch_img = images[swatch_name] %}
                {% assign products_count = 0 %}
                  {% for product in collection.products %}
{% for t in product.tags %}
              {% if t == block.settings.title %}
                  {% assign products_count = products_count | plus: 1 %}
                  {% endif %}
                {% endfor %}
                  {% endfor %}
               {% if products_count > 0 %}
                
                <div data-img ={{ swatch_img }} data-name={{ swatch_name }} class="radio_div color" style="background-color:{{ block.settings.title }}; {% if swatch_img != blank %} background-image: url({{ swatch_img | img_url: '64x64' }}); {% endif %}">
                  <input class="coll-filter" type="checkbox" name="{{ block.type }}" value="{{ block.settings.title }}" title="{{ block.settings.title }}" {% if current_tags contains block.settings.title %} checked {% endif %}>
                  <div class="title_radio"></div>
                  <p>({{ products_count }})</p>
                  </div>
                {% endif %}
                {% endif %}
                {% endfor %}
                
Reply 1 (1)

KetanKumar
Shopify Partner
36843 3636 11978

@Romas_elc 

sorry for that issue can you please try this code

1. Go to Online Store->Theme->Edit code
2. Asset->/theme.scss.liquid->paste below code at the bottom of the file.

.main_collection .filter_div {display: none;}
.main_collection .product_div {width: 100%;}

 

If helpful then please Like and Accept Solution.
Want to modify or custom changes on store Hire me.
- Feel free to contact me on bamaniyaketan.sky@gmail.com regarding any help
Shopify Partner | Skype : bamaniya.sky
PSD to Shopify | Shopify Design Changes | Shopify Custom Theme Development and Desing | Custom Modifications In to Shopify Theme | SEO & Digital Marketing