@bendyline/squisq-video-react 2.4.23 → 2.4.25
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/NOTICE.md +9 -9
- package/README.md +1 -1
- package/THIRD_PARTY_LICENSES.txt +2 -2
- package/dist/{chunk-OLFWEKY5.js → chunk-7RONIAPM.js} +1 -1
- package/dist/{chunk-A52VG7RA.js → chunk-CWLDLWSE.js} +1 -1
- package/dist/{chunk-47ODXCBA.js → chunk-IOLZNTKA.js} +2 -2
- package/dist/{chunk-JDIMPME5.js → chunk-JVGUGMEZ.js} +1 -1
- package/dist/{chunk-TUZLVOSP.js → chunk-NTLNXUMA.js} +1 -1
- package/dist/{chunk-C7NEHV5X.js → chunk-R4P6O5U6.js} +240 -93
- package/dist/{chunk-ISYJJJXN.js → chunk-RIXBIX3H.js} +18 -3
- package/dist/{chunk-FMQI6WK2.js → chunk-UVDJINCK.js} +1 -1
- package/dist/{chunk-BNNLPKT2.js → chunk-Y5ZQ6M43.js} +1 -1
- package/dist/components/index.d.ts +3 -3
- package/dist/components/index.js +6 -6
- package/dist/cover-image/index.d.ts +2 -2
- package/dist/cover-image/index.js +3 -3
- package/dist/dashboard-image/index.d.ts +2 -2
- package/dist/dashboard-image/index.js +2 -2
- package/dist/encoder/index.js +2 -2
- package/dist/hooks/index.js +4 -4
- package/dist/index.d.ts +1 -1
- package/dist/index.js +8 -8
- package/dist/{lossyEncoder-EIXBAOLG.js → lossyEncoder-55PXLHLE.js} +1 -1
- package/dist/media-edit/index.js +1 -1
- package/dist/{mediaEditEngine-JLZ4Z5BB.js → mediaEditEngine-OBNK6I2B.js} +2 -2
- package/dist/workers/mediaEdit.worker.js +2 -2
- package/package.json +7 -7
|
@@ -333,10 +333,21 @@ async function encodeAacTrack(audioBuffer, sink, bitrate) {
|
|
|
333
333
|
const sampleRate = audioBuffer.sampleRate;
|
|
334
334
|
const channels = audioBuffer.numberOfChannels;
|
|
335
335
|
let encodeError = null;
|
|
336
|
+
let inFlight = 0;
|
|
337
|
+
let wake;
|
|
336
338
|
const encoder = new AudioEncoder({
|
|
337
|
-
output: (chunk, meta) =>
|
|
339
|
+
output: (chunk, meta) => {
|
|
340
|
+
inFlight = Math.max(0, inFlight - 1);
|
|
341
|
+
try {
|
|
342
|
+
sink.addAudioChunk(chunk, meta ?? void 0);
|
|
343
|
+
} catch (error) {
|
|
344
|
+
encodeError = error instanceof Error ? error : new Error(String(error));
|
|
345
|
+
}
|
|
346
|
+
wake?.();
|
|
347
|
+
},
|
|
338
348
|
error: (err) => {
|
|
339
349
|
encodeError = err instanceof Error ? err : new Error(String(err));
|
|
350
|
+
wake?.();
|
|
340
351
|
}
|
|
341
352
|
});
|
|
342
353
|
encoder.configure({ codec: "mp4a.40.2", sampleRate, numberOfChannels: channels, bitrate });
|
|
@@ -352,8 +363,11 @@ async function encodeAacTrack(audioBuffer, sink, bitrate) {
|
|
|
352
363
|
try {
|
|
353
364
|
for (let offset = 0; offset < total; offset += AAC_FRAME_SAMPLES) {
|
|
354
365
|
if (encodeError) throw encodeError;
|
|
355
|
-
|
|
356
|
-
await
|
|
366
|
+
while (inFlight >= queueLimit) {
|
|
367
|
+
await new Promise((resolve) => {
|
|
368
|
+
wake = resolve;
|
|
369
|
+
});
|
|
370
|
+
wake = void 0;
|
|
357
371
|
if (encodeError) throw encodeError;
|
|
358
372
|
}
|
|
359
373
|
const count = Math.min(AAC_FRAME_SAMPLES, total - offset);
|
|
@@ -371,6 +385,7 @@ async function encodeAacTrack(audioBuffer, sink, bitrate) {
|
|
|
371
385
|
data: planar
|
|
372
386
|
});
|
|
373
387
|
try {
|
|
388
|
+
inFlight++;
|
|
374
389
|
encoder.encode(audioData);
|
|
375
390
|
} finally {
|
|
376
391
|
audioData.close();
|
|
@@ -92,7 +92,7 @@ function createWavStreamWriter(sampleRate, channels, options = {}) {
|
|
|
92
92
|
// src/audioFile/audioFileEncoder.ts
|
|
93
93
|
var lossyModule = null;
|
|
94
94
|
function loadLossyModule() {
|
|
95
|
-
lossyModule ?? (lossyModule = import("./lossyEncoder-
|
|
95
|
+
lossyModule ?? (lossyModule = import("./lossyEncoder-55PXLHLE.js"));
|
|
96
96
|
return lossyModule;
|
|
97
97
|
}
|
|
98
98
|
function validateOptions(options) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { Doc, MediaProvider } from '@bendyline/squisq/schemas';
|
|
3
3
|
import { e as MediaEditRenderManager } from '../mediaEditRenderManager-W_o6RRhT.js';
|
|
4
4
|
import { b as VideoExportConfig, f as VideoOutputFormat } from '../useVideoExport-DsNDpjmO.js';
|
|
@@ -66,7 +66,7 @@ interface VideoExportPalette {
|
|
|
66
66
|
success: string;
|
|
67
67
|
danger: string;
|
|
68
68
|
}
|
|
69
|
-
declare function VideoExportModal({ doc, playerScript, mediaProvider, images, audio, mediaEditRenders, defaultConfig, colorScheme, uiPalette, saveOutput, saveActionLabel, onClose, }: VideoExportModalProps):
|
|
69
|
+
declare function VideoExportModal({ doc, playerScript, mediaProvider, images, audio, mediaEditRenders, defaultConfig, colorScheme, uiPalette, saveOutput, saveActionLabel, onClose, }: VideoExportModalProps): react.JSX.Element;
|
|
70
70
|
|
|
71
71
|
interface VideoExportButtonProps {
|
|
72
72
|
/** The document to export */
|
|
@@ -104,6 +104,6 @@ interface VideoExportButtonProps {
|
|
|
104
104
|
/** Whether the button is disabled */
|
|
105
105
|
disabled?: boolean;
|
|
106
106
|
}
|
|
107
|
-
declare function VideoExportButton({ doc, playerScript, mediaProvider, images, audio, defaultConfig, colorScheme, uiPalette, saveOutput, saveActionLabel, label, style, disabled, }: VideoExportButtonProps):
|
|
107
|
+
declare function VideoExportButton({ doc, playerScript, mediaProvider, images, audio, defaultConfig, colorScheme, uiPalette, saveOutput, saveActionLabel, label, style, disabled, }: VideoExportButtonProps): react.JSX.Element;
|
|
108
108
|
|
|
109
109
|
export { VideoExportButton, type VideoExportButtonProps, VideoExportModal, type VideoExportModalProps, type VideoExportPalette };
|
package/dist/components/index.js
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import {
|
|
2
2
|
VideoExportButton,
|
|
3
3
|
VideoExportModal
|
|
4
|
-
} from "../chunk-
|
|
4
|
+
} from "../chunk-NTLNXUMA.js";
|
|
5
5
|
import {
|
|
6
6
|
CoverImageExportModal,
|
|
7
7
|
coverImageFilename,
|
|
8
8
|
validateCoverImageDimensions
|
|
9
|
-
} from "../chunk-
|
|
9
|
+
} from "../chunk-JVGUGMEZ.js";
|
|
10
10
|
import "../chunk-3NJDHK62.js";
|
|
11
|
-
import "../chunk-
|
|
12
|
-
import "../chunk-
|
|
13
|
-
import "../chunk-
|
|
14
|
-
import "../chunk-
|
|
11
|
+
import "../chunk-IOLZNTKA.js";
|
|
12
|
+
import "../chunk-CWLDLWSE.js";
|
|
13
|
+
import "../chunk-R4P6O5U6.js";
|
|
14
|
+
import "../chunk-RIXBIX3H.js";
|
|
15
15
|
import "../chunk-5MFQMJ5Z.js";
|
|
16
16
|
export {
|
|
17
17
|
CoverImageExportModal,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { Doc, MediaProvider, Theme } from '@bendyline/squisq/schemas';
|
|
3
3
|
import { CoverSlideTemplate } from '@bendyline/squisq/doc';
|
|
4
4
|
import { I as ImageExportFormat } from '../imageExportShared-B6nqWtE-.js';
|
|
@@ -19,6 +19,6 @@ interface CoverImageExportModalProps {
|
|
|
19
19
|
}
|
|
20
20
|
declare function validateCoverImageDimensions(width: number, height: number): string | null;
|
|
21
21
|
declare function coverImageFilename(requestedName: string | undefined, format: CoverImageExportFormat): string;
|
|
22
|
-
declare function CoverImageExportModal({ doc, mediaProvider, theme, coverSlideTemplate, defaultWidth, defaultHeight, defaultFileName, colorScheme, saveOutput, onClose, }: CoverImageExportModalProps):
|
|
22
|
+
declare function CoverImageExportModal({ doc, mediaProvider, theme, coverSlideTemplate, defaultWidth, defaultHeight, defaultFileName, colorScheme, saveOutput, onClose, }: CoverImageExportModalProps): react.JSX.Element;
|
|
23
23
|
|
|
24
24
|
export { type CoverImageExportFormat, CoverImageExportModal, type CoverImageExportModalProps, coverImageFilename, validateCoverImageDimensions };
|
|
@@ -2,10 +2,10 @@ import {
|
|
|
2
2
|
CoverImageExportModal,
|
|
3
3
|
coverImageFilename,
|
|
4
4
|
validateCoverImageDimensions
|
|
5
|
-
} from "../chunk-
|
|
5
|
+
} from "../chunk-JVGUGMEZ.js";
|
|
6
6
|
import "../chunk-3NJDHK62.js";
|
|
7
|
-
import "../chunk-
|
|
8
|
-
import "../chunk-
|
|
7
|
+
import "../chunk-CWLDLWSE.js";
|
|
8
|
+
import "../chunk-R4P6O5U6.js";
|
|
9
9
|
export {
|
|
10
10
|
CoverImageExportModal,
|
|
11
11
|
coverImageFilename,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { Doc, MediaProvider, Theme } from '@bendyline/squisq/schemas';
|
|
3
3
|
import { DashboardStyleId } from '@bendyline/squisq/doc';
|
|
4
4
|
import { DashboardResolutionId } from '@bendyline/squisq-video';
|
|
@@ -24,6 +24,6 @@ interface DashboardImageExportModalProps {
|
|
|
24
24
|
saveOutput?: (blob: Blob, filename: string) => boolean | void | Promise<boolean | void>;
|
|
25
25
|
onClose: () => void;
|
|
26
26
|
}
|
|
27
|
-
declare function DashboardImageExportModal({ doc, mediaProvider, theme, defaultResolution, defaultLayout, defaultShowTitle, defaultStyle, defaultFileName, colorScheme, saveOutput, onClose, }: DashboardImageExportModalProps):
|
|
27
|
+
declare function DashboardImageExportModal({ doc, mediaProvider, theme, defaultResolution, defaultLayout, defaultShowTitle, defaultStyle, defaultFileName, colorScheme, saveOutput, onClose, }: DashboardImageExportModalProps): react.JSX.Element;
|
|
28
28
|
|
|
29
29
|
export { type DashboardImageExportFormat, DashboardImageExportModal, type DashboardImageExportModalProps };
|
|
@@ -7,8 +7,8 @@ import {
|
|
|
7
7
|
} from "../chunk-3NJDHK62.js";
|
|
8
8
|
import {
|
|
9
9
|
useFrameCapture
|
|
10
|
-
} from "../chunk-
|
|
11
|
-
import "../chunk-
|
|
10
|
+
} from "../chunk-CWLDLWSE.js";
|
|
11
|
+
import "../chunk-R4P6O5U6.js";
|
|
12
12
|
|
|
13
13
|
// src/DashboardImageExportModal.tsx
|
|
14
14
|
import { useCallback, useId, useMemo, useRef, useState } from "react";
|
package/dist/encoder/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createAudioFileEncoder,
|
|
3
3
|
supportedAudioFileFormats
|
|
4
|
-
} from "../chunk-
|
|
4
|
+
} from "../chunk-UVDJINCK.js";
|
|
5
5
|
import "../chunk-2W6JQSIY.js";
|
|
6
6
|
import {
|
|
7
7
|
createEncoder,
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
supportsWebCodecs,
|
|
11
11
|
supportsWebCodecsAac,
|
|
12
12
|
supportsWebCodecsH264
|
|
13
|
-
} from "../chunk-
|
|
13
|
+
} from "../chunk-RIXBIX3H.js";
|
|
14
14
|
import "../chunk-5MFQMJ5Z.js";
|
|
15
15
|
export {
|
|
16
16
|
createAudioFileEncoder,
|
package/dist/hooks/index.js
CHANGED
|
@@ -3,12 +3,12 @@ import {
|
|
|
3
3
|
resolveVideoCoverFramePlan,
|
|
4
4
|
resolveVideoExportCover,
|
|
5
5
|
useVideoExport
|
|
6
|
-
} from "../chunk-
|
|
6
|
+
} from "../chunk-IOLZNTKA.js";
|
|
7
7
|
import {
|
|
8
8
|
useFrameCapture
|
|
9
|
-
} from "../chunk-
|
|
10
|
-
import "../chunk-
|
|
11
|
-
import "../chunk-
|
|
9
|
+
} from "../chunk-CWLDLWSE.js";
|
|
10
|
+
import "../chunk-R4P6O5U6.js";
|
|
11
|
+
import "../chunk-RIXBIX3H.js";
|
|
12
12
|
import "../chunk-5MFQMJ5Z.js";
|
|
13
13
|
export {
|
|
14
14
|
DEFAULT_VIDEO_COVER_PRE_ROLL_SECONDS,
|
package/dist/index.d.ts
CHANGED
|
@@ -7,7 +7,7 @@ export { AudioTimelineClip, FfmpegWasmLoadConfig } from '@bendyline/squisq-video
|
|
|
7
7
|
export { AudioFileEncoder, AudioFileEncoderOptions, AudioFileFormat, RenderDocumentAudioOptions, createAudioFileEncoder, renderAudioTimeline, renderDocumentAudio, supportedAudioFileFormats, supportsWebCodecsAac } from './encoder/index.js';
|
|
8
8
|
export { M as MediaEditJobOptions, a as MediaEditPausesRequest, b as MediaEditPausesResult, c as MediaEditPreviewRequest, d as MediaEditPreviewResult, e as MediaEditRenderManager, f as MediaEditRenderManagerOptions, g as MediaEditRenderRequest, h as MediaEditRenderResult, i as MediaEditRenderState, j as MediaEditRenderStatus, k as MediaEditRenderer, l as MediaEditRendererOptions, m as createMediaEditRenderManager, n as createMediaEditRenderer } from './mediaEditRenderManager-W_o6RRhT.js';
|
|
9
9
|
export { MediaEditRendersView, useMediaEditRenders, useMediaEditStatus, useProcessedAudio } from './media-edit/index.js';
|
|
10
|
-
import 'react
|
|
10
|
+
import 'react';
|
|
11
11
|
import '@bendyline/squisq/schemas';
|
|
12
12
|
import '@bendyline/squisq/doc';
|
|
13
13
|
import './imageExportShared-B6nqWtE-.js';
|
package/dist/index.js
CHANGED
|
@@ -1,27 +1,27 @@
|
|
|
1
1
|
import {
|
|
2
2
|
VideoExportButton,
|
|
3
3
|
VideoExportModal
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-NTLNXUMA.js";
|
|
5
5
|
import {
|
|
6
6
|
CoverImageExportModal,
|
|
7
7
|
coverImageFilename,
|
|
8
8
|
validateCoverImageDimensions
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-JVGUGMEZ.js";
|
|
10
10
|
import "./chunk-3NJDHK62.js";
|
|
11
11
|
import {
|
|
12
12
|
DEFAULT_VIDEO_COVER_PRE_ROLL_SECONDS,
|
|
13
13
|
resolveVideoCoverFramePlan,
|
|
14
14
|
resolveVideoExportCover,
|
|
15
15
|
useVideoExport
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-IOLZNTKA.js";
|
|
17
17
|
import {
|
|
18
18
|
useFrameCapture
|
|
19
|
-
} from "./chunk-
|
|
20
|
-
import "./chunk-
|
|
19
|
+
} from "./chunk-CWLDLWSE.js";
|
|
20
|
+
import "./chunk-R4P6O5U6.js";
|
|
21
21
|
import {
|
|
22
22
|
createAudioFileEncoder,
|
|
23
23
|
supportedAudioFileFormats
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-UVDJINCK.js";
|
|
25
25
|
import "./chunk-2W6JQSIY.js";
|
|
26
26
|
import {
|
|
27
27
|
createEncoder,
|
|
@@ -30,14 +30,14 @@ import {
|
|
|
30
30
|
supportsWebCodecs,
|
|
31
31
|
supportsWebCodecsAac,
|
|
32
32
|
supportsWebCodecsH264
|
|
33
|
-
} from "./chunk-
|
|
33
|
+
} from "./chunk-RIXBIX3H.js";
|
|
34
34
|
import {
|
|
35
35
|
createMediaEditRenderManager,
|
|
36
36
|
createMediaEditRenderer,
|
|
37
37
|
useMediaEditRenders,
|
|
38
38
|
useMediaEditStatus,
|
|
39
39
|
useProcessedAudio
|
|
40
|
-
} from "./chunk-
|
|
40
|
+
} from "./chunk-7RONIAPM.js";
|
|
41
41
|
import "./chunk-TL2IMDIZ.js";
|
|
42
42
|
import "./chunk-5MFQMJ5Z.js";
|
|
43
43
|
export {
|
package/dist/media-edit/index.js
CHANGED
|
@@ -3,8 +3,8 @@ import {
|
|
|
3
3
|
analyzeMediaEditPauses,
|
|
4
4
|
previewMediaEditAudio,
|
|
5
5
|
renderMediaEditAudio
|
|
6
|
-
} from "./chunk-
|
|
7
|
-
import "./chunk-
|
|
6
|
+
} from "./chunk-Y5ZQ6M43.js";
|
|
7
|
+
import "./chunk-R4P6O5U6.js";
|
|
8
8
|
export {
|
|
9
9
|
analyzeMediaEditAudio,
|
|
10
10
|
analyzeMediaEditPauses,
|
|
@@ -3,8 +3,8 @@ import {
|
|
|
3
3
|
analyzeMediaEditPauses,
|
|
4
4
|
previewMediaEditAudio,
|
|
5
5
|
renderMediaEditAudio
|
|
6
|
-
} from "../chunk-
|
|
7
|
-
import "../chunk-
|
|
6
|
+
} from "../chunk-Y5ZQ6M43.js";
|
|
7
|
+
import "../chunk-R4P6O5U6.js";
|
|
8
8
|
import {
|
|
9
9
|
createRnnoiseDenoiserFactory
|
|
10
10
|
} from "../chunk-TL2IMDIZ.js";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bendyline/squisq-video-react",
|
|
3
|
-
"version": "2.4.
|
|
3
|
+
"version": "2.4.25",
|
|
4
4
|
"description": "React components for browser-based MP4 and animated-GIF export of Squisq documents",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Bendyline",
|
|
@@ -77,19 +77,19 @@
|
|
|
77
77
|
"react-dom": "^18.0.0 || ^19.0.0"
|
|
78
78
|
},
|
|
79
79
|
"dependencies": {
|
|
80
|
-
"@bendyline/squisq": "2.11.
|
|
81
|
-
"@bendyline/squisq-video": "2.3.
|
|
82
|
-
"@bendyline/squisq-react": "2.11.
|
|
83
|
-
"@ffmpeg/core": "0.12.
|
|
80
|
+
"@bendyline/squisq": "2.11.19",
|
|
81
|
+
"@bendyline/squisq-video": "2.3.23",
|
|
82
|
+
"@bendyline/squisq-react": "2.11.21",
|
|
83
|
+
"@ffmpeg/core": "0.12.10",
|
|
84
84
|
"@ffmpeg/ffmpeg": "0.12.15",
|
|
85
85
|
"@ffmpeg/util": "0.12.2",
|
|
86
86
|
"@shiguredo/rnnoise-wasm": "2025.1.5",
|
|
87
87
|
"html2canvas": "1.4.1"
|
|
88
88
|
},
|
|
89
89
|
"devDependencies": {
|
|
90
|
-
"@types/react": "18.3.
|
|
90
|
+
"@types/react": "18.3.31",
|
|
91
91
|
"@types/react-dom": "18.3.7",
|
|
92
|
-
"mediabunny": "1.
|
|
92
|
+
"mediabunny": "1.61.0",
|
|
93
93
|
"mp4-muxer": "5.2.2",
|
|
94
94
|
"react": "18.3.1",
|
|
95
95
|
"react-dom": "18.3.1",
|