Xzya / hugo-bootstrap

This is a simple Hugo theme using Bootstrap v4.
MIT License
76 stars 51 forks source link

[to change the font color and size] #22

Open svcuong opened 5 years ago

svcuong commented 5 years ago

I started to use the hugo-bootstrap theme to create personal website and I like it so much. However, I am quite confused how I could change the font color and size. I know this question will sound stupid but just failed in getting solutions after a couple of hours' searching. Thanks in advance if you could give some ideas.

Xzya commented 5 years ago

Hello,

There are several ways to do this:

For example:

static/css/custom-styles.css

.blog-post > a {
    color: green;
    font-size: 1.25rem;
}

layouts/partials/head-custom.html

<link href="{{ .Site.BaseURL }}css/custom-styles.css" rel="stylesheet">

The above would increase the font of the "Read More →" link and make it green.

Keep in mind that some elements might be harder to target if they don't have custom classes set to them, but you can always override any of the theme's layout files and include your own classes to make it easier.

Let me know if this works for you, Thanks!