如何将汉堡包(抽屉)菜单与标题栏中的其他项目进行激烈对齐?所以,将汉堡菜单移动到绘制的红色条。
代码是:
<body>
<div class="mdl-layout mdl-js-layout mdl-layout--fixed-header">
<header class="mdl-layout__header">
<div class="mdl-layout__header-row">
<span class="mdl-layout-title">Acme</span>
<div class="mdl-layout-spacer"></div>
<nav class="mdl-navigation">
<a class="mdl-navigation__link" href="#">Home</a>
<a class="mdl-navigation__link" href="#">About</a>
<a class="mdl-navigation__link" href="#">Contact</a>
</nav>
</div>
</header>
<div id="mydrawer" class="mdl-layout__drawer">
<span class="mdl-layout-title">Acme</span>
<nav class="mdl-navigation">
<a class="mdl-navigation__link" href="#">Products</a>
<a class="mdl-navigation__link" href="#">Services</a>
<a class="mdl-navigation__link" href="#">Portfolios</a>
<a class="mdl-navigation__link" href="#">Achievements</a>
<a class="mdl-navigation__link" href="#">Blog</a>
</nav>
</div>
</body>
答案 0 :(得分:1)
答案在我的html页面的第一行。将下一行放在第&lt; html&gt; 标记之前:
<!doctype html>