mirror of
https://github.com/wassname/talk.git
synced 2026-07-03 15:11:12 +08:00
Merge branch 'master' into edit-comment-settings
This commit is contained in:
@@ -30,3 +30,13 @@
|
||||
font-weight: bold;
|
||||
}
|
||||
}
|
||||
|
||||
.profileEmail {
|
||||
border: none;
|
||||
background-color: transparent;
|
||||
pointer-events: none;
|
||||
font-size: 16px;
|
||||
position: absolute;
|
||||
width: 100%;
|
||||
outline: none;
|
||||
}
|
||||
|
||||
@@ -11,7 +11,7 @@ class UserDetail extends React.Component {
|
||||
hideUserDetail: PropTypes.func.isRequired
|
||||
}
|
||||
|
||||
copyPermalink () {
|
||||
copyPermalink = () => {
|
||||
this.profile.select();
|
||||
try {
|
||||
document.execCommand('copy');
|
||||
@@ -45,8 +45,8 @@ class UserDetail extends React.Component {
|
||||
return (
|
||||
<Drawer handleClickOutside={hideUserDetail}>
|
||||
<h3>{user.username}</h3>
|
||||
<Button className={styles.copyButton}>Copy</Button>
|
||||
{profile && <p ref={(ref) => this.profile = ref} contentEditable="true">{profile}</p>}
|
||||
<Button className={styles.copyButton} onClick={this.copyPermalink}>Copy</Button>
|
||||
{profile && <input className={styles.profileEmail} type="text" ref={(ref) => this.profile = ref} value={profile} />}
|
||||
<Slot fill="userProfile" user={user} />
|
||||
<p className={styles.memberSince}><strong>Member since</strong> {new Date(user.created_at).toLocaleString()}</p>
|
||||
<hr/>
|
||||
|
||||
Reference in New Issue
Block a user