Skip to content

[DO NOT MERGE] Hack a "nearly headless" sim #102

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions src/board/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,13 @@ export function createBoard(notifications: Notifications, fs: FileSystem) {
if (!svg) {
throw new Error("No SVG");
}
// Hack for Oxford student group for a nearly headless sim with a play button.
svg.style.display = "none";
const playButton = document.querySelector(".play-button") as HTMLElement;
playButton.style.width = "100px";
playButton.style.height = "100px";
playButton.style.margin = "0";

return new Board(notifications, fs, svg);
}

Expand Down Expand Up @@ -373,6 +380,9 @@ export class Board {
}

private displayRunningState() {
// Hack for Oxford group.
return;

this.svg.style.opacity = "unset";
const svgButtons = this.svg.querySelectorAll("[role='button']");
for (const button of svgButtons) {
Expand Down