Unverified Commit c8d6a730 authored by Lauri Timmanee's avatar Lauri Timmanee
Browse files

Issue #3232550 by Wim Leers, hooroomoo, xjm, ravi.shankar: Improve messaging...

Issue #3232550 by Wim Leers, hooroomoo, xjm, ravi.shankar: Improve messaging about Internet Explorer 11

(cherry picked from commit 3744d21b)
parent d52f1478
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -38,7 +38,7 @@
        const ck5Warning = () => {
          selectMessages.add(
            Drupal.t(
              'CKEditor 5 is not compatible with Internet Explorer 11. Text fields using CKEditor 5 will still be editable but without the benefits of CKEditor.',
              'CKEditor 5 is not compatible with Internet Explorer. Text fields using CKEditor 5 will fall back to plain HTML editing without CKEditor for users of Internet Explorer.',
            ),
            {
              type: 'warning',
@@ -48,7 +48,7 @@
            // https://www.drupal.org/docs/system-requirements/browser-requirements
            selectMessages.add(
              Drupal.t(
                'Text editor toolbar settings are not available. They will be available in any <a href="@supported-browsers">supported browser</a> other than Internet Explorer',
                'Text editor toolbar settings are not available in Internet Explorer. They will be available in other <a href="@supported-browsers">supported browsers</a>.',
                {
                  '@supported-browsers':
                    'https://www.drupal.org/docs/system-requirements/browser-requirements',
+2 −2
Original line number Diff line number Diff line
@@ -19,12 +19,12 @@
        var editorSettings = document.querySelector('#editor-settings-wrapper');

        var ck5Warning = function ck5Warning() {
          selectMessages.add(Drupal.t('CKEditor 5 is not compatible with Internet Explorer 11. Text fields using CKEditor 5 will still be editable but without the benefits of CKEditor.'), {
          selectMessages.add(Drupal.t('CKEditor 5 is not compatible with Internet Explorer. Text fields using CKEditor 5 will fall back to plain HTML editing without CKEditor for users of Internet Explorer.'), {
            type: 'warning'
          });

          if (isIE11) {
            selectMessages.add(Drupal.t('Text editor toolbar settings are not available. They will be available in any <a href="@supported-browsers">supported browser</a> other than Internet Explorer', {
            selectMessages.add(Drupal.t('Text editor toolbar settings are not available in Internet Explorer. They will be available in other <a href="@supported-browsers">supported browsers</a>.', {
              '@supported-browsers': 'https://www.drupal.org/docs/system-requirements/browser-requirements'
            }), {
              type: 'error'
+5 −1
Original line number Diff line number Diff line
@@ -37,7 +37,11 @@
        const editorMessages = new Drupal.Message(editorMessageContainer);
        editorMessages.add(
          Drupal.t(
            'Internet Explorer 11 user: a rich text editor is available for this field when used with any other supported browser.',
            'A rich text editor is available for this field when used with <a href="@supported-browsers">supported browsers</a> other than Internet Explorer.',
            {
              '@supported-browsers':
                'https://www.drupal.org/docs/system-requirements/browser-requirements',
            },
          ),
          {
            type: 'warning',
+3 −1
Original line number Diff line number Diff line
@@ -15,7 +15,9 @@
        var editorMessageContainer = document.createElement('div');
        element.parentNode.insertBefore(editorMessageContainer, element);
        var editorMessages = new Drupal.Message(editorMessageContainer);
        editorMessages.add(Drupal.t('Internet Explorer 11 user: a rich text editor is available for this field when used with any other supported browser.'), {
        editorMessages.add(Drupal.t('A rich text editor is available for this field when used with <a href="@supported-browsers">supported browsers</a> other than Internet Explorer.', {
          '@supported-browsers': 'https://www.drupal.org/docs/system-requirements/browser-requirements'
        }), {
          type: 'warning'
        });
      },
+1 −1
Original line number Diff line number Diff line
@@ -410,7 +410,7 @@ public function testMediaElementAllowedTags() {
  public function testInternetExplorerWarning() {
    $page = $this->getSession()->getPage();
    $assert_session = $this->assertSession();
    $warning_text = 'CKEditor 5 is not compatible with Internet Explorer 11. Fields using CKEditor 5 will still be editable but without the benefits of CKEditor.';
    $warning_text = 'CKEditor 5 is not compatible with Internet Explorer. Text fields using CKEditor 5 will fall back to plain HTML editing without CKEditor for users of Internet Explorer.';
    $this->createNewTextFormat($page, $assert_session);
    $assert_session->waitForText($warning_text);
    $page->selectFieldOption('editor[editor]', 'None');