修复无法显示mp4以外的文件的BUG
This commit is contained in:
@@ -109,6 +109,10 @@ header p {
|
|||||||
align-items: flex-start;
|
align-items: flex-start;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.dashboard > * {
|
||||||
|
min-width: 0;
|
||||||
|
}
|
||||||
|
|
||||||
.glass-panel {
|
.glass-panel {
|
||||||
background: var(--panel-bg);
|
background: var(--panel-bg);
|
||||||
backdrop-filter: blur(16px);
|
backdrop-filter: blur(16px);
|
||||||
@@ -155,10 +159,13 @@ header p {
|
|||||||
gap: 0.5rem;
|
gap: 0.5rem;
|
||||||
max-height: 500px;
|
max-height: 500px;
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
|
overflow-x: auto;
|
||||||
|
min-width: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.video-list::-webkit-scrollbar {
|
.video-list::-webkit-scrollbar {
|
||||||
width: 6px;
|
width: 6px;
|
||||||
|
height: 6px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.video-list::-webkit-scrollbar-thumb {
|
.video-list::-webkit-scrollbar-thumb {
|
||||||
@@ -176,6 +183,7 @@ header p {
|
|||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 1rem;
|
gap: 1rem;
|
||||||
|
min-width: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.video-item:hover {
|
.video-item:hover {
|
||||||
@@ -210,8 +218,19 @@ header p {
|
|||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
font-size: 0.95rem;
|
font-size: 0.95rem;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
overflow: hidden;
|
overflow-x: auto;
|
||||||
text-overflow: ellipsis;
|
overflow-y: hidden;
|
||||||
|
text-overflow: clip;
|
||||||
|
padding-bottom: 0.2rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.video-title::-webkit-scrollbar {
|
||||||
|
height: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.video-title::-webkit-scrollbar-thumb {
|
||||||
|
background: var(--panel-border);
|
||||||
|
border-radius: 6px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.video-meta {
|
.video-meta {
|
||||||
@@ -237,6 +256,7 @@ header p {
|
|||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 1rem;
|
gap: 1rem;
|
||||||
|
min-width: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.folder-header:hover {
|
.folder-header:hover {
|
||||||
|
|||||||
@@ -40,8 +40,13 @@ app.get('/api/videos', async (req, res) => {
|
|||||||
|
|
||||||
const response = await s3Client.send(command);
|
const response = await s3Client.send(command);
|
||||||
|
|
||||||
// Filter for common video formats
|
// Filter for a broader set of common video formats
|
||||||
const videoExtensions = ['.mp4', '.avi', '.mov', '.mkv', '.webm', '.flv', '.wmv', '.m4v'];
|
const videoExtensions = [
|
||||||
|
'.3gp', '.3g2', '.asf', '.avi', '.divx', '.flv', '.m2ts', '.m2v',
|
||||||
|
'.m4v', '.mkv', '.mov', '.mp4', '.mpeg', '.mpg', '.mts', '.mxf',
|
||||||
|
'.ogm', '.ogv', '.qt', '.rm', '.rmvb', '.ts', '.vob', '.vro',
|
||||||
|
'.webm', '.wmv'
|
||||||
|
];
|
||||||
const videos = (response.Contents || [])
|
const videos = (response.Contents || [])
|
||||||
.map(item => item.Key)
|
.map(item => item.Key)
|
||||||
.filter(key => {
|
.filter(key => {
|
||||||
|
|||||||
Reference in New Issue
Block a user