diff --git a/components/cartlist-card/index.js b/components/cartlist-card/index.js index 59bc297..51a3cee 100644 --- a/components/cartlist-card/index.js +++ b/components/cartlist-card/index.js @@ -63,7 +63,7 @@ export const CartCard = (props) => { .card-item { width: 100%; } - .card-bold{ + .card-bold { font-weight: bold; } .cartcard-container > img { @@ -114,12 +114,12 @@ export const CartCard = (props) => { .cartcard-container { flex-direction: column; } - .cartcard-button{ + .cartcard-button { display: flex; flex-direction: row; justify-content: space-evenly; } - .cartcard-fnbutton{ + .cartcard-fnbutton { display: flex; flex-direction: row; justify-content: space-evenly; diff --git a/constants/index.js b/constants/index.js new file mode 100644 index 0000000..453df3d --- /dev/null +++ b/constants/index.js @@ -0,0 +1,3 @@ +export const SHOP_PRODUCTS_ENDPOINT = 'http://localhost:5000/crypto/products'; +export const SOP_PRODUCT_BY_ID_ENDPOINT = + 'http://localhost:5000/crypto/products'; diff --git a/mock/products.json b/mock/products.json index 9830ae0..7e07029 100644 --- a/mock/products.json +++ b/mock/products.json @@ -1,38 +1,38 @@ -{ - "Shoe": { - "id": "Shoe", - "image": "shoes.jpeg", - "name": "Shoe", - "usage": [ - "Can be used if you are pissed of at someone", - "Can also be used to promote healthy activites" - ], - "category": "Footwear", - "manufacturer": "Ankush", - "price": 200 - }, - "Flower": { - "id": "Flower", - "image": "flowers.jpeg", - "name": "Flower", - "usage": [ - "Can be used as token of appreciation", - "Can be a good subsitute for gift" - ], - "category": "Gift", - "manufacturer": "Ankush", - "price": 300 - }, - "Coffee": { - "id": "Coffee", - "image": "coffee.jpeg", - "name": "Coffee", - "usage": [ - "Can serve as ice-breaker", - "Can be used as token of appreciation" - ], - "category": "Drink", - "manufacturer": "Ankush", - "price": 500 - } -} +[ + { + "id": "Shoe", + "image": "shoes.jpeg", + "name": "Shoe", + "usage": [ + "Can be used if you are pissed of at someone", + "Can also be used to promote healthy activites" + ], + "category": "Footwear", + "manufacturer": "Ankush", + "price": 200 + }, + { + "id": "Flower", + "image": "flowers.jpeg", + "name": "Flower", + "usage": [ + "Can be used as token of appreciation", + "Can be a good subsitute for gift" + ], + "category": "Gift", + "manufacturer": "Ankush", + "price": 300 + }, + { + "id": "Coffee", + "image": "coffee.jpeg", + "name": "Coffee", + "usage": [ + "Can serve as ice-breaker", + "Can be used as token of appreciation" + ], + "category": "Drink", + "manufacturer": "Ankush", + "price": 500 + } +] \ No newline at end of file diff --git a/package-lock.json b/package-lock.json index f236492..d322ea6 100644 --- a/package-lock.json +++ b/package-lock.json @@ -5972,6 +5972,14 @@ "integrity": "sha512-xh1Rl34h6Fi1DC2WWKfxUTVqRsNnr6LsKz2+hfwDxQJWmrx8+c7ylaqBMcHfl1U1r2dsifOvKX3LQuLNZ+XSvA==", "dev": true }, + "axios": { + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.21.1.tgz", + "integrity": "sha512-dKQiRHxGD9PPRIUNIWvZhPTPpl1rf/OxTYKsqKUDjBwYylTvV7SjSHJb9ratfyzM6wCdLCOYLzs73qpg5c4iGA==", + "requires": { + "follow-redirects": "^1.10.0" + } + }, "babel-code-frame": { "version": "6.26.0", "resolved": "https://registry.npmjs.org/babel-code-frame/-/babel-code-frame-6.26.0.tgz", @@ -10492,6 +10500,11 @@ "readable-stream": "^2.3.6" } }, + "follow-redirects": { + "version": "1.13.1", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.13.1.tgz", + "integrity": "sha512-SSG5xmZh1mkPGyKzjZP8zLjltIfpW32Y5QpdNJyjcfGxK3qo3NDDkZOZSFiGn1A6SclQxY9GzEwAHQ3dmYRWpg==" + }, "for-in": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/for-in/-/for-in-1.0.2.tgz", diff --git a/package.json b/package.json index 91382b4..ca021dd 100644 --- a/package.json +++ b/package.json @@ -16,6 +16,7 @@ }, "dependencies": { "@babel/plugin-transform-react-jsx": "^7.12.11", + "axios": "^0.21.1", "chart.js": "2.9.4", "eslint-plugin-jest": "^24.1.3", "framer-motion": "^2.9.4", diff --git a/pages/index.js b/pages/index.js index cc1ba44..e247f21 100644 --- a/pages/index.js +++ b/pages/index.js @@ -36,7 +36,7 @@ export default function Home() {
Latest Transactions
+Latest Transactions