/**
* @param BlockQuote $block
* @param HtmlRenderer $htmlRenderer
* @param bool $inTightList
*
* @return HtmlElement
*/
public function render(AbstractBlock $block, HtmlRenderer $htmlRenderer, $inTightList = false)
{
if (!$block instanceof BlockQuote) {
throw new \InvalidArgumentException('Incompatible block type: ' . get_class($block));
}
$filling = $htmlRenderer->renderBlocks($block->getChildren());
if ($filling === '') {
return new HtmlElement('blockquote', array(), $htmlRenderer->getOption('inner_separator', "\n"));
}
return new HtmlElement('blockquote', array(), $htmlRenderer->getOption('inner_separator', "\n") . $filling . $htmlRenderer->getOption('inner_separator', "\n"));
}