mirror of
https://github.com/livebook-dev/livebook.git
synced 2024-09-20 01:55:56 +08:00
Add setSmartCellEditorIntellisenseNode to iframe (#2230)
This commit is contained in:
parent
b3f7366a8f
commit
1c92311f8d
|
@ -26,7 +26,7 @@ import { sha256Base64 } from "../../lib/utils";
|
|||
// (2): https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe#attr-sandbox
|
||||
// (3): https://developer.mozilla.org/en-US/docs/Web/Security/Secure_Contexts
|
||||
|
||||
const IFRAME_SHA256 = "48LZtKkFYMd+4gsmVvbhvw9mTpJPw+ItRdGxPPs+5xw=";
|
||||
const IFRAME_SHA256 = "wcqj5QWCo66osdAWDnEgPRFyL7nfe8oNqNggnw4vvW8=";
|
||||
|
||||
export function initializeIframeSource(iframe, iframePort, iframeUrl) {
|
||||
const url = getIframeUrl(iframePort, iframeUrl);
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<base target="_parent">
|
||||
<base target="_parent" />
|
||||
<title>Output</title>
|
||||
<style>
|
||||
html,
|
||||
|
@ -102,6 +102,14 @@
|
|||
state.secretHandler = callback;
|
||||
postMessage({ type: "selectSecret", preselectName, options });
|
||||
},
|
||||
|
||||
setSmartCellEditorIntellisenseNode(node, cookie) {
|
||||
postMessage({
|
||||
type: "setSmartCellEditorIntellisenseNode",
|
||||
node,
|
||||
cookie,
|
||||
});
|
||||
},
|
||||
};
|
||||
|
||||
window.addEventListener("message", (event) => {
|
||||
|
|
Loading…
Reference in a new issue