/* Metro module 6766; source: modules/a11y/native/TextWithIOSLinkWorkaround.tsx; dependencies: [31, 27, 33, 4501, 6767, 4559, 4573, 477, 2] */ 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 PlatformUtilsModule from '../../../utils/PlatformUtils.tsx'; /* Metro dependency 477 */ import * as CreateStylesModule from '../../../design/components/Styles/native/createStyles.tsx'; /* Metro dependency 4501 */ import * as UseIsScreenReaderEnabledNativeModule from './useIsScreenReaderEnabled.native.tsx'; /* Metro dependency 4559 */ import * as TextModule from '../../../design/components/Text/native/Text.tsx'; /* Metro dependency 4573 */ import * as MigrationModule from '../../../intl/native/migration.tsx'; /* Metro dependency 6767 */ function _fun53296(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#53296, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6944:6, offset: 0x013448cb, size: 219 bytes, params: 8, frame: 19 const env0_0 = require; const Object = global.Object; Object.defineProperty(exports, '__esModule', {value: true}); const env0_6 = (CreateStylesModule).createStyles({column: {'flexDirection': 'column', 'flexShrink': 1}}); (FileImportTrackerModule).fileFinishedImporting('modules/a11y/native/TextWithIOSLinkWorkaround.tsx'); exports.TextWithIOSLinkWorkaround = TextWithIOSLinkWorkaround; function findLinks(a0) { // fn#53297, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6944:219, offset: 0x013449a6, size: 67 bytes, params: 2, frame: 12 const Children = ReactModule.Children; const value2 = Children.toArray(a0); return value2.filter(ReactModule.isValidElement).flatMap(_fun53298); function _fun53298(a0) { // fn#53298, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6944:304, offset: 0x013449e9, size: 115 bytes, params: 2, frame: 14 const type = a0.type; const value = environment.__proto__; const I18nLinkComponent = (MigrationModule).I18nLinkComponent; if (type === I18nLinkComponent || a0.props.accessibilityRole === 'link') { return [a0]; } const props = a0.props; return props.children != null ? findLinks(props.children) : []; } } function TextWithIOSLinkWorkaround(a0) { // fn#53299, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:6944:606, offset: 0x01344a5c, size: 202 bytes, params: 2, frame: 21 const children = a0.children; let value = Object.create(null); value.children = 0; const value2 = copyDataProperties({}, a0, value, undefined); const styles = useStyles(); const value4 = (UseIsScreenReaderEnabledNativeModule).useIsScreenReaderEnabled(); const Text = (TextModule).Text; value = ( {children} ); if (PlatformUtilsModule.isIOS()) { if (value4) { return ( {value} {findLinks(children)} ); } } return value; } } global.__d(_fun53296, 6766, [31, 27, 33, 4501, 6767, 4559, 4573, 477, 2]) /* metro module 6766, dependencies: [31, 27, 33, 4501, 6767, 4559, 4573, 477, 2] */;