@imposium-hub/components 1.43.3 → 1.43.4

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.
@@ -1,6 +1,6 @@
1
1
  !function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("react"),require("react-redux"),require("redux"),require("axios"),require("react-dom"),require("@fortawesome/react-fontawesome"),require("react-dnd"),require("hotkeys-js"),require("react-resize-detector"),require("react-tooltip"),require("react-table"),require("react-autosuggest"),require("react-dnd-html5-backend"),require("react-moveable"),require("localforage"));else if("function"==typeof define&&define.amd)define(["react","react-redux","redux","axios","react-dom","@fortawesome/react-fontawesome","react-dnd","hotkeys-js","react-resize-detector","react-tooltip","react-table","react-autosuggest","react-dnd-html5-backend","react-moveable","localforage"],t);else{var n="object"==typeof exports?t(require("react"),require("react-redux"),require("redux"),require("axios"),require("react-dom"),require("@fortawesome/react-fontawesome"),require("react-dnd"),require("hotkeys-js"),require("react-resize-detector"),require("react-tooltip"),require("react-table"),require("react-autosuggest"),require("react-dnd-html5-backend"),require("react-moveable"),require("localforage")):t(e.react,e["react-redux"],e.redux,e.axios,e["react-dom"],e["@fortawesome/react-fontawesome"],e["react-dnd"],e["hotkeys-js"],e["react-resize-detector"],e["react-tooltip"],e["react-table"],e["react-autosuggest"],e["react-dnd-html5-backend"],e["react-moveable"],e.localforage);for(var r in n)("object"==typeof exports?exports:e)[r]=n[r]}}(window,(function(e,t,n,r,a,o,i,s,u,l,c,d,p,f,h){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var a=t[r]={i:r,l:!1,exports:{}};return e[r].call(a.exports,a,a.exports,n),a.l=!0,a.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)n.d(r,a,function(t){return e[t]}.bind(null,a));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=90)}([function(t,n){t.exports=e},function(e,t,n){(function(e){e.exports=function(){"use strict";var t,r;function a(){return t.apply(null,arguments)}function o(e){return e instanceof Array||"[object Array]"===Object.prototype.toString.call(e)}function i(e){return null!=e&&"[object Object]"===Object.prototype.toString.call(e)}function s(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function u(e){if(Object.getOwnPropertyNames)return 0===Object.getOwnPropertyNames(e).length;var t;for(t in e)if(s(e,t))return!1;return!0}function l(e){return void 0===e}function c(e){return"number"==typeof e||"[object Number]"===Object.prototype.toString.call(e)}function d(e){return e instanceof Date||"[object Date]"===Object.prototype.toString.call(e)}function p(e,t){var n,r=[];for(n=0;n<e.length;++n)r.push(t(e[n],n));return r}function f(e,t){for(var n in t)s(t,n)&&(e[n]=t[n]);return s(t,"toString")&&(e.toString=t.toString),s(t,"valueOf")&&(e.valueOf=t.valueOf),e}function h(e,t,n,r){return kt(e,t,n,r,!0).utc()}function m(e){return null==e._pf&&(e._pf={empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidEra:null,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],era:null,meridiem:null,rfc2822:!1,weekdayMismatch:!1}),e._pf}function _(e){if(null==e._isValid){var t=m(e),n=r.call(t.parsedDateParts,(function(e){return null!=e})),a=!isNaN(e._d.getTime())&&t.overflow<0&&!t.empty&&!t.invalidEra&&!t.invalidMonth&&!t.invalidWeekday&&!t.weekdayMismatch&&!t.nullInput&&!t.invalidFormat&&!t.userInvalidated&&(!t.meridiem||t.meridiem&&n);if(e._strict&&(a=a&&0===t.charsLeftOver&&0===t.unusedTokens.length&&void 0===t.bigHour),null!=Object.isFrozen&&Object.isFrozen(e))return a;e._isValid=a}return e._isValid}function y(e){var t=h(NaN);return null!=e?f(m(t),e):m(t).userInvalidated=!0,t}r=Array.prototype.some?Array.prototype.some:function(e){var t,n=Object(this),r=n.length>>>0;for(t=0;t<r;t++)if(t in n&&e.call(this,n[t],t,n))return!0;return!1};var g=a.momentProperties=[],v=!1;function b(e,t){var n,r,a;if(l(t._isAMomentObject)||(e._isAMomentObject=t._isAMomentObject),l(t._i)||(e._i=t._i),l(t._f)||(e._f=t._f),l(t._l)||(e._l=t._l),l(t._strict)||(e._strict=t._strict),l(t._tzm)||(e._tzm=t._tzm),l(t._isUTC)||(e._isUTC=t._isUTC),l(t._offset)||(e._offset=t._offset),l(t._pf)||(e._pf=m(t)),l(t._locale)||(e._locale=t._locale),g.length>0)for(n=0;n<g.length;n++)l(a=t[r=g[n]])||(e[r]=a);return e}function w(e){b(this,e),this._d=new Date(null!=e._d?e._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),!1===v&&(v=!0,a.updateOffset(this),v=!1)}function M(e){return e instanceof w||null!=e&&null!=e._isAMomentObject}function L(e){!1===a.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+e)}function T(e,t){var n=!0;return f((function(){if(null!=a.deprecationHandler&&a.deprecationHandler(null,e),n){var r,o,i,u=[];for(o=0;o<arguments.length;o++){if(r="","object"==typeof arguments[o]){for(i in r+="\n["+o+"] ",arguments[0])s(arguments[0],i)&&(r+=i+": "+arguments[0][i]+", ");r=r.slice(0,-2)}else r=arguments[o];u.push(r)}L(e+"\nArguments: "+Array.prototype.slice.call(u).join("")+"\n"+(new Error).stack),n=!1}return t.apply(this,arguments)}),t)}var k,x={};function E(e,t){null!=a.deprecationHandler&&a.deprecationHandler(e,t),x[e]||(L(t),x[e]=!0)}function S(e){return"undefined"!=typeof Function&&e instanceof Function||"[object Function]"===Object.prototype.toString.call(e)}function O(e,t){var n,r=f({},e);for(n in t)s(t,n)&&(i(e[n])&&i(t[n])?(r[n]={},f(r[n],e[n]),f(r[n],t[n])):null!=t[n]?r[n]=t[n]:delete r[n]);for(n in e)s(e,n)&&!s(t,n)&&i(e[n])&&(r[n]=f({},r[n]));return r}function D(e){null!=e&&this.set(e)}function Y(e,t,n){var r=""+Math.abs(e),a=t-r.length;return(e>=0?n?"+":"":"-")+Math.pow(10,Math.max(0,a)).toString().substr(1)+r}a.suppressDeprecationWarnings=!1,a.deprecationHandler=null,k=Object.keys?Object.keys:function(e){var t,n=[];for(t in e)s(e,t)&&n.push(t);return n};var A=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,C=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,j={},P={};function H(e,t,n,r){var a=r;"string"==typeof r&&(a=function(){return this[r]()}),e&&(P[e]=a),t&&(P[t[0]]=function(){return Y(a.apply(this,arguments),t[1],t[2])}),n&&(P[n]=function(){return this.localeData().ordinal(a.apply(this,arguments),e)})}function I(e,t){return e.isValid()?(t=N(t,e.localeData()),j[t]=j[t]||function(e){var t,n,r,a=e.match(A);for(t=0,n=a.length;t<n;t++)P[a[t]]?a[t]=P[a[t]]:a[t]=(r=a[t]).match(/\[[\s\S]/)?r.replace(/^\[|\]$/g,""):r.replace(/\\/g,"");return function(t){var r,o="";for(r=0;r<n;r++)o+=S(a[r])?a[r].call(t,e):a[r];return o}}(t),j[t](e)):e.localeData().invalidDate()}function N(e,t){var n=5;function r(e){return t.longDateFormat(e)||e}for(C.lastIndex=0;n>=0&&C.test(e);)e=e.replace(C,r),C.lastIndex=0,n-=1;return e}var R={};function F(e,t){var n=e.toLowerCase();R[n]=R[n+"s"]=R[t]=e}function z(e){return"string"==typeof e?R[e]||R[e.toLowerCase()]:void 0}function U(e){var t,n,r={};for(n in e)s(e,n)&&(t=z(n))&&(r[t]=e[n]);return r}var W={};function B(e,t){W[e]=t}function V(e){return e%4==0&&e%100!=0||e%400==0}function G(e){return e<0?Math.ceil(e)||0:Math.floor(e)}function q(e){var t=+e,n=0;return 0!==t&&isFinite(t)&&(n=G(t)),n}function J(e,t){return function(n){return null!=n?($(this,e,n),a.updateOffset(this,t),this):K(this,e)}}function K(e,t){return e.isValid()?e._d["get"+(e._isUTC?"UTC":"")+t]():NaN}function $(e,t,n){e.isValid()&&!isNaN(n)&&("FullYear"===t&&V(e.year())&&1===e.month()&&29===e.date()?(n=q(n),e._d["set"+(e._isUTC?"UTC":"")+t](n,e.month(),Me(n,e.month()))):e._d["set"+(e._isUTC?"UTC":"")+t](n))}var X,Z=/\d/,Q=/\d\d/,ee=/\d{3}/,te=/\d{4}/,ne=/[+-]?\d{6}/,re=/\d\d?/,ae=/\d\d\d\d?/,oe=/\d\d\d\d\d\d?/,ie=/\d{1,3}/,se=/\d{1,4}/,ue=/[+-]?\d{1,6}/,le=/\d+/,ce=/[+-]?\d+/,de=/Z|[+-]\d\d:?\d\d/gi,pe=/Z|[+-]\d\d(?::?\d\d)?/gi,fe=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i;function he(e,t,n){X[e]=S(t)?t:function(e,r){return e&&n?n:t}}function me(e,t){return s(X,e)?X[e](t._strict,t._locale):new RegExp(_e(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,(function(e,t,n,r,a){return t||n||r||a}))))}function _e(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}X={};var ye,ge={};function ve(e,t){var n,r=t;for("string"==typeof e&&(e=[e]),c(t)&&(r=function(e,n){n[t]=q(e)}),n=0;n<e.length;n++)ge[e[n]]=r}function be(e,t){ve(e,(function(e,n,r,a){r._w=r._w||{},t(e,r._w,r,a)}))}function we(e,t,n){null!=t&&s(ge,e)&&ge[e](t,n._a,n,e)}function Me(e,t){if(isNaN(e)||isNaN(t))return NaN;var n,r=(t%(n=12)+n)%n;return e+=(t-r)/12,1===r?V(e)?29:28:31-r%7%2}ye=Array.prototype.indexOf?Array.prototype.indexOf:function(e){var t;for(t=0;t<this.length;++t)if(this[t]===e)return t;return-1},H("M",["MM",2],"Mo",(function(){return this.month()+1})),H("MMM",0,0,(function(e){return this.localeData().monthsShort(this,e)})),H("MMMM",0,0,(function(e){return this.localeData().months(this,e)})),F("month","M"),B("month",8),he("M",re),he("MM",re,Q),he("MMM",(function(e,t){return t.monthsShortRegex(e)})),he("MMMM",(function(e,t){return t.monthsRegex(e)})),ve(["M","MM"],(function(e,t){t[1]=q(e)-1})),ve(["MMM","MMMM"],(function(e,t,n,r){var a=n._locale.monthsParse(e,r,n._strict);null!=a?t[1]=a:m(n).invalidMonth=e}));var Le="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),Te="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),ke=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,xe=fe,Ee=fe;function Se(e,t,n){var r,a,o,i=e.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],r=0;r<12;++r)o=h([2e3,r]),this._shortMonthsParse[r]=this.monthsShort(o,"").toLocaleLowerCase(),this._longMonthsParse[r]=this.months(o,"").toLocaleLowerCase();return n?"MMM"===t?-1!==(a=ye.call(this._shortMonthsParse,i))?a:null:-1!==(a=ye.call(this._longMonthsParse,i))?a:null:"MMM"===t?-1!==(a=ye.call(this._shortMonthsParse,i))||-1!==(a=ye.call(this._longMonthsParse,i))?a:null:-1!==(a=ye.call(this._longMonthsParse,i))||-1!==(a=ye.call(this._shortMonthsParse,i))?a:null}function Oe(e,t){var n;if(!e.isValid())return e;if("string"==typeof t)if(/^\d+$/.test(t))t=q(t);else if(!c(t=e.localeData().monthsParse(t)))return e;return n=Math.min(e.date(),Me(e.year(),t)),e._d["set"+(e._isUTC?"UTC":"")+"Month"](t,n),e}function De(e){return null!=e?(Oe(this,e),a.updateOffset(this,!0),this):K(this,"Month")}function Ye(){function e(e,t){return t.length-e.length}var t,n,r=[],a=[],o=[];for(t=0;t<12;t++)n=h([2e3,t]),r.push(this.monthsShort(n,"")),a.push(this.months(n,"")),o.push(this.months(n,"")),o.push(this.monthsShort(n,""));for(r.sort(e),a.sort(e),o.sort(e),t=0;t<12;t++)r[t]=_e(r[t]),a[t]=_e(a[t]);for(t=0;t<24;t++)o[t]=_e(o[t]);this._monthsRegex=new RegExp("^("+o.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+a.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+r.join("|")+")","i")}function Ae(e){return V(e)?366:365}H("Y",0,0,(function(){var e=this.year();return e<=9999?Y(e,4):"+"+e})),H(0,["YY",2],0,(function(){return this.year()%100})),H(0,["YYYY",4],0,"year"),H(0,["YYYYY",5],0,"year"),H(0,["YYYYYY",6,!0],0,"year"),F("year","y"),B("year",1),he("Y",ce),he("YY",re,Q),he("YYYY",se,te),he("YYYYY",ue,ne),he("YYYYYY",ue,ne),ve(["YYYYY","YYYYYY"],0),ve("YYYY",(function(e,t){t[0]=2===e.length?a.parseTwoDigitYear(e):q(e)})),ve("YY",(function(e,t){t[0]=a.parseTwoDigitYear(e)})),ve("Y",(function(e,t){t[0]=parseInt(e,10)})),a.parseTwoDigitYear=function(e){return q(e)+(q(e)>68?1900:2e3)};var Ce=J("FullYear",!0);function je(e,t,n,r,a,o,i){var s;return e<100&&e>=0?(s=new Date(e+400,t,n,r,a,o,i),isFinite(s.getFullYear())&&s.setFullYear(e)):s=new Date(e,t,n,r,a,o,i),s}function Pe(e){var t,n;return e<100&&e>=0?((n=Array.prototype.slice.call(arguments))[0]=e+400,t=new Date(Date.UTC.apply(null,n)),isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e)):t=new Date(Date.UTC.apply(null,arguments)),t}function He(e,t,n){var r=7+t-n;return-(7+Pe(e,0,r).getUTCDay()-t)%7+r-1}function Ie(e,t,n,r,a){var o,i,s=1+7*(t-1)+(7+n-r)%7+He(e,r,a);return s<=0?i=Ae(o=e-1)+s:s>Ae(e)?(o=e+1,i=s-Ae(e)):(o=e,i=s),{year:o,dayOfYear:i}}function Ne(e,t,n){var r,a,o=He(e.year(),t,n),i=Math.floor((e.dayOfYear()-o-1)/7)+1;return i<1?r=i+Re(a=e.year()-1,t,n):i>Re(e.year(),t,n)?(r=i-Re(e.year(),t,n),a=e.year()+1):(a=e.year(),r=i),{week:r,year:a}}function Re(e,t,n){var r=He(e,t,n),a=He(e+1,t,n);return(Ae(e)-r+a)/7}function Fe(e,t){return e.slice(t,7).concat(e.slice(0,t))}H("w",["ww",2],"wo","week"),H("W",["WW",2],"Wo","isoWeek"),F("week","w"),F("isoWeek","W"),B("week",5),B("isoWeek",5),he("w",re),he("ww",re,Q),he("W",re),he("WW",re,Q),be(["w","ww","W","WW"],(function(e,t,n,r){t[r.substr(0,1)]=q(e)})),H("d",0,"do","day"),H("dd",0,0,(function(e){return this.localeData().weekdaysMin(this,e)})),H("ddd",0,0,(function(e){return this.localeData().weekdaysShort(this,e)})),H("dddd",0,0,(function(e){return this.localeData().weekdays(this,e)})),H("e",0,0,"weekday"),H("E",0,0,"isoWeekday"),F("day","d"),F("weekday","e"),F("isoWeekday","E"),B("day",11),B("weekday",11),B("isoWeekday",11),he("d",re),he("e",re),he("E",re),he("dd",(function(e,t){return t.weekdaysMinRegex(e)})),he("ddd",(function(e,t){return t.weekdaysShortRegex(e)})),he("dddd",(function(e,t){return t.weekdaysRegex(e)})),be(["dd","ddd","dddd"],(function(e,t,n,r){var a=n._locale.weekdaysParse(e,r,n._strict);null!=a?t.d=a:m(n).invalidWeekday=e})),be(["d","e","E"],(function(e,t,n,r){t[r]=q(e)}));var ze="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Ue="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),We="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),Be=fe,Ve=fe,Ge=fe;function qe(e,t,n){var r,a,o,i=e.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],r=0;r<7;++r)o=h([2e3,1]).day(r),this._minWeekdaysParse[r]=this.weekdaysMin(o,"").toLocaleLowerCase(),this._shortWeekdaysParse[r]=this.weekdaysShort(o,"").toLocaleLowerCase(),this._weekdaysParse[r]=this.weekdays(o,"").toLocaleLowerCase();return n?"dddd"===t?-1!==(a=ye.call(this._weekdaysParse,i))?a:null:"ddd"===t?-1!==(a=ye.call(this._shortWeekdaysParse,i))?a:null:-1!==(a=ye.call(this._minWeekdaysParse,i))?a:null:"dddd"===t?-1!==(a=ye.call(this._weekdaysParse,i))||-1!==(a=ye.call(this._shortWeekdaysParse,i))||-1!==(a=ye.call(this._minWeekdaysParse,i))?a:null:"ddd"===t?-1!==(a=ye.call(this._shortWeekdaysParse,i))||-1!==(a=ye.call(this._weekdaysParse,i))||-1!==(a=ye.call(this._minWeekdaysParse,i))?a:null:-1!==(a=ye.call(this._minWeekdaysParse,i))||-1!==(a=ye.call(this._weekdaysParse,i))||-1!==(a=ye.call(this._shortWeekdaysParse,i))?a:null}function Je(){function e(e,t){return t.length-e.length}var t,n,r,a,o,i=[],s=[],u=[],l=[];for(t=0;t<7;t++)n=h([2e3,1]).day(t),r=_e(this.weekdaysMin(n,"")),a=_e(this.weekdaysShort(n,"")),o=_e(this.weekdays(n,"")),i.push(r),s.push(a),u.push(o),l.push(r),l.push(a),l.push(o);i.sort(e),s.sort(e),u.sort(e),l.sort(e),this._weekdaysRegex=new RegExp("^("+l.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+u.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+i.join("|")+")","i")}function Ke(){return this.hours()%12||12}function $e(e,t){H(e,0,0,(function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)}))}function Xe(e,t){return t._meridiemParse}H("H",["HH",2],0,"hour"),H("h",["hh",2],0,Ke),H("k",["kk",2],0,(function(){return this.hours()||24})),H("hmm",0,0,(function(){return""+Ke.apply(this)+Y(this.minutes(),2)})),H("hmmss",0,0,(function(){return""+Ke.apply(this)+Y(this.minutes(),2)+Y(this.seconds(),2)})),H("Hmm",0,0,(function(){return""+this.hours()+Y(this.minutes(),2)})),H("Hmmss",0,0,(function(){return""+this.hours()+Y(this.minutes(),2)+Y(this.seconds(),2)})),$e("a",!0),$e("A",!1),F("hour","h"),B("hour",13),he("a",Xe),he("A",Xe),he("H",re),he("h",re),he("k",re),he("HH",re,Q),he("hh",re,Q),he("kk",re,Q),he("hmm",ae),he("hmmss",oe),he("Hmm",ae),he("Hmmss",oe),ve(["H","HH"],3),ve(["k","kk"],(function(e,t,n){var r=q(e);t[3]=24===r?0:r})),ve(["a","A"],(function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e})),ve(["h","hh"],(function(e,t,n){t[3]=q(e),m(n).bigHour=!0})),ve("hmm",(function(e,t,n){var r=e.length-2;t[3]=q(e.substr(0,r)),t[4]=q(e.substr(r)),m(n).bigHour=!0})),ve("hmmss",(function(e,t,n){var r=e.length-4,a=e.length-2;t[3]=q(e.substr(0,r)),t[4]=q(e.substr(r,2)),t[5]=q(e.substr(a)),m(n).bigHour=!0})),ve("Hmm",(function(e,t,n){var r=e.length-2;t[3]=q(e.substr(0,r)),t[4]=q(e.substr(r))})),ve("Hmmss",(function(e,t,n){var r=e.length-4,a=e.length-2;t[3]=q(e.substr(0,r)),t[4]=q(e.substr(r,2)),t[5]=q(e.substr(a))}));var Ze,Qe=J("Hours",!0),et={calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},longDateFormat:{LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:/\d{1,2}/,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},months:Le,monthsShort:Te,week:{dow:0,doy:6},weekdays:ze,weekdaysMin:We,weekdaysShort:Ue,meridiemParse:/[ap]\.?m?\.?/i},tt={},nt={};function rt(e,t){var n,r=Math.min(e.length,t.length);for(n=0;n<r;n+=1)if(e[n]!==t[n])return n;return r}function at(e){return e?e.toLowerCase().replace("_","-"):e}function ot(t){var r=null;if(void 0===tt[t]&&void 0!==e&&e&&e.exports)try{r=Ze._abbr,n(516)("./"+t),it(r)}catch(e){tt[t]=null}return tt[t]}function it(e,t){var n;return e&&((n=l(t)?ut(e):st(e,t))?Ze=n:"undefined"!=typeof console&&console.warn&&console.warn("Locale "+e+" not found. Did you forget to load it?")),Ze._abbr}function st(e,t){if(null!==t){var n,r=et;if(t.abbr=e,null!=tt[e])E("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),r=tt[e]._config;else if(null!=t.parentLocale)if(null!=tt[t.parentLocale])r=tt[t.parentLocale]._config;else{if(null==(n=ot(t.parentLocale)))return nt[t.parentLocale]||(nt[t.parentLocale]=[]),nt[t.parentLocale].push({name:e,config:t}),null;r=n._config}return tt[e]=new D(O(r,t)),nt[e]&&nt[e].forEach((function(e){st(e.name,e.config)})),it(e),tt[e]}return delete tt[e],null}function ut(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return Ze;if(!o(e)){if(t=ot(e))return t;e=[e]}return function(e){for(var t,n,r,a,o=0;o<e.length;){for(t=(a=at(e[o]).split("-")).length,n=(n=at(e[o+1]))?n.split("-"):null;t>0;){if(r=ot(a.slice(0,t).join("-")))return r;if(n&&n.length>=t&&rt(a,n)>=t-1)break;t--}o++}return Ze}(e)}function lt(e){var t,n=e._a;return n&&-2===m(e).overflow&&(t=n[1]<0||n[1]>11?1:n[2]<1||n[2]>Me(n[0],n[1])?2:n[3]<0||n[3]>24||24===n[3]&&(0!==n[4]||0!==n[5]||0!==n[6])?3:n[4]<0||n[4]>59?4:n[5]<0||n[5]>59?5:n[6]<0||n[6]>999?6:-1,m(e)._overflowDayOfYear&&(t<0||t>2)&&(t=2),m(e)._overflowWeeks&&-1===t&&(t=7),m(e)._overflowWeekday&&-1===t&&(t=8),m(e).overflow=t),e}var ct=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,dt=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,pt=/Z|[+-]\d\d(?::?\d\d)?/,ft=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],ht=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],mt=/^\/?Date\((-?\d+)/i,_t=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,yt={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function gt(e){var t,n,r,a,o,i,s=e._i,u=ct.exec(s)||dt.exec(s);if(u){for(m(e).iso=!0,t=0,n=ft.length;t<n;t++)if(ft[t][1].exec(u[1])){a=ft[t][0],r=!1!==ft[t][2];break}if(null==a)return void(e._isValid=!1);if(u[3]){for(t=0,n=ht.length;t<n;t++)if(ht[t][1].exec(u[3])){o=(u[2]||" ")+ht[t][0];break}if(null==o)return void(e._isValid=!1)}if(!r&&null!=o)return void(e._isValid=!1);if(u[4]){if(!pt.exec(u[4]))return void(e._isValid=!1);i="Z"}e._f=a+(o||"")+(i||""),Lt(e)}else e._isValid=!1}function vt(e){var t=parseInt(e,10);return t<=49?2e3+t:t<=999?1900+t:t}function bt(e){var t,n,r,a,o,i,s,u,l=_t.exec(e._i.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,""));if(l){if(n=l[4],r=l[3],a=l[2],o=l[5],i=l[6],s=l[7],u=[vt(n),Te.indexOf(r),parseInt(a,10),parseInt(o,10),parseInt(i,10)],s&&u.push(parseInt(s,10)),t=u,!function(e,t,n){return!e||Ue.indexOf(e)===new Date(t[0],t[1],t[2]).getDay()||(m(n).weekdayMismatch=!0,n._isValid=!1,!1)}(l[1],t,e))return;e._a=t,e._tzm=function(e,t,n){if(e)return yt[e];if(t)return 0;var r=parseInt(n,10),a=r%100;return(r-a)/100*60+a}(l[8],l[9],l[10]),e._d=Pe.apply(null,e._a),e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),m(e).rfc2822=!0}else e._isValid=!1}function wt(e,t,n){return null!=e?e:null!=t?t:n}function Mt(e){var t,n,r,o,i,s=[];if(!e._d){for(r=function(e){var t=new Date(a.now());return e._useUTC?[t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()]:[t.getFullYear(),t.getMonth(),t.getDate()]}(e),e._w&&null==e._a[2]&&null==e._a[1]&&function(e){var t,n,r,a,o,i,s,u,l;null!=(t=e._w).GG||null!=t.W||null!=t.E?(o=1,i=4,n=wt(t.GG,e._a[0],Ne(xt(),1,4).year),r=wt(t.W,1),((a=wt(t.E,1))<1||a>7)&&(u=!0)):(o=e._locale._week.dow,i=e._locale._week.doy,l=Ne(xt(),o,i),n=wt(t.gg,e._a[0],l.year),r=wt(t.w,l.week),null!=t.d?((a=t.d)<0||a>6)&&(u=!0):null!=t.e?(a=t.e+o,(t.e<0||t.e>6)&&(u=!0)):a=o),r<1||r>Re(n,o,i)?m(e)._overflowWeeks=!0:null!=u?m(e)._overflowWeekday=!0:(s=Ie(n,r,a,o,i),e._a[0]=s.year,e._dayOfYear=s.dayOfYear)}(e),null!=e._dayOfYear&&(i=wt(e._a[0],r[0]),(e._dayOfYear>Ae(i)||0===e._dayOfYear)&&(m(e)._overflowDayOfYear=!0),n=Pe(i,0,e._dayOfYear),e._a[1]=n.getUTCMonth(),e._a[2]=n.getUTCDate()),t=0;t<3&&null==e._a[t];++t)e._a[t]=s[t]=r[t];for(;t<7;t++)e._a[t]=s[t]=null==e._a[t]?2===t?1:0:e._a[t];24===e._a[3]&&0===e._a[4]&&0===e._a[5]&&0===e._a[6]&&(e._nextDay=!0,e._a[3]=0),e._d=(e._useUTC?Pe:je).apply(null,s),o=e._useUTC?e._d.getUTCDay():e._d.getDay(),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[3]=24),e._w&&void 0!==e._w.d&&e._w.d!==o&&(m(e).weekdayMismatch=!0)}}function Lt(e){if(e._f!==a.ISO_8601)if(e._f!==a.RFC_2822){e._a=[],m(e).empty=!0;var t,n,r,o,i,s,u=""+e._i,l=u.length,c=0;for(r=N(e._f,e._locale).match(A)||[],t=0;t<r.length;t++)o=r[t],(n=(u.match(me(o,e))||[])[0])&&((i=u.substr(0,u.indexOf(n))).length>0&&m(e).unusedInput.push(i),u=u.slice(u.indexOf(n)+n.length),c+=n.length),P[o]?(n?m(e).empty=!1:m(e).unusedTokens.push(o),we(o,n,e)):e._strict&&!n&&m(e).unusedTokens.push(o);m(e).charsLeftOver=l-c,u.length>0&&m(e).unusedInput.push(u),e._a[3]<=12&&!0===m(e).bigHour&&e._a[3]>0&&(m(e).bigHour=void 0),m(e).parsedDateParts=e._a.slice(0),m(e).meridiem=e._meridiem,e._a[3]=function(e,t,n){var r;return null==n?t:null!=e.meridiemHour?e.meridiemHour(t,n):null!=e.isPM?((r=e.isPM(n))&&t<12&&(t+=12),r||12!==t||(t=0),t):t}(e._locale,e._a[3],e._meridiem),null!==(s=m(e).era)&&(e._a[0]=e._locale.erasConvertYear(s,e._a[0])),Mt(e),lt(e)}else bt(e);else gt(e)}function Tt(e){var t=e._i,n=e._f;return e._locale=e._locale||ut(e._l),null===t||void 0===n&&""===t?y({nullInput:!0}):("string"==typeof t&&(e._i=t=e._locale.preparse(t)),M(t)?new w(lt(t)):(d(t)?e._d=t:o(n)?function(e){var t,n,r,a,o,i,s=!1;if(0===e._f.length)return m(e).invalidFormat=!0,void(e._d=new Date(NaN));for(a=0;a<e._f.length;a++)o=0,i=!1,t=b({},e),null!=e._useUTC&&(t._useUTC=e._useUTC),t._f=e._f[a],Lt(t),_(t)&&(i=!0),o+=m(t).charsLeftOver,o+=10*m(t).unusedTokens.length,m(t).score=o,s?o<r&&(r=o,n=t):(null==r||o<r||i)&&(r=o,n=t,i&&(s=!0));f(e,n||t)}(e):n?Lt(e):function(e){var t=e._i;l(t)?e._d=new Date(a.now()):d(t)?e._d=new Date(t.valueOf()):"string"==typeof t?function(e){var t=mt.exec(e._i);null===t?(gt(e),!1===e._isValid&&(delete e._isValid,bt(e),!1===e._isValid&&(delete e._isValid,e._strict?e._isValid=!1:a.createFromInputFallback(e)))):e._d=new Date(+t[1])}(e):o(t)?(e._a=p(t.slice(0),(function(e){return parseInt(e,10)})),Mt(e)):i(t)?function(e){if(!e._d){var t=U(e._i),n=void 0===t.day?t.date:t.day;e._a=p([t.year,t.month,n,t.hour,t.minute,t.second,t.millisecond],(function(e){return e&&parseInt(e,10)})),Mt(e)}}(e):c(t)?e._d=new Date(t):a.createFromInputFallback(e)}(e),_(e)||(e._d=null),e))}function kt(e,t,n,r,a){var s,l={};return!0!==t&&!1!==t||(r=t,t=void 0),!0!==n&&!1!==n||(r=n,n=void 0),(i(e)&&u(e)||o(e)&&0===e.length)&&(e=void 0),l._isAMomentObject=!0,l._useUTC=l._isUTC=a,l._l=n,l._i=e,l._f=t,l._strict=r,(s=new w(lt(Tt(l))))._nextDay&&(s.add(1,"d"),s._nextDay=void 0),s}function xt(e,t,n,r){return kt(e,t,n,r,!1)}a.createFromInputFallback=T("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",(function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))})),a.ISO_8601=function(){},a.RFC_2822=function(){};var Et=T("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var e=xt.apply(null,arguments);return this.isValid()&&e.isValid()?e<this?this:e:y()})),St=T("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var e=xt.apply(null,arguments);return this.isValid()&&e.isValid()?e>this?this:e:y()}));function Ot(e,t){var n,r;if(1===t.length&&o(t[0])&&(t=t[0]),!t.length)return xt();for(n=t[0],r=1;r<t.length;++r)t[r].isValid()&&!t[r][e](n)||(n=t[r]);return n}var Dt=["year","quarter","month","week","day","hour","minute","second","millisecond"];function Yt(e){var t=U(e),n=t.year||0,r=t.quarter||0,a=t.month||0,o=t.week||t.isoWeek||0,i=t.day||0,u=t.hour||0,l=t.minute||0,c=t.second||0,d=t.millisecond||0;this._isValid=function(e){var t,n,r=!1;for(t in e)if(s(e,t)&&(-1===ye.call(Dt,t)||null!=e[t]&&isNaN(e[t])))return!1;for(n=0;n<Dt.length;++n)if(e[Dt[n]]){if(r)return!1;parseFloat(e[Dt[n]])!==q(e[Dt[n]])&&(r=!0)}return!0}(t),this._milliseconds=+d+1e3*c+6e4*l+1e3*u*60*60,this._days=+i+7*o,this._months=+a+3*r+12*n,this._data={},this._locale=ut(),this._bubble()}function At(e){return e instanceof Yt}function Ct(e){return e<0?-1*Math.round(-1*e):Math.round(e)}function jt(e,t){H(e,0,0,(function(){var e=this.utcOffset(),n="+";return e<0&&(e=-e,n="-"),n+Y(~~(e/60),2)+t+Y(~~e%60,2)}))}jt("Z",":"),jt("ZZ",""),he("Z",pe),he("ZZ",pe),ve(["Z","ZZ"],(function(e,t,n){n._useUTC=!0,n._tzm=Ht(pe,e)}));var Pt=/([\+\-]|\d\d)/gi;function Ht(e,t){var n,r,a=(t||"").match(e);return null===a?null:0===(r=60*(n=((a[a.length-1]||[])+"").match(Pt)||["-",0,0])[1]+q(n[2]))?0:"+"===n[0]?r:-r}function It(e,t){var n,r;return t._isUTC?(n=t.clone(),r=(M(e)||d(e)?e.valueOf():xt(e).valueOf())-n.valueOf(),n._d.setTime(n._d.valueOf()+r),a.updateOffset(n,!1),n):xt(e).local()}function Nt(e){return-Math.round(e._d.getTimezoneOffset())}function Rt(){return!!this.isValid()&&this._isUTC&&0===this._offset}a.updateOffset=function(){};var Ft=/^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/,zt=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function Ut(e,t){var n,r,a,o,i,u,l=e,d=null;return At(e)?l={ms:e._milliseconds,d:e._days,M:e._months}:c(e)||!isNaN(+e)?(l={},t?l[t]=+e:l.milliseconds=+e):(d=Ft.exec(e))?(n="-"===d[1]?-1:1,l={y:0,d:q(d[2])*n,h:q(d[3])*n,m:q(d[4])*n,s:q(d[5])*n,ms:q(Ct(1e3*d[6]))*n}):(d=zt.exec(e))?(n="-"===d[1]?-1:1,l={y:Wt(d[2],n),M:Wt(d[3],n),w:Wt(d[4],n),d:Wt(d[5],n),h:Wt(d[6],n),m:Wt(d[7],n),s:Wt(d[8],n)}):null==l?l={}:"object"==typeof l&&("from"in l||"to"in l)&&(o=xt(l.from),i=xt(l.to),a=o.isValid()&&i.isValid()?(i=It(i,o),o.isBefore(i)?u=Bt(o,i):((u=Bt(i,o)).milliseconds=-u.milliseconds,u.months=-u.months),u):{milliseconds:0,months:0},(l={}).ms=a.milliseconds,l.M=a.months),r=new Yt(l),At(e)&&s(e,"_locale")&&(r._locale=e._locale),At(e)&&s(e,"_isValid")&&(r._isValid=e._isValid),r}function Wt(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function Bt(e,t){var n={};return n.months=t.month()-e.month()+12*(t.year()-e.year()),e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function Vt(e,t){return function(n,r){var a;return null===r||isNaN(+r)||(E(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),a=n,n=r,r=a),Gt(this,Ut(n,r),e),this}}function Gt(e,t,n,r){var o=t._milliseconds,i=Ct(t._days),s=Ct(t._months);e.isValid()&&(r=null==r||r,s&&Oe(e,K(e,"Month")+s*n),i&&$(e,"Date",K(e,"Date")+i*n),o&&e._d.setTime(e._d.valueOf()+o*n),r&&a.updateOffset(e,i||s))}Ut.fn=Yt.prototype,Ut.invalid=function(){return Ut(NaN)};var qt=Vt(1,"add"),Jt=Vt(-1,"subtract");function Kt(e){return"string"==typeof e||e instanceof String}function $t(e){return M(e)||d(e)||Kt(e)||c(e)||function(e){var t=o(e),n=!1;return t&&(n=0===e.filter((function(t){return!c(t)&&Kt(e)})).length),t&&n}(e)||function(e){var t,n,r=i(e)&&!u(e),a=!1,o=["years","year","y","months","month","M","days","day","d","dates","date","D","hours","hour","h","minutes","minute","m","seconds","second","s","milliseconds","millisecond","ms"];for(t=0;t<o.length;t+=1)n=o[t],a=a||s(e,n);return r&&a}(e)||null==e}function Xt(e){var t,n=i(e)&&!u(e),r=!1,a=["sameDay","nextDay","lastDay","nextWeek","lastWeek","sameElse"];for(t=0;t<a.length;t+=1)r=r||s(e,a[t]);return n&&r}function Zt(e,t){if(e.date()<t.date())return-Zt(t,e);var n=12*(t.year()-e.year())+(t.month()-e.month()),r=e.clone().add(n,"months");return-(n+(t-r<0?(t-r)/(r-e.clone().add(n-1,"months")):(t-r)/(e.clone().add(n+1,"months")-r)))||0}function Qt(e){var t;return void 0===e?this._locale._abbr:(null!=(t=ut(e))&&(this._locale=t),this)}a.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",a.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var en=T("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",(function(e){return void 0===e?this.localeData():this.locale(e)}));function tn(){return this._locale}function nn(e,t){return(e%t+t)%t}function rn(e,t,n){return e<100&&e>=0?new Date(e+400,t,n)-126227808e5:new Date(e,t,n).valueOf()}function an(e,t,n){return e<100&&e>=0?Date.UTC(e+400,t,n)-126227808e5:Date.UTC(e,t,n)}function on(e,t){return t.erasAbbrRegex(e)}function sn(){var e,t,n=[],r=[],a=[],o=[],i=this.eras();for(e=0,t=i.length;e<t;++e)r.push(_e(i[e].name)),n.push(_e(i[e].abbr)),a.push(_e(i[e].narrow)),o.push(_e(i[e].name)),o.push(_e(i[e].abbr)),o.push(_e(i[e].narrow));this._erasRegex=new RegExp("^("+o.join("|")+")","i"),this._erasNameRegex=new RegExp("^("+r.join("|")+")","i"),this._erasAbbrRegex=new RegExp("^("+n.join("|")+")","i"),this._erasNarrowRegex=new RegExp("^("+a.join("|")+")","i")}function un(e,t){H(0,[e,e.length],0,t)}function ln(e,t,n,r,a){var o;return null==e?Ne(this,r,a).year:(t>(o=Re(e,r,a))&&(t=o),cn.call(this,e,t,n,r,a))}function cn(e,t,n,r,a){var o=Ie(e,t,n,r,a),i=Pe(o.year,0,o.dayOfYear);return this.year(i.getUTCFullYear()),this.month(i.getUTCMonth()),this.date(i.getUTCDate()),this}H("N",0,0,"eraAbbr"),H("NN",0,0,"eraAbbr"),H("NNN",0,0,"eraAbbr"),H("NNNN",0,0,"eraName"),H("NNNNN",0,0,"eraNarrow"),H("y",["y",1],"yo","eraYear"),H("y",["yy",2],0,"eraYear"),H("y",["yyy",3],0,"eraYear"),H("y",["yyyy",4],0,"eraYear"),he("N",on),he("NN",on),he("NNN",on),he("NNNN",(function(e,t){return t.erasNameRegex(e)})),he("NNNNN",(function(e,t){return t.erasNarrowRegex(e)})),ve(["N","NN","NNN","NNNN","NNNNN"],(function(e,t,n,r){var a=n._locale.erasParse(e,r,n._strict);a?m(n).era=a:m(n).invalidEra=e})),he("y",le),he("yy",le),he("yyy",le),he("yyyy",le),he("yo",(function(e,t){return t._eraYearOrdinalRegex||le})),ve(["y","yy","yyy","yyyy"],0),ve(["yo"],(function(e,t,n,r){var a;n._locale._eraYearOrdinalRegex&&(a=e.match(n._locale._eraYearOrdinalRegex)),n._locale.eraYearOrdinalParse?t[0]=n._locale.eraYearOrdinalParse(e,a):t[0]=parseInt(e,10)})),H(0,["gg",2],0,(function(){return this.weekYear()%100})),H(0,["GG",2],0,(function(){return this.isoWeekYear()%100})),un("gggg","weekYear"),un("ggggg","weekYear"),un("GGGG","isoWeekYear"),un("GGGGG","isoWeekYear"),F("weekYear","gg"),F("isoWeekYear","GG"),B("weekYear",1),B("isoWeekYear",1),he("G",ce),he("g",ce),he("GG",re,Q),he("gg",re,Q),he("GGGG",se,te),he("gggg",se,te),he("GGGGG",ue,ne),he("ggggg",ue,ne),be(["gggg","ggggg","GGGG","GGGGG"],(function(e,t,n,r){t[r.substr(0,2)]=q(e)})),be(["gg","GG"],(function(e,t,n,r){t[r]=a.parseTwoDigitYear(e)})),H("Q",0,"Qo","quarter"),F("quarter","Q"),B("quarter",7),he("Q",Z),ve("Q",(function(e,t){t[1]=3*(q(e)-1)})),H("D",["DD",2],"Do","date"),F("date","D"),B("date",9),he("D",re),he("DD",re,Q),he("Do",(function(e,t){return e?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient})),ve(["D","DD"],2),ve("Do",(function(e,t){t[2]=q(e.match(re)[0])}));var dn=J("Date",!0);H("DDD",["DDDD",3],"DDDo","dayOfYear"),F("dayOfYear","DDD"),B("dayOfYear",4),he("DDD",ie),he("DDDD",ee),ve(["DDD","DDDD"],(function(e,t,n){n._dayOfYear=q(e)})),H("m",["mm",2],0,"minute"),F("minute","m"),B("minute",14),he("m",re),he("mm",re,Q),ve(["m","mm"],4);var pn=J("Minutes",!1);H("s",["ss",2],0,"second"),F("second","s"),B("second",15),he("s",re),he("ss",re,Q),ve(["s","ss"],5);var fn,hn,mn=J("Seconds",!1);for(H("S",0,0,(function(){return~~(this.millisecond()/100)})),H(0,["SS",2],0,(function(){return~~(this.millisecond()/10)})),H(0,["SSS",3],0,"millisecond"),H(0,["SSSS",4],0,(function(){return 10*this.millisecond()})),H(0,["SSSSS",5],0,(function(){return 100*this.millisecond()})),H(0,["SSSSSS",6],0,(function(){return 1e3*this.millisecond()})),H(0,["SSSSSSS",7],0,(function(){return 1e4*this.millisecond()})),H(0,["SSSSSSSS",8],0,(function(){return 1e5*this.millisecond()})),H(0,["SSSSSSSSS",9],0,(function(){return 1e6*this.millisecond()})),F("millisecond","ms"),B("millisecond",16),he("S",ie,Z),he("SS",ie,Q),he("SSS",ie,ee),fn="SSSS";fn.length<=9;fn+="S")he(fn,le);function _n(e,t){t[6]=q(1e3*("0."+e))}for(fn="S";fn.length<=9;fn+="S")ve(fn,_n);hn=J("Milliseconds",!1),H("z",0,0,"zoneAbbr"),H("zz",0,0,"zoneName");var yn=w.prototype;function gn(e){return e}yn.add=qt,yn.calendar=function(e,t){1===arguments.length&&(arguments[0]?$t(arguments[0])?(e=arguments[0],t=void 0):Xt(arguments[0])&&(t=arguments[0],e=void 0):(e=void 0,t=void 0));var n=e||xt(),r=It(n,this).startOf("day"),o=a.calendarFormat(this,r)||"sameElse",i=t&&(S(t[o])?t[o].call(this,n):t[o]);return this.format(i||this.localeData().calendar(o,this,xt(n)))},yn.clone=function(){return new w(this)},yn.diff=function(e,t,n){var r,a,o;if(!this.isValid())return NaN;if(!(r=It(e,this)).isValid())return NaN;switch(a=6e4*(r.utcOffset()-this.utcOffset()),t=z(t)){case"year":o=Zt(this,r)/12;break;case"month":o=Zt(this,r);break;case"quarter":o=Zt(this,r)/3;break;case"second":o=(this-r)/1e3;break;case"minute":o=(this-r)/6e4;break;case"hour":o=(this-r)/36e5;break;case"day":o=(this-r-a)/864e5;break;case"week":o=(this-r-a)/6048e5;break;default:o=this-r}return n?o:G(o)},yn.endOf=function(e){var t,n;if(void 0===(e=z(e))||"millisecond"===e||!this.isValid())return this;switch(n=this._isUTC?an:rn,e){case"year":t=n(this.year()+1,0,1)-1;break;case"quarter":t=n(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":t=n(this.year(),this.month()+1,1)-1;break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":t=n(this.year(),this.month(),this.date()+1)-1;break;case"hour":t=this._d.valueOf(),t+=36e5-nn(t+(this._isUTC?0:6e4*this.utcOffset()),36e5)-1;break;case"minute":t=this._d.valueOf(),t+=6e4-nn(t,6e4)-1;break;case"second":t=this._d.valueOf(),t+=1e3-nn(t,1e3)-1}return this._d.setTime(t),a.updateOffset(this,!0),this},yn.format=function(e){e||(e=this.isUtc()?a.defaultFormatUtc:a.defaultFormat);var t=I(this,e);return this.localeData().postformat(t)},yn.from=function(e,t){return this.isValid()&&(M(e)&&e.isValid()||xt(e).isValid())?Ut({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},yn.fromNow=function(e){return this.from(xt(),e)},yn.to=function(e,t){return this.isValid()&&(M(e)&&e.isValid()||xt(e).isValid())?Ut({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},yn.toNow=function(e){return this.to(xt(),e)},yn.get=function(e){return S(this[e=z(e)])?this[e]():this},yn.invalidAt=function(){return m(this).overflow},yn.isAfter=function(e,t){var n=M(e)?e:xt(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=z(t)||"millisecond")?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(t).valueOf())},yn.isBefore=function(e,t){var n=M(e)?e:xt(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=z(t)||"millisecond")?this.valueOf()<n.valueOf():this.clone().endOf(t).valueOf()<n.valueOf())},yn.isBetween=function(e,t,n,r){var a=M(e)?e:xt(e),o=M(t)?t:xt(t);return!!(this.isValid()&&a.isValid()&&o.isValid())&&(("("===(r=r||"()")[0]?this.isAfter(a,n):!this.isBefore(a,n))&&(")"===r[1]?this.isBefore(o,n):!this.isAfter(o,n)))},yn.isSame=function(e,t){var n,r=M(e)?e:xt(e);return!(!this.isValid()||!r.isValid())&&("millisecond"===(t=z(t)||"millisecond")?this.valueOf()===r.valueOf():(n=r.valueOf(),this.clone().startOf(t).valueOf()<=n&&n<=this.clone().endOf(t).valueOf()))},yn.isSameOrAfter=function(e,t){return this.isSame(e,t)||this.isAfter(e,t)},yn.isSameOrBefore=function(e,t){return this.isSame(e,t)||this.isBefore(e,t)},yn.isValid=function(){return _(this)},yn.lang=en,yn.locale=Qt,yn.localeData=tn,yn.max=St,yn.min=Et,yn.parsingFlags=function(){return f({},m(this))},yn.set=function(e,t){if("object"==typeof e){var n,r=function(e){var t,n=[];for(t in e)s(e,t)&&n.push({unit:t,priority:W[t]});return n.sort((function(e,t){return e.priority-t.priority})),n}(e=U(e));for(n=0;n<r.length;n++)this[r[n].unit](e[r[n].unit])}else if(S(this[e=z(e)]))return this[e](t);return this},yn.startOf=function(e){var t,n;if(void 0===(e=z(e))||"millisecond"===e||!this.isValid())return this;switch(n=this._isUTC?an:rn,e){case"year":t=n(this.year(),0,1);break;case"quarter":t=n(this.year(),this.month()-this.month()%3,1);break;case"month":t=n(this.year(),this.month(),1);break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":t=n(this.year(),this.month(),this.date());break;case"hour":t=this._d.valueOf(),t-=nn(t+(this._isUTC?0:6e4*this.utcOffset()),36e5);break;case"minute":t=this._d.valueOf(),t-=nn(t,6e4);break;case"second":t=this._d.valueOf(),t-=nn(t,1e3)}return this._d.setTime(t),a.updateOffset(this,!0),this},yn.subtract=Jt,yn.toArray=function(){var e=this;return[e.year(),e.month(),e.date(),e.hour(),e.minute(),e.second(),e.millisecond()]},yn.toObject=function(){var e=this;return{years:e.year(),months:e.month(),date:e.date(),hours:e.hours(),minutes:e.minutes(),seconds:e.seconds(),milliseconds:e.milliseconds()}},yn.toDate=function(){return new Date(this.valueOf())},yn.toISOString=function(e){if(!this.isValid())return null;var t=!0!==e,n=t?this.clone().utc():this;return n.year()<0||n.year()>9999?I(n,t?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):S(Date.prototype.toISOString)?t?this.toDate().toISOString():new Date(this.valueOf()+60*this.utcOffset()*1e3).toISOString().replace("Z",I(n,"Z")):I(n,t?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")},yn.inspect=function(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var e,t,n,r="moment",a="";return this.isLocal()||(r=0===this.utcOffset()?"moment.utc":"moment.parseZone",a="Z"),e="["+r+'("]',t=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",n=a+'[")]',this.format(e+t+"-MM-DD[T]HH:mm:ss.SSS"+n)},"undefined"!=typeof Symbol&&null!=Symbol.for&&(yn[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"}),yn.toJSON=function(){return this.isValid()?this.toISOString():null},yn.toString=function(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},yn.unix=function(){return Math.floor(this.valueOf()/1e3)},yn.valueOf=function(){return this._d.valueOf()-6e4*(this._offset||0)},yn.creationData=function(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}},yn.eraName=function(){var e,t,n,r=this.localeData().eras();for(e=0,t=r.length;e<t;++e){if(n=this.clone().startOf("day").valueOf(),r[e].since<=n&&n<=r[e].until)return r[e].name;if(r[e].until<=n&&n<=r[e].since)return r[e].name}return""},yn.eraNarrow=function(){var e,t,n,r=this.localeData().eras();for(e=0,t=r.length;e<t;++e){if(n=this.clone().startOf("day").valueOf(),r[e].since<=n&&n<=r[e].until)return r[e].narrow;if(r[e].until<=n&&n<=r[e].since)return r[e].narrow}return""},yn.eraAbbr=function(){var e,t,n,r=this.localeData().eras();for(e=0,t=r.length;e<t;++e){if(n=this.clone().startOf("day").valueOf(),r[e].since<=n&&n<=r[e].until)return r[e].abbr;if(r[e].until<=n&&n<=r[e].since)return r[e].abbr}return""},yn.eraYear=function(){var e,t,n,r,o=this.localeData().eras();for(e=0,t=o.length;e<t;++e)if(n=o[e].since<=o[e].until?1:-1,r=this.clone().startOf("day").valueOf(),o[e].since<=r&&r<=o[e].until||o[e].until<=r&&r<=o[e].since)return(this.year()-a(o[e].since).year())*n+o[e].offset;return this.year()},yn.year=Ce,yn.isLeapYear=function(){return V(this.year())},yn.weekYear=function(e){return ln.call(this,e,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)},yn.isoWeekYear=function(e){return ln.call(this,e,this.isoWeek(),this.isoWeekday(),1,4)},yn.quarter=yn.quarters=function(e){return null==e?Math.ceil((this.month()+1)/3):this.month(3*(e-1)+this.month()%3)},yn.month=De,yn.daysInMonth=function(){return Me(this.year(),this.month())},yn.week=yn.weeks=function(e){var t=this.localeData().week(this);return null==e?t:this.add(7*(e-t),"d")},yn.isoWeek=yn.isoWeeks=function(e){var t=Ne(this,1,4).week;return null==e?t:this.add(7*(e-t),"d")},yn.weeksInYear=function(){var e=this.localeData()._week;return Re(this.year(),e.dow,e.doy)},yn.weeksInWeekYear=function(){var e=this.localeData()._week;return Re(this.weekYear(),e.dow,e.doy)},yn.isoWeeksInYear=function(){return Re(this.year(),1,4)},yn.isoWeeksInISOWeekYear=function(){return Re(this.isoWeekYear(),1,4)},yn.date=dn,yn.day=yn.days=function(e){if(!this.isValid())return null!=e?this:NaN;var t=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=e?(e=function(e,t){return"string"!=typeof e?e:isNaN(e)?"number"==typeof(e=t.weekdaysParse(e))?e:null:parseInt(e,10)}(e,this.localeData()),this.add(e-t,"d")):t},yn.weekday=function(e){if(!this.isValid())return null!=e?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return null==e?t:this.add(e-t,"d")},yn.isoWeekday=function(e){if(!this.isValid())return null!=e?this:NaN;if(null!=e){var t=function(e,t){return"string"==typeof e?t.weekdaysParse(e)%7||7:isNaN(e)?null:e}(e,this.localeData());return this.day(this.day()%7?t:t-7)}return this.day()||7},yn.dayOfYear=function(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==e?t:this.add(e-t,"d")},yn.hour=yn.hours=Qe,yn.minute=yn.minutes=pn,yn.second=yn.seconds=mn,yn.millisecond=yn.milliseconds=hn,yn.utcOffset=function(e,t,n){var r,o=this._offset||0;if(!this.isValid())return null!=e?this:NaN;if(null!=e){if("string"==typeof e){if(null===(e=Ht(pe,e)))return this}else Math.abs(e)<16&&!n&&(e*=60);return!this._isUTC&&t&&(r=Nt(this)),this._offset=e,this._isUTC=!0,null!=r&&this.add(r,"m"),o!==e&&(!t||this._changeInProgress?Gt(this,Ut(e-o,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,a.updateOffset(this,!0),this._changeInProgress=null)),this}return this._isUTC?o:Nt(this)},yn.utc=function(e){return this.utcOffset(0,e)},yn.local=function(e){return this._isUTC&&(this.utcOffset(0,e),this._isUTC=!1,e&&this.subtract(Nt(this),"m")),this},yn.parseZone=function(){if(null!=this._tzm)this.utcOffset(this._tzm,!1,!0);else if("string"==typeof this._i){var e=Ht(de,this._i);null!=e?this.utcOffset(e):this.utcOffset(0,!0)}return this},yn.hasAlignedHourOffset=function(e){return!!this.isValid()&&(e=e?xt(e).utcOffset():0,(this.utcOffset()-e)%60==0)},yn.isDST=function(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()},yn.isLocal=function(){return!!this.isValid()&&!this._isUTC},yn.isUtcOffset=function(){return!!this.isValid()&&this._isUTC},yn.isUtc=Rt,yn.isUTC=Rt,yn.zoneAbbr=function(){return this._isUTC?"UTC":""},yn.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""},yn.dates=T("dates accessor is deprecated. Use date instead.",dn),yn.months=T("months accessor is deprecated. Use month instead",De),yn.years=T("years accessor is deprecated. Use year instead",Ce),yn.zone=T("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",(function(e,t){return null!=e?("string"!=typeof e&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()})),yn.isDSTShifted=T("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",(function(){if(!l(this._isDSTShifted))return this._isDSTShifted;var e,t={};return b(t,this),(t=Tt(t))._a?(e=t._isUTC?h(t._a):xt(t._a),this._isDSTShifted=this.isValid()&&function(e,t,n){var r,a=Math.min(e.length,t.length),o=Math.abs(e.length-t.length),i=0;for(r=0;r<a;r++)(n&&e[r]!==t[r]||!n&&q(e[r])!==q(t[r]))&&i++;return i+o}(t._a,e.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted}));var vn=D.prototype;function bn(e,t,n,r){var a=ut(),o=h().set(r,t);return a[n](o,e)}function wn(e,t,n){if(c(e)&&(t=e,e=void 0),e=e||"",null!=t)return bn(e,t,n,"month");var r,a=[];for(r=0;r<12;r++)a[r]=bn(e,r,n,"month");return a}function Mn(e,t,n,r){"boolean"==typeof e?(c(t)&&(n=t,t=void 0),t=t||""):(n=t=e,e=!1,c(t)&&(n=t,t=void 0),t=t||"");var a,o=ut(),i=e?o._week.dow:0,s=[];if(null!=n)return bn(t,(n+i)%7,r,"day");for(a=0;a<7;a++)s[a]=bn(t,(a+i)%7,r,"day");return s}vn.calendar=function(e,t,n){var r=this._calendar[e]||this._calendar.sameElse;return S(r)?r.call(t,n):r},vn.longDateFormat=function(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.match(A).map((function(e){return"MMMM"===e||"MM"===e||"DD"===e||"dddd"===e?e.slice(1):e})).join(""),this._longDateFormat[e])},vn.invalidDate=function(){return this._invalidDate},vn.ordinal=function(e){return this._ordinal.replace("%d",e)},vn.preparse=gn,vn.postformat=gn,vn.relativeTime=function(e,t,n,r){var a=this._relativeTime[n];return S(a)?a(e,t,n,r):a.replace(/%d/i,e)},vn.pastFuture=function(e,t){var n=this._relativeTime[e>0?"future":"past"];return S(n)?n(t):n.replace(/%s/i,t)},vn.set=function(e){var t,n;for(n in e)s(e,n)&&(S(t=e[n])?this[n]=t:this["_"+n]=t);this._config=e,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)},vn.eras=function(e,t){var n,r,o,i=this._eras||ut("en")._eras;for(n=0,r=i.length;n<r;++n){switch(typeof i[n].since){case"string":o=a(i[n].since).startOf("day"),i[n].since=o.valueOf()}switch(typeof i[n].until){case"undefined":i[n].until=1/0;break;case"string":o=a(i[n].until).startOf("day").valueOf(),i[n].until=o.valueOf()}}return i},vn.erasParse=function(e,t,n){var r,a,o,i,s,u=this.eras();for(e=e.toUpperCase(),r=0,a=u.length;r<a;++r)if(o=u[r].name.toUpperCase(),i=u[r].abbr.toUpperCase(),s=u[r].narrow.toUpperCase(),n)switch(t){case"N":case"NN":case"NNN":if(i===e)return u[r];break;case"NNNN":if(o===e)return u[r];break;case"NNNNN":if(s===e)return u[r]}else if([o,i,s].indexOf(e)>=0)return u[r]},vn.erasConvertYear=function(e,t){var n=e.since<=e.until?1:-1;return void 0===t?a(e.since).year():a(e.since).year()+(t-e.offset)*n},vn.erasAbbrRegex=function(e){return s(this,"_erasAbbrRegex")||sn.call(this),e?this._erasAbbrRegex:this._erasRegex},vn.erasNameRegex=function(e){return s(this,"_erasNameRegex")||sn.call(this),e?this._erasNameRegex:this._erasRegex},vn.erasNarrowRegex=function(e){return s(this,"_erasNarrowRegex")||sn.call(this),e?this._erasNarrowRegex:this._erasRegex},vn.months=function(e,t){return e?o(this._months)?this._months[e.month()]:this._months[(this._months.isFormat||ke).test(t)?"format":"standalone"][e.month()]:o(this._months)?this._months:this._months.standalone},vn.monthsShort=function(e,t){return e?o(this._monthsShort)?this._monthsShort[e.month()]:this._monthsShort[ke.test(t)?"format":"standalone"][e.month()]:o(this._monthsShort)?this._monthsShort:this._monthsShort.standalone},vn.monthsParse=function(e,t,n){var r,a,o;if(this._monthsParseExact)return Se.call(this,e,t,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),r=0;r<12;r++){if(a=h([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(a,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(a,"").replace(".","")+"$","i")),n||this._monthsParse[r]||(o="^"+this.months(a,"")+"|^"+this.monthsShort(a,""),this._monthsParse[r]=new RegExp(o.replace(".",""),"i")),n&&"MMMM"===t&&this._longMonthsParse[r].test(e))return r;if(n&&"MMM"===t&&this._shortMonthsParse[r].test(e))return r;if(!n&&this._monthsParse[r].test(e))return r}},vn.monthsRegex=function(e){return this._monthsParseExact?(s(this,"_monthsRegex")||Ye.call(this),e?this._monthsStrictRegex:this._monthsRegex):(s(this,"_monthsRegex")||(this._monthsRegex=Ee),this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex)},vn.monthsShortRegex=function(e){return this._monthsParseExact?(s(this,"_monthsRegex")||Ye.call(this),e?this._monthsShortStrictRegex:this._monthsShortRegex):(s(this,"_monthsShortRegex")||(this._monthsShortRegex=xe),this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex)},vn.week=function(e){return Ne(e,this._week.dow,this._week.doy).week},vn.firstDayOfYear=function(){return this._week.doy},vn.firstDayOfWeek=function(){return this._week.dow},vn.weekdays=function(e,t){var n=o(this._weekdays)?this._weekdays:this._weekdays[e&&!0!==e&&this._weekdays.isFormat.test(t)?"format":"standalone"];return!0===e?Fe(n,this._week.dow):e?n[e.day()]:n},vn.weekdaysMin=function(e){return!0===e?Fe(this._weekdaysMin,this._week.dow):e?this._weekdaysMin[e.day()]:this._weekdaysMin},vn.weekdaysShort=function(e){return!0===e?Fe(this._weekdaysShort,this._week.dow):e?this._weekdaysShort[e.day()]:this._weekdaysShort},vn.weekdaysParse=function(e,t,n){var r,a,o;if(this._weekdaysParseExact)return qe.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),r=0;r<7;r++){if(a=h([2e3,1]).day(r),n&&!this._fullWeekdaysParse[r]&&(this._fullWeekdaysParse[r]=new RegExp("^"+this.weekdays(a,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[r]=new RegExp("^"+this.weekdaysShort(a,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[r]=new RegExp("^"+this.weekdaysMin(a,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[r]||(o="^"+this.weekdays(a,"")+"|^"+this.weekdaysShort(a,"")+"|^"+this.weekdaysMin(a,""),this._weekdaysParse[r]=new RegExp(o.replace(".",""),"i")),n&&"dddd"===t&&this._fullWeekdaysParse[r].test(e))return r;if(n&&"ddd"===t&&this._shortWeekdaysParse[r].test(e))return r;if(n&&"dd"===t&&this._minWeekdaysParse[r].test(e))return r;if(!n&&this._weekdaysParse[r].test(e))return r}},vn.weekdaysRegex=function(e){return this._weekdaysParseExact?(s(this,"_weekdaysRegex")||Je.call(this),e?this._weekdaysStrictRegex:this._weekdaysRegex):(s(this,"_weekdaysRegex")||(this._weekdaysRegex=Be),this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex)},vn.weekdaysShortRegex=function(e){return this._weekdaysParseExact?(s(this,"_weekdaysRegex")||Je.call(this),e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(s(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=Ve),this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)},vn.weekdaysMinRegex=function(e){return this._weekdaysParseExact?(s(this,"_weekdaysRegex")||Je.call(this),e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(s(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=Ge),this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)},vn.isPM=function(e){return"p"===(e+"").toLowerCase().charAt(0)},vn.meridiem=function(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"},it("en",{eras:[{since:"0001-01-01",until:1/0,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10;return e+(1===q(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")}}),a.lang=T("moment.lang is deprecated. Use moment.locale instead.",it),a.langData=T("moment.langData is deprecated. Use moment.localeData instead.",ut);var Ln=Math.abs;function Tn(e,t,n,r){var a=Ut(t,n);return e._milliseconds+=r*a._milliseconds,e._days+=r*a._days,e._months+=r*a._months,e._bubble()}function kn(e){return e<0?Math.floor(e):Math.ceil(e)}function xn(e){return 4800*e/146097}function En(e){return 146097*e/4800}function Sn(e){return function(){return this.as(e)}}var On=Sn("ms"),Dn=Sn("s"),Yn=Sn("m"),An=Sn("h"),Cn=Sn("d"),jn=Sn("w"),Pn=Sn("M"),Hn=Sn("Q"),In=Sn("y");function Nn(e){return function(){return this.isValid()?this._data[e]:NaN}}var Rn=Nn("milliseconds"),Fn=Nn("seconds"),zn=Nn("minutes"),Un=Nn("hours"),Wn=Nn("days"),Bn=Nn("months"),Vn=Nn("years"),Gn=Math.round,qn={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function Jn(e,t,n,r,a){return a.relativeTime(t||1,!!n,e,r)}var Kn=Math.abs;function $n(e){return(e>0)-(e<0)||+e}function Xn(){if(!this.isValid())return this.localeData().invalidDate();var e,t,n,r,a,o,i,s,u=Kn(this._milliseconds)/1e3,l=Kn(this._days),c=Kn(this._months),d=this.asSeconds();return d?(e=G(u/60),t=G(e/60),u%=60,e%=60,n=G(c/12),c%=12,r=u?u.toFixed(3).replace(/\.?0+$/,""):"",a=d<0?"-":"",o=$n(this._months)!==$n(d)?"-":"",i=$n(this._days)!==$n(d)?"-":"",s=$n(this._milliseconds)!==$n(d)?"-":"",a+"P"+(n?o+n+"Y":"")+(c?o+c+"M":"")+(l?i+l+"D":"")+(t||e||u?"T":"")+(t?s+t+"H":"")+(e?s+e+"M":"")+(u?s+r+"S":"")):"P0D"}var Zn=Yt.prototype;return Zn.isValid=function(){return this._isValid},Zn.abs=function(){var e=this._data;return this._milliseconds=Ln(this._milliseconds),this._days=Ln(this._days),this._months=Ln(this._months),e.milliseconds=Ln(e.milliseconds),e.seconds=Ln(e.seconds),e.minutes=Ln(e.minutes),e.hours=Ln(e.hours),e.months=Ln(e.months),e.years=Ln(e.years),this},Zn.add=function(e,t){return Tn(this,e,t,1)},Zn.subtract=function(e,t){return Tn(this,e,t,-1)},Zn.as=function(e){if(!this.isValid())return NaN;var t,n,r=this._milliseconds;if("month"===(e=z(e))||"quarter"===e||"year"===e)switch(t=this._days+r/864e5,n=this._months+xn(t),e){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(t=this._days+Math.round(En(this._months)),e){case"week":return t/7+r/6048e5;case"day":return t+r/864e5;case"hour":return 24*t+r/36e5;case"minute":return 1440*t+r/6e4;case"second":return 86400*t+r/1e3;case"millisecond":return Math.floor(864e5*t)+r;default:throw new Error("Unknown unit "+e)}},Zn.asMilliseconds=On,Zn.asSeconds=Dn,Zn.asMinutes=Yn,Zn.asHours=An,Zn.asDays=Cn,Zn.asWeeks=jn,Zn.asMonths=Pn,Zn.asQuarters=Hn,Zn.asYears=In,Zn.valueOf=function(){return this.isValid()?this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*q(this._months/12):NaN},Zn._bubble=function(){var e,t,n,r,a,o=this._milliseconds,i=this._days,s=this._months,u=this._data;return o>=0&&i>=0&&s>=0||o<=0&&i<=0&&s<=0||(o+=864e5*kn(En(s)+i),i=0,s=0),u.milliseconds=o%1e3,e=G(o/1e3),u.seconds=e%60,t=G(e/60),u.minutes=t%60,n=G(t/60),u.hours=n%24,i+=G(n/24),a=G(xn(i)),s+=a,i-=kn(En(a)),r=G(s/12),s%=12,u.days=i,u.months=s,u.years=r,this},Zn.clone=function(){return Ut(this)},Zn.get=function(e){return e=z(e),this.isValid()?this[e+"s"]():NaN},Zn.milliseconds=Rn,Zn.seconds=Fn,Zn.minutes=zn,Zn.hours=Un,Zn.days=Wn,Zn.weeks=function(){return G(this.days()/7)},Zn.months=Bn,Zn.years=Vn,Zn.humanize=function(e,t){if(!this.isValid())return this.localeData().invalidDate();var n,r,a=!1,o=qn;return"object"==typeof e&&(t=e,e=!1),"boolean"==typeof e&&(a=e),"object"==typeof t&&(o=Object.assign({},qn,t),null!=t.s&&null==t.ss&&(o.ss=t.s-1)),n=this.localeData(),r=function(e,t,n,r){var a=Ut(e).abs(),o=Gn(a.as("s")),i=Gn(a.as("m")),s=Gn(a.as("h")),u=Gn(a.as("d")),l=Gn(a.as("M")),c=Gn(a.as("w")),d=Gn(a.as("y")),p=o<=n.ss&&["s",o]||o<n.s&&["ss",o]||i<=1&&["m"]||i<n.m&&["mm",i]||s<=1&&["h"]||s<n.h&&["hh",s]||u<=1&&["d"]||u<n.d&&["dd",u];return null!=n.w&&(p=p||c<=1&&["w"]||c<n.w&&["ww",c]),(p=p||l<=1&&["M"]||l<n.M&&["MM",l]||d<=1&&["y"]||["yy",d])[2]=t,p[3]=+e>0,p[4]=r,Jn.apply(null,p)}(this,!a,o,n),a&&(r=n.pastFuture(+this,r)),n.postformat(r)},Zn.toISOString=Xn,Zn.toString=Xn,Zn.toJSON=Xn,Zn.locale=Qt,Zn.localeData=tn,Zn.toIsoString=T("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Xn),Zn.lang=en,H("X",0,0,"unix"),H("x",0,0,"valueOf"),he("x",ce),he("X",/[+-]?\d+(\.\d{1,3})?/),ve("X",(function(e,t,n){n._d=new Date(1e3*parseFloat(e))})),ve("x",(function(e,t,n){n._d=new Date(q(e))})),
2
2
  //! moment.js
3
- a.version="2.29.1",t=xt,a.fn=yn,a.min=function(){var e=[].slice.call(arguments,0);return Ot("isBefore",e)},a.max=function(){var e=[].slice.call(arguments,0);return Ot("isAfter",e)},a.now=function(){return Date.now?Date.now():+new Date},a.utc=h,a.unix=function(e){return xt(1e3*e)},a.months=function(e,t){return wn(e,t,"months")},a.isDate=d,a.locale=it,a.invalid=y,a.duration=Ut,a.isMoment=M,a.weekdays=function(e,t,n){return Mn(e,t,n,"weekdays")},a.parseZone=function(){return xt.apply(null,arguments).parseZone()},a.localeData=ut,a.isDuration=At,a.monthsShort=function(e,t){return wn(e,t,"monthsShort")},a.weekdaysMin=function(e,t,n){return Mn(e,t,n,"weekdaysMin")},a.defineLocale=st,a.updateLocale=function(e,t){if(null!=t){var n,r,a=et;null!=tt[e]&&null!=tt[e].parentLocale?tt[e].set(O(tt[e]._config,t)):(null!=(r=ot(e))&&(a=r._config),t=O(a,t),null==r&&(t.abbr=e),(n=new D(t)).parentLocale=tt[e],tt[e]=n),it(e)}else null!=tt[e]&&(null!=tt[e].parentLocale?(tt[e]=tt[e].parentLocale,e===it()&&it(e)):null!=tt[e]&&delete tt[e]);return tt[e]},a.locales=function(){return k(tt)},a.weekdaysShort=function(e,t,n){return Mn(e,t,n,"weekdaysShort")},a.normalizeUnits=z,a.relativeTimeRounding=function(e){return void 0===e?Gn:"function"==typeof e&&(Gn=e,!0)},a.relativeTimeThreshold=function(e,t){return void 0!==qn[e]&&(void 0===t?qn[e]:(qn[e]=t,"s"===e&&(qn.ss=t-1),!0))},a.calendarFormat=function(e,t){var n=e.diff(t,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"},a.prototype=yn,a.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},a}()}).call(this,n(42)(e))},function(e,t,n){e.exports=n(365)()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ReactCSS=t.loop=t.handleActive=t.handleHover=t.hover=void 0;var r=l(n(368)),a=l(n(444)),o=l(n(470)),i=l(n(471)),s=l(n(472)),u=l(n(473));function l(e){return e&&e.__esModule?e:{default:e}}t.hover=i.default,t.handleHover=i.default,t.handleActive=s.default,t.loop=u.default;var c=t.ReactCSS=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];var s=(0,r.default)(n),u=(0,a.default)(e,s);return(0,o.default)(u)};t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ICON_FILE_CODE=t.ICON_CUBE=t.ICON_LAYER_GROUP=t.ICON_EXPAND_ARROWS=t.ICON_EXPAND=t.ICON_COMPRESS=t.ICON_ARROW_RIGHT=t.ICON_ARROW_CENTER_H=t.ICON_ARROW_LEFT=t.ICON_ARROW_DOWN=t.ICON_ARROW_CENTER_V=t.ICON_ARROW_UP=t.ICON_BARS=t.ICON_ALIGN_CENTER=t.ICON_ALIGN_RIGHT=t.ICON_ALIGN_LEFT=t.ICON_FONT=t.ICON_INFO_CIRCLE=t.ICON_TIMES_CIRCLE=t.SORT_DOWN=t.SORT_UP=t.ICON_BAN=t.ICON_USER_LOCK=t.ICON_CHEVRON_UP=t.ICON_CHEVRON_DOWN=t.ICON_ANGLE_DOUBLE_RIGHT=t.ICON_ANGLE_RIGHT=t.ICON_ANGLE_DOUBLE_LEFT=t.ICON_ANGLE_LEFT=t.ICON_EXCLAIMATION_TRIANGLE=t.ICON_CLIPBOARD=t.ICON_PLUS=t.ICON_SEARCH=t.ICON_EDIT=t.ICON_CHECK=t.ICON_CARET_DOWN=t.ICON_CARET_UP=t.ICON_CIRCLE_NOTCH=t.ICON_TIMES=t.ICON_COPY=t.ICON_AUDIO_TYPE=t.ICON_IMAGE_SEQ_TYPE=t.ICON_FILE_ARCHIVE=t.ICON_FILE_IMAGE=t.ICON_FILE_AUDIO=t.ICON_FILE_VIDEO=t.ICON_FILTER=t.ICON_STICKY_NOTE=t.ICON_IMAGE=t.ICON_VIDEO=void 0,t.ICON_UPLOAD=t.ICON_DOWNLOAD=t.ICON_JS=t.ICON_PROJECT_DIAGRAM=t.ICON_GLOBE=t.ICON_EMAIL=t.ICON_HUBSPOT=t.ICON_HELP=void 0;var r=n(0),a=n(37),o=n(290),i=n(291),s=n(292),u=n(293),l=n(294),c=n(94),d=n(295),p=n(296),f=n(297),h=n(298),m=n(299),_=n(300),y=n(301),g=n(302),v=n(303),b=n(58),w=n(304),M=n(305),L=n(306),T=n(307),k=n(308),x=n(309),E=n(57),S=n(95),O=n(310),D=n(311),Y=n(312),A=n(313),C=n(314),j=n(315),P=n(316),H=n(317),I=n(96),N=n(318),R=n(319),F=n(320),z=n(321),U=n(322),W=n(323),B=n(324),V=n(325),G=n(326),q=n(327),J=n(328),K=n(329),$=n(330),X=n(331),Z=n(332),Q=n(333),ee=n(334),te=n(335),ne=n(336),re=n(337),ae=n(338),oe=n(339),ie=n(340),se=n(341),ue=n(342);t.ICON_VIDEO=r.createElement(a.FontAwesomeIcon,{icon:S.faVideo}),t.ICON_IMAGE=r.createElement(a.FontAwesomeIcon,{icon:O.faImage}),t.ICON_STICKY_NOTE=r.createElement(a.FontAwesomeIcon,{icon:D.faStickyNote}),t.ICON_FILTER=r.createElement(a.FontAwesomeIcon,{icon:u.faFilter}),t.ICON_FILE_VIDEO=r.createElement(a.FontAwesomeIcon,{icon:c.faFileVideo}),t.ICON_FILE_AUDIO=r.createElement(a.FontAwesomeIcon,{icon:d.faFileAudio}),t.ICON_FILE_IMAGE=r.createElement(a.FontAwesomeIcon,{icon:p.faFileImage}),t.ICON_FILE_ARCHIVE=r.createElement(a.FontAwesomeIcon,{icon:f.faFileArchive}),t.ICON_IMAGE_SEQ_TYPE=r.createElement(a.FontAwesomeIcon,{icon:A.faImages}),t.ICON_AUDIO_TYPE=r.createElement(a.FontAwesomeIcon,{icon:C.faHeadphones}),t.ICON_COPY=r.createElement(a.FontAwesomeIcon,{icon:h.faCopy}),t.ICON_TIMES=r.createElement(a.FontAwesomeIcon,{icon:m.faTimes}),t.ICON_CIRCLE_NOTCH=r.createElement(a.FontAwesomeIcon,{icon:l.faCircleNotch}),t.ICON_CARET_UP=r.createElement(a.FontAwesomeIcon,{icon:o.faCaretUp}),t.ICON_CARET_DOWN=r.createElement(a.FontAwesomeIcon,{icon:i.faCaretDown}),t.ICON_CHECK=r.createElement(a.FontAwesomeIcon,{icon:s.faCheck}),t.ICON_EDIT=r.createElement(a.FontAwesomeIcon,{icon:_.faEdit}),t.ICON_SEARCH=r.createElement(a.FontAwesomeIcon,{icon:y.faSearch}),t.ICON_PLUS=r.createElement(a.FontAwesomeIcon,{icon:g.faPlus}),t.ICON_CLIPBOARD=r.createElement(a.FontAwesomeIcon,{icon:v.faClipboard}),t.ICON_EXCLAIMATION_TRIANGLE=r.createElement(a.FontAwesomeIcon,{icon:b.faExclamationTriangle}),t.ICON_ANGLE_LEFT=r.createElement(a.FontAwesomeIcon,{icon:w.faAngleLeft}),t.ICON_ANGLE_DOUBLE_LEFT=r.createElement(a.FontAwesomeIcon,{icon:M.faAngleDoubleLeft}),t.ICON_ANGLE_RIGHT=r.createElement(a.FontAwesomeIcon,{icon:L.faAngleRight}),t.ICON_ANGLE_DOUBLE_RIGHT=r.createElement(a.FontAwesomeIcon,{icon:T.faAngleDoubleRight}),t.ICON_CHEVRON_DOWN=r.createElement(a.FontAwesomeIcon,{icon:k.faChevronDown}),t.ICON_CHEVRON_UP=r.createElement(a.FontAwesomeIcon,{icon:x.faChevronUp}),t.ICON_USER_LOCK=r.createElement(a.FontAwesomeIcon,{icon:E.faUserLock}),t.ICON_BAN=r.createElement(a.FontAwesomeIcon,{icon:Y.faBan}),t.SORT_UP=r.createElement(a.FontAwesomeIcon,{icon:j.faSortUp}),t.SORT_DOWN=r.createElement(a.FontAwesomeIcon,{icon:P.faSortDown}),t.ICON_TIMES_CIRCLE=r.createElement(a.FontAwesomeIcon,{icon:H.faTimesCircle}),t.ICON_INFO_CIRCLE=r.createElement(a.FontAwesomeIcon,{icon:I.faInfoCircle}),t.ICON_FONT=r.createElement(a.FontAwesomeIcon,{icon:N.faFont}),t.ICON_ALIGN_LEFT=r.createElement(a.FontAwesomeIcon,{icon:R.faAlignLeft}),t.ICON_ALIGN_RIGHT=r.createElement(a.FontAwesomeIcon,{icon:F.faAlignRight}),t.ICON_ALIGN_CENTER=r.createElement(a.FontAwesomeIcon,{icon:z.faAlignCenter}),t.ICON_BARS=r.createElement(a.FontAwesomeIcon,{icon:U.faBars}),t.ICON_ARROW_UP=r.createElement(a.FontAwesomeIcon,{icon:W.faArrowToTop}),t.ICON_ARROW_CENTER_V=r.createElement(a.FontAwesomeIcon,{icon:V.faArrowsV}),t.ICON_ARROW_DOWN=r.createElement(a.FontAwesomeIcon,{icon:B.faArrowToBottom}),t.ICON_ARROW_LEFT=r.createElement(a.FontAwesomeIcon,{icon:G.faArrowToLeft}),t.ICON_ARROW_CENTER_H=r.createElement(a.FontAwesomeIcon,{icon:J.faArrowsH}),t.ICON_ARROW_RIGHT=r.createElement(a.FontAwesomeIcon,{icon:q.faArrowToRight}),t.ICON_COMPRESS=r.createElement(a.FontAwesomeIcon,{icon:X.faCompress}),t.ICON_EXPAND=r.createElement(a.FontAwesomeIcon,{icon:$.faExpand}),t.ICON_EXPAND_ARROWS=r.createElement(a.FontAwesomeIcon,{icon:K.faExpandArrowsAlt}),t.ICON_LAYER_GROUP=r.createElement(a.FontAwesomeIcon,{icon:Z.faLayerGroup}),t.ICON_CUBE=r.createElement(a.FontAwesomeIcon,{icon:Q.faCube}),t.ICON_FILE_CODE=r.createElement(a.FontAwesomeIcon,{icon:ee.faFileCode}),t.ICON_HELP=r.createElement(a.FontAwesomeIcon,{icon:te.faQuestionCircle}),t.ICON_HUBSPOT=r.createElement(a.FontAwesomeIcon,{icon:ne.faHubspot}),t.ICON_EMAIL=r.createElement(a.FontAwesomeIcon,{icon:re.faEnvelope}),t.ICON_GLOBE=r.createElement(a.FontAwesomeIcon,{icon:ae.faGlobe}),t.ICON_PROJECT_DIAGRAM=r.createElement(a.FontAwesomeIcon,{icon:oe.faProjectDiagram}),t.ICON_JS=r.createElement(a.FontAwesomeIcon,{icon:ie.faJs}),t.ICON_DOWNLOAD=r.createElement(a.FontAwesomeIcon,{icon:se.faDownload}),t.ICON_UPLOAD=r.createElement(a.FontAwesomeIcon,{icon:ue.faUpload})},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(9),u=n(60),l=n(4),c=function(e){function t(t){var n=e.call(this,t)||this;return n.tooltipId="imposium-button-"+s.generateUUID(),n}return a(t,e),t.prototype.onClick=function(e){this.props.onClick&&!this.props.loading&&this.props.onClick(e)},t.prototype.render=function(){var e=this,t=this.props,n=t.style,r=t.color,a=t.size,s=t.customStyles,c=this.props,d=c.width,p=c.loading,f=(c.tooltip,this.props),h=f.active,m=f.disabled,_=f.buttonRef,y=h?"active":"",g=m?"disabled":"";a||(a=""),n||(n="default"),r||(r=""),d&&(s?s.width=d:s={width:d});var v=p?i.createElement("span",{className:"loading-icon"},l.ICON_CIRCLE_NOTCH):this.props.children;return i.createElement("div",o({},u.renderTooltipProps(this.tooltipId,this.props.tooltip),{ref:_,className:"imposium-btn btn-"+n+" "+a+" "+r+" "+y+" "+g,onClick:function(t){return e.onClick(t)},style:s}),v,u.renderTooltip(this.tooltipId,this.props.tooltip))},t}(i.PureComponent);t.default=c},function(e,t,n){"use strict";var r=n(56),a="object"==typeof self&&self&&self.Object===Object&&self,o=r.a||a||Function("return this")();t.a=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BATCHES_COPY=t.project=t.header=t.integration=t.publish=t.compositions=t.previewer=t.assets=void 0,t.assets={tooltipFilter:"Filter by Asset type",previewNotAvailable:"Preview Not Available for this Asset Type",iconTypes:{filter:"Filter By Type",lut:"LUT",all:"All Types",video:"Video Files",audio:"Audio Files",video_composition:"Composition",image:"Image Files",image_sequence:"Image Sequences (Archive)",template:"Custom Template",static_composition:"Template",font:"Font Files"},uploads:{noUploads:"There are currently no assets uploading...",preparePhase:"Preparing asset...",autoTagInput:"Tag by filename",assignToStoryInput:"Assign to Story",assignToStoryInfo:"If selected, any assets uploaded will only be available to use with the currently selected story.",uploadButton:"Upload"},tags:{add:"Add new tag"},field:{fieldMismatchError:'Asset Type mismatch. Field only accepts "[accepts]" assets.',dragPrompt:"Drag Asset Here",tooltipClear:"Clear the selected Asset",tooltipFilter:"Filter assets to match Asset type"},details:"Asset Details",newDetails:"New Asset Details",name:"Name",date:"Date Created",addTag:"Add Tag",assetTag:"Tags",sessionExpired:"Your session has expired, please log in again to continue."},t.previewer={previewVars:"Preview Variables",time:"Time Elapsed:",expRunning:"Rendering Experience",runExpStart:"Creating Experience",runExpError:"Error running experience - ID: [expId]",triggerExpError:"Error triggering experience - ID: [expId]",expId:"Running Experience - ID: [expId]",createExpError:"Error creating experience",logDownloadError:"Could not download log of Job: [jobId]",logURLError:"Could not retrieve log URL of Job: [jobId]",btnLog:"Job Log",btnRender:"Render",btnReRender:"Re-Render",expIdField:"Exp. ID",runExpErrorDes:"Sorry, there was a problem creating your video. Please try again."},t.compositions={name:"Name",width:"Width",height:"Height",rotation:"Rotation",color:"Color",x:"X",y:"Y",wrap:"Wrap",fit:"Fit",fillMode:"Fill Mode",hAlign:"H. Align",vAlign:"V. Align",backgroundColor:"Background",layers:"Layers",layerText:"Text",fontType:"Font Type",layerImage:"Image",fontSize:"Font Size",lineHeight:"Line Height",font:"Font",letterSpacing:"Letter Spacing",wordSpacing:"Word Spacing",tooltipName:"Display name of this composition.",tooltipBackgroundColor:"Background color of this composition. Can also be transparent.",tooltipWidth:"Width of the composition, in pixels",tooltipHeight:"Height of the composition, in pixels",tooltipAddLayer:"Add a new layer to the composition",tooltipLayerRotation:"Rotation angle of the layer, in degrees",tooltipLayerX:"Layer X position.",tooltipLayerY:"Layer Y position",tooltipLayerWidth:"Layer width, in pixels.",tooltipLayerHeight:"Layer height, in pixels",textOptions:"Text Options",textLayerContent:"Content",tooltipTextLayerContent:"The copy rendered in this layer. Wrap variables like so: {{variable_id}}."},t.publish={accessKey:"Access Key",tooltipAccessKey:"API access key to use for this video distribution.",publishTitle:"Publish & Deliver",publishStepTitle:"STEP 1: Publish your Project",publishStepDesc:"Your project needs to be published before your changes can be seen. If you haven't made any changes since the last time you published, you can skip to the next step.",distributeStepTitle:"STEP 2: How do you want your users to view their video?",distributeStepDesc:"Select which Composition you want to deliver, access credentials you want to use, and distribution channel.",compositionError:"Please Select Composition",btnWebsite:"Webpage",webpageTitle:"STEP 3: Webpage",webPageHosted:"Webpage hosted on Imposium",webpageDesc:"You can share a demo page that is hosted on Imposium or you can download a sample webpage you can customize and use to generate videos. Please ensure you include a column for every variable on your story.",sampleWebpage:"Download sample webpage",btnEmail:"Email",exporting:"Exporting CSV... (please wait)",emailTitle:"STEP 3: Upload a CSV file with your user information in it.",emailDesc:"You can download a sample CSV with fields to populate as a starting point. Or you can upload one that already has the data in it.",downloadSampleCsvLink:"Download Sample CSV",uploadCsv:"Upload Your CSV UserList",generatingLink:"STEP 4: Generating embed links",downloadLink:"STEP 5: Download Your Userlist CSV file",btnDownload:"Download CSV",generatingLinkDesc:"Please wait while we generate the link for your users. This may take few minutes.",missingColumns:"Error: missing required columns",renderBatchFailed:"Error: Failed to render batch",createBatchFailed:"Error: Failed to create batch",downloadError:"Error downloading sample CSV.",embeddedCodeCopyError:"Error copying embed code.",creatingLinks:"Creating User Links... (please wait)",importingData:"Importing Data... (please wait)",downloadDesc:"Your CSV data file is ready to download with an embed code you can import into your email platform to send out.",titleMissingColumns:"Warning: ",csvMissingColumns:"Some of your column names did not match up with the variables in the story. Please ensure these variables line up and then re-upload the csv: ",csvMatchColumns:"Please match the column(s) provided to the story variables:",exportBatchOfVideo:"Export batch of videos",btnHubspot:"Hubspot",hubspotTitle:"STEP 3: Copy Hubspot code snippet",hubspotDesc:"Copy the provided embed code into HubSpot. Replace the placeholder variable values with HubSpot template strings, to splice in your user data.",saveChanges:"Save Changes",embeddedCode:"Embed Url: ",btnAPI:"API integration",btnExport:"Export",btnPublish:"Publish",btnSkip:"Skip",btnBack:"Back",btnFinished:"Done",btnCancel:"Cancel",btnNext:"Next",noCompErrorTitle:"No Compositions Found",noCompErrorDesc:"You must have at least 1 composition on your story to render and distribute videos."},t.integration={errorPullingComps:" Error getting composition IDs, contact your Imposium admin for support.",errorCreatingCreds:" Error creating credentials, contact your Imposium admin for support.",errorGettingCreds:" Error getting credentials, contact your Imposium admin for support.",documentation:"Documentation",docParagraph:"Use the links below for more information on integrating Imposium into your application.",js:"JavaScript SDK",jsSdkLink:"https://docs.imposium.com/js-sdk/#/",restLink:"https://docs.imposium.com",rest:"REST API",sdkArchiveSuffix:" - JS SDK Integration.zip"},t.header={publishing:"Publishing...",working:"Using Working Copy",statusError:"Error getting story status",publishJobError:"Error creating publish story job",publishPollError:"Error polling publish job status"},t.project={compName:"Composition",tooltipCompId:"Unique ID of the selected composition. Used to render that specific composition via the API and Imposium JS-SDK."},t.BATCHES_COPY={progress:{notRendered:"not rendered",rendering:"rendering",rendered:"rendered",cancelled:"cancelled",queued:"queued",malformed:"unknown"}}},function(e,n){e.exports=t},function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i};Object.defineProperty(t,"__esModule",{value:!0}),t.s3Url=t.formattedTime=t.formatDateDefault=t.padStart=t.toFixed=t.mimetypeConformsToOverlay=t.isFont=t.validateAssetMimetype=t.isObjEmpty=t.filterHotkeys=t.fitToContainer=t.generateUUID=t.string2HexCode=t.parameterizeServiceUrl=t.scrapeEmail=t.getFirstStoryInOrg=t.validateAccessLevel=t.getActiveOrg=t.isLocal=void 0;t.isLocal=function(){return"localhost"===window.location.hostname};t.getActiveOrg=function(e,t){return t.organizations.find((function(t){return t.id===e}))};t.validateAccessLevel=function(e,n,r){var a=t.getActiveOrg(e,r);return!!a&&a.services.includes(n)};t.getFirstStoryInOrg=function(e,n){var r=t.getActiveOrg(e,n);return r&&"object"==typeof r.stories[0]?r.stories[0].id:""};t.scrapeEmail=function(e){return e&&e.idTokenPayload&&e.idTokenPayload["https://imposium.com/email"]?e.idTokenPayload["https://imposium.com/email"]:""};t.parameterizeServiceUrl=function(e,t,n,r){if(!e||!t)return e&&!t?n+"?organization_id="+e:n;switch(r){case 1:case 4:case 5:case 6:case 8:return n+"/"+t+"?organization_id="+e;case 3:return n+"/dashboard/live/"+t+"?organization_id="+e;default:return n+"?organization_id="+e}};t.string2HexCode=function(e){var t=(16777215&e.split("").map((function(t,n){return e.charCodeAt(n)})).reduce((function(e,t){return t+((e<<5)-e)}),0)).toString(16).toUpperCase();return"#"+("00000".substring(0,6-t.length)+t)};t.generateUUID=function(){var e=(new Date).getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(t){var n=(e+16*Math.random())%16|0;return e=Math.floor(e/16),("x"===t?n:7&n|8).toString(16)}))};t.fitToContainer=function(e,t,n){var r,a,o,i,s=t.width/t.height,u=n.padding?e.width-2*n.padding:e.width,l=n.padding?e.height-2*n.padding:e.height,c=n.padding?n.padding:0;return"proportionalInside"===n.scaleMode?(r=(a=u)/s)>l&&(a=(r=l)*s):"proportionalOutside"===n.scaleMode?(r=(a=u)/s)<l&&(a=(r=l)*s):"none"!==n.scaleMode&&n.scaleMode||(a=t.width,r=t.height),n.maxWidth&&a>n.maxWidth&&(r=(a=n.maxWidth)/s),n.maxHeight&&r>n.maxHeight&&(a=(r=n.maxHeight)*s),i="left"===n.hAlign?0:"right"===n.hAlign?u-a:(u-a)/2,o="top"===n.vAlign?0:"bottom"===n.vAlign?l-r:(l-r)/2,{width:a,height:r,top:o+=c,left:i+=c}};t.filterHotkeys=function(e){var t=(e.target||e.srcElement).tagName,n=t.isContentEditable||"INPUT"===t||"SELECT"===t||"TEXTAREA"===t,r="Enter"===e.code,a="Escape"===e.code,o=!0===e.metaKey;return!!(!n||n&&r||n&&a||n&&o)};t.isObjEmpty=function(e){for(var t in e)if(e.hasOwnProperty(t))return!1;return!0};t.validateAssetMimetype=function(e){var n=r(e.type.split("/"),2),a=n[0],o=n[1],i=e.name.split("."),s=i[i.length-1];switch(a){case"image":case"video":case"audio":return!0;case"application":switch(o){case"zip":case"x-gzip":return!0}}return!!t.isFont(a,s)||(-1!==e.name.indexOf(".CUBE")||(console.warn("Mimetype: "+e.type+" is not a supported asset type."),!1))};t.isFont=function(e,t){var n=["font","otf","sfnt","ttf","woff","woff2","font-sfnt","font-woff","vnd.ms-fontobject","font/otf","font/sfnt","font/ttf","font/woff","font/woff2","font/font-sfnt","font/font-woff","font/vnd.ms-fontobject"];return e?-1!==n.indexOf(e):-1!==n.indexOf(t)};t.mimetypeConformsToOverlay=function(e,t){var n=r(t.type.split("/"),2),a=n[0],o=n[1];return"video"===e&&"video"===a||"image"===e&&"image"===a||"audio"===e&&"audio"===a||"template"===e&&"application"===a&&("zip"===o||"x-gzip"===o)||"image_sequence"===e&&"application"===a&&("zip"===o||"x-gzip"===o)};t.toFixed=function(e,t){var n=new RegExp("^-?\\d+(?:.\\d{0,"+(t||-1)+"})?");return e.toString().match(n)[0]};t.padStart=function(e,t){return new Array(t+1-(e+"").length).join("0")+e};t.formatDateDefault=function(e){var t=new Date(1e3*e),n=t.getMonth()+1,r=t.getDate(),a=t.getFullYear(),o=t.getHours(),i=o>=12?"PM":"AM";o>12&&(o-=12),0===o&&(o=12);var s=t.getMinutes();return s<10&&(s="0"+s),n+"/"+r+"/"+a+" "+o+":"+s+" "+i};t.formattedTime=function(e){var t=Math.floor(e/6e4),n=(e%6e4/1e3).toFixed(0);return(t<10?"0":"")+t+":"+(n<10?"0":"")+n};t.s3Url=function(e,t,n){return e?e.replace(t,n):""}},function(e,t){e.exports=n},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(9),u=n(60),l=n(4),c=n(5),d=function(e){function t(t){var n=e.call(this,t)||this;return n.tooltipId=s.generateUUID(),n.state={showInfo:!1},n.toggleIDInfo=function(){n.setState({showInfo:!n.state.showInfo})},n}return a(t,e),t.prototype.getLabelClass=function(){return this.props.label?"label-"+(this.props.labelPosition?this.props.labelPosition:"left"):"no-label"},t.prototype.renderLabel=function(){var e=this.state.showInfo,t=this.props,n=t.info,r=t.label,a=e?l.ICON_TIMES_CIRCLE:l.ICON_INFO_CIRCLE,s=n?i.createElement(c.default,{onClick:this.toggleIDInfo,size:"small",style:"subtle"},a):null;return s||r?i.createElement("label",o({},u.renderTooltipProps(this.tooltipId,this.props.tooltip),{className:this.getLabelClass()}),s,s&&" ",r):null},t.prototype.render=function(){var e=this.props,t=e.label,n=e.width,r=e.customClass,a=this.renderLabel(),s={},l={};return t||(l=u.renderTooltipProps(this.tooltipId,this.props.tooltip)),n&&(s.width="string"==typeof n?n:n+"px"),i.createElement("div",{className:"form-field "+r+" "+this.getLabelClass(),style:s},a,i.createElement("div",o({className:"form-field-content "+this.getLabelClass()},l),this.props.children,this.renderButtons()),u.renderTooltip(this.tooltipId,this.props.tooltip),this.renderInfo())},t.prototype.renderInfo=function(){var e=this.props.info,t=this.state.showInfo;return e&&t?i.createElement("p",null,e):null},t.prototype.renderButtons=function(){if(this.props.buttons)return i.createElement("div",{className:"form-field-buttons"},this.props.buttons)},t}(i.PureComponent);t.default=d},function(e,t){var n=Array.isArray;e.exports=n},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},i=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},s=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),l=n(62),c=n(5),d=n(11),p=n(9),f=n(4),h=n(363),m=function(e){function t(t){var n=e.call(this,t)||this;if(n.evtHandlers={submittable:function(){return n.forceSubmit()},controlled:function(e){return n.toggleEditing(e)},cancel:function(){return n.cancelEdit()},clear:function(){return n.forceSubmit(!0)},toggleEditing:function(e){return n.toggleEditing(e)},forceSubmit:function(){return n.forceSubmit()},clearValue:function(){return n.clearValue()},copyToClipboard:function(e){return n.copyToClipboard(e)},onSuggestionsFetchRequested:function(e){return n.onSuggestionsFetchRequested(e)},onSuggestionsClearRequested:function(){return n.onSuggestionsClearRequested()},getSuggestionValue:function(e){return n.getSuggestionValue(e)},renderSuggestion:function(e){return n.renderSuggestion(e)}},n.componentDidUpdate=function(e,t){(n.props.controlled||n.props.submittable)&&(e.value!==n.props.value&&n.setState({internalValue:n.props.value}),""===n.props.value&&!n.state.editing&&t.editing&&n.setState({internalValue:""}))},n.forceSubmit=function(e){void 0===e&&(e=!1);var t=n.state.internalValue;e||(n.props.doSubmit(t),"add"===n.props.submittableType&&n.setState({internalValue:""})),e&&(n.props.doSubmit(""),n.setState({internalValue:""}))},n.renderSubmittableIcon=function(){switch(n.props.submittableType){case"search":return f.ICON_SEARCH;case"check":return f.ICON_CHECK;case"add":return f.ICON_PLUS;default:return null}},n.onSuggestionsFetchRequested=function(e){var t=e.value;n.setState({suggestions:n.getSuggestions(t)})},n.onSuggestionsClearRequested=function(){n.setState({suggestions:[]})},n.props.controlled&&n.props.submittable)throw new Error("Actionable TextField(s) must be one of either: controlled or submittable.");return n.state={internalValue:t.value||"",suggestions:[],editing:!1},n.inputRef=u.createRef(),l.default.filter=function(e){return p.filterHotkeys(e)},n}return a(t,e),t.prototype.componentDidMount=function(){this.props.focusOnMount&&this.inputRef.current&&this.inputRef.current.focus()},t.prototype.componentWillUnmount=function(){this.props.submittable?(l.default.unbind("enter",this.evtHandlers.submittable),l.default.unbind("esc",this.evtHandlers.clear)):this.props.controlled&&(l.default.unbind("enter",this.evtHandlers.controlled),l.default.unbind("esc",this.evtHandlers.cancel))},t.prototype.setEditing=function(e){var t=this;this.setState({editing:e},(function(){t.inputRef.current.focus()}))},t.prototype.blur=function(e){this.props.onBlur&&this.props.onBlur(e),this.props.submittable?(l.default.unbind("enter",this.evtHandlers.submittable),l.default.unbind("esc",this.evtHandlers.clear)):this.props.controlled&&(l.default.unbind("enter",this.evtHandlers.controlled),l.default.unbind("esc",this.evtHandlers.cancel))},t.prototype.focus=function(e){this.props.onFocus&&this.props.onFocus(e),this.props.submittable?(l.default("enter",this.evtHandlers.submittable),l.default("esc",this.evtHandlers.clear)):this.props.controlled&&(l.default("enter",this.evtHandlers.controlled),l.default("esc",this.evtHandlers.cancel))},t.prototype.cancelEdit=function(){this.setState({editing:!1,internalValue:this.props.value})},t.prototype.copyToClipboard=function(e){var t=this.props,n=t.onNotification,r=t.onError;navigator.clipboard.writeText(this.props.value).then((function(){n&&n("Copied to clipboard!")}),(function(){r&&r("Error copying to clipboard.")}))},t.prototype.getValue=function(){var e=this.props,t=e.controlled,n=e.submittable,r=e.value,a=this.state.internalValue;return t||n?a:r||""},t.prototype.onChange=function(e,t){var n=this,r=this.props.pattern,a=t?t.newValue:e.target.value;if(this.props.controlled||this.props.submittable)this.setState({internalValue:a},(function(){t&&"click"===t.method&&n.evtHandlers.submittable()}));else{if(r&&!r.test(a))return;""===a&&(a=null),this.props.onChange(a)}},t.prototype.toggleEditing=function(e){var t=this;e.preventDefault(),e.stopPropagation();var n=this.state,r=n.editing,a=n.internalValue,o=this.props.value;r?this.setState({editing:!1},(function(){if(a!==o){var e=t.state.internalValue;""===e&&(e=null),t.props.onSubmit(e)}})):this.setState({editing:!0},(function(){var e=t.inputRef.current;e&&e.focus()}))},t.prototype.clearValue=function(){var e=this;this.setState({internalValue:""},(function(){e.props.doSubmit("")}))},t.prototype.getSuggestions=function(e){var t=e.trim().toLowerCase(),n=t.length;return 0===n?[]:this.props.suggestions.filter((function(e){return e.toLowerCase().slice(0,n)===t}))},t.prototype.getSuggestionValue=function(e){return e},t.prototype.renderSuggestion=function(e){return u.createElement("div",{className:"suggestion"},e)},t.prototype.renderButtons=function(){var e,t=this.props,n=t.controlled,r=t.submittable,a=(t.readOnly,t.buttons),o=t.showCopy,l=t.submittableType,d=t.value,p=t.hideButtons,h=this.state,m=h.editing;h.internalValue;a?Array.isArray(a)?e=s([],i(a)):(e=[]).push(a):e=[];var _="search"===l?"Search":"Confirm";if(p)return[];if(n){var y=m?f.ICON_CHECK:f.ICON_EDIT;e.push(u.createElement(c.default,{key:"btn-edit",style:"subtle",tooltip:"Edit",color:"secondary",onClick:this.evtHandlers.toggleEditing},y))}return r&&(e.push(u.createElement(c.default,{key:"btn-submit",style:"subtle",tooltip:_,color:"secondary",onClick:this.evtHandlers.forceSubmit},this.renderSubmittableIcon())),d&&e.push(u.createElement(c.default,{key:"btn-clear",style:"subtle",tooltip:"Clear",onClick:this.evtHandlers.clearValue},f.ICON_TIMES))),o&&e.push(u.createElement(c.default,{key:"btn-copy",style:"subtle",color:"primary",tooltip:"Copy to Clipboard",onClick:this.evtHandlers.copyToClipboard},f.ICON_CLIPBOARD)),e},t.prototype.renderInput=function(){var e=this,t=this.props,n=t.placeholder,r=t.controlled,a=t.submittable,i=t.disabled,s=t.readOnly,l=t.loading,c=this.state.suggestions,d=this.state.editing,p=r&&!d||i,f=r||a?"controlled-input":"",m={type:"text",placeholder:n,value:this.getValue(),disabled:p||l,readOnly:s,ref:this.inputRef,onFocus:function(t){return e.focus(t)},onBlur:function(t){return e.blur(t)}};return this.props.suggestions?(m.onChange=function(t,n){return e.onChange(t,n)},u.createElement(h,{suggestions:c,onSuggestionsFetchRequested:this.evtHandlers.onSuggestionsFetchRequested,onSuggestionsClearRequested:this.evtHandlers.onSuggestionsClearRequested,getSuggestionValue:this.evtHandlers.getSuggestionValue,renderSuggestion:this.evtHandlers.renderSuggestion,inputProps:m})):(m.onChange=function(t){return e.onChange(t)},u.createElement("input",o({className:""+f},m)))},t.prototype.render=function(){var e=this.props,t=e.label,n=e.width,r=e.tooltip,a=e.info,o=e.labelPosition;return u.createElement(d.default,{customClass:"text-field",label:t,buttons:this.renderButtons(),tooltip:r,info:a,labelPosition:o,width:n},this.renderInput())},t}(u.PureComponent);t.default=m},function(e,t,n){var r=n(103),a="object"==typeof self&&self&&self.Object===Object&&self,o=r||a||Function("return this")();e.exports=o},function(e,t){e.exports=function(e){return null!=e&&"object"==typeof e}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0);t.default=function(e){var t=e.style;return t||(t="default"),r.createElement("div",{className:"horizontal-rule "+t})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.deleteAssetTag=t.updateAssetData=t.updateAssetName=t.addAssetTag=t.deleteAssets=t.getAssets=t.doAssetTableHydration=t.toggleLoading=void 0;var r=n(83),a=n(33),o={TOGGLE_LOADING:"assetList/TOGGLE_LOADING",GET:"assetList/GET",ADD_TAG:"assetList/ADD_TAG",DELETE_TAG:"assetList/DELETE_TAG",UPDATE_NAME:"assetList/UPDATE_NAME",UPDATE_DATA:"assetList/UPDATE_DATA"};t.toggleLoading=function(e){return{type:o.TOGGLE_LOADING,toggle:e}};t.doAssetTableHydration=function(e,n,o){return function(i){return new Promise((function(s,u){Promise.all([i(t.getAssets(e,n)),i(r.getAssetTagList(e,n))]).then((function(){i(a.resetSelection),s()})).catch((function(e){"function"==typeof o&&o(),u()}))}))}};t.getAssets=function(e,n){return function(r,a){return new Promise((function(i,s){var u=a(),l=u.assetFilters;u.loading||r(t.toggleLoading(!0)),e.getAssets(l,n,!0).then((function(e){r({type:o.GET,assetList:e}),r(t.toggleLoading(!1)),i()})).catch((function(e){r(t.toggleLoading(!1)),s()}))}))}};t.deleteAssets=function(e,n,r){return function(a){if(window.confirm("Are you sure you want to delete "+n.length+" assets?"))return new Promise((function(o,i){a(t.toggleLoading(!0)),e.deleteAssets(n).then((function(){a(t.getAssets(e,r)),o()})).catch((function(e){a(t.toggleLoading(!1)),i()}))}))}};t.addAssetTag=function(e,t,n,r){return function(r,a){return new Promise((function(a){var i,s=n.includes(",")?n.split(",").filter(String).map((function(e){return e.trim()})):[n];0===s.length&&a(),s.length>0&&(i=s.map((function(n){return e.addAssetTag(t,n).then((function(){return a()})).catch((function(e){return a(e)}))})),Promise.all(i).then((function(e){a()})),r({type:o.ADD_TAG,id:t,freshTags:s}))}))}};t.updateAssetName=function(e,t,n,r){return void 0===r&&(r=!1),function(a){return new Promise((function(i,s){a({type:o.UPDATE_NAME,id:t,name:n}),r||e.updateAsset(t,{name:n}).then((function(){i()})).catch((function(e){s()}))}))}};t.updateAssetData=function(e,t,n){return function(r){return new Promise((function(a,i){r({type:o.UPDATE_DATA,id:t,name:name}),e.updateAsset(t,{data:JSON.stringify(n)}).then((function(){a()})).catch((function(e){i()}))}))}};t.deleteAssetTag=function(e,t,n){return function(r){return new Promise((function(a,i){r({type:o.DELETE_TAG,id:t,tag:n}),e.deleteAssetTag(t,n).then((function(){a()})).catch((function(e){i()}))}))}},t.default=o},function(e,t,n){var r=n(31),a=n(370),o=n(371),i=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":i&&i in Object(e)?a(e):o(e)}},function(e,t,n){var r=n(396),a=n(399);e.exports=function(e,t){var n=a(e,t);return r(n)?n:void 0}},function(e,t,n){"use strict";(function(e){var r=n(6),a=n(274),o="object"==typeof exports&&exports&&!exports.nodeType&&exports,i=o&&"object"==typeof e&&e&&!e.nodeType&&e,s=i&&i.exports===o?r.a.Buffer:void 0,u=(s?s.isBuffer:void 0)||a.a;t.a=u}).call(this,n(82)(e))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(4);t.default=function(){return r.createElement("div",{className:"spinner"},r.createElement("div",{className:"icon"},a.ICON_CIRCLE_NOTCH))}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(0),u=n(11),l=n(4),c=n(5),d=function(e){function t(t){var n=e.call(this,t)||this;return n.evtHandlers={copyToClipboard:function(e){return n.copyToClipboard(e)}},n}return a(t,e),t.prototype.copyToClipboard=function(e){var t=this.props,n=t.onNotification,r=t.onError;navigator.clipboard.writeText(this.props.value).then((function(){n&&n("Copied to clipboard!")}),(function(){r&&r("Error copying to clipboard.")}))},t.prototype.onChange=function(e){var t=e.target.value;"true"===t&&(t=!0),"false"===t&&(t=!1),this.props.onChange(t)},t.prototype.render=function(){var e,t=this,n=this.props,r=n.label,a=n.showCopy,d=n.options,p=n.value,f=n.width,h=n.buttons,m=n.selectRef,_=n.disable,y=n.tooltip,g=n.info,v=n.labelPosition,b=n.disableFirst,w=[],M=null==p?"":p,L=s.createElement("div",{key:"caret",className:"caret"},l.ICON_CARET_DOWN);return e=h?Array.isArray(h)?i([L],o(h)):[L,h]:[L],a&&e.push(s.createElement(c.default,{key:"btn-copy",style:"subtle",color:"primary",tooltip:"Copy to Clipboard",onClick:this.evtHandlers.copyToClipboard},l.ICON_CLIPBOARD)),d&&(w=d.map((function(e,t){var n=!!(0===t&&b||void 0!==e.disabled&&e.disabled),r=void 0!==e.value?e.value:e,a=void 0!==e.label?e.label:e;return s.createElement("option",{disabled:n,key:"option-"+r,value:r},a)}))),s.createElement(u.default,{customClass:"select-field",label:r,tooltip:y,buttons:e,info:g,labelPosition:v,width:f},s.createElement("select",{value:M,onChange:function(e){return t.onChange(e)},ref:m,disabled:_},w))},t}(s.PureComponent);t.default=d},function(e,t){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.updateFilters=void 0;var r={UPDATE:"assetFilters/UPDATE",RESET:"footageFilters/RESET"};t.updateFilters=function(e){return{type:r.UPDATE,newFilters:e}},t.default=r},function(e,t,n){"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),t.ASSET_COLORS=t.ASSET_TYPES=t.ASSET_ORIGIN=t.ASSET_DISTRO=void 0,t.ASSET_DISTRO="https://d188rqu2y6x0ew.cloudfront.net",t.ASSET_ORIGIN="https://imposium-footage.s3.us-east-1.amazonaws.com",t.ASSET_TYPES={VIDEO_COMPOSITION:"video_composition",STATIC_COMPOSITION:"static_composition",VIDEO:"video",IMAGE:"image",TEMPLATE:"template",AUDIO:"audio",IMAGE_SEQUENCE:"image_sequence",FONT:"font",LUT:"lut",ALL:"all"},t.ASSET_COLORS=((r={})[t.ASSET_TYPES.VIDEO]="rgba(236,22,150, 1)",r[t.ASSET_TYPES.IMAGE]="rgba(241,191,21, 1)",r[t.ASSET_TYPES.AUDIO]="rgba(72,177,222,1)",r[t.ASSET_TYPES.TEMPLATE]="rgba(208, 80, 35, 1)",r[t.ASSET_TYPES.VIDEO_COMPOSITION]="rgba(215, 22, 22, 1)",r[t.ASSET_TYPES.IMAGE_SEQUENCE]="rgba(241,191,21, 1)",r)},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.getPlayerStyle=void 0;var o=n(0),i=n(9),s=n(34);t.getPlayerStyle=function(e,t,n,r,a,o,s){var u={width:e,height:t},l={width:n,height:r},c=i.fitToContainer(u,l,{scaleMode:"proportionalInside",maxWidth:o,maxHeight:s,padding:a}),d=c.width,p=c.height;return{top:c.top+"px",left:c.left+"px",width:d+"px",height:p+"px"}};var u=function(e){function n(t){var r=e.call(this,t)||this;return r.state={videoHeight:1080,videoWidth:1920,scaleMode:n.SCALE_MODES.AUTOMATIC},r.videoNode=o.createRef(),r}return a(n,e),n.prototype.getVideoStyle=function(){var e=this.state,n=e.videoHeight,r=e.videoWidth,a=this.props,o=a.padding,i=a.width,u=a.height,l=a.maxWidth,c=a.maxHeight,d=void 0!==o?o:s.DEFAULT_PADDING;return n&&r?t.getPlayerStyle(i,u,r,n,d,l,c):{}},n.prototype.setTime=function(e){var t=this.videoNode.current;t&&(t.currentTime=e)},n.prototype.metadataLoaded=function(e){this.setState({videoWidth:e.target.videoWidth,videoHeight:e.target.videoHeight})},n.prototype.renderCustomControls=function(){var e=this.props.customControls;return e?o.cloneElement(e,{videoNode:this.videoNode}):null},n.prototype.render=function(){var e=this,t=this.props,n=t.url,r=t.active,a=t.muted,i=t.customControls,s=t.hideDefaultControls,u=!i&&!s,l=!!this.props.autoPlay&&this.props.autoPlay;return!1!==r?o.createElement("div",{className:"media-player"},o.createElement("div",{className:"inner-viewer",style:this.getVideoStyle()},o.createElement("video",{controls:u,onLoadedMetadata:function(t){return e.metadataLoaded(t)},muted:a,src:n,ref:this.videoNode,preload:"auto",autoPlay:l}),this.renderCustomControls())):null},n.SCALE_MODES={MANUAL:"manual",AUTOMATIC:"automatic"},n}(o.PureComponent);t.default=u},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},o=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var i=n(343),s=n(28),u=function(){function e(){}return e.LAST_STORY_ID_CACHE="imp_hub_last_story_id",e.LAST_ORG_ID_CACHE="imp_hub_last_org_id",e.SESSION_COOKIE_NAME="auth_state",e.FRESH_COOKIE={sub:"",organization_id:"",story_id:"",stories_hash:0,orgs_hash:0},e.getAccessData=function(t,n){return new Promise((function(r,a){var o=n?n+"/access":e.determineAccessUrl();s.default.get(o,{headers:{Authorization:"Bearer "+t}}).then((function(e){r(e.data?e.data:[])})).catch((function(e){a(e)}))}))},e.getSession=function(){return i.getJSON(e.SESSION_COOKIE_NAME)},e.removeSession=function(){var t=e.scrapeDomain();i.remove(e.SESSION_COOKIE_NAME,{domain:t})},e.buildFreshSession=function(t,n){var r,a,o,i,s=t.idTokenPayload,u=s.sub,l=s.exp,c=n.organizations,d="",p="";try{a=localStorage.getItem(e.LAST_ORG_ID_CACHE),o=localStorage.getItem(e.LAST_STORY_ID_CACHE)}catch(e){console.warn("Failed to look up cached hub settings",e)}a&&"object"==typeof(i=n.organizations.find((function(e){return e.id===a})))&&i.hasOwnProperty("id")&&(d=a),o&&d&&i.stories.find((function(e){return e.id===o}))&&(p=o),!d&&c.length>0&&"object"==typeof c[0]&&c[0].hasOwnProperty("id")&&(d=c[0].id),!p&&c[0].stories.length>0&&"object"==typeof c[0].stories[0]&&c[0].stories[0].hasOwnProperty("id")&&(p=c[0].stories[0].id),r={sub:u,organization_id:d,story_id:p,stories_hash:e.generateStoriesHash(n),orgs_hash:e.generateOrgsHash(n)},e.storeSession(r,l)},e.storeSession=function(t,n){var a=r(r({},e.FRESH_COOKIE),t),o=e.scrapeDomain(),s=new Date(1e3*n);i.set(e.SESSION_COOKIE_NAME,a,{domain:o,expires:s})},e.updateSession=function(t,n){var a=e.getSession(),o=r(r({},a),t);if(t.hasOwnProperty("organization_id"))try{localStorage.setItem(e.LAST_ORG_ID_CACHE,t.organization_id)}catch(e){console.warn("Failed to cache last organization id selected",e)}if(t.hasOwnProperty("story_id"))try{localStorage.setItem(e.LAST_STORY_ID_CACHE,t.story_id)}catch(e){console.warn("Failed to cache last story id selected",e)}e.storeSession(o,n)},e.generateOrgsHash=function(t){var n=t.organizations.map((function(e){return e.id})).join("");return e.string2Hash(n)},e.generateStoriesHash=function(t){var n=t.organizations.reduce((function(e,t){return o(o([],a(e)),a(t.stories))}),[]).map((function(e){return""+e.id+e.name})).join("");return e.string2Hash(n)},e.string2Hash=function(e){var t=0;if(0===e.length)return t;for(var n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return t},e.scrapeDomain=function(){var e=window.location.host.split(".").reverse();return e.length>2?"."+e[1]+"."+e[0].split(":")[0]:null},e.determineAccessUrl=function(){var e=window.location,t=e.hostname,n=e.host;return"localhost"===t?"https://api/access":n.includes(".staging.")?"https://api.staging.imposium.com/access":"https://api.imposium.com/access"},e}();t.default=u},function(e,t){e.exports=r},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(344),o=function(){function e(){}return e.IMPOSIUM_APP_DEFAULTS={domain:"imposium.auth0.com",scope:"openid",responseType:"token id_token",redirectUri:window.location.origin+"/auth"},e.bindToClient=function(t){e.auth0Client=new a.WebAuth(r({clientID:t},e.IMPOSIUM_APP_DEFAULTS))},e.login=function(){e.auth0Client.authorize()},e.logout=function(){e.auth0Client.logout({returnTo:window.location.origin+"/auth"})},e.checkExpiry=function(e){return e>Date.now().valueOf()/1e3},e.parseIdFromHash=function(t){return new Promise((function(n,r){e.auth0Client.parseHash({options:t},(function(e,t){e?r(e):n(t)}))}))},e.checkSession=function(){return new Promise((function(t,n){e.auth0Client.checkSession({},(function(e,r){e?n(e):t(r)}))}))},e}();t.default=o},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(11),s=n(4),u=function(e){function t(t){return e.call(this,t)||this}return a(t,e),t.prototype.toggle=function(e){this.props.propagate||e.stopPropagation(),this.props.onChange(!this.props.value,e)},t.prototype.render=function(){var e=this,t=this.props,n=t.value,r=t.label,a=t.width,u=t.tooltip,l=t.info,c=t.labelPosition,d=!0===n?s.ICON_CHECK:null;return o.createElement(i.default,{customClass:"checkbox-field",label:r,tooltip:u,info:l,labelPosition:c,width:a},o.createElement("div",{className:"checkbox",onClick:function(t){return e.toggle(t)}},d))},t}(o.PureComponent);t.default=u},function(e,t,n){var r=n(14).Symbol;e.exports=r},function(e,t,n){var r=n(105),a=n(378),o=n(43);e.exports=function(e){return o(e)?r(e):a(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.selectMultipleAssets=t.selectAsset=t.resetSelection=t.deselectAsset=t.selectAll=void 0;t.selectAll=function(){return function(e,t){var n=t().assetList.assets.map((function(e){return e.id}));e({type:a.SELECT_ALL,allIds:n})}};t.deselectAsset=function(e){return{type:a.DESELECT_ASSET,id:e}};t.resetSelection=function(){return{type:a.RESET_SELECTION}};t.selectAsset=function(e){return{type:a.SELECT_ASSET,id:e}};t.selectMultipleAssets=function(e){return function(t,n){for(var o=n(),i=o.selectedAssets,s=o.assetList.assets,u=i[i.length-1],l=r(s,u),c=r(s,e),d=l<c?c:l,p=[],f=l<c?l:c;f<=d;f++){var h=s[f];p.push(h.id)}t({type:a.SELECT_MULTIPLE,assets:p}),window.getSelection().removeAllRanges()}};var r=function(e,t){for(var n=0;n<e.length;n++){if(e[n].id===t)return n}},a={SELECT_ALL:"selectAssets/SELECT_ALL",SELECT_MULTIPLE:"selectAssets/SELECT_MULTIPLE",SELECT_ASSET:"selectedAssets/SELECT_ASSET",DESELECT_ASSET:"selectedAssets/DESELECT_ASSET",RESET_SELECTION:"selectedAssets/RESET_SELECTION"};t.default=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_PADDING=void 0,t.DEFAULT_PADDING=35},function(e,t){e.exports=a},function(e,t,n){var r;!function(a){var o=/^\s+/,i=/\s+$/,s=0,u=a.round,l=a.min,c=a.max,d=a.random;function p(e,t){if(t=t||{},(e=e||"")instanceof p)return e;if(!(this instanceof p))return new p(e,t);var n=function(e){var t={r:0,g:0,b:0},n=1,r=null,s=null,u=null,d=!1,p=!1;"string"==typeof e&&(e=function(e){e=e.replace(o,"").replace(i,"").toLowerCase();var t,n=!1;if(D[e])e=D[e],n=!0;else if("transparent"==e)return{r:0,g:0,b:0,a:0,format:"name"};if(t=W.rgb.exec(e))return{r:t[1],g:t[2],b:t[3]};if(t=W.rgba.exec(e))return{r:t[1],g:t[2],b:t[3],a:t[4]};if(t=W.hsl.exec(e))return{h:t[1],s:t[2],l:t[3]};if(t=W.hsla.exec(e))return{h:t[1],s:t[2],l:t[3],a:t[4]};if(t=W.hsv.exec(e))return{h:t[1],s:t[2],v:t[3]};if(t=W.hsva.exec(e))return{h:t[1],s:t[2],v:t[3],a:t[4]};if(t=W.hex8.exec(e))return{r:P(t[1]),g:P(t[2]),b:P(t[3]),a:R(t[4]),format:n?"name":"hex8"};if(t=W.hex6.exec(e))return{r:P(t[1]),g:P(t[2]),b:P(t[3]),format:n?"name":"hex"};if(t=W.hex4.exec(e))return{r:P(t[1]+""+t[1]),g:P(t[2]+""+t[2]),b:P(t[3]+""+t[3]),a:R(t[4]+""+t[4]),format:n?"name":"hex8"};if(t=W.hex3.exec(e))return{r:P(t[1]+""+t[1]),g:P(t[2]+""+t[2]),b:P(t[3]+""+t[3]),format:n?"name":"hex"};return!1}(e));"object"==typeof e&&(B(e.r)&&B(e.g)&&B(e.b)?(f=e.r,h=e.g,m=e.b,t={r:255*C(f,255),g:255*C(h,255),b:255*C(m,255)},d=!0,p="%"===String(e.r).substr(-1)?"prgb":"rgb"):B(e.h)&&B(e.s)&&B(e.v)?(r=I(e.s),s=I(e.v),t=function(e,t,n){e=6*C(e,360),t=C(t,100),n=C(n,100);var r=a.floor(e),o=e-r,i=n*(1-t),s=n*(1-o*t),u=n*(1-(1-o)*t),l=r%6;return{r:255*[n,s,i,i,u,n][l],g:255*[u,n,n,s,i,i][l],b:255*[i,i,u,n,n,s][l]}}(e.h,r,s),d=!0,p="hsv"):B(e.h)&&B(e.s)&&B(e.l)&&(r=I(e.s),u=I(e.l),t=function(e,t,n){var r,a,o;function i(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}if(e=C(e,360),t=C(t,100),n=C(n,100),0===t)r=a=o=n;else{var s=n<.5?n*(1+t):n+t-n*t,u=2*n-s;r=i(u,s,e+1/3),a=i(u,s,e),o=i(u,s,e-1/3)}return{r:255*r,g:255*a,b:255*o}}(e.h,r,u),d=!0,p="hsl"),e.hasOwnProperty("a")&&(n=e.a));var f,h,m;return n=A(n),{ok:d,format:e.format||p,r:l(255,c(t.r,0)),g:l(255,c(t.g,0)),b:l(255,c(t.b,0)),a:n}}(e);this._originalInput=e,this._r=n.r,this._g=n.g,this._b=n.b,this._a=n.a,this._roundA=u(100*this._a)/100,this._format=t.format||n.format,this._gradientType=t.gradientType,this._r<1&&(this._r=u(this._r)),this._g<1&&(this._g=u(this._g)),this._b<1&&(this._b=u(this._b)),this._ok=n.ok,this._tc_id=s++}function f(e,t,n){e=C(e,255),t=C(t,255),n=C(n,255);var r,a,o=c(e,t,n),i=l(e,t,n),s=(o+i)/2;if(o==i)r=a=0;else{var u=o-i;switch(a=s>.5?u/(2-o-i):u/(o+i),o){case e:r=(t-n)/u+(t<n?6:0);break;case t:r=(n-e)/u+2;break;case n:r=(e-t)/u+4}r/=6}return{h:r,s:a,l:s}}function h(e,t,n){e=C(e,255),t=C(t,255),n=C(n,255);var r,a,o=c(e,t,n),i=l(e,t,n),s=o,u=o-i;if(a=0===o?0:u/o,o==i)r=0;else{switch(o){case e:r=(t-n)/u+(t<n?6:0);break;case t:r=(n-e)/u+2;break;case n:r=(e-t)/u+4}r/=6}return{h:r,s:a,v:s}}function m(e,t,n,r){var a=[H(u(e).toString(16)),H(u(t).toString(16)),H(u(n).toString(16))];return r&&a[0].charAt(0)==a[0].charAt(1)&&a[1].charAt(0)==a[1].charAt(1)&&a[2].charAt(0)==a[2].charAt(1)?a[0].charAt(0)+a[1].charAt(0)+a[2].charAt(0):a.join("")}function _(e,t,n,r){return[H(N(r)),H(u(e).toString(16)),H(u(t).toString(16)),H(u(n).toString(16))].join("")}function y(e,t){t=0===t?0:t||10;var n=p(e).toHsl();return n.s-=t/100,n.s=j(n.s),p(n)}function g(e,t){t=0===t?0:t||10;var n=p(e).toHsl();return n.s+=t/100,n.s=j(n.s),p(n)}function v(e){return p(e).desaturate(100)}function b(e,t){t=0===t?0:t||10;var n=p(e).toHsl();return n.l+=t/100,n.l=j(n.l),p(n)}function w(e,t){t=0===t?0:t||10;var n=p(e).toRgb();return n.r=c(0,l(255,n.r-u(-t/100*255))),n.g=c(0,l(255,n.g-u(-t/100*255))),n.b=c(0,l(255,n.b-u(-t/100*255))),p(n)}function M(e,t){t=0===t?0:t||10;var n=p(e).toHsl();return n.l-=t/100,n.l=j(n.l),p(n)}function L(e,t){var n=p(e).toHsl(),r=(n.h+t)%360;return n.h=r<0?360+r:r,p(n)}function T(e){var t=p(e).toHsl();return t.h=(t.h+180)%360,p(t)}function k(e){var t=p(e).toHsl(),n=t.h;return[p(e),p({h:(n+120)%360,s:t.s,l:t.l}),p({h:(n+240)%360,s:t.s,l:t.l})]}function x(e){var t=p(e).toHsl(),n=t.h;return[p(e),p({h:(n+90)%360,s:t.s,l:t.l}),p({h:(n+180)%360,s:t.s,l:t.l}),p({h:(n+270)%360,s:t.s,l:t.l})]}function E(e){var t=p(e).toHsl(),n=t.h;return[p(e),p({h:(n+72)%360,s:t.s,l:t.l}),p({h:(n+216)%360,s:t.s,l:t.l})]}function S(e,t,n){t=t||6,n=n||30;var r=p(e).toHsl(),a=360/n,o=[p(e)];for(r.h=(r.h-(a*t>>1)+720)%360;--t;)r.h=(r.h+a)%360,o.push(p(r));return o}function O(e,t){t=t||6;for(var n=p(e).toHsv(),r=n.h,a=n.s,o=n.v,i=[],s=1/t;t--;)i.push(p({h:r,s:a,v:o})),o=(o+s)%1;return i}p.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var e=this.toRgb();return(299*e.r+587*e.g+114*e.b)/1e3},getLuminance:function(){var e,t,n,r=this.toRgb();return e=r.r/255,t=r.g/255,n=r.b/255,.2126*(e<=.03928?e/12.92:a.pow((e+.055)/1.055,2.4))+.7152*(t<=.03928?t/12.92:a.pow((t+.055)/1.055,2.4))+.0722*(n<=.03928?n/12.92:a.pow((n+.055)/1.055,2.4))},setAlpha:function(e){return this._a=A(e),this._roundA=u(100*this._a)/100,this},toHsv:function(){var e=h(this._r,this._g,this._b);return{h:360*e.h,s:e.s,v:e.v,a:this._a}},toHsvString:function(){var e=h(this._r,this._g,this._b),t=u(360*e.h),n=u(100*e.s),r=u(100*e.v);return 1==this._a?"hsv("+t+", "+n+"%, "+r+"%)":"hsva("+t+", "+n+"%, "+r+"%, "+this._roundA+")"},toHsl:function(){var e=f(this._r,this._g,this._b);return{h:360*e.h,s:e.s,l:e.l,a:this._a}},toHslString:function(){var e=f(this._r,this._g,this._b),t=u(360*e.h),n=u(100*e.s),r=u(100*e.l);return 1==this._a?"hsl("+t+", "+n+"%, "+r+"%)":"hsla("+t+", "+n+"%, "+r+"%, "+this._roundA+")"},toHex:function(e){return m(this._r,this._g,this._b,e)},toHexString:function(e){return"#"+this.toHex(e)},toHex8:function(e){return function(e,t,n,r,a){var o=[H(u(e).toString(16)),H(u(t).toString(16)),H(u(n).toString(16)),H(N(r))];if(a&&o[0].charAt(0)==o[0].charAt(1)&&o[1].charAt(0)==o[1].charAt(1)&&o[2].charAt(0)==o[2].charAt(1)&&o[3].charAt(0)==o[3].charAt(1))return o[0].charAt(0)+o[1].charAt(0)+o[2].charAt(0)+o[3].charAt(0);return o.join("")}(this._r,this._g,this._b,this._a,e)},toHex8String:function(e){return"#"+this.toHex8(e)},toRgb:function(){return{r:u(this._r),g:u(this._g),b:u(this._b),a:this._a}},toRgbString:function(){return 1==this._a?"rgb("+u(this._r)+", "+u(this._g)+", "+u(this._b)+")":"rgba("+u(this._r)+", "+u(this._g)+", "+u(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:u(100*C(this._r,255))+"%",g:u(100*C(this._g,255))+"%",b:u(100*C(this._b,255))+"%",a:this._a}},toPercentageRgbString:function(){return 1==this._a?"rgb("+u(100*C(this._r,255))+"%, "+u(100*C(this._g,255))+"%, "+u(100*C(this._b,255))+"%)":"rgba("+u(100*C(this._r,255))+"%, "+u(100*C(this._g,255))+"%, "+u(100*C(this._b,255))+"%, "+this._roundA+")"},toName:function(){return 0===this._a?"transparent":!(this._a<1)&&(Y[m(this._r,this._g,this._b,!0)]||!1)},toFilter:function(e){var t="#"+_(this._r,this._g,this._b,this._a),n=t,r=this._gradientType?"GradientType = 1, ":"";if(e){var a=p(e);n="#"+_(a._r,a._g,a._b,a._a)}return"progid:DXImageTransform.Microsoft.gradient("+r+"startColorstr="+t+",endColorstr="+n+")"},toString:function(e){var t=!!e;e=e||this._format;var n=!1,r=this._a<1&&this._a>=0;return t||!r||"hex"!==e&&"hex6"!==e&&"hex3"!==e&&"hex4"!==e&&"hex8"!==e&&"name"!==e?("rgb"===e&&(n=this.toRgbString()),"prgb"===e&&(n=this.toPercentageRgbString()),"hex"!==e&&"hex6"!==e||(n=this.toHexString()),"hex3"===e&&(n=this.toHexString(!0)),"hex4"===e&&(n=this.toHex8String(!0)),"hex8"===e&&(n=this.toHex8String()),"name"===e&&(n=this.toName()),"hsl"===e&&(n=this.toHslString()),"hsv"===e&&(n=this.toHsvString()),n||this.toHexString()):"name"===e&&0===this._a?this.toName():this.toRgbString()},clone:function(){return p(this.toString())},_applyModification:function(e,t){var n=e.apply(null,[this].concat([].slice.call(t)));return this._r=n._r,this._g=n._g,this._b=n._b,this.setAlpha(n._a),this},lighten:function(){return this._applyModification(b,arguments)},brighten:function(){return this._applyModification(w,arguments)},darken:function(){return this._applyModification(M,arguments)},desaturate:function(){return this._applyModification(y,arguments)},saturate:function(){return this._applyModification(g,arguments)},greyscale:function(){return this._applyModification(v,arguments)},spin:function(){return this._applyModification(L,arguments)},_applyCombination:function(e,t){return e.apply(null,[this].concat([].slice.call(t)))},analogous:function(){return this._applyCombination(S,arguments)},complement:function(){return this._applyCombination(T,arguments)},monochromatic:function(){return this._applyCombination(O,arguments)},splitcomplement:function(){return this._applyCombination(E,arguments)},triad:function(){return this._applyCombination(k,arguments)},tetrad:function(){return this._applyCombination(x,arguments)}},p.fromRatio=function(e,t){if("object"==typeof e){var n={};for(var r in e)e.hasOwnProperty(r)&&(n[r]="a"===r?e[r]:I(e[r]));e=n}return p(e,t)},p.equals=function(e,t){return!(!e||!t)&&p(e).toRgbString()==p(t).toRgbString()},p.random=function(){return p.fromRatio({r:d(),g:d(),b:d()})},p.mix=function(e,t,n){n=0===n?0:n||50;var r=p(e).toRgb(),a=p(t).toRgb(),o=n/100;return p({r:(a.r-r.r)*o+r.r,g:(a.g-r.g)*o+r.g,b:(a.b-r.b)*o+r.b,a:(a.a-r.a)*o+r.a})},p.readability=function(e,t){var n=p(e),r=p(t);return(a.max(n.getLuminance(),r.getLuminance())+.05)/(a.min(n.getLuminance(),r.getLuminance())+.05)},p.isReadable=function(e,t,n){var r,a,o=p.readability(e,t);switch(a=!1,(r=function(e){var t,n;t=((e=e||{level:"AA",size:"small"}).level||"AA").toUpperCase(),n=(e.size||"small").toLowerCase(),"AA"!==t&&"AAA"!==t&&(t="AA");"small"!==n&&"large"!==n&&(n="small");return{level:t,size:n}}(n)).level+r.size){case"AAsmall":case"AAAlarge":a=o>=4.5;break;case"AAlarge":a=o>=3;break;case"AAAsmall":a=o>=7}return a},p.mostReadable=function(e,t,n){var r,a,o,i,s=null,u=0;a=(n=n||{}).includeFallbackColors,o=n.level,i=n.size;for(var l=0;l<t.length;l++)(r=p.readability(e,t[l]))>u&&(u=r,s=p(t[l]));return p.isReadable(e,s,{level:o,size:i})||!a?s:(n.includeFallbackColors=!1,p.mostReadable(e,["#fff","#000"],n))};var D=p.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},Y=p.hexNames=function(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[e[n]]=n);return t}(D);function A(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function C(e,t){(function(e){return"string"==typeof e&&-1!=e.indexOf(".")&&1===parseFloat(e)})(e)&&(e="100%");var n=function(e){return"string"==typeof e&&-1!=e.indexOf("%")}(e);return e=l(t,c(0,parseFloat(e))),n&&(e=parseInt(e*t,10)/100),a.abs(e-t)<1e-6?1:e%t/parseFloat(t)}function j(e){return l(1,c(0,e))}function P(e){return parseInt(e,16)}function H(e){return 1==e.length?"0"+e:""+e}function I(e){return e<=1&&(e=100*e+"%"),e}function N(e){return a.round(255*parseFloat(e)).toString(16)}function R(e){return P(e)/255}var F,z,U,W=(z="[\\s|\\(]+("+(F="(?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?)")+")[,|\\s]+("+F+")[,|\\s]+("+F+")\\s*\\)?",U="[\\s|\\(]+("+F+")[,|\\s]+("+F+")[,|\\s]+("+F+")[,|\\s]+("+F+")\\s*\\)?",{CSS_UNIT:new RegExp(F),rgb:new RegExp("rgb"+z),rgba:new RegExp("rgba"+U),hsl:new RegExp("hsl"+z),hsla:new RegExp("hsla"+U),hsv:new RegExp("hsv"+z),hsva:new RegExp("hsva"+U),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/});function B(e){return!!W.CSS_UNIT.exec(e)}e.exports?e.exports=p:void 0===(r=function(){return p}.call(t,n,t,e))||(e.exports=r)}(Math)},function(e,t){e.exports=o},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.clearCachedAuth=t.login=t.AUTH_CACHE_KEY=void 0,t.AUTH_CACHE_KEY="imposium_hub_creds";t.login=function(e){try{localStorage.setItem(t.AUTH_CACHE_KEY,JSON.stringify(e))}catch(e){console.warn("Failed to cache auth creds...")}return{type:r.LOGIN,auth:e}};t.clearCachedAuth=function(){try{localStorage.removeItem(t.AUTH_CACHE_KEY)}catch(e){console.warn("Failed to remove cached creds")}return{type:r.CLEAR}};var r={LOGIN:"auth/LOGIN",CLEAR:"auth/CLEAR"};t.default=r},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},o=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0}),t.storyDeleted=t.storyNameMutated=t.orgNameMutated=t.storyAdded=t.clearCachedAccessList=t.cacheAccessData=t.ACCESS_CACHE_KEY=void 0;var i=n(27);t.ACCESS_CACHE_KEY="imposium_access_list";t.cacheAccessData=function(e){return s(e),{type:u.SET,accessData:e}};t.clearCachedAccessList=function(){try{localStorage.removeItem(t.ACCESS_CACHE_KEY)}catch(e){console.warn("Failed to clear access list cache from local storage.")}return{type:u.CLEAR}};t.storyAdded=function(e,t){return function(n,l){var c=l(),d=c.access,p=c.auth.idTokenPayload.exp,f=c.routing.locationBeforeTransitions.query.organization_id,h=r(r({},d),{organizations:d.organizations.map((function(n){return n.id===f?r(r({},n),{stories:o(o([],a(n.stories)),[{id:e,name:t}]).sort((function(e,t){return e.name.localeCompare(t.name)}))}):n}))});i.default.updateSession({stories_hash:i.default.generateStoriesHash(h)},p),s(h),n({type:u.STORY_ADDED,accessData:h})}};t.orgNameMutated=function(e,t){return function(n,a){var o=a(),l=o.access,c=o.auth.idTokenPayload.exp,d=r(r({},l),{organizations:l.organizations.map((function(n){return n.id===e?r(r({},n),{name:t}):n}))});i.default.updateSession({stories_hash:i.default.generateOrgsHash(d)},c),s(d),n({type:u.ORG_NAME_MUTATION,accessData:d})}};t.storyNameMutated=function(e,t){return function(n,a){var o=a(),l=o.access,c=o.auth.idTokenPayload.exp,d=o.routing.locationBeforeTransitions.query.organization_id,p=r(r({},l),{organizations:l.organizations.map((function(n){return n.id===d?r(r({},n),{stories:n.stories.map((function(n){return n.id===e?r(r({},n),{name:t}):n}))}):n}))});i.default.updateSession({stories_hash:i.default.generateOrgsHash(p)},c),s(p),n({type:u.STORY_NAME_MUTATION,accessData:p})}};t.storyDeleted=function(e){return function(t,n){var a=n(),o=a.access,l=a.auth.idTokenPayload.exp,c=a.routing.locationBeforeTransitions.query.organization_id,d=r(r({},o),{organizations:o.organizations.map((function(t){return t.id===c?r(r({},t),{stories:t.stories.filter((function(t){return t.id!==e}))}):t}))});i.default.updateSession({story_id:"",stories_hash:i.default.generateStoriesHash(d)},l),s(d),t({type:u.STORY_DELETED,accessData:d})}};var s=function(e){try{localStorage.setItem(t.ACCESS_CACHE_KEY,JSON.stringify(e))}catch(e){console.warn("Failed to cache access list in local storage.")}},u={SET:"access/SET",CLEAR:"access/CLEAR",STORY_ADDED:"access/STORY_ADDED",STORY_NAME_MUTATION:"access/STORY_NAME_MUTATION",ORG_NAME_MUTATION:"access/ORG_NAME_MUTATION",STORY_DELETED:"access/STORY_DELETED"};t.default=u},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(11),s=function(e){function t(t){var n=e.call(this,t)||this;return n.inputRef=o.createRef(),n}return a(t,e),t.prototype.onChange=function(e){var t=e.target.value;t=""===t?null:parseFloat(t),this.props.onChange(t)},t.prototype.onSelectFocus=function(){},t.prototype.onSelectBlur=function(){},t.prototype.handleLabelDrag=function(e){var t=this.props.value+e;this.props.onChange(t)},t.prototype.render=function(){var e=this,t=this.props,n=t.label,r=t.placeholder,a=t.width,s=t.readOnly,u=t.buttons,l=t.tooltip,c=t.info,d=t.labelPosition,p=t.min,f=t.max,h=this.props.value;return null===h&&(h=""),o.createElement(i.default,{customClass:"number-field",label:n,tooltip:l,buttons:u,info:c,labelPosition:d,width:a},o.createElement("input",{ref:this.inputRef,type:"number",pattern:"/^-?(0|[1-9]d*)(.d+)?$/",placeholder:r,value:h,readOnly:s,min:p,max:f,onFocus:function(){return e.onSelectFocus()},onBlur:function(){return e.onSelectBlur()},onChange:function(t){return e.onChange(t)}}))},t}(o.PureComponent);t.default=s},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,n){var r=n(110),a=n(68);e.exports=function(e){return null!=e&&a(e.length)&&!r(e)}},function(e,t,n){var r=n(386),a=n(387),o=n(388),i=n(389),s=n(390);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=a,u.prototype.get=o,u.prototype.has=i,u.prototype.set=s,e.exports=u},function(e,t,n){var r=n(74);e.exports=function(e,t){for(var n=e.length;n--;)if(r(e[n][0],t))return n;return-1}},function(e,t,n){var r=n(19)(Object,"create");e.exports=r},function(e,t,n){var r=n(408);e.exports=function(e,t){var n=e.__data__;return r(t)?n["string"==typeof t?"string":"hash"]:n.map}},function(e,t,n){var r=n(423),a=n(75),o=n(424),i=n(425),s=n(426),u=n(18),l=n(113),c=l(r),d=l(a),p=l(o),f=l(i),h=l(s),m=u;(r&&"[object DataView]"!=m(new r(new ArrayBuffer(1)))||a&&"[object Map]"!=m(new a)||o&&"[object Promise]"!=m(o.resolve())||i&&"[object Set]"!=m(new i)||s&&"[object WeakMap]"!=m(new s))&&(m=function(e){var t=u(e),n="[object Object]"==t?e.constructor:void 0,r=n?l(n):"";if(r)switch(r){case c:return"[object DataView]";case d:return"[object Map]";case p:return"[object Promise]";case f:return"[object Set]";case h:return"[object WeakMap]"}return t}),e.exports=m},function(e,t,n){var r=n(79);e.exports=function(e){if("string"==typeof e||r(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}},function(e,t,n){var r=n(125),a=n(126);e.exports=function(e,t,n,o){var i=!n;n||(n={});for(var s=-1,u=t.length;++s<u;){var l=t[s],c=o?o(n[l],e[l],l,n,e):void 0;void 0===c&&(c=e[l]),i?a(n,l,c):r(n,l,c)}return n}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(4),o=n(9),i=r.memo((function(e){if("string"!=typeof e.copy)throw new Error("Prop passed to Tag is not string: ");var t=e.colorize?""+o.string2HexCode(e.copy):"",n="function"==typeof e.removeHandler&&r.createElement("div",{className:"remove-tag",onClick:e.removeHandler},a.ICON_TIMES);return r.createElement("div",{key:e.copy,style:{borderLeftColor:t},className:"imposium-tag"},e.copy,n)}));t.default=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.cancelAssetUpload=t.uploadAssets=t.toggleAssignToStory=t.toggleAutoTag=void 0;var r=n(17),a=n(28),o={TOGGLE_AUTO_TAG:"assetUploads/TOGGLE_AUTO_TAG",TOGGLE_ASSIGN_TO_STORY:"assetUploads/TOGGLE_ASSIGN_TO_STORY",ADD_UPLOAD:"assetUploads/ADD_UPLOAD",UPDATE_PERCENT_UPLOADED:"assetUploads/UPDATE_PERCENT_UPLOADED",REMOVE_UPLOAD:"assetUploads/REMOVE_UPLOAD"};t.toggleAutoTag=function(e){return{type:o.TOGGLE_AUTO_TAG,toggle:e}};t.toggleAssignToStory=function(e){return{type:o.TOGGLE_ASSIGN_TO_STORY,toggle:e}};t.uploadAssets=function(e,t,n,s){return function(u,l){for(var c=l().assetUploads,d=c.autoTag,p=c.uploads,f=c.assignToStory,h=0,m=[],_=t.length>5?4:t.length-1,y=t.map((function(e){var t=p.filter((function(t){return t.filename.includes(e.name)})),n=t.length>0?e.name+" ("+t.length+")":e.name,r=d?e.name.substr(0,e.name.lastIndexOf(".")).split("_").join(","):"";return u({type:o.ADD_UPLOAD,uploadMeta:{filename:n,percent:0}}),{file:e,tags:r,filename:n,onUploadProgress:function(e){u({type:o.UPDATE_PERCENT_UPLOADED,percent:Math.floor(100*e.loaded/e.total),filename:n})}}})),g=function(t){var l=y.length,c=f&&n?n:null;e.uploadAsset(c,y[t].tags,y[t].file,y[t].onUploadProgress,y[t].filename).then((function(a){m.push((s&&s(a[0]),{footageId:a[0].id,jobId:a[0].job_id,filename:y[t].filename,onProcessed:function(){var t=m.filter((function(e){return e.jobId===a[0].job_id}))[0].filename;u({type:o.REMOVE_UPLOAD,filename:t}),r.doAssetTableHydration(e,n)}})),h!==l-1?g(h+=1):(m=m.filter((function(t,a){var i="string"==typeof t.jobId;return i||(u({type:o.REMOVE_UPLOAD,filename:t.filename}),r.doAssetTableHydration(e,n)),i}))).length>0&&i(e,m,-1)})).catch((function(e){a.default.isCancel(e)&&h!==l-1&&g(h+=1)}))},v=0;v<=_;v++)g(v),h=v}};var i=function(e,t,n){n=window.setTimeout((function(){var r=t.map((function(t){return e.getJob(t.jobId)}));Promise.all(r).then((function(r){var a;clearTimeout(n),r.forEach((function(e){"processing"!==e.status&&"completed"!==e.status||(a=t.find((function(t){return t.jobId===e.id})))&&(a.onProcessed(),t=t.filter((function(t){return t.jobId!==e.id})))})),t.length>0&&i(e,t,n)})).catch((function(e){console.error("Failed to poll for processing jobs:",e)}))}),5e3)};t.cancelAssetUpload=function(e,t){return function(n){t.cancelUploadAssets(e),n({type:o.REMOVE_UPLOAD,filename:e})}},t.default=o},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.getNewCompositionLayer=t.VARIABLE_TYPES=t.TEXT_SIZE_OPTIONS=t.DEFAULT_FONT=t.FILL_MODES=t.STADARD_FONTS=t.FONT_TYPE_OPTIONS=t.FONT_TYPES=void 0;var a=n(9);t.FONT_TYPES={STANDARD:"standard",CUSTOM:"custom"},t.FONT_TYPE_OPTIONS=[{label:"Standard",value:t.FONT_TYPES.STANDARD},{label:"Custom",value:t.FONT_TYPES.CUSTOM}],t.STADARD_FONTS=["Arial","Courier New","Georgia","Impact","Times New Roman","Trebuchet MS","Verdana"],t.FILL_MODES={FIT:"fit",FILL:"fill",STRETCH:"stretch"},t.DEFAULT_FONT="Arial",t.TEXT_SIZE_OPTIONS=[{label:"6px",value:6},{label:"8px",value:8},{label:"9px",value:9},{label:"10px",value:10},{label:"11px",value:11},{label:"12px",value:12},{label:"14px",value:14},{label:"16px",value:16},{label:"18px",value:18},{label:"24px",value:24},{label:"30px",value:30},{label:"36px",value:36},{label:"48px",value:48},{label:"60px",value:60},{label:"72px",value:72}],t.VARIABLE_TYPES={TEXT:"text",NUMBER:"number",BOOLEAN:"boolean",ENUM:"enum",IMAGE:"image",VIDEO:"video",AUDIO:"audio"};t.getNewCompositionLayer=function(){var e=r({},o);return e.id=a.generateUUID(),e};var o={id:null,x:0,y:0,width:200,height:100,rotation:0,name:"New Layer",content:"",color:"#000000",background_color:"transparent",font_size:24,font_type:"standard",font_weight:400,font:t.DEFAULT_FONT,custom_font_id:null,custom_font_url:null,letter_spacing:null,word_spacing:null,line_height:null,horizontal_alignment:"center",vertical_alignment:"center",text_wrap:!0,text_fit:!0}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e},s=this&&this.__values||function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(t,"__esModule",{value:!0}),t.BigLink=t.WizardError=t.TabHeader=t.TabContent=t.BigButton=void 0;var u=n(0),l=n(5),c=n(22),d=n(16),p=n(4),f=n(7),h=n(25),m=n(508),_=n(509),y=n(137),g=n(513),v=n(273),b=n(10),w=n(55),M=n(8),L=function(e){function n(t){var n=e.call(this,t)||this;return n.onSelectOption=function(e){n.props.publishData.publishing&&alert("WARNING: Your publish is still in progress, your changes will not be present in the rendered videos until the publish is complete"),n.setState({screenIndex:e,done:!1})},n.onCompositionChange=function(e){n.setState({selectedComposition:e})},n.onCredentialsChange=function(e){n.setState({accessKey:e})},n.nextClickHandler=function(){n.setState({nextStep:!0}),7===n.state.screenIndex&&n.emailWorkflow.current.getWrappedInstance().proceedWithExport()},n.onDoneHandler=function(){n.setState({done:!0,error:!1})},n.onErrorHandler=function(){n.setState({error:!n.state.error})},n.onNextHandler=function(e){n.setState({next:e})},n.state={compositions:[],selectedComposition:null,newPublish:!0,status:"",queryRunning:!0,publishMessage:"",screenIndex:0,accessKey:null,credentials:[],done:!1,error:!1,next:!1,nextStep:!1},n.emailWorkflow=u.createRef(),n.hiddenFileInputRef=u.createRef(),n}return a(n,e),n.prototype.componentDidMount=function(){var e=this,t=this.props,n=t.story,r=t.api,a=t.handleError,s=t.activeComposition;r.getAssets({type:h.ASSET_TYPES.VIDEO_COMPOSITION},n.id).then((function(t){var n=t.assets[0]?t.assets[0].id:null,r=s||n;e.setState({compositions:t.assets,selectedComposition:r})})).catch((function(e){a(f.integration.errorPullingComps)})),r.getAccssCredentials().then((function(t){0===t.length?r.createAccessCredentials("default").then((function(t){var n=e.state.credentials,r=i(i([],o(n)),[t]);e.setState({credentials:r,accessKey:t[0].access_key_id})})):e.setState({credentials:t,accessKey:t[0].access_key_id})})).catch((function(e){a(f.integration.errorGettingCreds)}))},n.prototype.checkStatus=function(){var e=this,t=this.props,n=t.project.storyId,r=t.api,a=t.handleError;n&&this.setState({queryRunning:!0,newPublish:!1,status:""},(function(){r.getStoryStatus(n).then((function(t){t?t.publishing&&e.setState({status:f.header.publishing},(function(){e.pollStatus(t.job_id)})):e.setState({queryRunning:!1,status:f.header.working})})).catch((function(t){e.setState({queryRunning:!1},(function(){404===t.response.status?e.setState({queryRunning:!1,status:f.header.working}):(a(f.header.statusError),e.setState({status:""}))}))}))}))},n.prototype.pollStatus=function(e){var t=this,n=this.props,r=n.api,a=n.handleError;r.pollJob(e).then((function(){t.checkStatus()})).catch((function(){a(f.header.publishPollError),t.setState({status:""})}))},n.prototype.handlePublish=function(){var e=this.props,t=e.story.id,n=e.api,r=e.handleError;this.props.publishVersion(n,t).catch((function(e){r(e)})),this.setState({screenIndex:1})},n.prototype.renderLowerButtons=function(){var e=this,t=this.state,n=t.screenIndex,r=t.done,a=t.error,o=t.next,i=this.props.publishing,s=[];if(0===n)s.push(u.createElement(l.default,{tooltip:f.publish.btnPublish,size:"large",disabled:i,key:"btn-publish",onClick:function(){return e.handlePublish()},color:"primary"},f.publish.btnPublish)),s.push(u.createElement(l.default,{tooltip:f.publish.btnSkip,key:"btn-skip",size:"large",onClick:function(){return e.setState({screenIndex:1})},color:"primary"},f.publish.btnSkip));else{(r||a)&&s.push(u.createElement(l.default,{tooltip:a?f.publish.btnCancel:f.publish.btnFinished,size:"large",key:"btn-finish",onClick:function(){return e.props.onClose()},color:"primary"},a?f.publish.btnCancel:f.publish.btnFinished));var c=1===n?0:1;s.push(u.createElement(l.default,{tooltip:f.publish.btnBack,size:"large",key:"btn-back",onClick:function(){return e.setState({screenIndex:c,next:!1,nextStep:!1,error:!1,done:!1})},color:"primary"},f.publish.btnBack)),a&&s.push(u.createElement(l.default,{tooltip:f.publish.btnNext,size:"large",key:"btn-next",color:"primary",disabled:!o,onClick:function(){return e.nextClickHandler()}},f.publish.btnNext))}return s},n.prototype.renderPublish=function(){return u.createElement("div",null,u.createElement("h2",null,f.publish.publishStepTitle),u.createElement(d.default,null),u.createElement("p",null,f.publish.publishStepDesc))},n.prototype.renderDistributionOptions=function(){var e,n,r,a,o=this,i=[],l=[],h=this.state,m=h.compositions,_=h.selectedComposition,y=h.credentials,g=h.accessKey;try{for(var v=s(m),b=v.next();!b.done;b=v.next()){var w=b.value;i.push({value:w.id,label:w.name})}}catch(t){e={error:t}}finally{try{b&&!b.done&&(n=v.return)&&n.call(v)}finally{if(e)throw e.error}}try{for(var M=s(y),L=M.next();!L.done;L=M.next()){var T=L.value;l.push({value:T.access_key_id,label:T.name})}}catch(e){r={error:e}}finally{try{L&&!L.done&&(a=M.return)&&a.call(M)}finally{if(r)throw r.error}}var k=[{label:u.createElement("span",null,p.ICON_GLOBE," ",f.publish.btnWebsite),onClick:function(e){return o.onSelectOption(2)}},{label:u.createElement("span",null,p.ICON_EMAIL," ",f.publish.btnEmail),onClick:function(e){return o.onSelectOption(3)}},{label:u.createElement("span",null,p.ICON_HUBSPOT," ",f.publish.btnHubspot),onClick:function(e){return o.onSelectOption(5)}},{label:u.createElement("span",null,p.ICON_PROJECT_DIAGRAM," ",f.publish.btnAPI),onClick:function(e){return o.onSelectOption(6)}},{label:u.createElement("span",null,p.ICON_DOWNLOAD," ",f.publish.btnExport),onClick:function(e){return o.onSelectOption(7)}}];return u.createElement("div",null,u.createElement("h2",null,f.publish.distributeStepTitle),u.createElement(d.default,null),u.createElement("p",null,f.publish.distributeStepDesc),u.createElement(d.default,null),!this.state.selectedComposition&&u.createElement("p",{className:"text-danger"},f.publish.noCompErrorDesc),u.createElement("div",{style:{marginTop:"10px"}},u.createElement(c.default,{label:f.project.compName,value:_,onChange:this.onCompositionChange,options:i,tooltip:f.project.tooltipCompId}),u.createElement(c.default,{label:f.publish.accessKey,value:g,onChange:this.onCredentialsChange,options:l,tooltip:f.publish.tooltipAccessKey}),u.createElement("div",{className:"link-wrapper"},null==k?void 0:k.map((function(e,n){return u.createElement(t.BigButton,{key:n,disabled:!o.state.selectedComposition,label:e.label,onClick:e.onClick})})))))},n.prototype.render=function(){var e,t=this.props,n=t.story,r=t.project,a=t.api,o=t.handleError,i=t.createFreshBatch,s=t.getBatches,l=t.getBatchExport,c=t.importBatchFromCsv,p=t.handleNotification,h=t.renderBatch,b=t.batchJobs,w=this.state,M=w.screenIndex,L=w.status,T=w.selectedComposition,k=w.compositions,x=w.accessKey,E=w.error,S=w.nextStep,O=(null===(e=k.find((function(e){return e.id===T})))||void 0===e?void 0:e.name)||"",D=n?n.acts[r.actId].inventory:{};return u.createElement("div",{className:"publish-wizard"},u.createElement("div",{className:"publish-wizard-header"},f.publish.publishTitle,u.createElement(v.default,{api:a})),u.createElement("div",null,0===M&&this.renderPublish(),1===M&&this.renderDistributionOptions(),2===M&&u.createElement(y.default,{story:n,compositionId:T,accessKey:x}),(3===M||7===M)&&u.createElement(g.default,{isExport:7===M,api:a,story:n,variables:D,onDone:this.onDoneHandler,onError:this.onErrorHandler,onNext:this.onNextHandler,error:E,status:L,renderBatch:h,batchJobs:b,accessKey:x,compositionId:T,compositionName:O,handleError:o,createFreshBatch:i,getBatches:s,getBatchExport:l,importBatchFromCsv:c,next:S,ref:this.emailWorkflow}),5===M&&u.createElement(m.default,{handleError:o,status:L,accessKey:x,story:n,handleNotification:p,compositionId:T}),6===M&&u.createElement(_.default,null),u.createElement("br",null),u.createElement(d.default,null),u.createElement("div",{className:"lower-buttons"},this.renderLowerButtons())))},n}(u.PureComponent);t.default=M.connect((function(e){return{publishData:e.publish}}),(function(e){return b.bindActionCreators({publishVersion:w.publishVersion},e)}))(L);t.BigButton=function(e){return u.createElement("div",{className:"big-link "+(e.disabled&&"disabled"),onClick:function(){return e.onClick()},style:e.style},u.createElement("h1",null,e.label))};t.TabContent=function(e){var t=e.children;return u.createElement("div",{className:"tab-content"},u.createElement("div",{className:"settings-tab"},u.createElement("div",{className:"integration-details"},t)))};t.TabHeader=function(e){var t=e.className,n=e.title;return u.createElement("div",{className:"tab-header"},u.createElement("div",{className:t||"tab-header-option active"},n))};t.WizardError=function(e){var t=e.description,n=e.title;return u.createElement("div",{className:"publish-wizard-error"},u.createElement("h3",null,n),u.createElement("p",null,t))};t.BigLink=function(e){return u.createElement("a",{className:"big-link",target:"_blank",href:e.link},u.createElement("h1",null,e.label))}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.clearStoryPublishStatus=t.publishVersion=t.cancelPublish=t.getStoryPublishStatus=void 0;var r=n(7),a={CLEAR_PUBLISH_STATUS:"publish/CLEAR_PUBLISH_STATUS",UPDATE_PUBLISH_STATUS:"publish/UPDATE_PUBLISH_STATUS"};t.getStoryPublishStatus=function(e,n){return function(o){return new Promise((function(i,s){e.getStoryStatus(n).then((function(i){if(i&&(o({type:a.UPDATE_PUBLISH_STATUS,data:i}),i.publishing)){var u=i.job_id;e.pollJob(u).then((function(){return o(t.getStoryPublishStatus(e,n))})).catch((function(e){console.error(e),s(r.header.publishPollError)}))}})).catch((function(e){var t;404!==(null===(t=null==e?void 0:e.response)||void 0===t?void 0:t.status)&&(console.error(e),s(r.header.publishPollError))}))}))}};t.cancelPublish=function(e,n){return function(r){return new Promise((function(a,o){e.cancelPublish(n).then((function(){e.cancelJobPolling().then((function(){r(t.getStoryPublishStatus(e,n))})).catch((function(e){throw o(e),e}))})).catch((function(e){throw o(e),e}))}))}};t.publishVersion=function(e,n){return function(a){return new Promise((function(o,i){e.runPublish(n,"").then((function(r){a(t.getStoryPublishStatus(e,n))})).catch((function(){i(r.header.publishJobError)}))}))}};t.clearStoryPublishStatus=function(e){return function(t){e.cancelJobPolling(),t({type:a.CLEAR_PUBLISH_STATUS})}},t.default=a},function(e,t,n){"use strict";(function(e){var n="object"==typeof e&&e&&e.Object===Object&&e;t.a=n}).call(this,n(38))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=[],a="M224 256A128 128 0 1 0 96 128a128 128 0 0 0 128 128zm96 64a63.08 63.08 0 0 1 8.1-30.5c-4.8-.5-9.5-1.5-14.5-1.5h-16.7a174.08 174.08 0 0 1-145.8 0h-16.7A134.43 134.43 0 0 0 0 422.4V464a48 48 0 0 0 48 48h280.9a63.54 63.54 0 0 1-8.9-32zm288-32h-32v-80a80 80 0 0 0-160 0v80h-32a32 32 0 0 0-32 32v160a32 32 0 0 0 32 32h224a32 32 0 0 0 32-32V320a32 32 0 0 0-32-32zM496 432a32 32 0 1 1 32-32 32 32 0 0 1-32 32zm32-144h-64v-80a32 32 0 0 1 64 0z";t.definition={prefix:"fas",iconName:"user-lock",icon:[640,512,r,"f502",a]},t.faUserLock=t.definition,t.prefix="fas",t.iconName="user-lock",t.width=640,t.height=512,t.ligatures=r,t.unicode="f502",t.svgPathData=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=[],a="M569.517 440.013C587.975 472.007 564.806 512 527.94 512H48.054c-36.937 0-59.999-40.055-41.577-71.987L246.423 23.985c18.467-32.009 64.72-31.951 83.154 0l239.94 416.028zM288 354c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z";t.definition={prefix:"fas",iconName:"exclamation-triangle",icon:[576,512,r,"f071",a]},t.faExclamationTriangle=t.definition,t.prefix="fas",t.iconName="exclamation-triangle",t.width=576,t.height=512,t.ligatures=r,t.unicode="f071",t.svgPathData=a},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=function(e){function t(n){var r=e.call(this,n)||this;return r.resizeHandler=function(){return r.onResize()},r.clickHandler=function(e){return r.detectOutsideClick(e)},r.escHandler=function(e){return r.onEsc(e)},r.dropdownRef=null,r.onResize=function(){var e=r.props.toggleRef;if(void 0!==e){var t=e.current.getBoundingClientRect(),n=t.top,a=t.left,o=t.bottom,i=t.right;r.setState({offset:{top:n,left:a,bottom:o,right:i}})}},r.cancelRender=function(e){void 0===e&&(e=!1);var t=r.props.onOutsideClick;window.removeEventListener("resize",r.resizeHandler),window.removeEventListener("mousedown",r.clickHandler),window.addEventListener("keydown",r.onEsc),r.setState({build:!1,offset:{}}),e&&t()},r.onEsc=function(e){e.keyCode===t.ESC_CODE&&r.cancelRender(!0)},r.detectOutsideClick=function(e){var t=r.props.toggleRef,n=e.target,a=!(!r.dropdownRef.current||!r.dropdownRef.current.contains(n)),o=!!(t&&t.current&&t.current.contains(n));a||o||r.cancelRender(!0)},r.state={build:!1,offset:{}},r.dropdownRef=o.createRef(),r}return a(t,e),t.prototype.componentDidUpdate=function(e){var t=this;this.props.show&&!e.show&&(this.onResize(),this.setState({build:!0},(function(){window.addEventListener("resize",t.resizeHandler),window.addEventListener("mousedown",t.clickHandler),window.addEventListener("keydown",t.onEsc)}))),!this.props.show&&e.show&&this.cancelRender()},t.prototype.render=function(){var e=this.state,t=e.build,n=e.offset,r=this.props,a=r.show,i=r.position,s=r.children,u={position:r.fixed?"fixed":"absolute",transform:t?"scaleY(1)":"scaleY(0)",opacity:t?"1":"0"};if(!a)return null;if(n){var l=document.documentElement.clientWidth,c=(n.top,n.left),d=n.bottom,p=n.right;switch(i){case"topleft":case"topright":case"bottomleft":u.top=d+5+"px",u.left=c+"px",u.transformOrigin="top left";break;case"bottomright":u.top=d+5+"px",u.right=l-p+"px",u.transformOrigin="top right"}}return o.createElement("div",{className:"imposium-dropdown",style:u,ref:this.dropdownRef},s)},t.ESC_CODE=27,t}(o.PureComponent);t.default=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.renderTooltip=t.renderTooltipProps=void 0;var r=n(0),a=n(35),o=n(353);t.renderTooltipProps=function(e,t){return t?{"data-tip":"object"==typeof t?t.content:t,"data-for":e}:{}};t.renderTooltip=function(e,t){var n=document.getElementById("tooltips");if(t&&n){var i="light",s="top";"object"==typeof t&&(i=t.theme?t.theme:"light",s=t.position?t.position:"top");var u=r.createElement(o,{place:s,offset:{top:0,right:0,bottom:0,left:0},id:e,className:"imposium-button-tooltip-"+i,delayShow:1e3,effect:"solid"});return a.createPortal(u,n)}return null}},function(e,t){e.exports=i},function(e,t){e.exports=s},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(11),u=n(60),l=function(e){function t(t){var n=e.call(this,t)||this;return n.clickCounter=0,n.handleMultipleClicks=function(e,t){n.clickCounter++,1===n.clickCounter&&(n.clickTimeout=window.setTimeout((function(){n.clickCounter=0,e()}),300)),2===n.clickCounter&&(clearTimeout(n.clickTimeout),n.clickCounter=0,t())},n.render=function(){var e=n.props,t=e.value,r=e.label,a=e.options,l=e.width,c=e.tooltip,d=e.info,p=e.labelPosition,f={width:100/a.length+"%"};return i.createElement(s.default,{customClass:"button-group-field",label:r,tooltip:c,info:d,labelPosition:p,width:l},i.createElement("div",{className:"button-group"},a.map((function(e,r){var a=e.value,s=e.label,l=e.icon?e.icon:null,c=a+"-"+r,d=a===t,p=d?"active":"",h=d?null:function(){n.props.onChange(a)};return i.createElement("div",o({key:"option-"+a,style:f,className:"button-group-option "+p},u.renderTooltipProps(c,e.tooltip),{onClick:"function"==typeof e.onDoubleClick?function(){return n.handleMultipleClicks(h,e.onDoubleClick)}:h}),l||s,u.renderTooltip(c,e.tooltip))}))))},n}return a(t,e),t}(i.PureComponent);t.default=l},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(0),u=n(5),l=n(11),c=n(4),d=function(e){function t(t){var n=e.call(this,t)||this;return n.state={internalValue:t.value,editing:!1},n.evtHandlers={toggleEditing:function(e){return n.toggleEditing(e)},copyToClipboard:function(e){return n.copyToClipboard(e)}},n.inputRef=s.createRef(),n}return a(t,e),t.prototype.blur=function(e){this.props.onBlur&&this.props.onBlur(e)},t.prototype.copyToClipboard=function(e){var t=this.props,n=t.onNotification,r=t.onError;navigator.clipboard.writeText(this.props.value).then((function(){n&&n("Copied to clipboard!")}),(function(){r&&r("Error copying to clipboard.")}))},t.prototype.focus=function(e){this.props.onFocus&&this.props.onFocus(e)},t.prototype.getValue=function(){var e=this.props,t=e.controlled,n=e.value,r=this.state.internalValue;return t?r:n},t.prototype.onChange=function(e){this.props.controlled?this.setState({internalValue:e.target.value}):this.props.onChange(e.target.value)},t.prototype.renderButtons=function(){var e=this.props,t=e.controlled,n=(e.readOnly,e.buttons),r=e.showCopy,a=this.state.editing,l=n?i([],o(n)):[];if(t){var d=a?c.ICON_CHECK:c.ICON_EDIT;l.push(s.createElement(u.default,{key:"btn-edit",style:"subtle",color:"secondary",onClick:this.evtHandlers.toggleEditing},d))}return r&&l.push(s.createElement(u.default,{key:"btn-copy",style:"subtle",tooltip:"Copy to Clipboard",color:"primary",onClick:this.evtHandlers.copyToClipboard},c.ICON_CLIPBOARD)),l},t.prototype.toggleEditing=function(e){var t=this,n=this.state,r=n.editing,a=n.internalValue,o=this.props.value;r?this.setState({editing:!1},(function(){a!==o&&t.props.onSubmit(t.state.internalValue)})):this.setState({editing:!0},(function(){var e=t.inputRef.current;e&&e.focus()}))},t.prototype.componentDidUpdate=function(e){this.props.controlled&&e.value!==this.props.value&&this.setState({internalValue:this.props.value})},t.prototype.render=function(){var e=this,t=this.props,n=t.label,r=t.placeholder,a=t.controlled,o=t.disabled,i=t.readOnly,u=t.width,c=t.tooltip,d=t.info,p=t.labelPosition,f=this.state.editing,h=a&&!f||o;return s.createElement(l.default,{customClass:"text-area-field",label:n,tooltip:c,buttons:this.renderButtons(),info:d,labelPosition:p,width:u},s.createElement("textarea",{placeholder:r,value:this.getValue(),disabled:h,readOnly:i,ref:this.inputRef,onChange:function(t){return e.onChange(t)},onFocus:function(t){return e.focus(t)},onBlur:function(t){return e.blur(t)}}))},t}(s.PureComponent);t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(11),s=n(531),u=function(e){function t(t){var n=e.call(this,t)||this;return n.transparentBg='url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAMUlEQVQ4T2NkYGAQYcAP3uCTZhw1gGGYhAGBZIA/nYDCgBDAm9BGDWAAJyRCgLaBCAAgXwixzAS0pgAAAABJRU5ErkJggg==") left center',n.state={pickerOpen:!1},n.picker=o.createRef(),n.clickOutsideHandler=function(e){return n.handleClickOutside(e)},n}return a(t,e),t.prototype.togglePicker=function(e){var t=this;e.preventDefault(),e.stopPropagation();var n=!this.state.pickerOpen;this.setState({pickerOpen:n},(function(){t.state.pickerOpen?document.addEventListener("click",t.clickOutsideHandler):document.removeEventListener("click",t.clickOutsideHandler)}))},t.prototype.handleClickOutside=function(e){var t=e.target,n=this.picker.current;do{if(t===n)return;t=t.parentNode}while(t);document.removeEventListener("click",this.clickOutsideHandler),this.setState({pickerOpen:!1})},t.prototype.handleChangeComplete=function(e,t){return this.props.onChange(e)},t.prototype.render=function(){var e,t=this,n=this.props,r=n.label,a=(n.placeholder,n.width),u=(n.readOnly,n.buttons),l=n.tooltip,c=n.value,d=n.enableAlpha,p=n.presetColors,f=n.info,h=n.labelPosition,m=!d,_=n.pickerPosition||"left",y=this.state.pickerOpen?o.createElement(s.SketchPicker,{color:c,disableAlpha:m,presetColors:p,onChangeComplete:function(e,n){return t.handleChangeComplete(e,n)}}):null;return e="transparent"===c?{background:this.transparentBg,border:"1px solid #1d1d1d",boxSizing:"border-box"}:{backgroundColor:c},o.createElement(i.default,{customClass:"color-field",label:r,tooltip:l,buttons:u,info:f,labelPosition:h,width:a},o.createElement("div",{className:"swatch",style:e,onClick:function(e){return t.togglePicker(e)}}),o.createElement("div",{className:"picker picker-"+_,ref:this.picker},y))},t}(o.PureComponent);t.default=u},function(e,t,n){var r=n(104),a=n(380);e.exports=function(e,t){return e&&r(e,a(t))}},function(e,t,n){(function(e){var r=n(14),a=n(376),o=t&&!t.nodeType&&t,i=o&&"object"==typeof e&&e&&!e.nodeType&&e,s=i&&i.exports===o?r.Buffer:void 0,u=(s?s.isBuffer:void 0)||a;e.exports=u}).call(this,n(42)(e))},function(e,t){e.exports=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}},function(e,t){e.exports=function(e){return function(t){return e(t)}}},function(e,t,n){(function(e){var r=n(103),a=t&&!t.nodeType&&t,o=a&&"object"==typeof e&&e&&!e.nodeType&&e,i=o&&o.exports===a&&r.process,s=function(){try{var e=o&&o.require&&o.require("util").types;return e||i&&i.binding&&i.binding("util")}catch(e){}}();e.exports=s}).call(this,n(42)(e))},function(e,t){var n=Object.prototype;e.exports=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||n)}},function(e,t,n){var r=n(109)(Object.getPrototypeOf,Object);e.exports=r},function(e,t,n){var r=n(44),a=n(391),o=n(392),i=n(393),s=n(394),u=n(395);function l(e){var t=this.__data__=new r(e);this.size=t.size}l.prototype.clear=a,l.prototype.delete=o,l.prototype.get=i,l.prototype.has=s,l.prototype.set=u,e.exports=l},function(e,t){e.exports=function(e,t){return e===t||e!=e&&t!=t}},function(e,t,n){var r=n(19)(n(14),"Map");e.exports=r},function(e,t,n){var r=n(400),a=n(407),o=n(409),i=n(410),s=n(411);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=a,u.prototype.get=o,u.prototype.has=i,u.prototype.set=s,e.exports=u},function(e,t,n){var r=n(422),a=n(120),o=Object.prototype.propertyIsEnumerable,i=Object.getOwnPropertySymbols,s=i?function(e){return null==e?[]:(e=Object(e),r(i(e),(function(t){return o.call(e,t)})))}:a;e.exports=s},function(e,t,n){var r=n(12),a=n(79),o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,i=/^\w*$/;e.exports=function(e,t){if(r(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!a(e))||(i.test(e)||!o.test(e)||null!=t&&e in Object(t))}},function(e,t,n){var r=n(18),a=n(15);e.exports=function(e){return"symbol"==typeof e||a(e)&&"[object Symbol]"==r(e)}},function(e,t,n){var r=n(105),a=n(451),o=n(43);e.exports=function(e){return o(e)?r(e,!0):a(e)}},function(e,t,n){var r=n(116);e.exports=function(e){var t=new e.constructor(e.byteLength);return new r(t).set(new r(e)),t}},function(e,t){e.exports=function(e){if(!e.webpackPolyfill){var t=Object.create(e);t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),Object.defineProperty(t,"exports",{enumerable:!0}),t.webpackPolyfill=1}return t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.addAssetTagToList=t.getAssetTagList=void 0;var r={GET:"assetTags/GET",ADD:"assetTags/ADD"};t.getAssetTagList=function(e,t){return function(n){return new Promise((function(a,o){e.getAssetTags(t).then((function(e){n({type:r.GET,assetTags:e}),a()})).catch((function(e){console.error("Failed to get tag list",e),o()}))}))}};t.addAssetTagToList=function(e){return{type:r.ADD,freshTags:e}},t.default=r},function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i};Object.defineProperty(t,"__esModule",{value:!0});var a=n(0),o=n(478),i=n(61);t.default=function(e){var t=r(i.useDrop({accept:[o.NativeTypes.FILE],drop:function(t,n){e.onDrop&&e.onDrop(e,n)},collect:function(e){return{isOver:e.isOver,canDrop:e.canDrop}}}),2),n=t[0],s=(n.canDrop,n.isOver,t[1]);return a.createElement("div",{className:e.className||"",ref:e.disable?void 0:s},e.children)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(25),o=n(7),i=n(4),s=r.memo((function(e){var t={color:a.ASSET_COLORS[e.type]};switch(e.type){case"filter":return r.createElement("span",null,i.ICON_FILTER);case"all":return r.createElement("span",{title:o.assets.iconTypes.all},i.ICON_TIMES);case a.ASSET_TYPES.VIDEO:return r.createElement("span",{title:o.assets.iconTypes.video,style:t},i.ICON_VIDEO);case a.ASSET_TYPES.AUDIO:return r.createElement("span",{title:o.assets.iconTypes.audio,style:t},i.ICON_AUDIO_TYPE);case a.ASSET_TYPES.IMAGE:return r.createElement("span",{title:o.assets.iconTypes.image,style:t},i.ICON_IMAGE);case a.ASSET_TYPES.IMAGE_SEQUENCE:return r.createElement("span",{title:o.assets.iconTypes.image_sequence,style:t},i.ICON_IMAGE_SEQ_TYPE);case a.ASSET_TYPES.TEMPLATE:return r.createElement("span",{title:o.assets.iconTypes.template,style:t},i.ICON_FILE_ARCHIVE);case a.ASSET_TYPES.VIDEO_COMPOSITION:return r.createElement("span",{title:o.assets.iconTypes.video_composition,style:t},i.ICON_LAYER_GROUP);case a.ASSET_TYPES.LUT:return r.createElement("span",{title:o.assets.iconTypes.lut},i.ICON_CUBE);case a.ASSET_TYPES.FONT:return r.createElement("span",{title:o.assets.iconTypes.font},i.ICON_FONT);case a.ASSET_TYPES.STATIC_COMPOSITION:return r.createElement("span",{title:o.assets.iconTypes.static_composition},i.ICON_FILE_CODE);default:return null}}));t.default=s},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(25),s=n(53),u=n(9),l=function(e){function t(t){var n=e.call(this,t)||this;return n.state={fontError:!1,fontLoaded:!1},n.innerTextRef=o.createRef(),n}return a(t,e),t.prototype.componentDidMount=function(){this.loadFont()},t.prototype.componentDidUpdate=function(e){var t=this.state.fontLoaded,n=this.props.options,r=n.font,a=n.custom_font_id,o=n.content;e.options.font===r&&e.options.custom_font_id===a||this.loadFont(),e.options.content!==o&&t&&this.fitText()},t.prototype.fitElement=function(e,t,n){for(var r=window.getComputedStyle(e,null),a=parseFloat(r.getPropertyValue("font-size")),o=parseFloat(r.getPropertyValue("letter-spacing")),i=parseFloat(r.getPropertyValue("line-height")),s=parseFloat(r.getPropertyValue("word-spacing")),u=o/a,l=i/a,c=s/a,d=e.offsetWidth,p=e.offsetHeight;d>t||p>n;)a--,o=Math.round(a*u),i=Math.round(a*l),s=Math.round(a*c),e.style.fontSize=a+"px",e.style.letterSpacing=o+"px",e.style.wordSpacing=s+"px",e.style.lineHeight=i+"px",d=e.offsetWidth,p=e.offsetHeight},t.prototype.loadFont=function(){var e=this,t=this.props.options,n=t.font,r=t.font_size,a=t.font_type,o=t.custom_font_url;if(a===s.FONT_TYPES.CUSTOM&&r&&o){var l=u.s3Url(o,i.ASSET_DISTRO,i.ASSET_ORIGIN),c=!1;try{c=document.fonts.check(r+"px "+n)}catch(e){this.errorLoadingFont()}c?this.fontReady():this.setState({fontLoaded:!1},(function(){var t=new FontFace(n,"url("+l+")",{style:"normal",weight:"normal"});t.load().then((function(n){document.fonts.add(t),e.fontReady()})).catch((function(t){e.errorLoadingFont()}))}))}else a===s.FONT_TYPES.STANDARD&&this.fontReady()},t.prototype.formatContent=function(){var e=this.props,t=e.options.content,n=e.inventory,r=t||"";if(n)for(var a in n)if(n.hasOwnProperty(a)){var i=new RegExp("{{"+a+"}}","g"),s=n[a];s&&(s=s.toString(),r=r.replace(i,s))}for(var u=r.split("\n"),l=[],c=0;c<u.length;c++)l.push(o.createElement("span",{key:"s-"+c},u[c])),u[c+1]&&l.push(o.createElement("br",{key:"b-"+c}));return l},t.prototype.fitText=function(){if(this.props.options.text_fit){var e=this.innerTextRef.current;e&&this.fitElement(e,this.props.options.width,this.props.options.height)}},t.prototype.errorLoadingFont=function(){var e=this;this.setState({fontError:!0},(function(){e.fontReady()}))},t.prototype.fontReady=function(){var e=this;this.setState({fontLoaded:!0},(function(){e.fitText(),e.props.onReady&&e.props.onReady()}))},t.prototype.getFlexStart=function(e){switch(e){case"left":return"flex-start";case"center":return"center";case"right":return"flex-end"}},t.prototype.render=function(){var e=this.props.options,t=e.color,n=e.background_color,r=e.line_height,a=e.word_spacing,i=e.letter_spacing,s=e.font_size,u=e.font_weight,l=e.font,c=e.horizontal_alignment,d=e.vertical_alignment,p={color:t,lineHeight:r?r+"px":"normal",wordSpacing:a?a+"px":"normal",letterSpacing:i?i+"px":"normal",fontSize:s?s+"px":"0px",fontWeight:u||400,whiteSpace:e.text_wrap?"normal":"nowrap",fontFamily:this.state.fontError?"Arial, helvetica, sans-serif":l},f={display:"flex",textAlign:c,justifyContent:this.getFlexStart(c),alignItems:d,backgroundColor:n};return o.createElement("div",{className:"composition-text-layer",style:f},o.createElement("div",{className:"inner-text",style:p,ref:this.innerTextRef},this.formatContent()))},t}(o.PureComponent);t.default=l},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(35);t.default=function(e){var t=e.children,n=e.id,o=document.getElementById(n),i=document.createElement("div");return r.useEffect((function(){return o.appendChild(i),function(){o.removeChild(i)}}),[i,o]),a.createPortal(t,i)}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.persistColumns=t.getBatch=t.updateAssociation=t.addPredefinedColumn=t.setPage=t.BATCH_ITEMS_PER_PAGE=void 0;var a=n(102);t.BATCH_ITEMS_PER_PAGE=50;var o={name:"experience_id",type:"EGC",from_import:0,detail:"id"},i={TOGGlE_LOADING:"activeBatch/TOGGLE_LOADING",TOGGLE_UPDATING:"activeBatch/TOGGLE_UPDATING",SET_BATCH:"activeBatch/SET_BATCH",ADD_COLUMN:"activeBatch/ADD_COLUMN",UPDATE_ASSOCIATION:"activeBatch/UPDATE_ASSOCIATION",REPLACE_ASSOCIATION_OPTIONS:"activeBatch/REPLACE_ASSOCIATION_OPTIONS",SET_PAGE:"activeBatch/SET_PAGE"};t.setPage=function(e){return{type:i.SET_PAGE,page:e}};t.addPredefinedColumn=function(e,n){return function(r){r({type:i.ADD_COLUMN,columnData:n}),r(t.persistColumns(e))}};t.updateAssociation=function(e,n,r,a){return function(o){o({type:i.UPDATE_ASSOCIATION,colIndex:n,newType:r,newAssociation:a}),o(t.persistColumns(e))}};t.getBatch=function(e){return function(n,r){var a=r(),s=a.story,c=a.batchesList.selected,d=a.activeBatch.page;return new Promise((function(r,a){n({type:i.TOGGlE_LOADING,toggle:!0}),e.getBatch(c.id,d).then((function(r){n({type:i.SET_BATCH,batch:r});var a=function(){var e=s.data?s.data.acts:s.acts,t=u(e),r=l(e),a=Object.keys(t).map((function(e){return{label:t[e].name,value:t[e].id}}));a.push({label:"composition_id",value:"composition_id"}),a.push({label:"composition_tag",value:"composition_tag"}),n({type:i.REPLACE_ASSOCIATION_OPTIONS,associationOptions:{UGC:a,EGC:r}}),n({type:i.TOGGlE_LOADING,toggle:!1})};0===r.columns.length?(n(t.addPredefinedColumn(e,o)),a()):a()})).catch((function(e){console.error("Failed to load batch:",e),n({type:i.TOGGlE_LOADING,toggle:!1}),a(e)}))}))}};t.persistColumns=function(e){return function(t,n){var r=n().activeBatch.data,a=r.id,o=r.columns;return t({type:i.TOGGLE_UPDATING,toggle:!0}),new Promise((function(n,r){e.updateBatchColumns(a,o).catch((function(n){return t(s(e,n))})).then((function(){t({type:i.TOGGLE_UPDATING,toggle:!1})}))}))}};var s=function(e,n){return function(r){console.error("Failed to update data set:",n),a.default.emit("error","Failed to update data set"),r(t.getBatch(e))}},u=function(e){var t=Object.keys(e),n={};return t.forEach((function(t){n=r(r({},n),e[t].inventory)})),n},l=function(e){var t,n,r=[],a=[],o=e[Object.keys(e)[0]];return void 0===o?[]:(t=Object.keys(o.scenes),void 0===(n=o.scenes[t[0]])?[]:(r.push({label:"Experience Id",value:"id"},{label:"Story Id",value:"story_id"}),n.sceneData.encodingSettings.forEach((function(e){if(e.extension&&e.height){var t=e.name,n=e.extension+"_"+e.height;void 0===a[n]&&(a[n]=0),a[n]++,r.push({label:t,value:1===a[n]?"video_url_"+n:"video_url_"+n+"_"+a[n].toString()})}})),n.exportAsPlaylist&&r.push({label:"M3U8",value:"video_url_m3u8"}),n.sceneData.savePosterFrame&&r.push({label:"Poster Frame",value:"poster"}),n.sceneData.saveSnapshotFrame&&r.push({label:"Snapshot Frame",value:"snapshot"}),n.sceneData.saveSocialFrame&&r.push({label:"Social Frame",value:"social"}),r))};t.default=i},function(e,t,n){"use strict";(function(e){var r=n(56),a="object"==typeof exports&&exports&&!exports.nodeType&&exports,o=a&&"object"==typeof e&&e&&!e.nodeType&&e,i=o&&o.exports===a&&r.a.process,s=function(){try{var e=o&&o.require&&o.require("util").types;return e||i&&i.binding&&i.binding("util")}catch(e){}}();t.a=s}).call(this,n(82)(e))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AssetsTableTypeCell=t.AssetsTableTypeFilter=t.AssetsTableSelectCell=t.AssetsTableSelectFilter=t.AssetsTablePreviewCell=t.AssetsTableDropzone=t.AssetsTableDateCell=t.AssetsTypeIcon=t.ImageSequencePlayer=t.ImagePreview=t.VideoPreview=t.AudioPlayer=t.VideoPlayer=t.ImagePlayer=t.AssetDetails=t.Portal=t.ShortcutMenu=t.StoryPreviewer=t.LogViewer=t.ServiceIcon=t.NoAccess=t.Spinner=t.DeterminateLoader=t.Section=t.SliderField=t.ToastService=t.TextAreaField=t.TextField=t.Tag=t.Tabs=t.ColorField=t.SelectField=t.NumberField=t.Modal=t.ListField=t.HRule=t.FieldWrapper=t.DataTablePaginator=t.DataTable=t.ControlledList=t.CheckboxField=t.Card=t.ButtonMenuItem=t.ButtonMenu=t.ButtonGroupField=t.Button=t.ImposiumDropdown=t.ImposiumHeader=t.AuthGate=t.AppWrapper=void 0,t.SessionService=t.AuthService=t.batchActions=t.activeBatch=t.assetActions=t.assetTags=t.addAssetTagToList=t.getAssetTagList=t.selectedAssets=t.assetUploads=t.assetList=t.assetFilters=t.resetSelection=t.deselectAsset=t.selectAsset=t.uploadAssets=t.toggleAutoTag=t.doAssetTableHydration=t.updateAssetData=t.updateAssetName=t.deleteAssetTag=t.addAssetTag=t.deleteAssets=t.getAssets=t.updateFilters=t.storyDeleted=t.orgNameMutated=t.storyNameMutated=t.storyAdded=t.clearCachedAccessList=t.cacheAccessData=t.access=t.clearCachedAuth=t.login=t.auth=t.StaticCompositionRenderer=t.StaticCompositionEditor=t.PreviewNotAvailable=t.DroppableAssetRenderer=t.FontAssetPreview=t.AssetsUploadMenu=t.AssetField=t.AssetsTableComplexTagCell=t.AssetsTableTagsPivot=t.AssetsTableTagsFilter=t.AssetsTableTagsCell=t.AssetsTableDurationCell=t.AssetsTableNameCell=t.AssetsTableNameFilter=t.AssetsTableStatusCell=void 0,t.PublishStatusIndicator=t.getStoryPublishStatus=t.clearStoryPublishStatus=t.publishVersion=t.publish=t.PublishWizard=t.ASSET_TYPES=t.CompositionRendererLayer=t.TextLayer=t.formatDateDefault=t.padStart=t.toFixed=t.validateAssetMimetype=t.mimetypeConformsToOverlay=t.filterHotkeys=t.formattedTime=t.fitToContainer=t.scrapeEmail=t.parameterizeServiceUrl=t.string2HexCode=t.getFirstStoryInOrg=t.validateAccessLevel=t.Timer=t.StorageService=t.LegacyAPI=t.API=void 0;var r=n(278);t.AppWrapper=r.default;var a=n(346);t.AuthGate=a.default;var o=n(92);t.ImposiumHeader=o.default;var i=n(59);t.ImposiumDropdown=i.default;var s=n(5);t.Button=s.default;var u=n(97);t.ButtonMenu=u.default;var l=n(98);t.ButtonMenuItem=l.default;var c=n(99);t.Card=c.default;var d=n(100);t.ControlledList=d.default;var p=n(354);t.DataTable=p.default;var f=n(359);t.DataTablePaginator=f.default;var h=n(360);t.Modal=h.default;var m=n(361);t.Tabs=m.default;var _=n(11);t.FieldWrapper=_.default;var y=n(30);t.CheckboxField=y.default;var g=n(362);t.ListField=g.default;var v=n(63);t.ButtonGroupField=v.default;var b=n(41);t.NumberField=b.default;var w=n(22);t.SelectField=w.default;var M=n(13);t.TextField=M.default;var L=n(64);t.TextAreaField=L.default;var T=n(102);t.ToastService=T.default;var k=n(367);t.SliderField=k.default;var x=n(65);t.ColorField=x.default;var E=n(51);t.Tag=E.default;var S=n(16);t.HRule=S.default;var O=n(474);t.Section=O.default;var D=n(21);t.Spinner=D.default;var Y=n(91);t.NoAccess=Y.default;var A=n(93);t.ServiceIcon=A.default;var C=n(128);t.DeterminateLoader=C.default;var j=n(475);t.AssetsTableDateCell=j.default;var P=n(476);t.AssetsTablePreviewCell=P.default;var H=n(477);t.AssetsTableDurationCell=H.default;var I=n(129);t.AssetField=I.default;var N=n(84);t.AssetsTableDropzone=N.default;var R=n(480);t.AssetsTableNameCell=R.default;var F=n(481);t.AssetsTableNameFilter=F.default;var z=n(482);t.AssetsTableSelectCell=z.default;var U=n(483);t.AssetsTableSelectFilter=U.default;var W=n(484);t.AssetsTableTagsCell=W.default;var B=n(485);t.AssetsTableTagsFilter=B.default;var V=n(486);t.AssetsTableTagsPivot=V.default;var G=n(487);t.AssetsTableComplexTagCell=G.default;var q=n(488);t.AssetsTableTypeCell=q.default;var J=n(489);t.AssetsTableStatusCell=J.default;var K=n(490);t.AssetsTableTypeFilter=K.default;var $=n(85);t.AssetsTypeIcon=$.default;var X=n(491);t.FontAssetPreview=X.default;var Z=n(492);t.AssetsUploadMenu=Z.default;var Q=n(493);Object.defineProperty(t,"PreviewNotAvailable",{enumerable:!0,get:function(){return Q.PreviewNotAvailable}});var ee=n(130);t.DroppableAssetRenderer=ee.default;var te=n(131);t.ImagePlayer=te.default;var ne=n(26);t.VideoPlayer=ne.default;var re=n(494);t.AudioPlayer=re.default;var ae=n(495);t.VideoPreview=ae.default;var oe=n(496);t.ImagePreview=oe.default;var ie=n(497);t.ImageSequencePlayer=ie.default;var se=n(132);t.LogViewer=se.default;var ue=n(499);t.StoryPreviewer=ue.default;var le=n(502);t.StaticCompositionEditor=le.default;var ce=n(135);t.StaticCompositionRenderer=ce.default;var de=n(506);t.ShortcutMenu=de.default;var pe=n(86);t.TextLayer=pe.default;var fe=n(25);Object.defineProperty(t,"ASSET_TYPES",{enumerable:!0,get:function(){return fe.ASSET_TYPES}});var he=n(87);t.Portal=he.default;var me=n(507);t.AssetDetails=me.default;var _e=n(54);t.PublishWizard=_e.default;var ye=n(517);t.auth=ye.default;var ge=n(39);Object.defineProperty(t,"login",{enumerable:!0,get:function(){return ge.login}}),Object.defineProperty(t,"clearCachedAuth",{enumerable:!0,get:function(){return ge.clearCachedAuth}});var ve=n(518);t.access=ve.default;var be=n(519);t.publish=be.default;var we=n(55);Object.defineProperty(t,"publishVersion",{enumerable:!0,get:function(){return we.publishVersion}}),Object.defineProperty(t,"clearStoryPublishStatus",{enumerable:!0,get:function(){return we.clearStoryPublishStatus}}),Object.defineProperty(t,"getStoryPublishStatus",{enumerable:!0,get:function(){return we.getStoryPublishStatus}});var Me=n(40);Object.defineProperty(t,"cacheAccessData",{enumerable:!0,get:function(){return Me.cacheAccessData}}),Object.defineProperty(t,"clearCachedAccessList",{enumerable:!0,get:function(){return Me.clearCachedAccessList}}),Object.defineProperty(t,"storyAdded",{enumerable:!0,get:function(){return Me.storyAdded}}),Object.defineProperty(t,"storyNameMutated",{enumerable:!0,get:function(){return Me.storyNameMutated}}),Object.defineProperty(t,"orgNameMutated",{enumerable:!0,get:function(){return Me.orgNameMutated}}),Object.defineProperty(t,"storyDeleted",{enumerable:!0,get:function(){return Me.storyDeleted}});var Le=n(24);Object.defineProperty(t,"updateFilters",{enumerable:!0,get:function(){return Le.updateFilters}});var Te=n(17);Object.defineProperty(t,"getAssets",{enumerable:!0,get:function(){return Te.getAssets}}),Object.defineProperty(t,"deleteAssets",{enumerable:!0,get:function(){return Te.deleteAssets}}),Object.defineProperty(t,"addAssetTag",{enumerable:!0,get:function(){return Te.addAssetTag}}),Object.defineProperty(t,"deleteAssetTag",{enumerable:!0,get:function(){return Te.deleteAssetTag}}),Object.defineProperty(t,"updateAssetName",{enumerable:!0,get:function(){return Te.updateAssetName}}),Object.defineProperty(t,"updateAssetData",{enumerable:!0,get:function(){return Te.updateAssetData}}),Object.defineProperty(t,"doAssetTableHydration",{enumerable:!0,get:function(){return Te.doAssetTableHydration}});var ke=n(83);Object.defineProperty(t,"getAssetTagList",{enumerable:!0,get:function(){return ke.getAssetTagList}}),Object.defineProperty(t,"addAssetTagToList",{enumerable:!0,get:function(){return ke.addAssetTagToList}});var xe=n(52);Object.defineProperty(t,"toggleAutoTag",{enumerable:!0,get:function(){return xe.toggleAutoTag}}),Object.defineProperty(t,"uploadAssets",{enumerable:!0,get:function(){return xe.uploadAssets}});var Ee=n(33);Object.defineProperty(t,"selectAsset",{enumerable:!0,get:function(){return Ee.selectAsset}}),Object.defineProperty(t,"deselectAsset",{enumerable:!0,get:function(){return Ee.deselectAsset}}),Object.defineProperty(t,"resetSelection",{enumerable:!0,get:function(){return Ee.resetSelection}});var Se=n(520);t.assetFilters=Se.default;var Oe=n(521);t.assetList=Oe.default;var De=n(522);t.assetTags=De.default;var Ye=n(523);t.assetUploads=Ye.default;var Ae=n(524);t.selectedAssets=Ae.default;var Ce=n(17);t.assetActions=Ce.default;var je=n(525);t.activeBatch=je.default;var Pe=n(88);t.batchActions=Pe.default;var He=n(29);t.AuthService=He.default;var Ie=n(27);t.SessionService=Ie.default;var Ne=n(526);t.API=Ne.default;var Re=n(528);t.LegacyAPI=Re.default;var Fe=n(529);t.StorageService=Fe.default;var ze=n(134);t.Timer=ze.default;var Ue=n(9);Object.defineProperty(t,"getFirstStoryInOrg",{enumerable:!0,get:function(){return Ue.getFirstStoryInOrg}}),Object.defineProperty(t,"string2HexCode",{enumerable:!0,get:function(){return Ue.string2HexCode}}),Object.defineProperty(t,"toFixed",{enumerable:!0,get:function(){return Ue.toFixed}}),Object.defineProperty(t,"padStart",{enumerable:!0,get:function(){return Ue.padStart}}),Object.defineProperty(t,"parameterizeServiceUrl",{enumerable:!0,get:function(){return Ue.parameterizeServiceUrl}}),Object.defineProperty(t,"scrapeEmail",{enumerable:!0,get:function(){return Ue.scrapeEmail}}),Object.defineProperty(t,"fitToContainer",{enumerable:!0,get:function(){return Ue.fitToContainer}}),Object.defineProperty(t,"filterHotkeys",{enumerable:!0,get:function(){return Ue.filterHotkeys}}),Object.defineProperty(t,"mimetypeConformsToOverlay",{enumerable:!0,get:function(){return Ue.mimetypeConformsToOverlay}}),Object.defineProperty(t,"validateAssetMimetype",{enumerable:!0,get:function(){return Ue.validateAssetMimetype}}),Object.defineProperty(t,"formatDateDefault",{enumerable:!0,get:function(){return Ue.formatDateDefault}}),Object.defineProperty(t,"validateAccessLevel",{enumerable:!0,get:function(){return Ue.validateAccessLevel}}),Object.defineProperty(t,"formattedTime",{enumerable:!0,get:function(){return Ue.formattedTime}});var We=n(136);t.CompositionRendererLayer=We.default;var Be=n(273);t.PublishStatusIndicator=Be.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(37),o=n(57),i=n(58);t.default=function(e){if(!e.type)throw new Error("NoAccess requires a type of either: request or restrict");var t="request"===e.type;return r.createElement("div",{className:"no-access"},t?r.createElement(a.FontAwesomeIcon,{icon:o.faUserLock,size:"6x"}):r.createElement(a.FontAwesomeIcon,{icon:i.faExclamationTriangle,size:"6x"}),r.createElement("div",{className:"no-access-copy"},r.createElement("h1",{className:"no-access-heading"},t?"You don't have access to Imposium yet":"Service not found"),t&&r.createElement("a",{href:"mailto:info@imposium.com?subject=My access to Imposium is restricted"},"Request Access")))}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(59),s=n(93),u=n(9),l=n(4),c=function(e){function t(n){var r=e.call(this,n)||this;return r.serviceToggleRef=null,r.storyToggleRef=null,r.orgsToggleRef=null,r.componentDidMount=function(){var e=r.props,t=e.accessData,n=e.activeOrganization;t&&r.parseAccessData(t,n)},r.componentDidUpdate=function(e){var n=r.props,a=n.accessData,o=n.activeOrganization,i=e.accessData,s=e.activeOrganization;a&&a!==i&&r.parseAccessData(a,o),"string"==typeof o&&o.length===t.UUID_LENGTH&&o!==s&&r.parseAccessData(a,o)},r.parseAccessData=function(e,n){var a=e.organizations,o=e.services,i=n?e.organizations.find((function(e){return e.id===n})):void 0,s=a.length>1?a.filter((function(e){return e.id!==n})):[],l=o&&i?o.filter((function(e){return i.services.includes(e.id)})):[],c=l.length>1?o.find((function(e){return window.location.href.includes(e.url)})):void 0,d=t.DEFAULT_ACCOUNT_TOGGLE_COLOR,p="";i&&i.hasOwnProperty("name")&&(d=u.string2HexCode(i.name),p=r.pullFirstChar(i.name)),r.setState({servicesByOrganization:l,activeServiceBlob:c,inactiveOrganizations:s,activeOrganizationBlob:i,dropdownToggleColor:d,activeFirstChar:p})},r.changeStory=function(e){var t=r.props.onStoryChange;"function"==typeof t&&(t(e),r.setState({showStoriesDropdown:!1}))},r.toggleAccountDropdown=function(e,t){void 0===t&&(t="");var n=r.props.onOrganizationChange;e?r.setState({showAccountDropdown:!0}):(r.setState({showAccountDropdown:!1}),t&&n&&n(t),t&&!n&&window.location.replace(r.getHomeUrl()+"?organization_id="+t))},r.getHomeUrl=function(){var e=window.location,t=e.hostname,n=e.host;return"localhost"===t?"http://localhost:3036":n.includes(".staging.")?"https://launchpad.staging.imposium.com":"https://launchpad.imposium.com"},r.doLogout=function(){r.setState({showAccountDropdown:!1}),r.props.logout()},r.pullFirstChar=function(e){return e?e.substring(0,1):""},r.renderDropdownChevron=function(e){return e?t.UP:t.DOWN},r.renderServiceAnchor=function(e,t,n){return o.createElement("div",{className:"anchor-wrapper",key:e.id},o.createElement("a",{href:u.parameterizeServiceUrl(t,n,e.url,e.id)},o.createElement("div",{className:"icon-fixed"},o.createElement(s.default,{iconName:e.icon,color:"#"+e.color})),e.name))},r.state={inactiveOrganizations:[],servicesByOrganization:[],activeServiceBlob:void 0,activeOrganizationBlob:void 0,showAccountDropdown:!1,showStoriesDropdown:!1,showServiceDropdown:!1,dropdownToggleColor:t.DEFAULT_ACCOUNT_TOGGLE_COLOR,activeFirstChar:""},r.serviceToggleRef=o.createRef(),r.storyToggleRef=o.createRef(),r.orgsToggleRef=o.createRef(),r}return a(t,e),t.prototype.render=function(){var e,n,r,a,c,d,p,f,h,m,_,y,g=this,v=this.props,b=v.email,w=v.accessData,M=v.activeOrganization,L=v.activeStory,T=v.hideStoryPicker,k=this.state,x=k.showAccountDropdown,E=k.servicesByOrganization,S=k.activeServiceBlob,O=k.showStoriesDropdown,D=k.inactiveOrganizations,Y=k.activeOrganizationBlob,A=k.activeFirstChar,C=k.dropdownToggleColor,j=k.showServiceDropdown,P={};return w&&((r=E.find((function(e){return window.location.href.includes(e.url)})))&&(P={color:"#"+r.color},n={borderBottom:"4px solid #"+r.color}),a=E.filter((function(e){return!e.private&&-1===t.PRIVATE_IDS.indexOf(e.id)})).map((function(e){return g.renderServiceAnchor(e,M,L)})),c=E.filter((function(e){return!e.private&&t.PRIVATE_IDS.indexOf(e.id)>-1})).map((function(e){return g.renderServiceAnchor(e,M,L)})),y=o.createElement("div",{className:"service-menu"},o.createElement("section",{className:"service-menu-section"},o.createElement("div",{className:"service-menu-heading"},t.SERVICE_MESH_ALIAS),o.createElement("div",{className:"service-menu-anchors"},a)),c.length>0&&o.createElement("section",{className:"service-menu-section"},o.createElement("div",{className:"service-menu-heading"},t.PRIVATE_HEADER),o.createElement("div",{className:"service-menu-anchors"},c)),o.createElement("section",{className:"service-menu-section"},o.createElement("div",{className:"service-menu-heading"},t.DOCS_HEADER),o.createElement("div",{className:"service-menu-anchors"},o.createElement("div",{className:"anchor-wrapper doc"},o.createElement("a",{target:"__blank",href:t.API_DOCS_LINK},o.createElement("div",{className:"icon-fixed"},o.createElement(s.default,{iconName:"FaCogs"})),t.API_DOCS_LINK_COPY)),o.createElement("div",{className:"anchor-wrapper doc"},o.createElement("a",{target:"__blank",href:t.SDK_DOCS_LINK},o.createElement("div",{className:"icon-fixed"},o.createElement(s.default,{iconName:"FaJsSquare"})),t.SDK_DOCS_LINK_COPY))))),_=o.createElement("button",{id:"btn-toggle-services",className:"btn-toggle-services",style:P,ref:this.serviceToggleRef,onClick:function(){return g.setState({showServiceDropdown:!g.state.showServiceDropdown})}},o.createElement("span",null,S?S.name:t.SERVICE_MESH_ALIAS),this.renderDropdownChevron(j)),d=o.createElement("button",{id:"btn-toggle-orgs",className:"btn-toggle-orgs",ref:this.orgsToggleRef,style:{backgroundColor:C},onClick:function(){return g.toggleAccountDropdown(!x)}},A)),w&&Y&&(p=o.createElement("div",{className:"orgs-menu-active-org"},o.createElement("div",{className:"active-first-char",style:{backgroundColor:C}},this.pullFirstChar(Y.name)),o.createElement("div",null,Y.name))),w&&Y&&!T&&(e=Y.stories.find((function(e){return e.id===L})),f=o.createElement("button",{id:"btn-toggle-story",className:"btn-toggle-story",ref:this.storyToggleRef,onClick:function(){g.setState({showStoriesDropdown:!g.state.showStoriesDropdown})}},o.createElement("div",{className:"story-name"},e?e.name:t.DEFAULT_SERVICE_TOGGLE_COPY),this.renderDropdownChevron(O)),m=0===Y.stories.length?o.createElement("div",{className:"no-stories-dialog"},t.NO_STORIES_COPY):Y.stories.map((function(e){return o.createElement("button",{key:e.id,className:"btn-change-story",onClick:function(){return g.changeStory(e)}},e.name)}))),x&&(h=o.createElement("div",{className:"orgs-menu-org-picker"},D.map((function(e){return o.createElement("button",{key:e.name,className:"menu-item inactive-org-button",onClick:function(){return g.toggleAccountDropdown(!1,e.id)}},o.createElement("div",{className:"inactive-first-char",style:{backgroundColor:u.string2HexCode(e.name)}},g.pullFirstChar(e.name)),e.name)})))),o.createElement("nav",{id:"imposium-header",className:"imposium-header",style:n},o.createElement("div",{className:"inner-content"},o.createElement("span",{className:"inner-left"},o.createElement("a",{className:"title",href:u.parameterizeServiceUrl(M,L,this.getHomeUrl())},o.createElement("div",{className:"logo"}),o.createElement("h1",{className:"heading"},t.DEFAULT_TITLE)),_),o.createElement("span",{className:"inner-right"},f,d,o.createElement("a",{href:"https://support.imposium.com",target:"_blank"},o.createElement("div",{className:"btn-help"},l.ICON_HELP)))),o.createElement(i.default,{key:"services-dropdown",position:"bottomleft",show:j,toggleRef:this.serviceToggleRef,onOutsideClick:function(){return g.setState({showServiceDropdown:!1})}},y),o.createElement(i.default,{key:"stories-dropdown",position:"bottomright",show:O,toggleRef:this.storyToggleRef,onOutsideClick:function(){return g.setState({showStoriesDropdown:!1})}},o.createElement("div",{className:"stories-menu"},m)),o.createElement(i.default,{key:"org-dropdown",position:"bottomright",show:x,toggleRef:this.orgsToggleRef,onOutsideClick:function(){return g.toggleAccountDropdown(!1)}},o.createElement("div",{className:"orgs-menu"},p,h,o.createElement("div",{className:"orgs-menu-footer"},o.createElement("div",{className:"email"},b),o.createElement("button",{className:"btn-logout",onClick:function(){return g.doLogout()}},t.LOGOUT_COPY)))))},t.DEFAULT_TITLE="imposium",t.SERVICE_MESH_ALIAS="services",t.DOCS_HEADER="documentation",t.PRIVATE_HEADER="admin",t.API_DOCS_LINK_COPY="REST API",t.SDK_DOCS_LINK_COPY="Javascript SDK",t.API_DOCS_LINK="https://docs.imposium.com",t.SDK_DOCS_LINK="https://docs.imposium.com/js-sdk/",t.DEFAULT_SERVICE_TOGGLE_COPY="stories",t.DEFAULT_ACCOUNT_TOGGLE_COLOR="royalblue",t.NO_STORIES_COPY="No stories were found",t.LOGOUT_COPY="logout",t.UUID_LENGTH=36,t.UP=l.ICON_CHEVRON_UP,t.DOWN=l.ICON_CHEVRON_DOWN,t.PRIVATE_IDS=[9,10,11,12],t}(o.PureComponent);t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(37),o=n(279),i=n(280),s=n(281),u=n(282),l=n(94),c=n(95),d=n(283),p=n(284),f=n(285),h=n(286),m=n(57),_=n(287),y=n(288),g=n(289);t.default=function(e){switch(e.iconName){case"FaFilm":return r.createElement(a.FontAwesomeIcon,{icon:i.faFilm,color:e.color});case"FaRegFileVideo":return r.createElement(a.FontAwesomeIcon,{icon:l.faFileVideo,color:e.color});case"FaChartBar":return r.createElement(a.FontAwesomeIcon,{icon:d.faChartBar,color:e.color});case"FaGavel":return r.createElement(a.FontAwesomeIcon,{icon:s.faGavel,color:e.color});case"FaDatabase":return r.createElement(a.FontAwesomeIcon,{icon:u.faDatabase,color:e.color});case"FaVideo":return r.createElement(a.FontAwesomeIcon,{icon:c.faVideo,color:e.color});case"FaUsersCog":return r.createElement(a.FontAwesomeIcon,{icon:p.faUsersCog,color:e.color});case"FaPlayCircle":return r.createElement(a.FontAwesomeIcon,{icon:h.faPlayCircle,color:e.color});case"FaUserLock":return r.createElement(a.FontAwesomeIcon,{icon:m.faUserLock,color:e.color});case"FaSiteMap":return r.createElement(a.FontAwesomeIcon,{icon:_.faSitemap,color:e.color});case"FaFileAlt":return r.createElement(a.FontAwesomeIcon,{icon:g.faFileAlt,color:e.color});case"FaChartArea":return r.createElement(a.FontAwesomeIcon,{icon:y.faChartArea,color:e.color});case"FaCogs":return r.createElement(a.FontAwesomeIcon,{icon:f.faCogs});case"FaJsSquare":return r.createElement(a.FontAwesomeIcon,{icon:o.faJsSquare});default:return null}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=[],a="M384 121.941V128H256V0h6.059c6.365 0 12.47 2.529 16.971 7.029l97.941 97.941A24.005 24.005 0 0 1 384 121.941zM224 136V0H24C10.745 0 0 10.745 0 24v464c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24V160H248c-13.2 0-24-10.8-24-24zm96 144.016v111.963c0 21.445-25.943 31.998-40.971 16.971L224 353.941V392c0 13.255-10.745 24-24 24H88c-13.255 0-24-10.745-24-24V280c0-13.255 10.745-24 24-24h112c13.255 0 24 10.745 24 24v38.059l55.029-55.013c15.011-15.01 40.971-4.491 40.971 16.97z";t.definition={prefix:"fas",iconName:"file-video",icon:[384,512,r,"f1c8",a]},t.faFileVideo=t.definition,t.prefix="fas",t.iconName="file-video",t.width=384,t.height=512,t.ligatures=r,t.unicode="f1c8",t.svgPathData=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=[],a="M336.2 64H47.8C21.4 64 0 85.4 0 111.8v288.4C0 426.6 21.4 448 47.8 448h288.4c26.4 0 47.8-21.4 47.8-47.8V111.8c0-26.4-21.4-47.8-47.8-47.8zm189.4 37.7L416 177.3v157.4l109.6 75.5c21.2 14.6 50.4-.3 50.4-25.8V127.5c0-25.4-29.1-40.4-50.4-25.8z";t.definition={prefix:"fas",iconName:"video",icon:[576,512,r,"f03d",a]},t.faVideo=t.definition,t.prefix="fas",t.iconName="video",t.width=576,t.height=512,t.ligatures=r,t.unicode="f03d",t.svgPathData=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=[],a="M256 8C119.043 8 8 119.083 8 256c0 136.997 111.043 248 248 248s248-111.003 248-248C504 119.083 392.957 8 256 8zm0 110c23.196 0 42 18.804 42 42s-18.804 42-42 42-42-18.804-42-42 18.804-42 42-42zm56 254c0 6.627-5.373 12-12 12h-88c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h12v-64h-12c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h64c6.627 0 12 5.373 12 12v100h12c6.627 0 12 5.373 12 12v24z";t.definition={prefix:"fas",iconName:"info-circle",icon:[512,512,r,"f05a",a]},t.faInfoCircle=t.definition,t.prefix="fas",t.iconName="info-circle",t.width=512,t.height=512,t.ligatures=r,t.unicode="f05a",t.svgPathData=a},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__values||function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=function(e){function t(t){var n=e.call(this,t)||this;return n.state={open:!1},n.evtHandlers={toggleMenu:function(e){return n.toggleMenu(e)},clickOutside:function(e,t){return n.handleClickOutside(e,t)}},n.toggleRef=i.createRef(),n.menuRef=i.createRef(),n}return a(t,e),t.prototype.handleClickOutside=function(e,t){var n=!!(this.toggleRef&&this.toggleRef.current&&this.toggleRef.current.contains(e.target)),r=!!(this.menuRef&&this.menuRef.current&&this.menuRef.current.contains(e.target));n||t||(document.removeEventListener("click",this.evtHandlers.clickOutside),this.setState({open:!1})),t&&!r&&(document.removeEventListener("click",this.evtHandlers.clickOutside),this.setState({open:!1}))},t.prototype.componentWillUnmount=function(){document.removeEventListener("click",this.evtHandlers.clickOutside)},t.prototype.toggleMenu=function(e){var t=this,n=this.props.onClick,r=!this.state.open;n&&n(r),this.setState({open:r},(function(){t.state.open?document.addEventListener("click",(function(e){return t.evtHandlers.clickOutside(e,!!n||void 0)})):document.removeEventListener("click",t.evtHandlers.clickOutside)}))},t.prototype.renderItems=function(){var e,t,n=this,r=this.props,a=r.items,s=r.isOpen,u=[],l=function(e){var t=i.cloneElement(e,{onClick:function(t){n.props.isOpen||document.removeEventListener("click",n.evtHandlers.clickOutside),n.setState({open:s||!1},(function(){e.props.onClick(t)}))}});u.push(t)};try{for(var c=o(a),d=c.next();!d.done;d=c.next()){l(d.value)}}catch(t){e={error:t}}finally{try{d&&!d.done&&(t=c.return)&&t.call(c)}finally{if(e)throw e.error}}return u},t.prototype.renderMenu=function(){var e=this.props.position;if(this.state.open)return i.createElement("div",{className:"menu "+e},this.renderItems())},t.prototype.render=function(){var e=this.props.button,t=this.state.open,n=i.cloneElement(e,{buttonRef:this.toggleRef,onClick:this.evtHandlers.toggleMenu,active:t});return i.createElement("div",{ref:this.menuRef,className:"button-menu"},n,this.renderMenu())},t}(i.PureComponent);t.default=s},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=function(e){function t(t){return e.call(this,t)||this}return a(t,e),t.prototype.render=function(){var e=this,t=this.props,n=t.label,r=t.active;return o.createElement("div",{className:"button-menu-item "+(r?"active":null)+" ",onClick:function(t){return e.props.onClick(t)}},n)},t}(o.Component);t.default=i},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(5),s=n(4),u=function(e){function t(t){var n=e.call(this,t)||this;return n.state={open:t.open},n.evtHandlers={toggleOpen:function(e){return n.toggleOpen(e)}},n}return a(t,e),t.prototype.toggleOpen=function(e){var t=this;e.persist(),e.preventDefault();var n=this.props,r=n.collapsable,a=n.onOpen,o=n.onClose;r&&("function"==typeof this.props.onToggle&&this.props.onToggle(!this.state.open),this.setState({open:!this.state.open},(function(){t.state.open&&a?a(e):!t.state.open&&o&&o(e)})))},t.prototype.componentDidUpdate=function(e){var t=this.props,n=t.open;t.collapsable;e.open!==n&&this.setState({open:n})},t.prototype.renderTitle=function(e){var t=this.props.title;return"small"===e?o.createElement("p",null,t):"large"===e?o.createElement("h1",null,t):o.createElement("h2",null,t)},t.prototype.renderContent=function(){if(this.state.open)return o.createElement("div",{className:"card-content"},this.props.children)},t.prototype.render=function(){var e=this.props,t=e.collapsable,n=(e.title,e.style),r=t?"collapsable":"",a=!this.state.open&&t?"closed":"",i=n||"default";return o.createElement("div",{className:"card "+a+" "+r+" "+i},o.createElement("div",{className:"card-header",onClick:this.evtHandlers.toggleOpen},this.renderTitle(i),this.renderButtons()),this.renderContent())},t.prototype.renderButtons=function(){var e=this.props.collapsable,t=this.state.open?s.ICON_CARET_UP:s.ICON_CARET_DOWN;if(e)return o.createElement("div",{className:"header-buttons"},o.createElement(i.default,{style:"subtle",onClick:this.evtHandlers.toggleOpen},t))},t}(o.PureComponent);t.default=u},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(5),s=n(4),u=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return a(t,e),t.prototype.renderRemoveButton=function(e){var t=this;if(this.props.removable)return o.createElement("div",{className:"buttons"},o.createElement(i.default,{style:"subtle",color:"danger",onClick:function(){return t.props.onRemove(e)}},s.ICON_TIMES))},t.prototype.render=function(){var e,t=this,n=this.props.items;return n&&(e=n.map((function(e,n){return o.createElement("div",{className:"item",key:"item-"+n},e,t.renderRemoveButton(n))}))),o.createElement("div",{className:"controlled-list"},e)},t}(o.PureComponent);t.default=u},function(e,t){e.exports=u},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(0),o=n(364),i=n(37),s=n(96),u=n(58),l=function(){function e(){}return e.DEFAULT_TOAST_CONFIG={hideAfter:3,position:"bottom-right"},e.INFO_STYLE={bar:{size:"2px",style:"solid",color:"#56B05E"},renderIcon:function(){return a.createElement(i.FontAwesomeIcon,{icon:s.faInfoCircle,color:"#56B05E"})}},e.ERROR_STYLE={bar:{size:"2px",style:"solid",color:"#AF1126"},renderIcon:function(){return a.createElement(i.FontAwesomeIcon,{icon:u.faExclamationTriangle,color:"#AF1126"})}},e.emit=function(t,n){switch(t){case"info":return void o.default.info(n,r(r({},e.DEFAULT_TOAST_CONFIG),e.INFO_STYLE));case"error":return void o.default.error(n,r(r({},e.DEFAULT_TOAST_CONFIG),e.ERROR_STYLE));default:return}},e}();t.default=l},function(e,t,n){(function(t){var n="object"==typeof t&&t&&t.Object===Object&&t;e.exports=n}).call(this,n(38))},function(e,t,n){var r=n(372),a=n(32);e.exports=function(e,t){return e&&r(e,t,a)}},function(e,t,n){var r=n(374),a=n(106),o=n(12),i=n(67),s=n(107),u=n(108),l=Object.prototype.hasOwnProperty;e.exports=function(e,t){var n=o(e),c=!n&&a(e),d=!n&&!c&&i(e),p=!n&&!c&&!d&&u(e),f=n||c||d||p,h=f?r(e.length,String):[],m=h.length;for(var _ in e)!t&&!l.call(e,_)||f&&("length"==_||d&&("offset"==_||"parent"==_)||p&&("buffer"==_||"byteLength"==_||"byteOffset"==_)||s(_,m))||h.push(_);return h}},function(e,t,n){var r=n(375),a=n(15),o=Object.prototype,i=o.hasOwnProperty,s=o.propertyIsEnumerable,u=r(function(){return arguments}())?r:function(e){return a(e)&&i.call(e,"callee")&&!s.call(e,"callee")};e.exports=u},function(e,t){var n=/^(?:0|[1-9]\d*)$/;e.exports=function(e,t){var r=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==r||"symbol"!=r&&n.test(e))&&e>-1&&e%1==0&&e<t}},function(e,t,n){var r=n(377),a=n(69),o=n(70),i=o&&o.isTypedArray,s=i?a(i):r;e.exports=s},function(e,t){e.exports=function(e,t){return function(n){return e(t(n))}}},function(e,t,n){var r=n(18),a=n(23);e.exports=function(e){if(!a(e))return!1;var t=r(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},function(e,t){e.exports=function(e){return e}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,a=Array(r);++n<r;)a[n]=t(e[n],n,e);return a}},function(e,t){var n=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return n.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},function(e,t,n){var r=n(412),a=n(15);e.exports=function e(t,n,o,i,s){return t===n||(null==t||null==n||!a(t)&&!a(n)?t!=t&&n!=n:r(t,n,o,i,e,s))}},function(e,t,n){var r=n(413),a=n(416),o=n(417);e.exports=function(e,t,n,i,s,u){var l=1&n,c=e.length,d=t.length;if(c!=d&&!(l&&d>c))return!1;var p=u.get(e),f=u.get(t);if(p&&f)return p==t&&f==e;var h=-1,m=!0,_=2&n?new r:void 0;for(u.set(e,t),u.set(t,e);++h<c;){var y=e[h],g=t[h];if(i)var v=l?i(g,y,h,t,e,u):i(y,g,h,e,t,u);if(void 0!==v){if(v)continue;m=!1;break}if(_){if(!a(t,(function(e,t){if(!o(_,t)&&(y===e||s(y,e,n,i,u)))return _.push(t)}))){m=!1;break}}else if(y!==g&&!s(y,g,n,i,u)){m=!1;break}}return u.delete(e),u.delete(t),m}},function(e,t,n){var r=n(14).Uint8Array;e.exports=r},function(e,t,n){var r=n(118),a=n(77),o=n(32);e.exports=function(e){return r(e,o,a)}},function(e,t,n){var r=n(119),a=n(12);e.exports=function(e,t,n){var o=t(e);return a(e)?o:r(o,n(e))}},function(e,t){e.exports=function(e,t){for(var n=-1,r=t.length,a=e.length;++n<r;)e[a+n]=t[n];return e}},function(e,t){e.exports=function(){return[]}},function(e,t,n){var r=n(23);e.exports=function(e){return e==e&&!r(e)}},function(e,t){e.exports=function(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in Object(n)))}}},function(e,t,n){var r=n(124),a=n(49);e.exports=function(e,t){for(var n=0,o=(t=r(t,e)).length;null!=e&&n<o;)e=e[a(t[n++])];return n&&n==o?e:void 0}},function(e,t,n){var r=n(12),a=n(78),o=n(430),i=n(433);e.exports=function(e,t){return r(e)?e:a(e,t)?[e]:o(i(e))}},function(e,t,n){var r=n(126),a=n(74),o=Object.prototype.hasOwnProperty;e.exports=function(e,t,n){var i=e[t];o.call(e,t)&&a(i,n)&&(void 0!==n||t in e)||r(e,t,n)}},function(e,t,n){var r=n(448);e.exports=function(e,t,n){"__proto__"==t&&r?r(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}},function(e,t,n){var r=n(119),a=n(72),o=n(77),i=n(120),s=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)r(t,o(e)),e=a(e);return t}:i;e.exports=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0);t.default=function(e){var t=e.progress?"scaleX("+e.progress/100+")":"scaleX(0)";return r.createElement("div",{className:"determinate-loader"},r.createElement("div",{className:"progress-bg",style:{transform:t}}),r.createElement("div",{className:"progress-copy"},Math.round(e.progress)+"%"))}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(7),s=n(5),u=n(13),l=n(84),c=n(130),d=n(9),p=n(24),f=n(52),h=n(8),m=n(10),_=n(4),y=function(e){function t(t){var n=e.call(this,t)||this;return n.onFileDrop=function(e,t){var r=n.props,a=r.accepts,o=r.storyId,i=r.api;if(t){var s=t.getItem().files;d.mimetypeConformsToOverlay(a,s[0])&&(n.setState({assetUploading:!0}),n.props.uploadAssets(i,[s[0]],o,(function(e){n.setState({assetName:e.name,error:!1},(function(){n.setState({assetUploading:!1}),n.props.onChange(e)}))})))}},n.state={assetName:"",error:!1,assetUploading:!1},n}return a(t,e),t.prototype.componentDidMount=function(){var e=this.props,t=e.assetId;e.api;t&&!this.state.assetName&&this.loadAsset()},t.prototype.componentDidUpdate=function(e,t){var n=this.props.assetId;n&&n!==e.assetId?this.loadAsset():n||this.setState({error:!1,assetName:""})},t.prototype.loadAsset=function(){var e=this,t=this.props,n=t.assetId;t.api.getAssetItem(n).then((function(t){e.setState({error:!1,assetName:t.name})})).catch((function(t){e.setState({error:!0,assetName:"Could not find asset: "+n})}))},t.prototype.setFilter=function(e){var t=this.props.accepts;this.props.updateFilters({type:t||"",page:1})},t.prototype.onAssetDrop=function(e,t){var n=this,r=e.rowData,a=e.rowData,o=a.name,s=(a.id,a.type),u=this.props.accepts;s===u?this.setState({assetName:o,error:!1},(function(){n.props.onChange(r)})):this.props.onError&&this.props.onError(i.assets.field.fieldMismatchError.replace("[accepts]",u))},t.prototype.clearAsset=function(e){var t=this;this.setState({assetName:"",error:!1},(function(){t.props.onChange(null)}))},t.prototype.render=function(){var e=this,t=this.props,n=t.assetId,r=t.label,a=t.width,d=t.tooltip,p=t.labelPosition,f=this.state,h=f.assetName,m=f.assetUploading,y=f.error?"error":"",g=n?"":i.assets.field.dragPrompt,v={width:a||"100%"},b=[];return b.push(o.createElement(s.default,{key:"btn-filter",onClick:function(t){return e.setFilter(t)},style:"subtle",tooltip:i.assets.field.tooltipFilter,color:"primary"},_.ICON_FILTER)),n&&!m&&b.unshift(o.createElement(s.default,{key:"btn-clear-asset",tooltip:i.assets.field.tooltipClear,onClick:function(t){return e.clearAsset(t)},style:"subtle"},_.ICON_TIMES)),o.createElement("div",{style:v,className:"asset-field "+y},o.createElement(l.default,{onDrop:function(t,n){return e.onFileDrop(t,n)},disable:m},o.createElement(c.default,{onDrop:function(t,n){return e.onAssetDrop(t,n)}},o.createElement(u.default,{readOnly:!0,label:r,tooltip:d,loading:m,placeholder:g,buttons:b,labelPosition:p,value:h}))))},t}(o.PureComponent);t.default=h.connect(null,(function(e){return m.bindActionCreators({updateFilters:p.updateFilters,uploadAssets:f.uploadAssets},e)}))(y)},function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i};Object.defineProperty(t,"__esModule",{value:!0});var a=n(0),o=n(61),i=n(479);t.default=function(e){var t=r(o.useDrop({accept:i.ASSET_DND_TYPES.ASSET_NAME,drop:e.onDrop,collect:function(e){return{isOver:e.isOver(),canDrop:e.canDrop()}}}),2),n=t[0],s=n.canDrop,u=n.isOver,l=t[1],c=s&&u?"1px solid royalblue":"";return a.createElement("div",{ref:l,className:"asset-target",style:{border:c}},e.children)}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(34),s=n(26),u=function(e){function t(t){var n=e.call(this,t)||this;return n.state={imageHeight:1080,imageWidth:1920},n.imgNode=o.createRef(),n}return a(t,e),t.prototype.getImageStyle=function(){var e=this.state,t=e.imageHeight,n=e.imageWidth,r=this.props,a=r.padding,o=r.width,u=r.height,l=void 0!==a?a:i.DEFAULT_PADDING;return t&&n?s.getPlayerStyle(o,u,n,t,l,n,t):{}},t.prototype.metadataLoaded=function(e){this.setState({imageWidth:e.target.naturalWidth,imageHeight:e.target.naturalHeight})},t.prototype.render=function(){var e=this,t=this.props,n=t.url;return!1!==t.active?o.createElement("div",{className:"media-player"},o.createElement("div",{className:"inner-viewer",style:this.getImageStyle()},o.createElement("img",{onLoad:function(t){return e.metadataLoaded(t)},src:n,ref:this.imgNode}))):null},t}(o.PureComponent);t.default=u},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(498),s=n(7),u=function(e){function t(t){var n=e.call(this,t)||this;return n.state={loading:!0,log:""},n.ansi_up=new i.default,n.ansi_up.use_classes=!0,n}return a(t,e),t.prototype.getJobLogs=function(){var e=this,t=this.props,n=t.api,r=t.onError,a=t.jobId;n.getJobLogUrl(this.props.jobId).then((function(t){var o=t.signed_url;n.getJobLog(o).then((function(t){e.setState({loading:!1,log:t})})).catch((function(t){r&&r(s.previewer.logDownloadError.replace("[jobId]",a)),e.setState({loading:!1,log:""})}))})).catch((function(t){r&&r(s.previewer.logURLError.replace("[jobId]",e.props.jobId)),e.setState({loading:!1,log:""})}))},t.prototype.componentDidMount=function(){this.props.jobId&&this.getJobLogs()},t.prototype.componentDidUpdate=function(e){e.jobId!==this.props.jobId&&this.props.jobId&&this.getJobLogs()},t.prototype.render=function(){var e=this.ansi_up.ansi_to_html(this.state.log);return o.createElement("div",{className:"log-viewer"},o.createElement("div",{className:"log-html",dangerouslySetInnerHTML:{__html:e}}))},t}(o.PureComponent);t.default=u},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BOOLEAN_DEFAULT_OPTIONS=t.VARIABLE_TYPES=void 0,t.VARIABLE_TYPES={TEXT:"text",NUMBER:"number",BOOLEAN:"boolean",ENUM:"enum",IMAGE:"image",VIDEO:"video",AUDIO:"audio"},t.BOOLEAN_DEFAULT_OPTIONS=[{value:!0,label:"True"},{value:!1,label:"False"}]},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e){this.config=e}return e.prototype.stop=function(){this.running=!1,clearInterval(this.timeInterval)},e.prototype.start=function(){var e=this;this.running=!0,clearInterval(this.timeInterval),this.startTime=Date.now(),this.timeInterval=setInterval((function(){return e.updateTimeElapsed()}),this.config.interval)},e.prototype.updateTimeElapsed=function(){var e=Date.now()-this.startTime;this.config.onUpdate(e)},e}();t.default=r},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},i=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},s=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),l=n(136),c=function(e){function t(t){var n=e.call(this,t)||this;return n.bgRef=u.createRef(),n}return a(t,e),t.prototype.renderLayers=function(){var e=this,t=this.props,n=t.composition.layers,r=t.inventory,a=t.selectedLayer,o=function(t){e.props.onSelectLayer(t)},s=[],c=[];return n?(n.map((function(t,n){var i,d=t.id&&t.id===a;c.push(new Promise((function(e,t){i=e,t}))),s.push(u.createElement(l.default,{onUpdate:function(t){return e.updateLayer(n,t)},onReady:i,onClick:o,selected:d,layer:t,inventory:r,key:t.id||n}))})),Promise.all(c).then((function(t){i(t,1)[0];e.props.onReady&&e.props.onReady()})),s):null},t.prototype.updateLayer=function(e,t){var n=o({},this.props.composition),r=s([],i(n.layers));r[e]=t,n.layers=r,this.props.onUpdate(n)},t.prototype.resetSelected=function(e){e.preventDefault(),e.stopPropagation();var t=this.bgRef.current;!t||e.target},t.prototype.render=function(){var e=this,t=this.props.composition,n=t.width,r=t.height,a=t.background_color,o={width:n+"px",height:r+"px"};return a&&(o.backgroundColor=a),u.createElement("div",{ref:this.bgRef,className:"static-composition-renderer",style:o,onClick:function(t){return e.resetSelected(t)}},this.renderLayers())},t}(u.PureComponent);t.default=c},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(505),u=n(62),l=n(86),c=function(e){function t(t){var n=e.call(this,t)||this;return n.layerRefMount=function(e){return n.onRefMount(e)},n.evtHandlers={onDrag:function(e){return n.handleDrag(e)},onResize:function(e){return n.handleResize(e)},onRotate:function(e){return n.handleRotate(e)},onClick:function(e){return n.layerClicked(e)},onShift:function(e){return n.onShift(e)},onLeft:function(e){return n.move(e,-1,0)},onRight:function(e){return n.move(e,1,0)},onUp:function(e){return n.move(e,0,-1)},onDown:function(e){return n.move(e,0,1)}},n.moveable=i.createRef(),n.state={lockRatio:!1},n}return a(t,e),t.prototype.move=function(e,t,n){if(this.props.selected){var r=e.shiftKey?10*t:t,a=e.shiftKey?10*n:n,i=o({},this.props.layer);i.x=i.x+r,i.y=i.y+a,this.props.onUpdate(i)}},t.prototype.onShift=function(e){if("Shift"===e.key&&16===e.keyCode&&this.props.selected){var t="keydown"===e.type;this.setState({lockRatio:t})}},t.prototype.componentDidUpdate=function(){var e=this.moveable.current;e&&e.updateRect()},t.prototype.componentDidMount=function(){u.default("*",{keyup:!0},this.evtHandlers.onShift),u.default("left, shift+left",this.evtHandlers.onLeft),u.default("right, shift+right",this.evtHandlers.onRight),u.default("up, shift+up",this.evtHandlers.onUp),u.default("down, shift+down",this.evtHandlers.onDown)},t.prototype.componentWillUnmount=function(){u.default.unbind("*",this.evtHandlers.onShift),u.default.unbind("left, shift+left",this.evtHandlers.onLeft),u.default.unbind("right, shift+right",this.evtHandlers.onRight),u.default.unbind("up, shift+up",this.evtHandlers.onUp),u.default.unbind("down, shift+down",this.evtHandlers.onDown)},t.prototype.handleDrag=function(e){var t=o({},this.props.layer);t.x=Math.round(e.left),t.y=Math.round(e.top),this.props.onUpdate(t)},t.prototype.handleResize=function(e){var t=e.drag.beforeDelta,n=e.width,r=e.height,a=o({},this.props.layer);a.width=Math.round(n),a.height=Math.round(r),a.x=Math.round(a.x+t[0]),a.y=Math.round(a.y+t[1]),this.props.onUpdate(a)},t.prototype.handleRotate=function(e){var t=o({},this.props.layer);t.rotation=Math.round(e.beforeDelta+t.rotation),this.props.onUpdate(t)},t.prototype.layerClicked=function(e){e.preventDefault(),e.stopPropagation(),this.props.onClick(this.props.layer.id)},t.prototype.onRefMount=function(e){this.layerRef=e,this.forceUpdate()},t.prototype.renderLayerContent=function(){var e=this.props,t=e.layer,n=e.inventory;return i.createElement(l.default,{onReady:this.props.onReady,inventory:n,options:t})},t.prototype.render=function(){var e=this.props,t=e.selected,n=e.layer,r=this.state.lockRatio,a="comp-layer-"+n.id,o={top:n.y+"px",left:n.x+"px",width:n.width+"px",height:n.height+"px",transform:"rotate("+n.rotation+"deg)"},u=t?i.createElement(s.default,{ref:this.moveable,target:document.querySelector("."+a),onDrag:this.evtHandlers.onDrag,onDragEnd:this.evtHandlers.onDragEnd,onResize:this.evtHandlers.onResize,onResizeEnd:this.evtHandlers.onResizeEnd,onRotate:this.evtHandlers.onRotate,onRotateEnd:this.evtHandlers.onRotateEnd,keepRatio:r,resizable:!0,rotatable:!0,origin:!1,draggable:!0}):null;return i.createElement(i.Fragment,null,u,i.createElement("div",{ref:this.layerRefMount,className:"composition-renderer-layer "+a,onClick:this.evtHandlers.onClick,style:o},this.renderLayerContent()))},t}(i.PureComponent);t.default=c},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.documentationLinks=void 0;var o=n(0),i=n(7),s=n(54),u=n(4),l=n(510),c=n(512),d=n(16);t.documentationLinks=[{key:"js-sdk-link",label:o.createElement("span",null,u.ICON_JS," ",i.integration.js),link:i.integration.jsSdkLink},{key:"rest-link",label:o.createElement("span",null,u.ICON_PROJECT_DIAGRAM," ",i.integration.rest),link:i.integration.restLink}];var p=function(e){function n(t){var n=e.call(this,t)||this;return n.downloadSampleWebPage=function(){var e,t,r=n.props,a=r.story,o=r.compositionId,s=r.accessKey,u=n.getFirstAct(a);a.id&&a.name&&void 0!==u&&u.hasOwnProperty("inventory")&&(e=a.name+i.integration.sdkArchiveSuffix,t={storyId:a.id,compositionId:o,storyName:a.name,accessToken:s,inventory:u.inventory},l.downloadSDKArchive(e,t))},n.getFirstAct=function(e){for(var t in e.acts)if(e.acts.hasOwnProperty(t))return e.acts[t]},n}return a(n,e),n.prototype.linkToDemoPage=function(){var e=this.props,t=e.accessKey,n=e.compositionId,r=e.story.id;if(t){var a=c.getDemoURL()+"/"+t+"/"+r+"/"+n;window.open(a,"_blank")}},n.prototype.render=function(){var e=this,n=[{label:o.createElement("span",null,u.ICON_GLOBE," ",i.publish.webPageHosted),onClick:function(){return e.linkToDemoPage()}},{label:o.createElement("span",null,u.ICON_DOWNLOAD," ",i.publish.sampleWebpage),onClick:function(){return e.downloadSampleWebPage()}}];return o.createElement("div",null,o.createElement("h2",null,i.publish.webpageTitle),o.createElement(d.default,null),o.createElement("p",null,i.publish.webpageDesc),o.createElement(d.default,null),o.createElement("div",{className:"link-wrapper"},null==n?void 0:n.map((function(e,t){return o.createElement(s.BigButton,{key:t,label:e.label,onClick:function(){return e.onClick()}})}))),o.createElement("br",null),o.createElement("br",null),o.createElement("h2",null,i.integration.documentation),o.createElement(d.default,null),o.createElement("p",null,i.integration.docParagraph),o.createElement("div",{className:"link-wrapper"},null===t.documentationLinks||void 0===t.documentationLinks?void 0:t.documentationLinks.map((function(e){return o.createElement(s.BigLink,{key:e.key,label:e.label,link:e.link})}))))},n}(o.PureComponent);t.default=p},function(e,t,n){!function(e){"use strict";
3
+ a.version="2.29.1",t=xt,a.fn=yn,a.min=function(){var e=[].slice.call(arguments,0);return Ot("isBefore",e)},a.max=function(){var e=[].slice.call(arguments,0);return Ot("isAfter",e)},a.now=function(){return Date.now?Date.now():+new Date},a.utc=h,a.unix=function(e){return xt(1e3*e)},a.months=function(e,t){return wn(e,t,"months")},a.isDate=d,a.locale=it,a.invalid=y,a.duration=Ut,a.isMoment=M,a.weekdays=function(e,t,n){return Mn(e,t,n,"weekdays")},a.parseZone=function(){return xt.apply(null,arguments).parseZone()},a.localeData=ut,a.isDuration=At,a.monthsShort=function(e,t){return wn(e,t,"monthsShort")},a.weekdaysMin=function(e,t,n){return Mn(e,t,n,"weekdaysMin")},a.defineLocale=st,a.updateLocale=function(e,t){if(null!=t){var n,r,a=et;null!=tt[e]&&null!=tt[e].parentLocale?tt[e].set(O(tt[e]._config,t)):(null!=(r=ot(e))&&(a=r._config),t=O(a,t),null==r&&(t.abbr=e),(n=new D(t)).parentLocale=tt[e],tt[e]=n),it(e)}else null!=tt[e]&&(null!=tt[e].parentLocale?(tt[e]=tt[e].parentLocale,e===it()&&it(e)):null!=tt[e]&&delete tt[e]);return tt[e]},a.locales=function(){return k(tt)},a.weekdaysShort=function(e,t,n){return Mn(e,t,n,"weekdaysShort")},a.normalizeUnits=z,a.relativeTimeRounding=function(e){return void 0===e?Gn:"function"==typeof e&&(Gn=e,!0)},a.relativeTimeThreshold=function(e,t){return void 0!==qn[e]&&(void 0===t?qn[e]:(qn[e]=t,"s"===e&&(qn.ss=t-1),!0))},a.calendarFormat=function(e,t){var n=e.diff(t,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"},a.prototype=yn,a.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},a}()}).call(this,n(42)(e))},function(e,t,n){e.exports=n(365)()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ReactCSS=t.loop=t.handleActive=t.handleHover=t.hover=void 0;var r=l(n(368)),a=l(n(444)),o=l(n(470)),i=l(n(471)),s=l(n(472)),u=l(n(473));function l(e){return e&&e.__esModule?e:{default:e}}t.hover=i.default,t.handleHover=i.default,t.handleActive=s.default,t.loop=u.default;var c=t.ReactCSS=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),i=1;i<t;i++)n[i-1]=arguments[i];var s=(0,r.default)(n),u=(0,a.default)(e,s);return(0,o.default)(u)};t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ICON_FILE_CODE=t.ICON_CUBE=t.ICON_LAYER_GROUP=t.ICON_EXPAND_ARROWS=t.ICON_EXPAND=t.ICON_COMPRESS=t.ICON_ARROW_RIGHT=t.ICON_ARROW_CENTER_H=t.ICON_ARROW_LEFT=t.ICON_ARROW_DOWN=t.ICON_ARROW_CENTER_V=t.ICON_ARROW_UP=t.ICON_BARS=t.ICON_ALIGN_CENTER=t.ICON_ALIGN_RIGHT=t.ICON_ALIGN_LEFT=t.ICON_FONT=t.ICON_INFO_CIRCLE=t.ICON_TIMES_CIRCLE=t.SORT_DOWN=t.SORT_UP=t.ICON_BAN=t.ICON_USER_LOCK=t.ICON_CHEVRON_UP=t.ICON_CHEVRON_DOWN=t.ICON_ANGLE_DOUBLE_RIGHT=t.ICON_ANGLE_RIGHT=t.ICON_ANGLE_DOUBLE_LEFT=t.ICON_ANGLE_LEFT=t.ICON_EXCLAIMATION_TRIANGLE=t.ICON_CLIPBOARD=t.ICON_PLUS=t.ICON_SEARCH=t.ICON_EDIT=t.ICON_CHECK=t.ICON_CARET_DOWN=t.ICON_CARET_UP=t.ICON_CIRCLE_NOTCH=t.ICON_TIMES=t.ICON_COPY=t.ICON_AUDIO_TYPE=t.ICON_IMAGE_SEQ_TYPE=t.ICON_FILE_ARCHIVE=t.ICON_FILE_IMAGE=t.ICON_FILE_AUDIO=t.ICON_FILE_VIDEO=t.ICON_FILTER=t.ICON_STICKY_NOTE=t.ICON_IMAGE=t.ICON_VIDEO=void 0,t.ICON_UPLOAD=t.ICON_DOWNLOAD=t.ICON_JS=t.ICON_PROJECT_DIAGRAM=t.ICON_GLOBE=t.ICON_EMAIL=t.ICON_HUBSPOT=t.ICON_HELP=void 0;var r=n(0),a=n(37),o=n(290),i=n(291),s=n(292),u=n(293),l=n(294),c=n(94),d=n(295),p=n(296),f=n(297),h=n(298),m=n(299),_=n(300),y=n(301),g=n(302),v=n(303),b=n(58),w=n(304),M=n(305),L=n(306),T=n(307),k=n(308),x=n(309),E=n(57),S=n(95),O=n(310),D=n(311),Y=n(312),A=n(313),C=n(314),j=n(315),P=n(316),H=n(317),I=n(96),N=n(318),R=n(319),F=n(320),z=n(321),U=n(322),W=n(323),B=n(324),V=n(325),G=n(326),q=n(327),J=n(328),K=n(329),$=n(330),X=n(331),Z=n(332),Q=n(333),ee=n(334),te=n(335),ne=n(336),re=n(337),ae=n(338),oe=n(339),ie=n(340),se=n(341),ue=n(342);t.ICON_VIDEO=r.createElement(a.FontAwesomeIcon,{icon:S.faVideo}),t.ICON_IMAGE=r.createElement(a.FontAwesomeIcon,{icon:O.faImage}),t.ICON_STICKY_NOTE=r.createElement(a.FontAwesomeIcon,{icon:D.faStickyNote}),t.ICON_FILTER=r.createElement(a.FontAwesomeIcon,{icon:u.faFilter}),t.ICON_FILE_VIDEO=r.createElement(a.FontAwesomeIcon,{icon:c.faFileVideo}),t.ICON_FILE_AUDIO=r.createElement(a.FontAwesomeIcon,{icon:d.faFileAudio}),t.ICON_FILE_IMAGE=r.createElement(a.FontAwesomeIcon,{icon:p.faFileImage}),t.ICON_FILE_ARCHIVE=r.createElement(a.FontAwesomeIcon,{icon:f.faFileArchive}),t.ICON_IMAGE_SEQ_TYPE=r.createElement(a.FontAwesomeIcon,{icon:A.faImages}),t.ICON_AUDIO_TYPE=r.createElement(a.FontAwesomeIcon,{icon:C.faHeadphones}),t.ICON_COPY=r.createElement(a.FontAwesomeIcon,{icon:h.faCopy}),t.ICON_TIMES=r.createElement(a.FontAwesomeIcon,{icon:m.faTimes}),t.ICON_CIRCLE_NOTCH=r.createElement(a.FontAwesomeIcon,{icon:l.faCircleNotch}),t.ICON_CARET_UP=r.createElement(a.FontAwesomeIcon,{icon:o.faCaretUp}),t.ICON_CARET_DOWN=r.createElement(a.FontAwesomeIcon,{icon:i.faCaretDown}),t.ICON_CHECK=r.createElement(a.FontAwesomeIcon,{icon:s.faCheck}),t.ICON_EDIT=r.createElement(a.FontAwesomeIcon,{icon:_.faEdit}),t.ICON_SEARCH=r.createElement(a.FontAwesomeIcon,{icon:y.faSearch}),t.ICON_PLUS=r.createElement(a.FontAwesomeIcon,{icon:g.faPlus}),t.ICON_CLIPBOARD=r.createElement(a.FontAwesomeIcon,{icon:v.faClipboard}),t.ICON_EXCLAIMATION_TRIANGLE=r.createElement(a.FontAwesomeIcon,{icon:b.faExclamationTriangle}),t.ICON_ANGLE_LEFT=r.createElement(a.FontAwesomeIcon,{icon:w.faAngleLeft}),t.ICON_ANGLE_DOUBLE_LEFT=r.createElement(a.FontAwesomeIcon,{icon:M.faAngleDoubleLeft}),t.ICON_ANGLE_RIGHT=r.createElement(a.FontAwesomeIcon,{icon:L.faAngleRight}),t.ICON_ANGLE_DOUBLE_RIGHT=r.createElement(a.FontAwesomeIcon,{icon:T.faAngleDoubleRight}),t.ICON_CHEVRON_DOWN=r.createElement(a.FontAwesomeIcon,{icon:k.faChevronDown}),t.ICON_CHEVRON_UP=r.createElement(a.FontAwesomeIcon,{icon:x.faChevronUp}),t.ICON_USER_LOCK=r.createElement(a.FontAwesomeIcon,{icon:E.faUserLock}),t.ICON_BAN=r.createElement(a.FontAwesomeIcon,{icon:Y.faBan}),t.SORT_UP=r.createElement(a.FontAwesomeIcon,{icon:j.faSortUp}),t.SORT_DOWN=r.createElement(a.FontAwesomeIcon,{icon:P.faSortDown}),t.ICON_TIMES_CIRCLE=r.createElement(a.FontAwesomeIcon,{icon:H.faTimesCircle}),t.ICON_INFO_CIRCLE=r.createElement(a.FontAwesomeIcon,{icon:I.faInfoCircle}),t.ICON_FONT=r.createElement(a.FontAwesomeIcon,{icon:N.faFont}),t.ICON_ALIGN_LEFT=r.createElement(a.FontAwesomeIcon,{icon:R.faAlignLeft}),t.ICON_ALIGN_RIGHT=r.createElement(a.FontAwesomeIcon,{icon:F.faAlignRight}),t.ICON_ALIGN_CENTER=r.createElement(a.FontAwesomeIcon,{icon:z.faAlignCenter}),t.ICON_BARS=r.createElement(a.FontAwesomeIcon,{icon:U.faBars}),t.ICON_ARROW_UP=r.createElement(a.FontAwesomeIcon,{icon:W.faArrowToTop}),t.ICON_ARROW_CENTER_V=r.createElement(a.FontAwesomeIcon,{icon:V.faArrowsV}),t.ICON_ARROW_DOWN=r.createElement(a.FontAwesomeIcon,{icon:B.faArrowToBottom}),t.ICON_ARROW_LEFT=r.createElement(a.FontAwesomeIcon,{icon:G.faArrowToLeft}),t.ICON_ARROW_CENTER_H=r.createElement(a.FontAwesomeIcon,{icon:J.faArrowsH}),t.ICON_ARROW_RIGHT=r.createElement(a.FontAwesomeIcon,{icon:q.faArrowToRight}),t.ICON_COMPRESS=r.createElement(a.FontAwesomeIcon,{icon:X.faCompress}),t.ICON_EXPAND=r.createElement(a.FontAwesomeIcon,{icon:$.faExpand}),t.ICON_EXPAND_ARROWS=r.createElement(a.FontAwesomeIcon,{icon:K.faExpandArrowsAlt}),t.ICON_LAYER_GROUP=r.createElement(a.FontAwesomeIcon,{icon:Z.faLayerGroup}),t.ICON_CUBE=r.createElement(a.FontAwesomeIcon,{icon:Q.faCube}),t.ICON_FILE_CODE=r.createElement(a.FontAwesomeIcon,{icon:ee.faFileCode}),t.ICON_HELP=r.createElement(a.FontAwesomeIcon,{icon:te.faQuestionCircle}),t.ICON_HUBSPOT=r.createElement(a.FontAwesomeIcon,{icon:ne.faHubspot}),t.ICON_EMAIL=r.createElement(a.FontAwesomeIcon,{icon:re.faEnvelope}),t.ICON_GLOBE=r.createElement(a.FontAwesomeIcon,{icon:ae.faGlobe}),t.ICON_PROJECT_DIAGRAM=r.createElement(a.FontAwesomeIcon,{icon:oe.faProjectDiagram}),t.ICON_JS=r.createElement(a.FontAwesomeIcon,{icon:ie.faJs}),t.ICON_DOWNLOAD=r.createElement(a.FontAwesomeIcon,{icon:se.faDownload}),t.ICON_UPLOAD=r.createElement(a.FontAwesomeIcon,{icon:ue.faUpload})},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(9),u=n(60),l=n(4),c=function(e){function t(t){var n=e.call(this,t)||this;return n.tooltipId="imposium-button-"+s.generateUUID(),n}return a(t,e),t.prototype.onClick=function(e){this.props.onClick&&!this.props.loading&&this.props.onClick(e)},t.prototype.render=function(){var e=this,t=this.props,n=t.style,r=t.color,a=t.size,s=t.customStyles,c=this.props,d=c.width,p=c.loading,f=(c.tooltip,this.props),h=f.active,m=f.disabled,_=f.buttonRef,y=h?"active":"",g=m?"disabled":"";a||(a=""),n||(n="default"),r||(r=""),d&&(s?s.width=d:s={width:d});var v=p?i.createElement("span",{className:"loading-icon"},l.ICON_CIRCLE_NOTCH):this.props.children;return i.createElement("div",o({},u.renderTooltipProps(this.tooltipId,this.props.tooltip),{ref:_,className:"imposium-btn btn-"+n+" "+a+" "+r+" "+y+" "+g,onClick:function(t){return e.onClick(t)},style:s}),v,u.renderTooltip(this.tooltipId,this.props.tooltip))},t}(i.PureComponent);t.default=c},function(e,t,n){"use strict";var r=n(56),a="object"==typeof self&&self&&self.Object===Object&&self,o=r.a||a||Function("return this")();t.a=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BATCHES_COPY=t.project=t.header=t.integration=t.publish=t.compositions=t.previewer=t.assets=void 0,t.assets={tooltipFilter:"Filter by Asset type",previewNotAvailable:"Preview Not Available for this Asset Type",iconTypes:{filter:"Filter By Type",lut:"LUT",all:"All Types",video:"Video Files",audio:"Audio Files",video_composition:"Composition",image:"Image Files",image_sequence:"Image Sequences (Archive)",template:"Custom Template",static_composition:"Template",font:"Font Files"},uploads:{noUploads:"There are currently no assets uploading...",preparePhase:"Preparing asset...",autoTagInput:"Tag by filename",assignToStoryInput:"Assign to Story",assignToStoryInfo:"If selected, any assets uploaded will only be available to use with the currently selected story.",uploadButton:"Upload"},tags:{add:"Add new tag",duplicated:'Duplicated Tags: "[dupedTags]" will not be added.'},field:{fieldMismatchError:'Asset Type mismatch. Field only accepts "[accepts]" assets.',dragPrompt:"Drag Asset Here",tooltipClear:"Clear the selected Asset",tooltipFilter:"Filter assets to match Asset type"},details:"Asset Details",newDetails:"New Asset Details",name:"Name",date:"Date Created",addTag:"Add Tag",assetTag:"Tags",sessionExpired:"Your session has expired, please log in again to continue."},t.previewer={previewVars:"Preview Variables",time:"Time Elapsed:",expRunning:"Rendering Experience",runExpStart:"Creating Experience",runExpError:"Error running experience - ID: [expId]",triggerExpError:"Error triggering experience - ID: [expId]",expId:"Running Experience - ID: [expId]",createExpError:"Error creating experience",logDownloadError:"Could not download log of Job: [jobId]",logURLError:"Could not retrieve log URL of Job: [jobId]",btnLog:"Job Log",btnRender:"Render",btnReRender:"Re-Render",expIdField:"Exp. ID",runExpErrorDes:"Sorry, there was a problem creating your video. Please try again."},t.compositions={name:"Name",width:"Width",height:"Height",rotation:"Rotation",color:"Color",x:"X",y:"Y",wrap:"Wrap",fit:"Fit",fillMode:"Fill Mode",hAlign:"H. Align",vAlign:"V. Align",backgroundColor:"Background",layers:"Layers",layerText:"Text",fontType:"Font Type",layerImage:"Image",fontSize:"Font Size",lineHeight:"Line Height",font:"Font",letterSpacing:"Letter Spacing",wordSpacing:"Word Spacing",tooltipName:"Display name of this composition.",tooltipBackgroundColor:"Background color of this composition. Can also be transparent.",tooltipWidth:"Width of the composition, in pixels",tooltipHeight:"Height of the composition, in pixels",tooltipAddLayer:"Add a new layer to the composition",tooltipLayerRotation:"Rotation angle of the layer, in degrees",tooltipLayerX:"Layer X position.",tooltipLayerY:"Layer Y position",tooltipLayerWidth:"Layer width, in pixels.",tooltipLayerHeight:"Layer height, in pixels",textOptions:"Text Options",textLayerContent:"Content",tooltipTextLayerContent:"The copy rendered in this layer. Wrap variables like so: {{variable_id}}."},t.publish={accessKey:"Access Key",tooltipAccessKey:"API access key to use for this video distribution.",publishTitle:"Publish & Deliver",publishStepTitle:"STEP 1: Publish your Project",publishStepDesc:"Your project needs to be published before your changes can be seen. If you haven't made any changes since the last time you published, you can skip to the next step.",distributeStepTitle:"STEP 2: How do you want your users to view their video?",distributeStepDesc:"Select which Composition you want to deliver, access credentials you want to use, and distribution channel.",compositionError:"Please Select Composition",btnWebsite:"Webpage",webpageTitle:"STEP 3: Webpage",webPageHosted:"Webpage hosted on Imposium",webpageDesc:"You can share a demo page that is hosted on Imposium or you can download a sample webpage you can customize and use to generate videos. Please ensure you include a column for every variable on your story.",sampleWebpage:"Download sample webpage",btnEmail:"Email",exporting:"Exporting CSV... (please wait)",emailTitle:"STEP 3: Upload a CSV file with your user information in it.",emailDesc:"You can download a sample CSV with fields to populate as a starting point. Or you can upload one that already has the data in it.",downloadSampleCsvLink:"Download Sample CSV",uploadCsv:"Upload Your CSV UserList",generatingLink:"STEP 4: Generating embed links",downloadLink:"STEP 5: Download Your Userlist CSV file",btnDownload:"Download CSV",generatingLinkDesc:"Please wait while we generate the link for your users. This may take few minutes.",missingColumns:"Error: missing required columns",renderBatchFailed:"Error: Failed to render batch",createBatchFailed:"Error: Failed to create batch",downloadError:"Error downloading sample CSV.",embeddedCodeCopyError:"Error copying embed code.",creatingLinks:"Creating User Links... (please wait)",importingData:"Importing Data... (please wait)",downloadDesc:"Your CSV data file is ready to download with an embed code you can import into your email platform to send out.",titleMissingColumns:"Warning: ",csvMissingColumns:"Some of your column names did not match up with the variables in the story. Please ensure these variables line up and then re-upload the csv: ",csvMatchColumns:"Please match the column(s) provided to the story variables:",exportBatchOfVideo:"Export batch of videos",btnHubspot:"Hubspot",hubspotTitle:"STEP 3: Copy Hubspot code snippet",hubspotDesc:"Copy the provided embed code into HubSpot. Replace the placeholder variable values with HubSpot template strings, to splice in your user data.",saveChanges:"Save Changes",embeddedCode:"Embed Url: ",btnAPI:"API integration",btnExport:"Export",btnPublish:"Publish",btnSkip:"Skip",btnBack:"Back",btnFinished:"Done",btnCancel:"Cancel",btnNext:"Next",noCompErrorTitle:"No Compositions Found",noCompErrorDesc:"You must have at least 1 composition on your story to render and distribute videos."},t.integration={errorPullingComps:" Error getting composition IDs, contact your Imposium admin for support.",errorCreatingCreds:" Error creating credentials, contact your Imposium admin for support.",errorGettingCreds:" Error getting credentials, contact your Imposium admin for support.",documentation:"Documentation",docParagraph:"Use the links below for more information on integrating Imposium into your application.",js:"JavaScript SDK",jsSdkLink:"https://docs.imposium.com/js-sdk/#/",restLink:"https://docs.imposium.com",rest:"REST API",sdkArchiveSuffix:" - JS SDK Integration.zip"},t.header={publishing:"Publishing...",working:"Using Working Copy",statusError:"Error getting story status",publishJobError:"Error creating publish story job",publishPollError:"Error polling publish job status"},t.project={compName:"Composition",tooltipCompId:"Unique ID of the selected composition. Used to render that specific composition via the API and Imposium JS-SDK."},t.BATCHES_COPY={progress:{notRendered:"not rendered",rendering:"rendering",rendered:"rendered",cancelled:"cancelled",queued:"queued",malformed:"unknown"}}},function(e,n){e.exports=t},function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i};Object.defineProperty(t,"__esModule",{value:!0}),t.s3Url=t.formattedTime=t.formatDateDefault=t.padStart=t.toFixed=t.mimetypeConformsToOverlay=t.isFont=t.validateAssetMimetype=t.isObjEmpty=t.filterHotkeys=t.fitToContainer=t.generateUUID=t.string2HexCode=t.parameterizeServiceUrl=t.scrapeEmail=t.getFirstStoryInOrg=t.validateAccessLevel=t.getActiveOrg=t.isLocal=void 0;t.isLocal=function(){return"localhost"===window.location.hostname};t.getActiveOrg=function(e,t){return t.organizations.find((function(t){return t.id===e}))};t.validateAccessLevel=function(e,n,r){var a=t.getActiveOrg(e,r);return!!a&&a.services.includes(n)};t.getFirstStoryInOrg=function(e,n){var r=t.getActiveOrg(e,n);return r&&"object"==typeof r.stories[0]?r.stories[0].id:""};t.scrapeEmail=function(e){return e&&e.idTokenPayload&&e.idTokenPayload["https://imposium.com/email"]?e.idTokenPayload["https://imposium.com/email"]:""};t.parameterizeServiceUrl=function(e,t,n,r){if(!e||!t)return e&&!t?n+"?organization_id="+e:n;switch(r){case 1:case 4:case 5:case 6:case 8:return n+"/"+t+"?organization_id="+e;case 3:return n+"/dashboard/live/"+t+"?organization_id="+e;default:return n+"?organization_id="+e}};t.string2HexCode=function(e){var t=(16777215&e.split("").map((function(t,n){return e.charCodeAt(n)})).reduce((function(e,t){return t+((e<<5)-e)}),0)).toString(16).toUpperCase();return"#"+("00000".substring(0,6-t.length)+t)};t.generateUUID=function(){var e=(new Date).getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(t){var n=(e+16*Math.random())%16|0;return e=Math.floor(e/16),("x"===t?n:7&n|8).toString(16)}))};t.fitToContainer=function(e,t,n){var r,a,o,i,s=t.width/t.height,u=n.padding?e.width-2*n.padding:e.width,l=n.padding?e.height-2*n.padding:e.height,c=n.padding?n.padding:0;return"proportionalInside"===n.scaleMode?(r=(a=u)/s)>l&&(a=(r=l)*s):"proportionalOutside"===n.scaleMode?(r=(a=u)/s)<l&&(a=(r=l)*s):"none"!==n.scaleMode&&n.scaleMode||(a=t.width,r=t.height),n.maxWidth&&a>n.maxWidth&&(r=(a=n.maxWidth)/s),n.maxHeight&&r>n.maxHeight&&(a=(r=n.maxHeight)*s),i="left"===n.hAlign?0:"right"===n.hAlign?u-a:(u-a)/2,o="top"===n.vAlign?0:"bottom"===n.vAlign?l-r:(l-r)/2,{width:a,height:r,top:o+=c,left:i+=c}};t.filterHotkeys=function(e){var t=(e.target||e.srcElement).tagName,n=t.isContentEditable||"INPUT"===t||"SELECT"===t||"TEXTAREA"===t,r="Enter"===e.code,a="Escape"===e.code,o=!0===e.metaKey;return!!(!n||n&&r||n&&a||n&&o)};t.isObjEmpty=function(e){for(var t in e)if(e.hasOwnProperty(t))return!1;return!0};t.validateAssetMimetype=function(e){var n=r(e.type.split("/"),2),a=n[0],o=n[1],i=e.name.split("."),s=i[i.length-1];switch(a){case"image":case"video":case"audio":return!0;case"application":switch(o){case"zip":case"x-gzip":return!0}}return!!t.isFont(a,s)||(-1!==e.name.indexOf(".CUBE")||(console.warn("Mimetype: "+e.type+" is not a supported asset type."),!1))};t.isFont=function(e,t){var n=["font","otf","sfnt","ttf","woff","woff2","font-sfnt","font-woff","vnd.ms-fontobject","font/otf","font/sfnt","font/ttf","font/woff","font/woff2","font/font-sfnt","font/font-woff","font/vnd.ms-fontobject"];return e?-1!==n.indexOf(e):-1!==n.indexOf(t)};t.mimetypeConformsToOverlay=function(e,t){var n=r(t.type.split("/"),2),a=n[0],o=n[1];return"video"===e&&"video"===a||"image"===e&&"image"===a||"audio"===e&&"audio"===a||"template"===e&&"application"===a&&("zip"===o||"x-gzip"===o)||"image_sequence"===e&&"application"===a&&("zip"===o||"x-gzip"===o)};t.toFixed=function(e,t){var n=new RegExp("^-?\\d+(?:.\\d{0,"+(t||-1)+"})?");return e.toString().match(n)[0]};t.padStart=function(e,t){return new Array(t+1-(e+"").length).join("0")+e};t.formatDateDefault=function(e){var t=new Date(1e3*e),n=t.getMonth()+1,r=t.getDate(),a=t.getFullYear(),o=t.getHours(),i=o>=12?"PM":"AM";o>12&&(o-=12),0===o&&(o=12);var s=t.getMinutes();return s<10&&(s="0"+s),n+"/"+r+"/"+a+" "+o+":"+s+" "+i};t.formattedTime=function(e){var t=Math.floor(e/6e4),n=(e%6e4/1e3).toFixed(0);return(t<10?"0":"")+t+":"+(n<10?"0":"")+n};t.s3Url=function(e,t,n){return e?e.replace(t,n):""}},function(e,t){e.exports=n},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(9),u=n(60),l=n(4),c=n(5),d=function(e){function t(t){var n=e.call(this,t)||this;return n.tooltipId=s.generateUUID(),n.state={showInfo:!1},n.toggleIDInfo=function(){n.setState({showInfo:!n.state.showInfo})},n}return a(t,e),t.prototype.getLabelClass=function(){return this.props.label?"label-"+(this.props.labelPosition?this.props.labelPosition:"left"):"no-label"},t.prototype.renderLabel=function(){var e=this.state.showInfo,t=this.props,n=t.info,r=t.label,a=e?l.ICON_TIMES_CIRCLE:l.ICON_INFO_CIRCLE,s=n?i.createElement(c.default,{onClick:this.toggleIDInfo,size:"small",style:"subtle"},a):null;return s||r?i.createElement("label",o({},u.renderTooltipProps(this.tooltipId,this.props.tooltip),{className:this.getLabelClass()}),s,s&&" ",r):null},t.prototype.render=function(){var e=this.props,t=e.label,n=e.width,r=e.customClass,a=this.renderLabel(),s={},l={};return t||(l=u.renderTooltipProps(this.tooltipId,this.props.tooltip)),n&&(s.width="string"==typeof n?n:n+"px"),i.createElement("div",{className:"form-field "+r+" "+this.getLabelClass(),style:s},a,i.createElement("div",o({className:"form-field-content "+this.getLabelClass()},l),this.props.children,this.renderButtons()),u.renderTooltip(this.tooltipId,this.props.tooltip),this.renderInfo())},t.prototype.renderInfo=function(){var e=this.props.info,t=this.state.showInfo;return e&&t?i.createElement("p",null,e):null},t.prototype.renderButtons=function(){if(this.props.buttons)return i.createElement("div",{className:"form-field-buttons"},this.props.buttons)},t}(i.PureComponent);t.default=d},function(e,t){var n=Array.isArray;e.exports=n},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},i=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},s=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),l=n(62),c=n(5),d=n(11),p=n(9),f=n(4),h=n(363),m=function(e){function t(t){var n=e.call(this,t)||this;if(n.evtHandlers={submittable:function(){return n.forceSubmit()},controlled:function(e){return n.toggleEditing(e)},cancel:function(){return n.cancelEdit()},clear:function(){return n.forceSubmit(!0)},toggleEditing:function(e){return n.toggleEditing(e)},forceSubmit:function(){return n.forceSubmit()},clearValue:function(){return n.clearValue()},copyToClipboard:function(e){return n.copyToClipboard(e)},onSuggestionsFetchRequested:function(e){return n.onSuggestionsFetchRequested(e)},onSuggestionsClearRequested:function(){return n.onSuggestionsClearRequested()},getSuggestionValue:function(e){return n.getSuggestionValue(e)},renderSuggestion:function(e){return n.renderSuggestion(e)}},n.componentDidUpdate=function(e,t){(n.props.controlled||n.props.submittable)&&(e.value!==n.props.value&&n.setState({internalValue:n.props.value}),""===n.props.value&&!n.state.editing&&t.editing&&n.setState({internalValue:""}))},n.forceSubmit=function(e){void 0===e&&(e=!1);var t=n.state.internalValue;e||(n.props.doSubmit(t),"add"===n.props.submittableType&&n.setState({internalValue:""})),e&&(n.props.doSubmit(""),n.setState({internalValue:""}))},n.renderSubmittableIcon=function(){switch(n.props.submittableType){case"search":return f.ICON_SEARCH;case"check":return f.ICON_CHECK;case"add":return f.ICON_PLUS;default:return null}},n.onSuggestionsFetchRequested=function(e){var t=e.value;n.setState({suggestions:n.getSuggestions(t)})},n.onSuggestionsClearRequested=function(){n.setState({suggestions:[]})},n.props.controlled&&n.props.submittable)throw new Error("Actionable TextField(s) must be one of either: controlled or submittable.");return n.state={internalValue:t.value||"",suggestions:[],editing:!1},n.inputRef=u.createRef(),l.default.filter=function(e){return p.filterHotkeys(e)},n}return a(t,e),t.prototype.componentDidMount=function(){this.props.focusOnMount&&this.inputRef.current&&this.inputRef.current.focus()},t.prototype.componentWillUnmount=function(){this.props.submittable?(l.default.unbind("enter",this.evtHandlers.submittable),l.default.unbind("esc",this.evtHandlers.clear)):this.props.controlled&&(l.default.unbind("enter",this.evtHandlers.controlled),l.default.unbind("esc",this.evtHandlers.cancel))},t.prototype.setEditing=function(e){var t=this;this.setState({editing:e},(function(){t.inputRef.current.focus()}))},t.prototype.blur=function(e){this.props.onBlur&&this.props.onBlur(e),this.props.submittable?(l.default.unbind("enter",this.evtHandlers.submittable),l.default.unbind("esc",this.evtHandlers.clear)):this.props.controlled&&(l.default.unbind("enter",this.evtHandlers.controlled),l.default.unbind("esc",this.evtHandlers.cancel))},t.prototype.focus=function(e){this.props.onFocus&&this.props.onFocus(e),this.props.submittable?(l.default("enter",this.evtHandlers.submittable),l.default("esc",this.evtHandlers.clear)):this.props.controlled&&(l.default("enter",this.evtHandlers.controlled),l.default("esc",this.evtHandlers.cancel))},t.prototype.cancelEdit=function(){this.setState({editing:!1,internalValue:this.props.value})},t.prototype.copyToClipboard=function(e){var t=this.props,n=t.onNotification,r=t.onError;navigator.clipboard.writeText(this.props.value).then((function(){n&&n("Copied to clipboard!")}),(function(){r&&r("Error copying to clipboard.")}))},t.prototype.getValue=function(){var e=this.props,t=e.controlled,n=e.submittable,r=e.value,a=this.state.internalValue;return t||n?a:r||""},t.prototype.onChange=function(e,t){var n=this,r=this.props.pattern,a=t?t.newValue:e.target.value;if(this.props.controlled||this.props.submittable)this.setState({internalValue:a},(function(){t&&"click"===t.method&&n.evtHandlers.submittable()}));else{if(r&&!r.test(a))return;""===a&&(a=null),this.props.onChange(a)}},t.prototype.toggleEditing=function(e){var t=this;e.preventDefault(),e.stopPropagation();var n=this.state,r=n.editing,a=n.internalValue,o=this.props.value;r?this.setState({editing:!1},(function(){if(a!==o){var e=t.state.internalValue;""===e&&(e=null),t.props.onSubmit(e)}})):this.setState({editing:!0},(function(){var e=t.inputRef.current;e&&e.focus()}))},t.prototype.clearValue=function(){var e=this;this.setState({internalValue:""},(function(){e.props.doSubmit("")}))},t.prototype.getSuggestions=function(e){var t=e.trim().toLowerCase(),n=t.length;return 0===n?[]:this.props.suggestions.filter((function(e){return e.toLowerCase().slice(0,n)===t}))},t.prototype.getSuggestionValue=function(e){return e},t.prototype.renderSuggestion=function(e){return u.createElement("div",{className:"suggestion"},e)},t.prototype.renderButtons=function(){var e,t=this.props,n=t.controlled,r=t.submittable,a=(t.readOnly,t.buttons),o=t.showCopy,l=t.submittableType,d=t.value,p=t.hideButtons,h=this.state,m=h.editing;h.internalValue;a?Array.isArray(a)?e=s([],i(a)):(e=[]).push(a):e=[];var _="search"===l?"Search":"Confirm";if(p)return[];if(n){var y=m?f.ICON_CHECK:f.ICON_EDIT;e.push(u.createElement(c.default,{key:"btn-edit",style:"subtle",tooltip:"Edit",color:"secondary",onClick:this.evtHandlers.toggleEditing},y))}return r&&(e.push(u.createElement(c.default,{key:"btn-submit",style:"subtle",tooltip:_,color:"secondary",onClick:this.evtHandlers.forceSubmit},this.renderSubmittableIcon())),d&&e.push(u.createElement(c.default,{key:"btn-clear",style:"subtle",tooltip:"Clear",onClick:this.evtHandlers.clearValue},f.ICON_TIMES))),o&&e.push(u.createElement(c.default,{key:"btn-copy",style:"subtle",color:"primary",tooltip:"Copy to Clipboard",onClick:this.evtHandlers.copyToClipboard},f.ICON_CLIPBOARD)),e},t.prototype.renderInput=function(){var e=this,t=this.props,n=t.placeholder,r=t.controlled,a=t.submittable,i=t.disabled,s=t.readOnly,l=t.loading,c=this.state.suggestions,d=this.state.editing,p=r&&!d||i,f=r||a?"controlled-input":"",m={type:"text",placeholder:n,value:this.getValue(),disabled:p||l,readOnly:s,ref:this.inputRef,onFocus:function(t){return e.focus(t)},onBlur:function(t){return e.blur(t)}};return this.props.suggestions?(m.onChange=function(t,n){return e.onChange(t,n)},u.createElement(h,{suggestions:c,onSuggestionsFetchRequested:this.evtHandlers.onSuggestionsFetchRequested,onSuggestionsClearRequested:this.evtHandlers.onSuggestionsClearRequested,getSuggestionValue:this.evtHandlers.getSuggestionValue,renderSuggestion:this.evtHandlers.renderSuggestion,inputProps:m})):(m.onChange=function(t){return e.onChange(t)},u.createElement("input",o({className:""+f},m)))},t.prototype.render=function(){var e=this.props,t=e.label,n=e.width,r=e.tooltip,a=e.info,o=e.labelPosition;return u.createElement(d.default,{customClass:"text-field",label:t,buttons:this.renderButtons(),tooltip:r,info:a,labelPosition:o,width:n},this.renderInput())},t}(u.PureComponent);t.default=m},function(e,t,n){var r=n(103),a="object"==typeof self&&self&&self.Object===Object&&self,o=r||a||Function("return this")();e.exports=o},function(e,t){e.exports=function(e){return null!=e&&"object"==typeof e}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0);t.default=function(e){var t=e.style;return t||(t="default"),r.createElement("div",{className:"horizontal-rule "+t})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.deleteAssetTag=t.updateAssetData=t.updateAssetName=t.addAssetTag=t.deleteAssets=t.getAssets=t.doAssetTableHydration=t.toggleLoading=void 0;var r=n(83),a=n(33),o={TOGGLE_LOADING:"assetList/TOGGLE_LOADING",GET:"assetList/GET",ADD_TAG:"assetList/ADD_TAG",DELETE_TAG:"assetList/DELETE_TAG",UPDATE_NAME:"assetList/UPDATE_NAME",UPDATE_DATA:"assetList/UPDATE_DATA"};t.toggleLoading=function(e){return{type:o.TOGGLE_LOADING,toggle:e}};t.doAssetTableHydration=function(e,n,o){return function(i){return new Promise((function(s,u){Promise.all([i(t.getAssets(e,n)),i(r.getAssetTagList(e,n))]).then((function(){i(a.resetSelection),s()})).catch((function(e){"function"==typeof o&&o(),u()}))}))}};t.getAssets=function(e,n){return function(r,a){return new Promise((function(i,s){var u=a(),l=u.assetFilters;u.loading||r(t.toggleLoading(!0)),e.getAssets(l,n,!0).then((function(e){r({type:o.GET,assetList:e}),r(t.toggleLoading(!1)),i()})).catch((function(e){r(t.toggleLoading(!1)),s()}))}))}};t.deleteAssets=function(e,n,r){return function(a){if(window.confirm("Are you sure you want to delete "+n.length+" assets?"))return new Promise((function(o,i){a(t.toggleLoading(!0)),e.deleteAssets(n).then((function(){a(t.getAssets(e,r)),o()})).catch((function(e){a(t.toggleLoading(!1)),i()}))}))}};t.addAssetTag=function(e,t,n,r){return function(r,a){return new Promise((function(a){var i,s=n.includes(",")?n.split(",").filter(String).map((function(e){return e.trim()})):[n];0===s.length&&a(),1===s.length&&(i=s.map((function(n){return e.addAssetTag(t,n).then((function(){return a()})).catch((function(e){return a(e)}))})),Promise.all(i).then((function(e){a()})),r({type:o.ADD_TAG,id:t,freshTags:s})),s.length>1&&(e.addAssetTags(t,s).then((function(){return a()})).catch((function(e){return a(e)})),r({type:o.ADD_TAG,id:t,freshTags:s}))}))}};t.updateAssetName=function(e,t,n,r){return void 0===r&&(r=!1),function(a){return new Promise((function(i,s){a({type:o.UPDATE_NAME,id:t,name:n}),r||e.updateAsset(t,{name:n}).then((function(){i()})).catch((function(e){s()}))}))}};t.updateAssetData=function(e,t,n){return function(r){return new Promise((function(a,i){r({type:o.UPDATE_DATA,id:t,name:name}),e.updateAsset(t,{data:JSON.stringify(n)}).then((function(){a()})).catch((function(e){i()}))}))}};t.deleteAssetTag=function(e,t,n){return function(r){return new Promise((function(a,i){r({type:o.DELETE_TAG,id:t,tag:n}),e.deleteAssetTag(t,n).then((function(){a()})).catch((function(e){i()}))}))}},t.default=o},function(e,t,n){var r=n(31),a=n(370),o=n(371),i=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":i&&i in Object(e)?a(e):o(e)}},function(e,t,n){var r=n(396),a=n(399);e.exports=function(e,t){var n=a(e,t);return r(n)?n:void 0}},function(e,t,n){"use strict";(function(e){var r=n(6),a=n(274),o="object"==typeof exports&&exports&&!exports.nodeType&&exports,i=o&&"object"==typeof e&&e&&!e.nodeType&&e,s=i&&i.exports===o?r.a.Buffer:void 0,u=(s?s.isBuffer:void 0)||a.a;t.a=u}).call(this,n(82)(e))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(4);t.default=function(){return r.createElement("div",{className:"spinner"},r.createElement("div",{className:"icon"},a.ICON_CIRCLE_NOTCH))}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(0),u=n(11),l=n(4),c=n(5),d=function(e){function t(t){var n=e.call(this,t)||this;return n.evtHandlers={copyToClipboard:function(e){return n.copyToClipboard(e)}},n}return a(t,e),t.prototype.copyToClipboard=function(e){var t=this.props,n=t.onNotification,r=t.onError;navigator.clipboard.writeText(this.props.value).then((function(){n&&n("Copied to clipboard!")}),(function(){r&&r("Error copying to clipboard.")}))},t.prototype.onChange=function(e){var t=e.target.value;"true"===t&&(t=!0),"false"===t&&(t=!1),this.props.onChange(t)},t.prototype.render=function(){var e,t=this,n=this.props,r=n.label,a=n.showCopy,d=n.options,p=n.value,f=n.width,h=n.buttons,m=n.selectRef,_=n.disable,y=n.tooltip,g=n.info,v=n.labelPosition,b=n.disableFirst,w=[],M=null==p?"":p,L=s.createElement("div",{key:"caret",className:"caret"},l.ICON_CARET_DOWN);return e=h?Array.isArray(h)?i([L],o(h)):[L,h]:[L],a&&e.push(s.createElement(c.default,{key:"btn-copy",style:"subtle",color:"primary",tooltip:"Copy to Clipboard",onClick:this.evtHandlers.copyToClipboard},l.ICON_CLIPBOARD)),d&&(w=d.map((function(e,t){var n=!!(0===t&&b||void 0!==e.disabled&&e.disabled),r=void 0!==e.value?e.value:e,a=void 0!==e.label?e.label:e;return s.createElement("option",{disabled:n,key:"option-"+r,value:r},a)}))),s.createElement(u.default,{customClass:"select-field",label:r,tooltip:y,buttons:e,info:g,labelPosition:v,width:f},s.createElement("select",{value:M,onChange:function(e){return t.onChange(e)},ref:m,disabled:_},w))},t}(s.PureComponent);t.default=d},function(e,t){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.updateFilters=void 0;var r={UPDATE:"assetFilters/UPDATE",RESET:"footageFilters/RESET"};t.updateFilters=function(e){return{type:r.UPDATE,newFilters:e}},t.default=r},function(e,t,n){"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),t.ASSET_COLORS=t.ASSET_TYPES=t.ASSET_ORIGIN=t.ASSET_DISTRO=void 0,t.ASSET_DISTRO="https://d188rqu2y6x0ew.cloudfront.net",t.ASSET_ORIGIN="https://imposium-footage.s3.us-east-1.amazonaws.com",t.ASSET_TYPES={VIDEO_COMPOSITION:"video_composition",STATIC_COMPOSITION:"static_composition",VIDEO:"video",IMAGE:"image",TEMPLATE:"template",AUDIO:"audio",IMAGE_SEQUENCE:"image_sequence",FONT:"font",LUT:"lut",ALL:"all"},t.ASSET_COLORS=((r={})[t.ASSET_TYPES.VIDEO]="rgba(236,22,150, 1)",r[t.ASSET_TYPES.IMAGE]="rgba(241,191,21, 1)",r[t.ASSET_TYPES.AUDIO]="rgba(72,177,222,1)",r[t.ASSET_TYPES.TEMPLATE]="rgba(208, 80, 35, 1)",r[t.ASSET_TYPES.VIDEO_COMPOSITION]="rgba(215, 22, 22, 1)",r[t.ASSET_TYPES.IMAGE_SEQUENCE]="rgba(241,191,21, 1)",r)},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.getPlayerStyle=void 0;var o=n(0),i=n(9),s=n(34);t.getPlayerStyle=function(e,t,n,r,a,o,s){var u={width:e,height:t},l={width:n,height:r},c=i.fitToContainer(u,l,{scaleMode:"proportionalInside",maxWidth:o,maxHeight:s,padding:a}),d=c.width,p=c.height;return{top:c.top+"px",left:c.left+"px",width:d+"px",height:p+"px"}};var u=function(e){function n(t){var r=e.call(this,t)||this;return r.state={videoHeight:1080,videoWidth:1920,scaleMode:n.SCALE_MODES.AUTOMATIC},r.videoNode=o.createRef(),r}return a(n,e),n.prototype.getVideoStyle=function(){var e=this.state,n=e.videoHeight,r=e.videoWidth,a=this.props,o=a.padding,i=a.width,u=a.height,l=a.maxWidth,c=a.maxHeight,d=void 0!==o?o:s.DEFAULT_PADDING;return n&&r?t.getPlayerStyle(i,u,r,n,d,l,c):{}},n.prototype.setTime=function(e){var t=this.videoNode.current;t&&(t.currentTime=e)},n.prototype.metadataLoaded=function(e){this.setState({videoWidth:e.target.videoWidth,videoHeight:e.target.videoHeight})},n.prototype.renderCustomControls=function(){var e=this.props.customControls;return e?o.cloneElement(e,{videoNode:this.videoNode}):null},n.prototype.render=function(){var e=this,t=this.props,n=t.url,r=t.active,a=t.muted,i=t.customControls,s=t.hideDefaultControls,u=!i&&!s,l=!!this.props.autoPlay&&this.props.autoPlay;return!1!==r?o.createElement("div",{className:"media-player"},o.createElement("div",{className:"inner-viewer",style:this.getVideoStyle()},o.createElement("video",{controls:u,onLoadedMetadata:function(t){return e.metadataLoaded(t)},muted:a,src:n,ref:this.videoNode,preload:"auto",autoPlay:l}),this.renderCustomControls())):null},n.SCALE_MODES={MANUAL:"manual",AUTOMATIC:"automatic"},n}(o.PureComponent);t.default=u},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},o=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var i=n(343),s=n(28),u=function(){function e(){}return e.LAST_STORY_ID_CACHE="imp_hub_last_story_id",e.LAST_ORG_ID_CACHE="imp_hub_last_org_id",e.SESSION_COOKIE_NAME="auth_state",e.FRESH_COOKIE={sub:"",organization_id:"",story_id:"",stories_hash:0,orgs_hash:0},e.getAccessData=function(t,n){return new Promise((function(r,a){var o=n?n+"/access":e.determineAccessUrl();s.default.get(o,{headers:{Authorization:"Bearer "+t}}).then((function(e){r(e.data?e.data:[])})).catch((function(e){a(e)}))}))},e.getSession=function(){return i.getJSON(e.SESSION_COOKIE_NAME)},e.removeSession=function(){var t=e.scrapeDomain();i.remove(e.SESSION_COOKIE_NAME,{domain:t})},e.buildFreshSession=function(t,n){var r,a,o,i,s=t.idTokenPayload,u=s.sub,l=s.exp,c=n.organizations,d="",p="";try{a=localStorage.getItem(e.LAST_ORG_ID_CACHE),o=localStorage.getItem(e.LAST_STORY_ID_CACHE)}catch(e){console.warn("Failed to look up cached hub settings",e)}a&&"object"==typeof(i=n.organizations.find((function(e){return e.id===a})))&&i.hasOwnProperty("id")&&(d=a),o&&d&&i.stories.find((function(e){return e.id===o}))&&(p=o),!d&&c.length>0&&"object"==typeof c[0]&&c[0].hasOwnProperty("id")&&(d=c[0].id),!p&&c[0].stories.length>0&&"object"==typeof c[0].stories[0]&&c[0].stories[0].hasOwnProperty("id")&&(p=c[0].stories[0].id),r={sub:u,organization_id:d,story_id:p,stories_hash:e.generateStoriesHash(n),orgs_hash:e.generateOrgsHash(n)},e.storeSession(r,l)},e.storeSession=function(t,n){var a=r(r({},e.FRESH_COOKIE),t),o=e.scrapeDomain(),s=new Date(1e3*n);i.set(e.SESSION_COOKIE_NAME,a,{domain:o,expires:s})},e.updateSession=function(t,n){var a=e.getSession(),o=r(r({},a),t);if(t.hasOwnProperty("organization_id"))try{localStorage.setItem(e.LAST_ORG_ID_CACHE,t.organization_id)}catch(e){console.warn("Failed to cache last organization id selected",e)}if(t.hasOwnProperty("story_id"))try{localStorage.setItem(e.LAST_STORY_ID_CACHE,t.story_id)}catch(e){console.warn("Failed to cache last story id selected",e)}e.storeSession(o,n)},e.generateOrgsHash=function(t){var n=t.organizations.map((function(e){return e.id})).join("");return e.string2Hash(n)},e.generateStoriesHash=function(t){var n=t.organizations.reduce((function(e,t){return o(o([],a(e)),a(t.stories))}),[]).map((function(e){return""+e.id+e.name})).join("");return e.string2Hash(n)},e.string2Hash=function(e){var t=0;if(0===e.length)return t;for(var n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return t},e.scrapeDomain=function(){var e=window.location.host.split(".").reverse();return e.length>2?"."+e[1]+"."+e[0].split(":")[0]:null},e.determineAccessUrl=function(){var e=window.location,t=e.hostname,n=e.host;return"localhost"===t?"https://api/access":n.includes(".staging.")?"https://api.staging.imposium.com/access":"https://api.imposium.com/access"},e}();t.default=u},function(e,t){e.exports=r},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(344),o=function(){function e(){}return e.IMPOSIUM_APP_DEFAULTS={domain:"imposium.auth0.com",scope:"openid",responseType:"token id_token",redirectUri:window.location.origin+"/auth"},e.bindToClient=function(t){e.auth0Client=new a.WebAuth(r({clientID:t},e.IMPOSIUM_APP_DEFAULTS))},e.login=function(){e.auth0Client.authorize()},e.logout=function(){e.auth0Client.logout({returnTo:window.location.origin+"/auth"})},e.checkExpiry=function(e){return e>Date.now().valueOf()/1e3},e.parseIdFromHash=function(t){return new Promise((function(n,r){e.auth0Client.parseHash({options:t},(function(e,t){e?r(e):n(t)}))}))},e.checkSession=function(){return new Promise((function(t,n){e.auth0Client.checkSession({},(function(e,r){e?n(e):t(r)}))}))},e}();t.default=o},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(11),s=n(4),u=function(e){function t(t){return e.call(this,t)||this}return a(t,e),t.prototype.toggle=function(e){this.props.propagate||e.stopPropagation(),this.props.onChange(!this.props.value,e)},t.prototype.render=function(){var e=this,t=this.props,n=t.value,r=t.label,a=t.width,u=t.tooltip,l=t.info,c=t.labelPosition,d=!0===n?s.ICON_CHECK:null;return o.createElement(i.default,{customClass:"checkbox-field",label:r,tooltip:u,info:l,labelPosition:c,width:a},o.createElement("div",{className:"checkbox",onClick:function(t){return e.toggle(t)}},d))},t}(o.PureComponent);t.default=u},function(e,t,n){var r=n(14).Symbol;e.exports=r},function(e,t,n){var r=n(105),a=n(378),o=n(43);e.exports=function(e){return o(e)?r(e):a(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.selectMultipleAssets=t.selectAsset=t.resetSelection=t.deselectAsset=t.selectAll=void 0;t.selectAll=function(){return function(e,t){var n=t().assetList.assets.map((function(e){return e.id}));e({type:a.SELECT_ALL,allIds:n})}};t.deselectAsset=function(e){return{type:a.DESELECT_ASSET,id:e}};t.resetSelection=function(){return{type:a.RESET_SELECTION}};t.selectAsset=function(e){return{type:a.SELECT_ASSET,id:e}};t.selectMultipleAssets=function(e){return function(t,n){for(var o=n(),i=o.selectedAssets,s=o.assetList.assets,u=i[i.length-1],l=r(s,u),c=r(s,e),d=l<c?c:l,p=[],f=l<c?l:c;f<=d;f++){var h=s[f];p.push(h.id)}t({type:a.SELECT_MULTIPLE,assets:p}),window.getSelection().removeAllRanges()}};var r=function(e,t){for(var n=0;n<e.length;n++){if(e[n].id===t)return n}},a={SELECT_ALL:"selectAssets/SELECT_ALL",SELECT_MULTIPLE:"selectAssets/SELECT_MULTIPLE",SELECT_ASSET:"selectedAssets/SELECT_ASSET",DESELECT_ASSET:"selectedAssets/DESELECT_ASSET",RESET_SELECTION:"selectedAssets/RESET_SELECTION"};t.default=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DEFAULT_PADDING=void 0,t.DEFAULT_PADDING=35},function(e,t){e.exports=a},function(e,t,n){var r;!function(a){var o=/^\s+/,i=/\s+$/,s=0,u=a.round,l=a.min,c=a.max,d=a.random;function p(e,t){if(t=t||{},(e=e||"")instanceof p)return e;if(!(this instanceof p))return new p(e,t);var n=function(e){var t={r:0,g:0,b:0},n=1,r=null,s=null,u=null,d=!1,p=!1;"string"==typeof e&&(e=function(e){e=e.replace(o,"").replace(i,"").toLowerCase();var t,n=!1;if(D[e])e=D[e],n=!0;else if("transparent"==e)return{r:0,g:0,b:0,a:0,format:"name"};if(t=W.rgb.exec(e))return{r:t[1],g:t[2],b:t[3]};if(t=W.rgba.exec(e))return{r:t[1],g:t[2],b:t[3],a:t[4]};if(t=W.hsl.exec(e))return{h:t[1],s:t[2],l:t[3]};if(t=W.hsla.exec(e))return{h:t[1],s:t[2],l:t[3],a:t[4]};if(t=W.hsv.exec(e))return{h:t[1],s:t[2],v:t[3]};if(t=W.hsva.exec(e))return{h:t[1],s:t[2],v:t[3],a:t[4]};if(t=W.hex8.exec(e))return{r:P(t[1]),g:P(t[2]),b:P(t[3]),a:R(t[4]),format:n?"name":"hex8"};if(t=W.hex6.exec(e))return{r:P(t[1]),g:P(t[2]),b:P(t[3]),format:n?"name":"hex"};if(t=W.hex4.exec(e))return{r:P(t[1]+""+t[1]),g:P(t[2]+""+t[2]),b:P(t[3]+""+t[3]),a:R(t[4]+""+t[4]),format:n?"name":"hex8"};if(t=W.hex3.exec(e))return{r:P(t[1]+""+t[1]),g:P(t[2]+""+t[2]),b:P(t[3]+""+t[3]),format:n?"name":"hex"};return!1}(e));"object"==typeof e&&(B(e.r)&&B(e.g)&&B(e.b)?(f=e.r,h=e.g,m=e.b,t={r:255*C(f,255),g:255*C(h,255),b:255*C(m,255)},d=!0,p="%"===String(e.r).substr(-1)?"prgb":"rgb"):B(e.h)&&B(e.s)&&B(e.v)?(r=I(e.s),s=I(e.v),t=function(e,t,n){e=6*C(e,360),t=C(t,100),n=C(n,100);var r=a.floor(e),o=e-r,i=n*(1-t),s=n*(1-o*t),u=n*(1-(1-o)*t),l=r%6;return{r:255*[n,s,i,i,u,n][l],g:255*[u,n,n,s,i,i][l],b:255*[i,i,u,n,n,s][l]}}(e.h,r,s),d=!0,p="hsv"):B(e.h)&&B(e.s)&&B(e.l)&&(r=I(e.s),u=I(e.l),t=function(e,t,n){var r,a,o;function i(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}if(e=C(e,360),t=C(t,100),n=C(n,100),0===t)r=a=o=n;else{var s=n<.5?n*(1+t):n+t-n*t,u=2*n-s;r=i(u,s,e+1/3),a=i(u,s,e),o=i(u,s,e-1/3)}return{r:255*r,g:255*a,b:255*o}}(e.h,r,u),d=!0,p="hsl"),e.hasOwnProperty("a")&&(n=e.a));var f,h,m;return n=A(n),{ok:d,format:e.format||p,r:l(255,c(t.r,0)),g:l(255,c(t.g,0)),b:l(255,c(t.b,0)),a:n}}(e);this._originalInput=e,this._r=n.r,this._g=n.g,this._b=n.b,this._a=n.a,this._roundA=u(100*this._a)/100,this._format=t.format||n.format,this._gradientType=t.gradientType,this._r<1&&(this._r=u(this._r)),this._g<1&&(this._g=u(this._g)),this._b<1&&(this._b=u(this._b)),this._ok=n.ok,this._tc_id=s++}function f(e,t,n){e=C(e,255),t=C(t,255),n=C(n,255);var r,a,o=c(e,t,n),i=l(e,t,n),s=(o+i)/2;if(o==i)r=a=0;else{var u=o-i;switch(a=s>.5?u/(2-o-i):u/(o+i),o){case e:r=(t-n)/u+(t<n?6:0);break;case t:r=(n-e)/u+2;break;case n:r=(e-t)/u+4}r/=6}return{h:r,s:a,l:s}}function h(e,t,n){e=C(e,255),t=C(t,255),n=C(n,255);var r,a,o=c(e,t,n),i=l(e,t,n),s=o,u=o-i;if(a=0===o?0:u/o,o==i)r=0;else{switch(o){case e:r=(t-n)/u+(t<n?6:0);break;case t:r=(n-e)/u+2;break;case n:r=(e-t)/u+4}r/=6}return{h:r,s:a,v:s}}function m(e,t,n,r){var a=[H(u(e).toString(16)),H(u(t).toString(16)),H(u(n).toString(16))];return r&&a[0].charAt(0)==a[0].charAt(1)&&a[1].charAt(0)==a[1].charAt(1)&&a[2].charAt(0)==a[2].charAt(1)?a[0].charAt(0)+a[1].charAt(0)+a[2].charAt(0):a.join("")}function _(e,t,n,r){return[H(N(r)),H(u(e).toString(16)),H(u(t).toString(16)),H(u(n).toString(16))].join("")}function y(e,t){t=0===t?0:t||10;var n=p(e).toHsl();return n.s-=t/100,n.s=j(n.s),p(n)}function g(e,t){t=0===t?0:t||10;var n=p(e).toHsl();return n.s+=t/100,n.s=j(n.s),p(n)}function v(e){return p(e).desaturate(100)}function b(e,t){t=0===t?0:t||10;var n=p(e).toHsl();return n.l+=t/100,n.l=j(n.l),p(n)}function w(e,t){t=0===t?0:t||10;var n=p(e).toRgb();return n.r=c(0,l(255,n.r-u(-t/100*255))),n.g=c(0,l(255,n.g-u(-t/100*255))),n.b=c(0,l(255,n.b-u(-t/100*255))),p(n)}function M(e,t){t=0===t?0:t||10;var n=p(e).toHsl();return n.l-=t/100,n.l=j(n.l),p(n)}function L(e,t){var n=p(e).toHsl(),r=(n.h+t)%360;return n.h=r<0?360+r:r,p(n)}function T(e){var t=p(e).toHsl();return t.h=(t.h+180)%360,p(t)}function k(e){var t=p(e).toHsl(),n=t.h;return[p(e),p({h:(n+120)%360,s:t.s,l:t.l}),p({h:(n+240)%360,s:t.s,l:t.l})]}function x(e){var t=p(e).toHsl(),n=t.h;return[p(e),p({h:(n+90)%360,s:t.s,l:t.l}),p({h:(n+180)%360,s:t.s,l:t.l}),p({h:(n+270)%360,s:t.s,l:t.l})]}function E(e){var t=p(e).toHsl(),n=t.h;return[p(e),p({h:(n+72)%360,s:t.s,l:t.l}),p({h:(n+216)%360,s:t.s,l:t.l})]}function S(e,t,n){t=t||6,n=n||30;var r=p(e).toHsl(),a=360/n,o=[p(e)];for(r.h=(r.h-(a*t>>1)+720)%360;--t;)r.h=(r.h+a)%360,o.push(p(r));return o}function O(e,t){t=t||6;for(var n=p(e).toHsv(),r=n.h,a=n.s,o=n.v,i=[],s=1/t;t--;)i.push(p({h:r,s:a,v:o})),o=(o+s)%1;return i}p.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var e=this.toRgb();return(299*e.r+587*e.g+114*e.b)/1e3},getLuminance:function(){var e,t,n,r=this.toRgb();return e=r.r/255,t=r.g/255,n=r.b/255,.2126*(e<=.03928?e/12.92:a.pow((e+.055)/1.055,2.4))+.7152*(t<=.03928?t/12.92:a.pow((t+.055)/1.055,2.4))+.0722*(n<=.03928?n/12.92:a.pow((n+.055)/1.055,2.4))},setAlpha:function(e){return this._a=A(e),this._roundA=u(100*this._a)/100,this},toHsv:function(){var e=h(this._r,this._g,this._b);return{h:360*e.h,s:e.s,v:e.v,a:this._a}},toHsvString:function(){var e=h(this._r,this._g,this._b),t=u(360*e.h),n=u(100*e.s),r=u(100*e.v);return 1==this._a?"hsv("+t+", "+n+"%, "+r+"%)":"hsva("+t+", "+n+"%, "+r+"%, "+this._roundA+")"},toHsl:function(){var e=f(this._r,this._g,this._b);return{h:360*e.h,s:e.s,l:e.l,a:this._a}},toHslString:function(){var e=f(this._r,this._g,this._b),t=u(360*e.h),n=u(100*e.s),r=u(100*e.l);return 1==this._a?"hsl("+t+", "+n+"%, "+r+"%)":"hsla("+t+", "+n+"%, "+r+"%, "+this._roundA+")"},toHex:function(e){return m(this._r,this._g,this._b,e)},toHexString:function(e){return"#"+this.toHex(e)},toHex8:function(e){return function(e,t,n,r,a){var o=[H(u(e).toString(16)),H(u(t).toString(16)),H(u(n).toString(16)),H(N(r))];if(a&&o[0].charAt(0)==o[0].charAt(1)&&o[1].charAt(0)==o[1].charAt(1)&&o[2].charAt(0)==o[2].charAt(1)&&o[3].charAt(0)==o[3].charAt(1))return o[0].charAt(0)+o[1].charAt(0)+o[2].charAt(0)+o[3].charAt(0);return o.join("")}(this._r,this._g,this._b,this._a,e)},toHex8String:function(e){return"#"+this.toHex8(e)},toRgb:function(){return{r:u(this._r),g:u(this._g),b:u(this._b),a:this._a}},toRgbString:function(){return 1==this._a?"rgb("+u(this._r)+", "+u(this._g)+", "+u(this._b)+")":"rgba("+u(this._r)+", "+u(this._g)+", "+u(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:u(100*C(this._r,255))+"%",g:u(100*C(this._g,255))+"%",b:u(100*C(this._b,255))+"%",a:this._a}},toPercentageRgbString:function(){return 1==this._a?"rgb("+u(100*C(this._r,255))+"%, "+u(100*C(this._g,255))+"%, "+u(100*C(this._b,255))+"%)":"rgba("+u(100*C(this._r,255))+"%, "+u(100*C(this._g,255))+"%, "+u(100*C(this._b,255))+"%, "+this._roundA+")"},toName:function(){return 0===this._a?"transparent":!(this._a<1)&&(Y[m(this._r,this._g,this._b,!0)]||!1)},toFilter:function(e){var t="#"+_(this._r,this._g,this._b,this._a),n=t,r=this._gradientType?"GradientType = 1, ":"";if(e){var a=p(e);n="#"+_(a._r,a._g,a._b,a._a)}return"progid:DXImageTransform.Microsoft.gradient("+r+"startColorstr="+t+",endColorstr="+n+")"},toString:function(e){var t=!!e;e=e||this._format;var n=!1,r=this._a<1&&this._a>=0;return t||!r||"hex"!==e&&"hex6"!==e&&"hex3"!==e&&"hex4"!==e&&"hex8"!==e&&"name"!==e?("rgb"===e&&(n=this.toRgbString()),"prgb"===e&&(n=this.toPercentageRgbString()),"hex"!==e&&"hex6"!==e||(n=this.toHexString()),"hex3"===e&&(n=this.toHexString(!0)),"hex4"===e&&(n=this.toHex8String(!0)),"hex8"===e&&(n=this.toHex8String()),"name"===e&&(n=this.toName()),"hsl"===e&&(n=this.toHslString()),"hsv"===e&&(n=this.toHsvString()),n||this.toHexString()):"name"===e&&0===this._a?this.toName():this.toRgbString()},clone:function(){return p(this.toString())},_applyModification:function(e,t){var n=e.apply(null,[this].concat([].slice.call(t)));return this._r=n._r,this._g=n._g,this._b=n._b,this.setAlpha(n._a),this},lighten:function(){return this._applyModification(b,arguments)},brighten:function(){return this._applyModification(w,arguments)},darken:function(){return this._applyModification(M,arguments)},desaturate:function(){return this._applyModification(y,arguments)},saturate:function(){return this._applyModification(g,arguments)},greyscale:function(){return this._applyModification(v,arguments)},spin:function(){return this._applyModification(L,arguments)},_applyCombination:function(e,t){return e.apply(null,[this].concat([].slice.call(t)))},analogous:function(){return this._applyCombination(S,arguments)},complement:function(){return this._applyCombination(T,arguments)},monochromatic:function(){return this._applyCombination(O,arguments)},splitcomplement:function(){return this._applyCombination(E,arguments)},triad:function(){return this._applyCombination(k,arguments)},tetrad:function(){return this._applyCombination(x,arguments)}},p.fromRatio=function(e,t){if("object"==typeof e){var n={};for(var r in e)e.hasOwnProperty(r)&&(n[r]="a"===r?e[r]:I(e[r]));e=n}return p(e,t)},p.equals=function(e,t){return!(!e||!t)&&p(e).toRgbString()==p(t).toRgbString()},p.random=function(){return p.fromRatio({r:d(),g:d(),b:d()})},p.mix=function(e,t,n){n=0===n?0:n||50;var r=p(e).toRgb(),a=p(t).toRgb(),o=n/100;return p({r:(a.r-r.r)*o+r.r,g:(a.g-r.g)*o+r.g,b:(a.b-r.b)*o+r.b,a:(a.a-r.a)*o+r.a})},p.readability=function(e,t){var n=p(e),r=p(t);return(a.max(n.getLuminance(),r.getLuminance())+.05)/(a.min(n.getLuminance(),r.getLuminance())+.05)},p.isReadable=function(e,t,n){var r,a,o=p.readability(e,t);switch(a=!1,(r=function(e){var t,n;t=((e=e||{level:"AA",size:"small"}).level||"AA").toUpperCase(),n=(e.size||"small").toLowerCase(),"AA"!==t&&"AAA"!==t&&(t="AA");"small"!==n&&"large"!==n&&(n="small");return{level:t,size:n}}(n)).level+r.size){case"AAsmall":case"AAAlarge":a=o>=4.5;break;case"AAlarge":a=o>=3;break;case"AAAsmall":a=o>=7}return a},p.mostReadable=function(e,t,n){var r,a,o,i,s=null,u=0;a=(n=n||{}).includeFallbackColors,o=n.level,i=n.size;for(var l=0;l<t.length;l++)(r=p.readability(e,t[l]))>u&&(u=r,s=p(t[l]));return p.isReadable(e,s,{level:o,size:i})||!a?s:(n.includeFallbackColors=!1,p.mostReadable(e,["#fff","#000"],n))};var D=p.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},Y=p.hexNames=function(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[e[n]]=n);return t}(D);function A(e){return e=parseFloat(e),(isNaN(e)||e<0||e>1)&&(e=1),e}function C(e,t){(function(e){return"string"==typeof e&&-1!=e.indexOf(".")&&1===parseFloat(e)})(e)&&(e="100%");var n=function(e){return"string"==typeof e&&-1!=e.indexOf("%")}(e);return e=l(t,c(0,parseFloat(e))),n&&(e=parseInt(e*t,10)/100),a.abs(e-t)<1e-6?1:e%t/parseFloat(t)}function j(e){return l(1,c(0,e))}function P(e){return parseInt(e,16)}function H(e){return 1==e.length?"0"+e:""+e}function I(e){return e<=1&&(e=100*e+"%"),e}function N(e){return a.round(255*parseFloat(e)).toString(16)}function R(e){return P(e)/255}var F,z,U,W=(z="[\\s|\\(]+("+(F="(?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?)")+")[,|\\s]+("+F+")[,|\\s]+("+F+")\\s*\\)?",U="[\\s|\\(]+("+F+")[,|\\s]+("+F+")[,|\\s]+("+F+")[,|\\s]+("+F+")\\s*\\)?",{CSS_UNIT:new RegExp(F),rgb:new RegExp("rgb"+z),rgba:new RegExp("rgba"+U),hsl:new RegExp("hsl"+z),hsla:new RegExp("hsla"+U),hsv:new RegExp("hsv"+z),hsva:new RegExp("hsva"+U),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/});function B(e){return!!W.CSS_UNIT.exec(e)}e.exports?e.exports=p:void 0===(r=function(){return p}.call(t,n,t,e))||(e.exports=r)}(Math)},function(e,t){e.exports=o},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.clearCachedAuth=t.login=t.AUTH_CACHE_KEY=void 0,t.AUTH_CACHE_KEY="imposium_hub_creds";t.login=function(e){try{localStorage.setItem(t.AUTH_CACHE_KEY,JSON.stringify(e))}catch(e){console.warn("Failed to cache auth creds...")}return{type:r.LOGIN,auth:e}};t.clearCachedAuth=function(){try{localStorage.removeItem(t.AUTH_CACHE_KEY)}catch(e){console.warn("Failed to remove cached creds")}return{type:r.CLEAR}};var r={LOGIN:"auth/LOGIN",CLEAR:"auth/CLEAR"};t.default=r},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},o=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0}),t.storyDeleted=t.storyNameMutated=t.orgNameMutated=t.storyAdded=t.clearCachedAccessList=t.cacheAccessData=t.ACCESS_CACHE_KEY=void 0;var i=n(27);t.ACCESS_CACHE_KEY="imposium_access_list";t.cacheAccessData=function(e){return s(e),{type:u.SET,accessData:e}};t.clearCachedAccessList=function(){try{localStorage.removeItem(t.ACCESS_CACHE_KEY)}catch(e){console.warn("Failed to clear access list cache from local storage.")}return{type:u.CLEAR}};t.storyAdded=function(e,t){return function(n,l){var c=l(),d=c.access,p=c.auth.idTokenPayload.exp,f=c.routing.locationBeforeTransitions.query.organization_id,h=r(r({},d),{organizations:d.organizations.map((function(n){return n.id===f?r(r({},n),{stories:o(o([],a(n.stories)),[{id:e,name:t}]).sort((function(e,t){return e.name.localeCompare(t.name)}))}):n}))});i.default.updateSession({stories_hash:i.default.generateStoriesHash(h)},p),s(h),n({type:u.STORY_ADDED,accessData:h})}};t.orgNameMutated=function(e,t){return function(n,a){var o=a(),l=o.access,c=o.auth.idTokenPayload.exp,d=r(r({},l),{organizations:l.organizations.map((function(n){return n.id===e?r(r({},n),{name:t}):n}))});i.default.updateSession({stories_hash:i.default.generateOrgsHash(d)},c),s(d),n({type:u.ORG_NAME_MUTATION,accessData:d})}};t.storyNameMutated=function(e,t){return function(n,a){var o=a(),l=o.access,c=o.auth.idTokenPayload.exp,d=o.routing.locationBeforeTransitions.query.organization_id,p=r(r({},l),{organizations:l.organizations.map((function(n){return n.id===d?r(r({},n),{stories:n.stories.map((function(n){return n.id===e?r(r({},n),{name:t}):n}))}):n}))});i.default.updateSession({stories_hash:i.default.generateOrgsHash(p)},c),s(p),n({type:u.STORY_NAME_MUTATION,accessData:p})}};t.storyDeleted=function(e){return function(t,n){var a=n(),o=a.access,l=a.auth.idTokenPayload.exp,c=a.routing.locationBeforeTransitions.query.organization_id,d=r(r({},o),{organizations:o.organizations.map((function(t){return t.id===c?r(r({},t),{stories:t.stories.filter((function(t){return t.id!==e}))}):t}))});i.default.updateSession({story_id:"",stories_hash:i.default.generateStoriesHash(d)},l),s(d),t({type:u.STORY_DELETED,accessData:d})}};var s=function(e){try{localStorage.setItem(t.ACCESS_CACHE_KEY,JSON.stringify(e))}catch(e){console.warn("Failed to cache access list in local storage.")}},u={SET:"access/SET",CLEAR:"access/CLEAR",STORY_ADDED:"access/STORY_ADDED",STORY_NAME_MUTATION:"access/STORY_NAME_MUTATION",ORG_NAME_MUTATION:"access/ORG_NAME_MUTATION",STORY_DELETED:"access/STORY_DELETED"};t.default=u},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(11),s=function(e){function t(t){var n=e.call(this,t)||this;return n.inputRef=o.createRef(),n}return a(t,e),t.prototype.onChange=function(e){var t=e.target.value;t=""===t?null:parseFloat(t),this.props.onChange(t)},t.prototype.onSelectFocus=function(){},t.prototype.onSelectBlur=function(){},t.prototype.handleLabelDrag=function(e){var t=this.props.value+e;this.props.onChange(t)},t.prototype.render=function(){var e=this,t=this.props,n=t.label,r=t.placeholder,a=t.width,s=t.readOnly,u=t.buttons,l=t.tooltip,c=t.info,d=t.labelPosition,p=t.min,f=t.max,h=this.props.value;return null===h&&(h=""),o.createElement(i.default,{customClass:"number-field",label:n,tooltip:l,buttons:u,info:c,labelPosition:d,width:a},o.createElement("input",{ref:this.inputRef,type:"number",pattern:"/^-?(0|[1-9]d*)(.d+)?$/",placeholder:r,value:h,readOnly:s,min:p,max:f,onFocus:function(){return e.onSelectFocus()},onBlur:function(){return e.onSelectBlur()},onChange:function(t){return e.onChange(t)}}))},t}(o.PureComponent);t.default=s},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,n){var r=n(110),a=n(68);e.exports=function(e){return null!=e&&a(e.length)&&!r(e)}},function(e,t,n){var r=n(386),a=n(387),o=n(388),i=n(389),s=n(390);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=a,u.prototype.get=o,u.prototype.has=i,u.prototype.set=s,e.exports=u},function(e,t,n){var r=n(74);e.exports=function(e,t){for(var n=e.length;n--;)if(r(e[n][0],t))return n;return-1}},function(e,t,n){var r=n(19)(Object,"create");e.exports=r},function(e,t,n){var r=n(408);e.exports=function(e,t){var n=e.__data__;return r(t)?n["string"==typeof t?"string":"hash"]:n.map}},function(e,t,n){var r=n(423),a=n(75),o=n(424),i=n(425),s=n(426),u=n(18),l=n(113),c=l(r),d=l(a),p=l(o),f=l(i),h=l(s),m=u;(r&&"[object DataView]"!=m(new r(new ArrayBuffer(1)))||a&&"[object Map]"!=m(new a)||o&&"[object Promise]"!=m(o.resolve())||i&&"[object Set]"!=m(new i)||s&&"[object WeakMap]"!=m(new s))&&(m=function(e){var t=u(e),n="[object Object]"==t?e.constructor:void 0,r=n?l(n):"";if(r)switch(r){case c:return"[object DataView]";case d:return"[object Map]";case p:return"[object Promise]";case f:return"[object Set]";case h:return"[object WeakMap]"}return t}),e.exports=m},function(e,t,n){var r=n(79);e.exports=function(e){if("string"==typeof e||r(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}},function(e,t,n){var r=n(125),a=n(126);e.exports=function(e,t,n,o){var i=!n;n||(n={});for(var s=-1,u=t.length;++s<u;){var l=t[s],c=o?o(n[l],e[l],l,n,e):void 0;void 0===c&&(c=e[l]),i?a(n,l,c):r(n,l,c)}return n}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(4),o=n(9),i=r.memo((function(e){if("string"!=typeof e.copy)throw new Error("Prop passed to Tag is not string: ");var t=e.colorize?""+o.string2HexCode(e.copy):"",n="function"==typeof e.removeHandler&&r.createElement("div",{className:"remove-tag",onClick:e.removeHandler},a.ICON_TIMES);return r.createElement("div",{key:e.copy,style:{borderLeftColor:t},className:"imposium-tag"},e.copy,n)}));t.default=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.cancelAssetUpload=t.uploadAssets=t.toggleAssignToStory=t.toggleAutoTag=void 0;var r=n(17),a=n(28),o={TOGGLE_AUTO_TAG:"assetUploads/TOGGLE_AUTO_TAG",TOGGLE_ASSIGN_TO_STORY:"assetUploads/TOGGLE_ASSIGN_TO_STORY",ADD_UPLOAD:"assetUploads/ADD_UPLOAD",UPDATE_PERCENT_UPLOADED:"assetUploads/UPDATE_PERCENT_UPLOADED",REMOVE_UPLOAD:"assetUploads/REMOVE_UPLOAD"};t.toggleAutoTag=function(e){return{type:o.TOGGLE_AUTO_TAG,toggle:e}};t.toggleAssignToStory=function(e){return{type:o.TOGGLE_ASSIGN_TO_STORY,toggle:e}};t.uploadAssets=function(e,t,n,s){return function(u,l){for(var c=l().assetUploads,d=c.autoTag,p=c.uploads,f=c.assignToStory,h=0,m=[],_=t.length>5?4:t.length-1,y=t.map((function(e){var t=p.filter((function(t){return t.filename.includes(e.name)})),n=t.length>0?e.name+" ("+t.length+")":e.name,r=d?e.name.substr(0,e.name.lastIndexOf(".")).split("_").join(","):"";return u({type:o.ADD_UPLOAD,uploadMeta:{filename:n,percent:0}}),{file:e,tags:r,filename:n,onUploadProgress:function(e){u({type:o.UPDATE_PERCENT_UPLOADED,percent:Math.floor(100*e.loaded/e.total),filename:n})}}})),g=function(t){var l=y.length,c=f&&n?n:null;e.uploadAsset(c,y[t].tags,y[t].file,y[t].onUploadProgress,y[t].filename).then((function(a){m.push((s&&s(a[0]),{footageId:a[0].id,jobId:a[0].job_id,filename:y[t].filename,onProcessed:function(){var t=m.filter((function(e){return e.jobId===a[0].job_id}))[0].filename;u({type:o.REMOVE_UPLOAD,filename:t}),r.doAssetTableHydration(e,n)}})),h!==l-1?g(h+=1):(m=m.filter((function(t,a){var i="string"==typeof t.jobId;return i||(u({type:o.REMOVE_UPLOAD,filename:t.filename}),r.doAssetTableHydration(e,n)),i}))).length>0&&i(e,m,-1)})).catch((function(e){a.default.isCancel(e)&&h!==l-1&&g(h+=1)}))},v=0;v<=_;v++)g(v),h=v}};var i=function(e,t,n){n=window.setTimeout((function(){var r=t.map((function(t){return e.getJob(t.jobId)}));Promise.all(r).then((function(r){var a;clearTimeout(n),r.forEach((function(e){"processing"!==e.status&&"completed"!==e.status||(a=t.find((function(t){return t.jobId===e.id})))&&(a.onProcessed(),t=t.filter((function(t){return t.jobId!==e.id})))})),t.length>0&&i(e,t,n)})).catch((function(e){console.error("Failed to poll for processing jobs:",e)}))}),5e3)};t.cancelAssetUpload=function(e,t){return function(n){t.cancelUploadAssets(e),n({type:o.REMOVE_UPLOAD,filename:e})}},t.default=o},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.getNewCompositionLayer=t.VARIABLE_TYPES=t.TEXT_SIZE_OPTIONS=t.DEFAULT_FONT=t.FILL_MODES=t.STADARD_FONTS=t.FONT_TYPE_OPTIONS=t.FONT_TYPES=void 0;var a=n(9);t.FONT_TYPES={STANDARD:"standard",CUSTOM:"custom"},t.FONT_TYPE_OPTIONS=[{label:"Standard",value:t.FONT_TYPES.STANDARD},{label:"Custom",value:t.FONT_TYPES.CUSTOM}],t.STADARD_FONTS=["Arial","Courier New","Georgia","Impact","Times New Roman","Trebuchet MS","Verdana"],t.FILL_MODES={FIT:"fit",FILL:"fill",STRETCH:"stretch"},t.DEFAULT_FONT="Arial",t.TEXT_SIZE_OPTIONS=[{label:"6px",value:6},{label:"8px",value:8},{label:"9px",value:9},{label:"10px",value:10},{label:"11px",value:11},{label:"12px",value:12},{label:"14px",value:14},{label:"16px",value:16},{label:"18px",value:18},{label:"24px",value:24},{label:"30px",value:30},{label:"36px",value:36},{label:"48px",value:48},{label:"60px",value:60},{label:"72px",value:72}],t.VARIABLE_TYPES={TEXT:"text",NUMBER:"number",BOOLEAN:"boolean",ENUM:"enum",IMAGE:"image",VIDEO:"video",AUDIO:"audio"};t.getNewCompositionLayer=function(){var e=r({},o);return e.id=a.generateUUID(),e};var o={id:null,x:0,y:0,width:200,height:100,rotation:0,name:"New Layer",content:"",color:"#000000",background_color:"transparent",font_size:24,font_type:"standard",font_weight:400,font:t.DEFAULT_FONT,custom_font_id:null,custom_font_url:null,letter_spacing:null,word_spacing:null,line_height:null,horizontal_alignment:"center",vertical_alignment:"center",text_wrap:!0,text_fit:!0}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e},s=this&&this.__values||function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(t,"__esModule",{value:!0}),t.BigLink=t.WizardError=t.TabHeader=t.TabContent=t.BigButton=void 0;var u=n(0),l=n(5),c=n(22),d=n(16),p=n(4),f=n(7),h=n(25),m=n(508),_=n(509),y=n(137),g=n(513),v=n(273),b=n(10),w=n(55),M=n(8),L=function(e){function n(t){var n=e.call(this,t)||this;return n.onSelectOption=function(e){n.props.publishData.publishing&&alert("WARNING: Your publish is still in progress, your changes will not be present in the rendered videos until the publish is complete"),n.setState({screenIndex:e,done:!1})},n.onCompositionChange=function(e){n.setState({selectedComposition:e})},n.onCredentialsChange=function(e){n.setState({accessKey:e})},n.nextClickHandler=function(){n.setState({nextStep:!0}),7===n.state.screenIndex&&n.emailWorkflow.current.getWrappedInstance().proceedWithExport()},n.onDoneHandler=function(){n.setState({done:!0,error:!1})},n.onErrorHandler=function(){n.setState({error:!n.state.error})},n.onNextHandler=function(e){n.setState({next:e})},n.state={compositions:[],selectedComposition:null,newPublish:!0,status:"",queryRunning:!0,publishMessage:"",screenIndex:0,accessKey:null,credentials:[],done:!1,error:!1,next:!1,nextStep:!1},n.emailWorkflow=u.createRef(),n.hiddenFileInputRef=u.createRef(),n}return a(n,e),n.prototype.componentDidMount=function(){var e=this,t=this.props,n=t.story,r=t.api,a=t.handleError,s=t.activeComposition;r.getAssets({type:h.ASSET_TYPES.VIDEO_COMPOSITION},n.id).then((function(t){var n=t.assets[0]?t.assets[0].id:null,r=s||n;e.setState({compositions:t.assets,selectedComposition:r})})).catch((function(e){a(f.integration.errorPullingComps)})),r.getAccssCredentials().then((function(t){0===t.length?r.createAccessCredentials("default").then((function(t){var n=e.state.credentials,r=i(i([],o(n)),[t]);e.setState({credentials:r,accessKey:t[0].access_key_id})})):e.setState({credentials:t,accessKey:t[0].access_key_id})})).catch((function(e){a(f.integration.errorGettingCreds)}))},n.prototype.checkStatus=function(){var e=this,t=this.props,n=t.project.storyId,r=t.api,a=t.handleError;n&&this.setState({queryRunning:!0,newPublish:!1,status:""},(function(){r.getStoryStatus(n).then((function(t){t?t.publishing&&e.setState({status:f.header.publishing},(function(){e.pollStatus(t.job_id)})):e.setState({queryRunning:!1,status:f.header.working})})).catch((function(t){e.setState({queryRunning:!1},(function(){404===t.response.status?e.setState({queryRunning:!1,status:f.header.working}):(a(f.header.statusError),e.setState({status:""}))}))}))}))},n.prototype.pollStatus=function(e){var t=this,n=this.props,r=n.api,a=n.handleError;r.pollJob(e).then((function(){t.checkStatus()})).catch((function(){a(f.header.publishPollError),t.setState({status:""})}))},n.prototype.handlePublish=function(){var e=this.props,t=e.story.id,n=e.api,r=e.handleError;this.props.publishVersion(n,t).catch((function(e){r(e)})),this.setState({screenIndex:1})},n.prototype.renderLowerButtons=function(){var e=this,t=this.state,n=t.screenIndex,r=t.done,a=t.error,o=t.next,i=this.props.publishing,s=[];if(0===n)s.push(u.createElement(l.default,{tooltip:f.publish.btnPublish,size:"large",disabled:i,key:"btn-publish",onClick:function(){return e.handlePublish()},color:"primary"},f.publish.btnPublish)),s.push(u.createElement(l.default,{tooltip:f.publish.btnSkip,key:"btn-skip",size:"large",onClick:function(){return e.setState({screenIndex:1})},color:"primary"},f.publish.btnSkip));else{(r||a)&&s.push(u.createElement(l.default,{tooltip:a?f.publish.btnCancel:f.publish.btnFinished,size:"large",key:"btn-finish",onClick:function(){return e.props.onClose()},color:"primary"},a?f.publish.btnCancel:f.publish.btnFinished));var c=1===n?0:1;s.push(u.createElement(l.default,{tooltip:f.publish.btnBack,size:"large",key:"btn-back",onClick:function(){return e.setState({screenIndex:c,next:!1,nextStep:!1,error:!1,done:!1})},color:"primary"},f.publish.btnBack)),a&&s.push(u.createElement(l.default,{tooltip:f.publish.btnNext,size:"large",key:"btn-next",color:"primary",disabled:!o,onClick:function(){return e.nextClickHandler()}},f.publish.btnNext))}return s},n.prototype.renderPublish=function(){return u.createElement("div",null,u.createElement("h2",null,f.publish.publishStepTitle),u.createElement(d.default,null),u.createElement("p",null,f.publish.publishStepDesc))},n.prototype.renderDistributionOptions=function(){var e,n,r,a,o=this,i=[],l=[],h=this.state,m=h.compositions,_=h.selectedComposition,y=h.credentials,g=h.accessKey;try{for(var v=s(m),b=v.next();!b.done;b=v.next()){var w=b.value;i.push({value:w.id,label:w.name})}}catch(t){e={error:t}}finally{try{b&&!b.done&&(n=v.return)&&n.call(v)}finally{if(e)throw e.error}}try{for(var M=s(y),L=M.next();!L.done;L=M.next()){var T=L.value;l.push({value:T.access_key_id,label:T.name})}}catch(e){r={error:e}}finally{try{L&&!L.done&&(a=M.return)&&a.call(M)}finally{if(r)throw r.error}}var k=[{label:u.createElement("span",null,p.ICON_GLOBE," ",f.publish.btnWebsite),onClick:function(e){return o.onSelectOption(2)}},{label:u.createElement("span",null,p.ICON_EMAIL," ",f.publish.btnEmail),onClick:function(e){return o.onSelectOption(3)}},{label:u.createElement("span",null,p.ICON_HUBSPOT," ",f.publish.btnHubspot),onClick:function(e){return o.onSelectOption(5)}},{label:u.createElement("span",null,p.ICON_PROJECT_DIAGRAM," ",f.publish.btnAPI),onClick:function(e){return o.onSelectOption(6)}},{label:u.createElement("span",null,p.ICON_DOWNLOAD," ",f.publish.btnExport),onClick:function(e){return o.onSelectOption(7)}}];return u.createElement("div",null,u.createElement("h2",null,f.publish.distributeStepTitle),u.createElement(d.default,null),u.createElement("p",null,f.publish.distributeStepDesc),u.createElement(d.default,null),!this.state.selectedComposition&&u.createElement("p",{className:"text-danger"},f.publish.noCompErrorDesc),u.createElement("div",{style:{marginTop:"10px"}},u.createElement(c.default,{label:f.project.compName,value:_,onChange:this.onCompositionChange,options:i,tooltip:f.project.tooltipCompId}),u.createElement(c.default,{label:f.publish.accessKey,value:g,onChange:this.onCredentialsChange,options:l,tooltip:f.publish.tooltipAccessKey}),u.createElement("div",{className:"link-wrapper"},null==k?void 0:k.map((function(e,n){return u.createElement(t.BigButton,{key:n,disabled:!o.state.selectedComposition,label:e.label,onClick:e.onClick})})))))},n.prototype.render=function(){var e,t=this.props,n=t.story,r=t.project,a=t.api,o=t.handleError,i=t.createFreshBatch,s=t.getBatches,l=t.getBatchExport,c=t.importBatchFromCsv,p=t.handleNotification,h=t.renderBatch,b=t.batchJobs,w=this.state,M=w.screenIndex,L=w.status,T=w.selectedComposition,k=w.compositions,x=w.accessKey,E=w.error,S=w.nextStep,O=(null===(e=k.find((function(e){return e.id===T})))||void 0===e?void 0:e.name)||"",D=n?n.acts[r.actId].inventory:{};return u.createElement("div",{className:"publish-wizard"},u.createElement("div",{className:"publish-wizard-header"},f.publish.publishTitle,u.createElement(v.default,{api:a})),u.createElement("div",null,0===M&&this.renderPublish(),1===M&&this.renderDistributionOptions(),2===M&&u.createElement(y.default,{story:n,compositionId:T,accessKey:x}),(3===M||7===M)&&u.createElement(g.default,{isExport:7===M,api:a,story:n,variables:D,onDone:this.onDoneHandler,onError:this.onErrorHandler,onNext:this.onNextHandler,error:E,status:L,renderBatch:h,batchJobs:b,accessKey:x,compositionId:T,compositionName:O,handleError:o,createFreshBatch:i,getBatches:s,getBatchExport:l,importBatchFromCsv:c,next:S,ref:this.emailWorkflow}),5===M&&u.createElement(m.default,{handleError:o,status:L,accessKey:x,story:n,handleNotification:p,compositionId:T}),6===M&&u.createElement(_.default,null),u.createElement("br",null),u.createElement(d.default,null),u.createElement("div",{className:"lower-buttons"},this.renderLowerButtons())))},n}(u.PureComponent);t.default=M.connect((function(e){return{publishData:e.publish}}),(function(e){return b.bindActionCreators({publishVersion:w.publishVersion},e)}))(L);t.BigButton=function(e){return u.createElement("div",{className:"big-link "+(e.disabled&&"disabled"),onClick:function(){return e.onClick()},style:e.style},u.createElement("h1",null,e.label))};t.TabContent=function(e){var t=e.children;return u.createElement("div",{className:"tab-content"},u.createElement("div",{className:"settings-tab"},u.createElement("div",{className:"integration-details"},t)))};t.TabHeader=function(e){var t=e.className,n=e.title;return u.createElement("div",{className:"tab-header"},u.createElement("div",{className:t||"tab-header-option active"},n))};t.WizardError=function(e){var t=e.description,n=e.title;return u.createElement("div",{className:"publish-wizard-error"},u.createElement("h3",null,n),u.createElement("p",null,t))};t.BigLink=function(e){return u.createElement("a",{className:"big-link",target:"_blank",href:e.link},u.createElement("h1",null,e.label))}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.clearStoryPublishStatus=t.publishVersion=t.cancelPublish=t.getStoryPublishStatus=void 0;var r=n(7),a={CLEAR_PUBLISH_STATUS:"publish/CLEAR_PUBLISH_STATUS",UPDATE_PUBLISH_STATUS:"publish/UPDATE_PUBLISH_STATUS"};t.getStoryPublishStatus=function(e,n){return function(o){return new Promise((function(i,s){e.getStoryStatus(n).then((function(i){if(i&&(o({type:a.UPDATE_PUBLISH_STATUS,data:i}),i.publishing)){var u=i.job_id;e.pollJob(u).then((function(){return o(t.getStoryPublishStatus(e,n))})).catch((function(e){console.error(e),s(r.header.publishPollError)}))}})).catch((function(e){var t;404!==(null===(t=null==e?void 0:e.response)||void 0===t?void 0:t.status)&&(console.error(e),s(r.header.publishPollError))}))}))}};t.cancelPublish=function(e,n){return function(r){return new Promise((function(a,o){e.cancelPublish(n).then((function(){e.cancelJobPolling().then((function(){r(t.getStoryPublishStatus(e,n))})).catch((function(e){throw o(e),e}))})).catch((function(e){throw o(e),e}))}))}};t.publishVersion=function(e,n){return function(a){return new Promise((function(o,i){e.runPublish(n,"").then((function(r){a(t.getStoryPublishStatus(e,n))})).catch((function(){i(r.header.publishJobError)}))}))}};t.clearStoryPublishStatus=function(e){return function(t){e.cancelJobPolling(),t({type:a.CLEAR_PUBLISH_STATUS})}},t.default=a},function(e,t,n){"use strict";(function(e){var n="object"==typeof e&&e&&e.Object===Object&&e;t.a=n}).call(this,n(38))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=[],a="M224 256A128 128 0 1 0 96 128a128 128 0 0 0 128 128zm96 64a63.08 63.08 0 0 1 8.1-30.5c-4.8-.5-9.5-1.5-14.5-1.5h-16.7a174.08 174.08 0 0 1-145.8 0h-16.7A134.43 134.43 0 0 0 0 422.4V464a48 48 0 0 0 48 48h280.9a63.54 63.54 0 0 1-8.9-32zm288-32h-32v-80a80 80 0 0 0-160 0v80h-32a32 32 0 0 0-32 32v160a32 32 0 0 0 32 32h224a32 32 0 0 0 32-32V320a32 32 0 0 0-32-32zM496 432a32 32 0 1 1 32-32 32 32 0 0 1-32 32zm32-144h-64v-80a32 32 0 0 1 64 0z";t.definition={prefix:"fas",iconName:"user-lock",icon:[640,512,r,"f502",a]},t.faUserLock=t.definition,t.prefix="fas",t.iconName="user-lock",t.width=640,t.height=512,t.ligatures=r,t.unicode="f502",t.svgPathData=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=[],a="M569.517 440.013C587.975 472.007 564.806 512 527.94 512H48.054c-36.937 0-59.999-40.055-41.577-71.987L246.423 23.985c18.467-32.009 64.72-31.951 83.154 0l239.94 416.028zM288 354c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z";t.definition={prefix:"fas",iconName:"exclamation-triangle",icon:[576,512,r,"f071",a]},t.faExclamationTriangle=t.definition,t.prefix="fas",t.iconName="exclamation-triangle",t.width=576,t.height=512,t.ligatures=r,t.unicode="f071",t.svgPathData=a},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=function(e){function t(n){var r=e.call(this,n)||this;return r.resizeHandler=function(){return r.onResize()},r.clickHandler=function(e){return r.detectOutsideClick(e)},r.escHandler=function(e){return r.onEsc(e)},r.dropdownRef=null,r.onResize=function(){var e=r.props.toggleRef;if(void 0!==e){var t=e.current.getBoundingClientRect(),n=t.top,a=t.left,o=t.bottom,i=t.right;r.setState({offset:{top:n,left:a,bottom:o,right:i}})}},r.cancelRender=function(e){void 0===e&&(e=!1);var t=r.props.onOutsideClick;window.removeEventListener("resize",r.resizeHandler),window.removeEventListener("mousedown",r.clickHandler),window.addEventListener("keydown",r.onEsc),r.setState({build:!1,offset:{}}),e&&t()},r.onEsc=function(e){e.keyCode===t.ESC_CODE&&r.cancelRender(!0)},r.detectOutsideClick=function(e){var t=r.props.toggleRef,n=e.target,a=!(!r.dropdownRef.current||!r.dropdownRef.current.contains(n)),o=!!(t&&t.current&&t.current.contains(n));a||o||r.cancelRender(!0)},r.state={build:!1,offset:{}},r.dropdownRef=o.createRef(),r}return a(t,e),t.prototype.componentDidUpdate=function(e){var t=this;this.props.show&&!e.show&&(this.onResize(),this.setState({build:!0},(function(){window.addEventListener("resize",t.resizeHandler),window.addEventListener("mousedown",t.clickHandler),window.addEventListener("keydown",t.onEsc)}))),!this.props.show&&e.show&&this.cancelRender()},t.prototype.render=function(){var e=this.state,t=e.build,n=e.offset,r=this.props,a=r.show,i=r.position,s=r.children,u={position:r.fixed?"fixed":"absolute",transform:t?"scaleY(1)":"scaleY(0)",opacity:t?"1":"0"};if(!a)return null;if(n){var l=document.documentElement.clientWidth,c=(n.top,n.left),d=n.bottom,p=n.right;switch(i){case"topleft":case"topright":case"bottomleft":u.top=d+5+"px",u.left=c+"px",u.transformOrigin="top left";break;case"bottomright":u.top=d+5+"px",u.right=l-p+"px",u.transformOrigin="top right"}}return o.createElement("div",{className:"imposium-dropdown",style:u,ref:this.dropdownRef},s)},t.ESC_CODE=27,t}(o.PureComponent);t.default=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.renderTooltip=t.renderTooltipProps=void 0;var r=n(0),a=n(35),o=n(353);t.renderTooltipProps=function(e,t){return t?{"data-tip":"object"==typeof t?t.content:t,"data-for":e}:{}};t.renderTooltip=function(e,t){var n=document.getElementById("tooltips");if(t&&n){var i="light",s="top";"object"==typeof t&&(i=t.theme?t.theme:"light",s=t.position?t.position:"top");var u=r.createElement(o,{place:s,offset:{top:0,right:0,bottom:0,left:0},id:e,className:"imposium-button-tooltip-"+i,delayShow:1e3,effect:"solid"});return a.createPortal(u,n)}return null}},function(e,t){e.exports=i},function(e,t){e.exports=s},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(11),u=n(60),l=function(e){function t(t){var n=e.call(this,t)||this;return n.clickCounter=0,n.handleMultipleClicks=function(e,t){n.clickCounter++,1===n.clickCounter&&(n.clickTimeout=window.setTimeout((function(){n.clickCounter=0,e()}),300)),2===n.clickCounter&&(clearTimeout(n.clickTimeout),n.clickCounter=0,t())},n.render=function(){var e=n.props,t=e.value,r=e.label,a=e.options,l=e.width,c=e.tooltip,d=e.info,p=e.labelPosition,f={width:100/a.length+"%"};return i.createElement(s.default,{customClass:"button-group-field",label:r,tooltip:c,info:d,labelPosition:p,width:l},i.createElement("div",{className:"button-group"},a.map((function(e,r){var a=e.value,s=e.label,l=e.icon?e.icon:null,c=a+"-"+r,d=a===t,p=d?"active":"",h=d?null:function(){n.props.onChange(a)};return i.createElement("div",o({key:"option-"+a,style:f,className:"button-group-option "+p},u.renderTooltipProps(c,e.tooltip),{onClick:"function"==typeof e.onDoubleClick?function(){return n.handleMultipleClicks(h,e.onDoubleClick)}:h}),l||s,u.renderTooltip(c,e.tooltip))}))))},n}return a(t,e),t}(i.PureComponent);t.default=l},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(0),u=n(5),l=n(11),c=n(4),d=function(e){function t(t){var n=e.call(this,t)||this;return n.state={internalValue:t.value,editing:!1},n.evtHandlers={toggleEditing:function(e){return n.toggleEditing(e)},copyToClipboard:function(e){return n.copyToClipboard(e)}},n.inputRef=s.createRef(),n}return a(t,e),t.prototype.blur=function(e){this.props.onBlur&&this.props.onBlur(e)},t.prototype.copyToClipboard=function(e){var t=this.props,n=t.onNotification,r=t.onError;navigator.clipboard.writeText(this.props.value).then((function(){n&&n("Copied to clipboard!")}),(function(){r&&r("Error copying to clipboard.")}))},t.prototype.focus=function(e){this.props.onFocus&&this.props.onFocus(e)},t.prototype.getValue=function(){var e=this.props,t=e.controlled,n=e.value,r=this.state.internalValue;return t?r:n},t.prototype.onChange=function(e){this.props.controlled?this.setState({internalValue:e.target.value}):this.props.onChange(e.target.value)},t.prototype.renderButtons=function(){var e=this.props,t=e.controlled,n=(e.readOnly,e.buttons),r=e.showCopy,a=this.state.editing,l=n?i([],o(n)):[];if(t){var d=a?c.ICON_CHECK:c.ICON_EDIT;l.push(s.createElement(u.default,{key:"btn-edit",style:"subtle",color:"secondary",onClick:this.evtHandlers.toggleEditing},d))}return r&&l.push(s.createElement(u.default,{key:"btn-copy",style:"subtle",tooltip:"Copy to Clipboard",color:"primary",onClick:this.evtHandlers.copyToClipboard},c.ICON_CLIPBOARD)),l},t.prototype.toggleEditing=function(e){var t=this,n=this.state,r=n.editing,a=n.internalValue,o=this.props.value;r?this.setState({editing:!1},(function(){a!==o&&t.props.onSubmit(t.state.internalValue)})):this.setState({editing:!0},(function(){var e=t.inputRef.current;e&&e.focus()}))},t.prototype.componentDidUpdate=function(e){this.props.controlled&&e.value!==this.props.value&&this.setState({internalValue:this.props.value})},t.prototype.render=function(){var e=this,t=this.props,n=t.label,r=t.placeholder,a=t.controlled,o=t.disabled,i=t.readOnly,u=t.width,c=t.tooltip,d=t.info,p=t.labelPosition,f=this.state.editing,h=a&&!f||o;return s.createElement(l.default,{customClass:"text-area-field",label:n,tooltip:c,buttons:this.renderButtons(),info:d,labelPosition:p,width:u},s.createElement("textarea",{placeholder:r,value:this.getValue(),disabled:h,readOnly:i,ref:this.inputRef,onChange:function(t){return e.onChange(t)},onFocus:function(t){return e.focus(t)},onBlur:function(t){return e.blur(t)}}))},t}(s.PureComponent);t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(11),s=n(531),u=function(e){function t(t){var n=e.call(this,t)||this;return n.transparentBg='url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAMUlEQVQ4T2NkYGAQYcAP3uCTZhw1gGGYhAGBZIA/nYDCgBDAm9BGDWAAJyRCgLaBCAAgXwixzAS0pgAAAABJRU5ErkJggg==") left center',n.state={pickerOpen:!1},n.picker=o.createRef(),n.clickOutsideHandler=function(e){return n.handleClickOutside(e)},n}return a(t,e),t.prototype.togglePicker=function(e){var t=this;e.preventDefault(),e.stopPropagation();var n=!this.state.pickerOpen;this.setState({pickerOpen:n},(function(){t.state.pickerOpen?document.addEventListener("click",t.clickOutsideHandler):document.removeEventListener("click",t.clickOutsideHandler)}))},t.prototype.handleClickOutside=function(e){var t=e.target,n=this.picker.current;do{if(t===n)return;t=t.parentNode}while(t);document.removeEventListener("click",this.clickOutsideHandler),this.setState({pickerOpen:!1})},t.prototype.handleChangeComplete=function(e,t){return this.props.onChange(e)},t.prototype.render=function(){var e,t=this,n=this.props,r=n.label,a=(n.placeholder,n.width),u=(n.readOnly,n.buttons),l=n.tooltip,c=n.value,d=n.enableAlpha,p=n.presetColors,f=n.info,h=n.labelPosition,m=!d,_=n.pickerPosition||"left",y=this.state.pickerOpen?o.createElement(s.SketchPicker,{color:c,disableAlpha:m,presetColors:p,onChangeComplete:function(e,n){return t.handleChangeComplete(e,n)}}):null;return e="transparent"===c?{background:this.transparentBg,border:"1px solid #1d1d1d",boxSizing:"border-box"}:{backgroundColor:c},o.createElement(i.default,{customClass:"color-field",label:r,tooltip:l,buttons:u,info:f,labelPosition:h,width:a},o.createElement("div",{className:"swatch",style:e,onClick:function(e){return t.togglePicker(e)}}),o.createElement("div",{className:"picker picker-"+_,ref:this.picker},y))},t}(o.PureComponent);t.default=u},function(e,t,n){var r=n(104),a=n(380);e.exports=function(e,t){return e&&r(e,a(t))}},function(e,t,n){(function(e){var r=n(14),a=n(376),o=t&&!t.nodeType&&t,i=o&&"object"==typeof e&&e&&!e.nodeType&&e,s=i&&i.exports===o?r.Buffer:void 0,u=(s?s.isBuffer:void 0)||a;e.exports=u}).call(this,n(42)(e))},function(e,t){e.exports=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}},function(e,t){e.exports=function(e){return function(t){return e(t)}}},function(e,t,n){(function(e){var r=n(103),a=t&&!t.nodeType&&t,o=a&&"object"==typeof e&&e&&!e.nodeType&&e,i=o&&o.exports===a&&r.process,s=function(){try{var e=o&&o.require&&o.require("util").types;return e||i&&i.binding&&i.binding("util")}catch(e){}}();e.exports=s}).call(this,n(42)(e))},function(e,t){var n=Object.prototype;e.exports=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||n)}},function(e,t,n){var r=n(109)(Object.getPrototypeOf,Object);e.exports=r},function(e,t,n){var r=n(44),a=n(391),o=n(392),i=n(393),s=n(394),u=n(395);function l(e){var t=this.__data__=new r(e);this.size=t.size}l.prototype.clear=a,l.prototype.delete=o,l.prototype.get=i,l.prototype.has=s,l.prototype.set=u,e.exports=l},function(e,t){e.exports=function(e,t){return e===t||e!=e&&t!=t}},function(e,t,n){var r=n(19)(n(14),"Map");e.exports=r},function(e,t,n){var r=n(400),a=n(407),o=n(409),i=n(410),s=n(411);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=a,u.prototype.get=o,u.prototype.has=i,u.prototype.set=s,e.exports=u},function(e,t,n){var r=n(422),a=n(120),o=Object.prototype.propertyIsEnumerable,i=Object.getOwnPropertySymbols,s=i?function(e){return null==e?[]:(e=Object(e),r(i(e),(function(t){return o.call(e,t)})))}:a;e.exports=s},function(e,t,n){var r=n(12),a=n(79),o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,i=/^\w*$/;e.exports=function(e,t){if(r(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!a(e))||(i.test(e)||!o.test(e)||null!=t&&e in Object(t))}},function(e,t,n){var r=n(18),a=n(15);e.exports=function(e){return"symbol"==typeof e||a(e)&&"[object Symbol]"==r(e)}},function(e,t,n){var r=n(105),a=n(451),o=n(43);e.exports=function(e){return o(e)?r(e,!0):a(e)}},function(e,t,n){var r=n(116);e.exports=function(e){var t=new e.constructor(e.byteLength);return new r(t).set(new r(e)),t}},function(e,t){e.exports=function(e){if(!e.webpackPolyfill){var t=Object.create(e);t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),Object.defineProperty(t,"exports",{enumerable:!0}),t.webpackPolyfill=1}return t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.addAssetTagToList=t.getAssetTagList=void 0;var r={GET:"assetTags/GET",ADD:"assetTags/ADD"};t.getAssetTagList=function(e,t){return function(n){return new Promise((function(a,o){e.getAssetTags(t).then((function(e){n({type:r.GET,assetTags:e}),a()})).catch((function(e){console.error("Failed to get tag list",e),o()}))}))}};t.addAssetTagToList=function(e){return{type:r.ADD,freshTags:e}},t.default=r},function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i};Object.defineProperty(t,"__esModule",{value:!0});var a=n(0),o=n(478),i=n(61);t.default=function(e){var t=r(i.useDrop({accept:[o.NativeTypes.FILE],drop:function(t,n){e.onDrop&&e.onDrop(e,n)},collect:function(e){return{isOver:e.isOver,canDrop:e.canDrop}}}),2),n=t[0],s=(n.canDrop,n.isOver,t[1]);return a.createElement("div",{className:e.className||"",ref:e.disable?void 0:s},e.children)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(25),o=n(7),i=n(4),s=r.memo((function(e){var t={color:a.ASSET_COLORS[e.type]};switch(e.type){case"filter":return r.createElement("span",null,i.ICON_FILTER);case"all":return r.createElement("span",{title:o.assets.iconTypes.all},i.ICON_TIMES);case a.ASSET_TYPES.VIDEO:return r.createElement("span",{title:o.assets.iconTypes.video,style:t},i.ICON_VIDEO);case a.ASSET_TYPES.AUDIO:return r.createElement("span",{title:o.assets.iconTypes.audio,style:t},i.ICON_AUDIO_TYPE);case a.ASSET_TYPES.IMAGE:return r.createElement("span",{title:o.assets.iconTypes.image,style:t},i.ICON_IMAGE);case a.ASSET_TYPES.IMAGE_SEQUENCE:return r.createElement("span",{title:o.assets.iconTypes.image_sequence,style:t},i.ICON_IMAGE_SEQ_TYPE);case a.ASSET_TYPES.TEMPLATE:return r.createElement("span",{title:o.assets.iconTypes.template,style:t},i.ICON_FILE_ARCHIVE);case a.ASSET_TYPES.VIDEO_COMPOSITION:return r.createElement("span",{title:o.assets.iconTypes.video_composition,style:t},i.ICON_LAYER_GROUP);case a.ASSET_TYPES.LUT:return r.createElement("span",{title:o.assets.iconTypes.lut},i.ICON_CUBE);case a.ASSET_TYPES.FONT:return r.createElement("span",{title:o.assets.iconTypes.font},i.ICON_FONT);case a.ASSET_TYPES.STATIC_COMPOSITION:return r.createElement("span",{title:o.assets.iconTypes.static_composition},i.ICON_FILE_CODE);default:return null}}));t.default=s},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(25),s=n(53),u=n(9),l=function(e){function t(t){var n=e.call(this,t)||this;return n.state={fontError:!1,fontLoaded:!1},n.innerTextRef=o.createRef(),n}return a(t,e),t.prototype.componentDidMount=function(){this.loadFont()},t.prototype.componentDidUpdate=function(e){var t=this.state.fontLoaded,n=this.props.options,r=n.font,a=n.custom_font_id,o=n.content;e.options.font===r&&e.options.custom_font_id===a||this.loadFont(),e.options.content!==o&&t&&this.fitText()},t.prototype.fitElement=function(e,t,n){for(var r=window.getComputedStyle(e,null),a=parseFloat(r.getPropertyValue("font-size")),o=parseFloat(r.getPropertyValue("letter-spacing")),i=parseFloat(r.getPropertyValue("line-height")),s=parseFloat(r.getPropertyValue("word-spacing")),u=o/a,l=i/a,c=s/a,d=e.offsetWidth,p=e.offsetHeight;d>t||p>n;)a--,o=Math.round(a*u),i=Math.round(a*l),s=Math.round(a*c),e.style.fontSize=a+"px",e.style.letterSpacing=o+"px",e.style.wordSpacing=s+"px",e.style.lineHeight=i+"px",d=e.offsetWidth,p=e.offsetHeight},t.prototype.loadFont=function(){var e=this,t=this.props.options,n=t.font,r=t.font_size,a=t.font_type,o=t.custom_font_url;if(a===s.FONT_TYPES.CUSTOM&&r&&o){var l=u.s3Url(o,i.ASSET_DISTRO,i.ASSET_ORIGIN),c=!1;try{c=document.fonts.check(r+"px "+n)}catch(e){this.errorLoadingFont()}c?this.fontReady():this.setState({fontLoaded:!1},(function(){var t=new FontFace(n,"url("+l+")",{style:"normal",weight:"normal"});t.load().then((function(n){document.fonts.add(t),e.fontReady()})).catch((function(t){e.errorLoadingFont()}))}))}else a===s.FONT_TYPES.STANDARD&&this.fontReady()},t.prototype.formatContent=function(){var e=this.props,t=e.options.content,n=e.inventory,r=t||"";if(n)for(var a in n)if(n.hasOwnProperty(a)){var i=new RegExp("{{"+a+"}}","g"),s=n[a];s&&(s=s.toString(),r=r.replace(i,s))}for(var u=r.split("\n"),l=[],c=0;c<u.length;c++)l.push(o.createElement("span",{key:"s-"+c},u[c])),u[c+1]&&l.push(o.createElement("br",{key:"b-"+c}));return l},t.prototype.fitText=function(){if(this.props.options.text_fit){var e=this.innerTextRef.current;e&&this.fitElement(e,this.props.options.width,this.props.options.height)}},t.prototype.errorLoadingFont=function(){var e=this;this.setState({fontError:!0},(function(){e.fontReady()}))},t.prototype.fontReady=function(){var e=this;this.setState({fontLoaded:!0},(function(){e.fitText(),e.props.onReady&&e.props.onReady()}))},t.prototype.getFlexStart=function(e){switch(e){case"left":return"flex-start";case"center":return"center";case"right":return"flex-end"}},t.prototype.render=function(){var e=this.props.options,t=e.color,n=e.background_color,r=e.line_height,a=e.word_spacing,i=e.letter_spacing,s=e.font_size,u=e.font_weight,l=e.font,c=e.horizontal_alignment,d=e.vertical_alignment,p={color:t,lineHeight:r?r+"px":"normal",wordSpacing:a?a+"px":"normal",letterSpacing:i?i+"px":"normal",fontSize:s?s+"px":"0px",fontWeight:u||400,whiteSpace:e.text_wrap?"normal":"nowrap",fontFamily:this.state.fontError?"Arial, helvetica, sans-serif":l},f={display:"flex",textAlign:c,justifyContent:this.getFlexStart(c),alignItems:d,backgroundColor:n};return o.createElement("div",{className:"composition-text-layer",style:f},o.createElement("div",{className:"inner-text",style:p,ref:this.innerTextRef},this.formatContent()))},t}(o.PureComponent);t.default=l},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(35);t.default=function(e){var t=e.children,n=e.id,o=document.getElementById(n),i=document.createElement("div");return r.useEffect((function(){return o.appendChild(i),function(){o.removeChild(i)}}),[i,o]),a.createPortal(t,i)}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.persistColumns=t.getBatch=t.updateAssociation=t.addPredefinedColumn=t.setPage=t.BATCH_ITEMS_PER_PAGE=void 0;var a=n(102);t.BATCH_ITEMS_PER_PAGE=50;var o={name:"experience_id",type:"EGC",from_import:0,detail:"id"},i={TOGGlE_LOADING:"activeBatch/TOGGLE_LOADING",TOGGLE_UPDATING:"activeBatch/TOGGLE_UPDATING",SET_BATCH:"activeBatch/SET_BATCH",ADD_COLUMN:"activeBatch/ADD_COLUMN",UPDATE_ASSOCIATION:"activeBatch/UPDATE_ASSOCIATION",REPLACE_ASSOCIATION_OPTIONS:"activeBatch/REPLACE_ASSOCIATION_OPTIONS",SET_PAGE:"activeBatch/SET_PAGE"};t.setPage=function(e){return{type:i.SET_PAGE,page:e}};t.addPredefinedColumn=function(e,n){return function(r){r({type:i.ADD_COLUMN,columnData:n}),r(t.persistColumns(e))}};t.updateAssociation=function(e,n,r,a){return function(o){o({type:i.UPDATE_ASSOCIATION,colIndex:n,newType:r,newAssociation:a}),o(t.persistColumns(e))}};t.getBatch=function(e){return function(n,r){var a=r(),s=a.story,c=a.batchesList.selected,d=a.activeBatch.page;return new Promise((function(r,a){n({type:i.TOGGlE_LOADING,toggle:!0}),e.getBatch(c.id,d).then((function(r){n({type:i.SET_BATCH,batch:r});var a=function(){var e=s.data?s.data.acts:s.acts,t=u(e),r=l(e),a=Object.keys(t).map((function(e){return{label:t[e].name,value:t[e].id}}));a.push({label:"composition_id",value:"composition_id"}),a.push({label:"composition_tag",value:"composition_tag"}),n({type:i.REPLACE_ASSOCIATION_OPTIONS,associationOptions:{UGC:a,EGC:r}}),n({type:i.TOGGlE_LOADING,toggle:!1})};0===r.columns.length?(n(t.addPredefinedColumn(e,o)),a()):a()})).catch((function(e){console.error("Failed to load batch:",e),n({type:i.TOGGlE_LOADING,toggle:!1}),a(e)}))}))}};t.persistColumns=function(e){return function(t,n){var r=n().activeBatch.data,a=r.id,o=r.columns;return t({type:i.TOGGLE_UPDATING,toggle:!0}),new Promise((function(n,r){e.updateBatchColumns(a,o).catch((function(n){return t(s(e,n))})).then((function(){t({type:i.TOGGLE_UPDATING,toggle:!1})}))}))}};var s=function(e,n){return function(r){console.error("Failed to update data set:",n),a.default.emit("error","Failed to update data set"),r(t.getBatch(e))}},u=function(e){var t=Object.keys(e),n={};return t.forEach((function(t){n=r(r({},n),e[t].inventory)})),n},l=function(e){var t,n,r=[],a=[],o=e[Object.keys(e)[0]];return void 0===o?[]:(t=Object.keys(o.scenes),void 0===(n=o.scenes[t[0]])?[]:(r.push({label:"Experience Id",value:"id"},{label:"Story Id",value:"story_id"}),n.sceneData.encodingSettings.forEach((function(e){if(e.extension&&e.height){var t=e.name,n=e.extension+"_"+e.height;void 0===a[n]&&(a[n]=0),a[n]++,r.push({label:t,value:1===a[n]?"video_url_"+n:"video_url_"+n+"_"+a[n].toString()})}})),n.exportAsPlaylist&&r.push({label:"M3U8",value:"video_url_m3u8"}),n.sceneData.savePosterFrame&&r.push({label:"Poster Frame",value:"poster"}),n.sceneData.saveSnapshotFrame&&r.push({label:"Snapshot Frame",value:"snapshot"}),n.sceneData.saveSocialFrame&&r.push({label:"Social Frame",value:"social"}),r))};t.default=i},function(e,t,n){"use strict";(function(e){var r=n(56),a="object"==typeof exports&&exports&&!exports.nodeType&&exports,o=a&&"object"==typeof e&&e&&!e.nodeType&&e,i=o&&o.exports===a&&r.a.process,s=function(){try{var e=o&&o.require&&o.require("util").types;return e||i&&i.binding&&i.binding("util")}catch(e){}}();t.a=s}).call(this,n(82)(e))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AssetsTableTypeCell=t.AssetsTableTypeFilter=t.AssetsTableSelectCell=t.AssetsTableSelectFilter=t.AssetsTablePreviewCell=t.AssetsTableDropzone=t.AssetsTableDateCell=t.AssetsTypeIcon=t.ImageSequencePlayer=t.ImagePreview=t.VideoPreview=t.AudioPlayer=t.VideoPlayer=t.ImagePlayer=t.AssetDetails=t.Portal=t.ShortcutMenu=t.StoryPreviewer=t.LogViewer=t.ServiceIcon=t.NoAccess=t.Spinner=t.DeterminateLoader=t.Section=t.SliderField=t.ToastService=t.TextAreaField=t.TextField=t.Tag=t.Tabs=t.ColorField=t.SelectField=t.NumberField=t.Modal=t.ListField=t.HRule=t.FieldWrapper=t.DataTablePaginator=t.DataTable=t.ControlledList=t.CheckboxField=t.Card=t.ButtonMenuItem=t.ButtonMenu=t.ButtonGroupField=t.Button=t.ImposiumDropdown=t.ImposiumHeader=t.AuthGate=t.AppWrapper=void 0,t.SessionService=t.AuthService=t.batchActions=t.activeBatch=t.assetActions=t.assetTags=t.addAssetTagToList=t.getAssetTagList=t.selectedAssets=t.assetUploads=t.assetList=t.assetFilters=t.resetSelection=t.deselectAsset=t.selectAsset=t.uploadAssets=t.toggleAutoTag=t.doAssetTableHydration=t.updateAssetData=t.updateAssetName=t.deleteAssetTag=t.addAssetTag=t.deleteAssets=t.getAssets=t.updateFilters=t.storyDeleted=t.orgNameMutated=t.storyNameMutated=t.storyAdded=t.clearCachedAccessList=t.cacheAccessData=t.access=t.clearCachedAuth=t.login=t.auth=t.StaticCompositionRenderer=t.StaticCompositionEditor=t.PreviewNotAvailable=t.DroppableAssetRenderer=t.FontAssetPreview=t.AssetsUploadMenu=t.AssetField=t.AssetsTableComplexTagCell=t.AssetsTableTagsPivot=t.AssetsTableTagsFilter=t.AssetsTableTagsCell=t.AssetsTableDurationCell=t.AssetsTableNameCell=t.AssetsTableNameFilter=t.AssetsTableStatusCell=void 0,t.PublishStatusIndicator=t.getStoryPublishStatus=t.clearStoryPublishStatus=t.publishVersion=t.publish=t.PublishWizard=t.ASSET_TYPES=t.CompositionRendererLayer=t.TextLayer=t.formatDateDefault=t.padStart=t.toFixed=t.validateAssetMimetype=t.mimetypeConformsToOverlay=t.filterHotkeys=t.formattedTime=t.fitToContainer=t.scrapeEmail=t.parameterizeServiceUrl=t.string2HexCode=t.getFirstStoryInOrg=t.validateAccessLevel=t.Timer=t.StorageService=t.LegacyAPI=t.API=void 0;var r=n(278);t.AppWrapper=r.default;var a=n(346);t.AuthGate=a.default;var o=n(92);t.ImposiumHeader=o.default;var i=n(59);t.ImposiumDropdown=i.default;var s=n(5);t.Button=s.default;var u=n(97);t.ButtonMenu=u.default;var l=n(98);t.ButtonMenuItem=l.default;var c=n(99);t.Card=c.default;var d=n(100);t.ControlledList=d.default;var p=n(354);t.DataTable=p.default;var f=n(359);t.DataTablePaginator=f.default;var h=n(360);t.Modal=h.default;var m=n(361);t.Tabs=m.default;var _=n(11);t.FieldWrapper=_.default;var y=n(30);t.CheckboxField=y.default;var g=n(362);t.ListField=g.default;var v=n(63);t.ButtonGroupField=v.default;var b=n(41);t.NumberField=b.default;var w=n(22);t.SelectField=w.default;var M=n(13);t.TextField=M.default;var L=n(64);t.TextAreaField=L.default;var T=n(102);t.ToastService=T.default;var k=n(367);t.SliderField=k.default;var x=n(65);t.ColorField=x.default;var E=n(51);t.Tag=E.default;var S=n(16);t.HRule=S.default;var O=n(474);t.Section=O.default;var D=n(21);t.Spinner=D.default;var Y=n(91);t.NoAccess=Y.default;var A=n(93);t.ServiceIcon=A.default;var C=n(128);t.DeterminateLoader=C.default;var j=n(475);t.AssetsTableDateCell=j.default;var P=n(476);t.AssetsTablePreviewCell=P.default;var H=n(477);t.AssetsTableDurationCell=H.default;var I=n(129);t.AssetField=I.default;var N=n(84);t.AssetsTableDropzone=N.default;var R=n(480);t.AssetsTableNameCell=R.default;var F=n(481);t.AssetsTableNameFilter=F.default;var z=n(482);t.AssetsTableSelectCell=z.default;var U=n(483);t.AssetsTableSelectFilter=U.default;var W=n(484);t.AssetsTableTagsCell=W.default;var B=n(485);t.AssetsTableTagsFilter=B.default;var V=n(486);t.AssetsTableTagsPivot=V.default;var G=n(487);t.AssetsTableComplexTagCell=G.default;var q=n(488);t.AssetsTableTypeCell=q.default;var J=n(489);t.AssetsTableStatusCell=J.default;var K=n(490);t.AssetsTableTypeFilter=K.default;var $=n(85);t.AssetsTypeIcon=$.default;var X=n(491);t.FontAssetPreview=X.default;var Z=n(492);t.AssetsUploadMenu=Z.default;var Q=n(493);Object.defineProperty(t,"PreviewNotAvailable",{enumerable:!0,get:function(){return Q.PreviewNotAvailable}});var ee=n(130);t.DroppableAssetRenderer=ee.default;var te=n(131);t.ImagePlayer=te.default;var ne=n(26);t.VideoPlayer=ne.default;var re=n(494);t.AudioPlayer=re.default;var ae=n(495);t.VideoPreview=ae.default;var oe=n(496);t.ImagePreview=oe.default;var ie=n(497);t.ImageSequencePlayer=ie.default;var se=n(132);t.LogViewer=se.default;var ue=n(499);t.StoryPreviewer=ue.default;var le=n(502);t.StaticCompositionEditor=le.default;var ce=n(135);t.StaticCompositionRenderer=ce.default;var de=n(506);t.ShortcutMenu=de.default;var pe=n(86);t.TextLayer=pe.default;var fe=n(25);Object.defineProperty(t,"ASSET_TYPES",{enumerable:!0,get:function(){return fe.ASSET_TYPES}});var he=n(87);t.Portal=he.default;var me=n(507);t.AssetDetails=me.default;var _e=n(54);t.PublishWizard=_e.default;var ye=n(517);t.auth=ye.default;var ge=n(39);Object.defineProperty(t,"login",{enumerable:!0,get:function(){return ge.login}}),Object.defineProperty(t,"clearCachedAuth",{enumerable:!0,get:function(){return ge.clearCachedAuth}});var ve=n(518);t.access=ve.default;var be=n(519);t.publish=be.default;var we=n(55);Object.defineProperty(t,"publishVersion",{enumerable:!0,get:function(){return we.publishVersion}}),Object.defineProperty(t,"clearStoryPublishStatus",{enumerable:!0,get:function(){return we.clearStoryPublishStatus}}),Object.defineProperty(t,"getStoryPublishStatus",{enumerable:!0,get:function(){return we.getStoryPublishStatus}});var Me=n(40);Object.defineProperty(t,"cacheAccessData",{enumerable:!0,get:function(){return Me.cacheAccessData}}),Object.defineProperty(t,"clearCachedAccessList",{enumerable:!0,get:function(){return Me.clearCachedAccessList}}),Object.defineProperty(t,"storyAdded",{enumerable:!0,get:function(){return Me.storyAdded}}),Object.defineProperty(t,"storyNameMutated",{enumerable:!0,get:function(){return Me.storyNameMutated}}),Object.defineProperty(t,"orgNameMutated",{enumerable:!0,get:function(){return Me.orgNameMutated}}),Object.defineProperty(t,"storyDeleted",{enumerable:!0,get:function(){return Me.storyDeleted}});var Le=n(24);Object.defineProperty(t,"updateFilters",{enumerable:!0,get:function(){return Le.updateFilters}});var Te=n(17);Object.defineProperty(t,"getAssets",{enumerable:!0,get:function(){return Te.getAssets}}),Object.defineProperty(t,"deleteAssets",{enumerable:!0,get:function(){return Te.deleteAssets}}),Object.defineProperty(t,"addAssetTag",{enumerable:!0,get:function(){return Te.addAssetTag}}),Object.defineProperty(t,"deleteAssetTag",{enumerable:!0,get:function(){return Te.deleteAssetTag}}),Object.defineProperty(t,"updateAssetName",{enumerable:!0,get:function(){return Te.updateAssetName}}),Object.defineProperty(t,"updateAssetData",{enumerable:!0,get:function(){return Te.updateAssetData}}),Object.defineProperty(t,"doAssetTableHydration",{enumerable:!0,get:function(){return Te.doAssetTableHydration}});var ke=n(83);Object.defineProperty(t,"getAssetTagList",{enumerable:!0,get:function(){return ke.getAssetTagList}}),Object.defineProperty(t,"addAssetTagToList",{enumerable:!0,get:function(){return ke.addAssetTagToList}});var xe=n(52);Object.defineProperty(t,"toggleAutoTag",{enumerable:!0,get:function(){return xe.toggleAutoTag}}),Object.defineProperty(t,"uploadAssets",{enumerable:!0,get:function(){return xe.uploadAssets}});var Ee=n(33);Object.defineProperty(t,"selectAsset",{enumerable:!0,get:function(){return Ee.selectAsset}}),Object.defineProperty(t,"deselectAsset",{enumerable:!0,get:function(){return Ee.deselectAsset}}),Object.defineProperty(t,"resetSelection",{enumerable:!0,get:function(){return Ee.resetSelection}});var Se=n(520);t.assetFilters=Se.default;var Oe=n(521);t.assetList=Oe.default;var De=n(522);t.assetTags=De.default;var Ye=n(523);t.assetUploads=Ye.default;var Ae=n(524);t.selectedAssets=Ae.default;var Ce=n(17);t.assetActions=Ce.default;var je=n(525);t.activeBatch=je.default;var Pe=n(88);t.batchActions=Pe.default;var He=n(29);t.AuthService=He.default;var Ie=n(27);t.SessionService=Ie.default;var Ne=n(526);t.API=Ne.default;var Re=n(528);t.LegacyAPI=Re.default;var Fe=n(529);t.StorageService=Fe.default;var ze=n(134);t.Timer=ze.default;var Ue=n(9);Object.defineProperty(t,"getFirstStoryInOrg",{enumerable:!0,get:function(){return Ue.getFirstStoryInOrg}}),Object.defineProperty(t,"string2HexCode",{enumerable:!0,get:function(){return Ue.string2HexCode}}),Object.defineProperty(t,"toFixed",{enumerable:!0,get:function(){return Ue.toFixed}}),Object.defineProperty(t,"padStart",{enumerable:!0,get:function(){return Ue.padStart}}),Object.defineProperty(t,"parameterizeServiceUrl",{enumerable:!0,get:function(){return Ue.parameterizeServiceUrl}}),Object.defineProperty(t,"scrapeEmail",{enumerable:!0,get:function(){return Ue.scrapeEmail}}),Object.defineProperty(t,"fitToContainer",{enumerable:!0,get:function(){return Ue.fitToContainer}}),Object.defineProperty(t,"filterHotkeys",{enumerable:!0,get:function(){return Ue.filterHotkeys}}),Object.defineProperty(t,"mimetypeConformsToOverlay",{enumerable:!0,get:function(){return Ue.mimetypeConformsToOverlay}}),Object.defineProperty(t,"validateAssetMimetype",{enumerable:!0,get:function(){return Ue.validateAssetMimetype}}),Object.defineProperty(t,"formatDateDefault",{enumerable:!0,get:function(){return Ue.formatDateDefault}}),Object.defineProperty(t,"validateAccessLevel",{enumerable:!0,get:function(){return Ue.validateAccessLevel}}),Object.defineProperty(t,"formattedTime",{enumerable:!0,get:function(){return Ue.formattedTime}});var We=n(136);t.CompositionRendererLayer=We.default;var Be=n(273);t.PublishStatusIndicator=Be.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(37),o=n(57),i=n(58);t.default=function(e){if(!e.type)throw new Error("NoAccess requires a type of either: request or restrict");var t="request"===e.type;return r.createElement("div",{className:"no-access"},t?r.createElement(a.FontAwesomeIcon,{icon:o.faUserLock,size:"6x"}):r.createElement(a.FontAwesomeIcon,{icon:i.faExclamationTriangle,size:"6x"}),r.createElement("div",{className:"no-access-copy"},r.createElement("h1",{className:"no-access-heading"},t?"You don't have access to Imposium yet":"Service not found"),t&&r.createElement("a",{href:"mailto:info@imposium.com?subject=My access to Imposium is restricted"},"Request Access")))}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(59),s=n(93),u=n(9),l=n(4),c=function(e){function t(n){var r=e.call(this,n)||this;return r.serviceToggleRef=null,r.storyToggleRef=null,r.orgsToggleRef=null,r.componentDidMount=function(){var e=r.props,t=e.accessData,n=e.activeOrganization;t&&r.parseAccessData(t,n)},r.componentDidUpdate=function(e){var n=r.props,a=n.accessData,o=n.activeOrganization,i=e.accessData,s=e.activeOrganization;a&&a!==i&&r.parseAccessData(a,o),"string"==typeof o&&o.length===t.UUID_LENGTH&&o!==s&&r.parseAccessData(a,o)},r.parseAccessData=function(e,n){var a=e.organizations,o=e.services,i=n?e.organizations.find((function(e){return e.id===n})):void 0,s=a.length>1?a.filter((function(e){return e.id!==n})):[],l=o&&i?o.filter((function(e){return i.services.includes(e.id)})):[],c=l.length>1?o.find((function(e){return window.location.href.includes(e.url)})):void 0,d=t.DEFAULT_ACCOUNT_TOGGLE_COLOR,p="";i&&i.hasOwnProperty("name")&&(d=u.string2HexCode(i.name),p=r.pullFirstChar(i.name)),r.setState({servicesByOrganization:l,activeServiceBlob:c,inactiveOrganizations:s,activeOrganizationBlob:i,dropdownToggleColor:d,activeFirstChar:p})},r.changeStory=function(e){var t=r.props.onStoryChange;"function"==typeof t&&(t(e),r.setState({showStoriesDropdown:!1}))},r.toggleAccountDropdown=function(e,t){void 0===t&&(t="");var n=r.props.onOrganizationChange;e?r.setState({showAccountDropdown:!0}):(r.setState({showAccountDropdown:!1}),t&&n&&n(t),t&&!n&&window.location.replace(r.getHomeUrl()+"?organization_id="+t))},r.getHomeUrl=function(){var e=window.location,t=e.hostname,n=e.host;return"localhost"===t?"http://localhost:3036":n.includes(".staging.")?"https://launchpad.staging.imposium.com":"https://launchpad.imposium.com"},r.doLogout=function(){r.setState({showAccountDropdown:!1}),r.props.logout()},r.pullFirstChar=function(e){return e?e.substring(0,1):""},r.renderDropdownChevron=function(e){return e?t.UP:t.DOWN},r.renderServiceAnchor=function(e,t,n){return o.createElement("div",{className:"anchor-wrapper",key:e.id},o.createElement("a",{href:u.parameterizeServiceUrl(t,n,e.url,e.id)},o.createElement("div",{className:"icon-fixed"},o.createElement(s.default,{iconName:e.icon,color:"#"+e.color})),e.name))},r.state={inactiveOrganizations:[],servicesByOrganization:[],activeServiceBlob:void 0,activeOrganizationBlob:void 0,showAccountDropdown:!1,showStoriesDropdown:!1,showServiceDropdown:!1,dropdownToggleColor:t.DEFAULT_ACCOUNT_TOGGLE_COLOR,activeFirstChar:""},r.serviceToggleRef=o.createRef(),r.storyToggleRef=o.createRef(),r.orgsToggleRef=o.createRef(),r}return a(t,e),t.prototype.render=function(){var e,n,r,a,c,d,p,f,h,m,_,y,g=this,v=this.props,b=v.email,w=v.accessData,M=v.activeOrganization,L=v.activeStory,T=v.hideStoryPicker,k=this.state,x=k.showAccountDropdown,E=k.servicesByOrganization,S=k.activeServiceBlob,O=k.showStoriesDropdown,D=k.inactiveOrganizations,Y=k.activeOrganizationBlob,A=k.activeFirstChar,C=k.dropdownToggleColor,j=k.showServiceDropdown,P={};return w&&((r=E.find((function(e){return window.location.href.includes(e.url)})))&&(P={color:"#"+r.color},n={borderBottom:"4px solid #"+r.color}),a=E.filter((function(e){return!e.private&&-1===t.PRIVATE_IDS.indexOf(e.id)})).map((function(e){return g.renderServiceAnchor(e,M,L)})),c=E.filter((function(e){return!e.private&&t.PRIVATE_IDS.indexOf(e.id)>-1})).map((function(e){return g.renderServiceAnchor(e,M,L)})),y=o.createElement("div",{className:"service-menu"},o.createElement("section",{className:"service-menu-section"},o.createElement("div",{className:"service-menu-heading"},t.SERVICE_MESH_ALIAS),o.createElement("div",{className:"service-menu-anchors"},a)),c.length>0&&o.createElement("section",{className:"service-menu-section"},o.createElement("div",{className:"service-menu-heading"},t.PRIVATE_HEADER),o.createElement("div",{className:"service-menu-anchors"},c)),o.createElement("section",{className:"service-menu-section"},o.createElement("div",{className:"service-menu-heading"},t.DOCS_HEADER),o.createElement("div",{className:"service-menu-anchors"},o.createElement("div",{className:"anchor-wrapper doc"},o.createElement("a",{target:"__blank",href:t.API_DOCS_LINK},o.createElement("div",{className:"icon-fixed"},o.createElement(s.default,{iconName:"FaCogs"})),t.API_DOCS_LINK_COPY)),o.createElement("div",{className:"anchor-wrapper doc"},o.createElement("a",{target:"__blank",href:t.SDK_DOCS_LINK},o.createElement("div",{className:"icon-fixed"},o.createElement(s.default,{iconName:"FaJsSquare"})),t.SDK_DOCS_LINK_COPY))))),_=o.createElement("button",{id:"btn-toggle-services",className:"btn-toggle-services",style:P,ref:this.serviceToggleRef,onClick:function(){return g.setState({showServiceDropdown:!g.state.showServiceDropdown})}},o.createElement("span",null,S?S.name:t.SERVICE_MESH_ALIAS),this.renderDropdownChevron(j)),d=o.createElement("button",{id:"btn-toggle-orgs",className:"btn-toggle-orgs",ref:this.orgsToggleRef,style:{backgroundColor:C},onClick:function(){return g.toggleAccountDropdown(!x)}},A)),w&&Y&&(p=o.createElement("div",{className:"orgs-menu-active-org"},o.createElement("div",{className:"active-first-char",style:{backgroundColor:C}},this.pullFirstChar(Y.name)),o.createElement("div",null,Y.name))),w&&Y&&!T&&(e=Y.stories.find((function(e){return e.id===L})),f=o.createElement("button",{id:"btn-toggle-story",className:"btn-toggle-story",ref:this.storyToggleRef,onClick:function(){g.setState({showStoriesDropdown:!g.state.showStoriesDropdown})}},o.createElement("div",{className:"story-name"},e?e.name:t.DEFAULT_SERVICE_TOGGLE_COPY),this.renderDropdownChevron(O)),m=0===Y.stories.length?o.createElement("div",{className:"no-stories-dialog"},t.NO_STORIES_COPY):Y.stories.map((function(e){return o.createElement("button",{key:e.id,className:"btn-change-story",onClick:function(){return g.changeStory(e)}},e.name)}))),x&&(h=o.createElement("div",{className:"orgs-menu-org-picker"},D.map((function(e){return o.createElement("button",{key:e.name,className:"menu-item inactive-org-button",onClick:function(){return g.toggleAccountDropdown(!1,e.id)}},o.createElement("div",{className:"inactive-first-char",style:{backgroundColor:u.string2HexCode(e.name)}},g.pullFirstChar(e.name)),e.name)})))),o.createElement("nav",{id:"imposium-header",className:"imposium-header",style:n},o.createElement("div",{className:"inner-content"},o.createElement("span",{className:"inner-left"},o.createElement("a",{className:"title",href:u.parameterizeServiceUrl(M,L,this.getHomeUrl())},o.createElement("div",{className:"logo"}),o.createElement("h1",{className:"heading"},t.DEFAULT_TITLE)),_),o.createElement("span",{className:"inner-right"},f,d,o.createElement("a",{href:"https://support.imposium.com",target:"_blank"},o.createElement("div",{className:"btn-help"},l.ICON_HELP)))),o.createElement(i.default,{key:"services-dropdown",position:"bottomleft",show:j,toggleRef:this.serviceToggleRef,onOutsideClick:function(){return g.setState({showServiceDropdown:!1})}},y),o.createElement(i.default,{key:"stories-dropdown",position:"bottomright",show:O,toggleRef:this.storyToggleRef,onOutsideClick:function(){return g.setState({showStoriesDropdown:!1})}},o.createElement("div",{className:"stories-menu"},m)),o.createElement(i.default,{key:"org-dropdown",position:"bottomright",show:x,toggleRef:this.orgsToggleRef,onOutsideClick:function(){return g.toggleAccountDropdown(!1)}},o.createElement("div",{className:"orgs-menu"},p,h,o.createElement("div",{className:"orgs-menu-footer"},o.createElement("div",{className:"email"},b),o.createElement("button",{className:"btn-logout",onClick:function(){return g.doLogout()}},t.LOGOUT_COPY)))))},t.DEFAULT_TITLE="imposium",t.SERVICE_MESH_ALIAS="services",t.DOCS_HEADER="documentation",t.PRIVATE_HEADER="admin",t.API_DOCS_LINK_COPY="REST API",t.SDK_DOCS_LINK_COPY="Javascript SDK",t.API_DOCS_LINK="https://docs.imposium.com",t.SDK_DOCS_LINK="https://docs.imposium.com/js-sdk/",t.DEFAULT_SERVICE_TOGGLE_COPY="stories",t.DEFAULT_ACCOUNT_TOGGLE_COLOR="royalblue",t.NO_STORIES_COPY="No stories were found",t.LOGOUT_COPY="logout",t.UUID_LENGTH=36,t.UP=l.ICON_CHEVRON_UP,t.DOWN=l.ICON_CHEVRON_DOWN,t.PRIVATE_IDS=[9,10,11,12],t}(o.PureComponent);t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(37),o=n(279),i=n(280),s=n(281),u=n(282),l=n(94),c=n(95),d=n(283),p=n(284),f=n(285),h=n(286),m=n(57),_=n(287),y=n(288),g=n(289);t.default=function(e){switch(e.iconName){case"FaFilm":return r.createElement(a.FontAwesomeIcon,{icon:i.faFilm,color:e.color});case"FaRegFileVideo":return r.createElement(a.FontAwesomeIcon,{icon:l.faFileVideo,color:e.color});case"FaChartBar":return r.createElement(a.FontAwesomeIcon,{icon:d.faChartBar,color:e.color});case"FaGavel":return r.createElement(a.FontAwesomeIcon,{icon:s.faGavel,color:e.color});case"FaDatabase":return r.createElement(a.FontAwesomeIcon,{icon:u.faDatabase,color:e.color});case"FaVideo":return r.createElement(a.FontAwesomeIcon,{icon:c.faVideo,color:e.color});case"FaUsersCog":return r.createElement(a.FontAwesomeIcon,{icon:p.faUsersCog,color:e.color});case"FaPlayCircle":return r.createElement(a.FontAwesomeIcon,{icon:h.faPlayCircle,color:e.color});case"FaUserLock":return r.createElement(a.FontAwesomeIcon,{icon:m.faUserLock,color:e.color});case"FaSiteMap":return r.createElement(a.FontAwesomeIcon,{icon:_.faSitemap,color:e.color});case"FaFileAlt":return r.createElement(a.FontAwesomeIcon,{icon:g.faFileAlt,color:e.color});case"FaChartArea":return r.createElement(a.FontAwesomeIcon,{icon:y.faChartArea,color:e.color});case"FaCogs":return r.createElement(a.FontAwesomeIcon,{icon:f.faCogs});case"FaJsSquare":return r.createElement(a.FontAwesomeIcon,{icon:o.faJsSquare});default:return null}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=[],a="M384 121.941V128H256V0h6.059c6.365 0 12.47 2.529 16.971 7.029l97.941 97.941A24.005 24.005 0 0 1 384 121.941zM224 136V0H24C10.745 0 0 10.745 0 24v464c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24V160H248c-13.2 0-24-10.8-24-24zm96 144.016v111.963c0 21.445-25.943 31.998-40.971 16.971L224 353.941V392c0 13.255-10.745 24-24 24H88c-13.255 0-24-10.745-24-24V280c0-13.255 10.745-24 24-24h112c13.255 0 24 10.745 24 24v38.059l55.029-55.013c15.011-15.01 40.971-4.491 40.971 16.97z";t.definition={prefix:"fas",iconName:"file-video",icon:[384,512,r,"f1c8",a]},t.faFileVideo=t.definition,t.prefix="fas",t.iconName="file-video",t.width=384,t.height=512,t.ligatures=r,t.unicode="f1c8",t.svgPathData=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=[],a="M336.2 64H47.8C21.4 64 0 85.4 0 111.8v288.4C0 426.6 21.4 448 47.8 448h288.4c26.4 0 47.8-21.4 47.8-47.8V111.8c0-26.4-21.4-47.8-47.8-47.8zm189.4 37.7L416 177.3v157.4l109.6 75.5c21.2 14.6 50.4-.3 50.4-25.8V127.5c0-25.4-29.1-40.4-50.4-25.8z";t.definition={prefix:"fas",iconName:"video",icon:[576,512,r,"f03d",a]},t.faVideo=t.definition,t.prefix="fas",t.iconName="video",t.width=576,t.height=512,t.ligatures=r,t.unicode="f03d",t.svgPathData=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=[],a="M256 8C119.043 8 8 119.083 8 256c0 136.997 111.043 248 248 248s248-111.003 248-248C504 119.083 392.957 8 256 8zm0 110c23.196 0 42 18.804 42 42s-18.804 42-42 42-42-18.804-42-42 18.804-42 42-42zm56 254c0 6.627-5.373 12-12 12h-88c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h12v-64h-12c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h64c6.627 0 12 5.373 12 12v100h12c6.627 0 12 5.373 12 12v24z";t.definition={prefix:"fas",iconName:"info-circle",icon:[512,512,r,"f05a",a]},t.faInfoCircle=t.definition,t.prefix="fas",t.iconName="info-circle",t.width=512,t.height=512,t.ligatures=r,t.unicode="f05a",t.svgPathData=a},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__values||function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=function(e){function t(t){var n=e.call(this,t)||this;return n.state={open:!1},n.evtHandlers={toggleMenu:function(e){return n.toggleMenu(e)},clickOutside:function(e,t){return n.handleClickOutside(e,t)}},n.toggleRef=i.createRef(),n.menuRef=i.createRef(),n}return a(t,e),t.prototype.handleClickOutside=function(e,t){var n=!!(this.toggleRef&&this.toggleRef.current&&this.toggleRef.current.contains(e.target)),r=!!(this.menuRef&&this.menuRef.current&&this.menuRef.current.contains(e.target));n||t||(document.removeEventListener("click",this.evtHandlers.clickOutside),this.setState({open:!1})),t&&!r&&(document.removeEventListener("click",this.evtHandlers.clickOutside),this.setState({open:!1}))},t.prototype.componentWillUnmount=function(){document.removeEventListener("click",this.evtHandlers.clickOutside)},t.prototype.toggleMenu=function(e){var t=this,n=this.props.onClick,r=!this.state.open;n&&n(r),this.setState({open:r},(function(){t.state.open?document.addEventListener("click",(function(e){return t.evtHandlers.clickOutside(e,!!n||void 0)})):document.removeEventListener("click",t.evtHandlers.clickOutside)}))},t.prototype.renderItems=function(){var e,t,n=this,r=this.props,a=r.items,s=r.isOpen,u=[],l=function(e){var t=i.cloneElement(e,{onClick:function(t){n.props.isOpen||document.removeEventListener("click",n.evtHandlers.clickOutside),n.setState({open:s||!1},(function(){e.props.onClick(t)}))}});u.push(t)};try{for(var c=o(a),d=c.next();!d.done;d=c.next()){l(d.value)}}catch(t){e={error:t}}finally{try{d&&!d.done&&(t=c.return)&&t.call(c)}finally{if(e)throw e.error}}return u},t.prototype.renderMenu=function(){var e=this.props.position;if(this.state.open)return i.createElement("div",{className:"menu "+e},this.renderItems())},t.prototype.render=function(){var e=this.props.button,t=this.state.open,n=i.cloneElement(e,{buttonRef:this.toggleRef,onClick:this.evtHandlers.toggleMenu,active:t});return i.createElement("div",{ref:this.menuRef,className:"button-menu"},n,this.renderMenu())},t}(i.PureComponent);t.default=s},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=function(e){function t(t){return e.call(this,t)||this}return a(t,e),t.prototype.render=function(){var e=this,t=this.props,n=t.label,r=t.active;return o.createElement("div",{className:"button-menu-item "+(r?"active":null)+" ",onClick:function(t){return e.props.onClick(t)}},n)},t}(o.Component);t.default=i},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(5),s=n(4),u=function(e){function t(t){var n=e.call(this,t)||this;return n.state={open:t.open},n.evtHandlers={toggleOpen:function(e){return n.toggleOpen(e)}},n}return a(t,e),t.prototype.toggleOpen=function(e){var t=this;e.persist(),e.preventDefault();var n=this.props,r=n.collapsable,a=n.onOpen,o=n.onClose;r&&("function"==typeof this.props.onToggle&&this.props.onToggle(!this.state.open),this.setState({open:!this.state.open},(function(){t.state.open&&a?a(e):!t.state.open&&o&&o(e)})))},t.prototype.componentDidUpdate=function(e){var t=this.props,n=t.open;t.collapsable;e.open!==n&&this.setState({open:n})},t.prototype.renderTitle=function(e){var t=this.props.title;return"small"===e?o.createElement("p",null,t):"large"===e?o.createElement("h1",null,t):o.createElement("h2",null,t)},t.prototype.renderContent=function(){if(this.state.open)return o.createElement("div",{className:"card-content"},this.props.children)},t.prototype.render=function(){var e=this.props,t=e.collapsable,n=(e.title,e.style),r=t?"collapsable":"",a=!this.state.open&&t?"closed":"",i=n||"default";return o.createElement("div",{className:"card "+a+" "+r+" "+i},o.createElement("div",{className:"card-header",onClick:this.evtHandlers.toggleOpen},this.renderTitle(i),this.renderButtons()),this.renderContent())},t.prototype.renderButtons=function(){var e=this.props.collapsable,t=this.state.open?s.ICON_CARET_UP:s.ICON_CARET_DOWN;if(e)return o.createElement("div",{className:"header-buttons"},o.createElement(i.default,{style:"subtle",onClick:this.evtHandlers.toggleOpen},t))},t}(o.PureComponent);t.default=u},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(5),s=n(4),u=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return a(t,e),t.prototype.renderRemoveButton=function(e){var t=this;if(this.props.removable)return o.createElement("div",{className:"buttons"},o.createElement(i.default,{style:"subtle",color:"danger",onClick:function(){return t.props.onRemove(e)}},s.ICON_TIMES))},t.prototype.render=function(){var e,t=this,n=this.props.items;return n&&(e=n.map((function(e,n){return o.createElement("div",{className:"item",key:"item-"+n},e,t.renderRemoveButton(n))}))),o.createElement("div",{className:"controlled-list"},e)},t}(o.PureComponent);t.default=u},function(e,t){e.exports=u},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(0),o=n(364),i=n(37),s=n(96),u=n(58),l=function(){function e(){}return e.DEFAULT_TOAST_CONFIG={hideAfter:3,position:"bottom-right"},e.INFO_STYLE={bar:{size:"2px",style:"solid",color:"#56B05E"},renderIcon:function(){return a.createElement(i.FontAwesomeIcon,{icon:s.faInfoCircle,color:"#56B05E"})}},e.ERROR_STYLE={bar:{size:"2px",style:"solid",color:"#AF1126"},renderIcon:function(){return a.createElement(i.FontAwesomeIcon,{icon:u.faExclamationTriangle,color:"#AF1126"})}},e.emit=function(t,n){switch(t){case"info":return void o.default.info(n,r(r({},e.DEFAULT_TOAST_CONFIG),e.INFO_STYLE));case"error":return void o.default.error(n,r(r({},e.DEFAULT_TOAST_CONFIG),e.ERROR_STYLE));default:return}},e}();t.default=l},function(e,t,n){(function(t){var n="object"==typeof t&&t&&t.Object===Object&&t;e.exports=n}).call(this,n(38))},function(e,t,n){var r=n(372),a=n(32);e.exports=function(e,t){return e&&r(e,t,a)}},function(e,t,n){var r=n(374),a=n(106),o=n(12),i=n(67),s=n(107),u=n(108),l=Object.prototype.hasOwnProperty;e.exports=function(e,t){var n=o(e),c=!n&&a(e),d=!n&&!c&&i(e),p=!n&&!c&&!d&&u(e),f=n||c||d||p,h=f?r(e.length,String):[],m=h.length;for(var _ in e)!t&&!l.call(e,_)||f&&("length"==_||d&&("offset"==_||"parent"==_)||p&&("buffer"==_||"byteLength"==_||"byteOffset"==_)||s(_,m))||h.push(_);return h}},function(e,t,n){var r=n(375),a=n(15),o=Object.prototype,i=o.hasOwnProperty,s=o.propertyIsEnumerable,u=r(function(){return arguments}())?r:function(e){return a(e)&&i.call(e,"callee")&&!s.call(e,"callee")};e.exports=u},function(e,t){var n=/^(?:0|[1-9]\d*)$/;e.exports=function(e,t){var r=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==r||"symbol"!=r&&n.test(e))&&e>-1&&e%1==0&&e<t}},function(e,t,n){var r=n(377),a=n(69),o=n(70),i=o&&o.isTypedArray,s=i?a(i):r;e.exports=s},function(e,t){e.exports=function(e,t){return function(n){return e(t(n))}}},function(e,t,n){var r=n(18),a=n(23);e.exports=function(e){if(!a(e))return!1;var t=r(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},function(e,t){e.exports=function(e){return e}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,a=Array(r);++n<r;)a[n]=t(e[n],n,e);return a}},function(e,t){var n=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return n.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},function(e,t,n){var r=n(412),a=n(15);e.exports=function e(t,n,o,i,s){return t===n||(null==t||null==n||!a(t)&&!a(n)?t!=t&&n!=n:r(t,n,o,i,e,s))}},function(e,t,n){var r=n(413),a=n(416),o=n(417);e.exports=function(e,t,n,i,s,u){var l=1&n,c=e.length,d=t.length;if(c!=d&&!(l&&d>c))return!1;var p=u.get(e),f=u.get(t);if(p&&f)return p==t&&f==e;var h=-1,m=!0,_=2&n?new r:void 0;for(u.set(e,t),u.set(t,e);++h<c;){var y=e[h],g=t[h];if(i)var v=l?i(g,y,h,t,e,u):i(y,g,h,e,t,u);if(void 0!==v){if(v)continue;m=!1;break}if(_){if(!a(t,(function(e,t){if(!o(_,t)&&(y===e||s(y,e,n,i,u)))return _.push(t)}))){m=!1;break}}else if(y!==g&&!s(y,g,n,i,u)){m=!1;break}}return u.delete(e),u.delete(t),m}},function(e,t,n){var r=n(14).Uint8Array;e.exports=r},function(e,t,n){var r=n(118),a=n(77),o=n(32);e.exports=function(e){return r(e,o,a)}},function(e,t,n){var r=n(119),a=n(12);e.exports=function(e,t,n){var o=t(e);return a(e)?o:r(o,n(e))}},function(e,t){e.exports=function(e,t){for(var n=-1,r=t.length,a=e.length;++n<r;)e[a+n]=t[n];return e}},function(e,t){e.exports=function(){return[]}},function(e,t,n){var r=n(23);e.exports=function(e){return e==e&&!r(e)}},function(e,t){e.exports=function(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in Object(n)))}}},function(e,t,n){var r=n(124),a=n(49);e.exports=function(e,t){for(var n=0,o=(t=r(t,e)).length;null!=e&&n<o;)e=e[a(t[n++])];return n&&n==o?e:void 0}},function(e,t,n){var r=n(12),a=n(78),o=n(430),i=n(433);e.exports=function(e,t){return r(e)?e:a(e,t)?[e]:o(i(e))}},function(e,t,n){var r=n(126),a=n(74),o=Object.prototype.hasOwnProperty;e.exports=function(e,t,n){var i=e[t];o.call(e,t)&&a(i,n)&&(void 0!==n||t in e)||r(e,t,n)}},function(e,t,n){var r=n(448);e.exports=function(e,t,n){"__proto__"==t&&r?r(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}},function(e,t,n){var r=n(119),a=n(72),o=n(77),i=n(120),s=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)r(t,o(e)),e=a(e);return t}:i;e.exports=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0);t.default=function(e){var t=e.progress?"scaleX("+e.progress/100+")":"scaleX(0)";return r.createElement("div",{className:"determinate-loader"},r.createElement("div",{className:"progress-bg",style:{transform:t}}),r.createElement("div",{className:"progress-copy"},Math.round(e.progress)+"%"))}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(7),s=n(5),u=n(13),l=n(84),c=n(130),d=n(9),p=n(24),f=n(52),h=n(8),m=n(10),_=n(4),y=function(e){function t(t){var n=e.call(this,t)||this;return n.onFileDrop=function(e,t){var r=n.props,a=r.accepts,o=r.storyId,i=r.api;if(t){var s=t.getItem().files;d.mimetypeConformsToOverlay(a,s[0])&&(n.setState({assetUploading:!0}),n.props.uploadAssets(i,[s[0]],o,(function(e){n.setState({assetName:e.name,error:!1},(function(){n.setState({assetUploading:!1}),n.props.onChange(e)}))})))}},n.state={assetName:"",error:!1,assetUploading:!1},n}return a(t,e),t.prototype.componentDidMount=function(){var e=this.props,t=e.assetId;e.api;t&&!this.state.assetName&&this.loadAsset()},t.prototype.componentDidUpdate=function(e,t){var n=this.props.assetId;n&&n!==e.assetId?this.loadAsset():n||this.setState({error:!1,assetName:""})},t.prototype.loadAsset=function(){var e=this,t=this.props,n=t.assetId;t.api.getAssetItem(n).then((function(t){e.setState({error:!1,assetName:t.name})})).catch((function(t){e.setState({error:!0,assetName:"Could not find asset: "+n})}))},t.prototype.setFilter=function(e){var t=this.props.accepts;this.props.updateFilters({type:t||"",page:1})},t.prototype.onAssetDrop=function(e,t){var n=this,r=e.rowData,a=e.rowData,o=a.name,s=(a.id,a.type),u=this.props.accepts;s===u?this.setState({assetName:o,error:!1},(function(){n.props.onChange(r)})):this.props.onError&&this.props.onError(i.assets.field.fieldMismatchError.replace("[accepts]",u))},t.prototype.clearAsset=function(e){var t=this;this.setState({assetName:"",error:!1},(function(){t.props.onChange(null)}))},t.prototype.render=function(){var e=this,t=this.props,n=t.assetId,r=t.label,a=t.width,d=t.tooltip,p=t.labelPosition,f=this.state,h=f.assetName,m=f.assetUploading,y=f.error?"error":"",g=n?"":i.assets.field.dragPrompt,v={width:a||"100%"},b=[];return b.push(o.createElement(s.default,{key:"btn-filter",onClick:function(t){return e.setFilter(t)},style:"subtle",tooltip:i.assets.field.tooltipFilter,color:"primary"},_.ICON_FILTER)),n&&!m&&b.unshift(o.createElement(s.default,{key:"btn-clear-asset",tooltip:i.assets.field.tooltipClear,onClick:function(t){return e.clearAsset(t)},style:"subtle"},_.ICON_TIMES)),o.createElement("div",{style:v,className:"asset-field "+y},o.createElement(l.default,{onDrop:function(t,n){return e.onFileDrop(t,n)},disable:m},o.createElement(c.default,{onDrop:function(t,n){return e.onAssetDrop(t,n)}},o.createElement(u.default,{readOnly:!0,label:r,tooltip:d,loading:m,placeholder:g,buttons:b,labelPosition:p,value:h}))))},t}(o.PureComponent);t.default=h.connect(null,(function(e){return m.bindActionCreators({updateFilters:p.updateFilters,uploadAssets:f.uploadAssets},e)}))(y)},function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i};Object.defineProperty(t,"__esModule",{value:!0});var a=n(0),o=n(61),i=n(479);t.default=function(e){var t=r(o.useDrop({accept:i.ASSET_DND_TYPES.ASSET_NAME,drop:e.onDrop,collect:function(e){return{isOver:e.isOver(),canDrop:e.canDrop()}}}),2),n=t[0],s=n.canDrop,u=n.isOver,l=t[1],c=s&&u?"1px solid royalblue":"";return a.createElement("div",{ref:l,className:"asset-target",style:{border:c}},e.children)}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(34),s=n(26),u=function(e){function t(t){var n=e.call(this,t)||this;return n.state={imageHeight:1080,imageWidth:1920},n.imgNode=o.createRef(),n}return a(t,e),t.prototype.getImageStyle=function(){var e=this.state,t=e.imageHeight,n=e.imageWidth,r=this.props,a=r.padding,o=r.width,u=r.height,l=void 0!==a?a:i.DEFAULT_PADDING;return t&&n?s.getPlayerStyle(o,u,n,t,l,n,t):{}},t.prototype.metadataLoaded=function(e){this.setState({imageWidth:e.target.naturalWidth,imageHeight:e.target.naturalHeight})},t.prototype.render=function(){var e=this,t=this.props,n=t.url;return!1!==t.active?o.createElement("div",{className:"media-player"},o.createElement("div",{className:"inner-viewer",style:this.getImageStyle()},o.createElement("img",{onLoad:function(t){return e.metadataLoaded(t)},src:n,ref:this.imgNode}))):null},t}(o.PureComponent);t.default=u},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(498),s=n(7),u=function(e){function t(t){var n=e.call(this,t)||this;return n.state={loading:!0,log:""},n.ansi_up=new i.default,n.ansi_up.use_classes=!0,n}return a(t,e),t.prototype.getJobLogs=function(){var e=this,t=this.props,n=t.api,r=t.onError,a=t.jobId;n.getJobLogUrl(this.props.jobId).then((function(t){var o=t.signed_url;n.getJobLog(o).then((function(t){e.setState({loading:!1,log:t})})).catch((function(t){r&&r(s.previewer.logDownloadError.replace("[jobId]",a)),e.setState({loading:!1,log:""})}))})).catch((function(t){r&&r(s.previewer.logURLError.replace("[jobId]",e.props.jobId)),e.setState({loading:!1,log:""})}))},t.prototype.componentDidMount=function(){this.props.jobId&&this.getJobLogs()},t.prototype.componentDidUpdate=function(e){e.jobId!==this.props.jobId&&this.props.jobId&&this.getJobLogs()},t.prototype.render=function(){var e=this.ansi_up.ansi_to_html(this.state.log);return o.createElement("div",{className:"log-viewer"},o.createElement("div",{className:"log-html",dangerouslySetInnerHTML:{__html:e}}))},t}(o.PureComponent);t.default=u},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BOOLEAN_DEFAULT_OPTIONS=t.VARIABLE_TYPES=void 0,t.VARIABLE_TYPES={TEXT:"text",NUMBER:"number",BOOLEAN:"boolean",ENUM:"enum",IMAGE:"image",VIDEO:"video",AUDIO:"audio"},t.BOOLEAN_DEFAULT_OPTIONS=[{value:!0,label:"True"},{value:!1,label:"False"}]},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e){this.config=e}return e.prototype.stop=function(){this.running=!1,clearInterval(this.timeInterval)},e.prototype.start=function(){var e=this;this.running=!0,clearInterval(this.timeInterval),this.startTime=Date.now(),this.timeInterval=setInterval((function(){return e.updateTimeElapsed()}),this.config.interval)},e.prototype.updateTimeElapsed=function(){var e=Date.now()-this.startTime;this.config.onUpdate(e)},e}();t.default=r},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},i=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},s=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),l=n(136),c=function(e){function t(t){var n=e.call(this,t)||this;return n.bgRef=u.createRef(),n}return a(t,e),t.prototype.renderLayers=function(){var e=this,t=this.props,n=t.composition.layers,r=t.inventory,a=t.selectedLayer,o=function(t){e.props.onSelectLayer(t)},s=[],c=[];return n?(n.map((function(t,n){var i,d=t.id&&t.id===a;c.push(new Promise((function(e,t){i=e,t}))),s.push(u.createElement(l.default,{onUpdate:function(t){return e.updateLayer(n,t)},onReady:i,onClick:o,selected:d,layer:t,inventory:r,key:t.id||n}))})),Promise.all(c).then((function(t){i(t,1)[0];e.props.onReady&&e.props.onReady()})),s):null},t.prototype.updateLayer=function(e,t){var n=o({},this.props.composition),r=s([],i(n.layers));r[e]=t,n.layers=r,this.props.onUpdate(n)},t.prototype.resetSelected=function(e){e.preventDefault(),e.stopPropagation();var t=this.bgRef.current;!t||e.target},t.prototype.render=function(){var e=this,t=this.props.composition,n=t.width,r=t.height,a=t.background_color,o={width:n+"px",height:r+"px"};return a&&(o.backgroundColor=a),u.createElement("div",{ref:this.bgRef,className:"static-composition-renderer",style:o,onClick:function(t){return e.resetSelected(t)}},this.renderLayers())},t}(u.PureComponent);t.default=c},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(505),u=n(62),l=n(86),c=function(e){function t(t){var n=e.call(this,t)||this;return n.layerRefMount=function(e){return n.onRefMount(e)},n.evtHandlers={onDrag:function(e){return n.handleDrag(e)},onResize:function(e){return n.handleResize(e)},onRotate:function(e){return n.handleRotate(e)},onClick:function(e){return n.layerClicked(e)},onShift:function(e){return n.onShift(e)},onLeft:function(e){return n.move(e,-1,0)},onRight:function(e){return n.move(e,1,0)},onUp:function(e){return n.move(e,0,-1)},onDown:function(e){return n.move(e,0,1)}},n.moveable=i.createRef(),n.state={lockRatio:!1},n}return a(t,e),t.prototype.move=function(e,t,n){if(this.props.selected){var r=e.shiftKey?10*t:t,a=e.shiftKey?10*n:n,i=o({},this.props.layer);i.x=i.x+r,i.y=i.y+a,this.props.onUpdate(i)}},t.prototype.onShift=function(e){if("Shift"===e.key&&16===e.keyCode&&this.props.selected){var t="keydown"===e.type;this.setState({lockRatio:t})}},t.prototype.componentDidUpdate=function(){var e=this.moveable.current;e&&e.updateRect()},t.prototype.componentDidMount=function(){u.default("*",{keyup:!0},this.evtHandlers.onShift),u.default("left, shift+left",this.evtHandlers.onLeft),u.default("right, shift+right",this.evtHandlers.onRight),u.default("up, shift+up",this.evtHandlers.onUp),u.default("down, shift+down",this.evtHandlers.onDown)},t.prototype.componentWillUnmount=function(){u.default.unbind("*",this.evtHandlers.onShift),u.default.unbind("left, shift+left",this.evtHandlers.onLeft),u.default.unbind("right, shift+right",this.evtHandlers.onRight),u.default.unbind("up, shift+up",this.evtHandlers.onUp),u.default.unbind("down, shift+down",this.evtHandlers.onDown)},t.prototype.handleDrag=function(e){var t=o({},this.props.layer);t.x=Math.round(e.left),t.y=Math.round(e.top),this.props.onUpdate(t)},t.prototype.handleResize=function(e){var t=e.drag.beforeDelta,n=e.width,r=e.height,a=o({},this.props.layer);a.width=Math.round(n),a.height=Math.round(r),a.x=Math.round(a.x+t[0]),a.y=Math.round(a.y+t[1]),this.props.onUpdate(a)},t.prototype.handleRotate=function(e){var t=o({},this.props.layer);t.rotation=Math.round(e.beforeDelta+t.rotation),this.props.onUpdate(t)},t.prototype.layerClicked=function(e){e.preventDefault(),e.stopPropagation(),this.props.onClick(this.props.layer.id)},t.prototype.onRefMount=function(e){this.layerRef=e,this.forceUpdate()},t.prototype.renderLayerContent=function(){var e=this.props,t=e.layer,n=e.inventory;return i.createElement(l.default,{onReady:this.props.onReady,inventory:n,options:t})},t.prototype.render=function(){var e=this.props,t=e.selected,n=e.layer,r=this.state.lockRatio,a="comp-layer-"+n.id,o={top:n.y+"px",left:n.x+"px",width:n.width+"px",height:n.height+"px",transform:"rotate("+n.rotation+"deg)"},u=t?i.createElement(s.default,{ref:this.moveable,target:document.querySelector("."+a),onDrag:this.evtHandlers.onDrag,onDragEnd:this.evtHandlers.onDragEnd,onResize:this.evtHandlers.onResize,onResizeEnd:this.evtHandlers.onResizeEnd,onRotate:this.evtHandlers.onRotate,onRotateEnd:this.evtHandlers.onRotateEnd,keepRatio:r,resizable:!0,rotatable:!0,origin:!1,draggable:!0}):null;return i.createElement(i.Fragment,null,u,i.createElement("div",{ref:this.layerRefMount,className:"composition-renderer-layer "+a,onClick:this.evtHandlers.onClick,style:o},this.renderLayerContent()))},t}(i.PureComponent);t.default=c},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.documentationLinks=void 0;var o=n(0),i=n(7),s=n(54),u=n(4),l=n(510),c=n(512),d=n(16);t.documentationLinks=[{key:"js-sdk-link",label:o.createElement("span",null,u.ICON_JS," ",i.integration.js),link:i.integration.jsSdkLink},{key:"rest-link",label:o.createElement("span",null,u.ICON_PROJECT_DIAGRAM," ",i.integration.rest),link:i.integration.restLink}];var p=function(e){function n(t){var n=e.call(this,t)||this;return n.downloadSampleWebPage=function(){var e,t,r=n.props,a=r.story,o=r.compositionId,s=r.accessKey,u=n.getFirstAct(a);a.id&&a.name&&void 0!==u&&u.hasOwnProperty("inventory")&&(e=a.name+i.integration.sdkArchiveSuffix,t={storyId:a.id,compositionId:o,storyName:a.name,accessToken:s,inventory:u.inventory},l.downloadSDKArchive(e,t))},n.getFirstAct=function(e){for(var t in e.acts)if(e.acts.hasOwnProperty(t))return e.acts[t]},n}return a(n,e),n.prototype.linkToDemoPage=function(){var e=this.props,t=e.accessKey,n=e.compositionId,r=e.story.id;if(t){var a=c.getDemoURL()+"/"+t+"/"+r+"/"+n;window.open(a,"_blank")}},n.prototype.render=function(){var e=this,n=[{label:o.createElement("span",null,u.ICON_GLOBE," ",i.publish.webPageHosted),onClick:function(){return e.linkToDemoPage()}},{label:o.createElement("span",null,u.ICON_DOWNLOAD," ",i.publish.sampleWebpage),onClick:function(){return e.downloadSampleWebPage()}}];return o.createElement("div",null,o.createElement("h2",null,i.publish.webpageTitle),o.createElement(d.default,null),o.createElement("p",null,i.publish.webpageDesc),o.createElement(d.default,null),o.createElement("div",{className:"link-wrapper"},null==n?void 0:n.map((function(e,t){return o.createElement(s.BigButton,{key:t,label:e.label,onClick:function(){return e.onClick()}})}))),o.createElement("br",null),o.createElement("br",null),o.createElement("h2",null,i.integration.documentation),o.createElement(d.default,null),o.createElement("p",null,i.integration.docParagraph),o.createElement("div",{className:"link-wrapper"},null===t.documentationLinks||void 0===t.documentationLinks?void 0:t.documentationLinks.map((function(e){return o.createElement(s.BigLink,{key:e.key,label:e.label,link:e.link})}))))},n}(o.PureComponent);t.default=p},function(e,t,n){!function(e){"use strict";
4
4
  //! moment.js locale configuration
5
5
  e.defineLocale("af",{months:"Januarie_Februarie_Maart_April_Mei_Junie_Julie_Augustus_September_Oktober_November_Desember".split("_"),monthsShort:"Jan_Feb_Mrt_Apr_Mei_Jun_Jul_Aug_Sep_Okt_Nov_Des".split("_"),weekdays:"Sondag_Maandag_Dinsdag_Woensdag_Donderdag_Vrydag_Saterdag".split("_"),weekdaysShort:"Son_Maa_Din_Woe_Don_Vry_Sat".split("_"),weekdaysMin:"So_Ma_Di_Wo_Do_Vr_Sa".split("_"),meridiemParse:/vm|nm/i,isPM:function(e){return/^nm$/i.test(e)},meridiem:function(e,t,n){return e<12?n?"vm":"VM":n?"nm":"NM"},longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Vandag om] LT",nextDay:"[Môre om] LT",nextWeek:"dddd [om] LT",lastDay:"[Gister om] LT",lastWeek:"[Laas] dddd [om] LT",sameElse:"L"},relativeTime:{future:"oor %s",past:"%s gelede",s:"'n paar sekondes",ss:"%d sekondes",m:"'n minuut",mm:"%d minute",h:"'n uur",hh:"%d ure",d:"'n dag",dd:"%d dae",M:"'n maand",MM:"%d maande",y:"'n jaar",yy:"%d jaar"},dayOfMonthOrdinalParse:/\d{1,2}(ste|de)/,ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}(n(1))},function(e,t,n){!function(e){"use strict";
6
6
  //! moment.js locale configuration
@@ -277,5 +277,5 @@ e.defineLocale("zh-tw",{months:"一月_二月_三月_四月_五月_六月_七月
277
277
  *
278
278
  * Copyright 2006, 2015 Klaus Hartl & Fagner Brack
279
279
  * Released under the MIT license
280
- */!function(o){if(void 0===(a="function"==typeof(r=o)?r.call(t,n,t,e):r)||(e.exports=a),!0,e.exports=o(),!!0){var i=window.Cookies,s=window.Cookies=o();s.noConflict=function(){return window.Cookies=i,s}}}((function(){function e(){for(var e=0,t={};e<arguments.length;e++){var n=arguments[e];for(var r in n)t[r]=n[r]}return t}function t(e){return e.replace(/(%[0-9A-Z]{2})+/g,decodeURIComponent)}return function n(r){function a(){}function o(t,n,o){if("undefined"!=typeof document){"number"==typeof(o=e({path:"/"},a.defaults,o)).expires&&(o.expires=new Date(1*new Date+864e5*o.expires)),o.expires=o.expires?o.expires.toUTCString():"";try{var i=JSON.stringify(n);/^[\{\[]/.test(i)&&(n=i)}catch(e){}n=r.write?r.write(n,t):encodeURIComponent(String(n)).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent),t=encodeURIComponent(String(t)).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent).replace(/[\(\)]/g,escape);var s="";for(var u in o)o[u]&&(s+="; "+u,!0!==o[u]&&(s+="="+o[u].split(";")[0]));return document.cookie=t+"="+n+s}}function i(e,n){if("undefined"!=typeof document){for(var a={},o=document.cookie?document.cookie.split("; "):[],i=0;i<o.length;i++){var s=o[i].split("="),u=s.slice(1).join("=");n||'"'!==u.charAt(0)||(u=u.slice(1,-1));try{var l=t(s[0]);if(u=(r.read||r)(u,l)||t(u),n)try{u=JSON.parse(u)}catch(e){}if(a[l]=u,e===l)break}catch(e){}}return e?a[e]:a}}return a.set=o,a.get=function(e){return i(e,!1)},a.getJSON=function(e){return i(e,!0)},a.remove=function(t,n){o(t,"",e(n,{expires:-1}))},a.defaults={},a.withConverter=n,a}((function(){}))}))},function(e,t,n){"use strict";n.r(t),function(e,r){n.d(t,"Authentication",(function(){return Rt})),n.d(t,"Management",(function(){return Ft})),n.d(t,"WebAuth",(function(){return Ht})),n.d(t,"version",(function(){return se}));var a="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{};function o(e,t){return e(t={exports:{}},t.exports),t.exports}var i=o((function(e){var t,n;t=a,n=function(){function e(e){var t=[];if(0===e.length)return"";if("string"!=typeof e[0])throw new TypeError("Url must be a string. Received "+e[0]);if(e[0].match(/^[^/:]+:\/*$/)&&e.length>1){var n=e.shift();e[0]=n+e[0]}e[0].match(/^file:\/\/\//)?e[0]=e[0].replace(/^([^/:]+):\/*/,"$1:///"):e[0]=e[0].replace(/^([^/:]+):\/*/,"$1://");for(var r=0;r<e.length;r++){var a=e[r];if("string"!=typeof a)throw new TypeError("Url must be a string. Received "+a);""!==a&&(r>0&&(a=a.replace(/^[\/]+/,"")),a=r<e.length-1?a.replace(/[\/]+$/,""):a.replace(/[\/]+$/,"/"),t.push(a))}var o=t.join("/"),i=(o=o.replace(/\/(\?|&|#[^!])/g,"$1")).split("?");return i.shift()+(i.length>0?"?":"")+i.join("&")}return function(){return e("object"==typeof arguments[0]?arguments[0]:[].slice.call(arguments))}},e.exports?e.exports=n():t.urljoin=n()})),s=Object.prototype.hasOwnProperty,u=Array.isArray,l=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),c=function(e,t){for(var n=t&&t.plainObjects?Object.create(null):{},r=0;r<e.length;++r)void 0!==e[r]&&(n[r]=e[r]);return n},d={arrayToObject:c,assign:function(e,t){return Object.keys(t).reduce((function(e,n){return e[n]=t[n],e}),e)},combine:function(e,t){return[].concat(e,t)},compact:function(e){for(var t=[{obj:{o:e},prop:"o"}],n=[],r=0;r<t.length;++r)for(var a=t[r],o=a.obj[a.prop],i=Object.keys(o),s=0;s<i.length;++s){var l=i[s],c=o[l];"object"==typeof c&&null!==c&&-1===n.indexOf(c)&&(t.push({obj:o,prop:l}),n.push(c))}return function(e){for(;e.length>1;){var t=e.pop(),n=t.obj[t.prop];if(u(n)){for(var r=[],a=0;a<n.length;++a)void 0!==n[a]&&r.push(n[a]);t.obj[t.prop]=r}}}(t),e},decode:function(e,t,n){var r=e.replace(/\+/g," ");if("iso-8859-1"===n)return r.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(r)}catch(e){return r}},encode:function(e,t,n){if(0===e.length)return e;var r=e;if("symbol"==typeof e?r=Symbol.prototype.toString.call(e):"string"!=typeof e&&(r=String(e)),"iso-8859-1"===n)return escape(r).replace(/%u[0-9a-f]{4}/gi,(function(e){return"%26%23"+parseInt(e.slice(2),16)+"%3B"}));for(var a="",o=0;o<r.length;++o){var i=r.charCodeAt(o);45===i||46===i||95===i||126===i||i>=48&&i<=57||i>=65&&i<=90||i>=97&&i<=122?a+=r.charAt(o):i<128?a+=l[i]:i<2048?a+=l[192|i>>6]+l[128|63&i]:i<55296||i>=57344?a+=l[224|i>>12]+l[128|i>>6&63]+l[128|63&i]:(o+=1,i=65536+((1023&i)<<10|1023&r.charCodeAt(o)),a+=l[240|i>>18]+l[128|i>>12&63]+l[128|i>>6&63]+l[128|63&i])}return a},isBuffer:function(e){return!(!e||"object"!=typeof e||!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e)))},isRegExp:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},maybeMap:function(e,t){if(u(e)){for(var n=[],r=0;r<e.length;r+=1)n.push(t(e[r]));return n}return t(e)},merge:function e(t,n,r){if(!n)return t;if("object"!=typeof n){if(u(t))t.push(n);else{if(!t||"object"!=typeof t)return[t,n];(r&&(r.plainObjects||r.allowPrototypes)||!s.call(Object.prototype,n))&&(t[n]=!0)}return t}if(!t||"object"!=typeof t)return[t].concat(n);var a=t;return u(t)&&!u(n)&&(a=c(t,r)),u(t)&&u(n)?(n.forEach((function(n,a){if(s.call(t,a)){var o=t[a];o&&"object"==typeof o&&n&&"object"==typeof n?t[a]=e(o,n,r):t.push(n)}else t[a]=n})),t):Object.keys(n).reduce((function(t,a){var o=n[a];return s.call(t,a)?t[a]=e(t[a],o,r):t[a]=o,t}),a)}},p=String.prototype.replace,f=/%20/g,h={RFC1738:"RFC1738",RFC3986:"RFC3986"},m=d.assign({default:h.RFC3986,formatters:{RFC1738:function(e){return p.call(e,f,"+")},RFC3986:function(e){return String(e)}}},h),_=Object.prototype.hasOwnProperty,y={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,t){return e+"["+t+"]"},repeat:function(e){return e}},g=Array.isArray,v=Array.prototype.push,b=function(e,t){v.apply(e,g(t)?t:[t])},w=Date.prototype.toISOString,M=m.default,L={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:d.encode,encodeValuesOnly:!1,format:M,formatter:m.formatters[M],indices:!1,serializeDate:function(e){return w.call(e)},skipNulls:!1,strictNullHandling:!1},T=function e(t,n,r,a,o,i,s,u,l,c,p,f,h){var m=t;if("function"==typeof s?m=s(n,m):m instanceof Date?m=c(m):"comma"===r&&g(m)&&(m=d.maybeMap(m,(function(e){return e instanceof Date?c(e):e})).join(",")),null===m){if(a)return i&&!f?i(n,L.encoder,h,"key"):n;m=""}if(function(e){return"string"==typeof e||"number"==typeof e||"boolean"==typeof e||"symbol"==typeof e||"bigint"==typeof e}(m)||d.isBuffer(m))return i?[p(f?n:i(n,L.encoder,h,"key"))+"="+p(i(m,L.encoder,h,"value"))]:[p(n)+"="+p(String(m))];var _,y=[];if(void 0===m)return y;if(g(s))_=s;else{var v=Object.keys(m);_=u?v.sort(u):v}for(var w=0;w<_.length;++w){var M=_[w],T=m[M];if(!o||null!==T){var k=g(m)?"function"==typeof r?r(n,M):n:n+(l?"."+M:"["+M+"]");b(y,e(T,k,r,a,o,i,s,u,l,c,p,f,h))}}return y},k=Object.prototype.hasOwnProperty,x=Array.isArray,E={allowDots:!1,allowPrototypes:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:d.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},S=function(e){return e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(parseInt(t,10))}))},O=function(e,t){return e&&"string"==typeof e&&t.comma&&e.indexOf(",")>-1?e.split(","):e},D=function(e,t,n,r){if(e){var a=n.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,o=/(\[[^[\]]*])/g,i=n.depth>0&&/(\[[^[\]]*])/.exec(a),s=i?a.slice(0,i.index):a,u=[];if(s){if(!n.plainObjects&&k.call(Object.prototype,s)&&!n.allowPrototypes)return;u.push(s)}for(var l=0;n.depth>0&&null!==(i=o.exec(a))&&l<n.depth;){if(l+=1,!n.plainObjects&&k.call(Object.prototype,i[1].slice(1,-1))&&!n.allowPrototypes)return;u.push(i[1])}return i&&u.push("["+a.slice(i.index)+"]"),function(e,t,n,r){for(var a=r?t:O(t,n),o=e.length-1;o>=0;--o){var i,s=e[o];if("[]"===s&&n.parseArrays)i=[].concat(a);else{i=n.plainObjects?Object.create(null):{};var u="["===s.charAt(0)&&"]"===s.charAt(s.length-1)?s.slice(1,-1):s,l=parseInt(u,10);n.parseArrays||""!==u?!isNaN(l)&&s!==u&&String(l)===u&&l>=0&&n.parseArrays&&l<=n.arrayLimit?(i=[])[l]=a:i[u]=a:i={0:a}}a=i}return a}(u,t,n,r)}},Y=function(e,t){var n,r=e,a=function(e){if(!e)return L;if(null!==e.encoder&&void 0!==e.encoder&&"function"!=typeof e.encoder)throw new TypeError("Encoder has to be a function.");var t=e.charset||L.charset;if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var n=m.default;if(void 0!==e.format){if(!_.call(m.formatters,e.format))throw new TypeError("Unknown format option provided.");n=e.format}var r=m.formatters[n],a=L.filter;return("function"==typeof e.filter||g(e.filter))&&(a=e.filter),{addQueryPrefix:"boolean"==typeof e.addQueryPrefix?e.addQueryPrefix:L.addQueryPrefix,allowDots:void 0===e.allowDots?L.allowDots:!!e.allowDots,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:L.charsetSentinel,delimiter:void 0===e.delimiter?L.delimiter:e.delimiter,encode:"boolean"==typeof e.encode?e.encode:L.encode,encoder:"function"==typeof e.encoder?e.encoder:L.encoder,encodeValuesOnly:"boolean"==typeof e.encodeValuesOnly?e.encodeValuesOnly:L.encodeValuesOnly,filter:a,formatter:r,serializeDate:"function"==typeof e.serializeDate?e.serializeDate:L.serializeDate,skipNulls:"boolean"==typeof e.skipNulls?e.skipNulls:L.skipNulls,sort:"function"==typeof e.sort?e.sort:null,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:L.strictNullHandling}}(t);"function"==typeof a.filter?r=(0,a.filter)("",r):g(a.filter)&&(n=a.filter);var o,i=[];if("object"!=typeof r||null===r)return"";o=t&&t.arrayFormat in y?t.arrayFormat:t&&"indices"in t?t.indices?"indices":"repeat":"indices";var s=y[o];n||(n=Object.keys(r)),a.sort&&n.sort(a.sort);for(var u=0;u<n.length;++u){var l=n[u];a.skipNulls&&null===r[l]||b(i,T(r[l],l,s,a.strictNullHandling,a.skipNulls,a.encode?a.encoder:null,a.filter,a.sort,a.allowDots,a.serializeDate,a.formatter,a.encodeValuesOnly,a.charset))}var c=i.join(a.delimiter),d=!0===a.addQueryPrefix?"?":"";return a.charsetSentinel&&("iso-8859-1"===a.charset?d+="utf8=%26%2310003%3B&":d+="utf8=%E2%9C%93&"),c.length>0?d+c:""},A=o((function(e){function t(e){if(e)return function(e){for(var n in t.prototype)e[n]=t.prototype[n];return e}(e)}e.exports=t,t.prototype.on=t.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},t.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},t.prototype.off=t.prototype.removeListener=t.prototype.removeAllListeners=t.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var a=0;a<r.length;a++)if((n=r[a])===t||n.fn===t){r.splice(a,1);break}return 0===r.length&&delete this._callbacks["$"+e],this},t.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){r=0;for(var a=(n=n.slice(0)).length;r<a;++r)n[r].apply(this,t)}return this},t.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},t.prototype.hasListeners=function(e){return!!this.listeners(e).length}})),C=H;H.default=H,H.stable=N,H.stableStringify=N;var j=[],P=[];function H(e,t,n){var r;for(function e(t,n,r,a){var o;if("object"==typeof t&&null!==t){for(o=0;o<r.length;o++)if(r[o]===t){var i=Object.getOwnPropertyDescriptor(a,n);return void(void 0!==i.get?i.configurable?(Object.defineProperty(a,n,{value:"[Circular]"}),j.push([a,n,t,i])):P.push([t,n]):(a[n]="[Circular]",j.push([a,n,t])))}if(r.push(t),Array.isArray(t))for(o=0;o<t.length;o++)e(t[o],o,r,t);else{var s=Object.keys(t);for(o=0;o<s.length;o++){var u=s[o];e(t[u],u,r,t)}}r.pop()}}(e,"",[],void 0),r=0===P.length?JSON.stringify(e,t,n):JSON.stringify(e,R(t),n);0!==j.length;){var a=j.pop();4===a.length?Object.defineProperty(a[0],a[1],a[3]):a[0][a[1]]=a[2]}return r}function I(e,t){return e<t?-1:e>t?1:0}function N(e,t,n){var r,a=function e(t,n,r,a){var o;if("object"==typeof t&&null!==t){for(o=0;o<r.length;o++)if(r[o]===t){var i=Object.getOwnPropertyDescriptor(a,n);return void(void 0!==i.get?i.configurable?(Object.defineProperty(a,n,{value:"[Circular]"}),j.push([a,n,t,i])):P.push([t,n]):(a[n]="[Circular]",j.push([a,n,t])))}if("function"==typeof t.toJSON)return;if(r.push(t),Array.isArray(t))for(o=0;o<t.length;o++)e(t[o],o,r,t);else{var s={},u=Object.keys(t).sort(I);for(o=0;o<u.length;o++){var l=u[o];e(t[l],l,r,t),s[l]=t[l]}if(void 0===a)return s;j.push([a,n,t]),a[n]=s}r.pop()}}(e,"",[],void 0)||e;for(r=0===P.length?JSON.stringify(a,t,n):JSON.stringify(a,R(t),n);0!==j.length;){var o=j.pop();4===o.length?Object.defineProperty(o[0],o[1],o[3]):o[0][o[1]]=o[2]}return r}function R(e){return e=void 0!==e?e:function(e,t){return t},function(t,n){if(P.length>0)for(var r=0;r<P.length;r++){var a=P[r];if(a[1]===t&&a[0]===n){n="[Circular]",P.splice(r,1);break}}return e.call(this,t,n)}}function F(e){return(F="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var z=function(e){return null!==e&&"object"===F(e)};function U(e){return(U="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var W=B;function B(e){if(e)return function(e){for(var t in B.prototype)Object.prototype.hasOwnProperty.call(B.prototype,t)&&(e[t]=B.prototype[t]);return e}(e)}B.prototype.clearTimeout=function(){return clearTimeout(this._timer),clearTimeout(this._responseTimeoutTimer),clearTimeout(this._uploadTimeoutTimer),delete this._timer,delete this._responseTimeoutTimer,delete this._uploadTimeoutTimer,this},B.prototype.parse=function(e){return this._parser=e,this},B.prototype.responseType=function(e){return this._responseType=e,this},B.prototype.serialize=function(e){return this._serializer=e,this},B.prototype.timeout=function(e){if(!e||"object"!==U(e))return this._timeout=e,this._responseTimeout=0,this._uploadTimeout=0,this;for(var t in e)if(Object.prototype.hasOwnProperty.call(e,t))switch(t){case"deadline":this._timeout=e.deadline;break;case"response":this._responseTimeout=e.response;break;case"upload":this._uploadTimeout=e.upload;break;default:console.warn("Unknown timeout option",t)}return this},B.prototype.retry=function(e,t){return 0!==arguments.length&&!0!==e||(e=1),e<=0&&(e=0),this._maxRetries=e,this._retries=0,this._retryCallback=t,this};var V=["ECONNRESET","ETIMEDOUT","EADDRINFO","ESOCKETTIMEDOUT"];B.prototype._shouldRetry=function(e,t){if(!this._maxRetries||this._retries++>=this._maxRetries)return!1;if(this._retryCallback)try{var n=this._retryCallback(e,t);if(!0===n)return!0;if(!1===n)return!1}catch(e){console.error(e)}if(t&&t.status&&t.status>=500&&501!==t.status)return!0;if(e){if(e.code&&V.includes(e.code))return!0;if(e.timeout&&"ECONNABORTED"===e.code)return!0;if(e.crossDomain)return!0}return!1},B.prototype._retry=function(){return this.clearTimeout(),this.req&&(this.req=null,this.req=this.request()),this._aborted=!1,this.timedout=!1,this.timedoutError=null,this._end()},B.prototype.then=function(e,t){var n=this;if(!this._fullfilledPromise){var r=this;this._endCalled&&console.warn("Warning: superagent request was sent twice, because both .end() and .then() were called. Never call .end() if you use promises"),this._fullfilledPromise=new Promise((function(e,t){r.on("abort",(function(){if(!(n._maxRetries&&n._maxRetries>n._retries))if(n.timedout&&n.timedoutError)t(n.timedoutError);else{var e=new Error("Aborted");e.code="ABORTED",e.status=n.status,e.method=n.method,e.url=n.url,t(e)}})),r.end((function(n,r){n?t(n):e(r)}))}))}return this._fullfilledPromise.then(e,t)},B.prototype.catch=function(e){return this.then(void 0,e)},B.prototype.use=function(e){return e(this),this},B.prototype.ok=function(e){if("function"!=typeof e)throw new Error("Callback required");return this._okCallback=e,this},B.prototype._isResponseOK=function(e){return!!e&&(this._okCallback?this._okCallback(e):e.status>=200&&e.status<300)},B.prototype.get=function(e){return this._header[e.toLowerCase()]},B.prototype.getHeader=B.prototype.get,B.prototype.set=function(e,t){if(z(e)){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&this.set(n,e[n]);return this}return this._header[e.toLowerCase()]=t,this.header[e]=t,this},B.prototype.unset=function(e){return delete this._header[e.toLowerCase()],delete this.header[e],this},B.prototype.field=function(e,t){if(null==e)throw new Error(".field(name, val) name can not be empty");if(this._data)throw new Error(".field() can't be used if .send() is used. Please use only .send() or only .field() & .attach()");if(z(e)){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&this.field(n,e[n]);return this}if(Array.isArray(t)){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&this.field(e,t[r]);return this}if(null==t)throw new Error(".field(name, val) val can not be empty");return"boolean"==typeof t&&(t=String(t)),this._getFormData().append(e,t),this},B.prototype.abort=function(){return this._aborted||(this._aborted=!0,this.xhr&&this.xhr.abort(),this.req&&this.req.abort(),this.clearTimeout(),this.emit("abort")),this},B.prototype._auth=function(e,t,n,r){switch(n.type){case"basic":this.set("Authorization","Basic ".concat(r("".concat(e,":").concat(t))));break;case"auto":this.username=e,this.password=t;break;case"bearer":this.set("Authorization","Bearer ".concat(e))}return this},B.prototype.withCredentials=function(e){return void 0===e&&(e=!0),this._withCredentials=e,this},B.prototype.redirects=function(e){return this._maxRedirects=e,this},B.prototype.maxResponseSize=function(e){if("number"!=typeof e)throw new TypeError("Invalid argument");return this._maxResponseSize=e,this},B.prototype.toJSON=function(){return{method:this.method,url:this.url,data:this._data,headers:this._header}},B.prototype.send=function(e){var t=z(e),n=this._header["content-type"];if(this._formData)throw new Error(".send() can't be used if .attach() or .field() is used. Please use only .send() or only .field() & .attach()");if(t&&!this._data)Array.isArray(e)?this._data=[]:this._isHost(e)||(this._data={});else if(e&&this._data&&this._isHost(this._data))throw new Error("Can't merge these send calls");if(t&&z(this._data))for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(this._data[r]=e[r]);else"string"==typeof e?(n||this.type("form"),n=this._header["content-type"],this._data="application/x-www-form-urlencoded"===n?this._data?"".concat(this._data,"&").concat(e):e:(this._data||"")+e):this._data=e;return!t||this._isHost(e)||n||this.type("json"),this},B.prototype.sortQuery=function(e){return this._sort=void 0===e||e,this},B.prototype._finalizeQueryString=function(){var e=this._query.join("&");if(e&&(this.url+=(this.url.includes("?")?"&":"?")+e),this._query.length=0,this._sort){var t=this.url.indexOf("?");if(t>=0){var n=this.url.slice(t+1).split("&");"function"==typeof this._sort?n.sort(this._sort):n.sort(),this.url=this.url.slice(0,t)+"?"+n.join("&")}}},B.prototype._appendQueryString=function(){console.warn("Unsupported")},B.prototype._timeoutError=function(e,t,n){if(!this._aborted){var r=new Error("".concat(e+t,"ms exceeded"));r.timeout=t,r.code="ECONNABORTED",r.errno=n,this.timedout=!0,this.timedoutError=r,this.abort(),this.callback(r)}},B.prototype._setTimeouts=function(){var e=this;this._timeout&&!this._timer&&(this._timer=setTimeout((function(){e._timeoutError("Timeout of ",e._timeout,"ETIME")}),this._timeout)),this._responseTimeout&&!this._responseTimeoutTimer&&(this._responseTimeoutTimer=setTimeout((function(){e._timeoutError("Response timeout of ",e._responseTimeout,"ETIMEDOUT")}),this._responseTimeout))};var G=q;function q(e){if(e)return function(e){for(var t in q.prototype)Object.prototype.hasOwnProperty.call(q.prototype,t)&&(e[t]=q.prototype[t]);return e}(e)}function J(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function K(){this._defaults=[]}q.prototype.get=function(e){return this.header[e.toLowerCase()]},q.prototype._setHeaderProperties=function(e){var t=e["content-type"]||"";this.type=t.split(/ *; */).shift();var n=function(e){return e.split(/ *; */).reduce((function(e,t){var n=t.split(/ *= */),r=n.shift(),a=n.shift();return r&&a&&(e[r]=a),e}),{})}(t);for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(this[r]=n[r]);this.links={};try{e.link&&(this.links=function(e){return e.split(/ *, */).reduce((function(e,t){var n=t.split(/ *; */),r=n[0].slice(1,-1);return e[n[1].split(/ *= */)[1].slice(1,-1)]=r,e}),{})}(e.link))}catch(e){}},q.prototype._setStatusProperties=function(e){var t=e/100|0;this.statusCode=e,this.status=this.statusCode,this.statusType=t,this.info=1===t,this.ok=2===t,this.redirect=3===t,this.clientError=4===t,this.serverError=5===t,this.error=(4===t||5===t)&&this.toError(),this.created=201===e,this.accepted=202===e,this.noContent=204===e,this.badRequest=400===e,this.unauthorized=401===e,this.notAcceptable=406===e,this.forbidden=403===e,this.notFound=404===e,this.unprocessableEntity=422===e},["use","on","once","set","query","type","accept","auth","withCredentials","sortQuery","retry","ok","redirects","timeout","buffer","serialize","parse","ca","key","pfx","cert","disableTLSCerts"].forEach((function(e){K.prototype[e]=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return this._defaults.push({fn:e,args:n}),this}})),K.prototype._setDefaults=function(e){this._defaults.forEach((function(t){e[t.fn].apply(e,function(e){return function(e){if(Array.isArray(e))return J(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return J(e,void 0);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?J(e,void 0):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t.args))}))};for(var $=K,X=o((function(e,t){function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var r;function a(){}"undefined"!=typeof window?r=window:"undefined"==typeof self?(console.warn("Using browser-only version of superagent in non-browser environment"),r=void 0):r=self,e.exports=function(e,n){return"function"==typeof n?new t.Request("GET",e).end(n):1===arguments.length?new t.Request("GET",e):new t.Request(e,n)};var o=t=e.exports;t.Request=p,o.getXHR=function(){if(r.XMLHttpRequest&&(!r.location||"file:"!==r.location.protocol||!r.ActiveXObject))return new XMLHttpRequest;try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(e){}throw new Error("Browser-only version of superagent could not find XHR")};var i="".trim?function(e){return e.trim()}:function(e){return e.replace(/(^\s*|\s*$)/g,"")};function s(e){if(!z(e))return e;var t=[];for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&u(t,n,e[n]);return t.join("&")}function u(e,t,n){if(void 0!==n)if(null!==n)if(Array.isArray(n))n.forEach((function(n){u(e,t,n)}));else if(z(n))for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&u(e,"".concat(t,"[").concat(r,"]"),n[r]);else e.push(encodeURI(t)+"="+encodeURIComponent(n));else e.push(encodeURI(t))}function l(e){for(var t,n,r={},a=e.split("&"),o=0,i=a.length;o<i;++o)-1===(n=(t=a[o]).indexOf("="))?r[decodeURIComponent(t)]="":r[decodeURIComponent(t.slice(0,n))]=decodeURIComponent(t.slice(n+1));return r}function c(e){return/[/+]json($|[^-\w])/.test(e)}function d(e){this.req=e,this.xhr=this.req.xhr,this.text="HEAD"!==this.req.method&&(""===this.xhr.responseType||"text"===this.xhr.responseType)||void 0===this.xhr.responseType?this.xhr.responseText:null,this.statusText=this.req.xhr.statusText;var t=this.xhr.status;1223===t&&(t=204),this._setStatusProperties(t),this.headers=function(e){for(var t,n,r,a,o=e.split(/\r?\n/),s={},u=0,l=o.length;u<l;++u)-1!==(t=(n=o[u]).indexOf(":"))&&(r=n.slice(0,t).toLowerCase(),a=i(n.slice(t+1)),s[r]=a);return s}(this.xhr.getAllResponseHeaders()),this.header=this.headers,this.header["content-type"]=this.xhr.getResponseHeader("content-type"),this._setHeaderProperties(this.header),null===this.text&&e._responseType?this.body=this.xhr.response:this.body="HEAD"===this.req.method?null:this._parseBody(this.text?this.text:this.xhr.response)}function p(e,t){var n=this;this._query=this._query||[],this.method=e,this.url=t,this.header={},this._header={},this.on("end",(function(){var e,t=null,r=null;try{r=new d(n)}catch(e){return(t=new Error("Parser is unable to parse the response")).parse=!0,t.original=e,n.xhr?(t.rawResponse=void 0===n.xhr.responseType?n.xhr.responseText:n.xhr.response,t.status=n.xhr.status?n.xhr.status:null,t.statusCode=t.status):(t.rawResponse=null,t.status=null),n.callback(t)}n.emit("response",r);try{n._isResponseOK(r)||(e=new Error(r.statusText||r.text||"Unsuccessful HTTP response"))}catch(t){e=t}e?(e.original=t,e.response=r,e.status=r.status,n.callback(e,r)):n.callback(null,r)}))}function f(e,t,n){var r=o("DELETE",e);return"function"==typeof t&&(n=t,t=null),t&&r.send(t),n&&r.end(n),r}o.serializeObject=s,o.parseString=l,o.types={html:"text/html",json:"application/json",xml:"text/xml",urlencoded:"application/x-www-form-urlencoded",form:"application/x-www-form-urlencoded","form-data":"application/x-www-form-urlencoded"},o.serialize={"application/x-www-form-urlencoded":s,"application/json":C},o.parse={"application/x-www-form-urlencoded":l,"application/json":JSON.parse},G(d.prototype),d.prototype._parseBody=function(e){var t=o.parse[this.type];return this.req._parser?this.req._parser(this,e):(!t&&c(this.type)&&(t=o.parse["application/json"]),t&&e&&(e.length>0||e instanceof Object)?t(e):null)},d.prototype.toError=function(){var e=this.req,t=e.method,n=e.url,r="cannot ".concat(t," ").concat(n," (").concat(this.status,")"),a=new Error(r);return a.status=this.status,a.method=t,a.url=n,a},o.Response=d,A(p.prototype),W(p.prototype),p.prototype.type=function(e){return this.set("Content-Type",o.types[e]||e),this},p.prototype.accept=function(e){return this.set("Accept",o.types[e]||e),this},p.prototype.auth=function(e,t,r){1===arguments.length&&(t=""),"object"===n(t)&&null!==t&&(r=t,t=""),r||(r={type:"function"==typeof btoa?"basic":"auto"});var a=function(e){if("function"==typeof btoa)return btoa(e);throw new Error("Cannot use basic auth, btoa is not a function")};return this._auth(e,t,r,a)},p.prototype.query=function(e){return"string"!=typeof e&&(e=s(e)),e&&this._query.push(e),this},p.prototype.attach=function(e,t,n){if(t){if(this._data)throw new Error("superagent can't mix .send() and .attach()");this._getFormData().append(e,t,n||t.name)}return this},p.prototype._getFormData=function(){return this._formData||(this._formData=new r.FormData),this._formData},p.prototype.callback=function(e,t){if(this._shouldRetry(e,t))return this._retry();var n=this._callback;this.clearTimeout(),e&&(this._maxRetries&&(e.retries=this._retries-1),this.emit("error",e)),n(e,t)},p.prototype.crossDomainError=function(){var e=new Error("Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.");e.crossDomain=!0,e.status=this.status,e.method=this.method,e.url=this.url,this.callback(e)},p.prototype.agent=function(){return console.warn("This is not supported in browser version of superagent"),this},p.prototype.ca=p.prototype.agent,p.prototype.buffer=p.prototype.ca,p.prototype.write=function(){throw new Error("Streaming is not supported in browser version of superagent")},p.prototype.pipe=p.prototype.write,p.prototype._isHost=function(e){return e&&"object"===n(e)&&!Array.isArray(e)&&"[object Object]"!==Object.prototype.toString.call(e)},p.prototype.end=function(e){this._endCalled&&console.warn("Warning: .end() was called twice. This is not supported in superagent"),this._endCalled=!0,this._callback=e||a,this._finalizeQueryString(),this._end()},p.prototype._setUploadTimeout=function(){var e=this;this._uploadTimeout&&!this._uploadTimeoutTimer&&(this._uploadTimeoutTimer=setTimeout((function(){e._timeoutError("Upload timeout of ",e._uploadTimeout,"ETIMEDOUT")}),this._uploadTimeout))},p.prototype._end=function(){if(this._aborted)return this.callback(new Error("The request has been aborted even before .end() was called"));var e=this;this.xhr=o.getXHR();var t=this.xhr,n=this._formData||this._data;this._setTimeouts(),t.onreadystatechange=function(){var n=t.readyState;if(n>=2&&e._responseTimeoutTimer&&clearTimeout(e._responseTimeoutTimer),4===n){var r;try{r=t.status}catch(e){r=0}if(!r){if(e.timedout||e._aborted)return;return e.crossDomainError()}e.emit("end")}};var r=function(t,n){n.total>0&&(n.percent=n.loaded/n.total*100,100===n.percent&&clearTimeout(e._uploadTimeoutTimer)),n.direction=t,e.emit("progress",n)};if(this.hasListeners("progress"))try{t.addEventListener("progress",r.bind(null,"download")),t.upload&&t.upload.addEventListener("progress",r.bind(null,"upload"))}catch(e){}t.upload&&this._setUploadTimeout();try{this.username&&this.password?t.open(this.method,this.url,!0,this.username,this.password):t.open(this.method,this.url,!0)}catch(e){return this.callback(e)}if(this._withCredentials&&(t.withCredentials=!0),!this._formData&&"GET"!==this.method&&"HEAD"!==this.method&&"string"!=typeof n&&!this._isHost(n)){var a=this._header["content-type"],i=this._serializer||o.serialize[a?a.split(";")[0]:""];!i&&c(a)&&(i=o.serialize["application/json"]),i&&(n=i(n))}for(var s in this.header)null!==this.header[s]&&Object.prototype.hasOwnProperty.call(this.header,s)&&t.setRequestHeader(s,this.header[s]);this._responseType&&(t.responseType=this._responseType),this.emit("request",this),t.send(void 0===n?null:n)},o.agent=function(){return new $},["GET","POST","OPTIONS","PATCH","PUT","DELETE"].forEach((function(e){$.prototype[e.toLowerCase()]=function(t,n){var r=new o.Request(e,t);return this._setDefaults(r),n&&r.end(n),r}})),$.prototype.del=$.prototype.delete,o.get=function(e,t,n){var r=o("GET",e);return"function"==typeof t&&(n=t,t=null),t&&r.query(t),n&&r.end(n),r},o.head=function(e,t,n){var r=o("HEAD",e);return"function"==typeof t&&(n=t,t=null),t&&r.query(t),n&&r.end(n),r},o.options=function(e,t,n){var r=o("OPTIONS",e);return"function"==typeof t&&(n=t,t=null),t&&r.send(t),n&&r.end(n),r},o.del=f,o.delete=f,o.patch=function(e,t,n){var r=o("PATCH",e);return"function"==typeof t&&(n=t,t=null),t&&r.send(t),n&&r.end(n),r},o.post=function(e,t,n){var r=o("POST",e);return"function"==typeof t&&(n=t,t=null),t&&r.send(t),n&&r.end(n),r},o.put=function(e,t,n){var r=o("PUT",e);return"function"==typeof t&&(n=t,t=null),t&&r.send(t),n&&r.end(n),r}})),Z=(X.Request,[]),Q=[],ee=("undefined"!=typeof Uint8Array&&Uint8Array,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"),te=0,ne=ee.length;te<ne;++te)Z[te]=ee[te],Q[ee.charCodeAt(te)]=te;function re(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&t,[n,n===t?0:4-n%4]}function ae(e,t,n){for(var r,a,o=[],i=t;i<n;i+=3)r=(e[i]<<16&16711680)+(e[i+1]<<8&65280)+(255&e[i+2]),o.push(Z[(a=r)>>18&63]+Z[a>>12&63]+Z[a>>6&63]+Z[63&a]);return o.join("")}Q["-".charCodeAt(0)]=62,Q["_".charCodeAt(0)]=63;var oe=function(e){for(var t,n=e.length,r=n%3,a=[],o=0,i=n-r;o<i;o+=16383)a.push(ae(e,o,o+16383>i?i:o+16383));return 1===r?(t=e[n-1],a.push(Z[t>>2]+Z[t<<4&63]+"==")):2===r&&(t=(e[n-2]<<8)+e[n-1],a.push(Z[t>>10]+Z[t>>4&63]+Z[t<<2&63]+"=")),a.join("")},ie=function(e){return oe(function(e){for(var t=new Array(e.length),n=0;n<e.length;n++)t[n]=e.charCodeAt(n);return t}(e)).replace(/\+/g,"-").replace(/\//g,"_")},se={raw:"9.16.2"},ue=Object.prototype.toString;function le(e,t,n,r){if(n="array"===n?"object":n,e&&typeof e[t]!==n)throw new Error(r)}function ce(e,t,n){if(typeof e!==t)throw new Error(n)}function de(e,t,n){if(-1===t.indexOf(e))throw new Error(n)}var pe={check:function(e,t,n){if(t.optional&&!e||ce(e,t.type,t.message),"object"===t.type&&n)for(var r=Object.keys(n),a=0;a<r.length;a++){var o=r[a];n[o].optional&&!e[o]||n[o].condition&&!n[o].condition(e)||(le(e,o,n[o].type,n[o].message),n[o].values&&de(e[o],n[o].values,n[o].value_message))}},attribute:le,variable:ce,value:de,isArray:function(e){return this.supportsIsArray()?Array.isArray(e):"[object Array]"===ue.call(e)},supportsIsArray:function(){return null!=Array.isArray}};function fe(e){if(null==e)throw new TypeError("Cannot convert first argument to object");for(var t=Object(e),n=1;n<arguments.length;n++){var r=arguments[n];if(null!=r)for(var a=Object.keys(Object(r)),o=0,i=a.length;o<i;o++){var s=a[o],u=Object.getOwnPropertyDescriptor(r,s);void 0!==u&&u.enumerable&&(t[s]=r[s])}}return t}var he=function(){return Object.assign?Object.assign:fe};function me(e,t){return t.reduce((function(t,n){return e[n]&&(t[n]=e[n]),t}),{})}function _e(e){var t=[];for(var n in e)t.push(e[n]);return t}function ye(){var e=_e(arguments);return e.unshift({}),he().apply(void 0,e)}function ge(e){var t=e.match(/^(https?:|file:|chrome-extension:)\/\/(([^:/?#]*)(?::([0-9]+))?)([/]{0,1}[^?#]*)(\?[^#]*|)(#.*|)$/);return t&&{href:e,protocol:t[1],host:t[2],hostname:t[3],port:t[4],pathname:t[5],search:t[6],hash:t[7]}}function ve(e,t){var n=ye(e);return e[t]&&(n[t]=e[t].trim()),n}var be={toSnakeCase:function e(t,n){return"object"!=typeof t||pe.isArray(t)||null===t?t:(n=n||[],Object.keys(t).reduce((function(r,a){return r[-1===n.indexOf(a)?function(e){for(var t,n="",r=0,a=!0,o=!0;r<e.length;)t=e.charCodeAt(r),!o&&t>=65&&t<=90||!a&&t>=48&&t<=57?(n+="_",n+=e[r].toLowerCase()):n+=e[r].toLowerCase(),a=t>=48&&t<=57,o=t>=65&&t<=90,r++;return n}(a):a]=e(t[a]),r}),{}))},toCamelCase:function e(t,n,r){return"object"!=typeof t||pe.isArray(t)||null===t?t:(n=n||[],r=r||{},Object.keys(t).reduce((function(a,o){var i,s=-1===n.indexOf(o)?(i=o.split("_")).reduce((function(e,t){return e+t.charAt(0).toUpperCase()+t.slice(1)}),i.shift()):o;return a[s]=e(t[s]||t[o],[],r),r.keepOriginal&&(a[o]=e(t[o],[],r)),a}),{}))},blacklist:function(e,t){return Object.keys(e).reduce((function(n,r){return-1===t.indexOf(r)&&(n[r]=e[r]),n}),{})},merge:function(e,t){return{base:t?me(e,t):e,with:function(e,t){return e=t?me(e,t):e,ye(this.base,e)}}},pick:me,getKeysNotIn:function(e,t){var n=[];for(var r in e)-1===t.indexOf(r)&&n.push(r);return n},extend:ye,getOriginFromUrl:function(e){if(e){var t=ge(e);if(!t)return null;var n=t.protocol+"//"+t.hostname;return t.port&&(n+=":"+t.port),n}},getLocationFromUrl:ge,trimUserDetails:function(e){return function(e,t){return["username","email","phoneNumber"].reduce(ve,e)}(e)},updatePropertyOn:function e(t,n,r){"string"==typeof n&&(n=n.split("."));var a=n[0];t.hasOwnProperty(a)&&(1===n.length?t[a]=r:e(t[a],n.slice(1),r))}};function we(e){this.request=e,this.method=e.method,this.url=e.url,this.body=e._data,this.headers=e._header}function Me(e){this.request=e}function Le(e){this._sendTelemetry=!1!==e._sendTelemetry||e._sendTelemetry,this._telemetryInfo=e._telemetryInfo||null,this._timesToRetryFailedRequests=e._timesToRetryFailedRequests,this.headers=e.headers||{},this._universalLoginPage=e.universalLoginPage}function Te(){return window}we.prototype.abort=function(){this.request.abort()},we.prototype.getMethod=function(){return this.method},we.prototype.getBody=function(){return this.body},we.prototype.getUrl=function(){return this.url},we.prototype.getHeaders=function(){return this.headers},Me.prototype.set=function(e,t){return this.request=this.request.set(e,t),this},Me.prototype.send=function(e){return this.request=this.request.send(be.trimUserDetails(e)),this},Me.prototype.withCredentials=function(){return this.request=this.request.withCredentials(),this},Me.prototype.end=function(e){return this.request.end(e),new we(this.request)},Le.prototype.setCommonConfiguration=function(e,t){if(t=t||{},this._timesToRetryFailedRequests>0&&(e=e.retry(this._timesToRetryFailedRequests)),t.noHeaders)return e;var n=this.headers;e=e.set("Content-Type","application/json");for(var r=Object.keys(this.headers),a=0;a<r.length;a++)e=e.set(r[a],n[r[a]]);return this._sendTelemetry&&(e=e.set("Auth0-Client",this.getTelemetryData())),e},Le.prototype.getTelemetryData=function(){var e=this._universalLoginPage?"auth0.js-ulp":"auth0.js",t={name:e,version:se.raw};this._telemetryInfo&&((t=be.extend({},this._telemetryInfo)).env=be.extend({},this._telemetryInfo.env),t.env[e]=se.raw);var n=JSON.stringify(t);return ie(n)},Le.prototype.get=function(e,t){return new Me(this.setCommonConfiguration(X.get(e),t))},Le.prototype.post=function(e,t){return new Me(this.setCommonConfiguration(X.post(e),t))},Le.prototype.patch=function(e,t){return new Me(this.setCommonConfiguration(X.patch(e),t))};var ke={redirect:function(e){Te().location=e},getDocument:function(){return Te().document},getWindow:Te,getOrigin:function(){var e=Te().location,t=e.origin;return t||(t=be.getOriginFromUrl(e.href)),t}};function xe(){}xe.prototype.getItem=function(){return null},xe.prototype.removeItem=function(){},xe.prototype.setItem=function(){};var Ee=o((function(e,t){var n;n=function(){function e(){for(var e=0,t={};e<arguments.length;e++){var n=arguments[e];for(var r in n)t[r]=n[r]}return t}function t(e){return e.replace(/(%[0-9A-Z]{2})+/g,decodeURIComponent)}return function n(r){function a(){}function o(t,n,o){if("undefined"!=typeof document){"number"==typeof(o=e({path:"/"},a.defaults,o)).expires&&(o.expires=new Date(1*new Date+864e5*o.expires)),o.expires=o.expires?o.expires.toUTCString():"";try{var i=JSON.stringify(n);/^[\{\[]/.test(i)&&(n=i)}catch(e){}n=r.write?r.write(n,t):encodeURIComponent(String(n)).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent),t=encodeURIComponent(String(t)).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent).replace(/[\(\)]/g,escape);var s="";for(var u in o)o[u]&&(s+="; "+u,!0!==o[u]&&(s+="="+o[u].split(";")[0]));return document.cookie=t+"="+n+s}}function i(e,n){if("undefined"!=typeof document){for(var a={},o=document.cookie?document.cookie.split("; "):[],i=0;i<o.length;i++){var s=o[i].split("="),u=s.slice(1).join("=");n||'"'!==u.charAt(0)||(u=u.slice(1,-1));try{var l=t(s[0]);if(u=(r.read||r)(u,l)||t(u),n)try{u=JSON.parse(u)}catch(e){}if(a[l]=u,e===l)break}catch(e){}}return e?a[e]:a}}return a.set=o,a.get=function(e){return i(e,!1)},a.getJSON=function(e){return i(e,!0)},a.remove=function(t,n){o(t,"",e(n,{expires:-1}))},a.defaults={},a.withConverter=n,a}((function(){}))},e.exports=n()}));function Se(){}function Oe(e){this.disableWarnings=e.disableWarnings}function De(e){if(this.warn=new Oe({}),this.storage=new Se,!0===e.__tryLocalStorageFirst)try{var t=ke.getWindow().localStorage;t&&(this.storage=t)}catch(e){this.warn.warning(e),this.warn.warning("Can't use localStorage. Using CookieStorage instead.")}}function Ye(e){this.handler=new De(e)}function Ae(e){this.storage=new Ye(e)}function Ce(e,t){return{error:e,errorDescription:t}}Se.prototype.getItem=function(e){return Ee.get(e)},Se.prototype.removeItem=function(e){Ee.remove(e)},Se.prototype.setItem=function(e,t,n){var r=be.extend({expires:1},n);"https:"===ke.getWindow().location.protocol&&(r.secure=!0),Ee.set(e,t,r)},Oe.prototype.warning=function(e){this.disableWarnings||console.warn(e)},De.prototype.failover=function(){this.storage instanceof xe?this.warn.warning("DummyStorage: ignore failover"):this.storage instanceof Se?(this.warn.warning("CookieStorage: failing over DummyStorage"),this.storage=new xe):(this.warn.warning("LocalStorage: failing over CookieStorage"),this.storage=new Se)},De.prototype.getItem=function(e){try{return this.storage.getItem(e)}catch(t){return this.warn.warning(t),this.failover(),this.getItem(e)}},De.prototype.removeItem=function(e){try{return this.storage.removeItem(e)}catch(t){return this.warn.warning(t),this.failover(),this.removeItem(e)}},De.prototype.setItem=function(e,t,n){try{return this.storage.setItem(e,t,n)}catch(r){return this.warn.warning(r),this.failover(),this.setItem(e,t,n)}},Ye.prototype.getItem=function(e){var t=this.handler.getItem(e);try{return JSON.parse(t)}catch(e){return t}},Ye.prototype.removeItem=function(e){return this.handler.removeItem(e)},Ye.prototype.setItem=function(e,t,n){var r=JSON.stringify(t);return this.handler.setItem(e,r,n)},Ae.prototype.set=function(e,t){var n={lastUsedConnection:e,lastUsedSub:t};this.storage.setItem("auth0.ssodata",JSON.stringify(n))},Ae.prototype.get=function(){var e=this.storage.getItem("auth0.ssodata");if(e)return JSON.parse(e)};var je={buildResponse:Ce,invalidToken:function(e){return Ce("invalid_token",e)}};function Pe(e,t){return(t=t||{}).ignoreCasing=!!t.ignoreCasing&&t.ignoreCasing,function(n,r){var a;return n||r?(!n&&r.err&&(n=r.err,r=null),!n&&r.error&&(n=r,r=null),n?(a={original:n},be.updatePropertyOn(a,"original.response.req._data.password","*****"),n.response&&n.response.statusCode&&(a.statusCode=n.response.statusCode),n.response&&n.response.statusText&&(a.statusText=n.response.statusText),n.response&&n.response.body&&(n=n.response.body),n.err&&(n=n.err),a.code=n.code||n.error||n.error_code||n.status||null,a.description=n.errorDescription||n.error_description||n.description||n.error||n.details||n.err||null,t.forceLegacyError&&(a.error=a.code,a.error_description=a.description),n.error_codes&&n.error_details&&(a.errorDetails={codes:n.error_codes,details:n.error_details}),n.name&&(a.name=n.name),n.policy&&(a.policy=n.policy),e(a)):!r.type||"text/html"!==r.type&&"text/plain"!==r.type?t.ignoreCasing?e(null,r.body||r):e(null,be.toCamelCase(r.body||r,[],{keepOriginal:t.keepOriginalCasing})):e(null,r.text)):e(je.buildResponse("generic_error","Something went wrong"))}}var He=["realm","audience","otp","client_id","client_secret","redirect_uri","scope","code","grant_type","username","password","refresh_token","assertion","client_assertion","client_assertion_type","code_verifier"],Ie=["connection","connection_scope","auth0Client","owp","device","realm","organization","invitation","protocol","_csrf","_intstate","login_ticket","client_id","response_type","response_mode","redirect_uri","audience","scope","state","nonce","display","prompt","screen_hint","max_age","ui_locales","claims_locales","id_token_hint","login_hint","acr_values","claims","registration","request","request_uri","code_challenge","code_challenge_method","access_type","display"],Ne=function(e,t){return be.pick(t,He)},Re=function(e,t){var n=be.getKeysNotIn(t,Ie);return n.length>0&&e.warning("Following parameters are not allowed on the `/authorize` endpoint: ["+n.join(",")+"]"),t},Fe="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{};function ze(e){var t={exports:{}};return e(t,t.exports),t.exports}var Ue=ze((function(e,t){e.exports=function(){function e(e){return"function"==typeof e}var t=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)},n=0,a=void 0,o=void 0,i=function(e,t){f[n]=e,f[n+1]=t,2===(n+=2)&&(o?o(h):v())},s="undefined"!=typeof window?window:void 0,u=s||{},l=u.MutationObserver||u.WebKitMutationObserver,c="undefined"==typeof self&&void 0!==r&&"[object process]"==={}.toString.call(r),d="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function p(){var e=setTimeout;return function(){return e(h,1)}}var f=new Array(1e3);function h(){for(var e=0;e<n;e+=2)(0,f[e])(f[e+1]),f[e]=void 0,f[e+1]=void 0;n=0}var m,_,y,g,v=void 0;function b(e,t){var n=this,r=new this.constructor(L);void 0===r[M]&&j(r);var a=n._state;if(a){var o=arguments[a-1];i((function(){return A(a,r,o,n._result)}))}else D(n,r,e,t);return r}function w(e){if(e&&"object"==typeof e&&e.constructor===this)return e;var t=new this(L);return x(t,e),t}v=c?function(){return r.nextTick(h)}:l?(_=0,y=new l(h),g=document.createTextNode(""),y.observe(g,{characterData:!0}),function(){g.data=_=++_%2}):d?((m=new MessageChannel).port1.onmessage=h,function(){return m.port2.postMessage(0)}):void 0===s?function(){try{var e=Function("return this")().require("vertx");return void 0!==(a=e.runOnLoop||e.runOnContext)?function(){a(h)}:p()}catch(e){return p()}}():p();var M=Math.random().toString(36).substring(2);function L(){}var T=void 0;function k(t,n,r){n.constructor===t.constructor&&r===b&&n.constructor.resolve===w?function(e,t){1===t._state?S(e,t._result):2===t._state?O(e,t._result):D(t,void 0,(function(t){return x(e,t)}),(function(t){return O(e,t)}))}(t,n):void 0===r?S(t,n):e(r)?function(e,t,n){i((function(e){var r=!1,a=function(n,a,o,i){try{n.call(a,(function(n){r||(r=!0,t!==n?x(e,n):S(e,n))}),(function(t){r||(r=!0,O(e,t))}))}catch(e){return e}}(n,t);!r&&a&&(r=!0,O(e,a))}),e)}(t,n,r):S(t,n)}function x(e,t){if(e===t)O(e,new TypeError("You cannot resolve a promise with itself"));else if(a=typeof(r=t),null===r||"object"!==a&&"function"!==a)S(e,t);else{var n=void 0;try{n=t.then}catch(t){return void O(e,t)}k(e,t,n)}var r,a}function E(e){e._onerror&&e._onerror(e._result),Y(e)}function S(e,t){e._state===T&&(e._result=t,e._state=1,0!==e._subscribers.length&&i(Y,e))}function O(e,t){e._state===T&&(e._state=2,e._result=t,i(E,e))}function D(e,t,n,r){var a=e._subscribers,o=a.length;e._onerror=null,a[o]=t,a[o+1]=n,a[o+2]=r,0===o&&e._state&&i(Y,e)}function Y(e){var t=e._subscribers,n=e._state;if(0!==t.length){for(var r=void 0,a=void 0,o=e._result,i=0;i<t.length;i+=3)a=t[i+n],(r=t[i])?A(n,r,a,o):a(o);e._subscribers.length=0}}function A(t,n,r,a){var o=e(r),i=void 0,s=void 0,u=!0;if(o){try{i=r(a)}catch(t){u=!1,s=t}if(n===i)return void O(n,new TypeError("A promises callback cannot return that same promise."))}else i=a;n._state!==T||(o&&u?x(n,i):!1===u?O(n,s):1===t?S(n,i):2===t&&O(n,i))}var C=0;function j(e){e[M]=C++,e._state=void 0,e._result=void 0,e._subscribers=[]}var P=function(){function e(e,n){this._instanceConstructor=e,this.promise=new e(L),this.promise[M]||j(this.promise),t(n)?(this.length=n.length,this._remaining=n.length,this._result=new Array(this.length),0===this.length?S(this.promise,this._result):(this.length=this.length||0,this._enumerate(n),0===this._remaining&&S(this.promise,this._result))):O(this.promise,new Error("Array Methods must be provided an Array"))}return e.prototype._enumerate=function(e){for(var t=0;this._state===T&&t<e.length;t++)this._eachEntry(e[t],t)},e.prototype._eachEntry=function(e,t){var n=this._instanceConstructor,r=n.resolve;if(r===w){var a=void 0,o=void 0,i=!1;try{a=e.then}catch(e){i=!0,o=e}if(a===b&&e._state!==T)this._settledAt(e._state,t,e._result);else if("function"!=typeof a)this._remaining--,this._result[t]=e;else if(n===H){var s=new n(L);i?O(s,o):k(s,e,a),this._willSettleAt(s,t)}else this._willSettleAt(new n((function(t){return t(e)})),t)}else this._willSettleAt(r(e),t)},e.prototype._settledAt=function(e,t,n){var r=this.promise;r._state===T&&(this._remaining--,2===e?O(r,n):this._result[t]=n),0===this._remaining&&S(r,this._result)},e.prototype._willSettleAt=function(e,t){var n=this;D(e,void 0,(function(e){return n._settledAt(1,t,e)}),(function(e){return n._settledAt(2,t,e)}))},e}(),H=function(){function t(e){this[M]=C++,this._result=this._state=void 0,this._subscribers=[],L!==e&&("function"!=typeof e&&function(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}(),this instanceof t?function(e,t){try{t((function(t){x(e,t)}),(function(t){O(e,t)}))}catch(t){O(e,t)}}(this,e):function(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}())}return t.prototype.catch=function(e){return this.then(null,e)},t.prototype.finally=function(t){var n=this,r=n.constructor;return e(t)?n.then((function(e){return r.resolve(t()).then((function(){return e}))}),(function(e){return r.resolve(t()).then((function(){throw e}))})):n.then(t,t)},t}();return H.prototype.then=b,H.all=function(e){return new P(this,e).promise},H.race=function(e){var n=this;return t(e)?new n((function(t,r){for(var a=e.length,o=0;o<a;o++)n.resolve(e[o]).then(t,r)})):new n((function(e,t){return t(new TypeError("You must pass an array to race."))}))},H.resolve=w,H.reject=function(e){var t=new this(L);return O(t,e),t},H._setScheduler=function(e){o=e},H._setAsap=function(e){i=e},H._asap=i,H.polyfill=function(){var e=void 0;if(void 0!==Fe)e=Fe;else if("undefined"!=typeof self)e=self;else try{e=Function("return this")()}catch(e){throw new Error("polyfill failed because global object is unavailable in this environment")}var t=e.Promise;if(t){var n=null;try{n=Object.prototype.toString.call(t.resolve())}catch(e){}if("[object Promise]"===n&&!t.cast)return}e.Promise=H},H.Promise=H,H}()})),We=ze((function(e,t){var n;e.exports=n=n||function(e,t){var n=Object.create||function(){function e(){}return function(t){var n;return e.prototype=t,n=new e,e.prototype=null,n}}(),r={},a=r.lib={},o=a.Base={extend:function(e){var t=n(this);return e&&t.mixIn(e),t.hasOwnProperty("init")&&this.init!==t.init||(t.init=function(){t.$super.init.apply(this,arguments)}),t.init.prototype=t,t.$super=this,t},create:function(){var e=this.extend();return e.init.apply(e,arguments),e},init:function(){},mixIn:function(e){for(var t in e)e.hasOwnProperty(t)&&(this[t]=e[t]);e.hasOwnProperty("toString")&&(this.toString=e.toString)},clone:function(){return this.init.prototype.extend(this)}},i=a.WordArray=o.extend({init:function(e,t){e=this.words=e||[],this.sigBytes=null!=t?t:4*e.length},toString:function(e){return(e||u).stringify(this)},concat:function(e){var t=this.words,n=e.words,r=this.sigBytes,a=e.sigBytes;if(this.clamp(),r%4)for(var o=0;o<a;o++)t[r+o>>>2]|=(n[o>>>2]>>>24-o%4*8&255)<<24-(r+o)%4*8;else for(o=0;o<a;o+=4)t[r+o>>>2]=n[o>>>2];return this.sigBytes+=a,this},clamp:function(){var t=this.words,n=this.sigBytes;t[n>>>2]&=4294967295<<32-n%4*8,t.length=e.ceil(n/4)},clone:function(){var e=o.clone.call(this);return e.words=this.words.slice(0),e},random:function(t){for(var n,r=[],a=function(t){t=t;var n=987654321,r=4294967295;return function(){var a=((n=36969*(65535&n)+(n>>16)&r)<<16)+(t=18e3*(65535&t)+(t>>16)&r)&r;return a/=4294967296,(a+=.5)*(e.random()>.5?1:-1)}},o=0;o<t;o+=4){var s=a(4294967296*(n||e.random()));n=987654071*s(),r.push(4294967296*s()|0)}return new i.init(r,t)}}),s=r.enc={},u=s.Hex={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],a=0;a<n;a++){var o=t[a>>>2]>>>24-a%4*8&255;r.push((o>>>4).toString(16)),r.push((15&o).toString(16))}return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r<t;r+=2)n[r>>>3]|=parseInt(e.substr(r,2),16)<<24-r%8*4;return new i.init(n,t/2)}},l=s.Latin1={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],a=0;a<n;a++)r.push(String.fromCharCode(t[a>>>2]>>>24-a%4*8&255));return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r<t;r++)n[r>>>2]|=(255&e.charCodeAt(r))<<24-r%4*8;return new i.init(n,t)}},c=s.Utf8={stringify:function(e){try{return decodeURIComponent(escape(l.stringify(e)))}catch(e){throw new Error("Malformed UTF-8 data")}},parse:function(e){return l.parse(unescape(encodeURIComponent(e)))}},d=a.BufferedBlockAlgorithm=o.extend({reset:function(){this._data=new i.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=c.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var n=this._data,r=n.words,a=n.sigBytes,o=this.blockSize,s=a/(4*o),u=(s=t?e.ceil(s):e.max((0|s)-this._minBufferSize,0))*o,l=e.min(4*u,a);if(u){for(var c=0;c<u;c+=o)this._doProcessBlock(r,c);var d=r.splice(0,u);n.sigBytes-=l}return new i.init(d,l)},clone:function(){var e=o.clone.call(this);return e._data=this._data.clone(),e},_minBufferSize:0});a.Hasher=d.extend({cfg:o.extend(),init:function(e){this.cfg=this.cfg.extend(e),this.reset()},reset:function(){d.reset.call(this),this._doReset()},update:function(e){return this._append(e),this._process(),this},finalize:function(e){return e&&this._append(e),this._doFinalize()},blockSize:16,_createHelper:function(e){return function(t,n){return new e.init(n).finalize(t)}},_createHmacHelper:function(e){return function(t,n){return new p.HMAC.init(e,n).finalize(t)}}});var p=r.algo={};return r}(Math)})),Be=ze((function(e,t){var n;e.exports=(n=We,function(e){var t=n,r=t.lib,a=r.WordArray,o=r.Hasher,i=t.algo,s=[],u=[];!function(){function t(t){for(var n=e.sqrt(t),r=2;r<=n;r++)if(!(t%r))return!1;return!0}function n(e){return 4294967296*(e-(0|e))|0}for(var r=2,a=0;a<64;)t(r)&&(a<8&&(s[a]=n(e.pow(r,.5))),u[a]=n(e.pow(r,1/3)),a++),r++}();var l=[],c=i.SHA256=o.extend({_doReset:function(){this._hash=new a.init(s.slice(0))},_doProcessBlock:function(e,t){for(var n=this._hash.words,r=n[0],a=n[1],o=n[2],i=n[3],s=n[4],c=n[5],d=n[6],p=n[7],f=0;f<64;f++){if(f<16)l[f]=0|e[t+f];else{var h=l[f-15],m=l[f-2];l[f]=((h<<25|h>>>7)^(h<<14|h>>>18)^h>>>3)+l[f-7]+((m<<15|m>>>17)^(m<<13|m>>>19)^m>>>10)+l[f-16]}var _=r&a^r&o^a&o,y=p+((s<<26|s>>>6)^(s<<21|s>>>11)^(s<<7|s>>>25))+(s&c^~s&d)+u[f]+l[f];p=d,d=c,c=s,s=i+y|0,i=o,o=a,a=r,r=y+(((r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22))+_)|0}n[0]=n[0]+r|0,n[1]=n[1]+a|0,n[2]=n[2]+o|0,n[3]=n[3]+i|0,n[4]=n[4]+s|0,n[5]=n[5]+c|0,n[6]=n[6]+d|0,n[7]=n[7]+p|0},_doFinalize:function(){var t=this._data,n=t.words,r=8*this._nDataBytes,a=8*t.sigBytes;return n[a>>>5]|=128<<24-a%32,n[14+(a+64>>>9<<4)]=e.floor(r/4294967296),n[15+(a+64>>>9<<4)]=r,t.sigBytes=4*n.length,this._process(),this._hash},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});t.SHA256=o._createHelper(c),t.HmacSHA256=o._createHmacHelper(c)}(Math),n.SHA256)})),Ve=ze((function(e,t){var n,r;e.exports=(r=(n=We).lib.WordArray,n.enc.Base64={stringify:function(e){var t=e.words,n=e.sigBytes,r=this._map;e.clamp();for(var a=[],o=0;o<n;o+=3)for(var i=(t[o>>>2]>>>24-o%4*8&255)<<16|(t[o+1>>>2]>>>24-(o+1)%4*8&255)<<8|t[o+2>>>2]>>>24-(o+2)%4*8&255,s=0;s<4&&o+.75*s<n;s++)a.push(r.charAt(i>>>6*(3-s)&63));var u=r.charAt(64);if(u)for(;a.length%4;)a.push(u);return a.join("")},parse:function(e){var t=e.length,n=this._map,a=this._reverseMap;if(!a){a=this._reverseMap=[];for(var o=0;o<n.length;o++)a[n.charCodeAt(o)]=o}var i=n.charAt(64);if(i){var s=e.indexOf(i);-1!==s&&(t=s)}return function(e,t,n){for(var a=[],o=0,i=0;i<t;i++)if(i%4){var s=n[e.charCodeAt(i-1)]<<i%4*2,u=n[e.charCodeAt(i)]>>>6-i%4*2;a[o>>>2]|=(s|u)<<24-o%4*8,o++}return r.create(a,o)}(e,t,a)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="},n.enc.Base64)})),Ge=ze((function(e,t){e.exports=We.enc.Hex})),qe=ze((function(e,t){(function(){var t;function n(e,t,n){null!=e&&("number"==typeof e?this.fromNumber(e,t,n):this.fromString(e,null==t&&"string"!=typeof e?256:t))}function r(){return new n(null)}var a="undefined"!=typeof navigator;a&&"Microsoft Internet Explorer"==navigator.appName?(n.prototype.am=function(e,t,n,r,a,o){for(var i=32767&t,s=t>>15;--o>=0;){var u=32767&this[e],l=this[e++]>>15,c=s*u+l*i;a=((u=i*u+((32767&c)<<15)+n[r]+(1073741823&a))>>>30)+(c>>>15)+s*l+(a>>>30),n[r++]=1073741823&u}return a},t=30):a&&"Netscape"!=navigator.appName?(n.prototype.am=function(e,t,n,r,a,o){for(;--o>=0;){var i=t*this[e++]+n[r]+a;a=Math.floor(i/67108864),n[r++]=67108863&i}return a},t=26):(n.prototype.am=function(e,t,n,r,a,o){for(var i=16383&t,s=t>>14;--o>=0;){var u=16383&this[e],l=this[e++]>>14,c=s*u+l*i;a=((u=i*u+((16383&c)<<14)+n[r]+a)>>28)+(c>>14)+s*l,n[r++]=268435455&u}return a},t=28),n.prototype.DB=t,n.prototype.DM=(1<<t)-1,n.prototype.DV=1<<t,n.prototype.FV=Math.pow(2,52),n.prototype.F1=52-t,n.prototype.F2=2*t-52;var o,i,s=new Array;for(o="0".charCodeAt(0),i=0;i<=9;++i)s[o++]=i;for(o="a".charCodeAt(0),i=10;i<36;++i)s[o++]=i;for(o="A".charCodeAt(0),i=10;i<36;++i)s[o++]=i;function u(e){return"0123456789abcdefghijklmnopqrstuvwxyz".charAt(e)}function l(e,t){var n=s[e.charCodeAt(t)];return null==n?-1:n}function c(e){var t=r();return t.fromInt(e),t}function d(e){var t,n=1;return 0!=(t=e>>>16)&&(e=t,n+=16),0!=(t=e>>8)&&(e=t,n+=8),0!=(t=e>>4)&&(e=t,n+=4),0!=(t=e>>2)&&(e=t,n+=2),0!=(t=e>>1)&&(e=t,n+=1),n}function p(e){this.m=e}function f(e){this.m=e,this.mp=e.invDigit(),this.mpl=32767&this.mp,this.mph=this.mp>>15,this.um=(1<<e.DB-15)-1,this.mt2=2*e.t}function h(e,t){return e&t}function m(e,t){return e|t}function _(e,t){return e^t}function y(e,t){return e&~t}function g(e){if(0==e)return-1;var t=0;return 0==(65535&e)&&(e>>=16,t+=16),0==(255&e)&&(e>>=8,t+=8),0==(15&e)&&(e>>=4,t+=4),0==(3&e)&&(e>>=2,t+=2),0==(1&e)&&++t,t}function v(e){for(var t=0;0!=e;)e&=e-1,++t;return t}function b(){}function w(e){return e}function M(e){this.r2=r(),this.q3=r(),n.ONE.dlShiftTo(2*e.t,this.r2),this.mu=this.r2.divide(e),this.m=e}p.prototype.convert=function(e){return e.s<0||e.compareTo(this.m)>=0?e.mod(this.m):e},p.prototype.revert=function(e){return e},p.prototype.reduce=function(e){e.divRemTo(this.m,null,e)},p.prototype.mulTo=function(e,t,n){e.multiplyTo(t,n),this.reduce(n)},p.prototype.sqrTo=function(e,t){e.squareTo(t),this.reduce(t)},f.prototype.convert=function(e){var t=r();return e.abs().dlShiftTo(this.m.t,t),t.divRemTo(this.m,null,t),e.s<0&&t.compareTo(n.ZERO)>0&&this.m.subTo(t,t),t},f.prototype.revert=function(e){var t=r();return e.copyTo(t),this.reduce(t),t},f.prototype.reduce=function(e){for(;e.t<=this.mt2;)e[e.t++]=0;for(var t=0;t<this.m.t;++t){var n=32767&e[t],r=n*this.mpl+((n*this.mph+(e[t]>>15)*this.mpl&this.um)<<15)&e.DM;for(e[n=t+this.m.t]+=this.m.am(0,r,e,t,0,this.m.t);e[n]>=e.DV;)e[n]-=e.DV,e[++n]++}e.clamp(),e.drShiftTo(this.m.t,e),e.compareTo(this.m)>=0&&e.subTo(this.m,e)},f.prototype.mulTo=function(e,t,n){e.multiplyTo(t,n),this.reduce(n)},f.prototype.sqrTo=function(e,t){e.squareTo(t),this.reduce(t)},n.prototype.copyTo=function(e){for(var t=this.t-1;t>=0;--t)e[t]=this[t];e.t=this.t,e.s=this.s},n.prototype.fromInt=function(e){this.t=1,this.s=e<0?-1:0,e>0?this[0]=e:e<-1?this[0]=e+this.DV:this.t=0},n.prototype.fromString=function(e,t){var r;if(16==t)r=4;else if(8==t)r=3;else if(256==t)r=8;else if(2==t)r=1;else if(32==t)r=5;else{if(4!=t)return void this.fromRadix(e,t);r=2}this.t=0,this.s=0;for(var a=e.length,o=!1,i=0;--a>=0;){var s=8==r?255&e[a]:l(e,a);s<0?"-"==e.charAt(a)&&(o=!0):(o=!1,0==i?this[this.t++]=s:i+r>this.DB?(this[this.t-1]|=(s&(1<<this.DB-i)-1)<<i,this[this.t++]=s>>this.DB-i):this[this.t-1]|=s<<i,(i+=r)>=this.DB&&(i-=this.DB))}8==r&&0!=(128&e[0])&&(this.s=-1,i>0&&(this[this.t-1]|=(1<<this.DB-i)-1<<i)),this.clamp(),o&&n.ZERO.subTo(this,this)},n.prototype.clamp=function(){for(var e=this.s&this.DM;this.t>0&&this[this.t-1]==e;)--this.t},n.prototype.dlShiftTo=function(e,t){var n;for(n=this.t-1;n>=0;--n)t[n+e]=this[n];for(n=e-1;n>=0;--n)t[n]=0;t.t=this.t+e,t.s=this.s},n.prototype.drShiftTo=function(e,t){for(var n=e;n<this.t;++n)t[n-e]=this[n];t.t=Math.max(this.t-e,0),t.s=this.s},n.prototype.lShiftTo=function(e,t){var n,r=e%this.DB,a=this.DB-r,o=(1<<a)-1,i=Math.floor(e/this.DB),s=this.s<<r&this.DM;for(n=this.t-1;n>=0;--n)t[n+i+1]=this[n]>>a|s,s=(this[n]&o)<<r;for(n=i-1;n>=0;--n)t[n]=0;t[i]=s,t.t=this.t+i+1,t.s=this.s,t.clamp()},n.prototype.rShiftTo=function(e,t){t.s=this.s;var n=Math.floor(e/this.DB);if(n>=this.t)t.t=0;else{var r=e%this.DB,a=this.DB-r,o=(1<<r)-1;t[0]=this[n]>>r;for(var i=n+1;i<this.t;++i)t[i-n-1]|=(this[i]&o)<<a,t[i-n]=this[i]>>r;r>0&&(t[this.t-n-1]|=(this.s&o)<<a),t.t=this.t-n,t.clamp()}},n.prototype.subTo=function(e,t){for(var n=0,r=0,a=Math.min(e.t,this.t);n<a;)r+=this[n]-e[n],t[n++]=r&this.DM,r>>=this.DB;if(e.t<this.t){for(r-=e.s;n<this.t;)r+=this[n],t[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;n<e.t;)r-=e[n],t[n++]=r&this.DM,r>>=this.DB;r-=e.s}t.s=r<0?-1:0,r<-1?t[n++]=this.DV+r:r>0&&(t[n++]=r),t.t=n,t.clamp()},n.prototype.multiplyTo=function(e,t){var r=this.abs(),a=e.abs(),o=r.t;for(t.t=o+a.t;--o>=0;)t[o]=0;for(o=0;o<a.t;++o)t[o+r.t]=r.am(0,a[o],t,o,0,r.t);t.s=0,t.clamp(),this.s!=e.s&&n.ZERO.subTo(t,t)},n.prototype.squareTo=function(e){for(var t=this.abs(),n=e.t=2*t.t;--n>=0;)e[n]=0;for(n=0;n<t.t-1;++n){var r=t.am(n,t[n],e,2*n,0,1);(e[n+t.t]+=t.am(n+1,2*t[n],e,2*n+1,r,t.t-n-1))>=t.DV&&(e[n+t.t]-=t.DV,e[n+t.t+1]=1)}e.t>0&&(e[e.t-1]+=t.am(n,t[n],e,2*n,0,1)),e.s=0,e.clamp()},n.prototype.divRemTo=function(e,t,a){var o=e.abs();if(!(o.t<=0)){var i=this.abs();if(i.t<o.t)return null!=t&&t.fromInt(0),void(null!=a&&this.copyTo(a));null==a&&(a=r());var s=r(),u=this.s,l=e.s,c=this.DB-d(o[o.t-1]);c>0?(o.lShiftTo(c,s),i.lShiftTo(c,a)):(o.copyTo(s),i.copyTo(a));var p=s.t,f=s[p-1];if(0!=f){var h=f*(1<<this.F1)+(p>1?s[p-2]>>this.F2:0),m=this.FV/h,_=(1<<this.F1)/h,y=1<<this.F2,g=a.t,v=g-p,b=null==t?r():t;for(s.dlShiftTo(v,b),a.compareTo(b)>=0&&(a[a.t++]=1,a.subTo(b,a)),n.ONE.dlShiftTo(p,b),b.subTo(s,s);s.t<p;)s[s.t++]=0;for(;--v>=0;){var w=a[--g]==f?this.DM:Math.floor(a[g]*m+(a[g-1]+y)*_);if((a[g]+=s.am(0,w,a,v,0,p))<w)for(s.dlShiftTo(v,b),a.subTo(b,a);a[g]<--w;)a.subTo(b,a)}null!=t&&(a.drShiftTo(p,t),u!=l&&n.ZERO.subTo(t,t)),a.t=p,a.clamp(),c>0&&a.rShiftTo(c,a),u<0&&n.ZERO.subTo(a,a)}}},n.prototype.invDigit=function(){if(this.t<1)return 0;var e=this[0];if(0==(1&e))return 0;var t=3&e;return(t=(t=(t=(t=t*(2-(15&e)*t)&15)*(2-(255&e)*t)&255)*(2-((65535&e)*t&65535))&65535)*(2-e*t%this.DV)%this.DV)>0?this.DV-t:-t},n.prototype.isEven=function(){return 0==(this.t>0?1&this[0]:this.s)},n.prototype.exp=function(e,t){if(e>4294967295||e<1)return n.ONE;var a=r(),o=r(),i=t.convert(this),s=d(e)-1;for(i.copyTo(a);--s>=0;)if(t.sqrTo(a,o),(e&1<<s)>0)t.mulTo(o,i,a);else{var u=a;a=o,o=u}return t.revert(a)},n.prototype.toString=function(e){if(this.s<0)return"-"+this.negate().toString(e);var t;if(16==e)t=4;else if(8==e)t=3;else if(2==e)t=1;else if(32==e)t=5;else{if(4!=e)return this.toRadix(e);t=2}var n,r=(1<<t)-1,a=!1,o="",i=this.t,s=this.DB-i*this.DB%t;if(i-- >0)for(s<this.DB&&(n=this[i]>>s)>0&&(a=!0,o=u(n));i>=0;)s<t?(n=(this[i]&(1<<s)-1)<<t-s,n|=this[--i]>>(s+=this.DB-t)):(n=this[i]>>(s-=t)&r,s<=0&&(s+=this.DB,--i)),n>0&&(a=!0),a&&(o+=u(n));return a?o:"0"},n.prototype.negate=function(){var e=r();return n.ZERO.subTo(this,e),e},n.prototype.abs=function(){return this.s<0?this.negate():this},n.prototype.compareTo=function(e){var t=this.s-e.s;if(0!=t)return t;var n=this.t;if(0!=(t=n-e.t))return this.s<0?-t:t;for(;--n>=0;)if(0!=(t=this[n]-e[n]))return t;return 0},n.prototype.bitLength=function(){return this.t<=0?0:this.DB*(this.t-1)+d(this[this.t-1]^this.s&this.DM)},n.prototype.mod=function(e){var t=r();return this.abs().divRemTo(e,null,t),this.s<0&&t.compareTo(n.ZERO)>0&&e.subTo(t,t),t},n.prototype.modPowInt=function(e,t){var n;return n=e<256||t.isEven()?new p(t):new f(t),this.exp(e,n)},n.ZERO=c(0),n.ONE=c(1),b.prototype.convert=w,b.prototype.revert=w,b.prototype.mulTo=function(e,t,n){e.multiplyTo(t,n)},b.prototype.sqrTo=function(e,t){e.squareTo(t)},M.prototype.convert=function(e){if(e.s<0||e.t>2*this.m.t)return e.mod(this.m);if(e.compareTo(this.m)<0)return e;var t=r();return e.copyTo(t),this.reduce(t),t},M.prototype.revert=function(e){return e},M.prototype.reduce=function(e){for(e.drShiftTo(this.m.t-1,this.r2),e.t>this.m.t+1&&(e.t=this.m.t+1,e.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);e.compareTo(this.r2)<0;)e.dAddOffset(1,this.m.t+1);for(e.subTo(this.r2,e);e.compareTo(this.m)>=0;)e.subTo(this.m,e)},M.prototype.mulTo=function(e,t,n){e.multiplyTo(t,n),this.reduce(n)},M.prototype.sqrTo=function(e,t){e.squareTo(t),this.reduce(t)};var L,T,k,x=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],E=(1<<26)/x[x.length-1];function S(){var e;e=(new Date).getTime(),T[k++]^=255&e,T[k++]^=e>>8&255,T[k++]^=e>>16&255,T[k++]^=e>>24&255,k>=P&&(k-=P)}if(n.prototype.chunkSize=function(e){return Math.floor(Math.LN2*this.DB/Math.log(e))},n.prototype.toRadix=function(e){if(null==e&&(e=10),0==this.signum()||e<2||e>36)return"0";var t=this.chunkSize(e),n=Math.pow(e,t),a=c(n),o=r(),i=r(),s="";for(this.divRemTo(a,o,i);o.signum()>0;)s=(n+i.intValue()).toString(e).substr(1)+s,o.divRemTo(a,o,i);return i.intValue().toString(e)+s},n.prototype.fromRadix=function(e,t){this.fromInt(0),null==t&&(t=10);for(var r=this.chunkSize(t),a=Math.pow(t,r),o=!1,i=0,s=0,u=0;u<e.length;++u){var c=l(e,u);c<0?"-"==e.charAt(u)&&0==this.signum()&&(o=!0):(s=t*s+c,++i>=r&&(this.dMultiply(a),this.dAddOffset(s,0),i=0,s=0))}i>0&&(this.dMultiply(Math.pow(t,i)),this.dAddOffset(s,0)),o&&n.ZERO.subTo(this,this)},n.prototype.fromNumber=function(e,t,r){if("number"==typeof t)if(e<2)this.fromInt(1);else for(this.fromNumber(e,r),this.testBit(e-1)||this.bitwiseTo(n.ONE.shiftLeft(e-1),m,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(t);)this.dAddOffset(2,0),this.bitLength()>e&&this.subTo(n.ONE.shiftLeft(e-1),this);else{var a=new Array,o=7&e;a.length=1+(e>>3),t.nextBytes(a),o>0?a[0]&=(1<<o)-1:a[0]=0,this.fromString(a,256)}},n.prototype.bitwiseTo=function(e,t,n){var r,a,o=Math.min(e.t,this.t);for(r=0;r<o;++r)n[r]=t(this[r],e[r]);if(e.t<this.t){for(a=e.s&this.DM,r=o;r<this.t;++r)n[r]=t(this[r],a);n.t=this.t}else{for(a=this.s&this.DM,r=o;r<e.t;++r)n[r]=t(a,e[r]);n.t=e.t}n.s=t(this.s,e.s),n.clamp()},n.prototype.changeBit=function(e,t){var r=n.ONE.shiftLeft(e);return this.bitwiseTo(r,t,r),r},n.prototype.addTo=function(e,t){for(var n=0,r=0,a=Math.min(e.t,this.t);n<a;)r+=this[n]+e[n],t[n++]=r&this.DM,r>>=this.DB;if(e.t<this.t){for(r+=e.s;n<this.t;)r+=this[n],t[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;n<e.t;)r+=e[n],t[n++]=r&this.DM,r>>=this.DB;r+=e.s}t.s=r<0?-1:0,r>0?t[n++]=r:r<-1&&(t[n++]=this.DV+r),t.t=n,t.clamp()},n.prototype.dMultiply=function(e){this[this.t]=this.am(0,e-1,this,0,0,this.t),++this.t,this.clamp()},n.prototype.dAddOffset=function(e,t){if(0!=e){for(;this.t<=t;)this[this.t++]=0;for(this[t]+=e;this[t]>=this.DV;)this[t]-=this.DV,++t>=this.t&&(this[this.t++]=0),++this[t]}},n.prototype.multiplyLowerTo=function(e,t,n){var r,a=Math.min(this.t+e.t,t);for(n.s=0,n.t=a;a>0;)n[--a]=0;for(r=n.t-this.t;a<r;++a)n[a+this.t]=this.am(0,e[a],n,a,0,this.t);for(r=Math.min(e.t,t);a<r;++a)this.am(0,e[a],n,a,0,t-a);n.clamp()},n.prototype.multiplyUpperTo=function(e,t,n){--t;var r=n.t=this.t+e.t-t;for(n.s=0;--r>=0;)n[r]=0;for(r=Math.max(t-this.t,0);r<e.t;++r)n[this.t+r-t]=this.am(t-r,e[r],n,0,0,this.t+r-t);n.clamp(),n.drShiftTo(1,n)},n.prototype.modInt=function(e){if(e<=0)return 0;var t=this.DV%e,n=this.s<0?e-1:0;if(this.t>0)if(0==t)n=this[0]%e;else for(var r=this.t-1;r>=0;--r)n=(t*n+this[r])%e;return n},n.prototype.millerRabin=function(e){var t=this.subtract(n.ONE),a=t.getLowestSetBit();if(a<=0)return!1;var o=t.shiftRight(a);(e=e+1>>1)>x.length&&(e=x.length);for(var i=r(),s=0;s<e;++s){i.fromInt(x[Math.floor(Math.random()*x.length)]);var u=i.modPow(o,this);if(0!=u.compareTo(n.ONE)&&0!=u.compareTo(t)){for(var l=1;l++<a&&0!=u.compareTo(t);)if(0==(u=u.modPowInt(2,this)).compareTo(n.ONE))return!1;if(0!=u.compareTo(t))return!1}}return!0},n.prototype.clone=function(){var e=r();return this.copyTo(e),e},n.prototype.intValue=function(){if(this.s<0){if(1==this.t)return this[0]-this.DV;if(0==this.t)return-1}else{if(1==this.t)return this[0];if(0==this.t)return 0}return(this[1]&(1<<32-this.DB)-1)<<this.DB|this[0]},n.prototype.byteValue=function(){return 0==this.t?this.s:this[0]<<24>>24},n.prototype.shortValue=function(){return 0==this.t?this.s:this[0]<<16>>16},n.prototype.signum=function(){return this.s<0?-1:this.t<=0||1==this.t&&this[0]<=0?0:1},n.prototype.toByteArray=function(){var e=this.t,t=new Array;t[0]=this.s;var n,r=this.DB-e*this.DB%8,a=0;if(e-- >0)for(r<this.DB&&(n=this[e]>>r)!=(this.s&this.DM)>>r&&(t[a++]=n|this.s<<this.DB-r);e>=0;)r<8?(n=(this[e]&(1<<r)-1)<<8-r,n|=this[--e]>>(r+=this.DB-8)):(n=this[e]>>(r-=8)&255,r<=0&&(r+=this.DB,--e)),0!=(128&n)&&(n|=-256),0==a&&(128&this.s)!=(128&n)&&++a,(a>0||n!=this.s)&&(t[a++]=n);return t},n.prototype.equals=function(e){return 0==this.compareTo(e)},n.prototype.min=function(e){return this.compareTo(e)<0?this:e},n.prototype.max=function(e){return this.compareTo(e)>0?this:e},n.prototype.and=function(e){var t=r();return this.bitwiseTo(e,h,t),t},n.prototype.or=function(e){var t=r();return this.bitwiseTo(e,m,t),t},n.prototype.xor=function(e){var t=r();return this.bitwiseTo(e,_,t),t},n.prototype.andNot=function(e){var t=r();return this.bitwiseTo(e,y,t),t},n.prototype.not=function(){for(var e=r(),t=0;t<this.t;++t)e[t]=this.DM&~this[t];return e.t=this.t,e.s=~this.s,e},n.prototype.shiftLeft=function(e){var t=r();return e<0?this.rShiftTo(-e,t):this.lShiftTo(e,t),t},n.prototype.shiftRight=function(e){var t=r();return e<0?this.lShiftTo(-e,t):this.rShiftTo(e,t),t},n.prototype.getLowestSetBit=function(){for(var e=0;e<this.t;++e)if(0!=this[e])return e*this.DB+g(this[e]);return this.s<0?this.t*this.DB:-1},n.prototype.bitCount=function(){for(var e=0,t=this.s&this.DM,n=0;n<this.t;++n)e+=v(this[n]^t);return e},n.prototype.testBit=function(e){var t=Math.floor(e/this.DB);return t>=this.t?0!=this.s:0!=(this[t]&1<<e%this.DB)},n.prototype.setBit=function(e){return this.changeBit(e,m)},n.prototype.clearBit=function(e){return this.changeBit(e,y)},n.prototype.flipBit=function(e){return this.changeBit(e,_)},n.prototype.add=function(e){var t=r();return this.addTo(e,t),t},n.prototype.subtract=function(e){var t=r();return this.subTo(e,t),t},n.prototype.multiply=function(e){var t=r();return this.multiplyTo(e,t),t},n.prototype.divide=function(e){var t=r();return this.divRemTo(e,t,null),t},n.prototype.remainder=function(e){var t=r();return this.divRemTo(e,null,t),t},n.prototype.divideAndRemainder=function(e){var t=r(),n=r();return this.divRemTo(e,t,n),new Array(t,n)},n.prototype.modPow=function(e,t){var n,a,o=e.bitLength(),i=c(1);if(o<=0)return i;n=o<18?1:o<48?3:o<144?4:o<768?5:6,a=o<8?new p(t):t.isEven()?new M(t):new f(t);var s=new Array,u=3,l=n-1,h=(1<<n)-1;if(s[1]=a.convert(this),n>1){var m=r();for(a.sqrTo(s[1],m);u<=h;)s[u]=r(),a.mulTo(m,s[u-2],s[u]),u+=2}var _,y,g=e.t-1,v=!0,b=r();for(o=d(e[g])-1;g>=0;){for(o>=l?_=e[g]>>o-l&h:(_=(e[g]&(1<<o+1)-1)<<l-o,g>0&&(_|=e[g-1]>>this.DB+o-l)),u=n;0==(1&_);)_>>=1,--u;if((o-=u)<0&&(o+=this.DB,--g),v)s[_].copyTo(i),v=!1;else{for(;u>1;)a.sqrTo(i,b),a.sqrTo(b,i),u-=2;u>0?a.sqrTo(i,b):(y=i,i=b,b=y),a.mulTo(b,s[_],i)}for(;g>=0&&0==(e[g]&1<<o);)a.sqrTo(i,b),y=i,i=b,b=y,--o<0&&(o=this.DB-1,--g)}return a.revert(i)},n.prototype.modInverse=function(e){var t=e.isEven();if(this.isEven()&&t||0==e.signum())return n.ZERO;for(var r=e.clone(),a=this.clone(),o=c(1),i=c(0),s=c(0),u=c(1);0!=r.signum();){for(;r.isEven();)r.rShiftTo(1,r),t?(o.isEven()&&i.isEven()||(o.addTo(this,o),i.subTo(e,i)),o.rShiftTo(1,o)):i.isEven()||i.subTo(e,i),i.rShiftTo(1,i);for(;a.isEven();)a.rShiftTo(1,a),t?(s.isEven()&&u.isEven()||(s.addTo(this,s),u.subTo(e,u)),s.rShiftTo(1,s)):u.isEven()||u.subTo(e,u),u.rShiftTo(1,u);r.compareTo(a)>=0?(r.subTo(a,r),t&&o.subTo(s,o),i.subTo(u,i)):(a.subTo(r,a),t&&s.subTo(o,s),u.subTo(i,u))}return 0!=a.compareTo(n.ONE)?n.ZERO:u.compareTo(e)>=0?u.subtract(e):u.signum()<0?(u.addTo(e,u),u.signum()<0?u.add(e):u):u},n.prototype.pow=function(e){return this.exp(e,new b)},n.prototype.gcd=function(e){var t=this.s<0?this.negate():this.clone(),n=e.s<0?e.negate():e.clone();if(t.compareTo(n)<0){var r=t;t=n,n=r}var a=t.getLowestSetBit(),o=n.getLowestSetBit();if(o<0)return t;for(a<o&&(o=a),o>0&&(t.rShiftTo(o,t),n.rShiftTo(o,n));t.signum()>0;)(a=t.getLowestSetBit())>0&&t.rShiftTo(a,t),(a=n.getLowestSetBit())>0&&n.rShiftTo(a,n),t.compareTo(n)>=0?(t.subTo(n,t),t.rShiftTo(1,t)):(n.subTo(t,n),n.rShiftTo(1,n));return o>0&&n.lShiftTo(o,n),n},n.prototype.isProbablePrime=function(e){var t,n=this.abs();if(1==n.t&&n[0]<=x[x.length-1]){for(t=0;t<x.length;++t)if(n[0]==x[t])return!0;return!1}if(n.isEven())return!1;for(t=1;t<x.length;){for(var r=x[t],a=t+1;a<x.length&&r<E;)r*=x[a++];for(r=n.modInt(r);t<a;)if(r%x[t++]==0)return!1}return n.millerRabin(e)},n.prototype.square=function(){var e=r();return this.squareTo(e),e},n.prototype.Barrett=M,null==T){var O;if(T=new Array,k=0,"undefined"!=typeof window&&window.crypto)if(window.crypto.getRandomValues){var D=new Uint8Array(32);for(window.crypto.getRandomValues(D),O=0;O<32;++O)T[k++]=D[O]}else if("Netscape"==navigator.appName&&navigator.appVersion<"5"){var Y=window.crypto.random(32);for(O=0;O<Y.length;++O)T[k++]=255&Y.charCodeAt(O)}for(;k<P;)O=Math.floor(65536*Math.random()),T[k++]=O>>>8,T[k++]=255&O;k=0,S()}function A(){if(null==L){for(S(),(L=new j).init(T),k=0;k<T.length;++k)T[k]=0;k=0}return L.next()}function C(){}function j(){this.i=0,this.j=0,this.S=new Array}C.prototype.nextBytes=function(e){var t;for(t=0;t<e.length;++t)e[t]=A()},j.prototype.init=function(e){var t,n,r;for(t=0;t<256;++t)this.S[t]=t;for(n=0,t=0;t<256;++t)r=this.S[t],this.S[t]=this.S[n=n+this.S[t]+e[t%e.length]&255],this.S[n]=r;this.i=0,this.j=0},j.prototype.next=function(){var e;return this.i=this.i+1&255,this.j=this.j+this.S[this.i]&255,e=this.S[this.i],this.S[this.i]=this.S[this.j],this.S[this.j]=e,this.S[e+this.S[this.i]&255]};var P=256;e.exports={default:n,BigInteger:n,SecureRandom:C}}).call(Fe)})),Je={sha1:"3021300906052b0e03021a05000414",sha224:"302d300d06096086480165030402040500041c",sha256:"3031300d060960864801650304020105000420",sha384:"3041300d060960864801650304020205000430",sha512:"3051300d060960864801650304020305000440",md2:"3020300c06082a864886f70d020205000410",md5:"3020300c06082a864886f70d020505000410",ripemd160:"3021300906052b2403020105000414"},Ke={sha256:Be};function $e(e,t){if(this.n=null,this.e=0,!(null!=e&&null!=t&&e.length>0&&t.length>0))throw new Error("Invalid key data");this.n=new qe.BigInteger(e,16),this.e=parseInt(t,16)}$e.prototype.verify=function(e,t){t=t.replace(/[^0-9a-f]|[\s\n]]/gi,"");var n=new qe.BigInteger(t,16);if(n.bitLength()>this.n.bitLength())throw new Error("Signature does not match with the key modulus.");var r=function(e){for(var t in Je){var n=Je[t],r=n.length;if(e.substring(0,r)===n)return{alg:t,hash:e.substring(r)}}return[]}(n.modPowInt(this.e,this.n).toString(16).replace(/^1f+00/,""));if(0===r.length)return!1;if(!Ke.hasOwnProperty(r.alg))throw new Error("Hashing algorithm is not supported.");var a=Ke[r.alg](e).toString();return r.hash===a};for(var Xe=[],Ze=[],Qe="undefined"!=typeof Uint8Array?Uint8Array:Array,et="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",tt=0,nt=et.length;tt<nt;++tt)Xe[tt]=et[tt],Ze[et.charCodeAt(tt)]=tt;Ze["-".charCodeAt(0)]=62,Ze["_".charCodeAt(0)]=63;var rt=function(e){var t,n,r=function(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}(e),a=r[0],o=r[1],i=new Qe(function(e,t,n){return 3*(t+n)/4-n}(0,a,o)),s=0,u=o>0?a-4:a;for(n=0;n<u;n+=4)t=Ze[e.charCodeAt(n)]<<18|Ze[e.charCodeAt(n+1)]<<12|Ze[e.charCodeAt(n+2)]<<6|Ze[e.charCodeAt(n+3)],i[s++]=t>>16&255,i[s++]=t>>8&255,i[s++]=255&t;return 2===o&&(t=Ze[e.charCodeAt(n)]<<2|Ze[e.charCodeAt(n+1)]>>4,i[s++]=255&t),1===o&&(t=Ze[e.charCodeAt(n)]<<10|Ze[e.charCodeAt(n+1)]<<4|Ze[e.charCodeAt(n+2)]>>2,i[s++]=t>>8&255,i[s++]=255&t),i};function at(e){var t=e.length%4;return 0===t?e:e+new Array(4-t+1).join("=")}function ot(e){return e=at(e).replace(/\-/g,"+").replace(/_/g,"/"),decodeURIComponent(function(e){for(var t="",n=0;n<e.length;n++)t+=String.fromCharCode(e[n]);return t}(rt(e)).split("").map((function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)})).join(""))}function it(e){return function(e){for(var t="",n=0;n<e.length;n++){var r=e[n].toString(16);t+=2===r.length?r:"0"+r}return t}(rt(at(e)))}var st=ze((function(e){var t,n;t=Fe,n=function(){function e(e){var t=[];if(0===e.length)return"";if("string"!=typeof e[0])throw new TypeError("Url must be a string. Received "+e[0]);if(e[0].match(/^[^/:]+:\/*$/)&&e.length>1){var n=e.shift();e[0]=n+e[0]}e[0]=e[0].match(/^file:\/\/\//)?e[0].replace(/^([^/:]+):\/*/,"$1:///"):e[0].replace(/^([^/:]+):\/*/,"$1://");for(var r=0;r<e.length;r++){var a=e[r];if("string"!=typeof a)throw new TypeError("Url must be a string. Received "+a);""!==a&&(r>0&&(a=a.replace(/^[\/]+/,"")),a=a.replace(/[\/]+$/,r<e.length-1?"":"/"),t.push(a))}var o=t.join("/"),i=(o=o.replace(/\/(\?|&|#[^!])/g,"$1")).split("?");return i.shift()+(i.length>0?"?":"")+i.join("&")}return function(){return e("object"==typeof arguments[0]?arguments[0]:[].slice.call(arguments))}},e.exports?e.exports=n():t.urljoin=n()}));function ut(e,t){return t=t||{},new Promise((function(n,r){var a=new XMLHttpRequest,o=[],i=[],s={},u=function(){return{ok:2==(a.status/100|0),statusText:a.statusText,status:a.status,url:a.responseURL,text:function(){return Promise.resolve(a.responseText)},json:function(){return Promise.resolve(JSON.parse(a.responseText))},blob:function(){return Promise.resolve(new Blob([a.response]))},clone:u,headers:{keys:function(){return o},entries:function(){return i},get:function(e){return s[e.toLowerCase()]},has:function(e){return e.toLowerCase()in s}}}};for(var l in a.open(t.method||"get",e,!0),a.onload=function(){a.getAllResponseHeaders().replace(/^(.*?):[^\S\n]*([\s\S]*?)$/gm,(function(e,t,n){o.push(t=t.toLowerCase()),i.push([t,n]),s[t]=s[t]?s[t]+","+n:n})),n(u())},a.onerror=r,a.withCredentials="include"==t.credentials,t.headers)a.setRequestHeader(l,t.headers[l]);a.send(t.body||null)}))}function lt(e){if(e.ok)return e.json();var t=new Error(e.statusText);return t.response=e,Promise.reject(t)}function ct(e){this.name="ConfigurationError",this.message=e||""}function dt(e){this.name="TokenValidationError",this.message=e||""}ct.prototype=Error.prototype,dt.prototype=Error.prototype;var pt=function(){function e(){}var t=e.prototype;return t.get=function(){return null},t.has=function(){return null},t.set=function(){return null},e}();Ue.polyfill();var ft=function(e){return"number"==typeof e},ht=function(){return new Date};function mt(e){var t=e||{};if(this.jwksCache=t.jwksCache||new pt,this.expectedAlg=t.expectedAlg||"RS256",this.issuer=t.issuer,this.audience=t.audience,this.leeway=0===t.leeway?0:t.leeway||60,this.jwksURI=t.jwksURI,this.maxAge=t.maxAge,this.__clock="function"==typeof t.__clock?t.__clock:ht,this.leeway<0||this.leeway>300)throw new ct("The leeway should be positive and lower than five minutes.");if("RS256"!==this.expectedAlg)throw new ct('Signature algorithm of "'+this.expectedAlg+'" is not supported. Expected the ID token to be signed with "RS256".')}function _t(e,t){this.plugins=t;for(var n=0;n<this.plugins.length;n++){if(this.plugins[n].version!==se.raw){var r="";throw this.plugins[n].constructor&&this.plugins[n].constructor.name&&(r=this.plugins[n].constructor.name),new Error("Plugin "+r+" version ("+this.plugins[n].version+") is not compatible with the SDK version ("+se.raw+")")}this.plugins[n].setWebAuth(e)}}mt.prototype.verify=function(e,t,n){if(!n&&t&&"function"==typeof t&&(n=t,t=void 0),!e)return n(new dt("ID token is required but missing"),null);var r=this.decode(e);if(r instanceof Error)return n(new dt("ID token could not be decoded"),null);var a=r.encoded.header+"."+r.encoded.payload,o=it(r.encoded.signature),i=r.header.alg,s=r.header.kid,u=r.payload.aud,l=r.payload.sub,c=r.payload.iss,d=r.payload.exp,p=r.payload.nbf,f=r.payload.iat,h=r.payload.azp,m=r.payload.auth_time,_=r.payload.nonce,y=this.__clock(),g=this;if(g.expectedAlg!==i)return n(new dt('Signature algorithm of "'+i+'" is not supported. Expected the ID token to be signed with "RS256".'),null);this.getRsaVerifier(c,s,(function(e,i){if(e)return n(e,null);if(!i.verify(a,o))return n(new dt("Invalid ID token signature."),null);if(!c||"string"!=typeof c)return n(new dt("Issuer (iss) claim must be a string present in the ID token"),null);if(g.issuer!==c)return n(new dt('Issuer (iss) claim mismatch in the ID token, expected "'+g.issuer+'", found "'+c+'"'),null);if(!l||"string"!=typeof l)return n(new dt("Subject (sub) claim must be a string present in the ID token"),null);if(!u||"string"!=typeof u&&!Array.isArray(u))return n(new dt("Audience (aud) claim must be a string or array of strings present in the ID token"),null);if(Array.isArray(u)&&!u.includes(g.audience))return n(new dt('Audience (aud) claim mismatch in the ID token; expected "'+g.audience+'" but was not one of "'+u.join(", ")+'"'),null);if("string"==typeof u&&g.audience!==u)return n(new dt('Audience (aud) claim mismatch in the ID token; expected "'+g.audience+'" but found "'+u+'"'),null);if(t){if(!_||"string"!=typeof _)return n(new dt("Nonce (nonce) claim must be a string present in the ID token"),null);if(_!==t)return n(new dt('Nonce (nonce) claim value mismatch in the ID token; expected "'+t+'", found "'+_+'"'),null)}if(Array.isArray(u)&&u.length>1){if(!h||"string"!=typeof h)return n(new dt("Authorized Party (azp) claim must be a string present in the ID token when Audience (aud) claim has multiple values"),null);if(h!==g.audience)return n(new dt('Authorized Party (azp) claim mismatch in the ID token; expected "'+g.audience+'", found "'+h+'"'),null)}if(!d||!ft(d))return n(new dt("Expiration Time (exp) claim must be a number present in the ID token"),null);if(!f||!ft(f))return n(new dt("Issued At (iat) claim must be a number present in the ID token"),null);var s=d+g.leeway,v=new Date(0);if(v.setUTCSeconds(s),y>v)return n(new dt('Expiration Time (exp) claim error in the ID token; current time "'+y+'" is after expiration time "'+v+'"'),null);if(p&&ft(p)){var b=p-g.leeway,w=new Date(0);if(w.setUTCSeconds(b),y<w)return n(new dt('Not Before Time (nbf) claim error in the ID token; current time "'+y+'" is before the not before time "'+w+'"'),null)}if(g.maxAge){if(!m||!ft(m))return n(new dt("Authentication Time (auth_time) claim must be a number present in the ID token when Max Age (max_age) is specified"),null);var M=m+g.maxAge+g.leeway,L=new Date(0);if(L.setUTCSeconds(M),y>L)return n(new dt('Authentication Time (auth_time) claim in the ID token indicates that too much time has passed since the last end-user authentication. Current time "'+y+'" is after last auth time at "'+L+'"'),null)}return n(null,r.payload)}))},mt.prototype.getRsaVerifier=function(e,t,n){var r=this,a=e+t;Promise.resolve(this.jwksCache.has(a)).then((function(n){return n?r.jwksCache.get(a):(o={jwksURI:r.jwksURI,iss:e,kid:t},("undefined"==typeof fetch?ut:fetch)(o.jwksURI||st(o.iss,".well-known","jwks.json")).then(lt).then((function(e){var t,n,r,a=null;for(t=0;t<e.keys.length&&null===a;t++)(n=e.keys[t]).kid===o.kid&&(a=n);if(!a)throw new Error('Could not find a public key for Key ID (kid) "'+o.kid+'"');return{modulus:it((r=a).n),exp:it(r.e)}})).catch((function(e){throw e})));var o})).then((function(e){if(!e||!e.modulus||!e.exp)throw new Error("Empty keyInfo in response");return Promise.resolve(r.jwksCache.set(a,e)).then((function(){n&&n(null,new $e(e.modulus,e.exp))}))})).catch((function(e){n&&n(e)}))},mt.prototype.decode=function(e){var t,n,r=e.split(".");if(3!==r.length)return new dt("Cannot decode a malformed JWT");try{t=JSON.parse(ot(r[0])),n=JSON.parse(ot(r[1]))}catch(e){return new dt("Token header or payload is not valid JSON")}return{header:t,payload:n,encoded:{header:r[0],payload:r[1],signature:r[2]}}},mt.prototype.validateAccessToken=function(e,t,n,r){if(this.expectedAlg!==t)return r(new dt('Signature algorithm of "'+t+'" is not supported. Expected "'+this.expectedAlg+'"'));var a,o=Be(e),i=Ge.stringify(o),s=i.substring(0,i.length/2),u=Ge.parse(s),l=Ve.stringify(u);return r((a={"+":"-","/":"_","=":""},l.replace(/[+/=]/g,(function(e){return a[e]}))!==n?new dt("Invalid access_token"):null))},_t.prototype.get=function(e){for(var t=0;t<this.plugins.length;t++)if(this.plugins[t].supports(e))return this.plugins[t].init();return null};var yt=function(e){var t=new Uint8Array(e),n=[],r="0123456789ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvwxyz-._~",a=ke.getWindow().crypto||ke.getWindow().msCrypto;if(!a)return null;for(var o=a.getRandomValues(t),i=0;i<o.length;i++)n.push(r[o[i]%r.length]);return n.join("")};function gt(e){var t=e.transaction||{};this.namespace=t.namespace||"com.auth0.auth.",this.keyLength=t.keyLength||32,this.storage=new Ye(e),this.options=e}function vt(e){if(this.url=e.url,this.callback=e.callback,this.timeout=e.timeout||6e4,this.timeoutCallback=e.timeoutCallback||null,this.eventListenerType=e.eventListenerType||"message",this.iframe=null,this.timeoutHandle=null,this._destroyTimeout=null,this.transientMessageEventListener=null,this.proxyEventListener=null,this.eventValidator=e.eventValidator||{isValid:function(){return!0}},"function"!=typeof this.callback)throw new Error("options.callback must be a function")}function bt(e){this.webAuth=e,this.warn=new Oe(e.baseOptions)}function wt(e,t){this.webAuth=e,this.baseOptions=t,this.request=new Le(t),this.webMessageHandler=new bt(e),this.storage=new Ye(t)}function Mt(e,t){return["co/verifier",encodeURIComponent(e),encodeURIComponent(t)].join("/")}function Lt(e,t){this.webAuth=e,this.baseOptions=t,this.crossOriginAuthentication=new wt(e,this.baseOptions),this.warn=new Oe({disableWarnings:!!t._disableDeprecationWarnings})}gt.prototype.process=function(e){if(!e.responseType)throw new Error("responseType is required");var t=e.realm||e.connection,n=-1!==e.responseType.indexOf("id_token"),r=this.generateTransaction(e.appState,e.state,e.nonce,t,n,e.organization);return e.state||(e.state=r.state),n&&!e.nonce&&(e.nonce=r.nonce),e},gt.prototype.generateTransaction=function(e,t,n,r,a,o){if(t=t||yt(this.keyLength),n=n||(a?yt(this.keyLength):null),ke.getWindow().location.host!==this.options.domain){var i={nonce:n,appState:e,state:t,lastUsedConnection:r};o&&(i.organization=o),this.storage.setItem(this.namespace+t,i,{expires:1/48})}return{state:t,nonce:n}},gt.prototype.getStoredTransaction=function(e){var t;return t=this.storage.getItem(this.namespace+e),this.clearTransaction(e),t},gt.prototype.clearTransaction=function(e){this.storage.removeItem(this.namespace+e)},vt.prototype.init=function(){var e=this,t=ke.getWindow();switch(this.iframe=t.document.createElement("iframe"),this.iframe.style.display="none",this.proxyEventListener=function(t){e.eventListener(t)},this.eventListenerType){case"message":this.eventSourceObject=t;break;case"load":this.eventSourceObject=this.iframe;break;default:throw new Error("Unsupported event listener type: "+this.eventListenerType)}this.eventSourceObject.addEventListener(this.eventListenerType,this.proxyEventListener,!1),t.document.body.appendChild(this.iframe),this.iframe.src=this.url,this.timeoutHandle=setTimeout((function(){e.timeoutHandler()}),this.timeout)},vt.prototype.eventListener=function(e){var t={event:e,sourceObject:this.eventSourceObject};this.eventValidator.isValid(t)&&(this.destroy(),this.callback(t))},vt.prototype.timeoutHandler=function(){this.destroy(),this.timeoutCallback&&this.timeoutCallback()},vt.prototype.destroy=function(){var e=this;clearTimeout(this.timeoutHandle),this._destroyTimeout=setTimeout((function(){e.eventSourceObject.removeEventListener(e.eventListenerType,e.proxyEventListener,!1),e.iframe.parentNode&&e.iframe.parentNode.removeChild(e.iframe)}),0)},bt.prototype.run=function(e,t){var n=this;e.responseMode="web_message",e.prompt="none";var r=ke.getOrigin(),a=be.getOriginFromUrl(e.redirectUri);if(a&&r!==a)return t({error:"origin_mismatch",error_description:"The redirectUri's origin ("+a+") should match the window's origin ("+r+")."});!function(e,t,n){new vt({url:e,eventListenerType:"message",callback:function(e){n(null,e)},timeout:t.timeout,eventValidator:{isValid:function(e){return"authorization_response"===e.event.data.type&&t.state===e.event.data.response.state}},timeoutCallback:function(){n({error:"timeout",error_description:"Timeout during executing web_message communication",state:t.state})}}).init()}(this.webAuth.client.buildAuthorizeUrl(e),e,(function(r,a){var o=r;if(!r&&a.event.data.response.error&&(o=a.event.data.response),!o){var i=a.event.data.response;return n.webAuth.validateAuthenticationResponse(e,i,t)}return"consent_required"===o.error&&"localhost"===ke.getWindow().location.hostname&&n.warn.warning("Consent Required. Consent can't be skipped on localhost. Read more here: https://auth0.com/docs/api-auth/user-consent#skipping-consent-for-first-party-clients"),n.webAuth.transactionManager.clearTransaction(o.state),t(be.pick(o,["error","error_description"]))}))},wt.prototype.login=function(e,t){var n=this,r=i(this.baseOptions.rootUrl,"/co/authenticate");e.username=e.username||e.email,delete e.email;var a={client_id:e.clientID||this.baseOptions.clientID,username:e.username};e.password&&(a.password=e.password),e.otp&&(a.otp=e.otp);var o=e.realm||this.baseOptions.realm;if(o){var s=e.credentialType||this.baseOptions.credentialType||"http://auth0.com/oauth/grant-type/password-realm";a.realm=o,a.credential_type=s}else a.credential_type="password";this.request.post(r).withCredentials().send(a).end((function(r,a){if(r){var o=r.response&&r.response.body||{error:"request_error",error_description:JSON.stringify(r)};return Pe(t,{forceLegacyError:!0})(o)}function i(){var r=!0===e.popup;e=be.blacklist(e,["password","credentialType","otp","popup","onRedirecting"]);var o=be.merge(e).with({loginTicket:a.body.login_ticket}),i=Mt(n.baseOptions.rootUrl,a.body.co_id);n.storage.setItem(i,a.body.co_verifier,{expires:1/96}),r?n.webMessageHandler.run(o,Pe(t,{forceLegacyError:!0})):n.webAuth.authorize(o)}"function"==typeof e.onRedirecting?e.onRedirecting(i):i()}))},wt.prototype.callback=function(){var e=decodeURIComponent(function(e){var t=("&"+ke.getWindow().location.hash.substring(1)).split("&origin=");if(2===t.length)return t.pop().split("&").shift()}()),t=ke.getWindow(),n=this;t.addEventListener("message",(function(e){if("co_verifier_request"===e.data.type){var t=Mt(e.origin,e.data.request.id),r=function(e,t){try{var n=e.getItem(t);return e.removeItem(t),n||""}catch(e){return""}}(n.storage,t);e.source.postMessage({type:"co_verifier_response",response:{verifier:r}},e.origin)}})),t.parent.postMessage({type:"ready"},e)},Lt.prototype.loginWithCredentials=function(e,t){e.realm=e.realm||e.connection,delete e.connection,this.crossOriginAuthentication.login(e,t)},Lt.prototype.signupAndLogin=function(e,t){var n=this;return this.webAuth.client.dbConnection.signup(e,(function(r){return r?t(r):(e.realm=e.realm||e.connection,delete e.connection,n.webAuth.login(e,t))}))};var Tt=o((function(e){var t=function(){function e(e,t,n){e.attachEvent?e.attachEvent("on"+t,n):e.addEventListener&&e.addEventListener(t,n,!1)}function t(e,t,n){e.detachEvent?e.detachEvent("on"+t,n):e.removeEventListener&&e.removeEventListener(t,n,!1)}function n(e){/^https?:\/\//.test(e)||(e=window.location.href);var t=/^(https?:\/\/[\-_a-zA-Z\.0-9:]+)/.exec(e);return t?t[1]:e}var r=function(){if("undefined"==typeof navigator)return!1;var e=-1,t=navigator.userAgent;return"Microsoft Internet Explorer"===navigator.appName?null!=new RegExp("MSIE ([0-9]{1,}[.0-9]{0,})").exec(t)&&(e=parseFloat(RegExp.$1)):t.indexOf("Trident")>-1&&null!==new RegExp("rv:([0-9]{2,2}[.0-9]{0,})").exec(t)&&(e=parseFloat(RegExp.$1)),e>=8}();return"undefined"!=typeof window&&window.JSON&&window.JSON.stringify&&window.JSON.parse&&window.postMessage?{open:function(a,o){if(!o)throw"missing required callback argument";var i,s;a.url||(i="missing required 'url' parameter"),a.relay_url||(i="missing required 'relay_url' parameter"),i&&setTimeout((function(){o(i)}),0),a.window_name||(a.window_name=null),a.window_features&&!function(){try{var e=navigator.userAgent;return-1!=e.indexOf("Fennec/")||-1!=e.indexOf("Firefox/")&&-1!=e.indexOf("Android")}catch(e){}return!1}()||(a.window_features=void 0);var u,l=a.origin||n(a.url);if(l!==n(a.relay_url))return setTimeout((function(){o("invalid arguments: origin of url and relay_url must match")}),0);r&&((s=document.createElement("iframe")).setAttribute("src",a.relay_url),s.style.display="none",s.setAttribute("name","__winchan_relay_frame"),document.body.appendChild(s),u=s.contentWindow);var c=a.popup||window.open(a.url,a.window_name,a.window_features);a.popup&&(c.location.href=a.url),u||(u=c);var d=setInterval((function(){c&&c.closed&&(f(),o&&(o("User closed the popup window"),o=null))}),500),p=JSON.stringify({a:"request",d:a.params});function f(){if(s&&document.body.removeChild(s),s=void 0,d&&(d=clearInterval(d)),t(window,"message",h),t(window,"unload",f),c)try{c.close()}catch(e){u.postMessage("die",l)}c=u=void 0}function h(e){if(e.origin===l){try{var t=JSON.parse(e.data)}catch(e){if(o)return o(e);throw e}"ready"===t.a?u.postMessage(p,l):"error"===t.a?(f(),o&&(o(t.d),o=null)):"response"===t.a&&(f(),o&&(o(null,t.d),o=null))}}return e(window,"unload",f),e(window,"message",h),{originalPopup:c,close:f,focus:function(){if(c)try{c.focus()}catch(e){}}}},onOpen:function(n){var a="*",o=r?function(){for(var e=window.opener.frames,t=e.length-1;t>=0;t--)try{if(e[t].location.protocol===window.location.protocol&&e[t].location.host===window.location.host&&"__winchan_relay_frame"===e[t].name)return e[t]}catch(e){}}():window.opener;if(!o)throw"can't find relay frame";function i(e){e=JSON.stringify(e),r?o.doPost(e,a):o.postMessage(e,a)}function s(e){if("die"===e.data)try{window.close()}catch(e){}}e(r?o:window,"message",(function e(r){var o;try{o=JSON.parse(r.data)}catch(e){}o&&"request"===o.a&&(t(window,"message",e),a=r.origin,n&&setTimeout((function(){n(a,o.d,(function(e){n=void 0,i({a:"response",d:e})}))}),0))})),e(r?o:window,"message",s);try{i({a:"ready"})}catch(t){e(o,"load",(function(e){i({a:"ready"})}))}var u=function(){try{t(r?o:window,"message",s)}catch(e){}n&&i({a:"error",d:"client closed window"}),n=void 0;try{window.close()}catch(e){}};return e(window,"unload",u),{detach:function(){t(window,"unload",u)}}}}:{open:function(e,t,n,r){setTimeout((function(){r("unsupported browser")}),0)},onOpen:function(e){setTimeout((function(){e("unsupported browser")}),0)}}}();e.exports&&(e.exports=t)})),kt=function(e){/^https?:\/\//.test(e)||(e=window.location.href);var t=/^(https?:\/\/[-_a-zA-Z.0-9:]+)/.exec(e);return t?t[1]:e};function xt(){this._current_popup=null}function Et(e,t){this.baseOptions=t,this.baseOptions.popupOrigin=t.popupOrigin,this.client=e.client,this.webAuth=e,this.transactionManager=new gt(this.baseOptions),this.crossOriginAuthentication=new wt(e,this.baseOptions),this.warn=new Oe({disableWarnings:!!t._disableDeprecationWarnings})}function St(e){this.authenticationUrl=e.authenticationUrl,this.timeout=e.timeout||6e4,this.handler=null,this.postMessageDataType=e.postMessageDataType||!1,this.postMessageOrigin=e.postMessageOrigin||ke.getWindow().location.origin||ke.getWindow().location.protocol+"//"+ke.getWindow().location.hostname+(ke.getWindow().location.port?":"+ke.getWindow().location.port:"")}function Ot(e){this.baseOptions=e,this.request=new Le(e),this.transactionManager=new gt(this.baseOptions)}function Dt(e,t){this.baseOptions=t,this.client=e,this.baseOptions.universalLoginPage=!0,this.request=new Le(this.baseOptions),this.warn=new Oe({disableWarnings:!!t._disableDeprecationWarnings})}xt.prototype.calculatePosition=function(e){var t=e.width||500,n=e.height||600,r=ke.getWindow(),a=void 0!==r.screenX?r.screenX:r.screenLeft,o=void 0!==r.screenY?r.screenY:r.screenTop,i=void 0!==r.outerWidth?r.outerWidth:r.document.body.clientWidth,s=void 0!==r.outerHeight?r.outerHeight:r.document.body.clientHeight;return{width:t,height:n,left:e.left||a+(i-t)/2,top:e.top||o+(s-n)/2}},xt.prototype.preload=function(e){var t=this,n=ke.getWindow(),r=this.calculatePosition(e.popupOptions||{}),a=be.merge(r).with(e.popupOptions),o=e.url||"about:blank",i=Y(a,{encode:!1,delimiter:","});return this._current_popup&&!this._current_popup.closed||(this._current_popup=n.open(o,"auth0_signup_popup",i),this._current_popup.kill=function(){this.close(),t._current_popup=null}),this._current_popup},xt.prototype.load=function(e,t,n,r){var a=this,o=this.calculatePosition(n.popupOptions||{}),i=be.merge(o).with(n.popupOptions),s=be.merge({url:e,relay_url:t,window_features:Y(i,{delimiter:",",encode:!1}),popup:this._current_popup}).with(n),u=Tt.open(s,(function(e,t){if(!e||"SyntaxError"!==e.name)return a._current_popup=null,r(e,t)}));return u.focus(),u},Et.prototype.buildPopupHandler=function(){var e=this.baseOptions.plugins.get("popup.getPopupHandler");return e?e.getPopupHandler():new xt},Et.prototype.preload=function(e){e=e||{};var t=this.buildPopupHandler();return t.preload(e),t},Et.prototype.getPopupHandler=function(e,t){return e.popupHandler?e.popupHandler:t?this.preload(e):this.buildPopupHandler()},Et.prototype.callback=function(e){var t=this,n=ke.getWindow(),r=(e=e||{}).popupOrigin||this.baseOptions.popupOrigin||ke.getOrigin();n.opener?Tt.onOpen((function(n,a,o){if(n!==r)return o({error:"origin_mismatch",error_description:"The popup's origin ("+n+") should match the `popupOrigin` parameter ("+r+")."});t.webAuth.parseHash(e||{},(function(e,t){return o(e||t)}))})):n.doPost=function(e){n.parent&&n.parent.postMessage(e,r)}},Et.prototype.authorize=function(e,t){var n,r,a={},o=this.baseOptions.plugins.get("popup.authorize"),s=be.merge(this.baseOptions,["clientID","scope","domain","audience","tenant","responseType","redirectUri","_csrf","state","_intstate","nonce","organization","invitation"]).with(be.blacklist(e,["popupHandler"]));return pe.check(s,{type:"object",message:"options parameter is not valid"},{responseType:{type:"string",message:"responseType option is required"}}),r=i(this.baseOptions.rootUrl,"relay.html"),e.owp?s.owp=!0:(a.origin=kt(s.redirectUri),r=s.redirectUri),e.popupOptions&&(a.popupOptions=be.pick(e.popupOptions,["width","height","top","left"])),o&&(s=o.processParams(s)),(s=this.transactionManager.process(s)).scope=s.scope||"openid profile email",delete s.domain,n=this.client.buildAuthorizeUrl(s),this.getPopupHandler(e).load(n,r,a,Pe(t,{keepOriginalCasing:!0}))},Et.prototype.loginWithCredentials=function(e,t){e.realm=e.realm||e.connection,e.popup=!0,e=be.merge(this.baseOptions,["redirectUri","responseType","state","nonce"]).with(be.blacklist(e,["popupHandler","connection"])),e=this.transactionManager.process(e),this.crossOriginAuthentication.login(e,t)},Et.prototype.passwordlessVerify=function(e,t){var n=this;return this.client.passwordless.verify(be.blacklist(e,["popupHandler"]),(function(r){if(r)return t(r);e.username=e.phoneNumber||e.email,e.password=e.verificationCode,delete e.email,delete e.phoneNumber,delete e.verificationCode,delete e.type,n.client.loginWithResourceOwner(e,t)}))},Et.prototype.signupAndLogin=function(e,t){var n=this;return this.client.dbConnection.signup(e,(function(r){if(r)return t(r);n.loginWithCredentials(e,t)}))},St.create=function(e){return new St(e)},St.prototype.login=function(e,t){this.handler=new vt({auth0:this.auth0,url:this.authenticationUrl,eventListenerType:e?"message":"load",callback:this.getCallbackHandler(t,e),timeout:this.timeout,eventValidator:this.getEventValidator(),timeoutCallback:function(){t(null,"#error=timeout&error_description=Timeout+during+authentication+renew.")},usePostMessage:e||!1}),this.handler.init()},St.prototype.getEventValidator=function(){var e=this;return{isValid:function(t){switch(t.event.type){case"message":return t.event.origin===e.postMessageOrigin&&t.event.source===e.handler.iframe.contentWindow&&(!1===e.postMessageDataType||t.event.data.type&&t.event.data.type===e.postMessageDataType);case"load":if("about:"===t.sourceObject.contentWindow.location.protocol)return!1;default:return!0}}}},St.prototype.getCallbackHandler=function(e,t){return function(n){var r;r=t?"object"==typeof n.event.data&&n.event.data.hash?n.event.data.hash:n.event.data:n.sourceObject.contentWindow.location.hash,e(null,r)}},Ot.prototype.login=function(e,t){var n,r;return n=i(this.baseOptions.rootUrl,"usernamepassword","login"),e.username=e.username||e.email,e=be.blacklist(e,["email","onRedirecting"]),r=be.merge(this.baseOptions,["clientID","redirectUri","tenant","responseType","responseMode","scope","audience"]).with(e),r=this.transactionManager.process(r),r=be.toSnakeCase(r,["auth0Client"]),this.request.post(n).send(r).end(Pe(t))},Ot.prototype.callback=function(e){var t,n=ke.getDocument();(t=n.createElement("div")).innerHTML=e,n.body.appendChild(t).children[0].submit()},Dt.prototype.login=function(e,t){if(ke.getWindow().location.host!==this.baseOptions.domain)throw new Error("This method is meant to be used only inside the Universal Login Page.");var n,r=be.merge(this.baseOptions,["clientID","redirectUri","tenant","responseType","responseMode","scope","audience","_csrf","state","_intstate","nonce"]).with(e);return pe.check(r,{type:"object",message:"options parameter is not valid"},{responseType:{type:"string",message:"responseType option is required"}}),(n=new Ot(this.baseOptions)).login(r,(function(r,a){if(r)return t(r);function o(){n.callback(a)}if("function"==typeof e.onRedirecting)return e.onRedirecting((function(){o()}));o()}))},Dt.prototype.signupAndLogin=function(e,t){var n=this;return n.client.client.dbConnection.signup(e,(function(r){return r?t(r):n.login(e,t)}))},Dt.prototype.getSSOData=function(e,t){var n,r="";return"function"==typeof e&&(t=e,e=!1),pe.check(e,{type:"boolean",message:"withActiveDirectories parameter is not valid"}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),e&&(r="?"+Y({ldaps:1,client_id:this.baseOptions.clientID})),n=i(this.baseOptions.rootUrl,"user","ssodata",r),this.request.get(n,{noHeaders:!0}).withCredentials().end(Pe(t))};var Yt=function(){},At={lang:"en",templates:{auth0:function(e){var t="code"===e.type?"Enter the code shown above":"Solve the formula shown above";return'<div class="captcha-challenge">\n <img src="'+e.image+'" />\n <button type="button" class="captcha-reload">↺</button>\n</div>\n<input type="text" name="captcha"\n class="form-control captcha-control"\n placeholder="'+t+'" />'},recaptcha_v2:function(){return'<div class="recaptcha" ></div><input type="hidden" name="captcha" />'},recaptcha_enterprise:function(){return'<div class="recaptcha" ></div><input type="hidden" name="captcha" />'},error:function(){return'<div class="error" style="color: red;">Error getting the bot detection challenge. Please contact the system administrator.</div>'}}};function Ct(e){switch(e){case"recaptcha_v2":return window.grecaptcha;case"recaptcha_enterprise":return window.grecaptcha.enterprise;default:throw new Error("Unknown captcha provider")}}var jt=function(e,t,n,r){function a(r){r=r||Yt,e.getChallenge((function(e,o){return e?(t.innerHTML=n.templates.error(e),r(e)):o.required?(t.style.display="","auth0"===o.provider?function(e,t,n,r){e.innerHTML=t.templates[n.provider](n),e.querySelector(".captcha-reload").addEventListener("click",(function(e){e.preventDefault(),r()}))}(t,n,o,a):"recaptcha_v2"!==o.provider&&"recaptcha_enterprise"!==o.provider||function(e,t,n){var r=e.hasAttribute("data-wid")&&e.getAttribute("data-wid");function a(t){e.querySelector('input[name="captcha"]').value=t||""}if(r)return a(),void Ct(n.provider).reset(r);e.innerHTML=t.templates[n.provider](n);var o=e.querySelector(".recaptcha");!function(e,t,n){var r="recaptchaCallback_"+Math.floor(1000001*Math.random());window[r]=function(){delete window[r],n()};var a=window.document.createElement("script");a.src=function(e,t,n){switch(e){case"recaptcha_v2":return"https://www.recaptcha.net/recaptcha/api.js?hl="+t+"&onload="+n;case"recaptcha_enterprise":return"https://www.recaptcha.net/recaptcha/enterprise.js?render=explicit&hl="+t+"&onload="+n;default:throw new Error("Unknown captcha provider")}}(t.provider,t.lang,r),a.async=!0,window.document.body.appendChild(a)}(0,{lang:t.lang,provider:n.provider},(function(){var t=Ct(n.provider);r=t.render(o,{callback:a,"expired-callback":function(){a()},"error-callback":function(){a()},sitekey:n.siteKey}),e.setAttribute("data-wid",r)}))}(t,n,o),void r()):(t.style.display="none",void(t.innerHTML=""))}))}return n=be.merge(At).with(n||{}),a(r),{reload:a,getValue:function(){var e=t.querySelector('input[name="captcha"]');if(e)return e.value}}};function Pt(){return new Date}function Ht(e){pe.check(e,{type:"object",message:"options parameter is not valid"},{domain:{type:"string",message:"domain option is required"},clientID:{type:"string",message:"clientID option is required"},responseType:{optional:!0,type:"string",message:"responseType is not valid"},responseMode:{optional:!0,type:"string",message:"responseMode is not valid"},redirectUri:{optional:!0,type:"string",message:"redirectUri is not valid"},scope:{optional:!0,type:"string",message:"scope is not valid"},audience:{optional:!0,type:"string",message:"audience is not valid"},popupOrigin:{optional:!0,type:"string",message:"popupOrigin is not valid"},leeway:{optional:!0,type:"number",message:"leeway is not valid"},plugins:{optional:!0,type:"array",message:"plugins is not valid"},maxAge:{optional:!0,type:"number",message:"maxAge is not valid"},_disableDeprecationWarnings:{optional:!0,type:"boolean",message:"_disableDeprecationWarnings option is not valid"},_sendTelemetry:{optional:!0,type:"boolean",message:"_sendTelemetry option is not valid"},_telemetryInfo:{optional:!0,type:"object",message:"_telemetryInfo option is not valid"},_timesToRetryFailedRequests:{optional:!0,type:"number",message:"_timesToRetryFailedRequests option is not valid"}}),e.overrides&&pe.check(e.overrides,{type:"object",message:"overrides option is not valid"},{__tenant:{optional:!0,type:"string",message:"__tenant option is required"},__token_issuer:{optional:!0,type:"string",message:"__token_issuer option is required"},__jwks_uri:{optional:!0,type:"string",message:"__jwks_uri is required"}}),this.baseOptions=e,this.baseOptions.plugins=new _t(this,this.baseOptions.plugins||[]),this.baseOptions._sendTelemetry=!1!==this.baseOptions._sendTelemetry||this.baseOptions._sendTelemetry,this.baseOptions._timesToRetryFailedRequests=e._timesToRetryFailedRequests?parseInt(e._timesToRetryFailedRequests,0):0,this.baseOptions.tenant=this.baseOptions.overrides&&this.baseOptions.overrides.__tenant||this.baseOptions.domain.split(".")[0],this.baseOptions.token_issuer=this.baseOptions.overrides&&this.baseOptions.overrides.__token_issuer||"https://"+this.baseOptions.domain+"/",this.baseOptions.jwksURI=this.baseOptions.overrides&&this.baseOptions.overrides.__jwks_uri,this.transactionManager=new gt(this.baseOptions),this.client=new Rt(this.baseOptions),this.redirect=new Lt(this,this.baseOptions),this.popup=new Et(this,this.baseOptions),this.crossOriginAuthentication=new wt(this,this.baseOptions),this.webMessageHandler=new bt(this),this._universalLogin=new Dt(this,this.baseOptions),this.ssodataStorage=new Ae(this.baseOptions)}function It(e,t){this.baseOptions=t,this.request=e}function Nt(e,t){this.baseOptions=t,this.request=e}function Rt(e,t){2===arguments.length?this.auth0=e:t=e,pe.check(t,{type:"object",message:"options parameter is not valid"},{domain:{type:"string",message:"domain option is required"},clientID:{type:"string",message:"clientID option is required"},responseType:{optional:!0,type:"string",message:"responseType is not valid"},responseMode:{optional:!0,type:"string",message:"responseMode is not valid"},redirectUri:{optional:!0,type:"string",message:"redirectUri is not valid"},scope:{optional:!0,type:"string",message:"scope is not valid"},audience:{optional:!0,type:"string",message:"audience is not valid"},_disableDeprecationWarnings:{optional:!0,type:"boolean",message:"_disableDeprecationWarnings option is not valid"},_sendTelemetry:{optional:!0,type:"boolean",message:"_sendTelemetry option is not valid"},_telemetryInfo:{optional:!0,type:"object",message:"_telemetryInfo option is not valid"}}),this.baseOptions=t,this.baseOptions._sendTelemetry=!1!==this.baseOptions._sendTelemetry||this.baseOptions._sendTelemetry,this.baseOptions.rootUrl=this.baseOptions.domain&&0===this.baseOptions.domain.toLowerCase().indexOf("http")?this.baseOptions.domain:"https://"+this.baseOptions.domain,this.request=new Le(this.baseOptions),this.passwordless=new It(this.request,this.baseOptions),this.dbConnection=new Nt(this.request,this.baseOptions),this.warn=new Oe({disableWarnings:!!t._disableDeprecationWarnings}),this.ssodataStorage=new Ae(this.baseOptions)}function Ft(e){pe.check(e,{type:"object",message:"options parameter is not valid"},{domain:{type:"string",message:"domain option is required"},token:{type:"string",message:"token option is required"},_sendTelemetry:{optional:!0,type:"boolean",message:"_sendTelemetry option is not valid"},_telemetryInfo:{optional:!0,type:"object",message:"_telemetryInfo option is not valid"}}),this.baseOptions=e,this.baseOptions.headers={Authorization:"Bearer "+this.baseOptions.token},this.request=new Le(this.baseOptions),this.baseOptions.rootUrl=i("https://"+this.baseOptions.domain,"api","v2")}Ht.prototype.parseHash=function(e,t){var n,r;t||"function"!=typeof e?e=e||{}:(t=e,e={});var a=ke.getWindow(),o=void 0===e.hash?a.location.hash:e.hash;if((n=function(e,t){var n=function(e){if(!e)return E;if(null!==e.decoder&&void 0!==e.decoder&&"function"!=typeof e.decoder)throw new TypeError("Decoder has to be a function.");if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var t=void 0===e.charset?E.charset:e.charset;return{allowDots:void 0===e.allowDots?E.allowDots:!!e.allowDots,allowPrototypes:"boolean"==typeof e.allowPrototypes?e.allowPrototypes:E.allowPrototypes,arrayLimit:"number"==typeof e.arrayLimit?e.arrayLimit:E.arrayLimit,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:E.charsetSentinel,comma:"boolean"==typeof e.comma?e.comma:E.comma,decoder:"function"==typeof e.decoder?e.decoder:E.decoder,delimiter:"string"==typeof e.delimiter||d.isRegExp(e.delimiter)?e.delimiter:E.delimiter,depth:"number"==typeof e.depth||!1===e.depth?+e.depth:E.depth,ignoreQueryPrefix:!0===e.ignoreQueryPrefix,interpretNumericEntities:"boolean"==typeof e.interpretNumericEntities?e.interpretNumericEntities:E.interpretNumericEntities,parameterLimit:"number"==typeof e.parameterLimit?e.parameterLimit:E.parameterLimit,parseArrays:!1!==e.parseArrays,plainObjects:"boolean"==typeof e.plainObjects?e.plainObjects:E.plainObjects,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:E.strictNullHandling}}(t);if(""===e||null==e)return n.plainObjects?Object.create(null):{};for(var r="string"==typeof e?function(e,t){var n,r={},a=t.ignoreQueryPrefix?e.replace(/^\?/,""):e,o=t.parameterLimit===1/0?void 0:t.parameterLimit,i=a.split(t.delimiter,o),s=-1,u=t.charset;if(t.charsetSentinel)for(n=0;n<i.length;++n)0===i[n].indexOf("utf8=")&&("utf8=%E2%9C%93"===i[n]?u="utf-8":"utf8=%26%2310003%3B"===i[n]&&(u="iso-8859-1"),s=n,n=i.length);for(n=0;n<i.length;++n)if(n!==s){var l,c,p=i[n],f=p.indexOf("]="),h=-1===f?p.indexOf("="):f+1;-1===h?(l=t.decoder(p,E.decoder,u,"key"),c=t.strictNullHandling?null:""):(l=t.decoder(p.slice(0,h),E.decoder,u,"key"),c=d.maybeMap(O(p.slice(h+1),t),(function(e){return t.decoder(e,E.decoder,u,"value")}))),c&&t.interpretNumericEntities&&"iso-8859-1"===u&&(c=S(c)),p.indexOf("[]=")>-1&&(c=x(c)?[c]:c),k.call(r,l)?r[l]=d.combine(r[l],c):r[l]=c}return r}(e,n):e,a=n.plainObjects?Object.create(null):{},o=Object.keys(r),i=0;i<o.length;++i){var s=o[i],u=D(s,r[s],n,"string"==typeof e);a=d.merge(a,u,n)}return d.compact(a)}(o=o.replace(/^#?\/?/,""))).hasOwnProperty("error"))return r=je.buildResponse(n.error,n.error_description),n.state&&(r.state=n.state),t(r);if(!n.hasOwnProperty("access_token")&&!n.hasOwnProperty("id_token")&&!n.hasOwnProperty("refresh_token"))return t(null,null);var i=(this.baseOptions.responseType||e.responseType||"").split(" ");return i.length>0&&-1!==i.indexOf("token")&&!n.hasOwnProperty("access_token")?t(je.buildResponse("invalid_hash","response_type contains `token`, but the parsed hash does not contain an `access_token` property")):i.length>0&&-1!==i.indexOf("id_token")&&!n.hasOwnProperty("id_token")?t(je.buildResponse("invalid_hash","response_type contains `id_token`, but the parsed hash does not contain an `id_token` property")):this.validateAuthenticationResponse(e,n,t)},Ht.prototype.validateAuthenticationResponse=function(e,t,n){var r=this;e.__enableIdPInitiatedLogin=e.__enableIdPInitiatedLogin||e.__enableImpersonation;var a=t.state,o=this.transactionManager.getStoredTransaction(a),i=e.state||o&&o.state||null,s=i===a;if((a||i||!e.__enableIdPInitiatedLogin)&&!s)return n({error:"invalid_token",errorDescription:"`state` does not match."});var u=e.nonce||o&&o.nonce||null,l=o&&o.organization,c=e.state||o&&o.appState||null,d=function(e,a){return e?n(e):(o&&o.lastUsedConnection&&(a&&(i=a.sub),r.ssodataStorage.set(o.lastUsedConnection,i)),n(null,function(e,t,n){return{accessToken:e.access_token||null,idToken:e.id_token||null,idTokenPayload:n||null,appState:t||null,refreshToken:e.refresh_token||null,state:e.state||null,expiresIn:e.expires_in?parseInt(e.expires_in,10):null,tokenType:e.token_type||null,scope:e.scope||null}}(t,c,a)));var i};return t.id_token?this.validateToken(t.id_token,u,(function(e,n){if(!e){if(l){if(!n.org_id)return d(je.invalidToken("Organization Id (org_id) claim must be a string present in the ID token"));if(n.org_id!==l)return d(je.invalidToken('Organization Id (org_id) claim value mismatch in the ID token; expected "'+l+'", found "'+n.org_id+'"'))}return t.access_token&&n.at_hash?(new mt).validateAccessToken(t.access_token,"RS256",n.at_hash,(function(e){return e?d(je.invalidToken(e.message)):d(null,n)})):d(null,n)}if("invalid_token"!==e.error||e.errorDescription&&e.errorDescription.indexOf("Nonce (nonce) claim value mismatch in the ID token")>-1)return d(e);var a=(new mt).decode(t.id_token);return"HS256"!==a.header.alg?d(e):(a.payload.nonce||null)!==u?d({error:"invalid_token",errorDescription:'Nonce (nonce) claim value mismatch in the ID token; expected "'+u+'", found "'+a.payload.nonce+'"'}):t.access_token?r.client.userInfo(t.access_token,(function(e,t){return e?d(e):d(null,t)})):d({error:"invalid_token",description:"The id_token cannot be validated because it was signed with the HS256 algorithm and public clients (like a browser) can’t store secrets. Please read the associated doc for possible ways to fix this. Read more: https://auth0.com/docs/errors/libraries/auth0-js/invalid-token#parsing-an-hs256-signed-id-token-without-an-access-token"})})):d(null,null)},Ht.prototype.validateToken=function(e,t,n){new mt({issuer:this.baseOptions.token_issuer,jwksURI:this.baseOptions.jwksURI,audience:this.baseOptions.clientID,leeway:this.baseOptions.leeway||60,maxAge:this.baseOptions.maxAge,__clock:this.baseOptions.__clock||Pt}).verify(e,t,(function(e,t){if(e)return n(je.invalidToken(e.message));n(null,t)}))},Ht.prototype.renewAuth=function(e,t){var n=!!e.usePostMessage,r=e.postMessageDataType||!1,a=e.postMessageOrigin||ke.getWindow().origin,o=e.timeout,i=this,s=be.merge(this.baseOptions,["clientID","redirectUri","responseType","scope","audience","_csrf","state","_intstate","nonce"]).with(e);s.responseType=s.responseType||"token",s.responseMode=s.responseMode||"fragment",s=this.transactionManager.process(s),pe.check(s,{type:"object",message:"options parameter is not valid"}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),s.prompt="none",s=be.blacklist(s,["usePostMessage","tenant","postMessageDataType","postMessageOrigin"]),St.create({authenticationUrl:this.client.buildAuthorizeUrl(s),postMessageDataType:r,postMessageOrigin:a,timeout:o}).login(n,(function(e,n){if("object"==typeof n)return t(e,n);i.parseHash({hash:n},t)}))},Ht.prototype.checkSession=function(e,t){var n=be.merge(this.baseOptions,["clientID","responseType","redirectUri","scope","audience","_csrf","state","_intstate","nonce"]).with(e);return"code"===n.responseType?t({error:"error",error_description:"responseType can't be `code`"}):(e.nonce||(n=this.transactionManager.process(n)),n.redirectUri?(pe.check(n,{type:"object",message:"options parameter is not valid"}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=be.blacklist(n,["usePostMessage","tenant","postMessageDataType"]),void this.webMessageHandler.run(n,Pe(t,{forceLegacyError:!0,ignoreCasing:!0}))):t({error:"error",error_description:"redirectUri can't be empty"}))},Ht.prototype.changePassword=function(e,t){return this.client.dbConnection.changePassword(e,t)},Ht.prototype.passwordlessStart=function(e,t){var n=be.merge(this.baseOptions,["responseType","responseMode","redirectUri","scope","audience","_csrf","state","_intstate","nonce"]).with(e.authParams);return e.authParams=this.transactionManager.process(n),this.client.passwordless.start(e,t)},Ht.prototype.signup=function(e,t){return this.client.dbConnection.signup(e,t)},Ht.prototype.authorize=function(e){var t=be.merge(this.baseOptions,["clientID","responseType","responseMode","redirectUri","scope","audience","_csrf","state","_intstate","nonce","organization","invitation"]).with(e);pe.check(t,{type:"object",message:"options parameter is not valid"},{responseType:{type:"string",message:"responseType option is required"}}),(t=this.transactionManager.process(t)).scope=t.scope||"openid profile email",ke.redirect(this.client.buildAuthorizeUrl(t))},Ht.prototype.signupAndAuthorize=function(e,t){var n=this;return this.client.dbConnection.signup(be.blacklist(e,["popupHandler"]),(function(r){if(r)return t(r);e.realm=e.connection,e.username||(e.username=e.email),n.client.login(e,t)}))},Ht.prototype.login=function(e,t){var n=be.merge(this.baseOptions,["clientID","responseType","redirectUri","scope","audience","_csrf","state","_intstate","nonce","onRedirecting","organization","invitation"]).with(e);n=this.transactionManager.process(n),ke.getWindow().location.host===this.baseOptions.domain?(n.connection=n.realm,delete n.realm,this._universalLogin.login(n,t)):this.crossOriginAuthentication.login(n,t)},Ht.prototype.passwordlessLogin=function(e,t){var n=be.merge(this.baseOptions,["clientID","responseType","redirectUri","scope","audience","_csrf","state","_intstate","nonce","onRedirecting"]).with(e);if(n=this.transactionManager.process(n),ke.getWindow().location.host===this.baseOptions.domain)this.passwordlessVerify(n,t);else{var r=be.extend({credentialType:"http://auth0.com/oauth/grant-type/passwordless/otp",realm:n.connection,username:n.email||n.phoneNumber,otp:n.verificationCode},be.blacklist(n,["connection","email","phoneNumber","verificationCode"]));this.crossOriginAuthentication.login(r,t)}},Ht.prototype.crossOriginAuthenticationCallback=function(){this.crossOriginVerification()},Ht.prototype.crossOriginVerification=function(){this.crossOriginAuthentication.callback()},Ht.prototype.logout=function(e){ke.redirect(this.client.buildLogoutUrl(e))},Ht.prototype.passwordlessVerify=function(e,t){var n=this,r=be.merge(this.baseOptions,["clientID","responseType","responseMode","redirectUri","scope","audience","_csrf","state","_intstate","nonce","onRedirecting"]).with(e);return pe.check(r,{type:"object",message:"options parameter is not valid"},{responseType:{type:"string",message:"responseType option is required"}}),r=this.transactionManager.process(r),this.client.passwordless.verify(r,(function(a){if(a)return t(a);function o(){ke.redirect(n.client.passwordless.buildVerifyUrl(r))}if("function"==typeof e.onRedirecting)return e.onRedirecting((function(){o()}));o()}))},Ht.prototype.renderCaptcha=function(e,t,n){return jt(this.client,e,t,n)},It.prototype.buildVerifyUrl=function(e){var t,n;return pe.check(e,{type:"object",message:"options parameter is not valid"},{connection:{type:"string",message:"connection option is required"},verificationCode:{type:"string",message:"verificationCode option is required"},phoneNumber:{optional:!1,type:"string",message:"phoneNumber option is required",condition:function(e){return!e.email}},email:{optional:!1,type:"string",message:"email option is required",condition:function(e){return!e.phoneNumber}}}),t=be.merge(this.baseOptions,["clientID","responseType","responseMode","redirectUri","scope","audience","_csrf","state","_intstate","protocol","nonce"]).with(e),this.baseOptions._sendTelemetry&&(t.auth0Client=this.request.getTelemetryData()),t=be.toSnakeCase(t,["auth0Client"]),n=Y(t),i(this.baseOptions.rootUrl,"passwordless","verify_redirect","?"+n)},It.prototype.start=function(e,t){var n,r;return pe.check(e,{type:"object",message:"options parameter is not valid"},{connection:{type:"string",message:"connection option is required"},send:{type:"string",message:"send option is required",values:["link","code"],value_message:"send is not valid ([link, code])"},phoneNumber:{optional:!0,type:"string",message:"phoneNumber option is required",condition:function(e){return"code"===e.send||!e.email}},email:{optional:!0,type:"string",message:"email option is required",condition:function(e){return"link"===e.send||!e.phoneNumber}},authParams:{optional:!0,type:"object",message:"authParams option is required"}}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"passwordless","start"),(r=be.merge(this.baseOptions,["clientID","responseType","redirectUri","scope"]).with(e)).scope&&(r.authParams=r.authParams||{},r.authParams.scope=r.authParams.scope||r.scope),r.redirectUri&&(r.authParams=r.authParams||{},r.authParams.redirect_uri=r.authParams.redirectUri||r.redirectUri),r.responseType&&(r.authParams=r.authParams||{},r.authParams.response_type=r.authParams.responseType||r.responseType),delete r.redirectUri,delete r.responseType,delete r.scope,r=be.toSnakeCase(r,["auth0Client","authParams"]),this.request.post(n).send(r).end(Pe(t))},It.prototype.verify=function(e,t){var n,r;return pe.check(e,{type:"object",message:"options parameter is not valid"},{connection:{type:"string",message:"connection option is required"},verificationCode:{type:"string",message:"verificationCode option is required"},phoneNumber:{optional:!1,type:"string",message:"phoneNumber option is required",condition:function(e){return!e.email}},email:{optional:!1,type:"string",message:"email option is required",condition:function(e){return!e.phoneNumber}}}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),r=be.pick(e,["connection","verificationCode","phoneNumber","email","auth0Client"]),r=be.toSnakeCase(r,["auth0Client"]),n=i(this.baseOptions.rootUrl,"passwordless","verify"),this.request.post(n).send(r).end(Pe(t))},Nt.prototype.signup=function(e,t){var n,r,a;return pe.check(e,{type:"object",message:"options parameter is not valid"},{connection:{type:"string",message:"connection option is required"},email:{type:"string",message:"email option is required"},password:{type:"string",message:"password option is required"}}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"dbconnections","signup"),a=(r=be.merge(this.baseOptions,["clientID","state"]).with(e)).user_metadata||r.userMetadata,r=be.blacklist(r,["scope","userMetadata","user_metadata"]),r=be.toSnakeCase(r,["auth0Client"]),a&&(r.user_metadata=a),this.request.post(n).send(r).end(Pe(t))},Nt.prototype.changePassword=function(e,t){var n,r;return pe.check(e,{type:"object",message:"options parameter is not valid"},{connection:{type:"string",message:"connection option is required"},email:{type:"string",message:"email option is required"}}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"dbconnections","change_password"),r=be.merge(this.baseOptions,["clientID"]).with(e,["email","connection"]),r=be.toSnakeCase(r,["auth0Client"]),this.request.post(n).send(r).end(Pe(t))},Rt.prototype.buildAuthorizeUrl=function(e){var t,n;return pe.check(e,{type:"object",message:"options parameter is not valid"}),t=be.merge(this.baseOptions,["clientID","responseType","responseMode","redirectUri","scope","audience"]).with(e),pe.check(t,{type:"object",message:"options parameter is not valid"},{clientID:{type:"string",message:"clientID option is required"},redirectUri:{optional:!0,type:"string",message:"redirectUri option is required"},responseType:{type:"string",message:"responseType option is required"},nonce:{type:"string",message:"nonce option is required",condition:function(e){return-1===e.responseType.indexOf("code")&&-1!==e.responseType.indexOf("id_token")}},scope:{optional:!0,type:"string",message:"scope option is required"},audience:{optional:!0,type:"string",message:"audience option is required"}}),this.baseOptions._sendTelemetry&&(t.auth0Client=this.request.getTelemetryData()),t.connection_scope&&pe.isArray(t.connection_scope)&&(t.connection_scope=t.connection_scope.join(",")),t=be.blacklist(t,["username","popupOptions","domain","tenant","timeout","appState"]),t=be.toSnakeCase(t,["auth0Client"]),t=Re(this.warn,t),n=Y(t),i(this.baseOptions.rootUrl,"authorize","?"+n)},Rt.prototype.buildLogoutUrl=function(e){var t,n;return pe.check(e,{optional:!0,type:"object",message:"options parameter is not valid"}),t=be.merge(this.baseOptions,["clientID"]).with(e||{}),this.baseOptions._sendTelemetry&&(t.auth0Client=this.request.getTelemetryData()),t=be.toSnakeCase(t,["auth0Client","returnTo"]),n=Y(be.blacklist(t,["federated"])),e&&void 0!==e.federated&&!1!==e.federated&&"false"!==e.federated&&(n+="&federated"),i(this.baseOptions.rootUrl,"v2","logout","?"+n)},Rt.prototype.loginWithDefaultDirectory=function(e,t){return pe.check(e,{type:"object",message:"options parameter is not valid"},{username:{type:"string",message:"username option is required"},password:{type:"string",message:"password option is required"},scope:{optional:!0,type:"string",message:"scope option is required"},audience:{optional:!0,type:"string",message:"audience option is required"}}),e.grantType="password",this.oauthToken(e,t)},Rt.prototype.login=function(e,t){return pe.check(e,{type:"object",message:"options parameter is not valid"},{username:{type:"string",message:"username option is required"},password:{type:"string",message:"password option is required"},realm:{type:"string",message:"realm option is required"},scope:{optional:!0,type:"string",message:"scope option is required"},audience:{optional:!0,type:"string",message:"audience option is required"}}),e.grantType="http://auth0.com/oauth/grant-type/password-realm",this.oauthToken(e,t)},Rt.prototype.oauthToken=function(e,t){var n,r;return pe.check(e,{type:"object",message:"options parameter is not valid"}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"oauth","token"),r=be.merge(this.baseOptions,["clientID","scope","audience"]).with(e),pe.check(r,{type:"object",message:"options parameter is not valid"},{clientID:{type:"string",message:"clientID option is required"},grantType:{type:"string",message:"grantType option is required"},scope:{optional:!0,type:"string",message:"scope option is required"},audience:{optional:!0,type:"string",message:"audience option is required"}}),r=be.toSnakeCase(r,["auth0Client"]),r=Ne(this.warn,r),this.request.post(n).send(r).end(Pe(t))},Rt.prototype.loginWithResourceOwner=function(e,t){var n,r;return pe.check(e,{type:"object",message:"options parameter is not valid"},{username:{type:"string",message:"username option is required"},password:{type:"string",message:"password option is required"},connection:{type:"string",message:"connection option is required"},scope:{optional:!0,type:"string",message:"scope option is required"}}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"oauth","ro"),r=be.merge(this.baseOptions,["clientID","scope"]).with(e,["username","password","scope","connection","device"]),(r=be.toSnakeCase(r,["auth0Client"])).grant_type=r.grant_type||"password",this.request.post(n).send(r).end(Pe(t))},Rt.prototype.getSSOData=function(e,t){if(this.auth0||(this.auth0=new Ht(this.baseOptions)),ke.getWindow().location.host===this.baseOptions.domain)return this.auth0._universalLogin.getSSOData(e,t);"function"==typeof e&&(t=e),pe.check(t,{type:"function",message:"cb parameter is not valid"});var n=this.baseOptions.clientID,r=this.ssodataStorage.get()||{};this.auth0.checkSession({responseType:"token id_token",scope:"openid profile email",connection:r.lastUsedConnection,timeout:5e3},(function(e,a){return e?"login_required"===e.error?t(null,{sso:!1}):("consent_required"===e.error&&(e.error_description="Consent required. When using `getSSOData`, the user has to be authenticated with the following scope: `openid profile email`."),t(e,{sso:!1})):r.lastUsedSub&&r.lastUsedSub!==a.idTokenPayload.sub?t(e,{sso:!1}):t(null,{lastUsedConnection:{name:r.lastUsedConnection},lastUsedUserID:a.idTokenPayload.sub,lastUsedUsername:a.idTokenPayload.email||a.idTokenPayload.name,lastUsedClientID:n,sessionClients:[n],sso:!0})}))},Rt.prototype.userInfo=function(e,t){var n;return pe.check(e,{type:"string",message:"accessToken parameter is not valid"}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"userinfo"),this.request.get(n).set("Authorization","Bearer "+e).end(Pe(t,{ignoreCasing:!0}))},Rt.prototype.getChallenge=function(e){if(pe.check(e,{type:"function",message:"cb parameter is not valid"}),!this.baseOptions.state)return e();var t=i(this.baseOptions.rootUrl,"usernamepassword","challenge");return this.request.post(t).send({state:this.baseOptions.state}).end(Pe(e,{ignoreCasing:!0}))},Rt.prototype.delegation=function(e,t){var n,r;return pe.check(e,{type:"object",message:"options parameter is not valid"},{grant_type:{type:"string",message:"grant_type option is required"}}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"delegation"),r=be.merge(this.baseOptions,["clientID"]).with(e),r=be.toSnakeCase(r,["auth0Client"]),this.request.post(n).send(r).end(Pe(t))},Rt.prototype.getUserCountry=function(e){var t;return pe.check(e,{type:"function",message:"cb parameter is not valid"}),t=i(this.baseOptions.rootUrl,"user","geoloc","country"),this.request.get(t).end(Pe(e))},Ft.prototype.getUser=function(e,t){var n;return pe.check(e,{type:"string",message:"userId parameter is not valid"}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"users",e),this.request.get(n).end(Pe(t,{ignoreCasing:!0}))},Ft.prototype.patchUserMetadata=function(e,t,n){var r;return pe.check(e,{type:"string",message:"userId parameter is not valid"}),pe.check(t,{type:"object",message:"userMetadata parameter is not valid"}),pe.check(n,{type:"function",message:"cb parameter is not valid"}),r=i(this.baseOptions.rootUrl,"users",e),this.request.patch(r).send({user_metadata:t}).end(Pe(n,{ignoreCasing:!0}))},Ft.prototype.patchUserAttributes=function(e,t,n){var r;return pe.check(e,{type:"string",message:"userId parameter is not valid"}),pe.check(t,{type:"object",message:"user parameter is not valid"}),pe.check(n,{type:"function",message:"cb parameter is not valid"}),r=i(this.baseOptions.rootUrl,"users",e),this.request.patch(r).send(t).end(Pe(n,{ignoreCasing:!0}))},Ft.prototype.linkUser=function(e,t,n){var r;return pe.check(e,{type:"string",message:"userId parameter is not valid"}),pe.check(t,{type:"string",message:"secondaryUserToken parameter is not valid"}),pe.check(n,{type:"function",message:"cb parameter is not valid"}),r=i(this.baseOptions.rootUrl,"users",e,"identities"),this.request.post(r).send({link_with:t}).end(Pe(n,{ignoreCasing:!0}))};var zt={Authentication:Rt,Management:Ft,WebAuth:Ht,version:se};t.default=zt}.call(this,n(38),n(345))},function(e,t){var n,r,a=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function s(e){if(n===setTimeout)return setTimeout(e,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:o}catch(e){n=o}try{r="function"==typeof clearTimeout?clearTimeout:i}catch(e){r=i}}();var u,l=[],c=!1,d=-1;function p(){c&&u&&(c=!1,u.length?l=u.concat(l):d=-1,l.length&&f())}function f(){if(!c){var e=s(p);c=!0;for(var t=l.length;t;){for(u=l,l=[];++d<t;)u&&u[d].run();d=-1,t=l.length}u=null,c=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===i||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function h(e,t){this.fun=e,this.array=t}function m(){}a.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];l.push(new h(e,t)),1!==l.length||c||s(f)},h.prototype.run=function(){this.fun.apply(null,this.array)},a.title="browser",a.browser=!0,a.env={},a.argv=[],a.version="",a.versions={},a.on=m,a.addListener=m,a.once=m,a.off=m,a.removeListener=m,a.removeAllListeners=m,a.emit=m,a.prependListener=m,a.prependOnceListener=m,a.listeners=function(e){return[]},a.binding=function(e){throw new Error("process.binding is not supported")},a.cwd=function(){return"/"},a.chdir=function(e){throw new Error("process.chdir is not supported")},a.umask=function(){return 0}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(347),s=n(27),u=n(29),l=n(8),c=n(10),d=n(39),p=n(40),f=function(e){function t(n){var r=e.call(this,n)||this;return r.componentDidMount=function(){var e=r.props,t=e.auth0ClientId,n=e.auth0Hash,a=e.onAuthenticated,o=e.baseUrl;u.default.bindToClient(t),n?u.default.parseIdFromHash(n).then((function(e){s.default.getAccessData(e.idToken,o).then((function(t){r.props.login(e),r.props.cacheAccessData(t),s.default.buildFreshSession(e,t),a()})).catch((function(e){u.default.login()}))})).catch((function(e){u.default.login()})):u.default.login()},r.render=function(){return o.createElement("div",{className:"auth-gate"},o.createElement(i.default,{color:t.LOADER_COLOR}))},r}return a(t,e),t.LOADER_COLOR="#2d8ceb",t}(o.PureComponent);t.default=l.connect(null,(function(e){return c.bindActionCreators({login:d.login,cacheAccessData:p.cacheAccessData},e)}))(f)},function(e,t,n){"use strict";var r,a=this&&this.__makeTemplateObject||function(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e},o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t};Object.defineProperty(t,"__esModule",{value:!0});var s,u,l=i(n(0)),c=n(532),d=n(350),p=c.keyframes(s||(s=a(["\n 0% {transform: scaley(1.0)}\n 50% {transform: scaley(0.4)}\n 100% {transform: scaley(1.0)}\n"],["\n 0% {transform: scaley(1.0)}\n 50% {transform: scaley(0.4)}\n 100% {transform: scaley(1.0)}\n"]))),f=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.style=function(e){var n=t.props,r=n.color,o=n.width,i=n.height,s=n.margin,l=n.radius,d=n.widthUnit,f=n.heightUnit,h=n.radiusUnit;return c.css(u||(u=a(["\n background-color: ",";\n width: ",";\n height: ",";\n margin: ",";\n border-radius: ",";\n display: inline-block;\n animation: "," 1s ","s infinite cubic-bezier(0.2, 0.68, 0.18, 1.08);\n animation-fill-mode: both;\n "],["\n background-color: ",";\n width: ",";\n height: ",";\n margin: ",";\n border-radius: ",";\n display: inline-block;\n animation: "," 1s ","s infinite cubic-bezier(0.2, 0.68, 0.18, 1.08);\n animation-fill-mode: both;\n "])),r,""+o+d,""+i+f,s,""+l+h,p,.1*e)},t}return o(t,e),t.prototype.render=function(){var e=this.props,t=e.loading,n=e.css;return t?c.jsx("div",{css:[n]},c.jsx("div",{css:this.style(1)}),c.jsx("div",{css:this.style(2)}),c.jsx("div",{css:this.style(3)}),c.jsx("div",{css:this.style(4)}),c.jsx("div",{css:this.style(5)})):null},t.defaultProps=d.heightWidthRadiusDefaults(35,4,2),t}(l.PureComponent);t.default=f},function(e,t,n){var r=n(349);e.exports=function(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,r(e,t)},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){function n(t,r){return e.exports=n=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},e.exports.default=e.exports,e.exports.__esModule=!0,n(t,r)}e.exports=n,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){"use strict";function r(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),r(n(351)),r(n(352))},function(e,t,n){"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0});var a=((r={}).loading=!0,r.color="#000000",r.css={},r);t.sizeDefaults=function(e){return Object.assign({},a,function(e){var t;return(t={}).size=e,t.sizeUnit="px",t}(e))},t.sizeMarginDefaults=function(e){var n;return Object.assign({},t.sizeDefaults(e),((n={}).margin="2px",n))},t.heightWidthDefaults=function(e,t){return Object.assign({},a,function(e,t){var n;return(n={}).height=e,n.heightUnit="px",n.width=t,n.widthUnit="px",n}(e,t))},t.heightWidthRadiusDefaults=function(e,n,r){var a;return void 0===r&&(r=2),Object.assign({},t.heightWidthDefaults(e,n),((a={}).radius=r,a.radiusUnit="px",a.margin="2px",a))}},function(e,t,n){"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),function(e){e.maroon="#800000",e.red="#FF0000",e.orange="#FFA500",e.yellow="#FFFF00",e.olive="#808000",e.green="#008000",e.purple="#800080",e.fuchsia="#FF00FF",e.lime="#00FF00",e.teal="#008080",e.aqua="#00FFFF",e.blue="#0000FF",e.navy="#000080",e.black="#000000",e.gray="#808080",e.silver="#C0C0C0",e.white="#FFFFFF"}(r||(r={})),t.calculateRgba=function(e,t){if(Object.keys(r).includes(e)&&(e=r[e]),"#"===e[0]&&(e=e.slice(1)),3===e.length){var n="";e.split("").forEach((function(e){n+=e,n+=e})),e=n}return"rgba("+e.match(/.{2}/g).map((function(e){return parseInt(e,16)})).join(", ")+", "+t+")"}},function(e,t){e.exports=l},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i};Object.defineProperty(t,"__esModule",{value:!0});var o,i=n(0),s=n(355),u=n(21),l=n(4),c=n(356),d=n(357),p=function(e){return i.createElement("div",{className:"ip-table-loader"},i.createElement(u.default,null))},f=function(e){return i.createElement("div",{className:"ip-table-empty"},i.createElement("span",{className:"empty-message"},l.ICON_EXCLAIMATION_TRIANGLE," ",e.copy||"No Data Found"))},h=function(e){[32,37,38,39,40].indexOf(e.keyCode)>-1&&e.preventDefault()};t.default=function(e){var t=i.useRef(null),n=i.useRef(null),u=a(i.useState(!1),2),m=u[0],_=u[1],y=a(i.useState([]),2),g=y[0],v=y[1],b=a(i.useState([]),2),w=b[0],M=b[1],L=Array.isArray(e.hiddenColumns)?e.hiddenColumns:[],T=Number.isInteger(e.currentPage)&&"function"==typeof e.onPage,k="function"==typeof e.onSort&&void 0!==e.sortBy,x="function"==typeof e.renderPivotComponent?e.renderPivotComponent:function(){return null},E="function"==typeof e.onRowDoubleClick,S={hiddenColumns:L,sortBy:k?e.sortBy:[],pageIndex:T?e.currentPage-1:void 0,pageSize:e.itemsPerPage,autoResetExpanded:!1},O=c.useTable({columns:w,data:g,manualSortBy:k,manualPagination:T,initialState:S,manualFilters:!0,disableMultiSorting:!0,autoResetExpanded:!1,disableSortRemove:k,pageCount:e.totalPages,pageSize:e.itemsPerPage},c.useFlexLayout,c.useFilters,c.useSortBy,c.useExpanded,c.usePagination,c.useResizeColumns),D=O.getTableProps,Y=O.getTableBodyProps,A=O.headerGroups,C=O.page,j=O.rows,P=O.prepareRow,H=O.canPreviousPage,I=O.canNextPage,N=O.pageOptions,R=O.pageCount,F=O.gotoPage,z=O.nextPage,U=O.previousPage,W=O.setPageSize,B=O.setHiddenColumns,V=O.visibleColumns,G=O.totalColumnsWidth,q=O.toggleAllRowsExpanded,J=O.state,K=J.pageIndex,$=J.pageSize,X=J.sortBy,Z=T?j:C,Q=e.hidePaginator?"hide-paginator":"",ee=t.current&&G>t.current.clientWidth?"horizontal-scroll":"",te=e.tightRows?"tight-rows":"";return i.useEffect((function(){return _(!0)}),[]),i.useEffect((function(){var t,n;M((t=e.columns,Array.isArray(t)?t:!Array.isArray(t)&&"object"==typeof t&&(n=Object.keys(t)).length>0?n.map((function(e){return r(r({},t[e]),{accessor:e})})):[]))}),[e.columns]),i.useEffect((function(){m&&Array.isArray(e.hiddenColumns)&&B(e.hiddenColumns)}),[e.hiddenColumns]),i.useEffect((function(){Array.isArray(e.data)&&v(e.data)}),[e.data]),i.useEffect((function(){m&&T&&q(!1)}),[e.currentPage]),i.useEffect((function(){m&&k&&e.onSort(X)}),[X]),i.createElement("section",{ref:t,className:"ip-table-wrapper",tabIndex:e.disableKeyScroll?0:void 0,onKeyDown:e.disableKeyScroll?h:null},e.showInterstitial&&i.createElement(p,null),m&&!e.showInterstitial&&0===g.length&&i.createElement(f,{copy:e.noDataText}),i.createElement("table",r({},D(),{className:"ip-table "+ee+" "+Q+" "+te}),i.createElement("thead",{className:"ip-table-head"},A.map((function(e){return i.createElement(i.Fragment,{key:"head-fragment"},i.createElement("tr",r({},e.getHeaderGroupProps(),{className:"ip-table-head-row"}),e.headers.map((function(e){var t=e.hasOwnProperty("Search"),n=e.getSortByToggleProps(),a=i.createElement("span",{className:"sort-status"},e.isSorted?e.isSortedDesc?l.ICON_CHEVRON_DOWN:l.ICON_CHEVRON_UP:null);return i.createElement("th",r({},e.getHeaderProps(),{className:"ip-table-header "+(e.canSort?"ip-sortable":"")}),!t&&i.createElement("div",r({},n,{className:"filterable-cell-wrapper"}),e.render("Header"),a),t&&i.createElement("div",{className:"filterable-cell-wrapper"},i.createElement("span",r({},n,{className:"searchable-sort-area"}),e.render("Header"),a),e.hasOwnProperty("Search")&&e.render("Search")),e.canResize&&i.createElement("div",r({},e.getResizerProps(),{className:"ip-table-resizer "+(e.isResizing?"resizing":"")})))}))),e.headers.some((function(e){return e.hasOwnProperty("Filter")}))&&i.createElement("tr",r({},e.getHeaderGroupProps({key:"filters-row"})),e.headers.map((function(e,t){return i.createElement("th",r({},e.getHeaderProps({key:"filter-"+t}),{key:"filter-col-"+t,className:"ip-table-filter"}),e.canFilter&&e.Filter?e.render("Filter"):null)}))))}))),i.createElement("tbody",r({},Y(),{className:"ip-table-body"}),Z.map((function(t,a){var s,u="";e.highlightBy&&t.original.hasOwnProperty(e.highlightBy.key)&&t.original[e.highlightBy.key]===e.highlightBy.value&&(u="selected",s=n),P(t);var l=t.getRowProps();l.className="ip-table-row "+u,l.onClick=function(n){var r=function(){"function"==typeof e.onRowClick&&e.onRowClick(t)};E||r(),1===n.detail&&E&&(o=window.setTimeout(r,200))},l.onDoubleClick=function(n){clearTimeout(o),E&&e.onRowDoubleClick(t)};var c=t.cells.map((function(e){return i.createElement("td",r({},e.getCellProps(),{className:("ip-table-col "+(e.column.overflowVisible?"overflow-visible":"")).trim()}),e.render("Cell"))}));return i.createElement(i.Fragment,{key:"row-"+a},e.dnd&&i.createElement(d.default,{rowProps:l,rowRef:s,key:"row-"+a,row:t,dndType:e.dndType,dndName:e.dndName},c),!e.dnd&&i.createElement("tr",r({key:"row-"+a,ref:s},l),c),t.isExpanded&&i.createElement("tr",r({},t.getRowProps({key:"pivot-row"}),{className:"ip-pivot-row"}),i.createElement("td",{className:"ip-pivot-col "+u,colSpan:V.length},x(t))))})))),!e.hidePaginator&&i.createElement(s.default,r({},{totalItems:e.totalItems,pageIndex:e.currentPage?e.currentPage:K,manualPagination:T,pageSize:$,pageCount:R,pageOptions:N,canNextPage:T?e.currentPage+1<=e.totalPages:I,canPreviousPage:T?e.currentPage-1>=1:H,gotoPage:T?e.onPage:F,setPageSize:W,nextPage:T?function(){return e.onPage(e.currentPage+1,$)}:z,previousPage:T?function(){return e.onPage(e.currentPage-1,$)}:U})))}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,a=n(0),o=n(5),i=n(4);t.default=function(e){e.manualPagination;var t=e.pageCount,n=e.pageIndex,s=e.pageSize,u=(e.pageOptions,e.totalItems),l=e.canPreviousPage,c=e.canNextPage,d=e.gotoPage,p=e.previousPage,f=e.nextPage;e.setPageSize;return a.createElement("section",{className:"ip-table-pagination"},a.createElement("span",null,a.createElement(o.default,{style:"subtle",size:"small",tooltip:"Go to first page",disabled:!l,onClick:function(){return d(1,s)}},i.ICON_ANGLE_DOUBLE_LEFT),a.createElement(o.default,{style:"subtle",size:"small",tooltip:"Go to previous page",disabled:!l,onClick:function(){return p()}},i.ICON_ANGLE_LEFT),a.createElement(o.default,{style:"subtle",size:"small",tooltip:"Go to next page",disabled:!c,onClick:function(){return f()}},i.ICON_ANGLE_RIGHT),a.createElement(o.default,{style:"subtle",size:"small",tooltip:"Go to last page",disabled:!c,onClick:function(){return d(t,s)}},i.ICON_ANGLE_DOUBLE_RIGHT),"  ",a.createElement("span",null,"Page  ",a.createElement("strong",null,n," of ",t),"  "),a.createElement("span",null,"Go to page   ",a.createElement("input",{className:"paginator-input",type:"number",placeholder:n,onChange:function(e){var n,a=e.target.value,o=Number(a);clearTimeout(r),!a||o<1||o>t||(o>=1&&o<=t&&(n=o),r=window.setTimeout((function(){return d(n,s)}),300))}})),"  "),a.createElement("span",{className:"total-assets"},"Total  ",a.createElement("strong",null,u||0)))}},function(e,t){e.exports=c},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i};Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(61),s=n(358);t.default=function(e){var t=e.dndType,n=e.dndName,u=e.row,l=a(i.useDrag({type:t,item:{name:n,rowData:u.original,type:t}}),2),c=(l[0],l[1]);return o.createElement("tr",r({},e.rowProps,{ref:s.default([c,e.rowRef])}),e.children)}},function(e,t,n){"use strict";n.r(t),t.default=function(e){return function(t){e.forEach((function(e){"function"==typeof e?e(t):null!=e&&(e.current=t)}))}}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(5),s=n(22),u=n(4),l=function(e){function t(n){var r=e.call(this,n)||this;return r.render=function(){for(var e=r.props,n=e.page,a=e.totalPages,l=e.totalItems,c=Number.isInteger(a),d=Number.isInteger(a)&&a>1,p=!c||n-1==0,f=!c||n+1>a,h=Math.max(n-t.DEFAULT_STEP,1),m=Math.min(n+t.DEFAULT_STEP,a),_=[],y=h;y<=m;y++)_.push(y);return o.createElement("div",{className:"paginator"},o.createElement("div",{className:"pagination-controls"},o.createElement("span",{className:"paging-button-group"},o.createElement(i.default,{color:"secondary",size:"small",disabled:p,onClick:function(){return r.props.onPage(1)}},u.ICON_ANGLE_DOUBLE_LEFT),o.createElement(i.default,{color:"secondary",size:"small",disabled:p,onClick:function(){return r.props.onPage(n-1)}},u.ICON_ANGLE_LEFT)),o.createElement("div",{className:"jump-to-wrapper"},o.createElement(s.default,{label:"Page",value:n,disable:!d,options:_,onChange:function(e){return r.props.onPage(parseInt(e,10))}})),o.createElement("span",{className:"paging-button-group"},o.createElement(i.default,{color:"secondary",size:"small",disabled:f,onClick:function(){return r.props.onPage(n+1)}},u.ICON_ANGLE_RIGHT),o.createElement(i.default,{color:"secondary",size:"small",disabled:f,onClick:function(){return r.props.onPage(a)}},u.ICON_ANGLE_DOUBLE_RIGHT))),o.createElement("div",{className:"total-assets"},"Total: ",l||t.DEFAULT_TOTAL))},r}return a(t,e),t.DEFAULT_TOTAL=0,t.DEFAULT_STEP=25,t}(o.PureComponent);t.default=l},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(5),s=n(4),u=function(e){function t(t){var n=e.call(this,t)||this;return n.closeStyles={position:"absolute",right:"0px",top:"0px"},n.evtHandlers={onClose:function(e){return n.onClose(e)}},n}return a(t,e),t.prototype.onClose=function(e){(0,this.props.onRequestClose)(e)},t.prototype.render=function(){var e=this.props,t=e.isOpen,n=(e.children,e.style),r=e.wrapperStyle;return t?o.createElement("div",{className:"modal",style:r},o.createElement("div",{className:"modal-bg",onClick:this.evtHandlers.onClose}),o.createElement("div",{className:"modal-container",style:n},o.createElement("div",{className:"modal-content"},this.props.children),o.createElement(i.default,{onClick:this.evtHandlers.onClose,customStyles:this.closeStyles},s.ICON_TIMES))):null},t}(o.PureComponent);t.default=u},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__values||function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(101),u=n(97),l=n(98),c=n(5),d=n(4),p=function(e){function t(t){var n=e.call(this,t)||this;return n.headerRef=i.createRef(),n.state={allowableTabsInView:0,isMenuOpen:!1},n}return a(t,e),t.prototype.componentDidMount=function(){var e=Math.floor(this.allowableNumOfTabs());this.setState({allowableTabsInView:e})},t.prototype.componentDidUpdate=function(e){var t=Math.floor(this.allowableNumOfTabs());this.setState({allowableTabsInView:t})},t.prototype.allowableNumOfTabs=function(){var e=this.props,t=e.options,n=e.tabPadding,r=0,a=this.headerRef.current;if(a){for(var o=a.offsetWidth,i=0;i<t.length;i++){var s=t[i],u=s.canClose||s.menuButtons?20:0,l=document.createElement("div");if(l.className="tab-header-option",l.innerHTML=s.label,a.appendChild(l),r+=l.offsetWidth+u,a.removeChild(l),l=null,r>=o-n-25)return i}return t.length}},t.prototype.renderContent=function(){var e,t,n,r,a=this.props,s=a.options,u=a.activeTab,l=a.keepMounted,c=a.width,d=a.height;if(l){var p=[];try{for(var f=o(s),h=f.next();!h.done;h=f.next()){var m=(v=h.value).key===u,_=i.cloneElement(v.content,{active:m,width:c,height:d});p.push(_)}}catch(t){e={error:t}}finally{try{h&&!h.done&&(t=f.return)&&t.call(f)}finally{if(e)throw e.error}}return p.length>0?p:null}try{for(var y=o(s),g=y.next();!g.done;g=y.next()){var v;if((v=g.value).key===u||!u)return v.content}}catch(e){n={error:e}}finally{try{g&&!g.done&&(r=y.return)&&r.call(y)}finally{if(n)throw n.error}}return null},t.prototype.renderHeader=function(){for(var e=this,t=this.props,n=t.options,r=t.activeTab,a=[],o=[],s=!1,p=function(t){var u=n[t],p=u.canClose,h=u.key,m=u.label,_=u.menuButtons,y=p?i.createElement(c.default,{style:"subtle",size:"small",onClick:function(t){t.preventDefault(),t.stopPropagation(),e.props.onClose(h)}},d.ICON_TIMES):null,g=_||null,v=h===r?"active":"";t<f.state.allowableTabsInView?a.push(i.createElement("div",{className:"tab-header-option "+v,onClick:function(){return e.props.onChange(h)},key:h},m,y,g)):(r!==h||s||(s=!0),o.push(i.createElement(l.default,{key:h,label:i.createElement("span",null,m,y,g),onClick:function(t){e.props.onChange(h)},active:r===h})))},f=this,h=0;h<n.length;h++)p(h);var m=i.createElement(c.default,{size:"large",style:"subtle",color:s?"primary":null},d.ICON_BARS);return i.createElement(i.Fragment,null,a,o.length>0?i.createElement("span",{className:"tab-header-menu"},i.createElement(u.default,{position:"left",items:o,onClick:function(t){e.setState({isMenuOpen:t})},isOpen:this.state.isMenuOpen,button:m})):null)},t.prototype.render=function(){return i.createElement("div",{className:"tabs"},i.createElement("div",{ref:this.headerRef,className:"tab-header"},this.renderHeader()),i.createElement("div",{className:"tab-content"},this.renderContent()))},t}(i.PureComponent);t.default=s.withResizeDetector(p)},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(0),u=n(62),l=n(5),c=n(11),d=n(100),p=n(9),f=n(4),h=function(e){function t(t){var n=e.call(this,t)||this;return n.state={textInputValue:""},n.inputRef=s.createRef(),u.default.filter=function(e){return p.filterHotkeys(e)},n.submitHandler=function(){return n.submitOption()},n}return a(t,e),t.prototype.deleteOption=function(e){var t=i([],o(this.props.options));t.splice(e,1),this.props.onChange(t)},t.prototype.componentWillUnmount=function(){u.default.unbind("enter",this.submitHandler)},t.prototype.inputBlur=function(e){u.default.unbind("enter",this.submitHandler),this.props.onBlur&&this.props.onBlur()},t.prototype.inputChanged=function(e){this.setState({textInputValue:e.target.value})},t.prototype.inputFocus=function(e){u.default("enter",this.submitHandler),this.props.onFocus&&this.props.onFocus()},t.prototype.submitOption=function(){var e=this,t=this.state.textInputValue,n=this.props.onError;if(""!==t){var r=void 0;-1===(r=this.props.options?i([],o(this.props.options)):[]).indexOf(t)?(r.push(t),this.props.onChange(r),this.setState({textInputValue:""},(function(){var t=e.inputRef.current;t&&t.focus()}))):n&&this.props.onError('"'+t+'" already exists in the list.')}else n&&this.props.onError("Can not add an empty item to the list")},t.prototype.render=function(){var e=this,t=this.props,n=t.label,r=t.options,a=t.placeholder,o=t.disabled,i=t.width,u=t.tooltip,l=(t.tooltipAdd,t.info),p=t.labelPosition,f=this.state.textInputValue;return s.createElement(c.default,{customClass:"list-field",label:n,tooltip:u,buttons:this.renderButtons(),info:l,labelPosition:p,width:i},s.createElement("input",{type:"text",placeholder:a,value:f,ref:this.inputRef,disabled:o,onChange:function(t){return e.inputChanged(t)},onFocus:function(t){return e.inputFocus(t)},onBlur:function(t){return e.inputBlur(t)}}),s.createElement(d.default,{items:r,removable:!0,onRemove:function(t){return e.deleteOption(t)}}))},t.prototype.renderButtons=function(){var e=this.props,t=e.buttons,n=e.tooltipAdd,r=t?i([],o(t)):[];return r.push(s.createElement(l.default,{key:"btn-submit",style:"subtle",tooltip:n,color:"primary",onClick:this.submitHandler},f.ICON_PLUS)),r},t}(s.PureComponent);t.default=h},function(e,t){e.exports=d},function(e,t,n){"use strict";n.r(t),n.d(t,"Toast",(function(){return d}));var r=n(0),a=n.n(r),o=n(35),i=n.n(o),s=n(2),u=function(){return(u=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};var l={success:function(e){return a.a.createElement("svg",u({viewBox:"0 0 426.667 426.667",width:18,height:18},e),a.a.createElement("path",{d:"M213.333 0C95.518 0 0 95.514 0 213.333s95.518 213.333 213.333 213.333c117.828 0 213.333-95.514 213.333-213.333S331.157 0 213.333 0zm-39.134 322.918l-93.935-93.931 31.309-31.309 62.626 62.622 140.894-140.898 31.309 31.309-172.203 172.207z",fill:"#6ac259"}))},warn:function(e){return a.a.createElement("svg",u({viewBox:"0 0 310.285 310.285",width:18,height:18},e),a.a.createElement("path",{d:"M264.845 45.441C235.542 16.139 196.583 0 155.142 0 113.702 0 74.743 16.139 45.44 45.441 16.138 74.743 0 113.703 0 155.144c0 41.439 16.138 80.399 45.44 109.701 29.303 29.303 68.262 45.44 109.702 45.44s80.399-16.138 109.702-45.44c29.303-29.302 45.44-68.262 45.44-109.701.001-41.441-16.137-80.401-45.439-109.703zm-132.673 3.895a12.587 12.587 0 0 1 9.119-3.873h28.04c3.482 0 6.72 1.403 9.114 3.888 2.395 2.485 3.643 5.804 3.514 9.284l-4.634 104.895c-.263 7.102-6.26 12.933-13.368 12.933H146.33c-7.112 0-13.099-5.839-13.345-12.945L128.64 58.594c-.121-3.48 1.133-6.773 3.532-9.258zm23.306 219.444c-16.266 0-28.532-12.844-28.532-29.876 0-17.223 12.122-30.211 28.196-30.211 16.602 0 28.196 12.423 28.196 30.211.001 17.591-11.456 29.876-27.86 29.876z",fill:"#FFDA44"}))},loading:function(e){return a.a.createElement("div",u({className:"ct-icon-loading"},e))},info:function(e){return a.a.createElement("svg",u({viewBox:"0 0 23.625 23.625",width:18,height:18},e),a.a.createElement("path",{d:"M11.812 0C5.289 0 0 5.289 0 11.812s5.289 11.813 11.812 11.813 11.813-5.29 11.813-11.813S18.335 0 11.812 0zm2.459 18.307c-.608.24-1.092.422-1.455.548a3.838 3.838 0 0 1-1.262.189c-.736 0-1.309-.18-1.717-.539s-.611-.814-.611-1.367c0-.215.015-.435.045-.659a8.23 8.23 0 0 1 .147-.759l.761-2.688c.067-.258.125-.503.171-.731.046-.23.068-.441.068-.633 0-.342-.071-.582-.212-.717-.143-.135-.412-.201-.813-.201-.196 0-.398.029-.605.09-.205.063-.383.12-.529.176l.201-.828c.498-.203.975-.377 1.43-.521a4.225 4.225 0 0 1 1.29-.218c.731 0 1.295.178 1.692.53.395.353.594.812.594 1.376 0 .117-.014.323-.041.617a4.129 4.129 0 0 1-.152.811l-.757 2.68a7.582 7.582 0 0 0-.167.736 3.892 3.892 0 0 0-.073.626c0 .356.079.599.239.728.158.129.435.194.827.194.185 0 .392-.033.626-.097.232-.064.4-.121.506-.17l-.203.827zm-.134-10.878a1.807 1.807 0 0 1-1.275.492c-.496 0-.924-.164-1.28-.492a1.57 1.57 0 0 1-.533-1.193c0-.465.18-.865.533-1.196a1.812 1.812 0 0 1 1.28-.497c.497 0 .923.165 1.275.497.353.331.53.731.53 1.196 0 .467-.177.865-.53 1.193z",fill:"#006DF0"}))},error:function(e){return a.a.createElement("svg",u({viewBox:"0 0 51.976 51.976",width:18,height:18},e),a.a.createElement("path",{d:"M44.373 7.603c-10.137-10.137-26.632-10.138-36.77 0-10.138 10.138-10.137 26.632 0 36.77s26.632 10.138 36.77 0c10.137-10.138 10.137-26.633 0-36.77zm-8.132 28.638a2 2 0 0 1-2.828 0l-7.425-7.425-7.778 7.778a2 2 0 1 1-2.828-2.828l7.778-7.778-7.425-7.425a2 2 0 1 1 2.828-2.828l7.425 7.425 7.071-7.071a2 2 0 1 1 2.828 2.828l-7.071 7.071 7.425 7.425a2 2 0 0 1 0 2.828z",fill:"#D80027"}))}},c={success:"#6EC05F",info:"#1271EC",warn:"#FED953",error:"#D60A2E",loading:"#0088ff"},d=function(e){var t,n,o,i,s="margin"+((e.position||"top-center").includes("bottom")?"Bottom":"Top"),d=["ct-toast",e.onClick?" ct-cursor-pointer":"","ct-toast-"+e.type].join(" "),p=((null===(n=e.bar)||void 0===n?void 0:n.size)||"3px")+" "+((null===(o=e.bar)||void 0===o?void 0:o.style)||"solid")+" "+((null===(i=e.bar)||void 0===i?void 0:i.color)||c[e.type]),f=l[e.type],h=Object(r.useState)(((t={opacity:0})[s]=-15,t)),m=h[0],_=h[1],y=u({paddingLeft:e.heading?25:void 0,minHeight:e.heading?50:void 0,borderLeft:p},m),g=function(){var t;_(((t={opacity:0})[s]="-15px",t)),setTimeout((function(){e.onHide(e.id,e.position)}),300)};Object(r.useEffect)((function(){var t,n=setTimeout((function(){var e;_(((e={opacity:1})[s]="15px",e))}),50);return 0!==e.hideAfter&&(t=setTimeout((function(){g()}),1e3*e.hideAfter)),function(){clearTimeout(n),t&&clearTimeout(t)}}),[]),Object(r.useEffect)((function(){e.show||g()}),[e.show]);var v={tabIndex:0,onClick:e.onClick,onKeyPress:function(t){13===t.keyCode&&e.onClick(t)}};return a.a.createElement("div",u({className:d,role:e.role?e.role:"status",style:y},e.onClick?v:{}),e.renderIcon?e.renderIcon():a.a.createElement(f,null),a.a.createElement("div",{className:e.heading?"ct-text-group-heading":"ct-text-group"},e.heading&&a.a.createElement("h4",{className:"ct-heading"},e.heading),a.a.createElement("div",{className:"ct-text"},e.text)))};d.propTypes={type:s.string.isRequired,text:Object(s.oneOfType)([s.string,s.node]).isRequired,show:s.bool,onHide:s.func,id:Object(s.oneOfType)([s.string,s.number]),hideAfter:s.number,heading:s.string,position:s.string,renderIcon:s.func,bar:Object(s.shape)({}),onClick:s.func,role:s.string},d.defaultProps={id:void 0,show:!0,onHide:void 0,hideAfter:3,heading:void 0,position:"top-center",renderIcon:void 0,bar:{},onClick:void 0,role:"status"};var p=function(e){return e.replace(/-([a-z])/g,(function(e){return e[1].toUpperCase()}))},f={topLeft:[],topCenter:[],topRight:[],bottomLeft:[],bottomCenter:[],bottomRight:[]},h=function(e){var t=e.toast,n=e.hiddenID,o=Object(r.useState)(f),i=o[0],s=o[1];Object(r.useEffect)((function(){t&&s((function(e){var n,r=p(t.position||"top-center");return u(u({},e),((n={})[r]=function(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),a=0;for(t=0;t<n;t++)for(var o=arguments[t],i=0,s=o.length;i<s;i++,a++)r[a]=o[i];return r}(e[r],[t]),n))}))}),[t]);var l=function(e,t){s((function(n){var r,a=p(t||"top-center");return u(u({},n),((r={})[a]=n[a].filter((function(t){return t.id!==e})),r))}))},c=["Left","Center","Right"];return a.a.createElement(a.a.Fragment,null,["top","bottom"].map((function(e){return a.a.createElement("div",{key:"row_"+e,className:"ct-row"},c.map((function(t){var r=""+e+t,o=["ct-group","bottom"===e?"ct-flex-bottom":""].join(" ");return a.a.createElement("div",{key:r,className:o},i[r].map((function(e){return a.a.createElement(d,u({key:r+"_"+e.id},e,{id:e.id,text:e.text,type:e.type,onClick:e.onClick,hideAfter:e.hideAfter,show:n!==e.id,onHide:l}))})))})))})))};h.propTypes={toast:Object(s.shape)({}),hiddenID:s.number},h.defaultProps={toast:void 0,hiddenID:void 0};!function(e,t){void 0===t&&(t={});var n=t.insertAt;if(e&&"undefined"!=typeof document){var r=document.head||document.getElementsByTagName("head")[0],a=document.createElement("style");a.type="text/css","top"===n&&r.firstChild?r.insertBefore(a,r.firstChild):r.appendChild(a),a.styleSheet?a.styleSheet.cssText=e:a.appendChild(document.createTextNode(e))}}("#ct-container {\n\tposition: fixed;\n\twidth: 100%;\n\theight: 100vh;\n\ttop: 0px;\n\tleft: 0px;\n\tz-index: 2000;\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: space-between;\n\tpointer-events: none;\n}\n\n.ct-row {\n\tdisplay: flex;\n\tjustify-content: space-between;\n}\n\n.ct-group {\n\tflex: 1;\n\tmargin: 10px 20px;\n\tdisplay: flex;\n\tflex-direction: column;\n\talign-items: center;\n}\n\n.ct-group:first-child {\n\talign-items: flex-start;\n}\n\n.ct-group:last-child {\n\talign-items: flex-end;\n}\n\n.ct-flex-bottom {\n\tjustify-content: flex-end;\n}\n\n.ct-toast {\n\tdisplay: flex;\n\tjustify-content: center;\n\talign-items: center;\n\tpadding: 12px 20px;\n\tbackground-color: #fff;\n\tbox-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);\n\tcolor: #000;\n\tborder-radius: 4px;\n\tmargin: 0px;\n\topacity: 1;\n\ttransition: 0.3s all ease-in-out;\n\tmin-height: 45px;\n\tpointer-events: all;\n}\n\n.ct-toast:focus {\n\toutline: none;\n}\n\n.ct-toast svg {\n\tmin-width: 18px;\n}\n\n.ct-cursor-pointer {\n\tcursor: pointer;\n}\n\n.ct-icon-loading {\n\tdisplay: inline-block;\n\twidth: 20px;\n\theight: 20px;\n}\n\n.ct-icon-loading:after {\n\tcontent: ' ';\n\tdisplay: block;\n\twidth: 14px;\n\theight: 14px;\n\tmargin: 1px;\n\tborder-radius: 50%;\n\tborder: 2px solid #0088ff;\n\tborder-color: #0088ff transparent #0088ff transparent;\n\tanimation: ct-icon-loading 1.2s linear infinite;\n}\n\n@keyframes ct-icon-loading {\n\t0% {\n\t\ttransform: rotate(0deg);\n\t}\n\t100% {\n\t\ttransform: rotate(360deg);\n\t}\n}\n\n.ct-text-group {\n\tmargin-left: 15px;\n}\n\n.ct-text-group-heading {\n\tmargin-left: 25px;\n}\n\n.ct-heading {\n\tfont-size: 18px;\n\tmargin: 0px;\n\tmargin-bottom: 5px;\n}\n\n.ct-text {\n\tfont-size: 14px;\n}\n\n@media (max-width: 768px) {\n\t.ct-row {\n\t\tjustify-content: flex-start;\n\t\tflex-direction: column;\n\t\tmargin: 7px 0px;\n\t}\n\n\t.ct-group {\n\t\tflex: none;\n\t\tmargin: 0px;\n\t}\n\n\t.ct-toast {\n\t\tmargin: 8px 15px;\n\t\twidth: initial;\n\t}\n}\n");var m=0,_=function(e,t){var n,r,o=document.getElementById((null===(n=t)||void 0===n?void 0:n.toastContainerID)||"ct-container");o||((o=document.createElement("div")).id="ct-container",document.body.appendChild(o)),m+=1;var s=1e3*(void 0===(null===(r=t)||void 0===r?void 0:r.hideAfter)?3:t.hideAfter),l=u({id:m,text:e},t);i.a.render(a.a.createElement(h,{toast:l}),o);var c=new Promise((function(e){setTimeout((function(){e()}),s)}));return c.hide=function(){i.a.render(a.a.createElement(h,{hiddenID:l.id}),o)},c};_.success=function(e,t){return _(e,u(u({},t),{type:"success"}))},_.warn=function(e,t){return _(e,u(u({},t),{type:"warn"}))},_.info=function(e,t){return _(e,u(u({},t),{type:"info"}))},_.error=function(e,t){return _(e,u(u({},t),{type:"error"}))},_.loading=function(e,t){return _(e,u(u({},t),{type:"loading"}))},t.default=_},function(e,t,n){"use strict";var r=n(366);function a(){}function o(){}o.resetWarningCache=a,e.exports=function(){function e(e,t,n,a,o,i){if(i!==r){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:o,resetWarningCache:a};return n.PropTypes=n,n}},function(e,t,n){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(11),s=function(e){function t(t){var n=e.call(this,t)||this;return n.state={tempValue:null},n}return a(t,e),t.prototype.componentWillUnmount=function(){clearTimeout(this.updateTimeout)},t.prototype.updateValue=function(e){this.props.onChange(e)},t.prototype.rangeInputChange=function(e){var t=this,n=e.target.value,r=parseFloat(n);clearTimeout(this.updateTimeout),this.setState({tempValue:r},(function(){t.updateTimeout=setTimeout((function(){t.updateValue(r),t.setState({tempValue:null})}),100)}))},t.prototype.numberInputChange=function(e){var t=this.props,n=t.min,r=t.max,a=e.target.value;(a=""===a?0:parseFloat(a))>=n&&a<=r&&this.updateValue(a)},t.prototype.render=function(){var e=this,t=this.props,n=t.label,r=t.width,a=t.min,s=t.max,u=t.step,l=t.defaultValue,c=t.value,d=t.tooltip,p=t.info,f=t.labelPosition,h=this.state.tempValue,m=null!==h?h:null==c?l:c;return o.createElement(i.default,{customClass:"slider-field",label:n,tooltip:d,info:p,labelPosition:f,width:r},o.createElement("input",{onChange:function(t){return e.rangeInputChange(t)},type:"range",min:a,max:s,value:m,step:u}),o.createElement("input",{className:"val",onChange:function(t){return e.numberInputChange(t)},type:"number",value:m}))},t}(o.PureComponent);t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.flattenNames=void 0;var r=s(n(369)),a=s(n(66)),o=s(n(381)),i=s(n(382));function s(e){return e&&e.__esModule?e:{default:e}}var u=t.flattenNames=function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=[];return(0,i.default)(t,(function(t){Array.isArray(t)?e(t).map((function(e){return n.push(e)})):(0,o.default)(t)?(0,a.default)(t,(function(e,t){!0===e&&n.push(t),n.push(t+"-"+e)})):(0,r.default)(t)&&n.push(t)})),n};t.default=u},function(e,t,n){var r=n(18),a=n(12),o=n(15);e.exports=function(e){return"string"==typeof e||!a(e)&&o(e)&&"[object String]"==r(e)}},function(e,t,n){var r=n(31),a=Object.prototype,o=a.hasOwnProperty,i=a.toString,s=r?r.toStringTag:void 0;e.exports=function(e){var t=o.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var a=i.call(e);return r&&(t?e[s]=n:delete e[s]),a}},function(e,t){var n=Object.prototype.toString;e.exports=function(e){return n.call(e)}},function(e,t,n){var r=n(373)();e.exports=r},function(e,t){e.exports=function(e){return function(t,n,r){for(var a=-1,o=Object(t),i=r(t),s=i.length;s--;){var u=i[e?s:++a];if(!1===n(o[u],u,o))break}return t}}},function(e,t){e.exports=function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}},function(e,t,n){var r=n(18),a=n(15);e.exports=function(e){return a(e)&&"[object Arguments]"==r(e)}},function(e,t){e.exports=function(){return!1}},function(e,t,n){var r=n(18),a=n(68),o=n(15),i={};i["[object Float32Array]"]=i["[object Float64Array]"]=i["[object Int8Array]"]=i["[object Int16Array]"]=i["[object Int32Array]"]=i["[object Uint8Array]"]=i["[object Uint8ClampedArray]"]=i["[object Uint16Array]"]=i["[object Uint32Array]"]=!0,i["[object Arguments]"]=i["[object Array]"]=i["[object ArrayBuffer]"]=i["[object Boolean]"]=i["[object DataView]"]=i["[object Date]"]=i["[object Error]"]=i["[object Function]"]=i["[object Map]"]=i["[object Number]"]=i["[object Object]"]=i["[object RegExp]"]=i["[object Set]"]=i["[object String]"]=i["[object WeakMap]"]=!1,e.exports=function(e){return o(e)&&a(e.length)&&!!i[r(e)]}},function(e,t,n){var r=n(71),a=n(379),o=Object.prototype.hasOwnProperty;e.exports=function(e){if(!r(e))return a(e);var t=[];for(var n in Object(e))o.call(e,n)&&"constructor"!=n&&t.push(n);return t}},function(e,t,n){var r=n(109)(Object.keys,Object);e.exports=r},function(e,t,n){var r=n(111);e.exports=function(e){return"function"==typeof e?e:r}},function(e,t,n){var r=n(18),a=n(72),o=n(15),i=Function.prototype,s=Object.prototype,u=i.toString,l=s.hasOwnProperty,c=u.call(Object);e.exports=function(e){if(!o(e)||"[object Object]"!=r(e))return!1;var t=a(e);if(null===t)return!0;var n=l.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&u.call(n)==c}},function(e,t,n){var r=n(112),a=n(383),o=n(441),i=n(12);e.exports=function(e,t){return(i(e)?r:o)(e,a(t,3))}},function(e,t,n){var r=n(384),a=n(428),o=n(111),i=n(12),s=n(438);e.exports=function(e){return"function"==typeof e?e:null==e?o:"object"==typeof e?i(e)?a(e[0],e[1]):r(e):s(e)}},function(e,t,n){var r=n(385),a=n(427),o=n(122);e.exports=function(e){var t=a(e);return 1==t.length&&t[0][2]?o(t[0][0],t[0][1]):function(n){return n===e||r(n,e,t)}}},function(e,t,n){var r=n(73),a=n(114);e.exports=function(e,t,n,o){var i=n.length,s=i,u=!o;if(null==e)return!s;for(e=Object(e);i--;){var l=n[i];if(u&&l[2]?l[1]!==e[l[0]]:!(l[0]in e))return!1}for(;++i<s;){var c=(l=n[i])[0],d=e[c],p=l[1];if(u&&l[2]){if(void 0===d&&!(c in e))return!1}else{var f=new r;if(o)var h=o(d,p,c,e,t,f);if(!(void 0===h?a(p,d,3,o,f):h))return!1}}return!0}},function(e,t){e.exports=function(){this.__data__=[],this.size=0}},function(e,t,n){var r=n(45),a=Array.prototype.splice;e.exports=function(e){var t=this.__data__,n=r(t,e);return!(n<0)&&(n==t.length-1?t.pop():a.call(t,n,1),--this.size,!0)}},function(e,t,n){var r=n(45);e.exports=function(e){var t=this.__data__,n=r(t,e);return n<0?void 0:t[n][1]}},function(e,t,n){var r=n(45);e.exports=function(e){return r(this.__data__,e)>-1}},function(e,t,n){var r=n(45);e.exports=function(e,t){var n=this.__data__,a=r(n,e);return a<0?(++this.size,n.push([e,t])):n[a][1]=t,this}},function(e,t,n){var r=n(44);e.exports=function(){this.__data__=new r,this.size=0}},function(e,t){e.exports=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}},function(e,t){e.exports=function(e){return this.__data__.get(e)}},function(e,t){e.exports=function(e){return this.__data__.has(e)}},function(e,t,n){var r=n(44),a=n(75),o=n(76);e.exports=function(e,t){var n=this.__data__;if(n instanceof r){var i=n.__data__;if(!a||i.length<199)return i.push([e,t]),this.size=++n.size,this;n=this.__data__=new o(i)}return n.set(e,t),this.size=n.size,this}},function(e,t,n){var r=n(110),a=n(397),o=n(23),i=n(113),s=/^\[object .+?Constructor\]$/,u=Function.prototype,l=Object.prototype,c=u.toString,d=l.hasOwnProperty,p=RegExp("^"+c.call(d).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!o(e)||a(e))&&(r(e)?p:s).test(i(e))}},function(e,t,n){var r,a=n(398),o=(r=/[^.]+$/.exec(a&&a.keys&&a.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";e.exports=function(e){return!!o&&o in e}},function(e,t,n){var r=n(14)["__core-js_shared__"];e.exports=r},function(e,t){e.exports=function(e,t){return null==e?void 0:e[t]}},function(e,t,n){var r=n(401),a=n(44),o=n(75);e.exports=function(){this.size=0,this.__data__={hash:new r,map:new(o||a),string:new r}}},function(e,t,n){var r=n(402),a=n(403),o=n(404),i=n(405),s=n(406);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=a,u.prototype.get=o,u.prototype.has=i,u.prototype.set=s,e.exports=u},function(e,t,n){var r=n(46);e.exports=function(){this.__data__=r?r(null):{},this.size=0}},function(e,t){e.exports=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}},function(e,t,n){var r=n(46),a=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;if(r){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return a.call(t,e)?t[e]:void 0}},function(e,t,n){var r=n(46),a=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;return r?void 0!==t[e]:a.call(t,e)}},function(e,t,n){var r=n(46);e.exports=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=r&&void 0===t?"__lodash_hash_undefined__":t,this}},function(e,t,n){var r=n(47);e.exports=function(e){var t=r(this,e).delete(e);return this.size-=t?1:0,t}},function(e,t){e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},function(e,t,n){var r=n(47);e.exports=function(e){return r(this,e).get(e)}},function(e,t,n){var r=n(47);e.exports=function(e){return r(this,e).has(e)}},function(e,t,n){var r=n(47);e.exports=function(e,t){var n=r(this,e),a=n.size;return n.set(e,t),this.size+=n.size==a?0:1,this}},function(e,t,n){var r=n(73),a=n(115),o=n(418),i=n(421),s=n(48),u=n(12),l=n(67),c=n(108),d="[object Object]",p=Object.prototype.hasOwnProperty;e.exports=function(e,t,n,f,h,m){var _=u(e),y=u(t),g=_?"[object Array]":s(e),v=y?"[object Array]":s(t),b=(g="[object Arguments]"==g?d:g)==d,w=(v="[object Arguments]"==v?d:v)==d,M=g==v;if(M&&l(e)){if(!l(t))return!1;_=!0,b=!1}if(M&&!b)return m||(m=new r),_||c(e)?a(e,t,n,f,h,m):o(e,t,g,n,f,h,m);if(!(1&n)){var L=b&&p.call(e,"__wrapped__"),T=w&&p.call(t,"__wrapped__");if(L||T){var k=L?e.value():e,x=T?t.value():t;return m||(m=new r),h(k,x,n,f,m)}}return!!M&&(m||(m=new r),i(e,t,n,f,h,m))}},function(e,t,n){var r=n(76),a=n(414),o=n(415);function i(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new r;++t<n;)this.add(e[t])}i.prototype.add=i.prototype.push=a,i.prototype.has=o,e.exports=i},function(e,t){e.exports=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this}},function(e,t){e.exports=function(e){return this.__data__.has(e)}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}},function(e,t){e.exports=function(e,t){return e.has(t)}},function(e,t,n){var r=n(31),a=n(116),o=n(74),i=n(115),s=n(419),u=n(420),l=r?r.prototype:void 0,c=l?l.valueOf:void 0;e.exports=function(e,t,n,r,l,d,p){switch(n){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!d(new a(e),new a(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return o(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var f=s;case"[object Set]":var h=1&r;if(f||(f=u),e.size!=t.size&&!h)return!1;var m=p.get(e);if(m)return m==t;r|=2,p.set(e,t);var _=i(f(e),f(t),r,l,d,p);return p.delete(e),_;case"[object Symbol]":if(c)return c.call(e)==c.call(t)}return!1}},function(e,t){e.exports=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}},function(e,t){e.exports=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}},function(e,t,n){var r=n(117),a=Object.prototype.hasOwnProperty;e.exports=function(e,t,n,o,i,s){var u=1&n,l=r(e),c=l.length;if(c!=r(t).length&&!u)return!1;for(var d=c;d--;){var p=l[d];if(!(u?p in t:a.call(t,p)))return!1}var f=s.get(e),h=s.get(t);if(f&&h)return f==t&&h==e;var m=!0;s.set(e,t),s.set(t,e);for(var _=u;++d<c;){var y=e[p=l[d]],g=t[p];if(o)var v=u?o(g,y,p,t,e,s):o(y,g,p,e,t,s);if(!(void 0===v?y===g||i(y,g,n,o,s):v)){m=!1;break}_||(_="constructor"==p)}if(m&&!_){var b=e.constructor,w=t.constructor;b==w||!("constructor"in e)||!("constructor"in t)||"function"==typeof b&&b instanceof b&&"function"==typeof w&&w instanceof w||(m=!1)}return s.delete(e),s.delete(t),m}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,a=0,o=[];++n<r;){var i=e[n];t(i,n,e)&&(o[a++]=i)}return o}},function(e,t,n){var r=n(19)(n(14),"DataView");e.exports=r},function(e,t,n){var r=n(19)(n(14),"Promise");e.exports=r},function(e,t,n){var r=n(19)(n(14),"Set");e.exports=r},function(e,t,n){var r=n(19)(n(14),"WeakMap");e.exports=r},function(e,t,n){var r=n(121),a=n(32);e.exports=function(e){for(var t=a(e),n=t.length;n--;){var o=t[n],i=e[o];t[n]=[o,i,r(i)]}return t}},function(e,t,n){var r=n(114),a=n(429),o=n(435),i=n(78),s=n(121),u=n(122),l=n(49);e.exports=function(e,t){return i(e)&&s(t)?u(l(e),t):function(n){var i=a(n,e);return void 0===i&&i===t?o(n,e):r(t,i,3)}}},function(e,t,n){var r=n(123);e.exports=function(e,t,n){var a=null==e?void 0:r(e,t);return void 0===a?n:a}},function(e,t,n){var r=n(431),a=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o=/\\(\\)?/g,i=r((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(a,(function(e,n,r,a){t.push(r?a.replace(o,"$1"):n||e)})),t}));e.exports=i},function(e,t,n){var r=n(432);e.exports=function(e){var t=r(e,(function(e){return 500===n.size&&n.clear(),e})),n=t.cache;return t}},function(e,t,n){var r=n(76);function a(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,a=t?t.apply(this,r):r[0],o=n.cache;if(o.has(a))return o.get(a);var i=e.apply(this,r);return n.cache=o.set(a,i)||o,i};return n.cache=new(a.Cache||r),n}a.Cache=r,e.exports=a},function(e,t,n){var r=n(434);e.exports=function(e){return null==e?"":r(e)}},function(e,t,n){var r=n(31),a=n(112),o=n(12),i=n(79),s=r?r.prototype:void 0,u=s?s.toString:void 0;e.exports=function e(t){if("string"==typeof t)return t;if(o(t))return a(t,e)+"";if(i(t))return u?u.call(t):"";var n=t+"";return"0"==n&&1/t==-1/0?"-0":n}},function(e,t,n){var r=n(436),a=n(437);e.exports=function(e,t){return null!=e&&a(e,t,r)}},function(e,t){e.exports=function(e,t){return null!=e&&t in Object(e)}},function(e,t,n){var r=n(124),a=n(106),o=n(12),i=n(107),s=n(68),u=n(49);e.exports=function(e,t,n){for(var l=-1,c=(t=r(t,e)).length,d=!1;++l<c;){var p=u(t[l]);if(!(d=null!=e&&n(e,p)))break;e=e[p]}return d||++l!=c?d:!!(c=null==e?0:e.length)&&s(c)&&i(p,c)&&(o(e)||a(e))}},function(e,t,n){var r=n(439),a=n(440),o=n(78),i=n(49);e.exports=function(e){return o(e)?r(i(e)):a(e)}},function(e,t){e.exports=function(e){return function(t){return null==t?void 0:t[e]}}},function(e,t,n){var r=n(123);e.exports=function(e){return function(t){return r(t,e)}}},function(e,t,n){var r=n(442),a=n(43);e.exports=function(e,t){var n=-1,o=a(e)?Array(e.length):[];return r(e,(function(e,r,a){o[++n]=t(e,r,a)})),o}},function(e,t,n){var r=n(104),a=n(443)(r);e.exports=a},function(e,t,n){var r=n(43);e.exports=function(e,t){return function(n,a){if(null==n)return n;if(!r(n))return e(n,a);for(var o=n.length,i=t?o:-1,s=Object(n);(t?i--:++i<o)&&!1!==a(s[i],i,s););return n}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.mergeClasses=void 0;var r=i(n(66)),a=i(n(445)),o=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e};function i(e){return e&&e.__esModule?e:{default:e}}var s=t.mergeClasses=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=e.default&&(0,a.default)(e.default)||{};return t.map((function(t){var a=e[t];return a&&(0,r.default)(a,(function(e,t){n[t]||(n[t]={}),n[t]=o({},n[t],a[t])})),t})),n};t.default=s},function(e,t,n){var r=n(446);e.exports=function(e){return r(e,5)}},function(e,t,n){var r=n(73),a=n(447),o=n(125),i=n(449),s=n(450),u=n(453),l=n(454),c=n(455),d=n(456),p=n(117),f=n(457),h=n(48),m=n(458),_=n(459),y=n(464),g=n(12),v=n(67),b=n(466),w=n(23),M=n(468),L=n(32),T=n(80),k={};k["[object Arguments]"]=k["[object Array]"]=k["[object ArrayBuffer]"]=k["[object DataView]"]=k["[object Boolean]"]=k["[object Date]"]=k["[object Float32Array]"]=k["[object Float64Array]"]=k["[object Int8Array]"]=k["[object Int16Array]"]=k["[object Int32Array]"]=k["[object Map]"]=k["[object Number]"]=k["[object Object]"]=k["[object RegExp]"]=k["[object Set]"]=k["[object String]"]=k["[object Symbol]"]=k["[object Uint8Array]"]=k["[object Uint8ClampedArray]"]=k["[object Uint16Array]"]=k["[object Uint32Array]"]=!0,k["[object Error]"]=k["[object Function]"]=k["[object WeakMap]"]=!1,e.exports=function e(t,n,x,E,S,O){var D,Y=1&n,A=2&n,C=4&n;if(x&&(D=S?x(t,E,S,O):x(t)),void 0!==D)return D;if(!w(t))return t;var j=g(t);if(j){if(D=m(t),!Y)return l(t,D)}else{var P=h(t),H="[object Function]"==P||"[object GeneratorFunction]"==P;if(v(t))return u(t,Y);if("[object Object]"==P||"[object Arguments]"==P||H&&!S){if(D=A||H?{}:y(t),!Y)return A?d(t,s(D,t)):c(t,i(D,t))}else{if(!k[P])return S?t:{};D=_(t,P,Y)}}O||(O=new r);var I=O.get(t);if(I)return I;O.set(t,D),M(t)?t.forEach((function(r){D.add(e(r,n,x,r,t,O))})):b(t)&&t.forEach((function(r,a){D.set(a,e(r,n,x,a,t,O))}));var N=j?void 0:(C?A?f:p:A?T:L)(t);return a(N||t,(function(r,a){N&&(r=t[a=r]),o(D,a,e(r,n,x,a,t,O))})),D}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}},function(e,t,n){var r=n(19),a=function(){try{var e=r(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();e.exports=a},function(e,t,n){var r=n(50),a=n(32);e.exports=function(e,t){return e&&r(t,a(t),e)}},function(e,t,n){var r=n(50),a=n(80);e.exports=function(e,t){return e&&r(t,a(t),e)}},function(e,t,n){var r=n(23),a=n(71),o=n(452),i=Object.prototype.hasOwnProperty;e.exports=function(e){if(!r(e))return o(e);var t=a(e),n=[];for(var s in e)("constructor"!=s||!t&&i.call(e,s))&&n.push(s);return n}},function(e,t){e.exports=function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}},function(e,t,n){(function(e){var r=n(14),a=t&&!t.nodeType&&t,o=a&&"object"==typeof e&&e&&!e.nodeType&&e,i=o&&o.exports===a?r.Buffer:void 0,s=i?i.allocUnsafe:void 0;e.exports=function(e,t){if(t)return e.slice();var n=e.length,r=s?s(n):new e.constructor(n);return e.copy(r),r}}).call(this,n(42)(e))},function(e,t){e.exports=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}},function(e,t,n){var r=n(50),a=n(77);e.exports=function(e,t){return r(e,a(e),t)}},function(e,t,n){var r=n(50),a=n(127);e.exports=function(e,t){return r(e,a(e),t)}},function(e,t,n){var r=n(118),a=n(127),o=n(80);e.exports=function(e){return r(e,o,a)}},function(e,t){var n=Object.prototype.hasOwnProperty;e.exports=function(e){var t=e.length,r=new e.constructor(t);return t&&"string"==typeof e[0]&&n.call(e,"index")&&(r.index=e.index,r.input=e.input),r}},function(e,t,n){var r=n(81),a=n(460),o=n(461),i=n(462),s=n(463);e.exports=function(e,t,n){var u=e.constructor;switch(t){case"[object ArrayBuffer]":return r(e);case"[object Boolean]":case"[object Date]":return new u(+e);case"[object DataView]":return a(e,n);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return s(e,n);case"[object Map]":return new u;case"[object Number]":case"[object String]":return new u(e);case"[object RegExp]":return o(e);case"[object Set]":return new u;case"[object Symbol]":return i(e)}}},function(e,t,n){var r=n(81);e.exports=function(e,t){var n=t?r(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}},function(e,t){var n=/\w*$/;e.exports=function(e){var t=new e.constructor(e.source,n.exec(e));return t.lastIndex=e.lastIndex,t}},function(e,t,n){var r=n(31),a=r?r.prototype:void 0,o=a?a.valueOf:void 0;e.exports=function(e){return o?Object(o.call(e)):{}}},function(e,t,n){var r=n(81);e.exports=function(e,t){var n=t?r(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}},function(e,t,n){var r=n(465),a=n(72),o=n(71);e.exports=function(e){return"function"!=typeof e.constructor||o(e)?{}:r(a(e))}},function(e,t,n){var r=n(23),a=Object.create,o=function(){function e(){}return function(t){if(!r(t))return{};if(a)return a(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();e.exports=o},function(e,t,n){var r=n(467),a=n(69),o=n(70),i=o&&o.isMap,s=i?a(i):r;e.exports=s},function(e,t,n){var r=n(48),a=n(15);e.exports=function(e){return a(e)&&"[object Map]"==r(e)}},function(e,t,n){var r=n(469),a=n(69),o=n(70),i=o&&o.isSet,s=i?a(i):r;e.exports=s},function(e,t,n){var r=n(48),a=n(15);e.exports=function(e){return a(e)&&"[object Set]"==r(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.autoprefix=void 0;var r,a=n(66),o=(r=a)&&r.__esModule?r:{default:r},i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e};var s={borderRadius:function(e){return{msBorderRadius:e,MozBorderRadius:e,OBorderRadius:e,WebkitBorderRadius:e,borderRadius:e}},boxShadow:function(e){return{msBoxShadow:e,MozBoxShadow:e,OBoxShadow:e,WebkitBoxShadow:e,boxShadow:e}},userSelect:function(e){return{WebkitTouchCallout:e,KhtmlUserSelect:e,MozUserSelect:e,msUserSelect:e,WebkitUserSelect:e,userSelect:e}},flex:function(e){return{WebkitBoxFlex:e,MozBoxFlex:e,WebkitFlex:e,msFlex:e,flex:e}},flexBasis:function(e){return{WebkitFlexBasis:e,flexBasis:e}},justifyContent:function(e){return{WebkitJustifyContent:e,justifyContent:e}},transition:function(e){return{msTransition:e,MozTransition:e,OTransition:e,WebkitTransition:e,transition:e}},transform:function(e){return{msTransform:e,MozTransform:e,OTransform:e,WebkitTransform:e,transform:e}},absolute:function(e){var t=e&&e.split(" ");return{position:"absolute",top:t&&t[0],right:t&&t[1],bottom:t&&t[2],left:t&&t[3]}},extend:function(e,t){var n=t[e];return n||{extend:e}}},u=t.autoprefix=function(e){var t={};return(0,o.default)(e,(function(e,n){var r={};(0,o.default)(e,(function(e,t){var n=s[t];n?r=i({},r,n(e)):r[t]=e})),t[n]=r})),t};t.default=u},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hover=void 0;var r,a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=n(0),i=(r=o)&&r.__esModule?r:{default:r};function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function l(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var c=t.hover=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"span";return function(n){function r(){var n,o,l;s(this,r);for(var c=arguments.length,d=Array(c),p=0;p<c;p++)d[p]=arguments[p];return o=l=u(this,(n=r.__proto__||Object.getPrototypeOf(r)).call.apply(n,[this].concat(d))),l.state={hover:!1},l.handleMouseOver=function(){return l.setState({hover:!0})},l.handleMouseOut=function(){return l.setState({hover:!1})},l.render=function(){return i.default.createElement(t,{onMouseOver:l.handleMouseOver,onMouseOut:l.handleMouseOut},i.default.createElement(e,a({},l.props,l.state)))},u(l,o)}return l(r,n),r}(i.default.Component)};t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.active=void 0;var r,a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=n(0),i=(r=o)&&r.__esModule?r:{default:r};function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function l(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var c=t.active=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"span";return function(n){function r(){var n,o,l;s(this,r);for(var c=arguments.length,d=Array(c),p=0;p<c;p++)d[p]=arguments[p];return o=l=u(this,(n=r.__proto__||Object.getPrototypeOf(r)).call.apply(n,[this].concat(d))),l.state={active:!1},l.handleMouseDown=function(){return l.setState({active:!0})},l.handleMouseUp=function(){return l.setState({active:!1})},l.render=function(){return i.default.createElement(t,{onMouseDown:l.handleMouseDown,onMouseUp:l.handleMouseUp},i.default.createElement(e,a({},l.props,l.state)))},u(l,o)}return l(r,n),r}(i.default.Component)};t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.default=function(e,t){var n={},r=function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];n[e]=t};return 0===e&&r("first-child"),e===t-1&&r("last-child"),(0===e||e%2==0)&&r("even"),1===Math.abs(e%2)&&r("odd"),r("nth-child",e),n}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0);t.default=function(e){var t="string"==typeof e.className?e.className:"",n=e.isLoading?r.createElement("div",{className:"loading-bar"}):null,a=r.createElement("div",{className:"title"},e.title);return e.hasOwnProperty("tabs")&&Array.isArray(e.tabs)&&(a=e.tabs.map((function(t,n){return r.createElement("div",{key:n,className:"tab "+(e.activeTabName===t?"active":""),onClick:function(){return e.selectTab(t,n)}},t)}))),r.createElement("div",{className:"section "+t},r.createElement("div",{className:"section-header"},a,r.createElement("div",{className:"buttons"},e.buttons)),r.createElement("div",{className:"section-content"},e.children),n)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(9),o=r.memo((function(e){return r.createElement("div",null,a.formatDateDefault(e.cell.row.values.date_created))}));t.default=o},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.HEADER_HEIGHT=t.PREVIEW_MAX_HEIGHT=t.PREVIEW_MAX_WIDTH=void 0;var i=n(0),s=n(90);t.PREVIEW_MAX_WIDTH=400,t.PREVIEW_MAX_HEIGHT=400,t.HEADER_HEIGHT=30;var u=function(e){function n(t){var n=e.call(this,t)||this;return n.iconRef=i.createRef(),n.evtHandlers={onClose:function(){return n.handleClose()},onClick:function(){return n.handlePreviewClick()}},n}return a(n,e),n.prototype.handleClose=function(){(0,this.props.onRequestClose)()},n.prototype.handlePreviewClick=function(){var e=this.props,t=e.onClick;e.showMedia||t()},n.prototype.render=function(){var e=this,n=function(n,r){if(e.iconRef.current){n||(n=t.PREVIEW_MAX_WIDTH),r||(r=t.PREVIEW_MAX_HEIGHT);var a=e.iconRef.current.getBoundingClientRect(),o=n/r,i=t.PREVIEW_MAX_WIDTH,s=i/o;s>t.PREVIEW_MAX_HEIGHT&&(i=(s=t.PREVIEW_MAX_HEIGHT)*o);var u=a.x+a.width-i,l=a.y+a.height-s-20;return u<0&&(u=a.x),l<t.HEADER_HEIGHT&&(l=a.y+20),{top:l,left:u,width:i,height:s,position:"absolute",zIndex:9e3}}},r=this.props,a=r.cell,u=r.showMedia;return i.createElement("div",{ref:this.iconRef,className:"asset-type-cell",onClick:this.evtHandlers.onClick},i.createElement(s.AssetsTypeIcon,{type:a.row.values.type}),a.row.values.type===s.ASSET_TYPES.IMAGE&&i.createElement(s.ImagePreview,{style:o({},n(a.row.original.width,a.row.original.height)),showMedia:u,url:a.row.original.url,onRequestClose:this.evtHandlers.onClose}),a.row.values.type===s.ASSET_TYPES.VIDEO&&i.createElement(s.VideoPreview,{playbackSettings:{autoPlay:!0,loop:!1},style:n(a.row.original.width,a.row.original.height),showMedia:u,url:a.row.original.url,onRequestClose:this.evtHandlers.onClose}))},n}(i.PureComponent),l=i.memo(u);t.default=l},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.secondsToTime=void 0;var r=n(0),a=n(17),o=n(8),i=n(10);t.secondsToTime=function(e){var t=Math.floor(e/60),n=Math.floor(e-60*t);return n<10&&(n="0"+n),t+":"+n};t.default=o.connect((function(e){return{}}),(function(e){return i.bindActionCreators({updateAssetName:a.updateAssetName},e)}))((function(e){var n=e.cell.row.original,a=n.duration;n.id;return null!=a?r.createElement("div",{className:"asset-duration-cell"},t.secondsToTime(a)):null}))},function(e,t){e.exports=p},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ASSET_DND_TYPES=void 0,t.ASSET_DND_TYPES={ASSET_NAME:"asset_name"}},function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i};Object.defineProperty(t,"__esModule",{value:!0});var a,o=n(0),i=n(0),s=n(13),u=n(17),l=n(8),c=n(10);t.default=l.connect((function(e){return{}}),(function(e){return c.bindActionCreators({updateAssetName:u.updateAssetName},e)}))((function(e){var t=e.cell.row.original,n=t.name,u=t.id,l=r(i.useState(""),2),c=l[0],d=l[1],p=function(t){e.updateAssetName(e.api,u,t)};return i.useEffect((function(){return d(n),function(){clearTimeout(a)}}),[n]),o.createElement(s.default,{value:c,width:"100%",onChange:function(e){return function(e){d(e),clearTimeout(a),a=setTimeout((function(){return p(e)}),1e3)}(e)}})}))},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(13),s=n(24),u=n(8),l=n(10),c=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.render=function(){var e=t.props.assetFilters;return o.createElement(i.default,{submittable:!0,submittableType:"search",value:e.name,doSubmit:function(e){return t.props.updateFilters({name:e})}})},t}return a(t,e),t}(o.PureComponent),d=u.connect((function(e){return{assetFilters:e.assetFilters}}),(function(e){return l.bindActionCreators({updateFilters:s.updateFilters},e)}))(o.memo(c));t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(33),s=n(30),u=n(8),l=n(10),c=function(e){function t(t){var n=e.call(this,t)||this;return n.render=function(){var e=n.props,t=e.cell,r=e.selectedAssets,a=t.row.original.id,i=r.indexOf(a)>-1;return o.createElement(s.default,{label:"",width:"auto",value:i,onChange:function(e,t){return function(e,t){e?t.shiftKey&&r.length>0?n.props.selectMultipleAssets(a):n.props.selectAsset(a):n.props.deselectAsset(a)}(e,t)}})},n}return a(t,e),t}(o.PureComponent),d=u.connect((function(e){return{selectedAssets:e.selectedAssets}}),(function(e){return l.bindActionCreators({selectAsset:i.selectAsset,deselectAsset:i.deselectAsset,selectMultipleAssets:i.selectMultipleAssets},e)}))(o.memo(c));t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(30),s=n(33),u=n(8),l=n(10),c=function(e){function t(t){var n=e.call(this,t)||this;return n.render=function(){var e=0===n.props.selectedAssets.length,t=e?function(){return n.props.selectAll()}:function(){return n.props.resetSelection()};return o.createElement(i.default,{label:"",propagate:!1,value:!e,onChange:t})},n}return a(t,e),t}(o.PureComponent),d=u.connect((function(e){return{selectedAssets:e.selectedAssets}}),(function(e){return l.bindActionCreators({selectAll:s.selectAll,resetSelection:s.resetSelection},e)}))(o.memo(c));t.default=d},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(5),o=r.memo((function(e){return r.createElement(a.default,{color:"secondary",style:"subtle",size:"small",onClick:e.onClick},e.cell.row.values.tags.length)}));t.default=o},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(24),s=n(13),u=n(8),l=n(10),c=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.render=function(){var e=t.props.assetFilters;return o.createElement(s.default,{submittable:!0,submittableType:"search",value:e.tags,doSubmit:function(e){return t.props.updateFilters({tags:e})}})},t}return a(t,e),t}(o.PureComponent),d=u.connect((function(e){return{assetFilters:e.assetFilters}}),(function(e){return l.bindActionCreators({updateFilters:i.updateFilters},e)}))(o.memo(c));t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(7),s=n(51),u=n(13),l=n(17),c=n(8),d=n(10),p=n(5),f=n(4),h=function(e){function t(n){var r=e.call(this,n)||this;return r.addTags=function(e,t){t&&r.props.addAssetTag(r.props.api,e,t)},r.render=function(){var e=r.props,n=e.row.original,a=n.id,l=n.tags,c=e.assetTags,d=l.map((function(e){return o.createElement(s.default,{key:e,copy:e,colorize:t.COLORIZE_TAGS,removeHandler:function(){return r.props.deleteAssetTag(r.props.api,a,e)}})}));return o.createElement("div",{className:"tags-column"},o.createElement(o.Fragment,null,o.createElement(u.default,{submittable:!0,submittableType:"add",suggestions:c,label:i.assets.tags.add,width:t.ADD_TAG_INPUT_WIDTH,doSubmit:function(e){return r.addTags(a,e)}}),d,o.createElement(p.default,{customStyles:{position:"absolute",right:"1px",top:"9px"},style:"subtle",onClick:function(e){return r.props.onClose(e,r.props.row)}},f.ICON_TIMES)))},r}return a(t,e),t.ADD_TAG_INPUT_WIDTH="280px",t.COLORIZE_TAGS=!0,t}(o.PureComponent);t.default=c.connect((function(e){return{assetTags:e.assetTags}}),(function(e){return d.bindActionCreators({addAssetTag:l.addAssetTag,deleteAssetTag:l.deleteAssetTag},e)}))(h)},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(51),s=n(13),u=n(17),l=n(8),c=n(10),d=function(e){function t(t){var n=e.call(this,t)||this;return n.render=function(){var e=n.props,t=e.cell,r=e.assetTags,a=t.row.original.tags.map((function(e){return o.createElement(i.default,{key:e,copy:e,colorize:!0,removeHandler:function(){return n.removeTag(e)}})}));return o.createElement("div",{className:"tags-complex-column"},a,o.createElement("div",{className:"new-tag"},o.createElement(s.default,{submittable:!0,submittableType:"add",placeholder:"+",hideButtons:!0,suggestions:r,doSubmit:function(e){return n.onSubmit(e)},width:"150px",buttons:[],value:n.state.newTag})))},n.state={newTag:""},n.inputRef=o.createRef(),n}return a(t,e),t.prototype.onSubmit=function(e){var t=this.props.cell.row.original,n=t.id;-1===t.tags.indexOf(e)&&this.props.addAssetTag(this.props.api,n,e),this.setState({newTag:""})},t.prototype.removeTag=function(e){var t=this.props.cell.row.original.id;this.props.deleteAssetTag(this.props.api,t,e)},t}(o.Component),p=l.connect((function(e){return{assetTags:e.assetTags}}),(function(e){return c.bindActionCreators({addAssetTag:u.addAssetTag,deleteAssetTag:u.deleteAssetTag},e)}))(o.memo(d));t.default=p},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(85),o=r.memo((function(e){return r.createElement("div",{className:"asset-type-cell"},r.createElement(a.default,{type:e.cell.row.values.type}))}));t.default=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=r.memo((function(e){var t=e.cell.row.original.processing?"processing":"complete";return r.createElement("div",{className:"asset-status-cell"},r.createElement("div",{className:"status-indicator "+t}))}));t.default=a},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(85),s=n(5),u=n(59),l=n(24),c=n(8),d=n(10),p=n(25),f=function(e){function t(t){var n=e.call(this,t)||this;return n.handleFilterChange=function(e){var t=e!==p.ASSET_TYPES.ALL?e:"";n.props.updateFilters({type:t,page:1})},n.render=function(){var e=n.state.openMenu,t=n.props.assetFilters.type,r=[],a=function(e){if(p.ASSET_TYPES.hasOwnProperty(e)){var t=p.ASSET_TYPES[e];r.push(o.createElement("div",{key:t,className:"asset-filter",onClick:function(){return n.handleFilterChange(t)}},o.createElement(i.default,{type:t})))}};for(var l in p.ASSET_TYPES)a(l);return o.createElement("div",{className:"centered cell"},o.createElement(s.default,{tooltip:"Filter by Asset type",buttonRef:n.typeFilterRef,onClick:function(){return n.setState({openMenu:!e})}},o.createElement(i.default,{type:t||"filter"}),o.createElement(u.default,{fixed:!0,show:e,position:"bottomleft",toggleRef:n.typeFilterRef,onOutsideClick:function(){return n.setState({openMenu:!1})}},r)))},n.state={openMenu:!1},n.typeFilterRef=o.createRef(),n}return a(t,e),t}(o.PureComponent),h=c.connect((function(e){return{assetFilters:e.assetFilters}}),(function(e){return d.bindActionCreators({updateFilters:l.updateFilters},e)}))(o.memo(f));t.default=h},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(34),s=n(26),u=n(86),l=function(e){function t(t){var n=e.call(this,t)||this;return n.defaultSize=600,n}return a(t,e),t.prototype.getWrapperStyle=function(){var e=this.props,t=e.padding,n=e.width,r=e.height,a=void 0!==t?t:i.DEFAULT_PADDING;return s.getPlayerStyle(n,r,this.defaultSize,this.defaultSize,a,this.defaultSize,this.defaultSize)},t.prototype.render=function(){var e=this.props,t=e.active,n=e.asset,r=n.name,a=n.url,i=n.id,s=e.width,l=e.height,c=this.getWrapperStyle();return!1!==t?o.createElement("div",{className:"media-player"},o.createElement("div",{className:"inner-viewer",style:c},o.createElement(u.default,{options:{width:s,height:l,x:0,y:0,rotation:0,id:"xxx",name:"xxx",content:"ABCDEFGHIJKLM\nNOPQRSTUVWXYZ\nabcdefghijklm\nnopqrstuvwxyz\n1234567890",color:"#000000",background_color:"#ffffff",font_size:80,font_weight:400,font_type:"custom",font:r,custom_font_url:a,custom_font_id:i,letter_spacing:null,word_spacing:null,line_height:null,horizontal_alignment:"center",vertical_alignment:"center",text_wrap:!0,text_fit:!0}}))):null},t}(o.PureComponent);t.default=l},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(7),s=n(30),u=n(128),l=n(52),c=n(10),d=n(8),p=n(4),f=n(5),h=function(e){function t(t){var n=e.call(this,t)||this;return n.render=function(){var e,t=n.props.assetUploads,r=t.uploads,a=t.autoTag,l=t.assignToStory;return e=r.length>0?r.map((function(e){var t=e.filename,r=e.percent,a=r<100?o.createElement(u.default,{progress:e.percent}):o.createElement("span",null,i.assets.uploads.preparePhase),s=r<100&&o.createElement(f.default,{key:"btn-cancel",onClick:function(){return n.handleCancelAssetUpload(t)},style:"subtle"},p.ICON_TIMES);return o.createElement("div",{className:"ongoing-upload",key:t},o.createElement("div",{className:"ongoing-upload-inner"},o.createElement("div",{className:"upload-filename"},t),s),a)})):o.createElement("div",{className:"no-ongoing-uploads"},i.assets.uploads.noUploads),o.createElement("div",{className:"uploads-menu"},o.createElement("div",{className:"uploads-controls"},o.createElement(s.default,{width:"50%",label:i.assets.uploads.autoTagInput,value:a,onChange:function(){return n.props.toggleAutoTag(!a)}}),o.createElement(s.default,{width:"50%",label:i.assets.uploads.assignToStoryInput,info:i.assets.uploads.assignToStoryInfo,value:l,onChange:function(){return n.props.toggleAssignToStory(!l)}})),o.createElement("div",{className:"uploads-list"},e))},n}return a(t,e),t.prototype.handleCancelAssetUpload=function(e){var t=this.props.api;this.props.cancelAssetUpload(e,t)},t}(o.PureComponent);t.default=d.connect((function(e){return{assetUploads:e.assetUploads}}),(function(e){return c.bindActionCreators({toggleAutoTag:l.toggleAutoTag,toggleAssignToStory:l.toggleAssignToStory,cancelAssetUpload:l.cancelAssetUpload},e)}))(h)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PreviewNotAvailable=void 0;var r=n(0),a=n(4),o=n(7);t.PreviewNotAvailable=function(e){return!0===e.active||void 0===e.active?r.createElement("div",{className:"preview-not-available"},r.createElement("div",{className:"cta"},r.createElement("div",{className:"icon"},a.ICON_BAN),r.createElement("p",null,o.assets.previewNotAvailable))):null}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(34),s=n(26),u=function(e){function t(t){var n=e.call(this,t)||this;return n.width=1280,n.height=720,n.audioNode=o.createRef(),n}return a(t,e),t.prototype.getImageStyle=function(){var e=this.props,t=e.padding,n=e.width,r=e.height,a=void 0!==t?t:i.DEFAULT_PADDING;return s.getPlayerStyle(n,r,this.width,this.height,a)},t.prototype.render=function(){var e=this.props,t=e.url;return!1!==e.active?o.createElement("div",{className:"media-player"},o.createElement("div",{className:"inner-viewer",style:this.getImageStyle()},o.createElement("audio",{controls:!0,src:t,ref:this.audioNode}))):null},t}(o.PureComponent);t.default=u},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(87),u=n(5),l=n(7),c=n(4),d=function(e){function t(t){var n=e.call(this,t)||this;return n.videoNode=null,n.videoNode=i.createRef(),n.evtHandlers={onClose:function(e){return n.onClose(e)}},n}return a(t,e),t.prototype.onClose=function(e){(0,this.props.onRequestClose)(e)},t.prototype.render=function(){var e=this.props,t=e.showMedia,n=e.url,r=e.playbackSettings,a=e.style;return t?i.createElement(s.default,{id:"portal-root"},i.createElement("div",{style:o({},a),className:"close-icon-preview"},i.createElement(u.default,{key:"btn-filter",onClick:this.evtHandlers.onClose,size:"large",style:"subtle",tooltip:l.assets.field.tooltipFilter},c.ICON_TIMES)),i.createElement("video",{style:a,muted:!0,ref:this.videoNode,autoPlay:r.autoPlay,loop:r.loop,controls:!0,preload:"preload",src:n,className:"asset-preview-background"})):null},t}(i.PureComponent);t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(87),u=n(4),l=n(5),c=n(7),d=function(e){function t(t){var n=e.call(this,t)||this;return n.imageNode=null,n.imageNode=i.createRef(),n.evtHandlers={onClose:function(e){return n.onClose(e)}},n.state={loaded:!1},n}return a(t,e),t.prototype.onClose=function(e){(0,this.props.onRequestClose)(e)},t.prototype.render=function(){var e=this,t=this.props,n=t.showMedia,r=t.url,a=t.style,d=this.state.loaded;return n?i.createElement(s.default,{id:"portal-root"},i.createElement("div",{style:o({},a),className:"close-icon-preview"},i.createElement(l.default,{key:"btn-filter",onClick:this.evtHandlers.onClose,size:"large",style:"subtle",tooltip:c.assets.field.tooltipFilter},u.ICON_TIMES)),i.createElement("img",{onLoad:function(){return e.setState({loaded:!0})},src:r,ref:this.imageNode,className:"asset-preview-background transparent "+(d?"":"hidden"),style:a})):null},t}(i.PureComponent);t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(34),s=n(26),u=function(e){function t(t){var n=e.call(this,t)||this;return n.state={imageHeight:1080,imageWidth:1920},n.imgNode=o.createRef(),n}return a(t,e),t.prototype.getImageStyle=function(){var e=this.state,t=e.imageHeight,n=e.imageWidth,r=this.props,a=r.padding,o=r.width,u=r.height,l=void 0!==a?a:i.DEFAULT_PADDING;return t&&n?s.getPlayerStyle(o,u,n,t,l):{}},t.prototype.metadataLoaded=function(e){this.setState({imageWidth:e.target.naturalWidth,imageHeight:e.target.naturalHeight})},t.prototype.render=function(){var e=this.props;e.url;return!1!==e.active?o.createElement("div",{className:"mediap-player"},o.createElement("div",{className:"inner-viewer",style:this.getImageStyle()})):null},t}(o.PureComponent);t.default=u},function(e,t,n){var r,a,o;a=[t],void 0===(o="function"==typeof(r=function(e){"use strict";var t,n=this&&this.__makeTemplateObject||function(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e};!function(e){e[e.EOS=0]="EOS",e[e.Text=1]="Text",e[e.Incomplete=2]="Incomplete",e[e.ESC=3]="ESC",e[e.Unknown=4]="Unknown",e[e.SGR=5]="SGR",e[e.OSCURL=6]="OSCURL"}(t||(t={}));var r=function(){function e(){this.VERSION="4.0.4",this.setup_palettes(),this._use_classes=!1,this._escape_for_html=!0,this.bold=!1,this.fg=this.bg=null,this._buffer="",this._url_whitelist={http:1,https:1}}return Object.defineProperty(e.prototype,"use_classes",{get:function(){return this._use_classes},set:function(e){this._use_classes=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"escape_for_html",{get:function(){return this._escape_for_html},set:function(e){this._escape_for_html=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"url_whitelist",{get:function(){return this._url_whitelist},set:function(e){this._url_whitelist=e},enumerable:!0,configurable:!0}),e.prototype.setup_palettes=function(){var e=this;this.ansi_colors=[[{rgb:[0,0,0],class_name:"ansi-black"},{rgb:[187,0,0],class_name:"ansi-red"},{rgb:[0,187,0],class_name:"ansi-green"},{rgb:[187,187,0],class_name:"ansi-yellow"},{rgb:[0,0,187],class_name:"ansi-blue"},{rgb:[187,0,187],class_name:"ansi-magenta"},{rgb:[0,187,187],class_name:"ansi-cyan"},{rgb:[255,255,255],class_name:"ansi-white"}],[{rgb:[85,85,85],class_name:"ansi-bright-black"},{rgb:[255,85,85],class_name:"ansi-bright-red"},{rgb:[0,255,0],class_name:"ansi-bright-green"},{rgb:[255,255,85],class_name:"ansi-bright-yellow"},{rgb:[85,85,255],class_name:"ansi-bright-blue"},{rgb:[255,85,255],class_name:"ansi-bright-magenta"},{rgb:[85,255,255],class_name:"ansi-bright-cyan"},{rgb:[255,255,255],class_name:"ansi-bright-white"}]],this.palette_256=[],this.ansi_colors.forEach((function(t){t.forEach((function(t){e.palette_256.push(t)}))}));for(var t=[0,95,135,175,215,255],n=0;n<6;++n)for(var r=0;r<6;++r)for(var a=0;a<6;++a){var o={rgb:[t[n],t[r],t[a]],class_name:"truecolor"};this.palette_256.push(o)}for(var i=8,s=0;s<24;++s,i+=10){var u={rgb:[i,i,i],class_name:"truecolor"};this.palette_256.push(u)}},e.prototype.escape_txt_for_html=function(e){return e.replace(/[&<>]/gm,(function(e){return"&"===e?"&amp;":"<"===e?"&lt;":">"===e?"&gt;":void 0}))},e.prototype.append_buffer=function(e){var t=this._buffer+e;this._buffer=t},e.prototype.get_next_packet=function(){var e={kind:t.EOS,text:"",url:""},r=this._buffer.length;if(0==r)return e;var o=this._buffer.indexOf("");if(-1==o)return e.kind=t.Text,e.text=this._buffer,this._buffer="",e;if(o>0)return e.kind=t.Text,e.text=this._buffer.slice(0,o),this._buffer=this._buffer.slice(o),e;if(0==o){if(1==r)return e.kind=t.Incomplete,e;var i=this._buffer.charAt(1);if("["!=i&&"]"!=i)return e.kind=t.ESC,e.text=this._buffer.slice(0,1),this._buffer=this._buffer.slice(1),e;if("["==i){if(this._csi_regex||(this._csi_regex=a(n(["\n ^ # beginning of line\n #\n # First attempt\n (?: # legal sequence\n [ # CSI\n ([<-?]?) # private-mode char\n ([d;]*) # any digits or semicolons\n ([ -/]? # an intermediate modifier\n [@-~]) # the command\n )\n | # alternate (second attempt)\n (?: # illegal sequence\n [ # CSI\n [ -~]* # anything legal\n ([\0-:]) # anything illegal\n )\n "],["\n ^ # beginning of line\n #\n # First attempt\n (?: # legal sequence\n \\x1b\\[ # CSI\n ([\\x3c-\\x3f]?) # private-mode char\n ([\\d;]*) # any digits or semicolons\n ([\\x20-\\x2f]? # an intermediate modifier\n [\\x40-\\x7e]) # the command\n )\n | # alternate (second attempt)\n (?: # illegal sequence\n \\x1b\\[ # CSI\n [\\x20-\\x7e]* # anything legal\n ([\\x00-\\x1f:]) # anything illegal\n )\n "]))),null===(l=this._buffer.match(this._csi_regex)))return e.kind=t.Incomplete,e;if(l[4])return e.kind=t.ESC,e.text=this._buffer.slice(0,1),this._buffer=this._buffer.slice(1),e;""!=l[1]||"m"!=l[3]?e.kind=t.Unknown:e.kind=t.SGR,e.text=l[2];var s=l[0].length;return this._buffer=this._buffer.slice(s),e}if("]"==i){if(r<4)return e.kind=t.Incomplete,e;if("8"!=this._buffer.charAt(2)||";"!=this._buffer.charAt(3))return e.kind=t.ESC,e.text=this._buffer.slice(0,1),this._buffer=this._buffer.slice(1),e;this._osc_st||(this._osc_st=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=e.raw[0],a=/^\s+|\s+\n|\s*#[\s\S]*?\n|\n/gm,o=r.replace(a,"");return new RegExp(o,"g")}(n(["\n (?: # legal sequence\n (\\) # ESC | # alternate\n () # BEL (what xterm did)\n )\n | # alternate (second attempt)\n ( # illegal sequence\n [\0-] # anything illegal\n | # alternate\n [\b-] # anything illegal\n | # alternate\n [-] # anything illegal\n )\n "],["\n (?: # legal sequence\n (\\x1b\\\\) # ESC \\\n | # alternate\n (\\x07) # BEL (what xterm did)\n )\n | # alternate (second attempt)\n ( # illegal sequence\n [\\x00-\\x06] # anything illegal\n | # alternate\n [\\x08-\\x1a] # anything illegal\n | # alternate\n [\\x1c-\\x1f] # anything illegal\n )\n "]))),this._osc_st.lastIndex=0;var u=this._osc_st.exec(this._buffer);if(null===u)return e.kind=t.Incomplete,e;if(u[3])return e.kind=t.ESC,e.text=this._buffer.slice(0,1),this._buffer=this._buffer.slice(1),e;var l,c=this._osc_st.exec(this._buffer);return null===c?(e.kind=t.Incomplete,e):c[3]?(e.kind=t.ESC,e.text=this._buffer.slice(0,1),this._buffer=this._buffer.slice(1),e):(this._osc_regex||(this._osc_regex=a(n(["\n ^ # beginning of line\n #\n ]8; # OSC Hyperlink\n [ -:<-~]* # params (excluding ;)\n ; # end of params\n ([!-~]{0,512}) # URL capture\n (?: # ST\n (?:\\) # ESC | # alternate\n (?:) # BEL (what xterm did)\n )\n ([!-~]+) # TEXT capture\n ]8;; # OSC Hyperlink End\n (?: # ST\n (?:\\) # ESC | # alternate\n (?:) # BEL (what xterm did)\n )\n "],["\n ^ # beginning of line\n #\n \\x1b\\]8; # OSC Hyperlink\n [\\x20-\\x3a\\x3c-\\x7e]* # params (excluding ;)\n ; # end of params\n ([\\x21-\\x7e]{0,512}) # URL capture\n (?: # ST\n (?:\\x1b\\\\) # ESC \\\n | # alternate\n (?:\\x07) # BEL (what xterm did)\n )\n ([\\x21-\\x7e]+) # TEXT capture\n \\x1b\\]8;; # OSC Hyperlink End\n (?: # ST\n (?:\\x1b\\\\) # ESC \\\n | # alternate\n (?:\\x07) # BEL (what xterm did)\n )\n "]))),null===(l=this._buffer.match(this._osc_regex))?(e.kind=t.ESC,e.text=this._buffer.slice(0,1),this._buffer=this._buffer.slice(1),e):(e.kind=t.OSCURL,e.url=l[1],e.text=l[2],s=l[0].length,this._buffer=this._buffer.slice(s),e))}}},e.prototype.ansi_to_html=function(e){this.append_buffer(e);for(var n=[];;){var r=this.get_next_packet();if(r.kind==t.EOS||r.kind==t.Incomplete)break;r.kind!=t.ESC&&r.kind!=t.Unknown&&(r.kind==t.Text?n.push(this.transform_to_html(this.with_state(r))):r.kind==t.SGR?this.process_ansi(r):r.kind==t.OSCURL&&n.push(this.process_hyperlink(r)))}return n.join("")},e.prototype.with_state=function(e){return{bold:this.bold,fg:this.fg,bg:this.bg,text:e.text}},e.prototype.process_ansi=function(e){for(var t=e.text.split(";");t.length>0;){var n=t.shift(),r=parseInt(n,10);if(isNaN(r)||0===r)this.fg=this.bg=null,this.bold=!1;else if(1===r)this.bold=!0;else if(22===r)this.bold=!1;else if(39===r)this.fg=null;else if(49===r)this.bg=null;else if(r>=30&&r<38)this.fg=this.ansi_colors[0][r-30];else if(r>=40&&r<48)this.bg=this.ansi_colors[0][r-40];else if(r>=90&&r<98)this.fg=this.ansi_colors[1][r-90];else if(r>=100&&r<108)this.bg=this.ansi_colors[1][r-100];else if((38===r||48===r)&&t.length>0){var a=38===r,o=t.shift();if("5"===o&&t.length>0){var i=parseInt(t.shift(),10);i>=0&&i<=255&&(a?this.fg=this.palette_256[i]:this.bg=this.palette_256[i])}if("2"===o&&t.length>2){var s=parseInt(t.shift(),10),u=parseInt(t.shift(),10),l=parseInt(t.shift(),10);if(s>=0&&s<=255&&u>=0&&u<=255&&l>=0&&l<=255){var c={rgb:[s,u,l],class_name:"truecolor"};a?this.fg=c:this.bg=c}}}}},e.prototype.transform_to_html=function(e){var t=e.text;if(0===t.length)return t;if(this._escape_for_html&&(t=this.escape_txt_for_html(t)),!e.bold&&null===e.fg&&null===e.bg)return t;var n=[],r=[],a=e.fg,o=e.bg;e.bold&&n.push("font-weight:bold"),this._use_classes?(a&&("truecolor"!==a.class_name?r.push(a.class_name+"-fg"):n.push("color:rgb("+a.rgb.join(",")+")")),o&&("truecolor"!==o.class_name?r.push(o.class_name+"-bg"):n.push("background-color:rgb("+o.rgb.join(",")+")"))):(a&&n.push("color:rgb("+a.rgb.join(",")+")"),o&&n.push("background-color:rgb("+o.rgb+")"));var i="",s="";return r.length&&(i=' class="'+r.join(" ")+'"'),n.length&&(s=' style="'+n.join(";")+'"'),"<span"+s+i+">"+t+"</span>"},e.prototype.process_hyperlink=function(e){var t=e.url.split(":");return t.length<1?"":this._url_whitelist[t[0]]?'<a href="'+this.escape_txt_for_html(e.url)+'">'+this.escape_txt_for_html(e.text)+"</a>":""},e}();function a(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=e.raw[0],a=/^\s+|\s+\n|\s*#[\s\S]*?\n|\n/gm,o=r.replace(a,"");return new RegExp(o)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=r})?r.apply(t,a):r)||(e.exports=o)},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(133),u=n(500),l=n(13),c=n(5),d=n(21),p=n(41),f=n(22),h=n(63),m=n(11),_=n(16),y=n(26),g=n(131),v=n(501),b=n(101),w=n(7),M=n(9),L=n(134),T=n(132),k=n(8),x=function(e){function t(t){var n=e.call(this,t)||this;n.TIMEOUT="02:00";var r=n.getInventoryDefaults(),a=n.getInventoryOptions();return n.state={inventory:r,inventoryOptions:a,experienceId:null,jobId:null,experience:null,timeElapsed:0,activeOutput:"",rendering:!1,isTimeOut:!1},n.timer=new L.default({interval:1e3,onUpdate:function(e){n.setState({timeElapsed:e})}}),n.evtHandlers={toggleOutput:function(e){return n.toggleActiveOutput(e)},createExp:function(){return n.createExperience()},gotExperience:null},n}return a(t,e),t.prototype.componentWillUnmount=function(){var e=this.props,t=e.api;e.onError,this.state.experienceId;this.timer.stop(),this.evtHandlers.gotExperience=null,t.cancelExperiencePolling()},t.prototype.getInventoryOptions=function(){var e=this.props.variables,t={};for(var n in e)if(e.hasOwnProperty(n)){var r=e[n];r.defaultItem&&r.defaultItem.type&&r.defaultItem.type.toLowerCase()===s.VARIABLE_TYPES.ENUM&&(t[r.id]=r.defaultItem.options)}return t},t.prototype.getInventoryDefaults=function(){var e=this.props.variables,t={};for(var n in e)if(e.hasOwnProperty(n)){var r=e[n];t[r.id]=this.getVariableValue(r.previewItem)}return t},t.prototype.checkInventoryDefaults=function(e){var t=this.props.variables,n=o({},this.state.inventory);for(var r in t)if(t.hasOwnProperty(r)){var a=t[r],i=e[r];if(i){var s=this.getVariableValue(i.previewItem),u=this.getVariableValue(a.previewItem);a.type===i.type&&s===u||(n[r]=u)}}return n},t.prototype.getVariableValue=function(e){if(e&&e.type){var t=e.type.toLowerCase();return t===s.VARIABLE_TYPES.IMAGE||t===s.VARIABLE_TYPES.VIDEO||t===s.VARIABLE_TYPES.AUDIO?e.url:e.src}},t.prototype.componentDidMount=function(){var e=this,t=this.props,n=t.experienceId,r=t.jobId;n&&r&&this.setState({jobId:r},(function(){e.getExperience(n)}))},t.prototype.componentDidUpdate=function(e,t){var n=this;if(e.storyId!==this.props.storyId&&(this.evtHandlers.gotExperience=null),e.variables!==this.props.variables){var r=void 0,a=this.getInventoryOptions();r=e.storyId===this.props.storyId?this.checkInventoryDefaults(e.variables):this.getInventoryDefaults(),this.setState({inventoryOptions:a,inventory:r})}if(this.props.notifications&&this.props.notifications[0]&&("error"===this.props.notifications[0].type&&this.setState({isTimeOut:!0}),"info"===this.props.notifications[0].type&&this.setState({isTimeOut:!1})),t.timeElapsed!==this.state.timeElapsed&&M.formattedTime(this.state.timeElapsed)===this.TIMEOUT&&!this.state.experience){var o=this.props,i=o.onError,s=o.api,u=this.state.experienceId;s.cancelExperiencePolling().then((function(){i(w.previewer.runExpError.replace("[expId]",u)),n.resetState(!0,(function(){n.setState({isTimeOut:!0})}))}))}},t.prototype.variableInputChanged=function(e,t){var n=o({},this.state.inventory);n[e]=t,this.setState({inventory:n})},t.prototype.getViewerOptions=function(){var e=[],t=this.state,n=t.experience.output,r=t.jobId,a=n.videos,o=n.images;if(a)for(var i in a)if(a.hasOwnProperty(i)){var s={label:"Video: "+i,value:u.OUTPUT_TYPES.VIDEO+"."+i};e.push(s)}if(o)for(var i in o)if(o.hasOwnProperty(i)){var l={label:"Image: "+i,value:u.OUTPUT_TYPES.IMAGE+"."+i};e.push(l)}return r&&e.push({label:w.previewer.btnLog,value:u.OUTPUT_TYPES.LOG+"."+r}),e},t.prototype.renderVariableFields=function(){var e=this,t=this.state,n=t.inventory,r=t.inventoryOptions,a=this.props.variables,o=[],u=function(t){if(a.hasOwnProperty(t)){var u=a[t];switch(u.type.toLowerCase()){case s.VARIABLE_TYPES.TEXT:o.push(i.createElement(l.default,{label:u.name,key:u.id,value:n[u.id],onChange:function(t){return e.variableInputChanged(u.id,t)}}));break;case s.VARIABLE_TYPES.NUMBER:o.push(i.createElement(p.default,{label:u.name,key:u.id,value:n[u.id],onChange:function(t){return e.variableInputChanged(u.id,t)}}));break;case s.VARIABLE_TYPES.ENUM:o.push(i.createElement(f.default,{label:u.name,key:u.id,value:n[u.id],options:r[u.id],onChange:function(t){return e.variableInputChanged(u.id,t)}}));break;case s.VARIABLE_TYPES.BOOLEAN:o.push(i.createElement(h.default,{label:u.name,key:u.id,value:n[u.id],options:s.BOOLEAN_DEFAULT_OPTIONS,onChange:function(t){return e.variableInputChanged(u.id,t)}}));break;case s.VARIABLE_TYPES.IMAGE:o.push(i.createElement(m.default,{label:u.name,key:u.id},i.createElement(v.default,{value:n[u.id],type:u.type,onChange:function(t){return e.variableInputChanged(u.id,t)}})));break;case s.VARIABLE_TYPES.VIDEO:case s.VARIABLE_TYPES.AUDIO:o.push(i.createElement(m.default,{label:u.name,key:u.id},i.createElement(v.default,{type:u.type,value:n[u.id],onChange:function(t){return e.variableInputChanged(u.id,t)}})))}}};for(var c in a)u(c);return o},t.prototype.getFirstOutput=function(e){var t=e.output.videos,n=e.output.images;if(t){for(var r in t)if(t.hasOwnProperty(r))return u.OUTPUT_TYPES.VIDEO+"."+r}else{if(!n)return null;for(var r in n)if(n.hasOwnProperty(r))return u.OUTPUT_TYPES.IMAGE+"."+r}},t.prototype.getExperience=function(e,t,n,r){var a=this;void 0===t&&(t=!1),this.timer.running||this.timer.start();var o=this.props,i=o.api,s=o.onError,u=o.onExperenceLoaded,l=o.onJobCreated;this.setState({rendering:!0},(function(){a.setState({experienceId:e},(function(){t?i.triggerEvent(e,n,r).then((function(t){a.setState({jobId:t.job_id},(function(){l&&l(e,t.job_id),a.evtHandlers.gotExperience=function(e){a.timer.stop(),u&&u(e),a.setState({rendering:!1,activeOutput:a.getFirstOutput(e),experience:e})};i.getExperience(e,!0).then((function(e){a.evtHandlers.gotExperience&&a.evtHandlers.gotExperience(e)})).catch((function(t){a.resetState(),s&&(t.error?s(t.error):s(w.previewer.runExpError.replace("[expId]",e)))}))}))})).catch((function(t){a.resetState(),s&&s(w.previewer.triggerExpError.replace("[expId]",e))})):(a.evtHandlers.gotExperience=function(e){a.timer.stop(),u&&u(e),a.setState({rendering:!1,activeOutput:a.getFirstOutput(e),experience:e})},i.getExperience(e,!0).then((function(e){a.evtHandlers.gotExperience&&a.evtHandlers.gotExperience(e)})).catch((function(t){a.resetState(),s&&(t.error?s(t.error):s(w.previewer.runExpError.replace("[expId]",e)))})))}))}))},t.prototype.createExperience=function(){var e=this,t=this.props,n=t.storyId,r=t.onNotification,a=t.onError,o=t.api,i=t.onExperienceCreated,s=t.compositionId,u=t.useWorkingCopy;this.resetState(!1,(function(){e.setState({rendering:!0,isTimeOut:!1},(function(){e.timer.start(),r&&r(w.previewer.runExpStart),o.createExperience(n,e.state.inventory,s,u).then((function(t){r&&r(w.previewer.expId.replace("[expId]",t.id)),i&&i(t),e.getExperience(t.id,!0,s,u)})).catch((function(t){e.resetState();var n=t.response,r=n.data;n.status;a&&(r&&r.error?a(w.previewer.createExpError+": "+r.error):a(w.previewer.createExpError+": "+t))}))}))}))},t.prototype.resetState=function(e,t){this.timer.stop(),this.setState({rendering:!1,experienceId:null,experience:null,jobId:null,timeElapsed:e?this.state.timeElapsed:0,activeOutput:null,isTimeOut:!1},(function(){t&&t()}))},t.prototype.renderViewerContent=function(){var e=this.state,t=e.rendering,n=e.experience,r=e.timeElapsed,a=e.activeOutput,o=e.isTimeOut,s=this.props,l=s.api,c=s.onError;if(t)return i.createElement("div",{className:"running-prompt"},i.createElement(d.default,null),i.createElement("br",null),i.createElement("h1",null,"  ",w.previewer.expRunning),i.createElement("p",null,w.previewer.time," ",M.formattedTime(r)));if(o||void 0===o)return i.createElement("div",{className:"running-prompt error-wrapper"},i.createElement("h1",null,"  ",w.previewer.runExpErrorDes),i.createElement("p",null,w.previewer.time," ",M.formattedTime(r)));if(n&&a){var p=void 0,f=void 0,h=a.split("."),m=h[0],_=h[1];if(m===u.OUTPUT_TYPES.IMAGE)f=n.output.images[_],p=i.createElement(g.default,{url:f,active:!0});else if(m===u.OUTPUT_TYPES.VIDEO){var v=n.output.videos[_],L=void 0!==v.width?parseInt(v.width,10):null,k=void 0!==v.height?parseInt(v.height,10):null;f=v.url,p=i.createElement(y.default,{url:f,active:!0,maxWidth:L,allowManualScale:!0,maxHeight:k})}else m===u.OUTPUT_TYPES.LOG&&(p=i.createElement("div",{className:"log"},i.createElement(T.default,{api:l,onError:c,jobId:_})));return i.createElement(b.default,{handleWidth:!0,handleHeight:!0},p)}return null},t.prototype.toggleActiveOutput=function(e){this.setState({activeOutput:e})},t.prototype.render=function(){var e,t,n=this.state,r=n.rendering,a=n.experience,o=n.activeOutput,s=a?w.previewer.btnReRender:w.previewer.btnRender,u=r?null:i.createElement(c.default,{size:"large",onClick:this.evtHandlers.createExp,color:"primary",style:"bold"},s);if(a){var d=this.getViewerOptions();e=i.createElement(f.default,{width:"130px",options:d,value:o,onChange:this.evtHandlers.toggleOutput}),t=i.createElement(l.default,{readOnly:!0,width:"360px",label:w.previewer.expIdField,showCopy:!0,value:a.id})}return i.createElement("div",{className:"story-viewer viewer"},i.createElement("div",{className:"variables"},i.createElement("h2",null,w.previewer.previewVars),i.createElement(_.default,null),this.renderVariableFields()),i.createElement("div",{className:"viewer-content"},i.createElement("div",{className:"content-header"},u,i.createElement("div",{className:"output"},e),i.createElement("div",{className:"right-interface"},t)),i.createElement("div",{className:"content-wrapper"},this.renderViewerContent())))},t}(i.PureComponent);t.default=k.connect((function(e){return{notifications:e.notifications}}),{})(x)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.OUTPUT_TYPES=void 0,t.OUTPUT_TYPES={LOG:"log",IMAGE:"image",VIDEO:"video"}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(21),s=n(133),u=n(84),l=n(5),c=n(4),d=function(e){function t(t){var n=e.call(this,t)||this;return n.input=o.createRef(),n.state={processing:!1,processedFile:null},n.evtHandlers={fileUpload:function(e){return n.fileUploaded(e)},fileDrop:function(e,t){return n.onFileDrop(e,t)},clearSelection:function(e){return n.clearSelection(e)},click:function(){return n.onClick()}},n}return a(t,e),t.prototype.clearSelection=function(e){e.preventDefault(),e.stopPropagation(),this.props.onChange(null)},t.prototype.fileUploaded=function(e){var t=e.target.files[0];t&&this.props.onChange(t)},t.prototype.componentDidUpdate=function(e){e.value!==this.props.value&&this.checkFile()},t.prototype.componentDidMount=function(){this.checkFile()},t.prototype.checkFile=function(){var e=this,t=this.props.value;t instanceof File&&this.setState({processing:!0,processedFile:null},(function(){var n=new FileReader;n.onload=function(){e.setState({processing:!1,processedFile:n.result})},n.readAsDataURL(t)}))},t.prototype.renderFields=function(){var e,t=this.state,n=t.processing,r=t.processedFile,a=this.props,u=a.type,l=a.value,c=l instanceof File;if(!l)return null;if(c){if(n)return o.createElement(i.default,null);e=r}else e=l;switch(u.toLowerCase()){case s.VARIABLE_TYPES.IMAGE:return o.createElement("img",{className:"default-preview",src:e});case s.VARIABLE_TYPES.VIDEO:return o.createElement("video",{className:"default-preview",src:e,controls:!0});case s.VARIABLE_TYPES.AUDIO:return o.createElement("audio",{className:"default-preview",src:e,controls:!0})}},t.prototype.getInputFilter=function(){var e=this.props,t=e.type;e.value;switch(t){case s.VARIABLE_TYPES.IMAGE:return"image/*";case s.VARIABLE_TYPES.VIDEO:return"video/*";case s.VARIABLE_TYPES.AUDIO:return"audio/*"}},t.prototype.onClick=function(){var e=this.input.current,t=this.state.processing;e&&!t&&e.click()},t.prototype.renderClearButton=function(){if(this.props.value)return o.createElement(l.default,{onClick:this.evtHandlers.clearSelection},c.ICON_TIMES)},t.prototype.onFileDrop=function(e,t){var n=t.getItem().files[0];n&&this.props.onChange(n)},t.prototype.render=function(){var e=this.state.processing,t=this.getInputFilter();return o.createElement(o.Fragment,null,o.createElement("input",{type:"file",accept:t,style:{display:"none"},ref:this.input,onChange:this.evtHandlers.fileUpload}),o.createElement(u.default,{onDrop:this.evtHandlers.fileDrop,disable:e},o.createElement("div",{className:"variable-default-upload",onClick:this.evtHandlers.click},this.renderFields(),o.createElement("div",{className:"btn-wrapper"},this.renderClearButton()))))},t}(o.PureComponent);t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(503),s=n(135),u=n(53),l=function(e){function t(t){var n=e.call(this,t)||this;return n.state={selectedLayer:null},n.eventHandlers={updateSelectedLayer:function(e){return n.updateSelectedLayer(e)}},n}return a(t,e),t.prototype.updateSelectedLayer=function(e){this.setState({selectedLayer:e})},t.prototype.variablesToInventory=function(){var e=this.props.variables,t={};for(var n in e)if(e.hasOwnProperty(n)){var r=e[n],a=r.type,o=r.previewItem;o&&(a===u.VARIABLE_TYPES.IMAGE||a===u.VARIABLE_TYPES.VIDEO||a===u.VARIABLE_TYPES.AUDIO?t[n]=o.url:t[n]=o.src)}return t},t.prototype.render=function(){var e=this.state.selectedLayer,t=this.props,n=t.storyId,r=t.api,a=t.composition;return a?o.createElement("div",{className:"static-composition-editor"},o.createElement("div",{className:"composition-config"},o.createElement(i.default,{storyId:n,api:r,composition:a,onSelectLayer:this.eventHandlers.updateSelectedLayer,selectedLayer:e,onUpdate:this.props.onUpdate})),o.createElement("div",{className:"composition-preview"},o.createElement(s.default,{inventory:this.variablesToInventory(),composition:a,onSelectLayer:this.eventHandlers.updateSelectedLayer,selectedLayer:e,onUpdate:this.props.onUpdate}))):null},t}(o.PureComponent);t.default=l},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},i=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},s=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),l=n(7),c=n(41),d=n(65),p=n(11),f=n(5),h=n(53),m=n(4),_=n(504),y=function(e){function t(t){var n=e.call(this,t)||this;return n.eventHandlers={inputs:{width:function(e){return n.compValueChanged("width",e)},height:function(e){return n.compValueChanged("height",e)},name:function(e){return n.compValueChanged("name",e)},backgroundColor:function(e){return n.bgChanged(e)}},selectLayer:function(e){return n.props.onSelectLayer(e)}},n.addLayerMenu=u.createElement(f.default,{onClick:function(){return n.addLayer()},style:"subtle",size:"small",color:"primary"},m.ICON_PLUS),n}return a(t,e),t.prototype.addLayer=function(){var e=h.getNewCompositionLayer(),t=o({},this.props.composition),n=s([],i(t.layers));n.push(e),t.layers=n,this.props.onUpdate(t),this.props.onSelectLayer(e.id)},t.prototype.updateLayer=function(e,t){var n=o({},this.props.composition),r=s([],i(n.layers));r[e]=t,n.layers=r,this.props.onUpdate(n)},t.prototype.compValueChanged=function(e,t){var n=o({},this.props.composition);n[e]=t,this.props.onUpdate(n)},t.prototype.bgChanged=function(e){if("transparent"===e.hex)this.compValueChanged("background_color",null);else{var t=e.rgb;this.compValueChanged("background_color","rgba("+t.r+","+t.g+","+t.b+","+t.a+")")}},t.prototype.render=function(){var e=this,t=this.props,n=t.composition,r=t.selectedLayer,a=t.storyId,o=t.api,i=(n.background_color&&n.background_color,u.createElement("span",null,l.compositions.layers," ",this.addLayerMenu));return u.createElement(u.Fragment,null,u.createElement(c.default,{label:l.compositions.width,tooltip:l.compositions.tooltipWidth,value:n.width,width:"30%",labelPosition:"top",onChange:this.eventHandlers.inputs.width}),u.createElement(c.default,{label:l.compositions.height,tooltip:l.compositions.tooltipHeight,value:n.height,width:"30%",labelPosition:"top",onChange:this.eventHandlers.inputs.height}),u.createElement(d.default,{label:l.compositions.backgroundColor,tooltip:l.compositions.tooltipBackgroundColor,enableAlpha:!0,value:n.background_color,width:"40%",labelPosition:"top",pickerPosition:"right",onChange:this.eventHandlers.inputs.backgroundColor}),u.createElement(p.default,{label:i,width:"100%",labelPosition:"top"},n.layers.map((function(t,n){var i=t.id===r;return u.createElement(_.default,{storyId:a,api:o,key:t.id,selected:i,onSelectLayer:e.eventHandlers.selectLayer,onUpdate:function(t){return e.updateLayer(n,t)},options:t})}))))},t}(u.PureComponent);t.default=y},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.V_ALIGN_OPTIONS=t.H_ALIGN_OPTIONS=void 0;var i=n(0),s=n(53),u=n(25),l=n(64),c=n(63),d=n(13),p=n(22),f=n(99),h=n(129),m=n(7),_=n(65),y=n(30),g=n(41),v=n(4);t.H_ALIGN_OPTIONS=[{icon:v.ICON_ALIGN_LEFT,value:"left"},{icon:v.ICON_ALIGN_CENTER,value:"center"},{icon:v.ICON_ALIGN_RIGHT,value:"right"}],t.V_ALIGN_OPTIONS=[{icon:v.ICON_ARROW_UP,value:"flex-start"},{icon:v.ICON_ARROW_CENTER_V,value:"center"},{icon:v.ICON_ARROW_DOWN,value:"flex-end"}];var b=function(e){function n(t){var n=e.call(this,t)||this;return n.eventHandlers={inputs:{name:function(e){return n.optionValueChanged("name",e)},width:function(e){return n.optionValueChanged("width",e)},height:function(e){return n.optionValueChanged("height",e)},x:function(e){return n.optionValueChanged("x",e)},y:function(e){return n.optionValueChanged("y",e)},rotation:function(e){return n.optionValueChanged("rotation",e)},content:function(e){return n.optionValueChanged("content",e)},hAlign:function(e){return n.optionValueChanged("horizontal_alignment",e)},vAlign:function(e){return n.optionValueChanged("vertical_alignment",e)},textWrap:function(e){return n.optionValueChanged("text_wrap",e)},textFit:function(e){return n.optionValueChanged("text_fit",e)},fontSize:function(e){return n.optionValueChanged("font_size",e)},lineHeight:function(e){return n.optionValueChanged("line_height",e)},letterSpacing:function(e){return n.optionValueChanged("letter_spacing",e)},font:function(e){return n.optionValueChanged("font",e)},customFont:function(e){return n.customFontUpdated(e)},fontType:function(e){return n.fontTypeChanged(e)},wordSpacing:function(e){return n.optionValueChanged("word_spacing",e)},color:function(e){return n.optionValueChanged("color",n.formatColor(e))},backgroundColor:function(e){return n.optionValueChanged("background_color",n.formatColor(e))}},onCardOpen:function(e){return n.onCardOpen()},onCardClose:function(e){return n.onCardClose()}},n}return a(n,e),n.prototype.customFontUpdated=function(e){var t=o({},this.props.options);if(e){var n=e.name,r=e.url,a=e.id;t.font=n,t.custom_font_url=r,t.custom_font_id=a}else t.font=s.DEFAULT_FONT,t.custom_font_url=null,t.custom_font_id=null;this.props.onUpdate(t)},n.prototype.onCardOpen=function(){var e=this.props.options.id;this.props.onSelectLayer(e)},n.prototype.onCardClose=function(){this.props.onSelectLayer(null)},n.prototype.fontTypeChanged=function(e){var t=o({},this.props.options);e===s.FONT_TYPES.STANDARD?(t.font_type=s.FONT_TYPES.STANDARD,t.font=s.DEFAULT_FONT):e===s.FONT_TYPES.CUSTOM&&(t.fontType=s.FONT_TYPES.CUSTOM,t.font=s.DEFAULT_FONT,t.custom_font_id=null,t.custom_font_url=null),this.props.onUpdate(t)},n.prototype.formatColor=function(e){var t=e.rgb;return"rgba("+t.r+","+t.g+","+t.b+","+t.a+")"},n.prototype.optionValueChanged=function(e,t){var n=o({},this.props.options);n[e]=t,this.props.onUpdate(n)},n.prototype.renderFontField=function(){var e=this.props,t=e.options,n=t.font_type,r=t.custom_font_id,a=t.font,o=e.storyId,l=e.api;return n===s.FONT_TYPES.STANDARD?i.createElement(p.default,{label:m.compositions.font,labelPosition:"top",width:"50%",options:s.STADARD_FONTS,onChange:this.eventHandlers.inputs.font,value:a}):n===s.FONT_TYPES.CUSTOM?i.createElement(h.default,{api:l,storyId:o,label:m.compositions.font,width:"50%",labelPosition:"top",onChange:this.eventHandlers.inputs.customFont,accepts:u.ASSET_TYPES.FONT,assetId:r}):null},n.prototype.render=function(){var e=this.props,n=e.options,r=e.selected;return i.createElement(f.default,{open:r,onOpen:this.eventHandlers.onCardOpen,onClose:this.eventHandlers.onCardClose,collapsable:!0,title:n.name},i.createElement(d.default,{label:m.compositions.name,tooltip:m.compositions.tooltipName,value:n.name,width:"100%",labelPosition:"top",onChange:this.eventHandlers.inputs.name}),i.createElement(g.default,{label:m.compositions.x,tooltip:m.compositions.tooltipLayerX,value:n.x,width:"20%",labelPosition:"top",onChange:this.eventHandlers.inputs.x}),i.createElement(g.default,{label:m.compositions.y,tooltip:m.compositions.tooltipLayerY,value:n.y,width:"20%",labelPosition:"top",onChange:this.eventHandlers.inputs.y}),i.createElement(g.default,{label:m.compositions.width,tooltip:m.compositions.tooltipLayerWidth,value:n.width,width:"20%",labelPosition:"top",onChange:this.eventHandlers.inputs.width}),i.createElement(g.default,{label:m.compositions.height,tooltip:m.compositions.tooltipLayerHeight,value:n.height,width:"20%",labelPosition:"top",onChange:this.eventHandlers.inputs.height}),i.createElement(g.default,{value:n.rotation,label:m.compositions.rotation,tooltip:m.compositions.tooltipLayerRotation,width:"20%",labelPosition:"top",onChange:this.eventHandlers.inputs.rotation}),i.createElement(l.default,{label:m.compositions.textLayerContent,tooltip:m.compositions.tooltipTextLayerContent,value:n.content,width:"100%",labelPosition:"top",onChange:this.eventHandlers.inputs.content}),i.createElement(c.default,{options:t.H_ALIGN_OPTIONS,value:n.horizontal_alignment,width:"50%",onChange:this.eventHandlers.inputs.hAlign}),i.createElement(c.default,{options:t.V_ALIGN_OPTIONS,value:n.vertical_alignment,width:"50%",onChange:this.eventHandlers.inputs.vAlign}),i.createElement(p.default,{label:m.compositions.fontType,options:s.FONT_TYPE_OPTIONS,value:n.font_type,width:"50%",labelPosition:"top",onChange:this.eventHandlers.inputs.fontType}),this.renderFontField(),i.createElement(g.default,{label:m.compositions.fontSize,value:n.font_size,width:"50%",labelPosition:"top",onChange:this.eventHandlers.inputs.fontSize}),i.createElement(g.default,{label:m.compositions.lineHeight,value:n.line_height,width:"50%",labelPosition:"top",onChange:this.eventHandlers.inputs.lineHeight}),i.createElement(g.default,{label:m.compositions.letterSpacing,value:n.letter_spacing,width:"50%",labelPosition:"top",onChange:this.eventHandlers.inputs.letterSpacing}),i.createElement(g.default,{label:m.compositions.wordSpacing,value:n.word_spacing,width:"50%",labelPosition:"top",onChange:this.eventHandlers.inputs.wordSpacing}),i.createElement(_.default,{label:m.compositions.color,value:n.color,enableAlpha:!0,width:"50%",labelPosition:"top",pickerPosition:"left",onChange:this.eventHandlers.inputs.color}),i.createElement(_.default,{label:m.compositions.backgroundColor,value:n.background_color,enableAlpha:!0,width:"50%",labelPosition:"top",pickerPosition:"right",onChange:this.eventHandlers.inputs.backgroundColor}),i.createElement(y.default,{label:m.compositions.wrap,value:n.text_wrap,width:"25%",labelPosition:"top",onChange:this.eventHandlers.inputs.textWrap}),i.createElement(y.default,{label:m.compositions.fit,value:n.text_fit,width:"25%",labelPosition:"top",onChange:this.eventHandlers.inputs.textFit}))},n}(i.PureComponent);t.default=b},function(e,t){e.exports=f},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(16);t.default=function(e){var t=e.shortcutCopyMap,n=e.heading,o=n?r.createElement(r.Fragment,null,r.createElement("h3",null,n),r.createElement(a.default,null)):null;return r.createElement("div",{className:"shortcuts-menu"},o,r.createElement("table",null,r.createElement("tbody",null,Object.keys(t).map((function(e){return r.createElement("tr",{className:"shortcut",key:e},r.createElement("td",{className:"hotkey-cell"},e),r.createElement("td",{className:"shortcut-desc"},t[e]))})))))}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(13),s=n(11),u=n(51),l=n(16),c=n(9),d=n(8),p=n(7),f=function(e){function t(t){var n=e.call(this,t)||this;return n.render=function(){var e=n.props,t=e.asset,r=e.columns,a=e.newAsset,u=e.assetTags;if(!t)return null;var d=a?p.assets.newDetails:p.assets.details,f=c.formatDateDefault(t.date_created),h=2===r,m=a?void 0:function(e){return n.props.onNameChange(e)},_=a?function(e){return n.props.onNameChange(e)}:void 0,y=o.createElement(i.default,{label:p.assets.name,controlled:!a,width:h?"50%":"100%",onSubmit:m,onChange:_,value:t.name}),g=o.createElement(i.default,{readOnly:!0,label:p.assets.date,width:h?"50%":"100%",value:f}),v=o.createElement(i.default,{submittable:!0,submittableType:"add",label:p.assets.addTag,suggestions:u,doSubmit:function(e){return n.props.onAddTag(e)},width:h?"50%":"100%",buttons:[],value:n.state.newTag}),b=o.createElement(s.default,{label:p.assets.assetTag,width:h?"50%":"100%"},n.renderTags());return o.createElement("div",{className:"asset-details"},o.createElement("h2",null,d),o.createElement("div",{className:"header-buttons"},n.props.headerButtons),o.createElement(l.default,null),y,g,v,b)},n.state={newTag:""},n}return a(t,e),t.prototype.renderTags=function(){var e=this;return this.props.asset.tags.map((function(t){return o.createElement(u.default,{key:t,copy:t,removeHandler:function(){return e.props.onRemoveTag(t)},colorize:!0})}))},t}(o.Component);t.default=d.connect((function(e){return{assetTags:e.assetTags}}),null)(f)},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(5),s=n(64),u=n(16),l=n(7),c=n(4),d=function(e){function t(t){var n=e.call(this,t)||this;return n.getFirstAct=function(e){for(var t in e.acts)if(e.acts.hasOwnProperty(t))return e.acts[t]},n}return a(t,e),t.prototype.createUrl=function(){var e=this.props,t=e.story,n=e.compositionId,r=e.accessKey,a=t.id,o=this.getFirstAct(t).inventory,i="";for(var s in o){if(o.hasOwnProperty(s))i+=""+(i?"&":"?")+s+"={{"+s.toUpperCase()+"}}"}var u=window.location.href,l=-1!==u.indexOf("staging")||-1!==u.indexOf("localhost")?"staging.imposium.com":"imposium.com";return'<a href="'+("https://player."+l+"/new/"+r+"/"+a+"/"+n+i)+'" target="_blank"><img width="400" alt="Play Video" src="'+("https://api."+l+"/story/"+a+"/"+n+"/poster"+i)+'"></a>'},t.prototype.render=function(){var e=this.props,t=e.status,n=e.handleError,r=e.handleNotification;return o.createElement("div",null,o.createElement("h2",null,l.publish.hubspotTitle),o.createElement(u.default,null),o.createElement("p",null,l.publish.hubspotDesc),o.createElement(u.default,null),o.createElement(s.default,{label:l.publish.embeddedCode,value:this.createUrl(),showCopy:t!==l.header.publishing,onNotification:function(e){return r(e)},onError:function(e){return n(e)},readOnly:!0}),t===l.header.publishing&&o.createElement(i.default,{size:"small",customStyles:{margin:0,height:"20px",border:"none"},color:"primary",onClick:function(){return n(l.publish.embeddedCodeCopyError)}},c.ICON_CLIPBOARD))},t}(o.PureComponent);t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(16),s=n(54),u=n(137),l=n(7),c=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return a(t,e),t.prototype.render=function(){return o.createElement("div",null,o.createElement("h2",null,l.integration.documentation),o.createElement(i.default,null),o.createElement("p",null,l.integration.docParagraph),o.createElement("div",{className:"link-wrapper"},null===u.documentationLinks||void 0===u.documentationLinks?void 0:u.documentationLinks.map((function(e){return o.createElement(s.BigLink,{key:e.key,label:e.label,link:e.link})}))))},t}(o.PureComponent);t.default=c},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.downloadSDKArchive=void 0;var a=n(28),o=n(511),i={method:"POST",responseType:"blob",headers:{"Content-Type":"application/json"}};t.downloadSDKArchive=function(e,t){var n=r(r({},i),{url:"https://template-generator.imposium.com/sdk-archive",data:JSON.stringify(t)});a.default(n).then((function(t){o.saveAs(t.data,e)})).catch((function(e){console.error("Failed to download sdk archive:",e)}))}},function(e,t,n){(function(n){var r,a,o;a=[],void 0===(o="function"==typeof(r=function(){"use strict";function t(e,t,n){var r=new XMLHttpRequest;r.open("GET",e),r.responseType="blob",r.onload=function(){s(r.response,t,n)},r.onerror=function(){console.error("could not download file")},r.send()}function r(e){var t=new XMLHttpRequest;t.open("HEAD",e,!1);try{t.send()}catch(e){}return 200<=t.status&&299>=t.status}function a(e){try{e.dispatchEvent(new MouseEvent("click"))}catch(n){var t=document.createEvent("MouseEvents");t.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),e.dispatchEvent(t)}}var o="object"==typeof window&&window.window===window?window:"object"==typeof self&&self.self===self?self:"object"==typeof n&&n.global===n?n:void 0,i=o.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),s=o.saveAs||("object"!=typeof window||window!==o?function(){}:"download"in HTMLAnchorElement.prototype&&!i?function(e,n,i){var s=o.URL||o.webkitURL,u=document.createElement("a");n=n||e.name||"download",u.download=n,u.rel="noopener","string"==typeof e?(u.href=e,u.origin===location.origin?a(u):r(u.href)?t(e,n,i):a(u,u.target="_blank")):(u.href=s.createObjectURL(e),setTimeout((function(){s.revokeObjectURL(u.href)}),4e4),setTimeout((function(){a(u)}),0))}:"msSaveOrOpenBlob"in navigator?function(e,n,o){if(n=n||e.name||"download","string"!=typeof e)navigator.msSaveOrOpenBlob(function(e,t){return void 0===t?t={autoBom:!1}:"object"!=typeof t&&(console.warn("Deprecated: Expected third argument to be a object"),t={autoBom:!t}),t.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(e.type)?new Blob(["\ufeff",e],{type:e.type}):e}(e,o),n);else if(r(e))t(e,n,o);else{var i=document.createElement("a");i.href=e,i.target="_blank",setTimeout((function(){a(i)}))}}:function(e,n,r,a){if((a=a||open("","_blank"))&&(a.document.title=a.document.body.innerText="downloading..."),"string"==typeof e)return t(e,n,r);var s="application/octet-stream"===e.type,u=/constructor/i.test(o.HTMLElement)||o.safari,l=/CriOS\/[\d]+/.test(navigator.userAgent);if((l||s&&u||i)&&"undefined"!=typeof FileReader){var c=new FileReader;c.onloadend=function(){var e=c.result;e=l?e:e.replace(/^data:[^;]*;/,"data:attachment/file;"),a?a.location.href=e:location=e,a=null},c.readAsDataURL(e)}else{var d=o.URL||o.webkitURL,p=d.createObjectURL(e);a?a.location=p:location.href=p,a=null,setTimeout((function(){d.revokeObjectURL(p)}),4e4)}});o.saveAs=s.saveAs=s,e.exports=s})?r.apply(t,a):r)||(e.exports=o)}).call(this,n(38))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getDemoURL=void 0;t.getDemoURL=function(){var e=window.location.href;return-1!==e.indexOf("localhost")?"http://localhost:3044":-1!==e.indexOf("staging")?"https://demo.staging.imposium.com":"https://demo.imposium.com"}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},i=this&&this.__values||function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(t,"__esModule",{value:!0});var s=n(0),u=n(16),l=n(21),c=n(7),d=n(54),p=n(514),f=n(4),h=n(1),m=n(10),_=n(8),y=n(22),g=n(88),v=function(e){function t(t){var n=e.call(this,t)||this;return n.selectCsv=function(){n.hiddenFileInputRef.current&&n.hiddenFileInputRef.current.click()},n.doUploadCsv=function(e){e.persist();var t=n.props.handleError;n.setState({uploading:!0,renderedBatch:!1}),n.props.createFreshBatch(n.getBatchName()).then((function(t){var r=t.id,a=t.name,o=t.story_id;n.setState({selectedBatchId:r}),n.importBatch({story_id:o,id:r,name:a,uploadEvt:e})})).catch((function(e){throw t(e),n.setState({uploadComplete:!1,uploading:!1}),e}))},n.getBatch=function(){var e=n.props.api;n.props.setPage(1),n.props.getBatch(e)},n.state={uploadComplete:!1,uploading:!1,downloading:!1,selectedBatchId:"",renderedBatch:!1,inventory:[],inventoryKeys:[],missingColumns:"",isMissing:!1},n.hiddenFileInputRef=s.createRef(),n}return a(t,e),t.prototype.componentDidMount=function(){this.getInventory()},t.prototype.getInventory=function(){var e=this.props.story.acts,t=Object.keys(e),n={};t.forEach((function(t){n=o(o({},n),e[t].inventory)}));var r=Object.keys(n).sort();this.setState({inventory:n}),this.setState({inventoryKeys:r})},t.prototype.downloadSampleCsv=function(){var e=this.props.story.name,n=this.state,r=n.inventory,a=n.inventoryKeys.map((function(e){return{id:e,name:r[e].name,show:!0}})).map((function(e){return e.id})).reduce((function(e,t){var n;return o(o({},e),((n={})[t]="",n))}),{}),i=b(e)+"-batch-template";new p.ExportToCsv(o(o({},t.CSV_EXPORT_CONFIG),{filename:i})).generateCsv([a])},t.prototype.getBatchName=function(){var e=this.props,t=e.story.name,n=e.compositionName,r=Date.now(),a=h(r).format("MMDDYY-HHmm");return b(t)+"-"+b(n)+"-"+a},t.prototype.proceedWithExport=function(){var e=this,t=this.props,n=t.renderBatch,r=t.activeBatch.data;n(r.id,r.name).then((function(){e.setState({renderedBatch:!0})})).catch((function(t){throw e.props.handleError(c.publish.renderBatchFailed),e.setState({renderedBatch:!1}),t}))},t.prototype.importBatch=function(e){var t=this,n=e.story_id,r=e.id,a=e.name,o=e.uploadEvt,i=this.props,s=i.accessKey,u=i.compositionId,l=i.isExport,c=i.onError;this.props.importBatchFromCsv(n,r,a,o.target.files[0],s,u,!l,l).then((function(){t.props.batchJobs.missing.length>0&&c(),t.setState({uploadComplete:!0,uploading:!1}),t.getBatch(),l&&0===Object.keys(t.props.batchJobs.missing).length&&t.renderBatch({id:r,name:a})})).catch((function(e){throw t.setState({uploadComplete:!1,uploading:!1}),e}))},t.prototype.renderBatch=function(e){var t=this,n=e.id,r=e.name;this.props.renderBatch(n,r).then((function(){t.setState({renderedBatch:!0})})).catch((function(e){throw t.props.handleError(c.publish.renderBatchFailed),t.setState({renderedBatch:!1}),e}))},t.prototype.downloadCsv=function(){var e=this;this.setState({downloading:!0},(function(){var t=e.props,n=t.status,r=(t.api,t.handleError),a=e.state.selectedBatchId;n!==c.header.publishing?e.props.getBatchExport(a).then((function(){e.props.onDone(),e.setState({downloading:!1})})):r(c.publish.downloadError)}))},t.prototype.renderLabel=function(){var e=this.props,n=e.isExport,r=e.batchJobs,a=this.state,o=a.renderedBatch,i=a.selectedBatchId,u=a.uploading,d=a.uploadComplete;if(n&&d&&!o&&0===Object.keys(this.props.batchJobs.missing).length)return s.createElement("div",{className:"progress-bar"},s.createElement("progress",{max:t.PROGRESS_MAX_VALUE,value:r.renders[i]}));if(u){var p=n?c.publish.importingData:c.publish.creatingLinks;return s.createElement("span",null,s.createElement(l.default,null)," ",p)}return s.createElement("span",null,f.ICON_UPLOAD," ",c.publish.uploadCsv)},t.prototype.onAssociationChange=function(e,t,n){var r=this.props.activeBatch.data.columns.findIndex((function(e){return e.detail===t}));-1!==r&&this.props.updateAssociation(this.props.api,r,"Static",null),this.props.updateAssociation(this.props.api,parseInt(e,10),"UGC",t),this.props.onNext(n)},t.prototype.renderColumnMap=function(){var e,t,n=this,r=this.props,a=r.activeBatch.data.columns,l=r.batchJobs.missing,d=r.variables;if(l.length>=0&&a){var p=Object.keys(d).map((function(e){return o({},d[e])})),f=Object.keys(a).map((function(e){return a[e]})),h=f.filter((function(e){return 0!==e.from_import})).map((function(e,t){var n={value:t,label:e.name};return-1!==p.findIndex((function(t){return e.detail===t.id}))&&(n.disabled=!0),n})),m=!1,_=function(e){if(!e.optional&&-1===f.findIndex((function(t){return t.detail===e.id})))return m=!0,"break"};try{for(var g=i(p),v=g.next();!v.done;v=g.next()){if("break"===_(v.value))break}}catch(t){e={error:t}}finally{try{v&&!v.done&&(t=g.return)&&t.call(g)}finally{if(e)throw e.error}}h.unshift("");var b=Object.keys(l).map((function(e){return l[e]})).join();return h.length<p.length?s.createElement(s.Fragment,null,s.createElement("h2",null,c.publish.titleMissingColumns),s.createElement(u.default,null),s.createElement("p",{className:"missingColumns"},c.publish.csvMissingColumns+" "+b)):s.createElement("div",{className:"align-columns"},s.createElement("h2",{className:"match-columns"},""+c.publish.csvMatchColumns),s.createElement(u.default,null),s.createElement("table",null,s.createElement("thead",null,s.createElement("tr",null,s.createElement("th",null,"Variable"),s.createElement("th",null,"CSV Column"))),s.createElement("tbody",null,p.map((function(e,t){var r=f.findIndex((function(t){return t.detail===e.id})),a=null!=r?r:"",o=e.optional?"":"required";return s.createElement("tr",{key:"var-"+e.id,className:""+o},s.createElement("td",{className:"variable"},s.createElement("p",null,e.name," ",e.optional?null:s.createElement("span",{style:{color:"red"}}," * "))),s.createElement("td",null,s.createElement(y.default,{options:h,value:a,onChange:function(t){return n.onAssociationChange(t,e.id,m)}})))})))))}},t.prototype.render=function(){var e=this,n=this.state,r=n.uploadComplete,a=n.uploading,o=n.downloading,i=n.renderedBatch,p=n.selectedBatchId,h=this.props,m=h.isExport,_=h.batchJobs,y=_.missing,g=_.renders,v=[{label:s.createElement("span",null,f.ICON_DOWNLOAD," ",c.publish.downloadSampleCsvLink),onClick:function(){return e.downloadSampleCsv()},key:"download-sample"},{label:this.renderLabel(),onClick:function(){return e.selectCsv()},key:"upload",disabled:m&&r||a}],b=o?s.createElement("span",null,s.createElement(l.default,null)," ",c.publish.exporting):s.createElement("span",null,f.ICON_DOWNLOAD," ",c.publish.btnDownload),w=s.createElement("div",{className:"progress-bar"},s.createElement("progress",{max:t.PROGRESS_MAX_VALUE,value:g[p]})),M=s.createElement("div",null,s.createElement("h2",null,r?c.publish.downloadLink:c.publish.generatingLink),s.createElement(u.default,null),s.createElement("p",null,r?c.publish.downloadDesc:c.publish.generatingLinkDesc),m&&r&&!i?s.createElement(d.BigButton,{label:w,disabled:m}):s.createElement(d.BigButton,{label:b,disabled:o,onClick:function(){return e.downloadCsv()}})),L=s.createElement(s.Fragment,null,this.props.error?this.props.next?M:"":M,this.renderColumnMap()),T=s.createElement("div",null,s.createElement("h2",null,c.publish.emailTitle),s.createElement(u.default,null),s.createElement("p",null,c.publish.emailDesc),s.createElement("input",{type:"file",style:{display:"none"},accept:"text/csv",ref:this.hiddenFileInputRef,onChange:this.doUploadCsv}),s.createElement("div",{className:"link-wrapper"},null==v?void 0:v.map((function(e,t){return s.createElement(d.BigButton,{label:s.createElement("span",null,e.label),onClick:e.onClick,disabled:null==e?void 0:e.disabled,key:e.key})}))));return(m&&0===Object.keys(y).length?i:r)?L:T},t.PROGRESS_MAX_VALUE=100,t.CSV_EXPORT_CONFIG={fieldSeparator:",",quoteStrings:'"',decimalSeparator:".",showLabels:!1,showTitle:!1,useTextFile:!1,useBom:!1,useKeysAsHeaders:!0},t}(s.PureComponent),b=function(e){return e.replace(/\W/g,"")};t.default=_.connect((function(e){return{activeBatch:e.activeBatch,batchesList:e.batchesList}}),(function(e){return m.bindActionCreators({updateAssociation:g.updateAssociation,getBatch:g.getBatch,setPage:g.setPage},e)}),null,{withRef:!0})(v)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}(n(515))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(){}return e.EOL="\r\n",e.BOM="\ufeff",e.DEFAULT_FIELD_SEPARATOR=",",e.DEFAULT_DECIMAL_SEPARATOR=".",e.DEFAULT_QUOTE='"',e.DEFAULT_SHOW_TITLE=!1,e.DEFAULT_TITLE="My Generated Report",e.DEFAULT_FILENAME="generated",e.DEFAULT_SHOW_LABELS=!1,e.DEFAULT_USE_TEXT_FILE=!1,e.DEFAULT_USE_BOM=!0,e.DEFAULT_HEADER=[],e.DEFAULT_KEYS_AS_HEADERS=!1,e}();t.CsvConfigConsts=r,t.ConfigDefaults={filename:r.DEFAULT_FILENAME,fieldSeparator:r.DEFAULT_FIELD_SEPARATOR,quoteStrings:r.DEFAULT_QUOTE,decimalSeparator:r.DEFAULT_DECIMAL_SEPARATOR,showLabels:r.DEFAULT_SHOW_LABELS,showTitle:r.DEFAULT_SHOW_TITLE,title:r.DEFAULT_TITLE,useTextFile:r.DEFAULT_USE_TEXT_FILE,useBom:r.DEFAULT_USE_BOM,headers:r.DEFAULT_HEADER,useKeysAsHeaders:r.DEFAULT_KEYS_AS_HEADERS};var a=function(){function e(e){this._csv="";var n=e||{};this._options=u({},t.ConfigDefaults,n),this._options.useKeysAsHeaders&&this._options.headers&&this._options.headers.length>0&&console.warn("Option to use object keys as headers was set, but headers were still passed!")}return Object.defineProperty(e.prototype,"options",{get:function(){return this._options},set:function(e){this._options=u({},t.ConfigDefaults,e)},enumerable:!0,configurable:!0}),e.prototype.generateCsv=function(e,t){if(void 0===t&&(t=!1),this._csv="",this._parseData(e),this._options.useBom&&(this._csv+=r.BOM),this._options.showTitle&&(this._csv+=this._options.title+"\r\n\n"),this._getHeaders(),this._getBody(),""!=this._csv){if(t)return this._csv;var n=this._options.useTextFile?"plain":"csv",a=this._options.useTextFile?".txt":".csv",o=new Blob([this._csv],{type:"text/"+n+";charset=utf8;"});if(navigator.msSaveBlob){var i=this._options.filename.replace(/ /g,"_")+a;navigator.msSaveBlob(o,i)}else{this._options.useTextFile,encodeURI(this._csv);var s=document.createElement("a");s.href=URL.createObjectURL(o),s.setAttribute("visibility","hidden"),s.download=this._options.filename.replace(/ /g,"_")+a,document.body.appendChild(s),s.click(),document.body.removeChild(s)}}else console.log("Invalid data")},e.prototype._getHeaders=function(){if(this._options.showLabels||this._options.useKeysAsHeaders){var e=this._options.useKeysAsHeaders?Object.keys(this._data[0]):this._options.headers;if(e.length>0){for(var t="",n=0;n<e.length;n++)t+=e[n]+this._options.fieldSeparator;t=t.slice(0,-1),this._csv+=t+r.EOL}}},e.prototype._getBody=function(){for(var e=Object.keys(this._data[0]),t=0;t<this._data.length;t++){for(var n="",a=0;a<e.length;a++){var o=e[a];n+=this._formatData(this._data[t][o])+this._options.fieldSeparator}n=n.slice(0,-1),this._csv+=n+r.EOL}},e.prototype._formatData=function(e){return"locale"===this._options.decimalSeparator&&this._isFloat(e)?e.toLocaleString():"."!==this._options.decimalSeparator&&this._isFloat(e)?e.toString().replace(".",this._options.decimalSeparator):"string"==typeof e?(e=e.replace(/"/g,'""'),(this._options.quoteStrings||e.indexOf(",")>-1||e.indexOf("\n")>-1||e.indexOf("\r")>-1)&&(e=this._options.quoteStrings+e+this._options.quoteStrings),e):"boolean"==typeof e?e?"TRUE":"FALSE":e},e.prototype._isFloat=function(e){return+e===e&&(!isFinite(e)||Boolean(e%1))},e.prototype._parseData=function(e){return this._data="object"!=typeof e?JSON.parse(e):e,this._data},e}();t.ExportToCsv=a;var o=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;function s(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function u(e){for(var t,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];for(var a,u=s(e),l=1;l<arguments.length;l++){for(var c in t=Object(arguments[l]))o.call(t,c)&&(u[c]=t[c]);if(Object.getOwnPropertySymbols){a=Object.getOwnPropertySymbols(t);for(var d=0;d<a.length;d++)i.call(t,a[d])&&(u[a[d]]=t[a[d]])}}return u}},function(e,t,n){var r={"./af":138,"./af.js":138,"./ar":139,"./ar-dz":140,"./ar-dz.js":140,"./ar-kw":141,"./ar-kw.js":141,"./ar-ly":142,"./ar-ly.js":142,"./ar-ma":143,"./ar-ma.js":143,"./ar-sa":144,"./ar-sa.js":144,"./ar-tn":145,"./ar-tn.js":145,"./ar.js":139,"./az":146,"./az.js":146,"./be":147,"./be.js":147,"./bg":148,"./bg.js":148,"./bm":149,"./bm.js":149,"./bn":150,"./bn-bd":151,"./bn-bd.js":151,"./bn.js":150,"./bo":152,"./bo.js":152,"./br":153,"./br.js":153,"./bs":154,"./bs.js":154,"./ca":155,"./ca.js":155,"./cs":156,"./cs.js":156,"./cv":157,"./cv.js":157,"./cy":158,"./cy.js":158,"./da":159,"./da.js":159,"./de":160,"./de-at":161,"./de-at.js":161,"./de-ch":162,"./de-ch.js":162,"./de.js":160,"./dv":163,"./dv.js":163,"./el":164,"./el.js":164,"./en-au":165,"./en-au.js":165,"./en-ca":166,"./en-ca.js":166,"./en-gb":167,"./en-gb.js":167,"./en-ie":168,"./en-ie.js":168,"./en-il":169,"./en-il.js":169,"./en-in":170,"./en-in.js":170,"./en-nz":171,"./en-nz.js":171,"./en-sg":172,"./en-sg.js":172,"./eo":173,"./eo.js":173,"./es":174,"./es-do":175,"./es-do.js":175,"./es-mx":176,"./es-mx.js":176,"./es-us":177,"./es-us.js":177,"./es.js":174,"./et":178,"./et.js":178,"./eu":179,"./eu.js":179,"./fa":180,"./fa.js":180,"./fi":181,"./fi.js":181,"./fil":182,"./fil.js":182,"./fo":183,"./fo.js":183,"./fr":184,"./fr-ca":185,"./fr-ca.js":185,"./fr-ch":186,"./fr-ch.js":186,"./fr.js":184,"./fy":187,"./fy.js":187,"./ga":188,"./ga.js":188,"./gd":189,"./gd.js":189,"./gl":190,"./gl.js":190,"./gom-deva":191,"./gom-deva.js":191,"./gom-latn":192,"./gom-latn.js":192,"./gu":193,"./gu.js":193,"./he":194,"./he.js":194,"./hi":195,"./hi.js":195,"./hr":196,"./hr.js":196,"./hu":197,"./hu.js":197,"./hy-am":198,"./hy-am.js":198,"./id":199,"./id.js":199,"./is":200,"./is.js":200,"./it":201,"./it-ch":202,"./it-ch.js":202,"./it.js":201,"./ja":203,"./ja.js":203,"./jv":204,"./jv.js":204,"./ka":205,"./ka.js":205,"./kk":206,"./kk.js":206,"./km":207,"./km.js":207,"./kn":208,"./kn.js":208,"./ko":209,"./ko.js":209,"./ku":210,"./ku.js":210,"./ky":211,"./ky.js":211,"./lb":212,"./lb.js":212,"./lo":213,"./lo.js":213,"./lt":214,"./lt.js":214,"./lv":215,"./lv.js":215,"./me":216,"./me.js":216,"./mi":217,"./mi.js":217,"./mk":218,"./mk.js":218,"./ml":219,"./ml.js":219,"./mn":220,"./mn.js":220,"./mr":221,"./mr.js":221,"./ms":222,"./ms-my":223,"./ms-my.js":223,"./ms.js":222,"./mt":224,"./mt.js":224,"./my":225,"./my.js":225,"./nb":226,"./nb.js":226,"./ne":227,"./ne.js":227,"./nl":228,"./nl-be":229,"./nl-be.js":229,"./nl.js":228,"./nn":230,"./nn.js":230,"./oc-lnc":231,"./oc-lnc.js":231,"./pa-in":232,"./pa-in.js":232,"./pl":233,"./pl.js":233,"./pt":234,"./pt-br":235,"./pt-br.js":235,"./pt.js":234,"./ro":236,"./ro.js":236,"./ru":237,"./ru.js":237,"./sd":238,"./sd.js":238,"./se":239,"./se.js":239,"./si":240,"./si.js":240,"./sk":241,"./sk.js":241,"./sl":242,"./sl.js":242,"./sq":243,"./sq.js":243,"./sr":244,"./sr-cyrl":245,"./sr-cyrl.js":245,"./sr.js":244,"./ss":246,"./ss.js":246,"./sv":247,"./sv.js":247,"./sw":248,"./sw.js":248,"./ta":249,"./ta.js":249,"./te":250,"./te.js":250,"./tet":251,"./tet.js":251,"./tg":252,"./tg.js":252,"./th":253,"./th.js":253,"./tk":254,"./tk.js":254,"./tl-ph":255,"./tl-ph.js":255,"./tlh":256,"./tlh.js":256,"./tr":257,"./tr.js":257,"./tzl":258,"./tzl.js":258,"./tzm":259,"./tzm-latn":260,"./tzm-latn.js":260,"./tzm.js":259,"./ug-cn":261,"./ug-cn.js":261,"./uk":262,"./uk.js":262,"./ur":263,"./ur.js":263,"./uz":264,"./uz-latn":265,"./uz-latn.js":265,"./uz.js":264,"./vi":266,"./vi.js":266,"./x-pseudo":267,"./x-pseudo.js":267,"./yo":268,"./yo.js":268,"./zh-cn":269,"./zh-cn.js":269,"./zh-hk":270,"./zh-hk.js":270,"./zh-mo":271,"./zh-mo.js":271,"./zh-tw":272,"./zh-tw.js":272};function a(e){var t=o(e);return n(t)}function o(e){if(!n.o(r,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return r[e]}a.keys=function(){return Object.keys(r)},a.resolve=o,e.exports=a,a.id=516},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(39),o=n(29),i=null;try{var s=JSON.parse(localStorage.getItem(a.AUTH_CACHE_KEY));if(s){var u=s.idTokenPayload.exp;o.default.checkExpiry(u)&&(i=s)}}catch(e){console.warn("Cached credentials were malformed or missing, redirected to login.")}t.default=function(e,t){switch(void 0===e&&(e=i),t.type){case a.default.LOGIN:return r({},t.auth);case a.default.CLEAR:return null;default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(40),o=null;try{o=JSON.parse(localStorage.getItem(a.ACCESS_CACHE_KEY))}catch(e){console.warn("Cached access data was malformed or missing, redirected to login.")}t.default=function(e,t){switch(void 0===e&&(e=o),t.type){case a.default.SET:case a.default.STORY_ADDED:case a.default.STORY_NAME_MUTATION:case a.default.ORG_NAME_MUTATION:case a.default.STORY_DELETED:return r({},t.accessData);case a.default.CLEAR:return null;default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(55),o={publishing:!1};t.default=function(e,t){switch(void 0===e&&(e=o),t.type){case a.default.UPDATE_PUBLISH_STATUS:return r(r({},e),t.data);case a.default.CLEAR_PUBLISH_STATUS:return o;default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(24),o={page:1,order:"date_created",order_direction:"desc",name:"",type:"",tags:""};t.default=function(e,t){switch(void 0===e&&(e=o),t.type){case a.default.UPDATE:return r(r({},e),t.newFilters);case a.default.RESET:return r({},o);default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},o=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var i=n(17),s={loading:!1};t.default=function(e,t){void 0===e&&(e=s);var n,u=[];switch(t.type){case i.default.TOGGLE_LOADING:return r(r({},e),{loading:t.toggle});case i.default.GET:return r(r({},e),t.assetList);case i.default.ADD_TAG:for(var l=0,c=e.assets.length;l<c;l++)(n=e.assets[l]).id===t.id?u[l]=r(r({},n),{tags:o(o([],a(n.tags)),a(t.freshTags))}):u[l]=n;return r(r({},e),{assets:u});case i.default.DELETE_TAG:return r(r({},e),{assets:e.assets.map((function(e){return e.id===t.id?r(r({},e),{tags:e.tags.filter((function(e){return e!==t.tag}))}):e}))});case i.default.UPDATE_NAME:return r(r({},e),{assets:e.assets.map((function(e){return e.id===t.id?r(r({},e),{name:t.name}):e}))});case i.default.UPDATE_DATA:return r(r({},e),{assets:e.assets.map((function(e){return e.id===t.id?r(r({},e),{data:t.data}):e}))});default:return e}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(83),a=[];t.default=function(e,t){switch(void 0===e&&(e=a),t.type){case r.default.GET:return t.assetTags;default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},o=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var i=n(52),s={autoTag:!0,assignToStory:!0,uploads:[]};t.default=function(e,t){switch(void 0===e&&(e=s),t.type){case i.default.TOGGLE_AUTO_TAG:return r(r({},e),{autoTag:t.toggle});case i.default.TOGGLE_ASSIGN_TO_STORY:return r(r({},e),{assignToStory:t.toggle});case i.default.ADD_UPLOAD:return r(r({},e),{uploads:o(o([],a(e.uploads)),[t.uploadMeta])});case i.default.UPDATE_PERCENT_UPLOADED:var n=e.uploads.map((function(e){return e.filename===t.filename?r(r({},e),{percent:t.percent}):e}));return r(r({},e),{uploads:n});case i.default.REMOVE_UPLOAD:return r(r({},e),{uploads:e.uploads.filter((function(e){return e.filename!==t.filename}))});default:return e}}},function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var o=n(33),i=[];t.default=function(e,t){switch(void 0===e&&(e=i),t.type){case o.default.SELECT_ALL:return a([],r(t.allIds));case o.default.SELECT_ASSET:return a(a([],r(e)),[t.id]);case o.default.SELECT_MULTIPLE:return a([],r(new Set(a(a([],r(e)),r(t.assets)))));case o.default.DESELECT_ASSET:return e.filter((function(e){return e!==t.id}));case o.default.RESET_SELECTION:return[];default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},o=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var i=n(88),s={loading:!0,updating:!1,associationOptions:{},page:1,data:{}},u={name:"New Column",type:"Static",from_import:1,detail:null};t.default=function(e,t){var n,l;switch(void 0===e&&(e=s),t.type){case i.default.TOGGlE_LOADING:return r(r({},e),{loading:t.toggle});case i.default.TOGGLE_UPDATING:return r(r({},e),{updating:t.toggle});case i.default.ADD_COLUMN:return void 0!==t.columnData?r(r({},e),{data:r(r({},e.data),{columns:o(o([],a(e.data.columns)),[t.columnData])})}):(l=(n=function(e){return e.data.columns.filter((function(e){return e.name.includes(u.name)})).length}(e))?r(r({},u),{name:u.name+" ("+n+")"}):r({},u),r(r({},e),{data:r(r({},e.data),{columns:o(o([],a(e.data.columns)),[l])})}));case i.default.REPLACE_ASSOCIATION_OPTIONS:return r(r({},e),{associationOptions:r({},t.associationOptions)});case i.default.UPDATE_ASSOCIATION:return r(r({},e),{data:r(r({},e.data),{columns:e.data.columns.map((function(e,n){return t.colIndex===n?"Static"===t.newType?r(r({},e),{type:t.newType,detail:null}):r(r({},e),{type:t.newType,detail:t.newAssociation,from_import:"EGC"===t.newType?0:1}):e}))})});case i.default.SET_BATCH:return r(r({},e),{data:r({},t.batch)});case i.default.SET_PAGE:return r(r({},e),{page:t.page});default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(28),o=n(9),i=n(527),s=n(7),u=n(29),l=n(27),c=function(){function e(e,t,n){var c=this;this.pollingInterval=1e3,this.cancelTokenCache={player:void 0,system:void 0},this.cancelTokens={},this.doRequest=function(e,t){return void 0===t&&(t=""),new Promise((function(n,r){c.http(e).then((function(e){t&&c.clearCache(t),n(e.data)})).catch((function(e){!a.default.isCancel(e)&&t&&c.clearCache(t),!e.response||403!==e.response.status&&401!==e.response.status||(alert(s.assets.sessionExpired),l.default.getSession()&&(l.default.removeSession(),u.default.logout())),r(e)}))}))},this.cancelPrevious=function(e){var t=a.default.CancelToken.source();return c.cancelTokenCache[e]&&c.cancelTokenCache[e].cancel(),c.cancelTokenCache[e]=t,t.token},this.clearCache=function(e){c.cancelTokenCache[e]=void 0},this.doAWSRequest=function(e,t){return void 0===t&&(t=""),new Promise((function(t,n){c.awsHttp(e).then((function(e){t(e.data)})).catch((function(e){n(e)}))}))},this.saveStory=function(e,t){return c.doRequest({method:"PATCH",url:"/story/"+e,data:t})},this.newStory=function(e){return c.doRequest({method:"POST",url:"/story",data:e})},this.deleteStory=function(e){return c.doRequest({method:"DELETE",url:"/story/"+e})},this.getStoryStatus=function(e){return c.doRequest({method:"GET",url:"/story/"+e+"/version"})},this.getStoryVersions=function(e){return c.doRequest({method:"GET",url:"/story/"+e+"/versions"})},this.revertVersion=function(e,t){var n={version_id:t};return c.doRequest({method:"POST",url:"/story/"+e+"/version/revert",data:n})},this.getSignedUrl=function(e,t){return c.doRequest({method:"GET",url:"/story/"+e+"/upload-url",params:{filename:t.name,content_type:t.type}})},this.uploadToSignedUrl=function(e,t,n){return c.doAWSRequest({url:e,method:"PUT",data:t,onUploadProgress:n,headers:{"Content-Type":t.type}})},this.checkS3Bucket=function(e){var t="/bucket/"+e;return c.doRequest({method:"GET",url:t})},this.createS3Bucket=function(e,t,n,r){var a="/bucket/"+e,o={region:t,create_distribution:r?1:0,read_only:n?1:0};return c.doRequest({method:"POST",url:a,data:o})},this.processStoryFile=function(e,t,n){var r="/story/"+e+"/file",a={};return t?a.file_key=t:n&&(a.url=n),c.doRequest({method:"POST",url:r,data:a})},this.getAssets=function(e,t,n){void 0===n&&(n=!1);var r="/assets?items_per_page=50&optional_story_id="+t+"&unprocessed="+n,a=function(t){e.hasOwnProperty(t)&&(e[t]&&"tags"!==t&&(r+="&"+t+"="+encodeURIComponent(e[t])),e[t]&&"tags"===t&&e[t].split(",").forEach((function(e,n){r+="&"+t+"["+n+"]="+encodeURIComponent(e)})))};for(var o in e)a(o);return c.doRequest({method:"GET",url:r})},this.getAssetItem=function(e){return c.doRequest({method:"GET",url:"/assets/"+e})},this.duplicateAsset=function(e,t){return c.doRequest({method:"POST",url:"/assets/"+e+"/copy",data:{name:t}})},this.cancelRequest=function(e){var t=a.default.CancelToken.source();return c.cancelTokens[e]=t,t.token},this.clearCancelTokes=function(){c.cancelTokens={}},this.uploadAsset=function(e,t,n,r,a){var o=new FormData,i=c.cancelRequest(a);return e&&o.append("story_id",e),o.append("tags",t),o.append("file",n),c.doRequest({method:"POST",url:"/assets",data:o,onUploadProgress:r,cancelToken:i})},this.cancelUploadAssets=function(e){var t=c.cancelTokens[e];t&&t.cancel()},this.createCompositionAsset=function(e,t,n){var r=new FormData;return r.append("story_id",e),r.append("data",t),r.append("type","video_composition"),r.append("name",n||"New Composition"),c.doRequest({method:"POST",url:"/assets",data:r})},this.createStaticCompositionAsset=function(e,t){var n=new FormData;return n.append("story_id",e),n.append("data",t),n.append("type","static_composition"),n.append("name","New Template"),c.doRequest({method:"POST",url:"/assets",data:n})},this.deleteAsset=function(e){return c.doRequest({method:"DELETE",url:"/assets/"+e})},this.deleteAssets=function(e){return c.doRequest({method:"DELETE",url:"/assets",data:{ids:e}})},this.copyAsset=function(e,t){return c.doRequest({method:"POST",url:"/assets/"+e+"/copy",data:t})},this.addAssetTag=function(e,t){return c.doRequest({method:"POST",url:"/assets/"+e+"/tag",data:{tag:t}})},this.deleteAssetTag=function(e,t){return c.doRequest({method:"DELETE",url:"/assets/"+e+"/tag",data:{tag:t}})},this.updateAsset=function(e,t){return c.doRequest({method:"PATCH",url:"/assets/"+e,data:t})},this.getAssetTags=function(e){return c.doRequest({method:"GET",url:"/assets/tags?story_id="+e})},this.getStory=function(e){return c.doRequest({method:"GET",url:"/story/"+e})},this.getExperiences=function(e,t){return c.doRequest({method:"GET",url:"/story/"+e+"/experiences",params:t})},this.exportExperiences=function(e,t){return c.doRequest({method:"GET",url:"/story/"+e+"/experiences/export",params:t})},this.blockByExperience=function(e){var t="/experience/"+e+"/block";return c.doRequest({method:"POST",url:t})},this.getBatches=function(e,t){return c.doRequest({method:"GET",url:"/story/"+e+"/batches",params:t})},this.getBatch=function(e,t){return c.doRequest({method:"GET",url:"/batch/"+e,params:{page:t}})},this.getBatchProgress=function(e){return c.doRequest({method:"GET",url:"/batch/"+e+"/progress"})},this.createFreshBatch=function(e,t){return c.doRequest({method:"POST",url:"/batch",data:{story_id:e,name:t}})},this.updateBatchName=function(e,t){return c.doRequest({method:"PATCH",url:"/batch/"+e+"/rename",data:{name:t}})},this.importBatchDataFromCsv=function(e,t,n,r,a,o){void 0===n&&(n=!1),void 0===r&&(r=null),void 0===a&&(a=null),void 0===o&&(o=!1);var i=new FormData;return i.append("file_key",t),n&&r&&a&&(i.append("include_email_embed","true"),i.append("composition_id",a),i.append("access_key",r)),o&&i.append("include_media","true"),c.doRequest({method:"POST",url:"/batch/"+e+"/data/from-csv",data:i})},this.updateBatchColumns=function(e,t){return c.doRequest({method:"PUT",url:"/batch/"+e+"/columns",data:t})},this.insertNewRow=function(e,t){return c.doRequest({method:"POST",url:"/batch/"+e+"/row/"+t})},this.updateCellValue=function(e,t,n,r){return c.doRequest({method:"PUT",url:"/batch/"+e+"/cell",data:{column_index:t,row_index:n,value:r}})},this.prepareBatchForRender=function(e){return c.doRequest({method:"POST",url:"/batch/"+e+"/prepare"})},this.checkBatchExportStatus=function(e){return c.doRequest({method:"GET",url:"/batch/"+e+"/export"})},this.invokeBatchExportJob=function(e){return c.doRequest({method:"POST",url:"/batch/"+e+"/export"})},this.downloadBatchExport=function(e,t){return c.doRequest({method:"GET",url:"/batch/"+e+"/export/"+t,responseType:"blob",params:{preserve:"true"}})},this.duplicateBatch=function(e){return c.doRequest({method:"POST",url:"/batch/"+e+"/duplicate"})},this.deleteBatch=function(e){return c.doRequest({method:"DELETE",url:"/batch/"+e})},this.updateModerationStatus=function(e,t,n){return c.doRequest({method:"POST",url:"/experience/"+e+"/status",data:{status:t,reason:n}})},this.addOrReplaceNote=function(e,t){return c.doRequest({method:"POST",url:"/experience/"+e+"/notes",data:{notes:t}})},this.getJob=function(e){return c.doRequest({method:"GET",url:"/job/"+e})},this.runCut=function(e,t,n,r){var a="/job/"+i.JOB_TYPES.RUN_CUT,o={story_id:e,act_id:t,scene_id:n,cut_id:r};return c.doRequest({method:"POST",url:a,data:o})},this.runReRenderCuts=function(e,t,n){var r="/job/"+i.JOB_TYPES.RE_RUN_CUTS,a={story_id:e,act_id:t,scene_id:n};return c.doRequest({method:"POST",url:r,data:a})},this.runProcessBaseVideo=function(e,t){var n="/job/"+i.JOB_TYPES.PROCESS_BASE_VIDEO,r={story_id:e,file_key:t};return c.doRequest({method:"POST",url:n,data:r})},this.runPublish=function(e,t){var n={story_id:e,message:t};return c.doRequest({method:"POST",url:"/job/publish",data:n})},this.cancelPublish=function(e){var t={story_id:e};return c.doRequest({method:"DELETE",url:"/job/publish",data:t})},this.pollJob=function(e){var t={method:"GET",url:"/job/"+e};return new Promise((function(e,n){c.pollForJob(t,e,n)}))},this.pollForJob=function(e,t,n){c.http(e).then((function(r){"failed"===r.data.status?n(r):void 0!==r.data.output?t(r.data):c.jobPollTimer=setTimeout((function(){c.pollForJob(e,t,n)}),c.pollingInterval)})).catch((function(e){n(e)}))},this.pollForExperience=function(e,t,n){c.http(e).then((function(r){"failed"===r.data.status?n(r):!1===r.data.rendering&&void 0!==r.data.error?n(r.data):void 0!==r.data.output?o.isObjEmpty(r.data.output)?c.experiencePollTimer=setTimeout((function(){c.pollForExperience(e,t,n)}),c.pollingInterval):t(r.data):c.experiencePollTimer=setTimeout((function(){c.pollForExperience(e,t,n)}),c.pollingInterval)})).catch((function(e){n(e)}))},this.getJobLogUrl=function(e){var t="/job/"+e+"/log-url";return c.doRequest({method:"GET",url:t})},this.getJobLog=function(e){return c.doAWSRequest({method:"GET",url:e})},this.createExperience=function(e,t,n,r){void 0===t&&(t={});var a=c.experienceFormData(e,t,n);r&&a.append("published","false");return c.doRequest({method:"POST",url:"/experience",data:a})},this.deleteExperience=function(e,t){void 0===t&&(t=!0);var n="/experience/"+e,r={erase_media:t};return c.doRequest({method:"DELETE",data:r,url:n})},this.triggerEvent=function(e,t,n){var r="/experience/"+e+"/trigger-event";if(t){var a=new FormData;return a.append("composition_id",t),n&&a.append("published","false"),c.doRequest({method:"POST",url:r,data:a})}return c.doRequest({method:"POST",url:r})},this.getExperience=function(e,t){void 0===t&&(t=!1);var n={method:"GET",url:"/experience/"+e};return t?new Promise((function(e,t){c.pollForExperience(n,e,t)})):c.doRequest(n)},this.experienceFormData=function(e,t,n){var a=r({},t),o=new FormData;for(var i in o.append("story_id",e),n&&o.append("composition_id",n),a)if(a[i]){var s=a[i];if(s&&"file"===s.type){var u=s.files;u.length>0?(a[i]="",o.append(i,u[0])):a[i]=""}else s&&s instanceof File&&(a[i]="",o.append(i,s,s.name));o.append("inventory["+i+"]",a[i])}return o},this.getAccssCredentials=function(){return c.doRequest({method:"GET",url:"/api-key"})},this.createAccessCredentials=function(e){var t={name:e};return c.doRequest({method:"POST",data:t,url:"/api-key"})},this.deleteAccessCrednetials=function(e){var t={access_key_id:e};return c.doRequest({method:"DELETE",data:t,url:"/api-key"})},this.invokeBatchRenderJob=function(e){return c.doRequest({method:"POST",url:"/job/render-batch",data:{batch_id:e}})},this.cancelBatchRenderJob=function(e){return c.doRequest({method:"POST",url:"/batch/"+e+"/cancel"})},this.getUsers=function(e,t,n){return c.doRequest({url:"/account/"+e+"/users?page="+t+"&items_per_page="+n,method:"GET"})},this.addUser=function(e,t,n){return c.doRequest({url:"/account/"+e+"/grant",method:"POST",data:{email:t,role_id:n}})},this.resendInvite=function(e,t){return c.doRequest({url:"/account/"+e+"/resend",method:"POST",data:{email:t}})},this.revokeInvite=function(e,t){return c.doRequest({url:"/account/"+e+"/revoke",method:"POST",data:{email:t}})},this.updateInviteRole=function(e,t,n){return c.doRequest({url:"/account/"+e+"/grant",method:"PATCH",data:{email:t,role_id:n}})},this.updateRole=function(e,t,n){return c.doRequest({url:"/account/"+e+"/user",method:"PATCH",data:{user_id:t,role_id:n}})},this.deleteUser=function(e,t){return c.doRequest({url:"/account/"+e+"/user",method:"DELETE",data:{user_id:t}})},this.getPlayerMetrics=function(e,t,n,r){void 0===r&&(r="player");var a={method:"GET",url:"/metrics/player/"+e,params:{start:t,end:n},cancelToken:c.cancelPrevious(r)};return c.doRequest(a,r)},this.getSystemMetrics=function(e,t,n,r,a){void 0===a&&(a="system");var o={method:"GET",url:"/metrics/system/"+e,params:{start:t,end:n,step:r},cancelToken:c.cancelPrevious(a)};return c.doRequest(o,a)},this.getOrganizations=function(e,t){return c.doRequest({url:"/account",method:"GET",params:{page:e,items_per_page:t}})},this.addOrganization=function(e,t){return c.doRequest({url:"/account",method:"POST",data:{name:e,initial_story:t}})},this.updateOrgName=function(e,t){return c.doRequest({url:"/account/"+e,method:"PATCH",data:{name:t}})},this.deleteOrg=function(e){},this.changeOrgPlan=function(e,t){return c.doRequest({url:"/account/"+e,method:"PATCH",data:{tier:t}})},this.getAccountInfo=function(e){return c.doRequest({url:"/account/"+e,method:"GET"})},this.cancelOrgPlan=function(e){return c.doRequest({url:"/account/"+e,method:"PATCH",data:{cancel:!0}})},this.getNextBillingPeriod=function(e){return c.doRequest({url:"/account/"+e+"/next-payment",method:"GET"})},this.getRedirectToBillingPortal=function(e){return c.doRequest({url:"/account/"+e+"/billing-portal",method:"GET"})},this.getRedirectToRenew=function(e,t){return c.doRequest({url:"/account/"+e+"/renew?tier="+t,method:"GET"})},this.getAPIUsageOverview=function(e,t){var n=e&&t?"?start="+e+"&end="+t:"";return c.doRequest({url:"/usage"+n,method:"GET"})},this.getUsageGraph=function(e,t,n){var r=t&&n?"?start="+t+"&end="+n:"";return c.doRequest({url:"/usage/daily/"+e+r,method:"GET"})},this.getBillingPeriods=function(){return c.doRequest({url:"/usage/billing-periods",method:"GET"})},this.http=n?a.default.create({baseURL:e,headers:{Authorization:"Bearer "+t,"X-Imposium-API-Version":"2.0.0","X-Imposium-Account-Id":n||""}}):a.default.create({baseURL:e,headers:{"X-Imposium-Access-Key":""+t,"X-Imposium-API-Version":"2.0.0"}}),this.awsHttp=a.default.create()}return e.prototype.cancelExperiencePolling=function(){var e=this;return new Promise((function(t){clearTimeout(e.experiencePollTimer),t()}))},e.prototype.cancelJobPolling=function(){var e=this;return new Promise((function(t){clearTimeout(e.jobPollTimer),t()}))},e}();t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.JOB_TYPES=void 0,t.JOB_TYPES={RUN_CUT:"make-cut",PROCESS_BASE_VIDEO:"process-base-video",RE_RUN_CUTS:"recut-scene"}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(28),a=function(e){var t=this;this.doRequest=function(e){return new Promise((function(n,r){t.http(e).then((function(e){n(e.data)})).catch((function(e){r(e)}))}))},this.updateModerationStatus=function(e,n,r){return t.doRequest({method:"POST",url:"/",data:{task:"update-experience-status",experience_id:e,status:n,reason:r}})},this.addOrReplaceNote=function(e,n){return t.doRequest({method:"POST",url:"/",data:{task:"update-experience-notes",experience_id:e,notes:n}})},this.http=r.default.create({baseURL:e+"/1.1"})};t.default=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(530),a=function(){function e(){}return e.setItem=function(e,t){return new Promise((function(n,a){r.setItem(e,t).then((function(){return n(null)})).catch((function(e){console.error("Failed to store key value pair:",e),a(e)}))}))},e.getItem=function(e){return new Promise((function(t,n){r.getItem(e).then((function(e){t(e)})).catch((function(e){console.error("Failed to look up value for key:",e),n(e)}))}))},e}();t.default=a},function(e,t){e.exports=h},function(e,t,n){"use strict";n.r(t),n.d(t,"AlphaPicker",(function(){return Gn})),n.d(t,"BlockPicker",(function(){return la})),n.d(t,"CirclePicker",(function(){return Ya})),n.d(t,"default",(function(){return za})),n.d(t,"ChromePicker",(function(){return za})),n.d(t,"CompactPicker",(function(){return Va})),n.d(t,"GithubPicker",(function(){return Ja})),n.d(t,"HuePicker",(function(){return Za})),n.d(t,"MaterialPicker",(function(){return Qa})),n.d(t,"PhotoshopPicker",(function(){return so})),n.d(t,"SketchPicker",(function(){return mo})),n.d(t,"SliderPicker",(function(){return bo})),n.d(t,"SwatchesPicker",(function(){return xo})),n.d(t,"TwitterPicker",(function(){return So})),n.d(t,"GooglePicker",(function(){return Po})),n.d(t,"CustomPicker",(function(){return Pn}));var r=n(0),a=n.n(r),o=n(3),i=n.n(o),s=function(e,t,n,r,a){var o=a.clientWidth,i=a.clientHeight,s="number"==typeof e.pageX?e.pageX:e.touches[0].pageX,u="number"==typeof e.pageY?e.pageY:e.touches[0].pageY,l=s-(a.getBoundingClientRect().left+window.pageXOffset),c=u-(a.getBoundingClientRect().top+window.pageYOffset);if("vertical"===n){var d=void 0;if(d=c<0?0:c>i?1:Math.round(100*c/i)/100,t.a!==d)return{h:t.h,s:t.s,l:t.l,a:d,source:"rgb"}}else{var p=void 0;if(r!==(p=l<0?0:l>o?1:Math.round(100*l/o)/100))return{h:t.h,s:t.s,l:t.l,a:p,source:"rgb"}}return null},u={},l=function(e,t,n,r){var a=e+"-"+t+"-"+n+(r?"-server":"");if(u[a])return u[a];var o=function(e,t,n,r){if("undefined"==typeof document&&!r)return null;var a=r?new r:document.createElement("canvas");a.width=2*n,a.height=2*n;var o=a.getContext("2d");return o?(o.fillStyle=e,o.fillRect(0,0,a.width,a.height),o.fillStyle=t,o.fillRect(0,0,n,n),o.translate(n,n),o.fillRect(0,0,n,n),a.toDataURL()):null}(e,t,n,r);return u[a]=o,o},c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},d=function(e){var t=e.white,n=e.grey,o=e.size,s=e.renderers,u=e.borderRadius,d=e.boxShadow,p=e.children,f=i()({default:{grid:{borderRadius:u,boxShadow:d,absolute:"0px 0px 0px 0px",background:"url("+l(t,n,o,s.canvas)+") center left"}}});return Object(r.isValidElement)(p)?a.a.cloneElement(p,c({},p.props,{style:c({},p.props.style,f.grid)})):a.a.createElement("div",{style:f.grid})};d.defaultProps={size:8,white:"transparent",grey:"rgba(0,0,0,.08)",renderers:{}};var p=d,f=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},h=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function m(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var y=function(e){function t(){var e,n,r;m(this,t);for(var a=arguments.length,o=Array(a),i=0;i<a;i++)o[i]=arguments[i];return n=r=_(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this].concat(o))),r.handleChange=function(e){var t=s(e,r.props.hsl,r.props.direction,r.props.a,r.container);t&&"function"==typeof r.props.onChange&&r.props.onChange(t,e)},r.handleMouseDown=function(e){r.handleChange(e),window.addEventListener("mousemove",r.handleChange),window.addEventListener("mouseup",r.handleMouseUp)},r.handleMouseUp=function(){r.unbindEventListeners()},r.unbindEventListeners=function(){window.removeEventListener("mousemove",r.handleChange),window.removeEventListener("mouseup",r.handleMouseUp)},_(r,n)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),h(t,[{key:"componentWillUnmount",value:function(){this.unbindEventListeners()}},{key:"render",value:function(){var e=this,t=this.props.rgb,n=i()({default:{alpha:{absolute:"0px 0px 0px 0px",borderRadius:this.props.radius},checkboard:{absolute:"0px 0px 0px 0px",overflow:"hidden",borderRadius:this.props.radius},gradient:{absolute:"0px 0px 0px 0px",background:"linear-gradient(to right, rgba("+t.r+","+t.g+","+t.b+", 0) 0%,\n rgba("+t.r+","+t.g+","+t.b+", 1) 100%)",boxShadow:this.props.shadow,borderRadius:this.props.radius},container:{position:"relative",height:"100%",margin:"0 3px"},pointer:{position:"absolute",left:100*t.a+"%"},slider:{width:"4px",borderRadius:"1px",height:"8px",boxShadow:"0 0 2px rgba(0, 0, 0, .6)",background:"#fff",marginTop:"1px",transform:"translateX(-2px)"}},vertical:{gradient:{background:"linear-gradient(to bottom, rgba("+t.r+","+t.g+","+t.b+", 0) 0%,\n rgba("+t.r+","+t.g+","+t.b+", 1) 100%)"},pointer:{left:0,top:100*t.a+"%"}},overwrite:f({},this.props.style)},{vertical:"vertical"===this.props.direction,overwrite:!0});return a.a.createElement("div",{style:n.alpha},a.a.createElement("div",{style:n.checkboard},a.a.createElement(p,{renderers:this.props.renderers})),a.a.createElement("div",{style:n.gradient}),a.a.createElement("div",{style:n.container,ref:function(t){return e.container=t},onMouseDown:this.handleMouseDown,onTouchMove:this.handleChange,onTouchStart:this.handleChange},a.a.createElement("div",{style:n.pointer},this.props.pointer?a.a.createElement(this.props.pointer,this.props):a.a.createElement("div",{style:n.slider}))))}}]),t}(r.PureComponent||r.Component),g=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var v=[38,40],b=1,w=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return n.handleBlur=function(){n.state.blurValue&&n.setState({value:n.state.blurValue,blurValue:null})},n.handleChange=function(e){n.setUpdatedValue(e.target.value,e)},n.handleKeyDown=function(e){var t,r=function(e){return Number(String(e).replace(/%/g,""))}(e.target.value);if(!isNaN(r)&&(t=e.keyCode,v.indexOf(t)>-1)){var a=n.getArrowOffset(),o=38===e.keyCode?r+a:r-a;n.setUpdatedValue(o,e)}},n.handleDrag=function(e){if(n.props.dragLabel){var t=Math.round(n.props.value+e.movementX);t>=0&&t<=n.props.dragMax&&n.props.onChange&&n.props.onChange(n.getValueObjectWithLabel(t),e)}},n.handleMouseDown=function(e){n.props.dragLabel&&(e.preventDefault(),n.handleDrag(e),window.addEventListener("mousemove",n.handleDrag),window.addEventListener("mouseup",n.handleMouseUp))},n.handleMouseUp=function(){n.unbindEventListeners()},n.unbindEventListeners=function(){window.removeEventListener("mousemove",n.handleDrag),window.removeEventListener("mouseup",n.handleMouseUp)},n.state={value:String(e.value).toUpperCase(),blurValue:String(e.value).toUpperCase()},n.inputId="rc-editable-input-"+b++,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),g(t,[{key:"componentDidUpdate",value:function(e,t){this.props.value===this.state.value||e.value===this.props.value&&t.value===this.state.value||(this.input===document.activeElement?this.setState({blurValue:String(this.props.value).toUpperCase()}):this.setState({value:String(this.props.value).toUpperCase(),blurValue:!this.state.blurValue&&String(this.props.value).toUpperCase()}))}},{key:"componentWillUnmount",value:function(){this.unbindEventListeners()}},{key:"getValueObjectWithLabel",value:function(e){return function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}({},this.props.label,e)}},{key:"getArrowOffset",value:function(){return this.props.arrowOffset||1}},{key:"setUpdatedValue",value:function(e,t){var n=this.props.label?this.getValueObjectWithLabel(e):e;this.props.onChange&&this.props.onChange(n,t),this.setState({value:e})}},{key:"render",value:function(){var e=this,t=i()({default:{wrap:{position:"relative"}},"user-override":{wrap:this.props.style&&this.props.style.wrap?this.props.style.wrap:{},input:this.props.style&&this.props.style.input?this.props.style.input:{},label:this.props.style&&this.props.style.label?this.props.style.label:{}},"dragLabel-true":{label:{cursor:"ew-resize"}}},{"user-override":!0},this.props);return a.a.createElement("div",{style:t.wrap},a.a.createElement("input",{id:this.inputId,style:t.input,ref:function(t){return e.input=t},value:this.state.value,onKeyDown:this.handleKeyDown,onChange:this.handleChange,onBlur:this.handleBlur,placeholder:this.props.placeholder,spellCheck:"false"}),this.props.label&&!this.props.hideLabel?a.a.createElement("label",{htmlFor:this.inputId,style:t.label,onMouseDown:this.handleMouseDown},this.props.label):null)}}]),t}(r.PureComponent||r.Component),M=function(e,t,n,r){var a=r.clientWidth,o=r.clientHeight,i="number"==typeof e.pageX?e.pageX:e.touches[0].pageX,s="number"==typeof e.pageY?e.pageY:e.touches[0].pageY,u=i-(r.getBoundingClientRect().left+window.pageXOffset),l=s-(r.getBoundingClientRect().top+window.pageYOffset);if("vertical"===t){var c=void 0;if(l<0)c=359;else if(l>o)c=0;else{c=360*(-100*l/o+100)/100}if(n.h!==c)return{h:c,s:n.s,l:n.l,a:n.a,source:"hsl"}}else{var d=void 0;if(u<0)d=0;else if(u>a)d=359;else{d=360*(100*u/a)/100}if(n.h!==d)return{h:d,s:n.s,l:n.l,a:n.a,source:"hsl"}}return null},L=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function T(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function k(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var x=function(e){function t(){var e,n,r;T(this,t);for(var a=arguments.length,o=Array(a),i=0;i<a;i++)o[i]=arguments[i];return n=r=k(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this].concat(o))),r.handleChange=function(e){var t=M(e,r.props.direction,r.props.hsl,r.container);t&&"function"==typeof r.props.onChange&&r.props.onChange(t,e)},r.handleMouseDown=function(e){r.handleChange(e),window.addEventListener("mousemove",r.handleChange),window.addEventListener("mouseup",r.handleMouseUp)},r.handleMouseUp=function(){r.unbindEventListeners()},k(r,n)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),L(t,[{key:"componentWillUnmount",value:function(){this.unbindEventListeners()}},{key:"unbindEventListeners",value:function(){window.removeEventListener("mousemove",this.handleChange),window.removeEventListener("mouseup",this.handleMouseUp)}},{key:"render",value:function(){var e=this,t=this.props.direction,n=void 0===t?"horizontal":t,r=i()({default:{hue:{absolute:"0px 0px 0px 0px",borderRadius:this.props.radius,boxShadow:this.props.shadow},container:{padding:"0 2px",position:"relative",height:"100%",borderRadius:this.props.radius},pointer:{position:"absolute",left:100*this.props.hsl.h/360+"%"},slider:{marginTop:"1px",width:"4px",borderRadius:"1px",height:"8px",boxShadow:"0 0 2px rgba(0, 0, 0, .6)",background:"#fff",transform:"translateX(-2px)"}},vertical:{pointer:{left:"0px",top:-100*this.props.hsl.h/360+100+"%"}}},{vertical:"vertical"===n});return a.a.createElement("div",{style:r.hue},a.a.createElement("div",{className:"hue-"+n,style:r.container,ref:function(t){return e.container=t},onMouseDown:this.handleMouseDown,onTouchMove:this.handleChange,onTouchStart:this.handleChange},a.a.createElement("style",null,"\n .hue-horizontal {\n background: linear-gradient(to right, #f00 0%, #ff0 17%, #0f0\n 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);\n background: -webkit-linear-gradient(to right, #f00 0%, #ff0\n 17%, #0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);\n }\n\n .hue-vertical {\n background: linear-gradient(to top, #f00 0%, #ff0 17%, #0f0 33%,\n #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);\n background: -webkit-linear-gradient(to top, #f00 0%, #ff0 17%,\n #0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);\n }\n "),a.a.createElement("div",{style:r.pointer},this.props.pointer?a.a.createElement(this.props.pointer,this.props):a.a.createElement("div",{style:r.slider}))))}}]),t}(r.PureComponent||r.Component),E=n(2),S=n.n(E);var O=function(){this.__data__=[],this.size=0};var D=function(e,t){return e===t||e!=e&&t!=t};var Y=function(e,t){for(var n=e.length;n--;)if(D(e[n][0],t))return n;return-1},A=Array.prototype.splice;var C=function(e){var t=this.__data__,n=Y(t,e);return!(n<0)&&(n==t.length-1?t.pop():A.call(t,n,1),--this.size,!0)};var j=function(e){var t=this.__data__,n=Y(t,e);return n<0?void 0:t[n][1]};var P=function(e){return Y(this.__data__,e)>-1};var H=function(e,t){var n=this.__data__,r=Y(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this};function I(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}I.prototype.clear=O,I.prototype.delete=C,I.prototype.get=j,I.prototype.has=P,I.prototype.set=H;var N=I;var R=function(){this.__data__=new N,this.size=0};var F=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n};var z=function(e){return this.__data__.get(e)};var U=function(e){return this.__data__.has(e)},W=n(6),B=W.a.Symbol,V=Object.prototype,G=V.hasOwnProperty,q=V.toString,J=B?B.toStringTag:void 0;var K=function(e){var t=G.call(e,J),n=e[J];try{e[J]=void 0;var r=!0}catch(e){}var a=q.call(e);return r&&(t?e[J]=n:delete e[J]),a},$=Object.prototype.toString;var X=function(e){return $.call(e)},Z=B?B.toStringTag:void 0;var Q=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Z&&Z in Object(e)?K(e):X(e)};var ee=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)};var te,ne=function(e){if(!ee(e))return!1;var t=Q(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t},re=W.a["__core-js_shared__"],ae=(te=/[^.]+$/.exec(re&&re.keys&&re.keys.IE_PROTO||""))?"Symbol(src)_1."+te:"";var oe=function(e){return!!ae&&ae in e},ie=Function.prototype.toString;var se=function(e){if(null!=e){try{return ie.call(e)}catch(e){}try{return e+""}catch(e){}}return""},ue=/^\[object .+?Constructor\]$/,le=Function.prototype,ce=Object.prototype,de=le.toString,pe=ce.hasOwnProperty,fe=RegExp("^"+de.call(pe).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");var he=function(e){return!(!ee(e)||oe(e))&&(ne(e)?fe:ue).test(se(e))};var me=function(e,t){return null==e?void 0:e[t]};var _e=function(e,t){var n=me(e,t);return he(n)?n:void 0},ye=_e(W.a,"Map"),ge=_e(Object,"create");var ve=function(){this.__data__=ge?ge(null):{},this.size=0};var be=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},we=Object.prototype.hasOwnProperty;var Me=function(e){var t=this.__data__;if(ge){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return we.call(t,e)?t[e]:void 0},Le=Object.prototype.hasOwnProperty;var Te=function(e){var t=this.__data__;return ge?void 0!==t[e]:Le.call(t,e)};var ke=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=ge&&void 0===t?"__lodash_hash_undefined__":t,this};function xe(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}xe.prototype.clear=ve,xe.prototype.delete=be,xe.prototype.get=Me,xe.prototype.has=Te,xe.prototype.set=ke;var Ee=xe;var Se=function(){this.size=0,this.__data__={hash:new Ee,map:new(ye||N),string:new Ee}};var Oe=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e};var De=function(e,t){var n=e.__data__;return Oe(t)?n["string"==typeof t?"string":"hash"]:n.map};var Ye=function(e){var t=De(this,e).delete(e);return this.size-=t?1:0,t};var Ae=function(e){return De(this,e).get(e)};var Ce=function(e){return De(this,e).has(e)};var je=function(e,t){var n=De(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this};function Pe(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Pe.prototype.clear=Se,Pe.prototype.delete=Ye,Pe.prototype.get=Ae,Pe.prototype.has=Ce,Pe.prototype.set=je;var He=Pe;var Ie=function(e,t){var n=this.__data__;if(n instanceof N){var r=n.__data__;if(!ye||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new He(r)}return n.set(e,t),this.size=n.size,this};function Ne(e){var t=this.__data__=new N(e);this.size=t.size}Ne.prototype.clear=R,Ne.prototype.delete=F,Ne.prototype.get=z,Ne.prototype.has=U,Ne.prototype.set=Ie;var Re=Ne,Fe=function(){try{var e=_e(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();var ze=function(e,t,n){"__proto__"==t&&Fe?Fe(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n};var Ue=function(e,t,n){(void 0!==n&&!D(e[t],n)||void 0===n&&!(t in e))&&ze(e,t,n)};var We=function(e){return function(t,n,r){for(var a=-1,o=Object(t),i=r(t),s=i.length;s--;){var u=i[e?s:++a];if(!1===n(o[u],u,o))break}return t}}(),Be=n(275),Ve=W.a.Uint8Array;var Ge=function(e){var t=new e.constructor(e.byteLength);return new Ve(t).set(new Ve(e)),t};var qe=function(e,t){var n=t?Ge(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)};var Je=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t},Ke=Object.create,$e=function(){function e(){}return function(t){if(!ee(t))return{};if(Ke)return Ke(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();var Xe=function(e,t){return function(n){return e(t(n))}},Ze=Xe(Object.getPrototypeOf,Object),Qe=Object.prototype;var et=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||Qe)};var tt=function(e){return"function"!=typeof e.constructor||et(e)?{}:$e(Ze(e))};var nt=function(e){return null!=e&&"object"==typeof e};var rt=function(e){return nt(e)&&"[object Arguments]"==Q(e)},at=Object.prototype,ot=at.hasOwnProperty,it=at.propertyIsEnumerable,st=rt(function(){return arguments}())?rt:function(e){return nt(e)&&ot.call(e,"callee")&&!it.call(e,"callee")},ut=Array.isArray;var lt=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991};var ct=function(e){return null!=e&&lt(e.length)&&!ne(e)};var dt=function(e){return nt(e)&&ct(e)},pt=n(20),ft=Function.prototype,ht=Object.prototype,mt=ft.toString,_t=ht.hasOwnProperty,yt=mt.call(Object);var gt=function(e){if(!nt(e)||"[object Object]"!=Q(e))return!1;var t=Ze(e);if(null===t)return!0;var n=_t.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&mt.call(n)==yt},vt={};vt["[object Float32Array]"]=vt["[object Float64Array]"]=vt["[object Int8Array]"]=vt["[object Int16Array]"]=vt["[object Int32Array]"]=vt["[object Uint8Array]"]=vt["[object Uint8ClampedArray]"]=vt["[object Uint16Array]"]=vt["[object Uint32Array]"]=!0,vt["[object Arguments]"]=vt["[object Array]"]=vt["[object ArrayBuffer]"]=vt["[object Boolean]"]=vt["[object DataView]"]=vt["[object Date]"]=vt["[object Error]"]=vt["[object Function]"]=vt["[object Map]"]=vt["[object Number]"]=vt["[object Object]"]=vt["[object RegExp]"]=vt["[object Set]"]=vt["[object String]"]=vt["[object WeakMap]"]=!1;var bt=function(e){return nt(e)&&lt(e.length)&&!!vt[Q(e)]};var wt=function(e){return function(t){return e(t)}},Mt=n(89),Lt=Mt.a&&Mt.a.isTypedArray,Tt=Lt?wt(Lt):bt;var kt=function(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]},xt=Object.prototype.hasOwnProperty;var Et=function(e,t,n){var r=e[t];xt.call(e,t)&&D(r,n)&&(void 0!==n||t in e)||ze(e,t,n)};var St=function(e,t,n,r){var a=!n;n||(n={});for(var o=-1,i=t.length;++o<i;){var s=t[o],u=r?r(n[s],e[s],s,n,e):void 0;void 0===u&&(u=e[s]),a?ze(n,s,u):Et(n,s,u)}return n};var Ot=function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r},Dt=/^(?:0|[1-9]\d*)$/;var Yt=function(e,t){var n=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==n||"symbol"!=n&&Dt.test(e))&&e>-1&&e%1==0&&e<t},At=Object.prototype.hasOwnProperty;var Ct=function(e,t){var n=ut(e),r=!n&&st(e),a=!n&&!r&&Object(pt.a)(e),o=!n&&!r&&!a&&Tt(e),i=n||r||a||o,s=i?Ot(e.length,String):[],u=s.length;for(var l in e)!t&&!At.call(e,l)||i&&("length"==l||a&&("offset"==l||"parent"==l)||o&&("buffer"==l||"byteLength"==l||"byteOffset"==l)||Yt(l,u))||s.push(l);return s};var jt=function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t},Pt=Object.prototype.hasOwnProperty;var Ht=function(e){if(!ee(e))return jt(e);var t=et(e),n=[];for(var r in e)("constructor"!=r||!t&&Pt.call(e,r))&&n.push(r);return n};var It=function(e){return ct(e)?Ct(e,!0):Ht(e)};var Nt=function(e){return St(e,It(e))};var Rt=function(e,t,n,r,a,o,i){var s=kt(e,n),u=kt(t,n),l=i.get(u);if(l)Ue(e,n,l);else{var c=o?o(s,u,n+"",e,t,i):void 0,d=void 0===c;if(d){var p=ut(u),f=!p&&Object(pt.a)(u),h=!p&&!f&&Tt(u);c=u,p||f||h?ut(s)?c=s:dt(s)?c=Je(s):f?(d=!1,c=Object(Be.a)(u,!0)):h?(d=!1,c=qe(u,!0)):c=[]:gt(u)||st(u)?(c=s,st(s)?c=Nt(s):ee(s)&&!ne(s)||(c=tt(u))):d=!1}d&&(i.set(u,c),a(c,u,r,o,i),i.delete(u)),Ue(e,n,c)}};var Ft=function e(t,n,r,a,o){t!==n&&We(n,(function(i,s){if(o||(o=new Re),ee(i))Rt(t,n,s,r,e,a,o);else{var u=a?a(kt(t,s),i,s+"",t,n,o):void 0;void 0===u&&(u=i),Ue(t,s,u)}}),It)};var zt=function(e){return e};var Ut=function(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)},Wt=Math.max;var Bt=function(e,t,n){return t=Wt(void 0===t?e.length-1:t,0),function(){for(var r=arguments,a=-1,o=Wt(r.length-t,0),i=Array(o);++a<o;)i[a]=r[t+a];a=-1;for(var s=Array(t+1);++a<t;)s[a]=r[a];return s[t]=n(i),Ut(e,this,s)}};var Vt=function(e){return function(){return e}},Gt=Fe?function(e,t){return Fe(e,"toString",{configurable:!0,enumerable:!1,value:Vt(t),writable:!0})}:zt,qt=Date.now;var Jt=function(e){var t=0,n=0;return function(){var r=qt(),a=16-(r-n);if(n=r,a>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}(Gt);var Kt=function(e,t){return Jt(Bt(e,t,zt),e+"")};var $t=function(e,t,n){if(!ee(n))return!1;var r=typeof t;return!!("number"==r?ct(n)&&Yt(t,n.length):"string"==r&&t in n)&&D(n[t],e)};var Xt=function(e){return Kt((function(t,n){var r=-1,a=n.length,o=a>1?n[a-1]:void 0,i=a>2?n[2]:void 0;for(o=e.length>3&&"function"==typeof o?(a--,o):void 0,i&&$t(n[0],n[1],i)&&(o=a<3?void 0:o,a=1),t=Object(t);++r<a;){var s=n[r];s&&e(t,s,r,o)}return t}))}((function(e,t,n){Ft(e,t,n)})),Zt=function(e){var t=e.zDepth,n=e.radius,r=e.background,o=e.children,s=e.styles,u=void 0===s?{}:s,l=i()(Xt({default:{wrap:{position:"relative",display:"inline-block"},content:{position:"relative"},bg:{absolute:"0px 0px 0px 0px",boxShadow:"0 "+t+"px "+4*t+"px rgba(0,0,0,.24)",borderRadius:n,background:r}},"zDepth-0":{bg:{boxShadow:"none"}},"zDepth-1":{bg:{boxShadow:"0 2px 10px rgba(0,0,0,.12), 0 2px 5px rgba(0,0,0,.16)"}},"zDepth-2":{bg:{boxShadow:"0 6px 20px rgba(0,0,0,.19), 0 8px 17px rgba(0,0,0,.2)"}},"zDepth-3":{bg:{boxShadow:"0 17px 50px rgba(0,0,0,.19), 0 12px 15px rgba(0,0,0,.24)"}},"zDepth-4":{bg:{boxShadow:"0 25px 55px rgba(0,0,0,.21), 0 16px 28px rgba(0,0,0,.22)"}},"zDepth-5":{bg:{boxShadow:"0 40px 77px rgba(0,0,0,.22), 0 27px 24px rgba(0,0,0,.2)"}},square:{bg:{borderRadius:"0"}},circle:{bg:{borderRadius:"50%"}}},u),{"zDepth-1":1===t});return a.a.createElement("div",{style:l.wrap},a.a.createElement("div",{style:l.bg}),a.a.createElement("div",{style:l.content},o))};Zt.propTypes={background:S.a.string,zDepth:S.a.oneOf([0,1,2,3,4,5]),radius:S.a.number,styles:S.a.object},Zt.defaultProps={background:"#fff",zDepth:1,radius:2,styles:{}};var Qt=Zt,en=function(){return W.a.Date.now()},tn=/\s/;var nn=function(e){for(var t=e.length;t--&&tn.test(e.charAt(t)););return t},rn=/^\s+/;var an=function(e){return e?e.slice(0,nn(e)+1).replace(rn,""):e};var on=function(e){return"symbol"==typeof e||nt(e)&&"[object Symbol]"==Q(e)},sn=/^[-+]0x[0-9a-f]+$/i,un=/^0b[01]+$/i,ln=/^0o[0-7]+$/i,cn=parseInt;var dn=function(e){if("number"==typeof e)return e;if(on(e))return NaN;if(ee(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=ee(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=an(e);var n=un.test(e);return n||ln.test(e)?cn(e.slice(2),n?2:8):sn.test(e)?NaN:+e},pn=Math.max,fn=Math.min;var hn=function(e,t,n){var r,a,o,i,s,u,l=0,c=!1,d=!1,p=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function f(t){var n=r,o=a;return r=a=void 0,l=t,i=e.apply(o,n)}function h(e){return l=e,s=setTimeout(_,t),c?f(e):i}function m(e){var n=e-u;return void 0===u||n>=t||n<0||d&&e-l>=o}function _(){var e=en();if(m(e))return y(e);s=setTimeout(_,function(e){var n=t-(e-u);return d?fn(n,o-(e-l)):n}(e))}function y(e){return s=void 0,p&&r?f(e):(r=a=void 0,i)}function g(){var e=en(),n=m(e);if(r=arguments,a=this,u=e,n){if(void 0===s)return h(u);if(d)return clearTimeout(s),s=setTimeout(_,t),f(u)}return void 0===s&&(s=setTimeout(_,t)),i}return t=dn(t)||0,ee(n)&&(c=!!n.leading,o=(d="maxWait"in n)?pn(dn(n.maxWait)||0,t):o,p="trailing"in n?!!n.trailing:p),g.cancel=function(){void 0!==s&&clearTimeout(s),l=0,r=u=a=s=void 0},g.flush=function(){return void 0===s?i:y(en())},g};var mn=function(e,t,n){var r=!0,a=!0;if("function"!=typeof e)throw new TypeError("Expected a function");return ee(n)&&(r="leading"in n?!!n.leading:r,a="trailing"in n?!!n.trailing:a),hn(e,t,{leading:r,maxWait:t,trailing:a})},_n=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var yn=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.handleChange=function(e){"function"==typeof n.props.onChange&&n.throttle(n.props.onChange,function(e,t,n){var r=n.getBoundingClientRect(),a=r.width,o=r.height,i="number"==typeof e.pageX?e.pageX:e.touches[0].pageX,s="number"==typeof e.pageY?e.pageY:e.touches[0].pageY,u=i-(n.getBoundingClientRect().left+window.pageXOffset),l=s-(n.getBoundingClientRect().top+window.pageYOffset);u<0?u=0:u>a&&(u=a),l<0?l=0:l>o&&(l=o);var c=u/a,d=1-l/o;return{h:t.h,s:c,v:d,a:t.a,source:"hsv"}}(e,n.props.hsl,n.container),e)},n.handleMouseDown=function(e){n.handleChange(e);var t=n.getContainerRenderWindow();t.addEventListener("mousemove",n.handleChange),t.addEventListener("mouseup",n.handleMouseUp)},n.handleMouseUp=function(){n.unbindEventListeners()},n.throttle=mn((function(e,t,n){e(t,n)}),50),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),_n(t,[{key:"componentWillUnmount",value:function(){this.throttle.cancel(),this.unbindEventListeners()}},{key:"getContainerRenderWindow",value:function(){for(var e=this.container,t=window;!t.document.contains(e)&&t.parent!==t;)t=t.parent;return t}},{key:"unbindEventListeners",value:function(){var e=this.getContainerRenderWindow();e.removeEventListener("mousemove",this.handleChange),e.removeEventListener("mouseup",this.handleMouseUp)}},{key:"render",value:function(){var e=this,t=this.props.style||{},n=t.color,r=t.white,o=t.black,s=t.pointer,u=t.circle,l=i()({default:{color:{absolute:"0px 0px 0px 0px",background:"hsl("+this.props.hsl.h+",100%, 50%)",borderRadius:this.props.radius},white:{absolute:"0px 0px 0px 0px",borderRadius:this.props.radius},black:{absolute:"0px 0px 0px 0px",boxShadow:this.props.shadow,borderRadius:this.props.radius},pointer:{position:"absolute",top:-100*this.props.hsv.v+100+"%",left:100*this.props.hsv.s+"%",cursor:"default"},circle:{width:"4px",height:"4px",boxShadow:"0 0 0 1.5px #fff, inset 0 0 1px 1px rgba(0,0,0,.3),\n 0 0 1px 2px rgba(0,0,0,.4)",borderRadius:"50%",cursor:"hand",transform:"translate(-2px, -2px)"}},custom:{color:n,white:r,black:o,pointer:s,circle:u}},{custom:!!this.props.style});return a.a.createElement("div",{style:l.color,ref:function(t){return e.container=t},onMouseDown:this.handleMouseDown,onTouchMove:this.handleChange,onTouchStart:this.handleChange},a.a.createElement("style",null,"\n .saturation-white {\n background: -webkit-linear-gradient(to right, #fff, rgba(255,255,255,0));\n background: linear-gradient(to right, #fff, rgba(255,255,255,0));\n }\n .saturation-black {\n background: -webkit-linear-gradient(to top, #000, rgba(0,0,0,0));\n background: linear-gradient(to top, #000, rgba(0,0,0,0));\n }\n "),a.a.createElement("div",{style:l.white,className:"saturation-white"},a.a.createElement("div",{style:l.black,className:"saturation-black"}),a.a.createElement("div",{style:l.pointer},this.props.pointer?a.a.createElement(this.props.pointer,this.props):a.a.createElement("div",{style:l.circle}))))}}]),t}(r.PureComponent||r.Component);var gn=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e},vn=Xe(Object.keys,Object),bn=Object.prototype.hasOwnProperty;var wn=function(e){if(!et(e))return vn(e);var t=[];for(var n in Object(e))bn.call(e,n)&&"constructor"!=n&&t.push(n);return t};var Mn=function(e){return ct(e)?Ct(e):wn(e)};var Ln=function(e,t){return function(n,r){if(null==n)return n;if(!ct(n))return e(n,r);for(var a=n.length,o=t?a:-1,i=Object(n);(t?o--:++o<a)&&!1!==r(i[o],o,i););return n}}((function(e,t){return e&&We(e,t,Mn)}));var Tn=function(e){return"function"==typeof e?e:zt};var kn=function(e,t){return(ut(e)?gn:Ln)(e,Tn(t))},xn=n(36),En=n.n(xn),Sn=function(e){var t=0,n=0;return kn(["r","g","b","a","h","s","l","v"],(function(r){if(e[r]&&(t+=1,isNaN(e[r])||(n+=1),"s"===r||"l"===r)){/^\d+%$/.test(e[r])&&(n+=1)}})),t===n&&e},On=function(e,t){var n=e.hex?En()(e.hex):En()(e),r=n.toHsl(),a=n.toHsv(),o=n.toRgb(),i=n.toHex();return 0===r.s&&(r.h=t||0,a.h=t||0),{hsl:r,hex:"000000"===i&&0===o.a?"transparent":"#"+i,rgb:o,hsv:a,oldHue:e.h||t||r.h,source:e.source}},Dn=function(e){if("transparent"===e)return!0;var t="#"===String(e).charAt(0)?1:0;return e.length!==4+t&&e.length<7+t&&En()(e).isValid()},Yn=function(e){if(!e)return"#fff";var t=On(e);return"transparent"===t.hex?"rgba(0,0,0,0.4)":(299*t.rgb.r+587*t.rgb.g+114*t.rgb.b)/1e3>=128?"#000":"#fff"},An=function(e,t){var n=e.replace("°","");return En()(t+" ("+n+")")._ok},Cn=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},jn=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var Pn=function(e){var t=function(t){function n(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(n.__proto__||Object.getPrototypeOf(n)).call(this));return t.handleChange=function(e,n){if(Sn(e)){var r=On(e,e.h||t.state.oldHue);t.setState(r),t.props.onChangeComplete&&t.debounce(t.props.onChangeComplete,r,n),t.props.onChange&&t.props.onChange(r,n)}},t.handleSwatchHover=function(e,n){if(Sn(e)){var r=On(e,e.h||t.state.oldHue);t.props.onSwatchHover&&t.props.onSwatchHover(r,n)}},t.state=Cn({},On(e.color,0)),t.debounce=hn((function(e,t,n){e(t,n)}),100),t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(n,t),jn(n,[{key:"render",value:function(){var t={};return this.props.onSwatchHover&&(t.onSwatchHover=this.handleSwatchHover),a.a.createElement(e,Cn({},this.props,this.state,{onChange:this.handleChange},t))}}],[{key:"getDerivedStateFromProps",value:function(e,t){return Cn({},On(e.color,t.oldHue))}}]),n}(r.PureComponent||r.Component);return t.propTypes=Cn({},e.propTypes),t.defaultProps=Cn({},e.defaultProps,{color:{h:250,s:.5,l:.2,a:1}}),t},Hn=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},In=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function Nn(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Rn(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function Fn(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var zn=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Un=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"span";return function(n){function r(){var e,t,n;Nn(this,r);for(var a=arguments.length,o=Array(a),i=0;i<a;i++)o[i]=arguments[i];return t=n=Rn(this,(e=r.__proto__||Object.getPrototypeOf(r)).call.apply(e,[this].concat(o))),n.state={focus:!1},n.handleFocus=function(){return n.setState({focus:!0})},n.handleBlur=function(){return n.setState({focus:!1})},Rn(n,t)}return Fn(r,n),In(r,[{key:"render",value:function(){return a.a.createElement(t,{onFocus:this.handleFocus,onBlur:this.handleBlur},a.a.createElement(e,Hn({},this.props,this.state)))}}]),r}(a.a.Component)}((function(e){var t=e.color,n=e.style,r=e.onClick,o=void 0===r?function(){}:r,s=e.onHover,u=e.title,l=void 0===u?t:u,c=e.children,d=e.focus,f=e.focusStyle,h=void 0===f?{}:f,m="transparent"===t,_=i()({default:{swatch:zn({background:t,height:"100%",width:"100%",cursor:"pointer",position:"relative",outline:"none"},n,d?h:{})}}),y={};return s&&(y.onMouseOver=function(e){return s(t,e)}),a.a.createElement("div",zn({style:_.swatch,onClick:function(e){return o(t,e)},title:l,tabIndex:0,onKeyDown:function(e){return 13===e.keyCode&&o(t,e)}},y),c,m&&a.a.createElement(p,{borderRadius:_.swatch.borderRadius,boxShadow:"inset 0 0 0 1px rgba(0,0,0,0.1)"}))})),Wn=function(e){var t=e.direction,n=i()({default:{picker:{width:"18px",height:"18px",borderRadius:"50%",transform:"translate(-9px, -1px)",backgroundColor:"rgb(248, 248, 248)",boxShadow:"0 1px 4px 0 rgba(0, 0, 0, 0.37)"}},vertical:{picker:{transform:"translate(-3px, -9px)"}}},{vertical:"vertical"===t});return a.a.createElement("div",{style:n.picker})},Bn=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Vn=function(e){var t=e.rgb,n=e.hsl,r=e.width,o=e.height,s=e.onChange,u=e.direction,l=e.style,c=e.renderers,d=e.pointer,p=e.className,f=void 0===p?"":p,h=i()({default:{picker:{position:"relative",width:r,height:o},alpha:{radius:"2px",style:l}}});return a.a.createElement("div",{style:h.picker,className:"alpha-picker "+f},a.a.createElement(y,Bn({},h.alpha,{rgb:t,hsl:n,pointer:d,renderers:c,onChange:s,direction:u})))};Vn.defaultProps={width:"316px",height:"16px",direction:"horizontal",pointer:Wn};var Gn=Pn(Vn);var qn=function(e,t){for(var n=-1,r=null==e?0:e.length,a=Array(r);++n<r;)a[n]=t(e[n],n,e);return a};var Jn=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this};var Kn=function(e){return this.__data__.has(e)};function $n(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new He;++t<n;)this.add(e[t])}$n.prototype.add=$n.prototype.push=Jn,$n.prototype.has=Kn;var Xn=$n;var Zn=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1};var Qn=function(e,t){return e.has(t)};var er=function(e,t,n,r,a,o){var i=1&n,s=e.length,u=t.length;if(s!=u&&!(i&&u>s))return!1;var l=o.get(e),c=o.get(t);if(l&&c)return l==t&&c==e;var d=-1,p=!0,f=2&n?new Xn:void 0;for(o.set(e,t),o.set(t,e);++d<s;){var h=e[d],m=t[d];if(r)var _=i?r(m,h,d,t,e,o):r(h,m,d,e,t,o);if(void 0!==_){if(_)continue;p=!1;break}if(f){if(!Zn(t,(function(e,t){if(!Qn(f,t)&&(h===e||a(h,e,n,r,o)))return f.push(t)}))){p=!1;break}}else if(h!==m&&!a(h,m,n,r,o)){p=!1;break}}return o.delete(e),o.delete(t),p};var tr=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n};var nr=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n},rr=B?B.prototype:void 0,ar=rr?rr.valueOf:void 0;var or=function(e,t,n,r,a,o,i){switch(n){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!o(new Ve(e),new Ve(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return D(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var s=tr;case"[object Set]":var u=1&r;if(s||(s=nr),e.size!=t.size&&!u)return!1;var l=i.get(e);if(l)return l==t;r|=2,i.set(e,t);var c=er(s(e),s(t),r,a,o,i);return i.delete(e),c;case"[object Symbol]":if(ar)return ar.call(e)==ar.call(t)}return!1};var ir=function(e,t){for(var n=-1,r=t.length,a=e.length;++n<r;)e[a+n]=t[n];return e};var sr=function(e,t,n){var r=t(e);return ut(e)?r:ir(r,n(e))};var ur=function(e,t){for(var n=-1,r=null==e?0:e.length,a=0,o=[];++n<r;){var i=e[n];t(i,n,e)&&(o[a++]=i)}return o};var lr=function(){return[]},cr=Object.prototype.propertyIsEnumerable,dr=Object.getOwnPropertySymbols,pr=dr?function(e){return null==e?[]:(e=Object(e),ur(dr(e),(function(t){return cr.call(e,t)})))}:lr;var fr=function(e){return sr(e,Mn,pr)},hr=Object.prototype.hasOwnProperty;var mr=function(e,t,n,r,a,o){var i=1&n,s=fr(e),u=s.length;if(u!=fr(t).length&&!i)return!1;for(var l=u;l--;){var c=s[l];if(!(i?c in t:hr.call(t,c)))return!1}var d=o.get(e),p=o.get(t);if(d&&p)return d==t&&p==e;var f=!0;o.set(e,t),o.set(t,e);for(var h=i;++l<u;){var m=e[c=s[l]],_=t[c];if(r)var y=i?r(_,m,c,t,e,o):r(m,_,c,e,t,o);if(!(void 0===y?m===_||a(m,_,n,r,o):y)){f=!1;break}h||(h="constructor"==c)}if(f&&!h){var g=e.constructor,v=t.constructor;g==v||!("constructor"in e)||!("constructor"in t)||"function"==typeof g&&g instanceof g&&"function"==typeof v&&v instanceof v||(f=!1)}return o.delete(e),o.delete(t),f},_r=_e(W.a,"DataView"),yr=_e(W.a,"Promise"),gr=_e(W.a,"Set"),vr=_e(W.a,"WeakMap"),br=se(_r),wr=se(ye),Mr=se(yr),Lr=se(gr),Tr=se(vr),kr=Q;(_r&&"[object DataView]"!=kr(new _r(new ArrayBuffer(1)))||ye&&"[object Map]"!=kr(new ye)||yr&&"[object Promise]"!=kr(yr.resolve())||gr&&"[object Set]"!=kr(new gr)||vr&&"[object WeakMap]"!=kr(new vr))&&(kr=function(e){var t=Q(e),n="[object Object]"==t?e.constructor:void 0,r=n?se(n):"";if(r)switch(r){case br:return"[object DataView]";case wr:return"[object Map]";case Mr:return"[object Promise]";case Lr:return"[object Set]";case Tr:return"[object WeakMap]"}return t});var xr=kr,Er=Object.prototype.hasOwnProperty;var Sr=function(e,t,n,r,a,o){var i=ut(e),s=ut(t),u=i?"[object Array]":xr(e),l=s?"[object Array]":xr(t),c="[object Object]"==(u="[object Arguments]"==u?"[object Object]":u),d="[object Object]"==(l="[object Arguments]"==l?"[object Object]":l),p=u==l;if(p&&Object(pt.a)(e)){if(!Object(pt.a)(t))return!1;i=!0,c=!1}if(p&&!c)return o||(o=new Re),i||Tt(e)?er(e,t,n,r,a,o):or(e,t,u,n,r,a,o);if(!(1&n)){var f=c&&Er.call(e,"__wrapped__"),h=d&&Er.call(t,"__wrapped__");if(f||h){var m=f?e.value():e,_=h?t.value():t;return o||(o=new Re),a(m,_,n,r,o)}}return!!p&&(o||(o=new Re),mr(e,t,n,r,a,o))};var Or=function e(t,n,r,a,o){return t===n||(null==t||null==n||!nt(t)&&!nt(n)?t!=t&&n!=n:Sr(t,n,r,a,e,o))};var Dr=function(e,t,n,r){var a=n.length,o=a,i=!r;if(null==e)return!o;for(e=Object(e);a--;){var s=n[a];if(i&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++a<o;){var u=(s=n[a])[0],l=e[u],c=s[1];if(i&&s[2]){if(void 0===l&&!(u in e))return!1}else{var d=new Re;if(r)var p=r(l,c,u,e,t,d);if(!(void 0===p?Or(c,l,3,r,d):p))return!1}}return!0};var Yr=function(e){return e==e&&!ee(e)};var Ar=function(e){for(var t=Mn(e),n=t.length;n--;){var r=t[n],a=e[r];t[n]=[r,a,Yr(a)]}return t};var Cr=function(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in Object(n)))}};var jr=function(e){var t=Ar(e);return 1==t.length&&t[0][2]?Cr(t[0][0],t[0][1]):function(n){return n===e||Dr(n,e,t)}},Pr=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Hr=/^\w*$/;var Ir=function(e,t){if(ut(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!on(e))||(Hr.test(e)||!Pr.test(e)||null!=t&&e in Object(t))};function Nr(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,a=t?t.apply(this,r):r[0],o=n.cache;if(o.has(a))return o.get(a);var i=e.apply(this,r);return n.cache=o.set(a,i)||o,i};return n.cache=new(Nr.Cache||He),n}Nr.Cache=He;var Rr=Nr;var Fr=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,zr=/\\(\\)?/g,Ur=function(e){var t=Rr(e,(function(e){return 500===n.size&&n.clear(),e})),n=t.cache;return t}((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(Fr,(function(e,n,r,a){t.push(r?a.replace(zr,"$1"):n||e)})),t})),Wr=B?B.prototype:void 0,Br=Wr?Wr.toString:void 0;var Vr=function e(t){if("string"==typeof t)return t;if(ut(t))return qn(t,e)+"";if(on(t))return Br?Br.call(t):"";var n=t+"";return"0"==n&&1/t==-1/0?"-0":n};var Gr=function(e){return null==e?"":Vr(e)};var qr=function(e,t){return ut(e)?e:Ir(e,t)?[e]:Ur(Gr(e))};var Jr=function(e){if("string"==typeof e||on(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t};var Kr=function(e,t){for(var n=0,r=(t=qr(t,e)).length;null!=e&&n<r;)e=e[Jr(t[n++])];return n&&n==r?e:void 0};var $r=function(e,t,n){var r=null==e?void 0:Kr(e,t);return void 0===r?n:r};var Xr=function(e,t){return null!=e&&t in Object(e)};var Zr=function(e,t,n){for(var r=-1,a=(t=qr(t,e)).length,o=!1;++r<a;){var i=Jr(t[r]);if(!(o=null!=e&&n(e,i)))break;e=e[i]}return o||++r!=a?o:!!(a=null==e?0:e.length)&&lt(a)&&Yt(i,a)&&(ut(e)||st(e))};var Qr=function(e,t){return null!=e&&Zr(e,t,Xr)};var ea=function(e,t){return Ir(e)&&Yr(t)?Cr(Jr(e),t):function(n){var r=$r(n,e);return void 0===r&&r===t?Qr(n,e):Or(t,r,3)}};var ta=function(e){return function(t){return null==t?void 0:t[e]}};var na=function(e){return function(t){return Kr(t,e)}};var ra=function(e){return Ir(e)?ta(Jr(e)):na(e)};var aa=function(e){return"function"==typeof e?e:null==e?zt:"object"==typeof e?ut(e)?ea(e[0],e[1]):jr(e):ra(e)};var oa=function(e,t){var n=-1,r=ct(e)?Array(e.length):[];return Ln(e,(function(e,a,o){r[++n]=t(e,a,o)})),r};var ia=function(e,t){return(ut(e)?qn:oa)(e,aa(t,3))},sa=function(e){var t=e.colors,n=e.onClick,r=e.onSwatchHover,o=i()({default:{swatches:{marginRight:"-10px"},swatch:{width:"22px",height:"22px",float:"left",marginRight:"10px",marginBottom:"10px",borderRadius:"4px"},clear:{clear:"both"}}});return a.a.createElement("div",{style:o.swatches},ia(t,(function(e){return a.a.createElement(Un,{key:e,color:e,style:o.swatch,onClick:n,onHover:r,focusStyle:{boxShadow:"0 0 4px "+e}})})),a.a.createElement("div",{style:o.clear}))},ua=function(e){var t=e.onChange,n=e.onSwatchHover,r=e.hex,o=e.colors,s=e.width,u=e.triangle,l=e.styles,c=void 0===l?{}:l,d=e.className,f=void 0===d?"":d,h="transparent"===r,m=function(e,n){Dn(e)&&t({hex:e,source:"hex"},n)},_=i()(Xt({default:{card:{width:s,background:"#fff",boxShadow:"0 1px rgba(0,0,0,.1)",borderRadius:"6px",position:"relative"},head:{height:"110px",background:r,borderRadius:"6px 6px 0 0",display:"flex",alignItems:"center",justifyContent:"center",position:"relative"},body:{padding:"10px"},label:{fontSize:"18px",color:Yn(r),position:"relative"},triangle:{width:"0px",height:"0px",borderStyle:"solid",borderWidth:"0 10px 10px 10px",borderColor:"transparent transparent "+r+" transparent",position:"absolute",top:"-10px",left:"50%",marginLeft:"-10px"},input:{width:"100%",fontSize:"12px",color:"#666",border:"0px",outline:"none",height:"22px",boxShadow:"inset 0 0 0 1px #ddd",borderRadius:"4px",padding:"0 7px",boxSizing:"border-box"}},"hide-triangle":{triangle:{display:"none"}}},c),{"hide-triangle":"hide"===u});return a.a.createElement("div",{style:_.card,className:"block-picker "+f},a.a.createElement("div",{style:_.triangle}),a.a.createElement("div",{style:_.head},h&&a.a.createElement(p,{borderRadius:"6px 6px 0 0"}),a.a.createElement("div",{style:_.label},r)),a.a.createElement("div",{style:_.body},a.a.createElement(sa,{colors:o,onClick:m,onSwatchHover:n}),a.a.createElement(w,{style:{input:_.input},value:r,onChange:m})))};ua.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),colors:S.a.arrayOf(S.a.string),triangle:S.a.oneOf(["top","hide"]),styles:S.a.object},ua.defaultProps={width:170,colors:["#D9E3F0","#F47373","#697689","#37D67A","#2CCCE4","#555555","#dce775","#ff8a65","#ba68c8"],triangle:"top",styles:{}};var la=Pn(ua),ca={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",a100:"#ff8a80",a200:"#ff5252",a400:"#ff1744",a700:"#d50000"},da={50:"#fce4ec",100:"#f8bbd0",200:"#f48fb1",300:"#f06292",400:"#ec407a",500:"#e91e63",600:"#d81b60",700:"#c2185b",800:"#ad1457",900:"#880e4f",a100:"#ff80ab",a200:"#ff4081",a400:"#f50057",a700:"#c51162"},pa={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",a100:"#ea80fc",a200:"#e040fb",a400:"#d500f9",a700:"#aa00ff"},fa={50:"#ede7f6",100:"#d1c4e9",200:"#b39ddb",300:"#9575cd",400:"#7e57c2",500:"#673ab7",600:"#5e35b1",700:"#512da8",800:"#4527a0",900:"#311b92",a100:"#b388ff",a200:"#7c4dff",a400:"#651fff",a700:"#6200ea"},ha={50:"#e8eaf6",100:"#c5cae9",200:"#9fa8da",300:"#7986cb",400:"#5c6bc0",500:"#3f51b5",600:"#3949ab",700:"#303f9f",800:"#283593",900:"#1a237e",a100:"#8c9eff",a200:"#536dfe",a400:"#3d5afe",a700:"#304ffe"},ma={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",a100:"#82b1ff",a200:"#448aff",a400:"#2979ff",a700:"#2962ff"},_a={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",a100:"#80d8ff",a200:"#40c4ff",a400:"#00b0ff",a700:"#0091ea"},ya={50:"#e0f7fa",100:"#b2ebf2",200:"#80deea",300:"#4dd0e1",400:"#26c6da",500:"#00bcd4",600:"#00acc1",700:"#0097a7",800:"#00838f",900:"#006064",a100:"#84ffff",a200:"#18ffff",a400:"#00e5ff",a700:"#00b8d4"},ga={50:"#e0f2f1",100:"#b2dfdb",200:"#80cbc4",300:"#4db6ac",400:"#26a69a",500:"#009688",600:"#00897b",700:"#00796b",800:"#00695c",900:"#004d40",a100:"#a7ffeb",a200:"#64ffda",a400:"#1de9b6",a700:"#00bfa5"},va={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",a100:"#b9f6ca",a200:"#69f0ae",a400:"#00e676",a700:"#00c853"},ba={50:"#f1f8e9",100:"#dcedc8",200:"#c5e1a5",300:"#aed581",400:"#9ccc65",500:"#8bc34a",600:"#7cb342",700:"#689f38",800:"#558b2f",900:"#33691e",a100:"#ccff90",a200:"#b2ff59",a400:"#76ff03",a700:"#64dd17"},wa={50:"#f9fbe7",100:"#f0f4c3",200:"#e6ee9c",300:"#dce775",400:"#d4e157",500:"#cddc39",600:"#c0ca33",700:"#afb42b",800:"#9e9d24",900:"#827717",a100:"#f4ff81",a200:"#eeff41",a400:"#c6ff00",a700:"#aeea00"},Ma={50:"#fffde7",100:"#fff9c4",200:"#fff59d",300:"#fff176",400:"#ffee58",500:"#ffeb3b",600:"#fdd835",700:"#fbc02d",800:"#f9a825",900:"#f57f17",a100:"#ffff8d",a200:"#ffff00",a400:"#ffea00",a700:"#ffd600"},La={50:"#fff8e1",100:"#ffecb3",200:"#ffe082",300:"#ffd54f",400:"#ffca28",500:"#ffc107",600:"#ffb300",700:"#ffa000",800:"#ff8f00",900:"#ff6f00",a100:"#ffe57f",a200:"#ffd740",a400:"#ffc400",a700:"#ffab00"},Ta={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",a100:"#ffd180",a200:"#ffab40",a400:"#ff9100",a700:"#ff6d00"},ka={50:"#fbe9e7",100:"#ffccbc",200:"#ffab91",300:"#ff8a65",400:"#ff7043",500:"#ff5722",600:"#f4511e",700:"#e64a19",800:"#d84315",900:"#bf360c",a100:"#ff9e80",a200:"#ff6e40",a400:"#ff3d00",a700:"#dd2c00"},xa={50:"#efebe9",100:"#d7ccc8",200:"#bcaaa4",300:"#a1887f",400:"#8d6e63",500:"#795548",600:"#6d4c41",700:"#5d4037",800:"#4e342e",900:"#3e2723"},Ea={50:"#eceff1",100:"#cfd8dc",200:"#b0bec5",300:"#90a4ae",400:"#78909c",500:"#607d8b",600:"#546e7a",700:"#455a64",800:"#37474f",900:"#263238"},Sa=function(e){var t=e.color,n=e.onClick,r=e.onSwatchHover,o=e.hover,s=e.active,u=e.circleSize,l=e.circleSpacing,c=i()({default:{swatch:{width:u,height:u,marginRight:l,marginBottom:l,transform:"scale(1)",transition:"100ms transform ease"},Swatch:{borderRadius:"50%",background:"transparent",boxShadow:"inset 0 0 0 "+(u/2+1)+"px "+t,transition:"100ms box-shadow ease"}},hover:{swatch:{transform:"scale(1.2)"}},active:{Swatch:{boxShadow:"inset 0 0 0 3px "+t}}},{hover:o,active:s});return a.a.createElement("div",{style:c.swatch},a.a.createElement(Un,{style:c.Swatch,color:t,onClick:n,onHover:r,focusStyle:{boxShadow:c.Swatch.boxShadow+", 0 0 5px "+t}}))};Sa.defaultProps={circleSize:28,circleSpacing:14};var Oa=Object(o.handleHover)(Sa),Da=function(e){var t=e.width,n=e.onChange,r=e.onSwatchHover,o=e.colors,s=e.hex,u=e.circleSize,l=e.styles,c=void 0===l?{}:l,d=e.circleSpacing,p=e.className,f=void 0===p?"":p,h=i()(Xt({default:{card:{width:t,display:"flex",flexWrap:"wrap",marginRight:-d,marginBottom:-d}}},c)),m=function(e,t){return n({hex:e,source:"hex"},t)};return a.a.createElement("div",{style:h.card,className:"circle-picker "+f},ia(o,(function(e){return a.a.createElement(Oa,{key:e,color:e,onClick:m,onSwatchHover:r,active:s===e.toLowerCase(),circleSize:u,circleSpacing:d})})))};Da.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),circleSize:S.a.number,circleSpacing:S.a.number,styles:S.a.object},Da.defaultProps={width:252,circleSize:28,circleSpacing:14,colors:[ca[500],da[500],pa[500],fa[500],ha[500],ma[500],_a[500],ya[500],ga[500],va[500],ba[500],wa[500],Ma[500],La[500],Ta[500],ka[500],xa[500],Ea[500]],styles:{}};var Ya=Pn(Da);var Aa=function(e){return void 0===e},Ca=n(276),ja=n.n(Ca),Pa=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var Ha=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return n.toggleViews=function(){"hex"===n.state.view?n.setState({view:"rgb"}):"rgb"===n.state.view?n.setState({view:"hsl"}):"hsl"===n.state.view&&(1===n.props.hsl.a?n.setState({view:"hex"}):n.setState({view:"rgb"}))},n.handleChange=function(e,t){e.hex?Dn(e.hex)&&n.props.onChange({hex:e.hex,source:"hex"},t):e.r||e.g||e.b?n.props.onChange({r:e.r||n.props.rgb.r,g:e.g||n.props.rgb.g,b:e.b||n.props.rgb.b,source:"rgb"},t):e.a?(e.a<0?e.a=0:e.a>1&&(e.a=1),n.props.onChange({h:n.props.hsl.h,s:n.props.hsl.s,l:n.props.hsl.l,a:Math.round(100*e.a)/100,source:"rgb"},t)):(e.h||e.s||e.l)&&("string"==typeof e.s&&e.s.includes("%")&&(e.s=e.s.replace("%","")),"string"==typeof e.l&&e.l.includes("%")&&(e.l=e.l.replace("%","")),1==e.s?e.s=.01:1==e.l&&(e.l=.01),n.props.onChange({h:e.h||n.props.hsl.h,s:Number(Aa(e.s)?n.props.hsl.s:e.s),l:Number(Aa(e.l)?n.props.hsl.l:e.l),source:"hsl"},t))},n.showHighlight=function(e){e.currentTarget.style.background="#eee"},n.hideHighlight=function(e){e.currentTarget.style.background="transparent"},1!==e.hsl.a&&"hex"===e.view?n.state={view:"rgb"}:n.state={view:e.view},n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),Pa(t,[{key:"render",value:function(){var e=this,t=i()({default:{wrap:{paddingTop:"16px",display:"flex"},fields:{flex:"1",display:"flex",marginLeft:"-6px"},field:{paddingLeft:"6px",width:"100%"},alpha:{paddingLeft:"6px",width:"100%"},toggle:{width:"32px",textAlign:"right",position:"relative"},icon:{marginRight:"-4px",marginTop:"12px",cursor:"pointer",position:"relative"},iconHighlight:{position:"absolute",width:"24px",height:"28px",background:"#eee",borderRadius:"4px",top:"10px",left:"12px",display:"none"},input:{fontSize:"11px",color:"#333",width:"100%",borderRadius:"2px",border:"none",boxShadow:"inset 0 0 0 1px #dadada",height:"21px",textAlign:"center"},label:{textTransform:"uppercase",fontSize:"11px",lineHeight:"11px",color:"#969696",textAlign:"center",display:"block",marginTop:"12px"},svg:{fill:"#333",width:"24px",height:"24px",border:"1px transparent solid",borderRadius:"5px"}},disableAlpha:{alpha:{display:"none"}}},this.props,this.state),n=void 0;return"hex"===this.state.view?n=a.a.createElement("div",{style:t.fields,className:"flexbox-fix"},a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"hex",value:this.props.hex,onChange:this.handleChange}))):"rgb"===this.state.view?n=a.a.createElement("div",{style:t.fields,className:"flexbox-fix"},a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"r",value:this.props.rgb.r,onChange:this.handleChange})),a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"g",value:this.props.rgb.g,onChange:this.handleChange})),a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"b",value:this.props.rgb.b,onChange:this.handleChange})),a.a.createElement("div",{style:t.alpha},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"a",value:this.props.rgb.a,arrowOffset:.01,onChange:this.handleChange}))):"hsl"===this.state.view&&(n=a.a.createElement("div",{style:t.fields,className:"flexbox-fix"},a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"h",value:Math.round(this.props.hsl.h),onChange:this.handleChange})),a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"s",value:Math.round(100*this.props.hsl.s)+"%",onChange:this.handleChange})),a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"l",value:Math.round(100*this.props.hsl.l)+"%",onChange:this.handleChange})),a.a.createElement("div",{style:t.alpha},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"a",value:this.props.hsl.a,arrowOffset:.01,onChange:this.handleChange})))),a.a.createElement("div",{style:t.wrap,className:"flexbox-fix"},n,a.a.createElement("div",{style:t.toggle},a.a.createElement("div",{style:t.icon,onClick:this.toggleViews,ref:function(t){return e.icon=t}},a.a.createElement(ja.a,{style:t.svg,onMouseOver:this.showHighlight,onMouseEnter:this.showHighlight,onMouseOut:this.hideHighlight}))))}}],[{key:"getDerivedStateFromProps",value:function(e,t){return 1!==e.hsl.a&&"hex"===t.view?{view:"rgb"}:null}}]),t}(a.a.Component);Ha.defaultProps={view:"hex"};var Ia=Ha,Na=function(){var e=i()({default:{picker:{width:"12px",height:"12px",borderRadius:"6px",transform:"translate(-6px, -1px)",backgroundColor:"rgb(248, 248, 248)",boxShadow:"0 1px 4px 0 rgba(0, 0, 0, 0.37)"}}});return a.a.createElement("div",{style:e.picker})},Ra=function(){var e=i()({default:{picker:{width:"12px",height:"12px",borderRadius:"6px",boxShadow:"inset 0 0 0 1px #fff",transform:"translate(-6px, -6px)"}}});return a.a.createElement("div",{style:e.picker})},Fa=function(e){var t=e.width,n=e.onChange,r=e.disableAlpha,o=e.rgb,s=e.hsl,u=e.hsv,l=e.hex,c=e.renderers,d=e.styles,f=void 0===d?{}:d,h=e.className,m=void 0===h?"":h,_=e.defaultView,g=i()(Xt({default:{picker:{width:t,background:"#fff",borderRadius:"2px",boxShadow:"0 0 2px rgba(0,0,0,.3), 0 4px 8px rgba(0,0,0,.3)",boxSizing:"initial",fontFamily:"Menlo"},saturation:{width:"100%",paddingBottom:"55%",position:"relative",borderRadius:"2px 2px 0 0",overflow:"hidden"},Saturation:{radius:"2px 2px 0 0"},body:{padding:"16px 16px 12px"},controls:{display:"flex"},color:{width:"32px"},swatch:{marginTop:"6px",width:"16px",height:"16px",borderRadius:"8px",position:"relative",overflow:"hidden"},active:{absolute:"0px 0px 0px 0px",borderRadius:"8px",boxShadow:"inset 0 0 0 1px rgba(0,0,0,.1)",background:"rgba("+o.r+", "+o.g+", "+o.b+", "+o.a+")",zIndex:"2"},toggles:{flex:"1"},hue:{height:"10px",position:"relative",marginBottom:"8px"},Hue:{radius:"2px"},alpha:{height:"10px",position:"relative"},Alpha:{radius:"2px"}},disableAlpha:{color:{width:"22px"},alpha:{display:"none"},hue:{marginBottom:"0px"},swatch:{width:"10px",height:"10px",marginTop:"0px"}}},f),{disableAlpha:r});return a.a.createElement("div",{style:g.picker,className:"chrome-picker "+m},a.a.createElement("div",{style:g.saturation},a.a.createElement(yn,{style:g.Saturation,hsl:s,hsv:u,pointer:Ra,onChange:n})),a.a.createElement("div",{style:g.body},a.a.createElement("div",{style:g.controls,className:"flexbox-fix"},a.a.createElement("div",{style:g.color},a.a.createElement("div",{style:g.swatch},a.a.createElement("div",{style:g.active}),a.a.createElement(p,{renderers:c}))),a.a.createElement("div",{style:g.toggles},a.a.createElement("div",{style:g.hue},a.a.createElement(x,{style:g.Hue,hsl:s,pointer:Na,onChange:n})),a.a.createElement("div",{style:g.alpha},a.a.createElement(y,{style:g.Alpha,rgb:o,hsl:s,pointer:Na,renderers:c,onChange:n})))),a.a.createElement(Ia,{rgb:o,hsl:s,hex:l,view:_,onChange:n,disableAlpha:r})))};Fa.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),disableAlpha:S.a.bool,styles:S.a.object,defaultView:S.a.oneOf(["hex","rgb","hsl"])},Fa.defaultProps={width:225,disableAlpha:!1,styles:{}};var za=Pn(Fa),Ua=function(e){var t=e.color,n=e.onClick,r=void 0===n?function(){}:n,o=e.onSwatchHover,s=e.active,u=i()({default:{color:{background:t,width:"15px",height:"15px",float:"left",marginRight:"5px",marginBottom:"5px",position:"relative",cursor:"pointer"},dot:{absolute:"5px 5px 5px 5px",background:Yn(t),borderRadius:"50%",opacity:"0"}},active:{dot:{opacity:"1"}},"color-#FFFFFF":{color:{boxShadow:"inset 0 0 0 1px #ddd"},dot:{background:"#000"}},transparent:{dot:{background:"#000"}}},{active:s,"color-#FFFFFF":"#FFFFFF"===t,transparent:"transparent"===t});return a.a.createElement(Un,{style:u.color,color:t,onClick:r,onHover:o,focusStyle:{boxShadow:"0 0 4px "+t}},a.a.createElement("div",{style:u.dot}))},Wa=function(e){var t=e.hex,n=e.rgb,r=e.onChange,o=i()({default:{fields:{display:"flex",paddingBottom:"6px",paddingRight:"5px",position:"relative"},active:{position:"absolute",top:"6px",left:"5px",height:"9px",width:"9px",background:t},HEXwrap:{flex:"6",position:"relative"},HEXinput:{width:"80%",padding:"0px",paddingLeft:"20%",border:"none",outline:"none",background:"none",fontSize:"12px",color:"#333",height:"16px"},HEXlabel:{display:"none"},RGBwrap:{flex:"3",position:"relative"},RGBinput:{width:"70%",padding:"0px",paddingLeft:"30%",border:"none",outline:"none",background:"none",fontSize:"12px",color:"#333",height:"16px"},RGBlabel:{position:"absolute",top:"3px",left:"0px",lineHeight:"16px",textTransform:"uppercase",fontSize:"12px",color:"#999"}}}),s=function(e,t){e.r||e.g||e.b?r({r:e.r||n.r,g:e.g||n.g,b:e.b||n.b,source:"rgb"},t):r({hex:e.hex,source:"hex"},t)};return a.a.createElement("div",{style:o.fields,className:"flexbox-fix"},a.a.createElement("div",{style:o.active}),a.a.createElement(w,{style:{wrap:o.HEXwrap,input:o.HEXinput,label:o.HEXlabel},label:"hex",value:t,onChange:s}),a.a.createElement(w,{style:{wrap:o.RGBwrap,input:o.RGBinput,label:o.RGBlabel},label:"r",value:n.r,onChange:s}),a.a.createElement(w,{style:{wrap:o.RGBwrap,input:o.RGBinput,label:o.RGBlabel},label:"g",value:n.g,onChange:s}),a.a.createElement(w,{style:{wrap:o.RGBwrap,input:o.RGBinput,label:o.RGBlabel},label:"b",value:n.b,onChange:s}))},Ba=function(e){var t=e.onChange,n=e.onSwatchHover,r=e.colors,o=e.hex,s=e.rgb,u=e.styles,l=void 0===u?{}:u,c=e.className,d=void 0===c?"":c,p=i()(Xt({default:{Compact:{background:"#f6f6f6",radius:"4px"},compact:{paddingTop:"5px",paddingLeft:"5px",boxSizing:"initial",width:"240px"},clear:{clear:"both"}}},l)),f=function(e,n){e.hex?Dn(e.hex)&&t({hex:e.hex,source:"hex"},n):t(e,n)};return a.a.createElement(Qt,{style:p.Compact,styles:l},a.a.createElement("div",{style:p.compact,className:"compact-picker "+d},a.a.createElement("div",null,ia(r,(function(e){return a.a.createElement(Ua,{key:e,color:e,active:e.toLowerCase()===o,onClick:f,onSwatchHover:n})})),a.a.createElement("div",{style:p.clear})),a.a.createElement(Wa,{hex:o,rgb:s,onChange:f})))};Ba.propTypes={colors:S.a.arrayOf(S.a.string),styles:S.a.object},Ba.defaultProps={colors:["#4D4D4D","#999999","#FFFFFF","#F44E3B","#FE9200","#FCDC00","#DBDF00","#A4DD00","#68CCCA","#73D8FF","#AEA1FF","#FDA1FF","#333333","#808080","#cccccc","#D33115","#E27300","#FCC400","#B0BC00","#68BC00","#16A5A5","#009CE0","#7B64FF","#FA28FF","#000000","#666666","#B3B3B3","#9F0500","#C45100","#FB9E00","#808900","#194D33","#0C797D","#0062B1","#653294","#AB149E"],styles:{}};var Va=Pn(Ba),Ga=Object(o.handleHover)((function(e){var t=e.hover,n=e.color,r=e.onClick,o=e.onSwatchHover,s={position:"relative",zIndex:"2",outline:"2px solid #fff",boxShadow:"0 0 5px 2px rgba(0,0,0,0.25)"},u=i()({default:{swatch:{width:"25px",height:"25px",fontSize:"0"}},hover:{swatch:s}},{hover:t});return a.a.createElement("div",{style:u.swatch},a.a.createElement(Un,{color:n,onClick:r,onHover:o,focusStyle:s}))})),qa=function(e){var t=e.width,n=e.colors,r=e.onChange,o=e.onSwatchHover,s=e.triangle,u=e.styles,l=void 0===u?{}:u,c=e.className,d=void 0===c?"":c,p=i()(Xt({default:{card:{width:t,background:"#fff",border:"1px solid rgba(0,0,0,0.2)",boxShadow:"0 3px 12px rgba(0,0,0,0.15)",borderRadius:"4px",position:"relative",padding:"5px",display:"flex",flexWrap:"wrap"},triangle:{position:"absolute",border:"7px solid transparent",borderBottomColor:"#fff"},triangleShadow:{position:"absolute",border:"8px solid transparent",borderBottomColor:"rgba(0,0,0,0.15)"}},"hide-triangle":{triangle:{display:"none"},triangleShadow:{display:"none"}},"top-left-triangle":{triangle:{top:"-14px",left:"10px"},triangleShadow:{top:"-16px",left:"9px"}},"top-right-triangle":{triangle:{top:"-14px",right:"10px"},triangleShadow:{top:"-16px",right:"9px"}},"bottom-left-triangle":{triangle:{top:"35px",left:"10px",transform:"rotate(180deg)"},triangleShadow:{top:"37px",left:"9px",transform:"rotate(180deg)"}},"bottom-right-triangle":{triangle:{top:"35px",right:"10px",transform:"rotate(180deg)"},triangleShadow:{top:"37px",right:"9px",transform:"rotate(180deg)"}}},l),{"hide-triangle":"hide"===s,"top-left-triangle":"top-left"===s,"top-right-triangle":"top-right"===s,"bottom-left-triangle":"bottom-left"===s,"bottom-right-triangle":"bottom-right"===s}),f=function(e,t){return r({hex:e,source:"hex"},t)};return a.a.createElement("div",{style:p.card,className:"github-picker "+d},a.a.createElement("div",{style:p.triangleShadow}),a.a.createElement("div",{style:p.triangle}),ia(n,(function(e){return a.a.createElement(Ga,{color:e,key:e,onClick:f,onSwatchHover:o})})))};qa.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),colors:S.a.arrayOf(S.a.string),triangle:S.a.oneOf(["hide","top-left","top-right","bottom-left","bottom-right"]),styles:S.a.object},qa.defaultProps={width:200,colors:["#B80000","#DB3E00","#FCCB00","#008B02","#006B76","#1273DE","#004DCF","#5300EB","#EB9694","#FAD0C3","#FEF3BD","#C1E1C5","#BEDADC","#C4DEF6","#BED3F3","#D4C4FB"],triangle:"top-left",styles:{}};var Ja=Pn(qa),Ka=function(e){var t=e.direction,n=i()({default:{picker:{width:"18px",height:"18px",borderRadius:"50%",transform:"translate(-9px, -1px)",backgroundColor:"rgb(248, 248, 248)",boxShadow:"0 1px 4px 0 rgba(0, 0, 0, 0.37)"}},vertical:{picker:{transform:"translate(-3px, -9px)"}}},{vertical:"vertical"===t});return a.a.createElement("div",{style:n.picker})},$a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Xa=function(e){var t=e.width,n=e.height,r=e.onChange,o=e.hsl,s=e.direction,u=e.pointer,l=e.styles,c=void 0===l?{}:l,d=e.className,p=void 0===d?"":d,f=i()(Xt({default:{picker:{position:"relative",width:t,height:n},hue:{radius:"2px"}}},c));return a.a.createElement("div",{style:f.picker,className:"hue-picker "+p},a.a.createElement(x,$a({},f.hue,{hsl:o,pointer:u,onChange:function(e){return r({a:1,h:e.h,l:.5,s:1})},direction:s})))};Xa.propTypes={styles:S.a.object},Xa.defaultProps={width:"316px",height:"16px",direction:"horizontal",pointer:Ka,styles:{}};var Za=Pn(Xa),Qa=Pn((function(e){var t=e.onChange,n=e.hex,r=e.rgb,o=e.styles,s=void 0===o?{}:o,u=e.className,l=void 0===u?"":u,c=i()(Xt({default:{material:{width:"98px",height:"98px",padding:"16px",fontFamily:"Roboto"},HEXwrap:{position:"relative"},HEXinput:{width:"100%",marginTop:"12px",fontSize:"15px",color:"#333",padding:"0px",border:"0px",borderBottom:"2px solid "+n,outline:"none",height:"30px"},HEXlabel:{position:"absolute",top:"0px",left:"0px",fontSize:"11px",color:"#999999",textTransform:"capitalize"},Hex:{style:{}},RGBwrap:{position:"relative"},RGBinput:{width:"100%",marginTop:"12px",fontSize:"15px",color:"#333",padding:"0px",border:"0px",borderBottom:"1px solid #eee",outline:"none",height:"30px"},RGBlabel:{position:"absolute",top:"0px",left:"0px",fontSize:"11px",color:"#999999",textTransform:"capitalize"},split:{display:"flex",marginRight:"-10px",paddingTop:"11px"},third:{flex:"1",paddingRight:"10px"}}},s)),d=function(e,n){e.hex?Dn(e.hex)&&t({hex:e.hex,source:"hex"},n):(e.r||e.g||e.b)&&t({r:e.r||r.r,g:e.g||r.g,b:e.b||r.b,source:"rgb"},n)};return a.a.createElement(Qt,{styles:s},a.a.createElement("div",{style:c.material,className:"material-picker "+l},a.a.createElement(w,{style:{wrap:c.HEXwrap,input:c.HEXinput,label:c.HEXlabel},label:"hex",value:n,onChange:d}),a.a.createElement("div",{style:c.split,className:"flexbox-fix"},a.a.createElement("div",{style:c.third},a.a.createElement(w,{style:{wrap:c.RGBwrap,input:c.RGBinput,label:c.RGBlabel},label:"r",value:r.r,onChange:d})),a.a.createElement("div",{style:c.third},a.a.createElement(w,{style:{wrap:c.RGBwrap,input:c.RGBinput,label:c.RGBlabel},label:"g",value:r.g,onChange:d})),a.a.createElement("div",{style:c.third},a.a.createElement(w,{style:{wrap:c.RGBwrap,input:c.RGBinput,label:c.RGBlabel},label:"b",value:r.b,onChange:d})))))})),eo=function(e){var t=e.onChange,n=e.rgb,r=e.hsv,o=e.hex,s=i()({default:{fields:{paddingTop:"5px",paddingBottom:"9px",width:"80px",position:"relative"},divider:{height:"5px"},RGBwrap:{position:"relative"},RGBinput:{marginLeft:"40%",width:"40%",height:"18px",border:"1px solid #888888",boxShadow:"inset 0 1px 1px rgba(0,0,0,.1), 0 1px 0 0 #ECECEC",marginBottom:"5px",fontSize:"13px",paddingLeft:"3px",marginRight:"10px"},RGBlabel:{left:"0px",top:"0px",width:"34px",textTransform:"uppercase",fontSize:"13px",height:"18px",lineHeight:"22px",position:"absolute"},HEXwrap:{position:"relative"},HEXinput:{marginLeft:"20%",width:"80%",height:"18px",border:"1px solid #888888",boxShadow:"inset 0 1px 1px rgba(0,0,0,.1), 0 1px 0 0 #ECECEC",marginBottom:"6px",fontSize:"13px",paddingLeft:"3px"},HEXlabel:{position:"absolute",top:"0px",left:"0px",width:"14px",textTransform:"uppercase",fontSize:"13px",height:"18px",lineHeight:"22px"},fieldSymbols:{position:"absolute",top:"5px",right:"-7px",fontSize:"13px"},symbol:{height:"20px",lineHeight:"22px",paddingBottom:"7px"}}}),u=function(e,a){e["#"]?Dn(e["#"])&&t({hex:e["#"],source:"hex"},a):e.r||e.g||e.b?t({r:e.r||n.r,g:e.g||n.g,b:e.b||n.b,source:"rgb"},a):(e.h||e.s||e.v)&&t({h:e.h||r.h,s:e.s||r.s,v:e.v||r.v,source:"hsv"},a)};return a.a.createElement("div",{style:s.fields},a.a.createElement(w,{style:{wrap:s.RGBwrap,input:s.RGBinput,label:s.RGBlabel},label:"h",value:Math.round(r.h),onChange:u}),a.a.createElement(w,{style:{wrap:s.RGBwrap,input:s.RGBinput,label:s.RGBlabel},label:"s",value:Math.round(100*r.s),onChange:u}),a.a.createElement(w,{style:{wrap:s.RGBwrap,input:s.RGBinput,label:s.RGBlabel},label:"v",value:Math.round(100*r.v),onChange:u}),a.a.createElement("div",{style:s.divider}),a.a.createElement(w,{style:{wrap:s.RGBwrap,input:s.RGBinput,label:s.RGBlabel},label:"r",value:n.r,onChange:u}),a.a.createElement(w,{style:{wrap:s.RGBwrap,input:s.RGBinput,label:s.RGBlabel},label:"g",value:n.g,onChange:u}),a.a.createElement(w,{style:{wrap:s.RGBwrap,input:s.RGBinput,label:s.RGBlabel},label:"b",value:n.b,onChange:u}),a.a.createElement("div",{style:s.divider}),a.a.createElement(w,{style:{wrap:s.HEXwrap,input:s.HEXinput,label:s.HEXlabel},label:"#",value:o.replace("#",""),onChange:u}),a.a.createElement("div",{style:s.fieldSymbols},a.a.createElement("div",{style:s.symbol},"°"),a.a.createElement("div",{style:s.symbol},"%"),a.a.createElement("div",{style:s.symbol},"%")))},to=function(e){var t=e.hsl,n=i()({default:{picker:{width:"12px",height:"12px",borderRadius:"6px",boxShadow:"inset 0 0 0 1px #fff",transform:"translate(-6px, -6px)"}},"black-outline":{picker:{boxShadow:"inset 0 0 0 1px #000"}}},{"black-outline":t.l>.5});return a.a.createElement("div",{style:n.picker})},no=function(){var e=i()({default:{triangle:{width:0,height:0,borderStyle:"solid",borderWidth:"4px 0 4px 6px",borderColor:"transparent transparent transparent #fff",position:"absolute",top:"1px",left:"1px"},triangleBorder:{width:0,height:0,borderStyle:"solid",borderWidth:"5px 0 5px 8px",borderColor:"transparent transparent transparent #555"},left:{Extend:"triangleBorder",transform:"translate(-13px, -4px)"},leftInside:{Extend:"triangle",transform:"translate(-8px, -5px)"},right:{Extend:"triangleBorder",transform:"translate(20px, -14px) rotate(180deg)"},rightInside:{Extend:"triangle",transform:"translate(-8px, -5px)"}}});return a.a.createElement("div",{style:e.pointer},a.a.createElement("div",{style:e.left},a.a.createElement("div",{style:e.leftInside})),a.a.createElement("div",{style:e.right},a.a.createElement("div",{style:e.rightInside})))},ro=function(e){var t=e.onClick,n=e.label,r=e.children,o=e.active,s=i()({default:{button:{backgroundImage:"linear-gradient(-180deg, #FFFFFF 0%, #E6E6E6 100%)",border:"1px solid #878787",borderRadius:"2px",height:"20px",boxShadow:"0 1px 0 0 #EAEAEA",fontSize:"14px",color:"#000",lineHeight:"20px",textAlign:"center",marginBottom:"10px",cursor:"pointer"}},active:{button:{boxShadow:"0 0 0 1px #878787"}}},{active:o});return a.a.createElement("div",{style:s.button,onClick:t},n||r)},ao=function(e){var t=e.rgb,n=e.currentColor,r=i()({default:{swatches:{border:"1px solid #B3B3B3",borderBottom:"1px solid #F0F0F0",marginBottom:"2px",marginTop:"1px"},new:{height:"34px",background:"rgb("+t.r+","+t.g+", "+t.b+")",boxShadow:"inset 1px 0 0 #000, inset -1px 0 0 #000, inset 0 1px 0 #000"},current:{height:"34px",background:n,boxShadow:"inset 1px 0 0 #000, inset -1px 0 0 #000, inset 0 -1px 0 #000"},label:{fontSize:"14px",color:"#000",textAlign:"center"}}});return a.a.createElement("div",null,a.a.createElement("div",{style:r.label},"new"),a.a.createElement("div",{style:r.swatches},a.a.createElement("div",{style:r.new}),a.a.createElement("div",{style:r.current})),a.a.createElement("div",{style:r.label},"current"))},oo=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var io=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return n.state={currentColor:e.hex},n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),oo(t,[{key:"render",value:function(){var e=this.props,t=e.styles,n=void 0===t?{}:t,r=e.className,o=void 0===r?"":r,s=i()(Xt({default:{picker:{background:"#DCDCDC",borderRadius:"4px",boxShadow:"0 0 0 1px rgba(0,0,0,.25), 0 8px 16px rgba(0,0,0,.15)",boxSizing:"initial",width:"513px"},head:{backgroundImage:"linear-gradient(-180deg, #F0F0F0 0%, #D4D4D4 100%)",borderBottom:"1px solid #B1B1B1",boxShadow:"inset 0 1px 0 0 rgba(255,255,255,.2), inset 0 -1px 0 0 rgba(0,0,0,.02)",height:"23px",lineHeight:"24px",borderRadius:"4px 4px 0 0",fontSize:"13px",color:"#4D4D4D",textAlign:"center"},body:{padding:"15px 15px 0",display:"flex"},saturation:{width:"256px",height:"256px",position:"relative",border:"2px solid #B3B3B3",borderBottom:"2px solid #F0F0F0",overflow:"hidden"},hue:{position:"relative",height:"256px",width:"19px",marginLeft:"10px",border:"2px solid #B3B3B3",borderBottom:"2px solid #F0F0F0"},controls:{width:"180px",marginLeft:"10px"},top:{display:"flex"},previews:{width:"60px"},actions:{flex:"1",marginLeft:"20px"}}},n));return a.a.createElement("div",{style:s.picker,className:"photoshop-picker "+o},a.a.createElement("div",{style:s.head},this.props.header),a.a.createElement("div",{style:s.body,className:"flexbox-fix"},a.a.createElement("div",{style:s.saturation},a.a.createElement(yn,{hsl:this.props.hsl,hsv:this.props.hsv,pointer:to,onChange:this.props.onChange})),a.a.createElement("div",{style:s.hue},a.a.createElement(x,{direction:"vertical",hsl:this.props.hsl,pointer:no,onChange:this.props.onChange})),a.a.createElement("div",{style:s.controls},a.a.createElement("div",{style:s.top,className:"flexbox-fix"},a.a.createElement("div",{style:s.previews},a.a.createElement(ao,{rgb:this.props.rgb,currentColor:this.state.currentColor})),a.a.createElement("div",{style:s.actions},a.a.createElement(ro,{label:"OK",onClick:this.props.onAccept,active:!0}),a.a.createElement(ro,{label:"Cancel",onClick:this.props.onCancel}),a.a.createElement(eo,{onChange:this.props.onChange,rgb:this.props.rgb,hsv:this.props.hsv,hex:this.props.hex}))))))}}]),t}(a.a.Component);io.propTypes={header:S.a.string,styles:S.a.object},io.defaultProps={header:"Color Picker",styles:{}};var so=Pn(io),uo=function(e){var t=e.onChange,n=e.rgb,r=e.hsl,o=e.hex,s=e.disableAlpha,u=i()({default:{fields:{display:"flex",paddingTop:"4px"},single:{flex:"1",paddingLeft:"6px"},alpha:{flex:"1",paddingLeft:"6px"},double:{flex:"2"},input:{width:"80%",padding:"4px 10% 3px",border:"none",boxShadow:"inset 0 0 0 1px #ccc",fontSize:"11px"},label:{display:"block",textAlign:"center",fontSize:"11px",color:"#222",paddingTop:"3px",paddingBottom:"4px",textTransform:"capitalize"}},disableAlpha:{alpha:{display:"none"}}},{disableAlpha:s}),l=function(e,a){e.hex?Dn(e.hex)&&t({hex:e.hex,source:"hex"},a):e.r||e.g||e.b?t({r:e.r||n.r,g:e.g||n.g,b:e.b||n.b,a:n.a,source:"rgb"},a):e.a&&(e.a<0?e.a=0:e.a>100&&(e.a=100),e.a/=100,t({h:r.h,s:r.s,l:r.l,a:e.a,source:"rgb"},a))};return a.a.createElement("div",{style:u.fields,className:"flexbox-fix"},a.a.createElement("div",{style:u.double},a.a.createElement(w,{style:{input:u.input,label:u.label},label:"hex",value:o.replace("#",""),onChange:l})),a.a.createElement("div",{style:u.single},a.a.createElement(w,{style:{input:u.input,label:u.label},label:"r",value:n.r,onChange:l,dragLabel:"true",dragMax:"255"})),a.a.createElement("div",{style:u.single},a.a.createElement(w,{style:{input:u.input,label:u.label},label:"g",value:n.g,onChange:l,dragLabel:"true",dragMax:"255"})),a.a.createElement("div",{style:u.single},a.a.createElement(w,{style:{input:u.input,label:u.label},label:"b",value:n.b,onChange:l,dragLabel:"true",dragMax:"255"})),a.a.createElement("div",{style:u.alpha},a.a.createElement(w,{style:{input:u.input,label:u.label},label:"a",value:Math.round(100*n.a),onChange:l,dragLabel:"true",dragMax:"100"})))},lo=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},co=function(e){var t=e.colors,n=e.onClick,r=void 0===n?function(){}:n,o=e.onSwatchHover,s=i()({default:{colors:{margin:"0 -10px",padding:"10px 0 0 10px",borderTop:"1px solid #eee",display:"flex",flexWrap:"wrap",position:"relative"},swatchWrap:{width:"16px",height:"16px",margin:"0 10px 10px 0"},swatch:{borderRadius:"3px",boxShadow:"inset 0 0 0 1px rgba(0,0,0,.15)"}},"no-presets":{colors:{display:"none"}}},{"no-presets":!t||!t.length}),u=function(e,t){r({hex:e,source:"hex"},t)};return a.a.createElement("div",{style:s.colors,className:"flexbox-fix"},t.map((function(e){var t="string"==typeof e?{color:e}:e,n=""+t.color+(t.title||"");return a.a.createElement("div",{key:n,style:s.swatchWrap},a.a.createElement(Un,lo({},t,{style:s.swatch,onClick:u,onHover:o,focusStyle:{boxShadow:"inset 0 0 0 1px rgba(0,0,0,.15), 0 0 4px "+t.color}})))})))};co.propTypes={colors:S.a.arrayOf(S.a.oneOfType([S.a.string,S.a.shape({color:S.a.string,title:S.a.string})])).isRequired};var po=co,fo=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ho=function(e){var t=e.width,n=e.rgb,r=e.hex,o=e.hsv,s=e.hsl,u=e.onChange,l=e.onSwatchHover,c=e.disableAlpha,d=e.presetColors,f=e.renderers,h=e.styles,m=void 0===h?{}:h,_=e.className,g=void 0===_?"":_,v=i()(Xt({default:fo({picker:{width:t,padding:"10px 10px 0",boxSizing:"initial",background:"#fff",borderRadius:"4px",boxShadow:"0 0 0 1px rgba(0,0,0,.15), 0 8px 16px rgba(0,0,0,.15)"},saturation:{width:"100%",paddingBottom:"75%",position:"relative",overflow:"hidden"},Saturation:{radius:"3px",shadow:"inset 0 0 0 1px rgba(0,0,0,.15), inset 0 0 4px rgba(0,0,0,.25)"},controls:{display:"flex"},sliders:{padding:"4px 0",flex:"1"},color:{width:"24px",height:"24px",position:"relative",marginTop:"4px",marginLeft:"4px",borderRadius:"3px"},activeColor:{absolute:"0px 0px 0px 0px",borderRadius:"2px",background:"rgba("+n.r+","+n.g+","+n.b+","+n.a+")",boxShadow:"inset 0 0 0 1px rgba(0,0,0,.15), inset 0 0 4px rgba(0,0,0,.25)"},hue:{position:"relative",height:"10px",overflow:"hidden"},Hue:{radius:"2px",shadow:"inset 0 0 0 1px rgba(0,0,0,.15), inset 0 0 4px rgba(0,0,0,.25)"},alpha:{position:"relative",height:"10px",marginTop:"4px",overflow:"hidden"},Alpha:{radius:"2px",shadow:"inset 0 0 0 1px rgba(0,0,0,.15), inset 0 0 4px rgba(0,0,0,.25)"}},m),disableAlpha:{color:{height:"10px"},hue:{height:"10px"},alpha:{display:"none"}}},m),{disableAlpha:c});return a.a.createElement("div",{style:v.picker,className:"sketch-picker "+g},a.a.createElement("div",{style:v.saturation},a.a.createElement(yn,{style:v.Saturation,hsl:s,hsv:o,onChange:u})),a.a.createElement("div",{style:v.controls,className:"flexbox-fix"},a.a.createElement("div",{style:v.sliders},a.a.createElement("div",{style:v.hue},a.a.createElement(x,{style:v.Hue,hsl:s,onChange:u})),a.a.createElement("div",{style:v.alpha},a.a.createElement(y,{style:v.Alpha,rgb:n,hsl:s,renderers:f,onChange:u}))),a.a.createElement("div",{style:v.color},a.a.createElement(p,null),a.a.createElement("div",{style:v.activeColor}))),a.a.createElement(uo,{rgb:n,hsl:s,hex:r,onChange:u,disableAlpha:c}),a.a.createElement(po,{colors:d,onClick:u,onSwatchHover:l}))};ho.propTypes={disableAlpha:S.a.bool,width:S.a.oneOfType([S.a.string,S.a.number]),styles:S.a.object},ho.defaultProps={disableAlpha:!1,width:200,styles:{},presetColors:["#D0021B","#F5A623","#F8E71C","#8B572A","#7ED321","#417505","#BD10E0","#9013FE","#4A90E2","#50E3C2","#B8E986","#000000","#4A4A4A","#9B9B9B","#FFFFFF"]};var mo=Pn(ho),_o=function(e){var t=e.hsl,n=e.offset,r=e.onClick,o=void 0===r?function(){}:r,s=e.active,u=e.first,l=e.last,c=i()({default:{swatch:{height:"12px",background:"hsl("+t.h+", 50%, "+100*n+"%)",cursor:"pointer"}},first:{swatch:{borderRadius:"2px 0 0 2px"}},last:{swatch:{borderRadius:"0 2px 2px 0"}},active:{swatch:{transform:"scaleY(1.8)",borderRadius:"3.6px/2px"}}},{active:s,first:u,last:l});return a.a.createElement("div",{style:c.swatch,onClick:function(e){return o({h:t.h,s:.5,l:n,source:"hsl"},e)}})},yo=function(e){var t=e.onClick,n=e.hsl,r=i()({default:{swatches:{marginTop:"20px"},swatch:{boxSizing:"border-box",width:"20%",paddingRight:"1px",float:"left"},clear:{clear:"both"}}});return a.a.createElement("div",{style:r.swatches},a.a.createElement("div",{style:r.swatch},a.a.createElement(_o,{hsl:n,offset:".80",active:Math.abs(n.l-.8)<.1&&Math.abs(n.s-.5)<.1,onClick:t,first:!0})),a.a.createElement("div",{style:r.swatch},a.a.createElement(_o,{hsl:n,offset:".65",active:Math.abs(n.l-.65)<.1&&Math.abs(n.s-.5)<.1,onClick:t})),a.a.createElement("div",{style:r.swatch},a.a.createElement(_o,{hsl:n,offset:".50",active:Math.abs(n.l-.5)<.1&&Math.abs(n.s-.5)<.1,onClick:t})),a.a.createElement("div",{style:r.swatch},a.a.createElement(_o,{hsl:n,offset:".35",active:Math.abs(n.l-.35)<.1&&Math.abs(n.s-.5)<.1,onClick:t})),a.a.createElement("div",{style:r.swatch},a.a.createElement(_o,{hsl:n,offset:".20",active:Math.abs(n.l-.2)<.1&&Math.abs(n.s-.5)<.1,onClick:t,last:!0})),a.a.createElement("div",{style:r.clear}))},go=function(){var e=i()({default:{picker:{width:"14px",height:"14px",borderRadius:"6px",transform:"translate(-7px, -1px)",backgroundColor:"rgb(248, 248, 248)",boxShadow:"0 1px 4px 0 rgba(0, 0, 0, 0.37)"}}});return a.a.createElement("div",{style:e.picker})},vo=function(e){var t=e.hsl,n=e.onChange,r=e.pointer,o=e.styles,s=void 0===o?{}:o,u=e.className,l=void 0===u?"":u,c=i()(Xt({default:{hue:{height:"12px",position:"relative"},Hue:{radius:"2px"}}},s));return a.a.createElement("div",{style:c.wrap||{},className:"slider-picker "+l},a.a.createElement("div",{style:c.hue},a.a.createElement(x,{style:c.Hue,hsl:t,pointer:r,onChange:n})),a.a.createElement("div",{style:c.swatches},a.a.createElement(yo,{hsl:t,onClick:n})))};vo.propTypes={styles:S.a.object},vo.defaultProps={pointer:go,styles:{}};var bo=Pn(vo),wo=n(277),Mo=n.n(wo),Lo=function(e){var t=e.color,n=e.onClick,r=void 0===n?function(){}:n,o=e.onSwatchHover,s=e.first,u=e.last,l=e.active,c=i()({default:{color:{width:"40px",height:"24px",cursor:"pointer",background:t,marginBottom:"1px"},check:{color:Yn(t),marginLeft:"8px",display:"none"}},first:{color:{overflow:"hidden",borderRadius:"2px 2px 0 0"}},last:{color:{overflow:"hidden",borderRadius:"0 0 2px 2px"}},active:{check:{display:"block"}},"color-#FFFFFF":{color:{boxShadow:"inset 0 0 0 1px #ddd"},check:{color:"#333"}},transparent:{check:{color:"#333"}}},{first:s,last:u,active:l,"color-#FFFFFF":"#FFFFFF"===t,transparent:"transparent"===t});return a.a.createElement(Un,{color:t,style:c.color,onClick:r,onHover:o,focusStyle:{boxShadow:"0 0 4px "+t}},a.a.createElement("div",{style:c.check},a.a.createElement(Mo.a,null)))},To=function(e){var t=e.onClick,n=e.onSwatchHover,r=e.group,o=e.active,s=i()({default:{group:{paddingBottom:"10px",width:"40px",float:"left",marginRight:"10px"}}});return a.a.createElement("div",{style:s.group},ia(r,(function(e,i){return a.a.createElement(Lo,{key:e,color:e,active:e.toLowerCase()===o,first:0===i,last:i===r.length-1,onClick:t,onSwatchHover:n})})))},ko=function(e){var t=e.width,n=e.height,r=e.onChange,o=e.onSwatchHover,s=e.colors,u=e.hex,l=e.styles,c=void 0===l?{}:l,d=e.className,p=void 0===d?"":d,f=i()(Xt({default:{picker:{width:t,height:n},overflow:{height:n,overflowY:"scroll"},body:{padding:"16px 0 6px 16px"},clear:{clear:"both"}}},c)),h=function(e,t){return r({hex:e,source:"hex"},t)};return a.a.createElement("div",{style:f.picker,className:"swatches-picker "+p},a.a.createElement(Qt,null,a.a.createElement("div",{style:f.overflow},a.a.createElement("div",{style:f.body},ia(s,(function(e){return a.a.createElement(To,{key:e.toString(),group:e,active:u,onClick:h,onSwatchHover:o})})),a.a.createElement("div",{style:f.clear})))))};ko.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),height:S.a.oneOfType([S.a.string,S.a.number]),colors:S.a.arrayOf(S.a.arrayOf(S.a.string)),styles:S.a.object},ko.defaultProps={width:320,height:240,colors:[[ca[900],ca[700],ca[500],ca[300],ca[100]],[da[900],da[700],da[500],da[300],da[100]],[pa[900],pa[700],pa[500],pa[300],pa[100]],[fa[900],fa[700],fa[500],fa[300],fa[100]],[ha[900],ha[700],ha[500],ha[300],ha[100]],[ma[900],ma[700],ma[500],ma[300],ma[100]],[_a[900],_a[700],_a[500],_a[300],_a[100]],[ya[900],ya[700],ya[500],ya[300],ya[100]],[ga[900],ga[700],ga[500],ga[300],ga[100]],["#194D33",va[700],va[500],va[300],va[100]],[ba[900],ba[700],ba[500],ba[300],ba[100]],[wa[900],wa[700],wa[500],wa[300],wa[100]],[Ma[900],Ma[700],Ma[500],Ma[300],Ma[100]],[La[900],La[700],La[500],La[300],La[100]],[Ta[900],Ta[700],Ta[500],Ta[300],Ta[100]],[ka[900],ka[700],ka[500],ka[300],ka[100]],[xa[900],xa[700],xa[500],xa[300],xa[100]],[Ea[900],Ea[700],Ea[500],Ea[300],Ea[100]],["#000000","#525252","#969696","#D9D9D9","#FFFFFF"]],styles:{}};var xo=Pn(ko),Eo=function(e){var t=e.onChange,n=e.onSwatchHover,r=e.hex,o=e.colors,s=e.width,u=e.triangle,l=e.styles,c=void 0===l?{}:l,d=e.className,p=void 0===d?"":d,f=i()(Xt({default:{card:{width:s,background:"#fff",border:"0 solid rgba(0,0,0,0.25)",boxShadow:"0 1px 4px rgba(0,0,0,0.25)",borderRadius:"4px",position:"relative"},body:{padding:"15px 9px 9px 15px"},label:{fontSize:"18px",color:"#fff"},triangle:{width:"0px",height:"0px",borderStyle:"solid",borderWidth:"0 9px 10px 9px",borderColor:"transparent transparent #fff transparent",position:"absolute"},triangleShadow:{width:"0px",height:"0px",borderStyle:"solid",borderWidth:"0 9px 10px 9px",borderColor:"transparent transparent rgba(0,0,0,.1) transparent",position:"absolute"},hash:{background:"#F0F0F0",height:"30px",width:"30px",borderRadius:"4px 0 0 4px",float:"left",color:"#98A1A4",display:"flex",alignItems:"center",justifyContent:"center"},input:{width:"100px",fontSize:"14px",color:"#666",border:"0px",outline:"none",height:"28px",boxShadow:"inset 0 0 0 1px #F0F0F0",boxSizing:"content-box",borderRadius:"0 4px 4px 0",float:"left",paddingLeft:"8px"},swatch:{width:"30px",height:"30px",float:"left",borderRadius:"4px",margin:"0 6px 6px 0"},clear:{clear:"both"}},"hide-triangle":{triangle:{display:"none"},triangleShadow:{display:"none"}},"top-left-triangle":{triangle:{top:"-10px",left:"12px"},triangleShadow:{top:"-11px",left:"12px"}},"top-right-triangle":{triangle:{top:"-10px",right:"12px"},triangleShadow:{top:"-11px",right:"12px"}}},c),{"hide-triangle":"hide"===u,"top-left-triangle":"top-left"===u,"top-right-triangle":"top-right"===u}),h=function(e,n){Dn(e)&&t({hex:e,source:"hex"},n)};return a.a.createElement("div",{style:f.card,className:"twitter-picker "+p},a.a.createElement("div",{style:f.triangleShadow}),a.a.createElement("div",{style:f.triangle}),a.a.createElement("div",{style:f.body},ia(o,(function(e,t){return a.a.createElement(Un,{key:t,color:e,hex:e,style:f.swatch,onClick:h,onHover:n,focusStyle:{boxShadow:"0 0 4px "+e}})})),a.a.createElement("div",{style:f.hash},"#"),a.a.createElement(w,{label:null,style:{input:f.input},value:r.replace("#",""),onChange:h}),a.a.createElement("div",{style:f.clear})))};Eo.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),triangle:S.a.oneOf(["hide","top-left","top-right"]),colors:S.a.arrayOf(S.a.string),styles:S.a.object},Eo.defaultProps={width:276,colors:["#FF6900","#FCB900","#7BDCB5","#00D084","#8ED1FC","#0693E3","#ABB8C3","#EB144C","#F78DA7","#9900EF"],triangle:"top-left",styles:{}};var So=Pn(Eo),Oo=function(e){var t=i()({default:{picker:{width:"20px",height:"20px",borderRadius:"22px",border:"2px #fff solid",transform:"translate(-12px, -13px)",background:"hsl("+Math.round(e.hsl.h)+", "+Math.round(100*e.hsl.s)+"%, "+Math.round(100*e.hsl.l)+"%)"}}});return a.a.createElement("div",{style:t.picker})};Oo.propTypes={hsl:S.a.shape({h:S.a.number,s:S.a.number,l:S.a.number,a:S.a.number})},Oo.defaultProps={hsl:{a:1,h:249.94,l:.2,s:.5}};var Do=Oo,Yo=function(e){var t=i()({default:{picker:{width:"20px",height:"20px",borderRadius:"22px",transform:"translate(-10px, -7px)",background:"hsl("+Math.round(e.hsl.h)+", 100%, 50%)",border:"2px white solid"}}});return a.a.createElement("div",{style:t.picker})};Yo.propTypes={hsl:S.a.shape({h:S.a.number,s:S.a.number,l:S.a.number,a:S.a.number})},Yo.defaultProps={hsl:{a:1,h:249.94,l:.2,s:.5}};var Ao=Yo,Co=function(e){var t=e.onChange,n=e.rgb,r=e.hsl,o=e.hex,s=e.hsv,u=function(e,n){if(e.hex)Dn(e.hex)&&t({hex:e.hex,source:"hex"},n);else if(e.rgb){var r=e.rgb.split(",");An(e.rgb,"rgb")&&t({r:r[0],g:r[1],b:r[2],a:1,source:"rgb"},n)}else if(e.hsv){var a=e.hsv.split(",");An(e.hsv,"hsv")&&(a[2]=a[2].replace("%",""),a[1]=a[1].replace("%",""),a[0]=a[0].replace("°",""),1==a[1]?a[1]=.01:1==a[2]&&(a[2]=.01),t({h:Number(a[0]),s:Number(a[1]),v:Number(a[2]),source:"hsv"},n))}else if(e.hsl){var o=e.hsl.split(",");An(e.hsl,"hsl")&&(o[2]=o[2].replace("%",""),o[1]=o[1].replace("%",""),o[0]=o[0].replace("°",""),1==p[1]?p[1]=.01:1==p[2]&&(p[2]=.01),t({h:Number(o[0]),s:Number(o[1]),v:Number(o[2]),source:"hsl"},n))}},l=i()({default:{wrap:{display:"flex",height:"100px",marginTop:"4px"},fields:{width:"100%"},column:{paddingTop:"10px",display:"flex",justifyContent:"space-between"},double:{padding:"0px 4.4px",boxSizing:"border-box"},input:{width:"100%",height:"38px",boxSizing:"border-box",padding:"4px 10% 3px",textAlign:"center",border:"1px solid #dadce0",fontSize:"11px",textTransform:"lowercase",borderRadius:"5px",outline:"none",fontFamily:"Roboto,Arial,sans-serif"},input2:{height:"38px",width:"100%",border:"1px solid #dadce0",boxSizing:"border-box",fontSize:"11px",textTransform:"lowercase",borderRadius:"5px",outline:"none",paddingLeft:"10px",fontFamily:"Roboto,Arial,sans-serif"},label:{textAlign:"center",fontSize:"12px",background:"#fff",position:"absolute",textTransform:"uppercase",color:"#3c4043",width:"35px",top:"-6px",left:"0",right:"0",marginLeft:"auto",marginRight:"auto",fontFamily:"Roboto,Arial,sans-serif"},label2:{left:"10px",textAlign:"center",fontSize:"12px",background:"#fff",position:"absolute",textTransform:"uppercase",color:"#3c4043",width:"32px",top:"-6px",fontFamily:"Roboto,Arial,sans-serif"},single:{flexGrow:"1",margin:"0px 4.4px"}}}),c=n.r+", "+n.g+", "+n.b,d=Math.round(r.h)+"°, "+Math.round(100*r.s)+"%, "+Math.round(100*r.l)+"%",p=Math.round(s.h)+"°, "+Math.round(100*s.s)+"%, "+Math.round(100*s.v)+"%";return a.a.createElement("div",{style:l.wrap,className:"flexbox-fix"},a.a.createElement("div",{style:l.fields},a.a.createElement("div",{style:l.double},a.a.createElement(w,{style:{input:l.input,label:l.label},label:"hex",value:o,onChange:u})),a.a.createElement("div",{style:l.column},a.a.createElement("div",{style:l.single},a.a.createElement(w,{style:{input:l.input2,label:l.label2},label:"rgb",value:c,onChange:u})),a.a.createElement("div",{style:l.single},a.a.createElement(w,{style:{input:l.input2,label:l.label2},label:"hsv",value:p,onChange:u})),a.a.createElement("div",{style:l.single},a.a.createElement(w,{style:{input:l.input2,label:l.label2},label:"hsl",value:d,onChange:u})))))},jo=function(e){var t=e.width,n=e.onChange,r=e.rgb,o=e.hsl,s=e.hsv,u=e.hex,l=e.header,c=e.styles,d=void 0===c?{}:c,p=e.className,f=void 0===p?"":p,h=i()(Xt({default:{picker:{width:t,background:"#fff",border:"1px solid #dfe1e5",boxSizing:"initial",display:"flex",flexWrap:"wrap",borderRadius:"8px 8px 0px 0px"},head:{height:"57px",width:"100%",paddingTop:"16px",paddingBottom:"16px",paddingLeft:"16px",fontSize:"20px",boxSizing:"border-box",fontFamily:"Roboto-Regular,HelveticaNeue,Arial,sans-serif"},saturation:{width:"70%",padding:"0px",position:"relative",overflow:"hidden"},swatch:{width:"30%",height:"228px",padding:"0px",background:"rgba("+r.r+", "+r.g+", "+r.b+", 1)",position:"relative",overflow:"hidden"},body:{margin:"auto",width:"95%"},controls:{display:"flex",boxSizing:"border-box",height:"52px",paddingTop:"22px"},color:{width:"32px"},hue:{height:"8px",position:"relative",margin:"0px 16px 0px 16px",width:"100%"},Hue:{radius:"2px"}}},d));return a.a.createElement("div",{style:h.picker,className:"google-picker "+f},a.a.createElement("div",{style:h.head},l),a.a.createElement("div",{style:h.swatch}),a.a.createElement("div",{style:h.saturation},a.a.createElement(yn,{hsl:o,hsv:s,pointer:Do,onChange:n})),a.a.createElement("div",{style:h.body},a.a.createElement("div",{style:h.controls,className:"flexbox-fix"},a.a.createElement("div",{style:h.hue},a.a.createElement(x,{style:h.Hue,hsl:o,radius:"4px",pointer:Ao,onChange:n}))),a.a.createElement(Co,{rgb:r,hsl:o,hex:u,hsv:s,onChange:n})))};jo.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),styles:S.a.object,header:S.a.string},jo.defaultProps={width:652,styles:{},header:"Color picker"};var Po=Pn(jo)},function(e,t,n){"use strict";function r(e,t){return(r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}n.r(t),n.d(t,"CacheProvider",(function(){return S})),n.d(t,"ThemeContext",(function(){return E})),n.d(t,"withEmotionCache",(function(){return O})),n.d(t,"css",(function(){return j})),n.d(t,"ClassNames",(function(){return z})),n.d(t,"Global",(function(){return H})),n.d(t,"createElement",(function(){return P})),n.d(t,"jsx",(function(){return P})),n.d(t,"keyframes",(function(){return N}));var a=n(0);var o=function(){function e(e){this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.before=null}var t=e.prototype;return t.insert=function(e){if(this.ctr%(this.isSpeedy?65e3:1)==0){var t,n=function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t}(this);t=0===this.tags.length?this.before:this.tags[this.tags.length-1].nextSibling,this.container.insertBefore(n,t),this.tags.push(n)}var r=this.tags[this.tags.length-1];if(this.isSpeedy){var a=function(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}(r);try{var o=105===e.charCodeAt(1)&&64===e.charCodeAt(0);a.insertRule(e,o?0:a.cssRules.length)}catch(e){0}}else r.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach((function(e){return e.parentNode.removeChild(e)})),this.tags=[],this.ctr=0},e}();var i=function(e){function t(e,t,r){var a=t.trim().split(h);t=a;var o=a.length,i=e.length;switch(i){case 0:case 1:var s=0;for(e=0===i?"":e[0]+" ";s<o;++s)t[s]=n(e,t[s],r).trim();break;default:var u=s=0;for(t=[];s<o;++s)for(var l=0;l<i;++l)t[u++]=n(e[l]+" ",a[s],r).trim()}return t}function n(e,t,n){var r=t.charCodeAt(0);switch(33>r&&(r=(t=t.trim()).charCodeAt(0)),r){case 38:return t.replace(m,"$1"+e.trim());case 58:return e.trim()+t.replace(m,"$1"+e.trim());default:if(0<1*n&&0<t.indexOf("\f"))return t.replace(m,(58===e.charCodeAt(0)?"":"$1")+e.trim())}return e+t}function r(e,t,n,o){var i=e+";",s=2*t+3*n+4*o;if(944===s){e=i.indexOf(":",9)+1;var u=i.substring(e,i.length-1).trim();return u=i.substring(0,e).trim()+u+";",1===O||2===O&&a(u,1)?"-webkit-"+u+u:u}if(0===O||2===O&&!a(i,1))return i;switch(s){case 1015:return 97===i.charCodeAt(10)?"-webkit-"+i+i:i;case 951:return 116===i.charCodeAt(3)?"-webkit-"+i+i:i;case 963:return 110===i.charCodeAt(5)?"-webkit-"+i+i:i;case 1009:if(100!==i.charCodeAt(4))break;case 969:case 942:return"-webkit-"+i+i;case 978:return"-webkit-"+i+"-moz-"+i+i;case 1019:case 983:return"-webkit-"+i+"-moz-"+i+"-ms-"+i+i;case 883:if(45===i.charCodeAt(8))return"-webkit-"+i+i;if(0<i.indexOf("image-set(",11))return i.replace(k,"$1-webkit-$2")+i;break;case 932:if(45===i.charCodeAt(4))switch(i.charCodeAt(5)){case 103:return"-webkit-box-"+i.replace("-grow","")+"-webkit-"+i+"-ms-"+i.replace("grow","positive")+i;case 115:return"-webkit-"+i+"-ms-"+i.replace("shrink","negative")+i;case 98:return"-webkit-"+i+"-ms-"+i.replace("basis","preferred-size")+i}return"-webkit-"+i+"-ms-"+i+i;case 964:return"-webkit-"+i+"-ms-flex-"+i+i;case 1023:if(99!==i.charCodeAt(8))break;return"-webkit-box-pack"+(u=i.substring(i.indexOf(":",15)).replace("flex-","").replace("space-between","justify"))+"-webkit-"+i+"-ms-flex-pack"+u+i;case 1005:return p.test(i)?i.replace(d,":-webkit-")+i.replace(d,":-moz-")+i:i;case 1e3:switch(t=(u=i.substring(13).trim()).indexOf("-")+1,u.charCodeAt(0)+u.charCodeAt(t)){case 226:u=i.replace(v,"tb");break;case 232:u=i.replace(v,"tb-rl");break;case 220:u=i.replace(v,"lr");break;default:return i}return"-webkit-"+i+"-ms-"+u+i;case 1017:if(-1===i.indexOf("sticky",9))break;case 975:switch(t=(i=e).length-10,s=(u=(33===i.charCodeAt(t)?i.substring(0,t):i).substring(e.indexOf(":",7)+1).trim()).charCodeAt(0)+(0|u.charCodeAt(7))){case 203:if(111>u.charCodeAt(8))break;case 115:i=i.replace(u,"-webkit-"+u)+";"+i;break;case 207:case 102:i=i.replace(u,"-webkit-"+(102<s?"inline-":"")+"box")+";"+i.replace(u,"-webkit-"+u)+";"+i.replace(u,"-ms-"+u+"box")+";"+i}return i+";";case 938:if(45===i.charCodeAt(5))switch(i.charCodeAt(6)){case 105:return u=i.replace("-items",""),"-webkit-"+i+"-webkit-box-"+u+"-ms-flex-"+u+i;case 115:return"-webkit-"+i+"-ms-flex-item-"+i.replace(M,"")+i;default:return"-webkit-"+i+"-ms-flex-line-pack"+i.replace("align-content","").replace(M,"")+i}break;case 973:case 989:if(45!==i.charCodeAt(3)||122===i.charCodeAt(4))break;case 931:case 953:if(!0===T.test(e))return 115===(u=e.substring(e.indexOf(":")+1)).charCodeAt(0)?r(e.replace("stretch","fill-available"),t,n,o).replace(":fill-available",":stretch"):i.replace(u,"-webkit-"+u)+i.replace(u,"-moz-"+u.replace("fill-",""))+i;break;case 962:if(i="-webkit-"+i+(102===i.charCodeAt(5)?"-ms-"+i:"")+i,211===n+o&&105===i.charCodeAt(13)&&0<i.indexOf("transform",10))return i.substring(0,i.indexOf(";",27)+1).replace(f,"$1-webkit-$2")+i}return i}function a(e,t){var n=e.indexOf(1===t?":":"{"),r=e.substring(0,3!==t?n:10);return n=e.substring(n+1,e.length-1),C(2!==t?r:r.replace(L,"$1"),n,t)}function o(e,t){var n=r(t,t.charCodeAt(0),t.charCodeAt(1),t.charCodeAt(2));return n!==t+";"?n.replace(w," or ($1)").substring(4):"("+t+")"}function i(e,t,n,r,a,o,i,s,l,c){for(var d,p=0,f=t;p<A;++p)switch(d=Y[p].call(u,e,f,n,r,a,o,i,s,l,c)){case void 0:case!1:case!0:case null:break;default:f=d}if(f!==t)return f}function s(e){return void 0!==(e=e.prefix)&&(C=null,e?"function"!=typeof e?O=1:(O=2,C=e):O=0),s}function u(e,n){var s=e;if(33>s.charCodeAt(0)&&(s=s.trim()),s=[s],0<A){var u=i(-1,n,s,s,E,x,0,0,0,0);void 0!==u&&"string"==typeof u&&(n=u)}var d=function e(n,s,u,d,p){for(var f,h,m,v,w,M=0,L=0,T=0,k=0,Y=0,C=0,P=m=f=0,H=0,I=0,N=0,R=0,F=u.length,z=F-1,U="",W="",B="",V="";H<F;){if(h=u.charCodeAt(H),H===z&&0!==L+k+T+M&&(0!==L&&(h=47===L?10:47),k=T=M=0,F++,z++),0===L+k+T+M){if(H===z&&(0<I&&(U=U.replace(c,"")),0<U.trim().length)){switch(h){case 32:case 9:case 59:case 13:case 10:break;default:U+=u.charAt(H)}h=59}switch(h){case 123:for(f=(U=U.trim()).charCodeAt(0),m=1,R=++H;H<F;){switch(h=u.charCodeAt(H)){case 123:m++;break;case 125:m--;break;case 47:switch(h=u.charCodeAt(H+1)){case 42:case 47:e:{for(P=H+1;P<z;++P)switch(u.charCodeAt(P)){case 47:if(42===h&&42===u.charCodeAt(P-1)&&H+2!==P){H=P+1;break e}break;case 10:if(47===h){H=P+1;break e}}H=P}}break;case 91:h++;case 40:h++;case 34:case 39:for(;H++<z&&u.charCodeAt(H)!==h;);}if(0===m)break;H++}switch(m=u.substring(R,H),0===f&&(f=(U=U.replace(l,"").trim()).charCodeAt(0)),f){case 64:switch(0<I&&(U=U.replace(c,"")),h=U.charCodeAt(1)){case 100:case 109:case 115:case 45:I=s;break;default:I=D}if(R=(m=e(s,I,m,h,p+1)).length,0<A&&(w=i(3,m,I=t(D,U,N),s,E,x,R,h,p,d),U=I.join(""),void 0!==w&&0===(R=(m=w.trim()).length)&&(h=0,m="")),0<R)switch(h){case 115:U=U.replace(b,o);case 100:case 109:case 45:m=U+"{"+m+"}";break;case 107:m=(U=U.replace(_,"$1 $2"))+"{"+m+"}",m=1===O||2===O&&a("@"+m,3)?"@-webkit-"+m+"@"+m:"@"+m;break;default:m=U+m,112===d&&(W+=m,m="")}else m="";break;default:m=e(s,t(s,U,N),m,d,p+1)}B+=m,m=N=I=P=f=0,U="",h=u.charCodeAt(++H);break;case 125:case 59:if(1<(R=(U=(0<I?U.replace(c,""):U).trim()).length))switch(0===P&&(f=U.charCodeAt(0),45===f||96<f&&123>f)&&(R=(U=U.replace(" ",":")).length),0<A&&void 0!==(w=i(1,U,s,n,E,x,W.length,d,p,d))&&0===(R=(U=w.trim()).length)&&(U="\0\0"),f=U.charCodeAt(0),h=U.charCodeAt(1),f){case 0:break;case 64:if(105===h||99===h){V+=U+u.charAt(H);break}default:58!==U.charCodeAt(R-1)&&(W+=r(U,f,h,U.charCodeAt(2)))}N=I=P=f=0,U="",h=u.charCodeAt(++H)}}switch(h){case 13:case 10:47===L?L=0:0===1+f&&107!==d&&0<U.length&&(I=1,U+="\0"),0<A*j&&i(0,U,s,n,E,x,W.length,d,p,d),x=1,E++;break;case 59:case 125:if(0===L+k+T+M){x++;break}default:switch(x++,v=u.charAt(H),h){case 9:case 32:if(0===k+M+L)switch(Y){case 44:case 58:case 9:case 32:v="";break;default:32!==h&&(v=" ")}break;case 0:v="\\0";break;case 12:v="\\f";break;case 11:v="\\v";break;case 38:0===k+L+M&&(I=N=1,v="\f"+v);break;case 108:if(0===k+L+M+S&&0<P)switch(H-P){case 2:112===Y&&58===u.charCodeAt(H-3)&&(S=Y);case 8:111===C&&(S=C)}break;case 58:0===k+L+M&&(P=H);break;case 44:0===L+T+k+M&&(I=1,v+="\r");break;case 34:case 39:0===L&&(k=k===h?0:0===k?h:k);break;case 91:0===k+L+T&&M++;break;case 93:0===k+L+T&&M--;break;case 41:0===k+L+M&&T--;break;case 40:if(0===k+L+M){if(0===f)switch(2*Y+3*C){case 533:break;default:f=1}T++}break;case 64:0===L+T+k+M+P+m&&(m=1);break;case 42:case 47:if(!(0<k+M+T))switch(L){case 0:switch(2*h+3*u.charCodeAt(H+1)){case 235:L=47;break;case 220:R=H,L=42}break;case 42:47===h&&42===Y&&R+2!==H&&(33===u.charCodeAt(R+2)&&(W+=u.substring(R,H+1)),v="",L=0)}}0===L&&(U+=v)}C=Y,Y=h,H++}if(0<(R=W.length)){if(I=s,0<A&&(void 0!==(w=i(2,W,I,n,E,x,R,d,p,d))&&0===(W=w).length))return V+W+B;if(W=I.join(",")+"{"+W+"}",0!=O*S){switch(2!==O||a(W,2)||(S=0),S){case 111:W=W.replace(g,":-moz-$1")+W;break;case 112:W=W.replace(y,"::-webkit-input-$1")+W.replace(y,"::-moz-$1")+W.replace(y,":-ms-input-$1")+W}S=0}}return V+W+B}(D,s,n,0,0);return 0<A&&(void 0!==(u=i(-2,d,s,s,E,x,d.length,0,0,0))&&(d=u)),"",S=0,x=E=1,d}var l=/^\0+/g,c=/[\0\r\f]/g,d=/: */g,p=/zoo|gra/,f=/([,: ])(transform)/g,h=/,\r+?/g,m=/([\t\r\n ])*\f?&/g,_=/@(k\w+)\s*(\S*)\s*/,y=/::(place)/g,g=/:(read-only)/g,v=/[svh]\w+-[tblr]{2}/,b=/\(\s*(.*)\s*\)/g,w=/([\s\S]*?);/g,M=/-self|flex-/g,L=/[^]*?(:[rp][el]a[\w-]+)[^]*/,T=/stretch|:\s*\w+\-(?:conte|avail)/,k=/([^-])(image-set\()/,x=1,E=1,S=0,O=1,D=[],Y=[],A=0,C=null,j=0;return u.use=function e(t){switch(t){case void 0:case null:A=Y.length=0;break;default:if("function"==typeof t)Y[A++]=t;else if("object"==typeof t)for(var n=0,r=t.length;n<r;++n)e(t[n]);else j=0|!!t}return e},u.set=s,void 0!==e&&s(e),u};function s(e){e&&u.current.insert(e+"}")}var u={current:null},l=function(e,t,n,r,a,o,i,l,c,d){switch(e){case 1:switch(t.charCodeAt(0)){case 64:return u.current.insert(t+";"),"";case 108:if(98===t.charCodeAt(2))return""}break;case 2:if(0===l)return t+"/*|*/";break;case 3:switch(l){case 102:case 112:return u.current.insert(n[0]+t),"";default:return t+(0===d?"/*|*/":"")}case-2:t.split("/*|*/}").forEach(s)}},c=function(e){void 0===e&&(e={});var t,n=e.key||"css";void 0!==e.prefix&&(t={prefix:e.prefix});var r=new i(t);var a,s={};a=e.container||document.head;var c,d=document.querySelectorAll("style[data-emotion-"+n+"]");Array.prototype.forEach.call(d,(function(e){e.getAttribute("data-emotion-"+n).split(" ").forEach((function(e){s[e]=!0})),e.parentNode!==a&&a.appendChild(e)})),r.use(e.stylisPlugins)(l),c=function(e,t,n,a){var o=t.name;u.current=n,r(e,t.styles),a&&(p.inserted[o]=!0)};var p={key:n,sheet:new o({key:n,container:a,nonce:e.nonce,speedy:e.speedy}),nonce:e.nonce,inserted:s,registered:{},insert:c};return p};n(348);function d(e,t,n){var r="";return n.split(" ").forEach((function(n){void 0!==e[n]?t.push(e[n]):r+=n+" "})),r}var p=function(e,t,n){var r=e.key+"-"+t.name;if(!1===n&&void 0===e.registered[r]&&(e.registered[r]=t.styles),void 0===e.inserted[t.name]){var a=t;do{e.insert("."+r,a,e.sheet,!0);a=a.next}while(void 0!==a)}};var f=function(e){for(var t,n=0,r=0,a=e.length;a>=4;++r,a-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(a){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)},h={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};var m=/[A-Z]|^ms/g,_=/_EMO_([^_]+?)_([^]*?)_EMO_/g,y=function(e){return 45===e.charCodeAt(1)},g=function(e){return null!=e&&"boolean"!=typeof e},v=function(e){var t={};return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}}((function(e){return y(e)?e:e.replace(m,"-$&").toLowerCase()})),b=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(_,(function(e,t,n){return M={name:t,styles:n,next:M},t}))}return 1===h[e]||y(e)||"number"!=typeof t||0===t?t:t+"px"};function w(e,t,n,r){if(null==n)return"";if(void 0!==n.__emotion_styles)return n;switch(typeof n){case"boolean":return"";case"object":if(1===n.anim)return M={name:n.name,styles:n.styles,next:M},n.name;if(void 0!==n.styles){var a=n.next;if(void 0!==a)for(;void 0!==a;)M={name:a.name,styles:a.styles,next:M},a=a.next;return n.styles+";"}return function(e,t,n){var r="";if(Array.isArray(n))for(var a=0;a<n.length;a++)r+=w(e,t,n[a],!1);else for(var o in n){var i=n[o];if("object"!=typeof i)null!=t&&void 0!==t[i]?r+=o+"{"+t[i]+"}":g(i)&&(r+=v(o)+":"+b(o,i)+";");else if(!Array.isArray(i)||"string"!=typeof i[0]||null!=t&&void 0!==t[i[0]]){var s=w(e,t,i,!1);switch(o){case"animation":case"animationName":r+=v(o)+":"+s+";";break;default:r+=o+"{"+s+"}"}}else for(var u=0;u<i.length;u++)g(i[u])&&(r+=v(o)+":"+b(o,i[u])+";")}return r}(e,t,n);case"function":if(void 0!==e){var o=M,i=n(e);return M=o,w(e,t,i,r)}break;case"string":}if(null==t)return n;var s=t[n];return void 0===s||r?n:s}var M,L=/label:\s*([^\s;\n{]+)\s*;/g;var T=function(e,t,n){if(1===e.length&&"object"==typeof e[0]&&null!==e[0]&&void 0!==e[0].styles)return e[0];var r=!0,a="";M=void 0;var o=e[0];null==o||void 0===o.raw?(r=!1,a+=w(n,t,o,!1)):a+=o[0];for(var i=1;i<e.length;i++)a+=w(n,t,e[i],46===a.charCodeAt(a.length-1)),r&&(a+=o[i]);L.lastIndex=0;for(var s,u="";null!==(s=L.exec(a));)u+="-"+s[1];return{name:f(a)+u,styles:a,next:M}},k=Object.prototype.hasOwnProperty,x=Object(a.createContext)("undefined"!=typeof HTMLElement?c():null),E=Object(a.createContext)({}),S=x.Provider,O=function(e){var t=function(t,n){return Object(a.createElement)(x.Consumer,null,(function(r){return e(t,r,n)}))};return Object(a.forwardRef)(t)},D="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",Y=function(e,t){var n={};for(var r in t)k.call(t,r)&&(n[r]=t[r]);return n[D]=e,n},A=function(e,t,n,r){var o=null===n?t.css:t.css(n);"string"==typeof o&&void 0!==e.registered[o]&&(o=e.registered[o]);var i=t[D],s=[o],u="";"string"==typeof t.className?u=d(e.registered,s,t.className):null!=t.className&&(u=t.className+" ");var l=T(s);p(e,l,"string"==typeof i);u+=e.key+"-"+l.name;var c={};for(var f in t)k.call(t,f)&&"css"!==f&&f!==D&&(c[f]=t[f]);return c.ref=r,c.className=u,Object(a.createElement)(i,c)},C=O((function(e,t,n){return"function"==typeof e.css?Object(a.createElement)(E.Consumer,null,(function(r){return A(t,e,r,n)})):A(t,e,null,n)}));var j=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return T(t)},P=function(e,t){var n=arguments;if(null==t||!k.call(t,"css"))return a.createElement.apply(void 0,n);var r=n.length,o=new Array(r);o[0]=C,o[1]=Y(e,t);for(var i=2;i<r;i++)o[i]=n[i];return a.createElement.apply(null,o)},H=O((function(e,t){var n=e.styles;if("function"==typeof n)return Object(a.createElement)(E.Consumer,null,(function(e){var r=T([n(e)]);return Object(a.createElement)(I,{serialized:r,cache:t})}));var r=T([n]);return Object(a.createElement)(I,{serialized:r,cache:t})})),I=function(e){var t,n;function a(t,n,r){return e.call(this,t,n,r)||this}n=e,(t=a).prototype=Object.create(n.prototype),t.prototype.constructor=t,r(t,n);var i=a.prototype;return i.componentDidMount=function(){this.sheet=new o({key:this.props.cache.key+"-global",nonce:this.props.cache.sheet.nonce,container:this.props.cache.sheet.container});var e=document.querySelector("style[data-emotion-"+this.props.cache.key+'="'+this.props.serialized.name+'"]');null!==e&&this.sheet.tags.push(e),this.props.cache.sheet.tags.length&&(this.sheet.before=this.props.cache.sheet.tags[0]),this.insertStyles()},i.componentDidUpdate=function(e){e.serialized.name!==this.props.serialized.name&&this.insertStyles()},i.insertStyles=function(){if(void 0!==this.props.serialized.next&&p(this.props.cache,this.props.serialized.next,!0),this.sheet.tags.length){var e=this.sheet.tags[this.sheet.tags.length-1].nextElementSibling;this.sheet.before=e,this.sheet.flush()}this.props.cache.insert("",this.props.serialized,this.sheet,!1)},i.componentWillUnmount=function(){this.sheet.flush()},i.render=function(){return null},a}(a.Component),N=function(){var e=j.apply(void 0,arguments),t="animation-"+e.name;return{name:t,styles:"@keyframes "+t+"{"+e.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}},R=function e(t){for(var n=t.length,r=0,a="";r<n;r++){var o=t[r];if(null!=o){var i=void 0;switch(typeof o){case"boolean":break;case"object":if(Array.isArray(o))i=e(o);else for(var s in i="",o)o[s]&&s&&(i&&(i+=" "),i+=s);break;default:i=o}i&&(a&&(a+=" "),a+=i)}}return a};function F(e,t,n){var r=[],a=d(e,r,n);return r.length<2?n:a+t(r)}var z=O((function(e,t){return Object(a.createElement)(E.Consumer,null,(function(n){var r=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];var a=T(n,t.registered);return p(t,a,!1),t.key+"-"+a.name},a={css:r,cx:function(){for(var e=arguments.length,n=new Array(e),a=0;a<e;a++)n[a]=arguments[a];return F(t.registered,r,R(n))},theme:n},o=e.children(a);return!0,o}))}))}])}));
280
+ */!function(o){if(void 0===(a="function"==typeof(r=o)?r.call(t,n,t,e):r)||(e.exports=a),!0,e.exports=o(),!!0){var i=window.Cookies,s=window.Cookies=o();s.noConflict=function(){return window.Cookies=i,s}}}((function(){function e(){for(var e=0,t={};e<arguments.length;e++){var n=arguments[e];for(var r in n)t[r]=n[r]}return t}function t(e){return e.replace(/(%[0-9A-Z]{2})+/g,decodeURIComponent)}return function n(r){function a(){}function o(t,n,o){if("undefined"!=typeof document){"number"==typeof(o=e({path:"/"},a.defaults,o)).expires&&(o.expires=new Date(1*new Date+864e5*o.expires)),o.expires=o.expires?o.expires.toUTCString():"";try{var i=JSON.stringify(n);/^[\{\[]/.test(i)&&(n=i)}catch(e){}n=r.write?r.write(n,t):encodeURIComponent(String(n)).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent),t=encodeURIComponent(String(t)).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent).replace(/[\(\)]/g,escape);var s="";for(var u in o)o[u]&&(s+="; "+u,!0!==o[u]&&(s+="="+o[u].split(";")[0]));return document.cookie=t+"="+n+s}}function i(e,n){if("undefined"!=typeof document){for(var a={},o=document.cookie?document.cookie.split("; "):[],i=0;i<o.length;i++){var s=o[i].split("="),u=s.slice(1).join("=");n||'"'!==u.charAt(0)||(u=u.slice(1,-1));try{var l=t(s[0]);if(u=(r.read||r)(u,l)||t(u),n)try{u=JSON.parse(u)}catch(e){}if(a[l]=u,e===l)break}catch(e){}}return e?a[e]:a}}return a.set=o,a.get=function(e){return i(e,!1)},a.getJSON=function(e){return i(e,!0)},a.remove=function(t,n){o(t,"",e(n,{expires:-1}))},a.defaults={},a.withConverter=n,a}((function(){}))}))},function(e,t,n){"use strict";n.r(t),function(e,r){n.d(t,"Authentication",(function(){return Rt})),n.d(t,"Management",(function(){return Ft})),n.d(t,"WebAuth",(function(){return Ht})),n.d(t,"version",(function(){return se}));var a="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{};function o(e,t){return e(t={exports:{}},t.exports),t.exports}var i=o((function(e){var t,n;t=a,n=function(){function e(e){var t=[];if(0===e.length)return"";if("string"!=typeof e[0])throw new TypeError("Url must be a string. Received "+e[0]);if(e[0].match(/^[^/:]+:\/*$/)&&e.length>1){var n=e.shift();e[0]=n+e[0]}e[0].match(/^file:\/\/\//)?e[0]=e[0].replace(/^([^/:]+):\/*/,"$1:///"):e[0]=e[0].replace(/^([^/:]+):\/*/,"$1://");for(var r=0;r<e.length;r++){var a=e[r];if("string"!=typeof a)throw new TypeError("Url must be a string. Received "+a);""!==a&&(r>0&&(a=a.replace(/^[\/]+/,"")),a=r<e.length-1?a.replace(/[\/]+$/,""):a.replace(/[\/]+$/,"/"),t.push(a))}var o=t.join("/"),i=(o=o.replace(/\/(\?|&|#[^!])/g,"$1")).split("?");return i.shift()+(i.length>0?"?":"")+i.join("&")}return function(){return e("object"==typeof arguments[0]?arguments[0]:[].slice.call(arguments))}},e.exports?e.exports=n():t.urljoin=n()})),s=Object.prototype.hasOwnProperty,u=Array.isArray,l=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),c=function(e,t){for(var n=t&&t.plainObjects?Object.create(null):{},r=0;r<e.length;++r)void 0!==e[r]&&(n[r]=e[r]);return n},d={arrayToObject:c,assign:function(e,t){return Object.keys(t).reduce((function(e,n){return e[n]=t[n],e}),e)},combine:function(e,t){return[].concat(e,t)},compact:function(e){for(var t=[{obj:{o:e},prop:"o"}],n=[],r=0;r<t.length;++r)for(var a=t[r],o=a.obj[a.prop],i=Object.keys(o),s=0;s<i.length;++s){var l=i[s],c=o[l];"object"==typeof c&&null!==c&&-1===n.indexOf(c)&&(t.push({obj:o,prop:l}),n.push(c))}return function(e){for(;e.length>1;){var t=e.pop(),n=t.obj[t.prop];if(u(n)){for(var r=[],a=0;a<n.length;++a)void 0!==n[a]&&r.push(n[a]);t.obj[t.prop]=r}}}(t),e},decode:function(e,t,n){var r=e.replace(/\+/g," ");if("iso-8859-1"===n)return r.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(r)}catch(e){return r}},encode:function(e,t,n){if(0===e.length)return e;var r=e;if("symbol"==typeof e?r=Symbol.prototype.toString.call(e):"string"!=typeof e&&(r=String(e)),"iso-8859-1"===n)return escape(r).replace(/%u[0-9a-f]{4}/gi,(function(e){return"%26%23"+parseInt(e.slice(2),16)+"%3B"}));for(var a="",o=0;o<r.length;++o){var i=r.charCodeAt(o);45===i||46===i||95===i||126===i||i>=48&&i<=57||i>=65&&i<=90||i>=97&&i<=122?a+=r.charAt(o):i<128?a+=l[i]:i<2048?a+=l[192|i>>6]+l[128|63&i]:i<55296||i>=57344?a+=l[224|i>>12]+l[128|i>>6&63]+l[128|63&i]:(o+=1,i=65536+((1023&i)<<10|1023&r.charCodeAt(o)),a+=l[240|i>>18]+l[128|i>>12&63]+l[128|i>>6&63]+l[128|63&i])}return a},isBuffer:function(e){return!(!e||"object"!=typeof e||!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e)))},isRegExp:function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},maybeMap:function(e,t){if(u(e)){for(var n=[],r=0;r<e.length;r+=1)n.push(t(e[r]));return n}return t(e)},merge:function e(t,n,r){if(!n)return t;if("object"!=typeof n){if(u(t))t.push(n);else{if(!t||"object"!=typeof t)return[t,n];(r&&(r.plainObjects||r.allowPrototypes)||!s.call(Object.prototype,n))&&(t[n]=!0)}return t}if(!t||"object"!=typeof t)return[t].concat(n);var a=t;return u(t)&&!u(n)&&(a=c(t,r)),u(t)&&u(n)?(n.forEach((function(n,a){if(s.call(t,a)){var o=t[a];o&&"object"==typeof o&&n&&"object"==typeof n?t[a]=e(o,n,r):t.push(n)}else t[a]=n})),t):Object.keys(n).reduce((function(t,a){var o=n[a];return s.call(t,a)?t[a]=e(t[a],o,r):t[a]=o,t}),a)}},p=String.prototype.replace,f=/%20/g,h={RFC1738:"RFC1738",RFC3986:"RFC3986"},m=d.assign({default:h.RFC3986,formatters:{RFC1738:function(e){return p.call(e,f,"+")},RFC3986:function(e){return String(e)}}},h),_=Object.prototype.hasOwnProperty,y={brackets:function(e){return e+"[]"},comma:"comma",indices:function(e,t){return e+"["+t+"]"},repeat:function(e){return e}},g=Array.isArray,v=Array.prototype.push,b=function(e,t){v.apply(e,g(t)?t:[t])},w=Date.prototype.toISOString,M=m.default,L={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:d.encode,encodeValuesOnly:!1,format:M,formatter:m.formatters[M],indices:!1,serializeDate:function(e){return w.call(e)},skipNulls:!1,strictNullHandling:!1},T=function e(t,n,r,a,o,i,s,u,l,c,p,f,h){var m=t;if("function"==typeof s?m=s(n,m):m instanceof Date?m=c(m):"comma"===r&&g(m)&&(m=d.maybeMap(m,(function(e){return e instanceof Date?c(e):e})).join(",")),null===m){if(a)return i&&!f?i(n,L.encoder,h,"key"):n;m=""}if(function(e){return"string"==typeof e||"number"==typeof e||"boolean"==typeof e||"symbol"==typeof e||"bigint"==typeof e}(m)||d.isBuffer(m))return i?[p(f?n:i(n,L.encoder,h,"key"))+"="+p(i(m,L.encoder,h,"value"))]:[p(n)+"="+p(String(m))];var _,y=[];if(void 0===m)return y;if(g(s))_=s;else{var v=Object.keys(m);_=u?v.sort(u):v}for(var w=0;w<_.length;++w){var M=_[w],T=m[M];if(!o||null!==T){var k=g(m)?"function"==typeof r?r(n,M):n:n+(l?"."+M:"["+M+"]");b(y,e(T,k,r,a,o,i,s,u,l,c,p,f,h))}}return y},k=Object.prototype.hasOwnProperty,x=Array.isArray,E={allowDots:!1,allowPrototypes:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:d.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},S=function(e){return e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(parseInt(t,10))}))},O=function(e,t){return e&&"string"==typeof e&&t.comma&&e.indexOf(",")>-1?e.split(","):e},D=function(e,t,n,r){if(e){var a=n.allowDots?e.replace(/\.([^.[]+)/g,"[$1]"):e,o=/(\[[^[\]]*])/g,i=n.depth>0&&/(\[[^[\]]*])/.exec(a),s=i?a.slice(0,i.index):a,u=[];if(s){if(!n.plainObjects&&k.call(Object.prototype,s)&&!n.allowPrototypes)return;u.push(s)}for(var l=0;n.depth>0&&null!==(i=o.exec(a))&&l<n.depth;){if(l+=1,!n.plainObjects&&k.call(Object.prototype,i[1].slice(1,-1))&&!n.allowPrototypes)return;u.push(i[1])}return i&&u.push("["+a.slice(i.index)+"]"),function(e,t,n,r){for(var a=r?t:O(t,n),o=e.length-1;o>=0;--o){var i,s=e[o];if("[]"===s&&n.parseArrays)i=[].concat(a);else{i=n.plainObjects?Object.create(null):{};var u="["===s.charAt(0)&&"]"===s.charAt(s.length-1)?s.slice(1,-1):s,l=parseInt(u,10);n.parseArrays||""!==u?!isNaN(l)&&s!==u&&String(l)===u&&l>=0&&n.parseArrays&&l<=n.arrayLimit?(i=[])[l]=a:i[u]=a:i={0:a}}a=i}return a}(u,t,n,r)}},Y=function(e,t){var n,r=e,a=function(e){if(!e)return L;if(null!==e.encoder&&void 0!==e.encoder&&"function"!=typeof e.encoder)throw new TypeError("Encoder has to be a function.");var t=e.charset||L.charset;if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var n=m.default;if(void 0!==e.format){if(!_.call(m.formatters,e.format))throw new TypeError("Unknown format option provided.");n=e.format}var r=m.formatters[n],a=L.filter;return("function"==typeof e.filter||g(e.filter))&&(a=e.filter),{addQueryPrefix:"boolean"==typeof e.addQueryPrefix?e.addQueryPrefix:L.addQueryPrefix,allowDots:void 0===e.allowDots?L.allowDots:!!e.allowDots,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:L.charsetSentinel,delimiter:void 0===e.delimiter?L.delimiter:e.delimiter,encode:"boolean"==typeof e.encode?e.encode:L.encode,encoder:"function"==typeof e.encoder?e.encoder:L.encoder,encodeValuesOnly:"boolean"==typeof e.encodeValuesOnly?e.encodeValuesOnly:L.encodeValuesOnly,filter:a,formatter:r,serializeDate:"function"==typeof e.serializeDate?e.serializeDate:L.serializeDate,skipNulls:"boolean"==typeof e.skipNulls?e.skipNulls:L.skipNulls,sort:"function"==typeof e.sort?e.sort:null,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:L.strictNullHandling}}(t);"function"==typeof a.filter?r=(0,a.filter)("",r):g(a.filter)&&(n=a.filter);var o,i=[];if("object"!=typeof r||null===r)return"";o=t&&t.arrayFormat in y?t.arrayFormat:t&&"indices"in t?t.indices?"indices":"repeat":"indices";var s=y[o];n||(n=Object.keys(r)),a.sort&&n.sort(a.sort);for(var u=0;u<n.length;++u){var l=n[u];a.skipNulls&&null===r[l]||b(i,T(r[l],l,s,a.strictNullHandling,a.skipNulls,a.encode?a.encoder:null,a.filter,a.sort,a.allowDots,a.serializeDate,a.formatter,a.encodeValuesOnly,a.charset))}var c=i.join(a.delimiter),d=!0===a.addQueryPrefix?"?":"";return a.charsetSentinel&&("iso-8859-1"===a.charset?d+="utf8=%26%2310003%3B&":d+="utf8=%E2%9C%93&"),c.length>0?d+c:""},A=o((function(e){function t(e){if(e)return function(e){for(var n in t.prototype)e[n]=t.prototype[n];return e}(e)}e.exports=t,t.prototype.on=t.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},t.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},t.prototype.off=t.prototype.removeListener=t.prototype.removeAllListeners=t.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var a=0;a<r.length;a++)if((n=r[a])===t||n.fn===t){r.splice(a,1);break}return 0===r.length&&delete this._callbacks["$"+e],this},t.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){r=0;for(var a=(n=n.slice(0)).length;r<a;++r)n[r].apply(this,t)}return this},t.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},t.prototype.hasListeners=function(e){return!!this.listeners(e).length}})),C=H;H.default=H,H.stable=N,H.stableStringify=N;var j=[],P=[];function H(e,t,n){var r;for(function e(t,n,r,a){var o;if("object"==typeof t&&null!==t){for(o=0;o<r.length;o++)if(r[o]===t){var i=Object.getOwnPropertyDescriptor(a,n);return void(void 0!==i.get?i.configurable?(Object.defineProperty(a,n,{value:"[Circular]"}),j.push([a,n,t,i])):P.push([t,n]):(a[n]="[Circular]",j.push([a,n,t])))}if(r.push(t),Array.isArray(t))for(o=0;o<t.length;o++)e(t[o],o,r,t);else{var s=Object.keys(t);for(o=0;o<s.length;o++){var u=s[o];e(t[u],u,r,t)}}r.pop()}}(e,"",[],void 0),r=0===P.length?JSON.stringify(e,t,n):JSON.stringify(e,R(t),n);0!==j.length;){var a=j.pop();4===a.length?Object.defineProperty(a[0],a[1],a[3]):a[0][a[1]]=a[2]}return r}function I(e,t){return e<t?-1:e>t?1:0}function N(e,t,n){var r,a=function e(t,n,r,a){var o;if("object"==typeof t&&null!==t){for(o=0;o<r.length;o++)if(r[o]===t){var i=Object.getOwnPropertyDescriptor(a,n);return void(void 0!==i.get?i.configurable?(Object.defineProperty(a,n,{value:"[Circular]"}),j.push([a,n,t,i])):P.push([t,n]):(a[n]="[Circular]",j.push([a,n,t])))}if("function"==typeof t.toJSON)return;if(r.push(t),Array.isArray(t))for(o=0;o<t.length;o++)e(t[o],o,r,t);else{var s={},u=Object.keys(t).sort(I);for(o=0;o<u.length;o++){var l=u[o];e(t[l],l,r,t),s[l]=t[l]}if(void 0===a)return s;j.push([a,n,t]),a[n]=s}r.pop()}}(e,"",[],void 0)||e;for(r=0===P.length?JSON.stringify(a,t,n):JSON.stringify(a,R(t),n);0!==j.length;){var o=j.pop();4===o.length?Object.defineProperty(o[0],o[1],o[3]):o[0][o[1]]=o[2]}return r}function R(e){return e=void 0!==e?e:function(e,t){return t},function(t,n){if(P.length>0)for(var r=0;r<P.length;r++){var a=P[r];if(a[1]===t&&a[0]===n){n="[Circular]",P.splice(r,1);break}}return e.call(this,t,n)}}function F(e){return(F="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var z=function(e){return null!==e&&"object"===F(e)};function U(e){return(U="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var W=B;function B(e){if(e)return function(e){for(var t in B.prototype)Object.prototype.hasOwnProperty.call(B.prototype,t)&&(e[t]=B.prototype[t]);return e}(e)}B.prototype.clearTimeout=function(){return clearTimeout(this._timer),clearTimeout(this._responseTimeoutTimer),clearTimeout(this._uploadTimeoutTimer),delete this._timer,delete this._responseTimeoutTimer,delete this._uploadTimeoutTimer,this},B.prototype.parse=function(e){return this._parser=e,this},B.prototype.responseType=function(e){return this._responseType=e,this},B.prototype.serialize=function(e){return this._serializer=e,this},B.prototype.timeout=function(e){if(!e||"object"!==U(e))return this._timeout=e,this._responseTimeout=0,this._uploadTimeout=0,this;for(var t in e)if(Object.prototype.hasOwnProperty.call(e,t))switch(t){case"deadline":this._timeout=e.deadline;break;case"response":this._responseTimeout=e.response;break;case"upload":this._uploadTimeout=e.upload;break;default:console.warn("Unknown timeout option",t)}return this},B.prototype.retry=function(e,t){return 0!==arguments.length&&!0!==e||(e=1),e<=0&&(e=0),this._maxRetries=e,this._retries=0,this._retryCallback=t,this};var V=["ECONNRESET","ETIMEDOUT","EADDRINFO","ESOCKETTIMEDOUT"];B.prototype._shouldRetry=function(e,t){if(!this._maxRetries||this._retries++>=this._maxRetries)return!1;if(this._retryCallback)try{var n=this._retryCallback(e,t);if(!0===n)return!0;if(!1===n)return!1}catch(e){console.error(e)}if(t&&t.status&&t.status>=500&&501!==t.status)return!0;if(e){if(e.code&&V.includes(e.code))return!0;if(e.timeout&&"ECONNABORTED"===e.code)return!0;if(e.crossDomain)return!0}return!1},B.prototype._retry=function(){return this.clearTimeout(),this.req&&(this.req=null,this.req=this.request()),this._aborted=!1,this.timedout=!1,this.timedoutError=null,this._end()},B.prototype.then=function(e,t){var n=this;if(!this._fullfilledPromise){var r=this;this._endCalled&&console.warn("Warning: superagent request was sent twice, because both .end() and .then() were called. Never call .end() if you use promises"),this._fullfilledPromise=new Promise((function(e,t){r.on("abort",(function(){if(!(n._maxRetries&&n._maxRetries>n._retries))if(n.timedout&&n.timedoutError)t(n.timedoutError);else{var e=new Error("Aborted");e.code="ABORTED",e.status=n.status,e.method=n.method,e.url=n.url,t(e)}})),r.end((function(n,r){n?t(n):e(r)}))}))}return this._fullfilledPromise.then(e,t)},B.prototype.catch=function(e){return this.then(void 0,e)},B.prototype.use=function(e){return e(this),this},B.prototype.ok=function(e){if("function"!=typeof e)throw new Error("Callback required");return this._okCallback=e,this},B.prototype._isResponseOK=function(e){return!!e&&(this._okCallback?this._okCallback(e):e.status>=200&&e.status<300)},B.prototype.get=function(e){return this._header[e.toLowerCase()]},B.prototype.getHeader=B.prototype.get,B.prototype.set=function(e,t){if(z(e)){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&this.set(n,e[n]);return this}return this._header[e.toLowerCase()]=t,this.header[e]=t,this},B.prototype.unset=function(e){return delete this._header[e.toLowerCase()],delete this.header[e],this},B.prototype.field=function(e,t){if(null==e)throw new Error(".field(name, val) name can not be empty");if(this._data)throw new Error(".field() can't be used if .send() is used. Please use only .send() or only .field() & .attach()");if(z(e)){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&this.field(n,e[n]);return this}if(Array.isArray(t)){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&this.field(e,t[r]);return this}if(null==t)throw new Error(".field(name, val) val can not be empty");return"boolean"==typeof t&&(t=String(t)),this._getFormData().append(e,t),this},B.prototype.abort=function(){return this._aborted||(this._aborted=!0,this.xhr&&this.xhr.abort(),this.req&&this.req.abort(),this.clearTimeout(),this.emit("abort")),this},B.prototype._auth=function(e,t,n,r){switch(n.type){case"basic":this.set("Authorization","Basic ".concat(r("".concat(e,":").concat(t))));break;case"auto":this.username=e,this.password=t;break;case"bearer":this.set("Authorization","Bearer ".concat(e))}return this},B.prototype.withCredentials=function(e){return void 0===e&&(e=!0),this._withCredentials=e,this},B.prototype.redirects=function(e){return this._maxRedirects=e,this},B.prototype.maxResponseSize=function(e){if("number"!=typeof e)throw new TypeError("Invalid argument");return this._maxResponseSize=e,this},B.prototype.toJSON=function(){return{method:this.method,url:this.url,data:this._data,headers:this._header}},B.prototype.send=function(e){var t=z(e),n=this._header["content-type"];if(this._formData)throw new Error(".send() can't be used if .attach() or .field() is used. Please use only .send() or only .field() & .attach()");if(t&&!this._data)Array.isArray(e)?this._data=[]:this._isHost(e)||(this._data={});else if(e&&this._data&&this._isHost(this._data))throw new Error("Can't merge these send calls");if(t&&z(this._data))for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(this._data[r]=e[r]);else"string"==typeof e?(n||this.type("form"),n=this._header["content-type"],this._data="application/x-www-form-urlencoded"===n?this._data?"".concat(this._data,"&").concat(e):e:(this._data||"")+e):this._data=e;return!t||this._isHost(e)||n||this.type("json"),this},B.prototype.sortQuery=function(e){return this._sort=void 0===e||e,this},B.prototype._finalizeQueryString=function(){var e=this._query.join("&");if(e&&(this.url+=(this.url.includes("?")?"&":"?")+e),this._query.length=0,this._sort){var t=this.url.indexOf("?");if(t>=0){var n=this.url.slice(t+1).split("&");"function"==typeof this._sort?n.sort(this._sort):n.sort(),this.url=this.url.slice(0,t)+"?"+n.join("&")}}},B.prototype._appendQueryString=function(){console.warn("Unsupported")},B.prototype._timeoutError=function(e,t,n){if(!this._aborted){var r=new Error("".concat(e+t,"ms exceeded"));r.timeout=t,r.code="ECONNABORTED",r.errno=n,this.timedout=!0,this.timedoutError=r,this.abort(),this.callback(r)}},B.prototype._setTimeouts=function(){var e=this;this._timeout&&!this._timer&&(this._timer=setTimeout((function(){e._timeoutError("Timeout of ",e._timeout,"ETIME")}),this._timeout)),this._responseTimeout&&!this._responseTimeoutTimer&&(this._responseTimeoutTimer=setTimeout((function(){e._timeoutError("Response timeout of ",e._responseTimeout,"ETIMEDOUT")}),this._responseTimeout))};var G=q;function q(e){if(e)return function(e){for(var t in q.prototype)Object.prototype.hasOwnProperty.call(q.prototype,t)&&(e[t]=q.prototype[t]);return e}(e)}function J(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function K(){this._defaults=[]}q.prototype.get=function(e){return this.header[e.toLowerCase()]},q.prototype._setHeaderProperties=function(e){var t=e["content-type"]||"";this.type=t.split(/ *; */).shift();var n=function(e){return e.split(/ *; */).reduce((function(e,t){var n=t.split(/ *= */),r=n.shift(),a=n.shift();return r&&a&&(e[r]=a),e}),{})}(t);for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(this[r]=n[r]);this.links={};try{e.link&&(this.links=function(e){return e.split(/ *, */).reduce((function(e,t){var n=t.split(/ *; */),r=n[0].slice(1,-1);return e[n[1].split(/ *= */)[1].slice(1,-1)]=r,e}),{})}(e.link))}catch(e){}},q.prototype._setStatusProperties=function(e){var t=e/100|0;this.statusCode=e,this.status=this.statusCode,this.statusType=t,this.info=1===t,this.ok=2===t,this.redirect=3===t,this.clientError=4===t,this.serverError=5===t,this.error=(4===t||5===t)&&this.toError(),this.created=201===e,this.accepted=202===e,this.noContent=204===e,this.badRequest=400===e,this.unauthorized=401===e,this.notAcceptable=406===e,this.forbidden=403===e,this.notFound=404===e,this.unprocessableEntity=422===e},["use","on","once","set","query","type","accept","auth","withCredentials","sortQuery","retry","ok","redirects","timeout","buffer","serialize","parse","ca","key","pfx","cert","disableTLSCerts"].forEach((function(e){K.prototype[e]=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return this._defaults.push({fn:e,args:n}),this}})),K.prototype._setDefaults=function(e){this._defaults.forEach((function(t){e[t.fn].apply(e,function(e){return function(e){if(Array.isArray(e))return J(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return J(e,void 0);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?J(e,void 0):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t.args))}))};for(var $=K,X=o((function(e,t){function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}var r;function a(){}"undefined"!=typeof window?r=window:"undefined"==typeof self?(console.warn("Using browser-only version of superagent in non-browser environment"),r=void 0):r=self,e.exports=function(e,n){return"function"==typeof n?new t.Request("GET",e).end(n):1===arguments.length?new t.Request("GET",e):new t.Request(e,n)};var o=t=e.exports;t.Request=p,o.getXHR=function(){if(r.XMLHttpRequest&&(!r.location||"file:"!==r.location.protocol||!r.ActiveXObject))return new XMLHttpRequest;try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(e){}throw new Error("Browser-only version of superagent could not find XHR")};var i="".trim?function(e){return e.trim()}:function(e){return e.replace(/(^\s*|\s*$)/g,"")};function s(e){if(!z(e))return e;var t=[];for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&u(t,n,e[n]);return t.join("&")}function u(e,t,n){if(void 0!==n)if(null!==n)if(Array.isArray(n))n.forEach((function(n){u(e,t,n)}));else if(z(n))for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&u(e,"".concat(t,"[").concat(r,"]"),n[r]);else e.push(encodeURI(t)+"="+encodeURIComponent(n));else e.push(encodeURI(t))}function l(e){for(var t,n,r={},a=e.split("&"),o=0,i=a.length;o<i;++o)-1===(n=(t=a[o]).indexOf("="))?r[decodeURIComponent(t)]="":r[decodeURIComponent(t.slice(0,n))]=decodeURIComponent(t.slice(n+1));return r}function c(e){return/[/+]json($|[^-\w])/.test(e)}function d(e){this.req=e,this.xhr=this.req.xhr,this.text="HEAD"!==this.req.method&&(""===this.xhr.responseType||"text"===this.xhr.responseType)||void 0===this.xhr.responseType?this.xhr.responseText:null,this.statusText=this.req.xhr.statusText;var t=this.xhr.status;1223===t&&(t=204),this._setStatusProperties(t),this.headers=function(e){for(var t,n,r,a,o=e.split(/\r?\n/),s={},u=0,l=o.length;u<l;++u)-1!==(t=(n=o[u]).indexOf(":"))&&(r=n.slice(0,t).toLowerCase(),a=i(n.slice(t+1)),s[r]=a);return s}(this.xhr.getAllResponseHeaders()),this.header=this.headers,this.header["content-type"]=this.xhr.getResponseHeader("content-type"),this._setHeaderProperties(this.header),null===this.text&&e._responseType?this.body=this.xhr.response:this.body="HEAD"===this.req.method?null:this._parseBody(this.text?this.text:this.xhr.response)}function p(e,t){var n=this;this._query=this._query||[],this.method=e,this.url=t,this.header={},this._header={},this.on("end",(function(){var e,t=null,r=null;try{r=new d(n)}catch(e){return(t=new Error("Parser is unable to parse the response")).parse=!0,t.original=e,n.xhr?(t.rawResponse=void 0===n.xhr.responseType?n.xhr.responseText:n.xhr.response,t.status=n.xhr.status?n.xhr.status:null,t.statusCode=t.status):(t.rawResponse=null,t.status=null),n.callback(t)}n.emit("response",r);try{n._isResponseOK(r)||(e=new Error(r.statusText||r.text||"Unsuccessful HTTP response"))}catch(t){e=t}e?(e.original=t,e.response=r,e.status=r.status,n.callback(e,r)):n.callback(null,r)}))}function f(e,t,n){var r=o("DELETE",e);return"function"==typeof t&&(n=t,t=null),t&&r.send(t),n&&r.end(n),r}o.serializeObject=s,o.parseString=l,o.types={html:"text/html",json:"application/json",xml:"text/xml",urlencoded:"application/x-www-form-urlencoded",form:"application/x-www-form-urlencoded","form-data":"application/x-www-form-urlencoded"},o.serialize={"application/x-www-form-urlencoded":s,"application/json":C},o.parse={"application/x-www-form-urlencoded":l,"application/json":JSON.parse},G(d.prototype),d.prototype._parseBody=function(e){var t=o.parse[this.type];return this.req._parser?this.req._parser(this,e):(!t&&c(this.type)&&(t=o.parse["application/json"]),t&&e&&(e.length>0||e instanceof Object)?t(e):null)},d.prototype.toError=function(){var e=this.req,t=e.method,n=e.url,r="cannot ".concat(t," ").concat(n," (").concat(this.status,")"),a=new Error(r);return a.status=this.status,a.method=t,a.url=n,a},o.Response=d,A(p.prototype),W(p.prototype),p.prototype.type=function(e){return this.set("Content-Type",o.types[e]||e),this},p.prototype.accept=function(e){return this.set("Accept",o.types[e]||e),this},p.prototype.auth=function(e,t,r){1===arguments.length&&(t=""),"object"===n(t)&&null!==t&&(r=t,t=""),r||(r={type:"function"==typeof btoa?"basic":"auto"});var a=function(e){if("function"==typeof btoa)return btoa(e);throw new Error("Cannot use basic auth, btoa is not a function")};return this._auth(e,t,r,a)},p.prototype.query=function(e){return"string"!=typeof e&&(e=s(e)),e&&this._query.push(e),this},p.prototype.attach=function(e,t,n){if(t){if(this._data)throw new Error("superagent can't mix .send() and .attach()");this._getFormData().append(e,t,n||t.name)}return this},p.prototype._getFormData=function(){return this._formData||(this._formData=new r.FormData),this._formData},p.prototype.callback=function(e,t){if(this._shouldRetry(e,t))return this._retry();var n=this._callback;this.clearTimeout(),e&&(this._maxRetries&&(e.retries=this._retries-1),this.emit("error",e)),n(e,t)},p.prototype.crossDomainError=function(){var e=new Error("Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.");e.crossDomain=!0,e.status=this.status,e.method=this.method,e.url=this.url,this.callback(e)},p.prototype.agent=function(){return console.warn("This is not supported in browser version of superagent"),this},p.prototype.ca=p.prototype.agent,p.prototype.buffer=p.prototype.ca,p.prototype.write=function(){throw new Error("Streaming is not supported in browser version of superagent")},p.prototype.pipe=p.prototype.write,p.prototype._isHost=function(e){return e&&"object"===n(e)&&!Array.isArray(e)&&"[object Object]"!==Object.prototype.toString.call(e)},p.prototype.end=function(e){this._endCalled&&console.warn("Warning: .end() was called twice. This is not supported in superagent"),this._endCalled=!0,this._callback=e||a,this._finalizeQueryString(),this._end()},p.prototype._setUploadTimeout=function(){var e=this;this._uploadTimeout&&!this._uploadTimeoutTimer&&(this._uploadTimeoutTimer=setTimeout((function(){e._timeoutError("Upload timeout of ",e._uploadTimeout,"ETIMEDOUT")}),this._uploadTimeout))},p.prototype._end=function(){if(this._aborted)return this.callback(new Error("The request has been aborted even before .end() was called"));var e=this;this.xhr=o.getXHR();var t=this.xhr,n=this._formData||this._data;this._setTimeouts(),t.onreadystatechange=function(){var n=t.readyState;if(n>=2&&e._responseTimeoutTimer&&clearTimeout(e._responseTimeoutTimer),4===n){var r;try{r=t.status}catch(e){r=0}if(!r){if(e.timedout||e._aborted)return;return e.crossDomainError()}e.emit("end")}};var r=function(t,n){n.total>0&&(n.percent=n.loaded/n.total*100,100===n.percent&&clearTimeout(e._uploadTimeoutTimer)),n.direction=t,e.emit("progress",n)};if(this.hasListeners("progress"))try{t.addEventListener("progress",r.bind(null,"download")),t.upload&&t.upload.addEventListener("progress",r.bind(null,"upload"))}catch(e){}t.upload&&this._setUploadTimeout();try{this.username&&this.password?t.open(this.method,this.url,!0,this.username,this.password):t.open(this.method,this.url,!0)}catch(e){return this.callback(e)}if(this._withCredentials&&(t.withCredentials=!0),!this._formData&&"GET"!==this.method&&"HEAD"!==this.method&&"string"!=typeof n&&!this._isHost(n)){var a=this._header["content-type"],i=this._serializer||o.serialize[a?a.split(";")[0]:""];!i&&c(a)&&(i=o.serialize["application/json"]),i&&(n=i(n))}for(var s in this.header)null!==this.header[s]&&Object.prototype.hasOwnProperty.call(this.header,s)&&t.setRequestHeader(s,this.header[s]);this._responseType&&(t.responseType=this._responseType),this.emit("request",this),t.send(void 0===n?null:n)},o.agent=function(){return new $},["GET","POST","OPTIONS","PATCH","PUT","DELETE"].forEach((function(e){$.prototype[e.toLowerCase()]=function(t,n){var r=new o.Request(e,t);return this._setDefaults(r),n&&r.end(n),r}})),$.prototype.del=$.prototype.delete,o.get=function(e,t,n){var r=o("GET",e);return"function"==typeof t&&(n=t,t=null),t&&r.query(t),n&&r.end(n),r},o.head=function(e,t,n){var r=o("HEAD",e);return"function"==typeof t&&(n=t,t=null),t&&r.query(t),n&&r.end(n),r},o.options=function(e,t,n){var r=o("OPTIONS",e);return"function"==typeof t&&(n=t,t=null),t&&r.send(t),n&&r.end(n),r},o.del=f,o.delete=f,o.patch=function(e,t,n){var r=o("PATCH",e);return"function"==typeof t&&(n=t,t=null),t&&r.send(t),n&&r.end(n),r},o.post=function(e,t,n){var r=o("POST",e);return"function"==typeof t&&(n=t,t=null),t&&r.send(t),n&&r.end(n),r},o.put=function(e,t,n){var r=o("PUT",e);return"function"==typeof t&&(n=t,t=null),t&&r.send(t),n&&r.end(n),r}})),Z=(X.Request,[]),Q=[],ee=("undefined"!=typeof Uint8Array&&Uint8Array,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"),te=0,ne=ee.length;te<ne;++te)Z[te]=ee[te],Q[ee.charCodeAt(te)]=te;function re(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&t,[n,n===t?0:4-n%4]}function ae(e,t,n){for(var r,a,o=[],i=t;i<n;i+=3)r=(e[i]<<16&16711680)+(e[i+1]<<8&65280)+(255&e[i+2]),o.push(Z[(a=r)>>18&63]+Z[a>>12&63]+Z[a>>6&63]+Z[63&a]);return o.join("")}Q["-".charCodeAt(0)]=62,Q["_".charCodeAt(0)]=63;var oe=function(e){for(var t,n=e.length,r=n%3,a=[],o=0,i=n-r;o<i;o+=16383)a.push(ae(e,o,o+16383>i?i:o+16383));return 1===r?(t=e[n-1],a.push(Z[t>>2]+Z[t<<4&63]+"==")):2===r&&(t=(e[n-2]<<8)+e[n-1],a.push(Z[t>>10]+Z[t>>4&63]+Z[t<<2&63]+"=")),a.join("")},ie=function(e){return oe(function(e){for(var t=new Array(e.length),n=0;n<e.length;n++)t[n]=e.charCodeAt(n);return t}(e)).replace(/\+/g,"-").replace(/\//g,"_")},se={raw:"9.16.2"},ue=Object.prototype.toString;function le(e,t,n,r){if(n="array"===n?"object":n,e&&typeof e[t]!==n)throw new Error(r)}function ce(e,t,n){if(typeof e!==t)throw new Error(n)}function de(e,t,n){if(-1===t.indexOf(e))throw new Error(n)}var pe={check:function(e,t,n){if(t.optional&&!e||ce(e,t.type,t.message),"object"===t.type&&n)for(var r=Object.keys(n),a=0;a<r.length;a++){var o=r[a];n[o].optional&&!e[o]||n[o].condition&&!n[o].condition(e)||(le(e,o,n[o].type,n[o].message),n[o].values&&de(e[o],n[o].values,n[o].value_message))}},attribute:le,variable:ce,value:de,isArray:function(e){return this.supportsIsArray()?Array.isArray(e):"[object Array]"===ue.call(e)},supportsIsArray:function(){return null!=Array.isArray}};function fe(e){if(null==e)throw new TypeError("Cannot convert first argument to object");for(var t=Object(e),n=1;n<arguments.length;n++){var r=arguments[n];if(null!=r)for(var a=Object.keys(Object(r)),o=0,i=a.length;o<i;o++){var s=a[o],u=Object.getOwnPropertyDescriptor(r,s);void 0!==u&&u.enumerable&&(t[s]=r[s])}}return t}var he=function(){return Object.assign?Object.assign:fe};function me(e,t){return t.reduce((function(t,n){return e[n]&&(t[n]=e[n]),t}),{})}function _e(e){var t=[];for(var n in e)t.push(e[n]);return t}function ye(){var e=_e(arguments);return e.unshift({}),he().apply(void 0,e)}function ge(e){var t=e.match(/^(https?:|file:|chrome-extension:)\/\/(([^:/?#]*)(?::([0-9]+))?)([/]{0,1}[^?#]*)(\?[^#]*|)(#.*|)$/);return t&&{href:e,protocol:t[1],host:t[2],hostname:t[3],port:t[4],pathname:t[5],search:t[6],hash:t[7]}}function ve(e,t){var n=ye(e);return e[t]&&(n[t]=e[t].trim()),n}var be={toSnakeCase:function e(t,n){return"object"!=typeof t||pe.isArray(t)||null===t?t:(n=n||[],Object.keys(t).reduce((function(r,a){return r[-1===n.indexOf(a)?function(e){for(var t,n="",r=0,a=!0,o=!0;r<e.length;)t=e.charCodeAt(r),!o&&t>=65&&t<=90||!a&&t>=48&&t<=57?(n+="_",n+=e[r].toLowerCase()):n+=e[r].toLowerCase(),a=t>=48&&t<=57,o=t>=65&&t<=90,r++;return n}(a):a]=e(t[a]),r}),{}))},toCamelCase:function e(t,n,r){return"object"!=typeof t||pe.isArray(t)||null===t?t:(n=n||[],r=r||{},Object.keys(t).reduce((function(a,o){var i,s=-1===n.indexOf(o)?(i=o.split("_")).reduce((function(e,t){return e+t.charAt(0).toUpperCase()+t.slice(1)}),i.shift()):o;return a[s]=e(t[s]||t[o],[],r),r.keepOriginal&&(a[o]=e(t[o],[],r)),a}),{}))},blacklist:function(e,t){return Object.keys(e).reduce((function(n,r){return-1===t.indexOf(r)&&(n[r]=e[r]),n}),{})},merge:function(e,t){return{base:t?me(e,t):e,with:function(e,t){return e=t?me(e,t):e,ye(this.base,e)}}},pick:me,getKeysNotIn:function(e,t){var n=[];for(var r in e)-1===t.indexOf(r)&&n.push(r);return n},extend:ye,getOriginFromUrl:function(e){if(e){var t=ge(e);if(!t)return null;var n=t.protocol+"//"+t.hostname;return t.port&&(n+=":"+t.port),n}},getLocationFromUrl:ge,trimUserDetails:function(e){return function(e,t){return["username","email","phoneNumber"].reduce(ve,e)}(e)},updatePropertyOn:function e(t,n,r){"string"==typeof n&&(n=n.split("."));var a=n[0];t.hasOwnProperty(a)&&(1===n.length?t[a]=r:e(t[a],n.slice(1),r))}};function we(e){this.request=e,this.method=e.method,this.url=e.url,this.body=e._data,this.headers=e._header}function Me(e){this.request=e}function Le(e){this._sendTelemetry=!1!==e._sendTelemetry||e._sendTelemetry,this._telemetryInfo=e._telemetryInfo||null,this._timesToRetryFailedRequests=e._timesToRetryFailedRequests,this.headers=e.headers||{},this._universalLoginPage=e.universalLoginPage}function Te(){return window}we.prototype.abort=function(){this.request.abort()},we.prototype.getMethod=function(){return this.method},we.prototype.getBody=function(){return this.body},we.prototype.getUrl=function(){return this.url},we.prototype.getHeaders=function(){return this.headers},Me.prototype.set=function(e,t){return this.request=this.request.set(e,t),this},Me.prototype.send=function(e){return this.request=this.request.send(be.trimUserDetails(e)),this},Me.prototype.withCredentials=function(){return this.request=this.request.withCredentials(),this},Me.prototype.end=function(e){return this.request.end(e),new we(this.request)},Le.prototype.setCommonConfiguration=function(e,t){if(t=t||{},this._timesToRetryFailedRequests>0&&(e=e.retry(this._timesToRetryFailedRequests)),t.noHeaders)return e;var n=this.headers;e=e.set("Content-Type","application/json");for(var r=Object.keys(this.headers),a=0;a<r.length;a++)e=e.set(r[a],n[r[a]]);return this._sendTelemetry&&(e=e.set("Auth0-Client",this.getTelemetryData())),e},Le.prototype.getTelemetryData=function(){var e=this._universalLoginPage?"auth0.js-ulp":"auth0.js",t={name:e,version:se.raw};this._telemetryInfo&&((t=be.extend({},this._telemetryInfo)).env=be.extend({},this._telemetryInfo.env),t.env[e]=se.raw);var n=JSON.stringify(t);return ie(n)},Le.prototype.get=function(e,t){return new Me(this.setCommonConfiguration(X.get(e),t))},Le.prototype.post=function(e,t){return new Me(this.setCommonConfiguration(X.post(e),t))},Le.prototype.patch=function(e,t){return new Me(this.setCommonConfiguration(X.patch(e),t))};var ke={redirect:function(e){Te().location=e},getDocument:function(){return Te().document},getWindow:Te,getOrigin:function(){var e=Te().location,t=e.origin;return t||(t=be.getOriginFromUrl(e.href)),t}};function xe(){}xe.prototype.getItem=function(){return null},xe.prototype.removeItem=function(){},xe.prototype.setItem=function(){};var Ee=o((function(e,t){var n;n=function(){function e(){for(var e=0,t={};e<arguments.length;e++){var n=arguments[e];for(var r in n)t[r]=n[r]}return t}function t(e){return e.replace(/(%[0-9A-Z]{2})+/g,decodeURIComponent)}return function n(r){function a(){}function o(t,n,o){if("undefined"!=typeof document){"number"==typeof(o=e({path:"/"},a.defaults,o)).expires&&(o.expires=new Date(1*new Date+864e5*o.expires)),o.expires=o.expires?o.expires.toUTCString():"";try{var i=JSON.stringify(n);/^[\{\[]/.test(i)&&(n=i)}catch(e){}n=r.write?r.write(n,t):encodeURIComponent(String(n)).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent),t=encodeURIComponent(String(t)).replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent).replace(/[\(\)]/g,escape);var s="";for(var u in o)o[u]&&(s+="; "+u,!0!==o[u]&&(s+="="+o[u].split(";")[0]));return document.cookie=t+"="+n+s}}function i(e,n){if("undefined"!=typeof document){for(var a={},o=document.cookie?document.cookie.split("; "):[],i=0;i<o.length;i++){var s=o[i].split("="),u=s.slice(1).join("=");n||'"'!==u.charAt(0)||(u=u.slice(1,-1));try{var l=t(s[0]);if(u=(r.read||r)(u,l)||t(u),n)try{u=JSON.parse(u)}catch(e){}if(a[l]=u,e===l)break}catch(e){}}return e?a[e]:a}}return a.set=o,a.get=function(e){return i(e,!1)},a.getJSON=function(e){return i(e,!0)},a.remove=function(t,n){o(t,"",e(n,{expires:-1}))},a.defaults={},a.withConverter=n,a}((function(){}))},e.exports=n()}));function Se(){}function Oe(e){this.disableWarnings=e.disableWarnings}function De(e){if(this.warn=new Oe({}),this.storage=new Se,!0===e.__tryLocalStorageFirst)try{var t=ke.getWindow().localStorage;t&&(this.storage=t)}catch(e){this.warn.warning(e),this.warn.warning("Can't use localStorage. Using CookieStorage instead.")}}function Ye(e){this.handler=new De(e)}function Ae(e){this.storage=new Ye(e)}function Ce(e,t){return{error:e,errorDescription:t}}Se.prototype.getItem=function(e){return Ee.get(e)},Se.prototype.removeItem=function(e){Ee.remove(e)},Se.prototype.setItem=function(e,t,n){var r=be.extend({expires:1},n);"https:"===ke.getWindow().location.protocol&&(r.secure=!0),Ee.set(e,t,r)},Oe.prototype.warning=function(e){this.disableWarnings||console.warn(e)},De.prototype.failover=function(){this.storage instanceof xe?this.warn.warning("DummyStorage: ignore failover"):this.storage instanceof Se?(this.warn.warning("CookieStorage: failing over DummyStorage"),this.storage=new xe):(this.warn.warning("LocalStorage: failing over CookieStorage"),this.storage=new Se)},De.prototype.getItem=function(e){try{return this.storage.getItem(e)}catch(t){return this.warn.warning(t),this.failover(),this.getItem(e)}},De.prototype.removeItem=function(e){try{return this.storage.removeItem(e)}catch(t){return this.warn.warning(t),this.failover(),this.removeItem(e)}},De.prototype.setItem=function(e,t,n){try{return this.storage.setItem(e,t,n)}catch(r){return this.warn.warning(r),this.failover(),this.setItem(e,t,n)}},Ye.prototype.getItem=function(e){var t=this.handler.getItem(e);try{return JSON.parse(t)}catch(e){return t}},Ye.prototype.removeItem=function(e){return this.handler.removeItem(e)},Ye.prototype.setItem=function(e,t,n){var r=JSON.stringify(t);return this.handler.setItem(e,r,n)},Ae.prototype.set=function(e,t){var n={lastUsedConnection:e,lastUsedSub:t};this.storage.setItem("auth0.ssodata",JSON.stringify(n))},Ae.prototype.get=function(){var e=this.storage.getItem("auth0.ssodata");if(e)return JSON.parse(e)};var je={buildResponse:Ce,invalidToken:function(e){return Ce("invalid_token",e)}};function Pe(e,t){return(t=t||{}).ignoreCasing=!!t.ignoreCasing&&t.ignoreCasing,function(n,r){var a;return n||r?(!n&&r.err&&(n=r.err,r=null),!n&&r.error&&(n=r,r=null),n?(a={original:n},be.updatePropertyOn(a,"original.response.req._data.password","*****"),n.response&&n.response.statusCode&&(a.statusCode=n.response.statusCode),n.response&&n.response.statusText&&(a.statusText=n.response.statusText),n.response&&n.response.body&&(n=n.response.body),n.err&&(n=n.err),a.code=n.code||n.error||n.error_code||n.status||null,a.description=n.errorDescription||n.error_description||n.description||n.error||n.details||n.err||null,t.forceLegacyError&&(a.error=a.code,a.error_description=a.description),n.error_codes&&n.error_details&&(a.errorDetails={codes:n.error_codes,details:n.error_details}),n.name&&(a.name=n.name),n.policy&&(a.policy=n.policy),e(a)):!r.type||"text/html"!==r.type&&"text/plain"!==r.type?t.ignoreCasing?e(null,r.body||r):e(null,be.toCamelCase(r.body||r,[],{keepOriginal:t.keepOriginalCasing})):e(null,r.text)):e(je.buildResponse("generic_error","Something went wrong"))}}var He=["realm","audience","otp","client_id","client_secret","redirect_uri","scope","code","grant_type","username","password","refresh_token","assertion","client_assertion","client_assertion_type","code_verifier"],Ie=["connection","connection_scope","auth0Client","owp","device","realm","organization","invitation","protocol","_csrf","_intstate","login_ticket","client_id","response_type","response_mode","redirect_uri","audience","scope","state","nonce","display","prompt","screen_hint","max_age","ui_locales","claims_locales","id_token_hint","login_hint","acr_values","claims","registration","request","request_uri","code_challenge","code_challenge_method","access_type","display"],Ne=function(e,t){return be.pick(t,He)},Re=function(e,t){var n=be.getKeysNotIn(t,Ie);return n.length>0&&e.warning("Following parameters are not allowed on the `/authorize` endpoint: ["+n.join(",")+"]"),t},Fe="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{};function ze(e){var t={exports:{}};return e(t,t.exports),t.exports}var Ue=ze((function(e,t){e.exports=function(){function e(e){return"function"==typeof e}var t=Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)},n=0,a=void 0,o=void 0,i=function(e,t){f[n]=e,f[n+1]=t,2===(n+=2)&&(o?o(h):v())},s="undefined"!=typeof window?window:void 0,u=s||{},l=u.MutationObserver||u.WebKitMutationObserver,c="undefined"==typeof self&&void 0!==r&&"[object process]"==={}.toString.call(r),d="undefined"!=typeof Uint8ClampedArray&&"undefined"!=typeof importScripts&&"undefined"!=typeof MessageChannel;function p(){var e=setTimeout;return function(){return e(h,1)}}var f=new Array(1e3);function h(){for(var e=0;e<n;e+=2)(0,f[e])(f[e+1]),f[e]=void 0,f[e+1]=void 0;n=0}var m,_,y,g,v=void 0;function b(e,t){var n=this,r=new this.constructor(L);void 0===r[M]&&j(r);var a=n._state;if(a){var o=arguments[a-1];i((function(){return A(a,r,o,n._result)}))}else D(n,r,e,t);return r}function w(e){if(e&&"object"==typeof e&&e.constructor===this)return e;var t=new this(L);return x(t,e),t}v=c?function(){return r.nextTick(h)}:l?(_=0,y=new l(h),g=document.createTextNode(""),y.observe(g,{characterData:!0}),function(){g.data=_=++_%2}):d?((m=new MessageChannel).port1.onmessage=h,function(){return m.port2.postMessage(0)}):void 0===s?function(){try{var e=Function("return this")().require("vertx");return void 0!==(a=e.runOnLoop||e.runOnContext)?function(){a(h)}:p()}catch(e){return p()}}():p();var M=Math.random().toString(36).substring(2);function L(){}var T=void 0;function k(t,n,r){n.constructor===t.constructor&&r===b&&n.constructor.resolve===w?function(e,t){1===t._state?S(e,t._result):2===t._state?O(e,t._result):D(t,void 0,(function(t){return x(e,t)}),(function(t){return O(e,t)}))}(t,n):void 0===r?S(t,n):e(r)?function(e,t,n){i((function(e){var r=!1,a=function(n,a,o,i){try{n.call(a,(function(n){r||(r=!0,t!==n?x(e,n):S(e,n))}),(function(t){r||(r=!0,O(e,t))}))}catch(e){return e}}(n,t);!r&&a&&(r=!0,O(e,a))}),e)}(t,n,r):S(t,n)}function x(e,t){if(e===t)O(e,new TypeError("You cannot resolve a promise with itself"));else if(a=typeof(r=t),null===r||"object"!==a&&"function"!==a)S(e,t);else{var n=void 0;try{n=t.then}catch(t){return void O(e,t)}k(e,t,n)}var r,a}function E(e){e._onerror&&e._onerror(e._result),Y(e)}function S(e,t){e._state===T&&(e._result=t,e._state=1,0!==e._subscribers.length&&i(Y,e))}function O(e,t){e._state===T&&(e._state=2,e._result=t,i(E,e))}function D(e,t,n,r){var a=e._subscribers,o=a.length;e._onerror=null,a[o]=t,a[o+1]=n,a[o+2]=r,0===o&&e._state&&i(Y,e)}function Y(e){var t=e._subscribers,n=e._state;if(0!==t.length){for(var r=void 0,a=void 0,o=e._result,i=0;i<t.length;i+=3)a=t[i+n],(r=t[i])?A(n,r,a,o):a(o);e._subscribers.length=0}}function A(t,n,r,a){var o=e(r),i=void 0,s=void 0,u=!0;if(o){try{i=r(a)}catch(t){u=!1,s=t}if(n===i)return void O(n,new TypeError("A promises callback cannot return that same promise."))}else i=a;n._state!==T||(o&&u?x(n,i):!1===u?O(n,s):1===t?S(n,i):2===t&&O(n,i))}var C=0;function j(e){e[M]=C++,e._state=void 0,e._result=void 0,e._subscribers=[]}var P=function(){function e(e,n){this._instanceConstructor=e,this.promise=new e(L),this.promise[M]||j(this.promise),t(n)?(this.length=n.length,this._remaining=n.length,this._result=new Array(this.length),0===this.length?S(this.promise,this._result):(this.length=this.length||0,this._enumerate(n),0===this._remaining&&S(this.promise,this._result))):O(this.promise,new Error("Array Methods must be provided an Array"))}return e.prototype._enumerate=function(e){for(var t=0;this._state===T&&t<e.length;t++)this._eachEntry(e[t],t)},e.prototype._eachEntry=function(e,t){var n=this._instanceConstructor,r=n.resolve;if(r===w){var a=void 0,o=void 0,i=!1;try{a=e.then}catch(e){i=!0,o=e}if(a===b&&e._state!==T)this._settledAt(e._state,t,e._result);else if("function"!=typeof a)this._remaining--,this._result[t]=e;else if(n===H){var s=new n(L);i?O(s,o):k(s,e,a),this._willSettleAt(s,t)}else this._willSettleAt(new n((function(t){return t(e)})),t)}else this._willSettleAt(r(e),t)},e.prototype._settledAt=function(e,t,n){var r=this.promise;r._state===T&&(this._remaining--,2===e?O(r,n):this._result[t]=n),0===this._remaining&&S(r,this._result)},e.prototype._willSettleAt=function(e,t){var n=this;D(e,void 0,(function(e){return n._settledAt(1,t,e)}),(function(e){return n._settledAt(2,t,e)}))},e}(),H=function(){function t(e){this[M]=C++,this._result=this._state=void 0,this._subscribers=[],L!==e&&("function"!=typeof e&&function(){throw new TypeError("You must pass a resolver function as the first argument to the promise constructor")}(),this instanceof t?function(e,t){try{t((function(t){x(e,t)}),(function(t){O(e,t)}))}catch(t){O(e,t)}}(this,e):function(){throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.")}())}return t.prototype.catch=function(e){return this.then(null,e)},t.prototype.finally=function(t){var n=this,r=n.constructor;return e(t)?n.then((function(e){return r.resolve(t()).then((function(){return e}))}),(function(e){return r.resolve(t()).then((function(){throw e}))})):n.then(t,t)},t}();return H.prototype.then=b,H.all=function(e){return new P(this,e).promise},H.race=function(e){var n=this;return t(e)?new n((function(t,r){for(var a=e.length,o=0;o<a;o++)n.resolve(e[o]).then(t,r)})):new n((function(e,t){return t(new TypeError("You must pass an array to race."))}))},H.resolve=w,H.reject=function(e){var t=new this(L);return O(t,e),t},H._setScheduler=function(e){o=e},H._setAsap=function(e){i=e},H._asap=i,H.polyfill=function(){var e=void 0;if(void 0!==Fe)e=Fe;else if("undefined"!=typeof self)e=self;else try{e=Function("return this")()}catch(e){throw new Error("polyfill failed because global object is unavailable in this environment")}var t=e.Promise;if(t){var n=null;try{n=Object.prototype.toString.call(t.resolve())}catch(e){}if("[object Promise]"===n&&!t.cast)return}e.Promise=H},H.Promise=H,H}()})),We=ze((function(e,t){var n;e.exports=n=n||function(e,t){var n=Object.create||function(){function e(){}return function(t){var n;return e.prototype=t,n=new e,e.prototype=null,n}}(),r={},a=r.lib={},o=a.Base={extend:function(e){var t=n(this);return e&&t.mixIn(e),t.hasOwnProperty("init")&&this.init!==t.init||(t.init=function(){t.$super.init.apply(this,arguments)}),t.init.prototype=t,t.$super=this,t},create:function(){var e=this.extend();return e.init.apply(e,arguments),e},init:function(){},mixIn:function(e){for(var t in e)e.hasOwnProperty(t)&&(this[t]=e[t]);e.hasOwnProperty("toString")&&(this.toString=e.toString)},clone:function(){return this.init.prototype.extend(this)}},i=a.WordArray=o.extend({init:function(e,t){e=this.words=e||[],this.sigBytes=null!=t?t:4*e.length},toString:function(e){return(e||u).stringify(this)},concat:function(e){var t=this.words,n=e.words,r=this.sigBytes,a=e.sigBytes;if(this.clamp(),r%4)for(var o=0;o<a;o++)t[r+o>>>2]|=(n[o>>>2]>>>24-o%4*8&255)<<24-(r+o)%4*8;else for(o=0;o<a;o+=4)t[r+o>>>2]=n[o>>>2];return this.sigBytes+=a,this},clamp:function(){var t=this.words,n=this.sigBytes;t[n>>>2]&=4294967295<<32-n%4*8,t.length=e.ceil(n/4)},clone:function(){var e=o.clone.call(this);return e.words=this.words.slice(0),e},random:function(t){for(var n,r=[],a=function(t){t=t;var n=987654321,r=4294967295;return function(){var a=((n=36969*(65535&n)+(n>>16)&r)<<16)+(t=18e3*(65535&t)+(t>>16)&r)&r;return a/=4294967296,(a+=.5)*(e.random()>.5?1:-1)}},o=0;o<t;o+=4){var s=a(4294967296*(n||e.random()));n=987654071*s(),r.push(4294967296*s()|0)}return new i.init(r,t)}}),s=r.enc={},u=s.Hex={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],a=0;a<n;a++){var o=t[a>>>2]>>>24-a%4*8&255;r.push((o>>>4).toString(16)),r.push((15&o).toString(16))}return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r<t;r+=2)n[r>>>3]|=parseInt(e.substr(r,2),16)<<24-r%8*4;return new i.init(n,t/2)}},l=s.Latin1={stringify:function(e){for(var t=e.words,n=e.sigBytes,r=[],a=0;a<n;a++)r.push(String.fromCharCode(t[a>>>2]>>>24-a%4*8&255));return r.join("")},parse:function(e){for(var t=e.length,n=[],r=0;r<t;r++)n[r>>>2]|=(255&e.charCodeAt(r))<<24-r%4*8;return new i.init(n,t)}},c=s.Utf8={stringify:function(e){try{return decodeURIComponent(escape(l.stringify(e)))}catch(e){throw new Error("Malformed UTF-8 data")}},parse:function(e){return l.parse(unescape(encodeURIComponent(e)))}},d=a.BufferedBlockAlgorithm=o.extend({reset:function(){this._data=new i.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=c.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var n=this._data,r=n.words,a=n.sigBytes,o=this.blockSize,s=a/(4*o),u=(s=t?e.ceil(s):e.max((0|s)-this._minBufferSize,0))*o,l=e.min(4*u,a);if(u){for(var c=0;c<u;c+=o)this._doProcessBlock(r,c);var d=r.splice(0,u);n.sigBytes-=l}return new i.init(d,l)},clone:function(){var e=o.clone.call(this);return e._data=this._data.clone(),e},_minBufferSize:0});a.Hasher=d.extend({cfg:o.extend(),init:function(e){this.cfg=this.cfg.extend(e),this.reset()},reset:function(){d.reset.call(this),this._doReset()},update:function(e){return this._append(e),this._process(),this},finalize:function(e){return e&&this._append(e),this._doFinalize()},blockSize:16,_createHelper:function(e){return function(t,n){return new e.init(n).finalize(t)}},_createHmacHelper:function(e){return function(t,n){return new p.HMAC.init(e,n).finalize(t)}}});var p=r.algo={};return r}(Math)})),Be=ze((function(e,t){var n;e.exports=(n=We,function(e){var t=n,r=t.lib,a=r.WordArray,o=r.Hasher,i=t.algo,s=[],u=[];!function(){function t(t){for(var n=e.sqrt(t),r=2;r<=n;r++)if(!(t%r))return!1;return!0}function n(e){return 4294967296*(e-(0|e))|0}for(var r=2,a=0;a<64;)t(r)&&(a<8&&(s[a]=n(e.pow(r,.5))),u[a]=n(e.pow(r,1/3)),a++),r++}();var l=[],c=i.SHA256=o.extend({_doReset:function(){this._hash=new a.init(s.slice(0))},_doProcessBlock:function(e,t){for(var n=this._hash.words,r=n[0],a=n[1],o=n[2],i=n[3],s=n[4],c=n[5],d=n[6],p=n[7],f=0;f<64;f++){if(f<16)l[f]=0|e[t+f];else{var h=l[f-15],m=l[f-2];l[f]=((h<<25|h>>>7)^(h<<14|h>>>18)^h>>>3)+l[f-7]+((m<<15|m>>>17)^(m<<13|m>>>19)^m>>>10)+l[f-16]}var _=r&a^r&o^a&o,y=p+((s<<26|s>>>6)^(s<<21|s>>>11)^(s<<7|s>>>25))+(s&c^~s&d)+u[f]+l[f];p=d,d=c,c=s,s=i+y|0,i=o,o=a,a=r,r=y+(((r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22))+_)|0}n[0]=n[0]+r|0,n[1]=n[1]+a|0,n[2]=n[2]+o|0,n[3]=n[3]+i|0,n[4]=n[4]+s|0,n[5]=n[5]+c|0,n[6]=n[6]+d|0,n[7]=n[7]+p|0},_doFinalize:function(){var t=this._data,n=t.words,r=8*this._nDataBytes,a=8*t.sigBytes;return n[a>>>5]|=128<<24-a%32,n[14+(a+64>>>9<<4)]=e.floor(r/4294967296),n[15+(a+64>>>9<<4)]=r,t.sigBytes=4*n.length,this._process(),this._hash},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});t.SHA256=o._createHelper(c),t.HmacSHA256=o._createHmacHelper(c)}(Math),n.SHA256)})),Ve=ze((function(e,t){var n,r;e.exports=(r=(n=We).lib.WordArray,n.enc.Base64={stringify:function(e){var t=e.words,n=e.sigBytes,r=this._map;e.clamp();for(var a=[],o=0;o<n;o+=3)for(var i=(t[o>>>2]>>>24-o%4*8&255)<<16|(t[o+1>>>2]>>>24-(o+1)%4*8&255)<<8|t[o+2>>>2]>>>24-(o+2)%4*8&255,s=0;s<4&&o+.75*s<n;s++)a.push(r.charAt(i>>>6*(3-s)&63));var u=r.charAt(64);if(u)for(;a.length%4;)a.push(u);return a.join("")},parse:function(e){var t=e.length,n=this._map,a=this._reverseMap;if(!a){a=this._reverseMap=[];for(var o=0;o<n.length;o++)a[n.charCodeAt(o)]=o}var i=n.charAt(64);if(i){var s=e.indexOf(i);-1!==s&&(t=s)}return function(e,t,n){for(var a=[],o=0,i=0;i<t;i++)if(i%4){var s=n[e.charCodeAt(i-1)]<<i%4*2,u=n[e.charCodeAt(i)]>>>6-i%4*2;a[o>>>2]|=(s|u)<<24-o%4*8,o++}return r.create(a,o)}(e,t,a)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="},n.enc.Base64)})),Ge=ze((function(e,t){e.exports=We.enc.Hex})),qe=ze((function(e,t){(function(){var t;function n(e,t,n){null!=e&&("number"==typeof e?this.fromNumber(e,t,n):this.fromString(e,null==t&&"string"!=typeof e?256:t))}function r(){return new n(null)}var a="undefined"!=typeof navigator;a&&"Microsoft Internet Explorer"==navigator.appName?(n.prototype.am=function(e,t,n,r,a,o){for(var i=32767&t,s=t>>15;--o>=0;){var u=32767&this[e],l=this[e++]>>15,c=s*u+l*i;a=((u=i*u+((32767&c)<<15)+n[r]+(1073741823&a))>>>30)+(c>>>15)+s*l+(a>>>30),n[r++]=1073741823&u}return a},t=30):a&&"Netscape"!=navigator.appName?(n.prototype.am=function(e,t,n,r,a,o){for(;--o>=0;){var i=t*this[e++]+n[r]+a;a=Math.floor(i/67108864),n[r++]=67108863&i}return a},t=26):(n.prototype.am=function(e,t,n,r,a,o){for(var i=16383&t,s=t>>14;--o>=0;){var u=16383&this[e],l=this[e++]>>14,c=s*u+l*i;a=((u=i*u+((16383&c)<<14)+n[r]+a)>>28)+(c>>14)+s*l,n[r++]=268435455&u}return a},t=28),n.prototype.DB=t,n.prototype.DM=(1<<t)-1,n.prototype.DV=1<<t,n.prototype.FV=Math.pow(2,52),n.prototype.F1=52-t,n.prototype.F2=2*t-52;var o,i,s=new Array;for(o="0".charCodeAt(0),i=0;i<=9;++i)s[o++]=i;for(o="a".charCodeAt(0),i=10;i<36;++i)s[o++]=i;for(o="A".charCodeAt(0),i=10;i<36;++i)s[o++]=i;function u(e){return"0123456789abcdefghijklmnopqrstuvwxyz".charAt(e)}function l(e,t){var n=s[e.charCodeAt(t)];return null==n?-1:n}function c(e){var t=r();return t.fromInt(e),t}function d(e){var t,n=1;return 0!=(t=e>>>16)&&(e=t,n+=16),0!=(t=e>>8)&&(e=t,n+=8),0!=(t=e>>4)&&(e=t,n+=4),0!=(t=e>>2)&&(e=t,n+=2),0!=(t=e>>1)&&(e=t,n+=1),n}function p(e){this.m=e}function f(e){this.m=e,this.mp=e.invDigit(),this.mpl=32767&this.mp,this.mph=this.mp>>15,this.um=(1<<e.DB-15)-1,this.mt2=2*e.t}function h(e,t){return e&t}function m(e,t){return e|t}function _(e,t){return e^t}function y(e,t){return e&~t}function g(e){if(0==e)return-1;var t=0;return 0==(65535&e)&&(e>>=16,t+=16),0==(255&e)&&(e>>=8,t+=8),0==(15&e)&&(e>>=4,t+=4),0==(3&e)&&(e>>=2,t+=2),0==(1&e)&&++t,t}function v(e){for(var t=0;0!=e;)e&=e-1,++t;return t}function b(){}function w(e){return e}function M(e){this.r2=r(),this.q3=r(),n.ONE.dlShiftTo(2*e.t,this.r2),this.mu=this.r2.divide(e),this.m=e}p.prototype.convert=function(e){return e.s<0||e.compareTo(this.m)>=0?e.mod(this.m):e},p.prototype.revert=function(e){return e},p.prototype.reduce=function(e){e.divRemTo(this.m,null,e)},p.prototype.mulTo=function(e,t,n){e.multiplyTo(t,n),this.reduce(n)},p.prototype.sqrTo=function(e,t){e.squareTo(t),this.reduce(t)},f.prototype.convert=function(e){var t=r();return e.abs().dlShiftTo(this.m.t,t),t.divRemTo(this.m,null,t),e.s<0&&t.compareTo(n.ZERO)>0&&this.m.subTo(t,t),t},f.prototype.revert=function(e){var t=r();return e.copyTo(t),this.reduce(t),t},f.prototype.reduce=function(e){for(;e.t<=this.mt2;)e[e.t++]=0;for(var t=0;t<this.m.t;++t){var n=32767&e[t],r=n*this.mpl+((n*this.mph+(e[t]>>15)*this.mpl&this.um)<<15)&e.DM;for(e[n=t+this.m.t]+=this.m.am(0,r,e,t,0,this.m.t);e[n]>=e.DV;)e[n]-=e.DV,e[++n]++}e.clamp(),e.drShiftTo(this.m.t,e),e.compareTo(this.m)>=0&&e.subTo(this.m,e)},f.prototype.mulTo=function(e,t,n){e.multiplyTo(t,n),this.reduce(n)},f.prototype.sqrTo=function(e,t){e.squareTo(t),this.reduce(t)},n.prototype.copyTo=function(e){for(var t=this.t-1;t>=0;--t)e[t]=this[t];e.t=this.t,e.s=this.s},n.prototype.fromInt=function(e){this.t=1,this.s=e<0?-1:0,e>0?this[0]=e:e<-1?this[0]=e+this.DV:this.t=0},n.prototype.fromString=function(e,t){var r;if(16==t)r=4;else if(8==t)r=3;else if(256==t)r=8;else if(2==t)r=1;else if(32==t)r=5;else{if(4!=t)return void this.fromRadix(e,t);r=2}this.t=0,this.s=0;for(var a=e.length,o=!1,i=0;--a>=0;){var s=8==r?255&e[a]:l(e,a);s<0?"-"==e.charAt(a)&&(o=!0):(o=!1,0==i?this[this.t++]=s:i+r>this.DB?(this[this.t-1]|=(s&(1<<this.DB-i)-1)<<i,this[this.t++]=s>>this.DB-i):this[this.t-1]|=s<<i,(i+=r)>=this.DB&&(i-=this.DB))}8==r&&0!=(128&e[0])&&(this.s=-1,i>0&&(this[this.t-1]|=(1<<this.DB-i)-1<<i)),this.clamp(),o&&n.ZERO.subTo(this,this)},n.prototype.clamp=function(){for(var e=this.s&this.DM;this.t>0&&this[this.t-1]==e;)--this.t},n.prototype.dlShiftTo=function(e,t){var n;for(n=this.t-1;n>=0;--n)t[n+e]=this[n];for(n=e-1;n>=0;--n)t[n]=0;t.t=this.t+e,t.s=this.s},n.prototype.drShiftTo=function(e,t){for(var n=e;n<this.t;++n)t[n-e]=this[n];t.t=Math.max(this.t-e,0),t.s=this.s},n.prototype.lShiftTo=function(e,t){var n,r=e%this.DB,a=this.DB-r,o=(1<<a)-1,i=Math.floor(e/this.DB),s=this.s<<r&this.DM;for(n=this.t-1;n>=0;--n)t[n+i+1]=this[n]>>a|s,s=(this[n]&o)<<r;for(n=i-1;n>=0;--n)t[n]=0;t[i]=s,t.t=this.t+i+1,t.s=this.s,t.clamp()},n.prototype.rShiftTo=function(e,t){t.s=this.s;var n=Math.floor(e/this.DB);if(n>=this.t)t.t=0;else{var r=e%this.DB,a=this.DB-r,o=(1<<r)-1;t[0]=this[n]>>r;for(var i=n+1;i<this.t;++i)t[i-n-1]|=(this[i]&o)<<a,t[i-n]=this[i]>>r;r>0&&(t[this.t-n-1]|=(this.s&o)<<a),t.t=this.t-n,t.clamp()}},n.prototype.subTo=function(e,t){for(var n=0,r=0,a=Math.min(e.t,this.t);n<a;)r+=this[n]-e[n],t[n++]=r&this.DM,r>>=this.DB;if(e.t<this.t){for(r-=e.s;n<this.t;)r+=this[n],t[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;n<e.t;)r-=e[n],t[n++]=r&this.DM,r>>=this.DB;r-=e.s}t.s=r<0?-1:0,r<-1?t[n++]=this.DV+r:r>0&&(t[n++]=r),t.t=n,t.clamp()},n.prototype.multiplyTo=function(e,t){var r=this.abs(),a=e.abs(),o=r.t;for(t.t=o+a.t;--o>=0;)t[o]=0;for(o=0;o<a.t;++o)t[o+r.t]=r.am(0,a[o],t,o,0,r.t);t.s=0,t.clamp(),this.s!=e.s&&n.ZERO.subTo(t,t)},n.prototype.squareTo=function(e){for(var t=this.abs(),n=e.t=2*t.t;--n>=0;)e[n]=0;for(n=0;n<t.t-1;++n){var r=t.am(n,t[n],e,2*n,0,1);(e[n+t.t]+=t.am(n+1,2*t[n],e,2*n+1,r,t.t-n-1))>=t.DV&&(e[n+t.t]-=t.DV,e[n+t.t+1]=1)}e.t>0&&(e[e.t-1]+=t.am(n,t[n],e,2*n,0,1)),e.s=0,e.clamp()},n.prototype.divRemTo=function(e,t,a){var o=e.abs();if(!(o.t<=0)){var i=this.abs();if(i.t<o.t)return null!=t&&t.fromInt(0),void(null!=a&&this.copyTo(a));null==a&&(a=r());var s=r(),u=this.s,l=e.s,c=this.DB-d(o[o.t-1]);c>0?(o.lShiftTo(c,s),i.lShiftTo(c,a)):(o.copyTo(s),i.copyTo(a));var p=s.t,f=s[p-1];if(0!=f){var h=f*(1<<this.F1)+(p>1?s[p-2]>>this.F2:0),m=this.FV/h,_=(1<<this.F1)/h,y=1<<this.F2,g=a.t,v=g-p,b=null==t?r():t;for(s.dlShiftTo(v,b),a.compareTo(b)>=0&&(a[a.t++]=1,a.subTo(b,a)),n.ONE.dlShiftTo(p,b),b.subTo(s,s);s.t<p;)s[s.t++]=0;for(;--v>=0;){var w=a[--g]==f?this.DM:Math.floor(a[g]*m+(a[g-1]+y)*_);if((a[g]+=s.am(0,w,a,v,0,p))<w)for(s.dlShiftTo(v,b),a.subTo(b,a);a[g]<--w;)a.subTo(b,a)}null!=t&&(a.drShiftTo(p,t),u!=l&&n.ZERO.subTo(t,t)),a.t=p,a.clamp(),c>0&&a.rShiftTo(c,a),u<0&&n.ZERO.subTo(a,a)}}},n.prototype.invDigit=function(){if(this.t<1)return 0;var e=this[0];if(0==(1&e))return 0;var t=3&e;return(t=(t=(t=(t=t*(2-(15&e)*t)&15)*(2-(255&e)*t)&255)*(2-((65535&e)*t&65535))&65535)*(2-e*t%this.DV)%this.DV)>0?this.DV-t:-t},n.prototype.isEven=function(){return 0==(this.t>0?1&this[0]:this.s)},n.prototype.exp=function(e,t){if(e>4294967295||e<1)return n.ONE;var a=r(),o=r(),i=t.convert(this),s=d(e)-1;for(i.copyTo(a);--s>=0;)if(t.sqrTo(a,o),(e&1<<s)>0)t.mulTo(o,i,a);else{var u=a;a=o,o=u}return t.revert(a)},n.prototype.toString=function(e){if(this.s<0)return"-"+this.negate().toString(e);var t;if(16==e)t=4;else if(8==e)t=3;else if(2==e)t=1;else if(32==e)t=5;else{if(4!=e)return this.toRadix(e);t=2}var n,r=(1<<t)-1,a=!1,o="",i=this.t,s=this.DB-i*this.DB%t;if(i-- >0)for(s<this.DB&&(n=this[i]>>s)>0&&(a=!0,o=u(n));i>=0;)s<t?(n=(this[i]&(1<<s)-1)<<t-s,n|=this[--i]>>(s+=this.DB-t)):(n=this[i]>>(s-=t)&r,s<=0&&(s+=this.DB,--i)),n>0&&(a=!0),a&&(o+=u(n));return a?o:"0"},n.prototype.negate=function(){var e=r();return n.ZERO.subTo(this,e),e},n.prototype.abs=function(){return this.s<0?this.negate():this},n.prototype.compareTo=function(e){var t=this.s-e.s;if(0!=t)return t;var n=this.t;if(0!=(t=n-e.t))return this.s<0?-t:t;for(;--n>=0;)if(0!=(t=this[n]-e[n]))return t;return 0},n.prototype.bitLength=function(){return this.t<=0?0:this.DB*(this.t-1)+d(this[this.t-1]^this.s&this.DM)},n.prototype.mod=function(e){var t=r();return this.abs().divRemTo(e,null,t),this.s<0&&t.compareTo(n.ZERO)>0&&e.subTo(t,t),t},n.prototype.modPowInt=function(e,t){var n;return n=e<256||t.isEven()?new p(t):new f(t),this.exp(e,n)},n.ZERO=c(0),n.ONE=c(1),b.prototype.convert=w,b.prototype.revert=w,b.prototype.mulTo=function(e,t,n){e.multiplyTo(t,n)},b.prototype.sqrTo=function(e,t){e.squareTo(t)},M.prototype.convert=function(e){if(e.s<0||e.t>2*this.m.t)return e.mod(this.m);if(e.compareTo(this.m)<0)return e;var t=r();return e.copyTo(t),this.reduce(t),t},M.prototype.revert=function(e){return e},M.prototype.reduce=function(e){for(e.drShiftTo(this.m.t-1,this.r2),e.t>this.m.t+1&&(e.t=this.m.t+1,e.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);e.compareTo(this.r2)<0;)e.dAddOffset(1,this.m.t+1);for(e.subTo(this.r2,e);e.compareTo(this.m)>=0;)e.subTo(this.m,e)},M.prototype.mulTo=function(e,t,n){e.multiplyTo(t,n),this.reduce(n)},M.prototype.sqrTo=function(e,t){e.squareTo(t),this.reduce(t)};var L,T,k,x=[2,3,5,7,11,13,17,19,23,29,31,37,41,43,47,53,59,61,67,71,73,79,83,89,97,101,103,107,109,113,127,131,137,139,149,151,157,163,167,173,179,181,191,193,197,199,211,223,227,229,233,239,241,251,257,263,269,271,277,281,283,293,307,311,313,317,331,337,347,349,353,359,367,373,379,383,389,397,401,409,419,421,431,433,439,443,449,457,461,463,467,479,487,491,499,503,509,521,523,541,547,557,563,569,571,577,587,593,599,601,607,613,617,619,631,641,643,647,653,659,661,673,677,683,691,701,709,719,727,733,739,743,751,757,761,769,773,787,797,809,811,821,823,827,829,839,853,857,859,863,877,881,883,887,907,911,919,929,937,941,947,953,967,971,977,983,991,997],E=(1<<26)/x[x.length-1];function S(){var e;e=(new Date).getTime(),T[k++]^=255&e,T[k++]^=e>>8&255,T[k++]^=e>>16&255,T[k++]^=e>>24&255,k>=P&&(k-=P)}if(n.prototype.chunkSize=function(e){return Math.floor(Math.LN2*this.DB/Math.log(e))},n.prototype.toRadix=function(e){if(null==e&&(e=10),0==this.signum()||e<2||e>36)return"0";var t=this.chunkSize(e),n=Math.pow(e,t),a=c(n),o=r(),i=r(),s="";for(this.divRemTo(a,o,i);o.signum()>0;)s=(n+i.intValue()).toString(e).substr(1)+s,o.divRemTo(a,o,i);return i.intValue().toString(e)+s},n.prototype.fromRadix=function(e,t){this.fromInt(0),null==t&&(t=10);for(var r=this.chunkSize(t),a=Math.pow(t,r),o=!1,i=0,s=0,u=0;u<e.length;++u){var c=l(e,u);c<0?"-"==e.charAt(u)&&0==this.signum()&&(o=!0):(s=t*s+c,++i>=r&&(this.dMultiply(a),this.dAddOffset(s,0),i=0,s=0))}i>0&&(this.dMultiply(Math.pow(t,i)),this.dAddOffset(s,0)),o&&n.ZERO.subTo(this,this)},n.prototype.fromNumber=function(e,t,r){if("number"==typeof t)if(e<2)this.fromInt(1);else for(this.fromNumber(e,r),this.testBit(e-1)||this.bitwiseTo(n.ONE.shiftLeft(e-1),m,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(t);)this.dAddOffset(2,0),this.bitLength()>e&&this.subTo(n.ONE.shiftLeft(e-1),this);else{var a=new Array,o=7&e;a.length=1+(e>>3),t.nextBytes(a),o>0?a[0]&=(1<<o)-1:a[0]=0,this.fromString(a,256)}},n.prototype.bitwiseTo=function(e,t,n){var r,a,o=Math.min(e.t,this.t);for(r=0;r<o;++r)n[r]=t(this[r],e[r]);if(e.t<this.t){for(a=e.s&this.DM,r=o;r<this.t;++r)n[r]=t(this[r],a);n.t=this.t}else{for(a=this.s&this.DM,r=o;r<e.t;++r)n[r]=t(a,e[r]);n.t=e.t}n.s=t(this.s,e.s),n.clamp()},n.prototype.changeBit=function(e,t){var r=n.ONE.shiftLeft(e);return this.bitwiseTo(r,t,r),r},n.prototype.addTo=function(e,t){for(var n=0,r=0,a=Math.min(e.t,this.t);n<a;)r+=this[n]+e[n],t[n++]=r&this.DM,r>>=this.DB;if(e.t<this.t){for(r+=e.s;n<this.t;)r+=this[n],t[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;n<e.t;)r+=e[n],t[n++]=r&this.DM,r>>=this.DB;r+=e.s}t.s=r<0?-1:0,r>0?t[n++]=r:r<-1&&(t[n++]=this.DV+r),t.t=n,t.clamp()},n.prototype.dMultiply=function(e){this[this.t]=this.am(0,e-1,this,0,0,this.t),++this.t,this.clamp()},n.prototype.dAddOffset=function(e,t){if(0!=e){for(;this.t<=t;)this[this.t++]=0;for(this[t]+=e;this[t]>=this.DV;)this[t]-=this.DV,++t>=this.t&&(this[this.t++]=0),++this[t]}},n.prototype.multiplyLowerTo=function(e,t,n){var r,a=Math.min(this.t+e.t,t);for(n.s=0,n.t=a;a>0;)n[--a]=0;for(r=n.t-this.t;a<r;++a)n[a+this.t]=this.am(0,e[a],n,a,0,this.t);for(r=Math.min(e.t,t);a<r;++a)this.am(0,e[a],n,a,0,t-a);n.clamp()},n.prototype.multiplyUpperTo=function(e,t,n){--t;var r=n.t=this.t+e.t-t;for(n.s=0;--r>=0;)n[r]=0;for(r=Math.max(t-this.t,0);r<e.t;++r)n[this.t+r-t]=this.am(t-r,e[r],n,0,0,this.t+r-t);n.clamp(),n.drShiftTo(1,n)},n.prototype.modInt=function(e){if(e<=0)return 0;var t=this.DV%e,n=this.s<0?e-1:0;if(this.t>0)if(0==t)n=this[0]%e;else for(var r=this.t-1;r>=0;--r)n=(t*n+this[r])%e;return n},n.prototype.millerRabin=function(e){var t=this.subtract(n.ONE),a=t.getLowestSetBit();if(a<=0)return!1;var o=t.shiftRight(a);(e=e+1>>1)>x.length&&(e=x.length);for(var i=r(),s=0;s<e;++s){i.fromInt(x[Math.floor(Math.random()*x.length)]);var u=i.modPow(o,this);if(0!=u.compareTo(n.ONE)&&0!=u.compareTo(t)){for(var l=1;l++<a&&0!=u.compareTo(t);)if(0==(u=u.modPowInt(2,this)).compareTo(n.ONE))return!1;if(0!=u.compareTo(t))return!1}}return!0},n.prototype.clone=function(){var e=r();return this.copyTo(e),e},n.prototype.intValue=function(){if(this.s<0){if(1==this.t)return this[0]-this.DV;if(0==this.t)return-1}else{if(1==this.t)return this[0];if(0==this.t)return 0}return(this[1]&(1<<32-this.DB)-1)<<this.DB|this[0]},n.prototype.byteValue=function(){return 0==this.t?this.s:this[0]<<24>>24},n.prototype.shortValue=function(){return 0==this.t?this.s:this[0]<<16>>16},n.prototype.signum=function(){return this.s<0?-1:this.t<=0||1==this.t&&this[0]<=0?0:1},n.prototype.toByteArray=function(){var e=this.t,t=new Array;t[0]=this.s;var n,r=this.DB-e*this.DB%8,a=0;if(e-- >0)for(r<this.DB&&(n=this[e]>>r)!=(this.s&this.DM)>>r&&(t[a++]=n|this.s<<this.DB-r);e>=0;)r<8?(n=(this[e]&(1<<r)-1)<<8-r,n|=this[--e]>>(r+=this.DB-8)):(n=this[e]>>(r-=8)&255,r<=0&&(r+=this.DB,--e)),0!=(128&n)&&(n|=-256),0==a&&(128&this.s)!=(128&n)&&++a,(a>0||n!=this.s)&&(t[a++]=n);return t},n.prototype.equals=function(e){return 0==this.compareTo(e)},n.prototype.min=function(e){return this.compareTo(e)<0?this:e},n.prototype.max=function(e){return this.compareTo(e)>0?this:e},n.prototype.and=function(e){var t=r();return this.bitwiseTo(e,h,t),t},n.prototype.or=function(e){var t=r();return this.bitwiseTo(e,m,t),t},n.prototype.xor=function(e){var t=r();return this.bitwiseTo(e,_,t),t},n.prototype.andNot=function(e){var t=r();return this.bitwiseTo(e,y,t),t},n.prototype.not=function(){for(var e=r(),t=0;t<this.t;++t)e[t]=this.DM&~this[t];return e.t=this.t,e.s=~this.s,e},n.prototype.shiftLeft=function(e){var t=r();return e<0?this.rShiftTo(-e,t):this.lShiftTo(e,t),t},n.prototype.shiftRight=function(e){var t=r();return e<0?this.lShiftTo(-e,t):this.rShiftTo(e,t),t},n.prototype.getLowestSetBit=function(){for(var e=0;e<this.t;++e)if(0!=this[e])return e*this.DB+g(this[e]);return this.s<0?this.t*this.DB:-1},n.prototype.bitCount=function(){for(var e=0,t=this.s&this.DM,n=0;n<this.t;++n)e+=v(this[n]^t);return e},n.prototype.testBit=function(e){var t=Math.floor(e/this.DB);return t>=this.t?0!=this.s:0!=(this[t]&1<<e%this.DB)},n.prototype.setBit=function(e){return this.changeBit(e,m)},n.prototype.clearBit=function(e){return this.changeBit(e,y)},n.prototype.flipBit=function(e){return this.changeBit(e,_)},n.prototype.add=function(e){var t=r();return this.addTo(e,t),t},n.prototype.subtract=function(e){var t=r();return this.subTo(e,t),t},n.prototype.multiply=function(e){var t=r();return this.multiplyTo(e,t),t},n.prototype.divide=function(e){var t=r();return this.divRemTo(e,t,null),t},n.prototype.remainder=function(e){var t=r();return this.divRemTo(e,null,t),t},n.prototype.divideAndRemainder=function(e){var t=r(),n=r();return this.divRemTo(e,t,n),new Array(t,n)},n.prototype.modPow=function(e,t){var n,a,o=e.bitLength(),i=c(1);if(o<=0)return i;n=o<18?1:o<48?3:o<144?4:o<768?5:6,a=o<8?new p(t):t.isEven()?new M(t):new f(t);var s=new Array,u=3,l=n-1,h=(1<<n)-1;if(s[1]=a.convert(this),n>1){var m=r();for(a.sqrTo(s[1],m);u<=h;)s[u]=r(),a.mulTo(m,s[u-2],s[u]),u+=2}var _,y,g=e.t-1,v=!0,b=r();for(o=d(e[g])-1;g>=0;){for(o>=l?_=e[g]>>o-l&h:(_=(e[g]&(1<<o+1)-1)<<l-o,g>0&&(_|=e[g-1]>>this.DB+o-l)),u=n;0==(1&_);)_>>=1,--u;if((o-=u)<0&&(o+=this.DB,--g),v)s[_].copyTo(i),v=!1;else{for(;u>1;)a.sqrTo(i,b),a.sqrTo(b,i),u-=2;u>0?a.sqrTo(i,b):(y=i,i=b,b=y),a.mulTo(b,s[_],i)}for(;g>=0&&0==(e[g]&1<<o);)a.sqrTo(i,b),y=i,i=b,b=y,--o<0&&(o=this.DB-1,--g)}return a.revert(i)},n.prototype.modInverse=function(e){var t=e.isEven();if(this.isEven()&&t||0==e.signum())return n.ZERO;for(var r=e.clone(),a=this.clone(),o=c(1),i=c(0),s=c(0),u=c(1);0!=r.signum();){for(;r.isEven();)r.rShiftTo(1,r),t?(o.isEven()&&i.isEven()||(o.addTo(this,o),i.subTo(e,i)),o.rShiftTo(1,o)):i.isEven()||i.subTo(e,i),i.rShiftTo(1,i);for(;a.isEven();)a.rShiftTo(1,a),t?(s.isEven()&&u.isEven()||(s.addTo(this,s),u.subTo(e,u)),s.rShiftTo(1,s)):u.isEven()||u.subTo(e,u),u.rShiftTo(1,u);r.compareTo(a)>=0?(r.subTo(a,r),t&&o.subTo(s,o),i.subTo(u,i)):(a.subTo(r,a),t&&s.subTo(o,s),u.subTo(i,u))}return 0!=a.compareTo(n.ONE)?n.ZERO:u.compareTo(e)>=0?u.subtract(e):u.signum()<0?(u.addTo(e,u),u.signum()<0?u.add(e):u):u},n.prototype.pow=function(e){return this.exp(e,new b)},n.prototype.gcd=function(e){var t=this.s<0?this.negate():this.clone(),n=e.s<0?e.negate():e.clone();if(t.compareTo(n)<0){var r=t;t=n,n=r}var a=t.getLowestSetBit(),o=n.getLowestSetBit();if(o<0)return t;for(a<o&&(o=a),o>0&&(t.rShiftTo(o,t),n.rShiftTo(o,n));t.signum()>0;)(a=t.getLowestSetBit())>0&&t.rShiftTo(a,t),(a=n.getLowestSetBit())>0&&n.rShiftTo(a,n),t.compareTo(n)>=0?(t.subTo(n,t),t.rShiftTo(1,t)):(n.subTo(t,n),n.rShiftTo(1,n));return o>0&&n.lShiftTo(o,n),n},n.prototype.isProbablePrime=function(e){var t,n=this.abs();if(1==n.t&&n[0]<=x[x.length-1]){for(t=0;t<x.length;++t)if(n[0]==x[t])return!0;return!1}if(n.isEven())return!1;for(t=1;t<x.length;){for(var r=x[t],a=t+1;a<x.length&&r<E;)r*=x[a++];for(r=n.modInt(r);t<a;)if(r%x[t++]==0)return!1}return n.millerRabin(e)},n.prototype.square=function(){var e=r();return this.squareTo(e),e},n.prototype.Barrett=M,null==T){var O;if(T=new Array,k=0,"undefined"!=typeof window&&window.crypto)if(window.crypto.getRandomValues){var D=new Uint8Array(32);for(window.crypto.getRandomValues(D),O=0;O<32;++O)T[k++]=D[O]}else if("Netscape"==navigator.appName&&navigator.appVersion<"5"){var Y=window.crypto.random(32);for(O=0;O<Y.length;++O)T[k++]=255&Y.charCodeAt(O)}for(;k<P;)O=Math.floor(65536*Math.random()),T[k++]=O>>>8,T[k++]=255&O;k=0,S()}function A(){if(null==L){for(S(),(L=new j).init(T),k=0;k<T.length;++k)T[k]=0;k=0}return L.next()}function C(){}function j(){this.i=0,this.j=0,this.S=new Array}C.prototype.nextBytes=function(e){var t;for(t=0;t<e.length;++t)e[t]=A()},j.prototype.init=function(e){var t,n,r;for(t=0;t<256;++t)this.S[t]=t;for(n=0,t=0;t<256;++t)r=this.S[t],this.S[t]=this.S[n=n+this.S[t]+e[t%e.length]&255],this.S[n]=r;this.i=0,this.j=0},j.prototype.next=function(){var e;return this.i=this.i+1&255,this.j=this.j+this.S[this.i]&255,e=this.S[this.i],this.S[this.i]=this.S[this.j],this.S[this.j]=e,this.S[e+this.S[this.i]&255]};var P=256;e.exports={default:n,BigInteger:n,SecureRandom:C}}).call(Fe)})),Je={sha1:"3021300906052b0e03021a05000414",sha224:"302d300d06096086480165030402040500041c",sha256:"3031300d060960864801650304020105000420",sha384:"3041300d060960864801650304020205000430",sha512:"3051300d060960864801650304020305000440",md2:"3020300c06082a864886f70d020205000410",md5:"3020300c06082a864886f70d020505000410",ripemd160:"3021300906052b2403020105000414"},Ke={sha256:Be};function $e(e,t){if(this.n=null,this.e=0,!(null!=e&&null!=t&&e.length>0&&t.length>0))throw new Error("Invalid key data");this.n=new qe.BigInteger(e,16),this.e=parseInt(t,16)}$e.prototype.verify=function(e,t){t=t.replace(/[^0-9a-f]|[\s\n]]/gi,"");var n=new qe.BigInteger(t,16);if(n.bitLength()>this.n.bitLength())throw new Error("Signature does not match with the key modulus.");var r=function(e){for(var t in Je){var n=Je[t],r=n.length;if(e.substring(0,r)===n)return{alg:t,hash:e.substring(r)}}return[]}(n.modPowInt(this.e,this.n).toString(16).replace(/^1f+00/,""));if(0===r.length)return!1;if(!Ke.hasOwnProperty(r.alg))throw new Error("Hashing algorithm is not supported.");var a=Ke[r.alg](e).toString();return r.hash===a};for(var Xe=[],Ze=[],Qe="undefined"!=typeof Uint8Array?Uint8Array:Array,et="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",tt=0,nt=et.length;tt<nt;++tt)Xe[tt]=et[tt],Ze[et.charCodeAt(tt)]=tt;Ze["-".charCodeAt(0)]=62,Ze["_".charCodeAt(0)]=63;var rt=function(e){var t,n,r=function(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}(e),a=r[0],o=r[1],i=new Qe(function(e,t,n){return 3*(t+n)/4-n}(0,a,o)),s=0,u=o>0?a-4:a;for(n=0;n<u;n+=4)t=Ze[e.charCodeAt(n)]<<18|Ze[e.charCodeAt(n+1)]<<12|Ze[e.charCodeAt(n+2)]<<6|Ze[e.charCodeAt(n+3)],i[s++]=t>>16&255,i[s++]=t>>8&255,i[s++]=255&t;return 2===o&&(t=Ze[e.charCodeAt(n)]<<2|Ze[e.charCodeAt(n+1)]>>4,i[s++]=255&t),1===o&&(t=Ze[e.charCodeAt(n)]<<10|Ze[e.charCodeAt(n+1)]<<4|Ze[e.charCodeAt(n+2)]>>2,i[s++]=t>>8&255,i[s++]=255&t),i};function at(e){var t=e.length%4;return 0===t?e:e+new Array(4-t+1).join("=")}function ot(e){return e=at(e).replace(/\-/g,"+").replace(/_/g,"/"),decodeURIComponent(function(e){for(var t="",n=0;n<e.length;n++)t+=String.fromCharCode(e[n]);return t}(rt(e)).split("").map((function(e){return"%"+("00"+e.charCodeAt(0).toString(16)).slice(-2)})).join(""))}function it(e){return function(e){for(var t="",n=0;n<e.length;n++){var r=e[n].toString(16);t+=2===r.length?r:"0"+r}return t}(rt(at(e)))}var st=ze((function(e){var t,n;t=Fe,n=function(){function e(e){var t=[];if(0===e.length)return"";if("string"!=typeof e[0])throw new TypeError("Url must be a string. Received "+e[0]);if(e[0].match(/^[^/:]+:\/*$/)&&e.length>1){var n=e.shift();e[0]=n+e[0]}e[0]=e[0].match(/^file:\/\/\//)?e[0].replace(/^([^/:]+):\/*/,"$1:///"):e[0].replace(/^([^/:]+):\/*/,"$1://");for(var r=0;r<e.length;r++){var a=e[r];if("string"!=typeof a)throw new TypeError("Url must be a string. Received "+a);""!==a&&(r>0&&(a=a.replace(/^[\/]+/,"")),a=a.replace(/[\/]+$/,r<e.length-1?"":"/"),t.push(a))}var o=t.join("/"),i=(o=o.replace(/\/(\?|&|#[^!])/g,"$1")).split("?");return i.shift()+(i.length>0?"?":"")+i.join("&")}return function(){return e("object"==typeof arguments[0]?arguments[0]:[].slice.call(arguments))}},e.exports?e.exports=n():t.urljoin=n()}));function ut(e,t){return t=t||{},new Promise((function(n,r){var a=new XMLHttpRequest,o=[],i=[],s={},u=function(){return{ok:2==(a.status/100|0),statusText:a.statusText,status:a.status,url:a.responseURL,text:function(){return Promise.resolve(a.responseText)},json:function(){return Promise.resolve(JSON.parse(a.responseText))},blob:function(){return Promise.resolve(new Blob([a.response]))},clone:u,headers:{keys:function(){return o},entries:function(){return i},get:function(e){return s[e.toLowerCase()]},has:function(e){return e.toLowerCase()in s}}}};for(var l in a.open(t.method||"get",e,!0),a.onload=function(){a.getAllResponseHeaders().replace(/^(.*?):[^\S\n]*([\s\S]*?)$/gm,(function(e,t,n){o.push(t=t.toLowerCase()),i.push([t,n]),s[t]=s[t]?s[t]+","+n:n})),n(u())},a.onerror=r,a.withCredentials="include"==t.credentials,t.headers)a.setRequestHeader(l,t.headers[l]);a.send(t.body||null)}))}function lt(e){if(e.ok)return e.json();var t=new Error(e.statusText);return t.response=e,Promise.reject(t)}function ct(e){this.name="ConfigurationError",this.message=e||""}function dt(e){this.name="TokenValidationError",this.message=e||""}ct.prototype=Error.prototype,dt.prototype=Error.prototype;var pt=function(){function e(){}var t=e.prototype;return t.get=function(){return null},t.has=function(){return null},t.set=function(){return null},e}();Ue.polyfill();var ft=function(e){return"number"==typeof e},ht=function(){return new Date};function mt(e){var t=e||{};if(this.jwksCache=t.jwksCache||new pt,this.expectedAlg=t.expectedAlg||"RS256",this.issuer=t.issuer,this.audience=t.audience,this.leeway=0===t.leeway?0:t.leeway||60,this.jwksURI=t.jwksURI,this.maxAge=t.maxAge,this.__clock="function"==typeof t.__clock?t.__clock:ht,this.leeway<0||this.leeway>300)throw new ct("The leeway should be positive and lower than five minutes.");if("RS256"!==this.expectedAlg)throw new ct('Signature algorithm of "'+this.expectedAlg+'" is not supported. Expected the ID token to be signed with "RS256".')}function _t(e,t){this.plugins=t;for(var n=0;n<this.plugins.length;n++){if(this.plugins[n].version!==se.raw){var r="";throw this.plugins[n].constructor&&this.plugins[n].constructor.name&&(r=this.plugins[n].constructor.name),new Error("Plugin "+r+" version ("+this.plugins[n].version+") is not compatible with the SDK version ("+se.raw+")")}this.plugins[n].setWebAuth(e)}}mt.prototype.verify=function(e,t,n){if(!n&&t&&"function"==typeof t&&(n=t,t=void 0),!e)return n(new dt("ID token is required but missing"),null);var r=this.decode(e);if(r instanceof Error)return n(new dt("ID token could not be decoded"),null);var a=r.encoded.header+"."+r.encoded.payload,o=it(r.encoded.signature),i=r.header.alg,s=r.header.kid,u=r.payload.aud,l=r.payload.sub,c=r.payload.iss,d=r.payload.exp,p=r.payload.nbf,f=r.payload.iat,h=r.payload.azp,m=r.payload.auth_time,_=r.payload.nonce,y=this.__clock(),g=this;if(g.expectedAlg!==i)return n(new dt('Signature algorithm of "'+i+'" is not supported. Expected the ID token to be signed with "RS256".'),null);this.getRsaVerifier(c,s,(function(e,i){if(e)return n(e,null);if(!i.verify(a,o))return n(new dt("Invalid ID token signature."),null);if(!c||"string"!=typeof c)return n(new dt("Issuer (iss) claim must be a string present in the ID token"),null);if(g.issuer!==c)return n(new dt('Issuer (iss) claim mismatch in the ID token, expected "'+g.issuer+'", found "'+c+'"'),null);if(!l||"string"!=typeof l)return n(new dt("Subject (sub) claim must be a string present in the ID token"),null);if(!u||"string"!=typeof u&&!Array.isArray(u))return n(new dt("Audience (aud) claim must be a string or array of strings present in the ID token"),null);if(Array.isArray(u)&&!u.includes(g.audience))return n(new dt('Audience (aud) claim mismatch in the ID token; expected "'+g.audience+'" but was not one of "'+u.join(", ")+'"'),null);if("string"==typeof u&&g.audience!==u)return n(new dt('Audience (aud) claim mismatch in the ID token; expected "'+g.audience+'" but found "'+u+'"'),null);if(t){if(!_||"string"!=typeof _)return n(new dt("Nonce (nonce) claim must be a string present in the ID token"),null);if(_!==t)return n(new dt('Nonce (nonce) claim value mismatch in the ID token; expected "'+t+'", found "'+_+'"'),null)}if(Array.isArray(u)&&u.length>1){if(!h||"string"!=typeof h)return n(new dt("Authorized Party (azp) claim must be a string present in the ID token when Audience (aud) claim has multiple values"),null);if(h!==g.audience)return n(new dt('Authorized Party (azp) claim mismatch in the ID token; expected "'+g.audience+'", found "'+h+'"'),null)}if(!d||!ft(d))return n(new dt("Expiration Time (exp) claim must be a number present in the ID token"),null);if(!f||!ft(f))return n(new dt("Issued At (iat) claim must be a number present in the ID token"),null);var s=d+g.leeway,v=new Date(0);if(v.setUTCSeconds(s),y>v)return n(new dt('Expiration Time (exp) claim error in the ID token; current time "'+y+'" is after expiration time "'+v+'"'),null);if(p&&ft(p)){var b=p-g.leeway,w=new Date(0);if(w.setUTCSeconds(b),y<w)return n(new dt('Not Before Time (nbf) claim error in the ID token; current time "'+y+'" is before the not before time "'+w+'"'),null)}if(g.maxAge){if(!m||!ft(m))return n(new dt("Authentication Time (auth_time) claim must be a number present in the ID token when Max Age (max_age) is specified"),null);var M=m+g.maxAge+g.leeway,L=new Date(0);if(L.setUTCSeconds(M),y>L)return n(new dt('Authentication Time (auth_time) claim in the ID token indicates that too much time has passed since the last end-user authentication. Current time "'+y+'" is after last auth time at "'+L+'"'),null)}return n(null,r.payload)}))},mt.prototype.getRsaVerifier=function(e,t,n){var r=this,a=e+t;Promise.resolve(this.jwksCache.has(a)).then((function(n){return n?r.jwksCache.get(a):(o={jwksURI:r.jwksURI,iss:e,kid:t},("undefined"==typeof fetch?ut:fetch)(o.jwksURI||st(o.iss,".well-known","jwks.json")).then(lt).then((function(e){var t,n,r,a=null;for(t=0;t<e.keys.length&&null===a;t++)(n=e.keys[t]).kid===o.kid&&(a=n);if(!a)throw new Error('Could not find a public key for Key ID (kid) "'+o.kid+'"');return{modulus:it((r=a).n),exp:it(r.e)}})).catch((function(e){throw e})));var o})).then((function(e){if(!e||!e.modulus||!e.exp)throw new Error("Empty keyInfo in response");return Promise.resolve(r.jwksCache.set(a,e)).then((function(){n&&n(null,new $e(e.modulus,e.exp))}))})).catch((function(e){n&&n(e)}))},mt.prototype.decode=function(e){var t,n,r=e.split(".");if(3!==r.length)return new dt("Cannot decode a malformed JWT");try{t=JSON.parse(ot(r[0])),n=JSON.parse(ot(r[1]))}catch(e){return new dt("Token header or payload is not valid JSON")}return{header:t,payload:n,encoded:{header:r[0],payload:r[1],signature:r[2]}}},mt.prototype.validateAccessToken=function(e,t,n,r){if(this.expectedAlg!==t)return r(new dt('Signature algorithm of "'+t+'" is not supported. Expected "'+this.expectedAlg+'"'));var a,o=Be(e),i=Ge.stringify(o),s=i.substring(0,i.length/2),u=Ge.parse(s),l=Ve.stringify(u);return r((a={"+":"-","/":"_","=":""},l.replace(/[+/=]/g,(function(e){return a[e]}))!==n?new dt("Invalid access_token"):null))},_t.prototype.get=function(e){for(var t=0;t<this.plugins.length;t++)if(this.plugins[t].supports(e))return this.plugins[t].init();return null};var yt=function(e){var t=new Uint8Array(e),n=[],r="0123456789ABCDEFGHIJKLMNOPQRSTUVXYZabcdefghijklmnopqrstuvwxyz-._~",a=ke.getWindow().crypto||ke.getWindow().msCrypto;if(!a)return null;for(var o=a.getRandomValues(t),i=0;i<o.length;i++)n.push(r[o[i]%r.length]);return n.join("")};function gt(e){var t=e.transaction||{};this.namespace=t.namespace||"com.auth0.auth.",this.keyLength=t.keyLength||32,this.storage=new Ye(e),this.options=e}function vt(e){if(this.url=e.url,this.callback=e.callback,this.timeout=e.timeout||6e4,this.timeoutCallback=e.timeoutCallback||null,this.eventListenerType=e.eventListenerType||"message",this.iframe=null,this.timeoutHandle=null,this._destroyTimeout=null,this.transientMessageEventListener=null,this.proxyEventListener=null,this.eventValidator=e.eventValidator||{isValid:function(){return!0}},"function"!=typeof this.callback)throw new Error("options.callback must be a function")}function bt(e){this.webAuth=e,this.warn=new Oe(e.baseOptions)}function wt(e,t){this.webAuth=e,this.baseOptions=t,this.request=new Le(t),this.webMessageHandler=new bt(e),this.storage=new Ye(t)}function Mt(e,t){return["co/verifier",encodeURIComponent(e),encodeURIComponent(t)].join("/")}function Lt(e,t){this.webAuth=e,this.baseOptions=t,this.crossOriginAuthentication=new wt(e,this.baseOptions),this.warn=new Oe({disableWarnings:!!t._disableDeprecationWarnings})}gt.prototype.process=function(e){if(!e.responseType)throw new Error("responseType is required");var t=e.realm||e.connection,n=-1!==e.responseType.indexOf("id_token"),r=this.generateTransaction(e.appState,e.state,e.nonce,t,n,e.organization);return e.state||(e.state=r.state),n&&!e.nonce&&(e.nonce=r.nonce),e},gt.prototype.generateTransaction=function(e,t,n,r,a,o){if(t=t||yt(this.keyLength),n=n||(a?yt(this.keyLength):null),ke.getWindow().location.host!==this.options.domain){var i={nonce:n,appState:e,state:t,lastUsedConnection:r};o&&(i.organization=o),this.storage.setItem(this.namespace+t,i,{expires:1/48})}return{state:t,nonce:n}},gt.prototype.getStoredTransaction=function(e){var t;return t=this.storage.getItem(this.namespace+e),this.clearTransaction(e),t},gt.prototype.clearTransaction=function(e){this.storage.removeItem(this.namespace+e)},vt.prototype.init=function(){var e=this,t=ke.getWindow();switch(this.iframe=t.document.createElement("iframe"),this.iframe.style.display="none",this.proxyEventListener=function(t){e.eventListener(t)},this.eventListenerType){case"message":this.eventSourceObject=t;break;case"load":this.eventSourceObject=this.iframe;break;default:throw new Error("Unsupported event listener type: "+this.eventListenerType)}this.eventSourceObject.addEventListener(this.eventListenerType,this.proxyEventListener,!1),t.document.body.appendChild(this.iframe),this.iframe.src=this.url,this.timeoutHandle=setTimeout((function(){e.timeoutHandler()}),this.timeout)},vt.prototype.eventListener=function(e){var t={event:e,sourceObject:this.eventSourceObject};this.eventValidator.isValid(t)&&(this.destroy(),this.callback(t))},vt.prototype.timeoutHandler=function(){this.destroy(),this.timeoutCallback&&this.timeoutCallback()},vt.prototype.destroy=function(){var e=this;clearTimeout(this.timeoutHandle),this._destroyTimeout=setTimeout((function(){e.eventSourceObject.removeEventListener(e.eventListenerType,e.proxyEventListener,!1),e.iframe.parentNode&&e.iframe.parentNode.removeChild(e.iframe)}),0)},bt.prototype.run=function(e,t){var n=this;e.responseMode="web_message",e.prompt="none";var r=ke.getOrigin(),a=be.getOriginFromUrl(e.redirectUri);if(a&&r!==a)return t({error:"origin_mismatch",error_description:"The redirectUri's origin ("+a+") should match the window's origin ("+r+")."});!function(e,t,n){new vt({url:e,eventListenerType:"message",callback:function(e){n(null,e)},timeout:t.timeout,eventValidator:{isValid:function(e){return"authorization_response"===e.event.data.type&&t.state===e.event.data.response.state}},timeoutCallback:function(){n({error:"timeout",error_description:"Timeout during executing web_message communication",state:t.state})}}).init()}(this.webAuth.client.buildAuthorizeUrl(e),e,(function(r,a){var o=r;if(!r&&a.event.data.response.error&&(o=a.event.data.response),!o){var i=a.event.data.response;return n.webAuth.validateAuthenticationResponse(e,i,t)}return"consent_required"===o.error&&"localhost"===ke.getWindow().location.hostname&&n.warn.warning("Consent Required. Consent can't be skipped on localhost. Read more here: https://auth0.com/docs/api-auth/user-consent#skipping-consent-for-first-party-clients"),n.webAuth.transactionManager.clearTransaction(o.state),t(be.pick(o,["error","error_description"]))}))},wt.prototype.login=function(e,t){var n=this,r=i(this.baseOptions.rootUrl,"/co/authenticate");e.username=e.username||e.email,delete e.email;var a={client_id:e.clientID||this.baseOptions.clientID,username:e.username};e.password&&(a.password=e.password),e.otp&&(a.otp=e.otp);var o=e.realm||this.baseOptions.realm;if(o){var s=e.credentialType||this.baseOptions.credentialType||"http://auth0.com/oauth/grant-type/password-realm";a.realm=o,a.credential_type=s}else a.credential_type="password";this.request.post(r).withCredentials().send(a).end((function(r,a){if(r){var o=r.response&&r.response.body||{error:"request_error",error_description:JSON.stringify(r)};return Pe(t,{forceLegacyError:!0})(o)}function i(){var r=!0===e.popup;e=be.blacklist(e,["password","credentialType","otp","popup","onRedirecting"]);var o=be.merge(e).with({loginTicket:a.body.login_ticket}),i=Mt(n.baseOptions.rootUrl,a.body.co_id);n.storage.setItem(i,a.body.co_verifier,{expires:1/96}),r?n.webMessageHandler.run(o,Pe(t,{forceLegacyError:!0})):n.webAuth.authorize(o)}"function"==typeof e.onRedirecting?e.onRedirecting(i):i()}))},wt.prototype.callback=function(){var e=decodeURIComponent(function(e){var t=("&"+ke.getWindow().location.hash.substring(1)).split("&origin=");if(2===t.length)return t.pop().split("&").shift()}()),t=ke.getWindow(),n=this;t.addEventListener("message",(function(e){if("co_verifier_request"===e.data.type){var t=Mt(e.origin,e.data.request.id),r=function(e,t){try{var n=e.getItem(t);return e.removeItem(t),n||""}catch(e){return""}}(n.storage,t);e.source.postMessage({type:"co_verifier_response",response:{verifier:r}},e.origin)}})),t.parent.postMessage({type:"ready"},e)},Lt.prototype.loginWithCredentials=function(e,t){e.realm=e.realm||e.connection,delete e.connection,this.crossOriginAuthentication.login(e,t)},Lt.prototype.signupAndLogin=function(e,t){var n=this;return this.webAuth.client.dbConnection.signup(e,(function(r){return r?t(r):(e.realm=e.realm||e.connection,delete e.connection,n.webAuth.login(e,t))}))};var Tt=o((function(e){var t=function(){function e(e,t,n){e.attachEvent?e.attachEvent("on"+t,n):e.addEventListener&&e.addEventListener(t,n,!1)}function t(e,t,n){e.detachEvent?e.detachEvent("on"+t,n):e.removeEventListener&&e.removeEventListener(t,n,!1)}function n(e){/^https?:\/\//.test(e)||(e=window.location.href);var t=/^(https?:\/\/[\-_a-zA-Z\.0-9:]+)/.exec(e);return t?t[1]:e}var r=function(){if("undefined"==typeof navigator)return!1;var e=-1,t=navigator.userAgent;return"Microsoft Internet Explorer"===navigator.appName?null!=new RegExp("MSIE ([0-9]{1,}[.0-9]{0,})").exec(t)&&(e=parseFloat(RegExp.$1)):t.indexOf("Trident")>-1&&null!==new RegExp("rv:([0-9]{2,2}[.0-9]{0,})").exec(t)&&(e=parseFloat(RegExp.$1)),e>=8}();return"undefined"!=typeof window&&window.JSON&&window.JSON.stringify&&window.JSON.parse&&window.postMessage?{open:function(a,o){if(!o)throw"missing required callback argument";var i,s;a.url||(i="missing required 'url' parameter"),a.relay_url||(i="missing required 'relay_url' parameter"),i&&setTimeout((function(){o(i)}),0),a.window_name||(a.window_name=null),a.window_features&&!function(){try{var e=navigator.userAgent;return-1!=e.indexOf("Fennec/")||-1!=e.indexOf("Firefox/")&&-1!=e.indexOf("Android")}catch(e){}return!1}()||(a.window_features=void 0);var u,l=a.origin||n(a.url);if(l!==n(a.relay_url))return setTimeout((function(){o("invalid arguments: origin of url and relay_url must match")}),0);r&&((s=document.createElement("iframe")).setAttribute("src",a.relay_url),s.style.display="none",s.setAttribute("name","__winchan_relay_frame"),document.body.appendChild(s),u=s.contentWindow);var c=a.popup||window.open(a.url,a.window_name,a.window_features);a.popup&&(c.location.href=a.url),u||(u=c);var d=setInterval((function(){c&&c.closed&&(f(),o&&(o("User closed the popup window"),o=null))}),500),p=JSON.stringify({a:"request",d:a.params});function f(){if(s&&document.body.removeChild(s),s=void 0,d&&(d=clearInterval(d)),t(window,"message",h),t(window,"unload",f),c)try{c.close()}catch(e){u.postMessage("die",l)}c=u=void 0}function h(e){if(e.origin===l){try{var t=JSON.parse(e.data)}catch(e){if(o)return o(e);throw e}"ready"===t.a?u.postMessage(p,l):"error"===t.a?(f(),o&&(o(t.d),o=null)):"response"===t.a&&(f(),o&&(o(null,t.d),o=null))}}return e(window,"unload",f),e(window,"message",h),{originalPopup:c,close:f,focus:function(){if(c)try{c.focus()}catch(e){}}}},onOpen:function(n){var a="*",o=r?function(){for(var e=window.opener.frames,t=e.length-1;t>=0;t--)try{if(e[t].location.protocol===window.location.protocol&&e[t].location.host===window.location.host&&"__winchan_relay_frame"===e[t].name)return e[t]}catch(e){}}():window.opener;if(!o)throw"can't find relay frame";function i(e){e=JSON.stringify(e),r?o.doPost(e,a):o.postMessage(e,a)}function s(e){if("die"===e.data)try{window.close()}catch(e){}}e(r?o:window,"message",(function e(r){var o;try{o=JSON.parse(r.data)}catch(e){}o&&"request"===o.a&&(t(window,"message",e),a=r.origin,n&&setTimeout((function(){n(a,o.d,(function(e){n=void 0,i({a:"response",d:e})}))}),0))})),e(r?o:window,"message",s);try{i({a:"ready"})}catch(t){e(o,"load",(function(e){i({a:"ready"})}))}var u=function(){try{t(r?o:window,"message",s)}catch(e){}n&&i({a:"error",d:"client closed window"}),n=void 0;try{window.close()}catch(e){}};return e(window,"unload",u),{detach:function(){t(window,"unload",u)}}}}:{open:function(e,t,n,r){setTimeout((function(){r("unsupported browser")}),0)},onOpen:function(e){setTimeout((function(){e("unsupported browser")}),0)}}}();e.exports&&(e.exports=t)})),kt=function(e){/^https?:\/\//.test(e)||(e=window.location.href);var t=/^(https?:\/\/[-_a-zA-Z.0-9:]+)/.exec(e);return t?t[1]:e};function xt(){this._current_popup=null}function Et(e,t){this.baseOptions=t,this.baseOptions.popupOrigin=t.popupOrigin,this.client=e.client,this.webAuth=e,this.transactionManager=new gt(this.baseOptions),this.crossOriginAuthentication=new wt(e,this.baseOptions),this.warn=new Oe({disableWarnings:!!t._disableDeprecationWarnings})}function St(e){this.authenticationUrl=e.authenticationUrl,this.timeout=e.timeout||6e4,this.handler=null,this.postMessageDataType=e.postMessageDataType||!1,this.postMessageOrigin=e.postMessageOrigin||ke.getWindow().location.origin||ke.getWindow().location.protocol+"//"+ke.getWindow().location.hostname+(ke.getWindow().location.port?":"+ke.getWindow().location.port:"")}function Ot(e){this.baseOptions=e,this.request=new Le(e),this.transactionManager=new gt(this.baseOptions)}function Dt(e,t){this.baseOptions=t,this.client=e,this.baseOptions.universalLoginPage=!0,this.request=new Le(this.baseOptions),this.warn=new Oe({disableWarnings:!!t._disableDeprecationWarnings})}xt.prototype.calculatePosition=function(e){var t=e.width||500,n=e.height||600,r=ke.getWindow(),a=void 0!==r.screenX?r.screenX:r.screenLeft,o=void 0!==r.screenY?r.screenY:r.screenTop,i=void 0!==r.outerWidth?r.outerWidth:r.document.body.clientWidth,s=void 0!==r.outerHeight?r.outerHeight:r.document.body.clientHeight;return{width:t,height:n,left:e.left||a+(i-t)/2,top:e.top||o+(s-n)/2}},xt.prototype.preload=function(e){var t=this,n=ke.getWindow(),r=this.calculatePosition(e.popupOptions||{}),a=be.merge(r).with(e.popupOptions),o=e.url||"about:blank",i=Y(a,{encode:!1,delimiter:","});return this._current_popup&&!this._current_popup.closed||(this._current_popup=n.open(o,"auth0_signup_popup",i),this._current_popup.kill=function(){this.close(),t._current_popup=null}),this._current_popup},xt.prototype.load=function(e,t,n,r){var a=this,o=this.calculatePosition(n.popupOptions||{}),i=be.merge(o).with(n.popupOptions),s=be.merge({url:e,relay_url:t,window_features:Y(i,{delimiter:",",encode:!1}),popup:this._current_popup}).with(n),u=Tt.open(s,(function(e,t){if(!e||"SyntaxError"!==e.name)return a._current_popup=null,r(e,t)}));return u.focus(),u},Et.prototype.buildPopupHandler=function(){var e=this.baseOptions.plugins.get("popup.getPopupHandler");return e?e.getPopupHandler():new xt},Et.prototype.preload=function(e){e=e||{};var t=this.buildPopupHandler();return t.preload(e),t},Et.prototype.getPopupHandler=function(e,t){return e.popupHandler?e.popupHandler:t?this.preload(e):this.buildPopupHandler()},Et.prototype.callback=function(e){var t=this,n=ke.getWindow(),r=(e=e||{}).popupOrigin||this.baseOptions.popupOrigin||ke.getOrigin();n.opener?Tt.onOpen((function(n,a,o){if(n!==r)return o({error:"origin_mismatch",error_description:"The popup's origin ("+n+") should match the `popupOrigin` parameter ("+r+")."});t.webAuth.parseHash(e||{},(function(e,t){return o(e||t)}))})):n.doPost=function(e){n.parent&&n.parent.postMessage(e,r)}},Et.prototype.authorize=function(e,t){var n,r,a={},o=this.baseOptions.plugins.get("popup.authorize"),s=be.merge(this.baseOptions,["clientID","scope","domain","audience","tenant","responseType","redirectUri","_csrf","state","_intstate","nonce","organization","invitation"]).with(be.blacklist(e,["popupHandler"]));return pe.check(s,{type:"object",message:"options parameter is not valid"},{responseType:{type:"string",message:"responseType option is required"}}),r=i(this.baseOptions.rootUrl,"relay.html"),e.owp?s.owp=!0:(a.origin=kt(s.redirectUri),r=s.redirectUri),e.popupOptions&&(a.popupOptions=be.pick(e.popupOptions,["width","height","top","left"])),o&&(s=o.processParams(s)),(s=this.transactionManager.process(s)).scope=s.scope||"openid profile email",delete s.domain,n=this.client.buildAuthorizeUrl(s),this.getPopupHandler(e).load(n,r,a,Pe(t,{keepOriginalCasing:!0}))},Et.prototype.loginWithCredentials=function(e,t){e.realm=e.realm||e.connection,e.popup=!0,e=be.merge(this.baseOptions,["redirectUri","responseType","state","nonce"]).with(be.blacklist(e,["popupHandler","connection"])),e=this.transactionManager.process(e),this.crossOriginAuthentication.login(e,t)},Et.prototype.passwordlessVerify=function(e,t){var n=this;return this.client.passwordless.verify(be.blacklist(e,["popupHandler"]),(function(r){if(r)return t(r);e.username=e.phoneNumber||e.email,e.password=e.verificationCode,delete e.email,delete e.phoneNumber,delete e.verificationCode,delete e.type,n.client.loginWithResourceOwner(e,t)}))},Et.prototype.signupAndLogin=function(e,t){var n=this;return this.client.dbConnection.signup(e,(function(r){if(r)return t(r);n.loginWithCredentials(e,t)}))},St.create=function(e){return new St(e)},St.prototype.login=function(e,t){this.handler=new vt({auth0:this.auth0,url:this.authenticationUrl,eventListenerType:e?"message":"load",callback:this.getCallbackHandler(t,e),timeout:this.timeout,eventValidator:this.getEventValidator(),timeoutCallback:function(){t(null,"#error=timeout&error_description=Timeout+during+authentication+renew.")},usePostMessage:e||!1}),this.handler.init()},St.prototype.getEventValidator=function(){var e=this;return{isValid:function(t){switch(t.event.type){case"message":return t.event.origin===e.postMessageOrigin&&t.event.source===e.handler.iframe.contentWindow&&(!1===e.postMessageDataType||t.event.data.type&&t.event.data.type===e.postMessageDataType);case"load":if("about:"===t.sourceObject.contentWindow.location.protocol)return!1;default:return!0}}}},St.prototype.getCallbackHandler=function(e,t){return function(n){var r;r=t?"object"==typeof n.event.data&&n.event.data.hash?n.event.data.hash:n.event.data:n.sourceObject.contentWindow.location.hash,e(null,r)}},Ot.prototype.login=function(e,t){var n,r;return n=i(this.baseOptions.rootUrl,"usernamepassword","login"),e.username=e.username||e.email,e=be.blacklist(e,["email","onRedirecting"]),r=be.merge(this.baseOptions,["clientID","redirectUri","tenant","responseType","responseMode","scope","audience"]).with(e),r=this.transactionManager.process(r),r=be.toSnakeCase(r,["auth0Client"]),this.request.post(n).send(r).end(Pe(t))},Ot.prototype.callback=function(e){var t,n=ke.getDocument();(t=n.createElement("div")).innerHTML=e,n.body.appendChild(t).children[0].submit()},Dt.prototype.login=function(e,t){if(ke.getWindow().location.host!==this.baseOptions.domain)throw new Error("This method is meant to be used only inside the Universal Login Page.");var n,r=be.merge(this.baseOptions,["clientID","redirectUri","tenant","responseType","responseMode","scope","audience","_csrf","state","_intstate","nonce"]).with(e);return pe.check(r,{type:"object",message:"options parameter is not valid"},{responseType:{type:"string",message:"responseType option is required"}}),(n=new Ot(this.baseOptions)).login(r,(function(r,a){if(r)return t(r);function o(){n.callback(a)}if("function"==typeof e.onRedirecting)return e.onRedirecting((function(){o()}));o()}))},Dt.prototype.signupAndLogin=function(e,t){var n=this;return n.client.client.dbConnection.signup(e,(function(r){return r?t(r):n.login(e,t)}))},Dt.prototype.getSSOData=function(e,t){var n,r="";return"function"==typeof e&&(t=e,e=!1),pe.check(e,{type:"boolean",message:"withActiveDirectories parameter is not valid"}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),e&&(r="?"+Y({ldaps:1,client_id:this.baseOptions.clientID})),n=i(this.baseOptions.rootUrl,"user","ssodata",r),this.request.get(n,{noHeaders:!0}).withCredentials().end(Pe(t))};var Yt=function(){},At={lang:"en",templates:{auth0:function(e){var t="code"===e.type?"Enter the code shown above":"Solve the formula shown above";return'<div class="captcha-challenge">\n <img src="'+e.image+'" />\n <button type="button" class="captcha-reload">↺</button>\n</div>\n<input type="text" name="captcha"\n class="form-control captcha-control"\n placeholder="'+t+'" />'},recaptcha_v2:function(){return'<div class="recaptcha" ></div><input type="hidden" name="captcha" />'},recaptcha_enterprise:function(){return'<div class="recaptcha" ></div><input type="hidden" name="captcha" />'},error:function(){return'<div class="error" style="color: red;">Error getting the bot detection challenge. Please contact the system administrator.</div>'}}};function Ct(e){switch(e){case"recaptcha_v2":return window.grecaptcha;case"recaptcha_enterprise":return window.grecaptcha.enterprise;default:throw new Error("Unknown captcha provider")}}var jt=function(e,t,n,r){function a(r){r=r||Yt,e.getChallenge((function(e,o){return e?(t.innerHTML=n.templates.error(e),r(e)):o.required?(t.style.display="","auth0"===o.provider?function(e,t,n,r){e.innerHTML=t.templates[n.provider](n),e.querySelector(".captcha-reload").addEventListener("click",(function(e){e.preventDefault(),r()}))}(t,n,o,a):"recaptcha_v2"!==o.provider&&"recaptcha_enterprise"!==o.provider||function(e,t,n){var r=e.hasAttribute("data-wid")&&e.getAttribute("data-wid");function a(t){e.querySelector('input[name="captcha"]').value=t||""}if(r)return a(),void Ct(n.provider).reset(r);e.innerHTML=t.templates[n.provider](n);var o=e.querySelector(".recaptcha");!function(e,t,n){var r="recaptchaCallback_"+Math.floor(1000001*Math.random());window[r]=function(){delete window[r],n()};var a=window.document.createElement("script");a.src=function(e,t,n){switch(e){case"recaptcha_v2":return"https://www.recaptcha.net/recaptcha/api.js?hl="+t+"&onload="+n;case"recaptcha_enterprise":return"https://www.recaptcha.net/recaptcha/enterprise.js?render=explicit&hl="+t+"&onload="+n;default:throw new Error("Unknown captcha provider")}}(t.provider,t.lang,r),a.async=!0,window.document.body.appendChild(a)}(0,{lang:t.lang,provider:n.provider},(function(){var t=Ct(n.provider);r=t.render(o,{callback:a,"expired-callback":function(){a()},"error-callback":function(){a()},sitekey:n.siteKey}),e.setAttribute("data-wid",r)}))}(t,n,o),void r()):(t.style.display="none",void(t.innerHTML=""))}))}return n=be.merge(At).with(n||{}),a(r),{reload:a,getValue:function(){var e=t.querySelector('input[name="captcha"]');if(e)return e.value}}};function Pt(){return new Date}function Ht(e){pe.check(e,{type:"object",message:"options parameter is not valid"},{domain:{type:"string",message:"domain option is required"},clientID:{type:"string",message:"clientID option is required"},responseType:{optional:!0,type:"string",message:"responseType is not valid"},responseMode:{optional:!0,type:"string",message:"responseMode is not valid"},redirectUri:{optional:!0,type:"string",message:"redirectUri is not valid"},scope:{optional:!0,type:"string",message:"scope is not valid"},audience:{optional:!0,type:"string",message:"audience is not valid"},popupOrigin:{optional:!0,type:"string",message:"popupOrigin is not valid"},leeway:{optional:!0,type:"number",message:"leeway is not valid"},plugins:{optional:!0,type:"array",message:"plugins is not valid"},maxAge:{optional:!0,type:"number",message:"maxAge is not valid"},_disableDeprecationWarnings:{optional:!0,type:"boolean",message:"_disableDeprecationWarnings option is not valid"},_sendTelemetry:{optional:!0,type:"boolean",message:"_sendTelemetry option is not valid"},_telemetryInfo:{optional:!0,type:"object",message:"_telemetryInfo option is not valid"},_timesToRetryFailedRequests:{optional:!0,type:"number",message:"_timesToRetryFailedRequests option is not valid"}}),e.overrides&&pe.check(e.overrides,{type:"object",message:"overrides option is not valid"},{__tenant:{optional:!0,type:"string",message:"__tenant option is required"},__token_issuer:{optional:!0,type:"string",message:"__token_issuer option is required"},__jwks_uri:{optional:!0,type:"string",message:"__jwks_uri is required"}}),this.baseOptions=e,this.baseOptions.plugins=new _t(this,this.baseOptions.plugins||[]),this.baseOptions._sendTelemetry=!1!==this.baseOptions._sendTelemetry||this.baseOptions._sendTelemetry,this.baseOptions._timesToRetryFailedRequests=e._timesToRetryFailedRequests?parseInt(e._timesToRetryFailedRequests,0):0,this.baseOptions.tenant=this.baseOptions.overrides&&this.baseOptions.overrides.__tenant||this.baseOptions.domain.split(".")[0],this.baseOptions.token_issuer=this.baseOptions.overrides&&this.baseOptions.overrides.__token_issuer||"https://"+this.baseOptions.domain+"/",this.baseOptions.jwksURI=this.baseOptions.overrides&&this.baseOptions.overrides.__jwks_uri,this.transactionManager=new gt(this.baseOptions),this.client=new Rt(this.baseOptions),this.redirect=new Lt(this,this.baseOptions),this.popup=new Et(this,this.baseOptions),this.crossOriginAuthentication=new wt(this,this.baseOptions),this.webMessageHandler=new bt(this),this._universalLogin=new Dt(this,this.baseOptions),this.ssodataStorage=new Ae(this.baseOptions)}function It(e,t){this.baseOptions=t,this.request=e}function Nt(e,t){this.baseOptions=t,this.request=e}function Rt(e,t){2===arguments.length?this.auth0=e:t=e,pe.check(t,{type:"object",message:"options parameter is not valid"},{domain:{type:"string",message:"domain option is required"},clientID:{type:"string",message:"clientID option is required"},responseType:{optional:!0,type:"string",message:"responseType is not valid"},responseMode:{optional:!0,type:"string",message:"responseMode is not valid"},redirectUri:{optional:!0,type:"string",message:"redirectUri is not valid"},scope:{optional:!0,type:"string",message:"scope is not valid"},audience:{optional:!0,type:"string",message:"audience is not valid"},_disableDeprecationWarnings:{optional:!0,type:"boolean",message:"_disableDeprecationWarnings option is not valid"},_sendTelemetry:{optional:!0,type:"boolean",message:"_sendTelemetry option is not valid"},_telemetryInfo:{optional:!0,type:"object",message:"_telemetryInfo option is not valid"}}),this.baseOptions=t,this.baseOptions._sendTelemetry=!1!==this.baseOptions._sendTelemetry||this.baseOptions._sendTelemetry,this.baseOptions.rootUrl=this.baseOptions.domain&&0===this.baseOptions.domain.toLowerCase().indexOf("http")?this.baseOptions.domain:"https://"+this.baseOptions.domain,this.request=new Le(this.baseOptions),this.passwordless=new It(this.request,this.baseOptions),this.dbConnection=new Nt(this.request,this.baseOptions),this.warn=new Oe({disableWarnings:!!t._disableDeprecationWarnings}),this.ssodataStorage=new Ae(this.baseOptions)}function Ft(e){pe.check(e,{type:"object",message:"options parameter is not valid"},{domain:{type:"string",message:"domain option is required"},token:{type:"string",message:"token option is required"},_sendTelemetry:{optional:!0,type:"boolean",message:"_sendTelemetry option is not valid"},_telemetryInfo:{optional:!0,type:"object",message:"_telemetryInfo option is not valid"}}),this.baseOptions=e,this.baseOptions.headers={Authorization:"Bearer "+this.baseOptions.token},this.request=new Le(this.baseOptions),this.baseOptions.rootUrl=i("https://"+this.baseOptions.domain,"api","v2")}Ht.prototype.parseHash=function(e,t){var n,r;t||"function"!=typeof e?e=e||{}:(t=e,e={});var a=ke.getWindow(),o=void 0===e.hash?a.location.hash:e.hash;if((n=function(e,t){var n=function(e){if(!e)return E;if(null!==e.decoder&&void 0!==e.decoder&&"function"!=typeof e.decoder)throw new TypeError("Decoder has to be a function.");if(void 0!==e.charset&&"utf-8"!==e.charset&&"iso-8859-1"!==e.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var t=void 0===e.charset?E.charset:e.charset;return{allowDots:void 0===e.allowDots?E.allowDots:!!e.allowDots,allowPrototypes:"boolean"==typeof e.allowPrototypes?e.allowPrototypes:E.allowPrototypes,arrayLimit:"number"==typeof e.arrayLimit?e.arrayLimit:E.arrayLimit,charset:t,charsetSentinel:"boolean"==typeof e.charsetSentinel?e.charsetSentinel:E.charsetSentinel,comma:"boolean"==typeof e.comma?e.comma:E.comma,decoder:"function"==typeof e.decoder?e.decoder:E.decoder,delimiter:"string"==typeof e.delimiter||d.isRegExp(e.delimiter)?e.delimiter:E.delimiter,depth:"number"==typeof e.depth||!1===e.depth?+e.depth:E.depth,ignoreQueryPrefix:!0===e.ignoreQueryPrefix,interpretNumericEntities:"boolean"==typeof e.interpretNumericEntities?e.interpretNumericEntities:E.interpretNumericEntities,parameterLimit:"number"==typeof e.parameterLimit?e.parameterLimit:E.parameterLimit,parseArrays:!1!==e.parseArrays,plainObjects:"boolean"==typeof e.plainObjects?e.plainObjects:E.plainObjects,strictNullHandling:"boolean"==typeof e.strictNullHandling?e.strictNullHandling:E.strictNullHandling}}(t);if(""===e||null==e)return n.plainObjects?Object.create(null):{};for(var r="string"==typeof e?function(e,t){var n,r={},a=t.ignoreQueryPrefix?e.replace(/^\?/,""):e,o=t.parameterLimit===1/0?void 0:t.parameterLimit,i=a.split(t.delimiter,o),s=-1,u=t.charset;if(t.charsetSentinel)for(n=0;n<i.length;++n)0===i[n].indexOf("utf8=")&&("utf8=%E2%9C%93"===i[n]?u="utf-8":"utf8=%26%2310003%3B"===i[n]&&(u="iso-8859-1"),s=n,n=i.length);for(n=0;n<i.length;++n)if(n!==s){var l,c,p=i[n],f=p.indexOf("]="),h=-1===f?p.indexOf("="):f+1;-1===h?(l=t.decoder(p,E.decoder,u,"key"),c=t.strictNullHandling?null:""):(l=t.decoder(p.slice(0,h),E.decoder,u,"key"),c=d.maybeMap(O(p.slice(h+1),t),(function(e){return t.decoder(e,E.decoder,u,"value")}))),c&&t.interpretNumericEntities&&"iso-8859-1"===u&&(c=S(c)),p.indexOf("[]=")>-1&&(c=x(c)?[c]:c),k.call(r,l)?r[l]=d.combine(r[l],c):r[l]=c}return r}(e,n):e,a=n.plainObjects?Object.create(null):{},o=Object.keys(r),i=0;i<o.length;++i){var s=o[i],u=D(s,r[s],n,"string"==typeof e);a=d.merge(a,u,n)}return d.compact(a)}(o=o.replace(/^#?\/?/,""))).hasOwnProperty("error"))return r=je.buildResponse(n.error,n.error_description),n.state&&(r.state=n.state),t(r);if(!n.hasOwnProperty("access_token")&&!n.hasOwnProperty("id_token")&&!n.hasOwnProperty("refresh_token"))return t(null,null);var i=(this.baseOptions.responseType||e.responseType||"").split(" ");return i.length>0&&-1!==i.indexOf("token")&&!n.hasOwnProperty("access_token")?t(je.buildResponse("invalid_hash","response_type contains `token`, but the parsed hash does not contain an `access_token` property")):i.length>0&&-1!==i.indexOf("id_token")&&!n.hasOwnProperty("id_token")?t(je.buildResponse("invalid_hash","response_type contains `id_token`, but the parsed hash does not contain an `id_token` property")):this.validateAuthenticationResponse(e,n,t)},Ht.prototype.validateAuthenticationResponse=function(e,t,n){var r=this;e.__enableIdPInitiatedLogin=e.__enableIdPInitiatedLogin||e.__enableImpersonation;var a=t.state,o=this.transactionManager.getStoredTransaction(a),i=e.state||o&&o.state||null,s=i===a;if((a||i||!e.__enableIdPInitiatedLogin)&&!s)return n({error:"invalid_token",errorDescription:"`state` does not match."});var u=e.nonce||o&&o.nonce||null,l=o&&o.organization,c=e.state||o&&o.appState||null,d=function(e,a){return e?n(e):(o&&o.lastUsedConnection&&(a&&(i=a.sub),r.ssodataStorage.set(o.lastUsedConnection,i)),n(null,function(e,t,n){return{accessToken:e.access_token||null,idToken:e.id_token||null,idTokenPayload:n||null,appState:t||null,refreshToken:e.refresh_token||null,state:e.state||null,expiresIn:e.expires_in?parseInt(e.expires_in,10):null,tokenType:e.token_type||null,scope:e.scope||null}}(t,c,a)));var i};return t.id_token?this.validateToken(t.id_token,u,(function(e,n){if(!e){if(l){if(!n.org_id)return d(je.invalidToken("Organization Id (org_id) claim must be a string present in the ID token"));if(n.org_id!==l)return d(je.invalidToken('Organization Id (org_id) claim value mismatch in the ID token; expected "'+l+'", found "'+n.org_id+'"'))}return t.access_token&&n.at_hash?(new mt).validateAccessToken(t.access_token,"RS256",n.at_hash,(function(e){return e?d(je.invalidToken(e.message)):d(null,n)})):d(null,n)}if("invalid_token"!==e.error||e.errorDescription&&e.errorDescription.indexOf("Nonce (nonce) claim value mismatch in the ID token")>-1)return d(e);var a=(new mt).decode(t.id_token);return"HS256"!==a.header.alg?d(e):(a.payload.nonce||null)!==u?d({error:"invalid_token",errorDescription:'Nonce (nonce) claim value mismatch in the ID token; expected "'+u+'", found "'+a.payload.nonce+'"'}):t.access_token?r.client.userInfo(t.access_token,(function(e,t){return e?d(e):d(null,t)})):d({error:"invalid_token",description:"The id_token cannot be validated because it was signed with the HS256 algorithm and public clients (like a browser) can’t store secrets. Please read the associated doc for possible ways to fix this. Read more: https://auth0.com/docs/errors/libraries/auth0-js/invalid-token#parsing-an-hs256-signed-id-token-without-an-access-token"})})):d(null,null)},Ht.prototype.validateToken=function(e,t,n){new mt({issuer:this.baseOptions.token_issuer,jwksURI:this.baseOptions.jwksURI,audience:this.baseOptions.clientID,leeway:this.baseOptions.leeway||60,maxAge:this.baseOptions.maxAge,__clock:this.baseOptions.__clock||Pt}).verify(e,t,(function(e,t){if(e)return n(je.invalidToken(e.message));n(null,t)}))},Ht.prototype.renewAuth=function(e,t){var n=!!e.usePostMessage,r=e.postMessageDataType||!1,a=e.postMessageOrigin||ke.getWindow().origin,o=e.timeout,i=this,s=be.merge(this.baseOptions,["clientID","redirectUri","responseType","scope","audience","_csrf","state","_intstate","nonce"]).with(e);s.responseType=s.responseType||"token",s.responseMode=s.responseMode||"fragment",s=this.transactionManager.process(s),pe.check(s,{type:"object",message:"options parameter is not valid"}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),s.prompt="none",s=be.blacklist(s,["usePostMessage","tenant","postMessageDataType","postMessageOrigin"]),St.create({authenticationUrl:this.client.buildAuthorizeUrl(s),postMessageDataType:r,postMessageOrigin:a,timeout:o}).login(n,(function(e,n){if("object"==typeof n)return t(e,n);i.parseHash({hash:n},t)}))},Ht.prototype.checkSession=function(e,t){var n=be.merge(this.baseOptions,["clientID","responseType","redirectUri","scope","audience","_csrf","state","_intstate","nonce"]).with(e);return"code"===n.responseType?t({error:"error",error_description:"responseType can't be `code`"}):(e.nonce||(n=this.transactionManager.process(n)),n.redirectUri?(pe.check(n,{type:"object",message:"options parameter is not valid"}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=be.blacklist(n,["usePostMessage","tenant","postMessageDataType"]),void this.webMessageHandler.run(n,Pe(t,{forceLegacyError:!0,ignoreCasing:!0}))):t({error:"error",error_description:"redirectUri can't be empty"}))},Ht.prototype.changePassword=function(e,t){return this.client.dbConnection.changePassword(e,t)},Ht.prototype.passwordlessStart=function(e,t){var n=be.merge(this.baseOptions,["responseType","responseMode","redirectUri","scope","audience","_csrf","state","_intstate","nonce"]).with(e.authParams);return e.authParams=this.transactionManager.process(n),this.client.passwordless.start(e,t)},Ht.prototype.signup=function(e,t){return this.client.dbConnection.signup(e,t)},Ht.prototype.authorize=function(e){var t=be.merge(this.baseOptions,["clientID","responseType","responseMode","redirectUri","scope","audience","_csrf","state","_intstate","nonce","organization","invitation"]).with(e);pe.check(t,{type:"object",message:"options parameter is not valid"},{responseType:{type:"string",message:"responseType option is required"}}),(t=this.transactionManager.process(t)).scope=t.scope||"openid profile email",ke.redirect(this.client.buildAuthorizeUrl(t))},Ht.prototype.signupAndAuthorize=function(e,t){var n=this;return this.client.dbConnection.signup(be.blacklist(e,["popupHandler"]),(function(r){if(r)return t(r);e.realm=e.connection,e.username||(e.username=e.email),n.client.login(e,t)}))},Ht.prototype.login=function(e,t){var n=be.merge(this.baseOptions,["clientID","responseType","redirectUri","scope","audience","_csrf","state","_intstate","nonce","onRedirecting","organization","invitation"]).with(e);n=this.transactionManager.process(n),ke.getWindow().location.host===this.baseOptions.domain?(n.connection=n.realm,delete n.realm,this._universalLogin.login(n,t)):this.crossOriginAuthentication.login(n,t)},Ht.prototype.passwordlessLogin=function(e,t){var n=be.merge(this.baseOptions,["clientID","responseType","redirectUri","scope","audience","_csrf","state","_intstate","nonce","onRedirecting"]).with(e);if(n=this.transactionManager.process(n),ke.getWindow().location.host===this.baseOptions.domain)this.passwordlessVerify(n,t);else{var r=be.extend({credentialType:"http://auth0.com/oauth/grant-type/passwordless/otp",realm:n.connection,username:n.email||n.phoneNumber,otp:n.verificationCode},be.blacklist(n,["connection","email","phoneNumber","verificationCode"]));this.crossOriginAuthentication.login(r,t)}},Ht.prototype.crossOriginAuthenticationCallback=function(){this.crossOriginVerification()},Ht.prototype.crossOriginVerification=function(){this.crossOriginAuthentication.callback()},Ht.prototype.logout=function(e){ke.redirect(this.client.buildLogoutUrl(e))},Ht.prototype.passwordlessVerify=function(e,t){var n=this,r=be.merge(this.baseOptions,["clientID","responseType","responseMode","redirectUri","scope","audience","_csrf","state","_intstate","nonce","onRedirecting"]).with(e);return pe.check(r,{type:"object",message:"options parameter is not valid"},{responseType:{type:"string",message:"responseType option is required"}}),r=this.transactionManager.process(r),this.client.passwordless.verify(r,(function(a){if(a)return t(a);function o(){ke.redirect(n.client.passwordless.buildVerifyUrl(r))}if("function"==typeof e.onRedirecting)return e.onRedirecting((function(){o()}));o()}))},Ht.prototype.renderCaptcha=function(e,t,n){return jt(this.client,e,t,n)},It.prototype.buildVerifyUrl=function(e){var t,n;return pe.check(e,{type:"object",message:"options parameter is not valid"},{connection:{type:"string",message:"connection option is required"},verificationCode:{type:"string",message:"verificationCode option is required"},phoneNumber:{optional:!1,type:"string",message:"phoneNumber option is required",condition:function(e){return!e.email}},email:{optional:!1,type:"string",message:"email option is required",condition:function(e){return!e.phoneNumber}}}),t=be.merge(this.baseOptions,["clientID","responseType","responseMode","redirectUri","scope","audience","_csrf","state","_intstate","protocol","nonce"]).with(e),this.baseOptions._sendTelemetry&&(t.auth0Client=this.request.getTelemetryData()),t=be.toSnakeCase(t,["auth0Client"]),n=Y(t),i(this.baseOptions.rootUrl,"passwordless","verify_redirect","?"+n)},It.prototype.start=function(e,t){var n,r;return pe.check(e,{type:"object",message:"options parameter is not valid"},{connection:{type:"string",message:"connection option is required"},send:{type:"string",message:"send option is required",values:["link","code"],value_message:"send is not valid ([link, code])"},phoneNumber:{optional:!0,type:"string",message:"phoneNumber option is required",condition:function(e){return"code"===e.send||!e.email}},email:{optional:!0,type:"string",message:"email option is required",condition:function(e){return"link"===e.send||!e.phoneNumber}},authParams:{optional:!0,type:"object",message:"authParams option is required"}}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"passwordless","start"),(r=be.merge(this.baseOptions,["clientID","responseType","redirectUri","scope"]).with(e)).scope&&(r.authParams=r.authParams||{},r.authParams.scope=r.authParams.scope||r.scope),r.redirectUri&&(r.authParams=r.authParams||{},r.authParams.redirect_uri=r.authParams.redirectUri||r.redirectUri),r.responseType&&(r.authParams=r.authParams||{},r.authParams.response_type=r.authParams.responseType||r.responseType),delete r.redirectUri,delete r.responseType,delete r.scope,r=be.toSnakeCase(r,["auth0Client","authParams"]),this.request.post(n).send(r).end(Pe(t))},It.prototype.verify=function(e,t){var n,r;return pe.check(e,{type:"object",message:"options parameter is not valid"},{connection:{type:"string",message:"connection option is required"},verificationCode:{type:"string",message:"verificationCode option is required"},phoneNumber:{optional:!1,type:"string",message:"phoneNumber option is required",condition:function(e){return!e.email}},email:{optional:!1,type:"string",message:"email option is required",condition:function(e){return!e.phoneNumber}}}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),r=be.pick(e,["connection","verificationCode","phoneNumber","email","auth0Client"]),r=be.toSnakeCase(r,["auth0Client"]),n=i(this.baseOptions.rootUrl,"passwordless","verify"),this.request.post(n).send(r).end(Pe(t))},Nt.prototype.signup=function(e,t){var n,r,a;return pe.check(e,{type:"object",message:"options parameter is not valid"},{connection:{type:"string",message:"connection option is required"},email:{type:"string",message:"email option is required"},password:{type:"string",message:"password option is required"}}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"dbconnections","signup"),a=(r=be.merge(this.baseOptions,["clientID","state"]).with(e)).user_metadata||r.userMetadata,r=be.blacklist(r,["scope","userMetadata","user_metadata"]),r=be.toSnakeCase(r,["auth0Client"]),a&&(r.user_metadata=a),this.request.post(n).send(r).end(Pe(t))},Nt.prototype.changePassword=function(e,t){var n,r;return pe.check(e,{type:"object",message:"options parameter is not valid"},{connection:{type:"string",message:"connection option is required"},email:{type:"string",message:"email option is required"}}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"dbconnections","change_password"),r=be.merge(this.baseOptions,["clientID"]).with(e,["email","connection"]),r=be.toSnakeCase(r,["auth0Client"]),this.request.post(n).send(r).end(Pe(t))},Rt.prototype.buildAuthorizeUrl=function(e){var t,n;return pe.check(e,{type:"object",message:"options parameter is not valid"}),t=be.merge(this.baseOptions,["clientID","responseType","responseMode","redirectUri","scope","audience"]).with(e),pe.check(t,{type:"object",message:"options parameter is not valid"},{clientID:{type:"string",message:"clientID option is required"},redirectUri:{optional:!0,type:"string",message:"redirectUri option is required"},responseType:{type:"string",message:"responseType option is required"},nonce:{type:"string",message:"nonce option is required",condition:function(e){return-1===e.responseType.indexOf("code")&&-1!==e.responseType.indexOf("id_token")}},scope:{optional:!0,type:"string",message:"scope option is required"},audience:{optional:!0,type:"string",message:"audience option is required"}}),this.baseOptions._sendTelemetry&&(t.auth0Client=this.request.getTelemetryData()),t.connection_scope&&pe.isArray(t.connection_scope)&&(t.connection_scope=t.connection_scope.join(",")),t=be.blacklist(t,["username","popupOptions","domain","tenant","timeout","appState"]),t=be.toSnakeCase(t,["auth0Client"]),t=Re(this.warn,t),n=Y(t),i(this.baseOptions.rootUrl,"authorize","?"+n)},Rt.prototype.buildLogoutUrl=function(e){var t,n;return pe.check(e,{optional:!0,type:"object",message:"options parameter is not valid"}),t=be.merge(this.baseOptions,["clientID"]).with(e||{}),this.baseOptions._sendTelemetry&&(t.auth0Client=this.request.getTelemetryData()),t=be.toSnakeCase(t,["auth0Client","returnTo"]),n=Y(be.blacklist(t,["federated"])),e&&void 0!==e.federated&&!1!==e.federated&&"false"!==e.federated&&(n+="&federated"),i(this.baseOptions.rootUrl,"v2","logout","?"+n)},Rt.prototype.loginWithDefaultDirectory=function(e,t){return pe.check(e,{type:"object",message:"options parameter is not valid"},{username:{type:"string",message:"username option is required"},password:{type:"string",message:"password option is required"},scope:{optional:!0,type:"string",message:"scope option is required"},audience:{optional:!0,type:"string",message:"audience option is required"}}),e.grantType="password",this.oauthToken(e,t)},Rt.prototype.login=function(e,t){return pe.check(e,{type:"object",message:"options parameter is not valid"},{username:{type:"string",message:"username option is required"},password:{type:"string",message:"password option is required"},realm:{type:"string",message:"realm option is required"},scope:{optional:!0,type:"string",message:"scope option is required"},audience:{optional:!0,type:"string",message:"audience option is required"}}),e.grantType="http://auth0.com/oauth/grant-type/password-realm",this.oauthToken(e,t)},Rt.prototype.oauthToken=function(e,t){var n,r;return pe.check(e,{type:"object",message:"options parameter is not valid"}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"oauth","token"),r=be.merge(this.baseOptions,["clientID","scope","audience"]).with(e),pe.check(r,{type:"object",message:"options parameter is not valid"},{clientID:{type:"string",message:"clientID option is required"},grantType:{type:"string",message:"grantType option is required"},scope:{optional:!0,type:"string",message:"scope option is required"},audience:{optional:!0,type:"string",message:"audience option is required"}}),r=be.toSnakeCase(r,["auth0Client"]),r=Ne(this.warn,r),this.request.post(n).send(r).end(Pe(t))},Rt.prototype.loginWithResourceOwner=function(e,t){var n,r;return pe.check(e,{type:"object",message:"options parameter is not valid"},{username:{type:"string",message:"username option is required"},password:{type:"string",message:"password option is required"},connection:{type:"string",message:"connection option is required"},scope:{optional:!0,type:"string",message:"scope option is required"}}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"oauth","ro"),r=be.merge(this.baseOptions,["clientID","scope"]).with(e,["username","password","scope","connection","device"]),(r=be.toSnakeCase(r,["auth0Client"])).grant_type=r.grant_type||"password",this.request.post(n).send(r).end(Pe(t))},Rt.prototype.getSSOData=function(e,t){if(this.auth0||(this.auth0=new Ht(this.baseOptions)),ke.getWindow().location.host===this.baseOptions.domain)return this.auth0._universalLogin.getSSOData(e,t);"function"==typeof e&&(t=e),pe.check(t,{type:"function",message:"cb parameter is not valid"});var n=this.baseOptions.clientID,r=this.ssodataStorage.get()||{};this.auth0.checkSession({responseType:"token id_token",scope:"openid profile email",connection:r.lastUsedConnection,timeout:5e3},(function(e,a){return e?"login_required"===e.error?t(null,{sso:!1}):("consent_required"===e.error&&(e.error_description="Consent required. When using `getSSOData`, the user has to be authenticated with the following scope: `openid profile email`."),t(e,{sso:!1})):r.lastUsedSub&&r.lastUsedSub!==a.idTokenPayload.sub?t(e,{sso:!1}):t(null,{lastUsedConnection:{name:r.lastUsedConnection},lastUsedUserID:a.idTokenPayload.sub,lastUsedUsername:a.idTokenPayload.email||a.idTokenPayload.name,lastUsedClientID:n,sessionClients:[n],sso:!0})}))},Rt.prototype.userInfo=function(e,t){var n;return pe.check(e,{type:"string",message:"accessToken parameter is not valid"}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"userinfo"),this.request.get(n).set("Authorization","Bearer "+e).end(Pe(t,{ignoreCasing:!0}))},Rt.prototype.getChallenge=function(e){if(pe.check(e,{type:"function",message:"cb parameter is not valid"}),!this.baseOptions.state)return e();var t=i(this.baseOptions.rootUrl,"usernamepassword","challenge");return this.request.post(t).send({state:this.baseOptions.state}).end(Pe(e,{ignoreCasing:!0}))},Rt.prototype.delegation=function(e,t){var n,r;return pe.check(e,{type:"object",message:"options parameter is not valid"},{grant_type:{type:"string",message:"grant_type option is required"}}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"delegation"),r=be.merge(this.baseOptions,["clientID"]).with(e),r=be.toSnakeCase(r,["auth0Client"]),this.request.post(n).send(r).end(Pe(t))},Rt.prototype.getUserCountry=function(e){var t;return pe.check(e,{type:"function",message:"cb parameter is not valid"}),t=i(this.baseOptions.rootUrl,"user","geoloc","country"),this.request.get(t).end(Pe(e))},Ft.prototype.getUser=function(e,t){var n;return pe.check(e,{type:"string",message:"userId parameter is not valid"}),pe.check(t,{type:"function",message:"cb parameter is not valid"}),n=i(this.baseOptions.rootUrl,"users",e),this.request.get(n).end(Pe(t,{ignoreCasing:!0}))},Ft.prototype.patchUserMetadata=function(e,t,n){var r;return pe.check(e,{type:"string",message:"userId parameter is not valid"}),pe.check(t,{type:"object",message:"userMetadata parameter is not valid"}),pe.check(n,{type:"function",message:"cb parameter is not valid"}),r=i(this.baseOptions.rootUrl,"users",e),this.request.patch(r).send({user_metadata:t}).end(Pe(n,{ignoreCasing:!0}))},Ft.prototype.patchUserAttributes=function(e,t,n){var r;return pe.check(e,{type:"string",message:"userId parameter is not valid"}),pe.check(t,{type:"object",message:"user parameter is not valid"}),pe.check(n,{type:"function",message:"cb parameter is not valid"}),r=i(this.baseOptions.rootUrl,"users",e),this.request.patch(r).send(t).end(Pe(n,{ignoreCasing:!0}))},Ft.prototype.linkUser=function(e,t,n){var r;return pe.check(e,{type:"string",message:"userId parameter is not valid"}),pe.check(t,{type:"string",message:"secondaryUserToken parameter is not valid"}),pe.check(n,{type:"function",message:"cb parameter is not valid"}),r=i(this.baseOptions.rootUrl,"users",e,"identities"),this.request.post(r).send({link_with:t}).end(Pe(n,{ignoreCasing:!0}))};var zt={Authentication:Rt,Management:Ft,WebAuth:Ht,version:se};t.default=zt}.call(this,n(38),n(345))},function(e,t){var n,r,a=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function s(e){if(n===setTimeout)return setTimeout(e,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:o}catch(e){n=o}try{r="function"==typeof clearTimeout?clearTimeout:i}catch(e){r=i}}();var u,l=[],c=!1,d=-1;function p(){c&&u&&(c=!1,u.length?l=u.concat(l):d=-1,l.length&&f())}function f(){if(!c){var e=s(p);c=!0;for(var t=l.length;t;){for(u=l,l=[];++d<t;)u&&u[d].run();d=-1,t=l.length}u=null,c=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===i||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function h(e,t){this.fun=e,this.array=t}function m(){}a.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];l.push(new h(e,t)),1!==l.length||c||s(f)},h.prototype.run=function(){this.fun.apply(null,this.array)},a.title="browser",a.browser=!0,a.env={},a.argv=[],a.version="",a.versions={},a.on=m,a.addListener=m,a.once=m,a.off=m,a.removeListener=m,a.removeAllListeners=m,a.emit=m,a.prependListener=m,a.prependOnceListener=m,a.listeners=function(e){return[]},a.binding=function(e){throw new Error("process.binding is not supported")},a.cwd=function(){return"/"},a.chdir=function(e){throw new Error("process.chdir is not supported")},a.umask=function(){return 0}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(347),s=n(27),u=n(29),l=n(8),c=n(10),d=n(39),p=n(40),f=function(e){function t(n){var r=e.call(this,n)||this;return r.componentDidMount=function(){var e=r.props,t=e.auth0ClientId,n=e.auth0Hash,a=e.onAuthenticated,o=e.baseUrl;u.default.bindToClient(t),n?u.default.parseIdFromHash(n).then((function(e){s.default.getAccessData(e.idToken,o).then((function(t){r.props.login(e),r.props.cacheAccessData(t),s.default.buildFreshSession(e,t),a()})).catch((function(e){u.default.login()}))})).catch((function(e){u.default.login()})):u.default.login()},r.render=function(){return o.createElement("div",{className:"auth-gate"},o.createElement(i.default,{color:t.LOADER_COLOR}))},r}return a(t,e),t.LOADER_COLOR="#2d8ceb",t}(o.PureComponent);t.default=l.connect(null,(function(e){return c.bindActionCreators({login:d.login,cacheAccessData:p.cacheAccessData},e)}))(f)},function(e,t,n){"use strict";var r,a=this&&this.__makeTemplateObject||function(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e},o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t};Object.defineProperty(t,"__esModule",{value:!0});var s,u,l=i(n(0)),c=n(532),d=n(350),p=c.keyframes(s||(s=a(["\n 0% {transform: scaley(1.0)}\n 50% {transform: scaley(0.4)}\n 100% {transform: scaley(1.0)}\n"],["\n 0% {transform: scaley(1.0)}\n 50% {transform: scaley(0.4)}\n 100% {transform: scaley(1.0)}\n"]))),f=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.style=function(e){var n=t.props,r=n.color,o=n.width,i=n.height,s=n.margin,l=n.radius,d=n.widthUnit,f=n.heightUnit,h=n.radiusUnit;return c.css(u||(u=a(["\n background-color: ",";\n width: ",";\n height: ",";\n margin: ",";\n border-radius: ",";\n display: inline-block;\n animation: "," 1s ","s infinite cubic-bezier(0.2, 0.68, 0.18, 1.08);\n animation-fill-mode: both;\n "],["\n background-color: ",";\n width: ",";\n height: ",";\n margin: ",";\n border-radius: ",";\n display: inline-block;\n animation: "," 1s ","s infinite cubic-bezier(0.2, 0.68, 0.18, 1.08);\n animation-fill-mode: both;\n "])),r,""+o+d,""+i+f,s,""+l+h,p,.1*e)},t}return o(t,e),t.prototype.render=function(){var e=this.props,t=e.loading,n=e.css;return t?c.jsx("div",{css:[n]},c.jsx("div",{css:this.style(1)}),c.jsx("div",{css:this.style(2)}),c.jsx("div",{css:this.style(3)}),c.jsx("div",{css:this.style(4)}),c.jsx("div",{css:this.style(5)})):null},t.defaultProps=d.heightWidthRadiusDefaults(35,4,2),t}(l.PureComponent);t.default=f},function(e,t,n){var r=n(349);e.exports=function(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,r(e,t)},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){function n(t,r){return e.exports=n=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},e.exports.default=e.exports,e.exports.__esModule=!0,n(t,r)}e.exports=n,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){"use strict";function r(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),r(n(351)),r(n(352))},function(e,t,n){"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0});var a=((r={}).loading=!0,r.color="#000000",r.css={},r);t.sizeDefaults=function(e){return Object.assign({},a,function(e){var t;return(t={}).size=e,t.sizeUnit="px",t}(e))},t.sizeMarginDefaults=function(e){var n;return Object.assign({},t.sizeDefaults(e),((n={}).margin="2px",n))},t.heightWidthDefaults=function(e,t){return Object.assign({},a,function(e,t){var n;return(n={}).height=e,n.heightUnit="px",n.width=t,n.widthUnit="px",n}(e,t))},t.heightWidthRadiusDefaults=function(e,n,r){var a;return void 0===r&&(r=2),Object.assign({},t.heightWidthDefaults(e,n),((a={}).radius=r,a.radiusUnit="px",a.margin="2px",a))}},function(e,t,n){"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),function(e){e.maroon="#800000",e.red="#FF0000",e.orange="#FFA500",e.yellow="#FFFF00",e.olive="#808000",e.green="#008000",e.purple="#800080",e.fuchsia="#FF00FF",e.lime="#00FF00",e.teal="#008080",e.aqua="#00FFFF",e.blue="#0000FF",e.navy="#000080",e.black="#000000",e.gray="#808080",e.silver="#C0C0C0",e.white="#FFFFFF"}(r||(r={})),t.calculateRgba=function(e,t){if(Object.keys(r).includes(e)&&(e=r[e]),"#"===e[0]&&(e=e.slice(1)),3===e.length){var n="";e.split("").forEach((function(e){n+=e,n+=e})),e=n}return"rgba("+e.match(/.{2}/g).map((function(e){return parseInt(e,16)})).join(", ")+", "+t+")"}},function(e,t){e.exports=l},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i};Object.defineProperty(t,"__esModule",{value:!0});var o,i=n(0),s=n(355),u=n(21),l=n(4),c=n(356),d=n(357),p=function(e){return i.createElement("div",{className:"ip-table-loader"},i.createElement(u.default,null))},f=function(e){return i.createElement("div",{className:"ip-table-empty"},i.createElement("span",{className:"empty-message"},l.ICON_EXCLAIMATION_TRIANGLE," ",e.copy||"No Data Found"))},h=function(e){[32,37,38,39,40].indexOf(e.keyCode)>-1&&e.preventDefault()};t.default=function(e){var t=i.useRef(null),n=i.useRef(null),u=a(i.useState(!1),2),m=u[0],_=u[1],y=a(i.useState([]),2),g=y[0],v=y[1],b=a(i.useState([]),2),w=b[0],M=b[1],L=Array.isArray(e.hiddenColumns)?e.hiddenColumns:[],T=Number.isInteger(e.currentPage)&&"function"==typeof e.onPage,k="function"==typeof e.onSort&&void 0!==e.sortBy,x="function"==typeof e.renderPivotComponent?e.renderPivotComponent:function(){return null},E="function"==typeof e.onRowDoubleClick,S={hiddenColumns:L,sortBy:k?e.sortBy:[],pageIndex:T?e.currentPage-1:void 0,pageSize:e.itemsPerPage,autoResetExpanded:!1},O=c.useTable({columns:w,data:g,manualSortBy:k,manualPagination:T,initialState:S,manualFilters:!0,disableMultiSorting:!0,autoResetExpanded:!1,disableSortRemove:k,pageCount:e.totalPages,pageSize:e.itemsPerPage},c.useFlexLayout,c.useFilters,c.useSortBy,c.useExpanded,c.usePagination,c.useResizeColumns),D=O.getTableProps,Y=O.getTableBodyProps,A=O.headerGroups,C=O.page,j=O.rows,P=O.prepareRow,H=O.canPreviousPage,I=O.canNextPage,N=O.pageOptions,R=O.pageCount,F=O.gotoPage,z=O.nextPage,U=O.previousPage,W=O.setPageSize,B=O.setHiddenColumns,V=O.visibleColumns,G=O.totalColumnsWidth,q=O.toggleAllRowsExpanded,J=O.state,K=J.pageIndex,$=J.pageSize,X=J.sortBy,Z=T?j:C,Q=e.hidePaginator?"hide-paginator":"",ee=t.current&&G>t.current.clientWidth?"horizontal-scroll":"",te=e.tightRows?"tight-rows":"";return i.useEffect((function(){return _(!0)}),[]),i.useEffect((function(){var t,n;M((t=e.columns,Array.isArray(t)?t:!Array.isArray(t)&&"object"==typeof t&&(n=Object.keys(t)).length>0?n.map((function(e){return r(r({},t[e]),{accessor:e})})):[]))}),[e.columns]),i.useEffect((function(){m&&Array.isArray(e.hiddenColumns)&&B(e.hiddenColumns)}),[e.hiddenColumns]),i.useEffect((function(){Array.isArray(e.data)&&v(e.data)}),[e.data]),i.useEffect((function(){m&&T&&q(!1)}),[e.currentPage]),i.useEffect((function(){m&&k&&e.onSort(X)}),[X]),i.createElement("section",{ref:t,className:"ip-table-wrapper",tabIndex:e.disableKeyScroll?0:void 0,onKeyDown:e.disableKeyScroll?h:null},e.showInterstitial&&i.createElement(p,null),m&&!e.showInterstitial&&0===g.length&&i.createElement(f,{copy:e.noDataText}),i.createElement("table",r({},D(),{className:"ip-table "+ee+" "+Q+" "+te}),i.createElement("thead",{className:"ip-table-head"},A.map((function(e){return i.createElement(i.Fragment,{key:"head-fragment"},i.createElement("tr",r({},e.getHeaderGroupProps(),{className:"ip-table-head-row"}),e.headers.map((function(e){var t=e.hasOwnProperty("Search"),n=e.getSortByToggleProps(),a=i.createElement("span",{className:"sort-status"},e.isSorted?e.isSortedDesc?l.ICON_CHEVRON_DOWN:l.ICON_CHEVRON_UP:null);return i.createElement("th",r({},e.getHeaderProps(),{className:"ip-table-header "+(e.canSort?"ip-sortable":"")}),!t&&i.createElement("div",r({},n,{className:"filterable-cell-wrapper"}),e.render("Header"),a),t&&i.createElement("div",{className:"filterable-cell-wrapper"},i.createElement("span",r({},n,{className:"searchable-sort-area"}),e.render("Header"),a),e.hasOwnProperty("Search")&&e.render("Search")),e.canResize&&i.createElement("div",r({},e.getResizerProps(),{className:"ip-table-resizer "+(e.isResizing?"resizing":"")})))}))),e.headers.some((function(e){return e.hasOwnProperty("Filter")}))&&i.createElement("tr",r({},e.getHeaderGroupProps({key:"filters-row"})),e.headers.map((function(e,t){return i.createElement("th",r({},e.getHeaderProps({key:"filter-"+t}),{key:"filter-col-"+t,className:"ip-table-filter"}),e.canFilter&&e.Filter?e.render("Filter"):null)}))))}))),i.createElement("tbody",r({},Y(),{className:"ip-table-body"}),Z.map((function(t,a){var s,u="";e.highlightBy&&t.original.hasOwnProperty(e.highlightBy.key)&&t.original[e.highlightBy.key]===e.highlightBy.value&&(u="selected",s=n),P(t);var l=t.getRowProps();l.className="ip-table-row "+u,l.onClick=function(n){var r=function(){"function"==typeof e.onRowClick&&e.onRowClick(t)};E||r(),1===n.detail&&E&&(o=window.setTimeout(r,200))},l.onDoubleClick=function(n){clearTimeout(o),E&&e.onRowDoubleClick(t)};var c=t.cells.map((function(e){return i.createElement("td",r({},e.getCellProps(),{className:("ip-table-col "+(e.column.overflowVisible?"overflow-visible":"")).trim()}),e.render("Cell"))}));return i.createElement(i.Fragment,{key:"row-"+a},e.dnd&&i.createElement(d.default,{rowProps:l,rowRef:s,key:"row-"+a,row:t,dndType:e.dndType,dndName:e.dndName},c),!e.dnd&&i.createElement("tr",r({key:"row-"+a,ref:s},l),c),t.isExpanded&&i.createElement("tr",r({},t.getRowProps({key:"pivot-row"}),{className:"ip-pivot-row"}),i.createElement("td",{className:"ip-pivot-col "+u,colSpan:V.length},x(t))))})))),!e.hidePaginator&&i.createElement(s.default,r({},{totalItems:e.totalItems,pageIndex:e.currentPage?e.currentPage:K,manualPagination:T,pageSize:$,pageCount:R,pageOptions:N,canNextPage:T?e.currentPage+1<=e.totalPages:I,canPreviousPage:T?e.currentPage-1>=1:H,gotoPage:T?e.onPage:F,setPageSize:W,nextPage:T?function(){return e.onPage(e.currentPage+1,$)}:z,previousPage:T?function(){return e.onPage(e.currentPage-1,$)}:U})))}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,a=n(0),o=n(5),i=n(4);t.default=function(e){e.manualPagination;var t=e.pageCount,n=e.pageIndex,s=e.pageSize,u=(e.pageOptions,e.totalItems),l=e.canPreviousPage,c=e.canNextPage,d=e.gotoPage,p=e.previousPage,f=e.nextPage;e.setPageSize;return a.createElement("section",{className:"ip-table-pagination"},a.createElement("span",null,a.createElement(o.default,{style:"subtle",size:"small",tooltip:"Go to first page",disabled:!l,onClick:function(){return d(1,s)}},i.ICON_ANGLE_DOUBLE_LEFT),a.createElement(o.default,{style:"subtle",size:"small",tooltip:"Go to previous page",disabled:!l,onClick:function(){return p()}},i.ICON_ANGLE_LEFT),a.createElement(o.default,{style:"subtle",size:"small",tooltip:"Go to next page",disabled:!c,onClick:function(){return f()}},i.ICON_ANGLE_RIGHT),a.createElement(o.default,{style:"subtle",size:"small",tooltip:"Go to last page",disabled:!c,onClick:function(){return d(t,s)}},i.ICON_ANGLE_DOUBLE_RIGHT),"  ",a.createElement("span",null,"Page  ",a.createElement("strong",null,n," of ",t),"  "),a.createElement("span",null,"Go to page   ",a.createElement("input",{className:"paginator-input",type:"number",placeholder:n,onChange:function(e){var n,a=e.target.value,o=Number(a);clearTimeout(r),!a||o<1||o>t||(o>=1&&o<=t&&(n=o),r=window.setTimeout((function(){return d(n,s)}),300))}})),"  "),a.createElement("span",{className:"total-assets"},"Total  ",a.createElement("strong",null,u||0)))}},function(e,t){e.exports=c},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i};Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(61),s=n(358);t.default=function(e){var t=e.dndType,n=e.dndName,u=e.row,l=a(i.useDrag({type:t,item:{name:n,rowData:u.original,type:t}}),2),c=(l[0],l[1]);return o.createElement("tr",r({},e.rowProps,{ref:s.default([c,e.rowRef])}),e.children)}},function(e,t,n){"use strict";n.r(t),t.default=function(e){return function(t){e.forEach((function(e){"function"==typeof e?e(t):null!=e&&(e.current=t)}))}}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(5),s=n(22),u=n(4),l=function(e){function t(n){var r=e.call(this,n)||this;return r.render=function(){for(var e=r.props,n=e.page,a=e.totalPages,l=e.totalItems,c=Number.isInteger(a),d=Number.isInteger(a)&&a>1,p=!c||n-1==0,f=!c||n+1>a,h=Math.max(n-t.DEFAULT_STEP,1),m=Math.min(n+t.DEFAULT_STEP,a),_=[],y=h;y<=m;y++)_.push(y);return o.createElement("div",{className:"paginator"},o.createElement("div",{className:"pagination-controls"},o.createElement("span",{className:"paging-button-group"},o.createElement(i.default,{color:"secondary",size:"small",disabled:p,onClick:function(){return r.props.onPage(1)}},u.ICON_ANGLE_DOUBLE_LEFT),o.createElement(i.default,{color:"secondary",size:"small",disabled:p,onClick:function(){return r.props.onPage(n-1)}},u.ICON_ANGLE_LEFT)),o.createElement("div",{className:"jump-to-wrapper"},o.createElement(s.default,{label:"Page",value:n,disable:!d,options:_,onChange:function(e){return r.props.onPage(parseInt(e,10))}})),o.createElement("span",{className:"paging-button-group"},o.createElement(i.default,{color:"secondary",size:"small",disabled:f,onClick:function(){return r.props.onPage(n+1)}},u.ICON_ANGLE_RIGHT),o.createElement(i.default,{color:"secondary",size:"small",disabled:f,onClick:function(){return r.props.onPage(a)}},u.ICON_ANGLE_DOUBLE_RIGHT))),o.createElement("div",{className:"total-assets"},"Total: ",l||t.DEFAULT_TOTAL))},r}return a(t,e),t.DEFAULT_TOTAL=0,t.DEFAULT_STEP=25,t}(o.PureComponent);t.default=l},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(5),s=n(4),u=function(e){function t(t){var n=e.call(this,t)||this;return n.closeStyles={position:"absolute",right:"0px",top:"0px"},n.evtHandlers={onClose:function(e){return n.onClose(e)}},n}return a(t,e),t.prototype.onClose=function(e){(0,this.props.onRequestClose)(e)},t.prototype.render=function(){var e=this.props,t=e.isOpen,n=(e.children,e.style),r=e.wrapperStyle;return t?o.createElement("div",{className:"modal",style:r},o.createElement("div",{className:"modal-bg",onClick:this.evtHandlers.onClose}),o.createElement("div",{className:"modal-container",style:n},o.createElement("div",{className:"modal-content"},this.props.children),o.createElement(i.default,{onClick:this.evtHandlers.onClose,customStyles:this.closeStyles},s.ICON_TIMES))):null},t}(o.PureComponent);t.default=u},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__values||function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(101),u=n(97),l=n(98),c=n(5),d=n(4),p=function(e){function t(t){var n=e.call(this,t)||this;return n.headerRef=i.createRef(),n.state={allowableTabsInView:0,isMenuOpen:!1},n}return a(t,e),t.prototype.componentDidMount=function(){var e=Math.floor(this.allowableNumOfTabs());this.setState({allowableTabsInView:e})},t.prototype.componentDidUpdate=function(e){var t=Math.floor(this.allowableNumOfTabs());this.setState({allowableTabsInView:t})},t.prototype.allowableNumOfTabs=function(){var e=this.props,t=e.options,n=e.tabPadding,r=0,a=this.headerRef.current;if(a){for(var o=a.offsetWidth,i=0;i<t.length;i++){var s=t[i],u=s.canClose||s.menuButtons?20:0,l=document.createElement("div");if(l.className="tab-header-option",l.innerHTML=s.label,a.appendChild(l),r+=l.offsetWidth+u,a.removeChild(l),l=null,r>=o-n-25)return i}return t.length}},t.prototype.renderContent=function(){var e,t,n,r,a=this.props,s=a.options,u=a.activeTab,l=a.keepMounted,c=a.width,d=a.height;if(l){var p=[];try{for(var f=o(s),h=f.next();!h.done;h=f.next()){var m=(v=h.value).key===u,_=i.cloneElement(v.content,{active:m,width:c,height:d});p.push(_)}}catch(t){e={error:t}}finally{try{h&&!h.done&&(t=f.return)&&t.call(f)}finally{if(e)throw e.error}}return p.length>0?p:null}try{for(var y=o(s),g=y.next();!g.done;g=y.next()){var v;if((v=g.value).key===u||!u)return v.content}}catch(e){n={error:e}}finally{try{g&&!g.done&&(r=y.return)&&r.call(y)}finally{if(n)throw n.error}}return null},t.prototype.renderHeader=function(){for(var e=this,t=this.props,n=t.options,r=t.activeTab,a=[],o=[],s=!1,p=function(t){var u=n[t],p=u.canClose,h=u.key,m=u.label,_=u.menuButtons,y=p?i.createElement(c.default,{style:"subtle",size:"small",onClick:function(t){t.preventDefault(),t.stopPropagation(),e.props.onClose(h)}},d.ICON_TIMES):null,g=_||null,v=h===r?"active":"";t<f.state.allowableTabsInView?a.push(i.createElement("div",{className:"tab-header-option "+v,onClick:function(){return e.props.onChange(h)},key:h},m,y,g)):(r!==h||s||(s=!0),o.push(i.createElement(l.default,{key:h,label:i.createElement("span",null,m,y,g),onClick:function(t){e.props.onChange(h)},active:r===h})))},f=this,h=0;h<n.length;h++)p(h);var m=i.createElement(c.default,{size:"large",style:"subtle",color:s?"primary":null},d.ICON_BARS);return i.createElement(i.Fragment,null,a,o.length>0?i.createElement("span",{className:"tab-header-menu"},i.createElement(u.default,{position:"left",items:o,onClick:function(t){e.setState({isMenuOpen:t})},isOpen:this.state.isMenuOpen,button:m})):null)},t.prototype.render=function(){return i.createElement("div",{className:"tabs"},i.createElement("div",{ref:this.headerRef,className:"tab-header"},this.renderHeader()),i.createElement("div",{className:"tab-content"},this.renderContent()))},t}(i.PureComponent);t.default=s.withResizeDetector(p)},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(0),u=n(62),l=n(5),c=n(11),d=n(100),p=n(9),f=n(4),h=function(e){function t(t){var n=e.call(this,t)||this;return n.state={textInputValue:""},n.inputRef=s.createRef(),u.default.filter=function(e){return p.filterHotkeys(e)},n.submitHandler=function(){return n.submitOption()},n}return a(t,e),t.prototype.deleteOption=function(e){var t=i([],o(this.props.options));t.splice(e,1),this.props.onChange(t)},t.prototype.componentWillUnmount=function(){u.default.unbind("enter",this.submitHandler)},t.prototype.inputBlur=function(e){u.default.unbind("enter",this.submitHandler),this.props.onBlur&&this.props.onBlur()},t.prototype.inputChanged=function(e){this.setState({textInputValue:e.target.value})},t.prototype.inputFocus=function(e){u.default("enter",this.submitHandler),this.props.onFocus&&this.props.onFocus()},t.prototype.submitOption=function(){var e=this,t=this.state.textInputValue,n=this.props.onError;if(""!==t){var r=void 0;-1===(r=this.props.options?i([],o(this.props.options)):[]).indexOf(t)?(r.push(t),this.props.onChange(r),this.setState({textInputValue:""},(function(){var t=e.inputRef.current;t&&t.focus()}))):n&&this.props.onError('"'+t+'" already exists in the list.')}else n&&this.props.onError("Can not add an empty item to the list")},t.prototype.render=function(){var e=this,t=this.props,n=t.label,r=t.options,a=t.placeholder,o=t.disabled,i=t.width,u=t.tooltip,l=(t.tooltipAdd,t.info),p=t.labelPosition,f=this.state.textInputValue;return s.createElement(c.default,{customClass:"list-field",label:n,tooltip:u,buttons:this.renderButtons(),info:l,labelPosition:p,width:i},s.createElement("input",{type:"text",placeholder:a,value:f,ref:this.inputRef,disabled:o,onChange:function(t){return e.inputChanged(t)},onFocus:function(t){return e.inputFocus(t)},onBlur:function(t){return e.inputBlur(t)}}),s.createElement(d.default,{items:r,removable:!0,onRemove:function(t){return e.deleteOption(t)}}))},t.prototype.renderButtons=function(){var e=this.props,t=e.buttons,n=e.tooltipAdd,r=t?i([],o(t)):[];return r.push(s.createElement(l.default,{key:"btn-submit",style:"subtle",tooltip:n,color:"primary",onClick:this.submitHandler},f.ICON_PLUS)),r},t}(s.PureComponent);t.default=h},function(e,t){e.exports=d},function(e,t,n){"use strict";n.r(t),n.d(t,"Toast",(function(){return d}));var r=n(0),a=n.n(r),o=n(35),i=n.n(o),s=n(2),u=function(){return(u=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};var l={success:function(e){return a.a.createElement("svg",u({viewBox:"0 0 426.667 426.667",width:18,height:18},e),a.a.createElement("path",{d:"M213.333 0C95.518 0 0 95.514 0 213.333s95.518 213.333 213.333 213.333c117.828 0 213.333-95.514 213.333-213.333S331.157 0 213.333 0zm-39.134 322.918l-93.935-93.931 31.309-31.309 62.626 62.622 140.894-140.898 31.309 31.309-172.203 172.207z",fill:"#6ac259"}))},warn:function(e){return a.a.createElement("svg",u({viewBox:"0 0 310.285 310.285",width:18,height:18},e),a.a.createElement("path",{d:"M264.845 45.441C235.542 16.139 196.583 0 155.142 0 113.702 0 74.743 16.139 45.44 45.441 16.138 74.743 0 113.703 0 155.144c0 41.439 16.138 80.399 45.44 109.701 29.303 29.303 68.262 45.44 109.702 45.44s80.399-16.138 109.702-45.44c29.303-29.302 45.44-68.262 45.44-109.701.001-41.441-16.137-80.401-45.439-109.703zm-132.673 3.895a12.587 12.587 0 0 1 9.119-3.873h28.04c3.482 0 6.72 1.403 9.114 3.888 2.395 2.485 3.643 5.804 3.514 9.284l-4.634 104.895c-.263 7.102-6.26 12.933-13.368 12.933H146.33c-7.112 0-13.099-5.839-13.345-12.945L128.64 58.594c-.121-3.48 1.133-6.773 3.532-9.258zm23.306 219.444c-16.266 0-28.532-12.844-28.532-29.876 0-17.223 12.122-30.211 28.196-30.211 16.602 0 28.196 12.423 28.196 30.211.001 17.591-11.456 29.876-27.86 29.876z",fill:"#FFDA44"}))},loading:function(e){return a.a.createElement("div",u({className:"ct-icon-loading"},e))},info:function(e){return a.a.createElement("svg",u({viewBox:"0 0 23.625 23.625",width:18,height:18},e),a.a.createElement("path",{d:"M11.812 0C5.289 0 0 5.289 0 11.812s5.289 11.813 11.812 11.813 11.813-5.29 11.813-11.813S18.335 0 11.812 0zm2.459 18.307c-.608.24-1.092.422-1.455.548a3.838 3.838 0 0 1-1.262.189c-.736 0-1.309-.18-1.717-.539s-.611-.814-.611-1.367c0-.215.015-.435.045-.659a8.23 8.23 0 0 1 .147-.759l.761-2.688c.067-.258.125-.503.171-.731.046-.23.068-.441.068-.633 0-.342-.071-.582-.212-.717-.143-.135-.412-.201-.813-.201-.196 0-.398.029-.605.09-.205.063-.383.12-.529.176l.201-.828c.498-.203.975-.377 1.43-.521a4.225 4.225 0 0 1 1.29-.218c.731 0 1.295.178 1.692.53.395.353.594.812.594 1.376 0 .117-.014.323-.041.617a4.129 4.129 0 0 1-.152.811l-.757 2.68a7.582 7.582 0 0 0-.167.736 3.892 3.892 0 0 0-.073.626c0 .356.079.599.239.728.158.129.435.194.827.194.185 0 .392-.033.626-.097.232-.064.4-.121.506-.17l-.203.827zm-.134-10.878a1.807 1.807 0 0 1-1.275.492c-.496 0-.924-.164-1.28-.492a1.57 1.57 0 0 1-.533-1.193c0-.465.18-.865.533-1.196a1.812 1.812 0 0 1 1.28-.497c.497 0 .923.165 1.275.497.353.331.53.731.53 1.196 0 .467-.177.865-.53 1.193z",fill:"#006DF0"}))},error:function(e){return a.a.createElement("svg",u({viewBox:"0 0 51.976 51.976",width:18,height:18},e),a.a.createElement("path",{d:"M44.373 7.603c-10.137-10.137-26.632-10.138-36.77 0-10.138 10.138-10.137 26.632 0 36.77s26.632 10.138 36.77 0c10.137-10.138 10.137-26.633 0-36.77zm-8.132 28.638a2 2 0 0 1-2.828 0l-7.425-7.425-7.778 7.778a2 2 0 1 1-2.828-2.828l7.778-7.778-7.425-7.425a2 2 0 1 1 2.828-2.828l7.425 7.425 7.071-7.071a2 2 0 1 1 2.828 2.828l-7.071 7.071 7.425 7.425a2 2 0 0 1 0 2.828z",fill:"#D80027"}))}},c={success:"#6EC05F",info:"#1271EC",warn:"#FED953",error:"#D60A2E",loading:"#0088ff"},d=function(e){var t,n,o,i,s="margin"+((e.position||"top-center").includes("bottom")?"Bottom":"Top"),d=["ct-toast",e.onClick?" ct-cursor-pointer":"","ct-toast-"+e.type].join(" "),p=((null===(n=e.bar)||void 0===n?void 0:n.size)||"3px")+" "+((null===(o=e.bar)||void 0===o?void 0:o.style)||"solid")+" "+((null===(i=e.bar)||void 0===i?void 0:i.color)||c[e.type]),f=l[e.type],h=Object(r.useState)(((t={opacity:0})[s]=-15,t)),m=h[0],_=h[1],y=u({paddingLeft:e.heading?25:void 0,minHeight:e.heading?50:void 0,borderLeft:p},m),g=function(){var t;_(((t={opacity:0})[s]="-15px",t)),setTimeout((function(){e.onHide(e.id,e.position)}),300)};Object(r.useEffect)((function(){var t,n=setTimeout((function(){var e;_(((e={opacity:1})[s]="15px",e))}),50);return 0!==e.hideAfter&&(t=setTimeout((function(){g()}),1e3*e.hideAfter)),function(){clearTimeout(n),t&&clearTimeout(t)}}),[]),Object(r.useEffect)((function(){e.show||g()}),[e.show]);var v={tabIndex:0,onClick:e.onClick,onKeyPress:function(t){13===t.keyCode&&e.onClick(t)}};return a.a.createElement("div",u({className:d,role:e.role?e.role:"status",style:y},e.onClick?v:{}),e.renderIcon?e.renderIcon():a.a.createElement(f,null),a.a.createElement("div",{className:e.heading?"ct-text-group-heading":"ct-text-group"},e.heading&&a.a.createElement("h4",{className:"ct-heading"},e.heading),a.a.createElement("div",{className:"ct-text"},e.text)))};d.propTypes={type:s.string.isRequired,text:Object(s.oneOfType)([s.string,s.node]).isRequired,show:s.bool,onHide:s.func,id:Object(s.oneOfType)([s.string,s.number]),hideAfter:s.number,heading:s.string,position:s.string,renderIcon:s.func,bar:Object(s.shape)({}),onClick:s.func,role:s.string},d.defaultProps={id:void 0,show:!0,onHide:void 0,hideAfter:3,heading:void 0,position:"top-center",renderIcon:void 0,bar:{},onClick:void 0,role:"status"};var p=function(e){return e.replace(/-([a-z])/g,(function(e){return e[1].toUpperCase()}))},f={topLeft:[],topCenter:[],topRight:[],bottomLeft:[],bottomCenter:[],bottomRight:[]},h=function(e){var t=e.toast,n=e.hiddenID,o=Object(r.useState)(f),i=o[0],s=o[1];Object(r.useEffect)((function(){t&&s((function(e){var n,r=p(t.position||"top-center");return u(u({},e),((n={})[r]=function(){for(var e=0,t=0,n=arguments.length;t<n;t++)e+=arguments[t].length;var r=Array(e),a=0;for(t=0;t<n;t++)for(var o=arguments[t],i=0,s=o.length;i<s;i++,a++)r[a]=o[i];return r}(e[r],[t]),n))}))}),[t]);var l=function(e,t){s((function(n){var r,a=p(t||"top-center");return u(u({},n),((r={})[a]=n[a].filter((function(t){return t.id!==e})),r))}))},c=["Left","Center","Right"];return a.a.createElement(a.a.Fragment,null,["top","bottom"].map((function(e){return a.a.createElement("div",{key:"row_"+e,className:"ct-row"},c.map((function(t){var r=""+e+t,o=["ct-group","bottom"===e?"ct-flex-bottom":""].join(" ");return a.a.createElement("div",{key:r,className:o},i[r].map((function(e){return a.a.createElement(d,u({key:r+"_"+e.id},e,{id:e.id,text:e.text,type:e.type,onClick:e.onClick,hideAfter:e.hideAfter,show:n!==e.id,onHide:l}))})))})))})))};h.propTypes={toast:Object(s.shape)({}),hiddenID:s.number},h.defaultProps={toast:void 0,hiddenID:void 0};!function(e,t){void 0===t&&(t={});var n=t.insertAt;if(e&&"undefined"!=typeof document){var r=document.head||document.getElementsByTagName("head")[0],a=document.createElement("style");a.type="text/css","top"===n&&r.firstChild?r.insertBefore(a,r.firstChild):r.appendChild(a),a.styleSheet?a.styleSheet.cssText=e:a.appendChild(document.createTextNode(e))}}("#ct-container {\n\tposition: fixed;\n\twidth: 100%;\n\theight: 100vh;\n\ttop: 0px;\n\tleft: 0px;\n\tz-index: 2000;\n\tdisplay: flex;\n\tflex-direction: column;\n\tjustify-content: space-between;\n\tpointer-events: none;\n}\n\n.ct-row {\n\tdisplay: flex;\n\tjustify-content: space-between;\n}\n\n.ct-group {\n\tflex: 1;\n\tmargin: 10px 20px;\n\tdisplay: flex;\n\tflex-direction: column;\n\talign-items: center;\n}\n\n.ct-group:first-child {\n\talign-items: flex-start;\n}\n\n.ct-group:last-child {\n\talign-items: flex-end;\n}\n\n.ct-flex-bottom {\n\tjustify-content: flex-end;\n}\n\n.ct-toast {\n\tdisplay: flex;\n\tjustify-content: center;\n\talign-items: center;\n\tpadding: 12px 20px;\n\tbackground-color: #fff;\n\tbox-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);\n\tcolor: #000;\n\tborder-radius: 4px;\n\tmargin: 0px;\n\topacity: 1;\n\ttransition: 0.3s all ease-in-out;\n\tmin-height: 45px;\n\tpointer-events: all;\n}\n\n.ct-toast:focus {\n\toutline: none;\n}\n\n.ct-toast svg {\n\tmin-width: 18px;\n}\n\n.ct-cursor-pointer {\n\tcursor: pointer;\n}\n\n.ct-icon-loading {\n\tdisplay: inline-block;\n\twidth: 20px;\n\theight: 20px;\n}\n\n.ct-icon-loading:after {\n\tcontent: ' ';\n\tdisplay: block;\n\twidth: 14px;\n\theight: 14px;\n\tmargin: 1px;\n\tborder-radius: 50%;\n\tborder: 2px solid #0088ff;\n\tborder-color: #0088ff transparent #0088ff transparent;\n\tanimation: ct-icon-loading 1.2s linear infinite;\n}\n\n@keyframes ct-icon-loading {\n\t0% {\n\t\ttransform: rotate(0deg);\n\t}\n\t100% {\n\t\ttransform: rotate(360deg);\n\t}\n}\n\n.ct-text-group {\n\tmargin-left: 15px;\n}\n\n.ct-text-group-heading {\n\tmargin-left: 25px;\n}\n\n.ct-heading {\n\tfont-size: 18px;\n\tmargin: 0px;\n\tmargin-bottom: 5px;\n}\n\n.ct-text {\n\tfont-size: 14px;\n}\n\n@media (max-width: 768px) {\n\t.ct-row {\n\t\tjustify-content: flex-start;\n\t\tflex-direction: column;\n\t\tmargin: 7px 0px;\n\t}\n\n\t.ct-group {\n\t\tflex: none;\n\t\tmargin: 0px;\n\t}\n\n\t.ct-toast {\n\t\tmargin: 8px 15px;\n\t\twidth: initial;\n\t}\n}\n");var m=0,_=function(e,t){var n,r,o=document.getElementById((null===(n=t)||void 0===n?void 0:n.toastContainerID)||"ct-container");o||((o=document.createElement("div")).id="ct-container",document.body.appendChild(o)),m+=1;var s=1e3*(void 0===(null===(r=t)||void 0===r?void 0:r.hideAfter)?3:t.hideAfter),l=u({id:m,text:e},t);i.a.render(a.a.createElement(h,{toast:l}),o);var c=new Promise((function(e){setTimeout((function(){e()}),s)}));return c.hide=function(){i.a.render(a.a.createElement(h,{hiddenID:l.id}),o)},c};_.success=function(e,t){return _(e,u(u({},t),{type:"success"}))},_.warn=function(e,t){return _(e,u(u({},t),{type:"warn"}))},_.info=function(e,t){return _(e,u(u({},t),{type:"info"}))},_.error=function(e,t){return _(e,u(u({},t),{type:"error"}))},_.loading=function(e,t){return _(e,u(u({},t),{type:"loading"}))},t.default=_},function(e,t,n){"use strict";var r=n(366);function a(){}function o(){}o.resetWarningCache=a,e.exports=function(){function e(e,t,n,a,o,i){if(i!==r){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:o,resetWarningCache:a};return n.PropTypes=n,n}},function(e,t,n){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(11),s=function(e){function t(t){var n=e.call(this,t)||this;return n.state={tempValue:null},n}return a(t,e),t.prototype.componentWillUnmount=function(){clearTimeout(this.updateTimeout)},t.prototype.updateValue=function(e){this.props.onChange(e)},t.prototype.rangeInputChange=function(e){var t=this,n=e.target.value,r=parseFloat(n);clearTimeout(this.updateTimeout),this.setState({tempValue:r},(function(){t.updateTimeout=setTimeout((function(){t.updateValue(r),t.setState({tempValue:null})}),100)}))},t.prototype.numberInputChange=function(e){var t=this.props,n=t.min,r=t.max,a=e.target.value;(a=""===a?0:parseFloat(a))>=n&&a<=r&&this.updateValue(a)},t.prototype.render=function(){var e=this,t=this.props,n=t.label,r=t.width,a=t.min,s=t.max,u=t.step,l=t.defaultValue,c=t.value,d=t.tooltip,p=t.info,f=t.labelPosition,h=this.state.tempValue,m=null!==h?h:null==c?l:c;return o.createElement(i.default,{customClass:"slider-field",label:n,tooltip:d,info:p,labelPosition:f,width:r},o.createElement("input",{onChange:function(t){return e.rangeInputChange(t)},type:"range",min:a,max:s,value:m,step:u}),o.createElement("input",{className:"val",onChange:function(t){return e.numberInputChange(t)},type:"number",value:m}))},t}(o.PureComponent);t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.flattenNames=void 0;var r=s(n(369)),a=s(n(66)),o=s(n(381)),i=s(n(382));function s(e){return e&&e.__esModule?e:{default:e}}var u=t.flattenNames=function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=[];return(0,i.default)(t,(function(t){Array.isArray(t)?e(t).map((function(e){return n.push(e)})):(0,o.default)(t)?(0,a.default)(t,(function(e,t){!0===e&&n.push(t),n.push(t+"-"+e)})):(0,r.default)(t)&&n.push(t)})),n};t.default=u},function(e,t,n){var r=n(18),a=n(12),o=n(15);e.exports=function(e){return"string"==typeof e||!a(e)&&o(e)&&"[object String]"==r(e)}},function(e,t,n){var r=n(31),a=Object.prototype,o=a.hasOwnProperty,i=a.toString,s=r?r.toStringTag:void 0;e.exports=function(e){var t=o.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var a=i.call(e);return r&&(t?e[s]=n:delete e[s]),a}},function(e,t){var n=Object.prototype.toString;e.exports=function(e){return n.call(e)}},function(e,t,n){var r=n(373)();e.exports=r},function(e,t){e.exports=function(e){return function(t,n,r){for(var a=-1,o=Object(t),i=r(t),s=i.length;s--;){var u=i[e?s:++a];if(!1===n(o[u],u,o))break}return t}}},function(e,t){e.exports=function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}},function(e,t,n){var r=n(18),a=n(15);e.exports=function(e){return a(e)&&"[object Arguments]"==r(e)}},function(e,t){e.exports=function(){return!1}},function(e,t,n){var r=n(18),a=n(68),o=n(15),i={};i["[object Float32Array]"]=i["[object Float64Array]"]=i["[object Int8Array]"]=i["[object Int16Array]"]=i["[object Int32Array]"]=i["[object Uint8Array]"]=i["[object Uint8ClampedArray]"]=i["[object Uint16Array]"]=i["[object Uint32Array]"]=!0,i["[object Arguments]"]=i["[object Array]"]=i["[object ArrayBuffer]"]=i["[object Boolean]"]=i["[object DataView]"]=i["[object Date]"]=i["[object Error]"]=i["[object Function]"]=i["[object Map]"]=i["[object Number]"]=i["[object Object]"]=i["[object RegExp]"]=i["[object Set]"]=i["[object String]"]=i["[object WeakMap]"]=!1,e.exports=function(e){return o(e)&&a(e.length)&&!!i[r(e)]}},function(e,t,n){var r=n(71),a=n(379),o=Object.prototype.hasOwnProperty;e.exports=function(e){if(!r(e))return a(e);var t=[];for(var n in Object(e))o.call(e,n)&&"constructor"!=n&&t.push(n);return t}},function(e,t,n){var r=n(109)(Object.keys,Object);e.exports=r},function(e,t,n){var r=n(111);e.exports=function(e){return"function"==typeof e?e:r}},function(e,t,n){var r=n(18),a=n(72),o=n(15),i=Function.prototype,s=Object.prototype,u=i.toString,l=s.hasOwnProperty,c=u.call(Object);e.exports=function(e){if(!o(e)||"[object Object]"!=r(e))return!1;var t=a(e);if(null===t)return!0;var n=l.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&u.call(n)==c}},function(e,t,n){var r=n(112),a=n(383),o=n(441),i=n(12);e.exports=function(e,t){return(i(e)?r:o)(e,a(t,3))}},function(e,t,n){var r=n(384),a=n(428),o=n(111),i=n(12),s=n(438);e.exports=function(e){return"function"==typeof e?e:null==e?o:"object"==typeof e?i(e)?a(e[0],e[1]):r(e):s(e)}},function(e,t,n){var r=n(385),a=n(427),o=n(122);e.exports=function(e){var t=a(e);return 1==t.length&&t[0][2]?o(t[0][0],t[0][1]):function(n){return n===e||r(n,e,t)}}},function(e,t,n){var r=n(73),a=n(114);e.exports=function(e,t,n,o){var i=n.length,s=i,u=!o;if(null==e)return!s;for(e=Object(e);i--;){var l=n[i];if(u&&l[2]?l[1]!==e[l[0]]:!(l[0]in e))return!1}for(;++i<s;){var c=(l=n[i])[0],d=e[c],p=l[1];if(u&&l[2]){if(void 0===d&&!(c in e))return!1}else{var f=new r;if(o)var h=o(d,p,c,e,t,f);if(!(void 0===h?a(p,d,3,o,f):h))return!1}}return!0}},function(e,t){e.exports=function(){this.__data__=[],this.size=0}},function(e,t,n){var r=n(45),a=Array.prototype.splice;e.exports=function(e){var t=this.__data__,n=r(t,e);return!(n<0)&&(n==t.length-1?t.pop():a.call(t,n,1),--this.size,!0)}},function(e,t,n){var r=n(45);e.exports=function(e){var t=this.__data__,n=r(t,e);return n<0?void 0:t[n][1]}},function(e,t,n){var r=n(45);e.exports=function(e){return r(this.__data__,e)>-1}},function(e,t,n){var r=n(45);e.exports=function(e,t){var n=this.__data__,a=r(n,e);return a<0?(++this.size,n.push([e,t])):n[a][1]=t,this}},function(e,t,n){var r=n(44);e.exports=function(){this.__data__=new r,this.size=0}},function(e,t){e.exports=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}},function(e,t){e.exports=function(e){return this.__data__.get(e)}},function(e,t){e.exports=function(e){return this.__data__.has(e)}},function(e,t,n){var r=n(44),a=n(75),o=n(76);e.exports=function(e,t){var n=this.__data__;if(n instanceof r){var i=n.__data__;if(!a||i.length<199)return i.push([e,t]),this.size=++n.size,this;n=this.__data__=new o(i)}return n.set(e,t),this.size=n.size,this}},function(e,t,n){var r=n(110),a=n(397),o=n(23),i=n(113),s=/^\[object .+?Constructor\]$/,u=Function.prototype,l=Object.prototype,c=u.toString,d=l.hasOwnProperty,p=RegExp("^"+c.call(d).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!o(e)||a(e))&&(r(e)?p:s).test(i(e))}},function(e,t,n){var r,a=n(398),o=(r=/[^.]+$/.exec(a&&a.keys&&a.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";e.exports=function(e){return!!o&&o in e}},function(e,t,n){var r=n(14)["__core-js_shared__"];e.exports=r},function(e,t){e.exports=function(e,t){return null==e?void 0:e[t]}},function(e,t,n){var r=n(401),a=n(44),o=n(75);e.exports=function(){this.size=0,this.__data__={hash:new r,map:new(o||a),string:new r}}},function(e,t,n){var r=n(402),a=n(403),o=n(404),i=n(405),s=n(406);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=a,u.prototype.get=o,u.prototype.has=i,u.prototype.set=s,e.exports=u},function(e,t,n){var r=n(46);e.exports=function(){this.__data__=r?r(null):{},this.size=0}},function(e,t){e.exports=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}},function(e,t,n){var r=n(46),a=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;if(r){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return a.call(t,e)?t[e]:void 0}},function(e,t,n){var r=n(46),a=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;return r?void 0!==t[e]:a.call(t,e)}},function(e,t,n){var r=n(46);e.exports=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=r&&void 0===t?"__lodash_hash_undefined__":t,this}},function(e,t,n){var r=n(47);e.exports=function(e){var t=r(this,e).delete(e);return this.size-=t?1:0,t}},function(e,t){e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},function(e,t,n){var r=n(47);e.exports=function(e){return r(this,e).get(e)}},function(e,t,n){var r=n(47);e.exports=function(e){return r(this,e).has(e)}},function(e,t,n){var r=n(47);e.exports=function(e,t){var n=r(this,e),a=n.size;return n.set(e,t),this.size+=n.size==a?0:1,this}},function(e,t,n){var r=n(73),a=n(115),o=n(418),i=n(421),s=n(48),u=n(12),l=n(67),c=n(108),d="[object Object]",p=Object.prototype.hasOwnProperty;e.exports=function(e,t,n,f,h,m){var _=u(e),y=u(t),g=_?"[object Array]":s(e),v=y?"[object Array]":s(t),b=(g="[object Arguments]"==g?d:g)==d,w=(v="[object Arguments]"==v?d:v)==d,M=g==v;if(M&&l(e)){if(!l(t))return!1;_=!0,b=!1}if(M&&!b)return m||(m=new r),_||c(e)?a(e,t,n,f,h,m):o(e,t,g,n,f,h,m);if(!(1&n)){var L=b&&p.call(e,"__wrapped__"),T=w&&p.call(t,"__wrapped__");if(L||T){var k=L?e.value():e,x=T?t.value():t;return m||(m=new r),h(k,x,n,f,m)}}return!!M&&(m||(m=new r),i(e,t,n,f,h,m))}},function(e,t,n){var r=n(76),a=n(414),o=n(415);function i(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new r;++t<n;)this.add(e[t])}i.prototype.add=i.prototype.push=a,i.prototype.has=o,e.exports=i},function(e,t){e.exports=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this}},function(e,t){e.exports=function(e){return this.__data__.has(e)}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}},function(e,t){e.exports=function(e,t){return e.has(t)}},function(e,t,n){var r=n(31),a=n(116),o=n(74),i=n(115),s=n(419),u=n(420),l=r?r.prototype:void 0,c=l?l.valueOf:void 0;e.exports=function(e,t,n,r,l,d,p){switch(n){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!d(new a(e),new a(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return o(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var f=s;case"[object Set]":var h=1&r;if(f||(f=u),e.size!=t.size&&!h)return!1;var m=p.get(e);if(m)return m==t;r|=2,p.set(e,t);var _=i(f(e),f(t),r,l,d,p);return p.delete(e),_;case"[object Symbol]":if(c)return c.call(e)==c.call(t)}return!1}},function(e,t){e.exports=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}},function(e,t){e.exports=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}},function(e,t,n){var r=n(117),a=Object.prototype.hasOwnProperty;e.exports=function(e,t,n,o,i,s){var u=1&n,l=r(e),c=l.length;if(c!=r(t).length&&!u)return!1;for(var d=c;d--;){var p=l[d];if(!(u?p in t:a.call(t,p)))return!1}var f=s.get(e),h=s.get(t);if(f&&h)return f==t&&h==e;var m=!0;s.set(e,t),s.set(t,e);for(var _=u;++d<c;){var y=e[p=l[d]],g=t[p];if(o)var v=u?o(g,y,p,t,e,s):o(y,g,p,e,t,s);if(!(void 0===v?y===g||i(y,g,n,o,s):v)){m=!1;break}_||(_="constructor"==p)}if(m&&!_){var b=e.constructor,w=t.constructor;b==w||!("constructor"in e)||!("constructor"in t)||"function"==typeof b&&b instanceof b&&"function"==typeof w&&w instanceof w||(m=!1)}return s.delete(e),s.delete(t),m}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,a=0,o=[];++n<r;){var i=e[n];t(i,n,e)&&(o[a++]=i)}return o}},function(e,t,n){var r=n(19)(n(14),"DataView");e.exports=r},function(e,t,n){var r=n(19)(n(14),"Promise");e.exports=r},function(e,t,n){var r=n(19)(n(14),"Set");e.exports=r},function(e,t,n){var r=n(19)(n(14),"WeakMap");e.exports=r},function(e,t,n){var r=n(121),a=n(32);e.exports=function(e){for(var t=a(e),n=t.length;n--;){var o=t[n],i=e[o];t[n]=[o,i,r(i)]}return t}},function(e,t,n){var r=n(114),a=n(429),o=n(435),i=n(78),s=n(121),u=n(122),l=n(49);e.exports=function(e,t){return i(e)&&s(t)?u(l(e),t):function(n){var i=a(n,e);return void 0===i&&i===t?o(n,e):r(t,i,3)}}},function(e,t,n){var r=n(123);e.exports=function(e,t,n){var a=null==e?void 0:r(e,t);return void 0===a?n:a}},function(e,t,n){var r=n(431),a=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o=/\\(\\)?/g,i=r((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(a,(function(e,n,r,a){t.push(r?a.replace(o,"$1"):n||e)})),t}));e.exports=i},function(e,t,n){var r=n(432);e.exports=function(e){var t=r(e,(function(e){return 500===n.size&&n.clear(),e})),n=t.cache;return t}},function(e,t,n){var r=n(76);function a(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,a=t?t.apply(this,r):r[0],o=n.cache;if(o.has(a))return o.get(a);var i=e.apply(this,r);return n.cache=o.set(a,i)||o,i};return n.cache=new(a.Cache||r),n}a.Cache=r,e.exports=a},function(e,t,n){var r=n(434);e.exports=function(e){return null==e?"":r(e)}},function(e,t,n){var r=n(31),a=n(112),o=n(12),i=n(79),s=r?r.prototype:void 0,u=s?s.toString:void 0;e.exports=function e(t){if("string"==typeof t)return t;if(o(t))return a(t,e)+"";if(i(t))return u?u.call(t):"";var n=t+"";return"0"==n&&1/t==-1/0?"-0":n}},function(e,t,n){var r=n(436),a=n(437);e.exports=function(e,t){return null!=e&&a(e,t,r)}},function(e,t){e.exports=function(e,t){return null!=e&&t in Object(e)}},function(e,t,n){var r=n(124),a=n(106),o=n(12),i=n(107),s=n(68),u=n(49);e.exports=function(e,t,n){for(var l=-1,c=(t=r(t,e)).length,d=!1;++l<c;){var p=u(t[l]);if(!(d=null!=e&&n(e,p)))break;e=e[p]}return d||++l!=c?d:!!(c=null==e?0:e.length)&&s(c)&&i(p,c)&&(o(e)||a(e))}},function(e,t,n){var r=n(439),a=n(440),o=n(78),i=n(49);e.exports=function(e){return o(e)?r(i(e)):a(e)}},function(e,t){e.exports=function(e){return function(t){return null==t?void 0:t[e]}}},function(e,t,n){var r=n(123);e.exports=function(e){return function(t){return r(t,e)}}},function(e,t,n){var r=n(442),a=n(43);e.exports=function(e,t){var n=-1,o=a(e)?Array(e.length):[];return r(e,(function(e,r,a){o[++n]=t(e,r,a)})),o}},function(e,t,n){var r=n(104),a=n(443)(r);e.exports=a},function(e,t,n){var r=n(43);e.exports=function(e,t){return function(n,a){if(null==n)return n;if(!r(n))return e(n,a);for(var o=n.length,i=t?o:-1,s=Object(n);(t?i--:++i<o)&&!1!==a(s[i],i,s););return n}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.mergeClasses=void 0;var r=i(n(66)),a=i(n(445)),o=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e};function i(e){return e&&e.__esModule?e:{default:e}}var s=t.mergeClasses=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=e.default&&(0,a.default)(e.default)||{};return t.map((function(t){var a=e[t];return a&&(0,r.default)(a,(function(e,t){n[t]||(n[t]={}),n[t]=o({},n[t],a[t])})),t})),n};t.default=s},function(e,t,n){var r=n(446);e.exports=function(e){return r(e,5)}},function(e,t,n){var r=n(73),a=n(447),o=n(125),i=n(449),s=n(450),u=n(453),l=n(454),c=n(455),d=n(456),p=n(117),f=n(457),h=n(48),m=n(458),_=n(459),y=n(464),g=n(12),v=n(67),b=n(466),w=n(23),M=n(468),L=n(32),T=n(80),k={};k["[object Arguments]"]=k["[object Array]"]=k["[object ArrayBuffer]"]=k["[object DataView]"]=k["[object Boolean]"]=k["[object Date]"]=k["[object Float32Array]"]=k["[object Float64Array]"]=k["[object Int8Array]"]=k["[object Int16Array]"]=k["[object Int32Array]"]=k["[object Map]"]=k["[object Number]"]=k["[object Object]"]=k["[object RegExp]"]=k["[object Set]"]=k["[object String]"]=k["[object Symbol]"]=k["[object Uint8Array]"]=k["[object Uint8ClampedArray]"]=k["[object Uint16Array]"]=k["[object Uint32Array]"]=!0,k["[object Error]"]=k["[object Function]"]=k["[object WeakMap]"]=!1,e.exports=function e(t,n,x,E,S,O){var D,Y=1&n,A=2&n,C=4&n;if(x&&(D=S?x(t,E,S,O):x(t)),void 0!==D)return D;if(!w(t))return t;var j=g(t);if(j){if(D=m(t),!Y)return l(t,D)}else{var P=h(t),H="[object Function]"==P||"[object GeneratorFunction]"==P;if(v(t))return u(t,Y);if("[object Object]"==P||"[object Arguments]"==P||H&&!S){if(D=A||H?{}:y(t),!Y)return A?d(t,s(D,t)):c(t,i(D,t))}else{if(!k[P])return S?t:{};D=_(t,P,Y)}}O||(O=new r);var I=O.get(t);if(I)return I;O.set(t,D),M(t)?t.forEach((function(r){D.add(e(r,n,x,r,t,O))})):b(t)&&t.forEach((function(r,a){D.set(a,e(r,n,x,a,t,O))}));var N=j?void 0:(C?A?f:p:A?T:L)(t);return a(N||t,(function(r,a){N&&(r=t[a=r]),o(D,a,e(r,n,x,a,t,O))})),D}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}},function(e,t,n){var r=n(19),a=function(){try{var e=r(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();e.exports=a},function(e,t,n){var r=n(50),a=n(32);e.exports=function(e,t){return e&&r(t,a(t),e)}},function(e,t,n){var r=n(50),a=n(80);e.exports=function(e,t){return e&&r(t,a(t),e)}},function(e,t,n){var r=n(23),a=n(71),o=n(452),i=Object.prototype.hasOwnProperty;e.exports=function(e){if(!r(e))return o(e);var t=a(e),n=[];for(var s in e)("constructor"!=s||!t&&i.call(e,s))&&n.push(s);return n}},function(e,t){e.exports=function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}},function(e,t,n){(function(e){var r=n(14),a=t&&!t.nodeType&&t,o=a&&"object"==typeof e&&e&&!e.nodeType&&e,i=o&&o.exports===a?r.Buffer:void 0,s=i?i.allocUnsafe:void 0;e.exports=function(e,t){if(t)return e.slice();var n=e.length,r=s?s(n):new e.constructor(n);return e.copy(r),r}}).call(this,n(42)(e))},function(e,t){e.exports=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}},function(e,t,n){var r=n(50),a=n(77);e.exports=function(e,t){return r(e,a(e),t)}},function(e,t,n){var r=n(50),a=n(127);e.exports=function(e,t){return r(e,a(e),t)}},function(e,t,n){var r=n(118),a=n(127),o=n(80);e.exports=function(e){return r(e,o,a)}},function(e,t){var n=Object.prototype.hasOwnProperty;e.exports=function(e){var t=e.length,r=new e.constructor(t);return t&&"string"==typeof e[0]&&n.call(e,"index")&&(r.index=e.index,r.input=e.input),r}},function(e,t,n){var r=n(81),a=n(460),o=n(461),i=n(462),s=n(463);e.exports=function(e,t,n){var u=e.constructor;switch(t){case"[object ArrayBuffer]":return r(e);case"[object Boolean]":case"[object Date]":return new u(+e);case"[object DataView]":return a(e,n);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return s(e,n);case"[object Map]":return new u;case"[object Number]":case"[object String]":return new u(e);case"[object RegExp]":return o(e);case"[object Set]":return new u;case"[object Symbol]":return i(e)}}},function(e,t,n){var r=n(81);e.exports=function(e,t){var n=t?r(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}},function(e,t){var n=/\w*$/;e.exports=function(e){var t=new e.constructor(e.source,n.exec(e));return t.lastIndex=e.lastIndex,t}},function(e,t,n){var r=n(31),a=r?r.prototype:void 0,o=a?a.valueOf:void 0;e.exports=function(e){return o?Object(o.call(e)):{}}},function(e,t,n){var r=n(81);e.exports=function(e,t){var n=t?r(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}},function(e,t,n){var r=n(465),a=n(72),o=n(71);e.exports=function(e){return"function"!=typeof e.constructor||o(e)?{}:r(a(e))}},function(e,t,n){var r=n(23),a=Object.create,o=function(){function e(){}return function(t){if(!r(t))return{};if(a)return a(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();e.exports=o},function(e,t,n){var r=n(467),a=n(69),o=n(70),i=o&&o.isMap,s=i?a(i):r;e.exports=s},function(e,t,n){var r=n(48),a=n(15);e.exports=function(e){return a(e)&&"[object Map]"==r(e)}},function(e,t,n){var r=n(469),a=n(69),o=n(70),i=o&&o.isSet,s=i?a(i):r;e.exports=s},function(e,t,n){var r=n(48),a=n(15);e.exports=function(e){return a(e)&&"[object Set]"==r(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.autoprefix=void 0;var r,a=n(66),o=(r=a)&&r.__esModule?r:{default:r},i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e};var s={borderRadius:function(e){return{msBorderRadius:e,MozBorderRadius:e,OBorderRadius:e,WebkitBorderRadius:e,borderRadius:e}},boxShadow:function(e){return{msBoxShadow:e,MozBoxShadow:e,OBoxShadow:e,WebkitBoxShadow:e,boxShadow:e}},userSelect:function(e){return{WebkitTouchCallout:e,KhtmlUserSelect:e,MozUserSelect:e,msUserSelect:e,WebkitUserSelect:e,userSelect:e}},flex:function(e){return{WebkitBoxFlex:e,MozBoxFlex:e,WebkitFlex:e,msFlex:e,flex:e}},flexBasis:function(e){return{WebkitFlexBasis:e,flexBasis:e}},justifyContent:function(e){return{WebkitJustifyContent:e,justifyContent:e}},transition:function(e){return{msTransition:e,MozTransition:e,OTransition:e,WebkitTransition:e,transition:e}},transform:function(e){return{msTransform:e,MozTransform:e,OTransform:e,WebkitTransform:e,transform:e}},absolute:function(e){var t=e&&e.split(" ");return{position:"absolute",top:t&&t[0],right:t&&t[1],bottom:t&&t[2],left:t&&t[3]}},extend:function(e,t){var n=t[e];return n||{extend:e}}},u=t.autoprefix=function(e){var t={};return(0,o.default)(e,(function(e,n){var r={};(0,o.default)(e,(function(e,t){var n=s[t];n?r=i({},r,n(e)):r[t]=e})),t[n]=r})),t};t.default=u},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hover=void 0;var r,a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=n(0),i=(r=o)&&r.__esModule?r:{default:r};function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function l(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var c=t.hover=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"span";return function(n){function r(){var n,o,l;s(this,r);for(var c=arguments.length,d=Array(c),p=0;p<c;p++)d[p]=arguments[p];return o=l=u(this,(n=r.__proto__||Object.getPrototypeOf(r)).call.apply(n,[this].concat(d))),l.state={hover:!1},l.handleMouseOver=function(){return l.setState({hover:!0})},l.handleMouseOut=function(){return l.setState({hover:!1})},l.render=function(){return i.default.createElement(t,{onMouseOver:l.handleMouseOver,onMouseOut:l.handleMouseOut},i.default.createElement(e,a({},l.props,l.state)))},u(l,o)}return l(r,n),r}(i.default.Component)};t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.active=void 0;var r,a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=n(0),i=(r=o)&&r.__esModule?r:{default:r};function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function l(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var c=t.active=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"span";return function(n){function r(){var n,o,l;s(this,r);for(var c=arguments.length,d=Array(c),p=0;p<c;p++)d[p]=arguments[p];return o=l=u(this,(n=r.__proto__||Object.getPrototypeOf(r)).call.apply(n,[this].concat(d))),l.state={active:!1},l.handleMouseDown=function(){return l.setState({active:!0})},l.handleMouseUp=function(){return l.setState({active:!1})},l.render=function(){return i.default.createElement(t,{onMouseDown:l.handleMouseDown,onMouseUp:l.handleMouseUp},i.default.createElement(e,a({},l.props,l.state)))},u(l,o)}return l(r,n),r}(i.default.Component)};t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.default=function(e,t){var n={},r=function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];n[e]=t};return 0===e&&r("first-child"),e===t-1&&r("last-child"),(0===e||e%2==0)&&r("even"),1===Math.abs(e%2)&&r("odd"),r("nth-child",e),n}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0);t.default=function(e){var t="string"==typeof e.className?e.className:"",n=e.isLoading?r.createElement("div",{className:"loading-bar"}):null,a=r.createElement("div",{className:"title"},e.title);return e.hasOwnProperty("tabs")&&Array.isArray(e.tabs)&&(a=e.tabs.map((function(t,n){return r.createElement("div",{key:n,className:"tab "+(e.activeTabName===t?"active":""),onClick:function(){return e.selectTab(t,n)}},t)}))),r.createElement("div",{className:"section "+t},r.createElement("div",{className:"section-header"},a,r.createElement("div",{className:"buttons"},e.buttons)),r.createElement("div",{className:"section-content"},e.children),n)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(9),o=r.memo((function(e){return r.createElement("div",null,a.formatDateDefault(e.cell.row.values.date_created))}));t.default=o},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.HEADER_HEIGHT=t.PREVIEW_MAX_HEIGHT=t.PREVIEW_MAX_WIDTH=void 0;var i=n(0),s=n(90);t.PREVIEW_MAX_WIDTH=400,t.PREVIEW_MAX_HEIGHT=400,t.HEADER_HEIGHT=30;var u=function(e){function n(t){var n=e.call(this,t)||this;return n.iconRef=i.createRef(),n.evtHandlers={onClose:function(){return n.handleClose()},onClick:function(){return n.handlePreviewClick()}},n}return a(n,e),n.prototype.handleClose=function(){(0,this.props.onRequestClose)()},n.prototype.handlePreviewClick=function(){var e=this.props,t=e.onClick;e.showMedia||t()},n.prototype.render=function(){var e=this,n=function(n,r){if(e.iconRef.current){n||(n=t.PREVIEW_MAX_WIDTH),r||(r=t.PREVIEW_MAX_HEIGHT);var a=e.iconRef.current.getBoundingClientRect(),o=n/r,i=t.PREVIEW_MAX_WIDTH,s=i/o;s>t.PREVIEW_MAX_HEIGHT&&(i=(s=t.PREVIEW_MAX_HEIGHT)*o);var u=a.x+a.width-i,l=a.y+a.height-s-20;return u<0&&(u=a.x),l<t.HEADER_HEIGHT&&(l=a.y+20),{top:l,left:u,width:i,height:s,position:"absolute",zIndex:9e3}}},r=this.props,a=r.cell,u=r.showMedia;return i.createElement("div",{ref:this.iconRef,className:"asset-type-cell",onClick:this.evtHandlers.onClick},i.createElement(s.AssetsTypeIcon,{type:a.row.values.type}),a.row.values.type===s.ASSET_TYPES.IMAGE&&i.createElement(s.ImagePreview,{style:o({},n(a.row.original.width,a.row.original.height)),showMedia:u,url:a.row.original.url,onRequestClose:this.evtHandlers.onClose}),a.row.values.type===s.ASSET_TYPES.VIDEO&&i.createElement(s.VideoPreview,{playbackSettings:{autoPlay:!0,loop:!1},style:n(a.row.original.width,a.row.original.height),showMedia:u,url:a.row.original.url,onRequestClose:this.evtHandlers.onClose}))},n}(i.PureComponent),l=i.memo(u);t.default=l},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.secondsToTime=void 0;var r=n(0),a=n(17),o=n(8),i=n(10);t.secondsToTime=function(e){var t=Math.floor(e/60),n=Math.floor(e-60*t);return n<10&&(n="0"+n),t+":"+n};t.default=o.connect((function(e){return{}}),(function(e){return i.bindActionCreators({updateAssetName:a.updateAssetName},e)}))((function(e){var n=e.cell.row.original,a=n.duration;n.id;return null!=a?r.createElement("div",{className:"asset-duration-cell"},t.secondsToTime(a)):null}))},function(e,t){e.exports=p},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ASSET_DND_TYPES=void 0,t.ASSET_DND_TYPES={ASSET_NAME:"asset_name"}},function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i};Object.defineProperty(t,"__esModule",{value:!0});var a,o=n(0),i=n(0),s=n(13),u=n(17),l=n(8),c=n(10);t.default=l.connect((function(e){return{}}),(function(e){return c.bindActionCreators({updateAssetName:u.updateAssetName},e)}))((function(e){var t=e.cell.row.original,n=t.name,u=t.id,l=r(i.useState(""),2),c=l[0],d=l[1],p=function(t){e.updateAssetName(e.api,u,t)};return i.useEffect((function(){return d(n),function(){clearTimeout(a)}}),[n]),o.createElement(s.default,{value:c,width:"100%",onChange:function(e){return function(e){d(e),clearTimeout(a),a=setTimeout((function(){return p(e)}),1e3)}(e)}})}))},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(13),s=n(24),u=n(8),l=n(10),c=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.render=function(){var e=t.props.assetFilters;return o.createElement(i.default,{submittable:!0,submittableType:"search",value:e.name,doSubmit:function(e){return t.props.updateFilters({name:e})}})},t}return a(t,e),t}(o.PureComponent),d=u.connect((function(e){return{assetFilters:e.assetFilters}}),(function(e){return l.bindActionCreators({updateFilters:s.updateFilters},e)}))(o.memo(c));t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(33),s=n(30),u=n(8),l=n(10),c=function(e){function t(t){var n=e.call(this,t)||this;return n.render=function(){var e=n.props,t=e.cell,r=e.selectedAssets,a=t.row.original.id,i=r.indexOf(a)>-1;return o.createElement(s.default,{label:"",width:"auto",value:i,onChange:function(e,t){return function(e,t){e?t.shiftKey&&r.length>0?n.props.selectMultipleAssets(a):n.props.selectAsset(a):n.props.deselectAsset(a)}(e,t)}})},n}return a(t,e),t}(o.PureComponent),d=u.connect((function(e){return{selectedAssets:e.selectedAssets}}),(function(e){return l.bindActionCreators({selectAsset:i.selectAsset,deselectAsset:i.deselectAsset,selectMultipleAssets:i.selectMultipleAssets},e)}))(o.memo(c));t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(30),s=n(33),u=n(8),l=n(10),c=function(e){function t(t){var n=e.call(this,t)||this;return n.render=function(){var e=0===n.props.selectedAssets.length,t=e?function(){return n.props.selectAll()}:function(){return n.props.resetSelection()};return o.createElement(i.default,{label:"",propagate:!1,value:!e,onChange:t})},n}return a(t,e),t}(o.PureComponent),d=u.connect((function(e){return{selectedAssets:e.selectedAssets}}),(function(e){return l.bindActionCreators({selectAll:s.selectAll,resetSelection:s.resetSelection},e)}))(o.memo(c));t.default=d},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(5),o=r.memo((function(e){return r.createElement(a.default,{color:"secondary",style:"subtle",size:"small",onClick:e.onClick},e.cell.row.values.tags.length)}));t.default=o},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(24),s=n(13),u=n(8),l=n(10),c=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.render=function(){var e=t.props.assetFilters;return o.createElement(s.default,{submittable:!0,submittableType:"search",value:e.tags,doSubmit:function(e){return t.props.updateFilters({tags:e})}})},t}return a(t,e),t}(o.PureComponent),d=u.connect((function(e){return{assetFilters:e.assetFilters}}),(function(e){return l.bindActionCreators({updateFilters:i.updateFilters},e)}))(o.memo(c));t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},i=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(0),u=n(7),l=n(51),c=n(13),d=n(17),p=n(8),f=n(10),h=n(5),m=n(4),_=function(e){function t(n){var r=e.call(this,n)||this;return r.addTags=function(e,t){t&&r.props.addAssetTag(r.props.api,e,t)},r.render=function(){var e=r.props,n=e.row.original,a=n.id,d=n.tags,p=e.assetTags,f=i([],o(new Set(d))).map((function(e){return s.createElement(l.default,{key:e,copy:e,colorize:t.COLORIZE_TAGS,removeHandler:function(){return r.props.deleteAssetTag(r.props.api,a,e)}})}));return s.createElement("div",{className:"tags-column"},s.createElement(s.Fragment,null,s.createElement(c.default,{submittable:!0,submittableType:"add",suggestions:p,label:u.assets.tags.add,width:t.ADD_TAG_INPUT_WIDTH,doSubmit:function(e){return r.addTags(a,e)}}),f,s.createElement(h.default,{customStyles:{position:"absolute",right:"1px",top:"9px"},style:"subtle",onClick:function(e){return r.props.onClose(e,r.props.row)}},m.ICON_TIMES)))},r}return a(t,e),t.ADD_TAG_INPUT_WIDTH="280px",t.COLORIZE_TAGS=!0,t}(s.PureComponent);t.default=p.connect((function(e){return{assetTags:e.assetTags}}),(function(e){return f.bindActionCreators({addAssetTag:d.addAssetTag,deleteAssetTag:d.deleteAssetTag},e)}))(_)},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(51),s=n(13),u=n(17),l=n(8),c=n(10),d=function(e){function t(t){var n=e.call(this,t)||this;return n.render=function(){var e=n.props,t=e.cell,r=e.assetTags,a=t.row.original.tags.map((function(e){return o.createElement(i.default,{key:e,copy:e,colorize:!0,removeHandler:function(){return n.removeTag(e)}})}));return o.createElement("div",{className:"tags-complex-column"},a,o.createElement("div",{className:"new-tag"},o.createElement(s.default,{submittable:!0,submittableType:"add",placeholder:"+",hideButtons:!0,suggestions:r,doSubmit:function(e){return n.onSubmit(e)},width:"150px",buttons:[],value:n.state.newTag})))},n.state={newTag:""},n.inputRef=o.createRef(),n}return a(t,e),t.prototype.onSubmit=function(e){var t=this.props.cell.row.original,n=t.id;-1===t.tags.indexOf(e)&&this.props.addAssetTag(this.props.api,n,e),this.setState({newTag:""})},t.prototype.removeTag=function(e){var t=this.props.cell.row.original.id;this.props.deleteAssetTag(this.props.api,t,e)},t}(o.Component),p=l.connect((function(e){return{assetTags:e.assetTags}}),(function(e){return c.bindActionCreators({addAssetTag:u.addAssetTag,deleteAssetTag:u.deleteAssetTag},e)}))(o.memo(d));t.default=p},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(85),o=r.memo((function(e){return r.createElement("div",{className:"asset-type-cell"},r.createElement(a.default,{type:e.cell.row.values.type}))}));t.default=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=r.memo((function(e){var t=e.cell.row.original.processing?"processing":"complete";return r.createElement("div",{className:"asset-status-cell"},r.createElement("div",{className:"status-indicator "+t}))}));t.default=a},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(85),s=n(5),u=n(59),l=n(24),c=n(8),d=n(10),p=n(25),f=function(e){function t(t){var n=e.call(this,t)||this;return n.handleFilterChange=function(e){var t=e!==p.ASSET_TYPES.ALL?e:"";n.props.updateFilters({type:t,page:1})},n.render=function(){var e=n.state.openMenu,t=n.props.assetFilters.type,r=[],a=function(e){if(p.ASSET_TYPES.hasOwnProperty(e)){var t=p.ASSET_TYPES[e];r.push(o.createElement("div",{key:t,className:"asset-filter",onClick:function(){return n.handleFilterChange(t)}},o.createElement(i.default,{type:t})))}};for(var l in p.ASSET_TYPES)a(l);return o.createElement("div",{className:"centered cell"},o.createElement(s.default,{tooltip:"Filter by Asset type",buttonRef:n.typeFilterRef,onClick:function(){return n.setState({openMenu:!e})}},o.createElement(i.default,{type:t||"filter"}),o.createElement(u.default,{fixed:!0,show:e,position:"bottomleft",toggleRef:n.typeFilterRef,onOutsideClick:function(){return n.setState({openMenu:!1})}},r)))},n.state={openMenu:!1},n.typeFilterRef=o.createRef(),n}return a(t,e),t}(o.PureComponent),h=c.connect((function(e){return{assetFilters:e.assetFilters}}),(function(e){return d.bindActionCreators({updateFilters:l.updateFilters},e)}))(o.memo(f));t.default=h},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(34),s=n(26),u=n(86),l=function(e){function t(t){var n=e.call(this,t)||this;return n.defaultSize=600,n}return a(t,e),t.prototype.getWrapperStyle=function(){var e=this.props,t=e.padding,n=e.width,r=e.height,a=void 0!==t?t:i.DEFAULT_PADDING;return s.getPlayerStyle(n,r,this.defaultSize,this.defaultSize,a,this.defaultSize,this.defaultSize)},t.prototype.render=function(){var e=this.props,t=e.active,n=e.asset,r=n.name,a=n.url,i=n.id,s=e.width,l=e.height,c=this.getWrapperStyle();return!1!==t?o.createElement("div",{className:"media-player"},o.createElement("div",{className:"inner-viewer",style:c},o.createElement(u.default,{options:{width:s,height:l,x:0,y:0,rotation:0,id:"xxx",name:"xxx",content:"ABCDEFGHIJKLM\nNOPQRSTUVWXYZ\nabcdefghijklm\nnopqrstuvwxyz\n1234567890",color:"#000000",background_color:"#ffffff",font_size:80,font_weight:400,font_type:"custom",font:r,custom_font_url:a,custom_font_id:i,letter_spacing:null,word_spacing:null,line_height:null,horizontal_alignment:"center",vertical_alignment:"center",text_wrap:!0,text_fit:!0}}))):null},t}(o.PureComponent);t.default=l},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(7),s=n(30),u=n(128),l=n(52),c=n(10),d=n(8),p=n(4),f=n(5),h=function(e){function t(t){var n=e.call(this,t)||this;return n.render=function(){var e,t=n.props.assetUploads,r=t.uploads,a=t.autoTag,l=t.assignToStory;return e=r.length>0?r.map((function(e){var t=e.filename,r=e.percent,a=r<100?o.createElement(u.default,{progress:e.percent}):o.createElement("span",null,i.assets.uploads.preparePhase),s=r<100&&o.createElement(f.default,{key:"btn-cancel",onClick:function(){return n.handleCancelAssetUpload(t)},style:"subtle"},p.ICON_TIMES);return o.createElement("div",{className:"ongoing-upload",key:t},o.createElement("div",{className:"ongoing-upload-inner"},o.createElement("div",{className:"upload-filename"},t),s),a)})):o.createElement("div",{className:"no-ongoing-uploads"},i.assets.uploads.noUploads),o.createElement("div",{className:"uploads-menu"},o.createElement("div",{className:"uploads-controls"},o.createElement(s.default,{width:"50%",label:i.assets.uploads.autoTagInput,value:a,onChange:function(){return n.props.toggleAutoTag(!a)}}),o.createElement(s.default,{width:"50%",label:i.assets.uploads.assignToStoryInput,info:i.assets.uploads.assignToStoryInfo,value:l,onChange:function(){return n.props.toggleAssignToStory(!l)}})),o.createElement("div",{className:"uploads-list"},e))},n}return a(t,e),t.prototype.handleCancelAssetUpload=function(e){var t=this.props.api;this.props.cancelAssetUpload(e,t)},t}(o.PureComponent);t.default=d.connect((function(e){return{assetUploads:e.assetUploads}}),(function(e){return c.bindActionCreators({toggleAutoTag:l.toggleAutoTag,toggleAssignToStory:l.toggleAssignToStory,cancelAssetUpload:l.cancelAssetUpload},e)}))(h)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PreviewNotAvailable=void 0;var r=n(0),a=n(4),o=n(7);t.PreviewNotAvailable=function(e){return!0===e.active||void 0===e.active?r.createElement("div",{className:"preview-not-available"},r.createElement("div",{className:"cta"},r.createElement("div",{className:"icon"},a.ICON_BAN),r.createElement("p",null,o.assets.previewNotAvailable))):null}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(34),s=n(26),u=function(e){function t(t){var n=e.call(this,t)||this;return n.width=1280,n.height=720,n.audioNode=o.createRef(),n}return a(t,e),t.prototype.getImageStyle=function(){var e=this.props,t=e.padding,n=e.width,r=e.height,a=void 0!==t?t:i.DEFAULT_PADDING;return s.getPlayerStyle(n,r,this.width,this.height,a)},t.prototype.render=function(){var e=this.props,t=e.url;return!1!==e.active?o.createElement("div",{className:"media-player"},o.createElement("div",{className:"inner-viewer",style:this.getImageStyle()},o.createElement("audio",{controls:!0,src:t,ref:this.audioNode}))):null},t}(o.PureComponent);t.default=u},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(87),u=n(5),l=n(7),c=n(4),d=function(e){function t(t){var n=e.call(this,t)||this;return n.videoNode=null,n.videoNode=i.createRef(),n.evtHandlers={onClose:function(e){return n.onClose(e)}},n}return a(t,e),t.prototype.onClose=function(e){(0,this.props.onRequestClose)(e)},t.prototype.render=function(){var e=this.props,t=e.showMedia,n=e.url,r=e.playbackSettings,a=e.style;return t?i.createElement(s.default,{id:"portal-root"},i.createElement("div",{style:o({},a),className:"close-icon-preview"},i.createElement(u.default,{key:"btn-filter",onClick:this.evtHandlers.onClose,size:"large",style:"subtle",tooltip:l.assets.field.tooltipFilter},c.ICON_TIMES)),i.createElement("video",{style:a,muted:!0,ref:this.videoNode,autoPlay:r.autoPlay,loop:r.loop,controls:!0,preload:"preload",src:n,className:"asset-preview-background"})):null},t}(i.PureComponent);t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(87),u=n(4),l=n(5),c=n(7),d=function(e){function t(t){var n=e.call(this,t)||this;return n.imageNode=null,n.imageNode=i.createRef(),n.evtHandlers={onClose:function(e){return n.onClose(e)}},n.state={loaded:!1},n}return a(t,e),t.prototype.onClose=function(e){(0,this.props.onRequestClose)(e)},t.prototype.render=function(){var e=this,t=this.props,n=t.showMedia,r=t.url,a=t.style,d=this.state.loaded;return n?i.createElement(s.default,{id:"portal-root"},i.createElement("div",{style:o({},a),className:"close-icon-preview"},i.createElement(l.default,{key:"btn-filter",onClick:this.evtHandlers.onClose,size:"large",style:"subtle",tooltip:c.assets.field.tooltipFilter},u.ICON_TIMES)),i.createElement("img",{onLoad:function(){return e.setState({loaded:!0})},src:r,ref:this.imageNode,className:"media-preview "+(d?"":"hidden"),style:a})):null},t}(i.PureComponent);t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(34),s=n(26),u=function(e){function t(t){var n=e.call(this,t)||this;return n.state={imageHeight:1080,imageWidth:1920},n.imgNode=o.createRef(),n}return a(t,e),t.prototype.getImageStyle=function(){var e=this.state,t=e.imageHeight,n=e.imageWidth,r=this.props,a=r.padding,o=r.width,u=r.height,l=void 0!==a?a:i.DEFAULT_PADDING;return t&&n?s.getPlayerStyle(o,u,n,t,l):{}},t.prototype.metadataLoaded=function(e){this.setState({imageWidth:e.target.naturalWidth,imageHeight:e.target.naturalHeight})},t.prototype.render=function(){var e=this.props;e.url;return!1!==e.active?o.createElement("div",{className:"mediap-player"},o.createElement("div",{className:"inner-viewer",style:this.getImageStyle()})):null},t}(o.PureComponent);t.default=u},function(e,t,n){var r,a,o;a=[t],void 0===(o="function"==typeof(r=function(e){"use strict";var t,n=this&&this.__makeTemplateObject||function(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e};!function(e){e[e.EOS=0]="EOS",e[e.Text=1]="Text",e[e.Incomplete=2]="Incomplete",e[e.ESC=3]="ESC",e[e.Unknown=4]="Unknown",e[e.SGR=5]="SGR",e[e.OSCURL=6]="OSCURL"}(t||(t={}));var r=function(){function e(){this.VERSION="4.0.4",this.setup_palettes(),this._use_classes=!1,this._escape_for_html=!0,this.bold=!1,this.fg=this.bg=null,this._buffer="",this._url_whitelist={http:1,https:1}}return Object.defineProperty(e.prototype,"use_classes",{get:function(){return this._use_classes},set:function(e){this._use_classes=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"escape_for_html",{get:function(){return this._escape_for_html},set:function(e){this._escape_for_html=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"url_whitelist",{get:function(){return this._url_whitelist},set:function(e){this._url_whitelist=e},enumerable:!0,configurable:!0}),e.prototype.setup_palettes=function(){var e=this;this.ansi_colors=[[{rgb:[0,0,0],class_name:"ansi-black"},{rgb:[187,0,0],class_name:"ansi-red"},{rgb:[0,187,0],class_name:"ansi-green"},{rgb:[187,187,0],class_name:"ansi-yellow"},{rgb:[0,0,187],class_name:"ansi-blue"},{rgb:[187,0,187],class_name:"ansi-magenta"},{rgb:[0,187,187],class_name:"ansi-cyan"},{rgb:[255,255,255],class_name:"ansi-white"}],[{rgb:[85,85,85],class_name:"ansi-bright-black"},{rgb:[255,85,85],class_name:"ansi-bright-red"},{rgb:[0,255,0],class_name:"ansi-bright-green"},{rgb:[255,255,85],class_name:"ansi-bright-yellow"},{rgb:[85,85,255],class_name:"ansi-bright-blue"},{rgb:[255,85,255],class_name:"ansi-bright-magenta"},{rgb:[85,255,255],class_name:"ansi-bright-cyan"},{rgb:[255,255,255],class_name:"ansi-bright-white"}]],this.palette_256=[],this.ansi_colors.forEach((function(t){t.forEach((function(t){e.palette_256.push(t)}))}));for(var t=[0,95,135,175,215,255],n=0;n<6;++n)for(var r=0;r<6;++r)for(var a=0;a<6;++a){var o={rgb:[t[n],t[r],t[a]],class_name:"truecolor"};this.palette_256.push(o)}for(var i=8,s=0;s<24;++s,i+=10){var u={rgb:[i,i,i],class_name:"truecolor"};this.palette_256.push(u)}},e.prototype.escape_txt_for_html=function(e){return e.replace(/[&<>]/gm,(function(e){return"&"===e?"&amp;":"<"===e?"&lt;":">"===e?"&gt;":void 0}))},e.prototype.append_buffer=function(e){var t=this._buffer+e;this._buffer=t},e.prototype.get_next_packet=function(){var e={kind:t.EOS,text:"",url:""},r=this._buffer.length;if(0==r)return e;var o=this._buffer.indexOf("");if(-1==o)return e.kind=t.Text,e.text=this._buffer,this._buffer="",e;if(o>0)return e.kind=t.Text,e.text=this._buffer.slice(0,o),this._buffer=this._buffer.slice(o),e;if(0==o){if(1==r)return e.kind=t.Incomplete,e;var i=this._buffer.charAt(1);if("["!=i&&"]"!=i)return e.kind=t.ESC,e.text=this._buffer.slice(0,1),this._buffer=this._buffer.slice(1),e;if("["==i){if(this._csi_regex||(this._csi_regex=a(n(["\n ^ # beginning of line\n #\n # First attempt\n (?: # legal sequence\n [ # CSI\n ([<-?]?) # private-mode char\n ([d;]*) # any digits or semicolons\n ([ -/]? # an intermediate modifier\n [@-~]) # the command\n )\n | # alternate (second attempt)\n (?: # illegal sequence\n [ # CSI\n [ -~]* # anything legal\n ([\0-:]) # anything illegal\n )\n "],["\n ^ # beginning of line\n #\n # First attempt\n (?: # legal sequence\n \\x1b\\[ # CSI\n ([\\x3c-\\x3f]?) # private-mode char\n ([\\d;]*) # any digits or semicolons\n ([\\x20-\\x2f]? # an intermediate modifier\n [\\x40-\\x7e]) # the command\n )\n | # alternate (second attempt)\n (?: # illegal sequence\n \\x1b\\[ # CSI\n [\\x20-\\x7e]* # anything legal\n ([\\x00-\\x1f:]) # anything illegal\n )\n "]))),null===(l=this._buffer.match(this._csi_regex)))return e.kind=t.Incomplete,e;if(l[4])return e.kind=t.ESC,e.text=this._buffer.slice(0,1),this._buffer=this._buffer.slice(1),e;""!=l[1]||"m"!=l[3]?e.kind=t.Unknown:e.kind=t.SGR,e.text=l[2];var s=l[0].length;return this._buffer=this._buffer.slice(s),e}if("]"==i){if(r<4)return e.kind=t.Incomplete,e;if("8"!=this._buffer.charAt(2)||";"!=this._buffer.charAt(3))return e.kind=t.ESC,e.text=this._buffer.slice(0,1),this._buffer=this._buffer.slice(1),e;this._osc_st||(this._osc_st=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=e.raw[0],a=/^\s+|\s+\n|\s*#[\s\S]*?\n|\n/gm,o=r.replace(a,"");return new RegExp(o,"g")}(n(["\n (?: # legal sequence\n (\\) # ESC | # alternate\n () # BEL (what xterm did)\n )\n | # alternate (second attempt)\n ( # illegal sequence\n [\0-] # anything illegal\n | # alternate\n [\b-] # anything illegal\n | # alternate\n [-] # anything illegal\n )\n "],["\n (?: # legal sequence\n (\\x1b\\\\) # ESC \\\n | # alternate\n (\\x07) # BEL (what xterm did)\n )\n | # alternate (second attempt)\n ( # illegal sequence\n [\\x00-\\x06] # anything illegal\n | # alternate\n [\\x08-\\x1a] # anything illegal\n | # alternate\n [\\x1c-\\x1f] # anything illegal\n )\n "]))),this._osc_st.lastIndex=0;var u=this._osc_st.exec(this._buffer);if(null===u)return e.kind=t.Incomplete,e;if(u[3])return e.kind=t.ESC,e.text=this._buffer.slice(0,1),this._buffer=this._buffer.slice(1),e;var l,c=this._osc_st.exec(this._buffer);return null===c?(e.kind=t.Incomplete,e):c[3]?(e.kind=t.ESC,e.text=this._buffer.slice(0,1),this._buffer=this._buffer.slice(1),e):(this._osc_regex||(this._osc_regex=a(n(["\n ^ # beginning of line\n #\n ]8; # OSC Hyperlink\n [ -:<-~]* # params (excluding ;)\n ; # end of params\n ([!-~]{0,512}) # URL capture\n (?: # ST\n (?:\\) # ESC | # alternate\n (?:) # BEL (what xterm did)\n )\n ([!-~]+) # TEXT capture\n ]8;; # OSC Hyperlink End\n (?: # ST\n (?:\\) # ESC | # alternate\n (?:) # BEL (what xterm did)\n )\n "],["\n ^ # beginning of line\n #\n \\x1b\\]8; # OSC Hyperlink\n [\\x20-\\x3a\\x3c-\\x7e]* # params (excluding ;)\n ; # end of params\n ([\\x21-\\x7e]{0,512}) # URL capture\n (?: # ST\n (?:\\x1b\\\\) # ESC \\\n | # alternate\n (?:\\x07) # BEL (what xterm did)\n )\n ([\\x21-\\x7e]+) # TEXT capture\n \\x1b\\]8;; # OSC Hyperlink End\n (?: # ST\n (?:\\x1b\\\\) # ESC \\\n | # alternate\n (?:\\x07) # BEL (what xterm did)\n )\n "]))),null===(l=this._buffer.match(this._osc_regex))?(e.kind=t.ESC,e.text=this._buffer.slice(0,1),this._buffer=this._buffer.slice(1),e):(e.kind=t.OSCURL,e.url=l[1],e.text=l[2],s=l[0].length,this._buffer=this._buffer.slice(s),e))}}},e.prototype.ansi_to_html=function(e){this.append_buffer(e);for(var n=[];;){var r=this.get_next_packet();if(r.kind==t.EOS||r.kind==t.Incomplete)break;r.kind!=t.ESC&&r.kind!=t.Unknown&&(r.kind==t.Text?n.push(this.transform_to_html(this.with_state(r))):r.kind==t.SGR?this.process_ansi(r):r.kind==t.OSCURL&&n.push(this.process_hyperlink(r)))}return n.join("")},e.prototype.with_state=function(e){return{bold:this.bold,fg:this.fg,bg:this.bg,text:e.text}},e.prototype.process_ansi=function(e){for(var t=e.text.split(";");t.length>0;){var n=t.shift(),r=parseInt(n,10);if(isNaN(r)||0===r)this.fg=this.bg=null,this.bold=!1;else if(1===r)this.bold=!0;else if(22===r)this.bold=!1;else if(39===r)this.fg=null;else if(49===r)this.bg=null;else if(r>=30&&r<38)this.fg=this.ansi_colors[0][r-30];else if(r>=40&&r<48)this.bg=this.ansi_colors[0][r-40];else if(r>=90&&r<98)this.fg=this.ansi_colors[1][r-90];else if(r>=100&&r<108)this.bg=this.ansi_colors[1][r-100];else if((38===r||48===r)&&t.length>0){var a=38===r,o=t.shift();if("5"===o&&t.length>0){var i=parseInt(t.shift(),10);i>=0&&i<=255&&(a?this.fg=this.palette_256[i]:this.bg=this.palette_256[i])}if("2"===o&&t.length>2){var s=parseInt(t.shift(),10),u=parseInt(t.shift(),10),l=parseInt(t.shift(),10);if(s>=0&&s<=255&&u>=0&&u<=255&&l>=0&&l<=255){var c={rgb:[s,u,l],class_name:"truecolor"};a?this.fg=c:this.bg=c}}}}},e.prototype.transform_to_html=function(e){var t=e.text;if(0===t.length)return t;if(this._escape_for_html&&(t=this.escape_txt_for_html(t)),!e.bold&&null===e.fg&&null===e.bg)return t;var n=[],r=[],a=e.fg,o=e.bg;e.bold&&n.push("font-weight:bold"),this._use_classes?(a&&("truecolor"!==a.class_name?r.push(a.class_name+"-fg"):n.push("color:rgb("+a.rgb.join(",")+")")),o&&("truecolor"!==o.class_name?r.push(o.class_name+"-bg"):n.push("background-color:rgb("+o.rgb.join(",")+")"))):(a&&n.push("color:rgb("+a.rgb.join(",")+")"),o&&n.push("background-color:rgb("+o.rgb+")"));var i="",s="";return r.length&&(i=' class="'+r.join(" ")+'"'),n.length&&(s=' style="'+n.join(";")+'"'),"<span"+s+i+">"+t+"</span>"},e.prototype.process_hyperlink=function(e){var t=e.url.split(":");return t.length<1?"":this._url_whitelist[t[0]]?'<a href="'+this.escape_txt_for_html(e.url)+'">'+this.escape_txt_for_html(e.text)+"</a>":""},e}();function a(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=e.raw[0],a=/^\s+|\s+\n|\s*#[\s\S]*?\n|\n/gm,o=r.replace(a,"");return new RegExp(o)}Object.defineProperty(e,"__esModule",{value:!0}),e.default=r})?r.apply(t,a):r)||(e.exports=o)},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var i=n(0),s=n(133),u=n(500),l=n(13),c=n(5),d=n(21),p=n(41),f=n(22),h=n(63),m=n(11),_=n(16),y=n(26),g=n(131),v=n(501),b=n(101),w=n(7),M=n(9),L=n(134),T=n(132),k=n(8),x=function(e){function t(t){var n=e.call(this,t)||this;n.TIMEOUT="02:00";var r=n.getInventoryDefaults(),a=n.getInventoryOptions();return n.state={inventory:r,inventoryOptions:a,experienceId:null,jobId:null,experience:null,timeElapsed:0,activeOutput:"",rendering:!1,isTimeOut:!1},n.timer=new L.default({interval:1e3,onUpdate:function(e){n.setState({timeElapsed:e})}}),n.evtHandlers={toggleOutput:function(e){return n.toggleActiveOutput(e)},createExp:function(){return n.createExperience()},gotExperience:null},n}return a(t,e),t.prototype.componentWillUnmount=function(){var e=this.props,t=e.api;e.onError,this.state.experienceId;this.timer.stop(),this.evtHandlers.gotExperience=null,t.cancelExperiencePolling()},t.prototype.getInventoryOptions=function(){var e=this.props.variables,t={};for(var n in e)if(e.hasOwnProperty(n)){var r=e[n];r.defaultItem&&r.defaultItem.type&&r.defaultItem.type.toLowerCase()===s.VARIABLE_TYPES.ENUM&&(t[r.id]=r.defaultItem.options)}return t},t.prototype.getInventoryDefaults=function(){var e=this.props.variables,t={};for(var n in e)if(e.hasOwnProperty(n)){var r=e[n];t[r.id]=this.getVariableValue(r.previewItem)}return t},t.prototype.checkInventoryDefaults=function(e){var t=this.props.variables,n=o({},this.state.inventory);for(var r in t)if(t.hasOwnProperty(r)){var a=t[r],i=e[r];if(i){var s=this.getVariableValue(i.previewItem),u=this.getVariableValue(a.previewItem);a.type===i.type&&s===u||(n[r]=u)}}return n},t.prototype.getVariableValue=function(e){if(e&&e.type){var t=e.type.toLowerCase();return t===s.VARIABLE_TYPES.IMAGE||t===s.VARIABLE_TYPES.VIDEO||t===s.VARIABLE_TYPES.AUDIO?e.url:e.src}},t.prototype.componentDidMount=function(){var e=this,t=this.props,n=t.experienceId,r=t.jobId;n&&r&&this.setState({jobId:r},(function(){e.getExperience(n)}))},t.prototype.componentDidUpdate=function(e,t){var n=this;if(e.storyId!==this.props.storyId&&(this.evtHandlers.gotExperience=null),e.variables!==this.props.variables){var r=void 0,a=this.getInventoryOptions();r=e.storyId===this.props.storyId?this.checkInventoryDefaults(e.variables):this.getInventoryDefaults(),this.setState({inventoryOptions:a,inventory:r})}if(this.props.notifications&&this.props.notifications[0]&&("error"===this.props.notifications[0].type&&this.setState({isTimeOut:!0}),"info"===this.props.notifications[0].type&&this.setState({isTimeOut:!1})),t.timeElapsed!==this.state.timeElapsed&&M.formattedTime(this.state.timeElapsed)===this.TIMEOUT&&!this.state.experience){var o=this.props,i=o.onError,s=o.api,u=this.state.experienceId;s.cancelExperiencePolling().then((function(){i(w.previewer.runExpError.replace("[expId]",u)),n.resetState(!0,(function(){n.setState({isTimeOut:!0})}))}))}},t.prototype.variableInputChanged=function(e,t){var n=o({},this.state.inventory);n[e]=t,this.setState({inventory:n})},t.prototype.getViewerOptions=function(){var e=[],t=this.state,n=t.experience.output,r=t.jobId,a=n.videos,o=n.images;if(a)for(var i in a)if(a.hasOwnProperty(i)){var s={label:"Video: "+i,value:u.OUTPUT_TYPES.VIDEO+"."+i};e.push(s)}if(o)for(var i in o)if(o.hasOwnProperty(i)){var l={label:"Image: "+i,value:u.OUTPUT_TYPES.IMAGE+"."+i};e.push(l)}return r&&e.push({label:w.previewer.btnLog,value:u.OUTPUT_TYPES.LOG+"."+r}),e},t.prototype.renderVariableFields=function(){var e=this,t=this.state,n=t.inventory,r=t.inventoryOptions,a=this.props.variables,o=[],u=function(t){if(a.hasOwnProperty(t)){var u=a[t];switch(u.type.toLowerCase()){case s.VARIABLE_TYPES.TEXT:o.push(i.createElement(l.default,{label:u.name,key:u.id,value:n[u.id],onChange:function(t){return e.variableInputChanged(u.id,t)}}));break;case s.VARIABLE_TYPES.NUMBER:o.push(i.createElement(p.default,{label:u.name,key:u.id,value:n[u.id],onChange:function(t){return e.variableInputChanged(u.id,t)}}));break;case s.VARIABLE_TYPES.ENUM:o.push(i.createElement(f.default,{label:u.name,key:u.id,value:n[u.id],options:r[u.id],onChange:function(t){return e.variableInputChanged(u.id,t)}}));break;case s.VARIABLE_TYPES.BOOLEAN:o.push(i.createElement(h.default,{label:u.name,key:u.id,value:n[u.id],options:s.BOOLEAN_DEFAULT_OPTIONS,onChange:function(t){return e.variableInputChanged(u.id,t)}}));break;case s.VARIABLE_TYPES.IMAGE:o.push(i.createElement(m.default,{label:u.name,key:u.id},i.createElement(v.default,{value:n[u.id],type:u.type,onChange:function(t){return e.variableInputChanged(u.id,t)}})));break;case s.VARIABLE_TYPES.VIDEO:case s.VARIABLE_TYPES.AUDIO:o.push(i.createElement(m.default,{label:u.name,key:u.id},i.createElement(v.default,{type:u.type,value:n[u.id],onChange:function(t){return e.variableInputChanged(u.id,t)}})))}}};for(var c in a)u(c);return o},t.prototype.getFirstOutput=function(e){var t=e.output.videos,n=e.output.images;if(t){for(var r in t)if(t.hasOwnProperty(r))return u.OUTPUT_TYPES.VIDEO+"."+r}else{if(!n)return null;for(var r in n)if(n.hasOwnProperty(r))return u.OUTPUT_TYPES.IMAGE+"."+r}},t.prototype.getExperience=function(e,t,n,r){var a=this;void 0===t&&(t=!1),this.timer.running||this.timer.start();var o=this.props,i=o.api,s=o.onError,u=o.onExperenceLoaded,l=o.onJobCreated;this.setState({rendering:!0},(function(){a.setState({experienceId:e},(function(){t?i.triggerEvent(e,n,r).then((function(t){a.setState({jobId:t.job_id},(function(){l&&l(e,t.job_id),a.evtHandlers.gotExperience=function(e){a.timer.stop(),u&&u(e),a.setState({rendering:!1,activeOutput:a.getFirstOutput(e),experience:e})};i.getExperience(e,!0).then((function(e){a.evtHandlers.gotExperience&&a.evtHandlers.gotExperience(e)})).catch((function(t){a.resetState(),s&&(t.error?s(t.error):s(w.previewer.runExpError.replace("[expId]",e)))}))}))})).catch((function(t){a.resetState(),s&&s(w.previewer.triggerExpError.replace("[expId]",e))})):(a.evtHandlers.gotExperience=function(e){a.timer.stop(),u&&u(e),a.setState({rendering:!1,activeOutput:a.getFirstOutput(e),experience:e})},i.getExperience(e,!0).then((function(e){a.evtHandlers.gotExperience&&a.evtHandlers.gotExperience(e)})).catch((function(t){a.resetState(),s&&(t.error?s(t.error):s(w.previewer.runExpError.replace("[expId]",e)))})))}))}))},t.prototype.createExperience=function(){var e=this,t=this.props,n=t.storyId,r=t.onNotification,a=t.onError,o=t.api,i=t.onExperienceCreated,s=t.compositionId,u=t.useWorkingCopy;this.resetState(!1,(function(){e.setState({rendering:!0,isTimeOut:!1},(function(){e.timer.start(),r&&r(w.previewer.runExpStart),o.createExperience(n,e.state.inventory,s,u).then((function(t){r&&r(w.previewer.expId.replace("[expId]",t.id)),i&&i(t),e.getExperience(t.id,!0,s,u)})).catch((function(t){e.resetState();var n=t.response,r=n.data;n.status;a&&(r&&r.error?a(w.previewer.createExpError+": "+r.error):a(w.previewer.createExpError+": "+t))}))}))}))},t.prototype.resetState=function(e,t){this.timer.stop(),this.setState({rendering:!1,experienceId:null,experience:null,jobId:null,timeElapsed:e?this.state.timeElapsed:0,activeOutput:null,isTimeOut:!1},(function(){t&&t()}))},t.prototype.renderViewerContent=function(){var e=this.state,t=e.rendering,n=e.experience,r=e.timeElapsed,a=e.activeOutput,o=e.isTimeOut,s=this.props,l=s.api,c=s.onError;if(t)return i.createElement("div",{className:"running-prompt"},i.createElement(d.default,null),i.createElement("br",null),i.createElement("h1",null,"  ",w.previewer.expRunning),i.createElement("p",null,w.previewer.time," ",M.formattedTime(r)));if(o||void 0===o)return i.createElement("div",{className:"running-prompt error-wrapper"},i.createElement("h1",null,"  ",w.previewer.runExpErrorDes),i.createElement("p",null,w.previewer.time," ",M.formattedTime(r)));if(n&&a){var p=void 0,f=void 0,h=a.split("."),m=h[0],_=h[1];if(m===u.OUTPUT_TYPES.IMAGE)f=n.output.images[_],p=i.createElement(g.default,{url:f,active:!0});else if(m===u.OUTPUT_TYPES.VIDEO){var v=n.output.videos[_],L=void 0!==v.width?parseInt(v.width,10):null,k=void 0!==v.height?parseInt(v.height,10):null;f=v.url,p=i.createElement(y.default,{url:f,active:!0,maxWidth:L,allowManualScale:!0,maxHeight:k})}else m===u.OUTPUT_TYPES.LOG&&(p=i.createElement("div",{className:"log"},i.createElement(T.default,{api:l,onError:c,jobId:_})));return i.createElement(b.default,{handleWidth:!0,handleHeight:!0},p)}return null},t.prototype.toggleActiveOutput=function(e){this.setState({activeOutput:e})},t.prototype.render=function(){var e,t,n=this.state,r=n.rendering,a=n.experience,o=n.activeOutput,s=a?w.previewer.btnReRender:w.previewer.btnRender,u=r?null:i.createElement(c.default,{size:"large",onClick:this.evtHandlers.createExp,color:"primary",style:"bold"},s);if(a){var d=this.getViewerOptions();e=i.createElement(f.default,{width:"130px",options:d,value:o,onChange:this.evtHandlers.toggleOutput}),t=i.createElement(l.default,{readOnly:!0,width:"360px",label:w.previewer.expIdField,showCopy:!0,value:a.id})}return i.createElement("div",{className:"story-viewer viewer"},i.createElement("div",{className:"variables"},i.createElement("h2",null,w.previewer.previewVars),i.createElement(_.default,null),this.renderVariableFields()),i.createElement("div",{className:"viewer-content"},i.createElement("div",{className:"content-header"},u,i.createElement("div",{className:"output"},e),i.createElement("div",{className:"right-interface"},t)),i.createElement("div",{className:"content-wrapper"},this.renderViewerContent())))},t}(i.PureComponent);t.default=k.connect((function(e){return{notifications:e.notifications}}),{})(x)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.OUTPUT_TYPES=void 0,t.OUTPUT_TYPES={LOG:"log",IMAGE:"image",VIDEO:"video"}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(21),s=n(133),u=n(84),l=n(5),c=n(4),d=function(e){function t(t){var n=e.call(this,t)||this;return n.input=o.createRef(),n.state={processing:!1,processedFile:null},n.evtHandlers={fileUpload:function(e){return n.fileUploaded(e)},fileDrop:function(e,t){return n.onFileDrop(e,t)},clearSelection:function(e){return n.clearSelection(e)},click:function(){return n.onClick()}},n}return a(t,e),t.prototype.clearSelection=function(e){e.preventDefault(),e.stopPropagation(),this.props.onChange(null)},t.prototype.fileUploaded=function(e){var t=e.target.files[0];t&&this.props.onChange(t)},t.prototype.componentDidUpdate=function(e){e.value!==this.props.value&&this.checkFile()},t.prototype.componentDidMount=function(){this.checkFile()},t.prototype.checkFile=function(){var e=this,t=this.props.value;t instanceof File&&this.setState({processing:!0,processedFile:null},(function(){var n=new FileReader;n.onload=function(){e.setState({processing:!1,processedFile:n.result})},n.readAsDataURL(t)}))},t.prototype.renderFields=function(){var e,t=this.state,n=t.processing,r=t.processedFile,a=this.props,u=a.type,l=a.value,c=l instanceof File;if(!l)return null;if(c){if(n)return o.createElement(i.default,null);e=r}else e=l;switch(u.toLowerCase()){case s.VARIABLE_TYPES.IMAGE:return o.createElement("img",{className:"default-preview",src:e});case s.VARIABLE_TYPES.VIDEO:return o.createElement("video",{className:"default-preview",src:e,controls:!0});case s.VARIABLE_TYPES.AUDIO:return o.createElement("audio",{className:"default-preview",src:e,controls:!0})}},t.prototype.getInputFilter=function(){var e=this.props,t=e.type;e.value;switch(t){case s.VARIABLE_TYPES.IMAGE:return"image/*";case s.VARIABLE_TYPES.VIDEO:return"video/*";case s.VARIABLE_TYPES.AUDIO:return"audio/*"}},t.prototype.onClick=function(){var e=this.input.current,t=this.state.processing;e&&!t&&e.click()},t.prototype.renderClearButton=function(){if(this.props.value)return o.createElement(l.default,{onClick:this.evtHandlers.clearSelection},c.ICON_TIMES)},t.prototype.onFileDrop=function(e,t){var n=t.getItem().files[0];n&&this.props.onChange(n)},t.prototype.render=function(){var e=this.state.processing,t=this.getInputFilter();return o.createElement(o.Fragment,null,o.createElement("input",{type:"file",accept:t,style:{display:"none"},ref:this.input,onChange:this.evtHandlers.fileUpload}),o.createElement(u.default,{onDrop:this.evtHandlers.fileDrop,disable:e},o.createElement("div",{className:"variable-default-upload",onClick:this.evtHandlers.click},this.renderFields(),o.createElement("div",{className:"btn-wrapper"},this.renderClearButton()))))},t}(o.PureComponent);t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(503),s=n(135),u=n(53),l=function(e){function t(t){var n=e.call(this,t)||this;return n.state={selectedLayer:null},n.eventHandlers={updateSelectedLayer:function(e){return n.updateSelectedLayer(e)}},n}return a(t,e),t.prototype.updateSelectedLayer=function(e){this.setState({selectedLayer:e})},t.prototype.variablesToInventory=function(){var e=this.props.variables,t={};for(var n in e)if(e.hasOwnProperty(n)){var r=e[n],a=r.type,o=r.previewItem;o&&(a===u.VARIABLE_TYPES.IMAGE||a===u.VARIABLE_TYPES.VIDEO||a===u.VARIABLE_TYPES.AUDIO?t[n]=o.url:t[n]=o.src)}return t},t.prototype.render=function(){var e=this.state.selectedLayer,t=this.props,n=t.storyId,r=t.api,a=t.composition;return a?o.createElement("div",{className:"static-composition-editor"},o.createElement("div",{className:"composition-config"},o.createElement(i.default,{storyId:n,api:r,composition:a,onSelectLayer:this.eventHandlers.updateSelectedLayer,selectedLayer:e,onUpdate:this.props.onUpdate})),o.createElement("div",{className:"composition-preview"},o.createElement(s.default,{inventory:this.variablesToInventory(),composition:a,onSelectLayer:this.eventHandlers.updateSelectedLayer,selectedLayer:e,onUpdate:this.props.onUpdate}))):null},t}(o.PureComponent);t.default=l},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},i=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},s=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var u=n(0),l=n(7),c=n(41),d=n(65),p=n(11),f=n(5),h=n(53),m=n(4),_=n(504),y=function(e){function t(t){var n=e.call(this,t)||this;return n.eventHandlers={inputs:{width:function(e){return n.compValueChanged("width",e)},height:function(e){return n.compValueChanged("height",e)},name:function(e){return n.compValueChanged("name",e)},backgroundColor:function(e){return n.bgChanged(e)}},selectLayer:function(e){return n.props.onSelectLayer(e)}},n.addLayerMenu=u.createElement(f.default,{onClick:function(){return n.addLayer()},style:"subtle",size:"small",color:"primary"},m.ICON_PLUS),n}return a(t,e),t.prototype.addLayer=function(){var e=h.getNewCompositionLayer(),t=o({},this.props.composition),n=s([],i(t.layers));n.push(e),t.layers=n,this.props.onUpdate(t),this.props.onSelectLayer(e.id)},t.prototype.updateLayer=function(e,t){var n=o({},this.props.composition),r=s([],i(n.layers));r[e]=t,n.layers=r,this.props.onUpdate(n)},t.prototype.compValueChanged=function(e,t){var n=o({},this.props.composition);n[e]=t,this.props.onUpdate(n)},t.prototype.bgChanged=function(e){if("transparent"===e.hex)this.compValueChanged("background_color",null);else{var t=e.rgb;this.compValueChanged("background_color","rgba("+t.r+","+t.g+","+t.b+","+t.a+")")}},t.prototype.render=function(){var e=this,t=this.props,n=t.composition,r=t.selectedLayer,a=t.storyId,o=t.api,i=(n.background_color&&n.background_color,u.createElement("span",null,l.compositions.layers," ",this.addLayerMenu));return u.createElement(u.Fragment,null,u.createElement(c.default,{label:l.compositions.width,tooltip:l.compositions.tooltipWidth,value:n.width,width:"30%",labelPosition:"top",onChange:this.eventHandlers.inputs.width}),u.createElement(c.default,{label:l.compositions.height,tooltip:l.compositions.tooltipHeight,value:n.height,width:"30%",labelPosition:"top",onChange:this.eventHandlers.inputs.height}),u.createElement(d.default,{label:l.compositions.backgroundColor,tooltip:l.compositions.tooltipBackgroundColor,enableAlpha:!0,value:n.background_color,width:"40%",labelPosition:"top",pickerPosition:"right",onChange:this.eventHandlers.inputs.backgroundColor}),u.createElement(p.default,{label:i,width:"100%",labelPosition:"top"},n.layers.map((function(t,n){var i=t.id===r;return u.createElement(_.default,{storyId:a,api:o,key:t.id,selected:i,onSelectLayer:e.eventHandlers.selectLayer,onUpdate:function(t){return e.updateLayer(n,t)},options:t})}))))},t}(u.PureComponent);t.default=y},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.V_ALIGN_OPTIONS=t.H_ALIGN_OPTIONS=void 0;var i=n(0),s=n(53),u=n(25),l=n(64),c=n(63),d=n(13),p=n(22),f=n(99),h=n(129),m=n(7),_=n(65),y=n(30),g=n(41),v=n(4);t.H_ALIGN_OPTIONS=[{icon:v.ICON_ALIGN_LEFT,value:"left"},{icon:v.ICON_ALIGN_CENTER,value:"center"},{icon:v.ICON_ALIGN_RIGHT,value:"right"}],t.V_ALIGN_OPTIONS=[{icon:v.ICON_ARROW_UP,value:"flex-start"},{icon:v.ICON_ARROW_CENTER_V,value:"center"},{icon:v.ICON_ARROW_DOWN,value:"flex-end"}];var b=function(e){function n(t){var n=e.call(this,t)||this;return n.eventHandlers={inputs:{name:function(e){return n.optionValueChanged("name",e)},width:function(e){return n.optionValueChanged("width",e)},height:function(e){return n.optionValueChanged("height",e)},x:function(e){return n.optionValueChanged("x",e)},y:function(e){return n.optionValueChanged("y",e)},rotation:function(e){return n.optionValueChanged("rotation",e)},content:function(e){return n.optionValueChanged("content",e)},hAlign:function(e){return n.optionValueChanged("horizontal_alignment",e)},vAlign:function(e){return n.optionValueChanged("vertical_alignment",e)},textWrap:function(e){return n.optionValueChanged("text_wrap",e)},textFit:function(e){return n.optionValueChanged("text_fit",e)},fontSize:function(e){return n.optionValueChanged("font_size",e)},lineHeight:function(e){return n.optionValueChanged("line_height",e)},letterSpacing:function(e){return n.optionValueChanged("letter_spacing",e)},font:function(e){return n.optionValueChanged("font",e)},customFont:function(e){return n.customFontUpdated(e)},fontType:function(e){return n.fontTypeChanged(e)},wordSpacing:function(e){return n.optionValueChanged("word_spacing",e)},color:function(e){return n.optionValueChanged("color",n.formatColor(e))},backgroundColor:function(e){return n.optionValueChanged("background_color",n.formatColor(e))}},onCardOpen:function(e){return n.onCardOpen()},onCardClose:function(e){return n.onCardClose()}},n}return a(n,e),n.prototype.customFontUpdated=function(e){var t=o({},this.props.options);if(e){var n=e.name,r=e.url,a=e.id;t.font=n,t.custom_font_url=r,t.custom_font_id=a}else t.font=s.DEFAULT_FONT,t.custom_font_url=null,t.custom_font_id=null;this.props.onUpdate(t)},n.prototype.onCardOpen=function(){var e=this.props.options.id;this.props.onSelectLayer(e)},n.prototype.onCardClose=function(){this.props.onSelectLayer(null)},n.prototype.fontTypeChanged=function(e){var t=o({},this.props.options);e===s.FONT_TYPES.STANDARD?(t.font_type=s.FONT_TYPES.STANDARD,t.font=s.DEFAULT_FONT):e===s.FONT_TYPES.CUSTOM&&(t.fontType=s.FONT_TYPES.CUSTOM,t.font=s.DEFAULT_FONT,t.custom_font_id=null,t.custom_font_url=null),this.props.onUpdate(t)},n.prototype.formatColor=function(e){var t=e.rgb;return"rgba("+t.r+","+t.g+","+t.b+","+t.a+")"},n.prototype.optionValueChanged=function(e,t){var n=o({},this.props.options);n[e]=t,this.props.onUpdate(n)},n.prototype.renderFontField=function(){var e=this.props,t=e.options,n=t.font_type,r=t.custom_font_id,a=t.font,o=e.storyId,l=e.api;return n===s.FONT_TYPES.STANDARD?i.createElement(p.default,{label:m.compositions.font,labelPosition:"top",width:"50%",options:s.STADARD_FONTS,onChange:this.eventHandlers.inputs.font,value:a}):n===s.FONT_TYPES.CUSTOM?i.createElement(h.default,{api:l,storyId:o,label:m.compositions.font,width:"50%",labelPosition:"top",onChange:this.eventHandlers.inputs.customFont,accepts:u.ASSET_TYPES.FONT,assetId:r}):null},n.prototype.render=function(){var e=this.props,n=e.options,r=e.selected;return i.createElement(f.default,{open:r,onOpen:this.eventHandlers.onCardOpen,onClose:this.eventHandlers.onCardClose,collapsable:!0,title:n.name},i.createElement(d.default,{label:m.compositions.name,tooltip:m.compositions.tooltipName,value:n.name,width:"100%",labelPosition:"top",onChange:this.eventHandlers.inputs.name}),i.createElement(g.default,{label:m.compositions.x,tooltip:m.compositions.tooltipLayerX,value:n.x,width:"20%",labelPosition:"top",onChange:this.eventHandlers.inputs.x}),i.createElement(g.default,{label:m.compositions.y,tooltip:m.compositions.tooltipLayerY,value:n.y,width:"20%",labelPosition:"top",onChange:this.eventHandlers.inputs.y}),i.createElement(g.default,{label:m.compositions.width,tooltip:m.compositions.tooltipLayerWidth,value:n.width,width:"20%",labelPosition:"top",onChange:this.eventHandlers.inputs.width}),i.createElement(g.default,{label:m.compositions.height,tooltip:m.compositions.tooltipLayerHeight,value:n.height,width:"20%",labelPosition:"top",onChange:this.eventHandlers.inputs.height}),i.createElement(g.default,{value:n.rotation,label:m.compositions.rotation,tooltip:m.compositions.tooltipLayerRotation,width:"20%",labelPosition:"top",onChange:this.eventHandlers.inputs.rotation}),i.createElement(l.default,{label:m.compositions.textLayerContent,tooltip:m.compositions.tooltipTextLayerContent,value:n.content,width:"100%",labelPosition:"top",onChange:this.eventHandlers.inputs.content}),i.createElement(c.default,{options:t.H_ALIGN_OPTIONS,value:n.horizontal_alignment,width:"50%",onChange:this.eventHandlers.inputs.hAlign}),i.createElement(c.default,{options:t.V_ALIGN_OPTIONS,value:n.vertical_alignment,width:"50%",onChange:this.eventHandlers.inputs.vAlign}),i.createElement(p.default,{label:m.compositions.fontType,options:s.FONT_TYPE_OPTIONS,value:n.font_type,width:"50%",labelPosition:"top",onChange:this.eventHandlers.inputs.fontType}),this.renderFontField(),i.createElement(g.default,{label:m.compositions.fontSize,value:n.font_size,width:"50%",labelPosition:"top",onChange:this.eventHandlers.inputs.fontSize}),i.createElement(g.default,{label:m.compositions.lineHeight,value:n.line_height,width:"50%",labelPosition:"top",onChange:this.eventHandlers.inputs.lineHeight}),i.createElement(g.default,{label:m.compositions.letterSpacing,value:n.letter_spacing,width:"50%",labelPosition:"top",onChange:this.eventHandlers.inputs.letterSpacing}),i.createElement(g.default,{label:m.compositions.wordSpacing,value:n.word_spacing,width:"50%",labelPosition:"top",onChange:this.eventHandlers.inputs.wordSpacing}),i.createElement(_.default,{label:m.compositions.color,value:n.color,enableAlpha:!0,width:"50%",labelPosition:"top",pickerPosition:"left",onChange:this.eventHandlers.inputs.color}),i.createElement(_.default,{label:m.compositions.backgroundColor,value:n.background_color,enableAlpha:!0,width:"50%",labelPosition:"top",pickerPosition:"right",onChange:this.eventHandlers.inputs.backgroundColor}),i.createElement(y.default,{label:m.compositions.wrap,value:n.text_wrap,width:"25%",labelPosition:"top",onChange:this.eventHandlers.inputs.textWrap}),i.createElement(y.default,{label:m.compositions.fit,value:n.text_fit,width:"25%",labelPosition:"top",onChange:this.eventHandlers.inputs.textFit}))},n}(i.PureComponent);t.default=b},function(e,t){e.exports=f},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),a=n(16);t.default=function(e){var t=e.shortcutCopyMap,n=e.heading,o=n?r.createElement(r.Fragment,null,r.createElement("h3",null,n),r.createElement(a.default,null)):null;return r.createElement("div",{className:"shortcuts-menu"},o,r.createElement("table",null,r.createElement("tbody",null,Object.keys(t).map((function(e){return r.createElement("tr",{className:"shortcut",key:e},r.createElement("td",{className:"hotkey-cell"},e),r.createElement("td",{className:"shortcut-desc"},t[e]))})))))}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(13),s=n(11),u=n(51),l=n(16),c=n(9),d=n(8),p=n(7),f=function(e){function t(t){var n=e.call(this,t)||this;return n.render=function(){var e=n.props,t=e.asset,r=e.columns,a=e.newAsset,u=e.assetTags;if(!t)return null;var d=a?p.assets.newDetails:p.assets.details,f=c.formatDateDefault(t.date_created),h=2===r,m=a?void 0:function(e){return n.props.onNameChange(e)},_=a?function(e){return n.props.onNameChange(e)}:void 0,y=o.createElement(i.default,{label:p.assets.name,controlled:!a,width:h?"50%":"100%",onSubmit:m,onChange:_,value:t.name}),g=o.createElement(i.default,{readOnly:!0,label:p.assets.date,width:h?"50%":"100%",value:f}),v=o.createElement(i.default,{submittable:!0,submittableType:"add",label:p.assets.addTag,suggestions:u,doSubmit:function(e){return n.props.onAddTag(e)},width:h?"50%":"100%",buttons:[],value:n.state.newTag}),b=o.createElement(s.default,{label:p.assets.assetTag,width:h?"50%":"100%"},n.renderTags());return o.createElement("div",{className:"asset-details"},o.createElement("h2",null,d),o.createElement("div",{className:"header-buttons"},n.props.headerButtons),o.createElement(l.default,null),y,g,v,b)},n.state={newTag:""},n}return a(t,e),t.prototype.renderTags=function(){var e=this;return this.props.asset.tags.map((function(t){return o.createElement(u.default,{key:t,copy:t,removeHandler:function(){return e.props.onRemoveTag(t)},colorize:!0})}))},t}(o.Component);t.default=d.connect((function(e){return{assetTags:e.assetTags}}),null)(f)},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(5),s=n(64),u=n(16),l=n(7),c=n(4),d=function(e){function t(t){var n=e.call(this,t)||this;return n.getFirstAct=function(e){for(var t in e.acts)if(e.acts.hasOwnProperty(t))return e.acts[t]},n}return a(t,e),t.prototype.createUrl=function(){var e=this.props,t=e.story,n=e.compositionId,r=e.accessKey,a=t.id,o=this.getFirstAct(t).inventory,i="";for(var s in o){if(o.hasOwnProperty(s))i+=""+(i?"&":"?")+s+"={{"+s.toUpperCase()+"}}"}var u=window.location.href,l=-1!==u.indexOf("staging")||-1!==u.indexOf("localhost")?"staging.imposium.com":"imposium.com";return'<a href="'+("https://player."+l+"/new/"+r+"/"+a+"/"+n+i)+'" target="_blank"><img width="400" alt="Play Video" src="'+("https://api."+l+"/story/"+a+"/"+n+"/poster"+i)+'"></a>'},t.prototype.render=function(){var e=this.props,t=e.status,n=e.handleError,r=e.handleNotification;return o.createElement("div",null,o.createElement("h2",null,l.publish.hubspotTitle),o.createElement(u.default,null),o.createElement("p",null,l.publish.hubspotDesc),o.createElement(u.default,null),o.createElement(s.default,{label:l.publish.embeddedCode,value:this.createUrl(),showCopy:t!==l.header.publishing,onNotification:function(e){return r(e)},onError:function(e){return n(e)},readOnly:!0}),t===l.header.publishing&&o.createElement(i.default,{size:"small",customStyles:{margin:0,height:"20px",border:"none"},color:"primary",onClick:function(){return n(l.publish.embeddedCodeCopyError)}},c.ICON_CLIPBOARD))},t}(o.PureComponent);t.default=d},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),i=n(16),s=n(54),u=n(137),l=n(7),c=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return a(t,e),t.prototype.render=function(){return o.createElement("div",null,o.createElement("h2",null,l.integration.documentation),o.createElement(i.default,null),o.createElement("p",null,l.integration.docParagraph),o.createElement("div",{className:"link-wrapper"},null===u.documentationLinks||void 0===u.documentationLinks?void 0:u.documentationLinks.map((function(e){return o.createElement(s.BigLink,{key:e.key,label:e.label,link:e.link})}))))},t}(o.PureComponent);t.default=c},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.downloadSDKArchive=void 0;var a=n(28),o=n(511),i={method:"POST",responseType:"blob",headers:{"Content-Type":"application/json"}};t.downloadSDKArchive=function(e,t){var n=r(r({},i),{url:"https://template-generator.imposium.com/sdk-archive",data:JSON.stringify(t)});a.default(n).then((function(t){o.saveAs(t.data,e)})).catch((function(e){console.error("Failed to download sdk archive:",e)}))}},function(e,t,n){(function(n){var r,a,o;a=[],void 0===(o="function"==typeof(r=function(){"use strict";function t(e,t,n){var r=new XMLHttpRequest;r.open("GET",e),r.responseType="blob",r.onload=function(){s(r.response,t,n)},r.onerror=function(){console.error("could not download file")},r.send()}function r(e){var t=new XMLHttpRequest;t.open("HEAD",e,!1);try{t.send()}catch(e){}return 200<=t.status&&299>=t.status}function a(e){try{e.dispatchEvent(new MouseEvent("click"))}catch(n){var t=document.createEvent("MouseEvents");t.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),e.dispatchEvent(t)}}var o="object"==typeof window&&window.window===window?window:"object"==typeof self&&self.self===self?self:"object"==typeof n&&n.global===n?n:void 0,i=o.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),s=o.saveAs||("object"!=typeof window||window!==o?function(){}:"download"in HTMLAnchorElement.prototype&&!i?function(e,n,i){var s=o.URL||o.webkitURL,u=document.createElement("a");n=n||e.name||"download",u.download=n,u.rel="noopener","string"==typeof e?(u.href=e,u.origin===location.origin?a(u):r(u.href)?t(e,n,i):a(u,u.target="_blank")):(u.href=s.createObjectURL(e),setTimeout((function(){s.revokeObjectURL(u.href)}),4e4),setTimeout((function(){a(u)}),0))}:"msSaveOrOpenBlob"in navigator?function(e,n,o){if(n=n||e.name||"download","string"!=typeof e)navigator.msSaveOrOpenBlob(function(e,t){return void 0===t?t={autoBom:!1}:"object"!=typeof t&&(console.warn("Deprecated: Expected third argument to be a object"),t={autoBom:!t}),t.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(e.type)?new Blob(["\ufeff",e],{type:e.type}):e}(e,o),n);else if(r(e))t(e,n,o);else{var i=document.createElement("a");i.href=e,i.target="_blank",setTimeout((function(){a(i)}))}}:function(e,n,r,a){if((a=a||open("","_blank"))&&(a.document.title=a.document.body.innerText="downloading..."),"string"==typeof e)return t(e,n,r);var s="application/octet-stream"===e.type,u=/constructor/i.test(o.HTMLElement)||o.safari,l=/CriOS\/[\d]+/.test(navigator.userAgent);if((l||s&&u||i)&&"undefined"!=typeof FileReader){var c=new FileReader;c.onloadend=function(){var e=c.result;e=l?e:e.replace(/^data:[^;]*;/,"data:attachment/file;"),a?a.location.href=e:location=e,a=null},c.readAsDataURL(e)}else{var d=o.URL||o.webkitURL,p=d.createObjectURL(e);a?a.location=p:location.href=p,a=null,setTimeout((function(){d.revokeObjectURL(p)}),4e4)}});o.saveAs=s.saveAs=s,e.exports=s})?r.apply(t,a):r)||(e.exports=o)}).call(this,n(38))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getDemoURL=void 0;t.getDemoURL=function(){var e=window.location.href;return-1!==e.indexOf("localhost")?"http://localhost:3044":-1!==e.indexOf("staging")?"https://demo.staging.imposium.com":"https://demo.imposium.com"}},function(e,t,n){"use strict";var r,a=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},i=this&&this.__values||function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(t,"__esModule",{value:!0});var s=n(0),u=n(16),l=n(21),c=n(7),d=n(54),p=n(514),f=n(4),h=n(1),m=n(10),_=n(8),y=n(22),g=n(88),v=function(e){function t(t){var n=e.call(this,t)||this;return n.selectCsv=function(){n.hiddenFileInputRef.current&&n.hiddenFileInputRef.current.click()},n.doUploadCsv=function(e){e.persist();var t=n.props.handleError;n.setState({uploading:!0,renderedBatch:!1}),n.props.createFreshBatch(n.getBatchName()).then((function(t){var r=t.id,a=t.name,o=t.story_id;n.setState({selectedBatchId:r}),n.importBatch({story_id:o,id:r,name:a,uploadEvt:e})})).catch((function(e){throw t(e),n.setState({uploadComplete:!1,uploading:!1}),e}))},n.getBatch=function(){var e=n.props.api;n.props.setPage(1),n.props.getBatch(e)},n.state={uploadComplete:!1,uploading:!1,downloading:!1,selectedBatchId:"",renderedBatch:!1,inventory:[],inventoryKeys:[],missingColumns:"",isMissing:!1},n.hiddenFileInputRef=s.createRef(),n}return a(t,e),t.prototype.componentDidMount=function(){this.getInventory()},t.prototype.getInventory=function(){var e=this.props.story.acts,t=Object.keys(e),n={};t.forEach((function(t){n=o(o({},n),e[t].inventory)}));var r=Object.keys(n).sort();this.setState({inventory:n}),this.setState({inventoryKeys:r})},t.prototype.downloadSampleCsv=function(){var e=this.props.story.name,n=this.state,r=n.inventory,a=n.inventoryKeys.map((function(e){return{id:e,name:r[e].name,show:!0}})).map((function(e){return e.id})).reduce((function(e,t){var n;return o(o({},e),((n={})[t]="",n))}),{}),i=b(e)+"-batch-template";new p.ExportToCsv(o(o({},t.CSV_EXPORT_CONFIG),{filename:i})).generateCsv([a])},t.prototype.getBatchName=function(){var e=this.props,t=e.story.name,n=e.compositionName,r=Date.now(),a=h(r).format("MMDDYY-HHmm");return b(t)+"-"+b(n)+"-"+a},t.prototype.proceedWithExport=function(){var e=this,t=this.props,n=t.renderBatch,r=t.activeBatch.data;n(r.id,r.name).then((function(){e.setState({renderedBatch:!0})})).catch((function(t){throw e.props.handleError(c.publish.renderBatchFailed),e.setState({renderedBatch:!1}),t}))},t.prototype.importBatch=function(e){var t=this,n=e.story_id,r=e.id,a=e.name,o=e.uploadEvt,i=this.props,s=i.accessKey,u=i.compositionId,l=i.isExport,c=i.onError;this.props.importBatchFromCsv(n,r,a,o.target.files[0],s,u,!l,l).then((function(){t.props.batchJobs.missing.length>0&&c(),t.setState({uploadComplete:!0,uploading:!1}),t.getBatch(),l&&0===Object.keys(t.props.batchJobs.missing).length&&t.renderBatch({id:r,name:a})})).catch((function(e){throw t.setState({uploadComplete:!1,uploading:!1}),e}))},t.prototype.renderBatch=function(e){var t=this,n=e.id,r=e.name;this.props.renderBatch(n,r).then((function(){t.setState({renderedBatch:!0})})).catch((function(e){throw t.props.handleError(c.publish.renderBatchFailed),t.setState({renderedBatch:!1}),e}))},t.prototype.downloadCsv=function(){var e=this;this.setState({downloading:!0},(function(){var t=e.props,n=t.status,r=(t.api,t.handleError),a=e.state.selectedBatchId;n!==c.header.publishing?e.props.getBatchExport(a).then((function(){e.props.onDone(),e.setState({downloading:!1})})):r(c.publish.downloadError)}))},t.prototype.renderLabel=function(){var e=this.props,n=e.isExport,r=e.batchJobs,a=this.state,o=a.renderedBatch,i=a.selectedBatchId,u=a.uploading,d=a.uploadComplete;if(n&&d&&!o&&0===Object.keys(this.props.batchJobs.missing).length)return s.createElement("div",{className:"progress-bar"},s.createElement("progress",{max:t.PROGRESS_MAX_VALUE,value:r.renders[i]}));if(u){var p=n?c.publish.importingData:c.publish.creatingLinks;return s.createElement("span",null,s.createElement(l.default,null)," ",p)}return s.createElement("span",null,f.ICON_UPLOAD," ",c.publish.uploadCsv)},t.prototype.onAssociationChange=function(e,t,n){var r=this.props.activeBatch.data.columns.findIndex((function(e){return e.detail===t}));-1!==r&&this.props.updateAssociation(this.props.api,r,"Static",null),this.props.updateAssociation(this.props.api,parseInt(e,10),"UGC",t),this.props.onNext(n)},t.prototype.renderColumnMap=function(){var e,t,n=this,r=this.props,a=r.activeBatch.data.columns,l=r.batchJobs.missing,d=r.variables;if(l.length>=0&&a){var p=Object.keys(d).map((function(e){return o({},d[e])})),f=Object.keys(a).map((function(e){return a[e]})),h=f.filter((function(e){return 0!==e.from_import})).map((function(e,t){var n={value:t,label:e.name};return-1!==p.findIndex((function(t){return e.detail===t.id}))&&(n.disabled=!0),n})),m=!1,_=function(e){if(!e.optional&&-1===f.findIndex((function(t){return t.detail===e.id})))return m=!0,"break"};try{for(var g=i(p),v=g.next();!v.done;v=g.next()){if("break"===_(v.value))break}}catch(t){e={error:t}}finally{try{v&&!v.done&&(t=g.return)&&t.call(g)}finally{if(e)throw e.error}}h.unshift("");var b=Object.keys(l).map((function(e){return l[e]})).join();return h.length<p.length?s.createElement(s.Fragment,null,s.createElement("h2",null,c.publish.titleMissingColumns),s.createElement(u.default,null),s.createElement("p",{className:"missingColumns"},c.publish.csvMissingColumns+" "+b)):s.createElement("div",{className:"align-columns"},s.createElement("h2",{className:"match-columns"},""+c.publish.csvMatchColumns),s.createElement(u.default,null),s.createElement("table",null,s.createElement("thead",null,s.createElement("tr",null,s.createElement("th",null,"Variable"),s.createElement("th",null,"CSV Column"))),s.createElement("tbody",null,p.map((function(e,t){var r=f.findIndex((function(t){return t.detail===e.id})),a=null!=r?r:"",o=e.optional?"":"required";return s.createElement("tr",{key:"var-"+e.id,className:""+o},s.createElement("td",{className:"variable"},s.createElement("p",null,e.name," ",e.optional?null:s.createElement("span",{style:{color:"red"}}," * "))),s.createElement("td",null,s.createElement(y.default,{options:h,value:a,onChange:function(t){return n.onAssociationChange(t,e.id,m)}})))})))))}},t.prototype.render=function(){var e=this,n=this.state,r=n.uploadComplete,a=n.uploading,o=n.downloading,i=n.renderedBatch,p=n.selectedBatchId,h=this.props,m=h.isExport,_=h.batchJobs,y=_.missing,g=_.renders,v=[{label:s.createElement("span",null,f.ICON_DOWNLOAD," ",c.publish.downloadSampleCsvLink),onClick:function(){return e.downloadSampleCsv()},key:"download-sample"},{label:this.renderLabel(),onClick:function(){return e.selectCsv()},key:"upload",disabled:m&&r||a}],b=o?s.createElement("span",null,s.createElement(l.default,null)," ",c.publish.exporting):s.createElement("span",null,f.ICON_DOWNLOAD," ",c.publish.btnDownload),w=s.createElement("div",{className:"progress-bar"},s.createElement("progress",{max:t.PROGRESS_MAX_VALUE,value:g[p]})),M=s.createElement("div",null,s.createElement("h2",null,r?c.publish.downloadLink:c.publish.generatingLink),s.createElement(u.default,null),s.createElement("p",null,r?c.publish.downloadDesc:c.publish.generatingLinkDesc),m&&r&&!i?s.createElement(d.BigButton,{label:w,disabled:m}):s.createElement(d.BigButton,{label:b,disabled:o,onClick:function(){return e.downloadCsv()}})),L=s.createElement(s.Fragment,null,this.props.error?this.props.next?M:"":M,this.renderColumnMap()),T=s.createElement("div",null,s.createElement("h2",null,c.publish.emailTitle),s.createElement(u.default,null),s.createElement("p",null,c.publish.emailDesc),s.createElement("input",{type:"file",style:{display:"none"},accept:"text/csv",ref:this.hiddenFileInputRef,onChange:this.doUploadCsv}),s.createElement("div",{className:"link-wrapper"},null==v?void 0:v.map((function(e,t){return s.createElement(d.BigButton,{label:s.createElement("span",null,e.label),onClick:e.onClick,disabled:null==e?void 0:e.disabled,key:e.key})}))));return(m&&0===Object.keys(y).length?i:r)?L:T},t.PROGRESS_MAX_VALUE=100,t.CSV_EXPORT_CONFIG={fieldSeparator:",",quoteStrings:'"',decimalSeparator:".",showLabels:!1,showTitle:!1,useTextFile:!1,useBom:!1,useKeysAsHeaders:!0},t}(s.PureComponent),b=function(e){return e.replace(/\W/g,"")};t.default=_.connect((function(e){return{activeBatch:e.activeBatch,batchesList:e.batchesList}}),(function(e){return m.bindActionCreators({updateAssociation:g.updateAssociation,getBatch:g.getBatch,setPage:g.setPage},e)}),null,{withRef:!0})(v)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}(n(515))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(){}return e.EOL="\r\n",e.BOM="\ufeff",e.DEFAULT_FIELD_SEPARATOR=",",e.DEFAULT_DECIMAL_SEPARATOR=".",e.DEFAULT_QUOTE='"',e.DEFAULT_SHOW_TITLE=!1,e.DEFAULT_TITLE="My Generated Report",e.DEFAULT_FILENAME="generated",e.DEFAULT_SHOW_LABELS=!1,e.DEFAULT_USE_TEXT_FILE=!1,e.DEFAULT_USE_BOM=!0,e.DEFAULT_HEADER=[],e.DEFAULT_KEYS_AS_HEADERS=!1,e}();t.CsvConfigConsts=r,t.ConfigDefaults={filename:r.DEFAULT_FILENAME,fieldSeparator:r.DEFAULT_FIELD_SEPARATOR,quoteStrings:r.DEFAULT_QUOTE,decimalSeparator:r.DEFAULT_DECIMAL_SEPARATOR,showLabels:r.DEFAULT_SHOW_LABELS,showTitle:r.DEFAULT_SHOW_TITLE,title:r.DEFAULT_TITLE,useTextFile:r.DEFAULT_USE_TEXT_FILE,useBom:r.DEFAULT_USE_BOM,headers:r.DEFAULT_HEADER,useKeysAsHeaders:r.DEFAULT_KEYS_AS_HEADERS};var a=function(){function e(e){this._csv="";var n=e||{};this._options=u({},t.ConfigDefaults,n),this._options.useKeysAsHeaders&&this._options.headers&&this._options.headers.length>0&&console.warn("Option to use object keys as headers was set, but headers were still passed!")}return Object.defineProperty(e.prototype,"options",{get:function(){return this._options},set:function(e){this._options=u({},t.ConfigDefaults,e)},enumerable:!0,configurable:!0}),e.prototype.generateCsv=function(e,t){if(void 0===t&&(t=!1),this._csv="",this._parseData(e),this._options.useBom&&(this._csv+=r.BOM),this._options.showTitle&&(this._csv+=this._options.title+"\r\n\n"),this._getHeaders(),this._getBody(),""!=this._csv){if(t)return this._csv;var n=this._options.useTextFile?"plain":"csv",a=this._options.useTextFile?".txt":".csv",o=new Blob([this._csv],{type:"text/"+n+";charset=utf8;"});if(navigator.msSaveBlob){var i=this._options.filename.replace(/ /g,"_")+a;navigator.msSaveBlob(o,i)}else{this._options.useTextFile,encodeURI(this._csv);var s=document.createElement("a");s.href=URL.createObjectURL(o),s.setAttribute("visibility","hidden"),s.download=this._options.filename.replace(/ /g,"_")+a,document.body.appendChild(s),s.click(),document.body.removeChild(s)}}else console.log("Invalid data")},e.prototype._getHeaders=function(){if(this._options.showLabels||this._options.useKeysAsHeaders){var e=this._options.useKeysAsHeaders?Object.keys(this._data[0]):this._options.headers;if(e.length>0){for(var t="",n=0;n<e.length;n++)t+=e[n]+this._options.fieldSeparator;t=t.slice(0,-1),this._csv+=t+r.EOL}}},e.prototype._getBody=function(){for(var e=Object.keys(this._data[0]),t=0;t<this._data.length;t++){for(var n="",a=0;a<e.length;a++){var o=e[a];n+=this._formatData(this._data[t][o])+this._options.fieldSeparator}n=n.slice(0,-1),this._csv+=n+r.EOL}},e.prototype._formatData=function(e){return"locale"===this._options.decimalSeparator&&this._isFloat(e)?e.toLocaleString():"."!==this._options.decimalSeparator&&this._isFloat(e)?e.toString().replace(".",this._options.decimalSeparator):"string"==typeof e?(e=e.replace(/"/g,'""'),(this._options.quoteStrings||e.indexOf(",")>-1||e.indexOf("\n")>-1||e.indexOf("\r")>-1)&&(e=this._options.quoteStrings+e+this._options.quoteStrings),e):"boolean"==typeof e?e?"TRUE":"FALSE":e},e.prototype._isFloat=function(e){return+e===e&&(!isFinite(e)||Boolean(e%1))},e.prototype._parseData=function(e){return this._data="object"!=typeof e?JSON.parse(e):e,this._data},e}();t.ExportToCsv=a;var o=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;function s(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function u(e){for(var t,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];for(var a,u=s(e),l=1;l<arguments.length;l++){for(var c in t=Object(arguments[l]))o.call(t,c)&&(u[c]=t[c]);if(Object.getOwnPropertySymbols){a=Object.getOwnPropertySymbols(t);for(var d=0;d<a.length;d++)i.call(t,a[d])&&(u[a[d]]=t[a[d]])}}return u}},function(e,t,n){var r={"./af":138,"./af.js":138,"./ar":139,"./ar-dz":140,"./ar-dz.js":140,"./ar-kw":141,"./ar-kw.js":141,"./ar-ly":142,"./ar-ly.js":142,"./ar-ma":143,"./ar-ma.js":143,"./ar-sa":144,"./ar-sa.js":144,"./ar-tn":145,"./ar-tn.js":145,"./ar.js":139,"./az":146,"./az.js":146,"./be":147,"./be.js":147,"./bg":148,"./bg.js":148,"./bm":149,"./bm.js":149,"./bn":150,"./bn-bd":151,"./bn-bd.js":151,"./bn.js":150,"./bo":152,"./bo.js":152,"./br":153,"./br.js":153,"./bs":154,"./bs.js":154,"./ca":155,"./ca.js":155,"./cs":156,"./cs.js":156,"./cv":157,"./cv.js":157,"./cy":158,"./cy.js":158,"./da":159,"./da.js":159,"./de":160,"./de-at":161,"./de-at.js":161,"./de-ch":162,"./de-ch.js":162,"./de.js":160,"./dv":163,"./dv.js":163,"./el":164,"./el.js":164,"./en-au":165,"./en-au.js":165,"./en-ca":166,"./en-ca.js":166,"./en-gb":167,"./en-gb.js":167,"./en-ie":168,"./en-ie.js":168,"./en-il":169,"./en-il.js":169,"./en-in":170,"./en-in.js":170,"./en-nz":171,"./en-nz.js":171,"./en-sg":172,"./en-sg.js":172,"./eo":173,"./eo.js":173,"./es":174,"./es-do":175,"./es-do.js":175,"./es-mx":176,"./es-mx.js":176,"./es-us":177,"./es-us.js":177,"./es.js":174,"./et":178,"./et.js":178,"./eu":179,"./eu.js":179,"./fa":180,"./fa.js":180,"./fi":181,"./fi.js":181,"./fil":182,"./fil.js":182,"./fo":183,"./fo.js":183,"./fr":184,"./fr-ca":185,"./fr-ca.js":185,"./fr-ch":186,"./fr-ch.js":186,"./fr.js":184,"./fy":187,"./fy.js":187,"./ga":188,"./ga.js":188,"./gd":189,"./gd.js":189,"./gl":190,"./gl.js":190,"./gom-deva":191,"./gom-deva.js":191,"./gom-latn":192,"./gom-latn.js":192,"./gu":193,"./gu.js":193,"./he":194,"./he.js":194,"./hi":195,"./hi.js":195,"./hr":196,"./hr.js":196,"./hu":197,"./hu.js":197,"./hy-am":198,"./hy-am.js":198,"./id":199,"./id.js":199,"./is":200,"./is.js":200,"./it":201,"./it-ch":202,"./it-ch.js":202,"./it.js":201,"./ja":203,"./ja.js":203,"./jv":204,"./jv.js":204,"./ka":205,"./ka.js":205,"./kk":206,"./kk.js":206,"./km":207,"./km.js":207,"./kn":208,"./kn.js":208,"./ko":209,"./ko.js":209,"./ku":210,"./ku.js":210,"./ky":211,"./ky.js":211,"./lb":212,"./lb.js":212,"./lo":213,"./lo.js":213,"./lt":214,"./lt.js":214,"./lv":215,"./lv.js":215,"./me":216,"./me.js":216,"./mi":217,"./mi.js":217,"./mk":218,"./mk.js":218,"./ml":219,"./ml.js":219,"./mn":220,"./mn.js":220,"./mr":221,"./mr.js":221,"./ms":222,"./ms-my":223,"./ms-my.js":223,"./ms.js":222,"./mt":224,"./mt.js":224,"./my":225,"./my.js":225,"./nb":226,"./nb.js":226,"./ne":227,"./ne.js":227,"./nl":228,"./nl-be":229,"./nl-be.js":229,"./nl.js":228,"./nn":230,"./nn.js":230,"./oc-lnc":231,"./oc-lnc.js":231,"./pa-in":232,"./pa-in.js":232,"./pl":233,"./pl.js":233,"./pt":234,"./pt-br":235,"./pt-br.js":235,"./pt.js":234,"./ro":236,"./ro.js":236,"./ru":237,"./ru.js":237,"./sd":238,"./sd.js":238,"./se":239,"./se.js":239,"./si":240,"./si.js":240,"./sk":241,"./sk.js":241,"./sl":242,"./sl.js":242,"./sq":243,"./sq.js":243,"./sr":244,"./sr-cyrl":245,"./sr-cyrl.js":245,"./sr.js":244,"./ss":246,"./ss.js":246,"./sv":247,"./sv.js":247,"./sw":248,"./sw.js":248,"./ta":249,"./ta.js":249,"./te":250,"./te.js":250,"./tet":251,"./tet.js":251,"./tg":252,"./tg.js":252,"./th":253,"./th.js":253,"./tk":254,"./tk.js":254,"./tl-ph":255,"./tl-ph.js":255,"./tlh":256,"./tlh.js":256,"./tr":257,"./tr.js":257,"./tzl":258,"./tzl.js":258,"./tzm":259,"./tzm-latn":260,"./tzm-latn.js":260,"./tzm.js":259,"./ug-cn":261,"./ug-cn.js":261,"./uk":262,"./uk.js":262,"./ur":263,"./ur.js":263,"./uz":264,"./uz-latn":265,"./uz-latn.js":265,"./uz.js":264,"./vi":266,"./vi.js":266,"./x-pseudo":267,"./x-pseudo.js":267,"./yo":268,"./yo.js":268,"./zh-cn":269,"./zh-cn.js":269,"./zh-hk":270,"./zh-hk.js":270,"./zh-mo":271,"./zh-mo.js":271,"./zh-tw":272,"./zh-tw.js":272};function a(e){var t=o(e);return n(t)}function o(e){if(!n.o(r,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return r[e]}a.keys=function(){return Object.keys(r)},a.resolve=o,e.exports=a,a.id=516},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(39),o=n(29),i=null;try{var s=JSON.parse(localStorage.getItem(a.AUTH_CACHE_KEY));if(s){var u=s.idTokenPayload.exp;o.default.checkExpiry(u)&&(i=s)}}catch(e){console.warn("Cached credentials were malformed or missing, redirected to login.")}t.default=function(e,t){switch(void 0===e&&(e=i),t.type){case a.default.LOGIN:return r({},t.auth);case a.default.CLEAR:return null;default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(40),o=null;try{o=JSON.parse(localStorage.getItem(a.ACCESS_CACHE_KEY))}catch(e){console.warn("Cached access data was malformed or missing, redirected to login.")}t.default=function(e,t){switch(void 0===e&&(e=o),t.type){case a.default.SET:case a.default.STORY_ADDED:case a.default.STORY_NAME_MUTATION:case a.default.ORG_NAME_MUTATION:case a.default.STORY_DELETED:return r({},t.accessData);case a.default.CLEAR:return null;default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(55),o={publishing:!1};t.default=function(e,t){switch(void 0===e&&(e=o),t.type){case a.default.UPDATE_PUBLISH_STATUS:return r(r({},e),t.data);case a.default.CLEAR_PUBLISH_STATUS:return o;default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(24),o={page:1,order:"date_created",order_direction:"desc",name:"",type:"",tags:""};t.default=function(e,t){switch(void 0===e&&(e=o),t.type){case a.default.UPDATE:return r(r({},e),t.newFilters);case a.default.RESET:return r({},o);default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},o=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var i=n(17),s={loading:!1};t.default=function(e,t){void 0===e&&(e=s);var n,u=[];switch(t.type){case i.default.TOGGLE_LOADING:return r(r({},e),{loading:t.toggle});case i.default.GET:return r(r({},e),t.assetList);case i.default.ADD_TAG:for(var l=0,c=e.assets.length;l<c;l++)(n=e.assets[l]).id===t.id?u[l]=r(r({},n),{tags:o(o([],a(n.tags)),a(t.freshTags))}):u[l]=n;return r(r({},e),{assets:u});case i.default.DELETE_TAG:return r(r({},e),{assets:e.assets.map((function(e){return e.id===t.id?r(r({},e),{tags:e.tags.filter((function(e){return e!==t.tag}))}):e}))});case i.default.UPDATE_NAME:return r(r({},e),{assets:e.assets.map((function(e){return e.id===t.id?r(r({},e),{name:t.name}):e}))});case i.default.UPDATE_DATA:return r(r({},e),{assets:e.assets.map((function(e){return e.id===t.id?r(r({},e),{data:t.data}):e}))});default:return e}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(83),a=[];t.default=function(e,t){switch(void 0===e&&(e=a),t.type){case r.default.GET:return t.assetTags;default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},o=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var i=n(52),s={autoTag:!0,assignToStory:!0,uploads:[]};t.default=function(e,t){switch(void 0===e&&(e=s),t.type){case i.default.TOGGLE_AUTO_TAG:return r(r({},e),{autoTag:t.toggle});case i.default.TOGGLE_ASSIGN_TO_STORY:return r(r({},e),{assignToStory:t.toggle});case i.default.ADD_UPLOAD:return r(r({},e),{uploads:o(o([],a(e.uploads)),[t.uploadMeta])});case i.default.UPDATE_PERCENT_UPLOADED:var n=e.uploads.map((function(e){return e.filename===t.filename?r(r({},e),{percent:t.percent}):e}));return r(r({},e),{uploads:n});case i.default.REMOVE_UPLOAD:return r(r({},e),{uploads:e.uploads.filter((function(e){return e.filename!==t.filename}))});default:return e}}},function(e,t,n){"use strict";var r=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},a=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var o=n(33),i=[];t.default=function(e,t){switch(void 0===e&&(e=i),t.type){case o.default.SELECT_ALL:return a([],r(t.allIds));case o.default.SELECT_ASSET:return a(a([],r(e)),[t.id]);case o.default.SELECT_MULTIPLE:return a([],r(new Set(a(a([],r(e)),r(t.assets)))));case o.default.DESELECT_ASSET:return e.filter((function(e){return e!==t.id}));case o.default.RESET_SELECTION:return[];default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)},a=this&&this.__read||function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,a,o=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)i.push(r.value)}catch(e){a={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(a)throw a.error}}return i},o=this&&this.__spreadArray||function(e,t){for(var n=0,r=t.length,a=e.length;n<r;n++,a++)e[a]=t[n];return e};Object.defineProperty(t,"__esModule",{value:!0});var i=n(88),s={loading:!0,updating:!1,associationOptions:{},page:1,data:{}},u={name:"New Column",type:"Static",from_import:1,detail:null};t.default=function(e,t){var n,l;switch(void 0===e&&(e=s),t.type){case i.default.TOGGlE_LOADING:return r(r({},e),{loading:t.toggle});case i.default.TOGGLE_UPDATING:return r(r({},e),{updating:t.toggle});case i.default.ADD_COLUMN:return void 0!==t.columnData?r(r({},e),{data:r(r({},e.data),{columns:o(o([],a(e.data.columns)),[t.columnData])})}):(l=(n=function(e){return e.data.columns.filter((function(e){return e.name.includes(u.name)})).length}(e))?r(r({},u),{name:u.name+" ("+n+")"}):r({},u),r(r({},e),{data:r(r({},e.data),{columns:o(o([],a(e.data.columns)),[l])})}));case i.default.REPLACE_ASSOCIATION_OPTIONS:return r(r({},e),{associationOptions:r({},t.associationOptions)});case i.default.UPDATE_ASSOCIATION:return r(r({},e),{data:r(r({},e.data),{columns:e.data.columns.map((function(e,n){return t.colIndex===n?"Static"===t.newType?r(r({},e),{type:t.newType,detail:null}):r(r({},e),{type:t.newType,detail:t.newAssociation,from_import:"EGC"===t.newType?0:1}):e}))})});case i.default.SET_BATCH:return r(r({},e),{data:r({},t.batch)});case i.default.SET_PAGE:return r(r({},e),{page:t.page});default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var a in t=arguments[n])Object.prototype.hasOwnProperty.call(t,a)&&(e[a]=t[a]);return e}).apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0});var a=n(28),o=n(9),i=n(527),s=n(7),u=n(29),l=n(27),c=function(){function e(e,t,n){var c=this;this.pollingInterval=1e3,this.cancelTokenCache={player:void 0,system:void 0},this.cancelTokens={},this.doRequest=function(e,t){return void 0===t&&(t=""),new Promise((function(n,r){c.http(e).then((function(e){t&&c.clearCache(t),n(e.data)})).catch((function(e){!a.default.isCancel(e)&&t&&c.clearCache(t),!e.response||403!==e.response.status&&401!==e.response.status||(alert(s.assets.sessionExpired),l.default.getSession()&&(l.default.removeSession(),u.default.logout())),r(e)}))}))},this.cancelPrevious=function(e){var t=a.default.CancelToken.source();return c.cancelTokenCache[e]&&c.cancelTokenCache[e].cancel(),c.cancelTokenCache[e]=t,t.token},this.clearCache=function(e){c.cancelTokenCache[e]=void 0},this.doAWSRequest=function(e,t){return void 0===t&&(t=""),new Promise((function(t,n){c.awsHttp(e).then((function(e){t(e.data)})).catch((function(e){n(e)}))}))},this.saveStory=function(e,t){return c.doRequest({method:"PATCH",url:"/story/"+e,data:t})},this.newStory=function(e){return c.doRequest({method:"POST",url:"/story",data:e})},this.deleteStory=function(e){return c.doRequest({method:"DELETE",url:"/story/"+e})},this.getStoryStatus=function(e){return c.doRequest({method:"GET",url:"/story/"+e+"/version"})},this.getStoryVersions=function(e){return c.doRequest({method:"GET",url:"/story/"+e+"/versions"})},this.revertVersion=function(e,t){var n={version_id:t};return c.doRequest({method:"POST",url:"/story/"+e+"/version/revert",data:n})},this.getSignedUrl=function(e,t){return c.doRequest({method:"GET",url:"/story/"+e+"/upload-url",params:{filename:t.name,content_type:t.type}})},this.uploadToSignedUrl=function(e,t,n){return c.doAWSRequest({url:e,method:"PUT",data:t,onUploadProgress:n,headers:{"Content-Type":t.type}})},this.checkS3Bucket=function(e){var t="/bucket/"+e;return c.doRequest({method:"GET",url:t})},this.createS3Bucket=function(e,t,n,r){var a="/bucket/"+e,o={region:t,create_distribution:r?1:0,read_only:n?1:0};return c.doRequest({method:"POST",url:a,data:o})},this.processStoryFile=function(e,t,n){var r="/story/"+e+"/file",a={};return t?a.file_key=t:n&&(a.url=n),c.doRequest({method:"POST",url:r,data:a})},this.getAssets=function(e,t,n){void 0===n&&(n=!1);var r="/assets?items_per_page=50&optional_story_id="+t+"&unprocessed="+n,a=function(t){e.hasOwnProperty(t)&&(e[t]&&"tags"!==t&&(r+="&"+t+"="+encodeURIComponent(e[t])),e[t]&&"tags"===t&&e[t].split(",").forEach((function(e,n){r+="&"+t+"["+n+"]="+encodeURIComponent(e)})))};for(var o in e)a(o);return c.doRequest({method:"GET",url:r})},this.getAssetItem=function(e){return c.doRequest({method:"GET",url:"/assets/"+e})},this.duplicateAsset=function(e,t){return c.doRequest({method:"POST",url:"/assets/"+e+"/copy",data:{name:t}})},this.cancelRequest=function(e){var t=a.default.CancelToken.source();return c.cancelTokens[e]=t,t.token},this.clearCancelTokes=function(){c.cancelTokens={}},this.uploadAsset=function(e,t,n,r,a){var o=new FormData,i=c.cancelRequest(a);return e&&o.append("story_id",e),o.append("tags",t),o.append("file",n),c.doRequest({method:"POST",url:"/assets",data:o,onUploadProgress:r,cancelToken:i})},this.cancelUploadAssets=function(e){var t=c.cancelTokens[e];t&&t.cancel()},this.createCompositionAsset=function(e,t,n){var r=new FormData;return r.append("story_id",e),r.append("data",t),r.append("type","video_composition"),r.append("name",n||"New Composition"),c.doRequest({method:"POST",url:"/assets",data:r})},this.createStaticCompositionAsset=function(e,t){var n=new FormData;return n.append("story_id",e),n.append("data",t),n.append("type","static_composition"),n.append("name","New Template"),c.doRequest({method:"POST",url:"/assets",data:n})},this.deleteAsset=function(e){return c.doRequest({method:"DELETE",url:"/assets/"+e})},this.deleteAssets=function(e){return c.doRequest({method:"DELETE",url:"/assets",data:{ids:e}})},this.copyAsset=function(e,t){return c.doRequest({method:"POST",url:"/assets/"+e+"/copy",data:t})},this.addAssetTag=function(e,t){return c.doRequest({method:"POST",url:"/assets/"+e+"/tag",data:{tag:t}})},this.addAssetTags=function(e,t){return c.doRequest({method:"POST",url:"/assets/"+e+"/tags",data:{tags:t}})},this.deleteAssetTag=function(e,t){return c.doRequest({method:"DELETE",url:"/assets/"+e+"/tag",data:{tag:t}})},this.updateAsset=function(e,t){return c.doRequest({method:"PATCH",url:"/assets/"+e,data:t})},this.getAssetTags=function(e){return c.doRequest({method:"GET",url:"/assets/tags?story_id="+e})},this.getStory=function(e){return c.doRequest({method:"GET",url:"/story/"+e})},this.getExperiences=function(e,t){return c.doRequest({method:"GET",url:"/story/"+e+"/experiences",params:t})},this.exportExperiences=function(e,t){return c.doRequest({method:"GET",url:"/story/"+e+"/experiences/export",params:t})},this.blockByExperience=function(e){var t="/experience/"+e+"/block";return c.doRequest({method:"POST",url:t})},this.getBatches=function(e,t){return c.doRequest({method:"GET",url:"/story/"+e+"/batches",params:t})},this.getBatch=function(e,t){return c.doRequest({method:"GET",url:"/batch/"+e,params:{page:t}})},this.getBatchProgress=function(e){return c.doRequest({method:"GET",url:"/batch/"+e+"/progress"})},this.createFreshBatch=function(e,t){return c.doRequest({method:"POST",url:"/batch",data:{story_id:e,name:t}})},this.updateBatchName=function(e,t){return c.doRequest({method:"PATCH",url:"/batch/"+e+"/rename",data:{name:t}})},this.importBatchDataFromCsv=function(e,t,n,r,a,o){void 0===n&&(n=!1),void 0===r&&(r=null),void 0===a&&(a=null),void 0===o&&(o=!1);var i=new FormData;return i.append("file_key",t),n&&r&&a&&(i.append("include_email_embed","true"),i.append("composition_id",a),i.append("access_key",r)),o&&i.append("include_media","true"),c.doRequest({method:"POST",url:"/batch/"+e+"/data/from-csv",data:i})},this.updateBatchColumns=function(e,t){return c.doRequest({method:"PUT",url:"/batch/"+e+"/columns",data:t})},this.insertNewRow=function(e,t){return c.doRequest({method:"POST",url:"/batch/"+e+"/row/"+t})},this.updateCellValue=function(e,t,n,r){return c.doRequest({method:"PUT",url:"/batch/"+e+"/cell",data:{column_index:t,row_index:n,value:r}})},this.prepareBatchForRender=function(e){return c.doRequest({method:"POST",url:"/batch/"+e+"/prepare"})},this.checkBatchExportStatus=function(e){return c.doRequest({method:"GET",url:"/batch/"+e+"/export"})},this.invokeBatchExportJob=function(e){return c.doRequest({method:"POST",url:"/batch/"+e+"/export"})},this.downloadBatchExport=function(e,t){return c.doRequest({method:"GET",url:"/batch/"+e+"/export/"+t,responseType:"blob",params:{preserve:"true"}})},this.duplicateBatch=function(e){return c.doRequest({method:"POST",url:"/batch/"+e+"/duplicate"})},this.deleteBatch=function(e){return c.doRequest({method:"DELETE",url:"/batch/"+e})},this.updateModerationStatus=function(e,t,n){return c.doRequest({method:"POST",url:"/experience/"+e+"/status",data:{status:t,reason:n}})},this.addOrReplaceNote=function(e,t){return c.doRequest({method:"POST",url:"/experience/"+e+"/notes",data:{notes:t}})},this.getJob=function(e){return c.doRequest({method:"GET",url:"/job/"+e})},this.runCut=function(e,t,n,r){var a="/job/"+i.JOB_TYPES.RUN_CUT,o={story_id:e,act_id:t,scene_id:n,cut_id:r};return c.doRequest({method:"POST",url:a,data:o})},this.runReRenderCuts=function(e,t,n){var r="/job/"+i.JOB_TYPES.RE_RUN_CUTS,a={story_id:e,act_id:t,scene_id:n};return c.doRequest({method:"POST",url:r,data:a})},this.runProcessBaseVideo=function(e,t){var n="/job/"+i.JOB_TYPES.PROCESS_BASE_VIDEO,r={story_id:e,file_key:t};return c.doRequest({method:"POST",url:n,data:r})},this.runPublish=function(e,t){var n={story_id:e,message:t};return c.doRequest({method:"POST",url:"/job/publish",data:n})},this.cancelPublish=function(e){var t={story_id:e};return c.doRequest({method:"DELETE",url:"/job/publish",data:t})},this.pollJob=function(e){var t={method:"GET",url:"/job/"+e};return new Promise((function(e,n){c.pollForJob(t,e,n)}))},this.pollForJob=function(e,t,n){c.http(e).then((function(r){"failed"===r.data.status?n(r):void 0!==r.data.output?t(r.data):c.jobPollTimer=setTimeout((function(){c.pollForJob(e,t,n)}),c.pollingInterval)})).catch((function(e){n(e)}))},this.pollForExperience=function(e,t,n){c.http(e).then((function(r){"failed"===r.data.status?n(r):!1===r.data.rendering&&void 0!==r.data.error?n(r.data):void 0!==r.data.output?o.isObjEmpty(r.data.output)?c.experiencePollTimer=setTimeout((function(){c.pollForExperience(e,t,n)}),c.pollingInterval):t(r.data):c.experiencePollTimer=setTimeout((function(){c.pollForExperience(e,t,n)}),c.pollingInterval)})).catch((function(e){n(e)}))},this.getJobLogUrl=function(e){var t="/job/"+e+"/log-url";return c.doRequest({method:"GET",url:t})},this.getJobLog=function(e){return c.doAWSRequest({method:"GET",url:e})},this.createExperience=function(e,t,n,r){void 0===t&&(t={});var a=c.experienceFormData(e,t,n);r&&a.append("published","false");return c.doRequest({method:"POST",url:"/experience",data:a})},this.deleteExperience=function(e,t){void 0===t&&(t=!0);var n="/experience/"+e,r={erase_media:t};return c.doRequest({method:"DELETE",data:r,url:n})},this.triggerEvent=function(e,t,n){var r="/experience/"+e+"/trigger-event";if(t){var a=new FormData;return a.append("composition_id",t),n&&a.append("published","false"),c.doRequest({method:"POST",url:r,data:a})}return c.doRequest({method:"POST",url:r})},this.getExperience=function(e,t){void 0===t&&(t=!1);var n={method:"GET",url:"/experience/"+e};return t?new Promise((function(e,t){c.pollForExperience(n,e,t)})):c.doRequest(n)},this.experienceFormData=function(e,t,n){var a=r({},t),o=new FormData;for(var i in o.append("story_id",e),n&&o.append("composition_id",n),a)if(a[i]){var s=a[i];if(s&&"file"===s.type){var u=s.files;u.length>0?(a[i]="",o.append(i,u[0])):a[i]=""}else s&&s instanceof File&&(a[i]="",o.append(i,s,s.name));o.append("inventory["+i+"]",a[i])}return o},this.getAccssCredentials=function(){return c.doRequest({method:"GET",url:"/api-key"})},this.createAccessCredentials=function(e){var t={name:e};return c.doRequest({method:"POST",data:t,url:"/api-key"})},this.deleteAccessCrednetials=function(e){var t={access_key_id:e};return c.doRequest({method:"DELETE",data:t,url:"/api-key"})},this.invokeBatchRenderJob=function(e){return c.doRequest({method:"POST",url:"/job/render-batch",data:{batch_id:e}})},this.cancelBatchRenderJob=function(e){return c.doRequest({method:"POST",url:"/batch/"+e+"/cancel"})},this.getUsers=function(e,t,n){return c.doRequest({url:"/account/"+e+"/users?page="+t+"&items_per_page="+n,method:"GET"})},this.addUser=function(e,t,n){return c.doRequest({url:"/account/"+e+"/grant",method:"POST",data:{email:t,role_id:n}})},this.resendInvite=function(e,t){return c.doRequest({url:"/account/"+e+"/resend",method:"POST",data:{email:t}})},this.revokeInvite=function(e,t){return c.doRequest({url:"/account/"+e+"/revoke",method:"POST",data:{email:t}})},this.updateInviteRole=function(e,t,n){return c.doRequest({url:"/account/"+e+"/grant",method:"PATCH",data:{email:t,role_id:n}})},this.updateRole=function(e,t,n){return c.doRequest({url:"/account/"+e+"/user",method:"PATCH",data:{user_id:t,role_id:n}})},this.deleteUser=function(e,t){return c.doRequest({url:"/account/"+e+"/user",method:"DELETE",data:{user_id:t}})},this.getPlayerMetrics=function(e,t,n,r){void 0===r&&(r="player");var a={method:"GET",url:"/metrics/player/"+e,params:{start:t,end:n},cancelToken:c.cancelPrevious(r)};return c.doRequest(a,r)},this.getSystemMetrics=function(e,t,n,r,a){void 0===a&&(a="system");var o={method:"GET",url:"/metrics/system/"+e,params:{start:t,end:n,step:r},cancelToken:c.cancelPrevious(a)};return c.doRequest(o,a)},this.getOrganizations=function(e,t){return c.doRequest({url:"/account",method:"GET",params:{page:e,items_per_page:t}})},this.addOrganization=function(e,t){return c.doRequest({url:"/account",method:"POST",data:{name:e,initial_story:t}})},this.updateOrgName=function(e,t){return c.doRequest({url:"/account/"+e,method:"PATCH",data:{name:t}})},this.deleteOrg=function(e){},this.changeOrgPlan=function(e,t){return c.doRequest({url:"/account/"+e,method:"PATCH",data:{tier:t}})},this.getAccountInfo=function(e){return c.doRequest({url:"/account/"+e,method:"GET"})},this.cancelOrgPlan=function(e){return c.doRequest({url:"/account/"+e,method:"PATCH",data:{cancel:!0}})},this.getNextBillingPeriod=function(e){return c.doRequest({url:"/account/"+e+"/next-payment",method:"GET"})},this.getRedirectToBillingPortal=function(e){return c.doRequest({url:"/account/"+e+"/billing-portal",method:"GET"})},this.getRedirectToRenew=function(e,t){return c.doRequest({url:"/account/"+e+"/renew?tier="+t,method:"GET"})},this.getAPIUsageOverview=function(e,t){var n=e&&t?"?start="+e+"&end="+t:"";return c.doRequest({url:"/usage"+n,method:"GET"})},this.getUsageGraph=function(e,t,n){var r=t&&n?"?start="+t+"&end="+n:"";return c.doRequest({url:"/usage/daily/"+e+r,method:"GET"})},this.getBillingPeriods=function(){return c.doRequest({url:"/usage/billing-periods",method:"GET"})},this.http=n?a.default.create({baseURL:e,headers:{Authorization:"Bearer "+t,"X-Imposium-API-Version":"2.0.0","X-Imposium-Account-Id":n||""}}):a.default.create({baseURL:e,headers:{"X-Imposium-Access-Key":""+t,"X-Imposium-API-Version":"2.0.0"}}),this.awsHttp=a.default.create()}return e.prototype.cancelExperiencePolling=function(){var e=this;return new Promise((function(t){clearTimeout(e.experiencePollTimer),t()}))},e.prototype.cancelJobPolling=function(){var e=this;return new Promise((function(t){clearTimeout(e.jobPollTimer),t()}))},e}();t.default=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.JOB_TYPES=void 0,t.JOB_TYPES={RUN_CUT:"make-cut",PROCESS_BASE_VIDEO:"process-base-video",RE_RUN_CUTS:"recut-scene"}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(28),a=function(e){var t=this;this.doRequest=function(e){return new Promise((function(n,r){t.http(e).then((function(e){n(e.data)})).catch((function(e){r(e)}))}))},this.updateModerationStatus=function(e,n,r){return t.doRequest({method:"POST",url:"/",data:{task:"update-experience-status",experience_id:e,status:n,reason:r}})},this.addOrReplaceNote=function(e,n){return t.doRequest({method:"POST",url:"/",data:{task:"update-experience-notes",experience_id:e,notes:n}})},this.http=r.default.create({baseURL:e+"/1.1"})};t.default=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(530),a=function(){function e(){}return e.setItem=function(e,t){return new Promise((function(n,a){r.setItem(e,t).then((function(){return n(null)})).catch((function(e){console.error("Failed to store key value pair:",e),a(e)}))}))},e.getItem=function(e){return new Promise((function(t,n){r.getItem(e).then((function(e){t(e)})).catch((function(e){console.error("Failed to look up value for key:",e),n(e)}))}))},e}();t.default=a},function(e,t){e.exports=h},function(e,t,n){"use strict";n.r(t),n.d(t,"AlphaPicker",(function(){return Gn})),n.d(t,"BlockPicker",(function(){return la})),n.d(t,"CirclePicker",(function(){return Ya})),n.d(t,"default",(function(){return za})),n.d(t,"ChromePicker",(function(){return za})),n.d(t,"CompactPicker",(function(){return Va})),n.d(t,"GithubPicker",(function(){return Ja})),n.d(t,"HuePicker",(function(){return Za})),n.d(t,"MaterialPicker",(function(){return Qa})),n.d(t,"PhotoshopPicker",(function(){return so})),n.d(t,"SketchPicker",(function(){return mo})),n.d(t,"SliderPicker",(function(){return bo})),n.d(t,"SwatchesPicker",(function(){return xo})),n.d(t,"TwitterPicker",(function(){return So})),n.d(t,"GooglePicker",(function(){return Po})),n.d(t,"CustomPicker",(function(){return Pn}));var r=n(0),a=n.n(r),o=n(3),i=n.n(o),s=function(e,t,n,r,a){var o=a.clientWidth,i=a.clientHeight,s="number"==typeof e.pageX?e.pageX:e.touches[0].pageX,u="number"==typeof e.pageY?e.pageY:e.touches[0].pageY,l=s-(a.getBoundingClientRect().left+window.pageXOffset),c=u-(a.getBoundingClientRect().top+window.pageYOffset);if("vertical"===n){var d=void 0;if(d=c<0?0:c>i?1:Math.round(100*c/i)/100,t.a!==d)return{h:t.h,s:t.s,l:t.l,a:d,source:"rgb"}}else{var p=void 0;if(r!==(p=l<0?0:l>o?1:Math.round(100*l/o)/100))return{h:t.h,s:t.s,l:t.l,a:p,source:"rgb"}}return null},u={},l=function(e,t,n,r){var a=e+"-"+t+"-"+n+(r?"-server":"");if(u[a])return u[a];var o=function(e,t,n,r){if("undefined"==typeof document&&!r)return null;var a=r?new r:document.createElement("canvas");a.width=2*n,a.height=2*n;var o=a.getContext("2d");return o?(o.fillStyle=e,o.fillRect(0,0,a.width,a.height),o.fillStyle=t,o.fillRect(0,0,n,n),o.translate(n,n),o.fillRect(0,0,n,n),a.toDataURL()):null}(e,t,n,r);return u[a]=o,o},c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},d=function(e){var t=e.white,n=e.grey,o=e.size,s=e.renderers,u=e.borderRadius,d=e.boxShadow,p=e.children,f=i()({default:{grid:{borderRadius:u,boxShadow:d,absolute:"0px 0px 0px 0px",background:"url("+l(t,n,o,s.canvas)+") center left"}}});return Object(r.isValidElement)(p)?a.a.cloneElement(p,c({},p.props,{style:c({},p.props.style,f.grid)})):a.a.createElement("div",{style:f.grid})};d.defaultProps={size:8,white:"transparent",grey:"rgba(0,0,0,.08)",renderers:{}};var p=d,f=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},h=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function m(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function _(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var y=function(e){function t(){var e,n,r;m(this,t);for(var a=arguments.length,o=Array(a),i=0;i<a;i++)o[i]=arguments[i];return n=r=_(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this].concat(o))),r.handleChange=function(e){var t=s(e,r.props.hsl,r.props.direction,r.props.a,r.container);t&&"function"==typeof r.props.onChange&&r.props.onChange(t,e)},r.handleMouseDown=function(e){r.handleChange(e),window.addEventListener("mousemove",r.handleChange),window.addEventListener("mouseup",r.handleMouseUp)},r.handleMouseUp=function(){r.unbindEventListeners()},r.unbindEventListeners=function(){window.removeEventListener("mousemove",r.handleChange),window.removeEventListener("mouseup",r.handleMouseUp)},_(r,n)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),h(t,[{key:"componentWillUnmount",value:function(){this.unbindEventListeners()}},{key:"render",value:function(){var e=this,t=this.props.rgb,n=i()({default:{alpha:{absolute:"0px 0px 0px 0px",borderRadius:this.props.radius},checkboard:{absolute:"0px 0px 0px 0px",overflow:"hidden",borderRadius:this.props.radius},gradient:{absolute:"0px 0px 0px 0px",background:"linear-gradient(to right, rgba("+t.r+","+t.g+","+t.b+", 0) 0%,\n rgba("+t.r+","+t.g+","+t.b+", 1) 100%)",boxShadow:this.props.shadow,borderRadius:this.props.radius},container:{position:"relative",height:"100%",margin:"0 3px"},pointer:{position:"absolute",left:100*t.a+"%"},slider:{width:"4px",borderRadius:"1px",height:"8px",boxShadow:"0 0 2px rgba(0, 0, 0, .6)",background:"#fff",marginTop:"1px",transform:"translateX(-2px)"}},vertical:{gradient:{background:"linear-gradient(to bottom, rgba("+t.r+","+t.g+","+t.b+", 0) 0%,\n rgba("+t.r+","+t.g+","+t.b+", 1) 100%)"},pointer:{left:0,top:100*t.a+"%"}},overwrite:f({},this.props.style)},{vertical:"vertical"===this.props.direction,overwrite:!0});return a.a.createElement("div",{style:n.alpha},a.a.createElement("div",{style:n.checkboard},a.a.createElement(p,{renderers:this.props.renderers})),a.a.createElement("div",{style:n.gradient}),a.a.createElement("div",{style:n.container,ref:function(t){return e.container=t},onMouseDown:this.handleMouseDown,onTouchMove:this.handleChange,onTouchStart:this.handleChange},a.a.createElement("div",{style:n.pointer},this.props.pointer?a.a.createElement(this.props.pointer,this.props):a.a.createElement("div",{style:n.slider}))))}}]),t}(r.PureComponent||r.Component),g=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var v=[38,40],b=1,w=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return n.handleBlur=function(){n.state.blurValue&&n.setState({value:n.state.blurValue,blurValue:null})},n.handleChange=function(e){n.setUpdatedValue(e.target.value,e)},n.handleKeyDown=function(e){var t,r=function(e){return Number(String(e).replace(/%/g,""))}(e.target.value);if(!isNaN(r)&&(t=e.keyCode,v.indexOf(t)>-1)){var a=n.getArrowOffset(),o=38===e.keyCode?r+a:r-a;n.setUpdatedValue(o,e)}},n.handleDrag=function(e){if(n.props.dragLabel){var t=Math.round(n.props.value+e.movementX);t>=0&&t<=n.props.dragMax&&n.props.onChange&&n.props.onChange(n.getValueObjectWithLabel(t),e)}},n.handleMouseDown=function(e){n.props.dragLabel&&(e.preventDefault(),n.handleDrag(e),window.addEventListener("mousemove",n.handleDrag),window.addEventListener("mouseup",n.handleMouseUp))},n.handleMouseUp=function(){n.unbindEventListeners()},n.unbindEventListeners=function(){window.removeEventListener("mousemove",n.handleDrag),window.removeEventListener("mouseup",n.handleMouseUp)},n.state={value:String(e.value).toUpperCase(),blurValue:String(e.value).toUpperCase()},n.inputId="rc-editable-input-"+b++,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),g(t,[{key:"componentDidUpdate",value:function(e,t){this.props.value===this.state.value||e.value===this.props.value&&t.value===this.state.value||(this.input===document.activeElement?this.setState({blurValue:String(this.props.value).toUpperCase()}):this.setState({value:String(this.props.value).toUpperCase(),blurValue:!this.state.blurValue&&String(this.props.value).toUpperCase()}))}},{key:"componentWillUnmount",value:function(){this.unbindEventListeners()}},{key:"getValueObjectWithLabel",value:function(e){return function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}({},this.props.label,e)}},{key:"getArrowOffset",value:function(){return this.props.arrowOffset||1}},{key:"setUpdatedValue",value:function(e,t){var n=this.props.label?this.getValueObjectWithLabel(e):e;this.props.onChange&&this.props.onChange(n,t),this.setState({value:e})}},{key:"render",value:function(){var e=this,t=i()({default:{wrap:{position:"relative"}},"user-override":{wrap:this.props.style&&this.props.style.wrap?this.props.style.wrap:{},input:this.props.style&&this.props.style.input?this.props.style.input:{},label:this.props.style&&this.props.style.label?this.props.style.label:{}},"dragLabel-true":{label:{cursor:"ew-resize"}}},{"user-override":!0},this.props);return a.a.createElement("div",{style:t.wrap},a.a.createElement("input",{id:this.inputId,style:t.input,ref:function(t){return e.input=t},value:this.state.value,onKeyDown:this.handleKeyDown,onChange:this.handleChange,onBlur:this.handleBlur,placeholder:this.props.placeholder,spellCheck:"false"}),this.props.label&&!this.props.hideLabel?a.a.createElement("label",{htmlFor:this.inputId,style:t.label,onMouseDown:this.handleMouseDown},this.props.label):null)}}]),t}(r.PureComponent||r.Component),M=function(e,t,n,r){var a=r.clientWidth,o=r.clientHeight,i="number"==typeof e.pageX?e.pageX:e.touches[0].pageX,s="number"==typeof e.pageY?e.pageY:e.touches[0].pageY,u=i-(r.getBoundingClientRect().left+window.pageXOffset),l=s-(r.getBoundingClientRect().top+window.pageYOffset);if("vertical"===t){var c=void 0;if(l<0)c=359;else if(l>o)c=0;else{c=360*(-100*l/o+100)/100}if(n.h!==c)return{h:c,s:n.s,l:n.l,a:n.a,source:"hsl"}}else{var d=void 0;if(u<0)d=0;else if(u>a)d=359;else{d=360*(100*u/a)/100}if(n.h!==d)return{h:d,s:n.s,l:n.l,a:n.a,source:"hsl"}}return null},L=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function T(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function k(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var x=function(e){function t(){var e,n,r;T(this,t);for(var a=arguments.length,o=Array(a),i=0;i<a;i++)o[i]=arguments[i];return n=r=k(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this].concat(o))),r.handleChange=function(e){var t=M(e,r.props.direction,r.props.hsl,r.container);t&&"function"==typeof r.props.onChange&&r.props.onChange(t,e)},r.handleMouseDown=function(e){r.handleChange(e),window.addEventListener("mousemove",r.handleChange),window.addEventListener("mouseup",r.handleMouseUp)},r.handleMouseUp=function(){r.unbindEventListeners()},k(r,n)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),L(t,[{key:"componentWillUnmount",value:function(){this.unbindEventListeners()}},{key:"unbindEventListeners",value:function(){window.removeEventListener("mousemove",this.handleChange),window.removeEventListener("mouseup",this.handleMouseUp)}},{key:"render",value:function(){var e=this,t=this.props.direction,n=void 0===t?"horizontal":t,r=i()({default:{hue:{absolute:"0px 0px 0px 0px",borderRadius:this.props.radius,boxShadow:this.props.shadow},container:{padding:"0 2px",position:"relative",height:"100%",borderRadius:this.props.radius},pointer:{position:"absolute",left:100*this.props.hsl.h/360+"%"},slider:{marginTop:"1px",width:"4px",borderRadius:"1px",height:"8px",boxShadow:"0 0 2px rgba(0, 0, 0, .6)",background:"#fff",transform:"translateX(-2px)"}},vertical:{pointer:{left:"0px",top:-100*this.props.hsl.h/360+100+"%"}}},{vertical:"vertical"===n});return a.a.createElement("div",{style:r.hue},a.a.createElement("div",{className:"hue-"+n,style:r.container,ref:function(t){return e.container=t},onMouseDown:this.handleMouseDown,onTouchMove:this.handleChange,onTouchStart:this.handleChange},a.a.createElement("style",null,"\n .hue-horizontal {\n background: linear-gradient(to right, #f00 0%, #ff0 17%, #0f0\n 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);\n background: -webkit-linear-gradient(to right, #f00 0%, #ff0\n 17%, #0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);\n }\n\n .hue-vertical {\n background: linear-gradient(to top, #f00 0%, #ff0 17%, #0f0 33%,\n #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);\n background: -webkit-linear-gradient(to top, #f00 0%, #ff0 17%,\n #0f0 33%, #0ff 50%, #00f 67%, #f0f 83%, #f00 100%);\n }\n "),a.a.createElement("div",{style:r.pointer},this.props.pointer?a.a.createElement(this.props.pointer,this.props):a.a.createElement("div",{style:r.slider}))))}}]),t}(r.PureComponent||r.Component),E=n(2),S=n.n(E);var O=function(){this.__data__=[],this.size=0};var D=function(e,t){return e===t||e!=e&&t!=t};var Y=function(e,t){for(var n=e.length;n--;)if(D(e[n][0],t))return n;return-1},A=Array.prototype.splice;var C=function(e){var t=this.__data__,n=Y(t,e);return!(n<0)&&(n==t.length-1?t.pop():A.call(t,n,1),--this.size,!0)};var j=function(e){var t=this.__data__,n=Y(t,e);return n<0?void 0:t[n][1]};var P=function(e){return Y(this.__data__,e)>-1};var H=function(e,t){var n=this.__data__,r=Y(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this};function I(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}I.prototype.clear=O,I.prototype.delete=C,I.prototype.get=j,I.prototype.has=P,I.prototype.set=H;var N=I;var R=function(){this.__data__=new N,this.size=0};var F=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n};var z=function(e){return this.__data__.get(e)};var U=function(e){return this.__data__.has(e)},W=n(6),B=W.a.Symbol,V=Object.prototype,G=V.hasOwnProperty,q=V.toString,J=B?B.toStringTag:void 0;var K=function(e){var t=G.call(e,J),n=e[J];try{e[J]=void 0;var r=!0}catch(e){}var a=q.call(e);return r&&(t?e[J]=n:delete e[J]),a},$=Object.prototype.toString;var X=function(e){return $.call(e)},Z=B?B.toStringTag:void 0;var Q=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Z&&Z in Object(e)?K(e):X(e)};var ee=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)};var te,ne=function(e){if(!ee(e))return!1;var t=Q(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t},re=W.a["__core-js_shared__"],ae=(te=/[^.]+$/.exec(re&&re.keys&&re.keys.IE_PROTO||""))?"Symbol(src)_1."+te:"";var oe=function(e){return!!ae&&ae in e},ie=Function.prototype.toString;var se=function(e){if(null!=e){try{return ie.call(e)}catch(e){}try{return e+""}catch(e){}}return""},ue=/^\[object .+?Constructor\]$/,le=Function.prototype,ce=Object.prototype,de=le.toString,pe=ce.hasOwnProperty,fe=RegExp("^"+de.call(pe).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");var he=function(e){return!(!ee(e)||oe(e))&&(ne(e)?fe:ue).test(se(e))};var me=function(e,t){return null==e?void 0:e[t]};var _e=function(e,t){var n=me(e,t);return he(n)?n:void 0},ye=_e(W.a,"Map"),ge=_e(Object,"create");var ve=function(){this.__data__=ge?ge(null):{},this.size=0};var be=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},we=Object.prototype.hasOwnProperty;var Me=function(e){var t=this.__data__;if(ge){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return we.call(t,e)?t[e]:void 0},Le=Object.prototype.hasOwnProperty;var Te=function(e){var t=this.__data__;return ge?void 0!==t[e]:Le.call(t,e)};var ke=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=ge&&void 0===t?"__lodash_hash_undefined__":t,this};function xe(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}xe.prototype.clear=ve,xe.prototype.delete=be,xe.prototype.get=Me,xe.prototype.has=Te,xe.prototype.set=ke;var Ee=xe;var Se=function(){this.size=0,this.__data__={hash:new Ee,map:new(ye||N),string:new Ee}};var Oe=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e};var De=function(e,t){var n=e.__data__;return Oe(t)?n["string"==typeof t?"string":"hash"]:n.map};var Ye=function(e){var t=De(this,e).delete(e);return this.size-=t?1:0,t};var Ae=function(e){return De(this,e).get(e)};var Ce=function(e){return De(this,e).has(e)};var je=function(e,t){var n=De(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this};function Pe(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Pe.prototype.clear=Se,Pe.prototype.delete=Ye,Pe.prototype.get=Ae,Pe.prototype.has=Ce,Pe.prototype.set=je;var He=Pe;var Ie=function(e,t){var n=this.__data__;if(n instanceof N){var r=n.__data__;if(!ye||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new He(r)}return n.set(e,t),this.size=n.size,this};function Ne(e){var t=this.__data__=new N(e);this.size=t.size}Ne.prototype.clear=R,Ne.prototype.delete=F,Ne.prototype.get=z,Ne.prototype.has=U,Ne.prototype.set=Ie;var Re=Ne,Fe=function(){try{var e=_e(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();var ze=function(e,t,n){"__proto__"==t&&Fe?Fe(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n};var Ue=function(e,t,n){(void 0!==n&&!D(e[t],n)||void 0===n&&!(t in e))&&ze(e,t,n)};var We=function(e){return function(t,n,r){for(var a=-1,o=Object(t),i=r(t),s=i.length;s--;){var u=i[e?s:++a];if(!1===n(o[u],u,o))break}return t}}(),Be=n(275),Ve=W.a.Uint8Array;var Ge=function(e){var t=new e.constructor(e.byteLength);return new Ve(t).set(new Ve(e)),t};var qe=function(e,t){var n=t?Ge(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)};var Je=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t},Ke=Object.create,$e=function(){function e(){}return function(t){if(!ee(t))return{};if(Ke)return Ke(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();var Xe=function(e,t){return function(n){return e(t(n))}},Ze=Xe(Object.getPrototypeOf,Object),Qe=Object.prototype;var et=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||Qe)};var tt=function(e){return"function"!=typeof e.constructor||et(e)?{}:$e(Ze(e))};var nt=function(e){return null!=e&&"object"==typeof e};var rt=function(e){return nt(e)&&"[object Arguments]"==Q(e)},at=Object.prototype,ot=at.hasOwnProperty,it=at.propertyIsEnumerable,st=rt(function(){return arguments}())?rt:function(e){return nt(e)&&ot.call(e,"callee")&&!it.call(e,"callee")},ut=Array.isArray;var lt=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991};var ct=function(e){return null!=e&&lt(e.length)&&!ne(e)};var dt=function(e){return nt(e)&&ct(e)},pt=n(20),ft=Function.prototype,ht=Object.prototype,mt=ft.toString,_t=ht.hasOwnProperty,yt=mt.call(Object);var gt=function(e){if(!nt(e)||"[object Object]"!=Q(e))return!1;var t=Ze(e);if(null===t)return!0;var n=_t.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&mt.call(n)==yt},vt={};vt["[object Float32Array]"]=vt["[object Float64Array]"]=vt["[object Int8Array]"]=vt["[object Int16Array]"]=vt["[object Int32Array]"]=vt["[object Uint8Array]"]=vt["[object Uint8ClampedArray]"]=vt["[object Uint16Array]"]=vt["[object Uint32Array]"]=!0,vt["[object Arguments]"]=vt["[object Array]"]=vt["[object ArrayBuffer]"]=vt["[object Boolean]"]=vt["[object DataView]"]=vt["[object Date]"]=vt["[object Error]"]=vt["[object Function]"]=vt["[object Map]"]=vt["[object Number]"]=vt["[object Object]"]=vt["[object RegExp]"]=vt["[object Set]"]=vt["[object String]"]=vt["[object WeakMap]"]=!1;var bt=function(e){return nt(e)&&lt(e.length)&&!!vt[Q(e)]};var wt=function(e){return function(t){return e(t)}},Mt=n(89),Lt=Mt.a&&Mt.a.isTypedArray,Tt=Lt?wt(Lt):bt;var kt=function(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]},xt=Object.prototype.hasOwnProperty;var Et=function(e,t,n){var r=e[t];xt.call(e,t)&&D(r,n)&&(void 0!==n||t in e)||ze(e,t,n)};var St=function(e,t,n,r){var a=!n;n||(n={});for(var o=-1,i=t.length;++o<i;){var s=t[o],u=r?r(n[s],e[s],s,n,e):void 0;void 0===u&&(u=e[s]),a?ze(n,s,u):Et(n,s,u)}return n};var Ot=function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r},Dt=/^(?:0|[1-9]\d*)$/;var Yt=function(e,t){var n=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==n||"symbol"!=n&&Dt.test(e))&&e>-1&&e%1==0&&e<t},At=Object.prototype.hasOwnProperty;var Ct=function(e,t){var n=ut(e),r=!n&&st(e),a=!n&&!r&&Object(pt.a)(e),o=!n&&!r&&!a&&Tt(e),i=n||r||a||o,s=i?Ot(e.length,String):[],u=s.length;for(var l in e)!t&&!At.call(e,l)||i&&("length"==l||a&&("offset"==l||"parent"==l)||o&&("buffer"==l||"byteLength"==l||"byteOffset"==l)||Yt(l,u))||s.push(l);return s};var jt=function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t},Pt=Object.prototype.hasOwnProperty;var Ht=function(e){if(!ee(e))return jt(e);var t=et(e),n=[];for(var r in e)("constructor"!=r||!t&&Pt.call(e,r))&&n.push(r);return n};var It=function(e){return ct(e)?Ct(e,!0):Ht(e)};var Nt=function(e){return St(e,It(e))};var Rt=function(e,t,n,r,a,o,i){var s=kt(e,n),u=kt(t,n),l=i.get(u);if(l)Ue(e,n,l);else{var c=o?o(s,u,n+"",e,t,i):void 0,d=void 0===c;if(d){var p=ut(u),f=!p&&Object(pt.a)(u),h=!p&&!f&&Tt(u);c=u,p||f||h?ut(s)?c=s:dt(s)?c=Je(s):f?(d=!1,c=Object(Be.a)(u,!0)):h?(d=!1,c=qe(u,!0)):c=[]:gt(u)||st(u)?(c=s,st(s)?c=Nt(s):ee(s)&&!ne(s)||(c=tt(u))):d=!1}d&&(i.set(u,c),a(c,u,r,o,i),i.delete(u)),Ue(e,n,c)}};var Ft=function e(t,n,r,a,o){t!==n&&We(n,(function(i,s){if(o||(o=new Re),ee(i))Rt(t,n,s,r,e,a,o);else{var u=a?a(kt(t,s),i,s+"",t,n,o):void 0;void 0===u&&(u=i),Ue(t,s,u)}}),It)};var zt=function(e){return e};var Ut=function(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)},Wt=Math.max;var Bt=function(e,t,n){return t=Wt(void 0===t?e.length-1:t,0),function(){for(var r=arguments,a=-1,o=Wt(r.length-t,0),i=Array(o);++a<o;)i[a]=r[t+a];a=-1;for(var s=Array(t+1);++a<t;)s[a]=r[a];return s[t]=n(i),Ut(e,this,s)}};var Vt=function(e){return function(){return e}},Gt=Fe?function(e,t){return Fe(e,"toString",{configurable:!0,enumerable:!1,value:Vt(t),writable:!0})}:zt,qt=Date.now;var Jt=function(e){var t=0,n=0;return function(){var r=qt(),a=16-(r-n);if(n=r,a>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}(Gt);var Kt=function(e,t){return Jt(Bt(e,t,zt),e+"")};var $t=function(e,t,n){if(!ee(n))return!1;var r=typeof t;return!!("number"==r?ct(n)&&Yt(t,n.length):"string"==r&&t in n)&&D(n[t],e)};var Xt=function(e){return Kt((function(t,n){var r=-1,a=n.length,o=a>1?n[a-1]:void 0,i=a>2?n[2]:void 0;for(o=e.length>3&&"function"==typeof o?(a--,o):void 0,i&&$t(n[0],n[1],i)&&(o=a<3?void 0:o,a=1),t=Object(t);++r<a;){var s=n[r];s&&e(t,s,r,o)}return t}))}((function(e,t,n){Ft(e,t,n)})),Zt=function(e){var t=e.zDepth,n=e.radius,r=e.background,o=e.children,s=e.styles,u=void 0===s?{}:s,l=i()(Xt({default:{wrap:{position:"relative",display:"inline-block"},content:{position:"relative"},bg:{absolute:"0px 0px 0px 0px",boxShadow:"0 "+t+"px "+4*t+"px rgba(0,0,0,.24)",borderRadius:n,background:r}},"zDepth-0":{bg:{boxShadow:"none"}},"zDepth-1":{bg:{boxShadow:"0 2px 10px rgba(0,0,0,.12), 0 2px 5px rgba(0,0,0,.16)"}},"zDepth-2":{bg:{boxShadow:"0 6px 20px rgba(0,0,0,.19), 0 8px 17px rgba(0,0,0,.2)"}},"zDepth-3":{bg:{boxShadow:"0 17px 50px rgba(0,0,0,.19), 0 12px 15px rgba(0,0,0,.24)"}},"zDepth-4":{bg:{boxShadow:"0 25px 55px rgba(0,0,0,.21), 0 16px 28px rgba(0,0,0,.22)"}},"zDepth-5":{bg:{boxShadow:"0 40px 77px rgba(0,0,0,.22), 0 27px 24px rgba(0,0,0,.2)"}},square:{bg:{borderRadius:"0"}},circle:{bg:{borderRadius:"50%"}}},u),{"zDepth-1":1===t});return a.a.createElement("div",{style:l.wrap},a.a.createElement("div",{style:l.bg}),a.a.createElement("div",{style:l.content},o))};Zt.propTypes={background:S.a.string,zDepth:S.a.oneOf([0,1,2,3,4,5]),radius:S.a.number,styles:S.a.object},Zt.defaultProps={background:"#fff",zDepth:1,radius:2,styles:{}};var Qt=Zt,en=function(){return W.a.Date.now()},tn=/\s/;var nn=function(e){for(var t=e.length;t--&&tn.test(e.charAt(t)););return t},rn=/^\s+/;var an=function(e){return e?e.slice(0,nn(e)+1).replace(rn,""):e};var on=function(e){return"symbol"==typeof e||nt(e)&&"[object Symbol]"==Q(e)},sn=/^[-+]0x[0-9a-f]+$/i,un=/^0b[01]+$/i,ln=/^0o[0-7]+$/i,cn=parseInt;var dn=function(e){if("number"==typeof e)return e;if(on(e))return NaN;if(ee(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=ee(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=an(e);var n=un.test(e);return n||ln.test(e)?cn(e.slice(2),n?2:8):sn.test(e)?NaN:+e},pn=Math.max,fn=Math.min;var hn=function(e,t,n){var r,a,o,i,s,u,l=0,c=!1,d=!1,p=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function f(t){var n=r,o=a;return r=a=void 0,l=t,i=e.apply(o,n)}function h(e){return l=e,s=setTimeout(_,t),c?f(e):i}function m(e){var n=e-u;return void 0===u||n>=t||n<0||d&&e-l>=o}function _(){var e=en();if(m(e))return y(e);s=setTimeout(_,function(e){var n=t-(e-u);return d?fn(n,o-(e-l)):n}(e))}function y(e){return s=void 0,p&&r?f(e):(r=a=void 0,i)}function g(){var e=en(),n=m(e);if(r=arguments,a=this,u=e,n){if(void 0===s)return h(u);if(d)return clearTimeout(s),s=setTimeout(_,t),f(u)}return void 0===s&&(s=setTimeout(_,t)),i}return t=dn(t)||0,ee(n)&&(c=!!n.leading,o=(d="maxWait"in n)?pn(dn(n.maxWait)||0,t):o,p="trailing"in n?!!n.trailing:p),g.cancel=function(){void 0!==s&&clearTimeout(s),l=0,r=u=a=s=void 0},g.flush=function(){return void 0===s?i:y(en())},g};var mn=function(e,t,n){var r=!0,a=!0;if("function"!=typeof e)throw new TypeError("Expected a function");return ee(n)&&(r="leading"in n?!!n.leading:r,a="trailing"in n?!!n.trailing:a),hn(e,t,{leading:r,maxWait:t,trailing:a})},_n=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var yn=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.handleChange=function(e){"function"==typeof n.props.onChange&&n.throttle(n.props.onChange,function(e,t,n){var r=n.getBoundingClientRect(),a=r.width,o=r.height,i="number"==typeof e.pageX?e.pageX:e.touches[0].pageX,s="number"==typeof e.pageY?e.pageY:e.touches[0].pageY,u=i-(n.getBoundingClientRect().left+window.pageXOffset),l=s-(n.getBoundingClientRect().top+window.pageYOffset);u<0?u=0:u>a&&(u=a),l<0?l=0:l>o&&(l=o);var c=u/a,d=1-l/o;return{h:t.h,s:c,v:d,a:t.a,source:"hsv"}}(e,n.props.hsl,n.container),e)},n.handleMouseDown=function(e){n.handleChange(e);var t=n.getContainerRenderWindow();t.addEventListener("mousemove",n.handleChange),t.addEventListener("mouseup",n.handleMouseUp)},n.handleMouseUp=function(){n.unbindEventListeners()},n.throttle=mn((function(e,t,n){e(t,n)}),50),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),_n(t,[{key:"componentWillUnmount",value:function(){this.throttle.cancel(),this.unbindEventListeners()}},{key:"getContainerRenderWindow",value:function(){for(var e=this.container,t=window;!t.document.contains(e)&&t.parent!==t;)t=t.parent;return t}},{key:"unbindEventListeners",value:function(){var e=this.getContainerRenderWindow();e.removeEventListener("mousemove",this.handleChange),e.removeEventListener("mouseup",this.handleMouseUp)}},{key:"render",value:function(){var e=this,t=this.props.style||{},n=t.color,r=t.white,o=t.black,s=t.pointer,u=t.circle,l=i()({default:{color:{absolute:"0px 0px 0px 0px",background:"hsl("+this.props.hsl.h+",100%, 50%)",borderRadius:this.props.radius},white:{absolute:"0px 0px 0px 0px",borderRadius:this.props.radius},black:{absolute:"0px 0px 0px 0px",boxShadow:this.props.shadow,borderRadius:this.props.radius},pointer:{position:"absolute",top:-100*this.props.hsv.v+100+"%",left:100*this.props.hsv.s+"%",cursor:"default"},circle:{width:"4px",height:"4px",boxShadow:"0 0 0 1.5px #fff, inset 0 0 1px 1px rgba(0,0,0,.3),\n 0 0 1px 2px rgba(0,0,0,.4)",borderRadius:"50%",cursor:"hand",transform:"translate(-2px, -2px)"}},custom:{color:n,white:r,black:o,pointer:s,circle:u}},{custom:!!this.props.style});return a.a.createElement("div",{style:l.color,ref:function(t){return e.container=t},onMouseDown:this.handleMouseDown,onTouchMove:this.handleChange,onTouchStart:this.handleChange},a.a.createElement("style",null,"\n .saturation-white {\n background: -webkit-linear-gradient(to right, #fff, rgba(255,255,255,0));\n background: linear-gradient(to right, #fff, rgba(255,255,255,0));\n }\n .saturation-black {\n background: -webkit-linear-gradient(to top, #000, rgba(0,0,0,0));\n background: linear-gradient(to top, #000, rgba(0,0,0,0));\n }\n "),a.a.createElement("div",{style:l.white,className:"saturation-white"},a.a.createElement("div",{style:l.black,className:"saturation-black"}),a.a.createElement("div",{style:l.pointer},this.props.pointer?a.a.createElement(this.props.pointer,this.props):a.a.createElement("div",{style:l.circle}))))}}]),t}(r.PureComponent||r.Component);var gn=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e},vn=Xe(Object.keys,Object),bn=Object.prototype.hasOwnProperty;var wn=function(e){if(!et(e))return vn(e);var t=[];for(var n in Object(e))bn.call(e,n)&&"constructor"!=n&&t.push(n);return t};var Mn=function(e){return ct(e)?Ct(e):wn(e)};var Ln=function(e,t){return function(n,r){if(null==n)return n;if(!ct(n))return e(n,r);for(var a=n.length,o=t?a:-1,i=Object(n);(t?o--:++o<a)&&!1!==r(i[o],o,i););return n}}((function(e,t){return e&&We(e,t,Mn)}));var Tn=function(e){return"function"==typeof e?e:zt};var kn=function(e,t){return(ut(e)?gn:Ln)(e,Tn(t))},xn=n(36),En=n.n(xn),Sn=function(e){var t=0,n=0;return kn(["r","g","b","a","h","s","l","v"],(function(r){if(e[r]&&(t+=1,isNaN(e[r])||(n+=1),"s"===r||"l"===r)){/^\d+%$/.test(e[r])&&(n+=1)}})),t===n&&e},On=function(e,t){var n=e.hex?En()(e.hex):En()(e),r=n.toHsl(),a=n.toHsv(),o=n.toRgb(),i=n.toHex();return 0===r.s&&(r.h=t||0,a.h=t||0),{hsl:r,hex:"000000"===i&&0===o.a?"transparent":"#"+i,rgb:o,hsv:a,oldHue:e.h||t||r.h,source:e.source}},Dn=function(e){if("transparent"===e)return!0;var t="#"===String(e).charAt(0)?1:0;return e.length!==4+t&&e.length<7+t&&En()(e).isValid()},Yn=function(e){if(!e)return"#fff";var t=On(e);return"transparent"===t.hex?"rgba(0,0,0,0.4)":(299*t.rgb.r+587*t.rgb.g+114*t.rgb.b)/1e3>=128?"#000":"#fff"},An=function(e,t){var n=e.replace("°","");return En()(t+" ("+n+")")._ok},Cn=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},jn=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var Pn=function(e){var t=function(t){function n(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,n);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(n.__proto__||Object.getPrototypeOf(n)).call(this));return t.handleChange=function(e,n){if(Sn(e)){var r=On(e,e.h||t.state.oldHue);t.setState(r),t.props.onChangeComplete&&t.debounce(t.props.onChangeComplete,r,n),t.props.onChange&&t.props.onChange(r,n)}},t.handleSwatchHover=function(e,n){if(Sn(e)){var r=On(e,e.h||t.state.oldHue);t.props.onSwatchHover&&t.props.onSwatchHover(r,n)}},t.state=Cn({},On(e.color,0)),t.debounce=hn((function(e,t,n){e(t,n)}),100),t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(n,t),jn(n,[{key:"render",value:function(){var t={};return this.props.onSwatchHover&&(t.onSwatchHover=this.handleSwatchHover),a.a.createElement(e,Cn({},this.props,this.state,{onChange:this.handleChange},t))}}],[{key:"getDerivedStateFromProps",value:function(e,t){return Cn({},On(e.color,t.oldHue))}}]),n}(r.PureComponent||r.Component);return t.propTypes=Cn({},e.propTypes),t.defaultProps=Cn({},e.defaultProps,{color:{h:250,s:.5,l:.2,a:1}}),t},Hn=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},In=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function Nn(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Rn(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function Fn(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var zn=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Un=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"span";return function(n){function r(){var e,t,n;Nn(this,r);for(var a=arguments.length,o=Array(a),i=0;i<a;i++)o[i]=arguments[i];return t=n=Rn(this,(e=r.__proto__||Object.getPrototypeOf(r)).call.apply(e,[this].concat(o))),n.state={focus:!1},n.handleFocus=function(){return n.setState({focus:!0})},n.handleBlur=function(){return n.setState({focus:!1})},Rn(n,t)}return Fn(r,n),In(r,[{key:"render",value:function(){return a.a.createElement(t,{onFocus:this.handleFocus,onBlur:this.handleBlur},a.a.createElement(e,Hn({},this.props,this.state)))}}]),r}(a.a.Component)}((function(e){var t=e.color,n=e.style,r=e.onClick,o=void 0===r?function(){}:r,s=e.onHover,u=e.title,l=void 0===u?t:u,c=e.children,d=e.focus,f=e.focusStyle,h=void 0===f?{}:f,m="transparent"===t,_=i()({default:{swatch:zn({background:t,height:"100%",width:"100%",cursor:"pointer",position:"relative",outline:"none"},n,d?h:{})}}),y={};return s&&(y.onMouseOver=function(e){return s(t,e)}),a.a.createElement("div",zn({style:_.swatch,onClick:function(e){return o(t,e)},title:l,tabIndex:0,onKeyDown:function(e){return 13===e.keyCode&&o(t,e)}},y),c,m&&a.a.createElement(p,{borderRadius:_.swatch.borderRadius,boxShadow:"inset 0 0 0 1px rgba(0,0,0,0.1)"}))})),Wn=function(e){var t=e.direction,n=i()({default:{picker:{width:"18px",height:"18px",borderRadius:"50%",transform:"translate(-9px, -1px)",backgroundColor:"rgb(248, 248, 248)",boxShadow:"0 1px 4px 0 rgba(0, 0, 0, 0.37)"}},vertical:{picker:{transform:"translate(-3px, -9px)"}}},{vertical:"vertical"===t});return a.a.createElement("div",{style:n.picker})},Bn=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Vn=function(e){var t=e.rgb,n=e.hsl,r=e.width,o=e.height,s=e.onChange,u=e.direction,l=e.style,c=e.renderers,d=e.pointer,p=e.className,f=void 0===p?"":p,h=i()({default:{picker:{position:"relative",width:r,height:o},alpha:{radius:"2px",style:l}}});return a.a.createElement("div",{style:h.picker,className:"alpha-picker "+f},a.a.createElement(y,Bn({},h.alpha,{rgb:t,hsl:n,pointer:d,renderers:c,onChange:s,direction:u})))};Vn.defaultProps={width:"316px",height:"16px",direction:"horizontal",pointer:Wn};var Gn=Pn(Vn);var qn=function(e,t){for(var n=-1,r=null==e?0:e.length,a=Array(r);++n<r;)a[n]=t(e[n],n,e);return a};var Jn=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this};var Kn=function(e){return this.__data__.has(e)};function $n(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new He;++t<n;)this.add(e[t])}$n.prototype.add=$n.prototype.push=Jn,$n.prototype.has=Kn;var Xn=$n;var Zn=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1};var Qn=function(e,t){return e.has(t)};var er=function(e,t,n,r,a,o){var i=1&n,s=e.length,u=t.length;if(s!=u&&!(i&&u>s))return!1;var l=o.get(e),c=o.get(t);if(l&&c)return l==t&&c==e;var d=-1,p=!0,f=2&n?new Xn:void 0;for(o.set(e,t),o.set(t,e);++d<s;){var h=e[d],m=t[d];if(r)var _=i?r(m,h,d,t,e,o):r(h,m,d,e,t,o);if(void 0!==_){if(_)continue;p=!1;break}if(f){if(!Zn(t,(function(e,t){if(!Qn(f,t)&&(h===e||a(h,e,n,r,o)))return f.push(t)}))){p=!1;break}}else if(h!==m&&!a(h,m,n,r,o)){p=!1;break}}return o.delete(e),o.delete(t),p};var tr=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n};var nr=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n},rr=B?B.prototype:void 0,ar=rr?rr.valueOf:void 0;var or=function(e,t,n,r,a,o,i){switch(n){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!o(new Ve(e),new Ve(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return D(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var s=tr;case"[object Set]":var u=1&r;if(s||(s=nr),e.size!=t.size&&!u)return!1;var l=i.get(e);if(l)return l==t;r|=2,i.set(e,t);var c=er(s(e),s(t),r,a,o,i);return i.delete(e),c;case"[object Symbol]":if(ar)return ar.call(e)==ar.call(t)}return!1};var ir=function(e,t){for(var n=-1,r=t.length,a=e.length;++n<r;)e[a+n]=t[n];return e};var sr=function(e,t,n){var r=t(e);return ut(e)?r:ir(r,n(e))};var ur=function(e,t){for(var n=-1,r=null==e?0:e.length,a=0,o=[];++n<r;){var i=e[n];t(i,n,e)&&(o[a++]=i)}return o};var lr=function(){return[]},cr=Object.prototype.propertyIsEnumerable,dr=Object.getOwnPropertySymbols,pr=dr?function(e){return null==e?[]:(e=Object(e),ur(dr(e),(function(t){return cr.call(e,t)})))}:lr;var fr=function(e){return sr(e,Mn,pr)},hr=Object.prototype.hasOwnProperty;var mr=function(e,t,n,r,a,o){var i=1&n,s=fr(e),u=s.length;if(u!=fr(t).length&&!i)return!1;for(var l=u;l--;){var c=s[l];if(!(i?c in t:hr.call(t,c)))return!1}var d=o.get(e),p=o.get(t);if(d&&p)return d==t&&p==e;var f=!0;o.set(e,t),o.set(t,e);for(var h=i;++l<u;){var m=e[c=s[l]],_=t[c];if(r)var y=i?r(_,m,c,t,e,o):r(m,_,c,e,t,o);if(!(void 0===y?m===_||a(m,_,n,r,o):y)){f=!1;break}h||(h="constructor"==c)}if(f&&!h){var g=e.constructor,v=t.constructor;g==v||!("constructor"in e)||!("constructor"in t)||"function"==typeof g&&g instanceof g&&"function"==typeof v&&v instanceof v||(f=!1)}return o.delete(e),o.delete(t),f},_r=_e(W.a,"DataView"),yr=_e(W.a,"Promise"),gr=_e(W.a,"Set"),vr=_e(W.a,"WeakMap"),br=se(_r),wr=se(ye),Mr=se(yr),Lr=se(gr),Tr=se(vr),kr=Q;(_r&&"[object DataView]"!=kr(new _r(new ArrayBuffer(1)))||ye&&"[object Map]"!=kr(new ye)||yr&&"[object Promise]"!=kr(yr.resolve())||gr&&"[object Set]"!=kr(new gr)||vr&&"[object WeakMap]"!=kr(new vr))&&(kr=function(e){var t=Q(e),n="[object Object]"==t?e.constructor:void 0,r=n?se(n):"";if(r)switch(r){case br:return"[object DataView]";case wr:return"[object Map]";case Mr:return"[object Promise]";case Lr:return"[object Set]";case Tr:return"[object WeakMap]"}return t});var xr=kr,Er=Object.prototype.hasOwnProperty;var Sr=function(e,t,n,r,a,o){var i=ut(e),s=ut(t),u=i?"[object Array]":xr(e),l=s?"[object Array]":xr(t),c="[object Object]"==(u="[object Arguments]"==u?"[object Object]":u),d="[object Object]"==(l="[object Arguments]"==l?"[object Object]":l),p=u==l;if(p&&Object(pt.a)(e)){if(!Object(pt.a)(t))return!1;i=!0,c=!1}if(p&&!c)return o||(o=new Re),i||Tt(e)?er(e,t,n,r,a,o):or(e,t,u,n,r,a,o);if(!(1&n)){var f=c&&Er.call(e,"__wrapped__"),h=d&&Er.call(t,"__wrapped__");if(f||h){var m=f?e.value():e,_=h?t.value():t;return o||(o=new Re),a(m,_,n,r,o)}}return!!p&&(o||(o=new Re),mr(e,t,n,r,a,o))};var Or=function e(t,n,r,a,o){return t===n||(null==t||null==n||!nt(t)&&!nt(n)?t!=t&&n!=n:Sr(t,n,r,a,e,o))};var Dr=function(e,t,n,r){var a=n.length,o=a,i=!r;if(null==e)return!o;for(e=Object(e);a--;){var s=n[a];if(i&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++a<o;){var u=(s=n[a])[0],l=e[u],c=s[1];if(i&&s[2]){if(void 0===l&&!(u in e))return!1}else{var d=new Re;if(r)var p=r(l,c,u,e,t,d);if(!(void 0===p?Or(c,l,3,r,d):p))return!1}}return!0};var Yr=function(e){return e==e&&!ee(e)};var Ar=function(e){for(var t=Mn(e),n=t.length;n--;){var r=t[n],a=e[r];t[n]=[r,a,Yr(a)]}return t};var Cr=function(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in Object(n)))}};var jr=function(e){var t=Ar(e);return 1==t.length&&t[0][2]?Cr(t[0][0],t[0][1]):function(n){return n===e||Dr(n,e,t)}},Pr=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Hr=/^\w*$/;var Ir=function(e,t){if(ut(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!on(e))||(Hr.test(e)||!Pr.test(e)||null!=t&&e in Object(t))};function Nr(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,a=t?t.apply(this,r):r[0],o=n.cache;if(o.has(a))return o.get(a);var i=e.apply(this,r);return n.cache=o.set(a,i)||o,i};return n.cache=new(Nr.Cache||He),n}Nr.Cache=He;var Rr=Nr;var Fr=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,zr=/\\(\\)?/g,Ur=function(e){var t=Rr(e,(function(e){return 500===n.size&&n.clear(),e})),n=t.cache;return t}((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(Fr,(function(e,n,r,a){t.push(r?a.replace(zr,"$1"):n||e)})),t})),Wr=B?B.prototype:void 0,Br=Wr?Wr.toString:void 0;var Vr=function e(t){if("string"==typeof t)return t;if(ut(t))return qn(t,e)+"";if(on(t))return Br?Br.call(t):"";var n=t+"";return"0"==n&&1/t==-1/0?"-0":n};var Gr=function(e){return null==e?"":Vr(e)};var qr=function(e,t){return ut(e)?e:Ir(e,t)?[e]:Ur(Gr(e))};var Jr=function(e){if("string"==typeof e||on(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t};var Kr=function(e,t){for(var n=0,r=(t=qr(t,e)).length;null!=e&&n<r;)e=e[Jr(t[n++])];return n&&n==r?e:void 0};var $r=function(e,t,n){var r=null==e?void 0:Kr(e,t);return void 0===r?n:r};var Xr=function(e,t){return null!=e&&t in Object(e)};var Zr=function(e,t,n){for(var r=-1,a=(t=qr(t,e)).length,o=!1;++r<a;){var i=Jr(t[r]);if(!(o=null!=e&&n(e,i)))break;e=e[i]}return o||++r!=a?o:!!(a=null==e?0:e.length)&&lt(a)&&Yt(i,a)&&(ut(e)||st(e))};var Qr=function(e,t){return null!=e&&Zr(e,t,Xr)};var ea=function(e,t){return Ir(e)&&Yr(t)?Cr(Jr(e),t):function(n){var r=$r(n,e);return void 0===r&&r===t?Qr(n,e):Or(t,r,3)}};var ta=function(e){return function(t){return null==t?void 0:t[e]}};var na=function(e){return function(t){return Kr(t,e)}};var ra=function(e){return Ir(e)?ta(Jr(e)):na(e)};var aa=function(e){return"function"==typeof e?e:null==e?zt:"object"==typeof e?ut(e)?ea(e[0],e[1]):jr(e):ra(e)};var oa=function(e,t){var n=-1,r=ct(e)?Array(e.length):[];return Ln(e,(function(e,a,o){r[++n]=t(e,a,o)})),r};var ia=function(e,t){return(ut(e)?qn:oa)(e,aa(t,3))},sa=function(e){var t=e.colors,n=e.onClick,r=e.onSwatchHover,o=i()({default:{swatches:{marginRight:"-10px"},swatch:{width:"22px",height:"22px",float:"left",marginRight:"10px",marginBottom:"10px",borderRadius:"4px"},clear:{clear:"both"}}});return a.a.createElement("div",{style:o.swatches},ia(t,(function(e){return a.a.createElement(Un,{key:e,color:e,style:o.swatch,onClick:n,onHover:r,focusStyle:{boxShadow:"0 0 4px "+e}})})),a.a.createElement("div",{style:o.clear}))},ua=function(e){var t=e.onChange,n=e.onSwatchHover,r=e.hex,o=e.colors,s=e.width,u=e.triangle,l=e.styles,c=void 0===l?{}:l,d=e.className,f=void 0===d?"":d,h="transparent"===r,m=function(e,n){Dn(e)&&t({hex:e,source:"hex"},n)},_=i()(Xt({default:{card:{width:s,background:"#fff",boxShadow:"0 1px rgba(0,0,0,.1)",borderRadius:"6px",position:"relative"},head:{height:"110px",background:r,borderRadius:"6px 6px 0 0",display:"flex",alignItems:"center",justifyContent:"center",position:"relative"},body:{padding:"10px"},label:{fontSize:"18px",color:Yn(r),position:"relative"},triangle:{width:"0px",height:"0px",borderStyle:"solid",borderWidth:"0 10px 10px 10px",borderColor:"transparent transparent "+r+" transparent",position:"absolute",top:"-10px",left:"50%",marginLeft:"-10px"},input:{width:"100%",fontSize:"12px",color:"#666",border:"0px",outline:"none",height:"22px",boxShadow:"inset 0 0 0 1px #ddd",borderRadius:"4px",padding:"0 7px",boxSizing:"border-box"}},"hide-triangle":{triangle:{display:"none"}}},c),{"hide-triangle":"hide"===u});return a.a.createElement("div",{style:_.card,className:"block-picker "+f},a.a.createElement("div",{style:_.triangle}),a.a.createElement("div",{style:_.head},h&&a.a.createElement(p,{borderRadius:"6px 6px 0 0"}),a.a.createElement("div",{style:_.label},r)),a.a.createElement("div",{style:_.body},a.a.createElement(sa,{colors:o,onClick:m,onSwatchHover:n}),a.a.createElement(w,{style:{input:_.input},value:r,onChange:m})))};ua.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),colors:S.a.arrayOf(S.a.string),triangle:S.a.oneOf(["top","hide"]),styles:S.a.object},ua.defaultProps={width:170,colors:["#D9E3F0","#F47373","#697689","#37D67A","#2CCCE4","#555555","#dce775","#ff8a65","#ba68c8"],triangle:"top",styles:{}};var la=Pn(ua),ca={50:"#ffebee",100:"#ffcdd2",200:"#ef9a9a",300:"#e57373",400:"#ef5350",500:"#f44336",600:"#e53935",700:"#d32f2f",800:"#c62828",900:"#b71c1c",a100:"#ff8a80",a200:"#ff5252",a400:"#ff1744",a700:"#d50000"},da={50:"#fce4ec",100:"#f8bbd0",200:"#f48fb1",300:"#f06292",400:"#ec407a",500:"#e91e63",600:"#d81b60",700:"#c2185b",800:"#ad1457",900:"#880e4f",a100:"#ff80ab",a200:"#ff4081",a400:"#f50057",a700:"#c51162"},pa={50:"#f3e5f5",100:"#e1bee7",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",600:"#8e24aa",700:"#7b1fa2",800:"#6a1b9a",900:"#4a148c",a100:"#ea80fc",a200:"#e040fb",a400:"#d500f9",a700:"#aa00ff"},fa={50:"#ede7f6",100:"#d1c4e9",200:"#b39ddb",300:"#9575cd",400:"#7e57c2",500:"#673ab7",600:"#5e35b1",700:"#512da8",800:"#4527a0",900:"#311b92",a100:"#b388ff",a200:"#7c4dff",a400:"#651fff",a700:"#6200ea"},ha={50:"#e8eaf6",100:"#c5cae9",200:"#9fa8da",300:"#7986cb",400:"#5c6bc0",500:"#3f51b5",600:"#3949ab",700:"#303f9f",800:"#283593",900:"#1a237e",a100:"#8c9eff",a200:"#536dfe",a400:"#3d5afe",a700:"#304ffe"},ma={50:"#e3f2fd",100:"#bbdefb",200:"#90caf9",300:"#64b5f6",400:"#42a5f5",500:"#2196f3",600:"#1e88e5",700:"#1976d2",800:"#1565c0",900:"#0d47a1",a100:"#82b1ff",a200:"#448aff",a400:"#2979ff",a700:"#2962ff"},_a={50:"#e1f5fe",100:"#b3e5fc",200:"#81d4fa",300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",600:"#039be5",700:"#0288d1",800:"#0277bd",900:"#01579b",a100:"#80d8ff",a200:"#40c4ff",a400:"#00b0ff",a700:"#0091ea"},ya={50:"#e0f7fa",100:"#b2ebf2",200:"#80deea",300:"#4dd0e1",400:"#26c6da",500:"#00bcd4",600:"#00acc1",700:"#0097a7",800:"#00838f",900:"#006064",a100:"#84ffff",a200:"#18ffff",a400:"#00e5ff",a700:"#00b8d4"},ga={50:"#e0f2f1",100:"#b2dfdb",200:"#80cbc4",300:"#4db6ac",400:"#26a69a",500:"#009688",600:"#00897b",700:"#00796b",800:"#00695c",900:"#004d40",a100:"#a7ffeb",a200:"#64ffda",a400:"#1de9b6",a700:"#00bfa5"},va={50:"#e8f5e9",100:"#c8e6c9",200:"#a5d6a7",300:"#81c784",400:"#66bb6a",500:"#4caf50",600:"#43a047",700:"#388e3c",800:"#2e7d32",900:"#1b5e20",a100:"#b9f6ca",a200:"#69f0ae",a400:"#00e676",a700:"#00c853"},ba={50:"#f1f8e9",100:"#dcedc8",200:"#c5e1a5",300:"#aed581",400:"#9ccc65",500:"#8bc34a",600:"#7cb342",700:"#689f38",800:"#558b2f",900:"#33691e",a100:"#ccff90",a200:"#b2ff59",a400:"#76ff03",a700:"#64dd17"},wa={50:"#f9fbe7",100:"#f0f4c3",200:"#e6ee9c",300:"#dce775",400:"#d4e157",500:"#cddc39",600:"#c0ca33",700:"#afb42b",800:"#9e9d24",900:"#827717",a100:"#f4ff81",a200:"#eeff41",a400:"#c6ff00",a700:"#aeea00"},Ma={50:"#fffde7",100:"#fff9c4",200:"#fff59d",300:"#fff176",400:"#ffee58",500:"#ffeb3b",600:"#fdd835",700:"#fbc02d",800:"#f9a825",900:"#f57f17",a100:"#ffff8d",a200:"#ffff00",a400:"#ffea00",a700:"#ffd600"},La={50:"#fff8e1",100:"#ffecb3",200:"#ffe082",300:"#ffd54f",400:"#ffca28",500:"#ffc107",600:"#ffb300",700:"#ffa000",800:"#ff8f00",900:"#ff6f00",a100:"#ffe57f",a200:"#ffd740",a400:"#ffc400",a700:"#ffab00"},Ta={50:"#fff3e0",100:"#ffe0b2",200:"#ffcc80",300:"#ffb74d",400:"#ffa726",500:"#ff9800",600:"#fb8c00",700:"#f57c00",800:"#ef6c00",900:"#e65100",a100:"#ffd180",a200:"#ffab40",a400:"#ff9100",a700:"#ff6d00"},ka={50:"#fbe9e7",100:"#ffccbc",200:"#ffab91",300:"#ff8a65",400:"#ff7043",500:"#ff5722",600:"#f4511e",700:"#e64a19",800:"#d84315",900:"#bf360c",a100:"#ff9e80",a200:"#ff6e40",a400:"#ff3d00",a700:"#dd2c00"},xa={50:"#efebe9",100:"#d7ccc8",200:"#bcaaa4",300:"#a1887f",400:"#8d6e63",500:"#795548",600:"#6d4c41",700:"#5d4037",800:"#4e342e",900:"#3e2723"},Ea={50:"#eceff1",100:"#cfd8dc",200:"#b0bec5",300:"#90a4ae",400:"#78909c",500:"#607d8b",600:"#546e7a",700:"#455a64",800:"#37474f",900:"#263238"},Sa=function(e){var t=e.color,n=e.onClick,r=e.onSwatchHover,o=e.hover,s=e.active,u=e.circleSize,l=e.circleSpacing,c=i()({default:{swatch:{width:u,height:u,marginRight:l,marginBottom:l,transform:"scale(1)",transition:"100ms transform ease"},Swatch:{borderRadius:"50%",background:"transparent",boxShadow:"inset 0 0 0 "+(u/2+1)+"px "+t,transition:"100ms box-shadow ease"}},hover:{swatch:{transform:"scale(1.2)"}},active:{Swatch:{boxShadow:"inset 0 0 0 3px "+t}}},{hover:o,active:s});return a.a.createElement("div",{style:c.swatch},a.a.createElement(Un,{style:c.Swatch,color:t,onClick:n,onHover:r,focusStyle:{boxShadow:c.Swatch.boxShadow+", 0 0 5px "+t}}))};Sa.defaultProps={circleSize:28,circleSpacing:14};var Oa=Object(o.handleHover)(Sa),Da=function(e){var t=e.width,n=e.onChange,r=e.onSwatchHover,o=e.colors,s=e.hex,u=e.circleSize,l=e.styles,c=void 0===l?{}:l,d=e.circleSpacing,p=e.className,f=void 0===p?"":p,h=i()(Xt({default:{card:{width:t,display:"flex",flexWrap:"wrap",marginRight:-d,marginBottom:-d}}},c)),m=function(e,t){return n({hex:e,source:"hex"},t)};return a.a.createElement("div",{style:h.card,className:"circle-picker "+f},ia(o,(function(e){return a.a.createElement(Oa,{key:e,color:e,onClick:m,onSwatchHover:r,active:s===e.toLowerCase(),circleSize:u,circleSpacing:d})})))};Da.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),circleSize:S.a.number,circleSpacing:S.a.number,styles:S.a.object},Da.defaultProps={width:252,circleSize:28,circleSpacing:14,colors:[ca[500],da[500],pa[500],fa[500],ha[500],ma[500],_a[500],ya[500],ga[500],va[500],ba[500],wa[500],Ma[500],La[500],Ta[500],ka[500],xa[500],Ea[500]],styles:{}};var Ya=Pn(Da);var Aa=function(e){return void 0===e},Ca=n(276),ja=n.n(Ca),Pa=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var Ha=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return n.toggleViews=function(){"hex"===n.state.view?n.setState({view:"rgb"}):"rgb"===n.state.view?n.setState({view:"hsl"}):"hsl"===n.state.view&&(1===n.props.hsl.a?n.setState({view:"hex"}):n.setState({view:"rgb"}))},n.handleChange=function(e,t){e.hex?Dn(e.hex)&&n.props.onChange({hex:e.hex,source:"hex"},t):e.r||e.g||e.b?n.props.onChange({r:e.r||n.props.rgb.r,g:e.g||n.props.rgb.g,b:e.b||n.props.rgb.b,source:"rgb"},t):e.a?(e.a<0?e.a=0:e.a>1&&(e.a=1),n.props.onChange({h:n.props.hsl.h,s:n.props.hsl.s,l:n.props.hsl.l,a:Math.round(100*e.a)/100,source:"rgb"},t)):(e.h||e.s||e.l)&&("string"==typeof e.s&&e.s.includes("%")&&(e.s=e.s.replace("%","")),"string"==typeof e.l&&e.l.includes("%")&&(e.l=e.l.replace("%","")),1==e.s?e.s=.01:1==e.l&&(e.l=.01),n.props.onChange({h:e.h||n.props.hsl.h,s:Number(Aa(e.s)?n.props.hsl.s:e.s),l:Number(Aa(e.l)?n.props.hsl.l:e.l),source:"hsl"},t))},n.showHighlight=function(e){e.currentTarget.style.background="#eee"},n.hideHighlight=function(e){e.currentTarget.style.background="transparent"},1!==e.hsl.a&&"hex"===e.view?n.state={view:"rgb"}:n.state={view:e.view},n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),Pa(t,[{key:"render",value:function(){var e=this,t=i()({default:{wrap:{paddingTop:"16px",display:"flex"},fields:{flex:"1",display:"flex",marginLeft:"-6px"},field:{paddingLeft:"6px",width:"100%"},alpha:{paddingLeft:"6px",width:"100%"},toggle:{width:"32px",textAlign:"right",position:"relative"},icon:{marginRight:"-4px",marginTop:"12px",cursor:"pointer",position:"relative"},iconHighlight:{position:"absolute",width:"24px",height:"28px",background:"#eee",borderRadius:"4px",top:"10px",left:"12px",display:"none"},input:{fontSize:"11px",color:"#333",width:"100%",borderRadius:"2px",border:"none",boxShadow:"inset 0 0 0 1px #dadada",height:"21px",textAlign:"center"},label:{textTransform:"uppercase",fontSize:"11px",lineHeight:"11px",color:"#969696",textAlign:"center",display:"block",marginTop:"12px"},svg:{fill:"#333",width:"24px",height:"24px",border:"1px transparent solid",borderRadius:"5px"}},disableAlpha:{alpha:{display:"none"}}},this.props,this.state),n=void 0;return"hex"===this.state.view?n=a.a.createElement("div",{style:t.fields,className:"flexbox-fix"},a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"hex",value:this.props.hex,onChange:this.handleChange}))):"rgb"===this.state.view?n=a.a.createElement("div",{style:t.fields,className:"flexbox-fix"},a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"r",value:this.props.rgb.r,onChange:this.handleChange})),a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"g",value:this.props.rgb.g,onChange:this.handleChange})),a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"b",value:this.props.rgb.b,onChange:this.handleChange})),a.a.createElement("div",{style:t.alpha},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"a",value:this.props.rgb.a,arrowOffset:.01,onChange:this.handleChange}))):"hsl"===this.state.view&&(n=a.a.createElement("div",{style:t.fields,className:"flexbox-fix"},a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"h",value:Math.round(this.props.hsl.h),onChange:this.handleChange})),a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"s",value:Math.round(100*this.props.hsl.s)+"%",onChange:this.handleChange})),a.a.createElement("div",{style:t.field},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"l",value:Math.round(100*this.props.hsl.l)+"%",onChange:this.handleChange})),a.a.createElement("div",{style:t.alpha},a.a.createElement(w,{style:{input:t.input,label:t.label},label:"a",value:this.props.hsl.a,arrowOffset:.01,onChange:this.handleChange})))),a.a.createElement("div",{style:t.wrap,className:"flexbox-fix"},n,a.a.createElement("div",{style:t.toggle},a.a.createElement("div",{style:t.icon,onClick:this.toggleViews,ref:function(t){return e.icon=t}},a.a.createElement(ja.a,{style:t.svg,onMouseOver:this.showHighlight,onMouseEnter:this.showHighlight,onMouseOut:this.hideHighlight}))))}}],[{key:"getDerivedStateFromProps",value:function(e,t){return 1!==e.hsl.a&&"hex"===t.view?{view:"rgb"}:null}}]),t}(a.a.Component);Ha.defaultProps={view:"hex"};var Ia=Ha,Na=function(){var e=i()({default:{picker:{width:"12px",height:"12px",borderRadius:"6px",transform:"translate(-6px, -1px)",backgroundColor:"rgb(248, 248, 248)",boxShadow:"0 1px 4px 0 rgba(0, 0, 0, 0.37)"}}});return a.a.createElement("div",{style:e.picker})},Ra=function(){var e=i()({default:{picker:{width:"12px",height:"12px",borderRadius:"6px",boxShadow:"inset 0 0 0 1px #fff",transform:"translate(-6px, -6px)"}}});return a.a.createElement("div",{style:e.picker})},Fa=function(e){var t=e.width,n=e.onChange,r=e.disableAlpha,o=e.rgb,s=e.hsl,u=e.hsv,l=e.hex,c=e.renderers,d=e.styles,f=void 0===d?{}:d,h=e.className,m=void 0===h?"":h,_=e.defaultView,g=i()(Xt({default:{picker:{width:t,background:"#fff",borderRadius:"2px",boxShadow:"0 0 2px rgba(0,0,0,.3), 0 4px 8px rgba(0,0,0,.3)",boxSizing:"initial",fontFamily:"Menlo"},saturation:{width:"100%",paddingBottom:"55%",position:"relative",borderRadius:"2px 2px 0 0",overflow:"hidden"},Saturation:{radius:"2px 2px 0 0"},body:{padding:"16px 16px 12px"},controls:{display:"flex"},color:{width:"32px"},swatch:{marginTop:"6px",width:"16px",height:"16px",borderRadius:"8px",position:"relative",overflow:"hidden"},active:{absolute:"0px 0px 0px 0px",borderRadius:"8px",boxShadow:"inset 0 0 0 1px rgba(0,0,0,.1)",background:"rgba("+o.r+", "+o.g+", "+o.b+", "+o.a+")",zIndex:"2"},toggles:{flex:"1"},hue:{height:"10px",position:"relative",marginBottom:"8px"},Hue:{radius:"2px"},alpha:{height:"10px",position:"relative"},Alpha:{radius:"2px"}},disableAlpha:{color:{width:"22px"},alpha:{display:"none"},hue:{marginBottom:"0px"},swatch:{width:"10px",height:"10px",marginTop:"0px"}}},f),{disableAlpha:r});return a.a.createElement("div",{style:g.picker,className:"chrome-picker "+m},a.a.createElement("div",{style:g.saturation},a.a.createElement(yn,{style:g.Saturation,hsl:s,hsv:u,pointer:Ra,onChange:n})),a.a.createElement("div",{style:g.body},a.a.createElement("div",{style:g.controls,className:"flexbox-fix"},a.a.createElement("div",{style:g.color},a.a.createElement("div",{style:g.swatch},a.a.createElement("div",{style:g.active}),a.a.createElement(p,{renderers:c}))),a.a.createElement("div",{style:g.toggles},a.a.createElement("div",{style:g.hue},a.a.createElement(x,{style:g.Hue,hsl:s,pointer:Na,onChange:n})),a.a.createElement("div",{style:g.alpha},a.a.createElement(y,{style:g.Alpha,rgb:o,hsl:s,pointer:Na,renderers:c,onChange:n})))),a.a.createElement(Ia,{rgb:o,hsl:s,hex:l,view:_,onChange:n,disableAlpha:r})))};Fa.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),disableAlpha:S.a.bool,styles:S.a.object,defaultView:S.a.oneOf(["hex","rgb","hsl"])},Fa.defaultProps={width:225,disableAlpha:!1,styles:{}};var za=Pn(Fa),Ua=function(e){var t=e.color,n=e.onClick,r=void 0===n?function(){}:n,o=e.onSwatchHover,s=e.active,u=i()({default:{color:{background:t,width:"15px",height:"15px",float:"left",marginRight:"5px",marginBottom:"5px",position:"relative",cursor:"pointer"},dot:{absolute:"5px 5px 5px 5px",background:Yn(t),borderRadius:"50%",opacity:"0"}},active:{dot:{opacity:"1"}},"color-#FFFFFF":{color:{boxShadow:"inset 0 0 0 1px #ddd"},dot:{background:"#000"}},transparent:{dot:{background:"#000"}}},{active:s,"color-#FFFFFF":"#FFFFFF"===t,transparent:"transparent"===t});return a.a.createElement(Un,{style:u.color,color:t,onClick:r,onHover:o,focusStyle:{boxShadow:"0 0 4px "+t}},a.a.createElement("div",{style:u.dot}))},Wa=function(e){var t=e.hex,n=e.rgb,r=e.onChange,o=i()({default:{fields:{display:"flex",paddingBottom:"6px",paddingRight:"5px",position:"relative"},active:{position:"absolute",top:"6px",left:"5px",height:"9px",width:"9px",background:t},HEXwrap:{flex:"6",position:"relative"},HEXinput:{width:"80%",padding:"0px",paddingLeft:"20%",border:"none",outline:"none",background:"none",fontSize:"12px",color:"#333",height:"16px"},HEXlabel:{display:"none"},RGBwrap:{flex:"3",position:"relative"},RGBinput:{width:"70%",padding:"0px",paddingLeft:"30%",border:"none",outline:"none",background:"none",fontSize:"12px",color:"#333",height:"16px"},RGBlabel:{position:"absolute",top:"3px",left:"0px",lineHeight:"16px",textTransform:"uppercase",fontSize:"12px",color:"#999"}}}),s=function(e,t){e.r||e.g||e.b?r({r:e.r||n.r,g:e.g||n.g,b:e.b||n.b,source:"rgb"},t):r({hex:e.hex,source:"hex"},t)};return a.a.createElement("div",{style:o.fields,className:"flexbox-fix"},a.a.createElement("div",{style:o.active}),a.a.createElement(w,{style:{wrap:o.HEXwrap,input:o.HEXinput,label:o.HEXlabel},label:"hex",value:t,onChange:s}),a.a.createElement(w,{style:{wrap:o.RGBwrap,input:o.RGBinput,label:o.RGBlabel},label:"r",value:n.r,onChange:s}),a.a.createElement(w,{style:{wrap:o.RGBwrap,input:o.RGBinput,label:o.RGBlabel},label:"g",value:n.g,onChange:s}),a.a.createElement(w,{style:{wrap:o.RGBwrap,input:o.RGBinput,label:o.RGBlabel},label:"b",value:n.b,onChange:s}))},Ba=function(e){var t=e.onChange,n=e.onSwatchHover,r=e.colors,o=e.hex,s=e.rgb,u=e.styles,l=void 0===u?{}:u,c=e.className,d=void 0===c?"":c,p=i()(Xt({default:{Compact:{background:"#f6f6f6",radius:"4px"},compact:{paddingTop:"5px",paddingLeft:"5px",boxSizing:"initial",width:"240px"},clear:{clear:"both"}}},l)),f=function(e,n){e.hex?Dn(e.hex)&&t({hex:e.hex,source:"hex"},n):t(e,n)};return a.a.createElement(Qt,{style:p.Compact,styles:l},a.a.createElement("div",{style:p.compact,className:"compact-picker "+d},a.a.createElement("div",null,ia(r,(function(e){return a.a.createElement(Ua,{key:e,color:e,active:e.toLowerCase()===o,onClick:f,onSwatchHover:n})})),a.a.createElement("div",{style:p.clear})),a.a.createElement(Wa,{hex:o,rgb:s,onChange:f})))};Ba.propTypes={colors:S.a.arrayOf(S.a.string),styles:S.a.object},Ba.defaultProps={colors:["#4D4D4D","#999999","#FFFFFF","#F44E3B","#FE9200","#FCDC00","#DBDF00","#A4DD00","#68CCCA","#73D8FF","#AEA1FF","#FDA1FF","#333333","#808080","#cccccc","#D33115","#E27300","#FCC400","#B0BC00","#68BC00","#16A5A5","#009CE0","#7B64FF","#FA28FF","#000000","#666666","#B3B3B3","#9F0500","#C45100","#FB9E00","#808900","#194D33","#0C797D","#0062B1","#653294","#AB149E"],styles:{}};var Va=Pn(Ba),Ga=Object(o.handleHover)((function(e){var t=e.hover,n=e.color,r=e.onClick,o=e.onSwatchHover,s={position:"relative",zIndex:"2",outline:"2px solid #fff",boxShadow:"0 0 5px 2px rgba(0,0,0,0.25)"},u=i()({default:{swatch:{width:"25px",height:"25px",fontSize:"0"}},hover:{swatch:s}},{hover:t});return a.a.createElement("div",{style:u.swatch},a.a.createElement(Un,{color:n,onClick:r,onHover:o,focusStyle:s}))})),qa=function(e){var t=e.width,n=e.colors,r=e.onChange,o=e.onSwatchHover,s=e.triangle,u=e.styles,l=void 0===u?{}:u,c=e.className,d=void 0===c?"":c,p=i()(Xt({default:{card:{width:t,background:"#fff",border:"1px solid rgba(0,0,0,0.2)",boxShadow:"0 3px 12px rgba(0,0,0,0.15)",borderRadius:"4px",position:"relative",padding:"5px",display:"flex",flexWrap:"wrap"},triangle:{position:"absolute",border:"7px solid transparent",borderBottomColor:"#fff"},triangleShadow:{position:"absolute",border:"8px solid transparent",borderBottomColor:"rgba(0,0,0,0.15)"}},"hide-triangle":{triangle:{display:"none"},triangleShadow:{display:"none"}},"top-left-triangle":{triangle:{top:"-14px",left:"10px"},triangleShadow:{top:"-16px",left:"9px"}},"top-right-triangle":{triangle:{top:"-14px",right:"10px"},triangleShadow:{top:"-16px",right:"9px"}},"bottom-left-triangle":{triangle:{top:"35px",left:"10px",transform:"rotate(180deg)"},triangleShadow:{top:"37px",left:"9px",transform:"rotate(180deg)"}},"bottom-right-triangle":{triangle:{top:"35px",right:"10px",transform:"rotate(180deg)"},triangleShadow:{top:"37px",right:"9px",transform:"rotate(180deg)"}}},l),{"hide-triangle":"hide"===s,"top-left-triangle":"top-left"===s,"top-right-triangle":"top-right"===s,"bottom-left-triangle":"bottom-left"===s,"bottom-right-triangle":"bottom-right"===s}),f=function(e,t){return r({hex:e,source:"hex"},t)};return a.a.createElement("div",{style:p.card,className:"github-picker "+d},a.a.createElement("div",{style:p.triangleShadow}),a.a.createElement("div",{style:p.triangle}),ia(n,(function(e){return a.a.createElement(Ga,{color:e,key:e,onClick:f,onSwatchHover:o})})))};qa.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),colors:S.a.arrayOf(S.a.string),triangle:S.a.oneOf(["hide","top-left","top-right","bottom-left","bottom-right"]),styles:S.a.object},qa.defaultProps={width:200,colors:["#B80000","#DB3E00","#FCCB00","#008B02","#006B76","#1273DE","#004DCF","#5300EB","#EB9694","#FAD0C3","#FEF3BD","#C1E1C5","#BEDADC","#C4DEF6","#BED3F3","#D4C4FB"],triangle:"top-left",styles:{}};var Ja=Pn(qa),Ka=function(e){var t=e.direction,n=i()({default:{picker:{width:"18px",height:"18px",borderRadius:"50%",transform:"translate(-9px, -1px)",backgroundColor:"rgb(248, 248, 248)",boxShadow:"0 1px 4px 0 rgba(0, 0, 0, 0.37)"}},vertical:{picker:{transform:"translate(-3px, -9px)"}}},{vertical:"vertical"===t});return a.a.createElement("div",{style:n.picker})},$a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Xa=function(e){var t=e.width,n=e.height,r=e.onChange,o=e.hsl,s=e.direction,u=e.pointer,l=e.styles,c=void 0===l?{}:l,d=e.className,p=void 0===d?"":d,f=i()(Xt({default:{picker:{position:"relative",width:t,height:n},hue:{radius:"2px"}}},c));return a.a.createElement("div",{style:f.picker,className:"hue-picker "+p},a.a.createElement(x,$a({},f.hue,{hsl:o,pointer:u,onChange:function(e){return r({a:1,h:e.h,l:.5,s:1})},direction:s})))};Xa.propTypes={styles:S.a.object},Xa.defaultProps={width:"316px",height:"16px",direction:"horizontal",pointer:Ka,styles:{}};var Za=Pn(Xa),Qa=Pn((function(e){var t=e.onChange,n=e.hex,r=e.rgb,o=e.styles,s=void 0===o?{}:o,u=e.className,l=void 0===u?"":u,c=i()(Xt({default:{material:{width:"98px",height:"98px",padding:"16px",fontFamily:"Roboto"},HEXwrap:{position:"relative"},HEXinput:{width:"100%",marginTop:"12px",fontSize:"15px",color:"#333",padding:"0px",border:"0px",borderBottom:"2px solid "+n,outline:"none",height:"30px"},HEXlabel:{position:"absolute",top:"0px",left:"0px",fontSize:"11px",color:"#999999",textTransform:"capitalize"},Hex:{style:{}},RGBwrap:{position:"relative"},RGBinput:{width:"100%",marginTop:"12px",fontSize:"15px",color:"#333",padding:"0px",border:"0px",borderBottom:"1px solid #eee",outline:"none",height:"30px"},RGBlabel:{position:"absolute",top:"0px",left:"0px",fontSize:"11px",color:"#999999",textTransform:"capitalize"},split:{display:"flex",marginRight:"-10px",paddingTop:"11px"},third:{flex:"1",paddingRight:"10px"}}},s)),d=function(e,n){e.hex?Dn(e.hex)&&t({hex:e.hex,source:"hex"},n):(e.r||e.g||e.b)&&t({r:e.r||r.r,g:e.g||r.g,b:e.b||r.b,source:"rgb"},n)};return a.a.createElement(Qt,{styles:s},a.a.createElement("div",{style:c.material,className:"material-picker "+l},a.a.createElement(w,{style:{wrap:c.HEXwrap,input:c.HEXinput,label:c.HEXlabel},label:"hex",value:n,onChange:d}),a.a.createElement("div",{style:c.split,className:"flexbox-fix"},a.a.createElement("div",{style:c.third},a.a.createElement(w,{style:{wrap:c.RGBwrap,input:c.RGBinput,label:c.RGBlabel},label:"r",value:r.r,onChange:d})),a.a.createElement("div",{style:c.third},a.a.createElement(w,{style:{wrap:c.RGBwrap,input:c.RGBinput,label:c.RGBlabel},label:"g",value:r.g,onChange:d})),a.a.createElement("div",{style:c.third},a.a.createElement(w,{style:{wrap:c.RGBwrap,input:c.RGBinput,label:c.RGBlabel},label:"b",value:r.b,onChange:d})))))})),eo=function(e){var t=e.onChange,n=e.rgb,r=e.hsv,o=e.hex,s=i()({default:{fields:{paddingTop:"5px",paddingBottom:"9px",width:"80px",position:"relative"},divider:{height:"5px"},RGBwrap:{position:"relative"},RGBinput:{marginLeft:"40%",width:"40%",height:"18px",border:"1px solid #888888",boxShadow:"inset 0 1px 1px rgba(0,0,0,.1), 0 1px 0 0 #ECECEC",marginBottom:"5px",fontSize:"13px",paddingLeft:"3px",marginRight:"10px"},RGBlabel:{left:"0px",top:"0px",width:"34px",textTransform:"uppercase",fontSize:"13px",height:"18px",lineHeight:"22px",position:"absolute"},HEXwrap:{position:"relative"},HEXinput:{marginLeft:"20%",width:"80%",height:"18px",border:"1px solid #888888",boxShadow:"inset 0 1px 1px rgba(0,0,0,.1), 0 1px 0 0 #ECECEC",marginBottom:"6px",fontSize:"13px",paddingLeft:"3px"},HEXlabel:{position:"absolute",top:"0px",left:"0px",width:"14px",textTransform:"uppercase",fontSize:"13px",height:"18px",lineHeight:"22px"},fieldSymbols:{position:"absolute",top:"5px",right:"-7px",fontSize:"13px"},symbol:{height:"20px",lineHeight:"22px",paddingBottom:"7px"}}}),u=function(e,a){e["#"]?Dn(e["#"])&&t({hex:e["#"],source:"hex"},a):e.r||e.g||e.b?t({r:e.r||n.r,g:e.g||n.g,b:e.b||n.b,source:"rgb"},a):(e.h||e.s||e.v)&&t({h:e.h||r.h,s:e.s||r.s,v:e.v||r.v,source:"hsv"},a)};return a.a.createElement("div",{style:s.fields},a.a.createElement(w,{style:{wrap:s.RGBwrap,input:s.RGBinput,label:s.RGBlabel},label:"h",value:Math.round(r.h),onChange:u}),a.a.createElement(w,{style:{wrap:s.RGBwrap,input:s.RGBinput,label:s.RGBlabel},label:"s",value:Math.round(100*r.s),onChange:u}),a.a.createElement(w,{style:{wrap:s.RGBwrap,input:s.RGBinput,label:s.RGBlabel},label:"v",value:Math.round(100*r.v),onChange:u}),a.a.createElement("div",{style:s.divider}),a.a.createElement(w,{style:{wrap:s.RGBwrap,input:s.RGBinput,label:s.RGBlabel},label:"r",value:n.r,onChange:u}),a.a.createElement(w,{style:{wrap:s.RGBwrap,input:s.RGBinput,label:s.RGBlabel},label:"g",value:n.g,onChange:u}),a.a.createElement(w,{style:{wrap:s.RGBwrap,input:s.RGBinput,label:s.RGBlabel},label:"b",value:n.b,onChange:u}),a.a.createElement("div",{style:s.divider}),a.a.createElement(w,{style:{wrap:s.HEXwrap,input:s.HEXinput,label:s.HEXlabel},label:"#",value:o.replace("#",""),onChange:u}),a.a.createElement("div",{style:s.fieldSymbols},a.a.createElement("div",{style:s.symbol},"°"),a.a.createElement("div",{style:s.symbol},"%"),a.a.createElement("div",{style:s.symbol},"%")))},to=function(e){var t=e.hsl,n=i()({default:{picker:{width:"12px",height:"12px",borderRadius:"6px",boxShadow:"inset 0 0 0 1px #fff",transform:"translate(-6px, -6px)"}},"black-outline":{picker:{boxShadow:"inset 0 0 0 1px #000"}}},{"black-outline":t.l>.5});return a.a.createElement("div",{style:n.picker})},no=function(){var e=i()({default:{triangle:{width:0,height:0,borderStyle:"solid",borderWidth:"4px 0 4px 6px",borderColor:"transparent transparent transparent #fff",position:"absolute",top:"1px",left:"1px"},triangleBorder:{width:0,height:0,borderStyle:"solid",borderWidth:"5px 0 5px 8px",borderColor:"transparent transparent transparent #555"},left:{Extend:"triangleBorder",transform:"translate(-13px, -4px)"},leftInside:{Extend:"triangle",transform:"translate(-8px, -5px)"},right:{Extend:"triangleBorder",transform:"translate(20px, -14px) rotate(180deg)"},rightInside:{Extend:"triangle",transform:"translate(-8px, -5px)"}}});return a.a.createElement("div",{style:e.pointer},a.a.createElement("div",{style:e.left},a.a.createElement("div",{style:e.leftInside})),a.a.createElement("div",{style:e.right},a.a.createElement("div",{style:e.rightInside})))},ro=function(e){var t=e.onClick,n=e.label,r=e.children,o=e.active,s=i()({default:{button:{backgroundImage:"linear-gradient(-180deg, #FFFFFF 0%, #E6E6E6 100%)",border:"1px solid #878787",borderRadius:"2px",height:"20px",boxShadow:"0 1px 0 0 #EAEAEA",fontSize:"14px",color:"#000",lineHeight:"20px",textAlign:"center",marginBottom:"10px",cursor:"pointer"}},active:{button:{boxShadow:"0 0 0 1px #878787"}}},{active:o});return a.a.createElement("div",{style:s.button,onClick:t},n||r)},ao=function(e){var t=e.rgb,n=e.currentColor,r=i()({default:{swatches:{border:"1px solid #B3B3B3",borderBottom:"1px solid #F0F0F0",marginBottom:"2px",marginTop:"1px"},new:{height:"34px",background:"rgb("+t.r+","+t.g+", "+t.b+")",boxShadow:"inset 1px 0 0 #000, inset -1px 0 0 #000, inset 0 1px 0 #000"},current:{height:"34px",background:n,boxShadow:"inset 1px 0 0 #000, inset -1px 0 0 #000, inset 0 -1px 0 #000"},label:{fontSize:"14px",color:"#000",textAlign:"center"}}});return a.a.createElement("div",null,a.a.createElement("div",{style:r.label},"new"),a.a.createElement("div",{style:r.swatches},a.a.createElement("div",{style:r.new}),a.a.createElement("div",{style:r.current})),a.a.createElement("div",{style:r.label},"current"))},oo=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var io=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return n.state={currentColor:e.hex},n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),oo(t,[{key:"render",value:function(){var e=this.props,t=e.styles,n=void 0===t?{}:t,r=e.className,o=void 0===r?"":r,s=i()(Xt({default:{picker:{background:"#DCDCDC",borderRadius:"4px",boxShadow:"0 0 0 1px rgba(0,0,0,.25), 0 8px 16px rgba(0,0,0,.15)",boxSizing:"initial",width:"513px"},head:{backgroundImage:"linear-gradient(-180deg, #F0F0F0 0%, #D4D4D4 100%)",borderBottom:"1px solid #B1B1B1",boxShadow:"inset 0 1px 0 0 rgba(255,255,255,.2), inset 0 -1px 0 0 rgba(0,0,0,.02)",height:"23px",lineHeight:"24px",borderRadius:"4px 4px 0 0",fontSize:"13px",color:"#4D4D4D",textAlign:"center"},body:{padding:"15px 15px 0",display:"flex"},saturation:{width:"256px",height:"256px",position:"relative",border:"2px solid #B3B3B3",borderBottom:"2px solid #F0F0F0",overflow:"hidden"},hue:{position:"relative",height:"256px",width:"19px",marginLeft:"10px",border:"2px solid #B3B3B3",borderBottom:"2px solid #F0F0F0"},controls:{width:"180px",marginLeft:"10px"},top:{display:"flex"},previews:{width:"60px"},actions:{flex:"1",marginLeft:"20px"}}},n));return a.a.createElement("div",{style:s.picker,className:"photoshop-picker "+o},a.a.createElement("div",{style:s.head},this.props.header),a.a.createElement("div",{style:s.body,className:"flexbox-fix"},a.a.createElement("div",{style:s.saturation},a.a.createElement(yn,{hsl:this.props.hsl,hsv:this.props.hsv,pointer:to,onChange:this.props.onChange})),a.a.createElement("div",{style:s.hue},a.a.createElement(x,{direction:"vertical",hsl:this.props.hsl,pointer:no,onChange:this.props.onChange})),a.a.createElement("div",{style:s.controls},a.a.createElement("div",{style:s.top,className:"flexbox-fix"},a.a.createElement("div",{style:s.previews},a.a.createElement(ao,{rgb:this.props.rgb,currentColor:this.state.currentColor})),a.a.createElement("div",{style:s.actions},a.a.createElement(ro,{label:"OK",onClick:this.props.onAccept,active:!0}),a.a.createElement(ro,{label:"Cancel",onClick:this.props.onCancel}),a.a.createElement(eo,{onChange:this.props.onChange,rgb:this.props.rgb,hsv:this.props.hsv,hex:this.props.hex}))))))}}]),t}(a.a.Component);io.propTypes={header:S.a.string,styles:S.a.object},io.defaultProps={header:"Color Picker",styles:{}};var so=Pn(io),uo=function(e){var t=e.onChange,n=e.rgb,r=e.hsl,o=e.hex,s=e.disableAlpha,u=i()({default:{fields:{display:"flex",paddingTop:"4px"},single:{flex:"1",paddingLeft:"6px"},alpha:{flex:"1",paddingLeft:"6px"},double:{flex:"2"},input:{width:"80%",padding:"4px 10% 3px",border:"none",boxShadow:"inset 0 0 0 1px #ccc",fontSize:"11px"},label:{display:"block",textAlign:"center",fontSize:"11px",color:"#222",paddingTop:"3px",paddingBottom:"4px",textTransform:"capitalize"}},disableAlpha:{alpha:{display:"none"}}},{disableAlpha:s}),l=function(e,a){e.hex?Dn(e.hex)&&t({hex:e.hex,source:"hex"},a):e.r||e.g||e.b?t({r:e.r||n.r,g:e.g||n.g,b:e.b||n.b,a:n.a,source:"rgb"},a):e.a&&(e.a<0?e.a=0:e.a>100&&(e.a=100),e.a/=100,t({h:r.h,s:r.s,l:r.l,a:e.a,source:"rgb"},a))};return a.a.createElement("div",{style:u.fields,className:"flexbox-fix"},a.a.createElement("div",{style:u.double},a.a.createElement(w,{style:{input:u.input,label:u.label},label:"hex",value:o.replace("#",""),onChange:l})),a.a.createElement("div",{style:u.single},a.a.createElement(w,{style:{input:u.input,label:u.label},label:"r",value:n.r,onChange:l,dragLabel:"true",dragMax:"255"})),a.a.createElement("div",{style:u.single},a.a.createElement(w,{style:{input:u.input,label:u.label},label:"g",value:n.g,onChange:l,dragLabel:"true",dragMax:"255"})),a.a.createElement("div",{style:u.single},a.a.createElement(w,{style:{input:u.input,label:u.label},label:"b",value:n.b,onChange:l,dragLabel:"true",dragMax:"255"})),a.a.createElement("div",{style:u.alpha},a.a.createElement(w,{style:{input:u.input,label:u.label},label:"a",value:Math.round(100*n.a),onChange:l,dragLabel:"true",dragMax:"100"})))},lo=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},co=function(e){var t=e.colors,n=e.onClick,r=void 0===n?function(){}:n,o=e.onSwatchHover,s=i()({default:{colors:{margin:"0 -10px",padding:"10px 0 0 10px",borderTop:"1px solid #eee",display:"flex",flexWrap:"wrap",position:"relative"},swatchWrap:{width:"16px",height:"16px",margin:"0 10px 10px 0"},swatch:{borderRadius:"3px",boxShadow:"inset 0 0 0 1px rgba(0,0,0,.15)"}},"no-presets":{colors:{display:"none"}}},{"no-presets":!t||!t.length}),u=function(e,t){r({hex:e,source:"hex"},t)};return a.a.createElement("div",{style:s.colors,className:"flexbox-fix"},t.map((function(e){var t="string"==typeof e?{color:e}:e,n=""+t.color+(t.title||"");return a.a.createElement("div",{key:n,style:s.swatchWrap},a.a.createElement(Un,lo({},t,{style:s.swatch,onClick:u,onHover:o,focusStyle:{boxShadow:"inset 0 0 0 1px rgba(0,0,0,.15), 0 0 4px "+t.color}})))})))};co.propTypes={colors:S.a.arrayOf(S.a.oneOfType([S.a.string,S.a.shape({color:S.a.string,title:S.a.string})])).isRequired};var po=co,fo=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ho=function(e){var t=e.width,n=e.rgb,r=e.hex,o=e.hsv,s=e.hsl,u=e.onChange,l=e.onSwatchHover,c=e.disableAlpha,d=e.presetColors,f=e.renderers,h=e.styles,m=void 0===h?{}:h,_=e.className,g=void 0===_?"":_,v=i()(Xt({default:fo({picker:{width:t,padding:"10px 10px 0",boxSizing:"initial",background:"#fff",borderRadius:"4px",boxShadow:"0 0 0 1px rgba(0,0,0,.15), 0 8px 16px rgba(0,0,0,.15)"},saturation:{width:"100%",paddingBottom:"75%",position:"relative",overflow:"hidden"},Saturation:{radius:"3px",shadow:"inset 0 0 0 1px rgba(0,0,0,.15), inset 0 0 4px rgba(0,0,0,.25)"},controls:{display:"flex"},sliders:{padding:"4px 0",flex:"1"},color:{width:"24px",height:"24px",position:"relative",marginTop:"4px",marginLeft:"4px",borderRadius:"3px"},activeColor:{absolute:"0px 0px 0px 0px",borderRadius:"2px",background:"rgba("+n.r+","+n.g+","+n.b+","+n.a+")",boxShadow:"inset 0 0 0 1px rgba(0,0,0,.15), inset 0 0 4px rgba(0,0,0,.25)"},hue:{position:"relative",height:"10px",overflow:"hidden"},Hue:{radius:"2px",shadow:"inset 0 0 0 1px rgba(0,0,0,.15), inset 0 0 4px rgba(0,0,0,.25)"},alpha:{position:"relative",height:"10px",marginTop:"4px",overflow:"hidden"},Alpha:{radius:"2px",shadow:"inset 0 0 0 1px rgba(0,0,0,.15), inset 0 0 4px rgba(0,0,0,.25)"}},m),disableAlpha:{color:{height:"10px"},hue:{height:"10px"},alpha:{display:"none"}}},m),{disableAlpha:c});return a.a.createElement("div",{style:v.picker,className:"sketch-picker "+g},a.a.createElement("div",{style:v.saturation},a.a.createElement(yn,{style:v.Saturation,hsl:s,hsv:o,onChange:u})),a.a.createElement("div",{style:v.controls,className:"flexbox-fix"},a.a.createElement("div",{style:v.sliders},a.a.createElement("div",{style:v.hue},a.a.createElement(x,{style:v.Hue,hsl:s,onChange:u})),a.a.createElement("div",{style:v.alpha},a.a.createElement(y,{style:v.Alpha,rgb:n,hsl:s,renderers:f,onChange:u}))),a.a.createElement("div",{style:v.color},a.a.createElement(p,null),a.a.createElement("div",{style:v.activeColor}))),a.a.createElement(uo,{rgb:n,hsl:s,hex:r,onChange:u,disableAlpha:c}),a.a.createElement(po,{colors:d,onClick:u,onSwatchHover:l}))};ho.propTypes={disableAlpha:S.a.bool,width:S.a.oneOfType([S.a.string,S.a.number]),styles:S.a.object},ho.defaultProps={disableAlpha:!1,width:200,styles:{},presetColors:["#D0021B","#F5A623","#F8E71C","#8B572A","#7ED321","#417505","#BD10E0","#9013FE","#4A90E2","#50E3C2","#B8E986","#000000","#4A4A4A","#9B9B9B","#FFFFFF"]};var mo=Pn(ho),_o=function(e){var t=e.hsl,n=e.offset,r=e.onClick,o=void 0===r?function(){}:r,s=e.active,u=e.first,l=e.last,c=i()({default:{swatch:{height:"12px",background:"hsl("+t.h+", 50%, "+100*n+"%)",cursor:"pointer"}},first:{swatch:{borderRadius:"2px 0 0 2px"}},last:{swatch:{borderRadius:"0 2px 2px 0"}},active:{swatch:{transform:"scaleY(1.8)",borderRadius:"3.6px/2px"}}},{active:s,first:u,last:l});return a.a.createElement("div",{style:c.swatch,onClick:function(e){return o({h:t.h,s:.5,l:n,source:"hsl"},e)}})},yo=function(e){var t=e.onClick,n=e.hsl,r=i()({default:{swatches:{marginTop:"20px"},swatch:{boxSizing:"border-box",width:"20%",paddingRight:"1px",float:"left"},clear:{clear:"both"}}});return a.a.createElement("div",{style:r.swatches},a.a.createElement("div",{style:r.swatch},a.a.createElement(_o,{hsl:n,offset:".80",active:Math.abs(n.l-.8)<.1&&Math.abs(n.s-.5)<.1,onClick:t,first:!0})),a.a.createElement("div",{style:r.swatch},a.a.createElement(_o,{hsl:n,offset:".65",active:Math.abs(n.l-.65)<.1&&Math.abs(n.s-.5)<.1,onClick:t})),a.a.createElement("div",{style:r.swatch},a.a.createElement(_o,{hsl:n,offset:".50",active:Math.abs(n.l-.5)<.1&&Math.abs(n.s-.5)<.1,onClick:t})),a.a.createElement("div",{style:r.swatch},a.a.createElement(_o,{hsl:n,offset:".35",active:Math.abs(n.l-.35)<.1&&Math.abs(n.s-.5)<.1,onClick:t})),a.a.createElement("div",{style:r.swatch},a.a.createElement(_o,{hsl:n,offset:".20",active:Math.abs(n.l-.2)<.1&&Math.abs(n.s-.5)<.1,onClick:t,last:!0})),a.a.createElement("div",{style:r.clear}))},go=function(){var e=i()({default:{picker:{width:"14px",height:"14px",borderRadius:"6px",transform:"translate(-7px, -1px)",backgroundColor:"rgb(248, 248, 248)",boxShadow:"0 1px 4px 0 rgba(0, 0, 0, 0.37)"}}});return a.a.createElement("div",{style:e.picker})},vo=function(e){var t=e.hsl,n=e.onChange,r=e.pointer,o=e.styles,s=void 0===o?{}:o,u=e.className,l=void 0===u?"":u,c=i()(Xt({default:{hue:{height:"12px",position:"relative"},Hue:{radius:"2px"}}},s));return a.a.createElement("div",{style:c.wrap||{},className:"slider-picker "+l},a.a.createElement("div",{style:c.hue},a.a.createElement(x,{style:c.Hue,hsl:t,pointer:r,onChange:n})),a.a.createElement("div",{style:c.swatches},a.a.createElement(yo,{hsl:t,onClick:n})))};vo.propTypes={styles:S.a.object},vo.defaultProps={pointer:go,styles:{}};var bo=Pn(vo),wo=n(277),Mo=n.n(wo),Lo=function(e){var t=e.color,n=e.onClick,r=void 0===n?function(){}:n,o=e.onSwatchHover,s=e.first,u=e.last,l=e.active,c=i()({default:{color:{width:"40px",height:"24px",cursor:"pointer",background:t,marginBottom:"1px"},check:{color:Yn(t),marginLeft:"8px",display:"none"}},first:{color:{overflow:"hidden",borderRadius:"2px 2px 0 0"}},last:{color:{overflow:"hidden",borderRadius:"0 0 2px 2px"}},active:{check:{display:"block"}},"color-#FFFFFF":{color:{boxShadow:"inset 0 0 0 1px #ddd"},check:{color:"#333"}},transparent:{check:{color:"#333"}}},{first:s,last:u,active:l,"color-#FFFFFF":"#FFFFFF"===t,transparent:"transparent"===t});return a.a.createElement(Un,{color:t,style:c.color,onClick:r,onHover:o,focusStyle:{boxShadow:"0 0 4px "+t}},a.a.createElement("div",{style:c.check},a.a.createElement(Mo.a,null)))},To=function(e){var t=e.onClick,n=e.onSwatchHover,r=e.group,o=e.active,s=i()({default:{group:{paddingBottom:"10px",width:"40px",float:"left",marginRight:"10px"}}});return a.a.createElement("div",{style:s.group},ia(r,(function(e,i){return a.a.createElement(Lo,{key:e,color:e,active:e.toLowerCase()===o,first:0===i,last:i===r.length-1,onClick:t,onSwatchHover:n})})))},ko=function(e){var t=e.width,n=e.height,r=e.onChange,o=e.onSwatchHover,s=e.colors,u=e.hex,l=e.styles,c=void 0===l?{}:l,d=e.className,p=void 0===d?"":d,f=i()(Xt({default:{picker:{width:t,height:n},overflow:{height:n,overflowY:"scroll"},body:{padding:"16px 0 6px 16px"},clear:{clear:"both"}}},c)),h=function(e,t){return r({hex:e,source:"hex"},t)};return a.a.createElement("div",{style:f.picker,className:"swatches-picker "+p},a.a.createElement(Qt,null,a.a.createElement("div",{style:f.overflow},a.a.createElement("div",{style:f.body},ia(s,(function(e){return a.a.createElement(To,{key:e.toString(),group:e,active:u,onClick:h,onSwatchHover:o})})),a.a.createElement("div",{style:f.clear})))))};ko.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),height:S.a.oneOfType([S.a.string,S.a.number]),colors:S.a.arrayOf(S.a.arrayOf(S.a.string)),styles:S.a.object},ko.defaultProps={width:320,height:240,colors:[[ca[900],ca[700],ca[500],ca[300],ca[100]],[da[900],da[700],da[500],da[300],da[100]],[pa[900],pa[700],pa[500],pa[300],pa[100]],[fa[900],fa[700],fa[500],fa[300],fa[100]],[ha[900],ha[700],ha[500],ha[300],ha[100]],[ma[900],ma[700],ma[500],ma[300],ma[100]],[_a[900],_a[700],_a[500],_a[300],_a[100]],[ya[900],ya[700],ya[500],ya[300],ya[100]],[ga[900],ga[700],ga[500],ga[300],ga[100]],["#194D33",va[700],va[500],va[300],va[100]],[ba[900],ba[700],ba[500],ba[300],ba[100]],[wa[900],wa[700],wa[500],wa[300],wa[100]],[Ma[900],Ma[700],Ma[500],Ma[300],Ma[100]],[La[900],La[700],La[500],La[300],La[100]],[Ta[900],Ta[700],Ta[500],Ta[300],Ta[100]],[ka[900],ka[700],ka[500],ka[300],ka[100]],[xa[900],xa[700],xa[500],xa[300],xa[100]],[Ea[900],Ea[700],Ea[500],Ea[300],Ea[100]],["#000000","#525252","#969696","#D9D9D9","#FFFFFF"]],styles:{}};var xo=Pn(ko),Eo=function(e){var t=e.onChange,n=e.onSwatchHover,r=e.hex,o=e.colors,s=e.width,u=e.triangle,l=e.styles,c=void 0===l?{}:l,d=e.className,p=void 0===d?"":d,f=i()(Xt({default:{card:{width:s,background:"#fff",border:"0 solid rgba(0,0,0,0.25)",boxShadow:"0 1px 4px rgba(0,0,0,0.25)",borderRadius:"4px",position:"relative"},body:{padding:"15px 9px 9px 15px"},label:{fontSize:"18px",color:"#fff"},triangle:{width:"0px",height:"0px",borderStyle:"solid",borderWidth:"0 9px 10px 9px",borderColor:"transparent transparent #fff transparent",position:"absolute"},triangleShadow:{width:"0px",height:"0px",borderStyle:"solid",borderWidth:"0 9px 10px 9px",borderColor:"transparent transparent rgba(0,0,0,.1) transparent",position:"absolute"},hash:{background:"#F0F0F0",height:"30px",width:"30px",borderRadius:"4px 0 0 4px",float:"left",color:"#98A1A4",display:"flex",alignItems:"center",justifyContent:"center"},input:{width:"100px",fontSize:"14px",color:"#666",border:"0px",outline:"none",height:"28px",boxShadow:"inset 0 0 0 1px #F0F0F0",boxSizing:"content-box",borderRadius:"0 4px 4px 0",float:"left",paddingLeft:"8px"},swatch:{width:"30px",height:"30px",float:"left",borderRadius:"4px",margin:"0 6px 6px 0"},clear:{clear:"both"}},"hide-triangle":{triangle:{display:"none"},triangleShadow:{display:"none"}},"top-left-triangle":{triangle:{top:"-10px",left:"12px"},triangleShadow:{top:"-11px",left:"12px"}},"top-right-triangle":{triangle:{top:"-10px",right:"12px"},triangleShadow:{top:"-11px",right:"12px"}}},c),{"hide-triangle":"hide"===u,"top-left-triangle":"top-left"===u,"top-right-triangle":"top-right"===u}),h=function(e,n){Dn(e)&&t({hex:e,source:"hex"},n)};return a.a.createElement("div",{style:f.card,className:"twitter-picker "+p},a.a.createElement("div",{style:f.triangleShadow}),a.a.createElement("div",{style:f.triangle}),a.a.createElement("div",{style:f.body},ia(o,(function(e,t){return a.a.createElement(Un,{key:t,color:e,hex:e,style:f.swatch,onClick:h,onHover:n,focusStyle:{boxShadow:"0 0 4px "+e}})})),a.a.createElement("div",{style:f.hash},"#"),a.a.createElement(w,{label:null,style:{input:f.input},value:r.replace("#",""),onChange:h}),a.a.createElement("div",{style:f.clear})))};Eo.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),triangle:S.a.oneOf(["hide","top-left","top-right"]),colors:S.a.arrayOf(S.a.string),styles:S.a.object},Eo.defaultProps={width:276,colors:["#FF6900","#FCB900","#7BDCB5","#00D084","#8ED1FC","#0693E3","#ABB8C3","#EB144C","#F78DA7","#9900EF"],triangle:"top-left",styles:{}};var So=Pn(Eo),Oo=function(e){var t=i()({default:{picker:{width:"20px",height:"20px",borderRadius:"22px",border:"2px #fff solid",transform:"translate(-12px, -13px)",background:"hsl("+Math.round(e.hsl.h)+", "+Math.round(100*e.hsl.s)+"%, "+Math.round(100*e.hsl.l)+"%)"}}});return a.a.createElement("div",{style:t.picker})};Oo.propTypes={hsl:S.a.shape({h:S.a.number,s:S.a.number,l:S.a.number,a:S.a.number})},Oo.defaultProps={hsl:{a:1,h:249.94,l:.2,s:.5}};var Do=Oo,Yo=function(e){var t=i()({default:{picker:{width:"20px",height:"20px",borderRadius:"22px",transform:"translate(-10px, -7px)",background:"hsl("+Math.round(e.hsl.h)+", 100%, 50%)",border:"2px white solid"}}});return a.a.createElement("div",{style:t.picker})};Yo.propTypes={hsl:S.a.shape({h:S.a.number,s:S.a.number,l:S.a.number,a:S.a.number})},Yo.defaultProps={hsl:{a:1,h:249.94,l:.2,s:.5}};var Ao=Yo,Co=function(e){var t=e.onChange,n=e.rgb,r=e.hsl,o=e.hex,s=e.hsv,u=function(e,n){if(e.hex)Dn(e.hex)&&t({hex:e.hex,source:"hex"},n);else if(e.rgb){var r=e.rgb.split(",");An(e.rgb,"rgb")&&t({r:r[0],g:r[1],b:r[2],a:1,source:"rgb"},n)}else if(e.hsv){var a=e.hsv.split(",");An(e.hsv,"hsv")&&(a[2]=a[2].replace("%",""),a[1]=a[1].replace("%",""),a[0]=a[0].replace("°",""),1==a[1]?a[1]=.01:1==a[2]&&(a[2]=.01),t({h:Number(a[0]),s:Number(a[1]),v:Number(a[2]),source:"hsv"},n))}else if(e.hsl){var o=e.hsl.split(",");An(e.hsl,"hsl")&&(o[2]=o[2].replace("%",""),o[1]=o[1].replace("%",""),o[0]=o[0].replace("°",""),1==p[1]?p[1]=.01:1==p[2]&&(p[2]=.01),t({h:Number(o[0]),s:Number(o[1]),v:Number(o[2]),source:"hsl"},n))}},l=i()({default:{wrap:{display:"flex",height:"100px",marginTop:"4px"},fields:{width:"100%"},column:{paddingTop:"10px",display:"flex",justifyContent:"space-between"},double:{padding:"0px 4.4px",boxSizing:"border-box"},input:{width:"100%",height:"38px",boxSizing:"border-box",padding:"4px 10% 3px",textAlign:"center",border:"1px solid #dadce0",fontSize:"11px",textTransform:"lowercase",borderRadius:"5px",outline:"none",fontFamily:"Roboto,Arial,sans-serif"},input2:{height:"38px",width:"100%",border:"1px solid #dadce0",boxSizing:"border-box",fontSize:"11px",textTransform:"lowercase",borderRadius:"5px",outline:"none",paddingLeft:"10px",fontFamily:"Roboto,Arial,sans-serif"},label:{textAlign:"center",fontSize:"12px",background:"#fff",position:"absolute",textTransform:"uppercase",color:"#3c4043",width:"35px",top:"-6px",left:"0",right:"0",marginLeft:"auto",marginRight:"auto",fontFamily:"Roboto,Arial,sans-serif"},label2:{left:"10px",textAlign:"center",fontSize:"12px",background:"#fff",position:"absolute",textTransform:"uppercase",color:"#3c4043",width:"32px",top:"-6px",fontFamily:"Roboto,Arial,sans-serif"},single:{flexGrow:"1",margin:"0px 4.4px"}}}),c=n.r+", "+n.g+", "+n.b,d=Math.round(r.h)+"°, "+Math.round(100*r.s)+"%, "+Math.round(100*r.l)+"%",p=Math.round(s.h)+"°, "+Math.round(100*s.s)+"%, "+Math.round(100*s.v)+"%";return a.a.createElement("div",{style:l.wrap,className:"flexbox-fix"},a.a.createElement("div",{style:l.fields},a.a.createElement("div",{style:l.double},a.a.createElement(w,{style:{input:l.input,label:l.label},label:"hex",value:o,onChange:u})),a.a.createElement("div",{style:l.column},a.a.createElement("div",{style:l.single},a.a.createElement(w,{style:{input:l.input2,label:l.label2},label:"rgb",value:c,onChange:u})),a.a.createElement("div",{style:l.single},a.a.createElement(w,{style:{input:l.input2,label:l.label2},label:"hsv",value:p,onChange:u})),a.a.createElement("div",{style:l.single},a.a.createElement(w,{style:{input:l.input2,label:l.label2},label:"hsl",value:d,onChange:u})))))},jo=function(e){var t=e.width,n=e.onChange,r=e.rgb,o=e.hsl,s=e.hsv,u=e.hex,l=e.header,c=e.styles,d=void 0===c?{}:c,p=e.className,f=void 0===p?"":p,h=i()(Xt({default:{picker:{width:t,background:"#fff",border:"1px solid #dfe1e5",boxSizing:"initial",display:"flex",flexWrap:"wrap",borderRadius:"8px 8px 0px 0px"},head:{height:"57px",width:"100%",paddingTop:"16px",paddingBottom:"16px",paddingLeft:"16px",fontSize:"20px",boxSizing:"border-box",fontFamily:"Roboto-Regular,HelveticaNeue,Arial,sans-serif"},saturation:{width:"70%",padding:"0px",position:"relative",overflow:"hidden"},swatch:{width:"30%",height:"228px",padding:"0px",background:"rgba("+r.r+", "+r.g+", "+r.b+", 1)",position:"relative",overflow:"hidden"},body:{margin:"auto",width:"95%"},controls:{display:"flex",boxSizing:"border-box",height:"52px",paddingTop:"22px"},color:{width:"32px"},hue:{height:"8px",position:"relative",margin:"0px 16px 0px 16px",width:"100%"},Hue:{radius:"2px"}}},d));return a.a.createElement("div",{style:h.picker,className:"google-picker "+f},a.a.createElement("div",{style:h.head},l),a.a.createElement("div",{style:h.swatch}),a.a.createElement("div",{style:h.saturation},a.a.createElement(yn,{hsl:o,hsv:s,pointer:Do,onChange:n})),a.a.createElement("div",{style:h.body},a.a.createElement("div",{style:h.controls,className:"flexbox-fix"},a.a.createElement("div",{style:h.hue},a.a.createElement(x,{style:h.Hue,hsl:o,radius:"4px",pointer:Ao,onChange:n}))),a.a.createElement(Co,{rgb:r,hsl:o,hex:u,hsv:s,onChange:n})))};jo.propTypes={width:S.a.oneOfType([S.a.string,S.a.number]),styles:S.a.object,header:S.a.string},jo.defaultProps={width:652,styles:{},header:"Color picker"};var Po=Pn(jo)},function(e,t,n){"use strict";function r(e,t){return(r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}n.r(t),n.d(t,"CacheProvider",(function(){return S})),n.d(t,"ThemeContext",(function(){return E})),n.d(t,"withEmotionCache",(function(){return O})),n.d(t,"css",(function(){return j})),n.d(t,"ClassNames",(function(){return z})),n.d(t,"Global",(function(){return H})),n.d(t,"createElement",(function(){return P})),n.d(t,"jsx",(function(){return P})),n.d(t,"keyframes",(function(){return N}));var a=n(0);var o=function(){function e(e){this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.before=null}var t=e.prototype;return t.insert=function(e){if(this.ctr%(this.isSpeedy?65e3:1)==0){var t,n=function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t}(this);t=0===this.tags.length?this.before:this.tags[this.tags.length-1].nextSibling,this.container.insertBefore(n,t),this.tags.push(n)}var r=this.tags[this.tags.length-1];if(this.isSpeedy){var a=function(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}(r);try{var o=105===e.charCodeAt(1)&&64===e.charCodeAt(0);a.insertRule(e,o?0:a.cssRules.length)}catch(e){0}}else r.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach((function(e){return e.parentNode.removeChild(e)})),this.tags=[],this.ctr=0},e}();var i=function(e){function t(e,t,r){var a=t.trim().split(h);t=a;var o=a.length,i=e.length;switch(i){case 0:case 1:var s=0;for(e=0===i?"":e[0]+" ";s<o;++s)t[s]=n(e,t[s],r).trim();break;default:var u=s=0;for(t=[];s<o;++s)for(var l=0;l<i;++l)t[u++]=n(e[l]+" ",a[s],r).trim()}return t}function n(e,t,n){var r=t.charCodeAt(0);switch(33>r&&(r=(t=t.trim()).charCodeAt(0)),r){case 38:return t.replace(m,"$1"+e.trim());case 58:return e.trim()+t.replace(m,"$1"+e.trim());default:if(0<1*n&&0<t.indexOf("\f"))return t.replace(m,(58===e.charCodeAt(0)?"":"$1")+e.trim())}return e+t}function r(e,t,n,o){var i=e+";",s=2*t+3*n+4*o;if(944===s){e=i.indexOf(":",9)+1;var u=i.substring(e,i.length-1).trim();return u=i.substring(0,e).trim()+u+";",1===O||2===O&&a(u,1)?"-webkit-"+u+u:u}if(0===O||2===O&&!a(i,1))return i;switch(s){case 1015:return 97===i.charCodeAt(10)?"-webkit-"+i+i:i;case 951:return 116===i.charCodeAt(3)?"-webkit-"+i+i:i;case 963:return 110===i.charCodeAt(5)?"-webkit-"+i+i:i;case 1009:if(100!==i.charCodeAt(4))break;case 969:case 942:return"-webkit-"+i+i;case 978:return"-webkit-"+i+"-moz-"+i+i;case 1019:case 983:return"-webkit-"+i+"-moz-"+i+"-ms-"+i+i;case 883:if(45===i.charCodeAt(8))return"-webkit-"+i+i;if(0<i.indexOf("image-set(",11))return i.replace(k,"$1-webkit-$2")+i;break;case 932:if(45===i.charCodeAt(4))switch(i.charCodeAt(5)){case 103:return"-webkit-box-"+i.replace("-grow","")+"-webkit-"+i+"-ms-"+i.replace("grow","positive")+i;case 115:return"-webkit-"+i+"-ms-"+i.replace("shrink","negative")+i;case 98:return"-webkit-"+i+"-ms-"+i.replace("basis","preferred-size")+i}return"-webkit-"+i+"-ms-"+i+i;case 964:return"-webkit-"+i+"-ms-flex-"+i+i;case 1023:if(99!==i.charCodeAt(8))break;return"-webkit-box-pack"+(u=i.substring(i.indexOf(":",15)).replace("flex-","").replace("space-between","justify"))+"-webkit-"+i+"-ms-flex-pack"+u+i;case 1005:return p.test(i)?i.replace(d,":-webkit-")+i.replace(d,":-moz-")+i:i;case 1e3:switch(t=(u=i.substring(13).trim()).indexOf("-")+1,u.charCodeAt(0)+u.charCodeAt(t)){case 226:u=i.replace(v,"tb");break;case 232:u=i.replace(v,"tb-rl");break;case 220:u=i.replace(v,"lr");break;default:return i}return"-webkit-"+i+"-ms-"+u+i;case 1017:if(-1===i.indexOf("sticky",9))break;case 975:switch(t=(i=e).length-10,s=(u=(33===i.charCodeAt(t)?i.substring(0,t):i).substring(e.indexOf(":",7)+1).trim()).charCodeAt(0)+(0|u.charCodeAt(7))){case 203:if(111>u.charCodeAt(8))break;case 115:i=i.replace(u,"-webkit-"+u)+";"+i;break;case 207:case 102:i=i.replace(u,"-webkit-"+(102<s?"inline-":"")+"box")+";"+i.replace(u,"-webkit-"+u)+";"+i.replace(u,"-ms-"+u+"box")+";"+i}return i+";";case 938:if(45===i.charCodeAt(5))switch(i.charCodeAt(6)){case 105:return u=i.replace("-items",""),"-webkit-"+i+"-webkit-box-"+u+"-ms-flex-"+u+i;case 115:return"-webkit-"+i+"-ms-flex-item-"+i.replace(M,"")+i;default:return"-webkit-"+i+"-ms-flex-line-pack"+i.replace("align-content","").replace(M,"")+i}break;case 973:case 989:if(45!==i.charCodeAt(3)||122===i.charCodeAt(4))break;case 931:case 953:if(!0===T.test(e))return 115===(u=e.substring(e.indexOf(":")+1)).charCodeAt(0)?r(e.replace("stretch","fill-available"),t,n,o).replace(":fill-available",":stretch"):i.replace(u,"-webkit-"+u)+i.replace(u,"-moz-"+u.replace("fill-",""))+i;break;case 962:if(i="-webkit-"+i+(102===i.charCodeAt(5)?"-ms-"+i:"")+i,211===n+o&&105===i.charCodeAt(13)&&0<i.indexOf("transform",10))return i.substring(0,i.indexOf(";",27)+1).replace(f,"$1-webkit-$2")+i}return i}function a(e,t){var n=e.indexOf(1===t?":":"{"),r=e.substring(0,3!==t?n:10);return n=e.substring(n+1,e.length-1),C(2!==t?r:r.replace(L,"$1"),n,t)}function o(e,t){var n=r(t,t.charCodeAt(0),t.charCodeAt(1),t.charCodeAt(2));return n!==t+";"?n.replace(w," or ($1)").substring(4):"("+t+")"}function i(e,t,n,r,a,o,i,s,l,c){for(var d,p=0,f=t;p<A;++p)switch(d=Y[p].call(u,e,f,n,r,a,o,i,s,l,c)){case void 0:case!1:case!0:case null:break;default:f=d}if(f!==t)return f}function s(e){return void 0!==(e=e.prefix)&&(C=null,e?"function"!=typeof e?O=1:(O=2,C=e):O=0),s}function u(e,n){var s=e;if(33>s.charCodeAt(0)&&(s=s.trim()),s=[s],0<A){var u=i(-1,n,s,s,E,x,0,0,0,0);void 0!==u&&"string"==typeof u&&(n=u)}var d=function e(n,s,u,d,p){for(var f,h,m,v,w,M=0,L=0,T=0,k=0,Y=0,C=0,P=m=f=0,H=0,I=0,N=0,R=0,F=u.length,z=F-1,U="",W="",B="",V="";H<F;){if(h=u.charCodeAt(H),H===z&&0!==L+k+T+M&&(0!==L&&(h=47===L?10:47),k=T=M=0,F++,z++),0===L+k+T+M){if(H===z&&(0<I&&(U=U.replace(c,"")),0<U.trim().length)){switch(h){case 32:case 9:case 59:case 13:case 10:break;default:U+=u.charAt(H)}h=59}switch(h){case 123:for(f=(U=U.trim()).charCodeAt(0),m=1,R=++H;H<F;){switch(h=u.charCodeAt(H)){case 123:m++;break;case 125:m--;break;case 47:switch(h=u.charCodeAt(H+1)){case 42:case 47:e:{for(P=H+1;P<z;++P)switch(u.charCodeAt(P)){case 47:if(42===h&&42===u.charCodeAt(P-1)&&H+2!==P){H=P+1;break e}break;case 10:if(47===h){H=P+1;break e}}H=P}}break;case 91:h++;case 40:h++;case 34:case 39:for(;H++<z&&u.charCodeAt(H)!==h;);}if(0===m)break;H++}switch(m=u.substring(R,H),0===f&&(f=(U=U.replace(l,"").trim()).charCodeAt(0)),f){case 64:switch(0<I&&(U=U.replace(c,"")),h=U.charCodeAt(1)){case 100:case 109:case 115:case 45:I=s;break;default:I=D}if(R=(m=e(s,I,m,h,p+1)).length,0<A&&(w=i(3,m,I=t(D,U,N),s,E,x,R,h,p,d),U=I.join(""),void 0!==w&&0===(R=(m=w.trim()).length)&&(h=0,m="")),0<R)switch(h){case 115:U=U.replace(b,o);case 100:case 109:case 45:m=U+"{"+m+"}";break;case 107:m=(U=U.replace(_,"$1 $2"))+"{"+m+"}",m=1===O||2===O&&a("@"+m,3)?"@-webkit-"+m+"@"+m:"@"+m;break;default:m=U+m,112===d&&(W+=m,m="")}else m="";break;default:m=e(s,t(s,U,N),m,d,p+1)}B+=m,m=N=I=P=f=0,U="",h=u.charCodeAt(++H);break;case 125:case 59:if(1<(R=(U=(0<I?U.replace(c,""):U).trim()).length))switch(0===P&&(f=U.charCodeAt(0),45===f||96<f&&123>f)&&(R=(U=U.replace(" ",":")).length),0<A&&void 0!==(w=i(1,U,s,n,E,x,W.length,d,p,d))&&0===(R=(U=w.trim()).length)&&(U="\0\0"),f=U.charCodeAt(0),h=U.charCodeAt(1),f){case 0:break;case 64:if(105===h||99===h){V+=U+u.charAt(H);break}default:58!==U.charCodeAt(R-1)&&(W+=r(U,f,h,U.charCodeAt(2)))}N=I=P=f=0,U="",h=u.charCodeAt(++H)}}switch(h){case 13:case 10:47===L?L=0:0===1+f&&107!==d&&0<U.length&&(I=1,U+="\0"),0<A*j&&i(0,U,s,n,E,x,W.length,d,p,d),x=1,E++;break;case 59:case 125:if(0===L+k+T+M){x++;break}default:switch(x++,v=u.charAt(H),h){case 9:case 32:if(0===k+M+L)switch(Y){case 44:case 58:case 9:case 32:v="";break;default:32!==h&&(v=" ")}break;case 0:v="\\0";break;case 12:v="\\f";break;case 11:v="\\v";break;case 38:0===k+L+M&&(I=N=1,v="\f"+v);break;case 108:if(0===k+L+M+S&&0<P)switch(H-P){case 2:112===Y&&58===u.charCodeAt(H-3)&&(S=Y);case 8:111===C&&(S=C)}break;case 58:0===k+L+M&&(P=H);break;case 44:0===L+T+k+M&&(I=1,v+="\r");break;case 34:case 39:0===L&&(k=k===h?0:0===k?h:k);break;case 91:0===k+L+T&&M++;break;case 93:0===k+L+T&&M--;break;case 41:0===k+L+M&&T--;break;case 40:if(0===k+L+M){if(0===f)switch(2*Y+3*C){case 533:break;default:f=1}T++}break;case 64:0===L+T+k+M+P+m&&(m=1);break;case 42:case 47:if(!(0<k+M+T))switch(L){case 0:switch(2*h+3*u.charCodeAt(H+1)){case 235:L=47;break;case 220:R=H,L=42}break;case 42:47===h&&42===Y&&R+2!==H&&(33===u.charCodeAt(R+2)&&(W+=u.substring(R,H+1)),v="",L=0)}}0===L&&(U+=v)}C=Y,Y=h,H++}if(0<(R=W.length)){if(I=s,0<A&&(void 0!==(w=i(2,W,I,n,E,x,R,d,p,d))&&0===(W=w).length))return V+W+B;if(W=I.join(",")+"{"+W+"}",0!=O*S){switch(2!==O||a(W,2)||(S=0),S){case 111:W=W.replace(g,":-moz-$1")+W;break;case 112:W=W.replace(y,"::-webkit-input-$1")+W.replace(y,"::-moz-$1")+W.replace(y,":-ms-input-$1")+W}S=0}}return V+W+B}(D,s,n,0,0);return 0<A&&(void 0!==(u=i(-2,d,s,s,E,x,d.length,0,0,0))&&(d=u)),"",S=0,x=E=1,d}var l=/^\0+/g,c=/[\0\r\f]/g,d=/: */g,p=/zoo|gra/,f=/([,: ])(transform)/g,h=/,\r+?/g,m=/([\t\r\n ])*\f?&/g,_=/@(k\w+)\s*(\S*)\s*/,y=/::(place)/g,g=/:(read-only)/g,v=/[svh]\w+-[tblr]{2}/,b=/\(\s*(.*)\s*\)/g,w=/([\s\S]*?);/g,M=/-self|flex-/g,L=/[^]*?(:[rp][el]a[\w-]+)[^]*/,T=/stretch|:\s*\w+\-(?:conte|avail)/,k=/([^-])(image-set\()/,x=1,E=1,S=0,O=1,D=[],Y=[],A=0,C=null,j=0;return u.use=function e(t){switch(t){case void 0:case null:A=Y.length=0;break;default:if("function"==typeof t)Y[A++]=t;else if("object"==typeof t)for(var n=0,r=t.length;n<r;++n)e(t[n]);else j=0|!!t}return e},u.set=s,void 0!==e&&s(e),u};function s(e){e&&u.current.insert(e+"}")}var u={current:null},l=function(e,t,n,r,a,o,i,l,c,d){switch(e){case 1:switch(t.charCodeAt(0)){case 64:return u.current.insert(t+";"),"";case 108:if(98===t.charCodeAt(2))return""}break;case 2:if(0===l)return t+"/*|*/";break;case 3:switch(l){case 102:case 112:return u.current.insert(n[0]+t),"";default:return t+(0===d?"/*|*/":"")}case-2:t.split("/*|*/}").forEach(s)}},c=function(e){void 0===e&&(e={});var t,n=e.key||"css";void 0!==e.prefix&&(t={prefix:e.prefix});var r=new i(t);var a,s={};a=e.container||document.head;var c,d=document.querySelectorAll("style[data-emotion-"+n+"]");Array.prototype.forEach.call(d,(function(e){e.getAttribute("data-emotion-"+n).split(" ").forEach((function(e){s[e]=!0})),e.parentNode!==a&&a.appendChild(e)})),r.use(e.stylisPlugins)(l),c=function(e,t,n,a){var o=t.name;u.current=n,r(e,t.styles),a&&(p.inserted[o]=!0)};var p={key:n,sheet:new o({key:n,container:a,nonce:e.nonce,speedy:e.speedy}),nonce:e.nonce,inserted:s,registered:{},insert:c};return p};n(348);function d(e,t,n){var r="";return n.split(" ").forEach((function(n){void 0!==e[n]?t.push(e[n]):r+=n+" "})),r}var p=function(e,t,n){var r=e.key+"-"+t.name;if(!1===n&&void 0===e.registered[r]&&(e.registered[r]=t.styles),void 0===e.inserted[t.name]){var a=t;do{e.insert("."+r,a,e.sheet,!0);a=a.next}while(void 0!==a)}};var f=function(e){for(var t,n=0,r=0,a=e.length;a>=4;++r,a-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(a){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)},h={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};var m=/[A-Z]|^ms/g,_=/_EMO_([^_]+?)_([^]*?)_EMO_/g,y=function(e){return 45===e.charCodeAt(1)},g=function(e){return null!=e&&"boolean"!=typeof e},v=function(e){var t={};return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}}((function(e){return y(e)?e:e.replace(m,"-$&").toLowerCase()})),b=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(_,(function(e,t,n){return M={name:t,styles:n,next:M},t}))}return 1===h[e]||y(e)||"number"!=typeof t||0===t?t:t+"px"};function w(e,t,n,r){if(null==n)return"";if(void 0!==n.__emotion_styles)return n;switch(typeof n){case"boolean":return"";case"object":if(1===n.anim)return M={name:n.name,styles:n.styles,next:M},n.name;if(void 0!==n.styles){var a=n.next;if(void 0!==a)for(;void 0!==a;)M={name:a.name,styles:a.styles,next:M},a=a.next;return n.styles+";"}return function(e,t,n){var r="";if(Array.isArray(n))for(var a=0;a<n.length;a++)r+=w(e,t,n[a],!1);else for(var o in n){var i=n[o];if("object"!=typeof i)null!=t&&void 0!==t[i]?r+=o+"{"+t[i]+"}":g(i)&&(r+=v(o)+":"+b(o,i)+";");else if(!Array.isArray(i)||"string"!=typeof i[0]||null!=t&&void 0!==t[i[0]]){var s=w(e,t,i,!1);switch(o){case"animation":case"animationName":r+=v(o)+":"+s+";";break;default:r+=o+"{"+s+"}"}}else for(var u=0;u<i.length;u++)g(i[u])&&(r+=v(o)+":"+b(o,i[u])+";")}return r}(e,t,n);case"function":if(void 0!==e){var o=M,i=n(e);return M=o,w(e,t,i,r)}break;case"string":}if(null==t)return n;var s=t[n];return void 0===s||r?n:s}var M,L=/label:\s*([^\s;\n{]+)\s*;/g;var T=function(e,t,n){if(1===e.length&&"object"==typeof e[0]&&null!==e[0]&&void 0!==e[0].styles)return e[0];var r=!0,a="";M=void 0;var o=e[0];null==o||void 0===o.raw?(r=!1,a+=w(n,t,o,!1)):a+=o[0];for(var i=1;i<e.length;i++)a+=w(n,t,e[i],46===a.charCodeAt(a.length-1)),r&&(a+=o[i]);L.lastIndex=0;for(var s,u="";null!==(s=L.exec(a));)u+="-"+s[1];return{name:f(a)+u,styles:a,next:M}},k=Object.prototype.hasOwnProperty,x=Object(a.createContext)("undefined"!=typeof HTMLElement?c():null),E=Object(a.createContext)({}),S=x.Provider,O=function(e){var t=function(t,n){return Object(a.createElement)(x.Consumer,null,(function(r){return e(t,r,n)}))};return Object(a.forwardRef)(t)},D="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",Y=function(e,t){var n={};for(var r in t)k.call(t,r)&&(n[r]=t[r]);return n[D]=e,n},A=function(e,t,n,r){var o=null===n?t.css:t.css(n);"string"==typeof o&&void 0!==e.registered[o]&&(o=e.registered[o]);var i=t[D],s=[o],u="";"string"==typeof t.className?u=d(e.registered,s,t.className):null!=t.className&&(u=t.className+" ");var l=T(s);p(e,l,"string"==typeof i);u+=e.key+"-"+l.name;var c={};for(var f in t)k.call(t,f)&&"css"!==f&&f!==D&&(c[f]=t[f]);return c.ref=r,c.className=u,Object(a.createElement)(i,c)},C=O((function(e,t,n){return"function"==typeof e.css?Object(a.createElement)(E.Consumer,null,(function(r){return A(t,e,r,n)})):A(t,e,null,n)}));var j=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return T(t)},P=function(e,t){var n=arguments;if(null==t||!k.call(t,"css"))return a.createElement.apply(void 0,n);var r=n.length,o=new Array(r);o[0]=C,o[1]=Y(e,t);for(var i=2;i<r;i++)o[i]=n[i];return a.createElement.apply(null,o)},H=O((function(e,t){var n=e.styles;if("function"==typeof n)return Object(a.createElement)(E.Consumer,null,(function(e){var r=T([n(e)]);return Object(a.createElement)(I,{serialized:r,cache:t})}));var r=T([n]);return Object(a.createElement)(I,{serialized:r,cache:t})})),I=function(e){var t,n;function a(t,n,r){return e.call(this,t,n,r)||this}n=e,(t=a).prototype=Object.create(n.prototype),t.prototype.constructor=t,r(t,n);var i=a.prototype;return i.componentDidMount=function(){this.sheet=new o({key:this.props.cache.key+"-global",nonce:this.props.cache.sheet.nonce,container:this.props.cache.sheet.container});var e=document.querySelector("style[data-emotion-"+this.props.cache.key+'="'+this.props.serialized.name+'"]');null!==e&&this.sheet.tags.push(e),this.props.cache.sheet.tags.length&&(this.sheet.before=this.props.cache.sheet.tags[0]),this.insertStyles()},i.componentDidUpdate=function(e){e.serialized.name!==this.props.serialized.name&&this.insertStyles()},i.insertStyles=function(){if(void 0!==this.props.serialized.next&&p(this.props.cache,this.props.serialized.next,!0),this.sheet.tags.length){var e=this.sheet.tags[this.sheet.tags.length-1].nextElementSibling;this.sheet.before=e,this.sheet.flush()}this.props.cache.insert("",this.props.serialized,this.sheet,!1)},i.componentWillUnmount=function(){this.sheet.flush()},i.render=function(){return null},a}(a.Component),N=function(){var e=j.apply(void 0,arguments),t="animation-"+e.name;return{name:t,styles:"@keyframes "+t+"{"+e.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}},R=function e(t){for(var n=t.length,r=0,a="";r<n;r++){var o=t[r];if(null!=o){var i=void 0;switch(typeof o){case"boolean":break;case"object":if(Array.isArray(o))i=e(o);else for(var s in i="",o)o[s]&&s&&(i&&(i+=" "),i+=s);break;default:i=o}i&&(a&&(a+=" "),a+=i)}}return a};function F(e,t,n){var r=[],a=d(e,r,n);return r.length<2?n:a+t(r)}var z=O((function(e,t){return Object(a.createElement)(E.Consumer,null,(function(n){var r=function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];var a=T(n,t.registered);return p(t,a,!1),t.key+"-"+a.name},a={css:r,cx:function(){for(var e=arguments.length,n=new Array(e),a=0;a<e;a++)n[a]=arguments[a];return F(t.registered,r,R(n))},theme:n},o=e.children(a);return!0,o}))}))}])}));
281
281
  //# sourceMappingURL=components.js.map