ComposeForm: wrap NIP05 text in a <Warning /> component
This commit is contained in:
parent
20cca0165b
commit
0207a29914
|
@ -45,8 +45,9 @@ const WarningWrapper: React.FC<IWarningWrapper> = ({ composeId }) => {
|
|||
}
|
||||
|
||||
if (account?.source?.nostr?.nip05 === undefined) {
|
||||
if (settingsNotifications.has('needsNip05')) {
|
||||
return (
|
||||
<Warning
|
||||
message={(settingsNotifications.has('needsNip05')) ? (
|
||||
<FormattedMessage
|
||||
id='compose_form.nip05.warning'
|
||||
defaultMessage={'You don\'t have a username configured. {click} to set one up.'}
|
||||
|
@ -58,16 +59,15 @@ const WarningWrapper: React.FC<IWarningWrapper> = ({ composeId }) => {
|
|||
),
|
||||
}}
|
||||
/>
|
||||
);
|
||||
} else {
|
||||
return (
|
||||
) : (
|
||||
<FormattedMessage
|
||||
id='compose_form.nip05.pending'
|
||||
defaultMessage='Your username request is under review.'
|
||||
/>
|
||||
)}
|
||||
/>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
if (needsLockWarning) {
|
||||
return (
|
||||
|
|
Loading…
Reference in New Issue