fix zap splits for large lists
This commit is contained in:
parent
9fb6f0dfee
commit
803c8ee05e
@ -163,11 +163,12 @@ export default function SendSats(props: SendSatsProps) {
|
|||||||
<FormattedMessage defaultMessage="Send sats splits to" />
|
<FormattedMessage defaultMessage="Send sats splits to" />
|
||||||
)}
|
)}
|
||||||
</h2>
|
</h2>
|
||||||
<div className="flex g4">
|
<div className="flex g4 f-wrap">
|
||||||
{props.targets.map(v => (
|
{props.targets.map(v => (
|
||||||
<ProfileImage
|
<ProfileImage
|
||||||
pubkey={v.value}
|
pubkey={v.value}
|
||||||
showUsername={false}
|
showUsername={false}
|
||||||
|
showFollowingMark={false}
|
||||||
imageOverlay={formatShort(Math.floor((amount?.amount ?? 0) * (v.weight / total)))}
|
imageOverlay={formatShort(Math.floor((amount?.amount ?? 0) * (v.weight / total)))}
|
||||||
/>
|
/>
|
||||||
))}
|
))}
|
||||||
|
@ -190,17 +190,21 @@ export class Zapper {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async #getService(t: ZapTarget) {
|
async #getService(t: ZapTarget) {
|
||||||
if (t.type === "lnurl") {
|
try {
|
||||||
const svc = new LNURL(t.value);
|
if (t.type === "lnurl") {
|
||||||
await svc.load();
|
const svc = new LNURL(t.value);
|
||||||
return svc;
|
|
||||||
} else if (t.type === "pubkey") {
|
|
||||||
const profile = await this.system.ProfileLoader.fetchProfile(t.value);
|
|
||||||
if (profile) {
|
|
||||||
const svc = new LNURL(profile.lud16 ?? profile.lud06 ?? "");
|
|
||||||
await svc.load();
|
await svc.load();
|
||||||
return svc;
|
return svc;
|
||||||
|
} else if (t.type === "pubkey") {
|
||||||
|
const profile = await this.system.ProfileLoader.fetchProfile(t.value);
|
||||||
|
if (profile) {
|
||||||
|
const svc = new LNURL(profile.lud16 ?? profile.lud06 ?? "");
|
||||||
|
await svc.load();
|
||||||
|
return svc;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
}catch {
|
||||||
|
// nothing
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -410,6 +410,10 @@ input:disabled {
|
|||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.f-wrap {
|
||||||
|
flex-flow: wrap;
|
||||||
|
}
|
||||||
|
|
||||||
.g2 {
|
.g2 {
|
||||||
gap: 2px;
|
gap: 2px;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user