+
Transactions
+
+
+
+
{{template "paging" $data}}
- {{- range $tx := $addr.Transactions}}{{$data := setTxToTemplateData $data $tx}}{{template "txdetail" $data}}{{end -}}
+
+ {{range $tx := $addr.Transactions}}{{$data := setTxToTemplateData $data $tx}}{{template "txdetail" $data}}{{end}}
{{template "paging" $data }}
{{end}}{{end}}
\ No newline at end of file
diff --git a/static/templates/block.html b/static/templates/block.html
index 4ee93b7b..9edcfd24 100644
--- a/static/templates/block.html
+++ b/static/templates/block.html
@@ -1,4 +1,4 @@
-{{define "specific"}}{{$cs := .CoinShortcut}}{{$b := .Block}}{{$data := . -}}
+{{define "specific"}}{{$cs := .CoinShortcut}}{{$b := .Block}}{{$data := .}}
Block
-
Transactions
+{{if $b.Transactions}}
+
+
Transactions
{{template "paging" $data}}
- {{- range $tx := $b.Transactions}}{{$data := setTxToTemplateData $data $tx}}{{template "txdetail" $data}}{{end -}}
+ {{range $tx := $b.Transactions}}{{$data := setTxToTemplateData $data $tx}}{{template "txdetail" $data}}{{end}}
{{template "paging" $data }}
{{end}}{{end}}
\ No newline at end of file
diff --git a/static/templates/blocks.html b/static/templates/blocks.html
index 01349c7b..23017a6e 100644
--- a/static/templates/blocks.html
+++ b/static/templates/blocks.html
@@ -3,7 +3,7 @@
Blocks
{{if $blocks.Blocks}}{{template "paging" $data }}{{end}}
-{{if $blocks.Blocks -}}
+{{if $blocks.Blocks}}
@@ -16,7 +16,7 @@
- {{- range $b := $blocks.Blocks -}}
+ {{range $b := $blocks.Blocks}}
| {{formatUint32 $b.Height}} |
{{$b.Hash}} |
@@ -24,7 +24,7 @@
{{formatUint32 $b.Txs}} |
{{formatUint32 $b.Size}} |
- {{- end -}}
+ {{end}}
diff --git a/static/templates/index.html b/static/templates/index.html
index a5da0f92..b7e23060 100644
--- a/static/templates/index.html
+++ b/static/templates/index.html
@@ -1,11 +1,11 @@
{{define "specific"}}{{$cs := .CoinShortcut}}{{$bb := .Info.Blockbook}}{{$be := .Info.Backend}}
Application status
-{{- if $bb.InitialSync -}}
+{{if $bb.InitialSync}}
Application is now in initial synchronization and does not provide any data.
-{{- end -}}
-{{- if not $bb.SyncMode -}}
+{{end}}
+{{if not $bb.SyncMode}}
Synchronization with backend is disabled, the state of index is not up to date.
-{{- end -}}
+{{end}}
@@ -50,7 +50,7 @@
| Transactions in Mempool |
{{if .InternalExplorer}}{{$bb.MempoolSize}}{{else}}{{formatInt $bb.MempoolSize}}{{end}} |
- {{- if $bb.HasFiatRates -}}
+ {{if $bb.HasFiatRates}}
| Current Fiat rates |
{{formatTime $bb.CurrentFiatRatesTime}} |
@@ -59,7 +59,7 @@
Historical Fiat rates |
{{formatTime $bb.HistoricalFiatRatesTime}}{{if $bb.HasTokenFiatRates}} tokens {{formatTime $bb.HistoricalTokenFiatRatesTime}}{{end}} |
- {{- end -}}
+ {{end}}
| Size On Disk |
{{formatInt64 $bb.DbSize}} |
@@ -67,19 +67,19 @@
-
+
Backend |
|
- {{- if $be.BackendError -}}
+ {{if $be.BackendError}}
| Backend Error |
{{$be.BackendError}} |
- {{- end -}}
+ {{end}}
| Chain |
{{$be.Chain}} |
@@ -88,24 +88,24 @@
Version |
{{$be.Version}} |
- {{- if $be.Subversion -}}
+ {{if $be.Subversion}}
| Subversion |
{{$be.Subversion}} |
- {{- end -}}
- {{- if $be.ProtocolVersion -}}
+ {{end}}
+ {{if $be.ProtocolVersion}}
| Protocol Version |
{{$be.ProtocolVersion}} |
- {{- end -}}
- {{- if $be.ConsensusVersion -}}
+ {{end}}
+ {{if $be.ConsensusVersion}}
| Consensus Version |
{{$be.ConsensusVersion}} |
- {{- end -}}
+ {{end}}
| Last Block |
{{formatInt $be.Blocks}} |
@@ -114,30 +114,30 @@
Difficulty |
{{$be.Difficulty}} |
- {{- if $be.Timeoffset -}}
+ {{if $be.Timeoffset}}
| Timeoffset |
{{$be.Timeoffset}} |
- {{- end -}}
- {{- if $be.SizeOnDisk -}}
+ {{end}}
+ {{if $be.SizeOnDisk}}
| Size On Disk |
{{formatInt64 $be.SizeOnDisk}} |
- {{- end -}}
- {{- if $be.Consensus -}}
+ {{end}}
+ {{if $be.Consensus}}
| Consensus |
{{toJSON $be.Consensus}} |
- {{- end -}}
- {{- if $be.Warnings -}}
+ {{end}}
+ {{if $be.Warnings}}
| Warnings |
{{$be.Warnings}} |
- {{- end -}}
+ {{end}}
diff --git a/static/templates/sendtx.html b/static/templates/sendtx.html
index 086925ca..40fef464 100644
--- a/static/templates/sendtx.html
+++ b/static/templates/sendtx.html
@@ -1,16 +1,16 @@
-{{define "specific" -}}
+{{define "specific"}}
Send Raw Transaction
-{{- if .Status -}}
-
{{.Status}}
-{{- end -}}
-{{- if .Error -}}
-
{{.Error.Text}}
-{{- end -}}
-{{- end -}}
\ No newline at end of file
+{{if .Status}}
+
{{.Status}}
+{{end}}
+{{if .Error}}
+
{{.Error.Text}}
+{{end}}
+{{end}}
\ No newline at end of file
diff --git a/static/templates/tx.html b/static/templates/tx.html
index 1f5e69bc..7eba2b8f 100644
--- a/static/templates/tx.html
+++ b/static/templates/tx.html
@@ -1,4 +1,4 @@
-{{define "specific"}}{{$cs := .CoinShortcut}}{{$tx := .Tx}}
+{{define "specific"}}{{$tx := .Tx}}{{$data := .}}
Transaction
@@ -7,7 +7,7 @@
- {{- if $tx.Confirmations -}}
+ {{if $tx.Confirmations}}
| Mined Time |
{{formatUnixTime $tx.Blocktime}} |
@@ -22,26 +22,26 @@
In Block Height |
{{formatInt $tx.Blockheight}} |
{{end}}
- {{- if $tx.EthereumSpecific -}}
+ {{if $tx.EthereumSpecific}}
| Status |
{{if $tx.EthereumSpecific.Status}}
{{if eq $tx.EthereumSpecific.Status 1}}
- Success |
+ Success |
{{else}}
- {{if eq $tx.EthereumSpecific.Status -1}}
+ {{if eq $tx.EthereumSpecific.Status 1}}
Pending |
{{else}}
Unknown |
{{end}}
{{end}}
{{else}}
- Fail{{if $tx.EthereumSpecific.Error}} ({{$tx.EthereumSpecific.Error}}){{end}} |
+ Failed{{if $tx.EthereumSpecific.Error}} {{$tx.EthereumSpecific.Error}}{{end}} |
{{end}}
| Value |
- {{formatAmount $tx.ValueOutSat}} {{$cs}} |
+ {{amount $tx.ValueOutSat $data "copyable"}} |
| Gas Used / Limit |
@@ -49,16 +49,16 @@
| Gas Price |
- {{formatAmount $tx.EthereumSpecific.GasPrice}} {{$cs}} |
+ {{amount $tx.EthereumSpecific.GasPrice $data "copyable"}} |
- {{- else -}}
+ {{else}}
| Total Input |
- {{formatAmount $tx.ValueInSat}} {{$cs}} |
+ {{amount $tx.ValueInSat $data "copyable"}} |
| Total Output |
- {{formatAmount $tx.ValueOutSat}} {{$cs}} |
+ {{amount $tx.ValueOutSat $data "copyable"}} |
{{if $tx.VSize}}
@@ -71,26 +71,26 @@
| Size |
{{formatInt $tx.Size}} |
- {{- end -}}
- {{- end -}}
- {{- end -}}
- {{- if $tx.FeesSat -}}
+ {{end}}
+ {{end}}
+ {{end}}
+ {{if $tx.FeesSat}}
| Fees |
- {{formatAmount $tx.FeesSat}} {{$cs}}{{if $tx.Size}} ({{feePerByte $tx}}){{end}} |
-
{{end -}}
+ {{amount $tx.FeesSat $data "copyable"}}{{if $tx.Size}} ({{feePerByte $tx}}){{end}} |
+ {{end}}
{{if not $tx.Confirmations}}
| RBF |
{{if $tx.Rbf}}
- ON
+ ON
{{else}}
OFF️
{{end}}
|
- {{end -}}
+ {{end}}
Details
diff --git a/static/templates/txdetail.html b/static/templates/txdetail.html
index 49ae9543..8dc50703 100644
--- a/static/templates/txdetail.html
+++ b/static/templates/txdetail.html
@@ -3,9 +3,9 @@
{{$tx.Txid}}
- {{- if $tx.Rbf}}
RBF{{end -}}
+ {{if $tx.Rbf}}
RBF{{end}}
- {{- if $tx.Blocktime}}
{{if $tx.Confirmations}}mined{{else}}first seen{{end}} {{formatUnixTime $tx.Blocktime}}
{{end -}}
+ {{if $tx.Blocktime}}
{{if $tx.Confirmations}}mined{{else}}first seen{{end}} {{formatUnixTime $tx.Blocktime}}
{{end}}
@@ -32,15 +32,15 @@
- {{- range $vout := $tx.Vout -}}
+ {{range $vout := $tx.Vout}}
{{range $a := $vout.Addresses}}
{{if and (ne $a $addr) $vout.IsAddress}}{{$a}}{{else}}{{$a}}{{end}}
- {{- else -}}
+ {{else}}
Unparsed address
- {{- end -}}
+ {{end}}
{{amount $vout.ValueSat $data "copyable"}}{{if $vout.Spent}}→{{else}}×
{{end}}
@@ -55,17 +55,17 @@