Added actor profile revisions.

This commit is contained in:
2024-10-22 03:12:42 +02:00
parent b5bef49f73
commit 3967745fb3
31 changed files with 1907 additions and 67 deletions

View File

@@ -136,13 +136,32 @@
class="bio-item figure"
>
<dfn class="bio-label"><Icon icon="ruler" />Figure</dfn>
<span class="bio-value">{{ actor.bust || '??' }}{{ actor.cup || '?' }}-{{ actor.waist || '??' }}-{{ actor.hip || '??' }}</span>
</li>
<li
v-if="!actor.naturalBoobs || !actor.naturalButt"
class="bio-item augmentations"
>
<dfn class="bio-label"><Icon icon="magic-wand2" />Augmentations</dfn>
<span class="bio-value">
<Icon
v-if="actor.naturalBoobs === false"
:title="'Enhanced boobs'"
icon="magic-wand2"
class="enhanced"
/>{{ actor.bust || '??' }}{{ actor.cup || '?' }}-{{ actor.waist || '??' }}-{{ actor.hip || '??' }}
<div
v-if="!actor.naturalBoobs"
:title="[actor.boobsVolume, augmentationMap[actor.boobsPlacement] || actor.boobsPlacement, augmentationMap[actor.boobsImplant] || actor.boobsImplant].filter(Boolean).join(' ')"
class="augmentations-section"
>Boobs<template v-if="actor.boobsVolume || actor.boobsImplant">:&nbsp;</template>
<template v-if="actor.boobsVolume">{{ actor.boobsVolume }}cc</template>
<template v-if="actor.boobsImplant">&nbsp;{{ augmentationMap[actor.boobsImplant] || actor.boobsImplant }}</template>
</div>
<div
v-if="!actor.naturalButt"
class="augmentations-section"
>Butt<template v-if="actor.buttVolume || actor.buttImplant">:&nbsp;</template>
<template v-if="actor.buttVolume">{{ actor.buttVolume }}cc</template>
<template v-if="actor.buttImplant">&nbsp;{{ augmentationMap[actor.buttImplant] || actor.buttImplant }}</template>
</div>
</span>
</li>
@@ -240,6 +259,21 @@
</li>
<li class="bio-item updated hideable">Updated {{ formatDate(actor.updatedAt, 'yyyy-MM-dd hh:mm') }}, ID: {{ actor.id }}</li>
<li class="bio-item actor-actions">
<a
v-if="user && user.role !== 'user'"
:href="`/actor/edit/${actor.id}/${actor.slug}`"
target="_blank"
class="link"
>Edit bio</a>
<a
:href="`/actor/revisions/${actor.id}/${actor.slug}`"
target="_blank"
class="link"
>Revisions</a>
</li>
</ul>
<div class="descriptions-container">
@@ -294,13 +328,16 @@
</template>
<script setup>
import { ref } from 'vue';
import { ref, inject } from 'vue';
import getPath from '#/src/get-path.js';
import { formatDate } from '#/utils/format.js';
const expanded = ref(false);
const pageContext = inject('pageContext');
const user = pageContext.user;
const props = defineProps({
actor: {
type: Object,
@@ -326,6 +363,17 @@ const showExpand = [
'weight',
].some((attribute) => !!props.actor[attribute]);
const augmentationMap = {
bbl: 'BBL',
fat: 'fat transfer',
lift: 'direct lift',
lipo: 'lipo without BBL',
filler: 'filler',
mms: 'MMS',
over: 'over-muscle',
under: 'under-muscle',
};
const descriptions = Object.values(Object.fromEntries(props.actor.profiles
.filter((profile) => !!profile.description)
.map((profile) => [profile.descriptionHash, {
@@ -519,6 +567,11 @@ const descriptions = Object.values(Object.fromEntries(props.actor.profiles
content: ',\00a0';
}
.augmentations .bio-value {
flex-direction: column;
align-items: flex-end;
}
.updated {
color: var(--highlight-weak-20);
font-size: .8rem;
@@ -638,6 +691,16 @@ const descriptions = Object.values(Object.fromEntries(props.actor.profiles
}
}
.actor-actions {
justify-content: flex-start;
gap: 1rem;
font-weight: normal;
.link {
color: var(--highlight-strong-20);
}
}
@media(--big) {
.descriptions-container {
display: none;