source: node_modules/d3-transition/src/transition/delay.js

Last change on this file was e4c61dd, checked in by istevanoska <ilinastevanoska@…>, 6 months ago

Prototype 1.1

  • Property mode set to 100644
File size: 513 bytes
RevLine 
[e4c61dd]1import {get, init} from "./schedule.js";
2
3function delayFunction(id, value) {
4 return function() {
5 init(this, id).delay = +value.apply(this, arguments);
6 };
7}
8
9function delayConstant(id, value) {
10 return value = +value, function() {
11 init(this, id).delay = value;
12 };
13}
14
15export default function(value) {
16 var id = this._id;
17
18 return arguments.length
19 ? this.each((typeof value === "function"
20 ? delayFunction
21 : delayConstant)(id, value))
22 : get(this.node(), id).delay;
23}
Note: See TracBrowser for help on using the repository browser.