Added actor revision overviews to actor and user pages.

This commit is contained in:
2024-10-23 01:28:54 +02:00
parent d0cf9bf5d0
commit 05bd7b703d
21 changed files with 424 additions and 219 deletions

View File

@@ -22,42 +22,48 @@
<a
:href="`/user/${profile.username}/stashes`"
class="domain nolink"
:class="{ active: domain === 'stashes' }"
:class="{ active: section === 'stashes' }"
>Stashes</a>
<a
:href="`/user/${profile.username}/alerts`"
class="domain nolink"
:class="{ active: domain === 'alerts' }"
:class="{ active: section === 'alerts' }"
>Alerts</a>
<a
:href="`/user/${profile.username}/templates`"
class="domain nolink"
:class="{ active: domain === 'templates' }"
:class="{ active: section === 'templates' }"
>Templates</a>
<a
:href="`/user/${profile.username}/revisions`"
:href="`/user/${profile.username}/revisions/scenes`"
class="domain nolink"
:class="{ active: domain === 'revisions' }"
>Revisions</a>
:class="{ active: section === 'revisions' && domain === 'scenes' }"
>Scene Revisions</a>
<a
:href="`/user/${profile.username}/revisions/actors`"
class="domain nolink"
:class="{ active: section === 'revisions' && domain === 'actors' }"
>Actor Revisions</a>
</nav>
<Stashes v-if="domain === 'stashes'" />
<Alerts v-if="domain === 'alerts' && profile.id === user?.id" />
<Stashes v-if="section === 'stashes'" />
<Alerts v-if="section === 'alerts' && profile.id === user?.id" />
<Summaries
v-if="domain === 'templates' && profile.id === user?.id"
v-if="section === 'templates' && profile.id === user?.id"
:release="mockupRelease"
/>
</div>
<div
v-if="domain === 'revisions' && profile.id === user?.id"
v-if="section === 'revisions' && profile.id === user?.id"
class="profile-section revisions"
>
<h3 class="section-header heading">Revisions</h3>
<h3 class="section-header heading">{{ domain.slice(0, -1) }} Revisions</h3>
<Revisions context="user" />
</div>
</div>
@@ -73,7 +79,10 @@ import Summaries from '#/components/scenes/summaries.vue';
import Revisions from '#/components/edit/revisions.vue';
const pageContext = inject('pageContext');
const section = pageContext.routeParams.section;
const domain = pageContext.routeParams.domain;
const user = pageContext.user;
const profile = ref(pageContext.pageProps.profile);
@@ -117,6 +126,7 @@ const mockupRelease = {
align-items: center;
justify-content: space-between;
padding: .5rem 1rem;
text-transform: capitalize;
.button {
margin-left: 1rem;
@@ -222,6 +232,11 @@ const mockupRelease = {
padding: 0 1rem;
}
.revisions-nav {
display: flex;
gap: 1rem;
}
@media(--compact) {
.domains {
padding: .5rem 1rem;