Files
discord-decomp/sources/by-id/module-00141-createReactNativeDocument.js
2026-07-28 01:06:53 +03:00

108 lines
6.1 KiB
JavaScript

/* Metro module 141; source: unknown; dependencies: [6, 7, 15, 17, 18, 132, 134, 137, 142, 138, 136] */
import ClassCallCheck from './module-00006-ClassCallCheck.js'; /* Metro dependency 6 */
import CreateClass from './module-00007-CreateClass.js'; /* Metro dependency 7 */
import PossibleConstructorReturn from './module-00015-PossibleConstructorReturn.js'; /* Metro dependency 15 */
import Module00017 from './module-00017.js'; /* Metro dependency 17 */
import Inherits from './module-00018-Inherits.js'; /* Metro dependency 18 */
import GetChildNodes from './module-00134-getChildNodes.js'; /* Metro dependency 134 */
import GetRawNativeDOMForTests from './module-00138-getRawNativeDOMForTests.js'; /* Metro dependency 138 */
import * as Module00136Module from './module-00136.js'; /* Metro dependency 136 */
import * as Module00137Module from './module-00137.js'; /* Metro dependency 137 */
function _fun2292(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#2292, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:166:6, offset: 0x00c7cff8, size: 193 bytes, params: 8, frame: 18
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
let value = GetChildNodes;
value = _fun2296(value);
exports.default = value;
exports.createReactNativeDocument = createReactNativeDocument;
function _isNativeReflectConstruct_2293() { // fn#2293, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:166:148, offset: 0x00c7d0b9, size: 94 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_2293_isNativeReflectConstruct = function() {
return !!result;
})();
}
function _fun2296(a0) { // fn#2296, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:166:373, offset: 0x00c7d117, size: 256 bytes, params: 2, frame: 16
const ReactNativeDocument2 = ReactNativeDocument;
Inherits(ReactNativeDocument2, a0);
return CreateClass(ReactNativeDocument2, [{key: 'childElementCount', get: function() {
return 1;
}}, {key: 'children', get: get_2299}, {key: 'documentElement', get: function() {
return this._documentElement;
}}, {key: 'firstElementChild', get: function() {
return this.documentElement;
}}, {key: 'lastElementChild', get: function() {
return this.documentElement;
}}, {key: 'nodeName', get: function() {
return '#document';
}}, {key: 'nodeType', get: function() {
return importDefault(dependencyMap[6]).DOCUMENT_NODE;
}}, {key: 'nodeValue', get: function() {
return null;
}}, {key: 'textContent', get: function() {
return null;
}}]);
function ReactNativeDocument(a0, a1) { // fn#2297, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:166:385, offset: 0x00c7d217, size: 273 bytes, params: 3, frame: 23
let value = environment.__proto__;
env1_3(this, ReactNativeDocument);
const items2 = [a1, null];
const value3 = env1_6(ReactNativeDocument);
const value6 = env1_5(this, _isNativeReflectConstruct_2293() ? global.Reflect.construct(value3, items2,
env1_6(this).constructor) : value3.apply(this, items2));
const reactNativeDocumentElementInstanceHandle = (Module00137Module).createReactNativeDocumentElementInstanceHandle();
value = importDefault(142) /* metro dependency 142 */;
value = new value(a0, null, reactNativeDocumentElementInstanceHandle, value6);
(Module00137Module).setNativeElementReferenceForReactNativeDocumentElementInstanceHandle(reactNativeDocumentElementInstanceHandle,
(GetRawNativeDOMForTests).linkRootNode(a0, reactNativeDocumentElementInstanceHandle));
(Module00137Module).setPublicInstanceForReactNativeDocumentElementInstanceHandle(reactNativeDocumentElementInstanceHandle,
value);
value6._documentElement = value;
return value6;
}
function get_2299() { // fn#2299, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:166:1113, offset: 0x00c7d32d, size: 55 bytes, params: 1, frame: 12
let value = environment.__proto__;
value = require(132) /* metro dependency 132 */;
return value.createHTMLCollection([this.documentElement]);
}
}
function createReactNativeDocument(a0) { // fn#2307, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:166:1687, offset: 0x00c7d3a3, size: 68 bytes, params: 2, frame: 14
const reactNativeDocumentInstanceHandle = (Module00136Module).createReactNativeDocumentInstanceHandle(a0);
const binding = env0_8;
const value = Object.create(binding.prototype, {constructor: {value: binding}});
const binding2 = new binding(a0, reactNativeDocumentInstanceHandle);
return binding2 instanceof Object ? binding2 : value;
}
}
global.__d(_fun2292, 141, [6, 7, 15, 17, 18, 132, 134, 137, 142, 138,
136]) /* metro module 141, dependencies: [6, 7, 15, 17, 18, 132, 134, 137, 142, 138, 136] */;