Skip to content

Commit

Permalink
Prerelease
Browse files Browse the repository at this point in the history
  • Loading branch information
Ronef committed Jun 3, 2023
1 parent ee21674 commit 9cb5f6a
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 5 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
# (MODX)EvolutionCMS.snippets.ddIf changelog


## Version 2.3.1 (2023-06-03)
* \* Compatibility with PHP < 8.
* \* Parameters → `trueChunk`, `falseChunk` → Placeholders: The following have been renamed (outdated names are still supported, but are not recommended):
* \* `[+snippetParams.operand1+]` → `[+ddIfParams.operand1+]`.
* \* `[+snippetParams.operand2+]` → `[+ddIfParams.operand2+]`.
* \* `[+snippetParams.operator+]` → `[+ddIfParams.operator+]`.


## Version 2.3 (2023-06-03)
* \+ Parameters → `operator` → Valid values → `'isIncludes'`: The new valid value. Case-sensitive check if `operand1` contains `operand2` (see README → Examples).
* \* `\ddTools::getTpl` is used instead of `$modx->getTpl` (means a bit less bugs).
Expand Down
8 changes: 8 additions & 0 deletions CHANGELOG_ru.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
# (MODX)EvolutionCMS.snippets.ddIf changelog


## Версия 2.3.1 (2023-06-03)
* \* Совместимость с PHP < 8.
* \* Параметры → `trueChunk`, `falseChunk` → Плейсхолдеры: Следующие были переименованы (старые названия все ещё поддерживаются, но не рекомендуются):
* \* `[+snippetParams.operand1+]` → `[+ddIfParams.operand1+]`.
* \* `[+snippetParams.operand2+]` → `[+ddIfParams.operand2+]`.
* \* `[+snippetParams.operator+]` → `[+ddIfParams.operator+]`.


## Версия 2.3 (2023-06-03)
* \+ Параметры → `operator` → Допустимые значения → `'isIncludes'`: Новое значение. Проверяет, содержит ли `operand1` в себе `operand2` с учётом регистра, (см. README → Примеры).
* \* `\ddTools::getTpl` используется вместо `$modx->getTpl` (стало чуть меньше багов).
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ require_once(
#### 1. Elements → Snippets: Create a new snippet with the following data

1. Snippet name: `ddIf`.
2. Description: `<b>2.3</b> This snippet compares different values and returns required chunk or string.`.
2. Description: `<b>2.3.1</b> This snippet compares different values and returns required chunk or string.`.
3. Category: `Core`.
4. Parse DocBlock: `no`.
5. Snippet code (php): Insert content of the `ddIf_snippet.php` file from the archive.
Expand Down
2 changes: 1 addition & 1 deletion README_ru.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ require_once(
#### 1. Элементы → Сниппеты: Создайте новый сниппет со следующими параметрами

1. Название сниппета: `ddIf`.
2. Описание: `<b>2.3</b> Сравнивает значения и выводит необходимый чанк или строку.`.
2. Описание: `<b>2.3.1</b> Сравнивает значения и выводит необходимый чанк или строку.`.
3. Категория: `Core`.
4. Анализировать DocBlock: `no`.
5. Код сниппета (php): Вставьте содержимое файла `ddIf_snippet.php` из архива.
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "dd/evolutioncms-snippets-ddif",
"type": "modxevo-snippet",
"version": "2.3.0",
"version": "2.3.1",
"description": "This snippet compares different values and returns required chunk or string.",
"keywords": [
"modx",
Expand Down
2 changes: 1 addition & 1 deletion ddIf_snippet.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php
/**
* ddIf
* @version 2.3 (2023-06-03)
* @version 2.3.1 (2023-06-03)
*
* @see README.md
*
Expand Down
2 changes: 1 addition & 1 deletion src/Snippet.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

class Snippet extends \DDTools\Snippet {
protected
$version = '2.3.0',
$version = '2.3.1',

$params = [
//Defaults
Expand Down

0 comments on commit 9cb5f6a

Please sign in to comment.