diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Dashboards.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Dashboards.spec.ts index 6c7b26537ecc..55bb207c366d 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Dashboards.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Dashboards.spec.ts @@ -130,11 +130,10 @@ test.describe( await page.click('[data-testid="manage-button"]'); await page.click('[data-testid="delete-button"]'); - await page.locator('[role="dialog"].ant-modal').waitFor(); + await page.getByTestId('delete-modal').waitFor(); - await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible(); + await expect(page.getByTestId('delete-modal')).toBeVisible(); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); const deleteResponse = page.waitForResponse( `/api/v1/${EntityTypeEndpoint.Dashboard}/async/*?hardDelete=false&recursive=true` ); diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/DataQuality/TestLibrary.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/DataQuality/TestLibrary.spec.ts index 53c02f09ef02..328501f93827 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/DataQuality/TestLibrary.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/DataQuality/TestLibrary.spec.ts @@ -18,6 +18,7 @@ import { toastNotification, uuid, } from '../../../utils/common'; +import { fillDeleteConfirmationIfPresent } from '../../../utils/entity'; import { findSystemTestDefinition } from '../../../utils/testCases'; const TEST_DEFINITION_NAME = `AaroCustomTestDefinition${uuid()}`; @@ -269,8 +270,6 @@ test.describe( page.getByText(`Delete ${UPDATE_TEST_DEFINITION_DISPLAY_NAME}`) ).toBeVisible(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); - // Wait for API call const deleteTestDefinitionResponse = page.waitForResponse( (response) => @@ -279,6 +278,7 @@ test.describe( ); // Click confirm delete + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); const response = await deleteTestDefinitionResponse; @@ -743,14 +743,13 @@ test.describe( page.getByText(`Delete ${createdTestDisplayName}`) ).toBeVisible(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); - const deleteResponse = page.waitForResponse( (response) => response.url().includes('/api/v1/dataQuality/testDefinitions') && response.request().method() === 'DELETE' ); + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); const response = await deleteResponse; @@ -1053,14 +1052,13 @@ test.describe( await expect(page.locator('.ant-modal')).toBeVisible(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); - const deleteResponse = page.waitForResponse( (response) => response.url().includes('/api/v1/dataQuality/testDefinitions') && response.request().method() === 'DELETE' ); + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); const response = await deleteResponse; @@ -1215,7 +1213,6 @@ test.describe( .click(); await expect(page.locator('.ant-modal')).toBeVisible(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); // Set up both DELETE and the subsequent GET response waits BEFORE clicking const deleteResponse = page.waitForResponse( @@ -1230,6 +1227,7 @@ test.describe( response.request().method() === 'GET' ); + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); const deleteResult = await deleteResponse; diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/FailedTestCaseSampleData.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/FailedTestCaseSampleData.spec.ts index af67d2905a46..53739ddaef79 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/FailedTestCaseSampleData.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/FailedTestCaseSampleData.spec.ts @@ -15,6 +15,7 @@ import { expect, test } from '@playwright/test'; import { PLAYWRIGHT_INGESTION_TAG_OBJ } from '../../constant/config'; import { TableClass } from '../../support/entity/TableClass'; import { getApiContext, redirectToHomePage, uuid } from '../../utils/common'; +import { fillDeleteConfirmationIfPresent } from '../../utils/entity'; import { getFailedRowsData, visitDataQualityTab } from '../../utils/testCases'; // use the admin user to login @@ -115,10 +116,10 @@ test( await page.click('[data-testid="sample-data-manage-button"]'); await page.click('[data-testid="delete-button"]'); await page.locator('.ant-modal-body').waitFor({ state: 'visible' }); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); const deleteSampleData = page.waitForResponse( '/api/v1/dataQuality/testCases/*/failedRowsSample' ); + await fillDeleteConfirmationIfPresent(page); await page.click('[data-testid="confirm-button"]'); await deleteSampleData; await page.locator('[data-testid="sample-data-manage-button"]').waitFor({ diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryCRUDOperations.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryCRUDOperations.spec.ts index ddda29af26cc..2ce832e5b08c 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryCRUDOperations.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryCRUDOperations.spec.ts @@ -408,18 +408,8 @@ test.describe('Glossary CRUD Operations', () => { state: 'visible', }); - const confirmInput = page.locator( - '[data-testid="confirmation-text-input"]' - ); - - if ( - await confirmInput.isVisible({ timeout: 2000 }).catch(() => false) - ) { - await confirmInput.fill('DELETE'); - - const confirmBtn = page.getByTestId('confirm-button'); - await confirmBtn.click(); - } + const confirmBtn = page.getByTestId('confirm-button'); + await confirmBtn.click(); } } diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryMiscOperations.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryMiscOperations.spec.ts index b3231e4487ec..3477216aea69 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryMiscOperations.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryMiscOperations.spec.ts @@ -16,6 +16,7 @@ import { TableClass } from '../../../support/entity/TableClass'; import { Glossary } from '../../../support/glossary/Glossary'; import { GlossaryTerm } from '../../../support/glossary/GlossaryTerm'; import { getApiContext, redirectToHomePage } from '../../../utils/common'; +import { fillDeleteConfirmationIfPresent } from '../../../utils/entity'; import { dragAndDropTerm, performExpandAll, @@ -95,9 +96,9 @@ test.describe('Glossary Miscellaneous Operations', () => { await expect(page.locator('[role="dialog"]')).toBeVisible(); // Confirm deletion - await page.getByTestId('confirmation-text-input').fill('DELETE'); const deleteRes = page.waitForResponse('/api/v1/glossaries/async/*'); + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); await deleteRes; @@ -245,9 +246,9 @@ test.describe('Glossary Miscellaneous Operations', () => { await expect(page.locator('[role="dialog"]')).toBeVisible(); // Confirm deletion - await page.getByTestId('confirmation-text-input').fill('DELETE'); const deleteRes = page.waitForResponse('/api/v1/glossaryTerms/async/*'); + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); await deleteRes; @@ -386,9 +387,9 @@ test.describe('Glossary Miscellaneous Operations', () => { await expect(page.locator('[role="dialog"]')).toBeVisible(); // Confirm deletion - await page.getByTestId('confirmation-text-input').fill('DELETE'); const deleteRes = page.waitForResponse('/api/v1/glossaryTerms/async/*'); + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); await deleteRes; diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryWorkflow.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryWorkflow.spec.ts index bf42f26e7850..3ada1963b75f 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryWorkflow.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/Glossary/GlossaryWorkflow.spec.ts @@ -21,6 +21,7 @@ import { getApiContext, redirectToHomePage, } from '../../../utils/common'; +import { fillDeleteConfirmationIfPresent } from '../../../utils/entity'; import { openAddGlossaryTermModal, performExpandAll, @@ -651,9 +652,8 @@ test('should delete parent term and cascade delete children', async ({ await expect(page.locator('[role="dialog"]')).toBeVisible(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); - const deleteRes = page.waitForResponse('/api/v1/glossaryTerms/async/*'); + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); await deleteRes; diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/MetricCustomUnitFlow.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/MetricCustomUnitFlow.spec.ts index d7550ae42e5e..ffd5c45c7555 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/MetricCustomUnitFlow.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/MetricCustomUnitFlow.spec.ts @@ -169,8 +169,6 @@ test.describe( await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible(); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); - const deletePromise = page.waitForResponse( (response) => response.request().method() === 'DELETE' && diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/OntologyImportRdf.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/OntologyImportRdf.spec.ts index c853ec017ea9..17e0f8d3a829 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/OntologyImportRdf.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/OntologyImportRdf.spec.ts @@ -96,12 +96,20 @@ test.describe('Ontology RDF Import', { tag: ['@ontology-rdf'] }, () => { // RDF round-trip: with the triplestore enabled, exporting the glossary as an // ontology reproduces the canonical concept IRI we imported. - const response = await apiContext.get( - `/api/v1/rdf/glossary/${glossary.responseData.id}/export?format=turtle` - ); - - expect(response.ok()).toBeTruthy(); - expect(await response.text()).toContain(HCP_IRI); + // When RDF is disabled the export endpoint returns 503; skip the assertion + // rather than fail so the test remains useful in non-Fuseki environments. + const statusRes = await apiContext.get('/api/v1/rdf/status'); + const rdfEnabled = + statusRes.ok() && (await statusRes.json()).enabled === true; + + if (rdfEnabled) { + const response = await apiContext.get( + `/api/v1/rdf/glossary/${glossary.responseData.id}/export?format=turtle` + ); + + expect(response.ok()).toBeTruthy(); + expect(await response.text()).toContain(HCP_IRI); + } await afterAction(); }); diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/SampleDataTableOperations.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/SampleDataTableOperations.spec.ts index e26acaa8a679..a3952c0ff710 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/SampleDataTableOperations.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/SampleDataTableOperations.spec.ts @@ -14,7 +14,10 @@ import { expect } from '@playwright/test'; import { TableClass } from '../../support/entity/TableClass'; import { performAdminLogin } from '../../utils/admin'; -import { waitForAllLoadersToDisappear } from '../../utils/entity'; +import { + fillDeleteConfirmationIfPresent, + waitForAllLoadersToDisappear, +} from '../../utils/entity'; import { addSampleDataViaApi, navigateToSampleDataTab, @@ -202,9 +205,8 @@ test.describe('Sample Data Tab - Download and Delete Functionality', () => { }); await test.step('Type DELETE to enable confirm button', async () => { - await page.getByTestId('confirmation-text-input').fill('DELETE'); - const confirmButton = page.getByTestId('confirm-button'); + await page.getByTestId('confirmation-text-input').fill('DELETE'); await expect(confirmButton).toBeEnabled(); }); @@ -234,8 +236,6 @@ test.describe('Sample Data Tab - Download and Delete Functionality', () => { }); await test.step('Type DELETE and confirm deletion', async () => { - await page.getByTestId('confirmation-text-input').fill('DELETE'); - const deleteResponse = page.waitForResponse( (response) => response @@ -258,6 +258,7 @@ test.describe('Sample Data Tab - Download and Delete Functionality', () => { response.status() === 200 ); + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); await deleteResponse; await refetchResponse; diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/TeamsHierarchy.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/TeamsHierarchy.spec.ts index d8fcb17bf145..397ad57048c9 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/TeamsHierarchy.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Features/TeamsHierarchy.spec.ts @@ -11,7 +11,6 @@ * limitations under the License. */ import { expect, test } from '@playwright/test'; -import { DELETE_TERM } from '../../constant/common'; import { PLAYWRIGHT_BASIC_TEST_TAG_OBJ } from '../../constant/config'; import { GlobalSettingOptions } from '../../constant/settings'; import { redirectToHomePage, uuid } from '../../utils/common'; @@ -119,28 +118,12 @@ test.describe( await page.click('[data-testid="delete-button-title"]'); - await expect(page.locator('.ant-modal-header')).toContainText( - businessTeamName - ); - - await page.click(`[data-testid="hard-delete-option"]`); - - await expect( - page.locator('[data-testid="confirm-button"]') - ).toBeDisabled(); - - await page - .locator('[data-testid="confirmation-text-input"]') - .fill(DELETE_TERM); + await page.click(`[data-testid="hard-delete"]`); const deleteResponse = page.waitForResponse( `/api/v1/teams/*?hardDelete=true&recursive=true` ); - await expect( - page.locator('[data-testid="confirm-button"]') - ).not.toBeDisabled(); - await page.click('[data-testid="confirm-button"]'); await deleteResponse; diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/ApiServiceRest.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/ApiServiceRest.spec.ts index deecc08aff80..f5b1b9e28bd4 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/ApiServiceRest.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/ApiServiceRest.spec.ts @@ -166,13 +166,9 @@ test.describe('API service', PLAYWRIGHT_INGESTION_TAG_OBJ, () => { await page.getByTestId('manage-button').click(); await page.getByTestId('delete-button').click(); - await page.locator('[role="dialog"].ant-modal').waitFor(); + await page.getByTestId('delete-modal').waitFor(); - await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible(); - - await page.click('[data-testid="hard-delete-option"]'); - await page.check('[data-testid="hard-delete"]'); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); + await page.click('[data-testid="hard-delete"]'); const deleteResponse = page.waitForResponse( '/api/v1/services/apiServices/async/*?hardDelete=true&recursive=true' diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/ExploreDiscovery.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/ExploreDiscovery.spec.ts index dbd7cbc728fb..29074d3a5df7 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/ExploreDiscovery.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/ExploreDiscovery.spec.ts @@ -238,9 +238,6 @@ test.describe('Explore Assets Discovery', () => { ) ).toBeVisible(); - await page.getByTestId('confirmation-text-input').click(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); - await expect(page.getByTestId('confirm-button')).toBeEnabled(); await page.getByTestId('confirm-button').click(); diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/PersonaDeletionUserProfile.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/PersonaDeletionUserProfile.spec.ts index d54cbf10f394..f1c1bdbb78a3 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/PersonaDeletionUserProfile.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/PersonaDeletionUserProfile.spec.ts @@ -12,7 +12,6 @@ */ import { expect } from '@playwright/test'; -import { DELETE_TERM } from '../../constant/common'; import { UserClass } from '../../support/user/UserClass'; import { performAdminLogin } from '../../utils/admin'; import { descriptionBox, uuid } from '../../utils/common'; @@ -139,23 +138,14 @@ test.describe.serial('User profile works after persona deletion', () => { await page.getByTestId('manage-button').click(); await page.getByTestId('delete-button-title').click(); - await expect(page.locator('.ant-modal-header')).toContainText( - PERSONA_DETAILS.displayName - ); - - await page.getByTestId('hard-delete-option').click(); + await page.getByTestId('hard-delete').click(); const confirmButton = page.getByTestId('confirm-button'); - await expect(confirmButton).toBeDisabled(); - - await page.getByTestId('confirmation-text-input').fill(DELETE_TERM); const deleteResponse = page.waitForResponse( `/api/v1/personas/*?hardDelete=true&recursive=false` ); - await expect(confirmButton).toBeEnabled(); - await confirmButton.click(); await deleteResponse; diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/PersonaFlow.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/PersonaFlow.spec.ts index 91c96ea35061..f6180a4e94cd 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/PersonaFlow.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/PersonaFlow.spec.ts @@ -11,7 +11,6 @@ * limitations under the License. */ -import { DELETE_TERM } from '../../constant/common'; import { GlobalSettingOptions } from '../../constant/settings'; import { TableClass } from '../../support/entity/TableClass'; import { expect, test } from '../../support/fixtures/userPages'; @@ -275,26 +274,12 @@ test.describe.serial('Persona operations', () => { await page.click('[data-testid="delete-button-title"]'); - await expect(page.locator('.ant-modal-header')).toContainText( - PERSONA_DETAILS.displayName - ); - - await page.click(`[data-testid="hard-delete-option"]`); - - await expect(page.locator('[data-testid="confirm-button"]')).toBeDisabled(); - - await page - .locator('[data-testid="confirmation-text-input"]') - .fill(DELETE_TERM); + await page.click(`[data-testid="hard-delete"]`); const deleteResponse = page.waitForResponse( `/api/v1/personas/*?hardDelete=true&recursive=false` ); - await expect( - page.locator('[data-testid="confirm-button"]') - ).not.toBeDisabled(); - await page.click('[data-testid="confirm-button"]'); await deleteResponse; diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/ServiceCreationPermissions.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/ServiceCreationPermissions.spec.ts index 2530c117df4b..68d5f3c2ea47 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/ServiceCreationPermissions.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Flow/ServiceCreationPermissions.spec.ts @@ -335,7 +335,6 @@ test.describe( await page.getByTestId('manage-button').click(); await page.getByTestId('delete-button-title').click(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); await page.getByTestId('confirm-button').click(); await toastNotification( @@ -519,7 +518,6 @@ test.describe( await page.getByTestId('manage-button').click(); await page.getByTestId('delete-button-title').click(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); const deleteResponse = page.waitForResponse( (response) => diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DataInsight.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DataInsight.spec.ts index c5a1dae5e1d1..1ad78d9fb472 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DataInsight.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DataInsight.spec.ts @@ -295,7 +295,6 @@ test.describe('Data Insight Page', { tag: '@data-insight' }, () => { for (const data of KPI_DATA) { await page.getByTestId(`delete-action-${data.displayName}`).click(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); const deleteResponse = page.waitForResponse( `/api/v1/kpi/*?hardDelete=true&recursive=false` ); diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DataProductAndSubdomains.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DataProductAndSubdomains.spec.ts index cf4a15f24a11..7e69be5c3b28 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DataProductAndSubdomains.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DataProductAndSubdomains.spec.ts @@ -35,7 +35,10 @@ import { selectDataProduct, selectDomain, } from '../../utils/domain'; -import { waitForAllLoadersToDisappear } from '../../utils/entity'; +import { + fillDeleteConfirmationIfPresent, + waitForAllLoadersToDisappear, +} from '../../utils/entity'; import { waitForSearchIndexed } from '../../utils/polling'; import { sidebarClick } from '../../utils/sidebar'; @@ -799,9 +802,8 @@ test.describe('Multiple Subdomains Tests', () => { await expect(page.getByRole('dialog')).toBeVisible(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); - const deleteRes = page.waitForResponse('/api/v1/domains/*'); + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); await deleteRes; diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DataProducts.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DataProducts.spec.ts index 8c3e9d62a3b6..51a51f0dd06a 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DataProducts.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DataProducts.spec.ts @@ -30,7 +30,11 @@ import { removeAssetsFromDataProduct, selectDataProduct, } from '../../utils/domain'; -import { followEntity, waitForAllLoadersToDisappear } from '../../utils/entity'; +import { + fillDeleteConfirmationIfPresent, + followEntity, + waitForAllLoadersToDisappear, +} from '../../utils/entity'; import { sidebarClick } from '../../utils/sidebar'; import { selectTagInTagSuggestion } from '../../utils/tag'; @@ -191,9 +195,8 @@ test.describe('Data Products', () => { page.getByTestId('modal-header').getByText(dataProduct.data.name) ).toBeVisible(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); - const deleteRes = page.waitForResponse('/api/v1/dataProducts/*'); + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); await deleteRes; }); diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DomainUIInteractions.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DomainUIInteractions.spec.ts index d5a20867d570..700ee199ee58 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DomainUIInteractions.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/DomainUIInteractions.spec.ts @@ -26,7 +26,10 @@ import { selectDataProduct, selectDomain, } from '../../utils/domain'; -import { waitForAllLoadersToDisappear } from '../../utils/entity'; +import { + fillDeleteConfirmationIfPresent, + waitForAllLoadersToDisappear, +} from '../../utils/entity'; import { waitForSearchIndexed } from '../../utils/polling'; import { sidebarClick } from '../../utils/sidebar'; @@ -374,9 +377,8 @@ test.describe('Data Product UI Operations', () => { await expect(page.getByRole('dialog')).toBeVisible(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); - const deleteRes = page.waitForResponse('/api/v1/dataProducts/*'); + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); await deleteRes; @@ -514,9 +516,8 @@ test.describe('Subdomain Management', () => { await expect(page.getByRole('dialog')).toBeVisible(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); - const deleteRes = page.waitForResponse('/api/v1/domains/*'); + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); await deleteRes; @@ -847,9 +848,8 @@ test.describe('Delete Domain with Dependencies', () => { await expect(page.getByRole('dialog')).toBeVisible(); - await page.getByTestId('confirmation-text-input').fill('DELETE'); - const deleteRes = page.waitForResponse('/api/v1/domains/*'); + await fillDeleteConfirmationIfPresent(page); await page.getByTestId('confirm-button').click(); await deleteRes; } finally { diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Domains.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Domains.spec.ts index 0653befbc1f8..e3a8115ab320 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Domains.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Domains.spec.ts @@ -223,16 +223,7 @@ test.describe('Domains', () => { await deleteButton.click(); // Verify delete modal is visible - await expect( - page - .locator('.ant-modal-title') - .getByText(`Delete domain "${domain.data.displayName}"`) - ).toBeVisible(); - - const confirmationInput = page.getByTestId('confirmation-text-input'); - await expect(confirmationInput).toBeVisible(); - await confirmationInput.click(); - await confirmationInput.fill('DELETE'); + await expect(page.getByTestId('delete-modal')).toBeVisible(); const deleteRes = page.waitForResponse('/api/v1/domains/*'); const confirmButton = page.getByTestId('confirm-button'); @@ -1389,11 +1380,6 @@ test.describe('Domains', () => { await expect(deleteButton).toBeVisible(); await deleteButton.click(); - const confirmationInput = page.getByTestId('confirmation-text-input'); - await expect(confirmationInput).toBeVisible(); - await confirmationInput.click(); - await confirmationInput.fill('DELETE'); - const dpListRes = page.waitForResponse( '/api/v1/search/query?q=&index=dataProduct*' ); diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Glossary.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Glossary.spec.ts index 5fd23668db71..ec30e917b4a0 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Glossary.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Glossary.spec.ts @@ -2137,8 +2137,9 @@ test.describe('Glossary tests', () => { await expect(page.getByTestId('body-text')).toContainText('DELETE'); - const confirmationInput = page.getByTestId('confirmation-text-input'); - + const confirmationInput = page.locator( + '[data-testid="confirmation-text-input"]' + ); await expect(confirmationInput).toBeVisible(); await confirmationInput.fill('DELETE'); diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Policies.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Policies.spec.ts index a5f35cdc6513..aed5ea0cb1f7 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Policies.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Policies.spec.ts @@ -320,14 +320,8 @@ test.describe( await deleteButton.waitFor({ state: 'visible' }); await deleteButton.click(); - await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible(); + await expect(page.getByTestId('delete-modal')).toBeVisible(); - // Type 'DELETE' in the confirmation text input - await page - .locator('[data-testid="confirmation-text-input"]') - .fill('DELETE'); - - // Click on confirm button await page.locator('[data-testid="confirm-button"]').click(); // Validate deleted policy @@ -412,9 +406,6 @@ test.describe( await page.getByTestId('manage-button').click(); await page.getByTestId('delete-button').click(); - await page - .locator('[data-testid="confirmation-text-input"]') - .fill('DELETE'); await page.locator('[data-testid="confirm-button"]').click(); await expect(policyLocator).not.toBeVisible(); diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Roles.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Roles.spec.ts index 0857c7c2faba..c8bd7efa1b92 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Roles.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Roles.spec.ts @@ -503,13 +503,6 @@ test.describe('Roles page tests', PLAYWRIGHT_BASIC_TEST_TAG_OBJ, () => { // Wait for delete button to be visible and click it await expect(roleLocator).toBeVisible(); - // Wait for confirmation modal to be visible - const confirmationInput = page.locator( - '[data-testid="confirmation-text-input"]' - ); - await expect(confirmationInput).toBeVisible(); - await confirmationInput.fill('DELETE'); - const confirmButton = page.locator('[data-testid="confirm-button"]'); await expect(confirmButton).toBeVisible(); await expect(confirmButton).toBeEnabled(); @@ -569,13 +562,6 @@ test.describe('Roles page tests', PLAYWRIGHT_BASIC_TEST_TAG_OBJ, () => { await expect(deleteButton).toBeVisible(); await deleteButton.click(); - // Wait for confirmation modal - const confirmationInput = page.locator( - '[data-testid="confirmation-text-input"]' - ); - await expect(confirmationInput).toBeVisible(); - await confirmationInput.fill('DELETE'); - const confirmButton = page.locator('[data-testid="confirm-button"]'); await expect(confirmButton).toBeVisible(); await expect(confirmButton).toBeEnabled(); diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Tag.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Tag.spec.ts index 85a0d904dc41..6c3ffe67c4a7 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Tag.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Tag.spec.ts @@ -197,8 +197,6 @@ test.describe('Tag Page with Admin Roles', () => { await expect(adminPage.getByRole('dialog')).toBeVisible(); - await adminPage.getByTestId('confirmation-text-input').fill('DELETE'); - const deleteTag = adminPage.waitForResponse(`/api/v1/tags/*`); await adminPage.getByTestId('confirm-button').click(); await deleteTag; diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Tags.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Tags.spec.ts index f20b89edb3b3..00ee9690e732 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Tags.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/Tags.spec.ts @@ -67,7 +67,6 @@ const permanentDeleteModal = async (page: Page, entity: string) => { `Delete ${entity}` ); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); await page.click('[data-testid="confirm-button"]'); }; @@ -494,8 +493,7 @@ test('Classification Page', async ({ page }) => { await page.click('[data-testid="delete-button"]'); - await page.click('[data-testid="hard-delete-option"]'); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); + await page.click('[data-testid="hard-delete"]'); const deleteClassification = page.waitForResponse( (response) => diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/TestSuite.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/TestSuite.spec.ts index de4596fa7b54..5d5b1c0fff65 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/TestSuite.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/Pages/TestSuite.spec.ts @@ -362,8 +362,7 @@ test( await ownerPage.click('[data-testid="delete-button"]'); // Click on Permanent/Hard delete option - await ownerPage.click('[data-testid="hard-delete-option"]'); - await ownerPage.fill('[data-testid="confirmation-text-input"]', 'DELETE'); + await ownerPage.click('[data-testid="hard-delete"]'); const deleteResponse = ownerPage.waitForResponse( '/api/v1/dataQuality/testSuites/*?hardDelete=true&recursive=true' ); diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/VersionPages/EntityVersionPages.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/VersionPages/EntityVersionPages.spec.ts index e9cee128890b..50ae4436f8df 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/VersionPages/EntityVersionPages.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/VersionPages/EntityVersionPages.spec.ts @@ -349,7 +349,6 @@ test.describe('Entity Version pages', () => { await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible(); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); const deleteResponse = page.waitForResponse( `/api/v1/${entity.endpoint}/async/*?hardDelete=false&recursive=true` ); diff --git a/openmetadata-ui/src/main/resources/ui/playwright/e2e/VersionPages/ServiceEntityVersionPage.spec.ts b/openmetadata-ui/src/main/resources/ui/playwright/e2e/VersionPages/ServiceEntityVersionPage.spec.ts index 833b4e4defa0..c13c8c6ceace 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/e2e/VersionPages/ServiceEntityVersionPage.spec.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/e2e/VersionPages/ServiceEntityVersionPage.spec.ts @@ -281,7 +281,6 @@ test.describe('Service Version pages', () => { await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible(); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); const deleteResponse = page.waitForResponse( `/api/v1/${entity.endpoint}/async/*?hardDelete=false&recursive=true` ); diff --git a/openmetadata-ui/src/main/resources/ui/playwright/utils/alert.ts b/openmetadata-ui/src/main/resources/ui/playwright/utils/alert.ts index 42394b59b4d5..dd3cb11eb26f 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/utils/alert.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/utils/alert.ts @@ -25,7 +25,6 @@ import { ALERT_WITH_PERMISSION_ROLE_NAME, } from '../constant/alert'; import { AlertDetails, EventDetails } from '../constant/alert.interface'; -import { DELETE_TERM } from '../constant/common'; import { Domain } from '../support/domain/Domain'; import { DashboardClass } from '../support/entity/DashboardClass'; import { TableClass } from '../support/entity/TableClass'; @@ -200,12 +199,6 @@ export const deleteAlertSteps = async ( ) => { await page.getByTestId(`alert-delete-${name}`).click(); - await expect(page.locator('.ant-modal-header')).toHaveText( - `Delete subscription "${displayName}"` - ); - - await page.fill('[data-testid="confirmation-text-input"]', DELETE_TERM); - const deleteAlert = page.waitForResponse( (response) => response.request().method() === 'DELETE' && response.status() === 200 diff --git a/openmetadata-ui/src/main/resources/ui/playwright/utils/asyncDelete.ts b/openmetadata-ui/src/main/resources/ui/playwright/utils/asyncDelete.ts index 788db0ca0776..af0fe66626ad 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/utils/asyncDelete.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/utils/asyncDelete.ts @@ -129,7 +129,6 @@ export const openDeleteModal = async (page: Page) => { * Fills the DELETE confirmation and clicks confirm button. */ export const confirmDelete = async (page: Page) => { - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); await page.click('[data-testid="confirm-button"]'); }; diff --git a/openmetadata-ui/src/main/resources/ui/playwright/utils/bot.ts b/openmetadata-ui/src/main/resources/ui/playwright/utils/bot.ts index 29f34b46573b..c28861d1872b 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/utils/bot.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/utils/bot.ts @@ -135,9 +135,7 @@ export const deleteBot = async (page: Page) => { // Click on delete button await page.getByTestId(`bot-delete-${botName}`).click(); - await page.getByTestId('hard-delete-option').click(); - - await page.getByTestId('confirmation-text-input').fill('DELETE'); + await page.getByTestId('hard-delete').click(); const deleteResponse = page.waitForResponse(`/api/v1/bots/*`); diff --git a/openmetadata-ui/src/main/resources/ui/playwright/utils/customMetric.ts b/openmetadata-ui/src/main/resources/ui/playwright/utils/customMetric.ts index 8b042db83b2d..2579784902f2 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/utils/customMetric.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/utils/customMetric.ts @@ -147,9 +147,6 @@ export const deleteCustomMetric = async ({ await page.click(`[data-testid="${metric.name}-custom-metrics-menu"]`); await page.getByRole('menuitemradio', { name: 'Delete' }).click(); - await expect(page.locator('.ant-modal-header')).toContainText(metric.name); - - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); const deleteMetricResponse = page.waitForResponse( isColumnMetric ? `/api/v1/tables/*/customMetric/${metric.column}/${metric.name}*` diff --git a/openmetadata-ui/src/main/resources/ui/playwright/utils/entity.ts b/openmetadata-ui/src/main/resources/ui/playwright/utils/entity.ts index 0e8fe9baf521..35b71f6a1547 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/utils/entity.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/utils/entity.ts @@ -2127,12 +2127,8 @@ export const softDeleteEntity = async ( await page.click('[data-testid="manage-button"]'); await page.click('[data-testid="delete-button"]'); - await page.locator('[role="dialog"].ant-modal').waitFor(); + await page.getByTestId('delete-modal').waitFor(); - await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible(); - await expect(page.locator('.ant-modal-title')).toContainText(displayName); - - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); const deleteResponse = page.waitForResponse( `/api/v1/${endPoint}/async/*?hardDelete=false&recursive=true` ); @@ -2220,17 +2216,9 @@ export const hardDeleteEntity = async ( await page.getByTestId('delete-button').waitFor(); await page.click('[data-testid="delete-button"]'); - await page.locator('[role="dialog"].ant-modal').waitFor(); - - await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible(); + await page.getByTestId('delete-modal').waitFor(); - await expect( - page.locator('[data-testid="delete-modal"] .ant-modal-title') - ).toHaveText(new RegExp(entityName)); - - await page.click('[data-testid="hard-delete-option"]'); - await page.check('[data-testid="hard-delete"]'); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); + await page.click('[data-testid="hard-delete"]'); const deleteResponse = page.waitForResponse( `/api/v1/${endPoint}/async/*?hardDelete=true&recursive=true` ); @@ -2620,3 +2608,17 @@ export const validateCopiedLinkFormat = ({ isValid: true, }; }; + +/** + * Types the DELETE confirmation only when the delete modal renders a + * confirmation text input. The radio-based DeleteEntityModal has no input, + * while the simple EntityDeleteModal still requires typing DELETE, so this + * guard keeps both flows working. + */ +export const fillDeleteConfirmationIfPresent = async (page: Page) => { + await page.getByTestId('confirm-button').waitFor({ state: 'visible' }); + const confirmInput = page.getByTestId('confirmation-text-input'); + if (await confirmInput.isVisible()) { + await confirmInput.fill('DELETE'); + } +}; diff --git a/openmetadata-ui/src/main/resources/ui/playwright/utils/glossary.ts b/openmetadata-ui/src/main/resources/ui/playwright/utils/glossary.ts index ee3389dcd38e..a544e9772002 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/utils/glossary.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/utils/glossary.ts @@ -1129,8 +1129,6 @@ export const deleteGlossaryOrGlossaryTerm = async ( entityName ); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); - const endpoint = isGlossaryTerm ? '/api/v1/glossaryTerms/async/*' : '/api/v1/glossaries/async/*'; diff --git a/openmetadata-ui/src/main/resources/ui/playwright/utils/serviceIngestion.ts b/openmetadata-ui/src/main/resources/ui/playwright/utils/serviceIngestion.ts index 8e507a590114..fed07087cb07 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/utils/serviceIngestion.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/utils/serviceIngestion.ts @@ -94,11 +94,8 @@ export const deleteService = async ( await page.locator('[data-menu-id*="delete-button"]').waitFor(); await page.click('[data-testid="delete-button-title"]'); - // Clicking on permanent delete radio button and checking the service name - await page.click('[data-testid="hard-delete-option"]'); - await page.click(`[data-testid="hard-delete-option"] >> text=${serviceName}`); - - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); + // Clicking on permanent delete radio button + await page.click('[data-testid="hard-delete"]'); const deleteResponse = page.waitForResponse((response) => response diff --git a/openmetadata-ui/src/main/resources/ui/playwright/utils/team.ts b/openmetadata-ui/src/main/resources/ui/playwright/utils/team.ts index e663ce55305d..1b41a9412823 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/utils/team.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/utils/team.ts @@ -119,12 +119,7 @@ export const softDeleteTeam = async (page: Page) => { .click(); await page.getByTestId('delete-button').click(); - await page.waitForLoadState('domcontentloaded'); - - await expect(page.getByTestId('confirmation-text-input')).toBeVisible(); - - await page.click('[data-testid="soft-delete-option"]'); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); + await page.getByTestId('delete-modal').waitFor(); const deleteResponse = page.waitForResponse( '/api/v1/teams/*?hardDelete=false&recursive=true' @@ -143,13 +138,9 @@ export const hardDeleteTeam = async (page: Page, teamName: string) => { .click(); await page.getByTestId('delete-button').click(); - await page.locator('[role="dialog"].ant-modal').waitFor(); - - await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible(); + await page.getByTestId('delete-modal').waitFor(); - await page.click('[data-testid="hard-delete-option"]'); - await page.check('[data-testid="hard-delete"]'); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); + await page.click('[data-testid="hard-delete"]'); const deleteResponse = page.waitForResponse( '/api/v1/teams/*?hardDelete=true&recursive=true' diff --git a/openmetadata-ui/src/main/resources/ui/playwright/utils/testCases.ts b/openmetadata-ui/src/main/resources/ui/playwright/utils/testCases.ts index 29e9fc13a3a2..1c725c5c20fa 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/utils/testCases.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/utils/testCases.ts @@ -186,10 +186,10 @@ export const waitForTestSuiteIngestionPipelinesListResponse = (page: Page) => }); export const confirmIngestionPipelineHardDelete = async (page: Page) => { - await page.getByTestId('confirmation-text-input').fill('DELETE'); const deleteResponse = page.waitForResponse( '/api/v1/services/ingestionPipelines/*?hardDelete=true' ); + await page.getByTestId('confirmation-text-input').fill('DELETE'); await page.getByTestId('confirm-button').click(); await deleteResponse; }; diff --git a/openmetadata-ui/src/main/resources/ui/playwright/utils/user.ts b/openmetadata-ui/src/main/resources/ui/playwright/utils/user.ts index 33f9c781819a..22833ca780bc 100644 --- a/openmetadata-ui/src/main/resources/ui/playwright/utils/user.ts +++ b/openmetadata-ui/src/main/resources/ui/playwright/utils/user.ts @@ -186,12 +186,7 @@ export const softDeleteUserProfilePage = async ( await page.getByText('Delete Profile').click(); - await page.locator('[role="dialog"].ant-modal').waitFor(); - - await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible(); - await expect(page.locator('.ant-modal-title')).toContainText(displayName); - - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); + await page.getByTestId('delete-modal').waitFor(); const deleteResponse = page.waitForResponse( '/api/v1/users/*?hardDelete=false&recursive=true' @@ -234,14 +229,9 @@ export const hardDeleteUserProfilePage = async ( ) => { await page.getByTestId('user-profile-manage-btn').click(); await page.getByText('Delete Profile').click(); - await page.locator('[role="dialog"].ant-modal').waitFor(); + await page.getByTestId('delete-modal').waitFor(); - await expect(page.locator('[role="dialog"].ant-modal')).toBeVisible(); - await expect(page.locator('.ant-modal-title')).toContainText(displayName); - - await page.click('[data-testid="hard-delete-option"]'); - await page.check('[data-testid="hard-delete"]'); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); + await page.click('[data-testid="hard-delete"]'); const deleteResponse = page.waitForResponse( '/api/v1/users/*?hardDelete=true&recursive=true' @@ -371,7 +361,6 @@ export const softDeleteUser = async ( await page.click(`[data-testid="delete-user-btn-${username}"]`); // Soft deleting the user await page.click('[data-testid="soft-delete"]'); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); const fetchUpdatedUsers = page.waitForResponse('/api/v1/users/*'); const deleteResponse = page.waitForResponse( @@ -467,18 +456,10 @@ export const permanentDeleteUser = async ( // Click on delete user button await page.click(`[data-testid="delete-user-btn-${username}"]`); - if (!isUserSoftDeleted) { - // Modal opens with soft-delete as default; wait for the form's - // initialization effect before switching, otherwise the click races - // with setFieldsValue and the selection gets clobbered. - await page - .locator('.ant-radio-wrapper-checked [data-testid="soft-delete"]') - .waitFor(); - } + await page.getByTestId('delete-modal').waitFor(); // Click on hard delete await page.click('[data-testid="hard-delete"]'); - await page.fill('[data-testid="confirmation-text-input"]', 'DELETE'); const reFetchUsers = page.waitForResponse( '/api/v1/users?**include=non-deleted' diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Database/Profiler/DataQualityTab/DataQualityTab.test.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Database/Profiler/DataQualityTab/DataQualityTab.test.tsx index d9f6d9d184a2..1b0dda9163a2 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Database/Profiler/DataQualityTab/DataQualityTab.test.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Database/Profiler/DataQualityTab/DataQualityTab.test.tsx @@ -330,11 +330,11 @@ jest.mock('../../../common/Loader/Loader', () => jest.fn().mockImplementation(() => Loader) ); -jest.mock('../../../common/DeleteWidget/DeleteWidgetModal', () => +jest.mock('../../../common/DeleteWidget/DeleteEntityModal', () => jest.fn().mockImplementation(({ visible, onCancel }) => visible ? (
-

DeleteWidgetModal

+

DeleteEntityModal

) : null diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Database/Profiler/DataQualityTab/DataQualityTab.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Database/Profiler/DataQualityTab/DataQualityTab.tsx index 9c267b72496b..0a11702d3b64 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Database/Profiler/DataQualityTab/DataQualityTab.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Database/Profiler/DataQualityTab/DataQualityTab.tsx @@ -57,7 +57,7 @@ import { getEntityDetailsPath } from '../../../../utils/RouterUtils'; import { replacePlus } from '../../../../utils/StringUtils'; import { showErrorToast } from '../../../../utils/ToastUtils'; import DateTimeDisplay from '../../../common/DateTimeDisplay/DateTimeDisplay'; -import DeleteWidgetModal from '../../../common/DeleteWidget/DeleteWidgetModal'; +import DeleteEntityModal from '../../../common/DeleteWidget/DeleteEntityModal'; import FilterTablePlaceHolder from '../../../common/ErrorWithPlaceholder/FilterTablePlaceHolder'; import NextPrevious from '../../../common/NextPrevious/NextPrevious'; import StatusBadge from '../../../common/StatusBadge/StatusBadge.component'; @@ -891,7 +891,7 @@ const DataQualityTab: React.FC = ({ onConfirm={handleConfirmClick} /> ) : ( - ); })} - { return jest.fn().mockImplementation(() =>
ProfilerLatestValue
); }); -jest.mock('../../../../common/DeleteWidget/DeleteWidgetModal', () => { - return jest.fn().mockImplementation(() =>
DeleteWidgetModal
); +jest.mock('../../../../common/DeleteWidget/DeleteEntityModal', () => { + return jest.fn().mockImplementation(() =>
DeleteEntityModal
); }); jest.mock('../../../../common/ErrorWithPlaceholder/ErrorPlaceHolder', () => { return jest.fn().mockImplementation(() =>
ErrorPlaceHolder
); diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Domain/DomainDetails/DomainDetails.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Domain/DomainDetails/DomainDetails.component.tsx index a37970d11338..f1e821faaa09 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Domain/DomainDetails/DomainDetails.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Domain/DomainDetails/DomainDetails.component.tsx @@ -112,7 +112,7 @@ import { import { withActivityFeed } from '../../AppRouter/withActivityFeed'; import { useFormDrawerWithHook } from '../../common/atoms/drawer'; import { CoverImage } from '../../common/CoverImage/CoverImage.component'; -import DeleteWidgetModal from '../../common/DeleteWidget/DeleteWidgetModal'; +import DeleteEntityModal from '../../common/DeleteWidget/DeleteEntityModal'; import AnnouncementCard from '../../common/EntityPageInfos/AnnouncementCard/AnnouncementCard'; import AnnouncementDrawer from '../../common/EntityPageInfos/AnnouncementDrawer/AnnouncementDrawer'; import HeaderBreadcrumb from '../../common/HeaderBreadcrumb/HeaderBreadcrumb.component'; @@ -1103,7 +1103,7 @@ const DomainDetails = ({ /> {domain && ( - onDelete(domain.id)} allowSoftDelete={false} entityId={domain.id} diff --git a/openmetadata-ui/src/main/resources/ui/src/components/ProfileCard/ProfileSectionUserDetailsCard.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/ProfileCard/ProfileSectionUserDetailsCard.component.tsx index fcfa6941ea2d..a8186ecdbdc4 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/ProfileCard/ProfileSectionUserDetailsCard.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/ProfileCard/ProfileSectionUserDetailsCard.component.tsx @@ -34,7 +34,7 @@ import { changePassword } from '../../rest/auth-API'; import { getEntityName } from '../../utils/EntityNameUtils'; import { showErrorToast, showSuccessToast } from '../../utils/ToastUtils'; import { getUserOnlineStatus, isMaskedEmail } from '../../utils/UsersPureUtils'; -import DeleteWidgetModal from '../common/DeleteWidget/DeleteWidgetModal'; +import DeleteEntityModal from '../common/DeleteWidget/DeleteEntityModal'; import UserPopOverCard from '../common/PopOverCard/UserPopOverCard'; import ProfilePicture from '../common/ProfilePicture/ProfilePicture'; import { ProfileEditModal } from '../Modals/ProfileEditModal/ProfileEditModal'; @@ -280,7 +280,7 @@ const ProfileSectionUserDetailsCard = ({ )} {isDelete && ( - - ({ + deleteEntity: jest.fn().mockImplementation(() => + Promise.resolve({ + status: 200, + data: { version: 1 }, + }) + ), +})); + +jest.mock('../../../hooks/useApplicationStore', () => ({ + useApplicationStore: jest.fn(() => ({ + currentUser: mockUserData, + })), +})); + +jest.mock('../../Auth/AuthProviders/AuthProvider', () => ({ + useAuthProvider: jest.fn().mockImplementation(() => ({ + onLogoutHandler: mockOnLogoutHandler, + })), +})); + +jest.mock('../../../utils/ToastUtils', () => ({ + showErrorToast: jest.fn(), + showSuccessToast: jest.fn(), +})); + +jest.mock('../../../utils/i18next/LocalUtil', () => ({ + Transi18next: ({ children }: { children: ReactNode }) => children, + t: jest.fn().mockImplementation((key: string) => key), +})); + +describe('DeleteEntityModal', () => { + beforeEach(() => { + jest.clearAllMocks(); + }); + + it('should render header, both options and action buttons without a text input', async () => { + render(); + + expect(await screen.findByTestId('delete-modal')).toBeInTheDocument(); + expect(await screen.findByTestId('modal-header')).toBeInTheDocument(); + expect(await screen.findByTestId('soft-delete')).toBeInTheDocument(); + expect(await screen.findByTestId('hard-delete')).toBeInTheDocument(); + expect(await screen.findByTestId('discard-button')).toBeInTheDocument(); + expect(await screen.findByTestId('confirm-button')).toBeInTheDocument(); + expect( + screen.queryByTestId('confirmation-text-input') + ).not.toBeInTheDocument(); + }); + + it('should confirm without requiring typed confirmation', async () => { + render(); + + const confirmButton = await screen.findByTestId('confirm-button'); + + expect(confirmButton).not.toBeDisabled(); + + await act(async () => { + fireEvent.click(confirmButton); + }); + + expect(deleteEntity).toHaveBeenCalled(); + }); + + it('should call onCancel when discard is clicked', async () => { + render(); + + fireEvent.click(await screen.findByTestId('discard-button')); + + expect(mockProps.onCancel).toHaveBeenCalled(); + }); + + it('should not logout when deleting a different user', async () => { + render(); + + fireEvent.click(await screen.findByTestId('hard-delete')); + + await act(async () => { + fireEvent.click(screen.getByTestId('confirm-button')); + }); + + expect(mockOnLogoutHandler).not.toHaveBeenCalled(); + }); + + it('should logout when deleting the current user', async () => { + render(); + + fireEvent.click(await screen.findByTestId('hard-delete')); + + await act(async () => { + fireEvent.click(screen.getByTestId('confirm-button')); + }); + + expect(mockOnLogoutHandler).toHaveBeenCalled(); + }); +}); diff --git a/openmetadata-ui/src/main/resources/ui/src/components/common/DeleteWidget/DeleteEntityModal.tsx b/openmetadata-ui/src/main/resources/ui/src/components/common/DeleteWidget/DeleteEntityModal.tsx new file mode 100644 index 000000000000..6e7a23e98d9d --- /dev/null +++ b/openmetadata-ui/src/main/resources/ui/src/components/common/DeleteWidget/DeleteEntityModal.tsx @@ -0,0 +1,323 @@ +/* + * Copyright 2025 Collate. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { + Button, + Dialog, + FeaturedIcon, + Modal, + ModalOverlay, + RadioButton, + RadioGroup, + Typography, +} from '@openmetadata/ui-core-components'; +import { Trash01 } from '@untitledui/icons'; +import { AxiosError } from 'axios'; +import classNames from 'classnames'; +import { startCase } from 'lodash'; +import { useCallback, useEffect, useMemo, useState } from 'react'; +import { useTranslation } from 'react-i18next'; +import { useAsyncDeleteProvider } from '../../../context/AsyncDeleteProvider/AsyncDeleteProvider'; +import { EntityType } from '../../../enums/entity.enum'; +import { useApplicationStore } from '../../../hooks/useApplicationStore'; +import { deleteEntity } from '../../../rest/miscAPI'; +import deleteWidgetClassBase from '../../../utils/DeleteWidget/DeleteWidgetClassBase'; +import { showErrorToast, showSuccessToast } from '../../../utils/ToastUtils'; +import { useAuthProvider } from '../../Auth/AuthProviders/AuthProvider'; +import { + DeleteType, + DeleteWidgetFormFields, + DeleteWidgetModalProps, +} from './DeleteWidget.interface'; + +const DeleteEntityModal = ({ + allowSoftDelete = true, + visible, + deleteMessage, + softDeleteMessagePostFix = '', + hardDeleteMessagePostFix = '', + entityName, + entityType, + onCancel, + entityId, + prepareType = true, + isAsyncDelete = false, + isRecursiveDelete, + afterDeleteAction, + successMessage, + deleteOptions, + onDelete, + isDeleting = false, +}: DeleteWidgetModalProps) => { + const { t } = useTranslation(); + const { currentUser } = useApplicationStore(); + const { onLogoutHandler } = useAuthProvider(); + const { handleOnAsyncEntityDeleteConfirm } = useAsyncDeleteProvider(); + const [deletionType, setDeletionType] = useState( + allowSoftDelete ? DeleteType.SOFT_DELETE : DeleteType.HARD_DELETE + ); + const [isLoading, setIsLoading] = useState(false); + const entityTypeName = useMemo(() => startCase(entityType), [entityType]); + + const DELETE_OPTION = useMemo( + () => [ + { + title: t('label.soft-delete'), + description: ( + <> + {t('message.soft-delete-common-message', { + entity: entityTypeName.toLowerCase(), + })} + {softDeleteMessagePostFix} + + ), + type: DeleteType.SOFT_DELETE, + isAllowed: allowSoftDelete, + }, + { + title: t('label.permanently-delete'), + description: ( + <> + {deleteMessage ?? + t('message.permanently-delete-common-message', { + entity: entityTypeName.toLowerCase(), + })} + {hardDeleteMessagePostFix} + + ), + type: DeleteType.HARD_DELETE, + isAllowed: true, + }, + ], + [ + t, + entityTypeName, + softDeleteMessagePostFix, + allowSoftDelete, + deleteMessage, + hardDeleteMessagePostFix, + ] + ); + + const options = useMemo( + () => (deleteOptions ?? DELETE_OPTION).filter((option) => option.isAllowed), + [deleteOptions, DELETE_OPTION] + ); + + const handleOnEntityDeleteCancel = useCallback(() => { + setDeletionType( + allowSoftDelete ? DeleteType.SOFT_DELETE : DeleteType.HARD_DELETE + ); + onCancel(); + }, [onCancel, allowSoftDelete]); + + const handleOnEntityDeleteConfirm = useCallback( + async ({ deleteType }: DeleteWidgetFormFields) => { + try { + setIsLoading(true); + const response = await deleteEntity( + prepareType + ? deleteWidgetClassBase.prepareEntityType(entityType) + : entityType, + entityId ?? '', + Boolean(isRecursiveDelete), + deleteType === DeleteType.HARD_DELETE + ); + if (response.status === 200) { + showSuccessToast( + successMessage ?? + t('server.entity-deleted-successfully', { + entity: entityName, + }) + ); + + if (entityType === EntityType.USER && entityId === currentUser?.id) { + onLogoutHandler(); + + return; + } + if (afterDeleteAction) { + afterDeleteAction( + deletionType === DeleteType.SOFT_DELETE, + response.data.version + ); + } + } else { + showErrorToast(t('server.unexpected-response')); + } + } catch (error) { + showErrorToast( + error as AxiosError, + t('server.delete-entity-error', { + entity: entityName, + }) + ); + } finally { + handleOnEntityDeleteCancel(); + setIsLoading(false); + } + }, + [ + entityType, + entityId, + isRecursiveDelete, + deletionType, + afterDeleteAction, + entityName, + handleOnEntityDeleteCancel, + currentUser?.id, + ] + ); + + const onConfirm = useCallback(async () => { + const values: DeleteWidgetFormFields = { + deleteType: deletionType, + deleteTextInput: '', + }; + if (isAsyncDelete) { + setIsLoading(true); + try { + await handleOnAsyncEntityDeleteConfirm({ + entityName, + entityId: entityId ?? '', + entityType, + deleteType: deletionType, + prepareType, + isRecursiveDelete: isRecursiveDelete ?? false, + afterDeleteAction, + }); + } finally { + setIsLoading(false); + handleOnEntityDeleteCancel(); + } + } else { + onDelete ? onDelete(values) : handleOnEntityDeleteConfirm(values); + } + }, [ + deletionType, + isAsyncDelete, + entityId, + onDelete, + entityName, + entityType, + prepareType, + isRecursiveDelete, + handleOnAsyncEntityDeleteConfirm, + handleOnEntityDeleteConfirm, + handleOnEntityDeleteCancel, + afterDeleteAction, + ]); + + useEffect(() => { + setDeletionType( + allowSoftDelete ? DeleteType.SOFT_DELETE : DeleteType.HARD_DELETE + ); + }, [allowSoftDelete, visible]); + + useEffect(() => { + setIsLoading(isDeleting); + }, [isDeleting]); + + return ( + + !isOpen && !isLoading && handleOnEntityDeleteCancel() + }> + + + + + + {t('label.delete')} "{entityName}" {entityTypeName} + + + + setDeletionType(value as DeleteType)}> + {options.map((option) => ( + + classNames( + 'tw:cursor-pointer tw:rounded-xl tw:border tw:p-4 tw:transition-colors', + isSelected + ? 'tw:border-brand tw:ring-1 tw:ring-brand' + : 'tw:border-secondary' + ) + } + data-testid={option.type} + hint={ + + {option.description} + + } + key={option.type} + label={ + + {option.title} + + } + size="md" + value={option.type} + /> + ))} + + +
+ + +
+
+
+
+ ); +}; + +export default DeleteEntityModal; diff --git a/openmetadata-ui/src/main/resources/ui/src/components/common/DeleteWidget/DeleteWidgetModal.test.tsx b/openmetadata-ui/src/main/resources/ui/src/components/common/DeleteWidget/DeleteWidgetModal.test.tsx deleted file mode 100644 index 07b8eb24d1e0..000000000000 --- a/openmetadata-ui/src/main/resources/ui/src/components/common/DeleteWidget/DeleteWidgetModal.test.tsx +++ /dev/null @@ -1,170 +0,0 @@ -/* - * Copyright 2022 Collate. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * http://www.apache.org/licenses/LICENSE-2.0 - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { act, fireEvent, render, screen } from '@testing-library/react'; -import userEvent from '@testing-library/user-event'; -import { ReactNode } from 'react'; -import { EntityType } from '../../../enums/entity.enum'; -import { mockUserData } from '../../../mocks/MyDataPage.mock'; -import { DeleteWidgetModalProps } from './DeleteWidget.interface'; -import DeleteWidgetModal from './DeleteWidgetModal'; - -const mockProps: DeleteWidgetModalProps = { - visible: true, - onCancel: jest.fn(), - entityName: 'entityName', - entityType: EntityType.TABLE, - entityId: 'entityId', -}; - -const mockPropsUser: DeleteWidgetModalProps = { - visible: true, - onCancel: jest.fn(), - entityName: 'entityName', - entityType: EntityType.USER, - entityId: mockUserData.id, -}; - -const mockOnLogoutHandler = jest.fn(); - -jest.mock('../../../rest/miscAPI', () => ({ - deleteEntity: jest.fn().mockImplementation(() => - Promise.resolve({ - status: 200, - }) - ), -})); - -jest.mock('../../../hooks/useApplicationStore', () => ({ - useApplicationStore: jest.fn(() => ({ - currentUser: mockUserData, - })), -})); - -jest.mock('../../Auth/AuthProviders/AuthProvider', () => ({ - useAuthProvider: jest.fn().mockImplementation(() => ({ - onLogoutHandler: mockOnLogoutHandler, - })), -})); - -jest.mock('../../../utils/ToastUtils', () => ({ - showSuccessToast: jest.fn(), -})); - -jest.mock('../../../utils/i18next/LocalUtil', () => ({ - Transi18next: ({ children }: { children: ReactNode }) => children, - t: jest.fn().mockImplementation((key: string) => key), -})); - -describe('Test DeleteWidgetV1 Component', () => { - it('Component should render properly', async () => { - render(); - - const deleteModal = await screen.findByTestId('delete-modal'); - const footer = await screen.findByTestId('footer'); - const discardButton = await screen.findByTestId('discard-button'); - const confirmButton = await screen.findByTestId('confirm-button'); - const softDelete = await screen.findByTestId('soft-delete'); - const hardDelete = await screen.findByTestId('hard-delete'); - const inputBox = await screen.findByTestId('confirmation-text-input'); - - expect(deleteModal).toBeInTheDocument(); - expect(footer).toBeInTheDocument(); - expect(discardButton).toBeInTheDocument(); - expect(confirmButton).toBeInTheDocument(); - expect(softDelete).toBeInTheDocument(); - expect(hardDelete).toBeInTheDocument(); - expect(inputBox).toBeInTheDocument(); - }); - - it('Delete click should work properly', async () => { - render(); - - const inputBox = await screen.findByTestId('confirmation-text-input'); - const confirmButton = await screen.findByTestId('confirm-button'); - const hardDelete = await screen.findByTestId('hard-delete'); - - fireEvent.click(hardDelete); - - fireEvent.change(inputBox, { target: { value: 'DELETE' } }); - - expect(confirmButton).not.toBeDisabled(); - - fireEvent.click(confirmButton); - }); - - it('Delete click should work properly regardless of capitalization', async () => { - render(); - - const inputBox = await screen.findByTestId('confirmation-text-input'); - const confirmButton = await screen.findByTestId('confirm-button'); - const hardDelete = await screen.findByTestId('hard-delete'); - - fireEvent.click(hardDelete); - - fireEvent.change(inputBox, { target: { value: 'delete' } }); - - expect(confirmButton).not.toBeDisabled(); - - userEvent.click(confirmButton); - }); - - it('Discard click should work properly', async () => { - render(); - const discardButton = await screen.findByTestId('discard-button'); - - fireEvent.click(discardButton); - - expect(mockProps.onCancel).toHaveBeenCalled(); - }); - - it('onLogoutHandler should not be called if entityType is user and EntityId and CurrentUser id is different', async () => { - render(); - - const confirmButton = screen.getByTestId('confirm-button'); - - fireEvent.click(screen.getByTestId('hard-delete')); - - fireEvent.change(screen.getByTestId('confirmation-text-input'), { - target: { value: 'DELETE' }, - }); - - expect(confirmButton).not.toBeDisabled(); - - await act(async () => { - fireEvent.click(confirmButton); - }); - - expect(mockOnLogoutHandler).not.toHaveBeenCalled(); - }); - - it('onLogoutHandler should be called if entityType is user and EntityId and CurrentUser id is same', async () => { - render(); - - const confirmButton = screen.getByTestId('confirm-button'); - - fireEvent.click(screen.getByTestId('hard-delete')); - - fireEvent.change(screen.getByTestId('confirmation-text-input'), { - target: { value: 'DELETE' }, - }); - - expect(confirmButton).not.toBeDisabled(); - - await act(async () => { - fireEvent.click(confirmButton); - }); - - expect(mockOnLogoutHandler).toHaveBeenCalled(); - }); -}); diff --git a/openmetadata-ui/src/main/resources/ui/src/components/common/DeleteWidget/DeleteWidgetModal.tsx b/openmetadata-ui/src/main/resources/ui/src/components/common/DeleteWidget/DeleteWidgetModal.tsx deleted file mode 100644 index 4c7545304bbe..000000000000 --- a/openmetadata-ui/src/main/resources/ui/src/components/common/DeleteWidget/DeleteWidgetModal.tsx +++ /dev/null @@ -1,391 +0,0 @@ -/* - * Copyright 2022 Collate. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * http://www.apache.org/licenses/LICENSE-2.0 - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -import { - Button, - Form, - Modal, - Radio, - RadioChangeEvent, - Space, - Typography, -} from 'antd'; -import Input, { InputRef } from 'antd/lib/input/Input'; -import { AxiosError } from 'axios'; -import { startCase } from 'lodash'; -import { - ChangeEvent, - useCallback, - useEffect, - useMemo, - useRef, - useState, -} from 'react'; -import { useTranslation } from 'react-i18next'; -import { useAsyncDeleteProvider } from '../../../context/AsyncDeleteProvider/AsyncDeleteProvider'; -import { EntityType } from '../../../enums/entity.enum'; -import { useApplicationStore } from '../../../hooks/useApplicationStore'; -import { deleteEntity } from '../../../rest/miscAPI'; -import deleteWidgetClassBase from '../../../utils/DeleteWidget/DeleteWidgetClassBase'; -import { Transi18next } from '../../../utils/i18next/LocalUtil'; -import { showErrorToast, showSuccessToast } from '../../../utils/ToastUtils'; -import { useAuthProvider } from '../../Auth/AuthProviders/AuthProvider'; -import './delete-widget-modal.style.less'; -import { - DeleteType, - DeleteWidgetFormFields, - DeleteWidgetModalProps, -} from './DeleteWidget.interface'; - -export const DELETE_CONFIRMATION_TEXT = 'DELETE'; - -const DeleteWidgetModal = ({ - allowSoftDelete = true, - visible, - deleteMessage, - softDeleteMessagePostFix = '', - hardDeleteMessagePostFix = '', - entityName, - entityType, - onCancel, - entityId, - prepareType = true, - isAsyncDelete = false, - isRecursiveDelete, - afterDeleteAction, - successMessage, - deleteOptions, - onDelete, - isDeleting = false, -}: DeleteWidgetModalProps) => { - const { t } = useTranslation(); - const [form] = Form.useForm(); - const { currentUser } = useApplicationStore(); - const { onLogoutHandler } = useAuthProvider(); - const { handleOnAsyncEntityDeleteConfirm } = useAsyncDeleteProvider(); - const [deleteConfirmationText, setDeleteConfirmationText] = - useState(''); - const [deletionType, setDeletionType] = useState( - allowSoftDelete ? DeleteType.SOFT_DELETE : DeleteType.HARD_DELETE - ); - const [isLoading, setIsLoading] = useState(false); - const deleteTextInputRef = useRef(null); - const entityTypeName = useMemo(() => { - return startCase(entityType); - }, [entityType]); - - const DELETE_OPTION = useMemo( - () => [ - { - title: `${t('label.delete')} ${entityTypeName} "${entityName}"`, - description: ( - <> - {deleteWidgetClassBase.getDeleteMessage( - entityName, - entityType, - true - )} - {softDeleteMessagePostFix} - - ), - type: DeleteType.SOFT_DELETE, - isAllowed: allowSoftDelete, - }, - { - title: `${t( - 'label.permanently-delete' - )} ${entityTypeName} "${entityName}"`, - description: ( - <> - {deleteMessage ?? - deleteWidgetClassBase.getDeleteMessage(entityName, entityType)} - {hardDeleteMessagePostFix} - - ), - type: DeleteType.HARD_DELETE, - isAllowed: true, - }, - ], - [ - entityType, - entityName, - softDeleteMessagePostFix, - allowSoftDelete, - deleteMessage, - hardDeleteMessagePostFix, - ] - ); - - const handleOnChange = useCallback((e: ChangeEvent) => { - setDeleteConfirmationText(e.target.value); - }, []); - - const handleOnEntityDeleteCancel = useCallback(() => { - setDeleteConfirmationText(''); - setDeletionType( - allowSoftDelete ? DeleteType.SOFT_DELETE : DeleteType.HARD_DELETE - ); - onCancel(); - }, [onCancel, allowSoftDelete]); - - const isDeleteTextPresent = useMemo(() => { - return ( - deleteConfirmationText.toLowerCase() === - DELETE_CONFIRMATION_TEXT.toLowerCase() && - (deletionType === DeleteType.SOFT_DELETE || - deletionType === DeleteType.HARD_DELETE) - ); - }, [deleteConfirmationText, deletionType]); - - const handleOnEntityDeleteConfirm = useCallback( - async ({ deleteType }: DeleteWidgetFormFields) => { - try { - setIsLoading(true); - const response = await deleteEntity( - prepareType - ? deleteWidgetClassBase.prepareEntityType(entityType) - : entityType, - entityId ?? '', - Boolean(isRecursiveDelete), - deleteType === DeleteType.HARD_DELETE - ); - if (response.status === 200) { - showSuccessToast( - successMessage ?? - t('server.entity-deleted-successfully', { - entity: entityName, - }) - ); - - if (entityType === EntityType.USER && entityId === currentUser?.id) { - onLogoutHandler(); - - return; - } - if (afterDeleteAction) { - afterDeleteAction( - deletionType === DeleteType.SOFT_DELETE, - response.data.version - ); - } - } else { - showErrorToast(t('server.unexpected-response')); - } - } catch (error) { - showErrorToast( - error as AxiosError, - t('server.delete-entity-error', { - entity: entityName, - }) - ); - } finally { - if (isDeleteTextPresent) { - handleOnEntityDeleteCancel(); - } - setIsLoading(false); - } - }, - [ - entityType, - entityId, - isRecursiveDelete, - deletionType, - afterDeleteAction, - entityName, - handleOnEntityDeleteCancel, - isDeleteTextPresent, - currentUser?.id, - ] - ); - - const onFormFinish = useCallback( - async (values: DeleteWidgetFormFields) => { - if (isAsyncDelete) { - setIsLoading(true); - await handleOnAsyncEntityDeleteConfirm({ - entityName, - entityId: entityId ?? '', - entityType, - deleteType: values.deleteType, - prepareType, - isRecursiveDelete: isRecursiveDelete ?? false, - afterDeleteAction, - }); - setIsLoading(false); - handleOnEntityDeleteCancel(); - } else { - onDelete ? onDelete(values) : handleOnEntityDeleteConfirm(values); - } - }, - [ - entityId, - onDelete, - entityName, - entityType, - prepareType, - isRecursiveDelete, - handleOnEntityDeleteConfirm, - handleOnEntityDeleteCancel, - afterDeleteAction, - ] - ); - - const onChange = useCallback((e: RadioChangeEvent) => { - const value = e.target.value; - setDeletionType(value); - }, []); - - useEffect(() => { - let timeout: number; - - if (visible) { - // using setTimeout here as directly calling focus() doesn't focus element after first time - timeout = window.setTimeout(() => { - deleteTextInputRef.current?.focus(); - }, 1); - } - - return () => { - clearTimeout(timeout); - }; - }, [visible, deleteTextInputRef]); - - useEffect(() => { - setDeletionType( - allowSoftDelete ? DeleteType.SOFT_DELETE : DeleteType.HARD_DELETE - ); - }, [allowSoftDelete]); - - const handleConfirmClick = useCallback(() => form.submit(), []); - - const footer = useMemo(() => { - return ( - - - - - - ); - }, [handleOnEntityDeleteCancel, isDeleteTextPresent, isLoading]); - - useEffect(() => { - // Resetting the form values on visibility change - // Using setFieldsValue instead of resetValue as the default value to be set - // is dynamic i.e. dependent on allowSoftDelete prop which sets it to undefined - // if reset using resetValue - form.setFieldsValue({ - deleteType: allowSoftDelete - ? DeleteType.SOFT_DELETE - : DeleteType.HARD_DELETE, - deleteTextInput: '', - }); - }, [visible]); - - useEffect(() => { - setIsLoading(isDeleting); - }, [isDeleting]); - - return ( - // Used Button to stop click propagation event in the - // TeamDetailsV1 and User.component collapsible panel. - - ); -}; - -export default DeleteWidgetModal; diff --git a/openmetadata-ui/src/main/resources/ui/src/components/common/DeleteWidget/delete-widget-modal.style.less b/openmetadata-ui/src/main/resources/ui/src/components/common/DeleteWidget/delete-widget-modal.style.less deleted file mode 100644 index acfea73a4b46..000000000000 --- a/openmetadata-ui/src/main/resources/ui/src/components/common/DeleteWidget/delete-widget-modal.style.less +++ /dev/null @@ -1,19 +0,0 @@ -/* - * Copyright 2023 Collate. - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * http://www.apache.org/licenses/LICENSE-2.0 - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -.delete-widget-title { - font-weight: 500; - - &.ant-typography { - margin-bottom: 4px; - } -} diff --git a/openmetadata-ui/src/main/resources/ui/src/components/common/EntityPageInfos/ManageButton/ManageButton.test.tsx b/openmetadata-ui/src/main/resources/ui/src/components/common/EntityPageInfos/ManageButton/ManageButton.test.tsx index 414eeb588f1e..95b5fd84efa7 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/common/EntityPageInfos/ManageButton/ManageButton.test.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/common/EntityPageInfos/ManageButton/ManageButton.test.tsx @@ -19,8 +19,8 @@ jest.mock('../../../../utils/AnnouncementsUtils', () => ({ ANNOUNCEMENT_ENTITIES: ['table', 'topic', 'dashboard', 'pipeline'], })); -jest.mock('../../DeleteWidget/DeleteWidgetModal', () => { - return jest.fn().mockReturnValue(
DeleteWidgetModal
); +jest.mock('../../DeleteWidget/DeleteEntityModal', () => { + return jest.fn().mockReturnValue(
DeleteEntityModal
); }); const mockAnnouncementClick = jest.fn(); @@ -79,7 +79,7 @@ describe('Test manage button component', () => { fireEvent.click(deleteOption); - expect(await screen.findByText('DeleteWidgetModal')).toBeInTheDocument(); + expect(await screen.findByText('DeleteEntityModal')).toBeInTheDocument(); }); it('Should call announcement callback on click of announcement option', async () => { diff --git a/openmetadata-ui/src/main/resources/ui/src/components/common/EntityPageInfos/ManageButton/ManageButton.tsx b/openmetadata-ui/src/main/resources/ui/src/components/common/EntityPageInfos/ManageButton/ManageButton.tsx index 9f917dd8108d..f50780d79544 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/common/EntityPageInfos/ManageButton/ManageButton.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/common/EntityPageInfos/ManageButton/ManageButton.tsx @@ -32,7 +32,7 @@ import entityUtilClassBase from '../../../../utils/EntityUtilClassBase'; import { showErrorToast } from '../../../../utils/ToastUtils'; import EntityNameModal from '../../../Modals/EntityNameModal/EntityNameModal.component'; import { EntityName } from '../../../Modals/EntityNameModal/EntityNameModal.interface'; -import DeleteWidgetModal from '../../DeleteWidget/DeleteWidgetModal'; +import DeleteEntityModal from '../../DeleteWidget/DeleteEntityModal'; import { ManageButtonItemLabel } from '../../ManageButtonContentItem/ManageButtonContentItem.component'; import { ManageButtonProps } from './ManageButton.interface'; import './ManageButton.less'; @@ -305,7 +305,7 @@ const ManageButton: FC = ({ <> {items.length ? renderDropdownTrigger() : null} {isDelete && ( - {{entityName}} إلى فقدان تكوين المسار (pipeline)، ولا يمكن استعادته.", "permanently-delete-metadata": "سيؤدي الحذف الدائم لـ <0>{{entityName}} إلى إزالة بياناته الوصفية من {{brandName}}، ولا يمكن استعادته.", "permanently-delete-metadata-and-dependents": "سيؤدي الحذف الدائم لـ {{entityName}} إلى إزالة بياناته الوصفية، وكذلك البيانات الوصفية لـ {{dependents}} من {{brandName}} بشكل دائم.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "تطور حجم الأصول في المنظمة.", "smart-sampling-hint": "يُحسِّن الموارد بناءً على حجم البيانات", "soft-delete-archive-message": "سيؤدي هذا الإجراء إلى تعطيل الوصول إلى {{entity}}. يمكنك استعادته لاحقًا من الأرشيف.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "سيؤدي الحذف الناعم (Soft deleting) إلى إلغاء تنشيط {{entity}}. سيؤدي هذا إلى تعطيل أي عمليات اكتشاف أو قراءة أو كتابة على {{entity}}.", "soft-delete-message-for-n-entities": "سيؤدي الحذف الناعم إلى إلغاء تنشيط {{count}} {{entity}}. سيؤدي هذا إلى تعطيل أي عمليات اكتشاف أو قراءة أو كتابة عليها.", "something-went-wrong": "حدث خطأ ما", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/de-de.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/de-de.json index 7e8fbaef449b..2e0585de3257 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/de-de.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/de-de.json @@ -3638,6 +3638,7 @@ "password-error-message": "Das Passwort muss mindestens 8 und maximal 56 Zeichen lang sein und mindestens einen Großbuchstaben (A-Z), einen Kleinbuchstaben (a-z), eine Zahl und ein Sonderzeichen (z. B. !, %, @ oder #) enthalten.", "password-pattern-error": "Das Passwort muss mindestens 8 und maximal 56 Zeichen lang sein und mindestens einen Sonderbuchstaben, einen Großbuchstaben und einen Kleinbuchstaben enthalten.", "path-of-the-dbt-files-stored": "Pfad zum Ordner, in dem die dbt-Dateien gespeichert sind", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "Das dauerhafte Löschen von <0>{{entityName}} führt zum Verlust der Pipeline-Konfiguration und kann nicht wiederhergestellt werden.", "permanently-delete-metadata": "Das dauerhafte Löschen dieses <0>{{entityName}} entfernt seine Metadaten dauerhaft aus {{brandName}}.", "permanently-delete-metadata-and-dependents": "Das dauerhafte Löschen dieses {{entityName}} entfernt seine Metadaten sowie die Metadaten von {{dependents}} dauerhaft aus {{brandName}}.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "Größenentwicklung der Assets in der Organisation.", "smart-sampling-hint": "Optimiert Ressourcen basierend auf der Datengröße", "soft-delete-archive-message": "Diese Aktion deaktiviert den Zugriff auf {{entity}}. Sie können es später aus dem Archiv wiederherstellen.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "Durch das Soft-Löschen wird {{entity}} deaktiviert. Dadurch werden alle Entdeckungs-, Lese- oder Schreibvorgänge auf {{entity}} deaktiviert.", "soft-delete-message-for-n-entities": "Das vorläufige Löschen deaktiviert diese {{count}} {{entity}}. Dadurch werden alle Erkennungs-, Lese- oder Schreibvorgänge für sie deaktiviert.", "something-went-wrong": "Etwas ist schiefgelaufen", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json index 2878a0582a95..5318fffd172e 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json @@ -3638,6 +3638,7 @@ "password-error-message": "Password must be a minimum of 8 and a maximum of 56 characters long and contain at least one uppercase character (A-Z), one lowercase character (a-z), one number, and one special character (such as !, %, @, or #)", "password-pattern-error": "Password must be of minimum 8 and maximum 56 characters, with one special , one upper, one lower case character", "path-of-the-dbt-files-stored": "Path of the folder where the dbt files are stored", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "Permanently deleting this <0>{{entityName}} will result in loss of pipeline configuration, and it cannot be recovered.", "permanently-delete-metadata": "Permanently deleting this <0>{{entityName}} will result in the removal of its metadata from {{brandName}}, and it cannot be recovered.", "permanently-delete-metadata-and-dependents": "Permanently deleting this {{entityName}} will remove its metadata, as well as the metadata of {{dependents}} from {{brandName}} permanently.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "Size evolution of assets in organization.", "smart-sampling-hint": "Optimizes resources based on data size", "soft-delete-archive-message": "This action will disable access to the {{entity}}. You can restore it later from Archives.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "Soft deleting will deactivate the {{entity}}. This will disable any discovery, read or write operations on {{entity}}.", "soft-delete-message-for-n-entities": "Soft deleting will deactivate these {{count}} {{entity}}. This will disable any discovery, read or write operations on them.", "something-went-wrong": "Something went wrong", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/es-es.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/es-es.json index 126b5fce0dbb..1db8592fb8f8 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/es-es.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/es-es.json @@ -3638,6 +3638,7 @@ "password-error-message": "La contraseña debe tener como mínimo 8 y como máximo 56 caracteres, con al menos una letra mayúscula, una letra minúscula, un número y un carácter especial (como !, %, @ o #)", "password-pattern-error": "La contraseña debe tener como mínimo 8 y como máximo 56 caracteres, con al menos una letra mayúscula, una letra minúscula, un número y un carácter especial (como !, %, @ o #)", "path-of-the-dbt-files-stored": "Ruta de la carpeta donde se almacenan los archivos dbt", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "Al eliminar permanentemente este <0>{{entityName}}, se perderá la configuración de la pipeline, y no podrá ser recuperada.", "permanently-delete-metadata": "Al eliminar permanentemente este <0>{{entityName}}, se eliminarán sus metadatos de {{brandName}} permanentemente.", "permanently-delete-metadata-and-dependents": "Al eliminar permanentemente este {{entityName}}, se eliminarán sus metadatos, así como los metadatos de {{dependents}} de {{brandName}} permanentemente.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "Evolución del tamaño de los activos en la organización.", "smart-sampling-hint": "Optimiza los recursos según el tamaño de los datos", "soft-delete-archive-message": "Esta acción deshabilitará el acceso a {{entity}}. Podrás restaurarlo más tarde desde Archivos.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "La eliminación suave desactivará la {{entity}}. Esto deshabilitará cualquier operación de descubrimiento, lectura o escritura en {{entity}}.", "soft-delete-message-for-n-entities": "La eliminación temporal desactivará estos {{count}} {{entity}}. Esto deshabilitará cualquier operación de descubrimiento, lectura o escritura sobre ellos.", "something-went-wrong": "Algo salió mal", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/fr-fr.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/fr-fr.json index 2ce5536a4272..b46f6601b77e 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/fr-fr.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/fr-fr.json @@ -3638,6 +3638,7 @@ "password-error-message": "Le mot de passe doit comporter au moins 8 caractères et au plus 56 caractères et doit contenir au moins une lettre majuscule (A-Z), une lettre minuscule (a-z), un chiffre et un caractère spécial (tel que !, %, @ ou #).", "password-pattern-error": "Le mot de passe doit comporter au moins 8 caractères et au plus 56 caractères, avec un caractère spécial, une lettre majuscule et une lettre minuscule.", "path-of-the-dbt-files-stored": "Chemin du dossier où sont situés les fichiers dbt.", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "La suppression définitive de <0>{{entityName}} entraînera la perte de la configuration du pipeline et ne pourra pas être récupérée.", "permanently-delete-metadata": "La suppression permanente de cette <0>{{entityName}} supprimera ses métadonnées de façon permanente d'{{brandName}}.", "permanently-delete-metadata-and-dependents": "La suppression permanente de cette {{entityName}} supprimera ses métadonnées ainsi que les métadonnées de {{dependents}} de façon permanente d'{{brandName}}.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "Evolution de la taille des actifs dans l'organisation.", "smart-sampling-hint": "Optimise les ressources en fonction de la taille des données", "soft-delete-archive-message": "Cette action désactivera l'accès à {{entity}}. Vous pourrez le restaurer plus tard depuis les Archives.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "La suppression logique désactivera le {{entity}}. Cela désactivera toute découverte, lecture ou écriture sur le {{entity}}.", "soft-delete-message-for-n-entities": "La suppression logique désactivera ces {{count}} {{entity}}. Cela désactivera toutes les opérations de découverte, de lecture ou d'écriture sur eux.", "something-went-wrong": "Quelque chose s'est mal passé", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/gl-es.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/gl-es.json index 45de983e8a40..110623187b23 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/gl-es.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/gl-es.json @@ -3638,6 +3638,7 @@ "password-error-message": "O contrasinal debe ter un mínimo de 8 e un máximo de 56 caracteres e conter polo menos unha maiúscula (A-Z), unha minúscula (a-z), un número e un carácter especial (como !, %, @ ou #)", "password-pattern-error": "O contrasinal debe ter un mínimo de 8 e un máximo de 56 caracteres, cun carácter especial, unha maiúscula e unha minúscula", "path-of-the-dbt-files-stored": "Ruta do cartafol onde se almacenan os ficheiros dbt", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "A eliminación permanente deste <0>{{entityName}} provocará a perda da configuración da canalización e non se poderá recuperar.", "permanently-delete-metadata": "Eliminar permanentemente este <0>{{entityName}} eliminará os seus metadatos de {{brandName}} e non poderá recuperarse.", "permanently-delete-metadata-and-dependents": "Eliminar permanentemente este {{entityName}} eliminará os seus metadatos, así como os metadatos de {{dependents}} de {{brandName}} de forma permanente.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "Evolución do tamaño dos activos na organización.", "smart-sampling-hint": "Optimiza os recursos segundo o tamaño dos datos", "soft-delete-archive-message": "Esta acción desactivará o acceso a {{entity}}. Poderás restauralo máis tarde desde Arquivos.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "A eliminación suave desactivará {{entity}}. Isto desactivará calquera operación de descubrimento, lectura ou escritura en {{entity}}.", "soft-delete-message-for-n-entities": "A eliminación suave desactivará estes {{count}} {{entity}}. Isto desactivará calquera operación de descubrimento, lectura ou escritura sobre eles.", "something-went-wrong": "Algo saíu mal", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/he-he.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/he-he.json index 486ac63ab017..16e8211e4344 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/he-he.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/he-he.json @@ -3638,6 +3638,7 @@ "password-error-message": "יש להזין סיסמה באורך של 8 עד 15 תווים ולכלול לפחות אות גדולה אחת (A-Z), אות קטנה אחת (a-z), מספר אחד ותו מיוחד (כמו !, %, @, או #)", "password-pattern-error": "יש להזין סיסמה באורך של 8 עד 56 תווים, עם תו מיוחד אחד, אות גדולה אחת ואות קטנה אחת", "path-of-the-dbt-files-stored": "נתיב לתיקייה בה נשמרים קבצי ה-dbt", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "מחיקה קבועה של <0>{{entityName}} תגרום לאובדן תצורת הצינור, ולא ניתן יהיה לשחזר אותה.", "permanently-delete-metadata": "מחיקה של {{entityName}} תסיר את המטה-דאטה שלו מ-{{brandName}} לצמיתות.", "permanently-delete-metadata-and-dependents": "מחיקה של {{entityName}} תסיר את המטה-דאטה שלו, כמו גם את המטה-דאטה של {{dependents}} מ-{{brandName}} לצמיתות.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "אבולוציה של גודל הנכסים בארגון.", "smart-sampling-hint": "מייעל משאבים בהתאם לגודל הנתונים", "soft-delete-archive-message": "פעולה זו תשבית את הגישה אל {{entity}}. תוכל לשחזר אותו מאוחר יותר מהארכיון.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "מחיקה רכה תשבית את {{entity}}. הפעולה תשבית כל קריאה או כתיבת הפעולות על {{entity}}.", "soft-delete-message-for-n-entities": "מחיקה רכה תשבית את {{count}} {{entity}} אלה. פעולה זו תשבית כל פעולות גילוי, קריאה או כתיבה עליהם.", "something-went-wrong": "משהו השתבש", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ja-jp.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ja-jp.json index 2d489b311127..5826286bb1d7 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ja-jp.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ja-jp.json @@ -3638,6 +3638,7 @@ "password-error-message": "パスワードは8文字以上66文字以下で、大文字 (A-Z)、小文字 (a-z)、数字、特殊文字 (!、%、@、# など) をそれぞれ少なくとも1文字含める必要があります。", "password-pattern-error": "パスワードは8~56文字で、1つの特殊文字、大文字1つ、小文字1つが含まれている必要があります。", "path-of-the-dbt-files-stored": "dbtファイルが保存されているフォルダのパス", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "この <0>{{entityName}} を完全に削除すると、パイプライン設定が失われ、元に戻すことはできません。", "permanently-delete-metadata": "この <0>{{entityName}} を完全に削除すると、{{brandName}} からメタデータが完全に削除されます。", "permanently-delete-metadata-and-dependents": "{{entityName}} を完全に削除すると、そのメタデータおよび {{dependents}} のメタデータも {{brandName}} から完全に削除されます。", @@ -3784,6 +3785,7 @@ "size-evolution-description": "組織内アセットのサイズの推移。", "smart-sampling-hint": "データサイズに基づいてリソースを最適化します", "soft-delete-archive-message": "この操作により、{{entity}}へのアクセスが無効になります。後でアーカイブから復元できます。", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "ソフトデリートは{{entity}}を非アクティブ化します。これにより、データの探索や{{entity}}に対する読み取りおよび書き込み操作が無効になります。", "soft-delete-message-for-n-entities": "ソフト削除すると、これらの {{count}} 件の{{entity}}が無効化されます。これにより、それらに対する検出、読み取り、書き込みの操作が無効になります。", "something-went-wrong": "問題が発生しました。", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ko-kr.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ko-kr.json index 511e747893fe..285c55121e7d 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ko-kr.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ko-kr.json @@ -3638,6 +3638,7 @@ "password-error-message": "비밀번호는 최소 8자에서 최대 56자 길이여야 하며, 최소 하나의 대문자(A-Z), 하나의 소문자(a-z), 하나의 숫자, 그리고 하나의 특수 문자(!, %, @, # 등)를 포함해야 합니다", "password-pattern-error": "비밀번호는 최소 8자에서 최대 56자 길이여야 하며, 하나의 특수 문자, 하나의 대문자, 하나의 소문자를 포함해야 합니다", "path-of-the-dbt-files-stored": "dbt 파일이 저장된 폴더의 경로", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "이 <0>{{entityName}}을(를) 영구적으로 삭제하면 파이프라인 구성이 손실되며 복구할 수 없습니다.", "permanently-delete-metadata": "이 <0>{{entityName}}을(를) 영구적으로 삭제하면 {{brandName}}에서 해당 메타데이터가 제거되며 복구할 수 없습니다.", "permanently-delete-metadata-and-dependents": "이 {{entityName}}을(를) 영구적으로 삭제하면 해당 메타데이터와 {{dependents}}의 메타데이터가 {{brandName}}에서 영구적으로 제거됩니다.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "조직의 자산 크기 변화.", "smart-sampling-hint": "데이터 크기에 따라 리소스를 최적화합니다", "soft-delete-archive-message": "이 작업은 {{entity}}에 대한 액세스를 비활성화합니다. 나중에 보관함에서 복원할 수 있습니다.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "소프트 삭제는 {{entity}}를 비활성화합니다. 이는 {{entity}}에 대한 모든 검색, 읽기 또는 쓰기 작업을 비활성화합니다.", "soft-delete-message-for-n-entities": "소프트 삭제하면 {{count}}개의 {{entity}}이(가) 비활성화됩니다. 이렇게 하면 해당 항목에 대한 검색, 읽기 또는 쓰기 작업이 비활성화됩니다.", "something-went-wrong": "문제가 발생했습니다", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/mr-in.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/mr-in.json index 428405ac50f0..5be11d629f5e 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/mr-in.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/mr-in.json @@ -3638,6 +3638,7 @@ "password-error-message": "पासवर्ड किमान 8 आणि कमाल 56 वर्णांचा असावा आणि त्यात किमान एक मोठा अक्षर (A-Z), एक लहान अक्षर (a-z), एक संख्या आणि एक विशेष वर्ण (जसे की !, %, @, किंवा #) असावा", "password-pattern-error": "पासवर्ड किमान 8 आणि कमाल 56 वर्णांचा असावा, ज्यात एक विशेष, एक मोठा, एक लहान अक्षर असावा", "path-of-the-dbt-files-stored": "dbt फाइल्स जिथे संग्रहित केल्या आहेत त्या फोल्डरचा पथ", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "हे <0>{{entityName}} कायमचे मिटवल्याने पाइपलाइन संरचना गमावली जाईल आणि ती पुनर्प्राप्त केली जाऊ शकत नाही.", "permanently-delete-metadata": "हे <0>{{entityName}} कायमचे मिटवल्याने त्याचे मेटाडेटा {{brandName}} मधून काढले जाईल आणि ते पुनर्प्राप्त केले जाऊ शकत नाही.", "permanently-delete-metadata-and-dependents": "हे {{entityName}} कायमचे मिटवल्याने त्याचे मेटाडेटा तसेच {{dependents}} चे मेटाडेटा {{brandName}} मधून कायमचे काढले जाईल.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "संस्थेतील ॲसेट्सच्या आकाराची उत्क्रांती.", "smart-sampling-hint": "डेटाच्या आकारावर आधारित संसाधने अनुकूलित करते", "soft-delete-archive-message": "या क्रियेमुळे {{entity}} वरील प्रवेश अक्षम होईल. आपण नंतर ते संग्रहणातून पुनर्संचयित करू शकता.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "सॉफ्ट डिलीट केल्याने {{entity}} निष्क्रिय होईल. हे {{entity}} वर कोणतीही शोध, वाचन किंवा लेखन ऑपरेशन्स अक्षम करेल.", "soft-delete-message-for-n-entities": "सॉफ्ट डिलीट केल्याने हे {{count}} {{entity}} निष्क्रिय होतील. यामुळे त्यांच्यावरील कोणतेही शोध, वाचन किंवा लेखन ऑपरेशन अक्षम होतील.", "something-went-wrong": "काहीतरी चुकले", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/nl-nl.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/nl-nl.json index 2418e85036a5..7f1185d2cda7 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/nl-nl.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/nl-nl.json @@ -3638,6 +3638,7 @@ "password-error-message": "Het wachtwoord moet minimaal 8 en maximaal 56 tekens lang zijn en ten minste één hoofdletter (A-Z), één kleine letter (a-z), één cijfer en één speciaal teken (zoals !, %, @ of #) bevatten", "password-pattern-error": "Wachtwoord moet minimaal 8 en maximaal 56 tekens lang zijn, met één speciaal teken, één hoofdletter, één kleine letter", "path-of-the-dbt-files-stored": "Pad naar de map waarin de dbt-bestanden zijn opgeslagen", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "Als u deze <0>{{entityName}} definitief verwijdert, gaat de pijplijnconfiguratie verloren en kan deze niet worden hersteld.", "permanently-delete-metadata": "Het permanent verwijderen van deze <0>{{entityName}} verwijdert de metadata ervan permanent uit {{brandName}}.", "permanently-delete-metadata-and-dependents": "Het permanent verwijderen van deze {{entityName}} verwijdert de metadata ervan, evenals de metadata van {{dependents}} permanent uit {{brandName}}.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "Ontwikkeling assethoeveelheid in de organisatie.", "smart-sampling-hint": "Optimaliseert resources op basis van gegevensgrootte", "soft-delete-archive-message": "Deze actie schakelt de toegang tot {{entity}} uit. U kunt het later herstellen vanuit Archieven.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "Zacht verwijderen zal de {{entity}} deactiveren. Hierdoor worden alle ontdekkings-, lees- of schrijfoperaties op {{entity}} uitgeschakeld.", "soft-delete-message-for-n-entities": "Zacht verwijderen deactiveert deze {{count}} {{entity}}. Dit schakelt alle ontdekkings-, lees- of schrijfbewerkingen op hen uit.", "something-went-wrong": "Er is iets misgegaan", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/pr-pr.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/pr-pr.json index b4ccd01382eb..0cfcb231ddd7 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/pr-pr.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/pr-pr.json @@ -3638,6 +3638,7 @@ "password-error-message": "رمز عبور باید حداقل 8 و حداکثر 56 کاراکتر باشد و حداقل یک کاراکتر بزرگ (A-Z)، یک کاراکتر کوچک (a-z)، یک عدد و یک کاراکتر خاص (مثل !، %، @، یا #) داشته باشد.", "password-pattern-error": "رمز عبور باید حداقل 8 و حداکثر 56 کاراکتر، با یک کاراکتر خاص، یک حرف بزرگ و یک حرف کوچک باشد.", "path-of-the-dbt-files-stored": "مسیر پوشه‌ای که فایل‌های dbt در آن ذخیره شده‌اند.", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "حذف دائمی این <0>{{entityName}} منجر به از دست رفتن پیکربندی پایپ‌لاین می‌شود و قابل بازیابی نیست.", "permanently-delete-metadata": "حذف دائم این <0>{{entityName}} منجر به حذف متادیتای آن از {{brandName}} می‌شود و قابل بازیابی نخواهد بود.", "permanently-delete-metadata-and-dependents": "حذف دائمی این {{entityName}} منجر به حذف متادیتای آن و همچنین متادیتای {{dependents}} از {{brandName}} به‌طور دائم می‌شود.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "تحول اندازه دارایی‌ها در سازمان.", "smart-sampling-hint": "Optimizes yer resources based on the size o' yer data, arrr", "soft-delete-archive-message": "Esta ação irá desativar o acesso a {{entity}}. Você poderá restaurá-lo mais tarde a partir de Arquivos.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "حذف نرم، {{entity}} را غیرفعال می‌کند. این اقدام هرگونه عملیات کشف، خواندن یا نوشتن روی {{entity}} را غیرفعال خواهد کرد.", "soft-delete-message-for-n-entities": "Soft deleting will deactivate these {{count}} {{entity}}. This will disable any discovery, read or write operations on them.", "something-went-wrong": "یک خطا رخ داده است.", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-br.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-br.json index 41f44deb9803..9f7e1ba775d7 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-br.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-br.json @@ -3638,6 +3638,7 @@ "password-error-message": "A senha deve ter no mínimo 8 e no máximo 56 caracteres e conter pelo menos uma letra maiúscula (A-Z), uma letra minúscula (a-z), um número e um caractere especial (como !, %, @ ou #)", "password-pattern-error": "A senha deve ter no mínimo 8 e no máximo 56 caracteres, com pelo menos um caractere especial, uma letra maiúscula e uma letra minúscula", "path-of-the-dbt-files-stored": "Caminho da pasta onde os arquivos dbt são armazenados", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "A exclusão permanente de <0>{{entityName}} resultará na perda da configuração do pipeline e não poderá ser recuperada.", "permanently-delete-metadata": "Excluir permanentemente este(a) <0>{{entityName}} removerá seus metadados do {{brandName}} permanentemente.", "permanently-delete-metadata-and-dependents": "Excluir permanentemente este(a) {{entityName}} removerá seus metadados, bem como os metadados de {{dependents}} do {{brandName}} permanentemente.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "Evolução do tamanho dos ativos na organização.", "smart-sampling-hint": "Otimiza recursos com base no tamanho dos dados", "soft-delete-archive-message": "Esta ação irá desativar o acesso a {{entity}}. Você poderá restaurá-lo mais tarde a partir de Arquivos.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "A exclusão suave desativará o {{entity}}. Isso desabilitará qualquer operação de descoberta, leitura ou gravação no {{entity}}.", "soft-delete-message-for-n-entities": "A exclusão suave desativará estes {{count}} {{entity}}. Isso desabilitará quaisquer operações de descoberta, leitura ou escrita sobre eles.", "something-went-wrong": "Algo deu errado", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-pt.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-pt.json index 512bc598ca27..1d0975327c83 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-pt.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-pt.json @@ -3638,6 +3638,7 @@ "password-error-message": "A senha deve ter no mínimo 8 e no máximo 56 caracteres e conter pelo menos uma letra maiúscula (A-Z), uma letra minúscula (a-z), um número e um caracter especial (como !, %, @ ou #)", "password-pattern-error": "A senha deve ter no mínimo 8 e no máximo 56 caracteres, com pelo menos um caracter especial, uma letra maiúscula e uma letra minúscula", "path-of-the-dbt-files-stored": "Caminho da pasta onde os arquivos dbt são armazenados", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "A exclusão permanente deste <0>{{entityName}} resultará na perda da configuração do pipeline e não poderá ser recuperada.", "permanently-delete-metadata": "Excluir permanentemente este(a) <0>{{entityName}} removerá seus metadados do {{brandName}} permanentemente.", "permanently-delete-metadata-and-dependents": "Excluir permanentemente este(a) {{entityName}} removerá seus metadados, bem como os metadados de {{dependents}} do {{brandName}} permanentemente.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "Evolução do tamanho dos ativos na organização.", "smart-sampling-hint": "Otimiza os recursos com base no tamanho dos dados", "soft-delete-archive-message": "Esta ação irá desativar o acesso a {{entity}}. Pode restaurá-lo mais tarde a partir de Arquivos.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "A exclusão suave desativará o {{entity}}. Isso desabilitará qualquer operação de descoberta, leitura ou gravação no {{entity}}.", "soft-delete-message-for-n-entities": "A eliminação suave irá desativar estes {{count}} {{entity}}. Isto irá desativar quaisquer operações de descoberta, leitura ou escrita sobre eles.", "something-went-wrong": "Algo deu errado", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ru-ru.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ru-ru.json index b40678067e99..46c1e54f9d09 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ru-ru.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ru-ru.json @@ -3638,6 +3638,7 @@ "password-error-message": "Пароль должен содержать не менее 8 и не более 56 символов, включая как минимум один символ верхнего регистра (A-Z), один символ нижнего регистра (az), одну цифру и один специальный символ (например, !, %, @ или #). )", "password-pattern-error": "Пароль должен состоять минимум из 8 и максимум из 56 символов, включая один специальный, один верхний и один нижний регистр.", "path-of-the-dbt-files-stored": "Путь к папке, в которой хранятся файлы dbt", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "Безвозвратное удаление <0>{{entityName}} приведет к потере конфигурации конвейера, и его нельзя будет восстановить.", "permanently-delete-metadata": "Внимание! Удаление объекта <0>{{entityName}} невозможно отменить — все метаданные будут утеряны.", "permanently-delete-metadata-and-dependents": "Внимание! Удаление объекта {{entityName}} невозможно отменить — все метаданные, включая {{dependers}} будут утеряны.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "Размер эволюции объектов в организации.", "smart-sampling-hint": "Оптимизирует ресурсы в зависимости от объёма данных", "soft-delete-archive-message": "Это действие отключит доступ к {{entity}}. Вы сможете восстановить его позже из Архива.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "Мягкое удаление деактивирует объект «{{entity}}». Обнаружение объекта, чтение или запись его данных отключатся.", "soft-delete-message-for-n-entities": "Мягкое удаление деактивирует {{count}} {{entity}}. Это отключит все операции обнаружения, чтения или записи для них.", "something-went-wrong": "Что-то пошло не так", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/sv-se.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/sv-se.json index 0f29eba60546..d7c81633d8ba 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/sv-se.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/sv-se.json @@ -3638,6 +3638,7 @@ "password-error-message": "Lösenordet måste vara minst 8 och högst 56 tecken långt och innehålla minst ett versalt tecken (A-Z), ett gement tecken (a-z), en siffra och ett specialtecken (såsom !, %, @ eller #)", "password-pattern-error": "Lösenordet måste vara minst 8 och högst 56 tecken, med ett specialtecken, ett versalt och ett gement tecken", "path-of-the-dbt-files-stored": "Sökväg till mappen där dbt-filerna lagras", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "Att permanent ta bort denna <0>{{entityName}} resulterar i förlust av pipelinekonfigurationen, och den kan inte återställas.", "permanently-delete-metadata": "Att permanent ta bort denna <0>{{entityName}} resulterar i att dess metadata tas bort från {{brandName}}, och den kan inte återställas.", "permanently-delete-metadata-and-dependents": "Att permanent ta bort denna {{entityName}} tar bort dess metadata samt metadatan för {{dependents}} permanent från {{brandName}}.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "Storleksutveckling av tillgångar i organisationen.", "smart-sampling-hint": "Optimerar resurser baserat på datastorlek", "soft-delete-archive-message": "Den här åtgärden inaktiverar åtkomsten till {{entity}}. Du kan återställa det senare från Arkiv.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "Mjuk borttagning inaktiverar {{entity}}. Detta inaktiverar all upptäckt, läs- eller skrivoperationer på {{entity}}.", "soft-delete-message-for-n-entities": "Mjuk radering inaktiverar dessa {{count}} {{entity}}. Det inaktiverar all sökning, läs- och skrivoperationer på dem.", "something-went-wrong": "Något gick fel", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/th-th.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/th-th.json index f67776e89755..3712187ff9ed 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/th-th.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/th-th.json @@ -3638,6 +3638,7 @@ "password-error-message": "รหัสผ่านต้องมีความยาวขั้นต่ำ 8 ตัวและสูงสุด 56 ตัว และต้องมีอย่างน้อยหนึ่งตัวอักษรพิมพ์ใหญ่ (A-Z), หนึ่งตัวอักษรพิมพ์เล็ก (a-z), หนึ่งตัวเลข, และหนึ่งอักขระพิเศษ (เช่น !, %, @, หรือ #)", "password-pattern-error": "รหัสผ่านต้องมีความยาวขั้นต่ำ 8 ตัวและสูงสุด 56 ตัว มีอักขระพิเศษหนึ่งตัว, ตัวอักษรพิมพ์ใหญ่หนึ่งตัว, ตัวอักษรพิมพ์เล็กหนึ่งตัว", "path-of-the-dbt-files-stored": "เส้นทางของโฟลเดอร์ที่จัดเก็บไฟล์ dbt", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "การลบ <0>{{entityName}} นี้อย่างถาวรจะทำให้การตั้งค่าท่อสูญหายและไม่สามารถกู้คืนได้", "permanently-delete-metadata": "การลบ <0>{{entityName}} นี้อย่างถาวรจะทำให้ข้อมูลเมตาของมันถูกลบออกจาก {{brandName}} และไม่สามารถกู้คืนได้", "permanently-delete-metadata-and-dependents": "การลบ {{entityName}} นี้อย่างถาวรจะทำให้ข้อมูลเมตาของมันและข้อมูลเมตาของ {{dependents}} ถูกลบออกจาก {{brandName}} อย่างถาวร", @@ -3784,6 +3785,7 @@ "size-evolution-description": "การพัฒนาขนาดของสินทรัพย์ในองค์กร", "smart-sampling-hint": "เพิ่มประสิทธิภาพทรัพยากรตามขนาดของข้อมูล", "soft-delete-archive-message": "การดำเนินการนี้จะปิดการเข้าถึง {{entity}} คุณสามารถกู้คืนได้ภายหลังจากที่เก็บถาวร", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "การลบแบบนุ่มนวลจะทำให้ {{entity}} ถูกปิดการใช้งาน ซึ่งจะปิดการค้นหา, อ่าน หรือการเขียนข้อมูลใน {{entity}}", "soft-delete-message-for-n-entities": "การลบแบบ Soft Delete จะปิดการใช้งาน {{count}} {{entity}} เหล่านี้ ซึ่งจะปิดการใช้งานการค้นหา การอ่าน หรือการเขียนทั้งหมดบนรายการเหล่านั้น", "something-went-wrong": "เกิดข้อผิดพลาดบางอย่าง", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/tr-tr.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/tr-tr.json index fcbeb220de8a..9448b34f60ac 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/tr-tr.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/tr-tr.json @@ -3638,6 +3638,7 @@ "password-error-message": "Şifre en az 8 ve en fazla 56 karakter uzunluğunda olmalı ve en az bir büyük harf (A-Z), bir küçük harf (a-z), bir rakam ve bir özel karakter ( !, %, @ veya # gibi) içermelidir.", "password-pattern-error": "Şifre en az 8 ve en fazla 56 karakterden oluşmalı, bir özel karakter, bir büyük harf, bir küçük harf içermelidir", "path-of-the-dbt-files-stored": "dbt dosyalarının saklandığı klasörün yolu", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "Bu <0>{{entityName}} kalıcı olarak silinmesi, iş akışı yapılandırmasının kaybolmasına neden olacak ve kurtarılamayacaktır.", "permanently-delete-metadata": "Bu <0>{{entityName}} kalıcı olarak silinmesi, metadatasının {{brandName}}'dan kaldırılmasına neden olacak ve kurtarılamayacaktır.", "permanently-delete-metadata-and-dependents": "Bu {{entityName}} kalıcı olarak silinmesi, metadatasının yanı sıra {{dependents}} metadatasını da {{brandName}}'dan kalıcı olarak kaldıracaktır.", @@ -3784,6 +3785,7 @@ "size-evolution-description": "Kuruluştaki varlıkların boyut evrimi.", "smart-sampling-hint": "Kaynakları veri boyutuna göre optimize eder", "soft-delete-archive-message": "Bu işlem {{entity}} öğesine erişimi devre dışı bırakacaktır. Daha sonra Arşivler'den geri yükleyebilirsiniz.", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "Geçici silme işlemi, {{entity}} öğesini devre dışı bırakacaktır. Bu, {{entity}} üzerindeki tüm keşif, okuma veya yazma işlemlerini devre dışı bırakacaktır.", "soft-delete-message-for-n-entities": "Geçici silme, bu {{count}} {{entity}} öğesini devre dışı bırakacak. Bu, bunlar üzerindeki tüm keşif, okuma veya yazma işlemlerini devre dışı bırakacaktır.", "something-went-wrong": "Bir şeyler ters gitti", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-cn.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-cn.json index a8c7de6ed571..36973db9b06e 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-cn.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-cn.json @@ -3638,6 +3638,7 @@ "password-error-message": "密码必须为8到56个字符, 至少包括一个大写字母(A-Z)、一个小写字母(a-z), 和一个特殊字符(例如:!, %, @, or #)", "password-pattern-error": "密码必须为8到56个字符, 至少包括一个特殊字符、一个大写字母、一个小写字母", "path-of-the-dbt-files-stored": "存储 dbt 文件的文件夹路径", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "永久删除此 <0>{{entityName}} 将导致管道配置丢失,并且无法恢复。", "permanently-delete-metadata": "永久删除此<0>{{entityName}}将永久从 {{brandName}} 中删除其元数据", "permanently-delete-metadata-and-dependents": "永久删除此{{entityName}}将永久从 {{brandName}} 中删除其元数据以及{{dependents}}的元数据", @@ -3784,6 +3785,7 @@ "size-evolution-description": "组织中资产规模的变化", "smart-sampling-hint": "根据数据大小优化资源", "soft-delete-archive-message": "此操作将禁用对 {{entity}} 的访问。您可以稍后从存档中将其恢复。", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "软删除将停用{{entity}}, 这将禁用{{entity}}上的任何发现、读取或写入操作", "soft-delete-message-for-n-entities": "软删除将停用这 {{count}} 个{{entity}}。这将禁止对其进行任何发现、读取或写入操作。", "something-went-wrong": "出现了一些问题", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-tw.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-tw.json index 8c5973ba1486..e4e52a52f946 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-tw.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-tw.json @@ -3638,6 +3638,7 @@ "password-error-message": "密碼長度必須介於 8 到 56 個字元之間,並包含至少一個大寫字母 (A-Z)、一個小寫字母 (a-z)、一個數字和一個特殊字元(如 !、%、@ 或 #)", "password-pattern-error": "密碼長度必須介於 8 到 56 個字元之間,並包含一個特殊字元、一個大寫字母和一個小寫字母", "path-of-the-dbt-files-stored": "儲存 dbt 檔案的資料夾路徑", + "permanently-delete-common-message": "Delete this {{entity}} and all its metadata forever. This can't be undone.", "permanently-delete-ingestion-pipeline": "永久刪除 <0>{{entityName}} 將導致管線組態遺失,且無法復原。", "permanently-delete-metadata": "永久刪除 <0>{{entityName}} 將導致其元資料從 {{brandName}} 中移除,且無法復原。", "permanently-delete-metadata-and-dependents": "永久刪除此 {{entityName}} 將從 {{brandName}} 中永久移除其元資料,以及 {{dependents}} 的元資料。", @@ -3784,6 +3785,7 @@ "size-evolution-description": "組織中資產的大小演進。", "smart-sampling-hint": "根據資料大小最佳化資源", "soft-delete-archive-message": "此操作將停用對 {{entity}} 的存取權限。您稍後可以從封存中還原它。", + "soft-delete-common-message": "Turn off this {{entity}}. You can restore it later.", "soft-delete-message-for-entity": "軟刪除將停用 {{entity}}。這將停用對 {{entity}} 的任何探索、讀取或寫入操作。", "soft-delete-message-for-n-entities": "軟刪除將停用這 {{count}} 個{{entity}}。這將停用對其的任何探索、讀取或寫入操作。", "something-went-wrong": "發生錯誤", diff --git a/openmetadata-ui/src/main/resources/ui/src/pages/AlertDetailsPage/AlertDetailsPage.test.tsx b/openmetadata-ui/src/main/resources/ui/src/pages/AlertDetailsPage/AlertDetailsPage.test.tsx index 678dc5185567..e8f68b4461ae 100644 --- a/openmetadata-ui/src/main/resources/ui/src/pages/AlertDetailsPage/AlertDetailsPage.test.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/pages/AlertDetailsPage/AlertDetailsPage.test.tsx @@ -101,8 +101,8 @@ jest.mock( () => jest.fn().mockImplementation(() =>
AlertRecentEventsTab
) ); -jest.mock('../../components/common/DeleteWidget/DeleteWidgetModal', () => - jest.fn().mockImplementation(() =>
DeleteWidgetModal
) +jest.mock('../../components/common/DeleteWidget/DeleteEntityModal', () => + jest.fn().mockImplementation(() =>
DeleteEntityModal
) ); jest.mock('../../components/common/ErrorWithPlaceholder/ErrorPlaceHolder', () => @@ -181,7 +181,7 @@ describe('AlertDetailsPage', () => { expect(screen.getByTestId('delete-button')).toBeInTheDocument(); expect(screen.getByText('label.configuration')).toBeInTheDocument(); expect(screen.getByText('label.recent-event-plural')).toBeInTheDocument(); - expect(screen.getByText('DeleteWidgetModal')).toBeInTheDocument(); + expect(screen.getByText('DeleteEntityModal')).toBeInTheDocument(); }); it('should render the description if alert description is present', async () => { diff --git a/openmetadata-ui/src/main/resources/ui/src/pages/AlertDetailsPage/components/AlertDetailsContent.tsx b/openmetadata-ui/src/main/resources/ui/src/pages/AlertDetailsPage/components/AlertDetailsContent.tsx index 657198d250dc..7d3fb48bad45 100644 --- a/openmetadata-ui/src/main/resources/ui/src/pages/AlertDetailsPage/components/AlertDetailsContent.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/pages/AlertDetailsPage/components/AlertDetailsContent.tsx @@ -16,7 +16,7 @@ import { Button, Card, Col, Row, Skeleton, Space, Tabs, Tooltip } from 'antd'; import { useTranslation } from 'react-i18next'; import { ReactComponent as EditIcon } from '../../../assets/svg/edit-new.svg'; import { ReactComponent as DeleteIcon } from '../../../assets/svg/ic-delete.svg'; -import DeleteWidgetModal from '../../../components/common/DeleteWidget/DeleteWidgetModal'; +import DeleteEntityModal from '../../../components/common/DeleteWidget/DeleteEntityModal'; import DescriptionV1 from '../../../components/common/EntityDescription/DescriptionV1'; import { OwnerLabel } from '../../../components/common/OwnerLabel/OwnerLabel.component'; import TitleBreadcrumb from '../../../components/common/TitleBreadcrumb/TitleBreadcrumb.component'; @@ -164,7 +164,7 @@ function AlertDetailsContent({ /> - ({ )), })); -jest.mock('../../components/common/DeleteWidget/DeleteWidgetModal', () => +jest.mock('../../components/common/DeleteWidget/DeleteEntityModal', () => jest.fn().mockReturnValue(
Delete Modal
) ); diff --git a/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/KPIList.tsx b/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/KPIList.tsx index 09e89c268cf1..4660614d99ac 100644 --- a/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/KPIList.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/pages/DataInsightPage/KPIList.tsx @@ -20,7 +20,7 @@ import { useTranslation } from 'react-i18next'; import { Link, useNavigate } from 'react-router-dom'; import { ReactComponent as EditIcon } from '../../assets/svg/edit-new.svg'; import { ReactComponent as IconDelete } from '../../assets/svg/ic-delete.svg'; -import DeleteWidgetModal from '../../components/common/DeleteWidget/DeleteWidgetModal'; +import DeleteEntityModal from '../../components/common/DeleteWidget/DeleteEntityModal'; import ErrorPlaceHolder from '../../components/common/ErrorWithPlaceholder/ErrorPlaceHolder'; import { PagingHandlerParams } from '../../components/common/NextPrevious/NextPrevious.interface'; import Table from '../../components/common/Table/Table'; @@ -244,7 +244,7 @@ const KPIList = () => { /> {selectedKpi && ( - { +jest.mock('../../components/common/DeleteWidget/DeleteEntityModal', () => { return jest .fn() .mockImplementation(({ visible }) => - visible ?

DeleteWidgetModal

: null + visible ?

DeleteEntityModal

: null ); }); @@ -273,7 +273,7 @@ describe('Notification Alerts Page Tests', () => { userEvent.click(deleteButton); }); - const deleteModal = await screen.findByText('DeleteWidgetModal'); + const deleteModal = await screen.findByText('DeleteEntityModal'); expect(deleteModal).toBeInTheDocument(); }); diff --git a/openmetadata-ui/src/main/resources/ui/src/pages/NotificationListPage/NotificationListPage.tsx b/openmetadata-ui/src/main/resources/ui/src/pages/NotificationListPage/NotificationListPage.tsx index 828d81e9f346..24742d5e9cea 100644 --- a/openmetadata-ui/src/main/resources/ui/src/pages/NotificationListPage/NotificationListPage.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/pages/NotificationListPage/NotificationListPage.tsx @@ -18,7 +18,7 @@ import { useTranslation } from 'react-i18next'; import { Link, useNavigate } from 'react-router-dom'; import { ReactComponent as EditIcon } from '../../assets/svg/edit-new.svg'; import { ReactComponent as DeleteIcon } from '../../assets/svg/ic-delete.svg'; -import DeleteWidgetModal from '../../components/common/DeleteWidget/DeleteWidgetModal'; +import DeleteEntityModal from '../../components/common/DeleteWidget/DeleteEntityModal'; import ErrorPlaceHolder from '../../components/common/ErrorWithPlaceholder/ErrorPlaceHolder'; import { PagingHandlerParams } from '../../components/common/NextPrevious/NextPrevious.interface'; import Table from '../../components/common/Table/Table'; @@ -387,7 +387,7 @@ const NotificationListPage = () => { /> - ({ default: jest.fn().mockImplementation(() =>
NextPrevious
), })); -jest.mock('../../components/common/DeleteWidget/DeleteWidgetModal', () => { +jest.mock('../../components/common/DeleteWidget/DeleteEntityModal', () => { return jest .fn() .mockImplementation(({ visible }) => - visible ?

DeleteWidgetModal

: null + visible ?

DeleteEntityModal

: null ); }); @@ -314,7 +314,7 @@ describe('Observability Alerts Page Tests', () => { fireEvent.click(deleteButton); - const deleteModal = await screen.findByText('DeleteWidgetModal'); + const deleteModal = await screen.findByText('DeleteEntityModal'); expect(deleteModal).toBeInTheDocument(); }); diff --git a/openmetadata-ui/src/main/resources/ui/src/pages/ObservabilityAlertsPage/ObservabilityAlertsPage.tsx b/openmetadata-ui/src/main/resources/ui/src/pages/ObservabilityAlertsPage/ObservabilityAlertsPage.tsx index 22aae6f15be8..3c425aa1d0f4 100644 --- a/openmetadata-ui/src/main/resources/ui/src/pages/ObservabilityAlertsPage/ObservabilityAlertsPage.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/pages/ObservabilityAlertsPage/ObservabilityAlertsPage.tsx @@ -12,7 +12,7 @@ */ import { Col, Row } from 'antd'; import { useTranslation } from 'react-i18next'; -import DeleteWidgetModal from '../../components/common/DeleteWidget/DeleteWidgetModal'; +import DeleteEntityModal from '../../components/common/DeleteWidget/DeleteEntityModal'; import PageLayoutV1 from '../../components/PageLayoutV1/PageLayoutV1'; import { EntityType } from '../../enums/entity.enum'; import { getEntityName } from '../../utils/EntityNameUtils'; @@ -74,7 +74,7 @@ const ObservabilityAlertsPage = () => { /> - { +jest.mock('../../../components/common/DeleteWidget/DeleteEntityModal', () => { return jest .fn() - .mockImplementation(() =>
DeleteWidgetModal.component
); + .mockImplementation(() =>
DeleteEntityModal.component
); }); jest.mock( diff --git a/openmetadata-ui/src/main/resources/ui/src/pages/PoliciesPage/PoliciesListPage/PoliciesListPage.test.tsx b/openmetadata-ui/src/main/resources/ui/src/pages/PoliciesPage/PoliciesListPage/PoliciesListPage.test.tsx index 70974f8db8ab..f7048196643c 100644 --- a/openmetadata-ui/src/main/resources/ui/src/pages/PoliciesPage/PoliciesListPage/PoliciesListPage.test.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/pages/PoliciesPage/PoliciesListPage/PoliciesListPage.test.tsx @@ -59,7 +59,7 @@ jest.mock('react-router-dom', () => ({ )), })); -jest.mock('../../../components/common/DeleteWidget/DeleteWidgetModal', () => +jest.mock('../../../components/common/DeleteWidget/DeleteEntityModal', () => jest.fn().mockReturnValue(
Delete Widget
) ); jest.mock( diff --git a/openmetadata-ui/src/main/resources/ui/src/pages/PoliciesPage/PoliciesListPage/PoliciesListPage.tsx b/openmetadata-ui/src/main/resources/ui/src/pages/PoliciesPage/PoliciesListPage/PoliciesListPage.tsx index 535006687722..945458b384b2 100644 --- a/openmetadata-ui/src/main/resources/ui/src/pages/PoliciesPage/PoliciesListPage/PoliciesListPage.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/pages/PoliciesPage/PoliciesListPage/PoliciesListPage.tsx @@ -19,7 +19,7 @@ import { useCallback, useEffect, useMemo, useState } from 'react'; import { useTranslation } from 'react-i18next'; import { Link, useNavigate } from 'react-router-dom'; import { ReactComponent as IconDelete } from '../../../assets/svg/ic-delete.svg'; -import DeleteWidgetModal from '../../../components/common/DeleteWidget/DeleteWidgetModal'; +import DeleteEntityModal from '../../../components/common/DeleteWidget/DeleteEntityModal'; import ErrorPlaceHolder from '../../../components/common/ErrorWithPlaceholder/ErrorPlaceHolder'; import { PagingHandlerParams } from '../../../components/common/NextPrevious/NextPrevious.interface'; import Table from '../../../components/common/Table/Table'; @@ -335,7 +335,7 @@ const PoliciesListPage = () => { size="small" /> {selectedPolicy && deletePolicyPermission && ( - ({ .fn() .mockImplementation(() => Promise.resolve(ROLES_LIST_WITH_PAGING)), })); -jest.mock('../../../components/common/DeleteWidget/DeleteWidgetModal', () => +jest.mock('../../../components/common/DeleteWidget/DeleteEntityModal', () => jest .fn() .mockReturnValue(
DeletWdigetModal
) diff --git a/openmetadata-ui/src/main/resources/ui/src/pages/RolesPage/RolesListPage/RolesListPage.tsx b/openmetadata-ui/src/main/resources/ui/src/pages/RolesPage/RolesListPage/RolesListPage.tsx index 11a1ee4dd58a..ff080a798eed 100644 --- a/openmetadata-ui/src/main/resources/ui/src/pages/RolesPage/RolesListPage/RolesListPage.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/pages/RolesPage/RolesListPage/RolesListPage.tsx @@ -19,7 +19,7 @@ import { useCallback, useEffect, useMemo, useState } from 'react'; import { useTranslation } from 'react-i18next'; import { Link, useNavigate } from 'react-router-dom'; import { ReactComponent as IconDelete } from '../../../assets/svg/ic-delete.svg'; -import DeleteWidgetModal from '../../../components/common/DeleteWidget/DeleteWidgetModal'; +import DeleteEntityModal from '../../../components/common/DeleteWidget/DeleteEntityModal'; import ErrorPlaceHolder from '../../../components/common/ErrorWithPlaceholder/ErrorPlaceHolder'; import { PagingHandlerParams } from '../../../components/common/NextPrevious/NextPrevious.interface'; import Table from '../../../components/common/Table/Table'; @@ -333,7 +333,7 @@ const RolesListPage = () => { size="small" /> {selectedRole && ( - { + return jest.fn().mockImplementation(() =>
DeleteEntityModal
); +}); + describe('Test UserListPage component', () => { let mockTableComponent: jest.Mock; diff --git a/openmetadata-ui/src/main/resources/ui/src/pages/UserListPage/UserListPageV1.tsx b/openmetadata-ui/src/main/resources/ui/src/pages/UserListPage/UserListPageV1.tsx index c5710e9ab92a..784a7bc798a8 100644 --- a/openmetadata-ui/src/main/resources/ui/src/pages/UserListPage/UserListPageV1.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/pages/UserListPage/UserListPageV1.tsx @@ -20,7 +20,7 @@ import { useTranslation } from 'react-i18next'; import { Link, Navigate, useNavigate } from 'react-router-dom'; import { ReactComponent as IconDelete } from '../../assets/svg/ic-delete.svg'; import { ReactComponent as IconRestore } from '../../assets/svg/ic-restore.svg'; -import DeleteWidgetModal from '../../components/common/DeleteWidget/DeleteWidgetModal'; +import DeleteEntityModal from '../../components/common/DeleteWidget/DeleteEntityModal'; import ErrorPlaceHolder from '../../components/common/ErrorWithPlaceholder/ErrorPlaceHolder'; import FilterTablePlaceHolder from '../../components/common/ErrorWithPlaceholder/FilterTablePlaceHolder'; import { PagingHandlerParams } from '../../components/common/NextPrevious/NextPrevious.interface'; @@ -577,7 +577,7 @@ const UserListPageV1 = () => {

- { handleSearch(''); // Update current count when Create / Delete operation performed