Toggle avatar cloning

This commit is contained in:
Natsumi
2022-01-15 15:44:20 +13:00
parent 70b34f6772
commit 3f5f231cd5
2 changed files with 20 additions and 5 deletions

View File

@@ -18468,6 +18468,14 @@ speechSynthesis.getVoices();
}
};
$app.methods.toggleAvatarCopying = function () {
API.saveCurrentUser({
allowAvatarCopying: !API.currentUser.allowAvatarCopying
}).then((args) => {
return args;
});
};
$app = new Vue($app);
window.$app = $app;
})();

View File

@@ -1484,11 +1484,18 @@ html
.detail
span.name Date Joined
span.extra(v-text="userDialog.ref.date_joined")
.x-friend-item(style="cursor:default")
.detail
span.name Avatar Copying
span.extra(v-if="userDialog.ref.allowAvatarCopying" style="color:#67C23A") Allow
span.extra(v-else style="color:#F56C6C") Deny
template(v-if="API.currentUser.id === userDialog.id")
.x-friend-item(@click="toggleAvatarCopying")
.detail
span.name Avatar Cloning
span.extra(v-if="userDialog.ref.allowAvatarCopying" style="color:#67C23A") Allow
span.extra(v-else style="color:#F56C6C") Deny
template(v-else)
.x-friend-item(style="cursor:default")
.detail
span.name Avatar Cloning
span.extra(v-if="userDialog.ref.allowAvatarCopying" style="color:#67C23A") Allow
span.extra(v-else style="color:#F56C6C") Deny
.x-friend-item(v-if="userDialog.ref.id === API.currentUser.id && API.currentUser.homeLocation" @click="showWorldDialog(API.currentUser.homeLocation)" style="width:100%")
.detail
span.name Home Location