1.0.1 • Published 6 years ago
react-ui-expand v1.0.1
react-ui-expand

Install
$ npm install react-ui-expand --saveUsage
import * as React from 'react';
import { render } from 'react-dom';
import Expand from 'react-ui-expand';
const Demo = () => {
return (<Expand
className="hoge"
button={<button>Open!!</button>}
>
{(button) => {
return(<div>{button}
This Element will expand to fullscreen!!
</div>);
}}
</Expand>)
};
render(<Demo/>, document.getElementById('demo'));Props
Common props you may want to specify include:
beforeOpen- subscribe to before open eventsonOpen- subscribe to open eventsbeforeClose- subscribe to before close eventsonClose- subscribe to close eventsclassName- apply a className to the controlbutton- jsx element to trigger eventschildren- callback function to return jsx element which includes the button element
License
MIT Licensed. Copyright (c) appleple 2019.