Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.

Problem includes component with responsiveGrid in edit mode (author)

Avatar

Level 1

Hi guys,

I have this error message in screen when i try to include a new component that has a responsiveGrid inside:

Uncaught (in promise) TypeError: editable.getParentPath is not a function

    at Array.ns.editables.self.getParent (core.min.62a4d5c92159bcf5ed8650762d1c1809.js:30061)

    at Object.ns.overlayManager.self.create (core.min.62a4d5c92159bcf5ed8650762d1c1809.js:18342)

    at Object.ns.overlayManager.self.recreate (core.min.62a4d5c92159bcf5ed8650762d1c1809.js:18393)

    at HTMLDocument.ns.overlayManager.self.recreateAll (core.min.62a4d5c92159bcf5ed8650762d1c1809.js:18409)

    at HTMLDocument.dispatch (jquery.min.5e8d3382f82b03b0bf3fea3024eecd61.js:124)

    at HTMLDocument.h.handle (jquery.min.5e8d3382f82b03b0bf3fea3024eecd61.js:117)

    at Object.trigger (jquery.min.5e8d3382f82b03b0bf3fea3024eecd61.js:122)

    at HTMLDocument.<anonymous> (jquery.min.5e8d3382f82b03b0bf3fea3024eecd61.js:137)

    at Function.each (jquery.min.5e8d3382f82b03b0bf3fea3024eecd61.js:50)

    at c.fn.init.each (jquery.min.5e8d3382f82b03b0bf3fea3024eecd61.js:46)

I debuged the code, and i found a new function in core.js added in 6.4 SP 2, that i believe has a code error.

In this function: function excludeDescendants(editables).

I have a array of objects, like [{name : 'diego'}, {name: 'john'}], then the code do a splice in last position, returning a new array.

Then the code build a new array and push the return of splice.

Like this:

var arr = [];

var new2 = [{name : 'diego'}, {name: 'john'}].splice(1,1);

arr.push(new2);

return arr;

And then the code try call getParentPath from this array. But this array in first position is another array not a object. Try in console.

I think the solution is var new2 = [{name : 'diego'}, {name: 'john'}].splice(1,1)[0];

Thank you

Diego

3 Replies

Avatar

Level 10

Please report this to customer care so it can be addressed by Eng. This should be fixed.

Avatar

Level 1

Ok. I dont have acess to do that, but i ask to other guy.

Avatar

Level 1

We're experiencing the same issue.

Components with responsive grids or parsys have errors when being inserted into a page.

This prevents event listeners (afterinsert, afterchildinsert...) to be triggered.

core.js:30103 Uncaught (in promise) TypeError: editable.getParentPath is not a function
     at Array.ns.editables.self.getParent (core.js:30103)
     at Object.ns.overlayManager.self.create (core.js:18384)
     at Object.ns.overlayManager.self.recreate (core.js:18435)
     at HTMLDocument.ns.overlayManager.self.recreateAll (core.js:18451)
     at HTMLDocument.dispatch (jquery.js:5226)
     at HTMLDocument.elemData.handle (jquery.js:4878)
     at Object.trigger (jquery.js:5130)
     at HTMLDocument. (jquery.js:5860)
     at Function.each (jquery.js:370)
     at jQuery.fn.init.each (jquery.js:137)

If in core#recreateAll, we do this after the following line for the affected component:

var editables = excludeDescendants((cfg && cfg.editables) || []);
/* FIX splice problem for the component */editables[0] = editables[0][0];

Component will behave as expected.

So I can confirm that problem is related with the splice statement as suggested in the initial comment.

Was the problem finally reported? is there any status on the progress?

Best regards