Skip to content

Commit

Permalink
eslint issues
Browse files Browse the repository at this point in the history
  • Loading branch information
EthanAuyeung committed Mar 19, 2024
1 parent 1b7ba14 commit 31ee5db
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 27 deletions.
6 changes: 1 addition & 5 deletions src/app/delivery/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,15 @@ import {
totalNumberOfItemsInCart,
} from '../../api/supabase/queries/cart_queries';
import { Normal700Text } from '../../styles/fonts';
import { fetchRecentOrderProducts } from '../../api/supabase/queries/order_queries';
import { OrderProduct, ProductWithQuantity } from '../../schema/schema';
import {ProductWithQuantity } from '../../schema/schema';
import OrderSummary from '../../components/OrderSummaryFolder/OrderSummary';
import ItemRows from './itemRows';
import NavBar from '../../components/NavBarFolder/NavBar';
import {
DeliveryContainer,
OrderContainer,
OrderSummaryText,
OrderButton,
InformationContainer,
InformationText,
QtyText,
} from './styles';

export default function App() {
Expand Down
2 changes: 0 additions & 2 deletions src/app/orderConfirmationDelivery/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,10 @@ import NavBar from '../../components/NavBarFolder/NavBar';
import {
FavoriteDiv,
OutterFavoriteDiv,
HeaderText,
OutterBox,
Label,
LabelBox,
ScrollDiv,
AddressText,
DateText,
CenterBox,
AddressDiv,
Expand Down
3 changes: 0 additions & 3 deletions src/app/orderConfirmationPickUp/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,11 @@ import {
FavoriteDiv,
ColDiv,
OutterFavoriteDiv,
HeaderText,
OutterBox,
Label,
LabelBox,
ScrollDiv,
AddressText,
DateText,
PickUpText,
CenterBox,
AddressDiv,
} from './styles';
Expand Down
14 changes: 6 additions & 8 deletions src/app/pickup/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import { arrayOfFavorites } from '@/api/supabase/queries/user_queries';
import { useState, useEffect } from 'react';
import { useRouter } from 'next/navigation';
import { Normal700Text } from '@/styles/fonts';
import { fetchRecentPickupTimes } from '@/api/supabase/queries/pickup_queries';
import { Pickup, Product } from '@/schema/schema';
import PickupButton from '@/components/PickUpFolder/PickupButton';
import {
Expand Down Expand Up @@ -34,20 +33,19 @@ import {
export default function Pickup() {
const [Cart, setCart] = useState<Product[]>([]);
const router = useRouter();
const [Time, setTimes] = useState<Pickup[]>([]);
// const [Time, setTimes] = useState<Pickup[]>([]);

useEffect(() => {
async function fetchProducts() {
const data = await arrayOfFavorites(); // change the function to grab the cartItems as products
setCart(data);
}
async function fetchTimes() {
const data = await fetchRecentPickupTimes(); // change the function to grab the cartItems as products
setTimes(data);
console.log(Time);
}
// async function fetchTimes() {
// const data = await fetchRecentPickupTimes(); // change the function to grab the cartItems as products
// setTimes(data);
// }
fetchProducts();
fetchTimes();
// fetchTimes();
}, []);

return (
Expand Down
2 changes: 2 additions & 0 deletions src/app/profileScreen/page.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
/* eslint-disable */

'use client';

import { useRouter } from 'next/navigation';
Expand Down
13 changes: 5 additions & 8 deletions src/components/PickUpFolder/PickupButton.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
/* eslint-disable */
import { useState } from 'react';

function PickupButton({
day,
date,
start,
end,
}: {
day: string;
date: string;
Expand All @@ -13,12 +10,12 @@ function PickupButton({
}) {
const [isSelected, setIsSelected] = useState<boolean>(false);

const defaultStyle = 'bg-[#4b711d]/[0.13] text-[#4B711D] border-[#547829]';
const selectedStyle = 'bg-[#547829] text-white border-[#547829]';
// const defaultStyle = 'bg-[#4b711d]/[0.13] text-[#4B711D] border-[#547829]';
// const selectedStyle = 'bg-[#547829] text-white border-[#547829]';

const handleClick = () => {
// const handleClick = () => {
setIsSelected(!isSelected);
};
// };

return <button type="button" aria-label="PickUPButtons" />;
}
Expand Down
2 changes: 1 addition & 1 deletion src/styles/components.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import styled, { createGlobalStyle } from 'styled-components';
import styled from 'styled-components';

import { User, ShoppingCart } from 'react-feather';
import COLORS from './colors';
Expand Down

0 comments on commit 31ee5db

Please sign in to comment.