Skip to content

Commit 9c037b4

Browse files
smnandrekbond
authored andcommitted
[Icons] Accept <twig:ux:icon /> (lowercase)
1 parent b237367 commit 9c037b4

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/Icons/src/Twig/UXIconComponentListener.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ public function __construct(
2828

2929
public function onPreCreateForRender(PreCreateForRenderEvent $event): void
3030
{
31-
if ('UX:Icon' !== $event->getName()) {
31+
if ('ux:icon' !== strtolower($event->getName())) {
3232
return;
3333
}
3434

src/Icons/tests/Fixtures/templates/template1.html.twig

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<li id="second">{{ ux_icon('user') }}</li>
44
<li id="third">{{ ux_icon('sub:check', {'data-action': 'string "with" quotes'}) }}</li>
55
<li id="fifth"><twig:UX:Icon name="user" class="h-8 w-8" /></li>
6-
<li id="sixth"><twig:UX:Icon name="sub:check" /></li>
7-
<li id="seventh"><twig:UX:Icon :name="'sub:'~'check'" /></li>
6+
<li id="sixth"><twig:ux:icon name="sub:check" /></li>
7+
<li id="seventh"><twig:Ux:Icon :name="'sub:'~'check'" /></li>
88
<li id="eighth">{{ ux_icon('iconamoon:3d-duotone') }}</li>
99
</ul>

0 commit comments

Comments
 (0)