@alisaitteke/seatmap-canvas 2.6.0 → 2.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
* SOFTWARE.
|
|
23
23
|
*/
|
|
24
24
|
|
|
25
|
-
!function(t,e){t&&!t.getElementById("livereloadscript")&&((e=t.createElement("script")).async=1,e.src="//"+(self.location.host||"localhost").split(":")[0]+":35729/livereload.js?snipver=1",e.id="livereloadscript",t.getElementsByTagName("head")[0].appendChild(e))}(self.document);var SeatmapCanvas=function(){"use strict";var t="http://www.w3.org/1999/xhtml",e={svg:"http://www.w3.org/2000/svg",xhtml:t,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function n(t){var n=t+="",i=n.indexOf(":");return i>=0&&"xmlns"!==(n=t.slice(0,i))&&(t=t.slice(i+1)),e.hasOwnProperty(n)?{space:e[n],local:t}:t}function i(e){return function(){var n=this.ownerDocument,i=this.namespaceURI;return i===t&&n.documentElement.namespaceURI===t?n.createElement(e):n.createElementNS(i,e)}}function o(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function r(t){var e=n(t);return(e.local?o:i)(e)}function s(){}function a(t){return null==t?s:function(){return this.querySelector(t)}}function l(){return[]}function u(t){return null==t?l:function(){return this.querySelectorAll(t)}}function c(t){return function(){return null==(e=t.apply(this,arguments))?[]:Array.isArray(e)?e:Array.from(e);var e}}function h(t){return function(){return this.matches(t)}}function f(t){return function(e){return e.matches(t)}}var p=Array.prototype.find;function d(){return this.firstElementChild}var g=Array.prototype.filter;function m(){return Array.from(this.children)}function v(t){return new Array(t.length)}function y(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}function _(t,e,n,i,o,r){for(var s,a=0,l=e.length,u=r.length;a<u;++a)(s=e[a])?(s.__data__=r[a],i[a]=s):n[a]=new y(t,r[a]);for(;a<l;++a)(s=e[a])&&(o[a]=s)}function b(t,e,n,i,o,r,s){var a,l,u,c=new Map,h=e.length,f=r.length,p=new Array(h);for(a=0;a<h;++a)(l=e[a])&&(p[a]=u=s.call(l,l.__data__,a,e)+"",c.has(u)?o[a]=l:c.set(u,l));for(a=0;a<f;++a)u=s.call(t,r[a],a,r)+"",(l=c.get(u))?(i[a]=l,l.__data__=r[a],c.delete(u)):n[a]=new y(t,r[a]);for(a=0;a<h;++a)(l=e[a])&&c.get(p[a])===l&&(o[a]=l)}function w(t){return t.__data__}function E(t){return"object"==typeof t&&"length"in t?t:Array.from(t)}function x(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function k(t){return function(){this.removeAttribute(t)}}function M(t){return function(){this.removeAttributeNS(t.space,t.local)}}function S(t,e){return function(){this.setAttribute(t,e)}}function T(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function L(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function z(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}function C(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function A(t){return function(){this.style.removeProperty(t)}}function O(t,e,n){return function(){this.style.setProperty(t,e,n)}}function B(t,e,n){return function(){var i=e.apply(this,arguments);null==i?this.style.removeProperty(t):this.style.setProperty(t,i,n)}}function N(t,e){return t.style.getPropertyValue(e)||C(t).getComputedStyle(t,null).getPropertyValue(e)}function U(t){return function(){delete this[t]}}function V(t,e){return function(){this[t]=e}}function G(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}function I(t){return t.trim().split(/^|\s+/)}function K(t){return t.classList||new P(t)}function P(t){this._node=t,this._names=I(t.getAttribute("class")||"")}function D(t,e){for(var n=K(t),i=-1,o=e.length;++i<o;)n.add(e[i])}function j(t,e){for(var n=K(t),i=-1,o=e.length;++i<o;)n.remove(e[i])}function R(t){return function(){D(this,t)}}function $(t){return function(){j(this,t)}}function Z(t,e){return function(){(e.apply(this,arguments)?D:j)(this,t)}}function H(){this.textContent=""}function q(t){return function(){this.textContent=t}}function Y(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}function F(){this.innerHTML=""}function X(t){return function(){this.innerHTML=t}}function W(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}function J(){this.nextSibling&&this.parentNode.appendChild(this)}function Q(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function tt(){return null}function et(){var t=this.parentNode;t&&t.removeChild(this)}function nt(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function it(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function ot(t){return function(){var e=this.__on;if(e){for(var n,i=0,o=-1,r=e.length;i<r;++i)n=e[i],t.type&&n.type!==t.type||n.name!==t.name?e[++o]=n:this.removeEventListener(n.type,n.listener,n.options);++o?e.length=o:delete this.__on}}}function rt(t,e,n){return function(){var i,o=this.__on,r=function(t){return function(e){t.call(this,e,this.__data__)}}(e);if(o)for(var s=0,a=o.length;s<a;++s)if((i=o[s]).type===t.type&&i.name===t.name)return this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=r,i.options=n),void(i.value=e);this.addEventListener(t.type,r,n),i={type:t.type,name:t.name,value:e,listener:r,options:n},o?o.push(i):this.__on=[i]}}function st(t,e,n){var i=C(t),o=i.CustomEvent;"function"==typeof o?o=new o(e,n):(o=i.document.createEvent("Event"),n?(o.initEvent(e,n.bubbles,n.cancelable),o.detail=n.detail):o.initEvent(e,!1,!1)),t.dispatchEvent(o)}function at(t,e){return function(){return st(this,t,e)}}function lt(t,e){return function(){return st(this,t,e.apply(this,arguments))}}y.prototype={constructor:y,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}},P.prototype={add:function(t){this._names.indexOf(t)<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var ut=[null];function ct(t,e){this._groups=t,this._parents=e}function ht(){return new ct([[document.documentElement]],ut)}function ft(t){return"string"==typeof t?new ct([[document.querySelector(t)]],[document.documentElement]):new ct([[t]],ut)}function pt(t,e){if(t=function(t){let e;for(;e=t.sourceEvent;)t=e;return t}(t),void 0===e&&(e=t.currentTarget),e){var n=e.ownerSVGElement||e;if(n.createSVGPoint){var i=n.createSVGPoint();return i.x=t.clientX,i.y=t.clientY,[(i=i.matrixTransform(e.getScreenCTM().inverse())).x,i.y]}if(e.getBoundingClientRect){var o=e.getBoundingClientRect();return[t.clientX-o.left-e.clientLeft,t.clientY-o.top-e.clientTop]}}return[t.pageX,t.pageY]}ct.prototype=ht.prototype={constructor:ct,select:function(t){"function"!=typeof t&&(t=a(t));for(var e=this._groups,n=e.length,i=new Array(n),o=0;o<n;++o)for(var r,s,l=e[o],u=l.length,c=i[o]=new Array(u),h=0;h<u;++h)(r=l[h])&&(s=t.call(r,r.__data__,h,l))&&("__data__"in r&&(s.__data__=r.__data__),c[h]=s);return new ct(i,this._parents)},selectAll:function(t){t="function"==typeof t?c(t):u(t);for(var e=this._groups,n=e.length,i=[],o=[],r=0;r<n;++r)for(var s,a=e[r],l=a.length,h=0;h<l;++h)(s=a[h])&&(i.push(t.call(s,s.__data__,h,a)),o.push(s));return new ct(i,o)},selectChild:function(t){return this.select(null==t?d:function(t){return function(){return p.call(this.children,t)}}("function"==typeof t?t:f(t)))},selectChildren:function(t){return this.selectAll(null==t?m:function(t){return function(){return g.call(this.children,t)}}("function"==typeof t?t:f(t)))},filter:function(t){"function"!=typeof t&&(t=h(t));for(var e=this._groups,n=e.length,i=new Array(n),o=0;o<n;++o)for(var r,s=e[o],a=s.length,l=i[o]=[],u=0;u<a;++u)(r=s[u])&&t.call(r,r.__data__,u,s)&&l.push(r);return new ct(i,this._parents)},data:function(t,e){if(!arguments.length)return Array.from(this,w);var n,i=e?b:_,o=this._parents,r=this._groups;"function"!=typeof t&&(n=t,t=function(){return n});for(var s=r.length,a=new Array(s),l=new Array(s),u=new Array(s),c=0;c<s;++c){var h=o[c],f=r[c],p=f.length,d=E(t.call(h,h&&h.__data__,c,o)),g=d.length,m=l[c]=new Array(g),v=a[c]=new Array(g);i(h,f,m,v,u[c]=new Array(p),d,e);for(var y,x,k=0,M=0;k<g;++k)if(y=m[k]){for(k>=M&&(M=k+1);!(x=v[M])&&++M<g;);y._next=x||null}}return(a=new ct(a,o))._enter=l,a._exit=u,a},enter:function(){return new ct(this._enter||this._groups.map(v),this._parents)},exit:function(){return new ct(this._exit||this._groups.map(v),this._parents)},join:function(t,e,n){var i=this.enter(),o=this,r=this.exit();return"function"==typeof t?(i=t(i))&&(i=i.selection()):i=i.append(t+""),null!=e&&(o=e(o))&&(o=o.selection()),null==n?r.remove():n(r),i&&o?i.merge(o).order():o},merge:function(t){for(var e=t.selection?t.selection():t,n=this._groups,i=e._groups,o=n.length,r=i.length,s=Math.min(o,r),a=new Array(o),l=0;l<s;++l)for(var u,c=n[l],h=i[l],f=c.length,p=a[l]=new Array(f),d=0;d<f;++d)(u=c[d]||h[d])&&(p[d]=u);for(;l<o;++l)a[l]=n[l];return new ct(a,this._parents)},selection:function(){return this},order:function(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var i,o=t[e],r=o.length-1,s=o[r];--r>=0;)(i=o[r])&&(s&&4^i.compareDocumentPosition(s)&&s.parentNode.insertBefore(i,s),s=i);return this},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=x);for(var n=this._groups,i=n.length,o=new Array(i),r=0;r<i;++r){for(var s,a=n[r],l=a.length,u=o[r]=new Array(l),c=0;c<l;++c)(s=a[c])&&(u[c]=s);u.sort(e)}return new ct(o,this._parents).order()},call:function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},nodes:function(){return Array.from(this)},node:function(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var i=t[e],o=0,r=i.length;o<r;++o){var s=i[o];if(s)return s}return null},size:function(){let t=0;for(const e of this)++t;return t},empty:function(){return!this.node()},each:function(t){for(var e=this._groups,n=0,i=e.length;n<i;++n)for(var o,r=e[n],s=0,a=r.length;s<a;++s)(o=r[s])&&t.call(o,o.__data__,s,r);return this},attr:function(t,e){var i=n(t);if(arguments.length<2){var o=this.node();return i.local?o.getAttributeNS(i.space,i.local):o.getAttribute(i)}return this.each((null==e?i.local?M:k:"function"==typeof e?i.local?z:L:i.local?T:S)(i,e))},style:function(t,e,n){return arguments.length>1?this.each((null==e?A:"function"==typeof e?B:O)(t,e,null==n?"":n)):N(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?U:"function"==typeof e?G:V)(t,e)):this.node()[t]},classed:function(t,e){var n=I(t+"");if(arguments.length<2){for(var i=K(this.node()),o=-1,r=n.length;++o<r;)if(!i.contains(n[o]))return!1;return!0}return this.each(("function"==typeof e?Z:e?R:$)(n,e))},text:function(t){return arguments.length?this.each(null==t?H:("function"==typeof t?Y:q)(t)):this.node().textContent},html:function(t){return arguments.length?this.each(null==t?F:("function"==typeof t?W:X)(t)):this.node().innerHTML},raise:function(){return this.each(J)},lower:function(){return this.each(Q)},append:function(t){var e="function"==typeof t?t:r(t);return this.select(function(){return this.appendChild(e.apply(this,arguments))})},insert:function(t,e){var n="function"==typeof t?t:r(t),i=null==e?tt:"function"==typeof e?e:a(e);return this.select(function(){return this.insertBefore(n.apply(this,arguments),i.apply(this,arguments)||null)})},remove:function(){return this.each(et)},clone:function(t){return this.select(t?it:nt)},datum:function(t){return arguments.length?this.property("__data__",t):this.node().__data__},on:function(t,e,n){var i,o,r=function(t){return t.trim().split(/^|\s+/).map(function(t){var e="",n=t.indexOf(".");return n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),{type:t,name:e}})}(t+""),s=r.length;if(!(arguments.length<2)){for(a=e?rt:ot,i=0;i<s;++i)this.each(a(r[i],e,n));return this}var a=this.node().__on;if(a)for(var l,u=0,c=a.length;u<c;++u)for(i=0,l=a[u];i<s;++i)if((o=r[i]).type===l.type&&o.name===l.name)return l.value},dispatch:function(t,e){return this.each(("function"==typeof e?lt:at)(t,e))},[Symbol.iterator]:function*(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var i,o=t[e],r=0,s=o.length;r<s;++r)(i=o[r])&&(yield i)}};var dt=function(t,e){return dt=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},dt(t,e)};function gt(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}dt(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function mt(t,e,n,i){var o,r=arguments.length,s=r<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,i);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(s=(r<3?o(s):r>3?o(e,n,s):o(e,n))||s);return r>3&&s&&Object.defineProperty(e,n,s),s}function vt(t,e){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,e)}function yt(t,e,n,i){return new(n||(n=Promise))(function(o,r){function s(t){try{l(i.next(t))}catch(t){r(t)}}function a(t){try{l(i.throw(t))}catch(t){r(t)}}function l(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n(function(t){t(e)})).then(s,a)}l((i=i.apply(t,e||[])).next())})}function _t(t,e){var n,i,o,r={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},s=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return s.next=a(0),s.throw=a(1),s.return=a(2),"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(a){return function(l){return function(a){if(n)throw new TypeError("Generator is already executing.");for(;s&&(s=0,a[0]&&(r=0)),r;)try{if(n=1,i&&(o=2&a[0]?i.return:a[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,a[1])).done)return o;switch(i=0,o&&(a=[2&a[0],o.value]),a[0]){case 0:case 1:o=a;break;case 4:return r.label++,{value:a[1],done:!1};case 5:r.label++,i=a[1],a=[0];continue;case 7:a=r.ops.pop(),r.trys.pop();continue;default:if(!(o=r.trys,(o=o.length>0&&o[o.length-1])||6!==a[0]&&2!==a[0])){r=0;continue}if(3===a[0]&&(!o||a[1]>o[0]&&a[1]<o[3])){r.label=a[1];break}if(6===a[0]&&r.label<o[1]){r.label=o[1],o=a;break}if(o&&r.label<o[2]){r.label=o[2],r.ops.push(a);break}o[2]&&r.ops.pop(),r.trys.pop();continue}a=e.call(t,r)}catch(t){a=[6,t],i=0}finally{n=o=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,l])}}}"function"==typeof SuppressedError&&SuppressedError;var bt,wt="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};
|
|
25
|
+
var SeatmapCanvas=function(){"use strict";var t="http://www.w3.org/1999/xhtml",e={svg:"http://www.w3.org/2000/svg",xhtml:t,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function n(t){var n=t+="",i=n.indexOf(":");return i>=0&&"xmlns"!==(n=t.slice(0,i))&&(t=t.slice(i+1)),e.hasOwnProperty(n)?{space:e[n],local:t}:t}function i(e){return function(){var n=this.ownerDocument,i=this.namespaceURI;return i===t&&n.documentElement.namespaceURI===t?n.createElement(e):n.createElementNS(i,e)}}function o(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function r(t){var e=n(t);return(e.local?o:i)(e)}function s(){}function a(t){return null==t?s:function(){return this.querySelector(t)}}function l(){return[]}function u(t){return null==t?l:function(){return this.querySelectorAll(t)}}function c(t){return function(){return null==(e=t.apply(this,arguments))?[]:Array.isArray(e)?e:Array.from(e);var e}}function h(t){return function(){return this.matches(t)}}function f(t){return function(e){return e.matches(t)}}var p=Array.prototype.find;function d(){return this.firstElementChild}var g=Array.prototype.filter;function m(){return Array.from(this.children)}function v(t){return new Array(t.length)}function y(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}function _(t,e,n,i,o,r){for(var s,a=0,l=e.length,u=r.length;a<u;++a)(s=e[a])?(s.__data__=r[a],i[a]=s):n[a]=new y(t,r[a]);for(;a<l;++a)(s=e[a])&&(o[a]=s)}function b(t,e,n,i,o,r,s){var a,l,u,c=new Map,h=e.length,f=r.length,p=new Array(h);for(a=0;a<h;++a)(l=e[a])&&(p[a]=u=s.call(l,l.__data__,a,e)+"",c.has(u)?o[a]=l:c.set(u,l));for(a=0;a<f;++a)u=s.call(t,r[a],a,r)+"",(l=c.get(u))?(i[a]=l,l.__data__=r[a],c.delete(u)):n[a]=new y(t,r[a]);for(a=0;a<h;++a)(l=e[a])&&c.get(p[a])===l&&(o[a]=l)}function w(t){return t.__data__}function E(t){return"object"==typeof t&&"length"in t?t:Array.from(t)}function x(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function k(t){return function(){this.removeAttribute(t)}}function M(t){return function(){this.removeAttributeNS(t.space,t.local)}}function S(t,e){return function(){this.setAttribute(t,e)}}function T(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function L(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function z(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}function C(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function A(t){return function(){this.style.removeProperty(t)}}function O(t,e,n){return function(){this.style.setProperty(t,e,n)}}function B(t,e,n){return function(){var i=e.apply(this,arguments);null==i?this.style.removeProperty(t):this.style.setProperty(t,i,n)}}function N(t,e){return t.style.getPropertyValue(e)||C(t).getComputedStyle(t,null).getPropertyValue(e)}function U(t){return function(){delete this[t]}}function V(t,e){return function(){this[t]=e}}function G(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}function I(t){return t.trim().split(/^|\s+/)}function K(t){return t.classList||new P(t)}function P(t){this._node=t,this._names=I(t.getAttribute("class")||"")}function D(t,e){for(var n=K(t),i=-1,o=e.length;++i<o;)n.add(e[i])}function j(t,e){for(var n=K(t),i=-1,o=e.length;++i<o;)n.remove(e[i])}function R(t){return function(){D(this,t)}}function $(t){return function(){j(this,t)}}function Z(t,e){return function(){(e.apply(this,arguments)?D:j)(this,t)}}function H(){this.textContent=""}function q(t){return function(){this.textContent=t}}function Y(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}function F(){this.innerHTML=""}function X(t){return function(){this.innerHTML=t}}function W(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}function J(){this.nextSibling&&this.parentNode.appendChild(this)}function Q(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function tt(){return null}function et(){var t=this.parentNode;t&&t.removeChild(this)}function nt(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function it(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function ot(t){return function(){var e=this.__on;if(e){for(var n,i=0,o=-1,r=e.length;i<r;++i)n=e[i],t.type&&n.type!==t.type||n.name!==t.name?e[++o]=n:this.removeEventListener(n.type,n.listener,n.options);++o?e.length=o:delete this.__on}}}function rt(t,e,n){return function(){var i,o=this.__on,r=function(t){return function(e){t.call(this,e,this.__data__)}}(e);if(o)for(var s=0,a=o.length;s<a;++s)if((i=o[s]).type===t.type&&i.name===t.name)return this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=r,i.options=n),void(i.value=e);this.addEventListener(t.type,r,n),i={type:t.type,name:t.name,value:e,listener:r,options:n},o?o.push(i):this.__on=[i]}}function st(t,e,n){var i=C(t),o=i.CustomEvent;"function"==typeof o?o=new o(e,n):(o=i.document.createEvent("Event"),n?(o.initEvent(e,n.bubbles,n.cancelable),o.detail=n.detail):o.initEvent(e,!1,!1)),t.dispatchEvent(o)}function at(t,e){return function(){return st(this,t,e)}}function lt(t,e){return function(){return st(this,t,e.apply(this,arguments))}}y.prototype={constructor:y,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}},P.prototype={add:function(t){this._names.indexOf(t)<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var ut=[null];function ct(t,e){this._groups=t,this._parents=e}function ht(){return new ct([[document.documentElement]],ut)}function ft(t){return"string"==typeof t?new ct([[document.querySelector(t)]],[document.documentElement]):new ct([[t]],ut)}function pt(t,e){if(t=function(t){let e;for(;e=t.sourceEvent;)t=e;return t}(t),void 0===e&&(e=t.currentTarget),e){var n=e.ownerSVGElement||e;if(n.createSVGPoint){var i=n.createSVGPoint();return i.x=t.clientX,i.y=t.clientY,[(i=i.matrixTransform(e.getScreenCTM().inverse())).x,i.y]}if(e.getBoundingClientRect){var o=e.getBoundingClientRect();return[t.clientX-o.left-e.clientLeft,t.clientY-o.top-e.clientTop]}}return[t.pageX,t.pageY]}ct.prototype=ht.prototype={constructor:ct,select:function(t){"function"!=typeof t&&(t=a(t));for(var e=this._groups,n=e.length,i=new Array(n),o=0;o<n;++o)for(var r,s,l=e[o],u=l.length,c=i[o]=new Array(u),h=0;h<u;++h)(r=l[h])&&(s=t.call(r,r.__data__,h,l))&&("__data__"in r&&(s.__data__=r.__data__),c[h]=s);return new ct(i,this._parents)},selectAll:function(t){t="function"==typeof t?c(t):u(t);for(var e=this._groups,n=e.length,i=[],o=[],r=0;r<n;++r)for(var s,a=e[r],l=a.length,h=0;h<l;++h)(s=a[h])&&(i.push(t.call(s,s.__data__,h,a)),o.push(s));return new ct(i,o)},selectChild:function(t){return this.select(null==t?d:function(t){return function(){return p.call(this.children,t)}}("function"==typeof t?t:f(t)))},selectChildren:function(t){return this.selectAll(null==t?m:function(t){return function(){return g.call(this.children,t)}}("function"==typeof t?t:f(t)))},filter:function(t){"function"!=typeof t&&(t=h(t));for(var e=this._groups,n=e.length,i=new Array(n),o=0;o<n;++o)for(var r,s=e[o],a=s.length,l=i[o]=[],u=0;u<a;++u)(r=s[u])&&t.call(r,r.__data__,u,s)&&l.push(r);return new ct(i,this._parents)},data:function(t,e){if(!arguments.length)return Array.from(this,w);var n,i=e?b:_,o=this._parents,r=this._groups;"function"!=typeof t&&(n=t,t=function(){return n});for(var s=r.length,a=new Array(s),l=new Array(s),u=new Array(s),c=0;c<s;++c){var h=o[c],f=r[c],p=f.length,d=E(t.call(h,h&&h.__data__,c,o)),g=d.length,m=l[c]=new Array(g),v=a[c]=new Array(g);i(h,f,m,v,u[c]=new Array(p),d,e);for(var y,x,k=0,M=0;k<g;++k)if(y=m[k]){for(k>=M&&(M=k+1);!(x=v[M])&&++M<g;);y._next=x||null}}return(a=new ct(a,o))._enter=l,a._exit=u,a},enter:function(){return new ct(this._enter||this._groups.map(v),this._parents)},exit:function(){return new ct(this._exit||this._groups.map(v),this._parents)},join:function(t,e,n){var i=this.enter(),o=this,r=this.exit();return"function"==typeof t?(i=t(i))&&(i=i.selection()):i=i.append(t+""),null!=e&&(o=e(o))&&(o=o.selection()),null==n?r.remove():n(r),i&&o?i.merge(o).order():o},merge:function(t){for(var e=t.selection?t.selection():t,n=this._groups,i=e._groups,o=n.length,r=i.length,s=Math.min(o,r),a=new Array(o),l=0;l<s;++l)for(var u,c=n[l],h=i[l],f=c.length,p=a[l]=new Array(f),d=0;d<f;++d)(u=c[d]||h[d])&&(p[d]=u);for(;l<o;++l)a[l]=n[l];return new ct(a,this._parents)},selection:function(){return this},order:function(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var i,o=t[e],r=o.length-1,s=o[r];--r>=0;)(i=o[r])&&(s&&4^i.compareDocumentPosition(s)&&s.parentNode.insertBefore(i,s),s=i);return this},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=x);for(var n=this._groups,i=n.length,o=new Array(i),r=0;r<i;++r){for(var s,a=n[r],l=a.length,u=o[r]=new Array(l),c=0;c<l;++c)(s=a[c])&&(u[c]=s);u.sort(e)}return new ct(o,this._parents).order()},call:function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},nodes:function(){return Array.from(this)},node:function(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var i=t[e],o=0,r=i.length;o<r;++o){var s=i[o];if(s)return s}return null},size:function(){let t=0;for(const e of this)++t;return t},empty:function(){return!this.node()},each:function(t){for(var e=this._groups,n=0,i=e.length;n<i;++n)for(var o,r=e[n],s=0,a=r.length;s<a;++s)(o=r[s])&&t.call(o,o.__data__,s,r);return this},attr:function(t,e){var i=n(t);if(arguments.length<2){var o=this.node();return i.local?o.getAttributeNS(i.space,i.local):o.getAttribute(i)}return this.each((null==e?i.local?M:k:"function"==typeof e?i.local?z:L:i.local?T:S)(i,e))},style:function(t,e,n){return arguments.length>1?this.each((null==e?A:"function"==typeof e?B:O)(t,e,null==n?"":n)):N(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?U:"function"==typeof e?G:V)(t,e)):this.node()[t]},classed:function(t,e){var n=I(t+"");if(arguments.length<2){for(var i=K(this.node()),o=-1,r=n.length;++o<r;)if(!i.contains(n[o]))return!1;return!0}return this.each(("function"==typeof e?Z:e?R:$)(n,e))},text:function(t){return arguments.length?this.each(null==t?H:("function"==typeof t?Y:q)(t)):this.node().textContent},html:function(t){return arguments.length?this.each(null==t?F:("function"==typeof t?W:X)(t)):this.node().innerHTML},raise:function(){return this.each(J)},lower:function(){return this.each(Q)},append:function(t){var e="function"==typeof t?t:r(t);return this.select(function(){return this.appendChild(e.apply(this,arguments))})},insert:function(t,e){var n="function"==typeof t?t:r(t),i=null==e?tt:"function"==typeof e?e:a(e);return this.select(function(){return this.insertBefore(n.apply(this,arguments),i.apply(this,arguments)||null)})},remove:function(){return this.each(et)},clone:function(t){return this.select(t?it:nt)},datum:function(t){return arguments.length?this.property("__data__",t):this.node().__data__},on:function(t,e,n){var i,o,r=function(t){return t.trim().split(/^|\s+/).map(function(t){var e="",n=t.indexOf(".");return n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),{type:t,name:e}})}(t+""),s=r.length;if(!(arguments.length<2)){for(a=e?rt:ot,i=0;i<s;++i)this.each(a(r[i],e,n));return this}var a=this.node().__on;if(a)for(var l,u=0,c=a.length;u<c;++u)for(i=0,l=a[u];i<s;++i)if((o=r[i]).type===l.type&&o.name===l.name)return l.value},dispatch:function(t,e){return this.each(("function"==typeof e?lt:at)(t,e))},[Symbol.iterator]:function*(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var i,o=t[e],r=0,s=o.length;r<s;++r)(i=o[r])&&(yield i)}};var dt=function(t,e){return dt=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},dt(t,e)};function gt(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}dt(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function mt(t,e,n,i){var o,r=arguments.length,s=r<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(t,e,n,i);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(s=(r<3?o(s):r>3?o(e,n,s):o(e,n))||s);return r>3&&s&&Object.defineProperty(e,n,s),s}function vt(t,e){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,e)}function yt(t,e,n,i){return new(n||(n=Promise))(function(o,r){function s(t){try{l(i.next(t))}catch(t){r(t)}}function a(t){try{l(i.throw(t))}catch(t){r(t)}}function l(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n(function(t){t(e)})).then(s,a)}l((i=i.apply(t,e||[])).next())})}function _t(t,e){var n,i,o,r={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},s=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return s.next=a(0),s.throw=a(1),s.return=a(2),"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(a){return function(l){return function(a){if(n)throw new TypeError("Generator is already executing.");for(;s&&(s=0,a[0]&&(r=0)),r;)try{if(n=1,i&&(o=2&a[0]?i.return:a[0]?i.throw||((o=i.return)&&o.call(i),0):i.next)&&!(o=o.call(i,a[1])).done)return o;switch(i=0,o&&(a=[2&a[0],o.value]),a[0]){case 0:case 1:o=a;break;case 4:return r.label++,{value:a[1],done:!1};case 5:r.label++,i=a[1],a=[0];continue;case 7:a=r.ops.pop(),r.trys.pop();continue;default:if(!(o=r.trys,(o=o.length>0&&o[o.length-1])||6!==a[0]&&2!==a[0])){r=0;continue}if(3===a[0]&&(!o||a[1]>o[0]&&a[1]<o[3])){r.label=a[1];break}if(6===a[0]&&r.label<o[1]){r.label=o[1],o=a;break}if(o&&r.label<o[2]){r.label=o[2],r.ops.push(a);break}o[2]&&r.ops.pop(),r.trys.pop();continue}a=e.call(t,r)}catch(t){a=[6,t],i=0}finally{n=o=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,l])}}}"function"==typeof SuppressedError&&SuppressedError;var bt,wt="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};
|
|
26
26
|
/*! *****************************************************************************
|
|
27
27
|
Copyright (C) Microsoft. All rights reserved.
|
|
28
28
|
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
|