Add node peers, blue banners, glowing diff ranges, fix back navigation

- Show Bitcoin Core peer count on block height card (hover for in/out)
- BestSharePage disclaimers now use solid blue styling
- Difficulty distribution ranges glow from warm peach to deep red
- Back-to-dashboard buttons always navigate to dashboard instead of
  using browser history
This commit is contained in:
satoshi
2026-05-19 02:34:15 +03:00
parent daa87e2352
commit e341fd7b26
7 changed files with 73 additions and 21 deletions
+14
View File
@@ -343,6 +343,20 @@ func (c *RPC) GetRawMempoolVerbose(ctx context.Context) (map[string]RawMempoolEn
return out, nil
}
type NetworkInfo struct {
Connections int `json:"connections"`
ConnectionsIn int `json:"connections_in"`
ConnectionsOut int `json:"connections_out"`
}
func (c *RPC) GetNetworkInfo(ctx context.Context) (*NetworkInfo, error) {
var out NetworkInfo
if err := c.Call(ctx, "getnetworkinfo", nil, &out); err != nil {
return nil, err
}
return &out, nil
}
// IsRPCError checks if err is an rpcError with a specific code.
func IsRPCError(err error, code int) bool {
var rerr *rpcError