Closes the toolbox and similar UX.
Optionaloptions: { advanced?: boolean }Hides the simulator. The user can reverse this via the UI.
Create a URL that can be used to import a project into MakeCode.
This can be useful if MakeCode is embedded in one application but you want to be able to export to non-embedded MakeCode.
The applications must be part of the same site as the process relies on shared client-side storage.
The URL must be used immediately as it won't remain valid if another call is made.
Import a file.
This works with hex and mkcd files.
TODO: Other types may also be supported.
Import a project.
The project needs to have a header.
Otherwise consider newProject
Import a tutorial from markdown text.
See also startActivity.
Open a MakeCode project.
Redo.
Renders an individual block by type (e.g. basic_show_id) to an SVG data URI.
Restarts the simulator.
Change the language restriction (e.g. move to just JavaScript).
Show the simulator. The user can reverse this via the UI.
See https://github.com/microsoft/pxt-microbit/issues/5456
Tutorial tool sharing link ID from https:*makecode.com/tutorial-tool prefixed with 'S' path: 'S96773-99918-18806-19059',
Built-in tutorial path: '/projects/rock-paper-scissors',
GitHub repo (no trailing .md, no blob/main cruft, tag versions)
You get a series of "tutorialevent" actions tracking load and progress which we'd need to add support for at least to error handle the load.
Start the simulator.
Stops the simulator.
Optionaloptions: { unload: boolean }
Optionally unload the simulator (removes its UI)
Switch the MakeCode to blocks mode.
You can find the current mode in the project.
Switch the MakeCode to JavaScript mode.
You can find the current mode in the project.
Switch the MakeCode to JavaScript mode.
You can find the current mode in the project.
Optionaloptions: { invervalSpeed?: number }Undo.
A driver for MakeCode.
This stores state to correlate requests/responses to and from MakeCode.