November Happy Hour will be moved to Thursday December 5th.

Triggering autosave event/ change to element in UI (visual mode)

Vote:
 

Hi,

My colleague is trying to use the visual editor in Edit view a bit creatively. What he wants to do is to be able to write to a block property (with jQuery/ JS) and then have Edit autosave/ listen to changes on this property like it would normally for a string property if you start typing into the input area.

What happens (of course), is that UI doesn't pick up on any writing to the element with jQuery (using .html()), and so when you move the cursor to the input area and click your mouse, the whole field is cleared.

Now, I've been reading a bit on dojo and widgets, and I'd assume there is no clear workaround for this, but I'm making this post in case there is a simple way to make the UI pick up on changes to an element.

Thoughts on this? Or, if no direct way, tips to another approach? (I have a bunch of links but some guidance would be really appreciated.)

#186769
Jan 04, 2018 10:28
Vote:
 

You might want to look at the new OPE features

https://world.episerver.com/blogs/john-philip-johansson/dates/2017/10/taking-control-of-client-side-rendering-in-ope-beta/

https://world.episerver.com/blogs/john-philip-johansson/dates/2017/12/taking-more-control-of-client-side-rendering-in-ope-beta2/

They are designed to allow you to take control via front end frameworks of editing and rendering.

#186779
Jan 04, 2018 12:22
Vote:
 

Thanks. This looks like a good option for a future solution.

For now it looks like the only way to do this is to 'do it properly' (creating an UI solution which is properly integrated). (Which is probably a good thing!)

#186887
Jan 08, 2018 12:30
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.