You are here

public function TocJsBlock::defaultConfiguration in Toc.js 8

Same name and namespace in other branches
  1. 2.0.x src/Plugin/Block/TocJsBlock.php \Drupal\toc_js\Plugin\Block\TocJsBlock::defaultConfiguration()

Overrides BlockPluginTrait::defaultConfiguration

File

src/Plugin/Block/TocJsBlock.php, line 63

Class

TocJsBlock
Provides a 'SocialSimpleBlock' block.

Namespace

Drupal\toc_js\Plugin\Block

Code

public function defaultConfiguration() {
  return [
    'title' => $this
      ->t('Table of content'),
    'selectors' => 'h2, h3',
    'selectors_minimum' => 0,
    'container' => '.node',
    'prefix' => 'toc',
    'list_type' => 'ul',
    'back_to_top' => 0,
    'back_to_top_label' => $this
      ->t('Back to top'),
    'smooth_scrolling' => 1,
    'scroll_to_offset' => 100,
    'highlight_on_scroll' => 1,
    'highlight_offset' => 100,
    'sticky' => 0,
    'sticky_offset' => 0,
    'sticky_stop' => '',
    'sticky_stop_padding' => 0,
  ] + parent::defaultConfiguration();
}