-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.svelte
72 lines (68 loc) · 1.28 KB
/
index.svelte
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
<script>
import Buy from "../components/Buy.svelte";
import Sell from "../components/Sell.svelte";
import PercentCalc from "../components/PercentCalc.svelte";
$: myfees = 0.5;
</script>
<svelte:head>
<title>Bitcoin Project</title>
</svelte:head>
<div class="box">
<div bp="grid">
<div class="setNumbers" bp="4 offset-5">
<p>
fees: <input
type="number"
min="0"
max="100"
bind:value={myfees}
class="fees"
step="0.05"
/>%
</p>
</div>
</div>
<hr />
<Buy fees={myfees} />
<hr />
<Sell fees={myfees} />
</div>
<div id="per">
<PercentCalc />
</div>
<style>
:global(p) {
font-family: "Courier New", Courier, monospace;
}
hr {
color: #ccc;
width: 50%;
}
.box,
#per {
width: 600px;
border: 1px solid #ccc;
border-bottom: 3px solid #ccc;
border-right: 3px solid #ccc;
margin: 20px auto;
padding: 10px;
}
:global(div) {
text-align: center;
}
.fees {
width: 5em;
text-align: center;
border: none;
}
:global(input) {
font-family: "Courier New", Courier, monospace;
background-color: #eee;
padding: 0 0.5em;
border: none;
}
:global(.result) {
text-align: center;
margin: 0px 0px;
}
</style>