Skip to content
Enables using http://suneditor.com in AEM dialogs as an RTE replacement.
JavaScript CSS
Branch: master
Clone or download
Latest commit d3a5274 Aug 14, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.settings v1.0.0 Aug 14, 2019
docs add initial editor Aug 13, 2019
jcr_root/apps/sun-editor/editor remove logging... smh Aug 13, 2019
.classpath v1.0.0 Aug 14, 2019
.gitignore add initial editor Aug 13, 2019
.project v1.0.0 Aug 14, 2019
README.md install docs Aug 14, 2019
pom.xml v1.0.0 Aug 14, 2019

README.md

AEM-SunEditor

Enables using http://suneditor.com in AEM dialogs as an RTE replacement.

Deploy the code

From source

mvn clean install -PautoInstallPackage

pre-built package

get the latest from releases

Usage

Here is a sample cq:dialog:

<cq:dialog jcr:primaryType="nt:unstructured"
  sling:resourceType="cq/gui/components/authoring/dialog"
  jcr:title="SunEditor"
  extraClientlibs="[suneditor]">
  <content jcr:primaryType="nt:unstructured"
    sling:resourceType="granite/ui/components/coral/foundation/container">
    <items jcr:primaryType="nt:unstructured">
      <textarea jcr:primaryType="nt:unstructured"
        sling:resourceType="granite/ui/components/coral/foundation/form/textarea"
        fieldLabel="Sun Editor"
        granite:id="suneditor"
        name="./html"
        resize="vertical"
        rows="20"/>
    </items>
  </content>
</cq:dialog>

The important parts are:

  1. on cq:dialog node, add extraClientlibs="[suneditor]"
  2. create a text area field: sling:resourceType="granite/ui/components/coral/foundation/form/textarea"
  3. set granite:id="suneditor" on the text area.
You can’t perform that action at this time.