@antv/g-svg 1.0.0-alpha.3 → 1.0.0-alpha.34
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.umd.js +16 -0
- package/es/ContextRegisterPlugin.d.ts +6 -0
- package/es/ContextRegisterPlugin.js +28 -0
- package/{dist → es}/SVGContextService.d.ts +15 -15
- package/es/SVGContextService.js +81 -0
- package/es/index.d.ts +8 -0
- package/es/index.js +31 -0
- package/{dist → es}/utils/format.d.ts +6 -6
- package/es/utils/format.js +34 -0
- package/lib/ContextRegisterPlugin.d.ts +6 -0
- package/lib/ContextRegisterPlugin.js +37 -0
- package/lib/SVGContextService.d.ts +15 -0
- package/lib/SVGContextService.js +91 -0
- package/lib/index.d.ts +8 -0
- package/lib/index.js +54 -0
- package/lib/utils/format.d.ts +6 -0
- package/lib/utils/format.js +42 -0
- package/package.json +21 -13
- package/dist/index.d.ts +0 -4
- package/dist/index.esm.js +0 -411
- package/dist/index.js +0 -415
- package/dist/utils/dom.d.ts +0 -7
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
!function(t,n){"object"==typeof exports&&"object"==typeof module?module.exports=n(require("mana-syringe"),require("@antv/g")):"function"==typeof define&&define.amd?define(["mana-syringe","@antv/g"],n):"object"==typeof exports?exports.SVG=n(require("mana-syringe"),require("@antv/g")):(t.G=t.G||{},t.G.SVG=n(t.G.ManaSyringe,t.G))}(window,(function(t,n){return function(t){var n={};function r(e){if(n[e])return n[e].exports;var u=n[e]={i:e,l:!1,exports:{}};return t[e].call(u.exports,u,u.exports,r),u.l=!0,u.exports}return r.m=t,r.c=n,r.d=function(t,n,e){r.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:e})},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.t=function(t,n){if(1&n&&(t=r(t)),8&n)return t;if(4&n&&"object"==typeof t&&t&&t.__esModule)return t;var e=Object.create(null);if(r.r(e),Object.defineProperty(e,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var u in t)r.d(e,u,function(n){return t[n]}.bind(null,u));return e},r.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(n,"a",n),n},r.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},r.p="",r(r.s=27)}([function(t,n,r){"use strict";r.r(n),r.d(n,"__extends",(function(){return u})),r.d(n,"__assign",(function(){return o})),r.d(n,"__rest",(function(){return i})),r.d(n,"__decorate",(function(){return a})),r.d(n,"__param",(function(){return c})),r.d(n,"__metadata",(function(){return f})),r.d(n,"__awaiter",(function(){return s})),r.d(n,"__generator",(function(){return d})),r.d(n,"__createBinding",(function(){return l})),r.d(n,"__exportStar",(function(){return h})),r.d(n,"__values",(function(){return p})),r.d(n,"__read",(function(){return v})),r.d(n,"__spread",(function(){return m})),r.d(n,"__spreadArrays",(function(){return b})),r.d(n,"__spreadArray",(function(){return y})),r.d(n,"__await",(function(){return M})),r.d(n,"__asyncGenerator",(function(){return g})),r.d(n,"__asyncDelegator",(function(){return w})),r.d(n,"__asyncValues",(function(){return A})),r.d(n,"__makeTemplateObject",(function(){return S})),r.d(n,"__importStar",(function(){return _})),r.d(n,"__importDefault",(function(){return x})),r.d(n,"__classPrivateFieldGet",(function(){return O})),r.d(n,"__classPrivateFieldSet",(function(){return P}));
|
|
2
|
+
/*! *****************************************************************************
|
|
3
|
+
Copyright (c) Microsoft Corporation.
|
|
4
|
+
|
|
5
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
6
|
+
purpose with or without fee is hereby granted.
|
|
7
|
+
|
|
8
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
9
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
10
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
11
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
12
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
13
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
14
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
15
|
+
***************************************************************************** */
|
|
16
|
+
var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])})(t,n)};function u(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}var o=function(){return(o=Object.assign||function(t){for(var n,r=1,e=arguments.length;r<e;r++)for(var u in n=arguments[r])Object.prototype.hasOwnProperty.call(n,u)&&(t[u]=n[u]);return t}).apply(this,arguments)};function i(t,n){var r={};for(var e in t)Object.prototype.hasOwnProperty.call(t,e)&&n.indexOf(e)<0&&(r[e]=t[e]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var u=0;for(e=Object.getOwnPropertySymbols(t);u<e.length;u++)n.indexOf(e[u])<0&&Object.prototype.propertyIsEnumerable.call(t,e[u])&&(r[e[u]]=t[e[u]])}return r}function a(t,n,r,e){var u,o=arguments.length,i=o<3?n:null===e?e=Object.getOwnPropertyDescriptor(n,r):e;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)i=Reflect.decorate(t,n,r,e);else for(var a=t.length-1;a>=0;a--)(u=t[a])&&(i=(o<3?u(i):o>3?u(n,r,i):u(n,r))||i);return o>3&&i&&Object.defineProperty(n,r,i),i}function c(t,n){return function(r,e){n(r,e,t)}}function f(t,n){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,n)}function s(t,n,r,e){return new(r||(r=Promise))((function(u,o){function i(t){try{c(e.next(t))}catch(t){o(t)}}function a(t){try{c(e.throw(t))}catch(t){o(t)}}function c(t){var n;t.done?u(t.value):(n=t.value,n instanceof r?n:new r((function(t){t(n)}))).then(i,a)}c((e=e.apply(t,n||[])).next())}))}function d(t,n){var r,e,u,o,i={label:0,sent:function(){if(1&u[0])throw u[1];return u[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(r)throw new TypeError("Generator is already executing.");for(;i;)try{if(r=1,e&&(u=2&o[0]?e.return:o[0]?e.throw||((u=e.return)&&u.call(e),0):e.next)&&!(u=u.call(e,o[1])).done)return u;switch(e=0,u&&(o=[2&o[0],u.value]),o[0]){case 0:case 1:u=o;break;case 4:return i.label++,{value:o[1],done:!1};case 5:i.label++,e=o[1],o=[0];continue;case 7:o=i.ops.pop(),i.trys.pop();continue;default:if(!(u=i.trys,(u=u.length>0&&u[u.length-1])||6!==o[0]&&2!==o[0])){i=0;continue}if(3===o[0]&&(!u||o[1]>u[0]&&o[1]<u[3])){i.label=o[1];break}if(6===o[0]&&i.label<u[1]){i.label=u[1],u=o;break}if(u&&i.label<u[2]){i.label=u[2],i.ops.push(o);break}u[2]&&i.ops.pop(),i.trys.pop();continue}o=n.call(t,i)}catch(t){o=[6,t],e=0}finally{r=u=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,a])}}}var l=Object.create?function(t,n,r,e){void 0===e&&(e=r),Object.defineProperty(t,e,{enumerable:!0,get:function(){return n[r]}})}:function(t,n,r,e){void 0===e&&(e=r),t[e]=n[r]};function h(t,n){for(var r in t)"default"===r||Object.prototype.hasOwnProperty.call(n,r)||l(n,t,r)}function p(t){var n="function"==typeof Symbol&&Symbol.iterator,r=n&&t[n],e=0;if(r)return r.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&e>=t.length&&(t=void 0),{value:t&&t[e++],done:!t}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")}function v(t,n){var r="function"==typeof Symbol&&t[Symbol.iterator];if(!r)return t;var e,u,o=r.call(t),i=[];try{for(;(void 0===n||n-- >0)&&!(e=o.next()).done;)i.push(e.value)}catch(t){u={error:t}}finally{try{e&&!e.done&&(r=o.return)&&r.call(o)}finally{if(u)throw u.error}}return i}function m(){for(var t=[],n=0;n<arguments.length;n++)t=t.concat(v(arguments[n]));return t}function b(){for(var t=0,n=0,r=arguments.length;n<r;n++)t+=arguments[n].length;var e=Array(t),u=0;for(n=0;n<r;n++)for(var o=arguments[n],i=0,a=o.length;i<a;i++,u++)e[u]=o[i];return e}function y(t,n,r){if(r||2===arguments.length)for(var e,u=0,o=n.length;u<o;u++)!e&&u in n||(e||(e=Array.prototype.slice.call(n,0,u)),e[u]=n[u]);return t.concat(e||Array.prototype.slice.call(n))}function M(t){return this instanceof M?(this.v=t,this):new M(t)}function g(t,n,r){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e,u=r.apply(t,n||[]),o=[];return e={},i("next"),i("throw"),i("return"),e[Symbol.asyncIterator]=function(){return this},e;function i(t){u[t]&&(e[t]=function(n){return new Promise((function(r,e){o.push([t,n,r,e])>1||a(t,n)}))})}function a(t,n){try{(r=u[t](n)).value instanceof M?Promise.resolve(r.value.v).then(c,f):s(o[0][2],r)}catch(t){s(o[0][3],t)}var r}function c(t){a("next",t)}function f(t){a("throw",t)}function s(t,n){t(n),o.shift(),o.length&&a(o[0][0],o[0][1])}}function w(t){var n,r;return n={},e("next"),e("throw",(function(t){throw t})),e("return"),n[Symbol.iterator]=function(){return this},n;function e(e,u){n[e]=t[e]?function(n){return(r=!r)?{value:M(t[e](n)),done:"return"===e}:u?u(n):n}:u}}function A(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n,r=t[Symbol.asyncIterator];return r?r.call(t):(t=p(t),n={},e("next"),e("throw"),e("return"),n[Symbol.asyncIterator]=function(){return this},n);function e(r){n[r]=t[r]&&function(n){return new Promise((function(e,u){(function(t,n,r,e){Promise.resolve(e).then((function(n){t({value:n,done:r})}),n)})(e,u,(n=t[r](n)).done,n.value)}))}}}function S(t,n){return Object.defineProperty?Object.defineProperty(t,"raw",{value:n}):t.raw=n,t}var E=Object.create?function(t,n){Object.defineProperty(t,"default",{enumerable:!0,value:n})}:function(t,n){t.default=n};function _(t){if(t&&t.__esModule)return t;var n={};if(null!=t)for(var r in t)"default"!==r&&Object.prototype.hasOwnProperty.call(t,r)&&l(n,t,r);return E(n,t),n}function x(t){return t&&t.__esModule?t:{default:t}}function O(t,n,r,e){if("a"===r&&!e)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof n?t!==n||!e:!n.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===r?e:"a"===r?e.call(t):e?e.value:n.get(t)}function P(t,n,r,e,u){if("m"===e)throw new TypeError("Private method is not writable");if("a"===e&&!u)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof n?t!==n||!u:!n.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");return"a"===e?u.call(t,r):u?u.value=r:n.set(t,r),r}},function(n,r){n.exports=t},function(t,r){t.exports=n},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.createSVGElement=function(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}},function(t,n,r){"use strict";r.r(n),r.d(n,"contains",(function(){return u})),r.d(n,"includes",(function(){return u})),r.d(n,"difference",(function(){return i})),r.d(n,"find",(function(){return y})),r.d(n,"findIndex",(function(){return M})),r.d(n,"firstValue",(function(){return g})),r.d(n,"flatten",(function(){return w})),r.d(n,"flattenDeep",(function(){return S})),r.d(n,"getRange",(function(){return x})),r.d(n,"pull",(function(){return j})),r.d(n,"pullAt",(function(){return C})),r.d(n,"reduce",(function(){return G})),r.d(n,"remove",(function(){return L})),r.d(n,"sortBy",(function(){return k})),r.d(n,"union",(function(){return D})),r.d(n,"uniq",(function(){return q})),r.d(n,"valuesOfKey",(function(){return N})),r.d(n,"head",(function(){return I})),r.d(n,"last",(function(){return F})),r.d(n,"startsWith",(function(){return $})),r.d(n,"endsWith",(function(){return B})),r.d(n,"filter",(function(){return o})),r.d(n,"every",(function(){return W})),r.d(n,"some",(function(){return H})),r.d(n,"group",(function(){return X})),r.d(n,"groupBy",(function(){return z})),r.d(n,"groupToMap",(function(){return Y})),r.d(n,"getWrapBehavior",(function(){return Q})),r.d(n,"wrapBehavior",(function(){return Z})),r.d(n,"number2color",(function(){return J})),r.d(n,"parseRadius",(function(){return tt})),r.d(n,"clamp",(function(){return nt})),r.d(n,"fixedBase",(function(){return rt})),r.d(n,"isDecimal",(function(){return ut})),r.d(n,"isEven",(function(){return ot})),r.d(n,"isInteger",(function(){return it})),r.d(n,"isNegative",(function(){return at})),r.d(n,"isNumberEqual",(function(){return ct})),r.d(n,"isOdd",(function(){return ft})),r.d(n,"isPositive",(function(){return st})),r.d(n,"max",(function(){return E})),r.d(n,"maxBy",(function(){return dt})),r.d(n,"min",(function(){return _})),r.d(n,"minBy",(function(){return lt})),r.d(n,"mod",(function(){return ht})),r.d(n,"toDegree",(function(){return vt})),r.d(n,"toInteger",(function(){return mt})),r.d(n,"toRadian",(function(){return yt})),r.d(n,"forIn",(function(){return Mt})),r.d(n,"has",(function(){return gt})),r.d(n,"hasKey",(function(){return wt})),r.d(n,"hasValue",(function(){return St})),r.d(n,"keys",(function(){return p})),r.d(n,"isMatch",(function(){return v})),r.d(n,"values",(function(){return At})),r.d(n,"lowerCase",(function(){return _t})),r.d(n,"lowerFirst",(function(){return xt})),r.d(n,"substitute",(function(){return Ot})),r.d(n,"upperCase",(function(){return Pt})),r.d(n,"upperFirst",(function(){return Rt})),r.d(n,"getType",(function(){return Tt})),r.d(n,"isArguments",(function(){return Ct})),r.d(n,"isArray",(function(){return d})),r.d(n,"isArrayLike",(function(){return e})),r.d(n,"isBoolean",(function(){return Gt})),r.d(n,"isDate",(function(){return Lt})),r.d(n,"isError",(function(){return Vt})),r.d(n,"isFunction",(function(){return f})),r.d(n,"isFinite",(function(){return kt})),r.d(n,"isNil",(function(){return s})),r.d(n,"isNull",(function(){return qt})),r.d(n,"isNumber",(function(){return et})),r.d(n,"isObject",(function(){return l})),r.d(n,"isObjectLike",(function(){return m})),r.d(n,"isPlainObject",(function(){return b})),r.d(n,"isPrototype",(function(){return Nt})),r.d(n,"isRegExp",(function(){return It})),r.d(n,"isString",(function(){return V})),r.d(n,"isType",(function(){return c})),r.d(n,"isUndefined",(function(){return Ft})),r.d(n,"isElement",(function(){return $t})),r.d(n,"requestAnimationFrame",(function(){return Bt})),r.d(n,"clearAnimationFrame",(function(){return Wt})),r.d(n,"augment",(function(){return zt})),r.d(n,"clone",(function(){return Xt})),r.d(n,"debounce",(function(){return Qt})),r.d(n,"memoize",(function(){return Zt})),r.d(n,"deepMix",(function(){return Jt})),r.d(n,"each",(function(){return h})),r.d(n,"extend",(function(){return tn})),r.d(n,"indexOf",(function(){return nn})),r.d(n,"isEmpty",(function(){return en})),r.d(n,"isEqual",(function(){return on})),r.d(n,"isEqualWith",(function(){return an})),r.d(n,"map",(function(){return cn})),r.d(n,"mapValues",(function(){return sn})),r.d(n,"mix",(function(){return Ut})),r.d(n,"assign",(function(){return Ut})),r.d(n,"get",(function(){return dn})),r.d(n,"set",(function(){return ln})),r.d(n,"pick",(function(){return pn})),r.d(n,"omit",(function(){return vn})),r.d(n,"throttle",(function(){return mn})),r.d(n,"toArray",(function(){return bn})),r.d(n,"toString",(function(){return Et})),r.d(n,"uniqueId",(function(){return Mn})),r.d(n,"noop",(function(){return gn})),r.d(n,"identity",(function(){return wn})),r.d(n,"size",(function(){return An})),r.d(n,"measureTextWidth",(function(){return _n})),r.d(n,"getEllipsisText",(function(){return xn})),r.d(n,"Cache",(function(){return On}));var e=function(t){return null!==t&&"function"!=typeof t&&isFinite(t.length)},u=function(t,n){return!!e(t)&&t.indexOf(n)>-1},o=function(t,n){if(!e(t))return t;for(var r=[],u=0;u<t.length;u++){var o=t[u];n(o,u)&&r.push(o)}return r},i=function(t,n){return void 0===n&&(n=[]),o(t,(function(t){return!u(n,t)}))},a={}.toString,c=function(t,n){return a.call(t)==="[object "+n+"]"},f=function(t){return c(t,"Function")},s=function(t){return null==t},d=function(t){return Array.isArray?Array.isArray(t):c(t,"Array")},l=function(t){var n=typeof t;return null!==t&&"object"===n||"function"===n};var h=function(t,n){if(t)if(d(t))for(var r=0,e=t.length;r<e&&!1!==n(t[r],r);r++);else if(l(t))for(var u in t)if(t.hasOwnProperty(u)&&!1===n(t[u],u))break},p=Object.keys?function(t){return Object.keys(t)}:function(t){var n=[];return h(t,(function(r,e){f(t)&&"prototype"===e||n.push(e)})),n};var v=function(t,n){var r=p(n),e=r.length;if(s(t))return!e;for(var u=0;u<e;u+=1){var o=r[u];if(n[o]!==t[o]||!(o in t))return!1}return!0},m=function(t){return"object"==typeof t&&null!==t},b=function(t){if(!m(t)||!c(t,"Object"))return!1;if(null===Object.getPrototypeOf(t))return!0;for(var n=t;null!==Object.getPrototypeOf(n);)n=Object.getPrototypeOf(n);return Object.getPrototypeOf(t)===n};var y=function(t,n){if(!d(t))return null;var r;if(f(n)&&(r=n),b(n)&&(r=function(t){return v(t,n)}),r)for(var e=0;e<t.length;e+=1)if(r(t[e]))return t[e];return null};var M=function(t,n,r){void 0===r&&(r=0);for(var e=r;e<t.length;e++)if(n(t[e],e))return e;return-1},g=function(t,n){for(var r=null,e=0;e<t.length;e++){var u=t[e][n];if(!s(u)){r=d(u)?u[0]:u;break}}return r},w=function(t){if(!d(t))return[];for(var n=[],r=0;r<t.length;r++)n=n.concat(t[r]);return n},A=function(t,n){if(void 0===n&&(n=[]),d(t))for(var r=0;r<t.length;r+=1)A(t[r],n);else n.push(t);return n},S=A,E=function(t){if(d(t))return t.reduce((function(t,n){return Math.max(t,n)}),t[0])},_=function(t){if(d(t))return t.reduce((function(t,n){return Math.min(t,n)}),t[0])},x=function(t){var n=t.filter((function(t){return!isNaN(t)}));if(!n.length)return{min:0,max:0};if(d(t[0])){for(var r=[],e=0;e<t.length;e++)r=r.concat(t[e]);n=r}var u=E(n);return{min:_(n),max:u}},O=Array.prototype,P=O.splice,R=O.indexOf,j=function(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];for(var e=0;e<n.length;e++)for(var u=n[e],o=-1;(o=R.call(t,u))>-1;)P.call(t,o,1);return t},T=Array.prototype.splice,C=function(t,n){if(!e(t))return[];for(var r=t?n.length:0,u=r-1;r--;){var o=void 0,i=n[r];r!==u&&i===o||(o=i,T.call(t,i,1))}return t},G=function(t,n,r){if(!d(t)&&!b(t))return t;var e=r;return h(t,(function(t,r){e=n(e,t,r)})),e},L=function(t,n){var r=[];if(!e(t))return r;for(var u=-1,o=[],i=t.length;++u<i;){var a=t[u];n(a,u,t)&&(r.push(a),o.push(u))}return C(t,o),r},V=function(t){return c(t,"String")};var k=function(t,n){var r;if(f(n))r=function(t,r){return n(t)-n(r)};else{var e=[];V(n)?e.push(n):d(n)&&(e=n),r=function(t,n){for(var r=0;r<e.length;r+=1){var u=e[r];if(t[u]>n[u])return 1;if(t[u]<n[u])return-1}return 0}}return t.sort(r),t};function q(t,n){void 0===n&&(n=new Map);var r=[];if(Array.isArray(t))for(var e=0,u=t.length;e<u;e++){var o=t[e];n.has(o)||(r.push(o),n.set(o,!0))}return r}var D=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return q([].concat.apply([],t))},N=function(t,n){for(var r=[],e={},u=0;u<t.length;u++){var o=t[u][n];if(!s(o)){d(o)||(o=[o]);for(var i=0;i<o.length;i++){var a=o[i];e[a]||(r.push(a),e[a]=!0)}}}return r};function I(t){if(e(t))return t[0]}function F(t){if(e(t)){return t[t.length-1]}}var $=function(t,n){return!(!d(t)&&!V(t))&&t[0]===n};var B=function(t,n){return!(!d(t)&&!V(t))&&t[t.length-1]===n},W=function(t,n){for(var r=0;r<t.length;r++)if(!n(t[r],r))return!1;return!0},H=function(t,n){for(var r=0;r<t.length;r++)if(n(t[r],r))return!0;return!1},U=Object.prototype.hasOwnProperty;var z=function(t,n){if(!n||!d(t))return{};for(var r,e={},u=f(n)?n:function(t){return t[n]},o=0;o<t.length;o++){var i=t[o];r=u(i),U.call(e,r)?e[r].push(i):e[r]=[i]}return e};function Y(t,n){if(!n)return{0:t};if(!f(n)){var r=d(n)?n:n.replace(/\s+/g,"").split("*");n=function(t){for(var n="_",e=0,u=r.length;e<u;e++)n+=t[r[e]]&&t[r[e]].toString();return n}}return z(t,n)}var X=function(t,n){if(!n)return[t];var r=Y(t,n),e=[];for(var u in r)e.push(r[u]);return e};var Q=function(t,n){return t["_wrap_"+n]};var Z=function(t,n){if(t["_wrap_"+n])return t["_wrap_"+n];var r=function(r){t[n](r)};return t["_wrap_"+n]=r,r},K={};var J=function(t){var n=K[t];if(!n){for(var r=t.toString(16),e=r.length;e<6;e++)r="0"+r;n="#"+r,K[t]=n}return n};var tt=function(t){var n=0,r=0,e=0,u=0;return d(t)?1===t.length?n=r=e=u=t[0]:2===t.length?(n=e=t[0],r=u=t[1]):3===t.length?(n=t[0],r=u=t[1],e=t[2]):(n=t[0],r=t[1],e=t[2],u=t[3]):n=r=e=u=t,{r1:n,r2:r,r3:e,r4:u}},nt=function(t,n,r){return t<n?n:t>r?r:t},rt=function(t,n){var r=n.toString(),e=r.indexOf(".");if(-1===e)return Math.round(t);var u=r.substr(e+1).length;return u>20&&(u=20),parseFloat(t.toFixed(u))},et=function(t){return c(t,"Number")},ut=function(t){return et(t)&&t%1!=0},ot=function(t){return et(t)&&t%2==0},it=Number.isInteger?Number.isInteger:function(t){return et(t)&&t%1==0},at=function(t){return et(t)&&t<0};function ct(t,n,r){return void 0===r&&(r=1e-5),Math.abs(t-n)<r}var ft=function(t){return et(t)&&t%2!=0},st=function(t){return et(t)&&t>0},dt=function(t,n){if(d(t)){for(var r,e=-1/0,u=0;u<t.length;u++){var o=t[u],i=f(n)?n(o):o[n];i>e&&(r=o,e=i)}return r}},lt=function(t,n){if(d(t)){for(var r,e=1/0,u=0;u<t.length;u++){var o=t[u],i=f(n)?n(o):o[n];i<e&&(r=o,e=i)}return r}},ht=function(t,n){return(t%n+n)%n},pt=180/Math.PI,vt=function(t){return pt*t},mt=parseInt,bt=Math.PI/180,yt=function(t){return bt*t},Mt=h,gt=function(t,n){return t.hasOwnProperty(n)},wt=gt,At=Object.values?function(t){return Object.values(t)}:function(t){var n=[];return h(t,(function(r,e){f(t)&&"prototype"===e||n.push(r)})),n},St=function(t,n){return u(At(t),n)},Et=function(t){return s(t)?"":t.toString()},_t=function(t){return Et(t).toLowerCase()},xt=function(t){var n=Et(t);return n.charAt(0).toLowerCase()+n.substring(1)};var Ot=function(t,n){return t&&n?t.replace(/\\?\{([^{}]+)\}/g,(function(t,r){return"\\"===t.charAt(0)?t.slice(1):void 0===n[r]?"":n[r]})):t},Pt=function(t){return Et(t).toUpperCase()},Rt=function(t){var n=Et(t);return n.charAt(0).toUpperCase()+n.substring(1)},jt={}.toString,Tt=function(t){return jt.call(t).replace(/^\[object /,"").replace(/]$/,"")},Ct=function(t){return c(t,"Arguments")},Gt=function(t){return c(t,"Boolean")},Lt=function(t){return c(t,"Date")},Vt=function(t){return c(t,"Error")},kt=function(t){return et(t)&&isFinite(t)},qt=function(t){return null===t},Dt=Object.prototype,Nt=function(t){var n=t&&t.constructor;return t===("function"==typeof n&&n.prototype||Dt)},It=function(t){return c(t,"RegExp")},Ft=function(t){return void 0===t},$t=function(t){return t instanceof Element||t instanceof HTMLDocument};function Bt(t){return(window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.msRequestAnimationFrame||function(t){return setTimeout(t,16)})(t)}function Wt(t){(window.cancelAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame||window.msCancelAnimationFrame||clearTimeout)(t)}function Ht(t,n){for(var r in n)n.hasOwnProperty(r)&&"constructor"!==r&&void 0!==n[r]&&(t[r]=n[r])}function Ut(t,n,r,e){return n&&Ht(t,n),r&&Ht(t,r),e&&Ht(t,e),t}var zt=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];for(var r=t[0],e=1;e<t.length;e++){var u=t[e];f(u)&&(u=u.prototype),Ut(r.prototype,u)}},Yt=function(t){if("object"!=typeof t||null===t)return t;var n;if(d(t)){n=[];for(var r=0,e=t.length;r<e;r++)"object"==typeof t[r]&&null!=t[r]?n[r]=Yt(t[r]):n[r]=t[r]}else for(var u in n={},t)"object"==typeof t[u]&&null!=t[u]?n[u]=Yt(t[u]):n[u]=t[u];return n},Xt=Yt;var Qt=function(t,n,r){var e;return function(){var u=this,o=arguments,i=function(){e=null,r||t.apply(u,o)},a=r&&!e;clearTimeout(e),e=setTimeout(i,n),a&&t.apply(u,o)}},Zt=function(t,n){if(!f(t))throw new TypeError("Expected a function");var r=function(){for(var e=[],u=0;u<arguments.length;u++)e[u]=arguments[u];var o=n?n.apply(this,e):e[0],i=r.cache;if(i.has(o))return i.get(o);var a=t.apply(this,e);return i.set(o,a),a};return r.cache=new Map,r};function Kt(t,n,r,e){for(var u in r=r||0,e=e||5,n)if(n.hasOwnProperty(u)){var o=n[u];null!==o&&b(o)?(b(t[u])||(t[u]={}),r<e?Kt(t[u],o,r+1,e):t[u]=n[u]):d(o)?(t[u]=[],t[u]=t[u].concat(o)):void 0!==o&&(t[u]=o)}}var Jt=function(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];for(var e=0;e<n.length;e+=1)Kt(t,n[e]);return t},tn=function(t,n,r,e){f(n)||(r=n,n=t,t=function(){});var u=Object.create?function(t,n){return Object.create(t,{constructor:{value:n}})}:function(t,n){function r(){}r.prototype=t;var e=new r;return e.constructor=n,e},o=u(n.prototype,t);return t.prototype=Ut(o,t.prototype),t.superclass=u(n.prototype,n),Ut(o,r),Ut(t,e),t},nn=function(t,n){if(!e(t))return-1;var r=Array.prototype.indexOf;if(r)return r.call(t,n);for(var u=-1,o=0;o<t.length;o++)if(t[o]===n){u=o;break}return u},rn=Object.prototype.hasOwnProperty;var en=function(t){if(s(t))return!0;if(e(t))return!t.length;var n=Tt(t);if("Map"===n||"Set"===n)return!t.size;if(Nt(t))return!Object.keys(t).length;for(var r in t)if(rn.call(t,r))return!1;return!0},un=function(t,n){if(t===n)return!0;if(!t||!n)return!1;if(V(t)||V(n))return!1;if(e(t)||e(n)){if(t.length!==n.length)return!1;for(var r=!0,u=0;u<t.length&&(r=un(t[u],n[u]));u++);return r}if(m(t)||m(n)){var o=Object.keys(t),i=Object.keys(n);if(o.length!==i.length)return!1;for(r=!0,u=0;u<o.length&&(r=un(t[o[u]],n[o[u]]));u++);return r}return!1},on=un,an=function(t,n,r){return f(r)?!!r(t,n):on(t,n)},cn=function(t,n){if(!e(t))return t;for(var r=[],u=0;u<t.length;u++){var o=t[u];r.push(n(o,u))}return r},fn=function(t){return t},sn=function(t,n){void 0===n&&(n=fn);var r={};return l(t)&&!s(t)&&Object.keys(t).forEach((function(e){r[e]=n(t[e],e)})),r},dn=function(t,n,r){for(var e=0,u=V(n)?n.split("."):n;t&&e<u.length;)t=t[u[e++]];return void 0===t||e<u.length?r:t},ln=function(t,n,r){var e=t,u=V(n)?n.split("."):n;return u.forEach((function(t,n){n<u.length-1?(l(e[t])||(e[t]=et(u[n+1])?[]:{}),e=e[t]):e[t]=r})),t},hn=Object.prototype.hasOwnProperty,pn=function(t,n){if(null===t||!b(t))return{};var r={};return h(n,(function(n){hn.call(t,n)&&(r[n]=t[n])})),r},vn=function(t,n){return G(t,(function(t,r,e){return n.includes(e)||(t[e]=r),t}),{})},mn=function(t,n,r){var e,u,o,i,a=0;r||(r={});var c=function(){a=!1===r.leading?0:Date.now(),e=null,i=t.apply(u,o),e||(u=o=null)},f=function(){var f=Date.now();a||!1!==r.leading||(a=f);var s=n-(f-a);return u=this,o=arguments,s<=0||s>n?(e&&(clearTimeout(e),e=null),a=f,i=t.apply(u,o),e||(u=o=null)):e||!1===r.trailing||(e=setTimeout(c,s)),i};return f.cancel=function(){clearTimeout(e),a=0,e=u=o=null},f},bn=function(t){return e(t)?Array.prototype.slice.call(t):[]},yn={},Mn=function(t){return yn[t=t||"g"]?yn[t]+=1:yn[t]=1,t+yn[t]},gn=function(){},wn=function(t){return t};function An(t){return s(t)?0:e(t)?t.length:Object.keys(t).length}var Sn,En=r(0),_n=Zt((function(t,n){void 0===n&&(n={});var r=n.fontSize,e=n.fontFamily,u=n.fontWeight,o=n.fontStyle,i=n.fontVariant;return Sn||(Sn=document.createElement("canvas").getContext("2d")),Sn.font=[o,i,u,r+"px",e].join(" "),Sn.measureText(V(t)?t:"").width}),(function(t,n){return void 0===n&&(n={}),Object(En.__spreadArrays)([t],At(n)).join("")})),xn=function(t,n,r,e){void 0===e&&(e="...");var u,o,i=_n(e,r),a=V(t)?t:Et(t),c=n,f=[];if(_n(t,r)<=n)return t;for(;u=a.substr(0,16),!((o=_n(u,r))+i>c&&o>c);)if(f.push(u),c-=o,!(a=a.substr(16)))return f.join("");for(;u=a.substr(0,1),!((o=_n(u,r))+i>c);)if(f.push(u),c-=o,!(a=a.substr(1)))return f.join("");return""+f.join("")+e},On=function(){function t(){this.map={}}return t.prototype.has=function(t){return void 0!==this.map[t]},t.prototype.get=function(t,n){var r=this.map[t];return void 0===r?n:r},t.prototype.set=function(t,n){this.map[t]=n},t.prototype.clear=function(){this.map={}},t.prototype.delete=function(t){delete this.map[t]},t.prototype.size=function(){return Object.keys(this.map).length},t}()},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var e={containerModule:!0,Plugin:!0,ElementSVG:!0};Object.defineProperty(n,"ElementSVG",{enumerable:!0,get:function(){return i.ElementSVG}}),n.containerModule=n.Plugin=void 0;var u=r(1),o=r(2),i=r(8),a=r(9),c=r(21),f=r(3);Object.keys(f).forEach((function(t){"default"!==t&&"__esModule"!==t&&(Object.prototype.hasOwnProperty.call(e,t)||t in n&&n[t]===f[t]||Object.defineProperty(n,t,{enumerable:!0,get:function(){return f[t]}}))})),o.world.registerComponent(i.ElementSVG);var s=(0,u.Module)((function(t){t(a.RectRenderer),t(a.ImageRenderer),t(a.LineRenderer),t(a.PolylineRenderer),t(a.TextRenderer),t(a.PathRenderer),t({token:a.ElementRendererFactory,useFactory:function(t){return function(n){return n===o.SHAPE.Rect?t.container.get(a.RectRenderer):n===o.SHAPE.Image?t.container.get(a.ImageRenderer):n===o.SHAPE.Line?t.container.get(a.LineRenderer):n===o.SHAPE.Polyline||n===o.SHAPE.Polygon?t.container.get(a.PolylineRenderer):n===o.SHAPE.Text?t.container.get(a.TextRenderer):n===o.SHAPE.Path?t.container.get(a.PathRenderer):null}}}),t(c.SVGRendererPlugin)}));n.containerModule=s;var d=function(){function t(){}return t.prototype.init=function(t){t.load(s,!0)},t.prototype.destroy=function(t){t.remove(a.RectRenderer),t.remove(a.ImageRenderer),t.remove(a.LineRenderer),t.remove(a.PolylineRenderer),t.remove(a.TextRenderer),t.remove(a.PathRenderer),t.remove(a.ElementRendererFactory),t.remove(c.SVGRendererPlugin)},t}();n.Plugin=d},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.Plugin=void 0;var e=r(1),u=r(11),o=(0,e.Module)((function(t){t(u.DOMInteractionPlugin)})),i=function(){function t(){}return t.prototype.init=function(t){t.load(o,!0)},t.prototype.destroy=function(t){t.remove(u.DOMInteractionPlugin)},t}();n.Plugin=i},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.Plugin=void 0;var e=r(1),u=r(25),o=(0,e.Module)((function(t){t(u.SVGPickerPlugin)})),i=function(){function t(){}return t.prototype.init=function(t){t.load(o,!0)},t.prototype.destroy=function(t){t.remove(u.SVGPickerPlugin)},t}();n.Plugin=i},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.ElementSVG=void 0;var e=r(0),u=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return(0,e.__extends)(n,t),n.tag="c-svg-element",n}(r(2).Component);n.ElementSVG=u},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.ElementRendererFactory=n.ElementRenderer=void 0,Object.defineProperty(n,"ImageRenderer",{enumerable:!0,get:function(){return u.ImageRenderer}}),Object.defineProperty(n,"LineRenderer",{enumerable:!0,get:function(){return o.LineRenderer}}),Object.defineProperty(n,"PathRenderer",{enumerable:!0,get:function(){return c.PathRenderer}}),Object.defineProperty(n,"PolylineRenderer",{enumerable:!0,get:function(){return i.PolylineRenderer}}),Object.defineProperty(n,"RectRenderer",{enumerable:!0,get:function(){return e.RectRenderer}}),Object.defineProperty(n,"TextRenderer",{enumerable:!0,get:function(){return a.TextRenderer}});var e=r(13),u=r(14),o=r(15),i=r(16),a=r(17),c=r(20);n.ElementRendererFactory="ElementRendererFactory";n.ElementRenderer="ElementRenderer"},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.numberToLongString=function(t){return t.toFixed(6).replace(".000000","")},n.parseRadius=function(t){var n=0,r=0,u=0,o=0;(0,e.isArray)(t)?1===t.length?n=r=u=o=t[0]:2===t.length?(n=u=t[0],r=o=t[1]):3===t.length?(n=t[0],r=o=t[1],u=t[2]):(n=t[0],r=t[1],u=t[2],o=t[3]):n=r=u=o=t;return{r1:n,r2:r,r3:u,r4:o}};var e=r(4)},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.DOMInteractionPlugin=void 0;var e=r(0),u=r(2),o=r(1),i=r(12),a=function(){function t(){}var n;return n=t,t.prototype.apply=function(t){var r=this,e=function(n){t.hooks.pointerMove.call(n)},u=function(n){t.hooks.pointerUp.call(n)},o=function(n){t.hooks.pointerDown.call(n)},a=function(n){t.hooks.pointerOver.call(n)},c=function(n){t.hooks.pointerOut.call(n)},f=function(n){t.hooks.pointerWheel.call(n)};t.hooks.init.tap(n.tag,(function(){var t=r.contextService.getDomElement();i.supportsPointerEvents?(self.document.addEventListener("pointermove",e,!0),t.addEventListener("pointerdown",o,!0),t.addEventListener("pointerleave",c,!0),t.addEventListener("pointerover",a,!0),self.addEventListener("pointerup",u,!0)):(self.document.addEventListener("mousemove",e,!0),t.addEventListener("mousedown",o,!0),t.addEventListener("mouseout",c,!0),t.addEventListener("mouseover",a,!0),self.addEventListener("mouseup",u,!0)),i.supportsTouchEvents&&(t.addEventListener("touchstart",o,!0),t.addEventListener("touchend",u,!0),t.addEventListener("touchmove",e,!0)),t.addEventListener("wheel",f,{passive:!0,capture:!0})})),t.hooks.destroy.tap(n.tag,(function(){var t=r.contextService.getDomElement();i.supportsPointerEvents?(self.document.removeEventListener("pointermove",e,!0),t.removeEventListener("pointerdown",o,!0),t.removeEventListener("pointerleave",c,!0),t.removeEventListener("pointerover",a,!0),self.removeEventListener("pointerup",u,!0)):(self.document.removeEventListener("mousemove",e,!0),t.removeEventListener("mousedown",o,!0),t.removeEventListener("mouseout",c,!0),t.removeEventListener("mouseover",a,!0),self.removeEventListener("mouseup",u,!0)),i.supportsTouchEvents&&(t.removeEventListener("touchstart",o,!0),t.removeEventListener("touchend",u,!0),t.removeEventListener("touchmove",e,!0)),t.removeEventListener("wheel",f,!0)}))},t.tag="DOMInteractionPlugin",(0,e.__decorate)([(0,o.inject)(u.ContextService),(0,e.__metadata)("design:type",Object)],t.prototype,"contextService",void 0),t=n=(0,e.__decorate)([(0,o.singleton)({contrib:u.RenderingPluginContribution})],t)}();n.DOMInteractionPlugin=a},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.isMouseEvent=function(t){return!self.MouseEvent||t instanceof MouseEvent&&(!u||!(t instanceof self.PointerEvent))},n.isTouchEvent=function(t){return e&&t instanceof TouchEvent},n.supportsTouchEvents=n.supportsPointerEvents=void 0;var e="ontouchstart"in self;n.supportsTouchEvents=e;var u=!!self.PointerEvent;n.supportsPointerEvents=u},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.RectRenderer=void 0;var e=r(0),u=r(4),o=r(1),i=r(10),a=function(){function t(){this.dependencies=["radius","width","height"]}return t.prototype.apply=function(t,n){var r=n.radius,e=void 0===r?0:r,o=n.width,a=void 0===o?0:o,c=n.height,f=void 0===c?0:c,s="";if(e){var d=(0,i.parseRadius)(e);(0,u.isArray)(e)?1===e.length?d.r1=d.r2=d.r3=d.r4=e[0]:2===e.length?(d.r1=d.r3=e[0],d.r2=d.r4=e[1]):3===e.length?(d.r1=e[0],d.r2=d.r4=e[1],d.r3=e[2]):(d.r1=e[0],d.r2=e[1],d.r3=e[2],d.r4=e[3]):d.r1=d.r2=d.r3=d.r4=e,s=[["M "+d.r1+",0"],["l "+(a-d.r1-d.r2)+",0"],["a "+d.r2+","+d.r2+",0,0,1,"+d.r2+","+d.r2],["l 0,"+(f-d.r2-d.r3)],["a "+d.r3+","+d.r3+",0,0,1,"+-d.r3+","+d.r3],["l "+(d.r3+d.r4-a)+",0"],["a "+d.r4+","+d.r4+",0,0,1,"+-d.r4+","+-d.r4],["l 0,"+(d.r4+d.r1-f)],["a "+d.r1+","+d.r1+",0,0,1,"+d.r1+","+-d.r1],["z"]].join(" ")}else s="M 0,0 l "+a+",0 l 0,"+f+" l"+-a+" 0 z";t.setAttribute("d",s)},t=(0,e.__decorate)([(0,o.singleton)()],t)}();n.RectRenderer=a},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.ImageRenderer=void 0;var e=r(0),u=r(4),o=r(1),i=function(){function t(){this.dependencies=["img","width","height"]}return t.prototype.apply=function(t,n){var r=n.img,e=void 0===r?"":r,o=n.width,i=void 0===o?0:o,a=n.height,c=void 0===a?0:a;if(t.setAttribute("x","0"),t.setAttribute("y","0"),(0,u.isString)(e))t.setAttribute("href",e);else if(e instanceof Image)i||t.setAttribute("width",""+e.width),c||t.setAttribute("height",""+e.height),t.setAttribute("href",e.src);else if(e instanceof HTMLElement&&(0,u.isString)(e.nodeName)&&"CANVAS"===e.nodeName.toUpperCase())t.setAttribute("href",e.toDataURL());else if(e instanceof ImageData){var f=document.createElement("canvas");f.setAttribute("width",""+e.width),f.setAttribute("height",""+e.height);var s=f.getContext("2d");s&&(s.putImageData(e,0,0),i||t.setAttribute("width",""+e.width),c||t.setAttribute("height",""+e.height),t.setAttribute("href",f.toDataURL()))}},t=(0,e.__decorate)([(0,o.singleton)()],t)}();n.ImageRenderer=i},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.LineRenderer=void 0;var e=r(0),u=r(2),o=r(1),i=function(){function t(){this.dependencies=["x1","y1","x2","y2"]}return t.prototype.apply=function(t,n){var r=n.x1,e=n.y1,o=n.x2,i=n.y2,a=n.defX,c=void 0===a?0:a,f=n.defY,s=void 0===f?0:f,d=n.stroke;t.setAttribute("x1",""+(r-c)),t.setAttribute("y1",""+(e-s)),t.setAttribute("x2",""+(o-c)),e===i&&d&&d.type!==u.PARSED_COLOR_TYPE.Constant?t.setAttribute("y2",""+(i-s+1e-5)):t.setAttribute("y2",""+(i-s))},t=(0,e.__decorate)([(0,o.singleton)()],t)}();n.LineRenderer=i},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.PolylineRenderer=void 0;var e=r(0),u=r(1),o=function(){function t(){this.dependencies=["points"]}return t.prototype.apply=function(t,n){var r=n.points,e=n.defX,u=void 0===e?0:e,o=n.defY,i=void 0===o?0:o;r&&r.points&&r.points.length>=2&&t.setAttribute("points",r.points.map((function(t){return t[0]-u+","+(t[1]-i)})).join(" "))},t=(0,e.__decorate)([(0,u.singleton)()],t)}();n.PolylineRenderer=o},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.TextRenderer=void 0;var e=r(0),u=r(18),o=r(1),i={top:"before-edge",middle:"central",bottom:"after-edge",alphabetic:"alphabetic",ideographic:"ideographic",hanging:"hanging"},a={top:"text-before-edge",middle:"central",bottom:"text-after-edge",alphabetic:"alphabetic",ideographic:"ideographic",hanging:"hanging"},c={left:"left",start:"left",center:"middle",right:"end",end:"end"},f=function(){function t(){this.dependencies=["text","font","fontSize","fontFamily","fontStyle","fontWeight","fontVariant","lineHeight","letterSpacing","padding","wordWrap","wordWrapWidth","leading","textBaseline","textAlign","whiteSpace"]}return t.prototype.apply=function(t,n){var r=n.textAlign,e=(n.text,n.textBaseline),o=(n.fontSize,n.lineCap),f=n.lineJoin,s=n.lineWidth,d=void 0===s?0:s,l=n.metrics,h=(0,u.detect)();h&&"firefox"===h.name?t.setAttribute("dominant-baseline",a[e]||"alphabetic"):(t.setAttribute("dominant-baseline",a[e]),t.setAttribute("alignment-baseline",i[e])),t.setAttribute("text-anchor",c[r]),t.setAttribute("paint-order","stroke"),t.setAttribute("style","stroke-linecap:"+o+"; stroke-linejoin:"+f+";");var p=l.lines,v=l.lineHeight,m=l.height,b=p.length;1===b?(t.innerHTML=p[0],t.setAttribute("dx",""+d/2)):t.innerHTML=p.map((function(t,n){var r=0;return 0===n?"middle"===e?r=v/2-m/2:"top"===e||"hanging"===e?r=0:"bottom"!==e&&"alphabetic"!==e&&"ideographic"!==e||(r=-v*(b-1)):r=v,'<tspan x="0" dx="'+d/2+'" dy="'+r+'">'+t+"</tspan>"})).join("")},t=(0,e.__decorate)([(0,o.singleton)()],t)}();n.TextRenderer=f},function(t,n,r){"use strict";r.r(n),function(t){r.d(n,"BrowserInfo",(function(){return u})),r.d(n,"NodeInfo",(function(){return o})),r.d(n,"SearchBotDeviceInfo",(function(){return i})),r.d(n,"BotInfo",(function(){return a})),r.d(n,"ReactNativeInfo",(function(){return c})),r.d(n,"detect",(function(){return l})),r.d(n,"browserName",(function(){return p})),r.d(n,"parseUserAgent",(function(){return v})),r.d(n,"detectOS",(function(){return m})),r.d(n,"getNodeVersion",(function(){return b}));var e=function(t,n,r){if(r||2===arguments.length)for(var e,u=0,o=n.length;u<o;u++)!e&&u in n||(e||(e=Array.prototype.slice.call(n,0,u)),e[u]=n[u]);return t.concat(e||Array.prototype.slice.call(n))},u=function(t,n,r){this.name=t,this.version=n,this.os=r,this.type="browser"},o=function(n){this.version=n,this.type="node",this.name="node",this.os=t.platform},i=function(t,n,r,e){this.name=t,this.version=n,this.os=r,this.bot=e,this.type="bot-device"},a=function(){this.type="bot",this.bot=!0,this.name="bot",this.version=null,this.os=null},c=function(){this.type="react-native",this.name="react-native",this.version=null,this.os=null},f=/(nuhk|curl|Googlebot|Yammybot|Openbot|Slurp|MSNBot|Ask\ Jeeves\/Teoma|ia_archiver)/,s=[["aol",/AOLShield\/([0-9\._]+)/],["edge",/Edge\/([0-9\._]+)/],["edge-ios",/EdgiOS\/([0-9\._]+)/],["yandexbrowser",/YaBrowser\/([0-9\._]+)/],["kakaotalk",/KAKAOTALK\s([0-9\.]+)/],["samsung",/SamsungBrowser\/([0-9\.]+)/],["silk",/\bSilk\/([0-9._-]+)\b/],["miui",/MiuiBrowser\/([0-9\.]+)$/],["beaker",/BeakerBrowser\/([0-9\.]+)/],["edge-chromium",/EdgA?\/([0-9\.]+)/],["chromium-webview",/(?!Chrom.*OPR)wv\).*Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["chrome",/(?!Chrom.*OPR)Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["phantomjs",/PhantomJS\/([0-9\.]+)(:?\s|$)/],["crios",/CriOS\/([0-9\.]+)(:?\s|$)/],["firefox",/Firefox\/([0-9\.]+)(?:\s|$)/],["fxios",/FxiOS\/([0-9\.]+)/],["opera-mini",/Opera Mini.*Version\/([0-9\.]+)/],["opera",/Opera\/([0-9\.]+)(?:\s|$)/],["opera",/OPR\/([0-9\.]+)(:?\s|$)/],["ie",/Trident\/7\.0.*rv\:([0-9\.]+).*\).*Gecko$/],["ie",/MSIE\s([0-9\.]+);.*Trident\/[4-7].0/],["ie",/MSIE\s(7\.0)/],["bb10",/BB10;\sTouch.*Version\/([0-9\.]+)/],["android",/Android\s([0-9\.]+)/],["ios",/Version\/([0-9\._]+).*Mobile.*Safari.*/],["safari",/Version\/([0-9\._]+).*Safari/],["facebook",/FB[AS]V\/([0-9\.]+)/],["instagram",/Instagram\s([0-9\.]+)/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Mobile/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Gecko\)$/],["curl",/^curl\/([0-9\.]+)$/],["searchbot",/alexa|bot|crawl(er|ing)|facebookexternalhit|feedburner|google web preview|nagios|postrank|pingdom|slurp|spider|yahoo!|yandex/]],d=[["iOS",/iP(hone|od|ad)/],["Android OS",/Android/],["BlackBerry OS",/BlackBerry|BB10/],["Windows Mobile",/IEMobile/],["Amazon OS",/Kindle/],["Windows 3.11",/Win16/],["Windows 95",/(Windows 95)|(Win95)|(Windows_95)/],["Windows 98",/(Windows 98)|(Win98)/],["Windows 2000",/(Windows NT 5.0)|(Windows 2000)/],["Windows XP",/(Windows NT 5.1)|(Windows XP)/],["Windows Server 2003",/(Windows NT 5.2)/],["Windows Vista",/(Windows NT 6.0)/],["Windows 7",/(Windows NT 6.1)/],["Windows 8",/(Windows NT 6.2)/],["Windows 8.1",/(Windows NT 6.3)/],["Windows 10",/(Windows NT 10.0)/],["Windows ME",/Windows ME/],["Open BSD",/OpenBSD/],["Sun OS",/SunOS/],["Chrome OS",/CrOS/],["Linux",/(Linux)|(X11)/],["Mac OS",/(Mac_PowerPC)|(Macintosh)/],["QNX",/QNX/],["BeOS",/BeOS/],["OS/2",/OS\/2/]];function l(t){return t?v(t):"undefined"==typeof document&&"undefined"!=typeof navigator&&"ReactNative"===navigator.product?new c:"undefined"!=typeof navigator?v(navigator.userAgent):b()}function h(t){return""!==t&&s.reduce((function(n,r){var e=r[0],u=r[1];if(n)return n;var o=u.exec(t);return!!o&&[e,o]}),!1)}function p(t){var n=h(t);return n?n[0]:null}function v(t){var n=h(t);if(!n)return null;var r=n[0],o=n[1];if("searchbot"===r)return new a;var c=o[1]&&o[1].split(".").join("_").split("_").slice(0,3);c?c.length<3&&(c=e(e([],c,!0),function(t){for(var n=[],r=0;r<t;r++)n.push("0");return n}(3-c.length),!0)):c=[];var s=c.join("."),d=m(t),l=f.exec(t);return l&&l[1]?new i(r,s,d,l[1]):new u(r,s,d)}function m(t){for(var n=0,r=d.length;n<r;n++){var e=d[n],u=e[0];if(e[1].exec(t))return u}return null}function b(){return void 0!==t&&t.version?new o(t.version.slice(1)):null}}.call(this,r(19))},function(t,n){var r,e,u=t.exports={};function o(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function a(t){if(r===setTimeout)return setTimeout(t,0);if((r===o||!r)&&setTimeout)return r=setTimeout,setTimeout(t,0);try{return r(t,0)}catch(n){try{return r.call(null,t,0)}catch(n){return r.call(this,t,0)}}}!function(){try{r="function"==typeof setTimeout?setTimeout:o}catch(t){r=o}try{e="function"==typeof clearTimeout?clearTimeout:i}catch(t){e=i}}();var c,f=[],s=!1,d=-1;function l(){s&&c&&(s=!1,c.length?f=c.concat(f):d=-1,f.length&&h())}function h(){if(!s){var t=a(l);s=!0;for(var n=f.length;n;){for(c=f,f=[];++d<n;)c&&c[d].run();d=-1,n=f.length}c=null,s=!1,function(t){if(e===clearTimeout)return clearTimeout(t);if((e===i||!e)&&clearTimeout)return e=clearTimeout,clearTimeout(t);try{e(t)}catch(n){try{return e.call(null,t)}catch(n){return e.call(this,t)}}}(t)}}function p(t,n){this.fun=t,this.array=n}function v(){}u.nextTick=function(t){var n=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)n[r-1]=arguments[r];f.push(new p(t,n)),1!==f.length||s||a(h)},p.prototype.run=function(){this.fun.apply(null,this.array)},u.title="browser",u.browser=!0,u.env={},u.argv=[],u.version="",u.versions={},u.on=v,u.addListener=v,u.once=v,u.off=v,u.removeListener=v,u.removeAllListeners=v,u.emit=v,u.prependListener=v,u.prependOnceListener=v,u.listeners=function(t){return[]},u.binding=function(t){throw new Error("process.binding is not supported")},u.cwd=function(){return"/"},u.chdir=function(t){throw new Error("process.chdir is not supported")},u.umask=function(){return 0}},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.PathRenderer=void 0;var e=r(0),u=r(1),o=function(){function t(){this.dependencies=["path"]}return t.prototype.apply=function(t,n){var r=n.path,e=n.defX,u=void 0===e?0:e,o=n.defY,i=void 0===o?0:o;t.setAttribute("d",this.formatPath(r.absolutePath,u,i))},t.prototype.formatPath=function(t,n,r){var e=t.map((function(t){switch(t[0]){case"M":return"M "+(t[1]-n)+","+(t[2]-r);case"L":return"L "+(t[1]-n)+","+(t[2]-r);case"Q":return"Q "+(t[1]-n)+" "+(t[2]-r)+","+(t[3]-n)+" "+(t[4]-r);case"C":return"C "+(t[1]-n)+" "+(t[2]-r)+","+(t[3]-n)+" "+(t[4]-r)+","+(t[5]-n)+" "+(t[6]-r);case"A":return"A "+t[1]+" "+t[2]+" "+t[3]+" "+t[4]+" "+t[5]+" "+(t[6]-n)+" "+(t[7]-r);case"Z":return"Z"}})).join(" ");return~e.indexOf("NaN")?"":e},t=(0,e.__decorate)([(0,u.singleton)()],t)}();n.PathRenderer=o},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.SVG_ATTR_MAP=n.SVGRendererPlugin=n.SHAPE_TO_TAGS=void 0;var e,u=r(0),o=r(1),i=r(26),a=r(2),c=r(8),f=r(3),s=r(10),d=r(9),l=r(22),h=r(23),p=r(24),v=((e={})[a.SHAPE.Rect]="path",e[a.SHAPE.Circle]="circle",e[a.SHAPE.Ellipse]="ellipse",e[a.SHAPE.Image]="image",e[a.SHAPE.Group]="g",e[a.SHAPE.Line]="line",e[a.SHAPE.Polyline]="polyline",e[a.SHAPE.Polygon]="polygon",e[a.SHAPE.Text]="text",e[a.SHAPE.Path]="path",e[a.SHAPE.HTML]="foreignObject",e);n.SHAPE_TO_TAGS=v;var m={opacity:"opacity",fillStyle:"fill",fill:"fill",fillOpacity:"fill-opacity",strokeStyle:"stroke",strokeOpacity:"stroke-opacity",stroke:"stroke",clipPath:"clip-path",r:"r",rx:"rx",ry:"ry",width:"width",height:"height",lineCap:"stroke-linecap",lineJoin:"stroke-linejoin",lineWidth:"stroke-width",lineDash:"stroke-dasharray",lineDashOffset:"stroke-dashoffset",miterLimit:"stroke-miterlimit",font:"font",fontSize:"font-size",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",fontFamily:"font-family",letterSpacing:"letter-spacing",startArrow:"marker-start",endArrow:"marker-end",class:"class",id:"id",style:"style",preserveAspectRatio:"preserveAspectRatio",visibility:"visibility",anchor:"anchor",shadowColor:"flood-color",shadowBlur:"stdDeviation",shadowOffsetX:"dx",shadowOffsetY:"dy",filter:"filter",innerHTML:"innerHTML"};n.SVG_ATTR_MAP=m;var b=function(){function t(){}var n;return n=t,t.prototype.apply=function(t){var r=this,e=function(t){var n=t.target;r.createSVGDom(n,r.$camera)},u=function(t){var n=t.target;r.removeSVGDom(n)},o=function(t){var n,e,u=t.target,o=t.detail,i=o.attributeName;o.newValue;if("zIndex"===i){var a=u.parentNode,f=null===(n=u.parentNode)||void 0===n?void 0:n.entity,s=null===(e=null==f?void 0:f.getComponent(c.ElementSVG))||void 0===e?void 0:e.$groupEl,d=((null==a?void 0:a.children)||[]).slice();s&&r.reorderChildren(s,d)}r.updateAttribute(u,i,u.parsedStyle[i])};t.hooks.init.tap(n.tag,(function(){r.$def=(0,f.createSVGElement)("defs");var t=r.contextService.getContext();t.appendChild(r.$def),t.setAttribute("color-interpolation-filters","sRGB"),r.$camera=(0,f.createSVGElement)("g"),r.$camera.id="g_svg_camera",r.applyTransform(r.$camera,r.camera.getOrthoMatrix()),t.appendChild(r.$camera),r.renderingContext.root.addEventListener(a.ElementEvent.MOUNTED,e),r.renderingContext.root.addEventListener(a.ElementEvent.UNMOUNTED,u),r.renderingContext.root.addEventListener(a.ElementEvent.ATTRIBUTE_CHANGED,o)})),t.hooks.destroy.tap(n.tag,(function(){r.renderingContext.root.removeEventListener(a.ElementEvent.MOUNTED,e),r.renderingContext.root.removeEventListener(a.ElementEvent.UNMOUNTED,u),r.renderingContext.root.removeEventListener(a.ElementEvent.ATTRIBUTE_CHANGED,o)})),t.hooks.render.tap(n.tag,(function(t){var n,e;r.renderingContext.renderReasons.has(a.RENDER_REASON.CameraChanged)&&r.applyTransform(r.$camera,r.camera.getOrthoMatrix());var u=t.entity,o=null===(n=u.getComponent(c.ElementSVG))||void 0===n?void 0:n.$el,i=null===(e=u.getComponent(c.ElementSVG))||void 0===e?void 0:e.$groupEl;o&&i&&(r.applyTransform(i,t.getLocalTransform()),r.reorderChildren(i,t.children||[]),u.getComponent(a.Renderable).dirty=!1)}))},t.prototype.reorderChildren=function(t,n){n.sort(this.sceneGraphService.sort);var r=document.createDocumentFragment();n.forEach((function(t){var n=t.entity.getComponent(c.ElementSVG).$groupEl;n&&r.appendChild(n)})),t.appendChild(r)},t.prototype.applyTransform=function(t,n){var r=i.mat4.getTranslation(i.vec3.create(),n),e=i.mat4.getScaling(i.vec3.create(),n),o=i.mat4.getRotation(i.quat.create(),n),c=(0,u.__read)(r,2),f=c[0],d=c[1],l=(0,u.__read)(e,2),h=l[0],p=l[1],v=(0,u.__read)((0,a.getEuler)(i.vec3.create(),o),3),m=v[0],b=(v[1],v[2]),y=(0,a.fromRotationTranslationScale)(m||b,f,d,h,p);t.setAttribute("transform","matrix("+(0,s.numberToLongString)(y[0])+","+(0,s.numberToLongString)(y[1])+","+(0,s.numberToLongString)(y[3])+","+(0,s.numberToLongString)(y[4])+","+(0,s.numberToLongString)(y[6])+","+(0,s.numberToLongString)(y[7])+")")},t.prototype.applyAttributes=function(t){var n,r,e=t.entity,u=null===(n=e.getComponent(c.ElementSVG))||void 0===n?void 0:n.$el,o=null===(r=e.getComponent(c.ElementSVG))||void 0===r?void 0:r.$groupEl;if(u&&o){var i=t.nodeName,f=t.attributes,s=t.parsedStyle;for(var d in u.setAttribute("fill","none"),i===a.SHAPE.Image&&u.setAttribute("preserveAspectRatio","none"),f)this.updateAttribute(t,d,s[d],!0);var l=this.elementRendererFactory(i);l&&l.apply(u,s)}},t.prototype.updateAttribute=function(t,n,r,e){var u,o,i;void 0===e&&(e=!1);var s=t.entity,d=null===(u=s.getComponent(c.ElementSVG))||void 0===u?void 0:u.$el,v=null===(o=s.getComponent(c.ElementSVG))||void 0===o?void 0:o.$groupEl,b=t.parsedStyle;if(m[n])if("fill"===n||"stroke"===n)(0,h.createOrUpdateGradientAndPattern)(this.$def,t,d,b[n],m[n]);else if("visibility"===n)null==v||v.setAttribute(m[n],""+r);else if("clipPath"===n){var y=r;if(y){var M="clip-path-"+y.entity.getName();if(!this.$def.querySelector("#"+M)){var g=(0,f.createSVGElement)("clipPath");g.id=M,this.$def.appendChild(g),this.createSVGDom(y,g,!0),y.entity.getComponent(c.ElementSVG).$groupEl=g}var w=null===(i=y.entity.getComponent(c.ElementSVG))||void 0===i?void 0:i.$groupEl;w&&this.applyTransform(w,y.getLocalTransform()),this.applyAttributes(y),null==d||d.setAttribute("clip-path","url(#"+M+")")}else null==d||d.removeAttribute("clip-path")}else if("shadowColor"===n||"shadowBlur"===n||"shadowOffsetX"===n||"shadowOffsetY"===n)(0,p.createOrUpdateShadow)(this.$def,t,d,n);else if("filter"===n)(0,l.createOrUpdateFilter)(this.$def,t,d,b[n]);else if("innerHTML"===n){var A=document.createElement("div");"string"==typeof r?A.innerHTML=r:A.appendChild(r),d.innerHTML="",d.appendChild(A)}else t.nodeName!==a.SHAPE.Text&&["anchor","width","height","r","rx","ry"].indexOf(n)>-1&&this.updateAnchorWithTransform(t),"anchor"!==n&&(null==d||d.setAttribute(m[n],""+r));if(!e&&d){var S=this.elementRendererFactory(t.nodeName);S&&S.dependencies.indexOf(n)>-1&&S.apply(d,t.parsedStyle)}},t.prototype.createSVGDom=function(t,n,r){var e;void 0===r&&(r=!1);var u=t.entity,o=u.addComponent(c.ElementSVG),i=v[t.nodeName]||"g";if(i){var s=void 0,d=(0,f.createSVGElement)(i);t.nodeName===a.SHAPE.HTML&&(t.parsedStyle.$el=d),d.id="g_svg_"+t.nodeName+"_"+u.getName(),"g"===i||r?s=d:(s=(0,f.createSVGElement)("g")).appendChild(d),o.$el=d,o.$groupEl=s;var l=t.parentNode&&(null===(e=t.parentNode.entity.getComponent(c.ElementSVG))||void 0===e?void 0:e.$groupEl)||n;l&&l.appendChild(s),this.applyAttributes(t)}},t.prototype.removeSVGDom=function(t){var n,r=null===(n=t.entity.getComponent(c.ElementSVG))||void 0===n?void 0:n.$groupEl;r&&r.parentNode&&(r.parentNode.removeChild(r),t.entity.removeComponent(c.ElementSVG,!0))},t.prototype.updateAnchorWithTransform=function(t){var n,r=t.getGeometryBounds(),e=r&&2*r.halfExtents[0]||0,u=r&&2*r.halfExtents[1]||0,o=(t.parsedStyle||{}).anchor,i=void 0===o?[0,0]:o,f=null===(n=t.entity.getComponent(c.ElementSVG))||void 0===n?void 0:n.$el;null==f||f.setAttribute("transform","translate(-"+i[0]*e+",-"+i[1]*u+")"),t.nodeName!==a.SHAPE.Circle&&t.nodeName!==a.SHAPE.Ellipse||(null==f||f.setAttribute("cx",""+e/2),null==f||f.setAttribute("cy",""+u/2))},t.tag="SVGRendererPlugin",(0,u.__decorate)([(0,o.inject)(a.DefaultCamera),(0,u.__metadata)("design:type",a.Camera)],t.prototype,"camera",void 0),(0,u.__decorate)([(0,o.inject)(a.ContextService),(0,u.__metadata)("design:type",Object)],t.prototype,"contextService",void 0),(0,u.__decorate)([(0,o.inject)(a.RenderingContext),(0,u.__metadata)("design:type",Object)],t.prototype,"renderingContext",void 0),(0,u.__decorate)([(0,o.inject)(a.SceneGraphService),(0,u.__metadata)("design:type",Object)],t.prototype,"sceneGraphService",void 0),(0,u.__decorate)([(0,o.inject)(d.ElementRendererFactory),(0,u.__metadata)("design:type",Function)],t.prototype,"elementRendererFactory",void 0),t=n=(0,u.__decorate)([(0,o.singleton)({contrib:a.RenderingPluginContribution})],t)}();n.SVGRendererPlugin=b},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.createOrUpdateFilter=function(t,n,r,c){var f="g-filter-"+n.entity.getName(),s=t.querySelectorAll("[name="+f+"]");s.length&&s.forEach((function(n){t.removeChild(n)}));if(0===c.length)null==r||r.removeAttribute("filter");else{var d=c.map((function(n,r){var c=n.name,s=n.params,d=(0,e.createSVGElement)("filter");return"blur"===c?function(t,n){var r=(0,e.createSVGElement)("feGaussianBlur");r.setAttribute("in","SourceGraphic"),r.setAttribute("stdDeviation",""+n[0].value),t.appendChild(r)}(d,s):"brightness"===c?function(t,n){var r=o(n[0]);i(t,{type:"linear",slope:r,intercept:0})}(d,s):"drop-shadow"===c?function(t,n){var r=n[0].value,u=n[1].value,o=n[2].value,i=n[3].formatted,a=(0,e.createSVGElement)("feGaussianBlur");a.setAttribute("in","SourceAlpha"),a.setAttribute("stdDeviation",""+o),t.appendChild(a);var c=(0,e.createSVGElement)("feOffset");c.setAttribute("dx",""+r),c.setAttribute("dy",""+u),c.setAttribute("result","offsetblur"),t.appendChild(c);var f=(0,e.createSVGElement)("feFlood");f.setAttribute("flood-color",i),t.appendChild(f);var s=(0,e.createSVGElement)("feComposite");s.setAttribute("in2","offsetblur"),s.setAttribute("operator","in"),t.appendChild(s);var d=(0,e.createSVGElement)("feMerge");t.appendChild(d);var l=(0,e.createSVGElement)("feMergeNode"),h=(0,e.createSVGElement)("feMergeNode");h.setAttribute("in","SourceGraphic"),d.appendChild(l),d.appendChild(h)}(d,s):"contrast"===c?function(t,n){var r=o(n[0]);i(t,{type:"linear",slope:r,intercept:-.5*r+.5})}(d,s):"grayscale"===c?function(t,n){var r=o(n[0]);a(t,[.2126+.7874*(1-r),.7152-.7152*(1-r),.0722-.0722*(1-r),0,0,.2126-.2126*(1-r),.7152+.2848*(1-r),.0722-.0722*(1-r),0,0,.2126-.2126*(1-r),.7152-.7152*(1-r),.0722+.9278*(1-r),0,0,0,0,0,1,0])}(d,s):"sepia"===c?function(t,n){var r=o(n[0]);a(t,[.393+.607*(1-r),.769-.769*(1-r),.189-.189*(1-r),0,0,.349-.349*(1-r),.686+.314*(1-r),.168-.168*(1-r),0,0,.272-.272*(1-r),.534-.534*(1-r),.131+.869*(1-r),0,0,0,0,0,1,0])}(d,s):"saturate"===c?function(t,n){var r=o(n[0]),u=(0,e.createSVGElement)("feColorMatrix");u.setAttribute("type","saturate"),u.setAttribute("values",""+r),t.appendChild(u)}(d,s):"hue-rotate"===c?function(t,n){var r=(0,e.createSVGElement)("feColorMatrix");r.setAttribute("type","hueRotate"),r.setAttribute("values",""+(0,u.convertAngleUnit)(n[0])),t.appendChild(r)}(d,s):"invert"===c&&function(t,n){var r=o(n[0]);i(t,{type:"table",tableValues:r+" "+(1-r)})}(d,s),d.id=f+"-"+r,d.setAttribute("name",f),t.appendChild(d),d.id}));null==r||r.setAttribute("filter",d.map((function(t){return"url(#"+t+")"})).join(" "))}};var e=r(3),u=r(2);function o(t){return"%"===t.unit?t.value/100:t.value}function i(t,n){var r=n.type,u=n.slope,o=n.intercept,i=n.tableValues,a=(0,e.createSVGElement)("feComponentTransfer");[(0,e.createSVGElement)("feFuncR"),(0,e.createSVGElement)("feFuncG"),(0,e.createSVGElement)("feFuncB")].forEach((function(t){t.setAttribute("type",r),"table"===r?t.setAttribute("tableValues",""+i):(t.setAttribute("slope",""+u),t.setAttribute("intercept",""+o)),a.appendChild(t)})),t.appendChild(a)}function a(t,n){var r=(0,e.createSVGElement)("feColorMatrix");r.setAttribute("type","matrix"),r.setAttribute("values",n.join(" ")),t.appendChild(r)}},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.createOrUpdateGradientAndPattern=function(t,n,r,c,f){var s=function(t){var n="",r=t.type;if(r===u.PARSED_COLOR_TYPE.Pattern){var e=t.value.src;n=e}else if(r===u.PARSED_COLOR_TYPE.LinearGradient||r===u.PARSED_COLOR_TYPE.RadialGradient){var o=t.value,c=o.x0,f=o.y0,s=o.x1,d=o.y1,l=o.r1,h=o.steps;n=""+r+c+f+s+d+(l||0)+h.map((function(t){return t.join("")})).join("")}n&&(i[n]||(i[n]="_pattern_"+r+"_"+a++));return i[n]}(c),d=t.querySelector("#"+s);c.type===u.PARSED_COLOR_TYPE.LinearGradient||c.type===u.PARSED_COLOR_TYPE.RadialGradient?(d||function(t,n,r){var i=(0,o.createSVGElement)(n.type===u.PARSED_COLOR_TYPE.LinearGradient?"linearGradient":"radialGradient");if(n.type===u.PARSED_COLOR_TYPE.LinearGradient){var a=n.value,c=a.x0,f=a.y0,s=a.x1,d=a.y1;i.setAttribute("x1",""+c),i.setAttribute("y1",""+f),i.setAttribute("x2",""+s),i.setAttribute("y2",""+d)}else{var l=n.value,h=(c=l.x0,f=l.y0,l.r1);i.setAttribute("cx",""+c),i.setAttribute("cy",""+f),i.setAttribute("r",""+h/2)}var p="";n.value.steps.forEach((function(t){var n=(0,e.__read)(t,2),r=n[0],u=n[1];p+='<stop offset="'+r+'" stop-color="'+u+'"></stop>'})),i.innerHTML=p,i.id=r,t.appendChild(i)}(t,c,s),null==r||r.setAttribute(f,"url(#"+s+")")):c.type===u.PARSED_COLOR_TYPE.Pattern?(d||function(t,n,r){var e=n.value.src,u=(0,o.createSVGElement)("pattern");u.setAttribute("patternUnits","userSpaceOnUse");var i=(0,o.createSVGElement)("image");u.appendChild(i),u.id=r,t.appendChild(u),i.setAttribute("href",e);var a=new window.Image;e.match(/^data:/i)||(a.crossOrigin="Anonymous");function c(){u.setAttribute("width",""+a.width),u.setAttribute("height",""+a.height)}a.src=e,a.complete?c():(a.onload=c,a.src=a.src)}(t,c,s),null==r||r.setAttribute(f,"url(#"+s+")")):null==r||r.setAttribute(f,""+c.formatted)};var e=r(0),u=r(2),o=r(3),i={},a=0},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.createOrUpdateShadow=function(t,n,r,u){var o="filter-dropshadow-"+n.entity.getName(),i=t.querySelector("#"+o);if(!i){i=(0,e.createSVGElement)("filter");var a=(0,e.createSVGElement)("feDropShadow");a.setAttribute("dx","0"),a.setAttribute("dy","0"),i.appendChild(a),i.id=o,t.appendChild(i)}var c=i.children[0];if("shadowColor"===u){var f=n.parsedStyle[u];c.setAttribute("flood-color",f.formatted)}else"shadowBlur"===u?c.setAttribute("stdDeviation",""+Number(n.parsedStyle[u])/2):"shadowOffsetX"===u?c.setAttribute("dx",n.parsedStyle[u]):"shadowOffsetY"===u&&c.setAttribute("dy",n.parsedStyle[u]);null==r||r.setAttribute("filter","url(#"+o+")")};var e=r(3)},function(t,n,r){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.SVGPickerPlugin=void 0;var e=r(0),u=r(1),o=r(2),i=function(){function t(){}var n;return n=t,t.prototype.apply=function(t){var r=this;t.hooks.pick.tap(n.tag,(function(t){var n=t.position,e=n.clientX,u=n.clientY;try{var o=document.elementFromPoint(e,u),i=null,a=o&&o.getAttribute("id");if(a){var c=a.lastIndexOf("_");(i=r.displayObjectPool.getByName(a.substring(c+1))).interactive||(i=null)}t.picked=i}catch(n){t.picked=null}return t}))},t.tag="SVGPickerPlugin",(0,e.__decorate)([(0,u.inject)(o.SceneGraphService),(0,e.__metadata)("design:type",Object)],t.prototype,"sceneGraphService",void 0),(0,e.__decorate)([(0,u.inject)(o.DisplayObjectPool),(0,e.__metadata)("design:type",o.DisplayObjectPool)],t.prototype,"displayObjectPool",void 0),t=n=(0,e.__decorate)([(0,u.singleton)({contrib:o.RenderingPluginContribution})],t)}();n.SVGPickerPlugin=i},function(t,n,r){"use strict";r.r(n),r.d(n,"glMatrix",(function(){return e})),r.d(n,"mat2",(function(){return u})),r.d(n,"mat2d",(function(){return o})),r.d(n,"mat3",(function(){return i})),r.d(n,"mat4",(function(){return a})),r.d(n,"quat",(function(){return s})),r.d(n,"quat2",(function(){return d})),r.d(n,"vec2",(function(){return l})),r.d(n,"vec3",(function(){return c})),r.d(n,"vec4",(function(){return f}));var e={};r.r(e),r.d(e,"EPSILON",(function(){return h})),r.d(e,"ARRAY_TYPE",(function(){return p})),r.d(e,"RANDOM",(function(){return v})),r.d(e,"setMatrixArrayType",(function(){return m})),r.d(e,"toRadian",(function(){return y})),r.d(e,"equals",(function(){return M}));var u={};r.r(u),r.d(u,"create",(function(){return g})),r.d(u,"clone",(function(){return w})),r.d(u,"copy",(function(){return A})),r.d(u,"identity",(function(){return S})),r.d(u,"fromValues",(function(){return E})),r.d(u,"set",(function(){return _})),r.d(u,"transpose",(function(){return x})),r.d(u,"invert",(function(){return O})),r.d(u,"adjoint",(function(){return P})),r.d(u,"determinant",(function(){return R})),r.d(u,"multiply",(function(){return j})),r.d(u,"rotate",(function(){return T})),r.d(u,"scale",(function(){return C})),r.d(u,"fromRotation",(function(){return G})),r.d(u,"fromScaling",(function(){return L})),r.d(u,"str",(function(){return V})),r.d(u,"frob",(function(){return k})),r.d(u,"LDU",(function(){return q})),r.d(u,"add",(function(){return D})),r.d(u,"subtract",(function(){return N})),r.d(u,"exactEquals",(function(){return I})),r.d(u,"equals",(function(){return F})),r.d(u,"multiplyScalar",(function(){return $})),r.d(u,"multiplyScalarAndAdd",(function(){return B})),r.d(u,"mul",(function(){return W})),r.d(u,"sub",(function(){return H}));var o={};r.r(o),r.d(o,"create",(function(){return U})),r.d(o,"clone",(function(){return z})),r.d(o,"copy",(function(){return Y})),r.d(o,"identity",(function(){return X})),r.d(o,"fromValues",(function(){return Q})),r.d(o,"set",(function(){return Z})),r.d(o,"invert",(function(){return K})),r.d(o,"determinant",(function(){return J})),r.d(o,"multiply",(function(){return tt})),r.d(o,"rotate",(function(){return nt})),r.d(o,"scale",(function(){return rt})),r.d(o,"translate",(function(){return et})),r.d(o,"fromRotation",(function(){return ut})),r.d(o,"fromScaling",(function(){return ot})),r.d(o,"fromTranslation",(function(){return it})),r.d(o,"str",(function(){return at})),r.d(o,"frob",(function(){return ct})),r.d(o,"add",(function(){return ft})),r.d(o,"subtract",(function(){return st})),r.d(o,"multiplyScalar",(function(){return dt})),r.d(o,"multiplyScalarAndAdd",(function(){return lt})),r.d(o,"exactEquals",(function(){return ht})),r.d(o,"equals",(function(){return pt})),r.d(o,"mul",(function(){return vt})),r.d(o,"sub",(function(){return mt}));var i={};r.r(i),r.d(i,"create",(function(){return bt})),r.d(i,"fromMat4",(function(){return yt})),r.d(i,"clone",(function(){return Mt})),r.d(i,"copy",(function(){return gt})),r.d(i,"fromValues",(function(){return wt})),r.d(i,"set",(function(){return At})),r.d(i,"identity",(function(){return St})),r.d(i,"transpose",(function(){return Et})),r.d(i,"invert",(function(){return _t})),r.d(i,"adjoint",(function(){return xt})),r.d(i,"determinant",(function(){return Ot})),r.d(i,"multiply",(function(){return Pt})),r.d(i,"translate",(function(){return Rt})),r.d(i,"rotate",(function(){return jt})),r.d(i,"scale",(function(){return Tt})),r.d(i,"fromTranslation",(function(){return Ct})),r.d(i,"fromRotation",(function(){return Gt})),r.d(i,"fromScaling",(function(){return Lt})),r.d(i,"fromMat2d",(function(){return Vt})),r.d(i,"fromQuat",(function(){return kt})),r.d(i,"normalFromMat4",(function(){return qt})),r.d(i,"projection",(function(){return Dt})),r.d(i,"str",(function(){return Nt})),r.d(i,"frob",(function(){return It})),r.d(i,"add",(function(){return Ft})),r.d(i,"subtract",(function(){return $t})),r.d(i,"multiplyScalar",(function(){return Bt})),r.d(i,"multiplyScalarAndAdd",(function(){return Wt})),r.d(i,"exactEquals",(function(){return Ht})),r.d(i,"equals",(function(){return Ut})),r.d(i,"mul",(function(){return zt})),r.d(i,"sub",(function(){return Yt}));var a={};r.r(a),r.d(a,"create",(function(){return Xt})),r.d(a,"clone",(function(){return Qt})),r.d(a,"copy",(function(){return Zt})),r.d(a,"fromValues",(function(){return Kt})),r.d(a,"set",(function(){return Jt})),r.d(a,"identity",(function(){return tn})),r.d(a,"transpose",(function(){return nn})),r.d(a,"invert",(function(){return rn})),r.d(a,"adjoint",(function(){return en})),r.d(a,"determinant",(function(){return un})),r.d(a,"multiply",(function(){return on})),r.d(a,"translate",(function(){return an})),r.d(a,"scale",(function(){return cn})),r.d(a,"rotate",(function(){return fn})),r.d(a,"rotateX",(function(){return sn})),r.d(a,"rotateY",(function(){return dn})),r.d(a,"rotateZ",(function(){return ln})),r.d(a,"fromTranslation",(function(){return hn})),r.d(a,"fromScaling",(function(){return pn})),r.d(a,"fromRotation",(function(){return vn})),r.d(a,"fromXRotation",(function(){return mn})),r.d(a,"fromYRotation",(function(){return bn})),r.d(a,"fromZRotation",(function(){return yn})),r.d(a,"fromRotationTranslation",(function(){return Mn})),r.d(a,"fromQuat2",(function(){return gn})),r.d(a,"getTranslation",(function(){return wn})),r.d(a,"getScaling",(function(){return An})),r.d(a,"getRotation",(function(){return Sn})),r.d(a,"fromRotationTranslationScale",(function(){return En})),r.d(a,"fromRotationTranslationScaleOrigin",(function(){return _n})),r.d(a,"fromQuat",(function(){return xn})),r.d(a,"frustum",(function(){return On})),r.d(a,"perspectiveNO",(function(){return Pn})),r.d(a,"perspective",(function(){return Rn})),r.d(a,"perspectiveZO",(function(){return jn})),r.d(a,"perspectiveFromFieldOfView",(function(){return Tn})),r.d(a,"orthoNO",(function(){return Cn})),r.d(a,"ortho",(function(){return Gn})),r.d(a,"orthoZO",(function(){return Ln})),r.d(a,"lookAt",(function(){return Vn})),r.d(a,"targetTo",(function(){return kn})),r.d(a,"str",(function(){return qn})),r.d(a,"frob",(function(){return Dn})),r.d(a,"add",(function(){return Nn})),r.d(a,"subtract",(function(){return In})),r.d(a,"multiplyScalar",(function(){return Fn})),r.d(a,"multiplyScalarAndAdd",(function(){return $n})),r.d(a,"exactEquals",(function(){return Bn})),r.d(a,"equals",(function(){return Wn})),r.d(a,"mul",(function(){return Hn})),r.d(a,"sub",(function(){return Un}));var c={};r.r(c),r.d(c,"create",(function(){return zn})),r.d(c,"clone",(function(){return Yn})),r.d(c,"length",(function(){return Xn})),r.d(c,"fromValues",(function(){return Qn})),r.d(c,"copy",(function(){return Zn})),r.d(c,"set",(function(){return Kn})),r.d(c,"add",(function(){return Jn})),r.d(c,"subtract",(function(){return tr})),r.d(c,"multiply",(function(){return nr})),r.d(c,"divide",(function(){return rr})),r.d(c,"ceil",(function(){return er})),r.d(c,"floor",(function(){return ur})),r.d(c,"min",(function(){return or})),r.d(c,"max",(function(){return ir})),r.d(c,"round",(function(){return ar})),r.d(c,"scale",(function(){return cr})),r.d(c,"scaleAndAdd",(function(){return fr})),r.d(c,"distance",(function(){return sr})),r.d(c,"squaredDistance",(function(){return dr})),r.d(c,"squaredLength",(function(){return lr})),r.d(c,"negate",(function(){return hr})),r.d(c,"inverse",(function(){return pr})),r.d(c,"normalize",(function(){return vr})),r.d(c,"dot",(function(){return mr})),r.d(c,"cross",(function(){return br})),r.d(c,"lerp",(function(){return yr})),r.d(c,"hermite",(function(){return Mr})),r.d(c,"bezier",(function(){return gr})),r.d(c,"random",(function(){return wr})),r.d(c,"transformMat4",(function(){return Ar})),r.d(c,"transformMat3",(function(){return Sr})),r.d(c,"transformQuat",(function(){return Er})),r.d(c,"rotateX",(function(){return _r})),r.d(c,"rotateY",(function(){return xr})),r.d(c,"rotateZ",(function(){return Or})),r.d(c,"angle",(function(){return Pr})),r.d(c,"zero",(function(){return Rr})),r.d(c,"str",(function(){return jr})),r.d(c,"exactEquals",(function(){return Tr})),r.d(c,"equals",(function(){return Cr})),r.d(c,"sub",(function(){return Lr})),r.d(c,"mul",(function(){return Vr})),r.d(c,"div",(function(){return kr})),r.d(c,"dist",(function(){return qr})),r.d(c,"sqrDist",(function(){return Dr})),r.d(c,"len",(function(){return Nr})),r.d(c,"sqrLen",(function(){return Ir})),r.d(c,"forEach",(function(){return Fr}));var f={};r.r(f),r.d(f,"create",(function(){return $r})),r.d(f,"clone",(function(){return Br})),r.d(f,"fromValues",(function(){return Wr})),r.d(f,"copy",(function(){return Hr})),r.d(f,"set",(function(){return Ur})),r.d(f,"add",(function(){return zr})),r.d(f,"subtract",(function(){return Yr})),r.d(f,"multiply",(function(){return Xr})),r.d(f,"divide",(function(){return Qr})),r.d(f,"ceil",(function(){return Zr})),r.d(f,"floor",(function(){return Kr})),r.d(f,"min",(function(){return Jr})),r.d(f,"max",(function(){return te})),r.d(f,"round",(function(){return ne})),r.d(f,"scale",(function(){return re})),r.d(f,"scaleAndAdd",(function(){return ee})),r.d(f,"distance",(function(){return ue})),r.d(f,"squaredDistance",(function(){return oe})),r.d(f,"length",(function(){return ie})),r.d(f,"squaredLength",(function(){return ae})),r.d(f,"negate",(function(){return ce})),r.d(f,"inverse",(function(){return fe})),r.d(f,"normalize",(function(){return se})),r.d(f,"dot",(function(){return de})),r.d(f,"cross",(function(){return le})),r.d(f,"lerp",(function(){return he})),r.d(f,"random",(function(){return pe})),r.d(f,"transformMat4",(function(){return ve})),r.d(f,"transformQuat",(function(){return me})),r.d(f,"zero",(function(){return be})),r.d(f,"str",(function(){return ye})),r.d(f,"exactEquals",(function(){return Me})),r.d(f,"equals",(function(){return ge})),r.d(f,"sub",(function(){return we})),r.d(f,"mul",(function(){return Ae})),r.d(f,"div",(function(){return Se})),r.d(f,"dist",(function(){return Ee})),r.d(f,"sqrDist",(function(){return _e})),r.d(f,"len",(function(){return xe})),r.d(f,"sqrLen",(function(){return Oe})),r.d(f,"forEach",(function(){return Pe}));var s={};r.r(s),r.d(s,"create",(function(){return Re})),r.d(s,"identity",(function(){return je})),r.d(s,"setAxisAngle",(function(){return Te})),r.d(s,"getAxisAngle",(function(){return Ce})),r.d(s,"getAngle",(function(){return Ge})),r.d(s,"multiply",(function(){return Le})),r.d(s,"rotateX",(function(){return Ve})),r.d(s,"rotateY",(function(){return ke})),r.d(s,"rotateZ",(function(){return qe})),r.d(s,"calculateW",(function(){return De})),r.d(s,"exp",(function(){return Ne})),r.d(s,"ln",(function(){return Ie})),r.d(s,"pow",(function(){return Fe})),r.d(s,"slerp",(function(){return $e})),r.d(s,"random",(function(){return Be})),r.d(s,"invert",(function(){return We})),r.d(s,"conjugate",(function(){return He})),r.d(s,"fromMat3",(function(){return Ue})),r.d(s,"fromEuler",(function(){return ze})),r.d(s,"str",(function(){return Ye})),r.d(s,"clone",(function(){return nu})),r.d(s,"fromValues",(function(){return ru})),r.d(s,"copy",(function(){return eu})),r.d(s,"set",(function(){return uu})),r.d(s,"add",(function(){return ou})),r.d(s,"mul",(function(){return iu})),r.d(s,"scale",(function(){return au})),r.d(s,"dot",(function(){return cu})),r.d(s,"lerp",(function(){return fu})),r.d(s,"length",(function(){return su})),r.d(s,"len",(function(){return du})),r.d(s,"squaredLength",(function(){return lu})),r.d(s,"sqrLen",(function(){return hu})),r.d(s,"normalize",(function(){return pu})),r.d(s,"exactEquals",(function(){return vu})),r.d(s,"equals",(function(){return mu})),r.d(s,"rotationTo",(function(){return bu})),r.d(s,"sqlerp",(function(){return yu})),r.d(s,"setAxes",(function(){return Mu}));var d={};r.r(d),r.d(d,"create",(function(){return gu})),r.d(d,"clone",(function(){return wu})),r.d(d,"fromValues",(function(){return Au})),r.d(d,"fromRotationTranslationValues",(function(){return Su})),r.d(d,"fromRotationTranslation",(function(){return Eu})),r.d(d,"fromTranslation",(function(){return _u})),r.d(d,"fromRotation",(function(){return xu})),r.d(d,"fromMat4",(function(){return Ou})),r.d(d,"copy",(function(){return Pu})),r.d(d,"identity",(function(){return Ru})),r.d(d,"set",(function(){return ju})),r.d(d,"getReal",(function(){return Tu})),r.d(d,"getDual",(function(){return Cu})),r.d(d,"setReal",(function(){return Gu})),r.d(d,"setDual",(function(){return Lu})),r.d(d,"getTranslation",(function(){return Vu})),r.d(d,"translate",(function(){return ku})),r.d(d,"rotateX",(function(){return qu})),r.d(d,"rotateY",(function(){return Du})),r.d(d,"rotateZ",(function(){return Nu})),r.d(d,"rotateByQuatAppend",(function(){return Iu})),r.d(d,"rotateByQuatPrepend",(function(){return Fu})),r.d(d,"rotateAroundAxis",(function(){return $u})),r.d(d,"add",(function(){return Bu})),r.d(d,"multiply",(function(){return Wu})),r.d(d,"mul",(function(){return Hu})),r.d(d,"scale",(function(){return Uu})),r.d(d,"dot",(function(){return zu})),r.d(d,"lerp",(function(){return Yu})),r.d(d,"invert",(function(){return Xu})),r.d(d,"conjugate",(function(){return Qu})),r.d(d,"length",(function(){return Zu})),r.d(d,"len",(function(){return Ku})),r.d(d,"squaredLength",(function(){return Ju})),r.d(d,"sqrLen",(function(){return to})),r.d(d,"normalize",(function(){return no})),r.d(d,"str",(function(){return ro})),r.d(d,"exactEquals",(function(){return eo})),r.d(d,"equals",(function(){return uo}));var l={};r.r(l),r.d(l,"create",(function(){return oo})),r.d(l,"clone",(function(){return io})),r.d(l,"fromValues",(function(){return ao})),r.d(l,"copy",(function(){return co})),r.d(l,"set",(function(){return fo})),r.d(l,"add",(function(){return so})),r.d(l,"subtract",(function(){return lo})),r.d(l,"multiply",(function(){return ho})),r.d(l,"divide",(function(){return po})),r.d(l,"ceil",(function(){return vo})),r.d(l,"floor",(function(){return mo})),r.d(l,"min",(function(){return bo})),r.d(l,"max",(function(){return yo})),r.d(l,"round",(function(){return Mo})),r.d(l,"scale",(function(){return go})),r.d(l,"scaleAndAdd",(function(){return wo})),r.d(l,"distance",(function(){return Ao})),r.d(l,"squaredDistance",(function(){return So})),r.d(l,"length",(function(){return Eo})),r.d(l,"squaredLength",(function(){return _o})),r.d(l,"negate",(function(){return xo})),r.d(l,"inverse",(function(){return Oo})),r.d(l,"normalize",(function(){return Po})),r.d(l,"dot",(function(){return Ro})),r.d(l,"cross",(function(){return jo})),r.d(l,"lerp",(function(){return To})),r.d(l,"random",(function(){return Co})),r.d(l,"transformMat2",(function(){return Go})),r.d(l,"transformMat2d",(function(){return Lo})),r.d(l,"transformMat3",(function(){return Vo})),r.d(l,"transformMat4",(function(){return ko})),r.d(l,"rotate",(function(){return qo})),r.d(l,"angle",(function(){return Do})),r.d(l,"zero",(function(){return No})),r.d(l,"str",(function(){return Io})),r.d(l,"exactEquals",(function(){return Fo})),r.d(l,"equals",(function(){return $o})),r.d(l,"len",(function(){return Bo})),r.d(l,"sub",(function(){return Wo})),r.d(l,"mul",(function(){return Ho})),r.d(l,"div",(function(){return Uo})),r.d(l,"dist",(function(){return zo})),r.d(l,"sqrDist",(function(){return Yo})),r.d(l,"sqrLen",(function(){return Xo})),r.d(l,"forEach",(function(){return Qo}));var h=1e-6,p="undefined"!=typeof Float32Array?Float32Array:Array,v=Math.random;function m(t){p=t}var b=Math.PI/180;function y(t){return t*b}function M(t,n){return Math.abs(t-n)<=h*Math.max(1,Math.abs(t),Math.abs(n))}function g(){var t=new p(4);return p!=Float32Array&&(t[1]=0,t[2]=0),t[0]=1,t[3]=1,t}function w(t){var n=new p(4);return n[0]=t[0],n[1]=t[1],n[2]=t[2],n[3]=t[3],n}function A(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t}function S(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t}function E(t,n,r,e){var u=new p(4);return u[0]=t,u[1]=n,u[2]=r,u[3]=e,u}function _(t,n,r,e,u){return t[0]=n,t[1]=r,t[2]=e,t[3]=u,t}function x(t,n){if(t===n){var r=n[1];t[1]=n[2],t[2]=r}else t[0]=n[0],t[1]=n[2],t[2]=n[1],t[3]=n[3];return t}function O(t,n){var r=n[0],e=n[1],u=n[2],o=n[3],i=r*o-u*e;return i?(i=1/i,t[0]=o*i,t[1]=-e*i,t[2]=-u*i,t[3]=r*i,t):null}function P(t,n){var r=n[0];return t[0]=n[3],t[1]=-n[1],t[2]=-n[2],t[3]=r,t}function R(t){return t[0]*t[3]-t[2]*t[1]}function j(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=r[0],c=r[1],f=r[2],s=r[3];return t[0]=e*a+o*c,t[1]=u*a+i*c,t[2]=e*f+o*s,t[3]=u*f+i*s,t}function T(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=Math.sin(r),c=Math.cos(r);return t[0]=e*c+o*a,t[1]=u*c+i*a,t[2]=e*-a+o*c,t[3]=u*-a+i*c,t}function C(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=r[0],c=r[1];return t[0]=e*a,t[1]=u*a,t[2]=o*c,t[3]=i*c,t}function G(t,n){var r=Math.sin(n),e=Math.cos(n);return t[0]=e,t[1]=r,t[2]=-r,t[3]=e,t}function L(t,n){return t[0]=n[0],t[1]=0,t[2]=0,t[3]=n[1],t}function V(t){return"mat2("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+")"}function k(t){return Math.hypot(t[0],t[1],t[2],t[3])}function q(t,n,r,e){return t[2]=e[2]/e[0],r[0]=e[0],r[1]=e[1],r[3]=e[3]-t[2]*r[1],[t,n,r]}function D(t,n,r){return t[0]=n[0]+r[0],t[1]=n[1]+r[1],t[2]=n[2]+r[2],t[3]=n[3]+r[3],t}function N(t,n,r){return t[0]=n[0]-r[0],t[1]=n[1]-r[1],t[2]=n[2]-r[2],t[3]=n[3]-r[3],t}function I(t,n){return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]&&t[3]===n[3]}function F(t,n){var r=t[0],e=t[1],u=t[2],o=t[3],i=n[0],a=n[1],c=n[2],f=n[3];return Math.abs(r-i)<=h*Math.max(1,Math.abs(r),Math.abs(i))&&Math.abs(e-a)<=h*Math.max(1,Math.abs(e),Math.abs(a))&&Math.abs(u-c)<=h*Math.max(1,Math.abs(u),Math.abs(c))&&Math.abs(o-f)<=h*Math.max(1,Math.abs(o),Math.abs(f))}function $(t,n,r){return t[0]=n[0]*r,t[1]=n[1]*r,t[2]=n[2]*r,t[3]=n[3]*r,t}function B(t,n,r,e){return t[0]=n[0]+r[0]*e,t[1]=n[1]+r[1]*e,t[2]=n[2]+r[2]*e,t[3]=n[3]+r[3]*e,t}Math.hypot||(Math.hypot=function(){for(var t=0,n=arguments.length;n--;)t+=arguments[n]*arguments[n];return Math.sqrt(t)});var W=j,H=N;function U(){var t=new p(6);return p!=Float32Array&&(t[1]=0,t[2]=0,t[4]=0,t[5]=0),t[0]=1,t[3]=1,t}function z(t){var n=new p(6);return n[0]=t[0],n[1]=t[1],n[2]=t[2],n[3]=t[3],n[4]=t[4],n[5]=t[5],n}function Y(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[4]=n[4],t[5]=n[5],t}function X(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t[4]=0,t[5]=0,t}function Q(t,n,r,e,u,o){var i=new p(6);return i[0]=t,i[1]=n,i[2]=r,i[3]=e,i[4]=u,i[5]=o,i}function Z(t,n,r,e,u,o,i){return t[0]=n,t[1]=r,t[2]=e,t[3]=u,t[4]=o,t[5]=i,t}function K(t,n){var r=n[0],e=n[1],u=n[2],o=n[3],i=n[4],a=n[5],c=r*o-e*u;return c?(c=1/c,t[0]=o*c,t[1]=-e*c,t[2]=-u*c,t[3]=r*c,t[4]=(u*a-o*i)*c,t[5]=(e*i-r*a)*c,t):null}function J(t){return t[0]*t[3]-t[1]*t[2]}function tt(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=n[4],c=n[5],f=r[0],s=r[1],d=r[2],l=r[3],h=r[4],p=r[5];return t[0]=e*f+o*s,t[1]=u*f+i*s,t[2]=e*d+o*l,t[3]=u*d+i*l,t[4]=e*h+o*p+a,t[5]=u*h+i*p+c,t}function nt(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=n[4],c=n[5],f=Math.sin(r),s=Math.cos(r);return t[0]=e*s+o*f,t[1]=u*s+i*f,t[2]=e*-f+o*s,t[3]=u*-f+i*s,t[4]=a,t[5]=c,t}function rt(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=n[4],c=n[5],f=r[0],s=r[1];return t[0]=e*f,t[1]=u*f,t[2]=o*s,t[3]=i*s,t[4]=a,t[5]=c,t}function et(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=n[4],c=n[5],f=r[0],s=r[1];return t[0]=e,t[1]=u,t[2]=o,t[3]=i,t[4]=e*f+o*s+a,t[5]=u*f+i*s+c,t}function ut(t,n){var r=Math.sin(n),e=Math.cos(n);return t[0]=e,t[1]=r,t[2]=-r,t[3]=e,t[4]=0,t[5]=0,t}function ot(t,n){return t[0]=n[0],t[1]=0,t[2]=0,t[3]=n[1],t[4]=0,t[5]=0,t}function it(t,n){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t[4]=n[0],t[5]=n[1],t}function at(t){return"mat2d("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+")"}function ct(t){return Math.hypot(t[0],t[1],t[2],t[3],t[4],t[5],1)}function ft(t,n,r){return t[0]=n[0]+r[0],t[1]=n[1]+r[1],t[2]=n[2]+r[2],t[3]=n[3]+r[3],t[4]=n[4]+r[4],t[5]=n[5]+r[5],t}function st(t,n,r){return t[0]=n[0]-r[0],t[1]=n[1]-r[1],t[2]=n[2]-r[2],t[3]=n[3]-r[3],t[4]=n[4]-r[4],t[5]=n[5]-r[5],t}function dt(t,n,r){return t[0]=n[0]*r,t[1]=n[1]*r,t[2]=n[2]*r,t[3]=n[3]*r,t[4]=n[4]*r,t[5]=n[5]*r,t}function lt(t,n,r,e){return t[0]=n[0]+r[0]*e,t[1]=n[1]+r[1]*e,t[2]=n[2]+r[2]*e,t[3]=n[3]+r[3]*e,t[4]=n[4]+r[4]*e,t[5]=n[5]+r[5]*e,t}function ht(t,n){return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]&&t[3]===n[3]&&t[4]===n[4]&&t[5]===n[5]}function pt(t,n){var r=t[0],e=t[1],u=t[2],o=t[3],i=t[4],a=t[5],c=n[0],f=n[1],s=n[2],d=n[3],l=n[4],p=n[5];return Math.abs(r-c)<=h*Math.max(1,Math.abs(r),Math.abs(c))&&Math.abs(e-f)<=h*Math.max(1,Math.abs(e),Math.abs(f))&&Math.abs(u-s)<=h*Math.max(1,Math.abs(u),Math.abs(s))&&Math.abs(o-d)<=h*Math.max(1,Math.abs(o),Math.abs(d))&&Math.abs(i-l)<=h*Math.max(1,Math.abs(i),Math.abs(l))&&Math.abs(a-p)<=h*Math.max(1,Math.abs(a),Math.abs(p))}var vt=tt,mt=st;function bt(){var t=new p(9);return p!=Float32Array&&(t[1]=0,t[2]=0,t[3]=0,t[5]=0,t[6]=0,t[7]=0),t[0]=1,t[4]=1,t[8]=1,t}function yt(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[4],t[4]=n[5],t[5]=n[6],t[6]=n[8],t[7]=n[9],t[8]=n[10],t}function Mt(t){var n=new p(9);return n[0]=t[0],n[1]=t[1],n[2]=t[2],n[3]=t[3],n[4]=t[4],n[5]=t[5],n[6]=t[6],n[7]=t[7],n[8]=t[8],n}function gt(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[4]=n[4],t[5]=n[5],t[6]=n[6],t[7]=n[7],t[8]=n[8],t}function wt(t,n,r,e,u,o,i,a,c){var f=new p(9);return f[0]=t,f[1]=n,f[2]=r,f[3]=e,f[4]=u,f[5]=o,f[6]=i,f[7]=a,f[8]=c,f}function At(t,n,r,e,u,o,i,a,c,f){return t[0]=n,t[1]=r,t[2]=e,t[3]=u,t[4]=o,t[5]=i,t[6]=a,t[7]=c,t[8]=f,t}function St(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t}function Et(t,n){if(t===n){var r=n[1],e=n[2],u=n[5];t[1]=n[3],t[2]=n[6],t[3]=r,t[5]=n[7],t[6]=e,t[7]=u}else t[0]=n[0],t[1]=n[3],t[2]=n[6],t[3]=n[1],t[4]=n[4],t[5]=n[7],t[6]=n[2],t[7]=n[5],t[8]=n[8];return t}function _t(t,n){var r=n[0],e=n[1],u=n[2],o=n[3],i=n[4],a=n[5],c=n[6],f=n[7],s=n[8],d=s*i-a*f,l=-s*o+a*c,h=f*o-i*c,p=r*d+e*l+u*h;return p?(p=1/p,t[0]=d*p,t[1]=(-s*e+u*f)*p,t[2]=(a*e-u*i)*p,t[3]=l*p,t[4]=(s*r-u*c)*p,t[5]=(-a*r+u*o)*p,t[6]=h*p,t[7]=(-f*r+e*c)*p,t[8]=(i*r-e*o)*p,t):null}function xt(t,n){var r=n[0],e=n[1],u=n[2],o=n[3],i=n[4],a=n[5],c=n[6],f=n[7],s=n[8];return t[0]=i*s-a*f,t[1]=u*f-e*s,t[2]=e*a-u*i,t[3]=a*c-o*s,t[4]=r*s-u*c,t[5]=u*o-r*a,t[6]=o*f-i*c,t[7]=e*c-r*f,t[8]=r*i-e*o,t}function Ot(t){var n=t[0],r=t[1],e=t[2],u=t[3],o=t[4],i=t[5],a=t[6],c=t[7],f=t[8];return n*(f*o-i*c)+r*(-f*u+i*a)+e*(c*u-o*a)}function Pt(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=n[4],c=n[5],f=n[6],s=n[7],d=n[8],l=r[0],h=r[1],p=r[2],v=r[3],m=r[4],b=r[5],y=r[6],M=r[7],g=r[8];return t[0]=l*e+h*i+p*f,t[1]=l*u+h*a+p*s,t[2]=l*o+h*c+p*d,t[3]=v*e+m*i+b*f,t[4]=v*u+m*a+b*s,t[5]=v*o+m*c+b*d,t[6]=y*e+M*i+g*f,t[7]=y*u+M*a+g*s,t[8]=y*o+M*c+g*d,t}function Rt(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=n[4],c=n[5],f=n[6],s=n[7],d=n[8],l=r[0],h=r[1];return t[0]=e,t[1]=u,t[2]=o,t[3]=i,t[4]=a,t[5]=c,t[6]=l*e+h*i+f,t[7]=l*u+h*a+s,t[8]=l*o+h*c+d,t}function jt(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=n[4],c=n[5],f=n[6],s=n[7],d=n[8],l=Math.sin(r),h=Math.cos(r);return t[0]=h*e+l*i,t[1]=h*u+l*a,t[2]=h*o+l*c,t[3]=h*i-l*e,t[4]=h*a-l*u,t[5]=h*c-l*o,t[6]=f,t[7]=s,t[8]=d,t}function Tt(t,n,r){var e=r[0],u=r[1];return t[0]=e*n[0],t[1]=e*n[1],t[2]=e*n[2],t[3]=u*n[3],t[4]=u*n[4],t[5]=u*n[5],t[6]=n[6],t[7]=n[7],t[8]=n[8],t}function Ct(t,n){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=n[0],t[7]=n[1],t[8]=1,t}function Gt(t,n){var r=Math.sin(n),e=Math.cos(n);return t[0]=e,t[1]=r,t[2]=0,t[3]=-r,t[4]=e,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t}function Lt(t,n){return t[0]=n[0],t[1]=0,t[2]=0,t[3]=0,t[4]=n[1],t[5]=0,t[6]=0,t[7]=0,t[8]=1,t}function Vt(t,n){return t[0]=n[0],t[1]=n[1],t[2]=0,t[3]=n[2],t[4]=n[3],t[5]=0,t[6]=n[4],t[7]=n[5],t[8]=1,t}function kt(t,n){var r=n[0],e=n[1],u=n[2],o=n[3],i=r+r,a=e+e,c=u+u,f=r*i,s=e*i,d=e*a,l=u*i,h=u*a,p=u*c,v=o*i,m=o*a,b=o*c;return t[0]=1-d-p,t[3]=s-b,t[6]=l+m,t[1]=s+b,t[4]=1-f-p,t[7]=h-v,t[2]=l-m,t[5]=h+v,t[8]=1-f-d,t}function qt(t,n){var r=n[0],e=n[1],u=n[2],o=n[3],i=n[4],a=n[5],c=n[6],f=n[7],s=n[8],d=n[9],l=n[10],h=n[11],p=n[12],v=n[13],m=n[14],b=n[15],y=r*a-e*i,M=r*c-u*i,g=r*f-o*i,w=e*c-u*a,A=e*f-o*a,S=u*f-o*c,E=s*v-d*p,_=s*m-l*p,x=s*b-h*p,O=d*m-l*v,P=d*b-h*v,R=l*b-h*m,j=y*R-M*P+g*O+w*x-A*_+S*E;return j?(j=1/j,t[0]=(a*R-c*P+f*O)*j,t[1]=(c*x-i*R-f*_)*j,t[2]=(i*P-a*x+f*E)*j,t[3]=(u*P-e*R-o*O)*j,t[4]=(r*R-u*x+o*_)*j,t[5]=(e*x-r*P-o*E)*j,t[6]=(v*S-m*A+b*w)*j,t[7]=(m*g-p*S-b*M)*j,t[8]=(p*A-v*g+b*y)*j,t):null}function Dt(t,n,r){return t[0]=2/n,t[1]=0,t[2]=0,t[3]=0,t[4]=-2/r,t[5]=0,t[6]=-1,t[7]=1,t[8]=1,t}function Nt(t){return"mat3("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+", "+t[6]+", "+t[7]+", "+t[8]+")"}function It(t){return Math.hypot(t[0],t[1],t[2],t[3],t[4],t[5],t[6],t[7],t[8])}function Ft(t,n,r){return t[0]=n[0]+r[0],t[1]=n[1]+r[1],t[2]=n[2]+r[2],t[3]=n[3]+r[3],t[4]=n[4]+r[4],t[5]=n[5]+r[5],t[6]=n[6]+r[6],t[7]=n[7]+r[7],t[8]=n[8]+r[8],t}function $t(t,n,r){return t[0]=n[0]-r[0],t[1]=n[1]-r[1],t[2]=n[2]-r[2],t[3]=n[3]-r[3],t[4]=n[4]-r[4],t[5]=n[5]-r[5],t[6]=n[6]-r[6],t[7]=n[7]-r[7],t[8]=n[8]-r[8],t}function Bt(t,n,r){return t[0]=n[0]*r,t[1]=n[1]*r,t[2]=n[2]*r,t[3]=n[3]*r,t[4]=n[4]*r,t[5]=n[5]*r,t[6]=n[6]*r,t[7]=n[7]*r,t[8]=n[8]*r,t}function Wt(t,n,r,e){return t[0]=n[0]+r[0]*e,t[1]=n[1]+r[1]*e,t[2]=n[2]+r[2]*e,t[3]=n[3]+r[3]*e,t[4]=n[4]+r[4]*e,t[5]=n[5]+r[5]*e,t[6]=n[6]+r[6]*e,t[7]=n[7]+r[7]*e,t[8]=n[8]+r[8]*e,t}function Ht(t,n){return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]&&t[3]===n[3]&&t[4]===n[4]&&t[5]===n[5]&&t[6]===n[6]&&t[7]===n[7]&&t[8]===n[8]}function Ut(t,n){var r=t[0],e=t[1],u=t[2],o=t[3],i=t[4],a=t[5],c=t[6],f=t[7],s=t[8],d=n[0],l=n[1],p=n[2],v=n[3],m=n[4],b=n[5],y=n[6],M=n[7],g=n[8];return Math.abs(r-d)<=h*Math.max(1,Math.abs(r),Math.abs(d))&&Math.abs(e-l)<=h*Math.max(1,Math.abs(e),Math.abs(l))&&Math.abs(u-p)<=h*Math.max(1,Math.abs(u),Math.abs(p))&&Math.abs(o-v)<=h*Math.max(1,Math.abs(o),Math.abs(v))&&Math.abs(i-m)<=h*Math.max(1,Math.abs(i),Math.abs(m))&&Math.abs(a-b)<=h*Math.max(1,Math.abs(a),Math.abs(b))&&Math.abs(c-y)<=h*Math.max(1,Math.abs(c),Math.abs(y))&&Math.abs(f-M)<=h*Math.max(1,Math.abs(f),Math.abs(M))&&Math.abs(s-g)<=h*Math.max(1,Math.abs(s),Math.abs(g))}var zt=Pt,Yt=$t;function Xt(){var t=new p(16);return p!=Float32Array&&(t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[11]=0,t[12]=0,t[13]=0,t[14]=0),t[0]=1,t[5]=1,t[10]=1,t[15]=1,t}function Qt(t){var n=new p(16);return n[0]=t[0],n[1]=t[1],n[2]=t[2],n[3]=t[3],n[4]=t[4],n[5]=t[5],n[6]=t[6],n[7]=t[7],n[8]=t[8],n[9]=t[9],n[10]=t[10],n[11]=t[11],n[12]=t[12],n[13]=t[13],n[14]=t[14],n[15]=t[15],n}function Zt(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[4]=n[4],t[5]=n[5],t[6]=n[6],t[7]=n[7],t[8]=n[8],t[9]=n[9],t[10]=n[10],t[11]=n[11],t[12]=n[12],t[13]=n[13],t[14]=n[14],t[15]=n[15],t}function Kt(t,n,r,e,u,o,i,a,c,f,s,d,l,h,v,m){var b=new p(16);return b[0]=t,b[1]=n,b[2]=r,b[3]=e,b[4]=u,b[5]=o,b[6]=i,b[7]=a,b[8]=c,b[9]=f,b[10]=s,b[11]=d,b[12]=l,b[13]=h,b[14]=v,b[15]=m,b}function Jt(t,n,r,e,u,o,i,a,c,f,s,d,l,h,p,v,m){return t[0]=n,t[1]=r,t[2]=e,t[3]=u,t[4]=o,t[5]=i,t[6]=a,t[7]=c,t[8]=f,t[9]=s,t[10]=d,t[11]=l,t[12]=h,t[13]=p,t[14]=v,t[15]=m,t}function tn(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function nn(t,n){if(t===n){var r=n[1],e=n[2],u=n[3],o=n[6],i=n[7],a=n[11];t[1]=n[4],t[2]=n[8],t[3]=n[12],t[4]=r,t[6]=n[9],t[7]=n[13],t[8]=e,t[9]=o,t[11]=n[14],t[12]=u,t[13]=i,t[14]=a}else t[0]=n[0],t[1]=n[4],t[2]=n[8],t[3]=n[12],t[4]=n[1],t[5]=n[5],t[6]=n[9],t[7]=n[13],t[8]=n[2],t[9]=n[6],t[10]=n[10],t[11]=n[14],t[12]=n[3],t[13]=n[7],t[14]=n[11],t[15]=n[15];return t}function rn(t,n){var r=n[0],e=n[1],u=n[2],o=n[3],i=n[4],a=n[5],c=n[6],f=n[7],s=n[8],d=n[9],l=n[10],h=n[11],p=n[12],v=n[13],m=n[14],b=n[15],y=r*a-e*i,M=r*c-u*i,g=r*f-o*i,w=e*c-u*a,A=e*f-o*a,S=u*f-o*c,E=s*v-d*p,_=s*m-l*p,x=s*b-h*p,O=d*m-l*v,P=d*b-h*v,R=l*b-h*m,j=y*R-M*P+g*O+w*x-A*_+S*E;return j?(j=1/j,t[0]=(a*R-c*P+f*O)*j,t[1]=(u*P-e*R-o*O)*j,t[2]=(v*S-m*A+b*w)*j,t[3]=(l*A-d*S-h*w)*j,t[4]=(c*x-i*R-f*_)*j,t[5]=(r*R-u*x+o*_)*j,t[6]=(m*g-p*S-b*M)*j,t[7]=(s*S-l*g+h*M)*j,t[8]=(i*P-a*x+f*E)*j,t[9]=(e*x-r*P-o*E)*j,t[10]=(p*A-v*g+b*y)*j,t[11]=(d*g-s*A-h*y)*j,t[12]=(a*_-i*O-c*E)*j,t[13]=(r*O-e*_+u*E)*j,t[14]=(v*M-p*w-m*y)*j,t[15]=(s*w-d*M+l*y)*j,t):null}function en(t,n){var r=n[0],e=n[1],u=n[2],o=n[3],i=n[4],a=n[5],c=n[6],f=n[7],s=n[8],d=n[9],l=n[10],h=n[11],p=n[12],v=n[13],m=n[14],b=n[15];return t[0]=a*(l*b-h*m)-d*(c*b-f*m)+v*(c*h-f*l),t[1]=-(e*(l*b-h*m)-d*(u*b-o*m)+v*(u*h-o*l)),t[2]=e*(c*b-f*m)-a*(u*b-o*m)+v*(u*f-o*c),t[3]=-(e*(c*h-f*l)-a*(u*h-o*l)+d*(u*f-o*c)),t[4]=-(i*(l*b-h*m)-s*(c*b-f*m)+p*(c*h-f*l)),t[5]=r*(l*b-h*m)-s*(u*b-o*m)+p*(u*h-o*l),t[6]=-(r*(c*b-f*m)-i*(u*b-o*m)+p*(u*f-o*c)),t[7]=r*(c*h-f*l)-i*(u*h-o*l)+s*(u*f-o*c),t[8]=i*(d*b-h*v)-s*(a*b-f*v)+p*(a*h-f*d),t[9]=-(r*(d*b-h*v)-s*(e*b-o*v)+p*(e*h-o*d)),t[10]=r*(a*b-f*v)-i*(e*b-o*v)+p*(e*f-o*a),t[11]=-(r*(a*h-f*d)-i*(e*h-o*d)+s*(e*f-o*a)),t[12]=-(i*(d*m-l*v)-s*(a*m-c*v)+p*(a*l-c*d)),t[13]=r*(d*m-l*v)-s*(e*m-u*v)+p*(e*l-u*d),t[14]=-(r*(a*m-c*v)-i*(e*m-u*v)+p*(e*c-u*a)),t[15]=r*(a*l-c*d)-i*(e*l-u*d)+s*(e*c-u*a),t}function un(t){var n=t[0],r=t[1],e=t[2],u=t[3],o=t[4],i=t[5],a=t[6],c=t[7],f=t[8],s=t[9],d=t[10],l=t[11],h=t[12],p=t[13],v=t[14],m=t[15];return(n*i-r*o)*(d*m-l*v)-(n*a-e*o)*(s*m-l*p)+(n*c-u*o)*(s*v-d*p)+(r*a-e*i)*(f*m-l*h)-(r*c-u*i)*(f*v-d*h)+(e*c-u*a)*(f*p-s*h)}function on(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=n[4],c=n[5],f=n[6],s=n[7],d=n[8],l=n[9],h=n[10],p=n[11],v=n[12],m=n[13],b=n[14],y=n[15],M=r[0],g=r[1],w=r[2],A=r[3];return t[0]=M*e+g*a+w*d+A*v,t[1]=M*u+g*c+w*l+A*m,t[2]=M*o+g*f+w*h+A*b,t[3]=M*i+g*s+w*p+A*y,M=r[4],g=r[5],w=r[6],A=r[7],t[4]=M*e+g*a+w*d+A*v,t[5]=M*u+g*c+w*l+A*m,t[6]=M*o+g*f+w*h+A*b,t[7]=M*i+g*s+w*p+A*y,M=r[8],g=r[9],w=r[10],A=r[11],t[8]=M*e+g*a+w*d+A*v,t[9]=M*u+g*c+w*l+A*m,t[10]=M*o+g*f+w*h+A*b,t[11]=M*i+g*s+w*p+A*y,M=r[12],g=r[13],w=r[14],A=r[15],t[12]=M*e+g*a+w*d+A*v,t[13]=M*u+g*c+w*l+A*m,t[14]=M*o+g*f+w*h+A*b,t[15]=M*i+g*s+w*p+A*y,t}function an(t,n,r){var e,u,o,i,a,c,f,s,d,l,h,p,v=r[0],m=r[1],b=r[2];return n===t?(t[12]=n[0]*v+n[4]*m+n[8]*b+n[12],t[13]=n[1]*v+n[5]*m+n[9]*b+n[13],t[14]=n[2]*v+n[6]*m+n[10]*b+n[14],t[15]=n[3]*v+n[7]*m+n[11]*b+n[15]):(e=n[0],u=n[1],o=n[2],i=n[3],a=n[4],c=n[5],f=n[6],s=n[7],d=n[8],l=n[9],h=n[10],p=n[11],t[0]=e,t[1]=u,t[2]=o,t[3]=i,t[4]=a,t[5]=c,t[6]=f,t[7]=s,t[8]=d,t[9]=l,t[10]=h,t[11]=p,t[12]=e*v+a*m+d*b+n[12],t[13]=u*v+c*m+l*b+n[13],t[14]=o*v+f*m+h*b+n[14],t[15]=i*v+s*m+p*b+n[15]),t}function cn(t,n,r){var e=r[0],u=r[1],o=r[2];return t[0]=n[0]*e,t[1]=n[1]*e,t[2]=n[2]*e,t[3]=n[3]*e,t[4]=n[4]*u,t[5]=n[5]*u,t[6]=n[6]*u,t[7]=n[7]*u,t[8]=n[8]*o,t[9]=n[9]*o,t[10]=n[10]*o,t[11]=n[11]*o,t[12]=n[12],t[13]=n[13],t[14]=n[14],t[15]=n[15],t}function fn(t,n,r,e){var u,o,i,a,c,f,s,d,l,p,v,m,b,y,M,g,w,A,S,E,_,x,O,P,R=e[0],j=e[1],T=e[2],C=Math.hypot(R,j,T);return C<h?null:(R*=C=1/C,j*=C,T*=C,u=Math.sin(r),i=1-(o=Math.cos(r)),a=n[0],c=n[1],f=n[2],s=n[3],d=n[4],l=n[5],p=n[6],v=n[7],m=n[8],b=n[9],y=n[10],M=n[11],g=R*R*i+o,w=j*R*i+T*u,A=T*R*i-j*u,S=R*j*i-T*u,E=j*j*i+o,_=T*j*i+R*u,x=R*T*i+j*u,O=j*T*i-R*u,P=T*T*i+o,t[0]=a*g+d*w+m*A,t[1]=c*g+l*w+b*A,t[2]=f*g+p*w+y*A,t[3]=s*g+v*w+M*A,t[4]=a*S+d*E+m*_,t[5]=c*S+l*E+b*_,t[6]=f*S+p*E+y*_,t[7]=s*S+v*E+M*_,t[8]=a*x+d*O+m*P,t[9]=c*x+l*O+b*P,t[10]=f*x+p*O+y*P,t[11]=s*x+v*O+M*P,n!==t&&(t[12]=n[12],t[13]=n[13],t[14]=n[14],t[15]=n[15]),t)}function sn(t,n,r){var e=Math.sin(r),u=Math.cos(r),o=n[4],i=n[5],a=n[6],c=n[7],f=n[8],s=n[9],d=n[10],l=n[11];return n!==t&&(t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[12]=n[12],t[13]=n[13],t[14]=n[14],t[15]=n[15]),t[4]=o*u+f*e,t[5]=i*u+s*e,t[6]=a*u+d*e,t[7]=c*u+l*e,t[8]=f*u-o*e,t[9]=s*u-i*e,t[10]=d*u-a*e,t[11]=l*u-c*e,t}function dn(t,n,r){var e=Math.sin(r),u=Math.cos(r),o=n[0],i=n[1],a=n[2],c=n[3],f=n[8],s=n[9],d=n[10],l=n[11];return n!==t&&(t[4]=n[4],t[5]=n[5],t[6]=n[6],t[7]=n[7],t[12]=n[12],t[13]=n[13],t[14]=n[14],t[15]=n[15]),t[0]=o*u-f*e,t[1]=i*u-s*e,t[2]=a*u-d*e,t[3]=c*u-l*e,t[8]=o*e+f*u,t[9]=i*e+s*u,t[10]=a*e+d*u,t[11]=c*e+l*u,t}function ln(t,n,r){var e=Math.sin(r),u=Math.cos(r),o=n[0],i=n[1],a=n[2],c=n[3],f=n[4],s=n[5],d=n[6],l=n[7];return n!==t&&(t[8]=n[8],t[9]=n[9],t[10]=n[10],t[11]=n[11],t[12]=n[12],t[13]=n[13],t[14]=n[14],t[15]=n[15]),t[0]=o*u+f*e,t[1]=i*u+s*e,t[2]=a*u+d*e,t[3]=c*u+l*e,t[4]=f*u-o*e,t[5]=s*u-i*e,t[6]=d*u-a*e,t[7]=l*u-c*e,t}function hn(t,n){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=n[0],t[13]=n[1],t[14]=n[2],t[15]=1,t}function pn(t,n){return t[0]=n[0],t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=n[1],t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=n[2],t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function vn(t,n,r){var e,u,o,i=r[0],a=r[1],c=r[2],f=Math.hypot(i,a,c);return f<h?null:(i*=f=1/f,a*=f,c*=f,e=Math.sin(n),o=1-(u=Math.cos(n)),t[0]=i*i*o+u,t[1]=a*i*o+c*e,t[2]=c*i*o-a*e,t[3]=0,t[4]=i*a*o-c*e,t[5]=a*a*o+u,t[6]=c*a*o+i*e,t[7]=0,t[8]=i*c*o+a*e,t[9]=a*c*o-i*e,t[10]=c*c*o+u,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t)}function mn(t,n){var r=Math.sin(n),e=Math.cos(n);return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=e,t[6]=r,t[7]=0,t[8]=0,t[9]=-r,t[10]=e,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function bn(t,n){var r=Math.sin(n),e=Math.cos(n);return t[0]=e,t[1]=0,t[2]=-r,t[3]=0,t[4]=0,t[5]=1,t[6]=0,t[7]=0,t[8]=r,t[9]=0,t[10]=e,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function yn(t,n){var r=Math.sin(n),e=Math.cos(n);return t[0]=e,t[1]=r,t[2]=0,t[3]=0,t[4]=-r,t[5]=e,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=1,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function Mn(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=e+e,c=u+u,f=o+o,s=e*a,d=e*c,l=e*f,h=u*c,p=u*f,v=o*f,m=i*a,b=i*c,y=i*f;return t[0]=1-(h+v),t[1]=d+y,t[2]=l-b,t[3]=0,t[4]=d-y,t[5]=1-(s+v),t[6]=p+m,t[7]=0,t[8]=l+b,t[9]=p-m,t[10]=1-(s+h),t[11]=0,t[12]=r[0],t[13]=r[1],t[14]=r[2],t[15]=1,t}function gn(t,n){var r=new p(3),e=-n[0],u=-n[1],o=-n[2],i=n[3],a=n[4],c=n[5],f=n[6],s=n[7],d=e*e+u*u+o*o+i*i;return d>0?(r[0]=2*(a*i+s*e+c*o-f*u)/d,r[1]=2*(c*i+s*u+f*e-a*o)/d,r[2]=2*(f*i+s*o+a*u-c*e)/d):(r[0]=2*(a*i+s*e+c*o-f*u),r[1]=2*(c*i+s*u+f*e-a*o),r[2]=2*(f*i+s*o+a*u-c*e)),Mn(t,n,r),t}function wn(t,n){return t[0]=n[12],t[1]=n[13],t[2]=n[14],t}function An(t,n){var r=n[0],e=n[1],u=n[2],o=n[4],i=n[5],a=n[6],c=n[8],f=n[9],s=n[10];return t[0]=Math.hypot(r,e,u),t[1]=Math.hypot(o,i,a),t[2]=Math.hypot(c,f,s),t}function Sn(t,n){var r=new p(3);An(r,n);var e=1/r[0],u=1/r[1],o=1/r[2],i=n[0]*e,a=n[1]*u,c=n[2]*o,f=n[4]*e,s=n[5]*u,d=n[6]*o,l=n[8]*e,h=n[9]*u,v=n[10]*o,m=i+s+v,b=0;return m>0?(b=2*Math.sqrt(m+1),t[3]=.25*b,t[0]=(d-h)/b,t[1]=(l-c)/b,t[2]=(a-f)/b):i>s&&i>v?(b=2*Math.sqrt(1+i-s-v),t[3]=(d-h)/b,t[0]=.25*b,t[1]=(a+f)/b,t[2]=(l+c)/b):s>v?(b=2*Math.sqrt(1+s-i-v),t[3]=(l-c)/b,t[0]=(a+f)/b,t[1]=.25*b,t[2]=(d+h)/b):(b=2*Math.sqrt(1+v-i-s),t[3]=(a-f)/b,t[0]=(l+c)/b,t[1]=(d+h)/b,t[2]=.25*b),t}function En(t,n,r,e){var u=n[0],o=n[1],i=n[2],a=n[3],c=u+u,f=o+o,s=i+i,d=u*c,l=u*f,h=u*s,p=o*f,v=o*s,m=i*s,b=a*c,y=a*f,M=a*s,g=e[0],w=e[1],A=e[2];return t[0]=(1-(p+m))*g,t[1]=(l+M)*g,t[2]=(h-y)*g,t[3]=0,t[4]=(l-M)*w,t[5]=(1-(d+m))*w,t[6]=(v+b)*w,t[7]=0,t[8]=(h+y)*A,t[9]=(v-b)*A,t[10]=(1-(d+p))*A,t[11]=0,t[12]=r[0],t[13]=r[1],t[14]=r[2],t[15]=1,t}function _n(t,n,r,e,u){var o=n[0],i=n[1],a=n[2],c=n[3],f=o+o,s=i+i,d=a+a,l=o*f,h=o*s,p=o*d,v=i*s,m=i*d,b=a*d,y=c*f,M=c*s,g=c*d,w=e[0],A=e[1],S=e[2],E=u[0],_=u[1],x=u[2],O=(1-(v+b))*w,P=(h+g)*w,R=(p-M)*w,j=(h-g)*A,T=(1-(l+b))*A,C=(m+y)*A,G=(p+M)*S,L=(m-y)*S,V=(1-(l+v))*S;return t[0]=O,t[1]=P,t[2]=R,t[3]=0,t[4]=j,t[5]=T,t[6]=C,t[7]=0,t[8]=G,t[9]=L,t[10]=V,t[11]=0,t[12]=r[0]+E-(O*E+j*_+G*x),t[13]=r[1]+_-(P*E+T*_+L*x),t[14]=r[2]+x-(R*E+C*_+V*x),t[15]=1,t}function xn(t,n){var r=n[0],e=n[1],u=n[2],o=n[3],i=r+r,a=e+e,c=u+u,f=r*i,s=e*i,d=e*a,l=u*i,h=u*a,p=u*c,v=o*i,m=o*a,b=o*c;return t[0]=1-d-p,t[1]=s+b,t[2]=l-m,t[3]=0,t[4]=s-b,t[5]=1-f-p,t[6]=h+v,t[7]=0,t[8]=l+m,t[9]=h-v,t[10]=1-f-d,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,t}function On(t,n,r,e,u,o,i){var a=1/(r-n),c=1/(u-e),f=1/(o-i);return t[0]=2*o*a,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=2*o*c,t[6]=0,t[7]=0,t[8]=(r+n)*a,t[9]=(u+e)*c,t[10]=(i+o)*f,t[11]=-1,t[12]=0,t[13]=0,t[14]=i*o*2*f,t[15]=0,t}function Pn(t,n,r,e,u){var o,i=1/Math.tan(n/2);return t[0]=i/r,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=i,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[11]=-1,t[12]=0,t[13]=0,t[15]=0,null!=u&&u!==1/0?(o=1/(e-u),t[10]=(u+e)*o,t[14]=2*u*e*o):(t[10]=-1,t[14]=-2*e),t}var Rn=Pn;function jn(t,n,r,e,u){var o,i=1/Math.tan(n/2);return t[0]=i/r,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=i,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[11]=-1,t[12]=0,t[13]=0,t[15]=0,null!=u&&u!==1/0?(o=1/(e-u),t[10]=u*o,t[14]=u*e*o):(t[10]=-1,t[14]=-e),t}function Tn(t,n,r,e){var u=Math.tan(n.upDegrees*Math.PI/180),o=Math.tan(n.downDegrees*Math.PI/180),i=Math.tan(n.leftDegrees*Math.PI/180),a=Math.tan(n.rightDegrees*Math.PI/180),c=2/(i+a),f=2/(u+o);return t[0]=c,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=f,t[6]=0,t[7]=0,t[8]=-(i-a)*c*.5,t[9]=(u-o)*f*.5,t[10]=e/(r-e),t[11]=-1,t[12]=0,t[13]=0,t[14]=e*r/(r-e),t[15]=0,t}function Cn(t,n,r,e,u,o,i){var a=1/(n-r),c=1/(e-u),f=1/(o-i);return t[0]=-2*a,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=-2*c,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=2*f,t[11]=0,t[12]=(n+r)*a,t[13]=(u+e)*c,t[14]=(i+o)*f,t[15]=1,t}var Gn=Cn;function Ln(t,n,r,e,u,o,i){var a=1/(n-r),c=1/(e-u),f=1/(o-i);return t[0]=-2*a,t[1]=0,t[2]=0,t[3]=0,t[4]=0,t[5]=-2*c,t[6]=0,t[7]=0,t[8]=0,t[9]=0,t[10]=f,t[11]=0,t[12]=(n+r)*a,t[13]=(u+e)*c,t[14]=o*f,t[15]=1,t}function Vn(t,n,r,e){var u,o,i,a,c,f,s,d,l,p,v=n[0],m=n[1],b=n[2],y=e[0],M=e[1],g=e[2],w=r[0],A=r[1],S=r[2];return Math.abs(v-w)<h&&Math.abs(m-A)<h&&Math.abs(b-S)<h?tn(t):(s=v-w,d=m-A,l=b-S,u=M*(l*=p=1/Math.hypot(s,d,l))-g*(d*=p),o=g*(s*=p)-y*l,i=y*d-M*s,(p=Math.hypot(u,o,i))?(u*=p=1/p,o*=p,i*=p):(u=0,o=0,i=0),a=d*i-l*o,c=l*u-s*i,f=s*o-d*u,(p=Math.hypot(a,c,f))?(a*=p=1/p,c*=p,f*=p):(a=0,c=0,f=0),t[0]=u,t[1]=a,t[2]=s,t[3]=0,t[4]=o,t[5]=c,t[6]=d,t[7]=0,t[8]=i,t[9]=f,t[10]=l,t[11]=0,t[12]=-(u*v+o*m+i*b),t[13]=-(a*v+c*m+f*b),t[14]=-(s*v+d*m+l*b),t[15]=1,t)}function kn(t,n,r,e){var u=n[0],o=n[1],i=n[2],a=e[0],c=e[1],f=e[2],s=u-r[0],d=o-r[1],l=i-r[2],h=s*s+d*d+l*l;h>0&&(s*=h=1/Math.sqrt(h),d*=h,l*=h);var p=c*l-f*d,v=f*s-a*l,m=a*d-c*s;return(h=p*p+v*v+m*m)>0&&(p*=h=1/Math.sqrt(h),v*=h,m*=h),t[0]=p,t[1]=v,t[2]=m,t[3]=0,t[4]=d*m-l*v,t[5]=l*p-s*m,t[6]=s*v-d*p,t[7]=0,t[8]=s,t[9]=d,t[10]=l,t[11]=0,t[12]=u,t[13]=o,t[14]=i,t[15]=1,t}function qn(t){return"mat4("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+", "+t[6]+", "+t[7]+", "+t[8]+", "+t[9]+", "+t[10]+", "+t[11]+", "+t[12]+", "+t[13]+", "+t[14]+", "+t[15]+")"}function Dn(t){return Math.hypot(t[0],t[1],t[2],t[3],t[4],t[5],t[6],t[7],t[8],t[9],t[10],t[11],t[12],t[13],t[14],t[15])}function Nn(t,n,r){return t[0]=n[0]+r[0],t[1]=n[1]+r[1],t[2]=n[2]+r[2],t[3]=n[3]+r[3],t[4]=n[4]+r[4],t[5]=n[5]+r[5],t[6]=n[6]+r[6],t[7]=n[7]+r[7],t[8]=n[8]+r[8],t[9]=n[9]+r[9],t[10]=n[10]+r[10],t[11]=n[11]+r[11],t[12]=n[12]+r[12],t[13]=n[13]+r[13],t[14]=n[14]+r[14],t[15]=n[15]+r[15],t}function In(t,n,r){return t[0]=n[0]-r[0],t[1]=n[1]-r[1],t[2]=n[2]-r[2],t[3]=n[3]-r[3],t[4]=n[4]-r[4],t[5]=n[5]-r[5],t[6]=n[6]-r[6],t[7]=n[7]-r[7],t[8]=n[8]-r[8],t[9]=n[9]-r[9],t[10]=n[10]-r[10],t[11]=n[11]-r[11],t[12]=n[12]-r[12],t[13]=n[13]-r[13],t[14]=n[14]-r[14],t[15]=n[15]-r[15],t}function Fn(t,n,r){return t[0]=n[0]*r,t[1]=n[1]*r,t[2]=n[2]*r,t[3]=n[3]*r,t[4]=n[4]*r,t[5]=n[5]*r,t[6]=n[6]*r,t[7]=n[7]*r,t[8]=n[8]*r,t[9]=n[9]*r,t[10]=n[10]*r,t[11]=n[11]*r,t[12]=n[12]*r,t[13]=n[13]*r,t[14]=n[14]*r,t[15]=n[15]*r,t}function $n(t,n,r,e){return t[0]=n[0]+r[0]*e,t[1]=n[1]+r[1]*e,t[2]=n[2]+r[2]*e,t[3]=n[3]+r[3]*e,t[4]=n[4]+r[4]*e,t[5]=n[5]+r[5]*e,t[6]=n[6]+r[6]*e,t[7]=n[7]+r[7]*e,t[8]=n[8]+r[8]*e,t[9]=n[9]+r[9]*e,t[10]=n[10]+r[10]*e,t[11]=n[11]+r[11]*e,t[12]=n[12]+r[12]*e,t[13]=n[13]+r[13]*e,t[14]=n[14]+r[14]*e,t[15]=n[15]+r[15]*e,t}function Bn(t,n){return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]&&t[3]===n[3]&&t[4]===n[4]&&t[5]===n[5]&&t[6]===n[6]&&t[7]===n[7]&&t[8]===n[8]&&t[9]===n[9]&&t[10]===n[10]&&t[11]===n[11]&&t[12]===n[12]&&t[13]===n[13]&&t[14]===n[14]&&t[15]===n[15]}function Wn(t,n){var r=t[0],e=t[1],u=t[2],o=t[3],i=t[4],a=t[5],c=t[6],f=t[7],s=t[8],d=t[9],l=t[10],p=t[11],v=t[12],m=t[13],b=t[14],y=t[15],M=n[0],g=n[1],w=n[2],A=n[3],S=n[4],E=n[5],_=n[6],x=n[7],O=n[8],P=n[9],R=n[10],j=n[11],T=n[12],C=n[13],G=n[14],L=n[15];return Math.abs(r-M)<=h*Math.max(1,Math.abs(r),Math.abs(M))&&Math.abs(e-g)<=h*Math.max(1,Math.abs(e),Math.abs(g))&&Math.abs(u-w)<=h*Math.max(1,Math.abs(u),Math.abs(w))&&Math.abs(o-A)<=h*Math.max(1,Math.abs(o),Math.abs(A))&&Math.abs(i-S)<=h*Math.max(1,Math.abs(i),Math.abs(S))&&Math.abs(a-E)<=h*Math.max(1,Math.abs(a),Math.abs(E))&&Math.abs(c-_)<=h*Math.max(1,Math.abs(c),Math.abs(_))&&Math.abs(f-x)<=h*Math.max(1,Math.abs(f),Math.abs(x))&&Math.abs(s-O)<=h*Math.max(1,Math.abs(s),Math.abs(O))&&Math.abs(d-P)<=h*Math.max(1,Math.abs(d),Math.abs(P))&&Math.abs(l-R)<=h*Math.max(1,Math.abs(l),Math.abs(R))&&Math.abs(p-j)<=h*Math.max(1,Math.abs(p),Math.abs(j))&&Math.abs(v-T)<=h*Math.max(1,Math.abs(v),Math.abs(T))&&Math.abs(m-C)<=h*Math.max(1,Math.abs(m),Math.abs(C))&&Math.abs(b-G)<=h*Math.max(1,Math.abs(b),Math.abs(G))&&Math.abs(y-L)<=h*Math.max(1,Math.abs(y),Math.abs(L))}var Hn=on,Un=In;function zn(){var t=new p(3);return p!=Float32Array&&(t[0]=0,t[1]=0,t[2]=0),t}function Yn(t){var n=new p(3);return n[0]=t[0],n[1]=t[1],n[2]=t[2],n}function Xn(t){var n=t[0],r=t[1],e=t[2];return Math.hypot(n,r,e)}function Qn(t,n,r){var e=new p(3);return e[0]=t,e[1]=n,e[2]=r,e}function Zn(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t}function Kn(t,n,r,e){return t[0]=n,t[1]=r,t[2]=e,t}function Jn(t,n,r){return t[0]=n[0]+r[0],t[1]=n[1]+r[1],t[2]=n[2]+r[2],t}function tr(t,n,r){return t[0]=n[0]-r[0],t[1]=n[1]-r[1],t[2]=n[2]-r[2],t}function nr(t,n,r){return t[0]=n[0]*r[0],t[1]=n[1]*r[1],t[2]=n[2]*r[2],t}function rr(t,n,r){return t[0]=n[0]/r[0],t[1]=n[1]/r[1],t[2]=n[2]/r[2],t}function er(t,n){return t[0]=Math.ceil(n[0]),t[1]=Math.ceil(n[1]),t[2]=Math.ceil(n[2]),t}function ur(t,n){return t[0]=Math.floor(n[0]),t[1]=Math.floor(n[1]),t[2]=Math.floor(n[2]),t}function or(t,n,r){return t[0]=Math.min(n[0],r[0]),t[1]=Math.min(n[1],r[1]),t[2]=Math.min(n[2],r[2]),t}function ir(t,n,r){return t[0]=Math.max(n[0],r[0]),t[1]=Math.max(n[1],r[1]),t[2]=Math.max(n[2],r[2]),t}function ar(t,n){return t[0]=Math.round(n[0]),t[1]=Math.round(n[1]),t[2]=Math.round(n[2]),t}function cr(t,n,r){return t[0]=n[0]*r,t[1]=n[1]*r,t[2]=n[2]*r,t}function fr(t,n,r,e){return t[0]=n[0]+r[0]*e,t[1]=n[1]+r[1]*e,t[2]=n[2]+r[2]*e,t}function sr(t,n){var r=n[0]-t[0],e=n[1]-t[1],u=n[2]-t[2];return Math.hypot(r,e,u)}function dr(t,n){var r=n[0]-t[0],e=n[1]-t[1],u=n[2]-t[2];return r*r+e*e+u*u}function lr(t){var n=t[0],r=t[1],e=t[2];return n*n+r*r+e*e}function hr(t,n){return t[0]=-n[0],t[1]=-n[1],t[2]=-n[2],t}function pr(t,n){return t[0]=1/n[0],t[1]=1/n[1],t[2]=1/n[2],t}function vr(t,n){var r=n[0],e=n[1],u=n[2],o=r*r+e*e+u*u;return o>0&&(o=1/Math.sqrt(o)),t[0]=n[0]*o,t[1]=n[1]*o,t[2]=n[2]*o,t}function mr(t,n){return t[0]*n[0]+t[1]*n[1]+t[2]*n[2]}function br(t,n,r){var e=n[0],u=n[1],o=n[2],i=r[0],a=r[1],c=r[2];return t[0]=u*c-o*a,t[1]=o*i-e*c,t[2]=e*a-u*i,t}function yr(t,n,r,e){var u=n[0],o=n[1],i=n[2];return t[0]=u+e*(r[0]-u),t[1]=o+e*(r[1]-o),t[2]=i+e*(r[2]-i),t}function Mr(t,n,r,e,u,o){var i=o*o,a=i*(2*o-3)+1,c=i*(o-2)+o,f=i*(o-1),s=i*(3-2*o);return t[0]=n[0]*a+r[0]*c+e[0]*f+u[0]*s,t[1]=n[1]*a+r[1]*c+e[1]*f+u[1]*s,t[2]=n[2]*a+r[2]*c+e[2]*f+u[2]*s,t}function gr(t,n,r,e,u,o){var i=1-o,a=i*i,c=o*o,f=a*i,s=3*o*a,d=3*c*i,l=c*o;return t[0]=n[0]*f+r[0]*s+e[0]*d+u[0]*l,t[1]=n[1]*f+r[1]*s+e[1]*d+u[1]*l,t[2]=n[2]*f+r[2]*s+e[2]*d+u[2]*l,t}function wr(t,n){n=n||1;var r=2*v()*Math.PI,e=2*v()-1,u=Math.sqrt(1-e*e)*n;return t[0]=Math.cos(r)*u,t[1]=Math.sin(r)*u,t[2]=e*n,t}function Ar(t,n,r){var e=n[0],u=n[1],o=n[2],i=r[3]*e+r[7]*u+r[11]*o+r[15];return i=i||1,t[0]=(r[0]*e+r[4]*u+r[8]*o+r[12])/i,t[1]=(r[1]*e+r[5]*u+r[9]*o+r[13])/i,t[2]=(r[2]*e+r[6]*u+r[10]*o+r[14])/i,t}function Sr(t,n,r){var e=n[0],u=n[1],o=n[2];return t[0]=e*r[0]+u*r[3]+o*r[6],t[1]=e*r[1]+u*r[4]+o*r[7],t[2]=e*r[2]+u*r[5]+o*r[8],t}function Er(t,n,r){var e=r[0],u=r[1],o=r[2],i=r[3],a=n[0],c=n[1],f=n[2],s=u*f-o*c,d=o*a-e*f,l=e*c-u*a,h=u*l-o*d,p=o*s-e*l,v=e*d-u*s,m=2*i;return s*=m,d*=m,l*=m,h*=2,p*=2,v*=2,t[0]=a+s+h,t[1]=c+d+p,t[2]=f+l+v,t}function _r(t,n,r,e){var u=[],o=[];return u[0]=n[0]-r[0],u[1]=n[1]-r[1],u[2]=n[2]-r[2],o[0]=u[0],o[1]=u[1]*Math.cos(e)-u[2]*Math.sin(e),o[2]=u[1]*Math.sin(e)+u[2]*Math.cos(e),t[0]=o[0]+r[0],t[1]=o[1]+r[1],t[2]=o[2]+r[2],t}function xr(t,n,r,e){var u=[],o=[];return u[0]=n[0]-r[0],u[1]=n[1]-r[1],u[2]=n[2]-r[2],o[0]=u[2]*Math.sin(e)+u[0]*Math.cos(e),o[1]=u[1],o[2]=u[2]*Math.cos(e)-u[0]*Math.sin(e),t[0]=o[0]+r[0],t[1]=o[1]+r[1],t[2]=o[2]+r[2],t}function Or(t,n,r,e){var u=[],o=[];return u[0]=n[0]-r[0],u[1]=n[1]-r[1],u[2]=n[2]-r[2],o[0]=u[0]*Math.cos(e)-u[1]*Math.sin(e),o[1]=u[0]*Math.sin(e)+u[1]*Math.cos(e),o[2]=u[2],t[0]=o[0]+r[0],t[1]=o[1]+r[1],t[2]=o[2]+r[2],t}function Pr(t,n){var r=t[0],e=t[1],u=t[2],o=n[0],i=n[1],a=n[2],c=Math.sqrt(r*r+e*e+u*u)*Math.sqrt(o*o+i*i+a*a),f=c&&mr(t,n)/c;return Math.acos(Math.min(Math.max(f,-1),1))}function Rr(t){return t[0]=0,t[1]=0,t[2]=0,t}function jr(t){return"vec3("+t[0]+", "+t[1]+", "+t[2]+")"}function Tr(t,n){return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]}function Cr(t,n){var r=t[0],e=t[1],u=t[2],o=n[0],i=n[1],a=n[2];return Math.abs(r-o)<=h*Math.max(1,Math.abs(r),Math.abs(o))&&Math.abs(e-i)<=h*Math.max(1,Math.abs(e),Math.abs(i))&&Math.abs(u-a)<=h*Math.max(1,Math.abs(u),Math.abs(a))}var Gr,Lr=tr,Vr=nr,kr=rr,qr=sr,Dr=dr,Nr=Xn,Ir=lr,Fr=(Gr=zn(),function(t,n,r,e,u,o){var i,a;for(n||(n=3),r||(r=0),a=e?Math.min(e*n+r,t.length):t.length,i=r;i<a;i+=n)Gr[0]=t[i],Gr[1]=t[i+1],Gr[2]=t[i+2],u(Gr,Gr,o),t[i]=Gr[0],t[i+1]=Gr[1],t[i+2]=Gr[2];return t});function $r(){var t=new p(4);return p!=Float32Array&&(t[0]=0,t[1]=0,t[2]=0,t[3]=0),t}function Br(t){var n=new p(4);return n[0]=t[0],n[1]=t[1],n[2]=t[2],n[3]=t[3],n}function Wr(t,n,r,e){var u=new p(4);return u[0]=t,u[1]=n,u[2]=r,u[3]=e,u}function Hr(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t}function Ur(t,n,r,e,u){return t[0]=n,t[1]=r,t[2]=e,t[3]=u,t}function zr(t,n,r){return t[0]=n[0]+r[0],t[1]=n[1]+r[1],t[2]=n[2]+r[2],t[3]=n[3]+r[3],t}function Yr(t,n,r){return t[0]=n[0]-r[0],t[1]=n[1]-r[1],t[2]=n[2]-r[2],t[3]=n[3]-r[3],t}function Xr(t,n,r){return t[0]=n[0]*r[0],t[1]=n[1]*r[1],t[2]=n[2]*r[2],t[3]=n[3]*r[3],t}function Qr(t,n,r){return t[0]=n[0]/r[0],t[1]=n[1]/r[1],t[2]=n[2]/r[2],t[3]=n[3]/r[3],t}function Zr(t,n){return t[0]=Math.ceil(n[0]),t[1]=Math.ceil(n[1]),t[2]=Math.ceil(n[2]),t[3]=Math.ceil(n[3]),t}function Kr(t,n){return t[0]=Math.floor(n[0]),t[1]=Math.floor(n[1]),t[2]=Math.floor(n[2]),t[3]=Math.floor(n[3]),t}function Jr(t,n,r){return t[0]=Math.min(n[0],r[0]),t[1]=Math.min(n[1],r[1]),t[2]=Math.min(n[2],r[2]),t[3]=Math.min(n[3],r[3]),t}function te(t,n,r){return t[0]=Math.max(n[0],r[0]),t[1]=Math.max(n[1],r[1]),t[2]=Math.max(n[2],r[2]),t[3]=Math.max(n[3],r[3]),t}function ne(t,n){return t[0]=Math.round(n[0]),t[1]=Math.round(n[1]),t[2]=Math.round(n[2]),t[3]=Math.round(n[3]),t}function re(t,n,r){return t[0]=n[0]*r,t[1]=n[1]*r,t[2]=n[2]*r,t[3]=n[3]*r,t}function ee(t,n,r,e){return t[0]=n[0]+r[0]*e,t[1]=n[1]+r[1]*e,t[2]=n[2]+r[2]*e,t[3]=n[3]+r[3]*e,t}function ue(t,n){var r=n[0]-t[0],e=n[1]-t[1],u=n[2]-t[2],o=n[3]-t[3];return Math.hypot(r,e,u,o)}function oe(t,n){var r=n[0]-t[0],e=n[1]-t[1],u=n[2]-t[2],o=n[3]-t[3];return r*r+e*e+u*u+o*o}function ie(t){var n=t[0],r=t[1],e=t[2],u=t[3];return Math.hypot(n,r,e,u)}function ae(t){var n=t[0],r=t[1],e=t[2],u=t[3];return n*n+r*r+e*e+u*u}function ce(t,n){return t[0]=-n[0],t[1]=-n[1],t[2]=-n[2],t[3]=-n[3],t}function fe(t,n){return t[0]=1/n[0],t[1]=1/n[1],t[2]=1/n[2],t[3]=1/n[3],t}function se(t,n){var r=n[0],e=n[1],u=n[2],o=n[3],i=r*r+e*e+u*u+o*o;return i>0&&(i=1/Math.sqrt(i)),t[0]=r*i,t[1]=e*i,t[2]=u*i,t[3]=o*i,t}function de(t,n){return t[0]*n[0]+t[1]*n[1]+t[2]*n[2]+t[3]*n[3]}function le(t,n,r,e){var u=r[0]*e[1]-r[1]*e[0],o=r[0]*e[2]-r[2]*e[0],i=r[0]*e[3]-r[3]*e[0],a=r[1]*e[2]-r[2]*e[1],c=r[1]*e[3]-r[3]*e[1],f=r[2]*e[3]-r[3]*e[2],s=n[0],d=n[1],l=n[2],h=n[3];return t[0]=d*f-l*c+h*a,t[1]=-s*f+l*i-h*o,t[2]=s*c-d*i+h*u,t[3]=-s*a+d*o-l*u,t}function he(t,n,r,e){var u=n[0],o=n[1],i=n[2],a=n[3];return t[0]=u+e*(r[0]-u),t[1]=o+e*(r[1]-o),t[2]=i+e*(r[2]-i),t[3]=a+e*(r[3]-a),t}function pe(t,n){var r,e,u,o,i,a;n=n||1;do{i=(r=2*v()-1)*r+(e=2*v()-1)*e}while(i>=1);do{a=(u=2*v()-1)*u+(o=2*v()-1)*o}while(a>=1);var c=Math.sqrt((1-i)/a);return t[0]=n*r,t[1]=n*e,t[2]=n*u*c,t[3]=n*o*c,t}function ve(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3];return t[0]=r[0]*e+r[4]*u+r[8]*o+r[12]*i,t[1]=r[1]*e+r[5]*u+r[9]*o+r[13]*i,t[2]=r[2]*e+r[6]*u+r[10]*o+r[14]*i,t[3]=r[3]*e+r[7]*u+r[11]*o+r[15]*i,t}function me(t,n,r){var e=n[0],u=n[1],o=n[2],i=r[0],a=r[1],c=r[2],f=r[3],s=f*e+a*o-c*u,d=f*u+c*e-i*o,l=f*o+i*u-a*e,h=-i*e-a*u-c*o;return t[0]=s*f+h*-i+d*-c-l*-a,t[1]=d*f+h*-a+l*-i-s*-c,t[2]=l*f+h*-c+s*-a-d*-i,t[3]=n[3],t}function be(t){return t[0]=0,t[1]=0,t[2]=0,t[3]=0,t}function ye(t){return"vec4("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+")"}function Me(t,n){return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]&&t[3]===n[3]}function ge(t,n){var r=t[0],e=t[1],u=t[2],o=t[3],i=n[0],a=n[1],c=n[2],f=n[3];return Math.abs(r-i)<=h*Math.max(1,Math.abs(r),Math.abs(i))&&Math.abs(e-a)<=h*Math.max(1,Math.abs(e),Math.abs(a))&&Math.abs(u-c)<=h*Math.max(1,Math.abs(u),Math.abs(c))&&Math.abs(o-f)<=h*Math.max(1,Math.abs(o),Math.abs(f))}var we=Yr,Ae=Xr,Se=Qr,Ee=ue,_e=oe,xe=ie,Oe=ae,Pe=function(){var t=$r();return function(n,r,e,u,o,i){var a,c;for(r||(r=4),e||(e=0),c=u?Math.min(u*r+e,n.length):n.length,a=e;a<c;a+=r)t[0]=n[a],t[1]=n[a+1],t[2]=n[a+2],t[3]=n[a+3],o(t,t,i),n[a]=t[0],n[a+1]=t[1],n[a+2]=t[2],n[a+3]=t[3];return n}}();function Re(){var t=new p(4);return p!=Float32Array&&(t[0]=0,t[1]=0,t[2]=0),t[3]=1,t}function je(t){return t[0]=0,t[1]=0,t[2]=0,t[3]=1,t}function Te(t,n,r){r*=.5;var e=Math.sin(r);return t[0]=e*n[0],t[1]=e*n[1],t[2]=e*n[2],t[3]=Math.cos(r),t}function Ce(t,n){var r=2*Math.acos(n[3]),e=Math.sin(r/2);return e>h?(t[0]=n[0]/e,t[1]=n[1]/e,t[2]=n[2]/e):(t[0]=1,t[1]=0,t[2]=0),r}function Ge(t,n){var r=cu(t,n);return Math.acos(2*r*r-1)}function Le(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=r[0],c=r[1],f=r[2],s=r[3];return t[0]=e*s+i*a+u*f-o*c,t[1]=u*s+i*c+o*a-e*f,t[2]=o*s+i*f+e*c-u*a,t[3]=i*s-e*a-u*c-o*f,t}function Ve(t,n,r){r*=.5;var e=n[0],u=n[1],o=n[2],i=n[3],a=Math.sin(r),c=Math.cos(r);return t[0]=e*c+i*a,t[1]=u*c+o*a,t[2]=o*c-u*a,t[3]=i*c-e*a,t}function ke(t,n,r){r*=.5;var e=n[0],u=n[1],o=n[2],i=n[3],a=Math.sin(r),c=Math.cos(r);return t[0]=e*c-o*a,t[1]=u*c+i*a,t[2]=o*c+e*a,t[3]=i*c-u*a,t}function qe(t,n,r){r*=.5;var e=n[0],u=n[1],o=n[2],i=n[3],a=Math.sin(r),c=Math.cos(r);return t[0]=e*c+u*a,t[1]=u*c-e*a,t[2]=o*c+i*a,t[3]=i*c-o*a,t}function De(t,n){var r=n[0],e=n[1],u=n[2];return t[0]=r,t[1]=e,t[2]=u,t[3]=Math.sqrt(Math.abs(1-r*r-e*e-u*u)),t}function Ne(t,n){var r=n[0],e=n[1],u=n[2],o=n[3],i=Math.sqrt(r*r+e*e+u*u),a=Math.exp(o),c=i>0?a*Math.sin(i)/i:0;return t[0]=r*c,t[1]=e*c,t[2]=u*c,t[3]=a*Math.cos(i),t}function Ie(t,n){var r=n[0],e=n[1],u=n[2],o=n[3],i=Math.sqrt(r*r+e*e+u*u),a=i>0?Math.atan2(i,o)/i:0;return t[0]=r*a,t[1]=e*a,t[2]=u*a,t[3]=.5*Math.log(r*r+e*e+u*u+o*o),t}function Fe(t,n,r){return Ie(t,n),au(t,t,r),Ne(t,t),t}function $e(t,n,r,e){var u,o,i,a,c,f=n[0],s=n[1],d=n[2],l=n[3],p=r[0],v=r[1],m=r[2],b=r[3];return(o=f*p+s*v+d*m+l*b)<0&&(o=-o,p=-p,v=-v,m=-m,b=-b),1-o>h?(u=Math.acos(o),i=Math.sin(u),a=Math.sin((1-e)*u)/i,c=Math.sin(e*u)/i):(a=1-e,c=e),t[0]=a*f+c*p,t[1]=a*s+c*v,t[2]=a*d+c*m,t[3]=a*l+c*b,t}function Be(t){var n=v(),r=v(),e=v(),u=Math.sqrt(1-n),o=Math.sqrt(n);return t[0]=u*Math.sin(2*Math.PI*r),t[1]=u*Math.cos(2*Math.PI*r),t[2]=o*Math.sin(2*Math.PI*e),t[3]=o*Math.cos(2*Math.PI*e),t}function We(t,n){var r=n[0],e=n[1],u=n[2],o=n[3],i=r*r+e*e+u*u+o*o,a=i?1/i:0;return t[0]=-r*a,t[1]=-e*a,t[2]=-u*a,t[3]=o*a,t}function He(t,n){return t[0]=-n[0],t[1]=-n[1],t[2]=-n[2],t[3]=n[3],t}function Ue(t,n){var r,e=n[0]+n[4]+n[8];if(e>0)r=Math.sqrt(e+1),t[3]=.5*r,r=.5/r,t[0]=(n[5]-n[7])*r,t[1]=(n[6]-n[2])*r,t[2]=(n[1]-n[3])*r;else{var u=0;n[4]>n[0]&&(u=1),n[8]>n[3*u+u]&&(u=2);var o=(u+1)%3,i=(u+2)%3;r=Math.sqrt(n[3*u+u]-n[3*o+o]-n[3*i+i]+1),t[u]=.5*r,r=.5/r,t[3]=(n[3*o+i]-n[3*i+o])*r,t[o]=(n[3*o+u]+n[3*u+o])*r,t[i]=(n[3*i+u]+n[3*u+i])*r}return t}function ze(t,n,r,e){var u=.5*Math.PI/180;n*=u,r*=u,e*=u;var o=Math.sin(n),i=Math.cos(n),a=Math.sin(r),c=Math.cos(r),f=Math.sin(e),s=Math.cos(e);return t[0]=o*c*s-i*a*f,t[1]=i*a*s+o*c*f,t[2]=i*c*f-o*a*s,t[3]=i*c*s+o*a*f,t}function Ye(t){return"quat("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+")"}var Xe,Qe,Ze,Ke,Je,tu,nu=Br,ru=Wr,eu=Hr,uu=Ur,ou=zr,iu=Le,au=re,cu=de,fu=he,su=ie,du=su,lu=ae,hu=lu,pu=se,vu=Me,mu=ge,bu=(Xe=zn(),Qe=Qn(1,0,0),Ze=Qn(0,1,0),function(t,n,r){var e=mr(n,r);return e<-.999999?(br(Xe,Qe,n),Nr(Xe)<1e-6&&br(Xe,Ze,n),vr(Xe,Xe),Te(t,Xe,Math.PI),t):e>.999999?(t[0]=0,t[1]=0,t[2]=0,t[3]=1,t):(br(Xe,n,r),t[0]=Xe[0],t[1]=Xe[1],t[2]=Xe[2],t[3]=1+e,pu(t,t))}),yu=(Ke=Re(),Je=Re(),function(t,n,r,e,u,o){return $e(Ke,n,u,o),$e(Je,r,e,o),$e(t,Ke,Je,2*o*(1-o)),t}),Mu=(tu=bt(),function(t,n,r,e){return tu[0]=r[0],tu[3]=r[1],tu[6]=r[2],tu[1]=e[0],tu[4]=e[1],tu[7]=e[2],tu[2]=-n[0],tu[5]=-n[1],tu[8]=-n[2],pu(t,Ue(t,tu))});function gu(){var t=new p(8);return p!=Float32Array&&(t[0]=0,t[1]=0,t[2]=0,t[4]=0,t[5]=0,t[6]=0,t[7]=0),t[3]=1,t}function wu(t){var n=new p(8);return n[0]=t[0],n[1]=t[1],n[2]=t[2],n[3]=t[3],n[4]=t[4],n[5]=t[5],n[6]=t[6],n[7]=t[7],n}function Au(t,n,r,e,u,o,i,a){var c=new p(8);return c[0]=t,c[1]=n,c[2]=r,c[3]=e,c[4]=u,c[5]=o,c[6]=i,c[7]=a,c}function Su(t,n,r,e,u,o,i){var a=new p(8);a[0]=t,a[1]=n,a[2]=r,a[3]=e;var c=.5*u,f=.5*o,s=.5*i;return a[4]=c*e+f*r-s*n,a[5]=f*e+s*t-c*r,a[6]=s*e+c*n-f*t,a[7]=-c*t-f*n-s*r,a}function Eu(t,n,r){var e=.5*r[0],u=.5*r[1],o=.5*r[2],i=n[0],a=n[1],c=n[2],f=n[3];return t[0]=i,t[1]=a,t[2]=c,t[3]=f,t[4]=e*f+u*c-o*a,t[5]=u*f+o*i-e*c,t[6]=o*f+e*a-u*i,t[7]=-e*i-u*a-o*c,t}function _u(t,n){return t[0]=0,t[1]=0,t[2]=0,t[3]=1,t[4]=.5*n[0],t[5]=.5*n[1],t[6]=.5*n[2],t[7]=0,t}function xu(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[4]=0,t[5]=0,t[6]=0,t[7]=0,t}function Ou(t,n){var r=Re();Sn(r,n);var e=new p(3);return wn(e,n),Eu(t,r,e),t}function Pu(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[4]=n[4],t[5]=n[5],t[6]=n[6],t[7]=n[7],t}function Ru(t){return t[0]=0,t[1]=0,t[2]=0,t[3]=1,t[4]=0,t[5]=0,t[6]=0,t[7]=0,t}function ju(t,n,r,e,u,o,i,a,c){return t[0]=n,t[1]=r,t[2]=e,t[3]=u,t[4]=o,t[5]=i,t[6]=a,t[7]=c,t}var Tu=eu;function Cu(t,n){return t[0]=n[4],t[1]=n[5],t[2]=n[6],t[3]=n[7],t}var Gu=eu;function Lu(t,n){return t[4]=n[0],t[5]=n[1],t[6]=n[2],t[7]=n[3],t}function Vu(t,n){var r=n[4],e=n[5],u=n[6],o=n[7],i=-n[0],a=-n[1],c=-n[2],f=n[3];return t[0]=2*(r*f+o*i+e*c-u*a),t[1]=2*(e*f+o*a+u*i-r*c),t[2]=2*(u*f+o*c+r*a-e*i),t}function ku(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=.5*r[0],c=.5*r[1],f=.5*r[2],s=n[4],d=n[5],l=n[6],h=n[7];return t[0]=e,t[1]=u,t[2]=o,t[3]=i,t[4]=i*a+u*f-o*c+s,t[5]=i*c+o*a-e*f+d,t[6]=i*f+e*c-u*a+l,t[7]=-e*a-u*c-o*f+h,t}function qu(t,n,r){var e=-n[0],u=-n[1],o=-n[2],i=n[3],a=n[4],c=n[5],f=n[6],s=n[7],d=a*i+s*e+c*o-f*u,l=c*i+s*u+f*e-a*o,h=f*i+s*o+a*u-c*e,p=s*i-a*e-c*u-f*o;return Ve(t,n,r),e=t[0],u=t[1],o=t[2],i=t[3],t[4]=d*i+p*e+l*o-h*u,t[5]=l*i+p*u+h*e-d*o,t[6]=h*i+p*o+d*u-l*e,t[7]=p*i-d*e-l*u-h*o,t}function Du(t,n,r){var e=-n[0],u=-n[1],o=-n[2],i=n[3],a=n[4],c=n[5],f=n[6],s=n[7],d=a*i+s*e+c*o-f*u,l=c*i+s*u+f*e-a*o,h=f*i+s*o+a*u-c*e,p=s*i-a*e-c*u-f*o;return ke(t,n,r),e=t[0],u=t[1],o=t[2],i=t[3],t[4]=d*i+p*e+l*o-h*u,t[5]=l*i+p*u+h*e-d*o,t[6]=h*i+p*o+d*u-l*e,t[7]=p*i-d*e-l*u-h*o,t}function Nu(t,n,r){var e=-n[0],u=-n[1],o=-n[2],i=n[3],a=n[4],c=n[5],f=n[6],s=n[7],d=a*i+s*e+c*o-f*u,l=c*i+s*u+f*e-a*o,h=f*i+s*o+a*u-c*e,p=s*i-a*e-c*u-f*o;return qe(t,n,r),e=t[0],u=t[1],o=t[2],i=t[3],t[4]=d*i+p*e+l*o-h*u,t[5]=l*i+p*u+h*e-d*o,t[6]=h*i+p*o+d*u-l*e,t[7]=p*i-d*e-l*u-h*o,t}function Iu(t,n,r){var e=r[0],u=r[1],o=r[2],i=r[3],a=n[0],c=n[1],f=n[2],s=n[3];return t[0]=a*i+s*e+c*o-f*u,t[1]=c*i+s*u+f*e-a*o,t[2]=f*i+s*o+a*u-c*e,t[3]=s*i-a*e-c*u-f*o,a=n[4],c=n[5],f=n[6],s=n[7],t[4]=a*i+s*e+c*o-f*u,t[5]=c*i+s*u+f*e-a*o,t[6]=f*i+s*o+a*u-c*e,t[7]=s*i-a*e-c*u-f*o,t}function Fu(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=r[0],c=r[1],f=r[2],s=r[3];return t[0]=e*s+i*a+u*f-o*c,t[1]=u*s+i*c+o*a-e*f,t[2]=o*s+i*f+e*c-u*a,t[3]=i*s-e*a-u*c-o*f,a=r[4],c=r[5],f=r[6],s=r[7],t[4]=e*s+i*a+u*f-o*c,t[5]=u*s+i*c+o*a-e*f,t[6]=o*s+i*f+e*c-u*a,t[7]=i*s-e*a-u*c-o*f,t}function $u(t,n,r,e){if(Math.abs(e)<h)return Pu(t,n);var u=Math.hypot(r[0],r[1],r[2]);e*=.5;var o=Math.sin(e),i=o*r[0]/u,a=o*r[1]/u,c=o*r[2]/u,f=Math.cos(e),s=n[0],d=n[1],l=n[2],p=n[3];t[0]=s*f+p*i+d*c-l*a,t[1]=d*f+p*a+l*i-s*c,t[2]=l*f+p*c+s*a-d*i,t[3]=p*f-s*i-d*a-l*c;var v=n[4],m=n[5],b=n[6],y=n[7];return t[4]=v*f+y*i+m*c-b*a,t[5]=m*f+y*a+b*i-v*c,t[6]=b*f+y*c+v*a-m*i,t[7]=y*f-v*i-m*a-b*c,t}function Bu(t,n,r){return t[0]=n[0]+r[0],t[1]=n[1]+r[1],t[2]=n[2]+r[2],t[3]=n[3]+r[3],t[4]=n[4]+r[4],t[5]=n[5]+r[5],t[6]=n[6]+r[6],t[7]=n[7]+r[7],t}function Wu(t,n,r){var e=n[0],u=n[1],o=n[2],i=n[3],a=r[4],c=r[5],f=r[6],s=r[7],d=n[4],l=n[5],h=n[6],p=n[7],v=r[0],m=r[1],b=r[2],y=r[3];return t[0]=e*y+i*v+u*b-o*m,t[1]=u*y+i*m+o*v-e*b,t[2]=o*y+i*b+e*m-u*v,t[3]=i*y-e*v-u*m-o*b,t[4]=e*s+i*a+u*f-o*c+d*y+p*v+l*b-h*m,t[5]=u*s+i*c+o*a-e*f+l*y+p*m+h*v-d*b,t[6]=o*s+i*f+e*c-u*a+h*y+p*b+d*m-l*v,t[7]=i*s-e*a-u*c-o*f+p*y-d*v-l*m-h*b,t}var Hu=Wu;function Uu(t,n,r){return t[0]=n[0]*r,t[1]=n[1]*r,t[2]=n[2]*r,t[3]=n[3]*r,t[4]=n[4]*r,t[5]=n[5]*r,t[6]=n[6]*r,t[7]=n[7]*r,t}var zu=cu;function Yu(t,n,r,e){var u=1-e;return zu(n,r)<0&&(e=-e),t[0]=n[0]*u+r[0]*e,t[1]=n[1]*u+r[1]*e,t[2]=n[2]*u+r[2]*e,t[3]=n[3]*u+r[3]*e,t[4]=n[4]*u+r[4]*e,t[5]=n[5]*u+r[5]*e,t[6]=n[6]*u+r[6]*e,t[7]=n[7]*u+r[7]*e,t}function Xu(t,n){var r=Ju(n);return t[0]=-n[0]/r,t[1]=-n[1]/r,t[2]=-n[2]/r,t[3]=n[3]/r,t[4]=-n[4]/r,t[5]=-n[5]/r,t[6]=-n[6]/r,t[7]=n[7]/r,t}function Qu(t,n){return t[0]=-n[0],t[1]=-n[1],t[2]=-n[2],t[3]=n[3],t[4]=-n[4],t[5]=-n[5],t[6]=-n[6],t[7]=n[7],t}var Zu=su,Ku=Zu,Ju=lu,to=Ju;function no(t,n){var r=Ju(n);if(r>0){r=Math.sqrt(r);var e=n[0]/r,u=n[1]/r,o=n[2]/r,i=n[3]/r,a=n[4],c=n[5],f=n[6],s=n[7],d=e*a+u*c+o*f+i*s;t[0]=e,t[1]=u,t[2]=o,t[3]=i,t[4]=(a-e*d)/r,t[5]=(c-u*d)/r,t[6]=(f-o*d)/r,t[7]=(s-i*d)/r}return t}function ro(t){return"quat2("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+", "+t[6]+", "+t[7]+")"}function eo(t,n){return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]&&t[3]===n[3]&&t[4]===n[4]&&t[5]===n[5]&&t[6]===n[6]&&t[7]===n[7]}function uo(t,n){var r=t[0],e=t[1],u=t[2],o=t[3],i=t[4],a=t[5],c=t[6],f=t[7],s=n[0],d=n[1],l=n[2],p=n[3],v=n[4],m=n[5],b=n[6],y=n[7];return Math.abs(r-s)<=h*Math.max(1,Math.abs(r),Math.abs(s))&&Math.abs(e-d)<=h*Math.max(1,Math.abs(e),Math.abs(d))&&Math.abs(u-l)<=h*Math.max(1,Math.abs(u),Math.abs(l))&&Math.abs(o-p)<=h*Math.max(1,Math.abs(o),Math.abs(p))&&Math.abs(i-v)<=h*Math.max(1,Math.abs(i),Math.abs(v))&&Math.abs(a-m)<=h*Math.max(1,Math.abs(a),Math.abs(m))&&Math.abs(c-b)<=h*Math.max(1,Math.abs(c),Math.abs(b))&&Math.abs(f-y)<=h*Math.max(1,Math.abs(f),Math.abs(y))}function oo(){var t=new p(2);return p!=Float32Array&&(t[0]=0,t[1]=0),t}function io(t){var n=new p(2);return n[0]=t[0],n[1]=t[1],n}function ao(t,n){var r=new p(2);return r[0]=t,r[1]=n,r}function co(t,n){return t[0]=n[0],t[1]=n[1],t}function fo(t,n,r){return t[0]=n,t[1]=r,t}function so(t,n,r){return t[0]=n[0]+r[0],t[1]=n[1]+r[1],t}function lo(t,n,r){return t[0]=n[0]-r[0],t[1]=n[1]-r[1],t}function ho(t,n,r){return t[0]=n[0]*r[0],t[1]=n[1]*r[1],t}function po(t,n,r){return t[0]=n[0]/r[0],t[1]=n[1]/r[1],t}function vo(t,n){return t[0]=Math.ceil(n[0]),t[1]=Math.ceil(n[1]),t}function mo(t,n){return t[0]=Math.floor(n[0]),t[1]=Math.floor(n[1]),t}function bo(t,n,r){return t[0]=Math.min(n[0],r[0]),t[1]=Math.min(n[1],r[1]),t}function yo(t,n,r){return t[0]=Math.max(n[0],r[0]),t[1]=Math.max(n[1],r[1]),t}function Mo(t,n){return t[0]=Math.round(n[0]),t[1]=Math.round(n[1]),t}function go(t,n,r){return t[0]=n[0]*r,t[1]=n[1]*r,t}function wo(t,n,r,e){return t[0]=n[0]+r[0]*e,t[1]=n[1]+r[1]*e,t}function Ao(t,n){var r=n[0]-t[0],e=n[1]-t[1];return Math.hypot(r,e)}function So(t,n){var r=n[0]-t[0],e=n[1]-t[1];return r*r+e*e}function Eo(t){var n=t[0],r=t[1];return Math.hypot(n,r)}function _o(t){var n=t[0],r=t[1];return n*n+r*r}function xo(t,n){return t[0]=-n[0],t[1]=-n[1],t}function Oo(t,n){return t[0]=1/n[0],t[1]=1/n[1],t}function Po(t,n){var r=n[0],e=n[1],u=r*r+e*e;return u>0&&(u=1/Math.sqrt(u)),t[0]=n[0]*u,t[1]=n[1]*u,t}function Ro(t,n){return t[0]*n[0]+t[1]*n[1]}function jo(t,n,r){var e=n[0]*r[1]-n[1]*r[0];return t[0]=t[1]=0,t[2]=e,t}function To(t,n,r,e){var u=n[0],o=n[1];return t[0]=u+e*(r[0]-u),t[1]=o+e*(r[1]-o),t}function Co(t,n){n=n||1;var r=2*v()*Math.PI;return t[0]=Math.cos(r)*n,t[1]=Math.sin(r)*n,t}function Go(t,n,r){var e=n[0],u=n[1];return t[0]=r[0]*e+r[2]*u,t[1]=r[1]*e+r[3]*u,t}function Lo(t,n,r){var e=n[0],u=n[1];return t[0]=r[0]*e+r[2]*u+r[4],t[1]=r[1]*e+r[3]*u+r[5],t}function Vo(t,n,r){var e=n[0],u=n[1];return t[0]=r[0]*e+r[3]*u+r[6],t[1]=r[1]*e+r[4]*u+r[7],t}function ko(t,n,r){var e=n[0],u=n[1];return t[0]=r[0]*e+r[4]*u+r[12],t[1]=r[1]*e+r[5]*u+r[13],t}function qo(t,n,r,e){var u=n[0]-r[0],o=n[1]-r[1],i=Math.sin(e),a=Math.cos(e);return t[0]=u*a-o*i+r[0],t[1]=u*i+o*a+r[1],t}function Do(t,n){var r=t[0],e=t[1],u=n[0],o=n[1],i=Math.sqrt(r*r+e*e)*Math.sqrt(u*u+o*o),a=i&&(r*u+e*o)/i;return Math.acos(Math.min(Math.max(a,-1),1))}function No(t){return t[0]=0,t[1]=0,t}function Io(t){return"vec2("+t[0]+", "+t[1]+")"}function Fo(t,n){return t[0]===n[0]&&t[1]===n[1]}function $o(t,n){var r=t[0],e=t[1],u=n[0],o=n[1];return Math.abs(r-u)<=h*Math.max(1,Math.abs(r),Math.abs(u))&&Math.abs(e-o)<=h*Math.max(1,Math.abs(e),Math.abs(o))}var Bo=Eo,Wo=lo,Ho=ho,Uo=po,zo=Ao,Yo=So,Xo=_o,Qo=function(){var t=oo();return function(n,r,e,u,o,i){var a,c;for(r||(r=2),e||(e=0),c=u?Math.min(u*r+e,n.length):n.length,a=e;a<c;a+=r)t[0]=n[a],t[1]=n[a+1],o(t,t,i),n[a]=t[0],n[a+1]=t[1];return n}}()},function(t,n,r){"use strict";r.r(n),r.d(n,"DomInteraction",(function(){return o})),r.d(n,"SVGRenderer",(function(){return i})),r.d(n,"SVGPicker",(function(){return a})),r.d(n,"Renderer",(function(){return h}));var e=r(0),u=r(2),o=r(6),i=r(5),a=r(7),c=r(1),f=r(4),s=function(){function t(){}return t.prototype.init=function(){var t=this.canvasConfig.container;if(this.$container=Object(f.isString)(t)?document.getElementById(t):t,this.$container){this.$container.style.position||(this.$container.style.position="relative");var n=Object(i.createSVGElement)("svg");n.setAttribute("width",""+this.canvasConfig.width),n.setAttribute("height",""+this.canvasConfig.height),this.$container.appendChild(n),this.$namespace=n}var r=window.devicePixelRatio||1;r=r>=1?Math.ceil(r):1,this.dpr=r},t.prototype.getDomElement=function(){return this.$namespace},t.prototype.getContext=function(){return this.$namespace},t.prototype.getDPR=function(){return this.dpr},t.prototype.getBoundingClientRect=function(){var t;return null===(t=this.$namespace)||void 0===t?void 0:t.getBoundingClientRect()},t.prototype.destroy=function(){this.$container&&this.$namespace&&this.$namespace.parentNode&&this.$container.removeChild(this.$namespace)},t.prototype.resize=function(t,n){this.$namespace&&(this.$namespace.setAttribute("width",""+t),this.$namespace.setAttribute("height",""+n))},t.prototype.applyCursorStyle=function(t){this.$container&&(this.$container.style.cursor=t)},Object(e.__decorate)([Object(c.inject)(u.CanvasConfig),Object(e.__metadata)("design:type",Object)],t.prototype,"canvasConfig",void 0),t=Object(e.__decorate)([Object(c.singleton)({token:u.ContextService})],t)}(),d=Object(c.Module)((function(t){t(s)})),l=function(){function t(){}return t.prototype.init=function(t){t.load(d,!0)},t.prototype.destroy=function(t){t.remove(s)},t}(),h=function(t){function n(n){var r=t.call(this,n)||this;return r.registerPlugin(new l),r.registerPlugin(new i.Plugin),r.registerPlugin(new o.Plugin),r.registerPlugin(new a.Plugin),r}return Object(e.__extends)(n,t),n}(u.AbstractRenderer)}])}));
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { Module } from 'mana-syringe';
|
|
2
|
+
import { SVGContextService } from './SVGContextService';
|
|
3
|
+
var containerModule = Module(function (register) {
|
|
4
|
+
/**
|
|
5
|
+
* implements ContextService
|
|
6
|
+
*/
|
|
7
|
+
register(SVGContextService);
|
|
8
|
+
});
|
|
9
|
+
|
|
10
|
+
var ContextRegisterPlugin =
|
|
11
|
+
/** @class */
|
|
12
|
+
function () {
|
|
13
|
+
function ContextRegisterPlugin() {}
|
|
14
|
+
|
|
15
|
+
ContextRegisterPlugin.prototype.init = function (container) {
|
|
16
|
+
container.load(containerModule, true);
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
ContextRegisterPlugin.prototype.destroy = function (container) {
|
|
20
|
+
container.remove(SVGContextService); // @ts-ignore
|
|
21
|
+
// container.container.unload(containerModule);
|
|
22
|
+
// container.unload(containerModule);
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
return ContextRegisterPlugin;
|
|
26
|
+
}();
|
|
27
|
+
|
|
28
|
+
export { ContextRegisterPlugin };
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { ContextService } from '@antv/g';
|
|
2
|
-
export declare class SVGContextService implements ContextService<SVGElement> {
|
|
3
|
-
private $container;
|
|
4
|
-
private $namespace;
|
|
5
|
-
private dpr;
|
|
6
|
-
private canvasConfig;
|
|
7
|
-
init(): void;
|
|
8
|
-
getDomElement(): SVGElement
|
|
9
|
-
getContext(): SVGElement
|
|
10
|
-
getDPR(): number;
|
|
11
|
-
getBoundingClientRect(): DOMRect;
|
|
12
|
-
destroy(): void;
|
|
13
|
-
resize(width: number, height: number): void;
|
|
14
|
-
applyCursorStyle(cursor: string): void;
|
|
15
|
-
}
|
|
1
|
+
import { ContextService } from '@antv/g';
|
|
2
|
+
export declare class SVGContextService implements ContextService<SVGElement> {
|
|
3
|
+
private $container;
|
|
4
|
+
private $namespace;
|
|
5
|
+
private dpr;
|
|
6
|
+
private canvasConfig;
|
|
7
|
+
init(): void;
|
|
8
|
+
getDomElement(): SVGElement;
|
|
9
|
+
getContext(): SVGElement;
|
|
10
|
+
getDPR(): number;
|
|
11
|
+
getBoundingClientRect(): DOMRect;
|
|
12
|
+
destroy(): void;
|
|
13
|
+
resize(width: number, height: number): void;
|
|
14
|
+
applyCursorStyle(cursor: string): void;
|
|
15
|
+
}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { __decorate, __metadata } from "tslib";
|
|
2
|
+
import { CanvasConfig, ContextService } from '@antv/g';
|
|
3
|
+
import { inject, singleton } from 'mana-syringe';
|
|
4
|
+
import { isString } from '@antv/util';
|
|
5
|
+
import { createSVGElement } from '@antv/g-plugin-svg-renderer';
|
|
6
|
+
|
|
7
|
+
var SVGContextService =
|
|
8
|
+
/** @class */
|
|
9
|
+
function () {
|
|
10
|
+
function SVGContextService() {}
|
|
11
|
+
|
|
12
|
+
SVGContextService.prototype.init = function () {
|
|
13
|
+
var container = this.canvasConfig.container; // create container
|
|
14
|
+
|
|
15
|
+
this.$container = isString(container) ? document.getElementById(container) : container;
|
|
16
|
+
|
|
17
|
+
if (this.$container) {
|
|
18
|
+
if (!this.$container.style.position) {
|
|
19
|
+
this.$container.style.position = 'relative';
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
var $namespace = createSVGElement('svg');
|
|
23
|
+
$namespace.setAttribute('width', "" + this.canvasConfig.width);
|
|
24
|
+
$namespace.setAttribute('height', "" + this.canvasConfig.height);
|
|
25
|
+
this.$container.appendChild($namespace);
|
|
26
|
+
this.$namespace = $namespace;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
var dpr = window.devicePixelRatio || 1;
|
|
30
|
+
dpr = dpr >= 1 ? Math.ceil(dpr) : 1;
|
|
31
|
+
this.dpr = dpr;
|
|
32
|
+
}; // @ts-ignore
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
SVGContextService.prototype.getDomElement = function () {
|
|
36
|
+
return this.$namespace;
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
SVGContextService.prototype.getContext = function () {
|
|
40
|
+
return this.$namespace;
|
|
41
|
+
};
|
|
42
|
+
|
|
43
|
+
SVGContextService.prototype.getDPR = function () {
|
|
44
|
+
return this.dpr;
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
SVGContextService.prototype.getBoundingClientRect = function () {
|
|
48
|
+
var _a;
|
|
49
|
+
|
|
50
|
+
return (_a = this.$namespace) === null || _a === void 0 ? void 0 : _a.getBoundingClientRect();
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
SVGContextService.prototype.destroy = function () {
|
|
54
|
+
// destroy context
|
|
55
|
+
if (this.$container && this.$namespace && this.$namespace.parentNode) {
|
|
56
|
+
this.$container.removeChild(this.$namespace);
|
|
57
|
+
}
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
SVGContextService.prototype.resize = function (width, height) {
|
|
61
|
+
if (this.$namespace) {
|
|
62
|
+
this.$namespace.setAttribute('width', "" + width);
|
|
63
|
+
this.$namespace.setAttribute('height', "" + height);
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
|
|
67
|
+
SVGContextService.prototype.applyCursorStyle = function (cursor) {
|
|
68
|
+
if (this.$container) {
|
|
69
|
+
this.$container.style.cursor = cursor;
|
|
70
|
+
}
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
__decorate([inject(CanvasConfig), __metadata("design:type", Object)], SVGContextService.prototype, "canvasConfig", void 0);
|
|
74
|
+
|
|
75
|
+
SVGContextService = __decorate([singleton({
|
|
76
|
+
token: ContextService
|
|
77
|
+
})], SVGContextService);
|
|
78
|
+
return SVGContextService;
|
|
79
|
+
}();
|
|
80
|
+
|
|
81
|
+
export { SVGContextService };
|
package/es/index.d.ts
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { AbstractRenderer, RendererConfig } from '@antv/g';
|
|
2
|
+
import * as DomInteraction from '@antv/g-plugin-dom-interaction';
|
|
3
|
+
import * as SVGRenderer from '@antv/g-plugin-svg-renderer';
|
|
4
|
+
import * as SVGPicker from '@antv/g-plugin-svg-picker';
|
|
5
|
+
export { DomInteraction, SVGRenderer, SVGPicker };
|
|
6
|
+
export declare class Renderer extends AbstractRenderer {
|
|
7
|
+
constructor(config?: Partial<RendererConfig>);
|
|
8
|
+
}
|
package/es/index.js
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { __extends } from "tslib";
|
|
2
|
+
import { AbstractRenderer } from '@antv/g';
|
|
3
|
+
import * as DomInteraction from '@antv/g-plugin-dom-interaction';
|
|
4
|
+
import * as SVGRenderer from '@antv/g-plugin-svg-renderer';
|
|
5
|
+
import * as SVGPicker from '@antv/g-plugin-svg-picker';
|
|
6
|
+
import { ContextRegisterPlugin } from './ContextRegisterPlugin';
|
|
7
|
+
export { DomInteraction, SVGRenderer, SVGPicker };
|
|
8
|
+
|
|
9
|
+
var Renderer =
|
|
10
|
+
/** @class */
|
|
11
|
+
function (_super) {
|
|
12
|
+
__extends(Renderer, _super);
|
|
13
|
+
|
|
14
|
+
function Renderer(config) {
|
|
15
|
+
var _this = _super.call(this, config) || this;
|
|
16
|
+
|
|
17
|
+
_this.registerPlugin(new ContextRegisterPlugin());
|
|
18
|
+
|
|
19
|
+
_this.registerPlugin(new SVGRenderer.Plugin());
|
|
20
|
+
|
|
21
|
+
_this.registerPlugin(new DomInteraction.Plugin());
|
|
22
|
+
|
|
23
|
+
_this.registerPlugin(new SVGPicker.Plugin());
|
|
24
|
+
|
|
25
|
+
return _this;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
return Renderer;
|
|
29
|
+
}(AbstractRenderer);
|
|
30
|
+
|
|
31
|
+
export { Renderer };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export declare function parseRadius(radius: number[]): {
|
|
2
|
-
r1: number;
|
|
3
|
-
r2: number;
|
|
4
|
-
r3: number;
|
|
5
|
-
r4: number;
|
|
6
|
-
};
|
|
1
|
+
export declare function parseRadius(radius: number[]): {
|
|
2
|
+
r1: number;
|
|
3
|
+
r2: number;
|
|
4
|
+
r3: number;
|
|
5
|
+
r4: number;
|
|
6
|
+
};
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { isArray } from '@antv/util';
|
|
2
|
+
export function parseRadius(radius) {
|
|
3
|
+
var r1 = 0;
|
|
4
|
+
var r2 = 0;
|
|
5
|
+
var r3 = 0;
|
|
6
|
+
var r4 = 0;
|
|
7
|
+
|
|
8
|
+
if (isArray(radius)) {
|
|
9
|
+
if (radius.length === 1) {
|
|
10
|
+
r1 = r2 = r3 = r4 = radius[0];
|
|
11
|
+
} else if (radius.length === 2) {
|
|
12
|
+
r1 = r3 = radius[0];
|
|
13
|
+
r2 = r4 = radius[1];
|
|
14
|
+
} else if (radius.length === 3) {
|
|
15
|
+
r1 = radius[0];
|
|
16
|
+
r2 = r4 = radius[1];
|
|
17
|
+
r3 = radius[2];
|
|
18
|
+
} else {
|
|
19
|
+
r1 = radius[0];
|
|
20
|
+
r2 = radius[1];
|
|
21
|
+
r3 = radius[2];
|
|
22
|
+
r4 = radius[3];
|
|
23
|
+
}
|
|
24
|
+
} else {
|
|
25
|
+
r1 = r2 = r3 = r4 = radius;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
return {
|
|
29
|
+
r1: r1,
|
|
30
|
+
r2: r2,
|
|
31
|
+
r3: r3,
|
|
32
|
+
r4: r4
|
|
33
|
+
};
|
|
34
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.ContextRegisterPlugin = void 0;
|
|
7
|
+
|
|
8
|
+
var _manaSyringe = require("mana-syringe");
|
|
9
|
+
|
|
10
|
+
var _SVGContextService = require("./SVGContextService");
|
|
11
|
+
|
|
12
|
+
var containerModule = (0, _manaSyringe.Module)(function (register) {
|
|
13
|
+
/**
|
|
14
|
+
* implements ContextService
|
|
15
|
+
*/
|
|
16
|
+
register(_SVGContextService.SVGContextService);
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
var ContextRegisterPlugin =
|
|
20
|
+
/** @class */
|
|
21
|
+
function () {
|
|
22
|
+
function ContextRegisterPlugin() {}
|
|
23
|
+
|
|
24
|
+
ContextRegisterPlugin.prototype.init = function (container) {
|
|
25
|
+
container.load(containerModule, true);
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
ContextRegisterPlugin.prototype.destroy = function (container) {
|
|
29
|
+
container.remove(_SVGContextService.SVGContextService); // @ts-ignore
|
|
30
|
+
// container.container.unload(containerModule);
|
|
31
|
+
// container.unload(containerModule);
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
return ContextRegisterPlugin;
|
|
35
|
+
}();
|
|
36
|
+
|
|
37
|
+
exports.ContextRegisterPlugin = ContextRegisterPlugin;
|