jajuma-gmbh / syntax-highlighter-4-page-builder

jajuma-gmbh/syntax-highlighter-4-page-builder

JaJuMa Syntax Highlighter 4 Page Builder for Magento 2

  • JaJuMa
magento2-module Compatibility: 2.4.7-2.4.9 Code Quality: Fail Tests: N/A Security: Pass MIT

:nerd_face: Syntax Highlighter 4 Page Builder for Magento 2 by JaJuMa

Syntax-Highlighter-4-Page-Builder-Module-Magento-2-large.png

Syntax Highlighter 4 Page Builder by JaJuMa adds
syntax highlighting as well as line numbers and color icons for HTML, CSS + Javascript code in Magento 2 Page Builder.

Compatible with

Hyvä Themes Mage-OS Magento
JaJuMa-Hyvanaut-small.png Mage-OS-Compatible.svg magento-icon.svg

Features

This extension provides following improvements for Magento 2 Page Builder HTML Editor:

  • Syntax highlighting for HTML, CSS & JS as well as Magento directives (41 themes included)
  • Color icons for CSS colors (hex, rgba, hsl, web colors)
  • Automatically added line numbers
  • Highlight matching braces on hover / via rainbow colors
  • Keep line indents on input line break
  • Show invisible characters (space, tabs, line breaks)
  • Preview CSS values on hover for angles, colors, gradients, easing functions & time for durations

Note
git-4-Page-Builder-Module-Magento-2-large.png
Looking for more improvements for Magento 2 Page Builder?
Want to use git for managing static content in Magento 2?
:arrow_right: Check our git 4 Page Builder extension.

Further Info, Extension Description & Manual

Demos

Screenshots

syntax-highlighter-4-page-builder-magento-2-theme-selection.jpg syntax-highlighter-4-page-builder-magento-2-dark-theme-example.jpg syntax-highlighter-4-page-builder-magento-2-light-theme-example.jpg

Installation

Install via composer as any other Magento extension from github:

composer require jajuma/module-syntax-highlighter

Using Syntax Highlighter 4 Page Builder

Go to JaJuMa -> Syntax Highlighter -> Configuration
And enable & configure the extension.
Use HTML editor in Page Builder - Happy Coding!

License

The code is licensed under the MIT License (MIT)

Credits

Powered by PrismJS &
Many thanks @Oliver Geer for his amazing article on https://css-tricks.com/
that helped a lot when creating this module and
@Gordon Lesti for his work on syntax highlighting for Magento directives with PrismJS.

Other Magento 2 & Hyvä Themes Extensions by JaJuMa

Other Services by JaJuMa

© JaJuMa GmbH | www.jajuma.de

No changelog yet

The vendor hasn't published a changelog. Tagged releases appear in the Versions tab.

Versions
Version Stability QA Status Compatibility Released
1.0.4 stable Fail Magento 2.4.7-2.4.9 Details 2025-01-13 05:56:59
1.0.3 stable Not tested Not yet tested Details 2024-02-06 03:29:57
1.0.2 stable Not tested Not yet tested Details 2024-01-24 07:24:20
1.0.1 stable Not tested Not yet tested Details 2023-07-17 03:03:16
1.0.0 stable Not tested Not yet tested Details 2023-05-30 11:02:51

No dependencies declared

This package's composer.json doesn't declare any required, suggested, replaced, or conflicting packages.

Compatibility

Each Magento release line is installed on its supported PHP versions, then the module is built (DI compilation + static-content deploy) and its unit and integration suites are run. The matrix shows the lines and PHP versions the module is confirmed to install and run on. Code-quality results further down (phpstan, phpcs, …) are reported separately and never affect compatibility.

Compatibility matrix (Magento × PHP)
Magento PHP 8.2 PHP 8.3 PHP 8.4 PHP 8.5
2.4.7 Pass Pass
2.4.8 Pass Pass
2.4.9 Pass Pass

Code Quality

Advisory checks against the module's source. Static analysis runs once across the whole module; PHPStan re-runs per Magento + PHP version because resolvable symbols differ between releases. These NEVER affect the Compatibility badge — a phpcs finding can't make a module incompatible.

Static analysis

Coding standards (phpcs), mess detection (phpmd), copy-pasted code (cpd), PHP cross-version compatibility, composer.json validity. Each runs once for the whole module.

Static analysis results
Tool Status Findings Summary
PHPCS Fail 30 16 errors, 14 warnings (ruleset: Magento2) — 7 auto-fixable with phpcbf
PHPMD Pass 0
Cpd Pass 0
Composer validate Info 1 valid; 1 advisory note (composer validate --strict)

PHPStan

Type-checks the module's PHP against a real Magento install at the configured gate level. Re-runs per Magento and PHP version because resolvable symbols differ between releases. Cell → details modal.

PHPStan results by Magento and PHP version
Magento PHP 8.2 PHP 8.3 PHP 8.4 PHP 8.5
2.4.7 5 5
2.4.8 5 5
2.4.9 5 5

Tests

Unit and integration suites, run for each applicable Magento and PHP version. A test failure speaks to the module's behaviour, not its compatibility with a Magento line, so it is reported here separately and never reddens the compatibility matrix.

Unit tests

Unit tests results by Magento and PHP version
Magento PHP 8.2 PHP 8.3 PHP 8.4 PHP 8.5
2.4.7 N/A N/A
2.4.8 N/A N/A
2.4.9 N/A N/A

Integration tests

Integration tests results by Magento and PHP version
Magento PHP 8.2 PHP 8.3 PHP 8.4 PHP 8.5
2.4.7 N/A N/A
2.4.8 N/A N/A
2.4.9 N/A N/A

Security

Security checks run directly against the module: an audit of its declared dependencies for known vulnerabilities (composer audit) and a scan of its source for malware and web-shell signatures. Each runs once. A malware detection fails the version outright.

Security results
Tool Status Findings Summary
Composer audit Pass 0
Malware scan Pass 0
License
MIT
Authors
Make it pay

Turn an existing module into recurring revenue.

If you already maintain a Magento 2 module on GitHub or GitLab, listing it on Packagento takes about five minutes. We mirror your tags, handle distribution signing, and route paid licenses through Stripe Connect, so you can keep shipping the way you already do.