0
私のdivは<i>
タグをラップするようにしようとしていますが、折り返しはしません。高さは常にdivの高さです。<i>
タグはパディングも余白もありません。多くのことしかし、私は私のスタイルとHTMLコードを追加してい動作しませんが、私はまた、いくつかのスクリーンショットHTML divはラップしません<i>タグ
CSS
<style>
.material-icons {
font-family: 'Material Icons';
font-weight: normal;
font-style: normal;
font-size: inherit;
display: inline-block;
line-height: 1;
text-transform: none;
letter-spacing: normal;
word-wrap: normal;
white-space: nowrap;
direction: ltr;
-webkit-font-smoothing: antialiased;
text-rendering: optimizeLegibility;
-moz-osx-font-smoothing: grayscale;
font-feature-settings: 'liga';
}
.button-content-ic {
display: inline-block;
margin: auto;
}
body, section, div {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
</style>
HTMLを追加するつもりです
の<div class="button-content-ic">
<i style="color: #fff;" class="material-icons">menu</i> </div>
スクリーンショット
タグ
ラッパータグ
事前にあなたの助けをありがとう。
イム申し訳ありませんが、私は投稿何の違いは何ですか? – kobbycoder
コードスニペットを実行しましたか?唯一違うのは、 '材料 - アイコン'に 'display:inline-block;'を代わりに 'display:block;'を使うことです。 – nstungcom
ありがとうございました。 – kobbycoder