Move Currency Switcher from Footer to Top - Brooklyn Theme

Move Currency Switcher from Footer to Top – Brooklyn Theme

https://youtu.be/wWYpQqcCO9w

Find this link of code:

<input type="hidden" name="currency_code" id="CurrencySelector" value="{{ form.current_currency.iso_code }}" data-disclosure-input/>

Paste this code:

<li class="site-nav__item site-nav__item--compressed">
             
                  {%- form 'localization', class: selectors_form_class -%}
                    {%- if locale_selector -%}
                      <div class="selectors-form__item">
                        <h2 class="visually-hidden" id="lang-heading">
                          {{ 'general.language.dropdown_label' | t }}
                        </h2>

                        <div class="disclosure" data-disclosure-locale>
                          <button type="button" class="disclosure__toggle" aria-expanded="false" aria-controls="lang-list" aria-describedby="lang-heading" data-disclosure-toggle>
                            {{ form.current_locale.endonym_name }}
                          </button>
                          <ul id="lang-list" class="disclosure-list" data-disclosure-list>
                            {%- for locale in form.available_locales -%}
                              <li class="disclosure-list__item {% if locale.iso_code == form.current_locale.iso_code %}disclosure-list__item--current{% endif %}">
                                <a class="disclosure-list__option" href="#" lang="{{ locale.iso_code }}" {% if locale.iso_code == form.current_locale.iso_code %}aria-current="true"{% endif %} data-value="{{ locale.iso_code }}" data-disclosure-option>
                                  {{ locale.endonym_name }}
                                </a>
                              </li>
                            {%- endfor -%}
                          </ul>
                          <input type="hidden" name="locale_code" id="LocaleSelector" value="{{ form.current_locale.iso_code }}" data-disclosure-input/>
                        </div>
                      </div>
                    {%- endif -%}
        
        				<div class="doubly-wrapper custom-xvert"></div>  
        
                    {%- if currency_selector -%}
                      <div class="selectors-form__item">
                        <h2 class="visually-hidden" id="currency-heading">
                          {{ 'general.currency.dropdown_label' | t }}
                        </h2>

                        <div class="disclosure" data-disclosure-currency>
                          <button type="button" class="disclosure__toggle" aria-expanded="false" aria-controls="currency-list" aria-describedby="currency-heading" data-disclosure-toggle>
                            {{ form.current_currency.iso_code }} {%- if form.current_currency.symbol -%}{{ form.current_currency.symbol }}{%- endif -%}
                          </button>
                          <ul id="currency-list" class="disclosure-list" data-disclosure-list>
                            {%- for currency in form.available_currencies -%}
                              <li class="disclosure-list__item {% if currency.iso_code == form.current_currency.iso_code %}disclosure-list__item--current{% endif %}">
                                <a class="disclosure-list__option" href="#" {% if currency.iso_code == form.current_currency.iso_code %}aria-current="true"{% endif %} data-value="{{ currency.iso_code }}" data-disclosure-option>
                                  {{ currency.iso_code }} {%- if currency.symbol -%}{{ currency.symbol }}{%- endif -%}
                                </a>
                              </li>
                            {%- endfor -%}
                          </ul>
                          <input type="hidden" name="currency_code" id="CurrencySelector" value="{{ form.current_currency.iso_code }}" data-disclosure-input/>
                        </div>
                      </div>
                    {%- endif -%}
                  {%- endform -%}
                  
                </li>  

Leave a Reply