Files
museion/docs/devlog
AlexKucera 695ec27e11
CI / ci (push) Canceled after 0s
feat(publish): illustrations travel inline (#34)
A piece's assets/ ink-sketch images publish with it: Send as Draft
first uploads every referenced image to Micro.blog's media endpoint
(q=config discovery, one multipart file POST per FILE — duplicate
refs share an upload), then each ![alt](assets/…) ref REWRITES IN
PLACE with its uploaded URL in the wire content. The image renders
exactly where the writer placed it and the alt rides the markdown;
the piece on disk never changes.

The first shape attached uploads as a Micropub photo property with
mp-photo-alt — live dogfood (2026-11-01) showed the theme renders
properties at the bottom of the post, losing position. No property
ships at all now; inline refs are the only transport, which also
makes the parsed body ref the only way an image ships — the alt
floor at the illustration rail is therefore the only gate a photo
needs (G12: a whitespace-empty alt refuses naming the file before
anything touches the wire; the mentor is never consulted).

Pre-flight gates every payload: the endpoint's exact formats
(PNG/JPEG/GIF/WebP/SVG), path containment resolved through symlinks
(a planted link never uploads outside-file bytes under the writer's
token), all-or-nothing uploads. A URL carrying markdown-active
characters rides the angle form ![alt](<url>) — a plain-paren
destination would close at the first ) and smuggle a live link into
the published post; the frontmatter trust gate does not cover
markdown's grammar.

Finish-audit (three reviewers) drove the angle form, the symlink
containment, the per-file upload dedup, and four pins; all four
behavior guards flip-verified in one batch cycle. Suite 546 passed /
0 failed; swiftformat + swiftlint clean. Ingest UX (drop image onto
the editor) is #141, blocked by this issue.
2026-11-01 21:52:58 +01:00
..