Phosphorum\Markdown\BlockQuoteExtension::processBlockQuote PHP Метод

processBlockQuote() публичный Метод

public processBlockQuote ( Ciconia\Common\Text $text )
$text Ciconia\Common\Text
    public function processBlockQuote(Text $text)
    {
        $text->replace('{
            (?:
            (?:
              ^[ \\t]*>[ \\t]? # > at the start of a line
                .+\\n            # rest of the first line
              (?:.+\\n)*         # subsequent consecutive lines
              \\n*               # blanks
            )+
            )
            }mx', function (Text $bq) {
            $bq->replace('/^[ \\t]*>[ \\t]?/m', '');
            $bq->replace('/^[ \\t]+$/m', '');
            $this->markdown->emit('block', [$bq]);
            $bq->replace('|\\s*<pre>.+?</pre>|s', function (Text $pre) {
                return $pre->replace('/^  /m', '');
            });
            return $this->getRenderer()->renderBlockQuote($bq) . "\n\n";
        });
    }