be-components 0.3.3 → 0.3.4
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.
- package/lib/commonjs/ApiOverrides/index.js +4 -0
- package/lib/commonjs/ApiOverrides/index.js.map +1 -1
- package/lib/commonjs/Components/Icons.js +50 -0
- package/lib/commonjs/Components/Icons.js.map +1 -1
- package/lib/commonjs/Components/ImageUploader.js +10 -1
- package/lib/commonjs/Components/ImageUploader.js.map +1 -1
- package/lib/commonjs/Components/LinearDiagnal.js +82 -0
- package/lib/commonjs/Components/LinearDiagnal.js.map +1 -0
- package/lib/commonjs/ProfileManager/Components/BasicInfoManager.js +81 -32
- package/lib/commonjs/ProfileManager/Components/BasicInfoManager.js.map +1 -1
- package/lib/commonjs/ProfileManager/Components/BasicStatus.js +89 -20
- package/lib/commonjs/ProfileManager/Components/BasicStatus.js.map +1 -1
- package/lib/commonjs/ProfileManager/Components/DOBManager.js +55 -33
- package/lib/commonjs/ProfileManager/Components/DOBManager.js.map +1 -1
- package/lib/commonjs/ProfileManager/Components/EmailManager.js +69 -34
- package/lib/commonjs/ProfileManager/Components/EmailManager.js.map +1 -1
- package/lib/commonjs/ProfileManager/Components/PasswordManager.js +47 -25
- package/lib/commonjs/ProfileManager/Components/PasswordManager.js.map +1 -1
- package/lib/commonjs/ProfileManager/Components/PhoneManager.js +70 -35
- package/lib/commonjs/ProfileManager/Components/PhoneManager.js.map +1 -1
- package/lib/commonjs/ProfileManager/Components/ProfilePicManager.js +45 -29
- package/lib/commonjs/ProfileManager/Components/ProfilePicManager.js.map +1 -1
- package/lib/commonjs/ProfileManager/Components/ProfileWelcome.js +59 -17
- package/lib/commonjs/ProfileManager/Components/ProfileWelcome.js.map +1 -1
- package/lib/commonjs/ProfileManager/Components/ProfileWizard.js +54 -28
- package/lib/commonjs/ProfileManager/Components/ProfileWizard.js.map +1 -1
- package/lib/commonjs/ProfileManager/Components/VouchCard.js +15 -23
- package/lib/commonjs/ProfileManager/Components/VouchCard.js.map +1 -1
- package/lib/commonjs/ProfileManager/api/index.js +1 -1
- package/lib/commonjs/ProfileManager/index.js +3 -1
- package/lib/commonjs/ProfileManager/index.js.map +1 -1
- package/lib/commonjs/constants/styles.js +21 -1
- package/lib/commonjs/constants/styles.js.map +1 -1
- package/lib/module/ApiOverrides/index.js +4 -0
- package/lib/module/ApiOverrides/index.js.map +1 -1
- package/lib/module/Components/Icons.js +50 -0
- package/lib/module/Components/Icons.js.map +1 -1
- package/lib/module/Components/ImageUploader.js +10 -1
- package/lib/module/Components/ImageUploader.js.map +1 -1
- package/lib/module/Components/LinearDiagnal.js +74 -0
- package/lib/module/Components/LinearDiagnal.js.map +1 -0
- package/lib/module/ProfileManager/Components/BasicInfoManager.js +82 -33
- package/lib/module/ProfileManager/Components/BasicInfoManager.js.map +1 -1
- package/lib/module/ProfileManager/Components/BasicStatus.js +90 -21
- package/lib/module/ProfileManager/Components/BasicStatus.js.map +1 -1
- package/lib/module/ProfileManager/Components/DOBManager.js +56 -34
- package/lib/module/ProfileManager/Components/DOBManager.js.map +1 -1
- package/lib/module/ProfileManager/Components/EmailManager.js +71 -36
- package/lib/module/ProfileManager/Components/EmailManager.js.map +1 -1
- package/lib/module/ProfileManager/Components/PasswordManager.js +48 -26
- package/lib/module/ProfileManager/Components/PasswordManager.js.map +1 -1
- package/lib/module/ProfileManager/Components/PhoneManager.js +72 -37
- package/lib/module/ProfileManager/Components/PhoneManager.js.map +1 -1
- package/lib/module/ProfileManager/Components/ProfilePicManager.js +45 -31
- package/lib/module/ProfileManager/Components/ProfilePicManager.js.map +1 -1
- package/lib/module/ProfileManager/Components/ProfileWelcome.js +60 -18
- package/lib/module/ProfileManager/Components/ProfileWelcome.js.map +1 -1
- package/lib/module/ProfileManager/Components/ProfileWizard.js +54 -28
- package/lib/module/ProfileManager/Components/ProfileWizard.js.map +1 -1
- package/lib/module/ProfileManager/Components/VouchCard.js +15 -23
- package/lib/module/ProfileManager/Components/VouchCard.js.map +1 -1
- package/lib/module/ProfileManager/api/index.js +1 -1
- package/lib/module/ProfileManager/index.js +3 -1
- package/lib/module/ProfileManager/index.js.map +1 -1
- package/lib/module/constants/styles.js +20 -0
- package/lib/module/constants/styles.js.map +1 -1
- package/lib/typescript/src/ApiOverrides/index.d.ts.map +1 -1
- package/lib/typescript/src/Components/Icons.d.ts +1 -0
- package/lib/typescript/src/Components/Icons.d.ts.map +1 -1
- package/lib/typescript/src/Components/ImageUploader.d.ts +1 -1
- package/lib/typescript/src/Components/ImageUploader.d.ts.map +1 -1
- package/lib/typescript/src/Components/LinearDiagnal.d.ts +14 -0
- package/lib/typescript/src/Components/LinearDiagnal.d.ts.map +1 -0
- package/lib/typescript/src/ProfileManager/Components/BasicInfoManager.d.ts.map +1 -1
- package/lib/typescript/src/ProfileManager/Components/BasicStatus.d.ts +9 -2
- package/lib/typescript/src/ProfileManager/Components/BasicStatus.d.ts.map +1 -1
- package/lib/typescript/src/ProfileManager/Components/DOBManager.d.ts.map +1 -1
- package/lib/typescript/src/ProfileManager/Components/EmailManager.d.ts.map +1 -1
- package/lib/typescript/src/ProfileManager/Components/PasswordManager.d.ts.map +1 -1
- package/lib/typescript/src/ProfileManager/Components/PhoneManager.d.ts.map +1 -1
- package/lib/typescript/src/ProfileManager/Components/ProfilePicManager.d.ts.map +1 -1
- package/lib/typescript/src/ProfileManager/Components/ProfileWelcome.d.ts +9 -2
- package/lib/typescript/src/ProfileManager/Components/ProfileWelcome.d.ts.map +1 -1
- package/lib/typescript/src/ProfileManager/Components/ProfileWizard.d.ts +3 -1
- package/lib/typescript/src/ProfileManager/Components/ProfileWizard.d.ts.map +1 -1
- package/lib/typescript/src/ProfileManager/Components/VouchCard.d.ts.map +1 -1
- package/lib/typescript/src/ProfileManager/index.d.ts +5 -2
- package/lib/typescript/src/ProfileManager/index.d.ts.map +1 -1
- package/lib/typescript/src/constants/styles.d.ts +26 -0
- package/lib/typescript/src/constants/styles.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/ApiOverrides/index.ts +4 -0
- package/src/Components/Icons.tsx +21 -0
- package/src/Components/ImageUploader.tsx +4 -3
- package/src/Components/LinearDiagnal.tsx +52 -0
- package/src/ProfileManager/Components/BasicInfoManager.tsx +110 -76
- package/src/ProfileManager/Components/BasicStatus.tsx +55 -24
- package/src/ProfileManager/Components/DOBManager.tsx +46 -28
- package/src/ProfileManager/Components/EmailManager.tsx +48 -33
- package/src/ProfileManager/Components/PasswordManager.tsx +36 -18
- package/src/ProfileManager/Components/PhoneManager.tsx +82 -66
- package/src/ProfileManager/Components/ProfilePicManager.tsx +38 -23
- package/src/ProfileManager/Components/ProfileWelcome.tsx +33 -14
- package/src/ProfileManager/Components/ProfileWizard.tsx +68 -20
- package/src/ProfileManager/Components/VouchCard.tsx +8 -11
- package/src/ProfileManager/api/index.ts +1 -1
- package/src/ProfileManager/index.tsx +7 -3
- package/src/constants/styles.ts +9 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { useEffect, useState } from 'react';
|
|
2
2
|
import { View, FlatList, TouchableOpacity, Image, Linking } from 'react-native';
|
|
3
|
-
import type { MyPlayerProps, ProfileLevelProps, ProfileStepProps, SettingProps } from "../api/types"
|
|
3
|
+
import type { CodeRequestProps, MyPlayerProps, PlayerReferralProps, ProfileLevelProps, ProfileStepProps, PromoProps, SettingProps } from "../api/types"
|
|
4
4
|
import { Button, Icons, Text } from '../../Components';
|
|
5
5
|
import Colors from '../../constants/colors';
|
|
6
6
|
import BasicInfoManager from './BasicInfoManager';
|
|
@@ -13,8 +13,9 @@ import VouchCard from './VouchCard';
|
|
|
13
13
|
import ProfilePicManager from './ProfilePicManager';
|
|
14
14
|
import ProfileWelcome from './ProfileWelcome';
|
|
15
15
|
import CodeRedeem from './CodeRedeem';
|
|
16
|
-
import type { PlayerSettingProps } from '../../types';
|
|
16
|
+
import type { PlayerSettingProps, PublicPlayerProps } from '../../types';
|
|
17
17
|
import SettingsManager from './SettingsManager';
|
|
18
|
+
import { ProfileApi } from '../api';
|
|
18
19
|
|
|
19
20
|
type ProfileWizardProps = {
|
|
20
21
|
player:MyPlayerProps,
|
|
@@ -26,7 +27,9 @@ type ProfileWizardProps = {
|
|
|
26
27
|
hidden_groups?:string[],
|
|
27
28
|
hidden_levels?:string[],
|
|
28
29
|
hidden_steps?:string[],
|
|
29
|
-
init_walkthrough?:
|
|
30
|
+
init_walkthrough?:{
|
|
31
|
+
level: 'basic'|'verify'
|
|
32
|
+
},
|
|
30
33
|
profile_attribute?:'basic'|'phone'|'email'|'dob'|'password'|'vouch'|'notification'|'preferences',
|
|
31
34
|
onClose:() => void,
|
|
32
35
|
onLogout:() => void,
|
|
@@ -34,11 +37,20 @@ type ProfileWizardProps = {
|
|
|
34
37
|
onPlayerUpdate:(player:MyPlayerProps, attribute?:string) => void
|
|
35
38
|
onUpdatePlayerSetting:(player_setting:PlayerSettingProps) => void
|
|
36
39
|
}
|
|
40
|
+
// { num:5, check: 'code', label: 'Promo', description: `Lets get you started with some promo bucks!`, complete:false },
|
|
37
41
|
|
|
38
42
|
const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, init_walkthrough, show_welcome, profile_attribute, width, hidden_groups, hidden_levels, hidden_steps, onUpdatePlayerSetting, onPlayerUpdate, onSelectLevel, onClose, onLogout }:ProfileWizardProps) => {
|
|
39
43
|
const [ draft_player, setDraftPlayer ] = useState(player);
|
|
44
|
+
const [ code_details, setCodeDetails ] = useState<
|
|
45
|
+
{
|
|
46
|
+
code_request?:CodeRequestProps,
|
|
47
|
+
referrer?:PublicPlayerProps,
|
|
48
|
+
promo?:PromoProps,
|
|
49
|
+
player_referral?:PlayerReferralProps
|
|
50
|
+
}
|
|
51
|
+
>({})
|
|
40
52
|
const [ show_logout, setShowLogout ] = useState(false);
|
|
41
|
-
const [ walkthrough, setWalkthrough ] = useState<
|
|
53
|
+
const [ walkthrough, setWalkthrough ] = useState<string | undefined>(undefined);
|
|
42
54
|
const [ active_level, setActiveLevel ] = useState<ProfileLevelProps>()
|
|
43
55
|
const [ active_step, setActiveStep ] = useState<ProfileStepProps>()
|
|
44
56
|
const [ groups, setGroups ] = useState([
|
|
@@ -70,7 +82,6 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
70
82
|
{ num:2, check: 'phone', label: 'Phone', description: `Lets make sure you can access your account in case you forget your password`, complete:false },
|
|
71
83
|
{ num:3, check: 'dob', label: 'Date of Birth', description: `We need to ensure you are at least 18 to play`, complete:false },
|
|
72
84
|
{ num:4, check: 'vouch', label: 'Verify', description: `We need to ensure you are at least 18 to play`, complete:false },
|
|
73
|
-
{ num:5, check: 'code', label: 'Promo', description: `Lets get you started with some promo bucks!`, complete:false },
|
|
74
85
|
|
|
75
86
|
]
|
|
76
87
|
}
|
|
@@ -96,9 +107,25 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
96
107
|
}
|
|
97
108
|
])
|
|
98
109
|
|
|
110
|
+
useEffect(() => {
|
|
111
|
+
getCodeFromServer()
|
|
112
|
+
},[])
|
|
113
|
+
|
|
114
|
+
const getCodeFromServer = async() => {
|
|
115
|
+
const request_resp = await ProfileApi.getMyCodeDetails()
|
|
116
|
+
setCodeDetails(request_resp)
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
useEffect(() => {
|
|
120
|
+
if(!init_walkthrough){ return }
|
|
121
|
+
setWalkthrough(init_walkthrough.level)
|
|
122
|
+
let walkthroughLevel = groups.find(g => g.profile_levels.find(l => l.identifier == init_walkthrough.level))?.profile_levels.find(l => l.identifier == init_walkthrough.level)
|
|
123
|
+
setActiveLevel(walkthroughLevel)
|
|
124
|
+
if(!show_welcome){ setActiveStep(walkthroughLevel?.profile_steps[0]) }
|
|
125
|
+
},[init_walkthrough])
|
|
126
|
+
|
|
99
127
|
useEffect(() => {
|
|
100
128
|
if(!player){ return }
|
|
101
|
-
setWalkthrough(init_walkthrough ? true : false)
|
|
102
129
|
setDraftPlayer(player)
|
|
103
130
|
const groups = setupSteps(player)
|
|
104
131
|
setGroups(groups);
|
|
@@ -111,7 +138,6 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
111
138
|
let profile_step:ProfileStepProps|undefined = undefined
|
|
112
139
|
groups.map(g => g.profile_levels.map((l:ProfileLevelProps) => {
|
|
113
140
|
let step = l.profile_steps.find(ps => ps.check == profile_attribute)
|
|
114
|
-
console.log(step)
|
|
115
141
|
if(step){
|
|
116
142
|
profile_step = step
|
|
117
143
|
profile_level = l
|
|
@@ -227,11 +253,25 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
227
253
|
}
|
|
228
254
|
|
|
229
255
|
const renderSteps = (data:{ item: ProfileStepProps, index:number }) => {
|
|
256
|
+
if(!active_level){ return <></> }
|
|
230
257
|
const active = data.item.check == active_step?.check ? true : false
|
|
231
258
|
if(!active_level){ return <></> }
|
|
232
259
|
return (
|
|
233
|
-
<TouchableOpacity
|
|
234
|
-
|
|
260
|
+
<TouchableOpacity
|
|
261
|
+
style={{
|
|
262
|
+
padding:10,
|
|
263
|
+
width: (width - 20) / active_level.profile_steps.length,
|
|
264
|
+
backgroundColor:getStepColor(data.item, active),
|
|
265
|
+
borderTopRightRadius: data.index == active_level.profile_steps.length - 1 ? 22 : 0,
|
|
266
|
+
borderBottomRightRadius: data.index == active_level.profile_steps.length - 1 ? 22 : 0,
|
|
267
|
+
borderBottomLeftRadius: data.index == 0 ? 22: 0,
|
|
268
|
+
borderTopLeftRadius: data.index == 0 ? 22: 0
|
|
269
|
+
|
|
270
|
+
}}
|
|
271
|
+
onPress={() => setActiveStep(data.item)}>
|
|
272
|
+
{!walkthrough ?
|
|
273
|
+
<Text size={14} textAlign='center' color={active?Colors.shades.white:Colors.brand.midnight} weight={active?'bold':'regular'}>{data.item.label}</Text>
|
|
274
|
+
:<></>}
|
|
235
275
|
</TouchableOpacity>
|
|
236
276
|
)
|
|
237
277
|
}
|
|
@@ -306,6 +346,7 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
306
346
|
</View>
|
|
307
347
|
:
|
|
308
348
|
<View style={{ flex:1 }}>
|
|
349
|
+
{!walkthrough ?
|
|
309
350
|
<TouchableOpacity style={{ flexDirection:'row', alignItems:'center', padding:10, borderTopWidth:2, borderColor:Colors.shades.shade600 }} onPress={() => {
|
|
310
351
|
setActiveLevel(undefined)
|
|
311
352
|
setActiveStep(undefined)
|
|
@@ -321,7 +362,8 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
321
362
|
</View>
|
|
322
363
|
:<></>}
|
|
323
364
|
</TouchableOpacity>
|
|
324
|
-
|
|
365
|
+
:<></>}
|
|
366
|
+
<View style={{ borderWidth:1, borderColor:Colors.shades.shade600, borderRadius:22, margin:10 }}>
|
|
325
367
|
<FlatList
|
|
326
368
|
data={active_level?.profile_steps}
|
|
327
369
|
renderItem={renderSteps}
|
|
@@ -335,18 +377,20 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
335
377
|
<ProfileWelcome
|
|
336
378
|
player={draft_player}
|
|
337
379
|
width={width}
|
|
380
|
+
code_details={code_details}
|
|
338
381
|
onStartSetup={() => {
|
|
339
382
|
if(!active_level){ return }
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
383
|
+
if(walkthrough){
|
|
384
|
+
let next_step = active_level.profile_steps[0]
|
|
385
|
+
setActiveStep(next_step)
|
|
386
|
+
}
|
|
343
387
|
}}
|
|
344
388
|
onClose={() => onClose()}
|
|
345
389
|
/>
|
|
346
390
|
:active_step?.check == 'basic' ?
|
|
347
391
|
<BasicInfoManager
|
|
348
392
|
player={draft_player}
|
|
349
|
-
walkthrough={walkthrough}
|
|
393
|
+
walkthrough={walkthrough == 'basic' ? true : false}
|
|
350
394
|
onClose={() => {
|
|
351
395
|
if(profile_attribute){ return onClose() }
|
|
352
396
|
return setActiveLevel(undefined)
|
|
@@ -363,7 +407,7 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
363
407
|
:active_step?.check == 'profile_pic'?
|
|
364
408
|
<ProfilePicManager
|
|
365
409
|
player={draft_player}
|
|
366
|
-
walkthrough={walkthrough}
|
|
410
|
+
walkthrough={walkthrough == 'basic' ? true : false}
|
|
367
411
|
onClose={() => {
|
|
368
412
|
if(profile_attribute){ return onClose() }
|
|
369
413
|
return setActiveLevel(undefined)
|
|
@@ -382,7 +426,7 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
382
426
|
if(profile_attribute){ return onClose() }
|
|
383
427
|
return setActiveLevel(undefined)
|
|
384
428
|
}}
|
|
385
|
-
walkthrough={walkthrough}
|
|
429
|
+
walkthrough={walkthrough == 'basic' ? true : false}
|
|
386
430
|
onNext={() => {
|
|
387
431
|
if(!active_level){ return }
|
|
388
432
|
let next_step = active_level.profile_steps[3]
|
|
@@ -393,7 +437,7 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
393
437
|
:active_step?.check == 'email' ?
|
|
394
438
|
<EmailManager
|
|
395
439
|
player={draft_player}
|
|
396
|
-
walkthrough={walkthrough}
|
|
440
|
+
walkthrough={walkthrough == 'verify' ? true : false}
|
|
397
441
|
onClose={() => {
|
|
398
442
|
if(profile_attribute){ return onClose() }
|
|
399
443
|
return setActiveLevel(undefined)
|
|
@@ -412,7 +456,7 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
412
456
|
if(profile_attribute){ return onClose() }
|
|
413
457
|
return setActiveLevel(undefined)
|
|
414
458
|
}}
|
|
415
|
-
walkthrough={walkthrough}
|
|
459
|
+
walkthrough={walkthrough == 'verify' ? true : false}
|
|
416
460
|
onNext={() => {
|
|
417
461
|
if(!active_level){ return }
|
|
418
462
|
let next_step = active_level.profile_steps[2]
|
|
@@ -423,13 +467,15 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
423
467
|
:active_step?.check == 'basic_review' ?
|
|
424
468
|
<BasicStatus
|
|
425
469
|
player={draft_player}
|
|
470
|
+
code_details={code_details}
|
|
426
471
|
onClose={() => {
|
|
427
472
|
if(profile_attribute){ return onClose() }
|
|
428
473
|
return setActiveLevel(undefined)
|
|
429
474
|
}}
|
|
430
475
|
onVerify={() => {
|
|
431
|
-
let new_level = groups[0]?.profile_levels
|
|
476
|
+
let new_level = groups[0]?.profile_levels.find(l => l.identifier == 'verify')
|
|
432
477
|
if(!new_level){return }
|
|
478
|
+
setWalkthrough('verify')
|
|
433
479
|
setActiveLevel(new_level)
|
|
434
480
|
onSelectLevel(new_level)
|
|
435
481
|
setActiveStep(new_level.profile_steps[0])
|
|
@@ -442,7 +488,7 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
442
488
|
if(profile_attribute){ return onClose() }
|
|
443
489
|
return setActiveLevel(undefined)
|
|
444
490
|
}}
|
|
445
|
-
walkthrough={walkthrough}
|
|
491
|
+
walkthrough={walkthrough == 'verify' ? true : false}
|
|
446
492
|
onNext={() => {
|
|
447
493
|
if(!active_level){ return }
|
|
448
494
|
let next_step = active_level.profile_steps[3]
|
|
@@ -516,4 +562,6 @@ const ProfileWizard = ({ player, hide_powered_by, settings, player_settings, in
|
|
|
516
562
|
)
|
|
517
563
|
}
|
|
518
564
|
|
|
565
|
+
|
|
566
|
+
|
|
519
567
|
export default ProfileWizard
|
|
@@ -160,11 +160,11 @@ const VouchCard = ({ player, onPlayerUpdate, onClose }:VouchCardProps) => {
|
|
|
160
160
|
return (
|
|
161
161
|
<View style={{ flex:1 }}>
|
|
162
162
|
<View style={{ flex:1 }}>
|
|
163
|
-
<View
|
|
164
|
-
<Text size={
|
|
165
|
-
<Text style={{ marginTop:
|
|
163
|
+
<View style={{ padding:20 }}>
|
|
164
|
+
<Text size={30} color={Colors.brand.midnight} weight='bold'>Help us identify you</Text>
|
|
165
|
+
<Text style={{ marginTop:15 }} size={16} color={Colors.brand.midnight} weight='regular'>We need to take extra steps to verify your account. Scan your Driver's License or state issued ID and take a selfie for instant verification</Text>
|
|
166
166
|
</View>
|
|
167
|
-
<TouchableOpacity style={{padding:10, borderRadius:8, backgroundColor:Colors.highlights.highlight500Faded,
|
|
167
|
+
<TouchableOpacity style={{padding:10, borderRadius:8, backgroundColor:Colors.highlights.highlight500Faded, margin:20}} onPress={() => setInfoVisible(!info_visible)}>
|
|
168
168
|
<View style={{ flexDirection:'row', alignItems:'center' }}>
|
|
169
169
|
<Text style={{ flex:1 }} size={14} weight='semibold' color={Colors.brand.midnight}>Why is this step required?</Text>
|
|
170
170
|
<Icons.ChevronIcon direction={info_visible?'up':'down'} size={10} color={Colors.brand.midnight} />
|
|
@@ -181,7 +181,7 @@ const VouchCard = ({ player, onPlayerUpdate, onClose }:VouchCardProps) => {
|
|
|
181
181
|
/>
|
|
182
182
|
</View>
|
|
183
183
|
{player.vouched_status == 'unverified' ?
|
|
184
|
-
<View>
|
|
184
|
+
<View style={{ padding:10 }}>
|
|
185
185
|
<TouchableOpacity
|
|
186
186
|
style={{ flexDirection:'row', alignItems:'center', padding:10, marginLeft:15, marginRight:15, borderRadius:8, backgroundColor:Colors.shades.shade100, marginTop:5 }}
|
|
187
187
|
onPress={() => setDisclaimerConfirmed(!disclaimer_confirmed)}>
|
|
@@ -217,12 +217,9 @@ const VouchCard = ({ player, onPlayerUpdate, onClose }:VouchCardProps) => {
|
|
|
217
217
|
:<></>}
|
|
218
218
|
<View nativeID='action_row' style={{ flexDirection:'row', padding:10 }}>
|
|
219
219
|
<Button
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
borderColor={Colors.brand.electric}
|
|
224
|
-
title_color={Colors.brand.electric}
|
|
225
|
-
title='CLOSE'
|
|
220
|
+
title='EXIT SETUP'
|
|
221
|
+
title_color={Colors.utility.error}
|
|
222
|
+
backgroundColor='transparent'
|
|
226
223
|
onPress={() => onClose()}
|
|
227
224
|
/>
|
|
228
225
|
{player.vouched_status == 'unverified' ?
|
|
@@ -251,7 +251,7 @@ getReferralDescription : (promo:PromoProps) => {
|
|
|
251
251
|
case 'promo_code': return `Get ${promo.amount} promo bucks after you verify your account`
|
|
252
252
|
case 'promo_sweepstakes': return `Have a chance at UP TO 500 promo bucks after you verify your account`
|
|
253
253
|
case 'referral_code': return `Get ${promo.amount} promo bucks after you verify your account. Your referrer will get the same after you make your first deposit`
|
|
254
|
-
case 'referral_sweepstakes': return `Have a
|
|
254
|
+
case 'referral_sweepstakes': return `Have a chance at UP TO 500 promo bucks after you verify your account. Your referrer will get the same after you make your first deposit`
|
|
255
255
|
default: return ''
|
|
256
256
|
}
|
|
257
257
|
} ,
|
|
@@ -11,6 +11,7 @@ type ProfileOverviewProps = {
|
|
|
11
11
|
width:number,
|
|
12
12
|
show_welcome?:boolean,
|
|
13
13
|
//access_token:string,
|
|
14
|
+
hide_powered_by?:boolean,
|
|
14
15
|
hidden_groups?:string[],
|
|
15
16
|
hidden_steps?:string[],
|
|
16
17
|
hidden_levels?:string[],
|
|
@@ -18,10 +19,12 @@ type ProfileOverviewProps = {
|
|
|
18
19
|
onLogout:() => void,
|
|
19
20
|
onPlayerUpdate?:(p:MyPlayerProps, attribute?:string) => void,
|
|
20
21
|
profile_attribute?:'basic'|'phone'|'email'|'dob'|'password'|'vouch'|'notification'|'preferences',
|
|
21
|
-
walkthrough?:
|
|
22
|
+
walkthrough?: {
|
|
23
|
+
level: 'verify' | 'basic'
|
|
24
|
+
}
|
|
22
25
|
}
|
|
23
26
|
|
|
24
|
-
const ProfileManager = ({ profile_attribute, onPlayerUpdate, show_welcome, hidden_groups, hidden_steps, hidden_levels, walkthrough, width, onClose, onLogout }: ProfileOverviewProps ) => {
|
|
27
|
+
const ProfileManager = ({ profile_attribute, hide_powered_by, onPlayerUpdate, show_welcome, hidden_groups, hidden_steps, hidden_levels, walkthrough, width, onClose, onLogout }: ProfileOverviewProps ) => {
|
|
25
28
|
const [ loading, setLoading ] = useState(false);
|
|
26
29
|
const [ draft_player, setDraftPlayer ] = useState<MyPlayerProps>();
|
|
27
30
|
const [ player_balance, setPlayerBalance ] = useState<PlayerBalanceProps>();
|
|
@@ -85,7 +88,7 @@ const ProfileManager = ({ profile_attribute, onPlayerUpdate, show_welcome, hidde
|
|
|
85
88
|
{player_balance ?
|
|
86
89
|
<View style={{ paddingRight:10 }}>
|
|
87
90
|
<Text size={16} color={Colors.brand.midnight} weight='bold' textAlign='right'>${player_balance.balance.toFixed(2)}</Text>
|
|
88
|
-
<Text style={{ marginTop:3 }} size={12} color={Colors.brand.midnight} weight='regular' textAlign='right'>Promo
|
|
91
|
+
<Text style={{ marginTop:3 }} size={12} color={Colors.brand.midnight} weight='regular' textAlign='right'>Promo {player_balance.promo_balance.toFixed(2)}</Text>
|
|
89
92
|
</View>
|
|
90
93
|
:<></>}
|
|
91
94
|
</View>
|
|
@@ -95,6 +98,7 @@ const ProfileManager = ({ profile_attribute, onPlayerUpdate, show_welcome, hidde
|
|
|
95
98
|
player_settings={player_settings}
|
|
96
99
|
settings={settings}
|
|
97
100
|
show_welcome={show_welcome}
|
|
101
|
+
hide_powered_by={hide_powered_by}
|
|
98
102
|
width={width}
|
|
99
103
|
hidden_groups={hidden_groups}
|
|
100
104
|
hidden_steps={hidden_steps}
|
package/src/constants/styles.ts
CHANGED
|
@@ -14,6 +14,15 @@ export const view_styles = StyleSheet.create({
|
|
|
14
14
|
}
|
|
15
15
|
})
|
|
16
16
|
|
|
17
|
+
export const button_styles = StyleSheet.create({
|
|
18
|
+
wizard_valid: {
|
|
19
|
+
backgroundColor:Colors.shades.white, height:50, width:50, justifyContent:'center', alignItems:'center', borderRadius:100, ...view_styles.float
|
|
20
|
+
},
|
|
21
|
+
wizard_invalid: {
|
|
22
|
+
backgroundColor:Colors.shades.white, height:50, width:50, justifyContent:'center', alignItems:'center', borderRadius:100, opacity:0.5
|
|
23
|
+
}
|
|
24
|
+
})
|
|
25
|
+
|
|
17
26
|
|
|
18
27
|
export const text_styles = StyleSheet.create({
|
|
19
28
|
dark_heading_1: {
|