@trail-cli/sdk 0.1.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/dist/index.d.ts +31 -0
- package/dist/index.global.js +232 -0
- package/dist/index.global.js.map +1 -0
- package/dist/index.js +932 -0
- package/dist/index.js.map +1 -0
- package/package.json +38 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
export { Guide, GuideStep, Target } from '@trail-cli/guide-schema';
|
|
2
|
+
|
|
3
|
+
interface TrailHandle {
|
|
4
|
+
next: () => void;
|
|
5
|
+
back: () => void;
|
|
6
|
+
exit: () => void;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
interface TrailInitOptions {
|
|
10
|
+
/** Explicit URL to a guide document (JSON or YAML). Overrides URL-based auto-detection. */
|
|
11
|
+
guideUrl?: string;
|
|
12
|
+
/** Base path used to resolve `?trail=&release=` query params. Defaults to "/guides". */
|
|
13
|
+
guideBaseUrl?: string;
|
|
14
|
+
}
|
|
15
|
+
interface ResolvedGuideRequest {
|
|
16
|
+
url: string;
|
|
17
|
+
guideId: string;
|
|
18
|
+
release: string;
|
|
19
|
+
}
|
|
20
|
+
declare function resolveGuideRequest(options: TrailInitOptions): ResolvedGuideRequest | null;
|
|
21
|
+
/**
|
|
22
|
+
* Entry point installed inside the application under test. No-ops (negligible
|
|
23
|
+
* overhead, per spec #34) unless a guide has actually been requested via
|
|
24
|
+
* `options.guideUrl` or the `?trail=&release=` query params.
|
|
25
|
+
*/
|
|
26
|
+
declare function init(options?: TrailInitOptions): Promise<TrailHandle | null>;
|
|
27
|
+
declare const Trail: {
|
|
28
|
+
init: typeof init;
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
export { Trail, type TrailHandle, type TrailInitOptions, resolveGuideRequest };
|