• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

CPS-IT / handlebars-forms / 22340918685

24 Feb 2026 07:26AM UTC coverage: 0.0%. Remained the same
22340918685

push

github

eliashaeussler
[TASK] Add ViewHelper arguments to CountrySelect and Select processors

0 of 20 new or added lines in 2 files covered. (0.0%)

45 existing lines in 2 files now uncovered.

0 of 484 relevant lines covered (0.0%)

0.0 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/Classes/DataProcessing/Renderable/TextfieldRenderableProcessor.php
1
<?php
2

3
declare(strict_types=1);
4

5
/*
6
 * This file is part of the TYPO3 CMS extension "handlebars_forms".
7
 *
8
 * It is free software; you can redistribute it and/or modify it under
9
 * the terms of the GNU General Public License, either version 2
10
 * of the License, or any later version.
11
 *
12
 * For the full copyright and license information, please read the
13
 * LICENSE.txt file that was distributed with this source code.
14
 *
15
 * The TYPO3 project - inspiring people to share!
16
 */
17

18
namespace CPSIT\Typo3HandlebarsForms\DataProcessing\Renderable;
19

20
use TYPO3\CMS\Fluid;
21
use TYPO3\CMS\Form;
22

23
/**
24
 * TextfieldRenderableProcessor
25
 *
26
 * @author Elias Häußler <e.haeussler@familie-redlich.de>
27
 * @license GPL-2.0-or-later
28
 *
29
 * @extends AbstractRenderableProcessor<Form\Domain\Model\FormElements\FormElementInterface>
30
 */
31
final class TextfieldRenderableProcessor extends AbstractRenderableProcessor
32
{
33
    protected array $supportedTypes = [
34
        'Date',
35
        'Email',
36
        'Number',
37
        'Telephone',
38
        'Text',
39
        'Url',
40
    ];
41

42
    public function process(
×
43
        Form\Domain\Model\Renderable\RootRenderableInterface $renderable,
44
        Fluid\Core\Rendering\RenderingContext $renderingContext,
45
    ): RenderableViewModel {
46
        $additionalAttributes = $this->renderAdditionalAttributes($renderingContext, $renderable);
×
47
        $result = $this->viewHelperInvoker->invoke(
×
48
            $renderingContext,
×
49
            Fluid\ViewHelpers\Form\TextfieldViewHelper::class,
×
50
            [
×
51
                'type' => match ($renderable->getType()) {
×
52
                    'Date' => 'date',
×
53
                    'Email' => 'email',
×
54
                    'Number' => 'number',
×
UNCOV
55
                    'Telephone' => 'tel',
×
56
                    'Url' => 'url',
×
57
                    default => 'text',
×
UNCOV
58
                },
×
UNCOV
59
                'property' => $renderable->getIdentifier(),
×
60
                'id' => $renderable->getUniqueIdentifier(),
×
UNCOV
61
                'class' => $renderable->getProperties()['elementClassAttribute'] ?? null,
×
UNCOV
62
                'errorClass' => $renderable->getProperties()['elementErrorClassAttribute'] ?? null,
×
UNCOV
63
                'additionalAttributes' => $additionalAttributes,
×
UNCOV
64
            ],
×
UNCOV
65
        );
×
66

UNCOV
67
        foreach ($additionalAttributes as $name => $value) {
×
UNCOV
68
            $result->tag->addAttribute($name, $value);
×
69
        }
70

UNCOV
71
        return new RenderableViewModel($renderingContext, $result->content, $result->tag);
×
72
    }
73
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc