You are here

protected function Flexbox::defineOptions in Views Flexbox 8

Information about options for all kinds of purposes will be held here.


'option_name' => array(
 - 'default' => default value,
 - 'contains' => (optional) array of items this contains, with its own
     defaults, etc. If contains is set, the default will be ignored and
     assumed to be array().
 ),

Return value

array Returns the options of this handler/plugin.

Overrides StylePluginBase::defineOptions

File

src/Plugin/views/style/Flexbox.php, line 33

Class

Flexbox
Style plugin to render each item in a flexbox layout.

Namespace

Drupal\views_flexbox\Plugin\views\style

Code

protected function defineOptions() {
  $options = parent::defineOptions();
  $options['style'] = [
    'default' => '_none_',
  ];
  $options['link_to_content'] = [
    'default' => FALSE,
  ];
  $options['link_source'] = [
    'default' => NULL,
  ];
  $options['direction'] = [
    'default' => 'row',
  ];
  $options['justify'] = [
    'default' => 'start',
  ];
  $options['align_items'] = [
    'default' => 'stretch',
  ];
  $options['align_content'] = [
    'default' => 'stretch',
  ];
  $options['item_class_default'] = [
    'default' => TRUE,
  ];
  $options['item_class_custom'] = [
    'default' => '',
  ];
  return $options;
}