Skip to content

Instantly share code, notes, and snippets.

@gunnarbittersmann
Last active August 29, 2015 14:20
Show Gist options
  • Select an option

  • Save gunnarbittersmann/7be3cdff57298af6ee74 to your computer and use it in GitHub Desktop.

Select an option

Save gunnarbittersmann/7be3cdff57298af6ee74 to your computer and use it in GitHub Desktop.
flexbox menu 1
/**
* flexbox menu 1
* http://forum.selfhtml.org/self/2015/apr/27/menue-horizontal-ausrichten/1638793#m1638793
*/
html
{
padding: 0;
background: hsl(240, 60%, 4%);
font: bold 1em/1.2 Helvetica, sans-serif;
color: hsl(30, 40%, 80%);
}
body
{
margin: 0;
padding: 0;
}
nav ul
{
display: flex;
flex-wrap: wrap;
justify-content: space-around;
list-style: none;
margin: 0;
padding: 0;
background: hsl(220, 60%, 16%);
}
nav li
{
margin: 0;
white-space: nowrap;
}
nav a {
display: block;
color: inherit;
padding: 0.5em;
}
<nav>
<ul>
<li><a>Star Trek</a></li>
<li><a>The Next Generation</a></li>
<li><a>Deep Space Nine</a></li>
<li><a>Voyager</a></li>
<li><a>Enterprise</a></li>
</ul>
</nav>
// alert('Hello world!');
{"view":"split-vertical","fontsize":"100","seethrough":"","prefixfree":"1","page":"css"}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment