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
get eventStore() {
[29000] Fix | Delete
return this.ctrl.gestureEventStores[this.key];
[29001] Fix | Delete
}
[29002] Fix | Delete
get timeoutStore() {
[29003] Fix | Delete
return this.ctrl.gestureTimeoutStores[this.key];
[29004] Fix | Delete
}
[29005] Fix | Delete
get config() {
[29006] Fix | Delete
return this.ctrl.config[this.key];
[29007] Fix | Delete
}
[29008] Fix | Delete
get sharedConfig() {
[29009] Fix | Delete
return this.ctrl.config.shared;
[29010] Fix | Delete
}
[29011] Fix | Delete
get handler() {
[29012] Fix | Delete
return this.ctrl.handlers[this.key];
[29013] Fix | Delete
}
[29014] Fix | Delete
reset() {
[29015] Fix | Delete
const {
[29016] Fix | Delete
state,
[29017] Fix | Delete
shared,
[29018] Fix | Delete
ingKey,
[29019] Fix | Delete
args
[29020] Fix | Delete
} = this;
[29021] Fix | Delete
shared[ingKey] = state._active = state.active = state._blocked = state._force = false;
[29022] Fix | Delete
state._step = [false, false];
[29023] Fix | Delete
state.intentional = false;
[29024] Fix | Delete
state._movement = [0, 0];
[29025] Fix | Delete
state._distance = [0, 0];
[29026] Fix | Delete
state._direction = [0, 0];
[29027] Fix | Delete
state._delta = [0, 0];
[29028] Fix | Delete
state._bounds = [[-Infinity, Infinity], [-Infinity, Infinity]];
[29029] Fix | Delete
state.args = args;
[29030] Fix | Delete
state.axis = undefined;
[29031] Fix | Delete
state.memo = undefined;
[29032] Fix | Delete
state.elapsedTime = state.timeDelta = 0;
[29033] Fix | Delete
state.direction = [0, 0];
[29034] Fix | Delete
state.distance = [0, 0];
[29035] Fix | Delete
state.overflow = [0, 0];
[29036] Fix | Delete
state._movementBound = [false, false];
[29037] Fix | Delete
state.velocity = [0, 0];
[29038] Fix | Delete
state.movement = [0, 0];
[29039] Fix | Delete
state.delta = [0, 0];
[29040] Fix | Delete
state.timeStamp = 0;
[29041] Fix | Delete
}
[29042] Fix | Delete
start(event) {
[29043] Fix | Delete
const state = this.state;
[29044] Fix | Delete
const config = this.config;
[29045] Fix | Delete
if (!state._active) {
[29046] Fix | Delete
this.reset();
[29047] Fix | Delete
this.computeInitial();
[29048] Fix | Delete
state._active = true;
[29049] Fix | Delete
state.target = event.target;
[29050] Fix | Delete
state.currentTarget = event.currentTarget;
[29051] Fix | Delete
state.lastOffset = config.from ? call(config.from, state) : state.offset;
[29052] Fix | Delete
state.offset = state.lastOffset;
[29053] Fix | Delete
state.startTime = state.timeStamp = event.timeStamp;
[29054] Fix | Delete
}
[29055] Fix | Delete
}
[29056] Fix | Delete
computeValues(values) {
[29057] Fix | Delete
const state = this.state;
[29058] Fix | Delete
state._values = values;
[29059] Fix | Delete
state.values = this.config.transform(values);
[29060] Fix | Delete
}
[29061] Fix | Delete
computeInitial() {
[29062] Fix | Delete
const state = this.state;
[29063] Fix | Delete
state._initial = state._values;
[29064] Fix | Delete
state.initial = state.values;
[29065] Fix | Delete
}
[29066] Fix | Delete
compute(event) {
[29067] Fix | Delete
const {
[29068] Fix | Delete
state,
[29069] Fix | Delete
config,
[29070] Fix | Delete
shared
[29071] Fix | Delete
} = this;
[29072] Fix | Delete
state.args = this.args;
[29073] Fix | Delete
let dt = 0;
[29074] Fix | Delete
if (event) {
[29075] Fix | Delete
state.event = event;
[29076] Fix | Delete
if (config.preventDefault && event.cancelable) state.event.preventDefault();
[29077] Fix | Delete
state.type = event.type;
[29078] Fix | Delete
shared.touches = this.ctrl.pointerIds.size || this.ctrl.touchIds.size;
[29079] Fix | Delete
shared.locked = !!document.pointerLockElement;
[29080] Fix | Delete
Object.assign(shared, getEventDetails(event));
[29081] Fix | Delete
shared.down = shared.pressed = shared.buttons % 2 === 1 || shared.touches > 0;
[29082] Fix | Delete
dt = event.timeStamp - state.timeStamp;
[29083] Fix | Delete
state.timeStamp = event.timeStamp;
[29084] Fix | Delete
state.elapsedTime = state.timeStamp - state.startTime;
[29085] Fix | Delete
}
[29086] Fix | Delete
if (state._active) {
[29087] Fix | Delete
const _absoluteDelta = state._delta.map(Math.abs);
[29088] Fix | Delete
V.addTo(state._distance, _absoluteDelta);
[29089] Fix | Delete
}
[29090] Fix | Delete
if (this.axisIntent) this.axisIntent(event);
[29091] Fix | Delete
const [_m0, _m1] = state._movement;
[29092] Fix | Delete
const [t0, t1] = config.threshold;
[29093] Fix | Delete
const {
[29094] Fix | Delete
_step,
[29095] Fix | Delete
values
[29096] Fix | Delete
} = state;
[29097] Fix | Delete
if (config.hasCustomTransform) {
[29098] Fix | Delete
if (_step[0] === false) _step[0] = Math.abs(_m0) >= t0 && values[0];
[29099] Fix | Delete
if (_step[1] === false) _step[1] = Math.abs(_m1) >= t1 && values[1];
[29100] Fix | Delete
} else {
[29101] Fix | Delete
if (_step[0] === false) _step[0] = Math.abs(_m0) >= t0 && Math.sign(_m0) * t0;
[29102] Fix | Delete
if (_step[1] === false) _step[1] = Math.abs(_m1) >= t1 && Math.sign(_m1) * t1;
[29103] Fix | Delete
}
[29104] Fix | Delete
state.intentional = _step[0] !== false || _step[1] !== false;
[29105] Fix | Delete
if (!state.intentional) return;
[29106] Fix | Delete
const movement = [0, 0];
[29107] Fix | Delete
if (config.hasCustomTransform) {
[29108] Fix | Delete
const [v0, v1] = values;
[29109] Fix | Delete
movement[0] = _step[0] !== false ? v0 - _step[0] : 0;
[29110] Fix | Delete
movement[1] = _step[1] !== false ? v1 - _step[1] : 0;
[29111] Fix | Delete
} else {
[29112] Fix | Delete
movement[0] = _step[0] !== false ? _m0 - _step[0] : 0;
[29113] Fix | Delete
movement[1] = _step[1] !== false ? _m1 - _step[1] : 0;
[29114] Fix | Delete
}
[29115] Fix | Delete
if (this.restrictToAxis && !state._blocked) this.restrictToAxis(movement);
[29116] Fix | Delete
const previousOffset = state.offset;
[29117] Fix | Delete
const gestureIsActive = state._active && !state._blocked || state.active;
[29118] Fix | Delete
if (gestureIsActive) {
[29119] Fix | Delete
state.first = state._active && !state.active;
[29120] Fix | Delete
state.last = !state._active && state.active;
[29121] Fix | Delete
state.active = shared[this.ingKey] = state._active;
[29122] Fix | Delete
if (event) {
[29123] Fix | Delete
if (state.first) {
[29124] Fix | Delete
if ('bounds' in config) state._bounds = call(config.bounds, state);
[29125] Fix | Delete
if (this.setup) this.setup();
[29126] Fix | Delete
}
[29127] Fix | Delete
state.movement = movement;
[29128] Fix | Delete
this.computeOffset();
[29129] Fix | Delete
}
[29130] Fix | Delete
}
[29131] Fix | Delete
const [ox, oy] = state.offset;
[29132] Fix | Delete
const [[x0, x1], [y0, y1]] = state._bounds;
[29133] Fix | Delete
state.overflow = [ox < x0 ? -1 : ox > x1 ? 1 : 0, oy < y0 ? -1 : oy > y1 ? 1 : 0];
[29134] Fix | Delete
state._movementBound[0] = state.overflow[0] ? state._movementBound[0] === false ? state._movement[0] : state._movementBound[0] : false;
[29135] Fix | Delete
state._movementBound[1] = state.overflow[1] ? state._movementBound[1] === false ? state._movement[1] : state._movementBound[1] : false;
[29136] Fix | Delete
const rubberband = state._active ? config.rubberband || [0, 0] : [0, 0];
[29137] Fix | Delete
state.offset = computeRubberband(state._bounds, state.offset, rubberband);
[29138] Fix | Delete
state.delta = V.sub(state.offset, previousOffset);
[29139] Fix | Delete
this.computeMovement();
[29140] Fix | Delete
if (gestureIsActive && (!state.last || dt > BEFORE_LAST_KINEMATICS_DELAY)) {
[29141] Fix | Delete
state.delta = V.sub(state.offset, previousOffset);
[29142] Fix | Delete
const absoluteDelta = state.delta.map(Math.abs);
[29143] Fix | Delete
V.addTo(state.distance, absoluteDelta);
[29144] Fix | Delete
state.direction = state.delta.map(Math.sign);
[29145] Fix | Delete
state._direction = state._delta.map(Math.sign);
[29146] Fix | Delete
if (!state.first && dt > 0) {
[29147] Fix | Delete
state.velocity = [absoluteDelta[0] / dt, absoluteDelta[1] / dt];
[29148] Fix | Delete
state.timeDelta = dt;
[29149] Fix | Delete
}
[29150] Fix | Delete
}
[29151] Fix | Delete
}
[29152] Fix | Delete
emit() {
[29153] Fix | Delete
const state = this.state;
[29154] Fix | Delete
const shared = this.shared;
[29155] Fix | Delete
const config = this.config;
[29156] Fix | Delete
if (!state._active) this.clean();
[29157] Fix | Delete
if ((state._blocked || !state.intentional) && !state._force && !config.triggerAllEvents) return;
[29158] Fix | Delete
const memo = this.handler(_objectSpread2(_objectSpread2(_objectSpread2({}, shared), state), {}, {
[29159] Fix | Delete
[this.aliasKey]: state.values
[29160] Fix | Delete
}));
[29161] Fix | Delete
if (memo !== undefined) state.memo = memo;
[29162] Fix | Delete
}
[29163] Fix | Delete
clean() {
[29164] Fix | Delete
this.eventStore.clean();
[29165] Fix | Delete
this.timeoutStore.clean();
[29166] Fix | Delete
}
[29167] Fix | Delete
}
[29168] Fix | Delete
[29169] Fix | Delete
function selectAxis([dx, dy], threshold) {
[29170] Fix | Delete
const absDx = Math.abs(dx);
[29171] Fix | Delete
const absDy = Math.abs(dy);
[29172] Fix | Delete
if (absDx > absDy && absDx > threshold) {
[29173] Fix | Delete
return 'x';
[29174] Fix | Delete
}
[29175] Fix | Delete
if (absDy > absDx && absDy > threshold) {
[29176] Fix | Delete
return 'y';
[29177] Fix | Delete
}
[29178] Fix | Delete
return undefined;
[29179] Fix | Delete
}
[29180] Fix | Delete
class CoordinatesEngine extends Engine {
[29181] Fix | Delete
constructor(...args) {
[29182] Fix | Delete
super(...args);
[29183] Fix | Delete
_defineProperty(this, "aliasKey", 'xy');
[29184] Fix | Delete
}
[29185] Fix | Delete
reset() {
[29186] Fix | Delete
super.reset();
[29187] Fix | Delete
this.state.axis = undefined;
[29188] Fix | Delete
}
[29189] Fix | Delete
init() {
[29190] Fix | Delete
this.state.offset = [0, 0];
[29191] Fix | Delete
this.state.lastOffset = [0, 0];
[29192] Fix | Delete
}
[29193] Fix | Delete
computeOffset() {
[29194] Fix | Delete
this.state.offset = V.add(this.state.lastOffset, this.state.movement);
[29195] Fix | Delete
}
[29196] Fix | Delete
computeMovement() {
[29197] Fix | Delete
this.state.movement = V.sub(this.state.offset, this.state.lastOffset);
[29198] Fix | Delete
}
[29199] Fix | Delete
axisIntent(event) {
[29200] Fix | Delete
const state = this.state;
[29201] Fix | Delete
const config = this.config;
[29202] Fix | Delete
if (!state.axis && event) {
[29203] Fix | Delete
const threshold = typeof config.axisThreshold === 'object' ? config.axisThreshold[getPointerType(event)] : config.axisThreshold;
[29204] Fix | Delete
state.axis = selectAxis(state._movement, threshold);
[29205] Fix | Delete
}
[29206] Fix | Delete
state._blocked = (config.lockDirection || !!config.axis) && !state.axis || !!config.axis && config.axis !== state.axis;
[29207] Fix | Delete
}
[29208] Fix | Delete
restrictToAxis(v) {
[29209] Fix | Delete
if (this.config.axis || this.config.lockDirection) {
[29210] Fix | Delete
switch (this.state.axis) {
[29211] Fix | Delete
case 'x':
[29212] Fix | Delete
v[1] = 0;
[29213] Fix | Delete
break;
[29214] Fix | Delete
case 'y':
[29215] Fix | Delete
v[0] = 0;
[29216] Fix | Delete
break;
[29217] Fix | Delete
}
[29218] Fix | Delete
}
[29219] Fix | Delete
}
[29220] Fix | Delete
}
[29221] Fix | Delete
[29222] Fix | Delete
const actions_fe213e88_esm_identity = v => v;
[29223] Fix | Delete
const DEFAULT_RUBBERBAND = 0.15;
[29224] Fix | Delete
const commonConfigResolver = {
[29225] Fix | Delete
enabled(value = true) {
[29226] Fix | Delete
return value;
[29227] Fix | Delete
},
[29228] Fix | Delete
eventOptions(value, _k, config) {
[29229] Fix | Delete
return _objectSpread2(_objectSpread2({}, config.shared.eventOptions), value);
[29230] Fix | Delete
},
[29231] Fix | Delete
preventDefault(value = false) {
[29232] Fix | Delete
return value;
[29233] Fix | Delete
},
[29234] Fix | Delete
triggerAllEvents(value = false) {
[29235] Fix | Delete
return value;
[29236] Fix | Delete
},
[29237] Fix | Delete
rubberband(value = 0) {
[29238] Fix | Delete
switch (value) {
[29239] Fix | Delete
case true:
[29240] Fix | Delete
return [DEFAULT_RUBBERBAND, DEFAULT_RUBBERBAND];
[29241] Fix | Delete
case false:
[29242] Fix | Delete
return [0, 0];
[29243] Fix | Delete
default:
[29244] Fix | Delete
return V.toVector(value);
[29245] Fix | Delete
}
[29246] Fix | Delete
},
[29247] Fix | Delete
from(value) {
[29248] Fix | Delete
if (typeof value === 'function') return value;
[29249] Fix | Delete
if (value != null) return V.toVector(value);
[29250] Fix | Delete
},
[29251] Fix | Delete
transform(value, _k, config) {
[29252] Fix | Delete
const transform = value || config.shared.transform;
[29253] Fix | Delete
this.hasCustomTransform = !!transform;
[29254] Fix | Delete
if (false) {}
[29255] Fix | Delete
return transform || actions_fe213e88_esm_identity;
[29256] Fix | Delete
},
[29257] Fix | Delete
threshold(value) {
[29258] Fix | Delete
return V.toVector(value, 0);
[29259] Fix | Delete
}
[29260] Fix | Delete
};
[29261] Fix | Delete
if (false) {}
[29262] Fix | Delete
[29263] Fix | Delete
const DEFAULT_AXIS_THRESHOLD = 0;
[29264] Fix | Delete
const coordinatesConfigResolver = _objectSpread2(_objectSpread2({}, commonConfigResolver), {}, {
[29265] Fix | Delete
axis(_v, _k, {
[29266] Fix | Delete
axis
[29267] Fix | Delete
}) {
[29268] Fix | Delete
this.lockDirection = axis === 'lock';
[29269] Fix | Delete
if (!this.lockDirection) return axis;
[29270] Fix | Delete
},
[29271] Fix | Delete
axisThreshold(value = DEFAULT_AXIS_THRESHOLD) {
[29272] Fix | Delete
return value;
[29273] Fix | Delete
},
[29274] Fix | Delete
bounds(value = {}) {
[29275] Fix | Delete
if (typeof value === 'function') {
[29276] Fix | Delete
return state => coordinatesConfigResolver.bounds(value(state));
[29277] Fix | Delete
}
[29278] Fix | Delete
if ('current' in value) {
[29279] Fix | Delete
return () => value.current;
[29280] Fix | Delete
}
[29281] Fix | Delete
if (typeof HTMLElement === 'function' && value instanceof HTMLElement) {
[29282] Fix | Delete
return value;
[29283] Fix | Delete
}
[29284] Fix | Delete
const {
[29285] Fix | Delete
left = -Infinity,
[29286] Fix | Delete
right = Infinity,
[29287] Fix | Delete
top = -Infinity,
[29288] Fix | Delete
bottom = Infinity
[29289] Fix | Delete
} = value;
[29290] Fix | Delete
return [[left, right], [top, bottom]];
[29291] Fix | Delete
}
[29292] Fix | Delete
});
[29293] Fix | Delete
[29294] Fix | Delete
const KEYS_DELTA_MAP = {
[29295] Fix | Delete
ArrowRight: (displacement, factor = 1) => [displacement * factor, 0],
[29296] Fix | Delete
ArrowLeft: (displacement, factor = 1) => [-1 * displacement * factor, 0],
[29297] Fix | Delete
ArrowUp: (displacement, factor = 1) => [0, -1 * displacement * factor],
[29298] Fix | Delete
ArrowDown: (displacement, factor = 1) => [0, displacement * factor]
[29299] Fix | Delete
};
[29300] Fix | Delete
class DragEngine extends CoordinatesEngine {
[29301] Fix | Delete
constructor(...args) {
[29302] Fix | Delete
super(...args);
[29303] Fix | Delete
_defineProperty(this, "ingKey", 'dragging');
[29304] Fix | Delete
}
[29305] Fix | Delete
reset() {
[29306] Fix | Delete
super.reset();
[29307] Fix | Delete
const state = this.state;
[29308] Fix | Delete
state._pointerId = undefined;
[29309] Fix | Delete
state._pointerActive = false;
[29310] Fix | Delete
state._keyboardActive = false;
[29311] Fix | Delete
state._preventScroll = false;
[29312] Fix | Delete
state._delayed = false;
[29313] Fix | Delete
state.swipe = [0, 0];
[29314] Fix | Delete
state.tap = false;
[29315] Fix | Delete
state.canceled = false;
[29316] Fix | Delete
state.cancel = this.cancel.bind(this);
[29317] Fix | Delete
}
[29318] Fix | Delete
setup() {
[29319] Fix | Delete
const state = this.state;
[29320] Fix | Delete
if (state._bounds instanceof HTMLElement) {
[29321] Fix | Delete
const boundRect = state._bounds.getBoundingClientRect();
[29322] Fix | Delete
const targetRect = state.currentTarget.getBoundingClientRect();
[29323] Fix | Delete
const _bounds = {
[29324] Fix | Delete
left: boundRect.left - targetRect.left + state.offset[0],
[29325] Fix | Delete
right: boundRect.right - targetRect.right + state.offset[0],
[29326] Fix | Delete
top: boundRect.top - targetRect.top + state.offset[1],
[29327] Fix | Delete
bottom: boundRect.bottom - targetRect.bottom + state.offset[1]
[29328] Fix | Delete
};
[29329] Fix | Delete
state._bounds = coordinatesConfigResolver.bounds(_bounds);
[29330] Fix | Delete
}
[29331] Fix | Delete
}
[29332] Fix | Delete
cancel() {
[29333] Fix | Delete
const state = this.state;
[29334] Fix | Delete
if (state.canceled) return;
[29335] Fix | Delete
state.canceled = true;
[29336] Fix | Delete
state._active = false;
[29337] Fix | Delete
setTimeout(() => {
[29338] Fix | Delete
this.compute();
[29339] Fix | Delete
this.emit();
[29340] Fix | Delete
}, 0);
[29341] Fix | Delete
}
[29342] Fix | Delete
setActive() {
[29343] Fix | Delete
this.state._active = this.state._pointerActive || this.state._keyboardActive;
[29344] Fix | Delete
}
[29345] Fix | Delete
clean() {
[29346] Fix | Delete
this.pointerClean();
[29347] Fix | Delete
this.state._pointerActive = false;
[29348] Fix | Delete
this.state._keyboardActive = false;
[29349] Fix | Delete
super.clean();
[29350] Fix | Delete
}
[29351] Fix | Delete
pointerDown(event) {
[29352] Fix | Delete
const config = this.config;
[29353] Fix | Delete
const state = this.state;
[29354] Fix | Delete
if (event.buttons != null && (Array.isArray(config.pointerButtons) ? !config.pointerButtons.includes(event.buttons) : config.pointerButtons !== -1 && config.pointerButtons !== event.buttons)) return;
[29355] Fix | Delete
const ctrlIds = this.ctrl.setEventIds(event);
[29356] Fix | Delete
if (config.pointerCapture) {
[29357] Fix | Delete
event.target.setPointerCapture(event.pointerId);
[29358] Fix | Delete
}
[29359] Fix | Delete
if (ctrlIds && ctrlIds.size > 1 && state._pointerActive) return;
[29360] Fix | Delete
this.start(event);
[29361] Fix | Delete
this.setupPointer(event);
[29362] Fix | Delete
state._pointerId = pointerId(event);
[29363] Fix | Delete
state._pointerActive = true;
[29364] Fix | Delete
this.computeValues(pointerValues(event));
[29365] Fix | Delete
this.computeInitial();
[29366] Fix | Delete
if (config.preventScrollAxis && getPointerType(event) !== 'mouse') {
[29367] Fix | Delete
state._active = false;
[29368] Fix | Delete
this.setupScrollPrevention(event);
[29369] Fix | Delete
} else if (config.delay > 0) {
[29370] Fix | Delete
this.setupDelayTrigger(event);
[29371] Fix | Delete
if (config.triggerAllEvents) {
[29372] Fix | Delete
this.compute(event);
[29373] Fix | Delete
this.emit();
[29374] Fix | Delete
}
[29375] Fix | Delete
} else {
[29376] Fix | Delete
this.startPointerDrag(event);
[29377] Fix | Delete
}
[29378] Fix | Delete
}
[29379] Fix | Delete
startPointerDrag(event) {
[29380] Fix | Delete
const state = this.state;
[29381] Fix | Delete
state._active = true;
[29382] Fix | Delete
state._preventScroll = true;
[29383] Fix | Delete
state._delayed = false;
[29384] Fix | Delete
this.compute(event);
[29385] Fix | Delete
this.emit();
[29386] Fix | Delete
}
[29387] Fix | Delete
pointerMove(event) {
[29388] Fix | Delete
const state = this.state;
[29389] Fix | Delete
const config = this.config;
[29390] Fix | Delete
if (!state._pointerActive) return;
[29391] Fix | Delete
const id = pointerId(event);
[29392] Fix | Delete
if (state._pointerId !== undefined && id !== state._pointerId) return;
[29393] Fix | Delete
const _values = pointerValues(event);
[29394] Fix | Delete
if (document.pointerLockElement === event.target) {
[29395] Fix | Delete
state._delta = [event.movementX, event.movementY];
[29396] Fix | Delete
} else {
[29397] Fix | Delete
state._delta = V.sub(_values, state._values);
[29398] Fix | Delete
this.computeValues(_values);
[29399] Fix | Delete
}
[29400] Fix | Delete
V.addTo(state._movement, state._delta);
[29401] Fix | Delete
this.compute(event);
[29402] Fix | Delete
if (state._delayed && state.intentional) {
[29403] Fix | Delete
this.timeoutStore.remove('dragDelay');
[29404] Fix | Delete
state.active = false;
[29405] Fix | Delete
this.startPointerDrag(event);
[29406] Fix | Delete
return;
[29407] Fix | Delete
}
[29408] Fix | Delete
if (config.preventScrollAxis && !state._preventScroll) {
[29409] Fix | Delete
if (state.axis) {
[29410] Fix | Delete
if (state.axis === config.preventScrollAxis || config.preventScrollAxis === 'xy') {
[29411] Fix | Delete
state._active = false;
[29412] Fix | Delete
this.clean();
[29413] Fix | Delete
return;
[29414] Fix | Delete
} else {
[29415] Fix | Delete
this.timeoutStore.remove('startPointerDrag');
[29416] Fix | Delete
this.startPointerDrag(event);
[29417] Fix | Delete
return;
[29418] Fix | Delete
}
[29419] Fix | Delete
} else {
[29420] Fix | Delete
return;
[29421] Fix | Delete
}
[29422] Fix | Delete
}
[29423] Fix | Delete
this.emit();
[29424] Fix | Delete
}
[29425] Fix | Delete
pointerUp(event) {
[29426] Fix | Delete
this.ctrl.setEventIds(event);
[29427] Fix | Delete
try {
[29428] Fix | Delete
if (this.config.pointerCapture && event.target.hasPointerCapture(event.pointerId)) {
[29429] Fix | Delete
;
[29430] Fix | Delete
event.target.releasePointerCapture(event.pointerId);
[29431] Fix | Delete
}
[29432] Fix | Delete
} catch (_unused) {
[29433] Fix | Delete
if (false) {}
[29434] Fix | Delete
}
[29435] Fix | Delete
const state = this.state;
[29436] Fix | Delete
const config = this.config;
[29437] Fix | Delete
if (!state._active || !state._pointerActive) return;
[29438] Fix | Delete
const id = pointerId(event);
[29439] Fix | Delete
if (state._pointerId !== undefined && id !== state._pointerId) return;
[29440] Fix | Delete
this.state._pointerActive = false;
[29441] Fix | Delete
this.setActive();
[29442] Fix | Delete
this.compute(event);
[29443] Fix | Delete
const [dx, dy] = state._distance;
[29444] Fix | Delete
state.tap = dx <= config.tapsThreshold && dy <= config.tapsThreshold;
[29445] Fix | Delete
if (state.tap && config.filterTaps) {
[29446] Fix | Delete
state._force = true;
[29447] Fix | Delete
} else {
[29448] Fix | Delete
const [_dx, _dy] = state._delta;
[29449] Fix | Delete
const [_mx, _my] = state._movement;
[29450] Fix | Delete
const [svx, svy] = config.swipe.velocity;
[29451] Fix | Delete
const [sx, sy] = config.swipe.distance;
[29452] Fix | Delete
const sdt = config.swipe.duration;
[29453] Fix | Delete
if (state.elapsedTime < sdt) {
[29454] Fix | Delete
const _vx = Math.abs(_dx / state.timeDelta);
[29455] Fix | Delete
const _vy = Math.abs(_dy / state.timeDelta);
[29456] Fix | Delete
if (_vx > svx && Math.abs(_mx) > sx) state.swipe[0] = Math.sign(_dx);
[29457] Fix | Delete
if (_vy > svy && Math.abs(_my) > sy) state.swipe[1] = Math.sign(_dy);
[29458] Fix | Delete
}
[29459] Fix | Delete
}
[29460] Fix | Delete
this.emit();
[29461] Fix | Delete
}
[29462] Fix | Delete
pointerClick(event) {
[29463] Fix | Delete
if (!this.state.tap && event.detail > 0) {
[29464] Fix | Delete
event.preventDefault();
[29465] Fix | Delete
event.stopPropagation();
[29466] Fix | Delete
}
[29467] Fix | Delete
}
[29468] Fix | Delete
setupPointer(event) {
[29469] Fix | Delete
const config = this.config;
[29470] Fix | Delete
const device = config.device;
[29471] Fix | Delete
if (false) {}
[29472] Fix | Delete
if (config.pointerLock) {
[29473] Fix | Delete
event.currentTarget.requestPointerLock();
[29474] Fix | Delete
}
[29475] Fix | Delete
if (!config.pointerCapture) {
[29476] Fix | Delete
this.eventStore.add(this.sharedConfig.window, device, 'change', this.pointerMove.bind(this));
[29477] Fix | Delete
this.eventStore.add(this.sharedConfig.window, device, 'end', this.pointerUp.bind(this));
[29478] Fix | Delete
this.eventStore.add(this.sharedConfig.window, device, 'cancel', this.pointerUp.bind(this));
[29479] Fix | Delete
}
[29480] Fix | Delete
}
[29481] Fix | Delete
pointerClean() {
[29482] Fix | Delete
if (this.config.pointerLock && document.pointerLockElement === this.state.currentTarget) {
[29483] Fix | Delete
document.exitPointerLock();
[29484] Fix | Delete
}
[29485] Fix | Delete
}
[29486] Fix | Delete
preventScroll(event) {
[29487] Fix | Delete
if (this.state._preventScroll && event.cancelable) {
[29488] Fix | Delete
event.preventDefault();
[29489] Fix | Delete
}
[29490] Fix | Delete
}
[29491] Fix | Delete
setupScrollPrevention(event) {
[29492] Fix | Delete
this.state._preventScroll = false;
[29493] Fix | Delete
persistEvent(event);
[29494] Fix | Delete
const remove = this.eventStore.add(this.sharedConfig.window, 'touch', 'change', this.preventScroll.bind(this), {
[29495] Fix | Delete
passive: false
[29496] Fix | Delete
});
[29497] Fix | Delete
this.eventStore.add(this.sharedConfig.window, 'touch', 'end', remove);
[29498] Fix | Delete
this.eventStore.add(this.sharedConfig.window, 'touch', 'cancel', remove);
[29499] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function