fathom-modal
v1.0.6
Published
A modal concept which aims to give a sense of depth between the page and modal layers.
Downloads
4
Readme
Fathom Modal
A modal concept which aims to give a sense of depth between the page and modal layers. This package was made based on avgrund. I have rewritten it using ES6 standart and also using Stylus.
How to:
Install
Yarn: yarn add fathom-modal
NPM: npm i fathom-modal --save
Use
import Fathom from 'fathon-modal';
const app = new Fathom('#element'); //you can also pass an HTMLElement
//to show the modal
app.show();
//to hide the modal
app.hide();
//to destroy
app.destroy(); //there is no need to call app.hide()
//to disable the blur effect just call app.blur = false before app.show()
Customize
You can override .fm-cover or .fm-document classes to customize the cover and document background colors for example.