Skip to content

Commit

Permalink
changes
Browse files Browse the repository at this point in the history
  • Loading branch information
uthuth1 committed Jun 6, 2024
1 parent 7017a72 commit 8c3ee9e
Show file tree
Hide file tree
Showing 12 changed files with 35 additions and 18 deletions.
Binary file not shown.
Binary file added back-end/uploads/53585a2a150062b51d504565fad4cc10
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
20 changes: 10 additions & 10 deletions back-office/src/widgets/layout/dashboard-navbar.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -126,13 +126,13 @@ export function DashboardNavbar() {
)}

<Menu>
<MenuHandler>
{/* <MenuHandler>
<IconButton variant="text" color="blue-gray">
<BellIcon className="w-5 h-5 text-blue-gray-500" />
</IconButton>
</MenuHandler>
<MenuList className="border-0 w-max">
<MenuItem className="flex items-center gap-3">
</MenuHandler> */}
{/* <MenuList className="border-0 w-max"> */}
{/* <MenuItem className="flex items-center gap-3">
<Avatar
src="https://demos.creative-tim.com/material-dashboard/assets/img/team-2.jpg"
alt="item-1"
Expand All @@ -155,8 +155,8 @@ export function DashboardNavbar() {
<ClockIcon className="h-3.5 w-3.5" /> 13 minutes ago
</Typography>
</div>
</MenuItem>
<MenuItem className="flex items-center gap-4">
</MenuItem> */}
{/* <MenuItem className="flex items-center gap-4">
<Avatar
src="https://demos.creative-tim.com/material-dashboard/assets/img/small-logos/logo-spotify.svg"
alt="item-1"
Expand All @@ -179,8 +179,8 @@ export function DashboardNavbar() {
<ClockIcon className="h-3.5 w-3.5" /> 1 day ago
</Typography>
</div>
</MenuItem>
<MenuItem className="flex items-center gap-4">
</MenuItem> */}
{/* <MenuItem className="flex items-center gap-4">
<div className="grid rounded-full h-9 w-9 place-items-center bg-gradient-to-tr from-blue-gray-800 to-blue-gray-900">
<CreditCardIcon className="w-4 h-4 text-white" />
</div>
Expand All @@ -200,8 +200,8 @@ export function DashboardNavbar() {
<ClockIcon className="h-3.5 w-3.5" /> 2 days ago
</Typography>
</div>
</MenuItem>
</MenuList>
</MenuItem> */}
{/* </MenuList> */}
</Menu>
<IconButton
variant="text"
Expand Down
5 changes: 3 additions & 2 deletions back-office/src/widgets/layout/sidenav.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,13 +54,14 @@ export function Sidenav({ brandImg, brandName, routes }) {

<IconButton
variant="text"
color="white"
color="black"
size="sm"
ripple={false}
className="absolute top-0 right-0 grid rounded-tl-none rounded-br-none xl:hidden"
onClick={() => setOpenSidenav(dispatch, false)}
>
<XMarkIcon strokeWidth={2.5} className="w-5 h-5 text-white" />
{/* hhhhhhhhh */}
<XMarkIcon strokeWidth={2.5} className="w-5 h-5 text-black" />
</IconButton>
</div>
<div className="m-4">
Expand Down
6 changes: 3 additions & 3 deletions front-store/src/Components/CartItem.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { formatPrice } from '../Utils/helpers'
import { removeItem, toggleAmount } from '../features/cartSlice'
import { useDispatch } from 'react-redux'

const CartItem = ({id,name,optionColor,amount,price}) => {
const CartItem = ({id,name,optionColor,amount,price, image}) => {
const dispatch = useDispatch()

const increase = () => {
Expand All @@ -23,8 +23,8 @@ const dispatch = useDispatch()
}
return <Wrapper>
<div className='title'>
{/* <img src={image} alt={name} /> */}
IMG
<img src={image} alt={name} />

<div>
<h5 className="name">{name} </h5>
<p className='color'>color: {optionColor}</p>
Expand Down
18 changes: 16 additions & 2 deletions front-store/src/Components/Footer.jsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React from "react";
import React, { useEffect } from "react";
import styled from "styled-components";
import {
FaPhone,
Expand All @@ -9,8 +9,15 @@ import {
} from "react-icons/fa";
import { IoMail } from "react-icons/io5";
import Logo from "./images/LogoBlack.svg";
import { Link } from "react-router-dom";

const Footer = () => {


// useEffect(()=>{
// window.scrollTo({ top: 0, behavior: "smooth" });

// },[])
return (
<Wrapper>
<section className="footer-section">
Expand Down Expand Up @@ -85,12 +92,19 @@ const Footer = () => {
<ul>
<li>
<a href="/">Home</a>


</li>
<li>
<a href="/products">Products</a>
</li>
<li>
<a href="/about">About Us</a>
<a href="/about">
About
</a>
{/* <Link to={'about'}>
About
</Link> */}
</li>
<li>
<a href="/cart">Cart</a>
Expand Down
4 changes: 3 additions & 1 deletion front-store/src/features/cartSlice.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ const cartSlice = createSlice({
addToCart: (state, action) => {
const { id, optionColor, amount, product } = action.payload;

console.log('product image card ', product)
// Generate unique identifier for each item in the cart
const itemId = `${id}-${optionColor}`;
// console.log('itemId', itemId)
Expand All @@ -50,7 +51,8 @@ const cartSlice = createSlice({
name: product.name,
optionColor,
amount,
price: product.price
price: product.price,
image:product.options[0]?.images[0]
};
return { ...state, cart: [...state.cart, newItem] };
}
Expand Down

0 comments on commit 8c3ee9e

Please sign in to comment.