diff --git a/static/app.js b/static/app.js
index d9c2934..8c50363 100644
--- a/static/app.js
+++ b/static/app.js
@@ -250,18 +250,15 @@ function openModal(concert) {
const btnDl = $('btn-download');
const alreadyDone = state.downloadedUrls.has(concert.url);
- btnDl.textContent = alreadyDone ? '✓ Déjà téléchargé' : 'Télécharger';
- btnDl.prepend((() => {
- const s = document.createElementNS('http://www.w3.org/2000/svg','svg');
- s.setAttribute('viewBox','0 0 20 20'); s.setAttribute('fill','none');
- s.setAttribute('width','16'); s.setAttribute('height','16');
- if (!alreadyDone) {
- s.innerHTML = `
- `;
- }
- return s;
- })());
- btnDl.disabled = alreadyDone;
+ btnDl.textContent = alreadyDone ? 'Re-télécharger' : 'Télécharger';
+ btnDl.classList.toggle('btn-redownload', alreadyDone);
+ const dlIcon = document.createElementNS('http://www.w3.org/2000/svg','svg');
+ dlIcon.setAttribute('viewBox','0 0 20 20'); dlIcon.setAttribute('fill','none');
+ dlIcon.setAttribute('width','16'); dlIcon.setAttribute('height','16');
+ dlIcon.innerHTML = `
+ `;
+ btnDl.prepend(dlIcon);
+ btnDl.disabled = false;
$('dl-progress-wrap').hidden = true;
$('dl-progress-fill').style.width = '0%';
@@ -342,7 +339,10 @@ function trackDownload(id, title, url) {
$('dl-progress-label').textContent = `${Math.round(pct)}%`;
if (s.state === 'done') {
$('dl-progress-label').textContent = '✓ Terminé';
- $('btn-download').textContent = '✓ Téléchargé';
+ const b = $('btn-download');
+ b.textContent = 'Re-télécharger';
+ b.classList.add('btn-redownload');
+ b.disabled = false;
}
}
diff --git a/static/style.css b/static/style.css
index 770860d..fd409f4 100644
--- a/static/style.css
+++ b/static/style.css
@@ -629,6 +629,8 @@ body {
.btn-download:hover { opacity: 0.88; transform: translateY(-1px); }
.btn-download:active { transform: none; }
.btn-download:disabled { opacity: 0.5; cursor: default; transform: none; }
+.btn-download.btn-redownload { background: transparent; color: var(--text-muted); border: 1px solid var(--border); }
+.btn-download.btn-redownload:hover { color: var(--text); border-color: var(--text-muted); opacity: 1; }
.btn-watch {
color: var(--text-dim);