Days
Hours
Minutes
Seconds
x

New Froala Editor v5.0.0 is here โ€“ Learn More

Skip to content
Froala Documentation

Paragraph Format Plugin

Plugins are fully functional during your trial once you've added your trial key to the setup.

Allows users to change the type of a paragraph:

use normal paragraphs, write some code or just highlight ideas using headings.


Plugin options:

paragraphDefaultSelection
String -
The default option to select for Paragraph Format.

Default: 'Paragraph Format'
paragraphFormat
Object -
An Object with the options that will appear in the Paragraph Format dropdown from the toolbar. Where 'N' tag will be treated as a when the enter option is set to FroalaEditor.ENTER_P and as a
when the enter option is set to FroalaEditor.ENTER_DIV.

Default:
{
N: 'Normal',
H1: 'Heading 1',
H2: 'Heading 2',
H3: 'Heading 3',
H4: 'Heading 4',
PRE: 'Code'
}
paragraphFormatSelectiont
Boolean -
The Paragraph Format button from the WYSIWYG editor's toolbar is replaced with a dropdown showing the actual paragraph format name for the current text selection.

Default: false

Plugin methods:

paragraphFormat.apply (value)
returns: Object
Change the format of the selected paragraphs.
โ— value: The format value to apply.
Type: String

Add Plugin to your code:

Plugin name: paragraphFormat

Plugin JS Script: ../js/plugins/paragraph_format.min.js

Or from CDN https://cdn.jsdelivr.net/npm/froala-editor@latest/js/plugins/paragraph_format.min.js

Plugin CSS link:


Ready to dive in? Explore our plans