Skip to content

Commit eeddf9e

Browse files
committed
Latte: sets Tag::$node
1 parent 7111406 commit eeddf9e

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

composer.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
"nette/forms": "^3.0",
3232
"nette/robot-loader": "^3.2 || ^4.0",
3333
"nette/security": "^3.0",
34-
"latte/latte": "^2.10.2 || ^3.0.3",
34+
"latte/latte": "^2.10.2 || ^3.0.12",
3535
"tracy/tracy": "^2.6",
3636
"mockery/mockery": "^1.0",
3737
"phpstan/phpstan-nette": "^0.12",
@@ -42,7 +42,7 @@
4242
"nette/di": "<3.0.7",
4343
"nette/forms": "<3.0",
4444
"nette/schema": "<1.2",
45-
"latte/latte": "<2.7.1 || >=3.0.0 <3.0.8 || >=3.1",
45+
"latte/latte": "<2.7.1 || >=3.0.0 <3.0.12 || >=3.1",
4646
"tracy/tracy": "<2.5"
4747
},
4848
"autoload": {

src/Bridges/ApplicationLatte/Nodes/IfCurrentNode.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ class IfCurrentNode extends StatementNode
3131
public static function create(Tag $tag): \Generator
3232
{
3333
trigger_error("Tag {ifCurrent} is deprecated, use {if isLinkCurrent('...')} instead (on line {$tag->position->line})", E_USER_DEPRECATED);
34-
$node = new static;
34+
$node = $tag->node = new static;
3535
if (!$tag->parser->isEnd()) {
3636
$node->destination = $tag->parser->parseUnquotedStringOrExpression();
3737
$tag->parser->stream->tryConsume(',');

src/Bridges/ApplicationLatte/Nodes/SnippetAreaNode.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class SnippetAreaNode extends StatementNode
3434
/** @return \Generator<int, ?array, array{AreaNode, ?Tag}, static> */
3535
public static function create(Tag $tag, TemplateParser $parser): \Generator
3636
{
37-
$node = new static;
37+
$node = $tag->node = new static;
3838
$name = $tag->parser->parseUnquotedStringOrExpression();
3939
if (
4040
$name instanceof Expression\ClassConstantFetchNode

src/Bridges/ApplicationLatte/Nodes/SnippetNode.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ public static function create(Tag $tag, TemplateParser $parser): \Generator
4141
{
4242
$tag->outputMode = $tag::OutputKeepIndentation;
4343

44-
$node = new static;
44+
$node = $tag->node = new static;
4545
$node->htmlElement = $tag->isNAttribute() ? $tag->htmlElement : null;
4646

4747
if ($tag->parser->isEnd()) {

0 commit comments

Comments
 (0)