Initial commit
This commit is contained in:
commit
af3b49f756
16065 files changed
+2938410
No files matched your search
@@ -0,0 +1,13 @@
|
||||
/* Metro module 6838; source: modules/dice_roll/DiceRollActionCreators.tsx; dependencies: [694, 2] */
|
||||
function _fun53845(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#53845, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7016:6, offset: 0x01357401, size: 97 bytes, params: 8, frame: 17
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/dice_roll/DiceRollActionCreators.tsx');
|
||||
exports.startDiceRoll = startDiceRoll;
|
||||
}
|
||||
|
||||
function startDiceRoll(a0, a1, a2) { // fn#53846, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7016:186, offset: 0x01357462, size: 71 bytes, params: 4, frame: 13
|
||||
(importDefault(694) /* metro dependency 694: Dispatcher */).dispatch({type: 'DICE_ROLL_START', channelId: a0,
|
||||
diceCount: a1, diceSides: a2});
|
||||
}
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
/* Metro module 7872; source: modules/dice_roll/DiceRollConstants.tsx; dependencies: [2] */
|
||||
function _fun63115(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#63115, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8050:6, offset: 0x01b70d67, size: 177 bytes, params: 8, frame: 17
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
items = [4, 6, 8, 10, 12, 20];
|
||||
const Set = global.Set;
|
||||
const set = new Set(items);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/dice_roll/DiceRollConstants.tsx');
|
||||
exports.ROLL_DURATION_MS = 1500;
|
||||
exports.AFTER_ROLL_DELAY_MS = 2000;
|
||||
exports.DISMISS_DELAY_MS = 300;
|
||||
exports.MAX_DICE_COUNT = 10;
|
||||
exports.ALLOWED_DICE_SIDES = items;
|
||||
exports.ALLOWED_DICE_SIDES_SET = set;
|
||||
exports.DEFAULT_DICE_SIDES = 6;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
/* Metro module 8038; source: modules/dice_roll/DiceRollExperiment.tsx; dependencies: [1854, 2] */
|
||||
function _fun63730(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#63730, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8216:6, offset: 0x01b8e584, size: 145 bytes, params: 8, frame: 20
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = require(1854) /* metro dependency 1854: apex */;
|
||||
value = value.createApexExperiment({'kind': 'user', 'name': '2026-05-dice-roll-slash-command',
|
||||
defaultConfig: {enabled: false}, variations: {[1]: {enabled: true}}});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/dice_roll/DiceRollExperiment.tsx');
|
||||
exports.default = value;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,301 @@
|
||||
/* Metro module 15688; source: modules/dice_roll/DiceRollLifecycleManager.tsx; dependencies: [6, 7, 15, 17, 18, 1379, 1934, 11526, 7872, 4503, 1244, 7067, 7076, 4860, 2] */
|
||||
function _fun120356(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#120356, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:6, offset: 0x02528ebf, size: 391 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importDefault(6) /* metro dependency 6 */;
|
||||
const env0_4 = importDefault(7) /* metro dependency 7 */;
|
||||
const env0_5 = importDefault(15) /* metro dependency 15 */;
|
||||
const env0_6 = importDefault(17) /* metro dependency 17 */;
|
||||
const env0_7 = importDefault(18) /* metro dependency 18 */;
|
||||
const channelStore = importDefault(1379) /* metro dependency 1379: ChannelStore */;
|
||||
const selectedChannelStore = importDefault(1934) /* metro dependency 1934: SelectedChannelStore */;
|
||||
const diceRollStore = importDefault(11526) /* metro dependency 11526: DiceRollStore */;
|
||||
const env0_11 = (require(11526) /* metro dependency 11526: DiceRollStore */).INITIAL_STATE;
|
||||
let value = require(7872) /* metro dependency 7872: DiceRollConstants */;
|
||||
const env0_12 = value.AFTER_ROLL_DELAY_MS;
|
||||
const env0_13 = value.ALLOWED_DICE_SIDES_SET;
|
||||
const env0_14 = value.DEFAULT_DICE_SIDES;
|
||||
const env0_15 = value.DISMISS_DELAY_MS;
|
||||
const env0_16 = value.MAX_DICE_COUNT;
|
||||
const env0_17 = value.ROLL_DURATION_MS;
|
||||
const env0_18 = (require(4503) /* metro dependency 4503: MessageConstants */).MessageSendLocation;
|
||||
value = importDefault(4860) /* metro dependency 4860: AutomaticLifecycleManager */;
|
||||
value = _fun120360(value);
|
||||
value = new value();
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/dice_roll/DiceRollLifecycleManager.tsx');
|
||||
exports.default = value;
|
||||
}
|
||||
|
||||
function _isNativeReflectConstruct_120357() { // fn#120357, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:387, offset: 0x02529046, size: 98 bytes, params: 1, frame: 18
|
||||
var Boolean;
|
||||
var prototype;
|
||||
var valueOf;
|
||||
var call;
|
||||
var Reflect;
|
||||
var construct;
|
||||
var closure;
|
||||
var value;
|
||||
var error;
|
||||
try {
|
||||
Boolean = global.Boolean;
|
||||
prototype = Boolean.prototype;
|
||||
valueOf = prototype.valueOf;
|
||||
call = valueOf.call;
|
||||
Reflect = global.Reflect;
|
||||
construct = Reflect.construct;
|
||||
Boolean = global.Boolean;
|
||||
closure = function() {
|
||||
};
|
||||
value = Reflect.apply(construct, Reflect, [Boolean, [], closure]);
|
||||
value = Reflect.apply(call, valueOf, [value]);
|
||||
var result = !value;
|
||||
} catch (error) {
|
||||
}
|
||||
return (_isNativeReflectConstruct_120357_isNativeReflectConstruct = function() {
|
||||
return !!result;
|
||||
})();
|
||||
}
|
||||
|
||||
function _fun120360(a0) { // fn#120360, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:590, offset: 0x025290a8, size: 151 bytes, params: 2, frame: 16
|
||||
const closure = DiceRollLifecycleManager;
|
||||
env0_7(closure, a0);
|
||||
return env0_4(closure, [{key: 'finishRoll', value: function(a0, a1, a2, a3) {
|
||||
var env0_0 = this;
|
||||
DiceRollStore.setState({rolling: false, results: a3});
|
||||
this.postRollDismissTimer = global.setTimeout(_fun120368, AFTER_ROLL_DELAY_MS);
|
||||
this.sendMessage(a0, a1, a2, a3);
|
||||
}}, {key: 'sendMessage', value: value_120369}, {key: 'dismiss', value: function() {
|
||||
var env0_0 = this;
|
||||
DiceRollStore.setState({dismissing: true});
|
||||
this.collapseTimer = global.setTimeout(_fun120373, DISMISS_DELAY_MS);
|
||||
}}, {key: 'clearTimers', value: function() {
|
||||
if (this.rollTimer != null) {
|
||||
global.clearTimeout(this.rollTimer);
|
||||
this.rollTimer = null;
|
||||
}
|
||||
if (this.postRollDismissTimer != null) {
|
||||
global.clearTimeout(this.postRollDismissTimer);
|
||||
this.postRollDismissTimer = null;
|
||||
}
|
||||
if (this.collapseTimer != null) {
|
||||
global.clearTimeout(this.collapseTimer);
|
||||
this.collapseTimer = null;
|
||||
}
|
||||
}}]);
|
||||
}
|
||||
|
||||
function DiceRollLifecycleManager(a0) { // fn#120361, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:602, offset: 0x0252913f, size: 212 bytes, params: 2, frame: 20
|
||||
var r0;
|
||||
var Reflect;
|
||||
let value = copyRestArgs(0, undefined);
|
||||
let binding = env1_3;
|
||||
binding(this, DiceRollLifecycleManager);
|
||||
const items = [];
|
||||
arraySpread(items, value, 0, items);
|
||||
value = env1_6(DiceRollLifecycleManager);
|
||||
binding = env1_5;
|
||||
if (_isNativeReflectConstruct_120357()) {
|
||||
Reflect = global.Reflect;
|
||||
value = Reflect.construct(value, items, env1_6(this).constructor);
|
||||
r0 = value;
|
||||
} else {
|
||||
value = value.apply(this, items);
|
||||
r0 = value;
|
||||
}
|
||||
value = binding(this, r0);
|
||||
value.actions = {CHANNEL_SELECT: CHANNEL_SELECT_120362, DICE_ROLL_START: DICE_ROLL_START};
|
||||
value.rollTimer = null;
|
||||
value.postRollDismissTimer = null;
|
||||
value.collapseTimer = null;
|
||||
value.handleChannelSelect = handleChannelSelect_120364;
|
||||
value.handleStartRoll = handleStartRoll;
|
||||
return value;
|
||||
}
|
||||
|
||||
function value_120367(a0, a1, a2, a3) { // fn#120367, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:1626, offset: 0x02529414, size: 104 bytes, params: 5, frame: 19
|
||||
DiceRollStore.setState({rolling: false, results: a3});
|
||||
this.postRollDismissTimer = global.setTimeout(_fun120368, AFTER_ROLL_DELAY_MS);
|
||||
this.sendMessage(a0, a1, a2, a3);
|
||||
}
|
||||
|
||||
function value_120369(a0, a1, a2, a3) { // fn#120369, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:1826, offset: 0x02529499, size: 548 bytes, params: 5, frame: 35
|
||||
var r6;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
|
||||
var value7;
|
||||
var value9;
|
||||
var defaultImport;
|
||||
const channel = ChannelStore.getChannel(a0);
|
||||
if (channel != null) {
|
||||
value7 = '[`' + intl.formatToPlainString(t.uV5JaG, {count: a1,
|
||||
sides: a2}) + '`](' + ('' + global.location.protocol + global.window.GLOBAL_ENV.WEBAPP_ENDPOINT + '/channels/' + (channel.getGuildId() ?? '@me') + '/' + a0 + '/roll-dice/' + a1 + 'd' + a2) + ')';
|
||||
value9 = intl.formatToMarkdownString(t.tmSbYW, {total: a3.reduce(function(a0, a1) {
|
||||
return a0 + a1;
|
||||
}, 0), count: a1, sides: a2});
|
||||
r6 = a1 === 1 ? '### ' + value9 + ' ' + value7 : '### ' + value9 + ' ' + value7 + '\n' + ('-# ' + a3.map(_fun120371).join(' '));
|
||||
defaultImport = importDefault(7067) /* metro dependency 7067: MessageActionCreators */;
|
||||
defaultImport.sendMessage(a0, (importDefault(7076) /* metro dependency 7076: MessageParser */).parse(channel,
|
||||
r6),
|
||||
true, {location: MessageSendLocation.CHAT_INPUT});
|
||||
}
|
||||
}
|
||||
|
||||
function value_120372() { // fn#120372, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:2424, offset: 0x025296e3, size: 71 bytes, params: 1, frame: 16
|
||||
DiceRollStore.setState({dismissing: true});
|
||||
this.collapseTimer = global.setTimeout(_fun120373, DISMISS_DELAY_MS);
|
||||
}
|
||||
|
||||
function DICE_ROLL_START(a0) { // fn#120363, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:930, owner: DiceRollLifecycleManager.DICE_ROLL_START, offset: 0x02529213, size: 23 bytes, params: 2, frame: 11
|
||||
return env0_0.handleStartRoll(a0);
|
||||
}
|
||||
|
||||
function DiceRollLifecycleManagerHandleChannelSelect({channelId}) { // fn#120364, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:1043, owner: DiceRollLifecycleManager.handleChannelSelect, offset: 0x0252922a, size: 84 bytes, params: 2, frame: 11
|
||||
var binding;
|
||||
let value = environment.__proto__.__proto__;
|
||||
value = DiceRollStore.getState();
|
||||
if (value.channelId != null && value.channelId !== channelId) {
|
||||
binding = env0_0;
|
||||
binding.clearTimers();
|
||||
binding.dismiss();
|
||||
}
|
||||
}
|
||||
|
||||
function handleStartRoll({channelId, diceCount, diceSides}) { // fn#120365, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:1165, owner: DiceRollLifecycleManager.handleStartRoll, offset: 0x0252927e, size: 353 bytes, params: 2, frame: 23
|
||||
var environment;
|
||||
var r4;
|
||||
var r8;
|
||||
var r7;
|
||||
var r5;
|
||||
var value;
|
||||
var getState;
|
||||
var channelId2;
|
||||
var value2;
|
||||
var Math;
|
||||
var min;
|
||||
var Math2;
|
||||
var max;
|
||||
var value3;
|
||||
var value4;
|
||||
var has;
|
||||
var setState;
|
||||
var items;
|
||||
var value5;
|
||||
var push;
|
||||
var floor;
|
||||
var Math3;
|
||||
var random;
|
||||
var value6;
|
||||
var value7;
|
||||
var binding;
|
||||
var setTimeout;
|
||||
const env0_0 = channelId;
|
||||
reducibleJoin2: while (true) {
|
||||
if (diceCount !== undefined) {
|
||||
break reducibleJoin2;
|
||||
}
|
||||
value = 1;
|
||||
diceCount = value;
|
||||
break reducibleJoin2;
|
||||
}
|
||||
reducibleJoin4: while (true) {
|
||||
if (diceSides !== undefined) {
|
||||
r4 = diceSides;
|
||||
break reducibleJoin4;
|
||||
}
|
||||
value = environment.__proto__.__proto__;
|
||||
r4 = DEFAULT_DICE_SIDES;
|
||||
break reducibleJoin4;
|
||||
}
|
||||
var env0_1;
|
||||
var env0_2;
|
||||
var env0_3;
|
||||
value = environment.__proto__.__proto__;
|
||||
const getChannelId = SelectedChannelStore.getChannelId;
|
||||
reducibleJoin13: while (true) {
|
||||
if (Reflect.apply(getChannelId, SelectedChannelStore, []) !== channelId) {
|
||||
break reducibleJoin13;
|
||||
}
|
||||
getState = DiceRollStore.getState;
|
||||
channelId2 = Reflect.apply(getState, DiceRollStore, []).channelId;
|
||||
if (channelId2 != null) {
|
||||
break reducibleJoin13;
|
||||
}
|
||||
value2 = 42;
|
||||
reducibleJoin8: while (true) {
|
||||
if (value2 === diceCount) {
|
||||
r8 = value2;
|
||||
break reducibleJoin8;
|
||||
}
|
||||
Math = global.Math;
|
||||
min = Math.min;
|
||||
Math2 = global.Math;
|
||||
max = Math2.max;
|
||||
value3 = Reflect.apply(max, Math2, [diceCount, 1]);
|
||||
value4 = Reflect.apply(min, Math, [value3, MAX_DICE_COUNT]);
|
||||
r8 = value4;
|
||||
break reducibleJoin8;
|
||||
}
|
||||
env0_1 = r8;
|
||||
has = ALLOWED_DICE_SIDES_SET.has;
|
||||
reducibleJoin10: while (true) {
|
||||
if (Reflect.apply(has, ALLOWED_DICE_SIDES_SET, [r4])) {
|
||||
r7 = r4;
|
||||
break reducibleJoin10;
|
||||
}
|
||||
r7 = DEFAULT_DICE_SIDES;
|
||||
break reducibleJoin10;
|
||||
}
|
||||
env0_2 = r7;
|
||||
setState = DiceRollStore.setState;
|
||||
Reflect.apply(setState, DiceRollStore, [{channelId: channelId, rolling: true, diceCount: r8, diceSides: r7,
|
||||
results: null}]);
|
||||
items = [];
|
||||
env0_3 = items;
|
||||
value5 = 0;
|
||||
if (value5 < r8) {
|
||||
r5 = value5;
|
||||
reducibleLoop11: while (true) {
|
||||
push = items.push;
|
||||
Math = global.Math;
|
||||
floor = Math.floor;
|
||||
Math3 = global.Math;
|
||||
random = Math3.random;
|
||||
Reflect.apply(push, items, [Reflect.apply(floor, Math, [Reflect.apply(random, Math3, []) * r7]) + 1]);
|
||||
value6 = typeof r5 === 'bigint' ? r5 + 1n : +r5 + 1;
|
||||
if (value6 < r8) {
|
||||
r5 = value6;
|
||||
continue reducibleLoop11;
|
||||
}
|
||||
break reducibleLoop11;
|
||||
}
|
||||
}
|
||||
value7 = environment;
|
||||
binding = env0_0;
|
||||
setTimeout = global.setTimeout;
|
||||
binding.rollTimer = setTimeout(_fun120366, ROLL_DURATION_MS);
|
||||
break reducibleJoin13;
|
||||
}
|
||||
}
|
||||
|
||||
function _fun120368() { // fn#120368, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:1717, offset: 0x0252947c, size: 29 bytes, params: 1, frame: 9
|
||||
const binding = env0_0;
|
||||
binding.postRollDismissTimer = null;
|
||||
binding.dismiss();
|
||||
}
|
||||
|
||||
function _fun120371(a0) { // fn#120371, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:2235, offset: 0x025296bd, size: 38 bytes, params: 2, frame: 11
|
||||
return ':game_die: ' + a0.toString();
|
||||
}
|
||||
|
||||
function _fun120373() { // fn#120373, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:2494, offset: 0x0252972a, size: 41 bytes, params: 1, frame: 11
|
||||
env0_0.collapseTimer = null;
|
||||
DiceRollStore.setState(INITIAL_STATE);
|
||||
}
|
||||
|
||||
function _fun120366() { // fn#120366, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15896:1484, offset: 0x025293df, size: 53 bytes, params: 1, frame: 17
|
||||
const binding = env1_0;
|
||||
binding.rollTimer = null;
|
||||
binding.finishRoll(channelId, env0_1, env0_2, env0_3);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,23 @@
|
||||
/* Metro module 11526; source: modules/dice_roll/DiceRollStore.tsx; dependencies: [629, 2] */
|
||||
function _fun88274(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#88274, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11712:6, offset: 0x01fde483, size: 150 bytes, params: 8, frame: 20
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = require(629) /* metro dependency 629 */;
|
||||
value = value.create(_fun88275);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/dice_roll/DiceRollStore.tsx');
|
||||
exports.default = value;
|
||||
exports.INITIAL_STATE = {'channelId': null, 'rolling': false, 'dismissing': false, 'diceCount': 1, 'diceSides': 6,
|
||||
'results': null};
|
||||
exports.useDiceRollState = useDiceRollState;
|
||||
}
|
||||
|
||||
function useDiceRollState(a0) { // fn#88276, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11712:329, offset: 0x01fde519, size: 32 bytes, params: 2, frame: 11
|
||||
const env0_0 = a0;
|
||||
return env0_1(_fun88277);
|
||||
}
|
||||
|
||||
function _fun88277(a0) { // fn#88277, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11712:368, offset: 0x01fde539, size: 26 bytes, params: 2, frame: 4
|
||||
const value = a0;
|
||||
return value.channelId !== env0_0 ? null : value;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,39 @@
|
||||
/* Metro module 11851; source: modules/dice_roll/DiceRollUtils.tsx; dependencies: [1244, 2] */
|
||||
function _fun90818(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#90818, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12037:6, offset: 0x02047b62, size: 107 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const sumResults = function(a0) {
|
||||
return a0.reduce(_fun90820, 0);
|
||||
};
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/dice_roll/DiceRollUtils.tsx');
|
||||
exports.getBarText = getBarText;
|
||||
}
|
||||
|
||||
function sumResults(a0) { // fn#90819, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12037:44, offset: 0x02047bcd, size: 28 bytes, params: 2, frame: 13
|
||||
return a0.reduce(function(a0, a1) {
|
||||
return a0 + a1;
|
||||
}, 0);
|
||||
}
|
||||
|
||||
function getBarText(a0, a1) { // fn#90821, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12037:230, offset: 0x02047be9, size: 165 bytes, params: 3, frame: 18
|
||||
var r0;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
var formatToPlainString;
|
||||
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
|
||||
var xU4pF1;
|
||||
var object2;
|
||||
if (a0) {
|
||||
r0 = intl.string(t['x/FIRX']);
|
||||
} else if (a1 == null) {
|
||||
r0 = '';
|
||||
} else {
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
xU4pF1 = t.xU4pF1;
|
||||
object2 = {};
|
||||
object2.total = sumResults(a1);
|
||||
r0 = Reflect.apply(formatToPlainString, intl, [xU4pF1, object2]);
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,159 @@
|
||||
/* Metro module 11850; source: modules/dice_roll/native/DiceRollBar.tsx; dependencies: [31, 27, 4502, 11526, 33, 4501, 697, 566, 4017, 4504, 1305, 11851, 11852, 4573, 2] */
|
||||
function _fun90811(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#90811, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12036:6, offset: 0x02047513, size: 356 bytes, params: 8, frame: 22
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const env0_4 = (require(27) /* metro dependency 27 */).View;
|
||||
const accessibilityStore = importDefault(4502) /* metro dependency 4502: AccessibilityStore */;
|
||||
const env0_6 = (require(11526) /* metro dependency 11526: DiceRollStore */).useDiceRollState;
|
||||
let value = require(33) /* metro dependency 33 */;
|
||||
const env0_7 = value.jsx;
|
||||
const env0_8 = value.jsxs;
|
||||
value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = value.createStyles;
|
||||
const object2 = {'flexDirection': 'row', 'alignItems': 'center', 'paddingHorizontal': 16, 'paddingVertical': 8,
|
||||
'gap': 12, 'borderTopWidth': 1};
|
||||
const BORDER_SUBTLE = (importDefault(697) /* metro dependency 697: native */).colors.BORDER_SUBTLE;
|
||||
object2.borderColor = BORDER_SUBTLE;
|
||||
const BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
|
||||
object2.backgroundColor = BACKGROUND_SURFACE_HIGH;
|
||||
const env0_9 = Reflect.apply(createStyles, value, [{animatedContainer: {overflow: 'hidden'}, container: object2}]);
|
||||
object = {code: 'function DiceRollBarTsx1(){const{useReducedMotion,height,opacity,withTiming,ANIMATION_DURATION_MS,DECELERATED_EASING}=this.__closure;if(useReducedMotion){return{height:height.get(),opacity:opacity.get()};}return{height:withTiming(height.get(),{duration:ANIMATION_DURATION_MS,easing:DECELERATED_EASING}),opacity:withTiming(opacity.get(),{duration:ANIMATION_DURATION_MS,easing:DECELERATED_EASING})};}'};
|
||||
object = {code: 'function DiceRollBarTsx2(){const{rotation}=this.__closure;return{transform:[{rotate:rotation.get()+"deg"}]};}'};
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/dice_roll/native/DiceRollBar.tsx');
|
||||
exports.default = DiceRollBar;
|
||||
}
|
||||
|
||||
function DiceRollBar({channelId}) { // fn#90812, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12036:1076, offset: 0x02047677, size: 750 bytes, params: 2, frame: 27
|
||||
var object2;
|
||||
const styles = useStyles();
|
||||
const value3 = useDiceRollState(channelId);
|
||||
const useReducedMotion = (require(566) /* metro dependency 566: flux */).useStateFromStores([AccessibilityStore],
|
||||
function() {
|
||||
return AccessibilityStore.useReducedMotion;
|
||||
});
|
||||
const value4 = (require(4017) /* metro dependency 4017: ReanimatedRexport */).useSharedValue(0);
|
||||
const value5 = (require(4017) /* metro dependency 4017: ReanimatedRexport */).useSharedValue(0);
|
||||
const value6 = (require(4017) /* metro dependency 4017: ReanimatedRexport */).useSharedValue(0);
|
||||
const env0_3 = value6;
|
||||
const r3 = value3 != null && !value3.dismissing;
|
||||
const rolling = value3?.rolling;
|
||||
const r6 = rolling != null && rolling;
|
||||
const binding = env0_3;
|
||||
binding.useEffect(_fun90814, [r3, value4, value5]);
|
||||
binding.useEffect(_fun90815, [r6, useReducedMotion, value6]);
|
||||
const reanimatedRexportModule = require(4017) /* metro dependency 4017: ReanimatedRexport */;
|
||||
let useAnimatedStyle = reanimatedRexportModule.useAnimatedStyle;
|
||||
let closure = DiceRollBarP;
|
||||
object2 = {useReducedMotion: useReducedMotion, height: value4, opacity: value5};
|
||||
object2.withTiming = (require(4504) /* metro dependency 4504: timing */).withTiming;
|
||||
object2.ANIMATION_DURATION_MS = 300;
|
||||
const DECELERATED_EASING = (require(1305) /* metro dependency 1305: native */).DECELERATED_EASING;
|
||||
object2.DECELERATED_EASING = DECELERATED_EASING;
|
||||
closure.__closure = object2;
|
||||
closure.__workletHash = 2405066513233;
|
||||
closure.__initData = env0_10;
|
||||
const value10 = Reflect.apply(useAnimatedStyle, reanimatedRexportModule, [closure]);
|
||||
const moduleValue6 = reanimatedRexportModule;
|
||||
useAnimatedStyle = moduleValue6.useAnimatedStyle;
|
||||
closure = DiceRollBarY;
|
||||
closure.__closure = {rotation: value6};
|
||||
closure.__workletHash = 12265072947874;
|
||||
closure.__initData = env0_11;
|
||||
const value11 = Reflect.apply(useAnimatedStyle, moduleValue6, [closure]);
|
||||
if (value3 == null) {
|
||||
return null;
|
||||
}
|
||||
const barText = (require(11851) /* metro dependency 11851: DiceRollUtils */).getBarText(r6, value3.results);
|
||||
const View2 = (importDefault(4017) /* metro dependency 4017: ReanimatedRexport */).View;
|
||||
const items2 = [value10];
|
||||
items2[1] = styles.animatedContainer;
|
||||
const View3 = (importDefault(4017) /* metro dependency 4017: ReanimatedRexport */).View;
|
||||
const DiceIcon = (require(11852) /* metro dependency 11852: DiceIcon */).DiceIcon;
|
||||
const view = <View3 style={value11}><DiceIcon size="md" /></View3>;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
return (
|
||||
<View2 style={items2}>
|
||||
<View style={styles.container}>
|
||||
{view}
|
||||
<Text variant="text-sm/normal" color="text-default">
|
||||
{barText}
|
||||
</Text>
|
||||
</View>
|
||||
</View2>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun90814() { // fn#90814, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12036:1352, offset: 0x02047965, size: 59 bytes, params: 1, frame: 14
|
||||
let binding = env0_1;
|
||||
const value2 = 0;
|
||||
binding.set(env0_4 ? 56 : value2);
|
||||
binding = env0_2;
|
||||
binding.set(env0_4 ? 1 : value2);
|
||||
}
|
||||
|
||||
function _fun90815() { // fn#90815, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12036:1408, offset: 0x020479a0, size: 172 bytes, params: 1, frame: 23
|
||||
var binding;
|
||||
var set;
|
||||
var withRepeat;
|
||||
var moduleValue;
|
||||
var withTiming;
|
||||
var object2;
|
||||
var value;
|
||||
if (env0_5) {
|
||||
if (useReducedMotion) {
|
||||
env0_3.set(0);
|
||||
} else {
|
||||
binding = env0_3;
|
||||
set = binding.set;
|
||||
value = environment.__proto__;
|
||||
value = require(4017) /* metro dependency 4017: ReanimatedRexport */;
|
||||
withRepeat = value.withRepeat;
|
||||
moduleValue = require(4504) /* metro dependency 4504: timing */;
|
||||
withTiming = moduleValue.withTiming;
|
||||
object2 = {duration: 800};
|
||||
object2.easing = (require(4017) /* metro dependency 4017: ReanimatedRexport */).Easing.linear;
|
||||
Reflect.apply(set, binding, [Reflect.apply(withRepeat, value, [Reflect.apply(withTiming, moduleValue, [360,
|
||||
object2]), -1, false])]);
|
||||
}
|
||||
} else {
|
||||
env0_3.set(0);
|
||||
}
|
||||
}
|
||||
|
||||
function DiceRollBarP() { // fn#90816, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12036:1579, owner: DiceRollBar.p, offset: 0x02047a4c, size: 210 bytes, params: 1, frame: 22
|
||||
var value2;
|
||||
var moduleValue;
|
||||
var withTiming;
|
||||
var binding;
|
||||
const DECELERATED_EASING = (require(1305) /* metro dependency 1305: native */).DECELERATED_EASING;
|
||||
var moduleValue2;
|
||||
const object2 = {};
|
||||
if (useReducedMotion) {
|
||||
binding = env0_1;
|
||||
object2.height = binding.get();
|
||||
binding = env0_2;
|
||||
object2.opacity = binding.get();
|
||||
} else {
|
||||
value2 = environment.__proto__;
|
||||
moduleValue = require(4504) /* metro dependency 4504: timing */;
|
||||
withTiming = moduleValue.withTiming;
|
||||
binding = env0_1;
|
||||
object2.height = Reflect.apply(withTiming, moduleValue, [binding.get(), {duration: 300,
|
||||
easing: DECELERATED_EASING}]);
|
||||
moduleValue2 = require(4504) /* metro dependency 4504: timing */;
|
||||
withTiming = moduleValue2.withTiming;
|
||||
binding = env0_2;
|
||||
object2.opacity = Reflect.apply(withTiming, moduleValue2, [binding.get(), {duration: 300,
|
||||
easing: DECELERATED_EASING}]);
|
||||
}
|
||||
return object2;
|
||||
}
|
||||
|
||||
function DiceRollBarY() { // fn#90817, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12036:2040, owner: DiceRollBar.y, offset: 0x02047b1e, size: 68 bytes, params: 1, frame: 15
|
||||
const object = {};
|
||||
object.rotate = '' + env0_3.get() + 'deg';
|
||||
return {transform: [object]};
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user