diff --git a/.php_cs.dist b/.php-cs-fixer.dist.php similarity index 97% rename from .php_cs.dist rename to .php-cs-fixer.dist.php index f2b25f9..cbd0b85 100644 --- a/.php_cs.dist +++ b/.php-cs-fixer.dist.php @@ -29,9 +29,9 @@ $rules = [ 'strict_param' => true, 'whitespace_after_comma_in_array' => true, ]; -return Config::create() +return (new Config) ->setRules($rules) ->setFinder($finder) ->setUsingCache(false) ->setRiskyAllowed(true) -; \ No newline at end of file +; diff --git a/composer.json b/composer.json index f1eb739..568e2cb 100644 --- a/composer.json +++ b/composer.json @@ -19,7 +19,7 @@ "require-dev": { "phpunit/phpunit": "^9.3.11||^8.5.21||^7.5.20", "vimeo/psalm": "^4.10.0", - "friendsofphp/php-cs-fixer": "^2.13", + "friendsofphp/php-cs-fixer": "^3.0.0", "infection/infection": "^0.25.0", "roave/infection-static-analysis-plugin": "^1.10.0" }, diff --git a/src/Components/Blocks/BlockQuote.php b/src/Components/Blocks/BlockQuote.php index 32b8adf..081bd35 100644 --- a/src/Components/Blocks/BlockQuote.php +++ b/src/Components/Blocks/BlockQuote.php @@ -3,7 +3,6 @@ namespace Erusev\Parsedown\Components\Blocks; use Erusev\Parsedown\AST\Handler; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Block; use Erusev\Parsedown\Components\ContinuableBlock; use Erusev\Parsedown\Html\Renderables\Element; diff --git a/src/Components/Blocks/FencedCode.php b/src/Components/Blocks/FencedCode.php index e8cc8dc..03d84a4 100644 --- a/src/Components/Blocks/FencedCode.php +++ b/src/Components/Blocks/FencedCode.php @@ -2,7 +2,6 @@ namespace Erusev\Parsedown\Components\Blocks; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Block; use Erusev\Parsedown\Components\ContinuableBlock; use Erusev\Parsedown\Html\Renderables\Element; diff --git a/src/Components/Blocks/Header.php b/src/Components/Blocks/Header.php index c3859fe..35faa95 100644 --- a/src/Components/Blocks/Header.php +++ b/src/Components/Blocks/Header.php @@ -3,7 +3,6 @@ namespace Erusev\Parsedown\Components\Blocks; use Erusev\Parsedown\AST\Handler; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Block; use Erusev\Parsedown\Configurables\HeaderSlug; use Erusev\Parsedown\Configurables\SlugRegister; diff --git a/src/Components/Blocks/IndentedCode.php b/src/Components/Blocks/IndentedCode.php index b5ae8fb..384d04b 100644 --- a/src/Components/Blocks/IndentedCode.php +++ b/src/Components/Blocks/IndentedCode.php @@ -2,7 +2,6 @@ namespace Erusev\Parsedown\Components\Blocks; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Block; use Erusev\Parsedown\Components\ContinuableBlock; use Erusev\Parsedown\Html\Renderables\Element; diff --git a/src/Components/Blocks/Markup.php b/src/Components/Blocks/Markup.php index efb6dea..7f28377 100644 --- a/src/Components/Blocks/Markup.php +++ b/src/Components/Blocks/Markup.php @@ -3,7 +3,6 @@ namespace Erusev\Parsedown\Components\Blocks; use Erusev\Parsedown\AST\Handler; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Block; use Erusev\Parsedown\Components\ContinuableBlock; use Erusev\Parsedown\Configurables\SafeMode; diff --git a/src/Components/Blocks/Paragraph.php b/src/Components/Blocks/Paragraph.php index c80a72c..f004d37 100644 --- a/src/Components/Blocks/Paragraph.php +++ b/src/Components/Blocks/Paragraph.php @@ -3,7 +3,6 @@ namespace Erusev\Parsedown\Components\Blocks; use Erusev\Parsedown\AST\Handler; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Block; use Erusev\Parsedown\Components\ContinuableBlock; use Erusev\Parsedown\Html\Renderables\Element; diff --git a/src/Components/Blocks/Reference.php b/src/Components/Blocks/Reference.php index 6570de1..10c90d5 100644 --- a/src/Components/Blocks/Reference.php +++ b/src/Components/Blocks/Reference.php @@ -2,7 +2,6 @@ namespace Erusev\Parsedown\Components\Blocks; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Block; use Erusev\Parsedown\Components\StateUpdatingBlock; use Erusev\Parsedown\Configurables\DefinitionBook; diff --git a/src/Components/Blocks/Rule.php b/src/Components/Blocks/Rule.php index a1a29e7..59887ba 100644 --- a/src/Components/Blocks/Rule.php +++ b/src/Components/Blocks/Rule.php @@ -2,7 +2,6 @@ namespace Erusev\Parsedown\Components\Blocks; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Block; use Erusev\Parsedown\Html\Renderables\Element; use Erusev\Parsedown\Parsing\Context; diff --git a/src/Components/Blocks/SetextHeader.php b/src/Components/Blocks/SetextHeader.php index 482e37a..244b3c0 100644 --- a/src/Components/Blocks/SetextHeader.php +++ b/src/Components/Blocks/SetextHeader.php @@ -3,7 +3,6 @@ namespace Erusev\Parsedown\Components\Blocks; use Erusev\Parsedown\AST\Handler; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\AcquisitioningBlock; use Erusev\Parsedown\Components\Block; use Erusev\Parsedown\Configurables\HeaderSlug; diff --git a/src/Components/Blocks/TList.php b/src/Components/Blocks/TList.php index b368c98..73d3e97 100644 --- a/src/Components/Blocks/TList.php +++ b/src/Components/Blocks/TList.php @@ -3,7 +3,6 @@ namespace Erusev\Parsedown\Components\Blocks; use Erusev\Parsedown\AST\Handler; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Block; use Erusev\Parsedown\Components\ContinuableBlock; use Erusev\Parsedown\Html\Renderables\Element; diff --git a/src/Components/Blocks/Table.php b/src/Components/Blocks/Table.php index 0ede0f6..8628478 100644 --- a/src/Components/Blocks/Table.php +++ b/src/Components/Blocks/Table.php @@ -3,7 +3,6 @@ namespace Erusev\Parsedown\Components\Blocks; use Erusev\Parsedown\AST\Handler; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\AcquisitioningBlock; use Erusev\Parsedown\Components\Block; use Erusev\Parsedown\Components\ContinuableBlock; diff --git a/src/Components/Inlines/Code.php b/src/Components/Inlines/Code.php index 211b1cf..2d00cab 100644 --- a/src/Components/Inlines/Code.php +++ b/src/Components/Inlines/Code.php @@ -2,7 +2,6 @@ namespace Erusev\Parsedown\Components\Inlines; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Html\Renderables\Element; use Erusev\Parsedown\Html\Renderables\Text; diff --git a/src/Components/Inlines/Email.php b/src/Components/Inlines/Email.php index 1d6c939..58252ca 100644 --- a/src/Components/Inlines/Email.php +++ b/src/Components/Inlines/Email.php @@ -2,7 +2,6 @@ namespace Erusev\Parsedown\Components\Inlines; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Html\Renderables\Element; use Erusev\Parsedown\Html\Renderables\Text; diff --git a/src/Components/Inlines/Emphasis.php b/src/Components/Inlines/Emphasis.php index 08bae6f..a8920dc 100644 --- a/src/Components/Inlines/Emphasis.php +++ b/src/Components/Inlines/Emphasis.php @@ -3,7 +3,6 @@ namespace Erusev\Parsedown\Components\Inlines; use Erusev\Parsedown\AST\Handler; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Html\Renderables\Element; use Erusev\Parsedown\Html\Renderables\Text; diff --git a/src/Components/Inlines/EscapeSequence.php b/src/Components/Inlines/EscapeSequence.php index 01653e2..43102cc 100644 --- a/src/Components/Inlines/EscapeSequence.php +++ b/src/Components/Inlines/EscapeSequence.php @@ -2,7 +2,6 @@ namespace Erusev\Parsedown\Components\Inlines; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Html\Renderables\Text; use Erusev\Parsedown\Parsing\Excerpt; diff --git a/src/Components/Inlines/HardBreak.php b/src/Components/Inlines/HardBreak.php index 232feab..de5f16e 100644 --- a/src/Components/Inlines/HardBreak.php +++ b/src/Components/Inlines/HardBreak.php @@ -2,7 +2,6 @@ namespace Erusev\Parsedown\Components\Inlines; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\BacktrackingInline; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Html\Renderables\Element; diff --git a/src/Components/Inlines/Image.php b/src/Components/Inlines/Image.php index 09b63a1..ae6a5e5 100644 --- a/src/Components/Inlines/Image.php +++ b/src/Components/Inlines/Image.php @@ -3,7 +3,6 @@ namespace Erusev\Parsedown\Components\Inlines; use Erusev\Parsedown\AST\Handler; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Configurables\SafeMode; use Erusev\Parsedown\Html\Renderables\Element; diff --git a/src/Components/Inlines/Link.php b/src/Components/Inlines/Link.php index df15792..26f8b34 100644 --- a/src/Components/Inlines/Link.php +++ b/src/Components/Inlines/Link.php @@ -3,7 +3,6 @@ namespace Erusev\Parsedown\Components\Inlines; use Erusev\Parsedown\AST\Handler; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Configurables\DefinitionBook; use Erusev\Parsedown\Configurables\InlineTypes; diff --git a/src/Components/Inlines/Markup.php b/src/Components/Inlines/Markup.php index 27c8704..aea50b2 100644 --- a/src/Components/Inlines/Markup.php +++ b/src/Components/Inlines/Markup.php @@ -3,7 +3,6 @@ namespace Erusev\Parsedown\Components\Inlines; use Erusev\Parsedown\AST\Handler; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Configurables\SafeMode; use Erusev\Parsedown\Html\Renderables\RawHtml; diff --git a/src/Components/Inlines/PlainText.php b/src/Components/Inlines/PlainText.php index 51ab482..1d65ec3 100644 --- a/src/Components/Inlines/PlainText.php +++ b/src/Components/Inlines/PlainText.php @@ -2,7 +2,6 @@ namespace Erusev\Parsedown\Components\Inlines; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Html\Renderables\Text; use Erusev\Parsedown\Parsing\Excerpt; diff --git a/src/Components/Inlines/SoftBreak.php b/src/Components/Inlines/SoftBreak.php index cdd34ef..93bca6e 100644 --- a/src/Components/Inlines/SoftBreak.php +++ b/src/Components/Inlines/SoftBreak.php @@ -3,7 +3,6 @@ namespace Erusev\Parsedown\Components\Inlines; use Erusev\Parsedown\AST\Handler; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\BacktrackingInline; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Configurables\Breaks; diff --git a/src/Components/Inlines/SpecialCharacter.php b/src/Components/Inlines/SpecialCharacter.php index 605a697..57c0932 100644 --- a/src/Components/Inlines/SpecialCharacter.php +++ b/src/Components/Inlines/SpecialCharacter.php @@ -2,7 +2,6 @@ namespace Erusev\Parsedown\Components\Inlines; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Html\Renderables\RawHtml; use Erusev\Parsedown\Html\Renderables\Text; diff --git a/src/Components/Inlines/Strikethrough.php b/src/Components/Inlines/Strikethrough.php index 984b878..57dca1c 100644 --- a/src/Components/Inlines/Strikethrough.php +++ b/src/Components/Inlines/Strikethrough.php @@ -3,7 +3,6 @@ namespace Erusev\Parsedown\Components\Inlines; use Erusev\Parsedown\AST\Handler; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Html\Renderables\Element; use Erusev\Parsedown\Html\Renderables\Text; diff --git a/src/Components/Inlines/Url.php b/src/Components/Inlines/Url.php index 396f4f3..8ebf504 100644 --- a/src/Components/Inlines/Url.php +++ b/src/Components/Inlines/Url.php @@ -2,7 +2,6 @@ namespace Erusev\Parsedown\Components\Inlines; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\BacktrackingInline; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Html\Renderables\Element; diff --git a/src/Components/Inlines/UrlTag.php b/src/Components/Inlines/UrlTag.php index 1a072fc..9469e39 100644 --- a/src/Components/Inlines/UrlTag.php +++ b/src/Components/Inlines/UrlTag.php @@ -2,7 +2,6 @@ namespace Erusev\Parsedown\Components\Inlines; -use Erusev\Parsedown\AST\StateRenderable; use Erusev\Parsedown\Components\Inline; use Erusev\Parsedown\Html\Renderables\Element; use Erusev\Parsedown\Html\Renderables\Text;