Skip to main content

document_to_copied_blocks

Function document_to_copied_blocks 

Source
pub fn document_to_copied_blocks(doc: &Document) -> CopiedBlocks
Expand description

Promote a flat Document into the clipboard {roots, byId} shape. Descends block.children so tables, toggle descendants, and any future parent→child references survive the conversion.

Single source of truth for the “Document → CopiedBlocks” shape transform — the WASM layer re-exports it verbatim instead of maintaining a near-identical copy.