ZDDC/zddc/internal/convert
ZDDC 85e0061d6c feat(editor): hint recognized front-matter fields via server placeholder
The markdown editor's YAML front-matter pane was a bare textarea, so authors
had no way to discover the keys the converter honours — notably `doctype:`
(report|letter|specification) and `numbering:`, which have no other source.

Add a single server-side source of truth, convert.RecognizedFrontMatter() +
convert.FrontMatterPlaceholder(), and expose it as JSON at GET /.api/frontmatter
(handler.ServeFrontMatterTemplate; read-only, no auth — leaks only documented
field names). The browse editor fetches it once (server mode) and sets the
front-matter textarea's placeholder to the greyed hint, so an empty pane shows
the recognized keys with one-line hints. It's placeholder-only: it inserts
nothing, vanishes on the first keystroke, and arbitrary keys remain free —
front matter is still passed through to pandoc untouched. file:// mode shows no
placeholder (conversion is server-only).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-05 08:23:25 -05:00
..
templates feat(server): multi-template MD→HTML with .zddc.d/templates cascade 2026-06-04 14:18:40 -05:00
convert.go feat(editor): hint recognized front-matter fields via server placeholder 2026-06-05 08:23:25 -05:00
convert_test.go feat(server): full md/docx/html conversion matrix + base64 image inlining 2026-06-04 21:02:11 -05:00
embed.go feat(server): full md/docx/html conversion matrix + base64 image inlining 2026-06-04 21:02:11 -05:00
health.go refactor(convert): wrapper-in-image owns the sandbox; Go just exec's binaries 2026-05-19 07:47:58 -05:00
inline-media.lua feat(server): full md/docx/html conversion matrix + base64 image inlining 2026-06-04 21:02:11 -05:00
runner.go feat(server): full md/docx/html conversion matrix + base64 image inlining 2026-06-04 21:02:11 -05:00
singleflight.go feat(zddc): MD→{docx,html,pdf} server-side conversion via stock pandoc + chromium containers 2026-05-13 10:33:56 -05:00
sysprocattr_linux.go feat(zddc): MD→{docx,html,pdf} server-side conversion via stock pandoc + chromium containers 2026-05-13 10:33:56 -05:00
sysprocattr_other.go feat(zddc): MD→{docx,html,pdf} server-side conversion via stock pandoc + chromium containers 2026-05-13 10:33:56 -05:00
sysprocattr_windows.go feat(zddc): MD→{docx,html,pdf} server-side conversion via stock pandoc + chromium containers 2026-05-13 10:33:56 -05:00
templatesync_test.go feat(server): multi-template MD→HTML with .zddc.d/templates cascade 2026-06-04 14:18:40 -05:00