diff --git a/core/modules/ckeditor/src/Plugin/CKEditorPlugin/Internal.php b/core/modules/ckeditor/src/Plugin/CKEditorPlugin/Internal.php
index 1d3690e..2385511 100644
--- a/core/modules/ckeditor/src/Plugin/CKEditorPlugin/Internal.php
+++ b/core/modules/ckeditor/src/Plugin/CKEditorPlugin/Internal.php
@@ -9,7 +9,6 @@
use Drupal\ckeditor\CKEditorPluginBase;
use Drupal\Component\Utility\NestedArray;
-use Drupal\Component\Utility\SafeMarkup;
use Drupal\Core\Cache\Cache;
use Drupal\Core\Cache\CacheBackendInterface;
use Drupal\Core\Plugin\ContainerFactoryPluginInterface;
@@ -131,7 +130,15 @@ public function getButtons() {
// In the markup below, we mostly use the name (which may include spaces),
// but in one spot we use it as a CSS class, so strip spaces.
$class_name = str_replace(' ', '', $name);
- return SafeMarkup::format('@name', ['@direction' => $direction, '@name' => $name, '@classname' => $class_name]);
+ return [
+ '#type' => 'inline_template',
+ '#template' => '{{ name }}',
+ '#context' => [
+ 'direction' => $direction,
+ 'name' => $name,
+ 'classname' => $class_name,
+ ],
+ ];
};
return array(
@@ -260,7 +267,13 @@ public function getButtons() {
),
'Format' => array(
'label' => t('HTML block format'),
- 'image_alternative' => SafeMarkup::format('@format_text', ['@format_text' => t('Format')]),
+ 'image_alternative' => [
+ '#type' => 'inline_template',
+ '#template' => '{{ format_text }}',
+ '#context' => [
+ 'format_text' => t('Format'),
+ ],
+ ],
),
// "table" plugin.
'Table' => array(
@@ -286,7 +299,13 @@ public function getButtons() {
// No plugin, separator "button" for toolbar builder UI use only.
'-' => array(
'label' => t('Separator'),
- 'image_alternative' => SafeMarkup::format('', ['@button_separator_text' => t('Button separator')]),
+ 'image_alternative' => [
+ '#type' => 'inline_template',
+ '#template' => '',
+ '#context' => [
+ 'button_separator_text' => t('Button separator'),
+ ],
+ ],
'attributes' => array(
'class' => array('ckeditor-button-separator'),
'data-drupal-ckeditor-type' => 'separator',
diff --git a/core/modules/ckeditor/src/Plugin/CKEditorPlugin/StylesCombo.php b/core/modules/ckeditor/src/Plugin/CKEditorPlugin/StylesCombo.php
index a260702..d3eb49f 100644
--- a/core/modules/ckeditor/src/Plugin/CKEditorPlugin/StylesCombo.php
+++ b/core/modules/ckeditor/src/Plugin/CKEditorPlugin/StylesCombo.php
@@ -10,7 +10,6 @@
use Drupal\ckeditor\CKEditorPluginBase;
use Drupal\ckeditor\CKEditorPluginConfigurableInterface;
use Drupal\Component\Utility\NestedArray;
-use Drupal\Component\Utility\SafeMarkup;
use Drupal\Core\Form\FormStateInterface;
use Drupal\editor\Entity\Editor;
@@ -60,7 +59,13 @@ public function getButtons() {
return array(
'Styles' => array(
'label' => t('Font style'),
- 'image_alternative' => SafeMarkup::format('@styles_text', ['@styles_text' => t('Styles')]),
+ 'image_alternative' => [
+ '#type' => 'inline_template',
+ '#template' => '{{ styles_text }}',
+ '#context' => [
+ 'styles_text' => t('Styles'),
+ ],
+ ],
),
);
}