Skip to content

cucr/mask.js

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Mask.js

Mask.js makes it easy to add a opacity layer to DOM Element. Especially for the annoying IE bug.

Usage:

a Mask object will be automatically created and attached to window. It has 3 Public APIs:

// debug: once the `debug` method is called, the layer's value 
// 	of opacity will set to 0.6
// NOTE: make sure the method is called before `set`
Mask.debug()

// create mask for dom element(s)
Mask.set(element1, element2, ... elementN);

// remove the mask over the dom element(s)
Mask.remove(element1, element2, ... elementN);

License:

Licensed under MIT. (c) Sofish Lin

About

create an opacity mask to a(all) specific element(s)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published