More Alignment Fixes

This commit is contained in:
Leo Herzog
2020-11-09 17:27:51 -05:00
parent a7ac84adf0
commit 9cf496cd51
4 changed files with 34 additions and 16 deletions

View File

@@ -33792,8 +33792,6 @@ function display() {
console.log(parsed);
resetProperties();
hash.value = parsed.infoHash;
name.value = parsed.name ? parsed.name : "";
if (parsed.created) {
@@ -33866,10 +33864,11 @@ function display() {
downloadTorrent.addEventListener('click', saveTorrent);
downloadTorrent.disabled = false;
} else {
getFiles.style.display = "block";
if (client.torrents.length > 0) {
getFiles.style.display = "none";
files.innerHTML = '<input type="text" placeholder="Attempting fetching files from Webtorrent..." disabled>';
} else {
getFiles.style.display = "block";
files.innerHTML = '<input type="text" placeholder="Not included in the URL/File provided" disabled>';
}
downloadTorrent.removeEventListener('click', saveTorrent);
@@ -33976,7 +33975,7 @@ function resetProperties() {
}
async function addCurrentTrackers() {
addTrackers.disabled = true;
addTrackers.className = 'disabled';
addTrackers.innerHTML = 'Adding...';
try {
let response = await fetch("https://newtrackon.com/api/100"); // get trackers with 100% uptime
@@ -33991,7 +33990,7 @@ async function addCurrentTrackers() {
console.error(e); // TODO: Alert user to error
}
addTrackers.innerHTML = 'Add Known Working Trackers';
addTrackers.disabled = false;
addTrackers.className = '';
display();
}

2
bundle.min.js vendored

File diff suppressed because one or more lines are too long

View File

@@ -129,8 +129,6 @@ function display() {
console.log(parsed);
resetProperties();
hash.value = parsed.infoHash;
name.value = parsed.name ? parsed.name : "";
if (parsed.created) {
@@ -203,10 +201,11 @@ function display() {
downloadTorrent.addEventListener('click', saveTorrent);
downloadTorrent.disabled = false;
} else {
getFiles.style.display = "block";
if (client.torrents.length > 0) {
getFiles.style.display = "none";
files.innerHTML = '<input type="text" placeholder="Attempting fetching files from Webtorrent..." disabled>';
} else {
getFiles.style.display = "block";
files.innerHTML = '<input type="text" placeholder="Not included in the URL/File provided" disabled>';
}
downloadTorrent.removeEventListener('click', saveTorrent);
@@ -313,7 +312,7 @@ function resetProperties() {
}
async function addCurrentTrackers() {
addTrackers.disabled = true;
addTrackers.className = 'disabled';
addTrackers.innerHTML = 'Adding...';
try {
let response = await fetch("https://newtrackon.com/api/100"); // get trackers with 100% uptime
@@ -328,7 +327,7 @@ async function addCurrentTrackers() {
console.error(e); // TODO: Alert user to error
}
addTrackers.innerHTML = 'Add Known Working Trackers';
addTrackers.disabled = false;
addTrackers.className = '';
display();
}

View File

@@ -67,12 +67,16 @@ button:disabled {
a {
color: var(--grey);
font-size: 85%;
text-decoration: underline;
text-transform: uppercase;
cursor: pointer;
}
.disabled {
text-decoration: none;
cursor: not-allowed;
}
header {
width: 100%;
height: 80px;
@@ -177,6 +181,11 @@ label[for="torrent"] {
flex-direction: column;
}
.labels > a {
font-size: 80%;
margin-top: 6px;
}
.content, #files {
width: 460px;
}
@@ -205,7 +214,7 @@ input {
}
.remove {
/* position: absolute; */
margin-left: 6px;
}
@media (max-width: 1080px) {
@@ -243,7 +252,7 @@ input {
}
#properties {
margin: 0 1.5vw;
margin: 0;
padding: 0 1.5vw;
width: 95vw;
}
@@ -257,8 +266,8 @@ input {
margin: 12px 0;
}
input, button, #addTracker, #addWebseed {
width: 94vw;
input, button {
width: 80vw;
text-align: center;
}
@@ -269,12 +278,23 @@ input {
.labels, .content, #files {
width: auto;
display: flex;
flex-direction: column;
align-items: center;
}
#announce, #urlList {
text-align: center;
}
#announce > * > *, #urlList > * > *, #addTracker, #addWebseed {
width: 80vw;
}
#addTracker, #addWebseed {
margin-right: 22px !important;
}
}
@media (max-width: 460px) {