Skip to content
This repository has been archived by the owner on Nov 24, 2024. It is now read-only.

Commit

Permalink
v1.8 امکان جستجوی تازه
Browse files Browse the repository at this point in the history
  • Loading branch information
ircfspace committed Apr 13, 2023
1 parent 5707b42 commit 588200b
Show file tree
Hide file tree
Showing 3 changed files with 68 additions and 4 deletions.
33 changes: 33 additions & 0 deletions assets/css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,39 @@ button {
.scanner .input-group-btn {
width: 20%!important;
}
.scanner .input-group-btn .btn-group {
float: right;
width: 100%;
}
.scanner .input-group-btn .btn-group .input-group-btn {
float: right;
width: auto;
}
.scanner .input-group-btn .prmScan {
float: right;
width: calc(100% - 20px)!important;
border-radius: 0!important;
padding-right: 5px;
padding-left: 5px;
}
.scanner .input-group-btn .scanOpt {
float: left;
width: 20px;
}
.scanner .input-group-btn .scanOpt button {
float: left;
width: 100%!important;
padding-right: 0;
padding-left: 0;
border-radius: 3px 0 0 3px!important;
}
.scanner .input-group-btn .scanOpt button .caret {
margin: 8px 0 8px -1px;
}
.scanner .input-group-btn .scanOpt .dropdown-menu {
right: inherit;
left: 0;
}

.modalBodyOverflow {
max-height: 63vh;
Expand Down
23 changes: 22 additions & 1 deletion assets/js/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ function startScan() {
let selectedIPs = getMultipleRandomElements(ips, num);
testIPs(selectedIPs, num, ping, beta);
document.getElementById('scanBtn').disabled = true;
document.getElementById('newScan').disabled = true;
document.getElementById('tableResults').classList.remove("hidden");
document.getElementById('process').classList.remove("hidden");
document.getElementById('download-text').classList.add("hidden");
Expand Down Expand Up @@ -115,11 +116,11 @@ async function testIPs(ipList, totalIp, timeout, betaVersion) {
}
else {
document.getElementById('download-text').classList.add("hidden");
document.getElementById('process').classList.add("hidden");
}
document.getElementById('process').classList.add("hidden");
$('#progressBar div').removeClass('progress-bar-striped active').css('width', '100%');
document.getElementById('scanBtn').disabled = false;
document.getElementById('newScan').disabled = false;
document.getElementById('ranges').disabled = false;
document.getElementById('download-num').disabled = false;
document.getElementById('max-ping').disabled = false;
Expand All @@ -128,6 +129,25 @@ async function testIPs(ipList, totalIp, timeout, betaVersion) {
$('input[name="forProvider"]').prop("disabled", false);
}

function newScan() {
testNo = 0;
validIPs = [];
testResult = 0;
document.getElementById('result').innerHTML = "";
document.getElementById('download-text').classList.add("hidden");
document.getElementById('process').classList.add("hidden");
$('#progressBar div').removeClass('progress-bar-striped active').css('width', '100%');
document.getElementById('scanBtn').disabled = false;
document.getElementById('newScan').disabled = false;
document.getElementById('ranges').disabled = false;
document.getElementById('download-num').disabled = false;
document.getElementById('max-ping').disabled = false;
document.getElementById('random').disabled = false;
document.getElementById('beta').disabled = false;
$('input[name="forProvider"]').prop("disabled", false);
startScan();
}

function cidrToIpArray(cidr) {
const parts = cidr.split('/');
const ip = parts[0];
Expand Down Expand Up @@ -452,4 +472,5 @@ function setOptions() {
$('#ranges').append($('<option></option>').val((p)).html(p+ ' ('+totalIp+' IP)'));
});
document.getElementById('scanBtn').disabled = false;
document.getElementById('newScan').disabled = false;
}
16 changes: 13 additions & 3 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<link href="./assets/css/bootstrap.min.css" rel="stylesheet" />
<link href="./assets/css/bootstrap-rtl.min.css" rel="stylesheet" />
<link href="./assets/css/vazir.css" rel="stylesheet" />
<link href="./assets/css/style.css?v1.6.5" rel="stylesheet" />
<link href="./assets/css/style.css?v1.8.0" rel="stylesheet" />
<title>IRCF | اسکنر آی‌پی کلودفلر</title>
<meta name="description" content="آی پی سالم و تمیز برای کلودفلر (کلادفلر) جهت دسترسی به اینترنت آزاد" />
<meta name="keywords" content="کلودفلر, کلادفلر, cloudflare, cf, آی پی تمیز, آی پی سالم, اسکن آی پی" />
Expand All @@ -14,7 +14,7 @@
<script src="./assets/js/jquery.min.js"></script>
<script src="./assets/js/bootstrap.min.js"></script>
<script src="./assets/js/ranges.js?v1.7.5"></script>
<script src="./assets/js/script.js?v1.7.5"></script>
<script src="./assets/js/script.js?v1.8.0"></script>
<meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests" />
<meta charset="UTF-8" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
Expand Down Expand Up @@ -79,7 +79,17 @@ <h1>اینترنت برای همه؛ یا هیچ‌کس!</h1>
<span class="input-group-addon">آی‌پی <small>با حداکثر</small> پینگ</span>
<input id="max-ping" type="number" min="100" max="3000" step="100" value="1000" class="form-control dirLeft" />
<div class="input-group-btn">
<button id="scanBtn" onclick="startScan()" class="btn btn-info" disabled>اسکن</button>
<div class="btn-group">
<button id="scanBtn" onclick="startScan()" class="btn btn-info prmScan" disabled>اسکن</button>
<div class="btn-group scanOpt">
<button type="button" class="btn btn-info dropdown-toggle" data-toggle="dropdown" id="newScan" disabled>
<span class="caret"></span>
</button>
<ul class="dropdown-menu" role="menu">
<li><a href="javascript:;" onclick="newScan();">اسکن تازه</a></li>
</ul>
</div>
</div>
</div>
</div>
<div class="betaVersion">
Expand Down

0 comments on commit 588200b

Please sign in to comment.