Fix #29 Download all password albums
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
|
||||
<title><%- title || 'Gallery' %></title>
|
||||
<title><%- title %></title>
|
||||
<link rel="icon" href="/share/static/favicon.ico" type="image/x-icon">
|
||||
<link type="text/css" rel="stylesheet" href="/share/static/style.css"/>
|
||||
<link type="text/css" rel="stylesheet" href="/share/static/lg/lightgallery-bundle.min.css"/>
|
||||
@@ -12,9 +12,15 @@
|
||||
<% if (showTitle) { %>
|
||||
<h1><%- title || 'Gallery' %></h1>
|
||||
<% } %>
|
||||
<% if (showDownload) { %>
|
||||
<%
|
||||
if (showDownload) {
|
||||
// If there is a password required for the download, format it as a query string
|
||||
const passwordQuery = Object.entries(password).length ? '?' + (new URLSearchParams(password)).toString() : ''
|
||||
%>
|
||||
<div id="download-all">
|
||||
<a href="<%- path %>/download" title="Download all"><img src="/images/download-all.svg" height="24" width="24" alt="Download all"></a>
|
||||
<a href="<%- path %>/download<%- passwordQuery %>" title="Download all"><img src="/images/download-all.svg"
|
||||
height="24"
|
||||
width="24" alt="Download all"></a>
|
||||
</div>
|
||||
<% } %>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user