@@ -770,16 +760,16 @@ const ContentMapper = () => {
version="v2"
icon="Setting"
size="small"
- onClick={() =>{
- const value ={
+ onClick={() => {
+ const value = {
ValidationRegex: data?.advanced?.ValidationRegex,
Mandatory: data?.advanced?.mandatory,
- Multiple: data?.advanced?.multiple,
+ Multiple: data?.advanced?.multiple,
Unique: data?.advanced?.unique,
- NonLocalizable: data?.advanced?.nonLocalizable
- }
- handleAdvancedSetting(data?.ContentstackFieldType, advancePropertise, data?.uid, data)}
- }
+ NonLocalizable: data?.advanced?.nonLocalizable
+ };
+ handleAdvancedSetting(data?.ContentstackFieldType, advancePropertise, data?.uid, data);
+ }}
/>
);
@@ -795,7 +785,6 @@ const ContentMapper = () => {
selectedContentType?.otherCmsUid &&
OtherContentType?.label
) {
-
setcontentTypeMapped((prevSelected) => ({
...prevSelected,
[otherCmsTitle]: OtherContentType?.label
@@ -941,7 +930,7 @@ const ContentMapper = () => {
const adjustedOption = options.map((option: any) => ({
...option,
isDisabled: contentTypeMapped && Object.values(contentTypeMapped).includes(option?.label)
- }));
+ }));
return (
diff --git a/ui/src/components/DestinationStack/Actions/LoadStacks.tsx b/ui/src/components/DestinationStack/Actions/LoadStacks.tsx
index 661e866c5..53803041c 100644
--- a/ui/src/components/DestinationStack/Actions/LoadStacks.tsx
+++ b/ui/src/components/DestinationStack/Actions/LoadStacks.tsx
@@ -38,8 +38,8 @@ const LoadStacks = (props: LoadFileFormatProps) => {
label: 'Loading stacks...',
value: 'loading',
default: false,
- master_locale:'',
- locales:[],
+ master_locale: '',
+ locales: [],
created_at: ''
}
];
@@ -162,12 +162,12 @@ const LoadStacks = (props: LoadFileFormatProps) => {
//Set selected Stack
const selectedStackData = validateArray(stackArray)
- ? stackArray.find(
- (stack: IDropDown) =>
- stack?.value === newMigrationData?.destination_stack?.selectedStack?.value
- )
- : DEFAULT_DROPDOWN;
-
+ ? stackArray.find(
+ (stack: IDropDown) =>
+ stack?.value === newMigrationData?.destination_stack?.selectedStack?.value
+ )
+ : DEFAULT_DROPDOWN;
+
setSelectedStack(selectedStackData);
const newMigrationDataObj: INewMigration = {
@@ -195,7 +195,7 @@ const LoadStacks = (props: LoadFileFormatProps) => {
}}
onSubmit={handleOnSave}
defaultValues={defaultStack}
- selectedOrganisation= {selectedOrganisation?.value}
+ selectedOrganisation={selectedOrganisation?.value}
{...props}
/>
),
diff --git a/ui/src/components/DestinationStack/Summary/StacksSummary.tsx b/ui/src/components/DestinationStack/Summary/StacksSummary.tsx
index ebb20d70d..b6c3bac58 100644
--- a/ui/src/components/DestinationStack/Summary/StacksSummary.tsx
+++ b/ui/src/components/DestinationStack/Summary/StacksSummary.tsx
@@ -2,8 +2,12 @@ import { useContext, useState } from 'react';
import StepIcon from '../../../components/Stepper/FlowStepper/StepIcon';
import { AppContext } from '../../../context/app/app.context';
import { isEmptyString } from '../../../utilities/functions';
-import { DEFAULT_DROPDOWN, IDropDown, INewMigration, IStep } from '../../../context/app/app.interface';
-
+import {
+ DEFAULT_DROPDOWN,
+ IDropDown,
+ INewMigration,
+ IStep
+} from '../../../context/app/app.interface';
import './summary.scss';
import { Icon, Select } from '@contentstack/venus-components';
@@ -11,7 +15,6 @@ interface StacksSummaryProps {
stepData: IStep;
}
-
const StacksSummary = (props: StacksSummaryProps): JSX.Element => {
const { newMigrationData } = useContext(AppContext);
const [selectedStack, setSelectedStack] = useState
(
@@ -26,7 +29,7 @@ const StacksSummary = (props: StacksSummaryProps): JSX.Element => {
value: 'loading',
default: false,
master_locale: '',
- locales:[],
+ locales: [],
created_at: ''
}
];
@@ -36,7 +39,7 @@ const StacksSummary = (props: StacksSummaryProps): JSX.Element => {
{/* {!isEmptyString(newMigrationData?.destination_stack?.selectedStack?.label) &&
!isEmptyString(newMigrationData?.destination_stack?.selectedStack?.value) && ( */}
-
+
@@ -45,7 +48,9 @@ const StacksSummary = (props: StacksSummaryProps): JSX.Element => {
className="stackselect"
version={'v2'}
options={allStack}
- onChange={()=>{return}}
+ onChange={() => {
+ return;
+ }}
value={selectedStack}
isSearchable={true}
isClearable={true}
@@ -64,7 +69,12 @@ const StacksSummary = (props: StacksSummaryProps): JSX.Element => {
-
{return}}>
+ {
+ return;
+ }}
+ >
Create New Stack
diff --git a/ui/src/components/DestinationStack/index.tsx b/ui/src/components/DestinationStack/index.tsx
index f08cae353..866eca491 100644
--- a/ui/src/components/DestinationStack/index.tsx
+++ b/ui/src/components/DestinationStack/index.tsx
@@ -84,7 +84,7 @@ const DestinationStackComponent = ({
value: destination_stack,
label: '',
master_locale: '',
- locales:[],
+ locales: [],
created_at: ''
};
@@ -164,10 +164,7 @@ const DestinationStackComponent = ({
//Check for migration Status and lock.
// Status where Migration is to be Locked:
- setIsMigrationLocked(
- projectData?.status === 2 ||
- projectData?.status === 5
- );
+ setIsMigrationLocked(projectData?.status === 2 || projectData?.status === 5);
};
fetchCMSData();
}, []);
@@ -190,7 +187,10 @@ const DestinationStackComponent = ({
internalActiveStepIndex > -1 &&
internalActiveStepIndex === migrationData?.destinationStackData?.all_steps?.length - 1
) {
- autoVerticalStepperComponent?.current?.handleDynamicStepChange(internalActiveStepIndex, true);
+ autoVerticalStepperComponent?.current?.handleDynamicStepChange(
+ internalActiveStepIndex,
+ true
+ );
}
}
}, [internalActiveStepIndex]);
diff --git a/ui/src/components/LegacyCms/Actions/LoadFileFormat.tsx b/ui/src/components/LegacyCms/Actions/LoadFileFormat.tsx
index 3c1dec755..3a9f62526 100644
--- a/ui/src/components/LegacyCms/Actions/LoadFileFormat.tsx
+++ b/ui/src/components/LegacyCms/Actions/LoadFileFormat.tsx
@@ -46,7 +46,7 @@ const LoadFileFormat = (props: LoadFileFormatProps) => {
/**** ALL METHODS HERE ****/
- const handleBtnClick = async(e: MouseEvent) => {
+ const handleBtnClick = async (e: MouseEvent) => {
e.preventDefault();
if (!isEmptyString(selectedCard?.fileformat_id) && isCheckedBoxChecked) {
updateNewMigrationData({
@@ -59,7 +59,7 @@ const LoadFileFormat = (props: LoadFileFormatProps) => {
await updateFileFormatData(selectedOrganisation?.value, projectId, {
file_format: selectedCard?.fileformat_id
});
-
+
await fileformatConfirmation(selectedOrganisation?.value, projectId, {
fileformat_confirmation: isCheckedBoxChecked
});
diff --git a/ui/src/components/LegacyCms/Actions/LoadPrefix.tsx b/ui/src/components/LegacyCms/Actions/LoadPrefix.tsx
index 4e5fb5410..b43f73ede 100644
--- a/ui/src/components/LegacyCms/Actions/LoadPrefix.tsx
+++ b/ui/src/components/LegacyCms/Actions/LoadPrefix.tsx
@@ -43,7 +43,7 @@ const LoadPreFix = (props: LoadSelectCmsProps) => {
/**** ALL METHODS HERE ****/
//Handle Prefix Change
- const handleOnBlur = async(e: MouseEvent) => {
+ const handleOnBlur = async (e: MouseEvent) => {
e.preventDefault();
if (!isEmptyString(prefix) && !isError && isCheckedBoxChecked) {
const newMigrationDataObj: INewMigration = {
@@ -128,7 +128,7 @@ const LoadPreFix = (props: LoadSelectCmsProps) => {
version="v2"
error={isError}
/>
- {isError && Affix should not be more than 5 chars
}
+ {isError && Affix should not be more than 5 chars
}
-
-
);
};
diff --git a/ui/src/components/LegacyCms/Summary/UploadFileSummary.tsx b/ui/src/components/LegacyCms/Summary/UploadFileSummary.tsx
index 04f3a3b21..55d3caf05 100644
--- a/ui/src/components/LegacyCms/Summary/UploadFileSummary.tsx
+++ b/ui/src/components/LegacyCms/Summary/UploadFileSummary.tsx
@@ -18,16 +18,17 @@ interface Props {
const FileComponent: React.FC
= ({ fileDetails }) => {
return (
- {fileDetails?.isLocalPath ?
- (
-
Local Path: {fileDetails?.localPath}
-
) :
- (
-
AWS Region: {fileDetails?.awsData?.awsRegion}
-
Bucket Name: {fileDetails?.awsData?.bucketName}
-
Bucket Key: {fileDetails?.awsData?.buketKey}
)}
-
-
+ {fileDetails?.isLocalPath ? (
+
+
Local Path: {fileDetails?.localPath}
+
+ ) : (
+
+
AWS Region: {fileDetails?.awsData?.awsRegion}
+
Bucket Name: {fileDetails?.awsData?.bucketName}
+
Bucket Key: {fileDetails?.awsData?.buketKey}
+
+ )}
);
};
diff --git a/ui/src/components/LegacyCms/index.tsx b/ui/src/components/LegacyCms/index.tsx
index 856a97207..13db987a8 100644
--- a/ui/src/components/LegacyCms/index.tsx
+++ b/ui/src/components/LegacyCms/index.tsx
@@ -177,10 +177,7 @@ const LegacyCMSComponent = ({ legacyCMSData, projectData }: LegacyCMSComponentPr
//Check for migration Status and lock.
// Status where Migration is to be Locked:
- setIsMigrationLocked(
- projectData?.status === 2 ||
- projectData?.status === 5
- );
+ setIsMigrationLocked(projectData?.status === 2 || projectData?.status === 5);
};
fetchCMSData();
diff --git a/ui/src/components/LegacyCms/legacyCms.scss b/ui/src/components/LegacyCms/legacyCms.scss
index 8d1cc71cb..c3918f41d 100644
--- a/ui/src/components/LegacyCms/legacyCms.scss
+++ b/ui/src/components/LegacyCms/legacyCms.scss
@@ -1,4 +1,4 @@
-@import '../../scss/variables';
+@import '../../scss/variables';
.service_list {
text-align: center;
display: flex;
diff --git a/ui/src/components/MainHeader/index.scss b/ui/src/components/MainHeader/index.scss
index c4903139d..20aea4986 100644
--- a/ui/src/components/MainHeader/index.scss
+++ b/ui/src/components/MainHeader/index.scss
@@ -23,8 +23,8 @@
display: flex;
height: 2.5rem;
justify-content: center;
- padding: .5rem;
- text-decoration: none;
+ padding: 0.5rem;
+ text-decoration: none;
}
a:focus {
border-radius: 5px;
@@ -49,9 +49,11 @@
color: #475161;
max-width: 11.1875rem;
width: auto;
- overflow: hidden;
+ // overflow: hidden;
}
- .Dropdown__menu--primary .Dropdown__menu__list__item, .Dropdown__menu--secondary .Dropdown__menu__list__item, .Dropdown__menu--tertiary .Dropdown__menu__list__item {
+ .Dropdown__menu--primary .Dropdown__menu__list__item,
+ .Dropdown__menu--secondary .Dropdown__menu__list__item,
+ .Dropdown__menu--tertiary .Dropdown__menu__list__item {
max-width: 14.5rem;
}
}
@@ -60,6 +62,6 @@
line-height: $line-height-reset;
}
.Dropdown__header__value {
- color: $color-black-222!important;
+ color: $color-black-222 !important;
line-height: $line-height-reset;
-}
\ No newline at end of file
+}
diff --git a/ui/src/components/MainHeader/index.tsx b/ui/src/components/MainHeader/index.tsx
index c3e6077aa..edbd57c66 100644
--- a/ui/src/components/MainHeader/index.tsx
+++ b/ui/src/components/MainHeader/index.tsx
@@ -102,7 +102,7 @@ const MainHeader = () => {
-
+
@@ -110,7 +110,7 @@ const MainHeader = () => {
''
)}
-
+
{
};
const nameValidation = (value: string) => {
-
- if (value === '') {
+ if(!value){
+ setInputValue(false);
+ return ;
+ }
+ else if (!/^[^\s].+[^\s]$/.test(value)) {
setInputValue(false);
return 'Please enter project name.';
} else if (value && value?.length > 200) {
@@ -56,18 +59,18 @@ const Modal = (props: ProjectModalProps) => {
return 'Project Name should not be more than 200 chars';
} else {
setInputValue(true);
- return '';
}
};
const descValidation = (value: string) => {
- if (value && value?.length > 255) {
+ if (value?.length >= 255) {
setInputValue(false);
return 'Description should not be more than 255 chars';
} else {
return '';
}
};
+
return (
<>
{
placeholder={namePlaceholder}
data-testid="title-input"
name="name"
+ maxLength='200'
error={(meta?.error || meta?.submitError) && meta?.touched}
/>
- {meta?.error && meta?.touched && (
-
+ {meta?.error && (
+
{meta?.error}
)}
+
>
);
}}
@@ -140,6 +149,7 @@ const Modal = (props: ProjectModalProps) => {
{({ input, meta }): JSX.Element => {
+
return (
<>
@@ -148,16 +158,19 @@ const Modal = (props: ProjectModalProps) => {
- {hasNestedValue(field) &&
- generateNestedOutline(field, nestedIndex)}
+ {hasNestedValue(field) && generateNestedOutline(field, nestedIndex)}
- )
+ );
})}
);
@@ -196,44 +189,43 @@ const TreeView = ({ schema = [] }: schemaType) => {
{nestedList?.length > 0 && (
{nestedList?.map((item: FieldMapType, index: number) => {
- let outlineName = "";
+ let outlineName = '';
if (item?.uid) {
- outlineName = item?.uid?.replace(/\.+/g, "_");
+ outlineName = item?.uid?.replace(/\.+/g, '_');
}
const hasNested = hasNestedValue(item);
-
+
return (
- -
-
) => {
- e.preventDefault();
- e.stopPropagation();
- handleClick(e);
- }}
+
-
- {
- document
- ?.querySelector('.PageLayout__leftSidebar')
- ?.classList.add('hovered');
+
) => {
+ e.preventDefault();
+ e.stopPropagation();
+ handleClick(e);
}}
>
- {hasNested && (
-
- )}
-
-
- {item?.otherCmsField}
-
- {hasNested && generateNestedOutline(item, index)}
-
- )})}
+
{
+ document
+ ?.querySelector('.PageLayout__leftSidebar')
+ ?.classList.add('hovered');
+ }}
+ >
+ {hasNested && }
+
+
+
{item?.otherCmsField}
+
+ {hasNested && generateNestedOutline(item, index)}
+
+ );
+ })}
)}
diff --git a/ui/src/components/Stepper/FlowStepper/FlowBlockItem.tsx b/ui/src/components/Stepper/FlowStepper/FlowBlockItem.tsx
index 01482e1a2..f2e480cad 100644
--- a/ui/src/components/Stepper/FlowStepper/FlowBlockItem.tsx
+++ b/ui/src/components/Stepper/FlowStepper/FlowBlockItem.tsx
@@ -16,19 +16,18 @@ interface FlowBlockItemProps {
isActive?: boolean;
isCompleted?: boolean;
step: IFlowStep;
- onStepClick: (step: IFlowStep, isCompleted:boolean) => () => void;
+ onStepClick: (step: IFlowStep, isCompleted: boolean) => () => void;
}
const FlowBlockItem: FC = (props: FlowBlockItemProps) => {
//console.log("isComeplted : ", props?.isCompleted, props?.step);
-
+
const [isHovered, setIsHovered] = useState(false);
const handleHoveredToggle = (flag: boolean) => () => {
setIsHovered(flag);
};
-
return (
@@ -43,7 +42,7 @@ const FlowBlockItem: FC = (props: FlowBlockItemProps) => {
className="step_tested_check"
icon={props?.isCompleted ? 'CheckCircle' : 'WarningBold'}
version="v2"
- stroke={props?.isCompleted ? 'none' : '#475161'}
+ stroke={props?.isCompleted ? 'none' : '#475161'}
>
@@ -52,7 +51,9 @@ const FlowBlockItem: FC
= (props: FlowBlockItemProps) => {
{
const navigate = useNavigate();
const { migrationData, updateMigrationData, selectedOrganisation } = useContext(AppContext);
- const onStepClick = (step: IFlowStep, isCompleted: boolean) => async() => {
- if (params?.stepId === `${step?.name}`) return;
-
+ const onStepClick = (step: IFlowStep, isCompleted: boolean) => async () => {
+ if (params?.stepId === `${step?.name}`) return;
+
updateMigrationData({ currentFlowStep: step });
-
+
const url = `/projects/${params?.projectId}/migration/steps/${step?.name}`;
- navigate(url, { replace: true });
-
+ navigate(url, { replace: true });
};
return (
{validateArray(migrationData?.allFlowSteps) ? (
migrationData?.allFlowSteps?.map((step: IFlowStep) => {
- return(
- +step?.name}
- />
- )})
+ return (
+ +step?.name}
+ />
+ );
+ })
) : (
<>>
)}
diff --git a/ui/src/components/Stepper/FlowStepper/flowStep.interface.ts b/ui/src/components/Stepper/FlowStepper/flowStep.interface.ts
index 4546e33bf..15122194e 100644
--- a/ui/src/components/Stepper/FlowStepper/flowStep.interface.ts
+++ b/ui/src/components/Stepper/FlowStepper/flowStep.interface.ts
@@ -4,7 +4,7 @@ export interface IFlowStep {
description: string;
name: string;
flow_id: string;
- isCompleted: boolean
+ isCompleted: boolean;
}
export const DEFAULT_IFLOWSTEP: IFlowStep = {
@@ -13,5 +13,5 @@ export const DEFAULT_IFLOWSTEP: IFlowStep = {
name: '1',
flow_id: '',
group_name: '',
- isCompleted:false
+ isCompleted: false
};
diff --git a/ui/src/components/Stepper/VerticalStepper/AutoVerticalStepper.tsx b/ui/src/components/Stepper/VerticalStepper/AutoVerticalStepper.tsx
index 9831397d0..8a16d5f89 100644
--- a/ui/src/components/Stepper/VerticalStepper/AutoVerticalStepper.tsx
+++ b/ui/src/components/Stepper/VerticalStepper/AutoVerticalStepper.tsx
@@ -164,8 +164,11 @@ const AutoVerticalStepper = React.forwardRef<
return (
- {steps?.map((step: any, index: number) => {
- const shouldShowIcon = (step?.title !== 'Select Stack' && step?.title !== 'Upload File' ) ? !step?.lock : false;
+ {steps?.map((step: any, index: number) => {
+ const shouldShowIcon =
+ step?.title !== 'Select Stack' && step?.title !== 'Upload File'
+ ? !step?.lock
+ : false;
const DataComponent = step?.data as React.ElementType;
const SummeryComponent = step?.summery as React.ElementType;
diff --git a/ui/src/context/app/app.interface.ts b/ui/src/context/app/app.interface.ts
index d17692ba0..8d4ca95d5 100644
--- a/ui/src/context/app/app.interface.ts
+++ b/ui/src/context/app/app.interface.ts
@@ -137,8 +137,8 @@ interface FieldTypes {
value: string;
}
interface locales {
- code:string;
- name:string
+ code: string;
+ name: string;
}
export interface ILegacyCms {
selectedCms: ICMSType;
@@ -181,7 +181,7 @@ export interface IDropDown {
value: string;
default?: boolean;
master_locale: string;
- locales:locales[];
+ locales: locales[];
created_at: string;
}
export interface ITestMigration {
@@ -210,7 +210,7 @@ export const DEFAULT_DROPDOWN: IDropDown = {
default: false,
uid: '',
master_locale: '',
- locales:[],
+ locales: [],
created_at: ''
};
diff --git a/ui/src/pages/Home/index.tsx b/ui/src/pages/Home/index.tsx
index 0eda36e71..03a7d1e0b 100644
--- a/ui/src/pages/Home/index.tsx
+++ b/ui/src/pages/Home/index.tsx
@@ -40,7 +40,9 @@ const Home = () => {
{cta?.title && (
-
+
)}
diff --git a/ui/src/pages/Login/index.scss b/ui/src/pages/Login/index.scss
index 723468031..2c93376fd 100644
--- a/ui/src/pages/Login/index.scss
+++ b/ui/src/pages/Login/index.scss
@@ -184,6 +184,6 @@
}
.send-sms {
span {
- line-height: 1!important;
+ line-height: 1 !important;
}
}
diff --git a/ui/src/pages/Login/index.tsx b/ui/src/pages/Login/index.tsx
index 0e0ca279b..15061ad48 100644
--- a/ui/src/pages/Login/index.tsx
+++ b/ui/src/pages/Login/index.tsx
@@ -19,10 +19,7 @@ import {
TFA_VIA_SMS_MESSAGE,
CS_ENTRIES
} from '../../utilities/constants';
-import {
- failtureNotification,
- setDataInLocalStorage
-} from '../../utilities/functions';
+import { failtureNotification, setDataInLocalStorage } from '../../utilities/functions';
// API Service
import { getCMSDataFromFile } from '../../cmsData/cmsSelector';
@@ -59,7 +56,11 @@ const Login: FC = () => {
const { login, two_factor_authentication: twoFactorAuthentication } = data;
- const accountData = { heading: data?.heading, subtitle: data?.subtitle, copyrightText: data?.copyrightText };
+ const accountData = {
+ heading: data?.heading,
+ subtitle: data?.subtitle,
+ copyrightText: data?.copyrightText
+ };
// ************* Context Here ************
const { setAuthToken, setIsAuthenticated } = useContext(AppContext);
@@ -73,7 +74,6 @@ const Login: FC = () => {
// Get the region
const urlParams = new URLSearchParams(location?.search);
const region = urlParams?.get?.('region');
-
// ************* send SMS token ************
const sendSMS = async () => {
@@ -186,7 +186,9 @@ const Login: FC = () => {
{loginStates?.tfa ? (
- {twoFactorAuthentication?.title &&
{twoFactorAuthentication?.title}
}
+ {twoFactorAuthentication?.title && (
+
{twoFactorAuthentication?.title}
+ )}
= () => {
className="mb-2"
version="v2"
htmlFor="tfa_token"
- aria-label="tfa_token"
-
+ aria-label="tfa_token"
>
{twoFactorAuthentication?.security_code?.title}
@@ -231,9 +232,11 @@ const Login: FC = () => {
- {twoFactorAuthentication?.send_sms?.pre_link_text &&
-
{twoFactorAuthentication?.send_sms?.pre_link_text}
- }
+ {twoFactorAuthentication?.send_sms?.pre_link_text && (
+
+ {twoFactorAuthentication?.send_sms?.pre_link_text}
+
+ )}
{twoFactorAuthentication?.send_sms?.link_text && (
= () => {
) : (
- {login?.title && (
-
{login?.title}
- )}
-
+ {login?.title &&
{login?.title}
}
+
{
diff --git a/ui/src/pages/Projects/index.tsx b/ui/src/pages/Projects/index.tsx
index af100a145..6e1017805 100644
--- a/ui/src/pages/Projects/index.tsx
+++ b/ui/src/pages/Projects/index.tsx
@@ -16,6 +16,7 @@ import { validateObject } from '../../utilities/functions';
// Interfaces
import { ProjectsType, ProjectsObj } from './projects.interface';
import { ModalObj } from '../../components/Modal/modal.interface';
+import { CTA } from '../Home/home.interface';
// Context
import { AppContext } from '../../context/app/app.context';
@@ -30,7 +31,6 @@ import { NO_PROJECTS, NO_PROJECTS_SEARCH } from '../../common/assets';
// styles
import './index.scss';
-import { CTA } from '../Home/home.interface';
const Projects = () => {
const [data, setData] = useState({});
@@ -44,7 +44,6 @@ const Projects = () => {
const outputIntro = HTMLReactParser(jsonToHtml(emptystate?.description ?? {}));
- // const history = useHistory();
const location = useLocation();
const queryParams = new URLSearchParams(location.search);
const search = (queryParams.get('search') ?? '').trim();
@@ -85,9 +84,6 @@ const Projects = () => {
}, []);
useEffect(() => {
- // navigate({
- // search: searchText ? `?region=${newParam}?search=${searchText}` : `?region=${newParam}`
- // });
setLoadStatus(true);
if (searchText) {
setProjects(
@@ -139,17 +135,15 @@ const Projects = () => {
const header = {
component: (
- <>
-
- >
+
)
};
@@ -162,27 +156,15 @@ const Projects = () => {
))}
- ) : projects && projects?.length > 0 ? (
+ ) : (
projects?.map((e) => (
))
- ) : projects && projects?.length > 0 && !searchText ? (
-
{emptystate?.empty_search_heading}}
- img={NO_PROJECTS_SEARCH}
- description={
-
- {HTMLReactParser(jsonToHtml(emptystate?.empty_search_description ?? {}))}
-
- }
- version="v2"
- className="no_results_found_page"
- testId="no-results-found-page"
- />
- ) : (
+ )}
+
+ {projects && projects?.length === 0 && !searchText && (
{
))}
)}
+
+ {projects && projects?.length === 0 && searchText && (
+
{emptystate?.empty_search_heading} }
+ img={NO_PROJECTS_SEARCH}
+ description={
+
+ {HTMLReactParser(jsonToHtml(emptystate?.empty_search_description ?? {}))}
+
+ }
+ version="v2"
+ className="no_results_found_page"
+ testId="no-results-found-page"
+ />
+ )}
)
};
diff --git a/ui/src/pages/RegionalLogin/index.tsx b/ui/src/pages/RegionalLogin/index.tsx
index 3bf266e6f..2af72a937 100644
--- a/ui/src/pages/RegionalLogin/index.tsx
+++ b/ui/src/pages/RegionalLogin/index.tsx
@@ -87,9 +87,7 @@ const RegionalLogin = () => {
{region?.service_title}
)}
- {region?.region_title && (
-
{region?.region_title}
- )}
+ {region?.region_title &&
{region?.region_title}
}
{region?.cta?.title && (
diff --git a/ui/src/scss/App.scss b/ui/src/scss/App.scss
index 1e24a7b4b..dd608e09c 100644
--- a/ui/src/scss/App.scss
+++ b/ui/src/scss/App.scss
@@ -282,8 +282,9 @@ body {
color: $color-font-base;
font-family: $font-family-primary;
line-height: 1.3rem;
- span, p {
- line-height: $line-height-default!important;
+ span,
+ p {
+ line-height: $line-height-default !important;
}
}
h1,
@@ -296,7 +297,7 @@ h6 {
}
p {
color: $color-font-gray;
- line-height: $line-height-default!important;
+ line-height: $line-height-default !important;
margin: 0;
}
h1 {
@@ -337,13 +338,32 @@ h2 {
.PageLayout__head__hamburger {
display: none;
}
+ .PageLayout__head {
+ & > .PageHeader {
+ padding-right: $px-20;
+ }
+ }
}
}
-.ReactModal__Overlay .ReactModal__Content .ReactModal__Content__header h3 {
- color: $color-black-2121;
- font-weight: bold;
+.ReactModal__Overlay {
+ .ReactModal__Content {
+ .ReactModal__Content__header h3 {
+ color: $color-black-2121;
+ font-weight: bold;
+ }
+ }
}
-.ReactModal__Content__footer .Button{
+.ReactModal__Content__footer .Button {
font-size: 1rem;
line-height: 100%;
-}
\ No newline at end of file
+}
+
+::-webkit-input-placeholder {
+ color: $color-black-2121 !important;
+}
+::-ms-input-placeholder {
+ color: $color-black-2121 !important;
+}
+::placeholder {
+ color: $color-black-2121 !important;
+}
diff --git a/ui/src/scss/_variables.scss b/ui/src/scss/_variables.scss
index 1d8442b82..e8e0e4ab6 100644
--- a/ui/src/scss/_variables.scss
+++ b/ui/src/scss/_variables.scss
@@ -29,7 +29,6 @@ $color-font-gray: #637392;
$color-black-2121: #212121;
$color-black-222: #222222;
-
$font-family-primary: 'Inter', sans-serif;
$font-family-secondary: 'Montserrat', sans-serif;
@@ -93,6 +92,7 @@ $px-32: 2rem; // 32px
$px-35: 2.188rem; // 36px
$px-36: 2.25rem; // 36px
$px-40: 2.5rem; // 40px
+$px-48: 3rem;
$px-50: 3.125rem; // 50px
$px-60: 3.75rem; // 60px
$px-70: 4.375rem; // 70px
diff --git a/ui/src/services/api/service.interface.ts b/ui/src/services/api/service.interface.ts
index 3a3fa636f..f52ef611d 100644
--- a/ui/src/services/api/service.interface.ts
+++ b/ui/src/services/api/service.interface.ts
@@ -12,7 +12,7 @@ export interface StackResponse {
name: string;
api_key: string;
master_locale: string;
- locales:[];
+ locales: [];
created_at: string;
}
diff --git a/ui/src/utilities/constants.interface.ts b/ui/src/utilities/constants.interface.ts
index c10759fdb..0089b4993 100644
--- a/ui/src/utilities/constants.interface.ts
+++ b/ui/src/utilities/constants.interface.ts
@@ -1,3 +1,3 @@
export interface ObjectType {
[key: string]: string;
-}
\ No newline at end of file
+}
diff --git a/ui/src/utilities/constants.ts b/ui/src/utilities/constants.ts
index 0a80ff568..a019a5400 100644
--- a/ui/src/utilities/constants.ts
+++ b/ui/src/utilities/constants.ts
@@ -1,4 +1,4 @@
-import { ObjectType } from './constants.interface'
+import { ObjectType } from './constants.interface';
export const BASE_API_URL = process.env.REACT_APP_BASE_API_URL;
export const assetsRelativeUrl = 'v3/assets';
export const WEBSITE_BASE_URL = process.env.REACT_APP_WEBSITE_BASE_URL;
@@ -63,8 +63,7 @@ export const UPLOAD_FILE_RELATIVE_URL = process.env.REACT_APP_UPLOAD_SERVER;
export const UPLOAD_FILE_URL = `${UPLOAD_FILE_RELATIVE_URL}upload`;
-
-export const PROJECT_STATUS:ObjectType = {
+export const PROJECT_STATUS: ObjectType = {
'0': 'Draft',
'1': 'Ready to test',
'2': 'Testing inprogress',