Skip to content
This repository was archived by the owner on Oct 15, 2025. It is now read-only.

Commit 893ecea

Browse files
committed
refactor(challenge): Make AnswerQueryResult static
It seldom changes.
1 parent 19987b2 commit 893ecea

File tree

1 file changed

+3
-8
lines changed

1 file changed

+3
-8
lines changed

src/Twig/Components/Challenge/Tabs/AnswerQueryResult.php

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,26 +7,21 @@
77
use App\Entity\ChallengeDto\FallableQueryResultDto;
88
use App\Entity\Question;
99
use App\Service\QuestionDbRunnerService;
10-
use Symfony\UX\LiveComponent\Attribute\AsLiveComponent;
11-
use Symfony\UX\LiveComponent\Attribute\LiveProp;
12-
use Symfony\UX\LiveComponent\DefaultActionTrait;
10+
use Symfony\UX\TwigComponent\Attribute\AsTwigComponent;
1311

1412
use function Symfony\Component\Translation\t;
1513

16-
#[AsLiveComponent]
14+
#[AsTwigComponent]
1715
final class AnswerQueryResult
1816
{
19-
use DefaultActionTrait;
20-
2117
public function __construct(
2218
private readonly QuestionDbRunnerService $questionDbRunnerService,
2319
) {
2420
}
2521

2622
/**
27-
* @var Question $question the question to present the answer
23+
* @var Question the question to present the answer
2824
*/
29-
#[LiveProp]
3025
public Question $question;
3126

3227
public function getAnswer(): FallableQueryResultDto

0 commit comments

Comments
 (0)