mirror of
https://github.com/myfatemi04/wheelshare-frontend.git
synced 2025-04-09 22:00:16 -04:00
show group code copy link always
This commit is contained in:
parent
88905a16ee
commit
5725e4cbff
|
@ -43,37 +43,46 @@ export default function GroupInviteCode() {
|
|||
</code>{' '}
|
||||
(click to show/hide)
|
||||
</span>
|
||||
{isAdmin && (
|
||||
<div style={{ display: 'flex', justifyContent: 'space-between' }}>
|
||||
<UIButton
|
||||
onClick={resetJoinCode}
|
||||
style={{
|
||||
backgroundColor: lightgrey,
|
||||
margin: '0.5rem',
|
||||
flex: 1,
|
||||
}}
|
||||
>
|
||||
Reset
|
||||
</UIButton>
|
||||
<UIButton
|
||||
onClick={generateJoinCode}
|
||||
style={{
|
||||
backgroundColor: lightgrey,
|
||||
margin: '0.5rem',
|
||||
flex: 1,
|
||||
}}
|
||||
>
|
||||
Regenerate
|
||||
</UIButton>
|
||||
<UIButton onClick={() => {navigator.clipboard.writeText("https://www.wheelshare.app/join/"+group.joinCode)}} style={{
|
||||
backgroundColor: lightgrey,
|
||||
margin: '0.5rem',
|
||||
flex: 1,
|
||||
}}>
|
||||
Copy Link
|
||||
</UIButton>
|
||||
</div>
|
||||
)}
|
||||
<div style={{ display: 'flex', justifyContent: 'space-between' }}>
|
||||
{isAdmin && (
|
||||
<>
|
||||
<UIButton
|
||||
onClick={resetJoinCode}
|
||||
style={{
|
||||
backgroundColor: lightgrey,
|
||||
margin: '0.5rem',
|
||||
flex: 1,
|
||||
}}
|
||||
>
|
||||
Reset
|
||||
</UIButton>
|
||||
<UIButton
|
||||
onClick={generateJoinCode}
|
||||
style={{
|
||||
backgroundColor: lightgrey,
|
||||
margin: '0.5rem',
|
||||
flex: 1,
|
||||
}}
|
||||
>
|
||||
Regenerate
|
||||
</UIButton>
|
||||
</>
|
||||
)}
|
||||
<UIButton
|
||||
onClick={() => {
|
||||
navigator.clipboard.writeText(
|
||||
'https://www.wheelshare.app/join/' + group.joinCode
|
||||
);
|
||||
}}
|
||||
style={{
|
||||
backgroundColor: lightgrey,
|
||||
margin: '0.5rem',
|
||||
flex: 1,
|
||||
}}
|
||||
>
|
||||
Copy Link
|
||||
</UIButton>
|
||||
</div>
|
||||
</>
|
||||
);
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue
Block a user