From c215410e692acc6f3c15afcf9727ca1fea2defef Mon Sep 17 00:00:00 2001 From: kakkokari-gtyih <67428053+kakkokari-gtyih@users.noreply.github.com> Date: Sat, 5 Oct 2024 15:27:27 +0900 Subject: [PATCH] showBelow -> showBehind --- locales/index.d.ts | 2 +- locales/ja-JP.yml | 2 +- .../src/core/entities/UserEntityService.ts | 2 +- packages/backend/src/models/User.ts | 2 +- packages/backend/src/models/json-schema/user.ts | 2 +- .../backend/src/server/api/endpoints/i/update.ts | 4 ++-- .../frontend/src/components/global/MkAvatar.vue | 2 +- .../settings/avatar-decoration.decoration.vue | 4 ++-- .../pages/settings/avatar-decoration.dialog.vue | 16 ++++++++-------- .../src/pages/settings/avatar-decoration.vue | 6 +++--- packages/misskey-js/src/autogen/types.ts | 4 ++-- 11 files changed, 23 insertions(+), 23 deletions(-) diff --git a/locales/index.d.ts b/locales/index.d.ts index e33d41f939..6062868ae4 100644 --- a/locales/index.d.ts +++ b/locales/index.d.ts @@ -4921,7 +4921,7 @@ export interface Locale extends ILocale { /** * アイコンの後ろに表示 */ - "showBelowAvatar": string; + "showBehindAvatar": string; /** * アイコンのデコレーションを表示 */ diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index 29229850b7..5286e0c596 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -1225,7 +1225,7 @@ detach: "外す" detachAll: "全て外す" angle: "角度" flip: "反転" -showBelowAvatar: "アイコンの後ろに表示" +showBehindAvatar: "アイコンの後ろに表示" showAvatarDecorations: "アイコンのデコレーションを表示" releaseToRefresh: "離してリロード" refreshing: "リロード中" diff --git a/packages/backend/src/core/entities/UserEntityService.ts b/packages/backend/src/core/entities/UserEntityService.ts index f98320b751..91d8a68f6d 100644 --- a/packages/backend/src/core/entities/UserEntityService.ts +++ b/packages/backend/src/core/entities/UserEntityService.ts @@ -486,7 +486,7 @@ export class UserEntityService implements OnModuleInit { flipH: ud.flipH || undefined, offsetX: ud.offsetX || undefined, offsetY: ud.offsetY || undefined, - showBelow: ud.showBelow || undefined, + showBehind: ud.showBehind || undefined, url: decorations.find(d => d.id === ud.id)!.url, }))) : [], isBot: user.isBot, diff --git a/packages/backend/src/models/User.ts b/packages/backend/src/models/User.ts index 68773ee3b3..e4c8a52ab9 100644 --- a/packages/backend/src/models/User.ts +++ b/packages/backend/src/models/User.ts @@ -147,7 +147,7 @@ export class MiUser { flipH?: boolean; offsetX?: number; offsetY?: number; - showBelow?: boolean; + showBehind?: boolean; }[]; @Index() diff --git a/packages/backend/src/models/json-schema/user.ts b/packages/backend/src/models/json-schema/user.ts index 6e1dce4d2d..238df6a161 100644 --- a/packages/backend/src/models/json-schema/user.ts +++ b/packages/backend/src/models/json-schema/user.ts @@ -104,7 +104,7 @@ export const packedUserLiteSchema = { type: 'number', nullable: false, optional: true, }, - showBelow: { + showBehind: { type: 'boolean', nullable: false, optional: true, }, diff --git a/packages/backend/src/server/api/endpoints/i/update.ts b/packages/backend/src/server/api/endpoints/i/update.ts index 41fa7473f2..072ed8a07e 100644 --- a/packages/backend/src/server/api/endpoints/i/update.ts +++ b/packages/backend/src/server/api/endpoints/i/update.ts @@ -146,7 +146,7 @@ export const paramDef = { flipH: { type: 'boolean', nullable: true }, offsetX: { type: 'number', nullable: true, maximum: 0.25, minimum: -0.25 }, offsetY: { type: 'number', nullable: true, maximum: 0.25, minimum: -0.25 }, - showBelow: { type: 'boolean', nullable: true }, + showBehind: { type: 'boolean', nullable: true }, }, required: ['id'], } }, @@ -387,7 +387,7 @@ export default class extends Endpoint { // eslint- flipH: d.flipH ?? false, offsetX: d.offsetX ?? 0, offsetY: d.offsetY ?? 0, - showBelow: d.showBelow ?? false, + showBehind: d.showBehind ?? false, })); } diff --git a/packages/frontend/src/components/global/MkAvatar.vue b/packages/frontend/src/components/global/MkAvatar.vue index aab6752450..f11676cf41 100644 --- a/packages/frontend/src/components/global/MkAvatar.vue +++ b/packages/frontend/src/components/global/MkAvatar.vue @@ -115,7 +115,7 @@ function getDecorationOffset(decoration: Omit) { - return decoration.showBelow ? '-1' : undefined; + return decoration.showBehind ? '-1' : undefined; } const color = ref(); diff --git a/packages/frontend/src/pages/settings/avatar-decoration.decoration.vue b/packages/frontend/src/pages/settings/avatar-decoration.decoration.vue index 30b158b703..6785cddaf5 100644 --- a/packages/frontend/src/pages/settings/avatar-decoration.decoration.vue +++ b/packages/frontend/src/pages/settings/avatar-decoration.decoration.vue @@ -9,7 +9,7 @@ SPDX-License-Identifier: AGPL-3.0-only @click="emit('click')" >
{{ decoration.name }}
- + @@ -32,7 +32,7 @@ const props = defineProps<{ flipH?: boolean; offsetX?: number; offsetY?: number; - showBelow?: boolean; + showBehind?: boolean; }>(); const emit = defineEmits<{ diff --git a/packages/frontend/src/pages/settings/avatar-decoration.dialog.vue b/packages/frontend/src/pages/settings/avatar-decoration.dialog.vue index d4378c7170..e9a9c582ad 100644 --- a/packages/frontend/src/pages/settings/avatar-decoration.dialog.vue +++ b/packages/frontend/src/pages/settings/avatar-decoration.dialog.vue @@ -29,8 +29,8 @@ SPDX-License-Identifier: AGPL-3.0-only - - + + @@ -74,14 +74,14 @@ const emit = defineEmits<{ flipH: boolean; offsetX: number; offsetY: number; - showBelow: boolean; + showBehind: boolean; }): void; (ev: 'update', payload: { angle: number; flipH: boolean; offsetX: number; offsetY: number; - showBelow: boolean; + showBehind: boolean; }): void; (ev: 'detach'): void; }>(); @@ -92,7 +92,7 @@ const angle = ref((props.usingIndex != null ? $i.avatarDecorations[props.usingIn const flipH = ref((props.usingIndex != null ? $i.avatarDecorations[props.usingIndex].flipH : null) ?? false); const offsetX = ref((props.usingIndex != null ? $i.avatarDecorations[props.usingIndex].offsetX : null) ?? 0); const offsetY = ref((props.usingIndex != null ? $i.avatarDecorations[props.usingIndex].offsetY : null) ?? 0); -const showBelow = ref((props.usingIndex != null ? $i.avatarDecorations[props.usingIndex].showBelow : null) ?? false); +const showBehind = ref((props.usingIndex != null ? $i.avatarDecorations[props.usingIndex].showBehind : null) ?? false); const decorationsForPreview = computed(() => { const decoration = { @@ -103,7 +103,7 @@ const decorationsForPreview = computed(() => { offsetX: offsetX.value, offsetY: offsetY.value, blink: true, - showBelow: showBelow.value, + showBehind: showBehind.value, }; const decorations = [...$i.avatarDecorations]; if (props.usingIndex != null) { @@ -124,7 +124,7 @@ async function update() { flipH: flipH.value, offsetX: offsetX.value, offsetY: offsetY.value, - showBelow: showBelow.value, + showBehind: showBehind.value, }); dialog.value?.close(); } @@ -135,7 +135,7 @@ async function attach() { flipH: flipH.value, offsetX: offsetX.value, offsetY: offsetY.value, - showBelow: showBelow.value, + showBehind: showBehind.value, }); dialog.value?.close(); } diff --git a/packages/frontend/src/pages/settings/avatar-decoration.vue b/packages/frontend/src/pages/settings/avatar-decoration.vue index 5324a6b7f7..e432b8d513 100644 --- a/packages/frontend/src/pages/settings/avatar-decoration.vue +++ b/packages/frontend/src/pages/settings/avatar-decoration.vue @@ -21,7 +21,7 @@ SPDX-License-Identifier: AGPL-3.0-only :flipH="avatarDecoration.flipH" :offsetX="avatarDecoration.offsetX" :offsetY="avatarDecoration.offsetY" - :showBelow="avatarDecoration.showBelow" + :showBehind="avatarDecoration.showBehind" :active="true" @click="openDecoration(avatarDecoration, i)" /> @@ -79,7 +79,7 @@ function openDecoration(avatarDecoration, index?: number) { flipH: payload.flipH, offsetX: payload.offsetX, offsetY: payload.offsetY, - showBelow: payload.showBelow, + showBehind: payload.showBehind, }; const update = [...$i.avatarDecorations, decoration]; await os.apiWithDialog('i/update', { @@ -94,7 +94,7 @@ function openDecoration(avatarDecoration, index?: number) { flipH: payload.flipH, offsetX: payload.offsetX, offsetY: payload.offsetY, - showBelow: payload.showBelow, + showBehind: payload.showBehind, }; const update = [...$i.avatarDecorations]; update[index] = decoration; diff --git a/packages/misskey-js/src/autogen/types.ts b/packages/misskey-js/src/autogen/types.ts index 33724bc016..e40debb3e1 100644 --- a/packages/misskey-js/src/autogen/types.ts +++ b/packages/misskey-js/src/autogen/types.ts @@ -3715,7 +3715,7 @@ export type components = { url: string; offsetX?: number; offsetY?: number; - showBelow?: boolean; + showBehind?: boolean; }[]; isBot?: boolean; isCat?: boolean; @@ -19698,7 +19698,7 @@ export type operations = { flipH?: boolean | null; offsetX?: number | null; offsetY?: number | null; - showBelow?: boolean | null; + showBehind?: boolean | null; })[]; /** Format: misskey:id */ bannerId?: string | null;