moved frontend to event driven bus, added more simulation stuff

This commit is contained in:
Parker TenBroeck 2026-01-11 00:30:06 -05:00
parent c7309a75d9
commit 8c8bb103b2
17 changed files with 767 additions and 493 deletions

View file

@ -10,9 +10,9 @@ export type Category =
| "NTM";
export class Example {
category: Category;
title: string;
machine: string;
readonly category: Category;
readonly title: string;
readonly machine: string;
constructor(category: Category, title: string, machine: string) {
this.category = category;
@ -21,7 +21,7 @@ export class Example {
}
}
export const examples: Example[] = [
export const examples: readonly Example[] = [
new Example(
"Tutorial",
"DFA",
@ -174,7 +174,7 @@ const CATEGORY_ORDER: Category[] = [
function buildExamplesDropdown(
selectEl: HTMLSelectElement,
examples: Example[],
examples: readonly Example[],
onPick?: (ex: Example) => void,
) {
// Clear everything except the first placeholder option (if present)