You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+3Lines changed: 3 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,3 +34,6 @@ First tagged release of the browser playground.
34
34
### Changed
35
35
36
36
- Updated the playground's complete-feature example links and visible source-extension copy from `.ml` to `.multi` to match the renamed upstream example files.
37
+
- Migrated the browser editor from CodeMirror 5 to Monaco Editor while preserving the existing Pyodide runtime flow, share links, theme toggle, keyboard shortcuts, and split-pane behavior.
38
+
- Pinned browser syntax highlighting to `tree-sitter-multilingual` by shipping a generated `assets/monarch.json` tokenizer artifact from the grammar repository.
39
+
- Updated the existing CI workflows to check out `multilingualprogramming/tree-sitter-multilingual` and fail if the pinned Monaco tokenizer drifts from the generated upstream artifact.
Copy file name to clipboardExpand all lines: README.md
+4-1Lines changed: 4 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -28,19 +28,22 @@ The playground runs entirely in the browser:
28
28
29
29
-**Pyodide** - CPython 3.12 compiled to WASM; runs the full interpreter
30
30
-**wabt.js** - WABT on WASM; compiles generated WAT to binary WASM in the browser
31
-
-**CodeMirror 5** - editor with syntax highlighting and dark/light theme toggle
31
+
-**Monaco Editor** - browser editor with generated multilingual syntax highlighting and dark/light theme toggle
32
32
33
33
No server is required. The page prefers a local wheel from `assets/wheel_info.json` when present, then falls back to installing `multilingualprogramming` from PyPI via `micropip`.
34
34
35
35
The main document is a thin shell. Playground styles live in `assets/playground.css`, and the application logic is split across `assets/main.js`, `assets/editor.js`, `assets/runtime.js`, `assets/ui.js`, `assets/theme.js`, `assets/i18n.js`, and `assets/examples.js`.
36
36
37
+
The editor syntax layer is generated from the sibling `tree-sitter-multilingual` repository at `https://github.com/multilingualprogramming/tree-sitter-multilingual`. The playground ships a pinned `assets/monarch.json` derived from that grammar so browser highlighting stays aligned with upstream keyword and grammar updates.
38
+
37
39
## Release validation
38
40
39
41
The pinned CI baseline lives in `requirements-build.txt`.
40
42
41
43
This release line is checked in two ways:
42
44
43
45
-`python tools/check_examples.py` executes all bundled example programs in each supported source language.
46
+
-`python tools/check_monarch_sync.py --tree-sitter-root ../tree-sitter-multilingual` verifies that the pinned Monaco tokenizer still matches the generated grammar artifact from `https://github.com/multilingualprogramming/tree-sitter-multilingual`.
44
47
- GitHub Actions runs `.github/workflows/example-executability.yml` on pushes and pull requests.
45
48
- A scheduled compatibility workflow also checks the pinned baseline, the latest published package, and upstream `main`.
Copy file name to clipboardExpand all lines: RELEASE.md
+9-4Lines changed: 9 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -21,20 +21,24 @@ Prepare a playground release when at least one of these changes:
21
21
3. Update visible release copy in [`index.html`](index.html), especially the backend note in the WAT / WASM tab.
22
22
4. Refresh examples and language metadata in [`assets/examples.js`](assets/examples.js), [`assets/editor.js`](assets/editor.js), and related runtime modules if language coverage changed.
23
23
Also verify that visible source-extension copy and upstream example links still match the current example filename convention, currently `.multi`.
24
+
If the grammar repo changed, refresh the pinned Monaco tokenizer asset in [`assets/monarch.json`](assets/monarch.json) from `../tree-sitter-multilingual/generated/monarch.json`.
25
+
The upstream grammar repository is `https://github.com/multilingualprogramming/tree-sitter-multilingual`.
9. Open [`index.html`](index.html) in a browser and smoke-test:
38
+
10. Open [`index.html`](index.html) in a browser and smoke-test:
35
39
language switching, example switching, run/clear/share, output tabs, theme toggle, keyboard navigation, and narrow-screen layout.
36
-
10. Update [`CHANGELOG.md`](CHANGELOG.md).
37
-
11. Prepare outward-facing release notes using the template below.
40
+
11. Update [`CHANGELOG.md`](CHANGELOG.md).
41
+
12. Prepare outward-facing release notes using the template below.
38
42
39
43
## Release note template
40
44
@@ -73,6 +77,7 @@ Highlights in the current release line:
73
77
-`with`, `try/except`, `lambda`, `match/case`, and `async/await`
74
78
-`@property` accessors and bytes literals
75
79
- modular browser assets centered on [`assets/playground.css`](assets/playground.css), [`assets/main.js`](assets/main.js), and [`assets/runtime.js`](assets/runtime.js)
80
+
- Monaco-based browser editing with grammar-generated syntax highlighting
76
81
- improved accessibility and mobile behavior
77
82
- added release validation with [`tools/check_release.py`](tools/check_release.py)
78
83
- added example executability validation with [`tools/check_examples.py`](tools/check_examples.py) and [`.github/workflows/example-executability.yml`](.github/workflows/example-executability.yml)
0 commit comments