From 92e04f101c60da48fc7158d6d47ec0b39870cc04 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andrzej=20Ko=C5=82buc?= <a.kolbuc@macopedia.com>
Date: Fri, 13 Aug 2021 09:28:33 +0200
Subject: [PATCH] [BUGFIX] Remove unnecessary html tags

Labels are rendered by CshViewHelper which do htmlspecialchars on it. Next step todo is change whole additional fields layout and prepare translations.

Resolves: #93888
Releases: master, 10.4
Change-Id: I19d12951a030977384ee3a923823990fe97e9211
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/70536
Tested-by: core-ci <typo3@b13.com>
Tested-by: kharaf <k.haraf@macopedia.com>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: kharaf <k.haraf@macopedia.com>
Reviewed-by: Rudy Gnodde <rudy@famouswolf.com>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
---
 .../ExecuteSchedulableCommandAdditionalFieldProvider.php  | 8 ++++----
 .../scheduler/Resources/Private/Language/locallang.xlf    | 2 +-
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/typo3/sysext/scheduler/Classes/Task/ExecuteSchedulableCommandAdditionalFieldProvider.php b/typo3/sysext/scheduler/Classes/Task/ExecuteSchedulableCommandAdditionalFieldProvider.php
index 429aef5f5426..576209f9bfb3 100644
--- a/typo3/sysext/scheduler/Classes/Task/ExecuteSchedulableCommandAdditionalFieldProvider.php
+++ b/typo3/sysext/scheduler/Classes/Task/ExecuteSchedulableCommandAdditionalFieldProvider.php
@@ -230,7 +230,7 @@ class ExecuteSchedulableCommandAdditionalFieldProvider implements AdditionalFiel
     {
         return [
             'code' => '',
-            'label' => '<strong>' . $description . '</strong>'
+            'label' => $description
         ];
     }
 
@@ -324,7 +324,7 @@ class ExecuteSchedulableCommandAdditionalFieldProvider implements AdditionalFiel
      */
     protected function getArgumentLabel(InputArgument $argument): string
     {
-        return 'Argument: ' . $argument->getName() . '. <em>' . htmlspecialchars($argument->getDescription()) . '</em>';
+        return 'Argument: ' . $argument->getName() . '. ' . htmlspecialchars($argument->getDescription());
     }
 
     /**
@@ -335,7 +335,7 @@ class ExecuteSchedulableCommandAdditionalFieldProvider implements AdditionalFiel
      */
     protected function getOptionLabel(InputOption $option): string
     {
-        return 'Option: ' . htmlspecialchars($option->getName()) . '. <em>' . htmlspecialchars($option->getDescription()) . '</em>';
+        return 'Option: ' . htmlspecialchars($option->getName()) . '. ' . htmlspecialchars($option->getDescription());
     }
 
     /**
@@ -428,7 +428,7 @@ class ExecuteSchedulableCommandAdditionalFieldProvider implements AdditionalFiel
             $inputTag->addAttribute('type', 'text');
             $inputTag->addAttribute('value', $currentValue);
             $inputTag->addAttribute('class', 'form-control');
-            $html .=  $inputTag->render();
+            $html .= $inputTag->render();
         }
 
         return $html;
diff --git a/typo3/sysext/scheduler/Resources/Private/Language/locallang.xlf b/typo3/sysext/scheduler/Resources/Private/Language/locallang.xlf
index 718f6c51a52d..c8411adb9c10 100644
--- a/typo3/sysext/scheduler/Resources/Private/Language/locallang.xlf
+++ b/typo3/sysext/scheduler/Resources/Private/Language/locallang.xlf
@@ -184,7 +184,7 @@
 				<source>Amount of tasks without found class</source>
 			</trans-unit>
 			<trans-unit id="label.schedulableCommandName" resname="label.schedulableCommandName">
-				<source><![CDATA[Schedulable Command. <em>Save and reopen to define command arguments</em>]]></source>
+				<source>Schedulable Command. Save and reopen to define command arguments</source>
 			</trans-unit>
 			<trans-unit id="label.saveAndCreateNewTask" resname="label.saveAndCreateNewTask">
 				<source>Save and create new task</source>
-- 
GitLab