@vestra-player/sdk 1.5.25 → 1.5.26

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.
package/llms-full.txt CHANGED
@@ -1,4 +1,4 @@
1
- # @vestra-player/sdk 1.5.25: full reference
1
+ # @vestra-player/sdk 1.5.26: full reference
2
2
 
3
3
  > Everything needed to write a Vestra Player plugin (plugin API `vestra/1`): the guides, every public declaration of `@vestra-player/sdk` and `@vestra-player/sdk/testing` with its documentation, and the complete source of the example plugins. Generated from the SDK's sources by scripts/llms.mjs; the short index is llms.txt.
4
4
 
@@ -65,6 +65,29 @@ my-plugin/
65
65
  }
66
66
  ```
67
67
 
68
+ Add a `tsconfig.json` for your editor. The `plugins` entry turns on the SDK's TypeScript plugin, which marks a call whose capability the manifest does not declare as you type (Capabilities):
69
+
70
+ ```json
71
+ {
72
+ "compilerOptions": {
73
+ "target": "ES2023",
74
+ "module": "NodeNext",
75
+ "moduleResolution": "NodeNext",
76
+ "strict": true,
77
+ "noEmit": true,
78
+ "allowImportingTsExtensions": true,
79
+ "verbatimModuleSyntax": true,
80
+ "erasableSyntaxOnly": true,
81
+ "skipLibCheck": true,
82
+ "types": ["node"],
83
+ "plugins": [{ "name": "@vestra-player/sdk/ts-plugin" }]
84
+ },
85
+ "include": ["*.ts", "tests/*.ts"]
86
+ }
87
+ ```
88
+
89
+ In VS Code, open a `.ts` file, run **TypeScript: Select TypeScript Version** and pick **Use Workspace Version** (the TypeScript the SDK installed): editors load a project's language-service plugins only with the project's own TypeScript.
90
+
68
91
  #### The manifest
69
92
 
70
93
  ```json
@@ -81,7 +104,7 @@ my-plugin/
81
104
  - `version` is `x.y.z`; `vestra-plugin build` writes it into the package.
82
105
  - `apiVersion` is always `"vestra/1"` for this major version of the SDK.
83
106
  - `entry` is the entry module: `.ts` while you develop, `.js` after building.
84
- - `capabilities` lists what the plugin may do. A call to a member whose capability is missing fails with `code: "capability"`.
107
+ - `capabilities` lists what the plugin may do. A call to a member whose capability is missing fails with `code: "capability"`; the editor (with the `tsconfig.json` above) and `vestra-plugin check` point such calls out before the plugin runs.
85
108
 
86
109
  Optional display fields (`name`, `author`, `punchline`, `description`, `tags`, `icon`, `readme`, `changelog`, `sourceUrl`, `license`) are shown by the plugin store and the plugin manager, and `minPlayerVersion` names the oldest player that can load the plugin. Every field with its exact rules is in Manifest.
87
110
 
@@ -2271,6 +2294,7 @@ A plugin lists what it may do in the manifest's `capabilities` (Manifest). A cal
2271
2294
  **Also needs** applies to every member of the row: declare those capabilities as well. A few members or options need one more, documented at the member:
2272
2295
 
2273
2296
  - video.filter also needs `events`.
2297
+ - The changes of Subtitles (`select`, `load`, `remove`, `setStyle`) also need `subtitles.read`: they read the current selection first.
2274
2298
  - A `processed` snapshot or export (MediaCapture) also needs `playback.read` and `subtitles.read`.
2275
2299
  - A file resolver (Resolvers.add with file types) also needs `producer.av`.
2276
2300
  - Without `events`, Player.state is read at start and after the plugin's own operations, and `onChange` listeners do not fire for changes made elsewhere.
@@ -2279,6 +2303,21 @@ A plugin lists what it may do in the manifest's `capabilities` (Manifest). A cal
2279
2303
 
2280
2304
  A member not in the table needs no capability: `plugin.tools`, `plugin.storage`, `plugin.system`, `plugin.app`, `plugin.ui` (images and Markdown), `plugin.i18n`, reading window.state, appearance.theme and packages.list. The table is `CAPABILITY_INFO`, which tests can import from `@vestra-player/sdk/testing` to check a manifest (CAPABILITY_INFO).
2281
2305
 
2306
+ #### Catching a missing capability
2307
+
2308
+ The player refuses a request whose capability the manifest does not declare, at run time. The SDK finds such calls earlier, with one rule: the player's own table of which request needs which capability (copied from the player), and the requests each member above sends. Nothing has to be remembered:
2309
+
2310
+ | Where | How |
2311
+ | ----------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
2312
+ | The editor | An error at the member, "`Player.seek` needs the capability "playback.control", which manifest.json does not declare", with the quick fix **Add 'playback.control' to manifest.json**. It comes from the TypeScript plugin `@vestra-player/sdk/ts-plugin`, listed in the project's `tsconfig.json` (`"plugins": [{ "name": "@vestra-player/sdk/ts-plugin" }]`, as in Getting started). In VS Code, run **TypeScript: Select TypeScript Version** → **Use Workspace Version**: editors load a project's plugins only with the project's own TypeScript. `tsc` ignores language-service plugins. |
2313
+ | `vestra-plugin check`, `build` and `pack` | `check` reports each use as `file:line:column` with the member, the capability and the request, and fails; `build` and `pack` run `check` first, so a package cannot be made with a missing capability. `check --json` prints the findings as JSON (Command line). |
2314
+
2315
+ The TypeScript plugin runs inside the editor's TypeScript server, on the editor's own Node.js, and needs that Node.js to be version 22.12 or later (the plugin is an ES module loaded with `require()`; the SDK itself needs 26, but the editor brings its own); current VS Code qualifies. With an older one the server logs that it could not load `@vestra-player/sdk/ts-plugin` and the editor shows no capability errors; `vestra-plugin check` still reports them. The quick fix edits the saved `manifest.json` (editors do not share unsaved JSON buffers with the TypeScript server) and keeps its layout and line endings.
2316
+
2317
+ The manifest is the nearest `manifest.json` above the file. Only the plugin's own code is checked: `tests/` (tests choose their capabilities in `startPlugin`), `node_modules/`, `dist/` and `vendor/` are not. A member needs the capabilities its requests need and those capabilities' **Also needs**, so a `video.filter` without `playback.read` is reported too.
2318
+
2319
+ The check follows types, not names: `plugin.player.seek`, `const { player } = plugin; player.seek(…)`, a function taking a `Player`, `plugin.clipboard["readText"]` and members of objects other members return (`panel.onChange` on a mounted panel) are all found. Not found: access with a computed name (`player[name]`), values typed `any`, plain JavaScript without types, and options that need more than the member (a `processed` capture, a file resolver). The player's check at run time stays: it is the boundary, since a plugin can bypass the SDK.
2320
+
2282
2321
  ## Reference: Limits
2283
2322
 
2284
2323
  The player bounds what one request may cost it. The limits are guards against runaway plugins, not sizes to aim for: a plugin that needs to come close to one usually needs a different design (send the rows near the view, not the whole list). The SDK checks the same limits before it sends a request, so a plugin's own tests hit them too (TestHost enforces them). A name in code style is a constant you can import from `@vestra-player/sdk/testing`.
@@ -3095,13 +3134,14 @@ Struct **`MarkdownBlock`**: One displayed block. Plugins only pass these through
3095
3134
 
3096
3135
  ```text
3097
3136
  usage: vestra-plugin <check|build|test|pack> [plugin-dir...] [--version x.y.z] [--out dir]
3137
+ vestra-plugin check [plugin-dir...] --json
3098
3138
  vestra-plugin i18n extract [plugin-dir...] [--locale <lang>]...
3099
3139
  vestra-plugin i18n check [plugin-dir...]
3100
3140
  ```
3101
3141
 
3102
3142
  | Command | Does |
3103
3143
  | --- | --- |
3104
- | `vestra-plugin check` | strict type check of the plugin's .ts files and tests/*.ts |
3144
+ | `vestra-plugin check` | strict type check of the plugin's .ts files and tests/*.ts (then every use of an API member whose capability manifest.json does not declare: file:line, member, capability; fails on any; --json prints the findings as JSON) |
3105
3145
  | `vestra-plugin build` | check, then write dist/: .ts → .js with types stripped, other package files copied, dist/manifest.json with `version` |
3106
3146
  | `vestra-plugin test` | node --test on tests/*.test.{ts,mjs} |
3107
3147
  | `vestra-plugin pack` | build, then dist/ → <out>/<id>-<version>.vxp (a zip; default out: the current directory) with its sha256 and size |
@@ -3114,6 +3154,7 @@ Exit codes: 0 on success, 1 when a command failed for any of the directories (ea
3114
3154
 
3115
3155
  - **The manifest first.** Every command checks `manifest.json` against the player's own rules (Manifest) before anything else. `check` also prints hints that do not fail, such as an id without the `<owner>.` prefix the official repository needs.
3116
3156
  - **Type checking** extends the nearest `tsconfig.json` at or above the plugin directory (up to the repository root), else built-in strict settings (`strict`, `NodeNext`, `verbatimModuleSyntax`, `erasableSyntaxOnly`). Only the plugin's own files and `tests/` are checked, with the SDK's own TypeScript 5.x.
3157
+ - **Capabilities.** After the type check, `check` reports every use of an API member whose capability `manifest.json` does not declare (`file:line:column`, the member, the capability, the request) and fails; `build` and `pack` run `check` first. Only the plugin's own code is checked, not `tests/`. The same check runs in the editor (Capabilities). `check --json` prints, instead of the text, one JSON array with an entry per plugin directory: `directory`, `plugin`, `findings` (each with `file` (absolute), `line` and `column` (1-based), `start` and `length` (the member's name as a UTF-16 offset and length in the file, as TypeScript counts), `api`, `capability`, `method`, `message`, and `requiredBy` when the capability is another one's **Also needs**) and `error` when the directory failed.
3117
3158
  - **`import type` only.** A plugin never imports SDK code at run time; `build` fails when the output still refers to `@vestra-player/sdk`. Tests import `@vestra-player/sdk/testing` freely.
3118
3159
  - **Translations.** With a `locales/` folder, `check` prints the `i18n check` problems as warnings and `build` compiles each `locales/<lang>.po` to `dist/locales/<lang>.json` (Translate a plugin).
3119
3160
 
@@ -5730,7 +5771,8 @@ interface SubtitleConditional {
5730
5771
  ### Subtitles
5731
5772
 
5732
5773
  `plugin.subtitles`: tracks, uploads and style. Reading needs
5733
- `subtitles.read`, changes need `subtitles.control`.
5774
+ `subtitles.read`; changes need `subtitles.control` and also
5775
+ `subtitles.read`, since they read the current selection first.
5734
5776
 
5735
5777
  ```ts
5736
5778
  interface Subtitles {
@@ -7892,8 +7934,11 @@ interface CapabilityInfo {
7892
7934
 
7893
7935
  Every manifest capability the player knows (`vestra/1`), in the player's
7894
7936
  order, with the members it opens, the capabilities they also need and the
7895
- store's wording. The player's tests check that the names agree with the
7896
- player's `host/src/plugins.rs` and the labels with its plugin store.
7937
+ store's wording. Built from the player's own capability table (its
7938
+ `src/host/capabilities.json`, copied into the SDK) and the requests each
7939
+ member sends, the same rule `vestra-plugin check` and the SDK's
7940
+ TypeScript plugin apply; the player's tests check that the copy is
7941
+ current.
7897
7942
 
7898
7943
  A member not listed under any capability needs none (`plugin.tools`,
7899
7944
  `plugin.storage`, `plugin.system`, `plugin.app`, `plugin.ui`,
package/llms.txt CHANGED
@@ -1,6 +1,6 @@
1
1
  # Vestra Player SDK
2
2
 
3
- > @vestra-player/sdk 1.5.25: write plugins for Vestra Player in TypeScript (plugin API `vestra/1`). A plugin is a folder with `manifest.json` and an entry module whose default export `activate(plugin)` the player calls; it runs in its own Node.js process. Everything a plugin creates (commands, windows, panels, filters, listeners…) is a handle that is released automatically when the plugin stops. L<n> are line numbers in llms-full.txt, next to this file: every page, declaration and example.
3
+ > @vestra-player/sdk 1.5.26: write plugins for Vestra Player in TypeScript (plugin API `vestra/1`). A plugin is a folder with `manifest.json` and an entry module whose default export `activate(plugin)` the player calls; it runs in its own Node.js process. Everything a plugin creates (commands, windows, panels, filters, listeners…) is a handle that is released automatically when the plugin stops. L<n> are line numbers in llms-full.txt, next to this file: every page, declaration and example.
4
4
 
5
5
  **Rules**
6
6
 
@@ -33,7 +33,7 @@ my-plugin/
33
33
  }
34
34
  ```
35
35
 
36
- Fields: `id`, `version`, `apiVersion`, `entry`, `capabilities`, `name`, `author`, `punchline`, `description`, `tags`, `icon`, `readme`, `changelog`, `sourceUrl`, `license`, `minPlayerVersion`; unknown fields and capabilities are rejected. Rules and limits: L2172–2238.
36
+ Fields: `id`, `version`, `apiVersion`, `entry`, `capabilities`, `name`, `author`, `punchline`, `description`, `tags`, `icon`, `readme`, `changelog`, `sourceUrl`, `license`, `minPlayerVersion`; unknown fields and capabilities are rejected. Rules and limits: L2195–2261.
37
37
 
38
38
  **main.ts**
39
39
 
@@ -76,9 +76,9 @@ export default async function activate(plugin: Plugin) {
76
76
  - `ui.settings`: Settings.page/show
77
77
  - `ui.theme`: Appearance.set/setLanguage
78
78
  - `secrets`: Secrets.get/set/delete
79
- - No capability: `tools`, `storage`, `system`, `app`, `ui` (images and Markdown), `i18n`, reading window.state, appearance.theme and packages.list. Details: L2239–2281.
79
+ - No capability: `tools`, `storage`, `system`, `app`, `ui` (images and Markdown), `i18n`, reading window.state, appearance.theme and packages.list. Details: L2262–2320.
80
80
 
81
- **Test**: `tests/*.test.ts` with `node:test`, run by `vestra-plugin test`. `startPlugin(activate, { directory: new URL("..", import.meta.url) })` from `@vestra-player/sdk/testing` returns `{ host, stop }`; `host` is a TestHost (an in-memory player): `host.setSource(…)`, `host.command(id).run()`, `host.press(key)`, `await host.settle()`, then assert on `host.osd`, `host.window(id).props`… Guide: L1635–1823; TestHost: L7019.
81
+ **Test**: `tests/*.test.ts` with `node:test`, run by `vestra-plugin test`. `startPlugin(activate, { directory: new URL("..", import.meta.url) })` from `@vestra-player/sdk/testing` returns `{ host, stop }`; `host` is a TestHost (an in-memory player): `host.setSource(…)`, `host.command(id).run()`, `host.press(key)`, `await host.settle()`, then assert on `host.osd`, `host.window(id).props`… Guide: L1658–1846; TestHost: L7061.
82
82
 
83
83
  **Command line**
84
84
 
@@ -106,39 +106,39 @@ export default async function activate(plugin: Plugin) {
106
106
  - `limit`: A player-wide limit was reached, a property value is over the limits of PropValue
107
107
  - `reserved`: The id is `vestra` or starts with `vestra.`
108
108
  - `versionMismatch`: The package needs a newer player or another `apiVersion`
109
- - Others: PluginError, llms-full.txt L3190.
109
+ - Others: PluginError, llms-full.txt L3231.
110
110
 
111
111
  ## Reference
112
112
 
113
113
  - [llms-full.txt](https://vestrasys.github.io/vestra-player-sdk/llms-full.txt), also node_modules/@vestra-player/sdk/llms-full.txt; the pages are on the [site](https://vestrasys.github.io/vestra-player-sdk/).
114
- - Tutorials: Getting started L9–214
115
- - Concepts: How a plugin runs L215–385; Commands, menus and key bindings L386–483; Playback state, controls and sources L484–629; Video and audio processing L630–708; Windows, panels, settings pages, dialogs and the OSD L709–997
116
- - How-to: Keep a slider responsive while dragging L998–1172; Remember a window's state between runs L1173–1302; Translate a plugin L1303–1486; Migrate a plugin to English source text L1487–1634; Test a plugin L1635–1823; Publish a plugin L1824–1912; Migrating off package rollback (1.5.16, removed in 1.5.17) L1913–1988
117
- - Guidelines: Interface guidelines L1989–2073; Menu guidelines L2074–2171
118
- - Reference: Manifest L2172–2238; Capabilities L2239–2281; Limits L2282–2386; Commands, menus and bindings L2387–2855; Platforms L2856–2884; Theme L2885–3091; Command line L3092–3147
119
- - [API: @vestra-player/sdk](https://vestrasys.github.io/vestra-player-sdk/modules/_vestra-player_sdk.html): L3148–6854
120
- - [API: @vestra-player/sdk/testing](https://vestrasys.github.io/vestra-player-sdk/modules/_vestra-player_sdk_testing.html): L6855–8257
114
+ - Tutorials: Getting started L9–237
115
+ - Concepts: How a plugin runs L238–408; Commands, menus and key bindings L409–506; Playback state, controls and sources L507–652; Video and audio processing L653–731; Windows, panels, settings pages, dialogs and the OSD L732–1020
116
+ - How-to: Keep a slider responsive while dragging L1021–1195; Remember a window's state between runs L1196–1325; Translate a plugin L1326–1509; Migrate a plugin to English source text L1510–1657; Test a plugin L1658–1846; Publish a plugin L1847–1935; Migrating off package rollback (1.5.16, removed in 1.5.17) L1936–2011
117
+ - Guidelines: Interface guidelines L2012–2096; Menu guidelines L2097–2194
118
+ - Reference: Manifest L2195–2261; Capabilities L2262–2320; Limits L2321–2425; Commands, menus and bindings L2426–2894; Platforms L2895–2923; Theme L2924–3130; Command line L3131–3188
119
+ - [API: @vestra-player/sdk](https://vestrasys.github.io/vestra-player-sdk/modules/_vestra-player_sdk.html): L3189–6896
120
+ - [API: @vestra-player/sdk/testing](https://vestrasys.github.io/vestra-player-sdk/modules/_vestra-player_sdk_testing.html): L6897–8302
121
121
 
122
122
  ## API
123
123
 
124
124
  Where each module of `plugin` (`plugin.<module>`) is declared:
125
125
 
126
- - Plugin L3382, Scope L3251, PluginError L3190, Disposable L3163
127
- - Commands L3594; Windows L3824; Panels L4467; Dialogs L4753; Player L5220; video: VideoFilter L5527, VideoView L5590, RenderOptions L5632; audio: AudioFilter L5551; Subtitles L5730; media: MediaCapture L5890; Resolvers L5995; Packages L6237; Osd L5463; Host L5394; Clipboard L6369; Power L6389; Tools L6422; Storage L6465; System L6552; Secrets L6570; window: MainWindow L4590; App L4671; Bindings L6339; Ui L3699; Timeline L4547; Drops L4123; Appearance L4152; I18n L4294; Settings L4400.
126
+ - Plugin L3423, Scope L3292, PluginError L3231, Disposable L3204
127
+ - Commands L3635; Windows L3865; Panels L4508; Dialogs L4794; Player L5261; video: VideoFilter L5568, VideoView L5631, RenderOptions L5673; audio: AudioFilter L5592; Subtitles L5771; media: MediaCapture L5932; Resolvers L6037; Packages L6279; Osd L5504; Host L5435; Clipboard L6411; Power L6431; Tools L6464; Storage L6507; System L6594; Secrets L6612; window: MainWindow L4631; App L4712; Bindings L6381; Ui L3740; Timeline L4588; Drops L4164; Appearance L4193; I18n L4335; Settings L4441.
128
128
 
129
129
  ## Examples
130
130
 
131
131
  Tested plugins in [examples/](https://github.com/vestrasys/vestra-player-sdk/tree/main/examples):
132
132
 
133
- - hello: The README Quick start: one menu command and an on-screen message. L8681–8770
134
- - blur: A tool window with one slider that blurs the playing video. L8771–9032
135
- - signal-generator: Generates its own video and audio: colour bars and a 1 kHz tone. L9033–9365
136
- - bookmark: A tool window bound to the playback state: remember the position and jump back to it. L9366–9550
137
- - panel-menu: A sidebar panel with its own right-click menu. L9551–9756
138
- - menus: Radio menu items, separator groups and a menu item whose title changes. L9757–9916
139
- - theme-widgets: A tool window drawn with the player's theme and widgets. L9917–10080
140
- - markdown: A window that shows a Markdown document. L10081–10275
141
- - i18n: A plugin in the player's language: English source text, a Chinese translation. L10276–10443
133
+ - hello: The README Quick start: one menu command and an on-screen message. L8726–8815
134
+ - blur: A tool window with one slider that blurs the playing video. L8816–9077
135
+ - signal-generator: Generates its own video and audio: colour bars and a 1 kHz tone. L9078–9410
136
+ - bookmark: A tool window bound to the playback state: remember the position and jump back to it. L9411–9595
137
+ - panel-menu: A sidebar panel with its own right-click menu. L9596–9801
138
+ - menus: Radio menu items, separator groups and a menu item whose title changes. L9802–9961
139
+ - theme-widgets: A tool window drawn with the player's theme and widgets. L9962–10125
140
+ - markdown: A window that shows a Markdown document. L10126–10320
141
+ - i18n: A plugin in the player's language: English source text, a Chinese translation. L10321–10488
142
142
 
143
143
  ## Optional
144
144
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vestra-player/sdk",
3
- "version": "1.5.25",
3
+ "version": "1.5.26",
4
4
  "description": "Plugin API types, test host and plugin CLI for Vestra Player (apiVersion vestra/1)",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -24,6 +24,10 @@
24
24
  "types": "./dist/player-runtime.d.ts",
25
25
  "default": "./dist/player-runtime.js"
26
26
  },
27
+ "./ts-plugin": {
28
+ "types": "./ts-plugin/index.d.ts",
29
+ "default": "./ts-plugin/index.js"
30
+ },
27
31
  "./llms.txt": "./llms.txt",
28
32
  "./llms-full.txt": "./llms-full.txt",
29
33
  "./package.json": "./package.json"
@@ -35,6 +39,7 @@
35
39
  "dist",
36
40
  "bin",
37
41
  "slint",
42
+ "ts-plugin",
38
43
  "README.md",
39
44
  "CHANGELOG.md",
40
45
  "LICENSE",
@@ -43,6 +48,7 @@
43
48
  ],
44
49
  "scripts": {
45
50
  "build": "node scripts/build.mjs",
51
+ "capabilities:sync": "node scripts/capabilities-sync.mjs",
46
52
  "check": "tsc -p tsconfig.check.json",
47
53
  "doc-lint": "node scripts/doc-lint.mjs",
48
54
  "docs": "typedoc",
@@ -50,8 +56,8 @@
50
56
  "docs:llms": "node scripts/llms.mjs",
51
57
  "docs:tables": "node scripts/doc-tables.mjs",
52
58
  "examples": "node scripts/check-examples.mjs",
53
- "format": "prettier --write \"{src,test,bin,scripts,examples}/**/*.{ts,mjs}\" package.json tsconfig.json tsconfig.check.json typedoc.json .oxlintrc.json examples/tsconfig.json \"examples/*/package.json\"",
54
- "format:check": "prettier --check \"{src,test,bin,scripts,examples}/**/*.{ts,mjs}\" package.json tsconfig.json tsconfig.check.json typedoc.json .oxlintrc.json examples/tsconfig.json \"examples/*/package.json\"",
59
+ "format": "prettier --write \"{src,test,bin,scripts,examples}/**/*.{ts,mjs}\" ts-plugin/index.js ts-plugin/index.d.ts package.json tsconfig.json tsconfig.check.json typedoc.json .oxlintrc.json examples/tsconfig.json \"examples/*/package.json\"",
60
+ "format:check": "prettier --check \"{src,test,bin,scripts,examples}/**/*.{ts,mjs}\" ts-plugin/index.js ts-plugin/index.d.ts package.json tsconfig.json tsconfig.check.json typedoc.json .oxlintrc.json examples/tsconfig.json \"examples/*/package.json\"",
55
61
  "lint": "oxlint --deny-warnings",
56
62
  "pack:check": "node scripts/check-pack.mjs",
57
63
  "pack:smoke": "node scripts/smoke-pack.mjs",
@@ -0,0 +1,8 @@
1
+ // @vestra-player/sdk/ts-plugin: the TypeScript language-service plugin. List
2
+ // it in tsconfig.json; it is not meant to be imported.
3
+ import type ts from "typescript";
4
+
5
+ declare function init(modules: {
6
+ typescript: typeof ts;
7
+ }): ts.server.PluginModule;
8
+ export = init;
@@ -0,0 +1,6 @@
1
+ // @vestra-player/sdk/ts-plugin: the TypeScript server loads language-service
2
+ // plugins with require() and Node 10 resolution (no package.json "exports"),
3
+ // hence this CommonJS directory. The plugin itself is dist/ts-plugin.js, an
4
+ // ES module without top-level await, which require() loads (Node 22.12+).
5
+ "use strict";
6
+ module.exports = require("../dist/ts-plugin.js").default;
@@ -0,0 +1,3 @@
1
+ {
2
+ "type": "commonjs"
3
+ }