What's the best way to align the hamburger menu to the left in Foundation CSS framework

My experience with SASS is still in its infancy, and I have encountered some issues. According to the documentation, I should make changes to _top-bar.scss by adding the line: $topbar-menu-icon-position: $default-float; (rather than $opposite-direction;).

However, this solution does not seem to be effective - the hamburger menu icon remains aligned to the right on mobile devices.

Although I believe the problem lies with the SASS code and not the HTML, here is the HTML code just in case:

<nav class="top-bar" data-topbar>
  <ul class="title-area">
    <li class="name">
      <h1><a href="#">Name</a></h1>
    </li>
    <li class="toggle-topbar menu-icon">
      <a href="#"><span>menu</span></a>
    </li>
  </ul>
  <section class="top-bar-section">
    <ul class="left">
      <li><a href="#">Link 1</a></li>
      <li><a href="#">Link 2</a></li>
      <li><a href="#">Link 3</a></li>
    </ul>
  </section>
</nav>

Answer №1

By visiting this link

You will find instructions on how to adjust the top bar position.

$topbar-menu-icon-position: $opposite-direction !default; // Change to $default-float for a left menu icon

To make the change, update it to:

$topbar-menu-icon-position: $default-float !default; 

I recommend making this adjustment in your local sass file instead of modifying the original, so you can easily update it in the future.

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

What is the best way to customize column width in AG-Grid?

I am looking for a way to dynamically set column width in my table. I have provided a stackblitz example which demonstrates that when changing the screen size, only the table border adjusts, but not the column widths. Is there a way to also change the col ...

Align the items in the Bootstrap navbar to the right using float

Can someone provide guidance on how to float navbar items to the right instead of the left? I have tried using the floats and float-right classes, but it seems that pull-right is deprecated. Any help would be greatly appreciated. <header class="conta ...

Overlap of Bootstrap Columns Occurs When Resizing the Browser

While I recognize that this issue is common, I have extensively reviewed similar questions but could not find a solution. <div class="container"> <div class="row"> <div class="col-xs-12 col-sm-12 col-md-6"> <img style="wi ...

pre-iframe loading function

Is it possible to capture the state of an iframe while data is loading? The onload event only fires once all content has finished loading. I would appreciate any assistance with this issue. Thank you. ...

Glitchy/Crazy CSS3 Animations

Currently, I am developing a website at . One of the features I have implemented is CSS3 transitions for route changes, but this feature only works in Chrome. Here's how the animation works: I apply the .preanimate class to rotate the phasing out di ...

Unable to interact with the submit button using Selenium

Hey there! I'm facing a bit of an issue with logging into using Selenium. I was able to successfully log in using the POST request method in BeautifulSoup, but now I need to switch to Selenium because I need to click on a button after login, which is ...

PHP receive apostrophe from $_GET array

Similar Question: “slash before every quote” issue Hello there, I am currently attempting to utilize $_GET in order to transmit the contents of a text box to another php file. However, whenever I include single (') or double (") quote ...

Modify the default navbar from Bootstrap to display as a fixed navbar

Is there a way to change my default navbar into a fixed navbar when I scroll? I have tried adding data-spy="affix" data-offset-top="200", which works but doesn't look quite right. Should I create a new CSS class or is there an easier solution availab ...

How can I address the issue of an inner content scroll bar?

I am facing an issue with the scroll bar on inner content. When I hover over an arrow on the inner content, the scroll bar appears as desired. However, it changes the content in a way that looks odd. Is there a solution to have a scroll bar on the inner co ...

What are the steps to display JSON data within an HTML div?

Struggling to display this JSON data within an HTML div [{ "botten": ["Crispy", "thin"] }, ] The HTML document's div has the class name box1_data. Below is my script: var crustInfo = document.getElementsByClassName("box1_data"); $.getJSON(' ...

Generating a dynamic list by utilizing database data once a button has been clicked

I'm looking to create a feature on my website where clicking on a button will populate a paragraph below it with data retrieved from a database query containing two columns. The first column provides the text for a list, while the second column contai ...

Styling radio buttons with CSS

I've been struggling to align my radio buttons next to their labels. Despite numerous changes to the CSS, I can't seem to get my text boxes, radio buttons, and comment box to line up properly. Specifically, the second radio button is causing alig ...

Challenges arise when using Bootstrap 4 for country selection

There have been reports that bootstrap 4 country select is not functioning properly. In an effort to troubleshoot, I delved into the documentation to find a solution. To make bootstrap-select compatible with bootstrap 4, refer to: Bootstrap 4 beta-2 ...

How to Change the Appearance of Elements in an Array Using React.js

My situation involves an array receiving data from an API, and I'm looking to customize each button's appearance by giving them different background colors. In addition, my project includes Material UI... Below is the snippet of code I have - {op ...

Guide to Modifying the Parameter Value in JMeter's "Http Request" for a checkbox with "title" text managing the state

In the HTML code, there is a checkbox element that initially has the title "Select all rows in this table": <input type="checkbox" class="form-checkbox" title="Select all rows in this table"> Upon inspection, the title ...

The leaflet map I created is not showing up on my website for some reason

I am currently working on a project using ReactJS and NextJS. One issue I am facing is that my leaflet map is not filling the entire parent div on my page, and it is not showing up at all. I had expected the map to automatically adjust to the parent div s ...

After the form is submitted on the current page, it will not submit again using jquery unless I refresh the page

Currently, I am attempting to submit my form on the same page utilizing jquery. However, after the initial submission, any further attempts fail. It seems that in order for the submission to work properly again, I need to refresh the page first. What cou ...

How can I use Vue.js @scroll to create a dynamic CSS property?

I am developing a vuejs component for my project and I am looking to implement a zoom functionality on scroll within a div, similar to Google Maps. <div @scroll="zoomOnScroll"> <Plotly :data="info" :layout="layout" :display-mode-bar="false"&g ...

Visibility of the br tag is not detected

I need to keep one specific div visible on the page while hiding all other content. However, I am facing an issue where the <br> tag inside that div is not showing up. <div id='min320'>min 320px<br>screen width required</div ...

"Vertical Line Encoding: A Strategy for Improved Data

Can someone help me with a coding issue I'm facing on my website? I am trying to create three vertical lines to separate images in columns, but every time I exit the editor and preview the site, the position of the lines changes. I'm new to HTML ...