be-components 0.5.4 → 0.5.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (126) hide show
  1. package/lib/commonjs/Checkout/components/PayPalOrderCapture.js +3 -1
  2. package/lib/commonjs/Checkout/components/PayPalOrderCapture.js.map +1 -1
  3. package/lib/commonjs/Checkout/index.js +3 -2
  4. package/lib/commonjs/Checkout/index.js.map +1 -1
  5. package/lib/commonjs/Wallet/api/index.js +12 -8
  6. package/lib/commonjs/Wallet/api/index.js.map +1 -1
  7. package/lib/commonjs/Wallet/components/ACHAddCard.js +15 -3
  8. package/lib/commonjs/Wallet/components/ACHAddCard.js.map +1 -1
  9. package/lib/commonjs/Wallet/components/AccountLimitManager.js +1 -1
  10. package/lib/commonjs/Wallet/components/AccountLimitManager.js.map +1 -1
  11. package/lib/commonjs/Wallet/components/AccountManager.js +9 -4
  12. package/lib/commonjs/Wallet/components/AccountManager.js.map +1 -1
  13. package/lib/commonjs/Wallet/components/AccountSnoozeManager.js +1 -1
  14. package/lib/commonjs/Wallet/components/AccountSnoozeManager.js.map +1 -1
  15. package/lib/commonjs/Wallet/components/AddressManager.js +2 -2
  16. package/lib/commonjs/Wallet/components/AddressManager.js.map +1 -1
  17. package/lib/commonjs/Wallet/components/DepositCard.js +83 -26
  18. package/lib/commonjs/Wallet/components/DepositCard.js.map +1 -1
  19. package/lib/commonjs/Wallet/components/FundAccountCard.js +1 -1
  20. package/lib/commonjs/Wallet/components/FundAccountCard.js.map +1 -1
  21. package/lib/commonjs/Wallet/components/LinkAccountManager.js +111 -3
  22. package/lib/commonjs/Wallet/components/LinkAccountManager.js.map +1 -1
  23. package/lib/commonjs/Wallet/components/ManageAccountCard.js +1 -1
  24. package/lib/commonjs/Wallet/components/ManageAccountCard.js.map +1 -1
  25. package/lib/commonjs/Wallet/components/ManualACHAdd.js +1 -1
  26. package/lib/commonjs/Wallet/components/ManualACHAdd.js.map +1 -1
  27. package/lib/commonjs/Wallet/components/ManualCardAdd.js +1 -1
  28. package/lib/commonjs/Wallet/components/ManualCardAdd.js.map +1 -1
  29. package/lib/commonjs/Wallet/components/MyBalance.js +1 -1
  30. package/lib/commonjs/Wallet/components/MyBalance.js.map +1 -1
  31. package/lib/commonjs/Wallet/components/OrderManager.js +1 -2
  32. package/lib/commonjs/Wallet/components/OrderManager.js.map +1 -1
  33. package/lib/commonjs/Wallet/components/VerifyACHAccount.js +1 -1
  34. package/lib/commonjs/Wallet/components/VerifyACHAccount.js.map +1 -1
  35. package/lib/commonjs/Wallet/components/WalletActionSelector.js +29 -7
  36. package/lib/commonjs/Wallet/components/WalletActionSelector.js.map +1 -1
  37. package/lib/commonjs/Wallet/components/WalletSettings.js +1 -1
  38. package/lib/commonjs/Wallet/components/WalletSettings.js.map +1 -1
  39. package/lib/commonjs/Wallet/components/WalletSetup.js +7 -3
  40. package/lib/commonjs/Wallet/components/WalletSetup.js.map +1 -1
  41. package/lib/commonjs/Wallet/components/WithdrawCard.js +9 -4
  42. package/lib/commonjs/Wallet/components/WithdrawCard.js.map +1 -1
  43. package/lib/commonjs/Wallet/index.js +279 -58
  44. package/lib/commonjs/Wallet/index.js.map +1 -1
  45. package/lib/module/Checkout/components/PayPalOrderCapture.js +3 -1
  46. package/lib/module/Checkout/components/PayPalOrderCapture.js.map +1 -1
  47. package/lib/module/Checkout/index.js +3 -2
  48. package/lib/module/Checkout/index.js.map +1 -1
  49. package/lib/module/Wallet/api/index.js +12 -8
  50. package/lib/module/Wallet/api/index.js.map +1 -1
  51. package/lib/module/Wallet/components/ACHAddCard.js +16 -4
  52. package/lib/module/Wallet/components/ACHAddCard.js.map +1 -1
  53. package/lib/module/Wallet/components/AccountLimitManager.js +2 -2
  54. package/lib/module/Wallet/components/AccountLimitManager.js.map +1 -1
  55. package/lib/module/Wallet/components/AccountManager.js +10 -5
  56. package/lib/module/Wallet/components/AccountManager.js.map +1 -1
  57. package/lib/module/Wallet/components/AccountSnoozeManager.js +2 -2
  58. package/lib/module/Wallet/components/AccountSnoozeManager.js.map +1 -1
  59. package/lib/module/Wallet/components/AddressManager.js +3 -3
  60. package/lib/module/Wallet/components/AddressManager.js.map +1 -1
  61. package/lib/module/Wallet/components/DepositCard.js +84 -27
  62. package/lib/module/Wallet/components/DepositCard.js.map +1 -1
  63. package/lib/module/Wallet/components/FundAccountCard.js +2 -2
  64. package/lib/module/Wallet/components/FundAccountCard.js.map +1 -1
  65. package/lib/module/Wallet/components/LinkAccountManager.js +112 -4
  66. package/lib/module/Wallet/components/LinkAccountManager.js.map +1 -1
  67. package/lib/module/Wallet/components/ManageAccountCard.js +2 -2
  68. package/lib/module/Wallet/components/ManageAccountCard.js.map +1 -1
  69. package/lib/module/Wallet/components/ManualACHAdd.js +2 -2
  70. package/lib/module/Wallet/components/ManualACHAdd.js.map +1 -1
  71. package/lib/module/Wallet/components/ManualCardAdd.js +2 -2
  72. package/lib/module/Wallet/components/ManualCardAdd.js.map +1 -1
  73. package/lib/module/Wallet/components/MyBalance.js +2 -2
  74. package/lib/module/Wallet/components/MyBalance.js.map +1 -1
  75. package/lib/module/Wallet/components/OrderManager.js +2 -3
  76. package/lib/module/Wallet/components/OrderManager.js.map +1 -1
  77. package/lib/module/Wallet/components/VerifyACHAccount.js +2 -2
  78. package/lib/module/Wallet/components/VerifyACHAccount.js.map +1 -1
  79. package/lib/module/Wallet/components/WalletActionSelector.js +29 -7
  80. package/lib/module/Wallet/components/WalletActionSelector.js.map +1 -1
  81. package/lib/module/Wallet/components/WalletSettings.js +2 -2
  82. package/lib/module/Wallet/components/WalletSettings.js.map +1 -1
  83. package/lib/module/Wallet/components/WalletSetup.js +8 -4
  84. package/lib/module/Wallet/components/WalletSetup.js.map +1 -1
  85. package/lib/module/Wallet/components/WithdrawCard.js +10 -5
  86. package/lib/module/Wallet/components/WithdrawCard.js.map +1 -1
  87. package/lib/module/Wallet/index.js +279 -58
  88. package/lib/module/Wallet/index.js.map +1 -1
  89. package/lib/typescript/src/Checkout/components/PayPalOrderCapture.d.ts.map +1 -1
  90. package/lib/typescript/src/Checkout/index.d.ts.map +1 -1
  91. package/lib/typescript/src/Wallet/api/index.d.ts.map +1 -1
  92. package/lib/typescript/src/Wallet/components/ACHAddCard.d.ts.map +1 -1
  93. package/lib/typescript/src/Wallet/components/AccountManager.d.ts.map +1 -1
  94. package/lib/typescript/src/Wallet/components/DepositCard.d.ts.map +1 -1
  95. package/lib/typescript/src/Wallet/components/LinkAccountManager.d.ts.map +1 -1
  96. package/lib/typescript/src/Wallet/components/OrderManager.d.ts.map +1 -1
  97. package/lib/typescript/src/Wallet/components/WalletActionSelector.d.ts +1 -1
  98. package/lib/typescript/src/Wallet/components/WalletActionSelector.d.ts.map +1 -1
  99. package/lib/typescript/src/Wallet/components/WalletSetup.d.ts.map +1 -1
  100. package/lib/typescript/src/Wallet/components/WithdrawCard.d.ts.map +1 -1
  101. package/lib/typescript/src/Wallet/index.d.ts +5 -1
  102. package/lib/typescript/src/Wallet/index.d.ts.map +1 -1
  103. package/package.json +1 -1
  104. package/src/Checkout/components/PayPalOrderCapture.tsx +3 -1
  105. package/src/Checkout/index.tsx +4 -2
  106. package/src/Observer/api/types.d.ts +1 -1
  107. package/src/Wallet/api/index.ts +7 -7
  108. package/src/Wallet/components/ACHAddCard.tsx +10 -4
  109. package/src/Wallet/components/AccountLimitManager.tsx +3 -3
  110. package/src/Wallet/components/AccountManager.tsx +6 -5
  111. package/src/Wallet/components/AccountSnoozeManager.tsx +3 -3
  112. package/src/Wallet/components/AddressManager.tsx +4 -4
  113. package/src/Wallet/components/DepositCard.tsx +32 -9
  114. package/src/Wallet/components/FundAccountCard.tsx +3 -3
  115. package/src/Wallet/components/LinkAccountManager.tsx +47 -4
  116. package/src/Wallet/components/ManageAccountCard.tsx +3 -3
  117. package/src/Wallet/components/ManualACHAdd.tsx +3 -3
  118. package/src/Wallet/components/ManualCardAdd.tsx +3 -3
  119. package/src/Wallet/components/MyBalance.tsx +3 -3
  120. package/src/Wallet/components/OrderManager.tsx +3 -4
  121. package/src/Wallet/components/VerifyACHAccount.tsx +3 -3
  122. package/src/Wallet/components/WalletActionSelector.tsx +18 -4
  123. package/src/Wallet/components/WalletSettings.tsx +3 -3
  124. package/src/Wallet/components/WalletSetup.tsx +4 -2
  125. package/src/Wallet/components/WithdrawCard.tsx +6 -4
  126. package/src/Wallet/index.tsx +133 -50
@@ -1,5 +1,5 @@
1
1
  import React, { useState } from 'react';
2
- import { View, TouchableOpacity } from "react-native";
2
+ import { View, TouchableOpacity, ScrollView } from "react-native";
3
3
  import { Button, Checkbox, Text, TextInput } from '../../Components';
4
4
  import type { MyPlayerProps } from '../../ProfileManager/api/types';
5
5
  import Colors from '../../constants/colors';
@@ -47,7 +47,7 @@ const ManualACHAdd = ({ player, onAddAccount, onCancel }:ManualACHAddProps) => {
47
47
  <Text size={26} color={Colors.brand.midnight} weight='bold'>MANUAL ACH ACCOUNT</Text>
48
48
  <Text style={{ marginTop:10 }} size={16} color={Colors.brand.midnight} weight='regular'>Complete the form below to add a new ACH account. Once submitted, we will send 2 small deposits to the account to confirm ownership. This process can take up to 3 business days.</Text>
49
49
  </View>
50
- <View style={{ flex:1, padding:20 }}>
50
+ <ScrollView style={{ flex:1, padding:20 }}>
51
51
  <View style={{ marginTop:10 }}>
52
52
  <Text size={14} color={Colors.brand.midnight} weight='semibold'>Name on account</Text>
53
53
  <TextInput
@@ -100,7 +100,7 @@ const ManualACHAdd = ({ player, onAddAccount, onCancel }:ManualACHAddProps) => {
100
100
  <Text style={{ marginTop:5 }} size={14} color={Colors.utility.warning}>Account Number Is Not Valid</Text>
101
101
  :<></>}
102
102
  </View>
103
- </View>
103
+ </ScrollView>
104
104
  <View>
105
105
  <TouchableOpacity style={{ flexDirection:'row', alignItems:'center', paddingLeft:20, paddingRight:20 }} onPress={() => setDisclaimer(!disclaimer)}>
106
106
  <Checkbox size={30} checked={disclaimer} disabled onSelect={() => console.log('')}/>
@@ -1,5 +1,5 @@
1
1
  import React, { useState } from 'react';
2
- import { View, StyleSheet } from "react-native";
2
+ import { View, StyleSheet, ScrollView } from "react-native";
3
3
  import type { MyPlayerProps } from '../../ProfileManager/api/types';
4
4
  import { WalletApi, WalletHelpers } from '../api';
5
5
  import { Button, Icons, Text, TextInput } from '../../Components';
@@ -69,7 +69,7 @@ const ManualCardAdd = ({ player, onAddAccount, onCancel }:ManualCardAddProps) =>
69
69
  <Text size={26} color={Colors.brand.midnight} weight='bold'>NEW CARD ACCOUNT</Text>
70
70
  <Text style={{ marginTop:10 }} size={16} color={Colors.brand.midnight} weight='regular'>Complete the form below to add a new card account. Once successfully added, you can transact immediately.</Text>
71
71
  </View>
72
- <View style={{ flex:1, padding:10, margin:10 }}>
72
+ <ScrollView style={{ flex:1, padding:10, margin:10 }}>
73
73
  <View nativeID='cc_input' style={{ marginTop:10 }}>
74
74
  <View nativeID='card_number' style={{ padding:5 }}>
75
75
  <View style={{ flexDirection:'row', alignItems:'center', padding:10 }}>
@@ -146,7 +146,7 @@ const ManualCardAdd = ({ player, onAddAccount, onCancel }:ManualCardAddProps) =>
146
146
  <Text size={14} color={Colors.utility.warning} weight='semibold'>Expiration date is not valid</Text>
147
147
  :<></>}
148
148
  </View>
149
- </View>
149
+ </ScrollView>
150
150
  {error ?
151
151
  <View style={{ padding:10 }}>
152
152
  <Text size={16} color={Colors.utility.warning} weight='bold' textAlign='center'>{error}</Text>
@@ -1,5 +1,5 @@
1
1
  import React from 'react';
2
- import { View, TouchableOpacity } from "react-native"
2
+ import { View, TouchableOpacity, ScrollView } from "react-native"
3
3
  import type { MyPlayerProps, PlayerBalanceProps } from '../../ProfileManager/api/types';
4
4
  import type { AccountProps } from '../../types';
5
5
  import { Button, Icons, Text } from '../../Components';
@@ -24,7 +24,7 @@ const MyBalance = ({ player_balance, onClose, onNext }:MyBalanceProps) => {
24
24
  <Text size={26} color={Colors.brand.midnight} weight='bold'>BETTOREDGE BALANCES</Text>
25
25
  <Text style={{ marginTop:10 }} size={16} color={Colors.brand.midnight} weight='regular'>All order and competition activity goes in and out of your BettorEdge balances. The specific balance depends on which app-mode you are in.</Text>
26
26
  </View>
27
- <View style={{ flex:1, padding:10 }}>
27
+ <ScrollView style={{ flex:1, padding:10 }}>
28
28
  <View style={{ padding:10, paddingBottom:0 }}>
29
29
  <Text size={18} color={Colors.brand.midnight} weight='bold' textAlign='left'>APP MODES</Text>
30
30
  </View>
@@ -62,7 +62,7 @@ const MyBalance = ({ player_balance, onClose, onNext }:MyBalanceProps) => {
62
62
  <Text size={16} weight='bold' color={Colors.shades.white}>E{player_balance.free_market_balance.toFixed(2)}</Text>
63
63
  </View>
64
64
  </View>
65
- </View>
65
+ </ScrollView>
66
66
  <View nativeID='action_row' style={{ flexDirection:'row', justifyContent:'space-between', padding:10 }}>
67
67
  <Button
68
68
  title='EXIT SETUP'
@@ -1,5 +1,5 @@
1
1
  import React, { useEffect, useState } from 'react';
2
- import { FlatList, View, ActivityIndicator } from 'react-native';
2
+ import { FlatList, View, ActivityIndicator, ScrollView } from 'react-native';
3
3
  import { ItemOrderApi } from '../api';
4
4
  import type { ItemOrderProps, ItemProps } from '../../types';
5
5
  import ItemOrderCard from './ItemOrderCard';
@@ -30,7 +30,6 @@ const OrderManager = ({ onClose }:OrderManagerProps) => {
30
30
 
31
31
  const getDataFromServer = async(offset:number) => {
32
32
  setLoading(true);
33
- console.log(offset)
34
33
  const my_orders = await ItemOrderApi.getMyItemOrders(offset);
35
34
  setData({
36
35
  items:my_orders.items,
@@ -55,7 +54,7 @@ const OrderManager = ({ onClose }:OrderManagerProps) => {
55
54
  <Text size={26} color={Colors.brand.midnight} weight='bold'>ORDER HISTORY</Text>
56
55
  <Text style={{ marginTop:10 }} size={16} color={Colors.brand.midnight} weight='regular'>Review your order history below. Select an item to see the transaction details.</Text>
57
56
  </View>
58
- <View style={{ flex:1, padding:10 }}>
57
+ <ScrollView style={{ flex:1, padding:10 }}>
59
58
  {loading ?
60
59
  <ActivityIndicator size='large' color={Colors.brand.midnight} />
61
60
  :<></>}
@@ -64,7 +63,7 @@ const OrderManager = ({ onClose }:OrderManagerProps) => {
64
63
  renderItem={renderItemOrders}
65
64
  keyExtractor={(item) => item.item_order_id.toString()}
66
65
  />
67
- </View>
66
+ </ScrollView>
68
67
  <View style={{ flexDirection:'row', alignItems:'center', padding:20, paddingBottom:0 }}>
69
68
  <Button
70
69
  style={{ opacity: offset > 0 ? 1 : 0.5 }}
@@ -1,5 +1,5 @@
1
1
  import React, { useState } from 'react';
2
- import { View } from 'react-native';
2
+ import { View, ScrollView } from 'react-native';
3
3
  import { Button, Text, TextInput } from '../../Components';
4
4
  import Colors from '../../constants/colors';
5
5
  import { WalletApi, WalletHelpers } from '../api';
@@ -59,7 +59,7 @@ const VerifyACHAccount = ({ account, onClose, onUpdateAccount }:VerifyACHWidgetP
59
59
  <Text size={26} color={Colors.brand.midnight} weight='bold'>VERIFY ACCOUNT</Text>
60
60
  <Text style={{ marginTop:10 }} size={16} color={Colors.brand.midnight} weight='regular'>Verify this account by entering the two deposit amounts received from Bettoredge when setting up the account.</Text>
61
61
  </View>
62
- <View nativeID='verify_inputs' style={{ flex:1, margin:20 }}>
62
+ <ScrollView nativeID='verify_inputs' style={{ flex:1, margin:20 }}>
63
63
  <View style={{marginTop:30}}>
64
64
  <Text textAlign='center' size={16} color={Colors.brand.midnight} weight='semibold'>Deposit 1</Text>
65
65
  <TextInput
@@ -88,7 +88,7 @@ const VerifyACHAccount = ({ account, onClose, onUpdateAccount }:VerifyACHWidgetP
88
88
  <Text style={{ marginTop:10 }} textAlign='center' size={14} color={Colors.utility.warning} weight='bold'>{error}</Text>
89
89
  :<></>}
90
90
 
91
- </View>
91
+ </ScrollView>
92
92
  {account.status == 'verify' ?
93
93
  <View nativeID='verify_actions' style={{ flexDirection:'row', padding:20 }}>
94
94
  <Button
@@ -14,7 +14,7 @@ type WalletActionSelectorProps ={
14
14
  onClose: () => void,
15
15
  walkthrough_steps:any[],
16
16
  onActionSelect:(action:any, account?:AccountProps) => void,
17
- onStartWalkthrough:(walkthrough:any) => void
17
+ onStartWalkthrough:(walkthrough:any, account?:AccountProps) => void
18
18
  }
19
19
 
20
20
  const sections = [
@@ -56,8 +56,8 @@ const WalletActionSelector = ({ player, walkthrough_steps, player_balance, accou
56
56
  if(!default_account){ default_account = accounts.find(a => a.account_type == 'paypal')}
57
57
  return onActionSelect(action, default_account)
58
58
  case 'withdraw':
59
- let withdraw_account = accounts.find(a => !a.ibt_placeholder && a.account_type == 'ach')
60
- if(!withdraw_account){ return onActionSelect({ action: 'add_ach_account' }) }
59
+ let withdraw_account = accounts.find(a => !a.ibt_placeholder && a.account_type == 'ach' && a.status == 'active')
60
+ if(!withdraw_account){ return onActionSelect({ action: 'ach_add' }) }
61
61
  return onActionSelect(action, withdraw_account)
62
62
  default: onActionSelect(action)
63
63
  }
@@ -99,11 +99,25 @@ const WalletActionSelector = ({ player, walkthrough_steps, player_balance, accou
99
99
  )
100
100
  }
101
101
 
102
+ const handleStepSelect = (step:any, index:number) => {
103
+ console.log(step)
104
+ switch(step.step){
105
+ case 'deposit':
106
+ let default_account = accounts.find(a => a.default_account)
107
+ if(!default_account){ default_account = accounts.find(a => a.account_type == 'paypal') }
108
+ if(!default_account){ return }
109
+ return onStartWalkthrough({ enabled:true, steps: walkthrough_steps, active_step: step.step, next_step: walkthrough_steps[index + 1]?.step}, default_account)
110
+ default:
111
+ return onStartWalkthrough({ enabled:true, steps: walkthrough_steps, active_step: step.step, next_step: walkthrough_steps[index + 1]?.step})
112
+ }
113
+
114
+ }
115
+
102
116
  const renderSteps = (data: { item:any, index:number }) => {
103
117
  return (
104
118
  <TouchableOpacity
105
119
  style={{ margin:5, padding:10, flexDirection:'row', alignItems:'center', borderWidth:1, borderColor:Colors.shades.shade600, borderRadius:8 }}
106
- onPress={() => onStartWalkthrough({ enabled:true, steps: walkthrough_steps, active_step: data.item.step })}>
120
+ onPress={() => handleStepSelect(data.item, data.index)}>
107
121
  <Icons.CheckCirlceIcon size={14} color={data.item.complete?Colors.utility.success:Colors.brand.slate}/>
108
122
  <Text style={{ flex:1, marginLeft:10 }} size={14} color={Colors.brand.midnight}>{data.item.label}</Text>
109
123
  <Icons.ChevronIcon direction='right' size={8} color={Colors.brand.midnight} />
@@ -2,7 +2,7 @@ import React from 'react';
2
2
  import { useState } from "react"
3
3
  import type { MyPlayerProps } from '../../ProfileManager/api/types';
4
4
  import type { PlayerDepositLimitProps, PlayerReferralProps, PlayerWithdrawLimitProps, PromoProps } from '../../types';
5
- import { View, TouchableOpacity } from 'react-native';
5
+ import { View, TouchableOpacity, ScrollView } from 'react-native';
6
6
  import { Button, Icons, Text } from '../../Components';
7
7
  import Colors from '../../constants/colors';
8
8
  import { WalletHelpers } from '../api';
@@ -57,7 +57,7 @@ const WalletSettings = ({ player, my_referral, deposit_limit, withdraw_limit, on
57
57
  <Text weight={active_tab == 'referral'?'bold':'regular'} textAlign="center" size={14} color={active_tab=='referral'?Colors.shades.white:Colors.brand.midnight}>Referral</Text>
58
58
  </TouchableOpacity>
59
59
  </View>
60
- <View nativeID="settings" style={{ flex:1, marginLeft:10, marginRight:10, borderRightWidth:1, borderLeftWidth:1, borderBottomWidth:1, borderColor:Colors.shades.shade600 }}>
60
+ <ScrollView nativeID="settings" style={{ flex:1, marginLeft:10, marginRight:10, borderRightWidth:1, borderLeftWidth:1, borderBottomWidth:1, borderColor:Colors.shades.shade600 }}>
61
61
  {active_tab == 'deposit' ?
62
62
  <View>
63
63
  {deposit_limit ?
@@ -197,7 +197,7 @@ const WalletSettings = ({ player, my_referral, deposit_limit, withdraw_limit, on
197
197
  :<></>}
198
198
  </View>
199
199
  :<></>}
200
- </View>
200
+ </ScrollView>
201
201
  {false && player?.type == 'freemium' ?
202
202
  <View style={{ backgroundColor:Colors.shades.shade600, borderRadius:8, padding:10, margin:10 }}>
203
203
  <Text size={14} color={Colors.brand.midnight} weight='semibold' textAlign="center">Want better limits and higher referral awards?</Text>
@@ -1,5 +1,5 @@
1
1
  import React, { useState } from 'react';
2
- import { View, Image, TouchableOpacity, Linking } from "react-native";
2
+ import { View, Image, TouchableOpacity, Linking, ScrollView } from "react-native";
3
3
  import type { WalletSettingsProps } from '../../types';
4
4
  import { Button, Checkbox, Icons, Text, TextInput } from '../../Components';
5
5
  import Colors from '../../constants/colors';
@@ -64,6 +64,7 @@ const WalletSetup = ({ wallet_settings, onSettingsUpdate, onClose, onNext }:Wall
64
64
  <Text style={{ marginTop:10 }} size={16} color={Colors.brand.midnight} weight='regular'>Welcome to your wallet. Please enter your security pin to continue!</Text>
65
65
  }
66
66
  </View>
67
+ <ScrollView style={{ flex:1 }}>
67
68
  {!wallet_settings.agreed_to_terms ?
68
69
  <View style={{ flex:1, padding:20 }}>
69
70
  <View>
@@ -170,7 +171,8 @@ const WalletSetup = ({ wallet_settings, onSettingsUpdate, onClose, onNext }:Wall
170
171
  </View>
171
172
  </View>
172
173
  }
173
- <View style={{ flexDirection:'row', padding:10 }}>
174
+ </ScrollView>
175
+ <View style={{ flexDirection:'row', padding:20 }}>
174
176
  {!wallet_settings.agreed_to_terms && onClose ?
175
177
  <View style={{ flex:1, flexDirection:'row' }}>
176
178
  <Button
@@ -1,5 +1,5 @@
1
1
  import React, { useEffect, useState } from 'react';
2
- import { ActivityIndicator, View } from "react-native";
2
+ import { ActivityIndicator, View, ScrollView } from "react-native";
3
3
  import type { AccountProps, ItemOrderProps, PlayerDepositLimitProps, PlayerWithdrawLimitProps, WalletSettingsProps } from '../../types';
4
4
  import { ItemOrderApi, ItemOrderHelpers } from '../api';
5
5
  import type { MyPlayerProps, PlayerBalanceProps } from '../../ProfileManager/api/types';
@@ -50,13 +50,14 @@ const WithdrawCard = ({ wallet_settings, onTransact, player_balance, account, wi
50
50
 
51
51
 
52
52
  let balance = Math.floor(player_balance.balance * 100) / 100
53
-
53
+ let limit_available = withdraw_limit.ach_daily_limit - withdraw_limit.last_days_ach_withdraws
54
54
  return (
55
55
  <View style={{ flex:1 }}>
56
56
  <View nativeID='deposit_rules' style={{ padding:10 }}>
57
57
  <Text size={28} textAlign='center' weight='bold' color={Colors.brand.midnight}>Withdraw to your bank</Text>
58
58
  <Text style={{ marginTop:10 }} size={14} textAlign='center' weight='regular' color={Colors.brand.midnight}>Withdraws can take up to 3 business days</Text>
59
59
  </View>
60
+ <ScrollView style={{ flex:1 }}>
60
61
  <View style={{ flex:1 }}>
61
62
  <View nativeID='deposit_amount' style={{ justifyContent:'center', alignItems:'center', padding:20 }}>
62
63
  <TextInput
@@ -73,7 +74,7 @@ const WithdrawCard = ({ wallet_settings, onTransact, player_balance, account, wi
73
74
  </View>
74
75
  <View style={{ flexDirection:'row', alignItems:'center', padding:10, paddingTop:0 }}>
75
76
  <Text style={{ flex:1 }} size={14} color={Colors.brand.midnight} weight='semibold'>Available For Withdraw</Text>
76
- <Text size={14} color={Colors.brand.midnight} weight='bold'>{available_for_withdraw.toFixed(2)}</Text>
77
+ <Text size={14} color={Colors.brand.midnight} weight='bold'>{Math.min(available_for_withdraw, limit_available).toFixed(2)}</Text>
77
78
  </View>
78
79
  <View style={{ marginTop:5, borderRadius:8, padding:10, backgroundColor:Colors.shades.shade600 }}>
79
80
  <Text size={14} color={Colors.brand.midnight} textAlign='left' weight='semibold'>Determined by the LESSER OF</Text>
@@ -103,7 +104,7 @@ const WithdrawCard = ({ wallet_settings, onTransact, player_balance, account, wi
103
104
  </View>
104
105
  <View style={{ padding:5, flexDirection:'row', alignItems:'center' , borderTopWidth:1, borderTopColor:Colors.shades.shade600 }}>
105
106
  <Text style={{ flex:1 }} size={14} color={Colors.brand.midnight} weight='bold'>Limit Available</Text>
106
- <Text size={14} color={Colors.brand.midnight} weight='bold'>${(withdraw_limit.ach_daily_limit - withdraw_limit.last_days_ach_withdraws).toFixed(2)}</Text>
107
+ <Text size={14} color={Colors.brand.midnight} weight='bold'>${(limit_available).toFixed(2)}</Text>
107
108
  </View>
108
109
  </View>
109
110
  </View>
@@ -118,6 +119,7 @@ const WithdrawCard = ({ wallet_settings, onTransact, player_balance, account, wi
118
119
  </View>
119
120
  :<></>}
120
121
  </View>
122
+ </ScrollView>
121
123
  <View nativeID='action_row' style={{ flexDirection:'row', padding:20 }}>
122
124
  <Button
123
125
  style={{ flex:1, marginRight:5, opacity: 1 }}