424 lines
19 KiB
React
424 lines
19 KiB
React
/* Metro module 7992; source: unknown; dependencies: [7993, 57, 29, 31, 27, 7994, 33, 7996, 7997, 7998] */
|
|
function _fun63552(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#63552, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8170:6, offset: 0x01b8520b, size: 521 bytes, params: 8, frame: 34
|
|
var r17;
|
|
var r14;
|
|
var r20;
|
|
var r3;
|
|
var __esModule;
|
|
var value3;
|
|
var value4;
|
|
var value5;
|
|
var has;
|
|
var value6;
|
|
var getOwnPropertyDescriptor;
|
|
var properties;
|
|
var properties2;
|
|
var properties3;
|
|
var propertyName;
|
|
var propertyName2;
|
|
var hasOwnProperty;
|
|
var call;
|
|
var value7;
|
|
var get;
|
|
var set;
|
|
var value8;
|
|
const env0_0 = require;
|
|
const value = require(7993) /* metro dependency 7993 */;
|
|
let Object = global.Object;
|
|
let defineProperty = Object.defineProperty;
|
|
Reflect.apply(defineProperty, Object, [exports, '__esModule', {value: true}]);
|
|
exports.default = undefined;
|
|
const env0_2 = value(require(57) /* metro dependency 57 */);
|
|
const env0_3 = value(require(29) /* metro dependency 29 */);
|
|
const value2 = require(31) /* metro dependency 31 */;
|
|
reducibleJoin24: while (true) {
|
|
reducibleJoin23: while (true) {
|
|
if (value2) {
|
|
__esModule = value2.__esModule;
|
|
if (__esModule) {
|
|
r3 = value2;
|
|
break reducibleJoin24;
|
|
}
|
|
value3 = null;
|
|
if (value3 === value2) {
|
|
break reducibleJoin23;
|
|
}
|
|
value4 = typeof value2;
|
|
if (value4 !== 'object') {
|
|
if (value4 !== 'function') {
|
|
break reducibleJoin23;
|
|
}
|
|
}
|
|
value5 = env0_9(undefined);
|
|
if (value5) {
|
|
has = value5.has;
|
|
if (Reflect.apply(has, value5, [value2])) {
|
|
get = value5.get;
|
|
value8 = Reflect.apply(get, value5, [value2]);
|
|
r3 = value8;
|
|
break reducibleJoin24;
|
|
}
|
|
}
|
|
value6 = Object.create(value3);
|
|
Object = global.Object;
|
|
defineProperty = Object.defineProperty;
|
|
reducibleJoin9: while (true) {
|
|
if (defineProperty) {
|
|
Object = global.Object;
|
|
getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
r17 = getOwnPropertyDescriptor;
|
|
break reducibleJoin9;
|
|
}
|
|
r17 = defineProperty;
|
|
break reducibleJoin9;
|
|
}
|
|
properties = Object.keys(value2);
|
|
properties2 = 0;
|
|
properties3 = properties.length;
|
|
if (properties !== undefined) {
|
|
r14 = properties2;
|
|
reducibleLoop10: while (true) {
|
|
propertyName = properties[r14];
|
|
propertyName2 = r14 + 1;
|
|
if (propertyName === undefined) {
|
|
break reducibleLoop10;
|
|
}
|
|
if (propertyName === 'default') {
|
|
r14 = propertyName2;
|
|
continue reducibleLoop10;
|
|
}
|
|
hasOwnProperty = ({}).hasOwnProperty;
|
|
call = hasOwnProperty.call;
|
|
if (Reflect.apply(call, hasOwnProperty, [value2, propertyName])) {
|
|
reducibleJoin15: while (true) {
|
|
if (r17) {
|
|
Object = global.Object;
|
|
getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
value7 = Reflect.apply(getOwnPropertyDescriptor, Object, [value2, propertyName]);
|
|
r20 = value7;
|
|
break reducibleJoin15;
|
|
}
|
|
r20 = value3;
|
|
break reducibleJoin15;
|
|
}
|
|
if (r20) {
|
|
get = r20.get;
|
|
reducibleJoin18: while (true) {
|
|
reducibleJoin19: while (true) {
|
|
if (get) {
|
|
break reducibleJoin19;
|
|
}
|
|
set = r20.set;
|
|
if (set) {
|
|
break reducibleJoin19;
|
|
}
|
|
break reducibleJoin18;
|
|
}
|
|
Object = global.Object;
|
|
defineProperty = Object.defineProperty;
|
|
Reflect.apply(defineProperty, Object, [value6, propertyName, r20]);
|
|
r14 = propertyName2;
|
|
continue reducibleLoop10;
|
|
}
|
|
}
|
|
value6[propertyName] = value2[propertyName];
|
|
r14 = propertyName2;
|
|
continue reducibleLoop10;
|
|
}
|
|
r14 = propertyName2;
|
|
continue reducibleLoop10;
|
|
}
|
|
}
|
|
value6.default = value2;
|
|
if (value5) {
|
|
set = value5.set;
|
|
Reflect.apply(set, value5, [value2, value6]);
|
|
r3 = value6;
|
|
break reducibleJoin24;
|
|
}
|
|
r3 = value6;
|
|
break reducibleJoin24;
|
|
}
|
|
value3 = null;
|
|
if (value3 === value2) {
|
|
break reducibleJoin23;
|
|
}
|
|
value4 = typeof value2;
|
|
if (value4 !== 'object') {
|
|
if (value4 !== 'function') {
|
|
break reducibleJoin23;
|
|
}
|
|
}
|
|
value5 = env0_9(undefined);
|
|
if (value5) {
|
|
has = value5.has;
|
|
if (Reflect.apply(has, value5, [value2])) {
|
|
get = value5.get;
|
|
value8 = Reflect.apply(get, value5, [value2]);
|
|
r3 = value8;
|
|
break reducibleJoin24;
|
|
}
|
|
}
|
|
value6 = Object.create(value3);
|
|
Object = global.Object;
|
|
defineProperty = Object.defineProperty;
|
|
reducibleJoin9: while (true) {
|
|
if (defineProperty) {
|
|
Object = global.Object;
|
|
getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
r17 = getOwnPropertyDescriptor;
|
|
break reducibleJoin9;
|
|
}
|
|
r17 = defineProperty;
|
|
break reducibleJoin9;
|
|
}
|
|
properties = Object.keys(value2);
|
|
properties2 = 0;
|
|
properties3 = properties.length;
|
|
if (properties !== undefined) {
|
|
r14 = properties2;
|
|
reducibleLoop10: while (true) {
|
|
propertyName = properties[r14];
|
|
propertyName2 = r14 + 1;
|
|
if (propertyName === undefined) {
|
|
break reducibleLoop10;
|
|
}
|
|
if (propertyName === 'default') {
|
|
r14 = propertyName2;
|
|
continue reducibleLoop10;
|
|
}
|
|
hasOwnProperty = ({}).hasOwnProperty;
|
|
call = hasOwnProperty.call;
|
|
if (Reflect.apply(call, hasOwnProperty, [value2, propertyName])) {
|
|
reducibleJoin15: while (true) {
|
|
if (r17) {
|
|
Object = global.Object;
|
|
getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
value7 = Reflect.apply(getOwnPropertyDescriptor, Object, [value2, propertyName]);
|
|
r20 = value7;
|
|
break reducibleJoin15;
|
|
}
|
|
r20 = value3;
|
|
break reducibleJoin15;
|
|
}
|
|
if (r20) {
|
|
get = r20.get;
|
|
reducibleJoin18: while (true) {
|
|
reducibleJoin19: while (true) {
|
|
if (get) {
|
|
break reducibleJoin19;
|
|
}
|
|
set = r20.set;
|
|
if (set) {
|
|
break reducibleJoin19;
|
|
}
|
|
break reducibleJoin18;
|
|
}
|
|
Object = global.Object;
|
|
defineProperty = Object.defineProperty;
|
|
Reflect.apply(defineProperty, Object, [value6, propertyName, r20]);
|
|
r14 = propertyName2;
|
|
continue reducibleLoop10;
|
|
}
|
|
}
|
|
value6[propertyName] = value2[propertyName];
|
|
r14 = propertyName2;
|
|
continue reducibleLoop10;
|
|
}
|
|
r14 = propertyName2;
|
|
continue reducibleLoop10;
|
|
}
|
|
}
|
|
value6.default = value2;
|
|
if (value5) {
|
|
set = value5.set;
|
|
Reflect.apply(set, value5, [value2, value6]);
|
|
r3 = value6;
|
|
break reducibleJoin24;
|
|
}
|
|
r3 = value6;
|
|
break reducibleJoin24;
|
|
}
|
|
r3 = {default: value2};
|
|
break reducibleJoin24;
|
|
}
|
|
const env0_5 = require(27) /* metro dependency 27 */;
|
|
const env0_6 = value(require(7994) /* metro dependency 7994 */);
|
|
const env0_7 = require(33) /* metro dependency 33 */;
|
|
const env0_8 = ['onValueChange', 'onSlidingStart', 'onSlidingComplete', 'onAccessibilityAction', 'value',
|
|
'minimumValue', 'maximumValue', 'step', 'inverted', 'tapToSeek', 'lowerLimit', 'upperLimit'];
|
|
exports.default = r3.default.forwardRef(SliderComponent);
|
|
}
|
|
|
|
function _getRequireWildcardCache(a0) { // fn#63553, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8170:864, offset: 0x01b85414, size: 109 bytes, params: 2, frame: 12
|
|
let WeakMap = global.WeakMap;
|
|
if (typeof WeakMap !== 'function') {
|
|
return null;
|
|
}
|
|
WeakMap = global.WeakMap;
|
|
let weakMap = new WeakMap();
|
|
WeakMap = global.WeakMap;
|
|
weakMap = new WeakMap();
|
|
return _getRequireWildcardCache_body(a0);
|
|
}
|
|
|
|
function SliderComponent(a0, a1) { // fn#63555, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8170:1090, offset: 0x01b85496, size: 1392 bytes, params: 3, frame: 42
|
|
var r22;
|
|
var r21;
|
|
var r6;
|
|
var Platform;
|
|
var select;
|
|
var object2;
|
|
var jsx;
|
|
const env0_0 = a0.onValueChange;
|
|
const onSlidingStart = a0.onSlidingStart;
|
|
const onSlidingComplete = a0.onSlidingComplete;
|
|
const env0_2 = onSlidingComplete;
|
|
const onAccessibilityAction = a0.onAccessibilityAction;
|
|
const env0_3 = onAccessibilityAction;
|
|
let value = a0.value;
|
|
const value2 = undefined;
|
|
const r0 = value2 !== value ? value : (require(7996) /* metro dependency 7996 */).constants.SLIDER_DEFAULT_INITIAL_VALUE;
|
|
const minimumValue = a0.minimumValue;
|
|
value = 0;
|
|
const r28 = value2 === minimumValue ? value : minimumValue;
|
|
const env0_4 = r28;
|
|
const maximumValue = a0.maximumValue;
|
|
const value3 = 1;
|
|
const r27 = value2 === maximumValue ? value3 : maximumValue;
|
|
const step = a0.step;
|
|
const r26 = value2 === step ? value : step;
|
|
const inverted = a0.inverted;
|
|
const r25 = value2 !== inverted && inverted;
|
|
const tapToSeek = a0.tapToSeek;
|
|
const r24 = value2 !== tapToSeek && tapToSeek;
|
|
const lowerLimit = a0.lowerLimit;
|
|
if (value2 !== lowerLimit) {
|
|
r22 = lowerLimit;
|
|
} else {
|
|
Platform = env0_5.Platform;
|
|
select = Platform.select;
|
|
object2 = {web: r28};
|
|
object2.default = (require(7996) /* metro dependency 7996 */).constants.LIMIT_MIN_VALUE;
|
|
r22 = Reflect.apply(select, Platform, [object2]);
|
|
}
|
|
var env0_5 = r22;
|
|
const upperLimit = a0.upperLimit;
|
|
if (value2 !== upperLimit) {
|
|
r21 = upperLimit;
|
|
} else {
|
|
Platform = env0_5.Platform;
|
|
select = Platform.select;
|
|
object2 = {web: r27};
|
|
object2.default = (require(7996) /* metro dependency 7996 */).constants.LIMIT_MAX_VALUE;
|
|
r21 = Reflect.apply(select, Platform, [object2]);
|
|
}
|
|
const env0_6 = r21;
|
|
let property = env0_3.default;
|
|
const value11 = property(a0, env0_8);
|
|
let useState = env0_4.useState;
|
|
const value12 = null;
|
|
let r7 = value12 == r0 ? r28 : r0;
|
|
r7 = value12 == r7 ? (require(7996) /* metro dependency 7996 */).constants.SLIDER_DEFAULT_INITIAL_VALUE : r7;
|
|
const value13 = useState(r7);
|
|
const binding = env0_2;
|
|
const value14 = (0, binding.default)(value13, 2);
|
|
property = value14[value];
|
|
const env0_7 = value14[value3];
|
|
useState = env0_4.useState;
|
|
const value16 = (0, binding.default)(useState(value), 2);
|
|
const property2 = value16[value];
|
|
var env0_8 = value16[value3];
|
|
value = (r27 - r28) / (r26 || (require(7996) /* metro dependency 7996 */).constants.DEFAULT_STEP_RESOLUTION);
|
|
const env0_9 = r26 || value;
|
|
const Array = global.Array;
|
|
const from = Array.from;
|
|
r7 = r26 ? value : r7;
|
|
value = Reflect.apply(from, Array, [{length: r7 + value3}, _fun63556]);
|
|
Platform = env0_5.Platform;
|
|
let OS = Platform.OS;
|
|
const r18 = OS === 'ios' ? (require(7997) /* metro dependency 7997 */).styles.defaultSlideriOS : (require(7997) /* metro dependency 7997 */).styles.defaultSlider;
|
|
object2 = {zIndex: value3, width: property2};
|
|
const items2 = [r18];
|
|
items2[1] = value11.style;
|
|
const closure = onChange_63557;
|
|
const r13 = typeof value11.disabled === 'boolean' ? value11.disabled : (value12 == value11.accessibilityState ? value2 : value11.accessibilityState.disabled) === true;
|
|
const r17 = typeof value11.disabled === 'boolean' ? global.Object.assign({}, value11.accessibilityState,
|
|
{disabled: value11.disabled}) : value11.accessibilityState;
|
|
const r16 = onSlidingStart ? function(a0) {
|
|
onSlidingStart(a0.nativeEvent.value);
|
|
} : value12;
|
|
const r15 = onSlidingComplete ? function(a0) {
|
|
onSlidingComplete(a0.nativeEvent.value);
|
|
} : value12;
|
|
const r5 = onAccessibilityAction ? function(a0) {
|
|
onAccessibilityAction(a0);
|
|
} : value12;
|
|
const Number = global.Number;
|
|
const r23 = Number.isNaN(r0) ? value2 : r0 || value2;
|
|
const useEffect = env0_4.useEffect;
|
|
useEffect(_fun63561, [r22, r21]);
|
|
const jsxs = env0_7.jsxs;
|
|
const View = env0_5.View;
|
|
const viewProps = {onLayout: onLayout_63562, style: [items2, {justifyContent: 'center'}]};
|
|
const StepMarker = value11.StepMarker;
|
|
if (StepMarker) {
|
|
jsx = env0_7.jsx;
|
|
const StepsIndicator = (require(7998) /* metro dependency 7998 */).StepsIndicator;
|
|
value = <StepsIndicator options={value} sliderWidth={property2} currentValue={property} renderStepNumber={value11.renderStepNumber} thumbImage={value11.thumbImage} StepMarker={value11.StepMarker} isLTR={r25} />;
|
|
r6 = value;
|
|
} else if (value11.renderStepNumber) {
|
|
jsx = env0_7.jsx;
|
|
const StepsIndicator2 = (require(7998) /* metro dependency 7998 */).StepsIndicator;
|
|
value = <StepsIndicator2 options={value} sliderWidth={property2} currentValue={property} renderStepNumber={value11.renderStepNumber} thumbImage={value11.thumbImage} StepMarker={value11.StepMarker} isLTR={r25} />;
|
|
r6 = value;
|
|
} else {
|
|
r6 = value12;
|
|
}
|
|
jsx = env0_7.jsx;
|
|
property = env0_6.default;
|
|
const Object = global.Object;
|
|
const assign = Object.assign;
|
|
Platform = env0_5.Platform;
|
|
OS = Platform.OS;
|
|
return (
|
|
<View {...viewProps}>
|
|
{r6}
|
|
{((Component) => <Component {...Reflect.apply(assign, Object, [{}, value11, {minimumValue: r28,
|
|
maximumValue: r27, step: r26, inverted: r25, tapToSeek: r24, value: r23, lowerLimit: r22,
|
|
upperLimit: r21, accessibilityState: r17,
|
|
thumbImage: OS === 'web' ? value11.thumbImage : value11.StepMarker ? value2 : env0_5.Image.resolveAssetSource(value11.thumbImage),
|
|
ref: a1, style: [object2, r18, {'alignContent': 'center', 'alignItems': 'center'}], onChange: closure,
|
|
onRNCSliderSlidingStart: r16, onRNCSliderSlidingComplete: r15, onRNCSliderValueChange: closure,
|
|
disabled: r13, onStartShouldSetResponder: function() {
|
|
return true;
|
|
}, onResponderTerminationRequest: function() {
|
|
return false;
|
|
}, onRNCSliderAccessibilityAction: r5,
|
|
thumbTintColor: value11.thumbImage && value11.StepMarker ? 'transparent' : value11.thumbTintColor}])} />)(property)}
|
|
</View>
|
|
);
|
|
}
|
|
|
|
function _fun63556(a0, a1) { // fn#63556, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8170:1938, offset: 0x01b85a06, size: 24 bytes, params: 3, frame: 3
|
|
return env0_4 + a1 * env0_9;
|
|
}
|
|
|
|
function SliderComponentOnChange(a0) { // fn#63557, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8170:2092, owner: SliderComponent.onChange, offset: 0x01b85a1e, size: 59 bytes, params: 2, frame: 13
|
|
if (onValueChange) {
|
|
onValueChange(a0.nativeEvent.value);
|
|
}
|
|
env0_7(a0.nativeEvent.value);
|
|
}
|
|
|
|
function _fun63561() { // fn#63561, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8170:2558, offset: 0x01b85aa8, size: 43 bytes, params: 1, frame: 11
|
|
if (env0_5 >= env0_6) {
|
|
global.console.warn('Invalid configuration: lower limit is supposed to be smaller than upper limit');
|
|
}
|
|
}
|
|
|
|
function SliderComponentOnLayout({nativeEvent}) { // fn#63562, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8170:2706, owner: SliderComponent.onLayout, offset: 0x01b85ad3, size: 36 bytes, params: 2, frame: 11
|
|
env0_8(nativeEvent.layout.width);
|
|
}
|
|
|