/* Metro module 7763; source: unknown; dependencies: [] */ function _fun62140(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#62140, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7941:6, offset: 0x01b584ad, size: 96 bytes, params: 8, frame: 16 const Object = global.Object; Object.defineProperty(exports, '__esModule', {value: true}); const regexp = RegExp('^rgba?\\(\\s*(100%|\\d{1,2}(\\.\\d+)?%)\\s*,\\s*(100%|\\d{1,2}(\\.\\d+)?%)\\s*,\\s*(100%|\\d{1,2}(\\.\\d+)?%)\\s*(?:,\\s*(1|0(\\.\\d+)?|100%|\\d{1,2}(\\.\\d+)?%)\\s*)?\\)$', ''); const percentTo255 = function(a0) { var Math = global.Math; return Math.round(2.55 * (0, global.parseFloat)(a0)); }; exports.RGB_RGBA_PATTERN = regexp; exports.convertPercentageColor = convertPercentageColor; } function parsePercentageRGBColor(a0) { // fn#62141, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7941:314, offset: 0x01b5850d, size: 277 bytes, params: 2, frame: 21 var r0; var property; var property2; var property3; var property4; var value3; var value4; var value5; var float; var value; const value2 = env0_0.exec(a0); if (value2) { property = value2[1]; property2 = value2[3]; property3 = value2[5]; property4 = value2[7]; value3 = percentTo255(property); value4 = percentTo255(property2); value = percentTo255(property3); value = '' + value3 + ', ' + value4 + ', ' + value; if (property4) { value5 = property4.endsWith('%'); float = global.parseFloat(property4); value = 'rgba(' + value + ', ' + (value5 ? float / 100 : float) + ')'; r0 = value; } else { value = 'rgb(' + value + ')'; r0 = value; } return r0; } global.console.warn('"' + a0 + '" is not a valid percentage rgb/rgba color'); return a0; } function convertPercentageColor(a0) { // fn#62143, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7941:673, offset: 0x01b58654, size: 81 bytes, params: 2, frame: 14 const value = a0; if (typeof value !== 'string') { return value; } const value2 = value.replace(RegExp('\\s', 'g'), ''); const binding = env0_0; return binding.test(value2) ? parsePercentageRGBColor(value2) : value; }