feat(post-form): EasyMDE editor + /post-scoped ESM bundle (U3)

Add a page-scoped js/src/post-form.js bundle (built ESM + code-splitting
so U4's heic-to becomes a deferred chunk) loaded only by post-form.html.twig
via a new base head_assets block. EasyMDE replaces the bare textarea with a
minimal toolbar (bold/italic/list/link/preview), FA-free via CSS glyphs, and
syncs codemirror.save() on change + capture-phase submit so the inline
required-field validator and payload see the live value.

Refs R7, R15, KTD2, KTD3.
This commit is contained in:
2026-07-04 15:40:28 +02:00
parent 87e216594e
commit 6282528dd8
8 changed files with 275 additions and 1 deletions
@@ -1,5 +1,10 @@
{% extends 'default.html.twig' %}
{% block head_assets %}
{% do assets.addCss('theme://css-compiled/post-form.css') %}
<script type="module" src="{{ url('theme://js/post/post-form.js') }}"></script>
{% endblock %}
{% block content %}
<div class="post-form-wrap">
<h1>New Entry</h1>