diff --git a/docs/kiri-moto/engine-apis.md b/docs/kiri-moto/engine-apis.md index 54d93d59..cd3eaf2e 100644 --- a/docs/kiri-moto/engine-apis.md +++ b/docs/kiri-moto/engine-apis.md @@ -16,13 +16,13 @@ you can view some example of how to use the engine [here](https://grid.space/kir ## Methods | Method | Description | Returns | -| --------------------------- | -------------------------------------------------------------------------------------------------------------- | ----------------- | ------- | ------- | -------- | +| --------------------------- | -------------------------------------------------------------------------------------------------------------- | ----------------- | | `load(url)` | Loads an [STL]() file from a given URL and centers the model. | `Promise` | | `clear()` | Clears all objects from workspace. | `void` | | `parse(data)` | Parses raw [STL]() data and loads it as a centered widget. | `Promise` | | `setListener(listener)` | Sets an event listener function to receive engine progress updates | `Engine` | | `setRender(bool)` | Enables or disables rendering. | `Engine` | -| `setMode(mode)` | Sets the slicing mode where mode is "CAM" | "FDM" | "LASER" | "SLA" . | `Engine` | +| `setMode(mode)` | Sets the slicing mode where mode is "CAM" \| "FDM" \| "LASER" \| "SLA" . | `Engine` | | `setDevice(device)` | Merges a custom device profile into the current settings. | `Engine` | | `setProcess(process)` | Merges custom slicing process parameters. | `Engine` | | `setController(controller)` | Sets the slicing controller settings and starts/stops the worker pool accordingly. | `Engine` | @@ -43,12 +43,13 @@ you can view some example of how to use the engine [here](https://grid.space/kir If a listener is set via `setListener(fn)`, it will be called with events such as: -- `{ loaded, vertices }` — when an STL file is loaded -- `{ parsed, vertices }` — when raw data is parsed -- `{ slice: msg }` — when slicing is complete -- `{ prepare: { update } }` — during toolpath preparation -- `{ prepare: { done: true } }` — when preparation is complete -- `{ export: { segment } }` — during G-code segment export -- `{ export: { done } }` — when export is finished +- `{ loaded, vertices }` — when an STL file is loaded +- `{ parsed, vertices }` — when raw data is parsed +- `{ slice: msg }` — when slicing is complete +- `{ prepare: { update } }` — during toolpath preparation +- `{ prepare: { done: true } }` — when preparation is complete +- `{ export: { segment } }` — during G-code segment export +- `{ export: { done } }` — when export is finished These allow for building progress indicators or responding to processing stages. +