mirror of
https://gitlab.com/timvisee/send.git
synced 2025-12-06 14:10:53 +03:00
Compare commits
7 Commits
c71100c82a
...
v3.4.25
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
56a0e830bd | ||
|
|
b3317df707 | ||
|
|
9931074905 | ||
|
|
0088a4ccc0 | ||
|
|
11aad6eac5 | ||
|
|
1fb2f45285 | ||
|
|
d0f21e8078 |
@@ -167,6 +167,10 @@ footer li a:hover {
|
|||||||
width: auto;
|
width: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.text-underline {
|
||||||
|
text-decoration: underline;
|
||||||
|
}
|
||||||
|
|
||||||
.main {
|
.main {
|
||||||
display: flex;
|
display: flex;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
|||||||
@@ -486,12 +486,12 @@ module.exports.empty = function(state, emit) {
|
|||||||
})}
|
})}
|
||||||
</button>
|
</button>
|
||||||
`;
|
`;
|
||||||
const warning = state.WEB_UI.UPLOAD_AREA_WARNING_HTML
|
const uploadNotice = state.WEB_UI.UPLOAD_AREA_NOTICE_HTML
|
||||||
? html`
|
? html`
|
||||||
<p
|
<p
|
||||||
class="w-full mt-8 p-2 border-default dark:border-grey-70 rounded-default text-orange-60 bg-yellow-40 text-center leading-normal"
|
class="w-full mt-8 p-2 border-default dark:border-grey-70 rounded-default text-orange-60 bg-yellow-40 text-center leading-normal"
|
||||||
>
|
>
|
||||||
${raw(state.WEB_UI.UPLOAD_AREA_WARNING_HTML)}
|
${raw(state.WEB_UI.UPLOAD_AREA_NOTICE_HTML)}
|
||||||
</p>
|
</p>
|
||||||
`
|
`
|
||||||
: '';
|
: '';
|
||||||
@@ -536,7 +536,7 @@ module.exports.empty = function(state, emit) {
|
|||||||
>
|
>
|
||||||
${state.translate('addFilesButton')}
|
${state.translate('addFilesButton')}
|
||||||
</label>
|
</label>
|
||||||
${upsell} ${warning}
|
${upsell} ${uploadNotice}
|
||||||
</send-upload-area>
|
</send-upload-area>
|
||||||
`;
|
`;
|
||||||
|
|
||||||
@@ -569,12 +569,12 @@ module.exports.preview = function(state, emit) {
|
|||||||
${archiveDetails(state.translate, archive)}
|
${archiveDetails(state.translate, archive)}
|
||||||
</div>
|
</div>
|
||||||
`;
|
`;
|
||||||
const warning = state.WEB_UI.DOWNLOAD_WARNING_HTML
|
const notice = state.WEB_UI.DOWNLOAD_NOTICE_HTML
|
||||||
? html`
|
? html`
|
||||||
<p
|
<p
|
||||||
class="w-full mt-4 p-2 border-default dark:border-grey-70 rounded-default text-orange-60 bg-yellow-40 text-center leading-normal"
|
class="w-full mt-4 p-2 border-default dark:border-grey-70 rounded-default text-orange-60 bg-yellow-40 text-center leading-normal"
|
||||||
>
|
>
|
||||||
${raw(state.WEB_UI.DOWNLOAD_WARNING_HTML)}
|
${raw(state.WEB_UI.DOWNLOAD_NOTICE_HTML)}
|
||||||
</p>
|
</p>
|
||||||
`
|
`
|
||||||
: '';
|
: '';
|
||||||
@@ -594,7 +594,7 @@ module.exports.preview = function(state, emit) {
|
|||||||
>
|
>
|
||||||
${state.translate('downloadButtonLabel')}
|
${state.translate('downloadButtonLabel')}
|
||||||
</button>
|
</button>
|
||||||
${warning}
|
${notice}
|
||||||
</send-archive>
|
</send-archive>
|
||||||
`;
|
`;
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
const html = require('choo/html');
|
const html = require('choo/html');
|
||||||
|
const raw = require('choo/html/raw');
|
||||||
const { list } = require('../utils');
|
const { list } = require('../utils');
|
||||||
const archiveTile = require('./archiveTile');
|
const archiveTile = require('./archiveTile');
|
||||||
const modal = require('./modal');
|
const modal = require('./modal');
|
||||||
@@ -16,7 +17,19 @@ module.exports = function(state, emit) {
|
|||||||
} else {
|
} else {
|
||||||
left = archiveTile.empty(state, emit);
|
left = archiveTile.empty(state, emit);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (archives.length > 0 && state.WEB_UI.UPLOADS_LIST_NOTICE_HTML) {
|
||||||
|
archives.push(html`
|
||||||
|
<p
|
||||||
|
class="w-full p-2 border-default dark:border-grey-70 rounded-default text-orange-60 bg-yellow-40 text-center leading-normal"
|
||||||
|
>
|
||||||
|
${raw(state.WEB_UI.UPLOADS_LIST_NOTICE_HTML)}
|
||||||
|
</p>
|
||||||
|
`);
|
||||||
|
}
|
||||||
|
|
||||||
archives.reverse();
|
archives.reverse();
|
||||||
|
|
||||||
const right =
|
const right =
|
||||||
archives.length === 0
|
archives.length === 0
|
||||||
? intro(state)
|
? intro(state)
|
||||||
|
|||||||
@@ -1,10 +1,22 @@
|
|||||||
const html = require('choo/html');
|
const html = require('choo/html');
|
||||||
|
const raw = require('choo/html/raw');
|
||||||
|
|
||||||
module.exports = function intro(state) {
|
module.exports = function intro(state) {
|
||||||
|
const notice = state.WEB_UI.MAIN_NOTICE_HTML
|
||||||
|
? html`
|
||||||
|
<p
|
||||||
|
class="w-full mt-2 p-2 border-default dark:border-grey-70 rounded-default text-orange-60 bg-yellow-40 text-center leading-normal"
|
||||||
|
>
|
||||||
|
${raw(state.WEB_UI.MAIN_NOTICE_HTML)}
|
||||||
|
</p>
|
||||||
|
`
|
||||||
|
: '';
|
||||||
|
|
||||||
return html`
|
return html`
|
||||||
<send-intro
|
<send-intro
|
||||||
class="flex flex-col items-center justify-center bg-white px-6 md:py-0 py-6 mb-0 h-full w-full dark:bg-grey-90"
|
class="flex flex-col items-center justify-center bg-white px-6 md:py-0 py-6 mb-0 h-full w-full dark:bg-grey-90"
|
||||||
>
|
>
|
||||||
|
${notice}
|
||||||
<div class="mt-12 flex flex-col h-full">
|
<div class="mt-12 flex flex-col h-full">
|
||||||
<h1 class="text-3xl font-bold md:pb-2">
|
<h1 class="text-3xl font-bold md:pb-2">
|
||||||
${state.translate('introTitle')}
|
${state.translate('introTitle')}
|
||||||
|
|||||||
4
package-lock.json
generated
4
package-lock.json
generated
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "send",
|
"name": "send",
|
||||||
"version": "3.4.24",
|
"version": "3.4.25",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "send",
|
"name": "send",
|
||||||
"version": "3.4.24",
|
"version": "3.4.25",
|
||||||
"license": "MPL-2.0",
|
"license": "MPL-2.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@dannycoates/express-ws": "^5.0.3",
|
"@dannycoates/express-ws": "^5.0.3",
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "send",
|
"name": "send",
|
||||||
"description": "File Sharing Experiment",
|
"description": "File Sharing Experiment",
|
||||||
"version": "3.4.24",
|
"version": "3.4.25",
|
||||||
"author": "Mozilla (https://mozilla.org)",
|
"author": "Mozilla (https://mozilla.org)",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"Tim Visee <3a4fb3964f@sinenomine.email> (https://timvisee.com)"
|
"Tim Visee <3a4fb3964f@sinenomine.email> (https://timvisee.com)"
|
||||||
|
|||||||
@@ -15,8 +15,10 @@ module.exports = {
|
|||||||
FOOTER_SOURCE_URL: config.footer_source_url,
|
FOOTER_SOURCE_URL: config.footer_source_url,
|
||||||
CUSTOM_FOOTER_TEXT: config.custom_footer_text,
|
CUSTOM_FOOTER_TEXT: config.custom_footer_text,
|
||||||
CUSTOM_FOOTER_URL: config.custom_footer_url,
|
CUSTOM_FOOTER_URL: config.custom_footer_url,
|
||||||
UPLOAD_AREA_WARNING_HTML: config.upload_area_warning_html,
|
MAIN_NOTICE_HTML: config.main_notice_html,
|
||||||
DOWNLOAD_WARNING_HTML: config.download_warning_html,
|
UPLOAD_AREA_NOTICE_HTML: config.upload_area_notice_html,
|
||||||
|
UPLOADS_LIST_NOTICE_HTML: config.uploads_list_notice_html,
|
||||||
|
DOWNLOAD_NOTICE_HTML: config.download_notice_html,
|
||||||
COLORS: {
|
COLORS: {
|
||||||
PRIMARY: config.ui_color_primary,
|
PRIMARY: config.ui_color_primary,
|
||||||
ACCENT: config.ui_color_accent
|
ACCENT: config.ui_color_accent
|
||||||
|
|||||||
@@ -264,15 +264,25 @@ const conf = convict({
|
|||||||
default: '',
|
default: '',
|
||||||
env: 'CUSTOM_FOOTER_URL'
|
env: 'CUSTOM_FOOTER_URL'
|
||||||
},
|
},
|
||||||
upload_area_warning_html: {
|
main_notice_html: {
|
||||||
format: String,
|
format: String,
|
||||||
default: '',
|
default: '',
|
||||||
env: 'SEND_UPLOAD_AREA_WARNING_HTML'
|
env: 'SEND_MAIN_NOTICE_HTML'
|
||||||
},
|
},
|
||||||
download_warning_html: {
|
upload_area_notice_html: {
|
||||||
format: String,
|
format: String,
|
||||||
default: '',
|
default: '',
|
||||||
env: 'SEND_DOWNLOAD_WARNING_HTML'
|
env: 'SEND_UPLOAD_AREA_NOTICE_HTML'
|
||||||
|
},
|
||||||
|
uploads_list_notice_html: {
|
||||||
|
format: String,
|
||||||
|
default: '',
|
||||||
|
env: 'SEND_UPLOADS_LIST_NOTICE_HTML'
|
||||||
|
},
|
||||||
|
download_notice_html: {
|
||||||
|
format: String,
|
||||||
|
default: '',
|
||||||
|
env: 'SEND_DOWNLOAD_NOTICE_HTML'
|
||||||
},
|
},
|
||||||
ui_color_primary: {
|
ui_color_primary: {
|
||||||
format: String,
|
format: String,
|
||||||
|
|||||||
Reference in New Issue
Block a user