Added x button to modal dialogs Issue #20
This commit is contained in:
parent
da01ac10bb
commit
8fc56f011b
3 changed files with 22 additions and 1 deletions
|
@ -1,5 +1,6 @@
|
|||
import { Fragment } from 'react'
|
||||
import { Dialog, Transition } from '@headlessui/react'
|
||||
import { XCircleIcon } from '@heroicons/react/outline'
|
||||
|
||||
type Props = {
|
||||
isOpen: boolean
|
||||
|
@ -44,6 +45,12 @@ export const AboutModal = ({ isOpen, handleClose }: Props) => {
|
|||
leaveTo="opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95"
|
||||
>
|
||||
<div className="inline-block align-bottom bg-white rounded-lg px-4 pt-5 pb-4 text-left overflow-hidden shadow-xl transform transition-all sm:my-8 sm:align-middle sm:max-w-sm sm:w-full sm:p-6">
|
||||
<div className="absolute right-4 top-4">
|
||||
<XCircleIcon
|
||||
className="h-6 w-6 cursor-pointer"
|
||||
onClick={() => handleClose()}
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
<div className="text-center">
|
||||
<Dialog.Title
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
import { Fragment } from 'react'
|
||||
import { Dialog, Transition } from '@headlessui/react'
|
||||
import { Cell } from '../grid/Cell'
|
||||
import { XCircleIcon } from '@heroicons/react/outline'
|
||||
|
||||
type Props = {
|
||||
isOpen: boolean
|
||||
|
@ -45,6 +46,12 @@ export const InfoModal = ({ isOpen, handleClose }: Props) => {
|
|||
leaveTo="opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95"
|
||||
>
|
||||
<div className="inline-block align-bottom bg-white rounded-lg px-4 pt-5 pb-4 text-left overflow-hidden shadow-xl transform transition-all sm:my-8 sm:align-middle sm:max-w-sm sm:w-full sm:p-6">
|
||||
<div className="absolute right-4 top-4">
|
||||
<XCircleIcon
|
||||
className="h-6 w-6 cursor-pointer"
|
||||
onClick={() => handleClose()}
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
<div className="text-center">
|
||||
<Dialog.Title
|
||||
|
|
|
@ -3,6 +3,7 @@ import { Dialog, Transition } from '@headlessui/react'
|
|||
import { CheckIcon } from '@heroicons/react/outline'
|
||||
import { MiniGrid } from '../mini-grid/MiniGrid'
|
||||
import { shareStatus } from '../../lib/share'
|
||||
import { XCircleIcon } from '@heroicons/react/outline'
|
||||
|
||||
type Props = {
|
||||
isOpen: boolean
|
||||
|
@ -54,6 +55,12 @@ export const WinModal = ({
|
|||
leaveTo="opacity-0 translate-y-4 sm:translate-y-0 sm:scale-95"
|
||||
>
|
||||
<div className="inline-block align-bottom bg-white rounded-lg px-4 pt-5 pb-4 text-left overflow-hidden shadow-xl transform transition-all sm:my-8 sm:align-middle sm:max-w-sm sm:w-full sm:p-6">
|
||||
<div className="absolute right-4 top-4">
|
||||
<XCircleIcon
|
||||
className="h-6 w-6 cursor-pointer"
|
||||
onClick={() => handleClose()}
|
||||
/>
|
||||
</div>
|
||||
<div>
|
||||
<div className="mx-auto flex items-center justify-center h-12 w-12 rounded-full bg-green-100">
|
||||
<CheckIcon
|
||||
|
|
Loading…
Add table
Reference in a new issue