Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: add ui versioning (#28) #30

Merged
merged 2 commits into from
Mar 8, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { Dialog, Transition } from '@headlessui/react'
import { InformationCircleIcon, CheckBadgeIcon } from '@heroicons/react/24/outline'
import { usePrepareContractWrite, useContractWrite, useWaitForTransaction, useAccount, Address } from 'wagmi'
import { useRouter } from 'next/router'
import Sector3DAOPriority from '../../abis/Sector3DAOPriority.json'
import Sector3DAOPriority from '../../../abis/v0/Sector3DAOPriority.json'
import Link from 'next/link'
import { config } from '@/utils/Config'

Expand Down
2 changes: 1 addition & 1 deletion src/components/DAO.tsx → src/components/v0/DAO.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Sector3DAO from '../../abis/Sector3DAO.json'
import Sector3DAO from '../../../abis/v0/Sector3DAO.json'
import { configureChains, createClient, useAccount, useConnect, useContractRead, useContractReads, useDisconnect, WagmiConfig } from 'wagmi'
import { useIsMounted } from '@/hooks/useIsMounted'
import Image from 'next/image'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { Dialog, Transition } from '@headlessui/react'
import { InformationCircleIcon, CheckBadgeIcon } from '@heroicons/react/24/outline'
import { usePrepareContractWrite, useContractWrite, useWaitForTransaction, useAccount, Address } from 'wagmi'
import { useRouter } from 'next/router'
import Sector3DAO from '../../abis/Sector3DAO.json'
import Sector3DAO from '../../../abis/v0/Sector3DAO.json'
import Link from 'next/link'
import { config } from '@/utils/Config'
import { ethers } from 'ethers'
Expand Down
13 changes: 0 additions & 13 deletions src/pages/api/hello.ts

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@ import { chainUtils } from '@/utils/ChainUtils'
import { configureChains, createClient, useAccount, useConnect, useContractRead, useContractReads, useDisconnect, WagmiConfig } from 'wagmi'
import { InjectedConnector } from 'wagmi/connectors/injected'
import { publicProvider } from '@wagmi/core/providers/public'
import Sector3DAO from '../../../abis/Sector3DAO.json'
import Sector3DAOPriority from '../../../abis/Sector3DAOPriority.json'
import Sector3DAO from '../../../../abis/v0/Sector3DAO.json'
import Sector3DAOPriority from '../../../../abis/v0/Sector3DAOPriority.json'
import { ethers } from 'ethers'
import Link from 'next/link'
import { useRouter } from 'next/router'
import { useIsMounted } from '@/hooks/useIsMounted'
import DAO from '@/components/DAO'
import DAO from '@/components/v0/DAO'
import { useState } from 'react'
import PriorityDialog from '@/components/PriorityDialog'
import PriorityDialog from '@/components/v0/PriorityDialog'

const font = PT_Mono({ subsets: ['latin'], weight: '400' })

Expand Down Expand Up @@ -293,7 +293,7 @@ function Priority({ priorityAddress }: any ) {
Epoch budget: {priority.epochBudget} <code>$TOKEN_NAME</code> per {priority.epochDuration} days<br />
Start date: {priority.startDate}<br />

<Link href={`/priorities/${priority.address}`}>
<Link href={`/v0/priorities/${priority.address}`}>
<button className='mt-4 px-4 py-2 text-gray-200 font-semibold rounded-xl bg-gray-700 hover:bg-gray-600'>⏱️ View Epochs</button>
</Link>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ import { chainUtils } from '@/utils/ChainUtils'
import { configureChains, createClient, useAccount, useConnect, useContractRead, useContractReads, useDisconnect, WagmiConfig } from 'wagmi'
import { InjectedConnector } from 'wagmi/connectors/injected'
import { publicProvider } from '@wagmi/core/providers/public'
import Sector3DAO from '../../../abis/Sector3DAO.json'
import Sector3DAOPriority from '../../../abis/Sector3DAOPriority.json'
import Sector3DAO from '../../../../abis/v0/Sector3DAO.json'
import Sector3DAOPriority from '../../../../abis/v0/Sector3DAOPriority.json'
import { ethers } from 'ethers'
import Link from 'next/link'
import { useRouter } from 'next/router'
import { useIsMounted } from '@/hooks/useIsMounted'
import DAO from '@/components/DAO'
import DAO from '@/components/v0/DAO'

const font = PT_Mono({ subsets: ['latin'], weight: '400' })

Expand Down Expand Up @@ -318,7 +318,7 @@ function Epochs({ priorityAddress, epochIndex }: any) {
<h3 className='text-xl font-bold mb-2'>Epoch #{priority.epochIndex + 1}</h3>
From <b>{epochs[0].startDate}</b> to <b>{epochs[0].endDate}</b><br />

<Link href={`/priorities/${priority.address}/epochs/${priority.epochIndex}`}>
<Link href={`/v0/priorities/${priority.address}/epochs/${priority.epochIndex}`}>
<button className='mt-4 px-4 py-2 text-white font-semibold rounded-xl bg-gray-700 hover:bg-gray-600'>⏳ Report Contributions</button>
</Link>
</div>
Expand All @@ -343,7 +343,7 @@ function Epochs({ priorityAddress, epochIndex }: any) {
<h3 className='text-xl font-bold mb-2'>Epoch #{priority.epochIndex + 1 - index}</h3>
From <b>{epoch.startDate}</b> to <b>{epoch.endDate}</b><br />

<Link href={`/priorities/${priority.address}/epochs/${priority.epochIndex - index}`}>
<Link href={`/v0/priorities/${priority.address}/epochs/${priority.epochIndex - index}`}>
<button className='mt-4 px-4 py-2 text-white font-semibold rounded-xl bg-gray-700 hover:bg-gray-600'>⌛️ View Contributions</button>
</Link>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,16 @@ import { chainUtils } from '@/utils/ChainUtils'
import { configureChains, createClient, useAccount, useConnect, useContractRead, useContractReads, useDisconnect, WagmiConfig } from 'wagmi'
import { InjectedConnector } from 'wagmi/connectors/injected'
import { publicProvider } from '@wagmi/core/providers/public'
import Sector3DAO from '../../../../../abis/Sector3DAO.json'
import Sector3DAOPriority from '../../../../../abis/Sector3DAOPriority.json'
import Sector3DAO from '../../../../../../abis/v0/Sector3DAO.json'
import Sector3DAOPriority from '../../../../../../abis/v0/Sector3DAOPriority.json'
import { ethers } from 'ethers'
import Link from 'next/link'
import { config } from '@/utils/Config'
import { useRouter } from 'next/router'
import { useIsMounted } from '@/hooks/useIsMounted'
import ContributionDialog from '@/components/ContributionDialog'
import ContributionDialog from '@/components/v0/ContributionDialog'
import { useState } from 'react'
import DAO from '@/components/DAO'
import DAO from '@/components/v0/DAO'

const font = PT_Mono({ subsets: ['latin'], weight: '400' })

Expand Down