Showing scene and channel count on entity page and tile.

This commit is contained in:
DebaucheryLibrarian
2021-10-30 22:41:58 +02:00
parent 8322d43b09
commit b764fdec85
8 changed files with 168 additions and 112 deletions

View File

@@ -1,15 +1,20 @@
<template>
<div class="filter-bar noselect">
<div class="sort">
<router-link
<RouterLink
v-for="section in ranges"
:key="section"
:to="{ params: { range: section, pageNumber: 1 }, query: $route.query }"
:class="{ active: $route.name === section || range === section }"
class="range range-button"
>{{ section }}</router-link>
>{{ section }}</RouterLink>
</div>
<span
v-if="itemsTotal && showTotal"
class="total"
>{{ itemsTotal }} <template v-if="itemsTotal === 1">scene</template><template v-else>scenes</template></span>
<div class="filters">
<ActorFilter
class="filters-filter"
@@ -78,6 +83,10 @@ export default {
type: Boolean,
default: false,
},
showTotal: {
type: Boolean,
default: true,
},
itemsTotal: {
type: Number,
default: 0,
@@ -240,6 +249,10 @@ export default {
.filters-filter:last-child .filter {
padding: .5rem 0 .5rem .5rem;
}
.total {
display: none;
}
}
</style>
@@ -351,4 +364,11 @@ export default {
margin: 0 1rem 0 0;
}
}
.total {
flex-shrink: 0;
padding: 0 1rem;
color: var(--shadow);
font-size: .8rem;
}
</style>