Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
a4ab395
Add Element interface
dingo-d Nov 19, 2022
a627c92
Add abstract element class
dingo-d Nov 19, 2022
1f93550
Initial implementation of the mj-text element
dingo-d Nov 19, 2022
5728363
Update base test class
dingo-d Nov 19, 2022
4ea8626
Add tests for the mj-text element class
dingo-d Nov 19, 2022
312100f
Fix the phpcs issue in the abstract element class
dingo-d Nov 19, 2022
7a3cdd6
Add cleanup for test properties
dingo-d Nov 19, 2022
22a9ffe
Reorder allowed attributes in alphabetical order
dingo-d Nov 19, 2022
d977088
Remove gitkeep
dingo-d Dec 1, 2023
691a20e
Add tests for the parser, renderer and some elements
dingo-d Dec 1, 2023
3a1207a
Change parser to return a node instead of array of nodes
dingo-d Dec 1, 2023
aff8b15
Add renderer code
dingo-d Dec 1, 2023
b42bc18
Add conditional tag helper trait
dingo-d Dec 1, 2023
03fb6f9
Add element factory
dingo-d Dec 1, 2023
1e21128
Add abstract element class and the element class
dingo-d Dec 1, 2023
d8039d0
WIP text element
dingo-d Dec 1, 2023
1084974
Update dependencies
dingo-d Dec 3, 2023
6e4b960
Improve factory create method
dingo-d Dec 3, 2023
16bdc38
Add type validator helper
dingo-d Dec 3, 2023
4d0d579
Allow creation of dynamic properties
dingo-d Dec 3, 2023
b65abf8
Add additional test for the render method
dingo-d Dec 3, 2023
a30ff7d
WIP Modify the getHtmlAttributes and formatAttributes methods
dingo-d Dec 3, 2023
4e4a9fb
Add return type shape to the text element
dingo-d Dec 3, 2023
c1058d5
Add validators
dingo-d Jan 28, 2024
6440e33
Add additional tests for the element formatting and overriding
dingo-d Jan 28, 2024
cd5804b
Minor grammar fix in docblock
dingo-d Jan 28, 2024
dd5ea44
Add types to allowed attributes for validation
dingo-d Jan 28, 2024
07c4901
Update abstract element class
dingo-d Jan 28, 2024
3d92692
Remove renderContent method from the Element interface
dingo-d Jan 28, 2024
5dafac4
Initial addition of body element
dingo-d Jan 28, 2024
890c707
Extract the dependency on the validator out of the validation method
dingo-d Jan 29, 2024
2f1b31c
Refactor validation code
dingo-d Jan 29, 2024
ffce08a
Update the coverage composer command
dingo-d Jan 29, 2024
67a1da3
Update validators
dingo-d Jan 29, 2024
d0c6e8a
Update tests for validators
dingo-d Jan 29, 2024
ff6813b
Fix phpcs issues
dingo-d Jan 29, 2024
b002f5f
Update packages
dingo-d Jul 17, 2025
17ddb99
WIP Update abstract element
dingo-d Jul 17, 2025
07c614a
WIP Modify the body component add column and section components
dingo-d Jul 17, 2025
82ea712
Modify element factory
dingo-d Jul 17, 2025
755b52d
Modify the type validator
dingo-d Jul 17, 2025
0100301
Add various helper traits
dingo-d Jul 17, 2025
e5a245d
Add body test
dingo-d Jul 17, 2025
6ed9c8c
Update packages
dingo-d Jul 17, 2025
f6362bf
Update phpunit config
dingo-d Jul 17, 2025
6536991
Add colors to phpcs config
dingo-d Jul 17, 2025
89ba28f
Fix phpstan config
dingo-d Jul 17, 2025
02bcb02
Fix code style issues
dingo-d Jul 17, 2025
9cb90e2
Fix one test and skip a failing test for now
dingo-d Jul 17, 2025
e99d596
Update workflow
dingo-d Jul 17, 2025
fe1c1f5
Fix workflow
dingo-d Jul 17, 2025
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
17 changes: 7 additions & 10 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
- name: "Set up PHP"
uses: "shivammathur/setup-php@v2"
with:
php-version: "7.4"
php-version: "8.3"
coverage: "none"

- name: "Checkout code"
Expand Down Expand Up @@ -64,17 +64,14 @@ jobs:
strategy:
fail-fast: false
matrix:
php: [ '8.1', '8.0', '7.4' ]
php: [ '8.3', '8.4' ]
allowed_failure: [ false ]
dependencies:
- "lowest"
- "highest"
include:
- php: '8.2'
- php: '8.5'
allowed_failure: true
exclude:
- php: '8.1'
dependencies: "lowest" # Fails due to PHP parser error on a specific version.
steps:
- name: "Set up PHP"
uses: "shivammathur/setup-php@v2"
Expand Down Expand Up @@ -116,10 +113,10 @@ jobs:
strategy:
fail-fast: false
matrix:
php: [ '8.1', '8.0', '7.4' ]
php: [ '8.3', '8.4' ]
allowed_failure: [ false ]
include:
- php: '8.2'
- php: '8.5'
allowed_failure: true
steps:
- name: "Set up PHP"
Expand Down Expand Up @@ -152,10 +149,10 @@ jobs:
strategy:
fail-fast: false
matrix:
php: [ '8.1', '8.0', '7.4' ]
php: [ '8.3', '8.4' ]
allowed_failure: [ false ]
include:
- php: '8.2'
- php: '8.5'
allowed_failure: true
steps:
- name: "Set up PHP"
Expand Down
14 changes: 7 additions & 7 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,16 @@
}
],
"require": {
"php": ">=7.4",
"php": ">=8.3",
"ext-simplexml": "*"
},
"require-dev": {
"squizlabs/php_codesniffer": "^3.7",
"pestphp/pest": "^1.22",
"phpstan/phpstan": "^1.9",
"captainhook/captainhook": "^5",
"pestphp/pest": "^3.8",
"php-parallel-lint/php-parallel-lint": "^1.3",
"phpcompatibility/php-compatibility": "^9.3",
"captainhook/captainhook": "^5.11",
"php-parallel-lint/php-parallel-lint": "^1.3"
"phpcsstandards/php_codesniffer": "^3.13",
"phpstan/phpstan": "^2.1"
},
"autoload": {
"psr-4": {
Expand All @@ -47,7 +47,7 @@
"test:types": "@php ./vendor/bin/phpstan",
"test:style": "@php ./vendor/bin/phpcs",
"test:unit": "@php ./vendor/bin/pest",
"test:coverage": "@php ./vendor/bin/pest --coverage",
"test:coverage": "@php -dxdebug.mode=coverage ./vendor/bin/pest --coverage",
"test": [
"@test:style",
"@test:types",
Expand Down
1 change: 1 addition & 0 deletions phpcs.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

<!-- Additional arguments. -->
<arg value="sp"/>
<arg name="colors"/>
<arg name="basepath" value="."/>
<arg name="parallel" value="8"/>
<arg name="extensions" value="php"/>
Expand Down
3 changes: 0 additions & 3 deletions phpstan.neon.dist
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@ parameters:
level: max
paths:
- src

checkMissingIterableValueType: true
reportUnmatchedIgnoredErrors: true
universalObjectCratesClasses:
- SimpleXMLElement

36 changes: 17 additions & 19 deletions phpunit.xml
Original file line number Diff line number Diff line change
@@ -1,21 +1,19 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="./vendor/phpunit/phpunit/phpunit.xsd"
bootstrap="vendor/autoload.php"
colors="true"
>
<testsuites>
<testsuite name="Unit Test Suite">
<directory>./tests/Unit/</directory>
</testsuite>
</testsuites>
<coverage processUncoveredFiles="true">
<include>
<directory suffix=".php">./src</directory>
</include>
<report>
<clover outputFile="tests/coverage/clover.xml"/>
<html outputDirectory="tests/coverage/html" lowUpperBound="50" highLowerBound="90"/>
</report>
</coverage>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="./vendor/phpunit/phpunit/phpunit.xsd" bootstrap="vendor/autoload.php" colors="true" cacheDirectory=".phpunit.cache">
<testsuites>
<testsuite name="Unit Test Suite">
<directory>./tests/Unit/</directory>
</testsuite>
</testsuites>
<coverage>
<report>
<clover outputFile="tests/coverage/clover.xml"/>
<html outputDirectory="tests/coverage/html" lowUpperBound="50" highLowerBound="90"/>
</report>
</coverage>
<source>
<include>
<directory suffix=".php">./src</directory>
</include>
</source>
</phpunit>
Empty file removed src/Elements/.gitkeep
Empty file.
Loading
Loading