Socket
Socket
Sign inDemoInstall

d3-selection

Package Overview
Dependencies
Maintainers
1
Versions
58
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

d3-selection - npm Package Compare versions

Comparing version 0.6.10 to 0.6.11

2

build/bundle.js

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

var version = "0.6.10"; export * from "../index"; export {version};
var version = "0.6.11"; export * from "../index"; export {version};

@@ -7,5 +7,7 @@ (function (global, factory) {

var xhtml = "http://www.w3.org/1999/xhtml";
var namespaces = {
svg: "http://www.w3.org/2000/svg",
xhtml: "http://www.w3.org/1999/xhtml",
xhtml: xhtml,
xlink: "http://www.w3.org/1999/xlink",

@@ -26,5 +28,5 @@ xml: "http://www.w3.org/XML/1998/namespace",

uri = this.namespaceURI;
return uri && uri !== document.documentElement.namespaceURI
? document.createElementNS(uri, name)
: document.createElement(name);
return uri === xhtml && document.documentElement.namespaceURI === xhtml
? document.createElement(name)
: document.createElementNS(uri, name);
};

@@ -925,3 +927,3 @@ }

var version = "0.6.10";
var version = "0.6.11";

@@ -928,0 +930,0 @@ exports.version = version;

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

!function(t,n){"object"==typeof exports&&"undefined"!=typeof module?n(exports):"function"==typeof define&&define.amd?define(["exports"],n):n(t.d3_selection={})}(this,function(t){"use strict";function n(t){var n=t+="",e=n.indexOf(":");return e>=0&&"xmlns"!==(n=t.slice(0,e))&&(t=t.slice(e+1)),Vt.hasOwnProperty(n)?{space:Vt[n],local:t}:t}function e(t){return function(){var n=this.ownerDocument,e=this.namespaceURI;return e&&e!==n.documentElement.namespaceURI?n.createElementNS(e,t):n.createElement(t)}}function r(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function i(t){var i=n(t);return(i.local?r:e)(i)}function u(t,n,e){return t=o(t,n,e),function(n){var e=n.relatedTarget;e&&(e===this||8&e.compareDocumentPosition(this))||t.call(this,n)}}function o(n,e,r){return function(i){var u=t.event;t.event=i;try{n.call(this,this.__data__,e,r)}finally{t.event=u}}}function s(t){return t.trim().split(/^|\s+/).map(function(t){var n="",e=t.indexOf(".");return e>=0&&(n=t.slice(e+1),t=t.slice(0,e)),{type:t,name:n}})}function a(t){return function(){var n=this.__on;if(n){for(var e,r=0,i=-1,u=n.length;u>r;++r)e=n[r],t.type&&e.type!==t.type||e.name!==t.name?n[++i]=e:this.removeEventListener(e.type,e.listener,e.capture);++i?n.length=i:delete this.__on}}}function c(t,n,e){var r=It.hasOwnProperty(t.type)?u:o;return function(i,u,o){var s,a=this.__on,c=r(n,u,o);if(a)for(var l=0,f=a.length;f>l;++l)if((s=a[l]).type===t.type&&s.name===t.name)return this.removeEventListener(s.type,s.listener,s.capture),this.addEventListener(s.type,s.listener=c,s.capture=e),void(s.value=n);this.addEventListener(t.type,c,e),s={type:t.type,name:t.name,value:n,listener:c,capture:e},a?a.push(s):this.__on=[s]}}function l(t,n,e){var r,i,u=s(t+""),o=u.length;{if(!(arguments.length<2)){for(l=n?c:a,null==e&&(e=!1),r=0;o>r;++r)this.each(l(u[r],n,e));return this}var l=this.node().__on;if(l)for(var f,h=0,p=l.length;p>h;++h)for(r=0,f=l[h];o>r;++r)if((i=u[r]).type===f.type&&i.name===f.name)return f.value}}function f(){for(var n,e=t.event;n=e.sourceEvent;)e=n;return e}function h(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function p(t){return function(){return this.querySelector(t)}}function m(t){"function"!=typeof t&&(t=p(t));for(var n=this._groups,e=this._update,r=n.length,i=new Array(r),u=0;r>u;++u)for(var o,s,a=n[u],c=a.length,l=i[u]=new Array(c),f=0;c>f;++f)(o=a[f])&&(s=t.call(o,o.__data__,f,a))&&("__data__"in o&&(s.__data__=o.__data__),e&&(e._groups[u][f]=s),l[f]=s);return new Tt(i,this._parents)}function _(t){return function(){return this.querySelectorAll(t)}}function d(t){"function"!=typeof t&&(t=_(t));for(var n=this._groups,e=n.length,r=[],i=[],u=0;e>u;++u)for(var o,s=n[u],a=s.length,c=0;a>c;++c)(o=s[c])&&(r.push(t.call(o,o.__data__,c,s)),i.push(o));return new Tt(r,i)}function v(t){"function"!=typeof t&&(t=Ht(t));for(var n=this._groups,e=n.length,r=new Array(e),i=0;e>i;++i)for(var u,o=n[i],s=o.length,a=r[i]=[],c=0;s>c;++c)(u=o[c])&&t.call(u,u.__data__,c,o)&&a.push(u);return new Tt(r,this._parents)}function g(t){return function(){return t}}function y(t,n,e,r,i,u){for(var o,s=0,a=n.length,c=u.length;c>s;++s)(o=n[s])?(o.__data__=u[s],r[s]=o):e[s]=new x(t,u[s]);for(;a>s;++s)(o=n[s])&&(i[s]=o)}function w(t,n,e,r,i,u,o){var s,a,c,l={},f=n.length,h=u.length,p=new Array(f);for(s=0;f>s;++s)(a=n[s])&&(p[s]=c=Yt+o.call(a,a.__data__,s,n),l[c]||(l[c]=a));for(s=0;h>s;++s)c=Yt+o.call(t,u[s],s,u),(a=l[c])?a!==!0&&(r[s]=a,a.__data__=u[s]):e[s]=new x(t,u[s]),l[c]=!0;for(s=0;f>s;++s)(a=n[s])&&l[p[s]]!==!0&&(i[s]=a)}function A(t,n){if(!t)return p=new Array(this.size()),c=-1,this.each(function(t){p[++c]=t}),p;var e=n?w:y,r=this._parents,i=this._groups;"function"!=typeof t&&(t=g(t));for(var u=i.length,o=new Array(u),s=new Array(u),a=new Array(u),c=0;u>c;++c){var l=r[c],f=i[c],h=f.length,p=t.call(l,l&&l.__data__,c,r),m=p.length,_=s[c]=new Array(m),d=o[c]=new Array(m),v=a[c]=new Array(h);e(l,f,_,d,v,p,n);for(var A,x,S=0,b=0;m>S;++S)if(A=_[S]){for(S>=b&&(b=S+1);!(x=d[b])&&++b<m;);A._next=x||null}}return this._groups=o,(this._enter=new Tt(s,r))._update=this,this._exit=new Tt(a,r),this}function x(t,n){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=n}function S(t){return new Array(t.length)}function b(){var t=this._enter;return t?(this._enter=null,t):(t=new Tt(this._groups.map(S),this._parents),t._update=this,t)}function E(){var t=this._exit;return t?(this._exit=null,t):new Tt(this._groups.map(S),this._parents)}function C(){for(var t=this._groups,n=-1,e=t.length;++n<e;)for(var r,i=t[n],u=i.length-1,o=i[u];--u>=0;)(r=i[u])&&(o&&o!==r.nextSibling&&o.parentNode.insertBefore(r,o),o=r);return this}function N(t){function n(n,e){return n&&e?t(n.__data__,e.__data__):!n-!e}t||(t=T);for(var e=this._groups,r=e.length,i=this._groups=new Array(r),u=0;r>u;++u){for(var o,s=e[u],a=s.length,c=i[u]=new Array(a),l=0;a>l;++l)(o=s[l])&&(c[l]=o);c.sort(n)}return this.order()}function T(t,n){return n>t?-1:t>n?1:t>=n?0:NaN}function L(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}function M(){var t=new Array(this.size()),n=-1;return this.each(function(){t[++n]=this}),t}function P(){for(var t=this._groups,n=0,e=t.length;e>n;++n)for(var r=t[n],i=0,u=r.length;u>i;++i){var o=r[i];if(o)return o}return null}function q(){var t=0;return this.each(function(){++t}),t}function B(){return!this.node()}function D(t){for(var n=this._groups,e=0,r=n.length;r>e;++e)for(var i,u=n[e],o=0,s=u.length;s>o;++o)(i=u[o])&&t.call(i,i.__data__,o,u);return this}function O(t){return function(){this.removeAttribute(t)}}function V(t){return function(){this.removeAttributeNS(t.space,t.local)}}function R(t,n){return function(){this.setAttribute(t,n)}}function X(t,n){return function(){this.setAttributeNS(t.space,t.local,n)}}function z(t,n){return function(){var e=n.apply(this,arguments);null==e?this.removeAttribute(t):this.setAttribute(t,e)}}function H(t,n){return function(){var e=n.apply(this,arguments);null==e?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,e)}}function I(t,e){var r=n(t);if(arguments.length<2){var i=this.node();return r.local?i.getAttributeNS(r.space,r.local):i.getAttribute(r)}return this.each((null==e?r.local?V:O:"function"==typeof e?r.local?H:z:r.local?X:R)(r,e))}function U(t){return function(){this.style.removeProperty(t)}}function Y(t,n,e){return function(){this.style.setProperty(t,n,e)}}function j(t,n,e){return function(){var r=n.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,e)}}function k(t,n,e){var r;return arguments.length>1?this.each((null==n?U:"function"==typeof n?j:Y)(t,n,null==e?"":e)):h(r=this.node()).getComputedStyle(r,null).getPropertyValue(t)}function G(t){return function(){delete this[t]}}function K(t,n){return function(){this[t]=n}}function W(t,n){return function(){var e=n.apply(this,arguments);null==e?delete this[t]:this[t]=e}}function $(t,n){return arguments.length>1?this.each((null==n?G:"function"==typeof n?W:K)(t,n)):this.node()[t]}function F(t){return t.trim().split(/^|\s+/)}function J(t){return t.classList||new Q(t)}function Q(t){this._node=t,this._names=F(t.getAttribute("class")||"")}function Z(t,n){for(var e=J(t),r=-1,i=n.length;++r<i;)e.add(n[r])}function tt(t,n){for(var e=J(t),r=-1,i=n.length;++r<i;)e.remove(n[r])}function nt(t){return function(){Z(this,t)}}function et(t){return function(){tt(this,t)}}function rt(t,n){return function(){(n.apply(this,arguments)?Z:tt)(this,t)}}function it(t,n){var e=F(t+"");if(arguments.length<2){for(var r=J(this.node()),i=-1,u=e.length;++i<u;)if(!r.contains(e[i]))return!1;return!0}return this.each(("function"==typeof n?rt:n?nt:et)(e,n))}function ut(){this.textContent=""}function ot(t){return function(){this.textContent=t}}function st(t){return function(){var n=t.apply(this,arguments);this.textContent=null==n?"":n}}function at(t){return arguments.length?this.each(null==t?ut:("function"==typeof t?st:ot)(t)):this.node().textContent}function ct(){this.innerHTML=""}function lt(t){return function(){this.innerHTML=t}}function ft(t){return function(){var n=t.apply(this,arguments);this.innerHTML=null==n?"":n}}function ht(t){return arguments.length?this.each(null==t?ct:("function"==typeof t?ft:lt)(t)):this.node().innerHTML}function pt(){this.parentNode.appendChild(this)}function mt(){return this.each(pt)}function _t(){this.parentNode.insertBefore(this,this.parentNode.firstChild)}function dt(){return this.each(_t)}function vt(t){return function(){return this.appendChild(t.apply(this,arguments))}}function gt(t,n){return function(){return this.insertBefore(t.apply(this,arguments),n.apply(this,arguments)||null)}}function yt(){return null}function wt(t,n){var e="function"==typeof t?t:i(t);return this.select(arguments.length<2?vt(e):gt(e,null==n?yt:"function"==typeof n?n:p(n)))}function At(){var t=this.parentNode;t&&t.removeChild(this)}function xt(){return this.each(At)}function St(t){return arguments.length?this.property("__data__",t):this.node().__data__}function bt(t,n,e){var r=h(t),i=r.CustomEvent;i?i=new i(n,e):(i=r.document.createEvent("Event"),e?(i.initEvent(n,e.bubbles,e.cancelable),i.detail=e.detail):i.initEvent(n,!1,!1)),t.dispatchEvent(i)}function Et(t,n){return function(){return bt(this,t,n)}}function Ct(t,n){return function(){return bt(this,t,n.apply(this,arguments))}}function Nt(t,n){return this.each(("function"==typeof n?Ct:Et)(t,n))}function Tt(t,n){this._groups=t,this._parents=n}function Lt(){return new Tt([[document.documentElement]],jt)}function Mt(t){return"string"==typeof t?new Tt([[document.querySelector(t)]],[document.documentElement]):new Tt([[t]],jt)}function Pt(t,n){var e=t.ownerSVGElement||t;if(e.createSVGPoint){var r=e.createSVGPoint();if(0>kt){var i=h(t);if(i.scrollX||i.scrollY){e=Mt(i.document.body).append("svg").style({position:"absolute",top:0,left:0,margin:0,padding:0,border:"none"},"important");var u=e.node().getScreenCTM();kt=!(u.f||u.e),e.remove()}}return kt?(r.x=n.pageX,r.y=n.pageY):(r.x=n.clientX,r.y=n.clientY),r=r.matrixTransform(t.getScreenCTM().inverse()),[r.x,r.y]}var o=t.getBoundingClientRect();return[n.clientX-o.left-t.clientLeft,n.clientY-o.top-t.clientTop]}function qt(t,n){return null==n&&(n=f()),n.changedTouches&&(n=n.changedTouches[0]),Pt(t,n)}function Bt(t){return"string"==typeof t?new Tt([document.querySelectorAll(t)],[document.documentElement]):new Tt([t],jt)}function Dt(t,n,e){arguments.length<3&&(e=n,n=f().changedTouches);for(var r,i=0,u=n?n.length:0;u>i;++i)if((r=n[i]).identifier===e)return Pt(t,r);return null}function Ot(t,n){null==n&&(n=f().touches);for(var e=0,r=n?n.length:0,i=new Array(r);r>e;++e)i[e]=Pt(t,n[e]);return i}var Vt={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},Rt=function(t){return function(){return this.matches(t)}};if("undefined"!=typeof document){var Xt=document.documentElement;if(!Xt.matches){var zt=Xt.webkitMatchesSelector||Xt.msMatchesSelector||Xt.mozMatchesSelector||Xt.oMatchesSelector;Rt=function(t){return function(){return zt.call(this,t)}}}}var Ht=Rt,It={};if(t.event=null,"undefined"!=typeof document){var Ut=document.documentElement;"onmouseenter"in Ut||(It={mouseenter:"mouseover",mouseleave:"mouseout"})}var Yt="$";x.prototype={appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,n){return this._parent.insertBefore(t,n)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}},Q.prototype={add:function(t){var n=this._names.indexOf(t);0>n&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var n=this._names.indexOf(t);n>=0&&(this._names.splice(n,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var jt=[null];Tt.prototype=Lt.prototype={select:m,selectAll:d,filter:v,data:A,enter:b,exit:E,order:C,sort:N,call:L,nodes:M,node:P,size:q,empty:B,each:D,attr:I,style:k,property:$,classed:it,text:at,html:ht,raise:mt,lower:dt,append:wt,remove:xt,datum:St,on:l,dispatch:Nt};var kt="undefined"!=typeof navigator&&/WebKit/.test(navigator.userAgent)?-1:0,Gt="0.6.10";t.version=Gt,t.creator=i,t.matcher=Ht,t.mouse=qt,t.namespace=n,t.namespaces=Vt,t.select=Mt,t.selectAll=Bt,t.selection=Lt,t.selector=p,t.selectorAll=_,t.touch=Dt,t.touches=Ot,t.window=h});
!function(t,n){"object"==typeof exports&&"undefined"!=typeof module?n(exports):"function"==typeof define&&define.amd?define(["exports"],n):n(t.d3_selection={})}(this,function(t){"use strict";function n(t){var n=t+="",e=n.indexOf(":");return e>=0&&"xmlns"!==(n=t.slice(0,e))&&(t=t.slice(e+1)),Rt.hasOwnProperty(n)?{space:Rt[n],local:t}:t}function e(t){return function(){var n=this.ownerDocument,e=this.namespaceURI;return e===Vt&&n.documentElement.namespaceURI===Vt?n.createElement(t):n.createElementNS(e,t)}}function r(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function i(t){var i=n(t);return(i.local?r:e)(i)}function u(t,n,e){return t=o(t,n,e),function(n){var e=n.relatedTarget;e&&(e===this||8&e.compareDocumentPosition(this))||t.call(this,n)}}function o(n,e,r){return function(i){var u=t.event;t.event=i;try{n.call(this,this.__data__,e,r)}finally{t.event=u}}}function s(t){return t.trim().split(/^|\s+/).map(function(t){var n="",e=t.indexOf(".");return e>=0&&(n=t.slice(e+1),t=t.slice(0,e)),{type:t,name:n}})}function a(t){return function(){var n=this.__on;if(n){for(var e,r=0,i=-1,u=n.length;u>r;++r)e=n[r],t.type&&e.type!==t.type||e.name!==t.name?n[++i]=e:this.removeEventListener(e.type,e.listener,e.capture);++i?n.length=i:delete this.__on}}}function c(t,n,e){var r=Ut.hasOwnProperty(t.type)?u:o;return function(i,u,o){var s,a=this.__on,c=r(n,u,o);if(a)for(var l=0,f=a.length;f>l;++l)if((s=a[l]).type===t.type&&s.name===t.name)return this.removeEventListener(s.type,s.listener,s.capture),this.addEventListener(s.type,s.listener=c,s.capture=e),void(s.value=n);this.addEventListener(t.type,c,e),s={type:t.type,name:t.name,value:n,listener:c,capture:e},a?a.push(s):this.__on=[s]}}function l(t,n,e){var r,i,u=s(t+""),o=u.length;{if(!(arguments.length<2)){for(l=n?c:a,null==e&&(e=!1),r=0;o>r;++r)this.each(l(u[r],n,e));return this}var l=this.node().__on;if(l)for(var f,h=0,p=l.length;p>h;++h)for(r=0,f=l[h];o>r;++r)if((i=u[r]).type===f.type&&i.name===f.name)return f.value}}function f(){for(var n,e=t.event;n=e.sourceEvent;)e=n;return e}function h(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function p(t){return function(){return this.querySelector(t)}}function m(t){"function"!=typeof t&&(t=p(t));for(var n=this._groups,e=this._update,r=n.length,i=new Array(r),u=0;r>u;++u)for(var o,s,a=n[u],c=a.length,l=i[u]=new Array(c),f=0;c>f;++f)(o=a[f])&&(s=t.call(o,o.__data__,f,a))&&("__data__"in o&&(s.__data__=o.__data__),e&&(e._groups[u][f]=s),l[f]=s);return new Tt(i,this._parents)}function _(t){return function(){return this.querySelectorAll(t)}}function d(t){"function"!=typeof t&&(t=_(t));for(var n=this._groups,e=n.length,r=[],i=[],u=0;e>u;++u)for(var o,s=n[u],a=s.length,c=0;a>c;++c)(o=s[c])&&(r.push(t.call(o,o.__data__,c,s)),i.push(o));return new Tt(r,i)}function v(t){"function"!=typeof t&&(t=It(t));for(var n=this._groups,e=n.length,r=new Array(e),i=0;e>i;++i)for(var u,o=n[i],s=o.length,a=r[i]=[],c=0;s>c;++c)(u=o[c])&&t.call(u,u.__data__,c,o)&&a.push(u);return new Tt(r,this._parents)}function g(t){return function(){return t}}function y(t,n,e,r,i,u){for(var o,s=0,a=n.length,c=u.length;c>s;++s)(o=n[s])?(o.__data__=u[s],r[s]=o):e[s]=new x(t,u[s]);for(;a>s;++s)(o=n[s])&&(i[s]=o)}function w(t,n,e,r,i,u,o){var s,a,c,l={},f=n.length,h=u.length,p=new Array(f);for(s=0;f>s;++s)(a=n[s])&&(p[s]=c=jt+o.call(a,a.__data__,s,n),l[c]||(l[c]=a));for(s=0;h>s;++s)c=jt+o.call(t,u[s],s,u),(a=l[c])?a!==!0&&(r[s]=a,a.__data__=u[s]):e[s]=new x(t,u[s]),l[c]=!0;for(s=0;f>s;++s)(a=n[s])&&l[p[s]]!==!0&&(i[s]=a)}function A(t,n){if(!t)return p=new Array(this.size()),c=-1,this.each(function(t){p[++c]=t}),p;var e=n?w:y,r=this._parents,i=this._groups;"function"!=typeof t&&(t=g(t));for(var u=i.length,o=new Array(u),s=new Array(u),a=new Array(u),c=0;u>c;++c){var l=r[c],f=i[c],h=f.length,p=t.call(l,l&&l.__data__,c,r),m=p.length,_=s[c]=new Array(m),d=o[c]=new Array(m),v=a[c]=new Array(h);e(l,f,_,d,v,p,n);for(var A,x,S=0,b=0;m>S;++S)if(A=_[S]){for(S>=b&&(b=S+1);!(x=d[b])&&++b<m;);A._next=x||null}}return this._groups=o,(this._enter=new Tt(s,r))._update=this,this._exit=new Tt(a,r),this}function x(t,n){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=n}function S(t){return new Array(t.length)}function b(){var t=this._enter;return t?(this._enter=null,t):(t=new Tt(this._groups.map(S),this._parents),t._update=this,t)}function E(){var t=this._exit;return t?(this._exit=null,t):new Tt(this._groups.map(S),this._parents)}function C(){for(var t=this._groups,n=-1,e=t.length;++n<e;)for(var r,i=t[n],u=i.length-1,o=i[u];--u>=0;)(r=i[u])&&(o&&o!==r.nextSibling&&o.parentNode.insertBefore(r,o),o=r);return this}function N(t){function n(n,e){return n&&e?t(n.__data__,e.__data__):!n-!e}t||(t=T);for(var e=this._groups,r=e.length,i=this._groups=new Array(r),u=0;r>u;++u){for(var o,s=e[u],a=s.length,c=i[u]=new Array(a),l=0;a>l;++l)(o=s[l])&&(c[l]=o);c.sort(n)}return this.order()}function T(t,n){return n>t?-1:t>n?1:t>=n?0:NaN}function L(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}function M(){var t=new Array(this.size()),n=-1;return this.each(function(){t[++n]=this}),t}function P(){for(var t=this._groups,n=0,e=t.length;e>n;++n)for(var r=t[n],i=0,u=r.length;u>i;++i){var o=r[i];if(o)return o}return null}function q(){var t=0;return this.each(function(){++t}),t}function B(){return!this.node()}function D(t){for(var n=this._groups,e=0,r=n.length;r>e;++e)for(var i,u=n[e],o=0,s=u.length;s>o;++o)(i=u[o])&&t.call(i,i.__data__,o,u);return this}function O(t){return function(){this.removeAttribute(t)}}function V(t){return function(){this.removeAttributeNS(t.space,t.local)}}function R(t,n){return function(){this.setAttribute(t,n)}}function X(t,n){return function(){this.setAttributeNS(t.space,t.local,n)}}function z(t,n){return function(){var e=n.apply(this,arguments);null==e?this.removeAttribute(t):this.setAttribute(t,e)}}function H(t,n){return function(){var e=n.apply(this,arguments);null==e?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,e)}}function I(t,e){var r=n(t);if(arguments.length<2){var i=this.node();return r.local?i.getAttributeNS(r.space,r.local):i.getAttribute(r)}return this.each((null==e?r.local?V:O:"function"==typeof e?r.local?H:z:r.local?X:R)(r,e))}function U(t){return function(){this.style.removeProperty(t)}}function Y(t,n,e){return function(){this.style.setProperty(t,n,e)}}function j(t,n,e){return function(){var r=n.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,e)}}function k(t,n,e){var r;return arguments.length>1?this.each((null==n?U:"function"==typeof n?j:Y)(t,n,null==e?"":e)):h(r=this.node()).getComputedStyle(r,null).getPropertyValue(t)}function G(t){return function(){delete this[t]}}function K(t,n){return function(){this[t]=n}}function W(t,n){return function(){var e=n.apply(this,arguments);null==e?delete this[t]:this[t]=e}}function $(t,n){return arguments.length>1?this.each((null==n?G:"function"==typeof n?W:K)(t,n)):this.node()[t]}function F(t){return t.trim().split(/^|\s+/)}function J(t){return t.classList||new Q(t)}function Q(t){this._node=t,this._names=F(t.getAttribute("class")||"")}function Z(t,n){for(var e=J(t),r=-1,i=n.length;++r<i;)e.add(n[r])}function tt(t,n){for(var e=J(t),r=-1,i=n.length;++r<i;)e.remove(n[r])}function nt(t){return function(){Z(this,t)}}function et(t){return function(){tt(this,t)}}function rt(t,n){return function(){(n.apply(this,arguments)?Z:tt)(this,t)}}function it(t,n){var e=F(t+"");if(arguments.length<2){for(var r=J(this.node()),i=-1,u=e.length;++i<u;)if(!r.contains(e[i]))return!1;return!0}return this.each(("function"==typeof n?rt:n?nt:et)(e,n))}function ut(){this.textContent=""}function ot(t){return function(){this.textContent=t}}function st(t){return function(){var n=t.apply(this,arguments);this.textContent=null==n?"":n}}function at(t){return arguments.length?this.each(null==t?ut:("function"==typeof t?st:ot)(t)):this.node().textContent}function ct(){this.innerHTML=""}function lt(t){return function(){this.innerHTML=t}}function ft(t){return function(){var n=t.apply(this,arguments);this.innerHTML=null==n?"":n}}function ht(t){return arguments.length?this.each(null==t?ct:("function"==typeof t?ft:lt)(t)):this.node().innerHTML}function pt(){this.parentNode.appendChild(this)}function mt(){return this.each(pt)}function _t(){this.parentNode.insertBefore(this,this.parentNode.firstChild)}function dt(){return this.each(_t)}function vt(t){return function(){return this.appendChild(t.apply(this,arguments))}}function gt(t,n){return function(){return this.insertBefore(t.apply(this,arguments),n.apply(this,arguments)||null)}}function yt(){return null}function wt(t,n){var e="function"==typeof t?t:i(t);return this.select(arguments.length<2?vt(e):gt(e,null==n?yt:"function"==typeof n?n:p(n)))}function At(){var t=this.parentNode;t&&t.removeChild(this)}function xt(){return this.each(At)}function St(t){return arguments.length?this.property("__data__",t):this.node().__data__}function bt(t,n,e){var r=h(t),i=r.CustomEvent;i?i=new i(n,e):(i=r.document.createEvent("Event"),e?(i.initEvent(n,e.bubbles,e.cancelable),i.detail=e.detail):i.initEvent(n,!1,!1)),t.dispatchEvent(i)}function Et(t,n){return function(){return bt(this,t,n)}}function Ct(t,n){return function(){return bt(this,t,n.apply(this,arguments))}}function Nt(t,n){return this.each(("function"==typeof n?Ct:Et)(t,n))}function Tt(t,n){this._groups=t,this._parents=n}function Lt(){return new Tt([[document.documentElement]],kt)}function Mt(t){return"string"==typeof t?new Tt([[document.querySelector(t)]],[document.documentElement]):new Tt([[t]],kt)}function Pt(t,n){var e=t.ownerSVGElement||t;if(e.createSVGPoint){var r=e.createSVGPoint();if(0>Gt){var i=h(t);if(i.scrollX||i.scrollY){e=Mt(i.document.body).append("svg").style({position:"absolute",top:0,left:0,margin:0,padding:0,border:"none"},"important");var u=e.node().getScreenCTM();Gt=!(u.f||u.e),e.remove()}}return Gt?(r.x=n.pageX,r.y=n.pageY):(r.x=n.clientX,r.y=n.clientY),r=r.matrixTransform(t.getScreenCTM().inverse()),[r.x,r.y]}var o=t.getBoundingClientRect();return[n.clientX-o.left-t.clientLeft,n.clientY-o.top-t.clientTop]}function qt(t,n){return null==n&&(n=f()),n.changedTouches&&(n=n.changedTouches[0]),Pt(t,n)}function Bt(t){return"string"==typeof t?new Tt([document.querySelectorAll(t)],[document.documentElement]):new Tt([t],kt)}function Dt(t,n,e){arguments.length<3&&(e=n,n=f().changedTouches);for(var r,i=0,u=n?n.length:0;u>i;++i)if((r=n[i]).identifier===e)return Pt(t,r);return null}function Ot(t,n){null==n&&(n=f().touches);for(var e=0,r=n?n.length:0,i=new Array(r);r>e;++e)i[e]=Pt(t,n[e]);return i}var Vt="http://www.w3.org/1999/xhtml",Rt={svg:"http://www.w3.org/2000/svg",xhtml:Vt,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},Xt=function(t){return function(){return this.matches(t)}};if("undefined"!=typeof document){var zt=document.documentElement;if(!zt.matches){var Ht=zt.webkitMatchesSelector||zt.msMatchesSelector||zt.mozMatchesSelector||zt.oMatchesSelector;Xt=function(t){return function(){return Ht.call(this,t)}}}}var It=Xt,Ut={};if(t.event=null,"undefined"!=typeof document){var Yt=document.documentElement;"onmouseenter"in Yt||(Ut={mouseenter:"mouseover",mouseleave:"mouseout"})}var jt="$";x.prototype={appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,n){return this._parent.insertBefore(t,n)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}},Q.prototype={add:function(t){var n=this._names.indexOf(t);0>n&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var n=this._names.indexOf(t);n>=0&&(this._names.splice(n,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var kt=[null];Tt.prototype=Lt.prototype={select:m,selectAll:d,filter:v,data:A,enter:b,exit:E,order:C,sort:N,call:L,nodes:M,node:P,size:q,empty:B,each:D,attr:I,style:k,property:$,classed:it,text:at,html:ht,raise:mt,lower:dt,append:wt,remove:xt,datum:St,on:l,dispatch:Nt};var Gt="undefined"!=typeof navigator&&/WebKit/.test(navigator.userAgent)?-1:0,Kt="0.6.11";t.version=Kt,t.creator=i,t.matcher=It,t.mouse=qt,t.namespace=n,t.namespaces=Rt,t.select=Mt,t.selectAll=Bt,t.selection=Lt,t.selector=p,t.selectorAll=_,t.touch=Dt,t.touches=Ot,t.window=h});
{
"name": "d3-selection",
"version": "0.6.10",
"version": "0.6.11",
"description": "Data-driven DOM manipulation: select elements and join them to data.",

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

import namespace from "./namespace";
import {xhtml} from "./namespaces";

@@ -7,5 +8,5 @@ function creatorInherit(name) {

uri = this.namespaceURI;
return uri && uri !== document.documentElement.namespaceURI
? document.createElementNS(uri, name)
: document.createElement(name);
return uri === xhtml && document.documentElement.namespaceURI === xhtml
? document.createElement(name)
: document.createElementNS(uri, name);
};

@@ -12,0 +13,0 @@ }

@@ -0,4 +1,6 @@

export var xhtml = "http://www.w3.org/1999/xhtml";
export default {
svg: "http://www.w3.org/2000/svg",
xhtml: "http://www.w3.org/1999/xhtml",
xhtml: xhtml,
xlink: "http://www.w3.org/1999/xlink",

@@ -5,0 +7,0 @@ xml: "http://www.w3.org/XML/1998/namespace",

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