Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

anets

henryfordstick21MIT0.2.5TypeScript support: included

JavaScript library about PPT complex animation

wipe, barn, checkerBoard, blinds, dissolve, randombar, strips, wedge, wheel, box, circle, diamon, plus, animation

readme

anets

JavaScript library about PPT complex animation. The document address.

Installation

The anets.js package lives in npm. To install the latest stable version, run the following command:

npm install anets

Or if you're using yarn:

yarn add anets

Import into your project:

import anets from 'anets';

Usage

<div id="bigImages">
  <img src="./pic.jpeg" />
</div>
const options = {
  item: '#bigImages',
  ani: {
    name: 'blindsInBOTTOM',
    duration: '2s',
  },
};

Anets.start(options, function (opts) {
  console.log(opts); // callback
});

You can use any element for the box and its elements, not just img.

Options

const anets = new Anet({
  item: '#bigImages',
  sound: 'music.mp3',
  audioElement: '#audio',
  ani: {
    cname: '百叶窗',
    name: 'blindsInBOTTOM',
    duration: '2s',
  },
  CanvasDOM: document.querySelector('canvas'),
  onStart: function (opts) {
    console.log(opts);
  },
  onEnd: function (opts) {
    console.log(opts);
  },
});

License

Anets 是 MIT 许可的