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-inclu.../js/dist
File: components.js
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/debug/record.mjs
[24000] Fix | Delete
function record(data) {
[24001] Fix | Delete
if (window.MotionDebug) {
[24002] Fix | Delete
window.MotionDebug.record(data);
[24003] Fix | Delete
}
[24004] Fix | Delete
}
[24005] Fix | Delete
[24006] Fix | Delete
[24007] Fix | Delete
[24008] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/render/dom/utils/is-svg-element.mjs
[24009] Fix | Delete
function isSVGElement(element) {
[24010] Fix | Delete
return element instanceof SVGElement && element.tagName !== "svg";
[24011] Fix | Delete
}
[24012] Fix | Delete
[24013] Fix | Delete
[24014] Fix | Delete
[24015] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/animation/interfaces/single-value.mjs
[24016] Fix | Delete
[24017] Fix | Delete
[24018] Fix | Delete
[24019] Fix | Delete
[24020] Fix | Delete
function animateSingleValue(value, keyframes, options) {
[24021] Fix | Delete
const motionValue$1 = isMotionValue(value) ? value : motionValue(value);
[24022] Fix | Delete
motionValue$1.start(animateMotionValue("", motionValue$1, keyframes, options));
[24023] Fix | Delete
return motionValue$1.animation;
[24024] Fix | Delete
}
[24025] Fix | Delete
[24026] Fix | Delete
[24027] Fix | Delete
[24028] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/projection/node/create-projection-node.mjs
[24029] Fix | Delete
[24030] Fix | Delete
[24031] Fix | Delete
[24032] Fix | Delete
[24033] Fix | Delete
[24034] Fix | Delete
[24035] Fix | Delete
[24036] Fix | Delete
[24037] Fix | Delete
[24038] Fix | Delete
[24039] Fix | Delete
[24040] Fix | Delete
[24041] Fix | Delete
[24042] Fix | Delete
[24043] Fix | Delete
[24044] Fix | Delete
[24045] Fix | Delete
[24046] Fix | Delete
[24047] Fix | Delete
[24048] Fix | Delete
[24049] Fix | Delete
[24050] Fix | Delete
[24051] Fix | Delete
[24052] Fix | Delete
[24053] Fix | Delete
[24054] Fix | Delete
[24055] Fix | Delete
[24056] Fix | Delete
[24057] Fix | Delete
const transformAxes = ["", "X", "Y", "Z"];
[24058] Fix | Delete
const hiddenVisibility = { visibility: "hidden" };
[24059] Fix | Delete
/**
[24060] Fix | Delete
* We use 1000 as the animation target as 0-1000 maps better to pixels than 0-1
[24061] Fix | Delete
* which has a noticeable difference in spring animations
[24062] Fix | Delete
*/
[24063] Fix | Delete
const animationTarget = 1000;
[24064] Fix | Delete
let create_projection_node_id = 0;
[24065] Fix | Delete
/**
[24066] Fix | Delete
* Use a mutable data object for debug data so as to not create a new
[24067] Fix | Delete
* object every frame.
[24068] Fix | Delete
*/
[24069] Fix | Delete
const projectionFrameData = {
[24070] Fix | Delete
type: "projectionFrame",
[24071] Fix | Delete
totalNodes: 0,
[24072] Fix | Delete
resolvedTargetDeltas: 0,
[24073] Fix | Delete
recalculatedProjection: 0,
[24074] Fix | Delete
};
[24075] Fix | Delete
function resetDistortingTransform(key, visualElement, values, sharedAnimationValues) {
[24076] Fix | Delete
const { latestValues } = visualElement;
[24077] Fix | Delete
// Record the distorting transform and then temporarily set it to 0
[24078] Fix | Delete
if (latestValues[key]) {
[24079] Fix | Delete
values[key] = latestValues[key];
[24080] Fix | Delete
visualElement.setStaticValue(key, 0);
[24081] Fix | Delete
if (sharedAnimationValues) {
[24082] Fix | Delete
sharedAnimationValues[key] = 0;
[24083] Fix | Delete
}
[24084] Fix | Delete
}
[24085] Fix | Delete
}
[24086] Fix | Delete
function createProjectionNode({ attachResizeListener, defaultParent, measureScroll, checkIsScrollRoot, resetTransform, }) {
[24087] Fix | Delete
return class ProjectionNode {
[24088] Fix | Delete
constructor(latestValues = {}, parent = defaultParent === null || defaultParent === void 0 ? void 0 : defaultParent()) {
[24089] Fix | Delete
/**
[24090] Fix | Delete
* A unique ID generated for every projection node.
[24091] Fix | Delete
*/
[24092] Fix | Delete
this.id = create_projection_node_id++;
[24093] Fix | Delete
/**
[24094] Fix | Delete
* An id that represents a unique session instigated by startUpdate.
[24095] Fix | Delete
*/
[24096] Fix | Delete
this.animationId = 0;
[24097] Fix | Delete
/**
[24098] Fix | Delete
* A Set containing all this component's children. This is used to iterate
[24099] Fix | Delete
* through the children.
[24100] Fix | Delete
*
[24101] Fix | Delete
* TODO: This could be faster to iterate as a flat array stored on the root node.
[24102] Fix | Delete
*/
[24103] Fix | Delete
this.children = new Set();
[24104] Fix | Delete
/**
[24105] Fix | Delete
* Options for the node. We use this to configure what kind of layout animations
[24106] Fix | Delete
* we should perform (if any).
[24107] Fix | Delete
*/
[24108] Fix | Delete
this.options = {};
[24109] Fix | Delete
/**
[24110] Fix | Delete
* We use this to detect when its safe to shut down part of a projection tree.
[24111] Fix | Delete
* We have to keep projecting children for scale correction and relative projection
[24112] Fix | Delete
* until all their parents stop performing layout animations.
[24113] Fix | Delete
*/
[24114] Fix | Delete
this.isTreeAnimating = false;
[24115] Fix | Delete
this.isAnimationBlocked = false;
[24116] Fix | Delete
/**
[24117] Fix | Delete
* Flag to true if we think this layout has been changed. We can't always know this,
[24118] Fix | Delete
* currently we set it to true every time a component renders, or if it has a layoutDependency
[24119] Fix | Delete
* if that has changed between renders. Additionally, components can be grouped by LayoutGroup
[24120] Fix | Delete
* and if one node is dirtied, they all are.
[24121] Fix | Delete
*/
[24122] Fix | Delete
this.isLayoutDirty = false;
[24123] Fix | Delete
/**
[24124] Fix | Delete
* Flag to true if we think the projection calculations for this node needs
[24125] Fix | Delete
* recalculating as a result of an updated transform or layout animation.
[24126] Fix | Delete
*/
[24127] Fix | Delete
this.isProjectionDirty = false;
[24128] Fix | Delete
/**
[24129] Fix | Delete
* Flag to true if the layout *or* transform has changed. This then gets propagated
[24130] Fix | Delete
* throughout the projection tree, forcing any element below to recalculate on the next frame.
[24131] Fix | Delete
*/
[24132] Fix | Delete
this.isSharedProjectionDirty = false;
[24133] Fix | Delete
/**
[24134] Fix | Delete
* Flag transform dirty. This gets propagated throughout the whole tree but is only
[24135] Fix | Delete
* respected by shared nodes.
[24136] Fix | Delete
*/
[24137] Fix | Delete
this.isTransformDirty = false;
[24138] Fix | Delete
/**
[24139] Fix | Delete
* Block layout updates for instant layout transitions throughout the tree.
[24140] Fix | Delete
*/
[24141] Fix | Delete
this.updateManuallyBlocked = false;
[24142] Fix | Delete
this.updateBlockedByResize = false;
[24143] Fix | Delete
/**
[24144] Fix | Delete
* Set to true between the start of the first `willUpdate` call and the end of the `didUpdate`
[24145] Fix | Delete
* call.
[24146] Fix | Delete
*/
[24147] Fix | Delete
this.isUpdating = false;
[24148] Fix | Delete
/**
[24149] Fix | Delete
* If this is an SVG element we currently disable projection transforms
[24150] Fix | Delete
*/
[24151] Fix | Delete
this.isSVG = false;
[24152] Fix | Delete
/**
[24153] Fix | Delete
* Flag to true (during promotion) if a node doing an instant layout transition needs to reset
[24154] Fix | Delete
* its projection styles.
[24155] Fix | Delete
*/
[24156] Fix | Delete
this.needsReset = false;
[24157] Fix | Delete
/**
[24158] Fix | Delete
* Flags whether this node should have its transform reset prior to measuring.
[24159] Fix | Delete
*/
[24160] Fix | Delete
this.shouldResetTransform = false;
[24161] Fix | Delete
/**
[24162] Fix | Delete
* An object representing the calculated contextual/accumulated/tree scale.
[24163] Fix | Delete
* This will be used to scale calculcated projection transforms, as these are
[24164] Fix | Delete
* calculated in screen-space but need to be scaled for elements to layoutly
[24165] Fix | Delete
* make it to their calculated destinations.
[24166] Fix | Delete
*
[24167] Fix | Delete
* TODO: Lazy-init
[24168] Fix | Delete
*/
[24169] Fix | Delete
this.treeScale = { x: 1, y: 1 };
[24170] Fix | Delete
/**
[24171] Fix | Delete
*
[24172] Fix | Delete
*/
[24173] Fix | Delete
this.eventHandlers = new Map();
[24174] Fix | Delete
this.hasTreeAnimated = false;
[24175] Fix | Delete
// Note: Currently only running on root node
[24176] Fix | Delete
this.updateScheduled = false;
[24177] Fix | Delete
this.projectionUpdateScheduled = false;
[24178] Fix | Delete
this.checkUpdateFailed = () => {
[24179] Fix | Delete
if (this.isUpdating) {
[24180] Fix | Delete
this.isUpdating = false;
[24181] Fix | Delete
this.clearAllSnapshots();
[24182] Fix | Delete
}
[24183] Fix | Delete
};
[24184] Fix | Delete
/**
[24185] Fix | Delete
* This is a multi-step process as shared nodes might be of different depths. Nodes
[24186] Fix | Delete
* are sorted by depth order, so we need to resolve the entire tree before moving to
[24187] Fix | Delete
* the next step.
[24188] Fix | Delete
*/
[24189] Fix | Delete
this.updateProjection = () => {
[24190] Fix | Delete
this.projectionUpdateScheduled = false;
[24191] Fix | Delete
/**
[24192] Fix | Delete
* Reset debug counts. Manually resetting rather than creating a new
[24193] Fix | Delete
* object each frame.
[24194] Fix | Delete
*/
[24195] Fix | Delete
projectionFrameData.totalNodes =
[24196] Fix | Delete
projectionFrameData.resolvedTargetDeltas =
[24197] Fix | Delete
projectionFrameData.recalculatedProjection =
[24198] Fix | Delete
0;
[24199] Fix | Delete
this.nodes.forEach(propagateDirtyNodes);
[24200] Fix | Delete
this.nodes.forEach(resolveTargetDelta);
[24201] Fix | Delete
this.nodes.forEach(calcProjection);
[24202] Fix | Delete
this.nodes.forEach(cleanDirtyNodes);
[24203] Fix | Delete
record(projectionFrameData);
[24204] Fix | Delete
};
[24205] Fix | Delete
this.hasProjected = false;
[24206] Fix | Delete
this.isVisible = true;
[24207] Fix | Delete
this.animationProgress = 0;
[24208] Fix | Delete
/**
[24209] Fix | Delete
* Shared layout
[24210] Fix | Delete
*/
[24211] Fix | Delete
// TODO Only running on root node
[24212] Fix | Delete
this.sharedNodes = new Map();
[24213] Fix | Delete
this.latestValues = latestValues;
[24214] Fix | Delete
this.root = parent ? parent.root || parent : this;
[24215] Fix | Delete
this.path = parent ? [...parent.path, parent] : [];
[24216] Fix | Delete
this.parent = parent;
[24217] Fix | Delete
this.depth = parent ? parent.depth + 1 : 0;
[24218] Fix | Delete
for (let i = 0; i < this.path.length; i++) {
[24219] Fix | Delete
this.path[i].shouldResetTransform = true;
[24220] Fix | Delete
}
[24221] Fix | Delete
if (this.root === this)
[24222] Fix | Delete
this.nodes = new FlatTree();
[24223] Fix | Delete
}
[24224] Fix | Delete
addEventListener(name, handler) {
[24225] Fix | Delete
if (!this.eventHandlers.has(name)) {
[24226] Fix | Delete
this.eventHandlers.set(name, new SubscriptionManager());
[24227] Fix | Delete
}
[24228] Fix | Delete
return this.eventHandlers.get(name).add(handler);
[24229] Fix | Delete
}
[24230] Fix | Delete
notifyListeners(name, ...args) {
[24231] Fix | Delete
const subscriptionManager = this.eventHandlers.get(name);
[24232] Fix | Delete
subscriptionManager && subscriptionManager.notify(...args);
[24233] Fix | Delete
}
[24234] Fix | Delete
hasListeners(name) {
[24235] Fix | Delete
return this.eventHandlers.has(name);
[24236] Fix | Delete
}
[24237] Fix | Delete
/**
[24238] Fix | Delete
* Lifecycles
[24239] Fix | Delete
*/
[24240] Fix | Delete
mount(instance, isLayoutDirty = this.root.hasTreeAnimated) {
[24241] Fix | Delete
if (this.instance)
[24242] Fix | Delete
return;
[24243] Fix | Delete
this.isSVG = isSVGElement(instance);
[24244] Fix | Delete
this.instance = instance;
[24245] Fix | Delete
const { layoutId, layout, visualElement } = this.options;
[24246] Fix | Delete
if (visualElement && !visualElement.current) {
[24247] Fix | Delete
visualElement.mount(instance);
[24248] Fix | Delete
}
[24249] Fix | Delete
this.root.nodes.add(this);
[24250] Fix | Delete
this.parent && this.parent.children.add(this);
[24251] Fix | Delete
if (isLayoutDirty && (layout || layoutId)) {
[24252] Fix | Delete
this.isLayoutDirty = true;
[24253] Fix | Delete
}
[24254] Fix | Delete
if (attachResizeListener) {
[24255] Fix | Delete
let cancelDelay;
[24256] Fix | Delete
const resizeUnblockUpdate = () => (this.root.updateBlockedByResize = false);
[24257] Fix | Delete
attachResizeListener(instance, () => {
[24258] Fix | Delete
this.root.updateBlockedByResize = true;
[24259] Fix | Delete
cancelDelay && cancelDelay();
[24260] Fix | Delete
cancelDelay = delay(resizeUnblockUpdate, 250);
[24261] Fix | Delete
if (globalProjectionState.hasAnimatedSinceResize) {
[24262] Fix | Delete
globalProjectionState.hasAnimatedSinceResize = false;
[24263] Fix | Delete
this.nodes.forEach(finishAnimation);
[24264] Fix | Delete
}
[24265] Fix | Delete
});
[24266] Fix | Delete
}
[24267] Fix | Delete
if (layoutId) {
[24268] Fix | Delete
this.root.registerSharedNode(layoutId, this);
[24269] Fix | Delete
}
[24270] Fix | Delete
// Only register the handler if it requires layout animation
[24271] Fix | Delete
if (this.options.animate !== false &&
[24272] Fix | Delete
visualElement &&
[24273] Fix | Delete
(layoutId || layout)) {
[24274] Fix | Delete
this.addEventListener("didUpdate", ({ delta, hasLayoutChanged, hasRelativeTargetChanged, layout: newLayout, }) => {
[24275] Fix | Delete
if (this.isTreeAnimationBlocked()) {
[24276] Fix | Delete
this.target = undefined;
[24277] Fix | Delete
this.relativeTarget = undefined;
[24278] Fix | Delete
return;
[24279] Fix | Delete
}
[24280] Fix | Delete
// TODO: Check here if an animation exists
[24281] Fix | Delete
const layoutTransition = this.options.transition ||
[24282] Fix | Delete
visualElement.getDefaultTransition() ||
[24283] Fix | Delete
defaultLayoutTransition;
[24284] Fix | Delete
const { onLayoutAnimationStart, onLayoutAnimationComplete, } = visualElement.getProps();
[24285] Fix | Delete
/**
[24286] Fix | Delete
* The target layout of the element might stay the same,
[24287] Fix | Delete
* but its position relative to its parent has changed.
[24288] Fix | Delete
*/
[24289] Fix | Delete
const targetChanged = !this.targetLayout ||
[24290] Fix | Delete
!boxEqualsRounded(this.targetLayout, newLayout) ||
[24291] Fix | Delete
hasRelativeTargetChanged;
[24292] Fix | Delete
/**
[24293] Fix | Delete
* If the layout hasn't seemed to have changed, it might be that the
[24294] Fix | Delete
* element is visually in the same place in the document but its position
[24295] Fix | Delete
* relative to its parent has indeed changed. So here we check for that.
[24296] Fix | Delete
*/
[24297] Fix | Delete
const hasOnlyRelativeTargetChanged = !hasLayoutChanged && hasRelativeTargetChanged;
[24298] Fix | Delete
if (this.options.layoutRoot ||
[24299] Fix | Delete
(this.resumeFrom && this.resumeFrom.instance) ||
[24300] Fix | Delete
hasOnlyRelativeTargetChanged ||
[24301] Fix | Delete
(hasLayoutChanged &&
[24302] Fix | Delete
(targetChanged || !this.currentAnimation))) {
[24303] Fix | Delete
if (this.resumeFrom) {
[24304] Fix | Delete
this.resumingFrom = this.resumeFrom;
[24305] Fix | Delete
this.resumingFrom.resumingFrom = undefined;
[24306] Fix | Delete
}
[24307] Fix | Delete
this.setAnimationOrigin(delta, hasOnlyRelativeTargetChanged);
[24308] Fix | Delete
const animationOptions = {
[24309] Fix | Delete
...getValueTransition(layoutTransition, "layout"),
[24310] Fix | Delete
onPlay: onLayoutAnimationStart,
[24311] Fix | Delete
onComplete: onLayoutAnimationComplete,
[24312] Fix | Delete
};
[24313] Fix | Delete
if (visualElement.shouldReduceMotion ||
[24314] Fix | Delete
this.options.layoutRoot) {
[24315] Fix | Delete
animationOptions.delay = 0;
[24316] Fix | Delete
animationOptions.type = false;
[24317] Fix | Delete
}
[24318] Fix | Delete
this.startAnimation(animationOptions);
[24319] Fix | Delete
}
[24320] Fix | Delete
else {
[24321] Fix | Delete
/**
[24322] Fix | Delete
* If the layout hasn't changed and we have an animation that hasn't started yet,
[24323] Fix | Delete
* finish it immediately. Otherwise it will be animating from a location
[24324] Fix | Delete
* that was probably never commited to screen and look like a jumpy box.
[24325] Fix | Delete
*/
[24326] Fix | Delete
if (!hasLayoutChanged) {
[24327] Fix | Delete
finishAnimation(this);
[24328] Fix | Delete
}
[24329] Fix | Delete
if (this.isLead() && this.options.onExitComplete) {
[24330] Fix | Delete
this.options.onExitComplete();
[24331] Fix | Delete
}
[24332] Fix | Delete
}
[24333] Fix | Delete
this.targetLayout = newLayout;
[24334] Fix | Delete
});
[24335] Fix | Delete
}
[24336] Fix | Delete
}
[24337] Fix | Delete
unmount() {
[24338] Fix | Delete
this.options.layoutId && this.willUpdate();
[24339] Fix | Delete
this.root.nodes.remove(this);
[24340] Fix | Delete
const stack = this.getStack();
[24341] Fix | Delete
stack && stack.remove(this);
[24342] Fix | Delete
this.parent && this.parent.children.delete(this);
[24343] Fix | Delete
this.instance = undefined;
[24344] Fix | Delete
cancelFrame(this.updateProjection);
[24345] Fix | Delete
}
[24346] Fix | Delete
// only on the root
[24347] Fix | Delete
blockUpdate() {
[24348] Fix | Delete
this.updateManuallyBlocked = true;
[24349] Fix | Delete
}
[24350] Fix | Delete
unblockUpdate() {
[24351] Fix | Delete
this.updateManuallyBlocked = false;
[24352] Fix | Delete
}
[24353] Fix | Delete
isUpdateBlocked() {
[24354] Fix | Delete
return this.updateManuallyBlocked || this.updateBlockedByResize;
[24355] Fix | Delete
}
[24356] Fix | Delete
isTreeAnimationBlocked() {
[24357] Fix | Delete
return (this.isAnimationBlocked ||
[24358] Fix | Delete
(this.parent && this.parent.isTreeAnimationBlocked()) ||
[24359] Fix | Delete
false);
[24360] Fix | Delete
}
[24361] Fix | Delete
// Note: currently only running on root node
[24362] Fix | Delete
startUpdate() {
[24363] Fix | Delete
if (this.isUpdateBlocked())
[24364] Fix | Delete
return;
[24365] Fix | Delete
this.isUpdating = true;
[24366] Fix | Delete
/**
[24367] Fix | Delete
* If we're running optimised appear animations then these must be
[24368] Fix | Delete
* cancelled before measuring the DOM. This is so we can measure
[24369] Fix | Delete
* the true layout of the element rather than the WAAPI animation
[24370] Fix | Delete
* which will be unaffected by the resetSkewAndRotate step.
[24371] Fix | Delete
*/
[24372] Fix | Delete
if (window.HandoffCancelAllAnimations) {
[24373] Fix | Delete
window.HandoffCancelAllAnimations();
[24374] Fix | Delete
}
[24375] Fix | Delete
this.nodes && this.nodes.forEach(resetSkewAndRotation);
[24376] Fix | Delete
this.animationId++;
[24377] Fix | Delete
}
[24378] Fix | Delete
getTransformTemplate() {
[24379] Fix | Delete
const { visualElement } = this.options;
[24380] Fix | Delete
return visualElement && visualElement.getProps().transformTemplate;
[24381] Fix | Delete
}
[24382] Fix | Delete
willUpdate(shouldNotifyListeners = true) {
[24383] Fix | Delete
this.root.hasTreeAnimated = true;
[24384] Fix | Delete
if (this.root.isUpdateBlocked()) {
[24385] Fix | Delete
this.options.onExitComplete && this.options.onExitComplete();
[24386] Fix | Delete
return;
[24387] Fix | Delete
}
[24388] Fix | Delete
!this.root.isUpdating && this.root.startUpdate();
[24389] Fix | Delete
if (this.isLayoutDirty)
[24390] Fix | Delete
return;
[24391] Fix | Delete
this.isLayoutDirty = true;
[24392] Fix | Delete
for (let i = 0; i < this.path.length; i++) {
[24393] Fix | Delete
const node = this.path[i];
[24394] Fix | Delete
node.shouldResetTransform = true;
[24395] Fix | Delete
node.updateScroll("snapshot");
[24396] Fix | Delete
if (node.options.layoutRoot) {
[24397] Fix | Delete
node.willUpdate(false);
[24398] Fix | Delete
}
[24399] Fix | Delete
}
[24400] Fix | Delete
const { layoutId, layout } = this.options;
[24401] Fix | Delete
if (layoutId === undefined && !layout)
[24402] Fix | Delete
return;
[24403] Fix | Delete
const transformTemplate = this.getTransformTemplate();
[24404] Fix | Delete
this.prevTransformTemplateValue = transformTemplate
[24405] Fix | Delete
? transformTemplate(this.latestValues, "")
[24406] Fix | Delete
: undefined;
[24407] Fix | Delete
this.updateSnapshot();
[24408] Fix | Delete
shouldNotifyListeners && this.notifyListeners("willUpdate");
[24409] Fix | Delete
}
[24410] Fix | Delete
update() {
[24411] Fix | Delete
this.updateScheduled = false;
[24412] Fix | Delete
const updateWasBlocked = this.isUpdateBlocked();
[24413] Fix | Delete
// When doing an instant transition, we skip the layout update,
[24414] Fix | Delete
// but should still clean up the measurements so that the next
[24415] Fix | Delete
// snapshot could be taken correctly.
[24416] Fix | Delete
if (updateWasBlocked) {
[24417] Fix | Delete
this.unblockUpdate();
[24418] Fix | Delete
this.clearAllSnapshots();
[24419] Fix | Delete
this.nodes.forEach(clearMeasurements);
[24420] Fix | Delete
return;
[24421] Fix | Delete
}
[24422] Fix | Delete
if (!this.isUpdating) {
[24423] Fix | Delete
this.nodes.forEach(clearIsLayoutDirty);
[24424] Fix | Delete
}
[24425] Fix | Delete
this.isUpdating = false;
[24426] Fix | Delete
/**
[24427] Fix | Delete
* Write
[24428] Fix | Delete
*/
[24429] Fix | Delete
this.nodes.forEach(resetTransformStyle);
[24430] Fix | Delete
/**
[24431] Fix | Delete
* Read ==================
[24432] Fix | Delete
*/
[24433] Fix | Delete
// Update layout measurements of updated children
[24434] Fix | Delete
this.nodes.forEach(updateLayout);
[24435] Fix | Delete
/**
[24436] Fix | Delete
* Write
[24437] Fix | Delete
*/
[24438] Fix | Delete
// Notify listeners that the layout is updated
[24439] Fix | Delete
this.nodes.forEach(notifyLayoutUpdate);
[24440] Fix | Delete
this.clearAllSnapshots();
[24441] Fix | Delete
/**
[24442] Fix | Delete
* Manually flush any pending updates. Ideally
[24443] Fix | Delete
* we could leave this to the following requestAnimationFrame but this seems
[24444] Fix | Delete
* to leave a flash of incorrectly styled content.
[24445] Fix | Delete
*/
[24446] Fix | Delete
const now = time.now();
[24447] Fix | Delete
frameData.delta = clamp_clamp(0, 1000 / 60, now - frameData.timestamp);
[24448] Fix | Delete
frameData.timestamp = now;
[24449] Fix | Delete
frameData.isProcessing = true;
[24450] Fix | Delete
steps.update.process(frameData);
[24451] Fix | Delete
steps.preRender.process(frameData);
[24452] Fix | Delete
steps.render.process(frameData);
[24453] Fix | Delete
frameData.isProcessing = false;
[24454] Fix | Delete
}
[24455] Fix | Delete
didUpdate() {
[24456] Fix | Delete
if (!this.updateScheduled) {
[24457] Fix | Delete
this.updateScheduled = true;
[24458] Fix | Delete
microtask.read(() => this.update());
[24459] Fix | Delete
}
[24460] Fix | Delete
}
[24461] Fix | Delete
clearAllSnapshots() {
[24462] Fix | Delete
this.nodes.forEach(clearSnapshot);
[24463] Fix | Delete
this.sharedNodes.forEach(removeLeadSnapshots);
[24464] Fix | Delete
}
[24465] Fix | Delete
scheduleUpdateProjection() {
[24466] Fix | Delete
if (!this.projectionUpdateScheduled) {
[24467] Fix | Delete
this.projectionUpdateScheduled = true;
[24468] Fix | Delete
frame_frame.preRender(this.updateProjection, false, true);
[24469] Fix | Delete
}
[24470] Fix | Delete
}
[24471] Fix | Delete
scheduleCheckAfterUnmount() {
[24472] Fix | Delete
/**
[24473] Fix | Delete
* If the unmounting node is in a layoutGroup and did trigger a willUpdate,
[24474] Fix | Delete
* we manually call didUpdate to give a chance to the siblings to animate.
[24475] Fix | Delete
* Otherwise, cleanup all snapshots to prevents future nodes from reusing them.
[24476] Fix | Delete
*/
[24477] Fix | Delete
frame_frame.postRender(() => {
[24478] Fix | Delete
if (this.isLayoutDirty) {
[24479] Fix | Delete
this.root.didUpdate();
[24480] Fix | Delete
}
[24481] Fix | Delete
else {
[24482] Fix | Delete
this.root.checkUpdateFailed();
[24483] Fix | Delete
}
[24484] Fix | Delete
});
[24485] Fix | Delete
}
[24486] Fix | Delete
/**
[24487] Fix | Delete
* Update measurements
[24488] Fix | Delete
*/
[24489] Fix | Delete
updateSnapshot() {
[24490] Fix | Delete
if (this.snapshot || !this.instance)
[24491] Fix | Delete
return;
[24492] Fix | Delete
this.snapshot = this.measure();
[24493] Fix | Delete
}
[24494] Fix | Delete
updateLayout() {
[24495] Fix | Delete
if (!this.instance)
[24496] Fix | Delete
return;
[24497] Fix | Delete
// TODO: Incorporate into a forwarded scroll offset
[24498] Fix | Delete
this.updateScroll();
[24499] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function