Problem/Motivation
Translations error's
> [notice] nl -vertaling gedownload voor webform_workflows_element.
> [error] Import of string "</div>" was skipped because of disallowed or malformed HTML.
> [error] Import of string "<div><b>Beginstatus voor nieuwe inzendingen: </b>" was skipped because of disallowed or malformed HTML.
Steps to reproduce
Instal Drupal Core & Webform Workflow elements.
Use a different interface language. Get the translated interface translation, for example Dutch.
Proposed resolution
Don't use structured HTML in a translation. So remove <div>'s.
WorkflowsSummaryController.php
row 451:
'initial_state' => [
'#type' => 'markup',
'#prefix' => t('<div><b>Initial state for new submissions: </b>'),
'#markup' => '<span class="webform-workflow-state-label with-color ' . webform_workflows_element_get_color_class_for_state_from_element($element, $initialState->id()) . '">' . $initialState->label() . '</span>',
'#suffix' => t('</div>'),
],
Remaining tasks
Write patch / merge request
User interface changes
-
API changes
-
Data model changes
-
Comments
Comment #3
martijn de witMoved the t() to the #markup and removed translation from prefix and suffix
Comment #4
maxwellkeeble commentedThanks, this has been fixed in the latest dev.
Comment #6
martijn de witThank you for the quick response!