Render the document description format !34

merged merged by cmc on 2026-09-12 02:20 UTC · krz/skunky-art:feat/document-descriptions into main

Discussion

cmc

The actual cause of #3: DeviantArt's editor stores descriptions and comments as a document tree ({"version":1,"document":{...}}), not Draft.js blocks. The parser expected blocks, found none, and rendered every current description empty. 13 of 14 daily deviations sampled today carry the new format.

renderDocument walks the tree: paragraphs, headings, bullet and ordered lists, blockquotes, code blocks, rules and hard breaks; text with bold, italic, underline, strike, code and link marks (DeviantArt's outgoing redirector stripped); da-emote through the emote route by image name or, when the payload names no image, by emote code (the new-format half of #6); da-deviation and da-deviation-thumb as proxied thumbnails linking to the post, gated by VisibleDeviation; da-gif as a link; da-mention as a profile link. Unknown containers render their children, unknown leaves nothing. All strings escaped. Draft.js and plain HTML still dispatch to their existing parsers.

Six fixture tests built from live node shapes, plus a throwaway run over 92 real descriptions and comments fetched from the instance's egress: none rendered empty, none leaked an unproxied wixmp URL.

Closes #3 Closes #6