(handler, type)
| 218 | }; |
| 219 | |
| 220 | const makeEditorDiv = (handler, type) => { |
| 221 | const editorDiv = document.createElement("div"); |
| 222 | editorDiv.className = `${type}-editor-input`; |
| 223 | editorDiv.setAttribute("aria-label", "Python Script Area"); |
| 224 | |
| 225 | const runButton = makeRunButton(handler, type); |
| 226 | const editorShadowContainer = document.createElement("div"); |
| 227 | |
| 228 | // avoid outer elements intercepting key events (reveal as example) |
| 229 | editorShadowContainer.addEventListener("keydown", (event) => { |
| 230 | event.stopPropagation(); |
| 231 | }); |
| 232 | |
| 233 | editorDiv.append(runButton, editorShadowContainer); |
| 234 | |
| 235 | return editorDiv; |
| 236 | }; |
| 237 | |
| 238 | const makeOutDiv = (type) => { |
| 239 | const outDiv = document.createElement("div"); |
no test coverage detected