From 9c1df99e9d3d0d589ecf99b066ca9f51cdc6414c Mon Sep 17 00:00:00 2001 From: Ajith KV Date: Mon, 30 Oct 2023 19:51:26 +0530 Subject: [PATCH] Add data-cy for workspace modal (#8044) --- .../CreateOrganization.jsx | 29 +++++++++++------ .../OrganizationManager/EditOrganization.jsx | 32 ++++++++++++------- 2 files changed, 40 insertions(+), 21 deletions(-) diff --git a/frontend/src/_components/OrganizationManager/CreateOrganization.jsx b/frontend/src/_components/OrganizationManager/CreateOrganization.jsx index 9b8e74d389..52a463ac86 100644 --- a/frontend/src/_components/OrganizationManager/CreateOrganization.jsx +++ b/frontend/src/_components/OrganizationManager/CreateOrganization.jsx @@ -124,7 +124,7 @@ export const CreateOrganization = ({ showCreateOrg, setShowCreateOrg }) => {
- + { @@ -140,15 +140,19 @@ export const CreateOrganization = ({ showCreateOrg, setShowCreateOrg }) => { autoFocus /> {fields['name']?.error ? ( - + ) : ( - + )}
- + {
)} {fields['slug']?.error ? ( - + ) : fields['slug'].value && !slugProgress ? ( - + ) : ( - + )}
- -
+ +
{!slugProgress ? ( `${getHostURL()}/${fields['slug']?.value || ''}` ) : ( @@ -198,7 +207,7 @@ export const CreateOrganization = ({ showCreateOrg, setShowCreateOrg }) => {
)}
-
diff --git a/frontend/src/_components/OrganizationManager/EditOrganization.jsx b/frontend/src/_components/OrganizationManager/EditOrganization.jsx index 3ebe0d5602..20ee9816ef 100644 --- a/frontend/src/_components/OrganizationManager/EditOrganization.jsx +++ b/frontend/src/_components/OrganizationManager/EditOrganization.jsx @@ -160,7 +160,7 @@ export const EditOrganization = ({ showEditOrg, setShowEditOrg, currentValue })
- + { @@ -177,15 +177,19 @@ export const EditOrganization = ({ showEditOrg, setShowEditOrg, currentValue }) autoFocus /> {fields['name']?.error ? ( - + ) : ( - + )}
- + )} {fields['slug']?.error ? ( - + ) : fields?.['slug']?.value !== currentValue?.slug && !slugProgress ? ( - + ) : ( - + )}
- -
+ +
{!slugProgress ? ( `${getHostURL()}/${fields['slug']?.value || ''}` ) : ( @@ -237,7 +246,7 @@ export const EditOrganization = ({ showEditOrg, setShowEditOrg, currentValue })
)}
-
- + {t('globals.cancel', 'Cancel')} {t('globals.save', 'Save')}