Tune the speed limit page a bit
This commit is contained in:
BIN
res/static/img/slow_down.xcf
Normal file
BIN
res/static/img/slow_down.xcf
Normal file
Binary file not shown.
@@ -27,7 +27,7 @@ export const set_file = async file => {
|
|||||||
file.availability === "ip_download_limited_captcha_required"
|
file.availability === "ip_download_limited_captcha_required"
|
||||||
) {
|
) {
|
||||||
viewer_type = "rate_limit"
|
viewer_type = "rate_limit"
|
||||||
} else if (file.download_speed_limit > 0) {
|
} else if (file.download_speed_limit > 0 && file.download_speed_limit <= 1<<20) {
|
||||||
viewer_type = "speed_limit"
|
viewer_type = "speed_limit"
|
||||||
} else {
|
} else {
|
||||||
viewer_type = file_type(file)
|
viewer_type = file_type(file)
|
||||||
|
@@ -14,7 +14,7 @@ let file = {
|
|||||||
let limits = {
|
let limits = {
|
||||||
download_limit: 1000,
|
download_limit: 1000,
|
||||||
download_limit_used: 0,
|
download_limit_used: 0,
|
||||||
transfer_limit: 50e9,
|
transfer_limit: 10e9,
|
||||||
transfer_limit_used: 0,
|
transfer_limit_used: 0,
|
||||||
}
|
}
|
||||||
onMount(async () => {
|
onMount(async () => {
|
||||||
@@ -34,11 +34,11 @@ onMount(async () => {
|
|||||||
<TextBlock width="800px">
|
<TextBlock width="800px">
|
||||||
<img src="/res/img/slow_down.webp" class="header_image" alt="Yea, I'm gonna need you to slow down a bit"/>
|
<img src="/res/img/slow_down.webp" class="header_image" alt="Yea, I'm gonna need you to slow down a bit"/>
|
||||||
<p>
|
<p>
|
||||||
Yea, so pixeldrain's free tier is supported by advertisements. And
|
Pixeldrain's free tier is supported by advertisements. There's only so
|
||||||
there's only so much that you can do with the budget those ads provide
|
much that you can do with the budget those ads provide (spoiler: it's
|
||||||
(spoiler: it's not a lot). {formatDataVolume(limits.transfer_limit, 3)}
|
not a lot). {formatDataVolume(limits.transfer_limit, 3)} per day is
|
||||||
every 48 hours is about the most I can give away for free, according to
|
about the most I can give away for free, and according to our records
|
||||||
our records you have already downloaded
|
you have already downloaded
|
||||||
{formatDataVolume(limits.transfer_limit_used, 3)}.
|
{formatDataVolume(limits.transfer_limit_used, 3)}.
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
@@ -48,10 +48,11 @@ onMount(async () => {
|
|||||||
a few options:
|
a few options:
|
||||||
</p>
|
</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Come back in 48 hours when your free transfer limit resets</li>
|
<li>Come back tomorrow when your free transfer limit resets</li>
|
||||||
<li>
|
<li>
|
||||||
Download the file at a rate of {limits.speed_limit/(1<<20)} MiB/s.
|
Download the file at a rate of {file.download_speed_limit/(1<<20)}
|
||||||
This will take at least {formatDuration((file.size/2097152)*1000)}
|
MiB/s. This will take at least
|
||||||
|
{formatDuration((file.size/file.download_speed_limit)*1000)}
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="https://www.patreon.com/join/pixeldrain/checkout?rid=5291427&cadence=12" target="_blank" class="button button_highlight">
|
<a href="https://www.patreon.com/join/pixeldrain/checkout?rid=5291427&cadence=12" target="_blank" class="button button_highlight">
|
||||||
|
@@ -45,7 +45,7 @@ onMount(() => {
|
|||||||
Data transfer limit
|
Data transfer limit
|
||||||
</div>
|
</div>
|
||||||
<div class="feat_normal">
|
<div class="feat_normal">
|
||||||
10 GB data transfer per 48 hours. When this threshold is reached
|
10 GB data transfer per 24 hours. When this threshold is reached
|
||||||
your download speed will be limited
|
your download speed will be limited
|
||||||
</div>
|
</div>
|
||||||
<div class="feat_pro">
|
<div class="feat_pro">
|
||||||
|
Reference in New Issue
Block a user