123

Pen Settings

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

You're using npm packages, so we've auto-selected Babel for you here, which we require to process imports and make it all work. If you need to use a different JavaScript preprocessor, remove the packages in the npm tab.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Use npm Packages

We can make npm packages available for you to use in your JavaScript. We use webpack to prepare them and make them available to import. We'll also process your JavaScript with Babel.

⚠️ This feature can only be used by logged in users.

Code Indentation

     

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

HTML Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.

            
              <!-- This demo uses float grid but you can use flex grid too -->

<div class="row">
  <div class="columns">
    <h2>Vertical Dropdown Menu</h2>
    <p><strong>Set up:</strong> Dropdown menus build on the <a href="foundation.zurb.com/sites/docs/">Menu</a> component's syntax. Add the class <code>.dropdown</code> and the attribute <code>data-dropdown-menu</code> to the menu container to set up the dropdown.</p>
    <p><strong>Activate:</strong> To create dropdown menus, nest a new <code>&lt;ul&gt;</code> inside an <code>&lt;li&gt;</code>. You can nest further to create more levels of dropdowns.</p>
    <p><strong>Vertical:</strong> Add the <code>.vertical</code> class to the top-level menu to make it vertical. Sub-menus are automatically vertical, regardless of the orientation of the top-level menu.</p>
    <div class="primary callout">
      <p>Menus are block-level elements, which means they stretch to fill the width of their container. To make the below example less goofy, we've hard-coded a <code>max-width</code> on the menu.</p>
    </div>
  </div>
</div>

<div class="row">
  <div class="columns">
    <ul class="vertical dropdown menu" data-dropdown-menu style="max-width: 250px;">
      <li>
        <a href="#Item-1">Item 1</a>
        <ul class="menu">
          <li><a href="#Item-1A">Item 1A</a></li>
          <li>
            <a href="#Item-1B">Item 1B</a>
            <ul class="menu">
              <li><a href="#Item-1Bi">Item 1B i</a></li>
              <li><a href="#Item-1Bii">Item 1B ii</a></li>
              <li>
                <a href="#Item-1Biii">Item 1B iii</a>
                <ul class="menu">
                  <li><a href="#Item-1Biiialpha">Item 1B iii alpha</a></li>
                  <li><a href="#Item-1Biiiomega">Item 1B iii omega</a></li>
                </ul>
              </li>
              <li>
                <a href="#Item-1Biv">Item 1B iv</a>
                <ul class="menu">
                  <li><a href="#Item-1Bivalpha">Item 1B iv alpha</a></li>
                </ul>
              </li>
            </ul>
          </li>
          <li><a href="#Item-1C">Item 1C</a></li>
        </ul>
      </li>
      <li>
        <a href="#Item-2">Item 2</a>
        <ul class="menu">
          <li><a href="#Item-2A">Item 2A</a></li>
          <li><a href="#Item-2B">Item 2B</a></li>
        </ul>
      </li>
      <li><a href="#Item-3">Item 3</a></li>
      <li><a href="#Item-4">Item 4</a></li>
    </ul>
  </div>
</div>



            
          
!
            
              /* Demo Styles */

body {
  padding: 2rem 1rem;
}
            
          
!
            
              $(document).foundation();
            
          
!
999px
🕑 One or more of the npm packages you are using needs to be built. You're the first person to ever need it! We're building it right now and your preview will start updating again when it's ready.

Console