Podcastindex-org/helipad

Show actual sats received?

Closed this issue · 2 comments

Since splits will change every recipient's amount. Show each person the actual sats they received (while still showing the total boost amount).

I barely know what I'm doing, but managed to modify home.js to split off msat & msat_total...

let boostSats = Math.trunc(element.value_msat / 1000);
let boostTotal = Math.trunc(element.value_msat_total / 1000);

...then did some math on the display to show sats, percent split, & boost total...

<h5 class="sats">' + boostSats + ' sats <small>(' + Math.trunc(boostSats/boostTotal*100) + '% of ' + boostTotal + ' sats) ' + boostSender + '</small></h5>
Helipad

I'm sure this isn't the best display (or code). Feel free to come up with a better solution. The main purpose is to show what someone actually received (based on their perspective/split).

I suppose if msat == msat_total, you could display the old/current way since it's 100% (no splits).

Cameron

Listening to PC20 show 91 about app fees and split payments. Adam mentioned he only looks at the total number and doesn't know what he's getting. Would this change be helpful?

I can make a PR if necessary. Or is helipad being completely rewritten (there's a rumor)?

I can def do this. I'm going to be revisiting Helipad soon.