Your IP : 18.116.88.132


Current Path : /var/www/www-root/data/www/www.monolith-realty.ru/bitrix/js/ui/progressbarjs/
Upload File :
Current File : /var/www/www-root/data/www/www.monolith-realty.ru/bitrix/js/ui/progressbarjs/progressbar.min.js

(function(t){if(typeof window.BX==="undefined"){window.BX={}}window.BX.ProgressBarJs=t()})(function(){var t,e,r;return function(){function t(e,r,n){function i(a,u){if(!r[a]){if(!e[a]){var s="function"==typeof require&&require;if(!u&&s)return s(a,!0);if(o)return o(a,!0);var f=new Error("Cannot find module '"+a+"'");throw f.code="MODULE_NOT_FOUND",f}var c=r[a]={exports:{}};e[a][0].call(c.exports,function(t){var r=e[a][1][t];return i(r||t)},c,c.exports,t,e,r,n)}return r[a].exports}for(var o="function"==typeof require&&require,a=0;a<n.length;a++)i(n[a]);return i}return t}()({1:[function(e,r,n){!function(e,i){"object"==typeof n&&"object"==typeof r?r.exports=i():"function"==typeof t&&t.amd?t("shifty",[],i):"object"==typeof n?n.shifty=i():e.shifty=i()}(window,function(){return function(t){var e={};function r(n){if(e[n])return e[n].exports;var i=e[n]={i:n,l:!1,exports:{}};return t[n].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=t,r.c=e,r.d=function(t,e,n){r.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},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,e){if(1&e&&(t=r(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)r.d(n,i,function(e){return t[e]}.bind(null,i));return n},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="",r(r.s=3)}([function(t,e,r){"use strict";(function(t){r.d(e,"e",function(){return d}),r.d(e,"c",function(){return y}),r.d(e,"b",function(){return _}),r.d(e,"a",function(){return w}),r.d(e,"d",function(){return m});var n=r(1);function i(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function o(t){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function a(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable}))),n.forEach(function(e){u(t,e,r[e])})}return t}function u(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var s="undefined"!=typeof window?window:t,f=s.requestAnimationFrame||s.webkitRequestAnimationFrame||s.oRequestAnimationFrame||s.msRequestAnimationFrame||s.mozCancelRequestAnimationFrame&&s.mozRequestAnimationFrame||setTimeout,c=function(){},h=null,l=null,p=a({},n),d=function(t,e,r,n,i,o,a){var u=t<o?0:(t-o)/i;for(var s in e){var f=a[s],c=f.call?f:p[f],h=r[s];e[s]=h+(n[s]-h)*c(u)}return e},v=function(t,e){var r=t._attachment,n=t._currentState,i=t._delay,o=t._easing,a=t._originalState,u=t._duration,s=t._step,f=t._targetState,c=t._timestamp,h=c+i+u,l=e>h?h:e,p=u-(h-l);l>=h?(s(f,r,p),t.stop(!0)):(t._applyFilter("beforeTween"),l<c+i?(l=1,u=1,c=1):c+=i,d(l,n,a,f,u,c,o),t._applyFilter("afterTween"),s(n,r,p))},y=function(){for(var t=w.now(),e=h;e;){var r=e._next;v(e,t),e=r}},_=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"linear",r={},n=o(e);if("string"===n||"function"===n)for(var i in t)r[i]=e;else for(var a in t)r[a]=e[a]||"linear";return r},g=function(t){if(t===h)(h=t._next)?h._previous=null:l=null;else if(t===l)(l=t._previous)?l._next=null:h=null;else{var e=t._previous,r=t._next;e._next=r,r._previous=e}t._previous=t._next=null},w=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this._currentState=e,this._configured=!1,this._filters=[],this._timestamp=null,this._next=null,this._previous=null,r&&this.setConfig(r)}var e,r,n;return e=t,(r=[{key:"_applyFilter",value:function(t){var e=!0,r=!1,n=void 0;try{for(var i,o=this._filters[Symbol.iterator]();!(e=(i=o.next()).done);e=!0){var a=i.value[t];a&&a(this)}}catch(t){r=!0,n=t}finally{try{e||null==o.return||o.return()}finally{if(r)throw n}}}},{key:"tween",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0,r=this._attachment,n=this._configured;return!e&&n||this.setConfig(e),this._pausedAtTime=null,this._timestamp=t.now(),this._start(this.get(),r),this.resume()}},{key:"setConfig",value:function(){var e=this,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=r.attachment,i=r.delay,o=void 0===i?0:i,u=r.duration,s=void 0===u?500:u,f=r.easing,h=r.from,l=r.promise,p=void 0===l?Promise:l,d=r.start,v=void 0===d?c:d,y=r.step,g=void 0===y?c:y,w=r.to;this._configured=!0,this._attachment=n,this._isPlaying=!1,this._pausedAtTime=null,this._scheduleId=null,this._delay=o,this._start=v,this._step=g,this._duration=s,this._currentState=a({},h||this.get()),this._originalState=this.get(),this._targetState=a({},w||this.get());var m=this._currentState;this._targetState=a({},m,this._targetState),this._easing=_(m,f);var b=t.filters;for(var S in this._filters.length=0,b)b[S].doesApply(this)&&this._filters.push(b[S]);return this._applyFilter("tweenCreated"),this._promise=new p(function(t,r){e._resolve=t,e._reject=r}),this._promise.catch(c),this}},{key:"get",value:function(){return a({},this._currentState)}},{key:"set",value:function(t){this._currentState=t}},{key:"pause",value:function(){if(this._isPlaying)return this._pausedAtTime=t.now(),this._isPlaying=!1,g(this),this}},{key:"resume",value:function(){if(null===this._timestamp)return this.tween();if(this._isPlaying)return this._promise;var e=t.now();return this._pausedAtTime&&(this._timestamp+=e-this._pausedAtTime,this._pausedAtTime=null),this._isPlaying=!0,null===h?(h=this,l=this,function t(){h&&(f.call(s,t,1e3/60),y())}()):(this._previous=l,l._next=this,l=this),this._promise}},{key:"seek",value:function(e){e=Math.max(e,0);var r=t.now();return this._timestamp+e===0?this:(this._timestamp=r-e,this._isPlaying||v(this,r),this)}},{key:"stop",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],e=this._attachment,r=this._currentState,n=this._easing,i=this._originalState,o=this._targetState;if(this._isPlaying)return this._isPlaying=!1,g(this),t?(this._applyFilter("beforeTween"),d(1,r,i,o,1,0,n),this._applyFilter("afterTween"),this._applyFilter("afterTweenEnd"),this._resolve(r,e)):this._reject(r,e),this}},{key:"isPlaying",value:function(){return this._isPlaying}},{key:"setScheduleFunction",value:function(e){t.setScheduleFunction(e)}},{key:"dispose",value:function(){for(var t in this)delete this[t]}}])&&i(e.prototype,r),n&&i(e,n),t}();function m(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=new w,r=e.tween(t);return r.tweenable=e,r}w.setScheduleFunction=function(t){return f=t},w.formulas=p,w.filters={},w.now=Date.now||function(){return+new Date}}).call(this,r(2))},function(t,e,r){"use strict";r.r(e),r.d(e,"linear",function(){return n}),r.d(e,"easeInQuad",function(){return i}),r.d(e,"easeOutQuad",function(){return o}),r.d(e,"easeInOutQuad",function(){return a}),r.d(e,"easeInCubic",function(){return u}),r.d(e,"easeOutCubic",function(){return s}),r.d(e,"easeInOutCubic",function(){return f}),r.d(e,"easeInQuart",function(){return c}),r.d(e,"easeOutQuart",function(){return h}),r.d(e,"easeInOutQuart",function(){return l}),r.d(e,"easeInQuint",function(){return p}),r.d(e,"easeOutQuint",function(){return d}),r.d(e,"easeInOutQuint",function(){return v}),r.d(e,"easeInSine",function(){return y}),r.d(e,"easeOutSine",function(){return _}),r.d(e,"easeInOutSine",function(){return g}),r.d(e,"easeInExpo",function(){return w}),r.d(e,"easeOutExpo",function(){return m}),r.d(e,"easeInOutExpo",function(){return b}),r.d(e,"easeInCirc",function(){return S}),r.d(e,"easeOutCirc",function(){return O}),r.d(e,"easeInOutCirc",function(){return x}),r.d(e,"easeOutBounce",function(){return k}),r.d(e,"easeInBack",function(){return P}),r.d(e,"easeOutBack",function(){return T}),r.d(e,"easeInOutBack",function(){return C}),r.d(e,"elastic",function(){return M}),r.d(e,"swingFromTo",function(){return E}),r.d(e,"swingFrom",function(){return A}),r.d(e,"swingTo",function(){return j}),r.d(e,"bounce",function(){return F}),r.d(e,"bouncePast",function(){return W}),r.d(e,"easeFromTo",function(){return I}),r.d(e,"easeFrom",function(){return q}),r.d(e,"easeTo",function(){return L});var n=function(t){return t},i=function(t){return Math.pow(t,2)},o=function(t){return-(Math.pow(t-1,2)-1)},a=function(t){return(t/=.5)<1?.5*Math.pow(t,2):-.5*((t-=2)*t-2)},u=function(t){return Math.pow(t,3)},s=function(t){return Math.pow(t-1,3)+1},f=function(t){return(t/=.5)<1?.5*Math.pow(t,3):.5*(Math.pow(t-2,3)+2)},c=function(t){return Math.pow(t,4)},h=function(t){return-(Math.pow(t-1,4)-1)},l=function(t){return(t/=.5)<1?.5*Math.pow(t,4):-.5*((t-=2)*Math.pow(t,3)-2)},p=function(t){return Math.pow(t,5)},d=function(t){return Math.pow(t-1,5)+1},v=function(t){return(t/=.5)<1?.5*Math.pow(t,5):.5*(Math.pow(t-2,5)+2)},y=function(t){return 1-Math.cos(t*(Math.PI/2))},_=function(t){return Math.sin(t*(Math.PI/2))},g=function(t){return-.5*(Math.cos(Math.PI*t)-1)},w=function(t){return 0===t?0:Math.pow(2,10*(t-1))},m=function(t){return 1===t?1:1-Math.pow(2,-10*t)},b=function(t){return 0===t?0:1===t?1:(t/=.5)<1?.5*Math.pow(2,10*(t-1)):.5*(2-Math.pow(2,-10*--t))},S=function(t){return-(Math.sqrt(1-t*t)-1)},O=function(t){return Math.sqrt(1-Math.pow(t-1,2))},x=function(t){return(t/=.5)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1)},k=function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},P=function(t){var e=1.70158;return t*t*((e+1)*t-e)},T=function(t){var e=1.70158;return(t-=1)*t*((e+1)*t+e)+1},C=function(t){var e=1.70158;return(t/=.5)<1?t*t*((1+(e*=1.525))*t-e)*.5:.5*((t-=2)*t*((1+(e*=1.525))*t+e)+2)},M=function(t){return-1*Math.pow(4,-8*t)*Math.sin((6*t-1)*(2*Math.PI)/2)+1},E=function(t){var e=1.70158;return(t/=.5)<1?t*t*((1+(e*=1.525))*t-e)*.5:.5*((t-=2)*t*((1+(e*=1.525))*t+e)+2)},A=function(t){var e=1.70158;return t*t*((e+1)*t-e)},j=function(t){var e=1.70158;return(t-=1)*t*((e+1)*t+e)+1},F=function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},W=function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?2-(7.5625*(t-=1.5/2.75)*t+.75):t<2.5/2.75?2-(7.5625*(t-=2.25/2.75)*t+.9375):2-(7.5625*(t-=2.625/2.75)*t+.984375)},I=function(t){return(t/=.5)<1?.5*Math.pow(t,4):-.5*((t-=2)*Math.pow(t,3)-2)},q=function(t){return Math.pow(t,4)},L=function(t){return Math.pow(t,.25)}},function(t,e){var r;r=function(){return this}();try{r=r||new Function("return this")()}catch(t){"object"==typeof window&&(r=window)}t.exports=r},function(t,e,r){"use strict";r.r(e);var n={};r.r(n),r.d(n,"doesApply",function(){return C}),r.d(n,"tweenCreated",function(){return M}),r.d(n,"beforeTween",function(){return E}),r.d(n,"afterTween",function(){return A});var i,o,a=r(0),u=/(\d|-|\.)/,s=/([^\-0-9.]+)/g,f=/[0-9.-]+/g,c=(i=f.source,o=/,\s*/.source,new RegExp("rgb\\(".concat(i).concat(o).concat(i).concat(o).concat(i,"\\)"),"g")),h=/^.*\(/,l=/#([0-9]|[a-f]){3,6}/gi,p=function(t,e){return t.map(function(t,r){return"_".concat(e,"_").concat(r)})};function d(t){return parseInt(t,16)}var v=function(t){return"rgb(".concat((e=t,3===(e=e.replace(/#/,"")).length&&(e=(e=e.split(""))[0]+e[0]+e[1]+e[1]+e[2]+e[2]),[d(e.substr(0,2)),d(e.substr(2,2)),d(e.substr(4,2))]).join(","),")");var e},y=function(t,e,r){var n=e.match(t),i=e.replace(t,"VAL");return n&&n.forEach(function(t){return i=i.replace("VAL",r(t))}),i},_=function(t){for(var e in t){var r=t[e];"string"==typeof r&&r.match(l)&&(t[e]=y(l,r,v))}},g=function(t){var e=t.match(f).map(Math.floor),r=t.match(h)[0];return"".concat(r).concat(e.join(","),")")},w=function(t){return t.match(f)},m=function(t){var e,r,n={};for(var i in t){var o=t[i];"string"==typeof o&&(n[i]={formatString:(e=o,r=void 0,r=e.match(s),r?(1===r.length||e.charAt(0).match(u))&&r.unshift(""):r=["",""],r.join("VAL")),chunkNames:p(w(o),i)})}return n},b=function(t,e){var r=function(r){w(t[r]).forEach(function(n,i){return t[e[r].chunkNames[i]]=+n}),delete t[r]};for(var n in e)r(n)},S=function(t,e){var r={};return e.forEach(function(e){r[e]=t[e],delete t[e]}),r},O=function(t,e){return e.map(function(e){return t[e]})},x=function(t,e){return e.forEach(function(e){return t=t.replace("VAL",+e.toFixed(4))}),t},k=function(t,e){for(var r in e){var n=e[r],i=n.chunkNames,o=n.formatString,a=x(o,O(S(t,i),i));t[r]=y(c,a,g)}},P=function(t,e){var r=function(r){var n=e[r].chunkNames,i=t[r];if("string"==typeof i){var o=i.split(" "),a=o[o.length-1];n.forEach(function(e,r){return t[e]=o[r]||a})}else n.forEach(function(e){return t[e]=i});delete t[r]};for(var n in e)r(n)},T=function(t,e){for(var r in e){var n=e[r].chunkNames,i=t[n[0]];t[r]="string"==typeof i?n.map(function(e){var r=t[e];return delete t[e],r}).join(" "):i}},C=function(t){var e=t._currentState;return Object.keys(e).some(function(t){return"string"==typeof e[t]})};function M(t){var e=t._currentState;[e,t._originalState,t._targetState].forEach(_),t._tokenData=m(e)}function E(t){var e=t._currentState,r=t._originalState,n=t._targetState,i=t._easing,o=t._tokenData;P(i,o),[e,r,n].forEach(function(t){return b(t,o)})}function A(t){var e=t._currentState,r=t._originalState,n=t._targetState,i=t._easing,o=t._tokenData;[e,r,n].forEach(function(t){return k(t,o)}),T(i,o)}function j(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var F=new a.a,W=a.a.filters,I=function(t,e,r,n){var i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,o=function(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{},n=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(r).filter(function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable}))),n.forEach(function(e){j(t,e,r[e])})}return t}({},t),u=Object(a.b)(t,n);for(var s in F._filters.length=0,F.set({}),F._currentState=o,F._originalState=t,F._targetState=e,F._easing=u,W)W[s].doesApply(F)&&F._filters.push(W[s]);F._applyFilter("tweenCreated"),F._applyFilter("beforeTween");var f=Object(a.e)(r,o,t,e,1,i,u);return F._applyFilter("afterTween"),f};function q(t){return function(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e<t.length;e++)r[e]=t[e];return r}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function L(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function D(t,e){if(!e.has(t))throw new TypeError("attempted to get private field on non-instance");var r=e.get(t);return r.get?r.get.call(t):r.value}var B=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),R.set(this,{writable:!0,value:[]});for(var e=arguments.length,r=new Array(e),n=0;n<e;n++)r[n]=arguments[n];r.forEach(this.add.bind(this))}var e,r,n;return e=t,(r=[{key:"add",value:function(t){return D(this,R).push(t),t}},{key:"remove",value:function(t){var e=D(this,R).indexOf(t);return~e&&D(this,R).splice(e,1),t}},{key:"empty",value:function(){return this.tweenables.map(this.remove.bind(this))}},{key:"isPlaying",value:function(){return D(this,R).some(function(t){return t.isPlaying()})}},{key:"play",value:function(){return D(this,R).forEach(function(t){return t.tween()}),this}},{key:"pause",value:function(){return D(this,R).forEach(function(t){return t.pause()}),this}},{key:"resume",value:function(){return D(this,R).forEach(function(t){return t.resume()}),this}},{key:"stop",value:function(t){return D(this,R).forEach(function(e){return e.stop(t)}),this}},{key:"tweenables",get:function(){return q(D(this,R))}},{key:"promises",get:function(){return D(this,R).map(function(t){return t._promise})}}])&&L(e.prototype,r),n&&L(e,n),t}(),R=new WeakMap;function N(t,e,r,n,i,o){var a=0,u=0,s=0,f=0,c=0,h=0,l=function(t){return((a*t+u)*t+s)*t},p=function(t){return t>=0?t:0-t};return a=1-(s=3*e)-(u=3*(n-e)-s),f=1-(h=3*r)-(c=3*(i-r)-h),function(t,e){return r=function(t,e){var r,n,i,o,f,c,h;for(i=t,c=0;c<8;c++){if(o=l(i)-t,p(o)<e)return i;if(p(f=(3*a*(h=i)+2*u)*h+s)<1e-6)break;i-=o/f}if((i=t)<(r=0))return r;if(i>(n=1))return n;for(;r<n;){if(o=l(i),p(o-t)<e)return i;t>o?r=i:n=i,i=.5*(n-r)+r}return i}(t,e),((f*r+c)*r+h)*r;var r}(t,function(t){return 1/(200*t)}(o))}var z=function(t,e,r,n,i){var o=function(t,e,r,n){return function(i){return N(i,t,e,r,n,1)}}(e,r,n,i);return o.displayName=t,o.x1=e,o.y1=r,o.x2=n,o.y2=i,a.a.formulas[t]=o},V=function(t){return delete a.a.formulas[t]};r.d(e,"processTweens",function(){return a.c}),r.d(e,"Tweenable",function(){return a.a}),r.d(e,"tween",function(){return a.d}),r.d(e,"interpolate",function(){return I}),r.d(e,"Scene",function(){return B}),r.d(e,"setBezierFunction",function(){return z}),r.d(e,"unsetBezierFunction",function(){return V}),a.a.filters.token=n}])})},{}],2:[function(t,e,r){var n=t("./shape");var i=t("./utils");var o=function t(e,r){this._pathTemplate="M 50,50 m 0,-{radius}"+" a {radius},{radius} 0 1 1 0,{2radius}"+" a {radius},{radius} 0 1 1 0,-{2radius}";this.containerAspectRatio=1;n.apply(this,arguments)};o.prototype=new n;o.prototype.constructor=o;o.prototype._pathString=function t(e){var r=e.strokeWidth;if(e.trailWidth&&e.trailWidth>e.strokeWidth){r=e.trailWidth}var n=50-r/2;return i.render(this._pathTemplate,{radius:n,"2radius":n*2})};o.prototype._trailString=function t(e){return this._pathString(e)};e.exports=o},{"./shape":7,"./utils":9}],3:[function(t,e,r){var n=t("./shape");var i=t("./utils");var o=function t(e,r){this._pathTemplate="M 0,{center} L 100,{center}";n.apply(this,arguments)};o.prototype=new n;o.prototype.constructor=o;o.prototype._initializeSvg=function t(e,r){e.setAttribute("viewBox","0 0 100 "+r.strokeWidth);e.setAttribute("preserveAspectRatio","none")};o.prototype._pathString=function t(e){return i.render(this._pathTemplate,{center:e.strokeWidth/2})};o.prototype._trailString=function t(e){return this._pathString(e)};e.exports=o},{"./shape":7,"./utils":9}],4:[function(t,e,r){e.exports={Line:t("./line"),Circle:t("./circle"),SemiCircle:t("./semicircle"),Square:t("./square"),Path:t("./path"),Shape:t("./shape"),utils:t("./utils")}},{"./circle":2,"./line":3,"./path":5,"./semicircle":6,"./shape":7,"./square":8,"./utils":9}],5:[function(t,e,r){var n=t("shifty");var i=t("./utils");var o=n.Tweenable;var a={easeIn:"easeInCubic",easeOut:"easeOutCubic",easeInOut:"easeInOutCubic"};var u=function t(e,r){if(!(this instanceof t)){throw new Error("Constructor was called without new keyword")}r=i.extend({delay:0,duration:800,easing:"linear",from:{},to:{},step:function(){}},r);var n;if(i.isString(e)){n=document.querySelector(e)}else{n=e}this.path=n;this._opts=r;this._tweenable=null;var o=this.path.getTotalLength();this.path.style.strokeDasharray=o+" "+o;this.set(0)};u.prototype.value=function t(){var e=this._getComputedDashOffset();var r=this.path.getTotalLength();var n=1-e/r;return parseFloat(n.toFixed(6),10)};u.prototype.set=function t(e){this.stop();this.path.style.strokeDashoffset=this._progressToOffset(e);var r=this._opts.step;if(i.isFunction(r)){var n=this._easing(this._opts.easing);var o=this._calculateTo(e,n);var a=this._opts.shape||this;r(o,a,this._opts.attachment)}};u.prototype.stop=function t(){this._stopTween();this.path.style.strokeDashoffset=this._getComputedDashOffset()};u.prototype.animate=function t(e,r,n){r=r||{};if(i.isFunction(r)){n=r;r={}}var a=i.extend({},r);var u=i.extend({},this._opts);r=i.extend(u,r);var s=this._easing(r.easing);var f=this._resolveFromAndTo(e,s,a);this.stop();this.path.getBoundingClientRect();var c=this._getComputedDashOffset();var h=this._progressToOffset(e);var l=this;this._tweenable=new o;this._tweenable.tween({from:i.extend({offset:c},f.from),to:i.extend({offset:h},f.to),duration:r.duration,delay:r.delay,easing:s,step:function(t){l.path.style.strokeDashoffset=t.offset;var e=r.shape||l;r.step(t,e,r.attachment)}}).then(function(t){if(i.isFunction(n)){n()}}).catch(function(t){})};u.prototype._getComputedDashOffset=function t(){var e=window.getComputedStyle(this.path,null);var r=e.getPropertyValue("stroke-dashoffset");return r?parseFloat(r,10):0};u.prototype._progressToOffset=function t(e){var r=this.path.getTotalLength();return r-e*r};u.prototype._resolveFromAndTo=function t(e,r,n){if(n.from&&n.to){return{from:n.from,to:n.to}}return{from:this._calculateFrom(r),to:this._calculateTo(e,r)}};u.prototype._calculateFrom=function t(e){return n.interpolate(this._opts.from,this._opts.to,this.value(),e)};u.prototype._calculateTo=function t(e,r){return n.interpolate(this._opts.from,this._opts.to,e,r)};u.prototype._stopTween=function t(){if(this._tweenable!==null){this._tweenable.stop();this._tweenable=null}};u.prototype._easing=function t(e){if(a.hasOwnProperty(e)){return a[e]}return e};e.exports=u},{"./utils":9,shifty:1}],6:[function(t,e,r){var n=t("./shape");var i=t("./circle");var o=t("./utils");var a=function t(e,r){this._pathTemplate="M 50,50 m -{radius},0"+" a {radius},{radius} 0 1 1 {2radius},0";this.containerAspectRatio=2;n.apply(this,arguments)};a.prototype=new n;a.prototype.constructor=a;a.prototype._initializeSvg=function t(e,r){e.setAttribute("viewBox","0 0 100 50")};a.prototype._initializeTextContainer=function t(e,r,n){if(e.text.style){n.style.top="auto";n.style.bottom="0";if(e.text.alignToBottom){o.setStyle(n,"transform","translate(-50%, 0)")}else{o.setStyle(n,"transform","translate(-50%, 50%)")}}};a.prototype._pathString=i.prototype._pathString;a.prototype._trailString=i.prototype._trailString;e.exports=a},{"./circle":2,"./shape":7,"./utils":9}],7:[function(t,e,r){var n=t("./path");var i=t("./utils");var o="Object is destroyed";var a=function t(e,r){if(!(this instanceof t)){throw new Error("Constructor was called without new keyword")}if(arguments.length===0){return}this._opts=i.extend({color:"#555",strokeWidth:1,trailColor:null,trailWidth:null,fill:null,text:{style:{color:null,position:"absolute",left:"50%",top:"50%",padding:0,margin:0,transform:{prefix:true,value:"translate(-50%, -50%)"}},autoStyleContainer:true,alignToBottom:true,value:null,className:"progressbar-text"},svgStyle:{display:"block",width:"100%"},warnings:false},r,true);if(i.isObject(r)&&r.svgStyle!==undefined){this._opts.svgStyle=r.svgStyle}if(i.isObject(r)&&i.isObject(r.text)&&r.text.style!==undefined){this._opts.text.style=r.text.style}var o=this._createSvgView(this._opts);var a;if(i.isString(e)){a=document.querySelector(e)}else{a=e}if(!a){throw new Error("Container does not exist: "+e)}this._container=a;this._container.appendChild(o.svg);if(this._opts.warnings){this._warnContainerAspectRatio(this._container)}if(this._opts.svgStyle){i.setStyles(o.svg,this._opts.svgStyle)}this.svg=o.svg;this.path=o.path;this.trail=o.trail;this.text=null;var u=i.extend({attachment:undefined,shape:this},this._opts);this._progressPath=new n(o.path,u);if(i.isObject(this._opts.text)&&this._opts.text.value!==null){this.setText(this._opts.text.value)}};a.prototype.animate=function t(e,r,n){if(this._progressPath===null){throw new Error(o)}this._progressPath.animate(e,r,n)};a.prototype.stop=function t(){if(this._progressPath===null){throw new Error(o)}if(this._progressPath===undefined){return}this._progressPath.stop()};a.prototype.pause=function t(){if(this._progressPath===null){throw new Error(o)}if(this._progressPath===undefined){return}if(!this._progressPath._tweenable){return}this._progressPath._tweenable.pause()};a.prototype.resume=function t(){if(this._progressPath===null){throw new Error(o)}if(this._progressPath===undefined){return}if(!this._progressPath._tweenable){return}this._progressPath._tweenable.resume()};a.prototype.destroy=function t(){if(this._progressPath===null){throw new Error(o)}this.stop();this.svg.parentNode.removeChild(this.svg);this.svg=null;this.path=null;this.trail=null;this._progressPath=null;if(this.text!==null){this.text.parentNode.removeChild(this.text);this.text=null}};a.prototype.set=function t(e){if(this._progressPath===null){throw new Error(o)}this._progressPath.set(e)};a.prototype.value=function t(){if(this._progressPath===null){throw new Error(o)}if(this._progressPath===undefined){return 0}return this._progressPath.value()};a.prototype.setText=function t(e){if(this._progressPath===null){throw new Error(o)}if(this.text===null){this.text=this._createTextContainer(this._opts,this._container);this._container.appendChild(this.text)}if(i.isObject(e)){i.removeChildren(this.text);this.text.appendChild(e)}else{this.text.innerHTML=e}};a.prototype._createSvgView=function t(e){var r=document.createElementNS("http://www.w3.org/2000/svg","svg");this._initializeSvg(r,e);var n=null;if(e.trailColor||e.trailWidth){n=this._createTrail(e);r.appendChild(n)}var i=this._createPath(e);r.appendChild(i);return{svg:r,path:i,trail:n}};a.prototype._initializeSvg=function t(e,r){e.setAttribute("viewBox","0 0 100 100")};a.prototype._createPath=function t(e){var r=this._pathString(e);return this._createPathElement(r,e)};a.prototype._createTrail=function t(e){var r=this._trailString(e);var n=i.extend({},e);if(!n.trailColor){n.trailColor="#eee"}if(!n.trailWidth){n.trailWidth=n.strokeWidth}n.color=n.trailColor;n.strokeWidth=n.trailWidth;n.fill=null;return this._createPathElement(r,n)};a.prototype._createPathElement=function t(e,r){var n=document.createElementNS("http://www.w3.org/2000/svg","path");n.setAttribute("d",e);n.setAttribute("stroke",r.color);n.setAttribute("stroke-width",r.strokeWidth);if(r.fill){n.setAttribute("fill",r.fill)}else{n.setAttribute("fill-opacity","0")}return n};a.prototype._createTextContainer=function t(e,r){var n=document.createElement("div");n.className=e.text.className;var o=e.text.style;if(o){if(e.text.autoStyleContainer){r.style.position="relative"}i.setStyles(n,o);if(!o.color){n.style.color=e.color}}this._initializeTextContainer(e,r,n);return n};a.prototype._initializeTextContainer=function(t,e,r){};a.prototype._pathString=function t(e){throw new Error("Override this function for each progress bar")};a.prototype._trailString=function t(e){throw new Error("Override this function for each progress bar")};a.prototype._warnContainerAspectRatio=function t(e){if(!this.containerAspectRatio){return}var r=window.getComputedStyle(e,null);var n=parseFloat(r.getPropertyValue("width"),10);var o=parseFloat(r.getPropertyValue("height"),10);if(!i.floatEquals(this.containerAspectRatio,n/o)){console.warn("Incorrect aspect ratio of container","#"+e.id,"detected:",r.getPropertyValue("width")+"(width)","/",r.getPropertyValue("height")+"(height)","=",n/o);console.warn("Aspect ratio of should be",this.containerAspectRatio)}};e.exports=a},{"./path":5,"./utils":9}],8:[function(t,e,r){var n=t("./shape");var i=t("./utils");var o=function t(e,r){this._pathTemplate="M 0,{halfOfStrokeWidth}"+" L {width},{halfOfStrokeWidth}"+" L {width},{width}"+" L {halfOfStrokeWidth},{width}"+" L {halfOfStrokeWidth},{strokeWidth}";this._trailTemplate="M {startMargin},{halfOfStrokeWidth}"+" L {width},{halfOfStrokeWidth}"+" L {width},{width}"+" L {halfOfStrokeWidth},{width}"+" L {halfOfStrokeWidth},{halfOfStrokeWidth}";n.apply(this,arguments)};o.prototype=new n;o.prototype.constructor=o;o.prototype._pathString=function t(e){var r=100-e.strokeWidth/2;return i.render(this._pathTemplate,{width:r,strokeWidth:e.strokeWidth,halfOfStrokeWidth:e.strokeWidth/2})};o.prototype._trailString=function t(e){var r=100-e.strokeWidth/2;return i.render(this._trailTemplate,{width:r,strokeWidth:e.strokeWidth,halfOfStrokeWidth:e.strokeWidth/2,startMargin:e.strokeWidth/2-e.trailWidth/2})};e.exports=o},{"./shape":7,"./utils":9}],9:[function(t,e,r){var n="Webkit Moz O ms".split(" ");var i=.001;function o(t,e,r){t=t||{};e=e||{};r=r||false;for(var n in e){if(e.hasOwnProperty(n)){var i=t[n];var a=e[n];if(r&&p(i)&&p(a)){t[n]=o(i,a,r)}else{t[n]=a}}}return t}function a(t,e){var r=t;for(var n in e){if(e.hasOwnProperty(n)){var i=e[n];var o="\\{"+n+"\\}";var a=new RegExp(o,"g");r=r.replace(a,i)}}return r}function u(t,e,r){var i=t.style;for(var o=0;o<n.length;++o){var a=n[o];i[a+f(e)]=r}i[e]=r}function s(t,e){d(e,function(e,r){if(e===null||e===undefined){return}if(p(e)&&e.prefix===true){u(t,r,e.value)}else{t.style[r]=e}})}function f(t){return t.charAt(0).toUpperCase()+t.slice(1)}function c(t){return typeof t==="string"||t instanceof String}function h(t){return typeof t==="function"}function l(t){return Object.prototype.toString.call(t)==="[object Array]"}function p(t){if(l(t)){return false}var e=typeof t;return e==="object"&&!!t}function d(t,e){for(var r in t){if(t.hasOwnProperty(r)){var n=t[r];e(n,r)}}}function v(t,e){return Math.abs(t-e)<i}function y(t){while(t.firstChild){t.removeChild(t.firstChild)}}e.exports={extend:o,render:a,setStyle:u,setStyles:s,capitalize:f,isString:c,isFunction:h,isObject:p,forEachObject:d,floatEquals:v,removeChildren:y}},{}]},{},[4])(4)});
//# sourceMappingURL=progressbar.map.js