Unplanned
Last Updated: 05 Apr 2024 05:04 by ADMIN
Charles
Created on: 29 Mar 2024 08:16
Category: Editor
Type: Bug Report
2
The drag and drop of an image in the kendo editor for jQuery in inlineEditing

Hello,

I have an issue when I use the drag and drop of a picture in the kendo Editor inline.

Let me explain it :

1) Go to : https://runner.telerik.io/fullscreen/uWosAbib (It's the standard example on your site) on chrome 123

2) Select the last editor "Rich UI Widgets for..."

3) Take a file of a picture on your computer and drop it on the first editor "Comprehensive HTML5/..."

Two things :

* The file open on a new tab browser instead of to be added to the html of the first editor

* There is a message in the debug tools (The stack trace is added in the Attach Files)

Uncaught TypeError: Cannot read properties of null (reading 'nodeType')
    at init.index (kendo.all.js:135127:1)

Another element, if you don't select and just drag and drop it's work.

Thank you for your awesome framework and good luck with the correction !

2 comments
ADMIN
Neli
Posted on: 05 Apr 2024 05:04

Hello Charles,

Thank you very much for reporting the behavior and for the suggested fix. 

I am changing the status of the item to 'Unplanned'. I will also leave a comment in the related GitHub issue with the suggested fix. 

As a token of gratitude for reporting the bug, I have updated your Telerik points.

Regards,
Neli
Progress Telerik

Stay tuned by visiting our public roadmap and feedback portal pages! Or perhaps, if you are new to our Kendo family, check out our getting started resources
Charles
Posted on: 29 Mar 2024 09:54

I have made this patch to correct the issue

 

diff --git a/esm/kendo.editor.js b/esm/kendo.editor.js
index 58d819d86540935360adbc100d691e5db71c273e..51f030ead0e2e4fee39366d38ebd6c704bf3796a 100644
--- a/esm/kendo.editor.js
+++ b/esm/kendo.editor.js
@@ -4998,9 +4998,9 @@ var RestorePoint = Class.extend({
nodeToPath: function(node) {
var path = [];

- while (node != this.rootNode) {
+ while (node !== null && node != this.rootNode) {
path.push(this.index(node));
- node = node.parentNode;
+ node = node?.parentNode;
}

return path;