You are here

public function ToggleEditableFormatter::bootstrapToggleSizesOptions in Toggle Editable fields 8

Return all sizes options for boostrapToggle plugin.

Return value

array A list of options to be use with boostrapToggle plugin.

2 calls to ToggleEditableFormatter::bootstrapToggleSizesOptions()
ToggleEditableFormatter::getBoostrapToogleParameters in src/Plugin/Field/FieldFormatter/ToggleEditableFormatter.php
Retrieve setting values for given option name.
ToggleEditableFormatter::settingsForm in src/Plugin/Field/FieldFormatter/ToggleEditableFormatter.php
Returns a form to configure settings for the formatter.

File

src/Plugin/Field/FieldFormatter/ToggleEditableFormatter.php, line 110

Class

ToggleEditableFormatter
Plugin implementation of the 'ranking' formatter.

Namespace

Drupal\toggle_editable_fields\Plugin\Field\FieldFormatter

Code

public function bootstrapToggleSizesOptions() {
  return [
    'large' => $this
      ->t('Large'),
    'normal' => $this
      ->t('Normal'),
    'small' => $this
      ->t('Small'),
    'mini' => $this
      ->t('Mini'),
  ];
}