[BUGFIX] Render links in checkbox label in TYPO3 Forms#895
Open
dextar47 wants to merge 1 commit into
Open
Conversation
Contributor
Author
|
fixes #894 |
twoldanski
requested changes
May 28, 2026
twoldanski
left a comment
Collaborator
There was a problem hiding this comment.
Hi, first for all thanks for PR & letting us know about this new feature in TYPO3 forms. Please refactor code to support this feature in more abstract way, we should support more cases that only containing links (that can be limited in particular project, also should be used for this form decorators, we can easily adjust in different projects.
| // TYPO3 v14 introduced native RTE support for form element labels; without this step, | ||
| // labels containing internal page links would be output as raw t3://page?uid=X URIs | ||
| // instead of resolved frontend URLs. | ||
| $formDefinition = $this->resolveRteLinksInFormDefinition($formDefinition); |
Collaborator
There was a problem hiding this comment.
this should be in decorator
| * @param array<mixed> $formDefinition | ||
| * @return array<mixed> | ||
| */ | ||
| private function resolveRteLinksInFormDefinition(array $formDefinition): array |
Collaborator
There was a problem hiding this comment.
this should go to decorator
| $element['renderables'] = $this->resolveRteLinksInRenderables($element['renderables']); | ||
| } | ||
|
|
||
| // Only process labels that contain an internal TYPO3 URI — skip plain-text labels |
Collaborator
There was a problem hiding this comment.
this is most usable use case for this new feature, but, on ext:headless should handle all rte cases, this can be limited in project override, we should go more abstract.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Rendering of links inside checkbox label was not working. In TYPO3 14 LTS, now there is an RTE box for checkbox label. Links should be rendered for frontend JSON.