don't show sites that don't allow embeddings
This commit is contained in:
parent
028f30cb77
commit
81f71bb354
2 changed files with 8 additions and 4 deletions
|
|
@ -13,6 +13,7 @@ const rng = mulberry32(Date.now());
|
|||
const loadedBundles = new Set();
|
||||
const container = document.getElementById("tab-container");
|
||||
const loadingEl = document.getElementById("loading");
|
||||
const showAll = new URLSearchParams(window.location.search).has("all");
|
||||
|
||||
// Detect browser and OS, set classes on body for tab styling
|
||||
function detectBrowser() {
|
||||
|
|
@ -203,7 +204,8 @@ async function loadMore() {
|
|||
const idx = pickBundle();
|
||||
if (idx === -1) break;
|
||||
try {
|
||||
const bundleEntries = await fetchBundle(idx);
|
||||
let bundleEntries = await fetchBundle(idx);
|
||||
if (!showAll) bundleEntries = bundleEntries.filter(e => e.iframe_ok);
|
||||
entries = entries.concat(bundleEntries);
|
||||
} catch (e) {
|
||||
console.error("Failed to load bundle:", e);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue