Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

d3-timer

Package Overview
Dependencies
Maintainers
1
Versions
35
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

d3-timer - npm Package Compare versions

Comparing version 0.5.0 to 0.5.1

9

build/d3-timer.js

@@ -1,2 +0,2 @@

// https://d3js.org/d3-timer/ Version 0.5.0. Copyright 2016 Mike Bostock.
// https://d3js.org/d3-timer/ Version 0.5.1. Copyright 2016 Mike Bostock.
(function (global, factory) {

@@ -93,9 +93,10 @@ typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :

function nap() {
var t0, t1 = taskHead, time = Infinity;
var t0, t1 = taskHead, t2, time = Infinity;
while (t1) {
if (t1._call) {
if (time > t1._time) time = t1._time;
t1 = (t0 = t1)._next;
t0 = t1, t1 = t1._next;
} else {
t1 = t0 ? t0._next = t1._next : taskHead = t1._next;
t2 = t1._next, t1._next = null;
t1 = t0 ? t0._next = t2 : taskHead = t2;
}

@@ -102,0 +103,0 @@ }

@@ -1,2 +0,2 @@

// https://d3js.org/d3-timer/ Version 0.5.0. Copyright 2016 Mike Bostock.
!function(t,n){"object"==typeof exports&&"undefined"!=typeof module?n(exports):"function"==typeof define&&define.amd?define(["exports"],n):n(t.d3=t.d3||{})}(this,function(t){"use strict";function n(){return x||(F(e),x=b.now()+w)}function e(){x=0}function i(){this._call=this._time=this._next=null}function o(t,n,e){var o=new i;return o.restart(t,n,e),o}function r(){n(),++p;for(var t,e=m;e;)(t=x-e._time)>=0&&e._call.call(null,t),e=e._next;--p}function u(t){x=(d=t||b.now())+w,p=h=0;try{r()}finally{p=0,l(),x=0}}function c(){var t=b.now(),n=t-d;n>y&&(w-=n,d=t)}function l(){for(var t,n=m,e=1/0;n;)n._call?(e>n._time&&(e=n._time),n=(t=n)._next):n=t?t._next=n._next:m=n._next;_=t,a(e)}function a(t){if(!p){h&&(h=clearTimeout(h));var n=t-x;n>24?(1/0>t&&(h=setTimeout(u,n)),v&&(v=clearInterval(v))):(v||(v=setInterval(c,y)),p=1,F(u))}}function f(t,n,e){var o=new i;return n=null==n?0:+n,o.restart(function(e){o.stop(),t(e+n)},n,e),o}function s(t,e,o){var r=new i,u=e;return null==e?(r.restart(t,e,o),r):(e=+e,o=null==o?n():+o,r.restart(function c(n){n+=u,r.restart(c,u+=e,o),t(n)},e,o),r)}var m,_,p=0,h=0,v=0,y=1e3,d=0,x=0,w=0,b="object"==typeof performance?performance:Date,F="function"==typeof requestAnimationFrame?b===Date?function(t){requestAnimationFrame(function(){t(b.now())})}:requestAnimationFrame:function(t){setTimeout(t,17)};i.prototype=o.prototype={constructor:i,restart:function(t,e,i){if("function"!=typeof t)throw new TypeError("callback is not a function");i=(null==i?n():+i)+(null==e?0:+e),this._next||_===this||(_?_._next=this:m=this,_=this),this._call=t,this._time=i,a()},stop:function(){this._call&&(this._call=null,this._time=1/0,a())}},t.now=n,t.timer=o,t.timerFlush=r,t.timeout=f,t.interval=s,Object.defineProperty(t,"__esModule",{value:!0})});
// https://d3js.org/d3-timer/ Version 0.5.1. Copyright 2016 Mike Bostock.
!function(t,n){"object"==typeof exports&&"undefined"!=typeof module?n(exports):"function"==typeof define&&define.amd?define(["exports"],n):n(t.d3=t.d3||{})}(this,function(t){"use strict";function n(){return x||(F(e),x=b.now()+w)}function e(){x=0}function i(){this._call=this._time=this._next=null}function o(t,n,e){var o=new i;return o.restart(t,n,e),o}function r(){n(),++p;for(var t,e=m;e;)(t=x-e._time)>=0&&e._call.call(null,t),e=e._next;--p}function u(t){x=(d=t||b.now())+w,p=h=0;try{r()}finally{p=0,c(),x=0}}function l(){var t=b.now(),n=t-d;n>y&&(w-=n,d=t)}function c(){for(var t,n,e=m,i=1/0;e;)e._call?(i>e._time&&(i=e._time),t=e,e=e._next):(n=e._next,e._next=null,e=t?t._next=n:m=n);_=t,a(i)}function a(t){if(!p){h&&(h=clearTimeout(h));var n=t-x;n>24?(1/0>t&&(h=setTimeout(u,n)),v&&(v=clearInterval(v))):(v||(v=setInterval(l,y)),p=1,F(u))}}function f(t,n,e){var o=new i;return n=null==n?0:+n,o.restart(function(e){o.stop(),t(e+n)},n,e),o}function s(t,e,o){var r=new i,u=e;return null==e?(r.restart(t,e,o),r):(e=+e,o=null==o?n():+o,r.restart(function l(n){n+=u,r.restart(l,u+=e,o),t(n)},e,o),r)}var m,_,p=0,h=0,v=0,y=1e3,d=0,x=0,w=0,b="object"==typeof performance?performance:Date,F="function"==typeof requestAnimationFrame?b===Date?function(t){requestAnimationFrame(function(){t(b.now())})}:requestAnimationFrame:function(t){setTimeout(t,17)};i.prototype=o.prototype={constructor:i,restart:function(t,e,i){if("function"!=typeof t)throw new TypeError("callback is not a function");i=(null==i?n():+i)+(null==e?0:+e),this._next||_===this||(_?_._next=this:m=this,_=this),this._call=t,this._time=i,a()},stop:function(){this._call&&(this._call=null,this._time=1/0,a())}},t.now=n,t.timer=o,t.timerFlush=r,t.timeout=f,t.interval=s,Object.defineProperty(t,"__esModule",{value:!0})});
{
"name": "d3-timer",
"version": "0.5.0",
"version": "0.5.1",
"description": "An efficient queue capable of managing thousands of concurrent animations.",

@@ -5,0 +5,0 @@ "keywords": [

@@ -87,9 +87,10 @@ var frame = 0, // is an animation frame pending?

function nap() {
var t0, t1 = taskHead, time = Infinity;
var t0, t1 = taskHead, t2, time = Infinity;
while (t1) {
if (t1._call) {
if (time > t1._time) time = t1._time;
t1 = (t0 = t1)._next;
t0 = t1, t1 = t1._next;
} else {
t1 = t0 ? t0._next = t1._next : taskHead = t1._next;
t2 = t1._next, t1._next = null;
t1 = t0 ? t0._next = t2 : taskHead = t2;
}

@@ -96,0 +97,0 @@ }

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc