You are here

public static function StarRatingFormatter::defaultSettings in Star Rating 8

Same name and namespace in other branches
  1. 8.4 src/Plugin/Field/FieldFormatter/StarRatingFormatter.php \Drupal\starrating\Plugin\Field\FieldFormatter\StarRatingFormatter::defaultSettings()
  2. 8.2 src/Plugin/Field/FieldFormatter/StarRatingFormatter.php \Drupal\starrating\Plugin\Field\FieldFormatter\StarRatingFormatter::defaultSettings()
  3. 8.3 src/Plugin/Field/FieldFormatter/StarRatingFormatter.php \Drupal\starrating\Plugin\Field\FieldFormatter\StarRatingFormatter::defaultSettings()

Defines the default settings for this plugin.

Return value

array A list of default settings, keyed by the setting name.

Overrides PluginSettingsBase::defaultSettings

File

src/Plugin/Field/FieldFormatter/StarRatingFormatter.php, line 26

Class

StarRatingFormatter
Plugin implementation of the 'addtocart' formatter.

Namespace

Drupal\starrating\Plugin\Field\FieldFormatter

Code

public static function defaultSettings() {
  return array(
    'fill_blank' => 0,
    'icon_type' => 'star',
    'icon_color' => 1,
  ) + parent::defaultSettings();
}