The T2B5 Theme is for Grav CMS. It includes numerous customisation options, such as navbar styles and web-app settings, as well as comprehensive favicon support. It supports using the following:
The recommended way to use the theme is by starting with the grav-skeleton-t2b5 repository. This includes this theme as well as the required pages, sample icons, and plugins.
To add the theme to an existing site first clone the repository into your /user/themes
folder:
git clone https://github.com/stom66/grav-theme-t2b5 /path/to/grav/user/themes/t2b5
To configure your site to use T2B5 you will need to do the following:
/user/config/system.yaml
to have the following properties:
theme:
setting to t2b5
.absolute_urls:
setting to true
.bin/grav clear-cache
.manifest.json
and browserconfig.xml
pages (described below)The T2B5 theme depends on a number of plugins. If you install via GPM you should be prompted to also install them.
If you were not prompted to install these automatically you can install them via the terminal with the following command:
bin/grav install
Some additional steps you can take after installing the theme to get the most from it:
Sitemap: https://example.com/sitemap.xml
to your robots.txt
fileTo customise the theme and rebuild the css first do the following:
1) From the terminal cd
to the theme dir: cd /path/to/user/themes/t2b5
2) Run: npm install
3) Run: npm run watch
to trigger the gulp build
t2b5/src/scss/custom/_styles.scss
t2b5/src/scss/custom/_typography.scss
t2b5/src/scss/custom/_variables.scss
By default the Bootstrap/Bootswatch libraries are included from CDNs and are not included in theme.css
If you wish to use a customised local Bootstrap style:
1) Disable the CSS CDN includes in the theme options
2) Uncomment the boostrap include statement in t2b5/src/scss/theme.scss
3) Run either npm run watch
or npm run build
to rebuild the CSS
You may wish to toggle the "Use minified CSS" option in the theme options during development to assist inspection.
The theme has comprehensive support for favicons and will automatically resize images to a variety of sizes to ensure maxium compatibility with popular browsers and devices.
Upload your favicons to the folder /user/images/icons
and select them via the Theme config page in the admin panel.
To enable support for ICO files in the theme configuration page add the following to user/config/media.yaml
:
ico:
type: file
thumb: media/thumb-png.png
mime: image/x-icon
image: null
To enable browserconfig.xml create the file pages/browserconfig/default.md
with the following contents:
---
slug: browserconfig.xml
title: browserconfig.xml
append_url_extension: '.xml'
template_format: xml
template: browserconfig
---
To enable manifest.json create the file pages/manifest/default.md
with the following contents:
---
slug: manifest
title: manifest.json
append_url_extension: '.json'
template_format: json
template: manifest
---