@beff/aula 0.6.1 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Binary file
package/dist/run.js CHANGED
@@ -67,10 +67,11 @@ const NODE = { frames: v8Frames, name: (file) => file, exists: () => true };
67
67
  export function definedAt(definition, host = NODE) {
68
68
  return host.frames(definition.call)[1] ?? { function: "", file: "", line: 0, col: 0 };
69
69
  }
70
- /** The location of a syntax error in an imported module: V8 starts the stack with `file:line`. */
70
+ /** The location of a syntax error in an imported module: V8 and Node's TypeScript parser start
71
+ * the stack with `file:line` (either a `file:` URL or an absolute path). */
71
72
  function syntaxLocation(stack) {
72
73
  const first = stack.split("\n")[0] ?? "";
73
- const m = /^(file:\S+?):(\d+)$/.exec(first);
74
+ const m = /^((?:file:|\/)\S+?):(\d+)(?::\d+)?$/.exec(first);
74
75
  if (m?.[1] === undefined || m[2] === undefined)
75
76
  return undefined;
76
77
  return { file: framePath(m[1]), line: Number(m[2]) };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@beff/aula",
3
- "version": "0.6.1",
3
+ "version": "0.7.0",
4
4
  "type": "module",
5
5
  "description": "The aula engine for narrated explainer videos: the Manim CE API, defineChapter, its rows, readChapter and renderChapter over a Rust WebAssembly component. Chapters and kits import it; the aula command is @beff/aula-cli.",
6
6
  "license": "MIT AND GPL-3.0-or-later",