Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
project
drupal
Commits
16a374d4
Unverified
Commit
16a374d4
authored
Feb 28, 2022
by
lauriii
Browse files
Issue
#3266310
by bnjmnm, Wim Leers, longwave: IE11 user warning has ungraceful failures
parent
c20ea2ac
Changes
4
Hide whitespace changes
Inline
Side-by-side
core/modules/ckeditor5/js/ckeditor5.es6.js
View file @
16a374d4
...
...
@@ -4,6 +4,13 @@
*/
/* global CKEditor5 */
((
Drupal
,
debounce
,
CKEditor5
,
$
,
once
)
=>
{
// CKEditor 5 is incompatible with IE11. When IE11 is detected, the CKEditor5
// variable is null. In those instances, exit early since CKEditor 5 is not
// loaded.
if
(
!
CKEditor5
)
{
return
;
}
/**
* The CKEDITOR instances.
*
...
...
core/modules/ckeditor5/js/ckeditor5.js
View file @
16a374d4
...
...
@@ -34,6 +34,10 @@ function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToAr
function
_arrayLikeToArray
(
arr
,
len
)
{
if
(
len
==
null
||
len
>
arr
.
length
)
len
=
arr
.
length
;
for
(
var
i
=
0
,
arr2
=
new
Array
(
len
);
i
<
len
;
i
++
)
{
arr2
[
i
]
=
arr
[
i
];
}
return
arr2
;
}
(
function
(
Drupal
,
debounce
,
CKEditor5
,
$
,
once
)
{
if
(
!
CKEditor5
)
{
return
;
}
Drupal
.
CKEditor5Instances
=
new
Map
();
var
callbacks
=
new
Map
();
var
required
=
new
Set
();
...
...
core/modules/ckeditor5/js/ie11.user.warnings.es6.js
View file @
16a374d4
...
...
@@ -14,6 +14,11 @@
// created. Features such as Quick Edit that require the presence of a
// Drupal.editors.ckeditor5, even for fields that do not use CKEditor 5.
if
(
isIE11
)
{
// Explicitly set the global CKEditor5 object to null. This ensures code
// expecting the existence of the object does not fail, but is easily
// distinguishable from a valid CKEditor5 object.
window
.
CKEditor5
=
null
;
// This will reference a MutationObserver used by several functions in
// Drupal.editors.ckeditor5. It is declared here and not the editor object
// in order to work with IE11 object scope.
...
...
core/modules/ckeditor5/js/ie11.user.warnings.js
View file @
16a374d4
...
...
@@ -9,6 +9,7 @@
var
isIE11
=
Modernizr
.
mq
(
'
(-ms-high-contrast: active), (-ms-high-contrast: none)
'
);
if
(
isIE11
)
{
window
.
CKEditor5
=
null
;
var
quickEditLabelObserver
=
null
;
Drupal
.
editors
.
ckeditor5
=
{
attach
:
function
attach
(
element
)
{
...
...
lauriii
@lauriii
mentioned in commit
802ec71e
·
Feb 28, 2022
mentioned in commit
802ec71e
mentioned in commit 802ec71e249bfd6ab47792906cf899d3d7c81ed9
Toggle commit list
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment