/* Metro module 13420; source: modules/parent_tools/native/ChangeSpendingLimitModal.tsx; dependencies: [5, 31, 27, 33, 4501, 697, 8129, 4573, 1244, 2224, 13421, 3857, 4073, 5080, 3856, 5137, 6258, 6259, 4572, 7981, 10120, 6261, 4578, 5282, 10121, 2] */ function _fun102109(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#102109, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13610:6, offset: 0x0222d270, size: 449 bytes, params: 8, frame: 24 var object3; const env0_0 = require; const Object = global.Object; Object.defineProperty(exports, '__esModule', {value: true}); const env0_3 = importDefault(5) /* metro dependency 5 */; const env0_4 = importAll(31) /* metro dependency 31 */; let value = require(27) /* metro dependency 27 */; const StyleSheet = value.StyleSheet; const env0_5 = value.View; value = require(33) /* metro dependency 33 */; const env0_6 = value.jsx; const env0_7 = value.jsxs; value = require(4501) /* metro dependency 4501: createStyles */; const createStyles = value.createStyles; object3 = {}; const object4 = {}; copyDataProperties(object4, StyleSheet.absoluteFillObject, undefined); const INPUT_FIELD_RADIUS_LG = (importDefault(697) /* metro dependency 697: native */).modules.mobile.INPUT_FIELD_RADIUS_LG; object4['borderRadius'] = INPUT_FIELD_RADIUS_LG; object4['borderWidth'] = 1; let ICON_FEEDBACK_WARNING = (importDefault(697) /* metro dependency 697: native */).colors.ICON_FEEDBACK_WARNING; object4['borderColor'] = ICON_FEEDBACK_WARNING; const BACKGROUND_FEEDBACK_WARNING = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_FEEDBACK_WARNING; object4['backgroundColor'] = BACKGROUND_FEEDBACK_WARNING; object3.warningOverlay = object4; const PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8; object3.warningRow = {'flexDirection': 'row', 'gap': null, 'alignItems': 'flex-start', gap: PX_8}; ICON_FEEDBACK_WARNING = (importDefault(697) /* metro dependency 697: native */).colors.ICON_FEEDBACK_WARNING; object3.warningText = {flex: 1, color: ICON_FEEDBACK_WARNING}; const env0_8 = Reflect.apply(createStyles, value, [object3]); (require(2) /* metro dependency 2 */).fileFinishedImporting('modules/parent_tools/native/ChangeSpendingLimitModal.tsx'); exports.default = ChangeSpendingLimitModal; } function renderMonthlySpendLine(a0, a1, a2, a3) { // fn#102110, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13610:568, offset: 0x0222d431, size: 388 bytes, params: 5, frame: 25 var r1; var r0; const Text = (require(4573) /* metro dependency 4573: Text */).Text; const intl = (require(1244) /* metro dependency 1244: indexNative */).intl; var items2; const value = null; if (value == a0) { r0 = value; } else { if (a1) { var viewBindingProps = {style: a3.warningRow}; items2 = [((WarningIcon) => )((require(8129) /* metro dependency 8129: WarningIcon */).WarningIcon)]; items2[1] = {intl.formatToPlainString((importDefault(2224) /* metro dependency 2224: FamilyCenterMessages */).Tk6x4X, {amount: a0, date: a2})}; r1 = {items2}; } else { r1 = {intl.formatToPlainString((importDefault(2224) /* metro dependency 2224: FamilyCenterMessages */).pfAlRY, {amount: a0})}; } r0 = r1; } return r0; } function ChangeSpendingLimitScreen({teenId}) { // fn#102111, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13610:1016, offset: 0x0222d5b5, size: 1295 bytes, params: 2, frame: 54 var r11; var object; var object2; const styles = useStyles(); const value3 = (require(13421) /* metro dependency 13421: ChangeSpendingLimitFormState */).useChangeSpendingLimitFormState(teenId); const amountInput = value3.amountInput; const handleAmountChange = value3.handleAmountChange; const currency = value3.currency; const currencySymbol = value3.currencySymbol; const exponent = value3.exponent; const isClearingCap = value3.isClearingCap; const isOverspending = value3.isOverspending; const canSave = value3.canSave; const isSubmitting = value3.isSubmitting; const renewalDate = value3.renewalDate; const monthlySpend = value3.monthlySpend; const env0_0 = value3.save; const value4 = _fun102112(); const r22 = monthlySpend != null && monthlySpend > 0 ? (require(5137) /* metro dependency 5137: PriceUtils */).formatPrice(monthlySpend, currency) : null; const value7 = amountInput.length > 0; const ModalScreen = (require(6258) /* metro dependency 6258: ModalScreenNative */).ModalScreen; const ModalContent = (require(6259) /* metro dependency 6259: ModalContentNative */).ModalContent; const Stack = (require(4572) /* metro dependency 4572: StackNative */).Stack; const PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16; const Text = (require(4573) /* metro dependency 4573: Text */).Text; const intl = (require(1244) /* metro dependency 1244: indexNative */).intl; let string = intl.string; const IFguF2 = (importDefault(2224) /* metro dependency 2224: FamilyCenterMessages */).IFguF2; const text = {Reflect.apply(string, intl, [IFguF2])}; const Stack2 = (require(4572) /* metro dependency 4572: StackNative */).Stack; const PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8; const items2 = [{(require(1244) /* metro dependency 1244: indexNative */).intl.string((importDefault(2224) /* metro dependency 2224: FamilyCenterMessages */)['1fHSu2'])}]; const TextInput = (require(7981) /* metro dependency 7981: TextInputNative */).TextInput; const textInputProps = {accessibilityLabel: (require(1244) /* metro dependency 1244: indexNative */).intl.string((importDefault(2224) /* metro dependency 2224: FamilyCenterMessages */)['1fHSu2']), value: amountInput, onChange: handleAmountChange, leadingText: value7 ? currencySymbol : undefined}; string = intl.string; const DjSv82 = (importDefault(2224) /* metro dependency 2224: FamilyCenterMessages */).DjSv82; textInputProps.placeholder = Reflect.apply(string, intl, [DjSv82]); textInputProps.keyboardType = exponent > 0 ? 'decimal-pad' : 'number-pad'; textInputProps.isClearable = true; items2[1] = {isOverspending ? : null}; items2[2] = renderMonthlySpendLine(r22, isOverspending, renewalDate, styles); const modalContent = {text}{items2}; const ModalFooter = (require(10120) /* metro dependency 10120: ModalFooterNative */).ModalFooter; const ButtonGroup = (require(6261) /* metro dependency 6261: ButtonGroupNative */).ButtonGroup; const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button; if (isClearingCap) { object2 = {variant: 'destructive'}; object2.text = intl.string((importDefault(2224) /* metro dependency 2224: FamilyCenterMessages */).JZDGJ8); object2.onPress = value4; object2.disabled = isSubmitting; object2.loading = isSubmitting; r11 = object2; } else { object = {}; object.text = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['R3BPH+']); object.onPress = value4; object.disabled = canSave ? isSubmitting : !canSave; object.loading = isSubmitting; r11 = object; } return ( {modalContent}