PathrockNetwork Gno Explorer
HomeBlocksTransactionsTokensRealmsPackagesValidatorsAnalytics

PathrockNetwork Gno Explorer — an independent explorer for Gno.land Mainnet (gnoland-1), operated by PathrockNetwork. Not an official Gno.land service.

gnowebarchive RPC

gno.land/r/g1leu8d2vsplhehcfkjg50mwgdpxdkt8tztu95wr/bubble

Realm
Open in gnoweb ↗

Overview

Kind
Realm (renderable)
Name
bubble
Namespace
g1leu8d2vsplhehcfkjg50mwgdpxdkt8tztu95wr
Files
7 (gnomod.toml)
Exported functions
54
Module
gno.land/r/g1leu8d2vsplhehcfkjg50mwgdpxdkt8tztu95wr/bubble
gno
0.9

Files (7)

  • gnomod.tomltoml
  • admin.gnogno
  • govern.gnogno
  • kinds.gnogno
  • mint.gnogno
  • render.gnogno
  • token.gnogno
render.gnogno
1package bubble23import (4	"strconv"5	"strings"6)78

Functions

  • Admin() string

  • Allowance(owner string, spender string) int64

  • Approve(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, spender string, amount int64)

  • BalanceOf(owner string) int64

  • Batches() int64

  • Burn(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, amount int64)

  • Cancel(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, id int64)

  • DayCap() int64

  • Delegate(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, to string)

  • DelegateOf(who string) string

  • Describe(id int64) string

  • Epoch() uint32

  • Execute(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, id int64)

  • GetDecimals() int

  • GetName() string

  • GetSymbol() string

  • HasVoted(id int64, who string) bool

  • KindRules(name string) (struct{QuorumBps int64; ThresholdBps int64; ProposeBps int64; VotingBlocks int64; DelayBlocks int64; GraceBlocks int64}, bool)

  • LastBatch() string

  • MeanTurnout() int64

  • Mint(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, to string, amount int64)

  • MintedToday() (minted int64, ceiling int64)

  • Minter() string

  • MintMany(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, batchID string, list string)

  • NewRules(quorumBps int64, thresholdBps int64, votingBlocks int64, delayBlocks int64, graceBlocks int64, proposeBps int64) struct{QuorumBps int64; ThresholdBps int64; ProposeBps int64; VotingBlocks int64; DelayBlocks int64; GraceBlocks int64}

  • Offer(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, k interface {Check func(string) .uverse.error; Describe func(string) string; Do func(int, .uverse.realm, string) .uverse.error; Name func() string}, r struct{QuorumBps int64; ThresholdBps int64; ProposeBps int64; VotingBlocks int64; DelayBlocks int64; GraceBlocks int64})

  • PastTotalVotes(at uint32) int64

  • PastVotes(who string, at uint32) int64

  • Paused() bool

  • Premined() int64

  • Preview(kind string, payload string) string

  • Propose(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, kind string, payload string, title string) int64

  • ReferralMinted() int64

  • ReleaseRoll(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, id int64)

  • Render(path string) string

  • RenounceAdmin(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string})

  • ReserveMinted() int64

  • SetAdmin(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, to string)

  • SetDayCap(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, n int64)

  • SetMinter(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, to string)

  • SetPaused(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, on bool)

  • Settle(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, id int64)

  • State(id int64) string

  • Sweep(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string})

  • Tally(id int64) (yes int64, no int64, abstain int64, total int64)

  • TextOnly(s string) interface {Error func() string}

  • Timings(id int64) (opened int64, closes int64, ready int64, expires int64)

  • TotalSupply() int64

  • Transfer(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, to string, amount int64)

  • TransferFrom(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, from string, to string, amount int64)

  • Vote(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, id int64, choice string)

  • VoteOf(id int64, who string) (choice string, weight int64, ok bool)

  • VotesOf(who string) int64

  • VoteWithReason(cur interface {.seal func(); Address func() .uverse.address; IsCode func() bool; IsCurrent func() bool; IsEphemeral func() bool; IsUser func() bool; IsUserCall func() bool; IsUserRun func() bool; PkgPath func() string; Previous func() .uverse.realm; String func() string; Sub func(string) .uverse.realm; Subpath func() string}, id int64, choice string, reason string)

Signatures reconstructed verbatim from vm/qfuncs — interface params keep their inline definitions.

Rendered

RenderedRawgnoweb ↗
// Render: "" the front page (the token's figures, then the governor's page); "gov/…" the governor's pages alone;
9// "json" the figures for the box; "me/<addr>" one holder's balance and votes.
10func Render(path string) string {
11 path = strings.Trim(path, "/")
12 switch {
13 case path == "json":
14 return jsonAll()
15 case strings.HasPrefix(path, "me/"):
16 a := address(path[3:])
17 return "{\"addr\":\"" + a.String() + "\",\"balance\":" + itoa(ledger.BalanceOf(a)) + ",\"votes\":" + itoa(ledger.VotesOf(a)) +
18 ",\"delegate\":\"" + ledger.DelegateOf(a).String() + "\"}"
19 case strings.HasPrefix(path, "gov"):
20 return engine.Render(strings.TrimPrefix(strings.TrimPrefix(path, "gov"), "/"), notes())
21 default:
22 return engine.Render(path, notes())
23 }
24}
25
26// notes are this realm's lines on the governor's front page: the figures the engine cannot know.
27func notes() string {
28 var b strings.Builder
29 b.WriteString("- supply: " + whole(ledger.TotalSupply()) + " of " + whole(MaxSupply) + " BUBBLE (premine " + whole(premined) +
30 ", referrals " + whole(referralMinted) + " of " + whole(ReferralPool) + ", reserve " + whole(reserveMinted) + " of " + whole(Reserve) + ")\n")
31 minted, ceiling := MintedToday()
32 b.WriteString("- today: " + whole(minted) + " of " + whole(ceiling) + " BUBBLE minted; batches " + itoa(batches) + "\n")
33 if admin == "" {
34 b.WriteString("- **the admin is gone** — every setting moves by vote\n")
35 } else {
36 b.WriteString("- admin: " + admin.String() + "\n")
37 }
38 if minter == "" {
39 b.WriteString("- **nobody mints** — the holders can name a minter\n")
40 } else {
41 b.WriteString("- minter: " + minter.String() + (map[bool]string{true: " (paused)", false: ""})[paused] + "\n")
42 }
43 b.WriteString("- a money vote's turnout bar follows the holders: a fifth of the supply, or the mean turnout of the last money votes when that is higher (mean now " + whole(meanTurnout()) + "), never above a third; the reserve moves at most " + whole(ReserveMaxPer) + " a proposal, ninety days apart\n")
44 return b.String()
45}
46
47func jsonAll() string {
48 minted, ceiling := MintedToday()
49 return "{\"name\":\"" + tokenName + "\",\"symbol\":\"" + tokenSymbol + "\",\"decimals\":" + strconv.Itoa(tokenDecimals) +
50 ",\"supply\":" + itoa(ledger.TotalSupply()) + ",\"max\":" + itoa(MaxSupply) + ",\"premine\":" + itoa(premined) +
51 ",\"referralMinted\":" + itoa(referralMinted) + ",\"referralPool\":" + itoa(ReferralPool) +
52 ",\"reserveMinted\":" + itoa(reserveMinted) + ",\"reserve\":" + itoa(Reserve) +
53 ",\"dayCap\":" + itoa(ceiling) + ",\"mintedToday\":" + itoa(minted) + ",\"day\":" + itoa(dayOf()) +
54 ",\"paused\":" + strconv.FormatBool(paused) + ",\"admin\":\"" + admin.String() + "\",\"minter\":\"" + minter.String() +
55 "\",\"lastBatch\":\"" + lastBatch + "\",\"batches\":" + itoa(batches) + ",\"epoch\":" + strconv.FormatUint(uint64(ledger.Epoch()), 10) +
56 ",\"height\":" + itoa(ledger.Height()) + ",\"now\":" + itoa(ledger.Now()) + "}"
57}
58
59func itoa(n int64) string { return strconv.FormatInt(n, 10) }
60

vm/qrender output, sanitized (docs/render-security.md) and displayed in an empty-sandbox iframe — scripts, forms and popups cannot run. Links stay inert in-preview; right-click to open.