From 56ceeeb4c7b5fdfdd99363a1315fb4c6606ddf90 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Frane=20Poli=C4=87?= <16856471+fPolic@users.noreply.github.com> Date: Mon, 2 Sep 2024 13:56:56 +0200 Subject: [PATCH] fix(dashboard): product option delete message (#8934) FIXES CC-408 --- packages/admin-next/dashboard/src/i18n/translations/en.json | 4 +++- .../product-option-section/product-option-section.tsx | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/packages/admin-next/dashboard/src/i18n/translations/en.json b/packages/admin-next/dashboard/src/i18n/translations/en.json index 9d8a3ea4ff..dd3c06df12 100644 --- a/packages/admin-next/dashboard/src/i18n/translations/en.json +++ b/packages/admin-next/dashboard/src/i18n/translations/en.json @@ -574,7 +574,9 @@ "create": { "header": "Create Option", "successToast": "Option {{title}} was successfully created." - } + }, + "deleteWarning": "You are about to delete the product option: {{title}}. This action cannot be undone." + }, "organization": { "header": "Organize", diff --git a/packages/admin-next/dashboard/src/routes/products/product-detail/components/product-option-section/product-option-section.tsx b/packages/admin-next/dashboard/src/routes/products/product-detail/components/product-option-section/product-option-section.tsx index 6087ab7052..6e037c959c 100644 --- a/packages/admin-next/dashboard/src/routes/products/product-detail/components/product-option-section/product-option-section.tsx +++ b/packages/admin-next/dashboard/src/routes/products/product-detail/components/product-option-section/product-option-section.tsx @@ -20,8 +20,8 @@ const OptionActions = ({ const handleDelete = async () => { const res = await prompt({ title: t("general.areYouSure"), - description: t("products.deleteWarning", { - title: product.title, + description: t("products.options.deleteWarning", { + title: option.title, }), confirmText: t("actions.delete"), cancelText: t("actions.cancel"),