-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathimtoken-activity.html
More file actions
145 lines (117 loc) · 5.24 KB
/
imtoken-activity.html
File metadata and controls
145 lines (117 loc) · 5.24 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<link rel="stylesheet" href="./src/css/imtoken_activity2.css" id="changecss">
<link rel="shortcut icon" href="./favicon.ico">
<style>
@font-face {
font-family: NotoSansHans-Regular;
src: url('./src/font/Roboto-Regular.ttf')
}
</style>
<title>imtoken-activity</title>
</head>
<body>
<div class="bg0">
<div class="bg">
<div class="b_div content_zh">
<div class="topbtn">
<a href="http://t.cn/AidyUp8A">存USDx</a>
<a class="got_usdx">购买USDx</a>
</div>
<div class="top_one">
<p class="title"><span>USDx剩余额度:</span> <span class="color">-</span></p>
<p class="title"><span>活动时间:</span> 2019年11月22日至12月05日</p>
<p class="title"><span>认购额度:</span> 150,000 USDx</p>
</div>
<div class="top_two">
<h5>参与规则</h5>
<ul>
<li>1. 仅限imToken钱包的用户参与 </li>
<li>2. 单笔最低存款金额为100 USDx,最高为10,000 USDx</li>
<li>3. 超出认购额度的USDx存款将按市场利息结算(目前年化存款利息约为8%)</li>
<li>4. 补贴收益将于12月06日中午12点前发放到用户存币地址</li>
</ul>
<a href="https://www.bilibili.com/video/av76239970/" target="_blank" class="jiaocheng">存款教程</a>
</div>
</div>
<!-- --- --- --- --- 分割线 --- --- --- --- -->
<div class="b_div content_en" style="display: none;">
<div class="topbtn">
<a href="http://t.cn/AidyUp8A">Save USDx</a>
<a class="got_usdx">Get USDx</a>
</div>
<div class="top_one">
<p class="title"><span>Remaining Balance: </span> <span class="color">-</span></p>
<p class="title"><span>Subscription Period: </span> Nov 22 to Dec 5, 2019</p>
<p class="title"><span>Total USDx available: </span> 150,000 USDx</p>
</div>
<div class="top_two">
<h5>IMPORTANT</h5>
<ul>
<li>1. Accessible from imToken only </li>
<li>2. Subscribe from 100 USDx up to 10,000 USDx per user</li>
<li>3. Subscriptions exceeding maximum supply (150,000 USDx) will be based on actual yielding
(Saving APR is around 8%)</li>
<li>4. Extra yielding will be allocated to the same address of entitled participants before
12:00 GMT+8:00, 6 Dec, 2019.</li>
</ul>
<a href="https://www.youtube.com/watch?v=cwfCne_PJus" target="_blank" class="jiaocheng">USDx Saving
Guide</a>
</div>
</div>
</div>
</div>
</body>
<script src="./src/js/jquery.min.js"></script>
<script>
$(function () {
console.log(navigator.language);
console.log(navigator.language === 'zh-CN');
// alert(navigator.language === 'zh-CN');
if (!(navigator.language === 'zh-CN')) {
console.log('111111: 英文环境')
$('.content_zh').css('display', 'none');
$('.content_en').css('display', 'block');
$('.bg').css({ 'background': "url('./src/images/imtoken_bg_en1.png') no-repeat center 0px", "backgroundSize": "100%" });
} else {
console.log('222222: 中文环境')
$('.content_zh').css('display', 'block');
$('.content_en').css('display', 'none');
$('.bg').css({ 'background': "url('./src/images/imtoken_bg1.png') no-repeat center 0px", "backgroundSize": "100%" });
}
// https://dforce.network/imtoken-activity.html
var now = new Date();
var number = now.getTime().toString();
var url = 'https://dforce.network/num.json?' + number;
$.get(url).done(function (data) {
// console.log('loding...')
if (data) {
console.log(data.num)
var input_str = format(data.num) + ' USDx';
$('.color').html(input_str)
} else {
console.log('没有数据.')
}
});
function format(num) {
var reg = /\d{1,3}(?=(\d{3})+$)/g;
return (num + '').replace(reg, '$&,');
}
$('.got_usdx').click((e) => {
e.preventDefault();
console.log(e);
if (window.ethereum.isImToken) {
imToken.callPromisifyAPI('navigator.routeTo', {
screen: 'Tokenlon',
})
} else {
alert('u are not in imToken now. pls do this in imToken.')
}
})
});
</script>
</html>