@ckeditor/ckeditor5-engine 47.4.0-alpha.4 → 47.4.0-alpha.5

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ckeditor/ckeditor5-engine",
3
- "version": "47.4.0-alpha.4",
3
+ "version": "47.4.0-alpha.5",
4
4
  "description": "The editing engine of CKEditor 5 – the best browser-based rich text editor.",
5
5
  "keywords": [
6
6
  "wysiwyg",
@@ -24,7 +24,7 @@
24
24
  "type": "module",
25
25
  "main": "src/index.js",
26
26
  "dependencies": {
27
- "@ckeditor/ckeditor5-utils": "47.4.0-alpha.4",
27
+ "@ckeditor/ckeditor5-utils": "47.4.0-alpha.5",
28
28
  "es-toolkit": "1.39.5"
29
29
  },
30
30
  "author": "CKSource (http://cksource.com/)",
@@ -546,17 +546,7 @@ function shouldMarkerChangeBeConverted(modelPosition, marker, mapper) {
546
546
  const hasCustomHandling = ancestors.some(element => {
547
547
  if (range.containsItem(element)) {
548
548
  const viewElement = mapper.toViewElement(element);
549
- if (viewElement) {
550
- return !!viewElement.getCustomProperty('addHighlight');
551
- }
552
- // Technically, a marker can be created on an element that doesn't have a corresponding view element.
553
- // This happens, for example, with the `title` element, which exists in the model but doesn't have
554
- // a direct view representation (only its child `title-content` is converted to `<h1>` in the view).
555
- // In such cases, we return `false` to indicate that there's no custom handling, allowing the marker
556
- // conversion to proceed normally.
557
- else {
558
- return false;
559
- }
549
+ return !!viewElement.getCustomProperty('addHighlight');
560
550
  }
561
551
  });
562
552
  return !hasCustomHandling;