From a14092aaf4f3d8aff53260bcaabf6ea12316e590 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fernando=20Fern=C3=A1ndez?= Date: Tue, 5 Nov 2024 23:28:43 +0100 Subject: [PATCH] refactor: replace deprecated getItemImageUrl function (#2488) --- .../src/components/Item/Metadata/MetadataEditor.vue | 3 ++- .../src/components/Item/Metadata/PersonEditor.vue | 3 ++- frontend/src/utils/images.ts | 13 +++++++++++-- 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/frontend/src/components/Item/Metadata/MetadataEditor.vue b/frontend/src/components/Item/Metadata/MetadataEditor.vue index bb3fff0963d..723d151d352 100644 --- a/frontend/src/components/Item/Metadata/MetadataEditor.vue +++ b/frontend/src/components/Item/Metadata/MetadataEditor.vue @@ -158,7 +158,7 @@ v-if="item.Id && item.PrimaryImageTag" :alt="$t('person')" :src=" - remote.sdk.api?.getItemImageUrl( + getItemImageUrl( item.Id, ImageType.Primary ) @@ -234,6 +234,7 @@ import { format, formatISO } from 'date-fns'; import { computed, ref } from 'vue'; import { useI18n } from 'vue-i18n'; import { watchImmediate } from '@vueuse/core'; +import { getItemImageUrl } from '@/utils/images'; import { isArray } from '@/utils/validation'; import { remote } from '@/plugins/remote'; import { useSnackbar } from '@/composables/use-snackbar'; diff --git a/frontend/src/components/Item/Metadata/PersonEditor.vue b/frontend/src/components/Item/Metadata/PersonEditor.vue index adee5401fb7..12e55163061 100644 --- a/frontend/src/components/Item/Metadata/PersonEditor.vue +++ b/frontend/src/components/Item/Metadata/PersonEditor.vue @@ -14,7 +14,7 @@ class="ml-2">