Skip to content

Commit

Permalink
Update mediaSlider_v2.js
Browse files Browse the repository at this point in the history
  • Loading branch information
ledangtrung committed Dec 2, 2024
1 parent bbedb99 commit 3371fd5
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions js/mediaSlider_v2.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,9 @@ class MediaSlider {
}

createMediaElement(url) {
if (!url) {
return `<div style="display: flex; justify-content: center; align-items: center; height: 40vh; font-weight: bold; color: #666;">📄 No documents 📋</div>`;
}
const mediaType = this.detectMediaType(url);
switch(mediaType) {
case 'image':
Expand Down

0 comments on commit 3371fd5

Please sign in to comment.