Item's Layouts

Pick a design for your collections in blog template

Boxed

Since time ago I've been thinking how to improve theme quality removing our Twig functions to handle aviability of user defined style vs proper text color. Best solution was move all those handlings to SASS functions and apply required modifications there. Now the code is much simpler, easy to understand, and let you add as many colors/styles as you desire.

Today template received a major update of Bootstrap 4.3.1 which includes a lot of improvements, SASS reestructured, new theme options and fixes.

I added support for readingtime Grav plugin for cards and boxed post layouts. Also has been included in item's template. Then you could customize the output string and words-per-minute in plugin configuration.

Cards

Moved macros to SASS functions

Since time ago I've been thinking how to improve theme quality removing our Twig functions to handle aviability of user defined style vs proper text color. Best solution was move all those handlings to SASS functions and apply required modifications there. Now the code is much simpler, easy to understand, and let you add as many colors/styles as you desire.

features

Updated Bootstrap and New Features

Today template received a major update of Bootstrap 4.3.1 which includes a lot of improvements, SASS reestructured, new theme options and fixes.

bugfix, features

Added support for Reading time plugin

I added support for readingtime Grav plugin for cards and boxed post layouts. Also has been included in item's template. Then you could customize the output string and words-per-minute in plugin configuration.

features

Blog Template

Create as many folders you want under /pages having a similar structure as image below:

Then under main folders (e.g. blog) create a markdown file blog.md to render a list of descendant items and optional sidebar. Follow Grav Collections praxis and set items to visible children.

content:
    items: '@self.children'
    order:
        by: date
        dir: desc
    limit: 5
    pagination: true

Afterwards just add the parameter layout as boxed, cards or masonry to visualize items in any of 3 collection designs availables (more incomming).

Modular

Blog template has a 'Modular block' content that should be setting up with Grav Page Collections, or use the show_more parameter as fallback to get children from a specific route and also adds a button at the end of block. You can choose any 3 layouts above to display your items: boxed, cards or masonry.

title: Blog Modular           # Page title
layout: boxed|cards|masonry   # Items collection design
show_more: /blog              # Displays a button to route and serves as fallback to get collection
content:                      # Collection sample params
    items:
      '@page': '/blog'
    order:
        by: date
        dir: desc
    limit: 6
    pagination: false

Template page

Create a blog or portfolio with sidebar to list descendant items. Use blog.md filename.

title: Blog
style: dark
layout: boxed
content:
    items: '@self.children'
    order:
        by: date
        dir: desc
    limit: 8
    pagination: true