diff --git a/shopping-cart/public/shopping_cart_icon.svg b/shopping-cart/public/shopping_cart_icon.svg new file mode 100644 index 0000000..0a51c8f --- /dev/null +++ b/shopping-cart/public/shopping_cart_icon.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/shopping-cart/src/Cart.jsx b/shopping-cart/src/Cart.jsx index 21d8b6c..c28826a 100644 --- a/shopping-cart/src/Cart.jsx +++ b/shopping-cart/src/Cart.jsx @@ -62,6 +62,7 @@ function OrderSummary({ cart }) {

Shipping (10%): ${currencyFormat(shippingFee)}

Total: ${currencyFormat(total)}

+ ); } @@ -71,7 +72,7 @@ function CartItem({ item, cart, setCart }) { return (
- {title} + {title}

{title}

diff --git a/shopping-cart/src/components/button.jsx b/shopping-cart/src/components/button.jsx new file mode 100644 index 0000000..5a2f319 --- /dev/null +++ b/shopping-cart/src/components/button.jsx @@ -0,0 +1,19 @@ +import PropTypes from "prop-types"; +import styles from "./button.module.css"; + +export default function Button(props) { + return ( + + ); +} + +Button.propTypes = { + onClick: PropTypes.func, + text: PropTypes.string, + styles: PropTypes.string, +}; diff --git a/shopping-cart/src/components/button.module.css b/shopping-cart/src/components/button.module.css new file mode 100644 index 0000000..553b685 --- /dev/null +++ b/shopping-cart/src/components/button.module.css @@ -0,0 +1,8 @@ +.btn { + padding: 1rem; + margin: 1rem; +} + +.action { + color: red; +} diff --git a/shopping-cart/src/components/main.jsx b/shopping-cart/src/components/main.jsx index 671b404..39aa3eb 100644 --- a/shopping-cart/src/components/main.jsx +++ b/shopping-cart/src/components/main.jsx @@ -1,6 +1,8 @@ +import Button from "./button"; +import { Link } from "react-router-dom"; import styles from "./main.module.css"; -export default function Main(props) { +export default function Main() { return (
@@ -10,13 +12,18 @@ export default function Main(props) { function Default() { return ( -
-

We help you skill up faster

+
+

+ Our products help you skill up faster +

Trying to pivot into tech? There's a lot to figure out. We can help - you navigate the path. Fast results and guaranteed growth. + you navigate the path with our products. Fast results and guaranteed + growth.

- + +
); } diff --git a/shopping-cart/src/components/main.module.css b/shopping-cart/src/components/main.module.css index f5915cd..c2dc36f 100644 --- a/shopping-cart/src/components/main.module.css +++ b/shopping-cart/src/components/main.module.css @@ -1,3 +1,10 @@ main { padding: 0 1rem; } + +.container { + display: flex; + flex-direction: column; + justify-content: start; + align-items: center; +} diff --git a/shopping-cart/src/css/cart.module.css b/shopping-cart/src/css/cart.module.css index 2630488..79d2b4d 100644 --- a/shopping-cart/src/css/cart.module.css +++ b/shopping-cart/src/css/cart.module.css @@ -34,7 +34,22 @@ .cartItem { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); - background-color: gray; + justify-items: center; + padding: 2rem 0; + position: relative; +} + +.cartItem::after { + content: ""; + position: absolute; + border-bottom: solid black; + margin: auto; + left: 0; + bottom: 0; + right: 0; + height: 1px; + width: 50%; + border-bottom: 1px solid black; } .qtybtn { @@ -47,12 +62,12 @@ margin: 0.5rem; } -.img { - width: 100%; +#img { + max-width: 100%; max-height: 300px; - vertical-align: middle; object-fit: contain; - float: left; + border-radius: 2rem; + align-self: center; } .header {