dsrkafuu / hugo-theme-fuji

A minimal Hugo theme with nice theme color. | 一个主题色极简 Hugo 主题。
https://github.dsrkafuu.net/hugo-theme-fuji/
Apache License 2.0
366 stars 97 forks source link

How to change the background colour and font? #11

Closed iamharshkumar97 closed 4 years ago

iamharshkumar97 commented 4 years ago

Where can I find the setting to change these?

Thanks

dsrkafuu commented 4 years ago

For now there's no ready-made way to change the background color. But actually, all the scss code put in the custom.scss will be generated into site's main css, background colour can alse be defined through this way.

As for font, you can change the font size/color, font-family and theme color scheme also using custom scss, check more details at https://github.com/amzrk2/hugo-theme-fuji#advance-configration.

iamharshkumar97 commented 4 years ago

Thank you for the reply. So which file should I copy from the theme folder to make changes and then save it as custom.scss? Also can I save my custom font in assets folder and then reference it in custom.scss ?

dsrkafuu commented 4 years ago

Just create a new sitefolder/assets/sass/custom.scss and copy variables you want to change from readme.

Need Hugo extended version.

Font-face works, if your custom font is sitefolder/static/fonts/aaa.woff2:

@font-face {
    ...
    url(/fonts/aaa.woff2)
}

Then change the font-family.

iamharshkumar97 commented 4 years ago

Thank you for all the help. Final question. Sorry for my ignorance but what should I add in custom.scssfor background?

Reference:

background colour can alse be defined through this way.

Also I tried changing the font. It didn't work.

@font-face {
    font-family: 'mallory';
    src: url(/fonts/mallory.woff2);
}

I added this.

dsrkafuu commented 4 years ago

For example:

body {
    background-color: #3F3F3F !important;
}

About font, see: https://imgur.com/a/JJ64ic5

stale[bot] commented 4 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.