Package Exports
- moving-shadow
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (moving-shadow) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
moving-shadow
A JavaScript module, which creates a responsive text shadow based on mouse position (desktop) or device orientation (mobile).
Install
Local
Download movingShadow.js
or
https://unpkg.com/moving-shadow
NPM
npm install --save moving-shadow
import movingShadow from 'movingShadow';
Usage
var shadowProp = {
selector: ".moving-one", // targets class or id
angle: 20, // Sets height of light source. Should be > 10 && < 100
diffusion: 0, // blur-radius
color: "#5af", // text-color
type: "shadow" // "shadow", "perspective"
}
movingShadow(shadowProp);
Examples
- Shadow - (source)
- Raised text with shadow - (source)
- Drop shadow - (source)