Custom elements in Editor

UI Components for Angular
Post Reply
microdeveloper
Posts: 82
Joined: 21 Mar 2016, 19:42

28 Mar 2016, 10:59

Hi first of all congrats for another exciting release.

Well i was waiting for the Editor control for long time now i am playing with it few things i want to know.
Can we add custom elements inside editor component.

cagatay.civici
Prime
Posts: 18616
Joined: 05 Jan 2009, 00:21
Location: Cybertron
Contact:

28 Mar 2016, 16:35

Yes, via toolbar. Notice the custom button at the bottom with fa-check icon.

Code: Select all

<p-editor [(value)]="text2" style="height:320px">
        <header>
            <span class="ql-format-group">
                <span title="Bold" class="ql-format-button ql-bold"></span>
                <span class="ql-format-separator"></span>
                <span title="Italic" class="ql-format-button ql-italic"></span>
                <span class="ql-format-separator"></span>
                <span title="Underline" class="ql-format-button ql-underline"></span>
                <span class="ql-format-separator"></span>
                <span title="Strikethrough" class="ql-format-button ql-strike"></span>
            </span>
            <button pButton icon="fa-check"></button>
        </header>
    </p-editor>

Post Reply

Return to “PrimeNG”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 25 guests