summaryrefslogtreecommitdiff
path: root/vendor/league/commonmark/src/Extension/TableOfContents/TableOfContentsExtension.php
diff options
context:
space:
mode:
authorGreg Roach <greg@subaqua.co.uk>2020-12-27 20:12:27 +0000
committerGreg Roach <greg@subaqua.co.uk>2021-03-11 10:22:29 +0000
commitf7cf8a155e2743f3d124eef3d30a558ab062fa4b (patch)
treea45052d9dc68b2049f4848e1043f56f6782ad3dd /vendor/league/commonmark/src/Extension/TableOfContents/TableOfContentsExtension.php
parent7989fe578b0082b5d3378ee0b461904deb3802d1 (diff)
downloadwebtrees-f7cf8a155e2743f3d124eef3d30a558ab062fa4b.tar.gz
webtrees-f7cf8a155e2743f3d124eef3d30a558ab062fa4b.tar.bz2
webtrees-f7cf8a155e2743f3d124eef3d30a558ab062fa4b.zip
Remove vendor dir, add support for PHP 8.0, drop support for PHP 7.1 and 7.2
Diffstat (limited to 'vendor/league/commonmark/src/Extension/TableOfContents/TableOfContentsExtension.php')
-rw-r--r--vendor/league/commonmark/src/Extension/TableOfContents/TableOfContentsExtension.php31
1 files changed, 0 insertions, 31 deletions
diff --git a/vendor/league/commonmark/src/Extension/TableOfContents/TableOfContentsExtension.php b/vendor/league/commonmark/src/Extension/TableOfContents/TableOfContentsExtension.php
deleted file mode 100644
index 287ced77d8..0000000000
--- a/vendor/league/commonmark/src/Extension/TableOfContents/TableOfContentsExtension.php
+++ /dev/null
@@ -1,31 +0,0 @@
-<?php
-
-/*
- * This file is part of the league/commonmark package.
- *
- * (c) Colin O'Dell <colinodell@gmail.com>
- *
- * For the full copyright and license information, please view the LICENSE
- * file that was distributed with this source code.
- */
-
-namespace League\CommonMark\Extension\TableOfContents;
-
-use League\CommonMark\ConfigurableEnvironmentInterface;
-use League\CommonMark\Event\DocumentParsedEvent;
-use League\CommonMark\Extension\ExtensionInterface;
-use League\CommonMark\Extension\TableOfContents\Node\TableOfContentsPlaceholder;
-
-final class TableOfContentsExtension implements ExtensionInterface
-{
- public function register(ConfigurableEnvironmentInterface $environment): void
- {
- $environment->addEventListener(DocumentParsedEvent::class, [new TableOfContentsBuilder(), 'onDocumentParsed'], -150);
-
- if ($environment->getConfig('table_of_contents/position') === TableOfContentsBuilder::POSITION_PLACEHOLDER) {
- $environment->addBlockParser(new TableOfContentsPlaceholderParser(), 200);
- // If a placeholder cannot be replaced with a TOC element this renderer will ensure the parser won't error out
- $environment->addBlockRenderer(TableOfContentsPlaceholder::class, new TableOfContentsPlaceholderRenderer());
- }
- }
-}