var config = {
buttons: buttons,
+ formatting: ['p', 'h2', 'h3', 'h4'],
imageCaption: false,
+ lang: 'wsc', // fake language to offload phrases
+ langs: {
+ wsc: {
+ // formatting dropdown
+ heading2: '{lang}wcf.editor.format.heading2{/lang}',
+ heading3: '{lang}wcf.editor.format.heading3{/lang}',
+ heading4: '{lang}wcf.editor.format.heading4{/lang}',
+ paragraph: '{lang}wcf.editor.format.paragraph{/lang}'
+ }
+ },
minHeight: 200,
plugins: [
'alignment',
alignment: { icon: 'fa-align-left', title: '{lang}wcf.editor.button.alignment{/lang}' },
bold: { icon: 'fa-bold', title: '{lang}wcf.editor.button.bold{/lang}' },
deleted: { icon: 'fa-strikethrough', title: '{lang}wcf.editor.button.strikethrough{/lang}' },
+ format: { icon: 'fa-paragraph', title: '{lang}wcf.editor.button.format{/lang}' },
html: { icon: 'fa-code', title: '{lang}wcf.editor.button.html{/lang}' },
italic: { icon: 'fa-italic', title: '{lang}wcf.editor.button.italic{/lang}' },
link: { icon: 'fa-link', title: '{lang}wcf.editor.button.link{/lang}' },
buttons.push('wcfSeparator');
+buttons.push('format');
+
+buttons.push('wcfSeparator');
+
buttons.push('bold');
buttons.push('italic');
buttons.push('underline');
display: none;
}
+/* format */
+.redactor-dropdown-h2 {
+ @include wcfFontSection;
+}
+
+.redactor-dropdown-h3 {
+ @include wcfFontHeadline;
+}
+
+.redactor-dropdown-h4 {
+ // TODO: add styling
+}
+
/* alignment plugin */
.text-center {
text-align: center;
<item name="wcf.editor.button.bold"><![CDATA[Fett]]></item>
<item name="wcf.editor.button.code"><![CDATA[Code]]></item>
<item name="wcf.editor.button.color"><![CDATA[Schriftfarbe]]></item>
+ <item name="wcf.editor.button.format"><![CDATA[Überschrift]]></item>
<item name="wcf.editor.button.html"><![CDATA[HTML]]></item>
<item name="wcf.editor.button.image"><![CDATA[Bild]]></item>
<item name="wcf.editor.button.inlineCode"><![CDATA[Inline-Code]]></item>
<item name="wcf.editor.code.line.description"><![CDATA[Optional: Legen Sie den Wert fest, ab dem die Zeilennummierung startet.]]></item>
<item name="wcf.editor.code.title"><![CDATA[{if $highlighter}{$highlighter}{else}Quellcode{/if}{if $file} - {$file}{/if}]]></item>
+ <item name="wcf.editor.format.heading2"><![CDATA[Überschrift]]></item>
+ <item name="wcf.editor.format.heading3"><![CDATA[Abschnitt]]></item>
+ <item name="wcf.editor.format.heading4"><![CDATA[Unterabschnitt]]></item>
+ <item name="wcf.editor.format.paragraph"><![CDATA[Normaler Text]]></item>
+
<item name="wcf.editor.image.edit"><![CDATA[Bild bearbeiten]]></item>
<item name="wcf.editor.image.insert"><![CDATA[Bild einfügen]]></item>
<item name="wcf.editor.image.link"><![CDATA[Verlinkung]]></item>
<item name="wcf.editor.button.bold"><![CDATA[Bold]]></item>
<item name="wcf.editor.button.code"><![CDATA[Code]]></item>
<item name="wcf.editor.button.color"><![CDATA[Font Color]]></item>
+ <item name="wcf.editor.button.format"><![CDATA[Headline]]></item>
<item name="wcf.editor.button.html"><![CDATA[HTML]]></item>
<item name="wcf.editor.button.image"><![CDATA[Image]]></item>
<item name="wcf.editor.button.inlineCode"><![CDATA[Inline-Code]]></item>
<item name="wcf.editor.code.line.description"><![CDATA[Optional: Specify the start for line enumeration.]]></item>
<item name="wcf.editor.code.title"><![CDATA[{if $highlighter}{$highlighter}{else}Code{/if}{if $file} - {$file}{/if}]]></item>
+ <item name="wcf.editor.format.heading2"><![CDATA[Headline]]></item>
+ <item name="wcf.editor.format.heading3"><![CDATA[Section]]></item>
+ <item name="wcf.editor.format.heading4"><![CDATA[Subsection]]></item>
+ <item name="wcf.editor.format.paragraph"><![CDATA[Normal text]]></item>
+
<item name="wcf.editor.image.edit"><![CDATA[Edit Image]]></item>
<item name="wcf.editor.image.insert"><![CDATA[Insert Image]]></item>
<item name="wcf.editor.image.link"><![CDATA[Link]]></item>