This is a Pelican template based on the Editorial HTML template of HTML5UP.
A demo of this template can be found here.
Screenshots can be found in the root directory of the repository.
Contents
- Responsive Design (Desktop, Tablet, Tablet (Portrait), Mobile)
- Static site search via
tipue_search
- Pygments
- Recent posts in sidebar
Due to the pretty classes that HTML5UP had in their HTML template, this Pelican template comes with some nice elements, which include:
- Support for multi-column formatting
- Image wrapping on left and right
- Fitting images
- Pretty buttons and pagination
See the Elements page for examples of the above and more!
Note: This template works best with reStructuredText documents. I have yet to figure out a "nice" way to apply the classes in the css file to Markdown sections.
You can clone this repository directly, then modify the entries in the
content
directory.
This template requires pelican
and beautifulsoup4
(for Tipue
Search). The tipue_search
plugin is required for search functionality,
and the render_math
plugin is recommended for better looking math.
To install the requirements, simply run:
pip install -r requirements.txt
As the structure stands now, the plugins directory contains symlinks to the
pelican-plugins
repository that was installed there as a submodule. If
this is not the case, the symlinks should be amended, the plugins can be
installed into the plugins
directory directly, or you can modify your
pelicanconf.py
.
If you want to start from scratch, or you want your theme to be in a separate
location from your content, you can copy the theme
folder to wherever
you need it, then modify your pelicanconf.py
accordingly.
The templates use the following variables:
Variable | Use |
---|---|
MENUITEMS |
Configuring the links in the navigation section of the sidebar. |
CONTACTS |
Configuring contact links/info at the bottom of the sidebar. |
SOCIAL |
Configuring the icons and links at the top of the page. |
SHAREPOST |
Configuring the "Share on:" links at the top of every post. |
When needed, icon class codes should correspond to the font-awesome class.
These common variables are highly encouraged to have the following settings
Variable | Recommendation |
---|---|
DEFAULT_PAGINATION |
Multple of 6 |
DIRECT_TEMPLATES |
['search', 'index', 'archives', 'authors', 'categories', 'tags', '404'] |
PAGINATED_TEMPLATES |
{'archives': None, 'tag': None, 'category': None, 'author': None} |
You will definitely want to modify index.html and sidebar.html. These contain hard coded text visible in the top portion of the index and the contacts section of the sidebar. Everything else should be essentially ready for roll-out, but feel free to tinker as you please!
This template is licensed under the Apache 2.0 license. See LICENSE for more details.
This template draws heavily from the fantastic work of others. The design is entirely based off of (and modified from) the Editorial template by HTML5UP [License - CCA 3.0]. Search is enabled by the Tipue Search plugin, created by Tipue [License - MIT. Images are from various artists at Unsplash [License - Unsplash License]. Fonts are Roboto Slab and Open Sans [License - Apache 2.0], and icons are provided by Font Awesome.