Initial commit
This commit is contained in:
commit
af3b49f756
16065 files changed
+2938410
No files matched your search
@@ -0,0 +1,75 @@
|
||||
/* Metro module 6994; source: design/components/TextField/native/BaseTextField.native.tsx; dependencies: [31, 33, 477, 1357, 6992, 3865, 6995, 3864, 2] */
|
||||
function _fun55416(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#55416, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7172:6, offset: 0x013a699b, size: 156 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = importAll(31) /* metro dependency 31 */;
|
||||
const value2 = require(33) /* metro dependency 33 */;
|
||||
const env0_3 = value2.jsx;
|
||||
const env0_4 = value2.jsxs;
|
||||
value = value.forwardRef(_fun55417);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('design/components/TextField/native/BaseTextField.native.tsx');
|
||||
exports.BaseTextField = value;
|
||||
}
|
||||
|
||||
function _fun55417(a0, a1) { // fn#55417, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7172:153, offset: 0x013a6a37, size: 561 bytes, params: 3, frame: 24
|
||||
var r14;
|
||||
var secureTextEntry;
|
||||
var keyboardType;
|
||||
var r2;
|
||||
var r10;
|
||||
var autoComplete;
|
||||
var isAndroid2;
|
||||
var isAndroid3;
|
||||
const value2 = (importDefault(1357) /* metro dependency 1357: MobileVisualRefreshExperiment */)('InputFieldContainer');
|
||||
const inputFieldContainerNativeModule = require(6992) /* metro dependency 6992: InputFieldContainerNative */;
|
||||
const useInputStyles = inputFieldContainerNativeModule.useInputStyles;
|
||||
let object2 = {};
|
||||
object2.size = a0.size;
|
||||
object2.isRound = a0.isRound;
|
||||
const leadingIcon = a0.leadingIcon;
|
||||
const value3 = null;
|
||||
object2.hasLeadingIcon = value3 != leadingIcon;
|
||||
object2.isRefreshEnabled = value2;
|
||||
const value4 = Reflect.apply(useInputStyles, inputFieldContainerNativeModule, [object2]);
|
||||
const {focusProps, isFocused} = (require(3865) /* metro dependency 3865: useFocusNative */).useFocus();
|
||||
if (a0.enableAndroidSanitizedInputWorkaround) {
|
||||
secureTextEntry = a0.secureTextEntry;
|
||||
keyboardType = a0.keyboardType;
|
||||
autoComplete = a0.autoComplete;
|
||||
secureTextEntry = !(secureTextEntry === undefined) && secureTextEntry;
|
||||
keyboardType = keyboardType === undefined ? 'default' : keyboardType;
|
||||
object2 = {};
|
||||
isAndroid2 = (require(477) /* metro dependency 477: PlatformUtils */).isAndroid();
|
||||
r2 = isAndroid2 ? 'off' : autoComplete;
|
||||
object2.autoComplete = r2;
|
||||
isAndroid3 = (require(477) /* metro dependency 477: PlatformUtils */).isAndroid();
|
||||
r2 = isAndroid3 ? !!isAndroid3 : secureTextEntry;
|
||||
object2.secureTextEntry = r2;
|
||||
r2 = (require(477) /* metro dependency 477: PlatformUtils */).isAndroid() ? 'visible-password' : keyboardType;
|
||||
object2.keyboardType = r2;
|
||||
r10 = object2;
|
||||
r14 = isAndroid2;
|
||||
} else {
|
||||
r10 = value3;
|
||||
}
|
||||
const InputFieldContainer = inputFieldContainerNativeModule.InputFieldContainer;
|
||||
const inputFieldContainerProps = {...a0};
|
||||
inputFieldContainerProps['isFocused'] = isFocused;
|
||||
const leading = a0.leading;
|
||||
const NativeTextInput = (require(6995) /* metro dependency 6995: NativeTextInputNative */).NativeTextInput;
|
||||
const nativeTextInputProps = {...r10};
|
||||
const value = require(3864) /* metro dependency 3864: mergePropsNative */;
|
||||
copyDataProperties(nativeTextInputProps, value.mergeProps(a0, focusProps), r14);
|
||||
nativeTextInputProps['ref'] = a1;
|
||||
nativeTextInputProps['style'] = [value4.padding, value4.text, a0.inputStyle];
|
||||
nativeTextInputProps['placeholderTextColor'] = value4.placeholderText.color;
|
||||
return (
|
||||
<InputFieldContainer {...inputFieldContainerProps}>
|
||||
{leading}
|
||||
<NativeTextInput {...nativeTextInputProps} />
|
||||
{a0.trailing}
|
||||
</InputFieldContainer>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,29 @@
|
||||
/* Metro module 6984; source: design/components/TextField/native/SearchField.native.tsx; dependencies: [31, 33, 6985, 1244, 6998, 2] */
|
||||
function _fun55374(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#55374, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7162:6, offset: 0x013a4f37, size: 140 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = importAll(31) /* metro dependency 31 */;
|
||||
const env0_2 = (require(33) /* metro dependency 33 */).jsx;
|
||||
value = value.forwardRef(_fun55375);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('design/components/TextField/native/SearchField.native.tsx');
|
||||
exports.SearchField = value;
|
||||
}
|
||||
|
||||
function _fun55375(a0, a1) { // fn#55375, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7162:136, offset: 0x013a4fc3, size: 194 bytes, params: 3, frame: 18
|
||||
const TextField = (require(6985) /* metro dependency 6985: TextFieldNative */).TextField;
|
||||
const object2 = {};
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
object2.placeholder = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['5h0QOP']);
|
||||
object2.returnKeyType = 'search';
|
||||
object2.ref = a1;
|
||||
copyDataProperties(object2, a0, intl);
|
||||
object2['autoCorrect'] = false;
|
||||
object2['autoCapitalize'] = 'none';
|
||||
object2['accessibilityRole'] = 'search';
|
||||
const MagnifyingGlassIcon = (require(6998) /* metro dependency 6998: MagnifyingGlassIcon */).MagnifyingGlassIcon;
|
||||
object2['leadingIcon'] = MagnifyingGlassIcon;
|
||||
object2['isClearable'] = true;
|
||||
return <TextField {...object2} />;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,78 @@
|
||||
/* Metro module 7687; source: design/components/TextField/native/TextAreaField.native.tsx; dependencies: [31, 27, 33, 4501, 697, 6992, 6986, 3862, 7688, 1244, 6995, 4573, 2] */
|
||||
function _fun61368(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#61368, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7865:6, offset: 0x01b3d186, size: 294 bytes, params: 8, frame: 23
|
||||
const env0_0 = require;
|
||||
const getLengthRemainingTextColor = function(a0, a1) {
|
||||
var value = 'text-muted';
|
||||
return a0 == null || a1 == null ? value : a1 <= 0 ? 'text-feedback-critical' : a1 < a0 / 9 ? 'text-feedback-warning' : value;
|
||||
};
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = importAll(31) /* metro dependency 31 */;
|
||||
const env0_2 = (require(27) /* metro dependency 27 */).View;
|
||||
const value2 = require(33) /* metro dependency 33 */;
|
||||
const env0_3 = value2.jsx;
|
||||
const env0_4 = value2.jsxs;
|
||||
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = createStylesModule.createStyles;
|
||||
const object = {position: 'absolute'};
|
||||
const PX_4 = (importDefault(697) /* metro dependency 697: native */).space.PX_4;
|
||||
object.bottom = PX_4;
|
||||
const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
|
||||
object.right = PX_16;
|
||||
const env0_5 = Reflect.apply(createStyles, createStylesModule, [{area: {'height': 128, 'textAlignVertical': 'top'},
|
||||
maxLengthIndicator: object}]);
|
||||
value = value.forwardRef(_fun61370);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('design/components/TextField/native/TextAreaField.native.tsx');
|
||||
exports.TextAreaField = value;
|
||||
}
|
||||
|
||||
function _fun61370(a0, a1) { // fn#61370, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7865:481, offset: 0x01b3d2f9, size: 651 bytes, params: 3, frame: 32
|
||||
var object4;
|
||||
var r4;
|
||||
var Text;
|
||||
const value2 = undefined;
|
||||
const value3 = (require(6992) /* metro dependency 6992: InputFieldContainerNative */).useInputStyles({'size': 'lg',
|
||||
'isRound': false, isDisabled: a0.isDisabled});
|
||||
const styles = useStyles();
|
||||
const maxLength = a0.maxLength;
|
||||
const {inputProps, innerRef,
|
||||
state} = (require(6986) /* metro dependency 6986: useTextFieldNative */).useTextField(a0, a1);
|
||||
const {focusProps, isFocused} = (require(3862) /* metro dependency 3862: native */).useFocus();
|
||||
const value6 = null;
|
||||
const r11 = value6 != maxLength ? maxLength - state.value.length : value2;
|
||||
const useCharacterLimitAnnouncementModule = require(7688) /* metro dependency 7688: useCharacterLimitAnnouncement */;
|
||||
const useCharacterLimitAnnouncement = useCharacterLimitAnnouncementModule.useCharacterLimitAnnouncement;
|
||||
object4 = {currentLength: state.value.length, maxLength: maxLength};
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
object4.message = intl.string((require(1244) /* metro dependency 1244: indexNative */).t.c2Jqed);
|
||||
Reflect.apply(useCharacterLimitAnnouncement, useCharacterLimitAnnouncementModule, [object4]);
|
||||
const InputFieldContainer = (require(6992) /* metro dependency 6992: InputFieldContainerNative */).InputFieldContainer;
|
||||
const inputFieldContainerProps = {...a0};
|
||||
inputFieldContainerProps['isFocused'] = isFocused;
|
||||
const NativeTextInput = (require(6995) /* metro dependency 6995: NativeTextInputNative */).NativeTextInput;
|
||||
const object3 = {};
|
||||
const nativeModule = require(3862) /* metro dependency 3862: native */;
|
||||
copyDataProperties(object3, nativeModule.mergeProps(inputProps, focusProps), intl);
|
||||
object3['ref'] = innerRef;
|
||||
object3['style'] = [value3.padding, value3.text, styles.area];
|
||||
object3['placeholderTextColor'] = value3.placeholderText.color;
|
||||
object3['multiline'] = true;
|
||||
const nativeTextInput = <NativeTextInput {...object3} />;
|
||||
if (value6 == r11) {
|
||||
r4 = value6;
|
||||
} else {
|
||||
var viewBindingProps = {style: styles.maxLengthIndicator};
|
||||
Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
r4 = <View {...viewBindingProps}><Text variant="text-xs/semibold" color={getLengthRemainingTextColor(maxLength,
|
||||
r11)} accessibilityLabel={intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t.fR1cof,
|
||||
|
||||
{remainingCharacters: r11})}>{r11}</Text></View>;
|
||||
}
|
||||
return (
|
||||
<InputFieldContainer {...inputFieldContainerProps}>
|
||||
{nativeTextInput}
|
||||
{r4}
|
||||
</InputFieldContainer>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,34 @@
|
||||
/* Metro module 6985; source: design/components/TextField/native/TextField.native.tsx; dependencies: [31, 33, 6986, 6987, 6991, 6994, 2] */
|
||||
function _fun55376(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#55376, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7163:6, offset: 0x013a5085, size: 140 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = importAll(31) /* metro dependency 31 */;
|
||||
const env0_2 = (require(33) /* metro dependency 33 */).jsx;
|
||||
value = value.forwardRef(_fun55377);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('design/components/TextField/native/TextField.native.tsx');
|
||||
exports.TextField = value;
|
||||
}
|
||||
|
||||
function _fun55377(a0, a1) { // fn#55377, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7163:136, offset: 0x013a5111, size: 249 bytes, params: 3, frame: 19
|
||||
const value2 = undefined;
|
||||
const value3 = (require(6986) /* metro dependency 6986: useTextFieldNative */).useTextField(a0, a1);
|
||||
const innerRef = value3.innerRef;
|
||||
const inputProps = value3.inputProps;
|
||||
const value4 = (require(6987) /* metro dependency 6987: useInputClearButtonNative */).useInputClearButtonConfig(a0,
|
||||
value3.state);
|
||||
const {leading, trailing,
|
||||
inputStyle} = (require(6991) /* metro dependency 6991: useInputAttachmentsNative */).useInputAttachments(a0,
|
||||
value4 != null ? {trailing: value4.content, trailingPressableProps: value4.pressableProps} : value2);
|
||||
const BaseTextField = (require(6994) /* metro dependency 6994: BaseTextFieldNative */).BaseTextField;
|
||||
return (
|
||||
<BaseTextField
|
||||
{...inputProps}
|
||||
{...{['ref']: innerRef}}
|
||||
{...{['leading']: leading}}
|
||||
{...{['trailing']: trailing}}
|
||||
{...{['inputStyle']: inputStyle}}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,150 @@
|
||||
/* Metro module 6986; source: design/components/TextField/native/useTextField.native.tsx; dependencies: [57, 31, 4570, 2] */
|
||||
function _fun55378(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#55378, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:6, offset: 0x013a520a, size: 148 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const closure = useTextFieldState;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_2 = importDefault(57) /* metro dependency 57 */;
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('design/components/TextField/native/useTextField.native.tsx');
|
||||
exports.useTextFieldState = closure;
|
||||
exports.useTextField = useTextField;
|
||||
}
|
||||
|
||||
function useTextFieldState({value, defaultValue, onChange, onClear}) { // fn#55379, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:116, offset: 0x013a529e, size: 211 bytes, params: 2, frame: 20
|
||||
let binding = env0_3;
|
||||
const useState = binding.useState;
|
||||
let r4 = value ?? defaultValue ?? '';
|
||||
const value5 = env0_2(Reflect.apply(useState, binding, [r4]), 2);
|
||||
const property = value5[0];
|
||||
var env0_2 = value5[1];
|
||||
r4 = value ?? property;
|
||||
value = r4.length > 0;
|
||||
binding = env0_3;
|
||||
let useCallback = binding.useCallback;
|
||||
const value6 = Reflect.apply(useCallback, binding, [_fun55380, [onChange]]);
|
||||
var env0_3 = value6;
|
||||
binding = env0_3;
|
||||
useCallback = binding.useCallback;
|
||||
return {value: r4, setTextValue: value6, clear: Reflect.apply(useCallback, binding, [_fun55381, [value6, onClear]]),
|
||||
hasValue: value};
|
||||
}
|
||||
|
||||
function useTextField(a0, a1) { // fn#55382, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:587, offset: 0x013a53bd, size: 257 bytes, params: 3, frame: 19
|
||||
var object3;
|
||||
const env0_0 = a0;
|
||||
const value2 = env0_3.useRef(null);
|
||||
const value3 = env0_3.useCallback(_fun55383, [value2, a0.onClear]);
|
||||
object3 = {};
|
||||
copyDataProperties(object3, a0, undefined);
|
||||
object3['onClear'] = value3;
|
||||
const value4 = useTextFieldState(object3);
|
||||
env0_3.useImperativeHandle(a1, function() {
|
||||
return {blur: _fun55385, focus: _fun55386, isFocused: _fun55387, getText: _fun55388, setText: _fun55389,
|
||||
measure: _fun55390, measureInWindow: _fun55391, measureLayout: _fun55392};
|
||||
}, [value2, value4]);
|
||||
object3 = {innerRef: value2, state: value4};
|
||||
const object4 = {};
|
||||
copyDataProperties(object4, a0, undefined);
|
||||
object4['onChange'] = undefined;
|
||||
object4['onChangeText'] = value4.setTextValue;
|
||||
object4['editable'] = !a0.isDisabled;
|
||||
object4['focusable'] = !a0.isDisabled && a0.focusable;
|
||||
object4['aria-disabled'] = a0.isDisabled;
|
||||
object3.inputProps = object4;
|
||||
return object3;
|
||||
}
|
||||
|
||||
function _fun55380(a0) { // fn#55380, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:312, offset: 0x013a5371, size: 38 bytes, params: 2, frame: 13
|
||||
env0_2(a0);
|
||||
if (onChange != null) {
|
||||
onChange(a0);
|
||||
}
|
||||
}
|
||||
|
||||
function _fun55381() { // fn#55381, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:359, offset: 0x013a5397, size: 38 bytes, params: 1, frame: 12
|
||||
env0_3('');
|
||||
if (onClear != null) {
|
||||
onClear();
|
||||
}
|
||||
}
|
||||
|
||||
function _fun55383() { // fn#55383, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:652, offset: 0x013a54be, size: 96 bytes, params: 1, frame: 13
|
||||
const current = env0_1.current;
|
||||
if (current != null) {
|
||||
current.clear();
|
||||
}
|
||||
const onClear = env0_0.onClear;
|
||||
if (onClear != null) {
|
||||
onClear();
|
||||
}
|
||||
const setAccessibilityFocusAndroidModule = require(4570) /* metro dependency 4570: setAccessibilityFocusAndroid */;
|
||||
setAccessibilityFocusAndroidModule.setAccessibilityFocus({ref: env0_1});
|
||||
}
|
||||
|
||||
function _fun55384() { // fn#55384, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:849, offset: 0x013a551e, size: 86 bytes, params: 1, frame: 3
|
||||
return {blur: blur_55385, focus: focus_55386, isFocused: isFocused_55387, getText: getText_55388,
|
||||
setText: setText_55389, measure: measure_55390, measureInWindow: measureInWindow_55391,
|
||||
measureLayout: measureLayout_55392};
|
||||
}
|
||||
|
||||
function blur_55385() { // fn#55385, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:860, offset: 0x013a5574, size: 32 bytes, params: 1, frame: 9
|
||||
const current = env1_1.current;
|
||||
if (current != null) {
|
||||
current.blur();
|
||||
}
|
||||
}
|
||||
|
||||
function focus_55386() { // fn#55386, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:908, offset: 0x013a5594, size: 32 bytes, params: 1, frame: 9
|
||||
const current = env1_1.current;
|
||||
if (current != null) {
|
||||
current.focus();
|
||||
}
|
||||
}
|
||||
|
||||
function isFocused_55387() { // fn#55387, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:961, offset: 0x013a55b4, size: 41 bytes, params: 1, frame: 10
|
||||
const value = environment.__proto__;
|
||||
return env1_1.current?.isFocused() === true;
|
||||
}
|
||||
|
||||
function getText_55388() { // fn#55388, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:1035, offset: 0x013a55dd, size: 14 bytes, params: 1, frame: 1
|
||||
return env1_2.value;
|
||||
}
|
||||
|
||||
function setText_55389(a0) { // fn#55389, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:1055, offset: 0x013a55eb, size: 84 bytes, params: 2, frame: 14
|
||||
var value;
|
||||
var current;
|
||||
if (a0 === '') {
|
||||
value = environment.__proto__;
|
||||
env1_2.clear();
|
||||
} else {
|
||||
value = environment.__proto__;
|
||||
current = env1_1.current;
|
||||
if (current != null) {
|
||||
current.setNativeProps({text: a0});
|
||||
}
|
||||
env1_2.setTextValue(a0);
|
||||
}
|
||||
}
|
||||
|
||||
function measure_55390(a0) { // fn#55390, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:1159, offset: 0x013a563f, size: 36 bytes, params: 2, frame: 11
|
||||
const current = env1_1.current;
|
||||
if (current != null) {
|
||||
current.measure(a0);
|
||||
}
|
||||
}
|
||||
|
||||
function measureInWindow_55391(a0) { // fn#55391, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:1220, offset: 0x013a5663, size: 36 bytes, params: 2, frame: 11
|
||||
const current = env1_1.current;
|
||||
if (current != null) {
|
||||
current.measureInWindow(a0);
|
||||
}
|
||||
}
|
||||
|
||||
function measureLayout_55392(a0, a1, a2) { // fn#55392, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7164:1287, offset: 0x013a5687, size: 44 bytes, params: 4, frame: 15
|
||||
const current = env1_1.current;
|
||||
if (current != null) {
|
||||
current.measureLayout(a0, a1, a2);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user