forked from upstream/filebrowser
582 lines
12 KiB
CSS
582 lines
12 KiB
CSS
#listingView {
|
|
--item-selected: white;
|
|
animation-duration: 0.25s;
|
|
transition: box-shadow 0.2s ease-in-out, transform 0.1s ease-in-out;
|
|
user-select: none;
|
|
min-height: 75vh;
|
|
padding-bottom: 2.5em; /* Space for status bar - this prevents items from going behind */
|
|
}
|
|
|
|
body.rtl #listingView {
|
|
margin-right: 16em;
|
|
}
|
|
|
|
#listingView h2 {
|
|
margin: 0 0 0 0.5em;
|
|
font-size: .9em;
|
|
color: rgba(0, 0, 0, 0.38);
|
|
font-weight: 500;
|
|
}
|
|
|
|
.listing-item div:last-of-type * {
|
|
text-overflow: ellipsis;
|
|
overflow: hidden;
|
|
}
|
|
|
|
#listingView>div {
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
justify-content: flex-start;
|
|
}
|
|
|
|
.listing-item {
|
|
display: flex;
|
|
flex-wrap: nowrap;
|
|
color: #6f6f6f;
|
|
transition: .1s ease background, .1s ease opacity;
|
|
align-items: center;
|
|
cursor: pointer;
|
|
user-select: none;
|
|
overflow: hidden;
|
|
width: var(--item-width);
|
|
height: var(--item-height);
|
|
border-radius: 1em;
|
|
background: var(--item-secondary);
|
|
color: var(--textPrimary);
|
|
border-color: var(--divider);
|
|
background: var(--surfacePrimary)
|
|
}
|
|
|
|
.listing-item div:last-of-type {
|
|
text-overflow: ellipsis;
|
|
white-space: nowrap;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.listing-item p {
|
|
margin: 0;
|
|
}
|
|
|
|
.listing-item .size,
|
|
.listing-item .modified,
|
|
.listing-item .duration {
|
|
font-size: 0.9em;
|
|
}
|
|
|
|
.listing-item i {
|
|
font-size: 4em;
|
|
vertical-align: bottom;
|
|
}
|
|
|
|
.listing-item img {
|
|
padding: 0;
|
|
height: 3.2em;
|
|
min-width: 3.2em;
|
|
max-width: 3.2em;
|
|
border-radius: 0.5em;
|
|
object-fit: cover;
|
|
vertical-align: bottom;
|
|
}
|
|
|
|
.message {
|
|
text-align: center;
|
|
font-size: 2em;
|
|
margin: 1em auto;
|
|
display: block !important;
|
|
width: 95%;
|
|
color: rgba(0, 0, 0, 0.3);
|
|
font-weight: 500;
|
|
}
|
|
|
|
.message i {
|
|
font-size: 2.5em;
|
|
margin-bottom: .2em;
|
|
display: block;
|
|
}
|
|
|
|
#listingView.gallery .listing-item,
|
|
#listingView.compact .listing-item,
|
|
#listingView.normal .listing-item,
|
|
#listingView.list .listing-item,
|
|
#listingView.icons .listing-item {
|
|
margin: .5em;
|
|
padding: 0.5em;
|
|
box-shadow: rgba(0, 0, 0, 0.06) 0px 1px 3px, rgba(0, 0, 0, 0.12) 0px 1px 2px;
|
|
}
|
|
|
|
#listingView.compact .listing-item:hover,
|
|
#listingView.list .listing-item:hover,
|
|
.search-entry:hover {
|
|
width: 98% !important;
|
|
margin-left: 1% !important;
|
|
padding-left: 0.5em !important;
|
|
}
|
|
|
|
#listingView.list .listing-item,
|
|
#listingView.compact .listing-item {
|
|
max-width: 100%;
|
|
border-radius: 0em;
|
|
}
|
|
|
|
.listing-item div:last-of-type {
|
|
width: 100%;
|
|
}
|
|
|
|
#listingView.gallery .listing-item {
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-content: center;
|
|
overflow: hidden;
|
|
justify-content: center;
|
|
margin: 0;
|
|
padding: 0;
|
|
position: relative;
|
|
width: 100%;
|
|
height: var(--item-height);
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
#listingView.icons .listing-item {
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-content: center;
|
|
overflow: hidden;
|
|
justify-content: flex-start;
|
|
padding: 0.5em;
|
|
margin: 0.25em;
|
|
position: relative;
|
|
width: 100%;
|
|
height: auto;
|
|
min-height: calc(var(--icons-view-icon-size, 60px) + 2em);
|
|
}
|
|
|
|
#listingView.gallery .listing-item .gallery-div {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
width: 100%;
|
|
height: 100%;
|
|
aspect-ratio: 1;
|
|
transition: all 0.25s ease-out;
|
|
}
|
|
|
|
#listingView.normal .listing-item,
|
|
#listingView.gallery .listing-item,
|
|
#listingView.icons .listing-item {
|
|
transition: width 0.25s ease-out, height 0.25s ease-out, box-shadow 0.2s ease-in-out, transform 0.1s ease-in-out;
|
|
}
|
|
|
|
#listingView.gallery .listing-item .text {
|
|
color: white;
|
|
text-shadow: 0 0 2px black;
|
|
pointer-events: none;
|
|
font-weight: 700;
|
|
position: absolute;
|
|
z-index: 1;
|
|
bottom: 0;
|
|
left: 0;
|
|
right: 0;
|
|
padding: 1em;
|
|
}
|
|
|
|
#listingView.gallery .listing-item .text .name {
|
|
text-align: center;
|
|
white-space: nowrap;
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
font-weight: 600;
|
|
}
|
|
|
|
#listingView.gallery .listing-item[data-type=image] div:last-of-type {
|
|
color: white;
|
|
}
|
|
|
|
#listingView.gallery .listing-item i {
|
|
margin: auto;
|
|
font-size: 8em;
|
|
background: none;
|
|
}
|
|
|
|
#listingView.gallery .listing-item span {
|
|
display: flex;
|
|
}
|
|
|
|
#listingView.list .listing-item img,
|
|
#listingView.compact .listing-item img {
|
|
min-width: unset;
|
|
}
|
|
|
|
#listingView.gallery .listing-item img {
|
|
width: 100%;
|
|
height: 100%;
|
|
max-width: 100%;
|
|
max-height: 100%;
|
|
aspect-ratio: 1;
|
|
object-fit: cover;
|
|
transition: all 0.25s ease-out;
|
|
}
|
|
#listingView.compact {
|
|
flex-direction: column;
|
|
width: 100%;
|
|
max-width: 100%;
|
|
margin: 0;
|
|
}
|
|
|
|
#listingView.compact .listing-item {
|
|
width: 100%;
|
|
margin: 0;
|
|
border: 1px solid rgba(0, 0, 0, 0.1);
|
|
padding: 0;
|
|
border-top: 0;
|
|
padding-left: .5em;
|
|
}
|
|
|
|
#listingView.compact h2 {
|
|
display: none;
|
|
}
|
|
|
|
#listingView.compact .listing-item div:first-of-type {
|
|
width: 3em;
|
|
}
|
|
|
|
#listingView.compact .listing-item div:first-of-type i {
|
|
font-size: var(--list-icon-font-size, 2em);
|
|
transition: font-size 0.25s ease-out;
|
|
}
|
|
|
|
#listingView.compact .listing-item div:first-of-type img {
|
|
width: var(--list-icon-image-size, 1.5em);
|
|
height: var(--list-icon-image-size, 1.5em);
|
|
border-radius: .25em;
|
|
transition: width 0.25s ease-out, height 0.25s ease-out;
|
|
}
|
|
|
|
#listingView.compact .listing-item div:last-of-type {
|
|
display: flex;
|
|
align-items: center;
|
|
}
|
|
|
|
#listingView .header .name {
|
|
margin-right: 1.5em;
|
|
}
|
|
|
|
#listingView .header>p {
|
|
margin: 0;
|
|
cursor: pointer;
|
|
}
|
|
|
|
#listingView .header .size,
|
|
#listingView.list .listing-item .size,
|
|
#listingView.compact .listing-item .size {
|
|
width: 25%;
|
|
}
|
|
|
|
#listingView .header .duration,
|
|
#listingView.list .listing-item .duration,
|
|
#listingView.compact .listing-item .duration {
|
|
margin-left: auto;
|
|
padding-right: 1em;
|
|
}
|
|
|
|
#listingView.list .listing-item .size.adjustment,
|
|
#listingView.compact .listing-item .size.adjustment {
|
|
width: calc(25% + 1em) !important;
|
|
}
|
|
|
|
|
|
#listingView .header .name,
|
|
#listingView.list .listing-item .name,
|
|
#listingView.compact .listing-item .name {
|
|
width: 50%;
|
|
}
|
|
|
|
#listingView.list .listing-item .name.adjustment,
|
|
#listingView.compact .listing-item .name.adjustment {
|
|
width: calc(50% + 1em) !important;
|
|
}
|
|
|
|
#listingView.normal .listing-item .text {
|
|
padding-left: 0.3em;
|
|
}
|
|
|
|
#listingView .header i {
|
|
font-size: 1.5em;
|
|
vertical-align: middle;
|
|
margin-left: .2em;
|
|
}
|
|
|
|
#listingView.compact .header {
|
|
z-index: 999;
|
|
padding: .85em;
|
|
border-bottom: 1px solid rgba(0, 0, 0, 0.1);
|
|
border-bottom-left-radius: 0px;
|
|
border-bottom-right-radius: 0px;
|
|
}
|
|
|
|
#listingView.compact .listing-item:first-child {
|
|
border-top: 1px solid rgba(0, 0, 0, 0.1);
|
|
}
|
|
|
|
#listingView.compact .header {
|
|
margin: 0;
|
|
border-bottom: unset;
|
|
box-shadow: unset;
|
|
}
|
|
|
|
#listingView.compact .header>div:first-child {
|
|
width: 0;
|
|
}
|
|
|
|
#listingView.compact .header a {
|
|
color: inherit;
|
|
}
|
|
|
|
#listingView.compact .header>div:first-child {
|
|
width: 0;
|
|
}
|
|
|
|
#listingView.compact .header span {
|
|
vertical-align: middle;
|
|
}
|
|
|
|
#listingView .header i {
|
|
opacity: 0;
|
|
transition: .1s ease all;
|
|
}
|
|
|
|
#listingView .header p:hover i,
|
|
#listingView .header .active i {
|
|
opacity: 1;
|
|
}
|
|
|
|
#listingView .header .active {
|
|
font-weight: bold;
|
|
}
|
|
|
|
#listingView.list {
|
|
flex-direction: column;
|
|
width: 100%;
|
|
max-width: 100%;
|
|
margin: 0;
|
|
}
|
|
|
|
#listingView.list .listing-item {
|
|
width: 100%;
|
|
margin: 0;
|
|
border: 1px solid rgba(0, 0, 0, 0.1);
|
|
padding: .5em;
|
|
border-top: 0;
|
|
}
|
|
|
|
.listing-item[aria-selected=true] {
|
|
background-color: color-mix(in srgb, var(--primaryColor) 85%, transparent) !important;
|
|
color: var(--item-selected) !important;
|
|
}
|
|
|
|
#listingView.gallery .listing-item[aria-selected=true] {
|
|
border: 0.2em solid var(--primaryColor) !important;
|
|
}
|
|
|
|
#listingView.gallery .listing-item .size,
|
|
#listingView.gallery .listing-item .modified,
|
|
#listingView.gallery .listing-item .duration,
|
|
#listingView.icons .listing-item .size,
|
|
#listingView.icons .listing-item .modified,
|
|
#listingView.icons .listing-item .duration {
|
|
display: none !important;
|
|
}
|
|
|
|
#listingView.list .listing-item div:first-of-type {
|
|
width: 3em;
|
|
}
|
|
|
|
#listingView.list .listing-item div:first-of-type i {
|
|
font-size: var(--list-icon-font-size, 2em);
|
|
transition: font-size 0.25s ease-out;
|
|
}
|
|
|
|
#listingView.list .listing-item div:first-of-type img {
|
|
width: var(--list-icon-image-size, 1.5em);
|
|
height: var(--list-icon-image-size, 1.5em);
|
|
border-radius: 0.2em;
|
|
transition: width 0.25s ease-out, height 0.25s ease-out;
|
|
}
|
|
|
|
#listingView.list .listing-item div:last-of-type {
|
|
display: flex;
|
|
align-items: center;
|
|
}
|
|
|
|
#listingView .header {
|
|
display: flex !important;
|
|
background: white;
|
|
border: 1px solid rgba(0, 0, 0, .1);
|
|
z-index: 999;
|
|
padding: .85em;
|
|
width: 100%;
|
|
}
|
|
|
|
#listingView.list .header i,
|
|
#listingView.normal .header i,
|
|
#listingView.gallery .header i,
|
|
#listingView.icons .header i {
|
|
font-size: 1.5em;
|
|
vertical-align: middle;
|
|
margin-left: .2em;
|
|
}
|
|
|
|
#listingView.compact .header,
|
|
#listingView.list .header {
|
|
border-top-left-radius: 1em;
|
|
border-top-right-radius: 1em;
|
|
border: unset;
|
|
}
|
|
|
|
#listingView.list .listing-item:first-child {
|
|
margin-top: .5em;
|
|
border-top-left-radius: 1em;
|
|
border-top-right-radius: 1em;
|
|
}
|
|
|
|
#listingView.compact .lastGroup>div:last-child {
|
|
border-bottom-left-radius: 1em;
|
|
border-bottom-right-radius: 1em;
|
|
}
|
|
|
|
#listingView.list .listing-item:last-child {
|
|
border-bottom-left-radius: 1em;
|
|
border-bottom-right-radius: 1em;
|
|
}
|
|
|
|
#listingView.list .listing-item:last-child {
|
|
margin-bottom: .5em;
|
|
}
|
|
|
|
#listingView>*>.header>div {
|
|
display: flex;
|
|
width: 100%;
|
|
}
|
|
|
|
#listingView.list .header,
|
|
#listingView.normal .header,
|
|
#listingView.gallery .header {
|
|
margin-bottom: .5em;
|
|
}
|
|
|
|
#listingView.list .header a {
|
|
color: inherit;
|
|
}
|
|
|
|
#listingView .name {
|
|
font-weight: normal;
|
|
}
|
|
|
|
#listingView .header span {
|
|
vertical-align: middle;
|
|
}
|
|
|
|
#listingView.list .header i {
|
|
opacity: 0;
|
|
transition: .1s ease all;
|
|
}
|
|
|
|
#listingView.list .header p:hover i,
|
|
#listingView.list .header .active i {
|
|
opacity: 1;
|
|
}
|
|
|
|
#listingView.list .header .active {
|
|
font-weight: bold;
|
|
}
|
|
|
|
.half-selected {
|
|
border-color: var(--primaryColor) !important;
|
|
}
|
|
|
|
#listingView.icons .listing-item .text {
|
|
display: block !important;
|
|
width: 100%;
|
|
margin-top: 0.3em;
|
|
padding: 0;
|
|
flex: 1;
|
|
text-align: center;
|
|
}
|
|
|
|
#listingView.icons .listing-item i {
|
|
height: var(--icons-view-icon-size, 50px);
|
|
width: var(--icons-view-icon-size, 80px);
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
transition: width 0.25s ease-out, height 0.25s ease-out;
|
|
}
|
|
|
|
#listingView.icons .listing-item img {
|
|
width: var(--icons-view-icon-size, 50px);
|
|
height: var(--icons-view-icon-size, 60px);
|
|
max-width: var(--icons-view-icon-size, 80px);
|
|
min-width: var(--icons-view-icon-size, 80px);
|
|
border-radius: 0.3em;
|
|
margin: 0;
|
|
transition: width 0.25s ease-out, height 0.25s ease-out;
|
|
}
|
|
|
|
/* Large icon styling for search results when preview images are enabled - matches icons view */
|
|
.search-entry.large-icons i.icon,
|
|
.search-entry.large-icons .image-preview,
|
|
.search-entry.large-icons .image-preview img.icon {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
transition: width 0.25s ease-out, height 0.25s ease-out;
|
|
padding: 0;
|
|
}
|
|
|
|
.search-entry.large-icons i.icon {
|
|
font-size: var(--icons-view-icon-size, 50px) !important;
|
|
line-height: 1 !important;
|
|
background: var(--iconBackground) !important;
|
|
}
|
|
|
|
.search-entry.large-icons .image-preview {
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.search-entry.large-icons .image-preview img.icon {
|
|
margin: 0;
|
|
object-fit: cover;
|
|
width: 50px;
|
|
height: 50px;
|
|
}
|
|
|
|
.search-entry.large-icons .image-preview {
|
|
width: unset !important;
|
|
height: unset !important;
|
|
}
|
|
|
|
#listingView.gallery .folder-items,
|
|
#listingView.gallery .file-items {
|
|
display: grid;
|
|
grid-template-columns: repeat(auto-fill, minmax(var(--item-width, 200px), 1fr));
|
|
gap: 1em;
|
|
padding: 0.5em;
|
|
width: 100%;
|
|
transition: grid-template-columns 0.25s ease-out;
|
|
}
|
|
|
|
#listingView.icons .folder-items,
|
|
#listingView.icons .file-items {
|
|
display: grid;
|
|
grid-template-columns: repeat(auto-fill, minmax(var(--icons-view-cell-size, 100px), 1fr));
|
|
gap: 0.5em;
|
|
padding: 0.25em;
|
|
width: 100%;
|
|
transition: grid-template-columns 0.25s ease-out;
|
|
}
|
|
|
|
/* Account space when sidebar is active - this give the columns a cleaner look */
|
|
#main.moveWithSidebar #listingView.icons .folder-items,
|
|
#main.moveWithSidebar #listingView.icons .file-items {
|
|
grid-template-columns: repeat(auto-fill, minmax(calc(var(--icons-view-cell-size, 100px) * 0.9), 1fr));
|
|
}
|