@ckeditor/ckeditor5-engine 47.6.0-alpha.8 → 47.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -9799,7 +9799,7 @@ const UNSAFE_ELEMENT_REPLACEMENT_ATTRIBUTE = 'data-ck-unsafe-element';
9799
9799
  if (attributeKey.startsWith('on')) {
9800
9800
  return false;
9801
9801
  }
9802
- if (attributeKey === 'srcdoc' && attributeValue.match(/\bon\S+\s*=|javascript:|<\s*\/*script/i)) {
9802
+ if (attributeKey === 'srcdoc') {
9803
9803
  return false;
9804
9804
  }
9805
9805
  if (elementName === 'img' && (attributeKey === 'src' || attributeKey === 'srcset')) {
@@ -9808,7 +9808,7 @@ const UNSAFE_ELEMENT_REPLACEMENT_ATTRIBUTE = 'data-ck-unsafe-element';
9808
9808
  if (elementName === 'source' && attributeKey === 'srcset') {
9809
9809
  return true;
9810
9810
  }
9811
- if (attributeValue.match(/^\s*(javascript:|data:(image\/svg|text\/x?html))/i)) {
9811
+ if (attributeValue.replace(/\s+/g, '').match(/^(javascript:|data:(image\/svg|text\/x?html))/i)) {
9812
9812
  return false;
9813
9813
  }
9814
9814
  return true;