-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
85 lines (82 loc) · 4.4 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Set inflation pool for Stellar/Trezor account</title>
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css">
<link rel="stylesheet" href="css/index.css">
</head>
<body>
<script src="https://code.jquery.com/jquery-3.3.1.min.js"></script>
<script src="https://connect.trezor.io/6/trezor-connect.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/stellar-sdk/0.11.0/stellar-sdk.js"></script>
<script src="js/model.js"></script>
<script src="js/ui.js"></script>
<div id="notify-panel"></div>
<div class="modal"></div>
<div class="container">
<br />
<p>
An excercise with <a href="https://github.com/trezor/connect">trezor-connect</a> and
<a href="https://github.com/stellar/js-stellar-sdk">js-stellar-sdk</a>. It allows
you to set <a href="https://pool.lumenaut.net/#faq">inflation destination</a>
for Stellar account using your Trezor wallet. Tested with Chrome 70+.
</p>
<p class="small">
THIS SOFTWARE IS NOT AFFILIATED WITH, OR SPONSORED, OR ENDORSED BY THE STELLAR DEVELOPMENT FOUNDATION.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
</p>
<div class="card bg-light">
<div class="card-body">
<div class="form-group">
<label for="account_id" class="font-weight-bold">Account address</label>
<input type="text" class="form-control" id="account_id" value="">
</div>
<button class="btn btn-secondary" onclick="_e(btn_get_account_id)">Get from Trezor</button>
<span class="small">(if you didn't installed Trezor Bridge yet, it may be required)</span>
</div>
</div>
<div class="card bg-light">
<div class="card-body">
<div class="form-group">
<label for="name_dest" class="font-weight-bold">Inflation destination</label>
<input type="text" class="form-control" id="inflation_dest">
</div>
<button class="btn btn-secondary" onclick="_e(btn_set_inflation_dest)">Fill lumenaut.net pool
address</button>
<span class="small">...or any other you prefer.</span>
</div>
</div>
<div class="card bg-light">
<div class="card-body">
<div class="form-group">
<label for="xdr" class="font-weight-bold">Signed transaction (XDR)</label>
<textarea class="form-control" rows="5" id="xdr"></textarea>
</div>
<button class="btn btn-secondary" onclick="_e(btn_build_xdr)">Sign transaction with Trezor</button>
→ <button class="btn btn-secondary" onclick="_e(btn_view_xdr)">Verify transaction</button>
→ <button class="btn btn-warning" onclick="_e(btn_submit_xdr)" class=>Submit transaction</button>
<span class="small">← only this yellow button makes real changes.</span>
</div>
</div>
<div class="card bg-light">
<div class="card-body">
<div class="form-group">
<label for="result" class="font-weight-bold">Submitted transaction ID</label>
<input type="text" class="form-control" id="tx_id"></textarea>
</div>
<button class="btn btn-secondary" onclick="_e(btn_view_tx)">View on stellarchain.io</button>
</div>
</div>
<footer class="page-footer">
<div class="small"><a href="https://github.com/kolontsov/stellar-trezor-inflation">GitHub</a>
· Donate XLM: GABVPCRKR57S4BT75JCS6K26P3I6EEP2PBMZUQ6OUSWR4PDH74HOY36T
</div>
</footer>
</div>
</body>
</html>