Files
2026-07-28 01:06:53 +03:00

181 lines
9.9 KiB
TypeScript

/* Metro module 9181; source: components_native/QRCode.tsx; dependencies: [29, 6, 7, 15, 17, 18, 31, 27, 33, 4501, 697, 9182, 4564, 3868, 9193, 8670, 2] */
import ClassCallCheck from '../by-id/module-00006-ClassCallCheck.js'; /* Metro dependency 6 */
import CreateClass from '../by-id/module-00007-CreateClass.js'; /* Metro dependency 7 */
import PossibleConstructorReturn from '../by-id/module-00015-PossibleConstructorReturn.js'; /* Metro dependency 15 */
import Module00017 from '../by-id/module-00017.js'; /* Metro dependency 17 */
import Inherits from '../by-id/module-00018-Inherits.js'; /* Metro dependency 18 */
import ObjectWithoutProperties from '../by-id/module-00029-ObjectWithoutProperties.js'; /* Metro dependency 29 */
import * as FileImportTrackerModule from '../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
import * as ReactModule from '../by-id/module-00031-React.js'; /* Metro dependency 31 */
import * as JsxRuntimeModule from '../by-id/module-00033-JsxRuntime.js'; /* Metro dependency 33 */
import * as NativeModule from '../external/discord_common/js/packages/design/native.tsx'; /* Metro dependency 3868 */
import * as CreateStylesModule from '../design/components/Styles/native/createStyles.tsx'; /* Metro dependency 4501 */
function _fun71942(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#71942, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9366:6, offset: 0x01d3277d, size: 719 bytes, params: 8, frame: 24
const env0_0 = require;
const env0_3 = ['style', 'text', 'blur', 'accessibilityLabel'];
let Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
let value = ReactModule;
const createLegacyClassComponentStyles = CreateStylesModule.createLegacyClassComponentStyles;
const object2 = {'display': 'flex', 'alignSelf': 'flex-start'};
const PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
object2.padding = PX_8;
object2.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.xs;
const env0_15 = Reflect.apply(createLegacyClassComponentStyles, CreateStylesModule, [{qrCode: object2,
qrCodeContainer: {'display': 'flex', 'alignSelf': 'flex-start', 'alignItems': 'center',
'justifyContent': 'center', 'position': 'relative'}, qrCodeOverlay: {'display': 'flex', 'alignItems': 'center',
'justifyContent': 'center'}, ['size-40']: {'width': 40, 'height': 40}, ['size-60']: {'width': 60,
'height': 60}}]);
object = {SIZE_40: 'SIZE_40', SIZE_60: 'SIZE_60'};
Object = global.Object;
const freeze = Object.freeze;
const SIZE_40 = object.SIZE_40;
const SIZE_60 = object.SIZE_60;
const value5 = Reflect.apply(freeze, Object, [{[SIZE_40]: 'size-40', [SIZE_60]: 'size-60'}]);
let PureComponent = value.PureComponent;
const value6 = _fun71947(PureComponent);
const ThemeContext = (NativeModule).ThemeContext;
value6.contextType = ThemeContext;
value6.defaultProps = {'size': 128, 'bgColor': '#ffffff', 'fgColor': '#000000'};
PureComponent = value.PureComponent;
value = _fun71950(PureComponent);
value.contextType = ThemeContext;
value.defaultProps = {'size': 144, 'bgColor': '#ffffff', 'fgColor': '#000000'};
(FileImportTrackerModule).fileFinishedImporting('components_native/QRCode.tsx');
exports.default = value6;
exports.QRCodeOverlaySizes = object;
exports.QR_CODE_OVERLAY_SIZE_MAP = value5;
exports.QRCodeWithOverlay = value;
function _callSuper_71943(a0, a1, a2) { // fn#71943, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9366:290, offset: 0x01d32a4c, size: 100 bytes, params: 4, frame: 20
var r0;
var Reflect;
let value = a2;
const value3 = Module00017(a1);
if (_isNativeReflectConstruct_71944()) {
Reflect = global.Reflect;
value = Reflect.construct(value3, value || [], Module00017(a0).constructor);
r0 = value;
} else {
value = value3.apply(a0, value);
r0 = value;
}
return PossibleConstructorReturn(a0, r0);
}
function _isNativeReflectConstruct_71944() { // fn#71944, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9366:421, offset: 0x01d32ab0, 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_71944_isNativeReflectConstruct = function() {
return !!result;
})();
}
function _fun71947(a0) { // fn#71947, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9366:1160, offset: 0x01d32b12, size: 72 bytes, params: 2, frame: 15
const QRCode2 = QRCode;
Inherits(QRCode2, a0);
return CreateClass(QRCode2, [{key: 'render', value: value_71949}]);
function QRCode() { // fn#71948, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9366:1172, offset: 0x01d32b5a, size: 42 bytes, params: 1, frame: 16
env1_5(this, QRCode);
return _callSuper_71943(this, QRCode, arguments);
}
function value_71949() { // fn#71949, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9366:1295, offset: 0x01d32b84, size: 313 bytes, params: 1, frame: 23
const value = environment.__proto__;
const value2 = env1_15(this.context);
const props = this.props;
const style = props.style;
const text = props.text;
const blur = props.blur;
const accessibilityLabel = props.accessibilityLabel;
const value3 = env1_4(props, env1_3);
const value4 = null;
return (
<View
accessible={value4 != accessibilityLabel}
accessibilityRole="image"
accessibilityLabel={accessibilityLabel}
style={[value2.qrCode, {backgroundColor: value3.bgColor}, style]}
>
<View style={{position: 'relative', width: value3.size, height: value3.size}}>
{((Component) => <Component value={text} level="M" {...value3} />)(importDefault(9182) /* metro dependency 9182 */)}
{
blur
? ((Component) => <Component style={StyleSheet.absoluteFill} blurTheme="dark" />)(importDefault(4564) /* metro dependency 4564: VisualEffectView */)
: value4
}
</View>
</View>
);
}
}
function _fun71950(a0) { // fn#71950, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9366:1832, offset: 0x01d32cbd, size: 72 bytes, params: 2, frame: 15
const QRCodeWithOverlay2 = QRCodeWithOverlay;
Inherits(QRCodeWithOverlay2, a0);
return CreateClass(QRCodeWithOverlay2, [{key: 'render', value: value_71952}]);
function QRCodeWithOverlay() { // fn#71951, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9366:1844, offset: 0x01d32b5a, size: 42 bytes, params: 1, frame: 16
env1_5(this, QRCodeWithOverlay);
return _callSuper_71943(this, QRCodeWithOverlay, arguments);
}
function value_71952() { // fn#71952, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9366:2022, offset: 0x01d32d05, size: 289 bytes, params: 1, frame: 24
const value = environment.__proto__;
let binding = env1_15;
const value2 = binding(this.context);
const {overlaySize, blur} = this.props;
binding = env1_17;
const value3 = null;
const property = binding[value3 != overlaySize ? overlaySize : env1_16.SIZE_40];
const qrCodeContainer = value2.qrCodeContainer;
const items2 = [
((Component) => <Component {...this.props} {...{['blur']: false}} />)(env1_18),
];
items2[1] = (
<View style={[value2.qrCodeOverlay, StyleSheet.absoluteFill]}>
<Image style={value2[property]} source={require(9193) /* metro dependency 9193 */} />
</View>
);
items2[2] = (
blur
? ((Component) => <Component style={StyleSheet.absoluteFill} />)(importDefault(8670) /* metro dependency 8670: VisualEffectViewThemed */)
: value3
);
return (
<View style={qrCodeContainer}>
{items2}
</View>
);
}
}
}
global.__d(_fun71942, 9181, [29, 6, 7, 15, 17, 18, 31, 27, 33, 4501, 697, 9182, 4564, 3868, 9193, 8670,
2]) /* metro module 9181, dependencies: [29, 6, 7, 15, 17, 18, 31, 27, 33, 4501, 697, 9182, 4564, 3868, 9193, 8670, 2] */;