Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93

Warning: Undefined array key "page_file_edit_line" in /home/sportsfever/public_html/filemanger/edit_text_line.php on line 32
/home/sportsfe.../httpdocs/clone/wp-conte.../plugins/embedpre.../assets/pdf/build
File: pdf.worker.js
return this[$content];
[45000] Fix | Delete
}
[45001] Fix | Delete
[$isDescendent](parent) {
[45002] Fix | Delete
return this[_parent] === parent || this[_parent][$isDescendent](parent);
[45003] Fix | Delete
}
[45004] Fix | Delete
}
[45005] Fix | Delete
class XmlObject extends XFAObject {
[45006] Fix | Delete
constructor(nsId, name, attributes = {}) {
[45007] Fix | Delete
super(nsId, name);
[45008] Fix | Delete
this[$content] = "";
[45009] Fix | Delete
this[_dataValue] = null;
[45010] Fix | Delete
if (name !== "#text") {
[45011] Fix | Delete
const map = new Map();
[45012] Fix | Delete
this[_attributes] = map;
[45013] Fix | Delete
for (const [attrName, value] of Object.entries(attributes)) {
[45014] Fix | Delete
map.set(attrName, new XFAAttribute(this, attrName, value));
[45015] Fix | Delete
}
[45016] Fix | Delete
if (attributes.hasOwnProperty($nsAttributes)) {
[45017] Fix | Delete
const dataNode = attributes[$nsAttributes].xfa.dataNode;
[45018] Fix | Delete
if (dataNode !== undefined) {
[45019] Fix | Delete
if (dataNode === "dataGroup") {
[45020] Fix | Delete
this[_dataValue] = false;
[45021] Fix | Delete
} else if (dataNode === "dataValue") {
[45022] Fix | Delete
this[_dataValue] = true;
[45023] Fix | Delete
}
[45024] Fix | Delete
}
[45025] Fix | Delete
}
[45026] Fix | Delete
}
[45027] Fix | Delete
this[$consumed] = false;
[45028] Fix | Delete
}
[45029] Fix | Delete
[$toString](buf) {
[45030] Fix | Delete
const tagName = this[$nodeName];
[45031] Fix | Delete
if (tagName === "#text") {
[45032] Fix | Delete
buf.push(encodeToXmlString(this[$content]));
[45033] Fix | Delete
return;
[45034] Fix | Delete
}
[45035] Fix | Delete
const utf8TagName = utf8StringToString(tagName);
[45036] Fix | Delete
const prefix = this[$namespaceId] === NS_DATASETS ? "xfa:" : "";
[45037] Fix | Delete
buf.push(`<${prefix}${utf8TagName}`);
[45038] Fix | Delete
for (const [name, value] of this[_attributes].entries()) {
[45039] Fix | Delete
const utf8Name = utf8StringToString(name);
[45040] Fix | Delete
buf.push(` ${utf8Name}="${encodeToXmlString(value[$content])}"`);
[45041] Fix | Delete
}
[45042] Fix | Delete
if (this[_dataValue] !== null) {
[45043] Fix | Delete
if (this[_dataValue]) {
[45044] Fix | Delete
buf.push(` xfa:dataNode="dataValue"`);
[45045] Fix | Delete
} else {
[45046] Fix | Delete
buf.push(` xfa:dataNode="dataGroup"`);
[45047] Fix | Delete
}
[45048] Fix | Delete
}
[45049] Fix | Delete
if (!this[$content] && this[_children].length === 0) {
[45050] Fix | Delete
buf.push("/>");
[45051] Fix | Delete
return;
[45052] Fix | Delete
}
[45053] Fix | Delete
buf.push(">");
[45054] Fix | Delete
if (this[$content]) {
[45055] Fix | Delete
if (typeof this[$content] === "string") {
[45056] Fix | Delete
buf.push(encodeToXmlString(this[$content]));
[45057] Fix | Delete
} else {
[45058] Fix | Delete
this[$content][$toString](buf);
[45059] Fix | Delete
}
[45060] Fix | Delete
} else {
[45061] Fix | Delete
for (const child of this[_children]) {
[45062] Fix | Delete
child[$toString](buf);
[45063] Fix | Delete
}
[45064] Fix | Delete
}
[45065] Fix | Delete
buf.push(`</${prefix}${utf8TagName}>`);
[45066] Fix | Delete
}
[45067] Fix | Delete
[$onChild](child) {
[45068] Fix | Delete
if (this[$content]) {
[45069] Fix | Delete
const node = new XmlObject(this[$namespaceId], "#text");
[45070] Fix | Delete
this[$appendChild](node);
[45071] Fix | Delete
node[$content] = this[$content];
[45072] Fix | Delete
this[$content] = "";
[45073] Fix | Delete
}
[45074] Fix | Delete
this[$appendChild](child);
[45075] Fix | Delete
return true;
[45076] Fix | Delete
}
[45077] Fix | Delete
[$onText](str) {
[45078] Fix | Delete
this[$content] += str;
[45079] Fix | Delete
}
[45080] Fix | Delete
[$finalize]() {
[45081] Fix | Delete
if (this[$content] && this[_children].length > 0) {
[45082] Fix | Delete
const node = new XmlObject(this[$namespaceId], "#text");
[45083] Fix | Delete
this[$appendChild](node);
[45084] Fix | Delete
node[$content] = this[$content];
[45085] Fix | Delete
delete this[$content];
[45086] Fix | Delete
}
[45087] Fix | Delete
}
[45088] Fix | Delete
[$toHTML]() {
[45089] Fix | Delete
if (this[$nodeName] === "#text") {
[45090] Fix | Delete
return HTMLResult.success({
[45091] Fix | Delete
name: "#text",
[45092] Fix | Delete
value: this[$content]
[45093] Fix | Delete
});
[45094] Fix | Delete
}
[45095] Fix | Delete
return HTMLResult.EMPTY;
[45096] Fix | Delete
}
[45097] Fix | Delete
[$getChildren](name = null) {
[45098] Fix | Delete
if (!name) {
[45099] Fix | Delete
return this[_children];
[45100] Fix | Delete
}
[45101] Fix | Delete
return this[_children].filter(c => c[$nodeName] === name);
[45102] Fix | Delete
}
[45103] Fix | Delete
[$getAttributes]() {
[45104] Fix | Delete
return this[_attributes];
[45105] Fix | Delete
}
[45106] Fix | Delete
[$getChildrenByClass](name) {
[45107] Fix | Delete
const value = this[_attributes].get(name);
[45108] Fix | Delete
if (value !== undefined) {
[45109] Fix | Delete
return value;
[45110] Fix | Delete
}
[45111] Fix | Delete
return this[$getChildren](name);
[45112] Fix | Delete
}
[45113] Fix | Delete
*[$getChildrenByNameIt](name, allTransparent) {
[45114] Fix | Delete
const value = this[_attributes].get(name);
[45115] Fix | Delete
if (value) {
[45116] Fix | Delete
yield value;
[45117] Fix | Delete
}
[45118] Fix | Delete
for (const child of this[_children]) {
[45119] Fix | Delete
if (child[$nodeName] === name) {
[45120] Fix | Delete
yield child;
[45121] Fix | Delete
}
[45122] Fix | Delete
if (allTransparent) {
[45123] Fix | Delete
yield* child[$getChildrenByNameIt](name, allTransparent);
[45124] Fix | Delete
}
[45125] Fix | Delete
}
[45126] Fix | Delete
}
[45127] Fix | Delete
*[$getAttributeIt](name, skipConsumed) {
[45128] Fix | Delete
const value = this[_attributes].get(name);
[45129] Fix | Delete
if (value && (!skipConsumed || !value[$consumed])) {
[45130] Fix | Delete
yield value;
[45131] Fix | Delete
}
[45132] Fix | Delete
for (const child of this[_children]) {
[45133] Fix | Delete
yield* child[$getAttributeIt](name, skipConsumed);
[45134] Fix | Delete
}
[45135] Fix | Delete
}
[45136] Fix | Delete
*[$getRealChildrenByNameIt](name, allTransparent, skipConsumed) {
[45137] Fix | Delete
for (const child of this[_children]) {
[45138] Fix | Delete
if (child[$nodeName] === name && (!skipConsumed || !child[$consumed])) {
[45139] Fix | Delete
yield child;
[45140] Fix | Delete
}
[45141] Fix | Delete
if (allTransparent) {
[45142] Fix | Delete
yield* child[$getRealChildrenByNameIt](name, allTransparent, skipConsumed);
[45143] Fix | Delete
}
[45144] Fix | Delete
}
[45145] Fix | Delete
}
[45146] Fix | Delete
[$isDataValue]() {
[45147] Fix | Delete
if (this[_dataValue] === null) {
[45148] Fix | Delete
return this[_children].length === 0 || this[_children][0][$namespaceId] === NamespaceIds.xhtml.id;
[45149] Fix | Delete
}
[45150] Fix | Delete
return this[_dataValue];
[45151] Fix | Delete
}
[45152] Fix | Delete
[$getDataValue]() {
[45153] Fix | Delete
if (this[_dataValue] === null) {
[45154] Fix | Delete
if (this[_children].length === 0) {
[45155] Fix | Delete
return this[$content].trim();
[45156] Fix | Delete
}
[45157] Fix | Delete
if (this[_children][0][$namespaceId] === NamespaceIds.xhtml.id) {
[45158] Fix | Delete
return this[_children][0][$text]().trim();
[45159] Fix | Delete
}
[45160] Fix | Delete
return null;
[45161] Fix | Delete
}
[45162] Fix | Delete
return this[$content].trim();
[45163] Fix | Delete
}
[45164] Fix | Delete
[$setValue](value) {
[45165] Fix | Delete
value = value.value || "";
[45166] Fix | Delete
this[$content] = value.toString();
[45167] Fix | Delete
}
[45168] Fix | Delete
[$dump](hasNS = false) {
[45169] Fix | Delete
const dumped = Object.create(null);
[45170] Fix | Delete
if (hasNS) {
[45171] Fix | Delete
dumped.$ns = this[$namespaceId];
[45172] Fix | Delete
}
[45173] Fix | Delete
if (this[$content]) {
[45174] Fix | Delete
dumped.$content = this[$content];
[45175] Fix | Delete
}
[45176] Fix | Delete
dumped.$name = this[$nodeName];
[45177] Fix | Delete
dumped.children = [];
[45178] Fix | Delete
for (const child of this[_children]) {
[45179] Fix | Delete
dumped.children.push(child[$dump](hasNS));
[45180] Fix | Delete
}
[45181] Fix | Delete
dumped.attributes = Object.create(null);
[45182] Fix | Delete
for (const [name, value] of this[_attributes]) {
[45183] Fix | Delete
dumped.attributes[name] = value[$content];
[45184] Fix | Delete
}
[45185] Fix | Delete
return dumped;
[45186] Fix | Delete
}
[45187] Fix | Delete
}
[45188] Fix | Delete
class ContentObject extends XFAObject {
[45189] Fix | Delete
constructor(nsId, name) {
[45190] Fix | Delete
super(nsId, name);
[45191] Fix | Delete
this[$content] = "";
[45192] Fix | Delete
}
[45193] Fix | Delete
[$onText](text) {
[45194] Fix | Delete
this[$content] += text;
[45195] Fix | Delete
}
[45196] Fix | Delete
[$finalize]() {}
[45197] Fix | Delete
}
[45198] Fix | Delete
class OptionObject extends ContentObject {
[45199] Fix | Delete
constructor(nsId, name, options) {
[45200] Fix | Delete
super(nsId, name);
[45201] Fix | Delete
this[_options] = options;
[45202] Fix | Delete
}
[45203] Fix | Delete
[$finalize]() {
[45204] Fix | Delete
this[$content] = getKeyword({
[45205] Fix | Delete
data: this[$content],
[45206] Fix | Delete
defaultValue: this[_options][0],
[45207] Fix | Delete
validate: k => this[_options].includes(k)
[45208] Fix | Delete
});
[45209] Fix | Delete
}
[45210] Fix | Delete
[$clean](builder) {
[45211] Fix | Delete
super[$clean](builder);
[45212] Fix | Delete
delete this[_options];
[45213] Fix | Delete
}
[45214] Fix | Delete
}
[45215] Fix | Delete
class StringObject extends ContentObject {
[45216] Fix | Delete
[$finalize]() {
[45217] Fix | Delete
this[$content] = this[$content].trim();
[45218] Fix | Delete
}
[45219] Fix | Delete
}
[45220] Fix | Delete
class IntegerObject extends ContentObject {
[45221] Fix | Delete
constructor(nsId, name, defaultValue, validator) {
[45222] Fix | Delete
super(nsId, name);
[45223] Fix | Delete
this[_defaultValue] = defaultValue;
[45224] Fix | Delete
this[_validator] = validator;
[45225] Fix | Delete
}
[45226] Fix | Delete
[$finalize]() {
[45227] Fix | Delete
this[$content] = getInteger({
[45228] Fix | Delete
data: this[$content],
[45229] Fix | Delete
defaultValue: this[_defaultValue],
[45230] Fix | Delete
validate: this[_validator]
[45231] Fix | Delete
});
[45232] Fix | Delete
}
[45233] Fix | Delete
[$clean](builder) {
[45234] Fix | Delete
super[$clean](builder);
[45235] Fix | Delete
delete this[_defaultValue];
[45236] Fix | Delete
delete this[_validator];
[45237] Fix | Delete
}
[45238] Fix | Delete
}
[45239] Fix | Delete
class Option01 extends IntegerObject {
[45240] Fix | Delete
constructor(nsId, name) {
[45241] Fix | Delete
super(nsId, name, 0, n => n === 1);
[45242] Fix | Delete
}
[45243] Fix | Delete
}
[45244] Fix | Delete
class Option10 extends IntegerObject {
[45245] Fix | Delete
constructor(nsId, name) {
[45246] Fix | Delete
super(nsId, name, 1, n => n === 0);
[45247] Fix | Delete
}
[45248] Fix | Delete
}
[45249] Fix | Delete
[45250] Fix | Delete
;// CONCATENATED MODULE: ./src/core/xfa/html_utils.js
[45251] Fix | Delete
[45252] Fix | Delete
[45253] Fix | Delete
[45254] Fix | Delete
[45255] Fix | Delete
[45256] Fix | Delete
[45257] Fix | Delete
[45258] Fix | Delete
[45259] Fix | Delete
[45260] Fix | Delete
[45261] Fix | Delete
function measureToString(m) {
[45262] Fix | Delete
if (typeof m === "string") {
[45263] Fix | Delete
return "0px";
[45264] Fix | Delete
}
[45265] Fix | Delete
return Number.isInteger(m) ? `${m}px` : `${m.toFixed(2)}px`;
[45266] Fix | Delete
}
[45267] Fix | Delete
const converters = {
[45268] Fix | Delete
anchorType(node, style) {
[45269] Fix | Delete
const parent = node[$getSubformParent]();
[45270] Fix | Delete
if (!parent || parent.layout && parent.layout !== "position") {
[45271] Fix | Delete
return;
[45272] Fix | Delete
}
[45273] Fix | Delete
if (!("transform" in style)) {
[45274] Fix | Delete
style.transform = "";
[45275] Fix | Delete
}
[45276] Fix | Delete
switch (node.anchorType) {
[45277] Fix | Delete
case "bottomCenter":
[45278] Fix | Delete
style.transform += "translate(-50%, -100%)";
[45279] Fix | Delete
break;
[45280] Fix | Delete
case "bottomLeft":
[45281] Fix | Delete
style.transform += "translate(0,-100%)";
[45282] Fix | Delete
break;
[45283] Fix | Delete
case "bottomRight":
[45284] Fix | Delete
style.transform += "translate(-100%,-100%)";
[45285] Fix | Delete
break;
[45286] Fix | Delete
case "middleCenter":
[45287] Fix | Delete
style.transform += "translate(-50%,-50%)";
[45288] Fix | Delete
break;
[45289] Fix | Delete
case "middleLeft":
[45290] Fix | Delete
style.transform += "translate(0,-50%)";
[45291] Fix | Delete
break;
[45292] Fix | Delete
case "middleRight":
[45293] Fix | Delete
style.transform += "translate(-100%,-50%)";
[45294] Fix | Delete
break;
[45295] Fix | Delete
case "topCenter":
[45296] Fix | Delete
style.transform += "translate(-50%,0)";
[45297] Fix | Delete
break;
[45298] Fix | Delete
case "topRight":
[45299] Fix | Delete
style.transform += "translate(-100%,0)";
[45300] Fix | Delete
break;
[45301] Fix | Delete
}
[45302] Fix | Delete
},
[45303] Fix | Delete
dimensions(node, style) {
[45304] Fix | Delete
const parent = node[$getSubformParent]();
[45305] Fix | Delete
let width = node.w;
[45306] Fix | Delete
const height = node.h;
[45307] Fix | Delete
if (parent.layout?.includes("row")) {
[45308] Fix | Delete
const extra = parent[$extra];
[45309] Fix | Delete
const colSpan = node.colSpan;
[45310] Fix | Delete
let w;
[45311] Fix | Delete
if (colSpan === -1) {
[45312] Fix | Delete
w = extra.columnWidths.slice(extra.currentColumn).reduce((a, x) => a + x, 0);
[45313] Fix | Delete
extra.currentColumn = 0;
[45314] Fix | Delete
} else {
[45315] Fix | Delete
w = extra.columnWidths.slice(extra.currentColumn, extra.currentColumn + colSpan).reduce((a, x) => a + x, 0);
[45316] Fix | Delete
extra.currentColumn = (extra.currentColumn + node.colSpan) % extra.columnWidths.length;
[45317] Fix | Delete
}
[45318] Fix | Delete
if (!isNaN(w)) {
[45319] Fix | Delete
width = node.w = w;
[45320] Fix | Delete
}
[45321] Fix | Delete
}
[45322] Fix | Delete
style.width = width !== "" ? measureToString(width) : "auto";
[45323] Fix | Delete
style.height = height !== "" ? measureToString(height) : "auto";
[45324] Fix | Delete
},
[45325] Fix | Delete
position(node, style) {
[45326] Fix | Delete
const parent = node[$getSubformParent]();
[45327] Fix | Delete
if (parent?.layout && parent.layout !== "position") {
[45328] Fix | Delete
return;
[45329] Fix | Delete
}
[45330] Fix | Delete
style.position = "absolute";
[45331] Fix | Delete
style.left = measureToString(node.x);
[45332] Fix | Delete
style.top = measureToString(node.y);
[45333] Fix | Delete
},
[45334] Fix | Delete
rotate(node, style) {
[45335] Fix | Delete
if (node.rotate) {
[45336] Fix | Delete
if (!("transform" in style)) {
[45337] Fix | Delete
style.transform = "";
[45338] Fix | Delete
}
[45339] Fix | Delete
style.transform += `rotate(-${node.rotate}deg)`;
[45340] Fix | Delete
style.transformOrigin = "top left";
[45341] Fix | Delete
}
[45342] Fix | Delete
},
[45343] Fix | Delete
presence(node, style) {
[45344] Fix | Delete
switch (node.presence) {
[45345] Fix | Delete
case "invisible":
[45346] Fix | Delete
style.visibility = "hidden";
[45347] Fix | Delete
break;
[45348] Fix | Delete
case "hidden":
[45349] Fix | Delete
case "inactive":
[45350] Fix | Delete
style.display = "none";
[45351] Fix | Delete
break;
[45352] Fix | Delete
}
[45353] Fix | Delete
},
[45354] Fix | Delete
hAlign(node, style) {
[45355] Fix | Delete
if (node[$nodeName] === "para") {
[45356] Fix | Delete
switch (node.hAlign) {
[45357] Fix | Delete
case "justifyAll":
[45358] Fix | Delete
style.textAlign = "justify-all";
[45359] Fix | Delete
break;
[45360] Fix | Delete
case "radix":
[45361] Fix | Delete
style.textAlign = "left";
[45362] Fix | Delete
break;
[45363] Fix | Delete
default:
[45364] Fix | Delete
style.textAlign = node.hAlign;
[45365] Fix | Delete
}
[45366] Fix | Delete
} else {
[45367] Fix | Delete
switch (node.hAlign) {
[45368] Fix | Delete
case "left":
[45369] Fix | Delete
style.alignSelf = "start";
[45370] Fix | Delete
break;
[45371] Fix | Delete
case "center":
[45372] Fix | Delete
style.alignSelf = "center";
[45373] Fix | Delete
break;
[45374] Fix | Delete
case "right":
[45375] Fix | Delete
style.alignSelf = "end";
[45376] Fix | Delete
break;
[45377] Fix | Delete
}
[45378] Fix | Delete
}
[45379] Fix | Delete
},
[45380] Fix | Delete
margin(node, style) {
[45381] Fix | Delete
if (node.margin) {
[45382] Fix | Delete
style.margin = node.margin[$toStyle]().margin;
[45383] Fix | Delete
}
[45384] Fix | Delete
}
[45385] Fix | Delete
};
[45386] Fix | Delete
function setMinMaxDimensions(node, style) {
[45387] Fix | Delete
const parent = node[$getSubformParent]();
[45388] Fix | Delete
if (parent.layout === "position") {
[45389] Fix | Delete
if (node.minW > 0) {
[45390] Fix | Delete
style.minWidth = measureToString(node.minW);
[45391] Fix | Delete
}
[45392] Fix | Delete
if (node.maxW > 0) {
[45393] Fix | Delete
style.maxWidth = measureToString(node.maxW);
[45394] Fix | Delete
}
[45395] Fix | Delete
if (node.minH > 0) {
[45396] Fix | Delete
style.minHeight = measureToString(node.minH);
[45397] Fix | Delete
}
[45398] Fix | Delete
if (node.maxH > 0) {
[45399] Fix | Delete
style.maxHeight = measureToString(node.maxH);
[45400] Fix | Delete
}
[45401] Fix | Delete
}
[45402] Fix | Delete
}
[45403] Fix | Delete
function layoutText(text, xfaFont, margin, lineHeight, fontFinder, width) {
[45404] Fix | Delete
const measure = new TextMeasure(xfaFont, margin, lineHeight, fontFinder);
[45405] Fix | Delete
if (typeof text === "string") {
[45406] Fix | Delete
measure.addString(text);
[45407] Fix | Delete
} else {
[45408] Fix | Delete
text[$pushGlyphs](measure);
[45409] Fix | Delete
}
[45410] Fix | Delete
return measure.compute(width);
[45411] Fix | Delete
}
[45412] Fix | Delete
function layoutNode(node, availableSpace) {
[45413] Fix | Delete
let height = null;
[45414] Fix | Delete
let width = null;
[45415] Fix | Delete
let isBroken = false;
[45416] Fix | Delete
if ((!node.w || !node.h) && node.value) {
[45417] Fix | Delete
let marginH = 0;
[45418] Fix | Delete
let marginV = 0;
[45419] Fix | Delete
if (node.margin) {
[45420] Fix | Delete
marginH = node.margin.leftInset + node.margin.rightInset;
[45421] Fix | Delete
marginV = node.margin.topInset + node.margin.bottomInset;
[45422] Fix | Delete
}
[45423] Fix | Delete
let lineHeight = null;
[45424] Fix | Delete
let margin = null;
[45425] Fix | Delete
if (node.para) {
[45426] Fix | Delete
margin = Object.create(null);
[45427] Fix | Delete
lineHeight = node.para.lineHeight === "" ? null : node.para.lineHeight;
[45428] Fix | Delete
margin.top = node.para.spaceAbove === "" ? 0 : node.para.spaceAbove;
[45429] Fix | Delete
margin.bottom = node.para.spaceBelow === "" ? 0 : node.para.spaceBelow;
[45430] Fix | Delete
margin.left = node.para.marginLeft === "" ? 0 : node.para.marginLeft;
[45431] Fix | Delete
margin.right = node.para.marginRight === "" ? 0 : node.para.marginRight;
[45432] Fix | Delete
}
[45433] Fix | Delete
let font = node.font;
[45434] Fix | Delete
if (!font) {
[45435] Fix | Delete
const root = node[$getTemplateRoot]();
[45436] Fix | Delete
let parent = node[$getParent]();
[45437] Fix | Delete
while (parent && parent !== root) {
[45438] Fix | Delete
if (parent.font) {
[45439] Fix | Delete
font = parent.font;
[45440] Fix | Delete
break;
[45441] Fix | Delete
}
[45442] Fix | Delete
parent = parent[$getParent]();
[45443] Fix | Delete
}
[45444] Fix | Delete
}
[45445] Fix | Delete
const maxWidth = (node.w || availableSpace.width) - marginH;
[45446] Fix | Delete
const fontFinder = node[$globalData].fontFinder;
[45447] Fix | Delete
if (node.value.exData && node.value.exData[$content] && node.value.exData.contentType === "text/html") {
[45448] Fix | Delete
const res = layoutText(node.value.exData[$content], font, margin, lineHeight, fontFinder, maxWidth);
[45449] Fix | Delete
width = res.width;
[45450] Fix | Delete
height = res.height;
[45451] Fix | Delete
isBroken = res.isBroken;
[45452] Fix | Delete
} else {
[45453] Fix | Delete
const text = node.value[$text]();
[45454] Fix | Delete
if (text) {
[45455] Fix | Delete
const res = layoutText(text, font, margin, lineHeight, fontFinder, maxWidth);
[45456] Fix | Delete
width = res.width;
[45457] Fix | Delete
height = res.height;
[45458] Fix | Delete
isBroken = res.isBroken;
[45459] Fix | Delete
}
[45460] Fix | Delete
}
[45461] Fix | Delete
if (width !== null && !node.w) {
[45462] Fix | Delete
width += marginH;
[45463] Fix | Delete
}
[45464] Fix | Delete
if (height !== null && !node.h) {
[45465] Fix | Delete
height += marginV;
[45466] Fix | Delete
}
[45467] Fix | Delete
}
[45468] Fix | Delete
return {
[45469] Fix | Delete
w: width,
[45470] Fix | Delete
h: height,
[45471] Fix | Delete
isBroken
[45472] Fix | Delete
};
[45473] Fix | Delete
}
[45474] Fix | Delete
function computeBbox(node, html, availableSpace) {
[45475] Fix | Delete
let bbox;
[45476] Fix | Delete
if (node.w !== "" && node.h !== "") {
[45477] Fix | Delete
bbox = [node.x, node.y, node.w, node.h];
[45478] Fix | Delete
} else {
[45479] Fix | Delete
if (!availableSpace) {
[45480] Fix | Delete
return null;
[45481] Fix | Delete
}
[45482] Fix | Delete
let width = node.w;
[45483] Fix | Delete
if (width === "") {
[45484] Fix | Delete
if (node.maxW === 0) {
[45485] Fix | Delete
const parent = node[$getSubformParent]();
[45486] Fix | Delete
width = parent.layout === "position" && parent.w !== "" ? 0 : node.minW;
[45487] Fix | Delete
} else {
[45488] Fix | Delete
width = Math.min(node.maxW, availableSpace.width);
[45489] Fix | Delete
}
[45490] Fix | Delete
html.attributes.style.width = measureToString(width);
[45491] Fix | Delete
}
[45492] Fix | Delete
let height = node.h;
[45493] Fix | Delete
if (height === "") {
[45494] Fix | Delete
if (node.maxH === 0) {
[45495] Fix | Delete
const parent = node[$getSubformParent]();
[45496] Fix | Delete
height = parent.layout === "position" && parent.h !== "" ? 0 : node.minH;
[45497] Fix | Delete
} else {
[45498] Fix | Delete
height = Math.min(node.maxH, availableSpace.height);
[45499] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function