From c6b88c74cd23fde552900aaac5ed2ef989161cc4 Mon Sep 17 00:00:00 2001 From: Natsumi Date: Sat, 24 May 2025 00:30:53 +1000 Subject: [PATCH] Add avatar author tags to avatar dialog --- .../dialogs/AvatarDialog/AvatarDialog.vue | 30 ++++++++++-- .../AvatarDialog/SetAvatarStylesDialog.vue | 48 +++++++++++++++---- src/localization/en/en.json | 2 +- 3 files changed, 66 insertions(+), 14 deletions(-) diff --git a/src/components/dialogs/AvatarDialog/AvatarDialog.vue b/src/components/dialogs/AvatarDialog/AvatarDialog.vue index 90d8c4b9..2e5dd1e8 100644 --- a/src/components/dialogs/AvatarDialog/AvatarDialog.vue +++ b/src/components/dialogs/AvatarDialog/AvatarDialog.vue @@ -197,6 +197,16 @@ }} + + + @@ -314,8 +324,8 @@ {{ t('dialog.avatar.actions.change_content_tags') }} - {{ - t('dialog.avatar.actions.change_styles') + {{ + t('dialog.avatar.actions.change_styles_author_tags') }} {{ t('dialog.avatar.actions.change_image') @@ -596,7 +606,9 @@ primaryStyle: '', secondaryStyle: '', availableAvatarStyles: [], - availableAvatarStylesMap: new Map() + availableAvatarStylesMap: new Map(), + initialTags: [], + authorTags: '' }); const avatarDialogPlatform = computed(() => { @@ -701,7 +713,7 @@ case 'Change Content Tags': showSetAvatarTagsDialog(D.id); break; - case 'Change Styles': + case 'Change Styles and Author Tags': showSetAvatarStylesDialog(D.id); break; case 'Download Unity Package': @@ -1154,6 +1166,16 @@ D.secondaryStyle = props.avatarDialog.ref.styles?.secondary || ''; D.initialPrimaryStyle = D.primaryStyle; D.initialSecondaryStyle = D.secondaryStyle; + D.initialTags = props.avatarDialog.ref.tags; + D.authorTags = ''; + for (const tag of D.initialTags) { + if (tag.startsWith('author_tag_')) { + if (D.authorTags) { + D.authorTags += ','; + } + D.authorTags += tag.substring(11); + } + } nextTick(() => { D.loading = false; }); diff --git a/src/components/dialogs/AvatarDialog/SetAvatarStylesDialog.vue b/src/components/dialogs/AvatarDialog/SetAvatarStylesDialog.vue index 682c064a..6ac92a3a 100644 --- a/src/components/dialogs/AvatarDialog/SetAvatarStylesDialog.vue +++ b/src/components/dialogs/AvatarDialog/SetAvatarStylesDialog.vue @@ -38,6 +38,16 @@ :value="style"> +
+
{{ $t('dialog.set_world_tags.author_tags') }}
+