fix invite url field name and render invitedBy/createdBy display names
This commit is contained in:
@@ -15,7 +15,7 @@ interface TeamMember {
|
|||||||
displayName: string | null
|
displayName: string | null
|
||||||
teamTitle: string | null
|
teamTitle: string | null
|
||||||
role: string
|
role: string
|
||||||
invitedBy: string | null
|
invitedBy: { id: string; displayName: string | null } | null
|
||||||
joinedAt: string
|
joinedAt: string
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -24,11 +24,11 @@ interface PendingInvite {
|
|||||||
role: string
|
role: string
|
||||||
label: string | null
|
label: string | null
|
||||||
expiresAt: string
|
expiresAt: string
|
||||||
createdBy: string | null
|
createdBy: { id: string; displayName: string | null } | null
|
||||||
}
|
}
|
||||||
|
|
||||||
interface InviteResult {
|
interface InviteResult {
|
||||||
url: string
|
inviteUrl: string
|
||||||
recoveryPhrase: string | null
|
recoveryPhrase: string | null
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -523,8 +523,8 @@ export default function AdminTeam() {
|
|||||||
wordBreak: 'break-all',
|
wordBreak: 'break-all',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<span className="flex-1" style={{ color: 'var(--text)' }}>{inviteResult.url}</span>
|
<span className="flex-1" style={{ color: 'var(--text)' }}>{inviteResult.inviteUrl}</span>
|
||||||
<CopyButton text={inviteResult.url} />
|
<CopyButton text={inviteResult.inviteUrl} />
|
||||||
</div>
|
</div>
|
||||||
{inviteResult.recoveryPhrase && (
|
{inviteResult.recoveryPhrase && (
|
||||||
<div>
|
<div>
|
||||||
@@ -589,7 +589,7 @@ export default function AdminTeam() {
|
|||||||
</div>
|
</div>
|
||||||
<div className="flex items-center gap-3" style={{ color: 'var(--text-tertiary)', fontSize: 'var(--text-xs)' }}>
|
<div className="flex items-center gap-3" style={{ color: 'var(--text-tertiary)', fontSize: 'var(--text-xs)' }}>
|
||||||
{m.teamTitle && <span>{m.teamTitle}</span>}
|
{m.teamTitle && <span>{m.teamTitle}</span>}
|
||||||
{m.invitedBy && <span>Invited by {m.invitedBy}</span>}
|
{m.invitedBy && <span>Invited by {m.invitedBy.displayName || 'Admin'}</span>}
|
||||||
<span>Joined {new Date(m.joinedAt).toLocaleDateString()}</span>
|
<span>Joined {new Date(m.joinedAt).toLocaleDateString()}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -642,7 +642,7 @@ export default function AdminTeam() {
|
|||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
<div style={{ color: 'var(--text-tertiary)', fontSize: 'var(--text-xs)' }}>
|
<div style={{ color: 'var(--text-tertiary)', fontSize: 'var(--text-xs)' }}>
|
||||||
{inv.createdBy && <span>Created by {inv.createdBy} - </span>}
|
{inv.createdBy && <span>Created by {inv.createdBy.displayName || 'Admin'} - </span>}
|
||||||
Expires {new Date(inv.expiresAt).toLocaleDateString()}
|
Expires {new Date(inv.expiresAt).toLocaleDateString()}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user