diff --git a/src/app/configs/routesConfig.js b/src/app/configs/routesConfig.js
index 1b110ba..523924a 100644
--- a/src/app/configs/routesConfig.js
+++ b/src/app/configs/routesConfig.js
@@ -6,8 +6,9 @@ import Error404Page from '../main/404/Error404Page';
import navigationPagesConfigs from '../main/navigationPages/navigationPagesConfig';
import authPagesConfigs from '../main/authPages/authPagesConfigs';
import HomeConfig from '../main/home/HomeConfig';
+import RentAndBuyConfig from '../main/rentAndBuy/RentAndBuyConfig';
-const routeConfigs = [...navigationPagesConfigs, ...authPagesConfigs, HomeConfig];
+const routeConfigs = [...navigationPagesConfigs, ...authPagesConfigs, HomeConfig, RentAndBuyConfig];
const routes = [
...FuseUtils.generateRoutesFromConfigs(routeConfigs, settingsConfig.defaultAuth),
diff --git a/src/app/main/home/components/AboutUs.js b/src/app/main/home/components/AboutUs.js
index 42ade72..19ed624 100644
--- a/src/app/main/home/components/AboutUs.js
+++ b/src/app/main/home/components/AboutUs.js
@@ -26,7 +26,7 @@ function AboutUs({ t }) {
{t('research_btn')}
diff --git a/src/app/main/home/components/Welcome.js b/src/app/main/home/components/Welcome.js
index 1275c4f..e0167b3 100644
--- a/src/app/main/home/components/Welcome.js
+++ b/src/app/main/home/components/Welcome.js
@@ -1,9 +1,11 @@
import { memo, useState } from 'react';
import { withTranslation } from 'react-i18next';
+import { useNavigate } from 'react-router-dom';
import SearchInput from '../../shared-components/SearchInput';
function Welcome({ t }) {
const [query, setQuery] = useState('');
+ const navigate = useNavigate();
const onInputType = (event) => {
const { target } = event;
@@ -12,7 +14,12 @@ function Welcome({ t }) {
};
const onSearch = () => {
- // query
+ const trimmedQuery = query.trim();
+ if (!trimmedQuery) {
+ return;
+ }
+
+ navigate(`/rent-and-buy/search?query=${trimmedQuery}`);
};
return (
diff --git a/src/app/main/rentAndBuy/RentAndBuy.js b/src/app/main/rentAndBuy/RentAndBuy.js
new file mode 100644
index 0000000..df9c796
--- /dev/null
+++ b/src/app/main/rentAndBuy/RentAndBuy.js
@@ -0,0 +1,16 @@
+import Typography from '@mui/material/Typography';
+import { withTranslation } from 'react-i18next';
+import { Outlet } from 'react-router-dom';
+
+function RentAndBuy({ t }) {
+ return (
+
+
+ {t('title')}
+
+
+
+ );
+}
+
+export default withTranslation('rentAndBuyPage')(RentAndBuy);
diff --git a/src/app/main/rentAndBuy/RentAndBuyConfig.js b/src/app/main/rentAndBuy/RentAndBuyConfig.js
new file mode 100644
index 0000000..ba3efbb
--- /dev/null
+++ b/src/app/main/rentAndBuy/RentAndBuyConfig.js
@@ -0,0 +1,38 @@
+import { lazy } from 'react';
+import i18next from 'i18next';
+
+import RentAndBuy from './RentAndBuy';
+import en from './i18n/en';
+
+i18next.addResourceBundle('en', 'rentAndBuyPage', en);
+
+const SearchAddress = lazy(() => import('./components/SearchAddress/SearchAddress'));
+const PropertyPreview = lazy(() => import('./components/PropertyPreview/PropertyPreview'));
+
+const RentAndBuyConfig = {
+ settings: {
+ layout: {
+ config: {},
+ style: 'layout2',
+ },
+ },
+ auth: null,
+ routes: [
+ {
+ path: '/rent-and-buy',
+ element: ,
+ children: [
+ {
+ path: 'search',
+ element: ,
+ },
+ {
+ path: 'preview',
+ element: ,
+ },
+ ],
+ },
+ ],
+};
+
+export default RentAndBuyConfig;
diff --git a/src/app/main/rentAndBuy/components/PropertyPreview/PropertyPreview.js b/src/app/main/rentAndBuy/components/PropertyPreview/PropertyPreview.js
new file mode 100644
index 0000000..3feef5c
--- /dev/null
+++ b/src/app/main/rentAndBuy/components/PropertyPreview/PropertyPreview.js
@@ -0,0 +1,32 @@
+import Button from '@mui/material/Button';
+import { useState } from 'react';
+import { withTranslation } from 'react-i18next';
+import RegistrationPopup from 'src/app/main/shared-components/popups/RegistrationPopup';
+
+function PropertyPreview({ t }) {
+ const [isPopupOpen, setIsPopupOpen] = useState(false);
+
+ const openPopup = () => setIsPopupOpen(true);
+ const closePopup = () => setIsPopupOpen(false);
+
+ return (
+ <>
+
+
+
+
+ >
+ );
+}
+
+export default withTranslation('rentAndBuyPage')(PropertyPreview);
diff --git a/src/app/main/rentAndBuy/components/SearchAddress/SearchAddress.js b/src/app/main/rentAndBuy/components/SearchAddress/SearchAddress.js
new file mode 100644
index 0000000..deab1ff
--- /dev/null
+++ b/src/app/main/rentAndBuy/components/SearchAddress/SearchAddress.js
@@ -0,0 +1,18 @@
+import { withTranslation } from 'react-i18next';
+import { Link } from 'react-router-dom';
+
+function SearchAddress({ t }) {
+ return (
+
+ How are you?
+
+ {t('show_btn')}
+
+
+ );
+}
+
+export default withTranslation('rentAndBuyPage')(SearchAddress);
diff --git a/src/app/main/rentAndBuy/i18n/en.js b/src/app/main/rentAndBuy/i18n/en.js
new file mode 100644
index 0000000..b0eb919
--- /dev/null
+++ b/src/app/main/rentAndBuy/i18n/en.js
@@ -0,0 +1,8 @@
+const locale = {
+ title: 'Rent&Buy Analysis',
+ show_btn: 'show',
+ see_more_btn: 'See more',
+ view: 'View the Calculation',
+};
+
+export default locale;
diff --git a/src/app/main/shared-components/PropertyAnalysisHeader.js b/src/app/main/shared-components/PropertyAnalysisHeader.js
new file mode 100644
index 0000000..4549d7f
--- /dev/null
+++ b/src/app/main/shared-components/PropertyAnalysisHeader.js
@@ -0,0 +1,11 @@
+import Paper from '@mui/material/Paper';
+
+function PropertyAnalysisHeader() {
+ return (
+
+
+
+ );
+}
+
+export default PropertyAnalysisHeader;
diff --git a/src/app/theme-layouts/layout2/components/NavLinks.js b/src/app/theme-layouts/layout2/components/NavLinks.js
index 13a3266..4804eb7 100644
--- a/src/app/theme-layouts/layout2/components/NavLinks.js
+++ b/src/app/theme-layouts/layout2/components/NavLinks.js
@@ -7,7 +7,7 @@ function NavLinks({ className }) {
return (
<>
-
+
{t('rent_and_buy')}