pub fn assembly_apply_document_json(
document_json: &str,
) -> Result<String, JsValue>Expand description
Fold the session’s solved state into a history DOCUMENT: replaces the
top-level assembly block and writes each pending pose / grounded flag
into the owning feature’s inputParams (matched by inputParams.id —
generic JSON, no dependency on the ACOMP feature shape). The app calls this
on its document before persisting or re-running (the pose-authority
write-back, spec §6 step 4).