You are here

public static function VotingApiReactionItem::defaultFieldSettings in Voting API Reaction 8

Defines the field-level settings for this plugin.

Return value

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

Overrides FieldItemBase::defaultFieldSettings

File

src/Plugin/Field/FieldType/VotingApiReactionItem.php, line 28

Class

VotingApiReactionItem
Plugin implementation of the 'votingapi_reaction' field type.

Namespace

Drupal\votingapi_reaction\Plugin\Field\FieldType

Code

public static function defaultFieldSettings() {
  return [
    'anonymous_detection' => [
      VotingApiReactionItemInterface::BY_COOKIES,
      VotingApiReactionItemInterface::BY_IP,
    ],
    'anonymous_rollover' => VotingApiReactionItemInterface::VOTINGAPI_ROLLOVER,
    'reactions' => [
      'reaction_angry',
      'reaction_laughing',
      'reaction_like',
      'reaction_love',
      'reaction_sad',
      'reaction_surprised',
    ],
  ] + parent::defaultFieldSettings();
}