Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

Richtext takes <div> after the <h3> Headline

Avatar

Avatar
Level 1
xerxes1
Level 1

Likes

0 likes

Total Posts

4 posts

Correct Reply

0 solutions
View profile

Avatar
Level 1
xerxes1
Level 1

Likes

0 likes

Total Posts

4 posts

Correct Reply

0 solutions
View profile
xerxes1
Level 1

08-01-2021

There are Paraformats like <p>, <h1>, <h2>, <h3> etc.

We are using the <p> tag as "standart" and the <h3> tag as "Headline" and the rest ist disabled.

When i say a line is "Headline" and then i click "Enter" the new line should be a <p> tag but it is creating a <div> tag.

Also when i want to change this <div> line to the "Standart" paraformat, the button is disabled.

I want that it is creating a <p> and not a <div> but i can't find from where the <div> is coming from and how i fix it ?


Here the HTML value:

 

<p>some text</p>
<h3>asdf<br>
</h3>
<div>asdf</div>

 

 

In the Image you can see how the button is grey when i want to change the <div> but when i click somewhere else in the text with no <div> the button can be clicked:

Unbenannt.PNG

 

Here is the _cd_dialog file, maybe it helps:

 

<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:jcr="http://www.jcp.org/jcr/1.0"
          xmlns:nt="http://www.jcp.org/jcr/nt/1.0"
          jcr:primaryType="nt:unstructured"
          jcr:title="Text"
          sling:resourceType="cq/gui/components/authoring/dialog">
    <content
            jcr:primaryType="nt:unstructured">
        <items jcr:primaryType="nt:unstructured">
            <tabs
                    jcr:primaryType="nt:unstructured">
                <items jcr:primaryType="nt:unstructured">
                    <properties
                            jcr:primaryType="nt:unstructured">
                        <items jcr:primaryType="nt:unstructured">
                            <columns
                                    jcr:primaryType="nt:unstructured">
                                <items jcr:primaryType="nt:unstructured">
                                    <column
                                            jcr:primaryType="nt:unstructured">
                                        <items jcr:primaryType="nt:unstructured">
                                            <text
                                                    jcr:primaryType="nt:unstructured"
                                                    sling:resourceType="cq/gui/components/authoring/dialog/richtext"
                                                    name="./text"
                                                    useFixedInlineToolbar="{Boolean}true">
                                                <rtePlugins jcr:primaryType="nt:unstructured"
                                                            sling:resourceSuperType="/mnt/override/apps/websitename/components/content/text/cq:editConfig/cq:inplaceEditing/inplaceEditingConfig/rtePlugins">
                                                    <paraformat
                                                            jcr:primaryType="nt:unstructured"
                                                            features="*">
                                                        <formats jcr:primaryType="nt:unstructured">
                                                            <default_p
                                                                    jcr:primaryType="nt:unstructured"
                                                                    description="Standard"
                                                                    tag="p"/>
                                                            <default_h1
                                                                    jcr:primaryType="nt:unstructured"
                                                                    sling:hideResource="true"/>
                                                            <default_h2
                                                                    jcr:primaryType="nt:unstructured"
                                                                    sling:hideResource="true"/>
                                                            <default_h3
                                                                    jcr:primaryType="nt:unstructured"
                                                                    description="Headline"
                                                                    tag="h3"/>
                                                            <default_h4
                                                                    jcr:primaryType="nt:unstructured"
                                                                    sling:hideResource="true"/>
                                                            <default_h5
                                                                    jcr:primaryType="nt:unstructured"
                                                                    sling:hideResource="true"/>
                                                            <default_h6
                                                                    jcr:primaryType="nt:unstructured"
                                                                    sling:hideResource="true"/>
                                                            <default_blockquote
                                                                    jcr:primaryType="nt:unstructured"
                                                                    sling:hideResource="true"/>
                                                            <default_hr
                                                                    jcr:primaryType="nt:unstructured"
                                                                    sling:hideResource="true"/>
                                                            <default_pre
                                                                    jcr:primaryType="nt:unstructured"
                                                                    sling:hideResource="true"/>
                                                        </formats>
                                                    </paraformat>
                                                </rtePlugins>
                                                <uiSettings jcr:primaryType="nt:unstructured"
                                                            sling:resourceSuperType="/mnt/override/apps/websitename/components/content/text/cq:editConfig/cq:inplaceEditing/inplaceEditingConfig/uiSettings">
                                                    <cui jcr:primaryType="nt:unstructured">
                                                        <inline
                                                                jcr:primaryType="nt:unstructured"
                                                                toolbar="[subsuperscript#subscript,subsuperscript#superscript,edit#paste-plaintext,edit#paste-wordhtml,links#modifylink,links#unlink,findreplace#find,findreplace#replace,undo#undo,undo#redo,#lists,table#createoredit,#justify,spellcheck#checktext,misctools#specialchars,misctools#sourceedit,#paraformat,#styles,tooltip#tooltip,telephonelink#telephonelink]">
                                                            <popovers jcr:primaryType="nt:unstructured">
                                                                <justify
                                                                        jcr:primaryType="nt:unstructured"
                                                                        items="[justify#justifyleft,justify#justifycenter,justify#justifyright]"
                                                                        ref="justify"/>
                                                                <lists
                                                                        jcr:primaryType="nt:unstructured"
                                                                        items="[lists#unordered,lists#ordered,lists#outdent,lists#indent]"
                                                                        ref="lists"/>
                                                                <paraformat
                                                                        jcr:primaryType="nt:unstructured"
                                                                        items="paraformat:getFormats:paraformat-pulldown"
                                                                        ref="paraformat"/>
                                                                <styles
                                                                        jcr:primaryType="nt:unstructured"
                                                                        items="styles:getStyles:styles-pulldown"
                                                                        ref="styles"/>
                                                            </popovers>
                                                        </inline>
                                                    </cui>
                                                </uiSettings>
                                                <htmlRules jcr:primaryType="nt:unstructured"
                                                           sling:resourceSuperType="/mnt/override/apps/websitename/components/content/text/cq:editConfig/cq:inplaceEditing/inplaceEditingConfig/htmlRules">
                                                </htmlRules>
                                            </text>
                                            <id
                                                    jcr:primaryType="nt:unstructured"
                                                    sling:hideResource="true"/>
                                        </items>
                                    </column>
                                </items>
                            </columns>
                        </items>
                    </properties>
                </items>
            </tabs>
        </items>
    </content>
</jcr:root>

 

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Establish
MVP
BrianKasingli
MVP

Likes

644 likes

Total Posts

605 posts

Correct Reply

239 solutions
Top badges earned
Establish
Ignite 1
Give Back 5
Give Back 3
Give Back 10
View profile

Avatar
Establish
MVP
BrianKasingli
MVP

Likes

644 likes

Total Posts

605 posts

Correct Reply

239 solutions
Top badges earned
Establish
Ignite 1
Give Back 5
Give Back 3
Give Back 10
View profile
BrianKasingli
MVP

08-01-2021

@xerxes1,

I have tested the RichText editor with all enabled features, and have no headings (h2,h3,h3) selected. On AEM 6.5, Everything is working as expected here. You can find my the component that I have tested here, https://gist.github.com/briankasingli/1a7e3e12deaa2e076645b09d30039b46

Take a look at my screenshot, the view source code looks like it's working as expected. 

BrianKasingli_1-1610107669008.png

Maybe what you can do is share your _cq_dialog.xml configuration with us, so we can further investigate your situation.

 

Answers (2)

Answers (2)

Avatar

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,429 likes

Total Posts

3,300 posts

Correct Reply

937 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile

Avatar
Coach
MVP
Arun_Patidar
MVP

Likes

1,429 likes

Total Posts

3,300 posts

Correct Reply

937 solutions
Top badges earned
Coach
Contributor 2
Ignite 10
Give Back 700
Boost 1000
View profile
Arun_Patidar
MVP

08-01-2021

Hi,

What is the AEM version that you are using?

Avatar

Avatar
Validate 1
MVP
Umesh_Thakur
MVP

Likes

147 likes

Total Posts

157 posts

Correct Reply

53 solutions
Top badges earned
Validate 1
Applaud 25
Ignite 3
Ignite 1
Give Back 5
View profile

Avatar
Validate 1
MVP
Umesh_Thakur
MVP

Likes

147 likes

Total Posts

157 posts

Correct Reply

53 solutions
Top badges earned
Validate 1
Applaud 25
Ignite 3
Ignite 1
Give Back 5
View profile
Umesh_Thakur
MVP

08-01-2021

Hi @xerxes1,

Under the paraformat node you will have some formates nodes there usually we have the name and its equivalent HTML tag. At the same place you can see and update it.

TUmesh_0-1610107732133.png

Hope this will help.

Umesh Thakur