Chap
Posts

The [post] shortcode can be used to display a secondary loop of posts anywhere using WP_Query.

Posts shortcode arguments
Classes
Typeitems grid cards
Itemscompact very compact divided relaxed very relaxed
Griddivided vertically divided celled internally celled relaxed very relaxed
Cardsraised stackable doubling centered fluid red green blue ...
queryWordPress query string or keyword (Available keywords: related).
templateCustom template name. Template file must reside in the (child) theme's templates directory and be prefixed with loop- (ex. templates/loop-list).
excerptCustom excerpt length (number of words). Set to 0 to disable excerpts. (Default: 55)
thumbnailCustom thumbnail image size (none|thumbnail|small|medium|large|full). (Default: medium)
headerPosts header size (tiny|small|medium|large|huge). (Default: small)
metaInfo displayed below post title. (date_author|timeago_author|date|timeago|author|none)
tagsSet to false to disable tags (categories, tags and sticky post indicator).
read_moreSet to false to disable the "Read more" link.
paginationSet to true to enable pagination.
pagination_alignmentPagination alignment (left|center|right).
pagination_menuAdditional classes for the pagination menu.
nextPagination next posts link text (default: "Older posts").
prevPagination previous posts link text (default: "Newer posts").
countSpecify post count when query is a keyword (default: 4).
header_textHeader text to display above posts (only displayed if there are posts).
header_classesClasses for the header.
content_beforeContent before the posts (only displayed if there are posts).
content_afterContent after the posts (only displayed if there are posts).
Items

WC Filter Products by Attribute internal server error allowed memory bytes exhausted

WooCommerce Filter Products by Attribute widget was causing the shop page to produce an Internal Server Error 500 and preventing the page from displaying. While logged in and WP_DEBUG enabled the page loaded partially but failed when it was time to render the widget. Looking at WooCommerce -> Status -> Logs -> fatal-errors-*.log the error…

[posts items query="posts_per_page=3&ignore_sticky_posts=1"]
Divided items

WC Filter Products by Attribute internal server error allowed memory bytes exhausted

WooCommerce Filter Products by Attribute widget was causing the shop page to produce an Internal Server Error 500 and preventing the page from displaying. While logged in and WP_DEBUG enabled the page loaded partially but failed when it was time to render the widget. Looking at WooCommerce -> Status -> Logs -> fatal-errors-*.log the error…

[posts divided items query="posts_per_page=3&ignore_sticky_posts=1"]
Relaxed items

WC Filter Products by Attribute internal server error allowed memory bytes exhausted

WooCommerce Filter Products by Attribute widget was causing the shop page to produce an Internal Server Error 500 and preventing the page from displaying. While logged in and WP_DEBUG enabled the page loaded partially but failed when it was time to render the widget. Looking at WooCommerce -> Status -> Logs -> fatal-errors-*.log the error…

[posts very relaxed items query="posts_per_page=3&ignore_sticky_posts=1"]
Grid

WC Filter Products by Attribute internal server error allowed memory bytes exhausted

WooCommerce Filter Products by Attribute widget was causing the shop page to produce an Internal Server Error 500 and preventing the page from displaying. While logged in and WP_DEBUG enabled the page loaded partially but failed when it was time to render the widget. Looking at WooCommerce -> Status -> Logs -> fatal-errors-*.log the error…

[posts grid query="posts_per_page=3&ignore_sticky_posts=1"]
Divided grid

WC Filter Products by Attribute internal server error allowed memory bytes exhausted

WooCommerce Filter Products by Attribute widget was causing the shop page to produce an Internal Server Error 500 and preventing the page from displaying. While logged in and WP_DEBUG enabled the page loaded partially but failed when it was time to render the widget. Looking at WooCommerce -> Status -> Logs -> fatal-errors-*.log the error…

[posts divided two column grid query="posts_per_page=4&ignore_sticky_posts=1"]
Celled grid

WC Filter Products by Attribute internal server error allowed memory bytes exhausted

WooCommerce Filter Products by Attribute widget was causing the shop page to produce an Internal Server Error 500 and preventing the page from displaying. While logged in and WP_DEBUG enabled the page loaded partially but failed when it was time to render the widget. Looking at WooCommerce -> Status -> Logs -> fatal-errors-*.log the error…

[posts celled two column grid query="posts_per_page=6&ignore_sticky_posts=1"]
Internally celled grid
[posts internally celled two column grid query="posts_per_page=6&ignore_sticky_posts=1&meta_key=_thumbnail_id"]
Cards
[posts cards query="posts_per_page=3&ignore_sticky_posts=1&meta_key=_thumbnail_id"]
Cards count

WC Filter Products by Attribute internal server error allowed memory bytes exhausted

WooCommerce Filter Products by Attribute widget was causing the shop page to produce an Internal Server Error 500 and preventing the page from displaying. While logged in and WP_DEBUG enabled the page loaded partially but failed when it was time to render the widget. Looking at WooCommerce -> Status -> Logs -> fatal-errors-*.log the error…

Read more
[posts four stackable cards query="posts_per_page=4&ignore_sticky_posts=1"]
Basic pagination

WC Filter Products by Attribute internal server error allowed memory bytes exhausted

WooCommerce Filter Products by Attribute widget was causing the shop page to produce an Internal Server Error 500 and preventing the page from displaying. While logged in and WP_DEBUG enabled the page loaded partially but failed when it was time to render the widget. Looking at WooCommerce -> Status -> Logs -> fatal-errors-*.log the error…

[posts divided items query="posts_per_page=3&ignore_sticky_posts=1" pagination="true"]
Advanced pagination

WC Filter Products by Attribute internal server error allowed memory bytes exhausted

WooCommerce Filter Products by Attribute widget was causing the shop page to produce an Internal Server Error 500 and preventing the page from displaying. While logged in and WP_DEBUG enabled the page loaded partially but failed when it was time to render the widget. Looking at WooCommerce -> Status -> Logs -> fatal-errors-*.log the error…

[posts two column grid
	query="posts_per_page=4"
	pagination="true"
	next="Older entries"
	prev="Newer entries"
	pagination_alignment="right"
	pagination_menu="tiny secondary"
]
Content instead of excerpt

Chap 1.24.0

Tested with WooCommerce 6.8.2 and 6.9-RC1.
PHP version requirement upped from 5.6 to 7.4.
Updates for PHP 8.1 (WordPress itself is currently not updated for PHP 8.1 so upgrading may still cause deprecated notices).
Removed various deprecated code from the theme.
Theme option code editors now resize height on the fly.
Chap Slide preview page no longer renders the (duplicate) slide as post content.
Chap Slide can now be a link.
Added option to specify aspect ratio for slides.
Added option to enable additional items under Chap admin bar item.
Fixed relocated “Customizer” link showing up on admin pages.
Added option to enable automatic image downsizing.
Added option to specify full width featured image aspect ratio.
Added asterisks to indicate modified SUI components in the SUI editor.
Added option to display WC results count and sorting in a grid (better responsiveness).
Added option to display random products on 404 pages.
Added option to display WC on sale label as a regular label instead of a ribbon.
Added option to display WC on sale label on single product page.
Added options to customize classes of several WC Cart and Checkout elements.
Added option to enable WC test mode for making test purchases.
WC coupon input form is now stackable on smaller screens.
Fixed WC shop tables not using theme border radius.
Added responsive helper mixins for SUI editor.
WC product categories widget now adds wrappers for each depth.
Chap Shortcodes 1.13.3
Added styles attribute which can append custom CSS to the shortcode in a <style> tag.
Dynamic shortcodes can now be used in shortcode attribute as attribute="%cscd-name%".
Dynamic shortcodes can now contain shortcodes.
[field] shortcode now respects for attribute.
WC product prices in [search] shortcode results now use tax settings.
Gutenberg Semantic UI 1.0.34
Composites block now includes presets for WC [products] shortcodes.
Image, Posts and Gallery blocks can now use custom image sizes when the theme option for automatic image downsizing is enabled.
Posts block now supports slider.
Live SUI recompiling in the editor has been removed.
Added control for uppercase text helper.
[posts one column vertically divided grid
	query="posts_per_page=1&ignore_sticky_posts=1"
	template="templates/loop-content"
	pagination="true"
	next="Older post"
	prev="Newer post"
]
Notes
The loop-content template is designed to show posts with content inside grid loops.
Custom header size

WC Filter Products by Attribute internal server error allowed memory bytes exhausted

WooCommerce Filter Products by Attribute widget was causing the shop page to produce an Internal Server Error 500 and preventing the page from displaying. While logged in and WP_DEBUG enabled the page loaded partially but failed when it was time to render the widget. Looking at WooCommerce -> Status -> Logs -> fatal-errors-*.log the error…

[posts items query="posts_per_page=3&ignore_sticky_posts=1" header="huge"]
No thumbnails
[posts three column grid query="posts_per_page=3&ignore_sticky_posts=1&meta_key=_thumbnail_id" excerpt="20" thumbnail="none"]
[posts three column grid query="posts_per_page=3&ignore_sticky_posts=1&meta_key=_thumbnail_id" excerpt="0"]
No meta
[posts three column grid query="posts_per_page=3&ignore_sticky_posts=1&meta_key=_thumbnail_id" excerpt="20" meta="false"]
No tags
[posts three column grid query="posts_per_page=3&ignore_sticky_posts=1&meta_key=_thumbnail_id" excerpt="20" tags="false"]
[posts three column grid query="posts_per_page=3&ignore_sticky_posts=1&meta_key=_thumbnail_id" excerpt="20" read_more="false"]
[subheader dividing]More posts[/subheader]
[posts compact marginless items query="posts_per_page=5&ignore_sticky_posts=1" header="tiny" excerpt="0" thumbnail="none" meta="true" tags="false" read_more="false"]
[posts query="related" count="5"]
Notes
Using the "related" keyword as query will fetch related posts.
You can use custom WP_Query arguments programmatically by using the csc_posts_query filter. Argument 2 of that filter will contain the shortcode's arguments which can be used to identify which instance of the shortcode it is.
[posts id="custom"]
add_filter('csc_posts_query', function($query, $args) {
	if(isset($args['id']) && $args['id'] === 'custom') {
		return [
			'category__in' => [2, 6],
			'posts_per_page' => 3,
		];
	}
	return $query;
}, 10, 2);
[posts items query="posts_per_page=3&ignore_sticky_posts=1" header_text="Header shown when there are posts" header_classes="large dividing"]
[posts items query="posts_per_page=3&cat=123123" header_text="Header not shown because there are no posts"]
Notes
Header can be prepended with the header_text argument for only when there are results.
Wrapper: content before/after

WC Filter Products by Attribute internal server error allowed memory bytes exhausted

WooCommerce Filter Products by Attribute widget was causing the shop page to produce an Internal Server Error 500 and preventing the page from displaying. While logged in and WP_DEBUG enabled the page loaded partially but failed when it was time to render the widget. Looking at WooCommerce -> Status -> Logs -> fatal-errors-*.log the error…

[posts items query="posts_per_page=3&ignore_sticky_posts=1" content_before="<div class='ui primary segment'>" content_after="</div>"]
[posts items query="posts_per_page=3&cat=123123" content_before="<div class='ui primary segment'>" content_after="</div>"]
Notes
You can specify before and after content to wrap the posts in something. The wrapper elements won't be displayed when there are no posts.
That way there won't be an empty container when there are no related posts for example.
[posts three column internally celled stackable grid query="related" count="6" header_text="Related posts" header_classes="large dividing" content_before="<div class='ui segment'>" content_after="</div>"]
Notes
Adding this shortcode to Chap Theme -> Code -> After post content can easily display related posts for all posts.