6 lines
153 KiB
JavaScript
6 lines
153 KiB
JavaScript
|
/**
|
||
|
* Skipped minification because the original files appears to be already minified.
|
||
|
* Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files
|
||
|
*/
|
||
|
(function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):(e=e||self,t(e.canvg={}))})(this,function(e){'use strict';var ge=Math.tan,ce=Math.atan2,pe=Math.PI,ye=Math.round,he=String.prototype,fe=Math.max,me=Math.min,xe=Math.ceil,be=Math.sin,ve=Math.cos,ke=Math.floor,Se=Math.sqrt,Pe=Math.pow;function t(e,t){return t={exports:{}},e(t,t.exports),t.exports}function n(e){return e.replace(/(?!\u3000)\s+/gm," ")}function a(e){return e.replace(/^[\n \t]+/,"")}function r(e){return e.replace(/[\n \t]+$/,"")}function o(e){var t=(e||"").match(/-?(\d+(?:\.\d*(?:[eE][+-]?\d+)?)?|\.\d+)(?=\D|$)/gm)||[];return t.map(parseFloat)}function l(e){return ra.test(e)?e.toLowerCase():e}function s(e){var t=e.match(/url\(('([^']+)'|"([^"]+)"|([^'"\)]+))\)/)||[];return t[2]||t[3]||t[4]}function d(e,t){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e)){var n=[],a=!0,r=!1,i=void 0;try{for(var o=e[Symbol.iterator](),l;!(a=(l=o.next()).done)&&(n.push(l.value),!(t&&n.length===t));a=!0);}catch(e){r=!0,i=e}finally{try{a||null==o["return"]||o["return"]()}finally{if(r)throw i}}return n}}function u(e,t){return da(e)||ua(e,t)||ga()}function g(e,t){var n=e.match(t);return n?[e.replace(t," "),n.length]:[e,0]}function p(e){var t=[0,0,0],n=e.replace(/:not\(([^\)]*)\)/g," $1 ").replace(/{[\s\S]*/gm," "),a=0,r=g(n,pa),i=ca(r,2);n=i[0],a=i[1],t[1]+=a;var o=g(n,ya),l=ca(o,2);n=l[0],a=l[1],t[0]+=a;var s=g(n,ha),d=ca(s,2);n=d[0],a=d[1],t[1]+=a;var u=g(n,fa),c=ca(u,2);n=c[0],a=c[1],t[2]+=a;var p=g(n,ma),y=ca(p,2);n=y[0],a=y[1],t[1]+=a;var h=g(n,xa),f=ca(h,2);n=f[0],a=f[1],t[1]+=a,n=n.replace(/[\*\s\+>~]/g," ").replace(/[#\.]/g," ");var m=g(n,ba),x=ca(m,2);return n=x[0],a=x[1],t[2]+=a,t.join("")}function y(e){return Se(Pe(e[0],2)+Pe(e[1],2))}function h(e,t){return(e[0]*t[0]+e[1]*t[1])/(y(e)*y(t))}function x(e,t){var n=Math.acos;return(e[0]*t[1]<e[1]*t[0]?-1:1)*n(h(e,t))}function b(e){return e*e*e}function v(e){return 3*e*e*(1-e)}function k(e){return 3*e*(1-e)*(1-e)}function S(e){return(1-e)*(1-e)*(1-e)}function P(e){return e*e}function A(e){return 2*e*(1-e)}function E(e){return(1-e)*(1-e)}function T(e,t,n,a,r,i,o){try{var l=e[i](o),s=l.value}catch(e){return void n(e)}l.done?t(s):Promise.resolve(s).then(a,r)}function C(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function w(e,t){for(var n=0,a;n<t.length;n++)a=t[n],a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}function O(){throw new Error("setTimeout has not been defined")}function V(){throw new Error("clearTimeout has not been defined")}function L(t){if(Jo===setTimeout)return setTimeout(t,0);if((Jo===O||!Jo)&&setTimeout)return Jo=setTimeout,setTimeout(t,0);try{return Jo(t,0)}catch(n){try{return Jo.call(null,t,0)}catch(n){return Jo.call(this,t,0)}}}function R(t){if(el===clearTimeout)return clearTimeout(t);if((el===V||!el)&&clearTimeout)return el=clearTimeout,clearTimeout(t);try{return el(t)}catch(n){try{return el.call(null,t)}catch(n){return el.call(this,t)}}}function I(){nl&&rl&&(nl=!1,rl.length?tl=rl.concat(tl):al=-1,tl.length&&D())}function D(){if(!nl){var e=L(I);nl=!0;for(var t=tl.length;t;){for(rl=tl,tl=[];++al<t;)rl&&rl[al].run();al=-1,t=tl.length}rl=null,nl=!1,R(e)}}function N(e){var t=Array(arguments.length-1);if(1<arguments.length)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];tl.push(new M(e,t)),1!==tl.length||nl||L(D)}function M(e,t){this.fun=e,this.array=t}function z(){}function B(){throw new Error("process.binding is not supported")}function _(){return"/"}function F(){throw new Error("process.chdir is not supported")}function G(){return 0}function H(e){var t=1e-3*gl.call(ul),n=ke(t),a=ke(1e9*(t%1));return e&&(n-=e[0],a-=e[1],0>a&&(n--,a+=1e9)),[n,a]}function Y(){var e=new Date;return(e-cl)/1e3}function $(e){var t=e.trim();return /^('|")/.test(t)?t:"\"".concat(t,"\"")}function U(e){return"undefined"==typeof process?e:e.trim().split(",").map($).join(",")}f
|
||
|
//# sourceMappingURL=umd.js.map
|