Remove pixfuture ads because they don't pay well
This commit is contained in:
@@ -26,7 +26,8 @@ onMount(() => {
|
||||
}
|
||||
}
|
||||
|
||||
switch (Math.floor(Math.random() * 5)) {
|
||||
let now = new Date().getTime()
|
||||
switch (now % 4) {
|
||||
case 0:
|
||||
set_ad_type("brave")
|
||||
break
|
||||
@@ -37,9 +38,6 @@ onMount(() => {
|
||||
set_ad_type("ads.plus")
|
||||
break
|
||||
case 3:
|
||||
set_ad_type("pixfuture")
|
||||
break
|
||||
case 4:
|
||||
set_ad_type("adaround")
|
||||
break
|
||||
}
|
||||
|
@@ -46,17 +46,14 @@ onMount(async () => {
|
||||
return
|
||||
}
|
||||
|
||||
switch (Math.floor(Math.random() * 4)) {
|
||||
switch (now % 3) {
|
||||
case 0:
|
||||
set_ad_type("aads2")
|
||||
break
|
||||
case 1:
|
||||
set_ad_type("pixfuture")
|
||||
break
|
||||
case 2:
|
||||
set_ad_type("ads.plus")
|
||||
break
|
||||
case 3:
|
||||
case 2:
|
||||
set_ad_type("adaround")
|
||||
break
|
||||
}
|
||||
|
@@ -154,7 +154,7 @@ const reload = async () => {
|
||||
loading = false
|
||||
}
|
||||
|
||||
const open_list = async l => {
|
||||
const open_list = l => {
|
||||
l.download_href = window.api_endpoint+"/list/"+l.id+"/zip"
|
||||
l.info_href = window.api_endpoint+"/list/"+l.id
|
||||
l.files.forEach(f => {
|
||||
@@ -172,10 +172,9 @@ const open_list = async l => {
|
||||
let hashID = parseInt(matches ? matches[1] : null)
|
||||
if (Number.isInteger(hashID)) {
|
||||
// The URL contains an item number. Navigate to that item
|
||||
view = "file"
|
||||
open_file_index(parseInt(hashID))
|
||||
} else {
|
||||
view = "gallery"
|
||||
open_file_index(hashID)
|
||||
} else if (view !== "gallery") {
|
||||
toggle_gallery()
|
||||
}
|
||||
}
|
||||
const open_file_index = async index => {
|
||||
@@ -188,12 +187,13 @@ const open_file_index = async index => {
|
||||
|
||||
file_set_href(list.files[index])
|
||||
file = list.files[index]
|
||||
view = "file"
|
||||
|
||||
if (view !== "file") {
|
||||
view = "file"
|
||||
await tick() // Wait for the ListNavigator to render
|
||||
}
|
||||
|
||||
if (is_list) {
|
||||
// Wait for the ListNavigator to render
|
||||
await tick()
|
||||
|
||||
// Update the URL
|
||||
location.replace("#item=" + index)
|
||||
list_navigator.set_item(index)
|
||||
|
@@ -82,7 +82,7 @@ const select_item_event = idx => {
|
||||
<div class="list_item file_button"
|
||||
class:file_button_selected={file.selected}
|
||||
on:click={() => { select_item_event(index) }}>
|
||||
<img src={file.icon_href+"?width=48&height=48"} alt={file.name} class="list_item_thumbnail" />
|
||||
<img src={file.icon_href+"?width=48&height=48"} alt={file.name} class="list_item_thumbnail" loading="lazy"/>
|
||||
{file.name}
|
||||
</div>
|
||||
{/each}
|
||||
|
Reference in New Issue
Block a user