diff --git a/src/App.js b/src/App.js
index 3f6afce..cc048ec 100644
--- a/src/App.js
+++ b/src/App.js
@@ -1,9 +1,7 @@
-import React, { useEffect } from "react";
+import React from "react";
import Footer from "./shared-components/footer-component/Footer";
import Navbar from "./shared-components/navbar-component/Navbar";
import { BrowserRouter, Route, Switch } from "react-router-dom";
-import i18next from "i18next";
-import Cookies from "js-cookie";
import HomePage from "./homePage/Homepage";
import ListingsPage from "./listings-page/ListingsPage";
import AgentPage from "./agent-page/AgentPage";
@@ -15,62 +13,9 @@ import Login from "./login-page/Login";
import Account from "./login-page/account/Account";
import ContactUs from "./shared-components/contact-us/contact-us";
-const langauges = [
- {
- code: "fr",
- name: "Français",
- country_code: "fr",
- },
- {
- code: "en",
- name: "English",
- country_code: "gb",
- },
-];
-
function App() {
- const currentLanguageCode = Cookies.get("i18next") || "en";
- const currentLanguage = langauges.find(
- (lang) => lang.code === currentLanguageCode
- );
-
- useEffect(() => {
- document.body.dir = currentLanguage.dir || "ltr";
- }, [currentLanguage]);
return (
- {/* create the translations button */}
-
diff --git a/src/login-page/Login.js b/src/login-page/Login.js
index f260a7a..276856a 100644
--- a/src/login-page/Login.js
+++ b/src/login-page/Login.js
@@ -14,14 +14,20 @@ class Login extends Component {
},
};
- handleLogin = (e) => {
- console.log(e);
- };
+ handleLogin() {
+ // if ( !== this.state.Account.email) {
+ // alert("invalid");
+ // }
+ // if (password !== this.state.Account.password) {
+ // alert("invalid");
+ // }
+ }
+
render() {
const { t } = this.props;
return (
-
-
-
+
+
diff --git a/src/login-page/account/Account.js b/src/login-page/account/Account.js
index 9097434..92ca733 100644
--- a/src/login-page/account/Account.js
+++ b/src/login-page/account/Account.js
@@ -11,6 +11,7 @@ class Account extends Component {
lastName: "Green",
email: "kevon.green@kcribs.com",
password: "Kcribs123",
+ phoneNumber: "613-234-8796",
},
};
render() {
@@ -93,7 +94,7 @@ class Account extends Component {
type="text"
class="form-control"
id="account-phoneNumber"
- placeholder={this.state.Account.email}
+ placeholder={this.state.Account.phoneNumber}
required
disabled={true}
/>
diff --git a/src/shared-components/navbar-component/Navbar.js b/src/shared-components/navbar-component/Navbar.js
index f01c618..2dd8b0b 100644
--- a/src/shared-components/navbar-component/Navbar.js
+++ b/src/shared-components/navbar-component/Navbar.js
@@ -1,11 +1,33 @@
-import React from "react";
+import React, { useEffect } from "react";
import { Link, withRouter } from "react-router-dom";
import "./Navbar.css";
import logo from "./logo2.png";
+import Cookies from "js-cookie";
/* eslint-disable jsx-a11y/anchor-is-valid */
import { useTranslation } from "react-i18next";
+import i18next from "i18next";
+const langauges = [
+ {
+ code: "fr",
+ name: "Français",
+ country_code: "fr",
+ },
+ {
+ code: "en",
+ name: "English",
+ country_code: "gb",
+ },
+];
+
const Navbar = () => {
+ const currentLanguageCode = Cookies.get("i18next") || "en";
+ const currentLanguage = langauges.find(
+ (lang) => lang.code === currentLanguageCode
+ );
const { t } = useTranslation();
+ useEffect(() => {
+ document.body.dir = currentLanguage.dir || "ltr";
+ }, [currentLanguage]);
return (
/* Nav Bar */
@@ -27,6 +49,34 @@ const Navbar = () => {
+ -
+
+
+
+
+
-
{t("Nav_Home")}