Skip to content

Commit 0253329

Browse files
committed
🔧 Apply file input styles via JavaScript for reliability
- Ensure file input is absolutely positioned and covers upload area - Apply styles programmatically for better browser compatibility - Remove Clear All button from DOM if it exists (cleanup) - Set upload area overflow to hidden - Update cache-busting to v=6
1 parent b7567b6 commit 0253329

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

docs/assets/app.js

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,6 +180,26 @@ class App {
180180
console.error('Required elements not found');
181181
return;
182182
}
183+
184+
// Ensure file input is styled correctly
185+
this.fileInput.style.position = 'absolute';
186+
this.fileInput.style.top = '0';
187+
this.fileInput.style.left = '0';
188+
this.fileInput.style.width = '100%';
189+
this.fileInput.style.height = '100%';
190+
this.fileInput.style.opacity = '0';
191+
this.fileInput.style.cursor = 'pointer';
192+
this.fileInput.style.zIndex = '10';
193+
this.fileInput.style.fontSize = '0';
194+
195+
// Ensure upload area has overflow hidden
196+
this.uploadArea.style.overflow = 'hidden';
197+
198+
// Remove Clear All button if it exists (should not exist, but cleanup)
199+
const clearBtn = document.getElementById('clearBtn');
200+
if (clearBtn) {
201+
clearBtn.remove();
202+
}
183203
}
184204

185205
setupEventListeners() {

0 commit comments

Comments
 (0)