janoside / btc-rpc-explorer

Database-free, self-hosted Bitcoin explorer, via RPC to Bitcoin Core.
https://bitcoinexplorer.org
MIT License
1.52k stars 1.13k forks source link

Feature: search by xpub/ypub/zpub #298

Open pointbiz opened 3 years ago

pointbiz commented 3 years ago

The search box could accept an xpub or ypub or zpub.

The results page would show all the transactions related to addresses that belong to the xpub/ypub/zpub.

janoside commented 2 years ago

Cleaning up. At least v1.0 of this feature is done.

schildbach commented 2 years ago

I think last I tested this, only addresses were derived but no related transactions shown. I'll re-test this soon.

janoside commented 2 years ago

Whoops...that's my fault for scanning a little too fast. You're correct, transactions are NOT currently shown.

pointbiz commented 2 years ago

https://github.com/janoside/btc-rpc-explorer/pull/336#issuecomment-856928416

I mentioned a possible implementation idea in the above comment.

pointbiz commented 1 year ago

I'd like to think about the UI for showing transactions belonging to an xpub.

It seems to me there's usefulness in seeing the receive and change addresses and being able to navigate them using pagination.

However, I visualize the UI similarly to the Address Page UI where you see a list of transactions that you can navigate via pagination.

How do we resolve the need for two elements to need pagination if we display them together?

What are the possible solutions? Do we have the xpub summary page then have two links to choose if you want to see addresses or transactions? Then display those as their own separate pages? With routes like xyzpub/{xpub} xyzpub/{xpub}/addresses xyzpub/{xpub}/transactions

Side note: calculating the balance might be costly, need to double check, maybe it can be excluded for now.