You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

132 lines
4.3 KiB

extends layout
block headContent
title Address #{address}
block content
if (result && result.validateaddress)
if (!result.validateaddress.isvalid)
h1(class="h3 text-danger") Invalid Address
br
small(class="monospace") #{address}
else
h1(class="h3") Address
br
small(class="monospace") #{address}
hr
if (payoutAddressForMiner)
div(class="alert alert-primary", style="padding-bottom: 0;")
7 years ago
div(class="float-left", style="width: 50px; height: 50px; font-size: 18px;")
i(class="fas fa-certificate fa-2x", style="margin-top: 10px;")
h4(class="alert-heading h5") #{coinConfig.name} Fun
p
span This looks like a miner payout address for
span(class="font-weight-bold") #{payoutAddressForMiner.name}
if (coinConfig.miningPoolsConfigUrls.length > 1)
span (see the configurations:
each item, index in coinConfig.miningPoolsConfigUrls
if (index > 0)
span ,
a(href=item) config ##{index + 1}
span )
else
span (see the configuration
a(href=coinConfig.miningPoolsConfigUrls[0]) here
span )
if (false)
pre
code #{JSON.stringify(addressObj, null, 4)}
ul(class='nav nav-tabs mb-3')
li(class="nav-item")
7 years ago
a(data-toggle="tab", href="#tab-details", class="nav-link active", role="tab") Details
li(class="nav-item")
a(data-toggle="tab", href="#tab-json", class="nav-link", role="tab") JSON
div(class="tab-content")
7 years ago
div(id="tab-details", class="tab-pane active", role="tabpanel")
7 years ago
div(class="card mb-3")
div(class="card-header")
span(class="h6") Summary
div(class="card-body")
if (addressObj.hash)
div(class="row")
div(class="summary-table-label") Hash 160
div(class="summary-table-content monospace") #{addressObj.hash.toString("hex")}
if (result.validateaddress.scriptPubKey)
div(class="row")
div(class="summary-table-label") Script Public Key
div(class="summary-table-content monospace") #{result.validateaddress.scriptPubKey}
7 years ago
if (addressObj.hasOwnProperty("version"))
div(class="row")
div(class="summary-table-label") Version
div(class="summary-table-content monospace") #{addressObj.version}
if (result.validateaddress.hasOwnProperty("witness_version"))
div(class="row")
div(class="summary-table-label") Witness Version
div(class="summary-table-content monospace") #{result.validateaddress.witness_version}
if (result.validateaddress.witness_program)
div(class="row")
div(class="summary-table-label") Witness Program
div(class="summary-table-content monospace") #{result.validateaddress.witness_program}
div(class="row")
div(class="summary-table-label") QR Code
div(class="summary-table-content monospace")
img(src=addressQrCodeUrl, alt=address, style="border: solid 1px #ccc;")
div(class="card mb-3")
div(class="card-header")
span(class="h6") Flags
div(class="card-body")
table(class="table table-responsive-sm text-center")
thead
tr
th Is Valid?
th Is Script?
th Is Witness?
th Is Mine?
th Is Watch-Only?
tbody
tr
- var x = result.validateaddress;
- var flags = [x.isvalid, x.isscript, x.iswitness, x.ismine, x.iswatchonly];
each flag in flags
td
if (flag)
i(class="fas fa-check text-success")
else
i(class="fas fa-times text-danger")
div(class="card")
div(class="card-header")
span(class="h6") Transactions
div(class="card-body")
table(class="table")
strong
p(class="text-warning") This is a work-in-progress
p Since this app is database-free, displaying a list of transactions involving the current address is tricky. I'm actively researching the best way to implement this.
a(href="https://github.com/janoside/btc-rpc-explorer/issues/8") Suggestions and/or pull requests are welcome!
div(id="tab-json", class="tab-pane", role="tabpanel")
div(class="highlight")
pre
code(class="language-json", data-lang="json") #{JSON.stringify(result.validateaddress, null, 4)}