remove expiration when invoice is confirmed
This commit is contained in:
parent
13926d57da
commit
cfb8fa7014
|
@ -47,13 +47,14 @@ export function Invoice ({ invoice, onPayment, info, successVerb }) {
|
|||
description={numWithUnits(invoice.satsRequested, { abbreviate: false })}
|
||||
statusVariant={variant} status={status}
|
||||
/>
|
||||
<div className='text-muted text-center'>
|
||||
<Countdown
|
||||
date={invoice.expiresAt} onComplete={() => {
|
||||
setExpired(true)
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
{!invoice.confirmedAt &&
|
||||
<div className='text-muted text-center'>
|
||||
<Countdown
|
||||
date={invoice.expiresAt} onComplete={() => {
|
||||
setExpired(true)
|
||||
}}
|
||||
/>
|
||||
</div>}
|
||||
{info && <div className='text-muted fst-italic text-center'>{info}</div>}
|
||||
<div className='w-100'>
|
||||
{nostr
|
||||
|
|
|
@ -110,12 +110,12 @@ function Detail ({ fact }) {
|
|||
if (!fact.item) {
|
||||
let zap
|
||||
try {
|
||||
zap = JSON.parse(fact.zapMessage)
|
||||
zap = JSON.parse(fact.description)
|
||||
} catch { }
|
||||
return (
|
||||
<div className='px-3'>
|
||||
<Link className={satusClass(fact.status)} href={`/${fact.type}s/${fact.factId}`}>
|
||||
{(zap && <span className='d-block'>nostr zap</span>) ||
|
||||
{(zap && <span className='d-block'>nostr zap{zap.content && `: ${zap.content}`}</span>) ||
|
||||
(fact.description && <span className='d-block'>{fact.description}</span>)}
|
||||
{fact.invoiceComment && <small className='text-muted'>sender says: {fact.invoiceComment}</small>}
|
||||
{!fact.invoiceComment && !fact.description && <span className='d-block'>no description</span>}
|
||||
|
|
Loading…
Reference in New Issue