Profile shows referral link

This commit is contained in:
Reckless_Satoshi 2022-03-05 03:48:11 -08:00
parent c385be123f
commit e775c02011
No known key found for this signature in database
GPG Key ID: 9C4585B561315571
3 changed files with 38 additions and 5 deletions

View File

@ -22,6 +22,7 @@ import ContentCopy from "@mui/icons-material/ContentCopy";
import DnsIcon from '@mui/icons-material/Dns';
import WebIcon from '@mui/icons-material/Web';
import BookIcon from '@mui/icons-material/Book';
import PersonAddAltIcon from '@mui/icons-material/PersonAddAlt';
// pretty numbers
function pn(x) {
@ -247,6 +248,7 @@ export default class BottomBar extends Component {
/>
</ListItemAvatar>
</ListItem>
<Divider/>
{this.state.active_order_id ?
// TODO Link to router and do this.props.history.push
@ -264,6 +266,7 @@ export default class BottomBar extends Component {
<ListItemText primary="No active orders" secondary="Your current order"/>
</ListItem>
}
<ListItem>
<ListItemIcon>
<PasswordIcon/>
@ -278,14 +281,40 @@ export default class BottomBar extends Component {
size='small'
InputProps={{
endAdornment:
<IconButton onClick= {()=>navigator.clipboard.writeText(this.props.token)}>
<ContentCopy />
</IconButton>,
<Tooltip disableHoverListener open={this.state.copied} enterTouchDelay="0" title="Copied!">
<IconButton onClick= {()=>navigator.clipboard.writeText(this.props.token)}>
<ContentCopy />
</IconButton>
</Tooltip>,
}}
/>
:
'Cannot remember'}
</ListItemText>
</ListItemText>
</ListItem>
<Divider/>
<ListItem>
<ListItemIcon>
<PersonAddAltIcon/>
</ListItemIcon>
<ListItemText secondary="Your referral link">
<TextField
label='Share to earn satoshis'
// value={this.props.referral_link}
value={'LINKKKKKKK732hcd23j98j2iuwh78c2i3jd9cy2hiudn8723ihdcniu2hdci23923jiuxjw'}
// variant='filled'
size='small'
InputProps={{
endAdornment:
<Tooltip disableHoverListener open={this.state.copied} enterTouchDelay="0" title="Copied!">
<IconButton onClick= {()=>navigator.clipboard.writeText('LINKKKKKKK732hcd23j98j2iuwh78c2i3jd9cy2hiudn8723ihdcniu2hdci23923jiuxjw')}>
<ContentCopy />
</IconButton>
</Tooltip>,
}}
/>
</ListItemText>
</ListItem>
</List>

File diff suppressed because one or more lines are too long

View File

@ -838,6 +838,10 @@
!*** ./node_modules/@mui/base/utils/appendOwnerState.js ***!
\**********************************************************/
/*!**********************************************************!*\
!*** ./node_modules/@mui/icons-material/PersonAddAlt.js ***!
\**********************************************************/
/*!**********************************************************!*\
!*** ./node_modules/@mui/material/Alert/alertClasses.js ***!
\**********************************************************/