@hyperframes/inspector 0.9.72 → 0.9.74

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.
@@ -202,7 +202,7 @@ export declare function sampleAutomationLane(lane: HfAutomationLane, t: number,
202
202
  export declare function isConstantLane(lane: HfAutomationLane): boolean;
203
203
  /**
204
204
  * Sample a lane onto evenly spaced times, for consumers that want a plain
205
- * curve rather than a breakpoint list: `setValueCurveAtTime`, the render-side
205
+ * curve rather than a breakpoint list: the AudioParam scheduler, the render-side
206
206
  * volume envelope, and the lane's own drawing code.
207
207
  */
208
208
  export declare function sampleAutomationCurve(lane: HfAutomationLane, from: number, to: number, count: number, scale?: "linear" | "log"): Float32Array;
@@ -0,0 +1,35 @@
1
+ /**
2
+ * The largest entry or sub-composition HTML file a render compiles. Compiling and probing a page
3
+ * runs on the render server's main thread, and their cost grows with the page's size, so one huge
4
+ * page would hold up every other render in the same process.
5
+ */
6
+ export declare const MAX_COMPOSITION_HTML_BYTES: number;
7
+ /**
8
+ * What one render may inline across every sub-composition mount. Each file is checked on its own
9
+ * above, but a few small files that mount each other many times assemble a page far larger.
10
+ */
11
+ export declare const MAX_EXPANDED_COMPOSITION_BYTES: number;
12
+ /** About 4x the largest composition in 7 days of production renders (24,800 elements). */
13
+ export declare const MAX_EXPANDED_ELEMENTS = 100000;
14
+ export declare function isCompositionTooLargeError(error: unknown): error is Error;
15
+ export declare const REMOTE_SCRIPTS = "remote scripts";
16
+ export declare const REMOTE_STYLESHEETS = "remote stylesheets";
17
+ export declare const ENTRY_PAGE = "the entry page";
18
+ /** Adds up every mount a render inlines, and what it generates for them, and throws past a limit. */
19
+ export declare class CompositionExpansionBudget {
20
+ private bytes;
21
+ private mounts;
22
+ private generated;
23
+ private elements;
24
+ chargeElements(file: string, count: number): void;
25
+ /** `bytes` may be negative when a reserved upper bound is settled to the real size. */
26
+ chargeGenerated(file: string, bytes: number): void;
27
+ get generatedRoom(): number;
28
+ chargeGeneratedIfItFits(bytes: number): boolean;
29
+ charge(file: string, bytes: number): void;
30
+ }
31
+ /**
32
+ * Throws {@link CompositionTooLargeError} when `path` is a file over the limit, before anything
33
+ * reads it. A missing path or a folder passes, so the caller's own read reports it as before.
34
+ */
35
+ export declare function assertCompositionFileSize(path: string, file: string): void;
@@ -107,6 +107,8 @@ export interface InlineSubCompositionsOptions {
107
107
  * built, and each scoped sheet rule by rule as `scopeCssToComposition` reports it. May throw.
108
108
  */
109
109
  chargeEmitted?: (srcPath: string, bytes: number) => void;
110
+ /** Told how many elements each mount copies, before it is copied. May throw. */
111
+ chargeElements?: (srcPath: string, count: number) => void;
110
112
  }
111
113
  export interface ExternalLink {
112
114
  href: string;
@@ -9,6 +9,8 @@ export declare function servedToAnotherSite(doc: Document): boolean;
9
9
  export declare function markedForStudio(doc: Document): boolean;
10
10
  export declare function getLogicalOpacity(el: Element, computed: CSSStyleDeclaration): string;
11
11
  export declare const PLAYER_FRAME_ATTR = "data-hf-player-frame";
12
+ export declare const PLAYER_FRAME_NAME = "hyperframes-player";
13
+ export declare function servedToStudio(doc: Document): boolean;
12
14
  export declare function inPlayerFrame(doc: Document): boolean;
13
15
  export declare function defersMediaIn(doc: Document): boolean;
14
16
  export declare function capturePageIn(doc: Document): boolean;
@@ -24,7 +26,8 @@ export declare const RUNTIME_STAMPED_ATTR = "data-hf-autostamped";
24
26
  export declare const CLIP_HIDDEN_ATTR = "data-hf-clip-hidden";
25
27
  export declare const STUDIO_PREVIEW_FAR_SCENE_ATTR = "data-hf-far-scene";
26
28
  export declare const STUDIO_PREVIEW_PARKED_SCENE_ATTR = "data-hf-parked-scene";
27
- export declare const PREVIEW_ONLY_ATTRS: readonly ["data-hf-preview-video-frame", "data-hf-preview-video-source", "data-hf-preview-video-canvas", "data-hf-upcoming", "data-hf-far-scene", "data-hf-parked-scene", "data-hf-preview-lazy", "data-hf-preview-raster", "data-hf-autostamped"];
29
+ export declare const PREVIEW_FILE_SIZE_ATTR = "data-hf-file-size";
30
+ export declare const PREVIEW_ONLY_ATTRS: readonly ["data-hf-preview-video-frame", "data-hf-preview-video-source", "data-hf-preview-video-canvas", "data-hf-upcoming", "data-hf-far-scene", "data-hf-parked-scene", "data-hf-preview-lazy", "data-hf-preview-raster", "data-hf-autostamped", "data-hf-file-size"];
28
31
  export declare const isClipHiddenByRuntime: (el: HTMLElement) => boolean;
29
32
  export declare function applyAuthoredTiming(el: Element, attrs: ReadonlyArray<readonly [name: string, value: string]>): void;
30
33
  export declare function dropServiceWorkers(): Promise<void>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hyperframes/inspector",
3
- "version": "0.9.72",
3
+ "version": "0.9.74",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/heygen-com/hyperframes",
@@ -43,8 +43,8 @@
43
43
  "htmlparser2": "^10.1.0",
44
44
  "postcss": "^8.5.8",
45
45
  "puppeteer-core": "^25.8.0",
46
- "@hyperframes/core": "0.9.72",
47
- "@hyperframes/parsers": "0.9.72"
46
+ "@hyperframes/parsers": "0.9.74",
47
+ "@hyperframes/core": "0.9.74"
48
48
  },
49
49
  "devDependencies": {
50
50
  "@types/node": "^25.0.10",