Contents

Backend\FormWidgets\ToolbarBuilder

Overview

ToolbarBuilder renders a visual editor for a rich editor toolbar definition, as a sortable row of button tiles with a palette of available buttons, powered client-side by the oc.richEditor registry.

Extends
Implements
  • Larajax\Contracts\ViewComponentInterface

Public Properties

There are no public properties in the class.

Show inherited public properties

Inherited Public Properties

Protected Properties

protected $defaultAlias

defaultAlias to identify this widget.

Show inherited protected properties

Inherited Protected Properties


Public Methods

public getSaveValue()

public getSaveValue($value): void

getSaveValue stores the buttons as a comma separated string

public prepareVars()

public prepareVars(): void

prepareVars for display

public render()

public render(): void

render the widget's primary contents.

Show inherited public methods

Inherited Public Methods

Protected Methods

protected getInheritedButtons()

protected getInheritedButtons(): string|null 

getInheritedButtons returns the configured default toolbar displayed by empty definitions, a null return means the client-side defaults apply

protected getSeededButtons()

protected getSeededButtons(): string|null 

getSeededButtons returns the registered button list for the definition, used by the reset feature, a null return hides the feature

protected loadAssets()

protected loadAssets(): void

loadAssets adds widget specific asset files. Use $this->addJs() and $this->addCss() to register new assets to include on the page.

protected normalizeButtons()

protected normalizeButtons($buttons): string 

normalizeButtons cleans a button list to a comma separated string of safe button codes

Show inherited protected methods

Inherited Protected Methods