首页 > 解决方案 > 如何在 Jumbotron Bootstrap 3 中更改字体粗细

问题描述

如何更改中的.jumbotron和段落的字体粗细.jumbotron?我不要我的font-weight那么大。

HTML:

<header>
    <div class="container-fluid landing-page">
        <div class="jumbotron vertical-center">
            <h1>Embroider<span class="eze">eze</span></h1>
            <p>Branding <span class="eze">&#9679;</span> Promotional Items <span class="eze">&#9679;</span> Reflective Tape <span class="eze">&#9679;</span> Gifts</p>
        </div>
    </div>
</header>

CSS:

.jumbotron {
    color: #dbdbdb;
    background-color: transparent;
    text-align: center;
    margin-top: 300px;
    font-weight: 200;
}

此外,字体大小更改不起作用。

标签: csstwitter-bootstraptwitter-bootstrap-3

解决方案


默认情况下,bootstrap 有一些 h1 和 P 的样式。如果你想覆盖,试试这个

.jumbotron h1{

font-weight: 800;

}

.jumbotron p{

font-weight: 800;

}

推荐阅读