| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647 |
- <?php
- /**
- * @class FLRichTextModule
- */
- class FLRichTextModule extends FLBuilderModule {
- /**
- * @method __construct
- */
- public function __construct() {
- parent::__construct(array(
- 'name' => __( 'Text Editor', 'fl-builder' ),
- 'description' => __( 'A WYSIWYG text editor.', 'fl-builder' ),
- 'category' => __( 'Basic', 'fl-builder' ),
- 'partial_refresh' => true,
- 'icon' => 'text.svg',
- ));
- }
- }
- /**
- * Register the module and its form settings.
- */
- FLBuilder::register_module('FLRichTextModule', array(
- 'general' => array( // Tab
- 'title' => __( 'General', 'fl-builder' ), // Tab title
- 'sections' => array( // Tab Sections
- 'general' => array( // Section
- 'title' => '', // Section Title
- 'fields' => array( // Section Fields
- 'text' => array(
- 'type' => 'editor',
- 'label' => '',
- 'rows' => 13,
- 'wpautop' => false,
- 'preview' => array(
- 'type' => 'text',
- 'selector' => '.fl-rich-text',
- ),
- 'connections' => array( 'string' ),
- ),
- ),
- ),
- ),
- ),
- ));
|