1.0.5 • Published 3 years ago

react-modal-comp v1.0.5

Weekly downloads
-
License
ISC
Repository
-
Last release
3 years ago

Component example

import { useState } from  'react'
import {Modal} from  'react-modal-comp'

function  App() {
	const [visible, setVisible] =  useState(false)
	return (
		<div  className="App">
			<button  onClick={() =>  setVisible(true)}>Active modal</button>
			<Modal  showModal={visible}  closeModal={() =>  setVisible(false)}  bodyClass='component-body-modal'>
				Modal box
			</Modal>
		</div>
	)
}

export  default  App

Component Props |Props|Type | Desc |---|---|---| | showModal| boolean | show/hide modal | closeModal| fn|return the action to close the modal | overlayClass| string|overlay className | bodyClass| string|body className

1.0.5

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago

0.1.0

3 years ago