gethugothemes / dot-hugo

Dot - Hugo Documentation Theme
https://gethugothemes.com/products/dot/?utm_source=dot_github&utm_medium=referral&utm_campaign=github_theme_about
MIT License
261 stars 148 forks source link

:memo: layouts/index: Add optional text above site topics #177

Closed jwflory closed 2 years ago

jwflory commented 2 years ago

This commit allows a site to have generic text to appear at the top of the site, underneath the header but above the topics. This is useful because it allows a site maintainer to give more context or lead-ins to the content available on the site. Since this might not be applicable for all users, this is made an optional feature. If there is no index file in content/, nothing will appear and the site will appear as it does now.

Screenshot of the index page from the example site with the new feature. A text block is shown at the top of the page.

jwflory commented 2 years ago

If possible, it would be nice for this to be reviewed by Monday, 22 November. At @UNICEF, we are preparing a webinar next week to demo the unicef/drone-4sdgtoolkit site, which uses Dot. We hope to pull this downstream to use in our theme too and add some text ahead of the webinar:

Drones for SDGs Toolkit webinar registration. Click to open for more information shared on Twitter.