Skip to main content

Module lens

Module lens 

Source
Expand description

The article lenses: formatted view, source view, edit decoding, and export.

Both lenses render one shared sim_codec_doc::MarkupDoc value. The formatted lens projects semantic blocks to Scene nodes, the source lens shows the deterministic source text for the same markup value, and intent decoding turns validated edit-field gestures into reversible markup edits.

Constants§

ARTICLE_FORMATTED_LENS
The formatted article lens id.
ARTICLE_SOURCE_LENS
The source article lens id.

Functions§

article_formatted
Render the formatted article: outline plus a block canvas.
article_outline
The outline: a tree of the article’s section headings.
article_source
Render the source article as deterministic source text.
export_intermediate
The stable intermediate document value used for export.
export_markdown
Export the document through the shared markup source writer.
markup_edit_from_intent
Decode a document edit Intent into a reversible markup edit.
with_cache
Attach a cached rendered output (a Scene) to an embed block.