Expand my Community achievements bar.

SOLVED

[AEM6.5] RTE under Multifield. spacing before a superscript character on RTE

Avatar

Level 6

I'm facing issue in RTE with Multifield

issue here is I'm observing a spacing before a superscript character on RTE. We don’t see any spacing issue in the author dialog during configuration but we do have spacing on the actual page before the superscript character.

image.png

I am trying to create this field using below dialog xml structure,

Could you please look and guide me why I am getting extra spaces in actual page.

<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:sling="http://sling.apache.org/jcr/sling/1.0" xmlns:cq="http://www.day.com/jcr/cq/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="Blade"
    sling:resourceType="cq/gui/components/authoring/dialog">
    <content
        jcr:primaryType="nt:unstructured"
        sling:resourceType="granite/ui/components/foundation/container"
        class="richtextfullscreen">
        <layout
            jcr:primaryType="nt:unstructured"
            sling:resourceType="granite/ui/components/foundation/layouts/tabs"
            type="nav"/>
        <items jcr:primaryType="nt:unstructured">
            <tab1
                jcr:primaryType="nt:unstructured"
                jcr:title="Content"
                sling:resourceType="granite/ui/components/foundation/section">
                <layout
                    jcr:primaryType="nt:unstructured"
                    sling:resourceType="granite/ui/components/foundation/layouts/fixedcolumns"/>
                <items jcr:primaryType="nt:unstructured">
                    <column
                        jcr:primaryType="nt:unstructured"
                        sling:resourceType="granite/ui/components/foundation/container">
                        <items jcr:primaryType="nt:unstructured">
                            <fieldset
                                jcr:primaryType="nt:unstructured"
                                jcr:title=""
                                sling:resourceType="granite/ui/components/foundation/form/fieldset">
                                <layout
                                    jcr:primaryType="nt:unstructured"
                                    sling:resourceType="granite/ui/components/foundation/layouts/fixedcolumns"/>
                                <items jcr:primaryType="nt:unstructured">
                                    <promotionItems
                                        jcr:primaryType="nt:unstructured"
                                        jcr:title="Items"
                                        sling:resourceType="granite/ui/components/foundation/section">
                                        <layout
                                            jcr:primaryType="nt:unstructured"
                                            sling:resourceType="granite/ui/components/foundation/layouts/fixedcolumns"
                                            margin="{Boolean}true"/>
                                        <items jcr:primaryType="nt:unstructured">
                                            <column
                                                jcr:primaryType="nt:unstructured"
                                                sling:resourceType="granite/ui/components/foundation/container">
                                                <items jcr:primaryType="nt:unstructured">
                                                    <itemmultifield
                                                        jcr:primaryType="nt:unstructured"
                                                        sling:resourceType="granite/ui/components/coral/foundation/form/multifield"
                                                        class="full-width"
                                                        composite="{Boolean}true"
                                                        eaem-nested=""
                                                        fieldLabel="Items">
                                                        <field
                                                            jcr:primaryType="nt:unstructured"
                                                            sling:resourceType="granite/ui/components/coral/foundation/container"
                                                            name="./contentMulti">
                                                            <items jcr:primaryType="nt:unstructured">
                                                                <column
                                                                    jcr:primaryType="nt:unstructured"
                                                                    sling:resourceType="granite/ui/components/coral/foundation/container"
                                                                    fieldLabel="Items">
                                                                    <items jcr:primaryType="nt:unstructured">
                                                                        <title
                                                                            jcr:primaryType="nt:unstructured"
                                                                            sling:resourceType="granite/ui/components/foundation/form/textfield"
                                                                            fieldLabel="Title"
                                                                            name="./title"
                                                                            required="false"/>
                                                                        <description
                                                                            jcr:primaryType="nt:unstructured"
                                                                            sling:resourceType="cq/gui/components/authoring/dialog/richtext"
                                                                            fieldLabel="Description"
                                                                            name="./description"
                                                                            useFixedInlineToolbar="{Boolean}true">
                                                                            <rtePlugins
                                                                                jcr:primaryType="nt:unstructured"
                                                                                features="*">
                                                                                <edit
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    features="[paste-wordhtml]"
                                                                                    name="edit">
                                                                                    <htmlPasteRules jcr:primaryType="nt:unstructured">
                                                                                        <allowBasics
                                                                                            jcr:primaryType="nt:unstructured"
                                                                                            anchor="{Boolean}true"
                                                                                            bold="{Boolean}true"
                                                                                            image="{Boolean}true"
                                                                                            italic="{Boolean}true"
                                                                                            underline="{Boolean}true"/>
                                                                                    </htmlPasteRules>
                                                                                </edit>
                                                                                <findreplace
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    features="*"
                                                                                    name="findreplace"/>
                                                                                <format
                                                                                    jcr:created="{Date}2011-05-25T18:49:56.487+05:30"
                                                                                    jcr:createdBy="admin"
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    features="[bold,italic,underline]"
                                                                                    name="format"/>
                                                                                <image
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    features="*"
                                                                                    name="image"/>
                                                                                <justify
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    features="*"
                                                                                    name="justify"/>
                                                                                <keys
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    name="keys"
                                                                                    tabSize="4"/>
                                                                                <links
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    features="*"
                                                                                    name="links"/>
                                                                                <lists
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    features="[ordered,unordered,indent]"
                                                                                    name="lists"/>
                                                                                <misctools
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    features="[specialchars]"
                                                                                    name="misctools">
                                                                                    <specialCharsConfig jcr:primaryType="nt:unstructured">
                                                                                        <chars jcr:primaryType="nt:unstructured">
                                                                                            <copyright
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                entity="&amp;#169;"/>
                                                                                            <half
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                entity="&amp;#189;"/>
                                                                                            <registred
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                entity="&amp;#174;"/>
                                                                                            <trademark
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                entity="&amp;#8482;"/>
                                                                                            <carat
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                entity="&amp;#8250;"/>
                                                                                        </chars>
                                                                                    </specialCharsConfig>
                                                                                </misctools>
                                                                                <paraformat
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    features="*"
                                                                                    name="paraformat">
                                                                                    <formats jcr:primaryType="cq:WidgetCollection">
                                                                                        <myheading
                                                                                            jcr:primaryType="nt:unstructured"
                                                                                            tag="h1"/>
                                                                                        <myparagraph
                                                                                            jcr:primaryType="nt:unstructured"
                                                                                            tag="p"/>
                                                                                        <myblockquote
                                                                                            jcr:primaryType="nt:unstructured"
                                                                                            tag="blockquote"/>
                                                                                    </formats>
                                                                                </paraformat>
                                                                                <spellcheck
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    features="*"
                                                                                    name="spellcheck"/>
                                                                                <subsuperscript
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    features="*"
                                                                                    name="subsuperscript"/>
                                                                                <styles
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    features="*"
                                                                                    name="styles">
                                                                                    <styles jcr:primaryType="cq:WidgetCollection">
                                                                                        <blueButtonCTA
                                                                                            jcr:primaryType="nt:unstructured"
                                                                                            cssName="button-blue-light"
                                                                                            text="Blue Button CTA"/>
                                                                                        <whiteButtonCTA
                                                                                            jcr:primaryType="nt:unstructured"
                                                                                            cssName="button-white"
                                                                                            text="White Button CTA"/>
                                                                                    </styles>
                                                                                </styles>
                                                                            </rtePlugins>
                                                                            <uiSettings jcr:primaryType="nt:unstructured">
                                                                                <cui jcr:primaryType="nt:unstructured">
                                                                                    <inline
                                                                                        jcr:primaryType="nt:unstructured"
                                                                                        toolbar="[#edit,format#bold,format#italic,format#underline,#justify,-,#lists,-,links#modifylink,links#unlink,links#anchor,-,-,#paraformat,-,#styles,-,edit#cut,edit#copy,edit#paste-plaintext,edit#paste-default,edit#paste-wordhtml,-,undo#undo,undo#redo,-,findreplace#find,findreplace#replace,-,spellcheck#checktext,-,misctools#sourceedit,misctools#specialchars,-,table#createoredit,subsuperscript#superscript,subsuperscript#subscript]">
                                                                                        <popovers jcr:primaryType="nt:unstructured">
                                                                                            <paraformat
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                items="paraformat:getFormats:paraformat-pulldown"
                                                                                                ref="paraformat"/>
                                                                                            <lists
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                items="[lists#unordered,lists#ordered,lists#outdent,lists#indent]"
                                                                                                ref="lists"/>
                                                                                            <justify
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                items="[justify#justifyleft,justify#justifycenter,justify#justifyright]"
                                                                                                ref="justify"/>
                                                                                            <findreplace
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                items="[findreplace#find,findreplace#replace]"
                                                                                                ref="findreplace"/>
                                                                                            <styles
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                items="styles:getStyles:styles-pulldown"
                                                                                                ref="styles"/>
                                                                                        </popovers>
                                                                                    </inline>
                                                                                    <dialogFullScreen
                                                                                        jcr:primaryType="nt:unstructured"
                                                                                        toolbar="[#edit,format#bold,format#italic,format#underline,#justify,-,#lists,-,links#modifylink,links#unlink,links#anchor,-,-,#paraformat,-,#styles,-,edit#cut,edit#copy,edit#paste-plaintext,edit#paste-default,edit#paste-wordhtml,-,undo#undo,undo#redo,-,findreplace#find,findreplace#replace,-,spellcheck#checktext,-,misctools#sourceedit,misctools#specialchars,-,table#createoredit,subsuperscript#superscript,subsuperscript#subscript,-,fullscreen#start,useFixedInlineToolbar=true]">
                                                                                        <popovers jcr:primaryType="nt:unstructured">
                                                                                            <paraformat
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                items="paraformat:getFormats:paraformat-pulldown"
                                                                                                ref="paraformat"/>
                                                                                            <lists
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                items="[lists#unordered,lists#ordered,lists#outdent,lists#indent]"
                                                                                                ref="lists"/>
                                                                                            <justify
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                items="[justify#justifyleft,justify#justifycenter,justify#justifyright]"
                                                                                                ref="justify"/>
                                                                                            <findreplace
                                                                                                jcr:primaryType="nt:unstructured"
                                                                                                items="[findreplace#find,findreplace#replace]"
                                                                                                ref="findreplace"/>
                                                                                        </popovers>
                                                                                    </dialogFullScreen>
                                                                                </cui>
                                                                            </uiSettings>
                                                                            <htmlRules jcr:primaryType="nt:unstructured">
                                                                                <blockHandling
                                                                                    jcr:primaryType="nt:unstructured"
                                                                                    removeSingleParagraphContainer="{Boolean}true"/>
                                                                            </htmlRules>
                                                                        </description>
                                                                    </items>
                                                                </column>
                                                            </items>
                                                        </field>
                                                    </itemmultifield>
                                                </items>
                                            </column>
                                        </items>
                                    </promotionItems>
                                </items>
                            </fieldset>
                        </items>
                    </column>
                </items>
            </tab1>
        </items>
    </content>
</jcr:root>

Thanks,

@kautuk_sahni  @arunpatidar  @Vijayalakshmi_S   @vanegi  @Theo_Pendle  @BrianKasingli 

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Level 8

Hi @tushaar_srivastava 

The spacing issue which you have mentioned here is because of if there is any custom css styles added in your project clientlib css which is getting applied when the same superscript content rendered on the page. so, please check project clientlib css file & remove below mentioned styles if its added to remove space.

 

Coral Styles applied on RTE :

coral_style.png

 

 

Renders Superscript content as it is if there is no custom style added in project clientlib.

project.png

 

 

Space added if there is css style added for superscript tag as mentioned below

left: 0.2em;

position: relative;

 

custom.png

 

-Manjunath

View solution in original post

2 Replies

Avatar

Correct answer by
Level 8

Hi @tushaar_srivastava 

The spacing issue which you have mentioned here is because of if there is any custom css styles added in your project clientlib css which is getting applied when the same superscript content rendered on the page. so, please check project clientlib css file & remove below mentioned styles if its added to remove space.

 

Coral Styles applied on RTE :

coral_style.png

 

 

Renders Superscript content as it is if there is no custom style added in project clientlib.

project.png

 

 

Space added if there is css style added for superscript tag as mentioned below

left: 0.2em;

position: relative;

 

custom.png

 

-Manjunath

Avatar

Community Advisor

One More thing, I can see you are still using granite UI so if possible, migrate it to the coral3 UI since this is more compatible with 6.5.

this might be also a cause of it.