dialog - How to change persistence property of cq:inplaceEditing -


i wish use cq:inplaceediting modify property on jcr whenever used aem authors. unfortunately, not know how modify name of property modifies in jcr. appears modifies value of property "text" default.

for purposes, want use rich-text-editing properties have names define, not default name "text."

the image @ link shows tree contains cq:inplaceediting (courtesy of crxde):

enter image description here

these attributes of cq:editconfig:

enter image description here

these attributes of cq:inplaceediting:

enter image description here

...and content node of jcr looks when use inplaceeditor. i've blotted out names of properties potential security reasons. note "text" property below changed when used inplaceeditor. note want able define property name inplaceeditor changes, rather "text" property:

enter image description here

is there way use different property name instead of "text"?

-----------edit----------

after changing property "textpropertyname" property searching for, still doesn't appear modify behavior of inplaceeditor. still modifies "text" property of jcr nodes instead of 1 put in "textpropertyname" attribute.

this picture contains attributes of cq:inplaceeditingconfig:

enter image description here

the picture below contains attributes of jcr node @ path specified in "configpath" variable in picture above. note set textpropertyname attribute in node , text component still modifies default attribute "text" instead of 1 specified:

enter image description here

finally, picture below shows contents of jcr tree inside of text component.

enter image description here

-----------another edit----------

i discovered inline text editor persisting correct property after had switched classic ui. reason, doesn't work correctly touch ui.

how find it

the inplace editing capability defined subclasses of cq.ipe.inplaceediting function. can find searching editortype through crxde tool.

searching cq.ipe.inplaceediting returns multiple results such cq.ipe.texteditor @ end of script registers desired editortype i.e.: cq.ipe.inplaceediting.register("text", cq.ipe.texteditor);

the answer

reading through editor code can find first configurable property called textpropertyname according it's documentation looking for. combining inplace configuration node (see adobe's documentation) solution case.

an example

you can try on instance of geometrixx component.

  1. first go crxde , find geometrixx text component: /apps/geometrixx-gov/components/text.
  2. notice /apps/geometrixx-gov/components/text/cq:editconfig/cq:inplaceediting@configpath property value.
  3. find /apps/geometrixx-gov/components/text/dialog/items/tab1/items/text resource , add new property: textpropertyname=mypropertyname.
  4. then open geometrixx gov page add geometrixx text component, edit inplace , network console. you'll notice post request altered parameter name

edit after touchui clarification

touchui case

if want achieve same touchui interface doesn't go easy, unfortunately. text inplace editor touchui defined /libs/cq/gui/components/authoring/clientlibs/editor/js/editors/inlinetexteditor.js.

searching "text" gives overview how hardcoded property. aem 6.1 (on i'm testing it) can find it's occurence in ns.persistence.readparagraphcontent function initialcontent extracted resource json map. occurence can found in finishinlineedit , addhistorystep methods. changing 3 occurences of "text" value brings expected outcome.

this non-acceptable - it's platform-wide change , affect other (incl. ootb) components might no expected. simplest copy-paste whole editor clientlib , register editor new name - see last couple of lines: ns.editor.register. if feel comfortable in js, might worth extend editor , alter 3 methods affected.


Comments

Popular posts from this blog

php - Zend Framework / Skeleton-Application / Composer install issue -

c# - Better 64-bit byte array hash -

python - PyCharm Type error Message -