125 lines
7.3 KiB
TypeScript
125 lines
7.3 KiB
TypeScript
/* Metro module 14220; source: modules/mfa/native/components/ClipboardCopyInput.tsx; dependencies: [5, 31, 27, 7030, 661, 33, 4501, 566, 8994, 5459, 6797, 7981, 2] */
|
|
import Module00005 from '../../../../by-id/module-00005.js'; /* Metro dependency 5 */
|
|
import AppStateStore from '../../../../stores/native/AppStateStore.tsx'; /* Metro dependency 7030 */
|
|
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 ConstantsModule from '../../../../Constants.tsx'; /* Metro dependency 661 */
|
|
import * as CreateStylesModule from '../../../../design/components/Styles/native/createStyles.tsx'; /* Metro dependency 4501 */
|
|
import * as TextInputNativeModule from '../../../../design/components/TextInput/native/TextInput.native.tsx'; /* Metro dependency 7981 */
|
|
|
|
function _fun107527(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#107527, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14417:6, offset: 0x022ffaad, size: 264 bytes, params: 8, frame: 19
|
|
const env0_0 = require;
|
|
const Object = global.Object;
|
|
Object.defineProperty(exports, '__esModule', {value: true});
|
|
const env0_9 = (CreateStylesModule).createStyles({inputContainer: {'flexDirection': 'column',
|
|
'alignSelf': 'stretch'}});
|
|
(FileImportTrackerModule).fileFinishedImporting('modules/mfa/native/components/ClipboardCopyInput.tsx');
|
|
exports.default = ClipboardCopyInput;
|
|
function ClipboardCopyInput({label, placeholder, isValidClipboardCode, maxLength, onChangeCode, error, textContentType, autoComplete, keyboardType, isDisabled, autoFocus}) { // fn#107528, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14417:358, offset: 0x022ffbb5, size: 403 bytes, params: 2, frame: 32
|
|
autoFocus = autoFocus === undefined || autoFocus;
|
|
const styles = useStyles();
|
|
let env0_0 = ReactModule.useRef(null);
|
|
const value2 = ReactModule.useRef(null);
|
|
ReactModule.useEffect(function() {
|
|
var env0_0 = _fun107531;
|
|
if (state === AppStates.ACTIVE) {
|
|
_fun107536();
|
|
}
|
|
}, [(require(566) /* metro dependency 566: flux */).useStateFromStores([AppStateStore], function() {
|
|
return AppStateStore.getState();
|
|
}), (importDefault(8994) /* metro dependency 8994: useStableCallback */)(isValidClipboardCode),
|
|
(importDefault(8994) /* metro dependency 8994: useStableCallback */)(onChangeCode)]);
|
|
const TextInput = (TextInputNativeModule).TextInput;
|
|
return (
|
|
<View style={styles.inputContainer}>
|
|
<TextInput
|
|
ref={value2}
|
|
autoFocus={autoFocus}
|
|
autoCorrect={false}
|
|
autoCapitalize="none"
|
|
errorMessage={error}
|
|
maxLength={maxLength}
|
|
onChange={onChangeCode}
|
|
label={label}
|
|
accessibilityLabel={label}
|
|
placeholder={placeholder}
|
|
isClearable
|
|
textContentType={textContentType}
|
|
autoComplete={autoComplete}
|
|
keyboardType={keyboardType}
|
|
isDisabled={isDisabled}
|
|
/>
|
|
</View>
|
|
);
|
|
function _fun107530() { // fn#107530, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14417:688, offset: 0x022ffd48, size: 54 bytes, params: 1, frame: 10
|
|
const stateBinding = state;
|
|
const ACTIVE = AppStates.ACTIVE;
|
|
if (stateBinding === ACTIVE) {
|
|
(function() {
|
|
return _run.apply(this, arguments);
|
|
})();
|
|
}
|
|
function _run() { // fn#107531, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14417:693, offset: 0x022ffd7e, size: 53 bytes, params: 1, frame: 13
|
|
var environment;
|
|
const value = environment.__proto__.__proto__;
|
|
return env2_3(_fun107533).apply(this, arguments);
|
|
function* _fun107533() { // fn#107533, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14417:724, offset: 0x022ffdbe, size: 240 bytes, params: 1, frame: 16
|
|
var environment;
|
|
if (true) {
|
|
var Promise = global.Promise;
|
|
var promise = new Promise(function(a0) {
|
|
return (0, global.setTimeout)(a0, 500);
|
|
});
|
|
yield promise;
|
|
if (false) {
|
|
return undefined;
|
|
}
|
|
Promise = global.Promise;
|
|
promise = new Promise(_fun107535);
|
|
yield promise;
|
|
if (false) {
|
|
return undefined;
|
|
}
|
|
promise = environment.__proto__.__proto__.__proto__.__proto__;
|
|
promise = env4_0(env4_2[10]);
|
|
var getString = promise.getString;
|
|
yield Reflect.apply(getString, promise, []);
|
|
if (false) {
|
|
return undefined;
|
|
}
|
|
promise = promise.trim();
|
|
var current = require.current;
|
|
if (promise !== current) {
|
|
require.current = promise;
|
|
if (env3_3(promise)) {
|
|
current = importDefault.current;
|
|
if (current != null) {
|
|
current.setText(promise);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
function _fun107535(a0) { // fn#107535, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14417:803, offset: 0x022ffec9, size: 41 bytes, params: 2, frame: 11
|
|
const value = environment.__proto__.__proto__.__proto__.__proto__.__proto__;
|
|
return env5_0(env5_2[9]).runAfterInteractions(a0);
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
function run_107536() { // fn#107536, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14417:993, offset: 0x00c3945f, size: 30 bytes, params: 1, frame: 13
|
|
return _run.apply(this, arguments);
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
global.__d(_fun107527, 14220, [5, 31, 27, 7030, 661, 33, 4501, 566, 8994, 5459, 6797, 7981,
|
|
2]) /* metro module 14220, dependencies: [5, 31, 27, 7030, 661, 33, 4501, 566, 8994, 5459, 6797, 7981, 2] */;
|