repl: Process display IDs for updatable displays (#15738)
Release Notes: - Added `update_display_data` support for REPL. https://github.com/user-attachments/assets/d618e457-e314-482e-954a-6384f185629a
This commit is contained in:
parent
68446d2ed1
commit
36b61a8b87
2 changed files with 105 additions and 34 deletions
|
@ -549,6 +549,20 @@ impl Session {
|
|||
self.kernel.set_kernel_info(&reply);
|
||||
cx.notify();
|
||||
}
|
||||
JupyterMessageContent::UpdateDisplayData(update) => {
|
||||
let display_id = if let Some(display_id) = update.transient.display_id.clone() {
|
||||
display_id
|
||||
} else {
|
||||
return;
|
||||
};
|
||||
|
||||
self.blocks.iter_mut().for_each(|(_, block)| {
|
||||
block.execution_view.update(cx, |execution_view, cx| {
|
||||
execution_view.update_display_data(&update.data, &display_id, cx);
|
||||
});
|
||||
});
|
||||
return;
|
||||
}
|
||||
_ => {}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue