Skip to content

Commit

Permalink
chore: merge
Browse files Browse the repository at this point in the history
  • Loading branch information
beyond009 committed May 5, 2024
1 parent 8f399e8 commit e5431ea
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 62 deletions.
4 changes: 0 additions & 4 deletions src/components/ProjectDetailCard/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,6 @@ export function ProjectDetailCard({ setIsOpen }: ProjectCardProps) {
},
});

<<<<<<< HEAD
=======
const setIsOpen = useStakeModalStore((state) => state.setIsOpen);
>>>>>>> 3b715a99e57775ccecead4a5c5fdc36657b34c78

const statusText = useMemo(() => {
if (!poolInfo) return 'Not started';
Expand Down
55 changes: 19 additions & 36 deletions src/components/StakeModal/index.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
'use client';

import { Dialog, Transition } from '@headlessui/react'
import { Fragment } from 'react'
import { Dialog, Transition } from '@headlessui/react';
import { Fragment } from 'react';
import { StakeTokenInput } from './StakeTokenInput/index.js';

import { StakeTokenInput } from '@/components/StakeModal/StakeTokenInput/index.js'

interface StakeModalProps {
isOpen: boolean
Expand All @@ -12,7 +12,13 @@ interface StakeModalProps {
export function StakeModal({ isOpen, setIsOpen }: StakeModalProps) {
return (
<Transition appear show={isOpen} as={Fragment}>
<Dialog as="div" className="relative z-50" onClose={() => { setIsOpen(false) }}>
<Dialog
as="div"
className="relative z-50"
onClose={() => {
setIsOpen(false);
}}
>
<Transition.Child
as={Fragment}
enter="ease-out duration-300"
Expand All @@ -36,36 +42,13 @@ export function StakeModal({ isOpen, setIsOpen }: StakeModalProps) {
leaveFrom="opacity-100 scale-100"
leaveTo="opacity-0 scale-95"
>
<Transition.Child
as={Fragment}
enter="ease-out duration-300"
enterFrom="opacity-0"
enterTo="opacity-100"
leave="ease-in duration-200"
leaveFrom="opacity-100"
leaveTo="opacity-0"
>
<div className="fixed inset-0 bg-black/25" />
</Transition.Child>

<div className="fixed inset-0 overflow-y-auto">
<div className="flex min-h-full items-center justify-center p-4 text-center">
<Transition.Child
as={Fragment}
enter="ease-out duration-300"
enterFrom="opacity-0 scale-95"
enterTo="opacity-100 scale-100"
leave="ease-in duration-200"
leaveFrom="opacity-100 scale-100"
leaveTo="opacity-0 scale-95"
>
<Dialog.Panel className="z-[999] w-full max-w-[630px] transform overflow-hidden rounded-2xl bg-neutrals8 p-[24px] text-left align-middle shadow-xl transition-all">
<StakeTokenInput onClose={() => setIsOpen(false)} />
</Dialog.Panel>
</Transition.Child>
</div>
</div>
</Dialog>
</Transition>
);
<Dialog.Panel className="z-[999] w-full max-w-[630px] transform overflow-hidden rounded-2xl bg-neutrals8 p-[24px] text-left align-middle shadow-xl transition-all">
<StakeTokenInput onClose={() => setIsOpen(false)} />
</Dialog.Panel>
</Transition.Child>
</div>
</div>
</Dialog>
</Transition>
);
}
22 changes: 0 additions & 22 deletions src/store/useStakeModalStore.ts

This file was deleted.

0 comments on commit e5431ea

Please sign in to comment.