1
0
mirror of https://github.com/typemill/typemill.git synced 2025-08-06 14:16:46 +02:00

translations integrated, hero images, image classes

This commit is contained in:
trendschau
2020-05-01 19:54:55 +02:00
parent df61395649
commit d273c5ea88
27 changed files with 326 additions and 106 deletions

View File

@@ -321,6 +321,28 @@ class ParsedownExtension extends \ParsedownExtra
return $Element;
}
protected function paragraph($Line)
{
$paragraph = array(
'type' => 'Paragraph',
'element' => array(
'name' => 'p',
'handler' => array(
'function' => 'lineElements',
'argument' => $Line['text'],
'destination' => 'elements',
),
),
);
if(isset($Line['text'][1]) && $Line['text'][0] == '!' && $Line['text'][1] == '[')
{
$paragraph['element']['attributes']['class'] = 'p-image';
}
return $paragraph;
}
# Inline Math
# check https://github.com/BenjaminHoegh/ParsedownMath