Skip to content

Commit

Permalink
Improve logging
Browse files Browse the repository at this point in the history
  • Loading branch information
jorg-vr committed Oct 24, 2023
1 parent 2f2f1b8 commit d41b5bf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion app/assets/javascripts/tutor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -136,10 +136,11 @@ export function initTutor(submissionCode: string): void {
const modal = document.querySelector("#tutor #info-modal");

const content = document.querySelector("#tutorcontent");
console.log("create_tutor", content, codeTrace);
console.log("create_tutor", content, codeTrace && codeTrace.length > 0);
if (content) {
content.innerHTML = `<iframe id="tutorviz" width="100%" frameBorder="0" src="${window.dodona.sandboxUrl}/tutorviz/tutorviz.html"></iframe>`;
document.querySelector("#tutorviz").addEventListener("load", () => {
console.log("load");
window.iFrameResize({ checkOrigin: false, onInit: frame => frame.iFrameResizer.sendMessage(JSON.parse(codeTrace)), scrolling: "omit" }, "#tutorviz");
});
}
Expand Down

0 comments on commit d41b5bf

Please sign in to comment.