-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
190 lines (185 loc) · 6.78 KB
/
index.html
File metadata and controls
190 lines (185 loc) · 6.78 KB
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
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="shortcut icon" href="/favicon.ico" type="image/x-icon">
<meta charset="UTF-8">
<title>Commercium Wallet</title>
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.6.3/css/all.css" integrity="sha384-UHRtZLI+pbxtHCWp1t77Bi1L4ZtiqrqD80Kn4Z8NTSRyMA2Fd33n5dQ8lWUE00s/" crossorigin="anonymous">
<link rel="stylesheet" type="text/css" href="css/semantic.min.css">
<link rel="stylesheet" type="text/css" href="css/style.css">
<script src="js/jquery-3.2.1.min.js"></script>
<script src="js/moment.js"></script>
<script src="js/livestamp.js"></script>
<script src="js/semantic.min.js"></script>
<script src="js/axios2.js"></script>
<script src="js/Buffer2.js"></script>
<script src="js/bch.js"></script>
<script src="js/makemnemonic.js"></script>
<script src="js/bitgo-utxo-lib.js"></script>
</head>
<body>
<div id="app">
<div id="sidebar" class="ui sidebar inverted vertical menu visible">
<div class="item">
<br/>
<img class="ui centered image" src="resources/icon.png">
<div class="ui inverted centered header">Commercium Wallet</div>
</div>
<div class="item">
<br/>
<br/>
A simple light web wallet for easy access to Commercium.
<br/>
<br/>
<br/>
</div>
<div class="item">
<div class="three ui buttons">
<button :class="color" class="ui basic top left pointing small dropdown icon button" data-tooltip="Change Fiat Currency" data-position="bottom left">
<i class="money icon"></i>
<div class="menu">
<div class="divider"></div>
<div class="header">
Fiat
</div>
<div class="item" v-for="symbol, code in currencies" @click="updateFiat(code)">
{{ symbol }} {{ code }}
</div>
</div>
</button>
<button :class="color" class="ui basic small icon button" data-tooltip="Delete account" data-position="bottom right" @click="delCookie('phrase')">
<i class="trash icon"></i>
</button>
<button :class="color" class="ui basic small icon button" data-tooltip="Show Private Key" data-position="bottom right" @click="privModal()">
<i class="user secret icon"></i>
</button>
</div>
</div>
</div>
<div id="horizontal" class="ui inverted menu">
<div class="item">
<div class="ui inverted header">Commercium Wallet</div>
<div class="ui three buttons">
<button :class="color" class="ui basic pointing medium dropdown icon button" data-tooltip="Change Fiat Currency" data-position="bottom center">
<i class="large money icon"></i>
<div class="menu">
<div class="divider"></div>
<div class="header">
Fiat
</div>
<div class="item" v-for="symbol, code in currencies" @click="updateFiat(code)">
{{ symbol }} {{ code }}
</div>
</div>
</button>
<button :class="color" class="ui basic small icon button" data-tooltip="Delete account" data-position="bottom center" @click="delCookie('phrase')">
<i class="trash icon"></i>
</button>
<button :class="color" class="ui basic small icon button" data-tooltip="Show Private Key" data-position="bottom right" @click="privModal()">
<i class="user secret icon"></i>
</button>
</div>
</div>
</div>
<div class="pusher">
<div class="ui inverted blue vertical masthead center aligned segment" id="price-header">
<div class="price">
<h1>{{ amount }}</h1>
<h2>{{ fiat_amount }}</h2>
<button :class="color" class="ui button" @click="sendModal()">
<i class="send outline icon"></i>
Send
</button>
<button :class="color" class="ui button" @click="copyAddress()">
<i class="copy icon"></i>
Copy Address
</button>
<h3>{{ address }}</h3>
</div>
</div>
<div class="ui center aligned container" id="transactions">
<h2>Transactions</h2>
<table class="ui very basic compact stackable table">
<thead>
<tr>
<th></th>
<th>Time</th>
<th>Transaction ID</th>
<th>Amount</th>
</tr>
</thead>
<tbody>
<tr v-for="tx in transactions">
<td v-if="tx.vin[0].addr == address">
<i class="medium circular inverted red arrow right icon"></i>
<i v-if="tx.confirmations < 1" class="fas fa-hourglass-start">
</td>
<td v-else-if="tx.vin[0].addr == 'zaddr'">
<i class="medium circular inverted yellow arrow left icon"></i>
<i v-if="tx.confirmations < 1" class="fas fa-hourglass-start">
</td>
<td v-else>
<i class="medium circular inverted green arrow left icon"></i>
<i v-if="tx.confirmations < 1" class="fas fa-hourglass-start">
</td>
<td><span :data-livestamp="tx.time"></span></td>
<td><a :href="baseURL + '/tx/' + tx.txid" target="_blank">{{ tx.txid }}</a></td>
<td v-if="tx.vin[0].addr == address" class="negative">
<!-- -{{ tx.vout[0].value }} {{ symbol }} -->
-{{ getOutputValue2(tx.vout) }} {{ symbol }}
</td>
<td v-else class="positive">
+{{ getOutputValue(tx.vout) }} {{ symbol }}
</td>
</tr>
</tbody>
</table>
</div>
<audio id="audio" src="resources/ding.wav" preload="auto"></audio>
</div>
<div class="ui modal" id="send_modal">
<div class="header">Send Coins</div>
<div class="content">
<div class="ui form">
<div class="field">
<label>Amount (A {{ fee }} {{ symbol }} miner fee is deducted from your balance)</label>
<div class="ui action input">
<input id="send-amount" placeholder="Amount..." type="number">
<button class="ui button" @click="maxAmount()">Max Amount</button>
</div>
</div>
<div class="field">
<label>Recipient Address</label>
<input id="receive-address" placeholder="Address" type="text">
</div>
<button :class="color" class="ui button" id="send-button" @click="sendTransaction()">
Send
</button>
<button class="ui deny button" onclick="$('#send_modal').modal('hide');">
Cancel
</button>
<div v-if="msg.title" :class="msg.status" class="ui message">
<div class="header">{{ msg.title }}</div>
<p>{{ msg.reason }}</p>
</div>
</div>
</div>
</div>
<div class="ui modal" id="priv_modal">
<div class="header">Private Key</div>
<div class="content">
<div class="ui form">
<label>{{ private }}</label>
<br/>
<br/>
<!--button :class="color" class="ui button" id="send-button" @click="copyPriv()">
Copy
</button>-->
</div>
</div>
</div>
</div>
</body>
<script src="js/vue.min.js"></script>
<script src="js/script.js"></script>
</html>