An open API service indexing awesome lists of open source software.

https://github.com/sakalx/overlay-reveal-effect

React overlay reveal effect component
https://github.com/sakalx/overlay-reveal-effect

animate animation effect overlay react reveal transition transition-animation

Last synced: 2 months ago
JSON representation

React overlay reveal effect component

Awesome Lists containing this project

README

        

# Overlay reveal effect react-component.
________________________________________________________
________________________________________________________

#### Props

| Name | Type | Default | Description |
| --- | --- | --- | --- |
| **children** | `node` | | *The content node to be showed.* |
| **direction** | `string` | *top-right* | *Direction the child node will enter from.* |
| **isOpen** | `boolean` | *false* | *If `true`, the component will transition in.* |
| **mainFon** | `string` | *#90caf9* | *The main background color.* |
| **secondaryFon** | `string` | *#ec407a* | *The secondary background color of overlay.* |
________________________________________________________
________________________________________________________

### Example
[DEMO](https://sakalx.github.io/overlay-reveal-effect/)

```javascript
import React, {useState} from 'react';
import OverlayEffect from 'overlay-reveal-effect';

class App extends React.Component {
render() {
const [open, setOpen] = useState(false);

const handleOpen = () => {
setOpen(true);
};

const handleClose = () => {
setOpen(false);
}

return (


OPEN


Overlay Effect


CLOSE


)
}
}
```