@g9tm/app-diagnostic 0.4.0 → 0.5.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.
package/README.md ADDED
@@ -0,0 +1,15 @@
1
+ # @g9tm/app-diagnostic
2
+
3
+ The platform-free TypeScript client of G9AppDiagnostic: the wire profile, the resumable tester-report upload, the recording
4
+ state machine, the tester mode's engine (`TesterEngine`: the draft, the captures, the gesture, the send rules, the outbox and
5
+ the report list) and the live channel (`LiveChannel`). No platform code: a host gives it its files, its media and its HTTP.
6
+
7
+ | Host | Package |
8
+ |---|---|
9
+ | A browser, or the web layer of a native shell | [`@g9tm/app-diagnostic-web`](https://www.npmjs.com/package/@g9tm/app-diagnostic-web) |
10
+ | Capacitor | [`@g9tm/app-diagnostic-capacitor`](https://www.npmjs.com/package/@g9tm/app-diagnostic-capacitor) |
11
+ | Tauri v2 | [`@g9tm/app-diagnostic-tauri`](https://www.npmjs.com/package/@g9tm/app-diagnostic-tauri) |
12
+ | Lynx | [`@g9tm/app-diagnostic-lynx`](https://www.npmjs.com/package/@g9tm/app-diagnostic-lynx) |
13
+
14
+ Erasable TypeScript only, shipped as source (`src/index.ts`): a bundler or Node's type stripping (≥ 22.6) reads it.
15
+ `npm test` runs its tests against a stand-in gateway that keeps the contract. MIT.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@g9tm/app-diagnostic",
3
- "version": "0.4.0",
3
+ "version": "0.5.0",
4
4
  "description": "Device diagnostics client for apps in the field: tester reports (resumable upload) to a G9AppDiagnostic gateway. No platform code: the host reads the archive.",
5
5
  "type": "module",
6
6
  "main": "src/index.ts",
@@ -13,8 +13,15 @@
13
13
  },
14
14
  "./package.json": "./package.json"
15
15
  },
16
- "files": ["src"],
17
- "scripts": { "test": "node --test test/*.test.ts" },
16
+ "files": [
17
+ "src",
18
+ "README.md"
19
+ ],
20
+ "scripts": {
21
+ "test": "node --test test/*.test.ts"
22
+ },
18
23
  "license": "MIT",
19
- "engines": { "node": ">=22.6" }
24
+ "engines": {
25
+ "node": ">=22.6"
26
+ }
20
27
  }
@@ -46,6 +46,8 @@ export interface ITesterHost {
46
46
  readonly platform: string;
47
47
  /** The app's version as reports carry it. */
48
48
  readonly appVersion: string;
49
+ /** Which of the gateway's apps this is (WebDiagnostic:Apps[].Id, 0.5.0); absent = the gateway matches the host it used. */
50
+ readonly appId?: string;
49
51
  }
50
52
 
51
53
  /** A finished recording: the file stays where the recorder wrote it. */
@@ -809,6 +811,7 @@ export class TesterEngine {
809
811
  ...(manifest.kind ? { kind: manifest.kind } : {}),
810
812
  ...(manifest.branch ? { branch: manifest.branch } : {}),
811
813
  ...(manifest.commit ? { commit: manifest.commit } : {}),
814
+ ...(host.appId ? { appId: host.appId } : {}),
812
815
  };
813
816
  const http = this.o.http;
814
817
  const uploader = new TesterReportUploader({