This commit is contained in:
Ren Amamiya
2023-09-26 09:05:39 +07:00
parent a66770989b
commit 236131087a
21 changed files with 605 additions and 523 deletions

View File

@@ -60,7 +60,7 @@ export function NoteZap({ id, pubkey }: { id: string; pubkey: string }) {
if (send) {
await sendNativeNotification(
`You've tipped ${compactNumber.format(send.amount)} sats to ${
user?.display_name || user?.name
user?.name || user?.display_name || user?.displayName
}`
);
@@ -106,7 +106,7 @@ export function NoteZap({ id, pubkey }: { id: string; pubkey: string }) {
<div className="inline-flex w-full shrink-0 items-center justify-between px-5 py-3">
<div className="w-6" />
<Dialog.Title className="text-center text-sm font-semibold leading-none text-white">
Send tip to {user?.display_name || user?.name}
Send tip to {user?.name || user?.display_name || user?.displayName}
</Dialog.Title>
<Dialog.Close className="inline-flex h-6 w-6 items-center justify-center rounded-md backdrop-blur-xl hover:bg-white/10">
<CancelIcon className="h-4 w-4 text-white/50" />

View File

@@ -18,20 +18,24 @@ export function MentionUser({ pubkey }: { pubkey: string }) {
onClick={() =>
setWidget(db, {
kind: WidgetKinds.local.user,
title: user?.name || user?.display_name,
title: user?.name || user?.display_name || user?.displayName,
content: pubkey,
})
}
onKeyDown={() =>
setWidget(db, {
kind: WidgetKinds.local.user,
title: user?.name || user?.display_name,
title: user?.name || user?.display_name || user?.displayName,
content: pubkey,
})
}
className="break-words text-fuchsia-400 hover:text-fuchsia-500"
>
{user?.name || user?.display_name || user?.username || displayNpub(pubkey, 16)}
{user?.name ||
user?.display_name ||
user?.displayName ||
user?.username ||
displayNpub(pubkey, 16)}
</span>
);
}