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
return animations;
[22000] Fix | Delete
}
[22001] Fix | Delete
return {
[22002] Fix | Delete
animateChanges,
[22003] Fix | Delete
setActive,
[22004] Fix | Delete
setAnimateFunction,
[22005] Fix | Delete
getState: () => state,
[22006] Fix | Delete
};
[22007] Fix | Delete
}
[22008] Fix | Delete
function checkVariantsDidChange(prev, next) {
[22009] Fix | Delete
if (typeof next === "string") {
[22010] Fix | Delete
return next !== prev;
[22011] Fix | Delete
}
[22012] Fix | Delete
else if (Array.isArray(next)) {
[22013] Fix | Delete
return !shallowCompare(next, prev);
[22014] Fix | Delete
}
[22015] Fix | Delete
return false;
[22016] Fix | Delete
}
[22017] Fix | Delete
function createTypeState(isActive = false) {
[22018] Fix | Delete
return {
[22019] Fix | Delete
isActive,
[22020] Fix | Delete
protectedKeys: {},
[22021] Fix | Delete
needsAnimating: {},
[22022] Fix | Delete
prevResolvedValues: {},
[22023] Fix | Delete
};
[22024] Fix | Delete
}
[22025] Fix | Delete
function createState() {
[22026] Fix | Delete
return {
[22027] Fix | Delete
animate: createTypeState(true),
[22028] Fix | Delete
whileInView: createTypeState(),
[22029] Fix | Delete
whileHover: createTypeState(),
[22030] Fix | Delete
whileTap: createTypeState(),
[22031] Fix | Delete
whileDrag: createTypeState(),
[22032] Fix | Delete
whileFocus: createTypeState(),
[22033] Fix | Delete
exit: createTypeState(),
[22034] Fix | Delete
};
[22035] Fix | Delete
}
[22036] Fix | Delete
[22037] Fix | Delete
[22038] Fix | Delete
[22039] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/motion/features/animation/index.mjs
[22040] Fix | Delete
[22041] Fix | Delete
[22042] Fix | Delete
[22043] Fix | Delete
[22044] Fix | Delete
class AnimationFeature extends Feature {
[22045] Fix | Delete
/**
[22046] Fix | Delete
* We dynamically generate the AnimationState manager as it contains a reference
[22047] Fix | Delete
* to the underlying animation library. We only want to load that if we load this,
[22048] Fix | Delete
* so people can optionally code split it out using the `m` component.
[22049] Fix | Delete
*/
[22050] Fix | Delete
constructor(node) {
[22051] Fix | Delete
super(node);
[22052] Fix | Delete
node.animationState || (node.animationState = createAnimationState(node));
[22053] Fix | Delete
}
[22054] Fix | Delete
updateAnimationControlsSubscription() {
[22055] Fix | Delete
const { animate } = this.node.getProps();
[22056] Fix | Delete
this.unmount();
[22057] Fix | Delete
if (isAnimationControls(animate)) {
[22058] Fix | Delete
this.unmount = animate.subscribe(this.node);
[22059] Fix | Delete
}
[22060] Fix | Delete
}
[22061] Fix | Delete
/**
[22062] Fix | Delete
* Subscribe any provided AnimationControls to the component's VisualElement
[22063] Fix | Delete
*/
[22064] Fix | Delete
mount() {
[22065] Fix | Delete
this.updateAnimationControlsSubscription();
[22066] Fix | Delete
}
[22067] Fix | Delete
update() {
[22068] Fix | Delete
const { animate } = this.node.getProps();
[22069] Fix | Delete
const { animate: prevAnimate } = this.node.prevProps || {};
[22070] Fix | Delete
if (animate !== prevAnimate) {
[22071] Fix | Delete
this.updateAnimationControlsSubscription();
[22072] Fix | Delete
}
[22073] Fix | Delete
}
[22074] Fix | Delete
unmount() { }
[22075] Fix | Delete
}
[22076] Fix | Delete
[22077] Fix | Delete
[22078] Fix | Delete
[22079] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/motion/features/animation/exit.mjs
[22080] Fix | Delete
[22081] Fix | Delete
[22082] Fix | Delete
let id = 0;
[22083] Fix | Delete
class ExitAnimationFeature extends Feature {
[22084] Fix | Delete
constructor() {
[22085] Fix | Delete
super(...arguments);
[22086] Fix | Delete
this.id = id++;
[22087] Fix | Delete
}
[22088] Fix | Delete
update() {
[22089] Fix | Delete
if (!this.node.presenceContext)
[22090] Fix | Delete
return;
[22091] Fix | Delete
const { isPresent, onExitComplete } = this.node.presenceContext;
[22092] Fix | Delete
const { isPresent: prevIsPresent } = this.node.prevPresenceContext || {};
[22093] Fix | Delete
if (!this.node.animationState || isPresent === prevIsPresent) {
[22094] Fix | Delete
return;
[22095] Fix | Delete
}
[22096] Fix | Delete
const exitAnimation = this.node.animationState.setActive("exit", !isPresent);
[22097] Fix | Delete
if (onExitComplete && !isPresent) {
[22098] Fix | Delete
exitAnimation.then(() => onExitComplete(this.id));
[22099] Fix | Delete
}
[22100] Fix | Delete
}
[22101] Fix | Delete
mount() {
[22102] Fix | Delete
const { register } = this.node.presenceContext || {};
[22103] Fix | Delete
if (register) {
[22104] Fix | Delete
this.unmount = register(this.id);
[22105] Fix | Delete
}
[22106] Fix | Delete
}
[22107] Fix | Delete
unmount() { }
[22108] Fix | Delete
}
[22109] Fix | Delete
[22110] Fix | Delete
[22111] Fix | Delete
[22112] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/motion/features/animations.mjs
[22113] Fix | Delete
[22114] Fix | Delete
[22115] Fix | Delete
[22116] Fix | Delete
const animations = {
[22117] Fix | Delete
animation: {
[22118] Fix | Delete
Feature: AnimationFeature,
[22119] Fix | Delete
},
[22120] Fix | Delete
exit: {
[22121] Fix | Delete
Feature: ExitAnimationFeature,
[22122] Fix | Delete
},
[22123] Fix | Delete
};
[22124] Fix | Delete
[22125] Fix | Delete
[22126] Fix | Delete
[22127] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/utils/distance.mjs
[22128] Fix | Delete
const distance = (a, b) => Math.abs(a - b);
[22129] Fix | Delete
function distance2D(a, b) {
[22130] Fix | Delete
// Multi-dimensional
[22131] Fix | Delete
const xDelta = distance(a.x, b.x);
[22132] Fix | Delete
const yDelta = distance(a.y, b.y);
[22133] Fix | Delete
return Math.sqrt(xDelta ** 2 + yDelta ** 2);
[22134] Fix | Delete
}
[22135] Fix | Delete
[22136] Fix | Delete
[22137] Fix | Delete
[22138] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/gestures/pan/PanSession.mjs
[22139] Fix | Delete
[22140] Fix | Delete
[22141] Fix | Delete
[22142] Fix | Delete
[22143] Fix | Delete
[22144] Fix | Delete
[22145] Fix | Delete
[22146] Fix | Delete
[22147] Fix | Delete
/**
[22148] Fix | Delete
* @internal
[22149] Fix | Delete
*/
[22150] Fix | Delete
class PanSession {
[22151] Fix | Delete
constructor(event, handlers, { transformPagePoint, contextWindow, dragSnapToOrigin = false } = {}) {
[22152] Fix | Delete
/**
[22153] Fix | Delete
* @internal
[22154] Fix | Delete
*/
[22155] Fix | Delete
this.startEvent = null;
[22156] Fix | Delete
/**
[22157] Fix | Delete
* @internal
[22158] Fix | Delete
*/
[22159] Fix | Delete
this.lastMoveEvent = null;
[22160] Fix | Delete
/**
[22161] Fix | Delete
* @internal
[22162] Fix | Delete
*/
[22163] Fix | Delete
this.lastMoveEventInfo = null;
[22164] Fix | Delete
/**
[22165] Fix | Delete
* @internal
[22166] Fix | Delete
*/
[22167] Fix | Delete
this.handlers = {};
[22168] Fix | Delete
/**
[22169] Fix | Delete
* @internal
[22170] Fix | Delete
*/
[22171] Fix | Delete
this.contextWindow = window;
[22172] Fix | Delete
this.updatePoint = () => {
[22173] Fix | Delete
if (!(this.lastMoveEvent && this.lastMoveEventInfo))
[22174] Fix | Delete
return;
[22175] Fix | Delete
const info = getPanInfo(this.lastMoveEventInfo, this.history);
[22176] Fix | Delete
const isPanStarted = this.startEvent !== null;
[22177] Fix | Delete
// Only start panning if the offset is larger than 3 pixels. If we make it
[22178] Fix | Delete
// any larger than this we'll want to reset the pointer history
[22179] Fix | Delete
// on the first update to avoid visual snapping to the cursoe.
[22180] Fix | Delete
const isDistancePastThreshold = distance2D(info.offset, { x: 0, y: 0 }) >= 3;
[22181] Fix | Delete
if (!isPanStarted && !isDistancePastThreshold)
[22182] Fix | Delete
return;
[22183] Fix | Delete
const { point } = info;
[22184] Fix | Delete
const { timestamp } = frameData;
[22185] Fix | Delete
this.history.push({ ...point, timestamp });
[22186] Fix | Delete
const { onStart, onMove } = this.handlers;
[22187] Fix | Delete
if (!isPanStarted) {
[22188] Fix | Delete
onStart && onStart(this.lastMoveEvent, info);
[22189] Fix | Delete
this.startEvent = this.lastMoveEvent;
[22190] Fix | Delete
}
[22191] Fix | Delete
onMove && onMove(this.lastMoveEvent, info);
[22192] Fix | Delete
};
[22193] Fix | Delete
this.handlePointerMove = (event, info) => {
[22194] Fix | Delete
this.lastMoveEvent = event;
[22195] Fix | Delete
this.lastMoveEventInfo = transformPoint(info, this.transformPagePoint);
[22196] Fix | Delete
// Throttle mouse move event to once per frame
[22197] Fix | Delete
frame_frame.update(this.updatePoint, true);
[22198] Fix | Delete
};
[22199] Fix | Delete
this.handlePointerUp = (event, info) => {
[22200] Fix | Delete
this.end();
[22201] Fix | Delete
const { onEnd, onSessionEnd, resumeAnimation } = this.handlers;
[22202] Fix | Delete
if (this.dragSnapToOrigin)
[22203] Fix | Delete
resumeAnimation && resumeAnimation();
[22204] Fix | Delete
if (!(this.lastMoveEvent && this.lastMoveEventInfo))
[22205] Fix | Delete
return;
[22206] Fix | Delete
const panInfo = getPanInfo(event.type === "pointercancel"
[22207] Fix | Delete
? this.lastMoveEventInfo
[22208] Fix | Delete
: transformPoint(info, this.transformPagePoint), this.history);
[22209] Fix | Delete
if (this.startEvent && onEnd) {
[22210] Fix | Delete
onEnd(event, panInfo);
[22211] Fix | Delete
}
[22212] Fix | Delete
onSessionEnd && onSessionEnd(event, panInfo);
[22213] Fix | Delete
};
[22214] Fix | Delete
// If we have more than one touch, don't start detecting this gesture
[22215] Fix | Delete
if (!isPrimaryPointer(event))
[22216] Fix | Delete
return;
[22217] Fix | Delete
this.dragSnapToOrigin = dragSnapToOrigin;
[22218] Fix | Delete
this.handlers = handlers;
[22219] Fix | Delete
this.transformPagePoint = transformPagePoint;
[22220] Fix | Delete
this.contextWindow = contextWindow || window;
[22221] Fix | Delete
const info = extractEventInfo(event);
[22222] Fix | Delete
const initialInfo = transformPoint(info, this.transformPagePoint);
[22223] Fix | Delete
const { point } = initialInfo;
[22224] Fix | Delete
const { timestamp } = frameData;
[22225] Fix | Delete
this.history = [{ ...point, timestamp }];
[22226] Fix | Delete
const { onSessionStart } = handlers;
[22227] Fix | Delete
onSessionStart &&
[22228] Fix | Delete
onSessionStart(event, getPanInfo(initialInfo, this.history));
[22229] Fix | Delete
this.removeListeners = pipe(addPointerEvent(this.contextWindow, "pointermove", this.handlePointerMove), addPointerEvent(this.contextWindow, "pointerup", this.handlePointerUp), addPointerEvent(this.contextWindow, "pointercancel", this.handlePointerUp));
[22230] Fix | Delete
}
[22231] Fix | Delete
updateHandlers(handlers) {
[22232] Fix | Delete
this.handlers = handlers;
[22233] Fix | Delete
}
[22234] Fix | Delete
end() {
[22235] Fix | Delete
this.removeListeners && this.removeListeners();
[22236] Fix | Delete
cancelFrame(this.updatePoint);
[22237] Fix | Delete
}
[22238] Fix | Delete
}
[22239] Fix | Delete
function transformPoint(info, transformPagePoint) {
[22240] Fix | Delete
return transformPagePoint ? { point: transformPagePoint(info.point) } : info;
[22241] Fix | Delete
}
[22242] Fix | Delete
function subtractPoint(a, b) {
[22243] Fix | Delete
return { x: a.x - b.x, y: a.y - b.y };
[22244] Fix | Delete
}
[22245] Fix | Delete
function getPanInfo({ point }, history) {
[22246] Fix | Delete
return {
[22247] Fix | Delete
point,
[22248] Fix | Delete
delta: subtractPoint(point, lastDevicePoint(history)),
[22249] Fix | Delete
offset: subtractPoint(point, startDevicePoint(history)),
[22250] Fix | Delete
velocity: getVelocity(history, 0.1),
[22251] Fix | Delete
};
[22252] Fix | Delete
}
[22253] Fix | Delete
function startDevicePoint(history) {
[22254] Fix | Delete
return history[0];
[22255] Fix | Delete
}
[22256] Fix | Delete
function lastDevicePoint(history) {
[22257] Fix | Delete
return history[history.length - 1];
[22258] Fix | Delete
}
[22259] Fix | Delete
function getVelocity(history, timeDelta) {
[22260] Fix | Delete
if (history.length < 2) {
[22261] Fix | Delete
return { x: 0, y: 0 };
[22262] Fix | Delete
}
[22263] Fix | Delete
let i = history.length - 1;
[22264] Fix | Delete
let timestampedPoint = null;
[22265] Fix | Delete
const lastPoint = lastDevicePoint(history);
[22266] Fix | Delete
while (i >= 0) {
[22267] Fix | Delete
timestampedPoint = history[i];
[22268] Fix | Delete
if (lastPoint.timestamp - timestampedPoint.timestamp >
[22269] Fix | Delete
secondsToMilliseconds(timeDelta)) {
[22270] Fix | Delete
break;
[22271] Fix | Delete
}
[22272] Fix | Delete
i--;
[22273] Fix | Delete
}
[22274] Fix | Delete
if (!timestampedPoint) {
[22275] Fix | Delete
return { x: 0, y: 0 };
[22276] Fix | Delete
}
[22277] Fix | Delete
const time = millisecondsToSeconds(lastPoint.timestamp - timestampedPoint.timestamp);
[22278] Fix | Delete
if (time === 0) {
[22279] Fix | Delete
return { x: 0, y: 0 };
[22280] Fix | Delete
}
[22281] Fix | Delete
const currentVelocity = {
[22282] Fix | Delete
x: (lastPoint.x - timestampedPoint.x) / time,
[22283] Fix | Delete
y: (lastPoint.y - timestampedPoint.y) / time,
[22284] Fix | Delete
};
[22285] Fix | Delete
if (currentVelocity.x === Infinity) {
[22286] Fix | Delete
currentVelocity.x = 0;
[22287] Fix | Delete
}
[22288] Fix | Delete
if (currentVelocity.y === Infinity) {
[22289] Fix | Delete
currentVelocity.y = 0;
[22290] Fix | Delete
}
[22291] Fix | Delete
return currentVelocity;
[22292] Fix | Delete
}
[22293] Fix | Delete
[22294] Fix | Delete
[22295] Fix | Delete
[22296] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/projection/geometry/delta-calc.mjs
[22297] Fix | Delete
[22298] Fix | Delete
[22299] Fix | Delete
function calcLength(axis) {
[22300] Fix | Delete
return axis.max - axis.min;
[22301] Fix | Delete
}
[22302] Fix | Delete
function isNear(value, target = 0, maxDistance = 0.01) {
[22303] Fix | Delete
return Math.abs(value - target) <= maxDistance;
[22304] Fix | Delete
}
[22305] Fix | Delete
function calcAxisDelta(delta, source, target, origin = 0.5) {
[22306] Fix | Delete
delta.origin = origin;
[22307] Fix | Delete
delta.originPoint = mixNumber(source.min, source.max, delta.origin);
[22308] Fix | Delete
delta.scale = calcLength(target) / calcLength(source);
[22309] Fix | Delete
if (isNear(delta.scale, 1, 0.0001) || isNaN(delta.scale))
[22310] Fix | Delete
delta.scale = 1;
[22311] Fix | Delete
delta.translate =
[22312] Fix | Delete
mixNumber(target.min, target.max, delta.origin) - delta.originPoint;
[22313] Fix | Delete
if (isNear(delta.translate) || isNaN(delta.translate))
[22314] Fix | Delete
delta.translate = 0;
[22315] Fix | Delete
}
[22316] Fix | Delete
function calcBoxDelta(delta, source, target, origin) {
[22317] Fix | Delete
calcAxisDelta(delta.x, source.x, target.x, origin ? origin.originX : undefined);
[22318] Fix | Delete
calcAxisDelta(delta.y, source.y, target.y, origin ? origin.originY : undefined);
[22319] Fix | Delete
}
[22320] Fix | Delete
function calcRelativeAxis(target, relative, parent) {
[22321] Fix | Delete
target.min = parent.min + relative.min;
[22322] Fix | Delete
target.max = target.min + calcLength(relative);
[22323] Fix | Delete
}
[22324] Fix | Delete
function calcRelativeBox(target, relative, parent) {
[22325] Fix | Delete
calcRelativeAxis(target.x, relative.x, parent.x);
[22326] Fix | Delete
calcRelativeAxis(target.y, relative.y, parent.y);
[22327] Fix | Delete
}
[22328] Fix | Delete
function calcRelativeAxisPosition(target, layout, parent) {
[22329] Fix | Delete
target.min = layout.min - parent.min;
[22330] Fix | Delete
target.max = target.min + calcLength(layout);
[22331] Fix | Delete
}
[22332] Fix | Delete
function calcRelativePosition(target, layout, parent) {
[22333] Fix | Delete
calcRelativeAxisPosition(target.x, layout.x, parent.x);
[22334] Fix | Delete
calcRelativeAxisPosition(target.y, layout.y, parent.y);
[22335] Fix | Delete
}
[22336] Fix | Delete
[22337] Fix | Delete
[22338] Fix | Delete
[22339] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/gestures/drag/utils/constraints.mjs
[22340] Fix | Delete
[22341] Fix | Delete
[22342] Fix | Delete
[22343] Fix | Delete
[22344] Fix | Delete
[22345] Fix | Delete
/**
[22346] Fix | Delete
* Apply constraints to a point. These constraints are both physical along an
[22347] Fix | Delete
* axis, and an elastic factor that determines how much to constrain the point
[22348] Fix | Delete
* by if it does lie outside the defined parameters.
[22349] Fix | Delete
*/
[22350] Fix | Delete
function applyConstraints(point, { min, max }, elastic) {
[22351] Fix | Delete
if (min !== undefined && point < min) {
[22352] Fix | Delete
// If we have a min point defined, and this is outside of that, constrain
[22353] Fix | Delete
point = elastic
[22354] Fix | Delete
? mixNumber(min, point, elastic.min)
[22355] Fix | Delete
: Math.max(point, min);
[22356] Fix | Delete
}
[22357] Fix | Delete
else if (max !== undefined && point > max) {
[22358] Fix | Delete
// If we have a max point defined, and this is outside of that, constrain
[22359] Fix | Delete
point = elastic
[22360] Fix | Delete
? mixNumber(max, point, elastic.max)
[22361] Fix | Delete
: Math.min(point, max);
[22362] Fix | Delete
}
[22363] Fix | Delete
return point;
[22364] Fix | Delete
}
[22365] Fix | Delete
/**
[22366] Fix | Delete
* Calculate constraints in terms of the viewport when defined relatively to the
[22367] Fix | Delete
* measured axis. This is measured from the nearest edge, so a max constraint of 200
[22368] Fix | Delete
* on an axis with a max value of 300 would return a constraint of 500 - axis length
[22369] Fix | Delete
*/
[22370] Fix | Delete
function calcRelativeAxisConstraints(axis, min, max) {
[22371] Fix | Delete
return {
[22372] Fix | Delete
min: min !== undefined ? axis.min + min : undefined,
[22373] Fix | Delete
max: max !== undefined
[22374] Fix | Delete
? axis.max + max - (axis.max - axis.min)
[22375] Fix | Delete
: undefined,
[22376] Fix | Delete
};
[22377] Fix | Delete
}
[22378] Fix | Delete
/**
[22379] Fix | Delete
* Calculate constraints in terms of the viewport when
[22380] Fix | Delete
* defined relatively to the measured bounding box.
[22381] Fix | Delete
*/
[22382] Fix | Delete
function calcRelativeConstraints(layoutBox, { top, left, bottom, right }) {
[22383] Fix | Delete
return {
[22384] Fix | Delete
x: calcRelativeAxisConstraints(layoutBox.x, left, right),
[22385] Fix | Delete
y: calcRelativeAxisConstraints(layoutBox.y, top, bottom),
[22386] Fix | Delete
};
[22387] Fix | Delete
}
[22388] Fix | Delete
/**
[22389] Fix | Delete
* Calculate viewport constraints when defined as another viewport-relative axis
[22390] Fix | Delete
*/
[22391] Fix | Delete
function calcViewportAxisConstraints(layoutAxis, constraintsAxis) {
[22392] Fix | Delete
let min = constraintsAxis.min - layoutAxis.min;
[22393] Fix | Delete
let max = constraintsAxis.max - layoutAxis.max;
[22394] Fix | Delete
// If the constraints axis is actually smaller than the layout axis then we can
[22395] Fix | Delete
// flip the constraints
[22396] Fix | Delete
if (constraintsAxis.max - constraintsAxis.min <
[22397] Fix | Delete
layoutAxis.max - layoutAxis.min) {
[22398] Fix | Delete
[min, max] = [max, min];
[22399] Fix | Delete
}
[22400] Fix | Delete
return { min, max };
[22401] Fix | Delete
}
[22402] Fix | Delete
/**
[22403] Fix | Delete
* Calculate viewport constraints when defined as another viewport-relative box
[22404] Fix | Delete
*/
[22405] Fix | Delete
function calcViewportConstraints(layoutBox, constraintsBox) {
[22406] Fix | Delete
return {
[22407] Fix | Delete
x: calcViewportAxisConstraints(layoutBox.x, constraintsBox.x),
[22408] Fix | Delete
y: calcViewportAxisConstraints(layoutBox.y, constraintsBox.y),
[22409] Fix | Delete
};
[22410] Fix | Delete
}
[22411] Fix | Delete
/**
[22412] Fix | Delete
* Calculate a transform origin relative to the source axis, between 0-1, that results
[22413] Fix | Delete
* in an asthetically pleasing scale/transform needed to project from source to target.
[22414] Fix | Delete
*/
[22415] Fix | Delete
function constraints_calcOrigin(source, target) {
[22416] Fix | Delete
let origin = 0.5;
[22417] Fix | Delete
const sourceLength = calcLength(source);
[22418] Fix | Delete
const targetLength = calcLength(target);
[22419] Fix | Delete
if (targetLength > sourceLength) {
[22420] Fix | Delete
origin = progress(target.min, target.max - sourceLength, source.min);
[22421] Fix | Delete
}
[22422] Fix | Delete
else if (sourceLength > targetLength) {
[22423] Fix | Delete
origin = progress(source.min, source.max - targetLength, target.min);
[22424] Fix | Delete
}
[22425] Fix | Delete
return clamp_clamp(0, 1, origin);
[22426] Fix | Delete
}
[22427] Fix | Delete
/**
[22428] Fix | Delete
* Rebase the calculated viewport constraints relative to the layout.min point.
[22429] Fix | Delete
*/
[22430] Fix | Delete
function rebaseAxisConstraints(layout, constraints) {
[22431] Fix | Delete
const relativeConstraints = {};
[22432] Fix | Delete
if (constraints.min !== undefined) {
[22433] Fix | Delete
relativeConstraints.min = constraints.min - layout.min;
[22434] Fix | Delete
}
[22435] Fix | Delete
if (constraints.max !== undefined) {
[22436] Fix | Delete
relativeConstraints.max = constraints.max - layout.min;
[22437] Fix | Delete
}
[22438] Fix | Delete
return relativeConstraints;
[22439] Fix | Delete
}
[22440] Fix | Delete
const defaultElastic = 0.35;
[22441] Fix | Delete
/**
[22442] Fix | Delete
* Accepts a dragElastic prop and returns resolved elastic values for each axis.
[22443] Fix | Delete
*/
[22444] Fix | Delete
function resolveDragElastic(dragElastic = defaultElastic) {
[22445] Fix | Delete
if (dragElastic === false) {
[22446] Fix | Delete
dragElastic = 0;
[22447] Fix | Delete
}
[22448] Fix | Delete
else if (dragElastic === true) {
[22449] Fix | Delete
dragElastic = defaultElastic;
[22450] Fix | Delete
}
[22451] Fix | Delete
return {
[22452] Fix | Delete
x: resolveAxisElastic(dragElastic, "left", "right"),
[22453] Fix | Delete
y: resolveAxisElastic(dragElastic, "top", "bottom"),
[22454] Fix | Delete
};
[22455] Fix | Delete
}
[22456] Fix | Delete
function resolveAxisElastic(dragElastic, minLabel, maxLabel) {
[22457] Fix | Delete
return {
[22458] Fix | Delete
min: resolvePointElastic(dragElastic, minLabel),
[22459] Fix | Delete
max: resolvePointElastic(dragElastic, maxLabel),
[22460] Fix | Delete
};
[22461] Fix | Delete
}
[22462] Fix | Delete
function resolvePointElastic(dragElastic, label) {
[22463] Fix | Delete
return typeof dragElastic === "number"
[22464] Fix | Delete
? dragElastic
[22465] Fix | Delete
: dragElastic[label] || 0;
[22466] Fix | Delete
}
[22467] Fix | Delete
[22468] Fix | Delete
[22469] Fix | Delete
[22470] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/projection/geometry/models.mjs
[22471] Fix | Delete
const createAxisDelta = () => ({
[22472] Fix | Delete
translate: 0,
[22473] Fix | Delete
scale: 1,
[22474] Fix | Delete
origin: 0,
[22475] Fix | Delete
originPoint: 0,
[22476] Fix | Delete
});
[22477] Fix | Delete
const createDelta = () => ({
[22478] Fix | Delete
x: createAxisDelta(),
[22479] Fix | Delete
y: createAxisDelta(),
[22480] Fix | Delete
});
[22481] Fix | Delete
const createAxis = () => ({ min: 0, max: 0 });
[22482] Fix | Delete
const createBox = () => ({
[22483] Fix | Delete
x: createAxis(),
[22484] Fix | Delete
y: createAxis(),
[22485] Fix | Delete
});
[22486] Fix | Delete
[22487] Fix | Delete
[22488] Fix | Delete
[22489] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/projection/utils/each-axis.mjs
[22490] Fix | Delete
function eachAxis(callback) {
[22491] Fix | Delete
return [callback("x"), callback("y")];
[22492] Fix | Delete
}
[22493] Fix | Delete
[22494] Fix | Delete
[22495] Fix | Delete
[22496] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/framer-motion/dist/es/projection/geometry/conversion.mjs
[22497] Fix | Delete
/**
[22498] Fix | Delete
* Bounding boxes tend to be defined as top, left, right, bottom. For various operations
[22499] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function