ugcinc-render 1.8.2 → 1.8.3
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.js +6 -8
- package/dist/index.mjs +12 -14
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -2185,19 +2185,17 @@ function CaptionOverlay({ captions, style, previewTimeMs }) {
|
|
|
2185
2185
|
);
|
|
2186
2186
|
}
|
|
2187
2187
|
}
|
|
2188
|
-
return /* @__PURE__ */ (0, import_jsx_runtime6.
|
|
2188
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
|
|
2189
2189
|
"span",
|
|
2190
2190
|
{
|
|
2191
2191
|
style: {
|
|
2192
2192
|
color,
|
|
2193
2193
|
display: "inline-block",
|
|
2194
2194
|
transform: `scale(${scale})`,
|
|
2195
|
-
transformOrigin: "center center"
|
|
2195
|
+
transformOrigin: "center center",
|
|
2196
|
+
marginRight: index < currentPage.words.length - 1 ? "0.25em" : 0
|
|
2196
2197
|
},
|
|
2197
|
-
children:
|
|
2198
|
-
word.word,
|
|
2199
|
-
index < currentPage.words.length - 1 ? " " : ""
|
|
2200
|
-
]
|
|
2198
|
+
children: word.word
|
|
2201
2199
|
},
|
|
2202
2200
|
`${word.word}-${word.startMs}-${index}`
|
|
2203
2201
|
);
|
|
@@ -2219,7 +2217,7 @@ function AutoCaptionComposition({
|
|
|
2219
2217
|
style: {
|
|
2220
2218
|
width: "100%",
|
|
2221
2219
|
height: "100%",
|
|
2222
|
-
objectFit: "
|
|
2220
|
+
objectFit: "cover"
|
|
2223
2221
|
}
|
|
2224
2222
|
}
|
|
2225
2223
|
),
|
|
@@ -2239,7 +2237,7 @@ function AutoCaptionCompositionWithVideo({
|
|
|
2239
2237
|
style: {
|
|
2240
2238
|
width: "100%",
|
|
2241
2239
|
height: "100%",
|
|
2242
|
-
objectFit: "
|
|
2240
|
+
objectFit: "cover"
|
|
2243
2241
|
}
|
|
2244
2242
|
}
|
|
2245
2243
|
),
|
package/dist/index.mjs
CHANGED
|
@@ -1203,7 +1203,7 @@ import { AbsoluteFill as AbsoluteFill3, Video, OffthreadVideo as OffthreadVideo2
|
|
|
1203
1203
|
// src/components/CaptionOverlay.tsx
|
|
1204
1204
|
import { useMemo as useMemo6 } from "react";
|
|
1205
1205
|
import { useCurrentFrame as useCurrentFrame4, useVideoConfig as useVideoConfig4, interpolate } from "remotion";
|
|
1206
|
-
import { jsx as jsx6
|
|
1206
|
+
import { jsx as jsx6 } from "react/jsx-runtime";
|
|
1207
1207
|
function createPages(words, wordsPerPage) {
|
|
1208
1208
|
const pages = [];
|
|
1209
1209
|
for (let i = 0; i < words.length; i += wordsPerPage) {
|
|
@@ -1323,19 +1323,17 @@ function CaptionOverlay({ captions, style, previewTimeMs }) {
|
|
|
1323
1323
|
);
|
|
1324
1324
|
}
|
|
1325
1325
|
}
|
|
1326
|
-
return /* @__PURE__ */
|
|
1326
|
+
return /* @__PURE__ */ jsx6(
|
|
1327
1327
|
"span",
|
|
1328
1328
|
{
|
|
1329
1329
|
style: {
|
|
1330
1330
|
color,
|
|
1331
1331
|
display: "inline-block",
|
|
1332
1332
|
transform: `scale(${scale})`,
|
|
1333
|
-
transformOrigin: "center center"
|
|
1333
|
+
transformOrigin: "center center",
|
|
1334
|
+
marginRight: index < currentPage.words.length - 1 ? "0.25em" : 0
|
|
1334
1335
|
},
|
|
1335
|
-
children:
|
|
1336
|
-
word.word,
|
|
1337
|
-
index < currentPage.words.length - 1 ? " " : ""
|
|
1338
|
-
]
|
|
1336
|
+
children: word.word
|
|
1339
1337
|
},
|
|
1340
1338
|
`${word.word}-${word.startMs}-${index}`
|
|
1341
1339
|
);
|
|
@@ -1343,13 +1341,13 @@ function CaptionOverlay({ captions, style, previewTimeMs }) {
|
|
|
1343
1341
|
}
|
|
1344
1342
|
|
|
1345
1343
|
// src/compositions/AutoCaptionComposition.tsx
|
|
1346
|
-
import { jsx as jsx7, jsxs as
|
|
1344
|
+
import { jsx as jsx7, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
1347
1345
|
function AutoCaptionComposition({
|
|
1348
1346
|
videoUrl,
|
|
1349
1347
|
captions,
|
|
1350
1348
|
style
|
|
1351
1349
|
}) {
|
|
1352
|
-
return /* @__PURE__ */
|
|
1350
|
+
return /* @__PURE__ */ jsxs4(AbsoluteFill3, { style: { backgroundColor: "#000000" }, children: [
|
|
1353
1351
|
/* @__PURE__ */ jsx7(
|
|
1354
1352
|
OffthreadVideo2,
|
|
1355
1353
|
{
|
|
@@ -1357,7 +1355,7 @@ function AutoCaptionComposition({
|
|
|
1357
1355
|
style: {
|
|
1358
1356
|
width: "100%",
|
|
1359
1357
|
height: "100%",
|
|
1360
|
-
objectFit: "
|
|
1358
|
+
objectFit: "cover"
|
|
1361
1359
|
}
|
|
1362
1360
|
}
|
|
1363
1361
|
),
|
|
@@ -1369,7 +1367,7 @@ function AutoCaptionCompositionWithVideo({
|
|
|
1369
1367
|
captions,
|
|
1370
1368
|
style
|
|
1371
1369
|
}) {
|
|
1372
|
-
return /* @__PURE__ */
|
|
1370
|
+
return /* @__PURE__ */ jsxs4(AbsoluteFill3, { style: { backgroundColor: "#000000" }, children: [
|
|
1373
1371
|
/* @__PURE__ */ jsx7(
|
|
1374
1372
|
Video,
|
|
1375
1373
|
{
|
|
@@ -1377,7 +1375,7 @@ function AutoCaptionCompositionWithVideo({
|
|
|
1377
1375
|
style: {
|
|
1378
1376
|
width: "100%",
|
|
1379
1377
|
height: "100%",
|
|
1380
|
-
objectFit: "
|
|
1378
|
+
objectFit: "cover"
|
|
1381
1379
|
}
|
|
1382
1380
|
}
|
|
1383
1381
|
),
|
|
@@ -1468,7 +1466,7 @@ function useResolvedPositions(elements, textValues) {
|
|
|
1468
1466
|
|
|
1469
1467
|
// src/Root.tsx
|
|
1470
1468
|
import { Composition } from "remotion";
|
|
1471
|
-
import { Fragment, jsx as jsx8, jsxs as
|
|
1469
|
+
import { Fragment, jsx as jsx8, jsxs as jsxs5 } from "react/jsx-runtime";
|
|
1472
1470
|
var defaultImageProps = {
|
|
1473
1471
|
config: {
|
|
1474
1472
|
width: 1080,
|
|
@@ -1563,7 +1561,7 @@ var calculateImageMetadata = async ({ props }) => {
|
|
|
1563
1561
|
};
|
|
1564
1562
|
};
|
|
1565
1563
|
var RenderRoot = () => {
|
|
1566
|
-
return /* @__PURE__ */
|
|
1564
|
+
return /* @__PURE__ */ jsxs5(Fragment, { children: [
|
|
1567
1565
|
/* @__PURE__ */ jsx8(
|
|
1568
1566
|
Composition,
|
|
1569
1567
|
{
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ugcinc-render",
|
|
3
|
-
"version": "1.8.
|
|
3
|
+
"version": "1.8.3",
|
|
4
4
|
"description": "Unified rendering package for UGC Inc - shared types, components, and compositions for pixel-perfect client/server rendering",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|