Skip to content

Commit

Permalink
chore: minor cleanup, more clean up needed
Browse files Browse the repository at this point in the history
  • Loading branch information
sajald77 committed Aug 21, 2024
1 parent 7ed022a commit fc18f70
Show file tree
Hide file tree
Showing 14 changed files with 7 additions and 176 deletions.
2 changes: 0 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@
"emoji-picker-react": "^4.9.3",
"express": "^4.19.2",
"fast-deep-equal": "^3.1.3",
"file-saver": "^2.0.5",
"framer-motion": "^11.2.6",
"get-video-id": "^4.1.5",
"graphql": "^16.9.0",
Expand Down Expand Up @@ -148,7 +147,6 @@
"@testing-library/react-hooks": "^8.0.1",
"@testing-library/user-event": "^14.4.3",
"@types/dompurify": "^3.0.2",
"@types/file-saver": "^2",
"@types/loadable__component": "^5.13.4",
"@types/luxon": "^3.2.0",
"@types/node": "^18.11.18",
Expand Down
2 changes: 0 additions & 2 deletions src/api/airtable.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
// api.airtable.com/v0/appyM7XlNIWVypuP5/Featured%20Project?maxRecords=3&view=Grid%20view

import { VITE_APP_AIR_TABLE_KEY } from '@/shared/constants/config/env'

const AIRTABLE_API = 'https://api.airtable.com/v0/appyM7XlNIWVypuP5'
Expand Down
Binary file removed src/assets/medalFirst.png
Binary file not shown.
Binary file removed src/assets/medalSecond.png
Binary file not shown.
Binary file removed src/assets/medalThird.png
Binary file not shown.
5 changes: 0 additions & 5 deletions src/components/molecules/index.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,3 @@
export * from '../../modules/project/pages1/projectFunding/views/fundingInit/sections/DonationInput'
export * from '../../modules/project/pages1/projectView/views/rewards/components/UpdateCurrencyModal'
export * from '../../shared/molecules/CalendarButton'
export * from '../../shared/molecules/CreatorEmailButton'
export * from '../../shared/molecules/FileUpload'
export * from './AddSponsor'
export * from './AmountInputWithSatoshiToggle'
export * from './AppFooter'
Expand Down
23 changes: 0 additions & 23 deletions src/config/apollo-client/apolloClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -107,29 +107,6 @@ const splitLink = split(
const clientConfig: ApolloClientOptions<NormalizedCacheObject> = {
link: from([retryLink, splitLink]),
cache,
// resolvers: {
// Mutation: {
// ProjectRewardCreate(_, data, { cache }) {
// const reward = data?.projectRewardCreate

// cache.writeQuery({
// query: QUERY_PROJECT_REWARD,
// data: {
// __typename: 'ProjectReward',
// getProjectReward: reward,
// },
// })

// cache.modify({
// fields: {
// projectRewardsGet(existingRewards = []) {
// return [reward, ...existingRewards]
// },
// },
// })
// },
// },
// },
}

export const client = new ApolloClient(clientConfig)
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import { Box } from '@chakra-ui/react'
import { useState } from 'react'

import { FileUpload } from '@/shared/molecules'

import { AddPictureIcon } from '../../../../../components/icons/svg/AddPictureIcon'
import { FileUpload } from '../../../../../components/molecules'
import { ImageWithReload } from '../../../../../components/ui'
import Loader from '../../../../../components/ui/Loader'
import { getRandomOrb } from '../../../../../utils'
Expand Down
2 changes: 1 addition & 1 deletion src/modules/project/forms/ProjectForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import { PiInfo } from 'react-icons/pi'

import { Body } from '@/shared/components/typography'
import { validateImageUrl } from '@/shared/markdown/validations/image'
import { FileUpload } from '@/shared/molecules'

import { FileUpload } from '../../../components/molecules'
import { TextArea, TextInputBox, UploadBox } from '../../../components/ui'
import { useAuthContext } from '../../../context'
import { FieldContainer } from '../../../shared/components/form/FieldContainer'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ import { useMemo } from 'react'
import { useForm } from 'react-hook-form'
import { useTranslation } from 'react-i18next'

import { UpdateCurrencyModal } from '@/components/molecules'
import { useProjectAPI } from '@/modules/project/API/useProjectAPI'
import { useProjectAtom } from '@/modules/project/hooks/useProjectAtom'
import { UpdateCurrencyModal } from '@/modules/project/pages1/projectView/views/rewards/components'
import { FieldContainer } from '@/shared/components/form'
import { useModal } from '@/shared/hooks'
import { RewardCurrency } from '@/types'
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import { useCallback, useEffect, useState } from 'react'
import { PiArrowLeft, PiImages } from 'react-icons/pi'
import { Link, useLocation, useNavigate, useParams } from 'react-router-dom'

import { FileUpload } from '@/components/molecules'
import { AlertDialogue } from '@/components/molecules/AlertDialogue'
import { ImageWithReload, TextArea } from '@/components/ui'
import Loader from '@/components/ui/Loader'
Expand All @@ -14,6 +13,7 @@ import { CardLayout, SkeletonLayout } from '@/shared/components/layouts'
import { Body, H1 } from '@/shared/components/typography'
import { dimensions, getPath, ProjectEntryValidations } from '@/shared/constants'
import { useModal } from '@/shared/hooks'
import { FileUpload } from '@/shared/molecules'
import { ImageCropAspectRatio } from '@/shared/molecules/ImageCropperModal'
import { Entry, EntryStatus } from '@/types'
import { isActive, useCustomTheme, useNotification } from '@/utils'
Expand Down
3 changes: 2 additions & 1 deletion src/shared/markdown/components/ImageField.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import { FormControl } from '@chakra-ui/react'
import { Control, Controller, FieldValue } from 'react-hook-form'

import { FileUpload } from '../../../components/molecules'
import { FileUpload } from '@/shared/molecules'

import { UploadBox } from '../../../components/ui'
import { FieldContainer } from '../../components/form/FieldContainer'

Expand Down
16 changes: 0 additions & 16 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -11242,13 +11242,6 @@ __metadata:
languageName: node
linkType: hard

"@types/file-saver@npm:^2":
version: 2.0.7
resolution: "@types/file-saver@npm:2.0.7"
checksum: 10c0/c6b88a1aea8eec58469da2a90828fef6e9d5d590c7094fb959783d7c32878af80d39439734f3d41b78355dadb507f606e3d04a29a160c85411c65251e58df847
languageName: node
linkType: hard

"@types/filesystem@npm:*":
version: 0.0.32
resolution: "@types/filesystem@npm:0.0.32"
Expand Down Expand Up @@ -17269,13 +17262,6 @@ __metadata:
languageName: node
linkType: hard

"file-saver@npm:^2.0.5":
version: 2.0.5
resolution: "file-saver@npm:2.0.5"
checksum: 10c0/0a361f683786c34b2574aea53744cb70d0a6feb0fa5e3af00f2fcb6c9d40d3049cc1470e38c6c75df24219f247f6fb3076f86943958f580e62ee2ffe897af8b1
languageName: node
linkType: hard

"file-selector@npm:^0.6.0":
version: 0.6.0
resolution: "file-selector@npm:0.6.0"
Expand Down Expand Up @@ -17900,7 +17886,6 @@ __metadata:
"@testing-library/react-hooks": "npm:^8.0.1"
"@testing-library/user-event": "npm:^14.4.3"
"@types/dompurify": "npm:^3.0.2"
"@types/file-saver": "npm:^2"
"@types/loadable__component": "npm:^5.13.4"
"@types/luxon": "npm:^3.2.0"
"@types/node": "npm:^18.11.18"
Expand Down Expand Up @@ -17944,7 +17929,6 @@ __metadata:
eslint-plugin-testing-library: "npm:^5.10.0"
express: "npm:^4.19.2"
fast-deep-equal: "npm:^3.1.3"
file-saver: "npm:^2.0.5"
framer-motion: "npm:^11.2.6"
get-video-id: "npm:^4.1.5"
graphql: "npm:^16.9.0"
Expand Down

0 comments on commit fc18f70

Please sign in to comment.