feat: differentiate dir listing color (#18)

pull/3756/head
Laurynas Gadliauskas 2021-07-27 10:59:44 +03:00 committed by GitHub
parent 8688af97b7
commit 04e3be48a4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 16 additions and 0 deletions

View File

@ -12,6 +12,7 @@
:aria-label="name"
:aria-selected="isSelected"
ref="item"
:class="listingClass"
>
<div>
<img
@ -101,6 +102,13 @@ export default {
if (this.type === "video") return "movie";
return "insert_drive_file";
},
listingClass() {
if (this.isDir) return "folder";
if (this.type === "image") return "image";
if (this.type === "audio") return "audio";
if (this.type === "video") return "video";
return "file";
},
isDraggable() {
return this.readOnly == undefined && this.user.perm.rename;
},

View File

@ -53,6 +53,14 @@
vertical-align: bottom;
}
#listing .item.folder i {
color: var(--blue);
}
#listing .item[aria-selected=true].folder i {
color: #fff;
}
#listing .item img {
width: 4em;
height: 4em;