@hyperframes/studio-server 0.8.79 → 0.8.81
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/{chunk-X3T65KC2.js → chunk-FTDTO3QP.js} +3 -3
- package/dist/{chunk-45POWYFS.js → chunk-G6IIFKXY.js} +7 -14
- package/dist/{chunk-45POWYFS.js.map → chunk-G6IIFKXY.js.map} +1 -1
- package/dist/{chunk-QYDRVMJ6.js → chunk-P5EJPIH3.js} +5 -3
- package/dist/chunk-P5EJPIH3.js.map +1 -0
- package/dist/{chunk-4MNTZVVZ.js → chunk-TJQ76IEA.js} +81 -11
- package/dist/chunk-TJQ76IEA.js.map +1 -0
- package/dist/helpers/mediaCodecMap.d.ts +7 -7
- package/dist/helpers/mediaCodecMap.js +1 -1
- package/dist/helpers/mediaProxyPreview.d.ts +1 -1
- package/dist/helpers/mediaProxyPreview.js +3 -3
- package/dist/helpers/proxyTranscoder.js +2 -2
- package/dist/helpers/sourceMutation.js +1 -1
- package/dist/index.d.ts +9 -3
- package/dist/index.js +522 -346
- package/dist/index.js.map +1 -1
- package/dist/{mediaProxyPreview-rAYw-Jeh.d.ts → mediaProxyPreview-BOp3Wa9v.d.ts} +5 -4
- package/package.json +4 -3
- package/dist/chunk-4MNTZVVZ.js.map +0 -1
- package/dist/chunk-QYDRVMJ6.js.map +0 -1
- /package/dist/{chunk-X3T65KC2.js.map → chunk-FTDTO3QP.js.map} +0 -0
|
@@ -98,14 +98,9 @@ type MediaProxyEligibility = {
|
|
|
98
98
|
};
|
|
99
99
|
/** Single policy gate shared by proactive scans and on-demand proxy routes. */
|
|
100
100
|
declare function decideMediaProxyEligibility(facts: AssetCodecFacts | null): MediaProxyEligibility;
|
|
101
|
-
/**
|
|
102
|
-
* Probe a single video asset. Best-effort: ffprobe missing, erroring, or
|
|
103
|
-
* finding no video stream resolves to `null` (asset omitted by the caller),
|
|
104
|
-
* never a throw. Async so a pool of probes runs concurrently (the default
|
|
105
|
-
* runner is `execFile`-based).
|
|
106
|
-
*/
|
|
107
|
-
declare function probeAssetCodec(filePath: string, runner?: FfprobeRunner): Promise<AssetCodecFacts | null>;
|
|
108
101
|
interface CachedAssetProbe {
|
|
102
|
+
/** The file a symlinked path pointed at, so retargeting the link is a miss. */
|
|
103
|
+
target: string;
|
|
109
104
|
mtimeMs: number;
|
|
110
105
|
size: number;
|
|
111
106
|
facts: AssetCodecFacts | null;
|
|
@@ -114,6 +109,11 @@ interface CachedAssetProbe {
|
|
|
114
109
|
* and reuse it across scans; a fresh instance defeats the caching benefit. */
|
|
115
110
|
type MediaCodecProbeCache = Map<string, CachedAssetProbe>;
|
|
116
111
|
declare function createMediaCodecProbeCache(): MediaCodecProbeCache;
|
|
112
|
+
/**
|
|
113
|
+
* Codec facts for one video, cached per path until its target, mtime or size changes; a hit skips
|
|
114
|
+
* `runner`. Never throws: no video stream or a failed probe gives `null`, and a failed probe is not cached.
|
|
115
|
+
*/
|
|
116
|
+
declare function probeAssetCodec(filePath: string, runner?: FfprobeRunner, cache?: MediaCodecProbeCache): Promise<AssetCodecFacts | null>;
|
|
117
117
|
/** Structurally compatible with `packages/lint/src/hevcPreviewLint.ts`'s
|
|
118
118
|
* (unexported) `HtmlSourceLike`. */
|
|
119
119
|
interface HtmlSourceLike {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { k as PreviewApiAdapter, a as PreviewDocumentStore, s as injectMediaCodecMap, t as injectMediaCodecMapIntoHtml, u as isAutoProxyEnabled, v as proxyEtagSalt, w as resolvePreviewMediaCodecProbeCache } from '../mediaProxyPreview-
|
|
1
|
+
export { k as PreviewApiAdapter, a as PreviewDocumentStore, s as injectMediaCodecMap, t as injectMediaCodecMapIntoHtml, u as isAutoProxyEnabled, v as proxyEtagSalt, w as resolvePreviewMediaCodecProbeCache } from '../mediaProxyPreview-BOp3Wa9v.js';
|
|
2
2
|
import './mediaCodecMap.js';
|
|
3
3
|
import '@hyperframes/core';
|
|
4
4
|
import '@hyperframes/parsers';
|
|
@@ -4,9 +4,9 @@ import {
|
|
|
4
4
|
isAutoProxyEnabled,
|
|
5
5
|
proxyEtagSalt,
|
|
6
6
|
resolvePreviewMediaCodecProbeCache
|
|
7
|
-
} from "../chunk-
|
|
8
|
-
import "../chunk-
|
|
9
|
-
import "../chunk-
|
|
7
|
+
} from "../chunk-FTDTO3QP.js";
|
|
8
|
+
import "../chunk-G6IIFKXY.js";
|
|
9
|
+
import "../chunk-TJQ76IEA.js";
|
|
10
10
|
export {
|
|
11
11
|
injectMediaCodecMap,
|
|
12
12
|
injectMediaCodecMapIntoHtml,
|
|
@@ -11,8 +11,8 @@ import {
|
|
|
11
11
|
getProxyCachePath,
|
|
12
12
|
resolveProxy,
|
|
13
13
|
waitForProxy
|
|
14
|
-
} from "../chunk-
|
|
15
|
-
import "../chunk-
|
|
14
|
+
} from "../chunk-G6IIFKXY.js";
|
|
15
|
+
import "../chunk-TJQ76IEA.js";
|
|
16
16
|
export {
|
|
17
17
|
DEFAULT_PROXY_WAIT_TIMEOUT_MS,
|
|
18
18
|
FfmpegMissingFilterError,
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Hono } from 'hono';
|
|
2
|
-
import { S as StudioApiAdapter, P as ProjectHistory, a as PreviewDocumentStore, M as MediaProcessingJobState } from './mediaProxyPreview-
|
|
3
|
-
export { C as ClosedWindow, D as DEFAULT_HISTORY_ROOT, b as HISTORY_START, H as HistoryClosedError, c as HistoryEntry, d as HistoryEntrySide, e as HistoryFileChange, f as HistoryListItem, g as HistoryResult, h as HistoryWho, i as HistoryWindow, L as LintResult, j as MAX_WINDOW_IDLE_MS, k as PreviewApiAdapter, l as ProjectHistoryOptions, R as RenderJobState, m as ResolvedProject, n as StudioSelectionResponse, o as StudioSelectionSnapshot, p as StudioSelectionTextField, U as UNDO_MODES, q as UndoMode, r as openProjectHistory } from './mediaProxyPreview-
|
|
2
|
+
import { S as StudioApiAdapter, P as ProjectHistory, a as PreviewDocumentStore, M as MediaProcessingJobState } from './mediaProxyPreview-BOp3Wa9v.js';
|
|
3
|
+
export { C as ClosedWindow, D as DEFAULT_HISTORY_ROOT, b as HISTORY_START, H as HistoryClosedError, c as HistoryEntry, d as HistoryEntrySide, e as HistoryFileChange, f as HistoryListItem, g as HistoryResult, h as HistoryWho, i as HistoryWindow, L as LintResult, j as MAX_WINDOW_IDLE_MS, k as PreviewApiAdapter, l as ProjectHistoryOptions, R as RenderJobState, m as ResolvedProject, n as StudioSelectionResponse, o as StudioSelectionSnapshot, p as StudioSelectionTextField, U as UNDO_MODES, q as UndoMode, r as openProjectHistory } from './mediaProxyPreview-BOp3Wa9v.js';
|
|
4
4
|
import { SourceMutationTarget } from './helpers/sourceMutation.js';
|
|
5
5
|
export { PatchOperation, dedupeClonedCompositionId, findTargetElement, parseSourceDocument, patchElementInHtml, removeElementFromHtml, splitElementInHtml } from './helpers/sourceMutation.js';
|
|
6
6
|
export { ScreenshotClip, getElementScreenshotClip } from './helpers/screenshotClip.js';
|
|
@@ -52,11 +52,17 @@ declare function createProjectSignature(projectDir: string, excluding?: Readonly
|
|
|
52
52
|
*/
|
|
53
53
|
declare function compositionsAffectedBy(projectDir: string, changedPath: string): string[] | null;
|
|
54
54
|
|
|
55
|
+
declare function affectsPreview(projectDir: string, changedPath: string): boolean;
|
|
56
|
+
|
|
55
57
|
declare class HistoryBusyError extends Error {
|
|
56
58
|
readonly pid: number;
|
|
57
59
|
constructor(pid: number);
|
|
58
60
|
}
|
|
59
61
|
|
|
62
|
+
declare class HistoryIdError extends Error {
|
|
63
|
+
constructor(message: string);
|
|
64
|
+
}
|
|
65
|
+
|
|
60
66
|
type Opened = Promise<ProjectHistory | null>;
|
|
61
67
|
/** A host's histories, one per project folder, opened on first use; a new project at the path gets its own. */
|
|
62
68
|
declare function historyCache(open: (projectDir: string) => Opened): {
|
|
@@ -216,4 +222,4 @@ type BackgroundRemovalRender = (options: {
|
|
|
216
222
|
}>;
|
|
217
223
|
declare function createBackgroundRemovalJob(opts: BackgroundRemovalJobOptions, render: BackgroundRemovalRender): MediaProcessingJobState;
|
|
218
224
|
|
|
219
|
-
export { type AppliedFileMutation, type BackgroundRemovalRender, DELETED_VERSION, type DuplicateElementResult, type FileMutationInput, type FileWriteReceipt, HistoryBusyError, MIME_TYPES, MediaProcessingJobState, PREVIEW_BUNDLE_OPTIONS, ProjectHistory, SourceMutationTarget, StudioApiAdapter, type ThumbnailOutputDimensions, affectsProjectSignature, applyFileMutations, buildSubCompositionHtml, compositionsAffectedBy, consumeFileWriteReceipt, createBackgroundRemovalJob, createPreviewDocumentStore, createProjectSignature, createStudioApi, duplicateElementInHtml, fileContentVersion, getMimeType, historyCache, identifyFileWrite, requestSubPath, settledFileTag, stampProjectHfIds, thumbnailDeviceScaleFactor, walkDir };
|
|
225
|
+
export { type AppliedFileMutation, type BackgroundRemovalRender, DELETED_VERSION, type DuplicateElementResult, type FileMutationInput, type FileWriteReceipt, HistoryBusyError, HistoryIdError, MIME_TYPES, MediaProcessingJobState, PREVIEW_BUNDLE_OPTIONS, ProjectHistory, SourceMutationTarget, StudioApiAdapter, type ThumbnailOutputDimensions, affectsPreview, affectsProjectSignature, applyFileMutations, buildSubCompositionHtml, compositionsAffectedBy, consumeFileWriteReceipt, createBackgroundRemovalJob, createPreviewDocumentStore, createProjectSignature, createStudioApi, duplicateElementInHtml, fileContentVersion, getMimeType, historyCache, identifyFileWrite, requestSubPath, settledFileTag, stampProjectHfIds, thumbnailDeviceScaleFactor, walkDir };
|