From 2669aa485355c50e87bbcee21c01b330ba7b9f35 Mon Sep 17 00:00:00 2001 From: mahdi andalib Date: Wed, 11 May 2022 15:51:38 +0430 Subject: [PATCH] update src/components/Navbar/HeaderDesign1/index.js and src/components/Navbar/HeaderDesign2/index.js --- src/components/Navbar/HeaderDesign1/index.js | 2 +- src/components/Navbar/HeaderDesign2/index.js | 148 ++++++------------- 2 files changed, 45 insertions(+), 105 deletions(-) diff --git a/src/components/Navbar/HeaderDesign1/index.js b/src/components/Navbar/HeaderDesign1/index.js index a59e5c7..b4b95a6 100644 --- a/src/components/Navbar/HeaderDesign1/index.js +++ b/src/components/Navbar/HeaderDesign1/index.js @@ -127,7 +127,7 @@ HeaderDesign1.defaultProps = { ], category: false, - searchBox: false, + searchBox: true, // icons loginBtn: false, }; diff --git a/src/components/Navbar/HeaderDesign2/index.js b/src/components/Navbar/HeaderDesign2/index.js index 205b9cf..2c0112c 100644 --- a/src/components/Navbar/HeaderDesign2/index.js +++ b/src/components/Navbar/HeaderDesign2/index.js @@ -1,94 +1,36 @@ import React from "react"; - -import cartIcon from "../../../assets/icons/dark-crimson-cart-icon.svg"; -import profileIcon from "../../../assets/icons/dark-crimson-profile-icon.svg"; -import profilePic from "./profile-pic.svg"; -import downwardArrow from "./arrow-down.svg"; -import search from "./search-normal.svg"; import Switch from "../../Switch"; +import Search from "../../SearchDesign/Search"; -const HeaderDesign2 = ({ username, userJob }) => { +const HeaderDesign2 = ({ username, userJob, menuItems }) => { return ( -
- {/* {headerDivider && ( -
- )} */} -
-
- - دانوین - -
- -
-
- - محصولات - - - دسته بندی - - - تماس با ما - - - درباره ما - - - پیگیری - - - وبلاگ - -
+
+
+ {/* right side */} +
+ دانوین +
    + {menuItems.map((menuItem, index) => ( +
  • + {menuItem.item} +
    +
  • + ))} +
- -
-
+ {/* left side */}{" "} +
+
-
- - +
+
- {/*
-
- -
-
*/} - {/*

Price`}> - 140,000 - - تومان - -

*/} - {/* */} - {/* */} - - {/* */} - {/* */}
-
+

{username}

{userJob}

@@ -115,26 +57,24 @@ HeaderDesign2.defaultProps = { username: "رستم پهلوان زاده", userJob: "مدیریت سامانه هوشمند", - headerDivider: true, - - topHeader: true, - bottomHeader: true, - - menuItems: false, - category: false, - searchBox: true, - - // icons - loginBtn: true, - - whiteIconCart: false, - darkCrimsonIconCart: false, - - whiteIconHamburgerMenu: false, - darkIconHamburgerMenu: true, - - iconHolder: true, - iconProfile: false, - iconCart: true, - iconSearch: false, + menuItems: [ + { + item: "محصولات", + }, + { + item: "دسته بندی", + }, + { + item: "تماس با ما", + }, + { + item: "درباره ما", + }, + { + item: "پیگیری", + }, + { + item: "وبلاگ", + }, + ], };