Add star subscription indicators to sharing settings
This commit is contained in:
@@ -30,7 +30,10 @@ let submit = async e => {
|
||||
|
||||
if (single_or_all === "all") {
|
||||
list.files.forEach(file => {
|
||||
files.push(file.id)
|
||||
// Only report files which have not been blocked yet
|
||||
if (file.abuse_type !== "") {
|
||||
files.push(file.id)
|
||||
}
|
||||
})
|
||||
} else {
|
||||
files.push(file.id)
|
||||
|
@@ -95,7 +95,11 @@ const fullscreen = () => {
|
||||
{#if !video_reload}
|
||||
<div class="container">
|
||||
|
||||
{#if file.mime_type === "video/x-matroska" || file.mime_type === "video/quicktime"}
|
||||
{#if
|
||||
file.mime_type === "video/x-matroska" ||
|
||||
file.mime_type === "video/quicktime" ||
|
||||
file.mime_type === "video/x-ms-asf"
|
||||
}
|
||||
<div class="compatibility_warning">
|
||||
This video file type is not compatible with every web
|
||||
browser. If the video fails to play you can try downloading
|
||||
|
8
svelte/src/icons/Persistence.svelte
Normal file
8
svelte/src/icons/Persistence.svelte
Normal file
@@ -0,0 +1,8 @@
|
||||
<i class="icon star" title="These options require a Persistence (€8) subscription to use">star</i>
|
||||
|
||||
<style>
|
||||
.star {
|
||||
font-size: 1em;
|
||||
color: #BF00FF;
|
||||
}
|
||||
</style>
|
8
svelte/src/icons/Pro.svelte
Normal file
8
svelte/src/icons/Pro.svelte
Normal file
@@ -0,0 +1,8 @@
|
||||
<i class="icon star" title="These options require a Pro (€4) subscription to use">star</i>
|
||||
|
||||
<style>
|
||||
.star {
|
||||
font-size: 1em;
|
||||
color: #FFCC33;
|
||||
}
|
||||
</style>
|
@@ -1,5 +1,6 @@
|
||||
<script>
|
||||
import { onMount } from "svelte";
|
||||
import Pro from "../icons/Pro.svelte";
|
||||
import { formatDataVolume } from "../util/Formatting.svelte";
|
||||
import LoadingIndicator from "../util/LoadingIndicator.svelte";
|
||||
import ProgressBar from "../util/ProgressBar.svelte";
|
||||
@@ -80,7 +81,7 @@ onMount(() => {
|
||||
<LoadingIndicator loading={loading}/>
|
||||
|
||||
<section>
|
||||
<h2>Bandwidth sharing</h2>
|
||||
<h2><Pro/>Bandwidth sharing (hotlinking)</h2>
|
||||
<SuccessMessage bind:this={success_message}></SuccessMessage>
|
||||
|
||||
<button on:click={toggle_hotlinking}>
|
||||
@@ -100,7 +101,7 @@ onMount(() => {
|
||||
page.
|
||||
</p>
|
||||
|
||||
<h2>Bill shock limit</h2>
|
||||
<h2><Pro/>Bill shock limit</h2>
|
||||
<p>
|
||||
Billshock limit in gigabytes per month (1 TB = 1000 GB). Set to 0 to disable.
|
||||
</p>
|
||||
@@ -125,18 +126,7 @@ onMount(() => {
|
||||
Set to 0 to disable the limit.
|
||||
</p>
|
||||
|
||||
<h2>Skip download page</h2>
|
||||
<p>
|
||||
This setting only applies to your account, others will still see the
|
||||
download page when visiting your files. When this is enabled you will be
|
||||
redirected to the file download API when clicking a pixeldrain link.
|
||||
This means that images, videos and PDF files will be opened directly in
|
||||
your browser, and other files are immediately downloaded to your device.
|
||||
This only works for single file links, not albums.
|
||||
</p>
|
||||
<p>
|
||||
You will need a Pro subscription to use this feature.
|
||||
</p>
|
||||
<h2><Pro/>Skip download page</h2>
|
||||
<button on:click={toggle_skip_viewer}>
|
||||
{#if skip_viewer}
|
||||
<i class="icon green">check</i> ON (click to turn off)
|
||||
@@ -144,6 +134,15 @@ onMount(() => {
|
||||
<i class="icon red">close</i> OFF (click to turn on)
|
||||
{/if}
|
||||
</button>
|
||||
<p>
|
||||
This setting only applies to your account, others will still see the
|
||||
download page when visiting your files. When this is enabled you will be
|
||||
redirected to the file download API when clicking a pixeldrain link.
|
||||
This means that images, videos and PDF files will be opened directly in
|
||||
your browser, and other files are immediately downloaded to your device.
|
||||
This only works for single file links, not albums. You will need a Pro
|
||||
subscription to use this feature.
|
||||
</p>
|
||||
</section>
|
||||
|
||||
<style>
|
||||
|
@@ -1,5 +1,6 @@
|
||||
<script>
|
||||
import { onMount } from "svelte";
|
||||
import Persistence from "../icons/Persistence.svelte";
|
||||
import LoadingIndicator from "../util/LoadingIndicator.svelte";
|
||||
import SuccessMessage from "../util/SuccessMessage.svelte";
|
||||
|
||||
@@ -42,7 +43,7 @@ onMount(() => {
|
||||
<LoadingIndicator loading={loading}/>
|
||||
|
||||
<section>
|
||||
<h2>Embedding controls</h2>
|
||||
<h2><Persistence/>Embedding controls</h2>
|
||||
<SuccessMessage bind:this={success_message}></SuccessMessage>
|
||||
{#if !window.user.subscription.file_viewer_branding}
|
||||
<div class="highlight_yellow">
|
||||
|
@@ -5,6 +5,7 @@ import LoadingIndicator from "../util/LoadingIndicator.svelte";
|
||||
import SuccessMessage from "../util/SuccessMessage.svelte";
|
||||
import ThemePicker from "../util/ThemePicker.svelte";
|
||||
import { onMount } from "svelte";
|
||||
import Persistence from "../icons/Persistence.svelte";
|
||||
|
||||
let loading = false
|
||||
let success_message
|
||||
@@ -92,7 +93,7 @@ onMount(() => {
|
||||
<LoadingIndicator loading={loading}/>
|
||||
|
||||
<section>
|
||||
<h2>File viewer branding</h2>
|
||||
<h2><Persistence/>File viewer branding</h2>
|
||||
{#if !window.user.subscription.file_viewer_branding}
|
||||
<div class="highlight_yellow">
|
||||
Sharing settings are not available for your account. Subscribe to
|
||||
|
Reference in New Issue
Block a user