Skip to content

Kirby 3.7.5

markdown

A plaintext HTML/markdown/kirbytext block. This is perfect to combine WYSIWYG content with custom HTML, Kirbytext or Markdown.

Preview

Default files

Snippet

<?php /** @var \Kirby\Cms\Block $block */ ?>
<?= $block->text()->kt();

To overwrite this default snippet, place your custom file in /site/snippets/blocks/markdown.php.

Blueprint

name: field.blocks.markdown.name
icon: markdown
preview: markdown
wysiwyg: true
fields:
  text:
    label: field.blocks.markdown.label
    placeholder: field.blocks.markdown.placeholder
    type: textarea
    buttons: false
    font: monospace

To overwrite this default blueprint, place your custom file in /site/blueprints/blocks/markdown.yml.

Vue component

kirby/blob/main/panel/src/components/Forms/Blocks/Types/Markdown.vue