From 9e6fcfaf13d77e2b8fafd39d6fd528489dc3d2e8 Mon Sep 17 00:00:00 2001 From: buttle Date: Mon, 13 Sep 2021 13:11:52 +0200 Subject: [PATCH] adds wrapper. adds archive-item-block to wrapper --- src/Site/BlockLayout/SimpleMDText.php | 4 +++- view/common/block-layout/simpleMDText.phtml | 7 +++++++ 2 files changed, 10 insertions(+), 1 deletion(-) create mode 100644 view/common/block-layout/simpleMDText.phtml diff --git a/src/Site/BlockLayout/SimpleMDText.php b/src/Site/BlockLayout/SimpleMDText.php index b802bfa..48aed09 100644 --- a/src/Site/BlockLayout/SimpleMDText.php +++ b/src/Site/BlockLayout/SimpleMDText.php @@ -75,6 +75,8 @@ class SimpleMDText extends AbstractBlockLayout public function render(PhpRenderer $view, SitePageBlockRepresentation $block) { $parsedown = new Parsedown(); - return $parsedown->text($block->dataValue('markdown_text')); + return $view->partial('common/block-layout/simpleMDText', [ + 'html' => $parsedown->text($block->dataValue('markdown_text')) + ]); } } diff --git a/view/common/block-layout/simpleMDText.phtml b/view/common/block-layout/simpleMDText.phtml new file mode 100644 index 0000000..3aa9cae --- /dev/null +++ b/view/common/block-layout/simpleMDText.phtml @@ -0,0 +1,7 @@ + + +
+ + + +