fix: Remove/Disable Duplicate button in Read Only mode of an event-type (#15511)

* fix: Remove/Disable Duplicate button in Read Only mode of an event-type

* fix: use readonly variable

* fix: hiding for smaller devices

* update test cases

---------

Co-authored-by: Keith Williams <[email protected]>
Co-authored-by: unknown <[email protected]>
Co-authored-by: Anik Dhabal Babu <[email protected]>
This commit is contained in:
authored and GitHub committed 2024-07-03 15:23:22 +05:30
1 parent 4f76d4468e
commit 8cd9285cc6
2 files changed
+42 -41

No files matched your search

+2
View File
@@ -91,6 +91,8 @@ testBothFutureAndLegacyRoutes.describe("Event Types tests", () => {
const firstFullSlug = await page.locator(`[data-testid=event-type-slug-${eventTypeId}]`).innerText();
const firstSlug = firstFullSlug.split("/")[2];
await expect(page.locator("[data-testid=readonly-badge]")).toBeHidden();
await page.click(`[data-testid=event-type-options-${eventTypeId}]`);
await page.click(`[data-testid=event-type-duplicate-${eventTypeId}]`);
// Wait for the dialog to appear so we can get the URL