From a8889aef71b47258acaa9feee5fa3bb920ebccfe Mon Sep 17 00:00:00 2001 From: sidharthv96 Date: Fri, 30 Jul 2021 09:57:38 +0000 Subject: [PATCH] deploy: 57bb0fa248c0ec00a5ed9b6db0f9e2f30238c783 --- .../assets/pages/__layout.svelte-f724ac47.css | 1 + _app/chunks/analytics.browser.es-de8d1c22.js | 1 + _app/chunks/preload-helper-78524df4.js | 1 + _app/chunks/singletons-12a22614.js | 1 + _app/chunks/util-5805f6cc.js | 1 + _app/chunks/vendor-134b46ff.js | 40 +++++++++++++++++++ _app/error.svelte-0a86134d.js | 1 + _app/pages/__layout.svelte-54219fd5.js | 1 + _app/pages/edit.svelte-44f34ed1.js | 1 + _app/pages/index.svelte-fdfef9f1.js | 1 + _app/pages/view.svelte-14980d45.js | 1 + _app/start-83e63352.js | 1 + edit/index.html | 15 +++---- index.html | 15 +++---- view/index.html | 15 +++---- 15 files changed, 66 insertions(+), 30 deletions(-) create mode 100644 _app/assets/pages/__layout.svelte-f724ac47.css create mode 100644 _app/chunks/analytics.browser.es-de8d1c22.js create mode 100644 _app/chunks/preload-helper-78524df4.js create mode 100644 _app/chunks/singletons-12a22614.js create mode 100644 _app/chunks/util-5805f6cc.js create mode 100644 _app/chunks/vendor-134b46ff.js create mode 100644 _app/error.svelte-0a86134d.js create mode 100644 _app/pages/__layout.svelte-54219fd5.js create mode 100644 _app/pages/edit.svelte-44f34ed1.js create mode 100644 _app/pages/index.svelte-fdfef9f1.js create mode 100644 _app/pages/view.svelte-14980d45.js create mode 100644 _app/start-83e63352.js diff --git a/_app/assets/pages/__layout.svelte-f724ac47.css b/_app/assets/pages/__layout.svelte-f724ac47.css new file mode 100644 index 00000000..5131521a --- /dev/null +++ b/_app/assets/pages/__layout.svelte-f724ac47.css @@ -0,0 +1 @@ +/*! tailwindcss v2.2.7 | MIT License | https://tailwindcss.com*//*! modern-normalize v1.1.0 | MIT License | https://github.com/sindresorhus/modern-normalize */html{-webkit-text-size-adjust:100%;line-height:1.15;-moz-tab-size:4;-o-tab-size:4;tab-size:4}body{font-family:system-ui,-apple-system,Segoe UI,Roboto,Helvetica,Arial,sans-serif,Apple Color Emoji,Segoe UI Emoji;margin:0}hr{color:inherit;height:0}abbr[title]{-webkit-text-decoration:underline dotted;text-decoration:underline dotted}b,strong{font-weight:bolder}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Consolas,Liberation Mono,Menlo,monospace;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0}button,select{text-transform:none}[type=button],button{-webkit-appearance:button}legend{padding:0}progress{vertical-align:baseline}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}button{background-color:transparent;background-image:none}fieldset,ol,ul{margin:0;padding:0}ol,ul{list-style:none}html{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;line-height:1.5}body{font-family:inherit;line-height:inherit}*,:after,:before{border:0 solid;box-sizing:border-box}hr{border-top-width:1px}img{border-style:solid}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:#9ca3af;opacity:1}input:-ms-input-placeholder,textarea:-ms-input-placeholder{color:#9ca3af;opacity:1}input::placeholder,textarea::placeholder{color:#9ca3af;opacity:1}button{cursor:pointer}table{border-collapse:collapse}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}button,input,optgroup,select,textarea{color:inherit;line-height:inherit;padding:0}code,kbd,pre,samp{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]{display:none}*,:after,:before{--tw-border-opacity:1;border-color:rgba(229,231,235,var(--tw-border-opacity))}.container{width:100%}@media (min-width:640px){.container{max-width:640px}}@media (min-width:768px){.container{max-width:768px}}@media (min-width:1024px){.container{max-width:1024px}}@media (min-width:1280px){.container{max-width:1280px}}@media (min-width:1536px){.container{max-width:1536px}}.fixed{position:fixed}.absolute{position:absolute}.m-2{margin:.5rem}.mx-2{margin-left:.5rem;margin-right:.5rem}.-mt-2{margin-top:-.5rem}.mr-2{margin-right:.5rem}.-mb-4{margin-bottom:-1rem}.block{display:block}.flex{display:flex}.table{display:table}.hidden{display:none}.h-6{height:1.5rem}.h-56{height:14rem}.h-full{height:100%}.h-screen{height:100vh}.w-24{width:6rem}.w-28{width:7rem}.w-auto{width:auto}.w-full{width:100%}.flex-1{flex:1 1 0%}.flex-auto{flex:1 1 auto}.flex-none{flex:none}.flex-grow{flex-grow:1}.transform{--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;transform:translateX(var(--tw-translate-x)) translateY(var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@-webkit-keyframes spin{to{transform:rotate(1turn)}}@keyframes spin{to{transform:rotate(1turn)}}@-webkit-keyframes ping{75%,to{opacity:0;transform:scale(2)}}@keyframes ping{75%,to{opacity:0;transform:scale(2)}}@-webkit-keyframes pulse{50%{opacity:.5}}@keyframes pulse{50%{opacity:.5}}@-webkit-keyframes bounce{0%,to{-webkit-animation-timing-function:cubic-bezier(.8,0,1,1);animation-timing-function:cubic-bezier(.8,0,1,1);transform:translateY(-25%)}50%{-webkit-animation-timing-function:cubic-bezier(0,0,.2,1);animation-timing-function:cubic-bezier(0,0,.2,1);transform:none}}@keyframes bounce{0%,to{-webkit-animation-timing-function:cubic-bezier(.8,0,1,1);animation-timing-function:cubic-bezier(.8,0,1,1);transform:translateY(-25%)}50%{-webkit-animation-timing-function:cubic-bezier(0,0,.2,1);animation-timing-function:cubic-bezier(0,0,.2,1);transform:none}}.cursor-default{cursor:default}.cursor-pointer{cursor:pointer}.resize{resize:both}.flex-row{flex-direction:row}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.content-center{align-content:center}.items-center{align-items:center}.justify-between{justify-content:space-between}.gap-2{gap:.5rem}.gap-x-4{-moz-column-gap:1rem;column-gap:1rem}.space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse:0;margin-bottom:calc(.5rem*var(--tw-space-y-reverse));margin-top:calc(.5rem*(1 - var(--tw-space-y-reverse)))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.rounded{border-radius:.25rem}.rounded-t{border-top-left-radius:.25rem;border-top-right-radius:.25rem}.border{border-width:1px}.border-white{--tw-border-opacity:1;border-color:rgba(255,255,255,var(--tw-border-opacity))}.border-gray-400{--tw-border-opacity:1;border-color:rgba(156,163,175,var(--tw-border-opacity))}.border-indigo-500{--tw-border-opacity:1;border-color:rgba(99,102,241,var(--tw-border-opacity))}.bg-white{--tw-bg-opacity:1;background-color:rgba(255,255,255,var(--tw-bg-opacity))}.bg-gray-100{--tw-bg-opacity:1;background-color:rgba(243,244,246,var(--tw-bg-opacity))}.bg-red-200{--tw-bg-opacity:1;background-color:rgba(254,202,202,var(--tw-bg-opacity))}.bg-green-200{--tw-bg-opacity:1;background-color:rgba(167,243,208,var(--tw-bg-opacity))}.bg-indigo-400{--tw-bg-opacity:1;background-color:rgba(129,140,248,var(--tw-bg-opacity))}.bg-indigo-500{--tw-bg-opacity:1;background-color:rgba(99,102,241,var(--tw-bg-opacity))}.hover\:bg-red-300:hover{--tw-bg-opacity:1;background-color:rgba(252,165,165,var(--tw-bg-opacity))}.hover\:bg-green-300:hover{--tw-bg-opacity:1;background-color:rgba(110,231,183,var(--tw-bg-opacity))}.hover\:bg-indigo-600:hover{--tw-bg-opacity:1;background-color:rgba(79,70,229,var(--tw-bg-opacity))}.hover\:bg-indigo-700:hover{--tw-bg-opacity:1;background-color:rgba(67,56,202,var(--tw-bg-opacity))}.fill-current{fill:currentColor}.p-2{padding:.5rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-4{padding-left:1rem;padding-right:1rem}.py-1{padding-bottom:.25rem;padding-top:.25rem}.pt-4{padding-top:1rem}.text-center{text-align:center}.text-xs{font-size:.75rem;line-height:1rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-base{font-size:1rem;line-height:1.5rem}.font-thin{font-weight:100}.font-semibold{font-weight:600}.font-bold{font-weight:700}.leading-normal{line-height:1.5}.text-white{--tw-text-opacity:1;color:rgba(255,255,255,var(--tw-text-opacity))}.text-gray-400{--tw-text-opacity:1;color:rgba(156,163,175,var(--tw-text-opacity))}.text-gray-600{--tw-text-opacity:1;color:rgba(75,85,99,var(--tw-text-opacity))}.text-red-400{--tw-text-opacity:1;color:rgba(248,113,113,var(--tw-text-opacity))}.text-indigo-500{--tw-text-opacity:1;color:rgba(99,102,241,var(--tw-text-opacity))}*,:after,:before{--tw-shadow:0 0 #0000}.shadow{--tw-shadow:0 1px 3px 0 rgba(0,0,0,0.1),0 1px 2px 0 rgba(0,0,0,0.06);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}*,:after,:before{--tw-ring-inset:var(--tw-empty, );/*!*//*!*/--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,0.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000}.filter{--tw-blur:var(--tw-empty, );/*!*//*!*/--tw-brightness:var(--tw-empty, );/*!*//*!*/--tw-contrast:var(--tw-empty, );/*!*//*!*/--tw-grayscale:var(--tw-empty, );/*!*//*!*/--tw-hue-rotate:var(--tw-empty, );/*!*//*!*/--tw-invert:var(--tw-empty, );/*!*//*!*/--tw-saturate:var(--tw-empty, );/*!*//*!*/--tw-sepia:var(--tw-empty, );/*!*//*!*/--tw-drop-shadow:var(--tw-empty, );/*!*//*!*/filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition{transition-duration:.15s;transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:background-color,border-color,color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.nav-btn{border-bottom-width:2px;border-color:transparent;display:block}.nav-btn:hover{--tw-border-opacity:1;border-color:rgba(255,255,255,var(--tw-border-opacity))}.nav-btn{padding:.75rem 0}@media (min-width:1024px){.nav-btn{padding:.5rem}}.btn{background-color:rgba(99,102,241,var(--tw-bg-opacity));border-radius:.25rem}.btn,.btn:hover{--tw-bg-opacity:1}.btn:hover{background-color:rgba(67,56,202,var(--tw-bg-opacity))}.btn{--tw-shadow:0 1px 3px 0 rgba(0,0,0,0.1),0 1px 2px 0 rgba(0,0,0,0.06);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);padding-left:1rem;padding-right:1rem}.action-btn{--tw-bg-opacity:1;background-color:rgba(129,140,248,var(--tw-bg-opacity));border-radius:.25rem;flex:1 1 auto}.action-btn:hover{--tw-bg-opacity:1;background-color:rgba(99,102,241,var(--tw-bg-opacity))}.action-btn{--tw-text-opacity:1;--tw-shadow:0 1px 3px 0 rgba(0,0,0,0.1),0 1px 2px 0 rgba(0,0,0,0.06);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);color:rgba(255,255,255,var(--tw-text-opacity));padding:.5rem}@media (min-width:768px){.md\:flex{display:flex}.md\:hidden{display:none}}@media (min-width:1024px){.lg\:flex{display:flex}.lg\:hidden{display:none}.lg\:w-auto{width:auto}.lg\:items-center{align-items:center}.lg\:pt-0{padding-top:0}} \ No newline at end of file diff --git a/_app/chunks/analytics.browser.es-de8d1c22.js b/_app/chunks/analytics.browser.es-de8d1c22.js new file mode 100644 index 00000000..51b2e13d --- /dev/null +++ b/_app/chunks/analytics.browser.es-de8d1c22.js @@ -0,0 +1 @@ +function t(t,e,n,r,o){for(e=e.split?e.split("."):e,r=0;r1;return a||(l?o(t,e):r(t)),l?document.cookie=t+"="+encodeURIComponent(e)+(i?"; expires="+new Date(+new Date+1e3*i).toUTCString()+(u?"; path="+u:"")+(c?"; domain="+c:"")+(s?"; secure":""):""):decodeURIComponent((("; "+document.cookie).split("; "+t+"=")[1]||"").split(";")[0])}}var p=d();function d(){if(typeof p!==n)return p;p=!0;try{typeof localStorage!==n&&typeof JSON!==n||(p=!1),localStorage.setItem(n,n),localStorage.removeItem(n)}catch(t){p=!1}return p}var h="undefined"!=typeof window;function g(t){return"function"==typeof t}function y(t){return"string"==typeof t}function v(t){return void 0===t}function m(t){return"boolean"==typeof t}function b(t){if("object"!=typeof t||null===t)return!1;for(var e=t;null!==Object.getPrototypeOf(e);)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(t)===e}function w(t){var e=t;try{if("true"===(e=JSON.parse(t)))return!0;if("false"===e)return!1;if(b(e))return e;parseFloat(e)===e&&(e=parseFloat(e))}catch(n){}if(null!==e&&""!==e)return e}var x=d(),S=l();function E(t,e){if(t){var n=I(e),o=!P(n),i=O(n)?w(localStorage.getItem(t)):void 0;if(o&&!v(i))return i;var a=k(n)?w(u(t)):void 0;if(o&&a)return a;var c=r(t);return o?c:{localStorage:i,cookie:a,global:c}}}function I(t){return t?"string"==typeof t?t:t.storage:"any"}function O(t){return x&&_(t,"localStorage")}function k(t){return S&&_(t,"cookie")}function P(t){return"*"===t||"all"===t}function _(t,e){return"any"===t||t===e||P(t)}var j={setItem:function(t,e,n){if(t&&!v(e)){var i={},a=I(n),s=JSON.stringify(e),l=!P(a);return O(a)&&(i.localStorage={location:"localStorage",current:e,previous:w(localStorage.getItem(t))},localStorage.setItem(t,s),l)?i.localStorage:k(a)&&(i.cookie={location:"cookie",current:e,previous:w(u(t))},c(t,s),l)?i.cookie:(i.global={location:"global",current:e,previous:r(t)},o(t,e),l?i.global:i)}},getItem:E,removeItem:function(t,e){if(t){var n=I(e),r=E(t,"*"),o={};return!v(r.localStorage)&&O(n)&&(localStorage.removeItem(t),o.localStorage=r.localStorage),!v(r.cookie)&&k(n)&&(s(t),o.cookie=r.cookie),!v(r.global)&&_(n,"global")&&(i(t),o.global=r.global),o}}};function N(t){try{return decodeURIComponent(t.replace(/\+/g," "))}catch(e){return null}}var A="undefined"!=typeof document;function T(t){return function(t){var e,n={},r=/([^&=]+)=?([^&]*)/g;for(;e=r.exec(t);){var o=N(e[1]),i=N(e[2]);"[]"===o.substring(o.length-2)?(n[o=o.substring(0,o.length-2)]||(n[o]=[])).push(i):n[o]=""===i||i}for(var a in n){var u=a.split("[");u.length>1&&(L(n,u.map((function(t){return t.replace(/[?[\]\\ ]/g,"")})),n[a]),delete n[a])}return n}(function(t){if(t){var e=t.match(/\?(.*)/);return e&&e[1]?e[1].split("#")[0]:""}return A&&window.location.search.substring(1)}(t))}function L(t,e,n){for(var r=e.length-1,o=0;o>4}return t}var M=function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);e=0;--i){var a=this.tryEntries[i],u=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var c=r.call(a,"catchLoc"),s=r.call(a,"finallyLoc");if(c&&s){if(this.prev=0;--n){var o=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),P(n),g}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var o=r.arg;P(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:j(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),g}},t}(t.exports);try{regeneratorRuntime=e}catch(n){Function("r","regeneratorRuntime = r")(e)}}));function F(t,e,n,r,o,i,a){try{var u=t[i](a),c=u.value}catch(s){return void n(s)}u.done?e(c):Promise.resolve(c).then(r,o)}var G=function(t){return function(){var e=this,n=arguments;return new Promise((function(r,o){var i=t.apply(e,n);function a(t){F(i,r,o,a,u,"next",t)}function u(t){F(i,r,o,a,u,"throw",t)}a(void 0)}))}};var $=function(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t};function B(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}var J=function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1?arguments[1]:void 0;if(i)throw i;for(var r=!1,o={},u=0;u0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(n.type===ft.setItemEnd){if(n.key===it)return J(J({},e),{anonymousId:n.value});if(n.key===at)return J(J({},e),{userId:n.value})}switch(n.type){case ft.identify:return Object.assign({},e,{userId:n.userId,traits:J(J({},e.traits),n.traits)});case ft.reset:return[at,it,ut].forEach((function(e){t.removeItem(e)})),Object.assign({},e,{userId:null,anonymousId:null,traits:{}});default:return e}}}function mt(t){return{userId:t.getItem(at),anonymousId:t.getItem(it),traits:t.getItem(ut)}}var bt=function(t){return"__TEMP__"+t};function wt(t){return function(e,n,o){var i=n.getState("user")[e];if(i)return i;if(o&&b(o)&&o[e])return o[e];var a=mt(t)[e];return a||(r(bt(e))||null)}}function xt(t){var e=t.storage,n=e.setItem,r=e.removeItem,o=e.getItem;return function(t){return function(e){return function(a){var u=a.userId,c=a.traits,s=a.options;if(a.type===ft.reset&&([at,ut,it].forEach((function(t){r(t)})),[rt,ot,"traits"].forEach((function(t){i(bt(t))}))),a.type===ft.identify){o(it)||n(it,z());var l=o(at),f=o(ut)||{};l&&l!==u&&t.dispatch({type:ft.userIdChanged,old:{userId:l,traits:f},new:{userId:u,traits:c},options:s}),u&&n(at,u),c&&n(ut,J(J({},f),c))}return e(a)}}}}var St={};function Et(t,e){St[t]&&g(St[t])&&(St[t](e),delete St[t])}function It(t,e,n){return new Promise((function(r,o){return e()?r(t):n<1?o(J(J({},t),{},{queue:!0})):(i=10,new Promise((function(t){return setTimeout(t,i)}))).then((function(i){return It(t,e,n-10).then(r,o)}));var i}))}function Ot(t,e,n){var r=e(),o=t.getState(),i=o.plugins,a=o.context,u=o.queue,c=o.user;if(!a.offline&&u&&u.actions&&u.actions.length){var s=u.actions.reduce((function(t,e,n){return i[e.plugin].loaded?(t.process.push(e),t.processIndex.push(n)):(t.requeue.push(e),t.requeueIndex.push(n)),t}),{processIndex:[],process:[],requeue:[],requeueIndex:[]});if(s.processIndex&&s.processIndex.length){s.processIndex.forEach((function(e){var o=u.actions[e],a=o.plugin,s=o.payload.type,l=r[a][s];if(l&&g(l)){var f=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return[rt,ot].reduce((function(n,r){return t.hasOwnProperty(r)&&e[r]&&e[r]!==t[r]&&(n[r]=e[r]),n}),t)}(o.payload,c);l({payload:f,config:i[a].config,instance:n});var p="".concat(s,":").concat(a);t.dispatch(J(J({},f),{},{type:p,_:{called:p,from:"queueDrain"}}))}}));var l=u.actions.filter((function(t,e){return!~s.processIndex.indexOf(e)}));u.actions=l}}}function kt(t,e,n){return setInterval((function(){return Ot(t,e,n)}),3e3)}var Pt=function(t){if(Array.isArray(t))return t};var _t=function(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var a,u=t[Symbol.iterator]();!(r=(a=u.next()).done)&&(n.push(a.value),!e||n.length!==e);r=!0);}catch(c){o=!0,i=c}finally{try{r||null==u.return||u.return()}finally{if(o)throw i}}return n};var jt=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance")};var Nt=function(t,e){return Pt(t)||_t(t,e)||jt()};function At(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return Object.keys(t).filter((function(t){var r=n.plugins||{};return m(r[t])?r[t]:!1!==r.all&&(!e[t]||!1!==e[t].enabled)})).map((function(e){return t[e]}))}var Tt=/Start$/,Lt=/^bootstrap/,zt=/^ready/;function Mt(t,e,n,r,o){return Dt.apply(this,arguments)}function Dt(){return(Dt=G(V.mark((function t(e,n,r,o,i){var a,u,c,s,l,f,p,d,h,y,v;return V.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(a=g(n)?n():n,u=e.type,c=u.replace(Tt,""),!e._||!e._.called){t.next=5;break}return t.abrupt("return",e);case 5:return s=r.getState(),l=At(a,s.plugins,e.options),u===ft.initializeStart&&e.fromEnable&&(l=Object.keys(s.plugins).filter((function(t){var n=s.plugins[t];return e.plugins.includes(t)&&!n.initialized})).map((function(t){return a[t]}))),f=l.map((function(t){return t.name})),p=Gt(u,l),t.next=12,Ut({action:e,data:{exact:p.before,namespaced:p.beforeNS},state:s,allPlugins:a,allMatches:p,instance:r,store:o,EVENTS:i});case 12:if(!Bt(d=t.sent,f.length)){t.next=15;break}return t.abrupt("return",d);case 15:if(u!==c){t.next=19;break}h=d,t.next=22;break;case 19:return t.next=21,Ut({action:J(J({},d),{},{type:c}),data:{exact:p.during,namespaced:p.duringNS},state:s,allPlugins:a,allMatches:p,instance:r,store:o,EVENTS:i});case 21:h=t.sent;case 22:if(!u.match(Tt)){t.next=28;break}return y="".concat(c,"End"),t.next=26,Ut({action:J(J({},h),{},{type:y}),data:{exact:p.after,namespaced:p.afterNS},state:s,allPlugins:a,allMatches:p,instance:r,store:o,EVENTS:i});case 26:(v=t.sent).meta&&v.meta.hasCallback&&Et(v.meta.rid,{payload:v});case 28:return t.abrupt("return",d);case 29:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Ut(t){return Ct.apply(this,arguments)}function Ct(){return(Ct=G(V.mark((function t(e){var n,r,o,i,a,u,c,s,l,f,p,d,h,y,v,m,w,x;return V.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e.data,r=e.action,o=e.instance,i=e.state,a=e.allPlugins,u=e.allMatches,c=e.store,s=e.EVENTS,l=i.plugins,f=i.context,p=r.type,d=p.match(Tt),h=n.exact.map((function(t){return t.pluginName})),d&&(h=u.during.map((function(t){return t.pluginName}))),y=Wt(o,h),v=n.exact.reduce((function(t,e){var n=e.pluginName,r=e.methodName,o=!1;return r.match(/^initialize/)||r.match(/^reset/)||(o=!l[n].loaded),f.offline&&r.match(/^(page|track|identify)/)&&(o=!0),t["".concat(n)]=o,t}),{}),t.next=10,n.exact.reduce(function(){var t=G(V.mark((function t(e,i,u){var c,s,f;return V.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return c=i.pluginName,t.next=3,e;case 3:if(s=t.sent,!n.namespaced||!n.namespaced[c]){t.next=11;break}return t.next=7,n.namespaced[c].reduce(function(){var t=G(V.mark((function t(e,n,r){var i,u,s,f;return V.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return u=function(t,e,n){return function(r,o){var i=n||e;return J(J({},t),{},{abort:{reason:r,plugins:o||[e],caller:p,from:i}})}},t.next=3,e;case 3:if(i=t.sent,n.method&&g(n.method)){t.next=6;break}return t.abrupt("return",i);case 6:return Yt(n.methodName,n.pluginName),t.next=9,n.method({payload:i,instance:o,abort:u(i,c,n.pluginName),config:Rt(n.pluginName,l,a),plugins:l});case 9:return s=t.sent,f=b(s)?s:{},t.abrupt("return",Promise.resolve(J(J({},i),f)));case 12:case"end":return t.stop()}}),t)})));return function(e,n,r){return t.apply(this,arguments)}}(),Promise.resolve(r));case 7:f=t.sent,s[c]=f,t.next=12;break;case 11:s[c]=r;case 12:return t.abrupt("return",Promise.resolve(s));case 13:case"end":return t.stop()}}),t)})));return function(e,n,r){return t.apply(this,arguments)}}(),Promise.resolve({}));case 10:return m=t.sent,t.next=13,n.exact.reduce(function(){var t=G(V.mark((function t(e,r,i){var u,s,f,h,g,w,x,S,E,I,O,k;return V.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return u=n.exact.length===i+1,s=r.pluginName,f=a[s],t.next=5,e;case 5:if(h=t.sent,g=m[s]?m[s]:{},d&&(g=h),!$t(g,s)){t.next=11;break}return qt({data:g,method:p,instance:o,pluginName:s,store:c}),t.abrupt("return",Promise.resolve(h));case 11:if(!$t(h,s)){t.next=14;break}return u&&qt({data:h,method:p,instance:o,store:c}),t.abrupt("return",Promise.resolve(h));case 14:if(!v.hasOwnProperty(s)||!0!==v[s]){t.next=17;break}return c.dispatch({type:"queue",plugin:s,payload:g,_:{called:"queue",from:"queueMechanism"}}),t.abrupt("return",Promise.resolve(h));case 17:return w=y(m[s],a[s]),t.next=20,f[p]({abort:w.abort,payload:g,instance:o,config:Rt(s,l,a),plugins:l});case 20:return x=t.sent,S=b(x)?x:{},E=J(J({},h),S),$t(I=m[s],s)?qt({data:I,method:p,instance:o,pluginName:s,store:c}):(O="".concat(p,":").concat(s),(O.match(/:/g)||[]).length<2&&!p.match(Lt)&&!p.match(zt)&&(k=d?E:g,o.dispatch(J(J({},k),{},{type:O,_:{called:O,from:"submethod"}})))),t.abrupt("return",Promise.resolve(E));case 26:case"end":return t.stop()}}),t)})));return function(e,n,r){return t.apply(this,arguments)}}(),Promise.resolve(r));case 13:if(w=t.sent,p.match(Tt)||p.match(/^registerPlugin/)||p.match(zt)||p.match(Lt)||p.match(/^params/)||p.match(/^userIdChanged/)){t.next=21;break}if(s.plugins.includes(p),!w._||w._.originalAction!==p){t.next=18;break}return t.abrupt("return",w);case 18:x=J(J({},w),{_:{originalAction:w.type,called:w.type,from:"engineEnd"}}),Bt(w,n.exact.length)&&!p.match(/End$/)&&(x=J(J({},x),{type:w.type+"Aborted"})),c.dispatch(x);case 21:return t.abrupt("return",w);case 22:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function qt(t){var e=t.data,n=t.method;t.instance;var r=t.pluginName,o=n+"Aborted"+(r?":"+r:"");t.store.dispatch(J(J({},e),{},{type:o,_:{called:o,from:"abort"}}))}function Rt(t,e,n){var r=e[t]||n[t];return r&&r.config?r.config:{}}function Vt(t,e){return e.reduce((function(e,n){return n[t]?e.concat({methodName:t,pluginName:n.name,method:n[t]}):e}),[])}function Ft(t,e){var n=function(t){return t.replace(Tt,"")}(t),r=e?":".concat(e):"";return["".concat(t).concat(r),"".concat(n).concat(r),"".concat(n,"End").concat(r)]}function Gt(t,e,n){var r=Ft(t).map((function(t){return Vt(t,e)}));return e.reduce((function(n,r){var o=r.name,i=Ft(t,o).map((function(t){return Vt(t,e)})),a=Nt(i,3),u=a[0],c=a[1],s=a[2];return u.length&&(n.beforeNS[o]=u),c.length&&(n.duringNS[o]=c),s.length&&(n.afterNS[o]=s),n}),{before:r[0],beforeNS:{},during:r[1],duringNS:{},after:r[2],afterNS:{}})}function $t(t,e){var n=t.abort;return!!n&&(!0===n||(Xt(n,e)||n&&Xt(n.plugins,e)))}function Bt(t,e){var n=t.abort;if(!n)return!1;if(!0===n||y(n))return!0;var r=n.plugins;return Jt(n)&&n.length===e||Jt(r)&&r.length===e}function Jt(t){return Array.isArray(t)}function Xt(t,e){return!(!t||!Jt(t))&&t.includes(e)}function Wt(t,e){return function(n,r,o){var i=r.config,a=r.name,u="".concat(a,".").concat(n.type);o&&(u=o.event);var c=n.type.match(Tt)?function(t,e,n,r,o){return function(i,a){var u=r?r.name:t,c=a&&Jt(a)?a:n;if(r&&(!(c=a&&Jt(a)?a:[t]).includes(t)||1!==c.length))throw new Error("Method ".concat(e," can only abort ").concat(t," plugin. ").concat(JSON.stringify(c)," input valid"));return J(J({},o),{},{abort:{reason:i,plugins:c,caller:e,_:u}})}}(a,u,e,o,n):function(t,e){return function(){throw new Error(t.type+" action not cancellable. Remove abort in "+e)}}(n,u);return{payload:Zt(n),instance:t,config:i||{},abort:c}}}function Yt(t,e){var n=Ht(t);if(n&&n.name===e){var r=Ht(n.method),o=r?"or "+r.method:"";throw new Error([e+" plugin is calling method "+t,"Plugins cant call self","Use ".concat(n.method," ").concat(o," in ").concat(e," plugin insteadof ").concat(t)].join("\n"))}}function Ht(t){var e=t.match(/(.*):(.*)/);return!!e&&{method:e[1],name:e[2]}}function Zt(t){return Object.keys(t).reduce((function(e,n){return"type"===n||(b(t[n])?e[n]=Object.assign({},t[n]):e[n]=t[n]),e}),{})}function Kt(t,e,n){var r={};return function(o){return function(i){return function(){var a=G(V.mark((function a(u){var c,s,l,f,p,d,h,g,y,v,m,b;return V.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:if(c=u.type,s=u.abort,l=u.plugins,f=u,!s){a.next=4;break}return a.abrupt("return",i(u));case 4:if(c===ft.enablePlugin&&o.dispatch({type:ft.initializeStart,plugins:l,disabled:[],fromEnable:!0,meta:u.meta}),c===ft.disablePlugin&&setTimeout((function(){return Et(u.meta.rid,{payload:u})}),0),c===ft.initializeEnd&&(p=e(),d=Object.keys(p),h=d.filter((function(t){return l.includes(t)})).map((function(t){return p[t]})),g=[],y=[],v=u.disabled,m=h.map((function(t){var e=t.loaded,n=t.name;return It(t,e,1e4).then((function(e){return r[n]||(o.dispatch({type:ft.pluginReadyType(n),name:n,events:Object.keys(t).filter((function(t){return!lt.includes(t)}))}),r[n]=!0),g=g.concat(n),t})).catch((function(t){if(t instanceof Error)throw new Error(t);return y=y.concat(t.name),t}))})),Promise.all(m).then((function(t){var e={plugins:g,failed:y,disabled:v};setTimeout((function(){d.length===m.length+v.length&&o.dispatch(J(J({},{type:ft.ready}),e))}),0)}))),c===ft.bootstrap){a.next=13;break}return/^ready:([^:]*)$/.test(c)&&setTimeout((function(){return Ot(o,e,t)}),0),a.next=11,Mt(u,e,t,o,n);case 11:return b=a.sent,a.abrupt("return",i(b));case 13:return a.abrupt("return",i(f));case 14:case"end":return a.stop()}}),a)})));return function(t){return a.apply(this,arguments)}}()}}}function Qt(t){return function(e){return function(e){return function(n){var r=n.type,o=n.key,i=n.value,a=n.options;if(r===ft.setItem||r===ft.removeItem){if(n.abort)return e(n);r===ft.setItem?t.setItem(o,i,a):t.removeItem(o,a)}return e(n)}}}}var te=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")},ee=function t(){var e=this;te(this,t),$(this,"before",[]),$(this,"after",[]),$(this,"addMiddleware",(function(t,n){e[n]=e[n].concat(t)})),$(this,"removeMiddleware",(function(t,n){var r=e[n].findIndex((function(e){return e===t}));-1!==r&&(e[n]=[].concat(C(e[n].slice(0,r)),C(e[n].slice(r+1))))})),$(this,"dynamicMiddlewares",(function(t){return function(n){return function(r){return function(o){var i={getState:n.getState,dispatch:function(t){return n.dispatch(t)}},a=e[t].map((function(t){return t(i)}));return et.apply(void 0,C(a))(r)(o)}}}}))};function ne(t){return function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0,r={};if("initialize:aborted"===n.type)return e;if(/^registerPlugin:([^:]*)$/.test(n.type)){var o=re(n.type,"registerPlugin"),i=t()[o];if(!i||!o)return e;var a=n.enabled;return r[o]={enabled:a,initialized:!!a&&Boolean(!i.initialize),loaded:!!a&&Boolean(i.loaded()),config:i.config||{}},J(J({},e),r)}if(/^initialize:([^:]*)$/.test(n.type)){var u=re(n.type,ft.initialize),c=t()[u];return c&&u?(r[u]=J(J({},e[u]),{initialized:!0,loaded:Boolean(c.loaded())}),J(J({},e),r)):e}if(/^ready:([^:]*)$/.test(n.type))return r[n.name]=J(J({},e[n.name]),{loaded:!0}),J(J({},e),r);switch(n.type){case ft.disablePlugin:return J(J({},e),oe(n.plugins,!1,e));case ft.enablePlugin:return J(J({},e),oe(n.plugins,!0,e));default:return e}}}function re(t,e){return t.substring(e.length+1,t.length)}function oe(t,e,n){return t.reduce((function(t,r){return t[r]=J(J({},n[r]),{enabled:e}),t}),n)}function ie(t){try{return JSON.parse(JSON.stringify(t))}catch(e){}return t}var ae={last:{},history:[]};function ue(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ae,e=arguments.length>1?arguments[1]:void 0,n=e.type,r=e.event,o=e.properties,i=e.options,a=e.meta;switch(n){case ft.track:var u=ie(J(J({event:r,properties:o},Object.keys(i).length&&{options:i}),{},{meta:a}));return J(J({},t),{last:u,history:t.history.concat(u)});default:return t}}var ce={actions:[]};function se(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ce,e=arguments.length>1?arguments[1]:void 0,n=e.type,r=e.payload;switch(n){case"queue":var o;return o=r&&r.type&&r.type===ft.identify?[e].concat(t.actions):t.actions.concat(e),J(J({},t),{},{actions:o});case"dequeue":return[];default:return t}}var le=/#.*$/;function fe(t){var e=/(http[s]?:\/\/)?([^\/\s]+\/)(.*)/g.exec(t);return"/"+(e&&e[3]?e[3].split("?")[0].replace(le,""):"")}function pe(t){var e=function(){if(h)for(var t,e=document.getElementsByTagName("link"),n=0;t=e[n];n++)if("canonical"===t.getAttribute("rel"))return t.getAttribute("href")}();return e?e.match(/\?/)?e:e+t:window.location.href.replace(le,"")}var de,he,ge,ye,ve=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!h)return t;var e=document,n=e.title,r=e.referrer,o=window,i=o.location,a=o.innerWidth,u=o.innerHeight,c=i.hash,s=i.search,l=pe(s),f={title:n,url:l,path:fe(l),hash:c,search:s,width:a,height:u};return r&&""!==r&&(f.referrer=r),J(J({},f),t)},me={last:{},history:[]};function be(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:me,e=arguments.length>1?arguments[1]:void 0,n=e.properties,r=e.options,o=e.meta;switch(e.type){case ft.page:var i=ie(J({properties:n,meta:o},Object.keys(r).length&&{options:r}));return J(J({},t),{last:i,history:t.history.concat(i)});default:return t}}de=function(){if(!h)return!1;var t=navigator.appVersion;return~t.indexOf("Win")?"Windows":~t.indexOf("Mac")?"MacOS":~t.indexOf("X11")?"UNIX":~t.indexOf("Linux")?"Linux":"Unknown OS"}(),he=h?document.referrer:null,ge=function(){if(A){var t=navigator,e=t.language,n=t.languages;return t.userLanguage||(n&&n.length?n[0]:e)}}(),ye=function(){try{return Intl.DateTimeFormat().resolvedOptions().timeZone}catch(t){}}();var we={initialized:!1,sessionId:z(),app:null,version:null,debug:!1,offline:!!h&&!navigator.onLine,os:{name:de},userAgent:h?navigator.userAgent:"node",library:{name:"analytics",version:"0.10.9"},timezone:ye,locale:ge,campaign:{},referrer:he};function xe(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:we,e=arguments.length>1?arguments[1]:void 0,n=t.initialized,r=e.type,o=e.campaign;switch(r){case ft.campaign:return J(J({},t),{campaign:o});case ft.offline:return J(J({},t),{offline:!0});case ft.online:return J(J({},t),{offline:!1});default:return n?t:J(J(J({},we),t),{initialized:!0})}}var Se=["plugins","reducers","storage"];function Ee(t){return Object.keys(t).reduce((function(e,n){return Se.includes(n)||(e[n]=t[n]),e}),{})}function Ie(t,e,n){if(h){var r=window[(n?"add":"remove")+"EventListener"];t.split(" ").forEach((function(t){r(t,e)}))}}function Oe(t){var e=Ie.bind(null,"online offline",(function(e){return Promise.resolve(!navigator.onLine).then(t)}));return e(!0),function(t){return e(!1)}}function ke(){var t="__analytics__";return o(t,[]),function(t){return function(n,r,o){var i=t(n,r,o),a=i.dispatch;return Object.assign(i,{dispatch:function(t){var n=t.action||t;return e.__analytics__.push(n),a(t)}})}}}function Pe(t){return function(){return et(et.apply(null,arguments),ke())}}function _e(t){return t?(e=t,Array.isArray(e)?t:[t]):[];var e}function je(t){for(var e,n=t||Array.prototype.slice.call(arguments),r=0;r0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,r=z();return e&&(St[r]=Ae(e,je(n))),J(J({},t),{},{rid:r,ts:Ne()},e?{hasCallback:!0}:{})}function Le(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.reducers||{},a=e.initialUser||{},u=(e.plugins||[]).reduce((function(t,e){if(g(e))return t.middlewares=t.middlewares.concat(e),t;if(e.NAMESPACE&&(e.name=e.NAMESPACE),!e.name)throw new Error("https://lytics.dev/errors/1");var n=e.EVENTS?Object.keys(e.EVENTS).map((function(t){return e.EVENTS[t]})):[],r=!(!1===e.enabled),o=!(e.config&&!1===e.config.enabled);t.pluginEnabled[e.name]=r&&o,delete e.enabled,e.methods&&(t.methods[e.name]=Object.keys(e.methods).reduce((function(t,n){return t[n]=at(e.methods[n]),t}),{}),delete e.methods);var i=Object.keys(e).concat(n),a=new Set(t.events.concat(i));if(t.events=Array.from(a),t.pluginsArray=t.pluginsArray.concat(e),t.plugins[e.name])throw new Error(e.name+"AlreadyLoaded");return t.plugins[e.name]=e,t.plugins[e.name].loaded||(t.plugins[e.name].loaded=function(){return!0}),t}),{plugins:{},pluginEnabled:{},methods:{},pluginsArray:[],middlewares:[],events:[]}),c=e.storage?e.storage:{getItem:r,setItem:o,removeItem:i},s=wt(c),l=u.plugins,f=u.events.filter((function(t){return!lt.includes(t)})).sort(),p=new Set(f.concat(st).filter((function(t){return!lt.includes(t)}))),d=Array.from(p).sort(),v=function(){return l},m=new ee,w=m.addMiddleware,x=m.removeMiddleware,S=m.dynamicMiddlewares,E=function(){throw new Error("Abort disabled inListener")},I=T(),O=mt(c),k=J(J(J(J({},O),a),I.an_uid?{userId:I.an_uid}:{}),I.an_aid?{anonymousId:I.an_aid}:{});k.anonymousId||(k.anonymousId=z());var P,_,j,N=J({enable:function(t,e){return new Promise((function(n){W.dispatch({type:ft.enablePlugin,plugins:_e(t),_:{originalAction:ft.enablePlugin}},n,[e])}))},disable:function(t,e){return new Promise((function(n){W.dispatch({type:ft.disablePlugin,plugins:_e(t),_:{originalAction:ft.disablePlugin}},n,[e])}))}},u.methods),A={identify:(j=G(V.mark((function t(e,n,r,i){var a,u,c,l,f;return V.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return a=y(e)?e:null,u=b(e)?e:n,c=r||{},l=A.user(),o(bt(rt),a),f=a||u.userId||s(rt,A,u),t.abrupt("return",new Promise((function(t){W.dispatch(J({type:ft.identifyStart,userId:f,traits:u||{},options:c,anonymousId:l.anonymousId},l.id&&l.id!==a&&{previousId:l.id}),t,[n,r,i])})));case 7:case"end":return t.stop()}}),t)}))),function(t,e,n,r){return j.apply(this,arguments)}),track:(_=G(V.mark((function t(e,n,r,o){var i,a,u;return V.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if((i=b(e)?e.event:e)&&y(i)){t.next=3;break}throw new Error("EventMissing");case 3:return a=b(e)?e:n||{},u=b(r)?r:{},t.abrupt("return",new Promise((function(t){W.dispatch({type:ft.trackStart,event:i,properties:a,options:u,userId:s(rt,A,n),anonymousId:s(ot,A,n)},t,[n,r,o])})));case 6:case"end":return t.stop()}}),t)}))),function(t,e,n,r){return _.apply(this,arguments)}),page:(P=G(V.mark((function t(e,n,r){var o,i;return V.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return o=b(e)?e:{},i=b(n)?n:{},t.abrupt("return",new Promise((function(t){W.dispatch({type:ft.pageStart,properties:ve(o),options:i,userId:s(rt,A,o),anonymousId:s(ot,A,o)},t,[e,n,r])})));case 3:case"end":return t.stop()}}),t)}))),function(t,e,n){return P.apply(this,arguments)}),user:function(e){if(e===rt||"id"===e)return s(rt,A);if(e===ot||"anonId"===e)return s(ot,A);var n=A.getState("user");return e?t(n,e):n},reset:function(t){return new Promise((function(e){W.dispatch({type:ft.resetStart},e,t)}))},ready:function(t){return A.on(ft.ready,t)},on:function(t,e){if(!t||!g(e))return!1;if(t===ft.bootstrap)throw new Error(".on disabled for "+t);var n=/Start$|Start:/;if("*"===t){var r=function(t){return function(t){return function(r){return r.type.match(n)&&e({payload:r,instance:A,plugins:l}),t(r)}}},o=function(t){return function(t){return function(r){return r.type.match(n)||e({payload:r,instance:A,plugins:l}),t(r)}}};return w(r,ze),w(o,Me),function(){x(r,ze),x(o,Me)}}var i=t.match(n)?ze:Me,a=function(n){return function(n){return function(r){return r.type===t&&e({payload:r,instance:A,plugins:l,abort:E}),n(r)}}};return w(a,i),function(){return x(a,i)}},once:function(t,e){if(!t||!g(e))return!1;if(t===ft.bootstrap)throw new Error(".once disabled for "+t);var n=A.on(t,(function(t){var r=t.payload;e({payload:r,instance:A,plugins:l,abort:E}),n()}));return n},getState:function(e){var n=W.getState();return e?t(n,e):Object.assign({},n)},dispatch:function(t){var e=y(t)?{type:t}:t;if(pt(e.type))throw new Error("reserved action "+e.type);var n=t._||{},r=J(J({},e),{},{_:J({originalAction:e.type},n)});W.dispatch(r)},enablePlugin:N.enable,disablePlugin:N.disable,plugins:N,storage:{getItem:c.getItem,setItem:function(t,e,n){W.dispatch({type:ft.setItemStart,key:t,value:e,options:n})},removeItem:function(t,e){W.dispatch({type:ft.removeItemStart,key:t,options:e})}},setAnonymousId:function(t,e){A.storage.setItem(it,t,e)},events:{all:d,core:st,plugins:f}},L=function(t){return function(t){return function(e){return e.meta||(e.meta=Te()),t(e)}}},M=u.middlewares.concat([L,S(ze),Kt(A,v,{all:d,plugins:f}),Qt(c),yt(A),xt(A),S(Me)]),D={context:xe,user:vt(c),page:be,track:ue,plugins:ne(v),queue:se},U=et,q=et;if(h&&e.debug){var F=window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__;F&&(U=F({trace:!0,traceLimit:25})),q=function(){return 0===arguments.length?ke():b(R(arguments[0]))?Pe():Pe().apply(null,arguments)}}var $=Ee(e),B=u.pluginsArray.reduce((function(t,e){var n=e.name,r=e.config,o=e.loaded,i=u.pluginEnabled[n];return t[n]={enabled:i,initialized:!!i&&Boolean(!e.initialize),loaded:Boolean(o()),config:r||{}},t}),{}),X={context:$,user:k,plugins:B},W=K(tt(J(J({},D),n)),X,q(U(nt.apply(void 0,C(M)))));function Y(t){return function(e,n,r){var o=Te(e.meta,n,_e(r)),i=J(J({},e),{meta:o});return t.apply(null,[i])}}W.dispatch=Y(W.dispatch);var H=Object.keys(l);W.dispatch({type:ft.bootstrap,plugins:H,config:$,params:I,user:k,initialUser:a,persistedUser:O});var Z=H.filter((function(t){return u.pluginEnabled[t]})),Q=H.filter((function(t){return!u.pluginEnabled[t]}));function at(t){return function(){for(var e=Array.prototype.slice.call(arguments),n=new Array(t.length),r=0;r0&&void 0!==arguments[0]?arguments[0]:{},e={storage:j};return Le(Ce(Ce({},e),t))}export default qe;export{qe as Analytics,ct as CONSTANTS,ft as EVENTS,qe as init}; diff --git a/_app/chunks/preload-helper-78524df4.js b/_app/chunks/preload-helper-78524df4.js new file mode 100644 index 00000000..18369883 --- /dev/null +++ b/_app/chunks/preload-helper-78524df4.js @@ -0,0 +1 @@ +let e;const r={},t=function(t,n){if(!n||0===n.length)return t();if(void 0===e){const r=document.createElement("link").relList;e=r&&r.supports&&r.supports("modulepreload")?"modulepreload":"preload"}return Promise.all(n.map((t=>{if((t=`/mermaid-live-editor/_app/${t}`)in r)return;r[t]=!0;const n=t.endsWith(".css"),o=n?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${t}"]${o}`))return;const s=document.createElement("link");return s.rel=n?"stylesheet":e,n||(s.as="script",s.crossOrigin=""),s.href=t,document.head.appendChild(s),n?new Promise(((e,r)=>{s.addEventListener("load",e),s.addEventListener("error",r)})):void 0}))).then((()=>t()))};export{t as _}; diff --git a/_app/chunks/singletons-12a22614.js b/_app/chunks/singletons-12a22614.js new file mode 100644 index 00000000..d09d8e86 --- /dev/null +++ b/_app/chunks/singletons-12a22614.js @@ -0,0 +1 @@ +let t;function a(a){t=a}export{a as i,t as r}; diff --git a/_app/chunks/util-5805f6cc.js b/_app/chunks/util-5805f6cc.js new file mode 100644 index 00000000..9afddde6 --- /dev/null +++ b/_app/chunks/util-5805f6cc.js @@ -0,0 +1 @@ +var e=Object.defineProperty,a=Object.defineProperties,t=Object.getOwnPropertyDescriptors,r=Object.getOwnPropertySymbols,s=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable,i=(a,t,r)=>t in a?e(a,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):a[t]=r,n=(e,a)=>{for(var t in a||(a={}))s.call(a,t)&&i(e,t,a[t]);if(r)for(var t of r(a))o.call(a,t)&&i(e,t,a[t]);return e},c=(e,r)=>a(e,t(r));import{a4 as l,a5 as d,C as p,a6 as u,$ as m,a8 as f,ac as y,S as g,i as h,s as b,e as v,c as O,a as S,d as E,b as w,P as D,f as T,H as L,I as j,J as _,z as x,aa as C,ab as P,L as I}from"./vendor-134b46ff.js";import{_ as J}from"./preload-helper-78524df4.js";let A;let N;const k=l(p({code:"graph TD\n A[Christmas] --\x3e|Get money| B(Go shopping)\n B --\x3e C{Let me think}\n C --\x3e|One| D[Laptop]\n C --\x3e|Two| E[iPhone]\n C --\x3e|Three| F[fa:fa-car Car]\n ",mermaid:JSON.stringify({theme:"default"},null,2),updateEditor:!1,autoSync:!0,updateDiagram:!0}),d(),"codeStore"),V=u([k],(([e],a)=>{a(m(JSON.stringify(e),!0))})),$=e=>{k.update((a=>n(n({},a),e)))};let R=!1;const z=(e,a,t=!1)=>{var r;r=e,A&&(clearTimeout(N),N=setTimeout((function(){const e=r.replace(/^\s*%%.*\n/g,"\n").trimStart().split(" ")[0];console.debug("ga:","send","event","render",e),A.track("render",{graphType:e})}),5e3));if((e.match(/\n/g)||"").length+1>50&&!R&&f(k).autoSync){const e=confirm("Long diagram deteced. Turn off Auto Sync? Click the sync logo to manually sync.");R=!0,e&&$({autoSync:!1})}k.update((r=>c(n({},r),{code:e,updateEditor:a,updateDiagram:t})))},B=(e,a)=>{k.update((t=>c(n({},t),{mermaid:e,updateEditor:a})))},G=()=>JSON.stringify(f(k)),H=p(void 0);function F(e){let a,t;return{c(){a=v("div"),t=v("div"),this.h()},l(e){a=O(e,"DIV",{id:!0,class:!0});var r=S(a);t=O(r,"DIV",{id:!0,class:!0}),S(t).forEach(E),r.forEach(E),this.h()},h(){w(t,"id","container"),w(t,"class","flex-1 overflow-auto"),w(a,"id","view"),w(a,"class","p-2 svelte-5ndy2s"),D(a,"error",e[1]),D(a,"outOfSync",e[2])},m(r,s){T(r,a,s),L(a,t),e[3](t)},p(e,[t]){2&t&&D(a,"error",e[1]),4&t&&D(a,"outOfSync",e[2])},i:j,o:j,d(t){t&&E(a),e[3](null)}}}function M(e,a,t){let r;_(e,k,(e=>t(7,r=e)));let s,o="",i="",n=!1,c=!1,l=!0;return x((()=>{k.subscribe((e=>{try{if(s&&e&&(e.updateDiagram||e.autoSync)){if(e.autoSync||C(k,r.updateDiagram=!1,r),t(2,c=!1),l=!0,o===e.code&&i===e.mermaid)return;o=e.code,i=e.mermaid;const a=s.parentElement.parentElement.parentElement.scrollTop;delete s.dataset.processed,P.exports.initialize(Object.assign({},JSON.parse(e.mermaid))),P.exports.render("graph-div",o,(e=>{t(0,s.innerHTML=e,s)})),t(0,s.parentElement.parentElement.parentElement.scrollTop=a,s),t(1,n=!1)}else l?l=!1:t(2,c=!0)}catch(a){console.log("view fail",a),t(1,n=!0)}})),H.subscribe((e=>{void 0===e?t(1,n=!1):(t(1,n=!0),console.log("Error: ",e))}))})),[s,n,c,function(e){I[e?"unshift":"push"]((()=>{s=e,t(0,s)}))}]}class U extends g{constructor(e){super(),h(this,e,M,F,b,{})}}const q=()=>{(e=>{let a;try{const t=y(e);console.log(`Tring to load state: ${t}`),a=JSON.parse(t);const r="string"==typeof a.mermaid?JSON.parse(a.mermaid):a.mermaid;r.securityLevel&&"strict"!==r.securityLevel&&confirm(`Removing "securityLevel":"${r.securityLevel}" from the config for safety.\nClick Cancel if you trust the source of this Diagram.`)&&delete r.securityLevel,a.mermaid=JSON.stringify(r,null,2)}catch(t){e&&console.error("Init error",t),a=f(k),console.log(a)}$(c(n({},a),{updateEditor:!0}))})(window.location.hash.slice(1))},K=()=>{$({updateDiagram:!0})},Q=async()=>{q(),K(),V.subscribe((e=>{history.replaceState(void 0,void 0,`#${e}`)})),await(async()=>{if(!A)try{const{Analytics:e}=await J((()=>import("./analytics.browser.es-de8d1c22.js")),[]),a=await J((()=>import("./analytics-plugin-ga.browser.es-1cdb0512.js")),[]);A=e({app:"mermaid-live-editor",plugins:[a.init({trackingId:"UA-153180559-1"})]})}catch{console.info("Analytics blocked ;)")}})(),null==A||A.page()};export{U as V,A as a,V as b,k as c,B as d,H as e,G as g,Q as i,K as s,z as u}; diff --git a/_app/chunks/vendor-134b46ff.js b/_app/chunks/vendor-134b46ff.js new file mode 100644 index 00000000..e5cff95b --- /dev/null +++ b/_app/chunks/vendor-134b46ff.js @@ -0,0 +1,40 @@ +function t(){}const e=t=>t;function n(t,e){for(const n in e)t[n]=e[n];return t}function r(t){return t()}function i(){return Object.create(null)}function a(t){t.forEach(r)}function o(t){return"function"==typeof t}function s(t,e){return t!=t?e==e:t!==e||t&&"object"==typeof t||"function"==typeof t}function c(e,...n){if(null==e)return t;const r=e.subscribe(...n);return r.unsubscribe?()=>r.unsubscribe():r}function l(t){let e;return c(t,(t=>e=t))(),e}function u(t,e,n){t.$$.on_destroy.push(c(e,n))}function h(t,e,n,r){if(t){const i=d(t,e,n,r);return t[0](i)}}function d(t,e,r,i){return t[1]&&i?n(r.ctx.slice(),t[1](i(e))):r.ctx}function f(t,e,n,r){if(t[2]&&r){const i=t[2](r(n));if(void 0===e.dirty)return i;if("object"==typeof i){const t=[],n=Math.max(e.dirty.length,i.length);for(let r=0;r32){const e=[],n=t.ctx.length/32;for(let t=0;twindow.performance.now():()=>Date.now(),_=v?t=>requestAnimationFrame(t):t;const w=new Set;function x(t){w.forEach((e=>{e.c(t)||(w.delete(e),e.f())})),0!==w.size&&_(x)}let k=!1;function C(t,e,n,r){for(;t>1);n(i)<=r?t=i+1:e=i}return t}function T(t){if(!t)return document;const e=t.getRootNode?t.getRootNode():t.ownerDocument;return e.host?e:document}function E(t){const e=D("style");return function(t,e){!function(t,e){t.appendChild(e)}(t.head||t,e)}(T(t),e),e}function S(t,e){if(k){for(!function(t){if(t.hydrate_init)return;t.hydrate_init=!0;let e=t.childNodes;if("HEAD"===t.nodeName){const t=[];for(let n=0;n0&&e[n[i]].claim_order<=t?i+1:C(1,i,(t=>e[n[t]].claim_order),t))-1;r[c]=n[a]+1;const o=a+1;n[o]=c,i=Math.max(o,i)}const a=[],o=[];let s=e.length-1;for(let c=n[i]+1;0!=c;c=r[c-1]){for(a.push(e[c-1]);s>=c;s--)o.push(e[s]);s--}for(;s>=0;s--)o.push(e[s]);a.reverse(),o.sort(((t,e)=>t.claim_order-e.claim_order));for(let c=0,l=0;c=a[l].claim_order;)l++;const e=lt.removeEventListener(e,n,r)}function I(t){return function(e){return e.stopPropagation(),t.call(this,e)}}function F(t,e,n){null==n?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}function P(t){return""===t?null:+t}function Y(t){return Array.from(t.childNodes)}function z(t,e,n,r,i=!1){!function(t){void 0===t.claim_info&&(t.claim_info={last_index:0,total_claimed:0})}(t);const a=(()=>{for(let r=t.claim_info.last_index;r=0;r--){const a=t[r];if(e(a)){const e=n(a);return void 0===e?t.splice(r,1):t[r]=e,i?void 0===e&&t.claim_info.last_index--:t.claim_info.last_index=r,a}}return r()})();return a.claim_order=t.claim_info.total_claimed,t.claim_info.total_claimed+=1,a}function U(t,e,n,r){return z(t,(t=>t.nodeName===e),(t=>{const e=[];for(let r=0;rt.removeAttribute(e)))}),(()=>r?j(e):D(e)))}function $(t,e){return z(t,(t=>3===t.nodeType),(t=>{const n=""+e;if(t.data.startsWith(n)){if(t.data.length!==n.length)return t.splitText(n.length)}else t.data=n}),(()=>N(e)),!0)}function W(t){return $(t," ")}function q(t,e){e=""+e,t.wholeText!==e&&(t.data=e)}function H(t,e){t.value=null==e?"":e}function V(t,e,n,r){t.style.setProperty(e,n,r?"important":"")}function G(t,e,n){t.classList[n?"add":"remove"](e)}function X(t,e,n=!1){const r=document.createEvent("CustomEvent");return r.initCustomEvent(t,n,!1,e),r}const Z=new Set;let Q,K=0;function J(t,e,n,r,i,a,o,s=0){const c=16.666/r;let l="{\n";for(let y=0;y<=1;y+=c){const t=e+(n-e)*a(y);l+=100*y+`%{${o(t,1-t)}}\n`}const u=l+`100% {${o(n,1-n)}}\n}`,h=`__svelte_${function(t){let e=5381,n=t.length;for(;n--;)e=(e<<5)-e^t.charCodeAt(n);return e>>>0}(u)}_${s}`,d=T(t);Z.add(d);const f=d.__svelte_stylesheet||(d.__svelte_stylesheet=E(t).sheet),p=d.__svelte_rules||(d.__svelte_rules={});p[h]||(p[h]=!0,f.insertRule(`@keyframes ${h} ${u}`,f.cssRules.length));const g=t.style.animation||"";return t.style.animation=`${g?`${g}, `:""}${h} ${r}ms linear ${i}ms 1 both`,K+=1,h}function tt(t,e){const n=(t.style.animation||"").split(", "),r=n.filter(e?t=>t.indexOf(e)<0:t=>-1===t.indexOf("__svelte")),i=n.length-r.length;i&&(t.style.animation=r.join(", "),K-=i,K||_((()=>{K||(Z.forEach((t=>{const e=t.__svelte_stylesheet;let n=e.cssRules.length;for(;n--;)e.deleteRule(n);t.__svelte_rules={}})),Z.clear())})))}function et(t){Q=t}function nt(){if(!Q)throw new Error("Function called outside component initialization");return Q}function rt(t){nt().$$.on_mount.push(t)}function it(t){nt().$$.after_update.push(t)}function at(){const t=nt();return(e,n)=>{const r=t.$$.callbacks[e];if(r){const i=X(e,n);r.slice().forEach((e=>{e.call(t,i)}))}}}function ot(t,e){nt().$$.context.set(t,e)}function st(t,e){const n=t.$$.callbacks[e.type];n&&n.slice().forEach((t=>t.call(this,e)))}const ct=[],lt=[],ut=[],ht=[],dt=Promise.resolve();let ft=!1;function pt(t){ut.push(t)}function gt(t){ht.push(t)}let yt=!1;const mt=new Set;function vt(){if(!yt){yt=!0;do{for(let t=0;t{xt.delete(t),r&&(n&&t.d(1),r())})),t.o(e)}}const Ot={duration:0};function At(n,r,i,s){let c=r(n,i),l=s?0:1,u=null,h=null,d=null;function f(){d&&tt(n,d)}function p(t,e){const n=t.b-l;return e*=Math.abs(n),{a:l,b:t.b,d:n,duration:e,start:t.start,end:t.start+e,group:t.group}}function g(r){const{delay:i=0,duration:o=300,easing:s=e,tick:g=t,css:y}=c||Ot,m={start:b()+i,b:r};r||(m.group=kt,kt.r+=1),u||h?h=m:(y&&(f(),d=J(n,l,r,o,i,s,y)),r&&g(0,1),u=p(m,o),pt((()=>wt(n,r,"start"))),function(t){let e;0===w.size&&_(x),new Promise((n=>{w.add(e={c:t,f:n})}))}((t=>{if(h&&t>h.start&&(u=p(h,o),h=null,wt(n,u.b,"start"),y&&(f(),d=J(n,l,u.b,u.duration,0,s,c.css))),u)if(t>=u.end)g(l=u.b,1-l),wt(n,u.b,"end"),h||(u.b?f():--u.group.r||a(u.group.c)),u=null;else if(t>=u.start){const e=t-u.start;l=u.a+u.d*s(e/u.duration),g(l,1-l)}return!(!u&&!h)})))}return{run(t){o(c)?(_t||(_t=Promise.resolve(),_t.then((()=>{_t=null}))),_t).then((()=>{c=c(),g(t)})):g(t)},end(){f(),u=h=null}}}function Mt(t,e){const n={},r={},i={$$scope:1};let a=t.length;for(;a--;){const o=t[a],s=e[a];if(s){for(const t in o)t in s||(r[t]=1);for(const t in s)i[t]||(n[t]=s[t],i[t]=1);t[a]=s}else for(const t in o)i[t]=1}for(const o in r)o in n||(n[o]=void 0);return n}function Dt(t){return"object"==typeof t&&null!==t?t:{}}function jt(t,e,n){const r=t.$$.props[e];void 0!==r&&(t.$$.bound[r]=n,n(t.$$.ctx[r]))}function Nt(t){t&&t.c()}function Bt(t,e){t&&t.l(e)}function Lt(t,e,n,i){const{fragment:s,on_mount:c,on_destroy:l,after_update:u}=t.$$;s&&s.m(e,n),i||pt((()=>{const e=c.map(r).filter(o);l?l.push(...e):a(e),t.$$.on_mount=[]})),u.forEach(pt)}function Rt(t,e){const n=t.$$;null!==n.fragment&&(a(n.on_destroy),n.fragment&&n.fragment.d(e),n.on_destroy=n.fragment=null,n.ctx=[])}function It(t,e){-1===t.$$.dirty[0]&&(ct.push(t),ft||(ft=!0,dt.then(vt)),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<{const i=r.length?r[0]:n;return d.ctx&&s(d.ctx[t],d.ctx[t]=i)&&(!d.skip_bound&&d.bound[t]&&d.bound[t](i),f&&It(e,t)),n})):[],d.update(),f=!0,a(d.before_update),d.fragment=!!o&&o(d.ctx),n.target){if(n.hydrate){k=!0;const t=Y(n.target);d.fragment&&d.fragment.l(t),t.forEach(A)}else d.fragment&&d.fragment.c();n.intro&&Et(e.$$.fragment),Lt(e,n.target,n.anchor,n.customElement),k=!1,vt()}et(h)}class Pt{$destroy(){Rt(this,1),this.$destroy=t}$on(t,e){const n=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return n.push(e),()=>{const t=n.indexOf(e);-1!==t&&n.splice(t,1)}}$set(t){var e;this.$$set&&(e=t,0!==Object.keys(e).length)&&(this.$$.skip_bound=!0,this.$$set(t),this.$$.skip_bound=!1)}}const Yt=[];function zt(e,n=t){let r;const i=new Set;function a(t){if(s(e,t)&&(e=t,r)){const t=!Yt.length;for(const n of i)n[1](),Yt.push(n,e);if(t){for(let t=0;t{i.delete(c),0===i.size&&(r(),r=null)}}}}function Ut(e,n,r){const i=!Array.isArray(e),s=i?[e]:e,l=n.length<2;return{subscribe:zt(r,(e=>{let r=!1;const u=[];let h=0,d=t;const f=()=>{if(h)return;d();const r=n(i?u[0]:u,e);l?e(r):d=o(r)?r:t},p=s.map(((t,e)=>c(t,(t=>{u[e]=t,h&=~(1<{h|=1<{let e={};return Gt.forEach(((t,n)=>e[t]=n)),e})(),Zt=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,Qt=String.fromCharCode.bind(String),Kt="function"==typeof Uint8Array.from?Uint8Array.from.bind(Uint8Array):(t,e=(t=>t))=>new Uint8Array(Array.prototype.slice.call(t,0).map(e)),Jt=t=>t.replace(/[^A-Za-z0-9\+\/]/g,""),te=Wt?t=>btoa(t):qt?t=>Buffer.from(t,"binary").toString("base64"):t=>{let e,n,r,i,a="";const o=t.length%3;for(let s=0;s255||(r=t.charCodeAt(s++))>255||(i=t.charCodeAt(s++))>255)throw new TypeError("invalid character found");e=n<<16|r<<8|i,a+=Gt[e>>18&63]+Gt[e>>12&63]+Gt[e>>6&63]+Gt[63&e]}return o?a.slice(0,o-3)+"===".substring(o):a},ee=qt?t=>Buffer.from(t).toString("base64"):t=>{let e=[];for(let n=0,r=t.length;n{if(t.length<2)return(e=t.charCodeAt(0))<128?t:e<2048?Qt(192|e>>>6)+Qt(128|63&e):Qt(224|e>>>12&15)+Qt(128|e>>>6&63)+Qt(128|63&e);var e=65536+1024*(t.charCodeAt(0)-55296)+(t.charCodeAt(1)-56320);return Qt(240|e>>>18&7)+Qt(128|e>>>12&63)+Qt(128|e>>>6&63)+Qt(128|63&e)},re=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,ie=qt?t=>Buffer.from(t,"utf8").toString("base64"):Vt?t=>ee(Vt.encode(t)):t=>te(t.replace(re,ne)),ae=(t,e=!1)=>e?(t=>t.replace(/[+\/]/g,(t=>"+"==t?"-":"_")).replace(/=+$/m,""))(ie(t)):ie(t),oe=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,se=t=>{switch(t.length){case 4:var e=((7&t.charCodeAt(0))<<18|(63&t.charCodeAt(1))<<12|(63&t.charCodeAt(2))<<6|63&t.charCodeAt(3))-65536;return Qt(55296+(e>>>10))+Qt(56320+(1023&e));case 3:return Qt((15&t.charCodeAt(0))<<12|(63&t.charCodeAt(1))<<6|63&t.charCodeAt(2));default:return Qt((31&t.charCodeAt(0))<<6|63&t.charCodeAt(1))}},ce=$t?t=>atob(Jt(t)):qt?t=>Buffer.from(t,"base64").toString("binary"):t=>{if(t=t.replace(/\s+/g,""),!Zt.test(t))throw new TypeError("malformed base64.");t+="==".slice(2-(3&t.length));let e,n,r,i="";for(let a=0;a>16&255):64===r?Qt(e>>16&255,e>>8&255):Qt(e>>16&255,e>>8&255,255&e);return i},le=qt?t=>Kt(Buffer.from(t,"base64")):t=>Kt(ce(t),(t=>t.charCodeAt(0))),ue=qt?t=>Buffer.from(t,"base64").toString("utf8"):Ht?t=>Ht.decode(le(t)):t=>ce(t).replace(oe,se),he=t=>ue(Jt(t.replace(/[-_]/g,(t=>"-"==t?"+":"/"))));function de(t,e,n){const r=e.getValue(n);return null!==r&&t.set(r),e.addListener&&e.addListener(n,(e=>{t.set(e)})),t.subscribe((t=>{e.setValue(n,t)})),Object.assign(Object.assign({},t),{delete(){e.deleteValue(n)}})}function fe(t,e=!1){const n=[],r=e=>{const r=e.key;e.storageArea===t&&n.filter((({key:t})=>t===r)).forEach((({listener:t})=>{let n=e.newValue;try{n=JSON.parse(e.newValue)}catch(r){}t(n)}))};return{addListener(t,i){n.push({key:t,listener:i}),1===n.length&&e&&"undefined"!=typeof window&&(null===window||void 0===window?void 0:window.addEventListener)&&window.addEventListener("storage",r)},removeListener(t,i){const a=n.indexOf({key:t,listener:i});-1!==a&&n.splice(a,1),0===n.length&&e&&"undefined"!=typeof window&&(null===window||void 0===window?void 0:window.removeEventListener)&&window.removeEventListener("storage",r)},getValue(e){let n=t.getItem(e);if(null!=n)try{n=JSON.parse(n)}catch(r){}return n},deleteValue(e){t.removeItem(e)},setValue(e,n){t.setItem(e,JSON.stringify(n))}}}function pe(t=!1){return"undefined"!=typeof window&&(null===window||void 0===window?void 0:window.localStorage)?fe(window.localStorage,t):(console.warn("Unable to find the localStorage. No data will be persisted."),{getValue:()=>null,deleteValue(){},setValue(){}})}const ge="8.11.2";function ye(t){const e=t-1;return e*e*e+1}function me(t,{delay:n=0,duration:r=400,easing:i=e}={}){const a=+getComputedStyle(t).opacity;return{delay:n,duration:r,easing:i,css:t=>"opacity: "+t*a}}function ve(t,{delay:e=0,duration:n=400,easing:r=ye}={}){const i=getComputedStyle(t),a=+i.opacity,o=parseFloat(i.height),s=parseFloat(i.paddingTop),c=parseFloat(i.paddingBottom),l=parseFloat(i.marginTop),u=parseFloat(i.marginBottom),h=parseFloat(i.borderTopWidth),d=parseFloat(i.borderBottomWidth);return{delay:e,duration:n,easing:r,css:t=>`overflow: hidden;opacity: ${Math.min(20*t,1)*a};height: ${t*o}px;padding-top: ${t*s}px;padding-bottom: ${t*c}px;margin-top: ${t*l}px;margin-bottom: ${t*u}px;border-top-width: ${t*h}px;border-bottom-width: ${t*d}px;`}} +//! moment.js +//! version : 2.29.1 +//! authors : Tim Wood, Iskren Chernev, Moment.js contributors +//! license : MIT +//! momentjs.com +var be,_e;function we(){return be.apply(null,arguments)}function xe(t){return t instanceof Array||"[object Array]"===Object.prototype.toString.call(t)}function ke(t){return null!=t&&"[object Object]"===Object.prototype.toString.call(t)}function Ce(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function Te(t){if(Object.getOwnPropertyNames)return 0===Object.getOwnPropertyNames(t).length;var e;for(e in t)if(Ce(t,e))return!1;return!0}function Ee(t){return void 0===t}function Se(t){return"number"==typeof t||"[object Number]"===Object.prototype.toString.call(t)}function Oe(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function Ae(t,e){var n,r=[];for(n=0;n>>0;for(e=0;e0)for(n=0;n=0?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}var Xe=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Ze=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,Qe={},Ke={};function Je(t,e,n,r){var i=r;"string"==typeof r&&(i=function(){return this[r]()}),t&&(Ke[t]=i),e&&(Ke[e[0]]=function(){return Ge(i.apply(this,arguments),e[1],e[2])}),n&&(Ke[n]=function(){return this.localeData().ordinal(i.apply(this,arguments),t)})}function tn(t,e){return t.isValid()?(e=en(e,t.localeData()),Qe[e]=Qe[e]||function(t){var e,n,r,i=t.match(Xe);for(e=0,n=i.length;e=0&&Ze.test(t);)t=t.replace(Ze,r),Ze.lastIndex=0,n-=1;return t}var nn={};function rn(t,e){var n=t.toLowerCase();nn[n]=nn[n+"s"]=nn[e]=t}function an(t){return"string"==typeof t?nn[t]||nn[t.toLowerCase()]:void 0}function on(t){var e,n,r={};for(n in t)Ce(t,n)&&(e=an(n))&&(r[e]=t[n]);return r}var sn={};function cn(t,e){sn[t]=e}function ln(t){return t%4==0&&t%100!=0||t%400==0}function un(t){return t<0?Math.ceil(t)||0:Math.floor(t)}function hn(t){var e=+t,n=0;return 0!==e&&isFinite(e)&&(n=un(e)),n}function dn(t,e){return function(n){return null!=n?(pn(this,t,n),we.updateOffset(this,e),this):fn(this,t)}}function fn(t,e){return t.isValid()?t._d["get"+(t._isUTC?"UTC":"")+e]():NaN}function pn(t,e,n){t.isValid()&&!isNaN(n)&&("FullYear"===e&&ln(t.year())&&1===t.month()&&29===t.date()?(n=hn(n),t._d["set"+(t._isUTC?"UTC":"")+e](n,t.month(),Yn(n,t.month()))):t._d["set"+(t._isUTC?"UTC":"")+e](n))}var gn,yn=/\d/,mn=/\d\d/,vn=/\d{3}/,bn=/\d{4}/,_n=/[+-]?\d{6}/,wn=/\d\d?/,xn=/\d\d\d\d?/,kn=/\d\d\d\d\d\d?/,Cn=/\d{1,3}/,Tn=/\d{1,4}/,En=/[+-]?\d{1,6}/,Sn=/\d+/,On=/[+-]?\d+/,An=/Z|[+-]\d\d:?\d\d/gi,Mn=/Z|[+-]\d\d(?::?\d\d)?/gi,Dn=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i;function jn(t,e,n){gn[t]=qe(e)?e:function(t,r){return t&&n?n:e}}function Nn(t,e){return Ce(gn,t)?gn[t](e._strict,e._locale):new RegExp(Bn(t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,(function(t,e,n,r,i){return e||n||r||i}))))}function Bn(t){return t.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}gn={};var Ln={};function Rn(t,e){var n,r=e;for("string"==typeof t&&(t=[t]),Se(e)&&(r=function(t,n){n[e]=hn(t)}),n=0;n68?1900:2e3)};var Qn=dn("FullYear",!0);function Kn(t,e,n,r,i,a,o){var s;return t<100&&t>=0?(s=new Date(t+400,e,n,r,i,a,o),isFinite(s.getFullYear())&&s.setFullYear(t)):s=new Date(t,e,n,r,i,a,o),s}function Jn(t){var e,n;return t<100&&t>=0?((n=Array.prototype.slice.call(arguments))[0]=t+400,e=new Date(Date.UTC.apply(null,n)),isFinite(e.getUTCFullYear())&&e.setUTCFullYear(t)):e=new Date(Date.UTC.apply(null,arguments)),e}function tr(t,e,n){var r=7+e-n;return-((7+Jn(t,0,r).getUTCDay()-e)%7)+r-1}function er(t,e,n,r,i){var a,o,s=1+7*(e-1)+(7+n-r)%7+tr(t,r,i);return s<=0?o=Zn(a=t-1)+s:s>Zn(t)?(a=t+1,o=s-Zn(t)):(a=t,o=s),{year:a,dayOfYear:o}}function nr(t,e,n){var r,i,a=tr(t.year(),e,n),o=Math.floor((t.dayOfYear()-a-1)/7)+1;return o<1?r=o+rr(i=t.year()-1,e,n):o>rr(t.year(),e,n)?(r=o-rr(t.year(),e,n),i=t.year()+1):(i=t.year(),r=o),{week:r,year:i}}function rr(t,e,n){var r=tr(t,e,n),i=tr(t+1,e,n);return(Zn(t)-r+i)/7}Je("w",["ww",2],"wo","week"),Je("W",["WW",2],"Wo","isoWeek"),rn("week","w"),rn("isoWeek","W"),cn("week",5),cn("isoWeek",5),jn("w",wn),jn("ww",wn,mn),jn("W",wn),jn("WW",wn,mn),In(["w","ww","W","WW"],(function(t,e,n,r){e[r.substr(0,1)]=hn(t)}));function ir(t,e){return t.slice(e,7).concat(t.slice(0,e))}Je("d",0,"do","day"),Je("dd",0,0,(function(t){return this.localeData().weekdaysMin(this,t)})),Je("ddd",0,0,(function(t){return this.localeData().weekdaysShort(this,t)})),Je("dddd",0,0,(function(t){return this.localeData().weekdays(this,t)})),Je("e",0,0,"weekday"),Je("E",0,0,"isoWeekday"),rn("day","d"),rn("weekday","e"),rn("isoWeekday","E"),cn("day",11),cn("weekday",11),cn("isoWeekday",11),jn("d",wn),jn("e",wn),jn("E",wn),jn("dd",(function(t,e){return e.weekdaysMinRegex(t)})),jn("ddd",(function(t,e){return e.weekdaysShortRegex(t)})),jn("dddd",(function(t,e){return e.weekdaysRegex(t)})),In(["dd","ddd","dddd"],(function(t,e,n,r){var i=n._locale.weekdaysParse(t,r,n._strict);null!=i?e.d=i:je(n).invalidWeekday=t})),In(["d","e","E"],(function(t,e,n,r){e[r]=hn(t)}));var ar="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),or="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),sr="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),cr=Dn,lr=Dn,ur=Dn;function hr(t,e,n){var r,i,a,o=t.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],r=0;r<7;++r)a=De([2e3,1]).day(r),this._minWeekdaysParse[r]=this.weekdaysMin(a,"").toLocaleLowerCase(),this._shortWeekdaysParse[r]=this.weekdaysShort(a,"").toLocaleLowerCase(),this._weekdaysParse[r]=this.weekdays(a,"").toLocaleLowerCase();return n?"dddd"===e?-1!==(i=Pn.call(this._weekdaysParse,o))?i:null:"ddd"===e?-1!==(i=Pn.call(this._shortWeekdaysParse,o))?i:null:-1!==(i=Pn.call(this._minWeekdaysParse,o))?i:null:"dddd"===e?-1!==(i=Pn.call(this._weekdaysParse,o))||-1!==(i=Pn.call(this._shortWeekdaysParse,o))||-1!==(i=Pn.call(this._minWeekdaysParse,o))?i:null:"ddd"===e?-1!==(i=Pn.call(this._shortWeekdaysParse,o))||-1!==(i=Pn.call(this._weekdaysParse,o))||-1!==(i=Pn.call(this._minWeekdaysParse,o))?i:null:-1!==(i=Pn.call(this._minWeekdaysParse,o))||-1!==(i=Pn.call(this._weekdaysParse,o))||-1!==(i=Pn.call(this._shortWeekdaysParse,o))?i:null}function dr(){function t(t,e){return e.length-t.length}var e,n,r,i,a,o=[],s=[],c=[],l=[];for(e=0;e<7;e++)n=De([2e3,1]).day(e),r=Bn(this.weekdaysMin(n,"")),i=Bn(this.weekdaysShort(n,"")),a=Bn(this.weekdays(n,"")),o.push(r),s.push(i),c.push(a),l.push(r),l.push(i),l.push(a);o.sort(t),s.sort(t),c.sort(t),l.sort(t),this._weekdaysRegex=new RegExp("^("+l.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+c.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+o.join("|")+")","i")}function fr(){return this.hours()%12||12}function pr(t,e){Je(t,0,0,(function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)}))}function gr(t,e){return e._meridiemParse}Je("H",["HH",2],0,"hour"),Je("h",["hh",2],0,fr),Je("k",["kk",2],0,(function(){return this.hours()||24})),Je("hmm",0,0,(function(){return""+fr.apply(this)+Ge(this.minutes(),2)})),Je("hmmss",0,0,(function(){return""+fr.apply(this)+Ge(this.minutes(),2)+Ge(this.seconds(),2)})),Je("Hmm",0,0,(function(){return""+this.hours()+Ge(this.minutes(),2)})),Je("Hmmss",0,0,(function(){return""+this.hours()+Ge(this.minutes(),2)+Ge(this.seconds(),2)})),pr("a",!0),pr("A",!1),rn("hour","h"),cn("hour",13),jn("a",gr),jn("A",gr),jn("H",wn),jn("h",wn),jn("k",wn),jn("HH",wn,mn),jn("hh",wn,mn),jn("kk",wn,mn),jn("hmm",xn),jn("hmmss",kn),jn("Hmm",xn),jn("Hmmss",kn),Rn(["H","HH"],3),Rn(["k","kk"],(function(t,e,n){var r=hn(t);e[3]=24===r?0:r})),Rn(["a","A"],(function(t,e,n){n._isPm=n._locale.isPM(t),n._meridiem=t})),Rn(["h","hh"],(function(t,e,n){e[3]=hn(t),je(n).bigHour=!0})),Rn("hmm",(function(t,e,n){var r=t.length-2;e[3]=hn(t.substr(0,r)),e[4]=hn(t.substr(r)),je(n).bigHour=!0})),Rn("hmmss",(function(t,e,n){var r=t.length-4,i=t.length-2;e[3]=hn(t.substr(0,r)),e[4]=hn(t.substr(r,2)),e[5]=hn(t.substr(i)),je(n).bigHour=!0})),Rn("Hmm",(function(t,e,n){var r=t.length-2;e[3]=hn(t.substr(0,r)),e[4]=hn(t.substr(r))})),Rn("Hmmss",(function(t,e,n){var r=t.length-4,i=t.length-2;e[3]=hn(t.substr(0,r)),e[4]=hn(t.substr(r,2)),e[5]=hn(t.substr(i))}));var yr=dn("Hours",!0);var mr,vr={calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},longDateFormat:{LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:/\d{1,2}/,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},months:zn,monthsShort:Un,week:{dow:0,doy:6},weekdays:ar,weekdaysMin:sr,weekdaysShort:or,meridiemParse:/[ap]\.?m?\.?/i},br={},_r={};function wr(t,e){var n,r=Math.min(t.length,e.length);for(n=0;n0;){if(r=kr(i.slice(0,e).join("-")))return r;if(n&&n.length>=e&&wr(i,n)>=e-1)break;e--}a++}return mr}(t)}function Sr(t){var e,n=t._a;return n&&-2===je(t).overflow&&(e=n[1]<0||n[1]>11?1:n[2]<1||n[2]>Yn(n[0],n[1])?2:n[3]<0||n[3]>24||24===n[3]&&(0!==n[4]||0!==n[5]||0!==n[6])?3:n[4]<0||n[4]>59?4:n[5]<0||n[5]>59?5:n[6]<0||n[6]>999?6:-1,je(t)._overflowDayOfYear&&(e<0||e>2)&&(e=2),je(t)._overflowWeeks&&-1===e&&(e=7),je(t)._overflowWeekday&&-1===e&&(e=8),je(t).overflow=e),t}var Or=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,Ar=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,Mr=/Z|[+-]\d\d(?::?\d\d)?/,Dr=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],jr=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],Nr=/^\/?Date\((-?\d+)/i,Br=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,Lr={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function Rr(t){var e,n,r,i,a,o,s=t._i,c=Or.exec(s)||Ar.exec(s);if(c){for(je(t).iso=!0,e=0,n=Dr.length;e7)&&(c=!0)):(a=t._locale._week.dow,o=t._locale._week.doy,l=nr(Wr(),a,o),n=Pr(e.gg,t._a[0],l.year),r=Pr(e.w,l.week),null!=e.d?((i=e.d)<0||i>6)&&(c=!0):null!=e.e?(i=e.e+a,(e.e<0||e.e>6)&&(c=!0)):i=a);r<1||r>rr(n,a,o)?je(t)._overflowWeeks=!0:null!=c?je(t)._overflowWeekday=!0:(s=er(n,r,i,a,o),t._a[0]=s.year,t._dayOfYear=s.dayOfYear)}(t),null!=t._dayOfYear&&(a=Pr(t._a[0],r[0]),(t._dayOfYear>Zn(a)||0===t._dayOfYear)&&(je(t)._overflowDayOfYear=!0),n=Jn(a,0,t._dayOfYear),t._a[1]=n.getUTCMonth(),t._a[2]=n.getUTCDate()),e=0;e<3&&null==t._a[e];++e)t._a[e]=o[e]=r[e];for(;e<7;e++)t._a[e]=o[e]=null==t._a[e]?2===e?1:0:t._a[e];24===t._a[3]&&0===t._a[4]&&0===t._a[5]&&0===t._a[6]&&(t._nextDay=!0,t._a[3]=0),t._d=(t._useUTC?Jn:Kn).apply(null,o),i=t._useUTC?t._d.getUTCDay():t._d.getDay(),null!=t._tzm&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),t._nextDay&&(t._a[3]=24),t._w&&void 0!==t._w.d&&t._w.d!==i&&(je(t).weekdayMismatch=!0)}}function zr(t){if(t._f!==we.ISO_8601)if(t._f!==we.RFC_2822){t._a=[],je(t).empty=!0;var e,n,r,i,a,o,s=""+t._i,c=s.length,l=0;for(r=en(t._f,t._locale).match(Xe)||[],e=0;e0&&je(t).unusedInput.push(a),s=s.slice(s.indexOf(n)+n.length),l+=n.length),Ke[i]?(n?je(t).empty=!1:je(t).unusedTokens.push(i),Fn(i,n,t)):t._strict&&!n&&je(t).unusedTokens.push(i);je(t).charsLeftOver=c-l,s.length>0&&je(t).unusedInput.push(s),t._a[3]<=12&&!0===je(t).bigHour&&t._a[3]>0&&(je(t).bigHour=void 0),je(t).parsedDateParts=t._a.slice(0),je(t).meridiem=t._meridiem,t._a[3]=function(t,e,n){var r;if(null==n)return e;return null!=t.meridiemHour?t.meridiemHour(e,n):null!=t.isPM?((r=t.isPM(n))&&e<12&&(e+=12),r||12!==e||(e=0),e):e}(t._locale,t._a[3],t._meridiem),null!==(o=je(t).era)&&(t._a[0]=t._locale.erasConvertYear(o,t._a[0])),Yr(t),Sr(t)}else Fr(t);else Rr(t)}function Ur(t){var e=t._i,n=t._f;return t._locale=t._locale||Er(t._l),null===e||void 0===n&&""===e?Be({nullInput:!0}):("string"==typeof e&&(t._i=e=t._locale.preparse(e)),Pe(e)?new Fe(Sr(e)):(Oe(e)?t._d=e:xe(n)?function(t){var e,n,r,i,a,o,s=!1;if(0===t._f.length)return je(t).invalidFormat=!0,void(t._d=new Date(NaN));for(i=0;ithis?this:t:Be()}));function Vr(t,e){var n,r;if(1===e.length&&xe(e[0])&&(e=e[0]),!e.length)return Wr();for(n=e[0],r=1;r=0?new Date(t+400,e,n)-126227808e5:new Date(t,e,n).valueOf()}function xi(t,e,n){return t<100&&t>=0?Date.UTC(t+400,e,n)-126227808e5:Date.UTC(t,e,n)}function ki(t,e){return e.erasAbbrRegex(t)}function Ci(){var t,e,n=[],r=[],i=[],a=[],o=this.eras();for(t=0,e=o.length;t(a=rr(t,r,i))&&(e=a),Si.call(this,t,e,n,r,i))}function Si(t,e,n,r,i){var a=er(t,e,n,r,i),o=Jn(a.year,0,a.dayOfYear);return this.year(o.getUTCFullYear()),this.month(o.getUTCMonth()),this.date(o.getUTCDate()),this}Je("N",0,0,"eraAbbr"),Je("NN",0,0,"eraAbbr"),Je("NNN",0,0,"eraAbbr"),Je("NNNN",0,0,"eraName"),Je("NNNNN",0,0,"eraNarrow"),Je("y",["y",1],"yo","eraYear"),Je("y",["yy",2],0,"eraYear"),Je("y",["yyy",3],0,"eraYear"),Je("y",["yyyy",4],0,"eraYear"),jn("N",ki),jn("NN",ki),jn("NNN",ki),jn("NNNN",(function(t,e){return e.erasNameRegex(t)})),jn("NNNNN",(function(t,e){return e.erasNarrowRegex(t)})),Rn(["N","NN","NNN","NNNN","NNNNN"],(function(t,e,n,r){var i=n._locale.erasParse(t,r,n._strict);i?je(n).era=i:je(n).invalidEra=t})),jn("y",Sn),jn("yy",Sn),jn("yyy",Sn),jn("yyyy",Sn),jn("yo",(function(t,e){return e._eraYearOrdinalRegex||Sn})),Rn(["y","yy","yyy","yyyy"],0),Rn(["yo"],(function(t,e,n,r){var i;n._locale._eraYearOrdinalRegex&&(i=t.match(n._locale._eraYearOrdinalRegex)),n._locale.eraYearOrdinalParse?e[0]=n._locale.eraYearOrdinalParse(t,i):e[0]=parseInt(t,10)})),Je(0,["gg",2],0,(function(){return this.weekYear()%100})),Je(0,["GG",2],0,(function(){return this.isoWeekYear()%100})),Ti("gggg","weekYear"),Ti("ggggg","weekYear"),Ti("GGGG","isoWeekYear"),Ti("GGGGG","isoWeekYear"),rn("weekYear","gg"),rn("isoWeekYear","GG"),cn("weekYear",1),cn("isoWeekYear",1),jn("G",On),jn("g",On),jn("GG",wn,mn),jn("gg",wn,mn),jn("GGGG",Tn,bn),jn("gggg",Tn,bn),jn("GGGGG",En,_n),jn("ggggg",En,_n),In(["gggg","ggggg","GGGG","GGGGG"],(function(t,e,n,r){e[r.substr(0,2)]=hn(t)})),In(["gg","GG"],(function(t,e,n,r){e[r]=we.parseTwoDigitYear(t)})),Je("Q",0,"Qo","quarter"),rn("quarter","Q"),cn("quarter",7),jn("Q",yn),Rn("Q",(function(t,e){e[1]=3*(hn(t)-1)})),Je("D",["DD",2],"Do","date"),rn("date","D"),cn("date",9),jn("D",wn),jn("DD",wn,mn),jn("Do",(function(t,e){return t?e._dayOfMonthOrdinalParse||e._ordinalParse:e._dayOfMonthOrdinalParseLenient})),Rn(["D","DD"],2),Rn("Do",(function(t,e){e[2]=hn(t.match(wn)[0])}));var Oi=dn("Date",!0);Je("DDD",["DDDD",3],"DDDo","dayOfYear"),rn("dayOfYear","DDD"),cn("dayOfYear",4),jn("DDD",Cn),jn("DDDD",vn),Rn(["DDD","DDDD"],(function(t,e,n){n._dayOfYear=hn(t)})),Je("m",["mm",2],0,"minute"),rn("minute","m"),cn("minute",14),jn("m",wn),jn("mm",wn,mn),Rn(["m","mm"],4);var Ai=dn("Minutes",!1);Je("s",["ss",2],0,"second"),rn("second","s"),cn("second",15),jn("s",wn),jn("ss",wn,mn),Rn(["s","ss"],5);var Mi,Di,ji=dn("Seconds",!1);for(Je("S",0,0,(function(){return~~(this.millisecond()/100)})),Je(0,["SS",2],0,(function(){return~~(this.millisecond()/10)})),Je(0,["SSS",3],0,"millisecond"),Je(0,["SSSS",4],0,(function(){return 10*this.millisecond()})),Je(0,["SSSSS",5],0,(function(){return 100*this.millisecond()})),Je(0,["SSSSSS",6],0,(function(){return 1e3*this.millisecond()})),Je(0,["SSSSSSS",7],0,(function(){return 1e4*this.millisecond()})),Je(0,["SSSSSSSS",8],0,(function(){return 1e5*this.millisecond()})),Je(0,["SSSSSSSSS",9],0,(function(){return 1e6*this.millisecond()})),rn("millisecond","ms"),cn("millisecond",16),jn("S",Cn,yn),jn("SS",Cn,mn),jn("SSS",Cn,vn),Mi="SSSS";Mi.length<=9;Mi+="S")jn(Mi,Sn);function Ni(t,e){e[6]=hn(1e3*("0."+t))}for(Mi="S";Mi.length<=9;Mi+="S")Rn(Mi,Ni);Di=dn("Milliseconds",!1),Je("z",0,0,"zoneAbbr"),Je("zz",0,0,"zoneName");var Bi=Fe.prototype;function Li(t){return t}Bi.add=hi,Bi.calendar=function(t,e){1===arguments.length&&(arguments[0]?pi(arguments[0])?(t=arguments[0],e=void 0):gi(arguments[0])&&(e=arguments[0],t=void 0):(t=void 0,e=void 0));var n=t||Wr(),r=ei(n,this).startOf("day"),i=we.calendarFormat(this,r)||"sameElse",a=e&&(qe(e[i])?e[i].call(this,n):e[i]);return this.format(a||this.localeData().calendar(i,this,Wr(n)))},Bi.clone=function(){return new Fe(this)},Bi.diff=function(t,e,n){var r,i,a;if(!this.isValid())return NaN;if(!(r=ei(t,this)).isValid())return NaN;switch(i=6e4*(r.utcOffset()-this.utcOffset()),e=an(e)){case"year":a=yi(this,r)/12;break;case"month":a=yi(this,r);break;case"quarter":a=yi(this,r)/3;break;case"second":a=(this-r)/1e3;break;case"minute":a=(this-r)/6e4;break;case"hour":a=(this-r)/36e5;break;case"day":a=(this-r-i)/864e5;break;case"week":a=(this-r-i)/6048e5;break;default:a=this-r}return n?a:un(a)},Bi.endOf=function(t){var e,n;if(void 0===(t=an(t))||"millisecond"===t||!this.isValid())return this;switch(n=this._isUTC?xi:wi,t){case"year":e=n(this.year()+1,0,1)-1;break;case"quarter":e=n(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":e=n(this.year(),this.month()+1,1)-1;break;case"week":e=n(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":e=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":e=n(this.year(),this.month(),this.date()+1)-1;break;case"hour":e=this._d.valueOf(),e+=36e5-_i(e+(this._isUTC?0:6e4*this.utcOffset()),36e5)-1;break;case"minute":e=this._d.valueOf(),e+=6e4-_i(e,6e4)-1;break;case"second":e=this._d.valueOf(),e+=1e3-_i(e,1e3)-1}return this._d.setTime(e),we.updateOffset(this,!0),this},Bi.format=function(t){t||(t=this.isUtc()?we.defaultFormatUtc:we.defaultFormat);var e=tn(this,t);return this.localeData().postformat(e)},Bi.from=function(t,e){return this.isValid()&&(Pe(t)&&t.isValid()||Wr(t).isValid())?oi({to:this,from:t}).locale(this.locale()).humanize(!e):this.localeData().invalidDate()},Bi.fromNow=function(t){return this.from(Wr(),t)},Bi.to=function(t,e){return this.isValid()&&(Pe(t)&&t.isValid()||Wr(t).isValid())?oi({from:this,to:t}).locale(this.locale()).humanize(!e):this.localeData().invalidDate()},Bi.toNow=function(t){return this.to(Wr(),t)},Bi.get=function(t){return qe(this[t=an(t)])?this[t]():this},Bi.invalidAt=function(){return je(this).overflow},Bi.isAfter=function(t,e){var n=Pe(t)?t:Wr(t);return!(!this.isValid()||!n.isValid())&&("millisecond"===(e=an(e)||"millisecond")?this.valueOf()>n.valueOf():n.valueOf()9999?tn(n,e?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):qe(Date.prototype.toISOString)?e?this.toDate().toISOString():new Date(this.valueOf()+60*this.utcOffset()*1e3).toISOString().replace("Z",tn(n,"Z")):tn(n,e?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")},Bi.inspect=function(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var t,e,n,r="moment",i="";return this.isLocal()||(r=0===this.utcOffset()?"moment.utc":"moment.parseZone",i="Z"),t="["+r+'("]',e=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY","-MM-DD[T]HH:mm:ss.SSS",n=i+'[")]',this.format(t+e+"-MM-DD[T]HH:mm:ss.SSS"+n)},"undefined"!=typeof Symbol&&null!=Symbol.for&&(Bi[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"}),Bi.toJSON=function(){return this.isValid()?this.toISOString():null},Bi.toString=function(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},Bi.unix=function(){return Math.floor(this.valueOf()/1e3)},Bi.valueOf=function(){return this._d.valueOf()-6e4*(this._offset||0)},Bi.creationData=function(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}},Bi.eraName=function(){var t,e,n,r=this.localeData().eras();for(t=0,e=r.length;tthis.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()},Bi.isLocal=function(){return!!this.isValid()&&!this._isUTC},Bi.isUtcOffset=function(){return!!this.isValid()&&this._isUTC},Bi.isUtc=ri,Bi.isUTC=ri,Bi.zoneAbbr=function(){return this._isUTC?"UTC":""},Bi.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""},Bi.dates=ze("dates accessor is deprecated. Use date instead.",Oi),Bi.months=ze("months accessor is deprecated. Use month instead",Gn),Bi.years=ze("years accessor is deprecated. Use year instead",Qn),Bi.zone=ze("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",(function(t,e){return null!=t?("string"!=typeof t&&(t=-t),this.utcOffset(t,e),this):-this.utcOffset()})),Bi.isDSTShifted=ze("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",(function(){if(!Ee(this._isDSTShifted))return this._isDSTShifted;var t,e={};return Ie(e,this),(e=Ur(e))._a?(t=e._isUTC?De(e._a):Wr(e._a),this._isDSTShifted=this.isValid()&&function(t,e,n){var r,i=Math.min(t.length,e.length),a=Math.abs(t.length-e.length),o=0;for(r=0;r0):this._isDSTShifted=!1,this._isDSTShifted}));var Ri=Ve.prototype;function Ii(t,e,n,r){var i=Er(),a=De().set(r,e);return i[n](a,t)}function Fi(t,e,n){if(Se(t)&&(e=t,t=void 0),t=t||"",null!=e)return Ii(t,e,n,"month");var r,i=[];for(r=0;r<12;r++)i[r]=Ii(t,r,n,"month");return i}function Pi(t,e,n,r){"boolean"==typeof t?(Se(e)&&(n=e,e=void 0),e=e||""):(n=e=t,t=!1,Se(e)&&(n=e,e=void 0),e=e||"");var i,a=Er(),o=t?a._week.dow:0,s=[];if(null!=n)return Ii(e,(n+o)%7,r,"day");for(i=0;i<7;i++)s[i]=Ii(e,(i+o)%7,r,"day");return s}Ri.calendar=function(t,e,n){var r=this._calendar[t]||this._calendar.sameElse;return qe(r)?r.call(e,n):r},Ri.longDateFormat=function(t){var e=this._longDateFormat[t],n=this._longDateFormat[t.toUpperCase()];return e||!n?e:(this._longDateFormat[t]=n.match(Xe).map((function(t){return"MMMM"===t||"MM"===t||"DD"===t||"dddd"===t?t.slice(1):t})).join(""),this._longDateFormat[t])},Ri.invalidDate=function(){return this._invalidDate},Ri.ordinal=function(t){return this._ordinal.replace("%d",t)},Ri.preparse=Li,Ri.postformat=Li,Ri.relativeTime=function(t,e,n,r){var i=this._relativeTime[n];return qe(i)?i(t,e,n,r):i.replace(/%d/i,t)},Ri.pastFuture=function(t,e){var n=this._relativeTime[t>0?"future":"past"];return qe(n)?n(e):n.replace(/%s/i,e)},Ri.set=function(t){var e,n;for(n in t)Ce(t,n)&&(qe(e=t[n])?this[n]=e:this["_"+n]=e);this._config=t,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)},Ri.eras=function(t,e){var n,r,i,a=this._eras||Er("en")._eras;for(n=0,r=a.length;n=0)return c[r]},Ri.erasConvertYear=function(t,e){var n=t.since<=t.until?1:-1;return void 0===e?we(t.since).year():we(t.since).year()+(e-t.offset)*n},Ri.erasAbbrRegex=function(t){return Ce(this,"_erasAbbrRegex")||Ci.call(this),t?this._erasAbbrRegex:this._erasRegex},Ri.erasNameRegex=function(t){return Ce(this,"_erasNameRegex")||Ci.call(this),t?this._erasNameRegex:this._erasRegex},Ri.erasNarrowRegex=function(t){return Ce(this,"_erasNarrowRegex")||Ci.call(this),t?this._erasNarrowRegex:this._erasRegex},Ri.months=function(t,e){return t?xe(this._months)?this._months[t.month()]:this._months[(this._months.isFormat||$n).test(e)?"format":"standalone"][t.month()]:xe(this._months)?this._months:this._months.standalone},Ri.monthsShort=function(t,e){return t?xe(this._monthsShort)?this._monthsShort[t.month()]:this._monthsShort[$n.test(e)?"format":"standalone"][t.month()]:xe(this._monthsShort)?this._monthsShort:this._monthsShort.standalone},Ri.monthsParse=function(t,e,n){var r,i,a;if(this._monthsParseExact)return Hn.call(this,t,e,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),r=0;r<12;r++){if(i=De([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(i,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(i,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(a="^"+this.months(i,"")+"|^"+this.monthsShort(i,""),this._monthsParse[r]=new RegExp(a.replace(".",""),"i")),n&&"MMMM"===e&&this._longMonthsParse[r].test(t))return r;if(n&&"MMM"===e&&this._shortMonthsParse[r].test(t))return r;if(!n&&this._monthsParse[r].test(t))return r}},Ri.monthsRegex=function(t){return this._monthsParseExact?(Ce(this,"_monthsRegex")||Xn.call(this),t?this._monthsStrictRegex:this._monthsRegex):(Ce(this,"_monthsRegex")||(this._monthsRegex=qn),this._monthsStrictRegex&&t?this._monthsStrictRegex:this._monthsRegex)},Ri.monthsShortRegex=function(t){return this._monthsParseExact?(Ce(this,"_monthsRegex")||Xn.call(this),t?this._monthsShortStrictRegex:this._monthsShortRegex):(Ce(this,"_monthsShortRegex")||(this._monthsShortRegex=Wn),this._monthsShortStrictRegex&&t?this._monthsShortStrictRegex:this._monthsShortRegex)},Ri.week=function(t){return nr(t,this._week.dow,this._week.doy).week},Ri.firstDayOfYear=function(){return this._week.doy},Ri.firstDayOfWeek=function(){return this._week.dow},Ri.weekdays=function(t,e){var n=xe(this._weekdays)?this._weekdays:this._weekdays[t&&!0!==t&&this._weekdays.isFormat.test(e)?"format":"standalone"];return!0===t?ir(n,this._week.dow):t?n[t.day()]:n},Ri.weekdaysMin=function(t){return!0===t?ir(this._weekdaysMin,this._week.dow):t?this._weekdaysMin[t.day()]:this._weekdaysMin},Ri.weekdaysShort=function(t){return!0===t?ir(this._weekdaysShort,this._week.dow):t?this._weekdaysShort[t.day()]:this._weekdaysShort},Ri.weekdaysParse=function(t,e,n){var r,i,a;if(this._weekdaysParseExact)return hr.call(this,t,e,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),r=0;r<7;r++){if(i=De([2e3,1]).day(r),n&&!this._fullWeekdaysParse[r]&&(this._fullWeekdaysParse[r]=new RegExp("^"+this.weekdays(i,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[r]=new RegExp("^"+this.weekdaysShort(i,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[r]=new RegExp("^"+this.weekdaysMin(i,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[r]||(a="^"+this.weekdays(i,"")+"|^"+this.weekdaysShort(i,"")+"|^"+this.weekdaysMin(i,""),this._weekdaysParse[r]=new RegExp(a.replace(".",""),"i")),n&&"dddd"===e&&this._fullWeekdaysParse[r].test(t))return r;if(n&&"ddd"===e&&this._shortWeekdaysParse[r].test(t))return r;if(n&&"dd"===e&&this._minWeekdaysParse[r].test(t))return r;if(!n&&this._weekdaysParse[r].test(t))return r}},Ri.weekdaysRegex=function(t){return this._weekdaysParseExact?(Ce(this,"_weekdaysRegex")||dr.call(this),t?this._weekdaysStrictRegex:this._weekdaysRegex):(Ce(this,"_weekdaysRegex")||(this._weekdaysRegex=cr),this._weekdaysStrictRegex&&t?this._weekdaysStrictRegex:this._weekdaysRegex)},Ri.weekdaysShortRegex=function(t){return this._weekdaysParseExact?(Ce(this,"_weekdaysRegex")||dr.call(this),t?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(Ce(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=lr),this._weekdaysShortStrictRegex&&t?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)},Ri.weekdaysMinRegex=function(t){return this._weekdaysParseExact?(Ce(this,"_weekdaysRegex")||dr.call(this),t?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(Ce(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=ur),this._weekdaysMinStrictRegex&&t?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)},Ri.isPM=function(t){return"p"===(t+"").toLowerCase().charAt(0)},Ri.meridiem=function(t,e,n){return t>11?n?"pm":"PM":n?"am":"AM"},Cr("en",{eras:[{since:"0001-01-01",until:1/0,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10;return t+(1===hn(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th")}}),we.lang=ze("moment.lang is deprecated. Use moment.locale instead.",Cr),we.langData=ze("moment.langData is deprecated. Use moment.localeData instead.",Er);var Yi=Math.abs;function zi(t,e,n,r){var i=oi(e,n);return t._milliseconds+=r*i._milliseconds,t._days+=r*i._days,t._months+=r*i._months,t._bubble()}function Ui(t){return t<0?Math.floor(t):Math.ceil(t)}function $i(t){return 4800*t/146097}function Wi(t){return 146097*t/4800}function qi(t){return function(){return this.as(t)}}var Hi=qi("ms"),Vi=qi("s"),Gi=qi("m"),Xi=qi("h"),Zi=qi("d"),Qi=qi("w"),Ki=qi("M"),Ji=qi("Q"),ta=qi("y");function ea(t){return function(){return this.isValid()?this._data[t]:NaN}}var na=ea("milliseconds"),ra=ea("seconds"),ia=ea("minutes"),aa=ea("hours"),oa=ea("days"),sa=ea("months"),ca=ea("years");var la=Math.round,ua={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function ha(t,e,n,r,i){return i.relativeTime(e||1,!!n,t,r)}var da=Math.abs;function fa(t){return(t>0)-(t<0)||+t}function pa(){if(!this.isValid())return this.localeData().invalidDate();var t,e,n,r,i,a,o,s,c=da(this._milliseconds)/1e3,l=da(this._days),u=da(this._months),h=this.asSeconds();return h?(t=un(c/60),e=un(t/60),c%=60,t%=60,n=un(u/12),u%=12,r=c?c.toFixed(3).replace(/\.?0+$/,""):"",i=h<0?"-":"",a=fa(this._months)!==fa(h)?"-":"",o=fa(this._days)!==fa(h)?"-":"",s=fa(this._milliseconds)!==fa(h)?"-":"",i+"P"+(n?a+n+"Y":"")+(u?a+u+"M":"")+(l?o+l+"D":"")+(e||t||c?"T":"")+(e?s+e+"H":"")+(t?s+t+"M":"")+(c?s+r+"S":"")):"P0D"}var ga=Xr.prototype;ga.isValid=function(){return this._isValid},ga.abs=function(){var t=this._data;return this._milliseconds=Yi(this._milliseconds),this._days=Yi(this._days),this._months=Yi(this._months),t.milliseconds=Yi(t.milliseconds),t.seconds=Yi(t.seconds),t.minutes=Yi(t.minutes),t.hours=Yi(t.hours),t.months=Yi(t.months),t.years=Yi(t.years),this},ga.add=function(t,e){return zi(this,t,e,1)},ga.subtract=function(t,e){return zi(this,t,e,-1)},ga.as=function(t){if(!this.isValid())return NaN;var e,n,r=this._milliseconds;if("month"===(t=an(t))||"quarter"===t||"year"===t)switch(e=this._days+r/864e5,n=this._months+$i(e),t){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(e=this._days+Math.round(Wi(this._months)),t){case"week":return e/7+r/6048e5;case"day":return e+r/864e5;case"hour":return 24*e+r/36e5;case"minute":return 1440*e+r/6e4;case"second":return 86400*e+r/1e3;case"millisecond":return Math.floor(864e5*e)+r;default:throw new Error("Unknown unit "+t)}},ga.asMilliseconds=Hi,ga.asSeconds=Vi,ga.asMinutes=Gi,ga.asHours=Xi,ga.asDays=Zi,ga.asWeeks=Qi,ga.asMonths=Ki,ga.asQuarters=Ji,ga.asYears=ta,ga.valueOf=function(){return this.isValid()?this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*hn(this._months/12):NaN},ga._bubble=function(){var t,e,n,r,i,a=this._milliseconds,o=this._days,s=this._months,c=this._data;return a>=0&&o>=0&&s>=0||a<=0&&o<=0&&s<=0||(a+=864e5*Ui(Wi(s)+o),o=0,s=0),c.milliseconds=a%1e3,t=un(a/1e3),c.seconds=t%60,e=un(t/60),c.minutes=e%60,n=un(e/60),c.hours=n%24,o+=un(n/24),s+=i=un($i(o)),o-=Ui(Wi(i)),r=un(s/12),s%=12,c.days=o,c.months=s,c.years=r,this},ga.clone=function(){return oi(this)},ga.get=function(t){return t=an(t),this.isValid()?this[t+"s"]():NaN},ga.milliseconds=na,ga.seconds=ra,ga.minutes=ia,ga.hours=aa,ga.days=oa,ga.weeks=function(){return un(this.days()/7)},ga.months=sa,ga.years=ca,ga.humanize=function(t,e){if(!this.isValid())return this.localeData().invalidDate();var n,r,i=!1,a=ua;return"object"==typeof t&&(e=t,t=!1),"boolean"==typeof t&&(i=t),"object"==typeof e&&(a=Object.assign({},ua,e),null!=e.s&&null==e.ss&&(a.ss=e.s-1)),r=function(t,e,n,r){var i=oi(t).abs(),a=la(i.as("s")),o=la(i.as("m")),s=la(i.as("h")),c=la(i.as("d")),l=la(i.as("M")),u=la(i.as("w")),h=la(i.as("y")),d=a<=n.ss&&["s",a]||a0,d[4]=r,ha.apply(null,d)}(this,!i,a,n=this.localeData()),i&&(r=n.pastFuture(+this,r)),n.postformat(r)},ga.toISOString=pa,ga.toString=pa,ga.toJSON=pa,ga.locale=mi,ga.localeData=bi,ga.toIsoString=ze("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",pa),ga.lang=vi,Je("X",0,0,"unix"),Je("x",0,0,"valueOf"),jn("x",On),jn("X",/[+-]?\d+(\.\d{1,3})?/),Rn("X",(function(t,e,n){n._d=new Date(1e3*parseFloat(t))})),Rn("x",(function(t,e,n){n._d=new Date(hn(t))})), +//! moment.js +we.version="2.29.1",be=Wr,we.fn=Bi,we.min=function(){var t=[].slice.call(arguments,0);return Vr("isBefore",t)},we.max=function(){var t=[].slice.call(arguments,0);return Vr("isAfter",t)},we.now=function(){return Date.now?Date.now():+new Date},we.utc=De,we.unix=function(t){return Wr(1e3*t)},we.months=function(t,e){return Fi(t,e,"months")},we.isDate=Oe,we.locale=Cr,we.invalid=Be,we.duration=oi,we.isMoment=Pe,we.weekdays=function(t,e,n){return Pi(t,e,n,"weekdays")},we.parseZone=function(){return Wr.apply(null,arguments).parseZone()},we.localeData=Er,we.isDuration=Zr,we.monthsShort=function(t,e){return Fi(t,e,"monthsShort")},we.weekdaysMin=function(t,e,n){return Pi(t,e,n,"weekdaysMin")},we.defineLocale=Tr,we.updateLocale=function(t,e){if(null!=e){var n,r,i=vr;null!=br[t]&&null!=br[t].parentLocale?br[t].set(He(br[t]._config,e)):(null!=(r=kr(t))&&(i=r._config),e=He(i,e),null==r&&(e.abbr=t),(n=new Ve(e)).parentLocale=br[t],br[t]=n),Cr(t)}else null!=br[t]&&(null!=br[t].parentLocale?(br[t]=br[t].parentLocale,t===Cr()&&Cr(t)):null!=br[t]&&delete br[t]);return br[t]},we.locales=function(){return Ue(br)},we.weekdaysShort=function(t,e,n){return Pi(t,e,n,"weekdaysShort")},we.normalizeUnits=an,we.relativeTimeRounding=function(t){return void 0===t?la:"function"==typeof t&&(la=t,!0)},we.relativeTimeThreshold=function(t,e){return void 0!==ua[t]&&(void 0===e?ua[t]:(ua[t]=e,"s"===t&&(ua.ss=e-1),!0))},we.calendarFormat=function(t,e){var n=t.diff(e,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"},we.prototype=Bi,we.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"};var ya="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function ma(t){if(t.__esModule)return t;var e=Object.defineProperty({},"__esModule",{value:!0});return Object.keys(t).forEach((function(n){var r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(e,n,r.get?r:{enumerable:!0,get:function(){return t[n]}})})),e}function va(t){throw new Error('Could not dynamically require "'+t+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var ba={exports:{}},_a=/^(%20|\s)*(javascript|data)/im,wa=/[^\x20-\x7E]/gim,xa=/^([^:]+):/gm,ka=[".","/"];var Ca={sanitizeUrl:function(t){if(!t)return"about:blank";var e,n,r=t.replace(wa,"").trim();return function(t){return ka.indexOf(t[0])>-1}(r)?r:(n=r.match(xa))?(e=n[0],_a.test(e)?"about:blank":r):"about:blank"}};function Ta(t,e){return te?1:t>=e?0:NaN}function Ea(t){var e;return 1===t.length&&(e=t,t=function(t,n){return Ta(e(t),n)}),{left:function(e,n,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r>>1;t(e[a],n)<0?r=a+1:i=a}return r},right:function(e,n,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r>>1;t(e[a],n)>0?i=a:r=a+1}return r}}}var Sa=Ea(Ta),Oa=Sa.right,Aa=Sa.left;function Ma(t,e){return[t,e]}function Da(t){return null===t?NaN:+t}function ja(t,e){var n,r,i=t.length,a=0,o=-1,s=0,c=0;if(null==e)for(;++o1)return c/(a-1)}function Na(t,e){var n=ja(t,e);return n?Math.sqrt(n):n}function Ba(t,e){var n,r,i,a=t.length,o=-1;if(null==e){for(;++o=n)for(r=i=n;++on&&(r=n),i=n)for(r=i=n;++on&&(r=n),i0)return[t];if((r=e0)for(t=Math.ceil(t/o),e=Math.floor(e/o),a=new Array(i=Math.ceil(e-t+1));++s=0?(a>=za?10:a>=Ua?5:a>=$a?2:1)*Math.pow(10,i):-Math.pow(10,-i)/(a>=za?10:a>=Ua?5:a>=$a?2:1)}function Ha(t,e,n){var r=Math.abs(e-t)/Math.max(0,n),i=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),a=r/i;return a>=za?i*=10:a>=Ua?i*=5:a>=$a&&(i*=2),e=1)return+n(t[r-1],r-1,t);var r,i=(r-1)*e,a=Math.floor(i),o=+n(t[a],a,t);return o+(+n(t[a+1],a+1,t)-o)*(i-a)}}function Xa(t,e){var n,r,i=t.length,a=-1;if(null==e){for(;++a=n)for(r=n;++ar&&(r=n)}else for(;++a=n)for(r=n;++ar&&(r=n);return r}function Za(t){for(var e,n,r,i=t.length,a=-1,o=0;++a=0;)for(e=(r=t[i]).length;--e>=0;)n[--o]=r[e];return n}function Qa(t,e){var n,r,i=t.length,a=-1;if(null==e){for(;++a=n)for(r=n;++an&&(r=n)}else for(;++a=n)for(r=n;++an&&(r=n);return r}function Ka(t){if(!(i=t.length))return[];for(var e=-1,n=Qa(t,Ja),r=new Array(n);++e=0&&(n=t.slice(r+1),t=t.slice(0,r)),t&&!e.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:n}}))}function fo(t,e){for(var n,r=0,i=t.length;r0)for(var n,r,i=new Array(n),a=0;a=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),yo.hasOwnProperty(e)?{space:yo[e],local:t}:t}function vo(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===go&&e.documentElement.namespaceURI===go?e.createElement(t):e.createElementNS(n,t)}}function bo(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function _o(t){var e=mo(t);return(e.local?bo:vo)(e)}function wo(){}function xo(t){return null==t?wo:function(){return this.querySelector(t)}}function ko(){return[]}function Co(t){return null==t?ko:function(){return this.querySelectorAll(t)}}function To(t){return function(){return this.matches(t)}}function Eo(t){return new Array(t.length)}function So(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}So.prototype={constructor:So,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)}};function Oo(t,e,n,r,i,a){for(var o,s=0,c=e.length,l=a.length;se?1:t>=e?0:NaN}function Do(t){return function(){this.removeAttribute(t)}}function jo(t){return function(){this.removeAttributeNS(t.space,t.local)}}function No(t,e){return function(){this.setAttribute(t,e)}}function Bo(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function Lo(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function Ro(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 Io(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function Fo(t){return function(){this.style.removeProperty(t)}}function Po(t,e,n){return function(){this.style.setProperty(t,e,n)}}function Yo(t,e,n){return function(){var r=e.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,n)}}function zo(t,e){return t.style.getPropertyValue(e)||Io(t).getComputedStyle(t,null).getPropertyValue(e)}function Uo(t){return function(){delete this[t]}}function $o(t,e){return function(){this[t]=e}}function Wo(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}function qo(t){return t.trim().split(/^|\s+/)}function Ho(t){return t.classList||new Vo(t)}function Vo(t){this._node=t,this._names=qo(t.getAttribute("class")||"")}function Go(t,e){for(var n=Ho(t),r=-1,i=e.length;++r=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var hs={},ds=null;"undefined"!=typeof document&&("onmouseenter"in document.documentElement||(hs={mouseenter:"mouseover",mouseleave:"mouseout"}));function fs(t,e,n){return t=ps(t,e,n),function(e){var n=e.relatedTarget;n&&(n===this||8&n.compareDocumentPosition(this))||t.call(this,e)}}function ps(t,e,n){return function(r){var i=ds;ds=r;try{t.call(this,this.__data__,e,n)}finally{ds=i}}}function gs(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}}))}function ys(t){return function(){var e=this.__on;if(e){for(var n,r=0,i=-1,a=e.length;r=w&&(w=_+1);!(b=m[w])&&++w=0;)(r=i[a])&&(o&&4^r.compareDocumentPosition(o)&&o.parentNode.insertBefore(r,o),o=r);return this},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=Mo);for(var n=this._groups,r=n.length,i=new Array(r),a=0;a1?this.each((null==e?Fo:"function"==typeof e?Yo:Po)(t,e,null==n?"":n)):zo(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?Uo:"function"==typeof e?Wo:$o)(t,e)):this.node()[t]},classed:function(t,e){var n=qo(t+"");if(arguments.length<2){for(var r=Ho(this.node()),i=-1,a=n.length;++i>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===n?cc(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===n?cc(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=Qs.exec(t))?new hc(e[1],e[2],e[3],1):(e=Ks.exec(t))?new hc(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=Js.exec(t))?cc(e[1],e[2],e[3],e[4]):(e=tc.exec(t))?cc(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=ec.exec(t))?gc(e[1],e[2]/100,e[3]/100,1):(e=nc.exec(t))?gc(e[1],e[2]/100,e[3]/100,e[4]):rc.hasOwnProperty(t)?sc(rc[t]):"transparent"===t?new hc(NaN,NaN,NaN,0):null}function sc(t){return new hc(t>>16&255,t>>8&255,255&t,1)}function cc(t,e,n,r){return r<=0&&(t=e=n=NaN),new hc(t,e,n,r)}function lc(t){return t instanceof qs||(t=oc(t)),t?new hc((t=t.rgb()).r,t.g,t.b,t.opacity):new hc}function uc(t,e,n,r){return 1===arguments.length?lc(t):new hc(t,e,n,null==r?1:r)}function hc(t,e,n,r){this.r=+t,this.g=+e,this.b=+n,this.opacity=+r}function dc(){return"#"+pc(this.r)+pc(this.g)+pc(this.b)}function fc(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===t?")":", "+t+")")}function pc(t){return((t=Math.max(0,Math.min(255,Math.round(t)||0)))<16?"0":"")+t.toString(16)}function gc(t,e,n,r){return r<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new vc(t,e,n,r)}function yc(t){if(t instanceof vc)return new vc(t.h,t.s,t.l,t.opacity);if(t instanceof qs||(t=oc(t)),!t)return new vc;if(t instanceof vc)return t;var e=(t=t.rgb()).r/255,n=t.g/255,r=t.b/255,i=Math.min(e,n,r),a=Math.max(e,n,r),o=NaN,s=a-i,c=(a+i)/2;return s?(o=e===a?(n-r)/s+6*(n0&&c<1?0:o,new vc(o,s,c,t.opacity)}function mc(t,e,n,r){return 1===arguments.length?yc(t):new vc(t,e,n,null==r?1:r)}function vc(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}function bc(t,e,n){return 255*(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)}$s(qs,oc,{copy:function(t){return Object.assign(new this.constructor,this,t)},displayable:function(){return this.rgb().displayable()},hex:ic,formatHex:ic,formatHsl:function(){return yc(this).formatHsl()},formatRgb:ac,toString:ac}),$s(hc,uc,Ws(qs,{brighter:function(t){return t=null==t?Hs:Math.pow(Hs,t),new hc(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new hc(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:dc,formatHex:dc,formatRgb:fc,toString:fc})),$s(vc,mc,Ws(qs,{brighter:function(t){return t=null==t?Hs:Math.pow(Hs,t),new vc(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new vc(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*e,i=2*n-r;return new hc(bc(t>=240?t-240:t+120,i,r),bc(t,i,r),bc(t<120?t+240:t-120,i,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===t?")":", "+t+")")}}));var _c=Math.PI/180,wc=180/Math.PI,xc=4/29,kc=6/29,Cc=3*kc*kc;function Tc(t){if(t instanceof Sc)return new Sc(t.l,t.a,t.b,t.opacity);if(t instanceof Bc)return Lc(t);t instanceof hc||(t=lc(t));var e,n,r=Dc(t.r),i=Dc(t.g),a=Dc(t.b),o=Oc((.2225045*r+.7168786*i+.0606169*a)/1);return r===i&&i===a?e=n=o:(e=Oc((.4360747*r+.3850649*i+.1430804*a)/.96422),n=Oc((.0139322*r+.0971045*i+.7141733*a)/.82521)),new Sc(116*o-16,500*(e-o),200*(o-n),t.opacity)}function Ec(t,e,n,r){return 1===arguments.length?Tc(t):new Sc(t,e,n,null==r?1:r)}function Sc(t,e,n,r){this.l=+t,this.a=+e,this.b=+n,this.opacity=+r}function Oc(t){return t>.008856451679035631?Math.pow(t,1/3):t/Cc+xc}function Ac(t){return t>kc?t*t*t:Cc*(t-xc)}function Mc(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function Dc(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function jc(t){if(t instanceof Bc)return new Bc(t.h,t.c,t.l,t.opacity);if(t instanceof Sc||(t=Tc(t)),0===t.a&&0===t.b)return new Bc(NaN,0=1?(n=1,e-1):Math.floor(n*e),i=t[r],a=t[r+1],o=r>0?t[r-1]:2*i-a,s=r180||n<-180?n-360*Math.round(n/360):n):Zc(isNaN(t)?e:t)}function Jc(t){return 1==(t=+t)?tl:function(e,n){return n-e?function(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(r){return Math.pow(t+r*e,n)}}(e,n,t):Zc(isNaN(e)?n:e)}}function tl(t,e){var n=e-t;return n?Qc(t,n):Zc(isNaN(t)?e:t)}$s(Hc,qc,Ws(qs,{brighter:function(t){return t=null==t?Hs:Math.pow(Hs,t),new Hc(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new Hc(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=isNaN(this.h)?0:(this.h+120)*_c,e=+this.l,n=isNaN(this.s)?0:this.s*e*(1-e),r=Math.cos(t),i=Math.sin(t);return new hc(255*(e+n*(Rc*r+Ic*i)),255*(e+n*(Fc*r+Pc*i)),255*(e+n*(Yc*r)),this.opacity)}}));var el=function t(e){var n=Jc(e);function r(t,e){var r=n((t=uc(t)).r,(e=uc(e)).r),i=n(t.g,e.g),a=n(t.b,e.b),o=tl(t.opacity,e.opacity);return function(e){return t.r=r(e),t.g=i(e),t.b=a(e),t.opacity=o(e),t+""}}return r.gamma=t,r}(1);function nl(t){return function(e){var n,r,i=e.length,a=new Array(i),o=new Array(i),s=new Array(i);for(n=0;na&&(i=e.slice(a,i),s[o]?s[o]+=i:s[++o]=i),(n=n[0])===(r=r[0])?s[o]?s[o]+=r:s[++o]=r:(s[++o]=null,c.push({i:o,x:ll(n,r)})),a=dl.lastIndex;return a180?e+=360:e-t>180&&(t+=360),a.push({i:n.push(i(n)+"rotate(",null,r)-2,x:ll(t,e)})):e&&n.push(i(n)+"rotate("+e+r)}(a.rotate,o.rotate,s,c),function(t,e,n,a){t!==e?a.push({i:n.push(i(n)+"skewX(",null,r)-2,x:ll(t,e)}):e&&n.push(i(n)+"skewX("+e+r)}(a.skewX,o.skewX,s,c),function(t,e,n,r,a,o){if(t!==n||e!==r){var s=a.push(i(a)+"scale(",null,",",null,")");o.push({i:s-4,x:ll(t,n)},{i:s-2,x:ll(e,r)})}else 1===n&&1===r||a.push(i(a)+"scale("+n+","+r+")")}(a.scaleX,a.scaleY,o.scaleX,o.scaleY,s,c),a=o=null,function(t){for(var e,n=-1,r=c.length;++n=0&&e._call.call(null,t),e=e._next;--Yl}function Jl(){Wl=($l=Hl.now())+ql,Yl=zl=0;try{Kl()}finally{Yl=0,function(){var t,e,n=Fl,r=1/0;for(;n;)n._call?(r>n._time&&(r=n._time),t=n,n=n._next):(e=n._next,n._next=null,n=t?t._next=e:Fl=e);Pl=t,eu(r)}(),Wl=0}}function tu(){var t=Hl.now(),e=t-$l;e>1e3&&(ql-=e,$l=t)}function eu(t){Yl||(zl&&(zl=clearTimeout(zl)),t-Wl>24?(t<1/0&&(zl=setTimeout(Jl,t-Hl.now()-ql)),Ul&&(Ul=clearInterval(Ul))):(Ul||($l=Hl.now(),Ul=setInterval(tu,1e3)),Yl=1,Vl(Jl)))}function nu(t,e,n){var r=new Zl;return e=null==e?0:+e,r.restart((function(n){r.stop(),t(n+e)}),e,n),r}Zl.prototype=Ql.prototype={constructor:Zl,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?Gl():+n)+(null==e?0:+e),this._next||Pl===this||(Pl?Pl._next=this:Fl=this,Pl=this),this._call=t,this._time=n,eu()},stop:function(){this._call&&(this._call=null,this._time=1/0,eu())}};var ru=lo("start","end","cancel","interrupt"),iu=[];function au(t,e,n,r,i,a){var o=t.__transition;if(o){if(n in o)return}else t.__transition={};!function(t,e,n){var r,i=t.__transition;function a(t){n.state=1,n.timer.restart(o,n.delay,n.time),n.delay<=t&&o(t-n.delay)}function o(a){var l,u,h,d;if(1!==n.state)return c();for(l in i)if((d=i[l]).name===n.name){if(3===d.state)return nu(o);4===d.state?(d.state=6,d.timer.stop(),d.on.call("interrupt",t,t.__data__,d.index,d.group),delete i[l]):+l0)throw new Error("too late; already scheduled");return n}function su(t,e){var n=cu(t,e);if(n.state>3)throw new Error("too late; already running");return n}function cu(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function lu(t,e){var n,r,i,a=t.__transition,o=!0;if(a){for(i in e=null==e?null:e+"",a)(n=a[i]).name===e?(r=n.state>2&&n.state<5,n.state=6,n.timer.stop(),n.on.call(r?"interrupt":"cancel",t,t.__data__,n.index,n.group),delete a[i]):o=!1;o&&delete t.__transition}}function uu(t,e){var n,r;return function(){var i=su(this,t),a=i.tween;if(a!==n)for(var o=0,s=(r=n=a).length;o=0&&(t=t.slice(0,e)),!t||"start"===t}))}(e)?ou:su;return function(){var o=a(this,t),s=o.on;s!==r&&(i=(r=s).copy()).on(e,n),o.on=i}}var Mu=Cs.prototype.constructor;function Du(t){return function(){this.style.removeProperty(t)}}function ju(t,e,n){return function(r){this.style.setProperty(t,e.call(this,r),n)}}function Nu(t,e,n){var r,i;function a(){var a=e.apply(this,arguments);return a!==i&&(r=(i=a)&&ju(t,a,n)),r}return a._value=e,a}function Bu(t){return function(e){this.textContent=t.call(this,e)}}function Lu(t){var e,n;function r(){var r=t.apply(this,arguments);return r!==n&&(e=(n=r)&&Bu(r)),e}return r._value=t,r}var Ru=0;function Iu(t,e,n,r){this._groups=t,this._parents=e,this._name=n,this._id=r}function Fu(t){return Cs().transition(t)}function Pu(){return++Ru}var Yu=Cs.prototype;function zu(t){return((t*=2)<=1?t*t:--t*(2-t)+1)/2}function Uu(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}Iu.prototype=Fu.prototype={constructor:Iu,select:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=xo(t));for(var r=this._groups,i=r.length,a=new Array(i),o=0;oMath.abs(t[1]-B[1])?y=!0:g=!0),B=t,p=!0,ph(),Y()}function Y(){var t;switch(A=B[0]-N[0],M=B[1]-N[1],b){case yh:case gh:_&&(A=Math.max(T-n,Math.min(S-c,A)),i=n+A,h=c+A),w&&(M=Math.max(E-o,Math.min(O-d,M)),s=o+M,f=d+M);break;case mh:_<0?(A=Math.max(T-n,Math.min(S-n,A)),i=n+A,h=c):_>0&&(A=Math.max(T-c,Math.min(S-c,A)),i=n,h=c+A),w<0?(M=Math.max(E-o,Math.min(O-o,M)),s=o+M,f=d):w>0&&(M=Math.max(E-d,Math.min(O-d,M)),s=o,f=d+M);break;case vh:_&&(i=Math.max(T,Math.min(S,n-A*_)),h=Math.max(T,Math.min(S,c+A*_))),w&&(s=Math.max(E,Math.min(O,o-M*w)),f=Math.max(E,Math.min(O,d+M*w)))}h0&&(n=i-A),w<0?d=f-M:w>0&&(o=s-M),b=yh,I.attr("cursor",Th.selection),Y());break;default:return}ph()}function $(){switch(ds.keyCode){case 16:D&&(g=y=D=!1,Y());break;case 18:b===vh&&(_<0?c=h:_>0&&(n=i),w<0?d=f:w>0&&(o=s),b=mh,Y());break;case 32:b===yh&&(ds.altKey?(_&&(c=h-A*_,n=i+A*_),w&&(d=f-M*w,o=s+M*w),b=vh):(_<0?c=h:_>0&&(n=i),w<0?d=f:w>0&&(o=s),b=mh),I.attr("cursor",Th[v]),Y());break;default:return}ph()}}function f(){u(this,arguments).moved()}function p(){u(this,arguments).ended()}function g(){var e=this.__brush||{selection:null};return e.extent=_h(n.apply(this,arguments)),e.dim=t,e}return c.move=function(e,n){e.selection?e.on("start.brush",(function(){u(this,arguments).beforestart().start()})).on("interrupt.brush end.brush",(function(){u(this,arguments).end()})).tween("brush",(function(){var e=this,r=e.__brush,i=u(e,arguments),a=r.selection,o=t.input("function"==typeof n?n.apply(this,arguments):n,r.extent),s=pl(a,o);function c(t){r.selection=1===t&&null===o?null:s(t),l.call(e),i.brush()}return null!==a&&null!==o?c:c(1)})):e.each((function(){var e=this,r=arguments,i=e.__brush,a=t.input("function"==typeof n?n.apply(e,r):n,i.extent),o=u(e,r).beforestart();lu(e),i.selection=null===a?null:a,l.call(e),o.start().brush().end()}))},c.clear=function(t){c.move(t,null)},h.prototype={beforestart:function(){return 1==++this.active&&(this.state.emitter=this,this.starting=!0),this},start:function(){return this.starting?(this.starting=!1,this.emit("start")):this.emit("brush"),this},brush:function(){return this.emit("brush"),this},end:function(){return 0==--this.active&&(delete this.state.emitter,this.emit("end")),this},emit:function(e){vs(new dh(c,e,t.output(this.state.selection)),o.apply,o,[e,this.that,this.args])}},c.extent=function(t){return arguments.length?(n="function"==typeof t?t:hh(_h(t)),c):n},c.filter=function(t){return arguments.length?(r="function"==typeof t?t:hh(!!t),c):r},c.touchable=function(t){return arguments.length?(i="function"==typeof t?t:hh(!!t),c):i},c.handleSize=function(t){return arguments.length?(s=+t,c):s},c.keyModifiers=function(t){return arguments.length?(a=!!t,c):a},c.on=function(){var t=o.on.apply(o,arguments);return t===o?c:t},c}var Ih=Math.cos,Fh=Math.sin,Ph=Math.PI,Yh=Ph/2,zh=2*Ph,Uh=Math.max;function $h(t){return function(e,n){return t(e.source.value+e.target.value,n.source.value+n.target.value)}}var Wh=Array.prototype.slice;function qh(t){return function(){return t}}var Hh=Math.PI,Vh=2*Hh,Gh=Vh-1e-6;function Xh(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function Zh(){return new Xh}function Qh(t){return t.source}function Kh(t){return t.target}function Jh(t){return t.radius}function td(t){return t.startAngle}function ed(t){return t.endAngle}Xh.prototype=Zh.prototype={constructor:Xh,moveTo:function(t,e){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)},closePath:function(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(t,e){this._+="L"+(this._x1=+t)+","+(this._y1=+e)},quadraticCurveTo:function(t,e,n,r){this._+="Q"+ +t+","+ +e+","+(this._x1=+n)+","+(this._y1=+r)},bezierCurveTo:function(t,e,n,r,i,a){this._+="C"+ +t+","+ +e+","+ +n+","+ +r+","+(this._x1=+i)+","+(this._y1=+a)},arcTo:function(t,e,n,r,i){t=+t,e=+e,n=+n,r=+r,i=+i;var a=this._x1,o=this._y1,s=n-t,c=r-e,l=a-t,u=o-e,h=l*l+u*u;if(i<0)throw new Error("negative radius: "+i);if(null===this._x1)this._+="M"+(this._x1=t)+","+(this._y1=e);else if(h>1e-6)if(Math.abs(u*s-c*l)>1e-6&&i){var d=n-a,f=r-o,p=s*s+c*c,g=d*d+f*f,y=Math.sqrt(p),m=Math.sqrt(h),v=i*Math.tan((Hh-Math.acos((p+h-g)/(2*y*m)))/2),b=v/m,_=v/y;Math.abs(b-1)>1e-6&&(this._+="L"+(t+b*l)+","+(e+b*u)),this._+="A"+i+","+i+",0,0,"+ +(u*d>l*f)+","+(this._x1=t+_*s)+","+(this._y1=e+_*c)}else this._+="L"+(this._x1=t)+","+(this._y1=e);else;},arc:function(t,e,n,r,i,a){t=+t,e=+e,a=!!a;var o=(n=+n)*Math.cos(r),s=n*Math.sin(r),c=t+o,l=e+s,u=1^a,h=a?r-i:i-r;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+c+","+l:(Math.abs(this._x1-c)>1e-6||Math.abs(this._y1-l)>1e-6)&&(this._+="L"+c+","+l),n&&(h<0&&(h=h%Vh+Vh),h>Gh?this._+="A"+n+","+n+",0,1,"+u+","+(t-o)+","+(e-s)+"A"+n+","+n+",0,1,"+u+","+(this._x1=c)+","+(this._y1=l):h>1e-6&&(this._+="A"+n+","+n+",0,"+ +(h>=Hh)+","+u+","+(this._x1=t+n*Math.cos(i))+","+(this._y1=e+n*Math.sin(i))))},rect:function(t,e,n,r){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};function nd(){}function rd(t,e){var n=new nd;if(t instanceof nd)t.each((function(t,e){n.set(e,t)}));else if(Array.isArray(t)){var r,i=-1,a=t.length;if(null==e)for(;++ir!=f>r&&n<(d-l)*(r-u)/(f-u)+l&&(i=-i)}return i}function yd(t,e,n){var r,i,a,o;return function(t,e,n){return(e[0]-t[0])*(n[1]-t[1])==(n[0]-t[0])*(e[1]-t[1])}(t,e,n)&&(i=t[r=+(t[0]===e[0])],a=n[r],o=e[r],i<=a&&a<=o||o<=a&&a<=i)}function md(){}var vd=[[],[[[1,1.5],[.5,1]]],[[[1.5,1],[1,1.5]]],[[[1.5,1],[.5,1]]],[[[1,.5],[1.5,1]]],[[[1,1.5],[.5,1]],[[1,.5],[1.5,1]]],[[[1,.5],[1,1.5]]],[[[1,.5],[.5,1]]],[[[.5,1],[1,.5]]],[[[1,1.5],[1,.5]]],[[[.5,1],[1,.5]],[[1.5,1],[1,1.5]]],[[[1.5,1],[1,.5]]],[[[.5,1],[1.5,1]]],[[[1,1.5],[1.5,1]]],[[[.5,1],[1,1.5]]],[]];function bd(){var t=1,e=1,n=Va,r=s;function i(t){var e=n(t);if(Array.isArray(e))e=e.slice().sort(dd);else{var r=Ba(t),i=r[0],o=r[1];e=Ha(i,o,e),e=Ya(Math.floor(i/e)*e,Math.floor(o/e)*e,e)}return e.map((function(e){return a(t,e)}))}function a(n,i){var a=[],s=[];return function(n,r,i){var a,s,c,l,u,h,d=new Array,f=new Array;a=s=-1,l=n[0]>=r,vd[l<<1].forEach(p);for(;++a=r,vd[c|l<<1].forEach(p);vd[l<<0].forEach(p);for(;++s=r,u=n[s*t]>=r,vd[l<<1|u<<2].forEach(p);++a=r,h=u,u=n[s*t+a+1]>=r,vd[c|l<<1|u<<2|h<<3].forEach(p);vd[l|u<<3].forEach(p)}a=-1,u=n[s*t]>=r,vd[u<<2].forEach(p);for(;++a=r,vd[u<<2|h<<3].forEach(p);function p(t){var e,n,r=[t[0][0]+a,t[0][1]+s],c=[t[1][0]+a,t[1][1]+s],l=o(r),u=o(c);(e=f[l])?(n=d[u])?(delete f[e.end],delete d[n.start],e===n?(e.ring.push(c),i(e.ring)):d[e.start]=f[n.end]={start:e.start,end:n.end,ring:e.ring.concat(n.ring)}):(delete f[e.end],e.ring.push(c),f[e.end=u]=e):(e=d[u])?(n=f[l])?(delete d[e.start],delete f[n.end],e===n?(e.ring.push(c),i(e.ring)):d[n.start]=f[e.end]={start:n.start,end:e.end,ring:n.ring.concat(e.ring)}):(delete d[e.start],e.ring.unshift(r),d[e.start=l]=e):d[l]=f[u]={start:l,end:u,ring:[r,c]}}vd[u<<3].forEach(p)}(n,i,(function(t){r(t,n,i),function(t){for(var e=0,n=t.length,r=t[n-1][1]*t[0][0]-t[n-1][0]*t[0][1];++e0?a.push([t]):s.push(t)})),s.forEach((function(t){for(var e,n=0,r=a.length;n0&&o0&&s0&&a>0))throw new Error("invalid size");return t=r,e=a,i},i.thresholds=function(t){return arguments.length?(n="function"==typeof t?t:Array.isArray(t)?fd(hd.call(t)):fd(t),i):n},i.smooth=function(t){return arguments.length?(r=t?s:md,i):r===s},i}function _d(t,e,n){for(var r=t.width,i=t.height,a=1+(n<<1),o=0;o=n&&(s>=a&&(c-=t.data[s-a+o*r]),e.data[s-n+o*r]=c/Math.min(s+1,r-1+a-s,a))}function wd(t,e,n){for(var r=t.width,i=t.height,a=1+(n<<1),o=0;o=n&&(s>=a&&(c-=t.data[o+(s-a)*r]),e.data[o+(s-n)*r]=c/Math.min(s+1,i-1+a-s,a))}function xd(t){return t[0]}function kd(t){return t[1]}function Cd(){return 1}var Td={},Ed={};function Sd(t){return new Function("d","return {"+t.map((function(t,e){return JSON.stringify(t)+": d["+e+'] || ""'})).join(",")+"}")}function Od(t){var e=Object.create(null),n=[];return t.forEach((function(t){for(var r in t)r in e||n.push(e[r]=r)})),n}function Ad(t,e){var n=t+"",r=n.length;return r9999?"+"+Ad(e,6):Ad(e,4))+"-"+Ad(t.getUTCMonth()+1,2)+"-"+Ad(t.getUTCDate(),2)+(a?"T"+Ad(n,2)+":"+Ad(r,2)+":"+Ad(i,2)+"."+Ad(a,3)+"Z":i?"T"+Ad(n,2)+":"+Ad(r,2)+":"+Ad(i,2)+"Z":r||n?"T"+Ad(n,2)+":"+Ad(r,2)+"Z":"")}function Dd(t){var e=new RegExp('["'+t+"\n\r]"),n=t.charCodeAt(0);function r(t,e){var r,i=[],a=t.length,o=0,s=0,c=a<=0,l=!1;function u(){if(c)return Ed;if(l)return l=!1,Td;var e,r,i=o;if(34===t.charCodeAt(i)){for(;o++=a?c=!0:10===(r=t.charCodeAt(o++))?l=!0:13===r&&(l=!0,10===t.charCodeAt(o)&&++o),t.slice(i+1,e-1).replace(/""/g,'"')}for(;o=(a=(g+m)/2))?g=a:m=a,(u=n>=(o=(y+v)/2))?y=o:v=o,i=f,!(f=f[h=u<<1|l]))return i[h]=p,t;if(s=+t._x.call(null,f.data),c=+t._y.call(null,f.data),e===s&&n===c)return p.next=f,i?i[h]=p:t._root=p,t;do{i=i?i[h]=new Array(4):t._root=new Array(4),(l=e>=(a=(g+m)/2))?g=a:m=a,(u=n>=(o=(y+v)/2))?y=o:v=o}while((h=u<<1|l)==(d=(c>=o)<<1|s>=a));return i[d]=f,i[h]=p,t}function hf(t,e,n,r,i){this.node=t,this.x0=e,this.y0=n,this.x1=r,this.y1=i}function df(t){return t[0]}function ff(t){return t[1]}function pf(t,e,n){var r=new gf(null==e?df:e,null==n?ff:n,NaN,NaN,NaN,NaN);return null==t?r:r.addAll(t)}function gf(t,e,n,r,i,a){this._x=t,this._y=e,this._x0=n,this._y0=r,this._x1=i,this._y1=a,this._root=void 0}function yf(t){for(var e={data:t.data},n=e;t=t.next;)n=n.next={data:t.data};return e}var mf=pf.prototype=gf.prototype;function vf(t){return t.x+t.vx}function bf(t){return t.y+t.vy}function _f(t){return t.index}function wf(t,e){var n=t.get(e);if(!n)throw new Error("missing: "+e);return n}function xf(t){return t.x}function kf(t){return t.y}mf.copy=function(){var t,e,n=new gf(this._x,this._y,this._x0,this._y0,this._x1,this._y1),r=this._root;if(!r)return n;if(!r.length)return n._root=yf(r),n;for(t=[{source:r,target:n._root=new Array(4)}];r=t.pop();)for(var i=0;i<4;++i)(e=r.source[i])&&(e.length?t.push({source:e,target:r.target[i]=new Array(4)}):r.target[i]=yf(e));return n},mf.add=function(t){var e=+this._x.call(null,t),n=+this._y.call(null,t);return uf(this.cover(e,n),e,n,t)},mf.addAll=function(t){var e,n,r,i,a=t.length,o=new Array(a),s=new Array(a),c=1/0,l=1/0,u=-1/0,h=-1/0;for(n=0;nu&&(u=r),ih&&(h=i));if(c>u||l>h)return this;for(this.cover(c,l).cover(u,h),n=0;nt||t>=i||r>e||e>=a;)switch(s=(ed||(a=c.y0)>f||(o=c.x1)=m)<<1|t>=y)&&(c=p[p.length-1],p[p.length-1]=p[p.length-1-l],p[p.length-1-l]=c)}else{var v=t-+this._x.call(null,g.data),b=e-+this._y.call(null,g.data),_=v*v+b*b;if(_=(s=(p+y)/2))?p=s:y=s,(u=o>=(c=(g+m)/2))?g=c:m=c,e=f,!(f=f[h=u<<1|l]))return this;if(!f.length)break;(e[h+1&3]||e[h+2&3]||e[h+3&3])&&(n=e,d=h)}for(;f.data!==t;)if(r=f,!(f=f.next))return this;return(i=f.next)&&delete f.next,r?(i?r.next=i:delete r.next,this):e?(i?e[h]=i:delete e[h],(f=e[0]||e[1]||e[2]||e[3])&&f===(e[3]||e[2]||e[1]||e[0])&&!f.length&&(n?n[d]=f:this._root=f),this):(this._root=i,this)},mf.removeAll=function(t){for(var e=0,n=t.length;e1?r[0]+r.slice(2):r,+t.slice(n+1)]}function Ef(t){return(t=Tf(Math.abs(t)))?t[1]:NaN}var Sf,Of=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Af(t){if(!(e=Of.exec(t)))throw new Error("invalid format: "+t);var e;return new Mf({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function Mf(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}function Df(t,e){var n=Tf(t,e);if(!n)return t+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}Af.prototype=Mf.prototype,Mf.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var jf={"%":function(t,e){return(100*t).toFixed(e)},b:function(t){return Math.round(t).toString(2)},c:function(t){return t+""},d:function(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},g:function(t,e){return t.toPrecision(e)},o:function(t){return Math.round(t).toString(8)},p:function(t,e){return Df(100*t,e)},r:Df,s:function(t,e){var n=Tf(t,e);if(!n)return t+"";var r=n[0],i=n[1],a=i-(Sf=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,o=r.length;return a===o?r:a>o?r+new Array(a-o+1).join("0"):a>0?r.slice(0,a)+"."+r.slice(a):"0."+new Array(1-a).join("0")+Tf(t,Math.max(0,e+a-1))[0]},X:function(t){return Math.round(t).toString(16).toUpperCase()},x:function(t){return Math.round(t).toString(16)}};function Nf(t){return t}var Bf,Lf,Rf,If=Array.prototype.map,Ff=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function Pf(t){var e,n,r=void 0===t.grouping||void 0===t.thousands?Nf:(e=If.call(t.grouping,Number),n=t.thousands+"",function(t,r){for(var i=t.length,a=[],o=0,s=e[0],c=0;i>0&&s>0&&(c+s+1>r&&(s=Math.max(1,r-c)),a.push(t.substring(i-=s,i+s)),!((c+=s+1)>r));)s=e[o=(o+1)%e.length];return a.reverse().join(n)}),i=void 0===t.currency?"":t.currency[0]+"",a=void 0===t.currency?"":t.currency[1]+"",o=void 0===t.decimal?".":t.decimal+"",s=void 0===t.numerals?Nf:function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}}(If.call(t.numerals,String)),c=void 0===t.percent?"%":t.percent+"",l=void 0===t.minus?"-":t.minus+"",u=void 0===t.nan?"NaN":t.nan+"";function h(t){var e=(t=Af(t)).fill,n=t.align,h=t.sign,d=t.symbol,f=t.zero,p=t.width,g=t.comma,y=t.precision,m=t.trim,v=t.type;"n"===v?(g=!0,v="g"):jf[v]||(void 0===y&&(y=12),m=!0,v="g"),(f||"0"===e&&"="===n)&&(f=!0,e="0",n="=");var b="$"===d?i:"#"===d&&/[boxX]/.test(v)?"0"+v.toLowerCase():"",_="$"===d?a:/[%p]/.test(v)?c:"",w=jf[v],x=/[defgprs%]/.test(v);function k(t){var i,a,c,d=b,k=_;if("c"===v)k=w(t)+k,t="";else{var C=(t=+t)<0||1/t<0;if(t=isNaN(t)?u:w(Math.abs(t),y),m&&(t=function(t){t:for(var e,n=t.length,r=1,i=-1;r0&&(i=0)}return i>0?t.slice(0,i)+t.slice(e+1):t}(t)),C&&0==+t&&"+"!==h&&(C=!1),d=(C?"("===h?h:l:"-"===h||"("===h?"":h)+d,k=("s"===v?Ff[8+Sf/3]:"")+k+(C&&"("===h?")":""),x)for(i=-1,a=t.length;++i(c=t.charCodeAt(i))||c>57){k=(46===c?o+t.slice(i+1):t.slice(i))+k,t=t.slice(0,i);break}}g&&!f&&(t=r(t,1/0));var T=d.length+t.length+k.length,E=T>1)+d+t+k+E.slice(T);break;default:t=E+d+t+k}return s(t)}return y=void 0===y?6:/[gprs]/.test(v)?Math.max(1,Math.min(21,y)):Math.max(0,Math.min(20,y)),k.toString=function(){return t+""},k}return{format:h,formatPrefix:function(t,e){var n=h(((t=Af(t)).type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(Ef(e)/3))),i=Math.pow(10,-r),a=Ff[8+r/3];return function(t){return n(i*t)+a}}}}function Yf(t){return Bf=Pf(t),Lf=Bf.format,Rf=Bf.formatPrefix,Bf}function zf(t){return Math.max(0,-Ef(Math.abs(t)))}function Uf(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(Ef(e)/3)))-Ef(Math.abs(t)))}function $f(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,Ef(e)-Ef(t))+1}function Wf(){return new qf}function qf(){this.reset()}Yf({decimal:".",thousands:",",grouping:[3],currency:["$",""],minus:"-"}),qf.prototype={constructor:qf,reset:function(){this.s=this.t=0},add:function(t){Vf(Hf,t,this.t),Vf(this,Hf.s,this.s),this.s?this.t+=Hf.t:this.s=Hf.t},valueOf:function(){return this.s}};var Hf=new qf;function Vf(t,e,n){var r=t.s=e+n,i=r-e,a=r-i;t.t=e-a+(n-i)}var Gf=Math.PI,Xf=Gf/2,Zf=Gf/4,Qf=2*Gf,Kf=180/Gf,Jf=Gf/180,tp=Math.abs,ep=Math.atan,np=Math.atan2,rp=Math.cos,ip=Math.ceil,ap=Math.exp,op=Math.log,sp=Math.pow,cp=Math.sin,lp=Math.sign||function(t){return t>0?1:t<0?-1:0},up=Math.sqrt,hp=Math.tan;function dp(t){return t>1?0:t<-1?Gf:Math.acos(t)}function fp(t){return t>1?Xf:t<-1?-Xf:Math.asin(t)}function pp(t){return(t=cp(t/2))*t}function gp(){}function yp(t,e){t&&vp.hasOwnProperty(t.type)&&vp[t.type](t,e)}var mp={Feature:function(t,e){yp(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,r=-1,i=n.length;++r=0?1:-1,i=r*n,a=rp(e=(e*=Jf)/2+Zf),o=cp(e),s=Ep*o,c=Tp*a+s*rp(i),l=s*r*cp(i);Sp.add(np(l,c)),Cp=t,Tp=a,Ep=o}function Bp(t){return[np(t[1],t[0]),fp(t[2])]}function Lp(t){var e=t[0],n=t[1],r=rp(n);return[r*rp(e),r*cp(e),cp(n)]}function Rp(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function Ip(t,e){return[t[1]*e[2]-t[2]*e[1],t[2]*e[0]-t[0]*e[2],t[0]*e[1]-t[1]*e[0]]}function Fp(t,e){t[0]+=e[0],t[1]+=e[1],t[2]+=e[2]}function Pp(t,e){return[t[0]*e,t[1]*e,t[2]*e]}function Yp(t){var e=up(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]);t[0]/=e,t[1]/=e,t[2]/=e}var zp,Up,$p,Wp,qp,Hp,Vp,Gp,Xp,Zp,Qp,Kp,Jp,tg,eg,ng,rg,ig,ag,og,sg,cg,lg,ug,hg,dg,fg=Wf(),pg={point:gg,lineStart:mg,lineEnd:vg,polygonStart:function(){pg.point=bg,pg.lineStart=_g,pg.lineEnd=wg,fg.reset(),Ap.polygonStart()},polygonEnd:function(){Ap.polygonEnd(),pg.point=gg,pg.lineStart=mg,pg.lineEnd=vg,Sp<0?(zp=-($p=180),Up=-(Wp=90)):fg>1e-6?Wp=90:fg<-1e-6&&(Up=-90),Zp[0]=zp,Zp[1]=$p},sphere:function(){zp=-($p=180),Up=-(Wp=90)}};function gg(t,e){Xp.push(Zp=[zp=t,$p=t]),eWp&&(Wp=e)}function yg(t,e){var n=Lp([t*Jf,e*Jf]);if(Gp){var r=Ip(Gp,n),i=Ip([r[1],-r[0],0],r);Yp(i),i=Bp(i);var a,o=t-qp,s=o>0?1:-1,c=i[0]*Kf*s,l=tp(o)>180;l^(s*qpWp&&(Wp=a):l^(s*qp<(c=(c+360)%360-180)&&cWp&&(Wp=e)),l?txg(zp,$p)&&($p=t):xg(t,$p)>xg(zp,$p)&&(zp=t):$p>=zp?(t$p&&($p=t)):t>qp?xg(zp,t)>xg(zp,$p)&&($p=t):xg(t,$p)>xg(zp,$p)&&(zp=t)}else Xp.push(Zp=[zp=t,$p=t]);eWp&&(Wp=e),Gp=n,qp=t}function mg(){pg.point=yg}function vg(){Zp[0]=zp,Zp[1]=$p,pg.point=gg,Gp=null}function bg(t,e){if(Gp){var n=t-qp;fg.add(tp(n)>180?n+(n>0?360:-360):n)}else Hp=t,Vp=e;Ap.point(t,e),yg(t,e)}function _g(){Ap.lineStart()}function wg(){bg(Hp,Vp),Ap.lineEnd(),tp(fg)>1e-6&&(zp=-($p=180)),Zp[0]=zp,Zp[1]=$p,Gp=null}function xg(t,e){return(e-=t)<0?e+360:e}function kg(t,e){return t[0]-e[0]}function Cg(t,e){return t[0]<=t[1]?t[0]<=e&&e<=t[1]:eGf?t+Math.round(-t/Qf)*Qf:t,e]}function Pg(t,e,n){return(t%=Qf)?e||n?Ig(zg(t),Ug(e,n)):zg(t):e||n?Ug(e,n):Fg}function Yg(t){return function(e,n){return[(e+=t)>Gf?e-Qf:e<-Gf?e+Qf:e,n]}}function zg(t){var e=Yg(t);return e.invert=Yg(-t),e}function Ug(t,e){var n=rp(t),r=cp(t),i=rp(e),a=cp(e);function o(t,e){var o=rp(e),s=rp(t)*o,c=cp(t)*o,l=cp(e),u=l*n+s*r;return[np(c*i-u*a,s*n-l*r),fp(u*i+c*a)]}return o.invert=function(t,e){var o=rp(e),s=rp(t)*o,c=cp(t)*o,l=cp(e),u=l*i-c*a;return[np(c*i+l*a,s*n+u*r),fp(u*n-s*r)]},o}function $g(t){function e(e){return(e=t(e[0]*Jf,e[1]*Jf))[0]*=Kf,e[1]*=Kf,e}return t=Pg(t[0]*Jf,t[1]*Jf,t.length>2?t[2]*Jf:0),e.invert=function(e){return(e=t.invert(e[0]*Jf,e[1]*Jf))[0]*=Kf,e[1]*=Kf,e},e}function Wg(t,e,n,r,i,a){if(n){var o=rp(e),s=cp(e),c=r*n;null==i?(i=e+r*Qf,a=e-c/2):(i=qg(o,i),a=qg(o,a),(r>0?ia)&&(i+=r*Qf));for(var l,u=i;r>0?u>a:u1&&e.push(e.pop().concat(e.shift()))},result:function(){var n=e;return e=[],t=null,n}}}function Vg(t,e){return tp(t[0]-e[0])<1e-6&&tp(t[1]-e[1])<1e-6}function Gg(t,e,n,r){this.x=t,this.z=e,this.o=n,this.e=r,this.v=!1,this.n=this.p=null}function Xg(t,e,n,r,i){var a,o,s=[],c=[];if(t.forEach((function(t){if(!((e=t.length-1)<=0)){var e,n,r=t[0],o=t[e];if(Vg(r,o)){if(!r[2]&&!o[2]){for(i.lineStart(),a=0;a=0;--a)i.point((u=l[a])[0],u[1]);else r(d.x,d.p.x,-1,i);d=d.p}l=(d=d.o).z,f=!f}while(!d.v);i.lineEnd()}}}function Zg(t){if(e=t.length){for(var e,n,r=0,i=t[0];++r=0?1:-1,T=C*k,E=T>Gf,S=g*w;if(Qg.add(np(S*C*cp(T),y*x+S*rp(T))),o+=E?k+C*Qf:k,E^f>=n^b>=n){var O=Ip(Lp(d),Lp(v));Yp(O);var A=Ip(a,O);Yp(A);var M=(E^k>=0?-1:1)*fp(A[2]);(r>M||r===M&&(O[0]||O[1]))&&(s+=E^k>=0?1:-1)}}return(o<-1e-6||o<1e-6&&Qg<-1e-6)^1&s}function ty(t,e,n,r){return function(i){var a,o,s,c=e(i),l=Hg(),u=e(l),h=!1,d={point:f,lineStart:g,lineEnd:y,polygonStart:function(){d.point=m,d.lineStart=v,d.lineEnd=b,o=[],a=[]},polygonEnd:function(){d.point=f,d.lineStart=g,d.lineEnd=y,o=Za(o);var t=Jg(a,r);o.length?(h||(i.polygonStart(),h=!0),Xg(o,ny,t,n,i)):t&&(h||(i.polygonStart(),h=!0),i.lineStart(),n(null,null,1,i),i.lineEnd()),h&&(i.polygonEnd(),h=!1),o=a=null},sphere:function(){i.polygonStart(),i.lineStart(),n(null,null,1,i),i.lineEnd(),i.polygonEnd()}};function f(e,n){t(e,n)&&i.point(e,n)}function p(t,e){c.point(t,e)}function g(){d.point=p,c.lineStart()}function y(){d.point=f,c.lineEnd()}function m(t,e){s.push([t,e]),u.point(t,e)}function v(){u.lineStart(),s=[]}function b(){m(s[0][0],s[0][1]),u.lineEnd();var t,e,n,r,c=u.clean(),d=l.result(),f=d.length;if(s.pop(),a.push(s),s=null,f)if(1&c){if((e=(n=d[0]).length-1)>0){for(h||(i.polygonStart(),h=!0),i.lineStart(),t=0;t1&&2&c&&d.push(d.pop().concat(d.shift())),o.push(d.filter(ey))}return d}}function ey(t){return t.length>1}function ny(t,e){return((t=t.x)[0]<0?t[1]-Xf-1e-6:Xf-t[1])-((e=e.x)[0]<0?e[1]-Xf-1e-6:Xf-e[1])}var ry=ty((function(){return!0}),(function(t){var e,n=NaN,r=NaN,i=NaN;return{lineStart:function(){t.lineStart(),e=1},point:function(a,o){var s=a>0?Gf:-Gf,c=tp(a-n);tp(c-Gf)<1e-6?(t.point(n,r=(r+o)/2>0?Xf:-Xf),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(s,r),t.point(a,r),e=0):i!==s&&c>=Gf&&(tp(n-i)<1e-6&&(n-=1e-6*i),tp(a-s)<1e-6&&(a-=1e-6*s),r=function(t,e,n,r){var i,a,o=cp(t-n);return tp(o)>1e-6?ep((cp(e)*(a=rp(r))*cp(n)-cp(r)*(i=rp(e))*cp(t))/(i*a*o)):(e+r)/2}(n,r,a,o),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(s,r),e=0),t.point(n=a,r=o),i=s},lineEnd:function(){t.lineEnd(),n=r=NaN},clean:function(){return 2-e}}}),(function(t,e,n,r){var i;if(null==t)i=n*Xf,r.point(-Gf,i),r.point(0,i),r.point(Gf,i),r.point(Gf,0),r.point(Gf,-i),r.point(0,-i),r.point(-Gf,-i),r.point(-Gf,0),r.point(-Gf,i);else if(tp(t[0]-e[0])>1e-6){var a=t[0]0,i=tp(e)>1e-6;function a(t,n){return rp(t)*rp(n)>e}function o(t,n,r){var i=[1,0,0],a=Ip(Lp(t),Lp(n)),o=Rp(a,a),s=a[0],c=o-s*s;if(!c)return!r&&t;var l=e*o/c,u=-e*s/c,h=Ip(i,a),d=Pp(i,l);Fp(d,Pp(a,u));var f=h,p=Rp(d,f),g=Rp(f,f),y=p*p-g*(Rp(d,d)-1);if(!(y<0)){var m=up(y),v=Pp(f,(-p-m)/g);if(Fp(v,d),v=Bp(v),!r)return v;var b,_=t[0],w=n[0],x=t[1],k=n[1];w<_&&(b=_,_=w,w=b);var C=w-_,T=tp(C-Gf)<1e-6;if(!T&&k0^v[1]<(tp(v[0]-_)<1e-6?x:k):x<=v[1]&&v[1]<=k:C>Gf^(_<=v[0]&&v[0]<=w)){var E=Pp(f,(-p+m)/g);return Fp(E,d),[v,Bp(E)]}}}function s(e,n){var i=r?t:Gf-t,a=0;return e<-i?a|=1:e>i&&(a|=2),n<-i?a|=4:n>i&&(a|=8),a}return ty(a,(function(t){var e,n,c,l,u;return{lineStart:function(){l=c=!1,u=1},point:function(h,d){var f,p=[h,d],g=a(h,d),y=r?g?0:s(h,d):g?s(h+(h<0?Gf:-Gf),d):0;if(!e&&(l=c=g)&&t.lineStart(),g!==c&&(!(f=o(e,p))||Vg(e,f)||Vg(p,f))&&(p[2]=1),g!==c)u=0,g?(t.lineStart(),f=o(p,e),t.point(f[0],f[1])):(f=o(e,p),t.point(f[0],f[1],2),t.lineEnd()),e=f;else if(i&&e&&r^g){var m;y&n||!(m=o(p,e,!0))||(u=0,r?(t.lineStart(),t.point(m[0][0],m[0][1]),t.point(m[1][0],m[1][1]),t.lineEnd()):(t.point(m[1][0],m[1][1]),t.lineEnd(),t.lineStart(),t.point(m[0][0],m[0][1],3)))}!g||e&&Vg(e,p)||t.point(p[0],p[1]),e=p,c=g,n=y},lineEnd:function(){c&&t.lineEnd(),e=null},clean:function(){return u|(l&&c)<<1}}}),(function(e,r,i,a){Wg(a,t,n,i,e,r)}),r?[0,-t]:[-Gf,t-Gf])}function ay(t,e,n,r){function i(i,a){return t<=i&&i<=n&&e<=a&&a<=r}function a(i,a,s,l){var u=0,h=0;if(null==i||(u=o(i,s))!==(h=o(a,s))||c(i,a)<0^s>0)do{l.point(0===u||3===u?t:n,u>1?r:e)}while((u=(u+s+4)%4)!==h);else l.point(a[0],a[1])}function o(r,i){return tp(r[0]-t)<1e-6?i>0?0:3:tp(r[0]-n)<1e-6?i>0?2:1:tp(r[1]-e)<1e-6?i>0?1:0:i>0?3:2}function s(t,e){return c(t.x,e.x)}function c(t,e){var n=o(t,1),r=o(e,1);return n!==r?n-r:0===n?e[1]-t[1]:1===n?t[0]-e[0]:2===n?t[1]-e[1]:e[0]-t[0]}return function(o){var c,l,u,h,d,f,p,g,y,m,v,b=o,_=Hg(),w={point:x,lineStart:function(){w.point=k,l&&l.push(u=[]);m=!0,y=!1,p=g=NaN},lineEnd:function(){c&&(k(h,d),f&&y&&_.rejoin(),c.push(_.result()));w.point=x,y&&b.lineEnd()},polygonStart:function(){b=_,c=[],l=[],v=!0},polygonEnd:function(){var e=function(){for(var e=0,n=0,i=l.length;nr&&(d-a)*(r-o)>(f-o)*(t-a)&&++e:f<=r&&(d-a)*(r-o)<(f-o)*(t-a)&&--e;return e}(),n=v&&e,i=(c=Za(c)).length;(n||i)&&(o.polygonStart(),n&&(o.lineStart(),a(null,null,1,o),o.lineEnd()),i&&Xg(c,s,e,a,o),o.polygonEnd());b=o,c=l=u=null}};function x(t,e){i(t,e)&&b.point(t,e)}function k(a,o){var s=i(a,o);if(l&&u.push([a,o]),m)h=a,d=o,f=s,m=!1,s&&(b.lineStart(),b.point(a,o));else if(s&&y)b.point(a,o);else{var c=[p=Math.max(-1e9,Math.min(1e9,p)),g=Math.max(-1e9,Math.min(1e9,g))],_=[a=Math.max(-1e9,Math.min(1e9,a)),o=Math.max(-1e9,Math.min(1e9,o))];!function(t,e,n,r,i,a){var o,s=t[0],c=t[1],l=0,u=1,h=e[0]-s,d=e[1]-c;if(o=n-s,h||!(o>0)){if(o/=h,h<0){if(o0){if(o>u)return;o>l&&(l=o)}if(o=i-s,h||!(o<0)){if(o/=h,h<0){if(o>u)return;o>l&&(l=o)}else if(h>0){if(o0)){if(o/=d,d<0){if(o0){if(o>u)return;o>l&&(l=o)}if(o=a-c,d||!(o<0)){if(o/=d,d<0){if(o>u)return;o>l&&(l=o)}else if(d>0){if(o0&&(t[0]=s+l*h,t[1]=c+l*d),u<1&&(e[0]=s+u*h,e[1]=c+u*d),!0}}}}}(c,_,t,e,n,r)?s&&(b.lineStart(),b.point(a,o),v=!1):(y||(b.lineStart(),b.point(c[0],c[1])),b.point(_[0],_[1]),s||b.lineEnd(),v=!1)}p=a,g=o,y=s}return w}}var oy,sy,cy,ly=Wf(),uy={sphere:gp,point:gp,lineStart:function(){uy.point=dy,uy.lineEnd=hy},lineEnd:gp,polygonStart:gp,polygonEnd:gp};function hy(){uy.point=uy.lineEnd=gp}function dy(t,e){oy=t*=Jf,sy=cp(e*=Jf),cy=rp(e),uy.point=fy}function fy(t,e){t*=Jf;var n=cp(e*=Jf),r=rp(e),i=tp(t-oy),a=rp(i),o=r*cp(i),s=cy*n-sy*r*a,c=sy*n+cy*r*a;ly.add(np(up(o*o+s*s),c)),oy=t,sy=n,cy=r}function py(t){return ly.reset(),wp(t,uy),+ly}var gy=[null,null],yy={type:"LineString",coordinates:gy};function my(t,e){return gy[0]=t,gy[1]=e,py(yy)}var vy={Feature:function(t,e){return _y(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,r=-1,i=n.length;++r0&&(i=my(t[a],t[a-1]))>0&&n<=i&&r<=i&&(n+r-i)*(1-Math.pow((n-r)/i,2))<1e-12*i)return!0;n=r}return!1}function ky(t,e){return!!Jg(t.map(Cy),Ty(e))}function Cy(t){return(t=t.map(Ty)).pop(),t}function Ty(t){return[t[0]*Jf,t[1]*Jf]}function Ey(t,e,n){var r=Ya(t,e-1e-6,n).concat(e);return function(t){return r.map((function(e){return[t,e]}))}}function Sy(t,e,n){var r=Ya(t,e-1e-6,n).concat(e);return function(t){return r.map((function(e){return[e,t]}))}}function Oy(){var t,e,n,r,i,a,o,s,c,l,u,h,d=10,f=d,p=90,g=360,y=2.5;function m(){return{type:"MultiLineString",coordinates:v()}}function v(){return Ya(ip(r/p)*p,n,p).map(u).concat(Ya(ip(s/g)*g,o,g).map(h)).concat(Ya(ip(e/d)*d,t,d).filter((function(t){return tp(t%p)>1e-6})).map(c)).concat(Ya(ip(a/f)*f,i,f).filter((function(t){return tp(t%g)>1e-6})).map(l))}return m.lines=function(){return v().map((function(t){return{type:"LineString",coordinates:t}}))},m.outline=function(){return{type:"Polygon",coordinates:[u(r).concat(h(o).slice(1),u(n).reverse().slice(1),h(s).reverse().slice(1))]}},m.extent=function(t){return arguments.length?m.extentMajor(t).extentMinor(t):m.extentMinor()},m.extentMajor=function(t){return arguments.length?(r=+t[0][0],n=+t[1][0],s=+t[0][1],o=+t[1][1],r>n&&(t=r,r=n,n=t),s>o&&(t=s,s=o,o=t),m.precision(y)):[[r,s],[n,o]]},m.extentMinor=function(n){return arguments.length?(e=+n[0][0],t=+n[1][0],a=+n[0][1],i=+n[1][1],e>t&&(n=e,e=t,t=n),a>i&&(n=a,a=i,i=n),m.precision(y)):[[e,a],[t,i]]},m.step=function(t){return arguments.length?m.stepMajor(t).stepMinor(t):m.stepMinor()},m.stepMajor=function(t){return arguments.length?(p=+t[0],g=+t[1],m):[p,g]},m.stepMinor=function(t){return arguments.length?(d=+t[0],f=+t[1],m):[d,f]},m.precision=function(d){return arguments.length?(y=+d,c=Ey(a,i,90),l=Sy(e,t,y),u=Ey(s,o,90),h=Sy(r,n,y),m):y},m.extentMajor([[-180,-89.999999],[180,89.999999]]).extentMinor([[-180,-80.000001],[180,80.000001]])}function Ay(t){return t}var My,Dy,jy,Ny,By=Wf(),Ly=Wf(),Ry={point:gp,lineStart:gp,lineEnd:gp,polygonStart:function(){Ry.lineStart=Iy,Ry.lineEnd=Yy},polygonEnd:function(){Ry.lineStart=Ry.lineEnd=Ry.point=gp,By.add(tp(Ly)),Ly.reset()},result:function(){var t=By/2;return By.reset(),t}};function Iy(){Ry.point=Fy}function Fy(t,e){Ry.point=Py,My=jy=t,Dy=Ny=e}function Py(t,e){Ly.add(Ny*t-jy*e),jy=t,Ny=e}function Yy(){Py(My,Dy)}var zy=1/0,Uy=zy,$y=-zy,Wy=$y,qy={point:function(t,e){t$y&&($y=t);eWy&&(Wy=e)},lineStart:gp,lineEnd:gp,polygonStart:gp,polygonEnd:gp,result:function(){var t=[[zy,Uy],[$y,Wy]];return $y=Wy=-(Uy=zy=1/0),t}};var Hy,Vy,Gy,Xy,Zy=0,Qy=0,Ky=0,Jy=0,tm=0,em=0,nm=0,rm=0,im=0,am={point:om,lineStart:sm,lineEnd:um,polygonStart:function(){am.lineStart=hm,am.lineEnd=dm},polygonEnd:function(){am.point=om,am.lineStart=sm,am.lineEnd=um},result:function(){var t=im?[nm/im,rm/im]:em?[Jy/em,tm/em]:Ky?[Zy/Ky,Qy/Ky]:[NaN,NaN];return Zy=Qy=Ky=Jy=tm=em=nm=rm=im=0,t}};function om(t,e){Zy+=t,Qy+=e,++Ky}function sm(){am.point=cm}function cm(t,e){am.point=lm,om(Gy=t,Xy=e)}function lm(t,e){var n=t-Gy,r=e-Xy,i=up(n*n+r*r);Jy+=i*(Gy+t)/2,tm+=i*(Xy+e)/2,em+=i,om(Gy=t,Xy=e)}function um(){am.point=om}function hm(){am.point=fm}function dm(){pm(Hy,Vy)}function fm(t,e){am.point=pm,om(Hy=Gy=t,Vy=Xy=e)}function pm(t,e){var n=t-Gy,r=e-Xy,i=up(n*n+r*r);Jy+=i*(Gy+t)/2,tm+=i*(Xy+e)/2,em+=i,nm+=(i=Xy*t-Gy*e)*(Gy+t),rm+=i*(Xy+e),im+=3*i,om(Gy=t,Xy=e)}function gm(t){this._context=t}gm.prototype={_radius:4.5,pointRadius:function(t){return this._radius=t,this},polygonStart:function(){this._line=0},polygonEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){0===this._line&&this._context.closePath(),this._point=NaN},point:function(t,e){switch(this._point){case 0:this._context.moveTo(t,e),this._point=1;break;case 1:this._context.lineTo(t,e);break;default:this._context.moveTo(t+this._radius,e),this._context.arc(t,e,this._radius,0,Qf)}},result:gp};var ym,mm,vm,bm,_m,wm=Wf(),xm={point:gp,lineStart:function(){xm.point=km},lineEnd:function(){ym&&Cm(mm,vm),xm.point=gp},polygonStart:function(){ym=!0},polygonEnd:function(){ym=null},result:function(){var t=+wm;return wm.reset(),t}};function km(t,e){xm.point=Cm,mm=bm=t,vm=_m=e}function Cm(t,e){bm-=t,_m-=e,wm.add(up(bm*bm+_m*_m)),bm=t,_m=e}function Tm(){this._string=[]}function Em(t){return"m0,"+t+"a"+t+","+t+" 0 1,1 0,"+-2*t+"a"+t+","+t+" 0 1,1 0,"+2*t+"z"}function Sm(t){return function(e){var n=new Om;for(var r in t)n[r]=t[r];return n.stream=e,n}}function Om(){}function Am(t,e,n){var r=t.clipExtent&&t.clipExtent();return t.scale(150).translate([0,0]),null!=r&&t.clipExtent(null),wp(n,t.stream(qy)),e(qy.result()),null!=r&&t.clipExtent(r),t}function Mm(t,e,n){return Am(t,(function(n){var r=e[1][0]-e[0][0],i=e[1][1]-e[0][1],a=Math.min(r/(n[1][0]-n[0][0]),i/(n[1][1]-n[0][1])),o=+e[0][0]+(r-a*(n[1][0]+n[0][0]))/2,s=+e[0][1]+(i-a*(n[1][1]+n[0][1]))/2;t.scale(150*a).translate([o,s])}),n)}function Dm(t,e,n){return Mm(t,[[0,0],e],n)}function jm(t,e,n){return Am(t,(function(n){var r=+e,i=r/(n[1][0]-n[0][0]),a=(r-i*(n[1][0]+n[0][0]))/2,o=-i*n[0][1];t.scale(150*i).translate([a,o])}),n)}function Nm(t,e,n){return Am(t,(function(n){var r=+e,i=r/(n[1][1]-n[0][1]),a=-i*n[0][0],o=(r-i*(n[1][1]+n[0][1]))/2;t.scale(150*i).translate([a,o])}),n)}Tm.prototype={_radius:4.5,_circle:Em(4.5),pointRadius:function(t){return(t=+t)!==this._radius&&(this._radius=t,this._circle=null),this},polygonStart:function(){this._line=0},polygonEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){0===this._line&&this._string.push("Z"),this._point=NaN},point:function(t,e){switch(this._point){case 0:this._string.push("M",t,",",e),this._point=1;break;case 1:this._string.push("L",t,",",e);break;default:null==this._circle&&(this._circle=Em(this._radius)),this._string.push("M",t,",",e,this._circle)}},result:function(){if(this._string.length){var t=this._string.join("");return this._string=[],t}return null}},Om.prototype={constructor:Om,point:function(t,e){this.stream.point(t,e)},sphere:function(){this.stream.sphere()},lineStart:function(){this.stream.lineStart()},lineEnd:function(){this.stream.lineEnd()},polygonStart:function(){this.stream.polygonStart()},polygonEnd:function(){this.stream.polygonEnd()}};var Bm=rp(30*Jf);function Lm(t,e){return+e?function(t,e){function n(r,i,a,o,s,c,l,u,h,d,f,p,g,y){var m=l-r,v=u-i,b=m*m+v*v;if(b>4*e&&g--){var _=o+d,w=s+f,x=c+p,k=up(_*_+w*w+x*x),C=fp(x/=k),T=tp(tp(x)-1)<1e-6||tp(a-h)<1e-6?(a+h)/2:np(w,_),E=t(T,C),S=E[0],O=E[1],A=S-r,M=O-i,D=v*A-m*M;(D*D/b>e||tp((m*A+v*M)/b-.5)>.3||o*d+s*f+c*p2?t[2]%360*Jf:0,A()):[y*Kf,m*Kf,v*Kf]},S.angle=function(t){return arguments.length?(b=t%360*Jf,A()):b*Kf},S.reflectX=function(t){return arguments.length?(_=t?-1:1,A()):_<0},S.reflectY=function(t){return arguments.length?(w=t?-1:1,A()):w<0},S.precision=function(t){return arguments.length?(o=Lm(s,E=t*t),M()):up(E)},S.fitExtent=function(t,e){return Mm(S,t,e)},S.fitSize=function(t,e){return Dm(S,t,e)},S.fitWidth=function(t,e){return jm(S,t,e)},S.fitHeight=function(t,e){return Nm(S,t,e)},function(){return e=t.apply(this,arguments),S.invert=e.invert&&O,A()}}function zm(t){var e=0,n=Gf/3,r=Ym(t),i=r(e,n);return i.parallels=function(t){return arguments.length?r(e=t[0]*Jf,n=t[1]*Jf):[e*Kf,n*Kf]},i}function Um(t,e){var n=cp(t),r=(n+cp(e))/2;if(tp(r)<1e-6)return function(t){var e=rp(t);function n(t,n){return[t*e,cp(n)/e]}return n.invert=function(t,n){return[t/e,fp(n*e)]},n}(t);var i=1+n*(2*r-n),a=up(i)/r;function o(t,e){var n=up(i-2*r*cp(e))/r;return[n*cp(t*=r),a-n*rp(t)]}return o.invert=function(t,e){var n=a-e,o=np(t,tp(n))*lp(n);return n*r<0&&(o-=Gf*lp(t)*lp(n)),[o/r,fp((i-(t*t+n*n)*r*r)/(2*r))]},o}function $m(){return zm(Um).scale(155.424).center([0,33.6442])}function Wm(){return $m().parallels([29.5,45.5]).scale(1070).translate([480,250]).rotate([96,0]).center([-.6,38.7])}function qm(t){return function(e,n){var r=rp(e),i=rp(n),a=t(r*i);return[a*i*cp(e),a*cp(n)]}}function Hm(t){return function(e,n){var r=up(e*e+n*n),i=t(r),a=cp(i),o=rp(i);return[np(e*a,r*o),fp(r&&n*a/r)]}}var Vm=qm((function(t){return up(2/(1+t))}));Vm.invert=Hm((function(t){return 2*fp(t/2)}));var Gm=qm((function(t){return(t=dp(t))&&t/cp(t)}));function Xm(t,e){return[t,op(hp((Xf+e)/2))]}function Zm(t){var e,n,r,i=Pm(t),a=i.center,o=i.scale,s=i.translate,c=i.clipExtent,l=null;function u(){var a=Gf*o(),s=i($g(i.rotate()).invert([0,0]));return c(null==l?[[s[0]-a,s[1]-a],[s[0]+a,s[1]+a]]:t===Xm?[[Math.max(s[0]-a,l),e],[Math.min(s[0]+a,n),r]]:[[l,Math.max(s[1]-a,e)],[n,Math.min(s[1]+a,r)]])}return i.scale=function(t){return arguments.length?(o(t),u()):o()},i.translate=function(t){return arguments.length?(s(t),u()):s()},i.center=function(t){return arguments.length?(a(t),u()):a()},i.clipExtent=function(t){return arguments.length?(null==t?l=e=n=r=null:(l=+t[0][0],e=+t[0][1],n=+t[1][0],r=+t[1][1]),u()):null==l?null:[[l,e],[n,r]]},u()}function Qm(t){return hp((Xf+t)/2)}function Km(t,e){var n=rp(t),r=t===e?cp(t):op(n/rp(e))/op(Qm(e)/Qm(t)),i=n*sp(Qm(t),r)/r;if(!r)return Xm;function a(t,e){i>0?e<1e-6-Xf&&(e=1e-6-Xf):e>Xf-1e-6&&(e=Xf-1e-6);var n=i/sp(Qm(e),r);return[n*cp(r*t),i-n*rp(r*t)]}return a.invert=function(t,e){var n=i-e,a=lp(r)*up(t*t+n*n),o=np(t,tp(n))*lp(n);return n*r<0&&(o-=Gf*lp(t)*lp(n)),[o/r,2*ep(sp(i/a,1/r))-Xf]},a}function Jm(t,e){return[t,e]}function tv(t,e){var n=rp(t),r=t===e?cp(t):(n-rp(e))/(e-t),i=n/r+t;if(tp(r)<1e-6)return Jm;function a(t,e){var n=i-e,a=r*t;return[n*cp(a),i-n*rp(a)]}return a.invert=function(t,e){var n=i-e,a=np(t,tp(n))*lp(n);return n*r<0&&(a-=Gf*lp(t)*lp(n)),[a/r,i-lp(r)*up(t*t+n*n)]},a}Gm.invert=Hm((function(t){return t})),Xm.invert=function(t,e){return[t,2*ep(ap(e))-Xf]},Jm.invert=Jm;var ev=1.340264,nv=-.081106,rv=893e-6,iv=.003796,av=up(3)/2;function ov(t,e){var n=fp(av*cp(e)),r=n*n,i=r*r*r;return[t*rp(n)/(av*(ev+3*nv*r+i*(7*rv+9*iv*r))),n*(ev+nv*r+i*(rv+iv*r))]}function sv(t,e){var n=rp(e),r=rp(t)*n;return[n*cp(t)/r,cp(e)/r]}function cv(t,e){var n=e*e,r=n*n;return[t*(.8707-.131979*n+r*(r*(.003971*n-.001529*r)-.013791)),e*(1.007226+n*(.015085+r*(.028874*n-.044475-.005916*r)))]}function lv(t,e){return[rp(e)*cp(t),cp(e)]}function uv(t,e){var n=rp(e),r=1+rp(t)*n;return[n*cp(t)/r,cp(e)/r]}function hv(t,e){return[op(hp((Xf+e)/2)),-t]}function dv(t,e){return t.parent===e.parent?1:2}function fv(t,e){return t+e.x}function pv(t,e){return Math.max(t,e.y)}function gv(t){var e=0,n=t.children,r=n&&n.length;if(r)for(;--r>=0;)e+=n[r].value;else e=1;t.value=e}function yv(t,e){var n,r,i,a,o,s=new _v(t),c=+t.value&&(s.value=t.value),l=[s];for(null==e&&(e=mv);n=l.pop();)if(c&&(n.value=+n.data.value),(i=e(n.data))&&(o=i.length))for(n.children=new Array(o),a=o-1;a>=0;--a)l.push(r=n.children[a]=new _v(i[a])),r.parent=n,r.depth=n.depth+1;return s.eachBefore(bv)}function mv(t){return t.children}function vv(t){t.data=t.data.data}function bv(t){var e=0;do{t.height=e}while((t=t.parent)&&t.height<++e)}function _v(t){this.data=t,this.depth=this.height=0,this.parent=null}ov.invert=function(t,e){for(var n,r=e,i=r*r,a=i*i*i,o=0;o<12&&(a=(i=(r-=n=(r*(ev+nv*i+a*(rv+iv*i))-e)/(ev+3*nv*i+a*(7*rv+9*iv*i)))*r)*i*i,!(tp(n)<1e-12));++o);return[av*t*(ev+3*nv*i+a*(7*rv+9*iv*i))/rp(r),fp(cp(r)/av)]},sv.invert=Hm(ep),cv.invert=function(t,e){var n,r=e,i=25;do{var a=r*r,o=a*a;r-=n=(r*(1.007226+a*(.015085+o*(.028874*a-.044475-.005916*o)))-e)/(1.007226+a*(.045255+o*(.259866*a-.311325-.005916*11*o)))}while(tp(n)>1e-6&&--i>0);return[t/(.8707+(a=r*r)*(a*(a*a*a*(.003971-.001529*a)-.013791)-.131979)),r]},lv.invert=Hm(fp),uv.invert=Hm((function(t){return 2*ep(t)})),hv.invert=function(t,e){return[-e,2*ep(ap(t))-Xf]},_v.prototype=yv.prototype={constructor:_v,count:function(){return this.eachAfter(gv)},each:function(t){var e,n,r,i,a=this,o=[a];do{for(e=o.reverse(),o=[];a=e.pop();)if(t(a),n=a.children)for(r=0,i=n.length;r=0;--n)i.push(e[n]);return this},sum:function(t){return this.eachAfter((function(e){for(var n=+t(e.data)||0,r=e.children,i=r&&r.length;--i>=0;)n+=r[i].value;e.value=n}))},sort:function(t){return this.eachBefore((function(e){e.children&&e.children.sort(t)}))},path:function(t){for(var e=this,n=function(t,e){if(t===e)return t;var n=t.ancestors(),r=e.ancestors(),i=null;t=n.pop(),e=r.pop();for(;t===e;)i=t,t=n.pop(),e=r.pop();return i}(e,t),r=[e];e!==n;)e=e.parent,r.push(e);for(var i=r.length;t!==n;)r.splice(i,0,t),t=t.parent;return r},ancestors:function(){for(var t=this,e=[t];t=t.parent;)e.push(t);return e},descendants:function(){var t=[];return this.each((function(e){t.push(e)})),t},leaves:function(){var t=[];return this.eachBefore((function(e){e.children||t.push(e)})),t},links:function(){var t=this,e=[];return t.each((function(n){n!==t&&e.push({source:n.parent,target:n})})),e},copy:function(){return yv(this).eachBefore(vv)}};var wv=Array.prototype.slice;function xv(t){for(var e,n,r=0,i=(t=function(t){for(var e,n,r=t.length;r;)n=Math.random()*r--|0,e=t[r],t[r]=t[n],t[n]=e;return t}(wv.call(t))).length,a=[];r0&&n*n>r*r+i*i}function Ev(t,e){for(var n=0;n(o*=o)?(r=(l+o-i)/(2*l),a=Math.sqrt(Math.max(0,o/l-r*r)),n.x=t.x-r*s-a*c,n.y=t.y-r*c+a*s):(r=(l+i-o)/(2*l),a=Math.sqrt(Math.max(0,i/l-r*r)),n.x=e.x+r*s-a*c,n.y=e.y+r*c+a*s)):(n.x=e.x+n.r,n.y=e.y)}function Dv(t,e){var n=t.r+e.r-1e-6,r=e.x-t.x,i=e.y-t.y;return n>0&&n*n>r*r+i*i}function jv(t){var e=t._,n=t.next._,r=e.r+n.r,i=(e.x*n.r+n.x*e.r)/r,a=(e.y*n.r+n.y*e.r)/r;return i*i+a*a}function Nv(t){this._=t,this.next=null,this.previous=null}function Bv(t){if(!(i=t.length))return 0;var e,n,r,i,a,o,s,c,l,u,h;if((e=t[0]).x=0,e.y=0,!(i>1))return e.r;if(n=t[1],e.x=-n.r,n.x=e.r,n.y=0,!(i>2))return e.r+n.r;Mv(n,e,r=t[2]),e=new Nv(e),n=new Nv(n),r=new Nv(r),e.next=r.previous=n,n.next=e.previous=r,r.next=n.previous=e;t:for(s=3;sd&&(d=s),y=u*u*g,(f=Math.max(d/y,y/h))>p){u-=s;break}p=f}m.push(o={value:u,dice:c1?e:1)},n}(nb);var ab=function t(e){function n(t,n,r,i,a){if((o=t._squarify)&&o.ratio===e)for(var o,s,c,l,u,h=-1,d=o.length,f=t.value;++h1?e:1)},n}(nb);function ob(t,e){return t[0]-e[0]||t[1]-e[1]}function sb(t){for(var e,n,r,i=t.length,a=[0,1],o=2,s=2;s1&&(e=t[a[o-2]],n=t[a[o-1]],r=t[s],(n[0]-e[0])*(r[1]-e[1])-(n[1]-e[1])*(r[0]-e[0])<=0);)--o;a[o++]=s}return a.slice(0,o)}function cb(){return Math.random()}var lb=function t(e){function n(t,n){return t=null==t?0:+t,n=null==n?1:+n,1===arguments.length?(n=t,t=0):n-=t,function(){return e()*n+t}}return n.source=t,n}(cb),ub=function t(e){function n(t,n){var r,i;return t=null==t?0:+t,n=null==n?1:+n,function(){var a;if(null!=r)a=r,r=null;else do{r=2*e()-1,a=2*e()-1,i=r*r+a*a}while(!i||i>1);return t+n*a*Math.sqrt(-2*Math.log(i)/i)}}return n.source=t,n}(cb),hb=function t(e){function n(){var t=ub.source(e).apply(this,arguments);return function(){return Math.exp(t())}}return n.source=t,n}(cb),db=function t(e){function n(t){return function(){for(var n=0,r=0;rr&&(e=n,n=r,r=e),function(t){return Math.max(n,Math.min(r,t))}}function Ab(t,e,n){var r=t[0],i=t[1],a=e[0],o=e[1];return i2?Mb:Ab,i=a=null,h}function h(e){return isNaN(e=+e)?n:(i||(i=r(o.map(t),s,c)))(t(l(e)))}return h.invert=function(n){return l(e((a||(a=r(s,o.map(t),ll)))(n)))},h.domain=function(t){return arguments.length?(o=vb.call(t,Cb),l===Eb||(l=Ob(o)),u()):o.slice()},h.range=function(t){return arguments.length?(s=bb.call(t),u()):s.slice()},h.rangeRound=function(t){return s=bb.call(t),c=gl,u()},h.clamp=function(t){return arguments.length?(l=t?Ob(o):Eb,h):l!==Eb},h.interpolate=function(t){return arguments.length?(c=t,u()):c},h.unknown=function(t){return arguments.length?(n=t,h):n},function(n,r){return t=n,e=r,u()}}function Nb(t,e){return jb()(t,e)}function Bb(t,e,n,r){var i,a=Ha(t,e,n);switch((r=Af(null==r?",f":r)).type){case"s":var o=Math.max(Math.abs(t),Math.abs(e));return null!=r.precision||isNaN(i=Uf(a,o))||(r.precision=i),Rf(r,o);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(i=$f(a,Math.max(Math.abs(t),Math.abs(e))))||(r.precision=i-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(i=zf(a))||(r.precision=i-2*("%"===r.type))}return Lf(r)}function Lb(t){var e=t.domain;return t.ticks=function(t){var n=e();return Wa(n[0],n[n.length-1],null==t?10:t)},t.tickFormat=function(t,n){var r=e();return Bb(r[0],r[r.length-1],null==t?10:t,n)},t.nice=function(n){null==n&&(n=10);var r,i=e(),a=0,o=i.length-1,s=i[a],c=i[o];return c0?r=qa(s=Math.floor(s/r)*r,c=Math.ceil(c/r)*r,n):r<0&&(r=qa(s=Math.ceil(s*r)/r,c=Math.floor(c*r)/r,n)),r>0?(i[a]=Math.floor(s/r)*r,i[o]=Math.ceil(c/r)*r,e(i)):r<0&&(i[a]=Math.ceil(s*r)/r,i[o]=Math.floor(c*r)/r,e(i)),t},t}function Rb(t,e){var n,r=0,i=(t=t.slice()).length-1,a=t[r],o=t[i];return o0){for(;dc)break;g.push(h)}}else for(;d=1;--u)if(!((h=l*u)c)break;g.push(h)}}else g=Wa(d,f,Math.min(f-d,p)).map(n);return r?g.reverse():g},r.tickFormat=function(t,i){if(null==i&&(i=10===a?".0e":","),"function"!=typeof i&&(i=Lf(i)),t===1/0)return i;null==t&&(t=10);var o=Math.max(1,a*t/r.ticks().length);return function(t){var r=t/n(Math.round(e(t)));return r*a0))return s;do{s.push(o=new Date(+n)),e(n,a),t(n)}while(o=e)for(;t(e),!n(e);)e.setTime(e-1)}),(function(t,r){if(t>=t)if(r<0)for(;++r<=0;)for(;e(t,-1),!n(t););else for(;--r>=0;)for(;e(t,1),!n(t););}))},n&&(i.count=function(e,r){return Kb.setTime(+e),Jb.setTime(+r),t(Kb),t(Jb),Math.floor(n(Kb,Jb))},i.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?i.filter(r?function(e){return r(e)%t==0}:function(e){return i.count(0,e)%t==0}):i:null}),i}var e_=t_((function(){}),(function(t,e){t.setTime(+t+e)}),(function(t,e){return e-t}));e_.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?t_((function(e){e.setTime(Math.floor(e/t)*t)}),(function(e,n){e.setTime(+e+n*t)}),(function(e,n){return(n-e)/t})):e_:null};var n_=e_.range,r_=t_((function(t){t.setTime(t-t.getMilliseconds())}),(function(t,e){t.setTime(+t+1e3*e)}),(function(t,e){return(e-t)/1e3}),(function(t){return t.getUTCSeconds()})),i_=r_.range,a_=t_((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds())}),(function(t,e){t.setTime(+t+6e4*e)}),(function(t,e){return(e-t)/6e4}),(function(t){return t.getMinutes()})),o_=a_.range,s_=t_((function(t){t.setTime(t-t.getMilliseconds()-1e3*t.getSeconds()-6e4*t.getMinutes())}),(function(t,e){t.setTime(+t+36e5*e)}),(function(t,e){return(e-t)/36e5}),(function(t){return t.getHours()})),c_=s_.range,l_=t_((function(t){t.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/864e5}),(function(t){return t.getDate()-1})),u_=l_.range;function h_(t){return t_((function(e){e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+7*e)}),(function(t,e){return(e-t-6e4*(e.getTimezoneOffset()-t.getTimezoneOffset()))/6048e5}))}var d_=h_(0),f_=h_(1),p_=h_(2),g_=h_(3),y_=h_(4),m_=h_(5),v_=h_(6),b_=d_.range,__=f_.range,w_=p_.range,x_=g_.range,k_=y_.range,C_=m_.range,T_=v_.range,E_=t_((function(t){t.setDate(1),t.setHours(0,0,0,0)}),(function(t,e){t.setMonth(t.getMonth()+e)}),(function(t,e){return e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear())}),(function(t){return t.getMonth()})),S_=E_.range,O_=t_((function(t){t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,e){t.setFullYear(t.getFullYear()+e)}),(function(t,e){return e.getFullYear()-t.getFullYear()}),(function(t){return t.getFullYear()}));O_.every=function(t){return isFinite(t=Math.floor(t))&&t>0?t_((function(e){e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)}),(function(e,n){e.setFullYear(e.getFullYear()+n*t)})):null};var A_=O_.range,M_=t_((function(t){t.setUTCSeconds(0,0)}),(function(t,e){t.setTime(+t+6e4*e)}),(function(t,e){return(e-t)/6e4}),(function(t){return t.getUTCMinutes()})),D_=M_.range,j_=t_((function(t){t.setUTCMinutes(0,0,0)}),(function(t,e){t.setTime(+t+36e5*e)}),(function(t,e){return(e-t)/36e5}),(function(t){return t.getUTCHours()})),N_=j_.range,B_=t_((function(t){t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+e)}),(function(t,e){return(e-t)/864e5}),(function(t){return t.getUTCDate()-1})),L_=B_.range;function R_(t){return t_((function(e){e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+7*e)}),(function(t,e){return(e-t)/6048e5}))}var I_=R_(0),F_=R_(1),P_=R_(2),Y_=R_(3),z_=R_(4),U_=R_(5),$_=R_(6),W_=I_.range,q_=F_.range,H_=P_.range,V_=Y_.range,G_=z_.range,X_=U_.range,Z_=$_.range,Q_=t_((function(t){t.setUTCDate(1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCMonth(t.getUTCMonth()+e)}),(function(t,e){return e.getUTCMonth()-t.getUTCMonth()+12*(e.getUTCFullYear()-t.getUTCFullYear())}),(function(t){return t.getUTCMonth()})),K_=Q_.range,J_=t_((function(t){t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCFullYear(t.getUTCFullYear()+e)}),(function(t,e){return e.getUTCFullYear()-t.getUTCFullYear()}),(function(t){return t.getUTCFullYear()}));J_.every=function(t){return isFinite(t=Math.floor(t))&&t>0?t_((function(e){e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),(function(e,n){e.setUTCFullYear(e.getUTCFullYear()+n*t)})):null};var tw=J_.range;function ew(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function nw(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function rw(t,e,n){return{y:t,m:e,d:n,H:0,M:0,S:0,L:0}}function iw(t){var e=t.dateTime,n=t.date,r=t.time,i=t.periods,a=t.days,o=t.shortDays,s=t.months,c=t.shortMonths,l=yw(i),u=mw(i),h=yw(a),d=mw(a),f=yw(o),p=mw(o),g=yw(s),y=mw(s),m=yw(c),v=mw(c),b={a:function(t){return o[t.getDay()]},A:function(t){return a[t.getDay()]},b:function(t){return c[t.getMonth()]},B:function(t){return s[t.getMonth()]},c:null,d:Fw,e:Fw,f:$w,g:tx,G:nx,H:Pw,I:Yw,j:zw,L:Uw,m:Ww,M:qw,p:function(t){return i[+(t.getHours()>=12)]},q:function(t){return 1+~~(t.getMonth()/3)},Q:Tx,s:Ex,S:Hw,u:Vw,U:Gw,V:Zw,w:Qw,W:Kw,x:null,X:null,y:Jw,Y:ex,Z:rx,"%":Cx},_={a:function(t){return o[t.getUTCDay()]},A:function(t){return a[t.getUTCDay()]},b:function(t){return c[t.getUTCMonth()]},B:function(t){return s[t.getUTCMonth()]},c:null,d:ix,e:ix,f:lx,g:_x,G:xx,H:ax,I:ox,j:sx,L:cx,m:ux,M:hx,p:function(t){return i[+(t.getUTCHours()>=12)]},q:function(t){return 1+~~(t.getUTCMonth()/3)},Q:Tx,s:Ex,S:dx,u:fx,U:px,V:yx,w:mx,W:vx,x:null,X:null,y:bx,Y:wx,Z:kx,"%":Cx},w={a:function(t,e,n){var r=f.exec(e.slice(n));return r?(t.w=p[r[0].toLowerCase()],n+r[0].length):-1},A:function(t,e,n){var r=h.exec(e.slice(n));return r?(t.w=d[r[0].toLowerCase()],n+r[0].length):-1},b:function(t,e,n){var r=m.exec(e.slice(n));return r?(t.m=v[r[0].toLowerCase()],n+r[0].length):-1},B:function(t,e,n){var r=g.exec(e.slice(n));return r?(t.m=y[r[0].toLowerCase()],n+r[0].length):-1},c:function(t,n,r){return C(t,e,n,r)},d:Ow,e:Ow,f:Bw,g:Cw,G:kw,H:Mw,I:Mw,j:Aw,L:Nw,m:Sw,M:Dw,p:function(t,e,n){var r=l.exec(e.slice(n));return r?(t.p=u[r[0].toLowerCase()],n+r[0].length):-1},q:Ew,Q:Rw,s:Iw,S:jw,u:bw,U:_w,V:ww,w:vw,W:xw,x:function(t,e,r){return C(t,n,e,r)},X:function(t,e,n){return C(t,r,e,n)},y:Cw,Y:kw,Z:Tw,"%":Lw};function x(t,e){return function(n){var r,i,a,o=[],s=-1,c=0,l=t.length;for(n instanceof Date||(n=new Date(+n));++s53)return null;"w"in a||(a.w=1),"Z"in a?(i=(r=nw(rw(a.y,0,1))).getUTCDay(),r=i>4||0===i?F_.ceil(r):F_(r),r=B_.offset(r,7*(a.V-1)),a.y=r.getUTCFullYear(),a.m=r.getUTCMonth(),a.d=r.getUTCDate()+(a.w+6)%7):(i=(r=ew(rw(a.y,0,1))).getDay(),r=i>4||0===i?f_.ceil(r):f_(r),r=l_.offset(r,7*(a.V-1)),a.y=r.getFullYear(),a.m=r.getMonth(),a.d=r.getDate()+(a.w+6)%7)}else("W"in a||"U"in a)&&("w"in a||(a.w="u"in a?a.u%7:"W"in a?1:0),i="Z"in a?nw(rw(a.y,0,1)).getUTCDay():ew(rw(a.y,0,1)).getDay(),a.m=0,a.d="W"in a?(a.w+6)%7+7*a.W-(i+5)%7:a.w+7*a.U-(i+6)%7);return"Z"in a?(a.H+=a.Z/100|0,a.M+=a.Z%100,nw(a)):ew(a)}}function C(t,e,n,r){for(var i,a,o=0,s=e.length,c=n.length;o=c)return-1;if(37===(i=e.charCodeAt(o++))){if(i=e.charAt(o++),!(a=w[i in uw?e.charAt(o++):i])||(r=a(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}return b.x=x(n,b),b.X=x(r,b),b.c=x(e,b),_.x=x(n,_),_.X=x(r,_),_.c=x(e,_),{format:function(t){var e=x(t+="",b);return e.toString=function(){return t},e},parse:function(t){var e=k(t+="",!1);return e.toString=function(){return t},e},utcFormat:function(t){var e=x(t+="",_);return e.toString=function(){return t},e},utcParse:function(t){var e=k(t+="",!0);return e.toString=function(){return t},e}}}var aw,ow,sw,cw,lw,uw={"-":"",_:" ",0:"0"},hw=/^\s*\d+/,dw=/^%/,fw=/[\\^$*+?|[\]().{}]/g;function pw(t,e,n){var r=t<0?"-":"",i=(r?-t:t)+"",a=i.length;return r+(a68?1900:2e3),n+r[0].length):-1}function Tw(t,e,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(n,n+6));return r?(t.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function Ew(t,e,n){var r=hw.exec(e.slice(n,n+1));return r?(t.q=3*r[0]-3,n+r[0].length):-1}function Sw(t,e,n){var r=hw.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function Ow(t,e,n){var r=hw.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function Aw(t,e,n){var r=hw.exec(e.slice(n,n+3));return r?(t.m=0,t.d=+r[0],n+r[0].length):-1}function Mw(t,e,n){var r=hw.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function Dw(t,e,n){var r=hw.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function jw(t,e,n){var r=hw.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function Nw(t,e,n){var r=hw.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function Bw(t,e,n){var r=hw.exec(e.slice(n,n+6));return r?(t.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Lw(t,e,n){var r=dw.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function Rw(t,e,n){var r=hw.exec(e.slice(n));return r?(t.Q=+r[0],n+r[0].length):-1}function Iw(t,e,n){var r=hw.exec(e.slice(n));return r?(t.s=+r[0],n+r[0].length):-1}function Fw(t,e){return pw(t.getDate(),e,2)}function Pw(t,e){return pw(t.getHours(),e,2)}function Yw(t,e){return pw(t.getHours()%12||12,e,2)}function zw(t,e){return pw(1+l_.count(O_(t),t),e,3)}function Uw(t,e){return pw(t.getMilliseconds(),e,3)}function $w(t,e){return Uw(t,e)+"000"}function Ww(t,e){return pw(t.getMonth()+1,e,2)}function qw(t,e){return pw(t.getMinutes(),e,2)}function Hw(t,e){return pw(t.getSeconds(),e,2)}function Vw(t){var e=t.getDay();return 0===e?7:e}function Gw(t,e){return pw(d_.count(O_(t)-1,t),e,2)}function Xw(t){var e=t.getDay();return e>=4||0===e?y_(t):y_.ceil(t)}function Zw(t,e){return t=Xw(t),pw(y_.count(O_(t),t)+(4===O_(t).getDay()),e,2)}function Qw(t){return t.getDay()}function Kw(t,e){return pw(f_.count(O_(t)-1,t),e,2)}function Jw(t,e){return pw(t.getFullYear()%100,e,2)}function tx(t,e){return pw((t=Xw(t)).getFullYear()%100,e,2)}function ex(t,e){return pw(t.getFullYear()%1e4,e,4)}function nx(t,e){var n=t.getDay();return pw((t=n>=4||0===n?y_(t):y_.ceil(t)).getFullYear()%1e4,e,4)}function rx(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+pw(e/60|0,"0",2)+pw(e%60,"0",2)}function ix(t,e){return pw(t.getUTCDate(),e,2)}function ax(t,e){return pw(t.getUTCHours(),e,2)}function ox(t,e){return pw(t.getUTCHours()%12||12,e,2)}function sx(t,e){return pw(1+B_.count(J_(t),t),e,3)}function cx(t,e){return pw(t.getUTCMilliseconds(),e,3)}function lx(t,e){return cx(t,e)+"000"}function ux(t,e){return pw(t.getUTCMonth()+1,e,2)}function hx(t,e){return pw(t.getUTCMinutes(),e,2)}function dx(t,e){return pw(t.getUTCSeconds(),e,2)}function fx(t){var e=t.getUTCDay();return 0===e?7:e}function px(t,e){return pw(I_.count(J_(t)-1,t),e,2)}function gx(t){var e=t.getUTCDay();return e>=4||0===e?z_(t):z_.ceil(t)}function yx(t,e){return t=gx(t),pw(z_.count(J_(t),t)+(4===J_(t).getUTCDay()),e,2)}function mx(t){return t.getUTCDay()}function vx(t,e){return pw(F_.count(J_(t)-1,t),e,2)}function bx(t,e){return pw(t.getUTCFullYear()%100,e,2)}function _x(t,e){return pw((t=gx(t)).getUTCFullYear()%100,e,2)}function wx(t,e){return pw(t.getUTCFullYear()%1e4,e,4)}function xx(t,e){var n=t.getUTCDay();return pw((t=n>=4||0===n?z_(t):z_.ceil(t)).getUTCFullYear()%1e4,e,4)}function kx(){return"+0000"}function Cx(){return"%"}function Tx(t){return+t}function Ex(t){return Math.floor(+t/1e3)}function Sx(t){return aw=iw(t),ow=aw.format,sw=aw.parse,cw=aw.utcFormat,lw=aw.utcParse,aw}Sx({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});var Ox=Date.prototype.toISOString?function(t){return t.toISOString()}:cw("%Y-%m-%dT%H:%M:%S.%LZ");var Ax=+new Date("2000-01-01T00:00:00.000Z")?function(t){var e=new Date(t);return isNaN(e)?null:e}:lw("%Y-%m-%dT%H:%M:%S.%LZ");function Mx(t){return new Date(t)}function Dx(t){return t instanceof Date?+t:+new Date(+t)}function jx(t,e,n,r,i,a,o,s,c){var l=Nb(Eb,Eb),u=l.invert,h=l.domain,d=c(".%L"),f=c(":%S"),p=c("%I:%M"),g=c("%I %p"),y=c("%a %d"),m=c("%b %d"),v=c("%B"),b=c("%Y"),_=[[o,1,1e3],[o,5,5e3],[o,15,15e3],[o,30,3e4],[a,1,6e4],[a,5,3e5],[a,15,9e5],[a,30,18e5],[i,1,36e5],[i,3,108e5],[i,6,216e5],[i,12,432e5],[r,1,864e5],[r,2,1728e5],[n,1,6048e5],[e,1,2592e6],[e,3,7776e6],[t,1,31536e6]];function w(s){return(o(s)1?0:t<-1?yC:Math.acos(t)}function _C(t){return t>=1?mC:t<=-1?-mC:Math.asin(t)}function wC(t){return t.innerRadius}function xC(t){return t.outerRadius}function kC(t){return t.startAngle}function CC(t){return t.endAngle}function TC(t){return t&&t.padAngle}function EC(t,e,n,r,i,a,o,s){var c=n-t,l=r-e,u=o-i,h=s-a,d=h*c-u*l;if(!(d*d<1e-12))return[t+(d=(u*(e-a)-h*(t-i))/d)*c,e+d*l]}function SC(t,e,n,r,i,a,o){var s=t-n,c=e-r,l=(o?a:-a)/gC(s*s+c*c),u=l*c,h=-l*s,d=t+u,f=e+h,p=n+u,g=r+h,y=(d+p)/2,m=(f+g)/2,v=p-d,b=g-f,_=v*v+b*b,w=i-a,x=d*g-p*f,k=(b<0?-1:1)*gC(dC(0,w*w*_-x*x)),C=(x*b-v*k)/_,T=(-x*v-b*k)/_,E=(x*b+v*k)/_,S=(-x*v+b*k)/_,O=C-y,A=T-m,M=E-y,D=S-m;return O*O+A*A>M*M+D*D&&(C=E,T=S),{cx:C,cy:T,x01:-u,y01:-h,x11:C*(i/w-1),y11:T*(i/w-1)}}function OC(t){this._context=t}function AC(t){return new OC(t)}function MC(t){return t[0]}function DC(t){return t[1]}function jC(){var t=MC,e=DC,n=cC(!0),r=null,i=AC,a=null;function o(o){var s,c,l,u=o.length,h=!1;for(null==r&&(a=i(l=Zh())),s=0;s<=u;++s)!(s=u;--h)s.point(y[h],m[h]);s.lineEnd(),s.areaEnd()}g&&(y[l]=+t(d,l,c),m[l]=+n(d,l,c),s.point(e?+e(d,l,c):y[l],r?+r(d,l,c):m[l]))}if(f)return s=null,f+""||null}function l(){return jC().defined(i).curve(o).context(a)}return c.x=function(n){return arguments.length?(t="function"==typeof n?n:cC(+n),e=null,c):t},c.x0=function(e){return arguments.length?(t="function"==typeof e?e:cC(+e),c):t},c.x1=function(t){return arguments.length?(e=null==t?null:"function"==typeof t?t:cC(+t),c):e},c.y=function(t){return arguments.length?(n="function"==typeof t?t:cC(+t),r=null,c):n},c.y0=function(t){return arguments.length?(n="function"==typeof t?t:cC(+t),c):n},c.y1=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:cC(+t),c):r},c.lineX0=c.lineY0=function(){return l().x(t).y(n)},c.lineY1=function(){return l().x(t).y(r)},c.lineX1=function(){return l().x(e).y(n)},c.defined=function(t){return arguments.length?(i="function"==typeof t?t:cC(!!t),c):i},c.curve=function(t){return arguments.length?(o=t,null!=a&&(s=o(a)),c):o},c.context=function(t){return arguments.length?(null==t?a=s=null:s=o(a=t),c):a},c}function BC(t,e){return et?1:e>=t?0:NaN}function LC(t){return t}OC.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e)}}};var RC=FC(AC);function IC(t){this._curve=t}function FC(t){function e(e){return new IC(t(e))}return e._curve=t,e}function PC(t){var e=t.curve;return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t.curve=function(t){return arguments.length?e(FC(t)):e()._curve},t}function YC(){return PC(jC().curve(RC))}function zC(){var t=NC().curve(RC),e=t.curve,n=t.lineX0,r=t.lineX1,i=t.lineY0,a=t.lineY1;return t.angle=t.x,delete t.x,t.startAngle=t.x0,delete t.x0,t.endAngle=t.x1,delete t.x1,t.radius=t.y,delete t.y,t.innerRadius=t.y0,delete t.y0,t.outerRadius=t.y1,delete t.y1,t.lineStartAngle=function(){return PC(n())},delete t.lineX0,t.lineEndAngle=function(){return PC(r())},delete t.lineX1,t.lineInnerRadius=function(){return PC(i())},delete t.lineY0,t.lineOuterRadius=function(){return PC(a())},delete t.lineY1,t.curve=function(t){return arguments.length?e(FC(t)):e()._curve},t}function UC(t,e){return[(e=+e)*Math.cos(t-=Math.PI/2),e*Math.sin(t)]}IC.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(t,e){this._curve.point(e*Math.sin(t),e*-Math.cos(t))}};var $C=Array.prototype.slice;function WC(t){return t.source}function qC(t){return t.target}function HC(t){var e=WC,n=qC,r=MC,i=DC,a=null;function o(){var o,s=$C.call(arguments),c=e.apply(this,s),l=n.apply(this,s);if(a||(a=o=Zh()),t(a,+r.apply(this,(s[0]=c,s)),+i.apply(this,s),+r.apply(this,(s[0]=l,s)),+i.apply(this,s)),o)return a=null,o+""||null}return o.source=function(t){return arguments.length?(e=t,o):e},o.target=function(t){return arguments.length?(n=t,o):n},o.x=function(t){return arguments.length?(r="function"==typeof t?t:cC(+t),o):r},o.y=function(t){return arguments.length?(i="function"==typeof t?t:cC(+t),o):i},o.context=function(t){return arguments.length?(a=null==t?null:t,o):a},o}function VC(t,e,n,r,i){t.moveTo(e,n),t.bezierCurveTo(e=(e+r)/2,n,e,i,r,i)}function GC(t,e,n,r,i){t.moveTo(e,n),t.bezierCurveTo(e,n=(n+i)/2,r,n,r,i)}function XC(t,e,n,r,i){var a=UC(e,n),o=UC(e,n=(n+i)/2),s=UC(r,n),c=UC(r,i);t.moveTo(a[0],a[1]),t.bezierCurveTo(o[0],o[1],s[0],s[1],c[0],c[1])}var ZC={draw:function(t,e){var n=Math.sqrt(e/yC);t.moveTo(n,0),t.arc(0,0,n,0,vC)}},QC={draw:function(t,e){var n=Math.sqrt(e/5)/2;t.moveTo(-3*n,-n),t.lineTo(-n,-n),t.lineTo(-n,-3*n),t.lineTo(n,-3*n),t.lineTo(n,-n),t.lineTo(3*n,-n),t.lineTo(3*n,n),t.lineTo(n,n),t.lineTo(n,3*n),t.lineTo(-n,3*n),t.lineTo(-n,n),t.lineTo(-3*n,n),t.closePath()}},KC=Math.sqrt(1/3),JC=2*KC,tT={draw:function(t,e){var n=Math.sqrt(e/JC),r=n*KC;t.moveTo(0,-n),t.lineTo(r,0),t.lineTo(0,n),t.lineTo(-r,0),t.closePath()}},eT=Math.sin(yC/10)/Math.sin(7*yC/10),nT=Math.sin(vC/10)*eT,rT=-Math.cos(vC/10)*eT,iT={draw:function(t,e){var n=Math.sqrt(.8908130915292852*e),r=nT*n,i=rT*n;t.moveTo(0,-n),t.lineTo(r,i);for(var a=1;a<5;++a){var o=vC*a/5,s=Math.cos(o),c=Math.sin(o);t.lineTo(c*n,-s*n),t.lineTo(s*r-c*i,c*r+s*i)}t.closePath()}},aT={draw:function(t,e){var n=Math.sqrt(e),r=-n/2;t.rect(r,r,n,n)}},oT=Math.sqrt(3),sT={draw:function(t,e){var n=-Math.sqrt(e/(3*oT));t.moveTo(0,2*n),t.lineTo(-oT*n,-n),t.lineTo(oT*n,-n),t.closePath()}},cT=-.5,lT=Math.sqrt(3)/2,uT=1/Math.sqrt(12),hT=3*(uT/2+1),dT={draw:function(t,e){var n=Math.sqrt(e/hT),r=n/2,i=n*uT,a=r,o=n*uT+n,s=-a,c=o;t.moveTo(r,i),t.lineTo(a,o),t.lineTo(s,c),t.lineTo(cT*r-lT*i,lT*r+cT*i),t.lineTo(cT*a-lT*o,lT*a+cT*o),t.lineTo(cT*s-lT*c,lT*s+cT*c),t.lineTo(cT*r+lT*i,cT*i-lT*r),t.lineTo(cT*a+lT*o,cT*o-lT*a),t.lineTo(cT*s+lT*c,cT*c-lT*s),t.closePath()}},fT=[ZC,QC,tT,aT,iT,sT,dT];function pT(){}function gT(t,e,n){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+n)/6)}function yT(t){this._context=t}function mT(t){this._context=t}function vT(t){this._context=t}function bT(t,e){this._basis=new yT(t),this._beta=e}yT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:gT(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:gT(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},mT.prototype={areaStart:pT,areaEnd:pT,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:gT(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},vT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+t)/6,r=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:gT(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},bT.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,n=t.length-1;if(n>0)for(var r,i=t[0],a=e[0],o=t[n]-i,s=e[n]-a,c=-1;++c<=n;)r=c/n,this._basis.point(this._beta*t[c]+(1-this._beta)*(i+r*o),this._beta*e[c]+(1-this._beta)*(a+r*s));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};var _T=function t(e){function n(t){return 1===e?new yT(t):new bT(t,e)}return n.beta=function(e){return t(+e)},n}(.85);function wT(t,e,n){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-n),t._x2,t._y2)}function xT(t,e){this._context=t,this._k=(1-e)/6}xT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:wT(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:wT(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var kT=function t(e){function n(t){return new xT(t,e)}return n.tension=function(e){return t(+e)},n}(0);function CT(t,e){this._context=t,this._k=(1-e)/6}CT.prototype={areaStart:pT,areaEnd:pT,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:wT(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var TT=function t(e){function n(t){return new CT(t,e)}return n.tension=function(e){return t(+e)},n}(0);function ET(t,e){this._context=t,this._k=(1-e)/6}ET.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:wT(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var ST=function t(e){function n(t){return new ET(t,e)}return n.tension=function(e){return t(+e)},n}(0);function OT(t,e,n){var r=t._x1,i=t._y1,a=t._x2,o=t._y2;if(t._l01_a>1e-12){var s=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,c=3*t._l01_a*(t._l01_a+t._l12_a);r=(r*s-t._x0*t._l12_2a+t._x2*t._l01_2a)/c,i=(i*s-t._y0*t._l12_2a+t._y2*t._l01_2a)/c}if(t._l23_a>1e-12){var l=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,u=3*t._l23_a*(t._l23_a+t._l12_a);a=(a*l+t._x1*t._l23_2a-e*t._l12_2a)/u,o=(o*l+t._y1*t._l23_2a-n*t._l12_2a)/u}t._context.bezierCurveTo(r,i,a,o,t._x2,t._y2)}function AT(t,e){this._context=t,this._alpha=e}AT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:OT(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var MT=function t(e){function n(t){return e?new AT(t,e):new xT(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function DT(t,e){this._context=t,this._alpha=e}DT.prototype={areaStart:pT,areaEnd:pT,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:OT(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var jT=function t(e){function n(t){return e?new DT(t,e):new CT(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function NT(t,e){this._context=t,this._alpha=e}NT.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:OT(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var BT=function t(e){function n(t){return e?new NT(t,e):new ET(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function LT(t){this._context=t}function RT(t){return t<0?-1:1}function IT(t,e,n){var r=t._x1-t._x0,i=e-t._x1,a=(t._y1-t._y0)/(r||i<0&&-0),o=(n-t._y1)/(i||r<0&&-0),s=(a*i+o*r)/(r+i);return(RT(a)+RT(o))*Math.min(Math.abs(a),Math.abs(o),.5*Math.abs(s))||0}function FT(t,e){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-e)/2:e}function PT(t,e,n){var r=t._x0,i=t._y0,a=t._x1,o=t._y1,s=(a-r)/3;t._context.bezierCurveTo(r+s,i+s*e,a-s,o-s*n,a,o)}function YT(t){this._context=t}function zT(t){this._context=new UT(t)}function UT(t){this._context=t}function $T(t){this._context=t}function WT(t){var e,n,r=t.length-1,i=new Array(r),a=new Array(r),o=new Array(r);for(i[0]=0,a[0]=2,o[0]=t[0]+2*t[1],e=1;e=0;--e)i[e]=(o[e]-i[e+1])/a[e];for(a[r-1]=(t[r]+i[r-1])/2,e=0;e1)for(var n,r,i,a=1,o=t[e[0]],s=o.length;a=0;)n[e]=e;return n}function GT(t,e){return t[e]}function XT(t){var e=t.map(ZT);return VT(t).sort((function(t,n){return e[t]-e[n]}))}function ZT(t){for(var e,n=-1,r=0,i=t.length,a=-1/0;++na&&(a=e,r=n);return r}function QT(t){var e=t.map(KT);return VT(t).sort((function(t,n){return e[t]-e[n]}))}function KT(t){for(var e,n=0,r=-1,i=t.length;++r0)){if(a/=d,d<0){if(a0){if(a>h)return;a>u&&(u=a)}if(a=r-c,d||!(a<0)){if(a/=d,d<0){if(a>h)return;a>u&&(u=a)}else if(d>0){if(a0)){if(a/=f,f<0){if(a0){if(a>h)return;a>u&&(u=a)}if(a=i-l,f||!(a<0)){if(a/=f,f<0){if(a>h)return;a>u&&(u=a)}else if(f>0){if(a0||h<1)||(u>0&&(t[0]=[c+u*d,l+u*f]),h<1&&(t[1]=[c+h*d,l+h*f]),!0)}}}}}function hE(t,e,n,r,i){var a=t[1];if(a)return!0;var o,s,c=t[0],l=t.left,u=t.right,h=l[0],d=l[1],f=u[0],p=u[1],g=(h+f)/2,y=(d+p)/2;if(p===d){if(g=r)return;if(h>f){if(c){if(c[1]>=i)return}else c=[g,n];a=[g,i]}else{if(c){if(c[1]1)if(h>f){if(c){if(c[1]>=i)return}else c=[(n-s)/o,n];a=[(i-s)/o,i]}else{if(c){if(c[1]=r)return}else c=[e,o*e+s];a=[r,o*r+s]}else{if(c){if(c[0]=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var n=this._x*(1-this._t)+t*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,e)}}this._x=t,this._y=e}},nE.prototype={constructor:nE,insert:function(t,e){var n,r,i;if(t){if(e.P=t,e.N=t.N,t.N&&(t.N.P=e),t.N=e,t.R){for(t=t.R;t.L;)t=t.L;t.L=e}else t.R=e;n=t}else this._?(t=oE(this._),e.P=null,e.N=t,t.P=t.L=e,n=t):(e.P=e.N=null,this._=e,n=null);for(e.L=e.R=null,e.U=n,e.C=!0,t=e;n&&n.C;)n===(r=n.U).L?(i=r.R)&&i.C?(n.C=i.C=!1,r.C=!0,t=r):(t===n.R&&(iE(this,n),n=(t=n).U),n.C=!1,r.C=!0,aE(this,r)):(i=r.L)&&i.C?(n.C=i.C=!1,r.C=!0,t=r):(t===n.L&&(aE(this,n),n=(t=n).U),n.C=!1,r.C=!0,iE(this,r)),n=t.U;this._.C=!1},remove:function(t){t.N&&(t.N.P=t.P),t.P&&(t.P.N=t.N),t.N=t.P=null;var e,n,r,i=t.U,a=t.L,o=t.R;if(n=a?o?oE(o):a:o,i?i.L===t?i.L=n:i.R=n:this._=n,a&&o?(r=n.C,n.C=t.C,n.L=a,a.U=n,n!==o?(i=n.U,n.U=t.U,t=n.R,i.L=t,n.R=o,o.U=n):(n.U=i,i=n,t=n.R)):(r=t.C,t=n),t&&(t.U=i),!r)if(t&&t.C)t.C=!1;else{do{if(t===this._)break;if(t===i.L){if((e=i.R).C&&(e.C=!1,i.C=!0,iE(this,i),e=i.R),e.L&&e.L.C||e.R&&e.R.C){e.R&&e.R.C||(e.L.C=!1,e.C=!0,aE(this,e),e=i.R),e.C=i.C,i.C=e.R.C=!1,iE(this,i),t=this._;break}}else if((e=i.L).C&&(e.C=!1,i.C=!0,aE(this,i),e=i.L),e.L&&e.L.C||e.R&&e.R.C){e.L&&e.L.C||(e.R.C=!1,e.C=!0,iE(this,e),e=i.L),e.C=i.C,i.C=e.L.C=!1,aE(this,i),t=this._;break}e.C=!0,t=i,i=i.U}while(!t.C);t&&(t.C=!1)}}};var gE,yE=[];function mE(){rE(this),this.x=this.y=this.arc=this.site=this.cy=null}function vE(t){var e=t.P,n=t.N;if(e&&n){var r=e.site,i=t.site,a=n.site;if(r!==a){var o=i[0],s=i[1],c=r[0]-o,l=r[1]-s,u=a[0]-o,h=a[1]-s,d=2*(c*h-l*u);if(!(d>=-NE)){var f=c*c+l*l,p=u*u+h*h,g=(h*f-l*p)/d,y=(c*p-u*f)/d,m=yE.pop()||new mE;m.arc=t,m.site=i,m.x=g+o,m.y=(m.cy=y+s)+Math.sqrt(g*g+y*y),t.circle=m;for(var v=null,b=ME._;b;)if(m.yjE)s=s.L;else{if(!((i=a-SE(s,o))>jE)){r>-jE?(e=s.P,n=s):i>-jE?(e=s,n=s.N):e=n=s;break}if(!s.R){e=s;break}s=s.R}!function(t){AE[t.index]={site:t,halfedges:[]}}(t);var c=xE(t);if(OE.insert(e,c),e||n){if(e===n)return bE(e),n=xE(e.site),OE.insert(c,n),c.edge=n.edge=sE(e.site,c.site),vE(e),void vE(n);if(n){bE(e),bE(n);var l=e.site,u=l[0],h=l[1],d=t[0]-u,f=t[1]-h,p=n.site,g=p[0]-u,y=p[1]-h,m=2*(d*y-f*g),v=d*d+f*f,b=g*g+y*y,_=[(y*v-f*b)/m+u,(d*b-g*v)/m+h];lE(n.edge,l,p,_),c.edge=sE(l,t,null,_),n.edge=sE(t,p,null,_),vE(e),vE(n)}else c.edge=sE(e.site,c.site)}}function EE(t,e){var n=t.site,r=n[0],i=n[1],a=i-e;if(!a)return r;var o=t.P;if(!o)return-1/0;var s=(n=o.site)[0],c=n[1],l=c-e;if(!l)return s;var u=s-r,h=1/a-1/l,d=u/l;return h?(-d+Math.sqrt(d*d-2*h*(u*u/(-2*l)-c+l/2+i-a/2)))/h+r:(r+s)/2}function SE(t,e){var n=t.N;if(n)return EE(n,e);var r=t.site;return r[1]===e?r[0]:1/0}var OE,AE,ME,DE,jE=1e-6,NE=1e-12;function BE(t,e){return e[1]-t[1]||e[0]-t[0]}function LE(t,e){var n,r,i,a=t.sort(BE).pop();for(DE=[],AE=new Array(t.length),OE=new nE,ME=new nE;;)if(i=gE,a&&(!i||a[1]jE||Math.abs(i[0][1]-i[1][1])>jE)||delete DE[a]}(o,s,c,l),function(t,e,n,r){var i,a,o,s,c,l,u,h,d,f,p,g,y=AE.length,m=!0;for(i=0;ijE||Math.abs(g-d)>jE)&&(c.splice(s,0,DE.push(cE(o,f,Math.abs(p-t)jE?[t,Math.abs(h-t)jE?[Math.abs(d-r)jE?[n,Math.abs(h-n)jE?[Math.abs(d-e)=s)return null;var c=t-i.site[0],l=e-i.site[1],u=c*c+l*l;do{i=a.cells[r=o],o=null,i.halfedges.forEach((function(n){var r=a.edges[n],s=r.left;if(s!==i.site&&s||(s=r.right)){var c=t-s[0],l=e-s[1],h=c*c+l*l;hr?(r+i)/2:Math.min(0,r)||Math.max(0,i),o>a?(a+o)/2:Math.min(0,a)||Math.max(0,o))}YE.prototype=FE.prototype;var XE=ma(Object.freeze({__proto__:null,[Symbol.toStringTag]:"Module",version:"5.16.0",bisect:Oa,bisectRight:Oa,bisectLeft:Aa,ascending:Ta,bisector:Ea,cross:function(t,e,n){var r,i,a,o,s=t.length,c=e.length,l=new Array(s*c);for(null==n&&(n=Ma),r=a=0;rt?1:e>=t?0:NaN},deviation:Na,extent:Ba,histogram:function(){var t=Pa,e=Ba,n=Va;function r(r){var i,a,o=r.length,s=new Array(o);for(i=0;iu;)h.pop(),--d;var f,p=new Array(d+1);for(i=0;i<=d;++i)(f=p[i]=[]).x0=i>0?h[i-1]:l,f.x1=i=r.length)return null!=t&&n.sort(t),null!=e?e(n):n;for(var c,l,u,h=-1,d=n.length,f=r[i++],p=rd(),g=o();++hr.length)return t;var a,s=i[n-1];return null!=e&&n>=r.length?a=t.entries():(a=[],t.each((function(t,e){a.push({key:e,values:o(t,n)})}))),null!=s?a.sort((function(t,e){return s(t.key,e.key)})):a}return n={object:function(t){return a(t,0,id,ad)},map:function(t){return a(t,0,od,sd)},entries:function(t){return o(a(t,0,od,sd),0)},key:function(t){return r.push(t),n},sortKeys:function(t){return i[r.length-1]=t,n},sortValues:function(e){return t=e,n},rollup:function(t){return e=t,n}}},set:ud,map:rd,keys:function(t){var e=[];for(var n in t)e.push(n);return e},values:function(t){var e=[];for(var n in t)e.push(t[n]);return e},entries:function(t){var e=[];for(var n in t)e.push({key:n,value:t[n]});return e},color:oc,rgb:uc,hsl:mc,lab:Ec,hcl:Nc,lch:function(t,e,n,r){return 1===arguments.length?jc(t):new Bc(n,e,t,null==r?1:r)},gray:function(t,e){return new Sc(t,0,0,null==e?1:e)},cubehelix:qc,contours:bd,contourDensity:function(){var t=xd,e=kd,n=Cd,r=960,i=500,a=20,o=2,s=3*a,c=r+2*s>>o,l=i+2*s>>o,u=fd(20);function h(r){var i=new Float32Array(c*l),h=new Float32Array(c*l);r.forEach((function(r,a,u){var h=+t(r,a,u)+s>>o,d=+e(r,a,u)+s>>o,f=+n(r,a,u);h>=0&&h=0&&d>o),wd({width:c,height:l,data:h},{width:c,height:l,data:i},a>>o),_d({width:c,height:l,data:i},{width:c,height:l,data:h},a>>o),wd({width:c,height:l,data:h},{width:c,height:l,data:i},a>>o),_d({width:c,height:l,data:i},{width:c,height:l,data:h},a>>o),wd({width:c,height:l,data:h},{width:c,height:l,data:i},a>>o);var f=u(i);if(!Array.isArray(f)){var p=Xa(i);f=Ha(0,p,f),(f=Ya(0,Math.floor(p/f)*f,f)).shift()}return bd().thresholds(f).size([c,l])(i).map(d)}function d(t){return t.value*=Math.pow(2,-2*o),t.coordinates.forEach(f),t}function f(t){t.forEach(p)}function p(t){t.forEach(g)}function g(t){t[0]=t[0]*Math.pow(2,o)-s,t[1]=t[1]*Math.pow(2,o)-s}function y(){return c=r+2*(s=3*a)>>o,l=i+2*s>>o,h}return h.x=function(e){return arguments.length?(t="function"==typeof e?e:fd(+e),h):t},h.y=function(t){return arguments.length?(e="function"==typeof t?t:fd(+t),h):e},h.weight=function(t){return arguments.length?(n="function"==typeof t?t:fd(+t),h):n},h.size=function(t){if(!arguments.length)return[r,i];var e=Math.ceil(t[0]),n=Math.ceil(t[1]);if(!(e>=0||e>=0))throw new Error("invalid size");return r=e,i=n,y()},h.cellSize=function(t){if(!arguments.length)return 1<=1))throw new Error("invalid cell size");return o=Math.floor(Math.log(t)/Math.LN2),y()},h.thresholds=function(t){return arguments.length?(u="function"==typeof t?t:Array.isArray(t)?fd(hd.call(t)):fd(t),h):u},h.bandwidth=function(t){if(!arguments.length)return Math.sqrt(a*(a+1));if(!((t=+t)>=0))throw new Error("invalid bandwidth");return a=Math.round((Math.sqrt(4*t*t+1)-1)/2),y()},h},dispatch:lo,drag:function(){var t,e,n,r,i=Ps,a=Ys,o=zs,s=Us,c={},l=lo("start","drag","end"),u=0,h=0;function d(t){t.on("mousedown.drag",f).filter(s).on("touchstart.drag",y).on("touchmove.drag",m).on("touchend.drag touchcancel.drag",v).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function f(){if(!r&&i.apply(this,arguments)){var o=b("mouse",a.apply(this,arguments),Ds,this,arguments);o&&(Ts(ds.view).on("mousemove.drag",p,!0).on("mouseup.drag",g,!0),Ls(ds.view),Ns(),n=!1,t=ds.clientX,e=ds.clientY,o("start"))}}function p(){if(Bs(),!n){var r=ds.clientX-t,i=ds.clientY-e;n=r*r+i*i>h}c.mouse("drag")}function g(){Ts(ds.view).on("mousemove.drag mouseup.drag",null),Rs(ds.view,n),Bs(),c.mouse("end")}function y(){if(i.apply(this,arguments)){var t,e,n=ds.changedTouches,r=a.apply(this,arguments),o=n.length;for(t=0;tc+f||il+f||as.index){var p=c-o.x-o.vx,g=l-o.y-o.vy,y=p*p+g*g;yt.r&&(t.r=t[e].r)}function s(){if(e){var r,i,a=e.length;for(n=new Array(a),r=0;r=o)){(t.data!==e||t.next)&&(0===u&&(f+=(u=lf())*u),0===h&&(f+=(h=lf())*h),f1?(null==n?s.remove(t):s.set(t,f(n)),e):s.get(t)},find:function(e,n,r){var i,a,o,s,c,l=0,u=t.length;for(null==r?r=1/0:r*=r,l=0;l1?(l.on(t,n),e):l.on(t)}}},forceX:function(t){var e,n,r,i=cf(.1);function a(t){for(var i,a=0,o=e.length;axg(r[0],r[1])&&(r[1]=i[1]),xg(i[0],r[1])>xg(r[0],r[1])&&(r[0]=i[0])):a.push(r=i);for(o=-1/0,e=0,r=a[n=a.length-1];e<=n;r=i,++e)i=a[e],(s=xg(r[1],i[0]))>o&&(o=s,zp=i[0],$p=r[1])}return Xp=Zp=null,zp===1/0||Up===1/0?[[NaN,NaN],[NaN,NaN]]:[[zp,Up],[$p,Wp]]},geoCentroid:function(t){Qp=Kp=Jp=tg=eg=ng=rg=ig=ag=og=sg=0,wp(t,Tg);var e=ag,n=og,r=sg,i=e*e+n*n+r*r;return i<1e-12&&(e=ng,n=rg,r=ig,Kp<1e-6&&(e=Jp,n=tg,r=eg),(i=e*e+n*n+r*r)<1e-12)?[NaN,NaN]:[np(n,e)*Kf,fp(r/up(i))*Kf]},geoCircle:function(){var t,e,n=Rg([0,0]),r=Rg(90),i=Rg(6),a={point:function(n,r){t.push(n=e(n,r)),n[0]*=Kf,n[1]*=Kf}};function o(){var o=n.apply(this,arguments),s=r.apply(this,arguments)*Jf,c=i.apply(this,arguments)*Jf;return t=[],e=Pg(-o[0]*Jf,-o[1]*Jf,0).invert,Wg(a,s,c,1),o={type:"Polygon",coordinates:[t]},t=e=null,o}return o.center=function(t){return arguments.length?(n="function"==typeof t?t:Rg([+t[0],+t[1]]),o):n},o.radius=function(t){return arguments.length?(r="function"==typeof t?t:Rg(+t),o):r},o.precision=function(t){return arguments.length?(i="function"==typeof t?t:Rg(+t),o):i},o},geoClipAntimeridian:ry,geoClipCircle:iy,geoClipExtent:function(){var t,e,n,r=0,i=0,a=960,o=500;return n={stream:function(n){return t&&e===n?t:t=ay(r,i,a,o)(e=n)},extent:function(s){return arguments.length?(r=+s[0][0],i=+s[0][1],a=+s[1][0],o=+s[1][1],t=e=null,n):[[r,i],[a,o]]}}},geoClipRectangle:ay,geoContains:function(t,e){return(t&&vy.hasOwnProperty(t.type)?vy[t.type]:_y)(t,e)},geoDistance:my,geoGraticule:Oy,geoGraticule10:function(){return Oy()()},geoInterpolate:function(t,e){var n=t[0]*Jf,r=t[1]*Jf,i=e[0]*Jf,a=e[1]*Jf,o=rp(r),s=cp(r),c=rp(a),l=cp(a),u=o*rp(n),h=o*cp(n),d=c*rp(i),f=c*cp(i),p=2*fp(up(pp(a-r)+o*c*pp(i-n))),g=cp(p),y=p?function(t){var e=cp(t*=p)/g,n=cp(p-t)/g,r=n*u+e*d,i=n*h+e*f,a=n*s+e*l;return[np(i,r)*Kf,np(a,up(r*r+i*i))*Kf]}:function(){return[n*Kf,r*Kf]};return y.distance=p,y},geoLength:py,geoPath:function(t,e){var n,r,i=4.5;function a(t){return t&&("function"==typeof i&&r.pointRadius(+i.apply(this,arguments)),wp(t,n(r))),r.result()}return a.area=function(t){return wp(t,n(Ry)),Ry.result()},a.measure=function(t){return wp(t,n(xm)),xm.result()},a.bounds=function(t){return wp(t,n(qy)),qy.result()},a.centroid=function(t){return wp(t,n(am)),am.result()},a.projection=function(e){return arguments.length?(n=null==e?(t=null,Ay):(t=e).stream,a):t},a.context=function(t){return arguments.length?(r=null==t?(e=null,new Tm):new gm(e=t),"function"!=typeof i&&r.pointRadius(i),a):e},a.pointRadius=function(t){return arguments.length?(i="function"==typeof t?t:(r.pointRadius(+t),+t),a):i},a.projection(t).context(e)},geoAlbers:Wm,geoAlbersUsa:function(){var t,e,n,r,i,a,o=Wm(),s=$m().rotate([154,0]).center([-2,58.5]).parallels([55,65]),c=$m().rotate([157,0]).center([-3,19.9]).parallels([8,18]),l={point:function(t,e){a=[t,e]}};function u(t){var e=t[0],o=t[1];return a=null,n.point(e,o),a||(r.point(e,o),a)||(i.point(e,o),a)}function h(){return t=e=null,u}return u.invert=function(t){var e=o.scale(),n=o.translate(),r=(t[0]-n[0])/e,i=(t[1]-n[1])/e;return(i>=.12&&i<.234&&r>=-.425&&r<-.214?s:i>=.166&&i<.234&&r>=-.214&&r<-.115?c:o).invert(t)},u.stream=function(n){return t&&e===n?t:(r=[o.stream(e=n),s.stream(n),c.stream(n)],i=r.length,t={point:function(t,e){for(var n=-1;++n2?t[2]+90:90]):[(t=n())[0],t[1],t[2]-90]},n([0,0,90]).scale(159.155)},geoTransverseMercatorRaw:hv,geoRotation:$g,geoStream:wp,geoTransform:function(t){return{stream:Sm(t)}},cluster:function(){var t=dv,e=1,n=1,r=!1;function i(i){var a,o=0;i.eachAfter((function(e){var n=e.children;n?(e.x=function(t){return t.reduce(fv,0)/t.length}(n),e.y=function(t){return 1+t.reduce(pv,0)}(n)):(e.x=a?o+=t(e,a):0,e.y=0,a=e)}));var s=function(t){for(var e;e=t.children;)t=e[0];return t}(i),c=function(t){for(var e;e=t.children;)t=e[e.length-1];return t}(i),l=s.x-t(s,c)/2,u=c.x+t(c,s)/2;return i.eachAfter(r?function(t){t.x=(t.x-i.x)*e,t.y=(i.y-t.y)*n}:function(t){t.x=(t.x-l)/(u-l)*e,t.y=(1-(i.y?t.y/i.y:1))*n})}return i.separation=function(e){return arguments.length?(t=e,i):t},i.size=function(t){return arguments.length?(r=!1,e=+t[0],n=+t[1],i):r?null:[e,n]},i.nodeSize=function(t){return arguments.length?(r=!0,e=+t[0],n=+t[1],i):r?[e,n]:null},i},hierarchy:yv,pack:function(){var t=null,e=1,n=1,r=Iv;function i(i){return i.x=e/2,i.y=n/2,t?i.eachBefore(Yv(t)).eachAfter(zv(r,.5)).eachBefore(Uv(1)):i.eachBefore(Yv(Pv)).eachAfter(zv(Iv,1)).eachAfter(zv(r,i.r/Math.min(e,n))).eachBefore(Uv(Math.min(e,n)/(2*i.r))),i}return i.radius=function(e){return arguments.length?(t=Lv(e),i):t},i.size=function(t){return arguments.length?(e=+t[0],n=+t[1],i):[e,n]},i.padding=function(t){return arguments.length?(r="function"==typeof t?t:Fv(+t),i):r},i},packSiblings:function(t){return Bv(t),t},packEnclose:xv,partition:function(){var t=1,e=1,n=0,r=!1;function i(i){var a=i.height+1;return i.x0=i.y0=n,i.x1=t,i.y1=e/a,i.eachBefore(function(t,e){return function(r){r.children&&Wv(r,r.x0,t*(r.depth+1)/e,r.x1,t*(r.depth+2)/e);var i=r.x0,a=r.y0,o=r.x1-n,s=r.y1-n;o0)throw new Error("cycle");return a}return n.id=function(e){return arguments.length?(t=Rv(e),n):t},n.parentId=function(t){return arguments.length?(e=Rv(t),n):e},n},tree:function(){var t=Xv,e=1,n=1,r=null;function i(i){var c=function(t){for(var e,n,r,i,a,o=new tb(t,0),s=[o];e=s.pop();)if(r=e._.children)for(e.children=new Array(a=r.length),i=a-1;i>=0;--i)s.push(n=e.children[i]=new tb(r[i],i)),n.parent=e;return(o.parent=new tb(null,0)).children=[o],o}(i);if(c.eachAfter(a),c.parent.m=-c.z,c.eachBefore(o),r)i.eachBefore(s);else{var l=i,u=i,h=i;i.eachBefore((function(t){t.xu.x&&(u=t),t.depth>h.depth&&(h=t)}));var d=l===u?1:t(l,u)/2,f=d-l.x,p=e/(u.x+d+f),g=n/(h.depth||1);i.eachBefore((function(t){t.x=(t.x+f)*p,t.y=t.depth*g}))}return i}function a(e){var n=e.children,r=e.parent.children,i=e.i?r[e.i-1]:null;if(n){!function(t){for(var e,n=0,r=0,i=t.children,a=i.length;--a>=0;)(e=i[a]).z+=n,e.m+=n,n+=e.s+(r+=e.c)}(e);var a=(n[0].z+n[n.length-1].z)/2;i?(e.z=i.z+t(e._,i._),e.m=e.z-a):e.z=a}else i&&(e.z=i.z+t(e._,i._));e.parent.A=function(e,n,r){if(n){for(var i,a=e,o=e,s=n,c=a.parent.children[0],l=a.m,u=o.m,h=s.m,d=c.m;s=Qv(s),a=Zv(a),s&&a;)c=Zv(c),(o=Qv(o)).a=e,(i=s.z+h-a.z-l+t(s._,a._))>0&&(Kv(Jv(s,e,r),e,i),l+=i,u+=i),h+=s.m,l+=a.m,d+=c.m,u+=o.m;s&&!Qv(o)&&(o.t=s,o.m+=h-u),a&&!Zv(c)&&(c.t=a,c.m+=l-d,r=e)}return r}(e,i,e.parent.A||r[0])}function o(t){t._.x=t.z+t.parent.m,t.m+=t.parent.m}function s(t){t.x*=e,t.y=t.depth*n}return i.separation=function(e){return arguments.length?(t=e,i):t},i.size=function(t){return arguments.length?(r=!1,e=+t[0],n=+t[1],i):r?null:[e,n]},i.nodeSize=function(t){return arguments.length?(r=!0,e=+t[0],n=+t[1],i):r?[e,n]:null},i},treemap:function(){var t=ib,e=!1,n=1,r=1,i=[0],a=Iv,o=Iv,s=Iv,c=Iv,l=Iv;function u(t){return t.x0=t.y0=0,t.x1=n,t.y1=r,t.eachBefore(h),i=[0],e&&t.eachBefore($v),t}function h(e){var n=i[e.depth],r=e.x0+n,u=e.y0+n,h=e.x1-n,d=e.y1-n;h=n-1){var u=s[e];return u.x0=i,u.y0=a,u.x1=o,void(u.y1=c)}var h=l[e],d=r/2+h,f=e+1,p=n-1;for(;f>>1;l[g]c-a){var v=(i*m+o*y)/r;t(e,f,y,i,a,v,c),t(f,n,m,v,a,o,c)}else{var b=(a*m+c*y)/r;t(e,f,y,i,a,o,b),t(f,n,m,i,b,o,c)}}(0,c,t.value,e,n,r,i)},treemapDice:Wv,treemapSlice:eb,treemapSliceDice:function(t,e,n,r,i){(1&t.depth?eb:Wv)(t,e,n,r,i)},treemapSquarify:ib,treemapResquarify:ab,interpolate:pl,interpolateArray:function(t,e){return(ol(e)?al:sl)(t,e)},interpolateBasis:Gc,interpolateBasisClosed:Xc,interpolateDate:cl,interpolateDiscrete:function(t){var e=t.length;return function(n){return t[Math.max(0,Math.min(e-1,Math.floor(n*e)))]}},interpolateHue:function(t,e){var n=Kc(+t,+e);return function(t){var e=n(t);return e-360*Math.floor(e/360)}},interpolateNumber:ll,interpolateNumberArray:al,interpolateObject:ul,interpolateRound:gl,interpolateString:fl,interpolateTransformCss:Cl,interpolateTransformSvg:Tl,interpolateZoom:Ol,interpolateRgb:el,interpolateRgbBasis:rl,interpolateRgbBasisClosed:il,interpolateHsl:Ml,interpolateHslLong:Dl,interpolateLab:function(t,e){var n=tl((t=Ec(t)).l,(e=Ec(e)).l),r=tl(t.a,e.a),i=tl(t.b,e.b),a=tl(t.opacity,e.opacity);return function(e){return t.l=n(e),t.a=r(e),t.b=i(e),t.opacity=a(e),t+""}},interpolateHcl:Nl,interpolateHclLong:Bl,interpolateCubehelix:Rl,interpolateCubehelixLong:Il,piecewise:function(t,e){for(var n=0,r=e.length-1,i=e[0],a=new Array(r<0?0:r);n=0;--e)l.push(t[r[a[e]][2]]);for(e=+s;es!=l>s&&o<(c-n)*(s-r)/(l-r)+n&&(u=!u),c=n,l=r;return u},polygonLength:function(t){for(var e,n,r=-1,i=t.length,a=t[i-1],o=a[0],s=a[1],c=0;++r0?i[e-1]:n[0],e=i?[a[i-1],r]:[a[e-1],a[e]]},s.unknown=function(t){return arguments.length?(e=t,s):s},s.thresholds=function(){return a.slice()},s.copy=function(){return t().domain([n,r]).range(o).unknown(e)},gb.apply(Lb(s),arguments)},scaleThreshold:function t(){var e,n=[.5],r=[0,1],i=1;function a(t){return t<=t?r[Oa(n,t,0,i)]:e}return a.domain=function(t){return arguments.length?(n=bb.call(t),i=Math.min(n.length,r.length-1),a):n.slice()},a.range=function(t){return arguments.length?(r=bb.call(t),i=Math.min(n.length,r.length-1),a):r.slice()},a.invertExtent=function(t){var e=r.indexOf(t);return[n[e-1],n[e]]},a.unknown=function(t){return arguments.length?(e=t,a):e},a.copy=function(){return t().domain(n).range(r).unknown(e)},gb.apply(a,arguments)},scaleTime:function(){return gb.apply(jx(O_,E_,d_,l_,s_,a_,r_,e_,ow).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)},scaleUtc:function(){return gb.apply(jx(J_,Q_,I_,B_,j_,M_,r_,e_,cw).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)},scaleSequential:function t(){var e=Lb(Nx()(Eb));return e.copy=function(){return Bx(e,t())},yb.apply(e,arguments)},scaleSequentialLog:function t(){var e=$b(Nx()).domain([1,10]);return e.copy=function(){return Bx(e,t()).base(e.base())},yb.apply(e,arguments)},scaleSequentialPow:Lx,scaleSequentialSqrt:function(){return Lx.apply(null,arguments).exponent(.5)},scaleSequentialSymlog:function t(){var e=Hb(Nx());return e.copy=function(){return Bx(e,t()).constant(e.constant())},yb.apply(e,arguments)},scaleSequentialQuantile:function t(){var e=[],n=Eb;function r(t){if(!isNaN(t=+t))return n((Oa(e,t)-1)/(e.length-1))}return r.domain=function(t){if(!arguments.length)return e.slice();e=[];for(var n,i=0,a=t.length;i1)&&(t-=Math.floor(t));var e=Math.abs(t-.5);return Jk.h=360*t-100,Jk.s=1.5-1.5*e,Jk.l=.8-.9*e,Jk+""},interpolateWarm:Qk,interpolateCool:Kk,interpolateSinebow:function(t){var e;return t=(.5-t)*Math.PI,tC.r=255*(e=Math.sin(t))*e,tC.g=255*(e=Math.sin(t+eC))*e,tC.b=255*(e=Math.sin(t+nC))*e,tC+""},interpolateTurbo:function(t){return t=Math.max(0,Math.min(1,t)),"rgb("+Math.max(0,Math.min(255,Math.round(34.61+t*(1172.33-t*(10793.56-t*(33300.12-t*(38394.49-14825.05*t)))))))+", "+Math.max(0,Math.min(255,Math.round(23.31+t*(557.33+t*(1225.33-t*(3574.96-t*(1073.77+707.56*t)))))))+", "+Math.max(0,Math.min(255,Math.round(27.2+t*(3211.1-t*(15327.97-t*(27814-t*(22569.18-6838.66*t)))))))+")"},interpolateViridis:iC,interpolateMagma:aC,interpolateInferno:oC,interpolatePlasma:sC,create:function(t){return Ts(_o(t).call(document.documentElement))},creator:_o,local:Ss,matcher:To,mouse:Ds,namespace:mo,namespaces:yo,clientPoint:Ms,select:Ts,selectAll:function(t){return"string"==typeof t?new ks([document.querySelectorAll(t)],[document.documentElement]):new ks([null==t?[]:t],xs)},selection:Cs,selector:xo,selectorAll:Co,style:zo,touch:js,touches:function(t,e){null==e&&(e=As().touches);for(var n=0,r=e?e.length:0,i=new Array(r);nd;if(s||(s=c=Zh()),h1e-12)if(p>vC-1e-12)s.moveTo(h*hC(d),h*pC(d)),s.arc(0,0,h,d,f,!g),u>1e-12&&(s.moveTo(u*hC(f),u*pC(f)),s.arc(0,0,u,f,d,g));else{var y,m,v=d,b=f,_=d,w=f,x=p,k=p,C=o.apply(this,arguments)/2,T=C>1e-12&&(r?+r.apply(this,arguments):gC(u*u+h*h)),E=fC(lC(h-u)/2,+n.apply(this,arguments)),S=E,O=E;if(T>1e-12){var A=_C(T/u*pC(C)),M=_C(T/h*pC(C));(x-=2*A)>1e-12?(_+=A*=g?1:-1,w-=A):(x=0,_=w=(d+f)/2),(k-=2*M)>1e-12?(v+=M*=g?1:-1,b-=M):(k=0,v=b=(d+f)/2)}var D=h*hC(v),j=h*pC(v),N=u*hC(w),B=u*pC(w);if(E>1e-12){var L,R=h*hC(b),I=h*pC(b),F=u*hC(_),P=u*pC(_);if(p1e-12?O>1e-12?(y=SC(F,P,D,j,h,O,g),m=SC(R,I,N,B,h,O,g),s.moveTo(y.cx+y.x01,y.cy+y.y01),O1e-12&&x>1e-12?S>1e-12?(y=SC(N,B,R,I,u,-S,g),m=SC(D,j,F,P,u,-S,g),s.lineTo(y.cx+y.x01,y.cy+y.y01),S0&&(f+=h);for(null!=e?p.sort((function(t,n){return e(g[t],g[n])})):null!=n&&p.sort((function(t,e){return n(o[t],o[e])})),s=0,l=f?(m-d*b)/f:0;s0?h*l:0)+b,g[c]={data:o[c],index:s,value:h,startAngle:y,endAngle:u,padAngle:v};return g}return o.value=function(e){return arguments.length?(t="function"==typeof e?e:cC(+e),o):t},o.sortValues=function(t){return arguments.length?(e=t,n=null,o):e},o.sort=function(t){return arguments.length?(n=t,e=null,o):n},o.startAngle=function(t){return arguments.length?(r="function"==typeof t?t:cC(+t),o):r},o.endAngle=function(t){return arguments.length?(i="function"==typeof t?t:cC(+t),o):i},o.padAngle=function(t){return arguments.length?(a="function"==typeof t?t:cC(+t),o):a},o},areaRadial:zC,radialArea:zC,lineRadial:YC,radialLine:YC,pointRadial:UC,linkHorizontal:function(){return HC(VC)},linkVertical:function(){return HC(GC)},linkRadial:function(){var t=HC(XC);return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t},symbol:function(){var t=cC(ZC),e=cC(64),n=null;function r(){var r;if(n||(n=r=Zh()),t.apply(this,arguments).draw(n,+e.apply(this,arguments)),r)return n=null,r+""||null}return r.type=function(e){return arguments.length?(t="function"==typeof e?e:cC(e),r):t},r.size=function(t){return arguments.length?(e="function"==typeof t?t:cC(+t),r):e},r.context=function(t){return arguments.length?(n=null==t?null:t,r):n},r},symbols:fT,symbolCircle:ZC,symbolCross:QC,symbolDiamond:tT,symbolSquare:aT,symbolStar:iT,symbolTriangle:sT,symbolWye:dT,curveBasisClosed:function(t){return new mT(t)},curveBasisOpen:function(t){return new vT(t)},curveBasis:function(t){return new yT(t)},curveBundle:_T,curveCardinalClosed:TT,curveCardinalOpen:ST,curveCardinal:kT,curveCatmullRomClosed:jT,curveCatmullRomOpen:BT,curveCatmullRom:MT,curveLinearClosed:function(t){return new LT(t)},curveLinear:AC,curveMonotoneX:function(t){return new YT(t)},curveMonotoneY:function(t){return new zT(t)},curveNatural:function(t){return new $T(t)},curveStep:function(t){return new qT(t,.5)},curveStepAfter:function(t){return new qT(t,1)},curveStepBefore:function(t){return new qT(t,0)},stack:function(){var t=cC([]),e=VT,n=HT,r=GT;function i(i){var a,o,s=t.apply(this,arguments),c=i.length,l=s.length,u=new Array(l);for(a=0;a0){for(var n,r,i,a=0,o=t[0].length;a0)for(var n,r,i,a,o,s,c=0,l=t[e[0]].length;c0?(r[0]=a,r[1]=a+=i):i<0?(r[1]=o,r[0]=o+=i):(r[0]=0,r[1]=i)},stackOffsetNone:HT,stackOffsetSilhouette:function(t,e){if((n=t.length)>0){for(var n,r=0,i=t[e[0]],a=i.length;r0&&(r=(n=t[e[0]]).length)>0){for(var n,r,i,a=0,o=1;o1&&n.name===e)return new Iu([[t]],uh,e,+r);return null},interrupt:lu,voronoi:function(){var t=tE,e=eE,n=null;function r(r){return new LE(r.map((function(n,i){var a=[Math.round(t(n,i,r)/jE)*jE,Math.round(e(n,i,r)/jE)*jE];return a.index=i,a.data=n,a})),n)}return r.polygons=function(t){return r(t).polygons()},r.links=function(t){return r(t).links()},r.triangles=function(t){return r(t).triangles()},r.x=function(e){return arguments.length?(t="function"==typeof e?e:JT(+e),r):t},r.y=function(t){return arguments.length?(e="function"==typeof t?t:JT(+t),r):e},r.extent=function(t){return arguments.length?(n=null==t?null:[[+t[0][0],+t[0][1]],[+t[1][0],+t[1][1]]],r):n&&[[n[0][0],n[0][1]],[n[1][0],n[1][1]]]},r.size=function(t){return arguments.length?(n=null==t?null:[[0,0],[+t[0],+t[1]]],r):n&&[n[1][0]-n[0][0],n[1][1]-n[0][1]]},r},zoom:function(){var t,e,n=$E,r=WE,i=GE,a=HE,o=VE,s=[0,1/0],c=[[-1/0,-1/0],[1/0,1/0]],l=250,u=Ol,h=lo("start","zoom","end"),d=500,f=0;function p(t){t.property("__zoom",qE).on("wheel.zoom",w).on("mousedown.zoom",x).on("dblclick.zoom",k).filter(o).on("touchstart.zoom",C).on("touchmove.zoom",T).on("touchend.zoom touchcancel.zoom",E).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function g(t,e){return(e=Math.max(s[0],Math.min(s[1],e)))===t.k?t:new FE(e,t.x,t.y)}function y(t,e,n){var r=e[0]-n[0]*t.k,i=e[1]-n[1]*t.k;return r===t.x&&i===t.y?t:new FE(t.k,r,i)}function m(t){return[(+t[0][0]+ +t[1][0])/2,(+t[0][1]+ +t[1][1])/2]}function v(t,e,n){t.on("start.zoom",(function(){b(this,arguments).start()})).on("interrupt.zoom end.zoom",(function(){b(this,arguments).end()})).tween("zoom",(function(){var t=this,i=arguments,a=b(t,i),o=r.apply(t,i),s=null==n?m(o):"function"==typeof n?n.apply(t,i):n,c=Math.max(o[1][0]-o[0][0],o[1][1]-o[0][1]),l=t.__zoom,h="function"==typeof e?e.apply(t,i):e,d=u(l.invert(s).concat(c/l.k),h.invert(s).concat(c/h.k));return function(t){if(1===t)t=h;else{var e=d(t),n=c/e[2];t=new FE(n,s[0]-e[0]*n,s[1]-e[1]*n)}a.zoom(null,t)}}))}function b(t,e,n){return!n&&t.__zooming||new _(t,e)}function _(t,e){this.that=t,this.args=e,this.active=0,this.extent=r.apply(t,e),this.taps=0}function w(){if(n.apply(this,arguments)){var t=b(this,arguments),e=this.__zoom,r=Math.max(s[0],Math.min(s[1],e.k*Math.pow(2,a.apply(this,arguments)))),o=Ds(this);if(t.wheel)t.mouse[0][0]===o[0]&&t.mouse[0][1]===o[1]||(t.mouse[1]=e.invert(t.mouse[0]=o)),clearTimeout(t.wheel);else{if(e.k===r)return;t.mouse=[o,e.invert(o)],lu(this),t.start()}UE(),t.wheel=setTimeout(l,150),t.zoom("mouse",i(y(g(e,r),t.mouse[0],t.mouse[1]),t.extent,c))}function l(){t.wheel=null,t.end()}}function x(){if(!e&&n.apply(this,arguments)){var t=b(this,arguments,!0),r=Ts(ds.view).on("mousemove.zoom",l,!0).on("mouseup.zoom",u,!0),a=Ds(this),o=ds.clientX,s=ds.clientY;Ls(ds.view),zE(),t.mouse=[a,this.__zoom.invert(a)],lu(this),t.start()}function l(){if(UE(),!t.moved){var e=ds.clientX-o,n=ds.clientY-s;t.moved=e*e+n*n>f}t.zoom("mouse",i(y(t.that.__zoom,t.mouse[0]=Ds(t.that),t.mouse[1]),t.extent,c))}function u(){r.on("mousemove.zoom mouseup.zoom",null),Rs(ds.view,t.moved),UE(),t.end()}}function k(){if(n.apply(this,arguments)){var t=this.__zoom,e=Ds(this),a=t.invert(e),o=t.k*(ds.shiftKey?.5:2),s=i(y(g(t,o),e,a),r.apply(this,arguments),c);UE(),l>0?Ts(this).transition().duration(l).call(v,s,e):Ts(this).call(p.transform,s)}}function C(){if(n.apply(this,arguments)){var e,r,i,a,o=ds.touches,s=o.length,c=b(this,arguments,ds.changedTouches.length===s);for(zE(),r=0;r-1},lS=function(t,e){var n=this.__data__,r=iS(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this};function uS(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e-1&&t%1==0&&t-1&&t%1==0&&t<=9007199254740991},SA=jS,OA=EA,AA=aA,MA={};MA["[object Float32Array]"]=MA["[object Float64Array]"]=MA["[object Int8Array]"]=MA["[object Int16Array]"]=MA["[object Int32Array]"]=MA["[object Uint8Array]"]=MA["[object Uint8ClampedArray]"]=MA["[object Uint16Array]"]=MA["[object Uint32Array]"]=!0,MA["[object Arguments]"]=MA["[object Array]"]=MA["[object ArrayBuffer]"]=MA["[object Boolean]"]=MA["[object DataView]"]=MA["[object Date]"]=MA["[object Error]"]=MA["[object Function]"]=MA["[object Map]"]=MA["[object Number]"]=MA["[object Object]"]=MA["[object RegExp]"]=MA["[object Set]"]=MA["[object String]"]=MA["[object WeakMap]"]=!1;var DA=function(t){return AA(t)&&OA(t.length)&&!!MA[SA(t)]};var jA=function(t){return function(e){return t(e)}},NA={exports:{}};!function(t,e){var n=mS,r=e&&!e.nodeType&&e,i=r&&t&&!t.nodeType&&t,a=i&&i.exports===r&&n.process,o=function(){try{var t=i&&i.require&&i.require("util").types;return t||a&&a.binding&&a.binding("util")}catch(e){}}();t.exports=o}(NA,NA.exports);var BA=DA,LA=jA,RA=NA.exports,IA=RA&&RA.isTypedArray,FA=IA?LA(IA):BA,PA=iA,YA=wA,zA=xA,UA=kA.exports,$A=TA,WA=FA,qA=Object.prototype.hasOwnProperty;var HA=function(t,e){var n=zA(t),r=!n&&YA(t),i=!n&&!r&&UA(t),a=!n&&!r&&!i&&WA(t),o=n||r||i||a,s=o?PA(t.length,String):[],c=s.length;for(var l in t)!e&&!qA.call(t,l)||o&&("length"==l||i&&("offset"==l||"parent"==l)||a&&("buffer"==l||"byteLength"==l||"byteOffset"==l)||$A(l,c))||s.push(l);return s},VA=Object.prototype;var GA=function(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||VA)};var XA=function(t,e){return function(n){return t(e(n))}},ZA=XA(Object.keys,Object),QA=GA,KA=ZA,JA=Object.prototype.hasOwnProperty;var tM=function(t){if(!QA(t))return KA(t);var e=[];for(var n in Object(t))JA.call(t,n)&&"constructor"!=n&&e.push(n);return e},eM=IS,nM=EA;var rM=function(t){return null!=t&&nM(t.length)&&!eM(t)},iM=HA,aM=tM,oM=rM;var sM=function(t){return oM(t)?iM(t):aM(t)},cM=rA,lM=sM;var uM=function(t,e){return t&&cM(e,lM(e),t)};var hM=NS,dM=GA,fM=function(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e},pM=Object.prototype.hasOwnProperty;var gM=HA,yM=function(t){if(!hM(t))return fM(t);var e=dM(t),n=[];for(var r in t)("constructor"!=r||!e&&pM.call(t,r))&&n.push(r);return n},mM=rM;var vM=function(t){return mM(t)?gM(t,!0):yM(t)},bM=rA,_M=vM;var wM=function(t,e){return t&&bM(e,_M(e),t)},xM={exports:{}};!function(t,e){var n=_S,r=e&&!e.nodeType&&e,i=r&&t&&!t.nodeType&&t,a=i&&i.exports===r?n.Buffer:void 0,o=a?a.allocUnsafe:void 0;t.exports=function(t,e){if(e)return t.slice();var n=t.length,r=o?o(n):new t.constructor(n);return t.copy(r),r}}(xM,xM.exports);var kM=function(t,e){var n=-1,r=t.length;for(e||(e=Array(r));++ns))return!1;var l=a.get(t),u=a.get(e);if(l&&u)return l==e&&u==t;var h=-1,d=!0,f=2&n?new tN:void 0;for(a.set(t,e),a.set(e,t);++h0&&r(c)?n>1?t(c,n-1,r,i,a):dR(a,c):i||(a[a.length]=c)}return a};var gR=function(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)},yR=Math.max;var mR=function(t,e,n){return e=yR(void 0===e?t.length-1:e,0),function(){for(var r=arguments,i=-1,a=yR(r.length-e,0),o=Array(a);++i0){if(++e>=800)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}(_R),kR=Ij,CR=mR,TR=xR;var ER=function(t,e){return TR(CR(t,e,kR),t+"")};var SR=function(t,e,n,r){for(var i=t.length,a=n+(r?1:-1);r?a--:++a-1};var NR=function(t,e,n){for(var r=-1,i=null==t?0:t.length;++r=200){var l=e?null:zR(t);if(l)return UR(l);o=!1,i=YR,c=new IR}else c=e?[]:s;t:for(;++ra){var o=i;i=a,a=o}return i+""+a+""+(nI.isUndefined(r)?"\0":r)}function cI(t,e,n,r){var i=""+e,a=""+n;if(!t&&i>a){var o=i;i=a,a=o}var s={v:i,w:a};return r&&(s.name=r),s}function lI(t,e){return sI(t,e.v,e.w,e.name)}iI.prototype._nodeCount=0,iI.prototype._edgeCount=0,iI.prototype.isDirected=function(){return this._isDirected},iI.prototype.isMultigraph=function(){return this._isMultigraph},iI.prototype.isCompound=function(){return this._isCompound},iI.prototype.setGraph=function(t){return this._label=t,this},iI.prototype.graph=function(){return this._label},iI.prototype.setDefaultNodeLabel=function(t){return nI.isFunction(t)||(t=nI.constant(t)),this._defaultNodeLabelFn=t,this},iI.prototype.nodeCount=function(){return this._nodeCount},iI.prototype.nodes=function(){return nI.keys(this._nodes)},iI.prototype.sources=function(){var t=this;return nI.filter(this.nodes(),(function(e){return nI.isEmpty(t._in[e])}))},iI.prototype.sinks=function(){var t=this;return nI.filter(this.nodes(),(function(e){return nI.isEmpty(t._out[e])}))},iI.prototype.setNodes=function(t,e){var n=arguments,r=this;return nI.each(t,(function(t){n.length>1?r.setNode(t,e):r.setNode(t)})),this},iI.prototype.setNode=function(t,e){return nI.has(this._nodes,t)?(arguments.length>1&&(this._nodes[t]=e),this):(this._nodes[t]=arguments.length>1?e:this._defaultNodeLabelFn(t),this._isCompound&&(this._parent[t]="\0",this._children[t]={},this._children["\0"][t]=!0),this._in[t]={},this._preds[t]={},this._out[t]={},this._sucs[t]={},++this._nodeCount,this)},iI.prototype.node=function(t){return this._nodes[t]},iI.prototype.hasNode=function(t){return nI.has(this._nodes,t)},iI.prototype.removeNode=function(t){var e=this;if(nI.has(this._nodes,t)){var n=function(t){e.removeEdge(e._edgeObjs[t])};delete this._nodes[t],this._isCompound&&(this._removeFromParentsChildList(t),delete this._parent[t],nI.each(this.children(t),(function(t){e.setParent(t)})),delete this._children[t]),nI.each(nI.keys(this._in[t]),n),delete this._in[t],delete this._preds[t],nI.each(nI.keys(this._out[t]),n),delete this._out[t],delete this._sucs[t],--this._nodeCount}return this},iI.prototype.setParent=function(t,e){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(nI.isUndefined(e))e="\0";else{for(var n=e+="";!nI.isUndefined(n);n=this.parent(n))if(n===t)throw new Error("Setting "+e+" as parent of "+t+" would create a cycle");this.setNode(e)}return this.setNode(t),this._removeFromParentsChildList(t),this._parent[t]=e,this._children[e][t]=!0,this},iI.prototype._removeFromParentsChildList=function(t){delete this._children[this._parent[t]][t]},iI.prototype.parent=function(t){if(this._isCompound){var e=this._parent[t];if("\0"!==e)return e}},iI.prototype.children=function(t){if(nI.isUndefined(t)&&(t="\0"),this._isCompound){var e=this._children[t];if(e)return nI.keys(e)}else{if("\0"===t)return this.nodes();if(this.hasNode(t))return[]}},iI.prototype.predecessors=function(t){var e=this._preds[t];if(e)return nI.keys(e)},iI.prototype.successors=function(t){var e=this._sucs[t];if(e)return nI.keys(e)},iI.prototype.neighbors=function(t){var e=this.predecessors(t);if(e)return nI.union(e,this.successors(t))},iI.prototype.isLeaf=function(t){return 0===(this.isDirected()?this.successors(t):this.neighbors(t)).length},iI.prototype.filterNodes=function(t){var e=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});e.setGraph(this.graph());var n=this;nI.each(this._nodes,(function(n,r){t(r)&&e.setNode(r,n)})),nI.each(this._edgeObjs,(function(t){e.hasNode(t.v)&&e.hasNode(t.w)&&e.setEdge(t,n.edge(t))}));var r={};function i(t){var a=n.parent(t);return void 0===a||e.hasNode(a)?(r[t]=a,a):a in r?r[a]:i(a)}return this._isCompound&&nI.each(e.nodes(),(function(t){e.setParent(t,i(t))})),e},iI.prototype.setDefaultEdgeLabel=function(t){return nI.isFunction(t)||(t=nI.constant(t)),this._defaultEdgeLabelFn=t,this},iI.prototype.edgeCount=function(){return this._edgeCount},iI.prototype.edges=function(){return nI.values(this._edgeObjs)},iI.prototype.setPath=function(t,e){var n=this,r=arguments;return nI.reduce(t,(function(t,i){return r.length>1?n.setEdge(t,i,e):n.setEdge(t,i),i})),this},iI.prototype.setEdge=function(){var t,e,n,r,i=!1,a=arguments[0];"object"==typeof a&&null!==a&&"v"in a?(t=a.v,e=a.w,n=a.name,2===arguments.length&&(r=arguments[1],i=!0)):(t=a,e=arguments[1],n=arguments[3],arguments.length>2&&(r=arguments[2],i=!0)),t=""+t,e=""+e,nI.isUndefined(n)||(n=""+n);var o=sI(this._isDirected,t,e,n);if(nI.has(this._edgeLabels,o))return i&&(this._edgeLabels[o]=r),this;if(!nI.isUndefined(n)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(t),this.setNode(e),this._edgeLabels[o]=i?r:this._defaultEdgeLabelFn(t,e,n);var s=cI(this._isDirected,t,e,n);return t=s.v,e=s.w,Object.freeze(s),this._edgeObjs[o]=s,aI(this._preds[e],t),aI(this._sucs[t],e),this._in[e][o]=s,this._out[t][o]=s,this._edgeCount++,this},iI.prototype.edge=function(t,e,n){var r=1===arguments.length?lI(this._isDirected,arguments[0]):sI(this._isDirected,t,e,n);return this._edgeLabels[r]},iI.prototype.hasEdge=function(t,e,n){var r=1===arguments.length?lI(this._isDirected,arguments[0]):sI(this._isDirected,t,e,n);return nI.has(this._edgeLabels,r)},iI.prototype.removeEdge=function(t,e,n){var r=1===arguments.length?lI(this._isDirected,arguments[0]):sI(this._isDirected,t,e,n),i=this._edgeObjs[r];return i&&(t=i.v,e=i.w,delete this._edgeLabels[r],delete this._edgeObjs[r],oI(this._preds[e],t),oI(this._sucs[t],e),delete this._in[e][r],delete this._out[t][r],this._edgeCount--),this},iI.prototype.inEdges=function(t,e){var n=this._in[t];if(n){var r=nI.values(n);return e?nI.filter(r,(function(t){return t.v===e})):r}},iI.prototype.outEdges=function(t,e){var n=this._out[t];if(n){var r=nI.values(n);return e?nI.filter(r,(function(t){return t.w===e})):r}},iI.prototype.nodeEdges=function(t,e){var n=this.inEdges(t,e);if(n)return n.concat(this.outEdges(t,e))};var uI={Graph:rI,version:"2.1.8"},hI=eI,dI=rI,fI={write:function(t){var e={options:{directed:t.isDirected(),multigraph:t.isMultigraph(),compound:t.isCompound()},nodes:pI(t),edges:gI(t)};hI.isUndefined(t.graph())||(e.value=hI.clone(t.graph()));return e},read:function(t){var e=new dI(t.options).setGraph(t.value);return hI.each(t.nodes,(function(t){e.setNode(t.v,t.value),t.parent&&e.setParent(t.v,t.parent)})),hI.each(t.edges,(function(t){e.setEdge({v:t.v,w:t.w,name:t.name},t.value)})),e}};function pI(t){return hI.map(t.nodes(),(function(e){var n=t.node(e),r=t.parent(e),i={v:e};return hI.isUndefined(n)||(i.value=n),hI.isUndefined(r)||(i.parent=r),i}))}function gI(t){return hI.map(t.edges(),(function(e){var n=t.edge(e),r={v:e.v,w:e.w};return hI.isUndefined(e.name)||(r.name=e.name),hI.isUndefined(n)||(r.value=n),r}))}var yI=eI,mI=function(t){var e,n={},r=[];function i(r){yI.has(n,r)||(n[r]=!0,e.push(r),yI.each(t.successors(r),i),yI.each(t.predecessors(r),i))}return yI.each(t.nodes(),(function(t){e=[],i(t),e.length&&r.push(e)})),r};var vI=eI,bI=_I;function _I(){this._arr=[],this._keyIndices={}}_I.prototype.size=function(){return this._arr.length},_I.prototype.keys=function(){return this._arr.map((function(t){return t.key}))},_I.prototype.has=function(t){return vI.has(this._keyIndices,t)},_I.prototype.priority=function(t){var e=this._keyIndices[t];if(void 0!==e)return this._arr[e].priority},_I.prototype.min=function(){if(0===this.size())throw new Error("Queue underflow");return this._arr[0].key},_I.prototype.add=function(t,e){var n=this._keyIndices;if(t=String(t),!vI.has(n,t)){var r=this._arr,i=r.length;return n[t]=i,r.push({key:t,priority:e}),this._decrease(i),!0}return!1},_I.prototype.removeMin=function(){this._swap(0,this._arr.length-1);var t=this._arr.pop();return delete this._keyIndices[t.key],this._heapify(0),t.key},_I.prototype.decrease=function(t,e){var n=this._keyIndices[t];if(e>this._arr[n].priority)throw new Error("New priority is greater than current priority. Key: "+t+" Old: "+this._arr[n].priority+" New: "+e);this._arr[n].priority=e,this._decrease(n)},_I.prototype._heapify=function(t){var e=this._arr,n=2*t,r=n+1,i=t;n>1].priority0&&(i=s.removeMin(),(a=o[i]).distance!==Number.POSITIVE_INFINITY);)r(i).forEach(c);return o}(t,String(e),n||kI,r||function(e){return t.outEdges(e)})},kI=eI.constant(1);var CI=xI,TI=eI,EI=function(t,e,n){return TI.transform(t.nodes(),(function(r,i){r[i]=CI(t,i,e,n)}),{})};var SI=eI,OI=function(t){var e=0,n=[],r={},i=[];function a(o){var s=r[o]={onStack:!0,lowlink:e,index:e++};if(n.push(o),t.successors(o).forEach((function(t){SI.has(r,t)?r[t].onStack&&(s.lowlink=Math.min(s.lowlink,r[t].index)):(a(t),s.lowlink=Math.min(s.lowlink,r[t].lowlink))})),s.lowlink===s.index){var c,l=[];do{c=n.pop(),r[c].onStack=!1,l.push(c)}while(o!==c);i.push(l)}}return t.nodes().forEach((function(t){SI.has(r,t)||a(t)})),i};var AI=eI,MI=OI,DI=function(t){return AI.filter(MI(t),(function(e){return e.length>1||1===e.length&&t.hasEdge(e[0],e[0])}))};var jI=function(t,e,n){return function(t,e,n){var r={},i=t.nodes();return i.forEach((function(t){r[t]={},r[t][t]={distance:0},i.forEach((function(e){t!==e&&(r[t][e]={distance:Number.POSITIVE_INFINITY})})),n(t).forEach((function(n){var i=n.v===t?n.w:n.v,a=e(n);r[t][i]={distance:a,predecessor:t}}))})),i.forEach((function(t){var e=r[t];i.forEach((function(n){var a=r[n];i.forEach((function(n){var r=a[t],i=e[n],o=a[n],s=r.distance+i.distance;s0;){if(n=a.removeMin(),WI.has(i,n))r.setEdge(n,i[n]);else{if(s)throw new Error("Input graph is not connected: "+t);s=!0}t.nodeEdges(n).forEach(o)}return r},tarjan:OI,topsort:LI},version:uI.version};try{VI=GI}catch(HG){}VI||(VI=window.graphlib);var XI=VI,ZI=Sj;var QI=function(t){return ZI(t,5)},KI=QE,JI=rM,tF=TA,eF=NS;var nF=function(t,e,n){if(!eF(n))return!1;var r=typeof e;return!!("number"==r?JI(n)&&tF(e,n.length):"string"==r&&e in n)&&KI(n[e],t)},rF=ER,iF=QE,aF=nF,oF=vM,sF=Object.prototype,cF=sF.hasOwnProperty,lF=rF((function(t,e){t=Object(t);var n=-1,r=e.length,i=r>2?e[2]:void 0;for(i&&aF(e[0],e[1],i)&&(r=1);++n-1?i[a?e[o]:o]:void 0}},pF=/\s/;var gF=function(t){for(var e=t.length;e--&&pF.test(t.charAt(e)););return e},yF=/^\s+/;var mF=function(t){return t?t.slice(0,gF(t)+1).replace(yF,""):t},vF=NS,bF=YN,_F=/^[-+]0x[0-9a-f]+$/i,wF=/^0b[01]+$/i,xF=/^0o[0-7]+$/i,kF=parseInt;var CF=function(t){if("number"==typeof t)return t;if(bF(t))return NaN;if(vF(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=vF(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=mF(t);var n=wF.test(t);return n||xF.test(t)?kF(t.slice(2),n?2:8):_F.test(t)?NaN:+t};var TF=function(t){return t?Infinity===(t=CF(t))||-Infinity===t?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0},EF=TF;var SF=SR,OF=qB,AF=function(t){var e=EF(t),n=e%1;return e==e?n?e-n:e:0},MF=Math.max;var DF=fF((function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=null==n?0:AF(n);return i<0&&(i=MF(r+i,0)),SF(t,OF(e),i)})),jF=pR;var NF=function(t){return(null==t?0:t.length)?jF(t,1):[]},BF=Dj,LF=Pj,RF=vM;var IF=function(t,e){return null==t?t:BF(t,LF(e),RF)};var FF=function(t){var e=null==t?0:t.length;return e?t[e-1]:void 0},PF=ZO,YF=Bj,zF=qB;var UF=function(t,e){var n={};return e=zF(e),YF(t,(function(t,r,i){PF(n,r,e(t,r,i))})),n},$F=YN;var WF=function(t,e,n){for(var r=-1,i=t.length;++re},VF=Ij;var GF=function(t){return t&&t.length?qF(t,VF,HF):void 0},XF=ZO,ZF=QE;var QF=function(t,e,n){(void 0!==n&&!ZF(t[e],n)||void 0===n&&!(e in t))&&XF(t,e,n)},KF=jS,JF=LM,tP=aA,eP=Function.prototype,nP=Object.prototype,rP=eP.toString,iP=nP.hasOwnProperty,aP=rP.call(Object);var oP=function(t){if(!tP(t)||"[object Object]"!=KF(t))return!1;var e=JF(t);if(null===e)return!0;var n=iP.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&rP.call(n)==aP};var sP=function(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]},cP=rA,lP=vM;var uP=QF,hP=xM.exports,dP=MD,fP=kM,pP=$D,gP=wA,yP=xA,mP=qR,vP=kA.exports,bP=IS,_P=NS,wP=oP,xP=FA,kP=sP,CP=function(t){return cP(t,lP(t))};var TP=qO,EP=QF,SP=Dj,OP=function(t,e,n,r,i,a,o){var s=kP(t,n),c=kP(e,n),l=o.get(c);if(l)uP(t,n,l);else{var u=a?a(s,c,n+"",t,e,o):void 0,h=void 0===u;if(h){var d=yP(c),f=!d&&vP(c),p=!d&&!f&&xP(c);u=c,d||f||p?yP(s)?u=s:mP(s)?u=fP(s):f?(h=!1,u=hP(c,!0)):p?(h=!1,u=dP(c,!0)):u=[]:wP(c)||gP(c)?(u=s,gP(s)?u=CP(s):_P(s)&&!bP(s)||(u=pP(c))):h=!1}h&&(o.set(c,u),i(u,c,r,a,o),o.delete(c)),uP(t,n,u)}},AP=NS,MP=vM,DP=sP;var jP=ER,NP=nF;var BP=function t(e,n,r,i,a){e!==n&&SP(n,(function(o,s){if(a||(a=new TP),AP(o))OP(e,n,s,r,t,i,a);else{var c=i?i(DP(e,s),o,s+"",e,n,a):void 0;void 0===c&&(c=o),EP(e,s,c)}}),MP)},LP=function(t){return jP((function(e,n){var r=-1,i=n.length,a=i>1?n[i-1]:void 0,o=i>2?n[2]:void 0;for(a=t.length>3&&"function"==typeof a?(i--,a):void 0,o&&NP(n[0],n[1],o)&&(a=i<3?void 0:a,i=1),e=Object(e);++re||a&&o&&c&&!s&&!l||r&&o&&c||!n&&c||!i)return 1;if(!r&&!a&&!l&&t=s?c:c*("desc"==n[r]?-1:1)}return t.index-e.index},kY=Ij,CY=xA;var TY=pR,EY=function(t,e,n){e=e.length?yY(e,(function(t){return CY(t)?function(e){return mY(e,1===t.length?t[0]:t)}:t})):[kY];var r=-1;e=yY(e,wY(vY));var i=bY(t,(function(t,n,i){return{criteria:yY(e,(function(e){return e(t)})),index:++r,value:t}}));return _Y(i,(function(t,e){return xY(t,e,n)}))},SY=nF,OY=ER((function(t,e){if(null==t)return[];var n=e.length;return n>1&&SY(t,e[0],e[1])?e=[]:n>2&&SY(e[0],e[1],e[2])&&(e=[e[0]]),EY(t,TY(e,1),[])})),AY=aB,MY=0;var DY=function(t){var e=++MY;return AY(t)+e};var jY=tA,NY=function(t,e,n){for(var r=-1,i=t.length,a=e.length,o={};++r0;--s)if(r=e[s].dequeue()){i=i.concat(HY(t,e,n,r,!0));break}}return i}(n.graph,n.buckets,n.zeroIdx);return zY.flatten(zY.map(r,(function(e){return t.outEdges(e.v,e.w)})),!0)},qY=zY.constant(1);function HY(t,e,n,r,i){var a=i?[]:void 0;return zY.forEach(t.inEdges(r.v),(function(r){var o=t.edge(r),s=t.node(r.v);i&&a.push({v:r.v,w:r.w}),s.out-=o,VY(e,n,s)})),zY.forEach(t.outEdges(r.v),(function(r){var i=t.edge(r),a=r.w,o=t.node(a);o.in-=i,VY(e,n,o)})),t.removeNode(r.v),a}function VY(t,e,n){n.out?n.in?t[n.out-n.in+e].enqueue(n):t[t.length-1].enqueue(n):t[0].enqueue(n)}var GY=RY,XY=WY,ZY={run:function(t){var e="greedy"===t.graph().acyclicer?XY(t,(n=t,function(t){return n.edge(t).weight})):function(t){var e=[],n={},r={};function i(a){GY.has(r,a)||(r[a]=!0,n[a]=!0,GY.forEach(t.outEdges(a),(function(t){GY.has(n,t.w)?e.push(t):i(t.w)})),delete n[a])}return GY.forEach(t.nodes(),i),e}(t);var n;GY.forEach(e,(function(e){var n=t.edge(e);t.removeEdge(e),n.forwardName=e.name,n.reversed=!0,t.setEdge(e.w,e.v,n,GY.uniqueId("rev"))}))},undo:function(t){GY.forEach(t.edges(),(function(e){var n=t.edge(e);if(n.reversed){t.removeEdge(e);var r=n.forwardName;delete n.reversed,delete n.forwardName,t.setEdge(e.w,e.v,n,r)}}))}};var QY=RY,KY=XI.Graph,JY={addDummyNode:tz,simplify:function(t){var e=(new KY).setGraph(t.graph());return QY.forEach(t.nodes(),(function(n){e.setNode(n,t.node(n))})),QY.forEach(t.edges(),(function(n){var r=e.edge(n.v,n.w)||{weight:0,minlen:1},i=t.edge(n);e.setEdge(n.v,n.w,{weight:r.weight+i.weight,minlen:Math.max(r.minlen,i.minlen)})})),e},asNonCompoundGraph:function(t){var e=new KY({multigraph:t.isMultigraph()}).setGraph(t.graph());return QY.forEach(t.nodes(),(function(n){t.children(n).length||e.setNode(n,t.node(n))})),QY.forEach(t.edges(),(function(n){e.setEdge(n,t.edge(n))})),e},successorWeights:function(t){var e=QY.map(t.nodes(),(function(e){var n={};return QY.forEach(t.outEdges(e),(function(e){n[e.w]=(n[e.w]||0)+t.edge(e).weight})),n}));return QY.zipObject(t.nodes(),e)},predecessorWeights:function(t){var e=QY.map(t.nodes(),(function(e){var n={};return QY.forEach(t.inEdges(e),(function(e){n[e.v]=(n[e.v]||0)+t.edge(e).weight})),n}));return QY.zipObject(t.nodes(),e)},intersectRect:function(t,e){var n,r,i=t.x,a=t.y,o=e.x-i,s=e.y-a,c=t.width/2,l=t.height/2;if(!o&&!s)throw new Error("Not possible to find intersection inside of the rectangle");Math.abs(s)*c>Math.abs(o)*l?(s<0&&(l=-l),n=l*o/s,r=l):(o<0&&(c=-c),n=c,r=c*s/o);return{x:i+n,y:a+r}},buildLayerMatrix:function(t){var e=QY.map(QY.range(ez(t)+1),(function(){return[]}));return QY.forEach(t.nodes(),(function(n){var r=t.node(n),i=r.rank;QY.isUndefined(i)||(e[i][r.order]=n)})),e},normalizeRanks:function(t){var e=QY.min(QY.map(t.nodes(),(function(e){return t.node(e).rank})));QY.forEach(t.nodes(),(function(n){var r=t.node(n);QY.has(r,"rank")&&(r.rank-=e)}))},removeEmptyRanks:function(t){var e=QY.min(QY.map(t.nodes(),(function(e){return t.node(e).rank}))),n=[];QY.forEach(t.nodes(),(function(r){var i=t.node(r).rank-e;n[i]||(n[i]=[]),n[i].push(r)}));var r=0,i=t.graph().nodeRankFactor;QY.forEach(n,(function(e,n){QY.isUndefined(e)&&n%i!=0?--r:r&&QY.forEach(e,(function(e){t.node(e).rank+=r}))}))},addBorderNode:function(t,e,n,r){var i={width:0,height:0};arguments.length>=4&&(i.rank=n,i.order=r);return tz(t,"border",i,e)},maxRank:ez,partition:function(t,e){var n={lhs:[],rhs:[]};return QY.forEach(t,(function(t){e(t)?n.lhs.push(t):n.rhs.push(t)})),n},time:function(t,e){var n=QY.now();try{return e()}finally{console.log(t+" time: "+(QY.now()-n)+"ms")}},notime:function(t,e){return e()}};function tz(t,e,n,r){var i;do{i=QY.uniqueId(r)}while(t.hasNode(i));return n.dummy=e,t.setNode(i,n),i}function ez(t){return QY.max(QY.map(t.nodes(),(function(e){var n=t.node(e).rank;if(!QY.isUndefined(n))return n})))}var nz=RY,rz=JY,iz={run:function(t){t.graph().dummyChains=[],nz.forEach(t.edges(),(function(e){!function(t,e){var n,r,i,a=e.v,o=t.node(a).rank,s=e.w,c=t.node(s).rank,l=e.name,u=t.edge(e),h=u.labelRank;if(c===o+1)return;for(t.removeEdge(e),i=0,++o;oo.lim&&(s=o,c=!0);var l=pz.filter(e.edges(),(function(e){return c===Mz(t,t.node(e.v),s)&&c!==Mz(t,t.node(e.w),s)}));return pz.minBy(l,(function(t){return yz(e,t)}))}function Az(t,e,n,r){var i=n.v,a=n.w;t.removeEdge(i,a),t.setEdge(r.v,r.w,{}),Tz(t),kz(t,e),function(t,e){var n=pz.find(t.nodes(),(function(t){return!e.node(t).parent})),r=vz(t,n);r=r.slice(1),pz.forEach(r,(function(n){var r=t.node(n).parent,i=e.edge(n,r),a=!1;i||(i=e.edge(r,n),a=!0),e.node(n).rank=e.node(r).rank+(a?i.minlen:-i.minlen)}))}(t,e)}function Mz(t,e,n){return n.low<=e.lim&&e.lim<=n.lim}xz.initLowLimValues=Tz,xz.initCutValues=kz,xz.calcCutValue=Cz,xz.leaveEdge=Sz,xz.enterEdge=Oz,xz.exchangeEdges=Az;var Dz=oz.longestPath,jz=uz,Nz=wz,Bz=function(t){switch(t.graph().ranker){case"network-simplex":Rz(t);break;case"tight-tree":!function(t){Dz(t),jz(t)}(t);break;case"longest-path":Lz(t);break;default:Rz(t)}};var Lz=Dz;function Rz(t){Nz(t)}var Iz=RY,Fz=function(t){var e=function(t){var e={},n=0;function r(i){var a=n;Iz.forEach(t.children(i),r),e[i]={low:a,lim:n++}}return Iz.forEach(t.children(),r),e}(t);Iz.forEach(t.graph().dummyChains,(function(n){for(var r=t.node(n),i=r.edgeObj,a=function(t,e,n,r){var i,a,o=[],s=[],c=Math.min(e[n].low,e[r].low),l=Math.max(e[n].lim,e[r].lim);i=n;do{i=t.parent(i),o.push(i)}while(i&&(e[i].low>c||l>e[i].lim));a=i,i=r;for(;(i=t.parent(i))!==a;)s.push(i);return{path:o.concat(s.reverse()),lca:a}}(t,e,i.v,i.w),o=a.path,s=a.lca,c=0,l=o[c],u=!0;n!==i.w;){if(r=t.node(n),u){for(;(l=o[c])!==s&&t.node(l).maxRank0;)e%2&&(n+=s[e+1]),s[e=e-1>>1]+=t.weight;c+=t.weight*n}))),c}var iU=RY;var aU=RY;var oU=RY,sU=JY;function cU(t,e,n){for(var r;e.length&&(r=oU.last(e)).i<=n;)e.pop(),t.push(r.vs),n++;return n}var lU=RY,uU=function(t,e){return iU.map(e,(function(e){var n=t.inEdges(e);if(n.length){var r=iU.reduce(n,(function(e,n){var r=t.edge(n),i=t.node(n.v);return{sum:e.sum+r.weight*i.order,weight:e.weight+r.weight}}),{sum:0,weight:0});return{v:e,barycenter:r.sum/r.weight,weight:r.weight}}return{v:e}}))},hU=function(t,e){var n={};return aU.forEach(t,(function(t,e){var r=n[t.v]={indegree:0,in:[],out:[],vs:[t.v],i:e};aU.isUndefined(t.barycenter)||(r.barycenter=t.barycenter,r.weight=t.weight)})),aU.forEach(e.edges(),(function(t){var e=n[t.v],r=n[t.w];aU.isUndefined(e)||aU.isUndefined(r)||(r.indegree++,e.out.push(n[t.w]))})),function(t){var e=[];function n(t){return function(e){e.merged||(aU.isUndefined(e.barycenter)||aU.isUndefined(t.barycenter)||e.barycenter>=t.barycenter)&&function(t,e){var n=0,r=0;t.weight&&(n+=t.barycenter*t.weight,r+=t.weight);e.weight&&(n+=e.barycenter*e.weight,r+=e.weight);t.vs=e.vs.concat(t.vs),t.barycenter=n/r,t.weight=r,t.i=Math.min(e.i,t.i),e.merged=!0}(t,e)}}function r(e){return function(n){n.in.push(e),0==--n.indegree&&t.push(n)}}for(;t.length;){var i=t.pop();e.push(i),aU.forEach(i.in.reverse(),n(i)),aU.forEach(i.out,r(i))}return aU.map(aU.filter(e,(function(t){return!t.merged})),(function(t){return aU.pick(t,["vs","i","barycenter","weight"])}))}(aU.filter(n,(function(t){return!t.indegree})))},dU=function(t,e){var n=sU.partition(t,(function(t){return oU.has(t,"barycenter")})),r=n.lhs,i=oU.sortBy(n.rhs,(function(t){return-t.i})),a=[],o=0,s=0,c=0;r.sort((l=!!e,function(t,e){return t.barycentere.barycenter?1:l?e.i-t.i:t.i-e.i})),c=cU(a,i,c),oU.forEach(r,(function(t){c+=t.vs.length,a.push(t.vs),o+=t.barycenter*t.weight,s+=t.weight,c=cU(a,i,c)}));var l;var u={vs:oU.flatten(a,!0)};s&&(u.barycenter=o/s,u.weight=s);return u},fU=function t(e,n,r,i){var a=e.children(n),o=e.node(n),s=o?o.borderLeft:void 0,c=o?o.borderRight:void 0,l={};s&&(a=lU.filter(a,(function(t){return t!==s&&t!==c})));var u=uU(e,a);lU.forEach(u,(function(n){if(e.children(n.v).length){var a=t(e,n.v,r,i);l[n.v]=a,lU.has(a,"barycenter")&&(o=n,s=a,lU.isUndefined(o.barycenter)?(o.barycenter=s.barycenter,o.weight=s.weight):(o.barycenter=(o.barycenter*o.weight+s.barycenter*s.weight)/(o.weight+s.weight),o.weight+=s.weight))}var o,s}));var h=hU(u,r);!function(t,e){lU.forEach(t,(function(t){t.vs=lU.flatten(t.vs.map((function(t){return e[t]?e[t].vs:t})),!0)}))}(h,l);var d=dU(h,i);if(s&&(d.vs=lU.flatten([s,d.vs,c],!0),e.predecessors(s).length)){var f=e.node(e.predecessors(s)[0]),p=e.node(e.predecessors(c)[0]);lU.has(d,"barycenter")||(d.barycenter=0,d.weight=0),d.barycenter=(d.barycenter*d.weight+f.order+p.order)/(d.weight+2),d.weight+=2}return d};var pU=RY,gU=XI.Graph;var yU=RY;var mU=RY,vU=tU,bU=nU,_U=fU,wU=function(t,e,n){var r=function(t){var e;for(;t.hasNode(e=pU.uniqueId("_root")););return e}(t),i=new gU({compound:!0}).setGraph({root:r}).setDefaultNodeLabel((function(e){return t.node(e)}));return pU.forEach(t.nodes(),(function(a){var o=t.node(a),s=t.parent(a);(o.rank===e||o.minRank<=e&&e<=o.maxRank)&&(i.setNode(a),i.setParent(a,s||r),pU.forEach(t[n](a),(function(e){var n=e.v===a?e.w:e.v,r=i.edge(n,a),o=pU.isUndefined(r)?0:r.weight;i.setEdge(n,a,{weight:t.edge(e).weight+o})})),pU.has(o,"minRank")&&i.setNode(a,{borderLeft:o.borderLeft[e],borderRight:o.borderRight[e]}))})),i},xU=function(t,e,n){var r,i={};yU.forEach(n,(function(n){for(var a,o,s=t.parent(n);s;){if((a=t.parent(s))?(o=i[a],i[a]=s):(o=r,r=s),o&&o!==s)return void e.setEdge(o,s);s=a}}))},kU=XI.Graph,CU=JY,TU=function(t){var e=CU.maxRank(t),n=EU(t,mU.range(1,e+1),"inEdges"),r=EU(t,mU.range(e-1,-1,-1),"outEdges"),i=vU(t);OU(t,i);for(var a,o=Number.POSITIVE_INFINITY,s=0,c=0;c<4;++s,++c){SU(s%2?n:r,s%4>=2),i=CU.buildLayerMatrix(t);var l=bU(t,i);lo)&&LU(n,e,s)}))}))}return AU.reduce(e,(function(e,n){var i,a=-1,o=0;return AU.forEach(n,(function(s,c){if("border"===t.node(s).dummy){var l=t.predecessors(s);l.length&&(i=t.node(l[0]).order,r(n,o,c,a,i),o=c,a=i)}r(n,o,n.length,i,e.length)})),n})),n}function LU(t,e,n){if(e>n){var r=e;e=n,n=r}var i=t[e];i||(t[e]=i={}),i[n]=!0}function RU(t,e,n){if(e>n){var r=e;e=n,n=r}return AU.has(t[e],n)}function IU(t,e,n,r){var i={},a={},o={};return AU.forEach(e,(function(t){AU.forEach(t,(function(t,e){i[t]=t,a[t]=t,o[t]=e}))})),AU.forEach(e,(function(t){var e=-1;AU.forEach(t,(function(t){var s=r(t);if(s.length)for(var c=((s=AU.sortBy(s,(function(t){return o[t]}))).length-1)/2,l=Math.floor(c),u=Math.ceil(c);l<=u;++l){var h=s[l];a[t]===t&&e0}var A$=function(t,e,n,r){var i,a,o,s,c,l,u,h,d,f,p,g,y;if(i=e.y-t.y,o=t.x-e.x,c=e.x*t.y-t.x*e.y,d=i*n.x+o*n.y+c,f=i*r.x+o*r.y+c,0!==d&&0!==f&&O$(d,f))return;if(a=r.y-n.y,s=n.x-r.x,l=r.x*n.y-n.x*r.y,u=a*t.x+s*t.y+l,h=a*e.x+s*e.y+l,0!==u&&0!==h&&O$(u,h))return;if(0===(p=i*s-a*o))return;return g=Math.abs(p/2),{x:(y=o*l-s*c)<0?(y-g)/p:(y+g)/p,y:(y=a*c-i*l)<0?(y-g)/p:(y+g)/p}},M$=function(t,e,n){var r=t.x,i=t.y,a=[],o=Number.POSITIVE_INFINITY,s=Number.POSITIVE_INFINITY;e.forEach((function(t){o=Math.min(o,t.x),s=Math.min(s,t.y)}));for(var c=r-t.width/2-o,l=i-t.height/2-s,u=0;u1&&a.sort((function(t,e){var r=t.x-n.x,i=t.y-n.y,a=Math.sqrt(r*r+i*i),o=e.x-n.x,s=e.y-n.y,c=Math.sqrt(o*o+s*s);return aMath.abs(o)*l?(s<0&&(l=-l),n=0===s?0:l*o/s,r=l):(o<0&&(c=-c),n=c,r=0===o?0:c*s/o);return{x:i+n,y:a+r}};var j$,N$={node:C$,circle:S$,ellipse:T$,polygon:M$,rect:D$};try{j$={defaults:lF,each:qj,isFunction:IS,isPlainObject:oP,pick:sY,has:tL,range:fY,uniqueId:DY}}catch(HG){}j$||(j$=window._);var B$,L$=j$;if(!B$)try{B$=XE}catch(HG){}B$||(B$=window.d3);var R$=L$,I$={isSubgraph:function(t,e){return!!t.children(e).length},edgeToId:function(t){return P$(t.v)+":"+P$(t.w)+":"+P$(t.name)},applyStyle:function(t,e){e&&t.attr("style",e)},applyClass:function(t,e,n){e&&t.attr("class",e).attr("class",n+" "+t.attr("class"))},applyTransition:function(t,e){var n=e.graph();if(R$.isPlainObject(n)){var r=n.transition;if(R$.isFunction(r))return r(t)}return t}};var F$=/:/g;function P$(t){return t?String(t).replace(F$,"\\:"):""}var Y$=I$;var z$=I$,U$=function(t,e){var n=t.append("foreignObject").attr("width","100000"),r=n.append("xhtml:div");r.attr("xmlns","http://www.w3.org/1999/xhtml");var i=e.label;switch(typeof i){case"function":r.insert(i);break;case"object":r.insert((function(){return i}));break;default:r.html(i)}z$.applyStyle(r,e.labelStyle),r.style("display","inline-block"),r.style("white-space","nowrap");var a=r.node().getBoundingClientRect();return n.attr("width",a.width).attr("height",a.height),n};var $$=I$;var W$=function(t,e){for(var n=t.append("text"),r=function(t){for(var e,n="",r=!1,i=0;i1?n-1:0),i=1;i/gm),Tq=HW(/^data-[\-\w.\u00B7-\uFFFF]/),Eq=HW(/^aria-[\-\w]+$/),Sq=HW(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Oq=HW(/^(?:\w+script|data):/i),Aq=HW(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Mq="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};function Dq(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e0&&void 0!==arguments[0]?arguments[0]:jq(),n=function(e){return t(e)};if(n.version="2.3.0",n.removed=[],!e||!e.document||9!==e.document.nodeType)return n.isSupported=!1,n;var r=e.document,i=e.document,a=e.DocumentFragment,o=e.HTMLTemplateElement,s=e.Node,c=e.Element,l=e.NodeFilter,u=e.NamedNodeMap,h=void 0===u?e.NamedNodeMap||e.MozNamedAttrMap:u,d=e.Text,f=e.Comment,p=e.DOMParser,g=e.trustedTypes,y=c.prototype,m=hq(y,"cloneNode"),v=hq(y,"nextSibling"),b=hq(y,"childNodes"),_=hq(y,"parentNode");if("function"==typeof o){var w=i.createElement("template");w.content&&w.content.ownerDocument&&(i=w.content.ownerDocument)}var x=Nq(g,r),k=x&&et?x.createHTML(""):"",C=i,T=C.implementation,E=C.createNodeIterator,S=C.createDocumentFragment,O=C.getElementsByTagName,A=r.importNode,M={};try{M=uq(i).documentMode?i.documentMode:{}}catch(Lt){}var D={};n.isSupported="function"==typeof _&&T&&void 0!==T.createHTMLDocument&&9!==M;var j=kq,N=Cq,B=Tq,L=Eq,R=Oq,I=Aq,F=Sq,P=null,Y=lq({},[].concat(Dq(dq),Dq(fq),Dq(pq),Dq(yq),Dq(vq))),z=null,U=lq({},[].concat(Dq(bq),Dq(_q),Dq(wq),Dq(xq))),$=null,W=null,q=!0,H=!0,V=!1,G=!1,X=!1,Z=!1,Q=!1,K=!1,J=!1,tt=!0,et=!1,nt=!0,rt=!0,it=!1,at={},ot=lq({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),st=null,ct=lq({},["audio","video","img","source","image","track"]),lt=null,ut=lq({},["alt","class","for","id","label","name","pattern","placeholder","summary","title","value","style","xmlns"]),ht="http://www.w3.org/1998/Math/MathML",dt="http://www.w3.org/2000/svg",ft="http://www.w3.org/1999/xhtml",pt=ft,gt=!1,yt=null,mt=i.createElement("form"),vt=function(t){yt&&yt===t||(t&&"object"===(void 0===t?"undefined":Mq(t))||(t={}),t=uq(t),P="ALLOWED_TAGS"in t?lq({},t.ALLOWED_TAGS):Y,z="ALLOWED_ATTR"in t?lq({},t.ALLOWED_ATTR):U,lt="ADD_URI_SAFE_ATTR"in t?lq(uq(ut),t.ADD_URI_SAFE_ATTR):ut,st="ADD_DATA_URI_TAGS"in t?lq(uq(ct),t.ADD_DATA_URI_TAGS):ct,$="FORBID_TAGS"in t?lq({},t.FORBID_TAGS):{},W="FORBID_ATTR"in t?lq({},t.FORBID_ATTR):{},at="USE_PROFILES"in t&&t.USE_PROFILES,q=!1!==t.ALLOW_ARIA_ATTR,H=!1!==t.ALLOW_DATA_ATTR,V=t.ALLOW_UNKNOWN_PROTOCOLS||!1,G=t.SAFE_FOR_TEMPLATES||!1,X=t.WHOLE_DOCUMENT||!1,K=t.RETURN_DOM||!1,J=t.RETURN_DOM_FRAGMENT||!1,tt=!1!==t.RETURN_DOM_IMPORT,et=t.RETURN_TRUSTED_TYPE||!1,Q=t.FORCE_BODY||!1,nt=!1!==t.SANITIZE_DOM,rt=!1!==t.KEEP_CONTENT,it=t.IN_PLACE||!1,F=t.ALLOWED_URI_REGEXP||F,pt=t.NAMESPACE||ft,G&&(H=!1),J&&(K=!0),at&&(P=lq({},[].concat(Dq(vq))),z=[],!0===at.html&&(lq(P,dq),lq(z,bq)),!0===at.svg&&(lq(P,fq),lq(z,_q),lq(z,xq)),!0===at.svgFilters&&(lq(P,pq),lq(z,_q),lq(z,xq)),!0===at.mathMl&&(lq(P,yq),lq(z,wq),lq(z,xq))),t.ADD_TAGS&&(P===Y&&(P=uq(P)),lq(P,t.ADD_TAGS)),t.ADD_ATTR&&(z===U&&(z=uq(z)),lq(z,t.ADD_ATTR)),t.ADD_URI_SAFE_ATTR&&lq(lt,t.ADD_URI_SAFE_ATTR),rt&&(P["#text"]=!0),X&&lq(P,["html","head","body"]),P.table&&(lq(P,["tbody"]),delete $.tbody),qW&&qW(t),yt=t)},bt=lq({},["mi","mo","mn","ms","mtext"]),_t=lq({},["foreignobject","desc","title","annotation-xml"]),wt=lq({},fq);lq(wt,pq),lq(wt,gq);var xt=lq({},yq);lq(xt,mq);var kt=function(t){var e=_(t);e&&e.tagName||(e={namespaceURI:ft,tagName:"template"});var n=eq(t.tagName),r=eq(e.tagName);if(t.namespaceURI===dt)return e.namespaceURI===ft?"svg"===n:e.namespaceURI===ht?"svg"===n&&("annotation-xml"===r||bt[r]):Boolean(wt[n]);if(t.namespaceURI===ht)return e.namespaceURI===ft?"math"===n:e.namespaceURI===dt?"math"===n&&_t[r]:Boolean(xt[n]);if(t.namespaceURI===ft){if(e.namespaceURI===dt&&!_t[r])return!1;if(e.namespaceURI===ht&&!bt[r])return!1;var i=lq({},["title","style","font","a","script"]);return!xt[n]&&(i[n]||!wt[n])}return!1},Ct=function(t){tq(n.removed,{element:t});try{t.parentNode.removeChild(t)}catch(Lt){try{t.outerHTML=k}catch(e){t.remove()}}},Tt=function(t,e){try{tq(n.removed,{attribute:e.getAttributeNode(t),from:e})}catch(Lt){tq(n.removed,{attribute:null,from:e})}if(e.removeAttribute(t),"is"===t&&!z[t])if(K||J)try{Ct(e)}catch(Lt){}else try{e.setAttribute(t,"")}catch(Lt){}},Et=function(t){var e=void 0,n=void 0;if(Q)t=""+t;else{var r=nq(t,/^[\r\n\t ]+/);n=r&&r[0]}var a=x?x.createHTML(t):t;if(pt===ft)try{e=(new p).parseFromString(a,"text/html")}catch(Lt){}if(!e||!e.documentElement){e=T.createDocument(pt,"template",null);try{e.documentElement.innerHTML=gt?"":a}catch(Lt){}}var o=e.body||e.documentElement;return t&&n&&o.insertBefore(i.createTextNode(n),o.childNodes[0]||null),pt===ft?O.call(e,X?"html":"body")[0]:X?e.documentElement:o},St=function(t){return E.call(t.ownerDocument||t,t,l.SHOW_ELEMENT|l.SHOW_COMMENT|l.SHOW_TEXT,null,!1)},Ot=function(t){return!(t instanceof d||t instanceof f)&&!("string"==typeof t.nodeName&&"string"==typeof t.textContent&&"function"==typeof t.removeChild&&t.attributes instanceof h&&"function"==typeof t.removeAttribute&&"function"==typeof t.setAttribute&&"string"==typeof t.namespaceURI&&"function"==typeof t.insertBefore)},At=function(t){return"object"===(void 0===s?"undefined":Mq(s))?t instanceof s:t&&"object"===(void 0===t?"undefined":Mq(t))&&"number"==typeof t.nodeType&&"string"==typeof t.nodeName},Mt=function(t,e,r){D[t]&&KW(D[t],(function(t){t.call(n,e,r,yt)}))},Dt=function(t){var e=void 0;if(Mt("beforeSanitizeElements",t,null),Ot(t))return Ct(t),!0;if(nq(t.nodeName,/[\u0080-\uFFFF]/))return Ct(t),!0;var r=eq(t.nodeName);if(Mt("uponSanitizeElement",t,{tagName:r,allowedTags:P}),!At(t.firstElementChild)&&(!At(t.content)||!At(t.content.firstElementChild))&&oq(/<[/\w]/g,t.innerHTML)&&oq(/<[/\w]/g,t.textContent))return Ct(t),!0;if(!P[r]||$[r]){if(rt&&!ot[r]){var i=_(t)||t.parentNode,a=b(t)||t.childNodes;if(a&&i)for(var o=a.length-1;o>=0;--o)i.insertBefore(m(a[o],!0),v(t))}return Ct(t),!0}return t instanceof c&&!kt(t)?(Ct(t),!0):"noscript"!==r&&"noembed"!==r||!oq(/<\/no(script|embed)/i,t.innerHTML)?(G&&3===t.nodeType&&(e=t.textContent,e=rq(e,j," "),e=rq(e,N," "),t.textContent!==e&&(tq(n.removed,{element:t.cloneNode()}),t.textContent=e)),Mt("afterSanitizeElements",t,null),!1):(Ct(t),!0)},jt=function(t,e,n){if(nt&&("id"===e||"name"===e)&&(n in i||n in mt))return!1;if(H&&!W[e]&&oq(B,e));else if(q&&oq(L,e));else{if(!z[e]||W[e])return!1;if(lt[e]);else if(oq(F,rq(n,I,"")));else if("src"!==e&&"xlink:href"!==e&&"href"!==e||"script"===t||0!==iq(n,"data:")||!st[t]){if(V&&!oq(R,rq(n,I,"")));else if(n)return!1}else;}return!0},Nt=function(t){var e=void 0,r=void 0,i=void 0,a=void 0;Mt("beforeSanitizeAttributes",t,null);var o=t.attributes;if(o){var s={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:z};for(a=o.length;a--;){var c=e=o[a],l=c.name,u=c.namespaceURI;if(r=aq(e.value),i=eq(l),s.attrName=i,s.attrValue=r,s.keepAttr=!0,s.forceKeepAttr=void 0,Mt("uponSanitizeAttribute",t,s),r=s.attrValue,!s.forceKeepAttr&&(Tt(l,t),s.keepAttr))if(oq(/\/>/i,r))Tt(l,t);else{G&&(r=rq(r,j," "),r=rq(r,N," "));var h=t.nodeName.toLowerCase();if(jt(h,i,r))try{u?t.setAttributeNS(u,l,r):t.setAttribute(l,r),JW(n.removed)}catch(Lt){}}}Mt("afterSanitizeAttributes",t,null)}},Bt=function t(e){var n=void 0,r=St(e);for(Mt("beforeSanitizeShadowDOM",e,null);n=r.nextNode();)Mt("uponSanitizeShadowNode",n,null),Dt(n)||(n.content instanceof a&&t(n.content),Nt(n));Mt("afterSanitizeShadowDOM",e,null)};return n.sanitize=function(t,i){var o=void 0,c=void 0,l=void 0,u=void 0,h=void 0;if((gt=!t)&&(t="\x3c!--\x3e"),"string"!=typeof t&&!At(t)){if("function"!=typeof t.toString)throw sq("toString is not a function");if("string"!=typeof(t=t.toString()))throw sq("dirty is not a string, aborting")}if(!n.isSupported){if("object"===Mq(e.toStaticHTML)||"function"==typeof e.toStaticHTML){if("string"==typeof t)return e.toStaticHTML(t);if(At(t))return e.toStaticHTML(t.outerHTML)}return t}if(Z||vt(i),n.removed=[],"string"==typeof t&&(it=!1),it);else if(t instanceof s)1===(c=(o=Et("\x3c!----\x3e")).ownerDocument.importNode(t,!0)).nodeType&&"BODY"===c.nodeName||"HTML"===c.nodeName?o=c:o.appendChild(c);else{if(!K&&!G&&!X&&-1===t.indexOf("<"))return x&&et?x.createHTML(t):t;if(!(o=Et(t)))return K?null:k}o&&Q&&Ct(o.firstChild);for(var d=St(it?t:o);l=d.nextNode();)3===l.nodeType&&l===u||Dt(l)||(l.content instanceof a&&Bt(l.content),Nt(l),u=l);if(u=null,it)return t;if(K){if(J)for(h=S.call(o.ownerDocument);o.firstChild;)h.appendChild(o.firstChild);else h=o;return tt&&(h=A.call(r,h,!0)),h}var f=X?o.outerHTML:o.innerHTML;return G&&(f=rq(f,j," "),f=rq(f,N," ")),x&&et?x.createHTML(f):f},n.setConfig=function(t){vt(t),Z=!0},n.clearConfig=function(){yt=null,Z=!1},n.isValidAttribute=function(t,e,n){yt||vt({});var r=eq(t),i=eq(e);return jt(r,i,n)},n.addHook=function(t,e){"function"==typeof e&&(D[t]=D[t]||[],tq(D[t],e))},n.removeHook=function(t){D[t]&&JW(D[t])},n.removeHooks=function(t){D[t]&&(D[t]=[])},n.removeAllHooks=function(){D={}},n}(),Lq=ma(Object.freeze({__proto__:null,[Symbol.toStringTag]:"Module",default:Bq})),Rq={},Iq={},Fq={},Pq={},Yq={};Object.defineProperty(Yq,"__esModule",{value:!0});var zq={min:{r:0,g:0,b:0,s:0,l:0,a:0},max:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},clamp:{r:function(t){return t>=255?255:t<0?0:t},g:function(t){return t>=255?255:t<0?0:t},b:function(t){return t>=255?255:t<0?0:t},h:function(t){return t%360},s:function(t){return t>=100?100:t<0?0:t},l:function(t){return t>=100?100:t<0?0:t},a:function(t){return t>=1?1:t<0?0:t}},toLinear:function(t){var e=t/255;return t>.03928?Math.pow((e+.055)/1.055,2.4):e/12.92},hue2rgb:function(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t},hsl2rgb:function(t,e){var n=t.h,r=t.s,i=t.l;if(!r)return 2.55*i;n/=360,r/=100;var a=(i/=100)<.5?i*(1+r):i+r-i*r,o=2*i-a;switch(e){case"r":return 255*zq.hue2rgb(o,a,n+1/3);case"g":return 255*zq.hue2rgb(o,a,n);case"b":return 255*zq.hue2rgb(o,a,n-1/3)}},rgb2hsl:function(t,e){var n=t.r,r=t.g,i=t.b;n/=255,r/=255,i/=255;var a=Math.max(n,r,i),o=Math.min(n,r,i),s=(a+o)/2;if("l"===e)return 100*s;if(a===o)return 0;var c=a-o;if("s"===e)return 100*(s>.5?c/(2-a-o):c/(a+o));switch(a){case n:return 60*((r-i)/c+(rn?Math.min(e,Math.max(n,t)):Math.min(n,Math.max(e,t))},round:function(t){return Math.round(1e10*t)/1e10}};Uq.default=$q;var Wq={};Object.defineProperty(Wq,"__esModule",{value:!0});var qq={dec2hex:function(t){var e=Math.round(t).toString(16);return e.length>1?e:"0"+e}};Wq.default=qq,Object.defineProperty(Pq,"__esModule",{value:!0});var Hq=Uq,Vq=Wq,Gq={channel:Yq.default,lang:Hq.default,unit:Vq.default};Pq.default=Gq;var Xq={},Zq={},Qq={};Object.defineProperty(Qq,"__esModule",{value:!0});var Kq=function(){function t(){this.type=0}return t.prototype.get=function(){return this.type},t.prototype.set=function(t){if(this.type&&this.type!==t)throw new Error("Cannot change both RGB and HSL channels at the same time");this.type=t},t.prototype.reset=function(){this.type=0},t.prototype.is=function(t){return this.type===t},t}();Qq.default=Kq,Object.defineProperty(Zq,"__esModule",{value:!0});var Jq=Pq,tH=Qq,eH=function(){function t(t,e){this.color=e,this.changed=!1,this.data=t,this.type=new tH.default}return t.prototype.set=function(t,e){return this.color=e,this.changed=!1,this.data=t,this.type.type=0,this},t.prototype._ensureHSL=function(){var t=this.data,e=t.h,n=t.s,r=t.l;void 0===e&&(t.h=Jq.default.channel.rgb2hsl(t,"h")),void 0===n&&(t.s=Jq.default.channel.rgb2hsl(t,"s")),void 0===r&&(t.l=Jq.default.channel.rgb2hsl(t,"l"))},t.prototype._ensureRGB=function(){var t=this.data,e=t.r,n=t.g,r=t.b;void 0===e&&(t.r=Jq.default.channel.hsl2rgb(t,"r")),void 0===n&&(t.g=Jq.default.channel.hsl2rgb(t,"g")),void 0===r&&(t.b=Jq.default.channel.hsl2rgb(t,"b"))},Object.defineProperty(t.prototype,"r",{get:function(){var t=this.data,e=t.r;return this.type.is(2)||void 0===e?(this._ensureHSL(),Jq.default.channel.hsl2rgb(t,"r")):e},set:function(t){this.type.set(1),this.changed=!0,this.data.r=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"g",{get:function(){var t=this.data,e=t.g;return this.type.is(2)||void 0===e?(this._ensureHSL(),Jq.default.channel.hsl2rgb(t,"g")):e},set:function(t){this.type.set(1),this.changed=!0,this.data.g=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"b",{get:function(){var t=this.data,e=t.b;return this.type.is(2)||void 0===e?(this._ensureHSL(),Jq.default.channel.hsl2rgb(t,"b")):e},set:function(t){this.type.set(1),this.changed=!0,this.data.b=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"h",{get:function(){var t=this.data,e=t.h;return this.type.is(1)||void 0===e?(this._ensureRGB(),Jq.default.channel.rgb2hsl(t,"h")):e},set:function(t){this.type.set(2),this.changed=!0,this.data.h=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"s",{get:function(){var t=this.data,e=t.s;return this.type.is(1)||void 0===e?(this._ensureRGB(),Jq.default.channel.rgb2hsl(t,"s")):e},set:function(t){this.type.set(2),this.changed=!0,this.data.s=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"l",{get:function(){var t=this.data,e=t.l;return this.type.is(1)||void 0===e?(this._ensureRGB(),Jq.default.channel.rgb2hsl(t,"l")):e},set:function(t){this.type.set(2),this.changed=!0,this.data.l=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"a",{get:function(){return this.data.a},set:function(t){this.changed=!0,this.data.a=t},enumerable:!0,configurable:!0}),t}();Zq.default=eH,Object.defineProperty(Xq,"__esModule",{value:!0});var nH=new Zq.default({r:0,g:0,b:0,a:0},"transparent");Xq.default=nH;var rH={},iH={},aH={};Object.defineProperty(aH,"__esModule",{value:!0});var oH=Pq,sH={};aH.DEC2HEX=sH;for(var cH=0;cH<=255;cH++)sH[cH]=oH.default.unit.dec2hex(cH);Object.defineProperty(iH,"__esModule",{value:!0});var lH=Xq,uH=aH,hH={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:function(t){if(35===t.charCodeAt(0)){var e=t.match(hH.re);if(e){var n=e[1],r=parseInt(n,16),i=n.length,a=i%4==0,o=i>4,s=o?1:17,c=o?8:4,l=a?0:-1,u=o?255:15;return lH.default.set({r:(r>>c*(l+3)&u)*s,g:(r>>c*(l+2)&u)*s,b:(r>>c*(l+1)&u)*s,a:a?(r&u)*s/255:1},t)}}},stringify:function(t){var e=t.r,n=t.g,r=t.b,i=t.a;return i<1?"#"+uH.DEC2HEX[Math.round(e)]+uH.DEC2HEX[Math.round(n)]+uH.DEC2HEX[Math.round(r)]+uH.DEC2HEX[Math.round(255*i)]:"#"+uH.DEC2HEX[Math.round(e)]+uH.DEC2HEX[Math.round(n)]+uH.DEC2HEX[Math.round(r)]}};iH.default=hH;var dH={};Object.defineProperty(dH,"__esModule",{value:!0});var fH=iH,pH={colors:{aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyanaqua:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",transparent:"#00000000",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},parse:function(t){t=t.toLowerCase();var e=pH.colors[t];if(e)return fH.default.parse(e)},stringify:function(t){var e=fH.default.stringify(t);for(var n in pH.colors)if(pH.colors[n]===e)return n}};dH.default=pH;var gH={};Object.defineProperty(gH,"__esModule",{value:!0});var yH=Pq,mH=Xq,vH={re:/^rgba?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?)))?\s*?\)$/i,parse:function(t){var e=t.charCodeAt(0);if(114===e||82===e){var n=t.match(vH.re);if(n){var r=n[1],i=n[2],a=n[3],o=n[4],s=n[5],c=n[6],l=n[7],u=n[8];return mH.default.set({r:yH.default.channel.clamp.r(i?2.55*parseFloat(r):parseFloat(r)),g:yH.default.channel.clamp.g(o?2.55*parseFloat(a):parseFloat(a)),b:yH.default.channel.clamp.b(c?2.55*parseFloat(s):parseFloat(s)),a:l?yH.default.channel.clamp.a(u?parseFloat(l)/100:parseFloat(l)):1},t)}}},stringify:function(t){var e=t.r,n=t.g,r=t.b,i=t.a;return i<1?"rgba("+yH.default.lang.round(e)+", "+yH.default.lang.round(n)+", "+yH.default.lang.round(r)+", "+yH.default.lang.round(i)+")":"rgb("+yH.default.lang.round(e)+", "+yH.default.lang.round(n)+", "+yH.default.lang.round(r)+")"}};gH.default=vH;var bH={};Object.defineProperty(bH,"__esModule",{value:!0});var _H=Pq,wH=Xq,xH={re:/^hsla?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(?:deg|grad|rad|turn)?)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(%)?))?\s*?\)$/i,hueRe:/^(.+?)(deg|grad|rad|turn)$/i,_hue2deg:function(t){var e=t.match(xH.hueRe);if(e){var n=e[1];switch(e[2]){case"grad":return _H.default.channel.clamp.h(.9*parseFloat(n));case"rad":return _H.default.channel.clamp.h(180*parseFloat(n)/Math.PI);case"turn":return _H.default.channel.clamp.h(360*parseFloat(n))}}return _H.default.channel.clamp.h(parseFloat(t))},parse:function(t){var e=t.charCodeAt(0);if(104===e||72===e){var n=t.match(xH.re);if(n){var r=n[1],i=n[2],a=n[3],o=n[4],s=n[5];return wH.default.set({h:xH._hue2deg(r),s:_H.default.channel.clamp.s(parseFloat(i)),l:_H.default.channel.clamp.l(parseFloat(a)),a:o?_H.default.channel.clamp.a(s?parseFloat(o)/100:parseFloat(o)):1},t)}}},stringify:function(t){var e=t.h,n=t.s,r=t.l,i=t.a;return i<1?"hsla("+_H.default.lang.round(e)+", "+_H.default.lang.round(n)+"%, "+_H.default.lang.round(r)+"%, "+i+")":"hsl("+_H.default.lang.round(e)+", "+_H.default.lang.round(n)+"%, "+_H.default.lang.round(r)+"%)"}};bH.default=xH,Object.defineProperty(rH,"__esModule",{value:!0});var kH=iH,CH=dH,TH=gH,EH=bH,SH={format:{keyword:CH.default,hex:kH.default,rgb:TH.default,rgba:TH.default,hsl:EH.default,hsla:EH.default},parse:function(t){if("string"!=typeof t)return t;var e=kH.default.parse(t)||TH.default.parse(t)||EH.default.parse(t)||CH.default.parse(t);if(e)return e;throw new Error('Unsupported color format: "'+t+'"')},stringify:function(t){return!t.changed&&t.color?t.color:t.type.is(2)||void 0===t.data.r?EH.default.stringify(t):t.a<1||!Number.isInteger(t.r)||!Number.isInteger(t.g)||!Number.isInteger(t.b)?TH.default.stringify(t):kH.default.stringify(t)}};rH.default=SH;var OH={};Object.defineProperty(OH,"__esModule",{value:!0});var AH=Pq,MH=rH;OH.default=function(t,e){var n=MH.default.parse(t);for(var r in e)n[r]=AH.default.channel.clamp[r](e[r]);return MH.default.stringify(n)},Object.defineProperty(Fq,"__esModule",{value:!0});var DH=Pq,jH=Xq,NH=rH,BH=OH;Fq.default=function(t,e,n,r){if(void 0===n&&(n=0),void 0===r&&(r=1),"number"!=typeof t)return BH.default(t,{a:e});var i=jH.default.set({r:DH.default.channel.clamp.r(t),g:DH.default.channel.clamp.g(e),b:DH.default.channel.clamp.b(n),a:DH.default.channel.clamp.a(r)});return NH.default.stringify(i)};var LH={};Object.defineProperty(LH,"__esModule",{value:!0});var RH=Pq,IH=Xq,FH=rH;LH.default=function(t,e,n,r){void 0===r&&(r=1);var i=IH.default.set({h:RH.default.channel.clamp.h(t),s:RH.default.channel.clamp.s(e),l:RH.default.channel.clamp.l(n),a:RH.default.channel.clamp.a(r)});return FH.default.stringify(i)};var PH={};Object.defineProperty(PH,"__esModule",{value:!0});var YH=rH;PH.default=function(t){return YH.default.format.keyword.stringify(YH.default.parse(t))};var zH={};Object.defineProperty(zH,"__esModule",{value:!0});var UH=rH;zH.default=function(t){return UH.default.format.hex.stringify(UH.default.parse(t))};var $H={};Object.defineProperty($H,"__esModule",{value:!0});var WH=rH;$H.default=function(t){return WH.default.format.rgba.stringify(WH.default.parse(t))};var qH={};Object.defineProperty(qH,"__esModule",{value:!0});var HH=rH;qH.default=function(t){return HH.default.format.hsla.stringify(HH.default.parse(t))};var VH={};Object.defineProperty(VH,"__esModule",{value:!0});var GH=Pq,XH=rH;VH.default=function(t,e){return GH.default.lang.round(XH.default.parse(t)[e])};var ZH={};Object.defineProperty(ZH,"__esModule",{value:!0});var QH=VH;ZH.default=function(t){return QH.default(t,"r")};var KH={};Object.defineProperty(KH,"__esModule",{value:!0});var JH=VH;KH.default=function(t){return JH.default(t,"g")};var tV={};Object.defineProperty(tV,"__esModule",{value:!0});var eV=VH;tV.default=function(t){return eV.default(t,"b")};var nV={};Object.defineProperty(nV,"__esModule",{value:!0});var rV=VH;nV.default=function(t){return rV.default(t,"h")};var iV={};Object.defineProperty(iV,"__esModule",{value:!0});var aV=VH;iV.default=function(t){return aV.default(t,"s")};var oV={};Object.defineProperty(oV,"__esModule",{value:!0});var sV=VH;oV.default=function(t){return sV.default(t,"l")};var cV={};Object.defineProperty(cV,"__esModule",{value:!0});var lV=VH;cV.default=function(t){return lV.default(t,"a")};var uV={},hV={};Object.defineProperty(hV,"__esModule",{value:!0});var dV=Pq,fV=rH;hV.default=function(t){var e=fV.default.parse(t),n=e.r,r=e.g,i=e.b,a=.2126*dV.default.channel.toLinear(n)+.7152*dV.default.channel.toLinear(r)+.0722*dV.default.channel.toLinear(i);return dV.default.lang.round(a)},Object.defineProperty(uV,"__esModule",{value:!0});var pV=Pq,gV=hV;uV.default=function(t,e){var n=gV.default(t),r=gV.default(e),i=Math.max(n,r),a=Math.min(n,r),o=(i+Number.EPSILON)/(a+Number.EPSILON);return pV.default.lang.round(pV.default.lang.clamp(o,1,10))};var yV={},mV={};Object.defineProperty(mV,"__esModule",{value:!0});var vV=hV;mV.default=function(t){return vV.default(t)>=.5},Object.defineProperty(yV,"__esModule",{value:!0});var bV=mV;yV.default=function(t){return!bV.default(t)};var _V={};Object.defineProperty(_V,"__esModule",{value:!0});var wV=rH;_V.default=function(t){try{return wV.default.parse(t),!0}catch(e){return!1}};var xV={},kV={};Object.defineProperty(kV,"__esModule",{value:!0});var CV=Pq,TV=rH;kV.default=function(t,e,n){var r=TV.default.parse(t),i=r[e],a=CV.default.channel.clamp[e](i+n);return i!==a&&(r[e]=a),TV.default.stringify(r)},Object.defineProperty(xV,"__esModule",{value:!0});var EV=kV;xV.default=function(t,e){return EV.default(t,"s",e)};var SV={};Object.defineProperty(SV,"__esModule",{value:!0});var OV=kV;SV.default=function(t,e){return OV.default(t,"s",-e)};var AV={};Object.defineProperty(AV,"__esModule",{value:!0});var MV=kV;AV.default=function(t,e){return MV.default(t,"l",e)};var DV={};Object.defineProperty(DV,"__esModule",{value:!0});var jV=kV;DV.default=function(t,e){return jV.default(t,"l",-e)};var NV={};Object.defineProperty(NV,"__esModule",{value:!0});var BV=kV;NV.default=function(t,e){return BV.default(t,"a",e)};var LV={};Object.defineProperty(LV,"__esModule",{value:!0});var RV=kV;LV.default=function(t,e){return RV.default(t,"a",-e)};var IV={};Object.defineProperty(IV,"__esModule",{value:!0});var FV=kV;IV.default=function(t){return FV.default(t,"h",180)};var PV={};Object.defineProperty(PV,"__esModule",{value:!0});var YV=OH;PV.default=function(t){return YV.default(t,{s:0})};var zV={};Object.defineProperty(zV,"__esModule",{value:!0});var UV=rH,$V=OH;zV.default=function(t,e){var n=UV.default.parse(t),r={};for(var i in e)e[i]&&(r[i]=n[i]+e[i]);return $V.default(t,r)};var WV={},qV={};Object.defineProperty(qV,"__esModule",{value:!0});var HV=rH,VV=Fq;qV.default=function(t,e,n){void 0===n&&(n=50);var r=HV.default.parse(t),i=r.r,a=r.g,o=r.b,s=r.a,c=HV.default.parse(e),l=c.r,u=c.g,h=c.b,d=c.a,f=n/100,p=2*f-1,g=s-d,y=((p*g==-1?p:(p+g)/(1+p*g))+1)/2,m=1-y,v=i*y+l*m,b=a*y+u*m,_=o*y+h*m,w=s*f+d*(1-f);return VV.default(v,b,_,w)},Object.defineProperty(WV,"__esModule",{value:!0});var GV=rH,XV=qV;WV.default=function(t,e){void 0===e&&(e=100);var n=GV.default.parse(t);return n.r=255-n.r,n.g=255-n.g,n.b=255-n.b,XV.default(n,t,e)};var ZV={};Object.defineProperty(ZV,"__esModule",{value:!0});var QV=Pq,KV=rH,JV=zV;ZV.default=function(t,e){var n,r,i,a=KV.default.parse(t),o={};for(var s in e)o[s]=(n=a[s],r=e[s],i=QV.default.channel.max[s],r>0?(i-n)*r/100:n*r/100);return JV.default(t,o)},Object.defineProperty(Iq,"__esModule",{value:!0});var tG=Fq;Iq.hex=tG.default;var eG=Fq;Iq.rgb=eG.default;var nG=Fq;Iq.rgba=nG.default;var rG=LH;Iq.hsl=rG.default;var iG=LH;Iq.hsla=iG.default;var aG=PH;Iq.toKeyword=aG.default;var oG=zH;Iq.toHex=oG.default;var sG=$H;Iq.toRgba=sG.default;var cG=qH;Iq.toHsla=cG.default;var lG=VH;Iq.channel=lG.default;var uG=ZH;Iq.red=uG.default;var hG=KH;Iq.green=hG.default;var dG=tV;Iq.blue=dG.default;var fG=nV;Iq.hue=fG.default;var pG=iV;Iq.saturation=pG.default;var gG=oV;Iq.lightness=gG.default;var yG=cV;Iq.alpha=yG.default;var mG=cV;Iq.opacity=mG.default;var vG=uV;Iq.contrast=vG.default;var bG=hV;Iq.luminance=bG.default;var _G=yV;Iq.isDark=_G.default;var wG=mV;Iq.isLight=wG.default;var xG=_V;Iq.isValid=xG.default;var kG=xV;Iq.saturate=kG.default;var CG=SV;Iq.desaturate=CG.default;var TG=AV;Iq.lighten=TG.default;var EG=DV;Iq.darken=EG.default;var SG=NV;Iq.opacify=SG.default;var OG=NV;Iq.fadeIn=OG.default;var AG=LV;Iq.transparentize=AG.default;var MG=LV;Iq.fadeOut=MG.default;var DG=IV;Iq.complement=DG.default;var jG=PV;Iq.grayscale=jG.default;var NG=zV;Iq.adjust=NG.default;var BG=OH;Iq.change=BG.default;var LG=WV;Iq.invert=LG.default;var RG=qV;Iq.mix=RG.default;var IG=ZV;Iq.scale=IG.default,function(t){Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}(Iq)}(Rq);var FG={exports:{}};!function(t,e){t.exports=function(){var e,n;function r(){return e.apply(null,arguments)}function i(t){return t instanceof Array||"[object Array]"===Object.prototype.toString.call(t)}function a(t){return null!=t&&"[object Object]"===Object.prototype.toString.call(t)}function o(t){return void 0===t}function s(t){return"number"==typeof t||"[object Number]"===Object.prototype.toString.call(t)}function c(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function l(t,e){var n,r=[];for(n=0;n>>0,r=0;rCt(t)?(a=t+1,s-Ct(t)):(a=t,s),{year:a,dayOfYear:o}}function $t(t,e,n){var r,i,a=zt(t.year(),e,n),o=Math.floor((t.dayOfYear()-a-1)/7)+1;return o<1?r=o+Wt(i=t.year()-1,e,n):o>Wt(t.year(),e,n)?(r=o-Wt(t.year(),e,n),i=t.year()+1):(i=t.year(),r=o),{week:r,year:i}}function Wt(t,e,n){var r=zt(t,e,n),i=zt(t+1,e,n);return(Ct(t)-r+i)/7}function qt(t,e){return t.slice(e,7).concat(t.slice(0,e))}$("w",["ww",2],"wo","week"),$("W",["WW",2],"Wo","isoWeek"),N("week","w"),N("isoWeek","W"),I("week",5),I("isoWeek",5),lt("w",Q),lt("ww",Q,V),lt("W",Q),lt("WW",Q,V),pt(["w","ww","W","WW"],(function(t,e,n,r){e[r.substr(0,1)]=x(t)})),$("d",0,"do","day"),$("dd",0,0,(function(t){return this.localeData().weekdaysMin(this,t)})),$("ddd",0,0,(function(t){return this.localeData().weekdaysShort(this,t)})),$("dddd",0,0,(function(t){return this.localeData().weekdays(this,t)})),$("e",0,0,"weekday"),$("E",0,0,"isoWeekday"),N("day","d"),N("weekday","e"),N("isoWeekday","E"),I("day",11),I("weekday",11),I("isoWeekday",11),lt("d",Q),lt("e",Q),lt("E",Q),lt("dd",(function(t,e){return e.weekdaysMinRegex(t)})),lt("ddd",(function(t,e){return e.weekdaysShortRegex(t)})),lt("dddd",(function(t,e){return e.weekdaysRegex(t)})),pt(["dd","ddd","dddd"],(function(t,e,n,r){var i=n._locale.weekdaysParse(t,r,n._strict);null!=i?e.d=i:f(n).invalidWeekday=t})),pt(["d","e","E"],(function(t,e,n,r){e[r]=x(t)}));var Ht="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Vt="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Gt="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),Xt=st,Zt=st,Qt=st;function Kt(){function t(t,e){return e.length-t.length}var e,n,r,i,a,o=[],s=[],c=[],l=[];for(e=0;e<7;e++)n=d([2e3,1]).day(e),r=this.weekdaysMin(n,""),i=this.weekdaysShort(n,""),a=this.weekdays(n,""),o.push(r),s.push(i),c.push(a),l.push(r),l.push(i),l.push(a);for(o.sort(t),s.sort(t),c.sort(t),l.sort(t),e=0;e<7;e++)s[e]=ht(s[e]),c[e]=ht(c[e]),l[e]=ht(l[e]);this._weekdaysRegex=new RegExp("^("+l.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+c.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+o.join("|")+")","i")}function Jt(){return this.hours()%12||12}function te(t,e){$(t,0,0,(function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)}))}function ee(t,e){return e._meridiemParse}$("H",["HH",2],0,"hour"),$("h",["hh",2],0,Jt),$("k",["kk",2],0,(function(){return this.hours()||24})),$("hmm",0,0,(function(){return""+Jt.apply(this)+F(this.minutes(),2)})),$("hmmss",0,0,(function(){return""+Jt.apply(this)+F(this.minutes(),2)+F(this.seconds(),2)})),$("Hmm",0,0,(function(){return""+this.hours()+F(this.minutes(),2)})),$("Hmmss",0,0,(function(){return""+this.hours()+F(this.minutes(),2)+F(this.seconds(),2)})),te("a",!0),te("A",!1),N("hour","h"),I("hour",13),lt("a",ee),lt("A",ee),lt("H",Q),lt("h",Q),lt("k",Q),lt("HH",Q,V),lt("hh",Q,V),lt("kk",Q,V),lt("hmm",K),lt("hmmss",J),lt("Hmm",K),lt("Hmmss",J),ft(["H","HH"],vt),ft(["k","kk"],(function(t,e,n){var r=x(t);e[vt]=24===r?0:r})),ft(["a","A"],(function(t,e,n){n._isPm=n._locale.isPM(t),n._meridiem=t})),ft(["h","hh"],(function(t,e,n){e[vt]=x(t),f(n).bigHour=!0})),ft("hmm",(function(t,e,n){var r=t.length-2;e[vt]=x(t.substr(0,r)),e[bt]=x(t.substr(r)),f(n).bigHour=!0})),ft("hmmss",(function(t,e,n){var r=t.length-4,i=t.length-2;e[vt]=x(t.substr(0,r)),e[bt]=x(t.substr(r,2)),e[_t]=x(t.substr(i)),f(n).bigHour=!0})),ft("Hmm",(function(t,e,n){var r=t.length-2;e[vt]=x(t.substr(0,r)),e[bt]=x(t.substr(r))})),ft("Hmmss",(function(t,e,n){var r=t.length-4,i=t.length-2;e[vt]=x(t.substr(0,r)),e[bt]=x(t.substr(r,2)),e[_t]=x(t.substr(i))}));var ne,re=Ot("Hours",!0),ie={calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},longDateFormat:{LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:/\d{1,2}/,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},months:Nt,monthsShort:Bt,week:{dow:0,doy:6},weekdays:Ht,weekdaysMin:Gt,weekdaysShort:Vt,meridiemParse:/[ap]\.?m?\.?/i},ae={},oe={};function se(t){return t?t.toLowerCase().replace("_","-"):t}function ce(e){var n=null;if(!ae[e]&&t&&t.exports)try{n=ne._abbr,va("./locale/"+e),le(n)}catch(r){}return ae[e]}function le(t,e){var n;return t&&((n=o(e)?he(t):ue(t,e))?ne=n:"undefined"!=typeof console&&console.warn&&console.warn("Locale "+t+" not found. Did you forget to load it?")),ne._abbr}function ue(t,e){if(null===e)return delete ae[t],null;var n,r=ie;if(e.abbr=t,null!=ae[t])O("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),r=ae[t]._config;else if(null!=e.parentLocale)if(null!=ae[e.parentLocale])r=ae[e.parentLocale]._config;else{if(null==(n=ce(e.parentLocale)))return oe[e.parentLocale]||(oe[e.parentLocale]=[]),oe[e.parentLocale].push({name:t,config:e}),null;r=n._config}return ae[t]=new D(M(r,e)),oe[t]&&oe[t].forEach((function(t){ue(t.name,t.config)})),le(t),ae[t]}function he(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return ne;if(!i(t)){if(e=ce(t))return e;t=[t]}return function(t){for(var e,n,r,i,a=0;a=e&&k(i,n,!0)>=e-1)break;e--}a++}return ne}(t)}function de(t){var e,n=t._a;return n&&-2===f(t).overflow&&(e=n[yt]<0||11Dt(n[gt],n[yt])?mt:n[vt]<0||24Wt(n,a,o)?f(t)._overflowWeeks=!0:null!=c?f(t)._overflowWeekday=!0:(s=Ut(n,r,i,a,o),t._a[gt]=s.year,t._dayOfYear=s.dayOfYear)}(t),null!=t._dayOfYear&&(o=fe(t._a[gt],i[gt]),(t._dayOfYear>Ct(o)||0===t._dayOfYear)&&(f(t)._overflowDayOfYear=!0),n=Yt(o,0,t._dayOfYear),t._a[yt]=n.getUTCMonth(),t._a[mt]=n.getUTCDate()),e=0;e<3&&null==t._a[e];++e)t._a[e]=s[e]=i[e];for(;e<7;e++)t._a[e]=s[e]=null==t._a[e]?2===e?1:0:t._a[e];24===t._a[vt]&&0===t._a[bt]&&0===t._a[_t]&&0===t._a[wt]&&(t._nextDay=!0,t._a[vt]=0),t._d=(t._useUTC?Yt:function(t,e,n,r,i,a,o){var s;return t<100&&0<=t?(s=new Date(t+400,e,n,r,i,a,o),isFinite(s.getFullYear())&&s.setFullYear(t)):s=new Date(t,e,n,r,i,a,o),s}).apply(null,s),a=t._useUTC?t._d.getUTCDay():t._d.getDay(),null!=t._tzm&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),t._nextDay&&(t._a[vt]=24),t._w&&void 0!==t._w.d&&t._w.d!==a&&(f(t).weekdayMismatch=!0)}}var ge=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,ye=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,me=/Z|[+-]\d\d(?::?\d\d)?/,ve=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/]],be=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],_e=/^\/?Date\((\-?\d+)/i;function we(t){var e,n,r,i,a,o,s=t._i,c=ge.exec(s)||ye.exec(s);if(c){for(f(t).iso=!0,e=0,n=ve.length;en.valueOf():n.valueOf()this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()},gn.isLocal=function(){return!!this.isValid()&&!this._isUTC},gn.isUtcOffset=function(){return!!this.isValid()&&this._isUTC},gn.isUtc=Ue,gn.isUTC=Ue,gn.zoneAbbr=function(){return this._isUTC?"UTC":""},gn.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""},gn.dates=T("dates accessor is deprecated. Use date instead.",ln),gn.months=T("months accessor is deprecated. Use month instead",Rt),gn.years=T("years accessor is deprecated. Use year instead",St),gn.zone=T("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",(function(t,e){return null!=t?("string"!=typeof t&&(t=-t),this.utcOffset(t,e),this):-this.utcOffset()})),gn.isDSTShifted=T("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",(function(){if(!o(this._isDSTShifted))return this._isDSTShifted;var t={};if(m(t,this),(t=Se(t))._a){var e=t._isUTC?d(t._a):Ae(t._a);this._isDSTShifted=this.isValid()&&00?E(t.characters,--t.position):0,t.column--,10===t.character&&(t.column=1,t.line--),t.character}function R(){return t.character=t.position2||Y(t.character)>3?"":" "}function H(e){for(;R();)switch(Y(t.character)){case 0:M(Z(t.position-1),e);break;case 2:M($(t.character),e);break;default:M(_(t.character),e)}return e}function V(e,n){for(;--n&&R()&&!(t.character<48||t.character>102||t.character>57&&t.character<65||t.character>70&&t.character<97););return P(e,F()+(n<6&&32==I()&&32==R()))}function G(e){for(;R();)switch(t.character){case e:return t.position;case 34:case 39:return G(34===e||39===e?e:t.character);case 40:41===e&&G(e);break;case 92:R()}return t.position}function X(e,n){for(;R()&&e+t.character!==57&&(e+t.character!==84||47!==I()););return"/*"+P(n,t.position-1)+"*"+_(47===e?e:R())}function Z(e){for(;!Y(I());)R();return P(e,t.position)}function Q(t){return U(K("",null,null,null,[""],t=z(t),0,[0],t))}function K(t,e,n,r,i,a,o,s,c){for(var l=0,u=0,h=o,d=0,f=0,p=0,g=1,y=1,m=1,v=0,b="",w=i,x=a,k=r,T=b;y;)switch(p=v,v=R()){case 34:case 39:case 91:case 40:T+=$(v);break;case 9:case 10:case 13:case 32:T+=q(p);break;case 92:T+=V(F()-1,7);continue;case 47:switch(I()){case 42:case 47:M(tt(X(R(),F()),e,n),c);break;default:T+="/"}break;case 123*g:s[l++]=O(T)*m;case 125*g:case 59:case 0:switch(v){case 0:case 125:y=0;case 59+u:f>0&&O(T)-h&&M(f>32?et(T+";",r,n,h-1):et(C(T," ","")+";",r,n,h-2),c);break;case 59:T+=";";default:if(M(k=J(T,e,n,l,u,i,s,b,w=[],x=[],h),a),123===v)if(0===u)K(T,e,k,k,w,a,h,s,x);else switch(d){case 100:case 109:case 115:K(t,k,k,r&&M(J(t,k,k,0,0,i,s,b,i,w=[],h),x),i,x,h,s,r?w:x);break;default:K(T,k,k,k,[""],x,h,s,x)}}l=u=f=0,g=m=1,b=T="",h=o;break;case 58:h=1+O(T),f=p;default:if(g<1)if(123==v)--g;else if(125==v&&0==g++&&125==L())continue;switch(T+=_(v),v*g){case 38:m=u>0?1:(T+="\f",-1);break;case 44:s[l++]=(O(T)-1)*m,m=1;break;case 64:45===I()&&(T+=$(R())),d=I(),u=O(b=T+=Z(F())),v++;break;case 45:45===p&&2==O(T)&&(g=0)}}return a}function J(t,e,n,r,i,o,s,c,l,u,h){for(var d=i-1,f=0===i?o:[""],p=A(f),g=0,y=0,m=0;g0?f[v]+" "+_:C(_,/&\f/g,f[v])))&&(l[m++]=w);return j(t,e,n,0===i?a:c,l,u,h)}function tt(t,e,n){return j(t,e,n,i,_(B()),S(t,2,-2),0)}function et(t,e,n,r){return j(t,e,n,o,S(t,0,r),S(t,r+1,-1),r)}function nt(t,i){switch(w(t,i)){case 5103:return r+"print-"+t+t;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return r+t+t;case 5349:case 4246:case 4810:case 6968:case 2756:return r+t+n+t+e+t+t;case 6828:case 4268:return r+t+e+t+t;case 6165:return r+t+e+"flex-"+t+t;case 5187:return r+t+C(t,/(\w+).+(:[^]+)/,r+"box-$1$2"+e+"flex-$1$2")+t;case 5443:return r+t+e+"flex-item-"+C(t,/flex-|-self/,"")+t;case 4675:return r+t+e+"flex-line-pack"+C(t,/align-content|flex-|-self/,"")+t;case 5548:return r+t+e+C(t,"shrink","negative")+t;case 5292:return r+t+e+C(t,"basis","preferred-size")+t;case 6060:return r+"box-"+C(t,"-grow","")+r+t+e+C(t,"grow","positive")+t;case 4554:return r+C(t,/([^-])(transform)/g,"$1"+r+"$2")+t;case 6187:return C(C(C(t,/(zoom-|grab)/,r+"$1"),/(image-set)/,r+"$1"),t,"")+t;case 5495:case 3959:return C(t,/(image-set\([^]*)/,r+"$1$`$1");case 4968:return C(C(t,/(.+:)(flex-)?(.*)/,r+"box-pack:$3"+e+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+r+t+t;case 4095:case 3583:case 4068:case 2532:return C(t,/(.+)-inline(.+)/,r+"$1$2")+t;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(O(t)-1-i>6)switch(E(t,i+1)){case 109:if(45!==E(t,i+4))break;case 102:return C(t,/(.+:)(.+)-([^]+)/,"$1"+r+"$2-$3$1"+n+(108==E(t,i+3)?"$3":"$2-$3"))+t;case 115:return~T(t,"stretch")?nt(C(t,"stretch","fill-available"),i)+t:t}break;case 4949:if(115!==E(t,i+1))break;case 6444:switch(E(t,O(t)-3-(~T(t,"!important")&&10))){case 107:return C(t,":",":"+r)+t;case 101:return C(t,/(.+:)([^;!]+)(;|!.+)?/,"$1"+r+(45===E(t,14)?"inline-":"")+"box$3$1"+r+"$2$3$1"+e+"$2box$3")+t}break;case 5936:switch(E(t,i+11)){case 114:return r+t+e+C(t,/[svh]\w+-[tblr]{2}/,"tb")+t;case 108:return r+t+e+C(t,/[svh]\w+-[tblr]{2}/,"tb-rl")+t;case 45:return r+t+e+C(t,/[svh]\w+-[tblr]{2}/,"lr")+t}return r+t+e+t+t}return t}function rt(t,e){for(var n="",r=A(t),i=0;i1?"":e;case n=A(r)-1:case 2:return 2===n?e+t+t:e+t;default:return e}}}))}))}}t.line=1,t.column=1,t.length=0,t.position=0,t.character=0,t.characters="",t.CHARSET=u,t.COMMENT=i,t.COUNTER_STYLE=m,t.DECLARATION=o,t.DOCUMENT=f,t.FONT_FACE=y,t.FONT_FEATURE_VALUES=v,t.IMPORT=l,t.KEYFRAMES=g,t.MEDIA=c,t.MOZ=n,t.MS=e,t.NAMESPACE=p,t.PAGE=s,t.RULESET=a,t.SUPPORTS=d,t.VIEWPORT=h,t.WEBKIT=r,t.abs=b,t.alloc=z,t.append=M,t.caret=F,t.char=B,t.charat=E,t.combine=D,t.comment=tt,t.commenter=X,t.compile=Q,t.copy=N,t.dealloc=U,t.declaration=et,t.delimit=$,t.delimiter=G,t.escaping=V,t.from=_,t.hash=w,t.identifier=Z,t.indexof=T,t.match=k,t.middleware=at,t.namespace=ct,t.next=R,t.node=j,t.parse=K,t.peek=I,t.prefix=nt,t.prefixer=st,t.prev=L,t.replace=C,t.ruleset=J,t.rulesheet=ot,t.serialize=rt,t.sizeof=A,t.slice=P,t.stringify=it,t.strlen=O,t.substr=S,t.token=Y,t.tokenize=W,t.tokenizer=H,t.trim=x,t.whitespace=q,Object.defineProperty(t,"__esModule",{value:!0})}(PG.exports),"undefined"!=typeof self&&self,ba.exports=function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s="./src/mermaid.js")}({"./node_modules/node-libs-browser/mock/empty.js":function(t,e){},"./node_modules/path-browserify/index.js":function(t,e,n){(function(t){function n(t,e){for(var n=0,r=t.length-1;r>=0;r--){var i=t[r];"."===i?t.splice(r,1):".."===i?(t.splice(r,1),n++):n&&(t.splice(r,1),n--)}if(e)for(;n--;n)t.unshift("..");return t}function r(t,e){if(t.filter)return t.filter(e);for(var n=[],r=0;r=-1&&!i;a--){var o=a>=0?arguments[a]:t.cwd();if("string"!=typeof o)throw new TypeError("Arguments to path.resolve must be strings");o&&(e=o+"/"+e,i="/"===o.charAt(0))}return(i?"/":"")+(e=n(r(e.split("/"),(function(t){return!!t})),!i).join("/"))||"."},e.normalize=function(t){var a=e.isAbsolute(t),o="/"===i(t,-1);return(t=n(r(t.split("/"),(function(t){return!!t})),!a).join("/"))||a||(t="."),t&&o&&(t+="/"),(a?"/":"")+t},e.isAbsolute=function(t){return"/"===t.charAt(0)},e.join=function(){var t=Array.prototype.slice.call(arguments,0);return e.normalize(r(t,(function(t,e){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t})).join("/"))},e.relative=function(t,n){function r(t){for(var e=0;e=0&&""===t[n];n--);return e>n?[]:t.slice(e,n-e+1)}t=e.resolve(t).substr(1),n=e.resolve(n).substr(1);for(var i=r(t.split("/")),a=r(n.split("/")),o=Math.min(i.length,a.length),s=o,c=0;c=1;--a)if(47===(e=t.charCodeAt(a))){if(!i){r=a;break}}else i=!1;return-1===r?n?"/":".":n&&1===r?"/":t.slice(0,r)},e.basename=function(t,e){var n=function(t){"string"!=typeof t&&(t+="");var e,n=0,r=-1,i=!0;for(e=t.length-1;e>=0;--e)if(47===t.charCodeAt(e)){if(!i){n=e+1;break}}else-1===r&&(i=!1,r=e+1);return-1===r?"":t.slice(n,r)}(t);return e&&n.substr(-1*e.length)===e&&(n=n.substr(0,n.length-e.length)),n},e.extname=function(t){"string"!=typeof t&&(t+="");for(var e=-1,n=0,r=-1,i=!0,a=0,o=t.length-1;o>=0;--o){var s=t.charCodeAt(o);if(47!==s)-1===r&&(i=!1,r=o+1),46===s?-1===e?e=o:1!==a&&(a=1):-1!==e&&(a=-1);else if(!i){n=o+1;break}}return-1===e||-1===r||0===a||1===a&&e===r-1&&e===n+1?"":t.slice(e,r)};var i="b"==="ab".substr(-1)?function(t,e,n){return t.substr(e,n)}:function(t,e,n){return e<0&&(e=t.length+e),t.substr(e,n)}}).call(this,n("./node_modules/process/browser.js"))},"./node_modules/process/browser.js":function(t,e){var n,r,i=t.exports={};function a(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function s(t){if(n===setTimeout)return setTimeout(t,0);if((n===a||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(HG){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:a}catch(HG){n=a}try{r="function"==typeof clearTimeout?clearTimeout:o}catch(HG){r=o}}();var c,l=[],u=!1,h=-1;function d(){u&&c&&(u=!1,c.length?l=c.concat(l):h=-1,l.length&&f())}function f(){if(!u){var t=s(d);u=!0;for(var e=l.length;e;){for(c=l,l=[];++h1)for(var n=1;n docs/Setup.md","build:watch":"yarn build --watch","release":"yarn build","lint":"eslint src","e2e:depr":"yarn lint && jest e2e --config e2e/jest.config.js","cypress":"percy exec -- cypress run","e2e":"start-server-and-test dev http://localhost:9000/ cypress","e2e-upd":"yarn lint && jest e2e -u --config e2e/jest.config.js","dev":"webpack-dev-server --config webpack.config.e2e.js","test":"yarn lint && jest src/.*","test:watch":"jest --watch src","prepublishOnly":"yarn build && yarn test","prepare":"yarn build"},"repository":{"type":"git","url":"https://github.com/knsv/mermaid"},"author":"Knut Sveidqvist","license":"MIT","standard":{"ignore":["**/parser/*.js","dist/**/*.js","cypress/**/*.js"],"globals":["page"]},"dependencies":{"@braintree/sanitize-url":"^3.1.0","@percy/migrate":"^0.10.0","d3":"^5.7.0","dagre":"^0.8.5","dagre-d3":"^0.6.4","dompurify":"2.3.0","graphlib":"^2.1.8","khroma":"^1.4.1","moment-mini":"^2.24.0","stylis":"^4.0.10"},"devDependencies":{"@babel/core":"^7.14.6","@babel/preset-env":"^7.14.7","@babel/register":"^7.14.5","@percy/cli":"^1.0.0-beta.58","@percy/cypress":"^3.1.0","babel-core":"7.0.0-bridge.0","babel-eslint":"^10.1.0","babel-jest":"^27.0.6","babel-loader":"^8.2.2","coveralls":"^3.0.2","css-to-string-loader":"^0.1.3","cypress":"7.6.0","documentation":"13.2.0","eslint":"^7.30.0","eslint-config-prettier":"^8.3.0","eslint-plugin-prettier":"^3.4.0","husky":"^7.0.1","identity-obj-proxy":"^3.0.0","jest":"^27.0.6","jison":"^0.4.18","js-base64":"3.6.1","moment":"^2.23.0","prettier":"^2.3.2","start-server-and-test":"^1.12.6","terser-webpack-plugin":"^2.2.2","webpack":"^4.41.2","webpack-bundle-analyzer":"^4.4.2","webpack-cli":"^3.1.2","webpack-dev-server":"^3.4.1","webpack-node-externals":"^1.7.2"},"files":["dist"],"yarn-upgrade-all":{"ignore":["babel-core"]},"sideEffects":["**/*.css","**/*.scss"],"husky":{"hooks":{"pre-push":"yarn test"}}}')},"./src/config.js":function(t,e,n){n.r(e),n.d(e,"defaultConfig",(function(){return l})),n.d(e,"updateCurrentConfig",(function(){return f})),n.d(e,"setSiteConfig",(function(){return p})),n.d(e,"saveConfigFromInitilize",(function(){return g})),n.d(e,"updateSiteConfig",(function(){return y})),n.d(e,"getSiteConfig",(function(){return m})),n.d(e,"setConfig",(function(){return v})),n.d(e,"getConfig",(function(){return b})),n.d(e,"sanitize",(function(){return _})),n.d(e,"addDirective",(function(){return w})),n.d(e,"reset",(function(){return x}));var r=n("./src/utils.js"),i=n("./src/logger.js"),a=n("./src/themes/index.js"),o=n("./src/defaultConfig.js");function s(t){return(s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}var c,l=Object.freeze(o.default),u=Object(r.assignWithDepth)({},l),h=[],d=Object(r.assignWithDepth)({},l),f=function(t,e){for(var n=Object(r.assignWithDepth)({},t),i={},o=0;o-1||e[n].indexOf(">")>-1||e[n].indexOf("url(data:")>-1)&&delete e[n],"object"===s(e[n])&&t(e[n])}))},w=function(t){t.fontFamily&&(t.themeVariables&&t.themeVariables.fontFamily||(t.themeVariables={fontFamily:t.fontFamily})),h.push(t),f(u,h)},x=function(){f(u,h=[])}},"./src/dagre-wrapper/clusters.js":function(t,e,n){n.r(e),n.d(e,"insertCluster",(function(){return h})),n.d(e,"getClusterTitleWidth",(function(){return d})),n.d(e,"clear",(function(){return f})),n.d(e,"positionCluster",(function(){return p}));var r=n("./src/dagre-wrapper/intersect/intersect-rect.js"),i=n("./src/logger.js"),a=n("./src/dagre-wrapper/createLabel.js"),o=n("d3"),s=n("./src/config.js"),c=n("./src/diagrams/common/common.js"),l={rect:function(t,e){i.log.trace("Creating subgraph rect for ",e.id,e);var n=t.insert("g").attr("class","cluster"+(e.class?" "+e.class:"")).attr("id",e.id),l=n.insert("rect",":first-child"),u=n.insert("g").attr("class","cluster-label"),h=u.node().appendChild(Object(a.default)(e.labelText,e.labelStyle,void 0,!0)),d=h.getBBox();if(Object(c.evaluate)(Object(s.getConfig)().flowchart.htmlLabels)){var f=h.children[0],p=Object(o.select)(h);d=f.getBoundingClientRect(),p.attr("width",d.width),p.attr("height",d.height)}var g=0*e.padding,y=g/2,m=e.width<=d.width+g?d.width+g:e.width;e.width<=d.width+g?e.diff=(d.width-e.width)/2:e.diff=-e.padding/2,i.log.trace("Data ",e,JSON.stringify(e)),l.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("x",e.x-m/2).attr("y",e.y-e.height/2-y).attr("width",m).attr("height",e.height+g),u.attr("transform","translate("+(e.x-d.width/2)+", "+(e.y-e.height/2+e.padding/3)+")");var v=l.node().getBBox();return e.width=v.width,e.height=v.height,e.intersect=function(t){return Object(r.default)(e,t)},n},roundedWithTitle:function(t,e){var n=t.insert("g").attr("class",e.classes).attr("id",e.id),i=n.insert("rect",":first-child"),l=n.insert("g").attr("class","cluster-label"),u=n.append("rect"),h=l.node().appendChild(Object(a.default)(e.labelText,e.labelStyle,void 0,!0)),d=h.getBBox();if(Object(c.evaluate)(Object(s.getConfig)().flowchart.htmlLabels)){var f=h.children[0],p=Object(o.select)(h);d=f.getBoundingClientRect(),p.attr("width",d.width),p.attr("height",d.height)}d=h.getBBox();var g=0*e.padding,y=g/2,m=e.width<=d.width+e.padding?d.width+e.padding:e.width;e.width<=d.width+e.padding?e.diff=(d.width+0*e.padding-e.width)/2:e.diff=-e.padding/2,i.attr("class","outer").attr("x",e.x-m/2-y).attr("y",e.y-e.height/2-y).attr("width",m+g).attr("height",e.height+g),u.attr("class","inner").attr("x",e.x-m/2-y).attr("y",e.y-e.height/2-y+d.height-1).attr("width",m+g).attr("height",e.height+g-d.height-3),l.attr("transform","translate("+(e.x-d.width/2)+", "+(e.y-e.height/2-e.padding/3+(Object(c.evaluate)(Object(s.getConfig)().flowchart.htmlLabels)?5:3))+")");var v=i.node().getBBox();return e.height=v.height,e.intersect=function(t){return Object(r.default)(e,t)},n},noteGroup:function(t,e){var n=t.insert("g").attr("class","note-cluster").attr("id",e.id),i=n.insert("rect",":first-child"),a=0*e.padding,o=a/2;i.attr("rx",e.rx).attr("ry",e.ry).attr("x",e.x-e.width/2-o).attr("y",e.y-e.height/2-o).attr("width",e.width+a).attr("height",e.height+a).attr("fill","none");var s=i.node().getBBox();return e.width=s.width,e.height=s.height,e.intersect=function(t){return Object(r.default)(e,t)},n},divider:function(t,e){var n=t.insert("g").attr("class",e.classes).attr("id",e.id),i=n.insert("rect",":first-child"),a=0*e.padding,o=a/2;i.attr("class","divider").attr("x",e.x-e.width/2-o).attr("y",e.y-e.height/2).attr("width",e.width+a).attr("height",e.height+a);var s=i.node().getBBox();return e.width=s.width,e.height=s.height,e.diff=-e.padding/2,e.intersect=function(t){return Object(r.default)(e,t)},n}},u={},h=function(t,e){i.log.trace("Inserting cluster");var n=e.shape||"rect";u[e.id]=l[n](t,e)},d=function(t,e){var n=Object(a.default)(e.labelText,e.labelStyle,void 0,!0);t.node().appendChild(n);var r=n.getBBox().width;return t.node().removeChild(n),r},f=function(){u={}},p=function(t){i.log.info("Position cluster ("+t.id+", "+t.x+", "+t.y+")"),u[t.id].attr("transform","translate("+t.x+", "+t.y+")")}},"./src/dagre-wrapper/createLabel.js":function(t,e,n){n.r(e);var r=n("d3"),i=n("./src/logger.js"),a=n("./src/diagrams/common/common.js"),o=n("./src/config.js");function s(t){return(s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}e.default=function(t,e,n,c){var l=t||"";if("object"===s(l)&&(l=l[0]),Object(a.evaluate)(Object(o.getConfig)().flowchart.htmlLabels))return l=l.replace(/\\n|\n/g,"
"),i.log.info("vertexText"+l),function(t){var e,n,i=Object(r.select)(document.createElementNS("http://www.w3.org/2000/svg","foreignObject")),a=i.append("xhtml:div"),o=t.label,s=t.isNode?"nodeLabel":"edgeLabel";return a.html('"+o+""),e=a,(n=t.labelStyle)&&e.attr("style",n),a.style("display","inline-block"),a.style("white-space","nowrap"),a.attr("xmlns","http://www.w3.org/1999/xhtml"),i.node()}({isNode:c,label:l.replace(/fa[lrsb]?:fa-[\w-]+/g,(function(t){return"")})),labelStyle:e.replace("fill:","color:")});var u=document.createElementNS("http://www.w3.org/2000/svg","text");u.setAttribute("style",e.replace("color:","fill:"));var h=[];h="string"==typeof l?l.split(/\\n|\n|/gi):Array.isArray(l)?l:[];for(var d=0;dMath.abs(i-e.x)*l){var d=n.y=o||a>=s}(e,t)||a)r.log.warn("abc88 outside",t,i),i=t,a||n.push(t);else{var o=p(e,i,t);r.log.warn("abc88 inside",t,i,o),r.log.warn("abc88 intersection",o);var s=!1;n.forEach((function(t){s=s||t.x===o.x&&t.y===o.y})),n.find((function(t){return t.x===o.x&&t.y===o.y}))?r.log.warn("abc88 no intersect",o,n):n.push(o),a=!0}})),r.log.warn("abc88 returning points",n),n},y=function(t,e,n,i,s,c){var l=n.points,u=!1,h=c.node(e.v),d=c.node(e.w);r.log.info("abc88 InsertEdge: ",n),d.intersect&&h.intersect&&((l=l.slice(1,n.points.length-1)).unshift(h.intersect(l[0])),r.log.info("Last point",l[l.length-1],d,d.intersect(l[l.length-1])),l.push(d.intersect(l[l.length-1]))),n.toCluster&&(r.log.info("to cluster abc88",i[n.toCluster]),l=g(n.points,i[n.toCluster].node),u=!0),n.fromCluster&&(r.log.info("from cluster abc88",i[n.fromCluster]),l=g(l.reverse(),i[n.fromCluster].node).reverse(),u=!0);var f,p=l.filter((function(t){return!Number.isNaN(t.y)}));f=("graph"===s||"flowchart"===s)&&n.curve||a.curveBasis;var y,m=Object(a.line)().x((function(t){return t.x})).y((function(t){return t.y})).curve(f);switch(n.thickness){case"normal":y="edge-thickness-normal";break;case"thick":y="edge-thickness-thick";break;default:y=""}switch(n.pattern){case"solid":y+=" edge-pattern-solid";break;case"dotted":y+=" edge-pattern-dotted";break;case"dashed":y+=" edge-pattern-dashed"}var v=t.append("path").attr("d",m(p)).attr("id",n.id).attr("class"," "+y+(n.classes?" "+n.classes:"")).attr("style",n.style),b="";switch(Object(o.getConfig)().state.arrowMarkerAbsolute&&(b=(b=(b=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search).replace(/\(/g,"\\(")).replace(/\)/g,"\\)")),r.log.info("arrowTypeStart",n.arrowTypeStart),r.log.info("arrowTypeEnd",n.arrowTypeEnd),n.arrowTypeStart){case"arrow_cross":v.attr("marker-start","url("+b+"#"+s+"-crossStart)");break;case"arrow_point":v.attr("marker-start","url("+b+"#"+s+"-pointStart)");break;case"arrow_barb":v.attr("marker-start","url("+b+"#"+s+"-barbStart)");break;case"arrow_circle":v.attr("marker-start","url("+b+"#"+s+"-circleStart)");break;case"aggregation":v.attr("marker-start","url("+b+"#"+s+"-aggregationStart)");break;case"extension":v.attr("marker-start","url("+b+"#"+s+"-extensionStart)");break;case"composition":v.attr("marker-start","url("+b+"#"+s+"-compositionStart)");break;case"dependency":v.attr("marker-start","url("+b+"#"+s+"-dependencyStart)")}switch(n.arrowTypeEnd){case"arrow_cross":v.attr("marker-end","url("+b+"#"+s+"-crossEnd)");break;case"arrow_point":v.attr("marker-end","url("+b+"#"+s+"-pointEnd)");break;case"arrow_barb":v.attr("marker-end","url("+b+"#"+s+"-barbEnd)");break;case"arrow_circle":v.attr("marker-end","url("+b+"#"+s+"-circleEnd)");break;case"aggregation":v.attr("marker-end","url("+b+"#"+s+"-aggregationEnd)");break;case"extension":v.attr("marker-end","url("+b+"#"+s+"-extensionEnd)");break;case"composition":v.attr("marker-end","url("+b+"#"+s+"-compositionEnd)");break;case"dependency":v.attr("marker-end","url("+b+"#"+s+"-dependencyEnd)")}var _={};return u&&(_.updatedPath=l),_.originalPath=n.points,_}},"./src/dagre-wrapper/index.js":function(t,e,n){n.r(e),n.d(e,"render",(function(){return g}));var r=n("dagre"),i=n.n(r),a=n("graphlib"),o=n.n(a),s=n("./src/dagre-wrapper/markers.js"),c=n("./src/dagre-wrapper/shapes/util.js"),l=n("./src/dagre-wrapper/mermaid-graphlib.js"),u=n("./src/dagre-wrapper/nodes.js"),h=n("./src/dagre-wrapper/clusters.js"),d=n("./src/dagre-wrapper/edges.js"),f=n("./src/logger.js"),p=function t(e,n,r,a){f.log.info("Graph in recursive render: XXX",o.a.json.write(n),a);var s=n.graph().rankdir;f.log.trace("Dir in recursive render - dir:",s);var p=e.insert("g").attr("class","root");n.nodes()?f.log.info("Recursive render XXX",n.nodes()):f.log.info("No nodes found for",n),n.edges().length>0&&f.log.trace("Recursive edges",n.edge(n.edges()[0]));var g=p.insert("g").attr("class","clusters"),y=p.insert("g").attr("class","edgePaths"),m=p.insert("g").attr("class","edgeLabels"),v=p.insert("g").attr("class","nodes");n.nodes().forEach((function(e){var i=n.node(e);if(void 0!==a){var o=JSON.parse(JSON.stringify(a.clusterData));f.log.info("Setting data for cluster XXX (",e,") ",o,a),n.setNode(a.id,o),n.parent(e)||(f.log.trace("Setting parent",e,a.id),n.setParent(e,a.id,o))}if(f.log.info("(Insert) Node XXX"+e+": "+JSON.stringify(n.node(e))),i&&i.clusterNode){f.log.info("Cluster identified",e,i.width,n.node(e));var h=t(v,i.graph,r,n.node(e)),d=h.elem;Object(c.updateNodeBounds)(i,d),i.diff=h.diff||0,f.log.info("Node bounds (abc123)",e,i,i.width,i.x,i.y),Object(u.setNodeElem)(d,i),f.log.warn("Recursive render complete ",d,i)}else n.children(e).length>0?(f.log.info("Cluster - the non recursive path XXX",e,i.id,i,n),f.log.info(Object(l.findNonClusterChild)(i.id,n)),l.clusterDb[i.id]={id:Object(l.findNonClusterChild)(i.id,n),node:i}):(f.log.info("Node - the non recursive path",e,i.id,i),Object(u.insertNode)(v,n.node(e),s))})),n.edges().forEach((function(t){var e=n.edge(t.v,t.w,t.name);f.log.info("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(t)),f.log.info("Edge "+t.v+" -> "+t.w+": ",t," ",JSON.stringify(n.edge(t))),f.log.info("Fix",l.clusterDb,"ids:",t.v,t.w,"Translateing: ",l.clusterDb[t.v],l.clusterDb[t.w]),Object(d.insertEdgeLabel)(m,e)})),n.edges().forEach((function(t){f.log.info("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(t))})),f.log.info("#############################################"),f.log.info("### Layout ###"),f.log.info("#############################################"),f.log.info(n),i.a.layout(n),f.log.info("Graph after layout:",o.a.json.write(n));var b=0;return Object(l.sortNodesByHierarchy)(n).forEach((function(t){var e=n.node(t);f.log.info("Position "+t+": "+JSON.stringify(n.node(t))),f.log.info("Position "+t+": ("+e.x,","+e.y,") width: ",e.width," height: ",e.height),e&&e.clusterNode?Object(u.positionNode)(e):n.children(t).length>0?(Object(h.insertCluster)(g,e),l.clusterDb[e.id].node=e):Object(u.positionNode)(e)})),n.edges().forEach((function(t){var e=n.edge(t);f.log.info("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(e),e);var i=Object(d.insertEdge)(y,t,e,l.clusterDb,r,n);Object(d.positionEdgeLabel)(e,i)})),n.nodes().forEach((function(t){var e=n.node(t);f.log.info(t,e.type,e.diff),"group"===e.type&&(b=e.diff)})),{elem:p,diff:b}},g=function(t,e,n,r,i){Object(s.default)(t,n,r,i),Object(u.clear)(),Object(d.clear)(),Object(h.clear)(),Object(l.clear)(),f.log.warn("Graph at first:",o.a.json.write(e)),Object(l.adjustClustersAndEdges)(e),f.log.warn("Graph after:",o.a.json.write(e)),p(t,e,r)}},"./src/dagre-wrapper/intersect/index.js":function(t,e,n){n.r(e);var r=n("./src/dagre-wrapper/intersect/intersect-node.js"),i=n.n(r),a=n("./src/dagre-wrapper/intersect/intersect-circle.js"),o=n("./src/dagre-wrapper/intersect/intersect-ellipse.js"),s=n("./src/dagre-wrapper/intersect/intersect-polygon.js"),c=n("./src/dagre-wrapper/intersect/intersect-rect.js");e.default={node:i.a,circle:a.default,ellipse:o.default,polygon:s.default,rect:c.default}},"./src/dagre-wrapper/intersect/intersect-circle.js":function(t,e,n){n.r(e);var r=n("./src/dagre-wrapper/intersect/intersect-ellipse.js");e.default=function(t,e,n){return Object(r.default)(t,e,e,n)}},"./src/dagre-wrapper/intersect/intersect-ellipse.js":function(t,e,n){n.r(e),e.default=function(t,e,n,r){var i=t.x,a=t.y,o=i-r.x,s=a-r.y,c=Math.sqrt(e*e*s*s+n*n*o*o),l=Math.abs(e*n*o/c);r.x0}n.r(e),e.default=function(t,e,n,i){var a,o,s,c,l,u,h,d,f,p,g,y,m;if(a=e.y-t.y,s=t.x-e.x,l=e.x*t.y-t.x*e.y,f=a*n.x+s*n.y+l,p=a*i.x+s*i.y+l,!(0!==f&&0!==p&&r(f,p)||(o=i.y-n.y,c=n.x-i.x,u=i.x*n.y-n.x*i.y,h=o*t.x+c*t.y+u,d=o*e.x+c*e.y+u,0!==h&&0!==d&&r(h,d)||0==(g=a*c-o*s))))return y=Math.abs(g/2),{x:(m=s*u-c*l)<0?(m-y)/g:(m+y)/g,y:(m=o*l-a*u)<0?(m-y)/g:(m+y)/g}}},"./src/dagre-wrapper/intersect/intersect-node.js":function(t,e){t.exports=function(t,e){return t.intersect(e)}},"./src/dagre-wrapper/intersect/intersect-polygon.js":function(t,e,n){n.r(e);var r=n("./src/dagre-wrapper/intersect/intersect-line.js");e.default=function(t,e,n){var i=t.x,a=t.y,o=[],s=Number.POSITIVE_INFINITY,c=Number.POSITIVE_INFINITY;"function"==typeof e.forEach?e.forEach((function(t){s=Math.min(s,t.x),c=Math.min(c,t.y)})):(s=Math.min(s,e.x),c=Math.min(c,e.y));for(var l=i-t.width/2-s,u=a-t.height/2-c,h=0;h1&&o.sort((function(t,e){var r=t.x-n.x,i=t.y-n.y,a=Math.sqrt(r*r+i*i),o=e.x-n.x,s=e.y-n.y,c=Math.sqrt(o*o+s*s);return aMath.abs(o)*l?(s<0&&(l=-l),n=0===s?0:l*o/s,r=l):(o<0&&(c=-c),n=c,r=0===o?0:c*s/o),{x:i+n,y:a+r}}},"./src/dagre-wrapper/markers.js":function(t,e,n){n.r(e);var r=n("./src/logger.js"),i={extension:function(t,e,n){r.log.trace("Making markers for ",n),t.append("defs").append("marker").attr("id",e+"-extensionStart").attr("class","marker extension "+e).attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),t.append("defs").append("marker").attr("id",e+"-extensionEnd").attr("class","marker extension "+e).attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z")},composition:function(t,e){t.append("defs").append("marker").attr("id",e+"-compositionStart").attr("class","marker composition "+e).attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",e+"-compositionEnd").attr("class","marker composition "+e).attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},aggregation:function(t,e){t.append("defs").append("marker").attr("id",e+"-aggregationStart").attr("class","marker aggregation "+e).attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",e+"-aggregationEnd").attr("class","marker aggregation "+e).attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},dependency:function(t,e){t.append("defs").append("marker").attr("id",e+"-dependencyStart").attr("class","marker dependency "+e).attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",e+"-dependencyEnd").attr("class","marker dependency "+e).attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},point:function(t,e){t.append("marker").attr("id",e+"-pointEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),t.append("marker").attr("id",e+"-pointStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",0).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},circle:function(t,e){t.append("marker").attr("id",e+"-circleEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),t.append("marker").attr("id",e+"-circleStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},cross:function(t,e){t.append("marker").attr("id",e+"-crossEnd").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),t.append("marker").attr("id",e+"-crossStart").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0")},barb:function(t,e){t.append("defs").append("marker").attr("id",e+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","strokeWidth").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")}};e.default=function(t,e,n,r){e.forEach((function(e){i[e](t,n,r)}))}},"./src/dagre-wrapper/mermaid-graphlib.js":function(t,e,n){n.r(e),n.d(e,"clusterDb",(function(){return o})),n.d(e,"clear",(function(){return l})),n.d(e,"extractDecendants",(function(){return d})),n.d(e,"validate",(function(){return f})),n.d(e,"findNonClusterChild",(function(){return p})),n.d(e,"adjustClustersAndEdges",(function(){return y})),n.d(e,"extractor",(function(){return m})),n.d(e,"sortNodesByHierarchy",(function(){return b}));var r=n("./src/logger.js"),i=n("graphlib"),a=n.n(i),o={},s={},c={},l=function(){s={},c={},o={}},u=function(t,e){return r.log.trace("In isDecendant",e," ",t," = ",s[e].indexOf(t)>=0),s[e].indexOf(t)>=0},h=function t(e,n,i,a){r.log.warn("Copying children of ",e,"root",a,"data",n.node(e),a);var o=n.children(e)||[];e!==a&&o.push(e),r.log.warn("Copying (nodes) clusterId",e,"nodes",o),o.forEach((function(o){if(n.children(o).length>0)t(o,n,i,a);else{var c=n.node(o);r.log.info("cp ",o," to ",a," with parent ",e),i.setNode(o,c),a!==n.parent(o)&&(r.log.warn("Setting parent",o,n.parent(o)),i.setParent(o,n.parent(o))),e!==a&&o!==e?(r.log.debug("Setting parent",o,e),i.setParent(o,e)):(r.log.info("In copy ",e,"root",a,"data",n.node(e),a),r.log.debug("Not Setting parent for node=",o,"cluster!==rootId",e!==a,"node!==clusterId",o!==e));var l=n.edges(o);r.log.debug("Copying Edges",l),l.forEach((function(t){r.log.info("Edge",t);var o=n.edge(t.v,t.w,t.name);r.log.info("Edge data",o,a);try{!function(t,e){return r.log.info("Decendants of ",e," is ",s[e]),r.log.info("Edge is ",t),t.v!==e&&t.w!==e&&(s[e]?(r.log.info("Here "),s[e].indexOf(t.v)>=0||!!u(t.v,e)||!!u(t.w,e)||s[e].indexOf(t.w)>=0):(r.log.debug("Tilt, ",e,",not in decendants"),!1))}(t,a)?r.log.info("Skipping copy of edge ",t.v,"--\x3e",t.w," rootId: ",a," clusterId:",e):(r.log.info("Copying as ",t.v,t.w,o,t.name),i.setEdge(t.v,t.w,o,t.name),r.log.info("newGraph edges ",i.edges(),i.edge(i.edges()[0])))}catch(HG){r.log.error(HG)}}))}r.log.debug("Removing node",o),n.removeNode(o)}))},d=function t(e,n){for(var r=n.children(e),i=[].concat(r),a=0;a0)return r.log.trace("The node ",e[n].v," is part of and edge even though it has children"),!1;if(t.children(e[n].w).length>0)return r.log.trace("The node ",e[n].w," is part of and edge even though it has children"),!1}return!0},p=function t(e,n){r.log.trace("Searching",e);var i=n.children(e);if(r.log.trace("Searching children of id ",e,i),i.length<1)return r.log.trace("This is a valid node",e),e;for(var a=0;a ",o),o}},g=function(t){return o[t]&&o[t].externalConnections&&o[t]?o[t].id:t},y=function(t,e){!t||e>10?r.log.debug("Opting out, no graph "):(r.log.debug("Opting in, graph "),t.nodes().forEach((function(e){t.children(e).length>0&&(r.log.warn("Cluster identified",e," Replacement id in edges: ",p(e,t)),s[e]=d(e,t),o[e]={id:p(e,t),clusterData:t.node(e)})})),t.nodes().forEach((function(e){var n=t.children(e),i=t.edges();n.length>0?(r.log.debug("Cluster identified",e,s),i.forEach((function(t){t.v!==e&&t.w!==e&&u(t.v,e)^u(t.w,e)&&(r.log.warn("Edge: ",t," leaves cluster ",e),r.log.warn("Decendants of XXX ",e,": ",s[e]),o[e].externalConnections=!0)}))):r.log.debug("Not a cluster ",e,s)})),t.edges().forEach((function(e){var n=t.edge(e);r.log.warn("Edge "+e.v+" -> "+e.w+": "+JSON.stringify(e)),r.log.warn("Edge "+e.v+" -> "+e.w+": "+JSON.stringify(t.edge(e)));var i=e.v,a=e.w;r.log.warn("Fix XXX",o,"ids:",e.v,e.w,"Translateing: ",o[e.v]," --- ",o[e.w]),(o[e.v]||o[e.w])&&(r.log.warn("Fixing and trixing - removing XXX",e.v,e.w,e.name),i=g(e.v),a=g(e.w),t.removeEdge(e.v,e.w,e.name),i!==e.v&&(n.fromCluster=e.v),a!==e.w&&(n.toCluster=e.w),r.log.warn("Fix Replacing with XXX",i,a,e.name),t.setEdge(i,a,n,e.name))})),r.log.warn("Adjusted Graph",a.a.json.write(t)),m(t,0),r.log.trace(o))},m=function t(e,n){if(r.log.warn("extractor - ",n,a.a.json.write(e),e.children("D")),n>10)r.log.error("Bailing out");else{for(var i=e.nodes(),s=!1,c=0;c0}if(s){r.log.debug("Nodes = ",i,n);for(var d=0;d0){r.log.warn("Cluster without external connections, without a parent and with children",f,n);var p="TB"===e.graph().rankdir?"LR":"TB";o[f]&&o[f].clusterData&&o[f].clusterData.dir&&(p=o[f].clusterData.dir,r.log.warn("Fixing dir",o[f].clusterData.dir,p));var g=new a.a.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:p,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel((function(){return{}}));r.log.warn("Old graph before copy",a.a.json.write(e)),h(f,e,g,f),e.setNode(f,{clusterNode:!0,id:f,clusterData:o[f].clusterData,labelText:o[f].labelText,graph:g}),r.log.warn("New graph after copy node: (",f,")",a.a.json.write(g)),r.log.debug("Old graph after copy",a.a.json.write(e))}else r.log.warn("Cluster ** ",f," **not meeting the criteria !externalConnections:",!o[f].externalConnections," no parent: ",!e.parent(f)," children ",e.children(f)&&e.children(f).length>0,e.children("D"),n),r.log.debug(o);else r.log.debug("Not a cluster",f,n)}i=e.nodes(),r.log.warn("New list of nodes",i);for(var y=0;y"):w,e.labelStyle,!0,!0));if(Object(h.evaluate)(Object(o.getConfig)().flowchart.htmlLabels)){var C=k.children[0],T=Object(r.select)(k);m=C.getBoundingClientRect(),T.attr("width",m.width),T.attr("height",m.height)}var E=e.padding/2;return Object(r.select)(k).attr("transform","translate( "+(m.width>x.width?0:(x.width-m.width)/2)+", "+(x.height+E+5)+")"),Object(r.select)(v).attr("transform","translate( "+(m.widthe.height/2-l)){var i=l*l*(1-r*r/(c*c));0!=i&&(i=Math.sqrt(i)),i=l-i,t.y-e.y>0&&(i=-i),n.y+=i}return n},r},start:function(t,e){var n=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),r=n.insert("circle",":first-child");return r.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),Object(a.updateNodeBounds)(e,r),e.intersect=function(t){return s.default.circle(e,7,t)},n},end:function(t,e){var n=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),r=n.insert("circle",":first-child"),i=n.insert("circle",":first-child");return i.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),r.attr("class","state-end").attr("r",5).attr("width",10).attr("height",10),Object(a.updateNodeBounds)(e,i),e.intersect=function(t){return s.default.circle(e,7,t)},n},note:l.default,subroutine:function(t,e){var n=Object(a.labelHelper)(t,e,void 0,!0),r=n.shapeSvg,i=n.bbox,o=i.width+e.padding,c=i.height+e.padding,l=[{x:0,y:0},{x:o,y:0},{x:o,y:-c},{x:0,y:-c},{x:0,y:0},{x:-8,y:0},{x:o+8,y:0},{x:o+8,y:-c},{x:-8,y:-c},{x:-8,y:0}],u=Object(a.insertPolygonShape)(r,o,c,l);return u.attr("style",e.style),Object(a.updateNodeBounds)(e,u),e.intersect=function(t){return s.default.polygon(e,l,t)},r},fork:f,join:f,class_box:function(t,e){var n,i=e.padding/2;n=e.classes?"node "+e.classes:"node default";var l=t.insert("g").attr("class",n).attr("id",e.domId||e.id),d=l.insert("rect",":first-child"),f=l.insert("line"),p=l.insert("line"),g=0,y=4,m=l.insert("g").attr("class","label"),v=0,b=e.classData.annotations&&e.classData.annotations[0],_=e.classData.annotations[0]?"«"+e.classData.annotations[0]+"»":"",w=m.node().appendChild(Object(c.default)(_,e.labelStyle,!0,!0)),x=w.getBBox();if(Object(h.evaluate)(Object(o.getConfig)().flowchart.htmlLabels)){var k=w.children[0],C=Object(r.select)(w);x=k.getBoundingClientRect(),C.attr("width",x.width),C.attr("height",x.height)}e.classData.annotations[0]&&(y+=x.height+4,g+=x.width);var T=e.classData.id;void 0!==e.classData.type&&""!==e.classData.type&&(T+="<"+e.classData.type+">");var E=m.node().appendChild(Object(c.default)(T,e.labelStyle,!0,!0));Object(r.select)(E).attr("class","classTitle");var S=E.getBBox();if(Object(h.evaluate)(Object(o.getConfig)().flowchart.htmlLabels)){var O=E.children[0],A=Object(r.select)(E);S=O.getBoundingClientRect(),A.attr("width",S.width),A.attr("height",S.height)}y+=S.height+4,S.width>g&&(g=S.width);var M=[];e.classData.members.forEach((function(t){var n=Object(u.parseMember)(t).displayText,i=m.node().appendChild(Object(c.default)(n,e.labelStyle,!0,!0)),a=i.getBBox();if(Object(h.evaluate)(Object(o.getConfig)().flowchart.htmlLabels)){var s=i.children[0],l=Object(r.select)(i);a=s.getBoundingClientRect(),l.attr("width",a.width),l.attr("height",a.height)}a.width>g&&(g=a.width),y+=a.height+4,M.push(i)})),y+=8;var D=[];if(e.classData.methods.forEach((function(t){var n=Object(u.parseMember)(t).displayText,i=m.node().appendChild(Object(c.default)(n,e.labelStyle,!0,!0)),a=i.getBBox();if(Object(h.evaluate)(Object(o.getConfig)().flowchart.htmlLabels)){var s=i.children[0],l=Object(r.select)(i);a=s.getBoundingClientRect(),l.attr("width",a.width),l.attr("height",a.height)}a.width>g&&(g=a.width),y+=a.height+4,D.push(i)})),y+=8,b){var j=(g-x.width)/2;Object(r.select)(w).attr("transform","translate( "+(-1*g/2+j)+", "+-1*y/2+")"),v=x.height+4}var N=(g-S.width)/2;return Object(r.select)(E).attr("transform","translate( "+(-1*g/2+N)+", "+(-1*y/2+v)+")"),v+=S.height+4,f.attr("class","divider").attr("x1",-g/2-i).attr("x2",g/2+i).attr("y1",-y/2-i+8+v).attr("y2",-y/2-i+8+v),v+=8,M.forEach((function(t){Object(r.select)(t).attr("transform","translate( "+-g/2+", "+(-1*y/2+v+4)+")"),v+=S.height+4})),v+=8,p.attr("class","divider").attr("x1",-g/2-i).attr("x2",g/2+i).attr("y1",-y/2-i+8+v).attr("y2",-y/2-i+8+v),v+=8,D.forEach((function(t){Object(r.select)(t).attr("transform","translate( "+-g/2+", "+(-1*y/2+v)+")"),v+=S.height+4})),d.attr("class","outer title-state").attr("x",-g/2-i).attr("y",-y/2-i).attr("width",g+e.padding).attr("height",y+e.padding),Object(a.updateNodeBounds)(e,d),e.intersect=function(t){return s.default.rect(e,t)},l}},g={},y=function(t,e,n){var r,i;e.link?(r=t.insert("svg:a").attr("xlink:href",e.link).attr("target",e.linkTarget||"_blank"),i=p[e.shape](r,e,n)):r=i=p[e.shape](t,e,n),e.tooltip&&i.attr("title",e.tooltip),e.class&&i.attr("class","node default "+e.class),g[e.id]=r,e.haveCallback&&g[e.id].attr("class",g[e.id].attr("class")+" clickable")},m=function(t,e){g[e.id]=t},v=function(){g={}},b=function(t){var e=g[t.id];i.log.trace("Transforming node",t.diff,t,"translate("+(t.x-t.width/2-5)+", "+t.width/2+")");var n=t.diff||0;return t.clusterNode?e.attr("transform","translate("+(t.x+n-t.width/2)+", "+(t.y-t.height/2-8)+")"):e.attr("transform","translate("+t.x+", "+t.y+")"),n}},"./src/dagre-wrapper/shapes/note.js":function(t,e,n){n.r(e);var r=n("./src/dagre-wrapper/shapes/util.js"),i=n("./src/logger.js"),a=n("./src/dagre-wrapper/intersect/index.js");e.default=function(t,e){var n=Object(r.labelHelper)(t,e,"node "+e.classes,!0),o=n.shapeSvg,s=n.bbox,c=n.halfPadding;i.log.info("Classes = ",e.classes);var l=o.insert("rect",":first-child");return l.attr("rx",e.rx).attr("ry",e.ry).attr("x",-s.width/2-c).attr("y",-s.height/2-c).attr("width",s.width+e.padding).attr("height",s.height+e.padding),Object(r.updateNodeBounds)(e,l),e.intersect=function(t){return a.default.rect(e,t)},o}},"./src/dagre-wrapper/shapes/util.js":function(t,e,n){n.r(e),n.d(e,"labelHelper",(function(){return s})),n.d(e,"updateNodeBounds",(function(){return c})),n.d(e,"insertPolygonShape",(function(){return l}));var r=n("./src/dagre-wrapper/createLabel.js"),i=n("./src/config.js"),a=n("d3"),o=n("./src/diagrams/common/common.js"),s=function(t,e,n,s){var c;c=n||"node default";var l=t.insert("g").attr("class",c).attr("id",e.domId||e.id),u=l.insert("g").attr("class","label").attr("style",e.labelStyle),h=u.node().appendChild(Object(r.default)(e.labelText,e.labelStyle,!1,s)),d=h.getBBox();if(Object(o.evaluate)(Object(i.getConfig)().flowchart.htmlLabels)){var f=h.children[0],p=Object(a.select)(h);d=f.getBoundingClientRect(),p.attr("width",d.width),p.attr("height",d.height)}var g=e.padding/2;return u.attr("transform","translate("+-d.width/2+", "+-d.height/2+")"),{shapeSvg:l,bbox:d,halfPadding:g,label:u}},c=function(t,e){var n=e.node().getBBox();t.width=n.width,t.height=n.height};function l(t,e,n,r){return t.insert("polygon",":first-child").attr("points",r.map((function(t){return t.x+","+t.y})).join(" ")).attr("class","label-container").attr("transform","translate("+-e/2+","+n/2+")")}},"./src/defaultConfig.js":function(t,e,n){n.r(e);var r={theme:"default",themeVariables:n("./src/themes/index.js").default.default.getThemeVariables(),themeCSS:void 0,maxTextSize:5e4,fontFamily:'"trebuchet ms", verdana, arial, sans-serif;',logLevel:5,securityLevel:"strict",startOnLoad:!0,arrowMarkerAbsolute:!1,secure:["secure","securityLevel","startOnLoad","maxTextSize"],deterministicIds:!1,deterministicIDSeed:void 0,flowchart:{diagramPadding:8,htmlLabels:!0,nodeSpacing:50,rankSpacing:50,curve:"basis",padding:15,useMaxWidth:!0,defaultRenderer:"dagre-d3"},sequence:{activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",mirrorActors:!0,bottomMarginAdj:1,useMaxWidth:!0,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:'"Open-Sans", "sans-serif"',actorFontWeight:400,noteFontSize:14,noteFontFamily:'"trebuchet ms", verdana, arial, sans-serif',noteFontWeight:400,noteAlign:"center",messageFontSize:16,messageFontFamily:'"trebuchet ms", verdana, arial, sans-serif',messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20,messageFont:function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},noteFont:function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},actorFont:function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}}},gantt:{titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:"%Y-%m-%d",useMaxWidth:!0,topAxis:!1,useWidth:void 0},journey:{diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,useMaxWidth:!0,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open-Sans", "sans-serif"',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"]},class:{arrowMarkerAbsolute:!1,useMaxWidth:!0,defaultRenderer:"dagre-d3"},git:{arrowMarkerAbsolute:!1,useWidth:void 0,useMaxWidth:!0},state:{dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:"20",compositTitleSize:35,radius:5,useMaxWidth:!0,defaultRenderer:"dagre-wrapper"},er:{diagramPadding:20,layoutDirection:"TB",minEntityWidth:100,minEntityHeight:75,entityPadding:15,stroke:"gray",fill:"honeydew",fontSize:12,useMaxWidth:!0},pie:{useWidth:void 0,useMaxWidth:!0},requirement:{useWidth:void 0,useMaxWidth:!0,rect_fill:"#f9f9f9",text_color:"#333",rect_border_size:"0.5px",rect_border_color:"#bbb",rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20}};r.class.arrowMarkerAbsolute=r.arrowMarkerAbsolute,r.git.arrowMarkerAbsolute=r.arrowMarkerAbsolute,e.default=r},"./src/diagrams/class/classDb.js":function(t,e,n){n.r(e),n.d(e,"parseDirective",(function(){return y})),n.d(e,"addClass",(function(){return v})),n.d(e,"lookUpDomId",(function(){return b})),n.d(e,"clear",(function(){return _})),n.d(e,"getClass",(function(){return w})),n.d(e,"getClasses",(function(){return x})),n.d(e,"getRelations",(function(){return k})),n.d(e,"addRelation",(function(){return C})),n.d(e,"addAnnotation",(function(){return T})),n.d(e,"addMember",(function(){return E})),n.d(e,"addMembers",(function(){return S})),n.d(e,"cleanupLabel",(function(){return O})),n.d(e,"setCssClass",(function(){return A})),n.d(e,"setLink",(function(){return M})),n.d(e,"setClickEvent",(function(){return D})),n.d(e,"bindFunctions",(function(){return N})),n.d(e,"lineType",(function(){return B})),n.d(e,"relationType",(function(){return L}));var r=n("d3"),i=n("./src/logger.js"),a=n("./src/config.js"),o=n("./src/diagrams/common/common.js"),s=n("./src/utils.js"),c=n("./src/mermaidAPI.js");function l(t){return function(t){if(Array.isArray(t))return u(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return u(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?u(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n0){var r=t.split("~");n=r[0],e=r[1]}return{className:n,type:e}},v=function(t){var e=m(t);void 0===f[e.className]&&(f[e.className]={id:e.className,type:e.type,cssClasses:[],methods:[],members:[],annotations:[],domId:h+e.className+"-"+p},p++)},b=function(t){for(var e=Object.keys(f),n=0;n>")?r.annotations.push(i.substring(2,i.length-2)):i.indexOf(")")>0?r.methods.push(i):i&&r.members.push(i)}},S=function(t,e){Array.isArray(e)&&(e.reverse(),e.forEach((function(e){return E(t,e)})))},O=function(t){return":"===t.substring(0,1)?t.substr(1).trim():t.trim()},A=function(t,e){t.split(",").forEach((function(t){var n=t;t[0].match(/\d/)&&(n=h+n),void 0!==f[n]&&f[n].cssClasses.push(e)}))},M=function(t,e,n){var r=a.getConfig();t.split(",").forEach((function(t){var i=t;t[0].match(/\d/)&&(i=h+i),void 0!==f[i]&&(f[i].link=s.default.formatUrl(e,r),f[i].linkTarget="string"==typeof n?n:"_blank")})),A(t,"clickable")},D=function(t,e,n){t.split(",").forEach((function(t){j(t,e,n),f[t].haveCallback=!0})),A(t,"clickable")},j=function(t,e,n){var r=a.getConfig(),i=t,o=b(i);if("loose"===r.securityLevel&&void 0!==e&&void 0!==f[i]){var c=[];if("string"==typeof n){c=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(var u=0;u0&&(i=i+" "+r.cssClasses.join(" "));var a={labelStyle:""},o=void 0!==r.text?r.text:r.id,s="";switch(r.type){case"class":s="class_box";break;default:s="class_box"}e.setNode(r.id,{labelStyle:a.labelStyle,shape:s,labelText:o,classData:r,rx:0,ry:0,class:i,style:a.style,id:r.id,domId:r.domId,haveCallback:r.haveCallback,link:r.link,width:"group"===r.type?500:void 0,type:r.type,padding:Object(d.getConfig)().flowchart.padding}),c.log.info("setNode",{labelStyle:a.labelStyle,shape:s,labelText:o,rx:0,ry:0,class:i,style:a.style,id:r.id,width:"group"===r.type?500:void 0,type:r.type,padding:Object(d.getConfig)().flowchart.padding})}))},b=function(t,e){var n=0;t.forEach((function(i){n++;var a={classes:"relation"};a.pattern=1==i.relation.lineType?"dashed":"solid",a.id="id"+n,"arrow_open"===i.type?a.arrowhead="none":a.arrowhead="normal",c.log.info(a,i),a.startLabelRight="none"===i.relationTitle1?"":i.relationTitle1,a.endLabelLeft="none"===i.relationTitle2?"":i.relationTitle2,a.arrowTypeStart=C(i.relation.type1),a.arrowTypeEnd=C(i.relation.type2);var o="",s="";if(void 0!==i.style){var l=Object(p.getStylesFromArray)(i.style);o=l.style,s=l.labelStyle}else o="fill:none";a.style=o,a.labelStyle=s,void 0!==i.interpolate?a.curve=Object(p.interpolateToCurve)(i.interpolate,r.curveLinear):void 0!==t.defaultInterpolate?a.curve=Object(p.interpolateToCurve)(t.defaultInterpolate,r.curveLinear):a.curve=Object(p.interpolateToCurve)(m.curve,r.curveLinear),i.text=i.title,void 0===i.text?void 0!==i.style&&(a.arrowheadStyle="fill: #333"):(a.arrowheadStyle="fill: #333",a.labelpos="c",Object(d.getConfig)().flowchart.htmlLabels,a.labelType="text",a.label=i.text.replace(g.default.lineBreakRegex,"\n"),void 0===i.style&&(a.style=a.style||"stroke: #333; stroke-width: 1.5px;fill:none"),a.labelStyle=a.labelStyle.replace("color:","fill:")),e.setEdge(i.id1,i.id2,a,n)}))},_=function(t){for(var e=Object.keys(y),n=0;n "+t.w+": "+JSON.stringify(i.edge(t))),h.default.drawEdge(n,i.edge(t),i.edge(t).relation,m))}));var w=n.node().getBBox(),x=w.width+40,k=w.height+40;Object(p.configureSvgSize)(n,k,x,m.useMaxWidth);var C="".concat(w.x-20," ").concat(w.y-20," ").concat(x," ").concat(k);c.log.debug("viewBox ".concat(C)),n.attr("viewBox",C)},k=function(t,e){c.log.info("Drawing class"),l.default.clear(),u.parser.parse(t);var n=Object(d.getConfig)().flowchart;c.log.info("config:",n);var i=n.nodeSpacing||50,a=n.rankSpacing||50,o=new s.a.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:"TD",nodesep:i,ranksep:a,marginx:8,marginy:8}).setDefaultEdgeLabel((function(){return{}})),h=l.default.getClasses(),g=l.default.getRelations();c.log.info(g),v(h,o),b(g,o);var y=Object(r.select)('[id="'.concat(e,'"]'));y.attr("xmlns:xlink","http://www.w3.org/1999/xlink");var m=Object(r.select)("#"+e+" g");Object(f.render)(m,o,["aggregation","extension","composition","dependency"],"classDiagram",e);var _=y.node().getBBox(),w=_.width+16,x=_.height+16;if(c.log.debug("new ViewBox 0 0 ".concat(w," ").concat(x),"translate(".concat(8-o._label.marginx,", ").concat(8-o._label.marginy,")")),Object(p.configureSvgSize)(y,x,w,n.useMaxWidth),y.attr("viewBox","0 0 ".concat(w," ").concat(x)),y.select("g").attr("transform","translate(".concat(8-o._label.marginx,", ").concat(8-_.y,")")),!n.htmlLabels)for(var k=document.querySelectorAll('[id="'+e+'"] .edgeLabel .label'),C=0;C "+t.w+": "+JSON.stringify(o.edge(t))),h.default.drawEdge(i,o.edge(t),o.edge(t).relation,p))}));var w=i.node().getBBox(),x=w.width+40,k=w.height+40;Object(d.configureSvgSize)(i,k,x,p.useMaxWidth);var C="".concat(w.x-20," ").concat(w.y-20," ").concat(x," ").concat(k);c.log.debug("viewBox ".concat(C)),i.attr("viewBox",C)};e.default={setConf:y,draw:m}},"./src/diagrams/class/parser/classDiagram.jison":function(t,e,n){(function(t,r){var i=function(){var t=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},e=[1,7],n=[1,6],r=[1,14],i=[1,25],a=[1,28],o=[1,26],s=[1,27],c=[1,29],l=[1,30],u=[1,31],h=[1,32],d=[1,35],f=[1,36],p=[1,37],g=[1,38],y=[10,19],m=[1,50],v=[1,51],b=[1,52],_=[1,53],w=[1,54],x=[1,55],k=[10,19,26,33,34,42,45,46,47,48,49,50,55,57],C=[10,19,24,26,33,34,38,42,45,46,47,48,49,50,55,57,72,73,74,75],T=[10,13,17,19],E=[42,72,73,74,75],S=[42,49,50,72,73,74,75],O=[42,45,46,47,48,72,73,74,75],A=[10,19,26],M=[1,87],D={trace:function(){},yy:{},symbols_:{error:2,start:3,mermaidDoc:4,directive:5,graphConfig:6,openDirective:7,typeDirective:8,closeDirective:9,NEWLINE:10,":":11,argDirective:12,open_directive:13,type_directive:14,arg_directive:15,close_directive:16,CLASS_DIAGRAM:17,statements:18,EOF:19,statement:20,className:21,alphaNumToken:22,classLiteralName:23,GENERICTYPE:24,relationStatement:25,LABEL:26,classStatement:27,methodStatement:28,annotationStatement:29,clickStatement:30,cssClassStatement:31,CLASS:32,STYLE_SEPARATOR:33,STRUCT_START:34,members:35,STRUCT_STOP:36,ANNOTATION_START:37,ANNOTATION_END:38,MEMBER:39,SEPARATOR:40,relation:41,STR:42,relationType:43,lineType:44,AGGREGATION:45,EXTENSION:46,COMPOSITION:47,DEPENDENCY:48,LINE:49,DOTTED_LINE:50,CALLBACK:51,LINK:52,LINK_TARGET:53,CLICK:54,CALLBACK_NAME:55,CALLBACK_ARGS:56,HREF:57,CSSCLASS:58,commentToken:59,textToken:60,graphCodeTokens:61,textNoTagsToken:62,TAGSTART:63,TAGEND:64,"==":65,"--":66,PCT:67,DEFAULT:68,SPACE:69,MINUS:70,keywords:71,UNICODE_TEXT:72,NUM:73,ALPHA:74,BQUOTE_STR:75,$accept:0,$end:1},terminals_:{2:"error",10:"NEWLINE",11:":",13:"open_directive",14:"type_directive",15:"arg_directive",16:"close_directive",17:"CLASS_DIAGRAM",19:"EOF",24:"GENERICTYPE",26:"LABEL",32:"CLASS",33:"STYLE_SEPARATOR",34:"STRUCT_START",36:"STRUCT_STOP",37:"ANNOTATION_START",38:"ANNOTATION_END",39:"MEMBER",40:"SEPARATOR",42:"STR",45:"AGGREGATION",46:"EXTENSION",47:"COMPOSITION",48:"DEPENDENCY",49:"LINE",50:"DOTTED_LINE",51:"CALLBACK",52:"LINK",53:"LINK_TARGET",54:"CLICK",55:"CALLBACK_NAME",56:"CALLBACK_ARGS",57:"HREF",58:"CSSCLASS",61:"graphCodeTokens",63:"TAGSTART",64:"TAGEND",65:"==",66:"--",67:"PCT",68:"DEFAULT",69:"SPACE",70:"MINUS",71:"keywords",72:"UNICODE_TEXT",73:"NUM",74:"ALPHA",75:"BQUOTE_STR"},productions_:[0,[3,1],[3,2],[4,1],[5,4],[5,6],[7,1],[8,1],[12,1],[9,1],[6,4],[18,1],[18,2],[18,3],[21,1],[21,1],[21,2],[21,2],[21,2],[20,1],[20,2],[20,1],[20,1],[20,1],[20,1],[20,1],[20,1],[27,2],[27,4],[27,5],[27,7],[29,4],[35,1],[35,2],[28,1],[28,2],[28,1],[28,1],[25,3],[25,4],[25,4],[25,5],[41,3],[41,2],[41,2],[41,1],[43,1],[43,1],[43,1],[43,1],[44,1],[44,1],[30,3],[30,4],[30,3],[30,4],[30,4],[30,5],[30,3],[30,4],[30,4],[30,5],[30,3],[30,4],[30,4],[30,5],[31,3],[59,1],[59,1],[60,1],[60,1],[60,1],[60,1],[60,1],[60,1],[60,1],[62,1],[62,1],[62,1],[62,1],[22,1],[22,1],[22,1],[23,1]],performAction:function(t,e,n,r,i,a,o){var s=a.length-1;switch(i){case 6:r.parseDirective("%%{","open_directive");break;case 7:r.parseDirective(a[s],"type_directive");break;case 8:a[s]=a[s].trim().replace(/'/g,'"'),r.parseDirective(a[s],"arg_directive");break;case 9:r.parseDirective("}%%","close_directive","class");break;case 14:case 15:this.$=a[s];break;case 16:this.$=a[s-1]+a[s];break;case 17:case 18:this.$=a[s-1]+"~"+a[s];break;case 19:r.addRelation(a[s]);break;case 20:a[s-1].title=r.cleanupLabel(a[s]),r.addRelation(a[s-1]);break;case 27:r.addClass(a[s]);break;case 28:r.addClass(a[s-2]),r.setCssClass(a[s-2],a[s]);break;case 29:r.addClass(a[s-3]),r.addMembers(a[s-3],a[s-1]);break;case 30:r.addClass(a[s-5]),r.setCssClass(a[s-5],a[s-3]),r.addMembers(a[s-5],a[s-1]);break;case 31:r.addAnnotation(a[s],a[s-2]);break;case 32:this.$=[a[s]];break;case 33:a[s].push(a[s-1]),this.$=a[s];break;case 34:break;case 35:r.addMember(a[s-1],r.cleanupLabel(a[s]));break;case 36:case 37:break;case 38:this.$={id1:a[s-2],id2:a[s],relation:a[s-1],relationTitle1:"none",relationTitle2:"none"};break;case 39:this.$={id1:a[s-3],id2:a[s],relation:a[s-1],relationTitle1:a[s-2],relationTitle2:"none"};break;case 40:this.$={id1:a[s-3],id2:a[s],relation:a[s-2],relationTitle1:"none",relationTitle2:a[s-1]};break;case 41:this.$={id1:a[s-4],id2:a[s],relation:a[s-2],relationTitle1:a[s-3],relationTitle2:a[s-1]};break;case 42:this.$={type1:a[s-2],type2:a[s],lineType:a[s-1]};break;case 43:this.$={type1:"none",type2:a[s],lineType:a[s-1]};break;case 44:this.$={type1:a[s-1],type2:"none",lineType:a[s]};break;case 45:this.$={type1:"none",type2:"none",lineType:a[s]};break;case 46:this.$=r.relationType.AGGREGATION;break;case 47:this.$=r.relationType.EXTENSION;break;case 48:this.$=r.relationType.COMPOSITION;break;case 49:this.$=r.relationType.DEPENDENCY;break;case 50:this.$=r.lineType.LINE;break;case 51:this.$=r.lineType.DOTTED_LINE;break;case 52:case 58:this.$=a[s-2],r.setClickEvent(a[s-1],a[s]);break;case 53:case 59:this.$=a[s-3],r.setClickEvent(a[s-2],a[s-1]),r.setTooltip(a[s-2],a[s]);break;case 54:case 62:this.$=a[s-2],r.setLink(a[s-1],a[s]);break;case 55:this.$=a[s-3],r.setLink(a[s-2],a[s-1],a[s]);break;case 56:case 64:this.$=a[s-3],r.setLink(a[s-2],a[s-1]),r.setTooltip(a[s-2],a[s]);break;case 57:case 65:this.$=a[s-4],r.setLink(a[s-3],a[s-2],a[s]),r.setTooltip(a[s-3],a[s-1]);break;case 60:this.$=a[s-3],r.setClickEvent(a[s-2],a[s-1],a[s]);break;case 61:this.$=a[s-4],r.setClickEvent(a[s-3],a[s-2],a[s-1]),r.setTooltip(a[s-3],a[s]);break;case 63:this.$=a[s-3],r.setLink(a[s-2],a[s-1],a[s]);break;case 66:r.setCssClass(a[s-1],a[s])}},table:[{3:1,4:2,5:3,6:4,7:5,13:e,17:n},{1:[3]},{1:[2,1]},{3:8,4:2,5:3,6:4,7:5,13:e,17:n},{1:[2,3]},{8:9,14:[1,10]},{10:[1,11]},{14:[2,6]},{1:[2,2]},{9:12,11:[1,13],16:r},t([11,16],[2,7]),{5:23,7:5,13:e,18:15,20:16,21:24,22:33,23:34,25:17,27:18,28:19,29:20,30:21,31:22,32:i,37:a,39:o,40:s,51:c,52:l,54:u,58:h,72:d,73:f,74:p,75:g},{10:[1,39]},{12:40,15:[1,41]},{10:[2,9]},{19:[1,42]},{10:[1,43],19:[2,11]},t(y,[2,19],{26:[1,44]}),t(y,[2,21]),t(y,[2,22]),t(y,[2,23]),t(y,[2,24]),t(y,[2,25]),t(y,[2,26]),t(y,[2,34],{41:45,43:48,44:49,26:[1,47],42:[1,46],45:m,46:v,47:b,48:_,49:w,50:x}),{21:56,22:33,23:34,72:d,73:f,74:p,75:g},t(y,[2,36]),t(y,[2,37]),{22:57,72:d,73:f,74:p},{21:58,22:33,23:34,72:d,73:f,74:p,75:g},{21:59,22:33,23:34,72:d,73:f,74:p,75:g},{21:60,22:33,23:34,72:d,73:f,74:p,75:g},{42:[1,61]},t(k,[2,14],{22:33,23:34,21:62,24:[1,63],72:d,73:f,74:p,75:g}),t(k,[2,15],{24:[1,64]}),t(C,[2,80]),t(C,[2,81]),t(C,[2,82]),t([10,19,24,26,33,34,42,45,46,47,48,49,50,55,57],[2,83]),t(T,[2,4]),{9:65,16:r},{16:[2,8]},{1:[2,10]},{5:23,7:5,13:e,18:66,19:[2,12],20:16,21:24,22:33,23:34,25:17,27:18,28:19,29:20,30:21,31:22,32:i,37:a,39:o,40:s,51:c,52:l,54:u,58:h,72:d,73:f,74:p,75:g},t(y,[2,20]),{21:67,22:33,23:34,42:[1,68],72:d,73:f,74:p,75:g},{41:69,43:48,44:49,45:m,46:v,47:b,48:_,49:w,50:x},t(y,[2,35]),{44:70,49:w,50:x},t(E,[2,45],{43:71,45:m,46:v,47:b,48:_}),t(S,[2,46]),t(S,[2,47]),t(S,[2,48]),t(S,[2,49]),t(O,[2,50]),t(O,[2,51]),t(y,[2,27],{33:[1,72],34:[1,73]}),{38:[1,74]},{42:[1,75]},{42:[1,76]},{55:[1,77],57:[1,78]},{22:79,72:d,73:f,74:p},t(k,[2,16]),t(k,[2,17]),t(k,[2,18]),{10:[1,80]},{19:[2,13]},t(A,[2,38]),{21:81,22:33,23:34,72:d,73:f,74:p,75:g},{21:82,22:33,23:34,42:[1,83],72:d,73:f,74:p,75:g},t(E,[2,44],{43:84,45:m,46:v,47:b,48:_}),t(E,[2,43]),{22:85,72:d,73:f,74:p},{35:86,39:M},{21:88,22:33,23:34,72:d,73:f,74:p,75:g},t(y,[2,52],{42:[1,89]}),t(y,[2,54],{42:[1,91],53:[1,90]}),t(y,[2,58],{42:[1,92],56:[1,93]}),t(y,[2,62],{42:[1,95],53:[1,94]}),t(y,[2,66]),t(T,[2,5]),t(A,[2,40]),t(A,[2,39]),{21:96,22:33,23:34,72:d,73:f,74:p,75:g},t(E,[2,42]),t(y,[2,28],{34:[1,97]}),{36:[1,98]},{35:99,36:[2,32],39:M},t(y,[2,31]),t(y,[2,53]),t(y,[2,55]),t(y,[2,56],{53:[1,100]}),t(y,[2,59]),t(y,[2,60],{42:[1,101]}),t(y,[2,63]),t(y,[2,64],{53:[1,102]}),t(A,[2,41]),{35:103,39:M},t(y,[2,29]),{36:[2,33]},t(y,[2,57]),t(y,[2,61]),t(y,[2,65]),{36:[1,104]},t(y,[2,30])],defaultActions:{2:[2,1],4:[2,3],7:[2,6],8:[2,2],14:[2,9],41:[2,8],42:[2,10],66:[2,13],99:[2,33]},parseError:function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)},parse:function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,s="",c=0,l=0,u=2,h=1,d=a.slice.call(arguments,1),f=Object.create(this.lexer),p={yy:{}};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p.yy[g]=this.yy[g]);f.setInput(t,p.yy),p.yy.lexer=f,p.yy.parser=this,void 0===f.yylloc&&(f.yylloc={});var y=f.yylloc;a.push(y);var m=f.options&&f.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||f.lex()||h)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof p.yy.parseError?this.parseError=p.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var b,_,w,x,k,C,T,E,S={};;){if(_=n[n.length-1],this.defaultActions[_]?w=this.defaultActions[_]:(null==b&&(b=v()),w=o[_]&&o[_][b]),void 0===w||!w.length||!w[0]){var O="";for(k in E=[],o[_])this.terminals_[k]&&k>u&&E.push("'"+this.terminals_[k]+"'");O=f.showPosition?"Parse error on line "+(c+1)+":\n"+f.showPosition()+"\nExpecting "+E.join(", ")+", got '"+(this.terminals_[b]||b)+"'":"Parse error on line "+(c+1)+": Unexpected "+(b==h?"end of input":"'"+(this.terminals_[b]||b)+"'"),this.parseError(O,{text:f.match,token:this.terminals_[b]||b,line:f.yylineno,loc:y,expected:E})}if(w[0]instanceof Array&&w.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+b);switch(w[0]){case 1:n.push(b),i.push(f.yytext),a.push(f.yylloc),n.push(w[1]),b=null,l=f.yyleng,s=f.yytext,c=f.yylineno,y=f.yylloc;break;case 2:if(C=this.productions_[w[1]][1],S.$=i[i.length-C],S._$={first_line:a[a.length-(C||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(C||1)].first_column,last_column:a[a.length-1].last_column},m&&(S._$.range=[a[a.length-(C||1)].range[0],a[a.length-1].range[1]]),void 0!==(x=this.performAction.apply(S,[s,l,c,p.yy,w[1],i,a].concat(d))))return x;C&&(n=n.slice(0,-1*C*2),i=i.slice(0,-1*C),a=a.slice(0,-1*C)),n.push(this.productions_[w[1]][0]),i.push(S.$),a.push(S._$),T=o[n[n.length-2]][n[n.length-1]],n.push(T);break;case 3:return!0}}return!0}},j={EOF:1,parseError:function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},setInput:function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},input:function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},unput:function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(t){this.unput(this.match.slice(t))},pastInput:function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},test_match:function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){var t=this.next();return t||this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},pushState:function(t){this.begin(t)},stateStackSize:function(){return this.conditionStack.length},options:{},performAction:function(t,e,n,r){switch(n){case 0:return this.begin("open_directive"),13;case 1:return this.begin("type_directive"),14;case 2:return this.popState(),this.begin("arg_directive"),11;case 3:return this.popState(),this.popState(),16;case 4:return 15;case 5:case 6:break;case 7:return 10;case 8:break;case 9:case 10:return 17;case 11:return this.begin("struct"),34;case 12:return"EOF_IN_STRUCT";case 13:return"OPEN_IN_STRUCT";case 14:return this.popState(),36;case 15:break;case 16:return"MEMBER";case 17:return 32;case 18:return 58;case 19:return 51;case 20:return 52;case 21:return 54;case 22:return 37;case 23:return 38;case 24:this.begin("generic");break;case 25:this.popState();break;case 26:return"GENERICTYPE";case 27:this.begin("string");break;case 28:this.popState();break;case 29:return"STR";case 30:this.begin("bqstring");break;case 31:this.popState();break;case 32:return"BQUOTE_STR";case 33:this.begin("href");break;case 34:this.popState();break;case 35:return 57;case 36:this.begin("callback_name");break;case 37:this.popState();break;case 38:this.popState(),this.begin("callback_args");break;case 39:return 55;case 40:this.popState();break;case 41:return 56;case 42:case 43:case 44:case 45:return 53;case 46:case 47:return 46;case 48:case 49:return 48;case 50:return 47;case 51:return 45;case 52:return 49;case 53:return 50;case 54:return 26;case 55:return 33;case 56:return 70;case 57:return"DOT";case 58:return"PLUS";case 59:return 67;case 60:case 61:return"EQUALS";case 62:return 74;case 63:return"PUNCTUATION";case 64:return 73;case 65:return 72;case 66:return 69;case 67:return 19}},rules:[/^(?:%%\{)/,/^(?:((?:(?!\}%%)[^:.])*))/,/^(?::)/,/^(?:\}%%)/,/^(?:((?:(?!\}%%).|\n)*))/,/^(?:%%(?!\{)*[^\n]*(\r?\n?)+)/,/^(?:%%[^\n]*(\r?\n)*)/,/^(?:(\r?\n)+)/,/^(?:\s+)/,/^(?:classDiagram-v2\b)/,/^(?:classDiagram\b)/,/^(?:[{])/,/^(?:$)/,/^(?:[{])/,/^(?:[}])/,/^(?:[\n])/,/^(?:[^{}\n]*)/,/^(?:class\b)/,/^(?:cssClass\b)/,/^(?:callback\b)/,/^(?:link\b)/,/^(?:click\b)/,/^(?:<<)/,/^(?:>>)/,/^(?:[~])/,/^(?:[~])/,/^(?:[^~]*)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:[`])/,/^(?:[`])/,/^(?:[^`]+)/,/^(?:href[\s]+["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:--)/,/^(?:\.\.)/,/^(?::{1}[^:\n;]+)/,/^(?::{3})/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:\w+)/,/^(?:[!"#$%&'*+,-.`?\\/])/,/^(?:[0-9]+)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\s)/,/^(?:$)/],conditions:{arg_directive:{rules:[3,4],inclusive:!1},type_directive:{rules:[2,3],inclusive:!1},open_directive:{rules:[1],inclusive:!1},callback_args:{rules:[40,41],inclusive:!1},callback_name:{rules:[37,38,39],inclusive:!1},href:{rules:[34,35],inclusive:!1},struct:{rules:[12,13,14,15,16],inclusive:!1},generic:{rules:[25,26],inclusive:!1},bqstring:{rules:[31,32],inclusive:!1},string:{rules:[28,29],inclusive:!1},INITIAL:{rules:[0,5,6,7,8,9,10,11,17,18,19,20,21,22,23,24,27,30,33,36,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67],inclusive:!0}}};function N(){this.yy={}}return D.lexer=j,N.prototype=D,D.Parser=N,new N}();e.parser=i,e.Parser=i.Parser,e.parse=function(){return i.parse.apply(i,arguments)},e.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),t.exit(1));var i=n("./node_modules/node-libs-browser/mock/empty.js").readFileSync(n("./node_modules/path-browserify/index.js").normalize(r[1]),"utf8");return e.parser.parse(i)},n.c[n.s]===r&&e.main(t.argv.slice(1))}).call(this,n("./node_modules/process/browser.js"),n("./node_modules/webpack/buildin/module.js")(t))},"./src/diagrams/class/styles.js":function(t,e,n){n.r(e),e.default=function(t){return"g.classGroup text {\n fill: ".concat(t.nodeBorder,";\n fill: ").concat(t.classText,";\n stroke: none;\n font-family: ").concat(t.fontFamily,";\n font-size: 10px;\n\n .title {\n font-weight: bolder;\n }\n\n}\n\n.classTitle {\n font-weight: bolder;\n}\n.node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ").concat(t.mainBkg,";\n stroke: ").concat(t.nodeBorder,";\n stroke-width: 1px;\n }\n\n\n.divider {\n stroke: ").concat(t.nodeBorder,";\n stroke: 1;\n}\n\ng.clickable {\n cursor: pointer;\n}\n\ng.classGroup rect {\n fill: ").concat(t.mainBkg,";\n stroke: ").concat(t.nodeBorder,";\n}\n\ng.classGroup line {\n stroke: ").concat(t.nodeBorder,";\n stroke-width: 1;\n}\n\n.classLabel .box {\n stroke: none;\n stroke-width: 0;\n fill: ").concat(t.mainBkg,";\n opacity: 0.5;\n}\n\n.classLabel .label {\n fill: ").concat(t.nodeBorder,";\n font-size: 10px;\n}\n\n.relation {\n stroke: ").concat(t.lineColor,";\n stroke-width: 1;\n fill: none;\n}\n\n.dashed-line{\n stroke-dasharray: 3;\n}\n\n#compositionStart, .composition {\n fill: ").concat(t.lineColor," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#compositionEnd, .composition {\n fill: ").concat(t.lineColor," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#dependencyStart, .dependency {\n fill: ").concat(t.lineColor," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#dependencyStart, .dependency {\n fill: ").concat(t.lineColor," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#extensionStart, .extension {\n fill: ").concat(t.lineColor," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#extensionEnd, .extension {\n fill: ").concat(t.lineColor," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#aggregationStart, .aggregation {\n fill: ").concat(t.mainBkg," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#aggregationEnd, .aggregation {\n fill: ").concat(t.mainBkg," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n.edgeTerminals {\n font-size: 11px;\n}\n\n")}},"./src/diagrams/class/svgDraw.js":function(t,e,n){n.r(e),n.d(e,"drawEdge",(function(){return c})),n.d(e,"drawClass",(function(){return l})),n.d(e,"parseMember",(function(){return u}));var r=n("d3"),i=n("./src/diagrams/class/classDb.js"),a=n("./src/utils.js"),o=n("./src/logger.js"),s=0,c=function(t,e,n,c){var l=function(t){switch(t){case i.relationType.AGGREGATION:return"aggregation";case i.relationType.EXTENSION:return"extension";case i.relationType.COMPOSITION:return"composition";case i.relationType.DEPENDENCY:return"dependency"}};e.points=e.points.filter((function(t){return!Number.isNaN(t.y)}));var u,h,d=e.points,f=Object(r.line)().x((function(t){return t.x})).y((function(t){return t.y})).curve(r.curveBasis),p=t.append("path").attr("d",f(d)).attr("id","edge"+s).attr("class","relation"),g="";c.arrowMarkerAbsolute&&(g=(g=(g=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search).replace(/\(/g,"\\(")).replace(/\)/g,"\\)")),1==n.relation.lineType&&p.attr("class","relation dashed-line"),"none"!==n.relation.type1&&p.attr("marker-start","url("+g+"#"+l(n.relation.type1)+"Start)"),"none"!==n.relation.type2&&p.attr("marker-end","url("+g+"#"+l(n.relation.type2)+"End)");var y,m,v,b,_=e.points.length,w=a.default.calcLabelPosition(e.points);if(u=w.x,h=w.y,_%2!=0&&_>1){var x=a.default.calcCardinalityPosition("none"!==n.relation.type1,e.points,e.points[0]),k=a.default.calcCardinalityPosition("none"!==n.relation.type2,e.points,e.points[_-1]);o.log.debug("cardinality_1_point "+JSON.stringify(x)),o.log.debug("cardinality_2_point "+JSON.stringify(k)),y=x.x,m=x.y,v=k.x,b=k.y}if(void 0!==n.title){var C=t.append("g").attr("class","classLabel"),T=C.append("text").attr("class","label").attr("x",u).attr("y",h).attr("fill","red").attr("text-anchor","middle").text(n.title);window.label=T;var E=T.node().getBBox();C.insert("rect",":first-child").attr("class","box").attr("x",E.x-c.padding/2).attr("y",E.y-c.padding/2).attr("width",E.width+c.padding).attr("height",E.height+c.padding)}o.log.info("Rendering relation "+JSON.stringify(n)),void 0!==n.relationTitle1&&"none"!==n.relationTitle1&&t.append("g").attr("class","cardinality").append("text").attr("class","type1").attr("x",y).attr("y",m).attr("fill","black").attr("font-size","6").text(n.relationTitle1),void 0!==n.relationTitle2&&"none"!==n.relationTitle2&&t.append("g").attr("class","cardinality").append("text").attr("class","type2").attr("x",v).attr("y",b).attr("fill","black").attr("font-size","6").text(n.relationTitle2),s++},l=function(t,e,n){o.log.info("Rendering class "+e);var r,a=e.id,s={id:a,label:e.id,width:0,height:0},c=t.append("g").attr("id",Object(i.lookUpDomId)(a)).attr("class","classGroup");r=e.link?c.append("svg:a").attr("xlink:href",e.link).attr("target",e.linkTarget).append("text").attr("y",n.textHeight+n.padding).attr("x",0):c.append("text").attr("y",n.textHeight+n.padding).attr("x",0);var l=!0;e.annotations.forEach((function(t){var e=r.append("tspan").text("«"+t+"»");l||e.attr("dy",n.textHeight),l=!1}));var u=e.id;void 0!==e.type&&""!==e.type&&(u+="<"+e.type+">");var h=r.append("tspan").text(u).attr("class","title");l||h.attr("dy",n.textHeight);var d=r.node().getBBox().height,f=c.append("line").attr("x1",0).attr("y1",n.padding+d+n.dividerMargin/2).attr("y2",n.padding+d+n.dividerMargin/2),g=c.append("text").attr("x",n.padding).attr("y",d+n.dividerMargin+n.textHeight).attr("fill","white").attr("class","classText");l=!0,e.members.forEach((function(t){p(g,t,l,n),l=!1}));var y=g.node().getBBox(),m=c.append("line").attr("x1",0).attr("y1",n.padding+d+n.dividerMargin+y.height).attr("y2",n.padding+d+n.dividerMargin+y.height),v=c.append("text").attr("x",n.padding).attr("y",d+2*n.dividerMargin+y.height+n.textHeight).attr("fill","white").attr("class","classText");l=!0,e.methods.forEach((function(t){p(v,t,l,n),l=!1}));var b=c.node().getBBox(),_=" ";e.cssClasses.length>0&&(_+=e.cssClasses.join(" "));var w=c.insert("rect",":first-child").attr("x",0).attr("y",0).attr("width",b.width+2*n.padding).attr("height",b.height+n.padding+.5*n.dividerMargin).attr("class",_).node().getBBox().width;return r.node().childNodes.forEach((function(t){t.setAttribute("x",(w-t.getBBox().width)/2)})),e.tooltip&&r.insert("title").text(e.tooltip),f.attr("x2",w),m.attr("x2",w),s.width=w,s.height=b.height+n.padding+.5*n.dividerMargin,s},u=function(t){var e=t.match(/(\+|-|~|#)?(\w+)(~\w+~|\[\])?\s+(\w+)/),n=t.match(/^([+|\-|~|#])?(\w+) *\( *(.*)\) *(\*|\$)? *(\w*[~|[\]]*\s*\w*~?)$/);return e&&!n?h(e):n?d(n):f(t)},h=function(t){var e="";try{e=(t[1]?t[1].trim():"")+(t[2]?t[2].trim():"")+(t[3]?g(t[3].trim()):"")+" "+(t[4]?t[4].trim():"")}catch(n){e=t}return{displayText:e,cssStyle:""}},d=function(t){var e="",n="";try{var r=t[1]?t[1].trim():"",i=t[2]?t[2].trim():"",a=t[3]?g(t[3].trim()):"",o=t[4]?t[4].trim():"";n=r+i+"("+a+")"+(t[5]?" : "+g(t[5]).trim():""),e=y(o)}catch(s){n=t}return{displayText:n,cssStyle:e}},f=function(t){var e="",n="",r="",i=t.indexOf("("),a=t.indexOf(")");if(i>1&&a>i&&a<=t.length){var o="",s="",c=t.substring(0,1);c.match(/\w/)?s=t.substring(0,i).trim():(c.match(/\+|-|~|#/)&&(o=c),s=t.substring(1,i).trim());var l=t.substring(i+1,a),u=t.substring(a+1,1);n=y(u),e=o+s+"("+g(l.trim())+")",a<"".length&&""!==(r=t.substring(a+2).trim())&&(r=" : "+g(r))}else e=g(t);return{displayText:e,cssStyle:n}},p=function(t,e,n,r){var i=u(e),a=t.append("tspan").attr("x",r.padding).text(i.displayText);""!==i.cssStyle&&a.attr("style",i.cssStyle),n||a.attr("dy",r.textHeight)},g=function t(e){var n=e;return-1!=e.indexOf("~")?t(n=(n=n.replace("~","<")).replace("~",">")):n},y=function(t){switch(t){case"*":return"font-style:italic;";case"$":return"text-decoration:underline;";default:return""}};e.default={drawClass:l,drawEdge:c,parseMember:u}},"./src/diagrams/common/common.js":function(t,e,n){n.r(e),n.d(e,"getRows",(function(){return a})),n.d(e,"removeScript",(function(){return o})),n.d(e,"sanitizeText",(function(){return s})),n.d(e,"lineBreakRegex",(function(){return c})),n.d(e,"hasBreaks",(function(){return l})),n.d(e,"splitBreaks",(function(){return u})),n.d(e,"evaluate",(function(){return f}));var r=n("dompurify"),i=n.n(r),a=function(t){if(!t)return 1;var e=d(t);return(e=e.replace(/\\n/g,"#br#")).split("#br#")},o=function(t){for(var e="",n=0;n>=0;){if(!((n=t.indexOf("=0)){e+=t,n=-1;break}e+=t.substr(0,n),(n=(t=t.substr(n+1)).indexOf("<\/script>"))>=0&&(n+=9,t=t.substr(n))}return e=(e=(e=e.replace(/javascript:/g,"#")).replace(/onerror=/g,"onerror:")).replace(/