Added the following ENVIRONMENT VARIABLES > send.ftl - if not set it will use translate().

CUSTOM_INTRO_TITLE > introTitle
CUSTOM_INTRO_DESCRIPTION: > introDescription
CUSTOM_DOWNLOAD_DESCRIPTION: downloadDescription
CUSTOM_TRY_SEND_DESCRIPTION: trySendDescription
CUSTOM_SEND_YOUR_FILES_LINK: sendYourFilesLink

CUSTOM_INTRO_TITLE: "Secure & Simple"
CUSTOM_INTRO_DESCRIPTION: "Share files with end-to-end encryption and a link that expires."
CUSTOM_DOWNLOAD_DESCRIPTION: "Shared with end-to-end encryption and a link that expires."
CUSTOM_TRY_SEND_DESCRIPTION: "Secure, Simple file sharing"
CUSTOM_SEND_YOUR_FILES_LINK: "Upload Files"
This commit is contained in:
Dylan Derr 2025-02-08 12:37:18 -06:00
parent 5124572dba
commit 2f491fac86
8 changed files with 83 additions and 15 deletions

View file

@ -2,7 +2,14 @@ const html = require('choo/html');
const assets = require('../../common/assets');
module.exports = function(state) {
const btnText = state.user.loggedIn ? 'okButton' : 'sendYourFilesLink';
const btnText = state.WEB_UI.CUSTOM_SEND_YOUR_FILES_LINK
? state.WEB_UI.CUSTOM_SEND_YOUR_FILES_LINK
: state.user.loggedIn
? 'okButton'
: 'sendYourFilesLink';
const trySendDescription =
state.WEB_UI.CUSTOM_TRY_SEND_DESCRIPTION ||
state.translate('trySendDescription');
return html`
<div
id="download-complete"
@ -20,11 +27,13 @@ module.exports = function(state) {
? 'hidden'
: ''}"
>
${state.translate('trySendDescription')}
${trySendDescription}
</p>
<p class="my-5">
<a href="/" class="btn rounded-lg flex items-center mt-4" role="button"
>${state.translate(btnText)}</a
>${state.WEB_UI.CUSTOM_SEND_YOUR_FILES_LINK
? btnText
: state.translate(btnText)}</a
>
</p>
</div>