Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
= 1.2.21 =
* Fixed the theme's Font Awesome 6 never loading on sites running Elementor or any other plugin that registers the generic "font-awesome" handle. WordPress keeps only the first registration of a handle, so the theme's stylesheet was silently dropped and every fa-brands / fa-solid icon -- the social links, the search button, the menu and pagination arrows -- rendered as a blank box. It now uses its own "shapely-font-awesome" handle
* Fixed the customizer loading Font Awesome from .../shapely/inc/assets/css/..., a path that has never existed, so the customizer's own icons 404'd
* Fixed related posts on portfolio items returning the wrong posts when the portfolio taxonomies are not registered: wp_get_object_terms() returns a WP_Error there, and it was being passed straight into the query
* Regenerated languages/shapely.pot, which had been built before the text domain unification and was missing 86 translatable strings
* Added a version check to the build so style.css, readme.txt, changelog.txt and package.json can no longer drift apart (readme.txt had been left at 1.2.19)
* Fixed the coding-standards CI job, which had been failing to install PHPCS rather than actually checking anything

= 1.2.20 =
* PHP 8.5 compatibility: removed every runtime deprecation and warning raised by the theme
* Verified on WordPress 7.0.2 / PHP 8.5: zero PHP notices across all templates, the customizer, the welcome screen and the block editor
Expand Down
2 changes: 1 addition & 1 deletion languages/shapely.pot
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# This file is distributed under the GNU General Public License v3.
msgid ""
msgstr ""
"Project-Id-Version: Shapely 1.2.20 1.2.20\n"
"Project-Id-Version: Shapely 1.2.21\n"
"Report-Msgid-Bugs-To: https://www.colorlib.com/\n"
"Last-Translator: Colorlib <office@colorlib.com>\n"
"Language-Team: Colorlib <office@colorlib.com>\n"
Expand Down
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "shapely",
"version": "1.2.20",
"version": "1.2.21",
"description": "Build and lint tooling for the Shapely WordPress theme.",
"homepage": "https://www.colorlib.com",
"author": "Colorlib",
Expand All @@ -25,9 +25,10 @@
"i18n": "node tools/make-pot.mjs",
"i18n:check": "node tools/check-textdomain.mjs",
"images": "node tools/optimize-images.mjs",
"prebuild": "npm run i18n:check",
"prebuild": "npm-run-all i18n:check version:check",
"build": "node tools/build-zip.mjs",
"verify": "npm-run-all lint i18n:check"
"verify": "npm-run-all lint i18n:check version:check",
"version:check": "node tools/check-version.mjs"
},
"devDependencies": {
"@eslint/js": "^10.0.1",
Expand Down
10 changes: 9 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,14 @@ This page template is used to create the Parallax homepage from our demo : https

== Changelog ==

= 1.2.21 =
* Fixed the theme's Font Awesome 6 never loading on sites running Elementor or any other plugin that registers the generic "font-awesome" handle. WordPress keeps only the first registration of a handle, so the theme's stylesheet was silently dropped and every fa-brands / fa-solid icon -- the social links, the search button, the menu and pagination arrows -- rendered as a blank box. It now uses its own "shapely-font-awesome" handle
* Fixed the customizer loading Font Awesome from .../shapely/inc/assets/css/..., a path that has never existed, so the customizer's own icons 404'd
* Fixed related posts on portfolio items returning the wrong posts when the portfolio taxonomies are not registered: wp_get_object_terms() returns a WP_Error there, and it was being passed straight into the query
* Regenerated languages/shapely.pot, which had been built before the text domain unification and was missing 86 translatable strings
* Added a version check to the build so style.css, readme.txt, changelog.txt and package.json can no longer drift apart (readme.txt had been left at 1.2.19)
* Fixed the coding-standards CI job, which had been failing to install PHPCS rather than actually checking anything

= 1.2.20 =
* PHP 8.5 compatibility: removed every runtime deprecation and warning raised by the theme
* Verified on WordPress 7.0.2 / PHP 8.5: zero PHP notices across all templates, the customizer, the welcome screen and the block editor
Expand Down Expand Up @@ -194,4 +202,4 @@ This page template is used to create the Parallax homepage from our demo : https
= 1.0.0 - March 26 2016 =
* Initial release

Stable tag: 1.2.19
Stable tag: 1.2.21
2 changes: 1 addition & 1 deletion style.css
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Theme URI: https://colorlib.com/wp/themes/shapely/
Author: Colorlib
Author URI: https://colorlib.com
Description: Shapely is a one-page WordPress theme for business, portfolio and small e-commerce sites. The front page is assembled from widgets, so you can stack parallax sections, a portfolio grid, testimonials, a client logo carousel, a call to action and a contact block in whatever order you need. It also ships conventional blog templates with a choice of left, right, full-width or no sidebar, four footer widget areas, and a social icon menu. WooCommerce and Jetpack are supported, and the theme is translation ready.
Version: 1.2.20
Version: 1.2.21
Requires at least: 6.4
Tested up to: 7.0
Requires PHP: 7.4
Expand Down
34 changes: 34 additions & 0 deletions tools/check-version.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
/**
* Fail the build when the version is not the same in all four places.
*
* The theme carries its version in style.css (the only file WordPress actually
* reads it from), readme.txt, changelog.txt and package.json. Nothing checked
* that they agreed, and they had already drifted: readme.txt's Stable tag sat
* at 1.2.19 while the theme shipped 1.2.20.
*/
import { readFile } from 'node:fs/promises';
import path from 'node:path';

const ROOT = path.resolve(import.meta.dirname, '..');
const read = (f) => readFile(path.join(ROOT, f), 'utf8');

const style = (await read('style.css')).match(/^\s*Version:\s*(.+)$/m)?.[1].trim() ?? '';
const readme = (await read('readme.txt')).match(/^Stable tag:\s*(.+)$/m)?.[1].trim() ?? '';
// changelog.txt is newest-first, so the first "= x.y.z =" heading is the release.
const changelog = (await read('changelog.txt')).match(/^=\s*([0-9][^=\s]*)\s*=/m)?.[1].trim() ?? '';
const pkg = JSON.parse(await read('package.json')).version ?? '';

const rows = [
['style.css Version', style],
['readme.txt Stable tag', readme],
['changelog.txt latest entry', changelog],
['package.json version', pkg],
];
rows.forEach(([label, v]) => console.log(` ${label.padEnd(30)} ${v || '(missing)'}`));

const unique = [...new Set(rows.map(([, v]) => v))];
if (unique.length !== 1 || !unique[0]) {
console.error(`\n version mismatch: ${unique.join(' / ')}`);
process.exit(1);
}
console.log(`\n versions agree: ${style}`);
7 changes: 6 additions & 1 deletion tools/make-pot.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,12 @@ try {
const args = [
'i18n', 'make-pot', ROOT, DEST,
'--domain=shapely',
'--package-name=' + `Shapely ${version}`.trim(),
/*
* Just the name. WP-CLI reads the version out of style.css and appends it
* itself, so passing "Shapely 1.2.20" here produced the doubled
* "Project-Id-Version: Shapely 1.2.20 1.2.20".
*/
'--package-name=Shapely',
'--exclude=node_modules,vendor,build,tools,src,.github',
'--headers=' + JSON.stringify({
'Report-Msgid-Bugs-To': 'https://www.colorlib.com/',
Expand Down
Loading