-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
81 lines (76 loc) · 2.9 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
<!DOCTYPE html>
<html lang="en" xmlns:v-on="http://www.w3.org/1999/xhtml">
<head>
<title>ShadowTest</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0/css/materialize.min.css">
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<script src="https://unpkg.com/vue@3"></script>
<script src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script>
</head>
<body>
<div id="app" class="container">
<div class="row center-align" style="margin-top: 30px">
<pre>
__ _ _ _____ _
/ _\ |__ __ _ __| | _____ _/__ \___ ___| |_
\ \| '_ \ / _` |/ _` |/ _ \ \ /\ / / / /\/ _ \/ __| __|
_\ \ | | | (_| | (_| | (_) \ V V / / / | __/\__ \ |_
\__/_| |_|\__,_|\__,_|\___/ \_/\_/ \/ \___||___/\__|
</pre>
</div>
<div class="row center-align">
<span class="input-field">
<input class="waves-effect" v-on:keyup.enter="testProxy" v-model="proxy" placeholder="ss://a key here" type="text"/>
</span>
<a v-on:click="testProxy" class="btn-large red">
<i class="material-icons">refresh</i>
</a>
<div class="left-align">
<h4 v-if="proxyStatus !== ''"><b>Status:</b> {{ proxyStatus }}</h4>
<h4 v-if="proxyLocation !== ''"><b>Location:</b> {{ proxyLocation }}</h4>
<h4 v-if="proxyLocation !== ''"><b>Address:</b> {{ proxyAddress }}</h4>
<h4 v-if="proxyISP !== ''"><b>ISP:</b> {{ proxyISP }}</h4>
</div>
</div>
</div>
</body>
<script>
const {createApp} = Vue
createApp({
data() {
return {
proxyStatus: '',
proxyLocation: '',
proxyAddress: '',
proxyISP: '',
proxy: ''
}
},
methods: {
testProxy() {
this.proxyStatus = 'Testing...';
this.proxyAddress = '';
this.proxyLocation = '';
this.proxyISP = '';
axios.post('/v2/test',
{
'address': this.proxy
}
).then(response => {
if (response.data.error !== undefined) {
this.proxyStatus = 'Offline';
} else {
this.proxyStatus = 'Online';
this.proxyAddress = response.data.YourFuckingIPAddress;
this.proxyLocation = response.data.YourFuckingLocation;
this.proxyISP = response.data.YourFuckingISP;
}
}).catch(error => {
this.proxyStatus = 'Error '+error.response.data;
});
}
}
}).mount('#app')
</script>
</html>