104 lines
3.1 KiB
JavaScript
104 lines
3.1 KiB
JavaScript
/*
|
|
* Extracted from browser-delivered Turbopack chunk: fd0220e4d10052af.701bdafa2d.js
|
|
* Module id: 905869
|
|
* For reading/searching only; this factory depends on the original Turbopack runtime.
|
|
*/
|
|
|
|
const moduleFactory = (e) => {
|
|
"use strict";
|
|
var t = e.i(182004),
|
|
n = e.i(497954),
|
|
i = e.i(959248),
|
|
r = e.i(934108),
|
|
a = e.i(713118);
|
|
function o(e) {
|
|
let t,
|
|
n,
|
|
i,
|
|
r,
|
|
o = (function (e) {
|
|
let t = e.measured;
|
|
if (!t?.width || !t?.height) return null;
|
|
let n = parseFloat(t.width),
|
|
i = parseFloat(t.height);
|
|
return Number.isFinite(n) && Number.isFinite(i)
|
|
? { width: n, height: i }
|
|
: null;
|
|
})(e);
|
|
if (o) return o;
|
|
let s = e.data,
|
|
c =
|
|
((t = s.contentWidth),
|
|
(n = s.contentHeight),
|
|
"number" == typeof t &&
|
|
Number.isFinite(t) &&
|
|
"number" == typeof n &&
|
|
Number.isFinite(n)
|
|
? { width: t, height: n }
|
|
: null);
|
|
if (c) return c;
|
|
let l =
|
|
((i = s.params),
|
|
(r = (0, a.extractRatioFromSettings)(i?.settings))
|
|
? (0, a.computeNodeDimensionsFromRatio)(r)
|
|
: null);
|
|
return l || { width: a.NODE_WIDTH, height: a.NODE_HEIGHT_EMPTY };
|
|
}
|
|
function s(e) {
|
|
if (e.measured) return e.measured;
|
|
let t = e.data,
|
|
n = t.nodeWidth,
|
|
i = t.nodeHeight;
|
|
return {
|
|
width: "number" == typeof n && Number.isFinite(n) ? n : 800,
|
|
height: "number" == typeof i && Number.isFinite(i) ? i : 400,
|
|
};
|
|
}
|
|
(0, n.registerCanvasNodeDefaultSize)(t.NodeType.AUDIO, function (e) {
|
|
let t, n, o;
|
|
return e.measured
|
|
? e.measured
|
|
: {
|
|
width: a.NODE_WIDTH,
|
|
height:
|
|
((t = e.data),
|
|
(n = (0, i.isTaskGenerating)(t?.taskInfo)),
|
|
(o = !!t?.url?.[0]),
|
|
n || o ? r.NODE_HEIGHT_AUDIO : a.NODE_HEIGHT_EMPTY),
|
|
};
|
|
}),
|
|
e.s([], 463478),
|
|
(0, n.registerCanvasNodeDefaultSize)(t.NodeType.GROUP, function (e) {
|
|
return e.measured ? e.measured : { width: 200, height: 120 };
|
|
}),
|
|
e.s([], 773614),
|
|
e.s(["mediaLikeDefaultSizeFromCanvasNode", () => o], 696302),
|
|
(0, n.registerCanvasNodeDefaultSize)(t.NodeType.IMAGE, function (e) {
|
|
return e.measured ? e.measured : o(e);
|
|
}),
|
|
e.s([], 458970),
|
|
(0, n.registerCanvasNodeDefaultSize)(t.NodeType.SCRIPT, s),
|
|
(0, n.registerCanvasNodeDefaultSize)("storyboard", s),
|
|
e.s([], 956949),
|
|
(0, n.registerCanvasNodeDefaultSize)(
|
|
t.NodeType.SPACE_SCENE_720,
|
|
function (e) {
|
|
if (e.measured) return e.measured;
|
|
let t = e.data;
|
|
return {
|
|
width:
|
|
"number" == typeof t?.contentWidth && t.contentWidth > 0
|
|
? t.contentWidth
|
|
: a.NODE_WIDTH,
|
|
height:
|
|
"number" == typeof t?.contentHeight && t.contentHeight > 0
|
|
? t.contentHeight
|
|
: 220,
|
|
};
|
|
},
|
|
),
|
|
e.s([], 905869);
|
|
};
|
|
|
|
export default moduleFactory;
|