From 4c0c2ad7595044babf36decb195825e1cb6b80a9 Mon Sep 17 00:00:00 2001
From: fynks <75840152+fynks@users.noreply.github.com>
Date: Thu, 16 Jan 2025 11:55:04 +0500
Subject: [PATCH] updated
---
docs/app-min.js | 1 +
docs/index.html | 12 +-
docs/styles.css | 421 +-----------------------------------------------
3 files changed, 9 insertions(+), 425 deletions(-)
create mode 100644 docs/app-min.js
diff --git a/docs/app-min.js b/docs/app-min.js
new file mode 100644
index 0000000..249dad7
--- /dev/null
+++ b/docs/app-min.js
@@ -0,0 +1 @@
+class TableManager{constructor(t,e,n){this.container=document.getElementById(t),this.searchInput=document.getElementById(e),this.clearIcon=document.getElementById(n),this.setupSearchFunctionality()}generateTable(t){if(!t||0===Object.keys(t).length)return void(this.container.innerHTML="
No data available.
");const e=Object.keys(t[Object.keys(t)[0]]),n=`\n \n \n \n Service Name \n ${e.map((t=>`${t} `)).join("")}\n \n \n \n ${Object.entries(t).map((([t,n])=>`\n \n ${t} \n ${e.map((t=>`\n \n ${"yes"===n[t]?"✅":"❌"}\n \n `)).join("")}\n \n `)).join("")}\n \n
\n `;this.container.innerHTML=n}setupSearchFunctionality(){this.searchInput?.addEventListener("input",(()=>{const t=this.searchInput.value.toLowerCase(),e=this.container.querySelectorAll("table tbody tr");this.clearIcon.style.display=t?"block":"none",e.forEach((e=>{const n=e.querySelector("td:first-child")?.textContent.toLowerCase();e.style.display=n?.includes(t)?"":"none"}))})),this.clearIcon?.addEventListener("click",(()=>{this.searchInput.value="",this.clearIcon.style.display="none",this.searchInput.dispatchEvent(new Event("input"))}))}}class ComparisonManager{constructor(t,e,n,a){this.container=document.getElementById(t),this.select1=document.getElementById(e),this.select2=document.getElementById(n),this.data=a,this.setupEventListeners(),this.populateDropdowns()}populateDropdowns(){const t=Object.keys(this.data[Object.keys(this.data)[0]]);[this.select1,this.select2].forEach((e=>{t.forEach((t=>{const n=document.createElement("option");n.value=t,n.textContent=t,e.appendChild(n)}))}))}generateCompareTable(){const t=this.select1.value,e=this.select2.value;if(!t||!e)return;const n=`\n X \n \n \n \n Service Name \n ${t} \n ${e} \n \n \n \n ${Object.entries(this.data).map((([n,a])=>`\n \n ${n} \n ${"yes"===a[t]?"✅":"❌"} \n ${"yes"===a[e]?"✅":"❌"} \n \n `)).join("")}\n \n
\n `;this.container.innerHTML=n,this.container.style.display="block",this.setupCloseButton()}setupEventListeners(){[this.select1,this.select2].forEach((t=>{t?.addEventListener("change",(()=>this.generateCompareTable()))}))}setupCloseButton(){document.getElementById("close-compare")?.addEventListener("click",(()=>{this.container.style.display="none"}))}}class PricingManager{constructor(t){this.container=document.getElementById(t)}generatePricingTable(t){if(!t?.plans?.length)return void(this.container.innerHTML="Error: Invalid pricing data structure.
");const e=Object.keys(t.plans[0]).filter((t=>"name"!==t)),n=`\n \n \n \n Plans \n ${e.map((t=>`${t} `)).join("")}\n \n \n \n ${t.plans.map((t=>`\n \n ${t.name} \n ${e.map((e=>`${t[e]} `)).join("")}\n \n `)).join("")}\n \n
\n `;this.container.innerHTML=n}}document.addEventListener("DOMContentLoaded",(async()=>{const t=new TableManager("file-hosts-table-container","host-search-input","clear-host-search"),e=new TableManager("adult-hosts-table-container","adult-host-search-input","clear-adult-host-search"),n=new PricingManager("pricing");try{const[a,s,i]=await Promise.all([fetch("./json/file-hosts.json").then((t=>t.json())),fetch("./json/adult-hosts.json").then((t=>t.json())),fetch("./json/pricing.json").then((t=>t.json()))]);t.generateTable(a),e.generateTable(s),n.generatePricingTable(i),new ComparisonManager("compare-table-container","provider1","provider2",a)}catch(a){const s="Error loading data. Please try again later.
";t.container.innerHTML=s,e.container.innerHTML=s,n.container.innerHTML=s}}));
\ No newline at end of file
diff --git a/docs/index.html b/docs/index.html
index 2ad4ee9..bc3d2de 100644
--- a/docs/index.html
+++ b/docs/index.html
@@ -96,9 +96,10 @@
Debrid-Link
Mega-Debrid
- Pricing
+ Pricing
+
-
+
[ * ] = 7 Days free trail at Alldebrid requires a phone
verification.
@@ -167,15 +168,16 @@
Mega-Debrid
- Last updated: January 14,
- 2025
+
+
Last updated: January 14, 2025
+
-
+