Skip to content

Commit 61c1f0e

Browse files
committed
chore: revert version from 1.2.0 to 1.1.0, consolidate changelog entries
1 parent 3a0550b commit 61c1f0e

6 files changed

Lines changed: 19 additions & 25 deletions

File tree

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "webberzone/webberzone-code-block-highlighting",
33
"description": "Extends the Gutenberg Code block with syntax highlighting powered by Prism.js.",
4-
"version": "1.2.0",
4+
"version": "1.1.0",
55
"type": "wordpress-plugin",
66
"keywords": [
77
"code block",
@@ -63,4 +63,4 @@
6363
],
6464
"zip": "./build-zip.sh"
6565
}
66-
}
66+
}

includes/frontend/class-blocks.php

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ public function enqueue_editor_assets(): void {
103103
* Only runs in the admin context to avoid duplicating the frontend enqueue
104104
* that `Styles_Handler` already handles via `wp_enqueue_scripts`.
105105
*
106-
* @since 1.2.0
106+
* @since 1.1.0
107107
*/
108108
public function enqueue_editor_canvas_styles(): void {
109109
if ( ! is_admin() ) {
@@ -309,7 +309,7 @@ public function render_code_block( string $block_content, array $block ): string
309309
* Injects language classes and data-attributes into the existing saved HTML
310310
* so the Prism JS bundle can highlight in the browser.
311311
*
312-
* @since 1.2.0
312+
* @since 1.1.0
313313
*
314314
* @param string $block_content The rendered block HTML.
315315
* @param array<string,mixed> $params Normalised block parameters.
@@ -418,7 +418,7 @@ protected function render_code_block_client( string $block_content, array $param
418418
* and injects toolbar overlays (language label, file name, copy button)
419419
* as PHP-rendered HTML so no Prism JS is required.
420420
*
421-
* @since 1.2.0
421+
* @since 1.1.0
422422
*
423423
* @param string $block_content The rendered block HTML.
424424
* @param array<string,mixed> $params Normalised block parameters.
@@ -683,7 +683,7 @@ protected static function remap_token_classes( string $html ): string {
683683
* register that rather than the global vendor/autoload.php to avoid leaking
684684
* unrelated dependencies into the WordPress runtime. Runs once per request.
685685
*
686-
* @since 1.2.0
686+
* @since 1.1.0
687687
*/
688688
protected static function load_highlighter(): void {
689689
static $loaded = false;
@@ -710,7 +710,7 @@ static function ( string $class_name ): void {
710710
* Languages not in the map are passed through unchanged; an empty string
711711
* means "no highlighting" (plain text).
712712
*
713-
* @since 1.2.0
713+
* @since 1.1.0
714714
*
715715
* @param string $prism_slug Prism language slug from the block attribute.
716716
* @return string hljs language slug, or empty string for plain text.
@@ -743,7 +743,7 @@ protected static function get_hljs_language( string $prism_slug ): string {
743743
* line highlighting. Properly closes and reopens inline <span> elements
744744
* at line boundaries so the output remains valid HTML.
745745
*
746-
* @since 1.2.0
746+
* @since 1.1.0
747747
*
748748
* @param string $html Highlighted HTML from highlight.php.
749749
* @param int $start First line number.
@@ -814,7 +814,7 @@ protected static function wrap_lines( string $html, int $start, array $target_li
814814
/**
815815
* Build a single <span class="wzcbh-line"> wrapper for one line.
816816
*
817-
* @since 1.2.0
817+
* @since 1.1.0
818818
*
819819
* @param int $line_num Current line number.
820820
* @param int[] $target_lines Line numbers that should be highlighted.
@@ -835,7 +835,7 @@ protected static function make_line_span( int $line_num, array $target_lines, st
835835
*
836836
* Accepts e.g. "1,3-5,7" → [1, 3, 4, 5, 7].
837837
*
838-
* @since 1.2.0
838+
* @since 1.1.0
839839
*
840840
* @param string $spec The line range specification.
841841
* @return int[]

includes/frontend/class-styles-handler.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ static function ( bool $carry, \WP_Post $post ): bool {
8383
/**
8484
* Enqueue assets for client-side (Prism.js) mode.
8585
*
86-
* @since 1.2.0
86+
* @since 1.1.0
8787
*/
8888
private function enqueue_client_mode_assets(): void {
8989
$asset_file = WZCBH_PLUGIN_DIR . 'includes/blocks/build/frontend.asset.php';
@@ -144,7 +144,7 @@ private function enqueue_client_mode_assets(): void {
144144
/**
145145
* Enqueue assets for server-side (highlight.php) mode.
146146
*
147-
* @since 1.2.0
147+
* @since 1.1.0
148148
*/
149149
private function enqueue_server_mode_assets(): void {
150150
$asset_file = WZCBH_PLUGIN_DIR . 'includes/blocks/build/frontend.asset.php';

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@webberzone/webberzone-code-block-highlighting",
3-
"version": "1.2.0",
3+
"version": "1.1.0",
44
"description": "Extends the Gutenberg Code block with syntax highlighting powered by Prism.js.",
55
"author": "WebberZone",
66
"license": "GPL-2.0-or-later",

readme.txt

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Donate link: https://wzn.io/donate-wz
44
Tags: syntax highlighting, code block, prism, gutenberg, code highlighting
55
Requires at least: 6.6
66
Tested up to: 7.0
7-
Stable tag: 1.2.0
7+
Stable tag: 1.1.0
88
Requires PHP: 7.4
99
License: GPLv2 or later
1010
License URI: https://www.gnu.org/licenses/gpl-2.0.html
@@ -176,15 +176,12 @@ Report security bugs through the Patchstack Vulnerability Disclosure Program. Th
176176

177177
== Changelog ==
178178

179-
= 1.2.0 =
179+
= 1.1.0 =
180180

181181
* New: Server-side highlighting mode powered by highlight.php — syntax is pre-rendered on the server with no JavaScript required on the frontend.
182182
* New: All 21 Prism themes work identically in both client-side and server-side modes. Server mode now outputs Prism-compatible token classes and loads the same theme CSS, so switching modes produces no visual difference.
183-
* Fix: Duplicate `language-*` class on `<code>` elements in client mode when the saved block HTML already carried the class.
184-
185-
= 1.1.0 =
186-
187183
* New: Added "Plain Text" language option to the language picker. Renders with Prism theme styling but no syntax highlighting.
184+
* Fix: Duplicate `language-*` class on `<code>` elements in client mode when the saved block HTML already carried the class.
188185

189186
= 1.0.0 =
190187

@@ -202,11 +199,8 @@ Report security bugs through the Patchstack Vulnerability Disclosure Program. Th
202199

203200
== Upgrade Notice ==
204201

205-
= 1.2.0 =
206-
Adds server-side highlighting mode (highlight.php) with full theme parity across all 21 Prism themes.
207-
208202
= 1.1.0 =
209-
Adds "Plain Text" to the language picker.
203+
Adds server-side highlighting mode (highlight.php) with full theme parity across all 21 Prism themes, plus a "Plain Text" language picker option.
210204

211205
= 1.0.0 =
212206
Initial release.

webberzone-code-block-highlighting.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
* Plugin Name: WebberZone Code Block Highlighting
1515
* Plugin URI: https://webberzone.com/webberzone-code-block-highlighting-page/
1616
* Description: Extends the Gutenberg Code block with syntax highlighting powered by Prism.js.
17-
* Version: 1.2.0
17+
* Version: 1.1.0
1818
* Author: WebberZone
1919
* Author URI: https://webberzone.com
2020
* License: GPL-2.0+
@@ -35,7 +35,7 @@
3535
* @since 1.0.0
3636
*/
3737
if ( ! defined( 'WZCBH_VERSION' ) ) {
38-
define( 'WZCBH_VERSION', '1.2.0' );
38+
define( 'WZCBH_VERSION', '1.1.0' );
3939
}
4040

4141
/**

0 commit comments

Comments
 (0)