Releases: timber/timber
Releases · timber/timber
Release Candidate for version 1.3.0
Fixes to comments; better pagination support
- Uses Twig 2.0 for PHP 7 users who install w Composer
- Default
$contextobject now returns a PostQuery for$context['posts']this is cool because you can use{{ posts.pagination }}in your Twig templates without any further PHP work (thanks @lggorman) Timber\Imageswith PDFs and other content types now return the file instead of null # (thanks @hoandang)
*Timber\Commentsnow support different comment types #1364 (thanks @yantei)Timber\Comments{{ comment.content }}now returns processed comment with<p>tags- Fix for HTTP error when uploading media files in Windows #1346 (thanks Matias Griese)
- Fix for image resizing on alternative WP setups (thanks @gillesgoetsch)
Fixed regression with default image sizing
Fix to S3 Image Handling
- Fixed a potential XSS security issue
- Fixed handling of images stored on S3
Fixes to image handling
- A bunch of fixes to how images in themes are handled #1317 #1293 (@jarednova)
- Fixed filter for avatar images in comments #1310 (@xavivars)
- Upgrades to PHPUnit and testing suite (@jarednova)
1.2.0 fixes & refactoring
Comment Threads and WordPress 4.7
Comment Threads
You can now more easily fetch an manipulate threads of comments thanks to the fancy new CommentThread object! Why?
- Adds depth info
- Nests by default (thus, the change from 1.1.* to 1.2)
- Supports future syntax features
Usage:
post.twig
<h1>{{ post.title }}</h1>
<article>{{ post.content }}</article>
<section class="comments">
{% for comment in post.comments %}
{% include "comment.twig" %}
{% endfor %}comment.twig
<div class="comment-{{ comment.id }} depth-{{ comment.depth }}">
{{ comment.content }}
<p class="who">{{ comment.author.name }}</p>
<div class="replies">
{% include "comment.twig" %}
</div>
</div>You can also do fun stuff when fetching comments like {% post.comments.order('DESC') %} or `{% post.comments.orderby('comment_author') %}
WordPress 4.7
The new version of WP introduced a bevy of small changes that broke a number of low-level Timber features. These were items caught by UnitTests (no reports of users seeing strange behavior), but out of an abundance of caution these were held until Timber 1.2 to reduce possibility of breaking live sites.
Twig deprecation fix
Ordering and Querying fixes
Co-Authors Plus, Yoast Improvements
- Added support for Co-Authors Plus Guest Authors #1239 (thanks @motia)
- Fix for Yoast SEO with multisite #1244 (thanks @alexandernanberg)
- Fixes issues with basedir restrictions that arose in Timber 1.1.9 #1245